/* ============================================================
   Webinovators — Design System
   ============================================================ */

:root {
  --bg: #F8F9FA;
  --bg-alt: #FFFFFF;
  --surface: #FFFFFF;
  --navy: #0F172A;
  --slate: #1E293B;
  --slate-2: #334155;
  --muted: #64748B;
  --line: #E2E8F0;
  --blue: #2563EB;
  --blue-hover: #1D4ED8;
  --purple: #7C3AED;
  --purple-hover: #6D28D9;
  --emerald: #10B981;
  --amber: #F59E0B;
  --rose: #F43F5E;
  --indigo-grad: linear-gradient(135deg, #6366F1 0%, #7C3AED 100%);
  --blue-grad: linear-gradient(135deg, #3B82F6 0%, #2563EB 100%);
  --radius-sm: 8px;
  --radius: 14px;
  --radius-lg: 22px;
  --shadow-sm: 0 1px 2px rgba(15,23,42,.05);
  --shadow: 0 8px 24px rgba(15,23,42,.08);
  --shadow-lg: 0 30px 60px -20px rgba(15,23,42,.20);
  --header-h: 64px;
  --transition: .18s ease;
}

/* ============ Reset & Base ============ */
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
html, body { margin: 0; padding: 0; }
body {
  font-family: 'Inter', system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  background: var(--bg);
  color: var(--slate);
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

/* Skip link */
.skip-link {
  position: absolute;
  top: -100px;
  left: 16px;
  background: var(--blue);
  color: #fff;
  padding: 8px 16px;
  border-radius: var(--radius-sm);
  font-weight: 600;
  z-index: 9999;
  transition: top .15s;
}
.skip-link:focus { top: 16px; }

.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 24px;
}

a { color: inherit; text-decoration: none; }
img { max-width: 100%; height: auto; display: block; }

h1, h2, h3, h4, h5 {
  color: var(--navy);
  font-weight: 800;
  letter-spacing: -0.02em;
  line-height: 1.15;
  margin: 0 0 16px;
}
h1 { font-size: clamp(2rem, 4.6vw, 3.6rem); }
h2 { font-size: clamp(1.7rem, 3.2vw, 2.6rem); }
h3 { font-size: 1.3rem; }
p { margin: 0 0 14px; color: var(--slate-2); }
.muted { color: var(--muted); }

/* ============ Header ============ */
.site-header {
  position: sticky; top: 0; z-index: 200;
  height: var(--header-h);
  background: rgba(255,255,255,.92);
  backdrop-filter: saturate(180%) blur(14px);
  -webkit-backdrop-filter: saturate(180%) blur(14px);
  border-bottom: 1px solid var(--line);
  transition: box-shadow var(--transition);
}
.site-header.scrolled { box-shadow: 0 4px 20px rgba(15,23,42,.08); }

.header-inner {
  display: flex; align-items: center; gap: 20px;
  height: 100%;
  padding: 0 24px;
}
.brand { display: flex; align-items: center; flex-shrink: 0; }
.brand-logo {
  display: block;
  height: 32px;
  width: auto;
  object-fit: contain;
  object-position: left center;
}
/* Footer logo: white pill background so it reads on dark navy */
.brand-logo-footer {
  background: #fff;
  border-radius: 8px;
  padding: 4px 10px;
  height: 36px;
}

/* Nav */
.primary-nav {
  display: flex; align-items: center; gap: 4px;
  margin-left: auto;
}
.primary-nav > a, .nav-trigger {
  padding: 8px 12px;
  border-radius: 10px;
  font-weight: 500;
  font-size: 0.93rem;
  color: var(--slate-2);
  background: transparent;
  border: 0;
  cursor: pointer;
  font-family: inherit;
  transition: background var(--transition), color var(--transition);
  white-space: nowrap;
}
.primary-nav > a:hover, .nav-trigger:hover { background: var(--bg); color: var(--navy); }
.primary-nav > a.active { color: var(--blue); background: rgba(37,99,235,.08); font-weight: 600; }

.nav-dropdown { position: relative; }
.dropdown-menu {
  position: absolute; top: calc(100% + 8px); left: 0;
  min-width: 210px;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow-lg);
  padding: 8px;
  opacity: 0; visibility: hidden; transform: translateY(8px);
  transition: opacity .15s, transform .15s, visibility .15s;
  pointer-events: none;
}
.dropdown-menu a {
  display: flex; align-items: center; gap: 8px;
  padding: 10px 12px; border-radius: 10px;
  color: var(--slate-2); font-size: 0.93rem; font-weight: 500;
  transition: background var(--transition), color var(--transition);
}
.dropdown-menu a:hover { background: var(--bg); color: var(--navy); }
.nav-dropdown:hover .dropdown-menu,
.nav-dropdown:focus-within .dropdown-menu {
  opacity: 1; visibility: visible; transform: translateY(0);
  pointer-events: auto;
}
.caret { font-size: 0.7rem; opacity: 0.6; margin-left: 2px; }

/* Header actions */
.header-actions { display: flex; align-items: center; gap: 10px; flex-shrink: 0; }

/* Burger */
.menu-toggle {
  display: none;
  flex-direction: column; justify-content: center; align-items: center; gap: 5px;
  width: 42px; height: 42px;
  background: transparent; border: 1px solid var(--line);
  border-radius: 10px;
  cursor: pointer; padding: 0;
  flex-shrink: 0;
}
.burger-bar {
  display: block;
  width: 18px; height: 2px;
  background: var(--slate);
  border-radius: 2px;
  transition: transform .25s, opacity .25s, width .25s;
}
.menu-toggle.open .burger-bar:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.menu-toggle.open .burger-bar:nth-child(2) { opacity: 0; width: 0; }
.menu-toggle.open .burger-bar:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* Nav overlay */
.nav-overlay {
  display: none;
  position: fixed; inset: 0; z-index: 150;
  background: rgba(15,23,42,.45);
  backdrop-filter: blur(2px);
  opacity: 0;
  transition: opacity .25s;
}
.nav-overlay.visible { opacity: 1; }

/* ============ Buttons ============ */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  padding: 11px 20px;
  font-weight: 600;
  font-size: 0.95rem;
  border-radius: 12px;
  border: 1px solid transparent;
  cursor: pointer;
  font-family: inherit;
  transition: transform .12s, box-shadow .15s, background .15s, color .15s, border-color .15s, filter .15s;
  white-space: nowrap;
  text-decoration: none;
  -webkit-tap-highlight-color: transparent;
  touch-action: manipulation;
}
.btn:active { transform: scale(.97); }
.btn-primary {
  background: var(--blue); color: #fff;
  box-shadow: 0 6px 18px rgba(37,99,235,.28);
}
.btn-primary:hover { background: var(--blue-hover); box-shadow: 0 8px 22px rgba(37,99,235,.36); }
.btn-secondary {
  background: var(--indigo-grad); color: #fff;
  box-shadow: 0 6px 18px rgba(124,58,237,.28);
}
.btn-secondary:hover { filter: brightness(1.06); box-shadow: 0 8px 22px rgba(124,58,237,.36); }
.btn-ghost {
  background: transparent; color: var(--slate);
  border-color: var(--line);
}
.btn-ghost:hover { background: var(--bg); color: var(--navy); border-color: #CBD5E1; }
.btn-dark { background: var(--navy); color: #fff; }
.btn-dark:hover { background: var(--slate); }
.btn-lg { padding: 14px 26px; font-size: 1rem; border-radius: 14px; }
.btn-sm { padding: 8px 14px; font-size: 0.85rem; border-radius: 10px; }
.btn-full { width: 100%; }

/* ============ Pills ============ */
.pill {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 5px 12px;
  background: rgba(37,99,235,.1);
  color: var(--blue);
  border-radius: 999px;
  font-size: 0.77rem;
  font-weight: 700;
  letter-spacing: 0.07em;
  text-transform: uppercase;
}
.pill-purple { background: rgba(124,58,237,.1); color: var(--purple); }
.pill-emerald { background: rgba(16,185,129,.12); color: var(--emerald); }
.pill-amber { background: rgba(245,158,11,.12); color: var(--amber); }
.pill-navy { background: rgba(15,23,42,.08); color: var(--navy); }
.pill-rose { background: rgba(244,63,94,.1); color: var(--rose); }

/* ============ Sections ============ */
section { padding: 88px 0; }
.section-tight { padding: 56px 0; }
.section-head { text-align: center; max-width: 760px; margin: 0 auto 52px; }
.section-head h2 { margin-top: 14px; }
.section-head p { font-size: 1.08rem; color: var(--muted); }

/* ============ Reveal animations ============ */
.reveal {
  opacity: 0;
  transform: translateY(22px);
  transition: opacity .55s cubic-bezier(.22,1,.36,1), transform .55s cubic-bezier(.22,1,.36,1);
}
.reveal.visible { opacity: 1; transform: translateY(0); }
.reveal-delay-1 { transition-delay: .08s; }
.reveal-delay-2 { transition-delay: .16s; }
.reveal-delay-3 { transition-delay: .24s; }

/* ============ Hero ============ */
.hero {
  position: relative;
  padding: 110px 0 90px;
  overflow: hidden;
  background:
    radial-gradient(900px 500px at 80% -10%, rgba(124,58,237,.14), transparent 60%),
    radial-gradient(800px 500px at 0% 10%, rgba(37,99,235,.12), transparent 60%),
    linear-gradient(180deg, #FFFFFF 0%, #F8F9FA 100%);
}
.hero-inner { display: grid; grid-template-columns: 1.05fr .95fr; gap: 56px; align-items: center; }
.hero h1 { margin-bottom: 20px; }
.hero h1 .grad {
  background: linear-gradient(135deg, #2563EB 0%, #7C3AED 100%);
  -webkit-background-clip: text; background-clip: text; color: transparent;
}
.hero-lede { font-size: 1.1rem; color: var(--slate-2); max-width: 560px; }
.hero-actions { display: flex; flex-wrap: wrap; gap: 14px; margin-top: 28px; }
.hero-meta { display: flex; gap: 20px; margin-top: 26px; flex-wrap: wrap; }
.hero-meta .item { display: flex; align-items: center; gap: 8px; color: var(--slate-2); font-size: 0.9rem; font-weight: 500; }
.hero-meta .dot { width: 8px; height: 8px; border-radius: 50%; background: var(--emerald); box-shadow: 0 0 0 4px rgba(16,185,129,.18); flex-shrink: 0; }

/* Hero visual */
.hero-card {
  position: relative;
  border-radius: var(--radius-lg);
  background: linear-gradient(160deg, #0F172A 0%, #1E293B 100%);
  color: #fff;
  padding: 28px;
  box-shadow: var(--shadow-lg);
  overflow: hidden;
}
.hero-card::before {
  content: ""; position: absolute; inset: -1px;
  background: linear-gradient(135deg, rgba(59,130,246,.5) 0%, rgba(124,58,237,.5) 50%, rgba(16,185,129,.3) 100%);
  border-radius: inherit; z-index: 0;
}
.hero-card > * { position: relative; z-index: 1; }
.hero-card .row { display: flex; justify-content: space-between; align-items: center; margin-bottom: 14px; }
.hero-card .label { font-size: 0.78rem; color: #94A3B8; text-transform: uppercase; letter-spacing: 0.1em; }
.metric-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; margin-top: 14px; }
.metric {
  background: rgba(255,255,255,.05);
  border: 1px solid rgba(255,255,255,.1);
  border-radius: var(--radius);
  padding: 14px;
  transition: background var(--transition);
}
.metric:hover { background: rgba(255,255,255,.09); }
.metric .num { font-size: 1.6rem; font-weight: 800; color: #fff; }
.metric .lbl { font-size: 0.79rem; color: #CBD5E1; margin-top: 4px; }
.bar { height: 6px; background: rgba(255,255,255,.1); border-radius: 999px; overflow: hidden; margin-top: 10px; }
.bar > span { display: block; height: 100%; background: linear-gradient(90deg, #3B82F6, #10B981); border-radius: 999px; }

/* ============ Logo bar ============ */
.logo-bar {
  display: flex; align-items: center; justify-content: center; flex-wrap: wrap;
  gap: 12px; padding: 30px 24px;
  border-top: 1px solid var(--line); border-bottom: 1px solid var(--line);
  background: #fff;
}
.logo-bar .lb-label { color: var(--muted); font-size: 0.88rem; width: 100%; text-align: center; margin-bottom: 6px; }
.logo-chip {
  display: inline-flex; align-items: center; gap: 7px;
  padding: 7px 14px;
  background: var(--bg); border: 1px solid var(--line);
  border-radius: 999px;
  font-weight: 700; color: var(--slate); font-size: 0.9rem;
  transition: border-color var(--transition), box-shadow var(--transition);
}
.logo-chip:hover { border-color: #CBD5E1; box-shadow: var(--shadow-sm); }
.logo-chip .dot { width: 8px; height: 8px; border-radius: 50%; flex-shrink: 0; }
.dot-blinkit { background: #FFD600; }
.dot-zepto { background: #7C3AED; }
.dot-instamart { background: #F43F5E; }
.dot-amazon { background: #FF9900; }
.dot-shopify { background: #10B981; }
.dot-flipkart { background: #2563EB; }

/* ============ Cards ============ */
.grid { display: grid; gap: 22px; }
.grid-3 { grid-template-columns: repeat(3, 1fr); }
.grid-2 { grid-template-columns: repeat(2, 1fr); }
.grid-4 { grid-template-columns: repeat(4, 1fr); }

.card {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  padding: 28px;
  box-shadow: var(--shadow-sm);
  transition: transform .2s cubic-bezier(.22,1,.36,1), box-shadow .2s, border-color .2s;
}
.card:hover { transform: translateY(-4px); box-shadow: var(--shadow); border-color: #CBD5E1; }
.card .ic {
  display: inline-grid; place-items: center;
  width: 50px; height: 50px;
  border-radius: 14px;
  background: rgba(37,99,235,.1);
  color: var(--blue);
  font-size: 1.3rem;
  margin-bottom: 18px;
}
.card.purple .ic { background: rgba(124,58,237,.1); color: var(--purple); }
.card.emerald .ic { background: rgba(16,185,129,.12); color: var(--emerald); }
.card.amber .ic { background: rgba(245,158,11,.12); color: var(--amber); }
.card.rose .ic { background: rgba(244,63,94,.12); color: var(--rose); }

/* Dark card */
.dark-card {
  background: linear-gradient(160deg, #0F172A 0%, #1E293B 100%);
  color: #fff;
  border-radius: var(--radius-lg);
  padding: 36px;
}
.dark-card h2, .dark-card h3 { color: #fff; }
.dark-card p { color: #CBD5E1; }

/* Stat cards */
.stat-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 22px; }
.stat-card {
  border-radius: var(--radius-lg);
  background: var(--surface);
  border: 1px solid var(--line);
  padding: 32px 28px;
  text-align: center;
  transition: transform .2s, box-shadow .2s;
}
.stat-card:hover { transform: translateY(-4px); box-shadow: var(--shadow); }
.stat-card .num {
  font-size: 2.8rem; font-weight: 900; color: var(--navy);
  letter-spacing: -0.03em;
  background: linear-gradient(135deg, #2563EB, #7C3AED);
  -webkit-background-clip: text; background-clip: text; color: transparent;
  line-height: 1;
}
.stat-card .lbl { color: var(--muted); margin-top: 10px; font-weight: 500; line-height: 1.4; }

/* ============ Forms ============ */
.form { display: grid; gap: 16px; }
.field label { display: block; font-size: 0.85rem; font-weight: 600; color: var(--slate); margin-bottom: 6px; }
.field input, .field select, .field textarea {
  width: 100%;
  padding: 12px 14px;
  border-radius: 12px;
  border: 1.5px solid var(--line);
  background: #fff;
  font-family: inherit;
  font-size: 0.95rem;
  color: var(--slate);
  transition: border-color .15s, box-shadow .15s;
  -webkit-appearance: none;
  appearance: none;
  min-height: 44px; /* Touch target */
}
.field input:focus, .field select:focus, .field textarea:focus {
  outline: none;
  border-color: var(--blue);
  box-shadow: 0 0 0 4px rgba(37,99,235,.12);
}
.field input.invalid, .field select.invalid, .field textarea.invalid {
  border-color: var(--rose);
  box-shadow: 0 0 0 3px rgba(244,63,94,.1);
}
.field input.valid, .field select.valid, .field textarea.valid {
  border-color: var(--emerald);
}
.field-error { font-size: 0.8rem; color: var(--rose); margin-top: 5px; display: none; }
.field-error.show { display: block; }
.field-row { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.field-hint { font-size: 0.8rem; color: var(--muted); margin-top: 5px; }
textarea { min-height: 120px; resize: vertical; }

/* Select arrow */
.field select {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 24 24' fill='none' stroke='%2364748B' stroke-width='2'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 12px center;
  padding-right: 36px;
}

/* ============ Audit page ============ */
.audit-cards { display: grid; grid-template-columns: 1fr 1fr; gap: 22px; }
.audit-card {
  background: #fff; border: 1.5px solid var(--line);
  border-radius: var(--radius-lg);
  padding: 24px;
  cursor: pointer;
  transition: border-color .15s, transform .15s, box-shadow .15s;
  user-select: none;
  -webkit-tap-highlight-color: transparent;
}
.audit-card:hover { border-color: var(--blue); transform: translateY(-3px); box-shadow: var(--shadow); }
.audit-card.active { border-color: var(--blue); box-shadow: 0 0 0 4px rgba(37,99,235,.1); }
.audit-form-wrap {
  margin-top: 28px;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  padding: 32px;
}
.audit-form-head { display: flex; justify-content: space-between; align-items: center; margin-bottom: 20px; flex-wrap: wrap; gap: 10px; }
.audit-result {
  margin-top: 24px;
  border-radius: var(--radius);
  padding: 22px;
  background: linear-gradient(135deg, rgba(37,99,235,.05), rgba(124,58,237,.05));
  border: 1px solid rgba(37,99,235,.18);
}
.score-ring {
  width: 110px; height: 110px;
  display: grid; place-items: center;
  border-radius: 50%;
  background: conic-gradient(var(--blue) calc(var(--p, 0) * 1%), #E2E8F0 0);
  position: relative;
  flex-shrink: 0;
}
.score-ring::after {
  content: ""; position: absolute; inset: 8px; background: #fff; border-radius: 50%;
}
.score-ring span {
  position: relative; z-index: 1;
  font-weight: 800; font-size: 1.6rem; color: var(--navy);
}

/* ============ Calculator ============ */
.calc-wrap { display: grid; grid-template-columns: 1fr 1fr; gap: 22px; align-items: start; }
.calc-card {
  background: #fff; border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  padding: 30px;
}
.calc-results {
  background: linear-gradient(160deg, #0F172A 0%, #1E293B 100%);
  color: #fff;
  border-radius: var(--radius-lg);
  padding: 30px;
}
.calc-results h3 { color: #fff; }
.result-item {
  background: rgba(255,255,255,.05);
  border: 1px solid rgba(255,255,255,.08);
  border-radius: var(--radius);
  padding: 16px;
  margin-bottom: 12px;
  transition: background var(--transition);
}
.result-item:hover { background: rgba(255,255,255,.09); }
.result-item .label { color: #94A3B8; font-size: 0.84rem; }
.result-item .value { font-size: 1.7rem; font-weight: 800; color: #fff; margin: 4px 0; }
.result-item .formula { color: #64748B; font-size: 0.77rem; font-family: ui-monospace, "JetBrains Mono", monospace; }

/* ============ Filters ============ */
.filter-row { display: flex; flex-wrap: wrap; gap: 10px; margin-bottom: 28px; }
.filter {
  padding: 9px 18px;
  background: #fff; border: 1.5px solid var(--line);
  border-radius: 999px;
  font-weight: 600; font-size: 0.88rem; color: var(--slate-2);
  cursor: pointer; font-family: inherit;
  transition: all .15s;
  min-height: 44px;
  -webkit-tap-highlight-color: transparent;
}
.filter:hover { border-color: var(--blue); color: var(--blue); background: rgba(37,99,235,.04); }
.filter.active { background: var(--blue); color: #fff; border-color: var(--blue); }

/* Blog cards */
.blog-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 22px; }
.blog-card {
  background: #fff; border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  overflow: hidden;
  transition: transform .2s cubic-bezier(.22,1,.36,1), box-shadow .2s;
  cursor: pointer;
}
.blog-card:hover { transform: translateY(-4px); box-shadow: var(--shadow); }
.blog-thumb { height: 160px; background: var(--indigo-grad); position: relative; overflow: hidden; }
.blog-thumb.qcom { background: linear-gradient(135deg, #2563EB, #10B981); }
.blog-thumb.mp { background: linear-gradient(135deg, #F59E0B, #F43F5E); }
.blog-thumb.d2c { background: linear-gradient(135deg, #7C3AED, #3B82F6); }
.blog-thumb .pill { position: absolute; top: 14px; left: 14px; background: rgba(255,255,255,.95); color: var(--slate); }
.blog-body { padding: 22px; }
.blog-body h3 { margin-bottom: 8px; font-size: 1.08rem; line-height: 1.3; }
.blog-meta { color: var(--muted); font-size: 0.84rem; margin-top: 14px; display: flex; align-items: center; gap: 8px; }

/* ============ FAQ ============ */
.faq-item {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 0 22px;
  margin-bottom: 10px;
  transition: border-color var(--transition);
}
.faq-item[open] { border-color: rgba(37,99,235,.25); }
.faq-item summary {
  list-style: none;
  cursor: pointer;
  font-weight: 600;
  color: var(--navy);
  padding: 18px 0;
  display: flex; justify-content: space-between; align-items: center;
  gap: 12px;
  user-select: none;
  -webkit-tap-highlight-color: transparent;
}
.faq-item summary::-webkit-details-marker { display: none; }
.faq-item summary::after {
  content: "+"; font-size: 1.4rem; color: var(--blue);
  flex-shrink: 0;
  transition: transform .2s;
  line-height: 1;
}
.faq-item[open] summary::after { content: "−"; }
.faq-item .body { padding: 0 0 18px; color: var(--slate-2); line-height: 1.7; }

/* ============ Timeline ============ */
.timeline { display: grid; gap: 14px; }
.tl-row {
  display: grid; grid-template-columns: 120px 1fr; gap: 18px;
  background: #fff; border: 1px solid var(--line);
  border-radius: var(--radius); padding: 20px;
  align-items: start;
}
.tl-row .when {
  display: inline-flex; align-items: center; justify-content: center;
  background: rgba(37,99,235,.1); color: var(--blue);
  border-radius: 10px; font-weight: 700; padding: 8px 12px; font-size: 0.84rem;
  height: fit-content; text-align: center; white-space: nowrap;
}
.tl-row .what h4 { margin: 0 0 4px; }
.tl-row .what p { margin: 0; }

/* ============ About ============ */
.about-hero { display: grid; grid-template-columns: 1.2fr .8fr; gap: 52px; align-items: center; }
.profile-card {
  background: linear-gradient(160deg, #1E293B 0%, #0F172A 100%);
  border-radius: var(--radius-lg);
  padding: 36px;
  color: #fff;
  text-align: center;
  box-shadow: var(--shadow-lg);
}
.avatar {
  width: 100px; height: 100px; border-radius: 50%;
  background: var(--indigo-grad);
  display: grid; place-items: center;
  font-size: 2.5rem; font-weight: 800; color: #fff;
  margin: 0 auto 18px;
  box-shadow: 0 16px 40px rgba(124,58,237,.4);
}
.badge-row { display: flex; flex-wrap: wrap; gap: 10px; margin: 14px 0 22px; }

/* ============ Resources ============ */
.resource-card {
  background: #fff; border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  padding: 28px;
  display: flex; flex-direction: column;
  gap: 14px;
  transition: transform .2s, box-shadow .2s;
}
.resource-card:hover { transform: translateY(-4px); box-shadow: var(--shadow); }
.resource-card .actions { margin-top: auto; padding-top: 4px; }

/* ============ Newsletter ============ */
.newsletter {
  margin-top: 60px;
  background: linear-gradient(135deg, #0F172A 0%, #1E293B 100%);
  border-radius: var(--radius-lg);
  padding: 48px 40px;
  color: #fff;
  text-align: center;
}
.newsletter h3 { color: #fff; font-size: 1.5rem; }
.newsletter form {
  display: flex; gap: 10px; max-width: 480px; margin: 20px auto 0; flex-wrap: wrap; justify-content: center;
}
.newsletter input {
  flex: 1; min-width: 200px;
  padding: 12px 16px;
  border-radius: 10px; border: 1.5px solid rgba(255,255,255,.15);
  background: rgba(255,255,255,.07);
  color: #fff;
  font-family: inherit; font-size: 0.95rem;
  transition: border-color .15s, box-shadow .15s;
}
.newsletter input:focus { outline: none; border-color: rgba(255,255,255,.4); box-shadow: 0 0 0 3px rgba(255,255,255,.08); }
.newsletter input::placeholder { color: #64748B; }

/* ============ Contact ============ */
.contact-grid { display: grid; grid-template-columns: 1.1fr .9fr; gap: 24px; align-items: start; }
.expect-list { display: grid; gap: 12px; }
.expect-item {
  display: grid; grid-template-columns: 44px 1fr; gap: 14px;
  background: #fff; border: 1px solid var(--line);
  padding: 16px; border-radius: var(--radius);
  align-items: start;
}
.expect-item .step {
  width: 36px; height: 36px; border-radius: 10px;
  background: var(--indigo-grad); color: #fff;
  display: grid; place-items: center;
  font-weight: 800; font-size: 0.95rem;
  flex-shrink: 0;
}
.expect-item h4 { margin: 0 0 4px; }
.expect-item p { margin: 0; font-size: 0.93rem; }

/* Spinner */
.spinner {
  display: inline-block;
  width: 18px; height: 18px;
  border: 2px solid rgba(255,255,255,.3);
  border-top-color: #fff;
  border-radius: 50%;
  animation: spin .7s linear infinite;
  flex-shrink: 0;
}
@keyframes spin { to { transform: rotate(360deg); } }

/* Form loading overlay */
.form-loading { position: relative; pointer-events: none; opacity: 0.7; }

/* ============ Toast notifications ============ */
.toast-container {
  position: fixed; bottom: 24px; right: 24px; z-index: 9000;
  display: flex; flex-direction: column; gap: 10px;
  pointer-events: none;
}
.toast {
  display: flex; align-items: center; gap: 12px;
  padding: 14px 18px;
  background: var(--navy);
  color: #fff;
  border-radius: var(--radius);
  box-shadow: var(--shadow-lg);
  font-size: 0.92rem;
  font-weight: 500;
  min-width: 260px;
  max-width: 380px;
  pointer-events: auto;
  animation: toast-in .3s cubic-bezier(.22,1,.36,1) both;
}
.toast.toast-success { background: #065F46; border-left: 4px solid var(--emerald); }
.toast.toast-error { background: #881337; border-left: 4px solid var(--rose); }
.toast.toast-info { background: #1E3A8A; border-left: 4px solid var(--blue); }
.toast.out { animation: toast-out .25s ease both; }
@keyframes toast-in {
  from { opacity: 0; transform: translateX(30px); }
  to { opacity: 1; transform: translateX(0); }
}
@keyframes toast-out {
  to { opacity: 0; transform: translateX(30px); }
}

/* ============ Scroll-to-top ============ */
.scroll-top {
  position: fixed; bottom: 24px; left: 24px; z-index: 8000;
  width: 44px; height: 44px;
  background: var(--navy); color: #fff;
  border: none; border-radius: 50%;
  font-size: 1.1rem; cursor: pointer;
  box-shadow: var(--shadow);
  opacity: 0; visibility: hidden; transform: translateY(10px);
  transition: opacity .2s, visibility .2s, transform .2s;
  display: grid; place-items: center;
}
.scroll-top.visible { opacity: 1; visibility: visible; transform: translateY(0); }
.scroll-top:hover { background: var(--slate); transform: translateY(-2px); }

/* ============ Footer ============ */
.site-footer {
  background: #0F172A;
  color: #94A3B8;
  margin-top: 80px;
  padding-top: 64px;
}
.site-footer .brand { color: #fff; }
.site-footer h4 { color: #fff; margin-bottom: 16px; font-size: 0.9rem; text-transform: uppercase; letter-spacing: 0.06em; }
.footer-grid { display: grid; grid-template-columns: 2fr 1fr 1fr 1fr; gap: 36px; }
.footer-col { display: flex; flex-direction: column; gap: 10px; }
.footer-col a { color: #94A3B8; font-size: 0.91rem; transition: color var(--transition); }
.footer-col a:hover { color: #fff; }
.footer-col .muted { color: #64748B; font-size: 0.9rem; max-width: 300px; line-height: 1.7; }
.footer-contact a { color: var(--blue) !important; font-weight: 500; }
.footer-contact a:hover { color: #93C5FD !important; }
.footer-bottom {
  display: flex; justify-content: space-between; align-items: center;
  border-top: 1px solid rgba(255,255,255,.07);
  margin-top: 44px; padding: 24px;
  font-size: 0.84rem;
}

/* ============ Page transition ============ */
.fade-in { animation: fade-in .3s cubic-bezier(.22,1,.36,1) both; }
@keyframes fade-in {
  from { opacity: 0; transform: translateY(8px); }
  to { opacity: 1; transform: translateY(0); }
}

/* ============ Success state ============ */
.success-state {
  text-align: center;
  padding: 48px 24px;
}
.success-icon {
  width: 72px; height: 72px;
  border-radius: 50%;
  background: rgba(16,185,129,.12);
  color: var(--emerald);
  font-size: 2rem;
  display: grid; place-items: center;
  margin: 0 auto 20px;
}

/* ============ Responsive — 1024px ============ */
@media (max-width: 1024px) {
  .primary-nav > a, .nav-trigger { padding: 7px 10px; font-size: 0.88rem; }
  .grid-4 { grid-template-columns: repeat(2, 1fr); }
}

/* ============ Responsive — 860px ============ */
@media (max-width: 860px) {
  .hero-inner { grid-template-columns: 1fr; }
  .hero-inner > div:last-child { display: none; } /* hide hero card on mobile */
  .about-hero { grid-template-columns: 1fr; }
  .about-hero > div:last-child { max-width: 360px; margin: 0 auto; width: 100%; }
  .contact-grid { grid-template-columns: 1fr; }
  .calc-wrap { grid-template-columns: 1fr; }
  .stat-grid { grid-template-columns: repeat(2, 1fr); }
  .footer-grid { grid-template-columns: 1fr 1fr; }
  .grid-3 { grid-template-columns: repeat(2, 1fr); }
  .blog-grid { grid-template-columns: repeat(2, 1fr); }
}

/* ============ Responsive — 720px ============ */
@media (max-width: 720px) {
  :root { --header-h: 58px; }

  /* Mobile nav */
  .primary-nav {
    position: fixed;
    top: var(--header-h); left: 0; right: 0;
    flex-direction: column; align-items: stretch; gap: 2px;
    background: #fff; border-bottom: 1px solid var(--line);
    padding: 12px 16px 18px;
    z-index: 175;
    max-height: calc(100dvh - var(--header-h));
    overflow-y: auto;
    transform: translateY(-110%);
    opacity: 0;
    visibility: hidden;
    transition: transform .28s cubic-bezier(.22,1,.36,1), opacity .22s, visibility .22s;
    box-shadow: 0 20px 40px rgba(15,23,42,.12);
  }
  .primary-nav.open {
    transform: translateY(0);
    opacity: 1;
    visibility: visible;
  }
  .primary-nav > a {
    padding: 13px 14px;
    font-size: 1rem;
    border-radius: 10px;
    min-height: 48px;
    display: flex; align-items: center;
  }
  .nav-dropdown { display: flex; flex-direction: column; gap: 2px; }
  .nav-trigger { padding: 13px 14px; text-align: left; font-size: 1rem; min-height: 48px; width: 100%; }
  .dropdown-menu {
    position: static;
    opacity: 1; visibility: visible; transform: none;
    box-shadow: none; border: none;
    background: var(--bg);
    border-radius: var(--radius);
    pointer-events: auto;
    padding: 6px;
    margin-top: 2px;
  }
  .dropdown-menu a { font-size: 0.95rem; padding: 11px 12px; }

  .nav-overlay { display: block; }
  .menu-toggle { display: flex; }
  .header-actions .btn-ghost { display: none; }

  /* Layout */
  .grid-3, .grid-4, .blog-grid, .audit-cards { grid-template-columns: 1fr; }
  .stat-grid { grid-template-columns: 1fr 1fr; }
  .grid-2 { grid-template-columns: 1fr; }
  .field-row { grid-template-columns: 1fr; }
  .footer-grid { grid-template-columns: 1fr 1fr; }
  .tl-row { grid-template-columns: 1fr; gap: 10px; }
  .tl-row .when { width: fit-content; }

  section { padding: 64px 0; }
  .hero { padding: 72px 0 56px; }
  .hero h1 { font-size: clamp(1.9rem, 7vw, 2.4rem); }
  .audit-form-wrap { padding: 22px; }
  .dark-card { padding: 26px; }
  .newsletter { padding: 36px 24px; }
  .footer-bottom { flex-direction: column; gap: 8px; text-align: center; }
}

@media (max-width: 480px) {
  .container { padding: 0 16px; }
  .hero-actions { flex-direction: column; }
  .hero-actions .btn { width: 100%; justify-content: center; }
  .stat-grid { grid-template-columns: 1fr; }
  .footer-grid { grid-template-columns: 1fr; }
  .dark-card[style*="grid-template-columns"] { display: flex !important; flex-direction: column; }
  .toast-container { right: 12px; left: 12px; bottom: 16px; }
  .toast { min-width: unset; width: 100%; }
  .scroll-top { left: 16px; bottom: 16px; }
}
