/* ===========================
   ROOT VARIABLES
=========================== */
:root {
  --accent:             #a8ff3e;
  --accent-dark:        #85d926;
  --accent-glow:        rgba(168, 255, 62, 0.18);
  --accent-glow-strong: rgba(168, 255, 62, 0.35);
  --text-light:         #ffffff;
  --text-muted:         rgba(255, 255, 255, 0.65);
  --text-dim:           rgba(255, 255, 255, 0.4);
  --bg:                 #0a0a0a;
  --bg-card:            rgba(255, 255, 255, 0.04);
  --bg-card-hover:      rgba(255, 255, 255, 0.07);
  --border:             rgba(255, 255, 255, 0.08);
  --border-accent:      rgba(168, 255, 62, 0.25);
  --header-bg:          rgba(10, 10, 10, 0.45);
  --header-border:      rgba(255, 255, 255, 0.1);
  --header-blur:        blur(18px);
  --transition:         0.35s cubic-bezier(0.4, 0, 0.2, 1);
  --font:               'Nunito', sans-serif;
  --font-display:       'Nunito', sans-serif;
  --radius:             20px;
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }

body {
  font-family: var(--font);
  background: var(--bg);
  color: var(--text-light);
  min-height: 100vh;
  font-size: 17px;
  overflow-x: hidden;
}

a { text-decoration: none; color: inherit; }
.accent-text { color: var(--accent); }

.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 24px;
}

/* ===========================
   HEADER
=========================== */
.header {
  position: fixed;
  top: 20px; left: 50%;
  transform: translateX(-50%);
  width: calc(100% - 48px);
  max-width: 1200px;
  z-index: 1000;
  border-radius: 999px;
  background: var(--header-bg);
  border: 1px solid var(--header-border);
  backdrop-filter: var(--header-blur);
  -webkit-backdrop-filter: var(--header-blur);
  transition: background var(--transition), box-shadow var(--transition);
}

.header.scrolled { background: rgba(10,10,10,0.75); box-shadow: 0 8px 40px rgba(0,0,0,0.4); }

.header__inner {
  display: flex; align-items: center;
  justify-content: space-between;
  padding: 4px 24px; gap: 16px; height: 64px;
}

.header__logo { flex-shrink: 0; display: flex; align-items: center; }
.header__logo img { height: 67px; width: auto; object-fit: contain; display: block; }

.header__nav {
  display: flex; align-items: center; gap: 6px;
  position: absolute; left: 50%; transform: translateX(-50%);
}

.nav__link {
  font-family: var(--font-body); font-size: 1rem; font-weight: 600;
  color: var(--text-muted); padding: 7px 16px; border-radius: 999px;
  position: relative; letter-spacing: 0.01em;
  transition: color var(--transition), background var(--transition);
}

.nav__link::before {
  content: ''; position: absolute; inset: 0; border-radius: 999px;
  background: rgba(255,255,255,0.07); opacity: 0; transform: scale(0.88);
  transition: opacity var(--transition), transform var(--transition);
}

.nav__link:hover { color: var(--text-light); }
.nav__link:hover::before { opacity: 1; transform: scale(1); }
.nav__link.active { color: var(--text-light); }
.nav__link.active::before { opacity: 1; transform: scale(1); }

.nav__link::after {
  content: ''; position: absolute; bottom: 4px; left: 50%;
  transform: translateX(-50%) scaleX(0); width: 16px; height: 2px;
  border-radius: 2px; background: var(--accent); transition: transform var(--transition);
}

.nav__link:hover::after, .nav__link.active::after { transform: translateX(-50%) scaleX(1); }

.header__btn {
  flex-shrink: 0; font-family: var(--font-body); font-size: 1rem;
  font-weight: 700; color: #0a0a0a; background: var(--accent);
  padding: 9px 22px; border-radius: 999px; letter-spacing: 0.01em;
  position: relative; overflow: hidden;
  transition: background var(--transition), transform var(--transition), box-shadow var(--transition);
}

.header__btn::before {
  content: ''; position: absolute; top: 0; left: -75%; width: 50%; height: 100%;
  background: linear-gradient(120deg, transparent, rgba(255,255,255,0.35), transparent);
  transform: skewX(-20deg); transition: left 0.55s ease;
}

.header__btn:hover::before { left: 140%; }
.header__btn:hover { background: var(--accent-dark); transform: translateY(-1px); box-shadow: 0 6px 24px rgba(168,255,62,0.35); }
.header__btn:active { transform: translateY(0px); }

.header__hamburger {
  display: none; flex-direction: column; justify-content: center;
  align-items: center; gap: 5px; background: none; border: none;
  cursor: pointer; padding: 6px; border-radius: 8px; flex-shrink: 0;
}

.header__hamburger span {
  display: block; width: 22px; height: 2px; border-radius: 2px;
  background: var(--text-light);
  transition: transform var(--transition), opacity var(--transition), width var(--transition);
  transform-origin: center;
}

.header__hamburger.open span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.header__hamburger.open span:nth-child(2) { opacity: 0; transform: scaleX(0); }
.header__hamburger.open span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

.header__mobile-nav {
  display: none; flex-direction: column; align-items: center; gap: 4px;
  padding: 12px 20px 20px; border-top: 1px solid var(--header-border);
  margin-top: 4px; max-height: 0; overflow: hidden; opacity: 0;
  transition: max-height 0.4s cubic-bezier(0.4,0,0.2,1), opacity 0.35s ease, padding 0.35s ease;
}

.header__mobile-nav.open { max-height: 400px; opacity: 1; }

.mobile-nav__link {
  font-family: var(--font-body); font-size: 1.05rem; font-weight: 600;
  color: var(--text-muted); padding: 10px 20px; border-radius: 999px;
  width: 100%; text-align: center;
  transition: color var(--transition), background var(--transition);
}

.mobile-nav__link:hover { color: var(--text-light); background: rgba(255,255,255,0.07); }
.mobile-btn { margin-top: 8px; display: inline-block; width: auto; min-width: 140px; }

@media (max-width: 768px) {
  .header { top: 12px; width: calc(100% - 24px); border-radius: 20px; }
  .header__nav { display: none; }
  .header__btn:not(.mobile-btn) { display: none; }
  .header__hamburger { display: flex; }
  .header__mobile-nav { display: flex; }
  .header.menu-open { border-radius: 20px; }
}

@media (max-width: 480px) {
  .header__inner { padding: 10px 12px; }
  .header__logo img { height: 60px; }
}


/* ===========================
   BLOG HERO
=========================== */
.blog-hero {
  position: relative;
  min-height: 88vh;
  display: flex;
  align-items: flex-end;
  overflow: hidden;
}
.blog-hero__image-wrap { position: absolute; inset: 0; z-index: 0; }
.blog-hero__image {
  width: 100%; height: 100%;
  object-fit: cover; object-position: center;
  display: block;
  transform: scale(1.04);
  transition: transform 8s ease;
}
.blog-hero:hover .blog-hero__image { transform: scale(1); }
.blog-hero__overlay {
  position: absolute; inset: 0;
  background:
    linear-gradient(to top, rgba(10,10,10,1) 0%, rgba(10,10,10,0.78) 42%, rgba(10,10,10,0.28) 72%, rgba(10,10,10,0.15) 100%),
    linear-gradient(to right, rgba(10,10,10,0.65) 0%, transparent 60%);
}
.blog-hero__content {
  position: relative; z-index: 2;
  padding-bottom: 72px; padding-top: 120px;
  max-width: 800px;
}
.blog-hero__meta-top {
  display: flex; align-items: center;
  gap: 12px; margin-bottom: 24px;
}
.blog-back-btn {
  display: inline-flex; align-items: center; gap: 6px;
  font-size: 0.82rem; font-weight: 700;
  color: var(--text-muted);
  background: rgba(255,255,255,0.08);
  border: 1px solid var(--border);
  padding: 7px 14px; border-radius: 999px;
  letter-spacing: 0.04em; text-transform: uppercase;
  transition: color var(--transition), background var(--transition), border-color var(--transition);
}
.blog-back-btn:hover {
  color: var(--text-light);
  background: rgba(255,255,255,0.12);
  border-color: rgba(255,255,255,0.18);
}
.blog-tag {
  display: inline-flex; align-items: center;
  font-size: 0.78rem; font-weight: 800;
  letter-spacing: 0.1em; text-transform: uppercase;
  color: #0a0a0a; background: var(--accent);
  padding: 6px 14px; border-radius: 999px;
}
.blog-hero__title {
  font-family: var(--font-display);
  font-size: clamp(2.4rem, 5.5vw, 4.2rem);
  font-weight: 800; line-height: 1.1;
  letter-spacing: -0.025em;
  color: var(--text-light); margin-bottom: 24px;
}
.blog-hero__info { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.blog-hero__info-item {
  display: inline-flex; align-items: center; gap: 6px;
  font-size: 0.875rem; font-weight: 600; color: var(--text-muted);
}
.blog-hero__info-item svg { opacity: 0.65; flex-shrink: 0; }
.blog-hero__dot { color: var(--text-dim); font-size: 1.1rem; }

/* ===========================
   BLOG MAIN LAYOUT
=========================== */
.blog-main { padding: 72px 0 80px; }

.blog-layout {
  display: grid;
  grid-template-columns: 1fr 300px;
  gap: 56px;
  /* CRITICAL: align-items start means sidebar is only
     as tall as its content, not stretched to article height */
  align-items: start;
}

/* ===========================
   ARTICLE
=========================== */
.blog-article {
  opacity: 0;
  transform: translateY(24px);
  animation: fadeUp 0.65s ease forwards;
  animation-delay: 0.1s;
}
@keyframes fadeUp { to { opacity: 1; transform: translateY(0); } }

.blog-article__lead {
  font-size: 1.2rem; font-weight: 600;
  color: var(--text-muted); line-height: 1.85;
  border-left: 3px solid var(--accent);
  padding-left: 24px; margin-bottom: 40px;
  font-style: italic;
}
.blog-intro-section { margin-bottom: 48px; }
.blog-intro-section p {
  font-size: 1rem; line-height: 1.9;
  color: var(--text-muted); margin-bottom: 16px; font-weight: 500;
}
.blog-intro-section p:last-child { margin-bottom: 0; }

.blog-section { margin-bottom: 48px; position: relative; }
.blog-section__number {
  font-size: 5.5rem; font-weight: 900;
  font-family: var(--font-display);
  color: rgba(168, 255, 62, 0.06);
  line-height: 1; margin-bottom: -24px;
  letter-spacing: -0.05em;
  user-select: none; pointer-events: none;
}
.blog-section__title {
  font-family: var(--font-display);
  font-size: clamp(1.4rem, 2.4vw, 1.9rem);
  font-weight: 800; color: var(--text-light);
  line-height: 1.25; margin-bottom: 20px;
  letter-spacing: -0.015em;
}
.blog-section p, .blog-conclusion p {
  font-size: 1rem; line-height: 1.9;
  color: var(--text-muted); margin-bottom: 16px; font-weight: 500;
}
.blog-section p:last-child, .blog-conclusion p:last-child { margin-bottom: 0; }
.blog-section strong, .blog-intro-section strong { color: var(--text-light); font-weight: 700; }
.blog-conclusion { margin-bottom: 48px; }

.blog-divider {
  height: 1px;
  background: linear-gradient(to right, var(--accent-glow), var(--border), transparent);
  margin: 48px 0; border: none;
}

.blog-highlight-card {
  display: flex; align-items: flex-start; gap: 16px;
  background: var(--bg-card);
  border: 1px solid var(--border-accent);
  border-radius: 16px; padding: 20px 24px; margin-top: 24px;
  position: relative; overflow: hidden;
  transition: background var(--transition), border-color var(--transition);
}
.blog-highlight-card::before {
  content: '';
  position: absolute; top: 0; left: 0;
  width: 3px; height: 100%;
  background: var(--accent); border-radius: 3px 0 0 3px;
}
.blog-highlight-card:hover { background: var(--bg-card-hover); border-color: rgba(168,255,62,0.4); }
.blog-highlight-card__icon {
  flex-shrink: 0; width: 44px; height: 44px;
  border-radius: 10px; background: var(--accent-glow);
  border: 1px solid var(--border-accent);
  display: flex; align-items: center; justify-content: center;
  color: var(--accent);
}
.blog-highlight-card p {
  font-size: 0.975rem; line-height: 1.7;
  color: var(--text-muted); font-weight: 500; margin: 0 !important;
}
.blog-highlight-card p strong { color: var(--accent); }

.blog-stat-row {
  display: grid; grid-template-columns: repeat(3,1fr);
  gap: 16px; margin-top: 32px;
}
.blog-stat {
  background: var(--bg-card); border: 1px solid var(--border);
  border-radius: 16px; padding: 24px 16px; text-align: center;
  transition: border-color var(--transition), background var(--transition), transform var(--transition);
  cursor: default;
}
.blog-stat:hover { border-color: var(--border-accent); background: var(--bg-card-hover); transform: translateY(-3px); }
.blog-stat__num {
  display: block;
  font-family: var(--font-display);
  font-size: 2rem; font-weight: 800;
  color: var(--accent); line-height: 1;
  margin-bottom: 8px; letter-spacing: -0.03em;
}
.blog-stat__label {
  display: block; font-size: 0.78rem; font-weight: 600;
  color: var(--text-dim); line-height: 1.45; letter-spacing: 0.01em;
}

.blog-cta-box {
  position: relative;
  background: linear-gradient(135deg, rgba(168,255,62,0.08) 0%, rgba(168,255,62,0.03) 100%);
  border: 1px solid var(--border-accent);
  border-radius: 24px; padding: 48px 40px;
  text-align: center; margin-top: 56px; overflow: hidden;
}
.blog-cta-box__glow {
  position: absolute; top: -60px; left: 50%;
  transform: translateX(-50%); width: 300px; height: 200px;
  background: radial-gradient(ellipse, rgba(168,255,62,0.18) 0%, transparent 70%);
  pointer-events: none;
}
.blog-cta-box__eyebrow {
  font-size: 0.78rem; font-weight: 800;
  letter-spacing: 0.14em; text-transform: uppercase;
  color: var(--accent); margin-bottom: 12px;
}
.blog-cta-box__title {
  font-family: var(--font-display);
  font-size: clamp(1.4rem, 2vw, 1.9rem);
  font-weight: 800; color: var(--text-light);
  margin-bottom: 16px; line-height: 1.25; letter-spacing: -0.015em;
}
.blog-cta-box__text {
  font-size: 0.975rem; line-height: 1.75;
  color: var(--text-muted); max-width: 480px;
  margin: 0 auto 28px; font-weight: 500;
}
.blog-cta-box__btn {
  display: inline-flex; align-items: center;
  font-size: 0.95rem; font-weight: 700;
  color: #0a0a0a; background: var(--accent);
  padding: 12px 28px; border-radius: 999px;
  position: relative; overflow: hidden;
  transition: background var(--transition), transform var(--transition), box-shadow var(--transition);
}
.blog-cta-box__btn:hover { background: var(--accent-dark); transform: translateY(-2px); box-shadow: 0 8px 32px rgba(168,255,62,0.35); }

.blog-back-row { margin-top: 40px; display: flex; align-items: center; }
.blog-back-link {
  display: inline-flex; align-items: center; gap: 6px;
  font-size: 0.875rem; font-weight: 700;
  color: var(--text-muted); background: var(--bg-card);
  border: 1px solid var(--border);
  padding: 9px 18px; border-radius: 999px;
  letter-spacing: 0.04em; text-transform: uppercase;
  transition: color var(--transition), background var(--transition), border-color var(--transition);
}
.blog-back-link:hover { color: var(--text-light); background: var(--bg-card-hover); border-color: rgba(255,255,255,0.14); }

/* ===========================
   SIDEBAR
   ─────────────────────────
   THE FIX:
   • .blog-sidebar has align-self:start — it is only as
     tall as its own stacked cards. No stretching to match
     the article column.
   • position:sticky is on .blog-sidebar itself, NOT on
     any child card. This is the only correct pattern.
   • No child card has position:sticky, position:fixed,
     or any positioning at all — they are plain flow blocks
     stacked with gap. Zero overlap possible.
=========================== */
.blog-sidebar {
  /* Stick the whole sidebar column as one unit */
  position: sticky;
  top: 104px;          /* header ~64px + 20px gap + 20px breathing */
  align-self: start;   /* don't stretch to article height */
  display: flex;
  flex-direction: column;
  gap: 20px;
  opacity: 0;
  animation: fadeUp 0.65s ease forwards;
  animation-delay: 0.25s;
}

/* Plain cards — NO position property at all */
.sidebar-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 18px;
  padding: 24px;
  transition: border-color var(--transition);
  /* ensure no overflow:hidden or transform that could
     interfere with the parent sticky */
}
.sidebar-card:hover { border-color: rgba(255,255,255,0.12); }

.sidebar-card__title {
  font-size: 0.72rem; font-weight: 800;
  letter-spacing: 0.12em; text-transform: uppercase;
  color: var(--text-dim); margin-bottom: 18px;
}

.sidebar-toc { display: flex; flex-direction: column; gap: 4px; }
.toc-link {
  display: flex; align-items: center; gap: 10px;
  font-size: 0.875rem; font-weight: 600;
  color: var(--text-muted);
  padding: 8px 10px; border-radius: 10px;
  transition: color var(--transition), background var(--transition);
  position: relative;
}
.toc-link::before {
  content: '';
  position: absolute; left: 0; top: 50%;
  transform: translateY(-50%);
  width: 2px; height: 0;
  background: var(--accent); border-radius: 2px;
  transition: height var(--transition);
}
.toc-link:hover, .toc-link.active { color: var(--text-light); background: rgba(255,255,255,0.05); }
.toc-link.active::before { height: 70%; }
.toc-num { font-size: 0.7rem; font-weight: 800; color: var(--accent); min-width: 22px; opacity: 0.8; }

.sidebar-meta-list { display: flex; flex-direction: column; gap: 14px; }
.sidebar-meta-item { display: flex; justify-content: space-between; align-items: center; font-size: 0.875rem; }
.sidebar-meta-label { color: var(--text-dim); font-weight: 600; }
.sidebar-meta-value { color: var(--text-muted); font-weight: 700; }

.sidebar-cta-card {
  background: linear-gradient(135deg, rgba(168,255,62,0.08), rgba(168,255,62,0.03));
  border-color: var(--border-accent);
}
.sidebar-cta__eyebrow {
  font-size: 0.72rem; font-weight: 800;
  letter-spacing: 0.1em; text-transform: uppercase;
  color: var(--accent); margin-bottom: 10px;
}
.sidebar-cta__text {
  font-size: 0.875rem; line-height: 1.7;
  color: var(--text-muted); font-weight: 500; margin-bottom: 18px;
}
.sidebar-cta__btn {
  display: block; text-align: center;
  font-size: 0.875rem; font-weight: 700;
  color: #0a0a0a; background: var(--accent);
  padding: 10px 20px; border-radius: 999px;
  transition: background var(--transition), transform var(--transition), box-shadow var(--transition);
}
.sidebar-cta__btn:hover { background: var(--accent-dark); transform: translateY(-1px); box-shadow: 0 4px 20px rgba(168,255,62,0.3); }

/* ===========================
   FOOTER SECTION
=========================== */
.footer {
  background: #080808;
  border-top: 1px solid rgba(255, 255, 255, 0.07);
  width: 100%;
}

.footer__inner {
  max-width: 1300px;
  margin: 0 auto;
  padding: 80px 60px 60px;
  display: grid;
  grid-template-columns: 1.6fr 1fr 1fr;
  gap: 60px;
  align-items: start;
}

.footer__brand {
  display: flex;
  flex-direction: column;
  gap: 24px;
}

.footer__logo {
  display: inline-block;
  flex-shrink: 0;
  line-height: 0;
}

.footer__logo img {
  height: 120px;
  width: auto;
  object-fit: contain;
  display: block;
  transition: opacity var(--transition);
}

.footer__logo:hover img { opacity: 0.85; }

.footer__tagline {
  font-family: var(--font-body);
  font-size: 1.05rem;
  color: var(--text-muted);
  line-height: 1.85;
  max-width: 360px;
}

.footer__col {
  display: flex;
  flex-direction: column;
  gap: 24px;
  padding-top: 8px;
}

.footer__col-title {
  font-family: var(--font-heading);
  font-size: 1.15rem;
  font-weight: 800;
  color: var(--text-light);
  letter-spacing: 0.02em;
  position: relative;
  padding-bottom: 14px;
}

.footer__col-title::after {
  content: '';
  position: absolute;
  bottom: 0; left: 0;
  width: 28px; height: 2px;
  border-radius: 2px;
  background: var(--accent);
}

.footer__links {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.footer__link {
  font-family: var(--font-body);
  font-size: 1rem;
  font-weight: 600;
  color: var(--text-muted);
  padding: 7px 16px;
  border-radius: 999px;
  position: relative;
  letter-spacing: 0.01em;
  display: inline-block;
  margin-left: -16px;
  transition: color var(--transition), background var(--transition);
}

.footer__link::before {
  content: '';
  position: absolute;
  inset: 0;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.07);
  opacity: 0;
  transform: scale(0.88);
  transition: opacity var(--transition), transform var(--transition);
}

.footer__link:hover { color: var(--text-light); }
.footer__link:hover::before { opacity: 1; transform: scale(1); }

.footer__link::after {
  content: '';
  position: absolute;
  bottom: 4px; left: 50%;
  transform: translateX(-50%) scaleX(0);
  width: 16px; height: 2px;
  border-radius: 2px;
  background: var(--accent);
  transition: transform var(--transition);
}

.footer__link:hover::after { transform: translateX(-50%) scaleX(1); }

.footer__bottom {
  border-top: 1px solid rgba(255, 255, 255, 0.07);
  padding: 24px 60px;
  max-width: 100%;
}

.footer__copy {
  max-width: 1300px;
  margin: 0 auto;
  font-family: var(--font-body);
  font-size: 0.9rem;
  color: rgba(255, 255, 255, 0.3);
  letter-spacing: 0.02em;
}

@media (max-width: 1024px) {
  .footer__inner { padding: 70px 40px 50px; gap: 48px; }
  .footer__bottom { padding: 22px 40px; }
}

@media (max-width: 768px) {
  .footer__inner { grid-template-columns: 1fr 1fr; padding: 60px 24px 48px; gap: 48px 32px; }
  .footer__brand { grid-column: 1 / -1; }
  .footer__logo img { height: 90px; }
  .footer__tagline { font-size: 1rem; max-width: 100%; }
  .footer__bottom { padding: 20px 24px; }
}

@media (max-width: 480px) {
  .footer__inner { grid-template-columns: 1fr; padding: 48px 20px 40px; gap: 40px; }
  .footer__logo img { height: 67px; }
  .footer__col-title { font-size: 1.05rem; }
  .footer__link { font-size: 0.95rem; }
  .footer__tagline { font-size: 0.95rem; }
  .footer__bottom { padding: 18px 20px; }
  .footer__copy { font-size: 0.82rem; }
}