/* =========================================================
   PlayLearn SHOP — tokens
   Light "reading room" theme: paper white, ink navy, forest
   green carried over from the original brand, amber "catalog
   stamp" for prices. Cards read like library index cards
   inside a clean, modern checkout flow.
   ========================================================= */
:root {
  --bg: #f6f6f2;
  --bg-elevated: #ffffff;
  --bg-card: #ffffff;
  --bg-card-hover: #fbfaf6;
  --bg-sunken: #efeee7;
  --border: #e3e2d9;
  --border-soft: #ebeae2;

  --text: #14181a;
  --text-dim: #5c6461;
  --text-faint: #8b928e;

  --accent: #1f7a5c;
  --accent-strong: #145c44;
  --accent-soft: rgba(31, 122, 92, 0.1);
  --price: #b9832a;
  --price-soft: rgba(185, 131, 42, 0.12);
  --danger: #c1443a;
  --danger-soft: rgba(193, 68, 58, 0.1);

  --font-display: "Fraunces", "Iowan Old Style", Georgia, serif;
  --font-mono: "IBM Plex Mono", "SF Mono", Consolas, monospace;

  --radius-sm: 8px;
  --radius: 12px;
  --radius-lg: 20px;
  --max-width: 1180px;

  --shadow-sm: 0 1px 2px rgba(20, 24, 26, 0.05);
  --shadow-md: 0 10px 28px -14px rgba(20, 24, 26, 0.16);
  --shadow-lg: 0 30px 70px -30px rgba(20, 24, 26, 0.22);

  --dur: 200ms;
  --ease: cubic-bezier(0.4, 0, 0.2, 1);
}

@media (prefers-reduced-motion: reduce) {
  * {
    animation-duration: 0.001ms !important;
    transition-duration: 0.001ms !important;
  }
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-mono);
  font-size: 15px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

/* faint dot grid backdrop, replaces the old circuit-grid */
body::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: -1;
  background-image: radial-gradient(var(--border) 1px, transparent 1px);
  background-size: 26px 26px;
  mask-image: radial-gradient(ellipse 75% 55% at 50% 0%, black 0%, transparent 65%);
  opacity: 0.6;
}

a { color: inherit; }

::selection { background: var(--accent-soft); color: var(--accent-strong); }

:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}

.wrap {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 24px;
}

.eyebrow {
  font-size: 12px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--accent);
  font-weight: 600;
}

.em {
  font-family: var(--font-display);
  font-style: italic;
  font-weight: 500;
}

/* =========================================================
   HEADER
   ========================================================= */
.site-header {
  position: sticky;
  top: 0;
  z-index: 40;
  background: rgba(246, 246, 242, 0.88);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--border);
}

.site-header .wrap {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 68px;
  gap: 20px;
}

.brand {
  display: flex;
  align-items: baseline;
  gap: 8px;
  font-weight: 600;
  letter-spacing: 0.02em;
  text-decoration: none;
  white-space: nowrap;
  color: var(--text);
}
.brand .brand-main { font-size: 15px; }
.brand .brand-sub {
  font-family: var(--font-display);
  font-style: italic;
  color: var(--text-dim);
  font-size: 14px;
}

.main-site-link {
  font-size: 12px;
  color: var(--text-dim);
  text-decoration: none;
  border: 1px solid var(--border);
  padding: 7px 12px;
  border-radius: 999px;
  transition: border-color var(--dur) var(--ease), color var(--dur) var(--ease);
  white-space: nowrap;
  background: var(--bg-elevated);
}
.main-site-link:hover { border-color: var(--accent); color: var(--accent); }

.header-actions {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-left: auto;
}

@media (max-width: 560px) {
  .site-header .wrap { gap: 10px; padding: 0 16px; }
  .main-site-link { display: none; }
  .brand .brand-sub { display: none; }
  .account-link { padding: 8px 10px; font-size: 12px; }
  .cart-button { padding: 8px 12px; font-size: 12px; }
  .header-actions { gap: 6px; }
}

.account-link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  color: var(--text);
  font-family: var(--font-mono);
  font-size: 13px;
  padding: 8px 14px;
  border-radius: 999px;
  cursor: pointer;
  text-decoration: none;
  transition: border-color var(--dur) var(--ease), color var(--dur) var(--ease);
  white-space: nowrap;
}
.account-link:hover { border-color: var(--accent); color: var(--accent); }

.cart-button {
  position: relative;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: var(--text);
  border: 1px solid var(--text);
  color: var(--bg-elevated);
  font-family: var(--font-mono);
  font-weight: 600;
  font-size: 13px;
  padding: 8px 16px;
  border-radius: 999px;
  cursor: pointer;
  transition: background var(--dur) var(--ease), transform var(--dur) var(--ease);
}
.cart-button:hover { background: var(--accent-strong); border-color: var(--accent-strong); }
.cart-button:active { transform: scale(0.97); }
.cart-count {
  background: var(--price);
  color: #2a1c05;
  font-weight: 700;
  font-size: 11px;
  min-width: 18px;
  height: 18px;
  border-radius: 999px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0 5px;
}

/* =========================================================
   TERMINAL CARD
   reused on the product page ("stamped catalog record" look)
   ========================================================= */
.terminal {
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: var(--shadow-lg);
  position: relative;
}
.terminal-bar {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 14px 20px;
  border-bottom: 1px dashed var(--border);
  background: var(--bg-sunken);
}
.terminal-dot { width: 9px; height: 9px; border-radius: 50%; background: var(--border); }
.terminal-dot:nth-child(1) { background: var(--danger); opacity: 0.55; }
.terminal-dot:nth-child(2) { background: var(--price); opacity: 0.65; }
.terminal-dot:nth-child(3) { background: var(--accent); opacity: 0.7; }
.terminal-title {
  margin-left: 8px;
  font-size: 11px;
  letter-spacing: 0.04em;
  color: var(--text-faint);
}
.terminal-body {
  padding: 22px 20px 26px;
  font-size: 13px;
  min-height: 220px;
}
.terminal-line { color: var(--text-dim); margin: 0 0 6px; }
.terminal-line .prompt { color: var(--accent); }
.terminal-line .path { color: var(--text-faint); }
.terminal-output { color: var(--text); margin: 2px 0 12px; white-space: pre-wrap; }
.terminal-caret {
  display: inline-block;
  width: 7px;
  height: 14px;
  background: var(--accent);
  vertical-align: text-bottom;
  animation: blink 1s step-end infinite;
}
@keyframes blink { 50% { opacity: 0; } }

/* =========================================================
   CATEGORY TABS
   ========================================================= */
.category-bar {
  position: sticky;
  top: 68px;
  z-index: 30;
  background: rgba(246, 246, 242, 0.94);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--border);
}
.category-bar .wrap {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding-top: 14px;
  padding-bottom: 14px;
}
.chip-row {
  display: flex;
  gap: 8px;
  overflow-x: auto;
  flex: 1 1 auto;
  min-width: 0;
  min-height: 34px;
  scrollbar-width: none; /* Firefox */
  -ms-overflow-style: none; /* old Edge/IE */
}
.chip-row::-webkit-scrollbar {
  display: none; /* Chrome/Safari/new Edge */
}

.mode-toggle {
  flex: 0 0 auto;
  display: flex;
  gap: 3px;
  background: var(--bg-sunken);
  border: 1px solid var(--border);
  border-radius: 999px;
  padding: 3px;
}
.mode-btn {
  font-family: var(--font-mono);
  font-size: 12px;
  padding: 7px 15px;
  border-radius: 999px;
  border: none;
  background: transparent;
  color: var(--text-dim);
  cursor: pointer;
  transition: all var(--dur) var(--ease);
  white-space: nowrap;
}
.mode-btn:hover { color: var(--text); }
.mode-btn[aria-pressed="true"] {
  background: var(--accent);
  color: #fff;
  font-weight: 600;
}
@media (max-width: 620px) {
  .category-bar .wrap { flex-wrap: wrap; }
  .mode-toggle { order: -1; width: 100%; justify-content: center; }
  .chip-row { width: 100%; }
  .chip-row:empty {
    display: none; /* Free mode clears this — on mobile it wraps to its own row, so collapse it instead of leaving a blank strip below the toggle */
    min-height: 0;
  }
}
.chip {
  flex: 0 0 auto;
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  color: var(--text-dim);
  font-family: var(--font-mono);
  font-size: 12.5px;
  padding: 8px 15px;
  border-radius: 999px;
  cursor: pointer;
  transition: all var(--dur) var(--ease);
  white-space: nowrap;
}
.chip:hover { color: var(--text); border-color: var(--text-dim); }
.chip[aria-pressed="true"] {
  background: var(--accent);
  border-color: var(--accent);
  color: #fff;
  font-weight: 600;
}

/* =========================================================
   PRODUCT GRID
   ========================================================= */
.catalog { padding: 44px 0 80px; }

.catalog-heading {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  margin-bottom: 22px;
}
.catalog-heading h2 {
  font-family: var(--font-display);
  font-style: italic;
  font-weight: 500;
  font-size: 24px;
  margin: 0;
  color: var(--text);
}
.catalog-heading span { font-size: 12px; color: var(--text-faint); }

.product-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
}
@media (max-width: 960px) { .product-grid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 620px) { .product-grid { grid-template-columns: 1fr; } }

.card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 18px;
  display: flex;
  flex-direction: column;
  gap: 12px;
  box-shadow: var(--shadow-sm);
  transition: border-color var(--dur) var(--ease), transform var(--dur) var(--ease), box-shadow var(--dur) var(--ease);
}
.card:hover { border-color: var(--accent); box-shadow: var(--shadow-md); transform: translateY(-3px); }

.card-cover {
  height: 96px;
  border-radius: var(--radius);
  border: 1px dashed var(--border);
  background: var(--bg-sunken);
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  padding: 10px 12px;
  position: relative;
  overflow: hidden;
}
.card-cover::after {
  content: "";
  position: absolute;
  inset: 0;
  background: repeating-linear-gradient(135deg, var(--accent-soft) 0px, var(--accent-soft) 1px, transparent 1px, transparent 12px);
  pointer-events: none;
}
.card-cover .stamp {
  width: 30px;
  height: 30px;
  border-radius: 50%;
  border: 1.5px solid var(--accent);
  color: var(--accent);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  background: var(--bg-elevated);
  z-index: 1;
}
.card-cover .fmt {
  border: 1px solid var(--border);
  padding: 3px 8px;
  border-radius: 999px;
  color: var(--text-dim);
  background: var(--bg-elevated);
  font-size: 10px;
  z-index: 1;
  align-self: flex-start;
}

.card-tag {
  font-size: 10.5px;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--accent);
  font-weight: 600;
}

.card-cover-link { display: block; text-decoration: none; }

.card h3 {
  font-family: var(--font-display);
  font-weight: 500;
  font-size: 17px;
  line-height: 1.3;
  margin: 0;
  color: var(--text);
}
.card h3 a { text-decoration: none; color: inherit; }
.card h3 a:hover { color: var(--accent); }

.card p {
  font-size: 12.5px;
  color: var(--text-dim);
  margin: 0;
  flex-grow: 1;
}

.card-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-top: 4px;
  gap: 10px;
  padding-top: 12px;
  border-top: 1px dashed var(--border);
}

.price {
  font-family: var(--font-mono);
  font-weight: 700;
  color: var(--price);
  font-size: 16px;
}
.price::before { content: "₹"; font-size: 13px; margin-right: 1px; opacity: 0.85; }
.price.price-free { color: var(--accent); }
.price.price-free::before { content: ""; margin-right: 0; }

.card-buttons { display: flex; gap: 8px; }

.btn {
  font-family: var(--font-mono);
  font-size: 12.5px;
  border-radius: 999px;
  padding: 9px 14px;
  cursor: pointer;
  border: 1px solid var(--border);
  background: var(--bg-elevated);
  color: var(--text);
  transition: all var(--dur) var(--ease);
}
.btn:hover { border-color: var(--accent); color: var(--accent); }
.btn-primary {
  background: var(--accent);
  border-color: var(--accent);
  color: #fff;
  font-weight: 600;
}
.btn-primary:hover { background: var(--accent-strong); border-color: var(--accent-strong); color: #fff; }
.btn-block { width: 100%; justify-content: center; display: flex; }
#download-receipt-btn { margin-bottom: 10px; }
.btn[disabled] { opacity: 0.5; cursor: not-allowed; }

.empty-state {
  text-align: center;
  padding: 60px 20px;
  color: var(--text-faint);
  font-size: 13px;
}

/* =========================================================
   CART DRAWER
   ========================================================= */
.overlay {
  position: fixed;
  inset: 0;
  background: rgba(20, 24, 26, 0.35);
  opacity: 0;
  pointer-events: none;
  transition: opacity var(--dur) var(--ease);
  z-index: 49;
}
.overlay.is-open { opacity: 1; pointer-events: auto; }

.drawer {
  position: fixed;
  top: 0;
  right: 0;
  height: 100%;
  width: min(420px, 100%);
  background: var(--bg-elevated);
  border-left: 1px solid var(--border);
  z-index: 50;
  transform: translateX(100%);
  transition: transform var(--dur) var(--ease);
  display: flex;
  flex-direction: column;
  box-shadow: var(--shadow-lg);
}
.drawer.is-open { transform: translateX(0); }

.drawer-header {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 16px 18px;
  border-bottom: 1px solid var(--border);
  background: var(--bg-sunken);
}
.drawer-header .terminal-title { margin-left: 0; font-weight: 600; color: var(--text-dim); }
.drawer-close {
  margin-left: auto;
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  color: var(--text-dim);
  cursor: pointer;
  font-size: 13px;
  line-height: 1;
  padding: 6px 9px;
  border-radius: 999px;
}
.drawer-close:hover { color: var(--text); border-color: var(--text-dim); }

.drawer-log {
  flex: 1;
  overflow-y: auto;
  padding: 16px 18px;
  font-size: 12.5px;
}
.drawer-log .terminal-line { display: none; }

.cart-items { margin-top: 0; display: flex; flex-direction: column; gap: 10px; }

.cart-item {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 4px 10px;
  border: 1px solid var(--border-soft);
  border-radius: var(--radius);
  padding: 12px 14px;
  background: var(--bg-card);
}
.cart-item-title { font-size: 13px; color: var(--text); grid-column: 1 / 2; font-weight: 500; }
.cart-item-remove {
  grid-column: 2 / 3;
  background: none;
  border: none;
  color: var(--danger);
  font-size: 11px;
  cursor: pointer;
  justify-self: end;
}
.cart-item-meta {
  grid-column: 1 / -1;
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 12px;
  color: var(--text-faint);
}
.qty-control {
  display: inline-flex;
  align-items: center;
  border: 1px solid var(--border);
  border-radius: 999px;
  overflow: hidden;
  background: var(--bg-sunken);
}
.qty-control button {
  background: none;
  border: none;
  color: var(--text-dim);
  width: 24px;
  height: 24px;
  cursor: pointer;
  font-family: var(--font-mono);
}
.qty-control button:hover { color: var(--accent); }
.qty-control span { min-width: 20px; text-align: center; font-size: 12px; color: var(--text); }

.drawer-footer {
  border-top: 1px solid var(--border);
  padding: 16px 18px 20px;
  background: var(--bg-sunken);
}
.drawer-summary-row {
  display: flex;
  justify-content: space-between;
  font-size: 13px;
  margin-bottom: 4px;
  color: var(--text-dim);
}
.drawer-summary-row.total {
  color: var(--text);
  font-size: 16px;
  font-weight: 700;
  margin: 10px 0 14px;
}
.drawer-summary-row.total .price::before { font-size: 12px; }

/* =========================================================
   CHECKOUT MODAL
   ========================================================= */
.modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(20, 24, 26, 0.45);
  display: none;
  align-items: center;
  justify-content: center;
  padding: 20px;
  z-index: 60;
}
.modal-overlay.is-open { display: flex; }

.modal {
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  width: min(480px, 100%);
  max-height: 88vh;
  overflow-y: auto;
  box-shadow: var(--shadow-lg);
}

.modal-body { padding: 22px 24px 26px; }

.field { margin-bottom: 14px; }
.field label {
  display: block;
  font-size: 11.5px;
  color: var(--text-faint);
  margin-bottom: 6px;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}
.field input {
  width: 100%;
  background: var(--bg-sunken);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  color: var(--text);
  font-family: var(--font-mono);
  font-size: 13px;
  padding: 11px 13px;
}
.field input:focus { border-color: var(--accent); outline: none; background: var(--bg-elevated); }
.field input[readonly] { color: var(--text-dim); cursor: not-allowed; }
.field input[readonly]:focus { border-color: var(--border); background: var(--bg-sunken); }
.field select {
  width: 100%;
  background: var(--bg-sunken);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  color: var(--text);
  font-family: var(--font-mono);
  font-size: 13px;
  padding: 11px 13px;
}
.field select:focus { border-color: var(--accent); outline: none; background: var(--bg-elevated); }
.field select:disabled { color: var(--text-dim); cursor: not-allowed; }
.field-note { font-size: 11px; color: var(--text-faint); margin: -6px 0 16px; line-height: 1.5; }
.field textarea {
  width: 100%;
  background: var(--bg-sunken);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  color: var(--text);
  font-family: var(--font-mono);
  font-size: 13px;
  padding: 11px 13px;
  resize: vertical;
  min-height: 90px;
}
.field textarea:focus { border-color: var(--accent); outline: none; background: var(--bg-elevated); }

.order-summary {
  border: 1px solid var(--border-soft);
  border-radius: var(--radius);
  padding: 12px 14px;
  margin-bottom: 18px;
  font-size: 12.5px;
  color: var(--text-dim);
  background: var(--bg-sunken);
}
.order-summary .row { display: flex; justify-content: space-between; padding: 4px 0; }
.order-summary .row.total { color: var(--text); font-weight: 700; border-top: 1px dashed var(--border); margin-top: 6px; padding-top: 10px; }

.checkout-note {
  font-size: 11.5px;
  color: var(--text-faint);
  margin: 12px 0 0;
  line-height: 1.5;
}

.checkout-success {
  text-align: center;
  padding: 12px 4px 4px;
}
.checkout-success .ok-mark {
  color: var(--accent);
  font-size: 32px;
  font-family: var(--font-display);
  width: 56px;
  height: 56px;
  line-height: 56px;
  border-radius: 50%;
  background: var(--accent-soft);
  margin: 0 auto;
}
.checkout-success h3 { font-family: var(--font-display); font-style: italic; font-weight: 500; margin: 16px 0 6px; }
.checkout-success p { color: var(--text-dim); font-size: 13px; }

/* =========================================================
   TOAST
   ========================================================= */
.toast {
  position: fixed;
  left: 50%;
  bottom: 24px;
  transform: translate(-50%, 12px);
  background: var(--text);
  border: 1px solid var(--text);
  color: var(--bg-elevated);
  font-size: 12.5px;
  padding: 11px 18px;
  border-radius: 999px;
  opacity: 0;
  pointer-events: none;
  transition: all var(--dur) var(--ease);
  z-index: 70;
  box-shadow: var(--shadow-md);
}
.toast.is-visible { opacity: 1; transform: translate(-50%, 0); }
.toast .prompt { color: var(--accent-strong); margin-right: 6px; }

/* =========================================================
   FOOTER
   ========================================================= */
.site-footer {
  border-top: 1px solid var(--border);
  padding: 40px 0 32px;
}
.site-footer .wrap {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  align-items: center;
  justify-content: space-between;
}
.site-footer p { margin: 0; font-size: 12px; color: var(--text-faint); }
.footer-links { display: flex; gap: 16px; }
.footer-links a { font-size: 12px; color: var(--text-dim); text-decoration: none; }
.footer-links a:hover { color: var(--accent); }

/* =========================================================
   PRODUCT PAGE — breadcrumb
   ========================================================= */
.breadcrumb {
  padding: 18px 0 0;
  font-size: 12px;
  color: var(--text-faint);
}
.breadcrumb a { color: var(--text-dim); text-decoration: none; }
.breadcrumb a:hover { color: var(--accent); }

/* =========================================================
   PRODUCT PAGE — hero
   ========================================================= */
.product-hero { padding: 24px 0 56px; }
.product-hero-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 52px;
  align-items: start;
}
@media (max-width: 900px) {
  .product-hero-grid { grid-template-columns: 1fr; gap: 32px; }
}

/* gallery */
.gallery-main {
  aspect-ratio: 4 / 5;
  border-radius: var(--radius-lg);
  border: 1px solid var(--border);
  background: var(--bg-elevated);
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  position: relative;
  box-shadow: var(--shadow-md);
}
.book-mock {
  width: 62%;
  aspect-ratio: 3 / 4.3;
  background: linear-gradient(155deg, var(--accent-soft), var(--bg-sunken));
  border: 1px solid var(--border);
  border-radius: 6px;
  box-shadow: var(--shadow-lg);
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  padding: 22px 20px;
  transition: transform var(--dur) var(--ease);
}
.gallery-main:hover .book-mock { transform: translateY(-4px) rotate(-0.6deg); }
.book-mock .book-eyebrow {
  font-size: 10px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--accent);
  font-weight: 600;
}
.book-mock .book-title {
  font-family: var(--font-display);
  font-style: italic;
  font-size: 21px;
  line-height: 1.25;
  color: var(--text);
  margin: 10px 0 0;
}
.book-mock .book-glyph {
  align-self: flex-end;
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--text-faint);
  writing-mode: vertical-rl;
}
.book-mock .book-footer {
  font-family: var(--font-mono);
  font-size: 10px;
  color: var(--text-faint);
  letter-spacing: 0.08em;
}

.gallery-thumbs {
  display: flex;
  gap: 10px;
  margin-top: 12px;
}
.gallery-thumb {
  flex: 1;
  aspect-ratio: 1;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border);
  background: var(--bg-card);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-mono);
  font-size: 10px;
  color: var(--text-faint);
  transition: border-color var(--dur) var(--ease);
  padding: 0;
}
.gallery-thumb:hover { border-color: var(--text-dim); }
.gallery-thumb[aria-pressed="true"] { border-color: var(--accent); color: var(--accent); background: var(--accent-soft); }

/* info column */
.product-info .eyebrow { margin-bottom: 10px; }
.product-info h1 {
  font-family: var(--font-display);
  font-weight: 400;
  font-style: italic;
  font-size: clamp(28px, 4vw, 38px);
  line-height: 1.12;
  margin: 0 0 12px;
  color: var(--text);
}
.product-rating {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 12.5px;
  color: var(--text-dim);
  margin-bottom: 16px;
}
.product-rating .stars { color: var(--price); letter-spacing: 1px; }

.product-info .lede {
  color: var(--text-dim);
  font-size: 14.5px;
  max-width: 52ch;
  margin: 0 0 22px;
}

.product-price-row {
  display: flex;
  align-items: baseline;
  gap: 10px;
  margin-bottom: 22px;
}
.product-price-row .price { font-size: 28px; }
.product-price-row .format-tag {
  font-size: 11.5px;
  color: var(--text-dim);
  border: 1px solid var(--border);
  padding: 4px 10px;
  border-radius: 999px;
  background: var(--bg-elevated);
}

.purchase-row {
  display: flex;
  gap: 10px;
  margin-bottom: 26px;
  flex-wrap: wrap;
}
.qty-stepper {
  display: inline-flex;
  align-items: center;
  border: 1px solid var(--border);
  border-radius: 999px;
  overflow: hidden;
  background: var(--bg-elevated);
}
.qty-stepper button {
  background: none;
  border: none;
  color: var(--text-dim);
  width: 36px;
  height: 42px;
  font-family: var(--font-mono);
  font-size: 15px;
  cursor: pointer;
}
.qty-stepper button:hover { color: var(--accent); }
.qty-stepper span { min-width: 28px; text-align: center; font-size: 13px; color: var(--text); }

.purchase-row .btn { padding: 11px 20px; font-size: 13px; }
.purchase-row .add-btn { flex: 1; min-width: 140px; }
.purchase-row .buy-btn { flex: 1; min-width: 140px; }

.highlight-row {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 10px;
  margin-bottom: 8px;
}
@media (max-width: 480px) { .highlight-row { grid-template-columns: 1fr; } }
.highlight {
  border: 1px solid var(--border-soft);
  border-radius: var(--radius);
  padding: 12px 14px;
  font-size: 12px;
  color: var(--text-dim);
  display: flex;
  align-items: center;
  gap: 8px;
  background: var(--bg-elevated);
}
.highlight .dot { color: var(--accent); }

/* =========================================================
   PRODUCT PAGE — sections
   ========================================================= */
.product-section { padding: 46px 0; border-top: 1px solid var(--border); }
.product-section h2 {
  font-family: var(--font-display);
  font-style: italic;
  font-weight: 500;
  font-size: 22px;
  margin: 0 0 20px;
  color: var(--text);
}

/* what's inside — chapter list */
.chapter-list { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; }
.chapter-list li {
  display: flex;
  gap: 14px;
  padding: 14px 0;
  border-bottom: 1px dashed var(--border);
  font-size: 13.5px;
}
.chapter-list li:last-child { border-bottom: none; }
.chapter-num { font-family: var(--font-mono); color: var(--price); font-size: 12px; min-width: 24px; font-weight: 700; }
.chapter-title { color: var(--text); }
.chapter-desc { color: var(--text-faint); font-size: 12.5px; display: block; margin-top: 2px; }

/* sample excerpt */
.excerpt-block {
  background: var(--bg-sunken);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 22px 24px;
}
.excerpt-block p {
  font-size: 13.5px;
  color: var(--text-dim);
  line-height: 1.7;
  margin: 0 0 10px;
}
.excerpt-block p:last-child { margin-bottom: 0; }

/* related */
.related-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
}
@media (max-width: 860px) { .related-grid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 560px) { .related-grid { grid-template-columns: 1fr; } }

/* FAQ accordion */
.accordion { border-top: 1px solid var(--border-soft); }
.accordion-item { border-bottom: 1px solid var(--border-soft); }
.accordion-trigger {
  width: 100%;
  text-align: left;
  background: none;
  border: none;
  color: var(--text);
  font-family: var(--font-mono);
  font-size: 13.5px;
  padding: 16px 4px;
  cursor: pointer;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
}
.accordion-trigger .icon {
  color: var(--accent);
  transition: transform var(--dur) var(--ease);
  flex-shrink: 0;
}
.accordion-item[data-open="true"] .accordion-trigger .icon { transform: rotate(45deg); }
.accordion-panel {
  overflow: hidden;
  max-height: 0;
  transition: max-height var(--dur) var(--ease);
}
.accordion-item[data-open="true"] .accordion-panel { max-height: 200px; }
.accordion-panel p {
  font-size: 13px;
  color: var(--text-dim);
  margin: 0 0 16px;
  padding: 0 4px;
  line-height: 1.6;
}

/* sticky mobile buy bar */
.mobile-buy-bar {
  display: none;
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 45;
  background: var(--bg-elevated);
  border-top: 1px solid var(--border);
  padding: 12px 16px;
  align-items: center;
  gap: 10px;
  box-shadow: 0 -8px 24px -12px rgba(20, 24, 26, 0.15);
}
.mobile-buy-bar .price { font-size: 16px; margin-right: auto; }
@media (max-width: 720px) {
  .mobile-buy-bar { display: flex; }
  .product-hero { padding-bottom: 90px; }
}

/* =========================================================
   LOGIN / ACCOUNT PAGE
   ========================================================= */
.auth-main {
  min-height: calc(100vh - 68px);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 48px 20px;
}
.auth-grid {
  max-width: 440px;
  width: 100%;
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-lg);
  overflow: hidden;
}

.auth-form-side { padding: 40px 36px; }
@media (max-width: 480px) {
  .auth-form-side { padding: 32px 24px; }
}
.auth-grid.is-wide { max-width: 560px; }
.auth-tabs {
  display: inline-flex;
  border: 1px solid var(--border);
  border-radius: 999px;
  padding: 3px;
  margin-bottom: 28px;
  background: var(--bg-sunken);
}
.auth-tab {
  border: none;
  background: none;
  font-family: var(--font-mono);
  font-size: 12.5px;
  padding: 8px 18px;
  border-radius: 999px;
  cursor: pointer;
  color: var(--text-dim);
}
.auth-tab[aria-selected="true"] {
  background: var(--bg-elevated);
  color: var(--text);
  font-weight: 600;
  box-shadow: var(--shadow-sm);
}
.auth-form-side h1 {
  font-family: var(--font-display);
  font-style: italic;
  font-weight: 500;
  font-size: 26px;
  margin: 0 0 8px;
}
.auth-form-side .sub { color: var(--text-dim); font-size: 13px; margin: 0 0 26px; }
.auth-form { display: none; }
.auth-form.is-active { display: block; }
.auth-divider {
  display: flex;
  align-items: center;
  gap: 12px;
  margin: 18px 0;
  color: var(--text-faint);
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}
.auth-divider::before, .auth-divider::after {
  content: "";
  flex: 1;
  height: 1px;
  background: var(--border);
}
.auth-guest-link {
  display: block;
  text-align: center;
  font-size: 12.5px;
  color: var(--text-dim);
  text-decoration: none;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 11px;
}
.auth-guest-link:hover { border-color: var(--accent); color: var(--accent); }
.btn-google {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  width: 100%;
  font-family: var(--font-mono);
  font-size: 12.5px;
  font-weight: 600;
  border-radius: 999px;
  padding: 10px 14px;
  cursor: pointer;
  border: 1px solid var(--border);
  background: #fff;
  color: #3c4043;
  transition: all var(--dur) var(--ease);
}
.btn-google:hover { border-color: var(--text-dim); box-shadow: var(--shadow-sm); }
.btn-google[disabled] { opacity: 0.5; cursor: not-allowed; }
.btn-google svg { width: 18px; height: 18px; flex-shrink: 0; }
.auth-form-foot { margin-top: 20px; font-size: 12px; color: var(--text-faint); text-align: center; }
.auth-form-foot button { background: none; border: none; color: var(--accent); font-family: var(--font-mono); font-size: 12px; cursor: pointer; padding: 0; text-decoration: underline; }

/* =========================================================
   PROFILE PAGE
   ========================================================= */
.profile-header {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-bottom: 30px;
}
.profile-avatar {
  width: 52px;
  height: 52px;
  border-radius: 50%;
  background: var(--accent-soft);
  color: var(--accent-strong);
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-display);
  font-style: italic;
  font-weight: 500;
  font-size: 22px;
  flex-shrink: 0;
}
.profile-header h1 {
  font-family: var(--font-display);
  font-style: italic;
  font-weight: 500;
  font-size: 22px;
  margin: 0 0 2px;
}
.profile-header .sub { margin: 0; font-size: 12.5px; color: var(--text-dim); }

.profile-rows {
  border-top: 1px solid var(--border-soft);
  margin-bottom: 28px;
}
.profile-row {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  padding: 14px 2px;
  border-bottom: 1px solid var(--border-soft);
  font-size: 13.5px;
}
.profile-row-label { color: var(--text-faint); }
.profile-row-value { color: var(--text); text-align: right; word-break: break-word; }

.btn-danger-outline {
  border-color: var(--danger-soft);
  color: var(--danger);
}
.btn-danger-outline:hover { border-color: var(--danger); color: var(--danger); background: var(--danger-soft); }

.profile-guest {
  text-align: center;
  padding: 10px 0 4px;
}
.profile-guest p { color: var(--text-dim); font-size: 13px; margin: 0 0 18px; }

/* collapsible sections on profile.html (personal info, security,
   order details, raise a query, your queries) — same visual language
   as the FAQ accordion on product.html, built on native <details> */
.profile-accordion { border-top: 1px solid var(--border-soft); margin-top: 26px; }
.profile-accordion-item { border-bottom: 1px solid var(--border-soft); }
.profile-accordion-item summary { list-style: none; cursor: pointer; }
.profile-accordion-item summary::-webkit-details-marker { display: none; }
.profile-accordion-trigger {
  width: 100%;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  padding: 16px 4px;
  color: var(--text);
  font-family: var(--font-display);
  font-style: italic;
  font-weight: 500;
  font-size: 16px;
}
.profile-accordion-trigger .icon {
  color: var(--accent);
  transition: transform var(--dur) var(--ease);
  flex-shrink: 0;
  font-family: var(--font-mono);
  font-style: normal;
}
.profile-accordion-item[open] .profile-accordion-trigger .icon { transform: rotate(45deg); }
.profile-accordion-panel { padding: 0 4px 22px; }
.profile-accordion-panel form { margin: 0; }

/* purchases list, on profile.html */
.purchase-list { display: flex; flex-direction: column; gap: 10px; margin-bottom: 8px; }
.purchase-item {
  border: 1px solid var(--border-soft);
  border-radius: var(--radius);
  padding: 14px 16px;
  background: var(--bg-elevated);
}
.purchase-item-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 10px;
  margin-bottom: 8px;
}
.purchase-id { font-size: 11px; color: var(--text-faint); }
.purchase-status {
  font-size: 10px;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  font-weight: 700;
  padding: 3px 9px;
  border-radius: 999px;
  flex-shrink: 0;
}
.purchase-status.status-successful { background: var(--accent-soft); color: var(--accent-strong); }
.purchase-item-items { font-size: 13px; color: var(--text-dim); margin-bottom: 10px; line-height: 1.5; }
.purchase-item-line { margin-bottom: 4px; }
.purchase-item-line:last-child { margin-bottom: 0; }
.purchase-item-foot { display: flex; justify-content: space-between; align-items: center; font-size: 12px; color: var(--text-faint); }
.purchase-item-foot .price { font-size: 14px; color: var(--text); }
.purchase-empty { font-size: 13px; color: var(--text-faint); }
.purchase-loading { font-size: 12.5px; color: var(--text-faint); }

.download-link { color: var(--accent); text-decoration: underline; cursor: pointer; }
.download-link:hover { color: var(--accent-strong); }
.btn-small { padding: 6px 13px; font-size: 11.5px; }

/* queries list, on profile.html */
.query-list { display: flex; flex-direction: column; gap: 10px; margin-bottom: 8px; }
.query-item {
  border: 1px solid var(--border-soft);
  border-radius: var(--radius);
  padding: 14px 16px;
  background: var(--bg-elevated);
}
.query-item > summary.query-item-head { list-style: none; cursor: pointer; }
.query-item > summary.query-item-head::-webkit-details-marker { display: none; }
.query-item-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 10px;
}
.query-item-head-right { display: flex; align-items: center; gap: 10px; }
.query-item-icon {
  color: var(--accent);
  transition: transform var(--dur) var(--ease);
  flex-shrink: 0;
  font-family: var(--font-mono);
  font-style: normal;
  font-size: 14px;
}
.query-item[open] .query-item-icon { transform: rotate(45deg); }
.query-item-panel { padding-top: 12px; }
.query-date { font-size: 11px; color: var(--text-faint); }
.query-status {
  font-size: 10px;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  font-weight: 700;
  padding: 3px 9px;
  border-radius: 999px;
  flex-shrink: 0;
}
.query-status.status-open { background: var(--price-soft); color: var(--price); }
.query-status.status-replied,
.query-status.status-closed { background: var(--accent-soft); color: var(--accent-strong); }

/* threaded messages inside a query — used on both profile.html
   (shopper's own thread) and admin.html (support queue), so a
   query can carry any number of back-and-forth messages until an
   admin marks it closed */
.query-thread { display: flex; flex-direction: column; gap: 8px; margin-bottom: 12px; }
.query-thread-msg {
  border-radius: var(--radius-sm);
  padding: 8px 12px;
  font-size: 13px;
  line-height: 1.5;
  white-space: pre-wrap;
  max-width: 90%;
}
.query-thread-msg .msg-meta {
  display: block;
  font-size: 10px;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin-bottom: 3px;
  opacity: 0.7;
}
.query-thread-msg.sender-user { background: var(--bg-sunken); color: var(--text); align-self: flex-start; }
.query-thread-msg.sender-admin { background: var(--accent-soft); color: var(--accent-strong); align-self: flex-end; text-align: right; }

/* follow-up reply box under an open query, on profile.html — only
   rendered while the query is still open */
.query-reply-form {
  display: flex;
  gap: 8px;
  border-top: 1px solid var(--border-soft);
  padding-top: 10px;
}
.query-reply-form textarea {
  flex: 1;
  background: var(--bg-sunken);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  color: var(--text);
  font-family: var(--font-mono);
  font-size: 12.5px;
  padding: 8px 10px;
  resize: vertical;
  min-height: 38px;
}
.query-reply-form textarea:focus { border-color: var(--accent); outline: none; background: var(--bg-elevated); }
.query-reply-form button { flex-shrink: 0; align-self: flex-end; }

/* =========================================================
   ADMIN / EXECUTIVE PANELS
   (executive.html mirrors admin.html's markup one-for-one with an
   "executive-" class prefix instead of "admin-" — every rule below
   targets both so the two pages share one visual language)
   ========================================================= */
.admin-main, .executive-main { padding: 40px 0 80px; }
.admin-section, .executive-section { margin-bottom: 46px; }
.admin-section h2, .executive-section h2 {
  font-family: var(--font-display);
  font-style: italic;
  font-weight: 500;
  font-size: 22px;
  margin: 0 0 6px;
  color: var(--text);
}
.admin-hint, .executive-hint { font-size: 12.5px; color: var(--text-dim); margin: 0 0 18px; max-width: 62ch; }
.admin-hint code, .executive-hint code {
  font-family: var(--font-mono);
  background: var(--bg-sunken);
  border: 1px solid var(--border-soft);
  border-radius: 4px;
  padding: 1px 5px;
  font-size: 11.5px;
  color: var(--text);
}

.admin-stats, .executive-stats {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 14px;
  margin-bottom: 22px;
}
@media (max-width: 620px) { .admin-stats, .executive-stats { grid-template-columns: 1fr; } }
.admin-stat, .executive-stat {
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 16px 18px;
  display: flex;
  flex-direction: column;
  gap: 6px;
  box-shadow: var(--shadow-sm);
}
.admin-stat-label, .executive-stat-label { font-size: 11px; text-transform: uppercase; letter-spacing: 0.06em; color: var(--text-faint); }
.admin-stat-value, .executive-stat-value { font-family: var(--font-mono); font-weight: 700; font-size: 22px; color: var(--text); }

.admin-table-wrap, .executive-table-wrap {
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  background: var(--bg-elevated);
  box-shadow: var(--shadow-sm);
}
.admin-table, .executive-table { width: 100%; border-collapse: collapse; font-size: 13px; }
.admin-table th, .admin-table td, .executive-table th, .executive-table td { text-align: left; padding: 11px 14px; border-bottom: 1px solid var(--border-soft); vertical-align: middle; }
.admin-table th, .executive-table th { font-size: 10.5px; text-transform: uppercase; letter-spacing: 0.05em; color: var(--text-faint); background: var(--bg-sunken); }
.admin-table tbody tr:last-child td, .executive-table tbody tr:last-child td { border-bottom: none; }
.admin-mono, .executive-mono { font-family: var(--font-mono); color: var(--text-dim); font-size: 12px; }
.admin-empty, .executive-empty { text-align: center; color: var(--text-faint); padding: 34px 14px; }
.admin-table td:last-child, .executive-table td:last-child { white-space: nowrap; }

.admin-link-form, .executive-link-form {
  display: flex;
  gap: 14px;
  align-items: flex-end;
  flex-wrap: wrap;
  margin-bottom: 20px;
}
.admin-link-form .field, .executive-link-form .field { margin-bottom: 0; flex: 1 1 220px; min-width: 200px; }
.admin-link-form button[type="submit"], .executive-link-form button[type="submit"] { flex: 0 0 auto; padding: 11px 22px; }

.admin-link-url-cell, .executive-link-url-cell { max-width: 340px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.admin-link-url-cell a, .executive-link-url-cell a { color: var(--accent); text-decoration: none; }
.admin-link-url-cell a:hover, .executive-link-url-cell a:hover { text-decoration: underline; }
.admin-table td .btn-small + .btn-small, .executive-table td .btn-small + .btn-small { margin-left: 6px; }

/* inline-editable fields inside admin/executive tables — Customers,
   Executives, Executive Verification sections */
.admin-table input[type="text"],
.admin-table input[type="email"],
.admin-table input[type="tel"],
.executive-table input[type="text"],
.executive-table input[type="email"],
.executive-table input[type="tel"] {
  width: 100%;
  min-width: 130px;
  background: var(--bg-sunken);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  color: var(--text);
  font-family: var(--font-mono);
  font-size: 12.5px;
  padding: 7px 10px;
}
.admin-table input[type="text"]:focus,
.admin-table input[type="email"]:focus,
.admin-table input[type="tel"]:focus,
.executive-table input[type="text"]:focus,
.executive-table input[type="email"]:focus,
.executive-table input[type="tel"]:focus { border-color: var(--accent); outline: none; background: var(--bg-elevated); }

/* Sales — single-day filter, on admin.html */
.admin-date-filter, .executive-date-filter {
  display: flex;
  align-items: center;
  gap: 10px;
  margin: 4px 0 18px;
}
.admin-date-filter label, .executive-date-filter label {
  font-size: 11.5px;
  color: var(--text-faint);
  text-transform: uppercase;
  letter-spacing: 0.04em;
}
.admin-date-filter input[type="date"], .executive-date-filter input[type="date"] {
  background: var(--bg-sunken);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  color: var(--text);
  font-family: var(--font-mono);
  font-size: 13px;
  padding: 8px 11px;
}
.admin-date-filter input[type="date"]:focus, .executive-date-filter input[type="date"]:focus { border-color: var(--accent); outline: none; background: var(--bg-elevated); }

/* Support queries, on admin.html / executive.html */
.admin-query-list, .executive-query-list { display: flex; flex-direction: column; gap: 12px; }
.admin-query-item, .executive-query-item {
  border: 1px solid var(--border-soft);
  border-radius: var(--radius);
  padding: 14px 16px;
  background: var(--bg-elevated);
}
.admin-query-head, .executive-query-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 10px;
  margin-bottom: 8px;
}
.admin-query-reply-field, .executive-query-reply-field { margin: 10px 0 12px; }
.admin-query-reply-field label, .executive-query-reply-field label {
  display: block;
  font-size: 11px;
  color: var(--text-faint);
  margin-bottom: 6px;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}
.admin-query-reply-input, .executive-query-reply-input {
  width: 100%;
  background: var(--bg-sunken);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  color: var(--text);
  font-family: var(--font-mono);
  font-size: 13px;
  padding: 10px 12px;
  resize: vertical;
}
.admin-query-reply-input:focus, .executive-query-reply-input:focus { border-color: var(--accent); outline: none; background: var(--bg-elevated); }
.admin-query-actions, .executive-query-actions { display: flex; gap: 8px; }

.admin-topbar, .executive-topbar {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 12px;
  margin-bottom: 28px;
  flex-wrap: wrap;
}
.admin-welcome, .executive-welcome { font-size: 12px; color: var(--text-faint); margin-right: auto; }

/* Change-password mini panel — toggled open from the executive
   topbar's "change password" button */
.pw-panel {
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow-sm);
  padding: 18px 20px;
  max-width: 360px;
  margin: 0 0 28px auto;
}
.pw-panel .field { margin-bottom: 12px; }
.pw-panel .field:last-of-type { margin-bottom: 16px; }
.pw-panel-actions { display: flex; gap: 8px; }

/* expandable admin/executive sections (Product links, Customers,
   Support queries, Executive Verification, Executives) — same look
   as before, just wrapped in <details> so each one can be collapsed.
   Sales stays a plain, always-open section on admin.html. */
.admin-section.is-collapsible, .executive-section.is-collapsible { margin-bottom: 46px; }
.admin-section.is-collapsible > summary, .executive-section.is-collapsible > summary {
  list-style: none;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding-bottom: 6px;
}
.admin-section.is-collapsible > summary::-webkit-details-marker,
.executive-section.is-collapsible > summary::-webkit-details-marker { display: none; }
.admin-section.is-collapsible > summary h2, .executive-section.is-collapsible > summary h2 { margin: 0; }
.admin-section.is-collapsible > summary .icon, .executive-section.is-collapsible > summary .icon {
  color: var(--accent);
  transition: transform var(--dur) var(--ease);
  flex-shrink: 0;
  font-family: var(--font-mono);
  font-style: normal;
  font-size: 20px;
  line-height: 1;
}
.admin-section.is-collapsible[open] > summary .icon, .executive-section.is-collapsible[open] > summary .icon { transform: rotate(45deg); }

@media (max-width: 760px) {
  .admin-table-wrap, .executive-table-wrap { overflow-x: auto; }
  .admin-table, .executive-table { min-width: 560px; }
}

/* =========================================================
   DASHBOARD (index.html) — "your study material"
   ========================================================= */
.dashboard-main { padding: 44px 0 80px; }
.dashboard-heading h2 { margin: 0 0 4px; }
.dashboard-intro { color: var(--text-dim); font-size: 13px; margin: 0 0 30px; max-width: 62ch; }

/* E-classroom hero — shown only once the shopper's semester Full
   Course is purchased; links out to /classroom/semesterN.html. */
.dashboard-hero {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  margin-bottom: 26px;
  padding: 26px 28px;
  background: var(--accent);
  background-image: repeating-linear-gradient(135deg, rgba(255, 255, 255, 0.06) 0px, rgba(255, 255, 255, 0.06) 1px, transparent 1px, transparent 14px);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-md);
  text-decoration: none;
  color: #fff;
  transition: transform var(--dur) var(--ease), box-shadow var(--dur) var(--ease);
}
.dashboard-hero:hover { transform: translateY(-2px); box-shadow: var(--shadow-lg); }
.dashboard-hero-text { min-width: 0; }
.dashboard-hero-eyebrow {
  display: block;
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.75);
  margin-bottom: 6px;
}
.dashboard-hero-text h3 {
  font-family: var(--font-display);
  font-style: italic;
  font-weight: 500;
  font-size: 22px;
  margin: 0 0 6px;
  color: #fff;
}
.dashboard-hero-text p {
  margin: 0;
  font-size: 13px;
  color: rgba(255, 255, 255, 0.85);
  max-width: 46ch;
}
.dashboard-hero-cta {
  flex-shrink: 0;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 11px 20px;
  border-radius: 999px;
  background: #fff;
  color: var(--accent-strong);
  font-family: var(--font-mono);
  font-size: 12.5px;
  font-weight: 600;
  white-space: nowrap;
}
.dashboard-hero-cta .arrow { transition: transform var(--dur) var(--ease); }
.dashboard-hero:hover .dashboard-hero-cta .arrow { transform: translateX(3px); }

/* Free Batch variant — shown instead of the paid (green) banner when
   a shopper only has the free batch unlocked for their semester. */
.dashboard-hero.is-free {
  background: var(--price);
}
.dashboard-hero.is-free .dashboard-hero-cta { color: var(--price); }

@media (max-width: 620px) {
  .dashboard-hero { flex-direction: column; align-items: flex-start; }
  .dashboard-hero-cta { align-self: stretch; justify-content: center; }
}

/* Each semester is its own "subject" tile/card... */
.dashboard-suggestions-heading {
  font-family: var(--font-mono);
  font-size: 12px;
  color: var(--text-dim);
  margin: 18px 0 14px;
  text-align: center;
}
.dashboard-suggestions-grid {
  grid-template-columns: repeat(2, 1fr);
  max-width: 640px;
  margin: 0 auto;
  text-align: left;
}
@media (max-width: 620px) { .dashboard-suggestions-grid { grid-template-columns: 1fr; } }

.dashboard-semester {
  margin-bottom: 22px;
  padding: 22px 22px 24px;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-sm);
}
.dashboard-semester-title {
  font-family: var(--font-display);
  font-style: italic;
  font-weight: 500;
  font-size: 20px;
  margin: 0 0 16px;
  color: var(--text);
}

/* Inside a semester, one expandable row per subject — click to reveal
   its Notes / PYQ / eBooks tiles. Built on native <details>, same
   pattern as .profile-accordion / the FAQ accordion. */
.dashboard-subject-list {
  border-top: 1px solid var(--border-soft);
}
.dashboard-subject {
  border-bottom: 1px solid var(--border-soft);
}
.dashboard-subject > summary { list-style: none; cursor: pointer; }
.dashboard-subject > summary::-webkit-details-marker { display: none; }
.dashboard-subject-trigger {
  width: 100%;
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 12px;
  padding: 14px 4px;
}
.dashboard-subject-label {
  display: flex;
  align-items: baseline;
  gap: 10px;
  flex-wrap: wrap;
  min-width: 0;
}
.dashboard-subject-trigger .icon {
  color: var(--accent);
  transition: transform var(--dur) var(--ease);
  flex-shrink: 0;
  font-family: var(--font-mono);
  font-style: normal;
}
.dashboard-subject[open] .dashboard-subject-trigger .icon { transform: rotate(45deg); }
.dashboard-subject-panel { padding: 0 4px 20px; }

.subject-code {
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 700;
  color: var(--accent);
  letter-spacing: 0.03em;
  flex-shrink: 0;
}
.subject-name {
  font-size: 12.5px;
  color: var(--text-dim);
}

/* ...each subject's expanded panel containing 3 sub-tiles: Notes / PYQ / eBooks. */
.material-tile-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 14px;
}
@media (max-width: 640px) {
  .material-tile-grid { grid-template-columns: 1fr; }
}

.material-tile {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
  text-align: center;
  padding: 20px 14px;
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  transition: border-color var(--dur) var(--ease);
}
.material-tile:not(.is-locked):hover { border-color: var(--accent); }
.material-tile.is-locked { background: var(--bg-sunken); }

.material-tag {
  font-family: var(--font-mono);
  font-size: 10.5px;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  font-weight: 700;
  color: var(--accent);
  background: var(--accent-soft);
  border-radius: 999px;
  padding: 4px 12px;
}
.material-tile.is-locked .material-tag { color: var(--text-faint); background: var(--border-soft); }

.material-name { color: var(--text-dim); font-size: 12px; line-height: 1.4; min-height: 32px; }

.material-tile .btn { width: 100%; justify-content: center; margin-top: auto; }
