/* NEXLIQA public site v2 — brand v1 tokens (Business/Brand/brand.json). No script: the demo runs on :has(). */
:root {
  --navy: #0A1A3A; --royal: #0B5BFF; --cyan: #00E5FF; --gold: #F5C542; --glow: #7FDBFF;
  --bg: var(--navy); --surface: #0F2550; --surface-2: #143067; --ink: #E8EEF8; --muted: #A9B8D0;
  --accent: var(--gold); --on-accent: var(--navy); --data: var(--cyan); --data-old: #A9B8D0; --flag: var(--gold);
  --inv-bg: #E8EEF8; --inv-ink: var(--navy);
  --ui-line: #2A4A86; --radius: 0;
  --m: clamp(16px, 2.6vw, 40px);
  --t-ui: 15px; --t-body: 18px; --t-sub: 24px; --t-h2: clamp(30px, 3.2vw, 46px); --t-display: clamp(34px, 3.7vw, 60px);
  --gap: clamp(120px, 14vw, 200px);
  --ease: cubic-bezier(.2, .7, .2, 1);
  font-family: "Segoe UI", Tahoma, Arial, sans-serif;
}
@media (prefers-color-scheme: light) {
  :root {
    --bg: #F6F8FC; --surface: #E7EDF8; --surface-2: #D9E3F4; --ink: #0A1A3A; --muted: #3A4A66;
    --accent: var(--navy); --on-accent: #FFFFFF; --data: #0B5BFF; --data-old: #5A6A84; --flag: #8A5A00;
    --inv-bg: var(--navy); --inv-ink: #E8EEF8; --ui-line: #B9C8E2;
  }
}
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body { margin: 0; background: var(--bg); color: var(--ink); font-size: var(--t-body); line-height: 1.6; }
img { display: block; max-width: 100%; height: auto; }
a { color: inherit; }
:focus-visible { outline: 3px solid var(--data); outline-offset: 3px; }
::selection { background: var(--gold); color: var(--navy); }
h1, h2, h3 { margin: 0; font-weight: 600; letter-spacing: -0.01em; line-height: 1.12; }
h2 { font-size: var(--t-h2); }
h3 { font-size: var(--t-sub); }
p { margin: 0; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }

/* buttons: one shape (square), one fill */
.btn { display: inline-block; background: var(--accent); color: var(--on-accent); text-decoration: none; font-weight: 600; font-size: var(--t-body); padding: 14px 26px; transition: transform .18s var(--ease), background-color .18s var(--ease); }
.btn:hover { transform: translateY(-2px); }
.btn:active { transform: translateY(1px) scale(.98); }
.btn-small { font-size: var(--t-ui); padding: 10px 18px; }

/* bar: wordmark, three links, one action */
.bar { display: flex; align-items: center; gap: 28px; padding: 18px var(--m); }
.brand img { width: 168px; height: auto; }
.bar nav { display: flex; gap: 24px; margin-inline-start: auto; font-size: var(--t-ui); }
.bar nav a { text-decoration: none; color: var(--ink); opacity: .82; transition: opacity .15s; }
.bar nav a:hover { opacity: 1; text-decoration: underline; text-underline-offset: 6px; }

/* HERO: sentence split by the working fragment */
.hero { display: grid; grid-template-columns: 1fr minmax(480px, 34vw) 1fr; grid-template-rows: auto auto; align-items: center; column-gap: 32px; row-gap: 48px; padding: clamp(32px, 6vh, 72px) var(--m) 0; }
.split { grid-column: 1 / -1; grid-row: 1; display: grid; grid-template-columns: subgrid; align-items: center; }
.half { display: block; font-size: var(--t-display); font-weight: 600; letter-spacing: -0.025em; line-height: 1.05; white-space: nowrap; }
.half.a { grid-column: 1; justify-self: start; text-align: start; animation: in-start .9s var(--ease) both; }
.half.b { grid-column: 3; justify-self: end; text-align: end; animation: in-end .9s var(--ease) .12s both; }
.hero-frame { grid-column: 2; grid-row: 1; position: relative; }
.hero-sub { grid-column: 1 / 3; grid-row: 2; max-width: 46ch; font-size: var(--t-body); }
.hero-btn { grid-column: 3; grid-row: 2; justify-self: end; }

/* data-ui fragments: the product's own conventions apply inside */
.ui { background: var(--surface); }
.ui-top { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 12px 14px; background: var(--surface-2); font-size: var(--t-ui); }
.file { direction: ltr; color: var(--muted); }
.seg { display: inline-flex; border: 1px solid var(--ui-line); } /* taste-skill-ignore: inside data-ui (segmented control) */
.seg label { padding: 6px 12px; cursor: pointer; font-size: var(--t-ui); color: var(--muted); transition: background-color .15s, color .15s; }
.seg label:hover { color: var(--ink); }
.grid { width: 100%; border-collapse: collapse; font-size: var(--t-ui); font-variant-numeric: tabular-nums; }
.grid th, .grid td { padding: 9px 12px; text-align: start; border-bottom: 1px solid var(--ui-line); white-space: nowrap; }
.grid th { color: var(--muted); font-weight: 500; font-size: var(--t-ui); }
.grid td:nth-child(2), .grid td:nth-child(3), .grid td:nth-child(4) { direction: ltr; text-align: end; }
.ui-foot { padding: 10px 14px; font-size: var(--t-ui); color: var(--muted); }
.c { color: var(--data); }
.flag { color: var(--flag) !important; font-weight: 600; direction: rtl; }

/* hero toggle: clean by default; "as received" shows raw */
.hero-frame .r { display: none; } .hero-frame tr.dup { display: none; }
.hero-frame:has(#hv-raw:checked) .r { display: inline; color: var(--data-old); }
.hero-frame:has(#hv-raw:checked) .c { display: none; }
.hero-frame:has(#hv-raw:checked) tr.dup { display: table-row; }
.hero-frame:has(#hv-raw:checked) tr.dup td { color: var(--flag); }
.hero-frame:has(#hv-raw:checked) label[for=hv-raw], .hero-frame:has(#hv-clean:checked) label[for=hv-clean] { background: var(--accent); color: var(--on-accent); }
.hero-frame:has(#hv-raw:focus-visible) label[for=hv-raw], .hero-frame:has(#hv-clean:focus-visible) label[for=hv-clean] { outline: 3px solid var(--data); outline-offset: 2px; }

section { margin-top: var(--gap); padding-inline: var(--m); }
.hero { margin-top: 0; }
.lead { margin-top: 16px; max-width: 52ch; }

/* FEATURES: staggered fragment cells */
.fixes h2 { margin-bottom: 56px; }
.cells { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
.cell { background: var(--surface); min-height: 300px; display: flex; flex-direction: column; justify-content: space-between; overflow: hidden; transition: background-color .2s var(--ease); }
.cell:hover { background: var(--surface-2); }
.cell .txt { padding: 28px; }
.cell .txt p { margin-top: 10px; font-size: var(--t-body); }
.cell.flip { flex-direction: column-reverse; }
.frag { background: var(--surface-2); padding: 16px 20px; margin-inline-start: 28px; transition: transform .3s var(--ease); }
.cell:hover .frag { transform: translateX(-6px); }
.frag .grid td { border-bottom-color: var(--ui-line); }
.frag .gone td { text-decoration: line-through; color: var(--data-old); }
.map { list-style: none; margin: 0; padding: 0; font-size: var(--t-ui); font-variant-numeric: tabular-nums; }
.map li { display: flex; justify-content: space-between; gap: 16px; padding: 8px 0; border-bottom: 1px solid var(--ui-line); } /* taste-skill-ignore: rows inside data-ui fragments */
.map li:last-child { border-bottom: 0; }
.map s { color: var(--data-old); direction: ltr; unicode-bidi: plaintext; }
.map b { color: var(--data); font-weight: 600; direction: ltr; unicode-bidi: plaintext; }

/* LEDGER statement */
.ledger { display: grid; grid-template-columns: 5fr 7fr; gap: 56px; align-items: center; }
.ledger-pic { margin: 0; }
.ledger-pic img { width: 100%; aspect-ratio: 4 / 5; object-fit: cover; object-position: 50% 12%; }
.statement { margin-top: 28px; font-size: var(--t-sub); line-height: 1.5; max-width: 34ch; }
.caption { margin-top: 24px; font-size: var(--t-ui); color: var(--muted); }

/* SHOWCASE: live demo, CSS only */
.demo { margin-top: 40px; display: grid; grid-template-columns: 62fr 38fr; background: var(--surface); max-width: 1120px; }
.demo-view { padding: 24px; counter-reset: rows; overflow-x: auto; }
.demo-view tbody tr { counter-increment: rows; }
.rows { margin-top: 14px; font-size: var(--t-ui); color: var(--muted); }
.count::after { content: counter(rows); color: var(--ink); font-weight: 600; }
.demo-ctl { background: var(--surface-2); padding: 12px 0; }
.demo-ctl label { display: flex; align-items: center; justify-content: space-between; min-height: 52px; padding: 0 20px; cursor: pointer; font-size: var(--t-ui); transition: background-color .15s; }
.demo-ctl label:hover { background: var(--surface); }
.demo-ctl i { width: 40px; height: 22px; background: var(--ui-line); position: relative; transition: background-color .2s var(--ease); }
.demo-ctl i::after { content: ""; position: absolute; top: 3px; inset-inline-end: 3px; width: 16px; height: 16px; background: var(--ink); transition: transform .2s var(--ease); }
.hint { margin-top: 16px; font-size: var(--t-ui); color: var(--muted); }
/* state: each fix on by default */
.demo .r { display: none; } .demo .c { display: inline; } .demo tr.dup { display: none; }
.demo:has(#f-dup:not(:checked)) tr.dup { display: table-row; } .demo:has(#f-dup:not(:checked)) tr.dup td { color: var(--flag); }
.demo:has(#f-space:not(:checked)) .sp.r, .demo:has(#f-digit:not(:checked)) .dg.r, .demo:has(#f-date:not(:checked)) .dt.r, .demo:has(#f-phone:not(:checked)) .ph.r, .demo:has(#f-flag:not(:checked)) .fl.r { display: inline; color: var(--data-old); }
.demo:has(#f-space:not(:checked)) .sp.c, .demo:has(#f-digit:not(:checked)) .dg.c, .demo:has(#f-date:not(:checked)) .dt.c, .demo:has(#f-phone:not(:checked)) .ph.c, .demo:has(#f-flag:not(:checked)) .fl.c { display: none; }
.demo:has(#f-dup:checked) label[for=f-dup] i, .demo:has(#f-space:checked) label[for=f-space] i, .demo:has(#f-digit:checked) label[for=f-digit] i,
.demo:has(#f-date:checked) label[for=f-date] i, .demo:has(#f-phone:checked) label[for=f-phone] i, .demo:has(#f-flag:checked) label[for=f-flag] i { background: var(--data); }
.demo:has(#f-dup:checked) label[for=f-dup] i::after, .demo:has(#f-space:checked) label[for=f-space] i::after, .demo:has(#f-digit:checked) label[for=f-digit] i::after,
.demo:has(#f-date:checked) label[for=f-date] i::after, .demo:has(#f-phone:checked) label[for=f-phone] i::after, .demo:has(#f-flag:checked) label[for=f-flag] i::after { transform: translateX(18px); background: var(--navy); }   /* RTL: the knob starts at the left (inline end) and slides right */
.demo:has(#f-dup:focus-visible) label[for=f-dup], .demo:has(#f-space:focus-visible) label[for=f-space], .demo:has(#f-digit:focus-visible) label[for=f-digit],
.demo:has(#f-date:focus-visible) label[for=f-date], .demo:has(#f-phone:focus-visible) label[for=f-phone], .demo:has(#f-flag:focus-visible) label[for=f-flag] { outline: 3px solid var(--data); outline-offset: -3px; }

/* HOW: call and response, heading pinned while the exchanges scroll */
.how { display: grid; grid-template-columns: 4fr 8fr; gap: 56px; align-items: start; }
.how-head { position: sticky; top: 96px; }
.how-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 88px; }
.say { font-size: var(--t-sub); font-weight: 600; }
.call { margin-top: 16px; background: var(--surface); padding: 20px; max-width: 560px; }
.resp { margin-top: 16px; margin-inline-start: 56px; background: var(--surface-2); padding: 18px 20px; max-width: 520px; font-size: var(--t-ui); }
.resp.wide { margin-inline-start: 0; max-width: 760px; }
.kv { display: grid; grid-template-columns: auto 1fr; gap: 8px 20px; margin: 0; }
.kv dt { color: var(--muted); } .kv dd { margin: 0; }
.status b { color: var(--data); margin-inline-end: 10px; }
.report caption { text-align: start; font-weight: 600; padding-bottom: 10px; direction: rtl; }
.report th { color: var(--ink); font-weight: 400; font-size: var(--t-ui); }
.report td { color: var(--data); font-weight: 600; }
.report .hl th, .report .hl td { color: var(--flag); }

/* PICTURE BAND: the one moving picture */
.band { margin: var(--gap) 0 0; overflow: hidden; position: relative; }
.band img { width: 100%; height: min(78vh, 760px); object-fit: cover; animation: drift 26s ease-in-out infinite alternate; }
.band figcaption { padding: 12px var(--m) 0; font-size: var(--t-ui); color: var(--muted); }

/* FAQ: accordion of filled tiles */
.faq { display: grid; grid-template-columns: 4fr 8fr; gap: 56px; align-items: start; }
.faq h2 { position: sticky; top: 96px; }
.tiles { display: grid; gap: 8px; }
details { background: var(--surface); transition: background-color .2s var(--ease); }
details:hover { background: var(--surface-2); }
summary { list-style: none; cursor: pointer; min-height: 72px; padding: 22px 24px; display: flex; justify-content: space-between; align-items: center; gap: 20px; font-size: var(--t-sub); font-weight: 500; }
summary::-webkit-details-marker { display: none; }
summary::after { content: "+"; font-size: 28px; line-height: 1; transition: transform .2s var(--ease); }
details[open] { background: var(--accent); color: var(--on-accent); }
details[open] summary::after { content: "−"; }
details p { padding: 0 24px 24px; max-width: 52ch; font-size: var(--t-body); }

/* CONTACT: the email as display type, inverse field */
.contact { margin-top: var(--gap); background: var(--inv-bg); color: var(--inv-ink); padding: clamp(72px, 10vh, 120px) var(--m); display: flex; flex-direction: column; }
.contact-sub { margin-top: 16px; max-width: 48ch; }
.mail { margin-top: clamp(40px, 8vh, 96px); font-size: clamp(32px, 7.6vw, 132px); font-weight: 400; letter-spacing: -0.035em; line-height: 1; text-decoration: none; align-self: flex-start; word-break: break-all; transition: opacity .2s; }
.mail:hover { text-decoration: underline; text-underline-offset: .12em; text-decoration-thickness: .04em; }

/* FOOTER: a single quiet line */
.foot { display: grid; grid-template-columns: 1fr auto 1fr; align-items: baseline; gap: 12px 24px; padding: 18svh var(--m) 30px; font-size: var(--t-ui); color: var(--muted); }
.f2 { display: flex; gap: 24px; } .f2 a { color: var(--ink); }
.f3 { justify-self: end; }
.credits { grid-column: 1 / -1; font-size: var(--t-ui); color: var(--muted); }
.credits a { color: var(--ink); }

/* MOTION: load entrances, scroll entrances, one moving picture; nothing hides content without support */
@keyframes in-start { from { opacity: 0; transform: translateX(32px); } }
@keyframes in-end { from { opacity: 0; transform: translateX(-32px); } }
@keyframes rise { from { opacity: 0; transform: translateY(24px); } }
@keyframes drift { from { transform: scale(1.02) translateX(0); } to { transform: scale(1.1) translateX(-2%); } }
.rise { animation: rise .8s var(--ease) both; } .r2 { animation-delay: .2s; } .r3 { animation-delay: .32s; } .r4 { animation-delay: .44s; }
@supports (animation-timeline: view()) {
  .enter { animation: rise linear forwards; animation-timeline: view(); animation-range: entry 0% entry 55%; }   /* forwards: never hidden before it enters */
  .cells .cell:nth-child(3n+2) { animation-range: entry 8% entry 63%; }
  .cells .cell:nth-child(3n) { animation-range: entry 16% entry 71%; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; }
  html { scroll-behavior: auto; }
}

/* TABLET */
@media (max-width: 1100px) {
  .hero { grid-template-columns: 1fr 1fr; }
  .split { grid-template-columns: subgrid; }
  .half.a { grid-column: 1; } .half.b { grid-column: 2; grid-row: 1; }
  .hero-frame { grid-column: 1 / -1; grid-row: 2; }
  .hero-sub { grid-column: 1; grid-row: 3; } .hero-btn { grid-column: 2; grid-row: 3; }
  .cells { grid-template-columns: 1fr 1fr; }
  .demo { grid-template-columns: 1fr; }
  .how, .faq { grid-template-columns: 1fr; gap: 40px; }
  .how-head, .faq h2 { position: static; }
}
/* PHONE: its own composition */
@media (max-width: 700px) {
  :root { --t-body: 17px; --gap: 96px; }
  .bar { flex-wrap: wrap; gap: 12px 16px; }
  .bar nav { order: 3; width: 100%; margin: 0; gap: 20px; }
  .bar .btn-small { margin-inline-start: auto; }
  .hero { display: flex; flex-direction: column; align-items: stretch; gap: 24px; padding-top: 32px; }
  .split { display: block; } .half { white-space: normal; }
  .half { font-size: 9.4vw; }
  .half.a { text-align: start; } .half.b { align-self: flex-end; text-align: end; }
  .hero-frame { order: 0; }

  .hero-frame .grid th, .hero-frame .grid td { padding: 8px 6px; font-size: 13px; }
  .hero-frame .grid td .flag { white-space: normal; display: inline-block; max-width: 6em; }
  .hero-frame { overflow-x: auto; }
  .hero-btn { align-self: flex-start; }
  .cells { grid-template-columns: 1fr; gap: 6px; }
  .cell { min-height: 0; } .cell.flip { flex-direction: column; }
  .cell .frag { margin-inline-start: 28px; }
  .cell:nth-child(even) .frag { margin-inline-start: 0; margin-inline-end: 28px; }
  .ledger, .how, .faq { grid-template-columns: 1fr; gap: 32px; }
  .how-head, .faq h2 { position: static; }

  .resp { margin-inline-start: 0; }
  summary { font-size: var(--t-body); min-height: 64px; }
  .demo-view { padding: 12px; }
  .demo-view .grid th, .demo-view .grid td { padding: 8px 5px; font-size: 13px; }
  .demo-view .grid td .flag { white-space: normal; display: inline-block; max-width: 6em; }
  .foot { grid-template-columns: 1fr; padding-top: 20svh; }
  .f3 { justify-self: start; }

}

/* legal pages */
.doc { max-width: 760px; margin: 0 auto; padding: 48px var(--m) 0; }
.doc h1 { font-size: var(--t-h2); }
.doc h2 { font-size: var(--t-sub); margin-top: 40px; }
.doc p, .doc li { margin-top: 12px; }
.doc .note { color: var(--muted); font-size: var(--t-ui); margin-top: 16px; }
.doc .foot { padding-top: 120px; }

/* 404 */
.nf { padding: clamp(48px, 10vh, 120px) var(--m) 0; display: grid; gap: 32px; justify-items: start; max-width: 760px; }
.nf h1 { font-size: var(--t-display); }
.nf-ui { width: min(100%, 520px); }
.nf-ui th { width: 30%; }
.nf-ui a { color: var(--data); }
.nf-sub { max-width: 46ch; }
