/* ==========================================================
 * CKS QUICK - FRONTEND
 *
 * Solo estilos propios del Quick.
 * El grid principal continúa utilizando el CSS del theme.
 * ========================================================== */


/* ==========================================================
 * ICONO INFORMACIÓN
 * ========================================================== */

.quick-info-trigger {
    position: absolute;
    top: 9px;
    right: 9px;
    z-index: 5;

    width: 30px;
    height: 30px;

    margin: 0;
    padding: 4px;

    border: 0;
    border-radius: 50%;

    background: rgba(0, 0, 0, .3);
    color: var(--white);

    cursor: pointer;

    display: flex;
    align-items: center;
    justify-content: center;

    box-sizing: border-box;

    appearance: none;
    -webkit-appearance: none;

    transition:
        background-color .18s ease,
        transform .18s ease;
}

.quick-info-trigger:hover,
.quick-info-trigger:focus-visible {
    background: rgba(0, 0, 0, .78);
    outline: none;
}

.quick-info-trigger svg {
    display: block;
    width: 100%;
    height: 100%;
    fill: var(--white);
}


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

.quick-info-modal {
    position: fixed;
    inset: 0;
    z-index: 999999;
    display: none;
    align-items: center;
    justify-content: center;
    padding: 20px;
    box-sizing: border-box;
}

.quick-info-modal.is-open {
    display: flex;
}

.quick-info-modal-backdrop {
    position: absolute;
    inset: 0;

    background: rgba(0, 0, 0, .62);
}

.quick-info-dialog {
    position: relative;
    z-index: 1;

    width: min(100%, 560px);

    /*height:
        min(720px,
            calc(100vh - 40px));*/

    max-height:
        calc(100vh - 40px);

    display: flex;
    flex-direction: column;

    overflow: hidden;

    box-sizing: border-box;

    padding: 24px;

    border-radius: 16px;

    background: var(--white);
    color: var(--black);

    box-shadow:
        0 20px 60px rgba(0, 0, 0, .28);
}


/* ==========================================================
 * CERRAR
 * ========================================================== */

.quick-info-close {
    position: absolute;
    top: 0;
    right: 0;

    width: 36px;
    height: 36px;

    padding: 0;

    border: 0;
    background: transparent;
    color: #000;

    cursor: pointer;

    font-size: 27px;
    line-height: 36px;
    text-align: center;

    display: flex;
    align-items: center;
    justify-content: center;
}

.quick-info-close svg {
    width: 100%;
    height: 100%;
}


/* ==========================================================
 * CABECERA
 * ========================================================== */

.quick-info-header {
    position: relative;

    width: 100%;
    box-sizing: border-box;

    padding-right: 42px;
}

.quick-info-heading {
    min-width: 0;
}

.quick-info-title-row {
    display: flex;
    align-items: center;
    justify-content: space-between;

    gap: 12px;
    min-width: 0;
}

.quick-info-title {
    flex: 1 1 auto;
    min-width: 0;

    margin: 0;
    padding: 0;

    font-size: 24px;
    line-height: 1.2;
    font-weight: 700;

    text-transform: capitalize;
    font-family: var(--font-outfit);
    letter-spacing: -.5px;
}

.quick-info-title .quick-verified svg {
    color: var(--black);
    fill: var(--black);
}



/* Unidad de negocio destacada en la card Quick */
.quick-business-unit {
    display: flex;
    justify-content: center;
    align-items: center;
    width: fit-content;
    height: 14px;
    border-radius: 20px;
    background: var(--white);
    color: var(--black);
    font-size: 10px;
    font-weight: 500;
    line-height: 1.2;
    margin: 0 auto 6px;
    padding: 0 6px;
}


/* ==========================================================
 * ENLACES DE CONTACTO
 * ========================================================== */

.quick-info-links {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    flex: 0 0 auto;
    gap: 7px;
}

.quick-info-link {
    display: inline-flex;
    align-items: center;
    justify-content: center;

    flex: 0 0 34px;

    width: 34px;
    height: 34px;
    padding: 7px;

    box-sizing: border-box;

    border: 0;
    border-radius: 50%;

    background: #f1f1f1;
    color: var(--black);

    text-decoration: none;

    cursor: pointer;

    transition:
        background-color .18s ease,
        color .18s ease,
        transform .18s ease;
}

.quick-info-link:hover,
.quick-info-link:focus-visible {
    background: #e5e5e5;
    color: var(--black);
    text-decoration: none;
    outline: none;
}

.quick-info-link:active {
    transform: scale(.94);
}

.quick-info-link svg {
    display: block;

    width: 100%;
    height: 100%;

    fill: currentColor;
}


/* ==========================================================
 * NACIONALIDAD
 * ========================================================== */

.quick-info-nationality {
    margin-bottom: 20px;
}


/* ==========================================================
 * FILAS
 * ========================================================== */

.quick-info-list {
    margin: 0;
    padding: 0;
}

.quick-info-row {
    margin: 0;

    padding: 13px 0;

    border-bottom:
        1px solid #ececec;
}

.quick-info-row:last-child {
    border-bottom: 0;
}


/* Etiqueta */

.quick-info-label {
    display: block;

    margin-bottom: 5px;

    font-size: 11px;
    line-height: 1.3;

    font-weight: 700;

    letter-spacing: .06em;

    text-transform: uppercase;

    color: #777;
}


/* Valor */

.quick-info-value {
    display: block;

    font-size: 16px;
    line-height: 1.45;

    font-weight: 500;
}


/* ==========================================================
 * PRECIOS QUICK — POPUP
 * ========================================================== */

/* Presenta los importes en una línea sin alterar las filas restantes. */
.quick-info-price-values {
    display: flex;
    align-items: baseline;
    flex-wrap: wrap;
    column-gap: 9px;
    row-gap: 3px;
}

.quick-info-price-primary {
    /* Hereda exactamente la tipografía del valor actual del popup. */
    display: inline-block;
}

.quick-info-price-secondary {
    display: inline-block;
    font-size: 13px;
    line-height: 1.35;
    font-weight: 500;
    color: #777;
}

.quick-info-price-primary--usd-only {
    /* USD ocupa el espacio principal con el diseño actual del valor. */
    color: inherit;
}


/* ==========================================================
 * SERVICIOS / CARACTERÍSTICAS
 * ========================================================== */

.quick-info-tags {
    display: flex;

    flex-wrap: wrap;

    gap: 7px;
}

.quick-info-tag {
    display: inline-flex;

    align-items: center;

    padding:
        6px 10px;

    border-radius: 999px;

    background: #f1f1f1;

    font-size: 13px;
    line-height: 1.2;
}


/* ==========================================================
 * SERVICIOS — NUBE CONTINUA EN TRES FILAS
 * ========================================================== */

.quick-info-services-shell {
    position: relative;
    display: flex;
    align-items: center;
    gap: 7px;
    width: fit-content;
    max-width: 100%;
    min-width: 0;
}

.quick-info-services-viewport {
    display: block;
    flex: 0 1 auto;
    min-width: 0;
    max-width: 100%;
    height: 100px;
    overflow-x: auto;
    overflow-y: hidden;
    scrollbar-width: none;
    -webkit-overflow-scrolling: touch;
    overscroll-behavior-x: contain;
    touch-action: pan-x;
}

.quick-info-services-viewport::-webkit-scrollbar {
    display: none;
}

.quick-info-services-track {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 7px;
    width: max-content;
    min-width: 0;
    height: 100px;
    box-sizing: border-box;
}

.quick-info-services-line {
    display: flex;
    flex: 0 0 auto;
    flex-flow: row nowrap;
    align-items: flex-start;
    gap: 7px;
    width: max-content;
    min-height: 28px;
}

.quick-info-services-line .quick-info-tag {
    flex: 0 0 auto;
    white-space: nowrap;
}

.quick-info-tag--trans-summary {
    background: #171f27;
    color: #fff;
}


.quick-info-services-controls {
    display: flex;
    flex: 0 0 auto;
    align-items: center;
    justify-content: center;
    gap: 4px;
}

.quick-info-services-controls[hidden] {
    display: none;
}

.quick-info-services-arrow {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 30px;
    height: 30px;
    margin: 0;
    padding: 5px;
    border: 0;
    border-radius: 50%;
    background: rgba(255, 255, 255, .96);
    color: #171f27;
    box-shadow: 0 1px 5px rgba(0, 0, 0, .18);
    cursor: pointer;
}

.quick-info-services-arrow[hidden],
.quick-info-services-arrow:disabled {
    display: none;
}

.quick-info-services-arrow svg {
    display: block;
    width: 100%;
    height: 100%;
    fill: none;
    stroke: currentColor;
    stroke-width: 2;
    stroke-linecap: round;
    stroke-linejoin: round;
}

.quick-info-services-arrow:focus-visible,
.quick-info-services-viewport:focus-visible {
    outline: 2px solid currentColor;
    outline-offset: 2px;
}


/* ==========================================================
 * CARACTERÍSTICAS — NUBE CONTINUA EN TRES FILAS
 * Mantiene la misma interacción y estética del riel de Servicios.
 * ========================================================== */

.quick-info-characteristics-shell {
    position: relative;
    display: flex;
    align-items: center;
    gap: 7px;
    width: fit-content;
    max-width: 100%;
    min-width: 0;
}

.quick-info-characteristics-viewport {
    display: block;
    flex: 0 1 auto;
    min-width: 0;
    max-width: 100%;
    height: 100px;
    overflow-x: auto;
    overflow-y: hidden;
    scrollbar-width: none;
    -webkit-overflow-scrolling: touch;
    overscroll-behavior-x: contain;
    touch-action: pan-x;
}

.quick-info-characteristics-viewport::-webkit-scrollbar {
    display: none;
}

.quick-info-characteristics-track {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 7px;
    width: max-content;
    min-width: 0;
    height: 100px;
    box-sizing: border-box;
}

.quick-info-characteristics-line {
    display: flex;
    flex: 0 0 auto;
    flex-flow: row nowrap;
    align-items: flex-start;
    gap: 7px;
    width: max-content;
    min-height: 28px;
}

.quick-info-characteristics-line .quick-info-tag {
    flex: 0 0 auto;
    white-space: nowrap;
}

.quick-info-characteristics-controls {
    display: flex;
    flex: 0 0 auto;
    align-items: center;
    justify-content: center;
    gap: 4px;
}

.quick-info-characteristics-controls[hidden] {
    display: none;
}

.quick-info-characteristics-arrow {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 30px;
    height: 30px;
    margin: 0;
    padding: 5px;
    border: 0;
    border-radius: 50%;
    background: rgba(255, 255, 255, .96);
    color: #171f27;
    box-shadow: 0 1px 5px rgba(0, 0, 0, .18);
    cursor: pointer;
}

.quick-info-characteristics-arrow[hidden],
.quick-info-characteristics-arrow:disabled {
    display: none;
}

.quick-info-characteristics-arrow svg {
    display: block;
    width: 100%;
    height: 100%;
    fill: none;
    stroke: currentColor;
    stroke-width: 2;
    stroke-linecap: round;
    stroke-linejoin: round;
}

.quick-info-characteristics-arrow:focus-visible,
.quick-info-characteristics-viewport:focus-visible {
    outline: 2px solid currentColor;
    outline-offset: 2px;
}


/* ==========================================================
 * BODY
 * ========================================================== */

body.cks-quick-modal-open {
    overflow: hidden;
}


/* ==========================================================
 * CATA - HUINCHA SUPERIOR DEL POPUP
 * ========================================================== */

.quick-info-content {
    position: relative;
}

.quick-info-cata {
    box-sizing: border-box;
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 14px 24px;
    background: var(--black);
    color: var(--white);
    margin: -24px -24px 12px;
}

.quick-info-cata-score {
    display: inline-flex;
    align-items: center;

    flex: 0 0 auto;
    font-size: 40px;
    font-weight: 800;
    line-height: 1;
    color: var(--malachite);
    letter-spacing: -.8px;
    font-family: var(--font-outfit);
}

.quick-info-cata-text {
    display: block;
    font-size: 14px;
    line-height: 16px;
    color: var(--white);
}

.quick-info-cata-detail {
    display: flex;
    flex-direction: column;
    flex: 1 1 auto;
    min-height: 0;
}

.quick-info-cata-detail[hidden] {
    display: none;
}

/*
 * Flecha de ir
 */

.quick-info-cata-more {
    background: inherit;
    cursor: pointer;
}

.quick-info-cata-more svg {
    width: 24px;
    height: 24px;
    margin: 6px;
    color: var(--white);
    rotate: 180deg;
}

.quick-info-cata-more.cata-arrow-hint svg {
    animation: cataArrowHint 600ms ease-out 1;
}

@keyframes cataArrowHint {

    0% {
        transform: translateX(0);
    }

    35% {
        transform: translateX(14px);
    }

    65% {
        transform: translateX(14px);
    }

    100% {
        transform: translateX(0);
    }

}

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

    .quick-info-cata-more.cata-arrow-hint svg {
        animation: none;
    }

}

/*
 * Flecha de volver
 */

.quick-info-cata-back {
    appearance: none;
    border: 0;
    background: transparent;
    padding: 0;
    margin: 0;
    cursor: pointer;
    flex: 0 0 auto;
}

.quick-info-cata-back svg {
    width: 24px;
    height: 24px;
    margin: 6px;
    color: var(--white);
}

.quick-info-cata-detail-model {
    flex: 1 1 auto;
    min-width: 0;
    margin: 0;
    padding: 0;
    font-size: 24px;
    line-height: 1.2;
    font-weight: 700;
    text-transform: capitalize;
    font-family: var(--font-outfit);
    letter-spacing: -.5px;
    color: var(--white);
}


/*
 * Contenido de la Cata
 */

.quick-info-cata-detail-body {
    flex: 1 1 auto;

    min-height: 0;

    overflow-y: auto;
    overflow-x: hidden;

    -webkit-overflow-scrolling: touch;

    padding: 0 0 50px;

    box-sizing: border-box;
}

.quick-info-cata-detail-body h2 {
    font-size: 14px;
    line-height: initial;
    font-weight: 600;
}

.quick-info-cata-detail-body p {
    font-size: 14px;
    line-height: 18px;
    width: 100%;
    margin-block-start: 1em;
    margin-block-end: 1em;
}

.quick-info-cata-detail-body strong {
    font-size: 14px;
    line-height: 18px;
}

/* =========================================================
 * CKS! QUICK — ASPECTOS DE LA CATA
 * ========================================================= */

.quick-info-cata-aspects {
    width: 100%;
    padding: 6px 0 16px;
}

/* ---------------------------------------------------------
 * CARRUSEL HORIZONTAL
 * --------------------------------------------------------- */

.quick-info-cata-aspects-track {
    display: flex;
    flex-wrap: nowrap;
    gap: 10px;

    width: 100%;
    max-width: 100%;

    overflow-x: auto;
    overflow-y: hidden;

    padding: 0 2px 4px;

    scrollbar-width: none;
    -webkit-overflow-scrolling: touch;
}

.quick-info-cata-aspects-track::-webkit-scrollbar {
    display: none;
}

.quick-info-cata-aspect {
    flex: 0 0 auto;
}

/* ---------------------------------------------------------
 * TARJETA
 * --------------------------------------------------------- */

.quick-info-cata-aspect {
    flex: 0 0 auto;
    gap: 4px;
    min-width: 70px;
    padding: 12px 0;
    border-radius: 9px;
    background: var(--ShuttleGrey);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
}

/* ---------------------------------------------------------
 * NOTA
 * --------------------------------------------------------- */

.quick-info-cata-aspect-score {
    display: block;
    font-size: 22px;
    line-height: 1;
    font-weight: 800;
    letter-spacing: -.3px;
    color: var(--white);
    font-family: var(--font-outfit);
}

/* ---------------------------------------------------------
 * TÍTULO
 * --------------------------------------------------------- */

.quick-info-cata-aspect-title {
    display: block;
    font-size: 13px;
    line-height: 1.15;
    font-weight: 400;
    white-space: nowrap;
    color: var(--white);
}

/* ==========================================================
 * MOBILE
 * ========================================================== */

@media (max-width: 480px) {

    .quick-info-modal {
        padding: 12px;
    }

    .quick-info-dialog {
        max-height:
            calc(100vh - 24px);

        padding:
            21px 18px;

        border-radius: 14px;
    }

    .quick-info-header {
        padding-right: 38px;
    }

    .quick-info-title-row {
        align-items: flex-start;
        gap: 9px;
    }

    .quick-info-links {
        gap: 5px;
    }

    .quick-info-link {
        flex-basis: 32px;

        width: 32px;
        height: 32px;

        padding: 6px;
    }

    .quick-info-nationality {
        margin-bottom: 15px;
    }

    .quick-info-cata {
        margin:
            -21px -18px 12px;
        padding:
            13px 18px;
    }

    /* Servicios: en móvil se utiliza todo el ancho y se navega al tacto. */
    .quick-info-services-shell {
        width: 100%;
        max-width: 100%;
        gap: 0;
    }

    .quick-info-services-viewport {
        flex: 1 1 100%;
        width: 100% !important;
        max-width: 100%;
    }

    .quick-info-services-controls {
        display: none !important;
    }

    /* Características: mismo comportamiento táctil que Servicios. */
    .quick-info-characteristics-shell {
        width: 100%;
        max-width: 100%;
        gap: 0;
    }

    .quick-info-characteristics-viewport {
        flex: 1 1 100%;
        width: 100% !important;
        max-width: 100%;
    }

    .quick-info-characteristics-controls {
        display: none !important;
    }
}