/* ============================================================
   Tasur — internal preview stylesheet
   Dark theme default; light via [data-theme="light"].
   Self-hosted fonts only; zero external requests.
   ============================================================ */

@font-face {
  font-family: "Inter";
  src: url("../fonts/InterVariable.woff2") format("woff2");
  font-weight: 100 900;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "JetBrains Mono";
  src: url("../fonts/JetBrainsMono-Regular.woff2") format("woff2");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "JetBrains Mono";
  src: url("../fonts/JetBrainsMono-Medium.woff2") format("woff2");
  font-weight: 500;
  font-style: normal;
  font-display: swap;
}

:root {
  color-scheme: dark;
  --bg: #0a0d12;
  --bg-2: #0f131b;
  --surface: #12161f;
  --surface-2: #161b26;
  --text: #e9edf3;
  --text-strong: #ffffff;
  --muted: #9aa5b4;
  --faint: #6b7686;
  --border: #232b39;
  --border-soft: #1b212d;
  --accent: #6ea8fe;
  --accent-strong: #8fbcff;
  --accent-ink: #08101d;
  --accent-dim: rgba(110, 168, 254, 0.12);
  --ok: #7fd4a3;
  --sans: "Inter", "Segoe UI", system-ui, -apple-system, sans-serif;
  --mono: "JetBrains Mono", ui-monospace, "SF Mono", Consolas, monospace;
  --shadow-ring: 0 0 0 1px var(--border);
  --ribbon-h: 2.25rem;
}

:root[data-theme="light"] {
  color-scheme: light;
  --bg: #fbfcfe;
  --bg-2: #f4f6fa;
  --surface: #ffffff;
  --surface-2: #f7f9fc;
  --text: #1a2029;
  --text-strong: #0c1118;
  --muted: #5b6574;
  --faint: #8a93a1;
  --border: #dfe4ec;
  --border-soft: #e9edf3;
  --accent: #1e5fd0;
  --accent-strong: #174ba8;
  --accent-ink: #ffffff;
  --accent-dim: rgba(30, 95, 208, 0.08);
  --ok: #1a7f4e;
}

/* ---------- base ---------- */

*, *::before, *::after { box-sizing: border-box; }

html {
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { transition: none !important; animation: none !important; }
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--sans);
  font-size: 1.0625rem;
  line-height: 1.65;
  font-feature-settings: "cv05", "cv11";
  padding-bottom: var(--ribbon-h);
}

h1, h2, h3 {
  color: var(--text-strong);
  line-height: 1.15;
  letter-spacing: -0.022em;
  margin: 0 0 0.6em;
  font-weight: 650;
  text-wrap: balance;
}
h1 { font-size: clamp(2.1rem, 5.5vw, 3.3rem); }
h2 { font-size: clamp(1.5rem, 3.4vw, 2.1rem); }
h3 { font-size: 1.14rem; letter-spacing: -0.012em; }

p { margin: 0 0 1em; }
p:last-child { margin-bottom: 0; }

a { color: var(--accent); text-decoration: none; }
a:hover { color: var(--accent-strong); text-decoration: underline; text-underline-offset: 3px; }

:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
  border-radius: 3px;
}

ul { padding-left: 1.2em; margin: 0 0 1em; }
li { margin-bottom: 0.45em; }

.mono, .num {
  font-family: var(--mono);
  font-feature-settings: normal;
}

.container {
  max-width: 1080px;
  margin: 0 auto;
  padding: 0 clamp(1.1rem, 4vw, 2rem);
}

.muted { color: var(--muted); }

.skip-link {
  position: absolute;
  left: -999px;
  top: 0;
  background: var(--accent);
  color: var(--accent-ink);
  padding: 0.5rem 1rem;
  z-index: 100;
  border-radius: 0 0 6px 0;
}
.skip-link:focus { left: 0; }

/* ---------- header ---------- */

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: color-mix(in srgb, var(--bg) 84%, transparent);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border-soft);
}

.header-inner {
  display: flex;
  align-items: center;
  gap: 1.1rem;
  flex-wrap: wrap;
  padding-top: 0.8rem;
  padding-bottom: 0.8rem;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 0.55rem;
  color: var(--text-strong);
  font-weight: 700;
  font-size: 1.14rem;
  letter-spacing: -0.02em;
}
.brand:hover { text-decoration: none; color: var(--text-strong); }
.brand svg { display: block; color: var(--accent); }

.site-nav {
  display: flex;
  gap: 0.15rem;
  margin-right: auto;
  flex-wrap: wrap;
}
.site-nav a {
  color: var(--muted);
  font-size: 0.94rem;
  font-weight: 500;
  padding: 0.35rem 0.7rem;
  border-radius: 7px;
}
.site-nav a:hover { color: var(--text-strong); text-decoration: none; background: var(--accent-dim); }
.site-nav a.active { color: var(--text-strong); background: var(--accent-dim); }

.header-tools { display: flex; align-items: center; gap: 0.7rem; margin-left: auto; }

.lang-switch {
  display: flex;
  border: 1px solid var(--border);
  border-radius: 8px;
  overflow: hidden;
}
.lang-switch a {
  font-family: var(--mono);
  font-size: 0.72rem;
  font-weight: 500;
  letter-spacing: 0.06em;
  color: var(--muted);
  padding: 0.32rem 0.55rem;
}
.lang-switch a + a { border-left: 1px solid var(--border); }
.lang-switch a:hover { color: var(--text-strong); text-decoration: none; background: var(--accent-dim); }
.lang-switch a[aria-current="true"] {
  color: var(--accent-ink);
  background: var(--accent);
}

.theme-toggle {
  appearance: none;
  border: 1px solid var(--border);
  background: transparent;
  color: var(--muted);
  border-radius: 8px;
  width: 2.1rem;
  height: 2.1rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  padding: 0;
}
.theme-toggle:hover { color: var(--text-strong); border-color: var(--faint); }
.theme-toggle svg { width: 1rem; height: 1rem; }
.theme-toggle .icon-sun { display: block; }
.theme-toggle .icon-moon { display: none; }
:root[data-theme="light"] .theme-toggle .icon-sun { display: none; }
:root[data-theme="light"] .theme-toggle .icon-moon { display: block; }

/* ---------- hero ---------- */

.hero {
  position: relative;
  overflow: hidden;
  padding: clamp(3.4rem, 8vw, 6.5rem) 0 clamp(2.8rem, 6vw, 5rem);
  border-bottom: 1px solid var(--border-soft);
  background:
    radial-gradient(ellipse 90% 70% at 70% -10%, var(--accent-dim), transparent 60%),
    var(--bg);
}

.hero-grid-motif {
  position: absolute;
  right: -40px;
  top: 50%;
  transform: translateY(-50%);
  color: var(--border);
  pointer-events: none;
  user-select: none;
}
.hero-grid-motif .cell-accent { fill: var(--accent); opacity: 0.55; }
@media (max-width: 860px) { .hero-grid-motif { display: none; } }

.hero-inner { position: relative; max-width: 46rem; }

.eyebrow {
  font-family: var(--mono);
  font-size: 0.74rem;
  font-weight: 500;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--accent);
  margin: 0 0 1.1rem;
}

.lede {
  font-size: clamp(1.05rem, 2vw, 1.2rem);
  color: var(--muted);
  max-width: 42rem;
}

.hero-ctas {
  display: flex;
  flex-wrap: wrap;
  gap: 0.8rem;
  margin-top: 1.9rem;
  align-items: center;
}

.hero-note {
  margin-top: 1.15rem;
  font-family: var(--mono);
  font-size: 0.82rem;
  color: var(--faint);
}

/* ---------- buttons ---------- */

.btn {
  display: inline-block;
  background: var(--accent);
  color: var(--accent-ink);
  font-weight: 600;
  font-size: 0.97rem;
  padding: 0.68rem 1.35rem;
  border-radius: 9px;
  border: 1px solid transparent;
  transition: background 0.15s ease;
}
.btn:hover { background: var(--accent-strong); color: var(--accent-ink); text-decoration: none; }

.btn-ghost {
  background: transparent;
  color: var(--text);
  border-color: var(--border);
}
.btn-ghost:hover { background: var(--accent-dim); color: var(--text-strong); border-color: var(--faint); }

/* ---------- sections ---------- */

.section { padding: clamp(2.8rem, 6vw, 4.6rem) 0; }
.section + .section { border-top: 1px solid var(--border-soft); }
.section-alt { background: var(--bg-2); }

.section-head { max-width: 44rem; margin-bottom: 2rem; }
.section-head .lede { font-size: 1.05rem; }

/* ---------- pillar cards ---------- */

.pillars {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(20rem, 100%), 1fr));
  gap: 1rem;
}

.card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 1.5rem 1.4rem;
}
.card h3 { margin-bottom: 0.55rem; }
.card p { color: var(--muted); font-size: 0.96rem; }

.card-kicker {
  font-family: var(--mono);
  font-size: 0.68rem;
  font-weight: 500;
  letter-spacing: 0.13em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 0.7rem;
}

.footnote-reframe {
  margin-top: 1.6rem;
  padding-left: 1rem;
  border-left: 2px solid var(--border);
  color: var(--faint);
  font-size: 0.9rem;
  max-width: 40rem;
}

.dev-line {
  margin-top: 1.4rem;
  font-family: var(--mono);
  font-size: 0.84rem;
  color: var(--muted);
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 9px;
  padding: 0.75rem 1rem;
  display: inline-block;
}
.dev-line::before { content: "$ "; color: var(--accent); }

/* ---------- tier teaser / cards ---------- */

.tiers {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(14.5rem, 100%), 1fr));
  gap: 1rem;
}

.tier-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 1.4rem 1.3rem;
  display: flex;
  flex-direction: column;
  gap: 0.45rem;
}
.tier-card.featured { border-color: var(--accent); box-shadow: 0 0 0 1px var(--accent); }
.tier-name { font-weight: 650; color: var(--text-strong); font-size: 1.02rem; letter-spacing: -0.01em; }
.tier-price {
  font-family: var(--mono);
  font-weight: 500;
  font-size: 1.55rem;
  color: var(--text-strong);
  letter-spacing: -0.02em;
}
.tier-price small { font-size: 0.78rem; color: var(--faint); font-weight: 400; }
.tier-vat { font-family: var(--mono); font-size: 0.76rem; color: var(--faint); }
.tier-desc { color: var(--muted); font-size: 0.92rem; flex-grow: 1; }
.tier-link { font-size: 0.92rem; font-weight: 550; }

.vat-note {
  margin-top: 1.3rem;
  font-size: 0.86rem;
  color: var(--faint);
}

/* ---------- badges ---------- */

.badge-tbc {
  display: inline-block;
  vertical-align: 0.14em;
  font-family: var(--mono);
  font-size: 0.62rem;
  font-weight: 500;
  letter-spacing: 0.07em;
  text-transform: uppercase;
  color: var(--muted);
  border: 1px solid var(--border);
  border-radius: 99px;
  padding: 0.1rem 0.5rem;
  white-space: nowrap;
}

/* ---------- pricing table ---------- */

.table-wrap {
  overflow-x: auto;
  border: 1px solid var(--border);
  border-radius: 12px;
  background: var(--surface);
  margin-top: 2.2rem;
}

table.ladder {
  border-collapse: collapse;
  width: 100%;
  min-width: 46rem;
  font-size: 0.92rem;
}
.ladder caption {
  position: absolute;
  width: 1px; height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
}
.ladder th, .ladder td {
  text-align: left;
  padding: 0.62rem 0.9rem;
  border-bottom: 1px solid var(--border-soft);
  vertical-align: top;
}
.ladder thead th {
  font-size: 0.8rem;
  font-weight: 650;
  color: var(--text-strong);
  background: var(--surface-2);
  position: sticky;
  top: 0;
}
.ladder thead th:not(:first-child) { font-family: var(--mono); font-weight: 500; }
.ladder tbody th[scope="row"] {
  font-weight: 500;
  color: var(--text);
  width: 34%;
}
.ladder td { font-family: var(--mono); font-size: 0.84rem; color: var(--muted); }
.ladder td.yes { color: var(--ok); }
.ladder td.no { color: var(--faint); }
.ladder tr.group th {
  font-family: var(--mono);
  font-size: 0.68rem;
  font-weight: 500;
  letter-spacing: 0.13em;
  text-transform: uppercase;
  color: var(--accent);
  background: var(--bg-2);
  padding-top: 0.85rem;
}
.ladder tbody tr:last-child th, .ladder tbody tr:last-child td { border-bottom: none; }

.table-notes {
  margin-top: 0.9rem;
  font-size: 0.84rem;
  color: var(--faint);
}
.table-notes p { margin-bottom: 0.3em; }

/* ---------- FAQ ---------- */

.faq { max-width: 46rem; }
.faq details {
  border: 1px solid var(--border);
  border-radius: 10px;
  background: var(--surface);
  margin-bottom: 0.7rem;
  padding: 0 1.1rem;
}
.faq summary {
  cursor: pointer;
  font-weight: 600;
  color: var(--text-strong);
  padding: 0.9rem 0;
  list-style: none;
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  align-items: baseline;
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after {
  content: "+";
  font-family: var(--mono);
  color: var(--accent);
  flex-shrink: 0;
}
.faq details[open] summary::after { content: "–"; }
.faq details > div {
  padding: 0 0 1rem;
  color: var(--muted);
  font-size: 0.95rem;
}

/* ---------- prose blocks (bureaus / product) ---------- */

.split {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(20rem, 100%), 1fr));
  gap: 1rem;
}

.feature-list { list-style: none; padding: 0; }
.feature-list li {
  padding-left: 1.35rem;
  position: relative;
  color: var(--muted);
}
.feature-list li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.62em;
  width: 0.55rem;
  height: 0.55rem;
  border: 1.5px solid var(--accent);
  border-radius: 2px;
}
.feature-list li strong { color: var(--text); font-weight: 600; }

/* ---------- closing CTA ---------- */

.cta-final {
  text-align: center;
  padding: clamp(3.2rem, 7vw, 5.5rem) 0;
}
.cta-final .lede { margin: 0 auto 1.6rem; }
.cta-final .hero-ctas { justify-content: center; }

/* ---------- footer ---------- */

.site-footer {
  border-top: 1px solid var(--border-soft);
  background: var(--bg-2);
  padding: 2.2rem 0 2.6rem;
}
.footer-inner {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem 2.5rem;
  align-items: baseline;
  justify-content: space-between;
}
.footer-brandline {
  font-weight: 650;
  color: var(--text-strong);
  letter-spacing: -0.01em;
}
.footer-legal {
  font-size: 0.82rem;
  color: var(--faint);
  max-width: 34rem;
  margin: 0;
}

/* ---------- preview ribbon ---------- */

.preview-ribbon {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 60;
  height: var(--ribbon-h);
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--surface-2);
  border-top: 1px solid var(--border);
  color: var(--muted);
  font-family: var(--mono);
  font-size: 0.68rem;
  font-weight: 500;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  text-align: center;
  padding: 0 0.8rem;
}
.preview-ribbon::before {
  content: "";
  width: 0.5rem;
  height: 0.5rem;
  border-radius: 50%;
  background: var(--accent);
  margin-right: 0.6rem;
  flex-shrink: 0;
  opacity: 0.8;
}

/* ---------- language fallback list (root) ---------- */

.lang-fallback {
  min-height: 70vh;
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 0.4rem;
}
.lang-fallback ul { list-style: none; padding: 0; }
.lang-fallback a { font-size: 1.2rem; font-weight: 600; }

/* ---------- docs (user guide) ---------- */

.docs-subnav {
  border-bottom: 1px solid var(--border-soft);
  background: var(--bg-2);
}
.docs-subnav .container {
  display: flex;
  gap: 1.4rem;
  overflow-x: auto;
  padding-top: 0.6rem;
  padding-bottom: 0.6rem;
  scrollbar-width: thin;
}
.docs-subnav a {
  font-family: var(--mono);
  font-size: 0.7rem;
  font-weight: 500;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--muted);
  white-space: nowrap;
}
.docs-subnav a:hover { color: var(--text-strong); text-decoration: none; }
.docs-subnav a.active { color: var(--accent); }

.hero-docs { padding-top: clamp(2.2rem, 5vw, 3.4rem); padding-bottom: clamp(1.6rem, 4vw, 2.6rem); }

.docs-prose { max-width: 46rem; }
.docs-prose h2 {
  margin-top: 2.1rem;
  font-size: 1.3rem;
}
.docs-prose h2:first-child { margin-top: 0; }
.docs-prose p { color: var(--muted); }

ol.steps {
  list-style: none;
  counter-reset: step;
  padding: 0;
  margin: 0.4rem 0 0.8rem;
}
ol.steps li {
  counter-increment: step;
  position: relative;
  padding-left: 2.3rem;
  margin-bottom: 0.6rem;
  color: var(--muted);
}
ol.steps li::before {
  content: counter(step);
  position: absolute;
  left: 0;
  top: 0.05em;
  width: 1.55rem;
  height: 1.55rem;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 1.5px solid var(--accent);
  border-radius: 6px;
  color: var(--accent);
  font-family: var(--mono);
  font-size: 0.78rem;
  font-weight: 500;
}

.note-soon {
  border: 1px solid var(--border);
  border-left: 3px solid var(--accent);
  border-radius: 8px;
  background: var(--surface);
  padding: 0.75rem 1rem;
  font-size: 0.9rem;
  color: var(--muted);
  margin: 1.1rem 0 0.4rem;
}
