/* ═══════════════════════════════════════════════════════════
   FOOTER.CSS — Carlos Sánchez Donate
   Refactor 2026 · Organizado y con microinteracciones
   ═══════════════════════════════════════════════════════════ */

/* ─── 1. SHARE RRSS (bloque compartir) ──────────────────── */
.share-rrss {
    margin-bottom: 8px;
    font-family: var(--font-heading);
    font-weight: 800;
    font-size: 1.5rem;
    text-align: center;
}

.bloque-share-rrss {
    width: 50%;
    margin: 48px auto;
}

.share-icons-rrss {
    display: flex;
    flex-direction: row;
    flex-wrap: nowrap;
    align-items: center;
    justify-content: space-evenly;
    min-width: 200px;
}

.x-twitter { filter: invert(1); }

/* ─── 2. MAIN FOOTER ─────────────────────────────────────── */
#main-footer {
    height: calc(100vh - 128px);
    min-height: 708px;
    margin: auto;
    padding: 0 var(--padding-site);
    display: flex;
    flex-direction: column;
    justify-content: space-around;
}

#primaryfooter.row-elements {
    display: flex;
    flex-direction: row;
    justify-content: space-between;
    align-items: stretch;
    padding: 0;
}

/* FIX del bug histórico: el selector era "main-footer" sin # ni . 
   Corregido a #main-footer para que efectivamente centre la 1ª columna. */
#main-footer .footer-column:nth-child(1) {
    display: flex;
    align-items: center;
}

.title-footer {
    display: flex;
}
.title-footer img {
    height: 120px;
    margin: auto;
}

/* ─── 3. POST FOOTER (barra inferior) ───────────────────── */
section#post-footer {
    height: 56px;
    display: flex;
    align-items: center;
    justify-content: space-around;
}

.post-footer {
    display: flex;
    justify-content: space-around;
}

section#post-footer .container { padding: 8px 0; }

/* ─── 4. COLUMNAS Y LISTAS ──────────────────────────────── */
.footer-column {
    max-width: 24%;
}

.footer-column .title-column {
    margin: 0 0 24px;
}

.titlesfooter {
    font-family: var(--font-heading);
    font-size: 1rem;
    font-weight: 700;
}

ul.footer-list,
.post-footer ul {
    list-style: none;
    margin: auto;
    padding-left: 0;
    max-width: 90vw;
    font-size: 1rem;
    text-transform: uppercase;
}

ul.footer-list li {
    max-width: 100%;
    height: 32px;
    margin: 8px 0;
    font-size: 1rem;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

ul.footer-list a,
.post-footer ul a {
    color: var(--white);
    text-decoration: none;
    transition: color var(--t-fast);
}

ul.footer-list a:hover { color: var(--secondary); }

.post-footer ul { display: flex; }

.post-footer ul li {
    margin-right: 64px;
    line-height: 1;
    text-align: center;
}

.post-footer ul a:hover { color: var(--main); }

/* Colores y frase del footer */
.light-gray-color { color: var(--grey); }
.dark-gray-bg { background-color: var(--grey); }

.frase-footer p {
    text-transform: uppercase;
    font-size: 1rem;
    line-height: 1.2;
}

/* ─── 5. NEWSLETTER ─────────────────────────────────────── */
.newsletter-monhly {
    margin-bottom: 16px;
    font-size: 0.875rem;
}

.sib_signup_box_inside_2 { display: flex; }

.footer-column input[type="text"] {
    width: 160px;
    padding: 6px 14px;
    background: var(--white);
    border: none;
    border-radius: var(--radius-xs);
    font-family: var(--font-heading);
    transition: box-shadow var(--t-base);
}

.footer-column input[type="text"]:focus {
    outline: none;
    box-shadow: var(--shadow-focus);
}

.footer-column .send-icon { display: contents; }

.footer-column .send-icon input {
    padding: 3px 10px 5px;
    background: var(--main);
    color: var(--white);
    border: 0;
    border-radius: var(--radius-xs);
    font-weight: 400;
    cursor: pointer;
    transition: background var(--t-fast), transform var(--t-fast);
}

.footer-column .send-icon input:hover {
    background: var(--black);
    transform: translateY(-1px);
}

/* ─── 6. REDES SOCIALES DEL FOOTER ──────────────────────── */
section#remark { padding-bottom: 32px; }

.rrss-footer {
    display: flex;
    align-items: flex-end;
    justify-content: space-around;
}

img.rrss-picture { width: 50px; }

/* Hover sin shift (antes cambiaba padding de 8→7 y creaba salto de 1px) */
.rrss-footer a {
    width: 80px;
    height: 80px;
    padding: 8px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: space-between;
    cursor: pointer;
    border: 1px solid transparent;
    border-radius: var(--radius-sm);
    transition: border-color var(--t-fast), transform var(--t-fast), box-shadow var(--t-base);
}

.rrss-footer a:hover {
    border-color: var(--main);
    transform: translateY(-3px);
    box-shadow: var(--shadow-main);
}

.single-rrss {
    font-family: var(--font-heading);
    font-size: 0.75rem;
    font-weight: 600;
    color: var(--white);
}

/* ─── 7. HOVERS GLOBALES (heredados del CSS original) ───── */
.posts-picture-hovered > .masinfo-text {
    background: var(--secondary);
}
.posts-picture-hovered::before {
    clip-path: polygon(150% 0, 100% 0, 100% 99%, 0% 225%);
}

ul#main-navbar li a:hover {
    background-color: var(--main);
    color: var(--white);
    text-shadow: 0 0 20px var(--black);
}

.categories-blog:hover { background: var(--secondary); }

button#search-button:hover {
    background: var(--secondary);
    color: var(--black);
    transition: all 0.2s linear;
}

/* ─── 8. TRABAJOS / TECNOLOGÍAS ─────────────────────────── */
.trabajo-display {
    padding: 80px 0;
    background: var(--white);
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: center;
}

.posts-tecs,
.posts-business {
    display: flex;
    align-items: flex-end;
    justify-content: flex-end;
    background-color: var(--white);
    background-repeat: no-repeat;
    background-position: center;
    background-size: cover;
    border-radius: var(--radius-xs);
    object-fit: cover;
    transition: transform var(--t-fast), box-shadow var(--t-base);
}

.posts-tecs:hover,
.posts-business:hover {
    transform: translateY(-3px);
    box-shadow: var(--shadow-md);
}

.posts-business { width: 256px; height: 100px; }
.posts-tecs { width: 160px; height: 160px; }

.excerpt-business,
.excerpt-tecs { margin: 8px 16px; }

.excerpt-tecs {
    display: flex;
    flex-direction: column-reverse;
    align-items: center;
}

h3.tecs-pics {
    margin: inherit;
    font-family: var(--font-heading);
    font-size: 1.625rem;
    line-height: 1;
    text-transform: none;
}

/* ─── 9. COOKIES (cn-cookie-notice) ─────────────────────── */
a#cn-accept-cookie {
    background-color: var(--secondary) !important;
    color: var(--black) !important;
}

a#cn-refuse-cookie,
a#cn-more-info {
    background-color: var(--black) !important;
}

/* ─── 10. FORMULARIOS WPCF7 / SENDINBLUE ────────────────── */
form#sib_signup_form_2 p.sib-alert-message-success {
    background-color: #dff0d8;
    border-color: #d6e9c6;
    color: #3c763d;
}

span.wpcf7-not-valid-tip {
    padding: 8px;
    background: #e36b6b;
    color: var(--white);
    font-weight: 600;
    border-radius: var(--radius-xs);
}

.wpcf7-response-output {
    color: var(--black);
    font-weight: 600;
    font-style: italic;
}

.screen-reader-response { display: none; }
.sib_loader { position: absolute; }

/* ─── 11. UTILIDADES / VARIOS ───────────────────────────── */
.dblock { display: block !important; }
.master_reservar_nav { cursor: pointer; }
.choosenotfound { margin-top: 16px; }
.precatnfound { margin: 16px auto; }

div#twitch-embed {
    display: flex;
    justify-content: center;
}

.noscriptwar {
    width: fit-content;
    margin: auto;
    padding: 8px;
    text-align: center;
    border: 1px solid var(--secondary);
    border-radius: var(--radius-xs);
}

/* ─── 12. ERROR 404 ─────────────────────────────────────── */
.error404 {
    height: auto !important;
    margin-top: 128px;
    margin-bottom: 40px;
}

/* ═══════════════════════════════════════════════════════════
   13. MEDIA QUERIES (ordenadas de menor a mayor)
   ═══════════════════════════════════════════════════════════ */

/* ≤ 362 — share icons en columna */
@media only screen and (max-width: 362px) {
    .share-icons-rrss {
        flex-direction: column;
        flex-wrap: wrap;
        align-items: center;
        min-width: auto;
    }
    .share-icons-rrss div { margin: 8px; }
}

/* ≤ 494 — móvil pequeño */
@media only screen and (max-width: 494px) {
    .error404 { margin-top: 40px; }

    .posts-picture::before {
        clip-path: polygon(150% 0, 100% 0, 100% 99%, 0% 225%) !important;
    }

    .excerpt-post a {
        display: flex;
        flex-direction: column;
        align-items: center;
    }

    #main-footer { height: auto; }

    #primaryfooter.row-elements { margin: 24px 0; }

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

/* ≤ 865 — post-footer en columna */
@media only screen and (max-width: 865px) {
    section#post-footer {
        height: auto;
        background: var(--light-grey);
    }

    .post-footer nav ul {
        margin: 0;
        display: flex;
        flex-direction: column;
        align-items: center;
        text-align: center;
    }

    .post-footer ul li {
        margin: 8px 0;
        font-size: 0.75rem;
        font-weight: bolder;
    }

    .post-footer ul a {
        color: var(--black);
        text-decoration: none;
    }
}

/* ≤ 1119 — footer plegado */
@media only screen and (max-width: 1119px) {
    .title-footer img { height: 80px; }

    #primaryfooter.row-elements {
        flex-direction: column;
        align-items: center;
        text-align: center;
        margin: 8px 0;
    }

    .footer-column { max-width: initial; }

    .footer-column .title-column {
        margin-top: 24px;
        margin-bottom: 0;
    }

    section#post-footer {
        display: flex;
        flex-direction: row;
        align-items: center;
        justify-content: space-evenly;
    }

    .posts-business { width: 132px; height: 33px; }
}

/* Altura auto en rangos intermedios */
@media only screen and (min-width: 495px) and (max-width: 1120px) {
    #main-footer { height: auto; }
}

@media only screen and (max-height: 760px) and (max-width: 1120px) {
    #main-footer { height: auto; }
}

/* ≥ 800 — share RRSS con sombra */
@media only screen and (min-width: 800px) {
    .bloque-share-rrss {
        display: flex;
        justify-content: space-evenly;
        filter: drop-shadow(2px 4px 2px rgb(0 0 0 / 0.15));
    }
}