/* xing Promo Landing Page — Swiss Minimalist Editorial System (Light & Matte Dark) */

:root,
[data-theme="light"] {
  --bg: #f8f8f7;
  --surface: #ffffff;
  --subtle: #f1f1ee;
  --code-bg: #fbfbfa;
  --border: #e5e5e1;
  --border-strong: #cfcfc9;

  --ink: #161615;
  --ink-secondary: #585854;
  --ink-muted: #8a8a83;

  --primary-bg: #161615;
  --primary-fg: #ffffff;
  --primary-hover: #2c2c2a;

  --ginkgo: #d98a00;
  --ginkgo-soft: rgba(217, 138, 0, 0.1);
  --ok: #15803d;

  --shadow-card: 0 1px 2px rgba(0, 0, 0, 0.04), 0 8px 28px rgba(0, 0, 0, 0.045);
  --shadow-stage: 0 2px 6px rgba(0, 0, 0, 0.05), 0 24px 64px rgba(0, 0, 0, 0.1);
  --font-sans: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  --font-mono: "JetBrains Mono", ui-monospace, SFMono-Regular, Menlo, monospace;
}

[data-theme="dark"] {
  --bg: #111112;
  --surface: #161618;
  --subtle: #1c1c1f;
  --code-bg: #131315;
  --border: #26262a;
  --border-strong: #3a3a41;

  --ink: #ededef;
  --ink-secondary: #a1a1aa;
  --ink-muted: #71717a;

  --primary-bg: #f4f4f5;
  --primary-fg: #111112;
  --primary-hover: #ffffff;

  --ginkgo: #f5b800;
  --ginkgo-soft: rgba(245, 184, 0, 0.12);
  --ok: #4ade80;

  --shadow-card: 0 1px 2px rgba(0, 0, 0, 0.35), 0 12px 32px rgba(0, 0, 0, 0.35);
  --shadow-stage: 0 2px 10px rgba(0, 0, 0, 0.45), 0 32px 80px rgba(0, 0, 0, 0.65);
}

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

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--font-sans);
  font-size: 15px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

.mono {
  font-family: var(--font-mono);
  font-variant-numeric: tabular-nums;
}

code {
  font-family: var(--font-mono);
  font-size: 0.88em;
  background: var(--subtle);
  border: 1px solid var(--border);
  border-radius: 4px;
  padding: 1px 5px;
}

.container {
  width: 100%;
  max-width: 1120px;
  margin: 0 auto;
  padding: 0 24px;
}

/* Sticky Minimal Navigation */
.nav {
  position: sticky;
  top: 0;
  z-index: 40;
  background: color-mix(in srgb, var(--bg) 88%, transparent);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border);
}

.nav-inner {
  height: 56px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: var(--ink);
  text-decoration: none;
  font-weight: 600;
  font-size: 15px;
  letter-spacing: -0.02em;
}
.brand-icon {
  display: block;
  border-radius: 5px;
}
.brand-tag {
  font-size: 10.5px;
  font-weight: 500;
  color: var(--ink-muted);
  border: 1px solid var(--border);
  background: var(--surface);
  border-radius: 99px;
  padding: 1px 7px;
  margin-left: 2px;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 24px;
}
.nav-links a {
  color: var(--ink-secondary);
  text-decoration: none;
  font-size: 13.5px;
  font-weight: 500;
  transition: color 0.12s;
}
.nav-links a:hover {
  color: var(--ink);
}

.nav-actions {
  display: flex;
  align-items: center;
  gap: 8px;
}

/* Theme Icon Toggle */
[data-theme="dark"] .icon-moon {
  display: none;
}
:root .icon-sun,
[data-theme="light"] .icon-sun {
  display: none;
}
[data-theme="dark"] .icon-sun {
  display: block;
}

/* Quiet Swiss Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  height: 32px;
  padding: 0 12px;
  border-radius: 7px;
  border: 1px solid var(--border);
  background: var(--surface);
  color: var(--ink);
  font-family: var(--font-sans);
  font-size: 13px;
  font-weight: 500;
  text-decoration: none;
  cursor: pointer;
  white-space: nowrap;
  transition: background 0.12s, border-color 0.12s, color 0.12s;
}
.btn:hover {
  background: var(--subtle);
  border-color: var(--border-strong);
}
.btn-primary {
  background: var(--primary-bg);
  border-color: var(--primary-bg);
  color: var(--primary-fg);
}
.btn-primary:hover {
  background: var(--primary-hover);
  border-color: var(--primary-hover);
}
.btn-ghost {
  background: transparent;
  border-color: transparent;
  color: var(--ink-secondary);
}
.btn-ghost:hover {
  background: var(--subtle);
  color: var(--ink);
}
.btn-active {
  background: var(--subtle);
  border-color: var(--border-strong);
  color: var(--ink);
}
.btn-lg {
  height: 40px;
  padding: 0 18px;
  font-size: 14px;
  border-radius: 8px;
}
.btn-sm {
  height: 28px;
  padding: 0 10px;
  font-size: 12px;
}
.btn-xs {
  height: 24px;
  padding: 0 8px;
  font-size: 11px;
  border-radius: 5px;
}
.btn-icon {
  width: 32px;
  padding: 0;
}

/* Hero */
.hero {
  padding: 64px 0 56px;
}
.hero-copy {
  max-width: 740px;
  margin: 0 auto 42px;
  text-align: center;
}
.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 11.5px;
  color: var(--ink-secondary);
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 99px;
  padding: 4px 12px;
  margin-bottom: 22px;
}
.eyebrow code {
  border: none;
  background: transparent;
  padding: 0;
  color: var(--ink);
}
.eyebrow-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--ginkgo);
  flex-shrink: 0;
}

.hero h1 {
  margin: 0 0 18px;
  font-size: clamp(34px, 5.2vw, 54px);
  line-height: 1.07;
  letter-spacing: -0.035em;
  font-weight: 700;
}
.hero-lead {
  margin: 0 auto 28px;
  max-width: 630px;
  font-size: 16.5px;
  line-height: 1.6;
  color: var(--ink-secondary);
}
.hero-ctas {
  display: flex;
  align-items: center;
  justify-content: center;
  flex-wrap: wrap;
  gap: 10px;
}

/* Cinema Video Stage */
.video-stage {
  border: 1px solid var(--border-strong);
  border-radius: 12px;
  background: var(--surface);
  box-shadow: var(--shadow-stage);
  overflow: hidden;
  scroll-margin-top: 76px;
}

.window-chrome {
  height: 36px;
  padding: 0 12px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  background: var(--subtle);
  border-bottom: 1px solid var(--border);
}
.window-dots {
  display: inline-flex;
  gap: 6px;
}
.window-dots span {
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: var(--border-strong);
}
.window-url {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 11px;
  color: var(--ink-muted);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.window-url img {
  border-radius: 3px;
}
.window-controls {
  display: inline-flex;
  align-items: center;
  gap: 4px;
}

.video-wrap {
  position: relative;
  background: #111112;
  aspect-ratio: 16 / 10;
}
.video-wrap video {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.chapter-bar {
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  border-top: 1px solid var(--border);
  background: var(--surface);
}
.chapter-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 10px 8px;
  border: none;
  border-right: 1px solid var(--border);
  background: transparent;
  color: var(--ink-secondary);
  font-family: var(--font-sans);
  font-size: 12px;
  font-weight: 500;
  cursor: pointer;
  transition: background 0.12s, color 0.12s;
  position: relative;
}
.chapter-btn:last-child {
  border-right: none;
}
.chapter-btn:hover {
  background: var(--subtle);
  color: var(--ink);
}
.chapter-btn.active {
  background: var(--subtle);
  color: var(--ink);
  font-weight: 600;
}
.chapter-btn.active::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  top: 0;
  height: 2px;
  background: var(--ginkgo);
}
.ch-num {
  font-size: 10.5px;
  color: var(--ink-muted);
}
.chapter-btn.active .ch-num {
  color: var(--ginkgo);
}

/* Metrics Strip */
.metrics-strip {
  margin-top: 32px;
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 14px;
}
.metric-box {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 16px 18px;
}
.metric-value {
  font-size: 20px;
  font-weight: 700;
  letter-spacing: -0.02em;
  color: var(--ink);
  margin-bottom: 4px;
}
.metric-label {
  font-size: 12.5px;
  line-height: 1.45;
  color: var(--ink-secondary);
}

/* Sections */
.section {
  padding: 76px 0;
  border-top: 1px solid var(--border);
}
.section-tinted {
  background: var(--surface);
}
.section-head {
  max-width: 640px;
  margin-bottom: 44px;
}
.section-kicker {
  display: inline-block;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.08em;
  color: var(--ginkgo);
  margin-bottom: 10px;
}
.section-head h2 {
  margin: 0 0 10px;
  font-size: clamp(24px, 3.2vw, 34px);
  line-height: 1.15;
  letter-spacing: -0.028em;
  font-weight: 700;
}
.section-head p {
  margin: 0;
  color: var(--ink-secondary);
  font-size: 15.5px;
}

/* Feature Alternating Rows */
.feature-list {
  display: flex;
  flex-direction: column;
  gap: 56px;
}
.feature-row {
  display: grid;
  grid-template-columns: 0.92fr 1.25fr;
  gap: 36px;
  align-items: center;
}
.feature-row.reverse .feature-text {
  order: 2;
}
.feature-row.reverse .feature-media {
  order: 1;
}

.pill {
  display: inline-block;
  font-size: 10.5px;
  font-weight: 600;
  letter-spacing: 0.04em;
  color: var(--ink-secondary);
  background: var(--subtle);
  border: 1px solid var(--border);
  border-radius: 5px;
  padding: 2px 8px;
  margin-bottom: 12px;
}
.feature-text h3 {
  margin: 0 0 12px;
  font-size: 22px;
  line-height: 1.22;
  letter-spacing: -0.02em;
}
.feature-text p {
  margin: 0 0 14px;
  color: var(--ink-secondary);
  font-size: 14.5px;
}
.check-list {
  margin: 0;
  padding: 0;
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 7px;
  font-size: 13.5px;
  color: var(--ink);
}
.check-list li {
  position: relative;
  padding-left: 18px;
}
.check-list li::before {
  content: "—";
  position: absolute;
  left: 0;
  color: var(--ginkgo);
  font-weight: 700;
}

.theme-preview-toggle {
  display: inline-flex;
  gap: 6px;
  margin-top: 6px;
}

.feature-media {
  margin: 0;
  border: 1px solid var(--border-strong);
  border-radius: 10px;
  overflow: hidden;
  background: var(--surface);
  box-shadow: var(--shadow-card);
}
.feature-media img {
  display: block;
  width: 100%;
  height: auto;
  cursor: zoom-in;
  transition: transform 0.2s ease;
}
.feature-media img:hover {
  transform: scale(1.008);
}

/* Comparison Table */
.table-card {
  border: 1px solid var(--border-strong);
  border-radius: 10px;
  background: var(--bg);
  overflow: hidden;
  box-shadow: var(--shadow-card);
}
.table-scroll {
  width: 100%;
  overflow-x: auto;
}
.compare-table {
  width: 100%;
  min-width: 720px;
  border-collapse: collapse;
  font-size: 13.5px;
}
.compare-table th,
.compare-table td {
  padding: 12px 16px;
  text-align: left;
  border-bottom: 1px solid var(--border);
}
.compare-table th {
  background: var(--subtle);
  font-weight: 600;
  color: var(--ink-secondary);
  font-size: 12.5px;
  letter-spacing: 0.01em;
}
.compare-table tr:last-child td {
  border-bottom: none;
}
.compare-table .col-xing {
  background: var(--ginkgo-soft);
  font-weight: 600;
  color: var(--ink);
}
.compare-table th.col-xing {
  color: var(--ink);
  font-weight: 700;
}
.compare-table td.yes {
  color: var(--ok);
}
.compare-table td.partial {
  color: var(--ink-secondary);
}
.compare-table td.no {
  color: var(--ink-muted);
}

/* Quickstart & Architecture */
.two-col {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
  margin-bottom: 24px;
}
.code-card {
  border: 1px solid var(--border-strong);
  border-radius: 10px;
  background: var(--surface);
  overflow: hidden;
  min-width: 0;
}
.code-card-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 8px 12px;
  background: var(--subtle);
  border-bottom: 1px solid var(--border);
  font-size: 11.5px;
  color: var(--ink-secondary);
}
.code-pre {
  margin: 0;
  padding: 14px 16px;
  background: var(--code-bg);
  overflow-x: auto;
  font-family: var(--font-mono);
  font-size: 12px;
  line-height: 1.55;
  color: var(--ink);
}
.code-pre code {
  border: none;
  background: transparent;
  padding: 0;
  font-size: inherit;
}

.arch-strip {
  display: grid;
  grid-template-columns: 1fr auto 1fr auto 1fr;
  gap: 12px;
  align-items: center;
  padding: 16px;
  border: 1px solid var(--border);
  border-radius: 10px;
  background: var(--surface);
}
.arch-node {
  padding: 10px 12px;
  border: 1px solid var(--border);
  border-radius: 7px;
  background: var(--bg);
}
.arch-title {
  font-size: 12px;
  font-weight: 600;
  margin-bottom: 3px;
}
.arch-desc {
  font-size: 12px;
  color: var(--ink-secondary);
}
.arch-arrow {
  font-size: 10.5px;
  color: var(--ink-muted);
  white-space: nowrap;
}

/* Footer */
.footer {
  border-top: 1px solid var(--border);
  padding: 28px 0;
  background: var(--surface);
}
.footer-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
}
.footer-note {
  font-size: 13px;
  font-weight: 400;
  color: var(--ink-muted);
}
.footer-links {
  display: flex;
  align-items: center;
  gap: 16px;
  font-size: 12px;
}
.footer-links a {
  color: var(--ink-secondary);
  text-decoration: none;
}
.footer-links a:hover {
  color: var(--ink);
}

/* Lightbox */
.lightbox {
  position: fixed;
  inset: 0;
  z-index: 100;
  background: rgba(12, 12, 14, 0.8);
  backdrop-filter: blur(4px);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
}
.lightbox[hidden] {
  display: none;
}
.lightbox-inner {
  max-width: min(1240px, 95vw);
  max-height: 92vh;
  background: var(--surface);
  border: 1px solid var(--border-strong);
  border-radius: 10px;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  box-shadow: var(--shadow-stage);
}
.lightbox-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 8px 12px;
  background: var(--subtle);
  border-bottom: 1px solid var(--border);
  font-size: 12px;
  color: var(--ink-secondary);
}
.lightbox-inner img {
  display: block;
  max-width: 100%;
  max-height: calc(92vh - 42px);
  object-fit: contain;
}

/* Responsive */
@media (max-width: 960px) {
  .metrics-strip {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .feature-row,
  .two-col {
    grid-template-columns: 1fr;
  }
  .feature-row.reverse .feature-text,
  .feature-row.reverse .feature-media {
    order: initial;
  }
  .chapter-bar {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
  .chapter-btn {
    border-bottom: 1px solid var(--border);
  }
  .arch-strip {
    grid-template-columns: 1fr;
    text-align: center;
  }
}

@media (max-width: 640px) {
  .nav-links,
  .brand-tag,
  .window-url {
    display: none;
  }
  .hero {
    padding: 40px 0 36px;
  }
  .metrics-strip,
  .chapter-bar {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}
