:root {
  --bg: #edf2f8;
  --panel: rgba(247, 250, 255, 0.68);
  --panel-strong: rgba(255, 255, 255, 0.92);
  --text: #16233b;
  --muted: #6e7f98;
  --line: rgba(34, 55, 86, 0.09);
  --shadow: 0 28px 90px rgba(20, 40, 72, 0.12);
  --accent: #1768e6;
  --accent-dark: #0f3776;
  --good: #1f8f5f;
  --warn: #c98714;
  --bad: #c1493d;
}

* { box-sizing: border-box; }

body {
  margin: 0;
  font-family: Outfit, "Segoe UI", Arial, sans-serif;
  color: var(--text);
  background:
    radial-gradient(circle at 8% 14%, rgba(255, 191, 128, 0.38) 0 12px, transparent 13px),
    radial-gradient(circle at 88% 12%, rgba(72, 163, 255, 0.18), transparent 22%),
    linear-gradient(135deg, #edf3f9 0%, #eef4fb 44%, #f8fbff 100%);
  min-height: 100vh;
  overflow-x: hidden;
}

.app-shell {
  max-width: 1240px;
  margin: 0 auto;
  padding: 28px 20px 56px;
}

.access-shell {
  min-height: 100vh;
  display: grid;
  place-items: center;
  padding: 24px;
}

.access-card {
  width: min(100%, 620px);
  padding: 34px;
  border-radius: 34px;
  background: linear-gradient(135deg, rgba(255,255,255,.8), rgba(241,247,255,.72));
  border: 1px solid rgba(255,255,255,.78);
  box-shadow: var(--shadow);
}

.back-link {
  display: inline-flex;
  margin-bottom: 18px;
  color: var(--muted);
  text-decoration: none;
  font-weight: 700;
}

.access-badge,
.topbar-badge,
.hero-pill,
.grade-badge {
  display: inline-flex;
  align-items: center;
  padding: 10px 14px;
  border-radius: 999px;
  border: 1px solid rgba(41, 65, 102, 0.08);
  background: rgba(255, 255, 255, 0.78);
  font-size: .88rem;
  font-weight: 700;
}

.access-card h1,
.brand-copy strong,
h1,
h2,
h3,
.hero-card strong,
.metric-card strong {
  font-family: "Space Grotesk", Outfit, Arial, sans-serif;
}

.access-card h1 {
  font-size: clamp(2rem, 5vw, 3.5rem);
  line-height: .95;
  margin: 16px 0 14px;
  max-width: 12ch;
}

.access-card p,
.hero-text,
.panel-head p,
.metric-card small,
.issue-box li,
.disclaimer-box {
  color: var(--muted);
  line-height: 1.7;
}

.access-form {
  display: grid;
  gap: 14px;
  margin-top: 24px;
}

.access-message { margin-top: 14px; min-height: 24px; font-weight: 600; }
.access-message.is-error { color: var(--bad); }
.access-message.is-success { color: var(--good); }

.topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  margin-bottom: 22px;
}

.brand-link {
  display: flex;
  align-items: center;
  gap: 14px;
  color: inherit;
  text-decoration: none;
}

.brand-mark {
  width: 60px;
  height: 60px;
  border-radius: 22px;
  background: linear-gradient(145deg, rgba(86,171,255,1), rgba(23,104,230,1) 55%, rgba(11,51,114,1));
  box-shadow: 0 20px 45px rgba(23, 104, 230, 0.26);
  display: grid;
  place-items: center;
  overflow: hidden;
}

.brand-mark img { width: 82%; height: 82%; object-fit: contain; }
.brand-copy { display: grid; gap: 2px; }
.brand-copy span { color: var(--muted); font-size: .95rem; }
.topbar-badges { display: flex; flex-wrap: wrap; gap: 10px; }
.topbar-badge-success { color: var(--good); background: rgba(31,143,95,.1); }

.hero {
  display: grid;
  grid-template-columns: 1.2fr .8fr;
  gap: 24px;
  margin-bottom: 24px;
}

.hero-copy,
.hero-card,
.panel {
  background: var(--panel);
  backdrop-filter: blur(22px);
  border: 1px solid rgba(255,255,255,.78);
  box-shadow: var(--shadow);
  border-radius: 34px;
}

.hero-copy { padding: 38px; }
.eyebrow { margin: 0 0 14px; color: var(--accent-dark); letter-spacing: .24em; font-size: 12px; font-weight: 800; }
h1 { margin: 0; font-size: clamp(2.8rem, 5vw, 4.8rem); line-height: .92; letter-spacing: -.07em; max-width: 11ch; }
.hero-pills { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 22px; }

.hero-card {
  padding: 30px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 16px;
  background: linear-gradient(180deg, rgba(230,240,255,.98), rgba(248,251,255,.94));
}

.hero-label,
.metric-card span,
label span,
.issue-box h3,
.panel-head p { color: var(--muted); }

.hero-card strong { font-size: clamp(3rem, 6vw, 4.8rem); line-height: .96; letter-spacing: -.08em; }

.grade-a { background: rgba(31, 143, 95, 0.12); color: var(--good); }
.grade-b { background: rgba(201, 135, 20, 0.14); color: var(--warn); }
.grade-c { background: rgba(193, 73, 61, 0.14); color: var(--bad); }

.layout {
  display: grid;
  grid-template-columns: 1.55fr 0.9fr;
  gap: 24px;
}

.panel {
  padding: 30px;
  background: linear-gradient(135deg, rgba(255,255,255,.68), rgba(243,248,255,.6));
}

.panel-head { margin-bottom: 18px; }
.panel-head.compact { margin-top: 26px; }
.panel-head h2, .issue-box h3 { margin: 0 0 6px; font-size: 1.14rem; }

form { display: grid; gap: 16px; }
.grid { display: grid; gap: 14px; }
.grid.three { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.grid.four { grid-template-columns: repeat(4, minmax(0, 1fr)); }

.stepper, .step-actions, .topbar-badges, .actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.step-chip,
.btn {
  font: inherit;
}

.step-chip {
  border: 1px solid var(--line);
  background: rgba(255,255,255,.72);
  color: var(--muted);
  border-radius: 999px;
  padding: 13px 18px;
  font-weight: 700;
  cursor: pointer;
}

.step-chip.is-active {
  background: linear-gradient(135deg, #58abff, var(--accent));
  color: white;
}

.wizard-step { display: none; }
.wizard-step.is-active { display: grid; gap: 16px; }

label { display: grid; gap: 8px; }
label span { font-size: .92rem; font-weight: 700; }

input, select, textarea {
  width: 100%;
  border-radius: 20px;
  border: 1px solid var(--line);
  background: var(--panel-strong);
  padding: 15px 16px;
  color: var(--text);
  outline: none;
  box-shadow: inset 0 1px 0 rgba(255,255,255,.88);
}

textarea { resize: vertical; }

.btn {
  border: 0;
  padding: 16px 20px;
  border-radius: 20px;
  cursor: pointer;
  font-weight: 800;
}

.btn-primary {
  background: linear-gradient(135deg, #59adff, #2f7fff 45%, #1768e6);
  color: white;
}

.btn-secondary {
  background: linear-gradient(135deg, #243552, #15233b);
  color: white;
}

.btn-ghost {
  background: rgba(255,255,255,.68);
  color: #172235;
  border: 1px solid rgba(34,55,86,.08);
}

.disclaimer-box {
  padding: 16px 18px;
  border-radius: 20px;
  background: rgba(255, 178, 125, 0.14);
  border: 1px solid rgba(255, 178, 125, 0.28);
}

.panel-summary {
  display: flex;
  flex-direction: column;
  gap: 18px;
  position: sticky;
  top: 20px;
  align-self: start;
}

.metric-stack { display: grid; gap: 12px; }
.metric-card, .issue-box {
  border-radius: 26px;
  padding: 22px;
  background: linear-gradient(180deg, rgba(255,255,255,.76), rgba(248,251,255,.62));
  border: 1px solid var(--line);
}

.metric-card strong {
  display: block;
  margin: 12px 0 6px;
  font-size: 2.35rem;
  letter-spacing: -.05em;
}

.issue-box ul { margin: 0; padding-left: 18px; display: grid; gap: 10px; }

@media (max-width: 1100px) {
  .topbar,
  .hero,
  .layout {
    grid-template-columns: 1fr;
    flex-direction: column;
    align-items: flex-start;
  }

  .panel-summary { position: static; }
}

@media (max-width: 760px) {
  .app-shell { padding: 18px 14px 32px; }
  .hero-copy, .hero-card, .panel, .access-card { border-radius: 22px; padding: 22px; }
  .grid.three, .grid.four { grid-template-columns: 1fr; }
  .hero-card strong { font-size: 3.2rem; }
}
