:root {
  --bg: #101828;
  --card: #182230;
  --card-2: #243247;
  --text: #F9FAFB;
  --muted: #D0D5DD;
  --accent: #7C3AED;
  --accent-2: #06B6D4;
  --warning: #F79009;
  --danger: #F04438;
  --success: #12B76A;
  --line: rgba(255, 255, 255, 0.1);
  --line-strong: rgba(255, 255, 255, 0.16);
  --surface-soft: rgba(36, 50, 71, 0.66);
  --shadow: 0 28px 70px rgba(0, 0, 0, 0.32);
  --shadow-soft: 0 18px 42px rgba(0, 0, 0, 0.24);
  --radius: 8px;
  --content: 1200px;
}

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

html {
  min-width: 320px;
  color-scheme: dark;
}

body {
  margin: 0;
  min-height: 100vh;
  overflow-x: hidden;
  color: var(--text);
  background: var(--bg);
  font-family: "Inter", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  text-rendering: optimizeLegibility;
}

body::before {
  position: fixed;
  inset: 0;
  z-index: -2;
  content: "";
  background:
    linear-gradient(145deg, rgba(124, 58, 237, 0.18), transparent 34%),
    linear-gradient(320deg, rgba(6, 182, 212, 0.12), transparent 38%),
    var(--bg);
}

body::after {
  position: fixed;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  content: "";
  background-image:
    linear-gradient(rgba(255, 255, 255, 0.035) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.035) 1px, transparent 1px);
  background-size: 44px 44px;
  mask-image: linear-gradient(to bottom, rgba(0, 0, 0, 0.5), transparent 78%);
}

img {
  max-width: 100%;
  display: block;
}

button {
  font: inherit;
}

button,
a {
  -webkit-tap-highlight-color: transparent;
}

.page-bg {
  min-height: 100vh;
}

.site-header {
  position: relative;
  z-index: 10;
  border-bottom: 1px solid rgba(16, 24, 40, 0.06);
  background: #FFFFFF;
  box-shadow: 0 10px 30px rgba(16, 24, 40, 0.06);
}

.site-header-inner {
  width: min(1680px, calc(100% - 80px));
  min-height: 120px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 40px;
}

.site-logo {
  display: inline-flex;
  align-items: center;
  flex: 0 0 auto;
  text-decoration: none;
}

.site-logo img {
  width: 238px;
  height: auto;
}

.site-nav {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 44px;
  min-width: 0;
}

.site-nav a {
  position: relative;
  color: #07142E;
  font-size: 1.08rem;
  font-weight: 800;
  line-height: 1.25;
  text-decoration: none;
  white-space: nowrap;
  transition: color 160ms ease;
}

.site-nav a::after {
  position: absolute;
  right: 0;
  bottom: -8px;
  left: 0;
  height: 2px;
  border-radius: 999px;
  content: "";
  background: linear-gradient(90deg, #7C3AED, #06B6D4);
  transform: scaleX(0);
  transform-origin: center;
  transition: transform 160ms ease;
}

.site-nav a:hover {
  color: #2B22B8;
}

.site-nav a:hover::after,
.site-nav a:focus-visible::after {
  transform: scaleX(1);
}

.site-nav a:focus-visible,
.site-logo:focus-visible {
  outline: 3px solid rgba(124, 58, 237, 0.32);
  outline-offset: 6px;
  border-radius: var(--radius);
}

.app-shell {
  width: min(var(--content), calc(100% - 32px));
  margin: 0 auto;
  padding: 32px 0;
}

.screen {
  min-height: calc(100vh - 64px);
}

.hidden {
  display: none !important;
}

h1,
h2,
h3 {
  margin: 0;
  font-family: "Montserrat", "Inter", sans-serif;
  line-height: 1.08;
  letter-spacing: 0;
}

h1 {
  max-width: 780px;
  font-size: 3.35rem;
  font-weight: 800;
}

h2 {
  font-size: 2.15rem;
  font-weight: 800;
}

h3 {
  font-size: 1.05rem;
  font-weight: 700;
}

p {
  margin: 0;
}

.eyebrow,
.info-label {
  color: var(--accent-2);
  font-size: 0.78rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.lead,
.scenario-text,
.scenario-dilemma {
  max-width: 78ch;
  color: var(--muted);
  font-size: 1.04rem;
  line-height: 1.68;
  overflow-wrap: anywhere;
}

.scenario-dilemma {
  color: var(--text);
  font-weight: 600;
}

.hero-card,
.card,
.info-card {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: rgba(24, 34, 48, 0.94);
  box-shadow: var(--shadow-soft);
  backdrop-filter: blur(12px);
}

.screen-start {
  display: grid;
  grid-template-columns: minmax(0, 1.45fr) minmax(280px, 0.55fr);
  gap: 24px;
  align-items: center;
}

.hero-card {
  position: relative;
  display: grid;
  gap: 24px;
  min-height: 520px;
  padding: 48px;
  overflow: hidden;
  box-shadow: var(--shadow);
}

.hero-card::before {
  position: absolute;
  inset: 0;
  pointer-events: none;
  content: "";
  background:
    linear-gradient(135deg, rgba(124, 58, 237, 0.18), transparent 42%),
    linear-gradient(315deg, rgba(6, 182, 212, 0.12), transparent 36%);
}

.hero-card > * {
  position: relative;
}

.lead {
  font-size: 1.12rem;
}

.hero-explainer {
  display: grid;
  gap: 14px;
  max-width: 78ch;
  color: var(--muted);
  font-size: 1rem;
  line-height: 1.64;
}

.hero-explainer p {
  overflow-wrap: anywhere;
}

.hero-explainer ul {
  display: grid;
  gap: 10px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.hero-explainer li {
  position: relative;
  padding-left: 26px;
  overflow-wrap: anywhere;
}

.hero-explainer li::before {
  position: absolute;
  top: 0.62em;
  left: 0;
  width: 9px;
  height: 9px;
  border-radius: 999px;
  content: "";
  background: var(--accent-2);
  box-shadow: 0 0 0 5px rgba(6, 182, 212, 0.1);
}

.start-actions,
.final-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  align-items: center;
}

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 46px;
  border: 1px solid transparent;
  border-radius: var(--radius);
  padding: 12px 18px;
  color: var(--text);
  font-weight: 800;
  line-height: 1.2;
  text-align: center;
  cursor: pointer;
  transition:
    color 160ms ease,
    border-color 160ms ease,
    background-color 160ms ease,
    box-shadow 160ms ease,
    transform 160ms ease;
}

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

.button:active {
  transform: translateY(0);
}

.button:focus-visible,
.choice-card:focus-visible {
  outline: 3px solid rgba(6, 182, 212, 0.56);
  outline-offset: 3px;
}

.button-primary {
  background: var(--accent);
  box-shadow: 0 14px 28px rgba(124, 58, 237, 0.28);
}

.button-primary:hover {
  background: #8B5CF6;
  box-shadow: 0 18px 36px rgba(124, 58, 237, 0.34);
}

.button-secondary {
  border-color: var(--line-strong);
  background: var(--card-2);
}

.button-secondary:hover {
  border-color: rgba(6, 182, 212, 0.6);
  background: #2B3A52;
}

.button-ghost {
  border-color: var(--line);
  background: rgba(255, 255, 255, 0.03);
}

.button-ghost:hover {
  border-color: rgba(208, 213, 221, 0.5);
  background: rgba(255, 255, 255, 0.07);
}

.button-small {
  min-height: 38px;
  padding: 8px 12px;
  font-size: 0.88rem;
}

.info-grid {
  display: grid;
  gap: 14px;
}

.info-card {
  display: grid;
  gap: 8px;
  padding: 18px;
  background: rgba(36, 50, 71, 0.78);
}

.info-card strong {
  color: var(--text);
  font-size: 1.18rem;
  line-height: 1.25;
  overflow-wrap: anywhere;
}

.top-bar {
  display: flex;
  justify-content: space-between;
  gap: 18px;
  align-items: flex-start;
  margin-bottom: 20px;
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: rgba(24, 34, 48, 0.9);
  box-shadow: var(--shadow-soft);
}

.top-bar > div:first-child {
  display: grid;
  gap: 8px;
  min-width: 0;
}

.top-bar-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  justify-content: flex-end;
  align-items: center;
  color: var(--muted);
}

.top-bar-meta span {
  min-height: 34px;
  display: inline-flex;
  align-items: center;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 7px 10px;
  background: var(--surface-soft);
  font-size: 0.9rem;
  font-weight: 700;
  white-space: nowrap;
}

.game-layout {
  display: grid;
  grid-template-columns: minmax(0, 1.9fr) minmax(292px, 0.86fr);
  gap: 20px;
  align-items: start;
}

.card {
  padding: 28px;
}

.scenario-card {
  display: grid;
  gap: 20px;
}

.choice-list {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  margin-top: 4px;
}

.choice-card {
  width: 100%;
  min-height: 138px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 17px;
  color: var(--text);
  background: var(--card-2);
  text-align: left;
  cursor: pointer;
  box-shadow: 0 12px 24px rgba(0, 0, 0, 0.16);
  transition:
    border-color 160ms ease,
    background-color 160ms ease,
    box-shadow 160ms ease,
    transform 160ms ease;
}

.choice-card:hover {
  border-color: rgba(6, 182, 212, 0.78);
  background: #2B3A52;
  box-shadow: 0 16px 30px rgba(0, 0, 0, 0.22);
  transform: translateY(-1px);
}

.choice-card:active {
  transform: translateY(0);
}

.choice-card strong {
  display: block;
  margin-bottom: 8px;
  font-size: 1rem;
  line-height: 1.35;
  overflow-wrap: anywhere;
}

.choice-card span {
  display: block;
  color: var(--muted);
  font-size: 0.92rem;
  line-height: 1.48;
  overflow-wrap: anywhere;
}

.metrics-panel {
  position: sticky;
  top: 20px;
  align-self: start;
  background: rgba(24, 34, 48, 0.96);
}

.metrics-panel h3 {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding-bottom: 14px;
  border-bottom: 1px solid var(--line);
}

.metrics-panel h3::after {
  width: 9px;
  height: 9px;
  border-radius: 999px;
  content: "";
  background: var(--accent-2);
  box-shadow: 0 0 0 5px rgba(6, 182, 212, 0.12);
}

.metrics-list,
.effects-list {
  display: grid;
  gap: 12px;
  margin-top: 16px;
}

.metric-row {
  display: grid;
  gap: 7px;
  padding: 11px;
  border: 1px solid rgba(255, 255, 255, 0.07);
  border-radius: var(--radius);
  background: rgba(36, 50, 71, 0.52);
}

.metric-row.metric-risk {
  border-color: rgba(240, 68, 56, 0.32);
  background: rgba(240, 68, 56, 0.07);
}

.metric-head,
.effect-row {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  color: var(--muted);
  font-size: 0.9rem;
  line-height: 1.35;
}

.metric-head strong {
  color: var(--text);
  white-space: nowrap;
}

.stat-track {
  height: 7px;
  overflow: hidden;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.1);
}

.stat-fill {
  width: var(--value, 0%);
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, var(--accent), var(--accent-2));
  transition: width 220ms ease;
}

.metric-budget .stat-fill {
  background: linear-gradient(90deg, var(--warning), var(--success));
}

.metric-aiTokens .stat-fill {
  background: var(--accent-2);
}

.metric-risk .stat-fill {
  background: linear-gradient(90deg, var(--warning), var(--danger));
}

.result-card {
  display: grid;
  gap: 18px;
  max-width: 820px;
  margin: 0 auto;
}

.selected-choice {
  padding: 14px 16px;
  border: 1px solid rgba(6, 182, 212, 0.24);
  border-radius: var(--radius);
  color: var(--text);
  background: rgba(36, 50, 71, 0.78);
  font-weight: 700;
  line-height: 1.45;
  overflow-wrap: anywhere;
}

.effects-list {
  margin-bottom: 4px;
}

.effect-row {
  align-items: center;
  min-height: 46px;
  padding: 12px 14px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: rgba(36, 50, 71, 0.7);
}

.effect-row strong {
  white-space: nowrap;
}

.effect-positive {
  color: var(--success);
}

.effect-negative {
  color: var(--warning);
}

.effect-row.metric-risk .effect-positive {
  color: var(--danger);
}

.effect-row.metric-risk .effect-negative {
  color: var(--success);
}

.effect-row .effect-negative:is([class]) {
  text-shadow: none;
}

.final-card {
  display: grid;
  gap: 18px;
  max-width: 900px;
  margin: 0 auto;
  padding: 36px;
  text-align: center;
  background:
    linear-gradient(150deg, rgba(124, 58, 237, 0.15), transparent 38%),
    linear-gradient(330deg, rgba(6, 182, 212, 0.12), transparent 36%),
    rgba(24, 34, 48, 0.96);
  box-shadow: var(--shadow);
}

.ending-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  justify-self: center;
  width: 92px;
  height: 92px;
  border: 1px solid rgba(6, 182, 212, 0.35);
  border-radius: var(--radius);
  background: rgba(6, 182, 212, 0.08);
  color: var(--accent-2);
}

.ending-icon svg {
  width: 58px;
  height: 58px;
}

.launch-level {
  justify-self: center;
  width: fit-content;
  max-width: 100%;
  padding: 8px 12px;
  border: 1px solid rgba(18, 183, 106, 0.34);
  border-radius: var(--radius);
  color: var(--success);
  background: rgba(18, 183, 106, 0.09);
  font-weight: 800;
  overflow-wrap: anywhere;
}

.registrations {
  display: grid;
  gap: 4px;
  justify-items: center;
}

.registrations span {
  color: var(--text);
  font-family: "Montserrat", "Inter", sans-serif;
  font-size: 4.7rem;
  font-weight: 800;
  line-height: 0.96;
}

.registrations small,
.copy-status {
  color: var(--muted);
}

.final-card .scenario-text {
  justify-self: center;
}

.final-metrics {
  grid-template-columns: repeat(5, minmax(0, 1fr));
  text-align: left;
}

.final-metrics .metric-row {
  min-width: 0;
}

.final-actions {
  justify-content: center;
}

.copy-status {
  min-height: 22px;
  font-weight: 700;
}

@media (max-width: 1024px) {
  .site-header-inner {
    width: min(100% - 40px, var(--content));
    min-height: auto;
    padding: 18px 0;
    flex-direction: column;
    align-items: flex-start;
    gap: 16px;
  }

  .site-logo img {
    width: 204px;
  }

  .site-nav {
    width: 100%;
    justify-content: flex-start;
    gap: 12px;
    flex-wrap: wrap;
  }

  .site-nav a {
    min-height: 42px;
    display: inline-flex;
    align-items: center;
    border: 1px solid rgba(16, 24, 40, 0.1);
    border-radius: var(--radius);
    padding: 9px 12px;
    background: #F8FAFC;
    font-size: 0.98rem;
    white-space: normal;
  }

  .site-nav a::after {
    display: none;
  }

  h1 {
    font-size: 2.85rem;
  }

  h2 {
    font-size: 1.85rem;
  }

  .screen-start,
  .game-layout {
    grid-template-columns: 1fr;
  }

  .hero-card {
    min-height: auto;
  }

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

  .metrics-panel {
    position: static;
  }

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

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

@media (max-width: 760px) {
  .app-shell {
    width: min(100% - 24px, var(--content));
    padding: 18px 0;
  }

  .screen {
    min-height: calc(100vh - 36px);
  }

  h1 {
    font-size: 2.25rem;
  }

  h2 {
    font-size: 1.55rem;
  }

  .lead,
  .scenario-text,
  .scenario-dilemma {
    font-size: 1rem;
    line-height: 1.62;
  }

  .hero-card,
  .card {
    padding: 22px;
  }

  .hero-card {
    gap: 20px;
  }

  .top-bar {
    flex-direction: column;
    padding: 16px;
  }

  .top-bar-meta {
    justify-content: flex-start;
  }

  .info-grid,
  .choice-list,
  .metrics-list,
  .final-metrics {
    grid-template-columns: 1fr;
  }

  .choice-card {
    min-height: 112px;
  }

  .registrations span {
    font-size: 3.25rem;
  }

  .ending-icon {
    width: 78px;
    height: 78px;
  }

  .ending-icon svg {
    width: 50px;
    height: 50px;
  }
}

@media (max-width: 520px) {
  .site-header-inner {
    width: min(100% - 24px, var(--content));
    padding: 14px 0;
  }

  .site-logo img {
    width: 178px;
  }

  .site-nav {
    display: grid;
    grid-template-columns: 1fr;
  }

  .site-nav a {
    width: 100%;
    justify-content: center;
    text-align: center;
  }

  .app-shell {
    width: min(100% - 20px, var(--content));
    padding: 10px 0;
  }

  .screen {
    min-height: calc(100vh - 20px);
  }

  h1 {
    font-size: 2rem;
  }

  h2 {
    font-size: 1.35rem;
  }

  .eyebrow,
  .info-label {
    font-size: 0.72rem;
  }

  .hero-card,
  .card,
  .top-bar {
    padding: 16px;
  }

  .start-actions,
  .final-actions {
    width: 100%;
  }

  .button {
    width: 100%;
    min-height: 48px;
    padding: 12px 14px;
  }

  .button-small {
    min-height: 44px;
  }

  .top-bar-meta,
  .top-bar-meta span {
    width: 100%;
  }

  .top-bar-meta span {
    justify-content: center;
  }

  .choice-card {
    min-height: 104px;
    padding: 15px;
  }

  .metric-row {
    padding: 10px;
  }

  .metric-head,
  .effect-row {
    font-size: 0.86rem;
  }

  .effect-row {
    align-items: flex-start;
    flex-direction: column;
  }

  .final-card {
    padding: 18px 16px;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    scroll-behavior: auto !important;
    transition-duration: 1ms !important;
  }
}
