/* ===== Chrono Vault custom theme (my own CSS, built on top of Bootstrap) ===== */

/* Theme colours */
:root {
  --gold: #c9a24b;
  --gold-hover: #e0bb63;
  --dark: #0e0e0e;
  --card: #181818;
  --border: #2c2c2c;
}

/* Dark background + footer stays at the bottom */
body {
  background: var(--dark);
  color: #e8e8e8;
  font-family: 'Inter', sans-serif;
  display: flex;
  flex-direction: column;
  min-height: 100vh;
}

main {
  flex: 1;
}

/* Elegant serif font for headings and logo */
h1, h2, h3, h4, h5, .navbar-brand {
  font-family: 'Playfair Display', serif;
}

/* Gold text helper */
.text-gold {
  color: var(--gold) !important;
}

.text-light-muted {
  color: #b5b5b5;
}

/* Navbar: black with a thin gold line */
.navbar-custom {
  background: #000;
  border-bottom: 1px solid var(--gold);
}

.navbar-custom .nav-link {
  color: #cfcfcf;
}

.navbar-custom .nav-link:hover {
  color: var(--gold);
}

/* Gold buttons */
.btn-gold {
  background: var(--gold);
  color: #000;
  border: none;
}

.btn-gold:hover {
  background: var(--gold-hover);
  color: #000;
}

.btn-outline-gold {
  border: 1px solid var(--gold);
  color: var(--gold);
}

.btn-outline-gold:hover {
  background: var(--gold);
  color: #000;
}

/* Splash page hero section */
.hero {
  min-height: 80vh;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 2rem;
  background: radial-gradient(circle at center, #2a2416 0%, var(--dark) 70%);
}

/* Footer: black with a gold line on top */
.footer-custom {
  background: #000;
  border-top: 1px solid var(--gold);
  color: #888;
}

.footer-link {
  color: #888;
  text-decoration: none;
}

.footer-link:hover {
  color: var(--gold);
}

/* Watch cards on the collection page */
.watch-card {
  background: var(--card);
  border: 1px solid var(--border);
  color: #e8e8e8;
  transition: border-color 0.2s, transform 0.2s;
}

.watch-card:hover {
  border-color: var(--gold);
  transform: translateY(-3px);
}

.watch-card .card-footer {
  background: transparent;
  border-top: 1px solid var(--border);
}

.watch-details li {
  color: #b5b5b5;
  margin-bottom: 4px;
}

.watch-details i {
  color: var(--gold);
  width: 20px;
}

.watch-notes {
  font-size: 0.9rem;
  color: #999;
  font-style: italic;
}

/* Status badges */
.badge-owned {
  background: var(--gold);
  color: #000;
}

.badge-wishlist {
  background: transparent;
  border: 1px solid #888;
  color: #ccc;
}

/* Empty collection message */
.empty-state {
  border: 1px dashed var(--border);
  border-radius: 8px;
}

/* Add / Edit forms */
.form-wrapper {
  max-width: 800px;
}

.vault-form {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 8px;
}

.vault-form .form-control,
.vault-form .form-select {
  background: #101010;
  color: #e8e8e8;
  border: 1px solid #333;
}

.vault-form .form-control:focus,
.vault-form .form-select:focus {
  border-color: var(--gold);
  box-shadow: 0 0 0 0.2rem rgba(201, 162, 75, 0.25);
}

.vault-form .form-control::placeholder {
  color: #666;
}

/* Login / Sign up forms */
.auth-wrapper {
  max-width: 440px;
}

/* Watch photo area at the top of each card */
.watch-img-wrap {
  position: relative;
  height: 220px;
  background: #101010;
  border-bottom: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}

/* Clock icon shown when there's no photo */
.watch-img-icon {
  font-size: 3rem;
  color: #333;
}

/* The photo fills the whole area, covering the icon */
.watch-img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

/* Stats bar on the collection page */
.stat-box {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 1rem 1.25rem;
  height: 100%;
}

.stat-number {
  font-family: 'Playfair Display', serif;
  font-size: 1.8rem;
  color: var(--gold);
}

.stat-label {
  font-size: 0.85rem;
  color: #999;
}

/* Toolbar: search box and sort dropdown match the dark theme */
.toolbar-input {
  background: #101010;
  color: #e8e8e8;
  border: 1px solid #333;
  min-width: 180px;
  width: auto;
}

.toolbar-input:focus {
  background: #101010;
  color: #e8e8e8;
  border-color: var(--gold);
  box-shadow: 0 0 0 0.2rem rgba(201, 162, 75, 0.25);
}

.toolbar-input::placeholder {
  color: #666;
}

/* Makes the calendar icon in date fields visible on the dark theme */
.vault-form input[type="date"] {
  color-scheme: dark;
}

/* Keep Edit/Delete buttons clickable above the card-wide link */
.watch-card .card-footer {
  position: relative;
  z-index: 2;
}

/* Detail page */
.detail-img {
  height: 420px;
  border: 1px solid var(--border);
  border-radius: 8px;
}

.detail-list li {
  display: flex;
  justify-content: space-between;
  padding: 0.6rem 0;
  border-bottom: 1px solid var(--border);
}

.detail-list span {
  color: #999;
}

/* Settings page */
.settings-wrapper {
  max-width: 720px;
}

.danger-zone {
  border-color: rgba(220, 53, 69, 0.5);
}

/* Error page */
.error-code {
  font-family: 'Playfair Display', serif;
  font-size: 6rem;
  line-height: 1;
  color: var(--gold);
}

.error-stack {
  max-width: 800px;
  max-height: 300px;
  margin: 2rem auto 0;
  padding: 1rem;
  overflow: auto;
  white-space: pre-wrap;
  text-align: left;
  font-size: 0.75rem;
  color: #999;
  background: #101010;
  border: 1px solid var(--border);
  border-radius: 8px;
}

/* Eye button next to password boxes */
.toggle-password {
  background: #101010;
  color: #999;
  border: 1px solid #333;
}

.toggle-password:hover {
  color: var(--gold);
  border-color: #333;
}

/* Toast notifications */
.vault-toast {
  background: #181818;
  color: #e8e8e8;
  border: 1px solid var(--border);
  border-left: 4px solid var(--gold);
}

.vault-toast .fa-circle-check { color: var(--gold); }
.toast-danger { border-left-color: #dc3545; }
.toast-danger .fa-circle-exclamation { color: #dc3545; }
.toast-warning { border-left-color: #ffc107; }

/* ===== Phone screens (narrower than 576px) ===== */
@media (max-width: 576px) {
  /* Smaller headline on the splash page */
  .hero .display-3 {
    font-size: 2.5rem;
  }

  /* Splash page buttons stack full-width */
  .hero .btn {
    display: block;
    width: 100%;
    margin: 0 0 0.75rem 0 !important;
  }

  /* Smaller page titles */
  h1 {
    font-size: 1.8rem;
  }

  /* Search and sort take the full width */
  .toolbar form,
  .toolbar-input {
    width: 100%;
    min-width: 0;
  }

  /* Filter tabs stretch across the screen */
  .toolbar .btn-group {
    width: 100%;
  }

  .toolbar .btn-group .btn {
    flex: 1;
  }

  /* Smaller stat numbers so they fit two per row */
  .stat-number {
    font-size: 1.4rem;
  }

  /* Shorter photo on the detail page */
  .detail-img {
    height: 300px;
  }
}

/* File upload button */
.vault-form input[type="file"]::file-selector-button {
  background: var(--gold);
  color: #000;
  border: none;
}

/* Tag chips (clickable, and above the card-wide link) */
.tag-chip {
  position: relative;
  z-index: 2;
  display: inline-block;
  margin: 0 0.25rem 0.25rem 0;
  padding: 0.15rem 0.6rem;
  font-size: 0.8rem;
  color: var(--gold);
  background: rgba(201, 162, 75, 0.1);
  border: 1px solid rgba(201, 162, 75, 0.35);
  border-radius: 999px;
  text-decoration: none;
}

.tag-chip:hover {
  background: var(--gold);
  color: #000;
}

/* Insights charts */
.chart-box {
  position: relative;
  height: 300px;
}

/* Gold on/off switches */
.form-check-input:checked {
  background-color: var(--gold);
  border-color: var(--gold);
}

/* Continue with Google button */
.google-btn {
  background: #fff;
  color: #1f1f1f;
  border: 1px solid #dadce0;
  font-weight: 500;
}

.google-btn:hover {
  background: #f1f1f1;
  color: #1f1f1f;
}

/* "or" line between social buttons and the form */
.or-divider {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  color: #777;
  font-size: 0.85rem;
}

.or-divider::before,
.or-divider::after {
  content: '';
  flex: 1;
  border-top: 1px solid var(--border);
}

/* Auto-fill box on Add/Edit */
.lookup-box {
  background: #101010;
  border: 1px dashed var(--border);
  border-radius: 8px;
}

/* Fields filled by auto-fill are outlined in gold until you edit them */
.vault-form .autofilled {
  border-color: var(--gold) !important;
  box-shadow: 0 0 0 0.15rem rgba(201, 162, 75, 0.25);
}


/* Confirmation pop-up (delete watch / delete account) */
.vault-modal {
  background: var(--card);
  color: #e8e8e8;
  border: 1px solid var(--border);
  border-top: 3px solid var(--gold);
  border-radius: 12px;
}

.vault-modal-icon {
  width: 60px;
  height: 60px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  font-size: 1.5rem;
  color: #dc3545;
  background: rgba(220, 53, 69, 0.12);
}

.modal-backdrop.show {
  opacity: 0.75;
}

/* The Vault panel on the detail page */
.vault-panel {
  background: #101010;
  border: 1px solid var(--border);
  border-left: 3px solid var(--gold);
  border-radius: 8px;
}

.vault-panel .serial {
  color: #e8e8e8;
  background: transparent;
  letter-spacing: 0.05em;
}

/* Service history list */
.service-list li {
  padding: 0.6rem 0;
  border-bottom: 1px solid var(--border);
}

/* "Sold" badge */
.badge-sold {
  background: #3a3a3a;
  color: #ccc;
}

/* Timeline page */
.timeline-wrapper {
  max-width: 760px;
}

.timeline-year {
  margin: 2rem 0 1rem;
  color: var(--gold);
}

.timeline {
  position: relative;
  margin: 0;
  padding-left: 2.5rem;
  border-left: 2px solid var(--border);
}

.timeline-item {
  position: relative;
  margin-bottom: 1rem;
}

.timeline-dot {
  position: absolute;
  left: -3.35rem;
  top: 0.6rem;
  width: 2.1rem;
  height: 2.1rem;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  font-size: 0.85rem;
  background: var(--card);
  border: 2px solid var(--gold);
  color: var(--gold);
}

.timeline-sold .timeline-dot { border-color: #6c757d; color: #adb5bd; }
.timeline-wishlist .timeline-dot { border-color: #888; color: #ccc; }
.timeline-service .timeline-dot { border-color: #5c7cfa; color: #91a7ff; }

.timeline-card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 0.75rem 1rem;
}

.timeline-title {
  color: #e8e8e8;
  font-weight: 500;
  text-decoration: none;
}

.timeline-title:hover {
  color: var(--gold);
}

/* Navbar dropdown */
.vault-dropdown {
  background: #111;
  border: 1px solid var(--border);
}

.vault-dropdown .dropdown-item:hover,
.vault-dropdown .dropdown-item:focus {
  background: rgba(201, 162, 75, 0.15);
  color: var(--gold);
}

/* Rotation calendar: 7 columns */
.calendar {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 6px;
}

.calendar-head {
  text-align: center;
  font-size: 0.75rem;
  color: #888;
  text-transform: uppercase;
}

.calendar-cell {
  position: relative;
  min-height: 92px;
  padding: 4px;
  background: #101010;
  border: 1px solid var(--border);
  border-radius: 6px;
  overflow: hidden;
}

.calendar-cell.empty {
  background: transparent;
  border-color: transparent;
}

.calendar-cell.today {
  border-color: var(--gold);
}

.calendar-cell.worn {
  background: rgba(201, 162, 75, 0.06);
}

.calendar-day {
  font-size: 0.75rem;
  color: #999;
}

.calendar-watch {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2px;
  margin-top: 2px;
  color: #e8e8e8;
  text-decoration: none;
  font-size: 0.7rem;
  text-align: center;
}

.calendar-watch img {
  width: 42px;
  height: 42px;
  object-fit: cover;
  border-radius: 50%;
  border: 1px solid var(--gold);
}

.calendar-watch .fa-clock {
  font-size: 1.6rem;
  color: var(--gold);
  margin: 6px 0;
}

.calendar-name {
  max-width: 100%;
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
}

.calendar-more {
  position: absolute;
  top: 4px;
  right: 6px;
  font-size: 0.7rem;
  color: var(--gold);
}

/* Smaller calendar on phones: hide names, smaller photos */
@media (max-width: 576px) {
  .calendar-cell { min-height: 58px; }
  .calendar-name { display: none; }
  .calendar-watch img { width: 30px; height: 30px; }
}

/* Compare page */
.compare-table {
  --bs-table-bg: transparent;
  --bs-table-color: #e8e8e8;
  border-color: var(--border);
  min-width: 600px;
}

.compare-table th[scope="row"] {
  color: #999;
  font-weight: 500;
  white-space: nowrap;
}

.compare-img {
  height: 160px;
  border: 1px solid var(--border);
  border-radius: 8px;
}

.compare-name {
  color: #e8e8e8;
  font-family: 'Playfair Display', serif;
  font-size: 1.15rem;
  text-decoration: none;
}

.compare-name:hover {
  color: var(--gold);
}

/* Photo gallery on the detail page */
.gallery {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(72px, 1fr));
  gap: 8px;
}

.gallery-item {
  position: relative;
  aspect-ratio: 1;
  border: 1px solid var(--border);
  border-radius: 6px;
  overflow: hidden;
}

.gallery-item.is-main { border-color: var(--gold); }
.gallery-item.is-viewing { outline: 2px solid var(--gold); }

.gallery-thumb {
  position: absolute;
  inset: 0;
  padding: 0;
  border: 0;
  background: #101010;
}

.gallery-actions {
  position: absolute;
  top: 3px;
  right: 3px;
  display: flex;
  gap: 3px;
}

.gallery-actions button {
  width: 22px;
  height: 22px;
  padding: 0;
  border: 0;
  border-radius: 50%;
  font-size: 0.65rem;
  color: #fff;
  background: rgba(0, 0, 0, 0.65);
}

.gallery-actions button:hover { color: var(--gold); }

.photo-input {
  background: #101010;
  color: #b5b5b5;
  border: 1px solid #333;
}

.photo-input::file-selector-button {
  background: #222;
  color: #e8e8e8;
  border: none;
}

/* Friends page */
.friends-wrapper {
  max-width: 760px;
}

.friend-row {
  padding: 0.85rem 1rem;
  margin-bottom: 0.5rem;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 8px;
}

.friend-avatar {
  width: 42px;
  height: 42px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  font-family: 'Playfair Display', serif;
  font-size: 1.2rem;
  color: #000;
  background: var(--gold);
}

.friend-name {
  color: #e8e8e8;
  font-weight: 500;
  text-decoration: none;
}

.friend-name:hover {
  color: var(--gold);
}

/* Wrist Checks feed */
.feed-wrapper {
  max-width: 620px;
}

.post-card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 10px;
  overflow: hidden;
}

/* Photos scroll sideways and snap one at a time */
.post-photos {
  display: flex;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  background: #000;
}

.post-photos img {
  flex: 0 0 100%;
  width: 100%;
  aspect-ratio: 1;
  object-fit: cover;
  scroll-snap-align: start;
}

.reaction {
  padding: 0.2rem 0.65rem;
  font-size: 0.95rem;
  color: #e8e8e8;
  background: #101010;
  border: 1px solid var(--border);
  border-radius: 999px;
}

.reaction:hover,
.reaction.mine {
  border-color: var(--gold);
  background: rgba(201, 162, 75, 0.15);
}

.small-avatar {
  width: 34px;
  height: 34px;
  font-size: 1rem;
}

.comment {
  padding: 0.6rem 0;
  border-bottom: 1px solid var(--border);
}

/* Notification bell */
.bell-badge {
  position: absolute;
  top: 2px;
  right: -4px;
  min-width: 18px;
  padding: 0 5px;
  font-size: 0.65rem;
  line-height: 18px;
  text-align: center;
  color: #000;
  background: var(--gold);
  border-radius: 999px;
}

.friend-row.unread {
  border-color: rgba(201, 162, 75, 0.5);
}

.unread-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: var(--gold);
}

/* Clock page */
.clock-face {
  width: 100%;
  max-width: 440px;
}

.clock-face .bezel { fill: #0b0b0b; stroke: var(--gold); stroke-width: 2; }
.clock-face .dial { fill: #141414; stroke: #2c2c2c; }
.clock-face .bezel-num { fill: #b5b5b5; font-size: 10px; text-anchor: middle; font-family: 'Inter', sans-serif; }
.clock-face .marker { stroke: #555; stroke-width: 1; }
.clock-face .marker-big { stroke: var(--gold); stroke-width: 3; }
.clock-face .brand { fill: var(--gold); font-size: 9px; letter-spacing: 2px; text-anchor: middle; font-family: 'Playfair Display', serif; }
.clock-face .moon-window { fill: #0b1530; stroke: var(--gold); }
.clock-face .moon-dark { fill: #1c2747; }
.clock-face .moon-lit { fill: #f2e6bf; }
.clock-face .hand { stroke-linecap: round; }
.clock-face .hand-hour { stroke: #e8e8e8; stroke-width: 6; }
.clock-face .hand-minute { stroke: #e8e8e8; stroke-width: 4; }
.clock-face .hand-second { stroke: var(--gold); stroke-width: 1.5; }
.clock-face .hand-cap { fill: var(--gold); }

.digital {
  font-family: 'Playfair Display', serif;
  font-size: 1.6rem;
  color: var(--gold);
}

.zone-swatch {
  flex: 0 0 14px;
  height: 14px;
  border-radius: 50%;
}

.zone-time {
  min-width: 48px;
  text-align: right;
  font-variant-numeric: tabular-nums;
}

/* ===== Marketplace ===== */
.listing-price {
  font-family: 'Playfair Display', serif;
  font-size: 1.25rem;
  color: var(--gold);
}

.listing-status {
  position: absolute;
  top: 10px;
  left: 10px;
  z-index: 1;
  padding: 0.2rem 0.6rem;
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  border-radius: 4px;
}

.status-reserved { background: #ffc107; color: #000; }
.status-sold { background: #dc3545; color: #fff; }
.status-removed { background: #555; color: #fff; }

/* Save heart on cards (above the card-wide link) */
.save-heart {
  position: absolute;
  top: 10px;
  right: 10px;
  z-index: 3;
}

.save-heart button {
  width: 34px;
  height: 34px;
  border: 0;
  border-radius: 50%;
  color: var(--gold);
  background: rgba(0, 0, 0, 0.65);
}

.market-filters .form-control,
.market-filters .form-select {
  background: #101010;
  color: #e8e8e8;
  border: 1px solid #333;
}

.listing-description {
  white-space: pre-line;
  color: #cfcfcf;
}

.safety-box {
  background: rgba(201, 162, 75, 0.06);
  border: 1px solid rgba(201, 162, 75, 0.3);
  border-radius: 8px;
}

.seller-avatar {
  width: 64px;
  height: 64px;
  font-size: 1.8rem;
}

/* Star rating picker (5 → 1 in the HTML, shown left to right with row-reverse) */
.star-picker {
  display: inline-flex;
  flex-direction: row-reverse;
  gap: 4px;
}

.star-picker input { display: none; }
.star-picker label { font-size: 1.8rem; color: #444; cursor: pointer; }
.star-picker input:checked ~ label,
.star-picker label:hover,
.star-picker label:hover ~ label { color: var(--gold); }

/* Keep / remove photos on the listing form */
.keep-photo { cursor: pointer; }
.keep-photo input {
  position: absolute;
  top: 6px;
  right: 6px;
  width: 18px;
  height: 18px;
  accent-color: var(--gold);
}

/* Messages */
.thread-thumb {
  flex: 0 0 52px;
  width: 52px;
  height: 52px;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  border-radius: 6px;
  background: #101010;
  color: var(--gold);
}

.thread-thumb img { width: 100%; height: 100%; object-fit: cover; }

.chat { display: flex; flex-direction: column; gap: 10px; }
.chat-row { display: flex; flex-direction: column; align-items: flex-start; max-width: 80%; }
.chat-row.mine { align-self: flex-end; align-items: flex-end; }

.chat-bubble {
  padding: 0.55rem 0.85rem;
  white-space: pre-line;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 14px 14px 14px 4px;
}

.chat-row.mine .chat-bubble {
  color: #000;
  background: var(--gold);
  border-color: var(--gold);
  border-radius: 14px 14px 4px 14px;
}

.chat-offer {
  padding: 0.75rem 1rem;
  background: #101010;
  border: 1px solid var(--gold);
  border-radius: 10px;
}

.chat-time { font-size: 0.7rem; color: #777; margin-top: 2px; }
.offer-accepted { color: #46a758; }
.offer-declined, .offer-withdrawn { color: #999; }
.offer-input { max-width: 180px; background: #101010; color: #e8e8e8; border: 1px solid #333; }

/* ===== Navbar "Buy a watch" mega menu ===== */
.mega-menu {
  padding: 1.5rem;
  background: #111;
  border: 1px solid var(--border);
  border-top: 2px solid var(--gold);
}

.mega-grid {
  display: grid;
  gap: 1.5rem;
}

.mega-title {
  margin-bottom: 0.75rem;
  font-family: 'Playfair Display', serif;
  font-size: 1.05rem;
  color: #fff;
}

.mega-link {
  display: block;
  padding: 0.2rem 0;
  color: #cfcfcf;
  text-decoration: none;
}

.mega-link:hover {
  color: var(--gold);
}

.mega-all {
  display: inline-block;
  margin-top: 0.75rem;
  color: var(--gold);
  font-size: 0.9rem;
}

.mega-brand-list {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  column-gap: 1.5rem;
}

/* Feature card on the right */
.mega-card {
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  min-height: 240px;
  padding: 1.25rem;
  color: #e8e8e8;
  text-decoration: none;
  border-radius: 8px;
  background: radial-gradient(circle at 80% 20%, rgba(201, 162, 75, 0.35), transparent 60%), linear-gradient(160deg, #2a2416, #0e0e0e);
  border: 1px solid rgba(201, 162, 75, 0.35);
}

.mega-card:hover { color: #fff; border-color: var(--gold); }
.mega-card-kicker { font-size: 0.8rem; color: var(--gold); text-transform: uppercase; letter-spacing: 0.05em; }
.mega-card-title { font-family: 'Playfair Display', serif; font-size: 1.8rem; line-height: 1.1; margin: 0.25rem 0; }
.mega-card-text { font-size: 0.85rem; color: #b5b5b5; }
.mega-card .btn { align-self: flex-start; }

/* Wide screens: big three-column panel across the marketplace bar */
@media (min-width: 992px) {
  .market-nav .container { position: relative; }
  .market-nav .mega-dropdown { position: static; }
  .market-nav .mega-menu {
    left: 0;
    right: 0;
    width: 100%;
    margin-top: 0.5rem !important;
  }
  .mega-grid { grid-template-columns: 1.6fr 1.3fr 1fr; }
}

/* Phones: brands in two columns, hide the feature card to save space */
@media (max-width: 991.98px) {
  .mega-menu { padding: 1rem; }
  .mega-card { display: none; }
}

/* "Sell a watch" menu: little descriptions under items */
.sell-menu .dropdown-item small {
  display: block;
  margin-left: 1.4rem;
  font-size: 0.75rem;
  color: #888;
}

/* All brands page */
.brands-columns {
  columns: 4 200px;
  column-gap: 2rem;
}

.brand-group {
  break-inside: avoid;
  margin-bottom: 1.5rem;
}

/* ===== Marketplace bar (under the main navbar on marketplace pages) ===== */
.market-nav {
  background: #141414;
  border-bottom: 1px solid var(--border);
}

.market-nav-title {
  font-family: 'Playfair Display', serif;
  font-size: 1.2rem;
  color: var(--gold);
  text-decoration: none;
  white-space: nowrap;
}

.market-search {
  position: relative;
  min-width: 220px;
  max-width: 520px;
}

.market-search i {
  position: absolute;
  left: 12px;
  top: 50%;
  transform: translateY(-50%);
  color: #777;
}

.market-search input {
  width: 100%;
  padding: 0.45rem 0.75rem 0.45rem 2.2rem;
  color: #e8e8e8;
  background: #0b0b0b;
  border: 1px solid #333;
  border-radius: 6px;
}

.market-search input:focus {
  outline: none;
  border-color: var(--gold);
}

.market-menu-link {
  display: inline-block;
  padding: 0.45rem 0.7rem;
  color: #cfcfcf;
  text-decoration: none;
  border-radius: 6px;
  white-space: nowrap;
}

.market-menu-link:hover,
.market-menu-link.show {
  color: var(--gold);
  background: rgba(201, 162, 75, 0.08);
}

/* Phones: the bar stacks and the search goes full width */
@media (max-width: 991.98px) {
  .market-search { order: 3; flex-basis: 100%; max-width: none; }
  .market-nav .mega-menu { width: calc(100vw - 2rem); }
}

/* ===== Add Watch: "Find your watch" ===== */
.finder-search {
  position: relative;
}

.finder-search i {
  position: absolute;
  left: 16px;
  top: 50%;
  transform: translateY(-50%);
  color: #777;
}

.finder-search input {
  width: 100%;
  padding: 0.85rem 1rem 0.85rem 2.75rem;
  font-size: 1.05rem;
  color: #e8e8e8;
  background: #0b0b0b;
  border: 1px solid #333;
  border-radius: 8px;
}

.finder-search input:focus {
  outline: none;
  border-color: var(--gold);
  box-shadow: 0 0 0 0.2rem rgba(201, 162, 75, 0.25);
}

.finder .form-select {
  background-color: #101010;
  color: #e8e8e8;
  border: 1px solid #333;
}

.finder-card {
  display: flex;
  flex-direction: column;
  justify-content: flex-start; /* buttons centre their content by default, which made the cards uneven */
  width: 100%;
  height: 100%;
  padding: 0 0 0.75rem;
  text-align: left;
  color: #e8e8e8;
  background: transparent;
  border: 1px solid transparent;
  border-radius: 8px;
  transition: border-color 0.15s;
}

.finder-card > span:not(.finder-img),
.finder-card > strong {
  padding: 0 0.6rem;
}

.finder-card:hover,
.finder-card.picked {
  border-color: var(--gold);
}

.finder-img {
  display: flex;
  width: 100%;
  flex-shrink: 0;
  align-items: center;
  justify-content: center;
  aspect-ratio: 1;
  margin-bottom: 0.6rem;
  overflow: hidden;
  border-radius: 8px;
  background: #fff;
}

.finder-img img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.finder-img .fa-clock {
  font-size: 2.5rem;
  color: #bbb;
}

/* ===== "Find photos" picker on Add/Edit ===== */
.photo-choice {
  display: block;
  width: 100%;
  aspect-ratio: 1;
  padding: 0;
  overflow: hidden;
  background: #fff;
  border: 2px solid transparent;
  border-radius: 8px;
}

.photo-choice img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.photo-choice:hover,
.photo-choice.picked {
  border-color: var(--gold);
}

.finder-img .fa-spinner {
  font-size: 1.8rem;
  color: #bbb;
}

/* Settings sections reached from the account dropdown */
[data-anchor] {
  scroll-margin-top: 90px;
}

[data-anchor]:target {
  color: var(--gold);
}

.finder-price {
  color: var(--gold);
  font-weight: 500;
}

/* ===== Collector extras ===== */
.badge-tile {
  height: 100%;
  padding: 1.25rem 1rem;
  text-align: center;
  background: #141414;
  border: 1px solid #262626;
  border-radius: 10px;
  opacity: 0.6;
}

.badge-tile.earned {
  opacity: 1;
  border-color: var(--gold);
}

.badge-icon {
  font-size: 2rem;
  color: #6b6b6b;
}

.badge-tile.earned .badge-icon {
  color: var(--gold);
}

.badge-progress {
  display: block;
  width: 100%;
  height: 6px;
  margin-bottom: 0.25rem;
  accent-color: var(--gold);
}

.badge-chip {
  display: inline-block;
  padding: 0.2rem 0.6rem;
  font-size: 0.8rem;
  color: var(--gold);
  border: 1px solid rgba(201, 162, 75, 0.5);
  border-radius: 999px;
}

.share-canvas {
  width: 100%;
  max-width: 540px;
  height: auto;
  border: 1px solid #2c2c2c;
  border-radius: 8px;
}

.accuracy-clock {
  font-family: 'Courier New', monospace;
  font-size: 2.6rem;
  letter-spacing: 0.05em;
  color: var(--gold);
}

.accuracy-rate {
  font-size: 1.6rem;
  font-weight: 600;
}

.accuracy-rate.good {
  color: #5cb85c;
}

.accuracy-rate.off {
  color: #e0a84b;
}

.size-svg {
  width: 100%;
  height: auto;
  background: #0b0b0b;
  border-radius: 8px;
}

.daily-wrap {
  max-width: 640px;
}

.daily-photo {
  width: 100%;
  aspect-ratio: 1;
  background-color: #fff;
  background-repeat: no-repeat;
  background-position: 50% 45%;
  border: 1px solid #2c2c2c;
  border-radius: 12px;
  transition: background-size 0.6s ease;
}

.daily-photo.done {
  background-size: contain !important;
  background-position: center;
}

.daily-guess {
  padding: 0.5rem 0.75rem;
  margin-bottom: 0.4rem;
  border-radius: 6px;
  background: #141414;
}

.daily-guess.right {
  border-left: 4px solid #5cb85c;
}

.daily-guess.close {
  border-left: 4px solid #e0bb63;
}

.daily-guess.wrong {
  border-left: 4px solid #a94442;
}

.match-card {
  cursor: default;
}

.review-stars {
  color: var(--gold);
  letter-spacing: 0.05em;
}

.review-quote {
  padding-left: 0.75rem;
  border-left: 3px solid rgba(201, 162, 75, 0.5);
}

.trade-match .fa-right-left {
  font-size: 1.1rem;
}

/* Photo credits and legal pages */
.photo-credit {
  font-size: 0.75rem;
  color: #8a8a8a;
}

.photo-credit a {
  color: #8a8a8a;
}

.legal-page {
  max-width: 820px;
}

.legal-page h4 {
  margin-top: 2rem;
  color: var(--gold);
}

.finder-estimate {
  font-size: 0.85rem;
  color: #9a9a9a;
}
