/* adlevr.com home: the product tells its own story while you scroll. Same Ember tokens as the app
   (src/app/globals.css) and site.css; fragments inside [data-ui] follow the app's own conventions. */

.landing { --max: 1240px; --pad: clamp(16px, 3vw, 40px); background: var(--paper); overflow-x: clip; }
.landing body { font-size: 16px; }

/* Language: Thai by default; ?lang=en or the switch shows English. Without JavaScript, Thai stays. */
html:not([data-lang="en"]) .l-en { display: none !important; }
html[data-lang="en"] .l-th { display: none !important; }

.shell { max-width: var(--max); margin: 0 auto; padding-inline: var(--pad); }

/* ---------- Header: the app's pill bar ---------- */
.bar-wrap { position: sticky; top: 12px; z-index: 20; padding-inline: var(--pad); margin-top: 12px; }
.bar {
  max-width: var(--max); margin: 0 auto; height: 60px; display: flex; align-items: center; justify-content: space-between; gap: 16px;
  padding: 0 10px 0 22px; border-radius: 999px; background: var(--card);
  transition: box-shadow 240ms var(--ease-out);
}
[data-scrolled] .bar { box-shadow: 0 12px 32px -8px rgb(25 25 28 / 0.14), 0 2px 6px rgb(25 25 28 / 0.06); }
.bar .wordmark { font-size: 26px; }
.bar-links { display: flex; gap: 2px; }
.bar-links a {
  height: 40px; display: inline-flex; align-items: center; padding: 0 16px; border-radius: 999px;
  font-size: 14px; font-weight: 500; color: var(--ink-soft); transition: background-color 160ms var(--ease-out), color 160ms var(--ease-out);
}
.bar-links a:hover { background: var(--card-sub); color: var(--ink); }
.bar-end { display: flex; align-items: center; gap: 8px; }
.seg { display: flex; padding: 3px; border-radius: 999px; background: var(--paper-deep); }
.seg button {
  font: inherit; font-size: 13px; font-weight: 600; color: var(--ink-mute); border: 0; background: none; cursor: pointer;
  min-height: 34px; min-width: 44px; padding: 0 12px; border-radius: 999px; transition: background-color 160ms var(--ease-out), color 160ms var(--ease-out);
}
.seg button[aria-pressed="true"] { background: var(--card); color: var(--ink); }
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px; height: 44px; padding: 0 20px; border-radius: 999px;
  font-size: 15px; font-weight: 500; white-space: nowrap; cursor: pointer;
  transition: transform 160ms var(--ease-out), background-color 160ms var(--ease-out), color 160ms var(--ease-out);
}
.btn:active { transform: scale(0.97); }
.btn-ink { background: var(--ink); color: #fff; }
.btn-ink:hover { background: var(--ink-soft); }
.btn-ghost { color: var(--ink); padding-inline: 6px; }
.btn-ghost:hover { color: var(--accent-ink); }
.btn .i { width: 17px; height: 17px; }

/* ---------- Type ---------- */
.display { font-size: clamp(40px, 5.6vw, 80px); font-weight: 500; line-height: 1.08; letter-spacing: -0.03em; max-width: 15ch; text-wrap: balance; }
:lang(th) .display, .display .l-th { line-height: 1.2; letter-spacing: -0.01em; }
.h2 { font-size: clamp(30px, 3.6vw, 48px); font-weight: 500; line-height: 1.14; letter-spacing: -0.02em; max-width: 20ch; text-wrap: balance; }
.h2 .l-th { line-height: 1.34; letter-spacing: 0; }
.sub { font-size: 17px; line-height: 1.65; color: var(--ink-soft); max-width: 54ch; text-wrap: pretty; }
.sub .l-th { line-height: 1.8; }
.note { font-size: 13px; color: var(--ink-mute); }
.tnum { font-variant-numeric: tabular-nums; }

/* ---------- Hero ---------- */
.hero { padding-top: clamp(56px, 9vh, 112px); }
.hero-top { display: grid; grid-template-columns: minmax(0, 7fr) minmax(0, 5fr); gap: 32px 48px; align-items: end; }
.hero-side { display: grid; gap: 22px; padding-bottom: 8px; }
.hero-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 16px; }
.stage-wrap { margin-top: clamp(40px, 7vh, 80px); perspective: 1600px; }
.stage {
  position: relative; border-radius: 32px; background: var(--paper-deep); padding: clamp(14px, 2vw, 28px);
  transform-origin: 50% 0; will-change: transform;
}
.stage-label {
  display: inline-flex; align-items: center; gap: 6px; height: 28px; padding: 0 12px; margin: 2px 0 0 6px; border-radius: 999px;
  background: var(--card); color: var(--ink-soft); font-size: 12px; font-weight: 600;
}
.stage-label::before { content: ""; width: 6px; height: 6px; border-radius: 50%; background: var(--accent); }

/* ---------- App fragments: the app's own look ---------- */
[data-ui] { font-size: 14px; line-height: 1.5; color: var(--ink); }
[data-ui] .l-th { line-height: 1.6; }
.ui-hero { display: flex; justify-content: space-between; align-items: flex-end; gap: 24px; padding: 18px 10px 22px; }
.ui-hero .ui-title { color: var(--ink); margin-top: 0; font-size: 26px; font-weight: 400; letter-spacing: -0.01em; line-height: 1.2; }
.ui-hero p { font-size: 14px; color: var(--ink-mute); margin-top: 2px; }
.ui-keys { display: flex; gap: clamp(16px, 3vw, 40px); }
.ui-key { display: grid; gap: 2px; justify-items: end; text-align: right; }
.ui-key span { font-size: 13px; color: var(--ink-mute); }
.ui-key b { font-size: 26px; font-weight: 600; font-variant-numeric: tabular-nums; line-height: 1.2; }
.chg { display: inline-flex; align-items: center; height: 22px; padding: 0 8px; border-radius: 999px; font-size: 12px; font-weight: 600; font-variant-numeric: tabular-nums; }
.chg.up { background: var(--good-wash, #d7eadc); color: var(--good-ink, #23633e); }
.chg.down { background: #d7eadc; color: #23633e; }

.ui-bento { display: grid; grid-template-columns: 1fr 1.25fr 1fr 1fr; gap: 12px; }
.ui-card { background: var(--card); border-radius: 24px; padding: 20px; display: flex; flex-direction: column; gap: 8px; min-height: 196px; min-width: 0; }
.ui-card .ui-h { font-size: 15px; font-weight: 500; }
.ui-card .hint { font-size: 13px; color: var(--ink-mute); }
.ui-card .big { margin-top: auto; font-size: 40px; font-weight: 500; font-variant-numeric: tabular-nums; line-height: 1.15; }
.ui-card.orange { background: var(--accent-deep); color: #fff; }
.ui-card.orange .hint { color: #fff; }
.ui-card.orange .big { font-size: 44px; }
.ui-list { display: grid; gap: 6px; margin-top: auto; }
.ui-list div { display: flex; justify-content: space-between; gap: 10px; font-size: 13px; }
.ui-list div span:last-child { font-weight: 600; white-space: nowrap; }
.orange .ui-list div { padding: 7px 10px; border-radius: 12px; background: rgb(255 255 255 / 0.12); }
.gauge { position: relative; height: 10px; border-radius: 999px; background: var(--line-soft); overflow: hidden; margin-top: 6px; }
.gauge i { position: absolute; inset: 0 auto 0 0; width: 60%; border-radius: inherit; background: var(--accent); transform-origin: 0 50%; }
.pins { display: grid; gap: 8px; margin-top: auto; }
.pins div { display: flex; gap: 10px; align-items: baseline; font-size: 13px; color: var(--ink-soft); }
.pins b { display: inline-grid; place-items: center; flex: none; width: 20px; height: 20px; border-radius: 50%; background: var(--ink); color: #fff; font-size: 11px; font-weight: 600; }
.meter { display: grid; gap: 6px; margin-top: auto; }
.meter-bar { position: relative; height: 10px; border-radius: 999px; background: var(--line-soft); }
.meter-bar i { position: absolute; inset: 0 auto 0 0; width: 64%; border-radius: inherit; background: var(--ink); transform-origin: 0 50%; }
.meter-bar em { position: absolute; top: -4px; bottom: -4px; left: 61%; width: 2px; border-radius: 2px; background: var(--accent); }

.ui-table { margin-top: 12px; background: var(--card); border-radius: 24px; padding: 8px 20px 12px; }
.ui-table .ui-h { font-size: 15px; font-weight: 600; padding: 12px 0 6px; }
.ui-row { display: grid; grid-template-columns: minmax(0, 2.4fr) repeat(3, minmax(0, 1fr)) minmax(0, 1.5fr) 44px; gap: 12px; align-items: center; padding: 11px 0; border-top: 1px solid var(--line-soft); font-size: 14px; }
.ui-row.head { border-top: 0; color: var(--ink-mute); font-size: 13px; font-weight: 500; padding: 4px 0 8px; }
.ui-row .name { font-weight: 500; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.ui-row .name small { display: block; font-size: 13px; font-weight: 400; color: var(--ink-mute); }
.ui-row .n { text-align: right; font-variant-numeric: tabular-nums; }
.sw { justify-self: end; width: 36px; height: 22px; border-radius: 999px; background: var(--ink); position: relative; }
.sw::after { content: ""; position: absolute; top: 3px; right: 3px; width: 16px; height: 16px; border-radius: 50%; background: #fff; }
.sw.off { background: #8c8c95; }
.sw.off::after { right: auto; left: 3px; }

.chip { display: inline-flex; align-items: center; gap: 6px; height: 26px; padding: 0 10px; border-radius: 999px; font-size: 12px; font-weight: 600; white-space: nowrap; width: max-content; }
.chip .i { width: 13px; height: 13px; }
.chip.scale { background: var(--accent-wash); color: var(--accent-ink); }
.chip.steady { background: #d7eadc; color: #23633e; }
.chip.fatigue { background: #f6e8bd; color: #7a5c00; }
.chip.cut { background: #f5dad3; color: #9e2a1d; }
.chip.learning { background: var(--line-soft); color: var(--ink-soft); }

/* ---------- Sections ---------- */
.section { padding-block: clamp(96px, 14vh, 168px); }
.section-head { display: grid; gap: 18px; margin-bottom: clamp(36px, 5vh, 56px); }

/* Verdict board: a dark band, one row open. */
.dark { background: var(--ink); color: #fff; border-radius: 40px; margin-inline: clamp(8px, 1.2vw, 16px); }
.dark .sub { color: #c4c4cc; }
.board { display: grid; gap: 6px; }
.b-row {
  display: grid; grid-template-columns: minmax(0, 3fr) repeat(2, minmax(0, 1fr)) minmax(0, 1.4fr); gap: 16px; align-items: center;
  width: 100%; min-height: 76px; padding: 0 24px; border: 0; border-radius: 20px; background: #232327; color: #fff;
  font: inherit; text-align: left; cursor: pointer; transition: background-color 200ms var(--ease-out);
}
.b-row:hover { background: #2b2b30; }
.b-row .nm { font-size: clamp(17px, 1.7vw, 22px); font-weight: 500; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.b-row .nm small { display: block; font-size: 13px; font-weight: 400; color: #b9b9c2; }
.b-row .fact { font-size: 17px; font-variant-numeric: tabular-nums; }
.b-row .fact small { display: block; font-size: 13px; color: #b9b9c2; }
.b-row .chip { justify-self: end; height: 32px; padding: 0 14px; font-size: 13px; }
.b-item { border-radius: 20px; overflow: hidden; }
.b-item[data-open] { background: var(--accent-deep); }
.b-row:focus-visible { outline: 2px solid #fff; outline-offset: -4px; border-radius: 20px; }
.m-cost { display: none; white-space: nowrap; }
.b-item[data-open] .b-row { background: var(--accent-deep); }
.b-item[data-open] .b-row small { color: #fff; }
.b-detail { display: grid; grid-template-rows: 0fr; background: var(--accent-deep); transition: grid-template-rows 260ms var(--ease-out); }
.b-item[data-open] .b-detail { grid-template-rows: 1fr; }
.b-detail > div { overflow: hidden; }
.b-detail p { padding: 0 24px 24px; font-size: 17px; line-height: 1.6; max-width: 62ch; color: #fff; }
.b-detail p .l-th { line-height: 1.75; }
.b-detail b { font-weight: 600; }
.board-foot { margin-top: 22px; color: #a6a6b0; font-size: 14px; }

/* How it works: statements scroll, the stage stays. */
.how { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); gap: 48px; }
.how-steps { display: grid; grid-column: 1; grid-row: 1; }
.step { min-height: 78vh; display: flex; flex-direction: column; justify-content: center; gap: 14px; }
.step:first-child { min-height: 60vh; justify-content: flex-start; padding-top: 18vh; }
.step:last-child { min-height: 96vh; }
.step-n { font-size: 14px; font-weight: 600; color: var(--accent-ink); font-variant-numeric: tabular-nums; }
.step h3 { font-size: clamp(26px, 2.6vw, 34px); font-weight: 500; line-height: 1.22; letter-spacing: -0.015em; color: var(--ink-mute); transition: color 240ms var(--ease-out); text-wrap: balance; max-width: 18ch; }
.step h3 .l-th { line-height: 1.4; letter-spacing: 0; }
.step p { font-size: 17px; line-height: 1.7; color: var(--ink-mute); max-width: 44ch; }
.step p .l-th { line-height: 1.8; }
.step[data-active] h3 { color: var(--ink); }
.step[data-active] p { color: var(--ink-soft); }
.how-stage { grid-column: 2; grid-row: 1; align-self: start; display: grid; gap: 12px; }
.scene { display: grid; align-content: center; }
/* With JavaScript the stage pins and shows one scene at a time; without it, the three scenes stack. */
.js .how-stage { position: sticky; top: 14vh; height: 72vh; min-height: 520px; max-height: 720px; border-radius: 32px; background: var(--paper-deep); overflow: hidden; display: block; }
.js .scene {
  position: absolute; inset: clamp(16px, 2.4vw, 32px);
  opacity: 0; transform: translateY(16px) scale(0.98); transition: opacity 260ms var(--ease-out), transform 260ms var(--ease-out); pointer-events: none;
}
.js .scene[data-on] { opacity: 1; transform: none; pointer-events: auto; }
.how-label { position: relative; z-index: 2; justify-self: start; }
.js .how-label { position: absolute; top: clamp(14px, 2vw, 24px); left: clamp(14px, 2vw, 24px); margin: 0; }

.adset { background: var(--card); border-radius: 24px; padding: 22px; display: grid; gap: 16px; }
.adset-h { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; }
.adset-h b { font-size: 16px; font-weight: 600; }
.adset-h span { font-size: 13px; color: var(--ink-mute); white-space: nowrap; }
.clip { display: grid; grid-template-columns: 52px minmax(0, 1fr) auto; gap: 14px; align-items: center; }
.thumb { width: 52px; aspect-ratio: 4 / 5; border-radius: 10px; display: grid; place-items: center; overflow: hidden; }
.thumb .i { width: 16px; height: 16px; opacity: 0.85; }
.share { display: grid; gap: 6px; }
.share-top { display: flex; justify-content: space-between; gap: 8px; font-size: 14px; }
.share-top b { font-weight: 500; }
.share-bar { height: 8px; border-radius: 999px; background: var(--line-soft); overflow: hidden; }
.share-bar i { display: block; height: 100%; border-radius: inherit; background: var(--accent); transform-origin: 0 50%; }
.clip .cost { text-align: right; font-variant-numeric: tabular-nums; font-size: 14px; }
.clip .cost small { display: block; font-size: 13px; color: var(--ink-mute); }

.pace { background: var(--card); border-radius: 24px; padding: 22px; display: grid; gap: 14px; }
.pace-top { display: flex; justify-content: space-between; align-items: flex-end; gap: 16px; flex-wrap: wrap; }
.pace-top b { font-size: 16px; font-weight: 600; }
.pace-top p { font-size: 13px; color: var(--ink-mute); }
.pace-nums { display: flex; gap: 24px; }
.pace-nums div { display: grid; }
.pace-nums span { font-size: 13px; color: var(--ink-mute); }
.pace-nums strong { font-size: 22px; font-weight: 600; font-variant-numeric: tabular-nums; }
.pace svg { width: 100%; height: auto; display: block; }
.pace .plan { stroke: var(--ink-mute); stroke-width: 2; fill: none; stroke-linecap: round; }
.pace .act { stroke: var(--accent); stroke-width: 3.5; fill: none; stroke-linecap: round; stroke-linejoin: round; }
.pace .grid line { stroke: #e2e2e7; stroke-width: 1; }
.pace .now { fill: var(--accent); }
.pace text { font-family: inherit; font-size: 12px; fill: var(--ink-mute); }
.pace .status { display: inline-flex; align-items: center; gap: 8px; font-size: 14px; color: var(--ink-soft); }

.chat { display: grid; gap: 12px; justify-items: start; }
.bubble { background: var(--card); border-radius: 22px 22px 22px 6px; padding: 18px 20px; max-width: 520px; display: grid; gap: 6px; font-size: 15px; }
.bubble p { color: var(--ink); }
.bubble p:first-child { font-weight: 600; }
.chat-actions { display: flex; gap: 8px; }
.copy-btn {
  display: inline-flex; align-items: center; gap: 8px; height: 40px; padding: 0 16px; border-radius: 999px; border: 0; cursor: pointer;
  background: var(--ink); color: #fff; font: inherit; font-size: 14px; font-weight: 500; transition: transform 160ms var(--ease-out), background-color 160ms var(--ease-out);
}
.copy-btn:hover { background: var(--ink-soft); }
.copy-btn:active { transform: scale(0.97); }
.copy-btn .i { width: 16px; height: 16px; }
.chat-meta { font-size: 13px; color: var(--ink-mute); }

/* Creatives: a row that slides sideways while the page scrolls. */
.creatives { overflow: hidden; }
.track { display: flex; gap: 16px; padding-inline: max(var(--pad), calc((100vw - var(--max)) / 2 + var(--pad))); width: max-content; will-change: transform; }
.track-wrap { display: grid; gap: 14px; }
.track-label { margin: 0 auto; width: 100%; }
.cr { width: clamp(220px, min(22vw, 40svh), 300px); flex: none; background: var(--card); border-radius: 24px; padding: 10px; display: grid; gap: 12px; }
.poster { position: relative; aspect-ratio: 4 / 5; border-radius: 16px; overflow: hidden; display: grid; align-content: space-between; padding: 18px; }
.poster .art { position: absolute; inset: 0; transition: transform 420ms var(--ease-out); }
.cr:hover .poster .art { transform: scale(1.04); }
.poster strong { position: relative; font-size: 26px; font-weight: 700; line-height: 1.25; white-space: pre-line; }
.poster span { position: relative; font-size: 13px; font-weight: 500; }
.poster .shape { position: absolute; right: 14%; bottom: 12%; border-radius: 14px 14px 6px 6px; }
.poster .play { position: absolute; top: 14px; right: 14px; width: 30px; height: 30px; border-radius: 50%; background: rgb(25 25 28 / 0.55); display: grid; place-items: center; color: #fff; }
.poster .play .i { width: 13px; height: 13px; }
.cr-body { padding: 2px 8px 8px; display: grid; gap: 10px; }
.cr-name { font-size: 14px; font-weight: 500; }
.cr-name small { display: block; font-size: 13px; color: var(--ink-mute); font-weight: 400; }
.cr-nums { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.cr-nums div { display: grid; }
.cr-nums span { font-size: 13px; color: var(--ink-mute); line-height: 1.4; }
.cr-nums b { font-size: 18px; font-weight: 600; font-variant-numeric: tabular-nums; }

/* Private by design: tiles. */
.tiles { display: grid; grid-template-columns: minmax(0, 1.3fr) minmax(0, 1fr) minmax(0, 1fr); gap: 10px; }
.t-half { grid-column: span 3; }
.t-third { grid-column: span 2; }
.tile.t-ink { grid-column: span 3; background: var(--ink); color: #fff; }
.tile.t-ink p { color: #c4c4cc; }
.tile.t-ink h3 { font-size: clamp(30px, 3.4vw, 46px); }
.tile { background: var(--card); border-radius: 24px; padding: 26px; min-height: 220px; display: flex; flex-direction: column; gap: 10px; }
.tile h3 { font-size: clamp(22px, 2vw, 28px); font-weight: 500; line-height: 1.25; letter-spacing: -0.01em; }
.tile h3 .l-th { line-height: 1.4; letter-spacing: 0; }
.tile p { font-size: 15px; line-height: 1.65; color: var(--ink-soft); margin-top: auto; }
.tile p .l-th { line-height: 1.75; }
.tile.tile-lead { background: var(--accent-deep); color: #fff; }
.tile-lead h3 { font-size: clamp(30px, 3.4vw, 46px); max-width: 14ch; }
.tile-lead p { color: #fff; font-size: 17px; }
.tile-lead a { color: #fff; text-decoration: underline; text-underline-offset: 4px; text-decoration-color: rgb(255 255 255 / 0.5); }
.tile-lead a:hover { text-decoration-color: #fff; }

/* Closing field. */
.close {
  margin: 0 clamp(8px, 1.2vw, 16px); border-radius: 40px; background: var(--accent-deep); color: #fff;
  min-height: 86svh; display: grid; grid-template-columns: minmax(0, 6fr) minmax(0, 5fr); gap: 32px; align-items: end;
  padding: clamp(32px, 5vw, 72px);
}
.close-text { display: grid; gap: 18px; align-self: end; }
.close-text h2 { font-size: clamp(52px, 7.4vw, 112px); font-weight: 500; line-height: 0.98; letter-spacing: -0.035em; }
.close-text h2 .l-th { line-height: 1.22; letter-spacing: -0.01em; }
.close-text p { font-size: 17px; line-height: 1.7; color: #fff; max-width: 44ch; }
.door { align-self: center; justify-self: end; width: min(420px, 100%); background: var(--card); color: var(--ink); border-radius: 28px; padding: 32px; display: grid; gap: 18px; justify-items: center; text-align: center;
 }
.door .mark { position: relative; display: grid; place-items: center; width: 56px; height: 56px; border-radius: 17px; background: var(--ink); color: var(--paper); font-family: "Fraunces", Georgia, serif; font-weight: 600; font-size: 40px; }
.door .mark, .door .mark * { line-height: 1; }
.door .mark span { margin-top: -0.3em; margin-left: -0.04em; }
.door .mark svg { position: absolute; top: 0.24em; right: 0.27em; height: 0.3em; width: 0.26em; color: var(--accent); }
.door .wordmark { font-size: 40px; }
.door p { font-size: 14px; color: var(--ink-soft); }
.door .btn { width: 100%; height: 50px; }

/* Footer tiles. */
.foot-tiles { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); gap: 8px; padding: 8px clamp(8px, 1.2vw, 16px) 16px; }
.ft { border-radius: 24px; background: var(--card); padding: 24px; display: flex; flex-direction: column; gap: 10px; min-height: 200px; }
.ft-1 { grid-column: span 5; }
.ft-2 { grid-column: span 4; }
.ft-4 { grid-column: span 3; }
.ft-5 { grid-column: span 12; background: var(--ink); color: var(--paper); min-height: 280px; display: grid; place-items: center; overflow: hidden; }
.ft-6 { grid-column: span 4; background: var(--accent); color: var(--ink); min-height: 280px; justify-content: space-between; transition: background-color 200ms var(--ease-out); }
.ft-6:hover { background: #f5864f; }
.ft p { font-size: 15px; color: var(--ink-soft); line-height: 1.6; }
.ft .small { font-size: 13px; color: var(--ink-mute); margin-top: auto; }
.ft ul { list-style: none; padding: 0; display: grid; gap: 6px; }
.ft ul a { font-size: 16px; font-weight: 500; color: var(--ink); text-decoration: underline; text-decoration-color: transparent; text-underline-offset: 4px; transition: text-decoration-color 160ms var(--ease-out); }
.ft ul a:hover { text-decoration-color: var(--accent); }
.ft .label { font-size: 13px; color: var(--ink-mute); }
.ft .clock { font-size: 40px; font-weight: 500; font-variant-numeric: tabular-nums; margin-top: auto; line-height: 1.1; }
.ft .mail-link { margin-top: auto; font-size: 22px; font-weight: 500; color: var(--ink); text-decoration: underline; text-decoration-color: var(--line); text-underline-offset: 5px; word-break: break-all; }
.ft .mail-link:hover { text-decoration-color: var(--accent); }
.ft-5 .wordmark { font-size: clamp(88px, 13vw, 200px); color: var(--paper); }
.ft-6 strong { font-size: 28px; font-weight: 500; line-height: 1.25; }
.ft-6 svg.arrow { align-self: flex-end; width: 56px; height: 56px; }

/* ---------- Smaller screens ---------- */
@media (width < 1080px) {
  .ui-bento { grid-template-columns: 1fr 1fr; }
  .tiles { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .tile.tile-lead { grid-column: span 2; }
}
@media (width < 860px) {
  .bar { padding-left: 18px; }
  .bar-links { display: none; }
  .bar .btn-ink span.l-en, .bar .btn-ink span.l-th { font-size: 14px; }
  .hero-top { grid-template-columns: 1fr; }
  .display { font-size: clamp(44px, 9vw, 80px); }
  .ui-hero { flex-direction: column; align-items: flex-start; }
  .ui-key { justify-items: start; text-align: left; }
  .ui-row { grid-template-columns: minmax(0, 1fr) auto; }
  .ui-row > :nth-child(2), .ui-row > :nth-child(3), .ui-row > :nth-child(4), .ui-row > :nth-child(6) { display: none; }
  .b-row { grid-template-columns: minmax(0, 1fr) auto; min-height: 68px; padding: 0 16px; }
  .b-row .fact { display: none; }
  .m-cost { display: inline; }
  .b-row .nm { white-space: normal; }
  .b-row .nm small { line-height: 1.5; }
  .b-detail p { padding: 0 16px 18px; font-size: 16px; }
  .how { display: block; }
  .js .how-stage { top: 84px; height: 52svh; min-height: 400px; z-index: 1; }
  .step, .step:first-child, .step:last-child { min-height: 62svh; padding-top: 28px; justify-content: flex-start; }
  .creatives .track { width: auto; overflow-x: auto; scroll-snap-type: x mandatory; scroll-padding-inline: var(--pad); padding-bottom: 8px; scrollbar-width: none; }
  .creatives .cr { scroll-snap-align: start; width: min(74vw, 340px); }
  .close { grid-template-columns: 1fr; align-items: start; min-height: auto; }
  .door { justify-self: stretch; width: 100%; }
  .foot-tiles { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 6px; }
  .ft-1, .ft-5 { grid-column: span 2; }
  .ft-2, .ft-4 { grid-column: span 1; min-height: 160px; }
  .ft-5 { min-height: 180px; }
}
@media (width < 560px) {
  .stage .ui-table, .stage .ui-card:nth-child(3) { display: none; }
  .clip { grid-template-columns: 40px minmax(0, 1fr) auto; gap: 10px; }
  .thumb { width: 40px; }
  .share-top { font-size: 13px; }
  .share-top b { white-space: nowrap; }
  .clip .spend { display: none; }
  .clip .cost small { max-width: 9em; margin-left: auto; }
  .adset { padding: 16px; gap: 14px; }
  .adset-h { flex-direction: column; gap: 2px; }
  .pace { padding: 16px; }
  .pace text { display: none; }
  .bubble { padding: 14px 16px; font-size: 14px; }
  .seg button { min-width: 40px; padding: 0 10px; }
  .bar .btn-ink { padding: 0 14px; height: 40px; }
  .bar .btn-ink .i { display: none; }
  .ui-bento { grid-template-columns: 1fr; }
  .ui-card { min-height: 150px; }
  .tiles { grid-template-columns: 1fr; }
  .tile.tile-lead { grid-column: span 1; }
  .tile { min-height: 0; }
  .ft-1, .ft-2, .ft-4 { grid-column: span 2; }
}

@media (prefers-reduced-motion: reduce) {
  .js .scene { transition: none; transform: none; }
}

/* Demo creatives: the clients' own poster colours (src/lib/demo/seed.ts), as classes because the
   site's CSP allows no inline styles. */
.pt-butter { background: #F2C230; color: #1C1B18; }
.pt-tomato { background: #E8461E; color: #FFF6EE; }
.pt-blush { background: #F2C9BC; color: #1C1B18; }
.pt-cobalt { background: #2F47D8; color: #EEF0FF; }
.pt-ink { background: #1C1B18; color: #EFECE6; }
.pt-paper { background: #EFECE6; color: #1C1B18; }
.pt-sky { background: #C9D4F6; color: #1C1B18; }
.acc-butter { background: #F2C230; }
.acc-tomato { background: #E8461E; }
.acc-cobalt { background: #2F47D8; }
.shape { position: absolute; right: 14%; bottom: 12%; width: 22%; height: 44%; border-radius: 14px 14px 6px 6px; }
.shape.bottle { width: 20%; height: 38%; border-radius: 12px 12px 8px 8px; }
.shape.bottle::before { content: ""; position: absolute; left: 32%; right: 32%; top: -18%; height: 20%; border-radius: 4px 4px 0 0; background: inherit; }
.shape.split { inset: 0 0 0 50%; width: auto; height: auto; border-radius: 0; opacity: 0.4; }
.shape.chat { width: 48%; height: 18%; right: 10%; bottom: 16%; border-radius: 16px 16px 16px 4px; }
.share-bar i.s58 { width: 58%; }
.share-bar i.s27 { width: 27%; }
.share-bar i.s15 { width: 15%; }
.chg.flat { background: var(--line-soft); color: var(--ink-soft); }
.tile-lead .h2 { color: inherit; }
.copy-btn > span { display: inline-flex; align-items: center; gap: 8px; }
.copy-btn .lbl-done { display: none; }
.copy-btn[data-done] .lbl-copy { display: none; }
.copy-btn[data-done] .lbl-done { display: inline-flex; }

/* Headline phrases never break inside; lines break between them. */
.nw { white-space: nowrap; }
.pt-sage { background: #A9C1A0; color: #1C1B18; }

.tile-lead :focus-visible, .close :focus-visible, .dark :focus-visible { outline-color: #fff; }
.tile { min-height: 300px; }
.tile:not(.tile-lead) p { margin-top: 0; }
.tile-ui { margin-top: auto; display: grid; gap: 12px; padding: 16px; border-radius: 16px; background: var(--card-sub); }
.ro-row { display: flex; justify-content: space-between; align-items: center; gap: 12px; font-size: 14px; font-weight: 500; }
.sw.dim { opacity: 0.4; }
.meters { gap: 10px; }
.mt { display: grid; grid-template-columns: 5.5em minmax(0, 1fr) auto; gap: 10px; align-items: center; font-size: 13px; }
.mt span { color: var(--ink-mute); }
.mt b { font-weight: 600; font-variant-numeric: tabular-nums; }
.mt-bar { height: 8px; border-radius: 999px; background: var(--line-soft); overflow: hidden; }
.mt-bar i { display: block; height: 100%; border-radius: inherit; background: var(--ink); }
.mt-bar i.m13 { width: 13%; } .mt-bar i.m8 { width: 8%; } .mt-bar i.m6 { width: 6%; }
.mt-note { font-size: 12px; color: var(--ink-mute); }
.shape-svg { position: absolute; right: 12%; bottom: 10%; width: 26%; height: auto; }
.shape-svg.split { inset: 0; width: 100%; height: 100%; }
.shape-svg.chat { width: 52%; right: 9%; bottom: 14%; }
