/* ===================================
   TRENCART - Main Stylesheet
   Bootstrap 5 + Custom Styles
   =================================== */

/* Global Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    line-height: 1.6;
    overflow-x: hidden;
}

a {
    text-decoration: none;
    color: inherit;
    transition: all var(--transition-speed) ease;
}

/* ===================================
   NAVBAR STYLES
   =================================== */
.navbar {
    background-color: var(--navbar-bg) !important;
    padding: 0.65rem 0;
    box-shadow: var(--shadow-md);
    transition: padding var(--transition-speed) ease, box-shadow var(--transition-speed) ease;
    border-bottom: 1px solid rgba(255,255,255,0.06);
}

.navbar.scrolled {
    padding: 0.4rem 0;
    box-shadow: var(--shadow-lg);
}

.navbar-brand {
    flex-shrink: 0;
    margin-right: 1.5rem;
}

.navbar-nav .nav-link {
    color: rgba(255,255,255,0.88) !important;
    padding: 0.45rem 0.9rem;
    font-size: 0.82rem;
    font-weight: 600;
    letter-spacing: 0.07em;
    text-transform: uppercase;
    position: relative;
    transition: color var(--transition-speed) ease;
    white-space: nowrap;
}

.navbar-nav .nav-link:hover,
.navbar-nav .nav-link.active {
    color: #fff !important;
}

.navbar-nav .nav-link::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0.9rem;
    right: 0.9rem;
    height: 2px;
    background: #fff;
    transform: scaleX(0);
    transition: transform var(--transition-speed) ease;
    border-radius: 2px;
}

.navbar-nav .nav-link:hover::after,
.navbar-nav .nav-link.active::after {
    transform: scaleX(1);
}

/* Cart link — icon only, no underline bar */
.nav-cart-link::after { display: none !important; }
.nav-cart-link { padding: 0.45rem 0.6rem !important; }
.nav-cart-link .cart-icon { font-size: 1.15rem; color: #fff; }

/* Navbar search bar — fills available space */
.navbar-search-form {
    flex: 1 1 auto;
    min-width: 0;
    margin: 0 1.2rem;
}
.nav-search-input {
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-right: none;
    color: #fff;
    font-size: 0.88rem;
    height: 36px;
    transition: background 0.2s ease, border-color 0.2s ease;
    border-radius: 6px 0 0 6px !important;
}
.nav-search-input::placeholder { color: rgba(255,255,255,0.5); }
.nav-search-input:focus {
    background: rgba(255, 255, 255, 0.18);
    border-color: rgba(255, 255, 255, 0.45);
    color: #fff;
    box-shadow: none;
}
.nav-search-btn {
    background: rgba(255,255,255,0.12);
    border: 1px solid rgba(255,255,255,0.2);
    border-left: none;
    color: rgba(255,255,255,0.85);
    height: 36px;
    padding: 0 14px;
    font-size: 0.85rem;
    border-radius: 0 6px 6px 0 !important;
    transition: background 0.2s ease;
}
.nav-search-btn:hover {
    background: rgba(255,255,255,0.22);
    color: #fff;
}

.cart-icon {
    position: relative;
    color: var(--white-primary);
    font-size: 1.25rem;
}

.cart-badge {
    position: absolute;
    top: -8px;
    right: -8px;
    background-color: #dc3545;
    color: white;
    border-radius: 50%;
    width: 20px;
    height: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.75rem;
    font-weight: bold;
}

/* ===================================
   HERO SECTION
   =================================== */
.hero-section {
    position: relative;
    height: 70vh;
    min-height: 500px;
    background: linear-gradient(135deg, var(--primary-black) 0%, var(--black-light) 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--white-primary);
    overflow: hidden;
}

.hero-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url('../images/hero/pattern.svg') repeat;
    opacity: 0.1;
}

.hero-content {
    position: relative;
    z-index: 2;
    text-align: center;
    max-width: 800px;
    padding: 2rem;
    animation: fadeInUp 1s ease;
}

.hero-content h1 {
    font-size: 3.5rem;
    font-weight: 700;
    margin-bottom: 1.5rem;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.3);
}

.hero-content p {
    font-size: 1.25rem;
    margin-bottom: 2rem;
    color: var(--white-secondary);
}

.hero-content .btn {
    padding: 0.875rem 2.5rem;
    font-size: 1.125rem;
    border-radius: 50px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 1px;
}

/* ===================================
   SECTIONS
   =================================== */
.section {
    padding: var(--section-padding);
}

.section-title {
    text-align: center;
    margin-bottom: 3rem;
}

.section-title h2 {
    font-size: 2.5rem;
    font-weight: 700;
    color: var(--text-primary);
    position: relative;
    display: inline-block;
    padding-bottom: 1rem;
}

.section-title h2::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 60px;
    height: 3px;
    background-color: var(--primary-black);
}

.section-title p {
    color: var(--text-secondary);
    font-size: 1.125rem;
    margin-top: 1rem;
}

/* ===================================
   CARDS
   =================================== */
.shop-card,
.product-card {
    background-color: var(--card-bg);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    overflow: hidden;
    transition: all var(--transition-speed) ease;
    height: 100%;
    box-shadow: var(--shadow-sm);
}

.shop-card:hover,
.product-card:hover {
    transform: translateY(-8px);
    box-shadow: var(--shadow-lg);
    border-color: var(--grey-primary);
}

.shop-card img,
.product-card img {
    width: 100%;
    height: 250px;
    object-fit: cover;
    transition: transform var(--transition-speed) ease;
}

.shop-card img {
    height: 170px;
}

.shop-card:hover img,
.product-card:hover img {
    transform: scale(1.05);
}

.card-body {
    padding: var(--card-padding);
}

.card-title {
    font-size: 1.25rem;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 0.75rem;
}

.card-text {
    color: var(--text-secondary);
    font-size: 0.95rem;
    margin-bottom: 1rem;
}

.card-price {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--primary-black);
    margin-bottom: 1rem;
}

/* ===================================
   BUTTONS
   =================================== */
.btn-primary {
    background-color: var(--primary-black);
    border-color: var(--primary-black);
    color: var(--white-primary);
    padding: 0.625rem 1.5rem;
    border-radius: 6px;
    font-weight: 600;
    transition: all var(--transition-speed) ease;
}

.btn-primary:hover {
    background-color: var(--black-light);
    border-color: var(--black-light);
    transform: translateY(-2px);
    box-shadow: var(--shadow-md);
}

.btn-outline-primary {
    border-color: var(--primary-black);
    color: var(--primary-black);
    background-color: transparent;
}

.btn-outline-primary:hover {
    background-color: var(--primary-black);
    color: var(--white-primary);
}

/* ===================================
   FOOTER
   =================================== */
.footer {
    background-color: var(--footer-bg);
    color: var(--white-primary);
    padding: 3rem 0 1rem;
}

.footer h5 {
    font-size: 1.25rem;
    font-weight: 600;
    margin-bottom: 1.5rem;
}

.footer ul {
    list-style: none;
    padding: 0;
}

.footer ul li {
    margin-bottom: 0.75rem;
}

.footer ul li a {
    color: var(--white-secondary);
    transition: color var(--transition-speed) ease;
}

.footer ul li a:hover {
    color: var(--white-primary);
    padding-left: 5px;
}

.footer-bottom {
    border-top: 1px solid var(--grey-primary);
    padding-top: 1.5rem;
    margin-top: 2rem;
    text-align: center;
    color: var(--grey-light);
}

/* ===================================
   BREADCRUMB
   =================================== */
.breadcrumb {
    background-color: var(--white-secondary);
    padding: 1rem;
    border-radius: 6px;
    margin-bottom: 2rem;
}

.breadcrumb-item a {
    color: var(--text-secondary);
}

.breadcrumb-item.active {
    color: var(--text-primary);
    font-weight: 600;
}

/* ===================================
   FILTER SIDEBAR
   =================================== */
.filter-sidebar {
    background-color: var(--white-secondary);
    padding: 1.5rem;
    border-radius: 12px;
    border: 1px solid var(--border-color);
    height: fit-content;
    position: sticky;
    top: 100px;
}

.filter-section {
    margin-bottom: 2rem;
}

.filter-section h5 {
    font-size: 1.125rem;
    font-weight: 600;
    margin-bottom: 1rem;
    color: var(--text-primary);
}

.filter-section .form-check {
    margin-bottom: 0.75rem;
}

.filter-section .form-check-label {
    color: var(--text-secondary);
    cursor: pointer;
}

.price-range-slider {
    margin: 1rem 0;
}

/* ===================================
   CART PAGE
   =================================== */
.cart-item {
    background-color: var(--white-secondary);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    padding: 1.5rem;
    margin-bottom: 1rem;
    display: flex;
    align-items: center;
    gap: 1.5rem;
}

.cart-item img {
    width: 100px;
    height: 100px;
    object-fit: cover;
    border-radius: 8px;
}

.cart-item-details {
    flex: 1;
}

.cart-item-title {
    font-size: 1.125rem;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 0.5rem;
}

.cart-item-shop {
    color: var(--text-secondary);
    font-size: 0.9rem;
}

.quantity-controls {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.quantity-controls button {
    width: 32px;
    height: 32px;
    border-radius: 4px;
    border: 1px solid var(--border-color);
    background-color: var(--white-primary);
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all var(--transition-speed) ease;
}

.quantity-controls button:hover {
    background-color: var(--primary-black);
    color: var(--white-primary);
    border-color: var(--primary-black);
}

.cart-summary {
    background-color: var(--white-secondary);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    padding: 2rem;
    position: sticky;
    top: 100px;
}

.cart-summary h4 {
    font-weight: 700;
    margin-bottom: 1.5rem;
}

.summary-row {
    display: flex;
    justify-content: space-between;
    margin-bottom: 1rem;
    padding-bottom: 1rem;
    border-bottom: 1px solid var(--border-color);
}

.summary-row:last-child {
    border-bottom: none;
    font-size: 1.25rem;
    font-weight: 700;
}

/* ===================================
   AUTH FORMS
   =================================== */
.auth-container {
    min-height: calc(100vh - 200px);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 2rem 0;
}

.auth-card {
    background-color: var(--white-secondary);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    padding: 3rem;
    max-width: 500px;
    width: 100%;
    box-shadow: var(--shadow-md);
}

.auth-card h2 {
    text-align: center;
    margin-bottom: 2rem;
    font-weight: 700;
}

.form-control {
    padding: 0.75rem;
    border-radius: 6px;
    border: 1px solid var(--border-color);
    transition: all var(--transition-speed) ease;
}

.form-control:focus {
    border-color: var(--primary-black);
    box-shadow: 0 0 0 0.2rem rgba(26, 26, 26, 0.15);
}

.password-toggle {
    position: absolute;
    right: 15px;
    top: 50%;
    transform: translateY(-50%);
    cursor: pointer;
    color: var(--text-secondary);
}

/* ===================================
   CHECKOUT PAGE
   =================================== */
.checkout-section {
    background-color: var(--white-secondary);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    padding: 2rem;
    margin-bottom: 2rem;
}

.checkout-section h4 {
    font-weight: 700;
    margin-bottom: 1.5rem;
    padding-bottom: 1rem;
    border-bottom: 2px solid var(--border-color);
}

.order-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem 0;
    border-bottom: 1px solid var(--border-color);
}

.order-item:last-child {
    border-bottom: none;
}

.payment-option {
    background-color: var(--white-primary);
    border: 2px solid var(--border-color);
    border-radius: 8px;
    padding: 1.25rem;
    margin-bottom: 1rem;
    cursor: pointer;
    transition: all var(--transition-speed) ease;
}

.payment-option:hover,
.payment-option.selected {
    border-color: var(--primary-black);
    background-color: var(--white-tertiary);
}

.payment-option input[type="radio"] {
    margin-right: 0.75rem;
}

/* ===================================
   ANIMATIONS
   =================================== */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.fade-in-up {
    animation: fadeInUp 0.6s ease;
}

/* ===================================
   RESPONSIVE DESIGN
   =================================== */
@media (max-width: 768px) {
    .hero-content h1 {
        font-size: 2.25rem;
    }

    .hero-content p {
        font-size: 1rem;
    }

    .section-title h2 {
        font-size: 2rem;
    }

    .filter-sidebar {
        margin-bottom: 2rem;
        position: static;
    }

    .cart-item {
        flex-direction: column;
        align-items: flex-start;
    }

    .cart-summary {
        position: static;
        margin-top: 2rem;
    }

    .auth-card {
        padding: 2rem 1.5rem;
    }
}

@media (max-width: 576px) {
    .hero-section {
        height: 50vh;
        min-height: 400px;
    }

    .hero-content h1 {
        font-size: 1.75rem;
    }

    .navbar-brand {
        font-size: 1.35rem;
    }
}

/* ===================================
   PRODUCT CARD ENHANCEMENTS
   =================================== */

/* Image wrapper — needed for discount badge overlay */
.product-img-wrap {
    position: relative;
    overflow: hidden;
}

/* Product images are shorter than shop images */
.product-img-wrap img {
    width: 100%;
    height: 180px;
    object-fit: cover;
    display: block;
    transition: transform var(--transition-speed) ease;
}

.product-card:hover .product-img-wrap img {
    transform: scale(1.05);
}

/* Discount badge sits on top-left corner of the image */
.product-discount-badge {
    position: absolute;
    top: 8px;
    left: 8px;
    background: #dc3545;
    color: #fff;
    font-size: 0.72rem;
    font-weight: 700;
    padding: 0.2rem 0.5rem;
    border-radius: 4px;
    letter-spacing: 0.4px;
    pointer-events: none;
}

/* Compact card title and price for product cards */
.product-card .card-title {
    font-size: 0.95rem;
    font-weight: 600;
    margin-bottom: 0.25rem;
}

.product-card .card-price {
    font-size: 1.1rem;
    font-weight: 700;
    margin-bottom: 0.5rem;
}

/* Inline size buttons on product cards */
.card-size-row {
    display: flex;
    flex-wrap: wrap;
    gap: 4px;
}
.card-size-btn {
    padding: 2px 8px;
    font-size: 11px;
    font-weight: 600;
    border: 1.5px solid #ccc;
    border-radius: 4px;
    background: #fff;
    color: #333;
    cursor: pointer;
    transition: all 0.15s;
    line-height: 1.6;
}
.card-size-btn:hover {
    border-color: #1a1a1a;
    background: #f5f5f5;
}
.card-size-btn.active {
    border-color: #1a1a1a;
    background: #1a1a1a;
    color: #fff;
}

/* ===================================
   ORDER SUCCESS OVERLAY (animated checkmark)
   =================================== */
.order-success-overlay {
    position: fixed;
    top: 0; left: 0;
    width: 100%; height: 100%;
    background: rgba(255, 255, 255, 0.97);
    z-index: 9999;
    display: flex;
    align-items: center;
    justify-content: center;
    animation: fadeIn 0.3s ease;
}

.order-success-box {
    text-align: center;
    padding: 2rem;
}

.order-checkmark {
    width: 100px;
    height: 100px;
    border-radius: 50%;
    display: block;
    stroke-width: 3;
    stroke: #fff;
    stroke-miterlimit: 10;
    margin: 0 auto;
    box-shadow: inset 0 0 0 #28a745;
    animation: checkmark-fill 0.4s ease-in-out 0.5s forwards,
               checkmark-scale 0.3s ease-in-out 0.9s both;
}

.order-checkmark-circle {
    stroke-dasharray: 166;
    stroke-dashoffset: 166;
    stroke-width: 3;
    stroke-miterlimit: 10;
    stroke: #28a745;
    fill: none;
    animation: stroke-draw 0.6s cubic-bezier(0.65, 0, 0.45, 1) forwards;
}

.order-checkmark-check {
    transform-origin: 50% 50%;
    stroke-dasharray: 48;
    stroke-dashoffset: 48;
    stroke: #fff;
    stroke-width: 3;
    animation: stroke-draw 0.3s cubic-bezier(0.65, 0, 0.45, 1) 0.7s forwards;
}

@keyframes stroke-draw {
    100% { stroke-dashoffset: 0; }
}

@keyframes checkmark-scale {
    0%, 100% { transform: none; }
    50%       { transform: scale3d(1.1, 1.1, 1); }
}

@keyframes checkmark-fill {
    100% { box-shadow: inset 0 0 0 60px #28a745; }
}

@keyframes fadeIn {
    from { opacity: 0; }
    to   { opacity: 1; }
}

/* ===================================
   DELIVERY TIMELINE
   =================================== */
.order-timeline {
    padding: 10px 0 4px;
}

.tl-steps {
    display: flex;
    justify-content: space-between;
    position: relative;
}

/* Grey background track — runs between centers of first and last step */
.tl-steps::before {
    content: '';
    position: absolute;
    top: 42px; /* icon-slot(28px) + half-circle(14px) */
    left: 10%;
    right: 10%;
    height: 2px;
    background: #e0e0e0;
    z-index: 0;
}

/* Dark filled-progress track — animates from 0 to target width */
.tl-fill-bar {
    position: absolute;
    top: 42px;
    left: 10%;
    height: 2px;
    background: #1a1a1a;
    z-index: 1;
    width: 0;
    animation: trackFill 1.1s ease-out forwards;
}

@keyframes trackFill {
    from { width: 0; }
    to   { width: var(--fill-to); }
}

.tl-step {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    position: relative;
    z-index: 2;
}

/* Slot above circles — keeps height so circles don't sit flush at the top */
.tl-icon-slot {
    height: 28px;
}

/* Outer wrapper: absolutely positioned, slides left→right via bikeRide */
.tl-bike-rider {
    position: absolute;
    top: 6px;
    transform: translateX(-50%); /* centres the icon over the step dot */
    font-size: 20px;
    color: #1a1a1a;
    z-index: 3;
    animation: bikeRide 1.2s cubic-bezier(0.25, 0.46, 0.45, 0.94) forwards;
}

/* Inner span: floats up-down independently (separate transform, no conflict) */
.tl-bike-float {
    display: block;
    animation: bikeFloat 0.5s ease-in-out infinite alternate;
}

@keyframes bikeRide {
    from { left: 10%; }          /* center of step 0 */
    to   { left: var(--bike-to); }
}

@keyframes bikeFloat {
    from { transform: translateY(0); }
    to   { transform: translateY(-5px); }
}

.tl-circle {
    width: 28px;
    height: 28px;
    border-radius: 50%;
    border: 2px solid #ddd;
    background: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 11px;
    color: #ddd;
    position: relative;
    z-index: 2;
}

.tl-step.tl-done .tl-circle {
    background: #1a1a1a;
    border-color: #1a1a1a;
    color: #fff;
}

.tl-step.tl-active .tl-circle {
    border-color: #1a1a1a;
    color: #1a1a1a;
    box-shadow: 0 0 0 3px rgba(26, 26, 26, 0.15);
}

.tl-label {
    font-size: 9px;
    color: #bbb;
    text-align: center;
    margin-top: 5px;
    line-height: 1.3;
    white-space: nowrap;
}

.tl-step.tl-done .tl-label,
.tl-step.tl-active .tl-label {
    color: #333;
    font-weight: 600;
}

/* ===================================
   PAGE BANNER (2025 modern)
   =================================== */
.page-banner {
    background: linear-gradient(135deg, #111 0%, #272727 100%);
    padding: 40px 0 38px;
    color: #fff;
    position: relative;
    overflow: hidden;
}

.page-banner::before {
    content: '';
    position: absolute;
    right: -100px;
    bottom: -100px;
    width: 320px;
    height: 320px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.03);
    pointer-events: none;
}

.page-banner .pb-eyebrow {
    font-size: 0.68rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 2px;
    color: rgba(255, 255, 255, 0.4);
    margin-bottom: 6px;
}

.page-banner .pb-title {
    font-size: 2.1rem;
    font-weight: 800;
    margin: 0 0 5px;
    letter-spacing: -0.5px;
    line-height: 1.15;
}

.page-banner .pb-sub {
    color: rgba(255, 255, 255, 0.5);
    margin: 0;
    font-size: 0.88rem;
}

.page-banner .pb-count {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    background: rgba(255, 255, 255, 0.1);
    color: rgba(255, 255, 255, 0.85);
    font-size: 0.78rem;
    font-weight: 600;
    padding: 4px 14px;
    border-radius: 50px;
    margin-top: 12px;
}

/* ===================================
   HORIZONTAL FILTER STRIP (shops page)
   =================================== */
.filter-strip {
    background: #fff;
    border-bottom: 1px solid #f0f0f0;
    padding: 11px 0;
    position: sticky;
    top: 60px;
    z-index: 99;
    box-shadow: 0 2px 14px rgba(0, 0, 0, 0.05);
}

.filter-strip .filter-row {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    align-items: center;
}

.filter-strip .fs-search {
    border: 1.5px solid #e8e8e8;
    border-radius: 50px;
    padding: 0 16px;
    font-size: 0.8rem;
    height: 34px;
    min-width: 190px;
    outline: none;
    transition: border-color 0.2s, box-shadow 0.2s;
}

.filter-strip .fs-search:focus {
    border-color: #1a1a1a;
    box-shadow: 0 0 0 3px rgba(26, 26, 26, 0.07);
}

.filter-strip select {
    border: 1.5px solid #e8e8e8;
    border-radius: 50px;
    padding: 0 14px;
    font-size: 0.8rem;
    font-weight: 600;
    color: #333;
    background: #fff;
    cursor: pointer;
    height: 34px;
    transition: border-color 0.2s, box-shadow 0.2s;
    appearance: auto;
}

.filter-strip select:focus {
    outline: none;
    border-color: #1a1a1a;
    box-shadow: 0 0 0 3px rgba(26, 26, 26, 0.07);
}

/* Offers / Top Sellers toggle chips in filter strip */
.filter-strip .btn-outline-secondary {
    border: 1.5px solid #e8e8e8 !important;
    border-radius: 50px !important;
    padding: 0 14px !important;
    font-size: 0.8rem !important;
    font-weight: 600 !important;
    color: #555 !important;
    background: #fff !important;
    height: 34px;
    display: inline-flex;
    align-items: center;
    gap: 5px;
    transition: all 0.2s !important;
}

.filter-strip .btn-outline-secondary:hover {
    border-color: #1a1a1a !important;
    color: #1a1a1a !important;
}

.filter-strip .btn-primary {
    background: #1a1a1a !important;
    border-color: #1a1a1a !important;
    color: #fff !important;
    border-radius: 50px !important;
    padding: 0 14px !important;
    font-size: 0.8rem !important;
    font-weight: 600 !important;
    height: 34px;
    display: inline-flex;
    align-items: center;
    gap: 5px;
}

.filter-strip .btn-outline-primary {
    border: 1.5px solid #e8e8e8 !important;
    color: #888 !important;
    background: #fff !important;
    border-radius: 50px !important;
    padding: 0 14px !important;
    font-size: 0.8rem !important;
    height: 34px;
    display: inline-flex;
    align-items: center;
    gap: 5px;
}

.filter-strip .btn-outline-primary:hover {
    background: #f5f5f5 !important;
    color: #333 !important;
    border-color: #ccc !important;
}

.filter-count {
    margin-left: auto;
    font-size: 0.78rem;
    color: #bbb;
    white-space: nowrap;
    font-weight: 500;
}

/* ===================================
   MODERN FILTER SIDEBAR (products page)
   =================================== */
.filter-sidebar {
    background: #fff !important;
    border: none !important;
    border-radius: 16px !important;
    padding: 1.25rem !important;
    box-shadow: 0 2px 20px rgba(0, 0, 0, 0.06) !important;
    position: sticky !important;
    top: 80px !important;
}

.filter-sidebar > h5:first-child {
    font-size: 0.68rem !important;
    font-weight: 700 !important;
    text-transform: uppercase !important;
    letter-spacing: 1.5px !important;
    color: #bbb !important;
    margin-bottom: 1rem !important;
    padding-bottom: 0.75rem !important;
    border-bottom: 1px solid #f0f0f0 !important;
}

.filter-section {
    margin-bottom: 1.1rem;
    padding-bottom: 1.1rem;
    border-bottom: 1px solid #f5f5f5;
}

.filter-section:last-of-type {
    border-bottom: none;
    margin-bottom: 0;
    padding-bottom: 0;
}

.filter-section h5 {
    font-size: 0.68rem !important;
    font-weight: 700 !important;
    text-transform: uppercase !important;
    letter-spacing: 1.2px !important;
    color: #bbb !important;
    margin-bottom: 0.6rem !important;
}

.filter-section .form-select {
    border: 1.5px solid #eee;
    border-radius: 10px;
    font-size: 0.83rem;
}

.filter-section .form-range {
    accent-color: #1a1a1a;
}

.filter-section .btn-outline-primary {
    border: 1.5px solid #e5e5e5 !important;
    color: #888 !important;
    font-size: 0.8rem !important;
    border-radius: 10px !important;
}

.filter-section .btn-outline-primary:hover {
    background: #1a1a1a !important;
    color: #fff !important;
    border-color: #1a1a1a !important;
}

/* ===================================
   MODERN CART
   =================================== */
.cart-item {
    background: #fff;
    border: none;
    border-radius: 16px;
    padding: 1.1rem 1.3rem;
    margin-bottom: 0;
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.055);
    transition: box-shadow 0.2s;
    height: 100%;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.cart-item:hover {
    box-shadow: 0 5px 22px rgba(0, 0, 0, 0.1);
}

.cart-item-top {
    display: flex;
    align-items: flex-start;
    gap: 12px;
}

.cart-item img {
    width: 88px;
    height: 88px;
    object-fit: cover;
    border-radius: 12px;
    flex-shrink: 0;
}

.cart-item-bottom {
    display: flex;
    align-items: center;
    gap: 10px;
    padding-top: 10px;
    border-top: 1px solid #f5f5f5;
    margin-top: auto;
}

.cart-summary {
    background: #fff;
    border: none;
    border-radius: 16px;
    padding: 1.5rem;
    box-shadow: 0 2px 20px rgba(0, 0, 0, 0.07);
}

/* Category dropdown in filter strip */
.filter-strip .dropdown-toggle {
    border: 1.5px solid #e8e8e8;
    border-radius: 50px;
    padding: 0 16px;
    font-size: 0.8rem;
    font-weight: 600;
    color: #333;
    background: #fff;
    height: 34px;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    white-space: nowrap;
    transition: border-color 0.2s, box-shadow 0.2s;
}

.filter-strip .dropdown-toggle:focus,
.filter-strip .dropdown-toggle:hover {
    outline: none;
    border-color: #1a1a1a;
    box-shadow: none;
    color: #1a1a1a;
}

.filter-strip .dropdown-toggle::after {
    margin-left: 4px;
}

.filter-strip .dropdown-menu {
    border-radius: 14px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.12);
    border: 1px solid #f0f0f0;
    padding: 10px 14px;
    min-width: 200px;
    max-height: 280px;
    overflow-y: auto;
}

.filter-strip .dropdown-menu .form-check {
    padding: 5px 0 5px 1.5em;
    margin: 0;
}

.filter-strip .dropdown-menu .form-check-label {
    font-size: 0.83rem;
    cursor: pointer;
}

/* Price chip inside filter strip */
.filter-strip .price-chip {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: #fff;
    border: 1.5px solid #e8e8e8;
    border-radius: 50px;
    padding: 0 14px;
    height: 34px;
}

.filter-strip .price-chip input[type="range"] {
    width: 80px;
    accent-color: #1a1a1a;
    cursor: pointer;
    margin: 0;
}

.filter-strip .price-chip span {
    font-size: 0.78rem;
    font-weight: 600;
    color: #333;
    white-space: nowrap;
}

/* ===================================
   MODERN CHECKOUT
   =================================== */
.checkout-section {
    background: #fff;
    border: none;
    border-radius: 16px;
    padding: 1.6rem;
    margin-bottom: 14px;
    box-shadow: 0 2px 14px rgba(0, 0, 0, 0.055);
}

.checkout-section h4 {
    font-size: 0.95rem;
    font-weight: 700;
    margin-bottom: 1.2rem;
    padding-bottom: 0.7rem;
    border-bottom: 1px solid #f0f0f0;
    color: #1a1a1a;
}

.payment-option {
    background: #fafafa;
    border: 2px solid #eee;
    border-radius: 12px;
    padding: 1rem;
    margin-bottom: 10px;
    cursor: pointer;
    transition: all 0.2s;
}

.payment-option.selected {
    border-color: #1a1a1a;
    background: #f8f8f8;
}

/* ===================================
   MODERN PROFILE
   =================================== */
.profile-avatar-card {
    background: linear-gradient(145deg, #1a1a1a 0%, #2d2d2d 100%);
    border-radius: 20px;
    padding: 2rem 1.5rem;
    text-align: center;
    color: #fff;
    height: 100%;
}

.profile-avatar-card .avatar-circle {
    width: 76px;
    height: 76px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.12);
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 1rem;
    font-size: 1.8rem;
    color: rgba(255, 255, 255, 0.75);
}

.profile-avatar-card h4 {
    font-weight: 700;
    margin-bottom: 0.2rem;
    font-size: 1.1rem;
}

.profile-avatar-card p {
    color: rgba(255, 255, 255, 0.55);
    font-size: 0.83rem;
    margin-bottom: 0.15rem;
}

.profile-avatar-card .btn-outline-light {
    border-color: rgba(255, 255, 255, 0.25) !important;
    color: rgba(255, 255, 255, 0.8) !important;
    font-size: 0.8rem;
    border-radius: 50px;
    margin-top: 1rem;
}

.profile-avatar-card .btn-outline-light:hover {
    background: rgba(255, 255, 255, 0.1) !important;
    border-color: rgba(255, 255, 255, 0.45) !important;
    color: #fff !important;
}

.profile-form-card {
    background: #fff;
    border: none;
    border-radius: 20px;
    padding: 1.75rem;
    box-shadow: 0 2px 20px rgba(0, 0, 0, 0.06);
    height: 100%;
}

.profile-form-card .pfc-label {
    font-size: 0.68rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1.5px;
    color: #bbb;
    margin-bottom: 1.1rem;
    padding-bottom: 0.7rem;
    border-bottom: 1px solid #f0f0f0;
    display: block;
}

/* ===================================
   PAGE BODY BACKGROUND
   =================================== */
.page-body {
    background: #f7f7f7;
    min-height: 60vh;
    padding: 30px 0 50px;
}

/* ===================================
   NEW ARRIVALS SECTION
   =================================== */
.na-section {
    background: #1a1a1a;
    padding: 60px 0;
}

.na-section .section-title h2 {
    color: #fff;
}

.na-section .section-title h2::after {
    background-color: #fff;
}

.na-section .section-title p {
    color: rgba(255, 255, 255, 0.55);
}

/* Horizontal scroll track */
.na-scroll-track {
    display: flex;
    gap: 16px;
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    padding-bottom: 14px;
    scrollbar-width: thin;
    scrollbar-color: #444 transparent;
}

.na-scroll-track::-webkit-scrollbar { height: 4px; }
.na-scroll-track::-webkit-scrollbar-track { background: transparent; }
.na-scroll-track::-webkit-scrollbar-thumb { background: #444; border-radius: 4px; }

/* Individual arrival card */
.na-card {
    flex: 0 0 200px;
    scroll-snap-align: start;
    text-decoration: none;
    color: inherit;
    border-radius: 14px;
    overflow: hidden;
    background: #fff;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.35);
    transition: transform 0.25s ease, box-shadow 0.25s ease;
    display: block;
}

.na-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 12px 28px rgba(0, 0, 0, 0.5);
}

/* Product image — portrait aspect ratio */
.na-img-wrap {
    position: relative;
    aspect-ratio: 3 / 4;
    overflow: hidden;
}

.na-img-wrap img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: transform 0.4s ease;
}

.na-card:hover .na-img-wrap img {
    transform: scale(1.07);
}

/* NEW pill badge */
.na-badge-new {
    position: absolute;
    top: 9px;
    left: 9px;
    background: #1a1a1a;
    color: #fff;
    font-size: 0.6rem;
    font-weight: 700;
    padding: 3px 9px;
    border-radius: 20px;
    letter-spacing: 1px;
    text-transform: uppercase;
}

/* Category pill badge */
.na-badge-cat {
    position: absolute;
    top: 9px;
    right: 9px;
    background: rgba(255, 255, 255, 0.88);
    color: #333;
    font-size: 0.6rem;
    font-weight: 600;
    padding: 3px 9px;
    border-radius: 20px;
    backdrop-filter: blur(4px);
    max-width: 90px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

/* Card text area */
.na-info {
    padding: 11px 12px 13px;
}

.na-name {
    font-size: 0.84rem;
    font-weight: 700;
    color: #1a1a1a;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    margin-bottom: 4px;
    line-height: 1.3;
}

.na-shop {
    font-size: 0.73rem;
    color: #6c757d;
    display: flex;
    align-items: center;
    gap: 5px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.na-shop i {
    font-size: 0.65rem;
    flex-shrink: 0;
    color: #aaa;
}

/* View All button for dark section */
.na-section .btn-outline-light {
    border-width: 2px;
    font-weight: 600;
    letter-spacing: 0.5px;
    padding: 0.65rem 2rem;
    border-radius: 50px;
}

/* ===================================
   FEATURES STRIP
   =================================== */
.features-strip {
    background: #111;
    padding: 26px 0;
    border-top: 1px solid #1e1e1e;
}

.features-strip .features-row {
    display: flex;
    align-items: center;
    justify-content: center;
    flex-wrap: wrap;
}

.features-strip .feature-item {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 10px 36px;
    flex: 1;
    min-width: 180px;
}

.features-strip .feature-icon {
    width: 44px;
    height: 44px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.07);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.1rem;
    color: #fff;
    flex-shrink: 0;
}

.features-strip .feature-text strong {
    display: block;
    font-size: 0.86rem;
    font-weight: 700;
    color: #fff;
    margin-bottom: 2px;
}

.features-strip .feature-text span {
    font-size: 0.74rem;
    color: rgba(255, 255, 255, 0.4);
    line-height: 1.3;
}

.features-strip .feature-divider {
    width: 1px;
    height: 34px;
    background: rgba(255, 255, 255, 0.09);
    flex-shrink: 0;
}

@media (max-width: 768px) {
    .features-strip .feature-divider { display: none; }
    .features-strip .feature-item { padding: 10px 20px; min-width: 160px; }
}

/* ===================================
   UTILITY CLASSES
   =================================== */
.text-grey {
    color: var(--text-secondary);
}

.bg-light-grey {
    background-color: var(--white-secondary);
}

.border-grey {
    border-color: var(--border-color);
}

.mt-section {
    margin-top: 4rem;
}

.mb-section {
    margin-bottom: 4rem;
}

/* ===================================
   MOBILE NAVBAR OVERRIDES (≤ 991px)
   Hides hamburger + collapse.
   Navigation is handled by the
   bottom tab bar injected by main.js.
   =================================== */
@media (max-width: 991.98px) {
    /* Collapse & toggler are replaced by the bottom bar */
    .navbar-toggler  { display: none !important; }
    .navbar-collapse { display: none !important; }

    /* Brand on the left, mobile icons on the right */
    .navbar .container-fluid {
        flex-wrap: nowrap;
        align-items: center;
    }

    /* Keep some room at the bottom for the fixed bar */
    body { padding-bottom: 64px; }
}

/* ── Mobile navbar icon row (search toggle + cart) ──────────────────── */
.mob-top-icons {
    display: none;
    align-items: center;
    gap: 18px;
    margin-left: auto;
}
@media (max-width: 991.98px) { .mob-top-icons { display: flex; } }

.mob-top-icons .mob-icon {
    background: none;
    border: none;
    color: rgba(255,255,255,0.9);
    font-size: 1.2rem;
    padding: 2px;
    position: relative;
    line-height: 1;
    text-decoration: none;
}
.mob-top-icons .mob-icon:hover { color: #fff; }

/* Reuse the same .cart-badge style for the top icon */
.mob-top-icons .cart-badge {
    top: -7px;
    right: -9px;
}

/* ── Mobile slide-down search bar ────────────────────────────────────── */
.mob-search-bar {
    overflow: hidden;
    max-height: 0;
    transition: max-height 0.25s ease, padding 0.25s ease;
    background: var(--primary-black);
    padding: 0 14px;
    position: sticky;
    top: 56px;           /* sit just below sticky navbar */
    z-index: 1028;
    border-bottom: 1px solid rgba(255,255,255,0.08);
}
.mob-search-bar.open {
    max-height: 60px;
    padding: 10px 14px;
}
.mob-search-bar .form-control {
    background: rgba(255,255,255,0.1);
    border: 1px solid rgba(255,255,255,0.22);
    border-right: none;
    color: #fff;
    font-size: 0.9rem;
    border-radius: 8px 0 0 8px;
}
.mob-search-bar .form-control::placeholder { color: rgba(255,255,255,0.45); }
.mob-search-bar .form-control:focus {
    background: rgba(255,255,255,0.16);
    border-color: rgba(255,255,255,0.45);
    color: #fff;
    box-shadow: none;
}
.mob-search-bar .btn-mob-search {
    background: rgba(255,255,255,0.15);
    border: 1px solid rgba(255,255,255,0.22);
    border-left: none;
    color: #fff;
    padding: 0 16px;
    border-radius: 0 8px 8px 0;
}
.mob-search-bar .btn-mob-search:hover { background: rgba(255,255,255,0.25); }

/* ── Mobile Bottom Tab Bar ───────────────────────────────────────────── */
.mob-bottom-bar {
    display: none;
    position: fixed;
    bottom: 0; left: 0; right: 0;
    height: 60px;
    background: var(--primary-black);
    z-index: 1040;
    border-top: 1px solid rgba(255,255,255,0.1);
    box-shadow: 0 -3px 14px rgba(0,0,0,0.25);
}
@media (max-width: 991.98px) { .mob-bottom-bar { display: flex; } }

.mob-tab {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    color: rgba(255,255,255,0.5);
    text-decoration: none;
    font-size: 9.5px;
    font-weight: 600;
    letter-spacing: 0.02em;
    gap: 3px;
    position: relative;
    transition: color 0.18s ease;
    padding-bottom: 2px;
}
.mob-tab i { font-size: 1.05rem; }
.mob-tab span { line-height: 1; }
.mob-tab:hover,
.mob-tab.active { color: #fff; }
.mob-tab.active::after {
    content: '';
    position: absolute;
    top: 0; left: 20%; right: 20%;
    height: 2px;
    background: #fff;
    border-radius: 0 0 3px 3px;
}

/* Cart badge inside bottom bar */
.mob-tab .mob-cart-dot {
    position: absolute;
    top: 6px;
    left: calc(50% + 5px);
    min-width: 15px;
    height: 15px;
    border-radius: 8px;
    background: #dc3545;
    color: #fff;
    font-size: 8.5px;
    font-weight: 700;
    display: none;
    align-items: center;
    justify-content: center;
    padding: 0 3px;
    line-height: 1;
}

/* ── Mobile Account Sheet (slide-up menu above bottom bar) ──────────── */
.mob-account-overlay {
    position: fixed;
    inset: 0;
    bottom: 60px;
    background: rgba(0,0,0,0.45);
    z-index: 1038;
    display: none;
}
.mob-account-overlay.open { display: block; }

.mob-account-sheet {
    position: fixed;
    bottom: 60px;
    left: 0; right: 0;
    background: #1c1c1c;
    border-top: 1px solid rgba(255,255,255,0.12);
    border-radius: 18px 18px 0 0;
    z-index: 1039;
    transform: translateY(100%);
    transition: transform 0.26s ease;
    padding-bottom: 6px;
    display: none;
}
@media (max-width: 991.98px) { .mob-account-sheet { display: block; } }
.mob-account-sheet.open { transform: translateY(0); }

.mob-account-sheet-handle {
    width: 38px; height: 4px;
    background: rgba(255,255,255,0.18);
    border-radius: 2px;
    margin: 12px auto 8px;
}
.mob-account-sheet-item {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 15px 22px;
    color: rgba(255,255,255,0.85);
    text-decoration: none;
    font-size: 0.95rem;
    font-weight: 500;
    border: none;
    background: none;
    width: 100%;
    text-align: left;
    cursor: pointer;
}
.mob-account-sheet-item i { width: 18px; text-align: center; font-size: 1rem; }
.mob-account-sheet-item:hover,
.mob-account-sheet-item:focus { background: rgba(255,255,255,0.07); color: #fff; }
.mob-account-sheet-item.danger { color: #ff6b6b; }
.mob-account-sheet-item.danger:hover { background: rgba(220,53,69,0.12); color: #ff4757; }

/* ===================================
   CSS-ONLY STAR RATING (rate-order.php)
   Stars rendered 5→1 in HTML, displayed
   left-to-right via flex-direction:row-reverse
   =================================== */
.star-rating-group {
    display: inline-flex;
    flex-direction: row-reverse;
    gap: 6px;
}

/* Hide the real radio buttons */
.sr-star-input {
    display: none;
}

/* Star icon label */
.sr-star-label {
    font-size: 2rem;
    color: #d0d0d0;
    cursor: pointer;
    transition: color 0.1s ease, transform 0.1s ease;
    line-height: 1;
}

/* Fill all stars at or below the checked one */
.sr-star-input:checked ~ .sr-star-label,
.sr-star-label:hover,
.sr-star-label:hover ~ .sr-star-label {
    color: #f5c518;
    transform: scale(1.1);
}
