/* ============================================================
   Cascade Analytica: Deep Ocean palette
   Navy + teal lead. Coral reserved for the primary call to action.
   ============================================================ */

:root {
  --primary: #12325A;   /* navy */
  --primary-700: #0d2748;
  --secondary: #0E8FA6; /* teal */
  --secondary-700: #0b7488;
  --sky: #2E8BD6;       /* lighter blue accent from palette mock */
  --accent: #F0563F;    /* coral, true CTA only */
  --accent-700: #d8482f;
  --ink: #0B1B2B;
  --steel: #6B7A8D;
  --mist: #E6EEF3;
  --mist-200: #f2f6fa;
  --paper: #FFFFFF;

  --text: #1c2b3a;
  --text-soft: #4a5b6b;

  --radius: 16px;
  --radius-sm: 10px;
  --shadow-sm: 0 1px 2px rgba(11, 27, 43, 0.06), 0 4px 16px rgba(11, 27, 43, 0.06);
  --shadow-md: 0 12px 40px rgba(11, 27, 43, 0.12);
  --shadow-lg: 0 30px 80px rgba(11, 27, 43, 0.22);

  --max: 1140px;
  --gap: clamp(1.25rem, 4vw, 2.5rem);

  --font: "Manrope", system-ui, -apple-system, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
}

/* ---------- base ---------- */
* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: var(--font);
  color: var(--text);
  background: var(--paper);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

h1, h2, h3 { color: var(--ink); line-height: 1.12; margin: 0 0 .5em; letter-spacing: -0.02em; }
p { margin: 0 0 1rem; }
a { color: var(--secondary-700); text-decoration: none; }

img, svg { display: block; max-width: 100%; }

.container { width: 100%; max-width: var(--max); margin-inline: auto; padding-inline: clamp(1.25rem, 5vw, 2.5rem); }
.narrow { max-width: 760px; }
.center { text-align: center; margin-inline: auto; }

.skip-link {
  position: absolute; left: -999px; top: 0;
  background: var(--accent); color: #fff; padding: .6rem 1rem; border-radius: 0 0 8px 0; z-index: 200;
}
.skip-link:focus { left: 0; }

/* ---------- buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center;
  font-weight: 700; font-size: 1rem; line-height: 1;
  padding: .95rem 1.5rem; border-radius: 999px;
  border: 2px solid transparent; cursor: pointer;
  transition: transform .15s ease, box-shadow .2s ease, background .2s ease, color .2s ease, border-color .2s ease;
  white-space: nowrap;
}
.btn-sm { padding: .7rem 1.15rem; font-size: .95rem; }

.btn-accent { background: var(--accent); color: #fff; box-shadow: 0 8px 24px rgba(240, 86, 63, 0.32); }
.btn-accent:hover { background: #d8482f; transform: translateY(-2px); box-shadow: 0 12px 30px rgba(240, 86, 63, 0.40); }

.btn-ghost { background: transparent; color: var(--primary); border-color: rgba(18, 50, 90, 0.25); }
.btn-ghost:hover { border-color: var(--primary); transform: translateY(-2px); }

.btn-ghost-light { color: #fff; border-color: rgba(255,255,255,0.4); }
.btn-ghost-light:hover { border-color: #fff; background: rgba(255,255,255,0.08); }

/* keyboard focus visibility (WCAG 2.4.7) */
a:focus-visible,
.btn:focus-visible,
.nav-toggle:focus-visible,
.skip-link:focus-visible {
  outline: 3px solid var(--sky);
  outline-offset: 3px;
  border-radius: 6px;
}
.cta-section .btn:focus-visible,
.section-dark a:focus-visible,
.btn-ghost-light:focus-visible { outline-color: #fff; }

/* ---------- header ---------- */
.site-header {
  position: sticky; top: 0; z-index: 100;
  background: rgba(255, 255, 255, 0.82);
  backdrop-filter: saturate(160%) blur(12px);
  -webkit-backdrop-filter: saturate(160%) blur(12px);
  border-bottom: 1px solid transparent;
  transition: border-color .2s ease, box-shadow .2s ease, background .2s ease;
}
.site-header.scrolled { border-color: var(--mist); box-shadow: var(--shadow-sm); }

.header-inner { display: flex; align-items: center; gap: 1.5rem; height: 72px; }

.brand { display: inline-flex; align-items: center; gap: .6rem; font-weight: 800; }
.brand-logo { height: 40px; width: auto; display: block; }
.footer-mark { height: 36px; width: auto; }
.brand-name { color: var(--ink); font-size: 1.18rem; letter-spacing: -0.02em; }
.brand-name-thin { font-weight: 500; color: var(--steel); }
.brand-name.light { color: #fff; }
.brand-name.light .brand-name-thin { color: var(--mist); }

.nav { display: flex; gap: 1.6rem; margin-left: auto; }
.nav a { color: var(--text-soft); font-weight: 600; font-size: .98rem; position: relative; }
.nav a::after {
  content: ""; position: absolute; left: 0; bottom: -6px; height: 2px; width: 0;
  background: var(--secondary); transition: width .2s ease;
}
.nav a:hover, .nav a:focus-visible { color: var(--ink); }
.nav a:hover::after, .nav a:focus-visible::after { width: 100%; }

.header-actions { margin-left: .2rem; }

.nav-toggle {
  display: none; flex-direction: column; gap: 5px; justify-content: center;
  width: 44px; height: 44px; margin-left: auto;
  background: none; border: none; cursor: pointer; padding: 0;
}
.nav-toggle span { display: block; height: 2.5px; width: 24px; background: var(--ink); border-radius: 2px; transition: transform .25s ease, opacity .2s ease; }
.nav-toggle[aria-expanded="true"] span:nth-child(1) { transform: translateY(7.5px) rotate(45deg); }
.nav-toggle[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
.nav-toggle[aria-expanded="true"] span:nth-child(3) { transform: translateY(-7.5px) rotate(-45deg); }

.mobile-nav { display: none; flex-direction: column; gap: .25rem; padding: .5rem clamp(1.25rem, 5vw, 2.5rem) 1.25rem; border-top: 1px solid var(--mist); background: #fff; }
.mobile-nav a { color: var(--text); font-weight: 600; padding: .7rem 0; }
.mobile-nav .btn { margin-top: .5rem; }

/* ---------- hero ---------- */
.hero {
  position: relative; overflow: hidden;
  background:
    radial-gradient(900px 500px at 78% -10%, rgba(14, 143, 166, 0.16), transparent 60%),
    radial-gradient(700px 500px at 100% 110%, rgba(46, 139, 214, 0.10), transparent 55%),
    var(--mist-200);
  padding: clamp(3rem, 7vw, 6rem) 0 clamp(3.5rem, 8vw, 7rem);
}
.hero-grid { display: grid; grid-template-columns: 1.05fr .95fr; gap: clamp(2rem, 5vw, 4rem); align-items: center; }

.eyebrow {
  text-transform: uppercase; letter-spacing: .14em; font-size: .8rem; font-weight: 700;
  color: var(--secondary-700); margin: 0 0 1rem;
}
.eyebrow-center { text-align: center; }
.eyebrow-light { color: #6fd0e3; }

.hero h1 { font-size: clamp(2.3rem, 5.2vw, 3.7rem); font-weight: 800; }
.lede { font-size: clamp(1.05rem, 1.6vw, 1.22rem); color: var(--text-soft); max-width: 36ch; }
.hero-cta { display: flex; flex-wrap: wrap; gap: .9rem; margin-top: 1.8rem; }
.hero-cta.center { justify-content: center; }

/* hero product mock */
.hero-visual { position: relative; }
.mock-card {
  position: relative; z-index: 2;
  background: #fff; border-radius: 20px; padding: 1.4rem;
  box-shadow: var(--shadow-lg); border: 1px solid var(--mist);
}
.mock-label { text-transform: uppercase; letter-spacing: .12em; font-size: .72rem; font-weight: 700; color: var(--steel); margin: 0 0 .9rem; }

.mock-question { display: flex; gap: .7rem; align-items: flex-start; margin-bottom: .9rem; }
.mock-avatar {
  flex: none; width: 28px; height: 28px; border-radius: 50%;
  background: var(--primary); color: #fff; font-weight: 700; font-size: .8rem;
  display: grid; place-items: center;
}
.mock-question p { margin: 0; font-weight: 600; color: var(--ink); }

.mock-answer {
  background: var(--mist-200); border-radius: 12px; padding: .9rem 1rem; margin-bottom: 1.1rem;
  border-left: 3px solid var(--secondary);
}
.mock-answer p { margin: 0 0 .65rem; font-size: .95rem; color: var(--text); }
.mock-answer strong { color: var(--secondary-700); }
.mock-citations { display: flex; flex-wrap: wrap; gap: .4rem; }
.cite-pill {
  font-size: .72rem; font-weight: 600; color: var(--steel);
  background: #fff; border: 1px solid var(--mist); padding: .2rem .55rem; border-radius: 999px;
}

.mock-kpi { display: flex; align-items: flex-end; justify-content: space-between; gap: 1rem; padding-top: .4rem; border-top: 1px solid var(--mist); }
.mock-kpi-label { text-transform: uppercase; letter-spacing: .1em; font-size: .7rem; font-weight: 700; color: var(--steel); margin: .6rem 0 .2rem; }
.mock-kpi-value { font-size: 2rem; font-weight: 800; color: var(--primary); margin: 0; line-height: 1; }
.mock-trend { font-size: .85rem; font-weight: 700; color: var(--secondary-700); vertical-align: middle; }
.mock-bars { display: flex; align-items: flex-end; gap: 7px; height: 56px; }
.mock-bars span { width: 16px; background: var(--primary); border-radius: 5px 5px 0 0; }
.mock-bars .bar-teal { background: var(--secondary); }
.mock-bars .bar-sky { background: var(--sky); }

.mock-glow {
  position: absolute; inset: -8% -6% -12% -6%; z-index: 1;
  background: radial-gradient(closest-side, rgba(14,143,166,0.22), transparent 75%);
  filter: blur(10px);
}

/* ---------- sections ---------- */
.section { padding: clamp(3.5rem, 8vw, 6.5rem) 0; }
.section-tint { background: var(--mist-200); }
.section-title { font-size: clamp(1.7rem, 3.4vw, 2.5rem); font-weight: 800; }
.section-title.center { text-align: center; }
.section-title.light { color: #fff; }
.section-lede { font-size: clamp(1.02rem, 1.5vw, 1.15rem); color: var(--text-soft); }
.section-lede.center { max-width: 58ch; margin-inline: auto; }
.section-lede.light { color: var(--mist); }

/* split (solution) */
.split { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(2rem, 5vw, 4rem); align-items: center; }
.check-list { list-style: none; padding: 0; margin: 1.4rem 0 0; }
.check-list li { position: relative; padding-left: 1.9rem; margin-bottom: .8rem; color: var(--text); font-weight: 500; }
.check-list li::before {
  content: ""; position: absolute; left: 0; top: .35em; width: 18px; height: 18px; border-radius: 50%;
  background: var(--secondary);
  -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath fill='white' d='M9 16.2 4.8 12l-1.4 1.4L9 19 21 7l-1.4-1.4z'/%3E%3C/svg%3E") center/14px no-repeat;
  mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath fill='white' d='M9 16.2 4.8 12l-1.4 1.4L9 19 21 7l-1.4-1.4z'/%3E%3C/svg%3E") center/14px no-repeat;
}

/* tri-layer: three co-equal pillars inside one labeled intelligence-layer frame */
.tri-layer { display: flex; flex-direction: column; gap: 16px; }

.tri-frame {
  position: relative;
  border: 1px solid var(--mist);
  border-radius: var(--radius);
  background: linear-gradient(180deg, #ffffff, var(--mist-200));
  box-shadow: var(--shadow-md);
  padding: 1.9rem 1.1rem 1.2rem;
}
.tri-frame-label {
  position: absolute; top: -0.8rem; left: 1.1rem; margin: 0;
  padding: .4rem .9rem;
  background: linear-gradient(120deg, var(--primary), var(--secondary));
  color: #fff; font-size: .72rem; font-weight: 700; letter-spacing: .08em;
  text-transform: uppercase; border-radius: 999px;
  box-shadow: 0 6px 16px rgba(14, 143, 166, 0.30);
}

.tri-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; align-items: stretch; }
.tri-pillar {
  display: flex; flex-direction: column; gap: .55rem;
  background: var(--paper);
  border: 1px solid var(--mist);
  border-top: 3px solid var(--secondary);
  border-radius: var(--radius-sm);
  padding: 1.1rem 1rem 1.15rem;
  box-shadow: var(--shadow-sm);
  transition: transform .18s ease, box-shadow .2s ease;
}
.tri-pillar:hover { transform: translateY(-3px); box-shadow: var(--shadow-md); }

/* three co-equal pillars, each with an accent from the data-viz blues (coral stays for CTAs) */
.tri-pillar:nth-child(1) { border-top-color: var(--primary); }
.tri-pillar:nth-child(2) { border-top-color: var(--secondary); }
.tri-pillar:nth-child(3) { border-top-color: var(--sky); }

.tri-icon {
  display: inline-flex; align-items: center; justify-content: center;
  width: 42px; height: 42px; border-radius: 11px;
  color: #fff; box-shadow: var(--shadow-sm);
}
.tri-icon svg { width: 22px; height: 22px; stroke-width: 2; }
.tri-pillar:nth-child(1) .tri-icon { background: var(--primary); }
.tri-pillar:nth-child(2) .tri-icon { background: var(--secondary); }
.tri-pillar:nth-child(3) .tri-icon { background: var(--sky); }

.tri-pillar-label { margin: 0; color: var(--ink); font-weight: 700; font-size: 1rem; line-height: 1.25; }
.tri-pillar-line { margin: 0; color: var(--text-soft); font-size: .88rem; line-height: 1.45; }

.tri-feed { display: flex; flex-direction: column; align-items: center; gap: .5rem; }
.tri-feed-arrow {
  display: inline-flex; align-items: center; justify-content: center;
  width: 36px; height: 36px; border-radius: 50%;
  background: linear-gradient(135deg, var(--secondary), var(--sky));
  color: #fff; box-shadow: 0 8px 18px rgba(46, 139, 214, 0.35);
}
.tri-feed-arrow svg { width: 18px; height: 18px; stroke-width: 2.25; }
.tri-feed-row {
  display: flex; flex-wrap: wrap; align-items: center; justify-content: center; gap: 8px;
  width: 100%;
  background: var(--paper);
  border: 1px solid var(--mist);
  border-radius: var(--radius-sm);
  box-shadow: var(--shadow-sm);
  padding: .85rem 1rem;
}
.tri-feed-label { color: var(--steel); font-size: .76rem; font-weight: 700; text-transform: uppercase; letter-spacing: .09em; }
.tri-source {
  background: var(--mist-200); border: 1px dashed var(--steel); color: var(--text-soft);
  border-radius: 999px; padding: .38rem .85rem; font-size: .84rem; font-weight: 600;
}

/* card grid */
.card-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1.25rem; margin-top: 2.5rem; }
.card {
  background: #fff; border: 1px solid var(--mist); border-top: 3px solid transparent;
  border-radius: var(--radius);
  padding: 1.6rem; box-shadow: var(--shadow-sm);
  transition: transform .2s ease, box-shadow .2s ease;
}
.card:hover { transform: translateY(-4px); box-shadow: var(--shadow-md); }
.card-icon {
  width: 46px; height: 46px; border-radius: 12px; display: grid; place-items: center;
  color: #fff; margin-bottom: 1.1rem; box-shadow: var(--shadow-sm);
}
.card-icon svg { width: 24px; height: 24px; stroke-width: 2; }

/* color-code the cards from the data-viz blues (coral stays for CTAs) */
.card:nth-child(3n+1) { border-top-color: var(--primary); }
.card:nth-child(3n+1) .card-icon { background: var(--primary); }
.card:nth-child(3n+2) { border-top-color: var(--secondary); }
.card:nth-child(3n+2) .card-icon { background: var(--secondary); }
.card:nth-child(3n)   { border-top-color: var(--sky); }
.card:nth-child(3n)   .card-icon { background: var(--sky); }

.card h3 { font-size: 1.18rem; }
.card p { margin: 0; color: var(--text-soft); font-size: .98rem; }

/* how it works (dark) */
.section-dark { background: var(--primary); position: relative; overflow: hidden; }
.section-dark::before {
  content: ""; position: absolute; inset: 0;
  background: radial-gradient(700px 400px at 85% -10%, rgba(14,143,166,0.3), transparent 60%);
}
.section-dark > .container { position: relative; }
.steps { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1.5rem; margin-top: 2.75rem; }
.step {
  background: rgba(255,255,255,0.05); border: 1px solid rgba(255,255,255,0.12);
  border-top: 3px solid var(--secondary);
  border-radius: var(--radius); padding: 1.75rem;
}
.step:nth-child(2) { border-top-color: var(--sky); }
.step-num {
  display: inline-grid; place-items: center; width: 44px; height: 44px; border-radius: 12px;
  background: linear-gradient(135deg, var(--secondary), var(--sky));
  color: #fff; font-weight: 800; font-size: 1.1rem; margin-bottom: 1rem;
  box-shadow: var(--shadow-sm);
}
.step h3 { color: #fff; font-size: 1.2rem; }
.step p { color: var(--mist); margin: 0; }

/* trust band */
.trust-band { background: var(--mist-200); }

/* cta */
.cta-section { background: linear-gradient(125deg, var(--primary-700), var(--secondary-700)); }

/* footer */
.site-footer { background: var(--ink); color: var(--mist); padding: 2.5rem 0; }
.footer-inner { display: flex; flex-direction: column; gap: .5rem; align-items: center; text-align: center; }
.footer-tag { color: #8A99AB; margin: .3rem 0 0; }
.footer-legal { color: #8A99AB; font-size: .85rem; margin: .4rem 0 0; }

/* reveal animation */
.reveal { opacity: 0; transform: translateY(18px); transition: opacity .6s ease, transform .6s ease; }
.reveal.in { opacity: 1; transform: none; }

/* ---------- responsive ---------- */
@media (max-width: 920px) {
  .hero-grid { grid-template-columns: 1fr; }
  .hero-visual { order: -1; max-width: 460px; }
  .lede { max-width: none; }
  .split { grid-template-columns: 1fr; }
  .tri-grid { grid-template-columns: 1fr; }
  .tri-pillar { padding: 1rem; }
  .tri-frame { padding: 1.4rem 1rem 1rem; }
  .card-grid { grid-template-columns: repeat(2, 1fr); }
  .steps { grid-template-columns: 1fr; }
}

@media (max-width: 720px) {
  .nav, .header-actions { display: none; }
  .nav-toggle { display: flex; }
  .mobile-nav.open { display: flex; }
  .card-grid { grid-template-columns: 1fr; }
  .brand-logo { height: 34px; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .reveal { opacity: 1; transform: none; transition: none; }
  .btn:hover, .card:hover, .tri-pillar:hover { transform: none; }
}
