/* =========================================================
   ELIKEYS ENT — Store Stylesheet
   Light, bright ecommerce theme. Warm gold accent carried over
   from the brand mark, on a clean white/cream base.
   Fonts: Poppins (display) + Inter (body) — the standard
   ecommerce pairing (Shopify-class stores lean on this combo).
   ========================================================= */

@import url('https://fonts.googleapis.com/css2?family=Poppins:wght@500;600;700;800&family=Inter:wght@400;500;600;700&display=swap');

:root {
    --bg:        #FFFFFF;
    --bg-soft:   #FAF8F4;
    --surface:   #FFFFFF;
    --surface-2: #F5F2EC;
    --border:    #E9E4D8;
    --gold:      #9C2B2B;
    --gold-hi:   #C0433D;
    --gold-soft: #F7E3E1;
    --ink:       #17150F;
    --text:      #221F19;
    --text-muted:#736C5E;
    --success:   #16A34A;
    --success-soft: #E7F7ED;
    --danger:    #DC2626;
    --danger-soft: #FDECEC;

    /* Category accents — a small, purposeful palette (one hue per category)
       so the catalog reads as colourful without the rest of the UI competing
       for attention. Buttons, links and status colors above stay as-is. */
    --cat-software:      #2F6FED; --cat-software-soft:      #EAF1FE;
    --cat-courses:       #8A4FD1; --cat-courses-soft:       #F2EBFB;
    --cat-loops:         #E0921E; --cat-loops-soft:         #FCF1DF;
    --cat-stems:         #E0527A; --cat-stems-soft:         #FBE7ED;
    --cat-templates:     #12968A; --cat-templates-soft:     #E3F5F3;
    --cat-patches-tones: #4CAF6D; --cat-patches-tones-soft: #EAF7EE;
    --cat-gadgets:       #C2410C; --cat-gadgets-soft:       #FCEAE0;
    --cat-default:       var(--gold); --cat-default-soft: var(--gold-soft);

    --radius:    12px;
    --shadow-sm: 0 1px 2px rgba(23,21,15,.05);
    --shadow-md: 0 8px 24px rgba(23,21,15,.08);
    --shadow-lg: 0 20px 48px rgba(23,21,15,.12);
    --font-display: 'Poppins', sans-serif;
    --font-body: 'Inter', sans-serif;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
    margin: 0;
    background: var(--bg);
    color: var(--text);
    font-family: var(--font-body);
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
h1, h2, h3, h4 { font-family: var(--font-display); font-weight: 700; margin: 0 0 .5em; letter-spacing: -0.01em; color: var(--ink); }
p { margin: 0 0 1em; color: var(--text-muted); }
:focus-visible { outline: 2px solid var(--gold); outline-offset: 2px; }
@media (prefers-reduced-motion: reduce) { * { animation: none !important; transition: none !important; scroll-behavior: auto !important; } }

.container { max-width: 1180px; margin: 0 auto; padding: 0 20px; }
.eyebrow {
    display: inline-block; font-family: var(--font-display); font-size: .72rem; font-weight: 600;
    letter-spacing: .14em; text-transform: uppercase; color: var(--gold);
    background: var(--gold-soft); padding: 5px 14px; border-radius: 999px;
    margin-bottom: 16px;
}

/* ---------- Reveal-on-scroll ---------- */
.reveal { opacity: 0; transform: translateY(18px); transition: opacity .6s ease, transform .6s ease; }
.reveal.is-visible { opacity: 1; transform: translateY(0); }

/* ---------- Buttons ---------- */
.btn {
    display: inline-flex; align-items: center; justify-content: center; gap: 8px;
    font-family: var(--font-display); font-weight: 600; font-size: .9rem;
    padding: 13px 26px; border-radius: 8px; border: 1px solid transparent;
    cursor: pointer; transition: transform .15s ease, background .2s ease, border-color .2s ease, box-shadow .2s ease;
    position: relative; overflow: hidden;
}
.btn:active { transform: scale(.97); }
.btn-primary { background: var(--ink); color: #fff; box-shadow: var(--shadow-sm); }
.btn-primary:hover { background: #2C2818; box-shadow: var(--shadow-md); transform: translateY(-1px); }
.btn-outline { background: transparent; border-color: var(--border); color: var(--ink); }
.btn-outline:hover { border-color: var(--gold); color: var(--gold); background: var(--gold-soft); }
.btn-danger { background: var(--danger); color: #fff; }
.btn-sm { padding: 8px 16px; font-size: .8rem; }
.btn-block { width: 100%; }

/* ---------- Header ---------- */
.site-header {
    position: sticky; top: 0; z-index: 50;
    background: rgba(255,255,255,.92); backdrop-filter: blur(10px);
    border-bottom: 1px solid var(--border);
}
.header-inner { display: flex; align-items: center; justify-content: space-between; padding: 14px 0; gap: 24px; }
.logo { display: flex; align-items: center; gap: 10px; font-family: var(--font-display); font-weight: 700; font-size: 1.15rem; color: var(--ink); }
.logo img { height: 40px; width: 40px; object-fit: cover; border-radius: 50%; display: block; box-shadow: 0 0 0 1px rgba(184,135,59,.25), 0 4px 14px rgba(184,135,59,.18); flex-shrink: 0; }
.logo .mark {
    width: 36px; height: 36px; border-radius: 50%;
    background: conic-gradient(from 90deg, var(--gold-hi), var(--gold), #6B1D1D, var(--gold-hi));
    display: flex; align-items: center; justify-content: center;
    box-shadow: 0 0 0 1px rgba(184,135,59,.25), 0 4px 14px rgba(184,135,59,.25);
    animation: spin 16s linear infinite;
    flex-shrink: 0;
}
.logo .mark::after { content: ''; width: 11px; height: 11px; background: #fff; border-radius: 50%; }
@keyframes spin { to { transform: rotate(360deg); } }
.logo small { display: block; color: var(--text-muted); font-family: var(--font-body); font-weight: 500; font-size: .68rem; letter-spacing: .04em; }

/* Sidebar drawer nav — toggleable on every screen size, not just mobile. */
.main-nav {
    position: fixed; top: 0; left: 0; bottom: 0; z-index: 80;
    height: 100vh;
    width: min(84vw, 300px);
    background: var(--bg);
    display: flex; flex-direction: column;
    align-items: stretch;
    padding: 8px 12px 20px; gap: 2px;
    transform: translateX(-100%);
    transition: transform .28s ease;
    overflow-y: auto;
    box-shadow: var(--shadow-lg);
    border-right: 1px solid var(--border);
}
.main-nav.open { transform: translateX(0); }

.main-nav-head {
    display: flex; align-items: center; justify-content: space-between;
    padding: 10px 8px 16px;
    font-family: var(--font-display); font-weight: 700; color: var(--ink);
    position: sticky; top: 0; background: var(--bg);
}
.nav-close { display: block; background: none; border: none; font-size: 1.25rem; color: var(--ink); cursor: pointer; padding: 4px; }

.nav-section-label {
    font-family: var(--font-display); font-size: .68rem; font-weight: 700; letter-spacing: .08em;
    text-transform: uppercase; color: var(--text-muted); padding: 16px 10px 6px;
}

.main-nav a.nav-link {
    display: flex; align-items: center; gap: 12px;
    width: 100%; padding: 10px 10px; border-radius: 10px;
    font-size: .92rem; font-weight: 600; color: var(--text-muted);
    transition: background .15s, color .15s;
}
.main-nav a.nav-link .nav-icon {
    font-size: 1.05rem; width: 26px; height: 26px; text-align: center; flex-shrink: 0;
    display: inline-flex; align-items: center; justify-content: center;
    border-radius: 8px; background: var(--chip-soft, transparent); overflow: hidden;
}
.main-nav a.nav-link .nav-icon img { width: 100%; height: 100%; object-fit: cover; display: block; }
.main-nav a.nav-link:hover { background: var(--surface-2); color: var(--ink); }
.main-nav a.nav-link.active { background: var(--chip-soft, var(--gold-soft)); color: var(--chip-color, var(--ink)); }

.nav-toggle { display: flex; background: none; border: none; color: var(--ink); font-size: 1.4rem; cursor: pointer; }

.header-actions { display: flex; align-items: center; gap: 16px; }
.icon-link { position: relative; color: var(--ink); font-size: 1.1rem; transition: transform .15s; }
.icon-link:hover { transform: translateY(-1px); }

.header-search { display: flex; align-items: center; flex: 1; max-width: 480px; min-width: 0; }
.header-search input[type=text] {
    width: 100%; padding: 9px 14px; border-radius: 20px 0 0 20px; border-right: none;
    font-size: .85rem; background: var(--surface-2);
}
.header-search button {
    border: 1px solid var(--border); border-left: none; background: var(--surface-2);
    border-radius: 0 20px 20px 0; padding: 9px 14px; cursor: pointer; font-size: .95rem;
    color: var(--ink); flex-shrink: 0; transition: background .15s;
}
.header-search button:hover { background: var(--gold-soft); }
@media (max-width: 640px) {
    .header-search { max-width: none; order: 3; flex-basis: 100%; margin-top: 10px; }
    .header-inner { flex-wrap: wrap; }
}
@media (max-width: 860px) {
    /* Cart/wishlist/account/sell are already covered by the bottom tab bar on
       mobile — no need to duplicate them up here, so the header stays down
       to just the menu button and search, as requested. */
    .header-actions-desktop-only { display: none; }
}
.cart-badge {
    position: absolute; top: -8px; right: -10px; background: var(--gold); color: #fff;
    font-size: .65rem; font-weight: 700; width: 18px; height: 18px; border-radius: 50%;
    display: flex; align-items: center; justify-content: center;
}

.nav-overlay {
    display: block; position: fixed; inset: 0; z-index: 75;
    height: 100vh; width: 100vw;
    background: rgba(23,21,15,.5);
    opacity: 0; pointer-events: none;
    transition: opacity .25s ease;
}
.nav-overlay.open { opacity: 1; pointer-events: auto; }

body.nav-lock { overflow: hidden; }

/* Extra-narrow phones: trim the header so logo + icons never get squeezed off-screen */
@media (max-width: 380px) {
    .logo small { display: none; }
    .header-inner { gap: 12px; }
    .header-actions { gap: 10px; }
}

/* ---------- Hero ---------- */
.hero { position: relative; padding: 76px 0 60px; overflow: hidden; border-bottom: 1px solid var(--border); background: linear-gradient(180deg, var(--bg-soft), var(--bg) 70%); }
.hero-eq { position: absolute; inset: auto 0 0 0; height: 90px; display: flex; align-items: flex-end; gap: 4px; opacity: .18; pointer-events: none; }
.hero-eq span { flex: 1; background: linear-gradient(180deg, var(--gold), transparent); animation: eq 1.6s ease-in-out infinite; }
.hero-eq span:nth-child(odd) { animation-duration: 1.1s; }
.hero-eq span:nth-child(3n) { animation-duration: 1.9s; }
@keyframes eq { 0%,100% { height: 12%; } 50% { height: 85%; } }
.hero-grid { display: grid; grid-template-columns: 1.1fr .9fr; gap: 50px; align-items: center; position: relative; z-index: 1; }
.hero h1 { font-size: clamp(2.1rem, 4.2vw, 3.4rem); line-height: 1.08; animation: fadeUp .7s ease both; }
.hero h1 span { color: var(--gold); }
.hero p { font-size: 1.02rem; max-width: 46ch; animation: fadeUp .7s ease .1s both; }
.hero-actions { display: flex; gap: 14px; margin-top: 24px; flex-wrap: wrap; animation: fadeUp .7s ease .2s both; }
@keyframes fadeUp { from { opacity: 0; transform: translateY(14px); } to { opacity: 1; transform: translateY(0); } }
.hero-visual { border: 1px solid var(--border); border-radius: var(--radius); background: var(--surface); padding: 26px; box-shadow: var(--shadow-md); animation: fadeUp .7s ease .15s both; }
.hero-visual .row { display: flex; justify-content: space-between; padding: 10px 0; border-bottom: 1px dashed var(--border); font-family: var(--font-display); font-size: .85rem; }
.hero-visual .row:last-child { border-bottom: none; }
.hero-visual .row b { color: var(--gold); }
@media (max-width: 860px) { .hero-grid { grid-template-columns: 1fr; } }

/* ---------- Mini banner (replaces old hero on homepage) ---------- */
.mini-banner {
    padding: 18px 0; border-bottom: 1px solid var(--border);
    background: linear-gradient(90deg, var(--gold-soft), var(--cat-templates-soft) 55%, var(--cat-software-soft));
}
.mini-banner-row { display: flex; align-items: center; justify-content: space-between; gap: 16px; flex-wrap: wrap; }
.mini-banner-text { font-family: var(--font-display); font-size: .95rem; font-weight: 600; color: var(--ink); }
.btn-sm { padding: 8px 16px; font-size: .82rem; }

/* ---------- Category chip strip ---------- */
.cat-strip-section { padding: 22px 0; }
.cat-strip { display: flex; gap: 10px; overflow-x: auto; padding-bottom: 4px; scrollbar-width: thin; }
.cat-chip {
    flex: 0 0 auto; background: var(--chip-soft, var(--surface)); border: 1px solid var(--chip-soft, var(--border)); border-radius: 999px;
    padding: 9px 20px; font-family: var(--font-display); font-weight: 600; font-size: .84rem;
    color: var(--chip-color, var(--ink)); white-space: nowrap; transition: border-color .2s, background .2s, color .2s;
}
.cat-chip:hover { border-color: var(--chip-color, var(--gold)); background: var(--chip-color, var(--gold)); color: #fff; }

/* ---------- Category strip ---------- */
.section { padding: 56px 0; }
.section-head { display: flex; align-items: flex-end; justify-content: space-between; margin-bottom: 28px; flex-wrap: wrap; gap: 12px; }
.section-head h2 { font-size: 1.7rem; margin: 0; }
.section-head-tools { display: flex; align-items: center; gap: 16px; flex-wrap: wrap; }
.sort-form { display: flex; align-items: center; gap: 8px; }
.sort-label { margin: 0; font-size: .82rem; color: var(--text-muted); font-weight: 600; white-space: nowrap; }
.sort-form select { width: auto; padding: 8px 12px; font-size: .85rem; }
.cat-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 14px; }
.cat-card {
    background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius);
    padding: 22px 16px; text-align: center; transition: border-color .2s, transform .2s, box-shadow .2s;
}
.cat-card:hover { border-color: var(--gold); transform: translateY(-4px); box-shadow: var(--shadow-md); }
.cat-card .dial { width: 46px; height: 46px; margin: 0 auto 12px; border-radius: 50%; border: 2px solid var(--gold); position: relative; transition: transform .3s ease; }
.cat-card:hover .dial { transform: rotate(35deg); }
.cat-card .dial::after { content: ''; position: absolute; top: 3px; left: 50%; width: 2px; height: 10px; background: var(--gold); transform: translateX(-50%); }
.cat-card span { font-family: var(--font-display); font-weight: 600; font-size: .88rem; color: var(--ink); }

/* ---------- Product grid ---------- */
/* Fixed-width tracks (not 1fr) so a short row — e.g. one "Recommended for
   you" card — stays compact instead of stretching to fill the container,
   same compact feel as the category grid below. */
.product-grid { display: grid; grid-template-columns: repeat(auto-fill, 230px); gap: 22px; }
.product-card { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); overflow: hidden; transition: border-color .2s, transform .2s, box-shadow .2s; display: flex; flex-direction: column; }
.product-card:hover { border-color: var(--gold); transform: translateY(-5px); box-shadow: var(--shadow-lg); }
.product-thumb { aspect-ratio: 1/1; background: var(--surface-2); position: relative; overflow: hidden; }
.product-thumb img { width: 100%; height: 100%; object-fit: cover; transition: transform .4s ease; }
.product-card:hover .product-thumb img { transform: scale(1.06); }
.product-thumb .badge { position: absolute; top: 10px; left: 10px; background: var(--ink); color: #fff; font-size: .68rem; font-weight: 700; padding: 4px 10px; border-radius: 999px; font-family: var(--font-display); }
.product-thumb .badge-discount { position: absolute; top: 10px; right: 10px; background: var(--danger); color: #fff; font-size: .68rem; font-weight: 700; padding: 4px 10px; border-radius: 999px; font-family: var(--font-display); }
.product-thumb .no-image { display: flex; align-items: center; justify-content: center; height: 100%; color: var(--text-muted); font-size: .8rem; background: var(--surface-2); }
.product-body { padding: 16px; display: flex; flex-direction: column; gap: 8px; flex: 1; }
.product-cat { font-size: .68rem; text-transform: uppercase; letter-spacing: .08em; color: var(--chip-color, var(--gold)); font-weight: 700; }
.product-name { font-family: var(--font-display); font-size: 1rem; font-weight: 600; color: var(--ink); }
.product-price { margin-top: auto; display: flex; align-items: center; justify-content: space-between; }
.product-price .price { font-family: var(--font-display); font-weight: 700; color: var(--ink); }
.product-price .compare { text-decoration: line-through; color: var(--text-muted); font-size: .8rem; margin-right: 6px; }

/* On phones: 2 products per row (2 up top, 2 below, and so on) instead of 1. */
@media (max-width: 640px) {
    .product-grid { grid-template-columns: repeat(2, 1fr); gap: 12px; }
    .product-card { border-radius: 12px; }
    .product-body { padding: 10px; gap: 5px; }
    .product-cat { font-size: .58rem; }
    .product-name {
        font-size: .82rem; line-height: 1.3; font-weight: 600;
        display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
    }
    .product-price { flex-direction: column; align-items: flex-start; gap: 0; margin-top: 4px; }
    .product-price .price { font-size: .88rem; }
    .product-price .compare { font-size: .68rem; margin-right: 0; }
    .product-thumb .badge, .product-thumb .badge-discount {
        font-size: .6rem; padding: 3px 8px; top: 6px;
    }
    .product-thumb .badge { left: 6px; }
    .product-thumb .badge-discount { right: 6px; }
    .product-thumb .wishlist-heart { top: 6px; left: 6px; width: 28px; height: 28px; font-size: .85rem; }
}
@media (max-width: 380px) {
    .product-grid { gap: 8px; }
    .product-body { padding: 8px; }
    .product-name { font-size: .76rem; }
    .product-price .price { font-size: .8rem; }
}

/* ---------- Forms ---------- */
.form-group { margin-bottom: 18px; }
label { display: block; font-size: .85rem; font-weight: 600; margin-bottom: 6px; color: var(--ink); }
input[type=text], input[type=email], input[type=password], input[type=tel], input[type=number],
textarea, select {
    width: 100%; padding: 12px 14px; background: var(--surface); border: 1px solid var(--border);
    border-radius: 8px; color: var(--text); font-family: var(--font-body); font-size: .92rem;
    transition: border-color .15s, box-shadow .15s;
}
input:focus, textarea:focus, select:focus { border-color: var(--gold); box-shadow: 0 0 0 3px var(--gold-soft); outline: none; }
textarea { resize: vertical; min-height: 100px; }
.form-card { max-width: 460px; margin: 60px auto; background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 34px; box-shadow: var(--shadow-md); }
.form-card h1 { font-size: 1.4rem; }
.form-foot { text-align: center; margin-top: 16px; font-size: .88rem; color: var(--text-muted); }
.form-foot a { color: var(--gold); font-weight: 600; }

/* ---------- Alerts ---------- */
.alert { padding: 13px 16px; border-radius: 8px; margin-bottom: 18px; font-size: .9rem; border: 1px solid transparent; }
.alert-success { background: var(--success-soft); border-color: rgba(22,163,74,.25); color: #14803A; }
.alert-error { background: var(--danger-soft); border-color: rgba(220,38,38,.25); color: #B32323; }

/* ---------- Cart / checkout ---------- */
.cart-table { width: 100%; border-collapse: collapse; }
.cart-table th { text-align: left; font-family: var(--font-display); font-size: .78rem; text-transform: uppercase; letter-spacing: .06em; color: var(--text-muted); padding: 10px; border-bottom: 1px solid var(--border); }
.cart-table td { padding: 14px 10px; border-bottom: 1px solid var(--border); vertical-align: middle; }
.cart-line-item { display: flex; align-items: center; gap: 12px; }
.cart-line-item img { width: 52px; height: 52px; border-radius: 6px; object-fit: cover; background: var(--surface-2); }
.qty-input { width: 64px; }
.cart-summary { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 24px; box-shadow: var(--shadow-sm); }
.summary-row { display: flex; justify-content: space-between; padding: 8px 0; font-size: .92rem; color: var(--text-muted); }

/* On phones, the cart/orders table becomes a stack of cards instead of a
   cramped table — nothing overlaps and nothing runs off the edge of the screen. */
@media (max-width: 640px) {
    .cart-table thead { display: none; }
    .cart-table, .cart-table tbody, .cart-table tr, .cart-table td { display: block; width: 100%; }
    .cart-table tr {
        border: 1px solid var(--border); border-radius: 12px;
        margin-bottom: 14px; padding: 4px 14px; background: var(--surface);
    }
    .cart-table td {
        display: flex; align-items: center; justify-content: space-between; gap: 12px;
        padding: 10px 0; border-bottom: 1px solid var(--border); text-align: right;
    }
    .cart-table td:last-child { border-bottom: none; }
    .cart-table td[data-label]::before {
        content: attr(data-label); font-weight: 600; color: var(--text-muted);
        font-size: .74rem; text-transform: uppercase; letter-spacing: .04em; flex-shrink: 0;
    }
    .cart-table td.cell-item { justify-content: flex-start; text-align: left; }
    .cart-table td.cell-action { justify-content: flex-end; }
    .cart-table .cart-line-item { flex-wrap: wrap; }
    .cart-table .qty-input { width: 68px; text-align: center; }

    /* The order-items "rate this product" strip spans the whole card, no label styling. */
    .cart-table tr.row-plain { border: none; background: none; padding: 0; margin-bottom: 8px; box-shadow: none; }
    .cart-table tr.row-plain td { display: block; padding: 0; border-bottom: none; }
}
.summary-row.total { color: var(--ink); font-family: var(--font-display); font-size: 1.15rem; font-weight: 700; border-top: 1px solid var(--border); margin-top: 8px; padding-top: 14px; }
.summary-row.total b { color: var(--gold); }

/* ---------- Product gallery (detail page) ---------- */
.gallery-thumbs { display: flex; gap: 10px; margin-top: 12px; flex-wrap: wrap; }
.gallery-thumbs img { width: 64px; height: 64px; object-fit: cover; border-radius: 8px; border: 2px solid var(--border); cursor: pointer; transition: border-color .15s, transform .15s; }
.gallery-thumbs img:hover { transform: translateY(-2px); }
.gallery-thumbs img.active { border-color: var(--gold); }

/* ---------- Footer ---------- */
.site-footer { border-top: 1px solid var(--border); padding: 46px 0 26px; margin-top: 60px; color: var(--text-muted); font-size: .88rem; background: var(--bg-soft); }
.footer-grid { display: grid; grid-template-columns: 1.4fr 1fr 1fr 1fr 1fr; gap: 32px; margin-bottom: 30px; }
.footer-grid h4 { color: var(--ink); font-size: .85rem; }
.footer-grid a { display: block; color: var(--text-muted); margin-bottom: 8px; transition: color .15s; }
.footer-grid a:hover { color: var(--gold); }
.footer-bottom { border-top: 1px solid var(--border); padding-top: 20px; display: flex; justify-content: space-between; flex-wrap: wrap; gap: 10px; }
@media (max-width: 900px) { .footer-grid { grid-template-columns: 1fr 1fr 1fr; } }
@media (max-width: 720px) { .footer-grid { grid-template-columns: 1fr 1fr; } }
@media (max-width: 480px) {
    .footer-grid { grid-template-columns: 1fr; }
    .site-footer .container > div:first-child { flex-direction: column; align-items: stretch !important; padding: 20px !important; }
    .site-footer form { width: 100%; }
    .site-footer input[type=email] { min-width: 0 !important; width: 100%; }
    .site-footer button { width: 100%; }
}

/* ---------- WhatsApp float ---------- */
.wa-float {
    position: fixed; bottom: 22px; right: 22px; background: #25D366; color: #fff;
    width: 54px; height: 54px; border-radius: 50%; display: flex; align-items: center; justify-content: center;
    font-size: 1.5rem; box-shadow: var(--shadow-lg); z-index: 60; animation: pulse 2.4s ease-in-out infinite;
}
@keyframes pulse { 0%,100% { box-shadow: 0 0 0 0 rgba(37,211,102,.35), var(--shadow-lg); } 50% { box-shadow: 0 0 0 10px rgba(37,211,102,0), var(--shadow-lg); } }

/* ---------- Misc pages ---------- */
.breadcrumb { font-size: .82rem; color: var(--text-muted); margin-bottom: 20px; }
.breadcrumb a { color: var(--gold); }
.empty-state { text-align: center; padding: 70px 20px; color: var(--text-muted); }
.pill { display: inline-block; padding: 3px 10px; border-radius: 999px; font-size: .72rem; font-weight: 700; font-family: var(--font-display); }
.pill-paid { background: var(--success-soft); color: var(--success); }
.pill-pending { background: var(--gold-soft); color: var(--gold); }
.pill-failed { background: var(--danger-soft); color: var(--danger); }
.pill-fulfilled { background: var(--success-soft); color: var(--success); }
/* Condition badge — styled like an actual price tag (pointed edge + punch hole),
   not a soft rounded pill, so "Brand new" / "Used" reads at a glance. */
.cond-tag {
    display: inline-flex; align-items: center; gap: 5px;
    font-size: .66rem; font-weight: 700; font-family: var(--font-display);
    text-transform: uppercase; letter-spacing: .03em;
    color: #fff; padding: 4px 10px 4px 16px;
    clip-path: polygon(9px 0, 100% 0, 100% 100%, 9px 100%, 0 50%);
}
.cond-tag::before {
    content: ''; position: absolute; left: 5px; top: 50%; width: 3px; height: 3px;
    background: rgba(255,255,255,.85); border-radius: 50%; transform: translateY(-50%);
}
.cond-tag { position: relative; }
.cond-tag.cond-new { background: var(--success); }
.cond-tag.cond-used { background: var(--gold); }
.table-wrap { overflow-x: auto; }
.two-col { display: grid; grid-template-columns: 1.5fr 1fr; gap: 40px; }
@media (max-width: 860px) { .two-col { grid-template-columns: 1fr; } }
.gallery-main { border: 1px solid var(--border); border-radius: var(--radius); overflow: hidden; background: var(--surface); aspect-ratio: 1/1; box-shadow: var(--shadow-sm); }
.gallery-main img { width: 100%; height: 100%; object-fit: cover; }
.gallery-main .no-image { height: 100%; display: flex; align-items: center; justify-content: center; color: var(--text-muted); }
.file-list { list-style: none; padding: 0; margin: 0; }
.file-list li { display: flex; justify-content: space-between; align-items: center; padding: 12px 14px; background: var(--surface); border: 1px solid var(--border); border-radius: 8px; margin-bottom: 10px; }

/* ---------------------------------------------------
   Variants, wishlist, 360 viewer, ratings & reviews
   --------------------------------------------------- */

/* Wishlist heart */
.wishlist-heart {
    background: var(--surface); border: 1px solid var(--border); border-radius: 999px;
    width: 34px; height: 34px; display: inline-flex; align-items: center; justify-content: center;
    font-size: 1rem; color: var(--text-muted); cursor: pointer; transition: all .15s; flex-shrink: 0;
}
.wishlist-heart:hover { border-color: var(--danger); color: var(--danger); }
.wishlist-heart.active { color: #fff; background: var(--danger); border-color: var(--danger); }
.wishlist-heart-lg { width: 42px; height: 42px; font-size: 1.2rem; }
.product-thumb .wishlist-heart { position: absolute; top: 10px; left: 10px; z-index: 3; }

/* Variant picker */
.variant-options { display: flex; flex-wrap: wrap; gap: 8px; }
.variant-pill {
    padding: 8px 16px; border: 1px solid var(--border); border-radius: 999px; background: var(--surface);
    font-size: .85rem; cursor: pointer; transition: all .15s; color: var(--ink);
}
.variant-pill:hover { border-color: var(--gold); }
.variant-pill.active { background: var(--ink); color: #fff; border-color: var(--ink); }
.variant-pill.out, .variant-pill:disabled { opacity: .45; text-decoration: line-through; cursor: not-allowed; }

/* 360 spin viewer */
.spin-viewer { position: relative; width: 100%; height: 100%; cursor: grab; user-select: none; touch-action: pan-y; }
.spin-viewer.dragging { cursor: grabbing; }
.spin-frame { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; opacity: 0; pointer-events: none; }
.spin-frame.active { opacity: 1; }
.spin-hint {
    position: absolute; bottom: 10px; left: 50%; transform: translateX(-50%);
    background: rgba(23,21,15,.7); color: #fff; font-size: .7rem; padding: 4px 10px; border-radius: 999px;
    pointer-events: none;
}
.gallery-thumbs-spin {
    width: 64px; height: 64px; border-radius: 8px; border: 2px solid var(--border);
    display: flex; align-items: center; justify-content: center; font-size: .72rem; font-weight: 700;
    color: var(--gold); background: var(--gold-soft); cursor: pointer; transition: border-color .15s;
}
.gallery-thumbs-spin.active, .gallery-thumbs-spin:hover { border-color: var(--gold); }

/* Ratings & stars */
.stars { color: var(--gold-hi); letter-spacing: 1px; }
.rating-summary { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.star-picker { font-size: 1.6rem; color: var(--border); margin-bottom: 12px; }
.star-picker span { cursor: pointer; transition: color .1s; }
.star-picker span.active { color: var(--gold-hi); }

/* Reviews */
.review-form-box {
    background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius);
    padding: 20px; margin-bottom: 26px; max-width: 560px; box-shadow: var(--shadow-sm);
}
.review-list { display: flex; flex-direction: column; gap: 16px; max-width: 720px; }
.review-card { border: 1px solid var(--border); border-radius: var(--radius); padding: 16px 18px; background: var(--surface); }
.review-thumb { width: 64px; height: 64px; object-fit: cover; border-radius: 8px; border: 1px solid var(--border); }

/* =====================================================================
   Buy/Sell intent gate — shown once per session on the homepage
   ===================================================================== */
.intent-gate {
    position: fixed; inset: 0; z-index: 200;
    background: rgba(23,21,15,.72);
    display: flex; align-items: center; justify-content: center;
    padding: 20px; opacity: 1; transition: opacity .2s ease;
}
.intent-gate.closing { opacity: 0; }
.intent-gate-card {
    position: relative; background: var(--surface); border-radius: var(--radius);
    box-shadow: var(--shadow-lg); padding: 32px 28px; max-width: 460px; width: 100%;
    text-align: center;
}
.intent-gate-card h2 { margin-bottom: 6px; }
.intent-gate-card > p { margin-bottom: 22px; }
.intent-gate-close {
    position: absolute; top: 12px; right: 14px; color: var(--text-muted);
    font-size: 1.1rem; text-decoration: none; line-height: 1;
}
.intent-gate-close:hover { color: var(--ink); }
.intent-gate-options { display: flex; flex-direction: column; gap: 12px; }
.intent-gate-btn {
    display: flex; flex-direction: column; align-items: center; gap: 4px;
    border: 1px solid var(--border); border-radius: var(--radius);
    padding: 18px 16px; text-decoration: none; color: var(--ink);
    transition: border-color .15s, transform .15s, background .15s;
}
.intent-gate-btn:hover { border-color: var(--gold); background: var(--gold-soft); transform: translateY(-1px); }
.intent-gate-btn span:nth-child(2) { font-weight: 700; font-size: 1.02rem; }
.intent-gate-icon {
    font-size: 1.6rem; width: 52px; height: 52px; border-radius: 50%;
    display: flex; align-items: center; justify-content: center;
    background: var(--cat-software-soft);
}
.intent-gate-btn small { color: var(--text-muted); font-size: .78rem; }
.intent-gate-btn-sell:hover { border-color: var(--gold); background: var(--gold-soft); }
.intent-gate-btn-sell .intent-gate-icon { background: var(--gold-soft); }

/* =====================================================================
   Bottom tab bar (mobile) — Home / Categories / Upload / Cart / Account
   ===================================================================== */
.bottom-nav { display: none; }

@media (max-width: 860px) {
    body.has-bottom-nav { padding-bottom: 66px; }
    .bottom-nav {
        display: flex; align-items: flex-end; justify-content: space-around;
        position: fixed; left: 0; right: 0; bottom: 0; z-index: 90;
        background: var(--surface); border-top: 1px solid var(--border);
        box-shadow: 0 -2px 10px rgba(23,21,15,.06);
        padding: 6px 4px calc(6px + env(safe-area-inset-bottom, 0px));
    }
    .bottom-nav-item {
        display: flex; flex-direction: column; align-items: center; gap: 2px;
        flex: 1; background: none; border: none; color: var(--text-muted);
        font-size: .66rem; font-weight: 600; text-decoration: none; cursor: pointer;
        padding: 4px 2px;
    }
    .bottom-nav-item.active { color: var(--gold); }
    .bottom-nav-icon { position: relative; font-size: 1.2rem; line-height: 1; }
    .bottom-nav-badge {
        position: absolute; top: -6px; right: -10px; background: var(--gold);
        color: #fff; font-size: .6rem; font-weight: 700; border-radius: 999px;
        min-width: 15px; height: 15px; display: flex; align-items: center; justify-content: center;
        padding: 0 3px;
    }
    .bottom-nav-upload { margin-top: -22px; }
    .bottom-nav-upload-icon {
        width: 44px; height: 44px; border-radius: 50%;
        background: var(--ink); color: #fff; font-size: 1.5rem; font-weight: 400;
        display: flex; align-items: center; justify-content: center;
        box-shadow: var(--shadow-md); margin-bottom: 2px;
    }
    .bottom-nav-upload span:last-child { color: var(--ink); }

    /* keep the WhatsApp float button clear of the bottom bar */
    .wa-float { bottom: 78px; }
}

/* =====================================================================
   Homepage hero — search-first, no logo/branding inside the block itself
   ===================================================================== */
.home-hero {
    padding: 34px 0 30px;
    background:
        linear-gradient(180deg, rgba(23,21,15,.55), rgba(23,21,15,.72)),
        url('/assets/images/hero-shop-1.jpg') center 35% / cover no-repeat;
    color: #fff;
}
.home-hero .container { position: relative; z-index: 1; }
.home-hero h1 {
    color: #fff; font-size: 1.5rem; text-align: center; margin-bottom: 18px;
    font-family: var(--font-display);
}
.home-hero-search {
    display: flex; max-width: 460px; margin: 0 auto;
    background: #fff; border-radius: 12px; padding: 6px 6px 6px 18px; box-shadow: var(--shadow-md);
}
.home-hero-search input[type=text] {
    border: none; background: none; flex: 1; min-width: 0; font-size: .95rem; color: var(--ink);
    padding: 10px 0;
}
.home-hero-search input[type=text]:focus { outline: none; }
.home-hero-search input[type=text]::placeholder { color: var(--text-muted); }
.home-hero-search button {
    border: none; background: var(--ink); color: #fff; border-radius: 8px;
    width: 42px; height: 42px; font-size: 1.05rem; cursor: pointer; flex-shrink: 0;
    display: flex; align-items: center; justify-content: center; transition: background .15s;
}
.home-hero-search button:hover { background: var(--gold); }

@media (max-width: 560px) {
    .home-hero h1 { font-size: 1.2rem; }
}

/* ---------- Quick action tiles ---------- */
.quick-actions { display: flex; gap: 12px; overflow-x: auto; padding-bottom: 4px; scrollbar-width: thin; }
.quick-action-card {
    flex: 1 1 140px; min-width: 130px; border-radius: var(--radius);
    padding: 18px 14px; text-align: center; text-decoration: none; color: var(--ink);
    display: flex; flex-direction: column; align-items: center; gap: 8px;
    font-weight: 600; font-size: .85rem; font-family: var(--font-display);
    transition: transform .15s;
}
.quick-action-card:hover { transform: translateY(-2px); }
.quick-action-icon {
    font-size: 1.6rem; width: 40px; height: 40px; display: flex; align-items: center;
    justify-content: center; border-radius: 12px; overflow: hidden;
}
.quick-action-icon img { width: 100%; height: 100%; object-fit: cover; display: block; }
.qa-sell   { background: var(--gold-soft); }
.qa-browse { background: var(--cat-software-soft); }
.qa-orders { background: var(--cat-templates-soft); }
.qa-saved  { background: var(--cat-stems-soft); }

/* ---------- Category grid (icon tiles) ---------- */
.category-grid {
    display: grid; grid-template-columns: repeat(auto-fill, minmax(110px, 1fr)); gap: 14px;
}
.category-tile {
    display: flex; flex-direction: column; align-items: center; gap: 8px;
    text-decoration: none; color: var(--ink); font-weight: 600; font-size: .82rem;
    font-family: var(--font-display); text-align: center;
}
.category-tile-icon {
    width: 56px; height: 56px; border-radius: 16px; background: var(--chip-soft, var(--surface-2));
    display: flex; align-items: center; justify-content: center; font-size: 1.5rem;
    transition: transform .15s; overflow: hidden;
}
.category-tile-icon img { width: 100%; height: 100%; object-fit: cover; display: block; }
.category-tile:hover .category-tile-icon { transform: translateY(-2px); }

@media (max-width: 560px) {
    .category-grid { grid-template-columns: repeat(3, 1fr); gap: 8px 6px; }
    .category-tile { font-size: .74rem; gap: 6px; }
    .category-tile-icon { width: 100%; height: auto; aspect-ratio: 1 / 1; border-radius: 14px; }
}

/* =====================================================================
   Account / profile page
   ===================================================================== */
.profile-head {
    display: flex; align-items: center; gap: 14px; margin-bottom: 20px; position: relative;
}
.profile-head-link {
    display: flex; align-items: center; gap: 14px; flex: 1; min-width: 0;
    text-decoration: none; color: inherit;
}
.profile-head img, .profile-head-placeholder {
    width: 56px; height: 56px; border-radius: 50%; object-fit: cover; flex-shrink: 0;
}
.profile-head-placeholder {
    background: var(--surface-2); display: flex; align-items: center; justify-content: center;
    font-size: 1.5rem; color: var(--text-muted);
}
.profile-head h1 { font-size: 1.2rem; flex: 1; min-width: 0; }
.profile-head-link:hover h1 { text-decoration: underline; }
.profile-head-settings {
    font-size: 1.2rem; text-decoration: none; color: var(--text-muted); flex-shrink: 0;
}

.profile-alerts { border-radius: var(--radius); overflow: hidden; margin-bottom: 22px; background: var(--gold); }
.profile-alerts-head {
    display: flex; justify-content: space-between; align-items: center;
    padding: 10px 16px; color: #fff; font-weight: 700; font-size: .85rem;
}
.profile-alerts-head button {
    background: none; border: none; color: rgba(255,255,255,.9); font-size: .78rem; cursor: pointer; text-decoration: underline;
}
.profile-alert-card {
    display: flex; justify-content: space-between; align-items: center; gap: 10px;
    background: #fff; margin: 0 6px 6px; padding: 12px 14px; border-radius: 10px;
    text-decoration: none; color: var(--ink); font-size: .82rem;
}
.profile-alert-card:last-child { margin-bottom: 6px; }
.profile-alert-error b { color: var(--danger); }
.profile-alert-warn b { color: var(--gold); }
.profile-alert-card span:last-child { color: var(--text-muted); font-size: 1.1rem; }

.profile-tiles {
    display: grid; grid-template-columns: 1fr 1fr; gap: 10px;
}
.profile-tile {
    display: flex; align-items: center; gap: 10px;
    background: var(--surface); border: 1px solid var(--border); border-radius: 10px;
    padding: 14px 12px; text-decoration: none; color: var(--ink); font-weight: 600; font-size: .85rem;
}
.profile-tile-icon { font-size: 1.15rem; }
.profile-tile-stat { flex-direction: column; align-items: flex-start; gap: 2px; }
.profile-tile-stat span { font-size: 1.1rem; font-weight: 700; }
.profile-tile-stat small { color: var(--text-muted); font-size: .68rem; letter-spacing: .04em; }

/* =====================================================================
   Seller dashboard — sidebar + "My products" ad-card list
   ===================================================================== */
.seller-dash { display: flex; gap: 28px; align-items: flex-start; }
.seller-dash-side { flex: 0 0 260px; }
.seller-dash-main { flex: 1; min-width: 0; }

@media (max-width: 860px) {
    .seller-dash { flex-direction: column; }
    .seller-dash-side { flex: 1 1 auto; width: 100%; }
}

.seller-dash-tabs { display: flex; gap: 4px; flex-wrap: wrap; }
.seller-dash-tabs a {
    padding: 7px 14px; border-radius: 999px; font-size: .82rem; font-weight: 600;
    color: var(--text-muted); text-decoration: none; background: var(--surface-2);
}
.seller-dash-tabs a.active { background: var(--ink); color: #fff; }

.seller-ad-list { display: flex; flex-direction: column; gap: 12px; }
.seller-ad-card {
    display: flex; gap: 14px; border: 1px solid var(--border); border-radius: var(--radius);
    padding: 14px; background: var(--surface);
}
.seller-ad-card img, .seller-ad-card-noimg {
    width: 84px; height: 84px; border-radius: 10px; object-fit: cover; flex-shrink: 0;
}
.seller-ad-card-noimg {
    background: var(--surface-2); display: flex; align-items: center; justify-content: center; font-size: 1.6rem;
}
.seller-ad-card-body { flex: 1; min-width: 0; }
.seller-ad-card-stats {
    display: flex; gap: 14px; font-size: .78rem; color: var(--text-muted); margin-top: 8px; flex-wrap: wrap;
}
.seller-ad-card-actions { display: flex; gap: 14px; margin-top: 10px; }
.seller-ad-card-actions a { font-size: .82rem; font-weight: 600; text-decoration: none; color: var(--gold); }

.badge-success, .badge-warn, .badge-error {
    display: inline-block; padding: 4px 11px; border-radius: 999px; font-size: .72rem;
    font-weight: 700; font-family: var(--font-display); white-space: nowrap;
}
.badge-success { background: var(--success-soft); color: var(--success); }
.badge-warn    { background: var(--gold-soft); color: var(--gold); }
.badge-error   { background: var(--danger-soft); color: var(--danger); }

/* =====================================================================
   Avatar picker + crop modal
   ===================================================================== */
.avatar-picker { display: flex; align-items: center; gap: 16px; }
.avatar-picker-preview {
    width: 72px; height: 72px; border-radius: 50%; overflow: hidden; flex-shrink: 0;
    background: var(--surface-2); display: flex; align-items: center; justify-content: center;
    font-size: 1.6rem; color: var(--text-muted);
}
.avatar-picker-preview img { width: 100%; height: 100%; object-fit: cover; }

.avatar-crop-modal {
    display: none; position: fixed; inset: 0; z-index: 300; background: rgba(23,21,15,.75);
    align-items: center; justify-content: center; padding: 20px;
}
.avatar-crop-modal.open { display: flex; }
.avatar-crop-modal-inner {
    background: #fff; border-radius: var(--radius); padding: 22px; max-width: 440px; width: 100%;
}
.avatar-crop-modal-inner h3 { font-size: 1rem; margin-bottom: 14px; }
.avatar-crop-canvas-wrap { max-height: 360px; overflow: hidden; background: #000; border-radius: 8px; }
.avatar-crop-actions { display: flex; justify-content: flex-end; gap: 10px; margin-top: 16px; }
/* Round the crop viewport so it's obvious this becomes a circular avatar */
.avatar-crop-canvas-wrap .cropper-view-box,
.avatar-crop-canvas-wrap .cropper-face { border-radius: 50%; }

/* ---------- Multi-select category checkboxes ---------- */
.category-checklist { display: flex; flex-direction: column; gap: 8px; }
.category-checklist label {
    display: flex; align-items: center; gap: 10px; font-weight: 500; font-size: .9rem;
    padding: 9px 12px; border: 1px solid var(--border); border-radius: 8px; cursor: pointer;
}
.category-checklist input[type=checkbox] { width: 16px; height: 16px; flex-shrink: 0; }