﻿/* Cabinet Dentaire Anfa (a fictional practice, a Repliwave demo). The site is a tooth chart: tap a tooth, say what it needs, and an estimate writes itself.
   Mint paper, deep teal, white. Geist Mono for headings and figures, Geist for text; Arabic uses the system font.
   Logical properties only, so Arabic mirrors by itself (the chart is a picture of a mouth and keeps its sides). Breakpoints: base (375), 768, 1280. */
:root { --bg: #eef4f2; --fg: #12302f; --acc: #0f6b6b; --card: #fff; --card-fg: #12302f; --line: rgba(18, 48, 47, .18); --soft: rgba(18, 48, 47, .72);
  --mono: 'Geist Mono', ui-monospace, 'SF Mono', Menlo, Consolas, monospace; --sans: 'Geist', system-ui, -apple-system, 'Segoe UI', sans-serif; --display: var(--mono);
  --ar: 'Geeza Pro', 'Noto Naskh Arabic', 'Noto Sans Arabic', 'Segoe UI', Tahoma, 'DejaVu Sans', sans-serif;
  --hw: 500; --ls: -.05em; --r: 12px; --pill: 10px; --gut: clamp(1.1rem, 4vw, 4rem); --foot-bg: #0b2726; --foot-fg: #eef4f2; --foot-mark: #7fc4bd; --bg-light: #eef4f2; --chip-bg: #fff; --chip-fg: #12302f; }
* { box-sizing: border-box; margin: 0; }
html { scroll-behavior: smooth; scroll-padding-top: 4.5rem; -webkit-text-size-adjust: 100%; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } *, *::before, *::after { transition-duration: .01ms !important; animation: none !important; } }
body { background: var(--bg); color: var(--fg); font: 400 1.0625rem/1.6 var(--sans); -webkit-font-smoothing: antialiased; overflow-x: clip; }
[dir='rtl'] body, [dir='rtl'] input, [dir='rtl'] textarea, [dir='rtl'] button { font-family: var(--ar); }
a { color: inherit; }
button, input, textarea { font: inherit; color: inherit; }
[hidden] { display: none !important; }
::selection { background: var(--acc); color: #fff; }
:focus-visible { outline: 2px solid var(--focus, var(--acc)); outline-offset: 3px; }
.skip { position: absolute; inset-inline-start: -999px; top: .5rem; z-index: 60; background: var(--fg); color: var(--bg); padding: .5rem .9rem; }
.skip:focus { inset-inline-start: .5rem; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
h1, h2, h3 { font-family: var(--display); font-weight: var(--hw); letter-spacing: var(--ls); }
[dir='rtl'] h2, [dir='rtl'] h3 { font-family: var(--ar); font-weight: 700; letter-spacing: 0; }
.wrap { max-width: 86rem; margin-inline: auto; padding-inline: var(--gut); }
.bar { position: sticky; top: 0; z-index: 30; display: flex; align-items: center; gap: 1rem; padding: max(.5rem, env(safe-area-inset-top)) var(--gut) .5rem; background: color-mix(in srgb, var(--bg) 90%, transparent); box-shadow: 0 1px 0 var(--line); backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px); }
.brand { font: var(--hw) 1.25rem/1 var(--display); letter-spacing: var(--ls); text-decoration: none; white-space: nowrap; }
.menu { display: none; gap: 1.5rem; margin-inline-start: auto; }
.menu a { display: inline-flex; align-items: center; min-height: 2.75rem; font-size: .92rem; text-decoration: none; }
.menu a:hover { text-decoration: underline; text-underline-offset: .4em; text-decoration-thickness: 1px; }
.tools { display: flex; align-items: center; gap: .5rem; margin-inline-start: auto; }
.langs { display: flex; }
.langs button { background: none; border: 0; font: 400 .74rem/1 var(--mono); padding: .5rem .45rem; min-width: 2.3rem; min-height: 2.75rem; cursor: pointer; opacity: .75; border-radius: 99px; }
.langs button[lang='ar'] { font-family: var(--ar); font-size: .95rem; }
.langs button[aria-pressed='true'] { opacity: 1; background: var(--fg); color: var(--bg); }
.badge { display: inline-flex; align-items: center; white-space: nowrap; min-height: 2.75rem; font-size: .78rem; text-decoration: none; border: 1px solid currentColor; border-radius: 99px; padding: .5rem .85rem; }
.badge .full { display: none; }
@media (min-width: 560px) { .badge .full { display: inline; } .badge .short { display: none; } }
@media (min-width: 900px) { .menu { display: flex; } .tools { margin-inline-start: 1.2rem; } }
.kicker { font: 400 .78rem/1.4 var(--mono); color: var(--acc2, var(--acc)); margin-bottom: .3rem; }
[dir='rtl'] .kicker { font-family: var(--ar); font-size: .92rem; }
.lead { color: var(--soft); max-width: 48ch; margin-top: .5rem; font-size: 1rem; }
[dir='rtl'] .lead { line-height: 1.9; }
.card > * { min-width: 0; }
.card { background: var(--card); color: var(--card-fg); --line: color-mix(in srgb, var(--card-fg) 18%, transparent); --soft: color-mix(in srgb, var(--card-fg) 70%, transparent); border-radius: var(--r); padding: 1.3rem; display: grid; gap: 1rem; }
.field { display: grid; gap: .35rem; font-size: .8rem; color: var(--soft); }
.card input[type=text], .card input[type=email], .card textarea { width: 100%; background: #fff; border: 1px solid color-mix(in srgb, var(--card-fg) 32%, transparent); border-radius: calc(var(--r) * .5); padding: .7rem .9rem; font-size: 1rem; min-height: 2.9rem; color: var(--card-fg); }
.card textarea { resize: vertical; }
.card [aria-invalid='true'] { border-color: #b3261e; }
.err { font-size: .78rem; color: #b3261e; min-height: 1em; }
.cta { display: inline-flex; align-items: center; justify-content: center; font-size: .95rem; font-weight: 500; text-decoration: none; text-align: center; border: 1px solid currentColor; border-radius: var(--pill, 99px); padding: .85rem 1.4rem; min-height: 3rem; cursor: pointer; background: transparent; color: inherit; transition: background-color .25s, color .25s, border-color .25s, opacity .25s; }
.cta.primary { background: var(--acc); border-color: var(--acc); color: #fff; width: 100%; }
.cta.primary:hover { background: var(--card-fg); border-color: var(--card-fg); }
.cta.primary:disabled { opacity: .35; pointer-events: none; }
.cta.light { background: var(--bg-light, #fff); border-color: var(--bg-light, #fff); color: var(--foot-bg); }
.textlink { background: none; border: 0; padding: 0; min-height: 2.75rem; cursor: pointer; font-size: .9rem; color: var(--acc); text-decoration: underline; text-underline-offset: .3em; text-decoration-thickness: 1px; justify-self: start; text-align: start; }
.small { font-size: .8rem; color: var(--soft); }
.ref { display: inline-grid; gap: .15rem; padding: .7rem 1rem; background: color-mix(in srgb, var(--card-fg) 7%, transparent); border-radius: calc(var(--r) * .6); justify-self: start; }
.ref b { font: 600 1.3rem/1.1 var(--mono); }
.ref span { font-size: .74rem; color: var(--soft); }
.done h3 { font-size: 1.7rem; line-height: 1.1; }
[dir='rtl'] .done h3 { font-size: 1.35rem; line-height: 1.5; }
.done dl { display: grid; gap: .5rem; margin: 0; }
.done dt { font-size: .74rem; color: var(--soft); }
.done dd { margin: 0; font-weight: 500; overflow-wrap: anywhere; }
.row { display: flex; gap: .4rem; overflow-x: auto; scrollbar-width: none; padding-bottom: .15rem; }
.row::-webkit-scrollbar { display: none; }
.day { flex: none; display: grid; justify-items: center; gap: .1rem; min-width: 3.6rem; min-height: 3.4rem; padding: .4rem .6rem; border: 1px solid var(--line); border-radius: calc(var(--r) * .6); background: transparent; cursor: pointer; font-size: .72rem; color: var(--soft); }
.day b { font: 600 1.05rem/1 var(--mono); color: var(--card-fg); }
.day[aria-pressed='true'] { background: var(--acc); border-color: var(--acc); color: #fff; }
.day[aria-pressed='true'] b { color: #fff; }
.day:disabled { opacity: .32; cursor: default; }
.sec { padding-block: clamp(3.5rem, 8vw, 6.5rem); }
.sec h2 { font-size: clamp(2.2rem, 6vw, 4.6rem); line-height: 1; }
[dir='rtl'] .sec h2 { font-size: clamp(1.9rem, 4.6vw, 3.2rem); line-height: 1.3; }
.rules { list-style: none; padding: 0; margin-top: 1.6rem; display: grid; gap: .8rem; max-width: 46ch; color: var(--soft); }
.rules li { padding-inline-start: 1.2rem; position: relative; }
.rules li::before { content: ''; position: absolute; inset-inline-start: 0; top: .62em; width: .5rem; height: .5rem; border-radius: 50%; background: var(--acc); }
.qchips { display: flex; flex-wrap: wrap; gap: .6rem; margin-top: 2rem; }
.qchips button { background: var(--chip-bg, #fff); color: var(--chip-fg, #222); border: 0; border-radius: var(--pill, 99px); padding: .8rem 1.3rem; min-height: 3rem; cursor: pointer; text-align: start; font-size: clamp(1rem, 1.7vw, 1.2rem); transition: background-color .25s, color .25s; }
.qchips button:hover { background: var(--acc); color: #fff; }
.foot { background: var(--foot-bg); color: var(--foot-fg); padding-top: clamp(3rem, 7vw, 5rem); overflow: clip; }
.foot .wrap { display: grid; gap: 1.4rem; justify-items: start; }
.foot-note { max-width: 44ch; opacity: .9; }
.wordmark { font: var(--hw) clamp(2.6rem, 13vw, 13rem)/.85 var(--display); letter-spacing: var(--ls); white-space: nowrap; text-align: center; color: var(--foot-mark); margin-top: 2.5rem; padding-bottom: 5rem; }
@keyframes pop { from { opacity: 0; transform: translateY(8px); } }
.pop { animation: pop .5s cubic-bezier(.2, .8, .2, 1) both; }

.clinic { padding-block: clamp(1rem, 2vw, 1.8rem) clamp(2.5rem, 5vw, 4.5rem); background-image: linear-gradient(90deg, rgba(18, 48, 47, .06) 1px, transparent 1px); background-size: calc(100% / 12) 100%; }
.intro { display: grid; gap: .6rem 2.5rem; align-items: end; margin-bottom: 1.2rem; }
@media (min-width: 860px) { .intro { grid-template-columns: auto 1fr; } .intro > div:last-child { max-width: 32rem; justify-self: end; } }
h1 { font-size: clamp(2rem, 4.6vw, 3.8rem); line-height: .95; max-width: 12ch; }
@media (max-width: 599px) { .brand { white-space: normal; font-size: .86rem; line-height: 1.05; max-width: 9ch; } .bar { gap: .5rem; } }
.intro h2 { font-size: clamp(1.3rem, 2.2vw, 1.8rem); line-height: 1.15; color: var(--acc); }
[dir='rtl'] .intro h2 { line-height: 1.5; }
.board { display: grid; gap: 1.6rem; }
@media (min-width: 1040px) { .board { grid-template-columns: minmax(0, 1fr) 25rem; gap: 2.5rem; align-items: start; } }
.chartbox { position: relative; background: radial-gradient(120% 90% at 50% 20%, #fff, #f1f7f5 70%, #e2eeeb); border-radius: var(--r); box-shadow: 0 0 0 1px var(--line), 0 30px 60px -40px rgba(18, 48, 47, .5); padding: clamp(.6rem, 2vw, 1.4rem); max-width: 38rem; margin-inline: auto; }
@media (min-width: 1040px) { .chartbox, .whole { max-width: min(38rem, max(21rem, calc((100svh - 17.5rem) * .68))); } } /* the whole mouth fits on a laptop screen */
#chart { display: block; width: 100%; height: auto; touch-action: manipulation; }
#chart text { font: 500 13px var(--mono); fill: rgba(18, 48, 47, .55); text-anchor: middle; dominant-baseline: central; }
#chart .tooth { cursor: pointer; outline: none; }
#chart .lift { transition: transform .3s cubic-bezier(.2, .8, .2, 1); transform-box: fill-box; transform-origin: center; }
#chart .body { fill: url(#enamel); stroke: #9fb3b0; stroke-width: 1; transition: fill .3s, stroke .3s, opacity .3s; }
#chart .groove { fill: none; stroke: rgba(18, 48, 47, .2); stroke-width: 1.6; stroke-linecap: round; }
#chart .cusp { fill: #fff; opacity: .85; }
#chart .tooth:hover .lift, #chart .tooth:focus-visible .lift { transform: scale(1.12) translateY(-1.5px); }
#chart .tooth:focus-visible .body { stroke: var(--acc); stroke-width: 2.5; }
#chart .tooth.open .lift { transform: scale(1.18) translateY(-2px); }
#chart .tooth.open .body { stroke: var(--acc); stroke-width: 3; }
#chart .dot { fill: #2f8f8a; stroke: #0f6b6b; stroke-width: 1.2; opacity: 0; transition: opacity .3s; }
#chart .dotgl { fill: #fff; opacity: 0; transition: opacity .3s; }
#chart .cross { stroke: #b4442c; stroke-width: 3; stroke-linecap: round; fill: none; opacity: 0; transition: opacity .3s; }
#chart .tooth.filling .dot { opacity: 1; } #chart .tooth.filling .dotgl { opacity: .8; }
#chart .tooth.crown .body { fill: url(#goldG); stroke: #8a6a12; }
#chart .tooth.crown .groove { stroke: rgba(90, 60, 5, .4); }
#chart .tooth.extract .body { fill: #fbeeea; stroke: #b4442c; stroke-dasharray: 4 3; opacity: .55; }
#chart .tooth.extract .groove, #chart .tooth.extract .cusp { opacity: 0; }
#chart .tooth.extract .cross { opacity: 1; }
#chart .tooth.hint .lift { animation: hint 1.6s ease-in-out infinite; }
@keyframes hint { 50% { transform: scale(1.2) translateY(-2px); } }
.pop { position: absolute; z-index: 5; width: 15.5rem; background: #12302f; color: #eef4f2; border-radius: var(--r); padding: .8rem; display: grid; gap: .35rem; box-shadow: 0 20px 40px -12px rgba(18, 48, 47, .55); animation: pop .25s cubic-bezier(.2, .8, .2, 1); }
[dir='rtl'] .pop, .chartbox .pop { direction: inherit; }
.pop h3 { font-size: 1rem; flex: 1; text-align: center; }
.pop .head { display: flex; align-items: center; justify-content: space-between; gap: .5rem; }
.pop .head button { width: 2.9rem; justify-content: center; font-size: 1.2rem; padding: 0; }
.pop button { display: flex; justify-content: space-between; align-items: center; gap: .8rem; width: 100%; min-height: 2.9rem; padding: .4rem .7rem; border: 1px solid rgba(238, 244, 242, .25); border-radius: 8px; background: transparent; cursor: pointer; text-align: start; font-size: .92rem; }
.pop button b { font: 500 .8rem/1 var(--mono); opacity: .8; white-space: nowrap; }
.pop button:hover, .pop button[aria-pressed='true'] { background: #eef4f2; color: #12302f; }
.whole { display: flex; flex-wrap: wrap; align-items: center; gap: .5rem 1rem; margin-top: 1rem; max-width: 38rem; margin-inline: auto; }
.lab { font: 400 .76rem/1 var(--mono); color: var(--soft); }
[dir='rtl'] .lab { font-family: var(--ar); font-size: .9rem; }
.wchips { display: flex; flex-wrap: wrap; gap: .4rem; }
.wchip { display: inline-flex; align-items: center; gap: .5rem; min-height: 2.75rem; padding: .4rem .8rem; border: 1px solid var(--line); border-radius: var(--pill); background: #fff; cursor: pointer; font-size: .9rem; }
.wchip input { width: 1.1rem; height: 1.1rem; accent-color: var(--acc); }
.wchip b { font: 500 .78rem/1 var(--mono); color: var(--soft); }
.wchip:has(input:checked) { border-color: var(--acc); box-shadow: inset 0 0 0 1px var(--acc); }
.sheet { position: relative; box-shadow: 0 0 0 1px var(--line), 0 30px 60px -40px rgba(18, 48, 47, .5); border-radius: var(--r) var(--r) 0 0; padding-bottom: 1.8rem; }
.sheet::after { content: ''; position: absolute; inset-inline: 0; bottom: -10px; height: 10px; background: linear-gradient(135deg, #fff 50%, transparent 50%) 0 0 / 14px 10px, linear-gradient(225deg, #fff 50%, transparent 50%) 0 0 / 14px 10px; }
@media (min-width: 1040px) { .sheet { position: sticky; top: 4.6rem; } }
.sheet .top { display: flex; justify-content: space-between; align-items: baseline; gap: 1rem; border-bottom: 1px dashed var(--line); padding-bottom: .7rem; }
.sheet h2 { font-size: 1.35rem; line-height: 1.1; }
.sheet .date { font: 400 .72rem/1 var(--mono); color: var(--soft); }
.qlines { list-style: none; padding: 0; display: grid; }
.qlines li { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 0 1rem; padding-block: .55rem; border-bottom: 1px dashed var(--line); }
.qlines li.new { animation: print .5s cubic-bezier(.2, .8, .2, 1) both; }
@keyframes print { from { opacity: 0; transform: translateY(-8px); clip-path: inset(0 0 100% 0); } to { clip-path: inset(0); } }
.qlines strong { font-weight: 600; font-size: .96rem; }
.qlines b { font: 500 .95rem/1.5 var(--mono); white-space: nowrap; }
.qlines small { grid-column: 1 / -1; font-size: .78rem; color: var(--soft); }
.qtotal { display: flex; justify-content: space-between; align-items: baseline; gap: 1rem; }
.qtotal span { font-size: .85rem; color: var(--soft); }
.qtotal b { font: 500 1.9rem/1 var(--mono); letter-spacing: -.04em; }
[dir='rtl'] .qlines b, [dir='rtl'] .qtotal b { font-family: var(--ar); }
.emptyq { padding: 1.4rem 1rem; border: 1px dashed var(--line); border-radius: 10px; color: var(--soft); text-align: center; }
.white { background: #fff; }
.two { display: grid; grid-template-columns: minmax(0, 1fr); gap: 2.5rem; }
@media (min-width: 960px) { .two { grid-template-columns: 5fr 6fr; gap: 5rem; align-items: start; } }
.prices { list-style: none; padding: 0; border-bottom: 1px solid var(--line); }
.prices li { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: .1rem 1rem; padding-block: .9rem; border-top: 1px solid var(--line); }
.prices h3 { font-size: clamp(1.2rem, 2.2vw, 1.6rem); line-height: 1.15; }
.prices b { font: 500 1rem/1.5 var(--mono); color: var(--acc); white-space: nowrap; }
.prices small { grid-column: 1 / -1; font: 400 .78rem/1.3 var(--mono); color: var(--soft); }
[dir='rtl'] .prices b, [dir='rtl'] .prices small { font-family: var(--ar); }
.teal { background: var(--acc); color: #eef4f2; --soft: rgba(238, 244, 242, .86); --focus: #eef4f2; }
.teal .qchips button:hover { background: #12302f; }

/* finish: weight and light on everything you can press, steadier numerals, cleaner type */
body { text-rendering: optimizeLegibility; font-kerning: normal; }
h1, h2, h3 { text-wrap: balance; }
output, time, .price, .mono, .qtotal b, .priceline b, .ref b, .num { font-variant-numeric: tabular-nums; }
.cta, .chip, .day, .slot, .sw, .quick, .wchip, .qchips button, .chips button, .nudge button, .qty button, .moon, .langs button { transition-property: background-color, color, border-color, transform, box-shadow, opacity; transition-duration: .2s; transition-timing-function: cubic-bezier(.2, .8, .2, 1); }
.cta:active, .chip:active, .day:active, .slot:active, .sw:active, .quick:active, .wchip:active, .qchips button:active, .chips button:active, .nudge button:active { transform: translateY(1px) scale(.985); }
.cta.primary, .cta.terra { box-shadow: inset 0 1px 0 rgba(255, 255, 255, .22), 0 12px 22px -14px rgba(0, 0, 0, .65); }
.cta.primary:hover, .cta.terra:hover { box-shadow: inset 0 1px 0 rgba(255, 255, 255, .18), 0 16px 26px -14px rgba(0, 0, 0, .7); transform: translateY(-1px); }
.card, .panel, .summary { box-shadow: inset 0 1px 0 rgba(255, 255, 255, .7), 0 1px 2px rgba(0, 0, 0, .06), 0 22px 44px -26px rgba(0, 0, 0, .5), 0 60px 90px -70px rgba(0, 0, 0, .45); }
input[type=text], input[type=email], input[type=tel], textarea { transition: border-color .2s, box-shadow .2s; box-shadow: inset 0 1px 2px rgba(0, 0, 0, .06); }
input[type=text]:focus-visible, input[type=email]:focus-visible, input[type=tel]:focus-visible, textarea:focus-visible { box-shadow: inset 0 1px 2px rgba(0, 0, 0, .06), 0 0 0 4px color-mix(in srgb, currentColor 14%, transparent); }
.day[aria-pressed='true'], .slot[aria-pressed='true'], .chip[aria-pressed='true'] { box-shadow: inset 0 1px 0 rgba(255, 255, 255, .2), 0 8px 14px -10px rgba(0, 0, 0, .6); }

/* talk: the assistant shown as a conversation; facts as numbered cards; the footer name fitted to its width */
:root { --t-acc: #0f6b6b; --t-bg: #0f6b6b; --t-fg: #eef4f2; }
.talk { background: var(--t-bg) !important; color: var(--t-fg) !important; }
.talk .lead { color: color-mix(in srgb, var(--t-fg) 82%, transparent) !important; }
.talkgrid { display: grid; gap: 2rem; align-items: center; }
@media (min-width: 900px) { .talkgrid { grid-template-columns: minmax(0, 5fr) minmax(0, 6fr); gap: 4rem; } }
.chat { position: relative; background: #fffdf9; color: #1d2422; border-radius: 1.6rem; padding: 1.3rem; display: grid; gap: 1rem; max-width: 34rem; width: 100%; justify-self: end; box-shadow: inset 0 1px 0 rgba(255, 255, 255, .9), 0 2px 4px rgba(0, 0, 0, .08), 0 30px 60px -30px rgba(0, 0, 0, .55), 0 70px 90px -70px rgba(0, 0, 0, .5); transform: rotate(-.6deg); }
[dir='rtl'] .chat { transform: rotate(.6deg); }
.chat .who { display: flex; align-items: center; gap: .8rem; padding-bottom: .9rem; border-bottom: 1px solid rgba(29, 36, 34, .1); }
.chat .av { width: 2.8rem; height: 2.8rem; border-radius: 50%; display: grid; place-items: center; background: radial-gradient(circle at 34% 28%, color-mix(in srgb, var(--t-acc) 60%, #fff), var(--t-acc) 62%, color-mix(in srgb, var(--t-acc) 70%, #000)); color: #fff; font-weight: 600; font-size: 1.15rem; box-shadow: 0 6px 12px -6px rgba(0, 0, 0, .5); }
.chat .who strong { display: block; font-weight: 600; font-size: 1.05rem; line-height: 1.2; }
.chat .who small { display: flex; align-items: center; gap: .4rem; font-size: .8rem; color: rgba(29, 36, 34, .65); }
.chat .who small::before { content: ''; width: .5rem; height: .5rem; border-radius: 50%; background: #3fae6a; box-shadow: 0 0 0 3px rgba(63, 174, 106, .2); }
.chat .bubble { justify-self: start; max-width: 90%; background: color-mix(in srgb, var(--t-acc) 9%, #f4f1ea); border-radius: 1.2rem; border-start-start-radius: .3rem; padding: .85rem 1.05rem; font-size: 1.02rem; line-height: 1.5; }
.chat .qchips { display: flex; flex-wrap: wrap; margin-top: 0 !important; justify-content: flex-end; gap: .45rem; }
.chat .qchips button { background: transparent !important; color: var(--t-acc) !important; border: 1.5px solid color-mix(in srgb, var(--t-acc) 55%, transparent) !important; border-radius: 1.2rem !important; border-end-end-radius: .3rem !important; padding: .6rem 1rem !important; min-height: 2.75rem; font: 500 .95rem/1.3 var(--sans, inherit) !important; text-align: start; }
[dir='rtl'] .chat .qchips button { font-family: var(--ar) !important; }
.chat .qchips button:hover { background: var(--t-acc) !important; color: #fff !important; border-color: var(--t-acc) !important; }
.rules { counter-reset: rule; grid-template-columns: repeat(auto-fit, minmax(min(14rem, 100%), 1fr)); max-width: none !important; gap: .7rem !important; }
.rules li { counter-increment: rule; padding: 1rem 1.1rem 1.1rem !important; border: 1px solid color-mix(in srgb, currentColor 16%, transparent); border-radius: .9rem; background: color-mix(in srgb, currentColor 3%, transparent); line-height: 1.5; }
.rules li::before { content: counter(rule, decimal-leading-zero) !important; position: static !important; display: block; width: auto !important; height: auto !important; background: none !important; border-radius: 0 !important; font: 500 .74rem/1 ui-monospace, 'Geist Mono', Menlo, monospace; letter-spacing: .06em; opacity: .6; margin-bottom: .55rem; }
.wordmark { font-size: min(13rem, calc(150vw / var(--chars, 12))) !important; }

/* polish 2: brand mark, the confirmation moment, paper grain, sections that ease in */
.mark { display: none; flex: none; width: 1.75rem; height: 1.75rem; color: inherit; margin-inline-end: -.45rem; }
.mark svg { width: 100%; height: 100%; display: block; }
@media (min-width: 480px) { .mark { display: block; } }
.okmark { width: 3.2rem; height: 3.2rem; color: var(--t-acc); display: block; }
.okmark circle { fill: color-mix(in srgb, var(--t-acc) 10%, transparent); stroke: currentColor; stroke-width: 2.4; stroke-dasharray: 151; stroke-dashoffset: 151; animation: okdraw .65s cubic-bezier(.6, 0, .2, 1) forwards; }
.okmark path { fill: none; stroke: currentColor; stroke-width: 3.2; stroke-linecap: round; stroke-linejoin: round; stroke-dasharray: 40; stroke-dashoffset: 40; animation: okdraw .4s .5s cubic-bezier(.6, 0, .2, 1) forwards; }
@keyframes okdraw { to { stroke-dashoffset: 0; } }
@media (prefers-reduced-motion: reduce) { .okmark circle, .okmark path { stroke-dashoffset: 0; } }
.ref, .ordernum { position: relative; border: 1.5px dashed color-mix(in srgb, currentColor 35%, transparent); background: color-mix(in srgb, var(--t-acc) 6%, transparent) !important; padding-inline: 1.3rem 2.6rem !important; }
.ref::after, .ordernum::after { content: ''; position: absolute; inset-inline-end: .8rem; top: 50%; width: 1.1rem; height: 1.1rem; margin-top: -.55rem; border-radius: 50%; border: 1.5px dashed color-mix(in srgb, currentColor 35%, transparent); }
body::after { content: ''; position: fixed; inset: 0; z-index: 40; pointer-events: none; opacity: .055; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='180' height='180'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.9' numOctaves='2' stitchTiles='stitch'/%3E%3CfeColorMatrix values='0 0 0 0 .5  0 0 0 0 .5  0 0 0 0 .5  0 0 0 1.1 -.2'/%3E%3C/filter%3E%3Crect width='180' height='180' filter='url(%23n)'/%3E%3C/svg%3E"); }
@supports (animation-timeline: view()) { @media (prefers-reduced-motion: no-preference) {
  .sec > .wrap, .talk .chat { animation: easein linear both; animation-timeline: view(); animation-range: entry 0% entry 55%; }
  @keyframes easein { from { opacity: 0; transform: translateY(34px); } } } }
.tile { transition: transform .5s cubic-bezier(.2, .8, .2, 1), box-shadow .5s cubic-bezier(.2, .8, .2, 1); }
.card:hover .tile { transform: perspective(800px) rotateX(7deg) translateY(-6px); box-shadow: 0 34px 40px -26px rgba(43, 42, 38, .55); }

/* narrow phones (320-400px): keep the top bar on one line, nothing wider than the screen */
@media (max-width: 400px) {
  .bar { gap: .5rem; }
  .brand { font-size: 1.2rem; min-width: 0; overflow: hidden; text-overflow: ellipsis; }
  .tools { gap: .25rem; flex: none; }
  .langs button { min-width: 1.9rem; padding: .5rem .25rem; font-size: .7rem; }
  .badge { padding: .5rem .6rem; font-size: .72rem; }
}
