:root {
  --bg: #f3f6fb;
  --surface: rgba(255, 255, 255, .72);
  --surface-2: rgba(247, 249, 252, .78);
  --text: #172033;
  --muted: #687184;
  --line: rgba(120, 139, 168, .22);
  --accent: #3f7cff;
  --accent-3: #19c7b8;
  --accent-2: #ff6b88;
  --gold: #c98d2b;
  --ink: #111827;
  --shadow: 0 28px 80px rgba(51, 70, 102, 0.12);
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  background:
    linear-gradient(115deg, rgba(12, 20, 36, .04) 0%, transparent 28%),
    radial-gradient(circle at 12% 6%, rgba(63, 124, 255, .22), transparent 30%),
    radial-gradient(circle at 86% 10%, rgba(25, 199, 184, .18), transparent 28%),
    radial-gradient(circle at 50% 0%, rgba(255, 255, 255, .9), transparent 38%),
    linear-gradient(180deg, #fbfcff 0%, #f5f7fb 44%, #ffffff 100%);
  color: var(--text);
  font-family: ui-sans-serif, -apple-system, BlinkMacSystemFont, "SF Pro Display", "SF Pro Text", Inter, "Segoe UI", sans-serif;
}

html {
  scroll-behavior: smooth;
}

.ambient {
  position: fixed;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  background: radial-gradient(circle at 50% 0%, rgba(255, 255, 255, .9), transparent 45%);
  mask-image: linear-gradient(180deg, #000 0%, transparent 70%);
}

.side-nav {
  position: fixed;
  left: 16px;
  top: 110px;
  z-index: 20;
  width: 132px;
  padding: 10px;
  border: 1px solid rgba(255, 255, 255, 0.78);
  background: rgba(255, 255, 255, 0.62);
  box-shadow: var(--shadow);
  backdrop-filter: blur(14px);
  border-radius: 20px;
  transition: opacity .16s ease, transform .16s ease, box-shadow .16s ease;
}

.side-title {
  margin-bottom: 8px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 900;
}

.side-nav a {
  display: flex;
  align-items: center;
  gap: 7px;
  padding: 9px 8px;
  color: var(--text);
  font-size: 13px;
  font-weight: 800;
  text-decoration: none;
  border-left: 3px solid transparent;
  border-radius: 12px;
}

.side-nav a::before {
  content: "";
  flex: 0 0 auto;
  width: 7px;
  height: 7px;
  border-radius: 999px;
  background: rgba(63,124,255,.34);
}

.side-nav a:hover,
.side-nav a.active {
  background: rgba(63, 124, 255, .1);
  color: var(--accent);
  border-left-color: var(--accent);
}

body.scrolled .side-nav {
  top: 76px;
  width: 104px;
  padding: 8px;
  opacity: .92;
  box-shadow: 0 14px 34px rgba(29,43,76,.1);
}

body.scrolled .side-nav a {
  min-height: 30px;
  padding: 7px 8px;
  color: rgba(23,32,51,.84);
  font-size: 12px;
  line-height: 1.1;
  border-left-color: transparent;
}

body.scrolled .side-nav .side-title {
  margin-bottom: 6px;
  padding: 0 2px;
  color: var(--accent);
  font-size: 11px;
}

body.scrolled .side-nav a::before {
  width: 6px;
  height: 6px;
  background: rgba(63,124,255,.42);
}

body.scrolled .side-nav a:hover,
body.scrolled .side-nav a.active {
  background: rgba(63,124,255,.12);
  color: var(--accent);
  border-left-color: transparent;
}

.topbar {
  position: sticky;
  top: 0;
  z-index: 10;
  display: flex;
  justify-content: space-between;
  gap: 20px;
  align-items: center;
  padding: 18px clamp(16px, 4vw, 48px);
  background: rgba(248, 251, 255, 0.72);
  border-bottom: 1px solid rgba(255, 255, 255, .68);
  backdrop-filter: blur(16px);
  transition: padding .2s ease, box-shadow .2s ease, background .2s ease, transform .2s ease;
}

body.scrolled .topbar {
  min-height: 46px;
  padding: 6px clamp(14px, 3vw, 36px);
  background: rgba(248, 251, 255, .82);
  box-shadow: 0 10px 26px rgba(29,43,76,.08);
}

body.scrolled .topbar .kicker {
  display: none;
}

body.scrolled h1 {
  font-size: 18px;
  letter-spacing: 0;
}

body.scrolled .status {
  max-width: min(48vw, 620px);
  font-size: 12px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

body.nav-hidden .topbar {
  transform: translateY(-112%);
}

.kicker {
  margin: 0 0 2px;
  color: var(--accent);
  font-size: 12px;
  font-weight: 800;
  text-transform: uppercase;
}

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

h1 {
  margin-bottom: 0;
  font-size: clamp(24px, 3vw, 38px);
  color: var(--text);
  letter-spacing: 0;
}

main {
  width: min(1440px, calc(100% - 32px));
  margin: 20px auto 48px;
  padding-left: 148px;
}

.status-wrap {
  display: flex;
  align-items: center;
  gap: 10px;
}

.pulse-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: #34c759;
  box-shadow: 0 0 0 8px rgba(52, 199, 89, .12), 0 0 22px rgba(52, 199, 89, .45);
}

.status {
  min-width: 220px;
  padding: 10px 12px;
  border: 1px solid rgba(255, 255, 255, .72);
  background: rgba(255, 255, 255, .58);
  color: var(--muted);
  font-size: 13px;
  text-align: right;
  border-radius: 999px;
}

.control-panel,
.history-panel,
.plain-summary,
.panel,
.trend-strip {
  background: var(--surface);
  border: 1px solid var(--line);
  box-shadow: var(--shadow);
  backdrop-filter: blur(18px);
  border-radius: 24px;
}

.command-hero {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(360px, .78fr);
  gap: 22px;
  min-height: 360px;
  padding: clamp(24px, 4vw, 42px);
  margin-bottom: 18px;
  overflow: hidden;
  border: 1px solid rgba(255,255,255,.68);
  border-radius: 32px;
  background:
    linear-gradient(120deg, rgba(13, 22, 40, .92) 0%, rgba(20, 34, 62, .84) 45%, rgba(255,255,255,.76) 100%),
    url("./assets/ai-hero.png");
  background-size: cover;
  background-position: center;
  box-shadow: 0 36px 96px rgba(29, 43, 76, .18);
}

.command-hero::before {
  content: "";
  position: absolute;
  inset: 0;
  background:
    linear-gradient(90deg, rgba(63,124,255,.16), transparent 48%),
    radial-gradient(circle at 72% 20%, rgba(91,225,216,.28), transparent 28%);
  pointer-events: none;
}

.command-copy,
.command-board {
  position: relative;
  z-index: 1;
}

.command-copy {
  align-self: center;
  color: #fff;
}

.command-copy .kicker {
  color: rgba(91,225,216,.95);
}

.command-copy h2 {
  max-width: 820px;
  margin-bottom: 14px;
  color: #fff;
  font-size: clamp(34px, 5vw, 68px);
  line-height: 1.02;
  letter-spacing: 0;
}

.command-copy p {
  max-width: 720px;
  color: rgba(255,255,255,.78);
  font-size: 17px;
  line-height: 1.75;
}

.command-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 24px;
}

.command-actions button {
  min-height: 46px;
  padding: 0 18px;
  border: 1px solid rgba(255,255,255,.18);
  border-radius: 999px;
  background: rgba(255,255,255,.12);
  color: #fff;
  backdrop-filter: blur(12px);
}

.command-actions button:first-child {
  background: linear-gradient(135deg, #3f7cff, #19c7b8);
  border-color: transparent;
  box-shadow: 0 16px 36px rgba(63,124,255,.28);
}

.command-board {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
  align-content: center;
}

.command-stat,
.route-card {
  border: 1px solid rgba(255,255,255,.72);
  background: rgba(255,255,255,.72);
  box-shadow: 0 18px 42px rgba(20,34,62,.12);
  backdrop-filter: blur(18px);
  border-radius: 20px;
}

.command-stat {
  min-height: 102px;
  padding: 16px;
}

.command-stat span,
.route-card span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 900;
}

.command-stat strong {
  display: block;
  margin-top: 8px;
  color: var(--text);
  font-size: 22px;
  line-height: 1.25;
}

.route-card {
  grid-column: 1 / -1;
  display: grid;
  grid-template-columns: 42px minmax(0, 1fr);
  gap: 12px;
  align-items: center;
  min-height: 86px;
  padding: 14px;
  cursor: pointer;
}

.route-card b {
  display: grid;
  place-items: center;
  width: 42px;
  height: 42px;
  border-radius: 14px;
  background: linear-gradient(135deg, rgba(63,124,255,.18), rgba(25,199,184,.16));
  color: var(--accent);
}

.route-card strong,
.route-card span {
  display: block;
}

.route-card strong {
  margin-bottom: 4px;
  font-size: 16px;
}

.control-panel {
  display: grid;
  grid-template-columns: minmax(240px, 1fr) auto auto auto;
  gap: 16px;
  align-items: end;
  padding: 18px;
  position: relative;
  overflow: hidden;
}

.control-panel::after,
.history-panel::after,
.plain-summary::after,
.panel::after,
.trend-strip::after,
.glossary::after {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  border: 1px solid rgba(255, 255, 255, .7);
  border-radius: inherit;
  opacity: .45;
}

.history-panel {
  position: relative;
  display: grid;
  grid-template-columns: minmax(220px, .7fr) minmax(360px, 1fr) auto;
  gap: 16px;
  align-items: center;
  margin-top: 18px;
  padding: 18px;
  overflow: hidden;
}

.history-timeline {
  grid-column: 1 / -1;
  display: flex;
  gap: 8px;
  overflow-x: auto;
  padding: 4px 0 2px;
}

.history-pill {
  flex: 0 0 auto;
  min-width: 142px;
  padding: 10px 12px;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: rgba(255,255,255,.68);
  color: var(--text);
  text-align: left;
  cursor: pointer;
}

.history-pill strong,
.history-pill span,
.history-pill em {
  display: block;
}

.history-pill strong {
  margin-bottom: 4px;
  font-size: 13px;
}

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

.history-pill em {
  width: 100%;
  margin-top: 8px;
  color: rgba(17, 24, 39, .72);
  font-size: 12px;
  font-style: normal;
  line-height: 1.35;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.history-pill.active {
  border-color: rgba(63,124,255,.42);
  background: linear-gradient(135deg, rgba(63,124,255,.16), rgba(255,255,255,.72));
  color: var(--accent);
}

.history-pill.active em {
  color: rgba(28, 72, 180, .86);
}

.history-panel h2 {
  font-size: 20px;
}

.history-controls {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.history-controls button,
.history-controls select {
  height: 40px;
  padding: 0 12px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: rgba(255,255,255,.78);
  color: var(--text);
  font-weight: 800;
}

.history-controls select {
  min-width: 220px;
}

.history-current {
  padding: 10px 12px;
  border-radius: 14px;
  background: rgba(63,124,255,.1);
  color: var(--accent);
  font-size: 13px;
  font-weight: 900;
  text-align: right;
}

.history-current strong,
.history-current span {
  display: block;
}

.history-current span {
  margin-top: 3px;
  color: rgba(28, 72, 180, .72);
  font-size: 12px;
  font-weight: 800;
}

body[data-history-mode="history"] .history-current {
  background: linear-gradient(135deg, rgba(63,124,255,.14), rgba(91,225,216,.12));
  box-shadow: inset 0 0 0 1px rgba(63,124,255,.18);
}

.search-wrap label {
  display: block;
  margin-bottom: 6px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 700;
}

input[type="search"] {
  width: 100%;
  height: 42px;
  padding: 0 12px;
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, .76);
  color: var(--text);
  font-size: 15px;
  outline: none;
  border-radius: 16px;
}

input[type="search"]:focus {
  border-color: var(--accent);
}

.filters {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
}

button {
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, .86);
  color: var(--text);
  cursor: pointer;
  font-weight: 800;
  border-radius: 16px;
}

.filter {
  min-width: 72px;
  height: 42px;
  padding: 0 12px;
}

.filter:first-child {
  min-width: 58px;
}

.filter.active {
  border-color: var(--accent);
  background: linear-gradient(135deg, #3f7cff, #7a5cff);
  color: #fff;
  box-shadow: 0 10px 24px rgba(19, 183, 157, .25);
}

.quick-modes {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

.quick-modes button {
  height: 42px;
  padding: 0 12px;
  border-radius: 999px;
  background: rgba(255,255,255,.78);
}

.quick-modes button.active {
  border-color: rgba(91,225,216,.62);
  background: linear-gradient(135deg, rgba(91,225,216,.22), rgba(63,124,255,.14));
  color: var(--accent);
  box-shadow: 0 10px 24px rgba(63,124,255,.11);
}

.filter-feedback {
  grid-column: 1 / -1;
  padding: 10px 12px;
  border: 1px solid rgba(63,124,255,.18);
  border-radius: 14px;
  background: rgba(63,124,255,.08);
  color: var(--accent);
  font-size: 13px;
  font-weight: 900;
  transition: transform .18s ease, background .18s ease, box-shadow .18s ease;
}

.filter-feedback.flash {
  transform: translateY(-1px);
  background: rgba(63,124,255,.16);
  box-shadow: 0 12px 28px rgba(63,124,255,.12);
}

.read-stats {
  grid-column: 1 / -1;
  justify-self: start;
  padding: 7px 10px;
  border-radius: 999px;
  background: rgba(255,255,255,.72);
  color: var(--muted);
  font-size: 12px;
  font-weight: 900;
}

.refresh {
  height: 42px;
  padding: 0 14px;
  border-color: var(--accent);
  background: var(--surface);
  color: var(--accent);
  border-radius: 16px;
}

.refresh:active {
  transform: translateY(1px);
}

.toggles {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  color: var(--muted);
  font-size: 14px;
}

.plain-summary {
  margin-top: 18px;
  padding: 28px;
  position: relative;
  overflow: hidden;
  min-height: 520px;
  background:
    linear-gradient(90deg, rgba(255, 255, 255, .94) 0%, rgba(255, 255, 255, .86) 42%, rgba(255, 255, 255, .28) 100%),
    url("./assets/ai-hero.png");
  background-size: cover;
  background-position: center;
  border-top: 1px solid var(--line);
  scroll-margin-top: 96px;
}

.plain-layout {
  display: grid;
  grid-template-columns: minmax(0, .95fr) minmax(340px, 1.05fr);
  gap: 32px;
  align-items: center;
}

.plain-head {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  align-items: flex-start;
  margin-bottom: 12px;
}

.plain-head span {
  color: var(--muted);
  font-size: 13px;
}

.plain-body {
  display: grid;
  gap: 12px;
}

.plain-body p {
  margin: 0;
  max-width: 980px;
  font-size: 18px;
  line-height: 1.8;
}

.plain-body strong {
  color: var(--accent-2);
}

.hero-visual {
  position: relative;
  min-height: 360px;
  border: 1px solid rgba(255, 255, 255, .72);
  border-radius: 28px;
  background:
    linear-gradient(135deg, rgba(255,255,255,.52), rgba(255,255,255,.18)),
    url("./assets/ai-hero.png");
  background-size: cover;
  background-position: center right;
  overflow: hidden;
  box-shadow: inset 0 1px 0 rgba(255,255,255,.52), 0 28px 80px rgba(51, 70, 102, .14);
}

.hero-visual::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  background:
    linear-gradient(90deg, rgba(255,255,255,.68), rgba(255,255,255,.18)),
    radial-gradient(circle at 76% 26%, rgba(63, 124, 255, .18), transparent 28%);
}

.signal-panel {
  position: relative;
  z-index: 2;
  display: grid;
  grid-template-columns: 1fr 180px;
  grid-template-rows: 1fr auto;
  gap: 16px;
  height: 100%;
  min-height: 360px;
  padding: 22px;
}

.radar-core {
  position: relative;
  min-height: 210px;
  border-radius: 24px;
  border: 1px solid rgba(255,255,255,.72);
  background:
    radial-gradient(circle at center, rgba(63,124,255,.26), transparent 17%),
    radial-gradient(circle at center, transparent 24%, rgba(63,124,255,.12) 25%, transparent 26%),
    radial-gradient(circle at center, transparent 42%, rgba(255,107,136,.14) 43%, transparent 44%),
    rgba(255,255,255,.36);
  backdrop-filter: blur(16px);
  overflow: hidden;
}

.radar-core::before {
  content: "";
  position: absolute;
  inset: 12%;
  border: 1px solid rgba(63,124,255,.18);
  border-radius: 50%;
}

.radar-core::after {
  content: "";
  position: absolute;
  left: 50%;
  top: 50%;
  width: 46%;
  height: 2px;
  transform-origin: left center;
  transform: rotate(-24deg);
  background: linear-gradient(90deg, rgba(63,124,255,.75), transparent);
}

.radar-core span {
  position: absolute;
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: #3f7cff;
  box-shadow: 0 0 0 8px rgba(63,124,255,.12);
}

.radar-core span:nth-child(1) {
  left: 26%;
  top: 32%;
}

.radar-core span:nth-child(2) {
  right: 28%;
  top: 44%;
  background: #ff6b88;
}

.radar-core span:nth-child(3) {
  left: 48%;
  bottom: 24%;
  background: #13b79d;
}

.signal-list {
  display: grid;
  gap: 10px;
}

.signal-link,
.signal-metric {
  padding: 13px;
  border: 1px solid rgba(255,255,255,.72);
  border-radius: 18px;
  background: rgba(255,255,255,.56);
  backdrop-filter: blur(16px);
  box-shadow: 0 14px 36px rgba(51,70,102,.1);
  color: var(--text);
  cursor: pointer;
  text-align: left;
  transition: transform .18s ease, box-shadow .18s ease, border-color .18s ease, background .18s ease;
}

.signal-link:hover,
.signal-metric:hover {
  transform: translateY(-2px);
  border-color: rgba(63, 124, 255, .36);
  background: rgba(255,255,255,.72);
  box-shadow: 0 20px 48px rgba(63, 124, 255, .16);
}

.signal-link:focus-visible,
.signal-metric:focus-visible {
  outline: 3px solid rgba(63, 124, 255, .28);
  outline-offset: 2px;
}

.signal-list strong,
.signal-list span {
  display: block;
}

.signal-list strong {
  margin-bottom: 4px;
  font-size: 14px;
}

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

.signal-metric {
  grid-column: 1 / -1;
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  width: 100%;
}

.signal-metric strong {
  font-size: 52px;
  line-height: .9;
  letter-spacing: 0;
  background: linear-gradient(135deg, #3f7cff, #ff6b88);
  -webkit-background-clip: text;
  color: transparent;
}

.signal-metric span {
  color: var(--muted);
  font-weight: 800;
}

.hero-visual .orbital {
  display: none;
}

/* legacy decorative orbit, hidden after the signal panel redesign */
.orbital {
  display: none;
}

/*
.hero-visual::after {
  content: "LIVE SIGNAL";
  position: absolute;
  right: 18px;
  bottom: 16px;
  color: rgba(16, 32, 35, .38);
  font-size: 12px;
  font-weight: 900;
  letter-spacing: 0;
}
*/

.summary-block {
  padding: 16px;
  border: 1px solid var(--line);
  background: rgba(255, 250, 245, .82);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, .65);
  border-radius: 18px;
}

.summary-block h3 {
  margin-bottom: 8px;
  font-size: 15px;
  color: var(--accent-2);
}

.summary-block ul {
  margin: 0;
  padding-left: 20px;
  line-height: 1.8;
}

.visual-digest {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 16px;
  margin-top: 20px;
}

.visual-digest article {
  position: relative;
  overflow: hidden;
  min-height: 168px;
  padding: 18px;
  border: 1px solid var(--line);
  display: grid;
  grid-template-rows: 82px auto auto;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, .18), rgba(255, 255, 255, .82) 58%),
    url("./assets/ai-card-backgrounds.png");
  background-size: 100% 100%, 700% 100%;
  background-position: center, 0% 50%;
  box-shadow: var(--shadow);
  border-radius: 24px;
  cursor: pointer;
  transition: transform .18s ease, box-shadow .18s ease, border-color .18s ease;
}

.visual-digest article:hover {
  transform: translateY(-3px);
  border-color: rgba(63, 124, 255, .34);
  box-shadow: 0 30px 80px rgba(63, 124, 255, .16);
}

.visual-digest article:focus-visible {
  outline: 3px solid rgba(63, 124, 255, .28);
  outline-offset: 3px;
}

.visual-digest article::after {
  content: "";
  position: absolute;
  right: -28px;
  top: -32px;
  width: 132px;
  height: 132px;
  border: 1px solid rgba(19, 183, 157, .18);
  transform: rotate(32deg);
}

.visual-digest article:nth-child(1) {
  background-position: center, 0% 50%;
}

.visual-digest article:nth-child(2) {
  background-position: center, 16.66% 50%;
}

.visual-digest article:nth-child(3) {
  background-position: center, 33.33% 50%;
}

.visual-digest article:nth-child(4) {
  background-position: center, 100% 50%;
}

.digest-icon {
  display: grid;
  width: 58px;
  height: 58px;
  place-items: center;
  margin-bottom: 14px;
  background: linear-gradient(135deg, #ffffff, #edf3ff);
  color: var(--text);
  border: 1px solid rgba(255, 255, 255, .8);
  border-radius: 16px;
  box-shadow: 0 12px 28px rgba(63, 124, 255, .12);
  color: #fff;
  position: relative;
}

.digest-icon::before,
.digest-icon::after {
  content: "";
  position: absolute;
  inset: 14px;
  border: 2px solid var(--accent);
}

.digest-icon::after {
  inset: 21px;
  border-color: var(--accent-2);
  transform: rotate(45deg);
}

.direction-core::before {
  border-radius: 50%;
}

.reader-core::before {
  border-radius: 8px;
  transform: rotate(22deg);
}

.filter-core::before {
  border-radius: 50% 50% 8px 8px;
}

.visual-digest strong {
  display: block;
  margin-bottom: 8px;
  font-size: 15px;
}

.visual-digest p {
  margin: 0;
  color: var(--muted);
  font-size: 14px;
  line-height: 1.65;
}

.glossary {
  position: relative;
  overflow: hidden;
  margin-top: 18px;
  padding: 18px;
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, .9);
  border-radius: 24px;
  box-shadow: var(--shadow);
}

.glossary-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
}

.term-card {
  padding: 12px;
  border: 1px solid var(--line);
  background: #fbfcfc;
  border-radius: 16px;
  cursor: pointer;
  transition: transform .16s ease, border-color .16s ease, box-shadow .16s ease;
}

.term-card:hover,
.term-card:focus-visible,
.term-card.expanded {
  transform: translateY(-1px);
  border-color: rgba(63,124,255,.34);
  box-shadow: 0 16px 36px rgba(51,70,102,.1);
  outline: none;
}

.term-card strong {
  display: block;
  margin-bottom: 5px;
  font-size: 14px;
}

.term-card p {
  margin: 0;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.55;
}

.term-card em {
  display: none;
  margin-top: 10px;
  padding: 10px;
  border-radius: 14px;
  background: linear-gradient(135deg, rgba(63,124,255,.08), rgba(91,225,216,.08));
  color: rgba(23,32,51,.88);
  font-size: 13px;
  font-style: normal;
  font-weight: 800;
  line-height: 1.5;
}

.term-card.expanded em {
  display: block;
}

.term-card em b {
  display: block;
  margin-bottom: 4px;
  color: var(--accent);
  font-size: 12px;
}

.cn-note {
  color: var(--accent);
  font-weight: 800;
}

.toolkit {
  margin-top: 20px;
  padding: 22px;
  border: 1px solid var(--line);
  background:
    radial-gradient(circle at 88% 12%, rgba(63,124,255,.12), transparent 26%),
    rgba(255,255,255,.74);
  border-radius: 28px;
  box-shadow: var(--shadow);
  backdrop-filter: blur(18px);
}

.toolkit-grid {
  display: grid;
  grid-template-columns: minmax(320px, 1.1fr) minmax(260px, .9fr) minmax(260px, .9fr);
  gap: 16px;
}

.tool-launchpad {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
  margin-bottom: 16px;
}

.tool-launch {
  position: relative;
  min-height: 104px;
  padding: 16px;
  border: 1px solid rgba(255,255,255,.72);
  border-radius: 22px;
  background:
    linear-gradient(180deg, rgba(255,255,255,.72), rgba(255,255,255,.5)),
    url("./assets/ai-card-backgrounds.png");
  background-size: 100% 100%, 700% 100%;
  text-align: left;
  box-shadow: 0 18px 48px rgba(51,70,102,.1);
}

.tool-launch:nth-child(2) {
  background-position: center, 33.33% 50%;
}

.tool-launch:nth-child(3) {
  background-position: center, 16.66% 50%;
}

.tool-launch:nth-child(4) {
  background-position: center, 66.66% 50%;
}

.tool-launch strong,
.tool-launch span {
  display: block;
}

.tool-launch strong {
  margin-bottom: 8px;
  font-size: 16px;
}

.tool-launch span {
  color: var(--muted);
  font-size: 13px;
}

.tool-launch::after {
  content: "进入";
  position: absolute;
  right: 14px;
  bottom: 12px;
  color: var(--accent);
  font-size: 12px;
  font-weight: 900;
}

.tool-launch:hover,
.tool-launch.active {
  transform: translateY(-2px);
  border-color: rgba(63,124,255,.38);
  box-shadow: 0 26px 70px rgba(63,124,255,.16);
}

.tutorial-panel {
  margin-bottom: 16px;
  padding: 20px;
  border: 1px solid var(--line);
  border-radius: 24px;
  background: rgba(255,255,255,.72);
  box-shadow: inset 0 1px 0 rgba(255,255,255,.8);
}

.tutorial-panel h3 {
  margin-bottom: 10px;
  font-size: 20px;
}

.tutorial-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 14px;
}

.tutorial-meta span {
  padding: 6px 10px;
  border-radius: 999px;
  background: rgba(63,124,255,.1);
  color: var(--accent);
  font-size: 12px;
  font-weight: 900;
}

.tutorial-steps {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
  counter-reset: steps;
}

.tutorial-step {
  min-height: 130px;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 18px;
  background: rgba(255,255,255,.72);
  counter-increment: steps;
}

.tutorial-step::before {
  content: counter(steps);
  display: grid;
  width: 28px;
  height: 28px;
  place-items: center;
  margin-bottom: 10px;
  border-radius: 50%;
  background: linear-gradient(135deg, #3f7cff, #7a5cff);
  color: #fff;
  font-weight: 900;
}

.tutorial-step strong {
  display: block;
  margin-bottom: 6px;
}

.tutorial-step p {
  margin: 0;
  color: var(--muted);
  line-height: 1.55;
}

.tool-card {
  position: relative;
  overflow: hidden;
  padding: 18px;
  border: 1px solid rgba(255,255,255,.72);
  border-radius: 24px;
  background:
    linear-gradient(180deg, rgba(255,255,255,.82), rgba(255,255,255,.58)),
    url("./assets/ai-card-backgrounds.png");
  background-size: 100% 100%, 700% 100%;
  box-shadow: 0 20px 56px rgba(51,70,102,.11);
}

.tool-card:nth-child(2) {
  background-position: center, 33.33% 50%;
}

.tool-card:nth-child(3) {
  background-position: center, 16.66% 50%;
}

.tool-card-head {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: center;
  margin-bottom: 10px;
}

.tool-card strong {
  font-size: 17px;
}

.tool-card p {
  margin-bottom: 12px;
  color: var(--muted);
  line-height: 1.6;
}

.tool-card pre {
  white-space: pre-wrap;
  margin: 0;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: rgba(255,255,255,.72);
  color: var(--text);
  font-family: inherit;
  line-height: 1.7;
}

.tool-card ul {
  margin: 0;
  padding-left: 0;
  line-height: 1.8;
  list-style: none;
}

.tool-card li label {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  gap: 8px;
  align-items: start;
  margin-bottom: 8px;
}

.tool-card li input {
  width: 17px;
  height: 17px;
  margin-top: 6px;
}

.copy-btn {
  height: 34px;
  padding: 0 12px;
  color: #fff;
  border-color: transparent;
  background: linear-gradient(135deg, #3f7cff, #7a5cff);
}

.role-picker {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 12px;
}

.role-pick {
  padding: 8px 11px;
  border-radius: 999px;
  font-size: 13px;
}

.role-pick.active {
  border-color: var(--accent);
  background: linear-gradient(135deg, #3f7cff, #7a5cff);
  color: #fff;
}

.instant-plan {
  display: grid;
  gap: 12px;
}

.instant-answer {
  padding: 14px;
  border: 1px solid rgba(63,124,255,.18);
  border-radius: 18px;
  background: rgba(255,255,255,.72);
}

.instant-answer span {
  display: block;
  margin-bottom: 7px;
  color: var(--accent);
  font-size: 12px;
  font-weight: 900;
}

.instant-answer strong {
  display: block;
  margin-bottom: 8px;
  line-height: 1.45;
}

.instant-answer p {
  margin: 0;
}

.instant-steps {
  display: grid;
  gap: 8px;
}

.instant-steps div {
  display: grid;
  grid-template-columns: 28px minmax(0, 1fr);
  gap: 9px;
  align-items: center;
}

.instant-steps b {
  display: grid;
  place-items: center;
  width: 28px;
  height: 28px;
  border-radius: 999px;
  background: rgba(63,124,255,.12);
  color: var(--accent);
}

.instant-steps span {
  color: var(--text);
  line-height: 1.45;
}

.instant-open {
  display: inline-flex;
  justify-content: center;
  padding: 11px 14px;
  border-radius: 999px;
  background: var(--accent);
  color: #fff;
  font-weight: 900;
  text-decoration: none;
  box-shadow: 0 14px 28px rgba(63,124,255,.18);
}

.role-actions {
  display: grid;
  gap: 10px;
}

.role-action {
  display: block;
  width: 100%;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: rgba(255,255,255,.68);
  text-align: left;
  transition: transform .16s ease, border-color .16s ease, box-shadow .16s ease;
}

.role-action:hover,
.role-action:focus-visible {
  transform: translateY(-1px);
  border-color: rgba(63,124,255,.34);
  box-shadow: 0 12px 28px rgba(51,70,102,.1);
  outline: none;
}

.role-action strong {
  display: block;
  margin-bottom: 5px;
  font-size: 14px;
}

.role-action span {
  display: block;
  color: var(--muted);
  line-height: 1.55;
}

.role-action em {
  display: inline-flex;
  margin-top: 8px;
  color: var(--accent);
  font-size: 12px;
  font-style: normal;
  font-weight: 900;
}

.brief-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 18px;
  margin-top: 18px;
}

.panel,
.trend-strip {
  padding: 20px;
}

.panel,
.trend-strip,
.level {
  scroll-margin-top: 96px;
}

.panel.primary {
  border-top: 4px solid var(--accent);
}

.panel-head {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  align-items: baseline;
  margin-bottom: 14px;
}

h2 {
  margin-bottom: 0;
  font-size: 18px;
}

.panel-head span {
  color: var(--muted);
  font-size: 13px;
}

.stack {
  display: grid;
  gap: 12px;
}

.story {
  position: relative;
  display: grid;
  grid-template-columns: clamp(180px, 16vw, 252px) minmax(0, 1fr);
  gap: 20px;
  align-items: start;
  padding: 18px;
  border: 1px solid rgba(122, 142, 174, .22);
  background:
    linear-gradient(180deg, rgba(255,255,255,.95), rgba(250,252,255,.86));
  overflow: hidden;
  box-shadow: 0 18px 46px rgba(29,43,76,.08);
  transition: transform .18s ease, box-shadow .18s ease, border-color .18s ease;
  border-radius: 26px;
}

.story-content {
  display: grid;
  gap: 10px;
  grid-column: 2;
}

.story::before {
  content: "";
  position: absolute;
  inset: 0 auto 0 0;
  width: 5px;
  z-index: 2;
  background: var(--accent);
}

.story[data-level="L1"]::before {
  background: var(--accent-2);
}

.story[data-level="L2"]::before {
  background: var(--gold);
}

.story[data-level="L5"]::before {
  background: #7a8380;
}

.story.hour-focus-story {
  border-color: rgba(63, 124, 255, .38);
  background:
    radial-gradient(circle at 12% 20%, rgba(91, 225, 216, .2), transparent 34%),
    linear-gradient(135deg, rgba(255,255,255,.96), rgba(240,246,255,.92));
  box-shadow: 0 18px 48px rgba(37, 79, 170, .13);
}

.story.hour-focus-story::before {
  width: 7px;
  background: linear-gradient(180deg, #3f7cff, #5be1d8);
}

.story.hour-focus-story .badge {
  background: rgba(63, 124, 255, .14);
  color: #2150c7;
}

.story.is-read {
  opacity: .68;
}

.story.is-read h3 {
  color: rgba(17, 24, 39, .62);
}

.story.is-later {
  border-color: rgba(255, 184, 77, .58);
  box-shadow: 0 16px 38px rgba(255, 184, 77, .12);
}

.story > *:not(.story-bg) {
  position: relative;
  z-index: 1;
}

.story-mark {
  display: none;
}

.story-bg {
  position: absolute;
  inset: 0;
  z-index: 0;
  opacity: .62;
  pointer-events: none;
  background:
    linear-gradient(90deg, rgba(255, 255, 255, .92) 0%, rgba(255, 255, 255, .84) 42%, rgba(255, 255, 255, .54) 72%, rgba(255, 255, 255, .32) 100%),
    url("./assets/ai-card-backgrounds.png");
  background-repeat: no-repeat;
  background-size: 100% 100%, 700% 100%;
  background-position: center, 0% 50%;
}

.story-art {
  position: relative;
  z-index: 1;
  align-self: stretch;
  grid-column: 1;
  grid-row: 1 / span 2;
  min-height: 100%;
  border-radius: 20px;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, .72);
  background:
    linear-gradient(180deg, rgba(255,255,255,.02), rgba(255,255,255,.18)),
    url("./assets/ai-card-backgrounds.png");
  background-size: 100% 100%, 700% 100%;
  background-position: center, 0% 50%;
  box-shadow: inset 0 1px 0 rgba(255,255,255,.42);
}

.story-art::before {
  content: attr(data-label);
  position: absolute;
  left: 14px;
  bottom: 12px;
  padding: 7px 10px;
  border-radius: 999px;
  background: rgba(255,255,255,.72);
  color: var(--text);
  font-size: 12px;
  font-weight: 900;
  backdrop-filter: blur(12px);
}

.story-art span {
  position: absolute;
  right: 16px;
  top: 16px;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: rgba(255,255,255,.62);
  backdrop-filter: blur(10px);
}

.story-art span::before,
.story-art span::after {
  content: "";
  position: absolute;
  inset: 13px;
  border: 2px solid var(--accent);
  transform: rotate(45deg);
}

.story-bg::before,
.story-bg::after {
  position: absolute;
  color: rgba(15, 28, 31, .075);
  font-size: 40px;
  line-height: 1;
  font-weight: 900;
  letter-spacing: 0;
}

.story-bg::before {
  content: attr(data-watermark);
  right: 28px;
  bottom: 18px;
  opacity: .42;
}

.story-bg::after {
  content: "";
  width: 100%;
  height: 100%;
  left: 0;
  top: 0;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, .08), rgba(255, 255, 255, .02)),
    linear-gradient(90deg, rgba(255, 255, 255, .18), transparent 74%);
}

.story.topic-regulation .story-bg {
  background-position: center, 0% 50%;
}

.story.topic-regulation .story-art {
  background-position: center, 0% 50%;
}

.story.topic-agent .story-bg {
  background-position: center, 16.66% 50%;
}

.story.topic-agent .story-art {
  background-position: center, 16.66% 50%;
}

.story.topic-security .story-bg {
  background-position: center, 33.33% 50%;
}

.story.topic-security .story-art {
  background-position: center, 33.33% 50%;
}

.story.topic-finance .story-bg {
  background-position: center, 50% 50%;
}

.story.topic-finance .story-art {
  background-position: center, 50% 50%;
}

.story.topic-research .story-bg {
  background-position: center, 66.66% 50%;
}

.story.topic-research .story-art {
  background-position: center, 66.66% 50%;
}

.story.topic-driving .story-bg {
  background-position: center, 83.33% 50%;
}

.story.topic-driving .story-art {
  background-position: center, 83.33% 50%;
}

.story.topic-noise .story-bg {
  background-position: center, 100% 50%;
}

.story.topic-noise .story-art {
  background-position: center, 100% 50%;
}

.story:hover {
  border-color: rgba(63,124,255,.32);
  box-shadow: 0 24px 62px rgba(29,43,76,.14);
  transform: translateY(-2px);
}

.story-top {
  display: flex;
  gap: 10px;
  align-items: flex-start;
}

.badge {
  flex: 0 0 auto;
  display: inline-grid;
  min-width: 52px;
  height: 26px;
  place-items: center;
  padding: 0 8px;
  background: rgba(8, 16, 19, .08);
  color: var(--accent);
  font-size: 12px;
  font-weight: 900;
  border-radius: 999px;
}

h3 {
  margin-bottom: 8px;
  font-size: 20px;
  line-height: 1.35;
}

.visual-row {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin: 6px 0 10px;
}

.visual-row span {
  display: inline-flex;
  align-items: center;
  min-height: 26px;
  padding: 4px 8px;
  background: rgba(255, 255, 255, .68);
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
  border-radius: 999px;
}

.topic-icon {
  color: var(--text) !important;
}

.action-chip.must {
  background: #fff1ee;
  color: var(--accent-2);
}

.action-chip.watch {
  background: #fff8e8;
  color: var(--gold);
}

.action-chip.scan {
  background: #eef8f5;
  color: var(--accent);
}

.action-chip.skip {
  background: #f1f2f2;
  color: #67706d;
}

.meta,
.reason,
.impact {
  color: var(--muted);
  font-size: 13px;
  line-height: 1.55;
}

.summary {
  margin: 10px 0;
  color: rgba(23,32,51,.92);
  font-size: 15px;
  line-height: 1.78;
}

.story-tools {
  display: grid;
  gap: 12px;
  margin-top: 14px;
}

.story-tool-buttons {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
}

.story-tool {
  min-height: 84px;
  padding: 12px;
  border: 1px solid rgba(122,142,174,.22);
  border-radius: 16px;
  background: rgba(255,255,255,.74);
  text-align: left;
  box-shadow: 0 10px 26px rgba(51,70,102,.06);
}

.story-tool strong,
.story-tool span {
  display: block;
}

.story-tool strong {
  margin-bottom: 5px;
  font-size: 13px;
}

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

.story-tool:hover {
  transform: translateY(-1px);
  border-color: rgba(63,124,255,.38);
  box-shadow: 0 16px 38px rgba(63,124,255,.13);
}

.story-tool.active {
  border-color: rgba(63,124,255,.56);
  background: linear-gradient(135deg, rgba(63,124,255,.14), rgba(255,255,255,.84));
  box-shadow: 0 16px 38px rgba(63,124,255,.16);
}

.story-action-kit {
  display: grid;
  grid-template-columns: minmax(240px, .72fr) minmax(360px, 1.16fr) minmax(300px, .94fr);
  grid-template-areas:
    "guide action answer"
    "tools tools answer"
    "scenes scenes scenes";
  gap: 12px;
  align-items: start;
  padding: 14px;
  border: 1px solid rgba(63, 124, 255, .14);
  border-radius: 20px;
  background:
    linear-gradient(135deg, rgba(255,255,255,.86), rgba(242,247,255,.78)),
    radial-gradient(circle at 100% 0%, rgba(91,225,216,.18), transparent 32%);
  box-shadow: inset 0 1px 0 rgba(255,255,255,.72);
}

.kit-tools {
  grid-area: tools;
}

.kit-scenes {
  grid-area: scenes;
}

.story-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 12px;
}

.story-actions button {
  min-height: 34px;
  padding: 0 11px;
  border-radius: 999px;
  background: rgba(255,255,255,.76);
  color: var(--muted);
  font-size: 12px;
}

.story.is-read .story-actions [data-read-story],
.story.is-later .story-actions [data-later-story] {
  border-color: rgba(63,124,255,.34);
  background: rgba(63,124,255,.1);
  color: var(--accent);
}

.kit-guide {
  grid-area: guide;
  padding: 12px;
  border-radius: 16px;
  background: linear-gradient(135deg, rgba(63,124,255,.12), rgba(91,225,216,.1));
}

.kit-guide strong {
  display: block;
  margin-bottom: 6px;
  color: var(--text);
  font-size: 15px;
}

.kit-guide p {
  margin: 0;
  color: var(--text);
  font-size: 13px;
  line-height: 1.6;
}

.kit-primary-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  margin-top: 10px;
  padding: 9px 12px;
  border-radius: 999px;
  background: var(--accent);
  color: #fff;
  font-size: 13px;
  font-weight: 900;
  text-decoration: none;
  box-shadow: 0 12px 24px rgba(63,124,255,.2);
}

.kit-action {
  grid-area: action;
  padding: 14px;
  border: 1px solid rgba(91, 225, 216, .2);
  border-radius: 16px;
  background:
    linear-gradient(135deg, rgba(255,255,255,.88), rgba(238, 255, 252, .66)),
    radial-gradient(circle at 100% 0%, rgba(91,225,216,.18), transparent 46%);
}

.kit-action > span,
.kit-answer > span,
.kit-tools > span,
.kit-scenes > span {
  display: inline-flex;
  margin-bottom: 6px;
  color: var(--accent);
  font-size: 12px;
  font-weight: 900;
}

.kit-action p,
.kit-answer p {
  margin: 0;
  color: var(--text);
  font-size: 13px;
  line-height: 1.6;
}

.kit-action strong {
  display: block;
  margin-bottom: 8px;
  color: var(--text);
  font-size: 14px;
}

.kit-action ol {
  counter-reset: step;
  display: grid;
  gap: 7px;
  margin: 8px 0 0;
  padding: 0;
  list-style: none;
}

.kit-action li {
  position: relative;
  padding: 8px 10px 8px 34px;
  border-radius: 13px;
  background: rgba(255,255,255,.74);
  color: var(--text);
  font-size: 12px;
  line-height: 1.45;
}

.kit-action li::before {
  content: counter(step);
  counter-increment: step;
  position: absolute;
  left: 10px;
  top: 8px;
  display: grid;
  width: 17px;
  height: 17px;
  place-items: center;
  border-radius: 50%;
  background: var(--accent);
  color: #fff;
  font-size: 10px;
  font-weight: 900;
}

.kit-answer {
  grid-area: answer;
  align-self: stretch;
  padding: 14px;
  border: 1px solid rgba(63,124,255,.2);
  border-radius: 16px;
  background:
    linear-gradient(180deg, rgba(255,255,255,.86), rgba(248,251,255,.72)),
    radial-gradient(circle at 100% 100%, rgba(63,124,255,.14), transparent 42%);
}

.kit-answer dl {
  display: grid;
  gap: 10px;
  margin: 0;
}

.kit-answer dl > div {
  display: grid;
  grid-template-columns: 90px minmax(0, 1fr);
  gap: 10px;
}

.kit-answer dt {
  color: var(--accent);
  font-size: 12px;
  font-weight: 900;
}

.kit-answer dd {
  margin: 0;
  color: var(--text);
  font-size: 13px;
  line-height: 1.55;
}

.kit-answer a {
  color: var(--accent);
  font-weight: 900;
  text-decoration: none;
}

.kit-tools > div {
  display: grid;
  grid-template-columns: repeat(3, minmax(160px, 1fr));
  gap: 8px;
}

.kit-tools a {
  min-height: 118px;
  padding: 9px;
  border: 1px solid rgba(151, 190, 184, .5);
  border-radius: 14px;
  background: rgba(255,255,255,.78);
  color: var(--text);
  text-decoration: none;
  transition: transform .16s ease, border-color .16s ease, box-shadow .16s ease;
}

.kit-tools a:hover {
  transform: translateY(-1px);
  border-color: rgba(63,124,255,.38);
  box-shadow: 0 10px 24px rgba(51,70,102,.1);
}

.kit-tools strong,
.kit-tools span {
  display: block;
}

.kit-tools strong {
  margin-bottom: 4px;
  font-size: 13px;
  color: var(--accent);
}

.kit-tools span {
  margin-top: 5px;
  color: var(--muted);
  font-size: 11px;
  line-height: 1.45;
}

.kit-scenes ul {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.kit-scenes li {
  padding: 6px 9px;
  border-radius: 999px;
  background: rgba(255,255,255,.72);
  color: var(--muted);
  font-size: 12px;
  font-weight: 750;
}

.story-tool-note {
  grid-column: 1 / -1;
  padding: 14px;
  border: 1px solid rgba(63,124,255,.28);
  border-radius: 18px;
  background:
    linear-gradient(135deg, rgba(63,124,255,.12), rgba(91,225,216,.1)),
    rgba(255,255,255,.76);
  color: var(--text);
  line-height: 1.65;
}

.tool-note-head {
  display: flex;
  gap: 10px;
  align-items: center;
  margin-bottom: 8px;
}

.tool-note-head strong {
  font-size: 16px;
}

.tool-note-head span {
  padding: 4px 8px;
  border-radius: 999px;
  background: rgba(255,255,255,.72);
  color: var(--accent);
  font-size: 12px;
  font-weight: 900;
}

.story-tool-note p {
  margin: 0 0 8px;
}

.story-tool-note ol {
  margin: 0;
  padding-left: 18px;
  color: var(--muted);
}

.story-tool-note a {
  display: inline-flex;
  margin-top: 10px;
  padding: 8px 12px;
  border-radius: 999px;
  background: var(--accent);
  color: #fff;
  font-size: 13px;
  font-weight: 900;
  text-decoration: none;
}

.story-judgement {
  grid-column: 2;
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr) auto;
  gap: 12px;
  align-items: center;
  align-self: stretch;
  padding: 16px;
  border-top: 1px solid rgba(122,142,174,.18);
  border-radius: 20px;
  background: rgba(255,255,255,.58);
}

.story-judgement .reason,
.story-judgement .impact {
  margin-bottom: 0;
}

.story-judgement strong {
  color: var(--text);
}

.source {
  display: inline-flex;
  justify-content: center;
  min-width: 150px;
  width: auto;
  margin-top: 10px;
  padding: 10px 12px;
  border-radius: 999px;
  background: rgba(63,124,255,.1);
  color: var(--accent);
  font-size: 13px;
  font-weight: 800;
  text-decoration: none;
}

.back-top {
  position: fixed;
  right: 22px;
  bottom: 24px;
  z-index: 30;
  min-width: 96px;
  height: 44px;
  padding: 0 16px;
  border-color: rgba(63,124,255,.24);
  border-radius: 999px;
  background: linear-gradient(135deg, rgba(63,124,255,.95), rgba(122,92,255,.95));
  color: #fff;
  box-shadow: 0 18px 38px rgba(37,79,170,.22);
  opacity: 0;
  pointer-events: none;
  transform: translateY(12px);
  transition: opacity .18s ease, transform .18s ease;
}

.back-top.show {
  opacity: 1;
  pointer-events: auto;
  transform: translateY(0);
}

.skip-panel {
  margin-top: 18px;
}

.skip-checklist {
  display: grid;
  gap: 10px;
}

.skip-item {
  display: grid;
  grid-template-columns: auto auto minmax(0, 1fr) auto;
  gap: 10px;
  align-items: start;
  padding: 12px;
  border: 1px solid rgba(255,111,89,.18);
  border-radius: 16px;
  background: #fff7f5;
  cursor: pointer;
  transition: opacity .16s ease, border-color .16s ease, background .16s ease;
}

.skip-item.checked {
  opacity: .62;
  border-color: rgba(103,112,109,.2);
  background: #f5f6f6;
}

.skip-item input {
  width: 18px;
  height: 18px;
  margin-top: 2px;
}

.skip-index {
  width: 24px;
  height: 24px;
  display: inline-grid;
  place-items: center;
  border-radius: 999px;
  background: rgba(255,111,89,.12);
  color: var(--accent-2);
  font-size: 12px;
  font-weight: 900;
}

.skip-item strong {
  display: block;
  margin-bottom: 4px;
}

.skip-item p {
  margin-bottom: 0;
  color: var(--muted);
  line-height: 1.55;
}

.skip-status {
  padding: 5px 9px;
  border-radius: 999px;
  background: rgba(255,255,255,.76);
  color: var(--muted);
  font-size: 12px;
  font-weight: 900;
}

.trend-strip {
  margin-top: 18px;
  border-top: 4px solid var(--gold);
}

.trend-strip p {
  margin: 10px 0 0;
  line-height: 1.8;
}

.levels {
  display: grid;
  grid-template-columns: 1fr;
  gap: 18px;
  margin-top: 18px;
  align-items: start;
}

.level {
  display: grid;
  gap: 10px;
}

.level-head {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 16px;
  margin: 10px 0 2px;
  padding: 18px 4px 10px;
  border-top: 1px solid rgba(122,142,174,.22);
  background: transparent;
}

.level-head h2 {
  font-size: 24px;
  color: var(--text);
}

.level-head p {
  margin: 4px 0 0;
  color: var(--muted);
  font-size: 13px;
}

.hidden {
  display: none !important;
}

.seo-static {
  margin-top: 20px;
  padding: 22px;
  border: 1px solid var(--line);
  border-radius: 26px;
  background: rgba(255, 255, 255, .86);
  box-shadow: var(--shadow);
}

.seo-static h2,
.seo-static h3 {
  margin-bottom: 10px;
}

.seo-static p,
.seo-static li {
  color: var(--muted);
  line-height: 1.75;
}

.seo-static-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
  margin-top: 12px;
}

.seo-static article {
  padding: 14px;
  border: 1px solid rgba(122,142,174,.2);
  border-radius: 18px;
  background: rgba(255,255,255,.72);
}

@media (max-width: 1180px) {
  body.scrolled .side-nav,
  .side-nav {
    position: sticky;
    top: 77px;
    left: auto;
    display: flex;
    width: calc(100% - 32px);
    margin: 12px auto 0;
    overflow-x: auto;
    opacity: 1;
  }

  .side-title {
    flex: 0 0 auto;
    margin: 0 8px 0 0;
    padding: 9px 8px;
  }

  .side-nav a {
    flex: 0 0 auto;
    white-space: nowrap;
  }

  body.scrolled .side-nav .side-title {
    display: block;
  }

  body.scrolled .side-nav a {
    color: var(--text);
  }

  body.scrolled .side-nav a::before {
    display: none;
  }

  main {
    padding-left: 0;
  }

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

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

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

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

  .toolkit-grid {
    grid-template-columns: 1fr;
  }

  .history-panel {
    grid-template-columns: 1fr;
  }

  .history-current {
    text-align: left;
  }

  .tool-launchpad,
  .tutorial-steps {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .story-action-kit {
    grid-template-columns: 1fr 1fr;
    grid-template-areas:
      "guide answer"
      "action answer"
      "tools tools"
      "scenes scenes";
  }

  .kit-tools {
    grid-column: 1 / -1;
  }

  .story-judgement {
    grid-template-columns: 1fr;
    align-items: stretch;
  }
}

@media (max-width: 820px) {
  .topbar,
  .plain-head,
  .panel-head {
    align-items: flex-start;
    flex-direction: column;
  }

  .status {
    width: 100%;
    text-align: left;
  }

  .control-panel,
  .history-panel,
  .brief-grid,
  .command-hero,
  .command-board,
  .plain-layout,
  .visual-digest,
  .glossary-grid,
  .toolkit-grid,
  .seo-static-grid,
  .tool-launchpad,
  .tutorial-steps,
  .levels {
    grid-template-columns: 1fr;
  }

  .command-hero {
    min-height: auto;
    padding: 24px;
  }

  .command-copy h2 {
    font-size: clamp(30px, 12vw, 44px);
  }

  .level-head {
    padding-top: 14px;
  }

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

  .story-art,
  .story-mark,
  .story-content,
  .story-judgement {
    grid-column: 1;
  }

  .story-tool-buttons,
  .story-action-kit,
  .kit-tools > div {
    grid-template-columns: 1fr;
  }

  .story-action-kit {
    grid-template-areas:
      "guide"
      "action"
      "answer"
      "tools"
      "scenes";
  }

  .signal-panel {
    grid-template-columns: 1fr;
    min-height: 420px;
  }

  .radar-core {
    min-height: 180px;
  }

  .signal-metric {
    grid-column: 1;
  }

  .story-judgement {
    grid-column: 1;
    padding-left: 0;
    border-left: 0;
    border-top: 1px solid var(--line);
    padding-top: 10px;
  }
}
