/* Electron RC (cloned from Electron Flight) — light theme (2026-10-15)
   Light, techy, clean. Brand cyan retained for buttons; --accent-text for text links. */

:root {
  --bg: #f6f8fb;
  --bg-elevated: #ffffff;
  --bg-card: #ffffff;
  --bg-card-hover: #f0f6fa;
  --border: rgba(16, 60, 90, 0.14);
  --border-strong: rgba(16, 90, 130, 0.30);
  --text: #2b3540;
  --text-muted: #55616e;
  --text-bright: #0d141c;
  --accent: #2fb0e5;
  --accent-hover: #4fc3f0;
  --accent-dim: rgba(47, 176, 229, 0.12);
  --accent-text: #0a6890; /* accent shade for text/links on light bg (WCAG AA) */
  --media-bg: #e9eef3;
  --accent-text-hover: #07506f;
  --accent-glow: rgba(47, 176, 229, 0.35);
  --radius: 12px;
  --radius-sm: 8px;
  --shadow: 0 12px 32px rgba(16, 40, 60, 0.12);
  --header-h: 64px;
  --max: 1120px;
  --font: "Inter", "Segoe UI", system-ui, -apple-system, sans-serif;
  --mono: "SF Mono", "Consolas", "Liberation Mono", monospace;
}

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

html {
  scroll-behavior: smooth;
  scrollbar-gutter: stable;
}

@supports not (scrollbar-gutter: stable) {
  html {
    overflow-y: scroll;
  }
}

/* Menu open: body is position:fixed via JS (mobile only). Do NOT set overflow:hidden
   on html — toggling that on the scrolling element resets scrollY to 0 in Chrome when
   scrollbar-gutter: stable is also set. Gutter on html stays reserved either way. */
html.nav-locked body {
  /* padding-right may also be set inline when scrollbar-gutter is unsupported */
  padding-right: var(--nav-scrollbar-comp, 0px);
  overscroll-behavior: none;
}

body {
  margin: 0;
  padding: 0;
  font-family: var(--font);
  font-size: 17px;
  line-height: 1.6;
  color: var(--text);
  background:
    radial-gradient(ellipse 80% 50% at 50% -20%, rgba(47, 176, 229, 0.12), transparent 55%),
    radial-gradient(ellipse 40% 30% at 100% 20%, rgba(47, 176, 229, 0.05), transparent 50%),
    var(--bg);
  min-height: 100vh;
  min-height: 100dvh;
  -webkit-font-smoothing: antialiased;
}

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

a {
  color: var(--accent-text);
  text-decoration: none;
  transition: color 0.2s ease, background 0.2s ease, border-color 0.2s ease, box-shadow 0.2s ease;
}

a:hover {
  color: var(--accent-text-hover);
}

h1, h2, h3, h4 {
  color: var(--text-bright);
  font-weight: 600;
  line-height: 1.25;
  margin: 0 0 0.6em;
}

h1 { font-size: clamp(1.65rem, 3.5vw, 2.25rem); letter-spacing: -0.02em; }
h2 { font-size: clamp(1.35rem, 2.5vw, 1.75rem); letter-spacing: -0.015em; }
h3 { font-size: 1.15rem; color: var(--accent-text); }

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

strong { color: var(--accent-text); font-weight: 600; }

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

li { margin-bottom: 0.35em; }

hr {
  border: none;
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--border-strong), transparent);
  margin: 2.5rem 0;
}

/* ---------- Layout ---------- */
/* Sticky footer: .site-wrap fills the viewport, main grows, footer sits flush at the bottom.
   Nothing in normal flow may follow .site-wrap — stray widget hosts would add a strip below the footer. */
.site-wrap {
  min-height: 100vh;
  min-height: 100dvh;
  display: flex;
  flex-direction: column;
}

body > .shopify-host:empty {
  display: none;
}

.container {
  width: min(100% - 2rem, var(--max));
  margin-inline: auto;
}

main {
  flex: 1;
}

/* ---------- Header / Nav ---------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 1000;
  height: var(--header-h);
  background: rgba(255, 255, 255, 0.88);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--border);
}

.header-inner {
  position: relative;
  height: var(--header-h);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
}

.brand {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  color: var(--text-bright);
  font-weight: 600;
  font-size: 0.95rem;
  letter-spacing: 0.02em;
}

.brand:hover { color: var(--text-bright); }

.brand img {
  width: 40px;
  height: 40px;
  object-fit: contain;
}

.nav-toggle {
  display: inline-flex;
  background: transparent;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  width: 44px;
  height: 44px;
  padding: 0;
  cursor: pointer;
  color: var(--accent-text);
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  /* Avoid iOS/WebKit first-tap-as-hover eating the open gesture after scroll. */
  touch-action: manipulation;
  -webkit-tap-highlight-color: transparent;
}

.nav-toggle:hover {
  border-color: var(--border-strong);
  background: var(--accent-dim);
}

.nav-toggle-bars {
  display: block;
  width: 18px;
  height: 2px;
  background: currentColor;
  position: relative;
  box-shadow: 0 -6px 0 currentColor, 0 6px 0 currentColor;
}

.site-nav {
  display: none;
  position: absolute;
  top: var(--header-h);
  left: 0;
  right: 0;
  flex-direction: column;
  align-items: stretch;
  gap: 0.35rem;
  padding: 0.75rem 1rem 1.15rem;
  background: rgba(255, 255, 255, 0.98);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--border);
  box-shadow: var(--shadow);
  max-height: calc(100vh - var(--header-h));
  max-height: calc(100dvh - var(--header-h));
  overflow-x: hidden;
  overflow-y: auto;
  overscroll-behavior: contain;
  -webkit-overflow-scrolling: touch;
}

.site-nav.is-open {
  display: flex;
}

/* Desktop: open menu = right 1/3 of the site body (.container / .header-inner),
   not 1/3 of the viewport. Absolute keeps the panel aligned to the content
   column's right edge when the body is centered with max-width. */
@media (min-width: 861px) {
  .site-nav {
    position: absolute;
    top: var(--header-h);
    left: auto;
    right: 0;
    width: 33.333%;
    max-width: 33.333%;
    box-sizing: border-box;
  }
}

.nav-group {
  display: flex;
  flex-direction: column;
  align-items: stretch;
  gap: 0.15rem;
}

.nav-group + .nav-group {
  margin-top: 0.35rem;
  padding-top: 0.65rem;
  border-top: 1px solid var(--border);
}

.nav-group-label {
  display: block;
  font-size: 0.7rem;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--accent-text);
  padding: 0.35rem 1rem 0.25rem;
}

.site-nav a {
  color: var(--text-muted);
  font-size: 1rem;
  font-weight: 500;
  padding: 0.8rem 1rem;
  border-radius: var(--radius-sm);
  white-space: normal;
}

.site-nav a:hover,
.site-nav a.is-active {
  color: var(--text-bright);
  background: var(--accent-dim);
}

/* ---------- Hero / Intro ---------- */
.hero {
  padding: 3rem 0 1.5rem;
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.8rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--accent-text);
  margin-bottom: 1rem;
}

.eyebrow::before {
  content: "";
  width: 28px;
  height: 1px;
  background: var(--accent);
}

.intro-blurb {
  max-width: 42rem;
  color: var(--text-muted);
  font-size: 1.05rem;
}

.intro-blurb strong {
  color: var(--text-bright);
}

/* ---------- Product spotlight ---------- */
.section {
  padding: 1.5rem 0 3rem;
}

.section-label {
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--text-muted);
  margin-bottom: 1.25rem;
  display: flex;
  align-items: center;
  gap: 1rem;
}

.section-label::after {
  content: "";
  flex: 1;
  height: 1px;
  background: var(--border);
}

.product-card {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1.1fr);
  gap: 2rem;
  align-items: stretch;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: calc(var(--radius) + 4px);
  padding: 1.5rem;
  box-shadow: var(--shadow);
  overflow: hidden;
  position: relative;
}

.product-card::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, rgba(47, 176, 229, 0.06), transparent 45%);
  pointer-events: none;
}

.product-media {
  position: relative;
  border-radius: var(--radius);
  overflow: hidden;
  background: var(--media-bg);
  border: 1px solid var(--border);
  width: 100%;
  max-width: 100%;
  align-self: start;
  min-width: 0;
}

.product-media img {
  width: 100%;
  height: auto;
  aspect-ratio: 1;
  object-fit: cover;
  display: block;
}

.product-body {
  position: relative;
  z-index: 1;
  height: 100%;
  display: flex;
  flex-direction: column;
}

.product-body h1 {
  margin-bottom: 0.75rem;
}

.product-body .lede {
  color: var(--text);
  margin-bottom: 1.25rem;
}

.price-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem 1.25rem;
  align-items: baseline;
  margin-bottom: 1.25rem;
  padding: 0.9rem 1rem;
  background: var(--accent-dim);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
}

.price {
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--text-bright);
  font-variant-numeric: tabular-nums;
}

.shipping-badge {
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--accent-text);
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  align-items: center;
  margin-bottom: 0.5rem;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.4rem;
  padding: 0.7rem 1.25rem;
  border-radius: var(--radius-sm);
  font-size: 0.95rem;
  font-weight: 600;
  border: 1px solid transparent;
  cursor: pointer;
  line-height: 1.2;
}

.btn-primary {
  background: var(--accent);
  color: #041018;
}

.btn-primary:hover {
  background: var(--accent-hover);
  color: #041018;
  box-shadow: 0 0 24px var(--accent-glow);
}

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

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

/* Shopify buy button host — keep compact */
.shopify-host {
  margin-top: 0.5rem;
  min-height: 48px;
}

.shopify-host iframe,
.shopify-host > div {
  max-width: 100%;
}

/* ---------- Tech cards ---------- */
.tech-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1.25rem;
}

.tech-card {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: 1.5rem;
  align-items: stretch;
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.25rem;
  transition: border-color 0.2s ease, background 0.2s ease;
}

.tech-card:hover {
  border-color: var(--border-strong);
  background: var(--bg-card-hover);
}

.tech-media {
  border-radius: var(--radius-sm);
  overflow: hidden;
  background: #000;
  border: 1px solid var(--border);
  aspect-ratio: 16 / 9;
  width: 100%;
  max-width: 100%;
  align-self: start;
  min-width: 0;
}

.tech-media video,
.tech-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.tech-body {
  height: 100%;
  display: flex;
  flex-direction: column;
}

.tech-body p {
  color: var(--text-muted);
  font-size: 0.98rem;
}

/* Tech card rows reused on inner pages (e.g. SCOPIC): labelled group below intro card */
.tech-section {
  margin-top: 2.25rem;
}

.tech-section .tech-body > :last-child {
  margin-bottom: 0;
}

/* ---------- Footer ---------- */
.site-footer {
  margin-top: auto;
  border-top: 1px solid var(--border);
  background: var(--bg-elevated);
  padding: 2rem 0 1.5rem;
}

.footer-inner {
  display: flex;
  flex-wrap: wrap;
  gap: 1.5rem;
  justify-content: space-between;
  align-items: center;
}

.footer-nav,
.social-nav {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem 1rem;
}

.footer-nav a,
.social-nav a {
  color: var(--text-muted);
  font-size: 0.9rem;
}

.footer-nav a:hover,
.social-nav a:hover {
  color: var(--accent-text);
}

.copyright {
  width: 100%;
  margin-top: 1.25rem;
  padding-top: 1.25rem;
  border-top: 1px solid var(--border);
  color: var(--text-muted);
  font-size: 0.85rem;
  text-align: center;
}

.sample-banner {
  background: linear-gradient(90deg, rgba(47, 176, 229, 0.15), rgba(47, 176, 229, 0.05));
  border-bottom: 1px solid var(--border);
  color: var(--text-muted);
  font-size: 0.8rem;
  text-align: center;
  padding: 0.45rem 1rem;
}

.sample-banner strong {
  color: var(--accent-text);
}

/* ---------- Responsive ---------- */
@media (max-width: 860px) {
  .product-card {
    grid-template-columns: 1fr;
    padding: 1.15rem;
  }

  .product-media img {
    aspect-ratio: 4 / 3;
  }

  .tech-card {
    grid-template-columns: 1fr;
  }

  .tech-media {
    aspect-ratio: 16 / 9;
  }
}

@media (max-width: 720px) {
  :root { --header-h: 60px; }

  .hero { padding-top: 2rem; }

  .footer-inner {
    flex-direction: column;
    align-items: flex-start;
  }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    transition: none !important;
    animation: none !important;
  }
}

/* ---------- Inner pages / prose ---------- */
.page-hero {
  padding: 2.5rem 0 1rem;
}

.page-hero h1 {
  margin-bottom: 0.75rem;
}

.page-hero .lede {
  max-width: 42rem;
  color: var(--text-muted);
  font-size: 1.05rem;
}

.content-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.5rem;
  box-shadow: var(--shadow);
  margin-bottom: 1.25rem;
  width: 100%;
}

.prose {
  /* Full-width within container; padding on .content-card keeps readable inset. */
  max-width: none;
  width: 100%;
}

.prose a {
  text-decoration: underline;
  text-underline-offset: 2px;
}

.media-row {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1rem;
  margin: 1.25rem 0;
  align-items: start;
}

.media-row > .media-frame {
  width: 100%;
  min-width: 0;
}

.media-row > .media-frame img,
.media-row > .media-frame video {
  width: 100%;
  height: auto;
  display: block;
}

.media-row.single {
  grid-template-columns: 1fr;
}

.media-frame {
  border-radius: var(--radius-sm);
  overflow: hidden;
  background: var(--media-bg);
  border: 1px solid var(--border);
}

.media-frame img,
.media-frame video {
  width: 100%;
  height: auto;
  display: block;
}

.media-frame.manual img {
  width: 100%;
}

.split-block {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1.1fr);
  gap: 1.5rem;
  align-items: stretch;
  margin: 1.25rem 0;
}

.split-block > .content-card {
  height: 100%;
  margin-bottom: 0;
  display: flex;
  flex-direction: column;
}

.split-block > .media-frame {
  margin: 0;
  width: 100%;
  max-width: 100%;
  align-self: start;
  min-width: 0;
}

.split-block > .media-frame > * {
  width: 100%;
  height: auto;
  display: block;
}

.feature-list {
  margin: 0 0 1.25rem;
  padding-left: 1.15em;
  color: var(--text);
}

.feature-list li {
  margin-bottom: 0.45em;
}

.meta-block h3 {
  margin-top: 1.25rem;
  margin-bottom: 0.5rem;
}

.meta-block h3:first-child {
  margin-top: 0;
}

.link-stack {
  display: flex;
  flex-direction: column;
  gap: 0.65rem;
  align-items: flex-start;
}

.link-stack a {
  font-weight: 500;
}

/* FAQ */
.faq-section {
  margin-top: 2rem;
  padding-top: 0.5rem;
}

.faq-item {
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 1rem 1.15rem;
  margin-bottom: 0.75rem;
}

.faq-item h3 {
  font-size: 1.05rem;
  margin-bottom: 0.5rem;
  color: var(--text-bright);
}

.faq-item p,
.faq-item ul {
  color: var(--text-muted);
  margin-bottom: 0.5em;
}

.faq-item ul:last-child,
.faq-item p:last-child {
  margin-bottom: 0;
}

/* Store product rows */
.store-grid {
  display: grid;
  gap: 1.25rem;
}

.store-card {
  display: grid;
  grid-template-columns: minmax(0, 280px) minmax(0, 1fr);
  gap: 1.5rem;
  align-items: stretch;
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.25rem;
  transition: border-color 0.2s ease, background 0.2s ease;
}

.store-card:hover {
  border-color: var(--border-strong);
  background: var(--bg-card-hover);
}

.store-card .media-frame {
  aspect-ratio: 1;
  width: 100%;
  max-width: 100%;
  align-self: start;
  min-width: 0;
}

.store-card .media-frame img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.store-card > :not(.media-frame) {
  height: 100%;
  display: flex;
  flex-direction: column;
}

/* Buttons inside stretched flex-column boxes: keep them short and left-aligned */
.tech-body > .btn,
.store-card > :not(.media-frame) > .btn,
.content-card > .btn,
.product-body > .btn {
  align-self: flex-start;
}

/* Forms */
.contact-panel {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: 1.5rem;
  align-items: stretch;
}

.contact-panel > .content-card {
  height: 100%;
  margin-bottom: 0;
  display: flex;
  flex-direction: column;
}

.contact-panel > .form {
  height: 100%;
}

.form {
  display: grid;
  gap: 0.85rem;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.25rem;
}

.form label {
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--text-muted);
  letter-spacing: 0.03em;
}

.form input,
.form textarea {
  width: 100%;
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  color: var(--text-bright);
  font: inherit;
  padding: 0.7rem 0.85rem;
}

.form input:focus,
.form textarea:focus {
  outline: none;
  border-color: var(--border-strong);
  box-shadow: 0 0 0 3px var(--accent-dim);
}

.form textarea {
  min-height: 140px;
  resize: vertical;
}

.form button[type="submit"] {
  justify-self: start;
  display: inline-flex;
  align-items: center;
  padding: 0.7rem 1.35rem;
  border: none;
  border-radius: var(--radius-sm);
  background: var(--accent);
  color: #041018;
  font-weight: 600;
  font-size: 0.95rem;
  cursor: pointer;
}

.form button[type="submit"]:hover {
  background: var(--accent-hover);
  box-shadow: 0 0 24px var(--accent-glow);
}

.alert-error {
  color: #a1001c;
  background: rgba(176, 0, 32, 0.12);
  border: 1px solid rgba(176, 0, 32, 0.35);
  border-radius: var(--radius-sm);
  padding: 0.85rem 1rem;
  margin-bottom: 1rem;
}

.alert-ok {
  color: var(--text);
  background: var(--accent-dim);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 0.85rem 1rem;
  margin-bottom: 1rem;
}

.hero-shot {
  margin: 0 0 1.25rem;
  border-radius: var(--radius);
  overflow: hidden;
  border: 1px solid var(--border);
  background: var(--media-bg);
}

.hero-shot img {
  width: 100%;
  max-height: 420px;
  object-fit: cover;
}

@media (max-width: 860px) {
  .split-block,
  .store-card,
  .contact-panel,
  .media-row {
    grid-template-columns: 1fr;
  }
}

/* ——— Content media lightbox (desktop only; img + video in <main>) ——— */
/* Matches redesign mobile breakpoint (max-width: 860px). */
@media (min-width: 861px) {
  img[data-lightbox],
  video[data-lightbox] {
    cursor: zoom-in;
  }
}

.lightbox {
  position: fixed;
  inset: 0;
  z-index: 10000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: max(1rem, env(safe-area-inset-top)) max(1rem, env(safe-area-inset-right))
    max(1rem, env(safe-area-inset-bottom)) max(1rem, env(safe-area-inset-left));
  background: rgba(232, 238, 244, 0.94);
  -webkit-backdrop-filter: blur(2px);
  backdrop-filter: blur(2px);
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transition: opacity 0.2s ease, visibility 0.2s ease;
}

.lightbox.is-open {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
}

.lightbox__dialog {
  position: relative;
  width: fit-content;
  max-width: min(96vw, 1400px);
  max-height: min(92vh, 92dvh);
  margin: 0;
  outline: none;
  line-height: 0;
  /* Border on the dialog (not the media) so it always hugs flush; avoids
     1–2px object-fit letterbox from border-box + 1px border on the media. */
  border: 1px solid var(--border-strong);
  border-radius: var(--radius-sm);
  box-shadow: var(--shadow);
  overflow: hidden;
  background: var(--media-bg);
}

.lightbox__image,
.lightbox__video {
  display: block;
  max-width: min(96vw, 1400px);
  max-height: min(88vh, 88dvh);
  width: auto;
  height: auto;
  margin: 0;
  border: none;
  border-radius: 0;
  box-shadow: none;
  background: var(--media-bg);
  /* fill: dimensions from fitLightboxMedia already match intrinsic aspect */
  object-fit: fill;
  cursor: default;
  vertical-align: top;
}

.lightbox__video {
  /* Intrinsic width/height (see fitLightboxMedia in site.js) — do not force
     viewport width or the border letterboxes when max-height clamps. */
  background: #000;
}

.lightbox__image[hidden],
.lightbox__video[hidden] {
  display: none !important;
}

.lightbox__close {
  /* Sit on the media frame (dialog hugs media via fit-content + fitLightboxMedia). */
  position: absolute;
  top: 10px;
  right: 10px;
  z-index: 2;
  width: 2.75rem;
  height: 2.75rem;
  padding: 0;
  border: 1px solid var(--border-strong);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.95);
  color: var(--text-bright);
  font-size: 1.6rem;
  line-height: 1;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  box-shadow: var(--shadow);
  transition: background 0.15s ease, border-color 0.15s ease, color 0.15s ease;
}

.lightbox__close:hover,
.lightbox__close:focus-visible {
  background: var(--bg-card-hover);
  border-color: var(--accent-text);
  color: var(--accent-text-hover);
  outline: none;
}

html.lightbox-open body {
  padding-right: var(--nav-scrollbar-comp, 0px);
  overscroll-behavior: none;
}

/* Mobile / narrow: feature off — no zoom cursor, overlay never shown. */
@media (max-width: 860px) {
  img[data-lightbox],
  video[data-lightbox] {
    cursor: default;
  }

  .lightbox,
  .lightbox.is-open {
    display: none !important;
    visibility: hidden !important;
    pointer-events: none !important;
  }
}

/* ---------- Legal link (footer copyright line) ---------- */
.copyright .legal-sep {
  margin: 0 0.6rem;
  opacity: 0.6;
}

.copyright .legal-link {
  color: var(--text-muted);
  text-decoration: underline;
  text-underline-offset: 2px;
}

.copyright .legal-link:hover {
  color: var(--accent-text);
}

/* ---------- Cookie consent banner (EU/UK only; injected by site.js) ---------- */
.consent-banner {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  /* Below the sticky header/menu (1000) and the lightbox (10000). */
  z-index: 900;
  padding: 0 1rem max(1rem, env(safe-area-inset-bottom));
  pointer-events: none;
}

.consent-banner[hidden] {
  display: none;
}

.consent-inner {
  pointer-events: auto;
  width: min(100%, var(--max));
  margin-inline: auto;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.75rem 1.25rem;
  background: rgba(255, 255, 255, 0.98);
  -webkit-backdrop-filter: blur(12px);
  backdrop-filter: blur(12px);
  border: 1px solid var(--border-strong);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 1rem 1.25rem;
}

.consent-text {
  flex: 1 1 24rem;
  min-width: 0;
  margin: 0;
  font-size: 0.92rem;
  line-height: 1.5;
  color: var(--text);
}

.consent-text strong {
  color: var(--text-bright);
}

.consent-text a {
  text-decoration: underline;
  text-underline-offset: 2px;
}

.consent-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.6rem;
}

.consent-actions .btn {
  min-width: 7.5rem;
}

.consent-banner .btn:focus-visible,
.consent-settings-btn:focus-visible {
  outline: 2px solid var(--accent-text);
  outline-offset: 2px;
}

/* Mobile menu open (scroll-locked overlay): tuck the banner away until it closes.
   visibility (not display) keeps its size so the footer spacing doesn't shift. */
html.nav-locked .consent-banner {
  visibility: hidden;
}

/* Keep the footer reachable above the banner while it is showing. */
html.consent-open .site-footer {
  padding-bottom: calc(1.5rem + var(--consent-h, 0px));
}

@media (max-width: 600px) {
  .consent-banner {
    padding: 0 0.5rem max(0.5rem, env(safe-area-inset-bottom));
  }

  .consent-inner {
    padding: 0.9rem 1rem;
    gap: 0.75rem;
  }

  .consent-text {
    flex-basis: 100%;
    font-size: 0.88rem;
  }

  .consent-actions {
    width: 100%;
  }

  .consent-actions .btn {
    flex: 1 1 0;
    min-width: 0;
  }
}

/* ---------- Privacy page ---------- */
.policy-summary {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1.25rem;
  margin-bottom: 1.25rem;
}

.policy-summary .tech-card {
  grid-template-columns: 1fr;
  gap: 0.5rem;
  align-content: start;
}

.policy-summary .tech-card h2 {
  font-size: 1.05rem;
  margin: 0;
  color: var(--text-bright);
}

.policy-summary .tech-card p {
  margin: 0;
  color: var(--text-muted);
  font-size: 0.95rem;
}

.policy-meta {
  color: var(--text-muted);
  font-size: 0.9rem;
}

.prose .policy-table-wrap {
  overflow-x: auto;
  margin: 0.75rem 0 1rem;
}

.prose table.policy-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.93rem;
}

.prose table.policy-table th,
.prose table.policy-table td {
  text-align: left;
  vertical-align: top;
  padding: 0.6rem 0.75rem;
  border-bottom: 1px solid var(--border);
}

.prose table.policy-table th {
  color: var(--text-bright);
  font-weight: 600;
}

.consent-status {
  color: var(--text-muted);
  font-size: 0.9rem;
  margin-top: 0.6rem;
}

@media (max-width: 860px) {
  .policy-summary {
    grid-template-columns: 1fr;
  }
}

/* ---- Light theme extras ---- */
.brand img, .site-header img[src*="logo"], .site-footer img[src*="logo"] { filter: brightness(0.22); }
::selection { background: rgba(47, 176, 229, 0.28); color: var(--text-bright); }
