/* =============================================
   CaseStream Landing Page
   Dark editorial + electric teal accent
   Typography: Sora (headings) + DM Sans (body)
   ============================================= */

:root {
  --bg:        #0C0E14;
  --surface:   #13151D;
  --card:      #1a1b26;
  --border:    #252836;
  --accent:     #00D9B5;
  --accent-dim: rgba(0,217,181,0.12);
  --text:      #F5F3EE;
  --text-dim:  #7D7A8A;
  --text-mid:  #A9A7B8;
  --green:      #4ADE80;
  --red:        #F87171;
  --amber:      #FBBF24;
  --font-head: 'Sora', sans-serif;
  --font-body: 'DM Sans', sans-serif;
}

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

html {
  scroll-behavior: smooth;
  font-size: 16px;
}

body {
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-body);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

/* ---- Section scaffold ---- */
.section-label {
  font-family: var(--font-body);
  font-size: 0.75rem;
  font-weight: 500;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--accent);
  display: block;
  margin-bottom: 1rem;
}

.section-title {
  font-family: var(--font-head);
  font-size: clamp(2rem, 4vw, 3rem);
  font-weight: 700;
  line-height: 1.15;
  color: var(--text);
  margin-bottom: 1.25rem;
}

.section-body {
  font-size: 1.0625rem;
  color: var(--text-mid);
  line-height: 1.75;
  max-width: 580px;
}

/* =============================================
   HERO
   ============================================= */
.hero {
  min-height: 100vh;
  display: flex;
  align-items: center;
  padding: 6rem 5vw 4rem;
  border-bottom: 1px solid var(--border);
  position: relative;
  overflow: hidden;
}

.hero::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0; bottom: 0;
  background:
    radial-gradient(ellipse 60% 50% at 75% 50%, rgba(0,217,181,0.06) 0%, transparent 70%),
    radial-gradient(ellipse 40% 60% at 20% 80%, rgba(0,217,181,0.03) 0%, transparent 60%);
  pointer-events: none;
}

.hero-inner {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 4rem;
  align-items: center;
  max-width: 1280px;
  margin: 0 auto;
  width: 100%;
  position: relative;
}

.hero-left {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}

.hero-label {
  font-size: 0.8rem;
  font-weight: 500;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--accent);
  background: var(--accent-dim);
  border: 1px solid rgba(0,217,181,0.2);
  padding: 0.35rem 0.9rem;
  border-radius: 100px;
  display: inline-block;
  width: fit-content;
}

.hero-headline {
  font-family: var(--font-head);
  font-size: clamp(2.5rem, 5vw, 4.5rem);
  font-weight: 800;
  line-height: 1.05;
  color: var(--text);
  letter-spacing: -0.02em;
}

.hero-highlight {
  color: var(--accent);
  display: block;
}

.hero-body {
  font-size: 1.125rem;
  color: var(--text-mid);
  line-height: 1.75;
  max-width: 460px;
}

/* Data visualization */
.data-viz {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 2rem;
  position: relative;
}

.viz-label-top {
  font-size: 0.7rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--text-dim);
  margin-bottom: 1.5rem;
}

.viz-grid {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.viz-row {
  display: grid;
  grid-template-columns: 12px 1fr auto;
  align-items: center;
  gap: 0.75rem;
  padding: 0.65rem 0.75rem;
  background: var(--card);
  border-radius: 8px;
  border: 1px solid var(--border);
}

.viz-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  flex-shrink: 0;
}

.green-pulse {
  background: var(--green);
  box-shadow: 0 0 0 0 rgba(74,222,128,0.5);
  animation: pulse-green 2s infinite;
}

.teal-pulse {
  background: var(--accent);
  box-shadow: 0 0 0 0 rgba(0,217,181,0.5);
  animation: pulse-teal 2s infinite;
}

.fading {
  background: var(--text-dim);
  opacity: 0.4;
}

@keyframes pulse-green {
  0%   { box-shadow: 0 0 0 0 rgba(74,222,128,0.6); }
  70%  { box-shadow: 0 0 0 6px rgba(74,222,128,0); }
  100% { box-shadow: 0 0 0 0 rgba(74,222,128,0); }
}

@keyframes pulse-teal {
  0%   { box-shadow: 0 0 0 0 rgba(0,217,181,0.6); }
  70%  { box-shadow: 0 0 0 6px rgba(0,217,181,0); }
  100% { box-shadow: 0 0 0 0 rgba(0,217,181,0); }
}

.viz-text {
  font-size: 0.85rem;
  color: var(--text-mid);
  font-family: var(--font-body);
}

.viz-score {
  font-family: var(--font-head);
  font-size: 0.8rem;
  font-weight: 700;
  color: var(--text);
  width: 26px;
  text-align: right;
}

.viz-badge {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  margin-top: 1.25rem;
  font-size: 0.8rem;
  color: var(--text-dim);
  border-top: 1px solid var(--border);
  padding-top: 1rem;
}

.viz-badge-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--accent);
  box-shadow: 0 0 8px var(--accent);
  flex-shrink: 0;
  animation: pulse-teal 2s infinite;
}

.viz-legend {
  display: flex;
  gap: 1rem;
  margin-top: 0.5rem;
}

.legend-item {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  font-size: 0.7rem;
  color: var(--text-dim);
}

.legend-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
}

.legend-dot.green { background: var(--green); }
.legend-dot.muted { background: var(--text-dim); opacity: 0.4; }

/* =============================================
   OUTCOME
   ============================================= */
.outcome {
  padding: 6rem 5vw;
  border-bottom: 1px solid var(--border);
}

.outcome-header {
  max-width: 1280px;
  margin: 0 auto 4rem;
}

.outcome-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1.5px;
  background: var(--border);
  border: 1px solid var(--border);
  border-radius: 16px;
  overflow: hidden;
  max-width: 1280px;
  margin: 0 auto;
}

.outcome-card {
  background: var(--surface);
  padding: 2.5rem 2rem;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.outcome-card.accent-card {
  background: var(--accent-dim);
  border-left: 2px solid var(--accent);
}

.outcome-big {
  font-family: var(--font-head);
  font-size: clamp(2.5rem, 4vw, 3.5rem);
  font-weight: 800;
  color: var(--text);
  line-height: 1;
}

.outcome-label {
  font-size: 0.95rem;
  font-weight: 500;
  color: var(--text-mid);
  line-height: 1.4;
}

.outcome-note {
  font-size: 0.8rem;
  color: var(--text-dim);
  line-height: 1.6;
}

/* =============================================
   PIPELINE
   ============================================= */
.pipeline {
  padding: 6rem 5vw;
  border-bottom: 1px solid var(--border);
}

.pipeline-header {
  max-width: 1280px;
  margin: 0 auto 4rem;
}

.pipeline-steps {
  display: flex;
  align-items: flex-start;
  gap: 0;
  max-width: 1280px;
  margin: 0 auto 3rem;
}

.pipeline-step {
  flex: 1;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 2rem 1.75rem;
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.step-number {
  font-family: var(--font-head);
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  color: var(--accent);
  background: var(--accent-dim);
  width: 40px;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 8px;
}

.step-title {
  font-family: var(--font-head);
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--text);
}

.step-desc {
  font-size: 0.9rem;
  color: var(--text-mid);
  line-height: 1.65;
}

.pipeline-connector {
  width: 3rem;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  top: 20px;
}

.pipeline-connector::after {
  content: '';
  display: block;
  width: 100%;
  height: 2px;
  background: linear-gradient(90deg, var(--border), var(--accent), var(--border));
  border-radius: 2px;
}

.pipeline-categories {
  max-width: 1280px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  gap: 1rem;
  flex-wrap: wrap;
}

.cat-label {
  font-size: 0.8rem;
  color: var(--text-dim);
  white-space: nowrap;
}

.cat-list {
  display: flex;
  gap: 0.5rem;
  flex-wrap: wrap;
}

.cat-tag {
  font-size: 0.8rem;
  color: var(--text-mid);
  background: var(--surface);
  border: 1px solid var(--border);
  padding: 0.35rem 0.85rem;
  border-radius: 100px;
}

/* =============================================
   JURISDICTION
   ============================================= */
.jurisdiction {
  padding: 6rem 5vw;
  border-bottom: 1px solid var(--border);
  background: var(--surface);
}

.jurisdiction-inner {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 5rem;
  align-items: center;
  max-width: 1280px;
  margin: 0 auto;
}

.jurisdiction-left {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}

.jurisdiction-stats {
  display: flex;
  gap: 2.5rem;
  padding-top: 0.5rem;
}

.jstat-num {
  font-family: var(--font-head);
  font-size: 2.5rem;
  font-weight: 800;
  color: var(--accent);
  line-height: 1;
}

.jstat-desc {
  font-size: 0.8rem;
  color: var(--text-dim);
  margin-top: 0.25rem;
}

/* Market map */
.market-map {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 2rem;
}

.map-header {
  font-size: 0.7rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--text-dim);
  margin-bottom: 1.5rem;
}

.map-rows {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.map-row {
  display: grid;
  grid-template-columns: 140px 1fr auto auto;
  align-items: center;
  gap: 0.75rem;
}

.map-city {
  font-size: 0.85rem;
  color: var(--text-mid);
  white-space: nowrap;
}

.map-bar-wrap {
  background: var(--border);
  border-radius: 4px;
  height: 6px;
  overflow: hidden;
}

.map-bar {
  height: 100%;
  border-radius: 4px;
  width: 0;
  transition: width 1s ease;
}

/* Simulate widths via inline style in the template or keep static */
.map-row:nth-child(1) .map-bar { width: 94%; }
.map-row:nth-child(2) .map-bar { width: 89%; }
.map-row:nth-child(3) .map-bar { width: 71%; }
.map-row:nth-child(4) .map-bar { width: 65%; }
.map-row:nth-child(5) .map-bar { width: 43%; }

.map-bar.high   { background: var(--accent); }
.map-bar.med   { background: var(--amber); }
.map-bar.low   { background: var(--text-dim); opacity: 0.4; }

.map-score {
  font-family: var(--font-head);
  font-size: 0.8rem;
  font-weight: 700;
  width: 28px;
  text-align: right;
}

.high-text { color: var(--accent); }
.med-text  { color: var(--amber); }
.low-text  { color: var(--text-dim); }

.map-tag {
  font-size: 0.65rem;
  color: var(--text-dim);
  text-align: right;
}

/* =============================================
   MANIFESTO
   ============================================= */
.manifesto {
  padding: 7rem 5vw;
  border-bottom: 1px solid var(--border);
  background:
    radial-gradient(ellipse 70% 60% at 50% 0%, rgba(0,217,181,0.04) 0%, transparent 70%);
}

.manifesto-inner {
  max-width: 900px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  gap: 2.5rem;
}

.manifesto-quote {
  font-family: var(--font-head);
  font-size: clamp(1.5rem, 3vw, 2.25rem);
  font-weight: 600;
  line-height: 1.3;
  color: var(--text);
  border-left: 3px solid var(--accent);
  padding-left: 2rem;
  font-style: normal;
}

.manifesto-body {
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
}

.manifesto-body p {
  font-size: 1.0625rem;
  color: var(--text-mid);
  line-height: 1.8;
}

/* =============================================
   CLOSING
   ============================================= */
.closing {
  padding: 7rem 5vw;
  border-bottom: 1px solid var(--border);
}

.closing-inner {
  max-width: 800px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 2rem;
}

.closing-headline {
  font-family: var(--font-head);
  font-size: clamp(2.5rem, 5vw, 4rem);
  font-weight: 800;
  line-height: 1.1;
  color: var(--text);
  letter-spacing: -0.02em;
}

.closing-body {
  font-size: 1.0625rem;
  color: var(--text-mid);
  line-height: 1.75;
  max-width: 600px;
}

.closing-statement {
  background: var(--accent-dim);
  border: 1px solid rgba(0,217,181,0.2);
  border-radius: 12px;
  padding: 1.75rem 2rem;
  max-width: 640px;
}

.closing-statement p {
  font-size: 1rem;
  color: var(--text-mid);
  line-height: 1.75;
}

/* =============================================
   FOOTER
   ============================================= */
.footer {
  padding: 2.5rem 5vw;
}

.footer-inner {
  max-width: 1280px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  flex-wrap: wrap;
}

.footer-logo {
  font-family: var(--font-head);
  font-size: 1.25rem;
  font-weight: 700;
  color: var(--text);
  letter-spacing: -0.02em;
}

.footer-tagline {
  font-size: 0.8rem;
  color: var(--text-dim);
  margin-top: 0.2rem;
}

.footer-meta {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.75rem;
  color: var(--text-dim);
}

.footer-sep { color: var(--border); }

/* =============================================
   RESPONSIVE
   ============================================= */
@media (max-width: 900px) {
  .hero-inner {
    grid-template-columns: 1fr;
    gap: 3rem;
  }
  .hero-right { order: -1; }
  .outcome-grid {
    grid-template-columns: repeat(2, 1fr);
  }
  .pipeline-steps {
    flex-direction: column;
    align-items: stretch;
  }
  .pipeline-connector {
    width: auto;
    height: 2rem;
    transform: rotate(90deg) translateX(-50%);
    transform-origin: center;
    position: static;
    justify-content: center;
  }
  .pipeline-connector::after {
    width: 2px;
    height: 100%;
    background: linear-gradient(180deg, var(--border), var(--accent), var(--border));
  }
  .jurisdiction-inner {
    grid-template-columns: 1fr;
    gap: 3rem;
  }
  .map-row {
    grid-template-columns: 110px 1fr auto auto;
  }
}

@media (max-width: 600px) {
  .outcome-grid {
    grid-template-columns: 1fr;
  }
  .map-row {
    grid-template-columns: 90px 1fr auto;
  }
  .map-tag { display: none; }
  .hero-headline { font-size: 2.5rem; }
  .closing-headline { font-size: 2.25rem; }
}