:root {
  color-scheme: light;
  --bg: oklch(0.97 0.02 92);
  --bg-strong: oklch(0.92 0.03 92);
  --surface: oklch(0.995 0.01 90 / 0.88);
  --surface-strong: oklch(0.99 0.02 90);
  --text: oklch(0.28 0.03 220);
  --muted: oklch(0.48 0.03 220);
  --line: oklch(0.85 0.03 90);
  --accent: oklch(0.62 0.13 194);
  --accent-strong: oklch(0.5 0.12 194);
  --accent-soft: oklch(0.9 0.04 194);
  --success: oklch(0.75 0.12 145);
  --error: oklch(0.7 0.16 28);
  --shadow: 0 24px 60px rgba(35, 56, 70, 0.12);
  --radius: 28px;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  min-height: 100vh;
  color: var(--text);
  background:
    radial-gradient(circle at top left, rgba(113, 202, 205, 0.28), transparent 28%),
    radial-gradient(circle at right 20%, rgba(255, 184, 93, 0.22), transparent 24%),
    linear-gradient(180deg, var(--bg), var(--bg-strong));
  font-family: "Manrope", sans-serif;
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  background-image: linear-gradient(rgba(37, 62, 77, 0.03) 1px, transparent 1px),
    linear-gradient(90deg, rgba(37, 62, 77, 0.03) 1px, transparent 1px);
  background-size: 72px 72px;
  pointer-events: none;
  opacity: 0.55;
}

.page-shell {
  position: relative;
  width: min(1120px, calc(100% - 32px));
  margin: 0 auto;
  padding: 32px 0 48px;
}

.flash-stack {
  display: grid;
  gap: 12px;
  margin-bottom: 18px;
}

.flash {
  border-radius: 18px;
  padding: 14px 16px;
  border: 1px solid var(--line);
  background: var(--surface);
  box-shadow: var(--shadow);
  font-weight: 700;
}

.flash-success {
  color: oklch(0.34 0.08 160);
  border-color: color-mix(in oklab, var(--success) 30%, white);
  background: color-mix(in oklab, white 70%, var(--success));
}

.flash-error {
  color: oklch(0.42 0.09 28);
  border-color: color-mix(in oklab, var(--error) 30%, white);
  background: color-mix(in oklab, white 78%, var(--error));
}

.hero-layout,
.admin-layout,
.auth-layout {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: clamp(24px, 4vw, 56px);
  align-items: start;
  min-height: calc(100vh - 80px);
}

.hero-copy,
.form-panel,
.admin-header,
.table-panel,
.auth-copy {
  position: relative;
  z-index: 1;
}

.hero-copy {
  padding: clamp(24px, 5vw, 56px) 0;
}

.eyebrow {
  margin: 0 0 14px;
  font-size: 0.83rem;
  font-weight: 800;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--accent-strong);
}

h1 {
  margin: 0;
  max-width: 10ch;
  font-family: "Instrument Serif", serif;
  font-size: clamp(3.3rem, 9vw, 6.5rem);
  line-height: 0.94;
  letter-spacing: -0.04em;
  text-wrap: balance;
}

.lead {
  max-width: 36rem;
  margin: 24px 0 0;
  font-size: clamp(1.05rem, 2vw, 1.24rem);
  line-height: 1.7;
  color: var(--muted);
}

.feature-list {
  display: grid;
  gap: 14px;
  padding: 0;
  margin: 36px 0 0;
  list-style: none;
}

.feature-list li {
  width: fit-content;
  padding: 12px 18px;
  border-radius: 999px;
  border: 1px solid rgba(76, 114, 128, 0.12);
  background: rgba(255, 251, 245, 0.7);
  font-weight: 700;
}

.form-panel,
.table-panel {
  padding: clamp(22px, 4vw, 34px);
  border: 1px solid rgba(76, 114, 128, 0.16);
  border-radius: var(--radius);
  background: linear-gradient(180deg, var(--surface), rgba(255, 255, 255, 0.7));
  box-shadow: var(--shadow);
  backdrop-filter: blur(12px);
}

.form-panel {
  margin-top: clamp(18px, 10vw, 88px);
}

.panel-badge {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 22px;
  padding: 10px 14px;
  border-radius: 999px;
  background: var(--accent-soft);
  color: var(--accent-strong);
  font-size: 0.9rem;
  font-weight: 800;
}

.waitlist-form {
  display: grid;
  gap: 14px;
}

label {
  font-size: 0.95rem;
  font-weight: 800;
}

input {
  width: 100%;
  padding: 16px 18px;
  border: 1px solid var(--line);
  border-radius: 18px;
  outline: none;
  background: var(--surface-strong);
  color: var(--text);
  font: inherit;
  transition: border-color 180ms ease, transform 180ms ease, box-shadow 180ms ease;
}

input:focus {
  border-color: color-mix(in oklab, var(--accent) 55%, white);
  transform: translateY(-1px);
  box-shadow: 0 0 0 4px color-mix(in oklab, var(--accent) 22%, white);
}

button {
  margin-top: 8px;
  padding: 16px 18px;
  border: none;
  border-radius: 18px;
  background: linear-gradient(135deg, var(--accent), color-mix(in oklab, var(--accent) 74%, white));
  color: oklch(0.98 0.01 200);
  font: inherit;
  font-weight: 800;
  cursor: pointer;
  transition: transform 180ms ease, box-shadow 180ms ease, filter 180ms ease;
}

button:hover {
  transform: translateY(-2px);
  box-shadow: 0 18px 28px rgba(49, 131, 145, 0.22);
  filter: saturate(1.05);
}

.ghost-button {
  margin-top: 0;
  padding: 12px 16px;
  border: 1px solid var(--line);
  background: rgba(255, 251, 245, 0.88);
  color: var(--text);
  box-shadow: none;
}

.ghost-button:hover {
  box-shadow: none;
  filter: none;
}

.panel-note {
  margin: 16px 0 0;
  color: var(--muted);
  line-height: 1.65;
}

.admin-layout {
  grid-template-columns: 1fr;
  min-height: auto;
}

.auth-layout {
  align-items: center;
}

.auth-copy {
  padding: clamp(24px, 5vw, 56px) 0;
}

.admin-header h1 {
  max-width: none;
  font-size: clamp(2.7rem, 6vw, 4.6rem);
}

.auth-copy h1 {
  max-width: none;
  font-size: clamp(2.8rem, 7vw, 5rem);
}

.auth-panel {
  margin-top: 0;
}

.admin-toolbar {
  display: flex;
  justify-content: flex-end;
  margin-bottom: 18px;
}

.table-wrap {
  overflow-x: auto;
}

table {
  width: 100%;
  border-collapse: collapse;
}

th,
td {
  padding: 16px 12px;
  border-bottom: 1px solid var(--line);
  text-align: left;
}

th {
  font-size: 0.84rem;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: var(--muted);
}

tbody tr:hover {
  background: rgba(255, 251, 245, 0.8);
}

.empty-state {
  padding: 44px 12px 12px;
}

.empty-state h2 {
  margin: 0 0 10px;
  font-family: "Instrument Serif", serif;
  font-size: clamp(2rem, 5vw, 3rem);
  line-height: 1;
}

.empty-state p {
  margin: 0;
  color: var(--muted);
}

@media (max-width: 900px) {
  .hero-layout,
  .admin-layout,
  .auth-layout {
    grid-template-columns: 1fr;
  }

  .hero-copy {
    padding-bottom: 0;
  }

  .form-panel {
    margin-top: 0;
  }

  h1 {
    max-width: 12ch;
  }
}

@media (max-width: 640px) {
  .page-shell {
    width: min(100% - 20px, 1120px);
    padding-top: 20px;
  }

  body::before {
    background-size: 48px 48px;
  }

  .feature-list li,
  .panel-badge {
    width: 100%;
    justify-content: center;
  }

  th,
  td {
    padding: 14px 10px;
    font-size: 0.94rem;
  }
}
