body {
    background-color: #ffcb06;
    font-family: "Ubuntu", helvetica;
    margin: 0;
    /* Eliminamos padding general para que escritorio quede igual */
}

/* ===== PESTAÑA SUPERIOR ===== */
.tab {
    background-color: rgba(168, 168, 168, 0.863);
    width: 560px; /* Restauramos el ancho fijo para escritorio */
    border-radius: 5px;
    margin: 10px auto 0;
    padding: 10px 0;
    box-shadow: 0 4px 10px 4px rgba(19, 35, 47, 0.3);
    color: black;
}

.tab h3 {
    text-align: center;
    opacity: 1;
    margin: 0;
    padding: 0;
    font-size: 16px; /* Tamaño original restaurado */
}

/* ===== CONTENIDO PRINCIPAL ===== */
.contenido-tab {
    background-color: #f5f5f5;
    width: 500px; /* Ancho fijo original restaurado */
    height: 450px; /* Alto fijo original restaurado */
    padding: 30px;
    margin: -2px auto 0;
    border-radius: 20px;
    border-top-left-radius: 0;
    border-top-right-radius: 0;
    box-shadow: 0 4px 10px 4px rgba(19, 35, 47, 0.3);
}

/* ===== LOGO ===== */
.abracol {
    height: 50px;
    position: relative;
    margin-left: 160px; /* Restauramos la posición original */
    margin-top: 1px;
    margin-bottom: 10px;
}

/* ===== ICONO DE LOGIN ===== */
.icon-login {
    height: 80px;
    position: relative;
    margin-left: 200px; /* Restauramos la posición original */
}

/* ===== TÍTULOS ===== */
h1 {
    text-align: center;
    font-size: 19px; /* Tamaño original */
    margin: 10px 0;
}

h3 {
    text-align: center;
    opacity: 0.5;
    margin-top: -16px; /* Restauramos margen original */
    margin-bottom: 0;
    font-size: 14px; /* Tamaño original */
}

/* ===== FORMULARIO ===== */
.contenedor-input {
    position: relative;
    margin-bottom: 40px; /* Margen original */
}

label {
    position: absolute;
    transform: translateY(6px);
    left: 13px;
    color: black;
    transition: all 0.1s ease;
    pointer-events: none;
    font-size: 20px; /* Tamaño original */
}

label .req {
    margin: 2px;
    color: #1ab188;
}

label.active {
    transform: translateY(-20px);
    left: 2px;
    font-size: 14px; /* Tamaño original */
    color: rgba(0, 0, 0, 0.5);
}

label.highlight {
    color: #1ab188;
}

input {
    font-size: 22px; /* Tamaño original */
    display: block;
    width: 100%;
    padding: 5px 10px;
    background: none;
    border: 1px solid #a0b3b0;
    border-top: none;
    border-left: none;
    border-right: none;
    color: black;
    border-radius: 5px;
    transition: all 0.5s ease;
}

input:focus {
    outline: none;
    border-color: #1ab188;
}

/* ===== BOTÓN DE MOSTRAR CONTRASEÑA ===== */
.password-toggle {
    position: absolute;
    top: 50%;
    right: 10px;
    transform: translateY(-50%);
    cursor: pointer;
    z-index: 10;
    color: black;
    font-size: 1.2rem;
    transition: color 0.3s ease;
}

.password-toggle:hover {
    color: #169371;
}

/* ===== BOTÓN PRINCIPAL ===== */
.button {
    border: 0;
    border-radius: 5px;
    cursor: pointer;
    padding: 15px;
    font-size: 15px; /* Tamaño original */
    background: black;
    color: #fff;
    display: block;
    width: 150px; /* Ancho original */
    margin: 50px auto 0; /* Margen original */
    transition: background-color 0.3s ease;
}

.button:hover,
.button:focus {
    background-color: cyan;
}

/* ===== OCULTAR ELEMENTOS DE AUTOFILL ===== */
::-ms-reveal,
::-webkit-contacts-auto-fill-button,
::-webkit-search-cancel-button {
    display: none !important;
    -webkit-appearance: none !important;
    appearance: none !important;
}

/* ==========================================
   📱 SOLO PARA MÓVILES - MEDIA QUERIES
   ========================================== */

/* Para tablets y móviles */
@media screen and (max-width: 768px) {
    body {
        padding: 20px 10px;
        display: flex;
        flex-direction: column;
        justify-content: center;
        min-height: 100vh;
        box-sizing: border-box;
    }

    /* La pestaña se adapta */
    .tab {
        width: 90%;
        max-width: 560px;
    }

    .tab h3 {
        font-size: clamp(14px, 4vw, 16px);
        padding: 0 10px;
    }

    /* El contenido se adapta */
    .contenido-tab {
        width: 90%;
        max-width: 500px;
        height: auto;
        min-height: 450px;
        padding: 30px 20px;
        box-sizing: border-box;
    }

    /* Imágenes centradas en móvil */
    .abracol,
    .icon-login {
        position: static;
        margin: 0 auto 20px;
        display: block;
    }

    .abracol {
        height: 40px;
    }

    .icon-login {
        height: 60px;
    }

    /* Ajustes de texto */
    h1 {
        font-size: clamp(18px, 5vw, 19px);
    }

    h3 {
        margin: -10px 0 20px;
        font-size: clamp(12px, 3.5vw, 14px);
    }

    /* Formulario */
    .contenedor-input {
        margin-bottom: 30px;
    }

    label {
        font-size: clamp(16px, 4vw, 20px);
    }

    label.active {
        font-size: clamp(12px, 3vw, 14px);
    }

    input {
        font-size: clamp(16px, 4vw, 22px);
        box-sizing: border-box;
    }

    /* Botón */
    .button {
        width: 80%;
        max-width: 150px;
        font-size: clamp(14px, 4vw, 15px);
        margin-top: 30px;
    }
}

/* Para móviles muy pequeños */
@media screen and (max-width: 480px) {
    .contenido-tab {
        padding: 20px 15px;
    }

    .contenedor-input {
        margin-bottom: 25px;
    }

    .button {
        padding: 12px;
    }

    .password-toggle {
        right: 5px;
        font-size: 1rem;
    }
}