@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700&display=swap');

:root {
    /* Colors - Dynamically injected from Tenant or fallback to default */
    --color-primary: var(--primary, #FFC107);
    --color-primary-hover: var(--secondary, #FFB300);
    --color-background: var(--bg, #0F0F0F);
    --color-surface: var(--bg-card, #1A1A1A);
    --color-surface-hover: rgba(255, 255, 255, 0.05);
    /* Derived or subtle change */
    --color-border-base: color-mix(in srgb, var(--color-text-main), transparent 90%);
    --color-border: var(--border-override, var(--color-border-base));
    /* Subtle border based on theme */

    /* Text Colors */
    --color-text-main: var(--text, #FFFFFF);
    /* Smart Text Muted: If background is light, use darker muted. If dark, use lighter muted. */
    --color-text-muted: color-mix(in srgb, var(--color-text-main), transparent 40%);
    --color-text-dark: #121212;

    /* New Configurable Variables */
    --color-navbar-bg: var(--navbar-bg, var(--bg-card));
    --color-nav-text: var(--nav-text, var(--color-text-muted));
    --color-border-override: var(--border-override, var(--color-border));
    --color-success: var(--success-color, #22c55e);

    /* Specific Component Colors */
    --color-btn-bg: var(--btn-bg, var(--primary, #FFC107));
    --color-btn-text: var(--btn-text, #000000);
    --color-link: var(--link-color, var(--primary, #FFC107));

    /* Brand Colors */
    --color-discord: #5865F2;
    --color-discord-hover: #4752C4;

    /* Spacing & Utilities */
    --container-width: 1200px;
    --border-radius: var(--radius, 12px);
    --card-shadow: 0 4px 20px rgba(0, 0, 0, 0.5);
    --transition: all 0.3s ease;
}

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

/* Remove number input arrows */
input[type=number]::-webkit-outer-spin-button,
input[type=number]::-webkit-inner-spin-button {
    -webkit-appearance: none;
    appearance: none;
    margin: 0;
}

input[type=number] {
    -moz-appearance: textfield;
    appearance: textfield;
}

body {
    font-family: 'Inter', sans-serif;
    background-color: var(--color-background);
    color: var(--color-text-main);
    line-height: 1.6;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    margin: 0;
}

/* Custom Scrollbar */
::-webkit-scrollbar {
    width: 10px;
    height: 10px;
}

::-webkit-scrollbar-track {
    background: var(--color-background);
}

::-webkit-scrollbar-thumb {
    background: rgba(255, 255, 255, 0.1);
    border-radius: 5px;
    border: 2px solid var(--color-background);
    background-clip: content-box;
}

::-webkit-scrollbar-thumb:hover {
    background: var(--color-primary);
    border: 2px solid var(--color-background);
    background-clip: content-box;
}

main {
    flex: 1;
}

/* Typography */
h1,
h2,
h3,
h4,
h5,
h6 {
    font-weight: 700;
    color: var(--color-text-main);
}

.hero-title {
    font-size: 3.5rem;
}

.hero-subtitle {
    font-size: 1.25rem;
}

a {
    text-decoration: none;
    color: var(--color-link);
    transition: var(--transition);
}

/* Layout Utilities */
.container {
    max-width: var(--container-width);
    margin: 0 auto;
    padding: 0 20px;
}

/* Components: Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 10px 24px;
    border-radius: 8px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
    border: none;
    font-size: 0.95rem;
    gap: 8px;
    position: relative;
    user-select: none;
}

.btn i {
    font-size: 1.1em;
}

.btn:active {
    transform: scale(0.96);
}

.btn-primary {
    background-color: var(--color-btn-bg);
    color: var(--color-btn-text);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
}

.btn-primary:hover {
    filter: brightness(1.1);
    transform: translateY(-2px);
    box-shadow: 0 6px 18px rgba(0, 0, 0, 0.3);
}

.btn-outline {
    background: transparent;
    border: 1px solid var(--color-border);
    color: var(--color-text-main);
}

.btn-outline:hover {
    border-color: var(--color-primary);
    color: var(--color-primary);
    background: rgba(255, 193, 7, 0.08);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
}

/* Discord Premium Button */
.btn-discord {
    background-color: var(--color-discord);
    color: #ffffff;
    box-shadow: 0 0 0 0 rgba(88, 101, 242, 0);
}

.btn-discord:hover {
    background-color: var(--color-discord-hover);
    transform: translateY(-2px);
    box-shadow: 0 4px 15px rgba(88, 101, 242, 0.4);
}

/* Components: Cards (Referencia CentralCart + Gold) */
.card {
    background-color: var(--color-surface);
    border-radius: var(--border-radius);
    padding: 24px;
    border: 1px solid var(--color-border);
    transition: var(--transition);
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.05), 0 2px 4px -1px rgba(0, 0, 0, 0.03);
}

.card:hover {
    border-color: var(--color-primary);
    transform: translateY(-4px);
    box-shadow: var(--card-shadow);
}

/* Header/Navbar */
.navbar {
    background-color: var(--color-navbar-bg);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid var(--color-border);
    position: sticky;
    top: 0;
    z-index: 1000;
    padding: 12px 0;
    transition: var(--transition);
}

.navbar-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.brand {
    font-size: 1.25rem;
    font-weight: 800;
    color: var(--color-text-main);
    display: flex;
    align-items: center;
    gap: 10px;
    z-index: 1001;
}

.brand i {
    color: var(--color-primary);
}

.nav-links {
    display: flex;
    gap: 24px;
    align-items: center;
}

.nav-link {
    color: var(--color-nav-text);
    font-weight: 500;
    position: relative;
    padding: 8px 0;
    font-size: 0.9rem;
}

.nav-link::after {
    content: '';
    position: absolute;
    width: 0;
    height: 2px;
    bottom: 2px;
    left: 0;
    background-color: var(--color-primary);
    transition: width 0.3s ease;
}

.nav-link:hover,
.nav-link.active {
    color: var(--color-link);
}

.nav-link:hover::after,
.nav-link.active::after {
    width: 100%;
}

/* Mobile Menu Toggle */
.menu-toggle {
    display: none;
    background: none;
    border: none;
    color: var(--color-text-main);
    font-size: 1.5rem;
    cursor: pointer;
    z-index: 1001;
}

/* --- RESPONSIVE DESIGN --- */

/* Laptops & Tablets (992px) */
@media (max-width: 992px) {
    :root {
        --container-width: 100%;
    }

    .hero h1 {
        font-size: 2.8rem !important;
    }

    .shop-layout {
        grid-template-columns: 1fr !important;
        gap: 24px !important;
    }

    .shop-sidebar {
        position: static !important;
        display: flex !important;
        flex-wrap: nowrap !important;
        overflow-x: auto !important;
        padding-bottom: 10px !important;
        gap: 10px !important;
        -webkit-overflow-scrolling: touch;
    }

    .shop-sidebar::-webkit-scrollbar {
        height: 4px;
    }

    .cat-link {
        white-space: nowrap !important;
        margin-bottom: 0 !important;
    }

    .sidebar-title {
        display: none !important;
    }
}

/* Mobile (768px) */
@media (max-width: 768px) {
    .menu-toggle {
        display: block;
    }

    .nav-links {
        position: fixed;
        top: 0;
        right: -100%;
        width: 80%;
        height: 100vh;
        background: var(--color-surface);
        flex-direction: column;
        justify-content: center;
        gap: 30px;
        transition: right 0.4s cubic-bezier(0.4, 0, 0.2, 1);
        box-shadow: -10px 0 30px rgba(0, 0, 0, 0.5);
        z-index: 1000;
    }

    .nav-links.active {
        right: 0;
    }

    .hero {
        padding: 60px 0 !important;
    }

    .hero h1 {
        font-size: 2.2rem !important;
    }

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

    .cta-group {
        flex-direction: column !important;
        width: 100%;
        max-width: 300px;
        margin: 0 auto;
    }

    .cta-group .btn {
        width: 100%;
    }

    .products-grid {
        grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)) !important;
        gap: 16px !important;
    }

    .product-card {
        padding: 0 !important;
    }

    .product-body {
        padding: 15px !important;
    }

    .navbar-actions {
        order: 2;
    }

    .brand {
        order: 1;
    }

    .menu-toggle {
        order: 3;
    }
}

/* Small Device (480px) */
@media (max-width: 480px) {
    .container {
        padding: 0 15px;
    }

    .hero h1 {
        font-size: 1.8rem !important;
    }

    .products-grid {
        grid-template-columns: 1fr !important;
    }

    .navbar {
        padding: 10px 0;
    }
}

/* Utilities */
.overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(4px);
    z-index: 999;
    display: none;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.overlay.active {
    display: block;
    opacity: 1;
}