/*
 * FM Digital Solutions — Find My Nursery Case Study Styles
 * Accent: --green (#5BBF2A)
 * Depends on: tokens.css, global.css
 */

/* ── Case study nav back ── */
.cs-nav-back {
  display:         flex;
  align-items:     center;
  gap:             6px;
  font-family:     var(--font-mono);
  font-size:       11px;
  font-weight:     600;
  letter-spacing:  .06em;
  text-transform:  uppercase;
  color:           var(--fg-subtle);
  text-decoration: none;
  transition:      color .15s;
}
.cs-nav-back:hover { color: var(--fg-muted); }
.cs-nav-back svg   { width: 14px; height: 14px; }

/* ── Hero ── */
.cs-hero {
  padding-top:    calc(var(--nav-h) + 5.5rem);
  padding-bottom: 5rem;
  position:       relative;
  overflow:       hidden;
  border-bottom:  1px solid var(--border);
}
.cs-hero-glow {
  position:       absolute;
  top:            -80px;
  right:          -120px;
  width:          700px;
  height:         700px;
  background:     radial-gradient(ellipse, rgba(91,191,42,.1) 0%, transparent 60%);
  pointer-events: none;
}
.cs-eyebrow {
  display:       flex;
  align-items:   center;
  gap:           10px;
  margin-bottom: 1.75rem;
  flex-wrap:     wrap;
}
.cs-tag {
  font-family:    var(--font-mono);
  font-size:      10.5px;
  font-weight:    600;
  letter-spacing: .08em;
  text-transform: uppercase;
  padding:        .25rem .7rem;
  border-radius:  20px;
  display:        inline-flex;
  align-items:    center;
}
.cs-tag-green  { background: rgba(91,191,42,.12); color: var(--green); border: 1px solid rgba(91,191,42,.25); }
.cs-tag-purple { background: rgba(107,61,150,.15); color: var(--purple-light); border: 1px solid rgba(107,61,150,.3); }
.cs-tag-muted  { background: var(--surface-3); color: var(--fg-subtle); border: 1px solid var(--border); }

.cs-hero-layout {
  display:               grid;
  grid-template-columns: 1fr 1fr;
  gap:                   5rem;
  align-items:           start;
}
@media (max-width: 900px) { .cs-hero-layout { grid-template-columns: 1fr; gap: 3rem; } }

.cs-h1 {
  font-family:    var(--font-head);
  font-weight:    800;
  font-size:      clamp(3.5rem, 9vw, 7rem);
  line-height:    .95;
  letter-spacing: -.05em;
  color:          #fff;
  margin-bottom:  1rem;
}
.cs-h1 em { font-style: normal; color: var(--green); }
.cs-hero-sub {
  font-size:     1.05rem;
  color:         var(--fg-muted);
  line-height:   1.7;
  max-width:     46ch;
  margin-bottom: 2rem;
}
.cs-stack-row { display: flex; flex-wrap: wrap; gap: .4rem; margin-bottom: 2rem; }
.cs-stag {
  font-family:    var(--font-mono);
  font-size:      10px;
  font-weight:    600;
  letter-spacing: .06em;
  text-transform: uppercase;
  background:     var(--surface-2);
  border:         1px solid var(--border);
  color:          var(--fg-subtle);
  padding:        .2rem .6rem;
  border-radius:  4px;
}
.cs-hero-links { display: flex; align-items: center; gap: .75rem; flex-wrap: wrap; }

/* ── Browser mockup (hero right) ── */
.browser-mock {
  border-radius: 12px;
  overflow:      hidden;
  border:        1px solid var(--border);
  box-shadow:    0 40px 80px rgba(0,0,0,.5);
}
.browser-bar {
  height:        32px;
  background:    var(--surface-2);
  border-bottom: 1px solid var(--border);
  display:       flex;
  align-items:   center;
  padding:       0 12px;
  gap:           7px;
}
.bd { width: 10px; height: 10px; border-radius: 50%; }
.bd-r { background: #FF5F57; }
.bd-y { background: #FFBD2E; }
.bd-g { background: #28CA41; }
.url-bar {
  flex:            1;
  height:          18px;
  background:      var(--surface-3);
  border-radius:   4px;
  margin:          0 8px;
  display:         flex;
  align-items:     center;
  justify-content: center;
  font-family:     var(--font-mono);
  font-size:       9px;
  color:           var(--fg-subtle);
}
.browser-screen {
  background:  var(--surface);
  aspect-ratio: 16/9;
  display:     flex;
  flex-direction: column;
  padding:     1rem;
  gap:         .5rem;
}
.bsc-search {
  height:        28px;
  background:    var(--surface-2);
  border:        1px solid var(--border);
  border-radius: 6px;
  display:       flex;
  align-items:   center;
  padding:       0 10px;
  gap:           8px;
}
.bsc-icon  { color: var(--green); font-size: 10px; }
.bsc-text  { font-family: var(--font-mono); font-size: 9px; color: var(--fg-subtle); }
.bsc-grid  { display: grid; grid-template-columns: 1fr 1fr 1fr; gap: 6px; flex: 1; }
.bsc-card  { background: var(--surface-2); border: 1px solid var(--border); border-radius: 6px; padding: 8px; display: flex; flex-direction: column; gap: 4px; }
.bsc-card-top { height: 18px; background: var(--surface-3); border-radius: 3px; }
.bsc-card-line { height: 4px; background: var(--border); border-radius: 2px; }
.bsc-card-line.w60 { width: 60%; }
.bsc-card-line.w80 { width: 80%; }
.bsc-card-badge {
  font-family:    var(--font-mono);
  font-size:      7px;
  font-weight:    600;
  color:          var(--green);
  letter-spacing: .04em;
  margin-top:     2px;
}

/* ── Stat band ── */
.stat-band-fmn {
  background:    var(--surface);
  border-top:    1px solid var(--border);
  border-bottom: 1px solid var(--border);
}
.stat-band-inner {
  display:         flex;
  align-items:     stretch;
  overflow-x:      auto;
  scrollbar-width: none;
}
.stat-band-inner::-webkit-scrollbar { display: none; }
.sb-cell {
  flex:           1;
  min-width:      140px;
  padding:        1.5rem 2.5rem;
  display:        flex;
  flex-direction: column;
  gap:            5px;
}
.sb-cell + .sb-cell { border-left: 1px solid var(--border); }
.sb-num {
  font-family:        var(--font-head);
  font-weight:        800;
  font-size:          clamp(1.8rem, 3.5vw, 2.6rem);
  letter-spacing:     -.04em;
  line-height:        1;
  color:              #fff;
  font-variant-numeric: tabular-nums;
}
.sb-green  { color: var(--green); }
.sb-cyan   { color: var(--cyan); }
.sb-lime   { color: var(--lime); }
.sb-purple { color: var(--purple-light); }
.sb-lbl {
  font-family:    var(--font-mono);
  font-size:      10px;
  font-weight:    600;
  letter-spacing: .08em;
  text-transform: uppercase;
  color:          var(--fg-subtle);
}

/* ── Section chrome ── */
.cs-section { padding-block: 5.5rem; border-top: 1px solid var(--border); }
.cs-slabel {
  font-family:    var(--font-mono);
  font-size:      10.5px;
  font-weight:    600;
  letter-spacing: .1em;
  text-transform: uppercase;
  color:          var(--fg-subtle);
  display:        flex;
  align-items:    center;
  gap:            10px;
  margin-bottom:  2.5rem;
}
.cs-slabel::after { content: ''; flex: 1; height: 1px; background: var(--border); }
.cs-sn    { color: var(--green); margin-right: 4px; }
.cs-h2 {
  font-family:    var(--font-head);
  font-weight:    800;
  font-size:      clamp(1.8rem, 4vw, 2.8rem);
  letter-spacing: -.04em;
  line-height:    1.05;
  color:          #fff;
  text-wrap:      balance;
}

/* ── Two-col ── */
.cs-two-col { display: grid; grid-template-columns: 1fr 1fr; gap: 4rem; align-items: start; }
@media (max-width: 800px) { .cs-two-col { grid-template-columns: 1fr; gap: 2.5rem; } }
.cs-lead-p { color: var(--fg-muted); line-height: 1.75; margin-top: 1rem; max-width: 50ch; }

/* ── Pain list ── */
.pain-list { display: flex; flex-direction: column; gap: .6rem; }
.pain-item {
  display:       flex;
  align-items:   flex-start;
  gap:           .75rem;
  background:    var(--surface);
  border:        1px solid var(--border);
  border-radius: 8px;
  padding:       .9rem 1.1rem;
}
.pain-dot {
  width:       6px;
  height:      6px;
  border-radius: 50%;
  background:  rgba(255,80,80,.6);
  flex-shrink: 0;
  margin-top:  7px;
}
.pain-item strong { color: var(--fg); font-weight: 600; display: block; margin-bottom: 2px; font-size: .875rem; }
.pain-item p      { font-size: .875rem; color: var(--fg-muted); line-height: 1.5; }

/* ── Feature marquee ── */
.marquee-wrap {
  display:        flex;
  flex-direction: column;
  gap:            1rem;
  overflow:       hidden;
  -webkit-mask-image: linear-gradient(90deg, transparent, #000 6%, #000 94%, transparent);
  mask-image:     linear-gradient(90deg, transparent, #000 6%, #000 94%, transparent);
}
.marquee-row { display: flex; }
.m-inner {
  display:   flex;
  gap:       1rem;
  animation: mq-fwd 30s linear infinite;
}
.marquee-row.rev .m-inner { animation: mq-rev 30s linear infinite; }
.marquee-wrap:hover .m-inner { animation-play-state: paused; }
@keyframes mq-fwd { 0% { transform: translateX(0); }    100% { transform: translateX(-50%); } }
@keyframes mq-rev { 0% { transform: translateX(-50%); } 100% { transform: translateX(0); } }
.f-card {
  flex-shrink:   0;
  width:         320px;
  background:    var(--surface);
  border:        1px solid var(--border);
  border-radius: 10px;
  padding:       1.5rem;
  position:      relative;
  overflow:      hidden;
}
@media (max-width: 640px) { .f-card { width: 260px; } }
.f-card::before { content: ''; position: absolute; top: 0; left: 0; right: 0; height: 2px; }
.fc-g::before { background: var(--green); }
.fc-p::before { background: var(--purple); }
.fc-c::before { background: var(--cyan); }
.fc-l::before { background: var(--lime); }
.f-card h3    { font-family: var(--font-head); font-weight: 700; font-size: .95rem; color: #fff; margin-bottom: .5rem; letter-spacing: -.01em; }
.f-card p     { font-size: .875rem; color: var(--fg-muted); line-height: 1.6; }
.fc-mono {
  font-family:    var(--font-mono);
  font-size:      9px;
  font-weight:    600;
  letter-spacing: .07em;
  text-transform: uppercase;
  color:          var(--fg-subtle);
  margin-bottom:  .6rem;
}

/* ── Growth section ── */
.growth-section {
  background:  var(--surface);
  padding-block: 5.5rem;
  border-top:  1px solid var(--border);
}
.growth-layout {
  display:               grid;
  grid-template-columns: 1fr 1.3fr;
  gap:                   5rem;
  align-items:           center;
}
@media (max-width: 900px) { .growth-layout { grid-template-columns: 1fr; gap: 3rem; } }
.growth-big {
  font-family:    var(--font-head);
  font-weight:    800;
  font-size:      clamp(4rem, 10vw, 7rem);
  letter-spacing: -.05em;
  color:          var(--green);
  line-height:    1;
}
.growth-sub {
  font-family:    var(--font-mono);
  font-size:      11px;
  font-weight:    600;
  letter-spacing: .06em;
  text-transform: uppercase;
  color:          var(--fg-subtle);
  margin-top:     .5rem;
}
.growth-text p { color: var(--fg-muted); line-height: 1.75; margin-top: 1rem; max-width: 44ch; }

/* growth chart */
.chart-bars {
  display:     flex;
  align-items: flex-end;
  gap:         10px;
  height:      180px;
}
.bar-col { flex: 1; display: flex; flex-direction: column; align-items: center; gap: 6px; }
.bar {
  width:         100%;
  border-radius: 5px 5px 0 0;
  background:    linear-gradient(180deg, var(--green) 0%, rgba(91,191,42,.25) 100%);
  position:      relative;
  min-height:    4px;
  transition:    opacity .2s;
}
.bar.peak { background: linear-gradient(180deg, var(--lime) 0%, rgba(91,191,42,.5) 100%); }
.bar:hover { opacity: .8; }
.bar-val {
  position:  absolute;
  top:       -22px;
  left:      50%;
  transform: translateX(-50%);
  font-family: var(--font-head);
  font-weight: 700;
  font-size:  10px;
  color:      #fff;
  white-space: nowrap;
}
.bar-lbl {
  font-family:    var(--font-mono);
  font-size:      9px;
  font-weight:    600;
  letter-spacing: .05em;
  text-transform: uppercase;
  color:          var(--fg-subtle);
}
.chart-note {
  font-family:    var(--font-mono);
  font-size:      9.5px;
  color:          var(--fg-subtle);
  letter-spacing: .04em;
  margin-top:     1.25rem;
  text-transform: uppercase;
}

/* ── Profile / school card section ── */
.profile-layout {
  display:               grid;
  grid-template-columns: 1fr 1fr;
  gap:                   4rem;
  align-items:           center;
}
@media (max-width: 900px) { .profile-layout { grid-template-columns: 1fr; gap: 3rem; } }
.profile-text p { color: var(--fg-muted); line-height: 1.75; margin-top: 1rem; max-width: 44ch; }

.check-list { list-style: none; display: flex; flex-direction: column; gap: .5rem; margin-top: 1.25rem; }
.check-list li {
  font-size:   .875rem;
  color:       var(--fg-muted);
  display:     flex;
  align-items: flex-start;
  gap:         .5rem;
  line-height: 1.5;
}
.check-list li::before { content: '→'; color: var(--green); flex-shrink: 0; }

/* school card mock */
.school-card-mock {
  background:    var(--surface);
  border:        1px solid var(--border);
  border-radius: 10px;
  overflow:      hidden;
}
.sc-header {
  padding:       1rem 1.25rem;
  border-bottom: 1px solid var(--border);
  display:       flex;
  align-items:   center;
  justify-content: space-between;
}
.sc-name   { font-family: var(--font-head); font-weight: 700; font-size: .9rem; color: #fff; }
.sc-tier   { font-family: var(--font-mono); font-size: 8px; font-weight: 600; text-transform: uppercase; letter-spacing: .07em; background: rgba(91,191,42,.15); color: var(--green); border: 1px solid rgba(91,191,42,.25); padding: 2px 7px; border-radius: 3px; }
.sc-body   { padding: 1.25rem; display: flex; flex-direction: column; gap: .6rem; }
.sc-row    { display: flex; align-items: center; justify-content: space-between; }
.sc-lbl    { font-family: var(--font-mono); font-size: 9px; font-weight: 600; letter-spacing: .06em; text-transform: uppercase; color: var(--fg-subtle); }
.sc-val    { font-family: var(--font-head); font-weight: 700; font-size: .85rem; color: var(--green); }
.sc-sep    { height: 1px; background: var(--border); }
.sc-stats  { display: flex; gap: 1.25rem; padding-top: .5rem; }
.sc-stat   { display: flex; flex-direction: column; gap: 2px; }
.sc-stat-n { font-family: var(--font-head); font-weight: 800; font-size: 1.1rem; letter-spacing: -.04em; color: #fff; font-variant-numeric: tabular-nums; }
.sc-stat-l { font-family: var(--font-mono); font-size: 8px; font-weight: 600; letter-spacing: .06em; text-transform: uppercase; color: var(--fg-subtle); }
.sc-stars  { display: flex; gap: 3px; margin-top: .25rem; }
.sc-star   { color: #FBBF24; font-size: 11px; }

/* ── Results: ticker + KPI ── */
.cs-results-layout { display: grid; grid-template-columns: 1fr 1fr; gap: 5rem; align-items: start; }
@media (max-width: 800px) { .cs-results-layout { grid-template-columns: 1fr; gap: 3rem; } }
.cs-results-text p { color: var(--fg-muted); line-height: 1.75; margin-top: 1rem; max-width: 46ch; }

/* ticker */
.ticker-outer { overflow: hidden; border: 1px solid var(--border); border-radius: 8px; background: var(--surface); margin-top: 2rem; }
.ticker-track {
  display:   flex;
  animation: ticker-fwd 18s linear infinite;
}
.ticker-track:hover { animation-play-state: paused; }
@keyframes ticker-fwd { 0% { transform: translateX(0); } 100% { transform: translateX(-50%); } }
.t-item {
  flex-shrink:   0;
  padding:       .9rem 1.75rem;
  border-right:  1px solid var(--border);
  display:       flex;
  flex-direction: column;
  gap:           3px;
}
.t-num {
  font-family:        var(--font-head);
  font-weight:        800;
  font-size:          1.4rem;
  letter-spacing:     -.04em;
  color:              #fff;
  white-space:        nowrap;
  font-variant-numeric: tabular-nums;
}
.t-g { color: var(--green); }
.t-c { color: var(--cyan); }
.t-l { color: var(--lime); }
.t-p { color: var(--purple-light); }
.t-lbl { font-family: var(--font-mono); font-size: 8.5px; font-weight: 600; letter-spacing: .07em; text-transform: uppercase; color: var(--fg-subtle); white-space: nowrap; }

/* KPI grid */
.kpi-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 1rem; }
.kpi-card {
  background:    var(--surface);
  border:        1px solid var(--border);
  border-radius: 8px;
  padding:       1.25rem;
  position:      relative;
  overflow:      hidden;
}
.kpi-card::after { content: ''; position: absolute; bottom: 0; left: 0; right: 0; height: 2px; }
.kpi-g::after { background: var(--green); }
.kpi-p::after { background: var(--purple); }
.kpi-c::after { background: var(--cyan); }
.kpi-l::after { background: var(--lime); }
.kpi-num {
  font-family:        var(--font-head);
  font-weight:        800;
  font-size:          2rem;
  letter-spacing:     -.04em;
  color:              #fff;
  line-height:        1;
  font-variant-numeric: tabular-nums;
}
.kpi-g { } .kpi-num-g { color: var(--green); }
.kpi-num-p { color: var(--purple-light); }
.kpi-num-c { color: var(--cyan); }
.kpi-num-l { color: var(--lime); }
.kpi-lbl { font-family: var(--font-mono); font-size: 9px; font-weight: 600; letter-spacing: .07em; text-transform: uppercase; color: var(--fg-subtle); margin-top: 4px; }

/* ── CTA ── */
.cs-cta {
  padding-block: 6rem;
  text-align:    center;
  border-top:    1px solid var(--border);
}
.cs-cta-h2 {
  font-family:    var(--font-head);
  font-weight:    800;
  font-size:      clamp(1.8rem, 4vw, 3rem);
  letter-spacing: -.03em;
  color:          #fff;
  text-wrap:      balance;
  margin-bottom:  1rem;
}
.cs-cta-sub {
  color:       var(--fg-muted);
  font-size:   1.05rem;
  max-width:   38ch;
  margin:      0 auto 2rem;
  line-height: 1.65;
}
.cs-cta-actions {
  display:         flex;
  align-items:     center;
  justify-content: center;
  gap:             .75rem;
  flex-wrap:       wrap;
}
.btn-green {
  display:         inline-flex;
  align-items:     center;
  gap:             6px;
  background:      var(--green);
  color:           #0C0E12;
  font-family:     var(--font-head);
  font-size:       13.5px;
  font-weight:     700;
  letter-spacing:  -.01em;
  text-decoration: none;
  padding:         0 1.75rem;
  height:          48px;
  border-radius:   6px;
  transition:      background .15s;
}
.btn-green:hover { background: #4faa22; }


/* ── Problem section: two slides, two cards each ── */
.pain-carousel { min-width: 0; }
.pain-viewport { overflow: hidden; }
.pain-track { display: flex; transition: transform .5s ease; }
.pain-slide { flex: 0 0 100%; min-width: 0; }
.pain-dots { display: flex; justify-content: center; gap: 8px; margin-top: 1rem; }
.pain-dot { width: 7px; height: 7px; padding: 0; border: 0; border-radius: 50%; background: var(--border-mid); cursor: pointer; }
.pain-dot.on { background: var(--lime); }


/* ── Growth chart: tall bars on one baseline, rising on scroll ── */
.growth-h2-hidden { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.growth-big { font-size: clamp(5rem, 12vw, 9rem); }
.chart-bars { height: 380px; align-items: stretch; gap: 12px; }
.bar-col { height: 100%; gap: 8px; }
.bar-track { flex: 1; width: 100%; display: flex; align-items: flex-end; border-bottom: 1px solid var(--border); }
.bar-track .bar { height: 0; min-height: 0; transition: height .9s cubic-bezier(.2,.7,.2,1); transition-delay: calc(var(--i, 0) * 90ms); }
.chart-area.in .bar-track .bar { height: var(--h); }
@media (prefers-reduced-motion: reduce) { .bar-track .bar { height: var(--h); transition: none; } }


/* ── Major features slider ── */
.feat-slider { padding-block: 5rem; border-top: 1px solid var(--border); }
.feat-h2-hidden { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.feat-viewport { overflow: hidden; }
.feat-track { display: flex; transition: transform .6s cubic-bezier(.4,0,.2,1); }
.feat-slide { flex: 0 0 100%; min-width: 0; display: grid; grid-template-columns: 1fr 1fr; gap: 3rem; align-items: center; }
.feat-copy { min-width: 0; }
.feat-count { font-family: var(--font-mono); font-size: 11px; letter-spacing: .1em; color: var(--fg-subtle); margin-bottom: .75rem; }
.feat-title { font-size: clamp(1.6rem, 3vw, 2.25rem); margin-bottom: .25rem; }
.feat-copy .cs-lead-p { font-size: .9rem; line-height: 1.65; margin-top: .75rem; max-width: 52ch; }
.feat-list { list-style: none; padding: 0; margin: 1.25rem 0 0; display: flex; flex-direction: column; gap: .55rem; }
.feat-list li { position: relative; padding-left: 1.5rem; color: var(--fg-muted); font-size: .875rem; line-height: 1.5; }
.feat-list li::before { content: '\2192'; position: absolute; left: 0; color: var(--green); }
.feat-media { aspect-ratio: 16 / 10; width: 100%; border: 1px solid var(--border); border-radius: 12px; overflow: hidden; background: var(--surface-2); }
.feat-media img { width: 100%; height: 100%; object-fit: cover; display: block; }
.feat-media-empty { background: repeating-linear-gradient(45deg, #14161c 0 14px, #181a21 14px 28px); }
.feat-dots { display: flex; justify-content: center; gap: 8px; margin-top: 2rem; }
.feat-dot { width: 7px; height: 7px; padding: 0; border: 0; border-radius: 50%; background: var(--border-mid); cursor: pointer; }
.feat-dot.on { background: var(--lime); }
@media (max-width: 860px) { .feat-slide { grid-template-columns: 1fr; gap: 1.5rem; } .feat-media { order: -1; } }
@media (prefers-reduced-motion: reduce) { .feat-track { transition: none; } }

.feat-nav { display: flex; align-items: center; justify-content: center; gap: 1.25rem; margin-top: 2rem; }
.feat-nav .feat-dots { margin-top: 0; }
.feat-arrow { width: 40px; height: 40px; border-radius: 50%; border: 1px solid var(--border-mid); background: transparent; color: var(--fg); font-size: 16px; cursor: pointer; transition: border-color .15s, background .15s; }
.feat-arrow:hover { border-color: var(--lime); background: rgba(190,216,45,.08); }


/* ── Hero: smaller headline, text left, one big image right at matching height ── */
.cs-hero-layout { align-items: center; gap: 3rem; }
.cs-h1 { font-size: clamp(2.5rem, 5.5vw, 4.25rem); }
.cs-hero-sub { font-size: .95rem; line-height: 1.65; margin-bottom: 1.5rem; }
.cs-stack-row { list-style: none; padding: 0; margin-top: 0; margin-bottom: 1.5rem; }
.cs-stag::before, .cs-stag::after { content: none; }
.cs-hero-media {
  aspect-ratio: 16 / 10; width: 100%; min-width: 0;
  border: 1px solid var(--border); border-radius: 12px; overflow: hidden;
  background: var(--surface-2);
}
.cs-hero-media img { width: 100%; height: 100%; object-fit: cover; display: block; }
.cs-hero-media-empty { background: repeating-linear-gradient(45deg, #14161c 0 14px, #181a21 14px 28px); }
/* ── Hero slideshow: crossfading screenshots, green snake border + glow ── */
.cs-hero-show { position: relative; width: 100%; min-width: 0; border-radius: 14px; box-shadow: 0 0 60px rgba(46,158,58,.22), 0 20px 60px rgba(0,0,0,.5); }
.chs-clip { position: relative; aspect-ratio: 16 / 10; border-radius: 14px; overflow: hidden; background: #0d0f14; }
.chs-img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; object-position: top center; opacity: 0; transition: opacity .8s ease; }
.chs-img.is-on { opacity: 1; }
.chs-snake { position: absolute; inset: 0; width: 100%; height: 100%; overflow: visible; pointer-events: none; z-index: 3; }
.chs-snake rect { x: 1px; y: 1px; width: calc(100% - 2px); height: calc(100% - 2px); fill: none; rx: 14px; ry: 14px; }
.chs-base { stroke: rgba(46,158,58,.40); stroke-width: 1.5; }
.chs-head, .chs-glow { stroke-linecap: round; stroke-dasharray: 24 76; stroke-dashoffset: 0; animation: chs-run 7s linear infinite; }
.chs-head { stroke: #7fdc88; stroke-width: 2.5; filter: drop-shadow(0 0 4px #2e9e3a); }
.chs-glow { stroke: #2e9e3a; stroke-width: 6; opacity: .55; filter: blur(7px); }
@keyframes chs-run { to { stroke-dashoffset: -100; } }
.chs-dots { position: absolute; left: 0; right: 0; bottom: 12px; display: flex; justify-content: center; gap: 8px; z-index: 4; }
.chs-dots button { width: 8px; height: 8px; padding: 0; border-radius: 50%; border: 0; background: rgba(255,255,255,.45); cursor: pointer; transition: background .2s, transform .2s; }
.chs-dots button.on { background: #7fdc88; transform: scale(1.25); }
@media (prefers-reduced-motion: reduce) { .chs-head, .chs-glow { animation: none; stroke-dasharray: 100 0; } .chs-img { transition: none; } }
.pain-dots .pain-dot { margin-top: 0; flex-shrink: 0; }
.pain-dots .pain-dot.on { background: var(--lime); }

/* Hero art wrapper */
.cs-hero-art { position: relative; min-width: 0; }
@media (min-width: 900px) { .cs-hero-art { margin: -4% -3% -4% 0; } }

/* ── FMN page: whole case study runs on FMN green (nav stays FMDS purple) ── */
.cs-hero, .cs-section, .feat-slider, .cs-cta {
  --purple: #2e9e3a; --purple-light: #7fdc88; --purple-dark: #217a2c; --purple-dim: #14391a;
  --purple-glow: rgba(46,158,58,.18); --lime: #7fdc88;
}
.cs-tag-purple { background: rgba(46,158,58,.15); color: #7fdc88; border: 1px solid rgba(46,158,58,.35); }
.cs-hero .btn-primary, .cs-cta .btn-primary { background: #2e9e3a; border-color: #2e9e3a; color: #fff; }
.cs-hero .btn-primary:hover, .cs-cta .btn-primary:hover { background: #217a2c; border-color: #217a2c; }
.cs-hero-glow { background: radial-gradient(circle at 70% 40%, rgba(46,158,58,.18), transparent 65%); }

/* Feature images: show the whole screenshot, never crop it */
.feat-media { aspect-ratio: auto; background: #0d0f14; display: flex; align-items: center; justify-content: center; }
.feat-media img { width: 100%; height: auto; max-height: 520px; object-fit: contain; }
.feat-media-empty { aspect-ratio: 16 / 10; }

/* ── Features deck (cards open on hover, focus or tap) ── */
.fd-deck { display: flex; flex-direction: column; gap: 10px; margin-top: 1.25rem; }
.fd-card { position: relative; border: 1px solid var(--border); border-radius: 16px; background: var(--surface-2); overflow: hidden; transition: border-color .3s, box-shadow .3s; }
.fd-card.is-active { border-color: rgba(46,158,58,.55); box-shadow: 0 0 40px rgba(46,158,58,.14); }
.fd-rail { display: flex; align-items: center; gap: 12px; width: 100%; padding: 16px 18px; background: transparent; border: 0; color: var(--fg); cursor: pointer; text-align: left; font: inherit; }
.fd-n { font: 600 12px ui-monospace, Menlo, monospace; color: #7fdc88; letter-spacing: .08em; }
.fd-t { font-weight: 600; font-size: 1rem; }
.fd-body { display: none; padding: 0 18px 18px; flex-direction: column; gap: 14px; }
.fd-card.is-active .fd-body { display: flex; }
.fd-media { border-radius: 12px; overflow: hidden; background: #0d0f14; border: 1px solid var(--border); }
.fd-media img { display: block; width: 100%; height: auto; }
.fd-h { font-size: 1.35rem; margin: 0; }
.fd-lead { margin: 0; color: var(--fg-muted, #9aa3b2); }
.fd-list { margin: 0; padding-left: 1.1rem; display: grid; gap: .3rem; font-size: .92rem; }
@media (min-width: 1024px) {
  .fd-deck { flex-direction: column; gap: 10px; height: auto; }
  .fd-card { flex: none; }
  .fd-rail { position: static; width: 100%; flex-direction: row; align-items: center; justify-content: flex-start; gap: 16px; padding: 18px 24px; cursor: pointer; }
  .fd-t { writing-mode: horizontal-tb; transform: none; font-size: 1.05rem; color: var(--fg-muted, #9aa3b2); }
  .fd-card.is-active .fd-t { color: var(--fg); }
  .fd-rail::after { content: "+"; margin-left: auto; font-size: 1.4rem; line-height: 1; color: #7fdc88; transition: transform .35s; }
  .fd-card.is-active .fd-rail::after { transform: rotate(45deg); }
  .fd-card:not(.is-active):hover { border-color: rgba(46,158,58,.4); }
  .fd-body { position: static; display: grid; grid-template-rows: 0fr; padding: 0; opacity: 1; pointer-events: auto; transition: grid-template-rows .5s cubic-bezier(.2,.8,.2,1); }
  .fd-card.is-active .fd-body { grid-template-rows: 1fr; }
  .fd-inner { min-height: 0; overflow: hidden; display: grid; grid-template-columns: 1.35fr 1fr; gap: 28px; padding: 0 24px; align-items: center; }
  .fd-card.is-active .fd-inner { padding: 4px 24px 24px; }
  .fd-media { display: block; }
  .fd-media img { width: 100%; max-height: 480px; object-fit: contain; }
  .fd-list li:nth-child(n+7) { display: none; }
  .fd-noimg .fd-inner { grid-template-columns: 1fr; }
  .fd-noimg .fd-copy { max-width: 640px; }
  .fd-noimg .fd-h { font-size: 1.5rem; }
}
@media (prefers-reduced-motion: reduce) { .fd-card, .fd-body { transition: none !important; } }

/* Features deck on phones and tablets: swipeable slider */
@media (max-width: 1023px) {
  .fd-deck { flex-direction: row; gap: 12px; overflow-x: auto; scroll-snap-type: x mandatory; -webkit-overflow-scrolling: touch; padding: 4px 2px 14px; margin-right: calc(-1 * var(--wrap-pad, 1.25rem)); scrollbar-width: none; }
  .fd-deck::-webkit-scrollbar { display: none; }
  .fd-card { flex: 0 0 86%; scroll-snap-align: start; }
  .fd-rail { cursor: default; pointer-events: none; padding-bottom: 6px; }
  .fd-body, .fd-card.is-active .fd-body { display: flex; }
  .fd-inner { display: flex; flex-direction: column; gap: 14px; }
  .fd-media img { max-height: 260px; object-fit: contain; margin: 0 auto; }
  .fd-list li:nth-child(n+5) { display: none; }
}

/* Hover delay: a glow line fills along the bar for .9s before the card opens */
@media (min-width: 1024px) {
  .fd-rail { position: relative; }
  .fd-rail::before { content: ""; position: absolute; left: 0; bottom: 0; height: 2px; width: 0; background: linear-gradient(90deg, #2e9e3a, #7fdc88); box-shadow: 0 0 10px #2e9e3a, 0 0 4px #7fdc88; border-radius: 2px; opacity: 0; }
  .fd-card.is-arming:not(.is-active) .fd-rail::before { opacity: 1; animation: fd-load .9s linear forwards; }
  .fd-card.is-arming:not(.is-active) { border-color: rgba(46,158,58,.5); }
}
@keyframes fd-load { from { width: 0; } to { width: 100%; } }
@media (prefers-reduced-motion: reduce) { .fd-card.is-arming .fd-rail::before { animation-duration: .01s; } }

/* Nav CTA matches the FMN green on this page */
body[class*="page-fmn-case-study"] .btn-cta,
body[class*="page-fmn-case-study"] .mobile-menu-cta { background: #2e9e3a; color: #fff; }
body[class*="page-fmn-case-study"] .btn-cta:hover,
body[class*="page-fmn-case-study"] .mobile-menu-cta:hover { background: #217a2c; }

/* a11y contrast */
.cs-hero .btn-primary,.cs-cta .btn-primary{background:#217a2c;border-color:#217a2c}
.cs-hero .btn-primary:hover,.cs-cta .btn-primary:hover{background:#185c21;border-color:#185c21}
body[class*="page-fmn-case-study"] .mobile-menu-cta{background:#217a2c}
