/* ============================================================
   WIT-KOMP — design system v2
   Light/dark theme via [data-theme]; system fonts (no Google Fonts).
   ============================================================ */

:root {
  --font-sans: ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto,
    "Helvetica Neue", Arial, sans-serif;
  --font-mono: ui-monospace, "SF Mono", "Cascadia Code", Menlo, Consolas, monospace;

  --radius: 14px;
  --radius-sm: 9px;
  --container: 1160px;
  --transition: 180ms cubic-bezier(0.4, 0, 0.2, 1);

  /* Brand constants (same in both themes) */
  --navy-1: #0a1428;
  --navy-2: #101d3a;
  --navy-3: #16264a;
  --cyan: #38bdf8;
  --violet: #818cf8;
}

[data-theme="light"], :root {
  --bg: #f6f8fc;
  --bg-alt: #edf1f8;
  --surface: #ffffff;
  --border: #dde5f0;
  --border-strong: #c6d3e6;
  --text: #101d3a;
  --text-muted: #51617e;
  --accent: #0b6bd4;
  --accent-strong: #0954a8;
  --accent-contrast: #ffffff;
  --accent-soft: #e3effd;
  --ok: #147a46; --ok-bg: #ddf4e7;
  --warn: #8a5b00; --warn-bg: #fdf1d7;
  --danger: #b3261e; --danger-bg: #fbe4e2;
  --code-bg: #0d1729;
  --code-text: #d7e4f7;
  --shadow: 0 1px 2px rgba(16, 29, 58, 0.06), 0 12px 32px -12px rgba(16, 29, 58, 0.12);
  --shadow-lift: 0 2px 4px rgba(16, 29, 58, 0.08), 0 20px 44px -16px rgba(11, 107, 212, 0.28);
  --hero-text: #eaf2fd;
  --hero-muted: #a9bcd9;
}

[data-theme="dark"] {
  --bg: #0a1220;
  --bg-alt: #0e1830;
  --surface: #131f38;
  --border: #24344f;
  --border-strong: #33476b;
  --text: #e6edf8;
  --text-muted: #9db0cc;
  --accent: #4cc2ff;
  --accent-strong: #85d6ff;
  --accent-contrast: #051220;
  --accent-soft: #12304e;
  --ok: #55c98a; --ok-bg: #10331f;
  --warn: #e8b34b; --warn-bg: #33260d;
  --danger: #ff8078; --danger-bg: #3a1512;
  --code-bg: #0a1220;
  --code-text: #cfe0f5;
  --shadow: 0 1px 2px rgba(0, 0, 0, 0.5), 0 16px 40px -16px rgba(0, 0, 0, 0.55);
  --shadow-lift: 0 2px 4px rgba(0, 0, 0, 0.5), 0 22px 48px -16px rgba(76, 194, 255, 0.22);
  --hero-text: #eaf2fd;
  --hero-muted: #a9bcd9;
}

/* ---------- Reset & base ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation: none !important; transition: none !important; }
}

body {
  margin: 0;
  font-family: var(--font-sans);
  font-size: 1.0625rem;
  line-height: 1.7;
  color: var(--text);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

img, video { max-width: 100%; height: auto; }
a { color: var(--accent); text-decoration-thickness: 1px; text-underline-offset: 3px; }
a:hover { color: var(--accent-strong); }

h1, h2, h3, h4 { line-height: 1.18; margin: 0 0 0.5em; font-weight: 800; letter-spacing: -0.022em; text-wrap: balance; }
h1 { font-size: clamp(2rem, 4.5vw, 2.9rem); }
h2 { font-size: clamp(1.45rem, 3vw, 2rem); }
h3 { font-size: 1.18rem; font-weight: 700; }
p { margin: 0 0 1em; }

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

.container { max-width: var(--container); margin-inline: auto; padding-inline: clamp(1.1rem, 4vw, 2rem); }
.sr-only {
  position: absolute; width: 1px; height: 1px; margin: -1px;
  clip-path: inset(50%); overflow: hidden; white-space: nowrap;
}

.skip-link {
  position: absolute; top: -52px; left: 1rem; z-index: 100;
  background: var(--accent); color: var(--accent-contrast);
  padding: 0.6rem 1.1rem; border-radius: var(--radius-sm);
  font-weight: 600; text-decoration: none;
  transition: top var(--transition);
}
.skip-link:focus { top: 0.6rem; color: var(--accent-contrast); }

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 0.45rem;
  padding: 0.7rem 1.5rem;
  border-radius: 999px;
  border: 1px solid var(--border-strong);
  background: var(--surface);
  color: var(--text);
  font: inherit; font-size: 0.98rem; font-weight: 650;
  text-decoration: none; cursor: pointer;
  transition: transform var(--transition), box-shadow var(--transition),
              border-color var(--transition), background var(--transition);
}
.btn:hover { border-color: var(--accent); color: var(--accent); transform: translateY(-2px); box-shadow: var(--shadow); }
.btn:active { transform: translateY(0); }

.btn-primary {
  background: linear-gradient(135deg, var(--accent), #2d8fe8);
  border: 1px solid transparent;
  color: var(--accent-contrast);
  box-shadow: 0 8px 20px -8px color-mix(in srgb, var(--accent) 65%, transparent);
}
[data-theme="dark"] .btn-primary { background: linear-gradient(135deg, #4cc2ff, #7aa8ff); }
.btn-primary:hover {
  color: var(--accent-contrast);
  box-shadow: 0 12px 26px -8px color-mix(in srgb, var(--accent) 80%, transparent);
  filter: brightness(1.06);
}

.btn-secondary { background: transparent; border-color: var(--border-strong); color: inherit; }
.btn-danger { background: var(--danger); border-color: var(--danger); color: #fff; border-radius: var(--radius-sm); }
.btn-block { display: flex; width: 100%; }
.btn-small { padding: 0.35rem 0.85rem; font-size: 0.85rem; border-radius: var(--radius-sm); }
.btn-row { display: flex; gap: 0.5rem; flex-wrap: wrap; align-items: center; }

/* ---------- Header ---------- */
.site-header {
  position: sticky; top: 0; z-index: 50;
  background: color-mix(in srgb, var(--bg) 78%, transparent);
  backdrop-filter: blur(14px) saturate(1.4);
  -webkit-backdrop-filter: blur(14px) saturate(1.4);
  border-bottom: 1px solid color-mix(in srgb, var(--border) 70%, transparent);
}
.header-inner { display: flex; align-items: center; gap: 1.25rem; min-height: 68px; }
.brand { display: flex; align-items: center; gap: 0.65rem; text-decoration: none; color: var(--text); font-weight: 800; }
.brand-mark {
  display: grid; place-items: center;
  width: 38px; height: 38px; border-radius: 11px;
  background: linear-gradient(135deg, var(--navy-2), #0b6bd4 90%);
  color: #7ed3ff; font-size: 0.82rem; font-weight: 800; letter-spacing: 0.03em;
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.15), 0 4px 12px -4px rgba(11,107,212,0.5);
}
.brand-name { font-size: 1.08rem; letter-spacing: -0.01em; }

.main-nav { margin-left: auto; }
.nav-list { display: flex; gap: 0.15rem; list-style: none; margin: 0; padding: 0; }
.nav-list a {
  display: block; padding: 0.5rem 0.9rem; border-radius: 999px;
  color: var(--text-muted); text-decoration: none; font-weight: 550; font-size: 0.97rem;
  transition: background var(--transition), color var(--transition);
}
.nav-list a:hover { background: var(--accent-soft); color: var(--accent-strong); }
.nav-list a.active { background: var(--accent-soft); color: var(--accent-strong); font-weight: 700; }

.header-actions { display: flex; align-items: center; gap: 0.5rem; }
.theme-toggle {
  width: 38px; height: 38px; border-radius: 50%;
  border: 1px solid var(--border); background: var(--surface);
  color: var(--text); cursor: pointer; font-size: 1rem;
  transition: border-color var(--transition), transform var(--transition);
}
.theme-toggle:hover { border-color: var(--accent); transform: rotate(15deg); }
[data-theme="light"] .theme-icon-light { display: none; }
[data-theme="dark"] .theme-icon-dark { display: none; }
.lang-switch {
  display: grid; place-items: center;
  min-width: 40px; height: 38px; padding-inline: 0.6rem;
  border: 1px solid var(--border); border-radius: 999px;
  font-weight: 750; font-size: 0.85rem; letter-spacing: 0.05em;
  text-decoration: none; color: var(--text-muted);
  transition: border-color var(--transition), color var(--transition);
}
.lang-switch:hover { border-color: var(--accent); color: var(--accent); }

/* Mobile nav (checkbox hack — works without JS) */
.nav-toggle-input { display: none; }
.nav-toggle { display: none; }
@media (max-width: 880px) {
  .nav-toggle {
    display: flex; flex-direction: column; justify-content: center; gap: 5px;
    width: 42px; height: 40px; cursor: pointer; padding: 9px;
    border: 1px solid var(--border); border-radius: var(--radius-sm);
  }
  .nav-toggle span { height: 2px; background: var(--text); border-radius: 2px; transition: transform var(--transition); }
  .nav-list {
    display: none; position: absolute; left: 0; right: 0; top: 68px;
    flex-direction: column; gap: 0.15rem;
    background: var(--surface);
    border-bottom: 1px solid var(--border); padding: 0.75rem 1rem 1.1rem;
    box-shadow: var(--shadow);
  }
  .nav-list a { border-radius: var(--radius-sm); padding: 0.7rem 0.9rem; }
  .nav-toggle-input:checked ~ .nav-list { display: flex; }
  .main-nav { position: static; }
}

/* ---------- Hero ---------- */
.hero {
  position: relative; overflow: hidden; isolation: isolate;
  padding: clamp(4rem, 10vw, 7.5rem) 0 clamp(4.5rem, 10vw, 8rem);
  background:
    radial-gradient(900px 480px at 85% -10%, rgba(76, 194, 255, 0.22), transparent 65%),
    radial-gradient(700px 420px at -5% 110%, rgba(129, 140, 248, 0.18), transparent 60%),
    linear-gradient(165deg, var(--navy-1) 0%, var(--navy-2) 55%, var(--navy-3) 100%);
  color: var(--hero-text);
}
/* data-grid motif */
.hero::before {
  content: ""; position: absolute; inset: 0; z-index: -1;
  background-image:
    linear-gradient(rgba(126, 211, 255, 0.055) 1px, transparent 1px),
    linear-gradient(90deg, rgba(126, 211, 255, 0.055) 1px, transparent 1px);
  background-size: 44px 44px;
  mask-image: radial-gradient(ellipse 90% 80% at 50% 20%, black 30%, transparent 75%);
}
/* soft glow orb */
.hero::after {
  content: ""; position: absolute; z-index: -1;
  width: 560px; height: 560px; right: -140px; top: -180px;
  background: radial-gradient(circle, rgba(76,194,255,0.35), rgba(129,140,248,0.12) 55%, transparent 70%);
  filter: blur(10px);
  animation: hero-glow 9s ease-in-out infinite alternate;
  pointer-events: none;
}
@keyframes hero-glow {
  from { transform: translate3d(0, 0, 0) scale(1); opacity: 0.85; }
  to   { transform: translate3d(-36px, 26px, 0) scale(1.08); opacity: 1; }
}

.hero-title {
  color: #ffffff;
  font-size: clamp(2.3rem, 5.6vw, 3.7rem);
  max-width: 21ch;
  margin-bottom: 0.4em;
}
.hero-title::after { content: ""; display: block; width: 76px; height: 4px; margin-top: 0.55em;
  border-radius: 2px; background: linear-gradient(90deg, var(--cyan), var(--violet)); }
.hero-text {
  font-size: clamp(1.05rem, 2vw, 1.22rem);
  color: var(--hero-muted);
  max-width: 60ch; line-height: 1.75;
}
.hero-buttons { display: flex; gap: 0.8rem; flex-wrap: wrap; margin-top: 2rem; }
.hero .btn-primary { background: linear-gradient(135deg, #38bdf8, #6d9dff); color: #06121f; }
.hero .btn-secondary,
.hero .btn:not(.btn-primary) {
  background: rgba(255, 255, 255, 0.06);
  border-color: rgba(160, 195, 235, 0.35);
  color: #dce9fa;
}
.hero .btn:not(.btn-primary):hover { border-color: var(--cyan); color: #ffffff; }

.hero-inner { position: relative; z-index: 1; }
.hero-copy { max-width: 100%; }
.hero-decor { display: none; }
.hero-decor svg { width: 100%; height: auto; display: block; }

@media (min-width: 920px) {
  .hero-inner {
    display: grid;
    grid-template-columns: minmax(0, 1.05fr) minmax(280px, 0.95fr);
    align-items: center;
    gap: clamp(1.5rem, 4vw, 3.5rem);
  }
  .hero-decor {
    display: block;
    max-width: 460px;
    justify-self: end;
    filter: drop-shadow(0 24px 48px rgba(4, 12, 26, 0.5));
    animation: hero-float 7s ease-in-out infinite alternate;
  }
}

@keyframes hero-float {
  from { transform: translateY(-8px); }
  to   { transform: translateY(8px); }
}

/* Flow content blocks on the home page (contained, so they don't hug the edge) */
.home-prose { padding-block: clamp(2.4rem, 6vw, 4rem); }
.home-prose > * + * { margin-top: 1.5rem; }

/* ---------- Sections ---------- */
.home-section { padding: clamp(3.2rem, 7vw, 5.5rem) 0; }
.home-section.container { padding-inline: clamp(1.1rem, 4vw, 2rem); }
.home-section-alt {
  background:
    radial-gradient(700px 300px at 15% 0%, color-mix(in srgb, var(--accent-soft) 70%, transparent), transparent 70%),
    var(--bg-alt);
  border-block: 1px solid var(--border);
}
.home-section-alt .container { padding-block: clamp(3.2rem, 7vw, 5.5rem); }

.home-section h2, .home-section-alt h2 { position: relative; padding-bottom: 0.55rem; }
.home-section h2::after, .home-section-alt h2::after {
  content: ""; position: absolute; left: 0; bottom: 0;
  width: 52px; height: 3px; border-radius: 2px;
  background: linear-gradient(90deg, var(--accent), var(--violet));
}

/* ---------- Cards ---------- */
.card-grid {
  display: grid; gap: 1.4rem;
  grid-template-columns: repeat(auto-fill, minmax(290px, 1fr));
  margin-top: 2rem;
}
.card {
  position: relative; display: block; overflow: hidden;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.75rem;
  color: var(--text);
  text-decoration: none;
  box-shadow: var(--shadow);
  transition: transform var(--transition), border-color var(--transition), box-shadow var(--transition);
}
.card::before {
  content: ""; position: absolute; inset: 0 0 auto 0; height: 3px;
  background: linear-gradient(90deg, var(--accent), var(--violet));
  opacity: 0; transition: opacity var(--transition);
}
a.card:hover { transform: translateY(-5px); border-color: color-mix(in srgb, var(--accent) 45%, var(--border)); box-shadow: var(--shadow-lift); }
a.card:hover::before { opacity: 1; }
.card h2, .card h3 { margin-top: 0.9rem; font-size: 1.16rem; }
.card p { color: var(--text-muted); margin: 0.35rem 0 0; font-size: 0.98rem; line-height: 1.65; }

.service-icon {
  display: inline-grid; place-items: center;
  width: 52px; height: 52px; border-radius: 14px;
  color: var(--accent);
  background: var(--accent-soft);
  box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--accent) 22%, transparent);
}
.product-tagline { font-weight: 650; color: var(--text) !important; }

.badge {
  display: inline-block; padding: 0.2rem 0.7rem; border-radius: 999px;
  font-size: 0.76rem; font-weight: 750; letter-spacing: 0.04em; text-transform: uppercase;
}
.badge-soon { background: linear-gradient(90deg, var(--accent-soft), color-mix(in srgb, var(--violet) 18%, var(--accent-soft))); color: var(--accent-strong); }
.badge-ok { background: var(--ok-bg); color: var(--ok); }
.badge-warn { background: var(--warn-bg); color: var(--warn); }

.tech-strip, .tech-chips { display: flex; flex-wrap: wrap; gap: 0.55rem; list-style: none; padding: 0; margin: 1.4rem 0 0; }
.tech-chip {
  padding: 0.4rem 1rem; border-radius: 999px;
  background: var(--surface); border: 1px solid var(--border);
  font-size: 0.9rem; font-weight: 570;
  transition: border-color var(--transition), transform var(--transition);
}
.tech-chip:hover { border-color: var(--accent); transform: translateY(-2px); }
.tech-more { margin-top: 1.4rem; font-weight: 600; }

/* ---------- Article / page content ---------- */
.page-article { padding: clamp(2.6rem, 6vw, 4.2rem) clamp(1.1rem, 4vw, 2rem); }
.page-narrow { max-width: 800px; }
.page-header { margin-bottom: 2.4rem; max-width: 70ch; }
.page-header h1 { position: relative; padding-bottom: 0.4em; }
.page-header h1::after {
  content: ""; position: absolute; left: 0; bottom: 0;
  width: 64px; height: 4px; border-radius: 2px;
  background: linear-gradient(90deg, var(--accent), var(--violet));
}
.page-lead { font-size: 1.18rem; color: var(--text-muted); max-width: 62ch; line-height: 1.7; }

.content-rich, .content-paragraph { max-width: 72ch; }
.content-rich h2, .content-rich h3 { margin-top: 1.9em; }
.content-rich pre, .content-code {
  background: var(--code-bg); color: var(--code-text);
  padding: 1.1rem 1.35rem; border-radius: var(--radius-sm);
  overflow-x: auto; font-family: var(--font-mono); font-size: 0.9rem; line-height: 1.6;
  border: 1px solid rgba(126, 211, 255, 0.12);
}
.content-rich code { font-family: var(--font-mono); font-size: 0.92em; }
.content-rich :not(pre) > code {
  background: var(--bg-alt); padding: 0.12em 0.45em; border-radius: 5px;
  border: 1px solid var(--border);
}
.content-quote {
  margin: 1.8rem 0; padding: 1rem 1.6rem;
  border-left: 4px solid var(--accent);
  background: var(--bg-alt); border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
  font-size: 1.06rem;
}
.content-quote cite { color: var(--text-muted); font-style: normal; font-size: 0.9rem; }
.content-divider { border: 0; border-top: 1px solid var(--border); margin: 3rem 0; }
.content-figure { margin: 2.2rem 0; }
.content-figure img { border-radius: var(--radius); border: 1px solid var(--border); box-shadow: var(--shadow); }
.content-figure figcaption { color: var(--text-muted); font-size: 0.9rem; margin-top: 0.6rem; }
.content-gallery {
  display: grid; gap: 1.1rem; margin: 2.2rem 0;
  grid-template-columns: repeat(auto-fill, minmax(230px, 1fr));
}
.content-gallery img {
  border-radius: var(--radius-sm); border: 1px solid var(--border);
  transition: transform var(--transition), box-shadow var(--transition);
}
.content-gallery img:hover { transform: scale(1.02); box-shadow: var(--shadow-lift); }
.content-columns { display: grid; gap: 2.2rem; grid-template-columns: repeat(auto-fit, minmax(270px, 1fr)); margin: 1.8rem 0; }
.content-table-wrap { overflow-x: auto; margin: 1.8rem 0; border-radius: var(--radius-sm); border: 1px solid var(--border); }
.content-table-wrap table { border-collapse: collapse; width: 100%; }
.content-table-wrap th, .content-table-wrap td { border-bottom: 1px solid var(--border); padding: 0.7rem 1rem; text-align: left; }
.content-table-wrap th { background: var(--bg-alt); font-size: 0.92rem; }
.content-video video { width: 100%; border-radius: var(--radius); border: 1px solid var(--border); }
.content-button-wrap { margin: 1.8rem 0; }

/* ---------- CTA band ---------- */
.cta-band {
  position: relative; overflow: hidden; isolation: isolate;
  margin-top: 3.5rem; padding: clamp(3.2rem, 8vw, 5.5rem) 0;
  background:
    radial-gradient(700px 380px at 80% 120%, rgba(76,194,255,0.25), transparent 60%),
    radial-gradient(520px 320px at 8% -30%, rgba(129,140,248,0.22), transparent 60%),
    linear-gradient(150deg, var(--navy-1), var(--navy-3));
  color: #e4ecf7; text-align: center;
}
.cta-band::before {
  content: ""; position: absolute; inset: 0; z-index: -1;
  background-image:
    linear-gradient(rgba(126, 211, 255, 0.05) 1px, transparent 1px),
    linear-gradient(90deg, rgba(126, 211, 255, 0.05) 1px, transparent 1px);
  background-size: 44px 44px;
  mask-image: radial-gradient(ellipse 80% 90% at 50% 50%, black 20%, transparent 80%);
}
.cta-band h2 { color: #fff; }
.cta-band h2::after { display: none; }
.cta-band p { color: #b8c9e0; max-width: 58ch; margin-inline: auto; font-size: 1.08rem; }
.cta-band .btn-primary { background: linear-gradient(135deg, #38bdf8, #6d9dff); color: #06121f; margin-top: 0.8rem; }

.disclaimer {
  padding: 0.85rem 1.15rem; border-radius: var(--radius-sm);
  background: var(--warn-bg); color: var(--warn); font-size: 0.95rem;
  border: 1px solid color-mix(in srgb, var(--warn) 25%, transparent);
}

/* ---------- Services / case studies ---------- */
.service-section { margin: 3.4rem 0; padding-top: 1rem; }
.service-section-header { display: flex; align-items: center; gap: 1rem; }
.service-section-header h2 { margin: 0; }
.service-short { font-size: 1.08rem; color: var(--text-muted); margin-top: 0.8rem; }
.case-section { margin: 2.8rem 0; }
.case-card img { border-radius: var(--radius-sm); margin-bottom: 0.6rem; }

/* ---------- Product page ---------- */
.product-hero {
  position: relative; overflow: hidden; isolation: isolate;
  padding: clamp(3.5rem, 8vw, 6rem) 0;
  background:
    radial-gradient(800px 420px at 15% -20%, rgba(76,194,255,0.2), transparent 60%),
    linear-gradient(160deg, var(--navy-1), var(--navy-3));
  color: var(--hero-text);
}
.product-hero::before {
  content: ""; position: absolute; inset: 0; z-index: -1;
  background-image:
    linear-gradient(rgba(126, 211, 255, 0.05) 1px, transparent 1px),
    linear-gradient(90deg, rgba(126, 211, 255, 0.05) 1px, transparent 1px);
  background-size: 44px 44px;
  mask-image: radial-gradient(ellipse 90% 90% at 40% 10%, black 25%, transparent 80%);
}
.product-hero h1 { color: #fff; }
.product-hero .hero-text { color: var(--hero-muted); font-size: 1.15rem; }
.product-short { max-width: 60ch; color: var(--hero-muted); }
.product-hero .btn-primary { background: linear-gradient(135deg, #38bdf8, #6d9dff); color: #06121f; margin-top: 0.8rem; }
.product-links { display: flex; gap: 1.8rem; margin: 2.8rem 0 1rem; font-weight: 600; }
.product-features, .product-databases { margin: 3rem 0; }

/* ---------- FAQ ---------- */
.faq-section { margin: 3rem 0; }
.faq-item {
  border: 1px solid var(--border); border-radius: var(--radius-sm);
  background: var(--surface); margin-bottom: 0.65rem; padding: 0;
  transition: border-color var(--transition);
}
.faq-item:hover { border-color: var(--border-strong); }
.faq-item[open] { border-color: color-mix(in srgb, var(--accent) 40%, var(--border)); }
.faq-item summary {
  cursor: pointer; font-weight: 650; padding: 1rem 1.25rem;
  border-radius: var(--radius-sm);
}
.faq-item summary::marker { color: var(--accent); }
.faq-answer { padding: 0 1.25rem 1.1rem; color: var(--text-muted); }

/* ---------- Forms ---------- */
.field { margin-bottom: 1.15rem; display: flex; flex-direction: column; gap: 0.4rem; }
.field label { font-weight: 620; font-size: 0.95rem; }
.field input, .field select, .field textarea {
  font: inherit; color: var(--text);
  background: var(--surface);
  border: 1px solid var(--border-strong); border-radius: var(--radius-sm);
  padding: 0.68rem 0.9rem;
  transition: border-color var(--transition), box-shadow var(--transition);
}
.field input:focus, .field select:focus, .field textarea:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: 0 0 0 4px color-mix(in srgb, var(--accent) 18%, transparent);
}
.field-checkbox { flex-direction: row; align-items: flex-start; gap: 0.65rem; }
.field-checkbox input { margin-top: 0.32rem; accent-color: var(--accent); }
.field-checkbox label { font-weight: 400; }
.form-row { display: grid; gap: 0 1.4rem; grid-template-columns: repeat(auto-fit, minmax(250px, 1fr)); }
.contact-form, .waitlist-form {
  max-width: 760px;
  background: var(--surface); border: 1px solid var(--border);
  border-radius: var(--radius); padding: clamp(1.4rem, 4vw, 2.2rem);
  box-shadow: var(--shadow);
}
.hp-field { position: absolute; left: -9999px; width: 1px; height: 1px; opacity: 0; }
.contact-aside { margin-top: 2.2rem; color: var(--text-muted); }

.waitlist {
  margin: 3rem 0;
  padding: clamp(1.6rem, 4vw, 2.4rem);
  border-radius: var(--radius);
  background:
    radial-gradient(420px 200px at 100% 0%, color-mix(in srgb, var(--accent-soft) 80%, transparent), transparent 70%),
    var(--bg-alt);
  border: 1px solid var(--border);
}
.waitlist .waitlist-form { box-shadow: none; border: 0; background: transparent; padding: 0; }

.alert { padding: 0.95rem 1.2rem; border-radius: var(--radius-sm); font-weight: 520; }
.alert-success { background: var(--ok-bg); color: var(--ok); border: 1px solid color-mix(in srgb, var(--ok) 25%, transparent); }
.alert-error { background: var(--danger-bg); color: var(--danger); border: 1px solid color-mix(in srgb, var(--danger) 25%, transparent); }

/* ---------- Articles ---------- */
.article-search { display: flex; gap: 0.6rem; max-width: 500px; margin-bottom: 2.2rem; }
.article-search input {
  flex: 1; font: inherit; padding: 0.68rem 1rem;
  border: 1px solid var(--border-strong); border-radius: 999px;
  background: var(--surface); color: var(--text);
}
.article-search input:focus { outline: none; border-color: var(--accent); box-shadow: 0 0 0 4px color-mix(in srgb, var(--accent) 18%, transparent); }
.article-list { display: flex; flex-direction: column; gap: 1.3rem; }
.article-teaser {
  display: grid; grid-template-columns: minmax(0, 230px) 1fr; gap: 1.4rem;
  background: var(--surface); border: 1px solid var(--border);
  border-radius: var(--radius); padding: 1.4rem;
  color: var(--text); text-decoration: none;
  box-shadow: var(--shadow);
  transition: transform var(--transition), border-color var(--transition), box-shadow var(--transition);
}
.article-teaser:hover { border-color: color-mix(in srgb, var(--accent) 45%, var(--border)); transform: translateY(-3px); box-shadow: var(--shadow-lift); }
.article-teaser img { border-radius: var(--radius-sm); }
@media (max-width: 640px) { .article-teaser { grid-template-columns: 1fr; } }
.article-meta { color: var(--text-muted); font-size: 0.9rem; }
.read-more { color: var(--accent); font-weight: 650; }
.article-toc {
  border: 1px solid var(--border); border-left: 4px solid var(--accent);
  border-radius: var(--radius-sm);
  background: var(--bg-alt); padding: 1.1rem 1.6rem; margin: 2.2rem 0;
}
.article-toc h2 { font-size: 1rem; margin-bottom: 0.5rem; }
.article-toc h2::after { display: none; }
.article-toc ol { margin: 0; padding-left: 1.25rem; }
.toc-level-3 { margin-left: 1rem; }
.article-nav { display: flex; justify-content: space-between; gap: 1rem; margin-top: 3.2rem; flex-wrap: wrap; }
.article-nav a {
  display: flex; flex-direction: column; gap: 0.2rem; text-decoration: none;
  padding: 1.1rem 1.3rem; border: 1px solid var(--border); border-radius: var(--radius);
  color: var(--text); max-width: 48%;
  transition: border-color var(--transition), transform var(--transition);
}
.article-nav a:hover { border-color: var(--accent); transform: translateY(-2px); }
.article-nav a span { color: var(--text-muted); font-size: 0.85rem; }
.pagination { display: flex; gap: 1rem; justify-content: center; margin-top: 2.8rem; }

/* ---------- Footer ---------- */
.site-footer {
  margin-top: 5rem;
  background: linear-gradient(180deg, var(--navy-1), #070e1c);
  color: #b9c8de;
  border-top: 1px solid rgba(126, 211, 255, 0.14);
}
.footer-grid {
  display: grid; gap: 2.4rem; padding-block: 3.4rem;
  grid-template-columns: repeat(auto-fit, minmax(230px, 1fr));
}
.footer-brand { font-weight: 800; font-size: 1.2rem; margin: 0; color: #ffffff; }
.footer-legal-name { color: #8ea2bf; margin: 0.3rem 0 0.85rem; }
.footer-company p { margin: 0.3rem 0; color: #8ea2bf; font-size: 0.95rem; }
.footer-company a { color: #b9c8de; }
.footer-heading {
  font-size: 0.82rem; text-transform: uppercase; letter-spacing: 0.1em;
  color: #7d92b0; font-weight: 700;
}
.footer-heading::after { display: none; }
.footer-col ul { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 0.5rem; }
.footer-col a { color: #c6d4e8; text-decoration: none; transition: color var(--transition); }
.footer-col a:hover { color: var(--cyan); }
.footer-bottom {
  padding-block: 1.2rem; border-top: 1px solid rgba(126, 211, 255, 0.1);
  color: #7d92b0; font-size: 0.9rem;
}
.footer-bottom p { margin: 0; }

/* ---------- 404 / error ---------- */
.not-found { text-align: center; padding-block: 5rem; }
.not-found h1 {
  font-size: clamp(4rem, 14vw, 7rem); margin-bottom: 0;
  background: linear-gradient(120deg, var(--accent), var(--violet));
  -webkit-background-clip: text; background-clip: text; color: transparent;
}
.not-found h1::after { display: none; }

/* ---------- Auth pages ---------- */
.auth-page {
  min-height: 100dvh; display: grid; place-items: center; padding: 1rem;
  background:
    radial-gradient(700px 400px at 80% -10%, rgba(76,194,255,0.16), transparent 60%),
    linear-gradient(160deg, var(--navy-1), var(--navy-3));
}
.auth-card {
  width: 100%; max-width: 430px;
  background: var(--surface); border: 1px solid var(--border);
  border-radius: var(--radius); box-shadow: var(--shadow-lift);
  padding: 2.2rem;
}
.auth-brand { display: flex; align-items: center; gap: 0.65rem; font-weight: 800; margin-bottom: 1.6rem; }
.auth-form { margin-top: 1rem; }
.auth-alt { margin-top: 1.3rem; font-size: 0.95rem; }
.auth-card h1 { font-size: 1.4rem; }
.auth-card h1::after { display: none; }

/* ---------- Admin panel ---------- */
.admin { display: grid; grid-template-columns: 256px 1fr; min-height: 100dvh; }
.admin-sidebar {
  background: linear-gradient(180deg, var(--navy-1), var(--navy-2));
  color: #cdd9ea; padding: 1.35rem 1rem;
  display: flex; flex-direction: column; gap: 1rem;
  position: sticky; top: 0; height: 100dvh; overflow-y: auto;
}
.admin-brand { color: #fff; font-weight: 800; text-decoration: none; font-size: 1.05rem; }
.admin-brand span { color: #4cc2ff; }
.admin-nav { display: flex; flex-direction: column; gap: 2px; }
.admin-nav a {
  color: #cdd9ea; text-decoration: none; padding: 0.48rem 0.75rem;
  border-radius: var(--radius-sm); font-size: 0.95rem;
  transition: background var(--transition), color var(--transition);
}
.admin-nav a:hover { background: rgba(76, 194, 255, 0.12); color: #fff; }
.admin-nav a.active { background: rgba(76, 194, 255, 0.2); color: #fff; }
.admin-nav-group {
  margin: 0.95rem 0 0.25rem; font-size: 0.73rem; text-transform: uppercase;
  letter-spacing: 0.1em; color: #7d92b0; font-weight: 700;
}
.admin-content { background: var(--bg); }
.admin-topbar {
  display: flex; justify-content: flex-end; align-items: center; gap: 1rem;
  padding: 0.8rem 1.6rem; border-bottom: 1px solid var(--border); background: var(--surface);
}
.admin-user { color: var(--text-muted); font-size: 0.95rem; }
.admin-view-site { text-decoration: none; font-weight: 650; }
.admin-main { padding: 1.6rem; max-width: 1240px; }
.admin-card {
  background: var(--surface); border: 1px solid var(--border);
  border-radius: var(--radius); padding: 1.6rem; margin-bottom: 1.6rem;
  box-shadow: var(--shadow);
}
.admin-table { width: 100%; border-collapse: collapse; font-size: 0.95rem; }
.admin-table th, .admin-table td {
  text-align: left; padding: 0.65rem 0.8rem; border-bottom: 1px solid var(--border);
  vertical-align: top;
}
.admin-table th { color: var(--text-muted); font-size: 0.82rem; text-transform: uppercase; letter-spacing: 0.05em; }
.admin-toolbar { display: flex; gap: 0.75rem; align-items: center; flex-wrap: wrap; margin-bottom: 1.3rem; }
.admin-toolbar input, .admin-toolbar select {
  font: inherit; padding: 0.5rem 0.8rem; border-radius: var(--radius-sm);
  border: 1px solid var(--border-strong); background: var(--surface); color: var(--text);
}
.hint { color: var(--text-muted); font-size: 0.9rem; }
.dash-number { font-size: 2.4rem; font-weight: 800; color: var(--accent); margin: 0.2rem 0 0; }
.recovery-codes {
  margin-top: 1.6rem; padding: 1.1rem 1.35rem; border-radius: var(--radius-sm);
  background: var(--warn-bg); border: 1px solid var(--warn);
}
.recovery-codes ul { columns: 2; list-style: none; padding: 0; }
.totp-key code, .totp-uri code { word-break: break-all; }
.setup-steps { color: var(--text-muted); }

.editor-block {
  border: 1px solid var(--border); border-radius: var(--radius-sm);
  background: var(--surface); padding: 1.1rem; margin-bottom: 0.8rem;
}
.editor-block-head {
  display: flex; align-items: center; gap: 0.6rem; margin-bottom: 0.8rem;
  color: var(--text-muted); font-size: 0.84rem; font-weight: 750;
  text-transform: uppercase; letter-spacing: 0.05em;
}
.editor-block-head .btn-row { margin-left: auto; }
.editor-textarea { width: 100%; min-height: 90px; font-family: var(--font-mono); font-size: 0.9rem; }
.translation-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 1.6rem; }
@media (max-width: 1000px) { .translation-grid { grid-template-columns: 1fr; } }
.media-grid {
  display: grid; gap: 1rem;
  grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
}
.media-tile {
  border: 1px solid var(--border); border-radius: var(--radius-sm);
  background: var(--surface); padding: 0.55rem; text-align: center; font-size: 0.8rem;
  cursor: pointer; transition: border-color var(--transition);
}
.media-tile:hover { border-color: var(--accent); }
.media-tile img { width: 100%; height: 100px; object-fit: cover; border-radius: 5px; }
.media-tile.selected { outline: 3px solid var(--accent); }

.preview-bar {
  display: flex; gap: 0.6rem; align-items: center; justify-content: center;
  padding: 0.7rem 1rem; background: var(--warn-bg); color: var(--warn);
  font-size: 0.92rem;
}
.preview-frame { transition: max-width var(--transition); }

@media (max-width: 900px) {
  .admin { grid-template-columns: 1fr; }
  .admin-sidebar { position: static; height: auto; }
}

/* ---------- Product showcase (real App Store screenshots) ---------- */
.app-showcase {
  margin-top: clamp(2.5rem, 6vw, 4.5rem);
  padding: clamp(2.5rem, 6vw, 4rem) 0 clamp(3rem, 7vw, 5rem);
  background:
    radial-gradient(760px 340px at 85% 0%, rgba(76, 194, 255, 0.16), transparent 65%),
    var(--bg-alt);
  border-block: 1px solid var(--border);
}
/* Embedded variant (inside the product page's existing container): no full-bleed
   background band and no second container — it inherits the article width. */
.app-showcase-embedded {
  margin-top: clamp(1.6rem, 4vw, 2.4rem);
  padding: 0;
  background: none;
  border: 0;
}
.app-showcase-heading {
  position: relative; padding-bottom: 0.55rem; margin-bottom: 1.2rem;
}
.app-showcase-heading::after {
  content: ""; position: absolute; left: 0; bottom: 0;
  width: 52px; height: 3px; border-radius: 2px;
  background: linear-gradient(90deg, var(--accent), var(--violet));
}

.app-showcase-intro {
  display: flex; align-items: center; gap: clamp(1rem, 3vw, 1.6rem);
  flex-wrap: wrap; margin-bottom: clamp(1.6rem, 4vw, 2.4rem);
}
.app-showcase-icon {
  width: 96px; height: 96px; border-radius: 22px; flex-shrink: 0;
  box-shadow: var(--shadow-lift);
  border: 1px solid var(--border);
}
.app-showcase-copy { flex: 1 1 320px; }
.app-showcase-copy h2 { margin: 0.1rem 0 0.35rem; }
.app-showcase-eyebrow {
  margin: 0; text-transform: uppercase; letter-spacing: 0.09em;
  font-size: 0.76rem; font-weight: 700; color: var(--accent);
}
.app-showcase-tagline { color: var(--text-muted); max-width: 60ch; margin: 0 0 1.1rem; }

.app-shots {
  display: flex; gap: clamp(0.8rem, 2vw, 1.4rem);
  overflow-x: auto; scroll-snap-type: x mandatory;
  padding: 0.5rem 0.2rem 1.2rem;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: thin;
}
.app-shot {
  scroll-snap-align: start; flex: 0 0 auto; width: clamp(240px, 70vw, 340px);
  margin: 0; text-align: center;
}
.app-shot img {
  width: 100%; height: auto; display: block;
  border-radius: 20px;
  border: 1px solid var(--border-strong);
  background: var(--surface);
  box-shadow: var(--shadow-lift);
}
.app-shot figcaption {
  margin-top: 0.7rem; font-size: 0.88rem; font-weight: 600; color: var(--text-muted);
}
