:root {
  --navy-950: #081828;
  --navy-900: #0c2236;
  --navy-800: #122e48;
  --navy-700: #1a3a5c;
  --copper: #e06020;
  --copper-hover: #c95217;
  --copper-soft: #fdeee3;
  --gold: #e8922e;
  --blue: #216ba5;

  --bg: #f7f8fa;
  --surface: #ffffff;
  --ink: #1a2330;
  --ink-soft: #3c4655;
  --muted: #6b7482;
  --border: #e6e9ee;
  --border-strong: #d5dae2;

  --green: #0f7a4d;
  --green-soft: #e6f4ed;
  --red: #d5230d;
  --red-soft: #fdecea;

  --radius: 14px;
  --radius-sm: 10px;
  --shadow-sm: 0 1px 2px rgba(12,34,54,.05);
  --shadow: 0 1px 3px rgba(12,34,54,.07), 0 2px 10px rgba(12,34,54,.04);
  --shadow-lg: 0 14px 40px rgba(12,34,54,.12);
  --font-display: "Fraunces", Georgia, "Times New Roman", serif;
  --font-body: "Plus Jakarta Sans", -apple-system, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
}

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

html { scroll-behavior: smooth; }

body {
  font-family: var(--font-body);
  background: var(--bg);
  color: var(--ink);
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

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

/* ===== Splash in-app (gambar di tengah saat app dibuka) ===== */
.app-splash {
  position: fixed; inset: 0; z-index: 9999;
  background: #f7f9f6;
  display: flex; align-items: center; justify-content: center;
  transition: opacity .45s ease;
}
.app-splash img { max-width: 80vw; max-height: 60vh; width: auto; height: auto; }
.app-splash.hidden { opacity: 0; pointer-events: none; }

/* Navigasi lanjutan (bukan cold start): sembunyikan splash seketika tanpa flash. */
html.no-splash .app-splash { display: none !important; }

/* Splash hanya untuk mobile (PWA) — di desktop disembunyikan biar nggak flash saat refresh. */
@media (min-width: 761px) {
  .app-splash { display: none !important; }
}

.container { width: 100%; max-width: 1160px; margin: 0 auto; padding: 0 24px; }

/* ===== Navbar ===== */
.navbar {
  background: var(--surface);
  border-bottom: 1px solid var(--border);
  position: sticky; top: 0; z-index: 50;
}
.nav-inner { display: flex; align-items: center; justify-content: space-between; height: 70px; gap: 16px; }
.brand { display: flex; flex-direction: column; align-items: flex-start; justify-content: center; gap: 2px; line-height: 1; color: var(--ink); }
.brand img { height: 48px; width: auto; object-fit: contain; display: block; }
.brand .brand-name { display: block; }
.brand .brand-name small { font-weight: 600; font-size: .52rem; color: var(--copper); letter-spacing: .03em; text-transform: uppercase; }
.nav-links { display: flex; gap: 4px; align-items: center; }
.nav-links a {
  color: var(--ink-soft); font-size: .92rem; font-weight: 600; padding: 8px 13px; border-radius: 9px;
  transition: background .15s, color .15s;
}
.nav-links a:hover { color: var(--navy-800); background: var(--bg); }
.nav-links a.active { color: var(--navy-800); background: var(--copper-soft); }
.nav-auth { display: inline-flex; align-items: center; gap: 8px; }
/* ===== Anti-FOUC navbar auth (state via html.authed / html.owner) ===== */
#nav-auth .nav-logout,
#nav-auth .nav-owner-link,
#nav-account { display: none; }
html.authed #nav-auth .nav-guest { display: none; }
html.authed #nav-auth .nav-logout { display: inline-flex; }
html.authed #nav-account { display: inline-flex; }
html.owner #nav-auth .nav-owner-link { display: inline-flex; }

/* Bell + burger (kanan navbar, di luar panel) */
.nav-actions { display: flex; align-items: center; gap: 8px; }
.icon-btn {
  position: relative; display: inline-flex; align-items: center; justify-content: center;
  width: 42px; height: 42px; border-radius: 10px; border: 1.5px solid var(--border);
  background: var(--surface); color: var(--ink-soft); cursor: pointer; transition: color .15s, border-color .15s;
}
.icon-btn:hover { color: var(--navy-800); border-color: var(--border-strong); }
.icon-btn .badge-num { position: absolute; top: -6px; right: -6px; margin: 0; }

/* Hamburger toggle (mobile only) */
.nav-toggle {
  display: none;
  background: var(--surface); border: 1.5px solid var(--border);
  color: var(--ink); font-size: 1.3rem; line-height: 1;
  width: 42px; height: 42px; border-radius: 10px; cursor: pointer;
  align-items: center; justify-content: center;
}

main { flex: 1; }

/* ===== Hero ===== */
.hero {
  background: linear-gradient(155deg, var(--navy-950) 0%, var(--navy-800) 60%, var(--navy-700) 130%);
  color: #fff; padding: 60px 0 90px; position: relative; overflow: hidden;
}
.hero::before {
  content: ""; position: absolute; right: -100px; top: -80px; width: 420px; height: 420px;
  background: radial-gradient(circle, rgba(224,96,32,.4), transparent 62%); border-radius: 50%;
}
.hero::after {
  content: ""; position: absolute; left: -60px; bottom: -120px; width: 320px; height: 320px;
  background: radial-gradient(circle, rgba(33,107,165,.35), transparent 60%); border-radius: 50%;
}
.hero-inner { position: relative; z-index: 1; max-width: 720px; }
.hero .eyebrow {
  display: inline-block; font-size: .74rem; font-weight: 700; letter-spacing: .14em; text-transform: uppercase;
  color: #f8c7a0; background: rgba(255,255,255,.08); border: 1px solid rgba(255,255,255,.16);
  padding: 5px 12px; border-radius: 20px; margin-bottom: 16px;
}
.hero h1 {
  font-family: var(--font-display); font-weight: 600; font-size: clamp(2rem, 4.5vw, 3.1rem);
  line-height: 1.1; letter-spacing: -.01em; margin-bottom: 14px;
}
.hero h1 em { font-style: italic; color: #f8c7a0; }
.hero p { color: rgba(255,255,255,.84); font-size: 1.06rem; max-width: 560px; }

/* ===== Search bar (floating) ===== */
.search-wrap { margin-top: -46px; position: relative; z-index: 5; margin-bottom: 40px; }
.search-box {
  display: flex; gap: 10px; align-items: stretch; flex-wrap: wrap;
  background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius);
  padding: 14px; box-shadow: var(--shadow-lg);
}
.search-box .field { flex: 1; min-width: 180px; display: flex; flex-direction: column; gap: 3px; }
.search-box .field label { font-size: .7rem; font-weight: 700; color: var(--muted); text-transform: uppercase; letter-spacing: .05em; padding-left: 2px; }
.search-box input, .search-box select {
  width: 100%; border: none; outline: none; background: transparent; font-size: .98rem;
  color: var(--ink); font-family: var(--font-body); padding: 7px 2px;
}
.search-box select { cursor: pointer; }
.search-box .btn { align-self: center; }

/* ===== Banner strip ===== */
.banner-strip { display: flex; gap: 14px; overflow-x: auto; margin-bottom: 10px; padding-bottom: 6px; }
.banner {
  background: linear-gradient(135deg, var(--copper), var(--gold));
  color: #fff; border-radius: var(--radius); padding: 18px 22px;
  display: flex; align-items: center; gap: 14px; min-width: 260px; box-shadow: var(--shadow);
  font-weight: 700; transition: transform .15s, box-shadow .15s;
}
.banner:hover { color: #fff; transform: translateY(-2px); box-shadow: var(--shadow-lg); }
.banner img { height: 46px; border-radius: 9px; }

/* ===== Section header ===== */
.section-head { display: flex; align-items: baseline; justify-content: space-between; margin: 34px 0 18px; }
.section-head h2 { font-family: var(--font-display); font-weight: 600; font-size: 1.65rem; letter-spacing: -.01em; color: var(--navy-900); }
.section-head .more { font-size: .9rem; font-weight: 600; }

/* ===== Auction tabs (halaman lelang) ===== */
.auction-tabs-row { display: flex; align-items: flex-end; justify-content: space-between; gap: 12px; flex-wrap: wrap; border-bottom: 1px solid var(--border); margin: 30px 0 18px; }
.auction-tabs { display: flex; gap: 4px; overflow-x: auto; scrollbar-width: none; }
.auction-tabs::-webkit-scrollbar { display: none; }
.auction-tabs-row .sort-btns { margin-bottom: 8px; flex-shrink: 0; }
.tab-btn {
  display: inline-flex; align-items: center; gap: 7px; background: none; border: none; border-bottom: 3px solid transparent;
  padding: 11px 16px 13px; font-size: .95rem; font-weight: 600; color: var(--muted); cursor: pointer;
  white-space: nowrap; transition: color .15s, border-color .15s; font-family: inherit;
}
.tab-btn:hover { color: var(--navy-900); }
.tab-btn.active { color: var(--navy-900); border-bottom-color: var(--copper); }
.tab-count {
  display: inline-flex; align-items: center; justify-content: center; min-width: 22px; height: 22px; padding: 0 6px;
  background: var(--border); border-radius: 20px; font-size: .74rem; font-weight: 700; color: var(--muted);
}
.tab-btn.active .tab-count { background: var(--copper-soft); color: var(--copper); }
.tab-panel { animation: tabFade .2s ease; }
@keyframes tabFade { from { opacity: 0; transform: translateY(4px); } to { opacity: 1; transform: none; } }
.status-tag.sold { background: var(--green); }
.status-tag.fee-buyer { background: var(--red); }
.status-tag.unsold { background: var(--muted); }
.status-tag.cancelled { background: var(--red); }

/* ===== Toolbar sort + filter kategori ===== */
.auction-toolbar { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; margin: 0 0 16px; }
.sort-btns { display: inline-flex; gap: 2px; background: var(--surface); border: 1px solid var(--border); border-radius: 12px; padding: 4px; box-shadow: var(--shadow-sm); }
.sort-btn {
  border: none; background: none; padding: 7px 13px; border-radius: 9px; font-size: .83rem; font-weight: 600;
  color: var(--muted); cursor: pointer; white-space: nowrap; transition: all .15s; font-family: inherit;
}
.sort-btn:hover { color: var(--navy-900); }
.sort-btn.active { background: var(--navy-800); color: #fff; }
.home-chips { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; }

/* ===== Category chips ===== */
.chips { display: flex; gap: 10px; flex-wrap: wrap; margin-bottom: 24px; }
.chip {
  display: inline-flex; align-items: center; gap: 8px; background: var(--surface); border: 1px solid var(--border);
  border-radius: 40px; padding: 9px 17px; font-size: .9rem; font-weight: 600; color: var(--ink-soft);
  cursor: pointer; transition: all .15s; box-shadow: var(--shadow-sm);
}
.chip:hover { border-color: var(--copper); color: var(--copper); }
.chip.active { background: var(--navy-800); border-color: var(--navy-800); color: #fff; }
.chip .emoji { font-size: 1.05rem; }

/* ===== Search results (produk + user) ===== */
.search-results { display: flex; flex-direction: column; gap: 28px; }
.search-group { display: flex; flex-direction: column; gap: 12px; }
.search-group-title { font-family: var(--font-display); font-weight: 600; font-size: 1.35rem; color: var(--navy-900); margin: 0; }
.user-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 14px; }
.user-card {
  display: flex; align-items: center; gap: 12px; background: var(--surface); border: 1px solid var(--border);
  border-radius: var(--radius); padding: 14px 16px; color: var(--ink); box-shadow: var(--shadow-sm);
  transition: border-color .15s, box-shadow .15s;
}
.user-card:hover { border-color: var(--copper); box-shadow: var(--shadow); color: var(--ink); }
.user-avatar { width: 48px; height: 48px; border-radius: 50%; object-fit: cover; flex-shrink: 0; }
.user-avatar-fallback { display: flex; align-items: center; justify-content: center; background: var(--copper-soft); color: var(--copper); font-weight: 800; font-size: 1.1rem; }
.user-card-info { display: flex; flex-direction: column; min-width: 0; }
.user-card-name { font-weight: 700; }
.user-card-username { color: var(--muted); font-size: .85rem; }
.user-card-loc { color: var(--muted); font-size: .8rem; }

/* ===== Listing grid ===== */
.listing-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(175px, 1fr)); gap: 14px; }
.card {
  background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius);
  overflow: hidden; color: var(--ink); display: flex; flex-direction: column;
  transition: box-shadow .18s, transform .18s, border-color .18s; box-shadow: var(--shadow-sm);
}
.card:hover { box-shadow: var(--shadow-lg); transform: translateY(-3px); border-color: var(--border-strong); color: var(--ink); }
.card-media {
  aspect-ratio: 1 / 1; background: linear-gradient(135deg, var(--navy-800), var(--blue));
  display: flex; align-items: center; justify-content: center; position: relative;
}
.card-media.coin { background: linear-gradient(135deg, #2f5f6b, #1a3a5c); }
.card-media .media-emoji { font-size: 2.1rem; filter: drop-shadow(0 3px 6px rgba(0,0,0,.3)); }
.card-media .tag {
  position: absolute; top: 12px; left: 12px; background: rgba(255,255,255,.95); color: var(--navy-800);
  font-size: .68rem; font-weight: 800; letter-spacing: .05em; text-transform: uppercase;
  padding: 4px 10px; border-radius: 20px;
}
.card-body { padding: 12px; display: flex; flex-direction: column; gap: 6px; flex: 1; }
.card-body h3 { font-size: .9rem; font-weight: 700; color: var(--ink); line-height: 1.3; }
.card-body .cond { font-size: .74rem; color: var(--muted); }
.card-price { font-size: 1.05rem; font-weight: 800; color: var(--navy-800); }
.card-price small { font-size: .8rem; color: var(--muted); font-weight: 600; }
.card-price.price-flash { animation: priceFlash .6s ease; }
@keyframes priceFlash {
  0% { color: var(--copper); transform: scale(1.08); }
  100% { color: var(--navy-800); transform: scale(1); }
}
.card-foot { display: flex; justify-content: space-between; align-items: center; margin-top: auto; padding-top: 6px; border-top: 1px solid var(--border); font-size: .76rem; color: var(--muted); }
.card-foot .bids { font-weight: 700; color: var(--copper); }
.card-foot .card-countdown { font-weight: 700; color: var(--navy-800); }
.card-seller { display: flex; align-items: center; gap: 8px; font-size: .76rem; color: var(--muted); }
.card-seller .seller-photo {
  width: 26px; height: 26px; border-radius: 50%; object-fit: cover; flex-shrink: 0;
  border: 1px solid var(--border);
}
.card-seller .seller-info { display: flex; flex-direction: column; min-width: 0; flex: 1; }
.card-seller .seller-name { font-weight: 700; color: var(--ink); line-height: 1.2; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.card-seller .seller-loc { font-size: .7rem; color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.card-seller .avatar {
  width: 26px; height: 26px; border-radius: 50%; background: var(--copper-soft); color: var(--copper);
  display: inline-flex; align-items: center; justify-content: center; font-weight: 800; font-size: .74rem; flex-shrink: 0;
}
.card-seller .share-btn {
  margin-left: auto; width: 28px; height: 28px; border-radius: 8px; border: 1px solid var(--border);
  background: var(--surface); color: var(--muted); cursor: pointer; display: inline-flex; align-items: center; justify-content: center;
  flex-shrink: 0; transition: color .15s, border-color .15s;
}
.card-seller .share-btn:hover { color: var(--copper); border-color: var(--copper); }

/* ===== Sell page card ===== */
.sell-card .card-media { position: relative; }
.sell-pill { position: absolute; top: 12px; right: 12px; }
.sell-card-actions { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 10px; padding-top: 10px; border-top: 1px solid var(--border); }
.sell-card-actions .btn-sm { padding: 6px 10px; font-size: .8rem; }

/* ===== Tombol 3-titik (kebab) + dropdown menu ===== */
.kebab-btn {
  display: inline-flex; align-items: center; justify-content: center;
  width: 30px; height: 30px; border-radius: 8px;
  border: 1px solid var(--border); background: var(--surface);
  color: var(--ink-soft); cursor: pointer;
  transition: color .15s, border-color .15s, background .15s, transform .1s;
}
.kebab-btn:hover { color: var(--copper); border-color: var(--copper); background: var(--copper-soft); }
.kebab-btn:active { transform: scale(.92); }
.card-menu {
  position: fixed; z-index: 9999; min-width: 200px;
  background: var(--surface); border: 1px solid var(--border); border-radius: 12px;
  box-shadow: var(--shadow-lg); padding: 6px;
}
.card-menu-item {
  display: flex; align-items: center; gap: 10px; width: 100%;
  padding: 9px 12px; border: none; background: none; cursor: pointer;
  font-size: .86rem; font-weight: 600; color: var(--ink); text-align: left;
  border-radius: 8px;
}
.card-menu-item:hover { background: var(--bg); color: var(--copper); }
a.card-media { text-decoration: none; color: inherit; }

/* ===== Header kartu transaksi: role + status + kebab ===== */
.tx-head {
  display: flex; align-items: center; gap: 6px;
  flex-wrap: wrap;
}
.tx-role {
  font-size: .68rem; font-weight: 800; letter-spacing: .05em; text-transform: uppercase;
  color: var(--muted);
}
.tx-head .status-pill { flex-shrink: 0; }
.tx-head .kebab-btn { margin-left: auto; flex-shrink: 0; }
.kebab-overlay {
  position: absolute; top: 10px; right: 10px;
  background: rgba(255,255,255,.92);
  box-shadow: 0 2px 6px rgba(0,0,0,.18);
}
.tx-status-overlay {
  position: absolute; top: 12px; left: 12px;
  box-shadow: 0 2px 6px rgba(0,0,0,.18);
}
.filter-check { display: inline-flex; align-items: center; gap: 6px; font-size: .88rem; font-weight: 600; color: var(--ink-soft); cursor: pointer; margin: 0; }
.filter-check input { margin: 0; width: auto; }

/* ===== Dashboard ===== */
.dash-container { padding-top: 28px; padding-bottom: 48px; }
.dash-head h1 { font-family: var(--font-display); font-weight: 600; font-size: 1.8rem; color: var(--navy-900); margin-bottom: 4px; }
.dash-wallet { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 14px; margin: 20px 0 22px; }
.dash-wallet-card {
  background: var(--surface); border: 1px solid var(--border); border-radius: 16px; padding: 18px 20px;
  box-shadow: var(--shadow-sm); display: flex; flex-direction: column; gap: 4px;
}
.dash-wallet-card.held { border-left: 4px solid var(--copper); }
.dash-wallet-label { font-size: .78rem; font-weight: 700; text-transform: uppercase; letter-spacing: .04em; color: var(--muted); }
.dash-wallet-amount { font-family: var(--font-display); font-size: 1.7rem; font-weight: 600; color: var(--navy-800); }
.dash-wallet-hint { font-size: .78rem; color: var(--muted); }

.dash-tabs { display: flex; gap: 4px; border-bottom: 1px solid var(--border); margin-bottom: 18px; overflow-x: auto; }
.dash-tab {
  background: none; border: none; padding: 11px 18px; font-size: .92rem; font-weight: 700;
  color: var(--muted); cursor: pointer; border-bottom: 2px solid transparent; font-family: var(--font-body); white-space: nowrap;
  transition: color .15s, border-color .15s;
}
.dash-tab:hover { color: var(--ink); }
.dash-tab.active { color: var(--copper); border-bottom-color: var(--copper); }
.dash-panel { display: none; }
.dash-panel.active { display: block; animation: ownerFade .2s ease; }

.empty-state {
  grid-column: 1 / -1;
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  gap: 8px; text-align: center; padding: 60px 24px;
  border: 1.5px dashed var(--border-strong); border-radius: 16px;
  background: var(--surface);
}
.empty-state .empty-title { font-weight: 800; color: var(--navy-800); font-size: 1.05rem; }
.empty-state .empty-desc { color: var(--muted); font-size: .9rem; max-width: 360px; line-height: 1.6; }
.empty-state .empty-desc a { font-weight: 700; }

.tx-card {
  background: var(--surface); border: 1px solid var(--border); border-radius: 16px; padding: 16px 18px;
  margin-bottom: 12px; box-shadow: var(--shadow-sm);
}
.tx-card-buyer { border-left: 4px solid var(--blue); }
.tx-card-seller { border-left: 4px solid var(--copper); }
.tx-card-head { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-bottom: 6px; }
.tx-role { font-size: .76rem; font-weight: 800; text-transform: uppercase; letter-spacing: .05em; color: var(--muted); }
.tx-role.buyer { color: var(--blue); }
.tx-role.seller { color: var(--copper); }
.tx-card-price { font-family: var(--font-display); font-size: 1.35rem; font-weight: 600; color: var(--navy-800); margin-bottom: 2px; }
.tx-item-meta { font-size: .85rem; color: var(--muted); margin-bottom: 2px; }

/* Bukti komplain (foto/video) */
.complaint-evidence { display: flex; flex-wrap: wrap; gap: 8px; margin: 6px 0; align-items: center; }
.complaint-thumb { width: 64px; height: 64px; object-fit: cover; border-radius: 8px; border: 1px solid var(--border); }

/* Tombol aksi ikon-only (chat / return / cetak) di card komplain */
.btn-icon { width: 38px; height: 38px; padding: 0; display: inline-flex; align-items: center; justify-content: center; font-size: 1.1rem; line-height: 1; border-radius: 10px; }

/* Modal galeri bukti komplain */
.evidence-gallery { display: flex; flex-direction: column; gap: 12px; max-height: 60vh; overflow-y: auto; }
.evidence-gallery .ev-img { width: 100%; border-radius: 10px; border: 1px solid var(--border); object-fit: contain; background: #fff; }
.ev-video { display: inline-block; padding: 10px 14px; border-radius: 10px; background: var(--copper-soft); color: var(--copper); text-decoration: none; font-weight: 600; }

/* Tracking kurir (BinderByte) */
.track-panel { margin-top: 8px; padding: 10px 12px; background: #f7f9fb; border: 1px solid var(--border); border-radius: 10px; }
.track-head { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.track-courier { font-weight: 700; color: var(--navy-800); font-size: .84rem; }
.track-awb { font-family: monospace; color: var(--ink-soft); font-size: .82rem; background: #fff; border: 1px solid var(--border); padding: 1px 6px; border-radius: 6px; }
.track-timeline { list-style: none; margin: 10px 0 0; padding: 0; }
.track-step { display: flex; gap: 10px; position: relative; padding-bottom: 12px; }
.track-step:last-child { padding-bottom: 0; }
.track-step:not(:last-child)::before { content: ""; position: absolute; left: 4px; top: 14px; bottom: 0; width: 2px; background: var(--border); }
.track-dot { flex: 0 0 auto; width: 10px; height: 10px; border-radius: 50%; background: var(--border-strong); margin-top: 3px; }
.track-step.active .track-dot { background: var(--copper); box-shadow: 0 0 0 3px var(--copper-soft); }
.track-step-body { min-width: 0; }
.track-step-desc { font-size: .82rem; color: var(--ink); line-height: 1.45; }
.track-step.active .track-step-desc { font-weight: 600; }
.track-step-date { font-size: .74rem; color: var(--muted); margin-top: 2px; }
.track-step-loc { font-size: .74rem; color: var(--ink-soft); margin-top: 2px; }
.track-detail { margin-top: 8px; padding: 8px 10px; background: #fff; border: 1px solid var(--border); border-radius: 8px; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 6px 14px; }
.track-detail-row { display: flex; flex-direction: column; font-size: .78rem; min-width: 0; }
.track-detail-row span { color: var(--muted); font-size: .7rem; }
.track-detail-row b { color: var(--ink); font-weight: 600; word-break: break-word; }
.tx-card-actions { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 12px; }

.tx-item {
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
  background: var(--surface); border: 1px solid var(--border); border-radius: 12px; padding: 14px 16px; margin-bottom: 10px;
}
.tx-item-main { min-width: 0; }
.tx-item-title { font-weight: 700; color: var(--ink); text-decoration: none; }
.tx-item-title:hover { text-decoration: underline; }
.tx-card-body { display: flex; gap: 14px; align-items: flex-start; }
.tx-card-info { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.tx-card-side { display: flex; flex-direction: column; align-items: center; gap: 6px; flex-shrink: 0; }
.tx-thumb-lg { width: 60px; height: 60px; border-radius: 8px; object-fit: cover; flex-shrink: 0; border: 1px solid var(--border); }
.tx-deadline { margin-top: 8px; font-size: .82rem; font-weight: 700; color: var(--copper); }
.tx-deadline.expired { color: var(--red, #dc2626); }

.ledger-item {
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
  background: var(--surface); border: 1px solid var(--border); border-radius: 12px; padding: 12px 16px; margin-bottom: 8px;
}
.ledger-type { font-weight: 700; font-size: .9rem; }
.ledger-amt { font-weight: 800; font-size: .95rem; }
.ledger-amt.pos { color: var(--green); }
.ledger-amt.neg { color: var(--red); }

/* Buku kas (tabel kecil pembukuan) */
.ledger-table { width: 100%; border-collapse: collapse; font-size: .85rem; }
.ledger-table th {
  text-align: left; font-size: .72rem; text-transform: uppercase; letter-spacing: .04em;
  color: var(--muted); padding: 8px 10px; border-bottom: 2px solid var(--border-strong);
}
.ledger-table td { padding: 8px 10px; border-bottom: 1px solid var(--border); vertical-align: top; }
.ledger-table th.num, .ledger-table td.num { text-align: right; font-variant-numeric: tabular-nums; white-space: nowrap; }
.ledger-table td.pos { color: var(--green); font-weight: 600; }
.ledger-table td.neg { color: var(--red); font-weight: 600; }
.ledger-table td.nowrap { white-space: nowrap; }

.withdraw-box { background: var(--surface); border: 1px solid var(--border); border-radius: 14px; padding: 18px; box-shadow: var(--shadow-sm); }
.withdraw-form { display: flex; gap: 8px; flex-wrap: wrap; }
.withdraw-form input { flex: 1; min-width: 130px; margin: 0; }

/* ===== Account ===== */
.acct-container { padding-top: 28px; padding-bottom: 48px; }
.acct-head h1 { font-family: var(--font-display); font-weight: 600; font-size: 1.8rem; color: var(--navy-900); margin-bottom: 4px; }
.acct-layout { display: grid; grid-template-columns: 280px 1fr; gap: 24px; align-items: start; margin-top: 20px; }
.acct-side { position: sticky; top: 90px; }
.acct-profile-card {
  background: var(--surface); border: 1px solid var(--border); border-radius: 16px;
  padding: 24px; text-align: center; box-shadow: var(--shadow-sm);
}
.acct-photo { display: block; margin: 0 auto; width: 96px; height: 96px; border-radius: 50%; object-fit: cover; border: 3px solid var(--copper-soft); }
.acct-photo-btn { display: inline-flex; margin-top: 12px; }
.acct-profile-card h3 { margin-top: 12px; font-weight: 800; color: var(--navy-900); font-size: 1.1rem; }
.acct-main { min-width: 0; }
.acct-tabs { display: flex; gap: 4px; border-bottom: 1px solid var(--border); margin-bottom: 16px; overflow-x: auto; }
.acct-tab {
  background: none; border: none; padding: 11px 18px; font-size: .92rem; font-weight: 700;
  color: var(--muted); cursor: pointer; border-bottom: 2px solid transparent; font-family: var(--font-body); white-space: nowrap;
  transition: color .15s, border-color .15s;
}
.acct-tab:hover { color: var(--ink); }
.acct-tab.active { color: var(--copper); border-bottom-color: var(--copper); }
.acct-panel { display: none; }
.acct-panel.active { display: block; animation: ownerFade .2s ease; }
.acct-card { background: var(--surface); border: 1px solid var(--border); border-radius: 16px; padding: 22px; box-shadow: var(--shadow-sm); }
.acct-form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 0 14px; }
.acct-field { margin-bottom: 4px; }
.acct-field-full { grid-column: 1 / -1; }
.acct-field label { font-size: .82rem; color: var(--ink-soft); font-weight: 700; }
.acct-card .btn { margin-top: 12px; }
@media (max-width: 760px) {
  .acct-layout { grid-template-columns: 1fr; }
  .acct-side { position: static; }
  .acct-form-grid { grid-template-columns: 1fr; }
}

/* ===== Buttons & forms ===== */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  background: var(--copper); color: #fff; border: none; border-radius: 10px;
  padding: 11px 20px; font-size: .95rem; cursor: pointer; font-weight: 700;
  transition: background .15s, box-shadow .15s, transform .1s; box-shadow: var(--shadow-sm);
  font-family: var(--font-body);
}
.btn:hover { background: var(--copper-hover); color: #fff; box-shadow: var(--shadow); }
.btn:active { transform: translateY(1px); }
.btn-sm { padding: 7px 14px; font-size: .84rem; border-radius: 8px; }
.btn-block { width: 100%; margin-top: 14px; }
.btn-ghost { background: var(--surface); border: 1px solid var(--border); color: var(--ink-soft); box-shadow: none; }
.btn-ghost:hover { background: var(--bg); color: var(--ink); border-color: var(--border-strong); }
.btn-navy { background: var(--navy-800); }
.btn-navy:hover { background: var(--navy-900); }

input, select, textarea {
  width: 100%; background: var(--surface); border: 1.5px solid var(--border);
  color: var(--ink); border-radius: 10px; padding: 12px 14px; font-size: .96rem;
  margin: 6px 0 14px; outline: none; transition: border-color .15s, box-shadow .15s;
  font-family: var(--font-body);
}
input:focus, select:focus, textarea:focus { border-color: var(--copper); box-shadow: 0 0 0 3px rgba(224,96,32,.12); }
label { font-size: .85rem; color: var(--ink-soft); font-weight: 700; }

.error { color: var(--red); font-size: .85rem; margin-top: 6px; min-height: 1em; }
.bank-locked { background: var(--warn-soft, #fff8e6); border: 1px solid var(--warn, #d99a1b); color: #8a6114; border-radius: 10px; padding: 10px 14px; font-size: .88rem; margin: 10px 0; line-height: 1.5; }
.login-error-banner { background: var(--red-soft); color: var(--red); border: 1px solid var(--red); border-radius: 10px; padding: 10px 14px; font-size: .88rem; margin-bottom: 14px; line-height: 1.45; }
.muted { color: var(--muted); }

/* ===== Auth card ===== */
.auth-card {
  max-width: 430px; margin: 48px auto; background: var(--surface);
  border: 1px solid var(--border); border-radius: 18px; padding: 32px; box-shadow: var(--shadow);
}
.auth-card.wide { max-width: 600px; }
.auth-card h1 { font-family: var(--font-display); font-weight: 600; font-size: 1.7rem; margin-bottom: 6px; color: var(--navy-900); }
.auth-card .sub { color: var(--muted); margin-bottom: 22px; font-size: .95rem; }
.auth-brand { text-align: center; }
.auth-logo { height: 84px; width: auto; margin-bottom: 10px; }
.auth-brand h1 { font-size: 1.6rem; }
.tagline { color: var(--copper); font-weight: 600; font-size: .9rem; letter-spacing: .02em; margin-bottom: 22px; }

/* ===== Login (redesign) ===== */
.login-wrap { display: flex; justify-content: center; padding: 48px 16px; }
.login-card {
  width: 100%; max-width: 430px; background: var(--surface);
  border: 1px solid var(--border); border-radius: 18px; padding: 36px 32px; box-shadow: var(--shadow);
}
.login-brand { text-align: center; margin-bottom: 20px; }
.login-logo { height: 72px; width: auto; margin-bottom: 12px; }
.login-brand h1 { font-family: var(--font-display); font-weight: 600; font-size: 1.5rem; color: var(--navy-900); margin-bottom: 4px; }
.login-brand .muted { font-size: .92rem; }
.login-google { margin-bottom: 4px; }
.btn-google {
  display: flex; align-items: center; justify-content: center; gap: 10px;
  width: 100%; padding: 12px; border: 1.5px solid var(--border); border-radius: 12px;
  background: var(--surface); color: var(--ink); font-weight: 700; font-size: .95rem;
  text-decoration: none; transition: background .15s, border-color .15s;
}
.btn-google:hover { background: var(--bg); border-color: var(--border-strong); color: var(--ink); }
.btn-facebook {
  display: flex; align-items: center; justify-content: center; gap: 10px;
  width: 100%; padding: 12px; border: 1.5px solid var(--border); border-radius: 12px;
  background: var(--surface); color: var(--ink); font-weight: 700; font-size: .95rem;
  text-decoration: none; transition: background .15s, border-color .15s;
}
.btn-facebook:hover { background: var(--bg); border-color: var(--border-strong); color: var(--ink); }
.login-divider { display: flex; align-items: center; gap: 12px; margin: 18px 0 14px; color: var(--muted); font-size: .82rem; }
.login-divider::before, .login-divider::after { content: ""; flex: 1; height: 1px; background: var(--border); }
.login-social { display: flex; flex-direction: column; justify-content: center; gap: 12px; margin-bottom: 4px; }
.social-btn {
  display: flex; align-items: center; justify-content: center; gap: 10px;
  width: 100%; padding: 12px 16px; border-radius: 10px;
  font-weight: 700; font-size: .95rem; text-decoration: none;
  border: 1.5px solid transparent; transition: transform .15s, opacity .15s;
}
.social-btn:hover { transform: translateY(-2px); opacity: .94; }
.social-fb { background: #1877F2; color: #fff; }
.social-gg { background: var(--surface); color: var(--ink); border-color: var(--border); }
.social-icon {
  width: 48px; height: 48px; border-radius: 50%;
  border: 1.5px solid var(--border); background: var(--surface);
  display: flex; align-items: center; justify-content: center;
  transition: background .15s, border-color .15s, transform .15s;
  text-decoration: none;
}
.social-icon:hover { background: var(--bg); border-color: var(--border-strong); transform: translateY(-2px); }
.legal-page { max-width: 760px; padding: 40px 20px 60px; line-height: 1.7; }
.legal-page h1 { font-family: var(--font-display); font-size: 2rem; font-weight: 700; color: var(--navy-900); margin-bottom: 4px; }
.legal-page h2 { font-size: 1.2rem; font-weight: 700; color: var(--navy-800); margin: 24px 0 8px; }
.legal-page p, .legal-page li { color: var(--ink-soft); }
.legal-page ul { margin: 0 0 12px; padding-left: 20px; }
.legal-page li { margin-bottom: 6px; }
.legal-page a { color: var(--blue); }

/* ===== Legal / policy pages (redesign) ===== */
.legal-hero {
  background: linear-gradient(155deg, var(--navy-950) 0%, var(--navy-800) 60%, var(--navy-700) 130%);
  color: #fff; padding: 56px 0 72px; position: relative; overflow: hidden;
}
.legal-hero::before {
  content: ""; position: absolute; right: -100px; top: -80px; width: 420px; height: 420px;
  background: radial-gradient(circle, rgba(224,96,32,.4), transparent 62%); border-radius: 50%;
}
.legal-hero::after {
  content: ""; position: absolute; left: -60px; bottom: -120px; width: 320px; height: 320px;
  background: radial-gradient(circle, rgba(33,107,165,.35), transparent 60%); border-radius: 50%;
}
.legal-hero .container { position: relative; z-index: 1; max-width: 760px; }
.legal-hero .legal-eyebrow {
  display: inline-block; font-size: .72rem; font-weight: 700; letter-spacing: .14em; text-transform: uppercase;
  color: #f8c7a0; background: rgba(255,255,255,.08); border: 1px solid rgba(255,255,255,.16);
  padding: 5px 12px; border-radius: 20px; margin-bottom: 14px;
}
.legal-hero h1 {
  font-family: var(--font-display); font-weight: 600; font-size: clamp(1.9rem, 4vw, 2.6rem);
  line-height: 1.15; letter-spacing: -.01em; margin-bottom: 10px;
}
.legal-hero .legal-updated { color: rgba(255,255,255,.68); font-size: .88rem; margin: 0; }
.legal-body { max-width: 760px; margin: -40px auto 0; padding: 0 20px 64px; position: relative; z-index: 2; }
.legal-card {
  background: var(--surface); border: 1px solid var(--border); border-radius: 18px;
  padding: 36px 40px; box-shadow: var(--shadow-lg);
}
.legal-card h2 {
  font-family: var(--font-display); font-weight: 600; font-size: 1.25rem; color: var(--navy-900);
  margin: 26px 0 8px; padding-bottom: 8px; border-bottom: 1px solid var(--border);
}
.legal-card h2:first-child { margin-top: 0; }
.legal-card p, .legal-card li { color: var(--ink-soft); font-size: .94rem; line-height: 1.75; }
.legal-card ul { margin: 6px 0 12px; padding-left: 20px; }
.legal-card li { margin-bottom: 6px; }
.legal-card a { color: var(--copper); font-weight: 600; }
.legal-card a:hover { color: var(--copper-hover); }
.legal-card .legal-note {
  margin-top: 24px; padding-top: 16px; border-top: 1px solid var(--border);
  font-size: .82rem; color: var(--muted);
}
/* ===== Page hero (header seragam untuk halaman internal) ===== */
.page-hero {
  background: linear-gradient(155deg, var(--navy-950) 0%, var(--navy-800) 60%, var(--navy-700) 130%);
  color: #fff; padding: 46px 0 54px; position: relative; overflow: hidden;
}
.page-hero::before {
  content: ""; position: absolute; right: -100px; top: -80px; width: 420px; height: 420px;
  background: radial-gradient(circle, rgba(224,96,32,.4), transparent 62%); border-radius: 50%;
}
.page-hero::after {
  content: ""; position: absolute; left: -60px; bottom: -120px; width: 320px; height: 320px;
  background: radial-gradient(circle, rgba(33,107,165,.35), transparent 60%); border-radius: 50%;
}
.page-hero .container { position: relative; z-index: 1; }
.page-hero .page-eyebrow {
  display: inline-block; font-size: .72rem; font-weight: 700; letter-spacing: .14em; text-transform: uppercase;
  color: #f8c7a0; background: rgba(255,255,255,.08); border: 1px solid rgba(255,255,255,.16);
  padding: 5px 12px; border-radius: 20px; margin-bottom: 14px;
}
.page-hero h1 {
  font-family: var(--font-display); font-weight: 600; font-size: clamp(1.8rem, 4vw, 2.4rem);
  line-height: 1.15; letter-spacing: -.01em; margin-bottom: 10px;
}
.page-hero .page-sub { color: rgba(255,255,255,.74); font-size: .98rem; max-width: 680px; margin: 0; }
.page-hero .page-hero-actions { margin-top: 20px; display: flex; gap: 10px; flex-wrap: wrap; }
.page-hero .page-hero-actions .btn { box-shadow: var(--shadow); }
.page-content { padding-top: 28px; padding-bottom: 48px; }
/* ===== Kontak cards ===== */
.legal-contact-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; margin-top: 20px; }
.legal-contact-item {
  background: var(--surface); border: 1px solid var(--border); border-radius: 14px;
  padding: 18px 20px; box-shadow: var(--shadow-sm);
}
.legal-contact-item .lc-label {
  font-size: .72rem; font-weight: 800; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); margin-bottom: 6px;
}
.legal-contact-item .lc-value { font-size: .95rem; color: var(--ink); font-weight: 600; }
.legal-contact-item .lc-value a { color: var(--copper); }
@media (max-width: 640px) {
  .legal-card { padding: 26px 22px; }
  .legal-contact-grid { grid-template-columns: 1fr; }
}
.rules-overlay { position: fixed; inset: 0; background: rgba(0,0,0,.55); display: flex; align-items: center; justify-content: center; z-index: 2000; padding: 20px; }
.rules-card { background: var(--surface); border-radius: 16px; max-width: 560px; width: 100%; max-height: 88vh; display: flex; flex-direction: column; overflow: hidden; box-shadow: var(--shadow-lg); }
.rules-head { flex: 0 0 auto; padding: 20px 24px; border-bottom: 1px solid var(--border); }
.rules-head h2 { font-family: var(--font-display); font-size: 1.4rem; font-weight: 700; color: var(--navy-900); }
.rules-head .muted { margin: 4px 0 0; }
.rules-body { flex: 1 1 auto; min-height: 0; padding: 16px 24px; overflow-y: auto; -webkit-overflow-scrolling: touch; overscroll-behavior: contain; }
.rules-body h3 { font-size: 1rem; font-weight: 700; color: var(--navy-800); margin: 16px 0 6px; }
.rules-body p, .rules-body li { font-size: .9rem; color: var(--ink-soft); line-height: 1.6; }
.rules-body ul { padding-left: 18px; margin: 0 0 8px; }
.rules-foot { flex: 0 0 auto; padding: 16px 24px; border-top: 1px solid var(--border); }
.rules-foot .btn { width: 100%; }
.rules-foot .btn:disabled { opacity: .45; cursor: not-allowed; }
.rules-check { display: flex; gap: 10px; align-items: flex-start; font-size: .85rem; color: var(--ink-soft); margin-bottom: 10px; line-height: 1.5; cursor: pointer; }
.rules-check input { margin-top: 2px; flex: none; width: 18px; height: 18px; accent-color: var(--copper); }
.rules-check a, .rules-links a { color: var(--copper); font-weight: 600; }
.rules-links { margin-top: 14px; font-size: .85rem; }
.rules-reject { display: block; text-align: center; margin-top: 10px; font-size: .82rem; color: var(--muted); text-decoration: underline; }
body.consent-open { overflow: hidden; }

/* Modal consent: bottom sheet & tipografi ringkas di HP */
@media (max-width: 640px) {
  .rules-overlay { padding: 0; align-items: flex-end; }
  .rules-card { max-width: 100%; width: 100%; max-height: 94vh; max-height: 94dvh; border-radius: 20px 20px 0 0; }
  .rules-head { padding: 16px 18px 10px; }
  .rules-head h2 { font-size: 1.15rem; }
  .rules-head .muted { font-size: .78rem; line-height: 1.4; margin-top: 2px; }
  .rules-body { padding: 8px 18px 12px; }
  .rules-body h3 { font-size: .9rem; margin: 10px 0 4px; }
  .rules-body p, .rules-body li { font-size: .82rem; line-height: 1.45; }
  .rules-body ul { padding-left: 16px; margin-bottom: 6px; }
  .rules-foot { padding: 10px 18px calc(10px + env(safe-area-inset-bottom)); }
  .rules-check { font-size: .78rem; gap: 8px; margin-bottom: 8px; }
  .rules-check input { width: 18px; height: 18px; margin-top: 1px; }
  .rules-foot .btn { padding: 11px 14px; font-size: .9rem; }
  .rules-reject { margin-top: 6px; font-size: .76rem; }
  .rules-links { font-size: .78rem; margin-top: 10px; }
}
.login-divider { display: flex; align-items: center; gap: 12px; margin: 18px 0; color: var(--muted); font-size: .8rem; }
.login-divider::before, .login-divider::after { content: ""; flex: 1; height: 1px; background: var(--border); }
.login-links { display: flex; justify-content: center; gap: 8px; margin-top: 16px; font-size: .9rem; }
.login-card-wide { max-width: 560px; }
.auth-section {
  font-size: .72rem; font-weight: 800; letter-spacing: .12em; text-transform: uppercase;
  color: var(--copper); margin: 24px 0 8px; padding-bottom: 6px;
  border-bottom: 1px solid var(--border);
}
.auth-section:first-of-type { margin-top: 0; }
.verify-title { font-family: var(--font-display); font-size: 1.2rem; color: var(--navy-900); text-align: center; margin: 0 0 4px; }
.avail-hint { min-height: 1.2em; font-size: .85rem; margin: -8px 0 10px; }
.avail-ok { color: var(--green, #1a7f37); font-weight: 600; }
.avail-bad { color: var(--red, #d5230d); font-weight: 600; }
.acct-banner { background: #fdeee3; border: 1px solid #f5c6a4; color: #7a3d1a; padding: 14px 16px; border-radius: 12px; margin-bottom: 18px; font-size: .92rem; }
@media (max-width: 480px) {
  .login-card { padding: 26px 20px; }
}

/* ===== Modal (PIN owner) ===== */
.modal-overlay {
  position: fixed; inset: 0; background: rgba(8,24,40,.55);
  display: flex; align-items: center; justify-content: center; z-index: 999; padding: 20px;
}
.modal-card {
  background: var(--surface); border-radius: 18px; padding: 28px; max-width: 380px; width: 100%;
  box-shadow: var(--shadow-lg); text-align: center;
}
.modal-card-wide { max-width: 480px; }
.modal-card h2 { font-family: var(--font-display); font-size: 1.4rem; color: var(--navy-900); margin-bottom: 8px; }
.modal-card .muted { margin-bottom: 18px; }
.modal-card input { margin-bottom: 12px; }

/* ===== Detail page ===== */
.detail-wrap { display: grid; grid-template-columns: 1fr 350px; gap: 28px; }
.gallery { margin: 20px 0; }
.gallery-main { width: 100%; height: 360px; object-fit: cover; border-radius: var(--radius); border: 1px solid var(--border); background: #f3f4f6; }
.gallery-thumbs { display: flex; gap: 8px; margin-top: 10px; flex-wrap: wrap; }
.gallery-thumbs img { width: 72px; height: 72px; object-fit: cover; border-radius: 8px; cursor: pointer; border: 2px solid var(--border); transition: border-color .15s; }
.gallery-thumbs img.active, .gallery-thumbs img:hover { border-color: var(--copper); }
.detail-main h1 { font-family: var(--font-display); font-weight: 600; font-size: 2rem; margin: 12px 0 6px; line-height: 1.15; color: var(--navy-900); }
.badge {
  display: inline-block; background: var(--copper-soft); color: var(--copper);
  padding: 5px 13px; border-radius: 20px; font-size: .75rem; font-weight: 800; text-transform: uppercase; letter-spacing: .05em;
}
.detail-hero {
  height: 300px; border-radius: var(--radius); margin: 20px 0;
  background: linear-gradient(135deg, var(--navy-800), var(--blue));
  display: flex; align-items: center; justify-content: center;
}
.detail-hero .media-emoji { font-size: 5rem; filter: drop-shadow(0 5px 10px rgba(0,0,0,.3)); }
.price-box {
  background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius);
  padding: 24px; margin: 20px 0; box-shadow: var(--shadow-sm);
}
.price-box .label { color: var(--muted); font-size: .85rem; font-weight: 600; }
.big-price { font-family: var(--font-display); font-size: 2.6rem; font-weight: 600; color: var(--navy-800); margin: 4px 0; }
.countdown { margin-bottom: 16px; font-weight: 600; color: var(--ink-soft); }
.bid-form { display: flex; gap: 10px; flex-wrap: wrap; }
.bid-form input { flex: 1; margin: 0; min-width: 150px; }

.detail-side { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 22px; box-shadow: var(--shadow-sm); height: fit-content; }
.detail-side h3 { font-family: var(--font-display); font-weight: 600; font-size: 1.2rem; color: var(--navy-900); }
.bid-list { list-style: none; margin-top: 12px; }
.bid-list li { display: flex; justify-content: space-between; padding: 10px 0; border-bottom: 1px solid var(--border); font-size: .9rem; }
.bid-list .amt { color: var(--navy-800); font-weight: 800; }
.bid-list .time { color: var(--muted); font-size: .8rem; }
.ld-bidhistory { margin-top: 18px; }
.ld-bidhistory-head { font-weight: 800; font-size: .95rem; color: var(--navy-900); margin-bottom: 2px; }
.ld-bidhistory .bid-list { max-height: 220px; overflow-y: auto; margin-top: 6px; padding-right: 4px; }

/* ===== Dashboard ===== */
.cards { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 16px; margin: 16px 0 26px; }
.stat-card { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 20px; box-shadow: var(--shadow-sm); }
.stat-card .label { font-size: .8rem; color: var(--muted); font-weight:600; text-transform: uppercase; letter-spacing: .05em; }
.stat-card .big { font-family: var(--font-display); font-size: 1.7rem; font-weight: 600; color: var(--navy-800); }
.inline-form { display: flex; flex-wrap: wrap; gap: 8px; margin: 12px 0; }
.inline-form input { flex: 1; min-width: 120px; margin: 0; }
h3 { margin: 26px 0 10px; font-weight: 800; color: var(--navy-900); font-size: 1.15rem; }

.footer { background: var(--navy-950); color: rgba(255,255,255,.72); padding: 48px 0 0; font-size: .88rem; margin-top: 40px; }
.footer-grid { display: grid; grid-template-columns: 1.6fr 1fr 1fr 1fr; gap: 32px; padding-bottom: 36px; }
.footer-col h4 { color: #fff; font-size: .82rem; font-weight: 800; letter-spacing: .08em; text-transform: uppercase; margin: 0 0 14px; opacity: .95; }
.footer-brand { display: flex; flex-direction: column; gap: 12px; }
.footer-logo { display: flex; align-items: center; gap: 10px; color: #fff; text-decoration: none; font-family: var(--font-display); font-size: 1.25rem; font-weight: 600; }
.footer-logo img { height: 30px; width: 30px; border-radius: 8px; }
.footer-tag { margin: 0; line-height: 1.6; color: rgba(255,255,255,.62); font-size: .85rem; max-width: 320px; }
.footer-links { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 10px; }
.footer-links a { color: rgba(255,255,255,.72); text-decoration: none; transition: color .15s ease; }
.footer-links a:hover { color: var(--gold); }
.footer-links span { color: rgba(255,255,255,.55); }
.footer-bottom { display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 10px; padding: 18px 0; border-top: 1px solid rgba(255,255,255,.1); font-size: .82rem; color: rgba(255,255,255,.55); }
.footer-bottom .muted { color: rgba(255,255,255,.45); }

/* ===== Badge notif ===== */
.badge-num {
  display: inline-block; background: var(--red); color: #fff; border-radius: 10px;
  padding: 0 7px; font-size: .72rem; font-weight: 800; margin-left: 3px; line-height: 1.5;
}

/* ===== Dropdown notifikasi (floating) ===== */
.notif-panel {
  position: fixed; top: 70px; right: 24px; width: 360px; max-width: calc(100vw - 32px);
  max-height: 70vh; display: none; flex-direction: column; z-index: 300;
  background: var(--surface); border: 1px solid var(--border); border-radius: 14px;
  box-shadow: var(--shadow-lg); overflow: hidden;
}
.notif-panel.open { display: flex; }
.notif-panel-head {
  display: flex; align-items: center; justify-content: space-between; gap: 8px;
  padding: 12px 16px; border-bottom: 1px solid var(--border); font-weight: 700;
}
.notif-list { overflow-y: auto; padding: 6px; }
.notif-item { display: flex; gap: 10px; padding: 12px; border-radius: 10px; cursor: pointer; transition: background .15s; }
.notif-item:hover { background: var(--bg); }
.notif-item.read { opacity: .6; }
.notif-item-body { min-width: 0; }
.notif-item-body b { font-size: .9rem; }
.notif-item-body .muted { font-size: .82rem; }
.notif-dot { width: 8px; height: 8px; border-radius: 50%; background: var(--copper); flex-shrink: 0; margin-top: 6px; }
.notif-empty { padding: 24px; text-align: center; color: var(--muted); }

/* ===== PWA install banner ===== */
.install-banner {
  position: fixed; top: 0; left: 0; right: 0;
  z-index: 300; display: flex; align-items: center; gap: 12px;
  background: var(--navy-900); color: #fff;
  padding: 12px 16px; box-shadow: var(--shadow-lg);
  border-bottom: 1px solid rgba(255,255,255,.12);
}
.install-banner-icon { width: 40px; height: 40px; border-radius: 9px; flex-shrink: 0; }
.install-banner-text { display: flex; flex-direction: column; gap: 1px; min-width: 0; }
.install-banner-text strong { font-size: .9rem; line-height: 1.25; }
.install-banner-text span { font-size: .76rem; color: rgba(255,255,255,.7); line-height: 1.3; }
.install-banner .btn { flex-shrink: 0; background: var(--copper); color: #fff; border: none; }
.install-banner .btn:hover { background: var(--copper-hover); color: #fff; }
.install-banner-close { background: none; border: none; color: rgba(255,255,255,.6); font-size: 1.3rem; line-height: 1; cursor: pointer; padding: 2px 6px; border-radius: 6px; flex-shrink: 0; }
.install-banner-close:hover { background: rgba(255,255,255,.12); color: #fff; }

/* Banner install hanya tampil di mobile (desktop disembunyikan). */
@media (min-width: 761px) {
  .install-banner { display: none !important; }
}

/* ===== Floating chat widget (WhatsApp style) ===== */
.chat-fab {
  position: fixed; bottom: 22px; right: 22px; width: 58px; height: 58px; border-radius: 50%;
  background: var(--copper); color: #fff; border: none; cursor: pointer; z-index: 250;
  display: flex; align-items: center; justify-content: center; box-shadow: var(--shadow-lg);
  transition: transform .15s, background .15s;
}
.chat-fab:hover { background: var(--copper-hover); transform: translateY(-2px); }
.chat-fab .badge-num { position: absolute; top: -4px; right: -4px; margin: 0; }
.chat-widget {
  position: fixed; bottom: 92px; right: 22px; width: 380px; max-width: calc(100vw - 32px);
  height: 520px; max-height: calc(100vh - 120px); z-index: 251;
  display: none; flex-direction: column; background: var(--surface);
  border: 1px solid var(--border); border-radius: 16px; box-shadow: var(--shadow-lg); overflow: hidden;
}
.chat-widget.open { display: flex; }
.chat-widget-head {
  display: flex; align-items: center; gap: 10px; padding: 12px 16px;
  background: var(--navy-800); color: #fff; font-weight: 700;
}
.chat-head-title-wrap { flex: 1; display: flex; align-items: center; gap: 8px; min-width: 0; }
.chat-head-profile { color: #ffd2a8; font-weight: 700; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 220px; }
.chat-head-profile:hover { color: #fff; text-decoration: underline; }
.chat-back, .chat-close { background: none; border: none; color: #fff; cursor: pointer; font-size: 1.2rem; line-height: 1; padding: 4px 6px; border-radius: 6px; }
.chat-back:hover, .chat-close:hover { background: rgba(255,255,255,.12); }
.chat-widget-body { flex: 1; min-height: 0; display: flex; flex-direction: column; }
.chat-view { flex: 1; min-height: 0; overflow-y: auto; overscroll-behavior: contain; }
.chat-widget .chat-empty { display: flex; flex-direction: column; align-items: center; justify-content: center; height: 100%; }
.chat-widget .chat-active { display: flex; flex-direction: column; height: 100%; }
.chat-widget .chat-messages { flex: 1; overflow-y: auto; padding: 14px; display: flex; flex-direction: column; gap: 8px; min-height: 0; overscroll-behavior: contain; }
.chat-widget .chat-input { display: flex; gap: 8px; padding: 10px; border-top: 1px solid var(--border); }
.chat-widget .chat-input input { flex: 1; margin: 0; }

/* ===== Chat ===== */
.chat-shell { display: grid; grid-template-columns: 300px 1fr; gap: 20px; }
.chat-list-pane { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 18px; box-shadow: var(--shadow-sm); height: calc(100vh - 200px); min-height: 480px; min-width: 0; overflow-y: auto; }
.chat-list-pane h3 { font-family: var(--font-display); font-weight: 600; color: var(--navy-900); margin-top: 0; }
.chat-main-pane { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); box-shadow: var(--shadow-sm); display: flex; flex-direction: column; height: calc(100vh - 200px); min-height: 480px; overflow: hidden; }
.chat-empty { display: flex; flex-direction: column; align-items: center; justify-content: center; flex: 1; gap: 10px; }
.chat-empty .big-emoji { font-size: 3rem; }
.chat-active { display: flex; flex-direction: column; flex: 1; min-height: 0; }
.chat-messages { flex: 1; overflow-y: auto; padding: 16px; display: flex; flex-direction: column; gap: 10px; min-height: 0; overscroll-behavior: contain; }
.chat-header { display: flex; align-items: center; gap: 12px; margin-bottom: 12px; }
.chat-input { display: flex; gap: 10px; padding: 12px; border-top: 1px solid var(--border); background: var(--surface); }
.chat-input input { flex: 1; margin: 0; }
.conv-item { display: flex; align-items: center; gap: 10px; padding: 10px 12px; border: 1px solid var(--border); border-radius: 10px; margin-bottom: 8px; color: var(--ink); text-decoration: none; transition: border-color .15s, background .15s; }
.conv-empty { text-align: center; padding: 36px 16px; color: var(--muted); }
.conv-empty-emoji { font-size: 2.4rem; display: block; margin-bottom: 8px; }
.conv-empty p { margin: 0; }
.conv-empty .conv-empty-sub { font-size: .8rem; margin-top: 6px; }
.conv-item:hover { border-color: var(--copper); background: var(--copper-soft); color: var(--ink); }
.conv-item.active { border-color: var(--copper); background: var(--copper-soft); }
.conv-photo { width: 40px; height: 40px; border-radius: 50%; object-fit: cover; flex-shrink: 0; border: 1px solid var(--border); }
.conv-photo-fb { display: flex; align-items: center; justify-content: center; background: var(--copper-soft); color: var(--copper); font-weight: 800; font-size: 1rem; }
.conv-info { flex: 1; min-width: 0; }
.conv-name { font-weight: 700; font-size: .88rem; display: flex; align-items: center; gap: 6px; line-height: 1.2; min-width: 0; }
.conv-name-text { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; min-width: 0; flex: 1; }
.conv-badge { background: var(--copper); color: #fff; font-size: .68rem; font-weight: 700; border-radius: 999px; padding: 1px 7px; flex-shrink: 0; }
.conv-title { font-size: .72rem; color: var(--copper); font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.conv-preview { font-size: .76rem; color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; margin-top: 2px; }
.chat-conv-head { display: flex; align-items: center; gap: 10px; padding: 10px 14px; border-bottom: 1px solid var(--border); background: var(--surface); flex-shrink: 0; }
.chat-conv-photo { width: 36px; height: 36px; border-radius: 50%; object-fit: cover; flex-shrink: 0; border: 1px solid var(--border); }
.chat-conv-photo-fb { display: flex; align-items: center; justify-content: center; background: var(--copper-soft); color: var(--copper); font-weight: 800; font-size: 1rem; }
.chat-conv-info { flex: 1; min-width: 0; }
.chat-conv-name { font-weight: 700; font-size: .9rem; color: var(--ink); line-height: 1.25; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.chat-conv-name a { color: var(--ink); text-decoration: none; }
.chat-conv-name a:hover { text-decoration: underline; color: var(--copper); }
.chat-conv-title { font-size: .74rem; color: var(--muted); line-height: 1.35; overflow: hidden; }
.chat-conv-title a { color: var(--copper); text-decoration: none; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; word-break: break-word; }
.chat-conv-title a:hover { text-decoration: underline; color: var(--copper-hover); }
.msg-avatar { width: 26px; height: 26px; border-radius: 50%; object-fit: cover; flex-shrink: 0; border: 1px solid var(--border); }
.msg-avatar-initial { display: inline-flex; align-items: center; justify-content: center; background: var(--navy-800); color: #fff; font-weight: 700; font-size: .72rem; }
.msg-avatar-ghost { width: 26px; height: 26px; flex-shrink: 0; visibility: hidden; }
.msg-sender { font-size: .68rem; color: var(--muted); margin-bottom: 2px; font-weight: 600; }
.status-tag { position: absolute; top: 12px; right: 12px; background: var(--copper); color: #fff; }
.status-tag.scheduled { background: var(--blue); }
.chat-layout { display: grid; grid-template-columns: 290px 1fr; gap: 20px; }
.chat-detail-full { max-width: 740px; }
.message-list { display: flex; flex-direction: column; gap: 10px; margin: 16px 0; min-height: 340px; }
.msg { display: flex; align-items: flex-end; gap: 8px; }
.msg.mine { flex-direction: row-reverse; }
.msg .msg-body { display: flex; flex-direction: column; max-width: 78%; }
.msg.mine .msg-body { align-items: flex-end; }
.msg .bubble {
  max-width: 100%; padding: 11px 16px; border-radius: 15px;
  background: var(--surface); border: 1px solid var(--border); box-shadow: var(--shadow-sm);
  overflow-wrap: anywhere;
}
.msg.mine .bubble { background: var(--navy-800); color: #fff; border: none; }
.msg .time { font-size: .7rem; color: var(--muted); margin-top: 3px; }
.msg-status { font-size: .62rem; color: var(--muted); margin-left: 6px; letter-spacing: .01em; }
.msg-status.read { color: var(--copper); }
.chat-img { max-width: 240px; max-height: 300px; border-radius: 12px; display: block; cursor: pointer; object-fit: cover; }
.btn-attach { padding: 11px 13px; font-size: 1.1rem; line-height: 1; }
.chat-attach-preview { display: flex; align-items: center; gap: 10px; padding: 8px 12px; border-top: 1px solid var(--border); background: var(--surface); }
.chat-attach-preview img { width: 52px; height: 52px; object-fit: cover; border-radius: 8px; border: 1px solid var(--border); }

/* ===== 404 ===== */
.notfound { text-align: center; padding: 80px 0; }
.notfound h1 { font-family: var(--font-display); font-size: 4rem; color: var(--navy-800); }

/* ===== Account / profil ===== */
.account-grid { display: grid; grid-template-columns: 280px 1fr; gap: 20px; align-items: start; }
.account-side .profile-card { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 22px; text-align: center; box-shadow: var(--shadow-sm); }
.profile-photo { width: 96px; height: 96px; border-radius: 50%; object-fit: cover; border: 3px solid var(--copper-soft); }
.profile-public { max-width: 520px; margin: 40px auto; text-align: center; background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 32px; box-shadow: var(--shadow); }
.profile-public h1 { font-family: var(--font-display); margin: 12px 0 0; }
.profile-public .profile-photo { width: 120px; height: 120px; }

/* ===== Halaman user (profil publik) ===== */
.up-container { padding-top: 28px; padding-bottom: 40px; }
.up-layout { display: grid; grid-template-columns: 300px 1fr; gap: 24px; align-items: start; }
.up-side { position: sticky; top: 90px; }
.up-card {
  background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius);
  padding: 26px 24px; text-align: center; box-shadow: var(--shadow-sm); position: relative;
}
.up-share {
  position: absolute; top: 14px; right: 14px;
  display: inline-flex; align-items: center; justify-content: center;
  width: 38px; height: 38px; border-radius: 10px;
  border: 1px solid var(--border); background: var(--surface);
  color: var(--muted); cursor: pointer;
  transition: color .15s, border-color .15s, background .15s, transform .1s;
}
.up-share:hover { color: var(--copper); border-color: var(--copper); background: var(--copper-soft); }
.up-share:active { transform: scale(.94); }
.up-report {
  position: absolute; top: 14px; right: 60px;
  display: inline-flex; align-items: center; justify-content: center;
  padding: 0 12px; height: 38px; border-radius: 10px;
  border: 1px solid var(--border); background: var(--surface);
  color: var(--muted); cursor: pointer;
  font-size: .8rem; font-weight: 700;
  transition: color .15s, border-color .15s, background .15s, transform .1s;
}
.up-report:hover { color: #d5230d; border-color: #d5230d; background: #fdecea; }
.up-report:active { transform: scale(.94); }
.up-photo { width: 110px; height: 110px; border-radius: 50%; object-fit: cover; border: 3px solid var(--copper-soft); }
.up-name { font-family: var(--font-display); font-size: 1.35rem; color: var(--navy-900); margin: 12px 0 2px; }
.up-username { font-size: .9rem; }
.up-facebook { margin-top: 8px; display: flex; justify-content: center; align-items: center; gap: 6px; flex-wrap: wrap; }
.up-facebook a { color: var(--copper); font-weight: 700; }
.up-meta { text-align: left; margin-top: 16px; padding-top: 16px; border-top: 1px solid var(--border); display: flex; flex-direction: column; gap: 8px; }
.up-meta-row { font-size: .88rem; }
.up-meta-label { color: var(--muted); font-weight: 700; display: inline-block; min-width: 64px; }
.up-joined { margin-top: 14px; font-size: .8rem; }
.up-main { min-width: 0; }
.up-tabs { display: flex; gap: 4px; border-bottom: 1px solid var(--border); margin-bottom: 16px; overflow-x: auto; }
.up-tab {
  background: none; border: none; padding: 11px 18px; font-size: .92rem; font-weight: 700;
  color: var(--muted); cursor: pointer; border-bottom: 2px solid transparent; font-family: var(--font-body); white-space: nowrap;
  transition: color .15s, border-color .15s;
}
.up-tab:hover { color: var(--ink); }
.up-tab.active { color: var(--copper); border-bottom-color: var(--copper); }
.up-panel { display: none; }
.up-panel.active { display: block; animation: ownerFade .2s ease; }
.up-filter { display: flex; gap: 10px; align-items: center; margin-bottom: 14px; flex-wrap: wrap; }
@media (max-width: 900px) {
  .up-layout { grid-template-columns: 1fr; }
  .up-side { position: static; }
}

/* ===== Seller card (halaman lelang) ===== */
.seller-card { display: flex; align-items: center; gap: 14px; background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 16px 18px; margin-top: 24px; box-shadow: var(--shadow-sm); }
.seller-avatar { width: 52px; height: 52px; border-radius: 50%; object-fit: cover; display: block; }
.seller-avatar-fallback { display: flex; align-items: center; justify-content: center; background: var(--copper-soft); color: var(--copper); font-weight: 800; font-size: 1.2rem; }
.seller-info { display: flex; flex-direction: column; gap: 2px; font-size: .9rem; }
.seller-info a { color: var(--copper); font-weight: 700; }

/* ===== Detail produk (redesign) ===== */
.ld-container { padding-top: 28px; padding-bottom: 40px; }
.ld-grid { display: grid; grid-template-columns: minmax(0, 1.05fr) minmax(0, .95fr); gap: 32px; align-items: start; }

.ld-gallery { }
.ld-gallery-main {
  position: relative; width: 100%; aspect-ratio: 4 / 3; border-radius: 16px; overflow: hidden;
  background: #eef1f5; border: 1px solid var(--border); display: flex; align-items: center; justify-content: center;
}
.ld-gallery-main img { width: 100%; height: 100%; object-fit: contain; cursor: zoom-in; }
.ld-zoom-hint {
  position: absolute; right: 12px; bottom: 12px; width: 40px; height: 40px; border-radius: 10px;
  background: rgba(255,255,255,.9); color: var(--navy-800); border: 1px solid var(--border);
  cursor: pointer; display: flex; align-items: center; justify-content: center;
  opacity: 0; transition: opacity .15s; z-index: 2;
}
.ld-gallery-main:hover .ld-zoom-hint { opacity: 1; }
.ld-gallery-main .ld-badge { z-index: 1; }
.ld-gallery-empty { font-size: 5rem; color: var(--copper); font-weight: 800; }
.ld-badge {
  position: absolute; top: 14px; left: 14px; background: rgba(255,255,255,.95); color: var(--navy-800);
  padding: 5px 13px; border-radius: 20px; font-size: .74rem; font-weight: 800; letter-spacing: .04em;
  text-transform: uppercase; box-shadow: var(--shadow-sm);
}
.ld-gallery-thumbs { display: grid; grid-template-columns: repeat(auto-fill, minmax(72px, 1fr)); gap: 8px; margin-top: 12px; }
.ld-gallery-thumbs img {
  width: 100%; aspect-ratio: 1; object-fit: cover; border-radius: 10px; cursor: pointer;
  border: 2px solid var(--border); transition: border-color .15s;
}
.ld-gallery-thumbs img.active, .ld-gallery-thumbs img:hover { border-color: var(--copper); }

.ld-title { font-family: var(--font-display); font-weight: 600; font-size: 1.85rem; line-height: 1.2; color: var(--navy-900); margin: 0 0 14px; }

.btn-icon { padding: 11px 14px; }
.btn-icon svg { display: block; }

.ld-meta { display: flex; flex-direction: column; gap: 8px; margin-bottom: 18px; }
.ld-meta-item { display: flex; align-items: baseline; gap: 10px; font-size: .92rem; }
.ld-meta-label { color: var(--muted); font-weight: 700; min-width: 64px; font-size: .82rem; text-transform: uppercase; letter-spacing: .03em; }
.ld-meta-value { color: var(--ink); font-weight: 600; }

.ld-price-box {
  background: var(--surface); border: 1px solid var(--border); border-radius: 16px;
  padding: 22px; box-shadow: var(--shadow-sm); margin-bottom: 18px;
}
.ld-desc-box { margin-bottom: 18px; }
.ld-desc-head { font-weight: 800; font-size: .95rem; color: var(--navy-900); margin-bottom: 6px; }
.ld-desc-box .ld-desc { max-height: 180px; overflow-y: auto; padding-right: 6px; }
.ld-price-label { color: var(--muted); font-size: .82rem; font-weight: 700; text-transform: uppercase; letter-spacing: .04em; }
.ld-price { font-family: var(--font-display); font-size: 2.4rem; font-weight: 600; color: var(--navy-800); margin: 6px 0; line-height: 1; }
.ld-price.price-flash { animation: ldPriceFlash .5s ease; }
@keyframes ldPriceFlash {
  0% { color: var(--copper); transform: scale(1.06); }
  100% { color: var(--navy-800); transform: scale(1); }
}
.ld-price-meta { display: flex; gap: 14px; color: var(--muted); font-size: .88rem; margin-bottom: 14px; flex-wrap: wrap; }
#current-winner { font-weight: 700; }
.you-won { color: var(--green); font-weight: 800; }
.you-lose { color: var(--red); font-weight: 700; }
.ld-countdown { padding: 10px 14px; background: var(--copper-soft); color: var(--copper-hover); border-radius: 10px; font-weight: 700; font-size: .92rem; margin-bottom: 14px; }
.ld-cancel-notice { padding: 10px 14px; background: var(--red-soft, #fef2f2); color: var(--red, #b91c1c); border: 1px solid #fecaca; border-radius: 10px; font-size: .9rem; margin-bottom: 14px; }
.ld-countdown #countdown-text.countdown-urgent { display: inline-block; animation: countdownPulse 1s ease-in-out infinite; }
@keyframes countdownPulse {
  0%, 100% { color: var(--copper-hover); }
  50% { color: var(--red); }
}
.ld-bid-form { display: flex; gap: 10px; flex-wrap: wrap; margin-bottom: 10px; }
.ld-bid-form input { flex: 1; min-width: 150px; margin: 0; }

/* ===== Swipe to bid (quick bid) ===== */
.swipe-bid {
  position: relative;
  width: 100%;
  height: 58px;
  border-radius: 14px;
  background: var(--navy-800);
  overflow: hidden;
  user-select: none;
  -webkit-user-select: none;
  touch-action: none;
  box-shadow: var(--shadow-sm);
}
.swipe-bid-track {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  pointer-events: none;
}
.swipe-bid-label { color: rgba(255,255,255,.72); font-weight: 700; font-size: .92rem; letter-spacing: .02em; }
.swipe-bid-price { color: #fff; font-weight: 800; font-size: 1.05rem; background: rgba(255,255,255,.14); padding: 3px 10px; border-radius: 999px; }
.swipe-bid-knob {
  position: absolute;
  left: 4px; top: 4px;
  width: 50px; height: 50px;
  border-radius: 11px;
  background: var(--copper);
  color: #fff;
  border: none;
  display: flex; align-items: center; justify-content: center;
  cursor: grab;
  touch-action: none;
  box-shadow: 0 2px 8px rgba(0,0,0,.28);
  z-index: 2;
}
.swipe-bid-knob:active { cursor: grabbing; }
.swipe-bid.swipe-dragging .swipe-bid-knob { cursor: grabbing; }
.swipe-bid.swipe-complete .swipe-bid-knob { background: var(--green); }
.swipe-bid.swipe-busy { opacity: .6; pointer-events: none; }
.ld-bid-manual { display: flex; gap: 8px; flex-wrap: wrap; width: 100%; }
.ld-bid-manual input { flex: 1; min-width: 150px; margin: 0; }
.ld-bid-manual .btn { flex-shrink: 0; }

.ld-actions { display: flex; gap: 8px; flex-wrap: wrap; }

.ld-seller {
  display: flex; align-items: flex-start; gap: 14px; background: var(--surface);
  border: 1px solid var(--border); border-radius: 16px; padding: 18px; box-shadow: var(--shadow-sm);
  margin-top: 16px;
}
.ld-seller-photo {
  width: 60px; height: 60px; border-radius: 50%; flex-shrink: 0; overflow: hidden; display: flex;
  align-items: center; justify-content: center; background: var(--copper-soft); color: var(--copper);
  font-weight: 800; font-size: 1.4rem; text-decoration: none;
}
.ld-seller-photo img { width: 100%; height: 100%; object-fit: cover; }
.ld-seller-body { flex: 1; min-width: 0; }
.ld-seller-name { font-weight: 800; font-size: 1.05rem; margin-bottom: 8px; }
.ld-seller-name a { color: var(--copper); }
.ld-seller-row { display: flex; gap: 8px; font-size: .86rem; margin-bottom: 4px; }
.ld-seller-label { color: var(--muted); font-weight: 700; min-width: 64px; flex-shrink: 0; }
.ld-seller-value { color: var(--ink-soft); word-break: break-word; }
.ld-seller-value a { color: var(--copper); }

.ld-section { margin-top: 34px; }
.ld-section h2 { font-family: var(--font-display); font-weight: 600; font-size: 1.35rem; color: var(--navy-900); margin-bottom: 14px; }
.ld-desc { white-space: pre-wrap; line-height: 1.7; color: var(--ink-soft); }

/* ===== Lightbox zoom gambar ===== */
.lightbox {
  position: fixed; inset: 0; z-index: 1000; background: rgba(8,24,40,.92);
  display: flex; align-items: center; justify-content: center;
  opacity: 0; visibility: hidden; transition: opacity .2s ease, visibility .2s ease;
}
.lightbox.open { opacity: 1; visibility: visible; }
.lightbox img { max-width: 92vw; max-height: 88vh; object-fit: contain; border-radius: 12px; box-shadow: var(--shadow-lg); }
.lightbox-close {
  position: absolute; top: 20px; right: 24px; width: 44px; height: 44px; border-radius: 50%;
  background: rgba(255,255,255,.12); color: #fff; border: none; font-size: 1.7rem; line-height: 1;
  cursor: pointer; display: flex; align-items: center; justify-content: center; transition: background .15s;
}
.lightbox-close:hover { background: rgba(255,255,255,.26); }
.lightbox-nav {
  position: absolute; top: 50%; transform: translateY(-50%); width: 46px; height: 46px; border-radius: 50%;
  background: rgba(255,255,255,.12); color: #fff; border: none; font-size: 1.3rem; line-height: 1;
  cursor: pointer; display: flex; align-items: center; justify-content: center; transition: background .15s;
}
.lightbox-nav:hover { background: rgba(255,255,255,.26); }
.lightbox-prev { left: 18px; }
.lightbox-next { right: 18px; }
.lightbox-nav:only-child, .lightbox-nav[style*="none"] { display: none; }
@media (max-width: 600px) {
  .lightbox-prev { left: 10px; }
  .lightbox-next { right: 10px; }
  .lightbox-close { top: 14px; right: 16px; }
}

@media (max-width: 900px) {
  .ld-grid { grid-template-columns: 1fr; gap: 20px; }
  .ld-gallery { position: static; }
  .ld-title { font-size: 1.45rem; }
  .ld-price { font-size: 2rem; }
}

/* ===== Sell item thumbnail ===== */
.sell-thumb { width: 72px; height: 72px; flex-shrink: 0; border-radius: 10px; overflow: hidden; border: 1px solid var(--border); display: flex; align-items: center; justify-content: center; background: var(--surface-2, #f3f4f6); }
.sell-thumb img { width: 100%; height: 100%; object-fit: cover; }
.sell-thumb .media-emoji { font-size: 1.6rem; }

/* ===== Sell list (kelola listing) — baris rapi per item ===== */
.sell-item {
  display: flex !important;
  flex-direction: row !important;
  align-items: center;
  gap: 14px;
  padding: 14px;
  margin: 10px 0;
}
.sell-item-info { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 3px; }
.sell-item-info .title { font-size: 1.05rem; font-weight: 700; color: var(--ink); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.sell-item-info .meta { font-size: .85rem; color: var(--muted); }
.sell-item-info .time { font-size: .8rem; color: var(--muted); }
.sell-item-actions { display: flex; flex-direction: column; gap: 6px; flex-shrink: 0; }
.status-pill {
  display: inline-block; padding: 2px 9px; border-radius: 20px; font-size: .72rem; font-weight: 700;
  letter-spacing: .03em; text-transform: uppercase;
}
.status-pill.draft { background: #eef1f5; color: #55606e; }
.status-pill.scheduled { background: #e7f0fb; color: var(--blue); }
.status-pill.published { background: var(--green-soft); color: var(--green); }
.status-pill.sold { background: var(--copper-soft); color: var(--copper); }
.status-pill.ended_unsold, .status-pill.cancelled { background: var(--red-soft); color: var(--red); }

@media (max-width: 560px) {
  .sell-item { gap: 10px; }
  .sell-thumb { width: 56px; height: 56px; }
  .sell-item-actions { flex-direction: row; }
  .sell-item-actions .btn { padding: 6px 10px; font-size: .78rem; }
}

/* ===== card thumbnail ===== */
.card-thumb { width: 100%; height: 100%; object-fit: contain; }
.card-media img { width: 100%; height: 100%; object-fit: contain; }
.card-media { overflow: hidden; }

@media (max-width: 760px) {
  .account-grid { grid-template-columns: 1fr; }
}

/* ===== Image upload (create form) ===== */
.dropzone {
  position: relative; border: 2px dashed var(--border-strong); border-radius: 12px;
  padding: 34px 16px; text-align: center; cursor: pointer; background: var(--surface);
  transition: border-color .15s, background .15s; margin-bottom: 12px;
}
.dropzone:hover, .dropzone.dragover { border-color: var(--copper); background: var(--copper-soft); }
.dropzone input { position: absolute; inset: 0; opacity: 0; cursor: pointer; margin: 0; }
.dz-placeholder { display: flex; flex-direction: column; align-items: center; gap: 6px; pointer-events: none; }
.dz-plus {
  width: 52px; height: 52px; border-radius: 50%; background: var(--copper-soft); color: var(--copper);
  font-size: 2rem; font-weight: 600; line-height: 1; display: flex; align-items: center; justify-content: center;
}
.dz-text { font-weight: 700; color: var(--ink-soft); }
.dz-hint { font-size: .78rem; color: var(--muted); }
.preview-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(90px, 1fr)); gap: 10px; margin-bottom: 14px; }
.preview-grid .pv {
  position: relative; aspect-ratio: 1; border-radius: 10px; overflow: hidden;
  border: 1px solid var(--border); background: var(--surface);
}
.preview-grid .pv img { width: 100%; height: 100%; object-fit: cover; }
.preview-grid .pv .rm {
  position: absolute; top: 4px; right: 4px; width: 22px; height: 22px; border-radius: 50%;
  background: rgba(0,0,0,.6); color: #fff; border: none; cursor: pointer; font-size: .9rem; line-height: 1;
  display: flex; align-items: center; justify-content: center;
}
.two-col { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.two-col input { margin: 6px 0 0; }
@media (max-width: 900px) {
  .container { padding: 0 16px; }
}

@media (max-width: 760px) {
  /* ===== Mobile navbar (hamburger) ===== */
  .nav-inner { height: 60px; gap: 10px; }
  .brand img { height: 36px; width: auto; }
  .brand { font-size: 1.1rem; }
  .brand .brand-name small { display: none; }
  .nav-toggle { display: inline-flex; }
  .nav-links {
    position: absolute; top: 60px; left: 0; right: 0;
    background: var(--surface); border-bottom: 1px solid var(--border);
    flex-direction: column; align-items: stretch; gap: 0; padding: 8px 16px 16px;
    display: none; box-shadow: var(--shadow-lg);
  }
  .nav-links.open { display: flex; }
  .nav-links a { padding: 12px 10px; font-size: 1rem; border-radius: 8px; }
  .nav-auth { flex-direction: column; align-items: stretch; gap: 4px; margin-top: 6px; }
  .nav-auth a { text-align: center; }

  /* ===== Hero ===== */
  .hero { padding: 36px 0 76px; }
  .hero h1 { font-size: 1.75rem; }
  .hero p { font-size: .95rem; }

  /* ===== Search ===== */
  .search-wrap { margin-top: -34px; margin-bottom: 28px; }
  .search-box { padding: 10px; gap: 6px; }
  .search-box .field { min-width: 100%; }
  .search-box .btn { width: 100%; margin-top: 4px; }

  /* ===== Chips ===== */
  .chips { gap: 8px; margin-bottom: 18px; overflow-x: auto; flex-wrap: nowrap; padding-bottom: 4px; }
  .chip { white-space: nowrap; padding: 8px 14px; font-size: .84rem; }

  /* ===== Section head ===== */
  .section-head { margin: 24px 0 14px; }
  .section-head h2 { font-size: 1.35rem; }

  /* ===== Cards ===== */
  .listing-grid { grid-template-columns: repeat(2, 1fr); gap: 12px; }
  .card-media { aspect-ratio: 1 / 1; height: auto; }
  .card-body { padding: 10px; gap: 4px; }
  .card-body h3 { font-size: .86rem; }
  .card-price { font-size: 1rem; }
  .card-foot { font-size: .7rem; }
  .card-seller { font-size: .7rem; }

  /* ===== Detail ===== */
  .detail-wrap { grid-template-columns: 1fr; gap: 20px; }
  .detail-main h1 { font-size: 1.5rem; }
  .gallery-main { height: 260px; }
  .gallery-thumbs img { width: 60px; height: 60px; }
  .big-price { font-size: 2rem; }
  .price-box { padding: 18px; }
  .bid-form { flex-direction: column; }
  .bid-form input { min-width: 100%; }
  .bid-form .btn { width: 100%; }

  /* ===== Auth ===== */
  .auth-card { margin: 20px auto; padding: 22px; border-radius: 14px; }
  .auth-card h1 { font-size: 1.4rem; }

  /* ===== Dashboard ===== */
  .cards { grid-template-columns: 1fr 1fr; gap: 10px; }
  .stat-card { padding: 14px; }
  .stat-card .big { font-size: 1.3rem; }
  .dash-wallet { display: flex; overflow-x: auto; scroll-snap-type: x mandatory; gap: 12px; margin: 20px 0 22px; padding-bottom: 6px; scrollbar-width: none; }
  .dash-wallet::-webkit-scrollbar { display: none; }
  .dash-wallet-card { flex: 0 0 82%; scroll-snap-align: start; min-width: 0; }

  /* ===== Chat ===== */
  .chat-layout { grid-template-columns: 1fr; }
  .chat-shell { grid-template-columns: 1fr; }

  /* ===== Footer ===== */
  .footer { padding: 32px 0 0; }
  .footer-grid { grid-template-columns: 1fr 1fr; gap: 24px; }
  .footer-bottom { flex-direction: column; text-align: center; }
}

@media (max-width: 380px) {
  .listing-grid { grid-template-columns: 1fr; }
  .cards { grid-template-columns: 1fr; }
}

/* ===== Owner panel ===== */
.owner-wrap { padding-top: 40px; padding-bottom: 64px; }
.owner-header { margin-bottom: 26px; }
.owner-header .eyebrow {
  display: inline-block; font-size: .74rem; font-weight: 700; letter-spacing: .14em; text-transform: uppercase;
  color: var(--copper); background: var(--copper-soft); padding: 5px 12px; border-radius: 20px; margin-bottom: 12px;
}
.owner-header h1 { font-family: var(--font-display); font-weight: 600; font-size: 2.1rem; color: var(--navy-900); margin-bottom: 6px; }
.owner-header .muted { font-size: .98rem; }

.owner-tabs {
  display: flex; gap: 4px; flex-wrap: wrap; margin-bottom: 22px;
  border-bottom: 1px solid var(--border);
}
.owner-tab {
  background: none; border: none; padding: 12px 18px; font-size: .92rem; font-weight: 700;
  color: var(--muted); cursor: pointer; border-bottom: 2px solid transparent; font-family: var(--font-body);
  transition: color .15s, border-color .15s;
}
.owner-tab:hover { color: var(--ink); }
.owner-tab.active { color: var(--copper); border-bottom-color: var(--copper); }

.owner-panel { display: none; }
.owner-panel.active { display: block; animation: ownerFade .2s ease; }
@keyframes ownerFade { from { opacity: 0; transform: translateY(4px); } to { opacity: 1; transform: none; } }

.panel-head { display: flex; align-items: baseline; gap: 10px; margin-bottom: 16px; }
.panel-head h2 { font-family: var(--font-display); font-weight: 600; font-size: 1.35rem; color: var(--navy-900); }
.panel-head .muted { font-size: .85rem; }

.owner-row {
  display: flex; align-items: center; gap: 14px; flex-wrap: wrap;
  background: var(--surface); border: 1px solid var(--border); border-radius: 12px;
  padding: 14px 16px; margin-bottom: 10px; box-shadow: var(--shadow-sm);
}
.owner-row .main { flex: 1; min-width: 200px; }
.owner-row .title { font-weight: 700; color: var(--ink); font-size: .98rem; }
.owner-row .title .muted { font-weight: 500; }
.owner-row .meta { font-size: .84rem; color: var(--muted); margin-top: 2px; }
.owner-row .actions { display: flex; gap: 6px; flex-shrink: 0; flex-wrap: wrap; align-items: center; }
.owner-row .wd-proof-input { font-size: .78rem; color: var(--muted); }
.owner-row .wd-proof-input::file-selector-button {
  padding: 5px 10px; border: 1px solid var(--border); border-radius: 8px;
  background: var(--surface); color: var(--ink); cursor: pointer; font-size: .78rem;
}
.owner-row .wd-note-input {
  padding: 6px 10px; border: 1px solid var(--border); border-radius: 8px;
  font-size: .82rem; min-width: 130px; margin: 0;
}

.owner-empty {
  color: var(--muted); text-align: center; padding: 28px;
  border: 1px dashed var(--border-strong); border-radius: 12px; background: var(--surface);
}

.banner-form { margin-bottom: 16px; }
.form-row { display: flex; gap: 8px; flex-wrap: wrap; }
.form-row input { flex: 1; min-width: 140px; margin: 0; }
.form-row .btn { flex-shrink: 0; }
.commission-box {
  background: var(--surface); border: 1px solid var(--border); border-radius: 12px;
  padding: 20px; box-shadow: var(--shadow-sm); max-width: 520px;
}
.commission-box label { display: block; margin-bottom: 4px; }

.status-pill.ok { background: var(--green-soft); color: var(--green); }
.status-pill.warn { background: #fff4e0; color: #b26a00; }
.status-pill.bad { background: var(--red-soft); color: var(--red); }
.status-pill.info { background: #e7f0fb; color: var(--blue); border: 1.5px solid var(--blue); }
.status-pill.neutral { background: #eef1f5; color: #55606e; }

/* Button loading spinner */
.spinner { display: inline-block; width: 14px; height: 14px; border: 2px solid rgba(255,255,255,.5); border-top-color: #fff; border-radius: 50%; vertical-align: -2px; animation: spin .7s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }

/* ===== Owner: tabel user + search + pagination ===== */
.user-toolbar { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; margin-bottom: 14px; }
.user-search { flex: 1; min-width: 240px; margin: 0 !important; }
.user-perpage { display: flex; align-items: center; gap: 8px; font-size: .85rem; color: var(--muted); }
.user-perpage label { margin: 0; font-weight: 600; }
.perpage-select { width: auto; margin: 0 !important; padding: 8px 10px; font-size: .85rem; }

.user-table-wrap { overflow-x: auto; }
.user-table { width: 100%; border-collapse: collapse; font-size: .85rem; }
.user-table thead th {
  text-align: left; font-size: .7rem; font-weight: 700; letter-spacing: .05em; text-transform: uppercase;
  color: var(--muted); padding: 8px 12px; border-bottom: 1px solid var(--border); background: var(--bg);
  white-space: nowrap;
}
.user-table th.num, .user-table td.num { text-align: right; }
.user-table tbody td { padding: 8px 12px; border-bottom: 1px solid var(--border); vertical-align: middle; }
.user-table tbody tr:last-child td { border-bottom: none; }
.user-table tbody tr:hover { background: #fafbfc; }
.u-name { font-weight: 700; color: var(--ink); display: flex; align-items: center; gap: 6px; flex-wrap: wrap; }
.u-sub { font-size: .8rem; color: var(--muted); }
.cell-actions { display: flex; gap: 6px; flex-wrap: wrap; align-items: center; justify-content: flex-end; }
.cell-actions .wd-proof-input, .cell-actions .wd-note-input { font-size: .78rem; }
.cell-actions .wd-note-input { padding: 6px 10px; border: 1px solid var(--border); border-radius: 8px; min-width: 110px; margin: 0; }
.u-email { color: var(--ink-soft); font-size: .85rem; }
.u-date { font-size: .82rem; color: var(--muted); white-space: nowrap; }

/* Audit log (owner) */
.nowrap { white-space: nowrap; }
.ref-cell { font-size: .82rem; color: var(--ink-soft); max-width: 320px; }
.amt-plus { color: var(--green, #16a34a); font-weight: 600; }
.amt-minus { color: var(--red, #dc2626); font-weight: 600; }
.audit-log-table td { font-size: .85rem; }
.audit-table td { font-size: .88rem; }

.user-pagination { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; margin-top: 14px; }
.user-pagination .pager-btns { display: flex; align-items: center; gap: 8px; }

.btn-danger { background: var(--red); }
.btn-danger:hover { background: #b81c09; }
.modal-card textarea { width: 100%; margin: 8px 0 16px; min-height: 96px; resize: vertical; }
.modal-actions { display: flex; gap: 8px; justify-content: flex-end; }

@media (max-width: 560px) {
  .owner-row { flex-direction: column; align-items: flex-start; }
  .owner-row .actions { width: 100%; }
  .owner-tabs { overflow-x: auto; flex-wrap: nowrap; }
  .owner-tab { white-space: nowrap; }
}

.tx-fee-breakdown {
  display: flex;
  flex-direction: column;
  gap: 2px;
  font-size: .78rem;
  color: var(--ink-soft, #3c4655);
  margin-top: 6px;
  padding: 8px 10px;
  background: #f7f9fc;
  border-radius: 8px;
}
.tx-fee-breakdown .tx-total {
  font-weight: 700;
  color: var(--navy, #0c2236);
  border-top: 1px dashed #e0e3e8;
  padding-top: 4px;
  margin-top: 2px;
}

/* Pilih metode pembayaran (modal bayar) */
.pay-method-grid {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin: 14px 0;
}
.pay-method-card {
  display: flex;
  flex-direction: column;
  gap: 4px;
  text-align: left;
  padding: 14px 16px;
  border: 1.5px solid var(--border, #e2e6ea);
  border-radius: 12px;
  background: #fff;
  cursor: pointer;
  transition: border-color .15s, box-shadow .15s;
}
.pay-method-card:hover {
  border-color: var(--copper, #e06020);
  box-shadow: 0 2px 8px rgba(0,0,0,.06);
}
.pay-method-card.selected {
  border-color: var(--copper, #e06020);
  background: #fff8f4;
}
.pay-method-name {
  font-weight: 700;
  font-size: 1rem;
  color: var(--navy, #0c2236);
}
.pay-method-desc {
  font-size: .82rem;
  color: var(--ink-soft, #3c4655);
}
.bca-info {
  background: #f7f9fc;
  border: 1px dashed var(--border, #e2e6ea);
  border-radius: 10px;
  padding: 12px 14px;
  margin: 8px 0;
  font-size: .9rem;
}

/* Nominal + tombol aksi modal bayar */
.pay-amount-line {
  background: #f0f6ff;
  border: 1px solid #d6e4f7;
  border-radius: 10px;
  padding: 10px 14px;
  margin-bottom: 12px;
  font-size: .9rem;
  color: var(--navy, #0c2236);
}
.pay-amount-line strong {
  color: var(--copper, #e06020);
  font-size: 1.05rem;
}
.bca-actions {
  display: flex;
  gap: 10px;
  margin-top: 12px;
}
.bca-actions .btn {
  flex: 1;
}

/* Baris aksi verifikasi/tolak BCA */
.tx-actions-row {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
}
