/* style.css */

@font-face {
    font-family: 'AceSans';
    src: url('./assets/AceSans-FREE.otf') format('opentype');
    font-weight: normal;
    font-style: normal;
}

:root {
    --brand-yellow: #F2CA50; /* Amarillo/dorado */
    --content-box-bg: rgba(231, 231, 231, 0.20); /* #E7E7E7 con 20% opacidad */
    --timer-label-text: rgba(255, 255, 255, 0.85);
    --placeholder-text-on-light-panel: rgba(0, 0, 0, 0.4);
    --input-text-on-light-panel: #333333;
    --button-text-on-yellow: #3A2E0A;
    --body-bg-fallback: #333333;
    --font-title: 'AceSans', 'Poppins', sans-serif;
    --font-body: 'Poppins', sans-serif;
    --form-pill-radius: 30px;
    --form-border-width: 1.5px; /* Grosor del borde del formulario */
}

body, html {
    margin: 0;
    padding: 0;
    height: 100%;
    font-family: var(--font-body);
    background-color: var(--body-bg-fallback);
    line-height: 1.6;
    color: #FFFFFF;
}

.background-container {
    width: 100%;
    min-height: 100vh;
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    opacity: 0.85; /* Ajusta según el contraste de tu imagen de fondo */
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    padding: 20px;
    box-sizing: border-box;
    position: relative;
}

.content-box {
    position: relative;
    z-index: 1;
    background-color: var(--content-box-bg);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    padding: clamp(30px, 6vw, 50px);
    border-radius: 15px;
    border: none; /* Sin borde para el content-box */
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.15);
    text-align: center;
    max-width: 620px;
    width: 90%;
}

.main-title {
    font-family: var(--font-title);
    font-size: clamp(1.8rem, 5vw, 2.6rem);
    font-weight: normal;
    color: var(--brand-yellow);
    margin-top: 0;
    margin-bottom: 30px;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    line-height: 1.2;
}

.countdown-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: clamp(15px, 3vw, 25px);
    margin-bottom: 35px;
}

.timer-item {
    display: flex;
    flex-direction: column;
    align-items: center;
}

.timer-value {
    font-family: var(--font-body);
    font-size: clamp(2.2rem, 7vw, 3.2rem);
    font-weight: 500;
    color: var(--brand-yellow);
    width: clamp(65px, 15vw, 80px);
    height: clamp(65px, 15vw, 80px);
    border: 2px solid rgba(255, 255, 255, 0.9);
    border-radius: 50%;
    display: flex;
    justify-content: center;
    align-items: center;
    margin-bottom: 8px;
}

.timer-label {
    font-size: clamp(0.75rem, 2.5vw, 0.9rem);
    font-weight: 400;
    color: var(--timer-label-text);
    text-transform: uppercase;
    letter-spacing: 0.1em;
}

.subscribe-prompt {
    font-family: var(--font-title);
    font-size: clamp(1rem, 3.5vw, 1.2rem);
    font-weight: normal;
    color: var(--brand-yellow);
    margin-bottom: 25px;
    line-height: 1.4;
}

/* --- ESTILOS DEL FORMULARIO (INPUT Y BOTÓN UNIDOS VISUALMENTE) --- */
.subscribe-form {
    display: flex; /* Para alinear input y botón */
    align-items: stretch; /* Para que tengan la misma altura */
    max-width: 480px;
    margin-left: auto;
    margin-right: auto;
    margin-bottom: 20px;
    /* No hay 'gap' para que estén juntos */
}

.email-input {
    flex-grow: 1;
    padding: 12px 20px;
    font-size: clamp(0.9rem, 2.5vw, 1rem);
    color: var(--input-text-on-light-panel);
    background-color: rgba(255, 255, 255, 0.35);

    border: var(--form-border-width) solid var(--brand-yellow);
    border-right: none; /* Crucial para la unión */

    border-top-left-radius: var(--form-pill-radius);
    border-bottom-left-radius: var(--form-pill-radius);
    border-top-right-radius: 0;
    border-bottom-right-radius: 0;

    outline: none;
    transition: background-color 0.3s, border-color 0.3s;
    position: relative;
    z-index: 1; /* Detrás del botón en la superposición */
}

.email-input::placeholder {
    color: var(--placeholder-text-on-light-panel);
    opacity: 1;
}

.email-input:focus {
    background-color: rgba(255, 255, 255, 0.5);
}

.subscribe-button {
    padding: 12px 25px;
    font-family: var(--font-title); /* Fuente AceSans */
    font-size: clamp(0.9rem, 2.5vw, 1rem);
    font-weight: normal; /* AceSans podría tener solo un peso */
    color: var(--button-text-on-yellow);
    background-color: var(--brand-yellow); /* Fondo amarillo */

    border-top: var(--form-border-width) solid var(--brand-yellow);
    border-bottom: var(--form-border-width) solid var(--brand-yellow);
    border-right: var(--form-border-width) solid var(--brand-yellow);
    border-left: none; /* Crucial para la unión */

    border-top-right-radius: var(--form-pill-radius);
    border-bottom-right-radius: var(--form-pill-radius);
    border-top-left-radius: 0;
    border-bottom-left-radius: 0;

    cursor: pointer;
    text-transform: uppercase;
    letter-spacing: 0.03em;
    transition: background-color 0.3s, transform 0.1s;
    white-space: nowrap;

    margin-left: calc(-1 * var(--form-border-width)); /* Superpone el botón sobre el espacio del borde */
    position: relative;
    z-index: 2; /* Encima del input en la superposición */
}
/* --- FIN DE ESTILOS DEL FORMULARIO --- */

.subscribe-button:hover {
    background-color: #dbc041;
}
.subscribe-button:active {
    transform: scale(0.96);
}

.form-message-style {
    font-size: 0.9rem;
    min-height: 1.2em;
    font-weight: 500;
}

.logo-container {
    position: absolute;
    bottom: 30px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 10;
}

.footer-logo {
    width: clamp(70px, 15vw, 90px);
    height: auto;
    opacity: 0.9;
    filter: brightness(0) invert(1); /* Para hacerlo blanco */
}

/* Media Queries (Ajuste para el formulario apilado) */
@media (max-width: 600px) {
    .content-box {
        padding: clamp(20px, 5vw, 30px) clamp(15px, 4vw, 25px);
    }

    .subscribe-form {
        flex-direction: column; /* Apilar input y botón */
        gap: 10px;  /* Espacio entre input y botón en móvil */
    }

    .email-input {
        width: 100%;
        box-sizing: border-box;
        border-radius: var(--form-pill-radius); /* Radio completo en móvil */
        border-right: var(--form-border-width) solid var(--brand-yellow); /* Borde derecho restaurado */
    }

    .subscribe-button {
        width: 100%;
        box-sizing: border-box;
        border-radius: var(--form-pill-radius); /* Radio completo en móvil */
        border: var(--form-border-width) solid var(--brand-yellow); /* Borde completo para el botón */
        margin-left: 0; /* Resetear el margen negativo */
    }

    .logo-container {
        bottom: 20px;
    }
    .footer-logo {
        width: clamp(60px, 18vw, 75px);
    }
}

