/* Laivikto · 白天默认主题 + 可切换的夜间主题。所有颜色都来自下面的变量。 */
:root,
[data-theme="light"] {
  --bg: #f7f9fc;
  --panel: #ffffff;
  --panel-2: #f1f4f8;
  --ink: #263238;
  --muted: #5f6b76;
  --accent: #168c9c;
  --accent-strong: #0e6e7b;
  --accent-soft: rgba(22, 140, 156, 0.1);
  --ok: #27845b;
  --wait: #6f6894;
  --err: #b4483c;
  --border: #dde4ea;
  --border-accent: rgba(22, 140, 156, 0.22);
  --line: #3a4a53;
  --line-soft: #9fb0ba;
  --flame: #e8893a;
  --flame-core: #f6c46a;
  --smoke: rgba(95, 107, 118, 0.16);
  --scan: rgba(38, 50, 56, 0.022);
  --glow: rgba(22, 140, 156, 0.09);
  --shadow: 0 1px 2px rgba(38, 50, 56, 0.05), 0 6px 20px rgba(38, 50, 56, 0.05);
  --focus: #0e6e7b;
  color-scheme: light;
}

[data-theme="dark"] {
  --bg: #151b20;
  --panel: #202930;
  --panel-2: #1a2228;
  --ink: #eef3f5;
  --muted: #b5c1c8;
  --accent: #3fb6c6;
  --accent-strong: #62cbd8;
  --accent-soft: rgba(63, 182, 198, 0.13);
  --ok: #62c493;
  --wait: #aea2d6;
  --err: #ec8579;
  --border: #38464e;
  --border-accent: rgba(63, 182, 198, 0.28);
  --line: #c9d5db;
  --line-soft: #6c7d86;
  --flame: #f0954a;
  --flame-core: #f8cf7c;
  --smoke: rgba(181, 193, 200, 0.18);
  --scan: rgba(255, 255, 255, 0.02);
  --glow: rgba(63, 182, 198, 0.08);
  --shadow: 0 1px 2px rgba(0, 0, 0, 0.25), 0 8px 24px rgba(0, 0, 0, 0.2);
  --focus: #62cbd8;
  color-scheme: dark;
}

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

[hidden] {
  display: none !important;
}

html {
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
}

body {
  margin: 0;
  min-height: 100vh;
  background: var(--bg);
  color: var(--ink);
  font-family: system-ui, -apple-system, "Segoe UI", "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", "Noto Sans CJK SC", "Source Han Sans SC", sans-serif;
  font-size: 16px;
  line-height: 1.65;
  transition: background-color 0.2s ease, color 0.2s ease;
}

/* 极淡的静态扫描线与偏上的淡青柔光（不动、不影响点击） */
body::before {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  background: repeating-linear-gradient(0deg, var(--scan) 0 1px, transparent 1px 5px);
  z-index: 0;
}
body::after {
  content: "";
  position: fixed;
  left: 50%;
  top: -12vmax;
  width: min(96vmax, 1080px);
  height: min(96vmax, 1080px);
  transform: translateX(-50%);
  border-radius: 50%;
  background: radial-gradient(circle, var(--glow), transparent 60%);
  pointer-events: none;
  z-index: 0;
}

.mono,
code,
.copy-value,
.st,
.log-panel,
.status-lines,
.metric-value,
.site-brand,
.brand-text,
.eyebrow,
.hero-title {
  font-family: ui-monospace, SFMono-Regular, "SF Mono", Menlo, Consolas, "Liberation Mono", "PingFang SC", "Microsoft YaHei", monospace;
}

a {
  color: var(--accent-strong);
  text-underline-offset: 3px;
}
a:hover {
  color: var(--accent);
}

:focus-visible {
  outline: 2px solid var(--focus);
  outline-offset: 2px;
  border-radius: 4px;
}

h1,
h2,
h3 {
  line-height: 1.3;
  margin: 0 0 0.5em;
  font-weight: 650;
}
h1 { font-size: clamp(1.6rem, 3.2vw, 2.1rem); }
h2 { font-size: 1.2rem; }
h3 { font-size: 1.02rem; }
p { margin: 0 0 0.8em; }

.icon {
  width: 1.15em;
  height: 1.15em;
  flex: none;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.9;
  stroke-linecap: round;
  stroke-linejoin: round;
  vertical-align: -0.2em;
}

.visually-hidden {
  position: absolute !important;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
}

.skip-link {
  position: absolute;
  left: 12px;
  top: -48px;
  z-index: 100;
  background: var(--panel);
  padding: 8px 12px;
  border: 1px solid var(--border);
  border-radius: 8px;
}
.skip-link:focus {
  top: 12px;
}

/* ---------- 按钮 ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.45em;
  min-height: 40px;
  padding: 0.45em 1em;
  border: 1px solid var(--border);
  border-radius: 9px;
  background: var(--panel);
  color: var(--ink);
  font: inherit;
  font-size: 0.95rem;
  font-weight: 550;
  line-height: 1.2;
  text-decoration: none;
  cursor: pointer;
  transition: border-color 0.15s ease, background-color 0.15s ease, color 0.15s ease;
}
.btn:hover {
  border-color: var(--accent);
  color: var(--ink);
}
.btn-primary {
  background: var(--accent-strong);
  border-color: var(--accent-strong);
  color: #fff;
}
[data-theme="dark"] .btn-primary {
  color: #10232a;
}
.btn-primary:hover {
  background: var(--accent);
  border-color: var(--accent);
  color: #fff;
}
[data-theme="dark"] .btn-primary:hover {
  color: #10232a;
}
.btn-ghost {
  background: transparent;
}
.btn-small {
  min-height: 34px;
  padding: 0.3em 0.8em;
  font-size: 0.88rem;
}
.btn-block {
  width: 100%;
}
.btn[disabled],
.btn[aria-disabled="true"] {
  opacity: 0.55;
  cursor: not-allowed;
}

.theme-toggle {
  display: inline-grid;
  place-items: center;
  width: 38px;
  height: 38px;
  border: 1px solid var(--border);
  border-radius: 50%;
  background: var(--panel);
  color: var(--ink);
  cursor: pointer;
  padding: 0;
}
.theme-toggle:hover {
  border-color: var(--accent);
}
.theme-toggle .icon {
  width: 18px;
  height: 18px;
  vertical-align: 0;
}
.theme-toggle .icon-moon,
[data-theme="dark"] .theme-toggle .icon-sun {
  display: none;
}
[data-theme="dark"] .theme-toggle .icon-moon {
  display: block;
}

/* ---------- 页头 ---------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 20;
  background: color-mix(in srgb, var(--bg) 88%, transparent);
  border-bottom: 1px solid var(--border);
  backdrop-filter: blur(8px);
}
.header-inner {
  max-width: 1080px;
  margin: 0 auto;
  padding: 10px 20px;
  display: flex;
  align-items: center;
  gap: 18px;
}
.site-brand {
  font-weight: 700;
  font-size: 1.1rem;
  letter-spacing: 0.04em;
  color: var(--ink);
  text-decoration: none;
}
.site-nav {
  display: flex;
  gap: 4px;
  flex-wrap: wrap;
}
.site-nav a {
  padding: 6px 10px;
  border-radius: 8px;
  color: var(--muted);
  text-decoration: none;
  font-size: 0.94rem;
}
.site-nav a:hover,
.site-nav a[aria-current="page"] {
  color: var(--ink);
  background: var(--accent-soft);
}
.header-actions {
  margin-left: auto;
  display: flex;
  align-items: center;
  gap: 10px;
}
.account {
  display: flex;
  align-items: center;
  gap: 8px;
}
.account-name {
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 0.9rem;
  color: var(--ink);
}
.inline-form {
  display: inline;
  margin: 0;
}

/* ---------- 主体 ---------- */
.site-main {
  position: relative;
  z-index: 1;
  max-width: 1080px;
  margin: 0 auto;
  padding: 28px 20px 56px;
}
.site-footer {
  position: relative;
  z-index: 1;
  border-top: 1px solid var(--border);
}
.footer-inner {
  max-width: 1080px;
  margin: 0 auto;
  padding: 18px 20px;
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  justify-content: space-between;
  color: var(--muted);
  font-size: 0.88rem;
}
.footer-links {
  display: flex;
  gap: 16px;
}

.eyebrow {
  margin: 0 0 0.3em;
  font-size: 0.72rem;
  letter-spacing: 0.16em;
  color: var(--accent-strong);
  text-transform: uppercase;
}
.lead {
  font-size: 1.06rem;
}
.muted {
  color: var(--muted);
}
.small {
  font-size: 0.86rem;
}
.pre {
  white-space: pre-wrap;
  overflow-wrap: anywhere;
}
.nowrap {
  white-space: nowrap;
}

.hero {
  padding: 28px 0 22px;
}
.hero-title {
  font-size: clamp(2.6rem, 9vw, 4.4rem);
  font-weight: 700;
  letter-spacing: 0.06em;
  margin: 0 0 0.15em;
  line-height: 1.1;
}
.hero-title::after {
  content: "";
  display: block;
  width: 64px;
  height: 2px;
  margin-top: 14px;
  background: var(--accent);
  border-radius: 2px;
}
.hero-sub {
  color: var(--muted);
  font-size: 1.05rem;
  max-width: 36em;
}
.page-head {
  padding: 12px 0 8px;
}

.panel {
  background: var(--panel);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 22px;
  margin: 0 0 20px;
  box-shadow: var(--shadow);
}
.panel-head {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 10px;
  flex-wrap: wrap;
}
.panel-head h2 {
  margin: 0;
}
.panel-icon,
.card-icon {
  display: inline-grid;
  place-items: center;
  width: 36px;
  height: 36px;
  border-radius: 10px;
  background: var(--accent-soft);
  color: var(--accent-strong);
}
.panel h2 .icon {
  margin-right: 6px;
  color: var(--accent-strong);
}
.tag {
  margin-left: auto;
  font-size: 0.72rem;
  letter-spacing: 0.12em;
  padding: 2px 8px;
  border: 1px solid var(--border-accent);
  border-radius: 999px;
  color: var(--accent-strong);
  text-transform: uppercase;
}

.state-line {
  display: flex;
  gap: 10px;
  align-items: baseline;
  margin: 0.4em 0 0.8em;
}
.st {
  flex: none;
  min-width: 3.5rem;
  font-size: 0.86rem;
  font-weight: 600;
}
.st-ok { color: var(--ok); }
.st-wait { color: var(--wait); }
.st-err { color: var(--err); }

.locked {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px 18px;
  padding-top: 6px;
  border-top: 1px dashed var(--border);
}
.locked .state-line {
  margin: 0.5em 0;
}

.address-block {
  border-top: 1px dashed var(--border);
  padding-top: 12px;
}
.copy-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px 10px;
  margin: 0 0 10px;
}
.copy-label {
  min-width: 5.5em;
  color: var(--muted);
  font-size: 0.92rem;
}
.copy-value {
  flex: 1 1 220px;
  min-width: 0;
  min-height: 40px;
  padding: 6px 10px;
  border: 1px solid var(--border);
  border-radius: 8px;
  background: var(--panel-2);
  color: var(--ink);
  font-size: 0.95rem;
}
.copy-status {
  min-height: 1.4em;
  margin: 0 0 6px;
  font-size: 0.9rem;
}
.copy-status.is-ok { color: var(--ok); }
.copy-status.is-err { color: var(--err); }
.steps {
  margin: 10px 0 0;
  padding-left: 1.3em;
  color: var(--muted);
}

/* 卡片 */
.cards {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(230px, 1fr));
  gap: 16px;
  margin: 0 0 20px;
}
.card {
  display: flex;
  flex-direction: column;
  gap: 4px;
  background: var(--panel);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 18px;
  box-shadow: var(--shadow);
}
.card h3 {
  margin: 8px 0 0;
}
.card p {
  flex: 1;
}
.card-link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-weight: 550;
  text-decoration: none;
}
.card-state {
  color: var(--muted);
  font-size: 0.9rem;
}
.card-off .card-icon {
  background: var(--panel-2);
  color: var(--muted);
}
.text-link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

/* 真实状态日志 */
.status-panel {
  font-size: 0.95rem;
}
.log-head {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  font-size: 0.68rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--muted);
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
}
.log-head.static {
  padding-bottom: 10px;
  margin-bottom: 8px;
  border-bottom: 1px solid var(--border);
}
/* 开场页的日志头部随正文一起放大 */
.intro .log-head {
  font-size: 0.95rem;
  letter-spacing: 0.16em;
}
.status-lines {
  list-style: none;
  margin: 0 0 10px;
  padding: 0;
  line-height: 1.95;
  font-size: 0.86rem;
}
.status-lines li {
  display: flex;
  gap: 10px;
}

/* 通知 */
.notice {
  padding: 10px 14px;
  border-radius: 10px;
  border: 1px solid var(--border);
  background: var(--panel);
  margin: 0 0 16px;
  font-size: 0.95rem;
}
.notice-ok { border-color: color-mix(in srgb, var(--ok) 45%, transparent); color: var(--ok); }
.notice-error { border-color: color-mix(in srgb, var(--err) 45%, transparent); color: var(--err); }
.notice-info { border-color: var(--border-accent); color: var(--accent-strong); }

/* 表单 */
.narrow {
  max-width: 440px;
  margin: 12px auto 0;
}
.form {
  display: grid;
  gap: 14px;
}
.form-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}
.span-2 {
  grid-column: 1 / -1;
}
.field {
  display: grid;
  gap: 6px;
  font-size: 0.93rem;
  min-width: 0;
}
.field > span:first-child {
  color: var(--muted);
}
.field input,
.field select,
.field textarea,
.input-small {
  width: 100%;
  min-height: 42px;
  padding: 8px 11px;
  border: 1px solid var(--border);
  border-radius: 9px;
  background: var(--panel-2);
  color: var(--ink);
  font: inherit;
}
.field textarea {
  resize: vertical;
}
.field input:focus,
.field select:focus,
.field textarea:focus,
.input-small:focus {
  border-color: var(--accent);
  outline: 2px solid var(--accent-soft);
  outline-offset: 0;
}
.field [aria-invalid="true"] {
  border-color: var(--err);
}
.field-error {
  color: var(--err);
}
.field.check,
.check {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}
.check input {
  width: 18px;
  height: 18px;
  min-height: 0;
  accent-color: var(--accent-strong);
}
.checks {
  border: 1px solid var(--border);
  border-radius: 9px;
  padding: 10px 14px;
  display: flex;
  flex-wrap: wrap;
  gap: 8px 20px;
}
.checks legend {
  color: var(--muted);
  padding: 0 4px;
}
.password-wrap {
  display: flex;
  gap: 8px;
}
.password-wrap input {
  flex: 1;
}
.actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 8px;
}

.contact-grid {
  display: grid;
  grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.1fr);
  gap: 20px;
  align-items: start;
}
.contact-grid h2 {
  display: flex;
  align-items: center;
}
.qr {
  display: block;
  margin: 8px 0 12px;
  border-radius: 8px;
  border: 1px solid var(--border);
  background: #fff;
}

.empty-state {
  text-align: center;
  padding: 44px 22px;
}
.empty-state .actions {
  justify-content: center;
}
.empty-icon {
  display: inline-grid;
  place-items: center;
  width: 56px;
  height: 56px;
  border-radius: 16px;
  background: var(--accent-soft);
  color: var(--accent-strong);
  margin-bottom: 12px;
}
.empty-icon .icon {
  width: 26px;
  height: 26px;
}
.prose ul {
  padding-left: 1.2em;
}

/* ---------- 后台 ---------- */
.admin-head {
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  gap: 12px;
  margin-bottom: 14px;
}
.admin-head h1 {
  margin: 0;
}
.admin-tabs {
  display: flex;
  gap: 4px;
  overflow-x: auto;
  border-bottom: 1px solid var(--border);
  margin: 0 0 18px;
}
.admin-tabs a {
  padding: 9px 12px;
  color: var(--muted);
  text-decoration: none;
  white-space: nowrap;
  border-bottom: 2px solid transparent;
  margin-bottom: -1px;
}
.admin-tabs a[aria-current="page"] {
  color: var(--ink);
  border-bottom-color: var(--accent);
}
.badge {
  display: inline-block;
  min-width: 1.5em;
  padding: 0 6px;
  border-radius: 999px;
  background: var(--accent-strong);
  color: #fff;
  font-size: 0.75rem;
  text-align: center;
}
[data-theme="dark"] .badge {
  color: #10232a;
}
.monitor-head {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 10px;
  margin-bottom: 6px;
}
.monitor-head h2 {
  margin: 0;
}
.env-badge {
  font-size: 0.78rem;
  padding: 2px 9px;
  border-radius: 999px;
  border: 1px solid;
}
.env-dev {
  color: var(--wait);
}
.env-prod {
  color: var(--ok);
}
.conn-line {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 4px 10px;
  padding: 8px 0 12px;
  border-bottom: 1px dashed var(--border);
  margin-bottom: 14px;
}
.metric-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
  gap: 12px;
  margin-bottom: 16px;
}
.metric {
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 12px 14px;
  background: var(--panel-2);
}
.metric h3 {
  margin: 0 0 2px;
  font-size: 0.82rem;
  color: var(--muted);
  font-weight: 600;
}
.metric-value {
  margin: 0;
  font-size: 1.4rem;
  font-weight: 650;
  font-variant-numeric: tabular-nums;
}
.metric-sub {
  margin: 0;
  font-size: 0.8rem;
  color: var(--muted);
  overflow-wrap: anywhere;
}
.metric.is-na .metric-value {
  color: var(--muted);
  font-size: 1.05rem;
}
.monitor.is-stale .metric-value {
  color: var(--muted);
}
.chart-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 12px;
}
.chart {
  margin: 0;
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 10px 12px;
}
.chart figcaption {
  font-size: 0.82rem;
  color: var(--muted);
  margin-bottom: 4px;
}
.spark {
  display: block;
  width: 100%;
  height: 80px;
}
.spark .grid {
  stroke: var(--border);
  stroke-width: 1;
  vector-effect: non-scaling-stroke;
}
.spark .series {
  fill: none;
  stroke: var(--accent);
  stroke-width: 1.9;
  vector-effect: non-scaling-stroke;
  stroke-linejoin: round;
}
.spark .series.alt {
  stroke: var(--wait);
}
.services-list {
  list-style: none;
  padding: 0;
  margin: 12px 0 0;
  font-size: 0.9rem;
}

.filter-bar {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 14px;
}
.chip {
  padding: 4px 12px;
  border: 1px solid var(--border);
  border-radius: 999px;
  text-decoration: none;
  color: var(--muted);
  font-size: 0.88rem;
}
.chip[aria-current="true"] {
  border-color: var(--accent);
  color: var(--ink);
  background: var(--accent-soft);
}
.table-wrap {
  overflow-x: auto;
}
.table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.92rem;
}
.table th,
.table td {
  text-align: left;
  padding: 9px 10px;
  border-bottom: 1px solid var(--border);
  vertical-align: top;
}
.table th {
  font-size: 0.8rem;
  color: var(--muted);
  font-weight: 600;
}
.clip {
  max-width: 320px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.status {
  font-size: 0.82rem;
  padding: 1px 8px;
  border-radius: 999px;
  border: 1px solid;
  white-space: nowrap;
}
.status-pending { color: var(--wait); }
.status-done { color: var(--ok); }
.status-rejected { color: var(--err); }
.inline-checks {
  display: flex;
  flex-wrap: wrap;
  gap: 6px 12px;
  align-items: center;
}
.reset-form {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
}
.input-small {
  min-height: 34px;
  width: 150px;
  padding: 4px 8px;
  font-size: 0.86rem;
}
.dl {
  display: grid;
  grid-template-columns: 7em 1fr;
  gap: 8px 14px;
  margin: 0 0 18px;
}
.dl dt {
  color: var(--muted);
}
.dl dd {
  margin: 0;
}
.empty-line {
  color: var(--muted);
  padding: 18px 0;
  margin: 0;
}

/* =====================================================================
   开场：五行模拟日志 → 飞机起飞与火箭升空 → Laivikto 品牌入口
   默认（无 JS / 已播放 / 减少动态）直接显示可点击的品牌入口
   ===================================================================== */
.intro-body {
  overflow: hidden;
}
.intro {
  position: relative;
  z-index: 1;
  min-height: 100vh;
  min-height: 100svh;
  display: grid;
  place-items: center;
  padding: 64px 16px 32px;
}
.intro-controls {
  position: fixed;
  top: 14px;
  right: 14px;
  z-index: 10;
  display: flex;
  gap: 10px;
  align-items: center;
}
.intro-stage {
  position: relative;
  width: min(1536px, 100%);
  display: grid;
  place-items: center;
}
.intro-stage > * {
  grid-area: 1 / 1;
}

.scene {
  width: 100%;
  height: auto;
  overflow: hidden;
  opacity: 0.55;
}
.scene path:not(.draw),
.scene circle {
  vector-effect: non-scaling-stroke;
}
.scene .draw,
.scene .runway-center {
  fill: none;
  stroke: var(--line);
  stroke-width: 1.9;
  stroke-linecap: round;
  stroke-linejoin: round;
}
.scene .runway-edge,
.scene .runway-mark {
  stroke: var(--line-soft);
}
.scene .runway-center {
  stroke: var(--line-soft);
  stroke-dasharray: 14 12;
  stroke-width: 1.4;
}
.scene .pad,
.scene .tower {
  stroke: var(--line);
}
.scene-label {
  fill: var(--muted);
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 11px;
  letter-spacing: 0.14em;
}
.scene .puff {
  fill: var(--smoke);
  stroke: none;
  opacity: 0;
}
.scene .plane-trail {
  fill: none;
  stroke: var(--accent);
  stroke-width: 1.4;
  stroke-linecap: round;
  opacity: 0;
}
.scene .rocket-body {
  fill: var(--panel);
  stroke: var(--line);
  stroke-width: 1.9;
  stroke-linejoin: round;
}
.scene .rocket-line {
  fill: none;
  stroke: var(--line);
  stroke-width: 1.2;
}
.scene .flame {
  fill: var(--flame);
  opacity: 0;
}
.scene .flame-core {
  fill: var(--flame-core);
  opacity: 0;
}
.scene .plane-body,
.scene .plane-wing {
  fill: var(--panel);
  stroke: var(--line);
  stroke-width: 1.9;
  stroke-linejoin: round;
}
.scene .plane-fin {
  fill: var(--panel);
  stroke: var(--line);
  stroke-width: 1.9;
  stroke-linejoin: round;
}
.scene .plane-detail {
  fill: none;
  stroke: var(--line);
  stroke-width: 1.4;
  stroke-linecap: round;
}
.scene .plane-wheel {
  fill: var(--line);
}

/* 日志面板（仅在播放时出现） */
.log-panel {
  position: relative;
  width: min(728px, 92%);
  margin: 0 auto;
  justify-self: center;
  align-self: center;
  border: 1px solid var(--border-accent);
  border-radius: 12px;
  background: color-mix(in srgb, var(--panel) 92%, transparent);
  box-shadow: var(--shadow);
  padding: 16px 24px 18px;
  overflow: hidden;
  display: none;
  z-index: 2;
}
.log-flag {
  color: var(--wait);
  letter-spacing: 0.06em;
}
.log-lines {
  list-style: none;
  margin: 12px 0 0;
  padding: 12px 0 0;
  border-top: 1px solid var(--border);
  font-size: 1.2rem;
  line-height: 2;
}
.log-line {
  display: flex;
  min-height: 2em;
}
.log-st {
  flex: none;
  width: 4.9rem;
  color: var(--wait);
}
.log-line.is-ok .log-st {
  color: var(--ok);
}
.log-cursor {
  display: inline-block;
  width: 0.55em;
  height: 1.05em;
  margin-left: 4px;
  vertical-align: -0.17em;
  background: var(--accent);
  animation: lv-blink 1.06s step-end infinite;
}
@keyframes lv-blink {
  50% { opacity: 0; }
}
.log-shock {
  position: absolute;
  left: 50%;
  top: 50%;
  width: 360px;
  height: 360px;
  margin: -180px 0 0 -180px;
  border-radius: 50%;
  border: 1px solid var(--accent);
  background: radial-gradient(circle, var(--accent-soft), transparent 65%);
  opacity: 0;
  pointer-events: none;
}

/* 品牌入口 */
.brand-wrap {
  position: relative;
  z-index: 3;
  display: grid;
  justify-items: center;
  gap: 8px;
  margin-top: -6%;
}
.brand-link {
  display: inline-block;
  padding: 4px 12px;
  color: var(--ink);
  text-decoration: none;
  border-radius: 10px;
}
.brand-link:hover {
  color: var(--ink);
}
.brand-link:focus-visible {
  outline-offset: 6px;
}
.brand-text {
  display: inline-block;
  font-size: clamp(2.6rem, 10vw, 5.6rem);
  font-weight: 700;
  letter-spacing: 0.08em;
  line-height: 1.05;
}
.brand-text .ch {
  display: inline-block;
}
.brand-line {
  display: block;
  width: 64px;
  height: 2px;
  border-radius: 2px;
  background: var(--accent);
  transform-origin: 50% 50%;
}
.enter-hint {
  margin: 4px 0 0;
  color: var(--muted);
  font-size: 0.9rem;
  letter-spacing: 0.08em;
}
.brand-link:hover ~ .enter-hint,
.brand-link:focus-visible ~ .enter-hint {
  color: var(--accent-strong);
}

/* 静态 / 就绪：飞机与火箭已离开画面，只留跑道与发射台 */
.intro[data-state="ready"] .plane,
.intro[data-state="ready"] .rocket,
.intro[data-state="entered"] .plane,
.intro[data-state="entered"] .rocket {
  display: none;
}
.intro[data-state="entered"] .brand-wrap {
  transition: opacity 0.22s cubic-bezier(.2, .8, .25, 1), transform 0.22s cubic-bezier(.2, .8, .25, 1);
  opacity: 0;
  transform: translateY(-10px) scale(0.97);
}

/* 播放中：由 intro.js 逐帧写入透明度与位移 */
.intro[data-state="playing"] .log-panel {
  display: block;
}
.intro[data-state="playing"] .brand-link {
  pointer-events: none;
}

/* 脚本尚未运行时（theme-init.js 已决定要播放），先隐藏品牌入口与场景，避免闪烁 */
.intro-pending .intro[data-state="static"] .brand-wrap,
.intro-pending .intro[data-state="static"] .scene {
  visibility: hidden;
}
.intro-pending .intro[data-state="static"] .log-panel {
  display: block;
}

@media (max-width: 480px) {
  .intro {
    padding: 72px 10px 24px;
  }
  .log-panel {
    padding: 10px 12px 12px;
    width: min(520px, 100%);
  }
  .log-lines {
    font-size: 0.79rem;
    margin: 10px 0 0;
    padding: 10px 0 0;
    line-height: 1.95;
  }
  .log-head,
  .intro .log-head {
    font-size: 0.62rem;
    letter-spacing: 0.1em;
  }
  .log-st {
    width: 3.5rem;
  }
  .intro-stage {
    width: min(960px, 100%);
  }
  .log-line {
    min-height: 1.95em;
  }
  .brand-wrap {
    margin-top: -10%;
  }
  .brand-text {
    font-size: clamp(2.3rem, 13vw, 3.4rem);
  }
}

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

/* ---------- 响应式 ---------- */
@media (max-width: 760px) {
  .contact-grid,
  .form-grid {
    grid-template-columns: minmax(0, 1fr);
  }
  .header-inner {
    flex-wrap: wrap;
    gap: 6px 12px;
    padding: 8px 14px;
  }
  .site-nav {
    order: 3;
    width: 100%;
    overflow-x: auto;
    flex-wrap: nowrap;
    margin: 0 -6px;
  }
  .site-nav a {
    white-space: nowrap;
  }
  .site-main {
    padding: 18px 14px 40px;
  }
  .panel {
    padding: 16px;
  }
  .admin-head {
    flex-wrap: wrap;
  }
  .dl {
    grid-template-columns: 1fr;
  }
  .dl dt {
    margin-top: 6px;
  }
}
