:root {
  --ink: #191c1f;
  --ink-2: #252b31;
  --white: #ffffff;
  --surface: rgba(255, 255, 255, 0.92);
  --surface-2: rgba(255, 255, 255, 0.72);
  --slate: #505a63;
  --muted: #8d969e;
  --line: rgba(25, 28, 31, 0.08);
  --blue: #494fdf;
  --blue-2: #6c87ff;
  --green: #00a87e;
  --green-2: #47d7a7;
  --red: #e23b4a;
  --red-2: #ff7f8f;
  --orange: #ec7e00;
  --gold: #d4a63a;
  --gold-2: #f0c85a;
  --radius-xl: 28px;
  --radius-lg: 22px;
  --radius-pill: 999px;
  --shadow-soft: 0 20px 60px rgba(25, 28, 31, 0.08);
  --shadow-strong: 0 28px 80px rgba(25, 28, 31, 0.14);
}

* {
  box-sizing: border-box;
}

html,
body {
  min-height: 100%;
}

body {
  margin: 0;
  font-family: Inter, -apple-system, BlinkMacSystemFont, "PingFang SC", sans-serif;
  color: var(--ink);
  background:
    radial-gradient(circle at 12% 8%, rgba(73, 79, 223, 0.14), transparent 28%),
    radial-gradient(circle at 82% 12%, rgba(0, 168, 126, 0.12), transparent 24%),
    radial-gradient(circle at 50% 100%, rgba(212, 166, 58, 0.1), transparent 30%),
    linear-gradient(180deg, #f7f8fb 0%, #eef1f4 48%, #e8ecf1 100%);
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  background-image:
    linear-gradient(rgba(25, 28, 31, 0.025) 1px, transparent 1px),
    linear-gradient(90deg, rgba(25, 28, 31, 0.025) 1px, transparent 1px);
  background-size: 32px 32px;
  mask-image: radial-gradient(circle at center, rgba(0, 0, 0, 0.7), transparent 92%);
  opacity: 0.45;
}

.landing-overlay,
.growth-modal,
.event-modal,
.settlement-overlay,
.fx-overlay {
  position: fixed;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 60;
}

.landing-overlay {
  background:
    radial-gradient(circle at top, rgba(73, 79, 223, 0.28), transparent 28%),
    linear-gradient(180deg, rgba(25, 28, 31, 0.94), rgba(37, 43, 49, 0.98));
  padding: 28px;
}

.landing-card {
  width: min(1160px, calc(100vw - 40px));
  max-height: calc(100vh - 56px);
  overflow: auto;
  padding: 32px;
  border-radius: 36px;
  background:
    radial-gradient(circle at top right, rgba(73, 79, 223, 0.1), transparent 34%),
    linear-gradient(180deg, rgba(255, 255, 255, 0.98), rgba(248, 249, 251, 0.98));
  border: 1px solid rgba(255, 255, 255, 0.5);
  box-shadow: var(--shadow-strong);
  backdrop-filter: blur(16px);
}

.landing-copy {
  margin-top: 14px;
  max-width: 860px;
  color: var(--slate);
  font-size: 16px;
  line-height: 1.75;
}

.landing-section {
  margin-top: 28px;
}

.landing-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
}

.landing-hint {
  color: var(--muted);
  font-size: 14px;
}

.landing-roles,
.landing-skills,
.landing-modes,
.landing-difficulties {
  display: grid;
  gap: 16px;
  margin-top: 18px;
}

.landing-modes {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

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

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

.landing-skills {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.landing-role,
.landing-skill,
.landing-mode,
.landing-difficulty,
.landing-match-card {
  position: relative;
  overflow: hidden;
  border-radius: 28px;
  background: rgba(25, 28, 31, 0.035);
  border: 1px solid transparent;
}

.landing-role,
.landing-skill,
.landing-mode,
.landing-difficulty {
  padding: 20px;
  cursor: pointer;
  transition: transform 180ms ease, border-color 180ms ease, box-shadow 180ms ease, background 180ms ease;
}

.landing-role::after,
.landing-skill::after,
.landing-mode::after,
.landing-difficulty::after {
  content: "";
  position: absolute;
  top: 0;
  right: 0;
  width: 96px;
  height: 96px;
  border-radius: 0 0 0 96px;
  background: linear-gradient(135deg, rgba(73, 79, 223, 0.18), rgba(108, 135, 255, 0.18));
  opacity: 0;
  transition: opacity 180ms ease;
}

.landing-role:hover,
.landing-skill:hover,
.landing-mode:hover,
.landing-difficulty:hover {
  transform: translateY(-2px);
  border-color: rgba(73, 79, 223, 0.16);
}

.landing-role.active,
.landing-skill.active,
.landing-mode.active,
.landing-difficulty.active {
  border-color: rgba(73, 79, 223, 0.44);
  background: linear-gradient(180deg, rgba(73, 79, 223, 0.08), rgba(255, 255, 255, 0.96));
  box-shadow: inset 0 0 0 1px rgba(73, 79, 223, 0.08), 0 16px 36px rgba(73, 79, 223, 0.08);
}

.landing-role.active::after,
.landing-skill.active::after,
.landing-mode.active::after,
.landing-difficulty.active::after {
  opacity: 1;
}

.landing-role h4,
.landing-skill h4,
.landing-mode h4,
.landing-difficulty h4 {
  margin: 0;
  font-size: 24px;
  font-weight: 700;
}

.landing-role p,
.landing-skill p,
.landing-mode p,
.landing-difficulty p {
  margin-top: 10px;
  color: var(--slate);
  font-size: 14px;
  line-height: 1.6;
}

.landing-match-card {
  margin-top: 18px;
  padding: 24px;
  background:
    radial-gradient(circle at top right, rgba(73, 79, 223, 0.1), transparent 42%),
    linear-gradient(180deg, rgba(73, 79, 223, 0.05), rgba(255, 255, 255, 0.96));
  border: 1px solid rgba(73, 79, 223, 0.24);
}

.landing-match-players {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
  margin-top: 18px;
}

.landing-match-player {
  padding: 14px 16px;
  border-radius: 18px;
  background: rgba(25, 28, 31, 0.04);
  color: var(--slate);
  font-size: 14px;
}

.landing-actions {
  margin-top: 32px;
  display: flex;
  justify-content: flex-end;
}

.hidden {
  display: none !important;
}

.app-shell {
  max-width: 1540px;
  margin: 0 auto;
  padding: 28px 28px 72px;
}

.topbar,
.phase-row,
.symbol-row,
.price-row,
.section-head,
.status-strip,
.asset-card-grid,
.position-meta,
.settlement-actions {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.topbar {
  margin-bottom: 20px;
}

.eyebrow {
  margin: 0 0 8px;
  font-size: 12px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--muted);
}

h1,
h2,
h3,
p {
  margin: 0;
}

h1 {
  font-size: 56px;
  letter-spacing: -0.04em;
}

.ghost-btn,
.trade-btn,
.phase-pill,
.role-chip,
.dev-chip,
.risk-chip,
.role-tab,
.pill-button {
  border: none;
  border-radius: var(--radius-pill);
}

.ghost-btn,
.pill-button,
.trade-btn,
.role-tab {
  cursor: pointer;
}

.ghost-btn {
  padding: 13px 18px;
  background: rgba(25, 28, 31, 0.08);
  color: var(--ink);
  font-weight: 700;
}

.hero-card,
.phase-rail-card,
.chart-card,
.smart-money-card,
.feed-card,
.metric-card,
.role-panel-card,
.trade-card,
.skill-card,
.strip-card,
.settlement-card {
  background: var(--surface);
  border-radius: 30px;
  box-shadow: var(--shadow-soft);
  border: 1px solid rgba(255, 255, 255, 0.56);
  backdrop-filter: blur(14px);
}

.hero-card {
  display: grid;
  grid-template-columns: 1.55fr 1fr;
  gap: 24px;
  padding: 32px;
  background:
    radial-gradient(circle at top right, rgba(73, 79, 223, 0.22), transparent 36%),
    radial-gradient(circle at bottom left, rgba(0, 168, 126, 0.14), transparent 34%),
    linear-gradient(180deg, #191c1f 0%, #252b31 100%);
  color: var(--white);
}

.phase-pill,
.role-chip,
.dev-chip,
.risk-chip {
  padding: 10px 16px;
  background: rgba(255, 255, 255, 0.12);
  color: var(--white);
  font-size: 13px;
  font-weight: 700;
}

.symbol-name {
  font-size: 44px;
  font-weight: 700;
  letter-spacing: -0.04em;
}

.price-row {
  margin-top: 14px;
}

.price-row strong {
  font-size: 78px;
  line-height: 0.95;
  letter-spacing: -0.05em;
}

.change {
  font-size: 26px;
  font-weight: 700;
}

.up {
  color: var(--green);
}

.down {
  color: var(--red);
}

.theme-copy {
  margin-top: 14px;
  color: rgba(255, 255, 255, 0.74);
  font-size: 16px;
}

.role-tabs {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  align-content: flex-start;
}

.role-tab {
  padding: 14px 18px;
  background: rgba(255, 255, 255, 0.12);
  color: var(--white);
  font-weight: 700;
}

.role-tab.active {
  background: var(--white);
  color: var(--ink);
}

.phase-banner,
.boss-banner,
.event-modal-card,
.growth-modal-card {
  border-radius: 30px;
  box-shadow: var(--shadow-strong);
}

.phase-banner {
  margin-top: 18px;
  padding: 18px 22px;
  color: var(--white);
  background: linear-gradient(135deg, var(--blue), var(--blue-2));
}

#endgameBanner {
  background: linear-gradient(135deg, #b3122d, var(--red));
}

.main-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.45fr) minmax(400px, 0.9fr);
  gap: 26px;
  margin-top: 24px;
}

.left-column,
.right-column {
  display: grid;
  gap: 24px;
  align-content: start;
}

.strip-card,
.phase-rail-card,
.chart-card,
.smart-money-card,
.feed-card,
.role-panel-card,
.trade-card,
.skill-card {
  padding: 24px;
}

.strip-card {
  display: flex;
  gap: 12px;
}

.strip-chip {
  flex: 1;
  padding: 14px 16px;
  border-radius: 20px;
}

.tone-neutral,
.tone-highlight {
  background: rgba(73, 79, 223, 0.08);
}

.tone-bull {
  background: rgba(0, 168, 126, 0.12);
}

.tone-bear,
.tone-warning {
  background: rgba(226, 59, 74, 0.12);
}

.strip-label,
.section-copy,
.metric-copy,
.trade-risk,
.guide-label,
.feed-item-body,
.info-label,
.info-subvalue {
  color: var(--slate);
}

.strip-label {
  font-size: 12px;
}

.strip-value {
  margin-top: 6px;
  font-weight: 700;
  font-size: 22px;
}

.phase-track,
.smart-money-track,
.position-bar,
.info-progress {
  height: 12px;
  margin-top: 16px;
  background: rgba(25, 28, 31, 0.08);
  border-radius: var(--radius-pill);
  overflow: hidden;
}

.phase-fill,
.smart-money-fill,
.position-fill,
.info-progress-fill {
  height: 100%;
  border-radius: inherit;
}

.phase-fill,
.position-fill,
.info-progress-fill.tone-neutral,
.info-progress-fill.tone-highlight {
  background: linear-gradient(90deg, var(--blue), var(--blue-2));
}

.smart-money-fill,
.info-progress-fill.tone-bull {
  background: linear-gradient(90deg, var(--green), var(--green-2));
}

.info-progress-fill.tone-bear,
.info-progress-fill.tone-warning {
  background: linear-gradient(90deg, #b3122d, var(--red));
}

.phase-items {
  display: flex;
  justify-content: space-between;
  gap: 8px;
  margin-top: 18px;
}

.phase-item {
  flex: 1;
  text-align: center;
}

.phase-item .dot {
  width: 10px;
  height: 10px;
  margin: 0 auto 8px;
  border-radius: 50%;
  background: rgba(25, 28, 31, 0.18);
}

.phase-item.active .dot {
  background: var(--blue);
  box-shadow: 0 0 0 8px rgba(73, 79, 223, 0.12);
}

.phase-item span {
  font-size: 12px;
  color: var(--muted);
}

.phase-item.active span {
  color: var(--ink);
  font-weight: 700;
}

.chart-card canvas {
  width: 100%;
  height: auto;
  margin-top: 18px;
  display: block;
  border-radius: 22px;
  background: linear-gradient(180deg, rgba(248, 249, 251, 0.9), rgba(243, 246, 250, 0.96));
}

.feed-list,
.role-info-list,
.skill-list,
.growth-list,
.settlement-list {
  display: grid;
  gap: 14px;
  margin-top: 16px;
}

.feed-item {
  padding: 16px;
  border-radius: 20px;
  background: rgba(25, 28, 31, 0.05);
  transition: transform 160ms ease, box-shadow 160ms ease;
}

.feed-item.head {
  box-shadow: inset 0 0 0 2px rgba(25, 28, 31, 0.06), 0 12px 30px rgba(25, 28, 31, 0.06);
  transform: translateY(-1px);
}

.feed-item-top {
  display: flex;
  justify-content: space-between;
  margin-bottom: 8px;
}

.feed-badge,
.growth-rarity {
  padding: 6px 12px;
  border-radius: var(--radius-pill);
  color: var(--white);
  font-size: 12px;
  font-weight: 700;
}

.feed-badge.tone-system {
  background: var(--blue);
}

.feed-badge.tone-bull {
  background: var(--green);
}

.feed-badge.tone-bear,
.feed-badge.tone-warning {
  background: var(--red);
}

.feed-tick {
  color: var(--muted);
  font-size: 12px;
}

.feed-item-title {
  font-size: 18px;
  font-weight: 700;
}

.metric-card {
  padding: 24px;
}

.metric-card h3 {
  margin-top: 10px;
  font-size: 38px;
}

.asset-card-grid {
  gap: 20px;
}

.asset-delta,
.position-meta {
  font-size: 13px;
  margin-top: 8px;
}

.trade-actions {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
  margin-top: 16px;
}

.trade-btn,
.pill-button {
  width: 100%;
  padding: 16px 20px;
  font-size: 16px;
  font-weight: 700;
  color: var(--white);
  background: linear-gradient(135deg, var(--blue), var(--blue-2));
}

.trade-btn.sell {
  background: linear-gradient(135deg, var(--ink), #383f47);
}

.pill-button.secondary {
  background: var(--white);
  color: var(--ink);
  border: 1px solid #d7dce0;
}

.trade-meta {
  margin-top: 8px;
  text-align: center;
  color: var(--slate);
  font-size: 13px;
}

.trade-risk {
  margin-top: 14px;
  font-size: 13px;
}

.skill-item,
.growth-card,
.info-item {
  padding: 18px;
  border-radius: 22px;
  background: rgba(25, 28, 31, 0.05);
}

.skill-item {
  position: relative;
  overflow: hidden;
  border: 1px solid transparent;
}

.skill-item::after {
  content: "";
  position: absolute;
  top: 0;
  right: 0;
  width: 92px;
  height: 92px;
  border-radius: 0 0 0 92px;
  opacity: 0.1;
}

.skill-tags {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  margin-top: 10px;
}

.skill-tag {
  padding: 4px 10px;
  border-radius: 999px;
  background: rgba(25, 28, 31, 0.08);
  color: var(--ink);
  font-size: 12px;
  font-weight: 700;
}

.skill-tag.resonance {
  background: rgba(0, 168, 126, 0.16);
  color: #00835f;
}

.skill-tag.cooldown {
  background: rgba(25, 28, 31, 0.06);
  color: var(--slate);
}

.skill-item.tier-s {
  border-color: rgba(212, 166, 58, 0.28);
  box-shadow: inset 0 0 0 1px rgba(212, 166, 58, 0.08), 0 14px 34px rgba(212, 166, 58, 0.08);
}

.skill-item.tier-s::after {
  background: linear-gradient(135deg, rgba(240, 200, 90, 1), rgba(212, 166, 58, 1));
}

.skill-item.tier-a {
  border-color: rgba(73, 79, 223, 0.24);
}

.skill-item.tier-a::after {
  background: linear-gradient(135deg, rgba(73, 79, 223, 1), rgba(108, 135, 255, 1));
}

.skill-item.tier-b {
  border-color: rgba(0, 168, 126, 0.22);
}

.skill-item.tier-b::after {
  background: linear-gradient(135deg, rgba(0, 168, 126, 1), rgba(71, 215, 167, 1));
}

.skill-item.has-resonance {
  border-style: dashed;
}

.skill-top,
.info-main {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.skill-name,
.growth-card-title,
.info-value {
  font-weight: 700;
}

.event-modal-card,
.growth-modal-card,
.settlement-card {
  width: min(560px, calc(100vw - 32px));
  padding: 28px;
  background: var(--white);
}

.settlement-overlay {
  background: rgba(25, 28, 31, 0.62);
}

.settlement-card {
  max-height: calc(100vh - 48px);
  overflow: auto;
}

.settlement-card section {
  margin-top: 20px;
}

.settlement-card h3 {
  margin-bottom: 10px;
  font-size: 20px;
}

.fx-overlay {
  pointer-events: none;
}

.fx-ring {
  width: 320px;
  height: 320px;
  border-radius: 50%;
  opacity: 0.22;
}

.fx-label {
  position: absolute;
  padding: 14px 22px;
  border-radius: var(--radius-pill);
  color: var(--white);
  font-weight: 700;
}

.fx-overlay.tone-blue .fx-ring,
.fx-overlay.tone-blue .fx-label {
  background: linear-gradient(135deg, rgba(73, 79, 223, 0.92), rgba(108, 135, 255, 0.92));
}

.fx-overlay.tone-red .fx-ring,
.fx-overlay.tone-red .fx-label {
  background: linear-gradient(135deg, rgba(179, 18, 45, 0.92), rgba(226, 59, 74, 0.92));
}

.fx-overlay.tone-green .fx-ring,
.fx-overlay.tone-green .fx-label {
  background: linear-gradient(135deg, rgba(0, 168, 126, 0.92), rgba(71, 215, 167, 0.92));
}

.fx-overlay.tone-gold .fx-ring,
.fx-overlay.tone-gold .fx-label {
  background: linear-gradient(135deg, rgba(212, 166, 58, 0.92), rgba(240, 200, 90, 0.92));
}

@media (max-width: 1100px) {
  .hero-card,
  .main-grid {
    grid-template-columns: 1fr;
  }

  .landing-roles,
  .landing-modes,
  .landing-difficulties,
  .landing-skills {
    grid-template-columns: 1fr;
  }

  .landing-match-players {
    grid-template-columns: 1fr;
  }
}
