*{
    margin:0;
    padding:0;
    box-sizing:border-box;
    font-family:"poppins",sans-serif;
    
}
body{
    padding-top: 100px;
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 100vh;
    margin: 0;
    background: url(../pictures/psu-logo.jpg) no-repeat top center,url(../pictures/dhvsu.jpg) no-repeat center center;
    background-attachment: fixed;
    background-size: 10%,cover;
    opacity: 0.9;
}


/* The .container and .form-container styles are crucial for responsiveness */
.container, .form-container {
    /* Changed fixed width to max-width for fluidity */
    max-width: 420px;
    width: 90%; /* Use percentage width on all screens */
    background: transparent;
    color: #dfe9f5;
    padding:1.5rem;
    margin:50px auto;
    border-radius:10px;
    box-shadow:0 20px 35px rgba(0,0,1,0.9);
    background: rgb(48, 44, 44);
    backdrop-filter: blur(-90px);
    /* Added transition for smooth resizing */
    transition: max-width 0.3s ease, padding 0.3s ease;
}

/* Ensure the form element itself is responsive */
form{
    /* Use fluid margin */
    margin:0 5%;
}

/* * ✅ RESPONSIVE PERSONAL INFORMATION LAYOUT (index.html)
 * Default (Desktop/Tablet): Side-by-side
 */
.row {
    display: flex;
    gap: 15px; /* Spacing between the inputs (Firstname/Lastname) */
    margin-bottom: 20px;
    width: 100%;
}

.row input {
    flex: 1; /* Makes inputs take up equal space */
    min-width: 0; 
    /* Inherits standard input styling */
}

.container .form-title{
    font-size:1.5rem;
    font-weight:bold;
    text-align:center;
    padding:1.3rem;
    margin-bottom:0.4rem;
}

.container .input-group{
    position: relative;
    width: 100%;
    height: 50px;
    margin: 30px 0;
}

.input-group input,
.form-container input {
    width:100%;
    height: 100%;
    background: transparent;
    border: none;
    outline: none;
    border: 2px solid rgba(255, 255, 255, .2);
    border-radius: 40px;
    font-size: 16px;
    color:#dfe9f5;
    padding: 20px 45px 20px  20px;
    /* Added transition for smoother input focus effects */
    transition: all 0.3s ease;
}

input::placeholder{
    color: white;
}

.input-group i {
    position: absolute;
    right: 20px;
    top: 48%;
    transform: translateY(-48%);
    font-size: 20px;

}
/* Added specific style for togglePassword icon in index.html */
.password-group .togglePassword {
    position: absolute;
    right: 20px;
    top: 50%;
    transform: translateY(-50%);
    font-size: 20px;
    color: #dfe9f5;
    cursor: pointer;
    z-index: 10;
}

.password-group {
    position: relative;
    margin-bottom: 20px; /* Add space below password fields */
}


input:focus{
    background-color: transparent;
    outline:transparent;
    border-bottom:2px solid hsl(327,90%,28%);
}

.container .remember-login {
    display: flex;
    justify-content: space-between;
    font-size: 14.5px;
    margin: -15px 0 15px;
}

.container .btn {
    width: 25%;
    height: 35px;
    background: #6b0ae2;
    border: none;
    outline: none;
    border-radius: 35px;
    box-shadow: 0 0 10px rgba(0,0,1,0.1);
    cursor: pointer;
    font-size: 16px;
    color: rgb(255, 255, 255);
    font-size: 600;
}

.container .recover{
    text-align: left;
    font-size: 600;
    margin-bottom:1rem;

}

input:focus~label,input:not(:placeholder-shown)~label{
    top:-3em;
    color:hsl(327,90%,28%);
    font-size:15px;
}

.recover a{
    text-decoration:none;
    color:rgb(125,125,235);
}

.recover a:hover{
    color:blue;
    text-decoration:underline;
}
button{
    font-size:1.1rem;
    padding:8px 0;
    border-radius:5px;
    outline:none;
    border:none;
    width:100%;
    background:rgb(33, 161, 28);
    color:white;
    cursor:pointer;
    transition:0.9s;
}
button:hover{
    background:#07001f;
}
.or{
    font-size:1.1rem;
    margin-top:0.5rem;
    text-align:center;
}
.icons{
    text-align:center;
}
.icons i{
    color:rgb(125,125,235);
    padding:0.8rem 1.5rem;
    border-radius:10px;
    font-size:1.5rem;
    cursor:pointer;
    border:2px solid #dfe9f5;
    margin:0 15px;
    transition:1s;
}
.icons i:hover{
    background:#07001f;
    font-size:1.6rem;
    border:2px solid rgb(125,125,235);
}
.links{
    display:flex;
    justify-content:space-around;
    padding:0 4rem;
    margin-top:0.9rem;
    font-weight:bold;
}
.links button {
    width: auto;
    background: transparent;
    color: rgb(125,125,235);
    padding: 0;
    font-size: 1rem;
    transition: none;
}
.links button:hover {
    background: transparent;
    text-decoration: underline;
    color: blue;
}
.messageDiv{
    background-color: hsl(327,90%,28%);
    color: white;
    padding: 10px 20px;
    margin: 10px;
    border: radius 5px; 
    font-size: 1rem;
    opacity: 0;
    animation: fadeOut 7s forwards;
}

/* ========================================= */
/* ✅ Responsive CSS for Mobile Devices (up to 768px - phones/small tablets) */
/* ========================================= */
@media (max-width: 768px) {
    body {
        padding-top: 0; /* ✅ alisin yung space sa itaas */
        background-size: 20%, cover;
        display: flex;
        justify-content: center;  /* ✅ center horizontally */
        align-items: center;      /* ✅ center vertically */
        min-height: 100vh;        /* ✅ occupy full screen height */
    }

    .container, .form-container {
        margin: 0 auto;          /* ✅ remove extra top margin */
        width: 90%;
        max-width: 400px;
    }

    .container, .form-container {
        /* Take up more screen space on mobile */
        width: 95%;
        /* Narrower max-width for better use of space */
        max-width: 400px; 
        margin: 20px auto;
        padding: 1.2rem;
    }

    /* * ✅ Make Personal Information fields stack on mobile
     * (Firstname and Lastname will now be top-to-bottom)
     */
    .row {
        flex-direction: column;
        gap: 0; /* Remove gap when stacking */
    }
    
    .row input {
        margin-bottom: 20px; /* Add space between stacked inputs */
    }
    
    .container .form-title {
        font-size: 1.3rem;
    }

    /* Reduce horizontal margin inside the form */
    form {
        margin: 0 1rem;
    }
    
    .links {
        /* Stack links vertically or adjust padding */
        padding: 0 1rem;
        flex-direction: column;
        align-items: center;
        gap: 10px;
    }
    
    .links p, .links button {
        text-align: center;
    }

    .icons i {
        /* Reduce icon size and margin */
        padding: 0.5rem 0.8rem;
        font-size: 1.2rem;
        margin: 0 5px;
    }
}

/* ========================================= */
/* ✅ Responsive CSS for Tablet Devices (769px to 1024px - iPads/Mid-sized monitors) */
/* ========================================= */
@media (min-width: 769px) and (max-width: 1024px) {
    body {
        padding-top: 50px;
        background-size: 15%, cover;
    }
    
    .container, .form-container {
        /* Allow forms to be slightly wider on tablet */
        max-width: 500px;
        width: 70%;
    }
    
    /* Keep .row as flex (side-by-side) on tablets */
    .row {
        gap: 20px;
    }

    form {
        margin: 0 2rem;
    }
}
