/* ===========================
    Google Font
=========================== */
@import url('https://fonts.googleapis.com/css2?family=Poppins:wght@400;500;600;700&display=swap');

/* ===========================
    Variables
=========================== */
:root{
    --navy:#2F4156;
    --teal:#567C8D;
    --sky:#C8D9E6;
    --beige:#F5EFEB;
    --white:#FFFFFF;
    --border:#D9D9D9;
    --shadow:0 12px 35px rgba(47,65,86,.12);
}

/* ===========================
    Reset
=========================== */
*{
    margin:0;
    padding:0;
    box-sizing:border-box;
}


/* ===========================
    Body
=========================== */
body{
    font-family:'Poppins',sans-serif;
    background:linear-gradient(
        135deg,
        var(--sky),
        var(--beige)
    );
    min-height:100vh;
    display:flex;
    justify-content:center;
    align-items:center;
    padding:24px;
}


/* ===========================
    Container
=========================== */
.auth-container{
    width:100%;
    display:flex;
    justify-content:center;
    align-items:center;
}


/* ===========================
    Card
=========================== */
.auth-card{
    width:100%;
    max-width:460px;
    background:var(--white);
    border-radius:14px;
    padding:28px 30px;
    box-shadow:var(--shadow);
}

/* ===========================
    Header
=========================== */
.auth-header{
    text-align:center;
    margin-bottom:22px;
}

.auth-logo{
    width:112px;
    height:112px;
    object-fit:contain;
}

.auth-brand{display:flex;align-items:center;justify-content:center;margin-bottom:12px}

.logo-text{
    font-size:34px;
    font-weight:700;
    color:var(--navy);
    margin-bottom:15px;
}

.auth-header h1{
    font-size:24px;
    color:var(--navy);
    line-height:1.3;
    margin-bottom:6px;
}

.auth-header p{
    color:#666;
    font-size:14px;
    line-height:1.5;
}

/* ===========================
    Inputs
=========================== */

.input-group{
    margin-bottom:15px;
}

.input-group label{
    display:block;
    margin-bottom:6px;
    color:var(--navy);
    font-weight:500;
    font-size:14px;
}

.input-group input,
.input-group select{
    width:100%;
    padding:10px 12px;
    border:1px solid var(--border);
    border-radius:8px;
    outline:none;
    font-size:14px;
    transition:.3s;
    font-family:Poppins;
}

.input-group input:focus,
.input-group select:focus{
    border-color:var(--teal);
    box-shadow:0 0 0 4px rgba(86,124,141,.12);
}

/* ===========================
   Buttons
=========================== */
.login-btn{
    width:100%;
    border:none;
    border-radius:8px;
    padding:11px;
    background:var(--teal);
    color:white;
    font-size:15px;
    font-weight:600;
    font-family:Poppins;
    cursor:pointer;
    transition:.3s;
    text-decoration:none;
    display:flex;
    justify-content:center;
    align-items:center;
}

.login-btn:hover{
    background:var(--navy);
}

/* ===========================
   Footer
=========================== */
.auth-footer{
    margin-top:20px;
    text-align:center;
    font-size:14px;
}

.auth-footer p{
    margin-bottom:10px;
}

.auth-footer a{
    color:var(--teal);
    text-decoration:none;
    font-weight:600;
}

.auth-footer a:hover{
    text-decoration:underline;
}

.guest-link{
    display:inline-block;
    margin-top:6px;
}

/* ===========================
    Login Options
=========================== */
.login-options{
    display:flex;
    justify-content:space-between;
    align-items:center;
    margin-bottom:16px;
    font-size:13px;
}

.login-options a{
    text-decoration:none;
    color:var(--teal);
}

.login-options a:hover{
    text-decoration:underline;
}

/* ===========================
    Password
=========================== */
.password-wrapper{
    position:relative;
}

.password-wrapper input{
    padding-right:50px;
}

.password-wrapper i{
    position:absolute;
    right:18px;
    top:50%;
    transform:translateY(-50%);
    cursor:pointer;
    color:#777;
}

/* ===========================
   Register Layout
=========================== */
.register-card{
    max-width:820px;
    padding:28px 32px;
}

.form-section{
    margin-top:24px;
}

.form-section:first-of-type{
    margin-top:0;
}

.form-section h3{
    color:var(--navy);
    font-size:16px;
    font-weight:600;
    margin-bottom:12px;
    padding-bottom:6px;
    border-bottom:2px solid var(--sky);
}

.form-grid{
    display:grid;
    grid-template-columns:repeat(auto-fit,minmax(210px,1fr));
    gap:14px;
}

/* ===========================
    Phone Number
=========================== */

.phone-input{
    display:flex;
    align-items:center;
    border:1px solid var(--border);
    border-radius:10px;
    overflow:hidden;
    background:white;
    transition:.3s;
}

.phone-input:focus-within{
    border-color:var(--teal);
    box-shadow:0 0 0 4px rgba(86,124,141,.12);
}

.phone-input span{
    padding:10px 12px;
    background:var(--beige);
    color:var(--navy);
    font-weight:600;
    border-right:1px solid var(--border);
}

.phone-input input{
    border:none !important;
    box-shadow:none !important;
    outline:none;
}

.terms{
    margin-top:25px;
    margin-bottom:25px;
}

.terms label{
    display:flex;
    align-items:center;
    gap:10px;
}

/* ===========================
    Password Strength
=========================== */

.password-strength{
    margin-top:12px;
    width:100%;
    height:8px;
    background:#e5e5e5;
    border-radius:30px;
    overflow:hidden;
}

#strengthBar{
    width:0;
    height:100%;
    transition:.35s;
    background:#dc3545;
}

#strengthText{
    display:block;
    margin-top:8px;
    color:#666;
    font-size:13px;
}

/* ===========================
    Terms
=========================== */
.terms{
    margin:20px 0;
}

.terms label{
    display:flex;
    align-items:flex-start;
    gap:9px;
    line-height:1.45;
    cursor:pointer;
    font-size:13px;
}

.terms input{
    margin-top:3px;
}

/* ===========================
    Validation
=========================== */

.success-message{
    color:#198754;
    font-size:13px;
    margin-top:8px;
}

.error-message{
    color:#dc3545;
    font-size:13px;
    margin-top:8px;
}


/* ===========================
    Responsive
=========================== */
@media(max-width:900px){

    body{
        padding:20px;
    }

    .register-card{
        max-width:100%;
        padding:26px;
    }
}

@media(max-width:600px){
    body{
        padding:15px;
    }

    .auth-card{
        padding:22px;
    }

    .auth-logo{
        width:96px;
        height:96px;
    }

    .auth-header h1{
        font-size:20px;
    }

    .form-grid{
        grid-template-columns:1fr;
    }

    .login-options{
        flex-direction:column;
        align-items:flex-start;
        gap:12px;
    }
}

.alert{
    padding:14px;
    border-radius:10px;
    margin-bottom:20px;
    font-size:14px;
}

.alert.error{
    background:#ffe8e8;
    color:#c62828;
    border:1px solid #ef9a9a;
}

.alert.success{
    background:#e9f7ef;
    color:#2e7d32;
    border:1px solid #81c784;
}

.password-wrapper{
    position:relative;
}

.password-wrapper input{
    width:100%;
    padding-right:45px;
}

.toggle-password{
    position:absolute;
    right:15px;
    top:50%;
    transform:translateY(-50%);
    cursor:pointer;
    color:#7d7d7d;
}


/* ===========================
    Required Fields
=========================== */
.required{
    color:#d62828;
    font-weight:700;
}

/* ===========================
    Validation Messages
=========================== */

.field-error{
    display:block;
    margin-top:6px;
    color:#d62828;
    font-size:12px;
    font-weight:500;
}
