/* ==========================================================================
   Modern Site Footer
   ========================================================================== */

.zc-site-footer {
    display: block;
    width: 100%;
    color: #94A3B8; /* Slate 400 */
    font-size: 14px;
    line-height: 1.5;
}

.zc-site-footer__inner {
    width: min(var(--zc-header-shell, 1480px), calc(100% - 32px));
    margin-inline: auto;
}

@media (min-width: 768px) {
    .zc-site-footer__inner {
        width: min(var(--zc-header-shell, 1480px), calc(100% - 64px));
    }
}

/* Base Links */
.zc-site-footer a {
    color: #94A3B8;
    text-decoration: none;
    transition: color 0.2s ease, outline 0.2s ease, text-decoration-color 0.2s ease;
}

.zc-site-footer a:focus-visible {
    outline: 2px solid var(--zoca-color-focus, #199ae8);
    outline-offset: 2px;
    border-radius: 2px;
}

/* Lists */
.zc-site-footer ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

/* Screen Reader Text */
.zc-site-footer .screen-reader-text {
    border: 0;
    clip: rect(1px, 1px, 1px, 1px);
    clip-path: inset(50%);
    height: 1px;
    margin: -1px;
    overflow: hidden;
    padding: 0;
    position: absolute;
    width: 1px;
    word-wrap: normal !important;
}

/* --------------------------------------------------------------------------
   Primary Service Cards Tier (Dark Cards)
   -------------------------------------------------------------------------- */
.zc-footer-service-cards {
    display: grid;
    grid-template-columns: 1fr;
    gap: var(--zoca-space-4, 16px);
    margin-bottom: var(--zoca-space-8, 32px);
    padding-bottom: var(--zoca-space-8, 32px);
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

@media (min-width: 640px) {
    .zc-footer-service-cards {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: var(--zoca-space-4, 16px);
    }
}

@media (min-width: 1024px) {
    .zc-footer-service-cards {
        grid-template-columns: repeat(4, minmax(0, 1fr));
        gap: var(--zoca-space-4, 16px);
        margin-bottom: var(--zoca-space-10, 40px);
        padding-bottom: var(--zoca-space-10, 40px);
    }
}

.zc-footer-service-card {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    padding: var(--zoca-space-4, 16px) var(--zoca-space-5, 20px);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: var(--zoca-radius-surface, 16px);
    background: rgba(255, 255, 255, 0.035);
    height: 100%;
    transition: border-color var(--zoca-transition-fast, 160ms ease),
                background-color var(--zoca-transition-fast, 160ms ease);
}

.zc-footer-service-card:hover {
    border-color: rgba(113, 200, 250, 0.22);
    background-color: rgba(255, 255, 255, 0.055);
}

.zc-footer-service-card__header {
    display: flex;
    align-items: center;
    gap: var(--zoca-space-2, 8px);
    margin-bottom: var(--zoca-space-2, 8px);
}

.zc-footer-service-card__icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: var(--zoca-color-action-on-dark, #71c8fa);
    flex-shrink: 0;
}

.zc-footer-service-card__glyph {
    display: block;
    width: 20px;
    height: 20px;
    stroke-width: 2;
    color: var(--zoca-color-action-on-dark, #71c8fa);
}

.zc-footer-service-card__title {
    color: #ffffff;
    font-size: var(--zoca-type-size-body, 15px);
    font-weight: var(--zoca-type-weight-semibold, 600);
    line-height: var(--zoca-type-leading-compact, 1.45);
    letter-spacing: -0.01em;
}

.zc-footer-service-card__body {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: var(--zoca-space-2, 8px);
    width: 100%;
    flex: 1 1 auto;
}

.zc-footer-service-card__text {
    margin: 0;
    color: #b6cad6;
    font-size: var(--zoca-type-size-supporting, 13.5px);
    line-height: var(--zoca-type-leading-body, 1.55);
}

body.zoca-modern-page .zc-footer-service-card__text a,
.zc-footer-service-card__text a {
    color: #ffffff;
    font-weight: var(--zoca-type-weight-semibold, 600);
    text-decoration: none;
}

body.zoca-modern-page .zc-footer-service-card__text a:hover,
.zc-footer-service-card__text a:hover {
    color: var(--zoca-color-action-on-dark, #71c8fa);
    text-decoration: underline;
}

body.zoca-modern-page .zc-footer-service-card__cta,
.zc-footer-service-card__cta {
    display: inline-flex;
    align-items: center;
    gap: var(--zoca-space-1, 4px);
    color: var(--zoca-color-action-on-dark, #71c8fa) !important;
    font-size: var(--zoca-type-size-supporting, 13.5px);
    font-weight: var(--zoca-type-weight-semibold, 600);
    text-decoration: none !important;
    margin-top: auto;
    padding-top: var(--zoca-space-2, 8px);
    padding-inline: 0;
    padding-bottom: 0;
    background: transparent;
    border: none;
    box-shadow: none;
    min-height: auto;
    transition: color var(--zoca-transition-fast, 160ms ease);
}

body.zoca-modern-page .zc-footer-service-card__cta:hover,
.zc-footer-service-card__cta:hover {
    color: #ffffff !important;
    text-decoration: underline !important;
    text-underline-offset: 3px;
    background: transparent;
    transform: none;
    box-shadow: none;
}

.zc-footer-service-card__cta-arrow {
    display: inline-block;
    transition: transform var(--zoca-transition-fast, 160ms ease);
}

body.zoca-modern-page .zc-footer-service-card__cta:hover .zc-footer-service-card__cta-arrow,
.zc-footer-service-card__cta:hover .zc-footer-service-card__cta-arrow {
    transform: translateX(3px);
}

/* --------------------------------------------------------------------------
   Main Footer
   -------------------------------------------------------------------------- */
.zc-site-footer__main {
    background-color: #0A1128; /* Navy 950 */
    padding-block: 32px;
    color: #94A3B8;
}

.zc-site-footer .zc-site-footer__main a,
.zc-site-footer .zc-site-footer__main a:visited {
    color: #94A3B8;
}

@media (min-width: 768px) {
    .zc-site-footer__main {
        padding-block: 40px;
    }
}

.zc-footer-main-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 40px;
}

/* Brand Anchor */
.zc-footer-logo-link {
    display: inline-block;
    margin-bottom: 24px;
}
.zc-footer-logo-link:focus-visible {
    outline-offset: 4px;
}
.zc-footer-logo-img {
    display: block;
    max-width: 112px;
    height: auto;
}

.zc-footer-address {
    font-style: normal;
    display: flex;
    flex-direction: column;
    gap: 12px;
}
.zc-footer-address__title {
    color: #FFFFFF;
    font-size: 16px;
    font-weight: 600;
    margin-bottom: 4px;
}
.zc-footer-address__item {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    line-height: 1.4;
}
.zc-footer-address__icon {
    flex-shrink: 0;
    color: #64748B; /* Slate 500 / Muted blue-grey */
    margin-top: 2px;
}
.zc-footer-address__text {
    color: #CBD5E1; /* Slate 300 */
    font-size: 14px;
}
.zc-footer-address__link {
    color: #94A3B8; /* Slate 400 */
    font-size: 14px;
}
.zc-footer-address__link:hover {
    color: #FFFFFF;
    text-decoration: underline;
}

/* Compact profile links shared with the About page. */
.zc-social-links {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 8px;
}
.zc-social-link {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    min-height: 40px;
    padding: 8px 11px;
    border-radius: 10px;
    font-size: 13px;
    font-weight: 600;
    line-height: 1.2;
    white-space: nowrap;
    transition: color .16s ease, background-color .16s ease, border-color .16s ease;
}
.zc-social-link svg { display: block; flex: none; }
.zc-social-link:focus-visible {
    outline: 2px solid var(--zoca-color-focus, #199ae8);
    outline-offset: 2px;
}
.zc-footer-social { margin-top: 20px; }
.zc-footer-social__title {
    margin: 0 0 7px;
    color: #fff;
    font-size: 14px;
    font-weight: 600;
}
.zc-site-footer .zc-footer-social .zc-social-link,
.zc-site-footer .zc-footer-social .zc-social-link:visited {
    color: #cbd5e1;
    background: rgba(255,255,255,.055);
    border: 1px solid rgba(255,255,255,.12);
}
.zc-site-footer .zc-footer-social .zc-social-link:hover {
    color: #fff;
    background: rgba(113,200,250,.13);
    border-color: rgba(113,200,250,.45);
}
.zc-about-social {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 12px 20px;
    margin-top: 28px;
    padding: 20px 0 0;
    border-top: 1px solid #dbe3ea;
}
.zc-content-page__prose .zc-about-social__title {
    margin: 0 0 3px;
    color: var(--zoca-color-navy-950, #0a1128);
    font-size: 17px;
    font-weight: 600;
}
.zc-content-page__prose .zc-about-social__text {
    margin: 0;
    color: var(--zoca-color-text-secondary, #475569);
    font-size: 14px;
}
.zc-content-page__prose .zc-about-social .zc-social-link {
    color: var(--zoca-color-navy-800, #1e293b);
    text-decoration: none;
    background: #f4f8fb;
    border: 1px solid #dbe3ea;
}
.zc-content-page__prose .zc-about-social .zc-social-link:hover {
    color: var(--zoca-color-action, #087cc2);
    background: #eaf5fc;
    border-color: #91ccef;
}

/* Columns */
.zc-site-footer .zc-footer-col-title {
    color: #FFFFFF !important;
    font-size: 16px;
    font-weight: 600;
    margin-top: 0;
    margin-bottom: 24px;
    display: block; /* Shown by default */
}

/* Mobile Accordions */
.zc-footer-accordion-toggle {
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 100%;
    background: transparent;
    border: none;
    border-bottom: 1px solid rgba(255,255,255,0.1);
    padding: 16px 0;
    color: #FFFFFF;
    font-size: 16px;
    font-weight: 600;
    text-align: left;
    cursor: pointer;
    font-family: inherit;
    transition: color 0.2s;
}

.zc-footer-accordion-toggle:focus-visible {
    outline: 2px solid var(--zoca-color-focus);
    outline-offset: -2px;
}

.zc-footer-chevron {
    transition: transform 0.3s ease;
}

/* JS Enhanced Mobile State */
.zc-accordions-enabled .zc-site-footer .zc-footer-col-title {
    display: none; /* Hide headings if JS is enabled on mobile */
}

.zc-accordions-enabled .zc-site-footer .zc-footer-accordion-toggle {
    display: flex !important;
}

.zc-accordions-enabled .zc-footer-nav {
    display: none; /* Base display none, handled by hidden property in JS */
    padding-bottom: 16px;
}

/* Let the hidden attribute on panels handle visibility, fallback for pure CSS */
.zc-accordions-enabled .zc-footer-nav:not([hidden]) {
    display: flex;
}

.zc-accordions-enabled .zc-footer-accordion-toggle[aria-expanded="true"] .zc-footer-chevron {
    transform: rotate(180deg);
}

/* No-JS Mobile State */
.zc-site-footer .zc-footer-accordion-toggle {
    display: none !important; /* Hide toggle button without JS */
}

.zc-footer-nav {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.zc-footer-nav a {
    display: inline-block;
    padding-block: 4px; /* Better touch target */
}
.zc-footer-nav a:hover {
    color: #FFFFFF;
    text-decoration: underline;
    text-decoration-color: var(--zoca-color-action);
    text-underline-offset: 4px;
}

/* Tablet Layout (2x2) */
@media (min-width: 768px) and (max-width: 1023px) {
    .zc-footer-main-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    .zc-footer-col--brand {
        grid-column: span 2;
        margin-bottom: 16px;
    }
    /* Disable accordions on tablet */
    .zc-accordions-enabled .zc-site-footer .zc-footer-accordion-toggle {
        display: none !important;
    }
    .zc-accordions-enabled .zc-footer-nav {
        display: flex;
    }
    .zc-accordions-enabled .zc-footer-col-title {
        display: block;
    }
}

/* Desktop Layout (Asymmetric) */
@media (min-width: 1024px) {
    .zc-footer-main-grid {
        grid-template-columns: repeat(12, 1fr);
        gap: 32px;
    }
    .zc-footer-col--brand {
        grid-column: span 4;
    }
    .zc-footer-col--comprar {
        grid-column: span 2;
    }
    .zc-footer-col--ayuda {
        grid-column: span 3;
    }
    .zc-footer-col--sobre {
        grid-column: span 3;
    }

    /* Disable accordions */
    .zc-site-footer .zc-footer-accordion-toggle {
        display: none !important;
    }
    .zc-accordions-enabled .zc-footer-col-title {
        display: block;
    }
    .zc-accordions-enabled .zc-footer-nav {
        display: flex;
        padding-bottom: 0;
    }
}

/* --------------------------------------------------------------------------
   Lower Utility Bar
   -------------------------------------------------------------------------- */
.zc-site-footer__bottom {
    background-color: #060A17; /* Navy 990 */
    padding-block: 24px;
    color: #94A3B8;
}

.zc-footer-bottom-grid {
    display: flex;
    flex-wrap: wrap;
    gap: 24px;
    align-items: center;
    justify-content: center;
    text-align: center;
}

.zc-footer-copyright {
    flex: 1 1 100%;
}

.zc-footer-legal-nav {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 16px;
    flex: 1 1 100%;
}

.zc-footer-legal-nav a {
    font-size: 13px;
    white-space: nowrap;
}

.zc-footer-payments {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 12px;
    flex: 1 1 100%;
}

.zc-payment-list {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
    justify-content: center;
    align-items: center;
}

.zc-payment-tile {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background-color: #FFFFFF;
    border-radius: 4px;
    height: 30px;
    padding-inline: 8px;
}

.zc-payment-tile img {
    display: block;
    max-height: 18px;
    width: auto;
}

@media (min-width: 1024px) {
    .zc-footer-bottom-grid {
        justify-content: space-between;
        text-align: left;
        flex-wrap: nowrap;
    }
    .zc-footer-copyright {
        flex: 0 1 auto;
        white-space: nowrap;
    }
    .zc-footer-legal-nav {
        flex: 1 1 auto;
        justify-content: center;
        gap: 24px;
    }
    .zc-footer-payments {
        flex: 0 1 auto;
        flex-direction: row;
    }
}

/* Reduced Motion */
@media (prefers-reduced-motion: reduce) {
    .zc-site-footer a,
    .zc-footer-accordion-toggle,
    .zc-footer-chevron {
        transition: none !important;
    }
}
