* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
  -webkit-tap-highlight-color: transparent;
}

html,
body {
  min-height: 100%;
}

body {
  font-family: Inter, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  background: #111;
  color: var(--text);
  overflow-x: hidden;
}

button,
input {
  font: inherit;
}

button {
  cursor: pointer;
}

a {
  color: inherit;
}

button:focus-visible,
a:focus-visible,
input:focus-visible,
[role="button"]:focus-visible {
  outline: 3px solid rgba(230, 126, 34, 0.45);
  outline-offset: 3px;
}

.skip-link {
  position: fixed;
  top: -80px;
  left: 14px;
  z-index: 1000;
  padding: 10px 14px;
  border-radius: 10px;
  background: #111;
  color: #fff;
}

.skip-link:focus {
  top: 14px;
}

.bagiq-app.light,
.light {
  --bg: #FDF9F4;
  --surface: #FFFFFF;
  --surface2: #F0E8DF;
  --border: #E8DED2;
  --text: #111111;
  --text2: #666666;
  --text3: #AAAAAA;
  --primary: #7C0236;
  --pl: rgba(124, 2, 54, 0.1);
  --speed: #E67E22;
  --glide: #3498DB;
  --turn: #9B59B6;
  --fade: #27AE60;
  --success: #27AE60;
  --warn: #E67E22;
  --danger: #D32F2F;
  --sh: 0 2px 12px rgba(0, 0, 0, 0.06);
}

.bagiq-app.dark,
.dark {
  --bg: #121212;
  --surface: #1E1E1E;
  --surface2: #2A2A2A;
  --border: #333333;
  --text: #F5EDE4;
  --text2: #A0A0A0;
  --text3: #555555;
  --primary: #F9447D;
  --pl: rgba(249, 68, 125, 0.12);
  --speed: #F0933A;
  --glide: #5AADE0;
  --turn: #B47ED4;
  --fade: #3FCC7A;
  --success: #3FCC7A;
  --warn: #F0933A;
  --danger: #EF5350;
  --sh: 0 2px 12px rgba(0, 0, 0, 0.3);
}

.bagiq-app {
  min-height: 100vh;
  background: var(--bg);
  color: var(--text);
}

.app-frame {
  min-height: 100vh;
  display: grid;
  grid-template-rows: 64px 1fr;
  grid-template-columns: 240px 1fr;
  grid-template-areas:
    "topbar topbar"
    "sidebar main";
  background: var(--bg);
}

.topbar {
  grid-area: topbar;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 32px;
  border-bottom: 1px solid var(--border);
  background: var(--bg);
  position: sticky;
  top: 0;
  z-index: 20;
}

.logo {
  border: 0;
  background: transparent;
  display: inline-flex;
  align-items: center;
  padding: 0;
  line-height: 0;
}

.logo img {
  display: block;
  width: clamp(138px, 14vw, 174px);
  height: auto;
}

.header-right {
  display: flex;
  gap: 10px;
  align-items: center;
}

.identity-stat {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 7px 14px;
  border: 1px solid var(--border);
  border-radius: 50px;
  background: var(--surface2);
  color: var(--text2);
  font-size: 12px;
  font-weight: 600;
}

.identity-stat strong {
  color: var(--text);
  font-weight: 800;
}

.icon-btn {
  width: 38px;
  height: 38px;
  border-radius: 50%;
  border: 1px solid var(--border);
  background: var(--surface);
  color: var(--text2);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  transition: all 0.2s;
}

.icon-btn:hover {
  border-color: var(--primary);
  color: var(--primary);
}

svg {
  width: 20px;
  height: 20px;
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.sidebar {
  grid-area: sidebar;
  display: flex;
  flex-direction: column;
  gap: 6px;
  height: calc(100vh - 64px);
  padding: 18px 14px;
  border-right: 1px solid var(--border);
  background: var(--bg);
  position: sticky;
  top: 64px;
  overflow-y: auto;
  scrollbar-width: none;
}

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

.sidebar-spacer {
  flex: 1;
}

.sidebar-cta {
  margin-top: 8px;
  padding-top: 14px;
  border-top: 1px solid var(--border);
}

.main {
  grid-area: main;
  width: 100%;
  min-width: 0;
  padding: 32px 40px 80px;
}

.bottom-nav {
  display: none;
}

.nav-item {
  display: flex;
  align-items: center;
  gap: 12px;
  width: 100%;
  padding: 10px 12px;
  border: 0;
  border-radius: 10px;
  background: transparent;
  color: var(--text2);
  position: relative;
  transition: all 0.15s;
}

.nav-item:hover {
  background: var(--surface2);
  color: var(--text);
}

.nav-item.active {
  background: var(--pl);
  color: var(--primary);
}

.nav-icon {
  width: 22px;
  height: 22px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  position: relative;
}

.nav-icon i {
  position: absolute;
  top: -6px;
  right: -8px;
  min-width: 15px;
  height: 15px;
  padding: 0 3px;
  border-radius: 50px;
  background: var(--primary);
  color: #fff;
  font-style: normal;
  font-size: 9px;
  font-weight: 800;
  display: flex;
  align-items: center;
  justify-content: center;
}

.nav-label {
  color: inherit;
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 0;
}

.nav-item.active .nav-label {
  font-weight: 700;
}

.nav-badge {
  margin-left: auto;
  min-width: 20px;
  height: 18px;
  padding: 0 6px;
  border-radius: 50px;
  background: var(--primary);
  color: #fff;
  font-size: 10px;
  font-weight: 800;
  display: flex;
  align-items: center;
  justify-content: center;
}

.screen {
  animation: fadeUp 0.22s ease;
}

@keyframes fadeUp {
  from {
    opacity: 0;
    transform: translateY(10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 16px;
  box-shadow: var(--sh);
}

.pill {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  min-height: 44px;
  padding: 0 18px;
  border-radius: 50px;
  border: 0;
  font-family: Inter, sans-serif;
  font-weight: 700;
  font-size: 14px;
  text-decoration: none;
  white-space: nowrap;
  transition: all 0.2s;
}

.pill svg {
  width: 16px;
  height: 16px;
}

.pill-p {
  background: var(--primary);
  color: #fff;
}

.pill-p:hover {
  transform: translateY(-1px);
  box-shadow: 0 6px 16px rgba(124, 2, 54, 0.3);
}

.pill-o {
  background: transparent;
  border: 1.5px solid var(--border);
  color: var(--text);
}

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

.pill-g {
  background: var(--pl);
  color: var(--primary);
}

.pill-sm {
  min-height: 34px;
  padding: 0 12px;
  font-size: 12px;
}

.pill-full {
  width: 100%;
}

.pill-danger {
  background: rgba(211, 47, 47, 0.1);
  border: 1.5px solid var(--danger);
  color: var(--danger);
}

.pill-success {
  background: rgba(39, 174, 96, 0.1);
  border: 1.5px solid var(--success);
  color: var(--success);
}

.pill-group {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
}

.tag {
  display: inline-flex;
  align-items: center;
  padding: 3px 9px;
  border-radius: 50px;
  background: var(--surface2);
  color: var(--text2);
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.tag-plain {
  text-transform: none;
  letter-spacing: 0;
}

.tag-p {
  background: var(--pl);
  color: var(--primary);
}

.tag-s {
  background: rgba(39, 174, 96, 0.12);
  color: var(--success);
}

.tag-w {
  background: rgba(230, 126, 34, 0.12);
  color: var(--warn);
}

.page-head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 24px;
  flex-wrap: wrap;
  margin-bottom: 24px;
}

.page-head.tight {
  margin-bottom: 16px;
}

.section-h {
  font-family: Manrope, Inter, sans-serif;
  font-weight: 800;
  font-size: 30px;
  color: var(--text);
  letter-spacing: 0;
  line-height: 1.1;
}

.section-sub {
  margin-top: 6px;
  color: var(--text2);
  font-size: 14px;
}

.kpi-row {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 12px;
  margin-bottom: 24px;
}

.bag-switcher {
  display: grid;
  gap: 8px;
  margin-bottom: 16px;
}

.bag-strip {
  display: flex;
  gap: 10px;
  overflow-x: auto;
  padding-bottom: 3px;
}

.bag-card {
  flex: 0 0 132px;
  display: grid;
  gap: 4px;
  min-height: 64px;
  padding: 9px 10px;
  border: 2px solid var(--border);
  border-radius: 14px;
  background: var(--surface);
  color: var(--text);
  text-align: left;
}

.bag-card.active {
  border-color: var(--primary);
  background: var(--pl);
}

.bag-card.new {
  border-style: dashed;
}

.bag-card span {
  color: var(--primary);
  font-size: 10px;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

.bag-card strong {
  font-size: 13px;
  font-weight: 900;
}

.bag-card small {
  color: var(--text2);
  font-size: 10px;
  line-height: 1.35;
}

.bag-actions {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

.kpi-card {
  padding: 16px 18px;
  border: 1px solid var(--border);
  border-radius: 14px;
  background: var(--surface);
}

.kpi-label {
  margin-bottom: 6px;
  color: var(--text3);
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

.kpi-value {
  font-family: Manrope, Inter, sans-serif;
  font-weight: 800;
  font-size: 26px;
  color: var(--text);
  line-height: 1;
}

.kpi-value.p {
  color: var(--primary);
}

.kpi-sub {
  margin-top: 4px;
  color: var(--text2);
  font-size: 11px;
}

.map-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 380px;
  gap: 24px;
  margin-bottom: 32px;
}

.identity-banner {
  display: grid;
  gap: 14px;
  margin-bottom: 14px;
  padding: 16px;
  border-radius: 16px;
  background: linear-gradient(135deg, var(--primary) 0%, rgba(124, 2, 54, 0.65) 100%);
  color: #fff;
  position: relative;
  overflow: hidden;
}

.identity-banner::after {
  content: "";
  position: absolute;
  right: -20px;
  top: -20px;
  width: 100px;
  height: 100px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.06);
}

.identity-copy,
.coverage-meter {
  position: relative;
  z-index: 1;
}

.identity-copy strong {
  display: block;
  margin-bottom: 2px;
  font-weight: 800;
  font-size: 17px;
}

.identity-copy span {
  color: rgba(255, 255, 255, 0.86);
  font-size: 12px;
}

.coverage-meter {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 5px;
  color: rgba(255, 255, 255, 0.86);
  font-size: 11px;
  font-weight: 600;
}

.coverage-bar {
  grid-column: 1 / -1;
  height: 8px;
  border-radius: 4px;
  background: rgba(255, 255, 255, 0.2);
  overflow: hidden;
}

.coverage-fill {
  height: 100%;
  border-radius: 4px;
  background: rgba(255, 255, 255, 0.9);
  transition: width 0.8s ease;
}

.map-card {
  padding: 12px 10px 8px;
  margin-bottom: 14px;
}

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

.map-card-head strong {
  font-size: 13px;
  font-weight: 800;
}

.category-legend,
.filter-bar,
.sort-row {
  display: flex;
  gap: 6px;
  overflow-x: auto;
  scrollbar-width: none;
}

.category-legend::-webkit-scrollbar,
.filter-bar::-webkit-scrollbar,
.sort-row::-webkit-scrollbar {
  display: none;
}

.legend-chip,
.filter-chip {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  flex-shrink: 0;
  padding: 5px 12px;
  border-radius: 50px;
  border: 1.5px solid var(--border);
  background: var(--surface);
  color: var(--text2);
  font-size: 11px;
  font-weight: 700;
  white-space: nowrap;
}

.legend-chip span {
  width: 7px;
  height: 7px;
  border-radius: 50%;
}

.legend-chip.active,
.filter-chip.active {
  background: var(--primary);
  border-color: var(--primary);
  color: #fff;
}

.bag-svg {
  display: block;
  width: 100%;
  height: auto;
  color: var(--text);
  stroke: none;
}

.bag-svg text {
  stroke: none !important;
  paint-order: normal;
  vector-effect: non-scaling-stroke;
}

.bag-svg line,
.bag-svg circle {
  vector-effect: non-scaling-stroke;
}

.gap-zone,
.disc-dot {
  cursor: pointer;
}

.gap-zone circle:first-child {
  opacity: 0.045;
  animation: gapBreathe 2.8s ease-in-out infinite;
  transform-box: fill-box;
  transform-origin: center;
}

.gap-zone circle:nth-child(2) {
  opacity: 0.42;
  animation: pulseStroke 2.4s ease-in-out infinite;
  transform-box: fill-box;
  transform-origin: center;
}

.disc-dot {
  transition: filter 0.16s ease, opacity 0.16s ease;
}

.disc-dot:hover {
  filter: drop-shadow(0 4px 8px rgba(0, 0, 0, 0.24));
}

@keyframes gapBreathe {
  0%,
  100% {
    transform: scale(0.96);
  }
  50% {
    transform: scale(1.08);
  }
}

.disc-dot text {
  fill: #fff;
  font-family: Inter, sans-serif;
  font-size: 7px;
  font-weight: 800;
  pointer-events: none;
}

@keyframes pulseStroke {
  0%,
  100% {
    stroke-opacity: 0.45;
  }
  50% {
    stroke-opacity: 1;
  }
}

.map-hint {
  margin-top: 2px;
  color: var(--text3);
  font-size: 10px;
  text-align: center;
}

.compact-list {
  max-height: 360px;
  overflow: auto;
  padding: 4px 2px 8px;
}

.compact-list h3 {
  margin: 10px 0 4px;
  font-size: 9px;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.disc-row,
.autocomplete-item,
.insight-card {
  width: 100%;
  border: 0;
  background: transparent;
  text-align: left;
}

.disc-row {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 0;
  border-bottom: 1px solid var(--border);
  color: var(--text);
}

.disc-row span:nth-child(2) {
  flex: 1;
  min-width: 0;
}

.disc-row strong,
.autocomplete-item strong {
  display: block;
  color: var(--text);
  font-size: 13px;
  font-weight: 700;
}

.disc-row small,
.autocomplete-item small {
  display: block;
  margin-top: 1px;
  color: var(--text2);
  font-size: 11px;
}

.disc-avatar {
  width: 38px;
  height: 38px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  font-size: 10px;
  font-weight: 800;
  flex-shrink: 0;
  position: relative;
}

.disc-avatar.large {
  width: 56px;
  height: 56px;
  font-size: 14px;
}

.flight-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 6px;
}

.flight-grid.compact {
  width: 92px;
  grid-template-columns: repeat(4, 20px);
  gap: 3px;
  flex-shrink: 0;
}

.flight-box {
  display: block;
  padding: 8px 4px;
  border-radius: 8px;
  color: #fff;
  text-align: center;
  font-size: 16px;
  font-weight: 800;
  box-shadow: inset 0 -2px 0 rgba(0, 0, 0, 0.15);
}

.flight-grid.compact .flight-box {
  padding: 3px 0;
  border-radius: 4px;
  font-size: 8px;
}

.flight-box small {
  display: block;
  margin-bottom: 2px;
  opacity: 0.85;
  font-size: 9px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.flight-grid.compact .flight-box small {
  display: none;
}

.f-sp {
  background: var(--speed);
}

.f-gl {
  background: var(--glide);
}

.f-tu {
  background: var(--turn);
}

.f-fa {
  background: var(--fade);
}

.insight-stack {
  display: grid;
  gap: 8px;
}

.insight-card {
  display: grid;
  gap: 4px;
  padding: 11px 14px;
  border: 1px solid var(--border);
  border-radius: 14px;
  background: var(--surface);
  box-shadow: var(--sh);
}

.insight-card.warn {
  border-color: rgba(230, 126, 34, 0.6);
  background: rgba(230, 126, 34, 0.08);
}

.insight-card strong {
  color: var(--text);
  font-size: 14px;
}

.insight-card small {
  color: var(--text2);
  font-size: 12px;
}

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

.recommend-sticky {
  position: sticky;
  top: 88px;
  display: grid;
  gap: 10px;
}

.impact-btn {
  box-shadow: 0 10px 24px rgba(124, 2, 54, 0.22);
}

.gap-fix-panel {
  max-width: 440px;
  margin-left: auto;
  margin-right: auto;
}

.gap-impact-head {
  display: grid;
  gap: 6px;
  margin-bottom: 12px;
}

.gap-impact-head h2 {
  margin: 0;
  color: var(--text);
  font-family: Manrope, Inter, sans-serif;
  font-size: 28px;
  line-height: 1.05;
}

.gap-impact-head p {
  margin: 0;
  color: var(--text2);
  font-size: 13px;
  line-height: 1.5;
}

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

.swipe-nav > div {
  display: grid;
  justify-items: center;
  gap: 6px;
  color: var(--text);
  font-size: 13px;
  font-weight: 900;
}

.swipe-nav-btn {
  width: 38px;
  height: 38px;
  border: 1.5px solid var(--border);
  border-radius: 50%;
  background: var(--surface);
  color: var(--text2);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  font-size: 18px;
  font-weight: 900;
  transition: transform 0.12s ease, border-color 0.12s ease, color 0.12s ease;
}

.swipe-nav-btn:hover {
  border-color: var(--primary);
  color: var(--primary);
  transform: scale(1.06);
}

.swipe-nav-btn:disabled {
  opacity: 0.25;
  cursor: default;
  transform: none;
}

.swipe-dots {
  display: flex;
  gap: 5px;
}

.swipe-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--border);
  transition: width 0.18s ease, background 0.18s ease;
}

.swipe-dot.active {
  width: 18px;
  border-radius: 999px;
  background: var(--primary);
}

.ghost-landing {
  display: grid;
  gap: 2px;
  margin-bottom: 10px;
  padding: 10px 12px;
  border: 1.5px solid var(--primary);
  border-radius: 14px;
  background: var(--pl);
}

.ghost-landing strong {
  color: var(--primary);
  font-size: 13px;
}

.ghost-landing span {
  color: var(--text2);
  font-size: 12px;
}

.gap-actions {
  display: grid;
  gap: 8px;
  margin-top: 10px;
}

.retailer-expanded {
  margin-top: 10px;
  padding: 4px 10px 0;
  border: 1px solid var(--border);
  border-radius: 14px;
  background: var(--surface2);
  animation: snapIn 0.16s ease;
}

.gwd-modal-backdrop {
  position: fixed;
  inset: 0;
  z-index: 9998;
  display: none;
  background: rgba(0, 0, 0, 0.7);
  opacity: 0;
  backdrop-filter: blur(5px);
  transition: opacity 0.22s ease;
}

.gwd-modal-backdrop.is-active {
  display: block;
  opacity: 1;
}

.gwd-retailer-drawer {
  position: fixed;
  top: 50%;
  left: 50%;
  z-index: 9999;
  width: min(92vw, 560px);
  max-height: 85vh;
  display: flex;
  flex-direction: column;
  border: 1px solid var(--border);
  border-radius: 12px;
  background: var(--surface);
  box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.6);
  transform: translate(-50%, -50%);
}

.gwd-drawer-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 16px 18px 10px;
  border-bottom: 1px solid var(--border);
  background: var(--surface2);
}

.gwd-modal-title-text {
  color: var(--text);
  font-size: 15px;
  font-weight: 900;
}

.gwd-drawer-label {
  display: grid;
  gap: 2px;
  color: var(--primary);
  font-size: 10px;
  font-weight: 900;
  text-align: right;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.gwd-last-updated {
  color: var(--text3);
  font-size: 10px;
  font-weight: 700;
  text-transform: none;
  letter-spacing: 0;
}

.gwd-modal-close-btn {
  width: 32px;
  height: 32px;
  border: 1px solid var(--border);
  border-radius: 50%;
  background: var(--surface);
  color: var(--text);
  font-size: 20px;
  font-weight: 900;
  cursor: pointer;
}

.bagiq-df-summary {
  display: grid;
  gap: 10px;
  padding: 14px 18px;
  border-bottom: 1px solid var(--border);
}

.gwd-retailer-list {
  flex: 1 1 auto;
  min-height: 0;
  overflow-y: auto;
}

.gwd-drawer-fallbacks {
  padding: 14px 18px 18px;
  border-top: 1px solid var(--border);
  background: var(--surface2);
}

.gwd-price-stock-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 10px;
}

.gwd-pc-price {
  display: flex;
  align-items: baseline;
  gap: 7px;
  color: var(--text);
  font-weight: 900;
}

.gwd-price-from {
  color: var(--text3);
  font-size: 12px;
}

.gwd-footer-price-val {
  font-size: 20px;
}

.gwd-stock-badge {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  color: var(--success);
  font-size: 11px;
  font-weight: 900;
}

.gwd-stock-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--success);
}

.price-actions {
  margin-top: 10px;
}

@keyframes snapIn {
  from {
    opacity: 0;
    transform: translateY(8px) scale(0.98);
  }
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

.panel-title {
  padding: 2px 2px 4px;
}

.panel-title h2 {
  margin: 8px 0 4px;
  color: var(--text);
  font-size: 22px;
  line-height: 1.1;
}

.panel-title p {
  color: var(--text2);
  font-size: 13px;
  line-height: 1.55;
}

.gwd-disc-card {
  margin-bottom: 10px;
  border: 1px solid var(--border);
  border-radius: 20px;
  background: var(--surface);
  overflow: hidden;
  transition: border-color 0.2s;
}

.gwd-disc-card.primary-rec {
  border-color: rgba(124, 2, 54, 0.35);
}

.gwd-disc-card-hero {
  position: relative;
  padding: 20px 16px 14px;
  text-align: center;
}

.gwd-disc-card-avatar {
  width: 80px;
  height: 80px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.2);
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 8px;
  color: #fff;
  font-family: Manrope, Inter, sans-serif;
  font-weight: 900;
  font-size: 22px;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.2);
}

.gwd-stab-badge,
.gwd-dl-badge {
  position: absolute;
  top: 12px;
  padding: 3px 8px;
  border-radius: 6px;
  background: rgba(0, 0, 0, 0.25);
  color: #fff;
  backdrop-filter: blur(4px);
  font-size: 10px;
  font-weight: 800;
}

.gwd-stab-badge {
  left: 12px;
}

.gwd-dl-badge {
  right: 12px;
}

.hero-brand {
  margin-bottom: 2px;
  color: rgba(255, 255, 255, 0.75);
  font-size: 11px;
  font-weight: 600;
}

.gwd-disc-card-hero h3 {
  color: #fff;
  font-size: 20px;
  font-weight: 800;
}

.gwd-disc-card-hero small {
  display: block;
  margin-top: 3px;
  color: rgba(255, 255, 255, 0.65);
  font-size: 11px;
}

.gwd-disc-card-body {
  display: grid;
  gap: 10px;
  padding: 14px;
}

.gwd-disc-card-body p {
  color: var(--text2);
  font-size: 12px;
  line-height: 1.6;
}

.rank-row {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 10px;
  border: 1px solid var(--border);
  border-radius: 12px;
  background: var(--surface2);
}

.rank-row span:last-child {
  flex: 1;
  color: var(--text2);
  font-size: 11px;
}

.dl-rank {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 3px 8px;
  border: 1px solid rgba(124, 2, 54, 0.15);
  border-radius: 6px;
  background: #F8F2EA;
  color: #5A0127;
  font-size: 10px;
  font-weight: 800;
}

.dark .dl-rank {
  border-color: rgba(249, 68, 125, 0.2);
  background: #1E1E1E;
  color: #F9447D;
}

.rank-up {
  margin-left: 3px;
  color: var(--success);
  font-weight: 900;
}

.rank-down {
  margin-left: 3px;
  color: var(--danger);
  font-weight: 900;
}

.rank-flat {
  margin-left: 3px;
  color: var(--text3);
  font-weight: 900;
}

.price-line {
  color: var(--text);
  font-size: 18px;
  font-weight: 800;
}

.retailer-list {
  border-top: 1px solid var(--border);
  margin-top: 2px;
}

.gwd-retailer-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  padding: 12px 18px;
  border-bottom: 1px solid var(--border);
  background: var(--surface);
  color: inherit;
  text-decoration: none;
}

.gwd-retailer-row:hover {
  background: var(--surface2);
}

.gwd-retailer-row:last-child {
  border-bottom: 0;
}

.gwd-iso-badge {
  width: 34px;
  height: 22px;
  flex-shrink: 0;
  border: 1px solid var(--border);
  border-radius: 4px;
  background: var(--surface2);
  color: var(--text3);
  font-size: 9px;
  font-weight: 800;
  display: flex;
  align-items: center;
  justify-content: center;
}

.gwd-retailer-identity {
  display: flex;
  flex-direction: column;
  flex: 1;
  min-width: 0;
}

.gwd-retailer-identity strong,
.gwd-retailer-name-text {
  display: block;
  color: var(--text);
  font-size: 13px;
  font-weight: 900;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.gwd-retailer-identity small,
.gwd-row-colours small,
.gwd-retailer-plastic {
  display: block;
  color: var(--text3);
  font-size: 10px;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.gwd-row-colours {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-shrink: 0;
}

.gwd-row-retailer {
  display: flex;
  flex: 1 1 180px;
  align-items: center;
  gap: 12px;
  min-width: 0;
}

.gwd-swatches-wrap {
  display: flex;
  align-items: center;
  gap: 5px;
}

.gwd-swatch {
  width: 14px;
  height: 14px;
  border-radius: 50%;
  border: 1px solid rgba(0, 0, 0, 0.1);
  background: var(--surface2);
  position: relative;
}

.gwd-swatch.blue { background: #3498DB; }
.gwd-swatch.pink { background: #F9447D; }
.gwd-swatch.glow { background: #D9F99D; }
.gwd-swatch.white { background: #fff; }
.gwd-swatch.green { background: #27AE60; }

.gwd-row-price {
  flex-shrink: 0;
  color: var(--text);
  font-size: 15px;
  font-weight: 800;
  white-space: nowrap;
}

.gwd-row-weight {
  padding: 3px 7px;
  border-radius: 5px;
  background: var(--surface2);
  color: var(--text3);
  font-size: 10px;
  font-weight: 900;
  white-space: nowrap;
}

.gwd-row-action {
  flex: 0 0 auto;
}

.gwd-btn-micro {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 30px;
  padding: 0 12px;
  border-radius: 999px;
  background: var(--primary);
  color: #fff;
  font-size: 12px;
  font-weight: 900;
  text-decoration: none;
}

.best-dot {
  margin-left: 6px;
  color: var(--success);
  font-size: 10px;
  font-weight: 900;
}

.retailer-note {
  color: var(--text3);
  font-size: 12px;
}

.column-narrow {
  max-width: 640px;
  margin: 0 auto;
}

.search-wrap {
  position: relative;
  margin-bottom: 14px;
}

.search-input {
  width: 100%;
  padding: 12px 40px 12px 16px;
  border: 2px solid var(--border);
  border-radius: 14px;
  background: var(--surface);
  color: var(--text);
  font-size: 15px;
  outline: none;
  transition: border-color 0.15s;
}

.search-input:focus {
  border-color: var(--primary);
}

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

.search-clear {
  position: absolute;
  top: 10px;
  right: 12px;
  border: 0;
  background: transparent;
  color: var(--text3);
  font-size: 18px;
}

.autocomplete-list {
  max-height: 420px;
  overflow-y: auto;
  border: 1.5px solid var(--border);
  border-radius: 14px;
  background: var(--surface);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.12);
}

.autocomplete-list.static {
  position: static;
}

.autocomplete-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 11px 14px;
  border-bottom: 1px solid var(--border);
  color: var(--text);
}

.autocomplete-item:last-child {
  border-bottom: 0;
}

.autocomplete-item:hover {
  background: var(--pl);
}

.auto-cat {
  flex-shrink: 0;
  padding: 2px 7px;
  border-radius: 50px;
  background: var(--surface2);
  color: var(--text3);
  font-size: 10px;
  font-weight: 700;
  white-space: nowrap;
}

.search-empty,
.empty-copy {
  padding: 16px;
  color: var(--text3);
  font-size: 13px;
  text-align: center;
}

.added-card,
.detox-card {
  display: grid;
  gap: 12px;
  padding: 14px;
}

.added-card p,
.detox-card p,
.theme-card p {
  color: var(--text2);
  font-size: 13px;
  line-height: 1.55;
}

.tag-screen {
  display: grid;
  grid-template-columns: 190px minmax(0, 1fr);
  gap: 14px;
}

.disc-rail {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.disc-chip {
  min-height: 40px;
  padding: 9px 12px;
  border: 1.5px solid var(--border);
  border-radius: 50px;
  background: var(--surface);
  color: var(--text2);
  font-weight: 700;
  text-align: left;
}

.disc-chip.active {
  border-color: var(--primary);
  background: var(--pl);
  color: var(--primary);
}

.question-card {
  display: grid;
  gap: 16px;
  padding: 18px;
}

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

.question-top h2 {
  margin: 0;
  color: var(--text);
  font-family: Manrope, Inter, sans-serif;
  font-size: 22px;
  line-height: 1.1;
}

.disc-title {
  display: flex;
  align-items: center;
  gap: 12px;
}

.disc-title strong {
  display: block;
  color: var(--text);
  font-size: 18px;
  font-weight: 800;
}

.disc-title small {
  display: block;
  color: var(--text2);
  font-size: 12px;
}

.profile-section {
  display: grid;
  gap: 8px;
}

.elabel {
  display: block;
  color: var(--text3);
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

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

.choice-btn,
.conf-btn {
  border: 2px solid var(--border);
  border-radius: 14px;
  background: var(--surface);
  color: var(--text);
  font-family: Inter, sans-serif;
  font-weight: 700;
  transition: all 0.15s;
}

.choice-btn {
  padding: 12px 10px;
  text-align: center;
}

.choice-btn i,
.conf-btn i {
  display: block;
  margin-bottom: 4px;
  color: var(--primary);
  font-style: normal;
  font-size: 18px;
  line-height: 1;
}

.conf-row {
  display: flex;
  gap: 8px;
}

.conf-btn {
  flex: 1;
  padding: 12px 6px;
  color: var(--text2);
}

.choice-btn.sel,
.conf-btn.sel {
  border-color: var(--primary);
  background: var(--pl);
  color: var(--primary);
}

.owned-disc-controls {
  display: grid;
  gap: 14px;
  padding: 14px;
  border: 1px solid var(--border);
  border-radius: 14px;
  background: var(--surface2);
}

.chip-wrap {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
}

.owned-chip {
  min-height: 34px;
  padding: 7px 10px;
  border: 1.5px solid var(--border);
  border-radius: 999px;
  background: var(--surface);
  color: var(--text2);
  font-size: 12px;
  font-weight: 800;
}

.owned-chip.active {
  border-color: var(--primary);
  background: var(--pl);
  color: var(--primary);
}

.colour-chips .owned-chip {
  text-transform: capitalize;
}

.mini-input {
  width: 100%;
  min-height: 40px;
  border: 1px solid var(--border);
  border-radius: 10px;
  background: var(--surface);
  color: var(--text);
  padding: 8px 10px;
  font-weight: 700;
}

.field-hint {
  color: var(--text3);
  font-size: 12px;
  line-height: 1.45;
}

.help-dot {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 15px;
  height: 15px;
  margin-left: 4px;
  border-radius: 50%;
  background: var(--surface2);
  color: var(--text3);
  font-size: 10px;
  font-weight: 900;
  text-transform: none;
  cursor: help;
  position: relative;
  overflow: visible;
}

.help-dot::after,
.gwd-swatch::after {
  content: attr(data-tooltip);
  position: absolute;
  left: 50%;
  bottom: calc(100% + 8px);
  z-index: 10000;
  width: max-content;
  max-width: 230px;
  padding: 8px 10px;
  border-radius: 8px;
  background: #171412;
  color: #fff;
  font-size: 11px;
  font-weight: 700;
  line-height: 1.35;
  text-align: left;
  text-transform: none;
  letter-spacing: 0;
  white-space: normal;
  opacity: 0;
  pointer-events: none;
  transform: translate(-50%, 4px);
  transition: opacity 0.12s ease, transform 0.12s ease;
}

.help-dot::before,
.gwd-swatch::before {
  content: "";
  position: absolute;
  left: 50%;
  bottom: calc(100% + 3px);
  z-index: 10000;
  border: 5px solid transparent;
  border-top-color: #171412;
  opacity: 0;
  pointer-events: none;
  transform: translateX(-50%);
  transition: opacity 0.12s ease;
}

.help-dot:hover::after,
.help-dot:focus::after,
.gwd-swatch:hover::after,
.help-dot:hover::before,
.help-dot:focus::before,
.gwd-swatch:hover::before {
  opacity: 1;
  transform: translate(-50%, 0);
}

.help-dot:hover::before,
.help-dot:focus::before,
.gwd-swatch:hover::before {
  transform: translateX(-50%);
}

.no-flight-card {
  margin-bottom: 14px;
  padding: 11px 14px;
  border: 1.5px solid var(--warn);
  border-radius: 14px;
  background: rgba(230, 126, 34, 0.08);
}

.no-flight-card strong {
  color: var(--warn);
  font-size: 13px;
}

.no-flight-card p {
  margin-top: 2px;
  color: var(--text2);
  font-size: 12px;
}

.coverage-change {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin: 12px 0;
  padding: 12px 14px;
  border-radius: 14px;
  background: var(--surface2);
  color: var(--text2);
}

.coverage-change strong {
  color: var(--primary);
  font-family: Manrope, Inter, sans-serif;
  font-size: 24px;
}

.disc-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 14px;
  margin-top: 14px;
}

.minimal-grid {
  margin-bottom: 14px;
}

.disc-card-d {
  display: grid;
  gap: 12px;
  padding: 18px;
  border-radius: 16px;
  transition: all 0.15s;
}

.disc-card-d:hover {
  border-color: var(--primary);
  transform: translateY(-2px);
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.06);
}

.preference-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
  margin: 14px 0;
}

.theme-screen {
  max-width: 1120px;
}

.theme-picker {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 10px;
  margin-bottom: 14px;
}

.theme-choice {
  min-height: 78px;
  padding: 12px;
  border: 2px solid var(--border);
  border-radius: 14px;
  background: var(--surface);
  color: var(--text);
  text-align: left;
  transition: all 0.15s;
}

.theme-choice:hover,
.theme-choice.active {
  border-color: var(--primary);
  background: var(--pl);
}

.theme-choice strong {
  display: block;
  font-size: 13px;
  font-weight: 900;
}

.theme-choice small {
  display: block;
  margin-top: 4px;
  color: var(--text2);
  font-size: 11px;
  font-weight: 700;
}

.theme-brief {
  display: grid;
  gap: 8px;
  margin-bottom: 12px;
  padding: 18px;
  border: 1.5px solid var(--border);
  border-radius: 16px;
  background: var(--surface);
}

.theme-brief h2 {
  margin: 0;
  color: var(--text);
  font-family: Manrope, Inter, sans-serif;
  font-size: 28px;
  line-height: 1;
}

.theme-brief p {
  margin: 0;
  color: var(--text2);
  font-size: 14px;
  line-height: 1.55;
}

.theme-proof {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
  margin-top: 6px;
}

.theme-proof span {
  display: grid;
  gap: 3px;
  padding: 10px 12px;
  border-radius: 12px;
  background: var(--surface2);
  color: var(--text2);
  font-size: 12px;
  line-height: 1.45;
}

.theme-proof strong {
  color: var(--primary);
  font-size: 10px;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.theme-controls {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
  margin-bottom: 14px;
}

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

.theme-slot {
  display: grid;
  gap: 10px;
}

.theme-slot-head {
  display: flex;
  align-items: center;
  gap: 8px;
  color: var(--text);
}

.theme-slot-head > span {
  width: 10px;
  height: 10px;
  border-radius: 999px;
  flex-shrink: 0;
}

.theme-slot-head strong {
  font-size: 14px;
  font-weight: 900;
}

.theme-slot-head small {
  color: var(--text3);
  font-size: 12px;
}

.theme-slot-picks {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 12px;
}

.theme-disc-card {
  border-radius: 14px;
}

.theme-disc-card p strong {
  color: var(--text);
}

.theme-stock-line {
  color: var(--text3);
  font-size: 12px;
  font-weight: 700;
}

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

.trait-row {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 6px;
  padding: 10px;
  border: 1px solid var(--border);
  border-radius: 12px;
  background: var(--surface);
}

.classification-pill,
.trait-pill {
  display: inline-flex;
  align-items: center;
  min-height: 24px;
  padding: 4px 8px;
  border-radius: 999px;
  font-size: 10px;
  font-weight: 900;
}

.classification-pill {
  background: #F8F2EA;
  color: #5A0127;
  border: 1px solid rgba(124, 2, 54, 0.15);
}

.dark .classification-pill {
  background: #1E1E1E;
  color: #F9447D;
  border-color: rgba(249, 68, 125, 0.2);
}

.trait-pill {
  background: var(--surface2);
  color: var(--text2);
}

.soft-labels span {
  padding: 5px 8px;
  border-radius: 999px;
  background: var(--pl);
  color: var(--primary);
  font-size: 11px;
  font-weight: 800;
}

.share-control-card,
.import-card,
.import-review {
  display: grid;
  gap: 12px;
  padding: 16px;
}

.share-control-card p {
  margin: 0;
  color: var(--text2);
  font-size: 13px;
  line-height: 1.5;
}

.share-link-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 8px;
}

.share-link-row input,
.import-textarea {
  width: 100%;
  border: 1px solid var(--border);
  border-radius: 10px;
  background: var(--surface2);
  color: var(--text);
  padding: 10px;
  font: inherit;
  font-size: 13px;
}

.import-textarea {
  min-height: 150px;
  resize: vertical;
}

.upload-box {
  display: grid;
  place-items: center;
  min-height: 130px;
  border: 2px dashed var(--border);
  border-radius: 14px;
  background: var(--surface2);
  color: var(--primary);
  font-weight: 900;
  cursor: pointer;
}

.upload-box input {
  display: none;
}

.import-review-list {
  display: grid;
  gap: 8px;
}

.import-review-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto auto;
  align-items: center;
  gap: 8px;
  padding: 10px;
  border: 1px solid var(--border);
  border-radius: 12px;
  background: var(--surface2);
}

.import-review-row strong,
.import-review-row small {
  display: block;
}

.import-review-row small {
  color: var(--text3);
  font-size: 11px;
}

.public-page,
.public-preview {
  display: grid;
  gap: 14px;
}

.public-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 14px;
}

.public-head h1 {
  margin: 8px 0 4px;
  color: var(--text);
  font-family: Manrope, Inter, sans-serif;
  font-size: 34px;
}

.public-head p {
  margin: 0;
  color: var(--text2);
  line-height: 1.55;
}

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

.public-attr {
  color: var(--text3);
  font-size: 12px;
  font-weight: 800;
  text-align: center;
}

.profile-edit-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 11px 14px;
  border: 1px solid var(--border);
  border-radius: 12px;
  background: var(--surface);
  color: var(--text);
  font-weight: 700;
}

.profile-edit-row input {
  width: 120px;
  min-height: 34px;
  border: 1px solid var(--border);
  border-radius: 8px;
  background: var(--surface2);
  color: var(--text);
  padding: 6px 8px;
}

.profile-identity {
  margin-bottom: 14px;
}

.stat-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
  margin-bottom: 14px;
}

.start-screen {
  max-width: 720px;
  margin: 0 auto;
}

.onboard-hero {
  text-align: center;
  padding: 28px 20px 20px;
}

.onboard-logo {
  display: block;
  width: min(230px, 72vw);
  height: auto;
  margin: 0 auto 16px;
}

.start-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
  margin-bottom: 14px;
}

.skill-card {
  display: flex;
  align-items: center;
  gap: 12px;
  min-height: 86px;
  padding: 14px 16px;
  border: 2px solid var(--border);
  border-radius: 14px;
  background: var(--surface);
  color: var(--text);
  text-align: left;
  transition: all 0.15s;
}

.skill-card.sel,
.skill-card:hover {
  border-color: var(--primary);
  background: var(--pl);
}

.skill-icon {
  width: 36px;
  height: 36px;
  border-radius: 10px;
  background: var(--surface2);
  color: var(--primary);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.skill-card strong {
  display: block;
  font-size: 14px;
}

.skill-card small {
  display: block;
  margin-top: 2px;
  color: var(--text2);
  font-size: 12px;
}

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

.mini-added span,
.mode-copy {
  color: var(--text2);
  font-size: 12px;
}

.mini-added span {
  padding: 4px 9px;
  border-radius: 50px;
  background: var(--surface2);
  font-weight: 700;
}

.detox-modes {
  margin: 14px 0 8px;
}

.mode-copy {
  margin-bottom: 12px;
  line-height: 1.5;
}

.share-card {
  display: grid;
  gap: 14px;
  padding: 18px;
  border: 1px solid var(--border);
  border-radius: 20px;
  background: var(--surface);
  box-shadow: var(--sh);
  margin: 14px 0;
}

.share-logo {
  pointer-events: none;
}

.share-logo img {
  width: 156px;
}

.share-list {
  display: grid;
  gap: 8px;
}

.share-list p {
  color: var(--text2);
  font-size: 13px;
}

.save-cta-card {
  display: grid;
  gap: 10px;
  padding: 14px;
  margin: 14px 0;
}

.save-cta-card strong {
  color: var(--text);
  font-size: 15px;
}

.save-cta-card p,
.import-message {
  color: var(--text2);
  font-size: 12px;
  line-height: 1.5;
}

.import-label {
  position: relative;
  overflow: hidden;
}

.import-label input {
  position: absolute;
  inset: 0;
  opacity: 0;
  cursor: pointer;
}

.import-row {
  align-items: center;
}

.stat-box {
  padding: 12px;
  border: 1px solid var(--border);
  border-radius: 12px;
  background: var(--surface);
  text-align: center;
}

.stat-val {
  color: var(--primary);
  font-size: 22px;
  font-weight: 800;
}

.stat-lbl {
  margin-top: 2px;
  color: var(--text3);
  font-size: 10px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.empty-screen {
  min-height: 60vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 10px;
  text-align: center;
}

.empty-screen h1 {
  color: var(--text);
  font-size: 20px;
}

.empty-screen p {
  color: var(--text2);
}

.detox-empty {
  width: 52px;
  height: 52px;
  border-radius: 50%;
  background: var(--pl);
  color: var(--primary);
  display: flex;
  align-items: center;
  justify-content: center;
}

.overlay-wrap {
  position: fixed;
  inset: 0;
  z-index: 99;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
  background: rgba(0, 0, 0, 0.55);
  backdrop-filter: blur(4px);
}

.overlay-panel {
  position: relative;
  width: min(540px, 100%);
  max-height: 88vh;
  overflow-y: auto;
  padding: 28px;
  border: 1px solid var(--border);
  border-radius: 20px;
  background: var(--surface);
  box-shadow: 0 24px 80px rgba(0, 0, 0, 0.45);
  animation: scaleIn 0.22s cubic-bezier(0.25, 0.8, 0.25, 1);
}

@keyframes scaleIn {
  from {
    opacity: 0;
    transform: scale(0.96);
  }
  to {
    opacity: 1;
    transform: scale(1);
  }
}

.panel-handle {
  display: none;
}

.modal-close {
  position: absolute;
  top: 14px;
  right: 14px;
  width: 32px;
  height: 32px;
  border: 1px solid var(--border);
  border-radius: 50%;
  background: var(--surface);
  color: var(--text2);
  font-size: 18px;
  line-height: 1;
}

.sheet-title {
  margin-bottom: 14px;
}

.tag-row {
  display: flex;
  flex-wrap: wrap;
  gap: 5px;
  margin: 12px 0;
}

.sheet-copy {
  margin: 12px 0;
  color: var(--text2);
  font-size: 13px;
  line-height: 1.6;
}

.tweaks-panel {
  position: fixed;
  right: 24px;
  bottom: 24px;
  z-index: 200;
  width: 280px;
  padding: 18px;
  border: 1px solid var(--border);
  border-radius: 16px;
  background: var(--surface);
  box-shadow: 0 16px 48px rgba(0, 0, 0, 0.3);
  animation: fadeUp 0.2s ease;
}

.tweaks-head,
.tweak-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.tweaks-head {
  margin-bottom: 14px;
}

.tweaks-head button {
  width: 24px;
  height: 24px;
  border: 1.5px solid var(--border);
  border-radius: 50%;
  background: var(--surface2);
  color: var(--text2);
}

.tweak-row {
  margin-bottom: 14px;
}

.tweak-row:last-child {
  margin-bottom: 0;
}

.tweak-label {
  color: var(--text);
  font-size: 13px;
  font-weight: 600;
}

.tweak-toggle {
  width: 44px;
  height: 24px;
  border: 0;
  border-radius: 12px;
  background: var(--border);
  position: relative;
  flex-shrink: 0;
}

.tweak-toggle::after {
  content: "";
  position: absolute;
  top: 2px;
  left: 2px;
  width: 20px;
  height: 20px;
  border-radius: 50%;
  background: #fff;
  box-shadow: 0 1px 4px rgba(0, 0, 0, 0.2);
  transition: transform 0.2s;
}

.tweak-toggle.on {
  background: var(--primary);
}

.tweak-toggle.on::after {
  transform: translateX(20px);
}

@media (max-width: 1180px) {
  .map-grid {
    grid-template-columns: 1fr;
  }

  .recommend-sticky {
    position: static;
  }
}

@media (max-width: 920px) {
  body {
    background: #111;
  }

  .app-frame {
    width: min(430px, 100vw);
    min-height: 100vh;
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    background: var(--bg);
    position: relative;
  }

  .topbar {
    position: static;
    flex-shrink: 0;
    height: 62px;
    padding: 14px 20px 12px;
  }

  .logo {
    font-size: 20px;
  }

  .identity-stat {
    display: none;
  }

  .sidebar {
    display: none;
  }

  .main {
    flex: 1;
    overflow-y: auto;
    padding: 16px 16px 88px;
    scrollbar-width: none;
  }

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

  .bottom-nav {
    height: 68px;
    padding: 0 2px 12px;
    display: flex;
    align-items: center;
    border-top: 1px solid var(--border);
    background: var(--surface);
    flex-shrink: 0;
    position: fixed;
    left: 50%;
    bottom: 0;
    width: min(430px, 100vw);
    transform: translateX(-50%);
    z-index: 30;
  }

  .bottom-nav .nav-item {
    flex: 1;
    flex-direction: column;
    justify-content: center;
    gap: 3px;
    padding: 5px 8px;
    border-radius: 12px;
  }

  .bottom-nav .nav-label {
    color: var(--text3);
    font-size: 9px;
    font-weight: 700;
    letter-spacing: 0.03em;
    text-transform: uppercase;
  }

  .bottom-nav .nav-item.active .nav-label {
    color: var(--primary);
  }

  .page-head {
    margin-bottom: 18px;
  }

  .section-h {
    font-size: 24px;
  }

  .kpi-row {
    grid-template-columns: repeat(2, 1fr);
    gap: 8px;
    margin-bottom: 18px;
  }

  .kpi-card {
    padding: 12px;
  }

  .map-grid,
  .tag-screen,
  .preference-grid,
  .theme-controls,
  .theme-proof,
  .public-summary-grid,
  .share-link-row,
  .import-review-row {
    grid-template-columns: 1fr;
  }

  .theme-picker {
    grid-template-columns: 1fr;
  }

  .theme-choice {
    min-height: 62px;
  }

  .theme-brief {
    padding: 15px;
  }

  .theme-brief h2 {
    font-size: 24px;
  }

  .theme-slot-picks {
    grid-template-columns: 1fr;
  }

  .map-card {
    padding: 12px 10px 8px;
  }

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

  .disc-rail {
    flex-direction: row;
    overflow-x: auto;
    padding-bottom: 2px;
  }

  .disc-chip {
    flex: 0 0 auto;
  }

  .question-card {
    padding: 14px;
  }

  .overlay-wrap {
    align-items: flex-end;
    padding: 0;
  }

  .overlay-panel {
    width: min(430px, 100vw);
    max-height: 92vh;
    border-radius: 24px 24px 0 0;
    border-width: 1px 0 0;
    padding: 10px 20px 28px;
    animation: slideUp 0.28s cubic-bezier(0.25, 0.8, 0.25, 1);
  }

  .panel-handle {
    display: block;
    width: 36px;
    height: 4px;
    margin: 0 auto 14px;
    border-radius: 2px;
    background: var(--border);
  }

  .modal-close {
    top: 12px;
    right: 14px;
  }

  .tweaks-panel {
    right: calc(50% - min(430px, 100vw) / 2 + 12px);
    bottom: 72px;
    width: 220px;
    padding: 16px;
  }

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

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

@keyframes slideUp {
  from {
    transform: translateY(100%);
  }
  to {
    transform: translateY(0);
  }
}

@media (max-width: 430px) {
  .app-frame,
  .bottom-nav,
  .overlay-panel {
    width: 100vw;
  }

  .main {
    padding-left: 14px;
    padding-right: 14px;
  }

  .conf-row {
    flex-wrap: wrap;
  }
}

@media (prefers-reduced-motion: reduce) {
  .gap-zone circle:first-child,
  .gap-zone circle:nth-child(2),
  .screen,
  .overlay-panel,
  .retailer-expanded {
    animation: none;
  }

  .disc-dot,
  .swipe-nav-btn,
  .swipe-dot {
    transition: none;
  }
}
