/* Show My Bike — Configurator Styles
 * Extracted from konfigurator.html without visual changes.
 */

/* ─── TYRE COLOR SELECTOR ─── */
.tyre-color-btns {
  display: flex;
  gap: 8px;
}
.tyre-color-btn {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 5px 11px;
  border: 1px solid var(--border-hi);
  border-radius: var(--r-xs);
  background: var(--bg);
  color: var(--text-mid);
  font-family: var(--ff-display);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.02em;
  cursor: pointer;
  transition: border-color 0.12s, background 0.12s, color 0.12s;
}
.tyre-color-btn:hover {
  border-color: var(--accent);
  color: var(--text);
}
.tyre-color-btn.active {
  border-color: var(--accent);
  background: var(--accent-tint);
  color: var(--text);
}
.tyre-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  display: inline-block;
  flex-shrink: 0;
}

.exit-btn {
  display: none;
  font-size: 12px;
  font-weight: 500;
  color: var(--text-mid);
  background: none;
  border: 1px solid var(--border);
  border-radius: var(--r-pill);
  cursor: pointer;
  padding: 6px 14px;
  transition: color 0.15s, border-color 0.15s;
}
.exit-btn:hover { color: var(--text); border-color: var(--border-hi); }
.exit-btn.visible { display: block; }

/* ─── MAIN GRID ─── */
.main {
  max-width: 1400px;
  margin: 0 auto;
  padding: 12px 14px;
  display: grid;
  grid-template-columns: 240px 1fr 240px;
  gap: 10px;
  align-items: start;
}

/* ─── CONFIGURATOR HEADER ─── */
.configurator-header {
  grid-column: 1 / -1;
  display: flex;
  align-items: baseline;
  gap: 16px;
  padding: 4px 0 6px;
  border-bottom: 1px solid var(--border);
  margin-bottom: 2px;
}
.configurator-title {
  font-family: var(--ff-display);
  font-weight: 700;
  font-size: 18px;
  letter-spacing: -0.02em;
  color: var(--text);
}
.configurator-sub {
  font-size: 12px;
  font-weight: 400;
  color: var(--text-mid);
  letter-spacing: 0.01em;
}

/* ─── PANELS ─── */
.panel {
  background: var(--bg2);
  border: 1px solid var(--border);
  border-radius: var(--r-md);
  overflow: hidden;
}

.panel-title {
  font-family: var(--ff-body);
  font-size: 10px;
  font-weight: 600;
  color: var(--text-low);
  text-transform: uppercase;
  letter-spacing: 0.12em;
  padding: 10px 12px 8px;
  border-bottom: 1px solid var(--border);
}

.brand-tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 3px;
  padding: 8px 8px 0;
}

.brand-tab {
  flex: 1;
  padding: 5px 3px;
  font-family: var(--ff-body);
  font-size: 10px;
  font-weight: 500;
  letter-spacing: 0.02em;
  text-align: center;
  border-radius: var(--r-xs);
  cursor: pointer;
  border: 1px solid var(--border);
  background: transparent;
  color: var(--text-mid);
  transition: all 0.12s;
  white-space: nowrap;
}
.brand-tab:hover { border-color: var(--accent-light); color: var(--accent-light); }
.brand-tab.active { background: var(--accent); border-color: var(--accent); color: #fff; }

/* ─── CATEGORY FILTER ─── */
.cat-filter {
  display: flex;
  gap: 3px;
  padding: 6px 8px 4px;
  flex-wrap: wrap;
}
.cat-btn {
  flex: 1;
  padding: 4px 3px;
  font-family: var(--ff-body);
  font-size: 9px;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-align: center;
  border-radius: var(--r-xs);
  cursor: pointer;
  border: 1px solid var(--border);
  background: transparent;
  color: var(--text-mid);
  transition: all 0.12s;
  white-space: nowrap;
  text-transform: uppercase;
}
.cat-btn:hover { opacity: 0.85; }
.cat-btn.active-all  { background: var(--accent); border-color: var(--accent); color: #fff; }
.cat-btn.active-race { background: #ef4444; border-color: #ef4444; color: #fff; }
.cat-btn.active-aero { background: #06b6d4; border-color: #06b6d4; color: #fff; }
.cat-btn.active-end  { background: #10b981; border-color: #10b981; color: #fff; }
.cat-btn-race { border-color: rgba(248,113,113,0.45); color: #f87171; }
.cat-btn-race:hover { border-color: #ef4444; color: #ef4444; }
.cat-btn-aero { border-color: rrgba(34,211,238,0.45); color: #22d3ee; }
.cat-btn-aero:hover { border-color: #06b6d4; color: #06b6d4; }
.cat-btn-end  { border-color: rgba(52,211,153,0.45); color: #34d399; }
.cat-btn-end:hover  { border-color: #10b981; color: #10b981; }

/* ── WHEEL FILTER SYSTEM ─────────────────────────────────── */

/* Mode toggle row — sits above category buttons, looks different */
.wheel-mode-toggle {
  display: flex;
  gap: 3px;
  padding: 6px 8px 2px;
}
.wheel-mode-btn {
  flex: 1;
  padding: 5px 4px;
  font-family: var(--ff-body);
  font-size: 9px;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-align: center;
  border-radius: var(--r-xs);
  cursor: pointer;
  border: 1px solid var(--border);
  background: transparent;
  color: var(--text-low);
  transition: all 0.14s;
  text-transform: uppercase;
}
/* Rim height mode — grey/neutral active */
.wheel-mode-btn.active-tech {
  background: var(--bg4);
  border-color: var(--border-hi);
  color: var(--text-mid);
}
/* Price mode — amber/gold active */
.wheel-mode-btn.active-price {
  background: rgba(245,158,11,0.14);
  border-color: rgba(245,158,11,0.40);
  color: #F59E0B;
}
.wheel-mode-btn:hover:not(.active-tech):not(.active-price) {
  border-color: var(--border-hi);
  color: var(--text-mid);
}

/* Category filter row */
.wheel-cat-filter {
  display: flex;
  gap: 3px;
  padding: 2px 8px 4px;
  flex-wrap: wrap;
}
/* Tech category active — grey filled */
.wcat-btn-active-tech {
  background: var(--bg4) !important;
  border-color: var(--border-hi) !important;
  color: var(--text) !important;
}
/* Price category active — amber filled */
.wcat-btn-active-price {
  background: rgba(245,158,11,0.16) !important;
  border-color: rgba(245,158,11,0.45) !important;
  color: #F59E0B !important;
}

/* Wheelset item tags — passive, informational only */
.wheel-tags { display: flex; gap: 3px; margin-top: 3px; flex-wrap: wrap; }
.whl-tag {
  display: inline-block;
  font-size: 8px;
  font-weight: 600;
  letter-spacing: 0.07em;
  text-transform: uppercase;
  padding: 1px 5px;
  border-radius: var(--r-xs);
}
/* All rim profile tags: uniform quiet grey */
.whl-tag-rp {
  background: var(--bg3);
  color: var(--text-low);
}
/* All price tags: uniform quiet amber */
.whl-tag-pt {
  background: rgba(245,158,11,0.10);
  color: rgba(245,158,11,0.75);
}

/* ─── CATEGORY BADGES on items ─── */
.cat-badge {
  display: inline-block;
  font-size: 8px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  padding: 1px 5px;
  border-radius: var(--r-xs);
  margin-top: 2px;
}
.cat-badge-race { background: rgba(220,38,38,0.15); color: #f87171; }
.cat-badge-aero { background: rgba(8,145,178,0.15); color: #22d3ee; }
.cat-badge-end  { background: rgba(5,150,105,0.15); color: #34d399; }

.panel-scroll {
  max-height: calc(100vh - 160px);
  overflow-y: auto;
  padding: 6px;
  scrollbar-width: thin;
  scrollbar-color: var(--border) transparent;
}
.panel-scroll::-webkit-scrollbar { width: 4px; }
.panel-scroll::-webkit-scrollbar-track { background: transparent; }
.panel-scroll::-webkit-scrollbar-thumb { background: var(--border); border-radius: 2px; }

/* ─── ITEMS ─── */
.item {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 6px 8px;
  border-radius: var(--r-sm);
  cursor: pointer;
  border: 1.5px solid transparent;
  transition: all 0.12s;
  margin-bottom: 2px;
}
.item:hover { background: var(--bg3); border-color: var(--border-hi); }
.item.sel-a { border-color: var(--accent); background: var(--accent-tint); }
.item.sel-b { border-color: var(--amber); background: rgba(245,158,11,0.08); }

.item-thumb {
  width: 44px;
  height: 32px;
  object-fit: contain;
  flex-shrink: 0;
  border-radius: var(--r-xs);
  background: var(--bg3);
}

.item-name {
  font-size: 12px;
  font-weight: 500;
  color: var(--text);
  line-height: 1.3;
}
.item-sub {
  font-size: 11px;
  color: var(--text-mid);
  margin-top: 1px;
}

/* ─── RIGHT COLUMN ─── */
.right-col { display: flex; flex-direction: column; gap: 10px; }

/* ─── SPEC CARD ─── */
.spec-card {
  background: var(--bg2);
  border: 1px solid var(--border);
  border-radius: var(--r-md);
  padding: 12px;
  display: none;
}
.spec-card-name {
  font-family: var(--ff-display);
  font-size: 13px;
  font-weight: 600;
  color: var(--text);
  margin-bottom: 10px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  letter-spacing: -0.01em;
}
.spec-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 5px 0;
  border-bottom: 1px solid var(--border);
}
.spec-row:last-child { border-bottom: none; }
.spec-lbl { font-size: 10px; color: var(--text-mid); }
.spec-val { font-size: 10px; font-weight: 600; color: var(--text); text-align: right; }
.spec-link { display: flex; justify-content: flex-end; margin-top: 8px; padding-top: 8px; border-top: 1px solid var(--border); }
.spec-link a { font-size: 10px; color: var(--accent-light); text-decoration: none; font-weight: 600; }
.spec-link a:hover { text-decoration: underline; }

/* ─── COMPARE SPEC ─── */
.compare-spec { display: none; grid-template-columns: 1fr 1fr; gap: 8px; }
.compare-spec.visible { display: grid; }
.cspec {
  background: var(--bg2);
  border: 1.5px solid var(--border);
  border-radius: var(--r-sm);
  padding: 10px;
}
.cspec.cspec-a { border-color: var(--accent); background: var(--accent-tint); }
.cspec.cspec-b { border-color: var(--amber); background: rgba(245,158,11,0.05); }
.cspec-tag { font-size: 9px; font-weight: 700; text-transform: uppercase; letter-spacing: 0.1em; margin-bottom: 4px; color: var(--text-low); }
.cspec.cspec-a .cspec-tag { color: var(--accent-light); }
.cspec.cspec-b .cspec-tag { color: var(--amber); }
.cspec-name { font-size: 10px; font-weight: 600; color: var(--text); margin-bottom: 7px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.cspec .spec-row { padding: 3px 0; }
.cspec .spec-lbl { font-size: 9px; }
.cspec .spec-val { font-size: 9px; }
.cspec-empty { font-size: 10px; color: var(--text-low); font-style: italic; padding: 4px 0; }

/* ─── CENTER COLUMN ─── */
.center { display: flex; flex-direction: column; gap: 10px; }

/* ─── BUILD LABEL ─── */
.build-label {
  background: var(--bg2);
  border: 1px solid var(--border);
  border-radius: var(--r-md);
  padding: 10px 20px;
  text-align: center;
}
.build-frame {
  font-family: var(--ff-display);
  font-size: 16px;
  font-weight: 700;
  letter-spacing: -0.02em;
  color: var(--text);
}
.build-wheel { font-size: 12px; color: var(--text-mid); margin-top: 2px; }
.build-label.empty { font-size: 12px; color: var(--text-low); padding: 12px 20px; letter-spacing: 0.02em; }

/* ─── COMPARE HEADER ─── */
.compare-header { display: none; grid-template-columns: 1fr 1fr; gap: 8px; }
.compare-header.visible { display: grid; }

.cbuild {
  padding: 10px 12px;
  border-radius: var(--r-sm);
  border: 1.5px solid var(--border);
  background: var(--bg2);
  cursor: pointer;
  transition: all 0.12s;
  min-width: 0;
  overflow: hidden;
}
.cbuild:hover { border-color: var(--border-hi); }
.cbuild.active { border-color: var(--accent); background: var(--accent-tint); }
.cbuild.active-b { border-color: var(--amber); background: rgba(245,158,11,0.08); }

.cbuild-media {
  display: none;
}

.cbuild-tag {
  font-size: 9px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--text-low);
  margin-bottom: 2px;
}
.cbuild.active .cbuild-tag { color: var(--accent-light); }
.cbuild.active-b .cbuild-tag { color: var(--amber); }
.cbuild-name {
  font-size: 11px;
  font-weight: 600;
  color: var(--text);
  overflow: hidden;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  word-break: break-word;
}
.cbuild-wheel { font-size: 10px; color: var(--text-mid); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

/* ─── STAGE ─── */
.stage {
  background: linear-gradient(to bottom, #f5f5f5, #eaeaea);
  border: 1px solid #e0e0e0;
  border-radius: var(--r-md);
  overflow: hidden;
}
.stage-inner {
  position: relative;
  width: 100%;
  padding-bottom: 65%;
  isolation: isolate;
  user-select: none;
}
#stage-inner img, #side-a img, #side-b img { pointer-events: none !important; user-select: none !important; }

#normal-wheels { position: absolute; inset: 0; z-index: 1; }
#normal-frame  { position: absolute; inset: 0; z-index: 2; }
#normal-wheels img, #normal-frame img { position: absolute; object-fit: contain; display: none; }
#nf-img { left: 20%; top: 10%; width: 60%; height: 80%; }

#side-a, #side-b { position: absolute; inset: 0; display: none; overflow: hidden; }
.side-wheels { position: absolute; inset: 0; z-index: 1; }
.side-frame  { position: absolute; inset: 0; z-index: 2; }
.side-wheels img, .side-frame img { position: absolute; object-fit: contain; display: none; }
.sf-img { left: 20%; top: 10%; width: 60%; height: 80%; }

#slider-line {
  position: absolute; top: 0; bottom: 0; width: 2px;
  background: rgba(43,43,43,0.52);
  z-index: 20; cursor: ew-resize;
  transform: translateX(-50%);
  box-shadow: 0 0 12px rgba(0,0,0,0.6);
  display: none;
}
#slider-handle {
  position: absolute; top: 50%; left: 50%;
  transform: translate(-50%,-50%);
  width: 36px; height: 36px;
  background: var(--accent);
  border-radius: 50%;
  box-shadow: 0 2px 12px rgba(0,0,0,0.5);
  display: flex; align-items: center; justify-content: center;
  font-size: 13px; cursor: ew-resize;
  color: #fff;
}

.stage-label {
  position: absolute; top: 10px;
  padding: 3px 10px; border-radius: var(--r-pill);
  font-family: var(--ff-body);
  font-size: 10px; font-weight: 700;
  text-transform: uppercase; letter-spacing: 0.08em;
  z-index: 10; display: none; pointer-events: none;
}
#lbl-a { left: 10px; background: var(--accent); color: #fff; }
#lbl-b { right: 10px; background: var(--amber); color: #fff; }

.hint {
  position: absolute; inset: 0;
  display: flex; flex-direction: column;
  align-items: center; justify-content: center;
  gap: 8px; z-index: 5;
}
.hint-icon { font-size: 28px; opacity: 0.2; }
.hint-text { font-size: 12px; color: #aaa; text-align: center; line-height: 1.5; letter-spacing: 0.02em; }

/* ─── BUTTONS ─── */
.compare-btn-wrap { display: flex; justify-content: center; }
.compare-btn {
  display: none;
  padding: 11px 28px;
  border-radius: var(--r-sm);
  border: none;
  background: var(--accent);
  color: #fff;
  font-family: var(--ff-body);
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 0.01em;
  cursor: pointer;
  transition: background 0.15s, box-shadow 0.15s;
}
.compare-btn:hover { background: var(--accent); color: #fff; box-shadow: 0 4px 16px var(--accent-glow); }
.compare-btn.visible { display: block; }

.share-btn-wrap { display: flex; justify-content: center; align-items: center; gap: 6px; margin-top: 4px; }
.share-btn, .reset-btn {
  display: none;
  align-items: center;
  gap: 5px;
  padding: 7px 16px;
  background: transparent;
  border: 1px solid var(--border-hi);
  color: var(--text-mid);
  border-radius: var(--r-pill);
  font-family: var(--ff-body);
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 0.01em;
  cursor: pointer;
  transition: border-color 0.15s, color 0.15s;
  white-space: nowrap;
  line-height: 1;
}
.share-btn:hover { border-color: var(--accent-light); color: var(--accent-light); }
.reset-btn:hover { border-color: var(--accent); color: var(--accent); }
.share-btn.visible { display: flex; }
.share-btn.ec-loading{opacity:.55;cursor:wait;pointer-events:none}
.reset-btn.visible { display: flex; }

/* ─── FOOTER NOTES ─── */
.footer-note { text-align: center; font-size: 10px; color: var(--text-low); letter-spacing: 0.02em; }

/* ─── TOAST ─── */
#share-toast {
  position: fixed; bottom: 24px; left: 50%;
  transform: translateX(-50%) translateY(16px);
  background: #fff; color: var(--text);
  border: 1px solid var(--border-hi);
  padding: 10px 22px; border-radius: var(--r-sm);
  font-family: var(--ff-body);
  font-size: 13px; font-weight: 500;
  letter-spacing: 0.01em;
  opacity: 0; transition: all 0.25s;
  pointer-events: none; z-index: 999; white-space: nowrap;
}
#share-toast.show { opacity: 1; transform: translateX(-50%) translateY(0); }

/* ─── MOBILE SPEC ─── */
#mobile-spec { display: none; }

/* ─── STAGE PROTECT ─── */
#stage-protect { position: absolute; inset: 0; z-index: 15; cursor: default; }

/* ─── MOBILE ─── */
.m-brand-select { display: none; }

/* ─── FOOTER ─── */
.footer-logo {
  font-family: var(--ff-display);
  font-size: 20px;
  letter-spacing: 0.02em;
  color: var(--text);
  text-decoration: none;
}

@media (max-width: 500px) {
  * { -webkit-tap-highlight-color: transparent; }
  input, select, textarea { font-size: 16px; }

  body { background: var(--bg); }

  .main { grid-template-columns: 1fr; padding: 8px; gap: 8px; }
  .center { gap: 6px; }
  .stage-inner { padding-bottom: 58%; }

  .build-frame { font-size: 13px; }
  .build-wheel { font-size: 11px; }
  .build-label { padding: 8px 14px; border-radius: var(--r-sm); }
  .build-label.empty { padding: 10px 14px; font-size: 11px; }

  .compare-btn, .share-btn { font-size: 13px; padding: 10px 20px; }

  .panel { border-radius: var(--r-sm); }
  .panel-title { padding: 9px 10px 6px; }
  .brand-tabs { display: none; }

  .m-brand-select {
    display: none;
    margin: 0 8px 6px;
    width: calc(100% - 16px);
    font-size: 16px;
    padding: 8px 10px;
    border-radius: var(--r-sm);
    border: 1px solid var(--border-hi);
    background: var(--bg3);
    color: var(--text);
    font-weight: 600;
    font-family: var(--ff-body);
    -webkit-appearance: none;
    appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath d='M1 1l5 5 5-5' stroke='%23666' stroke-width='1.5' fill='none'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 12px center;
    padding-right: 32px;
  }

  .panel-scroll {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 5px;
    padding: 6px 8px 10px;
    max-height: none;
    overflow: visible;
  }

  .item {
    flex-direction: column;
    align-items: center;
    padding: 6px 3px;
    text-align: center;
    gap: 3px;
    margin-bottom: 0;
    border-radius: var(--r-xs);
  }
  .item-thumb { width: 100%; max-width: 56px; height: 36px; object-fit: contain; }
  .item-name { font-size: 9px; line-height: 1.2; word-break: break-word; hyphens: auto; pointer-events: none; }
  .item-sub { display: none; }

  .right-col { gap: 8px; }
  .spec-card { display: none !important; }
  .compare-spec { display: none !important; }

  .cbuild { padding: 8px 10px; touch-action: manipulation; }
  .cbuild-tag { font-size: 9px; }
  .cbuild-name { font-size: 12px; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
  .cbuild-wheel { font-size: 11px; }

  .footer-note { font-size: 9px; }

  #mobile-spec { display: none; background: var(--bg2); border: 1px solid var(--border); border-radius: var(--r-sm); padding: 10px 14px; }
  #mobile-spec.visible { display: block; }
  .mspec-name { font-family: var(--ff-display); font-weight: 700; font-size: 13px; letter-spacing: -0.01em; color: var(--text); margin-bottom: 6px; }
  .mspec-row { display: flex; justify-content: space-between; padding: 3px 0; border-bottom: 1px solid var(--border); }
  .mspec-row:last-of-type { border-bottom: none; }
  .mspec-lbl { color: var(--text-low); font-size: 11px; }
  .mspec-val { font-weight: 600; font-size: 11px; color: var(--text); }
  .mspec-link { display: flex; justify-content: flex-end; margin-top: 7px; padding-top: 6px; border-top: 1px solid var(--border); }
  .mspec-link a { font-size: 14px; color: var(--accent-light); text-decoration: none; font-weight: 600; }
}


/* ── ACTION BAR ──────────────────────────────────────────── */
@keyframes action-bar-in {
  from { opacity: 0; transform: translateY(6px); }
  to   { opacity: 1; transform: translateY(0); }
}
@keyframes action-bar-out {
  from { opacity: 1; transform: translateY(0); }
  to   { opacity: 0; transform: translateY(6px); }
}

/* ── UNIFIED ACTION BAR (normal + compare modes) ─────────── */
.action-bar,
.compare-action-bar {
  width: 100%;
  margin-top: 0;
  position: relative;
  background: var(--bg2);
  border: 1px solid var(--border-hi);
  border-radius: var(--r-md);
  padding: 10px 16px;
  display: none;
  flex-direction: row;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  box-shadow: var(--shadow-card);
  flex-wrap: wrap;
}
.action-bar.visible,
.compare-action-bar.visible {
  display: flex;
  animation: action-bar-in 0.18s ease-out forwards;
}
.action-bar.hiding {
  display: flex;
  animation: action-bar-out 0.18s ease-out forwards;
}

/* Text block — left side */
.action-bar-text {
  text-align: left;
  min-width: 0;
  flex: 1;
}
.action-bar-label {
  font-family: var(--ff-body);
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--text-low);
  margin-bottom: 2px;
}
.action-bar-summary {
  font-family: var(--ff-display);
  font-size: 13px;
  font-weight: 600;
  color: var(--text);
  letter-spacing: -0.01em;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* Buttons block — right side */
.action-bar-buttons {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-shrink: 0;
}

/* Shared button base */
.action-btn-primary,
.action-btn-secondary,
.action-btn-coming-soon {
  height: 40px;
  padding: 0 16px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  border-radius: var(--r-pill);
  font-family: var(--ff-body);
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 0.01em;
  cursor: pointer;
  transition: background 0.14s, box-shadow 0.14s, transform 0.1s, border-color 0.14s, color 0.14s;
  white-space: nowrap;
  flex-shrink: 0;
}
.action-btn-primary svg,
.action-btn-secondary svg,
.action-btn-coming-soon svg { flex-shrink: 0; }

.action-btn-primary {
  background: var(--accent);
  color: #fff;
  border: 1px solid transparent;
}
.action-btn-primary:hover { background: var(--accent-light); box-shadow: 0 4px 20px var(--accent-glow); }
.action-btn-primary:active { transform: scale(0.98); }
.action-btn-primary:focus-visible { outline: 2px solid var(--accent-light); outline-offset: 3px; }

.action-btn-secondary {
  background: transparent;
  color: var(--text-mid);
  border: 1px solid var(--border-hi);
}
.action-btn-secondary:hover { border-color: rgba(255,255,255,0.28); color: var(--text); }
.action-btn-secondary:active { transform: scale(0.98); }
.action-btn-secondary:focus-visible { outline: 2px solid var(--border-hi); outline-offset: 3px; }
.action-btn-secondary.ec-loading { opacity: 0.55; cursor: wait; pointer-events: none; }

.action-btn-coming-soon {
  background: transparent;
  color: var(--text-low);
  border: 1px solid var(--border);
  cursor: not-allowed;
  opacity: 0.5;
}

/* Reset — tertiary, inline with buttons */
.action-bar-reset { display: flex; align-items: center; flex-shrink: 0; }
.action-reset-btn {
  display: flex;
  align-items: center;
  gap: 5px;
  padding: 4px 8px;
  background: none;
  border: none;
  border-radius: var(--r-pill);
  font-family: var(--ff-body);
  font-size: 11px;
  font-weight: 500;
  color: var(--text-low);
  cursor: pointer;
  letter-spacing: 0.01em;
  transition: color 0.14s, background 0.14s;
}
.action-reset-btn:hover { color: var(--text-mid); background: var(--bg3); }
.action-reset-btn:focus-visible { outline: 2px solid var(--border-hi); outline-offset: 2px; }

/* Compare-mode export button (legacy, unused) */
.compare-export-wrap { display: none; }

@media (max-width: 600px) {
  /* On mobile: fixed bar, vertical stacking */
  .action-bar,
  .compare-action-bar {
    position: fixed;
    bottom: 0; left: 0; right: 0;
    width: 100%;
    margin: 0;
    border-radius: var(--r-md) var(--r-md) 0 0;
    border-left: none; border-right: none; border-bottom: none;
    padding: 12px 16px;
    padding-bottom: calc(12px + env(safe-area-inset-bottom));
    box-shadow: 0 -4px 16px rgba(0,0,0,0.25);
    z-index: 90;
    background: rgba(255,255,255,0.97);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    flex-direction: column;
    align-items: stretch;
    gap: 8px;
  }
  .action-bar-text { text-align: center; }
  .action-bar-buttons {
    flex-direction: column;
    gap: 8px;
    width: 100%;
  }
  .action-btn-primary,
  .action-btn-secondary,
  .action-btn-coming-soon {
    width: 100%;
    height: 44px;
  }
  .action-bar-reset { justify-content: center; }
}
