/* ==========================================================================
   FiveM WebStore — global design system
   "Salvatores" noir theme: void-black background, gold/blood gradients,
   glassmorphism cards, smooth motion, accessible focus states.
   Matches the colors used on index.html / login.html.
   ========================================================================== */

:root {
    --bg-deep: #100a0b;
    --bg-panel: #1b1214;
    --gold-bright: #eccf8d;
    --gold: #c6a15b;
    --gold-dim: #8a6a34;
    --blood-bright: #a52c3a;
    --blood: #7a1a26;
    --blood-dim: #5c131c;

    /* legacy aliases so any code still referencing the old neon vars
       (e.g. cached HTML) resolves to the new palette instead of purple */
    --neon-purple: var(--gold);
    --neon-blue: var(--blood);
    --neon-cyan: var(--gold-bright);
    --neon-pink: var(--blood-bright);
}

* {
    scrollbar-width: thin;
    scrollbar-color: rgba(198, 161, 91, 0.6) transparent;
}

*::-webkit-scrollbar {
    width: 8px;
    height: 8px;
}

*::-webkit-scrollbar-thumb {
    background: linear-gradient(180deg, var(--gold), var(--blood));
    border-radius: 999px;
}

html {
    scroll-behavior: smooth;
}

body {
    background-color: var(--bg-deep);
    background-image:
        radial-gradient(ellipse 80% 60% at 100% -10%, rgba(122, 26, 38, 0.28), transparent 60%),
        radial-gradient(ellipse 70% 60% at 0% 100%, rgba(198, 161, 91, 0.14), transparent 60%),
        radial-gradient(ellipse 60% 50% at 50% 0%, rgba(198, 161, 91, 0.08), transparent 60%);
    background-attachment: fixed;
    font-family: 'Vazirmatn', 'Inter', system-ui, -apple-system, sans-serif;
    color: #ece3d0;
    min-height: 100vh;
}

/* ---------------------------------- Glass ---------------------------------- */
.glass {
    background: rgba(236, 227, 208, 0.03);
    backdrop-filter: blur(18px);
    -webkit-backdrop-filter: blur(18px);
    border: 1px solid rgba(198, 161, 91, 0.16);
}

.glass-strong {
    background: rgba(27, 18, 20, 0.82);
    backdrop-filter: blur(24px);
    -webkit-backdrop-filter: blur(24px);
    border: 1px solid rgba(198, 161, 91, 0.2);
}

.card-hover {
    transition: transform 0.35s cubic-bezier(0.22, 1, 0.36, 1), box-shadow 0.35s ease, border-color 0.35s ease;
}

.card-hover:hover {
    transform: translateY(-6px);
    border-color: rgba(198, 161, 91, 0.5);
    box-shadow: 0 20px 60px -15px rgba(122, 26, 38, 0.45);
}

/* --------------------------------- Gradients -------------------------------- */
.text-gradient {
    background: linear-gradient(90deg, var(--gold-bright), var(--gold), var(--blood-bright));
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
}

.btn-primary {
    background-image: linear-gradient(135deg, var(--blood-bright), var(--blood));
    box-shadow: 0 10px 30px -10px rgba(122, 26, 38, 0.6);
    transition: transform 0.2s ease, box-shadow 0.2s ease, filter 0.2s ease;
}

.btn-primary:hover {
    filter: brightness(1.1);
    transform: translateY(-2px);
    box-shadow: 0 14px 36px -8px rgba(165, 44, 58, 0.75);
}

.btn-primary:active {
    transform: translateY(0);
}

.btn-primary:disabled {
    opacity: 0.5;
    cursor: not-allowed;
    transform: none;
}

.btn-ghost {
    background: rgba(198, 161, 91, 0.06);
    border: 1px solid rgba(198, 161, 91, 0.18);
    transition: background 0.2s ease, border-color 0.2s ease;
}

.btn-ghost:hover {
    background: rgba(198, 161, 91, 0.14);
    border-color: rgba(198, 161, 91, 0.5);
}

/* ---------------------------------- Badges ---------------------------------- */
.badge-discount { background: linear-gradient(90deg, var(--blood-bright), var(--blood)); }
.badge-new { background: linear-gradient(90deg, var(--gold), var(--blood-bright)); }
.badge-popular { background: linear-gradient(90deg, var(--gold-bright), var(--gold-dim)); }

.badge {
    display: inline-flex;
    align-items: center;
    padding: 0.15rem 0.6rem;
    border-radius: 9999px;
    font-weight: 600;
    line-height: 1.4;
}

.badge-purple { background: rgba(198, 161, 91, 0.18); color: var(--gold-bright); }
.badge-cyan { background: rgba(198, 161, 91, 0.18); color: var(--gold-bright); }
.badge-amber { background: rgba(198, 161, 91, 0.18); color: var(--gold-bright); }
.badge-emerald { background: rgba(16, 185, 129, 0.18); color: #6ee7b7; }
.badge-rose { background: rgba(165, 44, 58, 0.2); color: #e78a92; }

/* --------------------------------- Animations -------------------------------- */
@keyframes fade-in-up {
    from { opacity: 0; transform: translateY(16px); }
    to { opacity: 1; transform: translateY(0); }
}
.animate-fade-in-up { animation: fade-in-up 0.6s cubic-bezier(0.22, 1, 0.36, 1) both; }

@keyframes glow-pulse {
    0%, 100% { box-shadow: 0 0 0 0 rgba(198, 161, 91, 0.45); }
    50% { box-shadow: 0 0 0 10px rgba(198, 161, 91, 0); }
}
.animate-glow { animation: glow-pulse 2.4s ease-in-out infinite; }

@keyframes float-y {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-10px); }
}
.animate-float { animation: float-y 5s ease-in-out infinite; }

@keyframes skeleton-shimmer {
    0% { background-position: -400px 0; }
    100% { background-position: 400px 0; }
}
.skeleton {
    background: linear-gradient(90deg, rgba(236,227,208,0.05) 25%, rgba(236,227,208,0.12) 37%, rgba(236,227,208,0.05) 63%);
    background-size: 800px 100%;
    animation: skeleton-shimmer 1.6s linear infinite;
    border-radius: 0.75rem;
}

@keyframes spin-slow { to { transform: rotate(360deg); } }
.animate-spin-slow { animation: spin-slow 6s linear infinite; }

/* ------------------------------- Toasts / Modals ------------------------------ */
#toast-root {
    position: fixed;
    top: 1rem;
    right: 1rem;
    z-index: 9999;
    display: flex;
    flex-direction: column;
    gap: 0.6rem;
    width: min(360px, calc(100vw - 2rem));
}

.toast {
    animation: fade-in-up 0.35s ease both;
}

.modal-backdrop {
    background: rgba(16, 10, 11, 0.8);
    backdrop-filter: blur(4px);
}

/* --------------------------------- Utilities --------------------------------- */
.input-field {
    background: rgba(236, 227, 208, 0.04);
    border: 1px solid rgba(198, 161, 91, 0.18);
    color: #ece3d0;
    transition: border-color 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

.input-field:focus {
    outline: none;
    border-color: var(--gold);
    box-shadow: 0 0 0 3px rgba(198, 161, 91, 0.25);
    background: rgba(236, 227, 208, 0.07);
}

.nav-link {
    position: relative;
    transition: color 0.2s ease;
}

.nav-link.active {
    color: #fff;
}

.nav-link.active::after {
    content: '';
    position: absolute;
    left: 0;
    right: 0;
    bottom: -6px;
    height: 2px;
    border-radius: 2px;
    background: linear-gradient(90deg, var(--gold), var(--blood-bright));
}

[x-cloak] { display: none !important; }

.focus-ring:focus-visible {
    outline: 2px solid var(--gold);
    outline-offset: 2px;
}

select option {
    background: #221619;
    color: #fff;
}
