:root {
    --brand-red: #B5121B;
    --brand-red-dark: #8E0E16;
    --brand-red-light: #D41820;
    --brand-gold: #C9922E;
    --brand-gold-light: #E8C876;
    --brand-gold-dark: #9A7020;
    --brand-black: #141414;
    --brand-charcoal: #1F1F1F;
    --brand-cream: #FAF8F5;
    --brand-warm: #F3F0EB;
    --brand-border: #E8E2D9;
}

body { font-family: 'Plus Jakarta Sans', system-ui, sans-serif; background: var(--brand-cream); color: #2a2a2a; }
.font-display { font-family: 'Cormorant Garamond', Georgia, serif; }

.btn-primary {
    display: inline-flex; align-items: center; justify-content: center; gap: .5rem;
    border-radius: .5rem; background: linear-gradient(135deg, var(--brand-red) 0%, var(--brand-red-dark) 100%);
    padding: .75rem 1.5rem; font-size: .875rem; font-weight: 600; color: #fff;
    box-shadow: 0 4px 14px rgba(181, 18, 27, .35); transition: all .2s;
}
.btn-primary:hover { transform: translateY(-1px); box-shadow: 0 6px 20px rgba(181, 18, 27, .45); }

.btn-gold {
    display: inline-flex; align-items: center; justify-content: center; gap: .5rem;
    border-radius: .5rem; background: linear-gradient(135deg, var(--brand-gold) 0%, var(--brand-gold-dark) 100%);
    padding: .75rem 1.5rem; font-size: .875rem; font-weight: 600; color: #fff;
    box-shadow: 0 4px 14px rgba(201, 146, 46, .35); transition: all .2s;
}
.btn-gold:hover { transform: translateY(-1px); }

.btn-outline {
    display: inline-flex; align-items: center; justify-content: center;
    border-radius: .5rem; border: 2px solid var(--brand-red); padding: .7rem 1.4rem;
    font-size: .875rem; font-weight: 600; color: var(--brand-red); background: transparent; transition: all .2s;
}
.btn-outline:hover { background: var(--brand-red); color: #fff; }

.card {
    border-radius: 1rem; border: 1px solid var(--brand-border); background: #fff;
    box-shadow: 0 1px 3px rgba(20, 20, 20, .06); transition: all .25s ease;
}
.card:hover { box-shadow: 0 12px 32px rgba(20, 20, 20, .1); border-color: rgba(201, 146, 46, .35); }

.text-brand-red { color: var(--brand-red); }
.text-brand-gold { color: var(--brand-gold); }
.bg-brand-dark { background: var(--brand-charcoal); }
.bg-brand-cream { background: var(--brand-cream); }

.gold-line { height: 3px; background: linear-gradient(90deg, transparent, var(--brand-gold), transparent); }
.section-title { font-family: 'Cormorant Garamond', Georgia, serif; font-size: 2.25rem; font-weight: 700; color: var(--brand-black); }
.section-title span { color: var(--brand-red); }

.badge-gold {
    display: inline-flex; align-items: center; gap: .25rem;
    border-radius: 9999px; background: rgba(201, 146, 46, .12);
    padding: .25rem .75rem; font-size: .75rem; font-weight: 600; color: var(--brand-gold-dark);
}

.input-field {
    width: 100%; border-radius: .5rem; border: 1px solid var(--brand-border);
    padding: .625rem 1rem; font-size: .875rem; transition: border-color .2s, box-shadow .2s;
}
.input-field:focus { outline: none; border-color: var(--brand-gold); box-shadow: 0 0 0 3px rgba(201, 146, 46, .15); }

.product-card-price { color: var(--brand-red); font-weight: 700; }
.product-card-cat { color: var(--brand-gold-dark); font-size: .7rem; font-weight: 600; text-transform: uppercase; letter-spacing: .05em; }

.stat-card {
    background: #fff; border: 1px solid var(--brand-border); border-radius: 1rem;
    padding: 1.25rem; text-align: center;
}
.stat-card .value { font-size: 1.75rem; font-weight: 800; color: var(--brand-red); }
.stat-card .label { font-size: .75rem; color: #666; text-transform: uppercase; letter-spacing: .04em; margin-top: .25rem; }

.rating-star { color: var(--brand-gold); }

.site-logo {
    height: 5rem;
    width: auto;
    max-width: 280px;
    object-fit: contain;
}
@media (min-width: 768px) {
    .site-logo {
        height: 6.5rem;
        max-width: 360px;
    }
}

/* Homepage hero slider */
.hero-slider {
    position: relative;
    overflow: hidden;
    background: var(--brand-charcoal);
    min-height: 320px;
}

.hero-slider-inner {
    position: relative;
    min-height: inherit;
}

.hero-slide {
    position: absolute;
    inset: 0;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.7s ease, visibility 0.7s ease;
    pointer-events: none;
    z-index: 0;
}

.hero-slide.is-active {
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
    z-index: 2;
}

.hero-slide-bg {
    position: absolute;
    inset: 0;
    background-size: cover;
    background-position: center;
    opacity: 0.25;
    filter: blur(2px);
    transform: scale(1.05);
}

.hero-slide-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(135deg, rgba(20, 20, 20, 0.92) 0%, rgba(31, 31, 31, 0.85) 50%, rgba(142, 14, 22, 0.55) 100%);
}

.hero-slide > .relative {
    position: relative;
    z-index: 1;
}

.hero-slide-img {
    width: 16rem;
    max-height: 14rem;
    object-fit: contain;
    filter: drop-shadow(0 12px 32px rgba(0, 0, 0, 0.45));
}

.hero-slider-controls {
    position: absolute;
    bottom: 1.25rem;
    left: 50%;
    transform: translateX(-50%);
    z-index: 10;
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.hero-slider-btn {
    width: 2.25rem;
    height: 2.25rem;
    border-radius: 9999px;
    border: 1px solid rgba(255, 255, 255, 0.35);
    background: rgba(0, 0, 0, 0.35);
    color: #fff;
    font-size: 1.25rem;
    line-height: 1;
    cursor: pointer;
    transition: background 0.2s;
}

.hero-slider-btn:hover {
    background: var(--brand-red);
    border-color: var(--brand-red);
}

.hero-slider-dots {
    display: flex;
    gap: 0.5rem;
}

.hero-slider-dot {
    width: 0.625rem;
    height: 0.625rem;
    border-radius: 9999px;
    border: none;
    background: rgba(255, 255, 255, 0.4);
    cursor: pointer;
    padding: 0;
    transition: background 0.2s, transform 0.2s;
}

.hero-slider-dot.is-active {
    background: var(--brand-gold);
    transform: scale(1.15);
}

@media (min-width: 768px) {
    .hero-slider {
        min-height: 380px;
    }
    .hero-slide-img {
        width: 18rem;
        max-height: 16rem;
    }
}

.hero-pattern {
    background:
        radial-gradient(ellipse 80% 60% at 70% 40%, rgba(201, 146, 46, .15) 0%, transparent 60%),
        radial-gradient(ellipse 60% 50% at 20% 80%, rgba(181, 18, 27, .12) 0%, transparent 50%),
        linear-gradient(135deg, var(--brand-charcoal) 0%, var(--brand-black) 100%);
}

.category-card-overlay {
    background: linear-gradient(to top, rgba(20,20,20,.85) 0%, transparent 60%);
}

.review-card { border-left: 3px solid var(--brand-gold); }

/* Manual horizontal scroll — standard overflow (wheel, trackpad, touch) */
.manual-scroll-viewport {
    overflow-x: auto;
    overflow-y: hidden;
    width: 100%;
    -webkit-overflow-scrolling: touch;
    scroll-padding-inline: 0.75rem;
    padding: 0.25rem 0 0.5rem;
}

.manual-scroll-track {
    display: flex;
    flex-wrap: nowrap;
    gap: 1rem;
    width: max-content;
    padding-inline: 0.5rem;
}

.manual-scroll-viewport .category-scroll-row {
    padding-inline: 0.5rem;
}

/* Auto-scroll rows — hidden scrollbar, JS-driven smooth scroll */
.auto-scroll-viewport {
    overflow: hidden;
    width: 100%;
    position: relative;
    mask-image: linear-gradient(to right, transparent 0, #000 2%, #000 98%, transparent 100%);
    -webkit-mask-image: linear-gradient(to right, transparent 0, #000 2%, #000 98%, transparent 100%);
}

.auto-scroll-track {
    display: flex;
    flex-wrap: nowrap;
    gap: 1rem;
    width: max-content;
    will-change: transform;
}

/* When all items fit — center in viewport, no duplicate clones */
.auto-scroll-viewport.is-static {
    mask-image: none;
    -webkit-mask-image: none;
}

.auto-scroll-viewport.is-static .auto-scroll-track {
    width: 100%;
    justify-content: center;
    will-change: auto;
}

.auto-scroll-track > * {
    flex: 0 0 auto;
}

/* Legacy class alias */
.home-scroll-row {
    display: flex;
    flex-wrap: nowrap;
    gap: 1rem;
}

.home-scroll-row > * {
    flex: 0 0 auto;
}

.home-scroll-item-sm { min-width: 140px; max-width: 160px; }
.home-scroll-item-md { min-width: 220px; max-width: 260px; }
.home-scroll-item-lg { min-width: 280px; max-width: 320px; }
.home-scroll-item-xl { min-width: 300px; max-width: 360px; }

/* Home page multi-row grids — 4 to 5 cards per row on desktop */
.home-cards-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1rem;
    align-items: stretch;
}

@media (min-width: 640px) {
    .home-cards-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (min-width: 768px) {
    .home-cards-grid {
        grid-template-columns: repeat(3, 1fr);
        gap: 1.125rem;
    }
}

@media (min-width: 1024px) {
    .home-cards-grid {
        grid-template-columns: repeat(4, 1fr);
        gap: 1.25rem;
    }
}

@media (min-width: 1280px) {
    .home-cards-grid {
        grid-template-columns: repeat(5, 1fr);
    }
}

.home-cards-grid > * {
    width: 100%;
    min-width: 0;
}

/* Category cards in auto-scroll row — fixed width single row */
.category-scroll-card {
    flex: 0 0 auto;
    width: 200px;
    max-width: 200px;
}

@media (min-width: 768px) {
    .category-scroll-card {
        width: 220px;
        max-width: 220px;
    }
}

/* 3 cards per row — importance & about facts */
.home-grid-3,
.importance-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 1rem;
    align-items: stretch;
}

@media (min-width: 640px) {
    .home-grid-3,
    .importance-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (min-width: 768px) {
    .home-grid-3,
    .importance-grid {
        grid-template-columns: repeat(3, 1fr);
        gap: 1.25rem;
    }
}

.home-grid-3 > *,
.importance-grid > * {
    width: 100%;
    min-width: 0;
}

/* Trust stats — single row, no scroll, fits container */
.trust-stats-grid {
    display: flex;
    flex-wrap: nowrap;
    align-items: stretch;
    justify-content: space-between;
    gap: clamp(0.375rem, 1vw, 0.875rem);
    width: 100%;
    padding: 0 clamp(0.25rem, 1.5vw, 1rem);
}

.trust-stats-grid .trust-stat-card {
    flex: 1 1 0;
    min-width: 0;
    width: auto;
    padding: clamp(0.625rem, 1.2vw, 1rem) clamp(0.25rem, 0.6vw, 0.5rem);
}

.trust-stats-grid .trust-stat-card-wide {
    flex: 1.4 1 0;
}

.trust-stats-grid .value {
    font-size: clamp(1.125rem, 2.2vw, 1.75rem);
    line-height: 1.2;
}

.trust-stats-grid .label {
    font-size: clamp(0.5625rem, 0.95vw, 0.75rem);
    line-height: 1.3;
}

@media (max-width: 639px) {
    .trust-stats-grid {
        flex-wrap: wrap;
        justify-content: center;
        padding: 0;
    }
    .trust-stats-grid .trust-stat-card {
        flex: 1 1 calc(33.333% - 0.5rem);
        max-width: calc(33.333% - 0.5rem);
    }
    .trust-stats-grid .trust-stat-card-wide {
        flex: 1 1 100%;
        max-width: 100%;
    }
}

/* Legacy auto-scroll stat cards (categories etc.) */
.stat-scroll-card {
    flex: 0 0 auto;
    width: 130px;
    min-width: 130px;
}

.stat-scroll-card-wide {
    width: 220px;
    min-width: 220px;
}

.importance-card {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    width: 100%;
    min-height: 100%;
    padding: 1.25rem;
    border-radius: 1rem;
    border: 1px solid var(--brand-border);
    background: #fff;
    box-shadow: 0 1px 3px rgba(20, 20, 20, .06);
    transition: box-shadow 0.2s, border-color 0.2s;
}

.importance-card:hover {
    border-color: rgba(201, 146, 46, .4);
    box-shadow: 0 8px 24px rgba(20, 20, 20, .08);
}

.importance-card .icon-wrap {
    width: 2.75rem;
    height: 2.75rem;
    border-radius: .75rem;
    background: linear-gradient(135deg, rgba(181, 18, 27, .1), rgba(201, 146, 46, .15));
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: .75rem;
    flex-shrink: 0;
}

.importance-card h3 {
    font-size: 1rem;
    line-height: 1.35;
}

.filter-chip {
    display: inline-flex; align-items: center; padding: .4rem 1rem;
    border-radius: 9999px; font-size: .8rem; font-weight: 600;
    border: 1px solid var(--brand-border); background: #fff; color: #444;
    transition: all .2s; white-space: nowrap;
}
.filter-chip:hover, .filter-chip.active {
    background: var(--brand-red); border-color: var(--brand-red); color: #fff;
}

/* Products page: categories on top, filters left */
.products-catalog-layout { width: 100%; }

.products-catalog-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 1.5rem;
    align-items: start;
}

@media (min-width: 1024px) {
    .products-catalog-grid {
        grid-template-columns: 260px 1fr;
        gap: 2rem;
    }
}

.products-filter-sidebar {
    width: 100%;
}

@media (max-width: 1023px) {
    .products-filter-sidebar {
        display: none;
        position: fixed;
        inset: 0;
        z-index: 60;
        background: rgba(20, 20, 20, 0.5);
        padding: 1rem;
        overflow-y: auto;
    }
    .products-filter-sidebar.is-open {
        display: block;
    }
    .products-filter-sidebar .card {
        max-width: 320px;
        margin: 2rem auto;
        position: relative;
    }
}

.products-catalog-main {
    min-width: 0;
}

/* Category strip — full width on top */
.category-scroll-top {
    width: 100%;
}

.category-scroll-row {
    display: flex;
    flex-wrap: nowrap;
    gap: 1.25rem;
    padding: 0.25rem 0;
}

.category-scroll-item {
    flex: 0 0 auto;
    scroll-snap-align: center;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    min-width: 88px;
    max-width: 100px;
    text-decoration: none;
    transition: transform 0.2s ease;
}
.category-scroll-item:hover { transform: translateY(-3px); }

.category-scroll-avatar {
    width: 72px;
    height: 72px;
    border-radius: 50%;
    overflow: hidden;
    border: 3px solid var(--brand-border);
    background: var(--brand-warm);
    padding: 6px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: border-color 0.2s, box-shadow 0.2s;
    box-shadow: 0 2px 8px rgba(20, 20, 20, 0.08);
}
.category-scroll-avatar img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    border-radius: 50%;
}
.category-scroll-avatar-all {
    background: linear-gradient(135deg, rgba(181, 18, 27, 0.08), rgba(201, 146, 46, 0.15));
}

.category-scroll-item.is-active .category-scroll-avatar {
    border-color: var(--brand-red);
    box-shadow: 0 0 0 3px rgba(181, 18, 27, 0.2), 0 4px 12px rgba(181, 18, 27, 0.25);
}
.category-scroll-item:hover .category-scroll-avatar {
    border-color: var(--brand-gold);
}

.category-scroll-label {
    margin-top: 0.5rem;
    font-size: 0.7rem;
    font-weight: 700;
    color: #333;
    line-height: 1.2;
    max-width: 100%;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}
.category-scroll-item.is-active .category-scroll-label { color: var(--brand-red); }

.category-scroll-count {
    font-size: 0.65rem;
    color: var(--brand-gold-dark);
    margin-top: 0.15rem;
    font-weight: 600;
}

@media (min-width: 768px) {
    .category-scroll-avatar { width: 80px; height: 80px; }
    .category-scroll-item { min-width: 96px; max-width: 110px; }
    .category-scroll-label { font-size: 0.75rem; }
}

/* Account area */
.account-nav-link {
    display: block;
    padding: 0.75rem 1rem;
    border-radius: 0.5rem;
    font-size: 0.875rem;
    font-weight: 600;
    color: #4b5563;
    transition: background .2s, color .2s;
}
.account-nav-link:hover { background: var(--brand-warm); color: var(--brand-red); }
.account-nav-link.is-active {
    background: rgba(181, 18, 27, .08);
    color: var(--brand-red);
}
