:root {
  --bg: #06101f;
  --bg-soft: #0d1b32;
  --surface: rgba(255, 255, 255, 0.11);
  --surface-strong: rgba(255, 255, 255, 0.17);
  --line: rgba(255, 255, 255, 0.22);
  --text: #f6fbff;
  --muted: rgba(231, 242, 255, 0.68);
  --primary: #69e3ff;
  --secondary: #a78bfa;
  --accent: #4ade80;
  --danger: #fb7185;
  --shadow: 0 24px 80px rgba(0, 0, 0, 0.36);
  --radius-xl: 32px;
  --radius-lg: 24px;
  --radius-md: 18px;
  color-scheme: dark;
}

* {
  box-sizing: border-box;
}

html {
  min-height: 100%;
  scroll-behavior: smooth;
}

body {
  min-height: 100vh;
  margin: 0;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Microsoft YaHei", sans-serif;
  background:
    radial-gradient(circle at 20% 10%, rgba(105, 227, 255, 0.22), transparent 32rem),
    radial-gradient(circle at 82% 24%, rgba(167, 139, 250, 0.28), transparent 30rem),
    linear-gradient(135deg, #040814 0%, #07182d 48%, #0e1530 100%);
  color: var(--text);
  overflow-x: hidden;
}

body.light-bloom {
  --surface: rgba(255, 255, 255, 0.16);
  --surface-strong: rgba(255, 255, 255, 0.23);
  --line: rgba(255, 255, 255, 0.3);
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  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: 48px 48px;
  mask-image: linear-gradient(to bottom, black, transparent 78%);
}

svg {
  display: block;
  width: 1em;
  height: 1em;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
}

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

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

.ambient {
  position: fixed;
  width: 34rem;
  height: 34rem;
  border-radius: 999px;
  filter: blur(26px);
  opacity: 0.42;
  pointer-events: none;
  mix-blend-mode: screen;
  animation: float 12s ease-in-out infinite alternate;
}

.ambient-one {
  left: -12rem;
  top: 8rem;
  background: rgba(34, 211, 238, 0.42);
}

.ambient-two {
  right: -10rem;
  top: 2rem;
  background: rgba(168, 85, 247, 0.42);
  animation-delay: -4s;
}

.ambient-three {
  right: 12rem;
  bottom: -16rem;
  background: rgba(74, 222, 128, 0.28);
  animation-delay: -8s;
}

.shell {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: 292px minmax(0, 1fr);
  gap: 24px;
  width: min(1480px, calc(100% - 32px));
  min-height: calc(100vh - 32px);
  margin: 16px auto;
}

.sidebar,
.glass-panel {
  border: 1px solid var(--line);
  background: linear-gradient(145deg, var(--surface-strong), rgba(255, 255, 255, 0.07));
  box-shadow: var(--shadow), inset 0 1px 0 rgba(255, 255, 255, 0.24);
  backdrop-filter: blur(28px) saturate(160%);
  -webkit-backdrop-filter: blur(28px) saturate(160%);
}

.sidebar {
  position: sticky;
  top: 16px;
  height: calc(100vh - 32px);
  display: flex;
  flex-direction: column;
  padding: 22px;
  border-radius: var(--radius-xl);
  overflow: hidden;
}

.sidebar::after {
  content: "";
  position: absolute;
  inset: auto -30% -30% 10%;
  height: 240px;
  background: radial-gradient(circle, rgba(105, 227, 255, 0.28), transparent 62%);
  pointer-events: none;
}

.brand {
  display: flex;
  align-items: center;
  gap: 14px;
  padding-bottom: 22px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.14);
}

.brand-mark {
  display: grid;
  place-items: center;
  width: 54px;
  height: 54px;
  border-radius: 18px;
  color: white;
  background: linear-gradient(135deg, rgba(105, 227, 255, 0.95), rgba(167, 139, 250, 0.9));
  box-shadow: 0 14px 32px rgba(105, 227, 255, 0.24);
}

.brand-mark svg {
  width: 28px;
  height: 28px;
  stroke-width: 1.7;
}

.eyebrow {
  margin: 0 0 6px;
  color: var(--primary);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.brand h1,
.topbar h2,
.hero h2,
.module-card h3 {
  margin: 0;
}

.brand h1 {
  font-size: 18px;
  letter-spacing: -0.02em;
}

.nav-list {
  display: grid;
  gap: 8px;
  margin-top: 24px;
}

.nav-item {
  position: relative;
  display: flex;
  align-items: center;
  gap: 12px;
  min-height: 48px;
  padding: 0 14px;
  border: 1px solid transparent;
  border-radius: 16px;
  color: var(--muted);
  font-size: 15px;
  transition: transform 180ms ease, border-color 180ms ease, background 180ms ease, color 180ms ease;
}

.nav-item:hover,
.nav-item:focus-visible,
.nav-item.active {
  color: var(--text);
  border-color: rgba(255, 255, 255, 0.2);
  background: linear-gradient(135deg, rgba(105, 227, 255, 0.18), rgba(167, 139, 250, 0.12));
  outline: none;
}

.nav-item:hover {
  transform: translateX(3px);
}

.nav-item.active::before {
  content: "";
  position: absolute;
  left: -7px;
  width: 4px;
  height: 24px;
  border-radius: 99px;
  background: var(--primary);
  box-shadow: 0 0 22px var(--primary);
}

.nav-icon {
  display: grid;
  place-items: center;
  width: 28px;
  height: 28px;
  color: currentColor;
}

.nav-icon svg {
  width: 20px;
  height: 20px;
}

.sidebar-card {
  position: relative;
  z-index: 1;
  margin-top: auto;
  padding: 18px;
  border: 1px solid rgba(255, 255, 255, 0.16);
  border-radius: 22px;
  background: rgba(0, 0, 0, 0.18);
}

.sidebar-card p,
.sidebar-card span {
  margin: 0;
  color: var(--muted);
  font-size: 13px;
}

.sidebar-card strong {
  display: block;
  margin: 8px 0;
  color: var(--text);
  font-size: 20px;
}

.content {
  display: grid;
  gap: 20px;
  min-width: 0;
}

.topbar {
  position: sticky;
  top: 16px;
  z-index: 5;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  padding: 18px 22px;
  border-radius: var(--radius-lg);
}

.topbar h2 {
  font-size: clamp(22px, 3vw, 32px);
  letter-spacing: -0.04em;
}

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

.primary-button,
.ghost-button,
.ghost-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  padding: 0 18px;
  border-radius: 999px;
  font-weight: 700;
  transition: transform 180ms ease, box-shadow 180ms ease, background 180ms ease;
}

.primary-button {
  border: 0;
  color: #04101d;
  background: linear-gradient(135deg, #69e3ff, #9ef7c5);
  box-shadow: 0 14px 34px rgba(105, 227, 255, 0.28);
}

.ghost-button,
.ghost-link {
  border: 1px solid rgba(255, 255, 255, 0.18);
  color: var(--text);
  background: rgba(255, 255, 255, 0.08);
  cursor: pointer;
}

.primary-button:hover,
.ghost-button:hover,
.ghost-link:hover,
.primary-button:focus-visible,
.ghost-button:focus-visible,
.ghost-link:focus-visible {
  transform: translateY(-2px);
  outline: none;
}

.hero {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 1.2fr) minmax(260px, 0.8fr);
  gap: 24px;
  min-height: 360px;
  padding: clamp(24px, 5vw, 48px);
  border-radius: var(--radius-xl);
  overflow: hidden;
}

.hero::before {
  content: "";
  position: absolute;
  inset: -50% 20% auto auto;
  width: 500px;
  height: 500px;
  border-radius: 999px;
  background: radial-gradient(circle, rgba(105, 227, 255, 0.18), transparent 68%);
}

.hero-copy {
  position: relative;
  z-index: 1;
  align-self: center;
}

.status-pill {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  min-height: 34px;
  padding: 0 13px;
  border: 1px solid rgba(74, 222, 128, 0.28);
  border-radius: 999px;
  color: #bbf7d0;
  background: rgba(74, 222, 128, 0.1);
  font-size: 13px;
  font-weight: 700;
}

.status-pill i {
  width: 8px;
  height: 8px;
  border-radius: 99px;
  background: var(--accent);
  box-shadow: 0 0 18px var(--accent);
}

.hero h2 {
  max-width: 760px;
  margin-top: 20px;
  font-size: clamp(34px, 6vw, 72px);
  line-height: 0.98;
  letter-spacing: -0.07em;
}

.hero p {
  max-width: 680px;
  margin: 22px 0;
  color: var(--muted);
  font-size: 16px;
  line-height: 1.8;
}

.hero-orb {
  position: relative;
  display: grid;
  place-items: center;
  min-height: 280px;
}

.orb-core {
  width: 190px;
  height: 190px;
  border-radius: 48% 52% 44% 56% / 58% 44% 56% 42%;
  background:
    radial-gradient(circle at 35% 30%, rgba(255,255,255,0.95), transparent 18%),
    linear-gradient(135deg, rgba(105, 227, 255, 0.92), rgba(167, 139, 250, 0.78) 54%, rgba(74, 222, 128, 0.72));
  box-shadow: 0 0 80px rgba(105, 227, 255, 0.36), inset -22px -22px 44px rgba(5, 12, 24, 0.24);
  animation: morph 7s ease-in-out infinite alternate;
}

.orb-ring {
  position: absolute;
  border: 1px solid rgba(255, 255, 255, 0.22);
  border-radius: 999px;
}

.ring-one {
  width: 280px;
  height: 140px;
  transform: rotate(-24deg);
}

.ring-two {
  width: 320px;
  height: 170px;
  transform: rotate(28deg);
}

.metrics-grid,
.module-grid {
  display: grid;
  gap: 18px;
}

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

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

.metric-card,
.module-card,
.timeline {
  border-radius: var(--radius-lg);
}

.metric-card {
  padding: 20px;
}

.metric-card p,
.metric-card span,
.module-card p,
.timeline-item p {
  color: var(--muted);
}

.metric-card p,
.metric-card span {
  margin: 0;
  font-size: 13px;
}

.metric-card strong {
  display: block;
  margin: 10px 0;
  font-size: clamp(26px, 3vw, 42px);
  letter-spacing: -0.06em;
}

.module-card {
  min-height: 210px;
  padding: 22px;
  transition: transform 180ms ease, border-color 180ms ease, background 180ms ease;
}

.module-card:hover,
.module-card.focused {
  transform: translateY(-4px);
  border-color: rgba(105, 227, 255, 0.42);
  background: linear-gradient(145deg, rgba(105, 227, 255, 0.16), rgba(255, 255, 255, 0.08));
}

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

.module-head span {
  display: grid;
  place-items: center;
  width: 42px;
  height: 42px;
  border-radius: 14px;
  color: var(--primary);
  background: rgba(105, 227, 255, 0.12);
  font-weight: 800;
}

.module-card h3 {
  font-size: 22px;
}

.module-card p {
  min-height: 58px;
  margin: 18px 0 24px;
  line-height: 1.7;
}

.module-card a {
  color: var(--primary);
  font-weight: 800;
}

.timeline {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
  padding: 22px;
  margin-bottom: 16px;
}

.timeline-item {
  padding: 16px;
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.07);
}

.timeline-item b {
  color: var(--primary);
}

.timeline-item p {
  margin: 8px 0 0;
  line-height: 1.6;
}

@keyframes float {
  from { transform: translate3d(0, 0, 0) scale(1); }
  to { transform: translate3d(18px, -24px, 0) scale(1.08); }
}

@keyframes morph {
  0% { border-radius: 48% 52% 44% 56% / 58% 44% 56% 42%; transform: rotate(0deg) scale(1); }
  100% { border-radius: 58% 42% 55% 45% / 44% 56% 44% 56%; transform: rotate(8deg) scale(1.04); }
}

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

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

  .sidebar {
    position: relative;
    top: auto;
    height: auto;
  }

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

  .metrics-grid,
  .module-grid,
  .timeline {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 760px) {
  .shell {
    width: min(100% - 20px, 520px);
    margin: 10px auto;
  }

  .sidebar,
  .topbar,
  .hero,
  .metric-card,
  .module-card,
  .timeline {
    border-radius: 22px;
  }

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

  .topbar {
    position: relative;
    top: auto;
    align-items: flex-start;
    flex-direction: column;
  }

  .hero {
    min-height: auto;
  }

  .hero h2 {
    font-size: clamp(34px, 14vw, 54px);
  }

  .hero-orb {
    min-height: 220px;
  }

  .orb-core {
    width: 150px;
    height: 150px;
  }

  .ring-one {
    width: 230px;
    height: 120px;
  }

  .ring-two {
    width: 260px;
    height: 136px;
  }

  .nav-list,
  .metrics-grid,
  .module-grid,
  .timeline {
    grid-template-columns: 1fr;
  }

  .top-actions,
  .hero-actions {
    width: 100%;
  }

  .primary-button,
  .ghost-button,
  .ghost-link {
    width: 100%;
  }
}
