:root {
  --bg: #04101d;
  --panel: rgba(8, 17, 32, 0.88);
  --panel-strong: rgba(13, 25, 46, 0.95);
  --line: rgba(147, 197, 253, 0.14);
  --text: #f6fbff;
  --muted: #98acc5;
  --accent: #53b4ff;
  --accent-strong: #5ef2c7;
  --warning: #ffcc66;
  --danger: #ff7d7d;
  --shadow: 0 28px 80px rgba(0, 0, 0, 0.34);
  --radius-lg: 28px;
  --radius-md: 18px;
  --radius-sm: 14px;
}

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

body {
  margin: 0;
  min-width: 320px;
  background:
    radial-gradient(circle at top left, rgba(83, 180, 255, 0.16), transparent 30%),
    radial-gradient(circle at 85% 20%, rgba(94, 242, 199, 0.14), transparent 25%),
    linear-gradient(180deg, #020711 0%, #071120 50%, #030813 100%);
  color: var(--text);
  font-family: "Inter", sans-serif;
  line-height: 1.6;
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  background-image:
    linear-gradient(rgba(255, 255, 255, 0.03) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.03) 1px, transparent 1px);
  background-size: 64px 64px;
  mask-image: linear-gradient(180deg, rgba(255, 255, 255, 0.72), transparent 100%);
  pointer-events: none;
}

a {
  color: inherit;
  text-decoration: none;
}

button,
input {
  font: inherit;
}

.app-shell {
  position: relative;
  min-height: 100vh;
  padding: 1.5rem;
  overflow: hidden;
}

.glow {
  position: fixed;
  width: 24rem;
  height: 24rem;
  border-radius: 50%;
  filter: blur(90px);
  opacity: 0.32;
  pointer-events: none;
}

.glow-left {
  top: 4rem;
  left: -6rem;
  background: rgba(83, 180, 255, 0.3);
}

.glow-right {
  right: -7rem;
  bottom: 0;
  background: rgba(94, 242, 199, 0.22);
}

.topbar,
.layout {
  width: min(1160px, 100%);
  margin: 0 auto;
}

.topbar {
  position: relative;
  z-index: 1;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 1.5rem;
}

.back-link,
.topbar-tag {
  display: inline-flex;
  align-items: center;
  padding: 0.72rem 1rem;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.04);
}

.back-link {
  color: #d9eeff;
  transition: transform 220ms ease, border-color 220ms ease;
}

.back-link:hover,
.back-link:focus-visible {
  transform: translateY(-2px);
  border-color: rgba(83, 180, 255, 0.32);
}

.topbar-tag {
  color: #9dd6ff;
  font-size: 0.86rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.layout {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: 1.08fr 0.92fr;
  gap: 1.15rem;
}

.hero-card,
.panel {
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  background:
    radial-gradient(circle at top left, rgba(83, 180, 255, 0.12), transparent 36%),
    linear-gradient(180deg, rgba(11, 22, 41, 0.96), rgba(7, 14, 27, 0.94));
  box-shadow: var(--shadow);
}

.hero-card {
  grid-column: 1 / -1;
  padding: clamp(1.7rem, 4vw, 2.5rem);
}

.eyebrow,
.panel-label {
  display: inline-flex;
  width: fit-content;
  padding: 0.4rem 0.75rem;
  border: 1px solid rgba(83, 180, 255, 0.2);
  border-radius: 999px;
  background: rgba(83, 180, 255, 0.08);
  color: #cceaff;
  font-size: 0.82rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.hero-card h1,
.panel h2 {
  margin: 0;
  font-family: "Space Grotesk", sans-serif;
  letter-spacing: -0.04em;
}

.hero-card h1 {
  margin-top: 1rem;
  font-size: clamp(2.4rem, 6vw, 4.8rem);
  line-height: 0.95;
}

.hero-card p {
  max-width: 48rem;
  margin: 1rem 0 0;
  color: var(--muted);
  font-size: 1.04rem;
}

.hero-stats {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1rem;
  margin-top: 1.8rem;
}

.hero-stats article,
.insight-card,
.recommendation-card {
  padding: 1rem 1.1rem;
  border: 1px solid rgba(147, 197, 253, 0.12);
  border-radius: var(--radius-md);
  background: rgba(255, 255, 255, 0.04);
}

.hero-stats strong {
  display: block;
  font-size: 1.6rem;
  font-family: "Space Grotesk", sans-serif;
}

.hero-stats span,
.insight-label {
  color: var(--muted);
}

.panel {
  padding: 1.45rem;
}

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

.panel h2 {
  margin-top: 0.8rem;
  font-size: 1.6rem;
  line-height: 1;
}

.ghost-button {
  min-height: 3rem;
  padding: 0.78rem 1.05rem;
  border: 1px solid rgba(83, 180, 255, 0.18);
  border-radius: 999px;
  background: rgba(83, 180, 255, 0.08);
  color: var(--text);
  cursor: pointer;
  transition: transform 220ms ease, border-color 220ms ease, background-color 220ms ease;
}

.ghost-button:hover,
.ghost-button:focus-visible {
  transform: translateY(-2px);
  border-color: rgba(83, 180, 255, 0.36);
  background: rgba(83, 180, 255, 0.14);
}

.input-label {
  display: block;
  margin-bottom: 0.65rem;
  color: #dceefe;
  font-weight: 600;
}

.input-wrap {
  position: relative;
}

.input-wrap input {
  width: 100%;
  min-height: 3.6rem;
  padding: 0 1.1rem;
  border: 1px solid rgba(147, 197, 253, 0.16);
  border-radius: var(--radius-sm);
  background: rgba(255, 255, 255, 0.04);
  color: var(--text);
  outline: none;
  transition: border-color 220ms ease, box-shadow 220ms ease;
}

.input-wrap input:focus {
  border-color: rgba(83, 180, 255, 0.42);
  box-shadow: 0 0 0 4px rgba(83, 180, 255, 0.12);
}

.score-panel {
  margin-top: 1.2rem;
}

.score-copy {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 0.7rem;
}

.score-copy span {
  color: #dff0ff;
  font-weight: 600;
}

.score-copy strong {
  font-family: "Space Grotesk", sans-serif;
  font-size: 1.15rem;
}

.meter-track {
  position: relative;
  height: 0.85rem;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.08);
  overflow: hidden;
}

.meter-track span {
  position: absolute;
  inset: 0 auto 0 0;
  width: 0;
  border-radius: inherit;
  background: linear-gradient(90deg, var(--danger), var(--warning), var(--accent-strong));
  transition: width 260ms ease;
}

.insight-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0.8rem;
  margin-top: 1.2rem;
}

.insight-card strong {
  display: block;
  margin-top: 0.35rem;
  font-size: 1rem;
}

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

.checklist li,
.feature-list li {
  position: relative;
  padding: 1rem 1rem 1rem 3.1rem;
  border: 1px solid rgba(147, 197, 253, 0.12);
  border-radius: var(--radius-md);
  background: rgba(255, 255, 255, 0.04);
  color: #dcefff;
}

.checklist li::before,
.feature-list li::before {
  content: "";
  position: absolute;
  top: 1rem;
  left: 1rem;
  width: 1.2rem;
  height: 1.2rem;
  border: 1px solid rgba(147, 197, 253, 0.24);
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.02);
  box-shadow: inset 0 0 0 4px transparent;
  transition: border-color 220ms ease, box-shadow 220ms ease, background-color 220ms ease;
}

.checklist li.is-valid::before {
  border-color: rgba(94, 242, 199, 0.32);
  background: rgba(94, 242, 199, 0.12);
  box-shadow: inset 0 0 0 4px rgba(94, 242, 199, 0.88);
}

.recommendation-card {
  margin-top: 1rem;
}

.recommendation-card p {
  margin: 0.75rem 0 0;
  color: var(--muted);
}

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

@media (max-width: 960px) {
  .layout {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 720px) {
  .app-shell {
    padding: 1rem;
  }

  .topbar {
    flex-direction: column;
    align-items: stretch;
  }

  .hero-stats,
  .insight-grid {
    grid-template-columns: 1fr;
  }

  .panel,
  .hero-card {
    border-radius: 22px;
  }

  .panel-heading,
  .score-copy {
    flex-direction: column;
    align-items: flex-start;
  }

  .ghost-button {
    width: 100%;
  }
}
