/* =========================================================
   CHAVES ONLINE — SITE GLOBAL
   Estilo: Panadería premium / cálido / elegante
========================================================= */


/* =========================================================
   RESET
========================================================= */

*,
*::before,
*::after {
    box-sizing: border-box;
}

html {
    margin: 0;
    padding: 0;
    scroll-behavior: smooth;
}

body {
    margin: 0;
    padding: 0;
}

img {
    display: block;
    max-width: 100%;
}

a {
    color: inherit;
    text-decoration: none;
}

button,
input,
textarea,
select {
    font: inherit;
}

button {
    cursor: pointer;
}


/* =========================================================
   VARIABLES
========================================================= */

:root {
    /* =====================================================
       COLORES PRINCIPALES
    ===================================================== */

    --color-principal: #FBF6EE;
    --color-secundario: #4E2E17;
    /* =====================================================
       FONDOS
    ===================================================== */

    --color-fondo: #FBF6EE;
    --color-fondo-claro: #FFFDF9;
    --color-fondo-crema: #F5EBDD;
    --color-fondo-dorado: #EFE0C5;
    /* =====================================================
       CAFÉ / MARCA
    ===================================================== */

    --color-pan: #7A4A2B;
    --color-pan-oscuro: #4E2E17;
    --color-pan-claro: #A96F45;
    /* =====================================================
       DORADOS
    ===================================================== */

    --color-dorado: #C9992E;
    --color-dorado-claro: #E8C77A;
    --color-dorado-palido: #F3E3BD;
    /* =====================================================
       TEXTO
    ===================================================== */

    --color-texto: #3A2A1D;
    --color-texto-suave: #6B5643;
    --color-texto-claro: #8A7663;
    /* =====================================================
       FEEDBACK
    ===================================================== */

    --color-exito: #4F7A3D;
    --color-exito-fondo: #E7F0DE;
    --color-error: #A63A2C;
    --color-error-fondo: #F6E3DF;
    /* =====================================================
       BORDES
    ===================================================== */

    --color-borde: #E3D5BF;
    --color-borde-suave: rgba(122, 74, 43, 0.10);
    /* =====================================================
       SOMBRAS
    ===================================================== */

    --sombra-suave: 0 6px 20px rgba(74, 44, 29, 0.08);
    --sombra-media: 0 12px 35px rgba(74, 44, 29, 0.13);
    --sombra-fuerte: 0 20px 55px rgba(74, 44, 29, 0.18);
    /* =====================================================
       TIPOGRAFÍAS
    ===================================================== */

    --fuente-titulos: "Playfair Display", Georgia, serif;
    --fuente-texto: "Poppins", system-ui, sans-serif;
    /* =====================================================
       RADIOS
    ===================================================== */

    --radio-pequeno: 10px;
    --radio-borde: 14px;
    --radio-grande: 22px;
    /* =====================================================
       TRANSICIONES
    ===================================================== */

    --transicion: 0.25s ease;
    --transicion-suave: 0.4s cubic-bezier(.22, 1, .36, 1);
    /* =====================================================
       ESTRUCTURA
    ===================================================== */

    --color-header: #4E2E17;
    --color-footer: #4E2E17;
    --color-body: #FBF6EE;
    /* =====================================================
       CARDS
    ===================================================== */

    --color-card: #F3E9D8;
    --color-card-hover: #EDE0CD;
    /* =====================================================
       TEXTO SOBRE CAFÉ
    ===================================================== */

    --color-texto-claro: #FFFDF9;
}


/* =========================================================
   BASE
========================================================= */

body {
    font-family: var(--fuente-texto);
    color: var(--color-texto);
    line-height: 1.6;
    background: linear-gradient( rgba(255, 253, 249, 0.90), rgba(255, 253, 249, 0.90) ), url("/images/fondo.jpg");
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    background-attachment: fixed;
    min-height: 100vh;
}


/* =========================================================
   TIPOGRAFÍA
========================================================= */

h1,
h2,
h3,
h4,
h5,
h6,
.marca__nombre {
    font-family: var(--fuente-titulos);
    color: var(--color-pan-oscuro);
    line-height: 1.2;
}

p {
    margin-top: 0;
}

.seccion__titulo {
    position: relative;
    margin: 0 0 2.5rem;
    text-align: center;
    font-size: clamp(1.8rem, 4vw, 2.5rem);
    letter-spacing: -0.02em;
}

    .seccion__titulo::after {
        content: "";
        display: block;
        width: 55px;
        height: 3px;
        margin: 0.9rem auto 0;
        border-radius: 999px;
        background: linear-gradient( 90deg, var(--color-dorado-claro), var(--color-dorado), var(--color-dorado-claro) );
    }


/* =========================================================
   CONTENEDOR
========================================================= */

.contenedor {
    width: min(1180px, calc(100% - 3rem));
    margin: 0 auto;
}


/* =========================================================
   SECCIONES
========================================================= */

.seccion {
    position: relative;
    padding: 5rem 0;
}

    .seccion::before {
        content: "";
        position: absolute;
        top: 0;
        left: 50%;
        width: 85%;
        height: 1px;
        transform: translateX(-50%);
        background: linear-gradient( 90deg, transparent, var(--color-dorado-claro), transparent );
        opacity: 0.8;
    }


/* =========================================================
   HEADER
========================================================= */

.encabezado {
    position: sticky;
    top: 0;
    z-index: 50;
    background: var(--color-header);
    color: var(--color-texto-claro);
    border-bottom: none;
    box-shadow: 0 4px 20px rgba(74, 44, 29, 0.12);
}

.encabezado__interior {
    min-height: 78px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 2rem;
    padding: 0 1.5rem;
}

.encabezado__navegacion {
    display: flex;
    align-items: center;
    gap: 1.8rem;
}


/* =========================================================
   MARCA
========================================================= */

.marca__nombre {
    color: #FFFDF9;
}


/* =========================================================
   NAVEGACIÓN
========================================================= */

.nav-principal {
    display: flex;
    align-items: center;
    gap: 1.35rem;
}

    .nav-principal a {
        position: relative;
        padding: 0.45rem 0.15rem;
        color: rgba(255, 253, 249, 0.82);
        font-size: 0.92rem;
        font-weight: 500;
        transition: color var(--transicion), transform var(--transicion);
    }

        .nav-principal a::after {
            content: "";
            position: absolute;
            left: 0;
            right: 0;
            bottom: 0;
            height: 2px;
            border-radius: 999px;
            background: var(--color-dorado);
            transform: scaleX(0);
            transform-origin: center;
            transition: transform var(--transicion-suave);
        }

        .nav-principal a:hover {
            color: #FFFDF9;
            transform: translateY(-1px);
        }

            .nav-principal a:hover::after,
            .nav-principal a.nav-activo::after {
                transform: scaleX(1);
            }

        .nav-principal a.nav-activo {
            color: #FFFDF9;
            font-weight: 600;
        }


/* =========================================================
   HEBRA DECORATIVA
========================================================= */

.hebra {
    height: 3px;
    background: linear-gradient( 90deg, var(--color-dorado-palido), var(--color-dorado), var(--color-dorado-claro), var(--color-dorado), var(--color-dorado-palido) );
}


/* =========================================================
   CARRITO
========================================================= */

.carrito-boton {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    flex: 0 0 42px;
    width: 42px;
    min-width: 42px;
    height: 42px;
    aspect-ratio: 1 / 1;
    border-radius: 50%;
    color: #FFFDF9;
    background: rgba(255, 255, 255, 0.10);
    transition: background var(--transicion), transform var(--transicion), box-shadow var(--transicion);
}

    .carrito-boton:hover {
        background: rgba(255, 255, 255, 0.18);
        transform: translateY(-2px);
        box-shadow: var(--sombra-suave);
    }

.carrito-boton__contador {
    position: absolute;
    top: -3px;
    right: -3px;
    min-width: 19px;
    height: 19px;
    padding: 0 5px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 999px;
    background: var(--color-dorado);
    color: #fff;
    font-size: 0.68rem;
    font-weight: 700;
    box-shadow: 0 3px 8px rgba(201, 153, 46, 0.35);
}


/* =========================================================
   BOTONES
========================================================= */

.boton {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    min-height: 44px;
    padding: 0.7rem 1.35rem;
    border: 1px solid transparent;
    border-radius: var(--radio-borde);
    font-size: 0.92rem;
    font-weight: 600;
    transition: transform var(--transicion), box-shadow var(--transicion), background var(--transicion), border-color var(--transicion);
}

    .boton:hover {
        transform: translateY(-2px);
    }

    .boton:active {
        transform: translateY(0);
    }


/* =========================================================
   BOTÓN PRIMARIO
========================================================= */

.boton--primario {
    color: #fff;
    background: linear-gradient( 135deg, var(--color-pan), var(--color-pan-oscuro) );
    box-shadow: 0 6px 16px rgba(78, 46, 23, 0.20);
}

    .boton--primario:hover {
        box-shadow: 0 10px 24px rgba(78, 46, 23, 0.28);
    }


/* =========================================================
   BOTÓN LÍNEA
========================================================= */

.boton--linea {
    color: var(--color-texto-suave);
    background: rgba(255, 255, 255, 0.60);
    border-color: var(--color-borde);
}

    .boton--linea:hover {
        color: var(--color-pan);
        border-color: var(--color-dorado);
        background: rgba(255, 255, 255, 0.90);
    }


/* =========================================================
   BOTÓN PELIGRO
========================================================= */

.boton--peligro {
    color: #fff;
    background: linear-gradient( 135deg, #B84A3B, var(--color-error) );
    box-shadow: 0 6px 15px rgba(166, 58, 44, 0.18);
}


/* =========================================================
   HERO
========================================================= */

.hero {
    position: relative;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    min-height: 560px;
    padding: 4rem 1.5rem;
    overflow: hidden;
    background: linear-gradient( to bottom, #F3E9D8 0%, #F5EBDD 72%, var(--color-body) 100% );
}

    /* =========================================================
   DECORACIÓN SUPERIOR
========================================================= */

    .hero::before {
        content: "";
        position: absolute;
        width: 420px;
        height: 420px;
        top: -180px;
        left: -120px;
        border-radius: 50%;
        background: radial-gradient( circle, rgba(216, 181, 137, 0.42), transparent 70% );
        filter: blur(15px);
        z-index: 0;
    }


    /* =========================================================
   DECORACIÓN INFERIOR
========================================================= */

    .hero::after {
        content: "";
        position: absolute;
        width: 500px;
        height: 500px;
        right: -180px;
        bottom: -250px;
        border-radius: 50%;
        background: radial-gradient( circle, rgba(201, 153, 46, 0.18), transparent 70% );
        filter: blur(25px);
        z-index: 0;
    }


.hero__interior {
    position: relative;
    z-index: 2;
    width: 100%;
    text-align: center;
}


.hero__texto {
    max-width: 720px;
    margin: 0 auto;
}

/* =========================================================
   LOGO HERO
========================================================= */

.hero__logo {
    position: relative;
    z-index: 3;
    margin: 0 auto 2rem;
    animation: aparecer-logo 1s cubic-bezier(.22, 1, .36, 1) both;
}

.logo-chaves {
    width: 500px;
    max-width: 75vw;
    height: auto;
    object-fit: contain;
    filter: drop-shadow( 0 15px 22px rgba(74, 44, 29, 0.13) );
    transition: transform 0.6s cubic-bezier(.22, 1, .36, 1);
}

.hero:hover .logo-chaves {
    transform: scale(1.025) translateY(-3px);
}


/* =========================================================
   HERO TEXTO
========================================================= */

.marca__eyebrow {
    display: inline-flex;
    align-items: center;
    gap: 0.7rem;
    margin-bottom: 1rem;
    color: var(--color-dorado);
    font-size: 1rem;
    font-weight: 1000;
    letter-spacing: 0.14em;
}

.marca__eyebrow {
    font-family: 'Dancing Script', cursive;
    font-size: 2rem;
    font-weight: 1000;
}


.marca__eyebrow::before,
.marca__eyebrow::after {
    content: "";
    width: 28px;
    height: 1px;
    background: var(--color-dorado-claro);
}

.hero__titulo {
    margin: 0 0 1.2rem;
    color: var(--color-pan-oscuro);
    font-size: clamp(2.3rem, 5vw, 4.3rem);
    line-height: 1.08;
    letter-spacing: -0.025em;
    animation: aparecer-texto 0.8s 0.15s both;
}

    .hero__titulo em {
        font-style: normal;
    }

.hero__descripcion {
    max-width: 590px;
    margin: 0 auto;
    color: var(--color-texto-suave);
    font-size: 1.05rem;
    line-height: 1.8;
    animation: aparecer-texto 0.8s 0.3s both;
}


/* =========================================================
   PUBLICACIONES
========================================================= */

.posts-feed {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 2.5rem;
    margin-top: 2rem;
}


/* =========================================================
   POST CARD
========================================================= */

.post-card {
    position: relative;
    width: min(100%, 700px);
    overflow: hidden;
    display: grid;
    grid-template-columns: 3fr 2fr;
    background: #FFFDF9;
    border: 1px solid rgba(227, 213, 191, 0.75);
    border-radius: var(--radio-grande);
    box-shadow: var(--sombra-suave);
    transform: translateY(25px);
    opacity: 0;
    transition: transform 0.55s cubic-bezier(.22, 1, .36, 1), opacity 0.55s ease, box-shadow 0.35s ease, border-color 0.35s ease;
}

    .post-card.in-view {
        opacity: 1;
        transform: translateY(0);
    }

    .post-card:hover {
        transform: translateY(-7px);
        border-color: rgba(201, 153, 46, 0.40);
        box-shadow: var(--sombra-media);
    }


    /* =========================================================
   BRILLO SUPERIOR
========================================================= */

    .post-card::before {
        content: "";
        position: absolute;
        top: 0;
        left: 0;
        right: 0;
        height: 3px;
        background: linear-gradient( 90deg, transparent, var(--color-dorado), transparent );
        opacity: 0;
        transition: opacity var(--transicion);
        z-index: 2;
    }

    .post-card:hover::before {
        opacity: 1;
    }


/* =========================================================
   IMAGEN POST
========================================================= */

.post-img {
    display: block;
    width: 100%;
    height: 100%;
    min-height: 360px;
    object-fit: cover;
    transition: transform 0.7s cubic-bezier(.22, 1, .36, 1), filter 0.4s ease;
}

.post-card:hover .post-img {
    transform: scale(1.035);
    filter: saturate(1.05);
}


/* =========================================================
   CONTENIDO POST
========================================================= */

.post-content {
    display: flex;
    flex-direction: column;
    justify-content: center;
    padding: 2rem 1.7rem;
    background: linear-gradient( 180deg, rgba(255, 255, 255, 0.96), rgba(255, 251, 245, 0.98) );
}

    .post-content h3 {
        margin: 0 0 0.8rem;
        color: var(--color-pan-oscuro);
        font-size: 1.4rem;
        line-height: 1.3;
    }

    .post-content p {
        margin: 0;
        color: var(--color-texto-suave);
        font-size: 0.95rem;
        line-height: 1.7;
    }


/* =========================================================
   SIN PUBLICACIONES
========================================================= */

.seccion__vacio {
    position: relative;
    max-width: 650px;
    margin: 2rem auto 0;
    padding: 3rem 2rem;
    text-align: center;
    color: var(--color-texto-suave);
    background: rgba(255, 255, 255, 0.75);
    border: 1px solid var(--color-borde);
    border-radius: var(--radio-grande);
    box-shadow: var(--sombra-suave);
    backdrop-filter: blur(8px);
}


/* =========================================================
   MENSAJES
========================================================= */

.mensaje {
    padding: 0.9rem 1.2rem;
    margin-bottom: 1.5rem;
    border-radius: var(--radio-borde);
    font-weight: 500;
    box-shadow: var(--sombra-suave);
}

.mensaje--exito {
    color: var(--color-exito);
    background: var(--color-exito-fondo);
}

.mensaje--error {
    color: var(--color-error);
    background: var(--color-error-fondo);
}


/* =========================================================
   ESTADOS
========================================================= */

.estado {
    display: inline-flex;
    align-items: center;
    padding: 0.25rem 0.7rem;
    border-radius: 999px;
    font-size: 0.78rem;
    font-weight: 600;
}

.estado--activo {
    color: var(--color-exito);
    background: var(--color-exito-fondo);
}

.estado--inactivo {
    color: var(--color-texto-suave);
    background: var(--color-fondo-crema);
}


/* =========================================================
   SWITCH
========================================================= */

.switch-estado {
    position: relative;
    width: 40px;
    height: 22px;
    padding: 0;
    border: none;
    border-radius: 999px;
    background: var(--color-borde);
    transition: background var(--transicion);
}

    .switch-estado span {
        position: absolute;
        top: 2px;
        left: 2px;
        width: 18px;
        height: 18px;
        border-radius: 50%;
        background: #fff;
        box-shadow: 0 2px 5px rgba(0, 0, 0, 0.12);
        transition: transform var(--transicion);
    }

    .switch-estado.activo {
        background: var(--color-exito);
    }

        .switch-estado.activo span {
            transform: translateX(18px);
        }


/* =========================================================
   FOOTER
========================================================= */

.pie {
    position: relative;
    margin-top: 5rem;
    overflow: hidden;
    background: var(--color-footer);
}

    .pie::before {
        content: "";
        position: absolute;
        top: -45px;
        left: 0;
        width: 100%;
        height: 45px;
        background: linear-gradient( to bottom, transparent, rgba(78, 46, 23, 0.08) );
        pointer-events: none;
    }

.hebra--pie {
    position: relative;
    margin-bottom: 0;
}

.pie__interior {
    position: relative;
    z-index: 1;
    padding: 3rem 1.5rem 4rem;
    text-align: center;
}

.marca__nombre--pie {
    color: #FFFDF9;
    font-size: 1.5rem;
}

.pie__texto {
    margin-top: 0.6rem;
    color: rgba(255, 253, 249, 0.72);
    font-size: 0.9rem;
}


/* =========================================================
   REDES FLOTANTES
========================================================= */

.redes-flotantes {
    position: fixed;
    right: 1.4rem;
    bottom: 1.4rem;
    display: flex;
    flex-direction: column;
    gap: 0.7rem;
    z-index: 40;
}

.red-social {
    width: 46px;
    height: 46px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    color: #fff;
    box-shadow: var(--sombra-media);
    transition: transform var(--transicion-suave), box-shadow var(--transicion);
}

    .red-social:hover {
        transform: translateY(-4px) scale(1.05);
        box-shadow: var(--sombra-fuerte);
    }

    .red-social.instagram {
        background: linear-gradient( 135deg, #833AB4, #C13584, #E1306C, #F77737 );
    }

    .red-social.whatsapp {
        background: #25D366;
    }

    .red-social.facebook {
        background: #1877F2;
    }

    .red-social.tiktok {
        background: #111;
    }
/* ==========================================================
   FORMULARIO
========================================================== */

.detalle-producto__formulario {
    width: 100%;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: .8rem;
    margin-top: 3.5rem;
}


/* ==========================================================
   CANTIDAD
========================================================== */

.selector-cantidad--grande {
    width: 150px;
    height: 50px;
    display: flex;
    align-items: center;
    background: var(--color-fondo-claro);
    border: 1px solid rgba(78, 46, 23, .18);
    border-radius: .7rem;
    overflow: hidden;
}


.selector-cantidad__boton {
    width: 50px;
    height: 50px;
    flex: 0 0 50px;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0;
    border: 0;
    background: var(--color-fondo-crema);
    color: var(--color-pan-oscuro);
    font-size: 1.3rem;
    font-weight: 700;
    cursor: pointer;
    transition: background .2s ease, color .2s ease;
}


    .selector-cantidad__boton:hover {
        background: var(--color-pan);
        color: var(--color-texto-claro);
    }


.selector-cantidad__input {
    width: 50px;
    height: 50px;
    flex: 1;
    padding: 0;
    border: 0;
    outline: none;
    background: transparent;
    color: var(--color-texto);
    text-align: center;
    font-size: 1rem;
    font-weight: 700;
    appearance: textfield;
}


/* ==========================================================
   BOTÓN AGREGAR
========================================================== */

.detalle-producto__formulario .boton-agregar {
    width: 100%;
    max-width: 380px;
    min-height: 52px;
    border-radius: .7rem;
    font-size: 1rem;
    font-weight: 700;
}

/* =========================================================
   MODAL
========================================================= */

.modal-confirmacion {
    display: none;
    position: fixed;
    inset: 0;
    align-items: center;
    justify-content: center;
    padding: 1rem;
    background: rgba(58, 42, 29, 0.48);
    backdrop-filter: blur(5px);
    z-index: 100;
}

    .modal-confirmacion.activo {
        display: flex;
        animation: aparecer-modal 0.25s ease both;
    }

.modal-confirmacion__contenido {
    width: min(400px, 100%);
    padding: 2rem;
    background: rgba(255, 255, 255, 0.97);
    border: 1px solid var(--color-borde);
    border-radius: var(--radio-grande);
    box-shadow: var(--sombra-fuerte);
    animation: subir-modal 0.3s cubic-bezier(.22, 1, .36, 1) both;
}

.modal-confirmacion__acciones {
    display: flex;
    justify-content: flex-end;
    gap: 0.75rem;
    margin-top: 1.5rem;
}


/* =========================================================
   MENÚ HAMBURGUESA
========================================================= */

.menu-hamburguesa {
    display: none;
    width: 42px;
    height: 42px;
    padding: 0;
    border: none;
    background: transparent;
    color: #FFFDF9;
    font-size: 1.65rem;
    cursor: pointer;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

    .menu-hamburguesa:hover {
        color: var(--color-dorado);
    }

    .menu-hamburguesa:active {
        transform: scale(0.95);
    }

    .menu-hamburguesa i {
        line-height: 1;
    }

/* =========================================================
   BOTÓN CERRAR SESIÓN
========================================================= */

.salir-edicion {
    margin: 0;
}

.boton-salir {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 40px;
    padding: 0.55rem 0.9rem;
    border: 1px solid rgba(255, 253, 249, 0.22);
    border-radius: 0.65rem;
    background: rgba(255, 253, 249, 0.08);
    color: rgba(255, 253, 249, 0.88);
    font: inherit;
    font-size: 0.88rem;
    font-weight: 500;
    cursor: pointer;
    transition: background var(--transicion), border-color var(--transicion), color var(--transicion), transform var(--transicion);
}

    .boton-salir:hover {
        background: rgba(255, 253, 249, 0.16);
        border-color: rgba(232, 199, 122, 0.55);
        color: #FFFDF9;
        transform: translateY(-1px);
    }

    .boton-salir:active {
        transform: translateY(0);
    }

.nav-principal a,
.nav-principal .boton-salir {
    display: flex;
    align-items: center;
    gap: 0.45rem;
}

.nav-principal i {
    font-size: 0.95rem;
    line-height: 1;
    flex-shrink: 0;
}


/* =========================================================
   MENÚ MÓVIL
========================================================= */

@media (max-width: 900px) {

    .encabezado__interior {
        position: relative;
    }

    .menu-hamburguesa {
        display: flex;
    }

    .encabezado__navegacion {
        display: flex;
        align-items: center;
    }

    .nav-principal {
        position: fixed;
        top: 74px;
        left: 1rem;
        right: 1rem;
        width: auto;
        max-width: none;
        z-index: 1000;
        display: none;
        flex-direction: column;
        padding: 0.7rem;
        background: #4E2E17;
        border: 1px solid rgba(255, 253, 249, 0.15);
        border-radius: 1rem;
        box-shadow: 0 12px 30px rgba(0, 0, 0, 0.20);
    }

        .nav-principal.menu-abierto {
            display: flex;
            animation: menu-aparecer 0.25s ease both;
        }

        .nav-principal a,
        .nav-principal .boton-salir {
            width: 100%;
            box-sizing: border-box;
            padding: 0.75rem 0.9rem;
            color: rgba(255, 253, 249, 0.88);
            text-align: left;
            border-radius: 0.65rem;
        }

            .nav-principal a::after {
                display: none;
            }

            .nav-principal a:hover,
            .nav-principal .boton-salir:hover {
                background: rgba(255, 253, 249, 0.08);
                color: #FFFDF9;
                transform: none;
            }

        .nav-principal .nav-activo {
            background: rgba(255, 253, 249, 0.10);
            color: #FFFDF9;
        }

    .salir-edicion {
        width: 100%;
    }

    .boton-salir {
        background: transparent;
        border: none;
        font: inherit;
        cursor: pointer;
    }
}


/* =========================================================
   RESPONSIVE — TABLET
========================================================= */

@media (max-width: 860px) {

    .encabezado__interior {
        min-height: 70px;
    }

    .encabezado__marca {
        margin-right: auto;
    }

    .hero {
        min-height: 500px;
    }

    .logo-chaves {
        width: 440px;
        max-width: 82vw;
    }
}


/* =========================================================
   RESPONSIVE — MÓVIL
========================================================= */

@media (max-width: 600px) {

    body {
        background-attachment: scroll;
    }


    /* =====================================================
       CONTENEDOR
    ===================================================== */

    .contenedor {
        width: min(100% - 2rem, 1180px);
    }


    /* =====================================================
       HEADER
    ===================================================== */

    .encabezado__interior {
        min-height: 68px;
        padding: 0.7rem 1rem;
    }

    .encabezado__navegacion {
        gap: 0.7rem;
    }

    .marca__nombre {
        font-size: 1.35rem;
    }

    .menu-hamburguesa {
        width: 40px;
        height: 40px;
        font-size: 1.55rem;
    }

    .nav-principal {
        top: 70px;
        left: 0.75rem;
        right: 0.75rem;
    }


    /* =====================================================
       HERO
    ===================================================== */

    .hero {
        min-height: 430px;
    }

    .hero__logo {
        margin-bottom: 1.5rem;
    }

    .logo-chaves {
        width: 340px;
        max-width: 88vw;
    }

    .hero__texto {
        max-width: 94%;
    }

    .hero__titulo {
        font-size: clamp(2rem, 9vw, 2.8rem);
    }

    .hero__descripcion {
        font-size: 0.94rem;
    }

    .marca__eyebrow {
        font-size: 0.72rem;
    }

        .marca__eyebrow::before,
        .marca__eyebrow::after {
            width: 18px;
        }


    /* =====================================================
       SECCIONES
    ===================================================== */

    .seccion {
        padding: 3.5rem 0;
    }


    /* =====================================================
       PUBLICACIONES
    ===================================================== */

    .posts-feed {
        width: 100%;
        gap: 1.8rem;
        margin-top: 1.5rem;
    }

    .post-card {
        width: 100%;
        grid-template-columns: 1fr;
        /* Animación más suave en móvil */
        opacity: 0;
        transform: translateY(18px);
        transition: opacity 0.7s ease, transform 0.7s cubic-bezier(.22, 1, .36, 1), box-shadow 0.3s ease, border-color 0.3s ease;
    }

        .post-card.in-view {
            opacity: 1;
            transform: translateY(0);
        }

    .post-img {
        display: block;
        width: 100%;
        height: auto;
        min-height: 0;
        aspect-ratio: 3 / 4;
        object-fit: cover;
    }

    .post-content {
        padding: 1.5rem 1.5rem 1.8rem;
    }

        .post-content h3 {
            font-size: 1.3rem;
            margin-bottom: 0.7rem;
        }

        .post-content p {
            font-size: 0.94rem;
            line-height: 1.65;
        }

    /*
       Las imágenes originales son 3:4.
       Al ocupar el 100% del ancho mantienen
       su proporción sin dejar espacios laterales.
    */

    .post-img {
        display: block;
        width: 100%;
        height: auto;
        min-height: 0;
        aspect-ratio: 3 / 4;
        object-fit: cover;
    }

    .post-content {
        padding: 1.5rem 1.5rem 1.8rem;
    }

        .post-content h3 {
            font-size: 1.3rem;
            margin-bottom: 0.7rem;
        }

        .post-content p {
            font-size: 0.94rem;
            line-height: 1.65;
        }


    /* =====================================================
       REDES
    ===================================================== */

    .redes-flotantes {
        right: 1rem;
        bottom: 1rem;
    }

    .red-social {
        width: 42px;
        height: 42px;
    }


    /* =====================================================
       MODAL
    ===================================================== */

    .modal-confirmacion__acciones {
        flex-direction: column-reverse;
    }

        .modal-confirmacion__acciones .boton {
            width: 100%;
        }
}


/* =========================================================
   RESPONSIVE — MÓVIL PEQUEÑO
========================================================= */

@media (max-width: 400px) {

    .hero {
        min-height: 390px;
    }

    .logo-chaves {
        width: 290px;
    }

    .hero__titulo {
        font-size: 1.85rem;
    }

    .hero__descripcion {
        font-size: 0.9rem;
    }

    .post-content {
        padding-left: 1.2rem;
        padding-right: 1.2rem;
    }
}


/* =========================================================
   ACCESIBILIDAD
========================================================= */

@media (prefers-reduced-motion: reduce) {

    html {
        scroll-behavior: auto;
    }

    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
}


/* =========================================================
   ANIMACIONES
========================================================= */

@keyframes aparecer-logo {

    from {
        opacity: 0;
        transform: translateY(-18px) scale(0.96);
    }

    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}


@keyframes aparecer-texto {

    from {
        opacity: 0;
        transform: translateY(18px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}


@keyframes aparecer-modal {

    from {
        opacity: 0;
    }

    to {
        opacity: 1;
    }
}


@keyframes subir-modal {

    from {
        opacity: 0;
        transform: translateY(20px) scale(0.97);
    }

    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}


@keyframes menu-aparecer {

    from {
        opacity: 0;
        transform: translateY(-8px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* ==========================================================
   ESTRUCTURA GENERAL — FOOTER AL FINAL
========================================================== */

html,
body {
    min-height: 100%;
}

body {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

main {
    flex: 1;
}
