/* ==========================================================================
   Discount Liberia 1.0 — design system
   White surfaces · royal blue · Liberian red · water-motion transitions
   ========================================================================== */

:root {
  --navy: #0b1d5c;
  --navy-2: #0f2a7a;
  --blue: #1f4fe0;
  --blue-600: #2563eb;
  --blue-500: #3b6cf6;
  --blue-100: #e7eeff;
  --blue-50: #f3f6ff;
  --red: #e5202b;
  --red-600: #d0141f;
  --red-50: #fff0f0;
  --amber: #f59e0b;
  --amber-50: #fff7e6;
  --green: #16a34a;
  --green-50: #e9f8ef;
  --violet: #8b5cf6;
  --ink: #0f1a3d;
  --ink-2: #33405f;
  --muted: #6b7591;
  --line: #e6eaf3;
  --line-2: #eef1f7;
  --surface: #ffffff;
  --bg: #f6f8fc;
  --star: #f5b301;
  --r-sm: 10px;
  --r: 14px;
  --r-lg: 20px;
  --r-xl: 26px;
  --sh-1: 0 1px 2px rgba(15, 26, 61, .05), 0 2px 8px rgba(15, 26, 61, .05);
  --sh-2: 0 6px 24px rgba(15, 33, 92, .09);
  --sh-3: 0 18px 50px rgba(15, 33, 92, .16);
  --ease: cubic-bezier(.22, .9, .32, 1);
  --ease-water: cubic-bezier(.65, 0, .35, 1);
  --font: "Plus Jakarta Sans", ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif;
  --tabbar-h: 64px;
  color-scheme: light;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body { margin: 0; font-family: var(--font); color: var(--ink); background: var(--bg); font-size: 15px; line-height: 1.5; -webkit-font-smoothing: antialiased; text-rendering: optimizeLegibility; overflow-x: hidden; }
img, svg { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; background: none; border: 0; padding: 0; cursor: pointer; }
input, select, textarea { font: inherit; color: inherit; }
h1, h2, h3, h4 { margin: 0; line-height: 1.2; letter-spacing: -.01em; }
p { margin: 0; }
ul { margin: 0; padding: 0; list-style: none; }
.ic { width: 1.25em; height: 1.25em; flex: none; }
[hidden] { display: none !important; }
.sr { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
:focus-visible { outline: 3px solid rgba(31, 79, 224, .45); outline-offset: 2px; border-radius: 8px; }
.wrap { width: 100%; max-width: 1280px; margin: 0 auto; padding: 0 16px; }
.muted { color: var(--muted); }
.red { color: var(--red); }
.blue { color: var(--blue); }
.green { color: var(--green); }
.nowrap { white-space: nowrap; }
.strike { text-decoration: line-through; color: var(--muted); font-weight: 500; }
.row { display: flex; align-items: center; gap: 10px; }
.between { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.stack > * + * { margin-top: 12px; }
.grow { flex: 1; min-width: 0; }
@media (max-width: 1023.98px) { .hide-m { display: none !important; } }
@media (min-width: 1024px) { .hide-d { display: none !important; } .wrap { padding: 0 24px; } }

/* ---------------------------------------------------------------- buttons */
.btn { --bg: var(--blue); --fg: #fff; position: relative; overflow: hidden; isolation: isolate; display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 44px; padding: 0 20px; border-radius: 12px; background: var(--bg); color: var(--fg); font-weight: 700; font-size: 15px; transition: transform .25s var(--ease), box-shadow .25s var(--ease), background .2s; white-space: nowrap; -webkit-tap-highlight-color: transparent; }
.btn:hover { box-shadow: 0 8px 22px color-mix(in srgb, var(--bg) 35%, transparent); transform: translateY(-1px); }
.btn:active { transform: translateY(0) scale(.98); }
.btn-red { --bg: var(--red); }
.btn-blue { --bg: var(--blue); }
.btn-navy { --bg: var(--navy); }
.btn-green { --bg: var(--green); }
.btn-soft { --bg: var(--blue-50); --fg: var(--blue); }
.btn-outline { --bg: #fff; --fg: var(--blue); box-shadow: inset 0 0 0 1.5px var(--blue); }
.btn-outline:hover { box-shadow: inset 0 0 0 1.5px var(--blue), 0 8px 22px rgba(31, 79, 224, .15); }
.btn-outline-red { --bg: #fff; --fg: var(--red); box-shadow: inset 0 0 0 1.5px var(--red); }
.btn-ghost { --bg: transparent; --fg: var(--ink-2); }
.btn-ghost:hover { box-shadow: none; background: var(--blue-50); }
.btn-lg { min-height: 54px; font-size: 16.5px; border-radius: 14px; padding: 0 26px; }
.btn-sm { min-height: 34px; padding: 0 12px; font-size: 13px; border-radius: 9px; }
.btn-pill { border-radius: 999px; }
.btn-block { width: 100%; }
.btn[disabled] { opacity: .55; pointer-events: none; }
.icon-btn { position: relative; display: inline-grid; place-items: center; width: 42px; height: 42px; border-radius: 12px; color: var(--ink); transition: background .2s; -webkit-tap-highlight-color: transparent; }
.icon-btn:hover { background: var(--blue-50); }
.icon-btn .ic { width: 24px; height: 24px; }
.bubble { position: absolute; top: 2px; right: 0; min-width: 18px; height: 18px; padding: 0 5px; border-radius: 999px; background: var(--red); color: #fff; font-size: 11px; font-weight: 800; display: grid; place-items: center; border: 2px solid #fff; line-height: 1; }
.bubble.bump { animation: bump .6s var(--ease); }
@keyframes bump { 0% { transform: scale(1); } 30% { transform: scale(1.45); } 60% { transform: scale(.9); } 100% { transform: scale(1); } }

/* ---------------------------------------------------------------- water ripple (any [data-ripple], .btn, .chip) */
.rpl { position: absolute; border-radius: 50%; pointer-events: none; transform: translate(-50%, -50%) scale(0); width: var(--d); height: var(--d); background: radial-gradient(circle, rgba(255,255,255,.45) 0 35%, rgba(255,255,255,.18) 36% 60%, transparent 61%); animation: rpl .75s var(--ease) forwards; z-index: -1; }
.rpl.dark { background: radial-gradient(circle, rgba(31,79,224,.16) 0 35%, rgba(31,79,224,.08) 36% 60%, transparent 61%); }
.rpl::after { content: ""; position: absolute; inset: 0; border-radius: 50%; border: 2px solid rgba(255,255,255,.5); animation: rplring .9s var(--ease) .08s forwards; opacity: .9; }
.rpl.dark::after { border-color: rgba(31,79,224,.25); }
@keyframes rpl { to { transform: translate(-50%, -50%) scale(1); opacity: 0; } }
@keyframes rplring { from { transform: scale(.35); } to { transform: scale(1.15); opacity: 0; } }
[data-ripple] { position: relative; overflow: hidden; isolation: isolate; }

/* ---------------------------------------------------------------- tide page transition */
#dl-tide { position: fixed; inset: 0; z-index: 9999; pointer-events: none; visibility: hidden; transform: translate3d(0, calc(100% + 120px), 0); will-change: transform; }
#dl-tide .tide-body { position: absolute; inset: 0; background: radial-gradient(120% 70% at 50% 110%, #2c63ff 0%, #1d47d6 45%, #0f2a7a 100%); }
#dl-tide .tide-waves { position: absolute; left: 0; right: 0; bottom: 100%; height: 120px; overflow: hidden; }
#dl-tide .tide-waves svg { position: absolute; bottom: -1px; left: 0; width: 200%; height: 100%; }
#dl-tide .w1 { fill: #2c63ff; animation: drift 2.2s linear infinite; }
#dl-tide .w2 { fill: rgba(229, 32, 43, .55); animation: drift 3.1s linear infinite reverse; opacity: .8; }
#dl-tide .w3 { fill: rgba(255, 255, 255, .35); animation: drift 1.7s linear infinite; }
@keyframes drift { from { transform: translateX(0); } to { transform: translateX(-50%); } }
#dl-tide .tide-mark { position: absolute; left: 50%; top: 50%; width: 76px; height: 76px; margin: -38px 0 0 -38px; opacity: 0; transform: scale(.8); transition: opacity .3s .25s, transform .5s var(--ease) .25s; filter: drop-shadow(0 10px 24px rgba(0,0,0,.25)); }
#dl-tide .bub { position: absolute; bottom: -20px; width: 10px; height: 10px; border-radius: 50%; background: rgba(255,255,255,.35); animation: bub 2.4s ease-in infinite; }
@keyframes bub { from { transform: translateY(0) scale(.6); opacity: 0; } 20% { opacity: 1; } to { transform: translateY(-110vh) scale(1.2); opacity: 0; } }
html.tide-rise #dl-tide, html.tide-in #dl-tide, html.tide-out #dl-tide { visibility: visible; }
html.tide-rise #dl-tide { transform: translate3d(0, 0, 0); transition: transform .48s var(--ease-water); pointer-events: auto; }
html.tide-rise #dl-tide .tide-mark { opacity: 1; transform: scale(1); }
html.tide-in #dl-tide { transform: translate3d(0, 0, 0); transition: none; animation: tidefail .6s 2.5s forwards; }
@keyframes tidefail { to { transform: translate3d(0, calc(100% + 120px), 0); } }
html.tide-in #dl-tide .tide-mark { opacity: 1; transform: none; transition: none; }
html.tide-out #dl-tide { transform: translate3d(0, calc(100% + 120px), 0); transition: transform .7s var(--ease-water); }
html.tide-out #dl-tide .tide-mark { opacity: 0; transition: opacity .2s; }
html.tide-out .main > * { animation: surface .8s var(--ease) both; }
@keyframes surface { from { opacity: .4; transform: translateY(18px); } to { opacity: 1; transform: none; } }

/* ---------------------------------------------------------------- toast */
.toasts { position: fixed; left: 50%; bottom: calc(var(--tabbar-h) + 18px + env(safe-area-inset-bottom)); transform: translateX(-50%); z-index: 9000; display: grid; gap: 8px; width: min(92vw, 420px); pointer-events: none; }
@media (min-width: 1024px) { .toasts { bottom: 28px; } }
.toast { pointer-events: auto; display: flex; align-items: center; gap: 10px; padding: 12px 16px; border-radius: 16px; background: var(--navy); color: #fff; font-weight: 600; font-size: 14px; box-shadow: var(--sh-3); animation: drop .6s var(--ease) both; }
.toast .ic { color: #7dd3fc; }
.toast.out { animation: dropout .45s var(--ease) forwards; }
@keyframes drop { 0% { opacity: 0; transform: translateY(24px) scale(.7, 1.2); border-radius: 50%; } 55% { transform: translateY(-4px) scale(1.04, .96); border-radius: 18px; } 100% { opacity: 1; transform: none; } }
@keyframes dropout { to { opacity: 0; transform: translateY(16px) scale(.92); } }

/* flying droplet (add to cart) */
.droplet { position: fixed; z-index: 9500; width: 22px; height: 22px; border-radius: 50% 50% 50% 0; background: radial-gradient(circle at 35% 35%, #8fb2ff, var(--blue) 60%, var(--navy)); box-shadow: 0 4px 14px rgba(31,79,224,.45); pointer-events: none; transform: rotate(-45deg); }
.splash-ring { position: fixed; z-index: 9500; width: 44px; height: 44px; margin: -22px 0 0 -22px; border-radius: 50%; border: 3px solid var(--blue); pointer-events: none; animation: ringout .7s var(--ease) forwards; }
@keyframes ringout { from { transform: scale(.2); opacity: 1; } to { transform: scale(1.6); opacity: 0; } }

/* ---------------------------------------------------------------- logo */
.logo { display: inline-flex; align-items: center; gap: 8px; line-height: 1; }
.logo-mark { width: 46px; height: 40px; flex: none; }
.logo-text { display: grid; gap: 1px; }
.logo-text b { font-weight: 900; letter-spacing: -.01em; font-size: 17px; color: var(--navy); }
.logo-text b + b { color: var(--red); }
.logo-text small { font-size: 6.5px; letter-spacing: .14em; font-weight: 700; color: var(--navy); margin-top: 2px; text-transform: uppercase; }
.logo.lg .logo-mark { width: 120px; height: 104px; }
.logo.lg { flex-direction: column; gap: 10px; text-align: center; }
.logo.lg .logo-text b { font-size: 40px; letter-spacing: -.02em; }
.logo.lg .logo-text small { font-size: 12px; letter-spacing: .3em; margin-top: 6px; }

/* ---------------------------------------------------------------- desktop header */
.hd { position: sticky; top: 0; z-index: 50; background: #fff; box-shadow: 0 1px 0 var(--line); }
.hd-top { display: flex; align-items: center; gap: 22px; height: 76px; }
.hd-search { flex: 1; display: flex; max-width: 640px; height: 46px; border-radius: 12px; border: 1.5px solid var(--line); background: #fff; transition: border-color .2s, box-shadow .2s; overflow: hidden; }
.hd-search:focus-within { border-color: var(--blue); box-shadow: 0 0 0 4px rgba(31,79,224,.1); }
.hd-search input { flex: 1; border: 0; outline: 0; padding: 0 16px; background: transparent; min-width: 0; }
.hd-search button { width: 56px; background: var(--red); color: #fff; display: grid; place-items: center; }
.hd-actions { display: flex; align-items: center; gap: 6px; margin-left: auto; }
.hd-act { position: relative; display: grid; justify-items: center; gap: 2px; padding: 6px 10px; border-radius: 12px; font-size: 12px; font-weight: 600; color: var(--ink-2); transition: background .2s; }
.hd-act:hover { background: var(--blue-50); }
.hd-act .ic { width: 24px; height: 24px; color: var(--ink); }
.hd-act .bubble { top: 0; right: 6px; }
.catbar { background: linear-gradient(90deg, var(--navy) 0%, var(--navy-2) 60%, #1638a8 100%); color: #fff; }
.catbar .wrap { display: flex; align-items: center; gap: 4px; height: 46px; overflow-x: auto; scrollbar-width: none; }
.catbar a { padding: 7px 14px; border-radius: 10px; font-size: 14px; font-weight: 600; white-space: nowrap; opacity: .92; transition: background .2s, opacity .2s; }
.catbar a:hover, .catbar a.on { background: rgba(255,255,255,.12); opacity: 1; }
.catbar a.all { background: var(--red); display: inline-flex; gap: 8px; align-items: center; opacity: 1; }

/* ---------------------------------------------------------------- mobile header */
.mh { position: sticky; top: 0; z-index: 50; background: rgba(255,255,255,.94); backdrop-filter: saturate(1.6) blur(14px); -webkit-backdrop-filter: saturate(1.6) blur(14px); padding-top: env(safe-area-inset-top); }
.mh-row { display: flex; align-items: center; gap: 6px; height: 58px; }
.mh-row .logo { margin-right: auto; }
.mh-title { flex: 1; font-size: 19px; font-weight: 800; color: var(--navy); text-align: center; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.mh-title > small { display: block; font-size: 12.5px; font-weight: 500; color: var(--muted); }
.mh-search { padding-top: 2px; padding-bottom: 12px; }
.m-search { display: flex; align-items: center; height: 48px; border-radius: 14px; background: var(--bg); border: 1.5px solid var(--line); overflow: hidden; transition: border-color .2s, box-shadow .2s; }
.m-search:focus-within { border-color: var(--blue); box-shadow: 0 0 0 4px rgba(31,79,224,.1); background: #fff; }
.m-search .ic { margin-left: 14px; color: var(--muted); }
.m-search input { flex: 1; border: 0; outline: 0; background: transparent; padding: 0 10px; min-width: 0; }
.m-search button { width: 52px; height: 100%; background: var(--red); color: #fff; display: grid; place-items: center; border-radius: 12px; }
.mh.shadow { box-shadow: 0 1px 0 var(--line); }

/* ---------------------------------------------------------------- bottom tab bar */
.tabbar { position: fixed; z-index: 60; left: 0; right: 0; bottom: 0; height: calc(var(--tabbar-h) + env(safe-area-inset-bottom)); padding-bottom: env(safe-area-inset-bottom); background: rgba(255,255,255,.96); backdrop-filter: blur(16px); -webkit-backdrop-filter: blur(16px); border-top: 1px solid var(--line); display: grid; grid-template-columns: repeat(5, 1fr); }
.tabbar a { position: relative; z-index: 1; display: grid; place-items: center; align-content: center; gap: 2px; font-size: 11.5px; font-weight: 600; color: #7a849e; -webkit-tap-highlight-color: transparent; transition: color .25s; }
.tabbar a .ic { width: 24px; height: 24px; transition: transform .45s var(--ease); }
.tabbar a.on { color: var(--red); }
.tabbar a.on .ic { transform: translateY(-2px) scale(1.08); }
.tabbar .blob { position: absolute; z-index: 0; top: 8px; height: 40px; width: 52px; border-radius: 20px; background: var(--red-50); transition: none; pointer-events: none; }
.tabbar a .tb-badge { position: absolute; top: 6px; left: calc(50% + 6px); min-width: 16px; height: 16px; border-radius: 999px; background: var(--red); color: #fff; font-size: 10px; display: grid; place-items: center; padding: 0 4px; border: 2px solid #fff; }
body.has-tabbar .main { padding-bottom: calc(var(--tabbar-h) + 24px + env(safe-area-inset-bottom)); }
@media (min-width: 1024px) { .tabbar, .mh { display: none; } body.has-tabbar .main { padding-bottom: 0; } }
@media (max-width: 1023.98px) { .hd, .ft { display: none; } }

/* ---------------------------------------------------------------- drawer */
.drawer { position: fixed; inset: 0; z-index: 80; visibility: hidden; }
.drawer .scrim { position: absolute; inset: 0; background: rgba(11, 29, 92, .35); opacity: 0; transition: opacity .35s; }
.drawer .panel { position: absolute; top: 0; bottom: 0; left: 0; width: min(86vw, 340px); background: #fff; transform: translateX(-102%); transition: transform .45s var(--ease); display: flex; flex-direction: column; padding: calc(16px + env(safe-area-inset-top)) 16px 16px; overflow-y: auto; border-radius: 0 24px 24px 0; }
.drawer.open { visibility: visible; }
.drawer.open .scrim { opacity: 1; }
.drawer.open .panel { transform: none; }
.drawer .dl-links a { display: flex; align-items: center; gap: 12px; padding: 12px 10px; border-radius: 12px; font-weight: 600; }
.drawer .dl-links a:hover { background: var(--blue-50); }
.drawer .dl-links .cat-dot { width: 34px; height: 34px; border-radius: 10px; display: grid; place-items: center; color: #fff; }
.drawer h4 { font-size: 12px; text-transform: uppercase; letter-spacing: .1em; color: var(--muted); margin: 18px 10px 6px; }

/* ---------------------------------------------------------------- generic surfaces */
.main { min-height: 60vh; }
.card { background: #fff; border-radius: var(--r-lg); box-shadow: var(--sh-1); border: 1px solid var(--line-2); }
.card-p { padding: 16px; }
@media (min-width: 768px) { .card-p { padding: 20px; } }
.section { padding: 18px 0; }
@media (min-width: 1024px) { .section { padding: 26px 0; } }
.sec-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 14px; }
.sec-head h2 { font-size: 19px; font-weight: 800; color: var(--navy); display: flex; align-items: center; gap: 8px; }
@media (min-width: 1024px) { .sec-head h2 { font-size: 22px; } }
.sec-head a { color: var(--blue); font-weight: 700; font-size: 14px; display: inline-flex; align-items: center; gap: 4px; }
.page-title { font-size: 24px; font-weight: 800; color: var(--navy); }
@media (min-width: 1024px) { .page-title { font-size: 28px; } }
.crumbs { display: flex; flex-wrap: wrap; gap: 6px; font-size: 13px; color: var(--muted); padding: 14px 0 4px; }
.crumbs a:hover { color: var(--blue); }
.crumbs span::before { content: "›"; margin-right: 6px; }
.demo-flag { position: fixed; z-index: 70; left: 10px; bottom: calc(var(--tabbar-h) + 10px + env(safe-area-inset-bottom)); background: var(--amber); color: #3b2500; font-size: 10px; font-weight: 800; letter-spacing: .12em; padding: 4px 10px; border-radius: 999px; text-transform: uppercase; box-shadow: var(--sh-2); pointer-events: none; opacity: .92; animation: demofade .6s 6s forwards; }
@keyframes demofade { to { opacity: 0; transform: translateY(8px); } }
@media (min-width: 1024px) { .demo-flag { bottom: 14px; left: 14px; } }
.demo-tag { display: inline-flex; align-items: center; gap: 4px; padding: 2px 8px; border-radius: 999px; background: var(--amber-50); color: #9a5b00; font-size: 11px; font-weight: 700; }
.empty { display: grid; justify-items: center; text-align: center; gap: 10px; padding: 44px 16px; color: var(--muted); }
.empty .ic { width: 54px; height: 54px; color: var(--blue); background: var(--blue-50); border-radius: 50%; padding: 13px; }
.empty h3 { color: var(--ink); font-size: 18px; }

/* chips & segmented */
.chips { display: flex; gap: 8px; overflow-x: auto; scrollbar-width: none; padding: 2px 0; -webkit-overflow-scrolling: touch; }
.chips::-webkit-scrollbar { display: none; }
.chip { position: relative; overflow: hidden; isolation: isolate; flex: none; display: inline-flex; align-items: center; gap: 6px; height: 36px; padding: 0 14px; border-radius: 12px; background: #fff; border: 1.5px solid var(--line); font-size: 13.5px; font-weight: 600; color: var(--ink-2); transition: all .25s var(--ease); white-space: nowrap; }
.chip:hover { border-color: #c8d3ee; }
.chip.on { background: var(--blue); border-color: var(--blue); color: #fff; box-shadow: 0 6px 16px rgba(31,79,224,.25); }
.chip.red.on { background: var(--red); border-color: var(--red); box-shadow: 0 6px 16px rgba(229,32,43,.25); }
.seg { position: relative; display: inline-flex; gap: 4px; padding: 4px; border-radius: 14px; background: var(--blue-50); }
.seg a, .seg button { position: relative; z-index: 1; padding: 8px 14px; border-radius: 10px; font-weight: 700; font-size: 13.5px; color: var(--ink-2); transition: color .3s; white-space: nowrap; }
.seg a.on, .seg button.on { color: #fff; }
.seg .seg-pill { position: absolute; z-index: 0; top: 4px; bottom: 4px; border-radius: 10px; background: var(--blue); box-shadow: 0 6px 16px rgba(31,79,224,.3); transition: left .5s var(--ease), width .5s var(--ease); }

/* badges */
.badge { display: inline-flex; align-items: center; gap: 5px; height: 26px; padding: 0 10px; border-radius: 8px; font-size: 12.5px; font-weight: 700; white-space: nowrap; }
.b-blue, .st-processing { background: var(--blue-100); color: var(--blue); }
.b-navy, .st-shipped { background: #e4e9ff; color: #2a3fb6; }
.b-violet, .st-out_for_delivery { background: #efe8ff; color: #6d3bd8; }
.b-green, .st-delivered, .st-active, .st-verified, .st-confirmed, .st-resolved { background: var(--green-50); color: var(--green); }
.b-amber, .st-placed, .st-pending, .st-in_progress, .st-draft { background: var(--amber-50); color: #b26a00; }
.b-gray, .st-cancelled, .st-refunded { background: #eef0f4; color: #5b6478; }
.b-red, .st-rejected, .st-suspended, .st-failed, .st-blocked, .st-open { background: var(--red-50); color: var(--red); }
.tag-off { position: absolute; top: 10px; left: 10px; z-index: 2; background: var(--red); color: #fff; font-weight: 800; font-size: 12px; padding: 3px 8px; border-radius: 8px; box-shadow: 0 4px 10px rgba(229,32,43,.3); }

/* stars */
.stars { display: inline-flex; gap: 1px; color: var(--star); }
.stars svg { width: 13px; height: 13px; }
.stars .off { color: #dfe3ec; }
.rating { display: inline-flex; align-items: center; gap: 4px; font-size: 12.5px; color: var(--muted); }

/* ---------------------------------------------------------------- product card */
.pgrid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
@media (min-width: 640px) { .pgrid { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
@media (min-width: 1024px) { .pgrid { grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 16px; } .pgrid.g5 { grid-template-columns: repeat(5, minmax(0, 1fr)); } }
.prow { display: grid; grid-auto-flow: column; grid-auto-columns: minmax(150px, 42%); gap: 12px; overflow-x: auto; scroll-snap-type: x mandatory; scrollbar-width: none; padding: 4px 2px 10px; margin: 0 -2px; }
.prow::-webkit-scrollbar { display: none; }
.prow > * { scroll-snap-align: start; }
@media (min-width: 640px) { .prow { grid-auto-columns: minmax(180px, 28%); } }
@media (min-width: 1024px) { .prow { grid-auto-columns: calc((100% - 64px) / 5); gap: 16px; } }
.pcard { position: relative; display: flex; flex-direction: column; background: #fff; border-radius: 18px; border: 1px solid var(--line-2); box-shadow: var(--sh-1); overflow: hidden; transition: transform .45s var(--ease), box-shadow .45s var(--ease); isolation: isolate; }
.pcard:hover { transform: translateY(-4px); box-shadow: var(--sh-2); }
.pcard .pimg { position: relative; aspect-ratio: 1 / 1; background: radial-gradient(90% 80% at 50% 35%, #fff 0%, #f3f6fd 100%); display: grid; place-items: center; overflow: hidden; }
.pcard .pimg img, .pcard .pimg .art { width: 78%; height: 78%; object-fit: contain; transition: transform .7s var(--ease); }
.pcard:hover .pimg img, .pcard:hover .pimg .art { transform: scale(1.06) rotate(-1.5deg); }
.pcard .pbody { padding: 10px 12px 12px; display: grid; gap: 4px; flex: 1; }
.pcard .pname { font-size: 13.5px; font-weight: 600; line-height: 1.3; color: var(--ink); display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; min-height: 2.6em; }
.pcard .pseller { font-size: 11.5px; color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.pcard .price { font-size: 16px; font-weight: 800; color: var(--red); letter-spacing: -.01em; }
.pcard .was { font-size: 12.5px; }
.pcard .pfoot { display: flex; align-items: center; justify-content: space-between; gap: 6px; margin-top: 2px; }
.pcard .add { position: relative; overflow: hidden; width: 34px; height: 34px; border-radius: 10px; display: grid; place-items: center; color: var(--red); background: var(--red-50); transition: background .25s, color .25s, transform .3s var(--ease); flex: none; }
.pcard .add:hover { background: var(--red); color: #fff; transform: scale(1.06); }
.pcard .add .ic { width: 19px; height: 19px; }
.heart { position: absolute; top: 8px; right: 8px; z-index: 2; width: 34px; height: 34px; border-radius: 50%; display: grid; place-items: center; background: rgba(255,255,255,.9); color: var(--blue); box-shadow: 0 2px 8px rgba(15,26,61,.08); transition: transform .3s var(--ease); }
.heart .ic { width: 19px; height: 19px; }
.heart.on { color: var(--red); }
.heart.on .ic { fill: currentColor; }
.heart.pop { animation: heartpop .55s var(--ease); }
@keyframes heartpop { 0% { transform: scale(1); } 35% { transform: scale(1.35); } 70% { transform: scale(.92); } 100% { transform: scale(1); } }
.origin { display: inline-flex; align-items: center; gap: 4px; font-size: 11px; font-weight: 700; color: var(--blue); }
.origin.local { color: var(--green); }
.origin .ic { width: 13px; height: 13px; }
.sold { font-size: 11.5px; color: var(--muted); }

/* list variant (flash deals list) */
.plist { display: grid; gap: 12px; }
.pline { display: grid; grid-template-columns: 112px 1fr; gap: 12px; padding: 10px; background: #fff; border-radius: 18px; border: 1px solid var(--line-2); box-shadow: var(--sh-1); position: relative; }
.pline .pimg { position: relative; border-radius: 14px; background: #f3f6fd; display: grid; place-items: center; aspect-ratio: 1; overflow: hidden; }
.pline .pimg .art, .pline .pimg img { width: 82%; height: 82%; object-fit: contain; }
.pline .tag-off { top: 6px; left: 6px; }
.pline .pname { font-weight: 700; font-size: 14.5px; padding-right: 32px; }
.pline .heart { top: 10px; right: 10px; background: transparent; box-shadow: none; }
.pline .price { font-weight: 800; color: var(--red); font-size: 17px; }

/* ---------------------------------------------------------------- category tiles */
.cats { display: grid; grid-template-columns: repeat(5, 1fr); gap: 14px 6px; }
@media (min-width: 1024px) { .cats { grid-template-columns: repeat(9, 1fr); gap: 16px; } }
.cat { display: grid; justify-items: center; gap: 7px; text-align: center; font-size: 12px; font-weight: 600; color: var(--ink-2); line-height: 1.25; -webkit-tap-highlight-color: transparent; }
.cat .ci { width: 54px; height: 54px; border-radius: 16px; display: grid; place-items: center; color: #fff; background: var(--c, var(--blue)); box-shadow: 0 8px 18px color-mix(in srgb, var(--c, var(--blue)) 30%, transparent); transition: transform .45s var(--ease), border-radius .45s var(--ease); }
.cat .ci .ic { width: 27px; height: 27px; }
.cat:hover .ci { transform: translateY(-3px); border-radius: 22px 12px 22px 12px; }
.cat.art .ci { width: 92px; height: 92px; border-radius: 20px; background: #f3f6fd; box-shadow: none; }
.cat.art .ci .art { width: 76px; height: 76px; }
.catlist { display: grid; gap: 10px; }
@media (min-width: 768px) { .catlist { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1024px) { .catlist { grid-template-columns: repeat(3, 1fr); } }
.catrow { display: grid; grid-template-columns: 72px 1fr auto; gap: 14px; align-items: center; padding: 10px 14px 10px 10px; background: #fff; border-radius: 18px; border: 1px solid var(--line-2); box-shadow: var(--sh-1); transition: transform .4s var(--ease), box-shadow .4s; }
.catrow:hover { transform: translateY(-2px); box-shadow: var(--sh-2); }
.catrow .thumb { width: 72px; height: 72px; border-radius: 14px; background: #f3f6fd; display: grid; place-items: center; }
.catrow .thumb .art { width: 60px; height: 60px; }
.catrow b { font-weight: 700; color: var(--navy); }
.catrow .ic { color: var(--muted); }

/* ---------------------------------------------------------------- hero */
.hero { position: relative; border-radius: 22px; overflow: hidden; color: #fff; background: linear-gradient(135deg, #0f2a7a 0%, #1d47d6 55%, #2c63ff 100%); min-height: 176px; box-shadow: 0 16px 36px rgba(29,71,214,.28); isolation: isolate; }
@media (min-width: 1024px) { .hero { min-height: 340px; border-radius: 24px; } }
.slides { position: relative; min-height: inherit; }
.slide { position: absolute; inset: 0; display: grid; grid-template-columns: 54% 46%; align-items: center; clip-path: polygon(-12% 0, -8% 10%, -12% 20%, -8% 30%, -12% 40%, -8% 50%, -12% 60%, -8% 70%, -12% 80%, -8% 90%, -12% 100%, 0 100%, 0 0); transition: clip-path 1.05s var(--ease-water); }
.slide.on { position: relative; clip-path: polygon(112% 0, 108% 10%, 112% 20%, 108% 30%, 112% 40%, 108% 50%, 112% 60%, 108% 70%, 112% 80%, 108% 90%, 112% 100%, 0 100%, 0 0); z-index: 2; min-height: inherit; }
.slide.leaving { z-index: 1; clip-path: polygon(112% 0, 108% 10%, 112% 20%, 108% 30%, 112% 40%, 108% 50%, 112% 60%, 108% 70%, 112% 80%, 108% 90%, 112% 100%, 0 100%, 0 0); position: absolute; transition: none; }
.slide .copy { padding: 18px 0 18px 18px; position: relative; z-index: 2; }
@media (min-width: 1024px) { .slide .copy { padding: 40px 0 40px 48px; } }
.hero h2 { font-weight: 900; font-size: 26px; line-height: 1; letter-spacing: -.02em; text-transform: uppercase; }
.hero h2 em { display: inline-block; font-style: normal; background: var(--red); padding: 2px 8px 1px; border-radius: 8px; margin-top: 4px; box-shadow: 0 6px 16px rgba(229,32,43,.4); }
@media (min-width: 1024px) { .hero h2 { font-size: 54px; } .hero h2 em { padding: 4px 14px 2px; border-radius: 12px; } }
.hero p { margin-top: 10px; font-size: 12px; font-weight: 600; opacity: .95; line-height: 1.35; }
@media (min-width: 1024px) { .hero p { font-size: 18px; margin-top: 16px; } }
.hero .btn { margin-top: 12px; min-height: 34px; padding: 0 14px; font-size: 12.5px; border-radius: 999px; }
@media (min-width: 1024px) { .hero .btn { min-height: 48px; padding: 0 24px; font-size: 16px; margin-top: 22px; } }
.hero .art-wrap { position: relative; height: 100%; min-height: inherit; }
.hero .art-wrap svg { position: absolute; inset: 0; width: 100%; height: 100%; }
.dots { position: absolute; z-index: 5; bottom: 10px; left: 18px; display: flex; gap: 5px; }
.dots button { width: 7px; height: 7px; border-radius: 99px; background: rgba(255,255,255,.5); transition: width .5s var(--ease), background .3s; }
.dots button.on { width: 22px; background: #fff; }
@media (min-width: 1024px) { .dots { left: 48px; bottom: 22px; } }

.promos { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
@media (min-width: 1024px) { .promos { gap: 18px; } }
.promo { position: relative; overflow: hidden; border-radius: 18px; color: #fff; min-height: 128px; padding: 14px; display: flex; flex-direction: column; justify-content: space-between; isolation: isolate; box-shadow: var(--sh-2); }
@media (min-width: 1024px) { .promo { min-height: 190px; padding: 28px; border-radius: 22px; } }
.promo.red { background: linear-gradient(135deg, #ff3b3b, #c8101b); }
.promo.blue { background: linear-gradient(135deg, #2c63ff, #0f2a7a); }
.promo h3 { font-size: 15px; font-weight: 900; text-transform: uppercase; line-height: 1.05; max-width: 70%; }
.promo p { font-size: 11px; font-weight: 600; opacity: .95; max-width: 62%; margin-top: 4px; }
@media (min-width: 1024px) { .promo h3 { font-size: 30px; } .promo p { font-size: 15px; } }
.promo .btn { align-self: flex-start; margin-top: 10px; min-height: 30px; font-size: 11.5px; padding: 0 12px; border-radius: 999px; --bg: #fff; --fg: var(--red); }
.promo.blue .btn { --fg: var(--blue); }
@media (min-width: 1024px) { .promo .btn { min-height: 44px; font-size: 15px; padding: 0 20px; } }
.promo .promo-art { position: absolute; right: -6px; bottom: -6px; width: 52%; height: 100%; z-index: -1; }

/* trust strip */
.trust { display: grid; grid-template-columns: repeat(4, 1fr); gap: 6px; padding: 12px 6px; background: #fff; border-radius: 18px; border: 1px solid var(--line-2); }
.trust div { display: flex; flex-direction: column; align-items: center; text-align: center; gap: 4px; font-size: 11px; font-weight: 700; color: var(--navy); line-height: 1.2; }
.trust .ic { width: 26px; height: 26px; color: var(--blue); }
.trust small { display: none; font-weight: 500; color: var(--muted); font-size: 12px; }
@media (min-width: 1024px) { .trust { padding: 18px 12px; } .trust div { flex-direction: row; text-align: left; justify-content: center; font-size: 14px; gap: 12px; } .trust .ic { width: 34px; height: 34px; } .trust small { display: block; } }

/* countdown */
.cd { display: inline-flex; gap: 5px; }
.cd span { min-width: 30px; padding: 3px 4px; border-radius: 7px; background: var(--red); color: #fff; font-weight: 800; font-size: 14px; text-align: center; line-height: 1.1; }
.cd span small { display: block; font-size: 8.5px; font-weight: 600; opacity: .9; }
.cd.lg span { min-width: 48px; padding: 6px; border-radius: 10px; font-size: 22px; background: rgba(255,255,255,.18); backdrop-filter: blur(6px); }

/* ---------------------------------------------------------------- listing page */
.listing { display: grid; gap: 18px; }
@media (min-width: 1024px) { .listing { grid-template-columns: 250px 1fr; gap: 26px; } }
.filters { background: #fff; border-radius: 18px; border: 1px solid var(--line-2); padding: 16px; align-self: start; position: sticky; top: 140px; }
.filters h4 { font-size: 15px; font-weight: 800; color: var(--navy); margin: 14px 0 8px; display: flex; justify-content: space-between; }
.filters h4:first-child { margin-top: 0; }
.filters .opt { display: flex; align-items: center; gap: 9px; padding: 5px 0; font-size: 14px; color: var(--ink-2); cursor: pointer; }
.filters .opt input { accent-color: var(--blue); width: 17px; height: 17px; }
.filters .sub a { display: block; padding: 7px 10px; border-radius: 10px; font-size: 14px; color: var(--ink-2); }
.filters .sub a.on, .filters .sub a:hover { background: var(--blue-50); color: var(--blue); font-weight: 700; }
.range-row { display: flex; gap: 8px; align-items: center; }
.range-row input { width: 100%; height: 38px; border-radius: 10px; border: 1.5px solid var(--line); padding: 0 10px; }
.toolbar { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.toolbar .sel { height: 38px; border-radius: 11px; border: 1.5px solid var(--line); padding: 0 12px; background: #fff; font-weight: 600; font-size: 13.5px; }
.cat-banner { position: relative; overflow: hidden; border-radius: 20px; background: linear-gradient(120deg, #0f2a7a, #1d47d6 60%, #2c63ff); color: #fff; padding: 22px; min-height: 120px; display: flex; align-items: center; isolation: isolate; }
.cat-banner h1 { font-size: 24px; font-weight: 900; text-transform: uppercase; }
.cat-banner p { opacity: .9; font-weight: 600; margin-top: 4px; }
.cat-banner .art { position: absolute; right: 12px; bottom: -14px; width: 150px; height: 150px; z-index: -1; opacity: .95; }
@media (min-width: 1024px) { .cat-banner { min-height: 170px; padding: 34px; } .cat-banner h1 { font-size: 36px; } .cat-banner .art { width: 220px; height: 220px; right: 40px; } }
.pager { display: flex; justify-content: center; gap: 6px; margin: 26px 0 6px; flex-wrap: wrap; }
.pager a, .pager span { min-width: 38px; height: 38px; display: grid; place-items: center; border-radius: 11px; background: #fff; border: 1.5px solid var(--line); font-weight: 700; font-size: 14px; padding: 0 10px; }
.pager .on { background: var(--blue); color: #fff; border-color: var(--blue); }
.pager .off { opacity: .45; }

/* ---------------------------------------------------------------- product detail */
.pd { display: grid; gap: 18px; }
@media (min-width: 1024px) { .pd { grid-template-columns: minmax(0, 1.05fr) minmax(0, 1fr) 280px; gap: 28px; align-items: start; } }
.gallery .main-img { position: relative; aspect-ratio: 1 / 1; border-radius: 22px; background: radial-gradient(100% 90% at 50% 30%, #fff, #eef3fc); display: grid; place-items: center; overflow: hidden; border: 1px solid var(--line-2); }
.gallery .main-img > img, .gallery .main-img > .art { width: 76%; height: 76%; object-fit: contain; transition: opacity .35s, transform .6s var(--ease); }
.gallery .main-img.swap > img, .gallery .main-img.swap > .art { opacity: 0; transform: scale(.94); }
.gallery .thumbs { display: grid; grid-template-columns: repeat(4, 1fr); gap: 10px; margin-top: 10px; }
.gallery .thumbs button { aspect-ratio: 1; border-radius: 14px; background: #f3f6fd; border: 2px solid transparent; display: grid; place-items: center; overflow: hidden; transition: border-color .25s, transform .3s var(--ease); }
.gallery .thumbs button.on { border-color: var(--blue); }
.gallery .thumbs button .art, .gallery .thumbs button img { width: 80%; height: 80%; object-fit: contain; }
.gallery .thumbs .play { background: linear-gradient(135deg, #0f2a7a, #2c63ff); color: #fff; }
.pd h1 { font-size: 24px; font-weight: 800; color: var(--navy); }
@media (min-width: 1024px) { .pd h1 { font-size: 30px; } }
.pd .variant { font-size: 17px; color: var(--ink-2); font-weight: 500; }
.pd .bigprice { font-size: 30px; font-weight: 900; color: var(--red); letter-spacing: -.02em; }
.pd .meta { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; font-size: 14px; color: var(--muted); }
.feature-pills { display: flex; gap: 8px; flex-wrap: wrap; }
.feature-pills span { display: inline-flex; align-items: center; gap: 6px; height: 32px; padding: 0 10px; border-radius: 10px; border: 1.5px solid var(--line); font-size: 12.5px; font-weight: 600; color: var(--ink-2); }
.feature-pills .ic { width: 16px; height: 16px; color: var(--blue); }
.opt-group h4 { font-size: 16px; font-weight: 700; margin-bottom: 8px; }
.opt-btns { display: flex; gap: 8px; flex-wrap: wrap; }
.opt-btns label { cursor: pointer; }
.opt-btns input { position: absolute; opacity: 0; pointer-events: none; }
.opt-btns span { display: grid; place-items: center; min-width: 70px; height: 42px; padding: 0 14px; border-radius: 12px; border: 1.5px solid var(--line); font-weight: 700; transition: all .3s var(--ease); }
.opt-btns input:checked + span { background: var(--blue); color: #fff; border-color: var(--blue); box-shadow: 0 6px 16px rgba(31,79,224,.28); }
.swatches { display: flex; gap: 12px; }
.swatches label { cursor: pointer; }
.swatches input { position: absolute; opacity: 0; }
.swatches span { display: block; width: 40px; height: 40px; border-radius: 50%; background: var(--c); box-shadow: inset 0 0 0 1px rgba(0,0,0,.1); transition: transform .3s var(--ease), box-shadow .3s; }
.swatches input:checked + span { box-shadow: 0 0 0 3px #fff, 0 0 0 5px var(--blue); transform: scale(1.04); }
.qty { display: inline-flex; align-items: center; border: 1.5px solid var(--line); border-radius: 12px; height: 44px; overflow: hidden; background: #fff; }
.qty button { width: 42px; height: 100%; display: grid; place-items: center; color: var(--ink-2); }
.qty button:hover { background: var(--blue-50); }
.qty input, .qty output { width: 42px; text-align: center; border: 0; font-weight: 800; outline: 0; background: transparent; }
.qty.sm { height: 34px; border-radius: 10px; }
.qty.sm button { width: 32px; }
.qty.sm output { width: 26px; font-size: 14px; }
.stock-ok { color: var(--green); font-weight: 700; display: inline-flex; align-items: center; gap: 6px; font-size: 14px; }
.stock-ok::before { content: ""; width: 9px; height: 9px; border-radius: 50%; background: var(--green); box-shadow: 0 0 0 0 rgba(22,163,74,.5); animation: pulse 2s infinite; }
@keyframes pulse { 70% { box-shadow: 0 0 0 8px rgba(22,163,74,0); } 100% { box-shadow: 0 0 0 0 rgba(22,163,74,0); } }
.side-box { border: 1px solid var(--line-2); border-radius: 18px; padding: 16px; background: #fff; }
.side-box h4 { font-size: 15px; font-weight: 800; color: var(--navy); margin-bottom: 10px; }
.seller-line { display: flex; gap: 10px; align-items: center; }
.avatar { width: 44px; height: 44px; border-radius: 12px; display: grid; place-items: center; font-weight: 800; color: #fff; background: linear-gradient(135deg, var(--navy), var(--blue)); flex: none; font-size: 15px; }
.avatar.round { border-radius: 50%; }
.avatar.lg { width: 64px; height: 64px; font-size: 22px; }
.verified { color: var(--green); font-size: 12.5px; font-weight: 700; display: inline-flex; align-items: center; gap: 4px; }
.verified .ic { width: 15px; height: 15px; }
.info-line { display: flex; gap: 10px; align-items: flex-start; padding: 8px 0; }
.info-line .ic { color: var(--blue); width: 22px; height: 22px; margin-top: 2px; }
.info-line b { font-size: 14px; display: block; }
.info-line span { font-size: 13px; color: var(--muted); }
.hl-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; }
.hl { text-align: center; padding: 12px 6px; border: 1px solid var(--line-2); border-radius: 14px; background: #fff; }
.hl .ic { width: 28px; height: 28px; color: var(--navy); margin: 0 auto 6px; }
.hl b { display: block; font-size: 12.5px; }
.hl span { font-size: 11.5px; color: var(--muted); }
.ptabs { position: sticky; top: 58px; z-index: 20; background: rgba(246,248,252,.95); backdrop-filter: blur(10px); padding: 8px 0; }
@media (min-width: 1024px) { .ptabs { top: 122px; } }
.ptabs .seg { max-width: 100%; overflow-x: auto; scrollbar-width: none; }
.ptabs .seg::-webkit-scrollbar { display: none; }
.tabpanel { display: none; animation: panelin .55s var(--ease); }
.tabpanel.on { display: block; }
@keyframes panelin { from { opacity: 0; transform: translateY(10px); clip-path: inset(0 0 30% 0 round 18px); } to { opacity: 1; transform: none; clip-path: inset(0 0 0 0 round 18px); } }
.specs { width: 100%; border-collapse: collapse; font-size: 14px; }
.specs th, .specs td { text-align: left; padding: 11px 12px; border-bottom: 1px solid var(--line-2); vertical-align: top; }
.specs th { width: 38%; color: var(--muted); font-weight: 600; }
.review { padding: 14px 0; border-bottom: 1px solid var(--line-2); }
.review:last-child { border-bottom: 0; }
.rev-photos { display: flex; gap: 6px; margin-top: 8px; }
.rev-photos span { width: 54px; height: 54px; border-radius: 10px; background: linear-gradient(135deg, #cfd8ea, #8a95ad); }
.bars { display: grid; gap: 6px; }
.bars div { display: grid; grid-template-columns: 46px 1fr 36px; gap: 8px; align-items: center; font-size: 12.5px; color: var(--muted); }
.bars i { display: block; height: 8px; border-radius: 99px; background: var(--line); overflow: hidden; }
.bars i b { display: block; height: 100%; width: 0; background: var(--blue); border-radius: 99px; transition: width 1.2s var(--ease); }
.bars.in i b { width: var(--w); }
.buybar { position: sticky; bottom: calc(var(--tabbar-h) + env(safe-area-inset-bottom)); z-index: 30; display: grid; gap: 8px; padding: 10px 0; background: linear-gradient(to top, var(--bg) 70%, transparent); }
@media (min-width: 1024px) { .buybar { position: static; background: none; padding: 0; } }

/* ---------------------------------------------------------------- cart / checkout */
.two-col { display: grid; gap: 18px; }
@media (min-width: 1024px) { .two-col { grid-template-columns: minmax(0, 1fr) 380px; gap: 26px; align-items: start; } .two-col .sticky { position: sticky; top: 140px; } }
.cline { display: grid; grid-template-columns: auto 88px 1fr; gap: 12px; padding: 14px; align-items: start; border-bottom: 1px solid var(--line-2); position: relative; }
.cline:last-child { border-bottom: 0; }
.cline .thumb { width: 88px; height: 88px; border-radius: 14px; background: #f3f6fd; display: grid; place-items: center; overflow: hidden; }
.cline .thumb .art, .cline .thumb img { width: 80%; height: 80%; object-fit: contain; }
.cline .name { font-weight: 700; font-size: 15px; line-height: 1.3; }
.cline .price { color: var(--red); font-weight: 800; font-size: 16px; }
.cline.removing { animation: evaporate .5s var(--ease) forwards; }
@keyframes evaporate { to { opacity: 0; transform: translateX(-30px) scale(.96); filter: blur(4px); } }
.check { appearance: none; width: 22px; height: 22px; border-radius: 7px; border: 2px solid #c6cfe3; display: grid; place-items: center; cursor: pointer; transition: all .25s var(--ease); margin-top: 32px; background: #fff; }
.check:checked { background: var(--blue); border-color: var(--blue); }
.check:checked::after { content: ""; width: 6px; height: 11px; border: solid #fff; border-width: 0 2.5px 2.5px 0; transform: rotate(45deg) translate(-1px, -1px); animation: tick .3s var(--ease); }
@keyframes tick { from { transform: rotate(45deg) scale(0); } }
.sum-row { display: flex; justify-content: space-between; padding: 7px 0; font-size: 14.5px; color: var(--ink-2); }
.sum-row.total { border-top: 1px solid var(--line); margin-top: 6px; padding-top: 14px; font-size: 19px; font-weight: 800; color: var(--red); }
.promo-form { display: flex; gap: 8px; margin: 14px 0; }
.promo-form .field { flex: 1; }
.steps { display: flex; align-items: flex-start; justify-content: center; gap: 0; margin: 4px 0 18px; }
.steps .st { display: grid; justify-items: center; gap: 4px; font-size: 13px; font-weight: 600; color: var(--muted); width: 96px; position: relative; }
.steps .st i { width: 34px; height: 34px; border-radius: 50%; display: grid; place-items: center; font-style: normal; font-weight: 800; background: var(--blue-100); color: var(--blue); position: relative; z-index: 1; transition: background .4s, color .4s, transform .5s var(--ease); }
.steps .st.on i { background: var(--red); color: #fff; transform: scale(1.08); box-shadow: 0 0 0 6px rgba(229,32,43,.12); }
.steps .st.done i { background: var(--blue); color: #fff; }
.steps .st.on { color: var(--red); }
.steps .st:not(:last-child)::after { content: ""; position: absolute; top: 17px; left: calc(50% + 20px); width: calc(100% - 40px); height: 3px; border-radius: 3px; background: linear-gradient(90deg, var(--blue) var(--fill, 0%), var(--line) var(--fill, 0%)); transition: --fill .6s; }
.steps .st.done::after { --fill: 100%; }
.opt-card { position: relative; display: grid; grid-template-columns: 24px 44px 1fr auto; gap: 12px; align-items: center; padding: 14px; border-radius: 16px; border: 1.5px solid var(--line); background: #fff; cursor: pointer; transition: border-color .3s, box-shadow .3s, background .3s; overflow: hidden; isolation: isolate; }
.opt-card + .opt-card { margin-top: 10px; }
.opt-card input { position: absolute; opacity: 0; }
.opt-card .radio { width: 22px; height: 22px; border-radius: 50%; border: 2px solid #c6cfe3; display: grid; place-items: center; transition: border-color .3s; }
.opt-card .radio::after { content: ""; width: 10px; height: 10px; border-radius: 50%; background: var(--red); transform: scale(0); transition: transform .35s var(--ease); }
.opt-card:has(input:checked) { border-color: var(--red); background: #fffafa; box-shadow: 0 8px 20px rgba(229,32,43,.08); }
.opt-card:has(input:checked) .radio { border-color: var(--red); }
.opt-card:has(input:checked) .radio::after { transform: scale(1); }
.opt-card.blue:has(input:checked) { border-color: var(--blue); background: var(--blue-50); }
.opt-card.blue:has(input:checked) .radio { border-color: var(--blue); }
.opt-card.blue .radio::after { background: var(--blue); }
.opt-card .oi { width: 44px; height: 44px; border-radius: 12px; display: grid; place-items: center; background: var(--blue-50); color: var(--blue); }
.opt-card .oi .ic { width: 24px; height: 24px; }
.opt-card b { display: block; font-size: 15px; }
.opt-card small { color: var(--muted); font-size: 13px; }
.opt-card .fee { font-weight: 800; color: var(--blue); }
.opt-card .ribbon { position: absolute; top: 10px; right: 10px; background: var(--red); color: #fff; font-size: 10.5px; font-weight: 800; padding: 2px 8px; border-radius: 6px; }
.pm-logo { width: 44px; height: 30px; border-radius: 7px; display: grid; place-items: center; font-size: 10px; font-weight: 900; letter-spacing: -.02em; }
.pm-mtn { background: #ffcb05; color: #003a70; }
.pm-orange { background: #111; color: #ff7900; }
.pm-card { background: #1a1f71; color: #fff; }
.pm-bank { background: var(--navy); color: #fff; }
.pm-cod { background: var(--green-50); color: var(--green); }
.addr { display: grid; grid-template-columns: 24px 1fr auto; gap: 12px; padding: 14px; border-radius: 16px; border: 1.5px solid var(--line); background: #fff; cursor: pointer; transition: all .3s; position: relative; }
.addr + .addr { margin-top: 10px; }
.addr input { position: absolute; opacity: 0; }
.addr:has(input:checked) { border-color: var(--blue); background: var(--blue-50); }
.addr .radio { width: 22px; height: 22px; border-radius: 50%; border: 2px solid #c6cfe3; display: grid; place-items: center; margin-top: 2px; }
.addr .radio::after { content: ""; width: 10px; height: 10px; border-radius: 50%; background: var(--blue); transform: scale(0); transition: transform .35s var(--ease); }
.addr:has(input:checked) .radio { border-color: var(--blue); }
.addr:has(input:checked) .radio::after { transform: scale(1); }
.addr b { font-size: 15px; }
.addr p { font-size: 13.5px; color: var(--ink-2); line-height: 1.45; }
.def-dot { width: 22px; height: 22px; border-radius: 50%; border: 2px solid #c6cfe3; display: grid; place-items: center; margin-top: 2px; }
.def-dot::after { content: ""; width: 10px; height: 10px; border-radius: 50%; background: var(--blue); transform: scale(0); transition: transform .35s var(--ease); }
.def-dot.on { border-color: var(--blue); }
.def-dot.on::after { transform: scale(1); }
.co-panel { display: block; }
@media (max-width: 1023.98px) {
  .js .co-panel { display: none; }
  .js .co-panel.on { display: block; animation: wash .7s var(--ease-water) both; }
}
@keyframes wash { from { clip-path: circle(0% at var(--ox, 50%) var(--oy, 100%)); } to { clip-path: circle(150% at var(--ox, 50%) var(--oy, 100%)); } }
.note-box { display: flex; gap: 10px; padding: 12px 14px; border-radius: 14px; background: var(--blue-50); color: var(--ink-2); font-size: 13.5px; }
.note-box .ic { color: var(--blue); flex: none; margin-top: 2px; }
.note-box.amber { background: var(--amber-50); }
.note-box.amber .ic { color: var(--amber); }
.pay-logos { display: flex; align-items: center; justify-content: center; gap: 14px; flex-wrap: wrap; font-weight: 900; color: var(--muted); font-size: 12px; margin-top: 12px; }

/* forms */
.field { display: grid; gap: 6px; }
.field label { font-size: 13.5px; font-weight: 700; color: var(--ink-2); }
.input, .field input, .field select, .field textarea { width: 100%; min-height: 46px; border-radius: 12px; border: 1.5px solid var(--line); padding: 10px 14px; background: #fff; outline: 0; transition: border-color .2s, box-shadow .2s; }
.field textarea { min-height: 110px; resize: vertical; }
.input:focus, .field input:focus, .field select:focus, .field textarea:focus { border-color: var(--blue); box-shadow: 0 0 0 4px rgba(31,79,224,.1); }
.field .err, .err { color: var(--red); font-size: 12.5px; font-weight: 600; }
.form-grid { display: grid; gap: 12px; }
@media (min-width: 640px) { .form-grid.two { grid-template-columns: 1fr 1fr; } }
.toggle { display: inline-flex; align-items: center; gap: 10px; cursor: pointer; font-weight: 600; }
.toggle input { appearance: none; width: 50px; height: 30px; border-radius: 99px; background: #d4dbea; position: relative; transition: background .35s; cursor: pointer; }
.toggle input::after { content: ""; position: absolute; top: 3px; left: 3px; width: 24px; height: 24px; border-radius: 50%; background: #fff; box-shadow: 0 2px 6px rgba(0,0,0,.2); transition: transform .45s var(--ease); }
.toggle input:checked { background: var(--green); }
.toggle input:checked::after { transform: translateX(20px); }
.alert { padding: 12px 14px; border-radius: 14px; background: var(--red-50); color: var(--red); font-weight: 600; font-size: 14px; }

/* ---------------------------------------------------------------- confirmation / tracking */
.success { text-align: center; padding: 28px 16px 8px; position: relative; overflow: hidden; }
.success .tick { width: 84px; height: 84px; margin: 0 auto 14px; border-radius: 50%; background: var(--green); color: #fff; display: grid; place-items: center; box-shadow: 0 0 0 10px rgba(22,163,74,.12); animation: tickpop .8s var(--ease) both; position: relative; }
.success .tick .ic { width: 44px; height: 44px; stroke-width: 3; stroke-dasharray: 30; stroke-dashoffset: 30; animation: draw .6s .35s var(--ease) forwards; }
.success .tick::before, .success .tick::after { content: ""; position: absolute; inset: -10px; border-radius: 50%; border: 2px solid rgba(22,163,74,.4); animation: ringout 1.6s .2s var(--ease) infinite; }
.success .tick::after { animation-delay: .7s; }
@keyframes tickpop { 0% { transform: scale(0); } 60% { transform: scale(1.12); } 100% { transform: scale(1); } }
@keyframes draw { to { stroke-dashoffset: 0; } }
.confetti { position: absolute; inset: 0; pointer-events: none; }
.confetti i { position: absolute; top: -10px; width: 8px; height: 14px; border-radius: 2px; animation: fall 2.6s var(--ease) forwards; opacity: 0; }
@keyframes fall { 0% { opacity: 1; transform: translateY(0) rotate(0); } 100% { opacity: 0; transform: translateY(280px) rotate(540deg); } }
.success h1 { font-size: 26px; font-weight: 800; color: var(--navy); }
.kv { display: grid; grid-template-columns: auto 1fr; gap: 0; }
.kv > * { padding: 12px 0; border-bottom: 1px solid var(--line-2); font-size: 14.5px; }
.kv > :nth-child(odd) { color: var(--ink-2); }
.kv > :nth-child(even) { text-align: right; font-weight: 700; }
.kv > :nth-last-child(-n+2) { border-bottom: 0; }
.prog { display: flex; justify-content: space-between; position: relative; margin: 8px 4px; }
.prog::before { content: ""; position: absolute; top: 15px; left: 6%; right: 6%; height: 3px; background: var(--line); border-radius: 3px; }
.prog .fill { position: absolute; top: 15px; left: 6%; height: 3px; border-radius: 3px; background: var(--blue); width: 0; transition: width 1.4s var(--ease); }
.prog.in .fill { width: var(--w); }
.prog .p { position: relative; z-index: 1; display: grid; justify-items: center; gap: 5px; width: 20%; text-align: center; font-size: 11.5px; font-weight: 600; color: var(--muted); }
.prog .p i { width: 32px; height: 32px; border-radius: 50%; background: #e9edf7; color: #9aa4bd; display: grid; place-items: center; transition: background .4s, color .4s; }
.prog .p i .ic { width: 17px; height: 17px; }
.prog .p.done i { background: var(--blue); color: #fff; }
.prog .p.now i { background: var(--blue); color: #fff; box-shadow: 0 0 0 5px rgba(31,79,224,.18); animation: nowpulse 2s infinite; }
.prog .p.done, .prog .p.now { color: var(--ink); }
@keyframes nowpulse { 50% { box-shadow: 0 0 0 9px rgba(31,79,224,.06); } }
.tl { position: relative; padding-left: 34px; }
.tl::before { content: ""; position: absolute; left: 11px; top: 8px; bottom: 8px; width: 2px; background: var(--line); }
.tl .water { position: absolute; left: 11px; top: 8px; width: 2px; height: 0; background: linear-gradient(var(--blue), #4f86ff); transition: height 1.6s var(--ease-water); border-radius: 2px; }
.tl .ev { position: relative; padding: 0 0 18px; }
.tl .ev::before { content: ""; position: absolute; left: -29px; top: 2px; width: 14px; height: 14px; border-radius: 50%; background: #fff; border: 3px solid #cbd3e6; }
.tl .ev.done::before { background: var(--blue); border-color: var(--blue); }
.tl .ev.now::before { background: #fff; border-color: var(--blue); box-shadow: 0 0 0 5px rgba(31,79,224,.16); }
.tl .ev b { display: block; font-size: 14.5px; }
.tl .ev span { font-size: 12.5px; color: var(--muted); }
.tl .ev.todo b { color: var(--muted); font-weight: 600; }
.route-map { position: relative; border-radius: 18px; overflow: hidden; background: linear-gradient(180deg, #dff0ff, #c9e6ff); }
.route-map svg { width: 100%; height: auto; }

/* ---------------------------------------------------------------- account */
.profile { display: flex; gap: 14px; align-items: center; }
.menu-list a, .menu-list button { width: 100%; display: flex; align-items: center; gap: 14px; padding: 14px 16px; border-bottom: 1px solid var(--line-2); font-weight: 600; text-align: left; transition: background .2s; }
.menu-list a:hover, .menu-list button:hover { background: var(--blue-50); }
.menu-list > :last-child { border-bottom: 0; }
.menu-list .ic { color: var(--navy); }
.menu-list .ic + span { flex: 1; }
.menu-list .count { min-width: 22px; height: 22px; border-radius: 99px; background: var(--red); color: #fff; font-size: 12px; display: grid; place-items: center; padding: 0 6px; }
.ocard { padding: 16px; }
.ocard + .ocard { margin-top: 12px; }
.mini-thumbs { display: flex; gap: 8px; }
.mini-thumbs span { width: 52px; height: 52px; border-radius: 12px; background: #f3f6fd; display: grid; place-items: center; overflow: hidden; }
.mini-thumbs .art, .mini-thumbs img { width: 84%; height: 84%; object-fit: contain; }
.ticket { display: grid; grid-template-columns: 4px 1fr auto; gap: 12px; padding: 12px 0; border-bottom: 1px solid var(--line-2); align-items: center; }
.ticket::before { content: ""; height: 100%; border-radius: 4px; background: var(--red); }
.ticket.resolved::before { background: var(--green); }
.ticket.in_progress::before { background: var(--blue); }
.help-tiles { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
@media (min-width: 768px) { .help-tiles { grid-template-columns: repeat(4, 1fr); } }
.help-tiles a { display: grid; justify-items: center; gap: 8px; padding: 18px 10px; border-radius: 16px; background: #fff; border: 1px solid var(--line-2); text-align: center; font-weight: 700; font-size: 14px; transition: transform .4s var(--ease), box-shadow .4s; }
.help-tiles a:hover { transform: translateY(-3px); box-shadow: var(--sh-2); }
.help-tiles .ic { width: 34px; height: 34px; color: var(--blue); }
.support-hero { position: relative; overflow: hidden; border-radius: 22px; padding: 22px; background: linear-gradient(135deg, var(--blue-50), #dbe6ff); }
.support-hero h1 { font-size: 26px; font-weight: 900; color: var(--navy); line-height: 1.1; }
.support-hero h1 em { color: var(--red); font-style: normal; display: block; }

/* sheet */
.sheet { position: fixed; inset: 0; z-index: 90; visibility: hidden; }
.sheet .scrim { position: absolute; inset: 0; background: rgba(11,29,92,.35); opacity: 0; transition: opacity .35s; }
.sheet .sheet-body { position: absolute; left: 0; right: 0; bottom: 0; max-height: 92vh; overflow-y: auto; background: #fff; border-radius: 26px 26px 0 0; padding: 10px 18px calc(24px + env(safe-area-inset-bottom)); transform: translateY(105%); transition: transform .55s var(--ease); }
.sheet .sheet-body::before { content: ""; display: block; width: 44px; height: 5px; border-radius: 9px; background: var(--line); margin: 0 auto 14px; }
.sheet.open { visibility: visible; }
.sheet.open .scrim { opacity: 1; }
.sheet.open .sheet-body { transform: none; }
@media (min-width: 768px) { .sheet .sheet-body { left: 50%; right: auto; bottom: auto; top: 50%; width: 520px; border-radius: 24px; transform: translate(-50%, -40%) scale(.96); opacity: 0; transition: transform .45s var(--ease), opacity .3s; } .sheet.open .sheet-body { transform: translate(-50%, -50%); opacity: 1; } }

/* ---------------------------------------------------------------- footer */
.ft { background: var(--navy); color: #c8d2f0; margin-top: 40px; }
.ft .wrap { display: grid; grid-template-columns: 1.4fr repeat(3, 1fr); gap: 30px; padding-top: 40px; padding-bottom: 30px; }
.ft h5 { color: #fff; font-size: 15px; margin: 0 0 12px; }
.ft a { display: block; padding: 4px 0; font-size: 14px; }
.ft a:hover { color: #fff; }
.ft .legal { border-top: 1px solid rgba(255,255,255,.1); padding: 16px 0; font-size: 13px; text-align: center; }
.ft .logo-text b { color: #fff; }
.ft .logo-text b + b { color: #ff5a62; }
.ft .logo-text small { color: #c8d2f0; }

/* ---------------------------------------------------------------- splash & onboarding */
.splash { position: fixed; inset: 0; z-index: 9800; display: flex; flex-direction: column; align-items: center; justify-content: space-between; text-align: center; background: linear-gradient(180deg, #eaf2ff 0%, #ffffff 34%, #f4f8ff 100%); padding: calc(18px + env(safe-area-inset-top)) 22px calc(18px + env(safe-area-inset-bottom)); overflow: hidden; clip-path: circle(150% at 50% 42%); transition: clip-path .85s var(--ease-water); }
.splash.gone { clip-path: circle(0% at 50% 42%); pointer-events: none; }
.splash[hidden] { display: none; }
.lang-pill { align-self: flex-end; display: inline-flex; align-items: center; gap: 8px; height: 38px; padding: 0 14px; border-radius: 999px; background: #fff; box-shadow: var(--sh-2); font-weight: 700; color: var(--navy); font-size: 14px; }
.lang-pill .flag { width: 22px; height: 22px; border-radius: 50%; overflow: hidden; }
.splash .tag1 { font-size: 34px; font-weight: 900; line-height: 1.02; letter-spacing: -.02em; color: var(--navy); }
.splash .tag1 em { display: block; color: var(--red); font-style: normal; }
.splash .sub { margin-top: 8px; color: var(--ink-2); font-size: 15px; }
.splash .scene { width: 100%; max-width: 420px; flex: 1; min-height: 0; display: grid; place-items: center; }
.splash .scene svg { width: 100%; height: 100%; max-height: min(300px, 30vh); }
.feat4 { display: grid; grid-template-columns: repeat(4, 1fr); gap: 6px; width: 100%; max-width: 420px; background: rgba(255,255,255,.85); border-radius: 18px; padding: 12px 6px; box-shadow: var(--sh-2); }
.feat4 div { display: grid; justify-items: center; gap: 6px; font-size: 12px; font-weight: 700; color: var(--navy); line-height: 1.2; }
.feat4 i { width: 48px; height: 48px; border-radius: 50%; display: grid; place-items: center; color: #fff; background: var(--blue); box-shadow: 0 0 0 6px rgba(31,79,224,.1); }
.feat4 i.r { background: var(--red); box-shadow: 0 0 0 6px rgba(229,32,43,.1); }
.feat4 i .ic { width: 24px; height: 24px; }
.liquid-bar { position: relative; width: min(100%, 360px); height: 14px; border-radius: 99px; background: #dfe7fb; overflow: hidden; margin-top: 16px; }
.liquid-bar .liq { position: absolute; inset: 0 auto 0 0; width: 0%; background: linear-gradient(90deg, #1d47d6, #3b6cf6); border-radius: 99px; overflow: hidden; transition: width .25s linear; }
.liquid-bar .liq::after { content: ""; position: absolute; top: -6px; right: -12px; width: 26px; height: 26px; border-radius: 42%; background: #3b6cf6; animation: spin 1.4s linear infinite; }
.liquid-bar .liq::before { content: ""; position: absolute; inset: 0; background: repeating-linear-gradient(110deg, rgba(255,255,255,.0) 0 10px, rgba(255,255,255,.22) 10px 18px); animation: flow 1s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
@keyframes flow { to { background-position: 40px 0; } }
.splash .pct { font-weight: 700; color: var(--ink-2); font-size: 13px; }
.splash .foot { display: grid; justify-items: center; gap: 2px; font-size: 10px; letter-spacing: .25em; color: var(--ink-2); font-weight: 700; margin-top: 10px; }
.splash .foot small { letter-spacing: .3em; color: var(--muted); font-size: 9px; }
.splash .bob { animation: bob 3.2s ease-in-out infinite; }
@keyframes bob { 50% { transform: translateY(-6px); } }

.onb { position: fixed; inset: 0; z-index: 9700; background: #fff; display: flex; flex-direction: column; }
.onb[hidden] { display: none; }
.onb.closing { animation: onbout .8s var(--ease-water) forwards; }
@keyframes onbout { to { clip-path: circle(0% at 50% 92%); } }
.onb-track { flex: 1; min-height: 0; display: grid; grid-auto-flow: column; grid-auto-columns: 100%; overflow-x: auto; scroll-snap-type: x mandatory; scrollbar-width: none; overscroll-behavior-x: contain; }
.onb-track::-webkit-scrollbar { display: none; }
.onb-slide { scroll-snap-align: center; display: flex; flex-direction: column; align-items: center; text-align: center; padding: calc(64px + env(safe-area-inset-top)) 24px 8px; background: linear-gradient(180deg, #eef4ff, #fff 46%); overflow: hidden; }
.onb-slide h2 { font-size: 32px; font-weight: 900; line-height: 1.05; color: var(--navy); letter-spacing: -.02em; }
.onb-slide h2 em { display: block; color: var(--red); font-style: normal; }
.onb-slide p { margin-top: 12px; color: var(--ink-2); max-width: 340px; }
.onb-slide .ill { flex: 1; width: 100%; max-width: 380px; min-height: 0; display: grid; place-items: center; margin-top: 12px; }
.onb-slide .ill svg { width: 100%; height: 100%; max-height: min(340px, 42vh); }
.onb-skip { position: absolute; top: calc(14px + env(safe-area-inset-top)); right: 16px; z-index: 2; height: 38px; padding: 0 18px; border-radius: 999px; background: var(--blue-100); color: var(--blue); font-weight: 700; }
.onb-foot { padding: 12px 22px calc(18px + env(safe-area-inset-bottom)); display: grid; gap: 14px; }
.onb-dots { display: flex; justify-content: center; gap: 6px; }
.onb-dots i { width: 9px; height: 9px; border-radius: 9px; background: #d4dcf0; transition: width .5s var(--ease), background .4s; }
.onb-dots i.on { width: 26px; background: var(--red); }
.onb-btns { display: flex; gap: 12px; }
.onb-btns .btn { flex: 1; }
.onb-signin { text-align: center; font-size: 14px; color: var(--muted); }
.onb-signin a { color: var(--blue); font-weight: 700; }

/* ---------------------------------------------------------------- reveal */
.rv { opacity: 0; transform: translateY(18px); transition: opacity .7s var(--ease), transform .8s var(--ease); transition-delay: calc(var(--i, 0) * 55ms); }
.rv.in { opacity: 1; transform: none; }

/* ==========================================================================
   PANELS (admin + seller)
   ========================================================================== */
body.panel { background: #f4f6fb; }
.pl { display: grid; grid-template-columns: 1fr; min-height: 100vh; }
@media (min-width: 1024px) { .pl { grid-template-columns: 236px 1fr; } }
.side { position: fixed; z-index: 70; inset: 0 auto 0 0; width: 252px; background: linear-gradient(180deg, #0b1d5c 0%, #0d2470 100%); color: #c8d2f0; transform: translateX(-104%); transition: transform .45s var(--ease); display: flex; flex-direction: column; overflow-y: auto; }
.side.open { transform: none; box-shadow: var(--sh-3); }
@media (min-width: 1024px) { .side { position: sticky; top: 0; height: 100vh; width: auto; transform: none; } }
.side .brand { padding: 16px 16px 12px; background: #fff; }
.side nav { padding: 12px 10px; display: grid; gap: 2px; }
.side nav a { position: relative; display: flex; align-items: center; gap: 12px; padding: 10px 12px; border-radius: 11px; font-size: 14px; font-weight: 600; transition: background .25s, color .25s; }
.side nav a:hover { background: rgba(255,255,255,.07); color: #fff; }
.side nav a.on { background: var(--blue); color: #fff; box-shadow: 0 8px 20px rgba(31,79,224,.45); }
.side nav a .ic { width: 19px; height: 19px; }
.side nav a .cnt { margin-left: auto; min-width: 22px; height: 20px; border-radius: 99px; background: var(--red); color: #fff; font-size: 11px; display: grid; place-items: center; padding: 0 6px; }
.side h6 { font-size: 10.5px; letter-spacing: .14em; text-transform: uppercase; color: #7f8cc0; margin: 14px 12px 6px; }
.side .side-foot { margin-top: auto; padding: 14px; font-size: 12px; color: #7f8cc0; }
.ptop { position: sticky; top: 0; z-index: 40; display: flex; align-items: center; gap: 12px; height: 64px; padding: 0 16px; background: rgba(255,255,255,.92); backdrop-filter: blur(12px); border-bottom: 1px solid var(--line); }
@media (min-width: 1024px) { .ptop { padding: 0 28px; } }
.ptop .search { flex: 1; max-width: 420px; display: flex; align-items: center; gap: 8px; height: 40px; border-radius: 11px; background: var(--bg); padding: 0 12px; color: var(--muted); }
.ptop .search input { border: 0; background: transparent; outline: 0; flex: 1; min-width: 0; font-size: 14px; }
.ptop .me { display: flex; align-items: center; gap: 10px; margin-left: auto; }
.ptop .me b { display: block; font-size: 14px; line-height: 1.1; }
.ptop .me small { color: var(--muted); font-size: 12px; }
.pmain { padding: 20px 16px 40px; min-width: 0; }
@media (min-width: 1024px) { .pmain { padding: 26px 28px 48px; } }
.phead { display: flex; align-items: flex-start; justify-content: space-between; gap: 14px; flex-wrap: wrap; margin-bottom: 18px; }
.phead h1 { font-size: 23px; font-weight: 800; color: var(--navy); }
.phead p { color: var(--muted); font-size: 14px; margin-top: 2px; }
.kpis { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
@media (min-width: 1100px) { .kpis { grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 16px; } }
.kpi { display: flex; gap: 12px; align-items: flex-start; padding: 16px; background: #fff; border-radius: 16px; border: 1px solid var(--line-2); box-shadow: var(--sh-1); position: relative; overflow: hidden; }
.kpi .ki { width: 44px; height: 44px; border-radius: 12px; display: grid; place-items: center; color: var(--c, var(--blue)); background: color-mix(in srgb, var(--c, var(--blue)) 12%, #fff); flex: none; }
.kpi .ki .ic { width: 22px; height: 22px; }
.kpi small { color: var(--muted); font-size: 12.5px; font-weight: 600; display: block; }
.kpi b { font-size: 22px; font-weight: 800; color: var(--navy); display: block; letter-spacing: -.01em; line-height: 1.25; }
.kpi .delta { font-size: 12px; font-weight: 700; color: var(--green); }
.kpi .delta.down { color: var(--red); }
.kpi::after { content: ""; position: absolute; right: -30px; bottom: -40px; width: 110px; height: 110px; border-radius: 42%; background: color-mix(in srgb, var(--c, var(--blue)) 6%, transparent); animation: spin 14s linear infinite; }
.pgrid2 { display: grid; gap: 16px; margin-top: 16px; }
@media (min-width: 1100px) { .pgrid2 { grid-template-columns: 1.6fr 1fr; } .pgrid2.even { grid-template-columns: 1fr 1fr; } }
.panel-card { background: #fff; border-radius: 18px; border: 1px solid var(--line-2); box-shadow: var(--sh-1); padding: 18px; min-width: 0; }
.panel-card h3 { font-size: 16px; font-weight: 800; color: var(--navy); }
.chart { width: 100%; height: auto; overflow: visible; }
.chart .grid line { stroke: #edf0f7; }
.chart .ax text { font-size: 10px; fill: #8c96ad; }
.chart .ln { fill: none; stroke-width: 2.5; stroke-linejoin: round; stroke-linecap: round; stroke-dasharray: var(--len); stroke-dashoffset: var(--len); }
.chart.in .ln { animation: drawln 1.8s var(--ease) forwards; }
@keyframes drawln { to { stroke-dashoffset: 0; } }
.chart .area { opacity: 0; transition: opacity .6s .6s; }
.chart.in .area { opacity: 1; }
.chart .rise { transform: translateY(100%); transition: transform 1.6s var(--ease-water) .2s; }
.chart.in .rise { transform: translateY(0); }
.chart .pt { opacity: 0; transition: opacity .3s; }
.chart.in .pt { opacity: 1; transition-delay: 1.4s; }
.chart .hot { fill: transparent; cursor: crosshair; }
.chart-tip { position: fixed; z-index: 95; pointer-events: none; background: var(--navy); color: #fff; font-size: 12px; padding: 7px 10px; border-radius: 10px; box-shadow: var(--sh-3); transform: translate(-50%, calc(-100% - 12px)); opacity: 0; transition: opacity .15s; white-space: nowrap; }
.chart-tip.on { opacity: 1; }
.legend { display: flex; gap: 14px; flex-wrap: wrap; font-size: 12.5px; color: var(--ink-2); font-weight: 600; }
.legend i { display: inline-block; width: 10px; height: 10px; border-radius: 3px; margin-right: 6px; vertical-align: -1px; }
.donut-wrap { display: grid; grid-template-columns: 150px 1fr; gap: 16px; align-items: center; }
.donut circle.seg { fill: none; stroke-width: 18; transform: rotate(-90deg); transform-origin: 50% 50%; stroke-dasharray: 0 999; transition: stroke-dasharray 1.4s var(--ease); }
.donut-legend { display: grid; gap: 8px; font-size: 13px; }
.donut-legend div { display: flex; align-items: center; gap: 8px; }
.donut-legend b { margin-left: auto; }
.donut-legend i { width: 10px; height: 10px; border-radius: 50%; }
.lbr-map { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 14px; align-items: center; }
.lbr-map svg path { stroke: #fff; stroke-width: 1.2; transition: fill .4s, transform .4s var(--ease); transform-box: fill-box; transform-origin: center; cursor: pointer; }
.lbr-map svg path:hover { transform: scale(1.04); filter: drop-shadow(0 4px 8px rgba(15,42,122,.25)); }
.lbr-map svg path.drop { animation: mapdrop .9s var(--ease) both; }
@keyframes mapdrop { from { opacity: 0; transform: scale(.85); } }
.county-list { display: grid; gap: 7px; font-size: 13px; }
.county-list div { display: flex; justify-content: space-between; gap: 8px; }
.county-list b { color: var(--navy); }
.tbl-wrap { overflow-x: auto; margin: 0 -18px; padding: 0 18px; }
.tbl { width: 100%; border-collapse: separate; border-spacing: 0; font-size: 13.5px; min-width: 640px; }
.tbl th { text-align: left; font-size: 12px; text-transform: uppercase; letter-spacing: .04em; color: var(--muted); font-weight: 700; padding: 10px 12px; border-bottom: 1px solid var(--line); white-space: nowrap; }
.tbl td { padding: 12px; border-bottom: 1px solid var(--line-2); vertical-align: middle; }
.tbl tr { transition: background .2s; }
.tbl tbody tr:hover { background: #f8faff; }
.tbl .num { font-variant-numeric: tabular-nums; }
.tbl .acts { display: flex; gap: 4px; }
.tbl .acts a, .tbl .acts button { width: 30px; height: 30px; border-radius: 8px; display: grid; place-items: center; color: var(--blue); }
.tbl .acts a:hover, .tbl .acts button:hover { background: var(--blue-50); }
.tbl .acts .ic { width: 16px; height: 16px; }
.tbl .pthumb { width: 40px; height: 40px; border-radius: 10px; background: #f3f6fd; display: grid; place-items: center; flex: none; }
.tbl .pthumb .art, .tbl .pthumb img { width: 34px; height: 34px; object-fit: contain; }
.tabs-line { display: flex; gap: 6px; overflow-x: auto; scrollbar-width: none; margin-bottom: 14px; }
.tabs-line a { flex: none; padding: 8px 14px; border-radius: 10px; font-weight: 700; font-size: 13.5px; color: var(--ink-2); background: #fff; border: 1.5px solid var(--line); transition: all .3s var(--ease); }
.tabs-line a.on { background: var(--blue); border-color: var(--blue); color: #fff; box-shadow: 0 6px 16px rgba(31,79,224,.25); }
.filters-row { display: flex; gap: 10px; flex-wrap: wrap; margin-bottom: 14px; }
.filters-row .input, .filters-row select { min-height: 40px; width: auto; flex: 1 1 160px; border-radius: 11px; border: 1.5px solid var(--line); padding: 0 12px; background: #fff; }
.pager-p { display: flex; justify-content: space-between; align-items: center; gap: 10px; flex-wrap: wrap; margin-top: 14px; font-size: 13px; color: var(--muted); }
.hamb { display: inline-grid; }
@media (min-width: 1024px) { .hamb { display: none; } }
.side-scrim { position: fixed; inset: 0; z-index: 65; background: rgba(11,29,92,.35); opacity: 0; visibility: hidden; transition: opacity .3s; }
.side-scrim.open { opacity: 1; visibility: visible; }
.mini-bars { display: flex; align-items: flex-end; gap: 3px; height: 34px; }
.mini-bars i { flex: 1; background: var(--blue-100); border-radius: 3px 3px 0 0; }
.upload-drop { display: grid; place-items: center; gap: 6px; text-align: center; padding: 26px; border-radius: 16px; border: 2px dashed #c8d3ee; background: var(--blue-50); color: var(--blue); cursor: pointer; transition: background .3s, border-color .3s; }
.upload-drop:hover, .upload-drop.drag { background: #e3ebff; border-color: var(--blue); }
.upload-drop .ic { width: 30px; height: 30px; }
.thumbs-row { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 10px; }
.thumbs-row span { width: 64px; height: 64px; border-radius: 12px; background: #f3f6fd center / cover no-repeat; border: 1px solid var(--line); }
.rte-bar { display: flex; gap: 2px; padding: 6px; border: 1.5px solid var(--line); border-bottom: 0; border-radius: 12px 12px 0 0; background: #fafbfe; }
.rte-bar button { width: 30px; height: 30px; border-radius: 7px; font-weight: 800; color: var(--ink-2); }
.rte-bar button:hover { background: var(--blue-50); }
.rte-bar + textarea { border-radius: 0 0 12px 12px !important; }

/* ==========================================================================
   DRIVER APP
   ========================================================================== */
body.driver { background: #f4f6fb; }
.dshell { max-width: 520px; margin: 0 auto; min-height: 100vh; background: #f4f6fb; position: relative; }
.dtop { position: sticky; top: 0; z-index: 40; display: flex; align-items: center; gap: 8px; height: 60px; padding: calc(env(safe-area-inset-top)) 12px 0; background: rgba(255,255,255,.95); backdrop-filter: blur(12px); }
.dtop h1 { flex: 1; text-align: center; font-size: 19px; font-weight: 800; color: var(--navy); }
.dmain { padding: 14px 14px calc(var(--tabbar-h) + 28px); }
.dtabbar { max-width: 520px; margin: 0 auto; }
.d-hello { display: flex; align-items: center; gap: 12px; }
.online-pill { display: inline-flex; align-items: center; gap: 6px; font-size: 13px; font-weight: 700; color: var(--green); }
.online-pill::before { content: ""; width: 8px; height: 8px; border-radius: 50%; background: currentColor; }
.online-pill.off { color: var(--muted); }
.dstats { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.dstat { display: flex; gap: 10px; align-items: center; padding: 14px; background: #fff; border-radius: 16px; border: 1px solid var(--line-2); }
.dstat i { width: 40px; height: 40px; border-radius: 12px; display: grid; place-items: center; background: var(--blue-50); color: var(--blue); }
.dstat b { display: block; font-size: 19px; color: var(--navy); line-height: 1.1; }
.dstat small { color: var(--muted); font-size: 12px; }
.offer { padding: 14px; background: #fff; border-radius: 18px; border: 1px solid var(--line-2); box-shadow: var(--sh-1); }
.offer + .offer { margin-top: 12px; }
.offer .timer { display: inline-flex; align-items: center; gap: 4px; height: 26px; padding: 0 9px; border-radius: 8px; background: var(--red); color: #fff; font-size: 12px; font-weight: 700; }
.leg { display: grid; grid-template-columns: 14px 1fr; gap: 8px; font-size: 13px; color: var(--ink-2); margin-top: 6px; }
.leg i { width: 10px; height: 10px; border-radius: 50%; border: 2px solid var(--blue); margin-top: 4px; }
.leg i.r { border-color: var(--red); }
.dmap { position: relative; border-radius: 18px; overflow: hidden; background: #e8eef6; }
.dmap svg { width: 100%; height: auto; display: block; }
.dmap .route { fill: none; stroke: var(--blue); stroke-width: 5; stroke-linecap: round; stroke-dasharray: var(--len); stroke-dashoffset: var(--len); animation: drawln 2.2s var(--ease) .2s forwards; }
.dmap .me { animation: pulse 2s infinite; }
.check-row { display: flex; gap: 12px; align-items: center; padding: 12px 0; border-bottom: 1px solid var(--line-2); font-weight: 600; font-size: 14px; cursor: pointer; }
.check-row .check { margin-top: 0; }
.earn-hero { border-radius: 20px; padding: 18px; color: #fff; background: linear-gradient(135deg, #ff3b3b, #c8101b); box-shadow: 0 14px 30px rgba(229,32,43,.3); position: relative; overflow: hidden; }
.earn-hero b { font-size: 34px; font-weight: 900; display: block; }
.earn-hero .three { display: grid; grid-template-columns: repeat(3, 1fr); background: #fff; color: var(--ink); border-radius: 14px; margin-top: 14px; padding: 10px 6px; text-align: center; }
.earn-hero .three b { font-size: 17px; color: var(--navy); }
.earn-hero .three small { font-size: 11.5px; color: var(--muted); }

/* driver login */
.dlogin { min-height: 100vh; display: flex; flex-direction: column; background: linear-gradient(180deg, #eef4ff, #fff 40%); max-width: 520px; margin: 0 auto; padding: calc(24px + env(safe-area-inset-top)) 22px 28px; }
.dlogin h1 { font-size: 34px; font-weight: 900; color: var(--navy); letter-spacing: -.02em; margin-top: 18px; }
.ticks { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; margin-top: 12px; font-weight: 600; font-size: 14px; color: var(--ink-2); }
.ticks span { display: flex; align-items: center; gap: 8px; }
.ticks .ic { color: #fff; background: var(--red); border-radius: 50%; padding: 3px; width: 20px; height: 20px; }
.in-ic { position: relative; }
.in-ic .ic { position: absolute; left: 14px; top: 50%; transform: translateY(-50%); color: var(--muted); }
.in-ic input { padding-left: 44px !important; }
.or { display: flex; align-items: center; gap: 10px; color: var(--muted); font-size: 13px; margin: 6px 0; }
.or::before, .or::after { content: ""; flex: 1; height: 1px; background: var(--line); }

/* panel login */
.plogin { min-height: 100vh; display: grid; place-items: center; padding: 24px; background: radial-gradient(80% 60% at 50% 0%, #e3ebff, #f4f6fb 70%); }
.plogin .box { width: min(100%, 420px); background: #fff; border-radius: 24px; padding: 28px; box-shadow: var(--sh-3); }

/* reduced motion */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; scroll-behavior: auto !important; }
  #dl-tide { display: none; }
  .rv { opacity: 1; transform: none; }
}
@media print { .tabbar, .mh, .hd, .ft, #dl-tide, .toasts { display: none !important; } }
