/* ============================================================
   DANO'S BLUNTS - style.css (v6)
   Palette: dark slate + burnt orange
   --slate0  #171C21  page background
   --slate1  #212932  panel
   --slate2  #33404C  borders / rules
   --brass   #D96A2B  burnt orange (primary accent)
   --brasshi #F08B45  bright burnt orange (headings, glow)
   --ink     #E8A377  body font (soft burnt orange)
   --copper  #B14E1E  deep burnt accent
   ============================================================ */

:root {
  --slate0: #171C21;
  --slate1: #212932;
  --slate2: #33404C;
  --brass: #D96A2B;
  --brasshi: #F08B45;
  --ink: #E8A377;
  --inkhi: #F5C9A8;
  --copper: #B14E1E;
  --danger: #C24B36;
  --ok: #7FA05A;
}

* { box-sizing: border-box; }

html, body { margin: 0; padding: 0; }

body {
  background:
    repeating-linear-gradient(93deg,
      rgba(51, 64, 76, 0.10) 0px, rgba(51, 64, 76, 0.10) 2px,
      transparent 2px, transparent 11px),
    linear-gradient(180deg, #1B2127, var(--slate0)),
    var(--slate0);
  color: var(--ink);
  font-family: "Lora", Georgia, serif;
  font-size: 17px;
  line-height: 1.6;
}

.mono { font-family: "IBM Plex Mono", Consolas, monospace; }

.hidden { display: none !important; }

/* ---------- Hero band (welcome page only) ---------- */
.band-hero {
  background: #FFFFFF;
  border-bottom: 4px solid var(--brass);
  text-align: center;
}
.band-img {
  display: block;
  width: 100%;
  max-width: 1100px;
  margin: 0 auto;
  height: auto;
}

/* ---------- Tabs + mini logo ---------- */
.tabs {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 10px;
  background: linear-gradient(180deg, #1E252C, var(--slate0));
  border-bottom: 1px solid var(--slate2);
  position: sticky;
  top: 0;
  z-index: 20;
}
.mini-logo {
  height: 30px;
  width: auto;
  border-radius: 3px;
  border: 1px solid var(--slate2);
  background: #FFF;
  margin-right: 8px;
}
.tab {
  font-family: "Rye", "Lora", serif;
  font-size: 0.85rem;
  letter-spacing: 0.04em;
  color: var(--brass);
  background: linear-gradient(180deg, #2A333D, #1D242B);
  border: 1px solid var(--slate2);
  border-radius: 3px;
  padding: 10px 16px;
  cursor: pointer;
  transition: color 0.15s, border-color 0.15s;
}
.tab:hover { color: var(--brasshi); border-color: var(--brass); }
.tab:focus-visible { outline: 2px solid var(--brasshi); outline-offset: 2px; }
.tab.active {
  color: #14181C;
  background: linear-gradient(180deg, var(--brasshi), var(--brass));
  border-color: var(--brasshi);
}
.tab-admin { opacity: 0.75; }

.tabs-admin {
  position: static;
  background: none;
  border-bottom: none;
  padding: 4px 0 18px 0;
  justify-content: flex-start;
}
.tabs-admin .tab { font-family: "IBM Plex Mono", monospace; font-size: 0.8rem; }

/* ---------- Views ---------- */
.view { display: none; }
.view.active { display: block; }
.aview { display: none; }
.aview.active { display: block; }

.wrap {
  max-width: 1060px;
  margin: 0 auto;
  padding: 34px 20px 70px 20px;
}

/* ---------- Signature: cigar-band section header ---------- */
.band-head {
  display: flex;
  align-items: center;
  gap: 14px;
  margin: 44px 0 18px 0;
  scroll-margin-top: 80px;
}
.band-head:first-child { margin-top: 6px; }
.band-head::before, .band-head::after {
  content: "";
  flex: 1;
  height: 7px;
  border-top: 1px solid var(--brass);
  border-bottom: 1px solid var(--brass);
}
.band-head span {
  font-family: "Rye", serif;
  font-size: 1.35rem;
  color: var(--brasshi);
  padding: 6px 22px;
  border: 1px solid var(--brass);
  border-radius: 40px / 24px;
  background: linear-gradient(180deg, #2A333D, #1D242B);
  box-shadow: 0 0 0 3px var(--slate0), 0 0 0 4px var(--slate2);
  white-space: nowrap;
}

.lede { font-size: 1.12rem; font-style: italic; color: var(--inkhi); }

/* ---------- Home features / care ---------- */
.feature-grid, .care-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 16px;
  margin-top: 18px;
}
.feature, .care {
  background: linear-gradient(180deg, var(--slate1), #1B222A);
  border: 1px solid var(--slate2);
  border-radius: 4px;
  padding: 18px 20px;
}
.feature h3, .care h3 {
  margin: 0 0 8px 0;
  font-family: "Rye", serif;
  font-weight: 400;
  font-size: 1.05rem;
  color: var(--brass);
}
.feature p, .care p { margin: 0; font-size: 0.97rem; }

.spec-card { margin: 26px 0 0 0; text-align: center; }
.spec-card img {
  max-width: 520px;
  width: 100%;
  border: 1px solid var(--slate2);
  border-radius: 4px;
  box-shadow: 0 8px 30px rgba(0, 0, 0, 0.55);
}
.spec-card figcaption { font-size: 0.9rem; color: var(--brass); margin-top: 10px; font-style: italic; }

/* ---------- Stock grid ---------- */
.stock-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
  gap: 16px;
  margin-top: 18px;
}
.stock-item {
  background: linear-gradient(180deg, var(--slate1), #1B222A);
  border: 1px solid var(--slate2);
  border-radius: 4px;
  padding: 16px 18px;
}
.stock-item h3 { margin: 0 0 6px 0; font-family: "Rye", serif; font-weight: 400; color: var(--brasshi); font-size: 1.02rem; }
.stock-item .meta { font-size: 0.88rem; color: var(--ink); margin: 2px 0; }
.stock-item .price { font-family: "IBM Plex Mono", monospace; color: var(--brasshi); font-size: 1.15rem; margin-top: 10px; }
.stock-item .sold { color: var(--danger); font-family: "IBM Plex Mono", monospace; }
.stock-item button { margin-top: 10px; }
.stock-empty { color: var(--ink); font-style: italic; opacity: 0.8; }

/* ---------- Tables ---------- */
.inv-table {
  width: 100%;
  border-collapse: collapse;
  margin-top: 14px;
  font-size: 0.9rem;
}
.inv-table th {
  font-family: "IBM Plex Mono", monospace;
  font-size: 0.75rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--brass);
  text-align: left;
  padding: 8px 10px;
  border-bottom: 2px solid var(--brass);
}
.inv-table td {
  padding: 8px 10px;
  border-bottom: 1px solid var(--slate2);
  vertical-align: middle;
}
.inv-table tr:hover td { background: rgba(217, 106, 43, 0.06); }
.tag { font-family: "IBM Plex Mono", monospace; font-size: 0.72rem; padding: 2px 8px; border-radius: 3px; border: 1px solid; }
.tag-standard { color: var(--ink); border-color: var(--slate2); }
.tag-premium { color: var(--brass); border-color: var(--brass); }
.tag-exotic { color: var(--brasshi); border-color: var(--brasshi); }
.tag-used { color: var(--copper); border-color: var(--copper); }
.tag-ok { color: var(--ok); border-color: var(--ok); }
.tag-low { color: var(--danger); border-color: var(--danger); }

/* ---------- Selection wheel ---------- */
.wheel-wrap {
  display: flex;
  justify-content: center;
  margin: 26px 0 4px 0;
}
.wheel {
  width: 300px;
  max-width: 84vw;
  overflow: visible;
}
.wheel-track {
  fill: none;
  stroke: #1D242B;
  stroke-width: 18;
}
.wheel-seg {
  fill: none;
  stroke: var(--slate2);
  stroke-width: 18;
  stroke-linecap: round;
  /* circumference of r=92 is ~578.05; arc ~118 leaves a gap per quarter */
  stroke-dasharray: 118 460.05;
  cursor: pointer;
  transition: stroke 0.3s, filter 0.3s;
}
.wheel-seg:hover { stroke: var(--copper); }
.wheel-seg.lit {
  stroke: var(--brasshi);
  filter: drop-shadow(0 0 7px rgba(240, 139, 69, 0.95));
}
.wheel.complete .wheel-seg.lit {
  filter: drop-shadow(0 0 11px rgba(240, 139, 69, 1));
}
.wheel-label {
  font-family: "IBM Plex Mono", monospace;
  font-size: 11px;
  letter-spacing: 0.14em;
  fill: var(--brass);
}
.wheel-price {
  font-family: "IBM Plex Mono", monospace;
  font-size: 30px;
  fill: var(--brasshi);
}
.wheel-sub {
  font-family: "IBM Plex Mono", monospace;
  font-size: 10px;
  letter-spacing: 0.1em;
  fill: var(--ink);
}

/* ---------- Tile pickers (wood / length / finish) ---------- */
.pick-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
  gap: 14px;
  margin-top: 16px;
}
.pick-grid-big {
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
}
.pick-tile {
  background: linear-gradient(180deg, var(--slate1), #1B222A);
  border: 2px solid var(--slate2);
  border-radius: 5px;
  padding: 10px;
  cursor: pointer;
  text-align: center;
  transition: border-color 0.15s, box-shadow 0.15s;
}
.pick-tile:hover { border-color: var(--brass); }
.pick-tile.selected {
  border-color: var(--brasshi);
  box-shadow: 0 0 10px rgba(240, 139, 69, 0.55);
}
.pick-tile.out { opacity: 0.4; cursor: not-allowed; }
.pick-img {
  position: relative;
  height: 84px;
  border-radius: 3px;
  background:
    repeating-linear-gradient(45deg,
      rgba(51, 64, 76, 0.35) 0px, rgba(51, 64, 76, 0.35) 8px,
      transparent 8px, transparent 16px),
    #1A2026;
  border: 1px dashed var(--slate2);
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
}
.pick-grid-big .pick-img { height: 120px; }
.pick-img .ph {
  font-family: "IBM Plex Mono", monospace;
  font-size: 0.66rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--slate2);
}
.pick-img img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.pick-name {
  margin-top: 8px;
  font-family: "Rye", serif;
  font-size: 0.86rem;
  color: var(--inkhi);
  line-height: 1.25;
}
.pick-sub { margin-top: 5px; font-size: 0.72rem; }

/* ---------- Band picker ---------- */
.band-controls {
  display: flex;
  flex-wrap: wrap;
  align-items: end;
  gap: 12px;
  margin: 14px 0;
}
.inline-label {
  font-family: "IBM Plex Mono", monospace;
  font-size: 0.78rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--brass);
  flex: 1 1 240px;
}
.inline-label select {
  display: block;
  width: 100%;
  margin-top: 6px;
  background: #1B222A;
  color: var(--inkhi);
  border: 1px solid var(--slate2);
  border-radius: 3px;
  padding: 10px 12px;
  font-family: "Lora", serif;
  font-size: 0.98rem;
}
.btn-inline { width: auto; flex: 0 0 auto; }

.one-done-notice {
  background: #241A12;
  border: 1px solid var(--brass);
  border-left: 4px solid var(--brasshi);
  border-radius: 4px;
  padding: 10px 14px;
  margin: 0 0 12px 0;
  font-size: 0.85rem;
  color: var(--ink);
}
.one-done-notice strong { color: var(--brasshi); }
.monthly-banner {
  background: linear-gradient(90deg, #2A1B0E, #241A12);
  border: 1px solid var(--brasshi);
  border-radius: 4px;
  padding: 10px 14px;
  margin: 0 0 12px 0;
  font-size: 0.9rem;
  color: var(--brasshi);
  font-family: "Rye", serif;
  letter-spacing: 0.03em;
}

/* Two-pane band picker: folder list and image grid scroll independently */
.band-gallery-wrap {
  display: flex;
  gap: 14px;
  margin: 0 0 16px 0;
  height: 480px;
}
.band-folder-nav {
  flex: 0 0 210px;
  overflow-y: auto;
  background: #14191E;
  border: 1px solid var(--slate2);
  border-radius: 4px;
  padding: 8px;
}
.band-gallery-grid {
  flex: 1;
  min-width: 0;
  overflow-y: auto;
  background: #14191E;
  border: 1px solid var(--slate2);
  border-radius: 4px;
  padding: 14px;
}
.folder-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 8px;
  padding: 7px 9px;
  margin-bottom: 3px;
  border-radius: 3px;
  cursor: pointer;
  font-size: 0.82rem;
  color: var(--ink);
  transition: background 0.12s, color 0.12s;
}
.folder-item:hover { background: #1F2731; color: var(--brasshi); }
.folder-item.active {
  background: var(--brass);
  color: #14191E;
  font-weight: 600;
}
.folder-item.active em { color: #14191E; }
.folder-item span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.folder-item em { font-style: normal; font-size: 0.7rem; color: var(--ink); flex-shrink: 0; }
.folder-item.folder-cat { font-family: "Rye", serif; font-size: 0.85rem; letter-spacing: 0.02em; }
.folder-item.folder-sub { padding-left: 20px; font-size: 0.78rem; }

.band-gallery-row {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
  gap: 12px;
  margin-bottom: 10px;
}
.band-group-head {
  margin: 4px 0 10px 0;
  border-bottom: 1px solid var(--slate2);
  padding-bottom: 4px;
}
.band-group-head span {
  font-family: "Rye", serif;
  font-size: 0.92rem;
  color: var(--brass);
  letter-spacing: 0.04em;
}
.band-group-sel span { color: var(--brasshi); }
.band-group-sel { border-bottom-color: var(--brass); }
.band-empty-note { color: var(--ink); font-size: 0.85rem; padding: 8px 0; }
.band-tile.pinned { box-shadow: 0 0 12px rgba(240, 139, 69, 0.45); }
.band-tile {
  cursor: pointer;
  border: 2px solid var(--slate2);
  border-radius: 4px;
  background: #FFF;
  padding: 4px;
  text-align: center;
  transition: border-color 0.12s, box-shadow 0.12s;
}
.band-tile:hover { border-color: var(--brass); }
.band-tile.selected {
  border-color: var(--brasshi);
  box-shadow: 0 0 10px rgba(240, 139, 69, 0.8);
}
.band-tile img { width: 100%; height: 100px; object-fit: contain; display: block; }
.band-tile-txt {
  height: 100px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.78rem;
  color: #333;
  padding: 2px;
}
.band-tile-name {
  font-family: "IBM Plex Mono", monospace;
  font-size: 0.64rem;
  color: #4A2E17;
  margin-top: 3px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.band-preview {
  display: block;
  max-width: 340px;
  width: 100%;
  margin: 0 0 16px 0;
  border: 1px solid var(--brass);
  border-radius: 3px;
  background: #FFF;
  padding: 4px;
}
.band-thumb {
  width: 84px;
  height: auto;
  display: block;
  border: 1px solid var(--slate2);
  border-radius: 2px;
  background: #FFF;
}

/* ---------- Order form ---------- */
.config-grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr;
  gap: 26px;
  margin-top: 20px;
}
.config-form label {
  display: block;
  margin-bottom: 14px;
  font-family: "IBM Plex Mono", monospace;
  font-size: 0.78rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--brass);
}
.config-form select,
.config-form input,
.config-form textarea,
.add-row input, .add-row select,
.settings-grid input,
.gate-row input,
.price-in {
  display: block;
  width: 100%;
  margin-top: 6px;
  background: #1B222A;
  color: var(--inkhi);
  border: 1px solid var(--slate2);
  border-radius: 3px;
  padding: 10px 12px;
  font-family: "Lora", serif;
  font-size: 0.98rem;
}
.price-in { margin-top: 0; padding: 6px 8px; max-width: 130px; }
.config-form select:focus, .config-form input:focus, .config-form textarea:focus,
.price-in:focus, .inline-label select:focus {
  outline: 2px solid var(--brass);
}

.price-panel {
  background: linear-gradient(180deg, #2A333D, #1B222A);
  border: 1px solid var(--brass);
  border-radius: 4px;
  padding: 22px;
  align-self: start;
  position: sticky;
  top: 90px;
}
.price-panel h3 { margin: 0 0 12px 0; font-family: "Rye", serif; font-weight: 400; color: var(--brasshi); }
.price-panel ul { list-style: none; margin: 0 0 14px 0; padding: 0; font-size: 0.82rem; }
.price-panel li { display: flex; justify-content: space-between; padding: 4px 0; border-bottom: 1px dotted var(--slate2); }
.price-total {
  font-size: 1.9rem;
  color: var(--brasshi);
  text-align: right;
  margin: 8px 0 6px 0;
}
.lead-note { font-size: 0.85rem; color: var(--ink); font-style: italic; margin-bottom: 14px; }

/* ---------- Buttons ---------- */
.btn-brass {
  font-family: "IBM Plex Mono", monospace;
  font-size: 0.85rem;
  letter-spacing: 0.05em;
  color: #14181C;
  background: linear-gradient(180deg, var(--brasshi), var(--brass));
  border: 1px solid var(--brasshi);
  border-radius: 3px;
  padding: 11px 18px;
  cursor: pointer;
  width: 100%;
  text-align: center;
}
.btn-brass:hover { filter: brightness(1.08); }
.btn-brass:focus-visible { outline: 2px solid var(--inkhi); outline-offset: 2px; }
.btn-small { width: auto; padding: 5px 10px; font-size: 0.72rem; }
.btn-slate {
  font-family: "IBM Plex Mono", monospace;
  font-size: 0.85rem;
  letter-spacing: 0.05em;
  color: var(--inkhi);
  background: linear-gradient(180deg, #2E3944, #222B34);
  border: 1px solid var(--slate2);
  border-radius: 3px;
  padding: 11px 18px;
  cursor: pointer;
}
.btn-slate:hover { border-color: var(--brass); color: var(--brasshi); }
.btn-danger {
  font-family: "IBM Plex Mono", monospace;
  font-size: 0.85rem;
  color: var(--inkhi);
  background: linear-gradient(180deg, #6E3325, #52251A);
  border: 1px solid var(--danger);
  border-radius: 3px;
  padding: 11px 18px;
  cursor: pointer;
}
.btn-file { display: inline-block; }

.order-msg { margin-top: 12px; font-size: 0.9rem; color: var(--ok); min-height: 1.4em; }
.order-msg.err { color: var(--danger); }

/* ---------- Admin ---------- */
.gate-row { display: flex; gap: 12px; max-width: 380px; }
.gate-row .btn-brass { width: auto; }

.books-cards {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(190px, 1fr));
  gap: 14px;
  margin-top: 16px;
}
.book-card {
  background: linear-gradient(180deg, var(--slate1), #1B222A);
  border: 1px solid var(--slate2);
  border-radius: 4px;
  padding: 16px 18px;
}
.book-card .k { font-family: "IBM Plex Mono", monospace; font-size: 0.7rem; letter-spacing: 0.08em; text-transform: uppercase; color: var(--brass); }
.book-card .v { font-family: "IBM Plex Mono", monospace; font-size: 1.5rem; color: var(--brasshi); margin-top: 4px; }

.add-row {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
  gap: 10px;
  margin-top: 14px;
  align-items: end;
}
.add-row input, .add-row select { margin-top: 0; }
.add-row .btn-brass { width: auto; }

.settings-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 16px;
  margin-top: 16px;
  align-items: end;
}
.settings-grid label {
  font-family: "IBM Plex Mono", monospace;
  font-size: 0.78rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--brass);
}
.settings-grid .btn-brass, .settings-grid .btn-danger { width: auto; }

.qty-btns { display: flex; gap: 4px; }

select.status-sel {
  background: #1B222A;
  color: var(--inkhi);
  border: 1px solid var(--slate2);
  border-radius: 3px;
  padding: 4px 6px;
  font-family: "IBM Plex Mono", monospace;
  font-size: 0.78rem;
}

/* ---------- Footer ---------- */
.foot {
  border-top: 1px solid var(--slate2);
  padding: 22px;
  text-align: center;
  font-size: 0.85rem;
  color: var(--ink);
}
.foot .mono { font-size: 0.72rem; color: #7C5B41; margin-top: 4px; }

/* ---------- Print label ---------- */
.label-print { display: none; }
@media print {
  body > *:not(.label-print) { display: none !important; }
  body { background: #FFF; }
  .label-print {
    display: block;
    color: #000;
    font-family: "Lora", Georgia, serif;
    padding: 40px;
  }
  .label-print .label-box {
    border: 2px solid #000;
    padding: 24px 28px;
    max-width: 480px;
    font-size: 18px;
    line-height: 1.5;
  }
  .label-print .label-from { font-size: 12px; margin-bottom: 18px; }
  .label-print .label-order {
    font-family: "IBM Plex Mono", monospace;
    font-size: 11px;
    margin-top: 18px;
    color: #444;
  }
}

/* ---------- Responsive ---------- */
@media (max-width: 820px) {
  .config-grid { grid-template-columns: 1fr; }
  .price-panel { position: static; }
  .band-head span { font-size: 1.05rem; white-space: normal; }
}

@media (prefers-reduced-motion: reduce) {
  * { transition: none !important; }
  .wheel-seg, .wheel-seg.lit { filter: none; }
}

/* ============================================================
   v7 additions: Bud Review, supplies, order sheet
   ============================================================ */

.vendor-strip { font-size: 0.9rem; }
.vendor-strip a, .resupply { color: var(--brasshi); text-decoration: none; border-bottom: 1px dotted var(--brass); }
.vendor-strip a:hover, .resupply:hover { color: var(--inkhi); }

/* Review cards (public) */
.review-card {
  background: linear-gradient(180deg, var(--slate1), #1B222A);
  border: 1px solid var(--slate2);
  border-left: 4px solid var(--brass);
  border-radius: 4px;
  padding: 22px 24px;
  margin-top: 20px;
}
.rv-head { display: flex; justify-content: space-between; align-items: start; gap: 16px; }
.rv-head h3 { margin: 0 0 6px 0; font-family: "Rye", serif; font-weight: 400; font-size: 1.3rem; color: var(--brasshi); }
.rv-meta { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; font-size: 0.8rem; }
.rv-date { opacity: 0.7; }
.rv-score { text-align: center; flex: 0 0 auto; }
.rv-score-num { font-size: 2.2rem; color: var(--brasshi); display: block; line-height: 1; }
.rv-score-of { font-family: "IBM Plex Mono", monospace; font-size: 0.7rem; color: var(--ink); }
.rv-sub {
  font-family: "IBM Plex Mono", monospace;
  font-size: 0.72rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--brass);
  margin: 18px 0 8px 0;
}
.terp-box { display: grid; gap: 6px; }
.terp-row { display: grid; grid-template-columns: 130px 1fr 60px; gap: 10px; align-items: center; }
.terp-name { font-size: 0.85rem; color: var(--inkhi); }
.terp-track {
  height: 10px;
  background: #14191E;
  border: 1px solid var(--slate2);
  border-radius: 5px;
  overflow: hidden;
}
.terp-fill {
  display: block;
  height: 100%;
  background: linear-gradient(90deg, var(--copper), var(--brasshi));
  border-radius: 5px;
}
.terp-pct { font-size: 0.75rem; text-align: right; color: var(--ink); }

.rv-cats {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(210px, 1fr));
  gap: 12px;
  margin-top: 16px;
}
.rv-cat {
  background: #1A2026;
  border: 1px solid var(--slate2);
  border-radius: 4px;
  padding: 12px 14px;
}
.rv-cat-head { display: flex; justify-content: space-between; align-items: center; }
.rv-cat-name { font-family: "Rye", serif; font-size: 0.9rem; color: var(--brass); }
.rv-dots { display: flex; gap: 3px; }
.dot {
  width: 11px; height: 11px;
  border-radius: 50%;
  border: 1px solid var(--slate2);
  background: #14191E;
}
.dot.on {
  background: var(--brasshi);
  border-color: var(--brasshi);
  box-shadow: 0 0 5px rgba(240, 139, 69, 0.7);
}
.rv-note { margin: 8px 0 0 0; font-size: 0.87rem; color: var(--ink); }
.rv-verdict {
  margin-top: 16px;
  padding: 12px 16px;
  border-left: 3px solid var(--brasshi);
  background: rgba(217, 106, 43, 0.07);
  font-style: italic;
  color: var(--inkhi);
}

/* Review editor */
.terp-rows { display: grid; gap: 8px; margin-top: 10px; }
.terp-input-row { display: grid; grid-template-columns: 1fr 110px; gap: 10px; max-width: 420px; }
.terp-input-row select, .terp-input-row input {
  background: #1B222A; color: var(--inkhi);
  border: 1px solid var(--slate2); border-radius: 3px;
  padding: 8px 10px; font-family: "Lora", serif;
}
.rating-rows { display: grid; gap: 8px; margin-top: 10px; }
.rating-input-row {
  display: grid;
  grid-template-columns: 90px 70px 1fr;
  gap: 10px;
  align-items: center;
}
.rating-cat { font-family: "Rye", serif; font-size: 0.9rem; color: var(--brass); }
.rating-input-row input {
  background: #1B222A; color: var(--inkhi);
  border: 1px solid var(--slate2); border-radius: 3px;
  padding: 8px 10px; font-family: "Lora", serif;
}
.verdict-label {
  display: block; margin-top: 18px;
  font-family: "IBM Plex Mono", monospace;
  font-size: 0.78rem; letter-spacing: 0.06em;
  text-transform: uppercase; color: var(--brass);
}
.verdict-label textarea {
  display: block; width: 100%; margin-top: 6px;
  background: #1B222A; color: var(--inkhi);
  border: 1px solid var(--slate2); border-radius: 3px;
  padding: 10px 12px; font-family: "Lora", serif; font-size: 0.98rem;
}

/* Order sheet (print) */
@media print {
  .sheet { max-width: 680px; color: #000; }
  .sheet-head { display: flex; justify-content: space-between; align-items: center; border-bottom: 3px solid #000; padding-bottom: 12px; }
  .sheet-logo { height: 60px; width: auto; }
  .sheet-po { font-family: "IBM Plex Mono", monospace; font-size: 22px; font-weight: 600; }
  .sheet-meta { font-family: "IBM Plex Mono", monospace; font-size: 11px; margin: 10px 0 20px 0; color: #333; }
  .sheet-cols { display: flex; gap: 30px; }
  .sheet-col { flex: 1; }
  .sheet-col h4 { font-family: "IBM Plex Mono", monospace; font-size: 11px; letter-spacing: 0.1em; border-bottom: 1px solid #000; padding-bottom: 4px; }
  .sheet-build { width: 100%; border-collapse: collapse; font-size: 14px; }
  .sheet-build td { padding: 5px 8px; border-bottom: 1px solid #CCC; }
  .sheet-build td:first-child { font-family: "IBM Plex Mono", monospace; font-size: 10px; text-transform: uppercase; color: #555; width: 70px; }
  .sheet-band { max-width: 100%; max-height: 110px; margin-top: 12px; border: 1px solid #000; }
  .sheet-total { margin-top: 26px; padding: 12px; border: 2px solid #000; font-family: "IBM Plex Mono", monospace; font-size: 16px; font-weight: 600; text-align: right; }
  .sheet-foot { margin-top: 20px; font-size: 11px; font-style: italic; color: #444; }
}

/* Batch order print sheet - 8 slips per page, cut apart on sticker paper */
@media print {
  .batch-page {
    display: grid;
    grid-template-columns: 1fr 1fr;
    grid-template-rows: repeat(4, 1fr);
    gap: 0;
    width: 100%;
    page-break-after: always;
  }
  .batch-page:last-child { page-break-after: auto; }
  .batch-slip {
    border: 1px dashed #999;
    padding: 10px 12px;
    color: #000;
    font-family: "Lora", Georgia, serif;
    display: flex;
    flex-direction: column;
    gap: 3px;
    min-height: 0;
    overflow: hidden;
  }
  .slip-head {
    display: flex; align-items: center; gap: 8px;
    font-size: 13px; font-weight: 600;
    border-bottom: 1px solid #000; padding-bottom: 3px;
  }
  .slip-win { color: #A15A00; font-weight: 700; font-size: 11px; }
  .slip-band { max-height: 46px; max-width: 100%; object-fit: contain; align-self: flex-start; }
  .slip-noband {
    height: 30px; display: flex; align-items: center;
    font-size: 11px; color: #777; font-style: italic;
  }
  .slip-ship { font-size: 11px; line-height: 1.3; }
  .slip-build { font-size: 10px; color: #333; }
  .slip-band-name { font-size: 10px; font-style: italic; color: #555; }
  .slip-total { font-size: 12px; font-weight: 700; margin-top: auto; text-align: right; }
}

/* v8: band status box + lead info */
.band-status {
  grid-column: 1 / -1;
  background: rgba(217, 106, 43, 0.08);
  border: 1px dashed var(--brass);
  border-radius: 4px;
  padding: 16px 20px;
  color: var(--inkhi);
  font-size: 0.95rem;
}
.band-status p { margin: 6px 0; }
.lead-info {
  margin-top: 12px;
  font-size: 0.78rem;
  color: var(--brasshi);
  padding: 10px 12px;
  background: #1A2026;
  border: 1px solid var(--slate2);
  border-radius: 3px;
}

/* v8.7: retired band rows in admin table */
.row-retired { opacity: 0.5; }
.row-retired td { filter: grayscale(60%); }

/* v8.8: band admin cards - replaces the wide table so nothing runs
   off-screen at high browser zoom, and the preview image is big
   enough to actually identify the design at a glance. */
.band-admin-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 16px;
  margin-bottom: 20px;
}
.band-card {
  background: #14191E;
  border: 1px solid var(--slate2);
  border-radius: 6px;
  overflow: hidden;
  display: flex;
  flex-direction: column;
}
.band-card.row-retired { opacity: 0.55; }
.band-card.row-retired .band-card-img { filter: grayscale(70%); }
.band-card-img {
  width: 100%;
  height: 170px;
  background: #FFF;
  display: flex;
  align-items: center;
  justify-content: center;
  border-bottom: 1px solid var(--slate2);
}
.band-card-img img { width: 100%; height: 100%; object-fit: contain; }
.band-card-body { padding: 12px 14px; display: flex; flex-direction: column; gap: 8px; }
.band-card-title {
  font-family: "Rye", serif;
  font-size: 1rem;
  color: var(--brasshi);
  line-height: 1.25;
}
.band-card-folder { font-size: 0.72rem; color: var(--ink); }
.band-card-stats {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  font-size: 0.78rem;
  color: var(--ink);
}
.band-card-stats strong { color: var(--inkhi); }
.band-card-reusable {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 0.78rem;
  color: var(--ink);
  cursor: pointer;
}
.band-card-actions {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  margin-top: 4px;
  flex-wrap: wrap;
}
.band-card-actions .btn-danger { margin-left: auto; }

/* v8.10: root-form and add-on toggles */
.root-form-toggle, .addon-toggle {
  display: flex;
  align-items: center;
  gap: 8px;
  margin: 6px 0 18px 0;
  padding: 10px 14px;
  background: #14191E;
  border: 1px solid var(--slate2);
  border-radius: 4px;
  font-size: 0.88rem;
  color: var(--ink);
  cursor: pointer;
}
.root-form-toggle input:disabled { cursor: not-allowed; }
.root-form-toggle .mono, .addon-toggle .mono { color: var(--brasshi); margin-left: auto; }

/* v8.11: band print sheet, invoice, order log, banner */
.band-sheet-banner {
  margin: 0 0 16px 0;
  padding: 12px 16px;
  background: rgba(217, 106, 43, 0.08);
  border: 1px dashed var(--brass);
  border-radius: 4px;
  color: var(--inkhi);
  font-size: 0.88rem;
}
.band-sheet-banner.band-sheet-full {
  background: rgba(217, 106, 43, 0.2);
  border-style: solid;
  border-color: var(--brasshi);
  font-weight: 600;
}
.band-sheet-banner .btn-small { margin-left: 8px; }

@media print {
  .bandsheet-page {
    display: grid;
    gap: 0.15in;
    justify-content: start;
    page-break-after: always;
  }
  .bandsheet-page:last-child { page-break-after: auto; }
  .bandsheet-cell {
    position: relative;
    border: 1px dashed #999;
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
  }
  .bandsheet-cell img { width: 100%; height: 100%; object-fit: contain; }
  .bandsheet-missing { font-size: 8px; color: #999; text-align: center; }
  .bandsheet-po {
    position: absolute; bottom: 1px; right: 3px;
    font-size: 6px; color: #aaa; font-family: monospace;
  }

  .invoice-table {
    width: 100%;
    border-collapse: collapse;
    margin: 14px 0;
    font-size: 12px;
  }
  .invoice-table th, .invoice-table td {
    border-bottom: 1px solid #ccc;
    padding: 5px 8px;
    text-align: left;
  }
  .invoice-table th:last-child, .invoice-table td:last-child { text-align: right; }
  .invoice-table .inv-win { color: #A15A00; font-weight: 700; }
  .log-table thead { display: table-header-group; }
  .log-table { font-size: 10px; }
}

/* v8.12: coming-soon overlay */
.coming-soon {
  position: fixed;
  inset: 0;
  z-index: 9999;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 14px;
  padding: 32px;
  text-align: center;
  background: radial-gradient(circle at 50% 30%, #212932, var(--slate0) 70%);
}
.coming-soon.hidden { display: none; }
body.coming-soon-active { overflow: hidden; }
.coming-soon-logo { max-width: 360px; width: 80%; margin-bottom: 10px; }
.coming-soon h1 {
  font-family: "Rye", serif;
  color: var(--brasshi);
  font-size: 2rem;
  margin: 0;
}
.coming-soon p { color: var(--ink); max-width: 480px; margin: 0; }
.coming-soon-form {
  display: flex;
  gap: 8px;
  margin-top: 8px;
  flex-wrap: wrap;
  justify-content: center;
}
.coming-soon-form input {
  padding: 10px 14px;
  border-radius: 4px;
  border: 1px solid var(--slate2);
  background: #14191E;
  color: var(--inkhi);
  min-width: 240px;
  font-family: "IBM Plex Mono", monospace;
}
.coming-soon-form button {
  padding: 10px 18px;
  border-radius: 4px;
  border: none;
  background: var(--brass);
  color: #14191E;
  font-weight: 600;
  cursor: pointer;
}
.coming-soon-form button:hover { background: var(--brasshi); }
#comingSoonCount { color: var(--ink); font-size: 0.8rem; opacity: 0.7; }
.coming-soon-admin-link {
  margin-top: 24px;
  background: none;
  border: none;
  color: var(--ink);
  opacity: 0.4;
  font-size: 0.72rem;
  cursor: pointer;
  text-decoration: underline;
}
.coming-soon-admin-link:hover { opacity: 0.9; }

/* v8.14: three-folder band system */
.band-card-title-edit {
  width: 100%;
  background: transparent;
  border: 1px solid transparent;
  border-radius: 3px;
  font-family: "Rye", serif;
  font-size: 0.95rem;
  color: var(--brasshi);
  padding: 2px 4px;
}
.band-card-title-edit:hover { border-color: var(--slate2); }
.band-card-title-edit:focus { border-color: var(--brass); outline: none; background: #0F1418; }
.band-card-reserve { opacity: 0.72; border-style: dashed; }
.band-card-note { font-size: 0.7rem; color: var(--ink); opacity: 0.8; }
.tag-reserve { background: #2A3340; color: var(--ink); }
.folder-status { margin: 10px 0 18px 0; }
.folder-status-row {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1.6fr 0.8fr;
  gap: 10px;
  align-items: center;
  padding: 8px 12px;
  border: 1px solid var(--slate2);
  border-left: 3px solid var(--brass);
  border-radius: 4px;
  margin-bottom: 6px;
  font-size: 0.82rem;
  color: var(--ink);
  background: #14191E;
}
.folder-status-name { font-family: "Rye", serif; color: var(--brasshi); font-size: 0.9rem; }
.folder-status-warn { color: #E0A03A; font-weight: 600; }
.folder-status-ok { color: var(--ok); }
.folder-status-serial { border-left-color: var(--brasshi); }

/* v8.17: Certificate of Authentication - business card size, 2-up */
@media print {
  .cert-page {
    display: grid;
    grid-template-columns: 3.5in 3.5in;
    grid-auto-rows: 2in;
    gap: 0.25in;
    justify-content: center;
    page-break-after: always;
  }
  .cert-page:last-child { page-break-after: auto; }
  .cert {
    width: 3.5in;
    height: 2in;
    box-sizing: border-box;
    border: 1px dashed #999;
    padding: 0.12in 0.16in;
    color: #000;
    background: #fff;
    font-family: "Lora", Georgia, serif;
    display: flex;
    flex-direction: column;
    overflow: hidden;
  }
  .cert-head { text-align: center; }
  .cert-logo { max-height: 0.32in; max-width: 100%; object-fit: contain; }
  .cert-title {
    text-align: center;
    font-size: 8.5px;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: #7A4A1E;
    border-bottom: 1px solid #C8A87A;
    padding-bottom: 2px;
    margin-bottom: 3px;
  }
  .cert-band {
    max-height: 0.42in;
    max-width: 100%;
    object-fit: contain;
    align-self: center;
    margin-bottom: 3px;
  }
  .cert-table { width: 100%; border-collapse: collapse; font-size: 8px; }
  .cert-table td { padding: 1px 2px; vertical-align: top; }
  .cert-table td:first-child {
    color: #7A4A1E;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    width: 30%;
  }
  .cert-table td:last-child { text-align: right; font-weight: 600; }
  .cert-serial { font-size: 10px; }
  .cert-foot {
    margin-top: auto;
    text-align: center;
    font-size: 6.5px;
    font-style: italic;
    color: #555;
    border-top: 1px solid #C8A87A;
    padding-top: 2px;
  }
}

/* v8.18: customer reviews */
.cr-list { display: grid; gap: 12px; margin-bottom: 20px; }
.cr-card {
  background: #14191E;
  border: 1px solid var(--slate2);
  border-left: 3px solid var(--brass);
  border-radius: 4px;
  padding: 12px 16px;
}
.cr-card-head { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; margin-bottom: 4px; }
.cr-name { font-family: "Rye", serif; color: var(--brasshi); font-size: 0.9rem; }
.cr-wood { font-size: 0.72rem; color: var(--ink); opacity: 0.8; margin-bottom: 6px; }
.cr-text { color: var(--inkhi); font-size: 0.9rem; line-height: 1.5; }
.cr-date { font-size: 0.7rem; color: var(--ink); opacity: 0.6; margin-top: 6px; }
.star { color: #3A4450; font-size: 1rem; }
.star.on { color: var(--brasshi); }
.cr-avg { display: flex; align-items: center; gap: 10px; margin-bottom: 14px; }
.cr-avg .mono { color: var(--ink); font-size: 0.85rem; }
.cr-pending {
  margin-left: 10px; font-size: 0.72rem; color: #14191E;
  background: var(--brasshi); padding: 2px 8px; border-radius: 10px;
}
.cr-admin-text { max-width: 340px; font-size: 0.8rem; }

/* v8.19: condensed spec form */
.spec-form {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
  align-items: start;
  margin-bottom: 20px;
}
@media (max-width: 900px) { .spec-form { grid-template-columns: 1fr; } }
.spec-col { display: flex; flex-direction: column; gap: 14px; }
.spec-block {
  background: #14191E;
  border: 1px solid var(--slate2);
  border-radius: 4px;
  padding: 10px 12px;
}
.spec-label {
  font-family: "Rye", serif;
  font-size: 0.82rem;
  color: var(--brasshi);
  letter-spacing: 0.03em;
  margin-bottom: 8px;
}
.spec-label em { font-style: normal; font-size: 0.7rem; color: var(--ink); opacity: 0.8; }
.opt-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(96px, 1fr)); gap: 6px; }
.opt-grid-2 { grid-template-columns: repeat(2, 1fr); }
.opt-grid-3 { grid-template-columns: repeat(3, 1fr); }
.opt-tile {
  border: 1px solid var(--slate2);
  border-radius: 3px;
  padding: 6px 8px;
  cursor: pointer;
  background: #1A2128;
  transition: border-color 0.12s, background 0.12s;
}
.opt-tile:hover { border-color: var(--brass); }
.opt-tile.selected { border-color: var(--brasshi); background: #2A1B0E; }
.opt-tile.out { opacity: 0.35; cursor: not-allowed; }
.opt-name { font-size: 0.8rem; color: var(--inkhi); }
.opt-note { font-size: 0.66rem; color: var(--ink); opacity: 0.75; margin-top: 2px; line-height: 1.25; }
.opt-price { color: var(--brasshi); font-family: "IBM Plex Mono", monospace; font-size: 0.7rem; }
.opt-toggle {
  display: flex; align-items: center; gap: 8px;
  margin-top: 8px; font-size: 0.78rem; color: var(--ink); cursor: pointer;
}
.opt-toggle .mono { color: var(--brasshi); margin-left: auto; }
.spec-band .band-gallery-wrap { height: 400px; }
.spec-band .one-done-notice { font-size: 0.76rem; padding: 8px 10px; margin-bottom: 8px; }

/* Wood reference page */
.wood-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 16px; margin-bottom: 24px; }
.wood-card { background: #14191E; border: 1px solid var(--slate2); border-radius: 5px; overflow: hidden; }
.wood-card-img { width: 100%; height: 150px; background: #0F1418; display: flex; align-items: center; justify-content: center; border-bottom: 1px solid var(--slate2); }
.wood-card-img img { width: 100%; height: 100%; object-fit: cover; }
.wood-card-body { padding: 12px 14px; }
.wood-card-name { font-family: "Rye", serif; color: var(--brasshi); font-size: 1rem; }
.wood-card-latin { font-style: italic; font-size: 0.72rem; color: var(--ink); opacity: 0.75; margin-bottom: 6px; }
.wood-card-desc { font-size: 0.83rem; color: var(--inkhi); line-height: 1.5; margin-bottom: 8px; }
.wood-spec { font-size: 0.74rem; color: var(--ink); margin-bottom: 3px; }
.wood-spec strong { color: var(--brass); text-transform: uppercase; font-size: 0.66rem; letter-spacing: 0.04em; }
.supplier-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 10px; }
.supplier-card { background: #14191E; border: 1px solid var(--slate2); border-left: 3px solid var(--brass); border-radius: 4px; padding: 10px 12px; }
.supplier-card a { color: var(--brasshi); font-weight: 600; text-decoration: none; font-size: 0.88rem; }
.supplier-card a:hover { text-decoration: underline; }
.supplier-note { font-size: 0.72rem; color: var(--ink); margin-top: 3px; }
.wood-card-img.no-photo::after {
  content: "grain photo pending";
  color: var(--ink);
  opacity: 0.45;
  font-size: 0.72rem;
  font-family: "IBM Plex Mono", monospace;
}

/* v8.22: live site visibility banner */
.live-visibility {
  padding: 12px 16px;
  border-radius: 4px;
  margin-bottom: 12px;
  font-size: 0.86rem;
  line-height: 1.5;
  border: 1px solid var(--slate2);
}
.live-visibility.is-closed {
  background: rgba(217, 106, 43, 0.14);
  border-color: var(--brasshi);
  color: var(--inkhi);
}
.live-visibility.is-open {
  background: rgba(90, 160, 90, 0.12);
  border-color: #5AA05A;
  color: var(--inkhi);
}

/* v8.23: buyer list + coming-soon reviews */
.buyer-list { display: flex; flex-wrap: wrap; gap: 8px; margin: 10px 0 6px 0; }
.buyer-chip {
  display: inline-flex; align-items: center; gap: 6px;
  background: #14191E; border: 1px solid var(--slate2);
  border-radius: 14px; padding: 5px 10px;
  font-size: 0.82rem; color: var(--inkhi);
}
.buyer-chip.has-reviewed { border-color: var(--brass); }
.buyer-chip em { color: var(--brasshi); font-style: normal; font-size: 0.7rem; }
.buyer-chip button {
  background: none; border: none; color: var(--ink);
  cursor: pointer; font-size: 1rem; line-height: 1; padding: 0 2px; opacity: 0.5;
}
.buyer-chip button:hover { color: var(--danger); opacity: 1; }

.cs-reviews { width: 100%; max-width: 620px; margin-top: 10px; }
.cs-review-list { display: grid; gap: 8px; max-height: 220px; overflow-y: auto; text-align: left; }
.cs-review-list .cr-card { padding: 9px 12px; }
.cs-review-list .cr-text { font-size: 0.82rem; }
.cs-review-toggle {
  margin-top: 12px; background: none; border: 1px solid var(--slate2);
  border-radius: 4px; color: var(--ink); padding: 7px 14px;
  cursor: pointer; font-size: 0.8rem;
}
.cs-review-toggle:hover { border-color: var(--brass); color: var(--brasshi); }
.cs-review-form {
  display: flex; flex-direction: column; gap: 8px;
  margin-top: 10px; text-align: left;
}
.cs-review-form.hidden { display: none; }
.cs-review-note { font-size: 0.76rem; color: var(--ink); margin: 0; }
.cs-review-form input, .cs-review-form select, .cs-review-form textarea {
  padding: 8px 12px; border-radius: 4px; border: 1px solid var(--slate2);
  background: #14191E; color: var(--inkhi); font-family: inherit; font-size: 0.85rem;
}
