:root {
  --primary-blue: #1e40af;
  --accent-teal: #14b8a6;
  --bg: #f8fafc;
  --text: #0f172a;
  --muted: #475569;
  --border: rgba(148, 163, 184, 0.5);
  --shadow: 0 10px 30px rgba(2, 6, 23, 0.08);
  --radius: 16px;
  --radius-lg: 24px;
  --ring: 0 0 0 2px rgba(30, 64, 175, 0.35);
  font-family:
    ui-sans-serif,
    system-ui,
    -apple-system,
    Segoe UI,
    Roboto,
    Helvetica,
    Arial,
    "Apple Color Emoji",
    "Segoe UI Emoji";
}
* {
  box-sizing: border-box;
}
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  min-height: 100vh;
}
a {
  color: inherit;
  text-decoration: none;
}
.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 24px;
}
@media (min-width: 1024px) {
  .container {
    padding: 0 48px;
  }
}
/* Navbar (matches Navbar.jsx structure) */
.site-header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 50;
}
.site-nav-wrap {
  margin: 16px 16px 0;
}
@media (min-width: 1024px) {
  .site-nav-wrap {
    margin: 16px 32px 0;
  }
}
.nav-surface {
  background: rgba(255, 255, 255, 0.8);
  backdrop-filter: blur(18px);
  -webkit-backdrop-filter: blur(18px);
  border: 1px solid rgba(226, 232, 240, 0.6);
  border-radius: 24px;
  box-shadow: 0 10px 30px rgba(226, 232, 240, 0.35);
}
.nav-inner {
  padding: 16px 24px;
}
.nav-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}
.brand {
  display: flex;
  align-items: center;
  gap: 12px;
  border-radius: 12px;
}
.brand:focus {
  outline: none;
  box-shadow: var(--ring);
}
.brand-icon {
  width: 40px;
  height: 40px;
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(135deg, var(--primary-blue), var(--accent-teal));
}
/* When a real logo image is used, avoid the gradient badge background */
.brand-icon.has-logo {
  background: transparent;
  box-shadow: none;
  border: 1px solid rgba(148, 163, 184, 0.35);
}
.brand-title {
  font-weight: 800;
  font-size: 20px;
  letter-spacing: -0.02em;
  color: var(--primary-blue);
}
.nav-links {
  display: none;
  gap: 32px;
  align-items: center;
}
@media (min-width: 1024px) {
  .nav-links {
    display: flex;
  }
}
.nav-link {
  position: relative;
  font-size: 14px;
  font-weight: 600;
  color: #475569;
  padding: 6px 8px;
  border-radius: 8px;
  transition:
    transform 0.15s ease,
    color 0.15s ease,
    background 0.15s ease;
}
.nav-link:hover {
  transform: scale(1.05);
  color: #0f172a;
}
.nav-link:focus {
  outline: none;
  box-shadow: var(--ring);
}
.nav-link.active {
  color: var(--primary-blue);
}
.nav-link.active::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: -4px;
  height: 3px;
  border-radius: 999px;
  background: var(--primary-blue);
}
.nav-actions {
  display: none;
  align-items: center;
  gap: 12px;
}
@media (min-width: 1024px) {
  .nav-actions {
    display: flex;
  }
}
.searchbar {
  width: 260px;
  border: 1px solid rgba(226, 232, 240, 0.9);
  background: white;
  border-radius: 12px;
  padding: 10px 12px;
  display: flex;
  align-items: center;
  gap: 8px;
}
.searchbar input {
  border: 0;
  outline: 0;
  width: 100%;
  font-size: 14px;
}
.btn {
  border: 0;
  cursor: pointer;
  height: 44px;
  padding: 0 18px;
  border-radius: 12px;
  font-weight: 600;
  display: inline-flex;
  align-items: center;
  gap: 10px;
  transition:
    transform 0.15s ease,
    box-shadow 0.2s ease,
    opacity 0.2s ease,
    background 0.2s ease;
}
.btn:focus {
  outline: none;
  box-shadow: var(--ring);
}
.btn-primary {
  background: #0f172a;
  color: white;
}
.btn-primary:hover {
  background: #111827;
  transform: scale(1.03);
  box-shadow: var(--shadow);
}
/* Mobile */
.mobile-actions {
  display: flex;
  align-items: center;
  gap: 8px;
}
@media (min-width: 1024px) {
  .mobile-actions {
    display: none;
  }
}
.icon-btn {
  width: 44px;
  height: 44px;
  border-radius: 12px;
  border: 0;
  background: transparent;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: #334155;
}
.icon-btn:hover {
  background: #f1f5f9;
}
.drawer-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(2, 6, 23, 0.45);
  display: none;
  z-index: 60;
}
.drawer {
  position: fixed;
  top: 0;
  right: -340px;
  height: 100%;
  width: 320px;
  background: white;
  z-index: 70;
  border-left: 1px solid rgba(226, 232, 240, 0.9);
  transition: right 0.25s ease;
  padding: 24px;
}
.drawer.open {
  right: 0;
}
.drawer-backdrop.open {
  display: block;
}
.drawer-brand {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-top: 8px;
  margin-bottom: 28px;
}
.drawer-title {
  font-size: 20px;
  font-weight: 800;
}
.drawer-links {
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.drawer-links a {
  padding: 12px 16px;
  border-radius: 14px;
  font-weight: 600;
  color: #334155;
}
.drawer-links a:hover {
  background: #f8fafc;
}
.drawer-links a.active {
  background: #eff6ff;
  color: var(--primary-blue);
}
/* Page spacing because header fixed */
main {
  padding-top: 110px;
}

/* Auth pages (login/register) */
.auth-main {
  padding-top: 140px; /* override main padding-top when header is fixed */
  padding-bottom: 64px;
  min-height: calc(100vh - 140px);
  display: flex;
  align-items: center;
  justify-content: center;
}
.auth-card {
  width: 100%;
  max-width: 620px;
}

/* Testimonials avatar (no photo required) */
.t-avatar {
  width: 48px;
  height: 48px;
  border-radius: 16px;
  background: linear-gradient(135deg, var(--primary-blue), var(--accent-teal));
  color: white;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 900;
  letter-spacing: 0.02em;
  box-shadow: 0 10px 22px rgba(30, 64, 175, 0.18);
}

/* Hero + sections */
.hero {
  background: #020617;
  color: white;
  position: relative;
  overflow: hidden;
}
.hero::before {
  content: "";
  position: absolute;
  inset: 0;
  opacity: 0.28;
  background: linear-gradient(135deg, #10b981, #06b6d4, #2563eb);
}
.hero-inner {
  position: relative;
  padding: 80px 0;
}
.hero-blur-bg {
  position: absolute;
  inset: 0;
  border-radius: 32px;
  overflow: hidden;
  pointer-events: none;
}
.hero-blur-bg img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transform: scale(1.15);
  filter: blur(26px);
  opacity: 0.55;
}
.hero-blur-bg::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(
    90deg,
    rgba(2, 6, 23, 0.92) 0%,
    rgba(2, 6, 23, 0.7) 48%,
    rgba(2, 6, 23, 0.4) 100%
  );
}
.hero-grid {
  display: grid;
  gap: 40px;
  align-items: center;
  position: relative;
  z-index: 1;
}
@media (min-width: 1024px) {
  .hero-grid {
    grid-template-columns: 1.1fr 0.9fr;
  }
}
.kicker {
  font-size: 12px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.75);
  font-weight: 700;
}
.hero-title {
  margin: 16px 0 0;
  font-size: 44px;
  line-height: 1.05;
  font-weight: 900;
  letter-spacing: -0.03em;
}
.hero-subtitle {
  margin: 16px 0 0;
  font-size: 18px;
  color: rgba(255, 255, 255, 0.8);
  font-weight: 700;
}
.hero-desc {
  margin: 16px 0 0;
  color: rgba(255, 255, 255, 0.7);
  line-height: 1.7;
}
.hero-ctas {
  margin-top: 28px;
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
}
.btn-light {
  background: white;
  color: #0f172a;
}
.btn-light:hover {
  opacity: 0.92;
}
.btn-ghost {
  background: rgba(255, 255, 255, 0.1);
  color: white;
  border: 1px solid rgba(255, 255, 255, 0.2);
}
.btn-ghost:hover {
  background: rgba(255, 255, 255, 0.14);
}
.hero-media {
  border-radius: 24px;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.16);
  box-shadow: 0 30px 60px rgba(0, 0, 0, 0.35);
}
.hero-media img {
  width: 100%;
  height: 420px;
  object-fit: cover;
  display: block;
}
.hero-floating {
  position: absolute;
  left: -20px;
  bottom: -20px;
  width: min(360px, 90%);
  padding: 16px;
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.2);
  backdrop-filter: blur(16px);
}
.hero-floating b {
  display: block;
  margin-bottom: 4px;
}
.carousel-controls {
  margin-top: 28px;
  display: flex;
  align-items: center;
  gap: 10px;
}
.circle-btn {
  width: 40px;
  height: 40px;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.2);
  color: white;
  cursor: pointer;
}
.circle-btn:hover {
  background: rgba(255, 255, 255, 0.14);
}
.dots {
  display: flex;
  gap: 8px;
  margin-left: 8px;
}
.dot {
  width: 10px;
  height: 10px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.4);
  border: 0;
  cursor: pointer;
}
.dot.active {
  background: white;
}
.section {
  padding: 80px 0;
  background: white;
}
.section.alt {
  background: #f8fafc;
}
.section-title {
  max-width: 720px;
  margin: 0 auto 48px;
  text-align: center;
}
.section-title .tag {
  font-size: 12px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: #64748b;
  font-weight: 800;
}
.section-title h2 {
  margin: 12px 0 0;
  font-size: 34px;
  letter-spacing: -0.02em;
}
.section-title p {
  margin: 14px 0 0;
  color: #475569;
  line-height: 1.7;
}
.grid3 {
  display: grid;
  gap: 22px;
}
@media (min-width: 768px) {
  .grid3 {
    grid-template-columns: repeat(2, 1fr);
  }
}
@media (min-width: 1024px) {
  .grid3 {
    grid-template-columns: repeat(3, 1fr);
  }
}
.card {
  background: white;
  border: 1px solid rgba(226, 232, 240, 0.9);
  border-radius: 24px;
  padding: 28px;
  transition:
    transform 0.2s ease,
    box-shadow 0.2s ease;
}
.card:hover {
  transform: translateY(-4px);
  box-shadow: 0 18px 44px rgba(148, 163, 184, 0.35);
}
.card-icon {
  width: 48px;
  height: 48px;
  border-radius: 16px;
  background: #0f172a;
  color: white;
  display: flex;
  align-items: center;
  justify-content: center;
}
.card h3 {
  margin: 18px 0 0;
  font-size: 20px;
  font-weight: 900;
}
.card p {
  margin: 12px 0 0;
  color: #475569;
  line-height: 1.7;
}

/* ---------- Media helpers (consistent cards, no crop) ---------- */
.media-frame {
  --h: 180px;
  height: var(--h);
  background: #e2e8f0;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}
.media-frame img {
  width: 100%;
  height: 100%;
  object-fit: contain; /* avoid cropping; keep full image visible */
  display: block;
}

.blog-media.no-crop img {
  object-fit: contain;
  background: #0f172a;
}

/* ---------- Load-more helpers ---------- */
.lm-hidden {
  display: none !important;
}
.lm-actions {
  margin-top: 22px;
  display: flex;
  justify-content: center;
}
.lm-btn {
  cursor: pointer;
}
.card .link {
  margin-top: 16px;
  display: inline-flex;
  gap: 8px;
  color: #047857;
  font-weight: 800;
}
.stats {
  display: grid;
  gap: 16px;
}
@media (min-width: 768px) {
  .stats {
    grid-template-columns: repeat(2, 1fr);
  }
}
@media (min-width: 1024px) {
  .stats {
    grid-template-columns: repeat(4, 1fr);
  }
}
.stat {
  background: white;
  border: 1px solid rgba(226, 232, 240, 0.9);
  border-radius: 24px;
  padding: 26px;
  text-align: center;
}
.stat .ico {
  width: 48px;
  height: 48px;
  border-radius: 16px;
  background: #ecfdf5;
  color: #047857;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: center;
}
.stat .val {
  margin-top: 14px;
  font-size: 28px;
  font-weight: 900;
}
.stat .lbl {
  margin-top: 8px;
  font-size: 13px;
  color: #475569;
  font-weight: 700;
}
.footer {
  background: #020617;
  color: #94a3b8;
  margin-top: 80px;
}
.footer-inner {
  padding: 64px 0;
}
.footer-grid {
  display: grid;
  gap: 28px;
}
@media (min-width: 768px) {
  .footer-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}
@media (min-width: 1024px) {
  .footer-grid {
    grid-template-columns: 2fr 1fr 1fr 1fr 1fr;
  }
}
.footer a:hover {
  opacity: 0.85;
}
.footer h4 {
  color: #e2e8f0;
  margin: 0 0 14px;
  font-size: 14px;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}
.footer small {
  color: #64748b;
}
.footer small,
.footer a {
  word-break: break-word;
}

.filter-btn {
  border: 1px solid rgba(226, 232, 240, 0.9);
  background: #f1f5f9;
  color: #334155;
  padding: 10px 14px;
  border-radius: 12px;
  font-weight: 700;
  cursor: pointer;
}
.filter-btn:hover {
  background: #e2e8f0;
}
.filter-btn.active {
  background: #0f172a;
  color: white;
  border-color: #0f172a;
}

/* ---------- Common UI pieces (to mimic shadcn/tailwind) ---------- */
.pill {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  border-radius: 999px;
  padding: 8px 14px;
  font-weight: 700;
  font-size: 13px;
  border: 1px solid rgba(226, 232, 240, 0.9);
  background: #fff;
}
.badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  border-radius: 999px;
  padding: 6px 10px;
  font-weight: 700;
  font-size: 12px;
  border: 1px solid rgba(226, 232, 240, 0.9);
  background: #fff;
}
.badge.secondary {
  background: #f1f5f9;
  color: #0f172a;
}
.badge.outline {
  background: transparent;
  color: #475569;
}
.input {
  width: 100%;
  border: 2px solid rgba(226, 232, 240, 0.9);
  background: #fff;
  border-radius: 16px;
  padding: 14px 16px;
  font-size: 16px;
  outline: none;
  transition:
    border-color 0.15s ease,
    box-shadow 0.15s ease;
}
.input:focus {
  border-color: rgba(30, 64, 175, 0.9);
  box-shadow: var(--ring);
}
.textarea {
  min-height: 120px;
  resize: none;
}

.select {
  position: relative;
  display: inline-block;
}
.select > button {
  height: 44px;
  padding: 0 14px;
  border-radius: 14px;
  border: 1px solid rgba(226, 232, 240, 0.9);
  background: #fff;
  font-weight: 700;
  color: #0f172a;
  display: inline-flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  min-width: 200px;
  cursor: pointer;
}
.select-panel {
  position: absolute;
  top: calc(100% + 10px);
  right: 0;
  min-width: 240px;
  background: #fff;
  border: 1px solid rgba(226, 232, 240, 0.9);
  border-radius: 16px;
  box-shadow: 0 18px 44px rgba(15, 23, 42, 0.12);
  padding: 8px;
  z-index: 20;
  display: none;
}
.select.open .select-panel {
  display: block;
}
.select-item {
  width: 100%;
  text-align: left;
  border: 0;
  background: transparent;
  padding: 10px 12px;
  border-radius: 12px;
  font-weight: 700;
  color: #0f172a;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 10px;
}
.select-item:hover {
  background: #f8fafc;
}

.tabs {
  display: inline-flex;
  background: #f1f5f9;
  border: 1px solid rgba(226, 232, 240, 0.9);
  border-radius: 16px;
  padding: 6px;
  gap: 6px;
  flex-wrap: wrap;
}
.tab {
  border: 0;
  background: transparent;
  padding: 10px 12px;
  border-radius: 12px;
  font-weight: 800;
  color: #334155;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 13px;
}
.tab.active {
  background: #fff;
  color: #0f172a;
  box-shadow: 0 10px 30px rgba(2, 6, 23, 0.08);
}

.grid {
  display: grid;
  gap: 22px;
}
@media (min-width: 768px) {
  .grid.cols-2 {
    grid-template-columns: repeat(2, 1fr);
  }
}
@media (min-width: 1024px) {
  .grid.cols-3 {
    grid-template-columns: repeat(3, 1fr);
  }
}

/* ---------- Page headers (dark gradient) ---------- */
.page-hero {
  background: linear-gradient(135deg, #020617, #0f172a, #020617);
  color: #fff;
  padding: 88px 0 72px;
  position: relative;
  overflow: hidden;
}
.page-hero::before {
  content: "";
  position: absolute;
  inset: 0;
  opacity: 0.2;
  background-image: radial-gradient(
    circle at 1px 1px,
    rgba(255, 255, 255, 0.15) 1px,
    transparent 0
  );
  background-size: 40px 40px;
}
.page-hero .glow {
  position: absolute;
  top: 40px;
  right: 80px;
  width: 320px;
  height: 320px;
  border-radius: 999px;
  filter: blur(60px);
  background: rgba(16, 185, 129, 0.18);
}
.page-hero .content {
  position: relative;
  z-index: 1;
  text-align: center;
}
.page-hero .k {
  color: #60a5fa;
  font-weight: 800;
  font-size: 12px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}
.page-hero h1 {
  margin: 16px 0 0;
  font-size: 44px;
  letter-spacing: -0.03em;
  font-weight: 900;
}
.page-hero p {
  margin: 14px auto 0;
  max-width: 720px;
  color: rgba(226, 232, 240, 0.75);
  font-size: 18px;
  line-height: 1.7;
}

/* ---------- Product/Course cards (match JSX) ---------- */
.tile {
  background: #fff;
  border: 1px solid rgba(226, 232, 240, 0.9);
  border-radius: 24px;
  overflow: hidden;
  transition:
    transform 0.2s ease,
    box-shadow 0.2s ease;
  display: flex;
  flex-direction: column;
  height: 100%;
}
.tile:hover {
  transform: translateY(-4px);
  box-shadow: 0 18px 44px rgba(148, 163, 184, 0.35);
}
.tile-media {
  position: relative;
  height: 192px;
  background: linear-gradient(135deg, #f1f5f9, #f8fafc);
  overflow: hidden;
}
.tile-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 0.35s ease;
}
.tile:hover .tile-media img {
  transform: scale(1.05);
}
.tile-body {
  padding: 24px;
  display: flex;
  flex-direction: column;
  gap: 12px;
  flex: 1;
}
.tile-title {
  margin: 0;
  font-size: 20px;
  font-weight: 900;
  color: #0f172a;
}
.tile:hover .tile-title {
  color: var(--primary-blue);
}
.tile-desc {
  margin: 0;
  color: #475569;
  line-height: 1.7;
  font-size: 14px;
}
.chips {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}
.chip {
  font-size: 12px;
  padding: 6px 10px;
  border-radius: 10px;
  background: #f1f5f9;
  color: #475569;
  font-weight: 700;
}
.tile-cta {
  margin-top: auto;
}
.btn-ghost-wide {
  width: 100%;
  justify-content: space-between;
  background: transparent;
  border: 0;
  padding: 12px 0;
  font-weight: 900;
  color: var(--primary-blue);
  cursor: pointer;
  border-radius: 14px;
}
.btn-ghost-wide:hover {
  background: #eff6ff;
  padding: 12px 14px;
}
.btn-ghost-wide.green {
  color: #059669;
}
.btn-ghost-wide.green:hover {
  background: #ecfdf5;
}

.media-badge {
  position: absolute;
  top: 14px;
  left: 14px;
}
.media-badge-right {
  position: absolute;
  top: 14px;
  right: 14px;
}

/* ---------- Blog cards ---------- */
.blog-card .tile-media {
  height: 220px;
}
.blog-card .tile-title {
  font-size: 20px;
}
.meta-row {
  display: flex;
  align-items: center;
  gap: 14px;
  color: #64748b;
  font-weight: 700;
  font-size: 12px;
  flex-wrap: wrap;
}
.meta-row .dot {
  width: 4px;
  height: 4px;
  border-radius: 999px;
  background: #cbd5e1;
}
.line-clamp-2 {
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.line-clamp-3 {
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

/* ---------- Blog post layout ---------- */
.post-wrap {
  background: #fff;
}
.post-header {
  padding: 72px 0 72px;
  background: linear-gradient(135deg, #020617, #0f172a, #020617);
  color: #fff;
  position: relative;
  overflow: hidden;
}
.post-header::before {
  content: "";
  position: absolute;
  inset: 0;
  opacity: 0.2;
  background-image: radial-gradient(
    circle at 1px 1px,
    rgba(255, 255, 255, 0.15) 1px,
    transparent 0
  );
  background-size: 40px 40px;
  pointer-events: none;
}
.post-header .glow {
  position: absolute;
  top: 40px;
  right: 80px;
  width: 320px;
  height: 320px;
  border-radius: 999px;
  filter: blur(70px);
  background: rgba(16, 185, 129, 0.18);
  pointer-events: none;
  z-index: 0;
}
.post-header .container {
  position: relative;
  z-index: 2;
}
.post-header .inner {
  position: relative;
  z-index: 1;
  max-width: 860px;
  margin: 0 auto;
}
.back-link {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: #94a3b8;
  font-weight: 800;
  border-radius: 14px;
  padding: 10px 12px;
  margin-left: -12px;
}
.back-link:hover {
  color: #fff;
  background: rgba(148, 163, 184, 0.12);
}
.post-header h1 {
  margin: 16px 0 0;
  font-size: 44px;
  line-height: 1.1;
  letter-spacing: -0.03em;
}
.author-row {
  display: flex;
  align-items: center;
  gap: 12px;
}
.avatar {
  width: 40px;
  height: 40px;
  border-radius: 999px;
  overflow: hidden;
  background: #334155;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #cbd5e1;
  font-weight: 900;
}
.avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}
.post-cover {
  max-width: 860px;
  margin: -40px auto 0;
  padding: 0 24px;
  position: relative;
  z-index: 2;
}
.post-cover img {
  width: 100%;
  height: 360px;
  object-fit: cover;
  border-radius: 24px;
  box-shadow: 0 30px 70px rgba(2, 6, 23, 0.35);
}
.post-content {
  max-width: 860px;
  margin: 0 auto;
  padding: 48px 24px 0;
}
.sharebar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  border-bottom: 1px solid rgba(226, 232, 240, 0.9);
  padding-bottom: 22px;
  margin-bottom: 22px;
}
.sharebuttons {
  display: flex;
  align-items: center;
  gap: 10px;
}
.sharebuttons .sbtn {
  width: 38px;
  height: 38px;
  border-radius: 999px;
  border: 1px solid rgba(226, 232, 240, 0.9);
  background: #fff;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
}
.sharebuttons .sbtn:hover {
  background: #f8fafc;
}
.mobile-share {
  display: none;
}
@media (max-width: 768px) {
  .sharebar {
    display: none;
  }
  .mobile-share {
    display: block;
    margin-bottom: 22px;
  }
}
.prose {
  font-size: 18px;
  line-height: 1.85;
  color: #334155;
}
.prose h1,
.prose h2,
.prose h3 {
  color: #0f172a;
  letter-spacing: -0.02em;
}
.prose h2 {
  font-size: 28px;
  margin: 32px 0 14px;
  font-weight: 900;
}
.prose h3 {
  font-size: 22px;
  margin: 24px 0 12px;
  font-weight: 900;
}
.prose p {
  margin: 14px 0;
}
.prose ul,
.prose ol {
  margin: 14px 0;
  padding-left: 22px;
}
.prose li {
  margin: 8px 0;
}
.prose blockquote {
  border-left: 4px solid #10b981;
  background: #ecfdf5;
  border-radius: 0 16px 16px 0;
  padding: 14px 16px;
  margin: 22px 0;
  color: #0f172a;
}
.prose a {
  color: #059669;
  text-decoration: underline;
}
.prose code {
  background: #f1f5f9;
  border-radius: 10px;
  padding: 2px 8px;
  font-size: 14px;
}
.prose pre {
  background: #0f172a;
  color: #e2e8f0;
  border-radius: 16px;
  padding: 16px;
  overflow: auto;
}
.bottom-share {
  margin-top: 36px;
  padding-top: 22px;
  border-top: 1px solid rgba(226, 232, 240, 0.9);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
}

/* ---------- Comments ---------- */
.comments {
  margin-top: 44px;
  padding-top: 44px;
  border-top: 1px solid rgba(226, 232, 240, 0.9);
}
.comments h3 {
  margin: 0;
  font-size: 26px;
  font-weight: 900;
  display: flex;
  align-items: center;
  gap: 10px;
}
.comment-form {
  background: #fff;
  border: 1px solid rgba(226, 232, 240, 0.9);
  border-radius: 24px;
  padding: 22px;
  margin: 18px 0;
}
.comment-list {
  display: flex;
  flex-direction: column;
  gap: 18px;
}
.comment-item {
  display: flex;
  gap: 14px;
}
.comment-bubble {
  background: #f8fafc;
  border-radius: 24px;
  padding: 16px;
  flex: 1;
}
.comment-actions {
  display: flex;
  gap: 10px;
  margin-top: 10px;
  flex-wrap: wrap;
}
.mini-btn {
  border: 0;
  background: transparent;
  color: #059669;
  font-weight: 900;
  cursor: pointer;
  border-radius: 12px;
  padding: 8px 10px;
}
.mini-btn:hover {
  background: #ecfdf5;
}
.mini-btn.danger {
  color: #ef4444;
}
.mini-btn.danger:hover {
  background: #fef2f2;
}
.nested {
  margin-left: 52px;
}

/* ---------- Search page ---------- */
.search-wrap {
  padding: 32px 0 64px;
}
.filters-bar {
  background: #fff;
  border: 1px solid rgba(226, 232, 240, 0.9);
  border-radius: 24px;
  padding: 16px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
}
.results-section {
  margin-top: 26px;
}
.results-title {
  display: flex;
  align-items: center;
  gap: 10px;
  margin: 0 0 16px;
}

/* ---------- Contact ---------- */
.contact-grid {
  display: grid;
  gap: 28px;
}
@media (min-width: 1024px) {
  .contact-grid {
    grid-template-columns: 1fr 2fr;
    gap: 48px;
  }
}
.contact-card {
  background: #fff;
  border: 1px solid rgba(226, 232, 240, 0.9);
  border-radius: 24px;
  padding: 28px;
  box-shadow: 0 18px 44px rgba(148, 163, 184, 0.25);
}
.field {
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.label {
  font-weight: 800;
  color: #334155;
}
.two-col {
  display: grid;
  gap: 16px;
}
@media (min-width: 768px) {
  .two-col {
    grid-template-columns: repeat(2, 1fr);
  }
}
.success-wrap {
  min-height: calc(100vh - 110px);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 48px 0;
}
.success-card {
  text-align: center;
  max-width: 620px;
}

/* ---------- Toast ---------- */
.toast {
  position: fixed;
  bottom: 18px;
  left: 50%;
  transform: translateX(-50%);
  background: #0f172a;
  color: #fff;
  padding: 12px 16px;
  border-radius: 999px;
  box-shadow: 0 18px 44px rgba(2, 6, 23, 0.35);
  z-index: 100;
  opacity: 0;
  pointer-events: none;
  transition:
    opacity 0.2s ease,
    transform 0.2s ease;
}
.toast.show {
  opacity: 1;
  transform: translateX(-50%) translateY(-6px);
}

/* ===================== Blog (remodeled) ===================== */
.toolbar {
  display: flex;
  gap: 14px;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  margin-bottom: 18px;
}
.toolbar-left {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
}
.toolbar-right {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  align-items: center;
}
.toolbar .input {
  display: flex;
  align-items: center;
  gap: 10px;
  background: #fff;
  border: 1px solid rgba(226, 232, 240, 0.9);
  border-radius: 16px;
  padding: 12px 14px;
}
.toolbar .input input {
  border: 0;
  outline: 0;
  width: 100%;
  font-size: 14px;
  background: transparent;
}

/* ---------- Contact page ---------- */
.label {
  display: block;
  margin: 0 0 6px;
  font-weight: 800;
  color: #0f172a;
}
.section.alt .label {
  color: #0f172a;
}
.contact-grid {
  display: grid;
  gap: 18px;
  grid-template-columns: 1fr;
  align-items: start;
}
.contact-form-card {
  padding: 22px;
}
.contact-form {
  margin-top: 18px;
  display: grid;
  gap: 12px;
}
.contact-row {
  display: grid;
  gap: 12px;
  grid-template-columns: 1fr;
}
.contact-aside {
  display: grid;
  gap: 18px;
}
@media (min-width: 900px) {
  .contact-grid {
    grid-template-columns: 1.1fr 0.9fr;
  }
  .contact-row {
    grid-template-columns: 1fr 1fr;
  }
}
.featured {
  margin-top: 18px;
}
.blog-feature {
  display: block;
  border-radius: 24px;
  overflow: hidden;
  border: 1px solid rgba(226, 232, 240, 0.9);
  background: #fff;
  box-shadow: 0 18px 44px rgba(2, 6, 23, 0.06);
  transition:
    transform 0.2s ease,
    box-shadow 0.2s ease;
}
.blog-feature:hover {
  transform: translateY(-4px);
  box-shadow: 0 22px 54px rgba(2, 6, 23, 0.1);
}
.blog-feature-grid {
  display: grid;
}
@media (min-width: 1024px) {
  .blog-feature-grid {
    grid-template-columns: 1.1fr 0.9fr;
  }
}
.blog-feature-media {
  position: relative;
  min-height: 260px;
  background: #0f172a;
}
.blog-feature-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  filter: saturate(1.05);
}
.blog-feature-fade {
  position: absolute;
  inset: 0;
  background: linear-gradient(
    90deg,
    rgba(2, 6, 23, 0.55),
    rgba(2, 6, 23, 0.15)
  );
}
@media (min-width: 1024px) {
  .blog-feature-fade {
    background: linear-gradient(
      135deg,
      rgba(2, 6, 23, 0.25),
      rgba(2, 6, 23, 0.05)
    );
  }
}
.blog-feature-body {
  padding: 28px;
  display: flex;
  flex-direction: column;
  gap: 14px;
}
.blog-feature-title {
  margin: 0;
  font-size: 28px;
  letter-spacing: -0.02em;
  font-weight: 900;
  line-height: 1.15;
}
.blog-feature-excerpt {
  margin: 0;
  color: #475569;
  line-height: 1.75;
}
.blog-feature-bottom {
  margin-top: auto;
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
}
.blog-feature-bottom .author {
  display: flex;
  align-items: center;
  gap: 12px;
}
.blog-feature-bottom .author-name {
  font-weight: 900;
  color: #0f172a;
}
.blog-feature-bottom .author-date {
  font-size: 12px;
  color: #64748b;
  font-weight: 800;
}
.blog-feature-bottom .readmore {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-weight: 900;
  color: var(--primary-blue);
  padding: 10px 12px;
  border-radius: 14px;
}
.blog-feature-bottom .readmore:hover {
  background: #eff6ff;
}

.blog-card {
  display: block;
  border-radius: 24px;
  overflow: hidden;
  background: #fff;
  border: 1px solid rgba(226, 232, 240, 0.9);
  transition:
    transform 0.2s ease,
    box-shadow 0.2s ease;
}
.blog-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 18px 44px rgba(148, 163, 184, 0.35);
}
.blog-media {
  position: relative;
  height: 210px;
  background: #0f172a;
  overflow: hidden;
}
.blog-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 0.35s ease;
  filter: saturate(1.05);
}
.blog-card:hover .blog-media img {
  transform: scale(1.04);
}
.blog-hover {
  position: absolute;
  inset: 0;
  background: linear-gradient(
    180deg,
    rgba(2, 6, 23, 0.05),
    rgba(2, 6, 23, 0.55)
  );
  opacity: 0.9;
}
.blog-body {
  padding: 22px;
}
.blog-title {
  margin: 0;
  font-size: 18px;
  line-height: 1.25;
  font-weight: 900;
  letter-spacing: -0.01em;
}
.blog-excerpt {
  margin: 10px 0 0;
  color: #475569;
  line-height: 1.7;
  font-size: 14px;
}
.blog-meta {
  margin-top: 16px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}
.blog-meta .meta {
  display: flex;
  align-items: center;
  gap: 8px;
  color: #64748b;
  font-weight: 800;
  font-size: 12px;
}
.blog-meta .meta-right {
  display: flex;
  align-items: center;
  gap: 10px;
}
.blog-meta .arrow {
  color: var(--primary-blue);
}
.badge-abs-right {
  position: absolute;
  top: 14px;
  right: 14px;
}
.badge-emerald {
  background: #ecfdf5;
  border-color: #a7f3d0;
  color: #047857;
}
.badge-purple {
  background: #f5f3ff;
  border-color: #ddd6fe;
  color: #6d28d9;
}
.badge-blue {
  background: #eff6ff;
  border-color: #bfdbfe;
  color: #1d4ed8;
}
.badge-amber {
  background: #fffbeb;
  border-color: #fde68a;
  color: #b45309;
}

/* ===================== Blog post (remodeled) ===================== */
.post-content {
  padding: 44px 0;
}
.post-body-grid {
  max-width: 1100px;
  margin: 0 auto;
  padding: 0 24px;
  display: grid;
  gap: 28px;
}
@media (min-width: 1024px) {
  .post-body-grid {
    grid-template-columns: 1fr 320px;
    align-items: start;
  }
}
.post-main {
  min-width: 0;
}
.post-aside {
  position: relative;
}
@media (min-width: 1024px) {
  .post-aside {
    position: sticky;
    top: 124px;
  }
}
.aside-card {
  background: #fff;
  border: 1px solid rgba(226, 232, 240, 0.9);
  border-radius: 24px;
  padding: 18px;
  box-shadow: 0 12px 30px rgba(2, 6, 23, 0.06);
  margin-bottom: 14px;
}
.aside-title {
  font-weight: 900;
  color: #0f172a;
  margin-bottom: 12px;
}
.toc {
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.toc a {
  display: block;
  padding: 10px 12px;
  border-radius: 14px;
  color: #334155;
  font-weight: 800;
  font-size: 13px;
  border: 1px solid rgba(226, 232, 240, 0.9);
  background: #f8fafc;
}
.toc a:hover {
  background: #eff6ff;
  color: var(--primary-blue);
  border-color: #bfdbfe;
}
.toc a.toc-h3 {
  font-weight: 800;
  font-size: 12px;
  margin-left: 10px;
  border-radius: 12px;
}
.aside-cta .btn {
  width: 100%;
  justify-content: center;
  margin-top: 10px;
}

/* Blog safe margins (fix edge-sticking on wide screens) */
#featuredPost,
#blogGrid {
  max-width: 1200px;
  margin-left: auto;
  margin-right: auto;
  padding-left: 24px;
  padding-right: 24px;
}
@media (min-width: 1024px) {
  #featuredPost,
  #blogGrid {
    padding-left: 48px;
    padding-right: 48px;
  }
}

/* ===== Blog refresh (minimal + wider cards) ===== */
.blog-toolbar {
  display: flex;
  gap: 14px;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
}
.blog-toolbar .toolbar-left {
  flex: 1;
  min-width: 240px;
}
.blog-toolbar .toolbar-right {
  display: flex;
  gap: 10px;
  align-items: center;
  flex-wrap: wrap;
}
@media (max-width: 640px) {
  .blog-toolbar {
    gap: 12px;
  }
  .blog-toolbar .toolbar-left {
    width: 100%;
  }
  .blog-toolbar .toolbar-right {
    width: 100%;
    overflow: auto;
    flex-wrap: nowrap;
    padding-bottom: 6px;
  }
  .blog-toolbar .toolbar-right::-webkit-scrollbar {
    height: 6px;
  }
}
.chip {
  border: 1px solid rgba(148, 163, 184, 0.5);
  background: rgba(255, 255, 255, 0.7);
  color: #0f172a;
  font-weight: 800;
  border-radius: 999px;
  padding: 10px 12px;
  font-size: 13px;
  white-space: nowrap;
  transition: 0.2s;
}
.chip:hover {
  transform: translateY(-1px);
  box-shadow: 0 10px 20px rgba(2, 6, 23, 0.08);
}
.chip.active {
  background: #0f172a;
  color: #fff;
  border-color: #0f172a;
}
.blog-section-head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 18px;
  margin-top: 22px;
}
.blog-section-head h2 {
  margin: 0;
  font-size: 20px;
  letter-spacing: -0.02em;
}
.blog-section-head p {
  margin: 0;
  color: #64748b;
  font-weight: 700;
}
@media (max-width: 640px) {
  .blog-section-head {
    flex-direction: column;
    align-items: flex-start;
  }
}
.blog-grid {
  display: grid;
  gap: 22px;
  margin-top: 18px;
}
@media (min-width: 768px) {
  .blog-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}
@media (min-width: 1180px) {
  .blog-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}
.blog-card {
  min-width: 0;
}
.blog-title {
  letter-spacing: -0.02em;
}

/* ===== Blog post social/actions ===== */
.post-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  margin-top: 18px;
}
.action-group {
  display: flex;
  gap: 10px;
  align-items: center;
  flex-wrap: wrap;
}
.icon-btn {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  border: 1px solid rgba(148, 163, 184, 0.35);
  background: rgba(255, 255, 255, 0.06);
  color: #e2e8f0;
  border-radius: 999px;
  padding: 10px 12px;
  font-weight: 900;
  font-size: 13px;
  cursor: pointer;
  transition: 0.2s;
}
.icon-btn:hover {
  transform: translateY(-1px);
  box-shadow: 0 16px 30px rgba(2, 6, 23, 0.25);
}
.icon-btn .svg {
  width: 18px;
  height: 18px;
  display: inline-flex;
}
.icon-btn.light {
  background: #fff;
  color: #0f172a;
  border-color: rgba(148, 163, 184, 0.5);
}
.icon-btn.light:hover {
  box-shadow: 0 14px 30px rgba(2, 6, 23, 0.1);
}
.share-label {
  color: #94a3b8;
  font-weight: 900;
  font-size: 12px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}
.share-row {
  display: flex;
  gap: 10px;
  align-items: center;
  flex-wrap: wrap;
}

/* Engagement + share row */
.post-excerpt {
  color: rgba(226, 232, 240, 0.78);
  font-size: 18px;
  line-height: 1.7;
}
.post-actions {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  margin-top: 18px;
}
.eng-btn {
  height: 40px;
  padding: 0 12px;
  border-radius: 999px;
  border: 1px solid rgba(148, 163, 184, 0.35);
  background: rgba(2, 6, 23, 0.18);
  color: #e2e8f0;
  display: inline-flex;
  align-items: center;
  gap: 10px;
  cursor: pointer;
  font-weight: 900;
}

/* ===== Related + resources ===== */
.post-bottom {
  padding: 34px 0 70px;
}
.related-grid {
  display: grid;
  gap: 18px;
  margin-top: 16px;
}
@media (min-width: 768px) {
  .related-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}
@media (min-width: 1180px) {
  .related-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}
.resource-list {
  display: grid;
  gap: 12px;
  margin-top: 14px;
}
.resource-item {
  display: flex;
  gap: 12px;
  align-items: flex-start;
  padding: 14px 14px;
  border-radius: 16px;
  border: 1px solid rgba(148, 163, 184, 0.35);
  background: #fff;
}
.resource-item .ri-ic {
  width: 36px;
  height: 36px;
  border-radius: 12px;
  display: grid;
  place-items: center;
  background: rgba(30, 64, 175, 0.08);
  color: #1e40af;
}
.resource-item .ri-title {
  font-weight: 950;
  margin: 0;
}
.resource-item .ri-desc {
  margin: 4px 0 0;
  color: #64748b;
  font-weight: 700;
  font-size: 13px;
  line-height: 1.5;
}

/* ===== Footer surface to keep margins on mobile ===== */
.footer {
  background: transparent;
  padding: 0 16px;
}
@media (min-width: 1024px) {
  .footer {
    padding: 0 24px;
  }
}
.footer-surface {
  background: #020617;
  color: #94a3b8;
  border-radius: 24px;
  overflow: hidden;
  box-shadow: 0 18px 50px rgba(2, 6, 23, 0.18);
}
.footer-inner {
  padding: 56px 0;
}

/* =============================
   Responsive nav drawer (CMS)
   Prevent duplicate menus on desktop
   ============================= */
.nav-toggle {
  display: none;
  background: transparent;
  border: 0;
  cursor: pointer;
  line-height: 0;
}
.nav-drawer {
  display: none;
}

@media (max-width: 900px) {
  .nav-links {
    display: none !important;
  }
  /* Hide top-right actions on mobile to avoid duplication with drawer links */
  .nav-actions {
    display: none !important;
  }
  .nav-toggle {
    display: inline-flex;
    align-items: center;
    justify-content: center;
  }
  .nav-drawer {
    display: none;
    position: absolute;
    left: 0;
    right: 0;
    top: 100%;
    z-index: 50;
  }
  .nav-drawer .drawer-inner {
    background: rgba(2, 6, 23, 0.96);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 16px;
    margin: 10px 16px;
    padding: 14px;
    box-shadow: 0 20px 60px rgba(2, 6, 23, 0.35);
  }
  .nav-drawer .drawer-link {
    display: block;
    padding: 10px 12px;
    border-radius: 12px;
    color: #e2e8f0;
    text-decoration: none;
  }
  .nav-drawer .drawer-link:hover {
    background: rgba(255, 255, 255, 0.08);
  }
  body.nav-open .nav-drawer {
    display: block;
  }
}

/* Mobile safe spacing: prevent the floating hero card from causing horizontal overflow */
@media (max-width: 640px) {
  .hero-floating {
    left: 12px;
    bottom: 12px;
  }
  .hero-media img {
    height: 360px;
  }
}

/* Defensive: avoid accidental horizontal scroll due to off-canvas elements */
html,
body {
  max-width: 100%;
  overflow-x: hidden;
}

@media (min-width: 901px) {
  .nav-drawer {
    display: none !important;
  }
}
/* Gutters responsivos */
:root {
  --gutter-xs: 16px;
  --gutter-sm: 20px;
  --gutter-md: 28px;
  --gutter-lg: 40px;
}

/* El fondo del carrusel SIEMPRE full width */
.hero-inner {
  width: 100%;
  padding-left: 0 !important;
  padding-right: 0 !important;
}

/* El contenido interno con márgenes */
.hero-inner .hero-grid {
  padding-left: var(--gutter-xs);
  padding-right: var(--gutter-xs);
  box-sizing: border-box;
}

/* Móviles grandes */
@media (min-width: 480px) {
  .hero-inner .hero-grid {
    padding-left: var(--gutter-sm);
    padding-right: var(--gutter-sm);
  }
}

/* Tablets */
@media (min-width: 768px) {
  .hero-inner .hero-grid {
    padding-left: var(--gutter-md);
    padding-right: var(--gutter-md);
  }
}

/* Pantallas medianas */
@media (min-width: 1024px) {
  .hero-inner .hero-grid {
    padding-left: var(--gutter-lg);
    padding-right: var(--gutter-lg);
  }
}
/* Fondo del footer full width */
footer {
  width: 100%;
  padding-left: 0 !important;
  padding-right: 0 !important;
  margin: 0;
  box-sizing: border-box;
}

/* Contenido interno del footer */
footer .footer-inner {
  padding-left: var(--gutter-xs);
  padding-right: var(--gutter-xs);
  box-sizing: border-box;
  max-width: 100%;
}

/* Móviles grandes */
@media (min-width: 480px) {
  footer .footer-inner {
    padding-left: var(--gutter-sm);
    padding-right: var(--gutter-sm);
  }
}

/* Tablets */
@media (min-width: 768px) {
  footer .footer-inner {
    padding-left: var(--gutter-md);
    padding-right: var(--gutter-md);
  }
}

/* Pantallas medianas */
@media (min-width: 1024px) {
  footer .footer-inner {
    padding-left: var(--gutter-lg);
    padding-right: var(--gutter-lg);
  }
}

.prose figure {
  margin: 18px auto;
}
.prose figure img {
  max-width: 100%;
  height: auto;
  display: block;
  border-radius: 14px;
}
.prose figcaption {
  font-size: 14px;
  color: #64748b;
  margin-top: 8px;
}

/* Blog tags 'View more' button (distinct color) */
.btn-tags-more {
  background: #6fafc5 !important;
  color: #fff !important;
  border-color: rgba(15, 23, 42, 0.12) !important;
}
.btn-tags-more:hover {
  filter: brightness(0.95);
}
/* === MEJORA PARA IMÁGENES PEQUEÑAS (EFECTO INSTAGRAM) === */
.media-frame {
  --h: 180px; /* Altura por defecto, se puede sobrescribir con inline styles */
  height: var(--h);
  width: 100%;
  background-color: #e2e8f0; /* Color de fondo por si la imagen no carga */
  position: relative; /* Necesario para posicionar el fondo borroso */
  overflow: hidden; /* Asegura que nada se salga del contenedor */
  display: flex;
  align-items: center;
  justify-content: center;
}

/* Fondo borroso */
.media-frame-blur {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  filter: blur(15px) brightness(0.9); /* Ajusta el blur y brillo a tu gusto */
  transform: scale(
    1.1
  ); /* Pequeño zoom para evitar bordes transparentes con el blur */
  opacity: 0.8; /* Un poco de transparencia para que no opaque la imagen principal */
  z-index: 1;
}

/* Imagen principal nítida */
.media-frame-img {
  position: relative;
  max-width: 100%;
  max-height: 100%;
  width: auto;
  height: auto;
  object-fit: contain; /* La imagen se escala para ser VISIBLE COMPLETAMENTE */
  object-position: center;
  display: block;
  z-index: 2;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15); /* Sutil sombra para darle profundidad */
}
/* === MEJORA PARA IMÁGENES DE BLOG (EFECTO INSTAGRAM) === */
.blog-media {
  position: relative;
  height: 210px; /* Mantenemos la altura que ya tenías */
  background: #0f172a;
  overflow: hidden;
  isolation: isolate; /* Crea un nuevo contexto de apilamiento */
}

/* Fondo borroso */
.blog-media-blur {
  position: absolute;
  top: -5px;
  left: -5px;
  right: -5px;
  bottom: -5px;
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  filter: blur(15px) brightness(0.8);
  z-index: 0;
  opacity: 0.9;
}

/* Imagen principal nítida */
.blog-media-img {
  position: relative;
  width: 100%;
  height: 100%;
  object-fit: contain !important; /* Forzamos contain para ver la imagen completa */
  object-position: center;
  display: block;
  z-index: 1;
  padding: 8px; /* Pequeño margen para que no toque los bordes */
  box-sizing: border-box;
}

/* Mantenemos el hover original pero lo adaptamos */
.blog-media:hover .blog-media-img {
  transform: scale(
    1.02
  ); /* Reducimos un poco el zoom del hover para no distorsionar */
  transition: transform 0.35s ease;
}

/* El blog-hover existente debe estar por encima del blur pero debajo del texto */
.blog-hover {
  position: absolute;
  inset: 0;
  background: linear-gradient(
    180deg,
    rgba(2, 6, 23, 0.05),
    rgba(2, 6, 23, 0.55)
  );
  z-index: 2; /* Por encima de la imagen y el blur */
  pointer-events: none; /* Para que no interfiera con clicks */
}

/* El badge debe estar siempre visible por encima de todo */
.blog-media .badge-abs-right {
  z-index: 3;
  position: absolute;
  top: 14px;
  right: 14px;
}
