/* Licenzo case study. Same split layout as the portfolio's Gamut and Emento case studies
   (sticky text panel on the left, stacked rounded cards on the right),
   recoloured for this project: dark-green cards, off-white text, Caribbean green accents. */
@font-face { font-family: "Tokyo Dreams"; src: url("../assets/tokyodreams-webfont.woff2") format("woff2"); font-display: block; ascent-override: 100%; descent-override: 20%; line-gap-override: 0%; }

:root {
  --bg: #141416;            /* page, as in the portfolio */
  --panel: #032221;         /* cards: the product's Dark Green */
  --ink: #f1f7f6; --p-gray: #9a9a9a; --soft: #7a7a7a;
  --line: rgba(244, 241, 234, 0.14);
  --rim: rgba(241, 247, 246, 0.12);
  --rich-black: #000f0b; --bangladesh: #03624c; --meadow: #2cc295; --caribbean: #00df81; --white: #f1f7f6;
  --display: "Tokyo Dreams", "Libre Baskerville", Georgia, serif;
  --sans: "Inter", "Helvetica Neue", Arial, sans-serif;
  --app: "Geist", var(--sans);
  --edge: 8px; --gap: 20px;
  --radius: clamp(30px, 4vw, 60px);
  --pad-x: clamp(2.5rem, 7vw, 6rem);
  --ease: cubic-bezier(0.22, 1, 0.36, 1);

  --fs-label: 0.75rem;
  --fs-small: 0.92rem;
}
*, *::before, *::after { box-sizing: border-box; }
html { background: var(--bg); scrollbar-width: none; }
html::-webkit-scrollbar, *::-webkit-scrollbar { width: 0; height: 0; display: none; }
html.lenis { scroll-behavior: auto; }
body { margin: 0; font-family: var(--sans); color: var(--ink); background: var(--bg); line-height: 1.6; -webkit-font-smoothing: antialiased; overflow-x: hidden; }
a { color: inherit; text-decoration: none; }
p, figure, blockquote, dl, dd { margin: 0; }
ul, ol { margin: 0; padding: 0; list-style: none; }

/* ============ Two-box split ============ */
.fn { display: grid; grid-template-columns: minmax(calc(23rem + clamp(1rem, 2vw, 2rem) + clamp(0.5rem, 1vw, 1rem)), 29%) minmax(0, 1fr);   /* left column never narrower than the four tabs on one line; the right one gives way until the tablet layout takes over */ gap: var(--gap); padding: var(--edge); align-items: start; max-width: 1900px; margin: 0 auto; }

/* Left side sits directly on the page background */
.fn-panel {
  position: sticky; top: var(--edge); height: calc(100vh - 2 * var(--edge)); height: calc(100svh - 2 * var(--edge));
  display: flex; flex-direction: column; overflow-y: auto; overflow-x: hidden;
  padding: clamp(2rem, 4vw, 3.5rem) clamp(0.5rem, 1vw, 1rem) clamp(2rem, 4vw, 3.5rem) clamp(1rem, 2vw, 2rem);
}
/* Left panel text: the two greys carry the same slight warm undertone as the cream used on the landing page */
.fn-panel { --p-gray: #9c9a95; --soft: #7b7974; }
.fn-back { display: block; width: 100%; padding-bottom: 1.4rem; border-bottom: 1px solid var(--line); font-size: var(--fs-label); letter-spacing: 0.12em; text-transform: uppercase; color: var(--p-gray); transition: color .3s var(--ease); }
.fn-back:hover { color: #fff; }
.fn-head { margin-top: 1.4rem; }
.fn-title { font-family: var(--display); font-weight: 400; font-size: clamp(2.8rem, 4.6vw, 4.2rem); line-height: 1; margin: 0 0 0.9rem; color: #fff; }
.fn-tagline { color: var(--p-gray); font-size: var(--fs-small); max-width: 40ch; }

.fn-tabs { display: flex; flex-wrap: wrap; align-items: center; gap: 0.35rem 1.4rem; margin-top: clamp(2.5rem, 9vh, 5rem); }
/* on short laptop screens the longest summary needs this room to fit without scrolling the panel */
@media (max-height: 860px) {
  .fn-tabs { margin-top: 2rem; }
  .fn-panel { padding-top: 2rem; padding-bottom: 2rem; }
}
.fn-tabs a { position: relative; padding: 0.35rem 0; font-size: var(--fs-label); letter-spacing: 0.12em; text-transform: uppercase; line-height: 1.6; color: var(--soft); transition: color .3s var(--ease); }
.fn-tabs a::after { content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 1px; background: #fff; transform: scaleX(0); transform-origin: left; transition: transform .4s var(--ease); }
.fn-tabs a:hover, .fn-tabs a.is-active { color: #fff; }
.fn-tabs a.is-active::after { transform: scaleX(1); }
/* Summary paragraphs: the landing page's --ink-2 cream, a step brighter than the grey labels */
.fn-sum { margin-top: 1.4rem; color: #cfcabf; font-size: var(--fs-small); line-height: 1.55; max-width: 44ch; white-space: pre-line; transition: opacity .32s var(--ease); }
/* Desktop: a long summary scrolls inside its own area (no scrollbar), so it never runs over the Previous / Next line */
@media (min-width: 1024px) {
  .fn-sum { overflow-y: auto; margin-bottom: 1rem; scrollbar-width: none; }
  .fn-sum::-webkit-scrollbar { display: none; }
}

.fn-foot { margin-top: auto; padding-top: 1rem; border-top: 1px solid var(--line); display: flex; justify-content: space-between; font-size: var(--fs-label); letter-spacing: 0.12em; text-transform: uppercase; color: var(--p-gray); }
.fn-foot a:hover { color: #fff; }

/* ============ Right side: stacked cards ============ */
/* inside the green cards the greys lean green too */
.fn-main { --p-gray: #9fb8b1; --soft: #6f8a83; --line: rgba(241, 247, 246, 0.14); display: grid; gap: var(--gap); font-family: var(--app); font-feature-settings: "lnum" 1; }
.fn-sec { position: relative; isolation: isolate; overflow: hidden; scroll-margin-top: var(--edge); background: var(--panel); border-radius: var(--radius); padding: clamp(2.5rem, 6.5vw, 6rem) var(--pad-x); container-type: inline-size; container-name: card; }

/* each card carries a soft green light in one corner */
.fn-sec::before { content: ""; position: absolute; z-index: -1; width: 60%; aspect-ratio: 1; border-radius: 50%; background: var(--glow); filter: blur(120px); opacity: 0.2; pointer-events: none; }
#discovery { --glow: var(--caribbean); }
#discovery::before { top: -24%; right: -22%; }
#strategy { --glow: var(--meadow); }
#strategy::before { top: -18%; left: -20%; opacity: 0.16; }
#design { --glow: var(--caribbean); }
#design::before { top: -8%; right: -30%; opacity: 0.14; }

/* Cover: two app windows on a dark-green stage */
.fn-cover { position: relative; container-type: size; height: calc(100svh - 2 * var(--edge)); overflow: hidden; background: var(--panel); border-radius: var(--radius); animation: fn-cover 1.6s var(--ease) both; }
@keyframes fn-cover { from { opacity: 0; transform: scale(1.03); } to { opacity: 1; transform: none; } }
.fn-cover__glow {
  position: absolute; inset: 0;
  background:
    radial-gradient(circle at 20% 70%, var(--caribbean) 0%, transparent 34%),
    radial-gradient(circle at 78% 24%, var(--meadow) 0%, transparent 36%);
  filter: blur(90px); opacity: 0.3;
}
.fn-cover .browser { position: absolute; top: 50%; }
.fn-cover .browser--back { right: -14cqw; width: 66cqw; transform: translateY(-78%); opacity: 0.6; }
.fn-cover .browser--front { left: 6cqw; width: 76cqw; transform: translateY(-38%); }

/* ============ App screens ============ */
/* Every screen is a 2x screenshot of the app laid out --w wide (1440 unless set); --h is how much of the
   page's height the window shows. The image fills its box, so nothing has to be measured in script. */
.browser { border-radius: 14px; background: #0a2a28; box-shadow: 0 0 0 1px rgba(241, 247, 246, 0.14), 0 40px 80px -30px rgba(0, 0, 0, 0.85); overflow: hidden; }
.browser__bar { display: flex; align-items: center; gap: 6px; height: 30px; padding: 0 12px; font-size: 0.75rem; color: var(--soft); }
.browser__bar i { width: 8px; height: 8px; border-radius: 50%; background: rgba(241, 247, 246, 0.2); }
.browser__bar span { margin-left: 8px; }
.screen { --w: 1440; --h: 900; position: relative; width: 100%; aspect-ratio: var(--w) / var(--h); background: #f1f7f6; overflow: hidden; }
.screen img, .crop img { position: absolute; inset: 0; display: block; width: 100%; height: 100%; pointer-events: none; }

/* One part of a screen, cut out of it: --cw/--ch is its size in app pixels */
.crop {
  --cw: 400; --ch: 300;
  position: relative; width: 100%; aspect-ratio: var(--cw) / var(--ch);
  border-radius: 18px; background: #f1f7f6; box-shadow: 0 0 0 1px var(--rim), 0 30px 60px -30px rgba(0, 0, 0, 0.8); overflow: hidden;
}

/* ============ Card content ============ */
.showcase { margin-top: clamp(5rem, 14cqi, 8rem); }
.showcase__head { display: grid; grid-template-columns: 1fr 1fr; align-items: end; gap: clamp(1.5rem, 5cqi, 3.5rem); margin-bottom: 2.6rem; padding-bottom: 1.4rem; border-bottom: 1px solid var(--line); }
@media (min-width: 1024px) { .showcase__head { margin-bottom: 4rem; } }
.showcase__head--inner { margin-top: clamp(5rem, 14cqi, 8rem); }
.showcase__title { margin: 0; font-weight: 300; font-size: clamp(1.7rem, 5cqi, 2.6rem); line-height: 1.08; letter-spacing: -0.02em; }
.showcase__lead { justify-self: end; max-width: 24rem; color: var(--p-gray); font-size: 0.95rem; line-height: 1.6; }

/* the pull-line already leaves a wide gap under it */
.pull + .showcase__head--inner { margin-top: 0; }

.label { margin-bottom: 1rem; font-size: var(--fs-label); font-weight: 600; letter-spacing: 0.12em; text-transform: uppercase; color: var(--p-gray); }
.note { margin-top: 0.9rem; font-size: 0.8rem; color: var(--soft); }

.pull { max-width: 22ch; margin: clamp(6rem, 18cqi, 10.5rem) auto; font-weight: 300; font-size: clamp(1.6rem, 5cqi, 2.6rem); line-height: 1.18; letter-spacing: -0.015em; text-align: center; }

/* Glass tile shared by every box inside a card */
.tile, .case, .finding, .flow__path, .goals li {
  background: linear-gradient(160deg, rgba(241, 247, 246, 0.08) 0%, rgba(241, 247, 246, 0.02) 100%);
  border: 1px solid var(--rim);
  border-radius: 22px;
  box-shadow: inset 0 1px 0 rgba(241, 247, 246, 0.08);
}

/* ---------- Discovery: the research, what it showed, and the journey it mapped ---------- */
/* The number on the left, what the research looked at as a ruled list on the right.
   The two columns are the same as the header's, so the list sits under the lead paragraph. */
.research { display: grid; grid-template-columns: 1fr 1fr; align-items: end; gap: clamp(1.5rem, 5cqi, 3.5rem); }
.research__num { font-weight: 300; font-size: clamp(5rem, 15cqi, 8.5rem); line-height: 0.8; letter-spacing: -0.05em; }
.research__num span { color: var(--caribbean); }
.research__text { margin-top: 1.2rem; font-size: clamp(1rem, 2.2cqi, 1.2rem); color: var(--p-gray); }
.research__focus .label { margin-bottom: 0.8rem; }
.research__tags li { display: flex; align-items: center; gap: 0.9rem; padding: 0.8rem 0; border-top: 1px solid var(--line); font-size: 1rem; }
.research__tags li:last-child { padding-bottom: 0; }
/* Lucide "arrow-right", drawn as a mask so it takes the text colour */
.research__tags li::before {
  --arrow: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M5 12h14'/%3E%3Cpath d='m12 5 7 7-7 7'/%3E%3C/svg%3E");
  content: ""; flex: none; width: 1rem; height: 1rem; background: var(--soft);
  -webkit-mask: var(--arrow) center / contain no-repeat; mask: var(--arrow) center / contain no-repeat;
}

.label--section { margin-top: clamp(4rem, 12cqi, 7rem); }

.findings { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 0.8rem; }
.finding { display: flex; flex-direction: column; justify-content: space-between; gap: 2.4rem; min-height: 11rem; padding: 1.3rem; }
.finding h4 { margin: 0; font-size: 1.3rem; font-weight: 500; line-height: 1.2; }
.finding p { font-size: 0.92rem; line-height: 1.5; color: var(--p-gray); }

/* five steps on one thin line, each marked by a dot; the line ends in an arrowhead */
.journey { position: relative; display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 1.4rem; padding-top: 1.9rem; counter-reset: step; }
.journey::before { content: ""; position: absolute; top: 4px; left: 4px; right: 0; height: 1px; background: rgba(241, 247, 246, 0.28); }
.journey::after { content: ""; position: absolute; top: 0; right: 0; width: 9px; height: 9px; border-top: 1px solid rgba(241, 247, 246, 0.5); border-right: 1px solid rgba(241, 247, 246, 0.5); rotate: 45deg; }
.journey li { position: relative; counter-increment: step; font-size: 1.05rem; font-weight: 500; line-height: 1.3; }
.journey li::before { content: ""; position: absolute; top: -1.9rem; left: 0; width: 9px; height: 9px; border-radius: 50%; background: var(--panel); border: 1px solid var(--caribbean); }
.journey li::after { content: "0" counter(step); display: block; order: -1; }
.journey li { display: flex; flex-direction: column; gap: 0.5rem; }
.journey li::after { font-size: var(--fs-label); font-weight: 600; letter-spacing: 0.08em; color: var(--soft); }

/* ---------- Discovery: three roles, and the same license priced at each of them ---------- */
.chain { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 1.4rem; }
.chain li { position: relative; }
.chain li + li::before { content: "→"; position: absolute; top: 50%; left: -1.4rem; width: 1.4rem; translate: 0 -50%; text-align: center; font-size: 0.9rem; color: var(--soft); }

.chain--roles li {
  display: flex; flex-direction: column; gap: 0.5rem; min-height: 9.5rem; padding: 1.1rem;
  border-radius: 20px; border: 1px solid var(--rim);
  background: linear-gradient(160deg, rgba(241, 247, 246, 0.1) 0%, rgba(241, 247, 246, 0.03) 100%);
  box-shadow: inset 0 1px 0 rgba(241, 247, 246, 0.1);
}
.chain--roles span { font-size: var(--fs-label); font-weight: 600; letter-spacing: 0.08em; color: var(--soft); }
.chain--roles b { font-size: 1.05rem; font-weight: 500; line-height: 1.25; }
.chain--roles p { margin-top: auto; font-size: 0.82rem; line-height: 1.45; color: var(--p-gray); }
/* the reseller is the role this case study designs for */
.chain--roles .is-focus { background: var(--white); border-color: var(--white); color: #04201a; box-shadow: none; }
.chain--roles .is-focus span { color: #526660; }
.chain--roles .is-focus p { color: #3a4f49; }

.chain__links { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 1.4rem; }
.chain__links span { justify-self: center; width: 0; height: 2.6rem; border-left: 1px dashed rgba(241, 247, 246, 0.28); }

.prices { padding: 1.2rem; border-radius: 14px; border: 1px dashed rgba(241, 247, 246, 0.18); background: rgba(0, 15, 11, 0.4); }
.prices .label { margin-bottom: 0.9rem; font-weight: 500; }
.prices .chain { margin-inline: -1.2rem; }
.prices .chain li { margin-inline: 0.5rem; padding: 0.8rem 0.9rem; border-radius: 10px; border: 1px solid rgba(0, 223, 129, 0.28); background: rgba(0, 223, 129, 0.06); }
.prices .chain li + li::before { left: calc(-1.4rem - 0.5rem); width: calc(1.4rem + 1rem); color: rgba(0, 223, 129, 0.6); }
.prices li span { display: block; font-size: 0.75rem; color: var(--p-gray); }
.prices li b { display: block; font-size: 1.15rem; font-weight: 500; letter-spacing: -0.01em; }
.prices small { display: block; margin-top: 0.2rem; font-size: 0.75rem; color: var(--caribbean); }

.cases { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 0.8rem; }
.case { padding: 1.3rem; }
.case__name { margin: 0; font-size: 1.3rem; font-weight: 500; }
/* a small icon tile, as in the app: rounded square, tinted green, with the Lucide icon of the screen that job happens on */
.case__name::before {
  content: ""; display: block; width: 2.25rem; height: 2.25rem; margin-bottom: 1.1rem; border-radius: 10px;
  background: var(--icon) center / 1.125rem no-repeat, rgba(0, 223, 129, 0.12);
}
.case:nth-child(1) { --icon: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%2300DF81' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m21 21-4.34-4.34'/%3E%3Ccircle cx='11' cy='11' r='8'/%3E%3C/svg%3E"); } /* search */
.case:nth-child(2) { --icon: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%2300DF81' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M6 22a2 2 0 0 1-2-2V4a2 2 0 0 1 2-2h8a2.4 2.4 0 0 1 1.704.706l3.588 3.588A2.4 2.4 0 0 1 20 8v12a2 2 0 0 1-2 2z'/%3E%3Cpath d='M14 2v5a1 1 0 0 0 1 1h5'/%3E%3Cpath d='M10 9H8'/%3E%3Cpath d='M16 13H8'/%3E%3Cpath d='M16 17H8'/%3E%3C/svg%3E"); } /* file-text */
.case:nth-child(3) { --icon: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%2300DF81' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M3 12a9 9 0 0 1 9-9 9.75 9.75 0 0 1 6.74 2.74L21 8'/%3E%3Cpath d='M21 3v5h-5'/%3E%3Cpath d='M21 12a9 9 0 0 1-9 9 9.75 9.75 0 0 1-6.74-2.74L3 16'/%3E%3Cpath d='M8 16H3v5'/%3E%3C/svg%3E"); } /* refresh-cw */
.case__line { margin: 0.35rem 0 1.5rem; color: var(--p-gray); font-size: 0.92rem; line-height: 1.5; }
.case__facts { display: grid; gap: 0.9rem; padding-top: 1.1rem; border-top: 1px solid var(--line); }
.case__facts dt { font-size: 0.75rem; color: var(--soft); }
.case__facts dd { font-size: 0.9rem; font-weight: 500; }

/* ---------- Strategy: one path from catalog to invoice, and the navigation built on it ---------- */
.path { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 1.4rem; counter-reset: step; }
.path li {
  position: relative; counter-increment: step;
  display: flex; flex-direction: column; justify-content: space-between; gap: 1.6rem; min-height: 7.5rem; padding: 1.1rem;
  border-radius: 20px; border: 1px solid var(--rim);
  background: linear-gradient(160deg, rgba(241, 247, 246, 0.1) 0%, rgba(241, 247, 246, 0.03) 100%);
  box-shadow: inset 0 1px 0 rgba(241, 247, 246, 0.1);
  font-size: 0.95rem; font-weight: 500; line-height: 1.3;
}
.path li::after { content: "0" counter(step); order: -1; font-size: var(--fs-label); font-weight: 600; letter-spacing: 0.08em; color: var(--soft); }
.path li + li::before { content: "→"; position: absolute; top: 50%; left: -1.4rem; width: 1.4rem; translate: 0 -50%; text-align: center; font-size: 0.9rem; color: var(--soft); }
.path small { display: block; margin-top: 0.25rem; font-size: 0.78rem; font-weight: 400; color: var(--p-gray); }
/* the two steps that exist in the prototype so far */
.path .is-built { background: var(--white); border-color: var(--white); color: #04201a; box-shadow: none; }
.path .is-built::after { color: #526660; }
.path .is-built small { color: #3a4f49; }

.flow__paths { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 0.8rem; margin-top: 0.8rem; }
.flow__path { padding: 1.3rem 1.2rem 1.4rem; }
.flow__name { display: block; font-size: 1.05rem; font-weight: 600; }
.flow__path p { margin: 0.2rem 0 1rem; font-size: 0.85rem; color: var(--p-gray); }
.flow__path ol { display: grid; gap: 0.5rem; }
.flow__path li { display: flex; align-items: center; height: 2.5rem; padding: 0 0.9rem; border-radius: 999px; border: 1px solid var(--rim); font-size: 0.85rem; }

.goals { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 0.8rem; }
.goals li { padding: 1.3rem; }
.goals span { display: block; margin-bottom: 1.6rem; font-size: var(--fs-label); font-weight: 500; letter-spacing: 0.08em; text-transform: uppercase; color: var(--soft); }
.goals b { display: block; font-weight: 300; font-size: clamp(1.05rem, 2.2cqi, 1.3rem); line-height: 1.3; }
.goals p { margin-top: 0.7rem; font-size: 0.88rem; line-height: 1.55; color: var(--p-gray); }

/* ---------- Design: the small system; each tile is an image of the block drawn in the prototype's case study ---------- */
.system { display: grid; grid-template-columns: 1fr 1fr; gap: 0.8rem; }
.system img { display: block; width: 100%; height: auto; align-self: start; }
.system img.is-wide { grid-column: 1 / -1; }
.label + .system { margin-top: 0; }
.system + .pair { margin-top: 0.8rem; }

/* ---------- Design: the screens ---------- */
figcaption { margin-top: 1rem; font-size: 0.82rem; line-height: 1.5; color: var(--p-gray); }
figcaption b { display: block; font-size: 0.88rem; font-weight: 600; color: var(--ink); }
.details { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: clamp(0.8rem, 2.4cqi, 1.5rem); align-items: start; margin-top: 2.6rem; }
.details__wide { grid-column: 1 / -1; }
.pair { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: clamp(0.8rem, 2.4cqi, 1.5rem); align-items: start; margin-top: clamp(0.8rem, 2.4cqi, 1.5rem); }
.brands { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: clamp(0.8rem, 2.4cqi, 1.5rem); align-items: start; }

@container card (max-width: 640px) {
  .showcase__head, .cases, .goals, .system, .flow__paths, .details, .pair, .brands { grid-template-columns: 1fr; }
  .findings { gap: 0.6rem; }
  .finding { min-height: 9.5rem; padding: 1rem; gap: 1.4rem; }
  .finding h4 { font-size: 1.05rem; }
  .finding p { font-size: 0.85rem; }
  .journey { gap: 0.8rem; }
  .journey li { font-size: 0.92rem; }
  .showcase__head { gap: 1.1rem; }
  .showcase__lead { justify-self: start; max-width: none; }
  .chain, .chain__links, .path { grid-template-columns: 1fr 1fr; gap: 0.6rem; }
  .chain li + li::before, .path li + li::before, .chain__links { display: none; }
  .prices { margin-top: 0.8rem; }
  .prices .chain { margin-inline: 0; }
  .prices .chain li { margin-inline: 0; }
}

@container card (max-width: 480px) {
  .research, .findings { grid-template-columns: 1fr; }
  .finding { min-height: 0; gap: 0.6rem; }
  /* the journey turns to run down the page, its line along the left edge */
  .journey { grid-template-columns: 1fr; gap: 1.3rem; padding: 0 0 0 1.6rem; }
  .journey::before { top: 4px; bottom: 4px; left: 4px; right: auto; width: 1px; height: auto; }
  .journey::after { display: none; }
  .journey li::before { top: 0.3rem; left: -1.6rem; }
}

/* ============ Tablet: 768–1023 ============
   Single column. The panel keeps title, tagline, section tabs and summary (as on desktop);
   Previous / Next move to the top bar and the landing menu to the bottom (css/case-nav.css). */
@media (min-width: 768px) and (max-width: 1023px) {
  .fn { grid-template-columns: 1fr; }
  .fn-panel { position: static; height: auto; overflow: visible; }
  .fn-foot { display: none; }
  .fn-tabs { margin-top: 2.5rem; }
  .fn-tagline, .fn-sum { max-width: 70ch; }
  .fn-cover { height: 78vh; }
}

/* ============ Mobile: ≤767 ============ */
@media (max-width: 767px) {
  :root { --pad-x: 1.5rem; }
  .fn { grid-template-columns: 1fr; }
  .fn-panel { position: static; height: auto; overflow: visible; }
  .fn-foot { display: none; }
  .fn-tabs { margin-top: 2rem; gap: 0.35rem 0.9rem; }
  .fn-tabs a { letter-spacing: 0.1em; }   /* keeps the four tabs on one line at 375px */
  .fn-tagline, .fn-sum { max-width: 70ch; }
  .fn-cover { height: 60vh; }
  .fn-cover .browser--back { display: none; }
  .fn-cover .browser--front { left: 5cqw; width: 150cqw; transform: translateY(-50%); }
  .fn-cover, .fn-sec { border-radius: 30px; }
}

@media (prefers-reduced-motion: reduce) {
  .fn-cover { animation: none; }
  .fn-sum { transition: none; }
}
