/* RideFlux website — plain CSS, no framework, no web fonts, no third-party requests.
   Brand colours come from the app's own theme (electric cyan #00E5FF on near-black).
   Layout uses logical properties throughout so Arabic and Urdu (dir="rtl") need no overrides. */

:root {
  color-scheme: dark light;

  --bg: #04070b;
  --bg-alt: #080d13;
  --surface: #0b1118;
  --surface-2: #121c26;
  --line: #1d2b37;
  --text: #e6f6f9;
  --muted: #9db2bc;
  --accent: #00e5ff;
  --accent-ink: #00262b;
  --accent-soft: rgba(0, 229, 255, 0.12);
  --ok: #3dff8f;
  --ok-soft: rgba(61, 255, 143, 0.12);
  --warn: #ffb74d;
  --warn-soft: rgba(255, 183, 77, 0.14);
  --glow: rgba(0, 229, 255, 0.20);
  --shadow: 0 24px 60px -20px rgba(0, 0, 0, 0.75);
  --frame: #1b2733;

  --radius: 18px;
  --radius-sm: 12px;
  --maxw: 1120px;
  --gutter: clamp(16px, 4vw, 28px);
  --header-h: 64px;
}

@media (prefers-color-scheme: light) {
  :root {
    --bg: #f4fafb;
    --bg-alt: #eaf4f6;
    --surface: #ffffff;
    --surface-2: #e3f0f3;
    --line: #cfe1e6;
    --text: #071f24;
    --muted: #42585f;
    --accent: #006875;
    --accent-ink: #ffffff;
    --accent-soft: rgba(0, 104, 117, 0.10);
    --ok: #0b7a3e;
    --ok-soft: rgba(11, 122, 62, 0.12);
    --warn: #a65300;
    --warn-soft: rgba(230, 81, 0, 0.12);
    --glow: rgba(0, 184, 212, 0.22);
    --shadow: 0 24px 50px -22px rgba(7, 31, 36, 0.40);
    --frame: #0d1a21;
  }
}

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

html {
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", "Noto Sans", Arial, sans-serif;
  font-size: 1rem;
  line-height: 1.65;
  overflow-wrap: break-word;
}

/* Script-specific stacks: the system default is rarely the best CJK / Indic / Arabic face. */
:lang(zh-TW) { font-family: system-ui, "PingFang TC", "Microsoft JhengHei", "Noto Sans TC", "Noto Sans CJK TC", sans-serif; }
:lang(zh-CN) { font-family: system-ui, "PingFang SC", "Microsoft YaHei", "Noto Sans SC", "Noto Sans CJK SC", sans-serif; }
:lang(ja)    { font-family: system-ui, "Hiragino Sans", "Yu Gothic UI", "Meiryo", "Noto Sans JP", "Noto Sans CJK JP", sans-serif; }
:lang(ko)    { font-family: system-ui, "Apple SD Gothic Neo", "Malgun Gothic", "Noto Sans KR", "Noto Sans CJK KR", sans-serif; }
:lang(hi)    { font-family: system-ui, "Nirmala UI", "Noto Sans Devanagari", "Mangal", sans-serif; }
:lang(ar)    { font-family: system-ui, "Segoe UI", "Noto Naskh Arabic", "Noto Sans Arabic", Tahoma, sans-serif; }
:lang(ur)    { font-family: system-ui, "Noto Nastaliq Urdu", "Jameel Noori Nastaleeq", "Segoe UI", "Noto Naskh Arabic", Tahoma, sans-serif; line-height: 1.9; }

img, svg { display: block; max-width: 100%; }
img { height: auto; }

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

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

code {
  font-family: ui-monospace, "SF Mono", "Cascadia Mono", Consolas, "Liberation Mono", monospace;
  font-size: 0.92em;
  background: var(--surface-2);
  border-radius: 6px;
  padding: 0.1em 0.4em;
}

.container { width: min(100% - 2 * var(--gutter), var(--maxw)); margin-inline: auto; }

.skip {
  position: absolute; inset-inline-start: 12px; top: -60px; z-index: 100;
  background: var(--accent); color: var(--accent-ink);
  padding: 10px 16px; border-radius: 10px; font-weight: 600; text-decoration: none;
}
.skip:focus { top: 12px; }

/* ---------- buttons & pills ---------- */

.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  min-height: 48px; padding: 0 22px;
  border-radius: 999px; border: 1.5px solid var(--line);
  font: inherit; font-weight: 600; text-decoration: none; color: var(--text);
  background: transparent; cursor: pointer;
  transition: background-color .15s, border-color .15s, transform .15s;
}
.btn:hover { border-color: var(--accent); background: var(--accent-soft); text-decoration: none; }
.btn-primary { background: var(--accent); color: var(--accent-ink); border-color: var(--accent); }
.btn-primary:hover { background: var(--accent); filter: brightness(1.08); }
.btn-sm { min-height: 40px; padding: 0 16px; font-size: 0.92rem; }
.btn svg { width: 18px; height: 18px; flex: none; }

.pill {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 3px 12px; border-radius: 999px;
  font-size: 0.82rem; font-weight: 700; line-height: 1.5; white-space: nowrap;
}
.pill-ok   { background: var(--ok-soft);   color: var(--ok); }
.pill-warn { background: var(--warn-soft); color: var(--warn); }
.pill::before { content: ""; width: 8px; height: 8px; border-radius: 50%; background: currentColor; }

.eyebrow {
  display: inline-block; padding: 6px 14px; margin: 0 0 20px;
  border: 1px solid var(--line); border-radius: 999px;
  background: var(--accent-soft); color: var(--accent);
  font-size: 0.85rem; font-weight: 600;
}
html[data-script="latin"] .eyebrow, html[data-script="cyrillic"] .eyebrow { letter-spacing: 0.02em; }

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

.site-header {
  position: sticky; top: 0; z-index: 50;
  background: color-mix(in srgb, var(--bg) 82%, transparent);
  -webkit-backdrop-filter: saturate(1.4) blur(14px);
  backdrop-filter: saturate(1.4) blur(14px);
  border-bottom: 1px solid var(--line);
}
.bar { display: flex; align-items: center; gap: 20px; min-height: var(--header-h); }
.brand { display: inline-flex; align-items: center; gap: 10px; color: var(--text); font-weight: 800; font-size: 1.15rem; text-decoration: none; }
.brand img { border-radius: 8px; }
.nav { display: flex; gap: 4px; margin-inline-start: auto; }
.nav a { color: var(--muted); text-decoration: none; padding: 8px 12px; border-radius: 10px; font-weight: 500; font-size: 0.95rem; }
.nav a:hover { color: var(--text); background: var(--accent-soft); }
.bar-actions { display: flex; align-items: center; gap: 10px; }

details.lang, details.menu { position: relative; }
details.lang > summary, details.menu > summary {
  list-style: none; cursor: pointer; user-select: none;
  display: inline-flex; align-items: center; gap: 8px;
  min-height: 40px; padding: 0 14px;
  border: 1.5px solid var(--line); border-radius: 999px;
  color: var(--text); font-size: 0.92rem; font-weight: 600;
}
details > summary::-webkit-details-marker { display: none; }
details.lang > summary:hover, details.menu > summary:hover { border-color: var(--accent); }
details.lang > summary svg, details.menu > summary svg { width: 18px; height: 18px; }
details.lang > summary::after { content: ""; width: 7px; height: 7px; border-inline-end: 2px solid currentColor; border-bottom: 2px solid currentColor; transform: rotate(45deg) translateY(-2px); opacity: .7; }

.popover {
  position: absolute; inset-inline-end: 0; top: calc(100% + 10px); z-index: 60;
  min-width: 220px; max-height: min(70vh, 460px); overflow: auto;
  margin: 0; padding: 8px; list-style: none;
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius-sm);
  box-shadow: var(--shadow);
}
.popover a { display: block; padding: 9px 12px; border-radius: 8px; color: var(--text); text-decoration: none; }
.popover a:hover { background: var(--accent-soft); }
.popover a[aria-current="true"] { background: var(--accent-soft); color: var(--accent); font-weight: 700; }

details.menu { display: none; }
details.menu .popover { min-width: 200px; }

@media (max-width: 900px) {
  .nav { display: none; }
  details.menu { display: block; }
  .bar { gap: 12px; }
  .bar-actions { margin-inline-start: auto; }
}
@media (max-width: 520px) {
  .bar-actions .btn { display: none; }
  details.lang > summary span { display: none; }
}

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

.hero {
  position: relative; overflow: hidden;
  padding-block: clamp(40px, 7vw, 88px) clamp(48px, 7vw, 96px);
  background:
    radial-gradient(60% 55% at 78% 28%, var(--glow), transparent 70%),
    radial-gradient(40% 40% at 8% 90%, var(--accent-soft), transparent 70%),
    var(--bg);
}
.hero-grid { display: grid; grid-template-columns: minmax(0, 1.08fr) minmax(0, 0.92fr); gap: clamp(32px, 6vw, 72px); align-items: center; }
.hero h1 { margin: 0 0 20px; font-size: clamp(2.1rem, 4.8vw, 3.6rem); line-height: 1.12; font-weight: 800; text-wrap: balance; }
html[data-script="latin"] .hero h1, html[data-script="cyrillic"] .hero h1 { letter-spacing: -0.025em; }
.hero h1 em { font-style: normal; color: var(--accent); }
.hero .lead { margin: 0 0 30px; max-width: 38em; font-size: clamp(1.02rem, 1.6vw, 1.2rem); color: var(--muted); }
.cta-row { display: flex; flex-wrap: wrap; align-items: center; gap: 14px 18px; }
/* Google's badge PNG carries its own transparent padding; pull it back so the button lines up with the text. */
.play-badge { display: inline-block; line-height: 0; border-radius: 10px; margin-inline-start: -10px; }
.play-badge img { height: 76px; width: auto; }
.hero .note { margin: 18px 0 0; font-size: 0.92rem; color: var(--muted); }

.phones { position: relative; display: flex; justify-content: center; align-items: flex-start; min-height: 520px; }
.phone {
  position: relative; margin: 0;
  width: clamp(190px, 21vw, 262px);
  border: 7px solid var(--frame); border-radius: 36px; background: #000;
  box-shadow: var(--shadow), 0 0 0 1px var(--line); overflow: hidden;
  aspect-ratio: 9 / 16;
}
.phone img { width: 100%; height: 100%; object-fit: cover; }
.phone-front { z-index: 2; margin-block-start: 0; }
.phone-back  { z-index: 1; margin-inline-start: -56px; margin-block-start: 64px; transform: scale(0.94); opacity: .96; }
[dir="rtl"] .phone-back { margin-inline-start: -56px; }

@media (max-width: 880px) {
  .hero-grid { grid-template-columns: minmax(0, 1fr); }
  .hero { text-align: start; }
  .phones { min-height: 0; padding-block-start: 8px; }
  .phone { width: clamp(150px, 38vw, 220px); }
  .phone-back { margin-inline-start: -36px; margin-block-start: 40px; }
}

/* ---------- trust strip ---------- */

.trust { border-block: 1px solid var(--line); background: var(--bg-alt); }
.trust-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px 24px; padding-block: 28px; }
.trust-item { display: flex; align-items: flex-start; gap: 12px; }
.trust-item svg { width: 28px; height: 28px; flex: none; color: var(--accent); margin-block-start: 2px; }
.trust-item strong { display: block; font-size: 0.98rem; line-height: 1.35; }
.trust-item span { display: block; color: var(--muted); font-size: 0.9rem; line-height: 1.4; }
@media (max-width: 880px) { .trust-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 440px) { .trust-grid { grid-template-columns: minmax(0, 1fr); } }

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

.section { padding-block: clamp(56px, 8vw, 104px); scroll-margin-top: var(--header-h); }
.section-alt { background: var(--bg-alt); border-block: 1px solid var(--line); }
.section-head { max-width: 46rem; margin: 0 auto clamp(32px, 5vw, 52px); text-align: center; }
.section h2 { margin: 0 0 14px; font-size: clamp(1.7rem, 3.4vw, 2.5rem); line-height: 1.2; font-weight: 800; text-wrap: balance; }
html[data-script="latin"] .section h2, html[data-script="cyrillic"] .section h2 { letter-spacing: -0.02em; }
.section-head p { margin: 0; color: var(--muted); font-size: 1.08rem; }

/* ---------- features ---------- */

.cards { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 320px), 1fr)); gap: 20px; }
.card {
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius);
  padding: 26px; transition: border-color .2s, transform .2s;
}
.card:hover { border-color: color-mix(in srgb, var(--accent) 55%, var(--line)); transform: translateY(-2px); }
.card h3 { margin: 16px 0 8px; font-size: 1.14rem; line-height: 1.35; }
.card p { margin: 0; color: var(--muted); }
.icon-box {
  width: 48px; height: 48px; border-radius: 14px; display: grid; place-items: center;
  background: var(--accent-soft); color: var(--accent);
}
.icon-box svg { width: 26px; height: 26px; }

/* ---------- screenshots ---------- */

.shots-wrap { position: relative; }
.shots {
  display: flex; gap: 22px; margin: 0; padding: 8px max(var(--gutter), calc((100vw - var(--maxw)) / 2)) 28px;
  list-style: none; overflow-x: auto; scroll-snap-type: x proximity;
  scrollbar-width: thin; scrollbar-color: var(--line) transparent;
}
.shots li { flex: none; width: clamp(190px, 24vw, 232px); scroll-snap-align: center; }
.shots figure { margin: 0; }
.shots .phone { width: 100%; }
.shots figcaption { margin-block-start: 14px; text-align: center; font-weight: 600; font-size: 0.95rem; color: var(--muted); }

/* ---------- AR HUD ---------- */

.split { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: clamp(32px, 6vw, 72px); align-items: center; }
/* minmax(0, 1fr), never bare 1fr: a bare 1fr has an `auto` minimum, so one long German or Russian word
   would widen the whole column past the viewport. */
@media (max-width: 880px) { .split { grid-template-columns: minmax(0, 1fr); } }
.split h2 { text-align: start; }
.split .lead { margin: 0 0 22px; color: var(--muted); font-size: 1.08rem; }
.ticks { margin: 0; padding: 0; list-style: none; display: grid; gap: 16px; }
.ticks li { position: relative; padding-inline-start: 34px; }
.ticks li::before {
  content: ""; position: absolute; inset-inline-start: 0; top: 0.28em; width: 20px; height: 20px; border-radius: 50%;
  background: var(--accent-soft);
}
/* The tick uses physical borders on purpose: a check mark is not mirrored in right-to-left scripts. */
.ticks li::after {
  content: ""; position: absolute; inset-inline-start: 7px; top: calc(0.28em + 3px); width: 6px; height: 11px;
  border-right: 2.5px solid var(--accent); border-bottom: 2.5px solid var(--accent); transform: rotate(40deg) scale(.8);
}

.callout {
  margin-block-start: 28px; padding: 20px 22px; border-radius: var(--radius-sm);
  background: var(--surface); border: 1px solid var(--line);
  display: flex; flex-wrap: wrap; align-items: center; gap: 12px 20px; justify-content: space-between;
}
.callout h3 { margin: 0 0 4px; font-size: 1rem; }
.callout p { margin: 0; color: var(--muted); font-size: 0.95rem; }

.diagram {
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius);
  padding: clamp(22px, 4vw, 36px); box-shadow: var(--shadow);
}
.flow { display: grid; grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr) auto minmax(0, 1fr); align-items: center; gap: 8px; }
.node { display: grid; justify-items: center; gap: 10px; min-width: 0; text-align: center; font-size: 0.88rem; font-weight: 600; line-height: 1.3; overflow-wrap: anywhere; }
.node .icon-box { width: 64px; height: 64px; border-radius: 20px; }
.node .icon-box svg { width: 34px; height: 34px; }
.node-glasses .icon-box { background: var(--accent); color: var(--accent-ink); box-shadow: 0 0 0 6px var(--accent-soft); }
.link { display: grid; justify-items: center; gap: 4px; color: var(--muted); font-size: 0.74rem; font-weight: 600; text-align: center; }
.link svg { width: 38px; height: 14px; color: var(--accent); }
[dir="rtl"] .link svg { transform: scaleX(-1); }
.flow-ring { display: grid; grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr) auto minmax(0, 1fr); margin-block-start: 10px; }
.flow-ring .node { grid-column: 5; }
.flow-ring .vlink { grid-column: 5; display: grid; justify-items: center; gap: 4px; color: var(--muted); font-size: 0.74rem; font-weight: 600; margin-block-end: 4px; }
.flow-ring .vlink svg { width: 14px; height: 30px; color: var(--accent); }
.node-ring .icon-box { background: var(--surface-2); color: var(--text); }
/* Narrow screens: stack the chain vertically so labels in any language have the full width. */
@media (max-width: 560px) {
  .flow, .flow-ring { grid-template-columns: minmax(0, 1fr); gap: 6px; }
  .flow-ring .node, .flow-ring .vlink { grid-column: 1; }
  .link { grid-auto-flow: column; justify-content: center; align-items: center; gap: 10px; }
  .link svg { width: 30px; height: 14px; transform: rotate(90deg); margin-block: 8px; }
  [dir="rtl"] .link svg { transform: rotate(90deg); }          /* a vertical arrow has no reading direction */
  .flow-ring .vlink { grid-auto-flow: column; justify-content: center; align-items: center; gap: 10px; }
  .flow-ring .vlink svg { width: 14px; height: 30px; }
}

/* ---------- wheels ---------- */

.table { border: 1px solid var(--line); border-radius: var(--radius); background: var(--surface); overflow: hidden; }
.tr { display: grid; grid-template-columns: minmax(0, 1.1fr) minmax(0, 1.5fr) minmax(0, 1.5fr); gap: 8px 24px; padding: 16px 24px; align-items: start; border-top: 1px solid var(--line); }
.tr:first-child { border-top: 0; }
.tr-head { background: var(--surface-2); font-size: 0.82rem; font-weight: 700; color: var(--muted); padding-block: 12px; }
.tr .brand-cell { font-weight: 700; }
.tr .brand-cell small { display: block; font-weight: 400; color: var(--muted); }
.tr .models { color: var(--muted); }
.tr .status { display: grid; gap: 6px; justify-items: start; }
.tr .status small { color: var(--muted); font-size: 0.86rem; line-height: 1.45; }
@media (max-width: 720px) {
  .tr { grid-template-columns: minmax(0, 1fr); gap: 6px; padding: 16px 18px; }
  .tr-head { display: none; }
}
.legend { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; margin-block-start: 28px; }
.legend p { margin: 0; padding: 18px 20px; border-radius: var(--radius-sm); background: var(--surface); border: 1px solid var(--line); color: var(--muted); }
.legend strong { color: var(--text); }
@media (max-width: 720px) { .legend { grid-template-columns: minmax(0, 1fr); } }
.cta-panel {
  margin-block-start: 28px; padding: 22px 24px; border-radius: var(--radius);
  display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 14px 24px;
  background: linear-gradient(135deg, var(--accent-soft), transparent 70%), var(--surface); border: 1px solid var(--line);
}
.cta-panel p { margin: 0; font-weight: 600; max-width: 40rem; }
.fine { margin: 22px 0 0; text-align: center; color: var(--muted); font-size: 0.88rem; }

/* ---------- privacy ---------- */

.priv-list { margin: 0 0 24px; padding: 0; list-style: none; display: grid; gap: 14px; }
.priv-list li { position: relative; padding-inline-start: 34px; }
.priv-list li::before { content: ""; position: absolute; inset-inline-start: 0; top: 0.3em; width: 20px; height: 20px; border-radius: 50%; background: var(--ok-soft); }
.priv-list li::after { content: ""; position: absolute; inset-inline-start: 7px; top: calc(0.3em + 3px); width: 6px; height: 11px; border-right: 2.5px solid var(--ok); border-bottom: 2.5px solid var(--ok); transform: rotate(40deg) scale(.8); }
.small-note { font-size: 0.86rem; color: var(--muted); }

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

.faq { max-width: 52rem; margin-inline: auto; display: grid; gap: 12px; }
.faq details { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius-sm); }
.faq details[open] { border-color: color-mix(in srgb, var(--accent) 50%, var(--line)); }
.faq summary {
  list-style: none; cursor: pointer; display: flex; align-items: center; justify-content: space-between; gap: 16px;
  padding: 18px 22px; font-weight: 700; line-height: 1.45;
}
.faq summary::after {
  content: ""; flex: none; width: 9px; height: 9px;
  border-inline-end: 2.5px solid var(--accent); border-bottom: 2.5px solid var(--accent);
  transform: rotate(45deg); transition: transform .2s;
}
.faq details[open] summary::after { transform: rotate(225deg); }
.faq .answer { padding: 0 22px 20px; color: var(--muted); }
.faq .answer p { margin: 0; }

/* ---------- what's new ---------- */

.news { max-width: 52rem; margin-inline: auto; }
.release { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 26px 28px; }
.release-head { display: flex; flex-wrap: wrap; align-items: baseline; gap: 6px 14px; margin-block-end: 12px; }
.release-head h3 { margin: 0; font-size: 1.3rem; }
.release-head time { color: var(--muted); font-size: 0.92rem; }
.release ul { margin: 0; padding-inline-start: 1.2em; display: grid; gap: 8px; }
.release ul[lang="en"] { direction: ltr; text-align: left; }
.release-foot { margin-block-start: 18px; display: flex; flex-wrap: wrap; gap: 8px 22px; align-items: center; justify-content: space-between; }
.release-foot p { margin: 0; color: var(--muted); font-size: 0.9rem; }

/* ---------- prose pages (privacy, release notes, 404) ---------- */

.page { padding-block: clamp(40px, 6vw, 80px); }
.prose { max-width: 46rem; margin-inline: auto; }
.prose h1 { margin: 0 0 8px; font-size: clamp(2rem, 4vw, 2.8rem); line-height: 1.15; }
.prose h2 { margin: 2.2em 0 .5em; font-size: 1.4rem; }
.prose p, .prose li { color: var(--text); }
.prose .meta { color: var(--muted); }
.prose ul { padding-inline-start: 1.3em; }
.prose table { width: 100%; border-collapse: collapse; margin: 1.2em 0; font-size: 0.95rem; display: block; overflow-x: auto; }
.prose th, .prose td { text-align: start; padding: 10px 14px; border: 1px solid var(--line); vertical-align: top; }
.prose th { background: var(--surface-2); }
.prose .toggle { display: flex; gap: 8px; margin: 18px 0 8px; flex-wrap: wrap; }
.prose .toggle a { padding: 6px 16px; border: 1.5px solid var(--line); border-radius: 999px; text-decoration: none; font-weight: 600; font-size: 0.92rem; color: var(--text); }
.prose .toggle a[aria-current="true"] { background: var(--accent); border-color: var(--accent); color: var(--accent-ink); }
.prose .back { display: inline-block; margin-block-end: 20px; color: var(--muted); text-decoration: none; font-weight: 600; }
.prose .back:hover { color: var(--accent); }
.prose .release { margin-block: 22px; }
.notfound { text-align: center; padding-block: clamp(80px, 14vw, 180px); }
.notfound h1 { font-size: clamp(2.2rem, 6vw, 4rem); margin: 0 0 12px; }

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

.site-footer { border-top: 1px solid var(--line); background: var(--bg-alt); padding-block: 48px 36px; font-size: 0.94rem; }
.foot-grid { display: grid; grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr) minmax(0, 1.4fr); gap: 36px 48px; }
.site-footer h2 { margin: 0 0 12px; font-size: 0.82rem; font-weight: 700; color: var(--muted); }
html[data-script="latin"] .site-footer h2, html[data-script="cyrillic"] .site-footer h2 { text-transform: uppercase; letter-spacing: 0.08em; }
.site-footer ul { margin: 0; padding: 0; list-style: none; display: grid; gap: 8px; }
.site-footer a { color: var(--text); text-decoration: none; }
.site-footer a:hover { color: var(--accent); text-decoration: underline; }
.foot-brand p { margin: 12px 0 0; color: var(--muted); max-width: 34rem; }
.lang-cloud { display: flex; flex-wrap: wrap; gap: 8px 6px; }
.lang-cloud a { padding: 4px 11px; border: 1px solid var(--line); border-radius: 999px; font-size: 0.88rem; }
.lang-cloud a[aria-current="true"] { background: var(--accent-soft); border-color: var(--accent); color: var(--accent); font-weight: 700; }
.foot-bottom { margin-block-start: 36px; padding-block-start: 22px; border-top: 1px solid var(--line); color: var(--muted); font-size: 0.88rem; display: flex; flex-wrap: wrap; gap: 6px 24px; justify-content: space-between; }
@media (max-width: 880px) { .foot-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } .foot-brand { grid-column: 1 / -1; } }
@media (max-width: 520px) { .foot-grid { grid-template-columns: minmax(0, 1fr); } }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  * { transition: none !important; }
  .card:hover { transform: none; }
}
