/* SemlingIO landing page. Plain CSS, no build step, no external requests. */
:root {
  --bg: #f7f7fb;
  --surface: #ffffff;
  --surface-2: #eef0f8;
  --text: #14152b;
  --muted: #5a5d78;
  --line: #e1e3f0;
  --accent: #4f46e5;
  --accent-2: #06b6d4;
  --accent-3: #d946ef;
  /* Primary button and tag gradient: white text stays at 4.5:1 or more at both ends (WCAG AA). */
  --btn-from: #4f46e5;
  --btn-to: #a21caf;
  --accent-soft: #ebe9fe;
  --ok: #059669;
  --hero-bg: #0d0e24;
  --hero-text: #f4f4ff;
  --hero-muted: #b4b6d8;
  --glass: rgba(255, 255, 255, 0.06);
  --glass-line: rgba(255, 255, 255, 0.14);
  --shadow: 0 20px 50px -20px rgba(36, 30, 120, 0.35);
  --radius: 18px;
  --max: 1120px;
  color-scheme: light;
}
/* Dark theme: the system setting, unless the visitor picked light with the switch
   (assets/theme.js sets data-theme on <html>), or dark picked with the switch. The two blocks
   hold the same values: keep them in sync. */
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #0b0c1d;
    --surface: #14162e;
    --surface-2: #101227;
    --text: #ececfb;
    --muted: #a3a6c8;
    --line: #262947;
    --accent: #8b85ff;
    --btn-from: #5b54e8;
    --accent-soft: #23234a;
    --ok: #34d399;
    --hero-bg: #07081a;
    --shadow: 0 20px 50px -20px rgba(0, 0, 0, 0.7);
    color-scheme: dark;
  }
}
:root[data-theme="dark"] {
  --bg: #0b0c1d;
  --surface: #14162e;
  --surface-2: #101227;
  --text: #ececfb;
  --muted: #a3a6c8;
  --line: #262947;
  --accent: #8b85ff;
  --btn-from: #5b54e8;
  --accent-soft: #23234a;
  --ok: #34d399;
  --hero-bg: #07081a;
  --shadow: 0 20px 50px -20px rgba(0, 0, 0, 0.7);
  color-scheme: dark;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}
html {
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
  /* Anchor targets land below the sticky header. */
  scroll-padding-top: 80px;
}
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font:
    17px / 1.65 system-ui,
    -apple-system,
    "Segoe UI",
    Roboto,
    "Helvetica Neue",
    Arial,
    sans-serif;
}
img {
  max-width: 100%;
  height: auto;
  display: block;
}
a {
  color: var(--accent);
}
h1,
h2,
h3 {
  line-height: 1.15;
  margin: 0 0 0.5em;
  letter-spacing: -0.02em;
}
h1 {
  font-size: clamp(2.3rem, 6vw, 4rem);
  font-weight: 800;
}
h2 {
  font-size: clamp(1.7rem, 3.6vw, 2.5rem);
  font-weight: 800;
}
h3 {
  font-size: 1.15rem;
}
p {
  margin: 0 0 1em;
}
code,
pre {
  font-family: ui-monospace, "Cascadia Code", Consolas, Menlo, monospace;
}

.wrap {
  max-width: var(--max);
  margin: 0 auto;
  padding: 0 16px;
}
.gradient-text {
  background: linear-gradient(90deg, var(--accent-2), #a5b4fc 45%, var(--accent-3));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

/* Header */
.site-header {
  position: sticky;
  top: 0;
  z-index: 10;
  background: rgba(13, 14, 36, 0.78);
  backdrop-filter: saturate(160%) blur(14px);
  -webkit-backdrop-filter: saturate(160%) blur(14px);
  border-bottom: 1px solid var(--glass-line);
}
.site-header .wrap {
  display: flex;
  align-items: center;
  gap: 16px;
  min-height: 64px;
  flex-wrap: wrap;
}
.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  font-weight: 800;
  font-size: 1.2rem;
  color: var(--hero-text);
  text-decoration: none;
  letter-spacing: -0.01em;
}
.brand img {
  width: 32px;
  height: 32px;
}
.nav {
  display: flex;
  gap: 20px;
  margin-left: auto;
  align-items: center;
  flex-wrap: wrap;
}
.nav a {
  color: var(--hero-muted);
  text-decoration: none;
  font-weight: 500;
}
.nav a:hover,
.nav a[aria-current="page"] {
  color: var(--hero-text);
}
/* On phones the header wraps to several rows: it scrolls away instead of covering the page. */
@media (max-width: 720px) {
  html {
    scroll-padding-top: 16px;
  }
  .site-header {
    position: static;
  }
  .site-header .wrap {
    gap: 8px 16px;
    padding-top: 10px;
    padding-bottom: 10px;
  }
  .nav {
    gap: 8px 16px;
  }
}

/* Buttons */
.btn {
  display: inline-block;
  padding: 12px 22px;
  border-radius: 999px;
  font-weight: 700;
  text-decoration: none;
  border: 1px solid transparent;
  background: linear-gradient(135deg, var(--btn-from), var(--btn-to));
  color: #fff;
  box-shadow: 0 10px 30px -10px rgba(99, 70, 229, 0.8);
  transition:
    transform 0.15s ease,
    box-shadow 0.15s ease;
}
.btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 16px 36px -12px rgba(99, 70, 229, 0.9);
}
.btn.secondary {
  background: transparent;
  color: var(--accent);
  border-color: currentColor;
  box-shadow: none;
}
.on-dark .btn.secondary,
.nav .btn.secondary {
  color: var(--hero-text);
  border-color: var(--glass-line);
  background: var(--glass);
}
.nav .btn {
  color: #fff;
  padding: 8px 18px;
}
.actions {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  margin-top: 28px;
}

/* Sections */
section {
  padding: 88px 0;
}
section.alt {
  background: var(--surface-2);
}
.lead {
  font-size: 1.2rem;
  color: var(--muted);
  max-width: 40em;
}
.eyebrow {
  display: inline-block;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  font-size: 0.78rem;
  font-weight: 800;
  color: var(--accent);
  background: var(--accent-soft);
  border-radius: 999px;
  padding: 4px 12px;
  margin-bottom: 16px;
}
.center {
  text-align: center;
}
.center .lead {
  margin-left: auto;
  margin-right: auto;
}

/* Dark hero */
.hero {
  position: relative;
  overflow: hidden;
  background:
    radial-gradient(60% 70% at 15% 10%, rgba(79, 70, 229, 0.55), transparent 70%),
    radial-gradient(45% 60% at 90% 20%, rgba(217, 70, 239, 0.4), transparent 70%),
    radial-gradient(50% 60% at 60% 110%, rgba(6, 182, 212, 0.4), transparent 70%), var(--hero-bg);
  color: var(--hero-text);
  padding: 96px 0 104px;
}
.hero::after {
  content: "";
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(255, 255, 255, 0.05) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.05) 1px, transparent 1px);
  background-size: 44px 44px;
  mask-image: radial-gradient(70% 70% at 50% 40%, #000, transparent);
  -webkit-mask-image: radial-gradient(70% 70% at 50% 40%, #000, transparent);
  pointer-events: none;
}
.hero .wrap {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: 1.05fr 1fr;
  gap: 56px;
  align-items: center;
}
.hero.compact {
  padding: 80px 0;
}
.hero.compact .wrap {
  display: block;
}
.hero .lead {
  color: var(--hero-muted);
}
.hero .eyebrow {
  background: var(--glass);
  border: 1px solid var(--glass-line);
  color: #c7d2fe;
}
@media (max-width: 880px) {
  .hero .wrap {
    grid-template-columns: 1fr;
  }
}

/* Translation demo card */
.demo {
  background: rgba(20, 22, 50, 0.72);
  border: 1px solid var(--glass-line);
  border-radius: 22px;
  padding: 20px;
  box-shadow: 0 40px 80px -30px rgba(0, 0, 0, 0.8);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  animation: float 7s ease-in-out infinite;
}
.demo-bar {
  display: flex;
  gap: 7px;
  margin-bottom: 16px;
}
.demo-bar i {
  width: 11px;
  height: 11px;
  border-radius: 50%;
  background: #ff5f57;
}
.demo-bar i:nth-child(2) {
  background: #febc2e;
}
.demo-bar i:nth-child(3) {
  background: #28c840;
}
.demo-row {
  display: grid;
  grid-template-columns: 44px 1fr auto;
  gap: 12px;
  align-items: center;
  padding: 12px 14px;
  border-radius: 12px;
  background: var(--glass);
  border: 1px solid var(--glass-line);
  margin-bottom: 10px;
  font-size: 0.95rem;
  opacity: 0;
  animation: rise 0.6s ease forwards;
}
.demo-row.source {
  background: rgba(79, 70, 229, 0.22);
  border-color: rgba(139, 133, 255, 0.5);
}
.demo-row:nth-child(3) {
  animation-delay: 0.5s;
}
.demo-row:nth-child(4) {
  animation-delay: 0.9s;
}
.demo-row:nth-child(5) {
  animation-delay: 1.3s;
}
.demo-row:nth-child(6) {
  animation-delay: 1.7s;
}
.lang {
  font:
    700 0.75rem / 1 ui-monospace,
    Consolas,
    monospace;
  text-align: center;
  padding: 6px 0;
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.1);
  color: #e0e7ff;
}
.demo-row .ph {
  color: #67e8f9;
  font-family: ui-monospace, Consolas, monospace;
}
.badge {
  font-size: 0.75rem;
  font-weight: 700;
  color: #6ee7b7;
  background: rgba(16, 185, 129, 0.15);
  border: 1px solid rgba(16, 185, 129, 0.4);
  border-radius: 999px;
  padding: 3px 10px;
  white-space: nowrap;
}
@keyframes rise {
  from {
    opacity: 0;
    transform: translateY(10px);
  }
  to {
    opacity: 1;
    transform: none;
  }
}
@keyframes float {
  0%,
  100% {
    transform: translateY(0);
  }
  50% {
    transform: translateY(-10px);
  }
}

/* Stats */
.stats {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 16px;
  margin-top: -52px;
  position: relative;
  z-index: 2;
}
.stat {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 22px 24px;
  box-shadow: var(--shadow);
}
.stat strong {
  display: block;
  font-size: 2.2rem;
  line-height: 1.1;
  font-weight: 800;
  background: linear-gradient(90deg, var(--accent), var(--accent-3));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}
.stat span {
  color: var(--muted);
}
section.after-stats {
  padding-top: 72px;
}

/* Cards */
.grid {
  display: grid;
  gap: 20px;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  margin-top: 40px;
}
.card {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 28px;
  transition:
    transform 0.2s ease,
    box-shadow 0.2s ease,
    border-color 0.2s ease;
}
.card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow);
  border-color: color-mix(in srgb, var(--accent) 40%, var(--line));
}
.card p:last-child {
  margin-bottom: 0;
}
.card p {
  color: var(--muted);
}
.icon {
  width: 48px;
  height: 48px;
  border-radius: 14px;
  display: grid;
  place-items: center;
  margin-bottom: 18px;
  color: #fff;
  background: linear-gradient(135deg, var(--accent), var(--accent-3));
}
.icon.cyan {
  background: linear-gradient(135deg, #0891b2, var(--accent));
}
.icon.green {
  background: linear-gradient(135deg, #059669, #0891b2);
}
.icon svg {
  width: 24px;
  height: 24px;
}

/* Steps */
.steps {
  counter-reset: step;
  list-style: none;
  padding: 0;
  margin: 40px 0 0;
  display: grid;
  gap: 20px;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
}
.steps li {
  counter-increment: step;
  position: relative;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 28px;
}
.steps li::before {
  content: counter(step);
  display: inline-grid;
  place-items: center;
  width: 40px;
  height: 40px;
  border-radius: 12px;
  background: linear-gradient(135deg, var(--btn-from), var(--btn-to));
  color: #fff;
  font-weight: 800;
  margin-bottom: 16px;
}
.steps p {
  color: var(--muted);
  margin: 0;
}

/* Chips */
.chips {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  padding: 0;
  margin: 24px 0 0;
  list-style: none;
}
.chips li {
  border: 1px solid var(--line);
  background: var(--surface);
  border-radius: 12px;
  padding: 10px 16px;
  font-weight: 600;
  font-family: ui-monospace, Consolas, monospace;
  font-size: 0.92rem;
}

.split {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 56px;
  align-items: center;
}
@media (max-width: 880px) {
  .split {
    grid-template-columns: 1fr;
  }
}

.checks {
  list-style: none;
  padding: 0;
  margin: 0;
}
.checks li {
  padding-left: 32px;
  position: relative;
  margin-bottom: 12px;
}
.checks li::before {
  content: "✓";
  position: absolute;
  left: 0;
  top: 1px;
  width: 22px;
  height: 22px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  font-size: 0.75rem;
  color: #fff;
  background: var(--ok);
  font-weight: 800;
}

/* Code and folder panels */
.panel {
  background: #0f1129;
  color: #dfe3ff;
  border: 1px solid #262a52;
  border-radius: var(--radius);
  padding: 22px 24px;
  margin: 0;
  overflow-x: auto;
  font-size: 0.92rem;
  line-height: 1.7;
  box-shadow: var(--shadow);
}
.panel .c {
  color: #7b80b5;
}
.panel .k {
  color: #67e8f9;
}
.panel .s {
  color: #f0abfc;
}
.panel .g {
  color: #6ee7b7;
}

/* Pricing */
.plans {
  display: grid;
  gap: 20px;
  /* Four plans: one row on wide screens, two by two on tablets, stacked on phones. */
  grid-template-columns: repeat(4, minmax(0, 1fr));
  margin-top: 8px;
  align-items: stretch;
}
@media (max-width: 1040px) {
  .plans {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}
@media (max-width: 600px) {
  .plans {
    grid-template-columns: 1fr;
  }
}
.plans-note {
  color: var(--muted);
  font-size: 0.9rem;
  margin-top: 20px;
  text-align: center;
}
.plan {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 32px;
  display: flex;
  flex-direction: column;
  position: relative;
  box-shadow: var(--shadow);
}
.plan.featured {
  border: 2px solid transparent;
  background:
    linear-gradient(var(--surface), var(--surface)) padding-box,
    linear-gradient(135deg, var(--accent-2), var(--accent), var(--accent-3)) border-box;
}
.plan .tag {
  position: absolute;
  top: -13px;
  left: 32px;
  font-size: 0.75rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: #fff;
  background: linear-gradient(90deg, var(--btn-from), var(--btn-to));
  border-radius: 999px;
  padding: 4px 12px;
}
.plan .price {
  font-size: 2.2rem;
  font-weight: 800;
  margin: 4px 0 4px;
}
.plan .price .per {
  font-size: 1rem;
  font-weight: 600;
  color: var(--muted);
}
.plan .price-alt {
  color: var(--muted);
  font-size: 0.95rem;
  font-weight: 600;
  margin: 0 0 8px;
}
.plan .note {
  color: var(--muted);
  margin-bottom: 20px;
}
.plan .checks {
  margin-bottom: 28px;
  flex: 1;
}
.plan .btn {
  text-align: center;
}
.pricing-wrap {
  margin-top: -64px;
  position: relative;
  z-index: 2;
}
/* Credit packs (ADR-096): two cards under the plans. */
.packs {
  margin-top: 72px;
}
.plans.packs-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  max-width: 760px;
  margin: 24px auto 0;
}
@media (max-width: 600px) {
  .plans.packs-grid {
    grid-template-columns: 1fr;
  }
}

details {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 18px 22px;
  margin-bottom: 12px;
}
summary {
  cursor: pointer;
  font-weight: 700;
}
.faq p {
  margin: 10px 0 0;
  color: var(--muted);
}
.faq {
  max-width: 780px;
  margin: 32px auto 0;
}

/* CTA banner */
.cta-band {
  border-radius: 28px;
  padding: 64px 32px;
  text-align: center;
  color: var(--hero-text);
  background:
    radial-gradient(60% 120% at 0% 0%, rgba(6, 182, 212, 0.55), transparent 60%),
    radial-gradient(60% 120% at 100% 100%, rgba(217, 70, 239, 0.55), transparent 60%),
    linear-gradient(135deg, #312e81, #4f46e5);
  box-shadow: var(--shadow);
}
.cta-band .lead {
  color: #e0e7ff;
  margin: 0 auto;
}
.cta-band .actions {
  justify-content: center;
}
.cta-band .btn {
  background: #fff;
  color: #312e81;
}
.cta-band .btn.secondary {
  background: transparent;
  color: #fff;
  border-color: rgba(255, 255, 255, 0.5);
}

/* Footer */
.site-footer {
  border-top: 1px solid var(--line);
  padding: 36px 0;
  color: var(--muted);
  font-size: 0.95rem;
}
.footer-row {
  display: flex;
  gap: 16px;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: center;
}
.site-footer nav {
  display: flex;
  gap: 18px;
  flex-wrap: wrap;
}
.site-footer a {
  color: var(--muted);
  text-decoration: none;
}
.site-footer a:hover {
  color: var(--text);
}
.site-footer .brand {
  color: var(--text);
  font-size: 1rem;
}
.site-footer .brand img {
  width: 24px;
  height: 24px;
}

@media (prefers-reduced-motion: reduce) {
  .demo,
  .demo-row {
    animation: none;
  }
  .demo-row {
    opacity: 1;
  }
  .btn,
  .card {
    transition: none;
  }
  html {
    scroll-behavior: auto;
  }
}

/* Legal pages (terms, privacy, imprint) */
.legal {
  max-width: 760px;
  margin: 0 auto;
  padding: 48px 16px 72px;
  line-height: 1.65;
}
.legal h2 {
  margin-top: 2.2em;
  font-size: 1.35rem;
}
.legal h3 {
  margin-top: 1.6em;
  font-size: 1.05rem;
}
.legal .updated,
.legal .notice {
  color: var(--muted);
}
.legal .notice {
  padding: 12px 16px;
  border-left: 4px solid var(--accent);
  background: var(--surface-2);
  border-radius: 6px;
}
.legal table {
  width: 100%;
  border-collapse: collapse;
  margin: 1em 0;
  font-size: 0.95rem;
}
.legal th,
.legal td {
  text-align: start;
  vertical-align: top;
  padding: 8px 10px;
  border-bottom: 1px solid var(--line);
}
.legal .table-scroll {
  overflow-x: auto;
}
.legal .todo {
  background: #fff3a3;
  color: #14152b;
  padding: 0 4px;
  border-radius: 3px;
}

/* User guide (guide.html) */
.guide {
  display: grid;
  gap: 48px;
  grid-template-columns: 240px minmax(0, 1fr);
  align-items: start;
}
.toc {
  position: sticky;
  top: 96px;
  font-size: 0.95rem;
}
.toc h2 {
  font-size: 0.78rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--muted);
}
.toc ol {
  list-style: none;
  padding: 0;
  margin: 0;
}
.toc li {
  margin: 0 0 6px;
}
.toc a {
  color: var(--text);
  text-decoration: none;
}
.toc a:hover {
  color: var(--accent);
}
.guide-body {
  max-width: 760px;
}
.guide-body section {
  padding: 0 0 48px;
}
.guide-body h2 {
  font-size: 1.7rem;
}
.guide-body h3 {
  margin-top: 1.4em;
}
.guide-body table {
  width: 100%;
  border-collapse: collapse;
  margin: 16px 0 20px;
  font-size: 0.95rem;
  display: block;
  overflow-x: auto;
}
.guide-body th,
.guide-body td {
  text-align: start;
  vertical-align: top;
  padding: 10px 12px;
  border-bottom: 1px solid var(--line);
}
.guide-body th {
  background: var(--surface-2);
}
.guide-body code {
  font-family: ui-monospace, "Cascadia Code", Consolas, Menlo, monospace;
  font-size: 0.9em;
  /* Long URLs and paths wrap instead of widening the page on phones. */
  overflow-wrap: anywhere;
}
.guide-body :not(pre) > code {
  background: var(--surface-2);
  border: 1px solid var(--line);
  border-radius: 6px;
  padding: 1px 5px;
}
.guide-body pre.panel {
  margin: 16px 0 20px;
}
.guide-body pre code {
  overflow-wrap: normal;
}
.guide .notice {
  background: var(--accent-soft);
  border: 1px solid var(--line);
  border-left: 4px solid var(--accent);
  border-radius: 12px;
  padding: 16px 20px;
  margin: 0 0 32px;
}
.guide .notice p {
  margin: 0;
}
.guide .notice.warn {
  border-left-color: #f59e0b;
}
@media (max-width: 860px) {
  .guide {
    grid-template-columns: minmax(0, 1fr);
    gap: 24px;
  }
  .toc {
    position: static;
  }
}

/* Error page (404.html) */
.not-found {
  min-height: 60vh;
  display: grid;
  align-content: center;
}
.not-found .actions {
  justify-content: center;
}

/* Language switcher: a <details> in the header whose list website mode fills in
   (the data-semling-languages placeholder); hidden while the placeholder is empty. */
.languages {
  position: relative;
  background: none;
  border: 0;
  border-radius: 0;
  padding: 0;
  margin: 0;
}
.languages:has(.semling-languages:empty) {
  display: none;
}
.languages summary {
  display: flex;
  align-items: center;
  gap: 6px;
  list-style: none;
  font-weight: 500;
  color: var(--hero-muted);
}
.languages summary::-webkit-details-marker {
  display: none;
}
.languages summary:hover,
.languages[open] summary {
  color: var(--hero-text);
}
.languages summary svg {
  width: 18px;
  height: 18px;
}

/* Light/dark switch: build-site.mjs adds it to the main menu, hidden until assets/theme.js runs.
   The icon shows the theme a click switches to. */
.theme-toggle {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  padding: 0;
  border: 1px solid var(--glass-line);
  border-radius: 999px;
  background: var(--glass);
  color: var(--hero-muted);
  cursor: pointer;
}
.theme-toggle:hover {
  color: var(--hero-text);
}
.theme-toggle:focus-visible {
  outline: 2px solid var(--accent-2);
  outline-offset: 2px;
}
.theme-toggle[hidden],
.theme-toggle[aria-pressed="true"] .moon,
.theme-toggle:not([aria-pressed="true"]) .sun {
  display: none;
}
.theme-toggle svg {
  width: 18px;
  height: 18px;
}

/* Signed in to the dashboard (assets/signed-in.js sets data-signed-in): the buttons that lead to it
   show their "Dashboard" text, which build-site.mjs adds hidden next to the default one. */
:root[data-signed-in] .when-signed-out {
  display: none;
}
:root[data-signed-in] .when-signed-in {
  display: inline;
}
.semling-languages ul {
  list-style: none;
  margin: 0;
  padding: 0;
}
/* A page without the placeholder gets the switcher as a <nav> before </body>. */
body > nav.semling-languages {
  max-width: var(--max);
  margin: 0 auto;
  padding: 0 16px 36px;
}
body > nav.semling-languages ul {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 18px;
}
body > nav.semling-languages a {
  color: var(--muted);
  text-decoration: none;
}
body > nav.semling-languages a[aria-current="page"] {
  color: var(--text);
  font-weight: 700;
}
.languages .semling-languages {
  position: absolute;
  inset-inline-end: 0;
  top: calc(100% + 12px);
  z-index: 20;
  min-width: 190px;
  max-height: 70vh;
  overflow-y: auto;
  padding: 6px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 12px;
  box-shadow: var(--shadow);
}
.languages .semling-languages a {
  display: block;
  padding: 6px 12px;
  border-radius: 8px;
  color: var(--text);
  text-decoration: none;
}
.languages .semling-languages a:hover {
  background: var(--surface-2);
  color: var(--text);
}
.languages .semling-languages a[aria-current="page"] {
  color: var(--accent);
  font-weight: 700;
}
