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

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
  --gold: #B8860B;
  --gold-light: #D4A017;
  --gold-muted: #E8D5A3;
  --cream: #FDFAF4;
  --warm-white: #F9F6EE;
  --border: rgba(184,134,11,0.18);
  --border-strong: rgba(184,134,11,0.35);
  --ink: #1A1408;
  --ink-muted: #5C4F30;
  --ink-faint: #9B8B6A;
  --red: #C0392B;
  --green: #2D7A4E;
  --amber: #92400E;
}

html, body {
  font-family: 'DM Sans', sans-serif;
  background: var(--cream);
  color: var(--ink);
  font-size: 16px;
  line-height: 1.6;
  min-height: 100vh;
}

h1, h2, h3, h4 {
  font-family: 'Playfair Display', serif;
  font-weight: 600;
  color: var(--ink);
  line-height: 1.2;
}

a { color: var(--gold); text-decoration: none; }
a:hover { color: var(--gold-light); }

input, select, textarea, button {
  font-family: 'DM Sans', sans-serif;
}

/* NAV — layout defined in sidebar section below */
.nav-left { display: flex; align-items: center; gap: 8px; }
.st-logo { display: flex; align-items: center; gap: 10px; text-decoration: none; }
.st-logo-text {
  font-family: 'Playfair Display', serif; font-size: 20px; font-weight: 600;
  color: var(--ink); letter-spacing: -0.3px;
}
.st-logo-text .gold { color: var(--gold); }
.st-nav-links { display: flex; list-style: none; gap: 16px; align-items: center; }
.st-nav-links a {
  font-size: 13px; font-weight: 400; color: var(--ink-muted);
  text-decoration: none; transition: color 0.15s; white-space: nowrap;
}
.st-nav-links a:hover, .st-nav-links a.active { color: var(--ink); }
.st-nav-actions { display: flex; align-items: center; gap: 6px; flex-shrink: 0; flex-wrap: nowrap; }
.btn-ghost-sm {
  padding: 5px 12px; border: 0.5px solid var(--border-strong); border-radius: 6px;
  background: transparent; font-size: 12px; font-weight: 500; color: var(--ink-muted);
  cursor: pointer; transition: all 0.15s; text-decoration: none; display: inline-block; white-space: nowrap;
}
.btn-ghost-sm:hover { background: var(--warm-white); color: var(--ink); }
.btn-primary-sm {
  padding: 5px 14px; border: none; border-radius: 6px; background: var(--gold);
  font-size: 12px; font-weight: 500; color: #fff; cursor: pointer;
  transition: background 0.15s; text-decoration: none; display: inline-block; white-space: nowrap;
}
.btn-primary-sm:hover { background: var(--gold-light); }

/* HERO */
.hero { text-align: center; padding: 80px 48px 64px; background: transparent; border: none; width: 100%; }
.hero-badge {
  display: inline-flex; align-items: center; gap: 6px; padding: 4px 14px;
  border: 0.5px solid var(--border-strong); border-radius: 20px;
  font-size: 12px; color: var(--gold); margin-bottom: 24px; letter-spacing: 0.3px;
}
.hero-title {
  font-family: 'Playfair Display', serif; font-size: 52px; font-weight: 600;
  color: var(--ink); letter-spacing: -0.5px; margin-bottom: 18px;
  border: none; outline: none; box-shadow: none;
}
.hero-sub {
  font-size: 16px; font-weight: 300; color: var(--ink-muted);
  max-width: 480px; margin: 0 auto 36px; line-height: 1.65;
}
.hero-actions { display: flex; align-items: center; justify-content: center; gap: 12px; }
.btn-hero-gold {
  padding: 12px 32px; background: var(--gold); color: #fff; border: none;
  border-radius: 7px; font-size: 15px; font-weight: 500; cursor: pointer;
  transition: background 0.15s; text-decoration: none; display: inline-block;
}
.btn-hero-gold:hover { background: var(--gold-light); color: #fff; }
.btn-hero-outline {
  padding: 12px 32px; background: transparent; color: var(--ink-muted);
  border: 0.5px solid var(--border-strong); border-radius: 7px;
  font-size: 15px; font-weight: 500; cursor: pointer; transition: all 0.15s;
  text-decoration: none; display: inline-block;
}
.btn-hero-outline:hover { background: var(--warm-white); color: var(--ink); }

/* HOME SECTIONS */
.home-section { padding: 48px 48px 40px; }
.section-header { display: flex; align-items: baseline; justify-content: space-between; margin-bottom: 28px; }
.section-title { font-family: 'Playfair Display', serif; font-size: 24px; font-weight: 600; color: var(--ink); }
.section-link { font-size: 13px; color: var(--gold); text-decoration: none; }
.section-link:hover { color: var(--gold-light); }
.empty-state {
  text-align: center; padding: 60px 0; color: var(--ink-faint);
  display: flex; flex-direction: column; align-items: center; gap: 14px; font-size: 14px;
}
.auction-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(250px, 1fr)); gap: 16px; }

/* AUCTION CARD */
.auction-card {
  background: #fff; border: 0.5px solid var(--border); border-radius: 10px;
  overflow: hidden; cursor: pointer; transition: border-color 0.15s, transform 0.15s;
}
.auction-card:hover { border-color: var(--gold-muted); transform: translateY(-2px); }
.card-img {
  height: 160px; background: var(--warm-white); display: flex; align-items: center;
  justify-content: center; border-bottom: 0.5px solid var(--border);
  position: relative; overflow: hidden;
}
.card-img img { width: 100%; height: 100%; object-fit: contain; padding: 8px; background: var(--warm-white); }
.card-category {
  position: absolute; top: 10px; right: 10px; background: #fff;
  border: 0.5px solid var(--border-strong); border-radius: 4px;
  font-size: 11px; font-weight: 500; color: var(--gold); padding: 3px 8px;
}
.card-body { padding: 14px 16px 16px; }
.card-title { font-size: 14px; font-weight: 500; color: var(--ink); margin-bottom: 12px; line-height: 1.35; min-height: 38px; }
.card-footer { display: flex; align-items: flex-end; justify-content: space-between; }
.card-price-label { font-size: 11px; color: var(--ink-faint); }
.card-price { font-family: 'Playfair Display', serif; font-size: 17px; font-weight: 600; color: var(--ink); }
.card-meta { text-align: right; font-size: 12px; color: var(--ink-faint); }
.card-bids { font-size: 11px; color: var(--ink-faint); margin-top: 3px; }

/* HOW IT WORKS */
.how-section { background: var(--warm-white); border-top: 0.5px solid var(--border); padding: 56px 0; }
.how-inner { max-width: 1100px; margin: 0 auto; padding: 0 48px; }
.steps-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 24px; margin-top: 40px; }
.step { text-align: center; padding: 28px 20px; background: #fff; border: 0.5px solid var(--border); border-radius: 12px; }
.step-icon {
  width: 48px; height: 48px; margin: 0 auto 14px;
  border: 0.5px solid var(--border-strong); border-radius: 10px;
  background: var(--warm-white); display: flex; align-items: center; justify-content: center;
}
.step-num { font-family: 'Playfair Display', serif; font-size: 11px; color: var(--gold); margin-bottom: 8px; letter-spacing: 0.5px; }
.step-title { font-size: 15px; font-weight: 500; color: var(--ink); margin-bottom: 8px; }
.step-desc { font-size: 13px; color: var(--ink-faint); line-height: 1.65; font-weight: 300; }

/* UTILITIES */
.page-wrap { padding: 32px 48px; max-width: 1200px; margin: 0 auto; }
.page-title { font-size: 28px; margin-bottom: 24px; }
.status-pill { display: inline-flex; align-items: center; gap: 5px; padding: 3px 10px; border-radius: 20px; font-size: 11px; font-weight: 500; }
.pill-pending  { background:#FEF3C7; color:#92400E; border:0.5px solid #F59E0B; }
.pill-approved { background:#ECFDF5; color:#065F46; border:0.5px solid #6EE7B7; }
.pill-rejected { background:#FEE2E2; color:#991B1B; border:0.5px solid #FCA5A5; }
.pill-live     { background:#EFF6FF; color:#1E40AF; border:0.5px solid #93C5FD; }
.pill-closed   { background:#F3F4F6; color:#374151; border:0.5px solid #D1D5DB; }
.btn-primary { padding: 9px 22px; background: var(--gold); color: #fff; border: none; border-radius: 6px; font-size: 14px; font-weight: 500; cursor: pointer; transition: background 0.15s; text-decoration: none; display: inline-block; }
.btn-primary:hover { background: var(--gold-light); color: #fff; }
.btn-outline { padding: 9px 22px; background: transparent; color: var(--ink-muted); border: 0.5px solid var(--border-strong); border-radius: 6px; font-size: 14px; font-weight: 500; cursor: pointer; transition: all 0.15s; text-decoration: none; display: inline-block; }
.btn-outline:hover { background: var(--warm-white); color: var(--ink); }
.btn-danger { padding: 9px 22px; background: transparent; color: var(--red); border: 0.5px solid rgba(192,57,43,0.35); border-radius: 6px; font-size: 14px; font-weight: 500; cursor: pointer; transition: all 0.15s; }
.btn-danger:hover { background: #FEE2E2; }
.card { background: #fff; border: 0.5px solid var(--border); border-radius: 10px; padding: 20px 24px; }
.form-label { font-size: 13px; font-weight: 500; color: var(--ink-muted); display: block; margin-bottom: 6px; }
.form-input { width: 100%; padding: 9px 12px; border: 0.5px solid var(--border-strong); border-radius: 6px; background: #fff; font-size: 14px; color: var(--ink); outline: none; transition: border-color 0.15s; }
.form-input:focus { border-color: var(--gold); }
.form-select { width: 100%; padding: 9px 12px; border: 0.5px solid var(--border-strong); border-radius: 6px; background: #fff; font-size: 14px; color: var(--ink); outline: none; cursor: pointer; }
.form-group { margin-bottom: 18px; }
table { width: 100%; border-collapse: collapse; }
th { font-size: 11px; color: var(--ink-faint); font-weight: 500; text-align: left; padding: 10px 16px; background: var(--warm-white); border-bottom: 0.5px solid var(--border); letter-spacing: 0.3px; text-transform: uppercase; }
td { font-size: 13px; color: var(--ink); padding: 11px 16px; border-bottom: 0.5px solid var(--border); vertical-align: middle; }
tr:last-child td { border-bottom: none; }
tr:hover td { background: var(--warm-white); }
footer { padding: 24px 48px; border-top: 0.5px solid var(--border); display: flex; align-items: center; justify-content: space-between; font-size: 13px; color: var(--ink-faint); margin-top: auto; }
.countdown { font-size: 13px; font-weight: 500; color: var(--ink-muted); }
.countdown.amber { color: var(--amber); }
.countdown.red { color: var(--red); }
.countdown.closed { color: var(--ink-faint); font-weight: 400; }

/* EXISTING PAGE STYLES */
.section { padding: 32px 48px; }
.loading { text-align: center; padding: 40px; color: var(--ink-faint); font-size: 14px; }
.warning-banner { background: #FEF3C7; border: 0.5px solid #F59E0B; border-radius: 8px; padding: 14px 20px; color: var(--amber); font-size: 14px; margin-bottom: 24px; }
.info-banner { background: var(--warm-white); border: 0.5px solid var(--border-strong); border-radius: 8px; padding: 14px 20px; color: var(--ink-muted); font-size: 14px; margin-top: 16px; }
.tab-bar { display: flex; gap: 0; border-bottom: 0.5px solid var(--border); margin-bottom: 24px; }
.tab-btn { padding: 10px 20px; background: none; border: none; border-bottom: 2px solid transparent; font-size: 14px; font-weight: 500; color: var(--ink-faint); cursor: pointer; transition: all 0.15s; }
.tab-btn:hover { color: var(--ink-muted); }
.tab-active { color: var(--ink); border-bottom-color: var(--gold); }
.tab-content { margin-top: 8px; }
.tab-content-header { display: flex; align-items: center; justify-content: space-between; margin-bottom: 16px; }
.dashboard-list { display: flex; flex-direction: column; gap: 2px; }
.dashboard-list-item { display: flex; align-items: center; justify-content: space-between; padding: 12px 16px; background: #fff; border: 0.5px solid var(--border); border-radius: 8px; text-decoration: none; color: var(--ink); transition: border-color 0.15s; }
.dashboard-list-item:hover { border-color: var(--gold-muted); }
.dashboard-list-title { font-size: 14px; font-weight: 500; }
.dashboard-list-meta { font-size: 12px; color: var(--ink-faint); margin-top: 2px; }
.status-badge { font-size: 11px; font-weight: 500; padding: 3px 10px; border-radius: 20px; }
.status-active { background: #ECFDF5; color: #065F46; }
.status-closed { background: #F3F4F6; color: #374151; }
.status-leading { background: #ECFDF5; color: #065F46; }
.status-outbid { background: #FEF3C7; color: #92400E; }
.btn-small { padding: 4px 12px; font-size: 12px; background: var(--gold); color: #fff; border-radius: 4px; text-decoration: none; }
.btn-disabled { opacity: 0.5; pointer-events: none; }

/* Auction detail */
.auction-detail { max-width: 1000px; margin: 0 auto; }
.auction-detail-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 32px; }
.auction-gallery-main { aspect-ratio: 4/3; background: var(--warm-white); border: 0.5px solid var(--border); border-radius: 10px; overflow: hidden; display: flex; align-items: center; justify-content: center; }
.auction-gallery-main img { width: 100%; height: 100%; object-fit: contain; padding: 12px; background: var(--warm-white); }
.auction-gallery-thumbs { display: flex; gap: 8px; margin-top: 8px; }
.auction-thumb { width: 60px; height: 60px; border: 0.5px solid var(--border); border-radius: 6px; overflow: hidden; cursor: pointer; transition: border-color 0.15s; }
.auction-thumb:hover, .auction-thumb-active { border-color: var(--gold); }
.auction-thumb img { width: 100%; height: 100%; object-fit: cover; }
.auction-detail-category { display: inline-block; font-size: 11px; font-weight: 500; color: var(--gold); border: 0.5px solid var(--border-strong); border-radius: 4px; padding: 3px 8px; margin-bottom: 8px; }
.auction-detail-title { font-size: 24px; margin-bottom: 8px; }
.auction-detail-seller { font-size: 13px; color: var(--ink-faint); margin-bottom: 20px; }
.auction-detail-price-block { background: var(--warm-white); border: 0.5px solid var(--border); border-radius: 8px; padding: 14px 18px; margin-bottom: 16px; }
.auction-detail-price-label { font-size: 11px; color: var(--ink-faint); }
.auction-detail-price { font-family: 'Playfair Display', serif; font-size: 28px; font-weight: 600; color: var(--ink); }
.auction-detail-meta { display: flex; gap: 24px; margin-bottom: 20px; }
.auction-detail-meta-label { font-size: 11px; color: var(--ink-faint); display: block; }
.auction-closed-banner { background: #F3F4F6; border: 0.5px solid #D1D5DB; border-radius: 8px; padding: 14px 18px; font-size: 14px; color: #374151; margin-top: 16px; }
.auction-detail-description { margin-top: 24px; padding-top: 20px; border-top: 0.5px solid var(--border); }
.auction-detail-description h3 { font-size: 16px; margin-bottom: 8px; }
.auction-detail-description p { font-size: 14px; color: var(--ink-muted); line-height: 1.65; }
.auction-card-no-image { color: var(--ink-faint); font-size: 13px; }

/* Tight meta row on auction detail */
.auction-meta-tight {
    display: flex;
    gap: 18px;
    flex-wrap: wrap;
    padding: 10px 14px;
    background: var(--warm-white);
    border: 0.5px solid var(--border);
    border-radius: 6px;
    margin-bottom: 0;
}
.auction-meta-tight .meta-label { color: var(--ink-faint); font-size: 12px; display: block; }
.auction-meta-tight .meta-value { font-weight: 500; font-size: 13px; }
.auction-meta-tight .meta-value-strong { font-weight: 600; font-size: 13px; }

/* Bid action row — bid form on left, watch button on right */
.bid-action-row {
    display: flex;
    gap: 12px;
    margin-top: 24px;
    align-items: stretch;
}
.bid-action-left { flex: 1 1 auto; min-width: 0; display: flex; }
.bid-action-left > * { flex: 1; }
.bid-action-right { flex: 0 0 auto; display: flex; }
.bid-action-watch {
    height: 100%;
    min-width: 180px;
    padding: 0 18px;
    white-space: nowrap;
}
@media (max-width: 640px) {
    .bid-action-row { flex-direction: column; }
    .bid-action-watch { width: 100%; min-width: 0; padding: 12px; }
}

/* Compact bid form */
.bid-form-compact {
    background: var(--warm-white);
    border: 0.5px solid var(--border);
    border-radius: 8px;
    padding: 12px 14px;
    width: 100%;
    box-sizing: border-box;
}
.bid-form-header {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 12px;
    margin-bottom: 2px;
}
.bid-form-action {
    display: flex;
    gap: 8px;
    align-items: stretch;
    margin-top: 6px;
}
.bid-form-action .bid-form-input {
    flex: 1;
    padding: 9px 12px;
    border: 0.5px solid var(--border-strong);
    border-radius: 6px;
    font-size: 14px;
    outline: none;
    min-width: 0;
}
.bid-form-action .bid-form-input:focus { border-color: var(--gold); }
.bid-form-submit-inline {
    padding: 0 18px;
    background: var(--gold);
    color: #fff;
    border: none;
    border-radius: 6px;
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    transition: background 0.15s;
    white-space: nowrap;
}
.bid-form-submit-inline:hover { background: var(--gold-light); }
.bid-form-submit-inline:disabled { opacity: 0.5; cursor: not-allowed; }

/* Bid form */
.bid-form { background: var(--warm-white); border: 0.5px solid var(--border); border-radius: 8px; padding: 16px 18px; margin-top: 16px; }
.bid-form-label { font-size: 11px; color: var(--ink-faint); }
.bid-form-current-price { font-size: 16px; font-weight: 600; }
.bid-form-min { font-size: 12px; color: var(--ink-faint); margin: 8px 0; }
.bid-form-input-row { display: flex; align-items: center; gap: 8px; margin-bottom: 12px; }
.bid-form-input { flex: 1; padding: 9px 12px; border: 0.5px solid var(--border-strong); border-radius: 6px; font-size: 14px; outline: none; }
.bid-form-input:focus { border-color: var(--gold); }
.bid-form-currency { font-size: 14px; color: var(--ink-faint); }
.bid-form-submit { width: 100%; padding: 10px; background: var(--gold); color: #fff; border: none; border-radius: 6px; font-size: 14px; font-weight: 500; cursor: pointer; transition: background 0.15s; }
.bid-form-submit:hover { background: var(--gold-light); }
.bid-form-submit:disabled { opacity: 0.5; cursor: not-allowed; }
.bid-form-error { color: var(--red); font-size: 13px; margin-top: 8px; }
.bid-form-success { color: var(--green); font-size: 13px; margin-top: 8px; }

/* Wanted item owner/admin actions */
.wanted-item-actions {
    display: flex;
    align-items: center;
    gap: 14px;
    margin-top: 8px;
    padding-top: 8px;
    border-top: 0.5px solid var(--border);
}
.wanted-item-edit {
    color: var(--gold);
    font-size: 12px;
    text-decoration: none;
    background: none;
    border: none;
    padding: 0;
    cursor: pointer;
}
.wanted-item-edit:hover { text-decoration: underline; }
.wanted-item-delete {
    color: #b04848;
    font-size: 12px;
    background: none;
    border: none;
    padding: 0;
    cursor: pointer;
}
.wanted-item-delete:hover:not(:disabled) { text-decoration: underline; }
.wanted-item-delete:disabled { opacity: 0.5; cursor: not-allowed; }

/* Bid history */
.bid-history { margin-top: 32px; }
.bid-history h3 { font-size: 18px; margin-bottom: 12px; }
.bid-history-item { display: flex; align-items: center; justify-content: space-between; padding: 8px 0; border-bottom: 0.5px solid var(--border); font-size: 13px; }
.bid-history-row {
    display: flex; align-items: center; gap: 12px; padding: 10px 0;
    border-bottom: 1px solid var(--border, #eee); flex-wrap: wrap;
}

/* Image lightbox */
.img-lightbox {
    position: fixed; inset: 0; background: rgba(0,0,0,0.92);
    z-index: 1000; display: flex; align-items: center; justify-content: center;
    padding: 24px; cursor: zoom-out;
}
.img-lightbox img {
    max-width: 100%; max-height: 100%; object-fit: contain;
    box-shadow: 0 8px 32px rgba(0,0,0,0.5); border-radius: 4px;
    cursor: default;
}
.img-lightbox-close {
    position: fixed; top: 16px; right: 20px; width: 44px; height: 44px;
    border-radius: 50%; border: none; background: rgba(255,255,255,0.15);
    color: #fff; font-size: 28px; line-height: 1; cursor: pointer;
    display: flex; align-items: center; justify-content: center; padding: 0;
    transition: background 0.15s;
}
.img-lightbox-close:hover { background: rgba(255,255,255,0.3); }
@media (max-width: 480px) {
    .bid-history-row { gap: 6px; font-size: 12px; }
    .bid-history-row > span:last-child { flex-basis: 100%; font-size: 11px; }
}
.bid-history-user { color: var(--ink-muted); }
.bid-history-amount { font-weight: 500; }
.bid-history-time { color: var(--ink-faint); font-size: 12px; }

/* Messages */
.message-thread-list { display: flex; flex-direction: column; gap: 2px; }
.message-thread-item { display: flex; justify-content: space-between; padding: 14px 16px; background: #fff; border: 0.5px solid var(--border); border-radius: 8px; text-decoration: none; color: var(--ink); transition: border-color 0.15s; }
.message-thread-item:hover { border-color: var(--gold-muted); }
.message-thread-unread { border-left: 3px solid var(--gold); }
.message-thread-title { font-size: 14px; font-weight: 500; }
.message-thread-other { font-size: 12px; color: var(--ink-faint); margin-top: 2px; }
.message-thread-preview { font-size: 13px; color: var(--ink-muted); margin-top: 4px; }
.message-thread-time { font-size: 11px; color: var(--ink-faint); }
.unread-badge { background: var(--red); color: #fff; font-size: 11px; font-weight: 600; min-width: 18px; height: 18px; border-radius: 9px; display: inline-flex; align-items: center; justify-content: center; padding: 0 5px; }

/* Chat */
.thread-header { display: flex; align-items: center; gap: 16px; margin-bottom: 24px; }
.thread-back { font-size: 13px; color: var(--ink-faint); }
.thread-title { font-size: 18px; }
.thread-title a { color: var(--ink); }
.chat-container { background: #fff; border: 0.5px solid var(--border); border-radius: 10px; padding: 20px; max-height: 400px; overflow-y: auto; display: flex; flex-direction: column; gap: 12px; }
.chat-bubble { max-width: 75%; padding: 10px 14px; border-radius: 10px; font-size: 14px; }
.chat-bubble-mine { align-self: flex-end; background: var(--gold); color: #fff; }
.chat-bubble-other { align-self: flex-start; background: var(--warm-white); border: 0.5px solid var(--border); color: var(--ink); }
.chat-bubble-sender { font-size: 11px; font-weight: 500; margin-bottom: 4px; }
.chat-bubble-mine .chat-bubble-sender { color: rgba(255,255,255,0.7); }
.chat-bubble-other .chat-bubble-sender { color: var(--ink-faint); }
.chat-bubble-time { font-size: 10px; margin-top: 4px; opacity: 0.6; }
.chat-input-bar { display: flex; gap: 8px; margin-top: 12px; }
.chat-input { flex: 1; padding: 10px 12px; border: 0.5px solid var(--border-strong); border-radius: 6px; font-size: 14px; resize: none; outline: none; }
.chat-input:focus { border-color: var(--gold); }
.chat-send-btn { padding: 10px 20px; }

/* Auth pages */
.auth-page { display: flex; align-items: center; justify-content: center; min-height: calc(100vh - 64px); padding: 48px; }
.auth-card { background: #fff; border: 0.5px solid var(--border); border-radius: 12px; padding: 36px 40px; width: 100%; max-width: 420px; }
.auth-card h1 { font-size: 24px; margin-bottom: 6px; }
.auth-subtitle { font-size: 14px; color: var(--ink-faint); margin-bottom: 24px; }
.auth-footer { text-align: center; font-size: 13px; color: var(--ink-faint); margin-top: 20px; }
.form-container { background: #fff; border: 0.5px solid var(--border); border-radius: 12px; padding: 32px; max-width: 640px; }
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.form-textarea { width: 100%; padding: 9px 12px; border: 0.5px solid var(--border-strong); border-radius: 6px; font-size: 14px; color: var(--ink); outline: none; resize: vertical; }
.form-textarea:focus { border-color: var(--gold); }
.form-file-input { font-size: 13px; color: var(--ink-muted); }
.form-actions { margin-top: 24px; }
.form-error { color: var(--red); font-size: 13px; margin-top: 12px; }
.validation-message { color: var(--red); font-size: 12px; margin-top: 4px; }
.image-preview-grid { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 10px; }
.image-preview-item { width: 80px; height: 80px; border: 0.5px solid var(--border); border-radius: 6px; overflow: hidden; }
.image-preview-item img { width: 100%; height: 100%; object-fit: cover; }

/* Admin Layout */
.admin-wrapper { display: flex; min-height: 100vh; }
.admin-sidebar-light {
  width: 220px; background: var(--cream); border-right: 0.5px solid var(--border);
  display: flex; flex-direction: column; flex-shrink: 0; position: sticky; top: 0; height: 100vh;
}
.admin-sidebar-logo {
  padding: 16px 20px; border-bottom: 0.5px solid var(--border);
  display: flex; align-items: center; gap: 8px;
}
.admin-sidebar-badge {
  padding: 8px 20px; border-bottom: 0.5px solid var(--border); margin-bottom: 8px;
}
.admin-badge-tag {
  font-size: 10px; background: var(--gold); color: #fff; padding: 2px 8px;
  border-radius: 3px; font-weight: 500; letter-spacing: 0.4px;
}
.admin-sidebar-nav { padding: 0 10px; flex: 1; }
.admin-sidebar-footer { padding: 10px; border-top: 0.5px solid var(--border); }
.admin-nav-item {
  display: flex; align-items: center; gap: 9px; padding: 8px 10px;
  border-radius: 6px; font-size: 13px; color: var(--ink-muted);
  text-decoration: none; margin-bottom: 2px; transition: all 0.12s;
}
.admin-nav-item:hover { background: var(--warm-white); color: var(--ink); }
.admin-nav-item.active { background: var(--warm-white); color: var(--gold); font-weight: 500; }
.admin-main-light { flex: 1; background: var(--warm-white); min-height: 100vh; }
.admin-content-wrap { padding: 32px 40px; max-width: 1100px; }

/* Admin */
.admin-section { margin-top: 32px; }
.admin-section h2 { font-size: 18px; margin-bottom: 12px; }
.stats-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; margin-bottom: 32px; }
.stat-card { background: #fff; border: 0.5px solid var(--border); border-radius: 10px; padding: 20px; text-align: center; }
.stat-value { font-family: 'Playfair Display', serif; font-size: 32px; font-weight: 600; color: var(--ink); }
.stat-label { font-size: 12px; color: var(--ink-faint); margin-top: 4px; }
.data-table { margin-top: 8px; }
.btn-approve { padding: 5px 14px; background: var(--green); color: #fff; border: none; border-radius: 4px; font-size: 12px; cursor: pointer; margin-right: 4px; }
.btn-reject { padding: 5px 14px; background: transparent; color: var(--red); border: 0.5px solid rgba(192,57,43,0.35); border-radius: 4px; font-size: 12px; cursor: pointer; }
.badge-category { background: #ECFDF5; color: #065F46; padding: 2px 8px; border-radius: 10px; font-size: 11px; }
.badge-pending { background: #FEF3C7; color: #92400E; padding: 2px 8px; border-radius: 10px; font-size: 11px; }
.countdown-urgent { color: var(--red) !important; font-weight: 600; }
.delete-overlay { position: fixed; inset: 0; background: rgba(0,0,0,0.4); display: flex; align-items: center; justify-content: center; z-index: 1000; }
.delete-dialog { background: #fff; border-radius: 12px; padding: 28px 32px; max-width: 400px; text-align: center; }
.delete-dialog h3 { font-size: 18px; margin-bottom: 10px; }
.delete-dialog p { font-size: 14px; color: var(--ink-muted); margin-bottom: 20px; }
.delete-dialog-actions { display: flex; gap: 10px; justify-content: center; }

/* Carousel */
/* Nav grid layout */
.st-nav {
  display: grid; grid-template-columns: auto 1fr auto;
  align-items: center; padding: 0 24px; height: 64px;
  background: var(--cream); border-bottom: 0.5px solid var(--border);
  position: sticky; top: 0; z-index: 100;
}
.nav-center {
  display: flex; align-items: center; justify-content: center;
  gap: 28px; flex-wrap: nowrap;
}
.nav-link {
  font-size: 14px; font-weight: 500; color: var(--ink-muted); text-decoration: none;
  padding: 4px 0; white-space: nowrap; transition: color 0.15s;
  border-bottom: 2px solid transparent;
}
.nav-link:hover { color: var(--ink); }
.nav-link.active { color: var(--gold); border-bottom-color: var(--gold); }
.mobile-only { display: none; }

/* Sidebar */
.sidebar-overlay {
  position: fixed; inset: 0; background: rgba(26,20,8,0.3);
  z-index: 200; opacity: 0; pointer-events: none; transition: opacity 0.25s;
}
.sidebar-overlay.open { opacity: 1; pointer-events: all; }
.sidebar-panel {
  position: fixed; top: 0; left: -320px; width: 300px; height: 100vh;
  background: var(--cream); border-right: 0.5px solid var(--border);
  z-index: 201; display: flex; flex-direction: column;
  transition: left 0.25s ease; overflow-y: auto;
}
.sidebar-panel.open { left: 0; }
.sidebar-header { display: flex; align-items: center; gap: 12px; padding: 20px 20px 16px; }
.sidebar-user-avatar {
  width: 44px; height: 44px; border-radius: 50%; background: var(--warm-white);
  border: 0.5px solid var(--border-strong); display: flex; align-items: center;
  justify-content: center; font-family: 'Playfair Display', serif;
  font-size: 18px; color: var(--gold); flex-shrink: 0;
}
.sidebar-user-name { font-size: 14px; font-weight: 500; color: var(--ink); }
.sidebar-user-email { font-size: 12px; color: var(--ink-faint); margin-top: 2px; }
.sidebar-close {
  margin-left: auto; background: transparent; border: none;
  cursor: pointer; color: var(--ink-faint); padding: 4px; flex-shrink: 0;
}
.sidebar-close:hover { color: var(--ink); }
.sidebar-divider { height: 0.5px; background: var(--border); margin: 8px 0; }
.sidebar-section-label {
  font-size: 10px; color: var(--ink-faint); text-transform: uppercase;
  letter-spacing: 0.5px; padding: 4px 20px 8px;
}
.sidebar-nav { flex: 1; padding: 8px 12px; }
.sidebar-nav-item {
  display: flex; align-items: center; gap: 12px; padding: 10px 12px;
  border-radius: 8px; font-size: 14px; color: var(--ink-muted);
  text-decoration: none; transition: all 0.12s; margin-bottom: 2px;
}
.sidebar-nav-item:hover { background: var(--warm-white); color: var(--ink); }
.sidebar-badge {
  margin-left: auto; background: var(--gold); color: #fff;
  font-size: 10px; font-weight: 500; padding: 1px 6px; border-radius: 10px;
}
.sidebar-footer { padding: 16px 12px; border-top: 0.5px solid var(--border); }
.sidebar-logout {
  display: flex; align-items: center; gap: 10px; width: 100%;
  padding: 10px 12px; border-radius: 8px; font-size: 14px;
  color: var(--ink-faint); background: transparent; border: none;
  cursor: pointer; font-family: 'DM Sans', sans-serif; transition: all 0.12s; text-align: left;
}
.sidebar-logout:hover { background: #FEE2E2; color: #991B1B; }
.sidebar-toggle-btn { background: transparent; border: none; cursor: pointer; padding: 0; display: flex; align-items: center; flex-shrink: 0; }
.sidebar-avatar {
  width: 34px; height: 34px; border-radius: 50%; background: var(--warm-white);
  border: 0.5px solid var(--border-strong); display: flex; align-items: center;
  justify-content: center; font-family: 'Playfair Display', serif;
  font-size: 14px; color: var(--gold); transition: border-color 0.12s;
}
.sidebar-avatar:hover { border-color: var(--gold); }


/* Splide carousel */
#auction-carousel.splide { padding: 0 52px; position: relative; }
#auction-carousel .splide__arrows { position: static; }
#auction-carousel .splide__arrow {
  position: absolute; top: 50%; transform: translateY(-50%);
  background: var(--warm-white); border: 1px solid var(--border-strong);
  width: 38px; height: 38px; border-radius: 50%; opacity: 1;
  cursor: pointer; transition: background 0.15s, border-color 0.15s; z-index: 10;
}
#auction-carousel .splide__arrow--prev { left: 0; }
#auction-carousel .splide__arrow--next { right: 0; }
#auction-carousel .splide__arrow svg { fill: var(--gold); width: 16px; height: 16px; }
#auction-carousel .splide__arrow:hover { background: var(--cream); border-color: var(--gold); }
.splide__slide { height: auto; display: flex; }
.splide__slide > * { flex: 1; min-width: 0; }

/* Featured section */
.featured-header {
  display: flex; justify-content: space-between; align-items: baseline;
  margin-bottom: 28px;
}
.featured-header .section-title { margin: 0; text-align: left; }
.featured-header .see-all-link {
  position: absolute; right: 0; font-size: 14px;
  color: var(--ink-muted); text-decoration: none;
}
.featured-header .see-all-link:hover { color: var(--gold); }

/* Category nav */
.nav-cats {
  display: flex; align-items: center; gap: 4px; margin-left: 6px;
  flex-wrap: nowrap; overflow-x: auto; scrollbar-width: none;
}
.nav-cats::-webkit-scrollbar { display: none; }
.nav-cat {
  font-size: 13px; font-weight: 400; color: var(--ink-muted); text-decoration: none;
  padding: 5px 14px; border: 0.5px solid var(--border-strong); border-radius: 20px;
  background: transparent; transition: all 0.15s; white-space: nowrap; cursor: pointer;
}
.nav-cat:hover, .nav-cat.active { background: var(--gold); color: #fff; border-color: var(--gold); }
.nav-separator { width: 1px; height: 14px; background: var(--border-strong); display: inline-block; margin: 0 4px; vertical-align: middle; }

/* Hamburger */
.nav-hamburger {
  display: none; background: transparent; border: none;
  cursor: pointer; color: var(--ink-muted); padding: 4px;
}
.nav-mobile-menu {
  display: none; position: absolute; top: 64px; left: 0; right: 0;
  background: var(--cream); border-bottom: 0.5px solid var(--border);
  padding: 12px 16px; flex-direction: column; gap: 4px; z-index: 200;
}
.nav-mobile-menu a {
  font-size: 15px; color: var(--ink-muted); text-decoration: none;
  padding: 10px 0; border-bottom: 0.5px solid var(--border);
}
.nav-mobile-menu a:last-child { border-bottom: none; }
.nav-mobile-menu.open { display: flex; }

/* Responsive */
@media (max-width: 1200px) {
  .st-nav { padding: 0 16px; }
  .nav-cat { font-size: 11px; padding: 3px 7px; }
  .btn-ghost-sm { font-size: 11px; padding: 5px 8px; }
}

@media (max-width: 1024px) {
  .nav-cats { display: none; }
  .nav-hamburger { display: block; }
}

@media (max-width: 768px) {
  .st-nav { padding: 0 12px; grid-template-columns: auto 1fr; height: 56px; }
  .nav-center { display: none; }
  .mobile-only { display: flex; }
  .st-nav-actions { justify-content: flex-end; gap: 6px; }
  .st-nav-actions .btn-ghost-sm { font-size: 11px; padding: 4px 8px; }
  .st-nav-actions .btn-primary-sm { font-size: 11px; padding: 4px 10px; }
  .nav-mobile-menu { top: 56px; }
  .hero { padding: 40px 16px 32px; }
  .hero-title { font-size: 34px; }
  .home-section { padding: 32px 16px; }
  .section { padding: 24px 16px; }
  .auction-grid { grid-template-columns: 1fr 1fr; gap: 10px; }
}

@media (max-width: 480px) {
  .auction-detail-grid { grid-template-columns: 1fr; }
  .steps-grid { grid-template-columns: repeat(2, 1fr); gap: 12px; }
  .how-inner { padding: 0 16px; }
  .stats-grid { grid-template-columns: repeat(2, 1fr); }
  .form-row { grid-template-columns: 1fr; }
  .how-section { padding: 36px 16px; }
  .auth-page { padding: 24px; }
  .page-wrap { padding: 20px 16px; }
  table { font-size: 12px; }
  th, td { padding: 8px 10px; }
}

@media (max-width: 360px) {
  .st-nav { padding: 0 8px; }
  .st-logo-text { font-size: 16px; }
  .st-nav-actions .btn-ghost-sm, .st-nav-actions .btn-primary-sm { font-size: 10px; padding: 4px 6px; }
}

@media (max-width: 480px) {
  .auction-grid { grid-template-columns: 1fr; }
  .hero-title { font-size: 28px; }
  .hero-actions { flex-direction: column; align-items: stretch; }
  .btn-hero-gold, .btn-hero-outline { text-align: center; }
  .steps-grid { grid-template-columns: 1fr; }
}

/* Gallery */
.auction-gallery { display: flex; flex-direction: column; gap: 12px; }
.gallery-main { width: 100%; aspect-ratio: 4/3; border-radius: 8px; overflow: hidden; background: var(--warm-white); border: 1px solid var(--border); }
.gallery-thumbs { display: flex; gap: 8px; overflow-x: auto; padding-bottom: 4px; }
.gallery-thumb {
  flex-shrink: 0; width: 72px; height: 72px; border-radius: 6px; overflow: hidden;
  border: 2px solid var(--border); padding: 0; background: var(--warm-white);
  cursor: pointer; transition: border-color 0.15s;
}
.gallery-thumb.active { border-color: var(--gold); }
.gallery-thumb:hover { border-color: var(--border-strong); }
.gallery-thumb img { width: 100%; height: 100%; object-fit: cover; }
.no-image-placeholder { width: 100%; height: 100%; display: flex; align-items: center; justify-content: center; background: var(--warm-white); }

/* Upload preview */
.upload-preview-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(110px, 1fr)); gap: 10px; margin-top: 12px; }
.upload-preview-item { position: relative; aspect-ratio: 1; border-radius: 8px; overflow: hidden; border: 2px solid var(--border); background: var(--warm-white); }
.upload-preview-item.is-primary { border-color: var(--gold); }
.upload-preview-item img { width: 100%; height: 100%; object-fit: cover; }
.upload-preview-actions { position: absolute; top: 4px; right: 4px; display: flex; gap: 4px; }
.btn-icon { width: 28px; height: 28px; border-radius: 50%; border: none; background: rgba(255,255,255,0.9); cursor: pointer; display: flex; align-items: center; justify-content: center; color: var(--ink-muted); transition: background 0.15s; }
.btn-icon:hover { background: #fff; }
.btn-icon.danger:hover { color: #c0392b; }
.primary-badge { position: absolute; bottom: 4px; left: 4px; font-size: 11px; padding: 2px 8px; border-radius: 4px; background: var(--gold); color: #fff; font-weight: 500; }
.form-hint { font-size: 13px; color: var(--ink-faint); margin: 4px 0 8px; }

/* Buy Now */
.buy-now-card { background: #fff; border: 1.5px solid var(--gold-muted); border-radius: 10px; padding: 18px 20px; }
.buy-now-label { font-size: 11px; color: var(--ink-faint); text-transform: uppercase; letter-spacing: 0.4px; margin-bottom: 4px; }
.buy-now-price { font-family: 'Playfair Display', serif; font-size: 28px; font-weight: 600; color: var(--ink); margin-bottom: 6px; }
.buy-now-sub { font-size: 12px; color: var(--ink-faint); margin-bottom: 14px; line-height: 1.5; }
.btn-buy-now {
  width: 100%; padding: 11px; background: var(--ink); color: #fff; border: none;
  border-radius: 7px; font-size: 14px; font-weight: 500; cursor: pointer;
  font-family: 'DM Sans', sans-serif; transition: background 0.15s;
}
.btn-buy-now:hover { background: var(--ink-muted); }
.btn-buy-now:disabled { opacity: 0.6; cursor: not-allowed; }

.ban-notice {
  background: #FEE2E2;
  border: 0.5px solid #FCA5A5;
  border-radius: 8px;
  padding: 14px 16px;
  font-size: 13px;
  color: #991B1B;
  display: flex;
  align-items: center;
  gap: 10px;
}

/* Cookie toggle */
.cookie-toggle { width: 36px; height: 20px; border-radius: 10px; border: none; background: #d5cec0; position: relative; cursor: pointer; transition: background 0.2s; }
.cookie-toggle::after { content: ''; position: absolute; top: 2px; left: 2px; width: 16px; height: 16px; border-radius: 50%; background: #fff; transition: transform 0.2s; }
.cookie-toggle.on { background: var(--gold); }
.cookie-toggle.on::after { transform: translateX(16px); }

/* Footer */
.st-footer { border-top: 0.5px solid var(--border); margin-top: 64px; padding: 32px 48px; background: var(--cream); }
.st-footer-inner { max-width: 1200px; margin: 0 auto; display: flex; align-items: center; justify-content: space-between; }
.st-footer-links { display: flex; align-items: center; gap: 24px; }
.st-footer-links a { font-size: 13px; color: var(--ink-muted); text-decoration: none; transition: color 0.15s; }
.st-footer-links a:hover { color: var(--ink); }
.st-footer-fb { display: inline-flex; align-items: center; gap: 6px; }
.st-footer-copy { font-size: 12px; color: var(--ink-faint); }

@media (max-width: 600px) {
  .st-footer { padding: 24px 16px; margin-top: 40px; }
  .st-footer-inner { flex-direction: column; gap: 16px; text-align: center; }
  .st-footer-links { flex-direction: column; gap: 12px; }
}

/* Blazor error UI */
#blazor-error-ui { background: lightyellow; bottom: 0; box-shadow: 0 -1px 2px rgba(0,0,0,0.2); display: none; left: 0; padding: 0.6rem 1.25rem 0.7rem; position: fixed; width: 100%; z-index: 1000; }
#blazor-error-ui .dismiss { cursor: pointer; position: absolute; right: 0.75rem; top: 0.5rem; }

/* =========================================================
   Uppboð / Óskað eftir filter pills
   ========================================================= */
.filter-pills {
    display: flex; flex-wrap: wrap; gap: 8px;
    margin-bottom: 16px;
}
.pill-filter {
    padding: 6px 14px; font-size: 12px; font-weight: 500;
    color: #8a7a4a; background: transparent;
    border: 1px solid #c9a84c; border-radius: 14px;
    cursor: pointer; transition: all 0.15s;
    font-family: 'DM Sans', sans-serif; white-space: nowrap;
}
.pill-filter:hover { background: rgba(201,168,76,0.08); }
.pill-filter.active { background: #c9a84c; color: #fff; border-color: #c9a84c; }

.pill-sort {
    padding: 5px 12px; font-size: 11px; font-weight: 500;
    color: var(--ink-muted); background: transparent;
    border: 1px solid #d3d1c7; border-radius: 14px;
    cursor: pointer; transition: all 0.15s;
    font-family: 'DM Sans', sans-serif; white-space: nowrap;
}
.pill-sort:hover { background: rgba(201,168,76,0.05); }
.pill-sort.active {
    color: #8a7a4a; border-color: #c9a84c;
    background: rgba(201,168,76,0.08);
}

/* 4-column auction grid (wraps naturally as items grow) */
.auction-grid-4col {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 18px;
}
@media (max-width: 960px) {
    .auction-grid-4col { grid-template-columns: repeat(3, 1fr); gap: 14px; }
}
@media (max-width: 720px) {
    .auction-grid-4col { grid-template-columns: repeat(2, 1fr); gap: 10px; }
}
@media (max-width: 420px) {
    .auction-grid-4col { grid-template-columns: 1fr; }
}

/* Uppbod listing grid — fixed card width so <4 items don't stretch. */
.uppbod-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 240px));
    gap: 16px;
    justify-content: center;
}
@media (max-width: 960px) {
    .uppbod-grid { grid-template-columns: repeat(3, minmax(0, 240px)); gap: 14px; }
}
@media (max-width: 720px) {
    .uppbod-grid { grid-template-columns: repeat(2, minmax(0, 240px)); gap: 10px; }
}
@media (max-width: 500px) {
    .uppbod-grid { grid-template-columns: minmax(0, 280px); }
}

/* =========================================================
   MOBILE RESPONSIVE FIXES — applied to all pages
   ========================================================= */

/* Prevent any horizontal page scrolling */
html, body { overflow-x: hidden; max-width: 100%; }

/* Media never overflows */
img, video, iframe { max-width: 100%; height: auto; }

/* Tables wider than the viewport: scroll locally instead of pushing the page */
@media (max-width: 768px) {
    .data-table, table {
        display: block;
        width: 100%;
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
        white-space: nowrap;
    }
    .data-table thead, .data-table tbody, .data-table tr,
    table thead, table tbody, table tr { display: table; width: 100%; table-layout: auto; }
}

/* Generic mobile layout adjustments */
@media (max-width: 768px) {
    .page-wrap { padding: 18px 14px; }
    .home-section { padding: 28px 14px 24px; }
    .section, .how-section { padding: 24px 14px; }
    .card, .form-container { padding: 16px 14px; }
    .auction-detail-grid { grid-template-columns: 1fr; gap: 18px; }
    .auction-detail-meta { flex-direction: column; gap: 8px; }
    .form-row { grid-template-columns: 1fr; }
    .stats-grid { grid-template-columns: repeat(2, 1fr); gap: 10px; }
    .steps-grid { grid-template-columns: 1fr 1fr; gap: 12px; }
    .auction-grid { grid-template-columns: 1fr 1fr; gap: 10px; }

    /* Center action button rows */
    .form-actions,
    .hero-actions,
    .pagination,
    .delete-dialog-actions,
    .tab-content-header { justify-content: center; flex-wrap: wrap; gap: 10px; }
    .form-actions { display: flex; }
    .tab-content-header { text-align: center; }

    /* Buttons stretched on small screens for easier tapping */
    .btn-primary, .btn-outline, .btn-danger { display: inline-block; }

    /* Forms: full-width inputs already, but ensure no min-width pushes overflow */
    .form-input, .form-select, .form-textarea { min-width: 0; width: 100%; }

    /* Tab bar scrolls horizontally if it overflows instead of breaking layout */
    .tab-bar { overflow-x: auto; -webkit-overflow-scrolling: touch; white-space: nowrap; flex-wrap: nowrap; }
    .tab-btn { flex-shrink: 0; }

    /* Bid form layout */
    .bid-form-input-row { flex-wrap: wrap; }

    /* Chat bubbles wider on small screens */
    .chat-bubble { max-width: 90%; }

    /* Section headers: stack title and link */
    .featured-header, .section-header { flex-direction: column; align-items: flex-start; gap: 8px; }
}

/* Admin sidebar: collapse to top horizontal bar on mobile */
@media (max-width: 900px) {
    .admin-wrapper { flex-direction: column; }
    .admin-sidebar-light {
        width: 100%; height: auto; position: static;
        border-right: none; border-bottom: 0.5px solid var(--border);
    }
    .admin-sidebar-nav {
        display: flex; flex-wrap: wrap; gap: 4px;
        padding: 8px 12px; overflow-x: auto;
    }
    .admin-nav-item { padding: 6px 12px; font-size: 12px; white-space: nowrap; }
    .admin-sidebar-logo { padding: 12px 16px; }
    .admin-sidebar-badge { display: none; }
    .admin-sidebar-footer { padding: 8px 12px; border-top: 0.5px solid var(--border); }
    .admin-content-wrap { padding: 20px 14px; max-width: 100%; }
    .admin-main-light { min-height: auto; }
}

/* Extra-small phones */
@media (max-width: 480px) {
    .auction-grid { grid-template-columns: 1fr; }
    .stats-grid { grid-template-columns: 1fr 1fr; }
    .steps-grid { grid-template-columns: 1fr; }
    .hero-actions { flex-direction: column; align-items: stretch; }
    .btn-hero-gold, .btn-hero-outline { text-align: center; width: 100%; }
    .auth-page { padding: 20px 14px; min-height: auto; }
    .auth-card { padding: 24px 18px; }
    .page-title { font-size: 22px; }
    .hero-title { font-size: 28px; }
    .hero-sub { font-size: 14px; }

    /* Buttons in tab-content-header (e.g. "Stofna uppboð") full width */
    .tab-content-header .btn-primary { width: 100%; }
}

/* Container failsafe — any block that's setting an inline max-width
   wider than the viewport gets capped */
.page-wrap, .auth-card, .form-container, .card,
.admin-content-wrap, .home-section, .auction-detail {
    max-width: 100%;
}

/* =========================================================
   Uppboð search + status tabs + ended card
   ========================================================= */
.uppbod-search-wrap {
    display: flex;
    justify-content: center;
    margin-bottom: 16px;
}
.uppbod-search {
    width: 100%;
    max-width: 420px;
    padding: 9px 14px;
    font-size: 14px;
    font-family: 'DM Sans', sans-serif;
    color: var(--ink);
    background: #fff;
    border: 0.5px solid var(--border-strong);
    border-radius: 8px;
    outline: none;
    transition: border-color 0.15s;
}
.uppbod-search:focus { border-color: var(--gold); }
.uppbod-search::placeholder { color: var(--ink-faint); }

.pill-tab {
    padding: 6px 18px;
    font-size: 12px;
    font-weight: 500;
    color: var(--ink-muted);
    background: transparent;
    border: 1px solid #d3d1c7;
    border-radius: 14px;
    cursor: pointer;
    transition: all 0.15s;
    font-family: 'DM Sans', sans-serif;
    white-space: nowrap;
}
.pill-tab:hover { background: rgba(201,168,76,0.05); }
.pill-tab.active {
    background: #c9a84c;
    color: #fff;
    border-color: #c9a84c;
}

.auction-card-ended { background: #f6f5f1; }
.auction-card-ended .card-img { opacity: 0.78; }
.auction-card-ended .card-title { color: var(--ink-muted); }
.card-ended-badge {
    position: absolute;
    top: 10px;
    left: 10px;
    background: #fff;
    border: 0.5px solid var(--border-strong);
    border-radius: 4px;
    font-size: 11px;
    font-weight: 500;
    color: var(--ink-muted);
    padding: 3px 8px;
}
.card-ended-date {
    font-size: 11px;
    color: var(--ink-faint);
    margin-top: 3px;
}

/* =========================================================
   Til sölu (For Sale) cards
   ========================================================= */
.forsale-price { color: #c9a84c; }
.forsale-card-sold { background: #f6f5f1; }
.forsale-card-sold .card-img { opacity: 0.78; }
.forsale-card-sold .card-title { color: var(--ink-muted); }
.card-sold-badge {
    position: absolute;
    top: 10px;
    left: 10px;
    background: #fff;
    border: 0.5px solid var(--border-strong);
    border-radius: 4px;
    font-size: 11px;
    font-weight: 500;
    color: var(--ink-muted);
    padding: 3px 8px;
}

