:root {
  --bg: #0D0D0C;
  --bg-elevated: #141412;
  --surface: #1B1B18;
  --surface-strong: #242420;
  --surface-hover: #1E1E1B;
  --text: #F5F5F3;
  --text-muted: #A1A19A;
  --text-dim: #73736D;
  --accent: #E5943C;
  --accent-soft: rgba(229, 148, 60, 0.14);
  --btn-solid-bg: #F5F5F3;
  --btn-solid-text: #0D0D0C;
  --verified: #4ADE80;
  --verified-bg: rgba(74, 222, 128, 0.12);
  --seasonal: #FBBF24;
  --seasonal-bg: rgba(251, 191, 36, 0.12);
  --danger: #F87171;
  --divider: rgba(255, 255, 255, 0.09);
  --divider-strong: rgba(255, 255, 255, 0.18);
  --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.35);
  --shadow-md: 0 8px 24px rgba(0, 0, 0, 0.45);
  --radius-sm: 8px;
  --radius-md: 12px;
  --radius-lg: 16px;
  --font-sans: 'Pretendard Variable', 'Pretendard', -apple-system, BlinkMacSystemFont, 'Apple SD Gothic Neo', 'Malgun Gothic', sans-serif;
}

html[data-theme="hanji-guide"] {
  --bg: #FFFFFF;
  --bg-elevated: #FAFAFA;
  --surface: #F4F4F2;
  --surface-strong: #EAEAE6;
  --surface-hover: #F5F5F3;
  --text: #111111;
  --text-muted: #595959;
  --text-dim: #767676;
  --accent: #C2410C;
  --accent-soft: rgba(194, 65, 12, 0.09);
  --btn-solid-bg: #111111;
  --btn-solid-text: #FFFFFF;
  --verified: #15803D;
  --verified-bg: rgba(21, 128, 61, 0.09);
  --seasonal: #B45309;
  --seasonal-bg: rgba(180, 83, 9, 0.09);
  --danger: #B91C1C;
  --divider: #E8E8E5;
  --divider-strong: #D4D4D0;
  --shadow-sm: 0 1px 3px rgba(17, 17, 17, 0.06);
  --shadow-md: 0 8px 24px rgba(17, 17, 17, 0.08);
  color-scheme: light;
}

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

html, body {
  margin: 0;
  padding: 0;
  background-color: var(--bg);
  color: var(--text);
  font-family: var(--font-sans);
  font-size: 15px;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  color-scheme: dark;
  overflow-x: clip;
}

html[data-theme="hanji-guide"],
html[data-theme="hanji-guide"] body {
  color-scheme: light;
}

body.is-sheet-open {
  overflow: hidden;
  touch-action: none;
}

button, input, select, textarea {
  font-family: inherit;
  color: inherit;
}

button, a, .pill, .reel-card, .hub-chip, .boong-pin {
  outline: none;
  -webkit-tap-highlight-color: transparent;
}

button:focus-visible,
a:focus-visible,
select:focus-visible,
input:focus-visible,
textarea:focus-visible,
.reel-card:focus-visible,
.hub-chip:focus-visible,
.boong-pin:focus-visible {
  box-shadow: 0 0 0 2px var(--text);
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  border: 0;
}

.section-eyebrow {
  display: inline-block;
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--text-dim);
  margin-bottom: 4px;
}

/* ==================== MASTHEAD ==================== */
.masthead {
  background: var(--bg);
  border-bottom: 1px solid var(--divider);
  position: sticky;
  top: var(--ad-top, 0px);
  z-index: 1100;
}

.masthead-inner {
  max-width: 1360px;
  margin: 0 auto;
  padding: 14px 28px 0;
}

.masthead-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.brand {
  display: flex;
  align-items: center;
  gap: 11px;
  text-decoration: none;
  color: inherit;
}

.brand-emblem {
  width: 34px;
  height: 34px;
  aspect-ratio: 1 / 1;
  border-radius: 50%;
  object-fit: contain;
  flex-shrink: 0;
  border: 1px solid var(--divider);
}

.brand-wordmark {
  display: flex;
  flex-direction: column;
}

.brand-title {
  font-size: 1.12rem;
  font-weight: 800;
  letter-spacing: -0.03em;
  color: var(--text);
  line-height: 1.2;
}

.brand-sub {
  font-size: 0.75rem;
  color: var(--text-dim);
}

.masthead-actions {
  display: flex;
  align-items: center;
  gap: 10px;
}

.theme-switcher {
  display: inline-flex;
  align-items: center;
  padding: 3px;
  border-radius: 999px;
  border: 1px solid var(--divider);
  background: var(--surface);
  gap: 2px;
}

.theme-opt {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  padding: 0;
  border-radius: 50%;
  border: none;
  background: transparent;
  color: var(--text-muted);
  cursor: pointer;
  transition: background-color 0.15s ease, color 0.15s ease;
}

.theme-icon {
  width: 16px;
  height: 16px;
  display: block;
}

.theme-opt:hover {
  color: var(--text);
}

.theme-opt.is-active {
  background: var(--bg);
  color: var(--text);
  box-shadow: var(--shadow-sm);
}

.primary-nav {
  display: flex;
  align-items: center;
  gap: 24px;
  margin-top: 10px;
  overflow-x: auto;
  scrollbar-width: none;
}

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

.nav-tab {
  position: relative;
  background: none;
  border: none;
  padding: 9px 0 11px;
  font-size: 0.88rem;
  font-weight: 500;
  color: var(--text-muted);
  cursor: pointer;
  white-space: nowrap;
  transition: color 0.15s ease;
}

.nav-tab:hover {
  color: var(--text);
}

.nav-tab.is-active {
  color: var(--text);
  font-weight: 700;
}

.nav-tab.is-active::after {
  content: '';
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: 2px;
  background: var(--text);
}

/* ==================== BUTTONS ==================== */
.btn-iron {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 8px 16px;
  border-radius: 999px;
  border: 1px solid var(--divider-strong);
  background: transparent;
  color: var(--text);
  font-size: 0.84rem;
  font-weight: 600;
  cursor: pointer;
  transition: background-color 0.15s ease, border-color 0.15s ease;
}

.btn-iron:hover {
  background: var(--surface);
  border-color: var(--text);
}

.btn-iron-primary,
.btn-primary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 10px 20px;
  min-height: 44px;
  border-radius: 999px;
  border: 1px solid var(--btn-solid-bg);
  background: var(--btn-solid-bg);
  color: var(--btn-solid-text);
  font-size: 0.88rem;
  font-weight: 700;
  cursor: pointer;
  transition: opacity 0.15s ease;
}

.btn-iron-primary:hover,
.btn-primary:hover {
  opacity: 0.88;
}

.btn-iron-sm {
  padding: 7px 14px;
  font-size: 0.8rem;
}

.btn-poll-trigger,
.btn-secondary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 9px 18px;
  min-height: 44px;
  border-radius: 999px;
  border: 1px solid var(--divider-strong);
  background: var(--bg);
  color: var(--text);
  font-size: 0.86rem;
  font-weight: 600;
  cursor: pointer;
  transition: background-color 0.15s ease, border-color 0.15s ease;
}

.btn-poll-trigger:hover,
.btn-poll-trigger[aria-expanded="true"],
.btn-secondary:hover {
  background: var(--surface);
  border-color: var(--text);
}

.btn-text {
  background: none;
  border: none;
  padding: 6px 8px;
  color: var(--text);
  font-size: 0.84rem;
  font-weight: 600;
  cursor: pointer;
}

.btn-text:hover {
  text-decoration: underline;
}

/* ==================== MAIN CONTAINER & BANNER ==================== */
.container {
  max-width: 1360px;
  margin: 0 auto;
  padding: 24px 28px 72px;
}

.status-banner {
  margin-bottom: 18px;
  padding: 12px 16px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--divider);
  background: var(--surface);
  color: var(--text);
  font-size: 0.88rem;
}

.status-banner.is-error {
  border-color: var(--danger);
  color: var(--danger);
}

/* ==================== HERO SECTION ==================== */
.hero-stall-banner {
  position: relative;
  min-height: 340px;
  border-radius: var(--radius-lg);
  overflow: hidden;
  background: #111110;
  display: flex;
  align-items: flex-end;
  border: 1px solid var(--divider);
}

.hero-video {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: brightness(0.68) contrast(1.04);
}

.hero-scrim {
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, rgba(13, 13, 12, 0.88) 0%, rgba(13, 13, 12, 0.50) 56%, rgba(13, 13, 12, 0.72) 100%);
}

.hero-glow-border {
  display: none;
}

.hero-sound-orb {
  position: absolute;
  top: 18px;
  right: 18px;
  z-index: 4;
  width: 38px;
  height: 38px;
  border-radius: 50%;
  border: 1px solid rgba(255, 255, 255, 0.24);
  background: rgba(13, 13, 12, 0.60);
  backdrop-filter: blur(8px);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
}

.hero-sound-svg {
  width: 18px;
  height: 18px;
}

.orb-flame-fill {
  stroke: #A1A19A;
  fill: none;
}

.orb-flame-core {
  fill: transparent;
}

.orb-mute-slash {
  stroke: #A1A19A;
}

.hero-sound-orb.is-lit .orb-flame-fill {
  stroke: #F5F5F3;
  fill: rgba(245, 245, 243, 0.28);
}

.hero-sound-orb.is-lit .orb-flame-core {
  fill: #FFFFFF;
}

.hero-sound-orb.is-lit .orb-mute-slash {
  opacity: 0;
}

.editorial-intro.hero-overlay {
  position: relative;
  z-index: 3;
  width: 100%;
  padding: 40px 36px 32px;
  display: grid;
  grid-template-columns: minmax(0, 1.55fr) minmax(220px, 0.6fr);
  align-items: end;
  gap: 36px;
}

.hero-kicker-row {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 12px;
}

.hero-chapter-seal {
  width: 36px;
  height: 36px;
  aspect-ratio: 1 / 1;
  border-radius: 50%;
  object-fit: contain;
  flex-shrink: 0;
  border: 1px solid rgba(255, 255, 255, 0.18);
}

.hero-kicker-meta {
  display: flex;
  flex-direction: column;
  gap: 1px;
}

.intro-kicker {
  margin: 0;
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: rgba(245, 245, 243, 0.72);
}

.hero-season-pill {
  font-size: 0.76rem;
  color: rgba(245, 245, 243, 0.62);
}

.intro-heading {
  margin: 0 0 10px;
  font-size: clamp(1.85rem, 3.4vw, 2.65rem);
  font-weight: 800;
  letter-spacing: -0.035em;
  line-height: 1.15;
  color: #FFFFFF;
}

.intro-desc {
  margin: 0 0 20px;
  max-width: 540px;
  font-size: 0.94rem;
  color: rgba(245, 245, 243, 0.80);
  line-height: 1.6;
}

.hero-cta-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px;
}

.hero-stall-banner .btn-poll-trigger {
  background: rgba(255, 255, 255, 0.10);
  border-color: rgba(255, 255, 255, 0.24);
  color: #FFFFFF;
}

.hero-stall-banner .btn-poll-trigger:hover {
  background: rgba(255, 255, 255, 0.18);
}

.hero-side {
  border-left: 1px solid rgba(255, 255, 255, 0.14);
  padding-left: 24px;
}

.intro-stats {
  margin: 0;
  display: grid;
  grid-template-columns: 1fr;
  gap: 10px;
}

.stat-item {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
  padding-bottom: 8px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.10);
}

.stat-item:last-child {
  padding-bottom: 0;
  border-bottom: none;
}

.stat-item dt {
  font-size: 0.78rem;
  color: rgba(245, 245, 243, 0.65);
}

.stat-item dd {
  margin: 0;
  font-size: 1.2rem;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
  color: #FFFFFF;
}

/* Light theme hero: clean commercial split cover */
html[data-theme="hanji-guide"] .hero-stall-banner {
  min-height: 340px;
  background: var(--bg-elevated);
  border: 1px solid var(--divider);
  align-items: stretch;
}

html[data-theme="hanji-guide"] .hero-video {
  left: auto;
  right: 20px;
  top: 20px;
  bottom: 20px;
  width: 44%;
  height: calc(100% - 40px);
  border-radius: var(--radius-md);
  filter: none;
}

html[data-theme="hanji-guide"] .hero-scrim {
  display: none;
}

html[data-theme="hanji-guide"] .hero-sound-orb {
  top: 32px;
  right: 32px;
}

html[data-theme="hanji-guide"] .editorial-intro.hero-overlay {
  width: 54%;
  padding: 32px 24px 30px 32px;
  grid-template-columns: 1fr;
  align-content: space-between;
  gap: 20px;
}

html[data-theme="hanji-guide"] .hero-chapter-seal {
  border-color: var(--divider);
}

html[data-theme="hanji-guide"] .intro-kicker,
html[data-theme="hanji-guide"] .hero-season-pill {
  color: var(--text-dim);
}

html[data-theme="hanji-guide"] .intro-heading {
  color: var(--text);
}

html[data-theme="hanji-guide"] .intro-desc {
  color: var(--text-muted);
}

html[data-theme="hanji-guide"] .hero-stall-banner .btn-poll-trigger {
  background: var(--bg);
  border-color: var(--divider-strong);
  color: var(--text);
}

html[data-theme="hanji-guide"] .hero-stall-banner .btn-poll-trigger:hover {
  background: var(--surface);
}

html[data-theme="hanji-guide"] .hero-side {
  border-left: none;
  border-top: 1px solid var(--divider);
  padding-left: 0;
  padding-top: 14px;
}

html[data-theme="hanji-guide"] .intro-stats {
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 16px;
}

html[data-theme="hanji-guide"] .stat-item {
  flex-direction: column;
  gap: 2px;
  border-bottom: none;
  padding-bottom: 0;
}

html[data-theme="hanji-guide"] .stat-item dt {
  color: var(--text-dim);
}

html[data-theme="hanji-guide"] .stat-item dd {
  color: var(--text);
}

/* ==================== TASTE POLL DRAWER ==================== */
.taste-poll-drawer {
  margin-top: 20px;
  padding: 24px 28px;
  border-radius: var(--radius-md);
  border: 1px solid var(--divider);
  background: var(--bg-elevated);
}

.poll-header {
  display: flex;
  align-items: center;
  gap: 18px;
  margin-bottom: 20px;
}

.poll-thumbs {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-shrink: 0;
}

.poll-thumbs img {
  object-fit: contain;
}

.poll-title {
  margin: 0 0 3px;
  font-size: 1.12rem;
  font-weight: 700;
  letter-spacing: -0.02em;
}

.poll-sub {
  margin: 0;
  font-size: 0.86rem;
  color: var(--text-muted);
}

.poll-choices {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  gap: 20px 28px;
}

.poll-group {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.poll-group-label {
  font-size: 0.78rem;
  font-weight: 600;
  color: var(--text-muted);
}

.poll-chip-row {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.poll-submit-wrap {
  margin-left: auto;
}

.poll-result-area {
  margin-top: 20px;
  padding-top: 16px;
  border-top: 1px solid var(--divider);
}

.poll-result-area h3 {
  margin: 0 0 4px;
  font-size: 1.02rem;
  font-weight: 700;
}

.poll-result-area p {
  margin: 0 0 12px;
  font-size: 0.86rem;
  color: var(--text-muted);
}

.poll-rec-list {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
}

.poll-rec-item {
  text-align: left;
  background: var(--bg);
  border: 1px solid var(--divider);
  border-radius: var(--radius-sm);
  padding: 12px 14px;
  cursor: pointer;
  display: flex;
  flex-direction: column;
  gap: 3px;
}

.poll-rec-item:hover {
  border-color: var(--text);
}

.poll-rec-item strong {
  font-size: 0.9rem;
  color: var(--text);
}

.poll-rec-item span {
  font-size: 0.78rem;
  color: var(--text-muted);
}

.poll-bars-area {
  margin-top: 16px;
  padding-top: 14px;
  border-top: 1px solid var(--divider);
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 18px 28px;
}

.poll-bar-group {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.poll-bar-group h4 {
  margin: 0 0 2px;
  font-size: 0.78rem;
  font-weight: 600;
  color: var(--text-muted);
}

.poll-bar-row {
  display: grid;
  grid-template-columns: 108px 1fr 44px;
  align-items: center;
  gap: 10px;
  font-size: 0.8rem;
}

.poll-bar-track {
  height: 5px;
  border-radius: 999px;
  background: var(--surface-strong);
  overflow: hidden;
}

.poll-bar-fill {
  height: 100%;
  border-radius: 999px;
  background: var(--text);
}

/* ==================== 4-ACT VIDEO REEL STRIP ==================== */
.craft-reel-section {
  margin-top: 32px;
}

.reel-section-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 12px;
}

.reel-kicker {
  display: none;
}

.reel-heading {
  margin: 0;
  font-size: 1.04rem;
  font-weight: 700;
  letter-spacing: -0.02em;
}

.reel-sub {
  font-size: 0.8rem;
  color: var(--text-dim);
}

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

.reel-card {
  position: relative;
  height: 132px;
  padding: 0;
  border: 1px solid var(--divider);
  border-radius: var(--radius-md);
  overflow: hidden;
  background: #141412;
  cursor: pointer;
  text-align: left;
  transition: transform 0.16s ease, border-color 0.16s ease;
}

.reel-card:hover {
  transform: translateY(-2px);
}

.reel-card.is-active {
  border-color: var(--text);
}

.reel-video {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: brightness(0.74);
  transition: transform 0.3s ease;
}

.reel-card:hover .reel-video {
  transform: scale(1.03);
}

.reel-scrim {
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(0, 0, 0, 0.08) 0%, rgba(0, 0, 0, 0.78) 100%);
}

.reel-meta {
  position: absolute;
  left: 14px;
  right: 14px;
  bottom: 12px;
  display: flex;
  flex-direction: column;
  gap: 1px;
}

.reel-act {
  font-size: 0.64rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  color: rgba(255, 255, 255, 0.72);
}

.reel-meta strong {
  font-size: 0.92rem;
  font-weight: 700;
  color: #FFFFFF;
}

.reel-meta span:last-child {
  font-size: 0.74rem;
  color: rgba(255, 255, 255, 0.78);
}

/* ==================== INTERACTIVE MAP SECTION ==================== */
.map-radar-section {
  margin-top: 36px;
  padding-top: 24px;
  border-top: 1px solid var(--divider);
}

.map-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 14px;
}

.map-kicker-row {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 2px;
}

.map-title {
  margin: 0;
  font-size: 1.12rem;
  font-weight: 700;
  letter-spacing: -0.02em;
}

.map-mode-badge {
  font-size: 0.74rem;
  font-weight: 600;
  color: var(--text-muted);
  padding: 2px 8px;
  border-radius: 999px;
  background: var(--surface);
}

.map-status-line {
  margin: 0;
  font-size: 0.84rem;
  color: var(--text-muted);
}

.map-legend {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-top: 6px;
  font-size: 0.76rem;
  color: var(--text-dim);
}

.legend-item {
  display: inline-flex;
  align-items: center;
  gap: 5px;
}

.legend-dot {
  display: inline-block;
  width: 9px;
  height: 9px;
  border-radius: 50%;
}

.legend-dot-seed {
  background: var(--accent);
}

.legend-dot-user {
  background: var(--verified);
}

.map-header-actions {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-shrink: 0;
}

.btn-map-toggle {
  padding: 7px 14px;
  border-radius: 999px;
  border: 1px solid var(--divider);
  background: transparent;
  color: var(--text-muted);
  font-size: 0.8rem;
  font-weight: 600;
  cursor: pointer;
}

.btn-map-toggle:hover {
  color: var(--text);
  border-color: var(--divider-strong);
}

.hub-quick-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-bottom: 12px;
}

.hub-chip {
  padding: 6px 12px;
  border-radius: 999px;
  border: 1px solid var(--divider);
  background: var(--bg);
  color: var(--text-muted);
  font-size: 0.78rem;
  font-weight: 500;
  cursor: pointer;
  transition: border-color 0.15s ease, color 0.15s ease, background-color 0.15s ease;
}

.hub-chip:hover {
  border-color: var(--text);
  color: var(--text);
}

.hub-chip.is-active {
  background: var(--btn-solid-bg);
  border-color: var(--btn-solid-bg);
  color: var(--btn-solid-text);
  font-weight: 600;
}

.holy-grail-map {
  position: relative;
  height: 350px;
  width: 100%;
  border-radius: var(--radius-md);
  border: 1px solid var(--divider);
  background: var(--surface);
  overflow: hidden;
}

.svg-radar-grid {
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(to right, var(--divider) 1px, transparent 1px),
    linear-gradient(to bottom, var(--divider) 1px, transparent 1px);
  background-size: 48px 48px;
  pointer-events: none;
}

.radar-user-pulse {
  position: absolute;
  width: 14px;
  height: 14px;
  border-radius: 50%;
  background: var(--accent);
  box-shadow: 0 0 0 5px var(--accent-soft);
  transform: translate(-50%, -50%);
  z-index: 30;
}

.boong-leaflet-icon {
  background: transparent;
  border: none;
}

/* Crisp Fresha / GetYourGuide pill map pins */
.boong-pin {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 4px 10px 4px 5px;
  border-radius: 999px;
  border: 1px solid var(--divider-strong);
  background: var(--bg);
  color: var(--text);
  font-size: 0.74rem;
  font-weight: 600;
  white-space: nowrap;
  cursor: pointer;
  box-shadow: var(--shadow-md);
  transition: transform 0.14s ease, background-color 0.14s ease;
}

.boong-pin:hover,
.boong-pin.is-selected {
  background: var(--btn-solid-bg);
  border-color: var(--btn-solid-bg);
  color: var(--btn-solid-text);
  transform: scale(1.05);
  z-index: 950 !important;
}

.boong-pin-rank {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 19px;
  height: 19px;
  padding: 0 4px;
  border-radius: 999px;
  background: var(--surface-strong);
  color: var(--text);
  font-size: 0.66rem;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
}

.boong-pin.is-top .boong-pin-rank,
.boong-pin.is-selected .boong-pin-rank {
  background: var(--accent);
  color: #FFFFFF;
}

.boong-pin.is-user-origin .boong-pin-rank {
  background: var(--verified);
  color: #FFFFFF;
}

.boong-pin.is-compact,
.holy-grail-map:not(.is-zoomed-in) .boong-pin:not(.is-top):not(.is-selected) {
  padding: 0;
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: var(--accent);
  border: 1.5px solid var(--bg);
  justify-content: center;
  box-shadow: 0 1px 4px rgba(0, 0, 0, 0.3);
}

.boong-pin.is-user-origin.is-compact,
.holy-grail-map:not(.is-zoomed-in) .boong-pin.is-user-origin:not(.is-top):not(.is-selected) {
  background: var(--verified);
  width: 11px;
  height: 11px;
}

.boong-pin.is-compact .boong-pin-rank,
.boong-pin.is-compact .boong-pin-label,
.holy-grail-map:not(.is-zoomed-in) .boong-pin:not(.is-top):not(.is-selected) .boong-pin-rank,
.holy-grail-map:not(.is-zoomed-in) .boong-pin:not(.is-top):not(.is-selected) .boong-pin-label {
  display: none;
}

.leaflet-container {
  background: var(--surface);
  font-family: var(--font-sans);
}

.leaflet-tile-pane {
  filter: invert(1) hue-rotate(180deg) brightness(0.82) contrast(1.04) saturate(0.35);
}

html[data-theme="hanji-guide"] .leaflet-tile-pane {
  filter: saturate(0.75) contrast(0.98);
}

.leaflet-bar a,
.leaflet-bar a:hover {
  background-color: var(--bg);
  color: var(--text);
  border-bottom-color: var(--divider);
}

.leaflet-control-attribution {
  background: var(--bg) !important;
  color: var(--text-dim) !important;
  opacity: 0.85;
}

.leaflet-control-attribution a {
  color: var(--text-muted) !important;
}

.map-nearby-strip {
  margin-top: 14px;
}

.nearby-caption {
  display: block;
  font-size: 0.78rem;
  color: var(--text-dim);
  margin-bottom: 8px;
}

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

.nearby-card {
  text-align: left;
  background: var(--bg);
  border: 1px solid var(--divider);
  border-radius: var(--radius-sm);
  padding: 12px 14px;
  cursor: pointer;
  display: flex;
  flex-direction: column;
  gap: 3px;
  transition: border-color 0.14s ease, background-color 0.14s ease;
}

.nearby-card:hover,
.nearby-card.is-selected {
  border-color: var(--text);
  background: var(--surface);
}

.nearby-card-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 0.75rem;
}

.nearby-dist {
  color: var(--accent);
  font-weight: 700;
  font-variant-numeric: tabular-nums;
}

.nearby-score {
  color: var(--text-muted);
  font-variant-numeric: tabular-nums;
}

.nearby-card strong {
  font-size: 0.9rem;
  font-weight: 700;
  color: var(--text);
}

.nearby-meta {
  font-size: 0.76rem;
  color: var(--text-muted);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* ==================== FILTER BAR (FRESHA / DOORDASH CLEAN PILLS) ==================== */
.filter-bar {
  margin-top: 32px;
  padding: 16px 0;
  border-top: 1px solid var(--divider);
  border-bottom: 1px solid var(--divider);
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 12px 20px;
}

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

.pill {
  padding: 7px 14px;
  border-radius: 999px;
  border: 1px solid var(--divider);
  background: var(--bg);
  color: var(--text-muted);
  font-size: 0.82rem;
  font-weight: 500;
  cursor: pointer;
  transition: border-color 0.14s ease, background-color 0.14s ease, color 0.14s ease;
}

.pill:hover {
  border-color: var(--text);
  color: var(--text);
}

.pill.is-active {
  background: var(--btn-solid-bg);
  border-color: var(--btn-solid-bg);
  color: var(--btn-solid-text);
  font-weight: 600;
}

.filter-controls {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
}

.select-minimal,
.search-input {
  height: 36px;
  padding: 0 13px;
  border-radius: 999px;
  border: 1px solid var(--divider);
  background: var(--bg);
  color: var(--text);
  font-size: 0.82rem;
  transition: border-color 0.14s ease;
}

.select-minimal:hover,
.search-input:hover,
.select-minimal:focus,
.search-input:focus {
  border-color: var(--text);
}

.search-input {
  width: 210px;
  background: var(--surface);
}

.search-input::placeholder {
  color: var(--text-dim);
}

/* ==================== BOARD LAYOUT (CLEAN DIRECTORY LIST + STICKY DETAIL) ==================== */
.board-layout {
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(380px, 0.9fr);
  gap: 32px;
  align-items: start;
  margin-top: 12px;
}

.leaderboard-column {
  min-width: 0;
}

.leaderboard-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 10px 12px 12px;
  border-bottom: 1px solid var(--divider);
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--text-dim);
}

.leaderboard-list {
  list-style: none;
  margin: 0;
  padding: 6px 0 0;
}

.leaderboard-list.is-flipping {
  animation: subtleFade 0.2s ease;
}

@keyframes subtleFade {
  from { opacity: 0.55; }
  to { opacity: 1; }
}

/* Clean commercial directory row: zero left accent bar, zero badge soup, 3 crisp lines */
.rank-row {
  display: grid;
  grid-template-columns: 34px minmax(0, 1fr) 64px;
  gap: 14px;
  align-items: start;
  padding: 16px 12px;
  border-radius: var(--radius-md);
  border: 1px solid transparent;
  border-bottom-color: var(--divider);
  cursor: pointer;
  transition: background-color 0.14s ease, border-color 0.14s ease;
}

.rank-row:hover {
  background: var(--surface-hover);
}

.rank-row.is-selected {
  background: var(--surface);
  border-color: var(--divider-strong);
}

.rank-col {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  padding-top: 2px;
  gap: 2px;
}

.rank-number {
  font-size: 0.92rem;
  font-weight: 700;
  line-height: 1.2;
  font-variant-numeric: tabular-nums;
  color: var(--text-dim);
}

.rank-number.is-top {
  color: var(--text);
}

.rank-dist-sub {
  font-size: 0.7rem;
  font-weight: 600;
  color: var(--accent);
  font-variant-numeric: tabular-nums;
}

.row-body {
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.row-head {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 8px;
}

.row-name {
  font-size: 0.98rem;
  font-weight: 700;
  color: var(--text);
  letter-spacing: -0.02em;
  line-height: 1.3;
}

/* Tripadvisor-style clean text-only status label */
.row-status {
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--text-dim);
}

.row-status.badge-verified {
  color: var(--verified);
}

.row-origin-user {
  display: inline-flex;
  align-items: center;
  padding: 1px 7px;
  border-radius: 999px;
  background: var(--verified-bg);
  color: var(--verified);
  font-size: 0.7rem;
  font-weight: 700;
}

.badge-user-origin {
  background: var(--verified-bg);
  color: var(--verified);
}

.store-photo-gallery {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(110px, 1fr));
  gap: 8px;
  margin: 0 0 18px;
}

.store-photo-link {
  display: block;
  aspect-ratio: 4 / 3;
  border-radius: var(--radius-sm);
  overflow: hidden;
  border: 1px solid var(--divider);
  background: var(--surface);
}

.store-photo-link img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.row-status.badge-seasonal {
  color: var(--seasonal);
}

.row-distance {
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--accent);
  font-variant-numeric: tabular-nums;
}

.row-meta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 2px 0;
  font-size: 0.8rem;
  color: var(--text-muted);
}

.meta-item {
  display: inline-flex;
  align-items: center;
}

.meta-item + .meta-item::before {
  content: '/';
  margin: 0 7px;
  color: var(--divider-strong);
  font-weight: 400;
}

.meta-district {
  color: var(--text);
  font-weight: 500;
}

.row-menus {
  margin: 0;
  font-size: 0.8rem;
  color: var(--text-dim);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.row-score-col {
  text-align: right;
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 2px;
  padding-top: 1px;
}

.row-score-value {
  font-size: 1.08rem;
  font-weight: 800;
  line-height: 1.2;
  letter-spacing: -0.02em;
  font-variant-numeric: tabular-nums;
  color: var(--text);
}

.rank-row.is-selected .row-score-value {
  color: var(--accent);
}

.row-score-sub {
  font-size: 0.72rem;
  color: var(--text-dim);
  font-variant-numeric: tabular-nums;
}

.badge {
  display: inline-flex;
  align-items: center;
  padding: 2px 8px;
  border-radius: 6px;
  background: var(--surface);
  color: var(--text-muted);
  font-size: 0.74rem;
  font-weight: 600;
}

.badge-verified {
  background: var(--verified-bg);
  color: var(--verified);
}

.badge-seasonal {
  background: var(--seasonal-bg);
  color: var(--seasonal);
}

.leaderboard-pagination {
  margin-top: 20px;
  padding-top: 14px;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 10px;
}

.pagination-status {
  width: 100%;
  text-align: center;
  margin: 0 0 4px;
  font-size: 0.8rem;
  color: var(--text-dim);
}

.empty-state {
  padding: 48px 20px;
  text-align: center;
  color: var(--text-muted);
}

/* ==================== DETAIL PANEL (CLEAN STICKY CARD LIKE FRESHA / TRIPADVISOR) ==================== */
.detail-backdrop {
  display: none;
}

.detail-panel {
  position: sticky;
  top: 106px;
  max-height: calc(100vh - 126px);
  overflow-y: auto;
  scrollbar-width: thin;
  scrollbar-color: var(--divider-strong) transparent;
}

.sheet-peek-spacer,
.detail-mobile-bar {
  display: none;
}

.sheet-surface {
  background: var(--bg);
  border: 1px solid var(--divider);
  border-radius: var(--radius-lg);
  padding: 26px 26px 32px;
  box-shadow: var(--shadow-sm);
}

.detail-placeholder {
  margin: 0;
  padding: 40px 12px;
  text-align: center;
  color: var(--text-dim);
  font-size: 0.88rem;
}

.detail-feedback {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 16px;
  padding: 10px 14px;
  border-radius: var(--radius-sm);
  background: var(--verified-bg);
  color: var(--text);
  font-size: 0.84rem;
}

.detail-feedback.is-error {
  background: rgba(185, 28, 28, 0.10);
  color: var(--danger);
}

.feedback-bag-icon {
  object-fit: contain;
  flex-shrink: 0;
}

.detail-kicker {
  font-size: 0.74rem;
  font-weight: 600;
  color: var(--text-dim);
  margin-bottom: 6px;
}

.detail-title {
  margin: 0 0 4px;
  font-size: 1.48rem;
  font-weight: 800;
  line-height: 1.24;
  letter-spacing: -0.03em;
}

.detail-address {
  margin: 0 0 12px;
  font-size: 0.84rem;
  color: var(--text-muted);
}

.detail-summary {
  margin: 0 0 18px;
  font-size: 0.9rem;
  color: var(--text);
  line-height: 1.62;
}

.detail-facts {
  margin: 0 0 18px;
  padding: 14px 0;
  border-top: 1px solid var(--divider);
  border-bottom: 1px solid var(--divider);
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px 16px;
}

.detail-facts > div {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.detail-facts dt {
  font-size: 0.72rem;
  color: var(--text-dim);
}

.detail-facts dd {
  margin: 0;
  font-size: 0.86rem;
  font-weight: 600;
  color: var(--text);
}

.location-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 22px;
}

.action-chip {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 7px 14px;
  min-height: 36px;
  border-radius: 999px;
  border: 1px solid var(--divider-strong);
  background: var(--bg);
  color: var(--text);
  font-size: 0.8rem;
  font-weight: 600;
  text-decoration: none;
  cursor: pointer;
  transition: background-color 0.14s ease, border-color 0.14s ease;
}

.action-chip:hover {
  background: var(--surface);
  border-color: var(--text);
}

.action-chip-accent {
  background: var(--btn-solid-bg);
  border-color: var(--btn-solid-bg);
  color: var(--btn-solid-text);
}

.action-chip-accent:hover {
  background: var(--btn-solid-bg);
  opacity: 0.88;
}

/* ==================== SPLIT ANATOMY STAGE ==================== */
.anatomy-stage {
  margin: 20px 0 22px;
  padding: 18px 0 20px;
  border-top: 1px solid var(--divider);
  border-bottom: 1px solid var(--divider);
}

.anatomy-topbar {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 10px;
}

.anatomy-title {
  margin: 0 0 2px;
  font-size: 0.96rem;
  font-weight: 700;
  letter-spacing: -0.02em;
}

.anatomy-subtitle {
  margin: 0;
  font-size: 0.78rem;
  color: var(--text-muted);
}

.anatomy-toggle-btn {
  padding: 5px 12px;
  border-radius: 999px;
  border: 1px solid var(--divider-strong);
  background: var(--bg);
  color: var(--text);
  font-size: 0.76rem;
  font-weight: 600;
  white-space: nowrap;
  cursor: pointer;
}

.anatomy-toggle-btn:hover {
  background: var(--surface);
}

.filling-tab-row {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-bottom: 12px;
}

.filling-tab-btn {
  padding: 5px 11px;
  border-radius: 999px;
  border: 1px solid var(--divider);
  background: var(--bg);
  color: var(--text-muted);
  font-size: 0.76rem;
  font-weight: 600;
  cursor: pointer;
}

.filling-tab-btn.is-active {
  background: var(--btn-solid-bg);
  border-color: var(--btn-solid-bg);
  color: var(--btn-solid-text);
}

.anatomy-canvas {
  position: relative;
  height: 200px;
  border-radius: var(--radius-md);
  overflow: hidden;
  background: var(--surface);
  border: 1px solid var(--divider);
  cursor: pointer;
  user-select: none;
}

.steam-canvas {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  z-index: 3;
}

.anatomy-rig {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 2;
}

.rig-img {
  position: absolute;
  max-width: 76%;
  max-height: 74%;
  object-fit: contain;
  pointer-events: none;
  filter: drop-shadow(0 10px 18px rgba(0, 0, 0, 0.28));
}

.rig-split-img {
  opacity: calc(0.2 + var(--tear, 0) * 0.8);
  transform: scale(calc(0.94 + var(--tear, 0) * 0.07));
}

.rig-whole-top {
  clip-path: inset(0 0 49% 0);
  opacity: calc(1 - var(--tear, 0) * 0.96);
  transform: translateY(calc(var(--tear, 0) * -26px)) rotate(calc(var(--tear, 0) * -4deg));
}

.rig-whole-bottom {
  clip-path: inset(49% 0 0 0);
  opacity: calc(1 - var(--tear, 0) * 0.96);
  transform: translateY(calc(var(--tear, 0) * 26px)) rotate(calc(var(--tear, 0) * 4deg));
}

.tear-seam-guide {
  position: absolute;
  left: 16%;
  right: 16%;
  top: 50%;
  height: 1px;
  border-top: 1px dashed var(--divider-strong);
  opacity: calc(1 - var(--tear, 0));
  pointer-events: none;
}

.anatomy-hud {
  position: absolute;
  inset: 10px;
  z-index: 4;
  pointer-events: none;
}

.hud-pin {
  position: absolute;
  padding: 4px 9px;
  border-radius: 6px;
  background: var(--bg);
  border: 1px solid var(--divider);
  font-size: 0.7rem;
  display: flex;
  align-items: baseline;
  gap: 5px;
  box-shadow: var(--shadow-sm);
}

.hud-pin span {
  color: var(--text-dim);
}

.hud-pin strong {
  color: var(--text);
  font-variant-numeric: tabular-nums;
}

.hud-pin-tl { top: 0; left: 0; }
.hud-pin-tr { top: 0; right: 0; }
.hud-pin-bl { bottom: 0; left: 0; }

.anatomy-footer {
  margin-top: 12px;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

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

.measurement-card {
  padding: 8px 0;
  border-bottom: 1px solid var(--divider);
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.measurement-card span {
  font-size: 0.72rem;
  color: var(--text-dim);
}

.measurement-card strong {
  font-size: 0.84rem;
  color: var(--text);
}

.tail-xray-head {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  font-size: 0.76rem;
  color: var(--text-muted);
  margin-bottom: 5px;
}

.tail-xray-head strong {
  color: var(--text);
}

.tail-xray-bar {
  height: 5px;
  border-radius: 999px;
  background: var(--surface-strong);
  overflow: hidden;
}

.tail-xray-fill {
  height: 100%;
  border-radius: 999px;
  background: var(--accent);
}

.tail-xray-axis {
  display: flex;
  justify-content: space-between;
  font-size: 0.68rem;
  color: var(--text-dim);
  margin-top: 4px;
}

/* ==================== SCORE BREAKDOWN & SOURCES ==================== */
.section-label {
  margin: 0 0 12px;
  font-size: 0.78rem;
  font-weight: 700;
  color: var(--text);
  letter-spacing: -0.01em;
}

.score-breakdown-section,
.sources-section,
.reviews-section,
.review-form-section {
  margin-top: 22px;
  padding-top: 18px;
  border-top: 1px solid var(--divider);
}

.score-headline {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  margin-bottom: 10px;
}

.score-headline strong {
  font-size: 1.75rem;
  font-weight: 800;
  letter-spacing: -0.03em;
  color: var(--text);
  font-variant-numeric: tabular-nums;
}

.score-headline span {
  font-size: 0.78rem;
  color: var(--text-dim);
}

.stacked-bar {
  display: flex;
  height: 6px;
  border-radius: 999px;
  overflow: hidden;
  gap: 2px;
  margin-bottom: 14px;
  background: var(--surface-strong);
}

.seg-ext { background: var(--text-dim); }
.seg-site { background: var(--accent); }
.seg-surv { background: var(--verified); }

.axis-row {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  font-size: 0.82rem;
  margin-bottom: 5px;
  color: var(--text-muted);
}

.axis-row strong {
  color: var(--text);
  font-variant-numeric: tabular-nums;
}

.axis-track {
  height: 4px;
  border-radius: 999px;
  background: var(--surface-strong);
  margin-bottom: 12px;
  overflow: hidden;
}

.axis-fill {
  height: 100%;
  border-radius: 999px;
  background: var(--text);
}

.subscore-strip {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 8px;
  margin-top: 14px;
  padding-top: 14px;
  border-top: 1px solid var(--divider);
}

.subscore-item {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.subscore-item span {
  font-size: 0.72rem;
  color: var(--text-dim);
}

.subscore-item strong {
  font-size: 0.9rem;
  color: var(--text);
  font-variant-numeric: tabular-nums;
}

.source-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.source-item {
  display: flex;
  flex-direction: column;
  gap: 2px;
  padding-bottom: 10px;
  border-bottom: 1px solid var(--divider);
}

.source-item:last-child {
  border-bottom: none;
  padding-bottom: 0;
}

.source-publisher {
  font-size: 0.72rem;
  font-weight: 600;
  color: var(--text-dim);
}

.source-link {
  color: var(--text);
  font-size: 0.84rem;
  font-weight: 500;
  text-decoration: underline;
  text-underline-offset: 3px;
  text-decoration-color: var(--divider-strong);
  word-break: break-word;
}

.source-link:hover {
  color: var(--accent);
  text-decoration-color: var(--accent);
}

.source-text {
  color: var(--text-muted);
  font-size: 0.84rem;
}

/* ==================== REVIEWS & FORM ==================== */
.review-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.review-item {
  padding-bottom: 14px;
  border-bottom: 1px solid var(--divider);
}

.review-item:last-child {
  border-bottom: none;
  padding-bottom: 0;
}

.review-top {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  margin-bottom: 6px;
}

.review-author {
  font-weight: 700;
  font-size: 0.88rem;
  color: var(--text);
}

.review-date {
  font-size: 0.74rem;
  color: var(--text-dim);
}

.review-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-bottom: 8px;
}

.review-comment {
  margin: 0;
  font-size: 0.86rem;
  color: var(--text);
}

.review-form {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.form-row-2 {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.form-field {
  display: flex;
  flex-direction: column;
  gap: 5px;
  font-size: 0.8rem;
  font-weight: 500;
  color: var(--text-muted);
}

.form-field input[type="text"],
.form-field input[type="number"],
.form-field input[type="url"],
.form-field select,
.form-field textarea {
  width: 100%;
  padding: 10px 12px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--divider-strong);
  background: var(--bg);
  color: var(--text);
  font-size: 0.9rem;
}

.form-field input:focus,
.form-field select:focus,
.form-field textarea:focus {
  border-color: var(--text);
}

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

.menu-chip {
  padding: 5px 10px;
  border-radius: 999px;
  border: 1px solid var(--divider);
  background: var(--bg);
  color: var(--text-muted);
  font-size: 0.76rem;
  cursor: pointer;
}

.menu-chip:hover {
  border-color: var(--text);
  color: var(--text);
}

.baking-preview {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 12px 14px;
  border-radius: var(--radius-sm);
  background: var(--surface);
  border: 1px solid var(--divider);
}

.baking-media-cluster {
  display: flex;
  align-items: center;
  gap: 4px;
  flex-shrink: 0;
}

.baking-bag-thumb,
.baking-fish-img {
  object-fit: contain;
}

.baking-caption {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 3px;
}

.baking-caption strong {
  font-size: 0.84rem;
  color: var(--text);
}

.baking-caption span {
  font-size: 0.74rem;
  color: var(--text-muted);
}

.baking-fill-track {
  height: 4px;
  border-radius: 999px;
  margin-top: 4px;
  background: var(--surface-strong);
  overflow: hidden;
}

.baking-fill-bar {
  height: 100%;
  background: var(--accent);
  transition: width 0.2s ease;
}

.rating-matrix {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

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

.rating-label {
  font-size: 0.82rem;
  color: var(--text-muted);
}

.rating-buttons {
  display: flex;
  gap: 6px;
}

.rating-buttons button {
  min-width: 36px;
  min-height: 44px;
  padding: 0 10px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--divider-strong);
  background: var(--bg);
  color: var(--text-muted);
  font-size: 0.84rem;
  font-weight: 700;
  cursor: pointer;
}

.rating-buttons button.is-active {
  background: var(--btn-solid-bg);
  border-color: var(--btn-solid-bg);
  color: var(--btn-solid-text);
}

.check-stack {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.check-inline {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 0.84rem;
  color: var(--text-muted);
  cursor: pointer;
}

.check-inline input[type="checkbox"] {
  accent-color: var(--text);
  width: 16px;
  height: 16px;
}

.form-error {
  margin: 0;
  color: var(--danger);
  font-size: 0.84rem;
}

.seal-stamp-wrap {
  display: flex;
  align-items: center;
  gap: 12px;
  margin: 10px 0;
  padding: 10px 12px;
  border-radius: var(--radius-sm);
  background: var(--surface);
}

.seal-stamp {
  padding: 3px 9px;
  border-radius: 6px;
  border: 1px solid var(--divider-strong);
  color: var(--text);
  font-size: 0.74rem;
  font-weight: 700;
}

.seal-desc {
  font-size: 0.78rem;
  color: var(--text-muted);
}

/* ==================== METHODOLOGY VIEW ==================== */
.method-hero-banner {
  position: relative;
  min-height: 280px;
  border-radius: var(--radius-lg);
  overflow: hidden;
  display: flex;
  align-items: flex-end;
  margin-bottom: 36px;
  border: 1px solid var(--divider);
}

.method-hero-img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: brightness(0.60);
}

html[data-theme="hanji-guide"] .method-hero-img {
  filter: brightness(0.92);
}

.method-hero-scrim {
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(13, 13, 12, 0.15) 0%, rgba(13, 13, 12, 0.90) 100%);
}

html[data-theme="hanji-guide"] .method-hero-scrim {
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.10) 0%, rgba(255, 255, 255, 0.78) 58%, rgba(255, 255, 255, 0.98) 100%);
}

.method-header {
  position: relative;
  z-index: 2;
  padding: 36px 36px 28px;
  max-width: 760px;
}

.method-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(340px, 0.85fr);
  gap: 40px;
  align-items: start;
}

.method-block {
  margin-bottom: 28px;
  padding-bottom: 24px;
  border-bottom: 1px solid var(--divider);
}

.method-block:last-child {
  border-bottom: none;
}

.method-block h2 {
  margin: 0 0 8px;
  font-size: 1.14rem;
  font-weight: 700;
  letter-spacing: -0.02em;
  color: var(--text);
}

.method-block p {
  margin: 0 0 10px;
  color: var(--text-muted);
  font-size: 0.92rem;
  line-height: 1.68;
}

.formula-box {
  background: var(--surface);
  border: 1px solid var(--divider);
  border-radius: var(--radius-sm);
  padding: 14px 16px;
  margin: 12px 0 16px;
  font-size: 0.9rem;
  font-weight: 700;
  color: var(--text);
  overflow-x: auto;
}

.method-list {
  margin: 0;
  padding-left: 18px;
  color: var(--text-muted);
  font-size: 0.9rem;
  line-height: 1.68;
}

.method-list li {
  margin-bottom: 9px;
}

.method-list strong {
  color: var(--text);
}

.method-list code {
  padding: 2px 6px;
  background: var(--surface);
  color: var(--text);
  font-size: 0.85em;
  border-radius: 4px;
}

.simulator-panel {
  position: sticky;
  top: 106px;
  background: var(--bg);
  border: 1px solid var(--divider);
  border-radius: var(--radius-lg);
  padding: 24px;
  box-shadow: var(--shadow-sm);
}

.sim-head h2 {
  margin: 0 0 6px;
  font-size: 1.14rem;
  font-weight: 700;
  letter-spacing: -0.02em;
}

.sim-head p {
  margin: 0 0 16px;
  font-size: 0.84rem;
  color: var(--text-muted);
}

.sim-presets {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-bottom: 18px;
}

.sim-presets .pill {
  font-size: 0.76rem;
  padding: 5px 10px;
}

.sim-result {
  background: var(--surface);
  border-radius: var(--radius-md);
  padding: 16px;
  margin-bottom: 18px;
}

.sim-total {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  margin-bottom: 12px;
}

.sim-total-label {
  font-size: 0.82rem;
  color: var(--text-muted);
}

.sim-total-value {
  font-size: 2.1rem;
  font-weight: 800;
  letter-spacing: -0.03em;
  color: var(--text);
  font-variant-numeric: tabular-nums;
}

.sim-meta {
  margin: 10px 0 0;
  font-size: 0.76rem;
  color: var(--text-muted);
  line-height: 1.5;
}

.sim-controls {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.sim-field {
  display: flex;
  flex-direction: column;
  gap: 5px;
}

.sim-field span {
  display: flex;
  justify-content: space-between;
  font-size: 0.8rem;
  color: var(--text-muted);
}

.sim-field strong {
  color: var(--text);
  font-variant-numeric: tabular-nums;
}

.sim-field input[type="range"] {
  accent-color: var(--text);
  cursor: pointer;
}

.sim-selects {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}

/* ==================== FOOTER ==================== */
.site-footer {
  position: relative;
  overflow: hidden;
  border-top: 1px solid var(--divider);
  background: var(--bg-elevated);
}

.footer-backdrop-wrap {
  position: absolute;
  inset: 0;
  pointer-events: none;
}

.footer-backdrop-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: right center;
  opacity: 0.22;
}

html[data-theme="hanji-guide"] .footer-backdrop-img {
  opacity: 0.65;
}

.footer-backdrop-scrim {
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, var(--bg-elevated) 0%, var(--bg-elevated) 40%, transparent 100%);
}

.footer-inner {
  position: relative;
  z-index: 2;
  max-width: 1360px;
  margin: 0 auto;
  padding: 32px 28px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}

.footer-brand {
  display: flex;
  align-items: center;
  gap: 14px;
}

.footer-crest {
  width: 40px;
  height: 40px;
  aspect-ratio: 1 / 1;
  border-radius: 50%;
  object-fit: contain;
  border: 1px solid var(--divider);
}

.footer-title {
  display: block;
  font-size: 1rem;
  font-weight: 700;
  color: var(--text);
}

.footer-sub {
  margin: 2px 0 0;
  font-size: 0.8rem;
  color: var(--text-muted);
}

.footer-seals {
  display: flex;
  align-items: center;
  gap: 10px;
}

.footer-seals img {
  width: 34px;
  height: 34px;
  aspect-ratio: 1 / 1;
  border-radius: 50%;
  object-fit: contain;
  border: 1px solid var(--divider);
  background: var(--bg);
}

/* ==================== DIALOG MODAL ==================== */
.store-dialog {
  width: min(600px, calc(100vw - 24px));
  max-height: calc(92dvh - var(--ad-top, 0px) - 16px);
  margin: calc(var(--ad-top, 0px) + 12px) auto auto;
  padding: 0;
  border: 1px solid var(--divider-strong);
  border-radius: var(--radius-lg);
  background: var(--bg);
  color: var(--text);
  overflow: auto;
  box-shadow: var(--shadow-md);
}

.store-dialog::backdrop {
  background: rgba(0, 0, 0, 0.56);
  backdrop-filter: blur(4px);
}

.dialog-form {
  padding: 24px 26px calc(24px + env(safe-area-inset-bottom, 0px));
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.dialog-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.dialog-head h2 {
  margin: 0;
  font-size: 1.24rem;
  font-weight: 800;
  letter-spacing: -0.02em;
}

.dialog-sub {
  margin: 0;
  font-size: 0.84rem;
  color: var(--text-muted);
}

.form-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.form-span-2 {
  grid-column: span 2;
}

.checkbox-group {
  border: 1px solid var(--divider);
  border-radius: var(--radius-sm);
  padding: 10px 12px;
  display: flex;
  flex-direction: row;
  flex-wrap: wrap;
  gap: 14px;
}

.checkbox-group legend {
  padding: 0 6px;
  font-size: 0.78rem;
  color: var(--text-muted);
}

.dialog-actions {
  display: flex;
  justify-content: flex-end;
  gap: 8px;
  padding-top: 8px;
}

.location-picker-block {
  gap: 8px;
}

.location-picker-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 8px;
}

.location-picker-actions {
  display: flex;
  align-items: center;
  gap: 6px;
}

.btn-picker,
.btn-picker-clear {
  padding: 5px 11px;
  border-radius: 999px;
  border: 1px solid var(--divider-strong);
  background: var(--bg);
  color: var(--text);
  font-size: 0.76rem;
  font-weight: 600;
  cursor: pointer;
}

.btn-picker:hover,
.btn-picker-clear:hover {
  background: var(--surface);
  border-color: var(--text);
}

.btn-picker-clear {
  color: var(--text-muted);
}

.location-picker-status {
  margin: 0;
  font-size: 0.76rem;
  color: var(--text-dim);
  line-height: 1.45;
}

.location-picker-status.is-pinned {
  color: var(--verified);
  font-weight: 600;
}

.store-picker-map {
  height: 196px;
  width: 100%;
  border-radius: var(--radius-sm);
  border: 1px solid var(--divider-strong);
  background: var(--surface);
  overflow: hidden;
}

.photo-upload-block {
  gap: 8px;
}

.photo-upload-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 8px;
}

.photo-upload-hint {
  margin: 0;
  font-size: 0.76rem;
  color: var(--text-dim);
}

.photo-preview-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
}

.photo-preview-item {
  position: relative;
  aspect-ratio: 4 / 3;
  border-radius: var(--radius-sm);
  overflow: hidden;
  border: 1px solid var(--divider);
  background: var(--surface);
}

.photo-preview-item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.photo-remove-btn {
  position: absolute;
  top: 6px;
  right: 6px;
  padding: 2px 7px;
  border-radius: 999px;
  border: none;
  background: rgba(17, 17, 17, 0.78);
  color: #FFFFFF;
  font-size: 0.68rem;
  font-weight: 600;
  cursor: pointer;
}

/* ==================== BAKING GAUGE & FX ==================== */
.baking-gauge {
  position: fixed;
  right: 20px;
  bottom: calc(20px + env(safe-area-inset-bottom, 0px));
  z-index: 900;
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 7px 13px;
  border-radius: 999px;
  border: 1px solid var(--divider-strong);
  background: var(--bg);
  color: var(--text);
  font-size: 0.76rem;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
  cursor: pointer;
  box-shadow: var(--shadow-md);
}

.gauge-fish-img {
  object-fit: contain;
}

.crumb-burst-layer {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 2500;
}

.crumb-particle {
  position: fixed;
  border-radius: 40% 60% 50% 50%;
  animation: crumbPop 0.65s cubic-bezier(0.2, 0.8, 0.2, 1) forwards;
}

@keyframes crumbPop {
  0% {
    opacity: 1;
    transform: translate(-50%, -50%) scale(1) rotate(0deg);
  }
  100% {
    opacity: 0;
    transform: translate(calc(-50% + var(--dx)), calc(-50% + var(--dy))) scale(0.35) rotate(var(--rot));
  }
}

/* ==================== RESPONSIVE & MOBILE BOTTOM SHEET ==================== */
@media (max-width: 1080px) {
  .editorial-intro.hero-overlay {
    grid-template-columns: 1fr;
    gap: 20px;
    padding: 36px 24px 26px;
  }

  .hero-side {
    border-left: none;
    border-top: 1px solid rgba(255, 255, 255, 0.14);
    padding-left: 0;
    padding-top: 14px;
  }

  .intro-stats {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 14px;
  }

  .stat-item {
    flex-direction: column;
    gap: 2px;
    border-bottom: none;
    padding-bottom: 0;
  }

  html[data-theme="hanji-guide"] .hero-stall-banner {
    display: flex;
    flex-direction: column;
    min-height: auto;
  }

  html[data-theme="hanji-guide"] .hero-video {
    position: relative;
    inset: auto;
    width: 100%;
    height: 210px;
    border-radius: 0;
  }

  html[data-theme="hanji-guide"] .hero-sound-orb {
    top: 14px;
    right: 14px;
  }

  html[data-theme="hanji-guide"] .editorial-intro.hero-overlay {
    width: 100%;
    padding: 22px 20px 24px;
  }

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

  .board-layout,
  .method-grid {
    grid-template-columns: 1fr;
    gap: 24px;
  }

  .simulator-panel {
    position: static;
  }

  .detail-backdrop {
    display: block;
    position: fixed;
    inset: 0;
    z-index: 1400;
    background: rgba(0, 0, 0, 0.48);
    backdrop-filter: blur(3px);
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.2s ease;
  }

  .detail-backdrop.is-open {
    opacity: 1;
    pointer-events: auto;
  }

  .detail-panel {
    position: fixed;
    left: 0;
    right: 0;
    bottom: 0;
    top: auto;
    z-index: 1500;
    height: 92dvh;
    max-height: 92dvh;
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
    transform: translateY(104%);
    transition: transform 0.28s cubic-bezier(0.22, 1, 0.36, 1);
    pointer-events: none;
  }

  .detail-panel.is-open {
    transform: translateY(0);
    pointer-events: auto;
  }

  .sheet-peek-spacer {
    display: block;
    height: 32dvh;
    pointer-events: none;
  }

  .sheet-surface {
    min-height: 60dvh;
    border-radius: 18px 18px 0 0;
    border: none;
    border-top: 1px solid var(--divider-strong);
    padding: 0 20px calc(28px + env(safe-area-inset-bottom, 0px));
    box-shadow: 0 -12px 32px rgba(0, 0, 0, 0.25);
  }

  .detail-mobile-bar {
    display: block;
    position: sticky;
    top: 0;
    z-index: 10;
    background: var(--bg);
    padding: 10px 0 12px;
    border-bottom: 1px solid var(--divider);
    margin-bottom: 16px;
  }

  .sheet-grabber {
    display: block;
    width: 36px;
    height: 4px;
    border-radius: 999px;
    background: var(--divider-strong);
    margin: 0 auto 10px;
  }

  .detail-mobile-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
  }

  .detail-mobile-label {
    font-size: 0.82rem;
    font-weight: 700;
    color: var(--text);
  }

  .detail-mobile-actions {
    display: flex;
    align-items: center;
    gap: 8px;
  }
}

@media (max-width: 720px) {
  .masthead-inner {
    padding: 12px 16px 0;
  }

  .brand-sub {
    display: none;
  }

  .primary-nav {
    gap: 18px;
  }

  .container {
    padding: 16px 16px 72px;
  }

  .craft-reel-grid {
    display: flex;
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    gap: 10px;
    padding-bottom: 4px;
    scrollbar-width: none;
  }

  .craft-reel-grid::-webkit-scrollbar {
    display: none;
  }

  .reel-card {
    flex: 0 0 74%;
    scroll-snap-align: start;
    height: 128px;
  }

  .reel-section-head {
    flex-direction: column;
    gap: 2px;
  }

  .map-header {
    flex-direction: column;
    align-items: flex-start;
  }

  .holy-grail-map {
    height: 290px;
  }

  .nearby-chips,
  .poll-rec-list,
  .poll-bars-area,
  .form-row-2,
  .form-grid,
  .sim-selects {
    grid-template-columns: 1fr;
  }

  .form-span-2 {
    grid-column: span 1;
  }

  .filter-controls {
    width: 100%;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 8px;
  }

  .sido-control,
  .search-wrap {
    grid-column: span 2;
  }

  .select-minimal,
  .search-input,
  .form-field input,
  .form-field select,
  .form-field textarea {
    width: 100%;
    font-size: 1rem;
    min-height: 44px;
  }

  .rank-row {
    grid-template-columns: 28px minmax(0, 1fr) 56px;
    gap: 10px;
    padding: 14px 8px;
  }

  .method-header {
    padding: 24px 18px 20px;
  }

  .footer-inner {
    flex-direction: column;
    align-items: flex-start;
    padding: 24px 16px;
  }

  .baking-gauge {
    right: 14px;
    bottom: calc(14px + env(safe-area-inset-bottom, 0px));
  }

  .theme-opt {
    width: 30px;
    height: 30px;
  }

  .btn-iron {
    padding: 7px 12px;
    font-size: 0.78rem;
  }
}
