/* ============================================================
   Theme switcher chip (js/drop-theme.js)
   ------------------------------------------------------------
   Bottom-left, opposite the quick-access dock (bottom-right).
   Shown only while at least one drop theme is open, so in a
   plain Original period this file draws nothing.
   This is the ORIGINAL look of the chip; a drop theme restyles
   it inside its own file (css/themes/<id>-style.css).
   ============================================================ */
.theme-chip {
  position: fixed;
  left: 16px;
  bottom: calc(16px + env(safe-area-inset-bottom, 0px));
  z-index: 60;
  font-family: var(--font-body);
}
.theme-chip__toggle {
  display: inline-flex; align-items: center; gap: 8px;
  min-height: 44px;
  padding: 8px 14px 8px 12px;
  background: var(--paper);
  color: var(--ink);
  border: var(--line-w) solid var(--ink);
  border-radius: 999px;
  box-shadow: 3px 3px 0 var(--ink);
  cursor: pointer;
  font: inherit;
  font-size: 13px;
  font-weight: 700;
  line-height: 1;
}
.theme-chip__toggle:hover { transform: translate(-1px, -1px); box-shadow: 4px 4px 0 var(--ink); }
.theme-chip__toggle:focus-visible,
.theme-chip__opt:focus-visible { outline: 3px solid var(--blue); outline-offset: 2px; }
.theme-chip__eyebrow {
  font-family: var(--font-display);
  font-size: 11px; letter-spacing: 0.12em;
  background: var(--ink); color: var(--paper);
  padding: 3px 6px; border-radius: 999px;
}
.theme-chip__caret { font-size: 10px; transition: transform .2s; }
.theme-chip.is-open .theme-chip__caret { transform: rotate(180deg); }

.theme-chip__menu {
  position: absolute;
  left: 0; bottom: calc(100% + 10px);
  width: max-content; min-width: 240px; max-width: calc(100vw - 32px);
  background: var(--paper);
  color: var(--ink);
  border: var(--line-w) solid var(--ink);
  border-radius: 10px;
  box-shadow: 4px 4px 0 var(--ink);
  padding: 8px;
}
.theme-chip__menu[hidden] { display: none; }
.theme-chip__title {
  font-family: var(--font-display); font-size: 14px; letter-spacing: 0.08em;
  margin: 4px 8px 8px;
}
.theme-chip__note { font-size: 12px; margin: 0 8px 8px; color: var(--ink-soft); }
.theme-chip__opt {
  display: grid; grid-template-columns: 14px 1fr; column-gap: 10px; align-items: center;
  width: 100%; min-height: 44px;
  padding: 8px 10px;
  background: none; border: 0; border-radius: 6px;
  color: inherit; text-align: left; cursor: pointer;
  font: inherit; font-size: 14px; font-weight: 700;
  text-decoration: none;
}
.theme-chip__opt:hover { background: var(--yellow); }
.theme-chip__opt .ko-en,
.theme-chip__opt .theme-chip__hint {
  grid-column: 2;
  font-size: 11px; font-weight: 500; color: var(--ink-soft);
}
.theme-chip__hint::before { content: '→ '; }
.theme-chip__dot {
  width: 12px; height: 12px; border-radius: 999px;
  border: 2px solid var(--ink);
  grid-row: 1 / span 3;
}
.theme-chip__opt.is-selected .theme-chip__dot { background: var(--red); }

/* Phones: lift clear of the product page's sticky buy bar, and keep the
   chip from covering content by shrinking it to its label. */
@media (max-width: 720px) {
  .theme-chip { left: 10px; bottom: calc(10px + env(safe-area-inset-bottom, 0px)); }
  .theme-chip__toggle { padding: 8px 12px 8px 10px; }
  .theme-chip__now { max-width: 34vw; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
}
@media (prefers-reduced-motion: reduce) {
  .theme-chip__caret, .theme-chip__toggle { transition: none; }
}
