
/* =========================================================
   PIE DE PÁGINA CASLA DEL SURESTE
========================================================= */

.footer {
    --footer-azul: #0d5bd7;
    --footer-azul-claro: #2878e8;
    --footer-fondo: #071a36;
    --footer-fondo-secundario: #0b2447;
    --footer-texto: #d4deec;
    --footer-texto-suave: #a8b8ce;

    position: relative;
    margin-top: 60px;
    color: var(--footer-texto);
    background: var(--footer-fondo);
    font-family: inherit;
}

/* =========================================================
   SECCIÓN PRINCIPAL
========================================================= */

.footer-principal {
    position: relative;
    overflow: hidden;
    padding: 58px 0 48px;
    background:
        radial-gradient(
            circle at 8% 0%,
            rgba(40, 120, 232, 0.17),
            transparent 34%
        ),
        linear-gradient(
            135deg,
            #071a36 0%,
            #0a2346 55%,
            #071a36 100%
        );
}

.footer-principal::before {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 3px;
    background: linear-gradient(
        90deg,
        #0d5bd7,
        #55a1ff,
        #0d5bd7
    );
}

.footer-principal .container {
    position: relative;
    z-index: 1;
}

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

.footer-marca {
    display: inline-flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 22px;
    color: #ffffff;
    text-decoration: none;
    transition: transform 0.25s ease;
}

.footer-marca:hover {
    color: #ffffff;
    transform: translateY(-2px);
}

.footer-logo-icono {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 49px;
    height: 49px;
    flex-shrink: 0;
    color: #ffffff;
    font-size: 23px;
    background: linear-gradient(
        135deg,
        #2878e8,
        #0d5bd7
    );
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 14px;
    box-shadow: 0 7px 20px rgba(13, 91, 215, 0.25);
}

.footer-logo-texto {
    display: flex;
    flex-direction: column;
    line-height: 1.1;
}

.footer-logo-texto strong {
    color: #ffffff;
    font-size: 25px;
    font-weight: 800;
    letter-spacing: 1.5px;
}

.footer-logo-texto small {
    margin-top: 5px;
    color: #8ebaff;
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 3px;
}

/* =========================================================
   DESCRIPCIÓN Y DISTINTIVO
========================================================= */

.footer-descripcion {
    max-width: 350px;
    margin: 0 0 21px;
    color: var(--footer-texto-suave);
    font-size: 14px;
    line-height: 1.9;
}

.footer-distintivo {
    display: inline-flex;
    align-items: center;
    gap: 9px;
    padding: 10px 13px;
    color: #dceaff;
    font-size: 12px;
    font-weight: 600;
    background: rgba(40, 120, 232, 0.12);
    border: 1px solid rgba(104, 165, 255, 0.22);
    border-radius: 9px;
}

.footer-distintivo i {
    color: #75adff;
    font-size: 15px;
}

/* =========================================================
   TÍTULOS
========================================================= */

.footer-titulo {
    position: relative;
    display: inline-block;
    margin: 7px 0 25px;
    padding-bottom: 12px;
    color: #ffffff;
    font-size: 16px;
    font-weight: 750;
    letter-spacing: 0.2px;
}

.footer-titulo::after {
    content: "";
    position: absolute;
    bottom: 0;
    left: 0;
    width: 36px;
    height: 3px;
    background: var(--footer-azul-claro);
    border-radius: 10px;
}

/* =========================================================
   ENLACES
========================================================= */

.footer-enlaces {
    display: flex;
    flex-direction: column;
    gap: 14px;
    margin: 0;
    padding: 0;
    list-style: none;
}

.footer-enlaces li {
    margin: 0;
    padding: 0;
}

.footer-enlaces a {
    display: inline-flex;
    align-items: center;
    gap: 9px;
    color: var(--footer-texto-suave);
    font-size: 13.5px;
    line-height: 1.6;
    text-decoration: none;
    transition:
        color 0.2s ease,
        transform 0.2s ease;
}

.footer-enlaces a i {
    color: #4f94f5;
    font-size: 11px;
    transition: transform 0.2s ease;
}

.footer-enlaces a:hover {
    color: #ffffff;
    transform: translateX(4px);
}

.footer-enlaces a:hover i {
    transform: translateX(2px);
}

/* =========================================================
   CONTACTO
========================================================= */

.footer-contacto {
    display: flex;
    flex-direction: column;
    gap: 19px;
}

.footer-contacto-item {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    min-width: 0;
}

.footer-contacto-icono {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 38px;
    height: 38px;
    flex-shrink: 0;
    color: #8dbbff;
    font-size: 15px;
    background: rgba(40, 120, 232, 0.13);
    border: 1px solid rgba(104, 165, 255, 0.16);
    border-radius: 10px;
}

.footer-contacto-item > div {
    display: flex;
    flex-direction: column;
    gap: 5px;
    min-width: 0;
    padding-top: 2px;
}

.footer-contacto-item strong {
    color: #ffffff;
    font-size: 12px;
    font-weight: 700;
}

.footer-contacto-item a,
.footer-contacto-item div > span {
    overflow-wrap: anywhere;
    color: var(--footer-texto-suave);
    font-size: 12.5px;
    line-height: 1.6;
    text-decoration: none;
    transition: color 0.2s ease;
}

.footer-contacto-item a:hover {
    color: #8dbbff;
}

/* =========================================================
   BARRA INFERIOR
========================================================= */

.footer-inferior {
    padding: 19px 0;
    background: rgba(0, 0, 0, 0.19);
    border-top: 1px solid rgba(255, 255, 255, 0.09);
}

.footer-inferior-contenido {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 15px 25px;
}

.footer-copy,
.footer-credit {
    margin: 0;
    color: var(--footer-texto-suave);
    font-size: 12px;
    line-height: 1.8;
}

.footer-copy strong {
    color: #ffffff;
    font-weight: 700;
}

.footer-credit {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 5px;
    flex-wrap: wrap;
}

.footer-credit i {
    margin: 0 2px;
    color: #ff5b75;
    font-size: 12px;
    animation: footer-latido 1.8s ease-in-out infinite;
}

.footer-credit strong {
    color: #ffffff;
    font-size: 13px;
    font-weight: 800;
    letter-spacing: 0.3px;
}

/* =========================================================
   BOTÓN FLOTANTE WHATSAPP
========================================================= */

.whatsapp-float {
    position: fixed;
    right: 24px;
    bottom: 24px;
    z-index: 1050;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 58px;
    height: 58px;
    color: #ffffff;
    font-size: 31px;
    text-decoration: none;
    background: #20c766;
    border: 3px solid rgba(255, 255, 255, 0.95);
    border-radius: 50%;
    box-shadow:
        0 5px 18px rgba(0, 0, 0, 0.22),
        0 0 0 5px rgba(32, 199, 102, 0.13);
    transition:
        transform 0.25s ease,
        background 0.25s ease,
        box-shadow 0.25s ease;
}

.whatsapp-float:hover {
    color: #ffffff;
    background: #16a957;
    transform: translateY(-4px) scale(1.04);
    box-shadow:
        0 9px 24px rgba(0, 0, 0, 0.25),
        0 0 0 7px rgba(32, 199, 102, 0.15);
}

.whatsapp-float:focus-visible {
    outline: 3px solid #ffffff;
    outline-offset: 4px;
}

/* =========================================================
   ANIMACIÓN DISCRETA
========================================================= */

@keyframes footer-latido {
    0%,
    100% {
        transform: scale(1);
    }

    50% {
        transform: scale(1.16);
    }
}

/* =========================================================
   TABLET
========================================================= */

@media (max-width: 991.98px) {

    .footer {
        margin-top: 45px;
    }

    .footer-principal {
        padding: 45px 0 35px;
    }

    .footer-titulo {
        margin-top: 4px;
    }

    .footer-descripcion {
        max-width: 430px;
    }
}

/* =========================================================
   CELULARES
========================================================= */

@media (max-width: 767.98px) {

    .footer {
        margin-top: 35px;
    }

    .footer-principal {
        padding: 27px 0 24px;
    }

    /* Distribución general en dos columnas */

    .footer-principal .container > .row {
        display: grid !important;
        grid-template-columns: minmax(0, 1fr) minmax(0, 1fr) !important;
        grid-template-areas:
            "marca marca"
            "explora compra"
            "contacto contacto";
        column-gap: 0 !important;
        row-gap: 19px !important;
        margin-left: 0 !important;
        margin-right: 0 !important;
    }

    .footer-principal .container > .row > div {
        width: auto !important;
        max-width: none !important;
        min-width: 0;
        flex: none !important;
        margin: 0 !important;
        padding-left: 10px;
        padding-right: 10px;
    }
    

    /* -----------------------------------------------------
       MARCA CASLA
    ----------------------------------------------------- */

    .footer-principal .container > .row > div:nth-child(1) {
        grid-area: marca;
        text-align: center;
    }

    .footer-marca {
        justify-content: center;
        gap: 10px;
        margin-bottom: 9px;
    }

    .footer-logo-icono {
        width: 43px;
        height: 43px;
        font-size: 20px;
        border-radius: 12px;
    }

    .footer-logo-texto strong {
        font-size: 22px;
    }

    .footer-logo-texto small {
        font-size: 10px;
        letter-spacing: 2.5px;
    }

    .footer-descripcion {
        max-width: 440px;
        margin: 0 auto 10px;
        font-size: 12.5px;
        line-height: 1.55;
    }

    .footer-distintivo {
        gap: 7px;
        padding: 7px 10px;
        font-size: 11px;
    }

    .footer-distintivo i {
        font-size: 13px;
    }

    /* -----------------------------------------------------
       EXPLORA Y TU COMPRA
    ----------------------------------------------------- */

    .footer-principal .container > .row > div:nth-child(2) {
        grid-area: explora;
        text-align: left;
    }

    .footer-principal .container > .row > div:nth-child(3) {
        grid-area: compra;
        text-align: left;
    }

    .footer-principal .container > .row > div:nth-child(2) .footer-titulo,
    .footer-principal .container > .row > div:nth-child(3) .footer-titulo {
        display: inline-block;
        margin: 0 0 10px;
        padding-bottom: 7px;
        font-size: 14px;
    }

    .footer-principal .container > .row > div:nth-child(2) .footer-titulo::after,
    .footer-principal .container > .row > div:nth-child(3) .footer-titulo::after {
        left: 0;
        transform: none;
    }

    .footer-enlaces {
        align-items: flex-start;
        gap: 7px;
    }

    .footer-enlaces a {
        gap: 6px;
        font-size: 12px;
        line-height: 1.45;
    }

    .footer-enlaces a i {
        font-size: 10px;
    }

    /* -----------------------------------------------------
       CONTACTO COMPACTO
    ----------------------------------------------------- */

    .footer-principal .container > .row > div:nth-child(4) {
        grid-area: contacto;
        text-align: center;
    }

    .footer-principal .container > .row > div:nth-child(4) .footer-titulo {
        display: inline-block;
        margin: 0 0 12px;
        padding-bottom: 7px;
        font-size: 14px;
    }

    .footer-principal .container > .row > div:nth-child(4) .footer-titulo::after {
        left: 50%;
        transform: translateX(-50%);
    }

    /* Dos columnas para teléfono y correo */

    .footer-contacto {
        display: grid;
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 11px 10px;
        align-items: stretch;
    }

    .footer-contacto-item {
        width: 100%;
        min-width: 0;
        align-items: center;
        gap: 8px;
        padding: 9px;
        text-align: left;
        background: rgba(255, 255, 255, 0.035);
        border: 1px solid rgba(255, 255, 255, 0.07);
        border-radius: 10px;
    }

    .footer-contacto-icono {
        width: 31px;
        height: 31px;
        font-size: 12px;
        border-radius: 8px;
    }

    .footer-contacto-item > div {
        flex: 1;
        gap: 3px;
        padding-top: 0;
    }

    .footer-contacto-item strong {
        font-size: 10.5px;
        line-height: 1.3;
    }

    .footer-contacto-item a,
    .footer-contacto-item div > span {
        font-size: 11px;
        line-height: 1.4;
        overflow-wrap: anywhere;
    }

    /* Ubicación ocupa toda la fila */

    .footer-contacto-item:nth-child(3) {
        grid-column: 1 / -1;
        max-width: none;
    }

    /* -----------------------------------------------------
       BARRA INFERIOR
    ----------------------------------------------------- */

    .footer-inferior {
        padding: 11px 0;
    }

    .footer-inferior-contenido {
        flex-direction: row;
        align-items: center;
        justify-content: space-between;
        gap: 8px 12px;
    }

    .footer-copy,
    .footer-credit {
        font-size: 10.5px;
        line-height: 1.45;
    }

    .footer-credit {
        justify-content: flex-end;
        flex-shrink: 0;
    }

    .footer-credit strong {
        font-size: 11px;
    }

    /* -----------------------------------------------------
       WHATSAPP
    ----------------------------------------------------- */

    .whatsapp-float {
        right: 14px;
        bottom: 14px;
        width: 49px;
        height: 49px;
        font-size: 25px;
    }
}


/* =========================================================
   CELULARES
========================================================= */

@media (max-width: 767.98px) {

    .footer {
        margin-top: 30px;
    }

    .footer-principal {
        padding: 28px 0 25px;
    }

    /* DISTRIBUCIÓN PRINCIPAL */

    .footer-principal .container > .row {
        display: grid !important;
        grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
        grid-template-areas:
            "marca marca"
            "explora compra"
            "contacto contacto";
        column-gap: 12px !important;
        row-gap: 24px !important;
        margin: 0 !important;
    }

    .footer-principal .container > .row > div {
        width: auto !important;
        max-width: none !important;
        min-width: 0;
        flex: none !important;
        margin: 0 !important;
        padding: 0 8px !important;
    }

    /* MARCA CASLA */

    .footer-principal .container > .row > div:nth-child(1) {
        grid-area: marca;
        text-align: center;
    }

    .footer-marca {
        display: flex;
        justify-content: center;
        width: fit-content;
        margin: 0 auto 12px;
        gap: 10px;
    }

    .footer-logo-icono {
        width: 43px;
        height: 43px;
        font-size: 20px;
        border-radius: 12px;
    }

    .footer-logo-texto strong {
        font-size: 22px;
    }

    .footer-logo-texto small {
        font-size: 10px;
        letter-spacing: 2.5px;
    }

    .footer-descripcion {
        width: 100%;
        max-width: 430px;
        margin: 0 auto 13px;
        font-size: 12.5px;
        line-height: 1.65;
        text-align: justify;
        text-align-last: center;
    }

    .footer-distintivo {
        display: flex;
        justify-content: center;
        width: fit-content;
        max-width: 100%;
        margin: 0 auto;
        padding: 8px 11px;
        gap: 7px;
        font-size: 11px;
        text-align: center;
    }

    /* EXPLORA Y TU COMPRA */

    .footer-principal .container > .row > div:nth-child(2) {
        grid-area: explora;
        text-align: center;
    }

    .footer-principal .container > .row > div:nth-child(3) {
        grid-area: compra;
        text-align: center;
    }

    .footer-principal .container > .row > div:nth-child(2) .footer-titulo,
    .footer-principal .container > .row > div:nth-child(3) .footer-titulo {
        display: block;
        width: fit-content;
        margin: 0 auto 13px;
        padding-bottom: 8px;
        font-size: 14px;
        text-align: center;
    }

    .footer-principal .container > .row > div:nth-child(2) .footer-titulo::after,
    .footer-principal .container > .row > div:nth-child(3) .footer-titulo::after {
        left: 50%;
        transform: translateX(-50%);
    }

    .footer-enlaces {
        display: flex;
        align-items: flex-start;
        gap: 9px;
        width: fit-content;
        max-width: 100%;
        margin: 0 auto;
    }

    .footer-enlaces li {
        width: 100%;
        text-align: left;
    }

    .footer-enlaces a {
        display: flex;
        align-items: flex-start;
        gap: 7px;
        font-size: 12px;
        line-height: 1.5;
        text-align: left;
    }

    .footer-enlaces a i {
        flex-shrink: 0;
        margin-top: 4px;
        font-size: 10px;
    }

    /* CONTACTO */

    .footer-principal .container > .row > div:nth-child(4) {
        grid-area: contacto;
        text-align: center;
    }

    .footer-principal .container > .row > div:nth-child(4) .footer-titulo {
        display: block;
        width: fit-content;
        margin: 0 auto 15px;
        padding-bottom: 8px;
        font-size: 14px;
    }

    .footer-principal .container > .row > div:nth-child(4) .footer-titulo::after {
        left: 50%;
        transform: translateX(-50%);
    }

    .footer-contacto {
        display: grid;
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 10px;
        align-items: stretch;
        max-width: 540px;
        margin: 0 auto;
    }

    .footer-contacto-item {
        display: flex;
        align-items: center;
        gap: 9px;
        width: 100%;
        min-width: 0;
        padding: 10px;
        text-align: left;
        background: rgba(255, 255, 255, 0.045);
        border: 1px solid rgba(255, 255, 255, 0.08);
        border-radius: 10px;
    }

    .footer-contacto-icono {
        width: 32px;
        height: 32px;
        flex-shrink: 0;
        font-size: 12px;
        border-radius: 8px;
    }

    .footer-contacto-item > div {
        flex: 1;
        min-width: 0;
        gap: 4px;
        padding: 0;
    }

    .footer-contacto-item strong {
        font-size: 10.5px;
        line-height: 1.4;
    }

    .footer-contacto-item a,
    .footer-contacto-item div > span {
        font-size: 11px;
        line-height: 1.5;
        overflow-wrap: anywhere;
        text-align: left;
    }

    .footer-contacto-item:nth-child(3) {
        grid-column: 1 / -1;
    }

    /* BARRA INFERIOR */

    .footer-inferior {
        padding: 13px 10px;
    }

    .footer-inferior-contenido {
        display: flex;
        flex-direction: column;
        align-items: center;
        justify-content: center;
        gap: 7px;
        text-align: center;
    }

    .footer-copy,
    .footer-credit {
        justify-content: center;
        margin: 0;
        font-size: 10.5px;
        line-height: 1.5;
        text-align: center;
    }

    .footer-credit {
        flex-wrap: wrap;
    }

    .footer-credit strong {
        font-size: 11px;
    }

    /* WHATSAPP */

    .whatsapp-float {
        right: 14px;
        bottom: 14px;
        width: 49px;
        height: 49px;
        font-size: 25px;
    }
}

/* =========================================================
   CELULARES PEQUEÑOS
========================================================= */

@media (max-width: 400px) {

    .footer-principal {
        padding: 24px 0 21px;
    }

    .footer-principal .container > .row {
        column-gap: 6px !important;
        row-gap: 20px !important;
    }

    .footer-principal .container > .row > div {
        padding-left: 5px !important;
        padding-right: 5px !important;
    }

    .footer-descripcion {
        font-size: 12px;
        line-height: 1.6;
    }

    .footer-enlaces {
        gap: 8px;
    }

    .footer-enlaces a {
        font-size: 11.5px;
    }

    .footer-contacto {
        gap: 8px;
    }

    .footer-contacto-item {
        gap: 7px;
        padding: 8px;
    }

    .footer-contacto-icono {
        width: 29px;
        height: 29px;
        font-size: 11px;
    }

    .footer-contacto-item strong {
        font-size: 10px;
    }

    .footer-contacto-item a,
    .footer-contacto-item div > span {
        font-size: 10.5px;
    }
}

/* =========================================================
   CELULARES MUY ESTRECHOS
========================================================= */

@media (max-width: 340px) {

    .footer-principal .container > .row {
        grid-template-columns: 1fr !important;
        grid-template-areas:
            "marca"
            "explora"
            "compra"
            "contacto";
    }

    .footer-principal .container > .row > div:nth-child(2),
    .footer-principal .container > .row > div:nth-child(3) {
        text-align: center;
    }

    .footer-enlaces {
        align-items: center;
    }

    .footer-contacto {
        grid-template-columns: 1fr;
    }

    .footer-contacto-item:nth-child(3) {
        grid-column: auto;
    }
}

/* =========================================================
   RESPETAR PREFERENCIAS DE MOVIMIENTO
========================================================= */

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

    .footer-credit i {
        animation: none;
    }

    .footer a {
        transition: none;
    }
}
