:root {
    --bg-vino: radial-gradient(circle, #630000 0%, #3a0000 100%);
    --transition-speed: 1.5s;
}

/* RESET */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    width: 100%;
    min-height: 100vh;
    background: #2a0000;
    display: flex;
    flex-direction: column;
    align-items: center;
    overflow-x: hidden;
}

body {
    display: flex;
    flex-direction: column;
    min-height: 100vh;
}

.footer {
    margin-top: auto; /* 👈 ESTO ES LA CLAVE */
}

/* =====================
   FONDO CANVAS
===================== */
#lux-bg {
    position: fixed;
    inset: 0;
    z-index: 1;
    pointer-events: none;
}

/* =====================
   NAVBAR
===================== */
.top-nav {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 72px;
    padding: 0 1.5rem;
    display: flex;
    align-items: center;
    justify-content: space-between;

    background: rgba(26, 0, 0, 0.55);
    backdrop-filter: blur(8px);
    border-bottom: 1px solid rgba(212,175,55,0.15);

    transition:
            transform 0.45s ease,
            background 0.45s ease,
            height 0.45s ease;

    z-index: 100;
}

.top-nav.scrolled {
    background: rgba(18, 0, 0, 0.95);
    height: 60px;
}

.top-nav.hide {
    transform: translateY(-100%);
}

.nav-logo {
    font-size: 1.1rem;
    letter-spacing: 0.3em;
    color: rgba(212,175,55,0.9);
}

/* MENU DESKTOP */
.nav-menu {
    display: flex;
    gap: 1.2rem;
}

.nav-menu a {
    font-size: 0.75rem;
    letter-spacing: 0.15em;
    text-transform: uppercase;
    text-decoration: none;
    color: rgba(255,255,255,0.85);
    position: relative;
}

.nav-menu a::after {
    content: "";
    position: absolute;
    bottom: -4px;
    left: 0;
    width: 0;
    height: 1px;
    background: rgba(212,175,55,0.8);
    transition: width 0.3s ease;
}

.nav-menu a:hover::after {
    width: 100%;
}

/* HAMBURGER */
.hamburger {
    display: none;
    background: none;
    border: none;
    cursor: pointer;
}

.hamburger span {
    display: block;
    width: 22px;
    height: 2px;
    margin: 4px 0;
    background: rgba(212,175,55,0.9);
}

/* MOBILE MENU */
@media (max-width: 768px) {
    .hamburger {
        display: block;
    }

    .nav-menu {
        position: fixed;
        top: 72px;
        left: 0;
        width: 100%;
        background: rgba(26,0,0,0.95);
        flex-direction: column;
        align-items: center;
        gap: 1.5rem;
        padding: 2rem 0;
        transform: translateY(-120%);
        transition: transform 0.4s ease;
    }

    .nav-menu.active {
        transform: translateY(0);
    }
}

/* =====================
   LOGO
===================== */
.logo-container {
    position: relative;
    z-index: 10;
    width: 85%;
    max-width: 900px;
    margin-top: 6rem;
    opacity: 0;
    transform: scale(0.9);
    filter: drop-shadow(0 0 15px rgba(255, 255, 255, 0.1));
    animation: entradaLogo var(--transition-speed)
    cubic-bezier(0.22, 1, 0.36, 1) forwards;
}

@keyframes entradaLogo {
    from {
        opacity: 0;
        transform: scale(0.85) translateY(30px);
        filter: blur(10px);
    }
    to {
        opacity: 1;
        transform: scale(1) translateY(0);
        filter: blur(0) drop-shadow(0 10px 30px rgba(0,0,0,0.8));
    }
}

svg {
    width: 100%;
    height: auto;
    display: block;
}

/* SVG COLORS */
.cls-1 {
    fill: #8f0100;
    stroke: rgba(0,0,0,0.2);
    stroke-width: 0.5px;
}

.cls-2 {
    fill: #ffffff;
}

/* =====================
   BOTONES CTA
===================== */
.cta-wrapper {
    margin-top: 2.5rem;
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 1.2rem;
    flex-wrap: wrap;
    z-index: 10;
}

.cta-postres {
    display: inline-block;
    padding: 0.9rem 2.8rem;
    font-size: 0.85rem;
    letter-spacing: 0.25em;
    text-transform: uppercase;
    text-decoration: none;

    color: rgba(212, 175, 55, 0.85);
    border: 1px solid rgba(212, 175, 55, 0.35);
    border-radius: 50px;
    background: transparent;

    transition:
            color 0.4s ease,
            border-color 0.4s ease,
            background 0.4s ease,
            transform 0.4s ease,
            box-shadow 0.4s ease;
}

.cta-postres:hover {
    color: #1a0000;
    background: rgba(212, 175, 55, 0.9);
    border-color: rgba(212, 175, 55, 0.9);
    transform: translateY(-2px);
    box-shadow: 0 10px 25px rgba(212, 175, 55, 0.25);
}

/* =====================
   ESTADOS (Loader / Error)
===================== */
.estado-msg {
    text-align: center;
    padding: 4rem 1rem;
    color: var(--dorado);
    font-size: 1.2rem;
}

.spinner {
    width: 40px;
    height: 40px;
    border: 3px solid rgba(212,175,55,0.3);
    border-radius: 50%;
    border-top-color: var(--dorado);
    animation: spin 1s ease-in-out infinite;
    margin: 0 auto 1rem;
}

@keyframes spin { to { transform: rotate(360deg); } }

.estado-msg button {
    background: var(--dorado);
    color: var(--vino-oscuro);
    border: none;
    padding: 0.5rem 1.5rem;
    margin-top: 1rem;
    cursor: pointer;
    font-weight: bold;
    border-radius: 4px;
}

/* =====================
   PRODUCTO AGOTADO
===================== */
.producto.agotado {
    filter: grayscale(0.8); /* Se pone grisáceo */
    opacity: 0.8;
    pointer-events: none; /* No clickeable */
}

.etiqueta-agotado {
    background: #8f0100; /* Rojo vino fuerte */
    color: #fff;
    padding: 4px 8px;
    font-size: 0.9rem;
    font-weight: bold;
    border-radius: 4px;
    border: 1px solid rgba(255,255,255,0.2);
    display: inline-block;
    margin-top: 5px;
}

/* Ajuste para que la info siempre quede abajo */
.producto {
    background-size: cover;
    background-position: center;
    min-height: 200px; /* Altura mínima para que se vea la imagen */
    display: flex;
    align-items: flex-end; /* Texto abajo */
    padding: 1rem;
    position: relative;
    /* Sombras para leer texto sobre imagen */
    box-shadow: inset 0 -60px 40px -10px rgba(0,0,0,0.8);
}

.info-producto {
    width: 100%;
}

.info-producto h3 {
    margin-bottom: 0.3rem;
    font-size: 1.1rem;
    text-shadow: 1px 1px 3px rgba(0,0,0,0.8);
}

.precio {
    color: var(--dorado);
    font-weight: bold;
    text-shadow: 1px 1px 2px rgba(0,0,0,1);
}