.form-container {
    display: grid;
    grid-template-columns: 1fr 5fr;
    height: 100%;
}

.form {
    display: flex;
    justify-content: center;
}

.form-inner-container {
    width: 90%;
    padding: 2rem;
    background-color: #FFFFFF;
    border: 1px solid #d9e3ec;
    border-radius: 10px;
}

.form-inner-container .form-heading p {
    color: #7e8d9d;
    font-weight: 500;
}

.form-content {
    margin-top: 1.5rem;
}

.form-content form {
    display: flex;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 0.8rem;
    position: relative;
    padding-bottom: 4rem;
}

.form-content .input-box {
    display: flex;
    flex-direction: column;
    width: 49%;
    gap: 4px;
    margin-top: 0.8rem;
}

.input-box label {
    color: #252c2c;
    font-weight: 600;
    font-size: 0.95rem;
}

.required-label::after {
    content: " *";
    color: red;
}

.input-box .input {
    width: 100%;
    display: flex;
    background-color: #FFFFFF;
    border: 1px solid #bed2e4;
    border-radius: 12px;
}

.input-box .baseline {
    align-items: baseline;
}

.input .icon {
    width: 10%;
    background-color: transparent;
    display: flex;
    align-items: center;
    justify-content: center;
    border-top-left-radius: 12px;
    border-bottom-left-radius: 12px;
}

.input .icon i {
    font-size: 1.04rem;
    color: #68736B;
}

.input input,
select,
.input textarea {
    width: 90%;
    padding: 1rem 0.5rem;
    border-top-right-radius: 12px;
    border-bottom-right-radius: 12px;
    border: none;
    outline: none;
    font-weight: 600;
    font-size: 0.95rem;
    background-color: transparent;
    color: #252c2c;
}


.input input,
select {
    width: 88%;
}

.input input::placeholder {
    font-size: 0.95rem;
    color: #89958D;

}

.input:hover,
.description:hover {
    border-color: #9cdfd9;
    box-shadow: 0 0 0 3px rgba(59, 158, 150, 0.15);
}


select,
input[type="date"] {
    color: #8FA9C4;
}

/* 1. Opt-in to the modern, customizable styling state */
select,
select::picker(select) {
    appearance: base-select;
}

/* 2. Style the main wrapper/button trigger */
select {
    cursor: pointer;
}

/* 3. Style the actual dropdown picker (listbox) */
select::picker(select) {
    background-color: #1a1a1a;
    border: 1px solid #333;
    border-radius: 8px;
    padding: 8px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

/* 4. Style the specific option items */
select option {
    padding: 10px;
    color: #ffffff;
    border-radius: 4px;
    cursor: pointer;
}

/* 5. Style the selected and hovered option states */
select option:hover,
select option:focus {
    background-color: #007bff;
    color: white;
}

/* 6. Style or change the native checkmark icon */
select option::checkmark {
    color: #00ff6a;
    content: "✓";
}


.modern-file-input::file-selector-button {
    background-color: #19ac5b;
    color: white;
    border: none;
    padding: 5px 20px;
    border-radius: 6px;
    cursor: pointer;
    font-weight: 500;
    margin-right: 15px;
    transition: background-color 0.2s ease;
}

/* Hover state */
.modern-file-input::file-selector-button:hover {
    background-color: #38ca81;
}

/* Focus state for accessibility */
.modern-file-input:focus-visible::file-selector-button {
    outline: 2px solid #46e57b;
    outline-offset: 2px;
}

.description-box .description {
    align-items: baseline;
}

.form-content .btn-box {
    width: max-content;
    border-radius: 12px;
    background-color: #009147;
    position: absolute;
    bottom: 0;
    right: 0;
}

.form-content .change-password {
    right: 15%;
}

.btn-box .btn {
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
}

.btn-box .btn .icon {
    width: 20%;
}

.btn button i {
    color: #FFFFFF;
}

.btn button {
    background-color: transparent;
    width: 100%;
    border: none;
    outline: none;
    padding: 0.8rem 0.5rem;
    color: #FFFFFF;
    font-size: 1.01rem;
}


.input-box .err-msg {
    display: flex;
    align-items: center;
    gap: 2px;
    margin-top: 2px;
}

.input-box .err-msg .icon {
    display: flex;
    align-items: center;
    justify-content: center;
}

.err-msg .icon .icon-red {
    color: red;
}

.err-msg small {
    color: red;
}

.input-box .hidden {
    display: none;
}

.input-box .show {
    display: inline-block;
}

.resend-otp {
    border: none;
    outline: none;
    padding: 0.5rem 1rem;
    width: max-content;
    border-radius: 8px;
    font-weight: 600;
    font-size: 0.95rem;
    color: #FFFFFF;
    border: 1px solid #bfecd0;
    background-color: #19ac5b;
}

/* =====================================================
   FORM PAGES - RESPONSIVE ONLY
   Paste at the very bottom of form.css (after your
   existing rules) so these override the desktop styles.
   Breakpoints: 950 / 600 / 360
   (950 matches the sidebar breakpoint in responsive.js)

   form.css is loaded on every page, so every rule here is
   scoped to .form-container / .form-content and cannot
   affect other pages.
   ===================================================== */


/* ---------- Tablets / sidebar becomes drawer ---------- */
@media (max-width: 950px) {

    /* minmax(0, ...) stops wide content from pushing the page sideways */
    .form-container {
        grid-template-columns: 0fr minmax(0, 5fr);
    }

    .form-container .form {
        padding-bottom: 1rem;
    }

    .form-container .form-inner-container {
        box-sizing: border-box;
        width: 94%;
        padding: 1.5rem;
    }

    .form-container .form-heading h1 {
        font-size: 1.8rem;
    }

    /* keeps a second floating button (change password) from sitting on the first */
    .form-content .change-password {
        right: auto;
        left: 0;
    }
}

@media (max-width: 732px) {
    .form-content .input-box {
        width: 100%;
    }
}

/* ---------- Phones: one field per row, full-width button ---------- */
@media (max-width: 600px) {

    .form-container .form-inner-container {
        width: calc(100% - 1.5rem);
        padding: 1rem;
    }

    .form-container .form-heading h1 {
        font-size: 1.5rem;
    }

    .form-container .form-heading p {
        font-size: 0.9rem;
    }

    .form-content {
        margin-top: 1rem;
    }

    .form-content form {
        flex-direction: column;
        gap: 0.2rem;
        padding-bottom: 0;
    }

    .form-content .input-box {
        width: 100%;
        margin-top: 0.6rem;
    }

    /* 1rem (16px) text also stops iPhones zooming in when a field is tapped */
    .form-content .input input,
    .form-content .input select,
    .form-content .input textarea {
        min-width: 0;
        font-size: 1rem;
    }

    /* submit button(s) leave the bottom-right corner and join the normal flow */
    .form-content .btn-box {
        position: static;
        width: 100%;
        margin-top: 1.2rem;
    }

    .form-content .resend-otp {
        max-width: 100%;
    }
}


/* ---------- Very small phones ---------- */
@media (max-width: 360px) {

    .form-container .form-inner-container {
        padding: 0.85rem;
    }

    .form-container .form-heading h1 {
        font-size: 1.3rem;
    }
}