* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: sans-serif;
}

body {
    min-height: 100vh;
    /* width: 100%;
    margin: 0;
    padding: 20px;
    display: flex;
    align-items: center;
    justify-content: center; */
}

.header {
    width: 100%;
    max-width: 400px;
    text-align: left;
}

.header p {
    color: #606060;
}

button {
    margin: 10px;
    padding: 10px;
    border-radius: 15px;
    cursor: pointer;
    width: 100%;
    max-width: 400px;
    border-style: none;
    background: #2990ff;
    color: #fff;
    transition: all 0.3s ease;
}

button:active {
    transform: scale(0.98);
}

#nextBtn:hover {
    background: #007bff;
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
}


section {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
}

.field {
    position: relative;
    margin: 10px;
    width: 100%;
    max-width: 400px;
}

.field input {
    width: 100%;
    padding: 16px;
    font-size: 16px;
    border: 2px solid #ccc;
    border-radius: 15px;
    outline: none;
    transition: border-color 0.3s;
    box-sizing: border-box;
}

.field i {
    position: absolute;
    right: 12px;
    top: 50%;
    transform: translateY(-50%);
    cursor: pointer;
    color: #999;
}

.field i:hover {
    color: #000;
}

.field label {
    position: absolute;
    left: 12px;
    top: 20px;
    color: #999;
    font-size: 12px;
    pointer-events: none;
    transition: 0.3s ease all;
    background: #fff;
    border-radius: 5px;
    padding: 0 5px;
}

.field input:focus {
    border-color: #007bff;
}

.field input:focus + label,
.field input:not(:placeholder-shown) + label {
    top: -8px;
    font-size: 12px;
}

.field input:focus + label {
    color: #007bff;
}

.field input:not(:focus) + label {
    color: #999;
}

.field input:hover {
    border-color: #000000;
}

input:focus:hover {
    border-color: #007bff;
}

.school-logo {
    width: min(280px, 70vw);
}

.form {
    width: 100%;
    max-width: 450px;
    padding: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.container {
  width: 100%;
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;

  /* Trimex background */
  background-image:
    linear-gradient(rgba(0, 0, 0, 0.45), rgba(0, 0, 0, 0.45)),
    url("pics/trimex.webp");
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
}

.right-panel {
    width: 100%;
    max-width: 470px;
    padding: 40px;
    
    /* Glass effect */
    background: rgba(255, 255, 255, 0.18);
    backdrop-filter: blur(15px);
    -webkit-backdrop-filter: blur(15px);

    /* Glass border */
    border: 1px solid rgba(255, 255, 255, 0.35);

    border-radius: 20px;

    /* Depth */
    box-shadow:
        0 8px 32px rgba(0, 0, 0, 0.25);

    color: #fff;
}

section {
    width: 100%;
    max-width: 450px;
    height: auto;
}

.left-panel {
    width: 100%;
}

img {
    max-width: 100%;
    height: auto;
}

.toast {
    position: fixed;
    top: 20px;
    right: 20px;

    background: #28a745;
    color: white;

    padding: 15px 25px;
    border-radius: 8px;

    font-weight: 600;

    opacity: 0;
    visibility: hidden;

    transition: all .3s ease;

    z-index: 9999;
}

.toast.show {
    opacity: 1;
    visibility: visible;
}

.field input.error {
    border-color: #dc3545;
    background: #fff5f5;
}

.field input.error + label {
    color: #dc3545;
}

.field input.error:focus {
    border-color: #dc3545;
}

.field{
    position:relative;
    width:100%;
    margin-bottom:20px;
}

.error-message{
    display:none;
    color:#dc3545;
    font-size:12px;
    margin-top:5px;
}

.error-message.show{
    display:block;
}

input.error{
    border:2px solid #dc3545;
}

.shake{
    animation:shake .35s;
}

@keyframes shake{

    0%{transform:translateX(0);}
    25%{transform:translateX(-5px);}
    50%{transform:translateX(5px);}
    75%{transform:translateX(-5px);}
    100%{transform:translateX(0);}
}

.button-group {
    width: 100%;
    max-width: 400px;
    display: flex;
    gap: 10px;
    margin: 10px;
}

.button-group button {
    flex: 1;
    margin: 0;
    width: auto;
}

#backBtn {
    background-color: #fff;
    color: #2990ff;
    border: 2px solid #2990ff;
}

#backBtn:hover {
    background: #f8f9fa;
    border-color: #007bff;
    color: #007bff;
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
}

.reset-section {
    width: 100%;
    max-width: 400px;
    margin: 0 auto;
}

.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;

    background: rgba(0, 0, 0, 0.5);

    display: flex;
    justify-content: center;
    align-items: center;

    z-index: 99999;
}

.modal-card {
    background: #fff;
    width: 400px;
    max-width: 90%;

    padding: 30px;

    border-radius: 20px;

    text-align: center;

    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);

    animation: modalPop 0.3s ease;
}

.success-icon {
    width: 80px;
    height: 80px;

    margin: 0 auto 20px;

    border-radius: 50%;

    background: #28a745;

    color: white;

    display: flex;
    justify-content: center;
    align-items: center;

    font-size: 36px;
}

.modal-card h2 {
    margin-bottom: 10px;
    color: #333;
}

.modal-card p {
    color: #666;
    margin-bottom: 20px;
}

.modal-card button {
    width: 100%;
    padding: 12px;

    border: none;
    border-radius: 10px;

    background: #2990ff;
    color: white;

    cursor: pointer;

    font-size: 15px;
}

.modal-card button:hover {
    background: #007bff;
}

.success-modal{

    position:fixed;
    inset:0;

    background:rgba(0,0,0,.45);

    display:none;

    justify-content:center;
    align-items:center;

    z-index:9999;

}

.success-modal.show{

    display:flex;

}

.success-content{

    width:90%;
    max-width:400px;

    background:white;

    padding:35px;

    border-radius:15px;

    text-align:center;

}

.success-content h2{

    margin-bottom:15px;

}

.success-content p{

    color:#666;

    line-height:1.6;

    margin-bottom:25px;

}

.success-content button{

    background:#2d8cff;

    color:white;

    border:none;

    padding:12px 30px;

    border-radius:10px;

    cursor:pointer;

}

@keyframes modalPop {
    from {
        opacity: 0;
        transform: scale(0.8);
    }

    to {
        opacity: 1;
        transform: scale(1);
    }
}

/* ===========================
   Loading Spinner
=========================== */

#nextBtn{

    display:flex;
    justify-content:center;
    align-items:center;
    gap:10px;

}

.spinner{

    display:none;

    width:18px;
    height:18px;

    border:3px solid rgba(255,255,255,.35);
    border-top:3px solid white;

    border-radius:50%;

    animation:spin .8s linear infinite;

}

.spinner.show{

    display:block;

}

@keyframes spin{

    from{

        transform:rotate(0deg);

    }

    to{

        transform:rotate(360deg);

    }

}

@media (max-width: 900px) {
    .container {
    flex-direction: column;
  }

  .right-panel {
    flex: 1;
    width: 100%;
    padding: 20px;
    display: flex;
    justify-content: center;
    align-items: center;
    overflow: hidden;
    align-items: flex-start;
  }

}