/* ─── Download Buttons ─── */

/* Buttons - Fallbacks para CSS3 */
.btn-download {
    width: 100%;
    /* Fallback para clamp() */
    padding: 20px 26px;
    font-family: 'minecraft_seven_v2', cursive;
    font-size: 1rem;
    border: none;
    cursor: pointer;
    position: relative;
    display: -webkit-box;
    display: -ms-flexbox;
    display: flex;
    -webkit-box-align: center;
    -ms-flex-align: center;
    align-items: center;
    -webkit-box-pack: center;
    -ms-flex-pack: center;
    justify-content: center;
    /* Fallback para gap con margin en hijos */
    -webkit-transition: all 0.2s ease;
    transition: all 0.2s ease;
    -webkit-box-shadow: 0 4px 0 rgba(0, 0, 0, 0.5);
    box-shadow: 0 4px 0 rgba(0, 0, 0, 0.5);
}

/* Fallback para gap en flexbox */
.btn-download > * {
    margin-left: 6px;
    margin-right: 6px;
}

.btn-download > *:first-child {
    margin-left: 0;
}

.btn-download > *:last-child {
    margin-right: 0;
}

@supports (font-size: clamp(1rem, 2vw, 3rem)) {
    .btn-download {
        padding: clamp(16px, 3vw, 24px) clamp(20px, 4vw, 32px);
        font-size: clamp(0.9rem, 2vw, 1.2rem);
    }
}

@supports (gap: 12px) {
    .btn-download {
        gap: 12px;
    }
    
    .btn-download > * {
        margin-left: 0;
        margin-right: 0;
    }
}

.btn-download:hover {
    -webkit-transform: translate(2px, 2px);
    transform: translate(2px, 2px);
    -webkit-box-shadow: 0 2px 0 rgba(0, 0, 0, 0.5);
    box-shadow: 0 2px 0 rgba(0, 0, 0, 0.5);
}

.btn-download:active {
    -webkit-transform: translate(4px, 4px);
    transform: translate(4px, 4px);
    -webkit-box-shadow: 0 0 0 rgba(0, 0, 0, 0.5);
    box-shadow: 0 0 0 rgba(0, 0, 0, 0.5);
}

.btn-green {
    background-color: #3C8527;
    border-top: 7px solid #52A535;
    border-bottom: 7px solid #2A641C;
    border-left: none;
    border-right: none;
    color: #fff;
}

.btn-green:hover {
    background-color: #469a2e;
}

.btn-green:active {
    background-color: #2f6b1f;
}

.btn-orange {
    background-color: #f0ad4e;
    border-top: 5px solid #f5bd68;
    border-bottom: 5px solid #d89442;
    border-left: none;
    border-right: none;
    color: #fff;
}

.btn-orange:hover {
    background-color: #f5bd68;
}

.btn-cyan {
    background-color: #5bc0de;
    border-top: 5px solid #6ccfe8;
    border-bottom: 5px solid #46a8c5;
    border-left: none;
    border-right: none;
    color: #fff;
}

.btn-cyan:hover {
    background-color: #6ccfe8;
}

.btn-orange:active {
    background-color: #c8872e;
}

.btn-cyan:active {
    background-color: #3a96b2;
}

/* Focus accesibilidad — Fallback CSS3 con :focus */
.btn-download:focus {
    outline: 3px solid #fff;
    outline-offset: 2px;
}

/* Mejora progresiva: ocultar outline en clicks de mouse */
.btn-download:focus:not(:focus-visible) {
    outline: none;
}

.btn-download:focus-visible {
    outline: 3px solid #fff;
    outline-offset: 2px;
}

.arrow {
    font-size: 1.5em;
    line-height: 1;
}

/* ─── Responsive ─── */
@media (max-width: 768px) {
    .btn-download {
        padding: 12px 16px;
        font-size: 0.85rem;
    }

    .btn-green {
        border-top-width: 4px;
        border-bottom-width: 4px;
    }
}

@media (max-width: 480px) {
    .btn-download {
        padding: 10px 12px;
        font-size: 0.75rem;
        min-height: 44px;
    }

    .btn-green {
        border-top-width: 3px;
        border-bottom-width: 3px;
    }
}

/* Botones compactos para pantallas apaisadas y de poca altura. */
@media (max-height: 540px) and (min-width: 769px) and (max-width: 960px) {
    .btn-download {
        min-height: 0;
        padding: 6px 8px;
        font-size: 0.62rem;
    }

    .btn-green {
        border-top-width: 3px;
        border-bottom-width: 3px;
    }
}
