/* CSS Reset */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
}

body {
    background-color: #eaf6f9;
    min-height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
    color: #0b192c;
    position: relative;
    padding: 20px;
}

/* Isolated background container: traps the floating circles so they
   never affect the document's layout or scroll size */
.background-anim-container {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    overflow: hidden;
    z-index: -1;
    pointer-events: none;
}

.bg-circle {
    position: absolute;
    border-radius: 50%;
    background: linear-gradient(135deg, rgba(74, 193, 240, 0.2), rgba(3, 15, 38, 0.05));
    animation: float 12s infinite ease-in-out alternate;
}

.circle-1 {
    width: 350px;
    height: 350px;
    top: -5%;
    left: -5%;
    animation-duration: 14s;
}

.circle-2 {
    width: 200px;
    height: 200px;
    bottom: 10%;
    left: 15%;
    animation-duration: 10s;
    animation-delay: 1s;
}

.circle-3 {
    width: 500px;
    height: 500px;
    bottom: -15%;
    right: -10%;
    animation-duration: 18s;
}

.circle-4 {
    width: 120px;
    height: 120px;
    top: 15%;
    right: 20%;
    animation-duration: 8s;
    animation-delay: 2s;
}

/* Sweeping floating effect: adds X and Y movement, not just Y */
@keyframes float {
    0% {
        transform: translate(0px, 0px) scale(1);
    }
    100% {
        transform: translate(50px, -80px) scale(1.1);
    }
}

.login-card {
    display: flex;
    flex-direction: column;
    width: 100%;
    max-width: 900px;
    background-color: #ffffff;
    border-radius: 30px;
    box-shadow: 0 25px 50px rgba(3, 15, 38, 0.15);
    overflow: hidden;
    z-index: 10;
    position: relative;
}

.info-panel {
    background-color: #030f26;
    color: white;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    padding: 50px 30px;
    text-align: center;
}

.info-panel .etas-logo {
    width: 130px;
    height: 130px;
    margin-bottom: 20px;
    object-fit: contain;
    border-radius: 28px;
}

.info-panel h2 {
    color: #4ac1f0;
    font-size: 30px;
    margin-bottom: 10px;
}

.form-panel {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    padding: 50px 30px;
    background-color: #ffffff;
    position: relative;
}

.form-wrapper {
    width: 100%;
    max-width: 350px;
}

.form-wrapper h1 {
    color: #4ac1f0;
    font-size: 26px;
    margin-bottom: 10px;
    text-align: center;
}

.form-wrapper p.sub-text {
    text-align: center;
    font-size: 14px;
    color: #64748b;
    margin-bottom: 30px;
}

.input-group {
    margin-bottom: 25px;
    position: relative;
}

.input-group input {
    width: 100%;
    padding: 16px 20px;
    border: 2px solid #e0eff5;
    border-radius: 12px;
    background-color: transparent;
    font-size: 15px;
    color: #0b192c;
    transition: border-color 0.3s ease;
}

.input-group input:focus {
    outline: none;
    border-color: #4ac1f0;
}

.input-group label {
    position: absolute;
    top: 17px;
    left: 20px;
    background-color: #ffffff;
    padding: 0 5px;
    font-size: 15px;
    color: #64748b;
    pointer-events: none;
    transition: all 0.3s ease;
    border-radius: 4px;
}

.input-group input:focus ~ label,
.input-group input:valid ~ label {
    top: -10px;
    left: 15px;
    font-size: 12px;
    color: #4ac1f0;
    font-weight: 600;
}

/* --- PASSWORD VISIBILITY TOGGLE --- */
.toggle-password {
    position: absolute;
    right: 15px;
    top: 15px;
    cursor: pointer;
    color: #64748b;
    transition: color 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
}

.toggle-password:hover {
    color: #4ac1f0;
}

.toggle-password svg {
    width: 20px;
    height: 20px;
    fill: none;
    stroke: currentColor;
    stroke-width: 2;
    stroke-linecap: round;
    stroke-linejoin: round;
}

/* --- MFA 6-DIGIT OTP STYLE --- */
.otp-container {
    display: flex;
    justify-content: space-between;
    gap: 10px;
    margin-bottom: 30px;
}

.otp-container input {
    width: 45px;
    height: 55px;
    border: 2px solid #e0eff5;
    border-radius: 10px;
    text-align: center;
    font-size: 22px;
    font-weight: 700;
    color: #0b192c;
    transition: all 0.3s ease;
}

.otp-container input:focus {
    outline: none;
    border-color: #4ac1f0;
    box-shadow: 0 4px 10px rgba(74, 193, 240, 0.15);
}

/* --- UTILITY / ERROR / SUCCESS --- */
.options {
    display: flex;
    justify-content: flex-end;
    align-items: center;
    font-size: 13px;
    margin-bottom: 30px;
}

.options a {
    color: #4ac1f0;
    text-decoration: none;
    font-weight: 600;
}

.options a:hover {
    text-decoration: underline;
}

.back-link {
    text-align: center;
    margin-top: 20px;
}

.back-link a {
    color: #4ac1f0;
    text-decoration: none;
    font-size: 13px;
    font-weight: 600;
}

button.login-btn {
    width: 100%;
    padding: 16px;
    border-radius: 12px;
    border: none;
    background-color: #030f26;
    color: white;
    font-size: 16px;
    font-weight: 700;
    cursor: pointer;
    transition: background-color 0.3s, opacity 0.3s;
}

button.login-btn:hover {
    background-color: #06193d;
}

button.login-btn:disabled {
    background-color: #94a3b8;
    cursor: not-allowed;
    opacity: 0.8;
}

.success-message {
    background-color: #e6f7ec;
    color: #2e7d32;
    border: 1px solid #81c784;
    padding: 12px;
    border-radius: 10px;
    font-size: 13px;
    font-weight: 600;
    text-align: center;
    margin-bottom: 25px;
}

.error-message {
    background-color: #fdecea;
    color: #b3261e;
    border: 1px solid #f5c6c3;
    border-radius: 8px;
    padding: 10px 15px;
    font-size: 13px;
    font-weight: 600;
    text-align: center;
    margin-bottom: 25px;
}

.mobile-message {
    background-color: #e8f6fc;
    color: #087ea4;
    border: 1px solid #8dcfec;
    border-radius: 8px;
    padding: 10px 15px;
    font-size: 13px;
    font-weight: 600;
    text-align: center;
    margin-bottom: 25px;
}

.hidden {
    display: none !important;
}

.fade-in {
    animation: fadeIn 0.4s ease forwards;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* --- DESKTOP / LAPTOP LAYOUT --- */
@media (min-width: 900px) {
    .login-card {
        flex-direction: row;
        min-height: 550px;
    }

    .info-panel {
        flex: 1;
        border-top-right-radius: 80px;
        border-bottom-right-radius: 80px;
        box-shadow: 15px 0 30px rgba(0, 0, 0, 0.08);
        z-index: 2;
    }

    .form-panel {
        flex: 1.2;
        padding: 60px;
    }
}
