/* hstu.de design system. No inline styles anywhere: the CSP only allows this file. */

:root {
  --bg: #f6f5f1;
  --surface: #ffffff;
  --surface-2: #efede6;
  --ink: #111318;
  --muted: #5d636e;
  --line: #e0ddd3;
  --accent: #c6f432;
  --accent-strong: #a8d60f;
  --accent-ink: #111318;
  --primary: #111318;
  --primary-ink: #f6f5f1;
  --link: #1d4ed8;
  --ok: #17794a;
  --ok-bg: #e2f5ea;
  --warn: #8a5a00;
  --warn-bg: #fdf0cf;
  --error: #b3202f;
  --error-bg: #fbe4e6;
  --info: #1d4ed8;
  --info-bg: #e4ecfd;
  --night: #0d0f12;
  --night-2: #171a20;
  --night-line: #2a2e37;
  --night-ink: #f2f3ee;
  --night-muted: #a2a8b3;
  --radius: 12px;
  --radius-sm: 8px;
  --shadow: 0 1px 2px rgb(17 19 24 / 6%), 0 8px 24px rgb(17 19 24 / 6%);
  --font: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --mono: ui-monospace, "Cascadia Code", "SF Mono", Menlo, Consolas, monospace;
  color-scheme: light dark;
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #0d0f12;
    --surface: #15181d;
    --surface-2: #1c2027;
    --ink: #f2f3ee;
    --muted: #a2a8b3;
    --line: #2a2e37;
    --primary: #c6f432;
    --primary-ink: #111318;
    --link: #9dbbff;
    --ok: #6fdc9f;
    --ok-bg: #12301f;
    --warn: #f2c65a;
    --warn-bg: #33270a;
    --error: #ff8a94;
    --error-bg: #3a1218;
    --info: #9dbbff;
    --info-bg: #141f3d;
    --shadow: 0 1px 2px rgb(0 0 0 / 40%), 0 8px 24px rgb(0 0 0 / 30%);
  }
}

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

html {
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--font);
  font-size: 16px;
  line-height: 1.55;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

main {
  flex: 1;
}

h1,
h2,
h3 {
  line-height: 1.15;
  letter-spacing: -0.02em;
  margin: 0 0 0.5em;
  text-wrap: balance;
}

h1 {
  font-size: clamp(1.6rem, 1.2rem + 1.6vw, 2.1rem);
}

h2 {
  font-size: 1.25rem;
}

h3 {
  font-size: 1.05rem;
}

p {
  margin: 0 0 1em;
}

a {
  color: var(--link);
  text-underline-offset: 2px;
}

a:hover {
  text-decoration-thickness: 2px;
}

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

img,
svg {
  max-width: 100%;
}

code,
.mono {
  font-family: var(--mono);
  font-size: 0.92em;
}

code {
  background: var(--surface-2);
  padding: 0.1em 0.35em;
  border-radius: 4px;
}

hr {
  border: 0;
  border-top: 1px solid var(--line);
  margin: 1.5rem 0;
}

.muted {
  color: var(--muted);
}

.small {
  font-size: 0.875rem;
}

.center {
  text-align: center;
}

.nowrap {
  white-space: nowrap;
}

.skip-link {
  position: absolute;
  left: -999px;
  top: 0;
  background: var(--accent);
  color: var(--accent-ink);
  padding: 0.5rem 1rem;
  z-index: 100;
}

.skip-link:focus {
  left: 0.5rem;
  top: 0.5rem;
}

.icon {
  flex: none;
  vertical-align: -0.2em;
}

.container {
  width: min(1120px, 100% - 2.5rem);
  margin-inline: auto;
}

.narrow {
  width: min(720px, 100% - 2.5rem);
  margin-inline: auto;
}

.stack > * + * {
  margin-top: 1rem;
}

.row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  align-items: center;
}

.spread {
  justify-content: space-between;
}

.grid-2,
.grid-3 {
  display: grid;
  gap: 1.25rem;
}

@media (min-width: 760px) {
  .grid-2 {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .grid-3 {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

/* --- Header ------------------------------------------------------------- */

.site-header {
  background: var(--night);
  color: var(--night-ink);
  border-bottom: 1px solid var(--night-line);
  position: sticky;
  top: 0;
  z-index: 20;
}

.header-row {
  display: flex;
  align-items: center;
  gap: 1.25rem;
  min-height: 60px;
}

.app-header-row {
  padding-inline: 1.25rem;
}

.logo {
  display: inline-flex;
  align-items: center;
  gap: 0.55rem;
  color: inherit;
  text-decoration: none;
  font-weight: 800;
  font-size: 1.2rem;
  letter-spacing: -0.03em;
}

.logo-mark {
  display: grid;
  place-items: center;
  width: 30px;
  height: 30px;
  border-radius: 8px;
  background: var(--accent);
  color: var(--accent-ink);
  font-weight: 900;
  font-size: 1.05rem;
}

.logo-dot {
  color: var(--accent);
}

.main-nav {
  display: flex;
  gap: 0.25rem;
  margin-left: 0.75rem;
  overflow-x: auto;
}

.main-nav a {
  color: var(--night-muted);
  text-decoration: none;
  padding: 0.4rem 0.7rem;
  border-radius: 999px;
  font-weight: 500;
  white-space: nowrap;
}

.main-nav a:hover,
.main-nav a[aria-current="page"] {
  color: var(--night-ink);
  background: var(--night-2);
}

.header-actions {
  margin-left: auto;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.site-header .btn-ghost {
  color: var(--night-ink);
  border-color: transparent;
}

.site-header .btn-ghost:hover {
  background: var(--night-2);
}

.site-header .btn-primary {
  background: var(--accent);
  color: var(--accent-ink);
  border-color: var(--accent);
}

.credit-pill {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.3rem 0.75rem;
  border-radius: 999px;
  border: 1px solid var(--night-line);
  color: var(--accent);
  text-decoration: none;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
}

.credit-pill:hover {
  border-color: var(--accent);
}

@media (max-width: 720px) {
  .main-nav {
    display: none;
  }

  .hide-mobile {
    display: none;
  }
}

/* --- Buttons ------------------------------------------------------------ */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.45rem;
  padding: 0.65rem 1.1rem;
  border-radius: 10px;
  border: 1px solid var(--line);
  background: var(--surface);
  color: var(--ink);
  font: inherit;
  font-weight: 600;
  line-height: 1.2;
  text-decoration: none;
  cursor: pointer;
  transition: transform 0.05s ease, background 0.15s ease, border-color 0.15s ease;
}

.btn:hover {
  border-color: var(--ink);
}

.btn:active {
  transform: translateY(1px);
}

.btn[disabled],
.btn[aria-disabled="true"] {
  opacity: 0.55;
  cursor: not-allowed;
}

.btn-primary {
  background: var(--primary);
  color: var(--primary-ink);
  border-color: var(--primary);
}

.btn-primary:hover {
  filter: brightness(1.12);
}

.btn-accent {
  background: var(--accent);
  color: var(--accent-ink);
  border-color: var(--accent);
}

.btn-accent:hover {
  background: var(--accent-strong);
  border-color: var(--accent-strong);
}

.btn-ghost {
  background: transparent;
}

.btn-danger {
  color: var(--error);
  border-color: color-mix(in srgb, var(--error) 40%, transparent);
}

.btn-danger:hover {
  background: var(--error-bg);
  border-color: var(--error);
}

.btn-small {
  padding: 0.4rem 0.75rem;
  font-size: 0.9rem;
  border-radius: 8px;
}

.btn-large {
  padding: 0.85rem 1.5rem;
  font-size: 1.05rem;
}

.btn-block {
  width: 100%;
}

.link-button {
  background: none;
  border: 0;
  padding: 0;
  font: inherit;
  color: var(--link);
  text-decoration: underline;
  cursor: pointer;
}

.inline-form {
  display: inline;
  margin: 0;
}

/* --- Forms -------------------------------------------------------------- */

.field label,
.check label {
  display: block;
  font-weight: 600;
  margin-bottom: 0.35rem;
}

.req {
  color: var(--error);
}

input[type="text"],
input[type="email"],
input[type="password"],
input[type="url"],
input[type="number"],
input[type="search"],
input[type="tel"],
input[type="date"],
input[type="file"],
select,
textarea {
  width: 100%;
  padding: 0.65rem 0.8rem;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: var(--surface);
  color: var(--ink);
  font: inherit;
}

textarea {
  resize: vertical;
  min-height: 6rem;
}

textarea.mono,
input.mono {
  font-family: var(--mono);
  font-size: 0.9rem;
}

input:focus,
select:focus,
textarea:focus {
  outline: 3px solid color-mix(in srgb, var(--accent-strong) 60%, transparent);
  outline-offset: 0;
  border-color: var(--ink);
}

.has-error input,
.has-error select,
.has-error textarea {
  border-color: var(--error);
}

.field-error {
  color: var(--error);
  font-size: 0.9rem;
  margin: 0.3rem 0 0;
}

.field-hint {
  color: var(--muted);
  font-size: 0.875rem;
  margin: 0.3rem 0 0;
}

.check label {
  display: flex;
  gap: 0.6rem;
  align-items: flex-start;
  font-weight: 400;
}

.check input {
  margin-top: 0.3rem;
  width: 1.05rem;
  height: 1.05rem;
  accent-color: var(--ink);
}

.form-row {
  display: grid;
  gap: 1rem;
}

@media (min-width: 640px) {
  .form-row {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .form-row.thirds {
    grid-template-columns: 1fr 2fr;
  }
}

.form-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  align-items: center;
  margin-top: 1.25rem;
}

.input-group {
  display: flex;
  gap: 0.5rem;
}

.input-group > input {
  flex: 1;
  min-width: 0;
}

@media (max-width: 520px) {
  .input-group {
    flex-direction: column;
  }
}

.copy {
  display: flex;
  gap: 0.5rem;
}

.copy input {
  flex: 1;
  min-width: 0;
  background: var(--surface-2);
}

/* --- Cards, tables, badges --------------------------------------------- */

.card {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 1.25rem;
  box-shadow: var(--shadow);
}

/* Vertical rhythm: blocks in the app area and stacked cards keep one gap ... */
.app-main > * + *,
.card + .card {
  margin-top: 1.25rem;
}

/* ... but cards laid out side by side in a grid must not be pushed down. */
.grid-2 > .card,
.grid-3 > .card,
.grid-2 > .card + .card,
.grid-3 > .card + .card {
  margin-top: 0;
}

.card-head {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 1rem;
  margin-bottom: 0.75rem;
}

.card-head h2,
.card-head h3 {
  margin: 0;
}

.table-wrap {
  overflow-x: auto;
  margin-inline: -0.25rem;
}

table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.95rem;
}

th,
td {
  text-align: left;
  padding: 0.6rem 0.5rem;
  border-bottom: 1px solid var(--line);
  vertical-align: middle;
}

th {
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--muted);
  font-weight: 600;
  white-space: nowrap;
}

tbody tr:last-child td {
  border-bottom: 0;
}

td.num,
th.num {
  text-align: right;
  font-variant-numeric: tabular-nums;
}

td.actions {
  text-align: right;
  white-space: nowrap;
}

.truncate {
  max-width: 22rem;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.badge {
  display: inline-block;
  padding: 0.12rem 0.55rem;
  border-radius: 999px;
  font-size: 0.78rem;
  font-weight: 700;
  white-space: nowrap;
}

.badge-ok {
  background: var(--ok-bg);
  color: var(--ok);
}

.badge-warn {
  background: var(--warn-bg);
  color: var(--warn);
}

.badge-error {
  background: var(--error-bg);
  color: var(--error);
}

.badge-info {
  background: var(--info-bg);
  color: var(--info);
}

.badge-muted {
  background: var(--surface-2);
  color: var(--muted);
}

.alert,
.flash {
  padding: 0.8rem 1rem;
  border-radius: 10px;
  border: 1px solid transparent;
  margin-bottom: 1rem;
  overflow-wrap: anywhere;
}

.alert-ok,
.flash-ok {
  background: var(--ok-bg);
  color: var(--ok);
  border-color: color-mix(in srgb, var(--ok) 30%, transparent);
}

.alert-error,
.flash-error {
  background: var(--error-bg);
  color: var(--error);
  border-color: color-mix(in srgb, var(--error) 30%, transparent);
}

.alert-info,
.flash-info,
.alert-muted {
  background: var(--info-bg);
  color: var(--info);
  border-color: color-mix(in srgb, var(--info) 30%, transparent);
}

.alert-warn {
  background: var(--warn-bg);
  color: var(--warn);
  border-color: color-mix(in srgb, var(--warn) 30%, transparent);
}

.flash a,
.alert a,
.flash .link-button {
  color: inherit;
  font-weight: 600;
}

.empty {
  text-align: center;
  padding: 2rem 1rem;
  color: var(--muted);
}

.empty h3 {
  color: var(--ink);
}

.stats {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(170px, 1fr));
  gap: 1rem;
  margin-bottom: 1.25rem;
}

.stat {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 1rem 1.1rem;
}

.stat-label {
  color: var(--muted);
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  font-weight: 600;
}

.stat-value {
  font-size: 1.7rem;
  font-weight: 800;
  letter-spacing: -0.02em;
  font-variant-numeric: tabular-nums;
}

.stat-sub {
  color: var(--muted);
  font-size: 0.85rem;
}

.dl {
  display: grid;
  grid-template-columns: minmax(8rem, max-content) 1fr;
  gap: 0.45rem 1.25rem;
  margin: 0;
}

.dl dt {
  color: var(--muted);
}

.dl dd {
  margin: 0;
  overflow-wrap: anywhere;
}

.pager {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-top: 1rem;
}

.pager-page {
  color: var(--muted);
  font-size: 0.9rem;
}

.chart {
  width: 100%;
  height: 150px;
  display: block;
}

.chart .bar {
  fill: var(--ink);
}

.chart .chart-axis {
  stroke: var(--line);
  stroke-width: 1;
}

.chart .chart-label {
  fill: var(--muted);
  font-size: 11px;
}

@media (prefers-color-scheme: dark) {
  .chart .bar {
    fill: var(--accent);
  }
}

.breakdown {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 0.45rem;
}

.breakdown li {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 90px 3rem;
  gap: 0.75rem;
  align-items: center;
  font-size: 0.95rem;
}

.breakdown-label {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.breakdown-value {
  text-align: right;
  font-variant-numeric: tabular-nums;
}

meter {
  width: 100%;
  height: 0.5rem;
}

.tabs {
  display: flex;
  gap: 0.25rem;
  border-bottom: 1px solid var(--line);
  margin-bottom: 1.25rem;
  overflow-x: auto;
}

.tabs a {
  padding: 0.6rem 0.9rem;
  text-decoration: none;
  color: var(--muted);
  font-weight: 600;
  border-bottom: 2px solid transparent;
  white-space: nowrap;
}

.tabs a[aria-current="page"] {
  color: var(--ink);
  border-bottom-color: var(--ink);
}

.steps {
  counter-reset: step;
  list-style: none;
  padding: 0;
  margin: 0;
  display: grid;
  gap: 0.75rem;
}

.steps li {
  counter-increment: step;
  display: grid;
  grid-template-columns: 2rem 1fr;
  gap: 0.75rem;
}

.steps li::before {
  content: counter(step);
  display: grid;
  place-items: center;
  width: 2rem;
  height: 2rem;
  border-radius: 50%;
  background: var(--accent);
  color: var(--accent-ink);
  font-weight: 800;
}

.price {
  font-weight: 800;
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}

.price small {
  font-weight: 500;
  color: var(--muted);
}

/* --- App shell ---------------------------------------------------------- */

.app-shell {
  display: grid;
  grid-template-columns: 220px minmax(0, 1fr);
  flex: 1;
  width: 100%;
}

.side-nav {
  display: flex;
  flex-direction: column;
  gap: 0.15rem;
  padding: 1.25rem 0.75rem;
  border-right: 1px solid var(--line);
  background: var(--surface);
  position: sticky;
  top: 61px;
  align-self: start;
  height: calc(100vh - 61px);
  overflow-y: auto;
}

.side-nav a {
  display: flex;
  align-items: center;
  gap: 0.65rem;
  padding: 0.55rem 0.75rem;
  border-radius: 9px;
  color: var(--muted);
  text-decoration: none;
  font-weight: 600;
}

.side-nav a:hover {
  background: var(--surface-2);
  color: var(--ink);
}

.side-nav a[aria-current="page"] {
  background: var(--ink);
  color: var(--bg);
}

@media (prefers-color-scheme: dark) {
  .side-nav a[aria-current="page"] {
    background: var(--accent);
    color: var(--accent-ink);
  }
}

.app-main {
  padding: 1.75rem clamp(1rem, 3vw, 2.5rem) 3rem;
  max-width: 1180px;
  width: 100%;
}

.page-head {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: flex-start;
  gap: 1rem;
  margin-bottom: 1.25rem;
}

.page-head h1 {
  margin-bottom: 0.2rem;
}

.page-head p {
  margin: 0;
}

.page-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.quick-actions {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(210px, 1fr));
  gap: 1rem;
}

.quick {
  display: grid;
  gap: 0.2rem;
  padding: 1rem 1.1rem;
  border-radius: var(--radius);
  border: 1px solid var(--line);
  background: var(--surface);
  color: var(--ink);
  text-decoration: none;
}

.quick:hover {
  border-color: var(--ink);
}

.quick span {
  color: var(--muted);
  font-size: 0.9rem;
}

.quick .icon {
  margin-bottom: 0.35rem;
}

@media (max-width: 860px) {
  .app-shell {
    grid-template-columns: minmax(0, 1fr);
  }

  .side-nav {
    flex-direction: row;
    position: static;
    height: auto;
    border-right: 0;
    border-bottom: 1px solid var(--line);
    padding: 0.5rem 0.75rem;
    overflow-x: auto;
  }

  .side-nav a {
    white-space: nowrap;
  }
}

/* --- Auth --------------------------------------------------------------- */

.layout-auth {
  background: var(--night);
}

.auth-main {
  display: grid;
  place-items: center;
  padding: 2rem 1rem;
}

.auth-card {
  width: min(430px, 100%);
  background: var(--surface);
  border-radius: 16px;
  padding: 2rem;
  box-shadow: var(--shadow);
}

.auth-logo {
  margin-bottom: 1.5rem;
}

.auth-alt {
  margin: 1.25rem 0 0;
  text-align: center;
  color: var(--muted);
}

/* --- Public pages ------------------------------------------------------- */

.hero {
  background:
    radial-gradient(900px 400px at 85% -10%, rgb(198 244 50 / 16%), transparent 60%),
    var(--night);
  color: var(--night-ink);
  padding: clamp(3rem, 7vw, 5.5rem) 0 clamp(3rem, 6vw, 4.5rem);
}

.hero h1 {
  font-size: clamp(2.3rem, 1.4rem + 4.2vw, 4.2rem);
  letter-spacing: -0.045em;
  line-height: 1.02;
  max-width: 14ch;
  margin-bottom: 1rem;
}

.hero h1 mark,
.mark {
  background: none;
  color: var(--accent);
}

.hero .lead {
  color: var(--night-muted);
  font-size: clamp(1.05rem, 0.95rem + 0.5vw, 1.3rem);
  max-width: 46ch;
}

.hero-grid {
  display: grid;
  gap: 2.5rem;
  align-items: center;
}

@media (min-width: 940px) {
  .hero-grid {
    grid-template-columns: 1.05fr 0.95fr;
  }
}

.hero-card {
  background: var(--night-2);
  border: 1px solid var(--night-line);
  border-radius: 18px;
  padding: 1.5rem;
}

.hero-card h2 {
  font-size: 1.1rem;
}

.hero-card label {
  color: var(--night-ink);
}

.hero-card input[type="text"],
.hero-card input[type="url"] {
  background: var(--night);
  border-color: var(--night-line);
  color: var(--night-ink);
}

.hero-card .field-hint,
.hero-card .muted {
  color: var(--night-muted);
}

.hero-card a {
  color: var(--accent);
}

.hero-result {
  margin-top: 1rem;
  padding: 0.9rem 1rem;
  border-radius: 12px;
  background: rgb(198 244 50 / 10%);
  border: 1px solid rgb(198 244 50 / 35%);
}

.hero-result .copy input {
  background: var(--night);
  border-color: var(--night-line);
  color: var(--accent);
  font-weight: 700;
}

.hero-points {
  list-style: none;
  padding: 0;
  margin: 1.5rem 0 0;
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem 1.25rem;
  color: var(--night-muted);
}

.hero-points li {
  display: flex;
  align-items: center;
  gap: 0.4rem;
}

.hero-points .icon {
  color: var(--accent);
}

.section {
  padding: clamp(2.5rem, 6vw, 4.5rem) 0;
}

.section-alt {
  background: var(--surface);
  border-block: 1px solid var(--line);
}

.section-head {
  max-width: 44rem;
  margin-bottom: 2rem;
}

.section-head h2 {
  font-size: clamp(1.6rem, 1.2rem + 1.8vw, 2.4rem);
  letter-spacing: -0.035em;
}

.eyebrow {
  display: inline-block;
  font-size: 0.8rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--muted);
  margin-bottom: 0.6rem;
}

.lead {
  font-size: 1.15rem;
  color: var(--muted);
}

.feature {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 16px;
  padding: 1.5rem;
}

.section-alt .feature {
  background: var(--bg);
}

.feature .icon-wrap {
  display: grid;
  place-items: center;
  width: 44px;
  height: 44px;
  border-radius: 12px;
  background: var(--accent);
  color: var(--accent-ink);
  margin-bottom: 1rem;
}

.feature ul,
.plan ul {
  padding-left: 1.1rem;
  margin: 0.75rem 0 0;
  color: var(--muted);
}

.feature li + li,
.plan li + li {
  margin-top: 0.3rem;
}

.plan {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 16px;
  padding: 1.5rem;
  display: flex;
  flex-direction: column;
}

.plan-price {
  font-size: 2rem;
  font-weight: 800;
  letter-spacing: -0.03em;
  margin: 0.25rem 0;
}

.plan-price small {
  font-size: 0.95rem;
  font-weight: 500;
  color: var(--muted);
}

.plan .btn {
  margin-top: auto;
}

.plan ul {
  margin-bottom: 1.25rem;
}

.cta-band {
  background: var(--night);
  color: var(--night-ink);
  border-radius: 20px;
  padding: clamp(1.75rem, 4vw, 3rem);
  display: flex;
  flex-wrap: wrap;
  gap: 1.5rem;
  align-items: center;
  justify-content: space-between;
}

.cta-band h2 {
  font-size: clamp(1.4rem, 1.1rem + 1.4vw, 2rem);
  margin: 0;
  max-width: 22ch;
}

.faq details {
  border-bottom: 1px solid var(--line);
  padding: 0.9rem 0;
}

.faq summary {
  cursor: pointer;
  font-weight: 700;
}

.faq details p {
  margin: 0.6rem 0 0;
  color: var(--muted);
}

.prose {
  padding-block: 2.5rem 4rem;
}

.prose h2 {
  margin-top: 2rem;
}

.prose h3 {
  margin-top: 1.5rem;
}

.prose ul {
  padding-left: 1.2rem;
}

.error-page {
  padding-block: 4rem;
}

.error-code {
  font-size: 4.5rem;
  font-weight: 900;
  letter-spacing: -0.05em;
  line-height: 1;
  margin: 0 0 0.5rem;
  color: var(--muted);
}

.site-footer {
  border-top: 1px solid var(--line);
  background: var(--surface);
  padding: 2rem 0;
  color: var(--muted);
  font-size: 0.95rem;
}

.site-footer .logo {
  color: var(--ink);
}

.site-footer .logo-dot {
  color: var(--accent-strong);
}

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

.footer-brand p {
  margin: 0.5rem 0 0;
}

.site-footer nav {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem 1.25rem;
}

.site-footer nav a {
  color: var(--muted);
}

/* --- Small page-specific pieces ------------------------------------------ */

.copy + .dl,
.card-head + .dl {
  margin-top: 1rem;
}

.qr {
  display: block;
  background: #fff;
  padding: 8px;
  border-radius: 10px;
  margin-bottom: 0.9rem;
}

.pack-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(190px, 1fr));
  gap: 1rem;
}

.pack {
  display: grid;
  gap: 0.5rem;
  justify-items: start;
  padding: 1rem;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--bg);
}

.pack-label {
  font-size: 0.8rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--muted);
}

.pack-credits {
  font-size: 1.6rem;
  font-weight: 800;
  letter-spacing: -0.02em;
  font-variant-numeric: tabular-nums;
}

.pack-credits small {
  font-size: 0.9rem;
  font-weight: 500;
  color: var(--muted);
}

td.pos {
  color: var(--ok);
}

td.neg {
  color: var(--error);
}

pre.code {
  background: var(--night);
  color: var(--night-ink);
  padding: 1rem;
  border-radius: 10px;
  overflow-x: auto;
  font-family: var(--mono);
  font-size: 0.85rem;
  line-height: 1.5;
  white-space: pre-wrap;
  overflow-wrap: anywhere;
  margin: 0.75rem 0;
}

pre.code code {
  background: none;
  padding: 0;
  color: inherit;
  font-size: inherit;
}

.key-form,
.api-help,
.admin-actions {
  margin-top: 1rem;
}

.api-help summary,
.mail summary {
  cursor: pointer;
}

.api-help summary {
  font-weight: 600;
}

.mail {
  border-bottom: 1px solid var(--line);
  padding: 0.6rem 0;
}

.mail:last-of-type {
  border-bottom: 0;
}

.report-ref {
  font-size: 1rem;
  overflow-wrap: anywhere;
}

.target-preview {
  padding: 0.8rem 1rem;
  background: var(--surface-2);
  border-radius: 10px;
  overflow-wrap: anywhere;
}

.prose-block > :last-child {
  margin-bottom: 0;
}

.card > .field-hint:last-child,
.card > p:last-child {
  margin-bottom: 0;
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  .btn {
    transition: none;
  }
}

.field + .dl,
.stack > .dl {
  margin-top: 1rem;
}
