@import url('https://fonts.googleapis.com/css2?family=Cormorant+Garamond:ital,wght@0,400;0,500;0,600;0,700;1,400;1,500&family=DM+Sans:wght@300;400;500;600&family=DM+Mono:wght@400;500&family=Inter:wght@400;500;600;700&display=swap');

/* ─── Design Tokens ─────────────────────────────────────────────────── */
:root {
  --obsidian:       #111318;
  --obsidian-mid:   #181c28;
  --obsidian-light: #20253a;
  --obsidian-border:#2e3450;
  --obsidian-hover: #1f2333;

  --gold-deep:   #a8762a;
  --gold:        #c9963c;
  --gold-bright: #e8b554;
  --gold-pale:   #f5d98a;
  --gold-glow:   rgba(201, 150, 60, 0.18);
  --gold-border: rgba(201, 150, 60, 0.35);

  --pearl:       #f0ece4;
  --pearl-dim:   #ccc5b5;
  --pearl-muted: #8e8880;

  --ruby:        #c0392b;
  --ruby-bright: #e74c3c;
  --ruby-glow:   rgba(192, 57, 43, 0.2);
  --ruby-bg:     rgba(192, 57, 43, 0.12);

  --emerald:     #1a6b4a;
  --emerald-bg:  rgba(26, 107, 74, 0.15);

  --sapphire:    #1a4a8a;
  --sapphire-bg: rgba(26, 74, 138, 0.15);

  --shadow-deep: 0 24px 64px rgba(0, 0, 0, 0.7);
  --shadow-card: 0 8px 32px rgba(0, 0, 0, 0.5);
  --shadow-gold: 0 0 32px rgba(201, 150, 60, 0.15);

  --radius:    8px;
  --radius-lg: 14px;

  /* Fixed .site-footer: must be ≥ real bar height or fixed pages overlap the bar */
  --site-footer-safe: 2.5rem;
}

/* ─── Reset & Base ──────────────────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

body {
  font-family: 'DM Sans', sans-serif;
  background: #181c26;
  color: var(--pearl);
  min-height: 100vh;
  padding-bottom: var(--site-footer-safe);
  -webkit-font-smoothing: antialiased;
  background-image:
    radial-gradient(ellipse 80% 50% at 50% -10%, rgba(201,150,60,0.07) 0%, transparent 60%),
    repeating-linear-gradient(
      0deg,
      transparent,
      transparent 79px,
      rgba(255,255,255,0.015) 79px,
      rgba(255,255,255,0.015) 80px
    );
}

/* Bid / confirmations / client list: .bid-page already uses calc(100vh - footer); drop body padding or it doubles the gap */
body:has(.bid-page),
body.bid-page {
  padding-bottom: 0;
}

/*
 * body { min-height: 100vh } would otherwise force these shells to full viewport height.
 * Flex/grid children then extend under the fixed .site-footer (overlap).
 */
body.bid-page {
  min-height: calc(100vh - var(--site-footer-safe));
  min-height: calc(100dvh - var(--site-footer-safe));
  max-height: calc(100vh - var(--site-footer-safe));
  max-height: calc(100dvh - var(--site-footer-safe));
}

/* Full-viewport admin shells subtract the footer in their own height; no extra body padding */
body.admin-dashboard-page,
body.admin-email-templates-page,
body.admin-client-usage-page {
  padding-bottom: 0;
}

/* ─── Global site footer (all pages) ───────────────────────────────── */
.site-footer {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  z-index: 100;
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.5rem 1rem;
  padding: 0.65rem 1.25rem;
  font-size: 0.8125rem;
  font-family: 'Inter', 'DM Sans', sans-serif;
  color: #b8bcc8;
  background: #1e2228;
  border-top: 1px solid rgba(255, 255, 255, 0.12);
}

.site-footer__sep {
  margin: 0 0.35rem;
  opacity: 0.55;
}

.site-footer__link {
  color: #d4d8e0;
  text-decoration: none;
}

.site-footer__link:hover {
  color: var(--gold-bright);
  text-decoration: underline;
}

@media (max-width: 520px) {
  :root {
    --site-footer-safe: 4.75rem;
  }

  .site-footer {
    flex-direction: column;
    align-items: flex-start;
    text-align: left;
  }
}

/* ─── Container ─────────────────────────────────────────────────────── */
.container {
  max-width: 1100px;
  margin: 2.5rem auto;
  padding: 0;
  background: var(--obsidian-mid);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-deep), var(--shadow-gold);
  border: 1px solid var(--obsidian-border);
  overflow: hidden;
}

/* ─── Top Bar ───────────────────────────────────────────────────────── */
.top-bar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 1.5rem 2rem;
  background: #14172080;
  border-bottom: 1px solid var(--gold-border);
  position: relative;
  overflow: hidden;
}
.top-bar::before {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, rgba(201,150,60,0.06) 0%, transparent 60%);
  pointer-events: none;
}
.top-bar::after {
  content: '';
  position: absolute;
  bottom: 0; left: 0; right: 0;
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--gold), transparent);
}

.top-bar-left { display: flex; flex-direction: column; gap: 0.2rem; }

.brand {
  font-family: 'Cormorant Garamond', serif;
  font-weight: 600;
  font-size: 1.9rem;
  letter-spacing: 0.12em;
  color: var(--gold-bright);
  text-transform: uppercase;
}
.brand-sub {
  font-size: 0.78rem;
  font-weight: 500;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--pearl-dim);
}

.top-bar-right .client-block {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 0.3rem;
}
.client-name {
  font-family: 'Cormorant Garamond', serif;
  font-size: 1.15rem;
  font-weight: 600;
  color: var(--pearl);
  letter-spacing: 0.02em;
}
.client-id-line {
  font-size: 0.72rem;
  font-weight: 500;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--gold);
  padding: 0.2rem 0.6rem;
  border: 1px solid var(--gold-border);
  border-radius: 4px;
  background: var(--gold-glow);
}

/* ─── Auction Summary ────────────────────────────────────────────────── */
.auction-summary {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  padding: 1rem 2rem;
  background: linear-gradient(135deg, #1e2336 0%, #181c2e 100%);
  border-bottom: 1px solid var(--obsidian-border);
  gap: 1.5rem;
}

.auction-name {
  font-family: 'Cormorant Garamond', serif;
  font-size: 1.25rem;
  font-weight: 600;
  font-style: italic;
  color: var(--gold-pale);
  letter-spacing: 0.03em;
  margin-bottom: 0.5rem;
}

.auction-deadline.tender-closing-lines { margin-top: 0.1rem; }

.tender-closing-line {
  font-size: 0.8rem;
  color: var(--pearl-dim);
  line-height: 1.5;
  letter-spacing: 0.01em;
}
.tender-closing-line.selected-tender {
  color: var(--gold-bright);
  font-weight: 600;
}

.auction-summary-right {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 0.5rem;
  flex-shrink: 0;
}
.auction-dates {
  font-size: 0.78rem;
  color: var(--pearl-dim);
  letter-spacing: 0.05em;
  text-transform: uppercase;
}

/* ─── Countdown Chip ─────────────────────────────────────────────────── */
.deadline-chip {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  font-size: 0.82rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  padding: 0.45rem 1rem;
  border-radius: 999px;
  background: var(--ruby-bg);
  color: #ff6b5b;
  border: 1px solid rgba(231, 76, 60, 0.4);
  box-shadow: 0 0 20px var(--ruby-glow);
  animation: pulse-urgency 2.5s ease-in-out infinite;
}
.deadline-chip::before {
  content: '●';
  font-size: 0.62rem;
  animation: blink-dot 1.2s ease-in-out infinite;
  margin-right: 0.1rem;
}

/* Last-minute: make countdown chip visually urgent */
.deadline-chip.is-last-minute {
  font-size: 1.08rem;
  padding: 0.55rem 1.15rem;
  border-color: rgba(255, 107, 91, 0.75);
  box-shadow: 0 0 26px rgba(255, 107, 91, 0.35);
  animation: pulse-urgency 0.9s ease-in-out infinite;
  transform: translateY(-1px);
}
@keyframes blink-dot {
  0%, 100% { opacity: 1; }
  50%       { opacity: 0.15; }
}

@keyframes pulse-urgency {
  0%, 100% { box-shadow: 0 0 16px var(--ruby-glow); }
  50%       { box-shadow: 0 0 28px rgba(231, 76, 60, 0.35); }
}

/* ─── Tender / Auction Selection ─────────────────────────────────────── */
.auction-tender-selection {
  padding: 0.75rem 2rem;
  background: rgba(232, 181, 84, 0.06);
  border-top: 1px solid rgba(201,150,60,0.2);
  border-bottom: 1px solid rgba(201,150,60,0.2);
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}
.selection-row {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  flex-wrap: wrap;
}
.tender-selection-row {
  padding-top: 0.5rem;
  border-top: 1px solid var(--obsidian-border);
  flex-wrap: nowrap;
  align-items: center;
}
.auction-tender-selection .tender-selection-row:first-child,
.auction-tender-selection .selection-row:only-child {
  padding-top: 0;
  border-top: none;
}

.auction-switcher-label,
.tender-label {
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--pearl-dim);
  white-space: nowrap;
  min-width: 8.5rem;
  flex-shrink: 0;
}

.auction-switcher {
  display: inline-flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.auction-pill, .tender-pill {
  display: inline-block;
  padding: 0.3rem 0.85rem;
  border-radius: 6px;
  font-size: 0.8rem;
  font-weight: 500;
  text-decoration: none;
  border: 1px solid rgba(201,150,60,0.25);
  background: rgba(255,255,255,0.07);
  color: var(--pearl);
  cursor: pointer;
  transition: all 0.18s ease;
  letter-spacing: 0.02em;
}
.auction-pill:hover, .tender-pill:hover {
  border-color: var(--gold-border);
  color: var(--gold-bright);
  background: var(--gold-glow);
}
.auction-pill.active, .tender-pill.active {
  background: linear-gradient(135deg, var(--gold-deep), var(--gold));
  border-color: var(--gold);
  color: var(--obsidian);
  font-weight: 700;
  box-shadow: 0 2px 12px rgba(201,150,60,0.35);
}

.tender-toggle {
  display: inline-flex;
  flex-direction: row;
  flex-wrap: nowrap;
  white-space: nowrap;
  gap: 0.4rem;
  margin: 0;
  flex-shrink: 0;
}
.tender-pill {
  border-radius: 999px;
  font-size: 0.78rem;
  padding: 0.25rem 0.8rem;
  flex: 0 0 auto;
}

/* ─── Bid Rule Note ──────────────────────────────────────────────────── */
.bid-rule {
  margin: 1rem 2rem 0;
  padding: 0.65rem 1rem;
  font-size: 0.8rem;
  font-weight: 400;
  color: var(--pearl-dim);
  background: rgba(255,255,255,0.03);
  border-left: 2px solid var(--gold-border);
  border-radius: 0 4px 4px 0;
  letter-spacing: 0.01em;
}
.bid-rule-text {
  margin-right: 0.35rem;
}
.bid-rule-email {
  color: var(--gold-bright);
  font-weight: 500;
  letter-spacing: 0.01em;
  text-decoration: underline;
  text-decoration-color: var(--gold-border);
  text-underline-offset: 2px;
}

/* ─── Flash Messages ─────────────────────────────────────────────────── */
.messages { margin: 1rem 2rem 0; }
.message {
  padding: 0.7rem 1rem;
  border-radius: var(--radius);
  margin-bottom: 0.4rem;
  font-size: 0.875rem;
  font-weight: 500;
  letter-spacing: 0.01em;
}
.message.error {
  background: var(--ruby-bg);
  color: #ff8070;
  border: 1px solid rgba(231, 76, 60, 0.3);
}
.message.success {
  background: var(--emerald-bg);
  color: #5dd6a0;
  border: 1px solid rgba(26, 107, 74, 0.4);
}
.message.info {
  background: var(--sapphire-bg);
  color: #7ab8f5;
  border: 1px solid rgba(26, 74, 138, 0.4);
}

/* ─── Closed Banner ──────────────────────────────────────────────────── */
.closed-banner {
  margin: 1rem 2rem 0;
  padding: 0.8rem 1rem;
  background: rgba(255, 180, 50, 0.08);
  color: var(--gold-bright);
  border-radius: var(--radius);
  border: 1px solid var(--gold-border);
  font-size: 0.875rem;
  font-weight: 500;
  letter-spacing: 0.02em;
}

/* ─── Lot Table ──────────────────────────────────────────────────────── */

.lot-table {
  width: 100%;
  border-collapse: separate;
  border-spacing: 0;
  margin-top: 1rem;
  border-radius: var(--radius-lg);
  overflow: visible;   /* must NOT be hidden — breaks sticky */
  border: 1px solid var(--obsidian-border);
  background: rgba(20, 23, 35, 0.98);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.05),
    0 2px 4px rgba(0, 0, 0, 0.4),
    0 8px 16px rgba(0, 0, 0, 0.5),
    0 24px 48px rgba(0, 0, 0, 0.6),
    0 40px 80px rgba(0, 0, 0, 0.5),
    0 0 40px rgba(201, 150, 60, 0.1);
}

.lot-table th {
  padding: 0.8rem 1rem;
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--gold-bright);
  background: rgba(20, 23, 35, 0.9);
  border-bottom: 1px solid var(--gold-border);
  text-align: left;
}
.lot-table th:last-child { text-align: right; padding-right: 1.25rem; }
.lot-table th:nth-child(2) { text-align: right; }

/* ─── Lot Media Hint ─────────────────────────────────────────────── */
.lot-media-hint {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  margin: 0.5rem 2rem 0;
  padding: 0.6rem 1rem;
  font-size: 0.8rem;
  color: var(--pearl-dim);
  background: rgba(201, 150, 60, 0.05);
  border-left: 2px solid var(--gold-border);
  border-radius: 0 4px 4px 0;
  letter-spacing: 0.01em;
}
.lot-media-hint strong {
  color: var(--gold-bright);
  font-weight: 600;
}
.lot-media-hint-icon {
  font-size: 1rem;
  flex-shrink: 0;
}
.lot-table td {
  padding: 0.7rem 1rem;
  font-size: 0.95rem;
  border-bottom: 1px solid rgba(255,255,255,0.06);
  transition: background 0.15s;
  vertical-align: middle;
  color: var(--pearl);
}
.lot-table td:first-child {
  font-family: 'DM Sans', sans-serif;
  font-size: 0.95rem;
  font-weight: 600;
  color: var(--pearl);
  letter-spacing: 0.03em;
}
.lot-table td:nth-child(2) {
  /* Your Bid — input column */
  text-align: right;
  font-variant-numeric: tabular-nums;
}
.lot-table td:last-child {
  /* Current Bid — gold, right-aligned */
  font-family: 'Inter', sans-serif;
  font-size: 1rem;
  color: var(--gold-bright);
  font-weight: 700;
  letter-spacing: -0.01em;
  text-align: right;
  font-variant-numeric: tabular-nums;
}

.lot-table tbody tr:nth-child(odd)  td { background: var(--obsidian-mid); }
.lot-table tbody tr:nth-child(even) td { background: var(--obsidian-light); }
.lot-table tbody tr:last-child td { border-bottom: none; }

.lot-table tr.has-bid td:first-child { color: var(--pearl); font-weight: 600; }
.lot-table tr.has-bid td:last-child  { color: var(--gold-bright); font-weight: 700; }

.lot-table tbody tr:hover td {
  background: rgba(201, 150, 60, 0.07) !important;
}

/* ─── Bid Input ──────────────────────────────────────────────────────── */
.lot-table input[type="text"][name^="bid_"] {
  appearance: textfield;
  -moz-appearance: textfield;
  width: 130px;
  padding: 0.5rem 0.75rem;
  background: var(--obsidian);
  border: 1px solid var(--obsidian-border);
  border-radius: var(--radius);
  color: var(--pearl);
  font-family: 'Inter', sans-serif;
  font-size: 1rem;
  font-weight: 700;
  text-align: right;
  font-variant-numeric: tabular-nums;
  letter-spacing: -0.01em;
  transition: border-color 0.2s, box-shadow 0.2s, background 0.2s;
}
.lot-table input[type="text"][name^="bid_"]::-webkit-inner-spin-button,
.lot-table input[type="text"][name^="bid_"]::-webkit-outer-spin-button { -webkit-appearance: none; }
.lot-table input[type="text"][name^="bid_"]:hover { border-color: var(--gold-border); }
.lot-table input[type="text"][name^="bid_"]:focus {
  outline: none;
  border-color: var(--gold);
  background: rgba(201, 150, 60, 0.06);
  box-shadow: 0 0 0 3px rgba(201, 150, 60, 0.12);
}

.lot-photo-link-wrap {
  margin-top: 0.15rem;
}
.lot-photo-main-link {
  background: transparent;
  border: none;
  padding: 0;
  margin: 0;
  font: inherit;
  color: var(--pearl);
  cursor: pointer;
  text-decoration: none;
}
.lot-photo-main-link:hover {
  text-decoration: underline;
  color: #f5d98a;
}
.lot-photo-link {
  font-size: 0.78rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: #7ab8f5;
  text-decoration: none;
}
.lot-photo-link:hover {
  text-decoration: underline;
  color: #9fc7ff;
}

.last-lot-info {
  margin: 1rem 2rem 0;
  padding: 0.6rem 0.9rem;
  font-size: 0.8rem;
  color: var(--pearl);
  background: rgba(0, 0, 0, 0.35);
  border-radius: var(--radius);
  border: 1px solid var(--obsidian-border);
}

/* ─── Field Error ────────────────────────────────────────────────────── */
.field-error {
  margin-top: 0.3rem;
  font-size: 0.73rem;
  font-weight: 500;
  color: #ff7a6a;
  letter-spacing: 0.01em;
  line-height: 1.3;
  max-width: 220px;
  text-align: right;
}

/* ─── Submit Button ──────────────────────────────────────────────────── */
.submit-btn {
  align-self: flex-end;
  margin-top: 1.5rem;
  padding: 0.85rem 2.5rem;
  background: linear-gradient(135deg, var(--gold-deep) 0%, var(--gold-bright) 100%);
  color: var(--obsidian);
  border: none;
  border-radius: var(--radius);
  font-family: 'DM Sans', sans-serif;
  font-size: 0.9rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  cursor: pointer;
  transition: all 0.2s ease;
  box-shadow: 0 4px 20px rgba(201, 150, 60, 0.4);
  position: relative;
  overflow: hidden;
}
.submit-btn::before {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, rgba(255,255,255,0.15) 0%, transparent 60%);
  opacity: 0;
  transition: opacity 0.2s;
}
.submit-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 32px rgba(201, 150, 60, 0.55);
}
.submit-btn:hover::before { opacity: 1; }
.submit-btn:active { transform: translateY(0); }

@keyframes submit-flash {
  0%, 100% { filter: brightness(1); transform: translateY(0); }
  50% { filter: brightness(1.42); transform: translateY(-1px); }
}

.submit-btn.is-last-minute {
  font-size: 1.05rem;
  padding: 0.95rem 2.8rem;
  border: 1px solid rgba(255, 255, 255, 0.18);
  animation: submit-flash 0.85s ease-in-out infinite;
}

.submit-btn:disabled {
  animation: none !important;
  filter: none !important;
  opacity: 0.65;
  cursor: not-allowed;
}

/* ─────────────────────────────────────────────────────────────────────
   LOGIN PAGE
   ───────────────────────────────────────────────────────────────────── */
.login-page {
  padding: 0;
  max-width: 520px;
  border: 1px solid rgba(201, 150, 60, 0.25);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.08),
    0 2px 4px rgba(0, 0, 0, 0.5),
    0 8px 16px rgba(0, 0, 0, 0.55),
    0 24px 48px rgba(0, 0, 0, 0.65),
    0 48px 96px rgba(0, 0, 0, 0.5),
    0 0 0 1px rgba(0, 0, 0, 0.8),
    0 0 60px rgba(201, 150, 60, 0.12);
}

.login-page .login-top-bar {
  padding: 2rem 2.5rem;
  background: #14172080;
  border-bottom: 1px solid var(--gold-border);
  position: relative;
  overflow: hidden;
}
.login-page .login-top-bar::after {
  content: '';
  position: absolute;
  bottom: 0; left: 0; right: 0;
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--gold), transparent);
}

.login-brand {
  font-family: 'Cormorant Garamond', serif;
  font-weight: 700;
  font-size: 2.1rem;
  letter-spacing: 0.1em;
  color: var(--gold-bright);
  text-transform: uppercase;
}
.login-brand-sub {
  font-size: 0.75rem;
  font-weight: 500;
  letter-spacing: 0.25em;
  text-transform: uppercase;
  color: var(--pearl-dim);
  margin-top: 0.25rem;
}

.login-page .auction-info-box {
  padding: 1.1rem 2.5rem;
  background: var(--obsidian-light);
  border-bottom: 1px solid var(--obsidian-border);
}
.login-page .auction-info-box p {
  font-size: 0.88rem;
  color: var(--pearl-dim);
  line-height: 1.6;
  margin-bottom: 0.25rem;
}
.login-page .auction-info-box p:last-child { margin-bottom: 0; }
.login-page .auction-info-box strong { color: var(--pearl); font-weight: 600; }

.auction-option.auction-first  { color: #7ab8f5; font-weight: 600; }
.auction-option.auction-second { color: #5dd6a0; font-weight: 600; }
/* Single auction display */
.auction-option.auction-single { color: #7ab8f5; font-weight: 600; }
.auction-info-box .auction-sep { color: var(--pearl-muted); margin: 0 0.3em; }

.login-form-card {
  padding: 2rem 2.5rem 2.5rem;
}
.admin-ip-blocked-card .message.error {
  margin-bottom: 0.75rem;
}
.admin-ip-blocked-hint {
  font-size: 0.85rem;
  line-height: 1.55;
  color: var(--pearl-muted);
  margin: 0;
}
.admin-ip-blocked-hint code {
  font-size: 0.88em;
}
.login-form {
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
}
.login-form label {
  display: block;
  font-size: 0.73rem;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--pearl-dim);
  margin-bottom: 0.4rem;
}
.login-form input {
  width: 100%;
  padding: 0.85rem 1.1rem;
  background: var(--obsidian);
  border: 1px solid var(--obsidian-border);
  border-radius: var(--radius);
  color: var(--pearl);
  font-family: 'DM Sans', sans-serif;
  font-size: 0.95rem;
  transition: border-color 0.2s, box-shadow 0.2s;
  /* Inset/debossed so inputs read as pressed in vs raised card & button */
  box-shadow: inset 0 2px 6px rgba(0, 0, 0, 0.4), inset 0 1px 0 rgba(0, 0, 0, 0.2);
}
.login-form select {
  width: 100%;
  padding: 0.85rem 1.1rem;
  background: var(--obsidian);
  border: 1px solid var(--obsidian-border);
  border-radius: var(--radius);
  color: var(--pearl);
  font-family: 'DM Sans', sans-serif;
  font-size: 0.95rem;
  cursor: pointer;
  box-shadow: inset 0 2px 6px rgba(0, 0, 0, 0.4), inset 0 1px 0 rgba(0, 0, 0, 0.2);
}
.login-form select:hover { border-color: rgba(201,150,60,0.4); }
.login-form select:focus {
  outline: none;
  border-color: var(--gold);
  box-shadow: inset 0 2px 6px rgba(0, 0, 0, 0.35), inset 0 1px 0 rgba(0, 0, 0, 0.15), 0 0 0 3px rgba(201, 150, 60, 0.12);
}
.login-form input::placeholder { color: var(--pearl-muted); font-size: 0.88rem; }
.login-form input:hover  { border-color: rgba(201,150,60,0.4); }
.login-form input:focus  {
  outline: none;
  border-color: var(--gold);
  box-shadow: inset 0 2px 6px rgba(0, 0, 0, 0.35), inset 0 1px 0 rgba(0, 0, 0, 0.15), 0 0 0 3px rgba(201, 150, 60, 0.12);
  background: rgba(201, 150, 60, 0.04);
}

/* OTP / login: same custom checkbox as bid sheet (.highest-bid-check) */
.login-page .login-remember-row {
  display: flex;
  align-items: flex-start;
  gap: 0.55rem;
  margin-top: 0.15rem;
  margin-bottom: 0;
  font-weight: 400;
  font-size: clamp(0.62rem, 2vw, 0.82rem);
  letter-spacing: 0.04em;
  text-transform: none;
  color: var(--pearl-muted);
  line-height: 1.35;
  cursor: pointer;
}
.login-page .login-remember-row .login-remember-text {
  flex: 1;
  min-width: 0;
  padding-top: 0.06rem;
}
/* Checkbox is still .login-form input — must override width:100% + padding from .login-form input */
.login-page .login-form input.login-remember-check {
  -webkit-appearance: none;
  appearance: none;
  box-sizing: border-box;
  flex: 0 0 auto;
  width: 14px;
  height: 14px;
  min-width: 14px;
  max-width: 14px;
  min-height: 14px;
  padding: 0;
  margin-top: 0.12em;
  border: 1px solid #788095;
  border-radius: 2px;
  background: #f1f3f7;
  cursor: pointer;
  position: relative;
  box-shadow: none;
  font-size: inherit;
}
.login-page .login-form input.login-remember-check:hover,
.login-page .login-form input.login-remember-check:focus {
  background: #f1f3f7;
  box-shadow: none;
}
.login-page .login-form input.login-remember-check:focus-visible {
  outline: 2px solid var(--gold);
  outline-offset: 1px;
  border-color: #788095;
}
.login-page .login-form input.login-remember-check:checked {
  border-color: #2ecb70;
  background: #2ecb70;
}
.login-page .login-form input.login-remember-check:checked::after {
  content: "";
  position: absolute;
  left: 4px;
  top: 1px;
  width: 2px;
  height: 6px;
  border: solid #ffffff;
  border-width: 0 2px 2px 0;
  transform: rotate(45deg);
}

.login-submit {
  width: 100%;
  margin-top: 0.5rem;
  padding: 0.9rem;
  background: linear-gradient(135deg, var(--gold-deep) 0%, var(--gold-bright) 100%);
  color: var(--obsidian);
  border: none;
  border-radius: var(--radius);
  font-family: 'DM Sans', sans-serif;
  font-size: 0.9rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  cursor: pointer;
  transition: all 0.2s;
  /* Embossed: top highlight + strong bottom shadow so button reads as raised */
  box-shadow:
    0 1px 0 rgba(255, 255, 255, 0.25) inset,
    0 4px 0 rgba(0, 0, 0, 0.25),
    0 6px 16px rgba(0, 0, 0, 0.4),
    0 4px 20px rgba(201, 150, 60, 0.35);
}
.login-submit:hover {
  transform: translateY(-2px);
  box-shadow:
    0 1px 0 rgba(255, 255, 255, 0.28) inset,
    0 6px 0 rgba(0, 0, 0, 0.2),
    0 10px 28px rgba(0, 0, 0, 0.45),
    0 8px 32px rgba(201, 150, 60, 0.5);
}
.login-submit:active {
  transform: translateY(0);
  box-shadow:
    0 1px 0 rgba(255, 255, 255, 0.15) inset,
    0 2px 0 rgba(0, 0, 0, 0.25),
    0 2px 8px rgba(0, 0, 0, 0.35);
}

.login-page .admin-passkey-sep {
  margin: 1rem 0 0;
  text-align: center;
  font-size: 0.85rem;
  color: #8f97a3;
}
.login-page .admin-passkey-msg {
  margin-top: 0.5rem;
  font-size: 0.8rem;
  color: #c4a35a;
}

/* Admin login: passkey = secondary CTA (teal; distinct from gold password sign-in) */
.login-page .login-passkey-btn {
  margin-top: 0.75rem;
  background: linear-gradient(135deg, #183d48 0%, #245560 100%);
  color: #cdd8dc;
  border: 1px solid rgba(100, 165, 178, 0.32);
  box-shadow:
    0 1px 0 rgba(255, 255, 255, 0.12) inset,
    0 4px 0 rgba(0, 0, 0, 0.23),
    0 6px 15px rgba(0, 0, 0, 0.36),
    0 2px 10px rgba(30, 110, 125, 0.16);
}
.login-page .login-passkey-btn:hover {
  background: linear-gradient(135deg, #1e4a56 0%, #2c6472 100%);
  color: #e8f0f3;
  box-shadow:
    0 1px 0 rgba(255, 255, 255, 0.16) inset,
    0 6px 0 rgba(0, 0, 0, 0.19),
    0 9px 24px rgba(0, 0, 0, 0.4),
    0 3px 16px rgba(40, 130, 145, 0.2);
}
.login-page .login-passkey-btn:active {
  background: linear-gradient(135deg, #15343e 0%, #1f4a56 100%);
  color: #c4ced2;
  box-shadow:
    0 1px 0 rgba(255, 255, 255, 0.09) inset,
    0 2px 0 rgba(0, 0, 0, 0.28),
    0 2px 9px rgba(0, 0, 0, 0.33);
}

/* ─────────────────────────────────────────────────────────────────────
   OTP PAGE
   ───────────────────────────────────────────────────────────────────── */
.container h1 {
  font-family: 'Cormorant Garamond', serif;
  font-size: 1.8rem;
  font-weight: 600;
  color: var(--gold-bright);
  letter-spacing: 0.06em;
  padding: 1.75rem 2rem 0;
}

.container > form {
  padding: 1.5rem 2rem 2rem;
  gap: 1.1rem;
}
.container > form label {
  font-size: 0.73rem;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--pearl-dim);
}
.container > form input[type="text"] {
  padding: 0.85rem 1.1rem;
  background: var(--obsidian);
  border: 1px solid var(--obsidian-border);
  border-radius: var(--radius);
  color: var(--pearl);
  font-family: 'DM Mono', monospace;
  font-size: 1.4rem;
  letter-spacing: 0.35em;
  text-align: center;
  transition: border-color 0.2s, box-shadow 0.2s;
}
.container > form input[type="text"]:focus {
  outline: none;
  border-color: var(--gold);
  box-shadow: 0 0 0 3px rgba(201, 150, 60, 0.12);
}
.container > form button[type="submit"] {
  padding: 0.85rem;
  background: linear-gradient(135deg, var(--gold-deep) 0%, var(--gold-bright) 100%);
  color: var(--obsidian);
  border: none;
  border-radius: var(--radius);
  font-family: 'DM Sans', sans-serif;
  font-size: 0.9rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  cursor: pointer;
  box-shadow: 0 4px 20px rgba(201, 150, 60, 0.35);
  transition: all 0.2s;
}
.container > form button[type="submit"]:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 32px rgba(201, 150, 60, 0.5);
}

/* ─────────────────────────────────────────────────────────────────────
   ADMIN CONSOLE — readable background and text (no dark blue/purple)
   ───────────────────────────────────────────────────────────────────── */
.container.admin-console {
  background: #2a2d36;
  border-color: #3d4048;
}
.container.admin-console .top-bar {
  background: #23262e;
  border-bottom-color: rgba(201, 150, 60, 0.35);
}
.container.admin-console .top-bar .brand { color: #e8b554; }
.container.admin-console .top-bar .subtitle,
.container.admin-console .top-bar .session-info span { color: #d4d0c8; }
.container.admin-console .top-bar .session-info .link-light { color: #e8b554; }
.container.admin-console .top-bar .session-info .link-light:hover { color: #f5d98a; }

.admin-content {
  padding: 2rem;
  background: #2e3139;
  color: #e8e6e1;
  min-height: 12rem;
}
.admin-content h1 {
  font-family: 'Cormorant Garamond', serif;
  font-size: 1.8rem;
  font-weight: 600;
  color: #e8e6e1;
  letter-spacing: 0.06em;
  margin-bottom: 0.5rem;
  text-align: left;
}
.admin-content p,
.admin-content .login-form label {
  color: #d4d0c8;
}
.admin-content code {
  background: rgba(0, 0, 0, 0.25);
  padding: 0.15rem 0.4rem;
  border-radius: 4px;
  color: #e8e6e1;
  font-size: 0.9em;
}
.admin-content .link-light {
  color: #e8b554;
  text-decoration: none;
  font-weight: 500;
}
.admin-content .link-light:hover {
  color: #f5d98a;
  text-decoration: underline;
}
.admin-content .session-info span {
  color: #d4d0c8;
}
.admin-content .login-form input,
.admin-content .login-form select {
  background: #1c1e24;
  border-color: #3d4048;
  color: #e8e6e1;
}
.admin-content .login-form input::placeholder {
  color: #8a8580;
}

.admin-dashboard-intro {
  margin-bottom: clamp(0.4rem, 2vw, 1.25rem);
  color: #d4d0c8;
  max-width: none;
  line-height: 1.35;
  font-size: clamp(0.72rem, 2.6vw, 0.95rem);
  flex-shrink: 0;
}

.admin-dashboard-groups {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: clamp(0.4rem, 1.5vw, 0.9rem);
  align-content: start;
  max-width: none;
  width: 100%;
  flex: 1 1 auto;
  min-height: 0;
}

.admin-dash-group {
  background: rgba(24, 26, 32, 0.75);
  border: 1px solid #3d4048;
  border-radius: clamp(6px, 1.2vw, 10px);
  padding: clamp(0.45rem, 1.8vw, 0.95rem) clamp(0.5rem, 1.8vw, 1rem);
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.2);
  min-height: 0;
}

.admin-dash-group-title {
  font-family: 'Cormorant Garamond', serif;
  font-size: clamp(0.68rem, 2.2vw, 1.05rem);
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: #c9963c;
  margin: 0 0 clamp(0.25rem, 1.2vw, 0.65rem);
  padding-bottom: clamp(0.2rem, 1vw, 0.45rem);
  border-bottom: 1px solid rgba(201, 150, 60, 0.25);
  line-height: 1.2;
}

.admin-dash-link-list {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: clamp(0.2rem, 1.2vw, 0.55rem);
}

.admin-dash-link-list li {
  display: flex;
  flex-direction: column;
  gap: 0.05rem;
  padding: clamp(0.15rem, 0.8vw, 0.3rem) 0;
  border-bottom: 1px dashed rgba(255, 255, 255, 0.06);
}

.admin-dash-link-list li:last-child {
  border-bottom: none;
  padding-bottom: 0;
}

.admin-dash-link {
  font-size: clamp(0.78rem, 2.4vw, 1rem);
  font-weight: 500;
  line-height: 1.25;
}

.admin-dash-desc {
  font-size: clamp(0.65rem, 2vw, 0.88rem);
  color: #9aa3b5;
  line-height: 1.3;
  padding-left: 0.05rem;
}

/* Dashboard: fit menu cards in one viewport (container keeps overflow:hidden) */
body.admin-dashboard-page {
  min-height: calc(100vh - var(--site-footer-safe));
  min-height: calc(100dvh - var(--site-footer-safe));
  overflow: hidden;
}

body.admin-dashboard-page .container.admin-console {
  max-width: min(1100px, calc(100vw - 1.25rem));
  width: 100%;
  margin: clamp(0.5rem, 2vw, 1rem) auto;
  max-height: calc(100vh - clamp(1rem, 3vw, 2rem) - var(--site-footer-safe));
  height: calc(100vh - clamp(1rem, 3vw, 2rem) - var(--site-footer-safe));
  max-height: calc(100dvh - clamp(1rem, 3vw, 2rem) - var(--site-footer-safe));
  height: calc(100dvh - clamp(1rem, 3vw, 2rem) - var(--site-footer-safe));
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

body.admin-dashboard-page .admin-content {
  flex: 1 1 auto;
  min-height: 0;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  padding: clamp(0.5rem, 2vw, 1.5rem) clamp(0.5rem, 2.5vw, 2rem) clamp(0.5rem, 2vw, 1.25rem);
}

body.admin-dashboard-page .admin-content h1 {
  font-size: clamp(1rem, 4.2vw, 1.8rem);
  margin-bottom: clamp(0.15rem, 1vw, 0.45rem);
  flex-shrink: 0;
}

body.admin-dashboard-page .admin-content .messages {
  flex-shrink: 0;
  margin-bottom: clamp(0.35rem, 1.5vw, 0.75rem) !important;
}

body.admin-dashboard-page .admin-content .messages .message {
  font-size: clamp(0.7rem, 2.2vw, 0.88rem);
  padding: 0.35rem 0.5rem;
}

body.admin-dashboard-page .top-bar {
  padding: clamp(0.6rem, 2vw, 1.5rem) clamp(0.75rem, 2.5vw, 2rem);
  flex-shrink: 0;
}

body.admin-dashboard-page .top-bar .brand {
  font-size: clamp(1rem, 4vw, 1.9rem);
}

body.admin-dashboard-page .top-bar .subtitle {
  font-size: clamp(0.65rem, 2vw, 0.78rem);
}

body.admin-dashboard-page .session-info {
  font-size: clamp(0.7rem, 2.2vw, 0.9rem);
}

body.admin-dashboard-page .admin-dashboard-groups {
  overflow: hidden;
}

@media (max-width: 520px) {
  body.admin-dashboard-page .container.admin-console {
    max-width: calc(100vw - 0.75rem);
    margin: 0.35rem auto;
    max-height: calc(100vh - 0.7rem - var(--site-footer-safe));
    height: calc(100vh - 0.7rem - var(--site-footer-safe));
    max-height: calc(100dvh - 0.7rem - var(--site-footer-safe));
    height: calc(100dvh - 0.7rem - var(--site-footer-safe));
  }

  body.admin-dashboard-page .admin-content {
    padding: 0.4rem 0.45rem 0.5rem;
  }

  .admin-dashboard-groups {
    gap: 0.35rem;
  }

  .admin-dash-group {
    padding: 0.35rem 0.4rem;
  }
}

/* Profile: fit in viewport (overflow hidden on shell), responsive type; inner area scrolls if needed */
body.admin-profile-page {
  min-height: calc(100vh - var(--site-footer-safe));
  min-height: calc(100dvh - var(--site-footer-safe));
  overflow-x: hidden;
  overflow-y: auto;
}

body.admin-profile-page .container.admin-console {
  max-width: min(780px, calc(100vw - 2.5rem));
  width: 100%;
  margin: clamp(1.2rem, 4vh, 2rem) auto;
  max-height: calc(96dvh - clamp(1rem, 3vw, 2rem) - var(--site-footer-safe));
  height: auto;
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

body.admin-profile-page .admin-profile-content {
  flex: 1 1 auto;
  min-height: 0 !important; /* override .admin-content 12rem min-height for flex shrink */
  overflow-x: hidden;
  overflow-y: auto;
  padding: clamp(0.4rem, 1.6vw, 1.1rem) clamp(0.45rem, 2vw, 1.5rem) clamp(0.5rem, 1.8vw, 1.1rem);
  -webkit-overflow-scrolling: touch;
}

body.admin-profile-page .admin-profile-content h1 {
  font-size: clamp(0.9rem, 3.6vw, 1.55rem);
  margin-bottom: clamp(0.15rem, 0.9vw, 0.4rem);
  flex-shrink: 0;
}

body.admin-profile-page .admin-profile-content .messages {
  flex-shrink: 0;
  margin-bottom: clamp(0.3rem, 1.2vw, 0.65rem) !important;
}

body.admin-profile-page .admin-profile-content .messages .message {
  font-size: clamp(0.65rem, 2vw, 0.82rem);
  padding: 0.3rem 0.45rem;
}

body.admin-profile-page .top-bar {
  padding: clamp(0.5rem, 1.8vw, 1.25rem) clamp(0.6rem, 2.2vw, 1.75rem);
  flex-shrink: 0;
}

body.admin-profile-page .top-bar .brand {
  font-size: clamp(0.9rem, 3.4vw, 1.7rem);
}

body.admin-profile-page .top-bar .subtitle {
  font-size: clamp(0.58rem, 1.9vw, 0.74rem);
}

body.admin-profile-page .session-info {
  font-size: clamp(0.65rem, 2vw, 0.85rem);
}

body.admin-profile-page .admin-profile-form {
  max-width: min(32rem, 100%);
  margin: 0 auto;
  gap: clamp(0.65rem, 2.3vw, 1.1rem);
}

body.admin-profile-page .admin-profile-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: clamp(0.65rem, 2.4vw, 1.15rem) clamp(0.85rem, 3vw, 1.5rem);
}

body.admin-profile-page .admin-profile-field--full {
  grid-column: 1 / -1;
}

body.admin-profile-page .admin-profile-form label {
  font-size: clamp(0.58rem, 1.85vw, 0.72rem);
  margin-bottom: clamp(0.2rem, 0.8vw, 0.35rem);
}

body.admin-profile-page .admin-profile-form input {
  font-size: clamp(0.74rem, 2.3vw, 0.88rem);
  padding: clamp(0.45rem, 1.6vw, 0.78rem) clamp(0.5rem, 1.8vw, 1rem);
}

body.admin-profile-page .admin-profile-form input:disabled {
  color: #8f98aa;
  background: #161b23;
  border-color: #303846;
  cursor: not-allowed;
  opacity: 1;
}

body.admin-profile-page .profile-field-hint {
  font-size: clamp(0.58rem, 1.85vw, 0.72rem);
  color: #a8a29e;
  margin: clamp(-0.25rem, -0.5vw, -0.15rem) 0 clamp(0.25rem, 1vw, 0.45rem);
  line-height: 1.3;
}

body.admin-profile-page .admin-profile-save-btn {
  margin-top: clamp(0.45rem, 1.5vw, 0.9rem);
  width: auto;
  font-size: clamp(0.68rem, 2vw, 0.82rem);
  padding: clamp(0.45rem, 1.5vw, 0.72rem) clamp(0.75rem, 2.5vw, 1.1rem);
}

body.admin-profile-page .profile-section-rule {
  margin: clamp(0.85rem, 3vw, 1.35rem) 0;
  border: none;
  border-top: 1px solid #3d3a36;
}

body.admin-profile-page .profile-passkeys-block {
  max-width: min(32rem, 100%);
  margin: 0 auto;
}

body.admin-profile-page .profile-passkeys-block h2 {
  font-family: 'Cormorant Garamond', serif;
  font-size: clamp(0.78rem, 2.5vw, 1rem);
  font-weight: 600;
  color: #e8e6e1;
  margin: 0 0 clamp(0.35rem, 1.2vw, 0.55rem);
  letter-spacing: 0.04em;
}

body.admin-profile-page .profile-passkeys-intro {
  font-size: clamp(0.58rem, 1.9vw, 0.78rem);
  color: #a8a29e;
  margin: 0 0 clamp(0.45rem, 1.5vw, 0.75rem);
  line-height: 1.35;
  max-width: min(36rem, 100%);
}

body.admin-profile-page .profile-passkeys-block > label {
  display: block;
  font-size: clamp(0.58rem, 1.85vw, 0.72rem);
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: #d4d0c8;
  margin-bottom: clamp(0.2rem, 0.8vw, 0.35rem);
}

body.admin-profile-page .profile-passkey-label-input {
  display: block;
  width: 100%;
  max-width: min(24rem, 100%);
  margin-bottom: clamp(0.45rem, 1.5vw, 0.65rem);
  padding: clamp(0.45rem, 1.6vw, 0.78rem) clamp(0.5rem, 1.8vw, 1rem);
  background: #1c1e24;
  border: 1px solid #3d4048;
  border-radius: var(--radius);
  color: #e8e6e1;
  font-family: 'DM Sans', sans-serif;
  font-size: clamp(0.74rem, 2.3vw, 0.88rem);
  box-shadow: inset 0 2px 6px rgba(0, 0, 0, 0.4), inset 0 1px 0 rgba(0, 0, 0, 0.2);
}

body.admin-profile-page .profile-passkey-register-btn {
  width: auto;
  font-size: clamp(0.68rem, 2vw, 0.82rem);
  padding: clamp(0.45rem, 1.5vw, 0.72rem) clamp(0.75rem, 2.5vw, 1.1rem);
}

body.admin-profile-page .profile-passkey-msg {
  display: none;
  margin-top: clamp(0.35rem, 1.2vw, 0.5rem);
  font-size: clamp(0.58rem, 1.85vw, 0.74rem);
  color: #c4a35a;
  line-height: 1.3;
}

body.admin-profile-page .profile-passkey-msg.is-visible {
  display: block;
}

body.admin-profile-page .profile-passkeys-list {
  list-style: disc;
  margin: clamp(0.55rem, 2vw, 0.85rem) 0 0;
  padding-left: clamp(0.85rem, 3vw, 1.15rem);
  font-size: clamp(0.56rem, 1.8vw, 0.78rem);
  color: #d4d0c8;
}

body.admin-profile-page .profile-passkeys-list-item {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 0.1rem 0.35rem;
  margin-bottom: clamp(0.28rem, 1vw, 0.42rem);
  line-height: 1.3;
}

body.admin-profile-page .profile-passkey-meta {
  color: #78716c;
}

body.admin-profile-page .profile-passkey-remove-form {
  display: inline;
  margin-left: clamp(0.25rem, 1vw, 0.45rem);
}

body.admin-profile-page .profile-passkey-remove {
  background: none;
  border: none;
  padding: 0;
  cursor: pointer;
  text-decoration: underline;
  color: #e07a7a;
  font: inherit;
  font-size: inherit;
}

body.admin-profile-page .profile-passkey-remove:hover {
  color: #f0a0a0;
}

body.admin-profile-page .profile-passkeys-empty {
  margin-top: clamp(0.55rem, 2vw, 0.85rem);
  font-size: clamp(0.58rem, 1.85vw, 0.76rem);
  color: #78716c;
}

@media (max-width: 520px) {
  body.admin-profile-page .container.admin-console {
    max-width: calc(100vw - 0.75rem);
    margin: 0.35rem auto;
    max-height: calc(100dvh - 0.7rem - var(--site-footer-safe));
    height: calc(100dvh - 0.7rem - var(--site-footer-safe));
  }

  body.admin-profile-page .admin-profile-content {
    padding: 0.35rem 0.4rem 0.45rem;
  }
}

/* User form: same responsive shell as profile, with 2-column grid */
body.admin-user-form-page {
  min-height: calc(100vh - var(--site-footer-safe));
  min-height: calc(100dvh - var(--site-footer-safe));
  overflow-x: hidden;
  overflow-y: auto;
}

body.admin-user-form-page .container.admin-console {
  max-width: min(920px, calc(100vw - 2rem));
  width: 100%;
  margin: clamp(1.2rem, 4vh, 2rem) auto;
  max-height: calc(96dvh - clamp(1rem, 3vw, 2rem) - var(--site-footer-safe));
  height: auto;
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

body.admin-user-form-page .admin-user-form-content {
  flex: 1 1 auto;
  min-height: 0 !important;
  overflow-x: hidden;
  overflow-y: auto;
  padding: clamp(0.4rem, 1.6vw, 1.1rem) clamp(0.45rem, 2vw, 1.5rem) clamp(0.5rem, 1.8vw, 1.1rem);
  -webkit-overflow-scrolling: touch;
}

body.admin-user-form-page .admin-user-form {
  max-width: min(40rem, 100%);
  margin: 0 auto;
  gap: clamp(0.75rem, 2.5vw, 1.25rem);
}

body.admin-user-form-page .admin-user-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: clamp(0.75rem, 2.6vw, 1.3rem) clamp(1rem, 3.2vw, 1.8rem);
}

body.admin-user-form-page .admin-user-field--full {
  grid-column: 1 / -1;
}

body.admin-user-form-page .admin-user-field-hint {
  font-size: clamp(0.58rem, 1.85vw, 0.72rem);
  color: #a8a29e;
  margin: clamp(-0.25rem, -0.5vw, -0.15rem) 0 clamp(0.25rem, 1vw, 0.45rem);
  line-height: 1.3;
}

body.admin-user-form-page .admin-user-save-btn {
  margin-top: clamp(0.45rem, 1.5vw, 0.9rem);
  width: auto;
}

@media (max-width: 700px) {
  body.admin-user-form-page .admin-user-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 520px) {
  body.admin-user-form-page .container.admin-console {
    max-width: calc(100vw - 0.75rem);
    margin: 0.35rem auto;
    max-height: calc(100dvh - 0.7rem - var(--site-footer-safe));
    height: calc(100dvh - 0.7rem - var(--site-footer-safe));
  }

  body.admin-user-form-page .admin-user-form-content {
    padding: 0.35rem 0.4rem 0.45rem;
  }
}

.admin-user-rights-intro {
  font-size: 0.9rem;
  color: #b7c6ff;
  margin-bottom: 1.25rem;
  max-width: 48rem;
  line-height: 1.5;
}
.admin-user-rights-form {
  max-width: 100%;
}
.admin-user-rights-scroll {
  max-height: min(55vh, 26rem);
  overflow-y: auto;
  overflow-x: auto;
  margin-bottom: 1rem;
  border-radius: 6px;
  border: 1px solid #3d4048;
}
.admin-user-rights-table {
  margin: 0;
  min-width: 36rem;
}
.admin-user-rights-table th,
.admin-user-rights-table td {
  vertical-align: middle;
  text-align: center;
}
.admin-user-rights-module-col {
  text-align: left !important;
  min-width: 14rem;
}
.admin-user-rights-module-cell {
  text-align: left !important;
  font-weight: 500;
}
.admin-user-rights-label {
  display: block;
  color: #e8e6e1;
}
.admin-user-rights-desc {
  display: block;
  font-size: 0.8rem;
  font-weight: 400;
  color: #8a8580;
  margin-top: 0.25rem;
  max-width: 20rem;
}
.admin-user-rights-check-cell input[type="checkbox"] {
  width: 1.1rem;
  height: 1.1rem;
  cursor: pointer;
  accent-color: #c9963c;
}
.admin-user-rights-actions {
  margin-top: 0.5rem;
  padding-bottom: 0.25rem;
}

.admin-email-tpl-intro {
  font-size: 0.9rem;
  color: #b7c6ff;
  margin-bottom: 1rem;
  max-width: 56rem;
  line-height: 1.45;
}

.admin-email-card {
  background: rgba(24, 26, 32, 0.7);
  border: 1px solid #3d4048;
  border-radius: 10px;
  box-shadow: 0 4px 24px rgba(0, 0, 0, 0.2);
}

.admin-email-layout-grid {
  display: grid;
  grid-template-columns: 20% 60% 20%;
  gap: 1rem;
  align-items: start;
}

.admin-email-card-left,
.admin-email-card-middle,
.admin-email-card-right {
  padding: 0.9rem;
  min-width: 0;
}

.admin-email-card-left {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

/* Left column: auction (context) vs email stages (templates) — separate panels */
.admin-email-auction-panel,
.admin-email-stages-panel {
  border-radius: 10px;
  padding: 0.75rem 0.65rem 0.85rem;
  border: 1px solid #3a3d44;
}

.admin-email-auction-panel {
  background: linear-gradient(160deg, rgba(30, 34, 42, 0.95) 0%, rgba(22, 24, 30, 0.98) 100%);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.04);
}

.admin-email-stages-panel {
  background: linear-gradient(165deg, rgba(26, 28, 34, 0.98) 0%, rgba(18, 20, 26, 0.99) 100%);
  border-color: rgba(201, 150, 60, 0.22);
  box-shadow:
    inset 0 1px 0 rgba(201, 150, 60, 0.08),
    0 4px 18px rgba(0, 0, 0, 0.22);
}

.admin-email-panel-title {
  font-family: 'Cormorant Garamond', serif;
  font-size: 0.82rem;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: #b8c0d0;
  margin: 0 0 0.2rem;
  line-height: 1.2;
}

.admin-email-panel-title--stages {
  color: #d4b87a;
  letter-spacing: 0.12em;
}

.admin-email-panel-caption {
  font-size: 0.72rem;
  color: #7a8294;
  line-height: 1.35;
  margin: 0 0 0.65rem;
}

.admin-email-auction-badge {
  margin: 0 0 0.55rem;
  padding: 0.3rem 0.55rem;
  display: inline-block;
  width: fit-content;
  font-size: 0.65rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  border-radius: 6px;
  line-height: 1.2;
}

.admin-email-auction-badge--live {
  color: #6ee7b7;
  background: rgba(26, 107, 74, 0.35);
  border: 1px solid rgba(46, 160, 112, 0.55);
  box-shadow: 0 0 12px rgba(46, 160, 112, 0.12);
}

.admin-email-auction-badge--upcoming {
  color: #f5d98a;
  background: rgba(201, 150, 60, 0.18);
  border: 1px solid rgba(201, 150, 60, 0.4);
}

.admin-email-auction-form {
  margin: 0;
}

.admin-email-auction-field {
  display: flex;
  flex-direction: column;
  gap: 0.3rem;
}

.admin-email-auction-field label {
  font-size: 0.72rem;
  color: #9aa3b5;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.admin-email-auction-field select {
  width: 100%;
  max-width: 100%;
  background: #14161c;
  color: #e8e6e1;
  border: 1px solid #454952;
  border-radius: 8px;
  padding: 0.5rem 0.55rem;
  font-family: inherit;
  font-size: 0.8rem;
}

.admin-email-auction-field select:focus {
  outline: none;
  border-color: rgba(201, 150, 60, 0.55);
  box-shadow: 0 0 0 2px rgba(201, 150, 60, 0.12);
}

/* Email stage tabs: numbered rail, clear active state */
.admin-email-stage-nav {
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
}

.admin-email-stage-link {
  display: flex;
  align-items: center;
  gap: 0.55rem;
  padding: 0.5rem 0.5rem 0.5rem 0.4rem;
  border-radius: 8px;
  text-decoration: none;
  color: #aeb6c8;
  font-size: 0.84rem;
  font-weight: 500;
  line-height: 1.25;
  border: 1px solid transparent;
  border-left: 3px solid transparent;
  transition:
    background 0.15s ease,
    color 0.15s ease,
    border-color 0.15s ease,
    box-shadow 0.15s ease;
}

.admin-email-stage-link:hover {
  background: rgba(255, 255, 255, 0.05);
  color: #ece8e0;
}

.admin-email-stage-link.is-active {
  background: linear-gradient(90deg, rgba(201, 150, 60, 0.2) 0%, rgba(201, 150, 60, 0.06) 100%);
  color: #f5d98a;
  border-color: rgba(201, 150, 60, 0.25);
  border-left-color: #e8b554;
  box-shadow: 0 2px 12px rgba(0, 0, 0, 0.2);
}

.admin-email-stage-num {
  flex: 0 0 1.5rem;
  width: 1.5rem;
  height: 1.5rem;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.68rem;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
  color: #6d7380;
  background: rgba(0, 0, 0, 0.28);
  border-radius: 6px;
  border: 1px solid #3d4048;
}

.admin-email-stage-link.is-active .admin-email-stage-num {
  color: #1a1c22;
  background: linear-gradient(145deg, #e8b554 0%, #c9963c 100%);
  border-color: rgba(255, 255, 255, 0.15);
}

.admin-email-stage-label {
  flex: 1;
  min-width: 0;
}

/* Draft column: single form, viewport-bound (avoid overflow:hidden on form so focus rings are not clipped) */
.admin-email-card-draft {
  display: flex;
  flex-direction: column;
  min-height: 0;
  overflow-x: hidden;
  overflow-y: auto;
}

.admin-email-draft-form {
  display: flex;
  flex-direction: column;
  flex: 1 1 auto;
  min-height: 0;
  overflow: visible;
  gap: 0.35rem;
}

.admin-email-draft-header {
  flex-shrink: 0;
}

.admin-email-draft-header--with-invitation-note {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 0.5rem 1rem;
}

.admin-email-draft-header--with-invitation-note .admin-email-draft-title {
  margin-bottom: 0;
}

.admin-email-draft-title {
  font-family: 'Cormorant Garamond', serif;
  font-size: 1.05rem;
  font-weight: 600;
  color: #ece8e0;
  margin: 0 0 0.2rem;
  letter-spacing: 0.04em;
}

.admin-email-draft-invitation-notice {
  font-size: 0.65rem;
  color: #8a92a8;
  margin: 0;
  line-height: 1.35;
  flex: 1 1 10rem;
  min-width: 0;
}

.admin-email-draft-invitation-notice code {
  font-size: 0.62rem;
  color: #aeb6c8;
}

.admin-email-draft-label {
  font-size: 0.72rem;
  color: #9aa3b5;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin-top: 0.15rem;
  flex-shrink: 0;
}

.admin-email-draft-input {
  width: 100%;
  background: #f7f4ed;
  color: #222;
  border: 1px solid #c9c4b8;
  border-radius: 8px;
  padding: 0.45rem 0.6rem;
  font-family: inherit;
  font-size: 0.88rem;
  flex-shrink: 0;
  box-sizing: border-box;
  color-scheme: light;
}

.admin-email-draft-input::placeholder {
  color: #6b6560;
  opacity: 1;
}

.admin-email-draft-input:focus-visible {
  outline: none;
  border-color: #a67c28;
  box-shadow: inset 0 0 0 1px rgba(201, 150, 60, 0.55);
}

.admin-email-draft-body-wrap {
  flex: 1 1 auto;
  min-height: 8.5rem;
  max-height: min(52vh, 520px);
  display: flex;
  flex-direction: column;
  padding: 2px;
  margin: 0 -2px;
  box-sizing: border-box;
}

.admin-email-draft-sig-wrap {
  flex: 0 0 auto;
  min-height: 6.5rem;
  max-height: min(34vh, 280px);
  display: flex;
  flex-direction: column;
  padding: 2px;
  margin: 0 -2px;
  box-sizing: border-box;
}

.admin-email-body--draft {
  flex: 1 1 auto;
  min-height: 7.5rem;
  max-height: 100%;
  overflow: auto;
  resize: none;
  border-radius: 8px;
  box-sizing: border-box;
}

.admin-email-body--draft:focus-visible {
  outline: none;
  border-color: #a67c28;
  box-shadow: inset 0 0 0 1px rgba(201, 150, 60, 0.55);
}

.admin-email-body--sig {
  min-height: 6rem;
  max-height: 100%;
  overflow: auto;
  resize: vertical;
  border-radius: 8px;
  box-sizing: border-box;
}

.admin-email-body--sig:focus-visible {
  outline: none;
  border-color: #a67c28;
  box-shadow: inset 0 0 0 1px rgba(201, 150, 60, 0.55);
}

.admin-email-draft-attach-row {
  flex-shrink: 0;
}

.admin-email-attach-hint {
  font-size: 0.72rem;
  line-height: 1.4;
  color: #8a92a8;
  margin: 0 0 0.35rem;
}

.admin-email-file-input {
  font-size: 0.8rem;
  color: #c8cdd8;
}

.admin-email-draft-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  align-items: center;
  flex-shrink: 0;
  margin-top: 0.25rem;
}

.admin-email-draft-preview-bar {
  flex-shrink: 0;
  display: flex;
  justify-content: center;
  margin-top: 0.65rem;
  padding-top: 0.5rem;
}

.admin-email-preview-btn-large {
  padding: 0.85rem 2.25rem;
  font-size: 1.12rem;
  font-weight: 600;
  background: linear-gradient(180deg, #b8892e 0%, #9a7224 100%);
  border: 1px solid #c9963c;
  color: #1a1c22;
  border-radius: 14px;
  min-width: 11rem;
}

.admin-email-preview-btn-large:hover {
  filter: brightness(1.06);
  color: #1a1c22;
}

.admin-email-preview-post-field-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
  opacity: 0;
}

.admin-email-send-block {
  flex-shrink: 0;
  margin-top: 0.5rem;
  padding-top: 0.65rem;
  border-top: 1px dashed rgba(255, 255, 255, 0.1);
}

.admin-email-hidden-form {
  display: none;
}

.admin-email-attachment-list--compact {
  flex-shrink: 0;
  border-top: 1px solid #3a3e48;
  padding-top: 0.5rem;
  margin-top: 0.35rem;
  max-height: min(20vh, 160px);
  overflow: auto;
}

.admin-email-attachment-list--compact .admin-email-attach-summary {
  display: block;
  font-size: 0.72rem;
  color: #9aa3b5;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  margin-bottom: 0.35rem;
}

.admin-email-attachment-list--compact ul {
  list-style: none;
  padding: 0;
  margin: 0;
}

.admin-email-attachment-list--compact li {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 0.5rem;
  padding: 0.25rem 0;
  font-size: 0.8rem;
  border-bottom: 1px dashed rgba(255, 255, 255, 0.06);
}

.admin-email-inline-form {
  margin: 0;
  flex-shrink: 0;
}

.admin-email-messages {
  flex-shrink: 0;
  margin-bottom: 0.5rem;
}

.admin-email-card-recipients {
  display: flex;
  flex-direction: column;
  min-height: 0;
  overflow: hidden;
}

.admin-email-card-recipients h3 {
  flex-shrink: 0;
}

.admin-email-card-recipients .admin-email-client-list {
  flex: 1 1 auto;
  min-height: 0;
  max-height: none;
  overflow: auto;
}

.admin-email-client-list--compact {
  gap: 0.2rem;
}

.admin-email-client-list--compact .admin-email-client-oneline {
  display: block;
  padding: 0.22rem 0.4rem;
  font-size: 0.8rem;
  color: #ece6da;
  line-height: 1.35;
  background: rgba(20, 22, 28, 0.45);
  border-radius: 4px;
  border: 1px solid #2f3238;
}

.admin-email-client-email {
  font-size: 0.68rem;
  color: #9aa3b5;
  font-weight: 400;
}

/* Preview popup window */
body.admin-email-preview-popup-page {
  margin: 0;
  min-height: calc(100vh - var(--site-footer-safe));
  min-height: calc(100dvh - var(--site-footer-safe));
  background: #1e2128;
  color: #e8e6e1;
}

.admin-email-preview-popup {
  max-width: 42rem;
  margin: 0 auto;
  padding: 1.25rem 1.5rem 2rem;
}

.admin-email-preview-popup-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
  margin-bottom: 1rem;
  padding-bottom: 0.75rem;
  border-bottom: 1px solid #3d4048;
}

.admin-email-preview-popup-head h1 {
  font-family: 'Cormorant Garamond', serif;
  font-size: 1.35rem;
  margin: 0;
  color: #e8b554;
}

.admin-email-preview-popup-error {
  color: #f0a8a0;
  font-size: 0.9rem;
  line-height: 1.45;
}

.admin-email-preview-popup-meta {
  font-size: 0.82rem;
  color: #c9963c;
  margin: 0 0 0.75rem;
}

.admin-email-preview-popup-label {
  font-size: 0.7rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: #7a8294;
  margin-bottom: 0.25rem;
}

.admin-email-preview-popup-subject {
  font-size: 0.95rem;
  color: #f0ebe3;
  padding: 0.5rem 0.65rem;
  background: #14161c;
  border-radius: 6px;
  border: 1px solid #2f3238;
  margin-bottom: 0.85rem;
}

.admin-email-preview-popup-body {
  margin: 0;
  padding: 0.65rem 0.75rem;
  background: #14161c;
  border: 1px solid #2f3238;
  border-radius: 6px;
  color: #dcd8d0;
  font-size: 0.85rem;
  line-height: 1.45;
  white-space: pre-wrap;
  word-break: break-word;
  max-height: min(70vh, 520px);
  overflow: auto;
  font-family: 'DM Sans', ui-sans-serif, system-ui, sans-serif;
}

.admin-email-preview-popup-body--html {
  white-space: normal;
  background: #f7f4ed;
  color: #222;
  border-color: #c9c4b8;
}

.admin-email-preview-popup-body--plain {
  margin-top: 0.5rem;
  max-height: min(40vh, 280px);
}

.admin-email-preview-plain-fallback {
  margin-top: 0.65rem;
  font-size: 0.78rem;
  color: #9aa3b5;
}

.admin-email-preview-plain-fallback summary {
  cursor: pointer;
  color: #c9963c;
  margin-bottom: 0.35rem;
}

.admin-email-preview-send-form {
  margin-top: 1.25rem;
  padding-top: 1rem;
  border-top: 1px dashed rgba(255, 255, 255, 0.12);
}

.admin-email-preview-send-field-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: pre-wrap;
  border: 0;
  opacity: 0;
}

.admin-email-preview-confirm {
  margin-top: 0.5rem;
}

.admin-email-merge-panel {
  margin-bottom: 1.25rem;
  padding: 1rem 1.1rem;
  background: rgba(24, 26, 32, 0.65);
  border: 1px solid #3d4048;
  border-radius: 10px;
}

.admin-email-merge-heading {
  font-size: 1.05rem;
  font-weight: 600;
  margin: 0 0 0.75rem;
  color: #e8e4dc;
}

.admin-email-merge-form {
  display: flex;
  flex-direction: column;
  gap: 0.65rem;
  margin-bottom: 0.75rem;
}

.admin-email-merge-row {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
}

.admin-email-merge-row label {
  font-size: 0.8rem;
  color: #9aa3b5;
}

.admin-email-merge-row select {
  max-width: 28rem;
  background: #1c1e24;
  color: #e8e6e1;
  border: 1px solid #3d4048;
  border-radius: 6px;
  padding: 0.45rem 0.6rem;
  font-family: inherit;
  font-size: 0.88rem;
}

.admin-email-merge-hint,
.admin-email-merge-empty {
  font-size: 0.85rem;
  color: #9aa3b5;
  margin: 0;
}

.admin-email-merge-meta {
  font-size: 0.82rem;
  color: #c9963c;
  margin: 0 0 0.5rem;
}

.admin-email-preview-block {
  margin-bottom: 1rem;
}

.admin-email-preview-label {
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: #7a8294;
  margin-bottom: 0.25rem;
}

.admin-email-preview-subject {
  font-size: 0.95rem;
  color: #f0ebe3;
  margin-bottom: 0.75rem;
  padding: 0.5rem 0.65rem;
  background: #14161c;
  border-radius: 6px;
  border: 1px solid #2f3238;
}

.admin-email-preview-body {
  margin: 0;
  padding: 0.65rem 0.75rem;
  background: #14161c;
  border: 1px solid #2f3238;
  border-radius: 6px;
  color: #dcd8d0;
  font-size: 0.82rem;
  line-height: 1.45;
  white-space: pre-wrap;
  word-break: break-word;
  max-height: 16rem;
  overflow: auto;
  font-family: 'DM Sans', ui-sans-serif, system-ui, sans-serif;
}

.admin-email-broadcast-form {
  padding-top: 0.5rem;
  border-top: 1px dashed rgba(255, 255, 255, 0.1);
}

.admin-email-confirm-send {
  display: flex;
  align-items: flex-start;
  gap: 0.5rem;
  font-size: 0.82rem;
  color: #b8c0d0;
  margin-bottom: 0.65rem;
  cursor: pointer;
}

.admin-email-confirm-send input {
  margin-top: 0.15rem;
  accent-color: #c9963c;
}

.admin-email-send-all {
  background: linear-gradient(180deg, #b8892e 0%, #9a7224 100%);
  border: 1px solid #c9963c;
}

.admin-email-tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin: 0 0 1rem;
}
.admin-email-tab {
  color: #e8b554;
  text-decoration: none;
  border: 1px solid #4a4d55;
  border-radius: 999px;
  padding: 0.35rem 0.8rem;
  font-size: 0.88rem;
}
.admin-email-tab.is-active {
  background: rgba(201, 150, 60, 0.2);
  border-color: #c9963c;
  color: #f5d98a;
}
.admin-email-coming-soon {
  font-size: 0.85rem;
  color: #d4d0c8;
  margin-bottom: 0.75rem;
}
.admin-email-form {
  max-width: none;
  margin-bottom: 1rem;
}
.admin-email-body {
  width: 100%;
  background: #1c1e24;
  color: #e8e6e1;
  border: 1px solid #3d4048;
  border-radius: 6px;
  padding: 0.65rem 0.75rem;
  resize: vertical;
  font-family: 'DM Sans', sans-serif;
  line-height: 1.45;
}

/* Email templates draft: same cream panel as preview HTML body */
.admin-email-body.admin-email-body--draft,
.admin-email-body.admin-email-body--sig {
  background: #f7f4ed;
  color: #222;
  border-color: #c9c4b8;
  border-radius: 8px;
  color-scheme: light;
}

.admin-email-hint {
  margin-top: -0.2rem;
  margin-bottom: 0.6rem;
  font-size: 0.8rem;
  color: #8a8580;
}
.admin-email-attachment-list {
  max-width: none;
  border-top: 1px solid #3d4048;
  padding-top: 0.75rem;
}

.admin-email-card-right h3 {
  margin: 0 0 0.35rem;
}

.admin-email-client-count {
  color: #c9963c;
  margin: 0 0 0.75rem;
  font-size: 0.82rem;
}

.admin-email-client-list {
  margin: 0;
  padding: 0;
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 0.45rem;
  max-height: 34rem;
  overflow: auto;
}

.admin-email-client-list li {
  display: flex;
  flex-direction: column;
  gap: 0.1rem;
  padding: 0.45rem 0.5rem;
  border-radius: 6px;
  background: rgba(20, 22, 28, 0.7);
  border: 1px solid #2f3238;
}

.admin-email-client-list strong {
  color: #ece6da;
  font-size: 0.84rem;
  line-height: 1.3;
}

.admin-email-client-list span {
  color: #aab2c2;
  font-size: 0.8rem;
  word-break: break-word;
}
.admin-email-attachment-list h3 {
  font-size: 1rem;
  margin-bottom: 0.5rem;
}
.admin-email-attachment-list ul {
  list-style: none;
  padding: 0;
  margin: 0;
}
.admin-email-attachment-list li {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  align-items: center;
  padding: 0.4rem 0;
  border-bottom: 1px dashed rgba(255, 255, 255, 0.08);
}

/* Email templates: one viewport, overflow hidden; scroll inside panels only */
body.admin-email-templates-page {
  min-height: calc(100vh - var(--site-footer-safe));
  min-height: calc(100dvh - var(--site-footer-safe));
  overflow: hidden;
}

body.admin-email-templates-page .container.admin-console.admin-email-templates-shell {
  max-width: none;
  width: calc(100vw - 2rem);
  margin: 1rem auto;
  max-height: calc(100vh - 2rem - var(--site-footer-safe));
  height: calc(100vh - 2rem - var(--site-footer-safe));
  max-height: calc(100dvh - 2rem - var(--site-footer-safe));
  height: calc(100dvh - 2rem - var(--site-footer-safe));
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

body.admin-email-templates-page .container.admin-console .top-bar {
  flex-shrink: 0;
  overflow: visible;
}

body.admin-email-templates-page .admin-email-templates-content {
  flex: 1 1 auto;
  min-height: 0;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  padding: 0.75rem 1rem 0.85rem;
}

body.admin-email-templates-page .admin-email-layout-grid {
  flex: 1 1 auto;
  min-height: 0;
  overflow: hidden;
  align-items: stretch;
}

body.admin-email-templates-page .admin-email-card-left {
  min-height: 0;
  overflow: auto;
}

body.admin-email-templates-page .admin-email-card-middle {
  min-height: 0;
  overflow-x: hidden;
  overflow-y: auto;
}

body.admin-email-templates-page .admin-email-card-right {
  min-height: 0;
  overflow: hidden;
}

.admin-email-page-title {
  position: absolute;
  left: 50%;
  transform: translateX(-50%);
  font-family: 'Cormorant Garamond', serif;
  font-size: 1.35rem;
  font-weight: 600;
  letter-spacing: 0.06em;
  color: #f0e6d4;
  text-transform: uppercase;
  pointer-events: none;
}

@media (max-width: 720px) {
  .admin-email-layout-grid {
    grid-template-columns: 1fr;
  }
  .admin-email-page-title {
    position: static;
    transform: none;
    width: 100%;
    text-align: left;
    margin-top: 0.4rem;
    font-size: 1.05rem;
  }
}

/* User rights: avoid clipping on narrow / short viewports (container & top-bar use overflow:hidden) */
body.admin-user-rights-page {
  overflow-x: auto;
  overflow-y: auto;
}

body.admin-user-rights-page .container.admin-console {
  overflow: visible;
}

body.admin-user-rights-page .container.admin-console .top-bar {
  overflow: visible;
}

@media (max-width: 768px) {
  body.admin-user-rights-page .container.admin-console {
    margin: 1rem max(0.75rem, env(safe-area-inset-right)) 1.5rem
      max(0.75rem, env(safe-area-inset-left));
    max-width: none;
    width: auto;
  }

  body.admin-user-rights-page .container.admin-console .top-bar {
    flex-wrap: wrap;
    align-items: flex-start;
    row-gap: 0.75rem;
    padding: 1rem 1rem;
  }

  body.admin-user-rights-page .container.admin-console .top-bar > div:first-child {
    min-width: 0;
    flex: 1 1 12rem;
  }

  body.admin-user-rights-page .container.admin-console .top-bar .brand {
    font-size: clamp(1.1rem, 4.5vw, 1.6rem);
    letter-spacing: 0.08em;
  }

  body.admin-user-rights-page .container.admin-console .top-bar .session-info {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: flex-end;
    gap: 0.35rem 0.85rem;
    max-width: 100%;
    flex: 1 1 auto;
  }

  body.admin-user-rights-page .admin-content {
    padding: 1.25rem 1rem 1.75rem;
  }

  /* Let the document scroll so intro, table, and Save stay reachable */
  body.admin-user-rights-page .admin-user-rights-scroll {
    max-height: none;
    overflow-y: visible;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
  }

  body.admin-user-rights-page .admin-user-rights-actions {
    padding-bottom: max(1rem, env(safe-area-inset-bottom));
  }
}

/* Admin auction path inputs: match \"Your bid\" background/contrast */
.container.admin-console input[type="text"][id^="path_"] {
  background: var(--obsidian);
  border: 1px solid var(--obsidian-border);
  color: var(--pearl);
  padding: 0.6rem 0.85rem;
  line-height: 1.5;
}

.btn-sm {
  width: auto;
  margin-top: 0;
  padding: 0.55rem 1.4rem;
  font-size: 0.8rem;
  box-shadow: 0 3px 14px rgba(201, 150, 60, 0.3);
}

.admin-progress {
  align-items: center;
  gap: 0.6rem;
}
.admin-progress-bar {
  width: 80px;
  height: 4px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.08);
  overflow: hidden;
  position: relative;
}
.admin-progress-bar::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, transparent, var(--gold-bright), transparent);
  animation: admin-progress-pulse 1.1s infinite;
}
.admin-progress-text {
  font-size: 0.78rem;
  color: #e8b554;
}

@keyframes admin-progress-pulse {
  0% { transform: translateX(-100%); }
  50% { transform: translateX(0%); }
  100% { transform: translateX(100%); }
}

/* ─── Legacy / Utility ───────────────────────────────────────────────── */
form { display: flex; flex-direction: column; gap: 1rem; }
input, select, button { font-size: 0.95rem; }

/* Two auctions: label + first on row 1, second indented to same start on row 2 */
.auction-info-two {
  display: flex;
  flex-direction: column;
  gap: 0.18rem;
  margin-bottom: 0.25rem;
}
.auction-info-row {
  display: flex;
  align-items: baseline;
  gap: 0.45rem;
}
.auction-info-label {
  font-size: 0.75rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--pearl);
  white-space: nowrap;
  flex-shrink: 0;
}
/* Invisible spacer on row 2 — label width + gap + one extra space */
.auction-info-indent {
  display: inline-block;
  width: calc(7.5em + 0.45rem + 1em);
  flex-shrink: 0;
}
.auction-info-two .auction-option {
  font-size: 0.92rem;
}
.auction-info-two .auction-sep {
  color: var(--pearl-muted);
  font-size: 0.82rem;
  flex-shrink: 0;
}

/* ─────────────────────────────────────────────────────────────────────
   LOT MEDIA PANEL (side drawer)
   ───────────────────────────────────────────────────────────────────── */
.lot-panel {
  display: none;
  position: fixed;
  inset: 0;
  z-index: 1000;
}
.lot-panel.open { display: block; }

.lot-panel-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.65);
  backdrop-filter: blur(3px);
  -webkit-backdrop-filter: blur(3px);
  animation: backdrop-in 0.25s ease;
}
@keyframes backdrop-in {
  from { opacity: 0; }
  to   { opacity: 1; }
}

.lot-panel-drawer {
  position: absolute;
  top: 0; right: 0; bottom: 0;
  width: 380px;
  max-width: 92vw;
  background: var(--obsidian-mid);
  border-left: 1px solid var(--gold-border);
  display: flex;
  flex-direction: column;
  box-shadow: -8px 0 48px rgba(0,0,0,0.7), -1px 0 0 rgba(201,150,60,0.1);
  animation: drawer-in 0.28s cubic-bezier(0.22, 1, 0.36, 1);
}
@keyframes drawer-in {
  from { transform: translateX(100%); opacity: 0.5; }
  to   { transform: translateX(0);    opacity: 1; }
}

.lot-panel-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1.25rem 1.5rem;
  background: var(--obsidian);
  border-bottom: 1px solid var(--gold-border);
  position: relative;
}
.lot-panel-header::after {
  content: '';
  position: absolute;
  bottom: 0; left: 0; right: 0;
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--gold), transparent);
}

.lot-panel-title-block {
  display: flex;
  align-items: baseline;
  gap: 0.6rem;
}
.lot-panel-label {
  font-size: 0.65rem;
  font-weight: 700;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--pearl-muted);
}
.lot-panel-name {
  font-family: 'Cormorant Garamond', serif;
  font-size: 1.4rem;
  font-weight: 600;
  color: var(--gold-bright);
  letter-spacing: 0.06em;
}

.lot-panel-close {
  background: none;
  border: 1px solid var(--obsidian-border);
  color: var(--pearl-dim);
  border-radius: 6px;
  width: 2rem;
  height: 2rem;
  font-size: 1.2rem;
  line-height: 1;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.15s;
  padding: 0;
}
.lot-panel-close:hover {
  border-color: var(--gold-border);
  color: var(--gold-bright);
  background: var(--gold-glow);
}

.lot-panel-body {
  flex: 1;
  overflow-y: auto;
  padding: 1.5rem;
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
}

.lot-panel-folder-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.6rem;
  padding: 0.75rem 1rem;
  background: var(--gold-glow);
  border: 1px solid var(--gold-border);
  border-radius: var(--radius);
  color: var(--gold-bright);
  font-size: 0.85rem;
  font-weight: 600;
  text-decoration: none;
  letter-spacing: 0.03em;
  transition: all 0.18s;
}
.lot-panel-folder-btn:hover {
  background: rgba(201,150,60,0.28);
  border-color: var(--gold);
  transform: translateY(-1px);
  box-shadow: 0 4px 16px rgba(201,150,60,0.2);
}

.lot-panel-details {
  margin-top: 0.5rem;
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
  font-size: 0.82rem;
  color: var(--pearl);
}
.lot-panel-details h2 {
  font-size: 0.9rem;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  color: var(--pearl-dim);
  margin-bottom: 0.15rem;
}
.lot-detail-row {
  display: flex;
  gap: 0.35rem;
}
.lot-detail-label {
  min-width: 80px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--pearl-muted);
}
.lot-detail-value {
  flex: 1;
}

/* ─── Page & layout: full viewport height, no body scroll ────────── */
html, body {
  height: 100%;
  overflow: hidden;
}

/* ─── Bid Page Header + Three-card Layout ────────────────────────── */
.bid-page {
  height: calc(100vh - var(--site-footer-safe));
  height: calc(100dvh - var(--site-footer-safe));
  padding: 0.85rem 1.15rem 0.35rem;
  box-sizing: border-box;
  display: flex;
  flex-direction: column;
  gap: 0.55rem;
}

.bid-page-header {
  background: linear-gradient(150deg, rgba(20,23,32,0.95) 0%, rgba(14,17,25,0.98) 100%);
  border: 1px solid var(--gold-border);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-deep), var(--shadow-gold);
  display: grid;
  grid-template-columns: minmax(240px, 1fr) minmax(280px, 1.2fr) minmax(240px, 1fr);
  align-items: center;
  column-gap: 1rem;
  padding: 1.05rem 1.5rem;
  min-height: 86px;
}
.bph-left { justify-self: start; }
.bph-left .bph-brand {
  font-size: 1.9rem;
  color: var(--gold-pale);
  letter-spacing: 0.08em;
  font-family: 'Cormorant Garamond', serif;
  font-weight: 600;
  line-height: 1.05;
}
.bph-left .bph-sub {
  margin-top: 0.15rem;
  font-size: 0.78rem;
  letter-spacing: 0.24em;
  text-transform: uppercase;
  color: var(--pearl-dim);
}
.admin-bid-entry-page .ic-admin-back-link {
  display: inline-block;
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--gold-bright);
  text-decoration: none;
}
.admin-bid-entry-page .ic-admin-back-link:hover {
  color: var(--gold-pale);
  text-decoration: underline;
}
.admin-bid-entry-page .ic-admin-logout-link {
  display: inline-block;
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--pearl-muted);
  text-decoration: none;
}
.admin-bid-entry-page .ic-admin-logout-link:hover {
  color: var(--gold-pale);
  text-decoration: underline;
}
.admin-bid-entry-page .bph-admin-user-name {
  font-size: 0.95rem;
  font-weight: 600;
  color: var(--pearl);
  letter-spacing: 0.02em;
  line-height: 1.2;
}
.admin-bid-entry-layout {
  display: flex;
  justify-content: center;
  padding: 1rem 0 2rem;
}
.admin-bid-entry-page .admin-bid-entry-card {
  max-width: 420px;
  width: 100%;
}
.admin-client-load-blocker {
  position: fixed;
  inset: 0;
  z-index: 99999;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(10, 12, 18, 0.58);
  cursor: wait;
  pointer-events: auto;
}
.admin-client-load-blocker__label {
  font-size: 0.82rem;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--gold-pale);
}
.bph-center {
  text-align: center;
}
.bph-auction-name {
  font-family: 'DM Mono', monospace;
  font-size: 1.04rem;
  font-weight: 500;
  letter-spacing: 0.02em;
  text-transform: uppercase;
  color: var(--gold-pale);
  line-height: 1.22;
}
.bph-auction-dates {
  margin-top: 0.18rem;
  font-size: 0.72rem;
  letter-spacing: 0.09em;
  text-transform: uppercase;
  color: var(--pearl-muted);
}
.bph-right {
  justify-self: end;
  text-align: right;
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 0.35rem;
}
.bph-client-name {
  font-family: 'Cormorant Garamond', serif;
  font-size: 1.25rem;
  font-weight: 600;
  color: var(--pearl);
  letter-spacing: 0.02em;
}
/* Client bid sheet: match admin header right (user line weight/size) */
.client-bid-entry-page .bph-client-name {
  font-family: 'DM Sans', sans-serif;
  font-size: 0.95rem;
  font-weight: 600;
  color: var(--pearl);
  letter-spacing: 0.02em;
  line-height: 1.2;
}
.bph-client-tag {
  display: inline-block;
  margin-top: 0.4rem;
  font-size: 0.82rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--gold);
  background: var(--gold-glow);
  border: 1px solid var(--gold-border);
  border-radius: 4px;
  padding: 0.2rem 0.65rem;
}
.client-bid-entry-page .bph-client-tag {
  margin-top: 0;
  font-size: 0.72rem;
  letter-spacing: 0.12em;
}

.bid-layout {
  display: grid;
  /* Card 1: 360px; card 2: 45%; card 3: remainder, min +20 vs 260px floor */
  grid-template-columns: 360px 45% minmax(280px, 1fr);
  gap: 1.15rem;
  flex: 1;
  min-height: 0;
}
/* Let grid columns shrink without forcing horizontal page/card scrollbars */
.bid-layout > .info-card,
.bid-layout > .bid-card,
.bid-layout > .lot-detail-card {
  min-width: 0;
}

/*
 * Client bid sheet: info column capped on wide viewports; center:right fr split (~1.265 : 1.385) tilts slightly to bid sheet vs image.
 * Left track uses min(max(%), rem) so it scales on mid widths but does not grow without bound on huge screens.
 */
.client-bid-entry-page .bid-layout {
  grid-template-columns: min(24rem, max(17.25rem, 25.5%)) minmax(0, 1.265fr) minmax(15rem, 1.385fr);
  gap: 1.1rem;
}

/* Client bid sheet: denser type in center (bid) + right (lot detail) cards */
.client-bid-entry-page .bid-card .bc-tender-label {
  font-size: 0.7rem;
}
.client-bid-entry-page .bid-card .bc-top-bar .tender-pill {
  font-size: 0.78rem;
  padding: 0.32rem 0.95rem;
}
.client-bid-entry-page .bid-card .bc-deadline-chip {
  font-size: 0.7rem;
  padding: 0.32rem 0.72rem;
}
.client-bid-entry-page .bid-card .lot-table th {
  padding: 0.62rem 0.8rem;
  font-size: 0.7rem;
}
.client-bid-entry-page .bid-card .lot-table td {
  padding: 0.55rem 0.8rem;
  font-size: 0.84rem;
}
.client-bid-entry-page .bid-card .lot-table td:first-child {
  font-size: 0.84rem;
}
.client-bid-entry-page .bid-card .lot-table td:last-child {
  font-size: 0.88rem;
}
.client-bid-entry-page .bid-card .lot-table input[type="text"][name^="bid_"] {
  width: 118px;
  padding: 0.42rem 0.6rem;
  font-size: 0.88rem;
}
.client-bid-entry-page .bid-card .lot-name-btn {
  font-size: 0.84rem;
}
.client-bid-entry-page .bid-card .field-error {
  font-size: 0.68rem;
}
.client-bid-entry-page .bid-card .bc-messages .message {
  font-size: 0.8rem;
  padding: 0.55rem 0.85rem;
}

.client-bid-entry-page .lot-detail-card .ldc-empty-icon {
  font-size: 1.65rem;
}
.client-bid-entry-page .lot-detail-card .ldc-empty-text {
  font-size: 0.66rem;
}
.client-bid-entry-page .lot-detail-card .ldc-img-loader,
.client-bid-entry-page .lot-detail-card .ldc-no-img {
  font-size: 0.68rem;
}
.client-bid-entry-page .lot-detail-card .ldc-eyebrow {
  font-size: 0.64rem;
}
.client-bid-entry-page .lot-detail-card .ldc-lot-name {
  font-size: 1.18rem;
}
.client-bid-entry-page .lot-detail-card .ldc-field-row dt {
  font-size: 0.58rem;
}
.client-bid-entry-page .lot-detail-card .ldc-field-row dd {
  font-size: 0.72rem;
}
.client-bid-entry-page .lot-detail-card .ldc-no-details {
  font-size: 0.6rem;
}
.client-bid-entry-page .lot-detail-card .ldc-sizes-label {
  font-size: 0.52rem;
}
.client-bid-entry-page .lot-detail-card .ldc-sizes-table th {
  font-size: 0.48rem;
  padding: 0.16rem 0.2rem;
}
.client-bid-entry-page .lot-detail-card .ldc-sizes-table td {
  font-size: 0.58rem;
  padding: 0.12rem 0.16rem;
}
.client-bid-entry-page .lot-detail-card .ldc-dropbox-btn {
  font-size: 0.62rem;
  padding: 0.48rem 0.65rem;
}
.client-bid-entry-page .lot-detail-card .ldc-dropbox-hint {
  font-size: 0.54rem;
}

/* User-role admin: no lot detail; Your Bids (+ submit while open) in right column */
.admin-bid-simple-entry .bid-layout > .admin-bid-actions-card {
  display: flex;
  flex-direction: column;
  min-height: 0;
}
.admin-bid-simple-entry .admin-bid-actions-card .ic-action-bar {
  margin-top: 0;
  flex: 1;
  min-height: 0;
  border-top: none;
  padding: 1rem 1.25rem 1.3rem;
  height: 100%;
}
.admin-bid-simple-entry .admin-bid-actions-card .ic-bid-summary {
  flex: 1;
  min-height: 0;
  display: flex;
  flex-direction: column;
}
.admin-bid-simple-entry .admin-bid-actions-card .ic-summary-list {
  flex: 1;
  min-height: 160px;
  max-height: none;
}

/* ══ Info Card (left sidebar) ══════════════════════════════════════ */
.info-card {
  background: var(--obsidian-mid);
  border: 1px solid var(--obsidian-border);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-deep), var(--shadow-gold);
  overflow-y: auto;
  overflow-x: hidden;
  display: flex;
  flex-direction: column;
  height: 100%;
}

/* Brand block */
.ic-brand {
  padding: 2rem 2rem 1.5rem;
  background: linear-gradient(150deg, rgba(20,23,32,0.95) 0%, rgba(14,17,25,0.98) 100%);
  border-bottom: 1px solid var(--gold-border);
  position: relative;
  flex-shrink: 0;
}
.ic-brand::after {
  content: '';
  position: absolute;
  bottom: 0; left: 0; right: 0;
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--gold), transparent);
}
.ic-brand .brand     { font-size: 1.9rem; }
.ic-brand .brand-sub { font-size: 0.78rem; margin-top: 0.15rem; }

/* Client block */
.ic-client {
  padding: 1.1rem 2rem;
  background: rgba(255,255,255,0.02);
  border-bottom: 1px solid var(--obsidian-border);
  flex-shrink: 0;
}
.ic-client-name {
  font-family: 'Cormorant Garamond', serif;
  font-size: 1.25rem;
  font-weight: 600;
  color: var(--pearl);
  letter-spacing: 0.02em;
}
.ic-client-tag {
  display: inline-block;
  margin-top: 0.4rem;
  font-size: 0.82rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--gold);
  background: var(--gold-glow);
  border: 1px solid var(--gold-border);
  border-radius: 4px;
  padding: 0.2rem 0.65rem;
}

/* Divider */
.ic-divider {
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--obsidian-border), transparent);
  flex-shrink: 0;
}

/* Auction + schedule combined box (styled like ic-client) */
.ic-auction-box {
  margin: 1rem 1.5rem;
  padding: 1rem 1.25rem 1.1rem;
  background: rgba(255,255,255,0.03);
  border: 1px solid var(--obsidian-border);
  border-radius: var(--radius);
  flex-shrink: 0;
}
.ic-auction-label {
  font-size: 0.64rem;
  font-weight: 700;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--pearl-muted);
  margin-bottom: 0.35rem;
}
.ic-auction-name {
  font-family: 'DM Mono', monospace;
  font-size: 1.12rem;
  font-weight: 500;
  font-style: normal;
  color: var(--gold-pale);
  letter-spacing: 0.03em;
  text-transform: uppercase;
  line-height: 1.32;
}
.ic-auction-dates {
  margin-top: 0.35rem;
  font-size: 0.75rem;
  color: var(--pearl-muted);
  letter-spacing: 0.04em;
  text-transform: uppercase;
}
.ic-auction-schedule {
  margin-top: 0.5rem;
  padding-top: 0.5rem;
  border-top: 1px solid var(--obsidian-border);
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
}
.ic-schedule-line {
  display: flex;
  align-items: flex-start;
  gap: 0.45rem;
  font-size: 0.78rem;
  color: var(--pearl-muted);
  line-height: 1.3;
}
.ic-schedule-dot {
  display: inline-block;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--obsidian-border);
  flex-shrink: 0;
  margin-top: 0.42em;
}
.ic-schedule-active {
  color: var(--gold-bright);
  font-weight: 600;
}
.ic-schedule-active .ic-schedule-dot {
  background: var(--gold-bright);
  box-shadow: 0 0 7px var(--gold-glow);
}

/* Switcher section */
.ic-section {
  padding: 0.75rem 1.5rem;
  flex-shrink: 0;
}
.ic-section-label {
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--pearl-muted);
  margin-bottom: 0.6rem;
}

/* Admin bid entry — left card (dark inputs + split picker / selected) */
.ic-admin-bid-entry {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}
.ic-admin-picker {
  padding: 0.85rem 1rem;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid var(--obsidian-border);
  border-radius: var(--radius);
}
.ic-admin-picker .ic-section-label {
  margin-bottom: 0.55rem;
}
.ic-admin-picker-form {
  display: grid;
  gap: 0.45rem;
}
.ic-admin-picker-form label {
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--pearl-muted);
}
.ic-admin-picker-form input[type="text"] {
  width: 100%;
  padding: 0.5rem 0.7rem;
  background: var(--obsidian);
  border: 1px solid var(--obsidian-border);
  border-radius: var(--radius);
  color: var(--pearl);
  font-family: 'Inter', sans-serif;
  font-size: 0.92rem;
  transition: border-color 0.2s, box-shadow 0.2s, background 0.2s;
}
.ic-admin-picker-form input[type="text"]::placeholder {
  color: var(--pearl-muted);
  opacity: 0.88;
}
.ic-admin-picker-form input[type="text"]:hover {
  border-color: var(--gold-border);
}
.ic-admin-picker-form input[type="text"]:focus {
  outline: none;
  border-color: var(--gold);
  background: rgba(201, 150, 60, 0.06);
  box-shadow: 0 0 0 3px rgba(201, 150, 60, 0.12);
}
.ic-admin-picker-submit {
  margin-top: 0.35rem;
}

.ic-admin-selected {
  padding: 0.85rem 1rem;
  background: rgba(201, 150, 60, 0.07);
  border: 1px solid var(--gold-border);
  border-radius: var(--radius);
}
.ic-admin-selected .ic-section-label {
  margin-bottom: 0.5rem;
  color: var(--gold-bright);
  letter-spacing: 0.16em;
}
.ic-admin-selected-body {
  display: flex;
  flex-direction: column;
  gap: 0.55rem;
}
.ic-admin-selected-row {
  display: flex;
  flex-direction: column;
  gap: 0.2rem;
}
.ic-admin-selected-label {
  font-size: 0.64rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--pearl-muted);
}
.ic-admin-selected-value {
  font-family: 'DM Mono', monospace;
  font-size: 0.95rem;
  color: var(--gold-pale);
  word-break: break-word;
  line-height: 1.35;
}

.ic-switcher {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}

/* Rules */
.ic-rules {
  padding: 0.8rem 1.5rem 0.9rem;
  display: flex;
  flex-direction: column;
  gap: 0.65rem;
  flex-shrink: 0;
}
.ic-tender-notes {
  display: flex;
  flex-direction: column;
  gap: 0.3rem;
}
.ic-tender-line {
  display: flex;
  align-items: flex-start;
  gap: 0.45rem;
  font-size: 0.76rem;
  line-height: 1.35;
  color: var(--pearl-dim);
}
.ic-tender-icon {
  font-size: 0.8rem;
  flex-shrink: 0;
  margin-top: 0.05em;
  color: var(--gold-bright);
}
.ic-tender-line.active {
  color: var(--gold-bright);
  font-weight: 600;
}
.ic-tender-line.active .ic-tender-icon {
  color: var(--gold-pale);
}
.ic-rule-item {
  display: flex;
  align-items: flex-start;
  gap: 0.45rem;
  font-size: 0.76rem;
  color: var(--pearl-dim);
  line-height: 1.35;
}
.ic-rule-icon {
  font-size: 0.8rem;
  flex-shrink: 0;
  margin-top: 0.05em;
  color: var(--gold-bright);
}
.ic-rule-item strong { color: var(--pearl); font-weight: 600; }
.ic-email {
  color: var(--gold-bright);
  text-decoration: none;
  border-bottom: 1px solid var(--gold-border);
  white-space: nowrap;
}
.ic-email:hover { border-color: var(--gold); color: var(--gold-pale); }

/* Client bid sheet: left column matches admin (ic-admin-bid-entry + bordered panel) */
.client-bid-entry-page .client-bid-sidebar-panel .ic-section-label {
  margin-bottom: 0.55rem;
}
.client-bid-entry-page .client-bid-sidebar-panel .ic-tender-notes {
  margin-bottom: 0.1rem;
}
.client-bid-entry-page .client-bid-sidebar-contact--separated {
  margin-top: 0.65rem;
  padding-top: 0.65rem;
  border-top: 1px solid var(--obsidian-border);
}
.client-bid-entry-page .client-bid-sidebar-panel .ic-tender-line {
  font-size: 0.72rem;
  line-height: 1.42;
  letter-spacing: 0.02em;
}
.client-bid-entry-page .client-bid-sidebar-panel .ic-rule-item {
  font-size: 0.72rem;
  line-height: 1.45;
}
.client-bid-entry-page .ic-closed {
  margin-left: 1.5rem;
  margin-right: 1.5rem;
}

/* Messages + closed */
.ic-messages { padding: 0 2rem 0.5rem; flex-shrink: 0; }
.ic-messages .message { margin-bottom: 0.4rem; }
.ic-closed { margin: 0 2rem 1.5rem; }

.ic-action-bar {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  padding: 1rem 1.5rem 1.3rem;
  margin-top: auto;
  border-top: 1px solid var(--obsidian-border);
}
.ic-action-bar--closed-tender {
  padding-bottom: 1.05rem;
}

/* Bid summary panel */
.ic-bid-summary {
  width: 100%;
  flex: 1;
  min-height: 0;
}
.ic-summary-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 0.5rem;
}
.ic-summary-title {
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--pearl-dim);
}
.ic-summary-count {
  font-size: 0.82rem;
  font-weight: 700;
  color: #7CFFB2;
  background: rgba(28, 122, 74, 0.24);
  border: 1px solid rgba(124, 255, 178, 0.35);
  border-radius: 999px;
  padding: 0.1rem 0.5rem;
  min-width: 1.4rem;
  text-align: center;
}
.ic-summary-list {
  max-height: 340px;
  min-height: 220px;
  overflow-y: auto;
  border: 1px solid var(--obsidian-border);
  border-radius: var(--radius);
  background: rgba(0, 0, 0, 0.2);
}
.ic-summary-empty {
  padding: 0.6rem 0.75rem;
  font-size: 0.72rem;
  color: var(--pearl-muted);
  text-align: center;
}
.ic-summary-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0.3rem 0.75rem;
  font-size: 0.75rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.04);
}
.ic-summary-row:last-child { border-bottom: none; }
.ic-summary-row:nth-child(odd) {
  background: rgba(255, 255, 255, 0.02);
}
.ic-summary-row:nth-child(even) {
  background: rgba(0, 0, 0, 0.15);
}
.ic-summary-lot {
  color: var(--pearl);
  font-weight: 600;
  cursor: pointer;
}
.ic-summary-lot:hover {
  color: var(--gold-bright);
  text-decoration: underline;
}
.ic-summary-amt {
  color: var(--gold-bright);
  font-weight: 700;
  font-variant-numeric: tabular-nums;
  display: flex;
  align-items: center;
  gap: 0.4rem;
}
.ic-summary-badge {
  font-size: 0.55rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  color: #5dd6a0;
  background: rgba(26, 107, 74, 0.2);
  border: 1px solid rgba(26, 107, 74, 0.35);
  border-radius: 3px;
  padding: 0.05rem 0.3rem;
}
.ic-badge-edited {
  color: #7ab8f5;
  background: rgba(26, 74, 138, 0.2);
  border-color: rgba(26, 74, 138, 0.4);
}

/* Confirmation modal */
.bid-confirm-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.7);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 1000;
  backdrop-filter: blur(4px);
}
.bid-confirm-modal {
  background: var(--obsidian-mid);
  border: 1px solid var(--gold-border);
  border-radius: var(--radius-lg);
  box-shadow: 0 24px 80px rgba(0, 0, 0, 0.6), 0 0 40px rgba(201, 150, 60, 0.12);
  width: 420px;
  max-height: 80vh;
  display: flex;
  flex-direction: column;
  overflow: hidden;
}
.bid-confirm-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 1rem 1.25rem;
  border-bottom: 1px solid var(--gold-border);
  background: rgba(201, 150, 60, 0.05);
  font-size: 0.85rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--gold-bright);
}
.bid-confirm-close {
  background: none;
  border: none;
  color: var(--pearl-muted);
  font-size: 1.3rem;
  cursor: pointer;
  padding: 0 0.2rem;
  line-height: 1;
}
.bid-confirm-close:hover { color: var(--pearl); }
.bid-confirm-body {
  padding: 1rem 1.25rem;
  overflow-y: auto;
  flex: 1;
}
.bid-confirm-intro {
  font-size: 0.8rem;
  color: var(--pearl-dim);
  margin-bottom: 0.25rem;
}
.bid-confirm-note {
  font-size: 0.7rem;
  color: var(--pearl-muted);
  margin-bottom: 0.75rem;
  font-style: italic;
}
.bid-confirm-table {
  width: auto;
  border-collapse: collapse;
  margin: 0 auto;
}
.bid-confirm-table th {
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--pearl-muted);
  padding: 0.4rem 0.5rem;
  text-align: left;
  border-bottom: 1px solid var(--obsidian-border);
}
.bid-confirm-table th:first-child,
.bid-confirm-table td:first-child { padding-right: 3rem; }
.bid-confirm-table td {
  padding: 0.45rem 0.5rem;
  font-size: 0.85rem;
  color: var(--pearl);
  font-weight: 600;
  border-bottom: 1px solid rgba(255, 255, 255, 0.04);
}
.bid-confirm-table td:last-child {
  color: var(--gold-bright);
  font-weight: 700;
  text-align: right;
}
.bid-confirm-table tbody tr:nth-child(odd) td {
  background: rgba(255, 255, 255, 0.02);
}
.bid-confirm-table tbody tr:nth-child(even) td {
  background: rgba(0, 0, 0, 0.15);
}
.bid-confirm-footer {
  display: flex;
  gap: 0.75rem;
  padding: 1rem 1.25rem;
  border-top: 1px solid var(--obsidian-border);
}
.bid-confirm-btn {
  flex: 1;
  padding: 0.65rem 1rem;
  border-radius: var(--radius);
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  cursor: pointer;
  border: 1px solid;
  transition: all 0.15s;
}
.bid-confirm-btn.cancel {
  background: transparent;
  border-color: var(--obsidian-border);
  color: var(--pearl-dim);
}
.bid-confirm-btn.cancel:hover {
  background: rgba(255, 255, 255, 0.05);
  color: var(--pearl);
}
.bid-confirm-btn.confirm {
  background: linear-gradient(135deg, var(--gold-deep), var(--gold-bright));
  border-color: var(--gold);
  color: var(--obsidian);
  box-shadow: 0 4px 16px rgba(201, 150, 60, 0.3);
}
.bid-confirm-btn.confirm:hover {
  box-shadow: 0 6px 24px rgba(201, 150, 60, 0.45);
  transform: translateY(-1px);
}

/* Submitting overlay */
.submit-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.8);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 2000;
  backdrop-filter: blur(6px);
}
.submit-overlay-content {
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1rem;
}
.submit-spinner {
  width: 40px;
  height: 40px;
  border: 3px solid rgba(201, 150, 60, 0.2);
  border-top-color: var(--gold-bright);
  border-radius: 50%;
  animation: submit-spin 0.8s linear infinite;
}
@keyframes submit-spin {
  to { transform: rotate(360deg); }
}
.submit-overlay-text {
  font-size: 1.1rem;
  font-weight: 600;
  color: var(--gold-bright);
  letter-spacing: 0.04em;
}
.submit-overlay-sub {
  font-size: 0.78rem;
  color: var(--pearl-muted);
}

.ic-action-box {
  width: 100%;
  padding: 1rem;
  border-radius: var(--radius);
  border: 1px solid var(--gold-border);
  background: rgba(201, 150, 60, 0.04);
  box-shadow: 0 0 20px rgba(201, 150, 60, 0.08);
  animation: ic-action-glow 3s ease-in-out infinite;
}
@keyframes ic-action-glow {
  0%, 100% { border-color: var(--gold-border); box-shadow: 0 0 12px rgba(201, 150, 60, 0.06); }
  50%      { border-color: var(--gold); box-shadow: 0 0 24px rgba(201, 150, 60, 0.15); }
}
.ic-action-box .submit-btn {
  width: 100%;
  margin-top: 0;
  text-align: center;
}

/* ══ Bid Card (right) ═══════════════════════════════════════════════ */
.bid-card {
  background: var(--obsidian-mid);
  border: 1px solid var(--obsidian-border);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-deep), var(--shadow-gold);
  display: flex;
  flex-direction: column;
  height: 100%;
  overflow: hidden;
}

/* Top bar: tender pills + submit button side by side, always visible */
.bc-top-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 0.85rem 1.5rem;
  background: rgba(201,150,60,0.05);
  border-bottom: 1px solid rgba(201,150,60,0.2);
  flex-shrink: 0;
}
.bc-tender-bar {
  display: flex;
  align-items: center;
  gap: 0.85rem;
}
.bc-tender-label {
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--pearl-dim);
  flex-shrink: 0;
}
.bc-top-bar .tender-toggle { margin: 0; }
.bc-top-bar .tender-pill {
  font-size: 0.88rem;
  padding: 0.4rem 1.1rem;
}
/* Deadline chip inside the bid card top bar */
.bc-deadline-chip {
  flex-shrink: 0;
  font-size: 0.78rem;
  padding: 0.38rem 0.85rem;
}

/* Submit button in top bar: compact but clear */
.bc-top-bar .submit-btn {
  margin-top: 0;
  padding: 0.55rem 1.6rem;
  font-size: 0.82rem;
  align-self: auto;
  white-space: nowrap;
  flex-shrink: 0;
}

.bc-messages {
  padding: 0.75rem 1.5rem 0;
  flex-shrink: 0;
}
.bc-messages .message { margin-bottom: 0.4rem; white-space: pre-line; }
.bc-no-bids-msg {
  padding: 0.6rem 1rem;
  border-radius: var(--radius);
  font-size: 0.82rem;
  font-weight: 500;
  color: var(--gold-bright);
  background: rgba(201, 150, 60, 0.1);
  border: 1px solid var(--gold-border);
  margin-bottom: 0.4rem;
}

/* Scrollable table wrapper */
.bc-table-scroll {
  flex: 1;
  overflow-y: auto;
  overflow-x: hidden;
}

/* Sticky table header */
.lot-table thead th {
  position: sticky;
  top: 0;
  z-index: 10;
  background: #0e1119;
  border-bottom: 1px solid var(--gold-border);
  will-change: transform;
}

#bid-form {
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 0;
  min-height: 100%;
}
.bid-card .lot-table {
  margin-top: 0;
  border-radius: 0;
  border: none;
  box-shadow: none;
}
/* Center “Current bid” column on client + admin bid sheets (matches admin layout) */
.bid-card .lot-table th.current-bid-col,
.bid-card .lot-table td.current-bid-col {
  text-align: center;
}
.admin-bid-entry-page .lot-table th.highest-bid-col,
.admin-bid-entry-page .lot-table td.highest-bid-col {
  text-align: center;
}
.admin-bid-entry-page .highest-bid-check {
  -webkit-appearance: none;
  appearance: none;
  border: 1px solid #788095;
  border-radius: 3px;
  background: #f1f3f7;
  width: 15px;
  height: 15px;
  opacity: 1;
  cursor: default;
  position: relative;
}
.admin-bid-entry-page .highest-bid-check:checked {
  border-color: #2ecb70;
  background: #2ecb70;
}
.admin-bid-entry-page .highest-bid-check:checked::after {
  content: "";
  position: absolute;
  left: 4px;
  top: 1px;
  width: 4px;
  height: 8px;
  border: solid #ffffff;
  border-width: 0 2px 2px 0;
  transform: rotate(45deg);
}
.admin-bid-entry-page .highest-bid-check:disabled {
  opacity: 1;
}

/* ══ Lot Detail Card (right) ════════════════════════════════════════ */
.lot-detail-card {
  background: var(--obsidian-mid);
  border: 1px solid var(--obsidian-border);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-deep), var(--shadow-gold);
  display: flex;
  flex-direction: column;
  height: 100%;
  overflow: hidden;
  min-width: 0;
}

.ldc-empty {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.75rem;
  padding: 2rem 1.5rem;
}
.ldc-empty-icon {
  font-size: 2rem;
  color: var(--obsidian-border);
}
.ldc-empty-text {
  font-size: 0.74rem;
  font-weight: 500;
  letter-spacing: 0.07em;
  text-transform: uppercase;
  color: var(--pearl-muted);
  text-align: center;
  line-height: 1.6;
}

.ldc-content {
  flex: 1;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  min-height: 0;
  min-width: 0;
  justify-content: flex-start;
}

/* Photo area — flexes to fill remaining space; no card scrollbars */
.ldc-img-wrap {
  width: 100%;
  flex: 1 1 auto;
  min-height: 0;
  background: var(--obsidian);
  border-bottom: 1px solid var(--obsidian-border);
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  overflow: hidden;
}
#ldc-img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  display: block;
}
.ldc-img-loader,
.ldc-no-img {
  font-size: 0.75rem;
  color: var(--pearl-muted);
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

/* Lot name header */
.ldc-lot-header {
  display: flex;
  align-items: baseline;
  gap: 0.5rem;
  flex-wrap: wrap;
  padding: 0.75rem 1rem 0.45rem;
  padding-left: 40%;
  border-bottom: 1px solid var(--obsidian-border);
  flex-shrink: 0;
  background: rgba(20,23,35,0.7);
  min-width: 0;
  overflow: hidden;
}
.ldc-eyebrow {
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--pearl-muted);
}
.ldc-lot-name {
  font-family: 'Cormorant Garamond', serif;
  font-size: 1.42rem;
  font-weight: 600;
  color: var(--gold-bright);
  letter-spacing: 0.05em;
  cursor: pointer;
  line-height: 1.15;
  overflow-wrap: anywhere;
  word-break: break-word;
}
.ldc-lot-name:hover {
  color: var(--gold-pale);
  text-decoration: underline;
}

/* Fields */
.ldc-fields {
  display: flex;
  flex-direction: column;
  gap: 0;
  padding: 0.45rem 1rem 0.65rem;
  padding-left: 40%;
  flex-shrink: 0;
  min-width: 0;
  overflow: hidden;
}
.ldc-field-row {
  display: flex;
  align-items: baseline;
  gap: 0.5rem;
  padding: 0.28rem 0;
  border-bottom: 1px solid rgba(255,255,255,0.04);
  min-width: 0;
}
.ldc-field-row:last-child { border-bottom: none; }
.ldc-field-row dt {
  font-size: 0.64rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--pearl-muted);
  min-width: 46px;
  flex-shrink: 0;
}
.ldc-field-row dd {
  font-size: 0.8rem;
  color: var(--pearl);
  font-weight: 500;
  margin: 0;
  min-width: 0;
  overflow-wrap: anywhere;
  word-break: break-word;
}
.ldc-no-details {
  font-size: 0.66rem;
  color: var(--pearl-muted);
  padding: 0.5rem 0;
  text-align: center;
}

/* Size distribution table */
.ldc-sizes {
  padding: 0.45rem 0.65rem 0.65rem;
  flex-shrink: 0;
  border-bottom: 1px solid var(--obsidian-border);
  overflow: hidden;
  min-width: 0;
}
.ldc-sizes-label {
  font-size: 0.58rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--pearl-muted);
  margin-bottom: 0.4rem;
}
.ldc-sizes-table {
  border-collapse: collapse;
  width: 100%;
  max-width: 100%;
  table-layout: fixed;
}
.ldc-sizes-table th {
  font-size: 0.52rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--pearl-muted);
  padding: 0.2rem 0.25rem;
  text-align: center;
  border-bottom: 1px solid rgba(255,255,255,0.08);
}
.ldc-sizes-table td {
  font-size: 0.64rem;
  font-weight: 600;
  color: var(--gold-bright);
  padding: 0.15rem 0.2rem;
  text-align: center;
  overflow: hidden;
  text-overflow: auto;
}

/* Dropbox button */
.ldc-dropbox-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  display: inline-flex;
  margin: 0 auto;
  padding: 0.55rem 0.75rem;
  background: var(--gold-glow);
  border: 1px solid var(--gold-border);
  border-radius: var(--radius);
  color: var(--gold-bright);
  font-size: 0.68rem;
  font-weight: 600;
  text-decoration: none;
  letter-spacing: 0.03em;
  transition: all 0.18s;
  flex-shrink: 0;
  max-width: 100%;
  box-sizing: border-box;
}
.ldc-dropbox-btn:hover {
  background: rgba(201,150,60,0.25);
  border-color: var(--gold);
  transform: translateY(-1px);
  box-shadow: 0 4px 14px rgba(201,150,60,0.18);
}
.ldc-dropbox-wrap {
  text-align: center;
  padding: 0 0.85rem 1rem;
  flex-shrink: 0;
  min-width: 0;
  overflow: hidden;
}
.ldc-dropbox-hint {
  font-size: 0.6rem;
  color: var(--pearl-muted);
  margin-top: 0.4rem;
  letter-spacing: 0.02em;
}

/* Active row highlight */
.lot-row { cursor: pointer; }
.lot-row-active td { background: rgba(201,150,60,0.09) !important; }
.lot-row-active td:first-child { border-left: 2px solid var(--gold); }

/* Lot name button */
.lot-name-btn {
  background: transparent;
  border: none;
  padding: 0;
  margin: 0;
  font: inherit;
  font-weight: 600;
  color: var(--pearl);
  cursor: pointer;
  text-align: left;
  transition: color 0.15s;
}
.lot-name-btn:hover { color: var(--gold-bright); text-decoration: underline; }

/* ── Medium widths: trim card 1 a touch more so center/lot keep room ─ */
@media (max-width: 1280px) and (min-width: 1101px) {
  .bid-layout {
    grid-template-columns: minmax(280px, 360px) 45% minmax(280px, 1fr);
    gap: 1rem;
  }
  /* Higher specificity than .bid-layout so client sheet follows this band too */
  .client-bid-entry-page .bid-layout {
    grid-template-columns: min(22.5rem, max(16.5rem, 25.5%)) minmax(0, 1.21fr) minmax(12rem, 1.34fr);
    gap: 1rem;
  }
}

/* ── Compact height for small screens (13" laptops) ─────────────── */
@media (max-height: 820px) {
  .bid-layout { padding: 0.75rem; gap: 0.75rem; }
  .ic-brand { padding: 1rem 1.5rem 0.75rem; }
  .ic-brand .brand { font-size: 1.5rem; }
  .ic-brand .brand-sub { font-size: 0.68rem; }
  .ic-client { padding: 0.6rem 1.5rem; }
  .ic-client-name { font-size: 1rem; }
  .ic-client-tag { margin-top: 0.2rem; font-size: 0.7rem; }
  .ic-divider { display: none; }
  .ic-auction-box { margin: 0.5rem 1.25rem; padding: 0.6rem 1rem; }
  .ic-auction-label { font-size: 0.58rem; margin-bottom: 0.15rem; }
  .ic-auction-name { font-size: 1rem; margin-bottom: 0.15rem; }
  .ic-auction-dates { font-size: 0.65rem; }
  .ic-schedule-line { font-size: 0.68rem; line-height: 1.35; }
  .ic-section { padding: 0.5rem 1.5rem; }
  .ic-rules { padding: 0.6rem 1.5rem; gap: 0.45rem; }
  .ic-rule-item { font-size: 0.72rem; line-height: 1.35; gap: 0.4rem; }
  .ic-rule-icon { font-size: 0.8rem; }
  .client-bid-entry-page .ic-admin-picker.client-bid-sidebar-panel {
    padding: 0.55rem 0.75rem;
  }
  .client-bid-entry-page .client-bid-sidebar-panel .ic-tender-line,
  .client-bid-entry-page .client-bid-sidebar-panel .ic-rule-item {
    font-size: 0.68rem;
  }
  .ic-action-bar { padding: 0.6rem 1.25rem 0.75rem; gap: 0.5rem; }
  .ic-summary-list { max-height: 180px; min-height: 140px; }
  .ic-summary-row { padding: 0.2rem 0.6rem; font-size: 0.7rem; }
  .ic-action-box { padding: 0.6rem; }
  .ic-action-box .submit-btn { padding: 0.55rem 1.5rem; font-size: 0.8rem; }
}

/* ── Responsive ─────────────────────────────────────────────────── */
@media (max-width: 1100px) {
  html, body { overflow: auto; height: auto; }
  .bid-page {
    min-height: calc(100vh - var(--site-footer-safe));
    min-height: calc(100dvh - var(--site-footer-safe));
    height: auto;
  }
  .bid-page-header {
    grid-template-columns: 1fr;
    row-gap: 0.5rem;
  }
  .bph-left, .bph-center, .bph-right {
    justify-self: start;
    text-align: left;
  }
  .admin-bid-entry-page .bph-right-admin,
  .client-bid-entry-page .bph-right {
    align-items: flex-start;
  }
  .bid-layout {
    grid-template-columns: 1fr;
    height: auto;
    padding: 0;
    gap: 1rem;
  }
  .client-bid-entry-page .bid-layout {
    grid-template-columns: 1fr;
    height: auto;
    padding: 0;
    gap: 1rem;
  }
  /* Slightly narrower first card when stacked (more room for bid sheet feel) */
  .info-card {
    max-width: min(100%, 34rem);
    width: 100%;
    margin-left: auto;
    margin-right: auto;
    height: auto;
    overflow: visible;
  }
  .bid-card {
    height: auto;
  }
  .bc-table-scroll { overflow: visible; }
  .bc-top-bar { flex-wrap: wrap; }

  /* Lot detail + image: fit viewport like a card — no inner scrollbar */
  .lot-detail-card {
    height: auto;
    max-height: min(58vh, 520px);
    min-height: 280px;
    overflow: hidden;
    width: 100%;
    max-width: min(100%, 34rem);
    margin-left: auto;
    margin-right: auto;
  }
  .admin-bid-simple-entry .admin-bid-actions-card {
    max-height: min(52vh, 480px);
    min-height: 220px;
  }
  .admin-bid-simple-entry .admin-bid-actions-card .ic-summary-list {
    max-height: min(36vh, 320px);
    min-height: 140px;
  }
  .ldc-content {
    overflow: hidden !important;
    flex: 1 1 auto;
    min-height: 0;
    max-height: 100%;
    justify-content: flex-start;
  }
  .ldc-img-wrap {
    flex: 1 1 auto;
    min-height: 100px;
    max-height: min(240px, 34vh);
  }
  .ldc-lot-header {
    padding-left: 1rem;
    padding-right: 0.85rem;
  }
  .ldc-fields {
    padding-left: 1rem;
    padding-right: 0.85rem;
  }
  .ldc-sizes {
    padding-left: 0.75rem;
    padding-right: 0.75rem;
  }
  .ldc-eyebrow {
    font-size: 0.72rem;
  }
  .ldc-lot-name {
    font-size: 1.35rem;
  }
  .ldc-field-row {
    padding: 0.22rem 0;
    gap: 0.45rem;
  }
  .ldc-field-row dt {
    font-size: 0.62rem;
    min-width: 44px;
    letter-spacing: 0.06em;
  }
  .ldc-field-row dd {
    font-size: 0.78rem;
  }
  .ldc-no-details {
    font-size: 0.65rem;
  }
  .ldc-sizes-label {
    font-size: 0.58rem;
  }
  .ldc-sizes-table th {
    font-size: 0.48rem;
    padding: 0.12rem 0.12rem;
  }
  .ldc-sizes-table td {
    font-size: 0.58rem;
    padding: 0.12rem 0.12rem;
  }
  .ldc-dropbox-btn {
    font-size: 0.65rem;
    padding: 0.42rem 0.55rem;
  }
  .ldc-dropbox-hint {
    font-size: 0.58rem;
  }
  .ldc-dropbox-wrap {
    padding: 0 0.85rem 0.85rem;
    flex-shrink: 0;
  }
  .ldc-empty {
    padding: 1.25rem 1rem;
  }
  .ldc-empty-text {
    font-size: 0.65rem;
  }
}

/* ─── Admin: client bid confirmations (left: filters + no-email list; right: pending 40% / notified 60%) ─ */
.admin-bid-confirmations-page .confirm-bid-layout {
  display: grid;
  grid-template-columns: 360px minmax(0, 1fr);
  gap: 1.15rem;
  flex: 1 1 auto;
  min-height: 0;
}
/* Grid items default min-height:auto prevents flex children from shrinking above the footer */
.admin-bid-confirmations-page .confirm-bid-layout > * {
  min-height: 0;
}
.admin-bid-confirmations-page .confirm-auction-card {
  padding: 0 0 1rem;
  min-height: 0;
  overflow: hidden;
}
.admin-bid-confirmations-page .confirm-auction-card-main {
  flex-shrink: 0;
  padding-bottom: 0.35rem;
  border-bottom: 1px solid rgba(201, 150, 60, 0.35);
  box-shadow: 0 1px 0 rgba(0, 0, 0, 0.25);
}
/* With an auction selected: auction+tender+hint ≈40%, no-email block ≈60% */
.admin-bid-confirmations-page .confirm-auction-card--with-noemail .confirm-auction-card-main {
  flex: 0 0 40%;
  min-height: 0;
  max-height: 40%;
  overflow-y: auto;
  overflow-x: hidden;
}
.admin-bid-confirmations-page .confirm-auction-card--with-noemail .confirm-left-noemail {
  flex: 1 1 0%;
  min-height: 0;
  margin-top: 1.2rem;
  padding-top: 1rem;
}
.admin-bid-confirmations-page .confirm-auction-card .ic-section {
  padding: 1rem 1.25rem 0.5rem;
}
.admin-bid-confirmations-page .confirm-left-noemail {
  flex: 1 1 auto;
  min-height: 0;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  margin-top: 0.85rem;
  padding-top: 0.75rem;
  background: linear-gradient(
    180deg,
    rgba(201, 150, 60, 0.08) 0%,
    rgba(201, 150, 60, 0.02) 2.25rem,
    transparent 100%
  );
}
.admin-bid-confirmations-page .confirm-left-noemail-title {
  flex-shrink: 0;
  margin: 0 1.25rem 0.25rem;
  font-size: 0.82rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--gold-pale);
}
.admin-bid-confirmations-page .confirm-left-noemail-note {
  flex-shrink: 0;
  margin: 0 1.25rem 0.45rem;
  font-size: 0.72rem;
  line-height: 1.4;
  color: var(--pearl-muted);
}
.admin-bid-confirmations-page .confirm-rio-toggle {
  flex-shrink: 0;
  margin: 0 1.25rem 0.5rem;
}
.admin-bid-confirmations-page .confirm-rio-label {
  display: flex;
  align-items: center;
  gap: 0.45rem;
  font-size: 0.72rem;
  color: var(--pearl-dim);
  cursor: pointer;
  user-select: none;
}
.admin-bid-confirmations-page .confirm-rio-label input {
  width: 1rem;
  height: 1rem;
  min-width: 1rem;
  min-height: 1rem;
  accent-color: var(--gold-bright);
  cursor: pointer;
}
.admin-bid-confirmations-page .confirm-left-noemail-scroll {
  flex: 1 1 auto;
  min-height: 0;
  margin: 0 1.25rem;
  overflow-y: auto;
  overflow-x: auto;
}
.admin-bid-confirmations-page .confirm-left-noemail-empty {
  margin: 0;
  padding: 0.15rem 0 0.35rem;
}
.admin-bid-confirmations-page .confirm-noemail-table {
  font-size: 0.76rem;
}
.admin-bid-confirmations-page .confirm-noemail-table thead th {
  padding: 0.45rem 0.5rem;
  font-size: 0.62rem;
}
.admin-bid-confirmations-page .confirm-noemail-table tbody td {
  padding: 0.4rem 0.5rem;
}
.admin-bid-confirmations-page .confirm-auction-hint {
  margin: 0.75rem 1.25rem 0;
  font-size: 0.78rem;
  line-height: 1.45;
  color: var(--pearl-muted);
}
.admin-bid-confirmations-page .confirm-auction-empty {
  margin: 0.25rem 0 0;
  font-size: 0.82rem;
  color: var(--gold-bright);
}
.admin-bid-confirmations-page .confirm-data-card {
  min-width: 0;
  flex: 1 1 auto;
  min-height: 0;
}
.admin-bid-confirmations-page .confirm-panel-columns {
  flex: 1;
  min-height: 0;
  display: flex;
  flex-direction: column;
  gap: 0.65rem;
  padding: 0.5rem 1.25rem 1rem;
  overflow: hidden;
}
.admin-bid-confirmations-page .confirm-panel-placeholder {
  flex: 1;
  min-height: 0;
  overflow-y: auto;
  display: flex;
  align-items: flex-start;
  padding-top: 0.25rem;
}
.admin-bid-confirmations-page .confirm-section {
  display: flex;
  flex-direction: column;
  min-height: 0;
  overflow: hidden;
}
.admin-bid-confirmations-page .confirm-section-pending {
  flex: 2 1 0%;
}
.admin-bid-confirmations-page .confirm-section-notified {
  flex: 3 1 0%;
}
.admin-bid-confirmations-page .confirm-section-title,
.admin-bid-confirmations-page .confirm-section-note {
  flex-shrink: 0;
}
.admin-bid-confirmations-page .confirm-section-body {
  flex: 1 1 auto;
  min-height: 0;
  display: flex;
  flex-direction: column;
  overflow: hidden;
}
.admin-bid-confirmations-page .confirm-pending-form {
  flex: 1 1 auto;
  min-height: 0;
  display: flex;
  flex-direction: column;
  overflow: hidden;
}
.admin-bid-confirmations-page .confirm-pending-head {
  flex-shrink: 0;
  display: flex;
  flex-direction: row;
  align-items: flex-start;
  justify-content: space-between;
  gap: 0.85rem 1rem;
  margin-bottom: 0.5rem;
}
.admin-bid-confirmations-page .confirm-pending-head-text {
  flex: 1 1 auto;
  min-width: 0;
}
.admin-bid-confirmations-page .confirm-pending-head .confirm-section-title {
  margin-bottom: 0.25rem;
}
.admin-bid-confirmations-page .confirm-pending-head-note {
  margin: 0;
  max-width: none;
}
.admin-bid-confirmations-page .confirm-pending-head-actions {
  flex-shrink: 0;
  align-self: center;
}
.admin-bid-confirmations-page .confirm-pending-send-btn {
  margin-top: 0;
  padding: 0.58rem 1.45rem;
  font-size: 0.86rem;
  white-space: nowrap;
}
.admin-bid-confirmations-page .confirm-section-scroll {
  flex: 1 1 auto;
  min-height: 0;
  overflow-y: auto;
  overflow-x: auto;
}
.admin-bid-confirmations-page .confirm-section-body > .confirm-empty {
  flex: 1 1 auto;
  min-height: 0;
  margin: 0;
  padding-top: 0.15rem;
}
.admin-bid-confirmations-page .confirm-section-title {
  margin: 0 0 0.35rem;
  font-size: 0.92rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--gold-pale);
}
.admin-bid-confirmations-page .confirm-section-note {
  margin: 0 0 0.65rem;
  font-size: 0.78rem;
  color: var(--pearl-muted);
  max-width: 48rem;
}
.admin-bid-confirmations-page .confirm-empty {
  margin: 0;
  font-size: 0.82rem;
  color: var(--pearl-muted);
}
.admin-bid-confirmations-page .confirm-table-wrap {
  border: 1px solid var(--obsidian-border);
  border-radius: var(--radius);
  overflow: hidden;
}
.admin-bid-confirmations-page .confirm-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.82rem;
}
.admin-bid-confirmations-page .confirm-table thead th {
  text-align: left;
  padding: 0.55rem 0.65rem;
  background: rgba(201, 150, 60, 0.12);
  color: var(--pearl);
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  font-size: 0.68rem;
  border-bottom: 1px solid var(--gold-border);
  white-space: nowrap;
}
.admin-bid-confirmations-page .confirm-th-sort-label {
  display: block;
  width: 100%;
  margin: 0;
  padding: 0;
  font: inherit;
  font-weight: inherit;
  font-size: inherit;
  letter-spacing: inherit;
  text-transform: inherit;
  text-align: left;
  color: inherit;
  background: none;
  border: none;
  cursor: pointer;
  line-height: 1.25;
}
.admin-bid-confirmations-page .confirm-th-sort-label:hover {
  color: var(--gold-pale);
}
.admin-bid-confirmations-page .confirm-th-sorted-asc .confirm-th-sort-label,
.admin-bid-confirmations-page .confirm-th-sorted-desc .confirm-th-sort-label {
  color: var(--gold-bright);
}
.admin-bid-confirmations-page .confirm-table tbody td {
  padding: 0.5rem 0.65rem;
  border-bottom: 1px solid rgba(46, 52, 80, 0.6);
  color: var(--pearl-dim);
  vertical-align: middle;
}
.admin-bid-confirmations-page .confirm-table tbody tr:last-child td {
  border-bottom: none;
}

/* Admin: client list (bid-sheet style) */
.admin-client-list-page .admin-client-list-layout {
  grid-template-columns: minmax(18rem, 24rem) 1fr;
}
.admin-client-list-page .admin-client-list-layout > * {
  min-height: 0;
}
.admin-client-list-page .admin-client-list-left {
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
}
.admin-client-list-page .admin-client-list-right {
  display: flex;
  flex-direction: column;
  min-height: 0;
}
.admin-client-list-head {
  padding: 0.7rem 1rem 0.5rem;
  border-bottom: 1px solid rgba(90, 104, 140, 0.25);
  display: flex;
  align-items: center;
  gap: 0.8rem;
  flex-wrap: wrap;
}
.admin-client-list-count {
  margin: 0;
  color: #d6d0c2;
  font-size: 0.86rem;
  margin-right: auto;
}
.admin-client-list-edit-toggle {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  font-size: 0.78rem;
  color: #d8cfb5;
}
.admin-client-list-edit-toggle input {
  accent-color: var(--gold-bright);
}
.admin-client-list-save-btn {
  width: auto;
  padding: 0.4rem 0.75rem;
  font-size: 0.76rem;
}
.admin-client-list-filter-form .confirm-rio-label {
  margin: 0;
}
.admin-client-list-filter-form select {
  min-height: 2.7rem;
  padding: 0.55rem 0.7rem;
  font-size: 0.92rem;
}
.admin-client-list-table-scroll {
  flex: 1 1 auto;
  min-height: 0;
  overflow: auto;
  padding: 0.55rem 0.85rem 0.9rem;
}
.admin-client-list-table {
  width: 100%;
  border-collapse: separate;
  border-spacing: 0;
  table-layout: fixed;
}
.admin-client-list-table th,
.admin-client-list-table td {
  text-align: left;
  padding: 0.5rem 0.55rem;
  border-bottom: 1px solid rgba(90, 104, 140, 0.2);
  color: #e8e2d4;
  font-size: 0.8rem;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.admin-client-list-cell-input {
  width: 100%;
  border: 1px solid transparent;
  background: transparent;
  color: inherit;
  font: inherit;
  padding: 0.15rem 0.2rem;
}
.admin-client-list-cell-input.is-editable {
  background: #0d131b;
  border-color: rgba(90, 104, 140, 0.45);
  border-radius: 4px;
}
.admin-client-list-cell-input:focus {
  outline: none;
  border-color: rgba(201, 169, 98, 0.55);
}
.admin-client-list-cell-input--locked {
  color: #95a2ba;
  cursor: not-allowed;
}
.admin-client-list-table thead th {
  position: sticky;
  top: 0;
  background: #121926;
  z-index: 2;
}
.admin-client-list-table .admin-client-list-filter-row th {
  top: 2.1rem;
  background: #111824;
}
.admin-client-list-filter-row input {
  width: 100%;
  background: #0d131b;
  border: 1px solid rgba(90, 104, 140, 0.45);
  color: #e7dfcf;
  border-radius: 4px;
  font-size: 0.74rem;
  padding: 0.28rem 0.4rem;
}
.admin-client-list-sort {
  background: none;
  border: none;
  color: #d7c7a0;
  cursor: pointer;
  font: inherit;
  padding: 0;
  text-align: left;
}
.admin-client-list-sort:hover {
  color: #eddab1;
  text-decoration: underline;
}
.admin-client-list-sort.is-asc::after {
  content: " ▲";
  font-size: 0.66rem;
}
.admin-client-list-sort.is-desc::after {
  content: " ▼";
  font-size: 0.66rem;
}

@media (max-width: 980px) {
  .admin-client-list-page .admin-client-list-layout {
    grid-template-columns: 1fr;
  }
  .admin-client-list-table-scroll {
    max-height: none;
  }
}
.admin-bid-confirmations-page .confirm-th-cb {
  width: 2.75rem;
  text-align: center;
  vertical-align: middle;
}
.admin-bid-confirmations-page .confirm-td-cb {
  text-align: center;
}
.admin-bid-confirmations-page .confirm-cb {
  width: 1.35rem;
  height: 1.35rem;
  min-width: 1.35rem;
  min-height: 1.35rem;
  cursor: pointer;
  accent-color: var(--gold-bright);
}
/* Open bid sheet: match table body text (no default link blue/bold) */
.admin-bid-confirmations-page a.confirm-bid-sheet-link {
  color: var(--pearl-dim);
  font-weight: 400;
  text-decoration: none;
  cursor: pointer;
  border-bottom: 1px solid transparent;
}
.admin-bid-confirmations-page a.confirm-bid-sheet-link:hover {
  color: var(--gold-pale);
  border-bottom-color: rgba(201, 150, 60, 0.45);
}
.admin-bid-confirmations-page a.confirm-bid-sheet-link:visited {
  color: var(--pearl-dim);
}
/* Bids column only: blue, bold, underlined */
.admin-bid-confirmations-page a.confirm-bid-sheet-link.confirm-bid-count-link {
  color: #4a9eff;
  font-weight: 700;
  text-decoration: underline;
  text-underline-offset: 0.12em;
  border-bottom: none;
}
.admin-bid-confirmations-page a.confirm-bid-sheet-link.confirm-bid-count-link:hover {
  color: #7ab8ff;
  text-decoration: underline;
  border-bottom: none;
}
.admin-bid-confirmations-page a.confirm-bid-sheet-link.confirm-bid-count-link:visited {
  color: #6ba8f0;
}
.admin-bid-confirmations-page .confirm-td-email {
  word-break: break-all;
  max-width: 14rem;
}
.admin-bid-confirmations-page .confirm-td-time {
  font-size: 0.78rem;
  white-space: nowrap;
}
.admin-bid-confirmations-page .confirm-notified-company-filter {
  flex-shrink: 0;
  width: 100%;
  max-width: 22rem;
  box-sizing: border-box;
  margin: 0 0 0.55rem;
  padding: 0.45rem 0.6rem;
  font-size: 0.82rem;
  color: var(--pearl);
  background: rgba(0, 0, 0, 0.25);
  border: 1px solid var(--obsidian-border);
  border-radius: var(--radius);
}
.admin-bid-confirmations-page .confirm-notified-company-filter::placeholder {
  color: var(--pearl-muted);
}
.admin-bid-confirmations-page .confirm-notified-company-filter:focus {
  outline: none;
  border-color: var(--gold-border);
  box-shadow: 0 0 0 1px rgba(201, 150, 60, 0.25);
}
.admin-bid-confirmations-page .confirm-th-actions {
  text-align: right;
  width: 5.5rem;
}
.admin-bid-confirmations-page .confirm-td-actions {
  text-align: right;
  white-space: nowrap;
}
.admin-bid-confirmations-page .confirm-resend-link {
  font-size: 0.72rem;
  font-weight: 500;
  letter-spacing: normal;
  text-transform: capitalize;
  color: #7eb8ff;
  text-decoration: underline;
}
.admin-bid-confirmations-page .confirm-resend-link:hover {
  color: #a8d4ff;
  text-decoration: underline;
}
.admin-bid-confirmations-page .confirm-resend-form-hidden {
  display: none;
}

/* Re-send: in-page confirm dialog (replaces system alert) */
body.confirm-resend-modal-open {
  overflow: hidden;
}
.admin-bid-confirmations-page .confirm-resend-modal {
  display: none;
  position: fixed;
  inset: 0;
  z-index: 20000;
  align-items: center;
  justify-content: center;
  padding: 1.25rem;
  box-sizing: border-box;
}
.admin-bid-confirmations-page .confirm-resend-modal.is-open {
  display: flex;
}
.admin-bid-confirmations-page .confirm-resend-modal-backdrop {
  position: absolute;
  inset: 0;
  margin: 0;
  padding: 0;
  border: none;
  background: rgba(8, 10, 16, 0.72);
  backdrop-filter: blur(3px);
  cursor: pointer;
}
.admin-bid-confirmations-page .confirm-resend-modal-panel {
  position: relative;
  z-index: 1;
  width: 100%;
  max-width: 26rem;
  padding: 1.35rem 1.5rem 1.25rem;
  background: linear-gradient(155deg, rgba(26, 29, 38, 0.98) 0%, rgba(16, 19, 28, 0.99) 100%);
  border: 1px solid var(--gold-border);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-deep), 0 0 0 1px rgba(201, 150, 60, 0.12);
}
.admin-bid-confirmations-page .confirm-resend-modal-title {
  margin: 0 0 0.85rem;
  font-size: 1rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--gold-pale);
}
.admin-bid-confirmations-page .confirm-resend-modal-lead {
  margin: 0 0 0.55rem;
  font-size: 0.88rem;
  line-height: 1.5;
  color: var(--pearl);
}
.admin-bid-confirmations-page .confirm-resend-modal-company {
  font-weight: 600;
  color: var(--gold-bright);
}
.admin-bid-confirmations-page .confirm-resend-modal-sub {
  margin: 0 0 1.25rem;
  font-size: 0.78rem;
  line-height: 1.45;
  color: var(--pearl-muted);
}
.admin-bid-confirmations-page .confirm-resend-modal-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 0.65rem;
}
.admin-bid-confirmations-page .confirm-resend-modal-btn {
  margin: 0;
  padding: 0.5rem 1.15rem;
  font-size: 0.8rem;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  border-radius: var(--radius);
  cursor: pointer;
  border: 1px solid transparent;
}
.admin-bid-confirmations-page .confirm-resend-modal-btn-cancel {
  background: transparent;
  color: var(--pearl-dim);
  border-color: var(--obsidian-border);
}
.admin-bid-confirmations-page .confirm-resend-modal-btn-cancel:hover {
  color: var(--pearl);
  border-color: rgba(201, 150, 60, 0.35);
}
.admin-bid-confirmations-page .confirm-resend-modal-btn-send.submit-btn {
  margin-top: 0;
  padding: 0.5rem 1.25rem;
  font-size: 0.78rem;
}
@media (max-width: 960px) {
  .admin-bid-confirmations-page .confirm-bid-layout {
    grid-template-columns: 1fr;
    grid-template-rows: auto minmax(280px, 1fr);
  }
  .admin-bid-confirmations-page .confirm-auction-card {
    max-height: 220px;
  }
  .admin-bid-confirmations-page .confirm-auction-card--with-noemail .confirm-auction-card-main {
    flex: 0 1 auto;
    max-height: none;
    overflow-y: auto;
  }
  .admin-bid-confirmations-page .confirm-auction-card--with-noemail .confirm-left-noemail {
    flex: 1 1 0%;
    min-height: 0;
  }
}

/* ─── Admin: client usage analytics ───────────────────────────────────── */
body.admin-client-usage-page {
  margin: 0;
  min-height: calc(100vh - var(--site-footer-safe));
  min-height: calc(100dvh - var(--site-footer-safe));
  height: calc(100vh - var(--site-footer-safe));
  height: calc(100dvh - var(--site-footer-safe));
  max-height: calc(100vh - var(--site-footer-safe));
  max-height: calc(100dvh - var(--site-footer-safe));
  overflow: hidden;
  box-sizing: border-box;
  display: flex;
  flex-direction: column;
}
body.admin-client-usage-page .admin-usage-console {
  flex: 1 1 auto;
  min-height: 0;
  display: flex;
  flex-direction: column;
  max-height: 100%;
  box-sizing: border-box;
}
body.admin-client-usage-page .admin-usage-top-bar {
  flex: 0 0 auto;
}
body.admin-client-usage-page .admin-usage-layout {
  flex: 1 1 0%;
  min-height: 0 !important;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  padding-top: 0.75rem;
}
body.admin-client-usage-page .admin-content h1 {
  margin-top: 0;
}
.admin-usage-header {
  flex: 0 0 auto;
  display: flex;
  flex-wrap: wrap;
  align-items: flex-start;
  gap: 0.75rem 1.5rem;
  margin-bottom: 0.65rem;
  padding-bottom: 0.65rem;
  border-bottom: 1px solid rgba(90, 104, 140, 0.3);
}
.admin-usage-header h1 {
  margin: 0;
  font-size: 1.35rem;
}
.admin-usage-period-toolbar {
  display: flex;
  flex-direction: column;
  align-items: stretch;
  gap: 0.65rem;
  flex: 1 1 14rem;
  min-width: 0;
}
.admin-usage-period-controls {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem 1.25rem;
  align-items: flex-end;
  justify-content: flex-end;
  width: 100%;
}
body.admin-usage-modal-open {
  overflow: hidden;
}
.admin-usage-modal {
  position: fixed;
  inset: 0;
  z-index: 12000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1rem;
  box-sizing: border-box;
}
.admin-usage-modal[hidden] {
  display: none !important;
}
.admin-usage-modal__backdrop {
  position: absolute;
  inset: 0;
  background: rgba(4, 8, 14, 0.72);
  backdrop-filter: blur(2px);
}
.admin-usage-modal__card {
  position: relative;
  z-index: 1;
  width: 100%;
  max-width: 22rem;
  padding: 1.15rem 1.25rem 1.2rem;
  border-radius: 10px;
  border: 1px solid rgba(201, 169, 98, 0.35);
  background: linear-gradient(165deg, #141c28 0%, #0d1219 100%);
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.45);
}
.admin-usage-modal__title {
  margin: 0 0 0.4rem;
  font-size: 1.05rem;
  font-weight: 600;
  color: #efe9dc;
}
.admin-usage-modal__hint {
  margin: 0 0 1rem;
  font-size: 0.76rem;
  line-height: 1.45;
  color: var(--pearl-muted, #9aa5c4);
}
.admin-usage-modal__fields {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  margin-bottom: 1rem;
}
.admin-usage-modal__label {
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--pearl-muted, #9aa5c4);
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
}
.admin-usage-modal__date {
  padding: 0.45rem 0.55rem;
  border-radius: 6px;
  border: 1px solid rgba(90, 104, 140, 0.55);
  background: #0d131b;
  color: #e7dfcf;
  font-size: 0.88rem;
  font-family: inherit;
}
.admin-usage-modal__date:focus {
  outline: none;
  border-color: rgba(201, 169, 98, 0.55);
  box-shadow: 0 0 0 1px rgba(201, 169, 98, 0.25);
}
.admin-usage-modal__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  justify-content: flex-end;
}
.admin-usage-modal__btn-primary {
  cursor: pointer;
  font: inherit;
  background: rgba(201, 169, 98, 0.18);
  border-color: rgba(201, 169, 98, 0.55);
}
.admin-usage-modal__btn-primary:hover {
  background: rgba(201, 169, 98, 0.28);
  border-color: rgba(231, 201, 120, 0.65);
}
.admin-usage-preset-wrap {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
  min-width: 11rem;
}
.admin-usage-preset-label {
  font-size: 0.7rem;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--pearl-muted, #9aa5c4);
}
.admin-usage-preset-select {
  padding: 0.4rem 0.5rem;
  border-radius: 4px;
  border: 1px solid rgba(90, 104, 140, 0.5);
  background: #0d131b;
  color: #e7dfcf;
  font-size: 0.8rem;
  max-width: 100%;
}
.admin-usage-period-meta {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 0.4rem;
  text-align: right;
  max-width: 100%;
  align-self: flex-end;
}
.admin-usage-period-range {
  margin: 0;
  font-size: 0.82rem;
  color: #e7dfcf;
  line-height: 1.35;
}
.admin-usage-period-length {
  color: var(--pearl-muted, #9aa5c4);
  font-size: 0.78rem;
}
.admin-usage-period-nav {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem;
  justify-content: flex-end;
}
.admin-usage-period-btn {
  display: inline-block;
  padding: 0.4rem 0.65rem;
  border-radius: 4px;
  border: 1px solid rgba(201, 169, 98, 0.45);
  background: rgba(30, 24, 14, 0.6);
  color: #e8d4a8;
  font-size: 0.78rem;
  text-decoration: none;
  white-space: nowrap;
}
a.admin-usage-period-btn:hover {
  border-color: rgba(231, 201, 120, 0.65);
  color: #f5e6c4;
}
.admin-usage-period-btn--disabled {
  opacity: 0.42;
  cursor: not-allowed;
  border-color: rgba(90, 104, 140, 0.35);
  color: var(--pearl-muted, #9aa5c4);
}
.admin-usage-scroll {
  flex: 1 1 0%;
  min-height: 0;
  overflow-y: auto;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  padding-right: 0.25rem;
  padding-bottom: 1rem;
}
.admin-usage-prompt {
  margin: 1rem 0 0;
  font-size: 0.9rem;
  color: var(--pearl-muted, #9aa5c4);
}
.admin-usage-security-note {
  font-size: 0.78rem;
  line-height: 1.45;
  color: var(--pearl-muted, #9aa5c4);
  max-width: 48rem;
  margin: 0 0 0.85rem;
}
.admin-usage-security-note--tight {
  margin-top: -0.35rem;
}
.admin-usage-security-note code {
  font-size: 0.88em;
}
.admin-usage-ip-cell code {
  font-size: 0.78rem;
  word-break: break-all;
}
.admin-usage-section-title {
  font-size: 1.05rem;
  margin: 1.25rem 0 0.65rem;
  color: #efe9dc;
  font-weight: 600;
}
.admin-usage-section-title:first-child {
  margin-top: 0;
}
.admin-usage-summary-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(9.5rem, 1fr));
  gap: 0.75rem;
  margin-bottom: 0.5rem;
  max-width: 100%;
}
.admin-usage-stat {
  background: rgba(15, 22, 36, 0.75);
  border: 1px solid rgba(90, 104, 140, 0.3);
  border-radius: 8px;
  padding: 0.65rem 0.75rem;
  text-align: center;
}
.admin-usage-stat--wide {
  grid-column: 1 / -1;
  text-align: left;
}
.admin-usage-stat-value {
  font-size: 1.35rem;
  font-weight: 700;
  color: #e8b554;
  line-height: 1.2;
}
.admin-usage-stat-label {
  font-size: 0.68rem;
  color: var(--pearl-muted, #9aa5c4);
  margin-top: 0.35rem;
  line-height: 1.35;
}
.admin-usage-table-wrap {
  overflow-x: auto;
  max-width: 100%;
  margin-bottom: 1rem;
  border: 1px solid rgba(90, 104, 140, 0.35);
  border-radius: 8px;
}
.admin-usage-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.82rem;
}
.admin-usage-table th,
.admin-usage-table td {
  padding: 0.5rem 0.65rem;
  text-align: left;
  border-bottom: 1px solid rgba(90, 104, 140, 0.25);
}
.admin-usage-table th {
  background: rgba(20, 28, 44, 0.95);
  color: #c9c4b8;
  font-weight: 600;
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.03em;
}
.admin-usage-table tbody tr:hover {
  background: rgba(232, 181, 84, 0.06);
}
.admin-usage-table td.num {
  text-align: right;
  font-variant-numeric: tabular-nums;
}
.admin-usage-empty {
  font-size: 0.88rem;
  color: var(--pearl-muted, #9aa5c4);
  margin: 0 0 1rem;
}