/* Hudhud Saba — visual identity */
:root {
  --navy: #0A2540; --navy-2: #12386b; --gold: #EAB308; --gold-2: #FACC15; --gold-dark: #a16207;
  --ink: #14213d; --muted: #5b6785; --cream: #fff9ee; --line: #e6dcc4; --card: rgba(255,255,255,.94);
  --radius: 16px; --shadow: 0 4px 18px rgba(11,42,91,.14);
}
* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body { margin: 0; font-family: Tahoma, "Segoe UI", Arial, sans-serif; color: var(--ink); background: #dbe9f7; min-height: 100vh; }
body.bg-banner { background: #cfe3f7 url(../assets/banner.jpg) center / cover fixed; }
body.bg-banner::after { content: ""; position: fixed; inset: 0; background: linear-gradient(180deg, rgba(255,255,255,.12), rgba(255,249,238,.55)); z-index: -1; }
html[dir="ltr"] body { font-family: "Segoe UI", Tahoma, Arial, sans-serif; }
a { color: inherit; cursor: pointer; text-decoration: none; }
button, input, select, textarea { font: inherit; }
button { cursor: pointer; }
img { max-width: 100%; }

/* top bar + navigation */
.topbar { background: var(--navy); color: #fff; display: flex; gap: 14px; align-items: center; padding: 8px 20px; font-size: 13px; flex-wrap: wrap; }
.topbar .grow, .grow { flex: 1; }
.topbar a { opacity: .9; } .topbar a:hover { opacity: 1; }
.topbar .pillbtn { background: transparent; color: #fff; border: 1px solid rgba(255,255,255,.55); border-radius: 20px; padding: 6px 16px; }
.sitenav { display: flex; align-items: center; gap: 22px; padding: 10px 24px; flex-wrap: wrap; background: rgba(255,255,255,.82); backdrop-filter: blur(6px); position: sticky; top: 0; z-index: 20; }
.brand { display: flex; align-items: center; gap: 10px; font-weight: 800; font-size: 21px; color: var(--navy); }
.brand img { width: 48px; height: 48px; border-radius: 50%; object-fit: cover; box-shadow: 0 0 0 2px var(--gold); }
.brand small { display: block; font-size: 11px; color: var(--muted); font-weight: 400; }
.sitenav .links { display: flex; gap: 20px; flex: 1; flex-wrap: wrap; }
.sitenav .links a { font-weight: 600; color: var(--navy); padding: 6px 0; border-bottom: 3px solid transparent; }
.sitenav .links a.on, .sitenav .links a:hover { border-color: var(--gold); }

/* buttons + form controls */
.btn { background: linear-gradient(var(--gold-2), var(--gold)); border: 0; color: #3a2a00; font-weight: 700; border-radius: 24px; padding: 11px 24px; transition: transform .15s, box-shadow .15s; }
.btn:hover { transform: translateY(-1px); box-shadow: 0 6px 14px rgba(224,165,38,.4); }
.btn.navy { background: var(--navy); color: #fff; } .btn.ghost { background: #fff; color: var(--navy); border: 1px solid var(--navy); }
.btn.sm { padding: 5px 13px; font-size: 13px; } .btn.block { width: 100%; }
input, select, textarea { width: 100%; padding: 11px 13px; border: 1px solid #d5d9e3; border-radius: 10px; margin: 5px 0; background: #fff; color: var(--ink); }
input:focus, select:focus, textarea:focus { outline: 2px solid var(--gold); border-color: var(--gold); }
label.check { display: flex; gap: 8px; align-items: center; font-size: 13px; } label.check input { width: auto; margin: 0; }

/* layout helpers */
.wrap { max-width: 1180px; margin: 0 auto; padding: 18px; }
.grid { display: grid; gap: 14px; }
.g5 { grid-template-columns: repeat(auto-fit, minmax(190px, 1fr)); } .g3 { grid-template-columns: repeat(auto-fit, minmax(270px, 1fr)); } .g2 { grid-template-columns: repeat(auto-fit, minmax(330px, 1fr)); }
.card { background: var(--card); border-radius: var(--radius); padding: 16px; box-shadow: var(--shadow); }
.card.navy { background: linear-gradient(135deg, var(--navy), var(--navy-2)); color: #fff; }
.row { display: flex; gap: 10px; align-items: center; } .wrapflex { flex-wrap: wrap; } .muted { color: var(--muted); font-size: 13px; }
.center { text-align: center; }

/* home hero */
.hero { min-height: 470px; display: flex; align-items: center; padding: 30px 5%;
  background: linear-gradient(to left, rgba(255,255,255,.9) 0, rgba(255,255,255,.62) 36%, rgba(255,255,255,0) 62%), url(../assets/banner.jpg) left center / cover; }
.hero .copy { max-width: 560px; margin-inline-start: 0; }
.hero h1 { font-size: 68px; margin: 0; color: var(--navy); line-height: 1.1; }
.hero h2 { color: var(--gold-dark); font-size: 25px; margin: 8px 0; }
.pill { display: inline-block; background: var(--navy); color: #fff; padding: 10px 26px; border-radius: 12px; font-weight: 700; font-size: 20px; margin: 8px 0; }
.feature { text-align: center; } .feature .ico { font-size: 34px; } .feature b { display: block; color: var(--navy); margin: 5px 0; } .feature span { font-size: 13px; color: var(--muted); }
.stats { display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; text-align: center; } .stats b { font-size: 22px; color: var(--navy); display: block; } .stats span { font-size: 12px; color: var(--muted); }
.site-footer { background: var(--navy); color: #fff; margin-top: 26px; padding: 22px; text-align: center; }
.site-footer .slogan { color: var(--gold-2); font-size: 20px; font-weight: 700; margin-bottom: 12px; }
.pay { display: inline-flex; gap: 8px; } .pay span { background: #fff; color: var(--navy); font-weight: 800; border-radius: 8px; padding: 6px 12px; font-size: 13px; }

/* auth pages */
.auth { display: grid; grid-template-columns: 1.1fr 1fr; gap: 24px; align-items: center; min-height: 560px; }
.auth h1 { font-size: 44px; color: var(--navy); margin: 0; }
.auth ul { list-style: none; padding: 0; font-weight: 700; } .auth li::before { content: "✔  "; color: var(--gold); }
.card .head { text-align: center; background: var(--navy); color: #fff; padding: 11px; border-radius: 12px; font-weight: 700; margin: 0 0 12px; }
.tabs { display: flex; gap: 6px; margin-bottom: 12px; } .tabs button { flex: 1; padding: 12px 6px; border-radius: 12px; border: 1px solid var(--line); background: #fff; font-weight: 700; color: var(--navy); }
.tabs button.on { background: var(--gold); border-color: var(--gold); }
.steps { display: flex; gap: 10px; flex-wrap: wrap; align-items: center; background: rgba(255,255,255,.9); border-radius: var(--radius); padding: 14px; }
.steps .st { flex: 1; min-width: 150px; text-align: center; font-size: 14px; font-weight: 700; color: var(--navy); } .steps .st i { display: block; font-style: normal; font-size: 26px; }

/* dashboards */
.dash-top { background: var(--navy); color: #fff; display: flex; align-items: center; gap: 14px; padding: 8px 20px; flex-wrap: wrap; }
.dash-top .brand { color: #fff; font-size: 18px; } .dash-top .brand img { width: 38px; height: 38px; }
.dash-top button { background: transparent; color: #fff; border: 1px solid rgba(255,255,255,.5); border-radius: 18px; padding: 5px 14px; }
.layout { display: grid; grid-template-columns: 210px 1fr; gap: 14px; } .menu { background: var(--navy); border-radius: var(--radius); padding: 10px; display: flex; flex-direction: column; gap: 4px; align-self: start; }
.menu a { color: #fff; padding: 10px 12px; border-radius: 10px; } .menu a.on { background: var(--gold); color: #3a2a00; font-weight: 700; }
.avatar { width: 42px; height: 42px; border-radius: 50%; object-fit: cover; flex: none; background: var(--navy); } .avatar.lg { width: 92px; height: 92px; }
.badge { padding: 3px 10px; border-radius: 12px; font-size: 12px; font-weight: 700; background: #eef; color: var(--navy); white-space: nowrap; }
.b-paid { background: #fff1cc; } .b-shipped { background: #dbeaff; } .b-delivered { background: #ffe3c4; } .b-completed { background: #c9f0d5; } .b-disputed, .b-refunded { background: #ffd9d9; }
table { width: 100%; border-collapse: collapse; font-size: 14px; } td, th { padding: 9px 8px; border-bottom: 1px solid var(--line); text-align: start; } .scroll { overflow: auto; }
.prod { text-align: center; cursor: pointer; transition: transform .15s; } .prod:hover { transform: translateY(-3px); } .prod .em { font-size: 52px; } .price { color: var(--gold-dark); font-weight: 800; font-size: 18px; } .stars { color: var(--gold); }
.chat { display: grid; grid-template-columns: 260px 1fr; gap: 12px; height: 540px; } .chat .list { overflow: auto; background: #fff; border-radius: 12px; }
.chat .list a { display: flex; gap: 8px; align-items: center; padding: 10px; border-bottom: 1px solid var(--line); } .chat .list a.on { background: #eaf2ff; }
.msgs { flex: 1; overflow: auto; display: flex; flex-direction: column; gap: 6px; background: #fff; border-radius: 12px; padding: 10px; }
.msg { max-width: 72%; padding: 8px 12px; border-radius: 14px; background: #eee; } .msg.me { background: #cfe3ff; align-self: flex-start; }
.timeline { border-inline-start: 3px solid var(--gold); padding-inline-start: 14px; margin: 8px 0; } #map { height: 300px; border-radius: 12px; margin-top: 10px; }
#toast { position: fixed; bottom: 22px; left: 50%; transform: translateX(-50%); background: var(--navy); color: #fff; padding: 10px 22px; border-radius: 22px; display: none; z-index: 99; max-width: 90vw; }
@media (max-width: 780px) {
  .auth, .layout, .chat { grid-template-columns: 1fr; } .chat { height: auto; } .hero h1 { font-size: 44px; } .stats { grid-template-columns: repeat(2, 1fr); }
  .menu { flex-direction: row; overflow-x: auto; } .menu a { white-space: nowrap; }
  .hero { background: linear-gradient(rgba(255,255,255,.82), rgba(255,255,255,.7)), url(../assets/banner.jpg) center / cover; }
}

/* images, comments, verification */
.pimg { width: 100%; height: 150px; object-fit: cover; border-radius: 12px; display: block; margin-bottom: 8px; }
.gallery { display: flex; gap: 8px; flex-wrap: wrap; margin: 8px 0; justify-content: center; } .gallery img { width: 78px; height: 78px; object-fit: cover; border-radius: 10px; border: 2px solid var(--line); cursor: pointer; }
.gallery .gi { position: relative; } .gallery .gi button { position: absolute; top: -6px; inset-inline-end: -6px; border: 0; border-radius: 50%; width: 22px; height: 22px; background: #c0392b; color: #fff; line-height: 1; }
.bigimg { width: 100%; max-height: 340px; object-fit: contain; border-radius: 12px; background: #fff; }
.notice { background: #fff4d6; border: 1px solid var(--gold); margin-bottom: 12px; padding: 10px 14px; }
.comment { border-bottom: 1px solid var(--line); padding: 8px 0; } .comment.reply { margin-inline-start: 34px; background: rgba(224,165,38,.08); border-radius: 10px; padding: 8px; }
.comment a { margin-inline-end: 12px; color: var(--navy); font-weight: 600; }
.overlay { position: fixed; inset: 0; background: rgba(0,0,0,.75); z-index: 98; display: flex; align-items: center; justify-content: center; padding: 20px; } .overlay img { max-width: 100%; max-height: 90vh; border-radius: 10px; }
td input { margin: 0; min-width: 70px; }

/* compact app bar + ⋮ menu + dashboard tab strip */
.appbar { display: flex; align-items: center; gap: 8px; padding: 8px 14px; background: rgba(255,255,255,.92); backdrop-filter: blur(8px); position: sticky; top: 0; z-index: 30; box-shadow: 0 2px 10px rgba(11,42,91,.12); }
.appbar .brand { font-size: 18px; } .appbar .brand img { width: 40px; height: 40px; } .appbar .brand small { display: none; }
@media (min-width: 700px) { .appbar .brand small { display: block; } }
.iconbtn { position: relative; width: 40px; height: 40px; border-radius: 50%; border: 0; background: #eef3fb; color: var(--navy); font-size: 19px; display: inline-flex; align-items: center; justify-content: center; }
.iconbtn:hover { background: #dfe9f8; } .iconbtn .dot { position: absolute; top: -3px; inset-inline-start: -3px; background: #d93025; color: #fff; font-size: 11px; min-width: 18px; height: 18px; border-radius: 9px; display: flex; align-items: center; justify-content: center; padding: 0 4px; }
.iconbtn .dot[hidden] { display: none; }
.chip { background: var(--navy); color: #fff; border-radius: 20px; padding: 7px 13px; font-weight: 700; font-size: 14px; white-space: nowrap; }
.menuwrap { position: relative; }
.dropmenu { display: none; position: absolute; top: 46px; inset-inline-end: 0; min-width: 210px; background: #fff; border-radius: 14px; box-shadow: 0 10px 30px rgba(11,42,91,.25); padding: 6px; z-index: 40; }
.dropmenu.open { display: block; } .dropmenu a { display: block; padding: 10px 12px; border-radius: 9px; color: var(--navy); font-weight: 600; } .dropmenu a:hover { background: #f1f5fc; } .dropmenu hr { border: 0; border-top: 1px solid var(--line); margin: 4px 0; }
.tabstrip { display: flex; gap: 8px; overflow-x: auto; padding: 4px 2px 12px; scrollbar-width: none; } .tabstrip::-webkit-scrollbar { display: none; }
.tab { white-space: nowrap; background: rgba(255,255,255,.95); color: var(--navy); padding: 9px 16px; border-radius: 20px; font-weight: 700; font-size: 14px; box-shadow: var(--shadow); } .tab.on { background: var(--gold); color: #3a2a00; }
.gbtn { display: flex; justify-content: center; margin: 10px 0 4px; } .or { text-align: center; color: var(--muted); font-size: 13px; margin: 8px 0; }
.roles { display: flex; gap: 8px; flex-wrap: wrap; justify-content: center; }

/* user chip, bottom navigation, modal, danger button */
.userchip { display: flex; align-items: center; gap: 9px; min-width: 0; font-weight: 800; color: var(--navy); } .userchip .avatar { width: 40px; height: 40px; box-shadow: 0 0 0 2px var(--gold); }
.userchip span { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 38vw; }
.btn.danger { background: #c62828; color: #fff; } .btn.danger:hover { box-shadow: 0 6px 14px rgba(198,40,40,.4); } .btn.danger[disabled] { opacity: .45; cursor: not-allowed; transform: none; box-shadow: none; }
.bottomnav { display: none; }
@media (max-width: 780px) {
  body.hasnav { padding-bottom: calc(74px + env(safe-area-inset-bottom, 0px)); }
  .bottomnav { display: flex; position: fixed; inset-inline: 0; bottom: 0; z-index: 60; background: var(--navy); padding: 6px 4px calc(6px + env(safe-area-inset-bottom, 0px)); box-shadow: 0 -6px 20px rgba(10,37,64,.35); border-top: 1px solid rgba(255,255,255,.08); }
  .bottomnav a { flex: 1; display: flex; flex-direction: column; align-items: center; gap: 3px; color: #9fb3d1; font-size: 11px; font-weight: 700; padding: 6px 0; border-radius: 12px; }
  .bottomnav a.on { color: var(--gold-2); background: rgba(250,204,21,.1); } .bottomnav svg { width: 24px; height: 24px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
}
.modal-back, .sheet-back { position: fixed; inset: 0; background: rgba(5,15,30,.65); z-index: 120; display: flex; align-items: center; justify-content: center; padding: 16px; }
.modal { background: #fff; border-radius: 18px; padding: 20px; max-width: 440px; width: 100%; box-shadow: 0 20px 50px rgba(0,0,0,.4); } .modal h3 { margin-top: 0; color: #c62828; }

/* marketplace */
.mk { max-width: 1240px; margin: 0 auto; padding: 12px 12px 28px; }
.mkhead { display: flex; gap: 10px; align-items: center; position: sticky; top: 58px; z-index: 20; background: rgba(255,255,255,.96); padding: 10px; border-radius: 16px; box-shadow: var(--shadow); }
.searchbox { flex: 1; display: flex; align-items: center; gap: 8px; background: #f1f5fb; border-radius: 24px; padding: 0 14px; border: 2px solid transparent; } .searchbox:focus-within { border-color: var(--gold); background: #fff; }
.searchbox input { border: 0; background: transparent; margin: 0; padding: 12px 0; outline: none; } .searchbox .x { border: 0; background: #d5dbe6; border-radius: 50%; width: 22px; height: 22px; line-height: 1; }
.cartbtn { background: var(--gold); color: #3a2a00; flex: none; } .cartbtn .dot { background: var(--navy); }
.chips { display: flex; gap: 8px; overflow-x: auto; padding: 10px 2px 2px; scrollbar-width: none; } .chips::-webkit-scrollbar { display: none; }
.chip2 { white-space: nowrap; border: 1px solid #d5dbe6; background: #fff; color: var(--navy); border-radius: 20px; padding: 8px 15px; font-weight: 700; font-size: 13px; } .chip2.on { background: var(--navy); color: #fff; border-color: var(--navy); }
.sorts .chip2.on { background: var(--gold); color: #3a2a00; border-color: var(--gold); }
.trustbar { display: flex; gap: 14px; overflow-x: auto; margin: 12px 0; padding: 10px 14px; background: linear-gradient(135deg, var(--navy), var(--navy-2)); color: #fff; border-radius: 14px; font-size: 13px; font-weight: 700; scrollbar-width: none; } .trustbar span { white-space: nowrap; }
.pgrid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 10px; } @media (min-width: 700px) { .pgrid { grid-template-columns: repeat(auto-fill, minmax(215px, 1fr)); gap: 16px; } }
.pcard { background: #fff; border-radius: 16px; overflow: hidden; display: flex; flex-direction: column; box-shadow: 0 2px 10px rgba(10,37,64,.1); transition: transform .15s, box-shadow .15s; } .pcard:hover { transform: translateY(-3px); box-shadow: 0 10px 26px rgba(10,37,64,.2); }
.pimgwrap { position: relative; display: block; aspect-ratio: 1 / 1; background: #eef2f8; } .pimgwrap img { width: 100%; height: 100%; object-fit: cover; display: block; } .noimg { height: 100%; display: flex; align-items: center; justify-content: center; font-size: 60px; }
.tag { position: absolute; top: 8px; inset-inline-start: 8px; font-size: 11px; font-weight: 800; border-radius: 8px; padding: 3px 8px; } .tag.low { background: #fff4d6; color: #92400e; } .tag.out { background: #c62828; color: #fff; }
.pbody { padding: 10px 12px 12px; display: flex; flex-direction: column; gap: 4px; flex: 1; }
.ptitle { font-weight: 700; color: var(--ink); line-height: 1.35; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; min-height: 2.7em; } .ptitle:hover { color: var(--navy); text-decoration: underline; }
.prate { font-size: 13px; } .pprice { color: var(--navy); font-weight: 800; } .pprice .cur { font-size: 14px; vertical-align: top; } .pprice .int { font-size: 24px; } .pprice sup { font-size: 13px; }
.pstore { font-size: 12px; color: var(--muted); } .vbadge { background: #e6f6ec; color: #17803d; border-radius: 8px; padding: 1px 6px; font-weight: 700; font-size: 11px; white-space: nowrap; }
.trust { font-size: 11px; color: #17803d; font-weight: 700; } .pbtns { display: flex; gap: 6px; margin-top: auto; padding-top: 6px; } .pbtns .btn { flex: 1; padding: 8px 4px; font-size: 12px; }
.skel { background: linear-gradient(90deg, #e8edf5 25%, #f4f7fb 50%, #e8edf5 75%); background-size: 200% 100%; animation: sh 1.2s infinite; border-radius: 16px; aspect-ratio: 3 / 4; } @keyframes sh { to { background-position: -200% 0; } }
.empty { grid-column: 1 / -1; text-align: center; padding: 40px 10px; color: var(--muted); } .empty .big { font-size: 54px; }
.fab { position: fixed; inset-inline-start: 16px; bottom: 90px; z-index: 50; background: var(--gold); color: #3a2a00; font-weight: 800; border-radius: 28px; padding: 14px 20px; box-shadow: 0 8px 22px rgba(10,37,64,.35); } @media (min-width: 781px) { .fab { bottom: 24px; } }
.pdp { display: grid; grid-template-columns: 1fr; gap: 16px; } @media (min-width: 900px) { .pdp { grid-template-columns: 1.15fr 1fr; align-items: start; } }
.buybox { position: sticky; top: 70px; } .bigimg { width: 100%; max-height: 460px; object-fit: contain; background: #fff; border-radius: 14px; }
.pdp .price-lg { color: var(--navy); font-size: 34px; font-weight: 800; } .guarantee { background: #eefaf2; border: 1px solid #bfe6cc; border-radius: 12px; padding: 10px 12px; font-size: 13px; color: #14532d; margin: 10px 0; }
.sheet { background: #fff; width: 100%; max-width: 560px; max-height: 88vh; overflow: auto; border-radius: 22px 22px 0 0; padding: 16px; align-self: flex-end; } .sheet-back { align-items: flex-end; padding: 0; justify-content: center; }
.crow { display: flex; gap: 10px; align-items: center; padding: 8px 0; border-bottom: 1px solid var(--line); } .crow img, .crow .noimg { width: 56px; height: 56px; border-radius: 10px; object-fit: cover; font-size: 28px; flex: none; background: #eef2f8; }
.qty { display: inline-flex; align-items: center; gap: 6px; } .qty button { width: 28px; height: 28px; border-radius: 50%; border: 1px solid #cdd5e2; background: #fff; font-weight: 800; }
