/* ==========================================================
   BRANDS PAGE
   SOSMedical
========================================================== */


/*
|--------------------------------------------------------------------------
| Hero
|--------------------------------------------------------------------------
*/

.brands-hero {
    position: relative;
    overflow: hidden;

    padding: 110px 0 90px;

    background:
        radial-gradient(
            circle at 85% 15%,
            rgba(0, 153, 216, 0.12),
            transparent 28%
        ),
        linear-gradient(
            135deg,
            #f8fcff,
            #eef7fb,
            #ffffff
        );
}

.brands-hero::before {
    position: absolute;
    top: -160px;
    right: -160px;

    width: 500px;
    height: 500px;

    content: "";
    pointer-events: none;

    border: 70px solid rgba(0, 153, 216, 0.04);
    border-radius: 50%;
}

.brands-hero__eyebrow {
    color: var(--secondary);

    font-size: 12px;
    font-weight: 700;
    letter-spacing: .12em;
    text-transform: uppercase;
}

.brands-hero__title {
    max-width: 850px;
    margin-top: 18px;

    font-size: clamp(42px, 6vw, 72px);
    line-height: 1.05;
}

.brands-hero__description {
    max-width: 720px;
    margin-top: 22px;

    color: var(--text-light);

    font-size: 18px;
    line-height: 1.9;
}


/*
|--------------------------------------------------------------------------
| Brands section
|--------------------------------------------------------------------------
*/

.brands-section {
    padding: 100px 0;
}

.brands-section__heading {
    margin-bottom: 70px;

    text-align: center;
}

.brands-section__title {
    font-size: clamp(32px, 5vw, 52px);
}

.brands-section__text {
    max-width: 700px;
    margin: 18px auto 0;

    color: var(--text-light);

    font-size: 17px;
    line-height: 1.8;
}


/*
|--------------------------------------------------------------------------
| Grid
|--------------------------------------------------------------------------
*/

.brands-grid {
    display: grid;
    grid-template-columns:
        repeat(3, minmax(0, 1fr));
    gap: 30px;
}


/*
|--------------------------------------------------------------------------
| Brand card
|--------------------------------------------------------------------------
*/

.brand-card {
    position: relative;

    overflow: hidden;

    background: var(--white);

    border: 1px solid rgba(11, 35, 65, .08);
    border-radius: 26px;

    box-shadow: var(--shadow-sm);

    transition:
        transform .35s ease,
        box-shadow .35s ease,
        border-color .35s ease;
}

.brand-card:hover {
    transform: translateY(-8px);

    border-color: rgba(0, 153, 216, .18);

    box-shadow:
        0 24px 50px rgba(11, 35, 65, .10);
}


/*
|--------------------------------------------------------------------------
| Desktop card
|--------------------------------------------------------------------------
*/

.brand-card__desktop {
    display: block;
}


/*
|--------------------------------------------------------------------------
| Mobile card
|--------------------------------------------------------------------------
*/

.brand-card-mobile {
    display: none;
}


/*
|--------------------------------------------------------------------------
| Principal brand
|--------------------------------------------------------------------------
*/

.brand-card--principal {
    border: 2px solid rgba(0, 153, 216, .20);

    background:
        linear-gradient(
            180deg,
            rgba(0, 153, 216, .03),
            #ffffff
        );
}

.brand-card--principal::before {
    position: absolute;
    top: 18px;
    right: 18px;
    z-index: 8;

    content: "Principal";

    padding: 8px 12px;

    color: var(--white);

    font-size: 11px;
    font-weight: 700;
    letter-spacing: .05em;
    text-transform: uppercase;

    background: var(--secondary);

    border-radius: 999px;
}


/*
|--------------------------------------------------------------------------
| Cover
|--------------------------------------------------------------------------
*/

.brand-card__cover {
    position: relative;

    display: block;

    height: 210px;

    overflow: hidden;

    background:
        linear-gradient(
            135deg,
            #edf7fc,
            #f7fbfd
        );
}

.brand-card__cover img {
    display: block;

    width: 100%;
    height: 100%;

    object-fit: cover;

    transition:
        transform .5s ease;
}

.brand-card:hover
.brand-card__cover img {
    transform: scale(1.05);
}


/*
|--------------------------------------------------------------------------
| Logo
|--------------------------------------------------------------------------
*/

.brand-card__logo-wrapper {
    position: relative;
    z-index: 5;

    display: flex;
    justify-content: center;

    margin-top: -42px;
}

.brand-card__logo {
    display: block;

    width: 120px;
    height: 120px;
    padding: 20px;

    object-fit: contain;

    background: var(--white);

    border-radius: 50%;

    box-shadow:
        0 15px 35px rgba(11, 35, 65, .10);
}


/*
|--------------------------------------------------------------------------
| Body
|--------------------------------------------------------------------------
*/

.brand-card__body {
    padding: 24px 28px 30px;
}

.brand-card__title {
    font-size: 26px;
    text-align: center;
}

.brand-card__title a {
    color: inherit;
}

.brand-card__description {
    min-height: 105px;
    margin-top: 16px;

    color: var(--text-light);

    font-size: 15px;
    line-height: 1.8;
    text-align: center;
}


/*
|--------------------------------------------------------------------------
| Stats
|--------------------------------------------------------------------------
*/

.brand-card__stats {
    display: flex;
    align-items: center;
    justify-content: center;

    margin-top: 20px;
}

.brand-card__count {
    display: inline-flex;
    align-items: center;
    gap: 8px;

    padding: 10px 16px;

    color: var(--secondary);

    font-size: 13px;
    font-weight: 700;

    background:
        rgba(0, 153, 216, .08);

    border-radius: 999px;
}


/*
|--------------------------------------------------------------------------
| Actions
|--------------------------------------------------------------------------
*/

.brand-card__actions {
    display: flex;
    justify-content: center;

    margin-top: 24px;
}

.brand-card__actions .btn {
    width: 100%;
}


/*
|--------------------------------------------------------------------------
| Logos wall
|--------------------------------------------------------------------------
*/

.brand-wall {
    padding: 110px 0;

    background:
        linear-gradient(
            180deg,
            #f7fafc,
            #ffffff
        );
}

.brand-wall__heading {
    margin-bottom: 60px;

    text-align: center;
}

.brand-wall__grid {
    display: grid;
    grid-template-columns:
        repeat(6, minmax(0, 1fr));
    gap: 24px;
}

.brand-wall__item {
    display: flex;
    align-items: center;
    justify-content: center;

    min-height: 120px;
    padding: 18px;

    background: var(--white);

    border: 1px solid rgba(11, 35, 65, .08);
    border-radius: 20px;

    transition:
        transform .3s ease,
        box-shadow .3s ease,
        border-color .3s ease;
}

.brand-wall__item:hover {
    transform: translateY(-5px);

    border-color: rgba(0, 153, 216, .18);

    box-shadow:
        0 15px 30px rgba(11, 35, 65, .08);
}

.brand-wall__logo {
    display: block;

    width: auto;
    max-width: 140px;
    height: auto;
    max-height: 70px;

    object-fit: contain;
}


/*
|--------------------------------------------------------------------------
| CTA
|--------------------------------------------------------------------------
*/

.brands-cta {
    position: relative;

    overflow: hidden;

    padding: 100px 0;

    background:
        linear-gradient(
            135deg,
            var(--secondary),
            #007cb0,
            var(--primary)
        );
}

.brands-cta::before {
    position: absolute;
    top: -120px;
    right: -120px;

    width: 320px;
    height: 320px;

    content: "";
    pointer-events: none;

    border: 60px solid rgba(255, 255, 255, .05);
    border-radius: 50%;
}

.brands-cta__content {
    position: relative;
    z-index: 2;

    text-align: center;
}

.brands-cta__title {
    color: var(--white);

    font-size: clamp(34px, 5vw, 58px);
}

.brands-cta__text {
    max-width: 700px;
    margin: 20px auto 0;

    color: rgba(255, 255, 255, .80);

    font-size: 18px;
    line-height: 1.8;
}

.brands-cta__actions {
    margin-top: 35px;
}

.brands-cta__actions .btn {
    min-width: 240px;
}


/*
|--------------------------------------------------------------------------
| Estado vacío
|--------------------------------------------------------------------------
*/

.brands-empty {
    display: flex;
    align-items: center;
    justify-content: center;
    flex-direction: column;

    min-height: 400px;
    padding: 50px 30px;

    text-align: center;

    background: var(--white);

    border: 1px solid rgba(11, 35, 65, 0.08);
    border-radius: var(--radius-lg);

    box-shadow: var(--shadow-sm);
}


/* ==========================================================
   RESPONSIVE — ESCRITORIO MEDIANO
========================================================== */

@media (max-width: 1200px) {

    .brands-grid {
        grid-template-columns:
            repeat(2, minmax(0, 1fr));
    }

    .brand-wall__grid {
        grid-template-columns:
            repeat(4, minmax(0, 1fr));
    }
}


/* ==========================================================
   RESPONSIVE — MÓVIL / TABLET
========================================================== */

@media (max-width: 768px) {

    /*
    |--------------------------------------------------------------------------
    | Hero
    |--------------------------------------------------------------------------
    */

    /*
|--------------------------------------------------------------------------
| Simplificar cabecera de listado en móvil
|--------------------------------------------------------------------------
*/

    .brands-section__heading {
        margin-bottom: 24px;
    }

    .brands-section__heading
    .section-heading__eyebrow,

    .brands-section__heading
    .brands-section__title,

    .brands-section__heading
    .brands-section__text {
        display: none;
    }

    .brands-section__heading::after {
    display: block;

    content: "LÍNEAS Y MARCAS QUE REPRESENTAMOS";

    color: var(--primary);

    font-size: 10px;
    font-weight: 800;
    letter-spacing: .12em;
    line-height: 1.4;
    text-align: center;
    text-transform: uppercase;
}

.brands-section__heading {
    position: relative;
}

.brands-section__heading::before {
    display: block;

    width: 28px;
    height: 2px;
    margin: 0 auto 12px;

    content: "";

    background:
        linear-gradient(
            90deg,
            var(--secondary),
            var(--success)
        );

    border-radius: 999px;
}

    .brands-hero {
        padding: 62px 0 48px;
    }

    .brands-hero::before {
        top: -120px;
        right: -180px;

        width: 380px;
        height: 380px;

        border-width: 55px;
    }

    .brands-hero__eyebrow {
        font-size: 10px;
        letter-spacing: .10em;
    }

    .brands-hero__title {
        max-width: 600px;
        margin-top: 14px;

        font-size: clamp(34px, 8vw, 46px);
        line-height: 1.07;
    }

    .brands-hero__description {
        max-width: 580px;
        margin-top: 17px;

        font-size: 14px;
        line-height: 1.7;
    }


    /*
    |--------------------------------------------------------------------------
    | Sección principal
    |--------------------------------------------------------------------------
    */

    .brands-section {
    padding: 38px 0 50px;
    }

    .brands-section__heading {
        margin-bottom: 34px;
    }

    .brands-section__title {
        font-size: clamp(28px, 7vw, 38px);
        line-height: 1.12;
    }

    .brands-section__text {
        max-width: 580px;
        margin-top: 13px;

        font-size: 14px;
        line-height: 1.65;
    }


    /*
    |--------------------------------------------------------------------------
    | Grid móvil tipo Home 2
    |--------------------------------------------------------------------------
    */

    .brands-grid {
        grid-template-columns:
            repeat(2, minmax(0, 1fr));
        gap: 13px;

        padding: 15px;

        background:
            linear-gradient(
                145deg,
                rgba(248, 251, 253, .96),
                rgba(255, 255, 255, .99)
            );

        border: 1px solid rgba(11, 35, 65, .08);
        border-radius: 25px;

        box-shadow:
            0 16px 40px rgba(11, 35, 65, .05);
    }


    /*
    |--------------------------------------------------------------------------
    | Ocultar tarjeta de escritorio
    |--------------------------------------------------------------------------
    */

    .brand-card__desktop {
        display: none;
    }


    /*
    |--------------------------------------------------------------------------
    | Limpiar contenedor original
    |--------------------------------------------------------------------------
    */

    .brand-card,
    .brand-card--principal {
        overflow: visible;

        background: transparent;

        border: 0;
        border-radius: 0;

        box-shadow: none;

        transform: none;
    }

    .brand-card:hover {
        transform: none;

        border-color: transparent;

        box-shadow: none;
    }

    /*
     * El distintivo "Principal" de escritorio
     * no debe aparecer en móvil.
     */

    .brand-card--principal::before {
        display: none;
    }


    /*
    |--------------------------------------------------------------------------
    | Tarjeta móvil
    |--------------------------------------------------------------------------
    */

    .brand-card-mobile {
        position: relative;

        display: flex;
        align-items: center;
        justify-content: center;

        min-height: 135px;
        padding: 22px 14px;

        overflow: hidden;

        text-decoration: none;

        background:
            linear-gradient(
                145deg,
                #ffffff,
                #fbfdfe
            );

        border: 1px solid rgba(11, 35, 65, .07);
        border-radius: 19px;

        box-shadow:
            0 6px 18px rgba(11, 35, 65, .035);

        isolation: isolate;

        transition:
            border-color .3s ease,
            box-shadow .3s ease,
            transform .3s ease;
    }

    .brand-card-mobile::before {
        position: absolute;
        inset: 0;
        z-index: -1;

        content: "";

        background:
            radial-gradient(
                circle at 50% 110%,
                rgba(0, 153, 216, .10),
                transparent 48%
            );

        opacity: 0;

        transition:
            opacity .3s ease;
    }

    .brand-card-mobile::after {
        position: absolute;
        right: 22%;
        bottom: 0;
        left: 22%;

        height: 3px;

        content: "";

        background:
            linear-gradient(
                90deg,
                var(--secondary),
                var(--success)
            );

        border-radius:
            999px 999px 0 0;

        opacity: 0;

        transform: scaleX(0);

        transition:
            opacity .3s ease,
            transform .3s ease;
    }


    /*
    |--------------------------------------------------------------------------
    | Marca principal móvil
    |--------------------------------------------------------------------------
    */

    .brand-card-mobile--principal {
        padding-top: 38px;

        background:
            radial-gradient(
                circle at 15% 10%,
                rgba(0, 153, 216, .11),
                transparent 38%
            ),
            linear-gradient(
                145deg,
                rgba(236, 249, 254, .96),
                rgba(241, 253, 248, .96)
            );

        border-color:
            rgba(0, 153, 216, .26);

        box-shadow:
            0 13px 30px rgba(0, 153, 216, .09);
    }

    .brand-card-mobile--principal::after {
        opacity: 1;
        transform: scaleX(1);
    }


    /*
    |--------------------------------------------------------------------------
    | Etiqueta línea principal
    |--------------------------------------------------------------------------
    */

    .brand-card-mobile__label {
        position: absolute;
        top: 9px;
        left: 50%;

        display: inline-flex;
        align-items: center;
        justify-content: center;

        min-height: 20px;
        padding: 4px 8px;

        color: var(--success);
        font-size: 6px;
        font-weight: 800;
        letter-spacing: .07em;
        line-height: 1;
        white-space: nowrap;
        text-transform: uppercase;

        background:
            rgba(232, 250, 243, .96);

        border: 1px solid rgba(0, 182, 122, .18);
        border-radius: 999px;

        transform: translateX(-50%);
    }


    /*
    |--------------------------------------------------------------------------
    | Logo móvil
    |--------------------------------------------------------------------------
    */

    .brand-card-mobile__logo {
        display: block;

        width: auto;
        max-width: 82%;
        height: auto;
        max-height: 70px;

        object-fit: contain;
        object-position: center;

        opacity: .88;

        transition:
            opacity .3s ease,
            transform .3s ease;
    }

    .brand-card-mobile--principal
    .brand-card-mobile__logo {
        max-width: 86%;
        max-height: 74px;

        opacity: 1;
    }


    /*
    |--------------------------------------------------------------------------
    | Muro de logos
    |--------------------------------------------------------------------------
    |
    | En móvil ya tenemos el listado principal convertido
    | en un muro de logos. Ocultamos esta segunda sección
    | porque sería información duplicada.
    |--------------------------------------------------------------------------
    */

    .brand-wall {
        display: none;
    }


    /*
    |--------------------------------------------------------------------------
    | CTA
    |--------------------------------------------------------------------------
    */

    .brands-cta {
        padding: 58px 0;
    }

    .brands-cta::before {
        top: -100px;
        right: -140px;

        width: 270px;
        height: 270px;

        border-width: 45px;
    }

    .brands-cta__title {
        font-size:
            clamp(29px, 7.5vw, 40px);

        line-height: 1.12;
    }

    .brands-cta__text {
        max-width: 580px;
        margin-top: 16px;

        font-size: 14px;
        line-height: 1.65;
    }

    .brands-cta__actions {
        margin-top: 25px;
    }

    .brands-cta__actions .btn {
        width: 100%;
        min-width: 0;
        min-height: 48px;
    }


    /*
    |--------------------------------------------------------------------------
    | Estado vacío
    |--------------------------------------------------------------------------
    */

    .brands-empty {
        min-height: 300px;
        padding: 35px 22px;

        border-radius: 20px;
    }
}


/* ==========================================================
   RESPONSIVE — TELÉFONOS PEQUEÑOS
========================================================== */

@media (max-width: 480px) {

    /*
    |--------------------------------------------------------------------------
    | Hero
    |--------------------------------------------------------------------------
    */

    .brands-hero {
        padding: 46px 0 38px;
    }

    .brands-hero__eyebrow {
        font-size: 9px;
        letter-spacing: .08em;
    }

    .brands-hero__title {
        margin-top: 11px;

        font-size: 30px;
        line-height: 1.07;
    }

    .brands-hero__description {
        margin-top: 13px;

        font-size: 13px;
        line-height: 1.6;
    }


    /*
    |--------------------------------------------------------------------------
    | Sección principal
    |--------------------------------------------------------------------------
    */

    .brands-section {
    padding: 32px 0 42px;
    }

    .brands-section__heading {
        margin-bottom: 27px;
    }

    .brands-section__title {
        font-size: 27px;
        line-height: 1.12;
    }

    .brands-section__text {
        margin-top: 10px;

        font-size: 13px;
        line-height: 1.6;
    }


    /*
    |--------------------------------------------------------------------------
    | Contenedor de marcas
    |--------------------------------------------------------------------------
    */

    .brands-grid {
        grid-template-columns:
            repeat(2, minmax(0, 1fr));
        gap: 9px;

        padding: 11px;

        border-radius: 21px;
    }


    /*
    |--------------------------------------------------------------------------
    | Tarjeta móvil
    |--------------------------------------------------------------------------
    */

    .brand-card-mobile {
        min-height: 108px;
        padding: 16px 9px;

        border-radius: 15px;
    }

    .brand-card-mobile--principal {
        padding-top: 31px;
    }


    /*
    |--------------------------------------------------------------------------
    | Logo
    |--------------------------------------------------------------------------
    */

    .brand-card-mobile__logo {
        max-width: 88%;
        max-height: 55px;
    }

    .brand-card-mobile--principal
    .brand-card-mobile__logo {
        max-width: 90%;
        max-height: 58px;
    }


    /*
    |--------------------------------------------------------------------------
    | Línea principal
    |--------------------------------------------------------------------------
    */

    .brand-card-mobile__label {
        top: 7px;

        min-height: 18px;
        padding: 3px 7px;

        font-size: 5.5px;
    }


    /*
    |--------------------------------------------------------------------------
    | CTA
    |--------------------------------------------------------------------------
    */

    .brands-cta {
        padding: 48px 0;
    }

    .brands-cta__title {
        font-size: 28px;
        line-height: 1.1;
    }

    .brands-cta__text {
        margin-top: 13px;

        font-size: 13px;
        line-height: 1.6;
    }

    .brands-cta__actions {
        margin-top: 20px;
    }

    .brands-cta__actions .btn {
        min-height: 46px;

        font-size: 12px;
    }


    /*
    |--------------------------------------------------------------------------
    | Estado vacío
    |--------------------------------------------------------------------------
    */

    .brands-empty {
        min-height: 260px;
        padding: 30px 18px;

        border-radius: 17px;
    }
}


/* ==========================================================
   DISPOSITIVOS QUE SÍ SOPORTAN HOVER
========================================================== */

@media (hover: hover) and (pointer: fine) {

    @media (max-width: 768px) {

        .brand-card-mobile:hover {
            border-color:
                rgba(0, 153, 216, .24);

            box-shadow:
                0 15px 34px
                rgba(11, 35, 65, .09);

            transform: translateY(-4px);
        }

        .brand-card-mobile:hover::before {
            opacity: 1;
        }

        .brand-card-mobile:hover::after {
            opacity: 1;
            transform: scaleX(1);
        }

        .brand-card-mobile:hover
        .brand-card-mobile__logo {
            opacity: 1;

            transform: scale(1.06);
        }
    }
}


/* ==========================================================
   MOVIMIENTO REDUCIDO
========================================================== */

@media (prefers-reduced-motion: reduce) {

    .brand-card,
    .brand-card__cover img,
    .brand-card-mobile,
    .brand-card-mobile::before,
    .brand-card-mobile::after,
    .brand-card-mobile__logo,
    .brand-wall__item {
        transition: none;
    }
}