/**
 * Blessed7
 * Archivo: assets/css/novedades.css
 *
 * Diseño exclusivo de la sección Novedades.
 * Complementa catalogo.css sin modificar las tarjetas del catálogo general.
 */

.pagina-novedades {
    --novedades-tinta: #18131f;
    --novedades-morado: #7544d8;
    --novedades-morado-oscuro: #4f258f;
    --novedades-lila: #bfa5ff;
    --novedades-rosa: #ff8fca;
    --novedades-fondo: #faf8ff;
    --novedades-borde: #e8e0f2;
    background: var(--novedades-fondo);
    color: var(--novedades-tinta);
}

.pagina-novedades .contenedor {
    width: min(1180px, calc(100% - 40px));
    margin-inline: auto;
}

/* ==========================================================================
   Portada
   ========================================================================== */

.novedades-portada {
    position: relative;
    isolation: isolate;
    overflow: hidden;
    padding: 34px 0 94px;
    color: #21172d;
    background:
        radial-gradient(
            circle at 74% 24%,
            rgba(189, 153, 255, 0.42),
            transparent 30%
        ),
        radial-gradient(
            circle at 92% 85%,
            rgba(255, 151, 205, 0.3),
            transparent 28%
        ),
        linear-gradient(135deg, #fff 0%, #f5efff 54%, #fff5fa 100%);
}

.novedades-portada::before {
    position: absolute;
    z-index: -1;
    top: 72px;
    left: 48%;
    width: 1px;
    height: 290px;
    background: linear-gradient(
        to bottom,
        transparent,
        rgba(99, 57, 153, 0.18),
        transparent
    );
    content: "";
    transform: rotate(16deg);
}

.novedades-portada__decoracion {
    position: absolute;
    z-index: -1;
    border: 1px solid rgba(105, 60, 162, 0.14);
    border-radius: 50%;
    pointer-events: none;
}

.novedades-portada__decoracion--uno {
    top: -220px;
    right: -95px;
    width: 520px;
    height: 520px;
}

.novedades-portada__decoracion--dos {
    right: 23%;
    bottom: -175px;
    width: 310px;
    height: 310px;
}

.novedades-portada__interior {
    position: relative;
    z-index: 1;
}

.novedades-migas {
    margin-bottom: 54px;
    color: #71677e;
}

.novedades-migas a:hover {
    color: var(--novedades-morado);
}

.novedades-portada__rejilla {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(230px, 320px);
    align-items: center;
    gap: clamp(45px, 8vw, 110px);
}

.novedades-portada__contenido {
    max-width: 760px;
}

.novedades-portada__eyebrow,
.novedades-encabezado__eyebrow {
    margin: 0 0 13px;
    color: var(--novedades-morado);
    font-size: 0.76rem;
    font-weight: 900;
    letter-spacing: 0.2em;
    text-transform: uppercase;
}

.novedades-portada h1 {
    max-width: 760px;
    margin: 0;
    color: var(--novedades-tinta);
    font-size: clamp(2.7rem, 6.5vw, 5.8rem);
    font-weight: 900;
    letter-spacing: -0.07em;
    line-height: 0.88;
}

.novedades-portada h1 span {
    display: block;
    color: transparent;
    background: linear-gradient(
        100deg,
        var(--novedades-morado-oscuro),
        #9463ee 52%,
        #d0589c
    );
    background-clip: text;
    -webkit-background-clip: text;
}

.novedades-portada__descripcion {
    max-width: 610px;
    margin: 25px 0 0;
    color: #665c70;
    font-size: clamp(0.98rem, 1.5vw, 1.1rem);
    line-height: 1.75;
}

.novedades-portada__boton {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 13px;
    min-height: 52px;
    margin-top: 30px;
    padding: 0 22px;
    border-radius: 999px;
    background: var(--novedades-tinta);
    color: #fff;
    font-size: 0.86rem;
    font-weight: 800;
    text-decoration: none;
    box-shadow: 0 14px 32px rgba(33, 19, 47, 0.18);
    transition:
        transform 180ms ease,
        background-color 180ms ease,
        box-shadow 180ms ease;
}

.novedades-portada__boton span {
    font-size: 1.05rem;
    transition: transform 180ms ease;
}

.novedades-portada__boton:hover {
    background: var(--novedades-morado-oscuro);
    box-shadow: 0 17px 37px rgba(79, 37, 143, 0.25);
    transform: translateY(-2px);
}

.novedades-portada__boton:hover span {
    transform: translateY(3px);
}

.novedades-portada__resumen {
    position: relative;
    display: flex;
    min-height: 270px;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 36px 26px;
    overflow: hidden;
    border: 1px solid rgba(104, 58, 161, 0.17);
    border-radius: 36px 12px 36px 12px;
    background: rgba(255, 255, 255, 0.72);
    text-align: center;
    box-shadow: 0 28px 65px rgba(72, 41, 105, 0.13);
    backdrop-filter: blur(15px);
}

.novedades-portada__resumen::after {
    position: absolute;
    right: -46px;
    bottom: -62px;
    width: 150px;
    height: 150px;
    border-radius: 50%;
    background: rgba(191, 165, 255, 0.24);
    content: "";
}

.novedades-portada__destello {
    position: absolute;
    top: 22px;
    right: 25px;
    color: var(--novedades-morado);
    font-size: 1.45rem;
}

.novedades-portada__resumen strong,
.novedades-portada__resumen span,
.novedades-portada__resumen small {
    display: block;
    position: relative;
    z-index: 1;
}

.novedades-portada__resumen strong {
    color: var(--novedades-morado-oscuro);
    font-size: clamp(4rem, 8vw, 6rem);
    font-weight: 900;
    letter-spacing: -0.08em;
    line-height: 0.88;
}

.novedades-portada__resumen > span:not(.novedades-portada__destello) {
    max-width: 170px;
    margin-top: 13px;
    color: #30263b;
    font-size: 0.92rem;
    font-weight: 800;
    line-height: 1.35;
}

.novedades-portada__resumen small {
    margin-top: 10px;
    color: #776d80;
    font-size: 0.72rem;
}

/* ==========================================================================
   Encabezado y controles
   ========================================================================== */

.novedades-seccion {
    padding: 0 0 90px;
}

.novedades-encabezado {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(260px, 430px);
    align-items: end;
    gap: 50px;
    padding: 61px 0 27px;
}

.novedades-encabezado h2 {
    margin: 0;
    color: var(--novedades-tinta);
    font-size: clamp(2rem, 4vw, 3.4rem);
    font-weight: 900;
    letter-spacing: -0.055em;
    line-height: 1;
}

.novedades-encabezado > p {
    margin: 0;
    color: #706778;
    font-size: 0.94rem;
    line-height: 1.7;
}

.novedades-controles {
    display: grid;
    grid-template-columns: minmax(240px, 1fr) minmax(180px, 0.42fr) auto;
    align-items: end;
    gap: 14px;
    margin-bottom: 30px;
    padding: 18px;
    border: 1px solid var(--novedades-borde);
    border-radius: 20px;
    background: rgba(255, 255, 255, 0.92);
    box-shadow: 0 14px 40px rgba(55, 32, 80, 0.07);
}

.novedades-busqueda,
.novedades-control {
    min-width: 0;
}

.novedades-busqueda > label,
.novedades-control > label {
    display: block;
    margin: 0 0 8px;
    color: #6b6074;
    font-size: 0.7rem;
    font-weight: 900;
    letter-spacing: 0.07em;
    text-transform: uppercase;
}

.novedades-busqueda__campo {
    position: relative;
}

.novedades-busqueda__campo svg {
    position: absolute;
    top: 50%;
    left: 15px;
    color: #776b81;
    transform: translateY(-50%);
    pointer-events: none;
}

.novedades-busqueda input,
.novedades-control select {
    width: 100%;
    min-height: 50px;
    border: 1px solid #ded6e7;
    border-radius: 13px;
    outline: 0;
    background: #fbf9fd;
    color: #29212f;
    font: inherit;
    font-size: 0.88rem;
    transition:
        border-color 180ms ease,
        box-shadow 180ms ease,
        background-color 180ms ease;
}

.novedades-busqueda input {
    padding: 0 15px 0 45px;
}

.novedades-control select {
    padding: 0 38px 0 14px;
    cursor: pointer;
}

.novedades-busqueda input:focus,
.novedades-control select:focus {
    border-color: #9d72dc;
    background: #fff;
    box-shadow: 0 0 0 4px rgba(117, 68, 216, 0.1);
}

.novedades-controles__boton {
    min-height: 50px;
    padding: 0 21px;
    border: 0;
    border-radius: 13px;
    background: linear-gradient(
        110deg,
        var(--novedades-morado-oscuro),
        var(--novedades-morado)
    );
    color: #fff;
    font: inherit;
    font-size: 0.82rem;
    font-weight: 800;
    cursor: pointer;
    box-shadow: 0 11px 24px rgba(79, 37, 143, 0.19);
    transition:
        transform 180ms ease,
        box-shadow 180ms ease;
}

.novedades-controles__boton:hover {
    box-shadow: 0 14px 29px rgba(79, 37, 143, 0.27);
    transform: translateY(-2px);
}

.novedades-resultados {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    margin: -8px 0 28px;
    padding: 13px 17px;
    border: 1px solid #e8e0ef;
    border-radius: 13px;
    background: #fff;
    color: #655b6e;
    font-size: 0.84rem;
}

.novedades-resultados p {
    margin: 0;
}

.novedades-resultados a {
    color: var(--novedades-morado-oscuro);
    font-weight: 800;
    text-decoration: none;
}

/* ==========================================================================
   Tarjetas y lanzamiento destacado
   ========================================================================== */

.novedades-grid {
    align-items: stretch;
}

.novedad-tarjeta {
    position: relative;
    overflow: hidden;
    border-color: #e8e0ed;
    background: #fff;
}

.novedad-tarjeta::before {
    position: absolute;
    z-index: 3;
    top: 0;
    left: 0;
    width: 100%;
    height: 3px;
    background: linear-gradient(
        90deg,
        var(--novedades-morado),
        var(--novedades-rosa)
    );
    content: "";
    opacity: 0;
    transition: opacity 180ms ease;
}

.novedad-tarjeta:hover::before {
    opacity: 1;
}

.novedad-tarjeta__imagen {
    background:
        radial-gradient(circle at 50% 42%, #fff 0%, #f4eff8 100%);
}

.novedad-tarjeta__imagen img {
    transition: transform 450ms cubic-bezier(0.2, 0.75, 0.25, 1);
}

.novedad-tarjeta:hover .novedad-tarjeta__imagen img {
    transform: scale(1.035);
}

.novedad-insignia {
    border: 1px solid rgba(255, 255, 255, 0.42);
    background: linear-gradient(115deg, #58279c, #9b54d4);
    box-shadow: 0 7px 18px rgba(63, 26, 102, 0.23);
}

.novedad-tarjeta__seleccion {
    position: absolute;
    right: 16px;
    bottom: 16px;
    left: 16px;
    z-index: 2;
    padding: 12px 15px;
    border: 1px solid rgba(255, 255, 255, 0.28);
    border-radius: 12px;
    background: rgba(25, 17, 32, 0.82);
    color: #fff;
    font-size: 0.72rem;
    font-weight: 900;
    letter-spacing: 0.09em;
    text-align: center;
    text-transform: uppercase;
    backdrop-filter: blur(10px);
}

.novedad-tarjeta .esta-disponible::before {
    background: #8051ce;
    box-shadow: 0 0 0 4px rgba(128, 81, 206, 0.12);
}

.novedad-tarjeta .producto-tarjeta__enlace {
    color: var(--novedades-morado-oscuro);
}

.novedad-tarjeta--principal {
    grid-column: span 2;
    display: grid;
    grid-template-columns: minmax(0, 1.12fr) minmax(260px, 0.88fr);
    min-height: 455px;
    border-radius: 27px;
    box-shadow: 0 24px 55px rgba(50, 28, 72, 0.11);
}

.novedad-tarjeta--principal .novedad-tarjeta__imagen {
    min-height: 100%;
    border-radius: 0;
}

.novedad-tarjeta--principal .novedad-tarjeta__imagen img {
    height: 100%;
    object-fit: cover;
}

.novedad-tarjeta--principal .producto-tarjeta__contenido {
    display: flex;
    min-width: 0;
    flex-direction: column;
    justify-content: center;
    padding: clamp(30px, 5vw, 56px);
}

.novedad-tarjeta--principal .producto-tarjeta__etiqueta {
    color: var(--novedades-morado);
}

.novedad-tarjeta--principal h2 {
    margin-top: 8px;
    font-size: clamp(1.65rem, 3vw, 2.65rem);
    letter-spacing: -0.045em;
    line-height: 1.04;
}

.novedad-tarjeta--principal .producto-tarjeta__descripcion {
    margin-top: 17px;
    font-size: 0.98rem;
    line-height: 1.7;
}

.novedad-tarjeta--principal .producto-tarjeta__pie {
    margin-top: auto;
    padding-top: 30px;
}

/* ==========================================================================
   Estado vacío y paginación
   ========================================================================== */

.novedades-estado {
    border-color: var(--novedades-borde);
    background:
        radial-gradient(
            circle at 50% 0%,
            rgba(191, 165, 255, 0.19),
            transparent 34%
        ),
        #fff;
}

.novedades-estado > span {
    color: var(--novedades-morado);
}

.novedades-estado a {
    background: var(--novedades-morado-oscuro);
}

.novedades-paginacion {
    margin-top: 46px;
}

.novedades-paginacion a:hover,
.novedades-paginacion .es-actual {
    border-color: var(--novedades-morado);
    background: var(--novedades-morado);
    color: #fff;
}

/* ==========================================================================
   Accesibilidad
   ========================================================================== */

.novedades-portada__boton:focus-visible,
.novedades-controles__boton:focus-visible,
.novedades-resultados a:focus-visible,
.novedad-tarjeta a:focus-visible,
.novedades-paginacion a:focus-visible {
    outline: 3px solid rgba(117, 68, 216, 0.42);
    outline-offset: 3px;
}

/* ==========================================================================
   Tableta
   ========================================================================== */

@media (max-width: 960px) {
    .novedades-portada {
        padding-bottom: 78px;
    }

    .novedades-portada__rejilla {
        grid-template-columns: minmax(0, 1fr) 235px;
        gap: 38px;
    }

    .novedades-portada__resumen {
        min-height: 235px;
    }

    .novedades-controles {
        grid-template-columns: minmax(230px, 1fr) minmax(170px, 0.55fr);
    }

    .novedades-controles__boton {
        grid-column: 1 / -1;
    }

    .novedad-tarjeta--principal {
        grid-template-columns: 1fr 1fr;
    }
}

/* ==========================================================================
   Móvil
   ========================================================================== */

@media (max-width: 720px) {
    .pagina-novedades .contenedor {
        width: min(100% - 28px, 1180px);
    }

    .novedades-portada {
        padding: 25px 0 62px;
    }

    .novedades-migas {
        margin-bottom: 36px;
    }

    .novedades-portada__rejilla {
        grid-template-columns: 1fr;
        gap: 36px;
    }

    .novedades-portada h1 {
        font-size: clamp(2.75rem, 15vw, 4.4rem);
    }

    .novedades-portada__descripcion {
        margin-top: 20px;
        line-height: 1.65;
    }

    .novedades-portada__boton {
        width: 100%;
        margin-top: 25px;
    }

    .novedades-portada__resumen {
        min-height: 185px;
        border-radius: 25px 9px 25px 9px;
    }

    .novedades-portada__resumen strong {
        font-size: 4.4rem;
    }

    .novedades-encabezado {
        grid-template-columns: 1fr;
        gap: 15px;
        padding: 45px 0 23px;
    }

    .novedades-controles {
        grid-template-columns: 1fr;
        gap: 16px;
        padding: 15px;
    }

    .novedades-controles__boton {
        grid-column: auto;
        width: 100%;
    }

    .novedades-resultados {
        align-items: flex-start;
        flex-direction: column;
        gap: 9px;
    }

    .novedad-tarjeta--principal {
        grid-column: auto;
        display: block;
        min-height: 0;
        border-radius: 20px;
    }

    .novedad-tarjeta--principal .novedad-tarjeta__imagen {
        min-height: 0;
    }

    .novedad-tarjeta--principal .novedad-tarjeta__imagen img {
        height: auto;
        object-fit: contain;
    }

    .novedad-tarjeta--principal .producto-tarjeta__contenido {
        display: block;
        padding: 22px;
    }

    .novedad-tarjeta--principal h2 {
        font-size: 1.45rem;
    }

    .novedad-tarjeta--principal .producto-tarjeta__descripcion {
        font-size: 0.9rem;
    }

    .novedad-tarjeta--principal .producto-tarjeta__pie {
        margin-top: 0;
        padding-top: 22px;
    }

    .novedades-paginacion {
        margin-top: 35px;
    }
}

@media (max-width: 430px) {
    .novedades-portada__eyebrow,
    .novedades-encabezado__eyebrow {
        letter-spacing: 0.15em;
    }

    .novedades-portada h1 {
        font-size: clamp(2.5rem, 14vw, 3.65rem);
    }

    .novedades-portada__resumen {
        padding-inline: 18px;
    }

    .novedad-tarjeta__seleccion {
        right: 11px;
        bottom: 11px;
        left: 11px;
        padding: 10px;
        font-size: 0.64rem;
    }
}

@media (prefers-reduced-motion: reduce) {
    .novedades-portada__boton,
    .novedades-portada__boton span,
    .novedades-controles__boton,
    .novedad-tarjeta::before,
    .novedad-tarjeta__imagen img {
        transition: none;
    }

    .novedades-portada__boton:hover,
    .novedades-controles__boton:hover,
    .novedad-tarjeta:hover .novedad-tarjeta__imagen img {
        transform: none;
    }
}