/* ===== CSS Variables ===== */
:root {
    --primary:     #FF6B35;
    --primary-dark:#e8531f;
    --secondary:   #4ECDC4;
    --dark:        #2D3436;
    --medium:      #636e72;
    --light:       #F8F9FA;
    --border:      #e0e0e0;
    --white:       #ffffff;
    --danger:      #e74c3c;
    --success:     #27ae60;
    --warning:     #f39c12;
    --info:        #3498db;
    --radius:      12px;
    --radius-sm:   6px;
    --shadow:      0 2px 12px rgba(0,0,0,.08);
    --shadow-md:   0 4px 24px rgba(0,0,0,.12);
    --font:        'Nunito', 'Segoe UI', system-ui, sans-serif;
}

/* ===== Reset & Base ===== */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body {
    font-family: var(--font);
    color: var(--dark);
    background: var(--white);
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
}
a { color: var(--primary); text-decoration: none; }
a:hover { text-decoration: underline; }
img { max-width: 100%; display: block; }

/* ===== Container ===== */
.container { max-width: 1200px; margin: 0 auto; padding: 0 1.25rem; }

/* ===== Buttons ===== */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: .4rem;
    padding: .6rem 1.4rem;
    border-radius: var(--radius-sm);
    border: 2px solid transparent;
    font-family: var(--font);
    font-size: .95rem;
    font-weight: 700;
    cursor: pointer;
    transition: all .18s ease;
    text-decoration: none;
    white-space: nowrap;
    line-height: 1.4;
}
.btn:hover { text-decoration: none; opacity: .92; }
.btn-primary   { background: var(--primary); color: #fff; border-color: var(--primary); }
.btn-primary:hover { background: var(--primary-dark); border-color: var(--primary-dark); }
.btn-secondary { background: var(--secondary); color: #fff; border-color: var(--secondary); }
.btn-ghost     { background: transparent; color: var(--dark); border-color: var(--border); }
.btn-ghost:hover { background: var(--light); }
.btn-danger    { background: var(--danger); color: #fff; border-color: var(--danger); }
.btn-lg  { padding: .85rem 2rem; font-size: 1.05rem; border-radius: var(--radius-sm); }
.btn-sm  { padding: .4rem 1rem; font-size: .88rem; }
.btn-xs  { padding: .28rem .7rem; font-size: .8rem; }
.btn-full { width: 100%; margin-top: .5rem; }

/* ===== Header ===== */
.site-header {
    background: var(--white);
    border-bottom: 2px solid var(--border);
    position: sticky;
    top: 0;
    z-index: 100;
    box-shadow: 0 2px 8px rgba(0,0,0,.06);
}
.site-header .container {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding-top: .85rem;
    padding-bottom: .85rem;
}
.logo {
    display: flex;
    align-items: center;
    gap: .5rem;
    font-size: 1.35rem;
    font-weight: 900;
    color: var(--dark);
    text-decoration: none;
    flex-shrink: 0;
}
.logo:hover { text-decoration: none; opacity: .85; }
.logo-icon { font-size: 1.5rem; }
.logo-text { color: var(--primary); }

.main-nav {
    display: flex;
    align-items: center;
    gap: .5rem;
    margin-left: auto;
}
.nav-link {
    padding: .45rem .9rem;
    border-radius: var(--radius-sm);
    font-weight: 700;
    color: var(--dark);
    text-decoration: none;
    transition: .15s;
    position: relative;
}
.nav-link:hover, .nav-link.active { background: var(--light); color: var(--primary); text-decoration: none; }
.cart-link { position: relative; }
.cart-badge {
    position: absolute;
    top: -.3rem;
    right: -.3rem;
    background: var(--primary);
    color: #fff;
    border-radius: 999px;
    font-size: .7rem;
    font-weight: 900;
    min-width: 18px;
    height: 18px;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0 4px;
}
.mobile-menu-btn { display: none; }

/* ===== Hero ===== */
.hero {
    background: linear-gradient(135deg, #fff8f5 0%, #e8faf9 100%);
    padding: 4rem 0 3rem;
    overflow: hidden;
}
.hero .container {
    display: flex;
    align-items: center;
    gap: 2rem;
}
.hero-content { flex: 1; }
.hero-title {
    font-size: clamp(2rem, 5vw, 3.2rem);
    font-weight: 900;
    color: var(--dark);
    line-height: 1.15;
    margin-bottom: .75rem;
}
.hero-title span { color: var(--primary); }
.hero-subtitle {
    font-size: 1.1rem;
    color: var(--medium);
    margin-bottom: 1.75rem;
    max-width: 460px;
}
.hero-visual {
    flex: 1;
    max-width: 420px;
    position: relative;
    height: 280px;
    display: flex;
    align-items: center;
    justify-content: center;
}
.hero-blobs { position: absolute; inset: 0; }
.blob {
    position: absolute;
    border-radius: 50%;
    opacity: .25;
}
.blob-1 { width: 240px; height: 240px; background: var(--primary); top: 0; left: 20%; animation: blobFloat 6s ease-in-out infinite; }
.blob-2 { width: 160px; height: 160px; background: var(--secondary); bottom: 0; right: 10%; animation: blobFloat 7s ease-in-out infinite .5s; }
.blob-3 { width: 100px; height: 100px; background: #FFEAA7; top: 50%; left: 5%; animation: blobFloat 8s ease-in-out infinite 1s; }
@keyframes blobFloat {
    0%, 100% { transform: translateY(0) scale(1); }
    50% { transform: translateY(-18px) scale(1.04); }
}
.hero-icons {
    position: relative;
    font-size: 3rem;
    display: flex;
    gap: 1.5rem;
    flex-wrap: wrap;
    justify-content: center;
    animation: heroIconsSpin 20s linear infinite;
}
@keyframes heroIconsSpin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}
.hero-icons span {
    display: inline-block;
    animation: heroIconsSpin 20s linear infinite reverse;
}

/* ===== Shop Section ===== */
.shop-section { padding: 3rem 0 4rem; }
.section-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    margin-bottom: 2rem;
    flex-wrap: wrap;
}
.section-header h2 { font-size: 1.8rem; font-weight: 900; }
.search-form { display: flex; gap: .5rem; }
.search-input {
    padding: .55rem 1rem;
    border: 2px solid var(--border);
    border-radius: var(--radius-sm);
    font-family: var(--font);
    font-size: .95rem;
    width: 220px;
}
.search-input:focus { outline: none; border-color: var(--primary); }

/* ===== Toys Grid ===== */
.toys-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
    gap: 1.5rem;
}
.toy-card {
    background: var(--white);
    border: 2px solid var(--border);
    border-radius: var(--radius);
    overflow: hidden;
    transition: transform .2s, box-shadow .2s, border-color .2s;
    position: relative;
}
.toy-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-md);
    border-color: var(--primary);
}
.toy-badge {
    position: absolute;
    top: .75rem;
    left: .75rem;
    background: var(--primary);
    color: #fff;
    font-size: .75rem;
    font-weight: 800;
    padding: .2rem .6rem;
    border-radius: 999px;
    z-index: 1;
    text-transform: uppercase;
    letter-spacing: .04em;
}
.toy-card-img-wrap {
    display: block;
    aspect-ratio: 1;
    overflow: hidden;
    background: var(--light);
}
.toy-card-img-wrap img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform .3s;
}
.toy-card:hover .toy-card-img-wrap img { transform: scale(1.05); }
.toy-placeholder {
    width: 100%;
    aspect-ratio: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 4rem;
    background: var(--light);
}
.toy-card-body { padding: 1rem; }
.toy-name { font-size: 1rem; font-weight: 800; margin-bottom: .3rem; }
.toy-name a { color: var(--dark); }
.toy-name a:hover { color: var(--primary); text-decoration: none; }
.toy-desc { font-size: .85rem; color: var(--medium); margin-bottom: .75rem; line-height: 1.5; }
.toy-meta {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: .75rem;
}
.toy-price { font-size: 1.15rem; font-weight: 900; color: var(--primary); }
.toy-colors-count { font-size: .8rem; color: var(--medium); background: var(--light); padding: .2rem .6rem; border-radius: 999px; }

/* ===== Empty State ===== */
.empty-state {
    text-align: center;
    padding: 4rem 1rem;
    color: var(--medium);
}
.empty-icon { font-size: 4rem; display: block; margin-bottom: 1rem; }
.empty-state p { font-size: 1.1rem; margin-bottom: 1.25rem; }

/* ===== Alerts ===== */
.alert {
    padding: .85rem 1.1rem;
    border-radius: var(--radius-sm);
    margin-bottom: 1.25rem;
    font-weight: 600;
    font-size: .95rem;
}
.alert-success { background: #d4edda; color: #155724; border: 1px solid #c3e6cb; }
.alert-danger   { background: #f8d7da; color: #721c24; border: 1px solid #f5c6cb; }
.alert-warning  { background: #fff3cd; color: #856404; border: 1px solid #ffeeba; }
.alert-info     { background: #d1ecf1; color: #0c5460; border: 1px solid #bee5eb; }

/* ===== Breadcrumb ===== */
.breadcrumb {
    font-size: .9rem;
    color: var(--medium);
    margin: 1.5rem 0 1rem;
}
.breadcrumb a { color: var(--medium); }
.breadcrumb a:hover { color: var(--primary); }
.breadcrumb span { margin: 0 .5rem; }

/* ===== Product Gallery ===== */
.product-gallery { display: flex; flex-direction: column; gap: .75rem; }
.gallery-main-wrap {
    border-radius: var(--radius);
    overflow: hidden;
    border: 2px solid var(--border);
    background: var(--light);
    aspect-ratio: 1;
}
.gallery-main-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: opacity .2s;
}
.gallery-main-img.switching { opacity: 0; }
.gallery-thumbs {
    display: flex;
    gap: .5rem;
    flex-wrap: wrap;
}
.gallery-thumb {
    width: 72px;
    height: 72px;
    border-radius: var(--radius-sm);
    overflow: hidden;
    border: 2px solid var(--border);
    cursor: pointer;
    padding: 0;
    background: var(--light);
    transition: border-color .15s, transform .15s;
    flex-shrink: 0;
}
.gallery-thumb img { width: 100%; height: 100%; object-fit: cover; }
.gallery-thumb:hover { border-color: var(--primary); transform: translateY(-2px); }
.gallery-thumb.active { border-color: var(--primary); box-shadow: 0 0 0 2px var(--primary); }

/* ===== Product Page ===== */
.product-layout {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 3rem;
    margin-bottom: 3rem;
}
.product-image-wrap {
    border-radius: var(--radius);
    overflow: hidden;
    border: 2px solid var(--border);
    background: var(--light);
    aspect-ratio: 1;
}
.product-image { width: 100%; height: 100%; object-fit: cover; }
.product-placeholder {
    width: 100%;
    aspect-ratio: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 8rem;
    background: var(--light);
}
.product-title { font-size: 2rem; font-weight: 900; margin-bottom: .5rem; }
.product-price { font-size: 1.8rem; font-weight: 900; color: var(--primary); margin-bottom: 1rem; }
.product-description {
    color: var(--medium);
    margin-bottom: 1.5rem;
    line-height: 1.7;
    font-size: .97rem;
}
.form-group { margin-bottom: 1.25rem; }
.form-label { display: block; font-weight: 700; margin-bottom: .5rem; font-size: .95rem; }
.form-control {
    width: 100%;
    padding: .65rem .9rem;
    border: 2px solid var(--border);
    border-radius: var(--radius-sm);
    font-family: var(--font);
    font-size: .95rem;
    transition: border-color .15s;
    background: var(--white);
}
.form-control:focus { outline: none; border-color: var(--primary); }

/* ===== Color Swatches ===== */
.color-swatches { display: flex; flex-wrap: wrap; gap: .6rem; }
.color-swatch-label {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: .3rem;
    cursor: pointer;
}
.color-swatch-label input[type="radio"] { display: none; }
.color-swatch {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    border: 3px solid transparent;
    transition: all .15s;
    box-shadow: 0 0 0 2px var(--border);
    cursor: pointer;
}
.color-swatch-label input:checked + .color-swatch {
    box-shadow: 0 0 0 3px var(--primary);
    transform: scale(1.15);
}
.color-name { font-size: .78rem; font-weight: 700; color: var(--medium); }

/* ===== Qty Control ===== */
.qty-control {
    display: inline-flex;
    align-items: center;
    border: 2px solid var(--border);
    border-radius: var(--radius-sm);
    overflow: hidden;
}
.qty-btn {
    background: var(--light);
    border: none;
    padding: .5rem .85rem;
    font-size: 1.1rem;
    font-weight: 700;
    cursor: pointer;
    transition: background .15s;
    font-family: var(--font);
}
.qty-btn:hover { background: var(--border); }
.qty-input {
    border: none;
    width: 52px;
    text-align: center;
    font-size: .95rem;
    font-weight: 700;
    font-family: var(--font);
    padding: .5rem 0;
    -moz-appearance: textfield;
}
.qty-input::-webkit-inner-spin-button { display: none; }

.product-badges {
    display: flex;
    flex-wrap: wrap;
    gap: .5rem;
    margin-top: 1.25rem;
    font-size: .82rem;
    color: var(--medium);
}
.product-badges span {
    background: var(--light);
    border: 1px solid var(--border);
    border-radius: 999px;
    padding: .25rem .7rem;
}

/* ===== Cart ===== */
.page-title { font-size: 2rem; font-weight: 900; margin: 1.5rem 0; }
.cart-layout {
    display: grid;
    grid-template-columns: 1fr 320px;
    gap: 2rem;
    margin-bottom: 3rem;
    align-items: start;
}
.cart-item {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 1rem;
    border: 2px solid var(--border);
    border-radius: var(--radius);
    margin-bottom: .75rem;
    background: var(--white);
}
.cart-item-img { width: 80px; height: 80px; flex-shrink: 0; border-radius: var(--radius-sm); overflow: hidden; background: var(--light); }
.cart-item-img img { width: 100%; height: 100%; object-fit: cover; }
.cart-placeholder { width: 100%; height: 100%; display: flex; align-items: center; justify-content: center; font-size: 2rem; }
.cart-item-info { flex: 1; min-width: 0; }
.cart-item-name { font-weight: 800; margin-bottom: .2rem; }
.cart-item-color { display: flex; align-items: center; gap: .4rem; font-size: .85rem; color: var(--medium); }
.color-dot { width: 14px; height: 14px; border-radius: 50%; flex-shrink: 0; border: 1px solid rgba(0,0,0,.12); }
.cart-item-price { font-size: .85rem; color: var(--medium); margin-top: .2rem; }
.cart-item-actions { display: flex; flex-direction: column; align-items: flex-end; gap: .5rem; }
.cart-item-subtotal { font-weight: 900; color: var(--primary); font-size: 1.05rem; }
.btn-remove { background: none; border: none; font-size: 1rem; cursor: pointer; color: var(--medium); padding: .2rem .4rem; border-radius: 4px; }
.btn-remove:hover { color: var(--danger); background: #fde8e8; }

.cart-summary {
    background: var(--white);
    border: 2px solid var(--border);
    border-radius: var(--radius);
    padding: 1.5rem;
    position: sticky;
    top: 90px;
}
.cart-summary h2 { font-size: 1.2rem; font-weight: 900; margin-bottom: 1rem; }
.summary-row { display: flex; justify-content: space-between; padding: .5rem 0; border-bottom: 1px solid var(--border); font-size: .95rem; }
.summary-total { font-weight: 900; font-size: 1.05rem; color: var(--primary); border-bottom: none; }
.text-muted { color: var(--medium); font-size: .88rem; }

/* ===== Checkout ===== */
.checkout-layout {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 2rem;
    margin-bottom: 3rem;
    align-items: start;
}
.checkout-items {
    background: var(--white);
    border: 2px solid var(--border);
    border-radius: var(--radius);
    padding: 1.5rem;
}
.checkout-items h2 { font-size: 1.2rem; font-weight: 900; margin-bottom: 1rem; }
.checkout-item {
    display: flex;
    gap: 1rem;
    padding: .75rem 0;
    border-bottom: 1px solid var(--border);
    align-items: center;
}
.checkout-item:last-of-type { border-bottom: none; }
.checkout-item-img { width: 56px; height: 56px; flex-shrink: 0; border-radius: var(--radius-sm); overflow: hidden; background: var(--light); }
.checkout-item-img img { width: 100%; height: 100%; object-fit: cover; }
.checkout-item-info { flex: 1; }
.checkout-item-name { font-weight: 800; font-size: .95rem; }
.checkout-item-qty { font-size: .82rem; color: var(--medium); }
.checkout-item-price { font-weight: 900; font-size: .95rem; color: var(--primary); }
.checkout-total { margin-top: 1rem; font-size: 1.1rem; text-align: right; padding-top: .75rem; border-top: 2px solid var(--border); }
.checkout-payment {
    background: var(--white);
    border: 2px solid var(--border);
    border-radius: var(--radius);
    padding: 1.5rem;
    position: sticky;
    top: 90px;
}
.checkout-payment h2 { font-size: 1.2rem; font-weight: 900; margin-bottom: .75rem; }
.payment-note { color: var(--medium); font-size: .9rem; margin-bottom: 1.25rem; }
.payment-tabs { display: flex; gap: .5rem; margin-bottom: 1.25rem; border-bottom: 2px solid var(--border); padding-bottom: 0; }
.payment-tab { background: none; border: none; border-bottom: 3px solid transparent; margin-bottom: -2px; padding: .5rem 1rem; font-family: var(--font); font-size: .9rem; font-weight: 700; color: var(--medium); cursor: pointer; transition: color .15s, border-color .15s; }
.payment-tab:hover { color: var(--dark); }
.payment-tab.active { color: var(--primary); border-bottom-color: var(--primary); }
.payment-panel.hidden { display: none; }
.btn-full { width: 100%; }
#paypal-button-container { min-height: 50px; }

/* ===== Success Page ===== */
.success-page {
    text-align: center;
    padding: 4rem 1rem;
    max-width: 480px;
    margin: 0 auto;
}
.success-icon { font-size: 5rem; margin-bottom: 1rem; animation: bounce .7s ease; }
@keyframes bounce { 0%,100%{transform:scale(1)} 50%{transform:scale(1.2)} }
.success-page h1 { font-size: 2.2rem; font-weight: 900; margin-bottom: .75rem; }
.success-msg { font-size: 1.1rem; color: var(--medium); margin-bottom: .5rem; }
.order-ref { font-size: 1rem; margin-bottom: 1.5rem; color: var(--medium); }

/* ===== Footer ===== */
.site-footer {
    background: var(--dark);
    color: rgba(255,255,255,.75);
    padding: 2.5rem 0;
    margin-top: auto;
}
.footer-inner { text-align: center; }
.footer-brand { font-size: 1.2rem; font-weight: 900; color: var(--white); margin-bottom: .3rem; }
.footer-tagline { font-size: .9rem; margin-bottom: .5rem; }
.footer-copy { font-size: .82rem; opacity: .6; }

/* ===== Admin Login ===== */
.admin-login-body {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, #f5f7fa, #e8f4f3);
}
.login-box {
    background: var(--white);
    border-radius: var(--radius);
    padding: 2.5rem;
    box-shadow: var(--shadow-md);
    width: 100%;
    max-width: 380px;
}
.login-logo { text-align: center; font-size: 3rem; margin-bottom: .5rem; }
.login-box h1 { text-align: center; font-weight: 900; margin-bottom: 1.5rem; }

/* ===== Site Main ===== */
.site-main { min-height: calc(100vh - 200px); }

/* ===== Responsive ===== */

/* Tablet */
@media (max-width: 900px) {
    .product-layout { gap: 2rem; }
    .cart-layout { grid-template-columns: 1fr 280px; }
}

/* Mobile — hamburger nav */
@media (max-width: 680px) {
    .mobile-menu-btn {
        display: flex;
        flex-direction: column;
        justify-content: center;
        gap: 5px;
        background: none;
        border: none;
        cursor: pointer;
        padding: .4rem;
        margin-left: auto;
        flex-shrink: 0;
    }
    .mobile-menu-btn span {
        display: block;
        width: 24px;
        height: 2.5px;
        background: var(--dark);
        border-radius: 2px;
        transition: transform .2s, opacity .2s;
    }
    .mobile-menu-btn.open span:nth-child(1) { transform: translateY(7.5px) rotate(45deg); }
    .mobile-menu-btn.open span:nth-child(2) { opacity: 0; }
    .mobile-menu-btn.open span:nth-child(3) { transform: translateY(-7.5px) rotate(-45deg); }

    .site-header { position: sticky; top: 0; }
    .site-header .container { flex-wrap: wrap; padding-top: .75rem; padding-bottom: .75rem; }

    .main-nav {
        display: none;
        width: 100%;
        flex-direction: column;
        gap: .25rem;
        padding: .5rem 0 .75rem;
        border-top: 1px solid var(--border);
        margin-top: .5rem;
    }
    .main-nav.open { display: flex; }
    .nav-link { padding: .75rem .5rem; font-size: 1rem; border-radius: var(--radius-sm); }

    /* Hero */
    .hero { padding: 2.5rem 0 2rem; }
    .hero .container { flex-direction: column; text-align: center; }
    .hero-visual { display: none; }
    .hero-subtitle { max-width: 100%; margin-left: auto; margin-right: auto; }
    .hero-content .btn { width: 100%; justify-content: center; }

    /* Shop */
    .shop-section { padding: 2rem 0 3rem; }
    .section-header { flex-direction: column; align-items: flex-start; gap: .75rem; }
    .search-form { width: 100%; }
    .search-input { flex: 1; width: auto; }

    /* Toys grid — 2 columns */
    .toys-grid { grid-template-columns: repeat(2, 1fr); gap: .75rem; }
    .toy-card-body { padding: .75rem; }
    .toy-name { font-size: .92rem; }
    .toy-desc { display: none; }
    .toy-meta { flex-direction: column; align-items: flex-start; gap: .25rem; }

    /* Product page */
    .product-layout { grid-template-columns: 1fr; gap: 1.5rem; margin-bottom: 2rem; }
    .product-title { font-size: 1.5rem; }
    .product-price { font-size: 1.4rem; }
    .color-swatch { width: 44px; height: 44px; } /* bigger tap targets */

    /* Qty control — bigger tap targets */
    .qty-btn { padding: .65rem 1rem; font-size: 1.2rem; }
    .qty-input { width: 56px; font-size: 1rem; }

    /* Cart */
    .page-title { font-size: 1.5rem; margin: 1rem 0; }
    .cart-layout { grid-template-columns: 1fr; gap: 1.25rem; }
    .cart-summary { position: static; }
    .cart-item { gap: .75rem; }
    .cart-item-img { width: 64px; height: 64px; }
    .cart-item-actions { flex-direction: row; align-items: center; flex-wrap: wrap; gap: .5rem; margin-top: .5rem; width: 100%; justify-content: space-between; }
    .cart-item-subtotal { font-size: 1rem; }

    /* Checkout */
    .checkout-layout { grid-template-columns: 1fr; gap: 1.25rem; }
    .checkout-payment { position: static; }

    /* Login box */
    .login-box { padding: 1.75rem 1.25rem; margin: 1rem; }
}

/* Small phones */
@media (max-width: 380px) {
    .toys-grid { grid-template-columns: 1fr; }
    .hero-title { font-size: 1.75rem; }
}

/* ── Category chip filter bar ───────────────────────────────────────── */
.category-chips {
    display: flex;
    gap: .55rem;
    flex-wrap: wrap;
    padding: .25rem 0 .25rem;
    margin: -.75rem 0 2rem;
}
.category-chips .chip {
    flex: 0 0 auto;
    display: inline-flex;
    align-items: center;
    padding: .5rem 1.15rem;
    border-radius: 999px;
    background: var(--white);
    color: var(--dark);
    text-decoration: none;
    font-family: var(--font);
    font-weight: 700;
    font-size: .92rem;
    line-height: 1;
    border: 2px solid var(--border);
    transition: transform .15s ease, background .15s ease, color .15s ease,
                border-color .15s ease, box-shadow .15s ease;
    white-space: nowrap;
    user-select: none;
}
.category-chips .chip:hover {
    border-color: var(--primary);
    color: var(--primary);
    text-decoration: none;
    transform: translateY(-1px);
}
.category-chips .chip.is-active {
    background: var(--primary);
    color: #fff;
    border-color: var(--primary);
    box-shadow: 0 4px 12px rgba(255,107,53,.28);
}
.category-chips .chip.is-active:hover {
    background: var(--primary-dark);
    border-color: var(--primary-dark);
    color: #fff;
}
.category-chips .chip:focus-visible {
    outline: 3px solid rgba(255,107,53,.35);
    outline-offset: 2px;
}
/* Mobile: let chips wrap, keep them tappable */
@media (max-width: 560px) {
    .category-chips { gap: .45rem; margin: -.5rem 0 1.25rem; }
    .category-chips .chip { padding: .45rem .9rem; font-size: .88rem; }
}

/* ── Product page category strip ──────────────────────────────────── */
.product-categories {
    display: flex;
    flex-wrap: wrap;
    gap: .4rem;
    margin: .5rem 0 1.25rem;
}
.product-categories a {
    display: inline-flex;
    align-items: center;
    padding: .3rem .85rem;
    border-radius: 999px;
    background: var(--light);
    border: 1px solid var(--border);
    color: var(--medium);
    font-size: .82rem;
    font-weight: 700;
    text-decoration: none;
    transition: background .15s ease, color .15s ease, border-color .15s ease;
}
.product-categories a:hover {
    background: var(--primary);
    border-color: var(--primary);
    color: #fff;
    text-decoration: none;
}
