/* PREDIX landing. One motif: the Duval triangle (60° geometry) runs the notch, the button
   corner, the bullets, the photo masks, the FAQ tabs and the band. Flat colour only. */

:root {
  --ground: #f2f6f9;
  --paper: #ffffff;
  --ink: #062b45;
  --ink-soft: #3d5a70;
  --navy: #023859;
  --blue: #005ca8;
  --blue-deep: #004a88;
  --amber: #f29f05;
  --amber-strong: #d98a00;
  --tint: #d6e5f2;
  --tint-2: #e6eef5;

  --font: "Anuphan", "Noto Sans Thai", system-ui, sans-serif;
  --s-display: clamp(40px, 6vw, 96px);
  --s-head: clamp(28px, 3.1vw, 46px);
  --s-lead: 20px;
  --s-body: 17px;
  --s-small: 14px;

  --margin: clamp(16px, 2.6vw, 40px);
  --gap-section: clamp(96px, 11vw, 168px);
  --chamfer: 14px;

  --ease-out: cubic-bezier(0.22, 1, 0.36, 1);
  --ease-in-out: cubic-bezier(0.65, 0, 0.35, 1);
  --t-press: 120ms;
  --t-hover: 180ms;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--ground);
  color: var(--ink);
  font-family: var(--font);
  font-size: var(--s-body);
  line-height: 1.6;
  overflow-x: hidden;
}
img, svg { display: block; max-width: 100%; }
a { color: inherit; }
button, input { font: inherit; color: inherit; }
h1, h2, h3, p { margin: 0; }
:focus-visible { outline: 3px solid var(--amber); outline-offset: 3px; }
::selection { background: var(--amber); color: var(--navy); }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

.wrap { padding-inline: var(--margin); }
.grid { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); column-gap: 24px; }

/* Thai needs room above and below for tone marks; display leading stays loose. */
.display { font-size: var(--s-display); font-weight: 600; line-height: 1.12; letter-spacing: -0.02em; }
.head { font-size: var(--s-head); font-weight: 600; line-height: 1.2; letter-spacing: -0.01em; }
.lead { font-size: var(--s-lead); line-height: 1.55; }
.small { font-size: var(--s-small); line-height: 1.5; }

/* ---------- Buttons: one shape, a 60° chamfer on the bottom-right corner ---------- */
.btn {
  --c: var(--chamfer);
  display: inline-flex; align-items: center; gap: 10px;
  padding: 14px 30px 14px 22px;
  background: var(--amber); color: var(--ink);
  font-weight: 600; font-size: var(--s-body); line-height: 1.2;
  text-decoration: none; border: 0; cursor: pointer;
  clip-path: polygon(0 0, 100% 0, 100% calc(100% - var(--c) * 1.732), calc(100% - var(--c)) 100%, 0 100%);
  transition: transform var(--t-press) var(--ease-out), background-color var(--t-hover) ease;
}
.btn:active { transform: scale(0.97); }
.btn--navy { background: var(--navy); color: #fff; }
.btn--small { padding: 10px 24px 10px 16px; font-size: var(--s-small); --c: 10px; }
@media (hover: hover) and (pointer: fine) {
  .btn:hover { background: var(--amber-strong); }
  .btn--navy:hover { background: var(--blue); }
}
.link { text-decoration: underline; text-decoration-color: transparent; text-underline-offset: 0.25em; transition: text-decoration-color var(--t-hover) ease; }
@media (hover: hover) and (pointer: fine) { .link:hover { text-decoration-color: currentColor; } }

/* Triangle bullet: the motif at text size */
.tri-list { list-style: none; padding: 0; margin: 0; }
.tri-list li { position: relative; padding-left: 1.3em; }
.tri-list li::before {
  content: ""; position: absolute; left: 0; top: 0.62em; width: 0.62em; height: 0.54em;
  background: var(--amber); clip-path: polygon(50% 0, 100% 100%, 0 100%);
}

/* ---------- Navigation ---------- */
.nav { position: relative; z-index: 5; display: flex; align-items: center; justify-content: space-between; padding: 24px var(--margin); }
.wordmark { display: inline-flex; align-items: center; gap: 10px; text-decoration: none; font-weight: 700; letter-spacing: 0.16em; font-size: 20px; }
.wordmark svg { width: 32px; height: 32px; }
.nav__links { display: flex; align-items: center; gap: 28px; font-size: 14px; }
.nav__links a:not(.btn) { text-decoration: none; }
@media (max-width: 860px) { .nav__links a:not(.btn) { display: none; } }

/* ---------- Hero ---------- */
.hero { position: relative; min-height: max(760px, 100svh); overflow: hidden; }
.hero__copy { position: relative; z-index: 2; padding: clamp(48px, 9vh, 120px) var(--margin) 0; max-width: 820px; }
.hero__copy .display span { display: block; white-space: nowrap; }
.hero__copy .lead { margin-top: 36px; max-width: 40ch; }
.hero__copy .btn { margin-top: 32px; }

/* The giant motif: a flat amber triangle entering from the right, cropped by the viewport */
.hero__motif {
  position: absolute; z-index: 0; top: -14vh; right: -22vw;
  width: min(92vw, 1180px); aspect-ratio: 1 / 0.866;
  background: var(--amber);
  clip-path: polygon(50% 0, 100% 100%, 0 100%);
}

/* The stage: blue field, top-left corner cut on the 60° line */
.hero__stage {
  --n: clamp(80px, 9vw, 150px);
  position: absolute; z-index: 1; left: 36%; right: 0; top: 44%; bottom: 0;
  background: var(--blue);
  clip-path: polygon(0 calc(var(--n) * 1.732), var(--n) 0, 100% 0, 100% 100%, 0 100%);
}
.hero__frag { position: absolute; left: calc(var(--n) * 0.9); top: 56px; width: min(680px, calc(100% - 96px)); }

/* ---------- App fragments (data-ui): the product's own conventions ---------- */
[data-ui] { font-family: var(--font); color: #0f2233; }
.panel { background: #fff; border-radius: 10px; padding: 22px 24px 26px; }
.panel__top { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; font-size: 14px; color: #4b6074; }
.panel__top strong { font-size: 17px; color: #0f2233; font-weight: 600; }
.duval { display: grid; grid-template-columns: minmax(0, 1.08fr) minmax(0, 1fr); gap: 24px; margin-top: 16px; align-items: start; }
.duval svg { width: 100%; height: auto; overflow: visible; }
.duval .zone { stroke: #fff; stroke-width: 2; transition: opacity 300ms ease; }
.duval .zone-label { font-size: 26px; font-weight: 600; fill: #0f2233; pointer-events: none; }
.duval .zone-label--light { fill: #fff; }
.duval .axis { font-size: 26px; fill: #4b6074; }
.duval .pt { transition: transform 420ms var(--ease-out); }
.gas { display: grid; gap: 14px; }
.gas label { display: flex; justify-content: space-between; font-size: 14px; color: #4b6074; }
.gas output { color: #0f2233; font-weight: 600; font-variant-numeric: tabular-nums; }
.gas input[type=range] { width: 100%; accent-color: var(--blue); height: 28px; cursor: pointer; }
.verdict { margin-top: 6px; padding: 14px 16px; border-radius: 8px; background: #eef4fa; }
.verdict__code { display: inline-block; min-width: 2.6em; text-align: center; padding: 5px 12px; border-radius: 6px; background: var(--navy); color: #fff; font-weight: 700; font-size: 14px; }
.verdict__text { margin-top: 6px; font-size: 14px; line-height: 1.45; color: #0f2233; }
.verdict__note { margin-top: 6px; font-size: 14px; color: #4b6074; }

/* ---------- Showcase: one control, blown up ---------- */
.showcase { position: relative; height: 92svh; min-height: 640px; overflow: hidden; background: var(--blue-deep); color: #fff; transition: background-color 500ms var(--ease-in-out); }
.showcase[data-kind="motor"] { background: var(--navy); }
.showcase__copy { position: relative; z-index: 2; padding: 88px var(--margin) 0; max-width: 640px; }
.showcase__copy p { margin-top: 18px; max-width: 46ch; }
.switch {
  position: absolute; z-index: 1; left: 31%; top: 44%;
  font-size: clamp(64px, 15vh, 170px);
  display: inline-flex; padding: 0.12em; gap: 0.08em;
  background: rgba(255, 255, 255, 0.14); border-radius: 0.3em; white-space: nowrap;
}
.switch button {
  border: 0; background: transparent; color: #fff; cursor: pointer;
  padding: 0.12em 0.42em 0.2em; border-radius: 0.22em; font-weight: 600; line-height: 1.2;
  transition: background-color 300ms var(--ease-out), color 300ms var(--ease-out), transform var(--t-press) var(--ease-out);
}
.switch button[aria-pressed="true"] { background: #fff; color: var(--navy); }
.switch button:active { transform: scale(0.98); }
.showcase__photo {
  position: absolute; z-index: 1; left: var(--margin); bottom: 0; width: min(34vw, 460px); aspect-ratio: 1 / 0.866;
  clip-path: polygon(50% 0, 100% 100%, 0 100%); margin: 0;
}
.showcase__photo img { width: 100%; height: 100%; object-fit: cover; transition: opacity 400ms ease; }
.showcase__photo img[hidden] { display: block; opacity: 0; position: absolute; inset: 0; }
.showcase__cap { position: absolute; z-index: 2; left: calc(var(--margin) + min(34vw, 460px) + 20px); bottom: 28px; max-width: 26ch; font-size: var(--s-small); color: rgba(255,255,255,0.86); }

/* ---------- How it works: stages as one bar ---------- */
.how { padding-top: var(--gap-section); }
.how .display { margin-bottom: 64px; }
.bar { display: flex; gap: 6px; height: 22vh; min-height: 168px; }
.bar__seg { position: relative; padding: 20px; color: #fff; min-width: 12%; transform-origin: left; }
.bar__seg strong { font-size: clamp(20px, 2vw, 30px); font-weight: 600; line-height: 1.2; }
.bar__seg--1 { flex-grow: 1.4; background: var(--navy); }
.bar__seg--2 { flex-grow: 4; background: var(--blue-deep); }
.bar__seg--3 { flex-grow: 2; background: var(--amber); color: var(--ink); }
.bar__seg--4 { flex-grow: 1; background: var(--tint); color: var(--navy); }
.bar__notes { display: flex; gap: 6px; margin-top: 18px; }
.bar__notes p { min-width: 12%; padding-right: 16px; max-width: 30ch; }
.bar__notes p:nth-child(1) { flex-grow: 1.4; }
.bar__notes p:nth-child(2) { flex-grow: 4; }
.bar__notes p:nth-child(3) { flex-grow: 1; }
.bar__notes p:nth-child(4) { flex-grow: 2; }

/* ---------- Features: close-ups on a board ---------- */
.board-wrap { padding-top: var(--gap-section); }
.board { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); grid-auto-rows: 104px; gap: 8px; padding-inline: 10px; }
.tile { position: relative; overflow: hidden; padding: 20px; display: flex; flex-direction: column; justify-content: flex-end; }
.tile h3 { font-size: 20px; font-weight: 600; line-height: 1.3; position: relative; z-index: 1; }
.tile p { font-size: 14px; line-height: 1.45; position: relative; z-index: 1; max-width: 38ch; }
.tile > [data-ui] { position: absolute; z-index: 0; }
.t-head { grid-column: span 6; grid-row: span 2; background: var(--navy); color: #fff; justify-content: flex-start; }
.t-head h2 { font-size: var(--s-head); font-weight: 600; line-height: 1.2; }
.t-ml { grid-column: span 6; grid-row: span 2; background: var(--amber); color: var(--ink); }
.t-hi { grid-column: span 6; grid-row: span 4; background: var(--paper); }
.t-rul { grid-column: span 3; grid-row: span 4; background: var(--blue-deep); color: #fff; }
.t-trend { grid-column: span 3; grid-row: span 2; background: var(--tint); }
.t-ok { grid-column: span 3; grid-row: span 2; background: var(--paper); }
.t-log { grid-column: span 6; grid-row: span 2; background: var(--tint-2); }
.t-2fa { grid-column: span 3; grid-row: span 2; background: var(--navy); color: #fff; }
.t-xls { grid-column: span 3; grid-row: span 2; background: var(--amber); color: var(--ink); }

/* enlarged elements, built in em, cropped by two tile edges */
.ui-grade { right: -0.35em; top: -0.18em; font-size: 64px; display: flex; align-items: center; gap: 0.35em; }
.ui-grade .disc { width: 3.4em; height: 3.4em; border-radius: 50%; background: #e7f2ea; color: #1f7a3d; display: grid; place-items: center; font-weight: 700; font-size: 1em; }
.ui-grade .disc span { font-size: 2.1em; line-height: 1; }
.ui-grade .bars { display: grid; grid-template-columns: auto 3.2em; align-items: center; column-gap: 0.25em; row-gap: 0.16em; }
.ui-grade .bars span { font-size: max(12px, 0.26em); color: #4b6074; text-align: right; line-height: 1; }
.ui-grade .bars i { display: block; height: 0.16em; border-radius: 0.08em; background: #cfe0ef; }
.ui-grade .bars i b { display: block; height: 100%; width: calc(var(--v, 1) * 100%); border-radius: inherit; background: var(--blue); transform-origin: left; }
.ui-rul { left: 20px; top: 24px; font-size: 34px; color: #fff; width: 7.4em; }
.ui-rul .num { font-size: 2.4em; font-weight: 700; line-height: 1; letter-spacing: -0.02em; }
.ui-rul .unit { font-size: 0.6em; margin-left: 0.2em; }
.ui-rul .range { margin-top: 0.5em; width: 7.4em; height: 0.36em; background: rgba(255,255,255,0.22); border-radius: 0.18em; position: relative; }
.ui-rul .range b { position: absolute; left: 22%; right: 18%; top: 0; bottom: 0; background: #fff; border-radius: inherit; }
.ui-rul .range i { position: absolute; left: 48%; top: -0.22em; width: 0.12em; height: 0.8em; background: var(--amber); }
.ui-rul .ends { display: flex; justify-content: space-between; width: 100%; font-size: max(12px, 0.42em); margin-top: 0.4em; }
.ui-trend { right: -12px; top: 10px; width: 78%; }
.ui-trend svg { width: 100%; height: auto; }
.ui-trend .line { fill: none; stroke: var(--blue); stroke-width: 3; stroke-linecap: round; stroke-linejoin: round; }
.ui-trend .limit { stroke: var(--amber-strong); stroke-width: 2; stroke-dasharray: 6 6; }
.ui-ml { right: -0.15em; top: -0.32em; font-size: 120px; font-weight: 700; line-height: 1; letter-spacing: -0.03em; color: var(--navy); }
.ui-ml small { font-size: 0.28em; font-weight: 600; letter-spacing: 0; margin-left: 0.1em; }
.ui-ok { right: -0.4em; top: 0.3em; font-size: 40px; }
.ui-ok span { display: inline-block; white-space: nowrap; padding: 0.15em 0.6em; border-radius: 0.3em; background: #e7f2ea; color: #1f7a3d; font-weight: 700; }
.ui-log { right: -2em; top: 18px; font-size: 22px; display: grid; gap: 0.35em; }
.ui-log div { background: #fff; border-radius: 0.3em; padding: 0.35em 0.7em; white-space: nowrap; color: #0f2233; }
.ui-log b { color: var(--blue); font-weight: 600; }
.ui-2fa { right: -0.6em; top: 0.35em; font-size: 40px; display: flex; gap: 0.18em; color: #fff; }
.ui-2fa span { width: 1.2em; height: 1.45em; border-radius: 0.18em; background: rgba(255,255,255,0.14); display: grid; place-items: center; font-weight: 700; }
.ui-xls { right: -0.6em; top: 0.25em; font-size: 22px; background: #fff; border-radius: 0.3em; overflow: hidden; color: #0f2233; }
.ui-xls table { border-collapse: collapse; }
.ui-xls td { padding: 0.25em 0.6em; border-bottom: 1px solid #e3eaf1; white-space: nowrap; }
.ui-xls tr:first-child td { background: #eef4fa; font-weight: 600; }

/* ---------- Band: photographs in triangles, tessellated like a truss ---------- */
.band { margin-top: var(--gap-section); background: var(--navy); color: #fff; padding: 72px 0 56px; overflow: hidden; }
.band h2 { padding-inline: var(--margin); max-width: 22em; }
.truss { --w: calc((100vw - 2 * var(--margin)) / 3); position: relative; height: calc(var(--w) * 0.866); margin: 48px var(--margin) 0; }
.truss figure { position: absolute; top: 0; margin: 0; width: var(--w); height: 100%; clip-path: polygon(50% 0, 100% 100%, 0 100%); }
.truss figure.down { clip-path: polygon(0 0, 100% 0, 50% 100%); }
.truss img { width: 100%; height: 100%; object-fit: cover; filter: grayscale(1) contrast(1.06); transition: filter 500ms ease, transform 900ms var(--ease-out); }
.truss figure:nth-child(1) { left: 0; }
.truss figure:nth-child(2) { left: calc(var(--w) * 0.5); }
.truss figure:nth-child(3) { left: calc(var(--w) * 1); }
.truss figure:nth-child(4) { left: calc(var(--w) * 1.5); }
.truss figure:nth-child(5) { left: calc(var(--w) * 2); }
@media (hover: hover) and (pointer: fine) { .truss figure:hover img { filter: none; transform: scale(1.04); } }
.truss__caps { display: grid; grid-template-columns: 1fr repeat(5, 2fr) 1fr; gap: 0; text-align: center; margin: 20px var(--margin) 0; color: #fff; }
.truss__caps p { padding-inline: 8px; }
.truss__caps p:first-child { grid-column: 2; }

/* ---------- Pricing: plan names, one live figure ---------- */
.pricing { padding-top: var(--gap-section); }
.pricing > .head { margin-bottom: 40px; }
.plans { align-items: start; }
.plans__names { grid-column: 1 / span 6; display: flex; flex-direction: column; }
.plan-name {
  text-align: left; background: none; border: 0; cursor: pointer; padding: 0.04em 0 0.04em 0.6em; position: relative;
  font-size: clamp(36px, 4.6vw, 72px); font-weight: 600; line-height: 1.22; color: #5a7387;
  transition: color var(--t-hover) ease;
}
.plan-name::before {
  content: ""; position: absolute; left: 0; top: 0.5em; width: 0.32em; height: 0.28em; background: var(--amber);
  clip-path: polygon(50% 0, 100% 100%, 0 100%); opacity: 0; transform: translateX(-6px); transition: opacity 200ms ease, transform 200ms var(--ease-out);
}
.plan-name[aria-selected="true"] { color: var(--ink); }
.plan-name[aria-selected="true"]::before { opacity: 1; transform: none; }
@media (hover: hover) and (pointer: fine) { .plan-name:hover { color: var(--blue); } }
.plan-stage { grid-column: 8 / span 5; position: sticky; top: 32px; background: var(--paper); padding: 36px 36px 40px; }
.plan-stage__body { transition: opacity 200ms ease; }
.plan-stage.is-swapping .plan-stage__body { opacity: 0; }
.price { display: flex; align-items: baseline; gap: 12px; flex-wrap: wrap; }
.price .btn { margin: 0 0 0 auto; align-self: center; }
.price__fig { font-size: clamp(64px, 8vw, 128px); font-weight: 700; line-height: 1; letter-spacing: -0.03em; font-variant-numeric: tabular-nums; }
.price__per { font-size: 20px; color: var(--ink-soft); }
.plan-stage .lead { margin-top: 16px; }
.plan-stage .tri-list { margin-top: 16px; display: grid; gap: 6px; }
.plan-stage .btn { margin-top: 28px; }
.plan-year { margin-top: 10px; font-size: var(--s-small); color: var(--ink-soft); }
.plan-inline { display: none; }
.plans__all { margin-top: 40px; max-width: 46ch; }

/* ---------- FAQ: tabbed index cards ---------- */
.faq { padding-top: var(--gap-section); }
.faq__inner { grid-column: 3 / span 8; }
.faq__inner > .head { margin-bottom: 48px; }
.card { --i: 0; position: relative; margin-top: -24px; padding-top: 40px; }
.card:first-of-type { margin-top: 0; }
.card__tab {
  position: absolute; top: 0; left: calc((100% - 220px) * var(--i) / 5); width: 220px; height: 40px;
  clip-path: polygon(23px 0, calc(100% - 23px) 0, 100% 100%, 0 100%);
  display: flex; align-items: center; justify-content: center; font-size: 17px; font-weight: 600;
}
.card__body { padding: 22px 28px 26px; }
.card__q { display: block; width: 100%; text-align: left; background: none; border: 0; cursor: pointer; font-size: 20px; font-weight: 600; line-height: 1.4; padding: 0; }
.card__a { display: grid; grid-template-rows: 0fr; transition: grid-template-rows 380ms var(--ease-out); }
.card__a > div { overflow: hidden; }
.card__a p { padding-top: 12px; max-width: 54ch; font-size: var(--s-body); }
.card.is-open .card__a { grid-template-rows: 1fr; }
.card--a .card__tab, .card--a .card__body { background: var(--blue-deep); color: #fff; }
.card--b .card__tab, .card--b .card__body { background: var(--navy); color: #fff; }
.card--c .card__tab, .card--c .card__body { background: var(--tint); color: var(--ink); }

/* ---------- CTA: first step, already open ---------- */
.cta { margin-top: var(--gap-section); background: var(--amber); color: var(--ink); min-height: 80svh; padding: 64px var(--margin); }
.cta .grid { min-height: calc(80svh - 128px); align-items: stretch; }
.cta__copy { grid-column: 1 / span 5; align-self: end; }
.cta__copy .display { line-height: 1.12; }
.cta__copy p { margin-top: 20px; max-width: 40ch; }
.dialog { grid-column: 7 / span 5; align-self: start; width: 100%; max-width: 460px; background: #fff; border-radius: 12px; padding: 28px; box-shadow: 0 24px 60px rgba(2, 56, 89, 0.28); /* taste-skill-ignore: an open dialog floats */ color: #0f2233; }
.dialog h3 { font-size: 22px; font-weight: 600; }
.dialog .field { margin-top: 20px; }
.dialog label { display: block; font-size: 14px; color: #4b6074; margin-bottom: 6px; }
.dialog input[type=text] { width: 100%; padding: 12px 14px; border: 1px solid #c7d5e2; border-radius: 8px; font-size: 17px; background: #fff; }
.dialog input[type=text]:focus { outline: 2px solid var(--blue); outline-offset: 0; border-color: var(--blue); }
.url { margin-top: 8px; font-size: 14px; color: #4b6074; overflow-wrap: anywhere; }
.url b { color: var(--blue); font-weight: 600; }
.seg { display: grid; grid-template-columns: 1fr 1fr; gap: 4px; padding: 4px; background: #eef4fa; border-radius: 8px; }
.seg button { border: 0; background: transparent; padding: 10px 8px; border-radius: 6px; cursor: pointer; font-size: 14px; font-weight: 600; color: #4b6074; transition: background-color 200ms ease, color 200ms ease; }
.seg button[aria-pressed="true"] { background: #fff; color: var(--navy); }
.dialog .btn { width: 100%; justify-content: center; margin-top: 24px; min-height: 52px; }
.dialog .hint { margin-top: 10px; font-size: 14px; color: #4b6074; }

/* ---------- Footer: the mark, built large ---------- */
.foot { background: var(--navy); color: #fff; padding: 64px var(--margin) 32px; }
.blocks { display: flex; gap: 4px; align-items: flex-end; height: 34svh; min-height: 220px; }
.blocks span {
  flex: 1; display: grid; place-items: center; background: var(--blue); color: var(--navy);
  font-weight: 700; font-size: clamp(64px, 12vw, 200px); line-height: 1; transform-origin: bottom;
}
.blocks span:nth-child(1) { height: 100%; background: var(--amber); }
.blocks span:nth-child(2), .blocks span:nth-child(4) { color: var(--tint); }
.blocks span:nth-child(2) { height: 72%; }
.blocks span:nth-child(3) { height: 88%; background: var(--tint); }
.blocks span:nth-child(4) { height: 64%; }
.blocks span:nth-child(5) { height: 94%; background: var(--amber); }
.blocks span:nth-child(6) { height: 78%; background: var(--tint); }
.blocks span:nth-child(7) { height: 90%; background: var(--blue); color: var(--tint); }
.foot__cols { margin-top: 56px; row-gap: 32px; }
.foot__cols h3 { font-size: 14px; font-weight: 600; margin-bottom: 10px; }
.foot__cols ul { list-style: none; padding: 0; margin: 0; display: grid; gap: 6px; font-size: 14px; }
.foot__cols a { text-decoration: none; }
.foot__links { grid-column: span 2; }
.foot__contact { grid-column: 9 / span 4; }
.credits { margin-top: 48px; font-size: var(--s-small); color: #fff; max-width: 75ch; }
.credits a { color: #fff; }
.foot__last { margin-top: 32px; display: flex; justify-content: space-between; align-items: center; gap: 16px; font-size: var(--s-small); }

/* ---------- Phone ---------- */
@media (max-width: 860px) {
  :root { --s-lead: 18px; }
  .grid { column-gap: 12px; }
  .hero { min-height: auto; padding-bottom: 0; }
  .hero__copy { padding-top: 24px; }
  .hero__copy .display { font-size: 10.4vw; }
  .hero__motif { display: none; }
  .hero__stage { position: relative; left: 0; top: auto; margin-top: 48px; --n: 72px; padding: calc(72px * 1.732 - 40px) 16px 0; }
  .hero__frag { position: relative; left: 0; top: 0; width: 100%; }
  .duval { grid-template-columns: 1fr; }

  .showcase { height: auto; min-height: 86svh; padding-bottom: 52vw; }
  .showcase__copy { padding-top: 56px; }
  .showcase__copy .head { font-size: 26px; }
  .switch { position: relative; left: var(--margin); top: auto; margin-top: 40px; font-size: 8.4vw; }
  .showcase__photo { width: 56vw; }
  .showcase__cap { left: calc(var(--margin) + 56vw + 12px); bottom: 20px; max-width: 30vw; }

  .bar { flex-direction: column; height: 70svh; min-height: 520px; }
  .bar__seg { min-height: 72px; min-width: 0; transform-origin: top; }
  .bar__seg p.sr-on-phone { display: block; }
  .bar__notes { display: none; }
  .bar__seg .seg-note { display: block; margin-top: 6px; font-size: 17px; font-weight: 400; max-width: 34ch; }

  .board { grid-template-columns: 1fr 1fr; grid-auto-rows: min(28vw, 150px); gap: 6px; padding-inline: 6px; }
  .t-head, .t-hi, .t-ml, .t-log { grid-column: span 2; }
  .t-head { grid-row: span 2; }
  .t-hi { grid-row: span 3; }
  .t-ml, .t-log { grid-row: span 2; }
  .t-rul, .t-trend, .t-ok, .t-2fa, .t-xls { grid-column: span 1; grid-row: span 2; }
  .t-rul { grid-row: span 3; }
  .tile h3 { font-size: 17px; }
  .tile p { font-size: 14px; }
  .ui-ml { font-size: 96px; }
  .ui-grade { font-size: 44px; }
  .ui-rul { font-size: 22px; }

  .truss { --w: calc((100vw - 2 * var(--margin)) / 1.5); height: calc(var(--w) * 0.866 * 2); }
  .truss figure { height: 50%; }
  .truss figure:nth-child(1) { left: 0; top: 0; }
  .truss figure:nth-child(2) { left: calc(var(--w) * 0.5); top: 0; }
  .truss figure:nth-child(3) { left: 0; top: 50%; clip-path: polygon(0 0, 100% 0, 50% 100%); }
  .truss figure:nth-child(4) { left: calc(var(--w) * 0.5); top: 50%; clip-path: polygon(50% 0, 100% 100%, 0 100%); }
  .truss figure:nth-child(5) { display: none; }
  .truss__caps { grid-template-columns: 1fr 1fr; text-align: left; }
  .truss__caps p:first-child { grid-column: auto; }
  .truss__caps p:nth-child(5) { display: none; }

  .plans__names { grid-column: 1 / -1; }
  .plan-name { font-size: 10vw; }
  .plan-stage { display: none; }
  .plan-inline { display: block; padding: 8px 0 64px 0.6em; }
  .plan-inline[hidden] { display: none; }
  .plan-inline .price__fig { font-size: 18vw; }

  .faq__inner { grid-column: 1 / -1; }
  .card__tab { width: 140px; font-size: 14px; left: calc((100% - 140px) * var(--i) / 5); }
  .card__body { padding: 20px; }
  .card__q { font-size: 20px; }

  .cta { padding: 48px var(--margin); }
  .cta .grid { min-height: auto; row-gap: 40px; }
  .cta__copy, .dialog { grid-column: 1 / -1; }
  .cta__copy { align-self: start; }
  .cta__copy .display { font-size: 12vw; }

  .blocks { height: 22svh; min-height: 140px; }
  .blocks span { font-size: 16vw; }
  .foot__links { grid-column: span 6; }
  .foot__contact { grid-column: 1 / -1; }
  .foot__last { flex-wrap: wrap; }
}
.seg-note { display: none; }

/* ---------- Motion ---------- */
@media (prefers-reduced-motion: no-preference) {
  .js [data-reveal] { opacity: 0; transform: translateY(24px); transition: opacity 700ms var(--ease-out), transform 900ms var(--ease-out); transition-delay: var(--d, 0ms); }
  .js [data-reveal].is-in { opacity: 1; transform: none; }

  /* signature: the stage opens like a shutter, rising along the 60° notch */
  .js .hero__stage { clip-path: polygon(0 100%, 0 100%, 100% 100%, 100% 100%, 0 100%); transition: clip-path 1100ms var(--ease-in-out) 200ms; }
  .js .hero__stage.is-in { clip-path: polygon(0 calc(var(--n) * 1.732), var(--n) 0, 100% 0, 100% 100%, 0 100%); }
  .js .hero__frag { transform: scale(1.08) translateY(40px); opacity: 0; transition: transform 1500ms var(--ease-out) 500ms, opacity 900ms ease 500ms; transform-origin: top left; }
  .js .hero__stage.is-in .hero__frag { transform: none; opacity: 1; }
  .js .hero__motif { transform: translate(18%, -10%) rotate(-8deg); transition: transform 1600ms var(--ease-out); }
  .js .hero__motif.is-in { transform: none; }

  .js .duval .zone { opacity: 0; }
  .js .duval.is-drawn .zone { opacity: 1; transition: opacity 500ms ease var(--zd, 0ms); }

  .js .bar__seg { transform: scaleX(0); transition: transform 900ms var(--ease-out) var(--d, 0ms); }
  .js .bar.is-in .bar__seg { transform: none; }
  .js .ui-grade .bars i b { transform: scaleX(0); transition: transform 900ms var(--ease-out) var(--d, 0ms); }
  .js .is-in .ui-grade .bars i b, .js .ui-grade.is-in .bars i b { transform: none; }
  .js .ui-trend .line { stroke-dasharray: 600; stroke-dashoffset: 600; transition: stroke-dashoffset 1600ms var(--ease-out) 200ms; }
  .js .is-in .ui-trend .line { stroke-dashoffset: 0; }
  .js .blocks span { transform: scaleY(0.2); transition: transform 900ms var(--ease-out) var(--d, 0ms); }
  .js .blocks.is-in span { transform: none; }
  .js .truss figure img { transform: scale(1.12); transition: transform 1500ms var(--ease-out) var(--d, 0ms), filter 500ms ease; }
  .js .truss.is-in figure img { transform: none; }
  .verdict__code { transition: background-color 300ms ease; }
  .verdict.is-pulse .verdict__code { animation: pulse 500ms var(--ease-out); }
  @keyframes pulse { 0% { transform: scale(1); } 40% { transform: scale(1.18); } 100% { transform: scale(1); } }
  .pulse-path { stroke-dasharray: 60; stroke-dashoffset: 60; animation: draw 2.4s var(--ease-in-out) 0.4s infinite; }
  @keyframes draw { 0% { stroke-dashoffset: 60; } 45%, 70% { stroke-dashoffset: 0; } 100% { stroke-dashoffset: -60; } }
  @media (max-width: 860px) { .js .bar__seg { transform: scaleY(0); } }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { transition-duration: 1ms !important; animation: none !important; scroll-behavior: auto !important; }
}

[data-plans] { display: flex; flex-direction: column; }
