:root {
  color-scheme: dark;
  --bg: #050606;
  --bg-soft: #0c0f10;
  --panel: rgba(8, 10, 10, 0.82);
  --panel-strong: rgba(10, 12, 12, 0.94);
  --line: rgba(255, 245, 228, 0.18);
  --line-strong: rgba(255, 245, 228, 0.3);
  --text: #f7f1e6;
  --muted: rgba(247, 241, 230, 0.7);
  --soft: rgba(247, 241, 230, 0.52);
  --amber: #d2a86b;
  --amber-soft: rgba(210, 168, 107, 0.18);
  --sage: #86a89b;
  --card-shadow: 0 32px 80px rgba(0, 0, 0, 0.42);
  --radius: 24px;
  --radius-sm: 16px;
  --mono: "IBM Plex Mono", "SFMono-Regular", "Menlo", "Monaco", monospace;
  --serif: "Songti SC", "STSong", "Noto Serif SC", serif;
}

* {
  box-sizing: border-box;
}

html,
body {
  margin: 0;
  min-height: 100%;
  background:
    radial-gradient(circle at top center, rgba(210, 168, 107, 0.12), transparent 30%),
    radial-gradient(circle at 80% 22%, rgba(134, 168, 155, 0.12), transparent 20%),
    linear-gradient(180deg, #040505 0%, #070909 100%);
  color: var(--text);
}

body {
  position: relative;
  overflow: hidden;
  font-family: "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", sans-serif;
}

body.experience-started {
  overflow: auto;
}

a,
button,
input,
textarea {
  font: inherit;
}

button {
  border: 0;
  background: transparent;
  color: inherit;
}

.background-grid,
.background-noise,
.screen-scanlines {
  position: fixed;
  inset: 0;
  pointer-events: none;
}

.background-grid {
  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: 72px 72px;
  mask-image: radial-gradient(circle at center, black 42%, transparent 90%);
  opacity: 0.4;
}

.background-noise {
  opacity: 0.09;
  background-image:
    radial-gradient(circle at 20% 20%, rgba(255, 255, 255, 0.24) 0 1px, transparent 1px),
    radial-gradient(circle at 60% 72%, rgba(255, 255, 255, 0.18) 0 1px, transparent 1px);
  background-size: 18px 18px, 24px 24px;
  animation: drift-noise 18s linear infinite;
}

.screen-scanlines {
  opacity: 0.18;
  background: linear-gradient(
    to bottom,
    rgba(255, 255, 255, 0.07) 0,
    rgba(255, 255, 255, 0.01) 1px,
    transparent 2px,
    transparent 4px
  );
  background-size: 100% 4px;
}

.boot-screen {
  position: fixed;
  inset: 0;
  z-index: 5;
  display: grid;
  place-items: center;
  padding: 28px;
  background: rgba(4, 5, 5, 0.92);
  backdrop-filter: blur(12px);
  transition:
    opacity 0.7s ease,
    visibility 0.7s ease;
}

.boot-screen.is-hidden {
  opacity: 0;
  visibility: hidden;
}

.boot-panel {
  width: min(1120px, 100%);
  min-height: min(760px, calc(100vh - 56px));
  padding: 36px;
  border-radius: 32px;
  border: 1px solid var(--line);
  background:
    linear-gradient(180deg, rgba(16, 18, 18, 0.98), rgba(8, 10, 10, 0.92)),
    rgba(8, 10, 10, 0.9);
  box-shadow: var(--card-shadow);
  display: grid;
  grid-template-rows: auto 1fr auto;
  gap: 28px;
}

.boot-header,
.boot-footer,
.terminal-row,
.monitor-topbar,
.action-strip,
.boot-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.boot-kicker,
.card-label,
.card-note,
.boot-meta,
.view-button,
.status-pill,
.action-link,
.start-button,
.boot-log,
.clock-line {
  font-family: var(--mono);
}

.boot-kicker,
.card-label {
  margin: 0 0 10px;
  color: var(--sage);
  font-size: 0.75rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
}

.boot-header h1 {
  margin: 0;
  font-family: var(--serif);
  font-size: clamp(2.1rem, 4vw, 3.7rem);
  font-weight: 700;
  letter-spacing: 0.02em;
}

.boot-meta {
  flex-wrap: wrap;
  color: var(--soft);
  font-size: 0.85rem;
  justify-content: flex-end;
}

.boot-log {
  overflow: auto;
  padding: 28px;
  border-radius: 26px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  background:
    linear-gradient(180deg, rgba(4, 5, 5, 0.96), rgba(5, 8, 7, 0.84)),
    rgba(5, 5, 5, 0.9);
  color: var(--muted);
  font-size: 0.94rem;
  line-height: 1.9;
}

.boot-log p {
  margin: 0;
}

.boot-log p + p {
  margin-top: 6px;
}

.boot-note p {
  margin: 0;
  color: var(--soft);
  line-height: 1.7;
}

.start-button {
  min-width: 188px;
  min-height: 58px;
  padding: 0 22px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  border-radius: 18px;
  border: 1px solid var(--line-strong);
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.06), rgba(210, 168, 107, 0.12));
  color: var(--text);
  cursor: pointer;
  transition:
    transform 0.25s ease,
    border-color 0.25s ease,
    opacity 0.25s ease;
}

.start-button:disabled {
  cursor: not-allowed;
  opacity: 0.45;
}

.start-button:not(:disabled):hover {
  transform: translateY(-2px);
  border-color: rgba(210, 168, 107, 0.56);
}

.start-button-cursor {
  width: 10px;
  height: 14px;
  background: var(--amber);
  animation: blink 0.8s steps(1, end) infinite;
}

.landing-shell {
  position: relative;
  z-index: 1;
  min-height: 100vh;
  padding: 30px;
  opacity: 0;
  transform: translateY(18px);
  pointer-events: none;
  transition:
    opacity 0.7s ease 0.15s,
    transform 0.7s ease 0.15s;
}

.landing-shell.is-visible {
  opacity: 1;
  transform: translateY(0);
  pointer-events: auto;
}

.hero-layout {
  width: min(1480px, 100%);
  min-height: calc(100vh - 60px);
  margin: 0 auto;
  display: grid;
  grid-template-columns: minmax(280px, 0.95fr) minmax(620px, 1.48fr) minmax(280px, 1fr);
  gap: 24px;
  align-items: stretch;
}

.info-column,
.meta-column {
  display: grid;
  gap: 20px;
  align-content: start;
}

.monitor-column {
  display: grid;
  grid-template-rows: auto 1fr auto;
  gap: 18px;
  min-height: 0;
}

.terminal-card {
  position: relative;
  padding: 22px;
  border-radius: var(--radius);
  border: 1px solid var(--line);
  background:
    linear-gradient(180deg, rgba(15, 16, 16, 0.9), rgba(8, 10, 10, 0.82)),
    var(--panel);
  box-shadow: var(--card-shadow);
  overflow: hidden;
}

.terminal-card::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, rgba(210, 168, 107, 0.08), transparent 32%);
  pointer-events: none;
}

.intro-card h2 {
  margin: 0;
  min-height: 3.4em;
  font-family: var(--serif);
  font-size: clamp(2rem, 4vw, 3.3rem);
  line-height: 1.04;
  letter-spacing: 0.04em;
}

.typed-subline,
.typed-detail,
.clock-line,
.command-copy,
.monitor-title,
.scenario-grid p,
.signal-list,
.spec-list,
.module-list p {
  color: var(--muted);
}

.typed-subline {
  min-height: 1.6em;
  font-size: 1.06rem;
}

.typed-detail {
  min-height: 3.2em;
  line-height: 1.75;
}

.typed-line,
.clock-line {
  margin: 0;
}

.clock-line {
  font-size: 1.08rem;
}

.status-pill {
  display: inline-flex;
  align-items: center;
  min-height: 28px;
  padding: 0 12px;
  border-radius: 999px;
  border: 1px solid rgba(134, 168, 155, 0.38);
  background: rgba(134, 168, 155, 0.12);
  color: #dbece5;
  font-size: 0.78rem;
  letter-spacing: 0.08em;
}

.spec-list,
.signal-list {
  margin: 18px 0 0;
  padding: 0;
  list-style: none;
}

.spec-list li,
.signal-list li {
  padding: 12px 0;
  line-height: 1.72;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
}

.signal-list li:first-child,
.spec-list li:first-child {
  border-top: 0;
  padding-top: 0;
}

.monitor-topbar {
  padding: 10px 4px 0;
}

.monitor-title {
  margin: 6px 0 0;
  font-size: 0.98rem;
}

.view-switcher {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  justify-content: flex-end;
}

.view-button {
  min-height: 40px;
  padding: 0 14px;
  border-radius: 999px;
  border: 1px solid rgba(255, 245, 228, 0.14);
  background: rgba(255, 255, 255, 0.04);
  color: var(--muted);
  cursor: pointer;
  transition:
    transform 0.25s ease,
    border-color 0.25s ease,
    background 0.25s ease,
    color 0.25s ease;
}

.view-button:hover,
.view-button.is-active {
  transform: translateY(-1px);
  border-color: rgba(210, 168, 107, 0.5);
  background: rgba(210, 168, 107, 0.14);
  color: var(--text);
}

.monitor-shell {
  min-height: 0;
  display: grid;
  grid-template-rows: 1fr auto;
  justify-items: center;
  perspective: 1800px;
  --tilt-x: 0deg;
  --tilt-y: 0deg;
}

.monitor-frame {
  width: min(100%, 920px);
  height: 100%;
  min-height: 580px;
  padding: 18px 18px 22px;
  border-radius: 30px;
  background:
    linear-gradient(180deg, rgba(30, 34, 34, 0.95), rgba(12, 13, 13, 0.95)),
    #0d0f10;
  border: 1px solid rgba(255, 255, 255, 0.16);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.08),
    0 45px 110px rgba(0, 0, 0, 0.45);
  transform:
    perspective(1800px)
    rotateX(var(--tilt-x))
    rotateY(var(--tilt-y))
    translateZ(0);
  transition: transform 0.18s ease;
}

.monitor-bezel {
  position: relative;
  width: 100%;
  height: 100%;
  padding: 18px;
  border-radius: 22px;
  background: linear-gradient(180deg, rgba(4, 5, 5, 0.95), rgba(8, 10, 10, 0.98));
  overflow: hidden;
}

.monitor-bezel iframe {
  width: 100%;
  height: 100%;
  border: 0;
  border-radius: 12px;
  background: #0b0d0d;
  filter: saturate(0.96) contrast(1.02);
}

.monitor-glow {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(120deg, rgba(255, 255, 255, 0.22), transparent 18%, transparent 68%, rgba(255, 255, 255, 0.06)),
    radial-gradient(circle at top left, rgba(210, 168, 107, 0.12), transparent 30%);
  pointer-events: none;
  mix-blend-mode: screen;
}

.monitor-stand {
  margin-top: 4px;
  display: grid;
  justify-items: center;
  gap: 0;
}

.monitor-neck {
  width: 110px;
  height: 74px;
  border-radius: 0 0 32px 32px;
  background: linear-gradient(180deg, rgba(28, 31, 31, 0.95), rgba(11, 12, 12, 0.95));
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-top: 0;
}

.monitor-base {
  width: 230px;
  height: 26px;
  margin-top: -4px;
  border-radius: 999px;
  background: linear-gradient(180deg, rgba(31, 33, 33, 0.95), rgba(12, 13, 13, 0.98));
  border: 1px solid rgba(255, 255, 255, 0.12);
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.3);
}

.action-strip {
  flex-wrap: wrap;
  justify-content: center;
  gap: 12px;
}

.action-link {
  min-height: 46px;
  padding: 0 18px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  border: 1px solid rgba(255, 245, 228, 0.14);
  background: rgba(255, 255, 255, 0.04);
  color: var(--text);
  text-decoration: none;
  transition:
    transform 0.25s ease,
    border-color 0.25s ease,
    background 0.25s ease;
}

.action-link:hover {
  transform: translateY(-1px);
  border-color: rgba(210, 168, 107, 0.5);
}

.primary-link {
  background: linear-gradient(135deg, rgba(210, 168, 107, 0.22), rgba(134, 168, 155, 0.18));
  border-color: rgba(210, 168, 107, 0.4);
}

.module-list,
.scenario-grid {
  position: relative;
  z-index: 1;
}

.module-list {
  margin: 16px 0 0;
  padding: 0;
  list-style: none;
  display: grid;
  gap: 14px;
}

.module-list li {
  display: grid;
  grid-template-columns: 42px 1fr;
  gap: 14px;
  align-items: start;
}

.module-list span {
  width: 42px;
  height: 42px;
  display: grid;
  place-items: center;
  border-radius: 14px;
  border: 1px solid rgba(210, 168, 107, 0.26);
  background: rgba(210, 168, 107, 0.08);
  color: var(--amber);
  font-family: var(--mono);
  font-size: 0.84rem;
}

.module-list strong,
.scenario-grid strong {
  display: block;
  margin-bottom: 6px;
  color: var(--text);
}

.module-list p,
.scenario-grid p,
.command-copy {
  margin: 0;
  line-height: 1.74;
}

.scenario-grid {
  margin-top: 16px;
  display: grid;
  gap: 16px;
}

.scenario-grid div {
  padding: 15px 16px;
  border-radius: 18px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  background: rgba(255, 255, 255, 0.03);
}

.command-card {
  min-height: 172px;
}

.command-copy {
  margin-top: 16px;
}

@keyframes blink {
  0%,
  49% {
    opacity: 1;
  }

  50%,
  100% {
    opacity: 0;
  }
}

@keyframes drift-noise {
  from {
    transform: translate3d(0, 0, 0);
  }

  to {
    transform: translate3d(-18px, 14px, 0);
  }
}

@media (max-width: 1200px) {
  body,
  body.experience-started {
    overflow: auto;
  }

  .hero-layout {
    min-height: auto;
    grid-template-columns: 1fr;
  }

  .info-column,
  .meta-column,
  .monitor-column {
    order: initial;
  }

  .monitor-frame {
    min-height: 520px;
  }
}

@media (max-width: 768px) {
  .boot-screen,
  .landing-shell {
    padding: 16px;
  }

  .boot-panel,
  .terminal-card {
    padding: 18px;
    border-radius: 22px;
  }

  .boot-header,
  .boot-footer,
  .monitor-topbar,
  .terminal-row {
    align-items: flex-start;
    flex-direction: column;
  }

  .boot-meta,
  .view-switcher {
    justify-content: flex-start;
  }

  .boot-panel {
    min-height: calc(100vh - 32px);
  }

  .boot-log {
    padding: 18px;
    font-size: 0.84rem;
    line-height: 1.7;
  }

  .hero-layout {
    gap: 16px;
  }

  .intro-card h2 {
    min-height: auto;
    font-size: clamp(1.8rem, 8vw, 2.7rem);
  }

  .monitor-frame {
    min-height: 300px;
    padding: 12px 12px 16px;
    border-radius: 24px;
  }

  .monitor-bezel {
    padding: 10px;
  }

  .monitor-neck {
    display: none;
  }

  .monitor-base {
    display: none;
  }

  .view-button,
  .action-link,
  .start-button {
    width: 100%;
  }

  .action-strip {
    display: grid;
  }

  .scenario-grid div {
    padding: 14px;
  }
}

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