/* ==========================================================================
   CX Suite — Guides stylesheet
   Reuses the exact tokens + chrome from the suite home page (index.html) so
   /guides/ pages match the dark system pixel for pixel, plus guide-only
   components (breadcrumb, guide cards, article prose, callouts).
   ========================================================================== */

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
  --accent:        #14b8a6;
  --accent-rgb:    20, 184, 166;
  --accent-glow:   rgba(20, 184, 166, 0.22);
  --accent-border: rgba(20, 184, 166, 0.30);
  --accent-2:      #2F80ED;

  --bg:            #060d14;
  --surface:       #0c1a24;
  --surface-2:     #101f2c;
  --surface-3:     #162433;
  --border:        rgba(255, 255, 255, 0.07);
  --border-hover:  rgba(255, 255, 255, 0.14);

  --text:          #f1f5f9;
  --text-muted:    #7a9ab5;
  --text-faint:    #3d5a72;

  --text-sm:       clamp(13px, 1.4vw, 15px);
  --text-base:     clamp(16px, 1.8vw, 18px);
  --text-lg:       clamp(20px, 2.5vw, 26px);
  --text-xl:       clamp(28px, 4vw, 40px);
  --text-2xl:      clamp(40px, 6vw, 64px);

  --space-sm:  clamp(12px, 2vw, 18px);
  --space-md:  clamp(20px, 3.5vw, 32px);
  --space-lg:  clamp(48px, 7vw, 88px);
  --space-xl:  clamp(80px, 12vw, 144px);

  --radius-sm: 8px;
  --radius-md: 14px;
  --radius-lg: 20px;
  --radius-xl: 28px;

  --shadow-glow: 0 0 60px rgba(20,184,166,0.18);

  --ease:     cubic-bezier(0.22, 1, 0.36, 1);
  --dur-fast: 0.25s;
}

html { scroll-behavior: smooth; }
body {
  background: var(--bg);
  color: var(--text);
  font-family: 'Inter', system-ui, sans-serif;
  font-size: 16px;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}
a { color: inherit; text-decoration: none; }
img { display: block; max-width: 100%; }
button { font: inherit; cursor: pointer; border: none; }

/* ── Mesh + grid background ─────────────────────────────── */
.bg-mesh {
  position: fixed; inset: 0; z-index: 0; pointer-events: none;
  background:
    radial-gradient(ellipse 80% 55% at 90% -10%, rgba(20,184,166,0.13) 0%, transparent 55%),
    radial-gradient(ellipse 60% 50% at -5%  95%, rgba(47,128,237,0.10) 0%, transparent 55%),
    radial-gradient(ellipse 45% 40% at 50%  55%, rgba(20,184,166,0.04) 0%, transparent 65%);
}
.bg-grid {
  position: fixed; inset: 0; z-index: 0; pointer-events: none;
  background-image:
    linear-gradient(rgba(255,255,255,0.022) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255,255,255,0.022) 1px, transparent 1px);
  background-size: 64px 64px;
  mask-image: radial-gradient(ellipse 80% 60% at 50% 40%, black 20%, transparent 80%);
}
body > *:not(.bg-mesh):not(.bg-grid) { position: relative; z-index: 1; }

/* ── Nav (identical to home) ────────────────────────────── */
.nav {
  position: fixed; top: 0; left: 0; right: 0; z-index: 200;
  height: 68px; display: flex; align-items: center;
  padding: 0 clamp(20px, 5vw, 52px);
  transition: background .35s ease, border-color .35s ease, backdrop-filter .35s ease;
}
.nav.scrolled {
  background: rgba(6,13,20,0.90);
  backdrop-filter: blur(20px) saturate(1.5);
  -webkit-backdrop-filter: blur(20px) saturate(1.5);
  border-bottom: 1px solid var(--border);
}
.nav-logo { display: flex; align-items: center; gap: 10px; font-weight: 700; font-size: 15px; letter-spacing: -0.02em; margin-right: auto; }
.nav-logo-mark {
  width: 34px; height: 34px; border-radius: 10px;
  background: linear-gradient(135deg, var(--accent), #0e9488);
  display: flex; align-items: center; justify-content: center;
  color: #060d14; font-size: 11px; font-weight: 900; letter-spacing: .05em;
  box-shadow: 0 6px 20px rgba(20,184,166,0.32); flex-shrink: 0;
}
.nav-logo-sub { font-size: 11px; font-weight: 600; color: var(--text-faint); letter-spacing: .04em; margin-top: 1px; }
.nav-links { display: flex; align-items: center; gap: 2px; list-style: none; margin-right: 20px; }
.nav-links a { padding: 8px 14px; border-radius: var(--radius-md); font-size: 14px; font-weight: 600; color: var(--text-muted); transition: color .2s, background .2s; }
.nav-links a:hover, .nav-links a.active { color: var(--text); background: rgba(255,255,255,.05); }
.nav-actions { display: flex; align-items: center; gap: 10px; }
.btn-ghost {
  padding: 9px 18px; border-radius: var(--radius-md);
  border: 1px solid var(--border); background: rgba(255,255,255,.03);
  color: var(--text-muted); font-size: 13px; font-weight: 700;
  transition: all .2s; min-height: 40px; display: inline-flex; align-items: center; gap: 7px;
}
.btn-ghost:hover { color: var(--text); border-color: var(--border-hover); background: rgba(255,255,255,.06); }
.btn-primary {
  padding: 10px 20px; border-radius: var(--radius-md);
  background: var(--accent); border: none; color: #060d14;
  font-size: 13px; font-weight: 700; transition: all .2s; min-height: 40px;
  display: inline-flex; align-items: center; gap: 7px; box-shadow: 0 4px 16px rgba(20,184,166,.28);
}
.btn-primary:hover { transform: translateY(-2px); box-shadow: 0 8px 28px rgba(20,184,166,.40); opacity: .92; }
.nav-toggle {
  display: none; align-items: center; justify-content: center;
  width: 40px; height: 40px; border-radius: var(--radius-sm);
  background: rgba(255,255,255,.05); border: 1px solid var(--border); color: var(--text); font-size: 16px;
}
.mobile-menu {
  display: none; flex-direction: column; gap: 4px;
  position: fixed; top: 68px; left: 0; right: 0; z-index: 199;
  background: var(--surface); border-bottom: 1px solid var(--border);
  padding: 12px 20px 16px; backdrop-filter: blur(20px);
}
.mobile-menu.open { display: flex; }
.mobile-menu a { padding: 10px 14px; border-radius: var(--radius-md); font-size: 15px; font-weight: 600; color: var(--text-muted); transition: color .2s, background .2s; }
.mobile-menu a:hover { color: var(--text); background: rgba(255,255,255,.05); }

/* ── Shared layout ──────────────────────────────────────── */
.wrap { max-width: 1200px; margin: 0 auto; padding: 0 clamp(20px,5vw,52px); }
.wrap-narrow { max-width: 780px; margin: 0 auto; padding: 0 clamp(20px,5vw,52px); }
/* Footer join: the last section owns its own bottom padding so content never
   touches the footer's top edge; the footer itself takes no top margin. */
main.wrap, main.wrap-narrow { padding-bottom: var(--space-lg); }
.section-eyebrow { font-size: 11px; font-weight: 700; letter-spacing: .14em; text-transform: uppercase; color: var(--accent); margin-bottom: 16px; }

/* ── Guide hero + breadcrumb ────────────────────────────── */
.guide-top { padding: clamp(120px,15vw,168px) 0 clamp(24px,4vw,40px); }
.breadcrumb { display: flex; align-items: center; gap: 8px; font-size: 13px; color: var(--text-faint); margin-bottom: 22px; flex-wrap: wrap; }
.breadcrumb a { color: var(--text-muted); transition: color .2s; }
.breadcrumb a:hover { color: var(--text); }
.breadcrumb i { font-size: 9px; color: var(--text-faint); }
.guide-h1 { font-size: var(--text-2xl); font-weight: 700; letter-spacing: -.03em; line-height: 1.04; margin-bottom: 18px; max-width: 720px; }
.guide-h1 span { color: var(--accent); }
.guide-lede { font-size: var(--text-base); color: var(--text-muted); line-height: 1.7; max-width: 620px; }
.guide-meta { display: flex; align-items: center; gap: 18px; flex-wrap: wrap; margin-top: 22px; font-size: 13px; color: var(--text-faint); }
.guide-meta span { display: flex; align-items: center; gap: 7px; }
.guide-meta i { color: var(--accent); font-size: 12px; }

/* ── Guide hub grid (cards match .app-card) ─────────────── */
.guide-grid {
  display: grid; grid-template-columns: repeat(auto-fill, minmax(320px,1fr));
  gap: 18px; padding: clamp(24px,4vw,40px) 0 clamp(40px,6vw,64px);
}
/* Fill-defined cards: no border, no shadow. Separation comes from the lighter
   surface fill on the dark canvas; the accent top bar signals the live ones. */
.guide-card {
  background: var(--surface-2); border-radius: var(--radius-lg);
  padding: 20px; display: flex; flex-direction: column; gap: 12px;
  transition: transform .3s var(--ease), background .3s ease;
  position: relative; overflow: hidden;
}
.guide-card::before {
  content: ''; position: absolute; top: 0; left: 0; right: 0; height: 2px;
  background: linear-gradient(90deg, var(--accent), transparent); opacity: 0; transition: opacity .3s ease;
}
a.guide-card:hover { transform: translateY(-4px); background: var(--surface-3); }
a.guide-card:hover::before { opacity: 1; }
.guide-card.soon { opacity: .66; }
.guide-card-top { display: flex; align-items: center; justify-content: space-between; }
/* De-chipped: bare flat line icon on the card surface, no tinted tile. */
.guide-icon { color: var(--accent); font-size: 26px; line-height: 1; flex-shrink: 0; }
.guide-icon.blue  { color: #2F80ED; }
.guide-icon.amber { color: #f59e0b; }
.guide-icon.purple{ color: #a855f7; }
.badge { font-size: 10px; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; padding: 3px 9px; border-radius: 99px; }
.badge-live { background: rgba(34,197,94,.14); color: #22c55e; }
.badge-soon { background: rgba(255,255,255,.06); color: var(--text-muted); }
.guide-card-name { font-size: 18px; font-weight: 700; letter-spacing: -.02em; }
.guide-card-desc { font-size: 14px; color: var(--text-muted); line-height: 1.65; }
.guide-card-cta { margin-top: auto; padding-top: 14px; font-size: 13px; font-weight: 700; color: var(--accent); display: flex; align-items: center; gap: 6px; }
.guide-card-cta.muted { color: var(--text-faint); }

/* ── Article prose ──────────────────────────────────────── */
.article { padding: clamp(24px,4vw,44px) 0 var(--space-xl); }
.article h2 { font-size: var(--text-xl); font-weight: 700; letter-spacing: -.02em; line-height: 1.15; margin: 44px 0 14px; }
.article h2:first-child { margin-top: 0; }
.article h3 { font-size: var(--text-lg); font-weight: 700; letter-spacing: -.01em; margin: 32px 0 10px; }
.article p { font-size: 16px; color: var(--text-muted); line-height: 1.8; margin-bottom: 18px; }
.article p strong, .article li strong { color: var(--text); font-weight: 700; }
.article a.link { color: var(--accent); font-weight: 600; border-bottom: 1px solid var(--accent-border); }
.article a.link:hover { border-bottom-color: var(--accent); }
.article ul, .article ol { margin: 0 0 18px 0; padding-left: 22px; }
.article li { font-size: 16px; color: var(--text-muted); line-height: 1.8; margin-bottom: 8px; }
.article ul li::marker { color: var(--accent); }
.article ol li::marker { color: var(--accent); font-weight: 700; }

/* Numbered steps — fill-defined rows, no border; bare accent numeral, no chip */
.steps { display: flex; flex-direction: column; gap: 12px; margin: 8px 0 26px; }
.step-row { display: grid; grid-template-columns: 34px 1fr; gap: 16px; align-items: start; background: var(--surface-2); border-radius: var(--radius-md); padding: 20px; }
.step-idx { color: var(--accent); font-weight: 700; font-size: 22px; line-height: 1.2; text-align: center; }
.step-row h4 { font-size: 16px; font-weight: 700; margin-bottom: 4px; }
.step-row p { font-size: 14px; margin-bottom: 0; }

/* Callout — surface fill + functional left accent stripe only (no full border) */
.callout { background: var(--surface-2); border-left: 3px solid var(--accent); border-radius: var(--radius-md); padding: 18px 20px; margin: 8px 0 26px; }
.callout.pro { border-left-color: var(--accent-2); }
.callout-title { font-size: 13px; font-weight: 700; letter-spacing: .02em; margin-bottom: 6px; display: flex; align-items: center; gap: 8px; }
.callout-title i { color: var(--accent); }
.callout.pro .callout-title i { color: var(--accent-2); }
.callout p { font-size: 14px; margin-bottom: 0; }

/* Table of contents — surface fill, no border */
.toc { background: var(--surface-2); border-radius: var(--radius-md); padding: 20px; margin-bottom: 32px; }
.toc h4 { font-size: 12px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--text-faint); margin-bottom: 12px; }
.toc a { display: block; font-size: 14px; color: var(--text-muted); padding: 5px 0; transition: color .2s; }
.toc a:hover { color: var(--accent); }

/* Next-step CTA panel — gradient fill band, no border */
.next-cta { background: linear-gradient(135deg, var(--surface-3), var(--surface)); border-radius: var(--radius-lg); padding: clamp(28px,4vw,40px); text-align: center; margin-top: 40px; }
.next-cta h3 { font-size: var(--text-lg); font-weight: 700; letter-spacing: -.02em; margin-bottom: 10px; }
.next-cta p { font-size: 14px; color: var(--text-muted); max-width: 460px; margin: 0 auto 22px; }
.next-cta .cta-actions { display: flex; gap: 12px; justify-content: center; flex-wrap: wrap; }

/* ── Footer (identical to home) ─────────────────────────── */
footer { padding: clamp(48px,7vw,80px) clamp(20px,5vw,52px) clamp(28px,4vw,40px); border-top: 1px solid var(--border); }
.footer-inner { max-width: 1100px; margin: 0 auto; display: grid; grid-template-columns: 1.8fr 1fr 1fr 1fr; gap: clamp(32px,5vw,64px); margin-bottom: 48px; }
.footer-brand p { font-size: 14px; color: var(--text-muted); line-height: 1.7; margin-top: 14px; max-width: 280px; }
.footer-col h4 { font-size: 12px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--text-faint); margin-bottom: 14px; }
.footer-col a { display: block; font-size: 14px; color: var(--text-muted); padding: 4px 0; transition: color .2s; }
.footer-col a:hover { color: var(--text); }
.footer-bottom { max-width: 1100px; margin: 0 auto; padding-top: 24px; border-top: 1px solid var(--border); display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 12px; font-size: 13px; color: var(--text-faint); }
.footer-bottom a { color: var(--text-faint); transition: color .2s; }
.footer-bottom a:hover { color: var(--text-muted); }

/* ── Reveal ─────────────────────────────────────────────── */
.reveal { opacity: 0; transform: translateY(36px); transition: opacity .7s var(--ease), transform .7s var(--ease); }
.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; }

/* ── Responsive ─────────────────────────────────────────── */
@media (max-width: 1024px) { .footer-inner { grid-template-columns: 1fr 1fr; } }
@media (max-width: 768px) {
  .nav-links, .btn-ghost { display: none; }
  .nav-toggle { display: flex; }
  .footer-inner { grid-template-columns: 1fr; }
  .step-row { grid-template-columns: 1fr; gap: 10px; }
}
@media (max-width: 480px) { .guide-grid { grid-template-columns: 1fr; } }
