/*!
 * Azad Innovation Fund — Homepage Design System
 * Light theme, RTL (Persian). Editorial, precise, restrained.
 * Fonts: Vazirmatn (body) · Syne (display) — loaded via <link> in <head>.
 */

/* ============================================================
   1. CUSTOM PROPERTIES
   ============================================================ */
:root {
  /* Color */
  --bg: #FAFBFC;
  --surface: #FFFFFF;
  --surface-alpha: rgba(255, 255, 255, 0.72);
  --surface-alpha-strong: rgba(255, 255, 255, 0.86);
  --ink: #0F1419;
  --ink-soft: #3D4654;
  --mute: #6B7280;
  --line: #E6E9EF;
  --line-strong: #D7DCE5;
  --blue: #0B4FFF;
  --blue-dark: #0A44DB;
  --blue-soft: #E8EEFF;
  --blue-mist: rgba(11, 79, 255, 0.08);
  --green: #0F9F6E;
  --green-dark: #0B7F57;
  --green-soft: #E6F7F0;
  --shadow-green: 0 16px 36px -14px rgba(15, 159, 110, 0.42);

  /* Radius */
  --radius-sm: 12px;
  --radius: 20px;
  --radius-lg: 28px;
  --radius-full: 999px;

  /* Shadow — soft, glass-like, never heavy */
  --shadow-xs: 0 1px 2px rgba(15, 20, 25, 0.045);
  --shadow-sm: 0 6px 16px -8px rgba(15, 20, 25, 0.08);
  --shadow: 0 16px 40px -12px rgba(15, 20, 25, 0.10), 0 2px 10px -4px rgba(15, 20, 25, 0.05);
  --shadow-lg: 0 32px 72px -20px rgba(15, 20, 25, 0.14), 0 8px 24px -8px rgba(15, 20, 25, 0.06);
  --shadow-blue: 0 18px 40px -14px rgba(11, 79, 255, 0.32);
  --shadow-glass-inset: inset 0 1px 0 rgba(255, 255, 255, 0.6);

  /* Type */
  --font-body: "Vazirmatn", "Segoe UI", Tahoma, sans-serif;
  --font-display: "Syne", "Vazirmatn", sans-serif;

  /* Motion */
  --ease: cubic-bezier(0.16, 1, 0.3, 1);
  --ease-spring: cubic-bezier(0.34, 1.56, 0.64, 1);
  --dur-1: 160ms;
  --dur-2: 320ms;
  --dur-3: 640ms;

  /* Layout */
  --container: 1200px;
  --gutter: clamp(20px, 5vw, 48px);
  --section-py: 120px;
  --section-py-sm: 72px;

  color-scheme: light only;
}

/* ============================================================
   2. RESET & BASE
   ============================================================ */
*,
*::before,
*::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  direction: rtl;
  scroll-behavior: smooth;
  text-size-adjust: 100%;
  -webkit-text-size-adjust: 100%;
}

body {
  min-height: 100dvh;
  background: var(--bg);
  color: var(--ink-soft);
  font-family: var(--font-body);
  font-size: 1rem;
  line-height: 1.75;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;
}

img,
picture,
video,
svg,
canvas {
  display: block;
  max-width: 100%;
  height: auto;
}

a {
  color: inherit;
  text-decoration: none;
}

button,
input,
textarea,
select {
  font: inherit;
  color: inherit;
  background: none;
  border: none;
}

button {
  cursor: pointer;
}

ul,
ol {
  list-style: none;
}

hr {
  border: none;
  border-top: 1px solid var(--line);
}

::selection {
  background: var(--blue-soft);
  color: var(--blue-dark);
}

/* ============================================================
   3. TYPOGRAPHY
   ============================================================ */
h1,
h2,
h3,
h4,
h5 {
  font-family: var(--font-display);
  color: var(--ink);
  font-weight: 700;
  line-height: 1.12;
  letter-spacing: -0.02em;
}

h1 {
  font-size: clamp(2.75rem, 3.2rem + 3vw, 5.5rem);
}

h2 {
  font-size: clamp(2.1rem, 1.9rem + 2vw, 3.4rem);
}

h3 {
  font-size: clamp(1.4rem, 1.2rem + 1vw, 2rem);
}

h4 {
  font-size: clamp(1.1rem, 1rem + 0.5vw, 1.35rem);
}

p {
  margin-block-end: 1em;
}

.lede {
  font-size: clamp(1.1rem, 1rem + 0.6vw, 1.4rem);
  color: var(--ink-soft);
  line-height: 1.65;
  max-width: 42ch;
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 0.55rem;
  font-size: 0.8rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--blue);
}

.eyebrow::before {
  content: "";
  inline-size: 6px;
  block-size: 6px;
  border-radius: 50%;
  background: var(--blue);
  box-shadow: 0 0 0 4px var(--blue-soft);
}

.mute {
  color: var(--mute);
}

.tnum {
  font-variant-numeric: tabular-nums;
}

/* ============================================================
   4. LAYOUT
   ============================================================ */
.wrap {
  width: 100%;
  max-width: var(--container);
  margin-inline: auto;
  padding-inline: var(--gutter);
}

.section {
  padding-block: var(--section-py);
}

.section-sm {
  padding-block: calc(var(--section-py) * 0.55);
}

.section-head {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  justify-content: space-between;
  gap: 1.5rem;
  margin-block-end: 3.5rem;
}

@media (max-width: 768px) {
  .section {
    padding-block: var(--section-py-sm);
  }

  .section-sm {
    padding-block: calc(var(--section-py-sm) * 0.65);
  }

  .section-head {
    margin-block-end: 2.25rem;
  }
}

/* ============================================================
   5. SCROLL PROGRESS + MOUSE GLOW
   ============================================================ */
.scroll-progress {
  position: fixed;
  inset-inline: 0;
  top: 0;
  height: 3px;
  z-index: 999;
  background: transparent;
  pointer-events: none;
}

.scroll-progress__bar {
  height: 100%;
  width: var(--progress, 0%);
  background: linear-gradient(90deg, var(--blue), #5C87FF);
  transition: width 0.12s linear;
}

.glow-follow {
  position: fixed;
  top: 0;
  left: 0;
  width: 480px;
  height: 480px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(11, 79, 255, 0.10), transparent 70%);
  transform: translate3d(calc(var(--x, 50vw) - 240px), calc(var(--y, 50vh) - 240px), 0);
  filter: blur(24px);
  pointer-events: none;
  opacity: 0;
  z-index: 1;
  transition: opacity 0.4s var(--ease);
}

.glow-follow.is-active {
  opacity: 1;
}

/* ============================================================
   6. REVEAL / MICRO-INTERACTIONS
   ============================================================ */
.reveal {
  opacity: 0;
  transform: translateY(28px);
  transition: opacity 0.8s var(--ease), transform 0.8s var(--ease);
}

.reveal.is-in {
  opacity: 1;
  transform: none;
}

.reveal-delay-1 { transition-delay: 0.08s; }
.reveal-delay-2 { transition-delay: 0.16s; }
.reveal-delay-3 { transition-delay: 0.24s; }
.reveal-delay-4 { transition-delay: 0.32s; }

/* ============================================================
   7. NAVIGATION
   ============================================================ */
.nav {
  position: sticky;
  top: 0;
  z-index: 400;
  /* No backdrop-filter: it traps position:fixed children inside the header */
  background: rgba(250, 251, 252, 0.94);
  border-bottom: 1px solid transparent;
  transition: background var(--dur-2) var(--ease), border-color var(--dur-2) var(--ease), box-shadow var(--dur-2) var(--ease);
}

.nav.is-scrolled {
  background: rgba(255, 255, 255, 0.98);
  border-color: var(--line);
  box-shadow: var(--shadow-sm);
}

.nav-inner {
  max-width: var(--container);
  margin-inline: auto;
  padding-inline: var(--gutter);
  height: 84px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.25rem;
}

.nav-logo {
  display: flex;
  align-items: center;
  gap: 0.7rem;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 1.15rem;
  color: var(--ink);
  position: relative;
  z-index: 2;
}

.nav-logo img {
  inline-size: 40px;
  block-size: 40px;
  border-radius: 11px;
  transition: transform 0.35s cubic-bezier(0.22, 1, 0.36, 1);
}

.nav-logo:hover img {
  transform: scale(1.06) rotate(-3deg);
}

.nav-logo__text span {
  color: var(--blue);
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 0.15rem;
  padding: 0.32rem;
  border-radius: 999px;
  background:
    linear-gradient(#fff, #fff) padding-box,
    linear-gradient(135deg, rgba(11, 79, 255, 0.18), rgba(15, 159, 110, 0.12), rgba(11, 79, 255, 0.08)) border-box;
  border: 1px solid transparent;
  box-shadow:
    0 10px 32px -24px rgba(10, 22, 40, 0.45),
    inset 0 1px 0 rgba(255, 255, 255, 0.9);
}

.nav-link {
  position: relative;
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.52rem 0.78rem;
  border-radius: 999px;
  font-size: 0.84rem;
  font-weight: 600;
  line-height: 1;
  color: var(--ink-soft);
  white-space: nowrap;
  flex-shrink: 0;
  overflow: hidden;
  isolation: isolate;
  transition: color 0.25s var(--ease), background-color 0.25s var(--ease), transform 0.28s var(--ease-spring), box-shadow 0.25s ease;
}

.nav-link__label {
  white-space: nowrap;
  display: inline-block;
}

.nav-link__ico {
  display: grid;
  place-items: center;
  width: 17px;
  height: 17px;
  flex-shrink: 0;
}

.nav-link__ico svg {
  width: 17px;
  height: 17px;
  transition: transform 0.35s var(--ease-spring);
}

.nav-link::before {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
  background: linear-gradient(135deg, rgba(11, 79, 255, 0.12), rgba(15, 159, 110, 0.06));
  opacity: 0;
  transform: scale(0.88);
  transition: opacity 0.28s ease, transform 0.35s var(--ease);
  z-index: -1;
}

.nav-link:hover {
  color: var(--blue);
  transform: translateY(-2px);
}

.nav-link:hover::before {
  opacity: 1;
  transform: scale(1);
}

.nav-link:hover .nav-link__ico svg {
  transform: translateY(-1px) scale(1.14) rotate(-4deg);
}

.nav-link.is-active {
  color: #fff;
  background: linear-gradient(135deg, #0b4fff 0%, #2f67ff 55%, #0f9f6e 160%);
  box-shadow: 0 12px 24px -12px rgba(11, 79, 255, 0.75);
}

.nav-link.is-active::before {
  opacity: 0;
}

.nav-link.is-active .nav-link__ico svg {
  transform: none;
}

.nav-cta {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  white-space: nowrap;
}

.nav-cta svg {
  width: 16px;
  height: 16px;
}

.nav-cta--primary,
.nav-cta--go {
  position: relative;
  overflow: hidden;
}

.nav-cta--go {
  background: linear-gradient(135deg, var(--green), #12b981) !important;
  color: #fff !important;
  border: none !important;
  box-shadow: var(--shadow-green);
}

.nav-cta--go:hover {
  background: linear-gradient(135deg, var(--green-dark), var(--green)) !important;
  filter: brightness(1.03);
  transform: translateY(-1px);
}

.nav-cta--go::after,
.nav-cta--primary::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(120deg, transparent 30%, rgba(255,255,255,0.3) 50%, transparent 70%);
  transform: translateX(-120%);
  transition: transform 0.55s ease;
}

.nav-cta--go:hover::after,
.nav-cta--primary:hover::after {
  transform: translateX(120%);
}

.nav-actions {
  display: flex;
  align-items: center;
  gap: 0.6rem;
}

.nav-toggle {
  display: none;
  position: relative;
  inline-size: 44px;
  block-size: 44px;
  align-items: center;
  justify-content: center;
  border-radius: 14px;
  border: 1px solid var(--line);
  background: #fff;
  cursor: pointer;
  z-index: 460;
  padding: 0;
  touch-action: manipulation;
  -webkit-tap-highlight-color: transparent;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.nav-toggle:hover {
  transform: scale(1.04);
  box-shadow: 0 8px 18px -14px rgba(11, 79, 255, 0.55);
}

.nav-toggle span {
  position: absolute;
  width: 18px;
  height: 1.5px;
  border-radius: 99px;
  background: var(--ink);
  transition: transform 0.28s cubic-bezier(0.34, 1.4, 0.64, 1), opacity 0.2s ease, top 0.2s ease;
}

.nav-toggle span:nth-child(1) { top: 15px; }
.nav-toggle span:nth-child(2) { top: 21px; }
.nav-toggle span:nth-child(3) { top: 27px; }

.nav-toggle.is-open span:nth-child(1) {
  top: 21px;
  transform: rotate(45deg);
}

.nav-toggle.is-open span:nth-child(2) {
  opacity: 0;
  transform: scaleX(0);
}

.nav-toggle.is-open span:nth-child(3) {
  top: 21px;
  transform: rotate(-45deg);
}

@media (max-width: 1180px) and (min-width: 901px) {
  .nav-link {
    padding: 0.55rem 0.62rem;
  }
  .nav-link__label {
    font-size: 0;
    width: 0;
    overflow: hidden;
  }
  .nav-actions__desk.nav-cta:not(.nav-cta--go) {
    display: none;
  }
}

/* Mobile drawer lives outside .nav (body-level) */
.nav-drawer {
  display: none;
}

.nav-backdrop {
  display: none;
}

@media (max-width: 900px) {
  .nav-actions__desk {
    display: none;
  }

  .nav-toggle {
    display: inline-flex;
  }

  .nav-links--desk {
    display: none !important;
  }

  .nav-backdrop {
    display: block;
    position: fixed;
    inset: 0;
    z-index: 1200;
    margin: 0;
    background: rgba(10, 22, 40, 0.42);
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    transition: opacity 0.25s ease, visibility 0.25s;
  }

  .nav-backdrop.is-open,
  .nav-backdrop.is-open[hidden] {
    display: block !important;
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
  }

  .nav-drawer {
    display: flex;
    position: fixed;
    top: 0;
    bottom: 0;
    right: 0;
    left: auto;
    width: min(320px, 88vw);
    z-index: 1210;
    flex-direction: column;
    align-items: stretch;
    gap: 0.2rem;
    padding: 1rem 1.1rem 1.5rem;
    margin: 0;
    background: #fff;
    border-left: 1px solid var(--line);
    box-shadow: -18px 0 48px -24px rgba(10, 22, 40, 0.35);
    transform: translateX(105%);
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    transition: transform 0.34s cubic-bezier(0.22, 1, 0.36, 1), opacity 0.25s ease, visibility 0.25s;
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
  }

  [dir="rtl"] .nav-drawer {
    right: auto;
    left: 0;
    border-left: none;
    border-right: 1px solid var(--line);
    box-shadow: 18px 0 48px -24px rgba(10, 22, 40, 0.35);
    transform: translateX(-105%);
  }

  .nav-drawer.is-open,
  .nav-drawer.is-open[hidden] {
    display: flex !important;
    transform: translateX(0) !important;
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
  }

  .nav-drawer__head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.75rem;
    padding: 0.35rem 0.25rem 0.9rem;
    margin-bottom: 0.35rem;
    border-bottom: 1px solid var(--line);
  }

  .nav-drawer__head strong {
    font-size: 0.95rem;
    color: var(--ink);
  }

  .nav-drawer__close {
    display: inline-flex;
    position: relative;
    width: 40px;
    height: 40px;
    border: 1px solid var(--line);
    border-radius: 10px;
    background: #fff;
    cursor: pointer;
  }

  .nav-drawer__close span {
    position: absolute;
    inset-inline-start: 11px;
    top: 19px;
    width: 16px;
    height: 1.5px;
    background: var(--ink);
    border-radius: 99px;
  }

  .nav-drawer__close span:first-child { transform: rotate(45deg); }
  .nav-drawer__close span:last-child { transform: rotate(-45deg); }

  .nav-drawer .nav-link {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.95rem 1rem;
    border-radius: 14px;
    font-size: 1rem;
    background: transparent;
    color: var(--ink);
    box-shadow: none;
  }

  .nav-drawer .nav-link.is-active,
  .nav-drawer .nav-link:hover {
    background: var(--blue-soft);
    color: var(--blue);
    transform: none;
  }

  .nav-drawer .nav-link__ico {
    width: 22px;
    height: 22px;
    color: var(--blue);
  }

  .nav-drawer .nav-link__ico svg {
    width: 22px;
    height: 22px;
  }

  .nav-drawer__cta {
    display: grid;
    gap: 0.5rem;
    margin-top: auto;
    padding-top: 1.25rem;
  }

  .nav-drawer__cta .btn {
    justify-content: center;
    width: 100%;
  }

  body.nav-open {
    overflow: hidden;
  }
}

/* ============================================================
   8. HERO
   ============================================================ */
.hero {
  position: relative;
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  isolation: isolate;
  padding-block: 140px 80px;
}

/* one subtle mesh — the only gradient wash permitted */
.hero::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 0;
  background:
    radial-gradient(circle at 18% 15%, rgba(11, 79, 255, 0.07), transparent 42%),
    radial-gradient(circle at 85% 12%, rgba(11, 79, 255, 0.05), transparent 38%),
    radial-gradient(circle at 50% 100%, rgba(11, 79, 255, 0.045), transparent 55%);
}

.hero-particles {
  position: absolute;
  inset: 0;
  z-index: 0;
  width: 100%;
  height: 100%;
  opacity: 0.65;
}

.hero-shapes {
  position: absolute;
  inset: 0;
  z-index: 1;
  pointer-events: none;
  overflow: hidden;
}

.shape {
  position: absolute;
  animation: float 9s ease-in-out infinite;
}

.shape-circle {
  border-radius: 50%;
  border: 1.5px solid rgba(11, 79, 255, 0.18);
}

.shape-circle.is-filled {
  background: var(--blue-soft);
  border: none;
}

.shape-square {
  border-radius: var(--radius-sm);
  border: 1.5px solid rgba(15, 20, 25, 0.08);
  transform: rotate(12deg);
}

.shape-ring {
  border-radius: 50%;
  border: 1.5px solid rgba(11, 79, 255, 0.14);
}

.shape-1 { inset-inline-start: 8%;  top: 18%; width: 120px;  height: 120px;  animation-delay: 0s; }
.shape-2 { inset-inline-end: 12%;   top: 12%; width: 64px;   height: 64px;   animation-delay: 1.2s; }
.shape-3 { inset-inline-end: 6%;    top: 55%; width: 160px;  height: 160px;  animation-delay: 2.4s; }
.shape-4 { inset-inline-start: 14%; top: 68%; width: 44px;   height: 44px;   animation-delay: 0.6s; }
.shape-5 { inset-inline-start: 46%; top: 8%;  width: 28px;   height: 28px;   animation-delay: 1.8s; }

@keyframes float {
  0%, 100% { transform: translateY(0) rotate(0deg); }
  50%      { transform: translateY(-22px) rotate(8deg); }
}

.hero-content {
  position: relative;
  z-index: 2;
  max-width: 860px;
  margin-inline: auto;
  text-align: center;
  padding-inline: var(--gutter);
}

.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.5rem 1rem;
  border: 1px solid var(--line);
  border-radius: var(--radius-full);
  background: var(--surface-alpha);
  backdrop-filter: blur(10px);
  font-size: 0.82rem;
  color: var(--ink-soft);
  margin-block-end: 2rem;
}

.hero-badge .dot {
  inline-size: 7px;
  block-size: 7px;
  border-radius: 50%;
  background: var(--blue);
  box-shadow: 0 0 0 4px var(--blue-soft);
}

.hero-title {
  font-family: var(--font-display);
  font-weight: 800;
  font-size: clamp(3rem, 2.4rem + 5vw, 7rem);
  line-height: 1.04;
  letter-spacing: -0.03em;
  color: var(--ink);
}

.hero-title .accent {
  color: var(--blue);
}

.hero-subtitle {
  margin: 1.75rem auto 0;
  font-size: clamp(1.05rem, 1rem + 0.6vw, 1.35rem);
  color: var(--ink-soft);
  max-width: 46ch;
  line-height: 1.65;
}

.hero-actions {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.85rem;
  flex-wrap: wrap;
  margin-block-start: 2.75rem;
}

.hero-scroll-cue {
  position: absolute;
  bottom: 36px;
  inset-inline: 0;
  z-index: 2;
  display: flex;
  justify-content: center;
  color: var(--mute);
  font-size: 0.78rem;
  letter-spacing: 0.06em;
}

@media (max-width: 640px) {
  .hero {
    min-height: 92vh;
    padding-block: 120px 64px;
  }

  .shape-2, .shape-5 { display: none; }
}

/* ============================================================
   9. BUTTONS (magnetic-ready)
   ============================================================ */
.btn {
  --mx: 0px;
  --my: 0px;
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.55rem;
  padding: 1rem 2.1rem;
  border-radius: var(--radius-full);
  font-weight: 600;
  font-size: 0.95rem;
  white-space: nowrap;
  border: 1px solid transparent;
  transform: translate(var(--mx), var(--my));
  will-change: transform;
  transition:
    transform var(--dur-2) var(--ease-spring),
    box-shadow var(--dur-2) var(--ease),
    background-color var(--dur-2) var(--ease),
    border-color var(--dur-2) var(--ease),
    color var(--dur-2) var(--ease);
}

.btn svg {
  inline-size: 18px;
  block-size: 18px;
  flex-shrink: 0;
}

.btn-primary {
  background: var(--blue);
  color: #fff;
  box-shadow: var(--shadow-blue);
}

.btn-primary:hover {
  transform: translate(var(--mx), var(--my)) translateY(-2px);
  background: var(--blue-dark);
  box-shadow: 0 22px 48px -14px rgba(11, 79, 255, 0.4);
}

.btn-primary:active {
  transform: translate(var(--mx), var(--my)) translateY(0) scale(0.98);
}

.btn-ghost {
  background: var(--surface);
  color: var(--ink);
  border-color: var(--line);
}

.btn-ghost:hover {
  transform: translate(var(--mx), var(--my)) translateY(-2px);
  border-color: var(--blue);
  color: var(--blue);
  background: var(--blue-soft);
}

.btn-text {
  padding: 0.4rem 0;
  border-radius: 4px;
  color: var(--blue);
  font-weight: 600;
  gap: 0.4rem;
}

.btn-text:hover {
  gap: 0.6rem;
}

.btn-sm {
  padding: 0.7rem 1.4rem;
  font-size: 0.85rem;
}

/* ============================================================
   10. STATS / DASHBOARD
   ============================================================ */
.stats {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}

.stat {
  padding: 2.75rem 1.5rem;
  text-align: center;
  border-inline-start: 1px solid var(--line);
  transition: background-color var(--dur-2) var(--ease);
}

.stat:first-child {
  border-inline-start: none;
}

.stat:hover {
  background: rgba(11, 79, 255, 0.025);
}

.stat-value {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: clamp(1.9rem, 1.5rem + 2vw, 3.25rem);
  color: var(--ink);
  font-variant-numeric: tabular-nums;
  letter-spacing: -0.02em;
}

.stat-label {
  margin-block-start: 0.5rem;
  font-size: 0.82rem;
  color: var(--mute);
  letter-spacing: 0.02em;
}

@media (max-width: 640px) {
  .stats {
    grid-template-columns: repeat(2, 1fr);
  }

  .stat:nth-child(2n+1) {
    border-inline-start: none;
  }

  .stat {
    padding: 2rem 1rem;
    border-block-end: 1px solid var(--line);
  }
}

/* ============================================================
   11. AI PANEL (conversation UI)
   ============================================================ */
.ai-panel {
  max-width: 560px;
  margin-inline: auto;
  padding: 1.75rem;
  border-radius: var(--radius-lg);
  background: var(--surface-alpha-strong);
  border: 1px solid rgba(255, 255, 255, 0.8);
  backdrop-filter: blur(24px) saturate(180%);
  -webkit-backdrop-filter: blur(24px) saturate(180%);
  box-shadow: var(--shadow), var(--shadow-glass-inset);
}

.ai-panel-head {
  display: flex;
  align-items: center;
  gap: 0.85rem;
  padding-block-end: 1.1rem;
  border-block-end: 1px solid var(--line);
  margin-block-end: 1.1rem;
}

.ai-avatar {
  inline-size: 38px;
  block-size: 38px;
  border-radius: 50%;
  background: var(--blue-soft);
  color: var(--blue);
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  flex-shrink: 0;
}

.ai-status {
  font-size: 0.78rem;
  color: var(--mute);
  display: flex;
  align-items: center;
  gap: 0.4rem;
}

.ai-status .dot {
  inline-size: 6px;
  block-size: 6px;
  border-radius: 50%;
  background: var(--blue);
}

.ai-messages {
  display: flex;
  flex-direction: column;
  gap: 0.9rem;
  max-height: 340px;
  overflow-y: auto;
}

.msg {
  max-width: 82%;
  padding: 0.9rem 1.15rem;
  border-radius: var(--radius);
  font-size: 0.92rem;
  line-height: 1.55;
}

.msg-ai {
  align-self: flex-start;
  background: var(--surface);
  border: 1px solid var(--line);
  border-start-start-radius: 6px;
  color: var(--ink-soft);
}

.msg-user {
  align-self: flex-end;
  margin-inline-start: auto;
  background: var(--blue);
  color: #fff;
  border-end-end-radius: 6px;
}

.ai-input-row {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  margin-block-start: 1.1rem;
  padding-block-start: 1.1rem;
  border-block-start: 1px solid var(--line);
}

.ai-input {
  flex: 1;
  padding: 0.8rem 1.2rem;
  border-radius: var(--radius-full);
  border: 1px solid var(--line);
  background: var(--surface);
  font-size: 0.9rem;
  transition: border-color var(--dur-1) var(--ease);
}

.ai-input:focus {
  border-color: var(--blue);
}

.ai-send {
  inline-size: 42px;
  block-size: 42px;
  flex-shrink: 0;
  border-radius: 50%;
  background: var(--blue);
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: transform var(--dur-1) var(--ease-spring), background-color var(--dur-1) var(--ease);
}

.ai-send:hover {
  transform: scale(1.06);
  background: var(--blue-dark);
}

/* ============================================================
   12. SERVICES (expandable, border-first)
   ============================================================ */
.services-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 1.25rem;
}

.service {
  padding: 2rem;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
  transition: border-color var(--dur-2) var(--ease), transform var(--dur-2) var(--ease), background-color var(--dur-2) var(--ease);
}

.service:hover,
.service:focus-within {
  border-color: var(--blue);
  transform: translateY(-4px);
  background: rgba(11, 79, 255, 0.015);
}

.service-top {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 1rem;
}

.service-icon {
  inline-size: 48px;
  block-size: 48px;
  border-radius: var(--radius-sm);
  background: var(--blue-soft);
  color: var(--blue);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.service-arrow {
  color: var(--mute);
  transition: transform var(--dur-2) var(--ease), color var(--dur-2) var(--ease);
}

.service:hover .service-arrow,
.service:focus-within .service-arrow {
  transform: rotate(45deg);
  color: var(--blue);
}

.service-title {
  margin-block-start: 1.25rem;
  font-size: 1.2rem;
}

.service-summary {
  margin-block-start: 0.5rem;
  color: var(--mute);
  font-size: 0.92rem;
  line-height: 1.6;
}

.service-details {
  display: grid;
  grid-template-rows: 0fr;
  opacity: 0;
  overflow: hidden;
  transition: grid-template-rows var(--dur-3) var(--ease), opacity var(--dur-2) var(--ease), margin-block-start var(--dur-3) var(--ease);
}

.service:hover .service-details,
.service:focus-within .service-details {
  grid-template-rows: 1fr;
  opacity: 1;
  margin-block-start: 1.1rem;
}

.service-details > div {
  min-height: 0;
  padding-block-start: 1.1rem;
  border-block-start: 1px solid var(--line);
  font-size: 0.88rem;
  color: var(--ink-soft);
  line-height: 1.7;
}

/* ============================================================
   13. TIMELINE (horizontal scroll-snap)
   ============================================================ */
.timeline {
  position: relative;
}

.timeline-track {
  display: flex;
  gap: 1.5rem;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  padding: 1.5rem var(--gutter) 2.5rem;
  margin-inline: calc(var(--gutter) * -1);
  scrollbar-width: none;
}

.timeline-track::-webkit-scrollbar {
  display: none;
}

.timeline-item {
  flex: 0 0 clamp(260px, 32vw, 340px);
  scroll-snap-align: start;
  padding: 1.75rem;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
  transition: border-color var(--dur-2) var(--ease), box-shadow var(--dur-2) var(--ease);
}

.timeline-item:hover {
  border-color: var(--blue);
  box-shadow: var(--shadow-sm);
}

.timeline-dot {
  inline-size: 10px;
  block-size: 10px;
  border-radius: 50%;
  background: var(--blue);
  box-shadow: 0 0 0 5px var(--blue-soft);
  margin-block-end: 1.25rem;
}

.timeline-year {
  font-family: var(--font-display);
  font-size: 1.6rem;
  font-weight: 700;
  color: var(--blue);
}

.timeline-title {
  margin-block-start: 0.5rem;
  font-size: 1.05rem;
  color: var(--ink);
  font-weight: 600;
}

.timeline-text {
  margin-block-start: 0.5rem;
  font-size: 0.88rem;
  color: var(--mute);
  line-height: 1.65;
}

/* ============================================================
   14. ECO CANVAS (network viz)
   ============================================================ */
.eco-canvas {
  position: relative;
  aspect-ratio: 16 / 9;
  border-radius: var(--radius-lg);
  border: 1px solid var(--line);
  background: linear-gradient(180deg, var(--surface), var(--bg));
  overflow: hidden;
}

.eco-canvas canvas,
.eco-canvas svg {
  position: absolute;
  inset: 0;
  inline-size: 100%;
  block-size: 100%;
}

.eco-node {
  position: absolute;
  inline-size: 10px;
  block-size: 10px;
  border-radius: 50%;
  background: var(--blue);
  box-shadow: 0 0 0 6px var(--blue-mist);
  transform: translate(-50%, -50%);
}

.eco-node.is-core {
  inline-size: 16px;
  block-size: 16px;
  background: var(--ink);
  box-shadow: 0 0 0 8px rgba(15, 20, 25, 0.06);
}

.eco-legend {
  position: absolute;
  inset-inline-start: 1.25rem;
  bottom: 1.25rem;
  display: flex;
  gap: 1rem;
  font-size: 0.78rem;
  color: var(--mute);
  background: var(--surface-alpha-strong);
  padding: 0.5rem 0.9rem;
  border-radius: var(--radius-full);
  border: 1px solid var(--line);
  backdrop-filter: blur(8px);
}

@media (max-width: 640px) {
  .eco-canvas {
    aspect-ratio: 4 / 5;
  }
}

/* ============================================================
   15. STORIES
   ============================================================ */
.stories-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 1.5rem;
}

.story {
  border-radius: var(--radius);
  border: 1px solid var(--line);
  background: var(--surface);
  overflow: hidden;
  transition: transform var(--dur-2) var(--ease), box-shadow var(--dur-2) var(--ease), border-color var(--dur-2) var(--ease);
}

.story:hover {
  transform: translateY(-6px);
  box-shadow: var(--shadow);
  border-color: var(--line-strong);
}

.story-media {
  aspect-ratio: 4 / 3;
  background: var(--blue-soft);
  object-fit: cover;
  width: 100%;
}

.story-body {
  padding: 1.75rem;
}

.story-quote {
  font-family: var(--font-display);
  font-size: 1.05rem;
  color: var(--ink);
  line-height: 1.55;
}

.story-meta {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  margin-block-start: 1.25rem;
}

.story-avatar {
  inline-size: 36px;
  block-size: 36px;
  border-radius: 50%;
  background: var(--blue-soft);
  flex-shrink: 0;
}

.story-name {
  font-size: 0.88rem;
  font-weight: 600;
  color: var(--ink);
}

.story-role {
  font-size: 0.8rem;
  color: var(--mute);
}

/* ============================================================
   16. NEWS (magazine grid)
   ============================================================ */
.news-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  grid-auto-rows: minmax(180px, auto);
  gap: 1.25rem;
}

.news-item {
  position: relative;
  grid-column: span 2;
  grid-row: span 1;
  border-radius: var(--radius);
  border: 1px solid var(--line);
  background: var(--surface);
  overflow: hidden;
  transition: transform var(--dur-2) var(--ease), box-shadow var(--dur-2) var(--ease);
}

.news-item:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-sm);
}

.news-item.is-featured {
  grid-column: span 2;
  grid-row: span 2;
}

.news-media {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.news-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(15, 20, 25, 0.78) 0%, rgba(15, 20, 25, 0.15) 55%, transparent 100%);
}

.news-content {
  position: relative;
  z-index: 1;
  height: 100%;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  padding: 1.5rem;
  color: #fff;
}

.news-category {
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--blue-soft);
}

.news-title {
  margin-block-start: 0.5rem;
  font-family: var(--font-display);
  font-size: clamp(1rem, 0.9rem + 0.6vw, 1.5rem);
  line-height: 1.3;
}

.news-item.is-featured .news-title {
  font-size: clamp(1.3rem, 1rem + 1.4vw, 2rem);
}

.news-date {
  margin-block-start: 0.6rem;
  font-size: 0.78rem;
  color: rgba(255, 255, 255, 0.75);
}

@media (max-width: 900px) {
  .news-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .news-item.is-featured {
    grid-column: span 2;
  }
}

@media (max-width: 560px) {
  .news-grid {
    grid-template-columns: 1fr;
  }

  .news-item,
  .news-item.is-featured {
    grid-column: span 1;
    grid-row: span 1;
    aspect-ratio: 4 / 3;
  }
}

/* ============================================================
   17. FOOTER
   ============================================================ */
.footer {
  border-block-start: 1px solid var(--line);
  background: var(--bg);
  padding-block: 4.5rem 2.5rem;
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr 1fr;
  gap: 2.5rem;
}

.footer-brand {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.footer-logo {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 1.1rem;
  color: var(--ink);
}

.footer-tagline {
  font-size: 0.88rem;
  color: var(--mute);
  max-width: 28ch;
  line-height: 1.65;
}

.footer-col-title {
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--ink);
  margin-block-end: 1rem;
}

.footer-col ul {
  display: flex;
  flex-direction: column;
  gap: 0.65rem;
}

.footer-col a {
  font-size: 0.9rem;
  color: var(--mute);
  transition: color var(--dur-1) var(--ease);
}

.footer-col a:hover {
  color: var(--blue);
}

.footer-bottom {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  flex-wrap: wrap;
  margin-block-start: 3.5rem;
  padding-block-start: 1.75rem;
  border-block-start: 1px solid var(--line);
  font-size: 0.82rem;
  color: var(--mute);
}

.footer-social {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.footer-social a {
  inline-size: 36px;
  block-size: 36px;
  border-radius: 50%;
  border: 1px solid var(--line);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--ink-soft);
  transition: border-color var(--dur-1) var(--ease), color var(--dur-1) var(--ease), background-color var(--dur-1) var(--ease);
}

.footer-social a:hover {
  border-color: var(--blue);
  color: var(--blue);
  background: var(--blue-soft);
}

@media (max-width: 860px) {
  .footer-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 2rem;
  }

  .footer-brand {
    grid-column: span 2;
  }
}

@media (max-width: 480px) {
  .footer-grid {
    grid-template-columns: 1fr;
  }

  .footer-brand {
    grid-column: span 1;
  }

  .footer-bottom {
    flex-direction: column;
    align-items: flex-start;
  }
}

/* ============================================================
   18. ACCESSIBILITY — FOCUS VISIBLE
   ============================================================ */
:focus {
  outline: none;
}

:focus-visible {
  outline: none;
  box-shadow: 0 0 0 4px var(--blue-soft);
  border-radius: inherit;
}

.btn:focus-visible,
.nav-link:focus-visible,
.service:focus-visible,
.story:focus-visible {
  box-shadow: 0 0 0 4px var(--blue-soft), var(--shadow-sm);
}

/* ============================================================
   19. RESPONSIVE — GLOBAL FINE-TUNING
   ============================================================ */
@media (max-width: 1024px) {
  .services-grid,
  .stories-grid {
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  }
}

@media (max-width: 480px) {
  :root {
    --gutter: 18px;
  }

  .hero-actions {
    flex-direction: column;
    align-items: stretch;
  }

  .btn {
    width: 100%;
  }
}

/* ============================================================
   20. REDUCED MOTION
   ============================================================ */
@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }

  .reveal {
    opacity: 1;
    transform: none;
  }

  .shape {
    animation: none;
  }

  .glow-follow {
    display: none;
  }
}

/* ============================================================
   21. EXTRA — globe, AI dock, chips, filters
   ============================================================ */
.hero-layout {
  display: grid;
  gap: clamp(2rem, 5vw, 4rem);
  align-items: center;
}

@media (min-width: 980px) {
  .hero-layout {
    grid-template-columns: 1.15fr 0.85fr;
  }
}

.hero-visual {
  position: relative;
  min-height: clamp(260px, 42vw, 420px);
  display: grid;
  place-items: center;
}

.hero-visual canvas#innovation-globe {
  width: min(100%, 420px);
  height: min(70vw, 420px);
  max-height: 420px;
}

.hero-stat-strip {
  display: flex;
  flex-wrap: wrap;
  gap: 1.25rem 2rem;
  margin-block-start: 2rem;
}

.hero-stat-strip strong {
  display: block;
  font-family: var(--font-display);
  font-size: 1.35rem;
  color: var(--ink);
  font-variant-numeric: tabular-nums;
}

.hero-stat-strip span {
  font-size: 0.78rem;
  color: var(--mute);
}

.ai-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-block-start: 0.85rem;
}

.ai-chips button {
  border: 1px solid var(--line);
  background: var(--surface);
  color: var(--ink-soft);
  border-radius: var(--radius-full);
  padding: 0.4rem 0.85rem;
  font-size: 0.78rem;
  font-family: inherit;
  cursor: pointer;
  transition: border-color var(--dur-1) var(--ease), color var(--dur-1) var(--ease), background var(--dur-1) var(--ease);
}

.ai-chips button:hover {
  border-color: var(--blue);
  color: var(--blue);
  background: var(--blue-soft);
}

.ai-thinking {
  display: inline-flex;
  gap: 0.28rem;
  align-items: center;
  height: 1rem;
}

.ai-thinking i {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--blue);
  opacity: 0.35;
  animation: think 1s ease-in-out infinite;
}

.ai-thinking i:nth-child(2) { animation-delay: 0.15s; }
.ai-thinking i:nth-child(3) { animation-delay: 0.3s; }

@keyframes think {
  0%, 100% { opacity: 0.25; transform: translateY(0); }
  50% { opacity: 1; transform: translateY(-3px); }
}

.ai-launcher {
  position: fixed;
  inset-inline-start: 1.25rem;
  inset-block-end: 1.25rem;
  z-index: 70;
  width: 56px;
  height: 56px;
  border-radius: 50%;
  border: none;
  background: var(--blue);
  color: #fff;
  box-shadow: var(--shadow-blue);
  cursor: pointer;
  font-size: 1.25rem;
  display: grid;
  place-items: center;
  transition: transform var(--dur-2) var(--ease);
}

.ai-launcher:hover {
  transform: scale(1.06);
}

.ai-dock {
  position: fixed;
  inset-inline-start: 1.25rem;
  inset-block-end: 5.5rem;
  z-index: 70;
  width: min(calc(100vw - 2rem), 380px);
  opacity: 0;
  pointer-events: none;
  transform: translateY(12px);
  transition: opacity var(--dur-2) var(--ease), transform var(--dur-2) var(--ease);
}

.ai-dock.is-open {
  opacity: 1;
  pointer-events: auto;
  transform: none;
}

.ai-dock .ai-panel {
  margin: 0;
  max-width: none;
}

.ai-dock-close {
  margin-inline-start: auto;
  border: none;
  background: transparent;
  color: var(--mute);
  cursor: pointer;
  font-size: 1rem;
  padding: 0.25rem;
}

.filter-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-block-end: 1.5rem;
}

.filter-row button {
  border: 1px solid var(--line);
  background: var(--surface);
  border-radius: var(--radius-full);
  padding: 0.45rem 0.95rem;
  font-size: 0.8rem;
  font-family: inherit;
  color: var(--mute);
  cursor: pointer;
}

.filter-row button.is-active,
.filter-row button:hover {
  border-color: var(--blue);
  color: var(--blue);
  background: var(--blue-soft);
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  border: 0;
}

.timeline-track.is-dragging {
  cursor: grabbing;
  scroll-snap-type: none;
}

/* Magazine news fallback (card layout used in HTML) */
.news-card {
  border-radius: var(--radius);
  border: 1px solid var(--line);
  background: var(--surface);
  overflow: hidden;
  transition: transform var(--dur-2) var(--ease), box-shadow var(--dur-2) var(--ease);
}

.news-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-sm);
}

.news-card.is-featured {
  grid-column: span 2;
  grid-row: span 2;
}

.news-card img {
  width: 100%;
  height: 200px;
  object-fit: cover;
}

.news-card.is-featured img {
  height: 280px;
}

.news-body {
  padding: 1.25rem 1.4rem 1.5rem;
}

.news-meta {
  font-size: 0.75rem;
  color: var(--mute);
  margin-bottom: 0.5rem;
}

.news-body h3 {
  font-family: var(--font-display);
  font-size: 1.05rem;
  color: var(--ink);
  line-height: 1.4;
}

.news-body p:last-child {
  margin-top: 0.5rem;
  font-size: 0.88rem;
  color: var(--mute);
}

.footer-inner {
  display: grid;
  gap: 2rem;
  padding-block: 3.5rem 2rem;
  grid-template-columns: 1.2fr 1fr;
}

@media (max-width: 768px) {
  .footer-inner {
    grid-template-columns: 1fr;
  }
  .news-card.is-featured {
    grid-column: span 2;
    grid-row: span 1;
  }
}

.footer-cols {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1.5rem;
}

.footer-label {
  font-size: 0.75rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--mute);
  margin-bottom: 0.75rem;
}

.footer-tag {
  margin-top: 0.75rem;
  color: var(--mute);
  font-size: 0.9rem;
  max-width: 28ch;
}

.footer-bottom {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 0.75rem;
  padding-block: 1.25rem 2rem;
  border-top: 1px solid var(--line);
  color: var(--mute);
  font-size: 0.8rem;
}

.timeline-year {
  font-size: 0.78rem;
  color: var(--blue);
  font-weight: 600;
  margin-bottom: 0.5rem;
}

.timeline-item h3 {
  font-family: var(--font-display);
  color: var(--ink);
  font-size: 1.1rem;
  margin-bottom: 0.4rem;
}

.timeline-item p {
  color: var(--mute);
  font-size: 0.88rem;
  line-height: 1.6;
}

