:root {
    --primary: #f0ebe1;
    --burgundy: #e05575;
    --burgundy-light: #ff7596;
    --beige: #1a1a24;
    --beige-dark: #2a2a35;
    --beige-light: #0e0e12;
    --text-color: #e8e8f0;
    --secondary-text: #9a9ab0;
    --bg-color: #1a1a24;
    --card-bg: #16161d;
    --border-color: #2a2a35;
    --shadow: 0 10px 40px rgba(0, 0, 0, 0.5);
    --hover-shadow: 0 20px 50px rgba(0, 0, 0, 0.8);
    --font-heading: 'Outfit', sans-serif;
    --font-body: 'Inter', sans-serif;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: var(--font-body);
}

body {
    background-color: var(--beige-light);
    color: var(--text-color);
    line-height: 1.6;
    overflow-x: hidden;
}

h1,
h2,
h3,
h4,
.logo-text {
    font-family: var(--font-heading);
}

a {
    text-decoration: none;
    color: inherit;
    transition: 0.3s;
}

/* Base Components Output */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0.8rem 1.8rem;
    border-radius: 50px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    border: 2px solid transparent;
}

.btn-primary {
    background: var(--burgundy);
    color: white;
    border-color: var(--burgundy);
}

.btn-primary:hover {
    background: #c23b56;
    border-color: #c23b56;
    box-shadow: 0 10px 25px rgba(194, 59, 86, 0.4);
    transform: translateY(-2px);
}

.btn-secondary {
    background: transparent;
    border-color: var(--burgundy);
    color: var(--burgundy);
}

.btn-secondary:hover {
    background: var(--burgundy);
    color: white;
    transform: translateY(-2px);
    box-shadow: 0 10px 25px rgba(194, 59, 86, 0.3);
}

.badge {
    position: absolute;
    top: 1rem;
    left: 1rem;
    background: var(--card-bg);
    color: var(--text-color);
    padding: 0.4rem 1rem;
    border-radius: 30px;
    font-size: 0.8rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1px;
    box-shadow: var(--shadow);
    border: 1px solid var(--border-color);
    z-index: 10;
}

/* Nav */
.navbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1.5rem 5%;
    background: rgba(14, 14, 18, 0.95);
    backdrop-filter: blur(10px);
    position: sticky;
    top: 0;
    width: 100%;
    z-index: 1000;
    box-shadow: 0 4px 30px rgba(0, 0, 0, 0.3);
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.logo-text {
    font-size: 1.8rem;
    font-weight: 800;
    color: var(--burgundy);
    letter-spacing: -1px;
}

.nav-links {
    display: flex;
    gap: 2rem;
    align-items: center;
}

.nav-links a {
    font-weight: 500;
    color: var(--secondary-text);
}

.nav-links a:hover {
    color: var(--burgundy);
}

.nav-actions {
    display: flex;
    align-items: center;
    gap: 1.5rem;
}

.cart-icon-btn {
    position: relative;
    background: none;
    border: none;
    font-size: 1.5rem;
    cursor: pointer;
    color: var(--primary);
    transition: 0.3s;
}

.cart-icon-btn:hover {
    transform: translateY(-2px);
    color: var(--burgundy);
}

#cartIconCount {
    position: absolute;
    top: -5px;
    right: -10px;
    background: var(--burgundy);
    color: white;
    font-size: 0.7rem;
    font-weight: 700;
    width: 20px;
    height: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    border: 2px solid white;
}

/* Toast Notifications */
.toast {
    position: fixed;
    bottom: 30px;
    right: 30px;
    background: rgba(22, 22, 29, 0.95);
    backdrop-filter: blur(10px);
    color: var(--text-color);
    padding: 1.2rem 1.5rem;
    border-radius: 12px;
    box-shadow: 0 10px 40px rgba(0,0,0,0.5);
    border-left: 5px solid #2ecc71;
    border-top: 1px solid var(--border-color);
    border-right: 1px solid var(--border-color);
    border-bottom: 1px solid var(--border-color);
    font-weight: 500;
    z-index: 9999;
    transform: translateX(120%);
    transition: transform 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    max-width: 350px;
}

.toast.show {
    transform: translateX(0);
}

.toast-error {
    border-left: 5px solid var(--burgundy);
}

/* Hero Section */
.hero-stacked {
    display: flex;
    flex-direction: column;
}

.hero-banner {
    position: relative;
    width: 100%;
    height: 60vh;
    min-height: 500px;
    display: flex;
    align-items: center;
    justify-content: center;
    background-size: cover;
    background-position: center;
    background-attachment: fixed;
    text-align: center;
    padding: 2rem;
}

.banner-badge {
    display: inline-block;
    padding: 0.5rem 1.5rem;
    border-radius: 50px;
    background: rgba(255, 255, 255, 0.9);
    font-size: 0.8rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 2px;
    margin-bottom: 1.5rem;
    color: var(--burgundy);
}

.hero-content h1 {
    font-size: 4rem;
    margin-bottom: 1rem;
    letter-spacing: -2px;
    color: var(--primary);
    line-height: 1.1;
}

.hero-content p {
    font-size: 1.2rem;
    max-width: 600px;
    margin: 0 auto 2rem;
    color: var(--secondary-text);
}

.hero-content.dark-content .banner-badge {
    background: rgba(0, 0, 0, 0.5);
    border: 1px solid var(--border-color);
    color: var(--primary);
}

.scrolling-banner {
    background: var(--burgundy);
    color: var(--primary);
    padding: 0.8rem;
    overflow: hidden;
    position: relative;
    border-top: 1px solid var(--border-color);
    border-bottom: 1px solid var(--border-color);
}

.scrolling-banner-content {
    white-space: nowrap;
    animation: scrollBanner 25s linear infinite;
    font-weight: 600;
    letter-spacing: 1px;
    font-size: 0.95rem;
}

@keyframes scrollBanner {
    0% {
        transform: translateX(100vw);
    }

    100% {
        transform: translateX(-100%);
    }
}

/* Product Layout */
.container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 4rem 5%;
}

.shop-layout {
    display: grid;
    grid-template-columns: 250px 1fr;
    gap: 3rem;
}

.sidebar {
    position: sticky;
    top: 100px;
    height: max-content;
}

.filter-group {
    background: var(--card-bg);
    padding: 1.5rem;
    border-radius: 16px;
    margin-bottom: 1.5rem;
    box-shadow: var(--shadow);
    border: 1px solid var(--border-color);
}

.filter-group h4 {
    margin-bottom: 1rem;
    padding-bottom: 0.5rem;
    border-bottom: 1px solid var(--border-color);
    font-size: 1.1rem;
}

.filter-group label {
    display: flex;
    align-items: center;
    gap: 0.8rem;
    margin-bottom: 0.8rem;
    cursor: pointer;
    color: var(--secondary-text);
    transition: 0.2s;
}

.filter-group label:hover {
    color: var(--primary);
    transform: translateX(4px);
}

select {
    width: 100%;
    padding: 0.8rem;
    border: 1px solid var(--border-color);
    border-radius: 8px;
    background: var(--beige-light);
    font-family: var(--font-body);
    outline: none;
}

.product-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 2rem;
}

.product-card {
    background: var(--card-bg);
    border-radius: 20px;
    overflow: hidden;
    box-shadow: var(--shadow);
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    border: 1px solid var(--border-color);
    position: relative;
    animation: fadeUp 0.6s cubic-bezier(0.16, 1, 0.3, 1) backwards;
}

.product-card:hover {
    transform: translateY(-10px) scale(1.02);
    box-shadow: var(--hover-shadow);
}

.product-image {
    position: relative;
    width: 100%;
    height: 380px;
    overflow: hidden;
}

.product-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.6s cubic-bezier(0.4, 0, 0.2, 1);
    background: var(--border-color);
}

.product-card:hover .product-image img {
    transform: scale(1.08);
}

.product-info {
    padding: 1.5rem;
}

.product-vendor {
    font-size: 0.8rem;
    color: var(--secondary-text);
    text-transform: uppercase;
    letter-spacing: 1px;
    font-weight: 600;
}

.product-title {
    font-size: 1.2rem;
    margin: 0.5rem 0;
    color: var(--primary);
}

.product-price {
    font-weight: 700;
    font-size: 1.3rem;
    color: var(--burgundy);
    margin-bottom: 1.5rem;
}

.product-actions {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0.5rem;
}

.product-actions button {
    opacity: 0;
    transform: translateY(10px);
    transition: 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.product-card:hover .product-actions button {
    opacity: 1;
    transform: translateY(0);
}

.product-actions button:nth-child(2) {
    transition-delay: 0.05s;
}

/* Authentication Layouts */
.auth-header {
    text-align: center;
    padding: 2rem 0;
}

.auth-wrapper {
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: calc(100vh - 150px);
    padding: 2rem;
}

.auth-card {
    background: var(--card-bg);
    width: 100%;
    max-width: 600px;
    padding: 3rem;
    border-radius: 24px;
    box-shadow: var(--shadow);
    border: 1px solid var(--border-color);
}

.login-toggle {
    display: flex;
    background: var(--beige-light);
    border-radius: 12px;
    padding: 0.5rem;
    margin-bottom: 2.5rem;
    border: 1px solid var(--border-color);
}

.login-toggle button {
    flex: 1;
    padding: 0.8rem;
    border: none;
    background: transparent;
    font-weight: 600;
    cursor: pointer;
    border-radius: 8px;
    transition: 0.3s;
    color: var(--secondary-text);
}

.login-toggle button.active {
    background: var(--card-bg);
    color: var(--burgundy);
    box-shadow: var(--shadow);
    border: 1px solid var(--border-color);
}

.form-group {
    margin-bottom: 1.5rem;
}

.form-group label {
    display: block;
    margin-bottom: 0.5rem;
    font-weight: 500;
    color: var(--text-color);
    font-size: 0.95rem;
}

.form-group input,
.form-group textarea {
    width: 100%;
    padding: 1rem;
    border: 2px solid var(--beige-dark);
    border-radius: 12px;
    font-family: var(--font-body);
    outline: none;
    transition: 0.3s;
    background: var(--beige-light);
}

.form-group input:focus,
.form-group textarea:focus {
    border-color: var(--burgundy);
    background: var(--card-bg);
    box-shadow: 0 0 0 4px rgba(161, 31, 55, 0.3);
}

/* Dashboards (Admin & Vendor) */
.dashboard-layout {
    display: flex;
    min-height: 100vh;
    background: var(--beige-light);
}

.dashboard-sidebar {
    width: 280px;
    background: var(--card-bg);
    padding: 2rem;
    border-right: 1px solid var(--border-color);
    position: fixed;
    height: 100vh;
    overflow-y: auto;
    z-index: 10;
}

.user-profile {
    display: flex;
    flex-direction: column;
    padding: 1.5rem;
    background: linear-gradient(135deg, rgba(161, 31, 55, 0.05), rgba(161, 31, 55, 0.01));
    border-radius: 16px;
    margin-bottom: 2.5rem;
    border: 1px solid rgba(161, 31, 55, 0.1);
}

.user-profile p {
    font-size: 0.85rem;
    color: var(--secondary-text);
    text-transform: uppercase;
    letter-spacing: 1px;
}

.dashboard-nav {
    list-style: none;
}

.dashboard-nav a {
    display: block;
    padding: 0.9rem 1.2rem;
    border-radius: 8px;
    color: var(--secondary-text);
    font-weight: 500;
    margin-bottom: 0.3rem;
    transition: 0.2s;
}

.dashboard-nav a:hover {
    background: var(--beige-light);
    color: var(--primary);
    transform: translateX(4px);
}

.dashboard-nav a.active {
    background: var(--burgundy);
    color: white;
}

.dashboard-content {
    flex: 1;
    margin-left: 280px;
    padding: 3rem;
}

.dashboard-content h2 {
    font-size: 2rem;
    margin-bottom: 0.5rem;
}

.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
    gap: 1.5rem;
    margin-bottom: 2rem;
}

.stat-card {
    background: var(--card-bg);
    padding: 2rem;
    border-radius: 20px;
    box-shadow: var(--shadow);
    border: 1px solid var(--border-color);
}

.stat-card h3 {
    font-size: 2.5rem;
    color: var(--primary);
    margin-bottom: 0.5rem;
    line-height: 1;
}

.stat-card p {
    color: var(--secondary-text);
    font-weight: 500;
}

.card {
    background: var(--card-bg);
    padding: 2.5rem;
    border-radius: 20px;
    box-shadow: var(--shadow);
    border: 1px solid var(--border-color);
}

table {
    width: 100%;
    border-collapse: separate;
    border-spacing: 0;
}

th,
td {
    padding: 1.5rem 1rem;
    text-align: left;
    border-bottom: 1px solid var(--border-color);
}

th {
    color: var(--secondary-text);
    font-weight: 600;
    font-size: 0.9rem;
    text-transform: uppercase;
    letter-spacing: 1px;
}

td {
    vertical-align: middle;
}

.hidden {
    display: none !important;
}

@keyframes fadeUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Footer */
.ultra-footer {
    background: #0a0a0a;
    color: white;
    padding: 6rem 5% 3rem;
    margin-top: 4rem;
}

.footer-grid {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr 1.5fr;
    gap: 4rem;
    margin-bottom: 4rem;
    max-width: 1400px;
    margin: 0 auto;
}

.footer-col h3 {
    color: white;
    margin-bottom: 1.5rem;
    font-size: 1.2rem;
}

.footer-col p {
    color: #888;
    line-height: 1.8;
}

.footer-links {
    list-style: none;
}

.footer-links li {
    margin-bottom: 0.8rem;
}

.footer-links a {
    color: #888;
}

.footer-links a:hover {
    color: var(--burgundy-light);
    padding-left: 5px;
}

.footer-bottom {
    text-align: center;
    padding-top: 3rem;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    color: #555;
    font-size: 0.9rem;
}

/* =========================================
   📱 MOBILE RESPONSIVENESS (Global)
   ========================================= */
@media (max-width: 900px) {
    .shop-layout {
        grid-template-columns: 1fr;
    }
    .sidebar {
        position: static;
        display: flex;
        flex-direction: column;
        gap: 1rem;
    }
    .filter-group {
        margin-bottom: 0;
    }
    .dashboard-layout {
        flex-direction: column;
    }
    .dashboard-sidebar {
        width: 100%;
        height: auto;
        position: relative;
        padding: 1.5rem;
        border-right: none;
        border-bottom: 1px solid var(--border-color);
        display: flex;
        flex-direction: column;
    }
    .dashboard-content {
        margin-left: 0;
        padding: 1.5rem;
    }
    .dashboard-nav {
        display: flex;
        overflow-x: auto;
        gap: 0.5rem;
        padding-bottom: 1rem;
    }
    .dashboard-nav a {
        white-space: nowrap;
        margin-bottom: 0;
    }
    .footer-grid {
        grid-template-columns: 1fr 1fr;
        gap: 2rem;
    }
}

@media (max-width: 768px) {
    .navbar {
        padding: 1rem 5%;
        flex-wrap: wrap;
        gap: 1rem;
        justify-content: center;
    }
    .nav-links {
        order: 3;
        width: 100%;
        justify-content: center;
        margin-top: 0.5rem;
        gap: 1.5rem;
    }
    .logo-text {
        font-size: 1.6rem;
    }
    .hero-banner {
        min-height: 400px;
        height: auto;
        padding: 4rem 1rem;
    }
    .hero-content h1 {
        font-size: 2.5rem;
        line-height: 1.1;
    }
    .hero-content p {
        font-size: 1rem;
    }
    .feature-strip {
        gap: 1rem;
        flex-direction: column;
        text-align: center;
    }
    .products-grid, .product-grid {
        grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
        gap: 1rem;
    }
    .product-image {
        height: 280px;
    }
    .product-title {
        font-size: 1.1rem;
    }
    .auth-card {
        padding: 1.5rem;
        border-radius: 16px;
    }
    .auth-wrapper {
        padding: 1rem;
    }
    .form-grid-2 {
        grid-template-columns: 1fr;
        gap: 0;
    }
    .stats-grid {
        grid-template-columns: 1fr;
    }
    .card {
        padding: 1.5rem;
        overflow-x: auto;
    }
    .footer-grid {
        grid-template-columns: 1fr;
        text-align: center;
    }
    .ultra-footer {
        padding: 3rem 5% 2rem;
    }
}

@media (max-width: 480px) {
    .products-grid, .product-grid {
        grid-template-columns: 1fr;
    }
    .product-image {
        height: 350px;
    }
    .shop-cta-row {
        flex-direction: column;
    }
    .shop-cta-btn {
        width: 100%;
    }
    #signupMap {
        height: 180px;
    }
}