/* Carbwise website. Brand: deep olive, EVOO gold, soft cream (docs/brand/BRAND.md). Mobile first.
   Every text/background pair below has at least 4.5:1 contrast in both themes. No inline styles anywhere. */
:root {
  --bg: #fbf8ef; --surface: #fffdf8; --tint: #f3efe0; --text: #1f2614; --muted: #5c6250; --line: #e5dfcb;
  --accent: #4e6b1f; --accent-text: #ffffff; --accent-dark: #2f4214; --olive-soft: #e9eeda;
  --gold: #c9a227; --gold-dark: #7a5a00; --gold-soft: #f7edcb; --danger: #a4441c; --err-bg: #f7e4d9;
  --radius: 16px; --sans: system-ui, -apple-system, "Segoe UI", Roboto, sans-serif; --serif: Georgia, "Times New Roman", "Noto Serif", serif;
}
@media (prefers-color-scheme: dark) {
  :root { --bg: #12150d; --surface: #1b2014; --tint: #171b10; --text: #edebdd; --muted: #b5b6a1; --line: #363c29;
    --accent: #a9c46c; --accent-text: #1a2408; --accent-dark: #d3e3aa; --olive-soft: #27321b;
    --gold: #e3c25a; --gold-dark: #f0d88a; --gold-soft: #3a321a; --danger: #ec9a72; --err-bg: #3d271c; }
}
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }
body { margin: 0; background: var(--bg); color: var(--text); font-family: var(--sans); font-size: 1.0625rem; line-height: 1.6; }
img, svg { max-width: 100%; height: auto; }
a { color: var(--accent); text-underline-offset: 3px; }
a:hover { color: var(--accent-dark); }
:focus-visible { outline: 3px solid var(--gold-dark); outline-offset: 2px; border-radius: 4px; }
h1, h2, h3 { font-family: var(--serif); font-weight: 600; line-height: 1.2; margin: 0 0 .5em; text-wrap: balance; }
h1 { font-size: clamp(1.9rem, 5.2vw, 3rem); }
h2 { font-size: clamp(1.5rem, 3.6vw, 2.1rem); }
h3 { font-size: 1.2rem; }
p { margin: 0 0 1em; }
ul, ol { padding-left: 1.3em; }
.wrap { width: min(1120px, 100% - 2rem); margin-inline: auto; }
.narrow { width: min(760px, 100% - 2rem); }
.small { font-size: .9rem; }
.muted { color: var(--muted); }
.lead { font-size: 1.15rem; color: var(--muted); max-width: 62ch; }
.skip { position: absolute; left: -999px; top: 0; background: var(--accent); color: var(--accent-text); padding: .6rem 1rem; z-index: 10; }
.skip:focus { left: .5rem; top: .5rem; }
[hidden] { display: none !important; }

/* Header */
.site-head { background: var(--surface); border-bottom: 1px solid var(--line); }
.head-row { display: flex; flex-wrap: wrap; align-items: center; gap: .4rem .75rem; padding: .6rem 0; }
.head-row .langs { order: 3; width: 100%; }
.brand { display: inline-flex; align-items: center; gap: .5rem; font-family: var(--serif); font-weight: 600; font-size: 1.35rem; color: var(--text); text-decoration: none; margin: 0 auto 0 0; }
.langs ul, .main-nav ul, .site-foot ul { list-style: none; margin: 0; padding: 0; }
.langs ul { display: flex; gap: .1rem; }
.langs a { display: block; padding: .35rem .45rem; border-radius: 8px; font-size: .85rem; font-weight: 600; text-decoration: none; color: var(--muted); }
.langs a[aria-current] { background: var(--olive-soft); color: var(--accent-dark); }
.main-nav { overflow-x: auto; scrollbar-width: thin; }
.main-nav ul { display: flex; gap: 1.25rem; white-space: nowrap; padding-bottom: .55rem; }
.main-nav a { color: var(--text); text-decoration: none; font-size: .95rem; padding: .25rem 0; display: block; }
.main-nav a:hover { color: var(--accent); text-decoration: underline; }
.app-page .main-nav { display: none; }

/* Buttons */
.btn, button { display: inline-block; font: inherit; font-weight: 600; border: 2px solid var(--accent); border-radius: 12px; padding: .65rem 1.15rem;
  background: var(--accent); color: var(--accent-text); text-decoration: none; cursor: pointer; text-align: center; }
.btn:hover { background: var(--accent-dark); border-color: var(--accent-dark); color: var(--accent-text); }
.btn.ghost, button.ghost { background: transparent; color: var(--accent-dark); }
.btn.ghost:hover, button.ghost:hover { background: var(--olive-soft); color: var(--accent-dark); }
.btn.small { padding: .35rem .8rem; font-size: .9rem; border-radius: 10px; }
button:disabled { opacity: .55; cursor: not-allowed; }
button.link { background: none; border: 0; color: var(--accent); padding: .25rem 0; text-align: left; text-decoration: underline; font-weight: 400; }
button.danger { background: var(--danger); border-color: var(--danger); color: #fff; }

/* Hero */
.hero { padding: 2rem 0 1.5rem; background: linear-gradient(180deg, var(--surface), var(--bg)); }
.hero-grid { display: grid; gap: 1.5rem; align-items: center; }
.kicker { font-weight: 700; color: var(--gold-dark); letter-spacing: .02em; margin-bottom: .6rem; }
.stores { display: flex; flex-wrap: wrap; gap: .75rem; margin: 1.25rem 0 .75rem; }
.store { display: inline-flex; align-items: center; gap: .7rem; min-width: 11.5rem; padding: .55rem 1.1rem .55rem .9rem; border-radius: 14px;
  background: var(--text); color: var(--bg); text-decoration: none; border: 2px solid var(--text); }
a.store:hover { background: var(--accent-dark); border-color: var(--accent-dark); color: var(--bg); }
.store .icon { fill: currentColor; stroke: none; flex: none; }
.store:nth-child(2) .icon { fill: none; stroke: currentColor; }
.store-text { display: grid; line-height: 1.2; }
.store-text small { font-size: .75rem; }
.store-text b { font-size: 1.15rem; }
.store.soon { background: transparent; color: var(--text); border-style: dashed; border-color: var(--muted); }
.notice { background: var(--gold-soft); color: var(--text); border-left: 4px solid var(--gold-dark); border-radius: 10px; padding: .8rem 1rem; font-size: .95rem; margin: 1rem 0 0; }
.dial { margin: 0 auto; max-width: 380px; text-align: center; }
.dial svg { width: 100%; display: block; }
.dial figcaption { font-size: .9rem; color: var(--muted); }
.dial-track { fill: none; stroke: var(--line); stroke-width: 22; }
.arc { fill: none; stroke-width: 22; stroke-linecap: butt; }
.arc.s0 { stroke: #d8c98c; } .arc.s1 { stroke: #c9a227; } .arc.s2 { stroke: #a9b25a; } .arc.s3 { stroke: #7d9a3a; } .arc.s4 { stroke: #4e6b1f; }
.dial-now { fill: var(--surface); stroke: var(--text); stroke-width: 4; }
.dial-h { font: 600 15px var(--sans); fill: var(--muted); }
.dial-big { font: 600 58px var(--serif); fill: var(--text); }
.dial-stage { font: 600 17px var(--sans); fill: var(--accent); }

/* Sections */
.band { padding: 2.75rem 0; scroll-margin-top: 1rem; }
.band.tint { background: var(--tint); }
.card { background: var(--surface); border: 1px solid var(--line); border-top: 3px solid var(--gold); border-radius: var(--radius); padding: 1.15rem; }
.card p:last-child { margin-bottom: 0; }
.icon { fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.icon.big { width: 34px; height: 34px; color: var(--accent); margin-bottom: .4rem; }
.tabs, .levels, .grid4 { list-style: none; padding: 0; margin: 1.25rem 0; display: grid; gap: .9rem; }
.tabs { counter-reset: tab; }
.levels { grid-template-columns: repeat(2, 1fr); }
.lvl { position: relative; padding-top: 1rem; }
.lvl h3 { font-size: 1.05rem; margin-bottom: .2em; }
.lvl-n { display: inline-grid; place-items: center; width: 2.1rem; height: 2.1rem; border-radius: 50%; font-weight: 700; margin-bottom: .5rem; background: var(--olive-soft); color: var(--accent-dark); }
.lvl-5 .lvl-n, .lvl-6 .lvl-n { background: var(--gold-soft); color: var(--gold-dark); }
.lvl-7 .lvl-n, .lvl-8 .lvl-n { background: var(--accent); color: var(--accent-text); }
.table-wrap { overflow-x: auto; margin: 1.25rem 0; border: 1px solid var(--line); border-radius: var(--radius); background: var(--surface); }
table { border-collapse: collapse; width: 100%; font-size: .95rem; }
th, td { text-align: left; padding: .6rem .8rem; border-bottom: 1px solid var(--line); vertical-align: top; }
tbody tr:last-child > * { border-bottom: 0; }
thead th { background: var(--olive-soft); color: var(--accent-dark); }
.stages th[scope=row] { white-space: nowrap; font-variant-numeric: tabular-nums; }
.plans { display: grid; gap: 1rem; margin: 1.25rem 0; }
.plan { display: flex; flex-direction: column; gap: .2rem; }
.plan.featured { border: 2px solid var(--accent); border-top-width: 3px; }
.plan .btn { margin-top: auto; }
.price { font-size: 1.05rem; margin: .4rem 0 .2rem; }
.price b { font-family: var(--serif); font-size: 2.1rem; }
.ticks { list-style: none; padding: 0; margin: .75rem 0 1.1rem; display: grid; gap: .45rem; }
.ticks li { display: flex; gap: .55rem; align-items: flex-start; }
.icon.tick { width: 20px; height: 20px; flex: none; margin-top: .2rem; color: var(--accent); stroke-width: 2.4; }
.faq { display: grid; gap: .6rem; margin-top: 1.25rem; max-width: 800px; }
.faq details { background: var(--surface); border: 1px solid var(--line); border-radius: 12px; padding: .2rem 1rem; }
.faq summary { cursor: pointer; font-weight: 600; padding: .65rem 0; }
.faq details p { margin: 0 0 .9rem; }

/* Pages: account, restore, imprint, legal */
.page { padding: 2rem 0 3rem; }
.page > .card, .page #app { margin: 1.25rem 0; }
#app { display: grid; gap: 1rem; }
#app > * { margin: 0; }
.stack { display: grid; gap: .8rem; }
.stack > * { margin: 0; }
.steps { padding-left: 1.3em; display: grid; gap: .5rem; }
.facts { display: grid; grid-template-columns: max-content 1fr; gap: .4rem 1.25rem; margin: 1.25rem 0; }
.facts dt { color: var(--muted); } .facts dd { margin: 0; }
.doc h2 { font-size: 1.3rem; margin-top: 1.6em; } .doc h3 { font-size: 1.1rem; margin-top: 1.3em; }
.doc li { margin-bottom: .5em; }
label { display: grid; gap: .25rem; font-weight: 600; font-size: .95rem; }
input { font: inherit; padding: .65rem .75rem; border-radius: 10px; border: 1px solid var(--muted); background: var(--bg); color: var(--text); width: 100%; }
.check { display: flex; gap: .6rem; align-items: flex-start; font-weight: 400; }
.check input { width: 1.25rem; height: 1.25rem; margin-top: .2rem; flex: none; }
.msg { padding: .7rem .9rem; border-radius: 10px; background: var(--olive-soft); }
.msg.error { background: var(--err-bg); color: var(--danger); }
.row { display: flex; flex-wrap: wrap; gap: .6rem; align-items: center; }
.badge { display: inline-block; padding: .15rem .7rem; border-radius: 999px; font-weight: 700; background: var(--olive-soft); color: var(--accent-dark); }
.badge.premium { background: var(--gold-soft); color: var(--gold-dark); }
td.actions { display: flex; flex-wrap: wrap; gap: .4rem; }
td.actions button { padding: .35rem .7rem; font-size: .9rem; }

/* Footer */
.site-foot { border-top: 1px solid var(--line); background: var(--surface); padding: 2rem 0 1.25rem; margin-top: 1rem; }
.foot-grid { display: grid; gap: 1.5rem; }
.site-foot h2 { font-family: var(--sans); font-size: .95rem; margin-bottom: .5rem; }
.site-foot li { margin-bottom: .35rem; font-size: .95rem; }
.site-foot .brand { font-size: 1.15rem; margin-bottom: .5rem; }
.copy { color: var(--muted); margin-top: 1.5rem; }

@media (min-width: 640px) {
  .site-head { position: sticky; top: 0; z-index: 5; }
  .head-row .langs { order: 0; width: auto; }
  .tabs { grid-template-columns: repeat(2, 1fr); }
  .levels { grid-template-columns: repeat(4, 1fr); }
  .grid4 { grid-template-columns: repeat(2, 1fr); }
  .plans { grid-template-columns: repeat(2, 1fr); max-width: 820px; }
  .foot-grid { grid-template-columns: 2fr 1fr 1fr; }
}
@media (min-width: 960px) {
  .hero { padding: 3.5rem 0 2rem; }
  .hero-grid { grid-template-columns: 1.25fr .75fr; gap: 3rem; }
  .tabs { grid-template-columns: repeat(5, 1fr); }
  .grid4 { grid-template-columns: repeat(4, 1fr); }
  .band { padding: 4rem 0; }
  .band, #new-phone { scroll-margin-top: 6.5rem; }
}
