/* DeCYFIR V4: four-story switcher (CSS radios, no JS) */
.s4 { margin-top: 56px; }
.s4r { position: absolute; opacity: 0; pointer-events: none; }
.s4__head { display: flex; justify-content: space-between; align-items: center; gap: 24px; margin-bottom: 24px; flex-wrap: wrap; }
.s4__eyb { margin: 0; font-size: 13px; font-weight: 700; letter-spacing: 1px; text-transform: uppercase; color: var(--red); }
.s4__tabs { display: flex; flex-wrap: wrap; gap: 8px; }
.s4l { padding: 11px 18px; border-radius: 999px; border: 1px solid rgba(16,24,40,.18); background: #fff; font-size: 14px; font-weight: 700; cursor: pointer; transition: background .2s, color .2s, border-color .2s; }
.s4l:hover { border-color: var(--ink); }
.s4__panels { display: grid; }
.s4p { grid-area: 1 / 1; visibility: hidden; opacity: 0; transition: opacity .25s; }
#s4-fin:checked ~ .s4__panels .s4p--fin, #s4-pharma:checked ~ .s4__panels .s4p--pharma, #s4-retail:checked ~ .s4__panels .s4p--retail, #s4-energy:checked ~ .s4__panels .s4p--energy { visibility: visible; opacity: 1; }
#s4-fin:checked ~ .s4__head .s4l--fin, #s4-pharma:checked ~ .s4__head .s4l--pharma, #s4-retail:checked ~ .s4__head .s4l--retail, #s4-energy:checked ~ .s4__head .s4l--energy { background: var(--ink); border-color: var(--ink); color: #fff; }
#s4-fin:focus-visible ~ .s4__head .s4l--fin, #s4-pharma:focus-visible ~ .s4__head .s4l--pharma, #s4-retail:focus-visible ~ .s4__head .s4l--retail, #s4-energy:focus-visible ~ .s4__head .s4l--energy { outline: 2px solid var(--violet); outline-offset: 2px; }
.sy4 { display: grid; grid-template-columns: minmax(0, .8fr) minmax(0, 1.2fr); border-radius: 26px; overflow: hidden; background: #fff; border: 1px solid var(--border); height: 100%; }
.sy4__img { position: relative; min-height: 460px; background-size: cover; background-position: center; }
.sy4__img::after { content: ""; position: absolute; inset: 0; background: linear-gradient(180deg, rgba(16,24,40,.05) 30%, rgba(16,24,40,.82)); }
.sy4__st { position: absolute; z-index: 1; left: 22px; right: 22px; bottom: 22px; display: flex; flex-wrap: wrap; gap: 10px; margin: 0; padding: 0; list-style: none; }
.sy4__st li { display: grid; padding: 12px 16px; border-radius: 14px; background: #fff; box-shadow: 0 16px 30px -18px rgba(0,0,0,.6); }
.sy4__st b { font-size: 28px; line-height: 1; font-weight: 600; color: var(--ink); } .sy4__st span { margin-top: 4px; font-size: 12.5px; color: var(--muted); }
.sy4__b { display: grid; align-content: start; gap: 10px; padding: 36px 40px; }
.sy4__k { margin: 0; font-size: 12.5px; font-weight: 700; letter-spacing: .8px; text-transform: uppercase; color: var(--red); }
.sy4__b h3 { margin: 0 0 6px; font-size: clamp(22px, 2.2vw, 28px); line-height: 1.25; font-weight: 500; }
.sy4__b > p:not(.lbl):not(.sy4__k) { margin: 0 0 6px; color: var(--ink-2); line-height: 1.55; }
.sy4 .lbl { margin: 6px 0 0; font-size: 12px; font-weight: 700; letter-spacing: 1px; text-transform: uppercase; color: var(--muted); }
.sy4 .cov { display: grid; gap: 8px; margin: 0; padding: 0; list-style: none; } .sy4 .cov li { display: flex; gap: 10px; font-size: 15px; line-height: 1.45; color: var(--ink-2); }
.sy4 .tk { width: 16px; height: 16px; flex: none; margin-top: 3px; fill: none; stroke: var(--violet); stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.sy4__q { position: relative; margin: 10px 0 6px; padding-top: 34px; }
.sy4__q::before { content: "\201C"; position: absolute; left: -3px; top: -14px; font-size: 72px; line-height: 1; font-weight: 600; color: var(--red); }
.sy4__q blockquote { margin: 0; font-size: 17px; line-height: 1.5; color: var(--ink); } .sy4__q figcaption { margin-top: 8px; font-size: 13px; font-weight: 700; color: var(--muted); }
.sy4__btn { justify-self: start; display: inline-flex; gap: 8px; padding: 11px 18px; border-radius: 999px; border: 1px solid rgba(16,24,40,.25); font-weight: 700; font-size: 15px; transition: border-color .2s; }
.sy4__btn:hover { border-color: var(--ink); }
@media (max-width: 960px) { .sy4 { grid-template-columns: minmax(0, 1fr); } .sy4__img { min-height: 260px; } .sy4__b { padding: 26px; } }
.sy4__st { gap: 8px; left: 16px; right: 16px; bottom: 16px; flex-wrap: nowrap; } .sy4__st li { flex: 1; min-width: 0; padding: 10px 12px; } .sy4__st b { font-size: 24px; } .sy4__st span { font-size: 11.5px; line-height: 1.3; }

/* ---- trimmed stories: numbers + quote only ---- */
.sy4 { grid-template-columns: minmax(0, .9fr) minmax(0, 1.1fr); }
.sy4__img { min-height: 380px; }
.sy4__tag { position: absolute; z-index: 1; left: 22px; bottom: 20px; margin: 0; padding: 7px 12px; border-radius: 999px; background: rgba(255,255,255,.92); font-size: 12px; font-weight: 700; letter-spacing: .6px; text-transform: uppercase; color: var(--ink); }
.sy4__b { align-content: center; gap: 22px; padding: 44px 48px; }
.sy4__b h3 { margin: 0; font-size: clamp(22px, 2.2vw, 28px); }
.sy4__nums { display: grid; gap: 0; margin: 0; padding: 18px 0; list-style: none; border-top: 1px solid var(--border); border-bottom: 1px solid var(--border); }
.sy4__nums--3 { grid-template-columns: repeat(3, minmax(0, 1fr)); } .sy4__nums--2 { grid-template-columns: repeat(2, minmax(0, 1fr)); } .sy4__nums--1 { grid-template-columns: minmax(0, 1fr); }
.sy4__nums li { display: grid; gap: 6px; padding-right: 18px; }
.sy4__nums li + li { padding-left: 18px; border-left: 1px solid var(--border); }
.sy4__nums b { font-size: clamp(34px, 3.6vw, 48px); line-height: 1; font-weight: 500; letter-spacing: -0.02em; color: var(--ink); }
.sy4__nums li:first-child b { color: var(--red); }
.sy4__nums span { font-size: 13.5px; color: var(--muted); }
.sy4__q { margin: 0; } .sy4__q blockquote { font-size: 18px; }

/* ---- Discover -> Act: a signal travels along the line and lights each step in turn ---- */
@media (prefers-reduced-motion: no-preference) {
  .steps--light .steps__list::after { content: ""; position: absolute; left: 10%; top: 21px; height: 4px; width: 0; border-radius: 2px;
    background: linear-gradient(90deg, var(--violet), var(--red)); box-shadow: 0 0 12px rgba(206,32,44,.45); animation: stepline 7s ease-in-out infinite; }
  @keyframes stepline { 0% { width: 0; opacity: 1; } 70% { width: 80%; opacity: 1; } 85%, 100% { width: 80%; opacity: 0; } }
  .steps--light .steps__list li { z-index: 1; }
  .steps--light .steps__list li span { animation: steplit 7s ease-in-out infinite; }
  .steps--light .steps__list li:nth-child(2) span { animation-delay: 1.2s; } .steps--light .steps__list li:nth-child(3) span { animation-delay: 2.45s; }
  .steps--light .steps__list li:nth-child(4) span { animation-delay: 3.65s; } .steps--light .steps__list li:nth-child(5) span { animation-name: steplast; animation-delay: 4.9s; }
  @keyframes steplit { 0%, 2% { background: var(--white); color: var(--ink); scale: 1; } 6%, 22% { background: var(--violet); color: #fff; scale: 1.12; } 30%, 100% { background: var(--white); color: var(--ink); scale: 1; } }
  @keyframes steplast { 0%, 2% { scale: 1; box-shadow: 0 0 0 6px rgba(206,32,44,.2); } 6%, 22% { scale: 1.18; box-shadow: 0 0 0 14px rgba(206,32,44,.18); } 30%, 100% { scale: 1; box-shadow: 0 0 0 6px rgba(206,32,44,.2); } }
}
@media (max-width: 760px) { .steps--light .steps__list::after { display: none; } .sy4__b { padding: 26px; } .sy4__nums--3 { grid-template-columns: minmax(0, 1fr); } .sy4__nums li + li { padding: 12px 0 0; border-left: 0; border-top: 1px solid var(--border); } }

/* ===== Dark mode (html[data-theme="dark"]) ===== */
/* intentional dark panel: the selected story tab uses background: var(--ink) + literal white
   text, same overloaded-variable pattern called out in shared/base.css — pin it here since
   this selector isn't in that file's pin list */
html[data-theme="dark"] #s4-fin:checked ~ .s4__head .s4l--fin,
html[data-theme="dark"] #s4-pharma:checked ~ .s4__head .s4l--pharma,
html[data-theme="dark"] #s4-retail:checked ~ .s4__head .s4l--retail,
html[data-theme="dark"] #s4-energy:checked ~ .s4__head .s4l--energy { background: #101828; border-color: #101828; }

/* light surfaces (literal #fff / rgba(255,255,255,.92)) used as cards/overlays */
html[data-theme="dark"] .s4l,
html[data-theme="dark"] .sy4,
html[data-theme="dark"] .sy4__st li { background: #1D2939; }
html[data-theme="dark"] .sy4__tag { background: rgba(16,24,40,.85); }

/* borders drawn with literal rgba(16,24,40,...) need lightening for visibility */
html[data-theme="dark"] .s4l,
html[data-theme="dark"] .sy4__btn { border-color: rgba(255,255,255,.18); }

/* the discover->act step badges pulse through var(--white)/var(--ink) (idle) which, with the
   shared --ink flip, would render light text on a literal white surface; give them a
   dark-mode keyframe instead of editing the light-mode one */
@media (prefers-reduced-motion: no-preference) {
  @keyframes steplit-dark { 0%, 2% { background: #1D2939; color: #F2F4F7; scale: 1; } 6%, 22% { background: var(--violet); color: #fff; scale: 1.12; } 30%, 100% { background: #1D2939; color: #F2F4F7; scale: 1; } }
  html[data-theme="dark"] .steps--light .steps__list li span { animation-name: steplit-dark; }
  html[data-theme="dark"] .steps--light .steps__list li:nth-child(5) span { animation-name: steplast; }
}
