/* ==========================================================================
   ALX Systems — public site
   No external fonts or scripts: fast, private (GDPR) and robot-friendly.
   The accent colour (--accent) is set by the administrator in Site settings.
   ========================================================================== */

:root {
  --accent: #ff7a1a;
  --bg: #0a0e13;
  --surface: #111821;
  --surface-2: #17202b;
  --line: rgba(255, 255, 255, .09);
  --line-strong: rgba(255, 255, 255, .18);
  --text: #e9eef3;
  --muted: #95a3b2;
  --light-bg: #f3f5f7;
  --light-surface: #ffffff;
  --light-text: #0d141c;
  --light-muted: #56636f;
  --light-line: #dde3e9;
  --radius: 10px;
  --radius-sm: 6px;
  --container: 1200px;
  --gutter: clamp(16px, 4vw, 40px);
  --header-h: 72px;
  --font: "Inter", "Segoe UI", system-ui, -apple-system, "Helvetica Neue", Arial, sans-serif;
  --mono: ui-monospace, "SFMono-Regular", "Cascadia Mono", "Roboto Mono", Menlo, Consolas, monospace;
  color-scheme: dark;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; scroll-padding-top: calc(var(--header-h) + 12px); }
body {
  margin: 0;
  font-family: var(--font);
  font-size: 1.0625rem;
  line-height: 1.6;
  color: var(--text);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}
img { max-width: 100%; height: auto; display: block; }
a { color: inherit; }
h1, h2, h3, h4 { line-height: 1.12; letter-spacing: -.02em; margin: 0 0 .5em; font-weight: 700; }
p { margin: 0 0 1em; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; border-radius: 2px; }

.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.skip-link { position: absolute; left: 12px; top: -60px; z-index: 100; background: var(--accent); color: #000; padding: 10px 16px; border-radius: var(--radius-sm); font-weight: 600; }
.skip-link:focus { top: 12px; }
.container { width: 100%; max-width: var(--container); margin: 0 auto; padding: 0 var(--gutter); }
.narrow-container { max-width: 820px; }
.muted { color: var(--muted); }
.pre-line { white-space: pre-line; }

/* ---------- Buttons ---------- */
.btn {
  --btn-bg: transparent; --btn-fg: inherit; --btn-bd: var(--line-strong);
  display: inline-flex; align-items: center; justify-content: center; gap: .5em;
  min-height: 46px; padding: 0 22px;
  border: 1px solid var(--btn-bd); border-radius: var(--radius-sm);
  background: var(--btn-bg); color: var(--btn-fg);
  font: 600 .95rem/1 var(--font); letter-spacing: .01em; text-decoration: none; cursor: pointer;
  transition: background-color .15s, border-color .15s, color .15s, transform .15s;
}
.btn:hover { transform: translateY(-1px); }
.btn-primary { --btn-bg: var(--accent); --btn-fg: #0a0e13; --btn-bd: var(--accent); }
.btn-primary:hover { filter: brightness(1.08); }
.btn-outline:hover, .btn-ghost:hover { --btn-bd: currentColor; }
.btn-dark { --btn-bg: #0a0e13; --btn-fg: #fff; --btn-bd: #0a0e13; }
.btn-ghost { --btn-bd: transparent; }
.btn-sm { min-height: 38px; padding: 0 14px; font-size: .88rem; }
.btn-block { width: 100%; }
.btn-row { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 28px; }
.inline-form { display: inline; margin: 0; }

/* ---------- Header ---------- */
.site-header {
  position: sticky; top: 0; z-index: 50;
  background: rgba(10, 14, 19, .82);
  backdrop-filter: saturate(160%) blur(14px); -webkit-backdrop-filter: saturate(160%) blur(14px);
  border-bottom: 1px solid var(--line);
}
.header-inner { display: flex; align-items: center; gap: 24px; min-height: var(--header-h); }
.brand { display: inline-flex; align-items: center; gap: 12px; text-decoration: none; font-weight: 800; letter-spacing: .01em; font-size: 1.2rem; white-space: nowrap; }
.brand img { height: 40px; width: auto; }
.brand-mark { width: 28px; height: 28px; flex: none; background: var(--accent); clip-path: polygon(50% 0, 100% 100%, 50% 74%, 0 100%); }
.site-nav { display: flex; align-items: center; flex: 1; gap: 24px; }
.nav-links { list-style: none; display: flex; gap: 4px; margin: 0 auto; padding: 0; }
.nav-links a { display: block; padding: 8px 12px; border-radius: var(--radius-sm); text-decoration: none; color: var(--muted); font-weight: 500; font-size: .95rem; transition: color .15s, background-color .15s; }
.nav-links a:hover { color: var(--text); background: rgba(255, 255, 255, .04); }
.nav-links a.active { color: var(--text); box-shadow: inset 0 -2px 0 var(--accent); border-radius: 0; }
.nav-account { display: flex; align-items: center; gap: 6px; }
.nav-toggle { display: none; margin-left: auto; width: 44px; height: 44px; border: 1px solid var(--line-strong); border-radius: var(--radius-sm); background: transparent; color: var(--text); cursor: pointer; position: relative; }
.nav-toggle-bar, .nav-toggle-bar::before, .nav-toggle-bar::after { position: absolute; left: 11px; width: 20px; height: 2px; background: currentColor; transition: transform .2s, opacity .2s; content: ""; }
.nav-toggle-bar { top: 20px; }
.nav-toggle-bar::before { left: 0; top: -6px; }
.nav-toggle-bar::after { left: 0; top: 6px; }
.nav-open .nav-toggle-bar { background: transparent; }
.nav-open .nav-toggle-bar::before { transform: translateY(6px) rotate(45deg); }
.nav-open .nav-toggle-bar::after { transform: translateY(-6px) rotate(-45deg); }

@media (max-width: 1000px) {
  .nav-toggle { display: block; }
  .site-nav {
    position: fixed; inset: var(--header-h) 0 auto 0; z-index: 49;
    flex-direction: column; align-items: stretch; gap: 16px;
    max-height: calc(100dvh - var(--header-h)); overflow-y: auto;
    padding: 16px var(--gutter) 24px;
    background: var(--bg); border-bottom: 1px solid var(--line);
    visibility: hidden; opacity: 0; transform: translateY(-8px);
    transition: opacity .2s, transform .2s, visibility .2s;
  }
  .nav-open .site-nav { visibility: visible; opacity: 1; transform: none; }
  .nav-links { flex-direction: column; margin: 0; }
  .nav-links a { padding: 14px 4px; font-size: 1.1rem; border-bottom: 1px solid var(--line); border-radius: 0; }
  .nav-links a.active { box-shadow: inset 3px 0 0 var(--accent); padding-left: 14px; }
  .nav-account { flex-wrap: wrap; }
  .nav-account .btn { flex: 1; }
  .no-js .site-nav { position: static; visibility: visible; opacity: 1; transform: none; }
}

/* ---------- Themes ---------- */
.theme-dark { background: var(--bg); color: var(--text); }
.theme-dark + .theme-dark { border-top: 1px solid var(--line); }
.theme-light { background: var(--light-bg); color: var(--light-text); color-scheme: light; --muted: var(--light-muted); --line: var(--light-line); --line-strong: #c5ced7; }
.theme-accent { background: var(--accent); color: #0a0e13; --muted: rgba(10, 14, 19, .72); --line: rgba(10, 14, 19, .15); --line-strong: rgba(10, 14, 19, .35); }
.theme-accent .eyebrow { color: #0a0e13; }
.theme-accent .eyebrow::before { background: #0a0e13; }
.theme-accent .btn-outline { --btn-bd: #0a0e13; }

/* ---------- Typography helpers ---------- */
.eyebrow {
  display: inline-flex; align-items: center; gap: 12px;
  margin: 0 0 18px; color: var(--accent);
  font: 600 .78rem/1.3 var(--mono); letter-spacing: .16em; text-transform: uppercase;
}
.eyebrow::before { content: ""; width: 28px; height: 2px; background: var(--accent); flex: none; }
.section { padding: clamp(64px, 9vw, 120px) 0; }
.section-tight { padding: clamp(48px, 6vw, 80px) 0; }
.section-head { max-width: 760px; margin-bottom: clamp(32px, 4vw, 52px); }
.section-head.center { margin-left: auto; margin-right: auto; text-align: center; }
.section-title { font-size: clamp(1.9rem, 3.6vw, 3rem); }
.lead { font-size: 1.15rem; color: var(--muted); margin: 0; }
.prose { max-width: 70ch; }
.prose.narrow { margin-bottom: 32px; }
.prose > :last-child { margin-bottom: 0; }
.prose h2 { font-size: 1.7rem; margin-top: 1.6em; }
.prose h3 { font-size: 1.3rem; margin-top: 1.4em; }
.prose a { color: var(--accent); text-underline-offset: 3px; }
.theme-light .prose a { color: inherit; text-decoration-color: var(--accent); text-decoration-thickness: 2px; }
.prose ul, .prose ol { padding-left: 1.2em; }
.prose li { margin: .35em 0; }
.prose li::marker { color: var(--accent); }
.prose img { border-radius: var(--radius); margin: 1.5em 0; }
.prose blockquote { margin: 1.5em 0; padding: .2em 0 .2em 1.2em; border-left: 3px solid var(--accent); font-size: 1.15rem; }
.prose code { font-family: var(--mono); font-size: .9em; padding: .1em .35em; border-radius: 4px; background: rgba(127, 127, 127, .15); }
.prose pre { overflow-x: auto; padding: 16px; border-radius: var(--radius-sm); background: #0a0e13; color: #e9eef3; }
.prose pre code { background: none; padding: 0; }
.prose hr { border: 0; border-top: 1px solid var(--line); margin: 2em 0; }
.table-wrap { overflow-x: auto; margin: 1.5em 0; }
.prose table { width: 100%; border-collapse: collapse; font-size: .97rem; }
.prose th, .prose td { text-align: left; padding: 10px 14px; border-bottom: 1px solid var(--line); }
.prose th { font: 600 .75rem/1.3 var(--mono); letter-spacing: .1em; text-transform: uppercase; color: var(--muted); }

/* ---------- Hero ---------- */
.hero { position: relative; overflow: hidden; isolation: isolate; display: flex; align-items: center; min-height: min(86vh, 860px); padding: clamp(80px, 12vw, 140px) 0; }
.hero-inline, .hero-plain { min-height: 0; }
.hero-plain { padding: clamp(72px, 10vw, 120px) 0 clamp(48px, 7vw, 80px); }
.page-plain .hero:first-child, .hero-inline { min-height: min(62vh, 620px); }
.hero-media { position: absolute; inset: 0; z-index: -2; width: 100%; height: 100%; object-fit: cover; object-position: 70% center; }
@media (max-width: 700px) { .hero-media { opacity: .45; } }
.hero::before { content: ""; position: absolute; inset: 0; z-index: -1; background: linear-gradient(90deg, rgba(10, 14, 19, .96) 0%, rgba(10, 14, 19, .82) 42%, rgba(10, 14, 19, .25) 100%), linear-gradient(0deg, rgba(10, 14, 19, .9) 0%, transparent 35%); }
.hero-plain::before { background: radial-gradient(1200px 500px at 85% 0%, color-mix(in srgb, var(--accent) 16%, transparent), transparent 70%); }
.theme-light.hero::before { background: linear-gradient(90deg, rgba(243, 245, 247, .97) 0%, rgba(243, 245, 247, .85) 45%, rgba(243, 245, 247, .2) 100%); }
.theme-accent.hero::before { background: linear-gradient(90deg, var(--accent) 0%, color-mix(in srgb, var(--accent) 85%, transparent) 50%, transparent 100%); }
.hero-grid {
  position: absolute; inset: 0; z-index: -1; pointer-events: none; opacity: .5;
  background-image: linear-gradient(var(--line) 1px, transparent 1px), linear-gradient(90deg, var(--line) 1px, transparent 1px);
  background-size: 64px 64px;
  mask-image: linear-gradient(180deg, #000 0%, transparent 85%); -webkit-mask-image: linear-gradient(180deg, #000 0%, transparent 85%);
}
.hero-inner { position: relative; }
.hero-inner > * { max-width: 760px; }
.hero-title { font-size: clamp(2.5rem, 6.4vw, 5.2rem); font-weight: 800; letter-spacing: -.035em; line-height: 1.02; margin-bottom: 24px; text-wrap: balance; }
.hero-inline .hero-title, .page-plain .hero-title { font-size: clamp(2.2rem, 5vw, 4rem); }
.hero-lead { font-size: clamp(1.1rem, 1.6vw, 1.3rem); color: var(--muted); max-width: 640px; margin: 0; }
.theme-dark .hero-lead { color: #c3ccd5; }

/* ---------- Page head (listings, articles) ---------- */
.page-head { position: relative; overflow: hidden; isolation: isolate; padding: clamp(56px, 8vw, 104px) 0 clamp(40px, 6vw, 72px); }
.page-head::before { content: ""; position: absolute; inset: 0; z-index: -1; background: radial-gradient(900px 400px at 90% 0%, color-mix(in srgb, var(--accent) 14%, transparent), transparent 70%); }
.page-head .hero-title { font-size: clamp(2.3rem, 5.4vw, 4.2rem); }
.article-title { font-size: clamp(2rem, 4.4vw, 3.3rem) !important; }
.breadcrumbs { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 28px; font-size: .88rem; color: var(--muted); }
.breadcrumbs a { color: var(--muted); text-decoration: none; }
.breadcrumbs a:hover { color: var(--text); }
.breadcrumbs span[aria-current] { color: var(--text); }

/* ---------- Split (text + image) ---------- */
.split { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(32px, 6vw, 88px); align-items: center; }
.split-reverse .split-media { order: -1; }
.split-noimage { grid-template-columns: 1fr; }
.split-media { margin: 0; border-radius: var(--radius); overflow: hidden; border: 1px solid var(--line); background: var(--surface); aspect-ratio: 4 / 3; }
.split-media img { width: 100%; height: 100%; object-fit: cover; }
.split-text .section-head { margin-bottom: 24px; }
@media (max-width: 860px) {
  .split { grid-template-columns: 1fr; }
  .split-reverse .split-media { order: 0; }
}

/* ---------- Feature grid ---------- */
.feature-grid { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(3, 1fr); gap: 1px; background: var(--line); border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; }
.feature-grid.count-4 { grid-template-columns: repeat(4, 1fr); }
.feature-grid.count-2 { grid-template-columns: repeat(2, 1fr); }
@media (max-width: 1000px) { .feature-grid, .feature-grid.count-4 { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 600px) { .feature-grid, .feature-grid.count-4, .feature-grid.count-2 { grid-template-columns: 1fr; } }
.feature { padding: clamp(24px, 3vw, 36px); background: var(--bg); transition: background-color .2s; }
.theme-light .feature { background: var(--light-surface); }
.theme-accent .feature { background: var(--accent); }
.feature:hover { background: var(--surface); }
.theme-light .feature:hover { background: #fafbfc; }
.feature-index { display: block; margin-bottom: 28px; font: 600 .8rem var(--mono); color: var(--accent); letter-spacing: .1em; }
.theme-accent .feature-index { color: #0a0e13; }
.feature h3 { font-size: 1.2rem; margin-bottom: .45em; }
.feature p { color: var(--muted); margin: 0; font-size: .98rem; }

/* ---------- Stats ---------- */
.stats-wrap .section-head { margin-bottom: 32px; }
.stats { display: grid; grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); gap: 0; margin: 0; }
.stat { display: flex; flex-direction: column-reverse; padding: 8px 28px; border-left: 1px solid var(--line-strong); }
.stat dt { font: 600 .78rem/1.4 var(--mono); letter-spacing: .14em; text-transform: uppercase; color: var(--muted); margin-top: 6px; }
.stat dd { margin: 0; font-size: clamp(2.4rem, 5vw, 3.8rem); font-weight: 800; letter-spacing: -.04em; line-height: 1; }
@media (max-width: 600px) {
  .stats { grid-template-columns: 1fr 1fr; row-gap: 28px; }
  .stat { padding: 4px 16px; }
}

/* ---------- Cards ---------- */
.card-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 320px), 1fr)); gap: 24px; }
.card-grid.count-1, .card-grid.count-2 { grid-template-columns: repeat(auto-fit, minmax(min(100%, 320px), 1fr)); }
.card-grid.count-1 { max-width: 560px; }
.card { border: 1px solid var(--line); border-radius: var(--radius); background: var(--surface); overflow: hidden; transition: transform .2s, box-shadow .2s, border-color .2s; }
.theme-light .card { background: var(--light-surface); box-shadow: 0 1px 2px rgba(13, 20, 28, .04); }
.card:hover { transform: translateY(-3px); border-color: var(--accent); box-shadow: 0 18px 40px -20px rgba(0, 0, 0, .45); }
.theme-light .card:hover { box-shadow: 0 18px 40px -22px rgba(13, 20, 28, .35); }
.card-link { display: flex; flex-direction: column; height: 100%; text-decoration: none; color: inherit; }
.card-media { position: relative; aspect-ratio: 16 / 10; background: #0d131a; overflow: hidden; }
.card-media-wide { aspect-ratio: 16 / 9; }
.card-media img { width: 100%; height: 100%; object-fit: cover; transition: transform .5s; }
.card:hover .card-media img { transform: scale(1.04); }
.card-body { display: flex; flex-direction: column; flex: 1; padding: 22px 24px 24px; }
.card-title { font-size: 1.35rem; margin-bottom: 4px; }
.card-sub { font-weight: 500; margin-bottom: 10px; }
.card-text { color: var(--muted); font-size: .96rem; margin-bottom: 18px; }
.card-date { display: block; font: 500 .8rem var(--mono); letter-spacing: .08em; text-transform: uppercase; color: var(--muted); margin-bottom: 10px; }
.card-more { margin-top: auto; font-weight: 600; font-size: .92rem; color: var(--accent); }
.theme-light .card-more { color: var(--light-text); text-decoration: underline; text-decoration-color: var(--accent); text-decoration-thickness: 2px; text-underline-offset: 4px; }
.tag { position: absolute; left: 14px; top: 14px; padding: 6px 10px; border-radius: 4px; font: 600 .7rem/1 var(--mono); letter-spacing: .1em; text-transform: uppercase; background: rgba(10, 14, 19, .82); color: #fff; backdrop-filter: blur(6px); }
.tag-defence { box-shadow: inset 3px 0 0 var(--accent); }
.tag-civil { box-shadow: inset 3px 0 0 #3fc1a5; }

/* ---------- CTA ---------- */
.cta { display: flex; align-items: center; justify-content: space-between; gap: 32px; flex-wrap: wrap; }
.cta > div:first-child { max-width: 680px; }
.cta-title { font-size: clamp(1.8rem, 3.4vw, 2.7rem); margin-bottom: 12px; }
.cta .prose p { margin: 0; }
.cta .btn-row { margin-top: 0; }

/* ---------- Contact ---------- */
.contact-card { font-style: normal; padding: 32px; border: 1px solid var(--line); border-radius: var(--radius); background: var(--surface); }
.theme-light .contact-card { background: var(--light-surface); }
.contact-card p { display: grid; gap: 2px; margin: 0 0 20px; }
.contact-card p:last-child { margin: 0; }
.contact-card .label { font: 600 .74rem var(--mono); letter-spacing: .12em; text-transform: uppercase; color: var(--muted); }
.contact-card a { font-size: 1.15rem; font-weight: 600; text-decoration: none; }
.contact-card a:hover { color: var(--accent); }

/* ---------- Filters & chips ---------- */
.filter-bar { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; margin-bottom: 36px; }
.filter-sep { width: 1px; height: 24px; background: var(--line-strong); margin: 0 6px; }
.chip { display: inline-flex; align-items: center; min-height: 36px; padding: 0 14px; border: 1px solid var(--line-strong); border-radius: 999px; text-decoration: none; font-size: .9rem; font-weight: 500; transition: all .15s; }
.chip:hover { border-color: currentColor; }
.chip.active { background: var(--light-text); border-color: var(--light-text); color: #fff; }
.theme-dark .chip.active { background: var(--text); color: var(--bg); }
.chip-strong { font-weight: 700; }
.empty { padding: 48px; text-align: center; border: 1px dashed var(--line-strong); border-radius: var(--radius); color: var(--muted); }
.pager { display: flex; align-items: center; justify-content: center; gap: 20px; margin-top: 48px; color: var(--muted); }

/* ---------- Product page ---------- */
.product-hero { position: relative; overflow: hidden; isolation: isolate; padding: clamp(48px, 7vw, 96px) 0; }
.product-hero::before { content: ""; position: absolute; inset: 0; z-index: -1; background: radial-gradient(900px 500px at 80% 40%, color-mix(in srgb, var(--accent) 16%, transparent), transparent 70%); }
.product-hero-inner { display: grid; grid-template-columns: 1fr 1.1fr; gap: clamp(32px, 5vw, 72px); align-items: center; }
.product-hero .hero-title { font-size: clamp(2.6rem, 6vw, 4.8rem); margin-bottom: 12px; }
.product-hero .hero-lead { color: var(--text); font-weight: 500; margin-bottom: 20px; }
.product-summary { color: var(--muted); max-width: 560px; }
.product-hero-media { margin: 0; border-radius: var(--radius); overflow: hidden; border: 1px solid var(--line); background: var(--surface); aspect-ratio: 16 / 11; }
.product-hero-media img { width: 100%; height: 100%; object-fit: cover; }
@media (max-width: 900px) { .product-hero-inner { grid-template-columns: 1fr; } }
.highlights { padding: 22px 0; }
.highlight-list { list-style: none; display: flex; flex-wrap: wrap; gap: 12px 40px; margin: 0 auto; }
.highlight-list li { display: flex; align-items: center; gap: 10px; font-weight: 600; }
.highlight-list li::before { content: ""; width: 8px; height: 8px; background: currentColor; transform: rotate(45deg); flex: none; }
.product-body { display: grid; grid-template-columns: minmax(0, 1fr) 400px; gap: clamp(32px, 5vw, 72px); align-items: start; }
@media (max-width: 960px) { .product-body { grid-template-columns: 1fr; } }
.spec-card { position: sticky; top: calc(var(--header-h) + 24px); padding: 28px; border-radius: var(--radius); background: var(--bg); color: var(--text); }
.spec-title { font: 600 .8rem var(--mono); letter-spacing: .14em; text-transform: uppercase; color: var(--accent); margin-bottom: 18px; }
.spec-list { margin: 0; }
.spec-list div { display: flex; justify-content: space-between; gap: 16px; padding: 12px 0; border-top: 1px solid rgba(255, 255, 255, .1); }
.spec-list dt { color: #95a3b2; font-size: .94rem; }
.spec-list dd { margin: 0; font-weight: 600; text-align: right; }
.gallery { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 280px), 1fr)); gap: 16px; }
.gallery-item { margin: 0; }
.gallery-item a { display: block; border-radius: var(--radius-sm); overflow: hidden; aspect-ratio: 4 / 3; background: var(--surface); cursor: zoom-in; }
.gallery-item img { width: 100%; height: 100%; object-fit: cover; transition: transform .4s; }
.gallery-item a:hover img { transform: scale(1.04); }
.gallery-item figcaption, .video-item figcaption { margin-top: 8px; font-size: .9rem; color: var(--muted); }
.video-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 460px), 1fr)); gap: 24px; }
.video-grid.single { grid-template-columns: minmax(0, 900px); }
.video-item { margin: 0; }
.video-item video, .video-frame, .video-facade { display: block; width: 100%; aspect-ratio: 16 / 9; border: 0; border-radius: var(--radius); background: #000; }
.video-facade { position: relative; padding: 0; overflow: hidden; cursor: pointer; color: #fff; }
.video-facade img { width: 100%; height: 100%; object-fit: cover; opacity: .8; transition: opacity .2s; }
.video-facade:hover img { opacity: 1; }
.video-facade .play { position: absolute; left: 50%; top: 50%; width: 76px; height: 76px; margin: -38px 0 0 -38px; border-radius: 50%; background: var(--accent); box-shadow: 0 10px 30px rgba(0, 0, 0, .5); }
.video-facade .play::after { content: ""; position: absolute; left: 31px; top: 24px; border-style: solid; border-width: 14px 0 14px 22px; border-color: transparent transparent transparent #0a0e13; }
.video-note { position: absolute; left: 12px; bottom: 10px; padding: 3px 8px; border-radius: 4px; background: rgba(0, 0, 0, .6); font-size: .75rem; }
.lightbox { width: 100vw; height: 100dvh; max-width: none; max-height: none; margin: 0; padding: 0; border: 0; background: rgba(5, 8, 11, .96); color: #fff; }
.lightbox::backdrop { background: rgba(0, 0, 0, .8); }
.lightbox figure { display: grid; place-items: center; height: 100%; margin: 0; padding: 56px 72px; }
.lightbox img { max-width: 100%; max-height: calc(100dvh - 140px); object-fit: contain; border-radius: 4px; }
.lightbox figcaption { margin-top: 12px; color: #c3ccd5; text-align: center; }
.lb-btn { position: absolute; width: 48px; height: 48px; border: 1px solid rgba(255, 255, 255, .25); border-radius: 50%; background: rgba(0, 0, 0, .4); color: #fff; font-size: 26px; line-height: 1; cursor: pointer; }
.lb-btn:hover { border-color: var(--accent); }
.lb-close { right: 16px; top: 16px; font-size: 18px; }
.lb-prev { left: 16px; top: 50%; }
.lb-next { right: 16px; top: 50%; }
.lightbox.single .lb-prev, .lightbox.single .lb-next { display: none; }
@media (max-width: 600px) { .lightbox figure { padding: 60px 8px; } .lb-prev, .lb-next { top: auto; bottom: 16px; } }
.restricted { display: grid; grid-template-columns: 340px 1fr; gap: 48px; align-items: start; }
@media (max-width: 860px) { .restricted { grid-template-columns: 1fr; gap: 16px; } }
.locked { padding: 28px; border: 1px dashed var(--line-strong); border-radius: var(--radius); background: var(--surface); }
.locked .btn-row { margin-top: 16px; }
.theme-light .locked { background: #fff; }
.docs-text { margin-bottom: 24px; }
.doc-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; }
.doc-item { display: flex; align-items: center; gap: 16px; padding: 14px 18px; border: 1px solid var(--line); border-radius: var(--radius); background: var(--light-surface); color: var(--light-text); }
.doc-icon { flex: none; display: grid; place-items: center; width: 48px; height: 56px; border-radius: 6px; background: #0a0e13; color: #fff; font: 800 .68rem var(--mono); box-shadow: inset 0 -4px 0 var(--accent); }
.doc-body { flex: 1; display: grid; gap: 3px; min-width: 0; }
.doc-desc { color: var(--muted); font-size: .93rem; }
.doc-body small { color: var(--muted); font: 600 .72rem var(--mono); letter-spacing: .08em; }
.doc-download { flex: none; white-space: nowrap; }
.doc-lock { flex: none; color: var(--muted); font-size: .85rem; font-weight: 600; }
.docs-note { margin-top: 12px; padding: 12px 14px; border-radius: var(--radius-sm); background: #fff3dc; color: #5c3a00; font-size: .92rem; }
@media (max-width: 600px) { .doc-item { flex-wrap: wrap; } .doc-download { width: 100%; } }

/* ---------- Article ---------- */
.article-image { margin: 0 0 40px; border-radius: var(--radius); overflow: hidden; }
.article .prose { font-size: 1.12rem; max-width: none; }
.tag-row { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 40px; }
.article-nav { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; margin-top: 48px; padding-top: 28px; border-top: 1px solid var(--line); }
.article-nav a { display: grid; gap: 4px; text-decoration: none; font-weight: 600; }
.article-nav a span { font: 500 .78rem var(--mono); letter-spacing: .08em; text-transform: uppercase; color: var(--muted); }
.article-nav a:hover { color: var(--accent); }
.article-nav .older { text-align: right; }

/* ---------- Auth & forms ---------- */
.auth-wrap { position: relative; overflow: hidden; isolation: isolate; display: grid; place-items: center; min-height: calc(100vh - var(--header-h)); padding: 56px var(--gutter); }
.auth-wrap::before { content: ""; position: absolute; inset: 0; z-index: -1; background: radial-gradient(700px 400px at 50% 0%, color-mix(in srgb, var(--accent) 14%, transparent), transparent 70%); }
.auth-card { width: 100%; max-width: 440px; padding: clamp(24px, 5vw, 44px); background: var(--surface); border: 1px solid var(--line); border-radius: 14px; box-shadow: 0 30px 80px -40px #000; }
.auth-card-wide { max-width: 680px; }
.auth-title { font-size: 2rem; margin-bottom: 6px; }
.auth-subtitle { font-size: 1.2rem; margin: 36px 0 16px; padding-top: 28px; border-top: 1px solid var(--line); }
.auth-foot { margin: 24px 0 0; text-align: center; color: var(--muted); font-size: .95rem; }
.auth-foot a, .check a, .alert a { color: var(--accent); }
form .btn-block { margin-top: 12px; }
.field { display: grid; gap: 6px; margin-bottom: 18px; }
.field-row { display: grid; grid-template-columns: 1fr 1fr; gap: 0 16px; }
@media (max-width: 600px) { .field-row { grid-template-columns: 1fr; } }
.field label { font-weight: 600; font-size: .92rem; }
.optional, .hint { color: var(--muted); font-weight: 400; font-size: .85rem; }
.field input, .field textarea, .field select {
  width: 100%; min-height: 48px; padding: 12px 14px;
  font: inherit; font-size: 1rem; color: var(--text);
  background: var(--bg); border: 1px solid var(--line-strong); border-radius: var(--radius-sm);
  transition: border-color .15s, box-shadow .15s;
}
.field textarea { min-height: 96px; resize: vertical; }
.field input:focus, .field textarea:focus { outline: none; border-color: var(--accent); box-shadow: 0 0 0 3px color-mix(in srgb, var(--accent) 25%, transparent); }
.field-error { color: #ff8a80; font-size: .88rem; }
.field-error:empty { display: none; }
.input-validation-error { border-color: #ff6b6b !important; }
.check { display: flex; gap: 10px; align-items: flex-start; margin: 4px 0 12px; font-size: .95rem; cursor: pointer; }
.check input { width: 18px; height: 18px; margin-top: 3px; accent-color: var(--accent); flex: none; }
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.alert { padding: 14px 16px; border-radius: var(--radius-sm); margin: 16px 0; background: var(--surface-2); border: 1px solid var(--line-strong); font-size: .95rem; }
.alert-error { border-color: rgba(255, 107, 107, .5); background: rgba(255, 107, 107, .08); }
.alert-ok { border-color: rgba(63, 193, 165, .5); background: rgba(63, 193, 165, .08); }
.validation-summary-valid { display: none; }
.alert ul { margin: 0; padding-left: 18px; }
.kv { margin: 20px 0; }
.kv div { display: grid; grid-template-columns: 140px 1fr; gap: 12px; padding: 10px 0; border-bottom: 1px solid var(--line); }
.kv dt { color: var(--muted); }
.kv dd { margin: 0; }
.badge { display: inline-block; padding: 4px 10px; border-radius: 999px; font-size: .8rem; font-weight: 600; background: var(--surface-2); border: 1px solid var(--line-strong); }
.badge-ok { color: #3fc1a5; border-color: rgba(63, 193, 165, .5); }
.badge-wait { color: #ffc15e; border-color: rgba(255, 193, 94, .5); }

/* ---------- Newsletter ---------- */
.news-form { display: flex; gap: 8px; }
.news-form input[type=email] {
  flex: 1; min-width: 0; min-height: 48px; padding: 0 14px;
  font: inherit; font-size: 1rem; color: var(--text);
  background: var(--bg); border: 1px solid var(--line-strong); border-radius: var(--radius-sm);
}
.theme-light .news-form input[type=email] { background: #fff; color: var(--light-text); }
.theme-accent .news-form input[type=email] { background: #fff; color: var(--light-text); border-color: transparent; }
.news-form input[type=email]:focus { outline: none; border-color: var(--accent); box-shadow: 0 0 0 3px color-mix(in srgb, var(--accent) 25%, transparent); }
.theme-accent .news-form .btn-primary { --btn-bg: #0a0e13; --btn-fg: #fff; --btn-bd: #0a0e13; }
.news-note { margin: 8px 0 0; font-size: .82rem; color: var(--muted); }
.news-note a { color: inherit; }
.news-band { display: grid; grid-template-columns: 1fr 1fr; gap: 24px 64px; align-items: center; }
.news-band .section-head { margin-bottom: 8px; }
@media (max-width: 860px) { .news-band { grid-template-columns: 1fr; } }
@media (max-width: 480px) { .news-form { flex-direction: column; } }

/* ---------- Footer ---------- */
.footer-news { display: grid; grid-template-columns: 1fr 1.1fr; gap: 16px 64px; align-items: center; padding-top: 48px; padding-bottom: 48px; border-bottom: 1px solid var(--line); }
.footer-news-title { font-size: 1.5rem; color: var(--text); margin-bottom: 6px; }
.footer-news p { margin: 0; }
.footer-news .news-note { margin-top: 8px; }
@media (max-width: 860px) { .footer-news { grid-template-columns: 1fr; } }
.site-footer { background: #070a0e; border-top: 1px solid var(--line); color: var(--muted); font-size: .95rem; }
.footer-grid { display: grid; grid-template-columns: 1.4fr 1fr 1fr 1.2fr; gap: 40px; padding-top: 64px; padding-bottom: 48px; }
.footer-brand .brand { color: var(--text); margin-bottom: 16px; }
.footer-brand p { max-width: 320px; }
.footer-title { font: 600 .76rem var(--mono); letter-spacing: .14em; text-transform: uppercase; color: var(--text); margin-bottom: 16px; }
.footer-links { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; }
.footer-links a { text-decoration: none; }
.footer-links a:hover { color: var(--accent); }
.footer-address { white-space: pre-line; }
.footer-bottom { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 16px; padding-top: 22px; padding-bottom: 28px; border-top: 1px solid var(--line); font-size: .88rem; }
.footer-inline { display: flex; flex-wrap: wrap; gap: 20px; list-style: none; margin: 0; padding: 0; }
.footer-inline a { text-decoration: none; }
.footer-inline a:hover { color: var(--text); }
@media (max-width: 860px) { .footer-grid { grid-template-columns: 1fr 1fr; } .footer-brand { grid-column: 1 / -1; } }
@media (max-width: 480px) { .footer-grid { grid-template-columns: 1fr; } }

/* ---------- Admin helpers on the public site ---------- */
.draft-banner { position: sticky; top: var(--header-h); z-index: 40; padding: 10px var(--gutter); background: #ffc15e; color: #1a1200; text-align: center; font-weight: 600; font-size: .92rem; }
.admin-fab { position: fixed; right: 20px; bottom: 20px; z-index: 60; padding: 12px 18px; border-radius: 999px; background: var(--accent); color: #0a0e13; font-weight: 700; text-decoration: none; box-shadow: 0 10px 30px -8px rgba(0, 0, 0, .6); }

/* ---------- Motion ---------- */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { transition: none !important; animation: none !important; scroll-behavior: auto !important; }
}
@media print {
  .site-header, .site-footer, .admin-fab, .btn-row { display: none !important; }
  body, .theme-dark, .theme-accent { background: #fff !important; color: #000 !important; }
}

/* ---------- Consent banner (Google Analytics) ---------- */
.consent {
  position: fixed; left: 16px; right: 16px; bottom: 16px; z-index: 70;
  display: flex; align-items: center; gap: 16px 28px; flex-wrap: wrap;
  max-width: 880px; margin: 0 auto; padding: 18px 22px;
  background: var(--surface); color: var(--text);
  border: 1px solid var(--line-strong); border-radius: var(--radius);
  box-shadow: 0 24px 60px -20px rgba(0, 0, 0, .7);
}
.consent[hidden] { display: none; }
.consent-text { flex: 1 1 380px; font-size: .92rem; }
.consent-text p { margin: 0 0 4px; }
.consent-text p:last-child { margin: 0; color: var(--muted); }
.consent-text a { color: var(--accent); }
.consent-actions { display: flex; gap: 8px; flex: 0 0 auto; }
.consent-actions .btn { min-width: 110px; }
@media (max-width: 480px) { .consent-actions { width: 100%; } .consent-actions .btn { flex: 1; } }
.restricted .section-title { font-size: clamp(1.8rem, 3vw, 2.4rem); overflow-wrap: anywhere; }

/* ---------- Home picture carousel ---------- */
.carousel-section { padding: 0; }
.carousel-section > .container { padding-top: clamp(40px, 6vw, 72px); }
.carousel-section .section-head { margin-bottom: 24px; }
.carousel { position: relative; overflow: hidden; aspect-ratio: 21 / 9; min-height: 340px; max-height: 78vh; width: 100%; background: #05080b; }
@media (max-width: 700px) { .carousel { aspect-ratio: 4 / 3; min-height: 0; } }
.slide { position: absolute; inset: 0; display: block; opacity: 0; transition: opacity 1s ease; pointer-events: none; color: #fff; text-decoration: none; }
.slide.is-active { opacity: 1; pointer-events: auto; z-index: 1; }
.slide img { width: 100%; height: 100%; object-fit: cover; transform: scale(1.001); transition: transform 6s ease-out; }
.slide.is-active img { transform: scale(1.04); }
.slide::after { content: ""; position: absolute; inset: 0; background: linear-gradient(0deg, rgba(5, 8, 11, .85) 0%, rgba(5, 8, 11, .25) 40%, transparent 65%); }
.slide-caption { position: absolute; left: 0; right: 0; bottom: 64px; z-index: 1; display: grid; gap: 4px; }
.slide-caption strong { font-size: clamp(1.6rem, 3.6vw, 2.8rem); font-weight: 800; letter-spacing: -.02em; line-height: 1.1; }
.slide-caption span { max-width: 640px; color: #d3dae1; font-size: clamp(.95rem, 1.4vw, 1.1rem); }
.slide-caption em { margin-top: 8px; font-style: normal; font-weight: 700; color: var(--accent); }
.slide:hover .slide-caption em, .slide:focus-visible .slide-caption em { text-decoration: underline; text-underline-offset: 4px; }
.slide:focus-visible { outline: 3px solid var(--accent); outline-offset: -3px; }
.carousel-controls { position: absolute; left: 0; right: 0; bottom: 22px; z-index: 2; display: flex; align-items: center; gap: 12px; pointer-events: none; }
.carousel-dots { display: flex; gap: 8px; pointer-events: auto; }
.dot { width: 28px; height: 4px; padding: 0; border: 0; border-radius: 2px; background: rgba(255, 255, 255, .35); cursor: pointer; transition: background-color .3s, width .3s; }
.dot:hover { background: rgba(255, 255, 255, .7); }
.dot.is-active { width: 44px; background: var(--accent); }
.dot::before { content: ""; display: block; margin: -10px 0; height: 24px; } /* larger touch target */
.carousel-pause { pointer-events: auto; margin-left: auto; width: 36px; height: 36px; border: 1px solid rgba(255, 255, 255, .35); border-radius: 50%; background: rgba(0, 0, 0, .35); color: #fff; font-size: .7rem; cursor: pointer; }
.carousel-pause:hover { border-color: var(--accent); }
@media (max-width: 700px) { .slide-caption { bottom: 52px; } .slide-caption span { display: none; } }
@media (prefers-reduced-motion: reduce) { .slide, .slide img { transition: none; } .slide.is-active img { transform: none; } }

/* ---------- Product versions & comparison ---------- */
.version-line { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 12px; margin: -4px 0 8px; color: var(--muted); font-size: .95rem; }
.version-badge { display: inline-block; padding: 3px 10px; border-radius: 999px; border: 1px solid var(--accent); color: var(--accent); font: 700 .8rem var(--mono); text-decoration: none; }
.card-version { margin-left: 6px; padding: 2px 8px; border-radius: 999px; border: 1px solid var(--line-strong); color: var(--muted); font: 600 .7rem var(--mono); vertical-align: middle; }
.version-block { margin-bottom: 16px; border: 1px solid var(--line); border-radius: var(--radius); background: var(--light-surface); }
.version-block > summary { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 14px; padding: 16px 20px; cursor: pointer; list-style: none; }
.version-block > summary::-webkit-details-marker { display: none; }
.version-block > summary::after { content: "+"; margin-left: auto; font-size: 1.4rem; line-height: 1; color: var(--muted); }
.version-block[open] > summary::after { content: "−"; }
.version-block .version-badge { font-size: .95rem; padding: 4px 12px; }
.version-date { color: var(--muted); font-size: .92rem; }
.version-tag { padding: 3px 10px; border-radius: 999px; background: var(--light-text); color: #fff; font-size: .75rem; font-weight: 700; }
.version-tag.draft { background: #ffc15e; color: #1a1200; }
.version-body { padding: 0 20px 24px; }
.variant-cards { list-style: none; margin: 0 0 20px; padding: 0; display: grid; grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); gap: 10px; }
.variant-cards li { display: grid; gap: 2px; padding: 12px 14px; border-radius: var(--radius-sm); background: var(--light-bg); border-left: 3px solid var(--accent); }
.variant-cards span { color: var(--muted); font-size: .88rem; }
.compare-wrap { overflow-x: auto; border: 1px solid var(--line); border-radius: var(--radius-sm); }
.compare-wrap:focus-visible { outline: 2px solid var(--accent); }
.compare { width: 100%; border-collapse: collapse; font-size: .95rem; }
.compare th, .compare td { padding: 12px 16px; border-bottom: 1px solid var(--line); text-align: center; }
.compare thead th { background: #0a0e13; color: #fff; font-weight: 700; white-space: nowrap; }
.compare thead th:first-child, .compare tbody th[scope=row] { text-align: left; }
.compare tbody th[scope=row] { font-weight: 600; position: sticky; left: 0; background: var(--light-surface); min-width: 180px; }
.compare thead th:first-child { position: sticky; left: 0; z-index: 1; }
.compare tbody tr:hover td, .compare tbody tr:hover th[scope=row] { background: #fafbfc; }
.compare-group th { background: var(--light-bg) !important; text-align: left !important; font: 700 .72rem var(--mono); letter-spacing: .12em; text-transform: uppercase; color: var(--muted); padding: 8px 16px; }
.c-yes { color: #138a6f; font-weight: 800; font-size: 1.15rem; }
.c-no, .c-none { color: #a3adb7; }
.c-text { font-weight: 600; }
.opt-pill { display: inline-block; padding: 2px 9px; border-radius: 999px; background: #fff3dc; color: #7a4b00; font-size: .75rem; font-weight: 700; }
.compare-legend { margin: 10px 0 0; color: var(--muted); font-size: .85rem; }
.compare-legend .c-yes { font-size: 1rem; }
.release-notes { margin-top: 24px; padding-top: 20px; border-top: 1px solid var(--line); }
.release-notes h3 { font-size: 1.1rem; }
#documentation .restricted { grid-template-columns: 1fr; gap: 28px; }
#documentation .restricted > div:first-child { display: flex; flex-wrap: wrap; align-items: flex-end; gap: 8px 32px; }
#documentation .restricted > div:first-child > * { margin-bottom: 0; }
#documentation .restricted > div:first-child .section-head, #documentation .eyebrow { flex-basis: 100%; }
#documentation .section-title { margin: 0; }
#documentation .btn-row { margin-top: 0 !important; }
/* "ALX Systems" keeps its spelling even inside labels styled in capitals. */
.brand-case { text-transform: none; }

/* ---------- Contact form ---------- */
.contact-split { align-items: start; }
.contact-form-card { padding: clamp(20px, 3vw, 32px); border-radius: var(--radius); background: var(--light-surface); border: 1px solid var(--line); color: var(--light-text); }
.theme-dark .contact-form-card { background: var(--surface); color: var(--text); }
.contact-form .field input, .contact-form .field select, .contact-form .field textarea { background: #fff; color: var(--light-text); border-color: #c5ced7; }
.theme-dark .contact-form .field input, .theme-dark .contact-form .field select, .theme-dark .contact-form .field textarea { background: var(--bg); color: var(--text); border-color: var(--line-strong); }
.contact-form .field select { appearance: auto; }
.contact-form .field-error { color: #c23b3b; }
.contact-form .alert-error { color: #8a1f1f; background: #fdeeee; border-color: #f0b4b4; }
.contact-form .check a { color: inherit; text-decoration-color: var(--accent); }
.contact-form .btn { margin-top: 8px; }
.contact-form [data-product-field][hidden] { display: none; }
/* Checkbox labels containing links: keep the text flowing as one paragraph. */
.check { display: block; position: relative; padding-left: 30px; }
.check input { position: absolute; left: 0; top: 0; margin-top: 3px; }

/* ---------- Shop: header cart ---------- */
.cart-link { position: relative; display: inline-flex; align-items: center; gap: 6px; min-height: 38px; padding: 0 10px; border-radius: var(--radius-sm); color: var(--muted); text-decoration: none; font-weight: 500; font-size: .92rem; }
.cart-link:hover, .cart-link.active { color: var(--text); background: rgba(255, 255, 255, .05); }
.cart-count { min-width: 20px; height: 20px; padding: 0 6px; border-radius: 999px; background: var(--accent); color: #0a0e13; font: 700 .75rem/20px var(--font); text-align: center; }
@media (min-width: 1001px) { .cart-label { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); } }

/* ---------- Shop: shared bits ---------- */
.mono { font-family: var(--mono); }
.nowrap { white-space: nowrap; }
.num { text-align: right; }
.page-head-sm { padding: clamp(40px, 6vw, 64px) 0 clamp(28px, 4vw, 44px); }
.page-head-sm .hero-title { font-size: clamp(2rem, 4.4vw, 3.2rem); margin-bottom: .2em; }
.theme-light .field input, .theme-light .field textarea, .theme-light .field select { background: #fff; color: var(--light-text); border-color: #c5ced7; }
.avail { font-weight: 600; font-size: .86rem; }
.avail-ok { color: #1f8a70; }
.avail-pre { color: #9a5b00; }
.avail-out { color: #b3261e; }
.theme-dark .avail-ok { color: #3fc1a5; } .theme-dark .avail-pre { color: #ffc15e; } .theme-dark .avail-out { color: #ff8a80; }
.release-line { font: 500 .85rem var(--mono); letter-spacing: .06em; text-transform: uppercase; color: var(--muted); margin: -4px 0 0; }
.release-line time { color: var(--text); }

/* ---------- Shop: product buy panel ---------- */
.buy-section { padding-top: clamp(32px, 5vw, 56px); padding-bottom: 0; }
.buy-card { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.25fr); gap: clamp(20px, 4vw, 48px); padding: clamp(20px, 3.5vw, 36px); background: #fff; border: 1px solid var(--light-line); border-left: 4px solid var(--accent); border-radius: var(--radius); box-shadow: 0 18px 40px -30px rgba(13, 20, 28, .4); }
.buy-title { font-size: clamp(1.5rem, 2.6vw, 2rem); }
.buy-release { padding: 10px 12px; border-radius: var(--radius-sm); background: #fff3dc; color: #5c3a00; font-size: .94rem; }
.buy-note { color: var(--muted); font-size: .9rem; }
.buy-note a { color: inherit; text-decoration-color: var(--accent); text-decoration-thickness: 2px; }
.buy-action .alert { margin-top: 0; }
.offer-list { border: 0; margin: 0 0 16px; padding: 0; display: grid; gap: 10px; }
.offer { position: relative; display: grid; grid-template-columns: 22px 1fr auto; grid-template-areas: "radio name price" "radio meta meta"; gap: 2px 12px; align-items: center; padding: 14px 16px; border: 1px solid var(--light-line); border-radius: var(--radius-sm); background: var(--light-bg); cursor: pointer; transition: border-color .15s, background-color .15s; }
.offer:hover { border-color: #c5ced7; }
.offer:has(input:checked) { border-color: var(--accent); background: color-mix(in srgb, var(--accent) 7%, #fff); box-shadow: inset 0 0 0 1px var(--accent); }
.offer input { grid-area: radio; width: 18px; height: 18px; accent-color: var(--accent); margin: 0; }
.offer-name { grid-area: name; font-weight: 700; }
.offer-price { grid-area: price; font-weight: 700; font-size: 1.1rem; white-space: nowrap; }
.offer-price small { font-weight: 500; font-size: .78rem; color: var(--muted); }
.offer-meta { grid-area: meta; display: flex; flex-wrap: wrap; gap: 4px 14px; font-size: .86rem; color: var(--muted); }
.offer.is-disabled { cursor: not-allowed; opacity: .6; }
.buy-row { display: flex; flex-wrap: wrap; align-items: flex-end; gap: 12px; }
.buy-row .field { margin: 0; }
.qty-field { width: 120px; }
.buy-row .btn { flex: 1; min-width: 180px; }
.buy-out { padding: 12px 14px; border-radius: var(--radius-sm); background: #fdeeee; color: #8a1f1f; }
.buy-out a { color: inherit; }
@media (max-width: 860px) { .buy-card { grid-template-columns: 1fr; } }

/* ---------- Shop: product cards ---------- */
.card-sales { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; margin: -6px 0 16px; }
.card-price { font-weight: 700; font-size: 1.05rem; }
.sale-tag { display: inline-block; padding: 3px 9px; border-radius: 999px; font: 600 .72rem/1.4 var(--mono); letter-spacing: .06em; text-transform: uppercase; border: 1px solid var(--line-strong); color: var(--muted); }
.sale-ok { color: #1f8a70; border-color: rgba(31, 138, 112, .45); }
.sale-pre { color: #9a5b00; border-color: rgba(154, 91, 0, .4); }
.sale-out { color: #b3261e; border-color: rgba(179, 38, 30, .35); }
.theme-dark .sale-ok { color: #3fc1a5; } .theme-dark .sale-pre { color: #ffc15e; } .theme-dark .sale-out { color: #ff8a80; }

/* ---------- Shop: cart ---------- */
.cart-empty { padding: 48px 24px; text-align: center; background: #fff; border: 1px dashed #c5ced7; border-radius: var(--radius); }
.cart-layout { display: grid; grid-template-columns: minmax(0, 1fr) 360px; gap: 32px; align-items: start; }
.cart-line { display: grid; grid-template-columns: 96px minmax(0, 1fr) auto auto 36px; gap: 16px; align-items: center; padding: 16px; margin-bottom: 12px; background: #fff; border: 1px solid var(--light-line); border-radius: var(--radius); }
.cart-line.has-problem { border-color: #f0b4b4; box-shadow: inset 3px 0 0 #b3261e; }
.cart-thumb { display: block; width: 96px; aspect-ratio: 4 / 3; border-radius: var(--radius-sm); background: #0d131a; overflow: hidden; }
.cart-thumb img { width: 100%; height: 100%; object-fit: cover; }
.cart-name { font-size: 1.1rem; margin: 0 0 2px; }
.cart-name a { text-decoration: none; }
.cart-name a:hover { text-decoration: underline; text-decoration-color: var(--accent); }
.cart-variant { margin: 0 0 4px; color: var(--muted); font-size: .92rem; }
.cart-avail { display: flex; flex-wrap: wrap; gap: 4px 14px; margin: 0; }
.cart-moq { font-size: .86rem; color: var(--muted); }
.cart-problem { margin: 6px 0 0; color: #b3261e; font-weight: 600; font-size: .9rem; }
.cart-qty { display: flex; align-items: center; gap: 8px; }
.cart-qty input { width: 84px; min-height: 42px; padding: 8px 10px; font: inherit; border: 1px solid #c5ced7; border-radius: var(--radius-sm); background: #fff; color: var(--light-text); }
.cart-qty input:focus { outline: none; border-color: var(--accent); box-shadow: 0 0 0 3px color-mix(in srgb, var(--accent) 25%, transparent); }
.cart-unit { color: var(--muted); font-size: .9rem; white-space: nowrap; }
.cart-subtotal { font-weight: 700; text-align: right; min-width: 90px; white-space: nowrap; }
.cart-remove { width: 36px; height: 36px; border: 1px solid transparent; border-radius: 50%; background: transparent; color: var(--muted); font-size: 1rem; cursor: pointer; }
.cart-remove:hover { color: #b3261e; border-color: #f0b4b4; background: #fdeeee; }
.cart-actions { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 4px; }
.cart-summary { position: sticky; top: calc(var(--header-h) + 16px); padding: 24px; background: #fff; border: 1px solid var(--light-line); border-radius: var(--radius); }
.cart-summary-title { font-size: 1.2rem; }
.cart-totals { margin: 0 0 12px; }
.cart-totals div { display: flex; justify-content: space-between; padding: 8px 0; border-bottom: 1px solid var(--light-line); }
.cart-totals dd { margin: 0; font-weight: 600; }
.cart-total { font-size: 1.25rem; font-weight: 700; border-bottom: 0 !important; }
.cart-login p { font-size: .94rem; }
.cart-login .btn + .btn { margin-top: 10px; }
.cart-summary button[disabled] { opacity: .5; cursor: not-allowed; transform: none; }
@media (max-width: 960px) { .cart-layout { grid-template-columns: 1fr; } .cart-summary { position: static; } }
@media (max-width: 640px) {
  .cart-line { grid-template-columns: 72px minmax(0, 1fr) auto; grid-template-areas: "thumb info remove" "qty qty sub"; }
  .cart-remove { justify-self: end; }
  .cart-thumb { grid-area: thumb; width: 72px; }
  .cart-info { grid-area: info; }
  .cart-remove { grid-area: remove; align-self: start; }
  .cart-qty { grid-area: qty; }
  .cart-subtotal { grid-area: sub; }
}

/* ---------- Shop: customer orders ---------- */
.table-wrap { overflow-x: auto; background: #fff; border: 1px solid var(--light-line); border-radius: var(--radius); }
.orders-table { width: 100%; border-collapse: collapse; font-size: .96rem; }
.orders-table th, .orders-table td { padding: 14px 16px; border-bottom: 1px solid var(--light-line); text-align: left; vertical-align: top; }
.orders-table thead th { font: 600 .74rem var(--mono); letter-spacing: .08em; text-transform: uppercase; color: var(--muted); background: var(--light-bg); }
.orders-table .num { text-align: right; }
.orders-table tfoot th, .orders-table tfoot td { border-bottom: 0; font-size: 1.1rem; }
.orders-table a { text-decoration-color: var(--accent); }
.status { display: inline-block; margin: 2px 6px 2px 0; padding: 3px 10px; border-radius: 999px; font: 600 .72rem/1.4 var(--mono); letter-spacing: .06em; text-transform: uppercase; background: #eef1f4; color: #56636f; }
.status-received { background: #ffe9d9; color: #8a3d00; }
.status-confirmed { background: #fff3dc; color: #7a4a00; }
.status-shipped, .status-completed { background: #e3f5ef; color: #1f6f5a; }
.status-cancelled { background: #fdeeee; color: #8a1f1f; }
.status-pre { background: #fff3dc; color: #7a4a00; }
.order-thanks { margin-top: 0; margin-bottom: 24px; }
.order-sub { font-size: 1.1rem; margin-top: 28px; }
.cart-section { padding-top: clamp(28px, 4vw, 48px); }
.avail-mto { color: #1d5fa8; }
.theme-dark .avail-mto { color: #7fb2ff; }
.sale-mto { color: #1d5fa8; border-color: rgba(29, 95, 168, .4); }
.theme-dark .sale-mto { color: #7fb2ff; }
.order-delivery { display: inline-block; margin-top: 4px; font-size: .88rem; color: #7a4a00; }

/* ---------- Shop: billing & invoices ---------- */
.billing-card { margin: 24px 0 0; padding: 22px 24px 8px; background: #fff; border: 1px solid var(--light-line); border-radius: var(--radius); scroll-margin-top: calc(var(--header-h) + 16px); }
.billing-card legend { padding: 0 6px; margin-left: -6px; font-weight: 700; font-size: 1.15rem; }
.billing-card .check { margin-bottom: 16px; }
.cart-extra dd { font-weight: 500; color: var(--muted); font-size: .9rem; }
.order-grid { display: grid; grid-template-columns: minmax(0, 1fr) 380px; gap: 28px; align-items: start; margin-top: 24px; }
.order-card { padding: 22px 24px; margin-bottom: 20px; background: #fff; border: 1px solid var(--light-line); border-radius: var(--radius); }
.order-card h2 { font-size: 1.15rem; margin-bottom: 12px; }
.order-card .kv { margin: 0; }
.order-card .kv div { grid-template-columns: 150px 1fr; padding: 8px 0; }
.pay-box { padding: 16px 18px; border-left: 3px solid var(--accent); background: var(--light-bg); border-radius: 0 var(--radius-sm) var(--radius-sm) 0; }
.pay-box .kv div { border-color: #e2e7ec; }
.pay-ref { font: 700 1.05rem var(--mono); letter-spacing: .02em; }
.paid-badge { display: inline-block; padding: 4px 12px; border-radius: 999px; background: #e3f5ef; color: #1f6f5a; font-weight: 700; font-size: .9rem; }
.unpaid-badge { display: inline-block; padding: 4px 12px; border-radius: 999px; background: #fff3dc; color: #7a4a00; font-weight: 700; font-size: .9rem; }
@media (max-width: 960px) { .order-grid { grid-template-columns: 1fr; } }
.pay-online { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 16px; margin: 6px 0 4px; }
.pay-online .buy-note { margin: 0; }
.field[hidden] { display: none; }

/* ---------- Logos ---------- */
.brand img.brand-logo { height: 58px; width: auto; }
.brand img.brand-mark-img { height: 30px; width: auto; flex: none; }
@media (max-width: 600px) { .brand img.brand-logo { height: 44px; } }
.terms-check { font-size: .88rem; margin: 6px 0 12px; }
.prose:has(table) { max-width: 1040px; }
.prose:has(table) > :not(table) { max-width: 70ch; }
.prose table { font-size: .92rem; }
.cart-ship dt small, .cart-total dt small { display: block; font-weight: 500; font-size: .78rem; color: var(--muted); }
.ship-block[hidden] { display: none; }
.ship-block { margin-bottom: 12px; }
.billing-card > .btn { margin: 0 0 18px; }

/* ---------- Saved order details ---------- */
.order-details { scroll-margin-top: calc(var(--header-h) + 16px); }
.od-lead { font-size: .95rem; margin: -6px 0 18px; }
.order-details select { appearance: auto; }
.details-summary { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 12px 24px; margin: 6px 0 10px; }
.details-summary address { font-style: normal; line-height: 1.5; }
.alabel-sm { font: 600 .74rem var(--mono); letter-spacing: .08em; text-transform: uppercase; color: var(--muted); margin: 0 0 4px; }
.details-edit { margin: 4px 0 16px; }
.details-edit > summary { cursor: pointer; font-weight: 600; color: var(--accent); margin-bottom: 12px; width: fit-content; }
.details-edit[open] > summary { margin-bottom: 8px; }

/* ---------- Support tickets ---------- */
.container-narrow { max-width: 860px; }
.ticket-actions { margin: 0 0 24px; }
.tickets-table .ticket-closed td { color: var(--muted); }
.prio { display: inline-block; padding: 3px 10px; border-radius: 999px; font: 600 .72rem/1.4 var(--mono); letter-spacing: .04em; white-space: nowrap; background: #eef1f4; color: #56636f; }
.prio-1 { background: #fdeeee; color: #8a1f1f; }
.prio-2 { background: #ffe9d9; color: #8a3d00; }
.prio-3 { background: #fff3dc; color: #6b4600; }
.prio-4 { background: #e8f0fb; color: #1f4f8a; }
.prio-5 { background: #eef1f4; color: #56636f; }
.tstatus { display: inline-block; padding: 3px 10px; border-radius: 999px; font: 600 .72rem/1.4 var(--mono); letter-spacing: .06em; text-transform: uppercase; white-space: nowrap; background: #eef1f4; color: #56636f; }
.tstatus-new, .tstatus-customerreplied { background: #fff3dc; color: #7a4a00; }
.tstatus-answered { background: #ffe9d9; color: #8a3d00; }
.tstatus-closed { background: #eef1f4; color: #56636f; }
.ticket-title { font-size: clamp(1.6rem, 3.4vw, 2.4rem); overflow-wrap: anywhere; }
.ticket-meta { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 14px; font-size: .95rem; }
.ticket-intro { margin: 0 0 20px; padding: 14px 18px; background: #fff; border: 1px solid var(--light-line); border-left: 3px solid var(--accent); border-radius: var(--radius-sm); white-space: pre-line; }
.ticket-form, .ticket-reply { padding: clamp(20px, 3vw, 28px); background: #fff; border: 1px solid var(--light-line); border-radius: var(--radius); }
.ticket-reply { margin-top: 28px; scroll-margin-top: calc(var(--header-h) + 16px); }
.ticket-reply h2 { font-size: 1.2rem; margin: 0 0 14px; }
.ticket-form .btn-row { margin-top: 8px; }
.prio-picker { border: 0; padding: 0; margin: 0 0 18px; min-width: 0; }
.prio-picker legend { font-weight: 600; font-size: .92rem; margin-bottom: 8px; padding: 0; }
.prio-options { display: grid; gap: 6px; }
.prio-option { position: relative; display: flex; gap: 12px; align-items: center; padding: 9px 12px; border: 1px solid #c5ced7; border-radius: var(--radius-sm); background: #fff; cursor: pointer; }
.prio-option input { position: absolute; opacity: 0; pointer-events: none; }
.prio-option:has(input:checked) { border-color: var(--accent); box-shadow: 0 0 0 2px color-mix(in srgb, var(--accent) 35%, transparent); }
.prio-option:has(input:focus-visible) { outline: 2px solid var(--accent); outline-offset: 2px; }
.prio-num { flex: none; display: grid; place-items: center; width: 28px; height: 28px; border-radius: 50%; font: 700 .9rem var(--mono); }
.prio-option.prio-1 .prio-num { background: #fdeeee; color: #8a1f1f; }
.prio-option.prio-2 .prio-num { background: #ffe9d9; color: #8a3d00; }
.prio-option.prio-3 .prio-num { background: #fff3dc; color: #6b4600; }
.prio-option.prio-4 .prio-num { background: #e8f0fb; color: #1f4f8a; }
.prio-option.prio-5 .prio-num { background: #eef1f4; color: #56636f; }
.prio-text { display: flex; flex-wrap: wrap; align-items: baseline; gap: 2px 10px; line-height: 1.35; }
.prio-text strong { min-width: 5.5em; }
.prio-text small { color: var(--muted); font-size: .88rem; }
.thread { list-style: none; margin: 0; padding: 0; display: grid; gap: 14px; }
.thread-msg { padding: 16px 20px; background: #fff; border: 1px solid var(--light-line); border-radius: var(--radius); scroll-margin-top: calc(var(--header-h) + 16px); }
.thread-msg.from-staff { border-left: 3px solid var(--accent); }
.thread-msg.from-me { margin-left: clamp(0px, 6vw, 48px); background: #fbfcfd; }
.thread-msg header { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 4px 12px; margin-bottom: 8px; font-size: .92rem; }
.thread-msg time, .thread-event time { color: var(--muted); font-size: .85rem; }
.thread-body { white-space: pre-wrap; overflow-wrap: anywhere; }
.thread-files { list-style: none; margin: 12px 0 0; padding: 10px 0 0; border-top: 1px dashed var(--light-line); display: grid; gap: 4px; font-size: .95rem; }
.thread-files a::before { content: "📎 "; }
.thread-files a { overflow-wrap: anywhere; }
.thread-event { text-align: center; font-size: .88rem; color: var(--muted); }
.ticket-close { display: flex; flex-wrap: wrap; align-items: center; gap: 10px 16px; margin-top: 22px; padding-top: 18px; border-top: 1px solid var(--light-line); }
.ticket-close p { margin: 0; color: var(--muted); }
[data-files-status].bad { color: #b3261e; font-weight: 600; }

/* Customer discount */
.cart-discount dd { color: #1f6f5a; font-weight: 700; }
.cart-discount dt small { display: block; font-weight: 500; font-size: .78rem; color: var(--muted); }
.order-discount { color: #1f6f5a; }

/* Bundles (combo products) */
.bundle-contents { margin: 0 0 18px; padding: 14px 16px; background: var(--light-bg); border-radius: var(--radius-sm); }
.bundle-contents ul { margin: 6px 0 0; padding-left: 18px; display: grid; gap: 3px; }
.bundle-contents li { font-size: .95rem; }
.line-kit { font-size: .86rem; }
.sale-kit { background: #e8f0fb; color: #1f4f8a; }
