/* ===== RESET ===== */
*, *::before, *::after { margin: 0; padding: 0; box-sizing: border-box; }

/* ===== TOKENS ===== */
:root {
  --bg-base: #1a1a20;
  --bg-elevated: #212128;
  --bg-card: #24242b;
  --bg-card-hover: #2c2c34;
  --border: #32323c;
  --border-subtle: #28282f;

  --text-primary: #f0f0f4;
  --text-secondary: #b8b8c4;
  --text-muted: #7a7a88;
  --text-dim: #555560;
  --text-inverse: #0b0b0e;

  --accent-green: #00FFA3;
  --accent-green-dim: #064e36;
  --neon-green: #00FFA3;
  --neon-glow: 0 0 8px rgba(0, 255, 163, 0.3), 0 0 24px rgba(0, 255, 163, 0.12), 0 0 48px rgba(0, 255, 163, 0.06);
  --accent-amber: #fbbf24;
  --accent-red: #f87171;

  /* 흑백 테마 */
  --white-bg: #eeeef2;
  --white-border: #d4d4dc;
  --white-accent: #1a1a22;
  --white-stat: #5a5a66;
  --white-rank: #444450;
  --white-glow: rgba(255, 255, 255, 0.15);
  --black-bg: #08080b;
  --black-border: #18181e;
  --black-text: #e0e0e6;
  --black-stat: #b8b8c2;
  --black-rank: #d0d0d8;
  --black-glow: rgba(0, 0, 0, 0.5);

  --font-body: 'Pretendard Variable', Pretendard, -apple-system, BlinkMacSystemFont, sans-serif;
  --font-mono: 'JetBrains Mono', 'Fira Code', monospace;

  /* Typography scale */
  --fs-display:   2.25rem;   /* 36px */
  --fs-heading-l: 1.5rem;    /* 24px */
  --fs-heading:   1.25rem;   /* 20px */
  --fs-body:      1rem;      /* 16px */
  --fs-ui:        1rem;      /* 16px */
  --fs-label:     0.875rem;  /* 14px */
  --fs-micro:     0.75rem;   /* 12px */

  --nav-h: 56px;
  --sidebar-w: 380px;
  --content-max: 640px;
  --gap: 36px;
}

html {
  font-size: 16px;
  scroll-behavior: smooth;
  background: var(--bg-base);
  color: var(--text-primary);
}

body {
  font-family: var(--font-body);
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  overflow: hidden;
  height: 100vh;
  position: relative;
}

/* ===== GREEN NEON AMBIENT GLOW ===== */
body::before {
  content: '';
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  background:
    radial-gradient(ellipse 60% 50% at 85% 50%, rgba(0, 255, 163, 0.06) 0%, transparent 70%),
    radial-gradient(ellipse 50% 60% at 15% 50%, rgba(255, 255, 255, 0.03) 0%, transparent 60%),
    radial-gradient(ellipse 80% 40% at 50% 100%, rgba(0, 255, 163, 0.04) 0%, transparent 60%);
}

/* ===== PAGE SECTIONS ===== */
.page-section { display: none; }
.page-section.active { display: block; }

/* ===== NAV ===== */
nav {
  position: sticky;
  top: 0;
  z-index: 100;
  height: var(--nav-h);
  background: rgba(26, 26, 32, 0.88);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border-subtle);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0 32px;
}

.logo {
  font-family: var(--font-mono);
  font-size: 1rem;
  font-weight: 600;
  color: var(--text-primary);
  letter-spacing: 0;
  position: absolute;
  left: calc(50% - var(--content-max) / 2 - var(--gap) - 8px);
  transform: translateX(-100%);
  text-decoration: none;
}

.logo span {
  color: var(--accent-green);
}

.nav-cats {
  display: flex;
  gap: 4px;
}

.nav-cat {
  font-family: var(--font-mono);
  font-size: var(--fs-ui);
  color: var(--text-muted);
  text-decoration: none;
  padding: 6px 10px;
  border-radius: 4px;
  border: 0;
  background: transparent;
  cursor: pointer;
  transition: all 0.15s;
  letter-spacing: 0.3px;
}

.nav-cat:hover {
  color: var(--text-secondary);
  background: rgba(255, 255, 255, 0.04);
}

.nav-cat.active {
  color: var(--neon-green);
  background: rgba(0, 255, 163, 0.08);
}

.nav-cta {
  position: absolute;
  right: 32px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: var(--fs-ui);
  padding: 8px 18px;
  border: 1px solid var(--border);
  border-radius: 6px;
  color: var(--text-secondary);
  background: transparent;
  cursor: pointer;
  transition: all 0.15s;
  font-family: var(--font-body);
  text-decoration: none;
  white-space: nowrap;
}

.nav-cta:hover {
  border-color: var(--neon-green);
  color: var(--neon-green);
  box-shadow: 0 0 8px rgba(0, 255, 163, 0.15);
}

/* ===== HERO ===== */
.hero {
  text-align: center;
  padding: 80px 16px 64px;
  max-width: 100%;
  margin: 0 auto;
}

.hero h1 {
  font-size: var(--fs-display);
  font-weight: 700;
  line-height: 1.15;
  letter-spacing: 0;
  margin-bottom: 20px;
  color: var(--text-primary);
}

.hero h1 em {
  font-style: normal;
  color: var(--accent-green);
}

.hero p {
  font-size: var(--fs-body);
  color: var(--text-secondary);
  line-height: 1.7;
  max-width: 480px;
  margin: 0 auto;
}

.hero-label {
  display: inline-block;
  font-family: var(--font-mono);
  font-size: var(--fs-label);
  color: var(--accent-green);
  border: 1px solid var(--accent-green-dim);
  background: rgba(52, 211, 153, 0.06);
  padding: 4px 12px;
  border-radius: 20px;
  margin-bottom: 28px;
  letter-spacing: 0.5px;
}

/* ===== MAIN LAYOUT ===== */
.main-layout {
  display: grid;
  grid-template-columns: var(--sidebar-w) 1fr var(--sidebar-w);
  gap: var(--gap);
  max-width: calc(var(--sidebar-w) * 2 + var(--content-max) + var(--gap) * 2 + 80px);
  margin: 0 auto;
  padding: 0 32px;
  height: calc(100vh - var(--nav-h));
  overflow: hidden;
  position: relative;
  z-index: 1;
}

/* ===== SCROLL COLUMNS ===== */
.sidebar, .content {
  overflow-y: auto;
  height: 100%;
  scrollbar-width: thin;
  scrollbar-color: #2a2a32 transparent;
}

.sidebar::-webkit-scrollbar,
.content::-webkit-scrollbar {
  width: 4px;
}

.sidebar::-webkit-scrollbar-track,
.content::-webkit-scrollbar-track {
  background: transparent;
}

.sidebar::-webkit-scrollbar-thumb,
.content::-webkit-scrollbar-thumb {
  background: #2a2a32;
  border-radius: 4px;
}

.sidebar::-webkit-scrollbar-thumb:hover,
.content::-webkit-scrollbar-thumb:hover {
  background: #3a3a44;
}

/* ===== SIDEBARS ===== */
.sidebar {
  display: flex;
  flex-direction: column;
  gap: 2px;
  padding: 24px 0 80px;
}

/* Team header — typographic, not card */
.team-header {
  padding: 32px 8px 20px;
  margin-bottom: 4px;
  flex-shrink: 0;
  border: none;
  background: none;
  border-radius: 0;
  text-align: center;
  position: relative;
  cursor: default;
}

.team-tooltip {
  position: absolute;
  top: 100%;
  left: 50%;
  transform: translateX(-50%);
  width: 280px;
  padding: 16px 18px;
  border-radius: 8px;
  font-family: var(--font-body);
  font-size: var(--fs-label);
  line-height: 1.65;
  color: var(--text-secondary);
  z-index: 80;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.2s;
}

.team-header:hover .team-tooltip {
  opacity: 1;
  pointer-events: auto;
}

.team-white .team-tooltip {
  background: #e4e4ea;
  color: #2a2a34;
  border: 1px solid #c8c8d0;
  box-shadow: 0 4px 20px rgba(0,0,0,0.15);
}

.team-black .team-tooltip {
  background: rgba(8, 8, 11, 0.92);
  border: 1px solid rgba(0, 255, 163, 0.2);
  box-shadow: 0 4px 24px rgba(0, 0, 0, 0.4), 0 0 12px rgba(0, 255, 163, 0.08);
}

.team-tooltip strong {
  display: block;
  font-size: var(--fs-body);
  margin-bottom: 6px;
  color: var(--text-primary);
}

.team-white .team-tooltip strong {
  color: #1a1a22;
}

.team-black .team-tooltip strong {
  color: var(--neon-green);
}

.team-header .team-label {
  font-family: var(--font-mono);
  font-size: 1.6rem;
  font-weight: 800;
  letter-spacing: 6px;
  text-transform: uppercase;
  line-height: 1;
  display: block;
  padding: 8px 0;
}

.team-header .team-sub {
  font-family: var(--font-mono);
  font-size: var(--fs-label);
  font-weight: 600;
  letter-spacing: 3px;
  text-transform: uppercase;
  margin-top: 6px;
  color: var(--text-secondary);
}

.team-header .team-range {
  font-family: var(--font-mono);
  font-size: var(--fs-label);
  letter-spacing: 2px;
  margin-top: 12px;
  padding-top: 12px;
  border-top: 1px solid var(--border-subtle);
  color: var(--text-muted);
  display: inline-block;
}

.team-white {
  color: #a0a0ac;
}

.team-white .team-label {
  color: #e8e8f0;
  text-shadow: 0 0 8px rgba(255, 255, 255, 0.15);
}

.team-white .team-range {
  border-color: #3a3a44;
}

.team-black {
  color: #a0a0ac;
}

.team-black .team-label {
  color: var(--bg-base);
  -webkit-text-stroke: 0.5px rgba(0, 255, 163, 0.6);
  text-shadow: 0 0 6px rgba(0, 255, 163, 0.15);
}

.team-black .team-sub {
  color: rgba(0, 255, 163, 0.5);
}

.team-black .team-range {
  border-color: rgba(0, 255, 163, 0.15);
  color: rgba(0, 255, 163, 0.35);
}

/* ===== STREAMER CARD — LCK STRIP STYLE ===== */
.s-card {
  position: relative;
  overflow: hidden;
  padding: 23px 20px;
  display: flex;
  align-items: center;
  gap: 10px;
  width: 100%;
  border-radius: 4px;
  border: none;
  border-bottom: 1px solid rgba(255,255,255,0.04);
  transition: background 0.15s;
  cursor: pointer;
  min-height: 72px;
  transform-style: preserve-3d;
  backface-visibility: hidden;
  appearance: none;
  color: inherit;
  font: inherit;
  text-align: inherit;
}

.s-card:focus-visible,
.nav-cat:focus-visible,
.nav-cta:focus-visible,
.sample-btn:focus-visible,
.cta-btn:focus-visible,
.modal-cta:focus-visible,
.scroll-arrow:focus-visible {
  outline: 2px solid var(--neon-green);
  outline-offset: 3px;
}

.s-card.flip-out {
  animation: flipOut 0.75s ease-in forwards;
}

.s-card.flip-in {
  animation: flipIn 0.75s ease-out forwards;
}

.s-card.flip-out-fast {
  animation: flipOut 0.15s ease-in forwards;
}

.s-card.flip-in-fast {
  animation: flipIn 0.15s ease-out forwards;
}

@keyframes flipOut {
  0% { transform: rotateX(0); opacity: 1; }
  100% { transform: rotateX(90deg); opacity: 0; }
}

@keyframes flipIn {
  0% { transform: rotateX(-90deg); opacity: 0; box-shadow: 0 0 16px rgba(0,255,163,0.4); }
  60% { box-shadow: 0 0 12px rgba(0,255,163,0.25); }
  100% { transform: rotateX(0); opacity: 1; box-shadow: none; }
}

.s-card:last-child { border-bottom: none; }

.s-card:hover { background: rgba(255,255,255,0.03); }

/* 프로필 이미지 — 블러 페이드 블리딩 */
.s-card[style*="--img"]::after {
  content: '';
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 140px;
  height: 140px;
  border-radius: 0;
  background-image: var(--img);
  background-size: cover;
  background-position: center;
  pointer-events: none;
  mask-image: linear-gradient(to right, black 60%, transparent 100%);
  -webkit-mask-image: linear-gradient(to right, black 60%, transparent 100%);
}

.s-rank {
  display: none;
}

.s-rank-inline {
  color: var(--text-dim);
  margin-right: 2px;
}

.s-info {
  flex: 1;
  min-width: 0;
}

.s-name {
  font-size: var(--fs-heading);
  font-weight: 800;
  letter-spacing: 0;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  line-height: 1.1;
}

.s-stat {
  font-family: var(--font-mono);
  font-size: var(--fs-label);
  margin-top: 3px;
  color: var(--text-muted);
}


.s-trend {
  font-family: var(--font-mono);
  font-size: var(--fs-micro);
  font-weight: 600;
  margin-left: 4px;
}

.s-trend.up { color: var(--accent-green); }
.s-trend.down { color: var(--accent-red); }
.s-trend.flat { color: var(--text-muted); }

/* ===== 백스트리머 (LEFT) — 밝은 스트립, 좌정렬 ===== */
.sidebar-white .s-card {
  background: var(--white-bg);
  border: 1px solid rgba(0,0,0,0.08);
  padding: 26px 20px 24px 96px;
  min-height: 77px;
  justify-content: flex-end;
  text-align: right;
}

.sidebar-white .s-card:hover {
  background: #e4e4ea;
}

.sidebar-white .s-card[style*="--img"]::after {
  left: 4px;
  opacity: 0.9;
}

.sidebar-white .s-rank {
  display: none;
}

.sidebar-white .s-name {
  color: var(--white-accent);
}

.sidebar-white .s-stat {
  color: var(--white-stat);
}

.sidebar-white .s-trend.up { color: #1a8a5a; }
.sidebar-white .s-trend.down { color: #c44040; }
.sidebar-white .s-trend.flat { color: #7a7a88; }

/* ===== 흑스트리머 (RIGHT) — 투명 + 그린 네온 글로우 ===== */
.sidebar-black .s-card {
  background: rgba(8, 8, 11, 0.3);
  border: 1px solid rgba(0, 255, 163, 0.15);
  border-bottom-color: rgba(0, 255, 163, 0.15);
  box-shadow: inset 0 0 12px rgba(0, 255, 163, 0.03), 0 0 8px rgba(0, 255, 163, 0.06);
  flex-direction: row-reverse;
  padding: 26px 96px 24px 20px;
  min-height: 77px;
  justify-content: flex-end;
  text-align: left;
  transition: all 0.2s ease;
}

.sidebar-black .s-card:hover {
  background: rgba(0, 255, 163, 0.05);
  border-color: rgba(0, 255, 163, 0.35);
  box-shadow: inset 0 0 16px rgba(0, 255, 163, 0.06), 0 0 12px rgba(0, 255, 163, 0.15), 0 0 32px rgba(0, 255, 163, 0.08);
}

.sidebar-black .s-card[style*="--img"]::after {
  right: 4px;
  left: auto;
  opacity: 0.9;
  mask-image: linear-gradient(to left, black 60%, transparent 100%);
  -webkit-mask-image: linear-gradient(to left, black 60%, transparent 100%);
}

.sidebar-black .s-rank {
  display: none;
}

.sidebar-black .s-name {
  color: #e8fff4;
}

.sidebar-black .s-stat {
  color: var(--black-stat);
}

.sidebar-black .s-trend {
  margin-left: 0;
  margin-right: 4px;
}

.sidebar-black .s-trend.up { color: var(--neon-green); }
.sidebar-black .s-trend.flat { color: #6a6a78; }

/* ===== CENTER CONTENT ===== */
.content {
  max-width: var(--content-max);
  margin: 0 auto;
  padding: 0 8px 0;
}

.content-intro {
  padding: 0 0 48px;
  border-bottom: 1px solid var(--border-subtle);
  margin-bottom: 48px;
}

.content-intro h2 {
  font-size: var(--fs-heading);
  font-weight: 600;
  margin-bottom: 12px;
  letter-spacing: 0;
}

.content-intro p {
  color: var(--text-secondary);
  font-size: var(--fs-body);
}

/* ===== LESSON BLOCK ===== */
.lesson {
  padding: 40px 0;
  border-bottom: 1px solid var(--border-subtle);
}

.lesson:last-of-type {
  border-bottom: none;
}

.lesson-header {
  display: flex;
  align-items: baseline;
  gap: 12px;
  margin-bottom: 14px;
}

.lesson-num {
  font-family: var(--font-mono);
  font-size: var(--fs-label);
  color: var(--accent-green);
  min-width: 24px;
}

.lesson-title {
  font-size: var(--fs-heading);
  font-weight: 600;
  letter-spacing: 0;
}

.lesson-concept {
  font-family: var(--font-mono);
  font-size: var(--fs-label);
  color: var(--text-muted);
  margin-bottom: 16px;
  padding-left: 36px;
}

.lesson-body {
  padding-left: 36px;
  color: var(--text-secondary);
  font-size: var(--fs-body);
  line-height: 1.75;
}

.lesson-body strong {
  color: var(--text-primary);
  font-weight: 600;
}

.lesson-toggle {
  display: flex;
  gap: 0;
  margin-bottom: 14px;
  padding-left: 36px;
}

.lesson-toggle-btn {
  font-family: var(--font-mono);
  font-size: var(--fs-ui);
  letter-spacing: 0.5px;
  padding: 5px 14px;
  border: 1px solid var(--border);
  background: none;
  color: var(--text-muted);
  cursor: pointer;
  transition: all 0.15s;
}

.lesson-toggle-btn:first-child {
  border-radius: 4px 0 0 4px;
}

.lesson-toggle-btn:last-child {
  border-radius: 0 4px 4px 0;
  border-left: none;
}

.lesson-toggle-btn.active {
  background: rgba(248, 113, 113, 0.08);
  border-color: rgba(248, 113, 113, 0.3);
  color: var(--accent-red);
}

.lesson-toggle-btn.active-neon {
  background: rgba(0, 255, 163, 0.08);
  border-color: rgba(0, 255, 163, 0.3);
  color: var(--neon-green);
}

.lesson-view {
  display: none;
  padding-left: 36px;
  color: var(--text-secondary);
  font-size: var(--fs-body);
  line-height: 1.75;
}

.lesson-view.active {
  display: block;
}

.lesson-view strong {
  color: var(--text-primary);
  font-weight: 600;
}

.lesson-view.reading strong {
  color: var(--neon-green);
}

.lesson-example {
  margin-top: 14px;
  padding: 14px 16px;
  background: var(--bg-elevated);
  border-left: 2px solid var(--accent-green-dim);
  border-radius: 0 6px 6px 0;
  font-size: var(--fs-body);
  color: var(--text-secondary);
  line-height: 1.7;
}

.lesson-example .num {
  font-family: var(--font-mono);
  color: var(--accent-amber);
}

/* ===== CATEGORY DIVIDER ===== */
.category {
  padding: 56px 0 8px;
  margin-bottom: 0;
}

.category-label {
  font-family: var(--font-mono);
  font-size: var(--fs-label);
  text-transform: uppercase;
  letter-spacing: 2px;
  color: var(--accent-green);
  padding-bottom: 12px;
  border-bottom: 1px solid var(--accent-green-dim);
}

/* ===== PRICING ===== */
.pricing-section {
  padding: 16px 0 0;
}

/* 무료 샘플 모집 배너 */
.pricing-banner {
  text-align: center;
  padding: 32px 20px;
  margin-bottom: 8px;
  border: 1px solid rgba(0, 255, 163, 0.25);
  border-radius: 8px;
  background: rgba(0, 255, 163, 0.04);
}
.pricing-banner-badge {
  display: inline-block;
  font-family: var(--font-mono);
  font-size: var(--fs-micro);
  letter-spacing: 2px;
  padding: 4px 14px;
  border-radius: 3px;
  background: rgba(0, 255, 163, 0.15);
  color: var(--neon-green);
  font-weight: 600;
  margin-bottom: 14px;
}
.pricing-banner-text {
  font-size: var(--fs-heading-l);
  color: var(--text-primary);
  margin-bottom: 8px;
}
.pricing-banner-text strong {
  color: var(--neon-green);
}
.pricing-banner-sub {
  font-size: var(--fs-label);
  color: var(--text-muted);
  line-height: 1.6;
}

.pricing-price.free {
  color: var(--neon-green);
}

.pricing-card {
  padding: 28px 0;
  border-bottom: 1px solid var(--border-subtle);
}

.pricing-card:last-child {
  border-bottom: none;
}

.pricing-header {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 8px;
}

.pricing-tag {
  font-family: var(--font-mono);
  font-size: var(--fs-micro);
  letter-spacing: 1px;
  text-transform: uppercase;
  padding: 3px 8px;
  border-radius: 3px;
  font-weight: 600;
}

.pricing-tag.entry { background: var(--bg-elevated); color: var(--text-secondary); }
.pricing-tag.main { background: rgba(0, 255, 163, 0.12); color: var(--neon-green); }
.pricing-tag.addon { background: var(--bg-elevated); color: var(--text-secondary); }
.pricing-tag.subscribe { background: rgba(0, 255, 163, 0.06); color: var(--accent-green); }

.pricing-name {
  font-size: var(--fs-heading);
  font-weight: 600;
  letter-spacing: 0;
}

.pricing-price {
  font-family: var(--font-mono);
  font-size: var(--fs-heading);
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 10px;
}

.pricing-card.featured .pricing-name {
  color: var(--neon-green);
}
.sample-btn {
  font-family: var(--font-mono);
  font-size: var(--fs-ui);
  padding: 3px 10px;
  margin-left: 8px;
  background: transparent;
  border: 1px solid rgba(0, 255, 163, 0.35);
  color: var(--neon-green);
  border-radius: 4px;
  cursor: pointer;
  vertical-align: middle;
  transition: background 0.2s, border-color 0.2s;
  letter-spacing: 0.5px;
}
.sample-btn:hover {
  background: rgba(0, 255, 163, 0.1);
  border-color: var(--neon-green);
}

.pricing-card.featured .pricing-price {
  color: var(--text-primary);
}

.pricing-desc {
  font-size: var(--fs-body);
  color: var(--text-secondary);
  line-height: 1.7;
}

/* ===== SIGNAL CARDS (떡상/떡락) ===== */
.signal-section {
  padding: 0 0 40px;
}

.signal-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 24px;
}

.signal-col-label {
  font-family: var(--font-mono);
  font-size: var(--fs-micro);
  color: var(--text-muted);
  letter-spacing: 1.5px;
  text-transform: uppercase;
  margin-bottom: 12px;
  padding-left: 2px;
}

.signal-item {
  margin-bottom: 2px;
}

.signal-card {
  display: block;
  width: 100%;
  padding: 16px 18px;
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: 6px;
  cursor: pointer;
  transition: background 0.15s, border-color 0.15s;
  appearance: none;
  color: inherit;
  font: inherit;
  text-align: left;
}

.signal-card:hover {
  background: var(--bg-card-hover);
  border-color: var(--border);
}

.signal-card:focus-visible {
  outline: 2px solid var(--neon-green);
  outline-offset: 2px;
}

.signal-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 6px;
}

.signal-name {
  font-size: var(--fs-body);
  font-weight: 600;
  color: var(--text-primary);
}

.signal-badge {
  font-family: var(--font-mono);
  font-size: var(--fs-micro);
  color: var(--text-muted);
  letter-spacing: 0.5px;
}

.signal-stats {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 8px;
  font-family: var(--font-mono);
  font-size: var(--fs-label);
  color: var(--text-secondary);
}

.signal-delta {
  font-weight: 600;
}

.signal-delta.rise {
  color: var(--neon-green);
}

.signal-delta.fall {
  color: var(--accent-red);
}

.signal-caption {
  font-size: var(--fs-label);
  color: var(--text-muted);
  line-height: 1.5;
}

.signal-spark {
  display: block;
  width: 100%;
  height: 28px;
  margin-top: 10px;
}

/* Signal why (expandable) */
.signal-why {
  overflow: hidden;
  max-height: 0;
  opacity: 0;
  transition: max-height 0.3s ease, opacity 0.2s ease, padding 0.3s ease;
  padding: 0 18px;
  background: var(--bg-elevated);
  border-radius: 0 0 6px 6px;
  margin-top: -1px;
  border: 1px solid var(--border-subtle);
  border-top: none;
}

.signal-why.open {
  max-height: 300px;
  opacity: 1;
  padding: 14px 18px 16px;
}

.signal-why-label {
  font-family: var(--font-mono);
  font-size: var(--fs-micro);
  color: var(--text-muted);
  letter-spacing: 1px;
  text-transform: uppercase;
  margin-bottom: 6px;
}

.signal-why-text {
  font-size: var(--fs-label);
  color: var(--text-secondary);
  line-height: 1.7;
}

.signal-card[aria-expanded="true"] {
  border-radius: 6px 6px 0 0;
  border-color: var(--border);
  background: var(--bg-card-hover);
}

/* Category insight text */
.category-insight {
  padding: 0 0 32px;
  font-size: var(--fs-body);
  color: var(--text-secondary);
  line-height: 1.7;
}

/* ===== CTA SECTION ===== */
.cta-section {
  text-align: center;
  padding: 80px 32px 100px;
  max-width: 560px;
  margin: 0 auto;
}

.cta-section h2 {
  font-size: var(--fs-heading-l);
  font-weight: 600;
  letter-spacing: 0;
  margin-bottom: 14px;
}

.cta-section p {
  color: var(--text-secondary);
  margin-bottom: 32px;
  font-size: var(--fs-body);
}

.cta-btn {
  display: inline-block;
  padding: 14px 40px;
  background: var(--neon-green);
  color: #0a0a0e;
  font-size: var(--fs-ui);
  font-weight: 600;
  border-radius: 8px;
  text-decoration: none;
  transition: all 0.2s;
  font-family: var(--font-body);
  box-shadow: 0 0 12px rgba(0, 255, 163, 0.25), 0 0 32px rgba(0, 255, 163, 0.1);
}

.cta-btn:hover {
  background: #33ffb5;
  transform: translateY(-1px);
  box-shadow: 0 0 16px rgba(0, 255, 163, 0.4), 0 0 48px rgba(0, 255, 163, 0.15);
}

.cta-sub {
  margin-top: 16px;
  font-size: var(--fs-label);
  color: var(--text-muted);
}

/* ===== SCROLL ARROWS ===== */
.scroll-arrows {
  position: fixed;
  left: 50%;
  transform: translateX(-50%);
  bottom: 24px;
  display: flex;
  gap: 6px;
  z-index: 90;
}
.scroll-arrow {
  width: 36px;
  height: 36px;
  border: 1px solid var(--border);
  border-radius: 6px;
  background: rgba(26, 26, 32, 0.85);
  backdrop-filter: blur(8px);
  color: var(--text-muted);
  font-size: 1rem;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.15s;
}
.scroll-arrow:hover {
  border-color: rgba(0, 255, 163, 0.3);
  color: var(--neon-green);
  background: rgba(0, 255, 163, 0.06);
}

/* ===== OPERATOR INTRO ===== */
.operator-intro {
  border-top: 1px solid var(--border-subtle);
  padding: 40px 32px;
  text-align: center;
  max-width: 480px;
  margin: 0 auto;
}
.operator-intro .op-what {
  font-size: var(--fs-body);
  color: var(--text-secondary);
  line-height: 1.7;
}
.operator-intro .op-detail {
  font-size: var(--fs-body);
  color: var(--text-secondary);
  line-height: 1.7;
  margin-top: 6px;
}
.operator-intro .op-status {
  font-size: var(--fs-label);
  color: var(--neon-green);
  margin-top: 16px;
}
.operator-intro .op-sig {
  font-size: var(--fs-micro);
  color: var(--text-dim);
  margin-top: 20px;
  letter-spacing: 0.05em;
}

/* ===== FOOTER ===== */
footer {
  border-top: 1px solid var(--border-subtle);
  padding: 32px;
  text-align: center;
  font-size: var(--fs-label);
  color: var(--text-dim);
}

footer a {
  color: var(--text-dim);
  text-decoration: none;
}

footer a:hover {
  color: var(--text-secondary);
}

/* ===== SAMPLE REPORT MODAL ===== */
.sample-modal {
  position: fixed;
  inset: 0;
  z-index: 9999;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 24px;
  background: rgba(0, 0, 0, 0.85);
}

.sample-modal.open {
  display: flex;
}

.sample-modal-panel {
  position: relative;
  width: min(900px, 90vw);
  height: min(88vh, 900px);
  overflow: hidden;
  border-radius: 12px;
  box-shadow: 0 0 40px rgba(0, 255, 163, 0.15);
  display: flex;
  flex-direction: column;
  background: var(--bg-card);
}

.sample-modal-close {
  position: absolute;
  top: 12px;
  right: 14px;
  z-index: 10;
  width: 36px;
  height: 36px;
  border: 1px solid rgba(255,255,255,0.2);
  border-radius: 50%;
  background: rgba(0,0,0,0.7);
  color: #fff;
  cursor: pointer;
  font-size: 1rem;
  display: flex;
  align-items: center;
  justify-content: center;
}

.sample-tab-bar {
  display: flex;
  gap: 0;
  border-bottom: 1px solid rgba(255,255,255,0.08);
  padding: 0 16px;
  background: rgba(0,0,0,0.3);
  border-radius: 12px 12px 0 0;
  flex-shrink: 0;
}

.sample-tab {
  font-family: var(--font-mono);
  font-size: var(--fs-label);
  padding: 12px 16px;
  border: none;
  background: none;
  color: var(--text-muted);
  cursor: pointer;
  border-bottom: 2px solid transparent;
  transition: all 0.15s;
}

.sample-tab.active {
  color: var(--neon-green);
  border-bottom-color: var(--neon-green);
}

.sample-viewer {
  overflow-y: auto;
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  padding: 8px;
  background: #2a2a30;
  -webkit-user-select: none;
  user-select: none;
}

.sample-viewer img {
  width: 100%;
  max-width: 800px;
  height: auto;
  display: block;
  pointer-events: none;
}

.sample-page-info {
  text-align: center;
  font-family: var(--font-mono);
  font-size: var(--fs-micro);
  color: var(--text-muted);
  padding: 8px;
  flex-shrink: 0;
  background: var(--bg-card);
}

/* ===== DEMO DATA TAG ===== */
.demo-tag {
  margin-left: 10px;
  padding: 2px 8px;
  border: 1px solid var(--border);
  border-radius: 999px;
  font-family: var(--font-mono);
  font-size: var(--fs-micro);
  letter-spacing: 1px;
  color: var(--text-dim);
  vertical-align: middle;
}

/* ===== RESPONSIVE ===== */
@media (max-width: 1560px) {
  :root {
    --sidebar-w: 300px;
  }
}

@media (max-width: 1280px) {
  :root {
    --sidebar-w: 240px;
  }
  /* trend is now inline in s-stat */
}

@media (max-width: 860px) {
  body {
    overflow-x: hidden;
    overflow-y: auto;
    height: auto;
  }

  nav {
    height: auto;
    min-height: var(--nav-h);
    justify-content: flex-start;
    align-items: center;
    gap: 8px;
    padding: 10px 14px;
    flex-wrap: wrap;
  }

  .logo {
    position: static;
    transform: none;
    flex: 0 0 auto;
    margin-right: auto;
  }

  .nav-cats {
    order: 3;
    width: 100%;
    overflow-x: auto;
    padding: 2px 0;
    scrollbar-width: none;
  }

  .nav-cats::-webkit-scrollbar {
    display: none;
  }

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

  .nav-cta {
    position: static;
    order: 2;
    width: 100%;
    flex: 0 0 100%;
    padding: 8px 12px;
    font-size: var(--fs-ui);
  }

  .main-layout {
    display: flex;
    flex-direction: column;
    padding: 0 20px 80px;
    width: 100%;
    max-width: 100%;
    height: auto;
    overflow: visible;
    gap: 0;
  }

  .content {
    order: 1;
    width: 100%;
    max-width: 100%;
    padding: 0;
    min-width: 0;
    height: auto;
    overflow-y: visible;
  }

  .sidebar {
    position: fixed;
    top: 0;
    bottom: 0;
    width: 80vw;
    max-width: 340px;
    z-index: 99;
    height: 100%;
    padding: calc(var(--nav-h) + 20px) 12px 80px;
    display: flex;
    flex-direction: column;
    gap: 2px;
    overflow-y: auto;
    overflow-x: hidden;
    scrollbar-width: none;
    transition: transform 0.35s cubic-bezier(0.4, 0, 0.2, 1);
  }

  .sidebar-left {
    left: 0;
    transform: translateX(-100%);
    background: #e8e8ec;
    border-right: 1px solid var(--white-border);
  }

  .sidebar-right {
    right: 0;
    transform: translateX(100%);
    background: var(--bg-base);
    border-left: 1px solid rgba(0, 255, 163, 0.15);
  }

  .sidebar.panel-open {
    transform: translateX(0);
    box-shadow: 0 0 40px rgba(0,0,0,0.4);
  }

  .sidebar-right.panel-open {
    box-shadow: 0 0 40px rgba(0,0,0,0.4), 0 0 60px rgba(0, 255, 163, 0.06);
  }

  .sidebar::-webkit-scrollbar { display: none; }

  .team-header {
    display: none;
  }

  .sidebar.panel-open .team-header {
    display: block;
    text-align: center;
    padding: 16px 8px 20px;
    margin: 0;
  }

  .sidebar.panel-open .team-header .team-tooltip {
    display: none;
  }

  .s-card {
    display: none;
    min-width: 0;
    max-width: 100%;
  }

  .sidebar.panel-open .s-card {
    display: flex;
    padding: 16px 14px;
    min-height: 68px;
  }

  .sidebar-left.panel-open .s-card {
    justify-content: flex-start;
    text-align: left;
    flex-direction: row;
    background: rgba(255,255,255,0.5);
    border-color: rgba(0,0,0,0.06);
  }

  .sidebar-right.panel-open .s-card {
    flex-direction: row;
    justify-content: flex-start;
    text-align: left;
  }

  .s-card[style*="--img"]::after {
    display: none;
  }

  .s-name { font-size: 1.125rem; }

  .s-stat {
    font-size: var(--fs-micro);
    white-space: normal;
    overflow-wrap: anywhere;
  }

  .peek-handle {
    position: fixed;
    top: 50%;
    transform: translateY(-50%);
    z-index: 90;
    width: 32px;
    padding: 24px 4px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 10px;
    cursor: pointer;
    font-family: var(--font-mono);
    font-size: 0.45rem;
    letter-spacing: 0;
    text-transform: uppercase;
    writing-mode: vertical-lr;
    -webkit-tap-highlight-color: transparent;
    touch-action: manipulation;
    transition: transform 0.15s, opacity 0.25s;
  }

  .peek-handle:active {
    transform: translateY(-50%) scale(0.92);
  }

  .peek-handle:focus-visible {
    outline: 2px solid var(--neon-green);
    outline-offset: 3px;
  }

  .peek-handle-left {
    left: 0;
    background: var(--white-bg);
    color: var(--white-accent);
    border-radius: 0 6px 6px 0;
    border: 1px solid var(--white-border);
    border-left: none;
  }

  .peek-handle-right {
    right: 0;
    background: rgba(8, 8, 11, 0.92);
    color: var(--neon-green);
    border-radius: 6px 0 0 6px;
    border: 1px solid rgba(0, 255, 163, 0.25);
    border-right: none;
    text-shadow: 0 0 8px rgba(0, 255, 163, 0.3);
  }

  .peek-handle .peek-dot {
    width: 4px;
    height: 4px;
    border-radius: 50%;
    writing-mode: horizontal-tb;
    animation: peekPulse 2.5s ease-in-out infinite;
  }

  .peek-handle-left .peek-dot {
    background: var(--white-accent);
  }

  .peek-handle-right .peek-dot {
    background: var(--neon-green);
    box-shadow: 0 0 6px rgba(0, 255, 163, 0.5);
    animation-delay: 1.2s;
  }

  .peek-handle .peek-count {
    writing-mode: horizontal-tb;
    font-size: 0.55rem;
    font-weight: 700;
    opacity: 0.6;
    transition: opacity 0.3s;
  }

  @keyframes peekPulse {
    0%, 100% { opacity: 0.3; transform: scale(1); }
    50% { opacity: 1; transform: scale(1.5); }
  }

  .panel-backdrop {
    position: fixed;
    inset: 0;
    z-index: 98;
    background: rgba(0, 0, 0, 0.45);
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.35s;
    -webkit-tap-highlight-color: transparent;
  }

  .panel-backdrop.active {
    opacity: 1;
    pointer-events: auto;
  }

  body.panel-active .peek-handle {
    opacity: 0;
    pointer-events: none;
  }

  .scroll-arrows {
    display: none;
  }

  .hero { padding: 60px 20px 48px; }
  .hero h1 { font-size: var(--fs-heading-l); }
  .hero p,
  .content-intro p,
  .lesson-view,
  .pricing-desc,
  .pricing-price {
    overflow-wrap: anywhere;
    word-break: keep-all;
  }

  .lesson-body,
  .lesson-concept,
  .lesson-toggle { padding-left: 0; }

  .lesson-header { gap: 8px; }

  .pricing-header {
    align-items: flex-start;
  }

  .pricing-name {
    line-height: 1.5;
  }

  .sample-btn {
    margin-left: 6px;
  }

  .cta-section {
    padding: 64px 12px 80px;
  }
}

/* global scrollbar removed — each column has its own */

/* ===== MODAL ===== */
.modal-overlay {
  position: fixed;
  inset: 0;
  z-index: 200;
  background: rgba(10, 10, 14, 0.75);
  backdrop-filter: blur(6px);
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.25s;
}

.modal-overlay.open {
  opacity: 1;
  pointer-events: auto;
}

.modal-panel {
  position: fixed;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%) scale(0.96);
  z-index: 201;
  width: 520px;
  max-height: 80vh;
  overflow-y: auto;
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 36px 32px 28px;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.25s, transform 0.25s;
  scrollbar-width: thin;
  scrollbar-color: #2a2a32 transparent;
}

.modal-panel.open {
  opacity: 1;
  pointer-events: auto;
  transform: translate(-50%, -50%) scale(1);
}

.modal-panel.team-black {
  border-color: rgba(0, 255, 163, 0.2);
  box-shadow: 0 0 40px rgba(0, 255, 163, 0.08);
}

.modal-close {
  position: absolute;
  top: 14px;
  right: 16px;
  background: none;
  border: none;
  color: var(--text-muted);
  font-size: 1.2rem;
  cursor: pointer;
  padding: 4px 8px;
  line-height: 1;
}

.modal-close:hover { color: var(--text-primary); }

.modal-top {
  display: flex;
  align-items: center;
  gap: 16px;
  margin-bottom: 24px;
}

.modal-avatar {
  width: 64px;
  height: 64px;
  border-radius: 50%;
  object-fit: cover;
  flex-shrink: 0;
}

.modal-panel.team-black .modal-avatar {
  box-shadow: 0 0 12px rgba(0, 255, 163, 0.2);
}

.modal-name {
  font-size: var(--fs-heading);
  font-weight: 800;
  letter-spacing: 0;
}

.modal-rank {
  font-family: var(--font-mono);
  font-size: var(--fs-label);
  color: var(--text-muted);
  margin-top: 2px;
}

/* 지표 그리드 */
.modal-metrics {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  gap: 12px;
  margin-bottom: 24px;
}

.modal-metric {
  background: var(--bg-card);
  border-radius: 8px;
  padding: 14px 12px;
  text-align: center;
}

.modal-metric-label {
  font-family: var(--font-mono);
  font-size: var(--fs-micro);
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 1px;
  margin-bottom: 6px;
}

.modal-metric-value {
  font-family: var(--font-mono);
  font-size: 1rem;
  font-weight: 600;
  color: var(--text-primary);
}

.modal-metric-value.up { color: var(--neon-green); }
.modal-metric-value.down { color: var(--accent-red); }

/* 더미 차트 */
.modal-chart {
  width: 100%;
  height: 120px;
  margin-bottom: 24px;
  border-radius: 8px;
  background: var(--bg-card);
  position: relative;
  overflow: hidden;
}

.modal-chart canvas {
  width: 100%;
  height: 100%;
}

/* 해석 */
.modal-section-label {
  font-family: var(--font-mono);
  font-size: var(--fs-micro);
  color: var(--accent-green);
  text-transform: uppercase;
  letter-spacing: 1.5px;
  margin-bottom: 10px;
}

.modal-interpretation {
  font-size: var(--fs-body);
  color: var(--text-secondary);
  line-height: 1.75;
  margin-bottom: 20px;
}

.modal-interpretation strong {
  color: var(--text-primary);
  font-weight: 600;
}

.modal-cta {
  display: block;
  text-align: center;
  padding: 12px;
  background: rgba(0, 255, 163, 0.08);
  border: 1px solid rgba(0, 255, 163, 0.2);
  border-radius: 8px;
  color: var(--neon-green);
  font-size: var(--fs-ui);
  font-family: var(--font-mono);
  text-decoration: none;
  transition: all 0.15s;
  letter-spacing: 0.5px;
}

.modal-cta:hover {
  background: rgba(0, 255, 163, 0.14);
  border-color: rgba(0, 255, 163, 0.4);
}

@media (max-width: 600px) {
  html,
  body {
    max-width: 100%;
    overflow-x: hidden;
  }

  .main-layout {
    padding-inline: 16px;
  }

  .hero {
    padding: 56px 0 44px;
  }

  .hero p,
  .content-intro p {
    max-width: 34ch;
    font-size: var(--fs-body);
    word-break: keep-all;
    overflow-wrap: anywhere;
  }

  .hero p {
    margin-inline: auto;
  }

  .sample-modal {
    padding: 12px;
  }

  .sample-modal-panel {
    width: 100%;
    height: calc(100vh - 24px);
  }

  .modal-panel {
    width: calc(100vw - 32px);
    max-height: calc(100vh - 32px);
    padding: 32px 20px 24px;
  }

  .modal-metrics {
    grid-template-columns: 1fr 1fr;
  }

  .modal-chart {
    height: 120px;
  }

  /* Signal cards mobile */
  .signal-grid {
    grid-template-columns: 1fr;
    gap: 32px;
  }

  .signal-card {
    padding: 14px 16px;
  }

  .signal-why.open {
    padding: 12px 16px 14px;
  }
}
