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

:root {
  color-scheme: light;
  --plum: #4d216a;
  --violet: #5e2690;
  --indigo: #2b2254;
  --periwinkle: #5e51aa;
  --cobalt: #3553a6;
  --rose: #c46667;
  --night: #141325;
  --midnight: #0c0f20;
  --ink: #171221;
  --ink-soft: #5c557a;
  --paper: #f6f2fb;
  --paper-strong: #fffbff;
  --sand: #ece5f7;
  --surface-frost: #fffbff;
  --surface-line: rgba(65, 63, 124, 0.12);
  --signal: var(--rose);
  --signal-dark: #94404d;
  --teal: var(--cobalt);
  --line: rgba(65, 63, 124, 0.16);
  --shadow: 0 22px 60px rgba(23, 18, 33, 0.12);
  --bg-start: #f7f3fc;
  --bg-end: #ece4f5;
  --accent-orb: rgba(94, 38, 144, 0.16);
  --grid-line: rgba(94, 81, 170, 0.05);
  --veil-bottom: rgba(23, 18, 33, 0.04);
  --button-primary-base: #5e2690;
  --button-primary-text: #ffffff;
  --button-primary-shadow: rgba(94, 38, 144, 0.28);
  --button-secondary-bg: #ffffff;
  --button-secondary-border: #c8c6d8;
  --panel-dark-start: #2b2254;
  --panel-dark-accent: #141325;
  --panel-dark-muted: rgba(246, 242, 251, 0.76);
  --status-glow: rgba(53, 83, 166, 0.16);
  --card-bg: #ffffff;
  --card-accent: rgba(94, 81, 170, 0.16);
  --link-hover-border: rgba(94, 81, 170, 0.32);
  --link-hover-shadow: rgba(23, 18, 33, 0.08);
  --section-band-kicker: #f2c9cb;
  --band-code-bg: rgba(255, 255, 255, 0.08);
  --code-bg: rgba(43, 34, 84, 0.08);
  --login-card-accent: rgba(94, 81, 170, 0.18);
  --radius-lg: 28px;
  --radius-md: 18px;
  --radius-sm: 12px;
}

:root[data-theme='dark'] {
  color-scheme: dark;
  --ink: #f6f2fb;
  --ink-soft: #bbb3d9;
  --paper: #141325;
  --paper-strong: #f9f6ff;
  --sand: #1d1c39;
  --surface-frost: #141221;
  --surface-line: rgba(147, 128, 217, 0.12);
  --signal-dark: #e39d9f;
  --line: rgba(147, 128, 217, 0.16);
  --shadow: 0 22px 60px rgba(5, 6, 24, 0.34);
  --bg-start: #050618;
  --bg-end: #171221;
  --accent-orb: rgba(94, 81, 170, 0.18);
  --grid-line: rgba(147, 128, 217, 0.08);
  --veil-bottom: rgba(5, 6, 24, 0.24);
  --button-primary-base: #7b3db8;
  --button-primary-shadow: rgba(94, 38, 144, 0.32);
  --button-secondary-bg: #1d1c39;
  --button-secondary-border: #3d3868;
  --panel-dark-start: #171221;
  --panel-dark-accent: #2b2254;
  --panel-dark-muted: rgba(246, 242, 251, 0.72);
  --status-glow: rgba(94, 81, 170, 0.18);
  --card-bg: #1d1c39;
  --card-accent: rgba(94, 38, 144, 0.24);
  --link-hover-border: rgba(196, 102, 103, 0.34);
  --link-hover-shadow: rgba(5, 6, 24, 0.28);
  --section-band-kicker: #d8afbe;
  --band-code-bg: rgba(255, 255, 255, 0.08);
  --code-bg: rgba(255, 255, 255, 0.08);
  --login-card-accent: rgba(94, 38, 144, 0.22);
}

html {
  min-height: 100%;
}

body {
  margin: 0;
  min-height: 100vh;
  background-color: var(--bg-start);
  background-image:
    linear-gradient(var(--grid-line) 1px, transparent 1px),
    linear-gradient(90deg, var(--grid-line) 1px, transparent 1px),
    radial-gradient(circle at 84% 14%, var(--accent-orb), transparent 24%),
    linear-gradient(160deg, var(--bg-start) 0%, var(--bg-end) 100%);
  background-size: 34px 34px, 34px 34px, cover, cover;
  background-attachment: fixed;
  color: var(--ink);
  font-family: "Avenir Next", "Segoe UI", sans-serif;
}

.page-shell {
  position: relative;
  z-index: 1;
  width: min(1180px, calc(100% - 40px));
  margin: 0 auto;
  padding: 34px 0 80px;
}

.page-shell-tight {
  width: min(980px, calc(100% - 40px));
}

.hero,
.section,
.login-card,
.login-copy {
  animation: lift-in 500ms ease forwards;
}

.reveal {
  opacity: 1;
  transform: translateY(20px);
  animation: lift-in 500ms ease forwards;
}

.reveal-1 { animation-delay: 40ms; }
.reveal-2 { animation-delay: 140ms; }
.reveal-3 { animation-delay: 240ms; }

.hero {
  display: grid;
  grid-template-columns: minmax(0, 1.25fr) minmax(320px, 0.75fr);
  gap: 22px;
  align-items: stretch;
  margin-bottom: 28px;
}

.hero-copy,
.hero-panel,
.section,
.login-card,
.login-copy {
  background: var(--surface-frost);
  border: 1px solid var(--surface-line);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow);
}

.hero-copy {
  padding: 36px;
}

.hero-panel {
  padding: 28px;
  background: linear-gradient(180deg, var(--panel-dark-start), var(--panel-dark-accent));
  color: var(--paper-strong);
}

.eyebrow,
.section-kicker,
.link-overline,
.card-label,
.meta-label {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 0.78rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--signal-dark);
  font-weight: 700;
}

.eyebrow::before,
.section-kicker::before,
.meta-label::before {
  content: "";
  width: 28px;
  height: 2px;
  background: currentColor;
  border-radius: 999px;
}

h1,
h2,
h3,
strong {
  font-family: "Iowan Old Style", "Palatino Linotype", "Book Antiqua", serif;
}

h1 {
  margin: 12px 0 14px;
  font-size: clamp(3rem, 5vw, 5.3rem);
  line-height: 0.96;
  letter-spacing: -0.05em;
}

.product-version {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  margin: 0 0 18px;
  color: var(--ink-soft);
  font-size: 0.92rem;
  font-weight: 700;
  letter-spacing: 0;
}

h2 {
  margin: 0;
  font-size: clamp(1.9rem, 3vw, 3rem);
  line-height: 1;
}

h3 {
  margin: 10px 0 8px;
  font-size: 1.35rem;
}

.lede {
  max-width: 54ch;
  font-size: 1.08rem;
  line-height: 1.65;
  color: var(--ink-soft);
}

.hero-actions,
.band-actions,
.login-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 26px;
}

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  position: relative;
  z-index: 1;
  min-height: 50px;
  padding: 0 18px;
  border-radius: 999px;
  border: 1px solid transparent;
  text-decoration: none;
  font-weight: 700;
  letter-spacing: 0.01em;
  transition: transform 180ms ease, box-shadow 180ms ease, background 180ms ease, color 180ms ease;
}

.button:hover {
  transform: translateY(-2px);
}

.button-primary {
  background: linear-gradient(135deg, var(--button-primary-base), var(--signal));
  border: none;
  color: var(--button-primary-text);
  box-shadow: 0 14px 30px var(--button-primary-shadow);
}

.button-secondary {
  background: var(--button-secondary-bg);
  border-color: var(--button-secondary-border);
  color: var(--ink);
}

.button-block {
  width: 100%;
}

.panel-title {
  text-align: center;
  font-size: 1.5rem;
  margin: 0 0 16px;
  color: var(--paper-strong);
  letter-spacing: -0.02em;
}

.panel-columns {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
}

.panel-col .signal-list li {
  padding: 10px 0;
  font-size: 0.92rem;
}

.panel-header {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 0.84rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--panel-dark-muted);
}

.status-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: var(--cobalt);
  box-shadow: 0 0 0 8px var(--status-glow);
}

.signal-list {
  list-style: none;
  margin: 26px 0 0;
  padding: 0;
  display: grid;
  gap: 16px;
}

.signal-list li {
  padding: 14px 0;
  border-top: 1px solid rgba(246, 242, 251, 0.14);
  color: rgba(246, 242, 251, 0.88);
}

.section {
  padding: 30px;
  margin-bottom: 22px;
}

.section-head {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-bottom: 18px;
}

.card-grid,
.link-grid {
  display: grid;
  gap: 16px;
}

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

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

.card,
.link-card {
  min-height: 220px;
  padding: 22px;
  border-radius: var(--radius-md);
  border: 1px solid var(--line);
  background: var(--card-bg);
}

.card-accent {
  background: linear-gradient(165deg, var(--paper-strong), var(--card-accent));
}

.card p,
.link-card span:last-child,
.band-copy p,
.login-copy-small,
.login-notes p {
  line-height: 1.6;
  color: var(--ink-soft);
}

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

.link-card {
  text-decoration: none;
  color: inherit;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  min-height: 180px;
  transition: transform 180ms ease, border-color 180ms ease, box-shadow 180ms ease;
}

.link-card:hover {
  transform: translateY(-4px);
  border-color: var(--link-hover-border);
  box-shadow: 0 16px 28px var(--link-hover-shadow);
}

.link-card[data-hidden="true"] {
  display: none;
}

.section-band {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  background: linear-gradient(135deg, var(--panel-dark-start), var(--panel-dark-accent));
  color: var(--paper-strong);
}

.section-band .section-kicker,
.section-band .section-kicker::before {
  color: var(--section-band-kicker);
}

.section-band p,
.section-band code {
  color: rgba(246, 242, 251, 0.84);
}

code {
  padding: 4px 8px;
  border-radius: 999px;
  background: var(--code-bg);
  font-family: "SFMono-Regular", "Menlo", monospace;
}

.section-band code {
  background: var(--band-code-bg);
}

.login-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(340px, 420px);
  gap: 22px;
}

.login-copy,
.login-card {
  padding: 34px;
}

.login-meta {
  display: grid;
  gap: 16px;
  margin-top: 28px;
}

.login-card {
  background: linear-gradient(180deg, var(--surface-frost), var(--login-card-accent));
}

.login-card-head {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 12px;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  font-size: 0.82rem;
  color: var(--ink-soft);
}

.login-notes {
  display: grid;
  gap: 10px;
  margin-top: 18px;
  padding-top: 18px;
  border-top: 1px solid var(--line);
}

.login-card-local {
  grid-column: 1 / -1;
}

.login-pre {
  margin: 12px 0;
  padding: 14px 16px;
  background: var(--band-code-bg);
  border-radius: 10px;
  overflow-x: auto;
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 0.92rem;
  white-space: pre-wrap;
  word-break: break-word;
}

.stack-list {
  list-style: none;
  margin: 0;
  padding: 0;
}

.stack-list li {
  padding: 14px 0;
  border-bottom: 1px solid var(--line);
  line-height: 1.5;
  color: var(--ink-soft);
}

.stack-list li:first-child {
  padding-top: 0;
}

.stack-list li strong {
  color: var(--ink);
  font-family: "Iowan Old Style", "Palatino Linotype", "Book Antiqua", serif;
}

.stack-list-links a {
  text-decoration: none;
  color: inherit;
  display: block;
  transition: color 120ms ease;
}

.stack-list-links a:hover {
  color: var(--signal-dark);
}

.stack-list-links a:hover strong {
  color: var(--signal-dark);
}

.site-footer {
  margin-top: 40px;
  padding: 20px 0;
  text-align: center;
  font-size: 0.85rem;
  color: var(--ink-soft);
}

.site-footer a {
  color: var(--signal-dark);
  text-decoration: none;
}

.site-footer a:hover {
  text-decoration: underline;
}

/* ── In-progress list ── */

.progress-list {
  list-style: none;
  padding: 0;
  margin: 0;
}

.progress-list-item {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0.5rem 0;
  border-bottom: 1px solid var(--line);
}

.progress-list-item:last-child {
  border-bottom: none;
}

.progress-list-title {
  flex: 0 0 auto;
  min-width: 14rem;
  color: var(--ink);
}

.progress-list-link {
  margin-left: 0.5rem;
  text-decoration: none;
  color: var(--ink-soft);
}

.progress-list-placeholder {
  color: var(--ink-soft);
  font-style: italic;
  padding: 0.5rem 0;
}


@keyframes lift-in {
  from {
    transform: translateY(12px);
  }
  to {
    transform: translateY(0);
  }
}

@media (max-width: 980px) {
  .hero,
  .login-layout,
  .section-band {
    grid-template-columns: 1fr;
    display: grid;
  }

  .card-grid-three,
  .card-grid-four,
  .link-grid {
    grid-template-columns: 1fr 1fr;
  }

}

@media (max-width: 720px) {
  .page-shell,
  .page-shell-tight {
    width: min(100% - 24px, 100%);
    padding-top: 18px;
  }

  .hero-copy,
  .hero-panel,
  .section,
  .login-copy,
  .login-card {
    padding: 24px;
  }

  h1 {
    font-size: 2.7rem;
  }

  .card-grid-three,
  .card-grid-four,
  .link-grid {
    grid-template-columns: 1fr;
  }

  .hero-actions,
  .band-actions,
  .login-actions {
    flex-direction: column;
  }

  .button,
  .button-block {
    width: 100%;
  }

}
