:root {
    --primary: #087f73;
    --primary-dark: #05665e;
    --navy: #12334a;
    --muted: #6d7d89;
    --soft: #eef8f6;
    --line: #dce7e5;
}

* {
    box-sizing: border-box;
}

body {
    margin: 0;
    min-height: 100vh;
    font-family: "DM Sans", sans-serif;
    color: var(--navy);
    background: #f7fbfa;
}

.login-page {
    min-height: 100vh;
    display: grid;
    grid-template-columns: minmax(470px, 48%) 1fr;
}

.clinic-panel {
    position: relative;
    overflow: hidden;
    min-height: 100vh;
    padding: 52px 64px;
    flex-direction: column;
    justify-content: space-between;
    color: #fff;
    background:
        linear-gradient(145deg, rgba(5, 91, 88, .96), rgba(10, 132, 121, .92)),
        radial-gradient(circle at top right, #1bb4a4, transparent 45%);
}

.clinic-panel::after {
    content: "";
    position: absolute;
    inset: auto -12% -24% auto;
    width: 460px;
    height: 460px;
    border: 1px solid rgba(255, 255, 255, .16);
    border-radius: 50%;
    box-shadow: 0 0 0 70px rgba(255, 255, 255, .035), 0 0 0 140px rgba(255, 255, 255, .025);
}

.brand,
.mobile-brand {
    position: relative;
    z-index: 2;
    display: flex;
    align-items: center;
    gap: 12px;
    color: inherit;
    font-size: 1.35rem;
    letter-spacing: -.02em;
}

.brand-icon {
    width: 44px;
    height: 44px;
    display: grid;
    place-items: center;
    border-radius: 13px;
    color: var(--primary);
    background: #fff;
    box-shadow: 0 8px 24px rgba(4, 53, 52, .18);
}

.clinic-copy {
    position: relative;
    z-index: 2;
    max-width: 610px;
}

.eyebrow {
    display: inline-flex;
    align-items: center;
    margin-bottom: 24px;
    padding: 9px 14px;
    border: 1px solid rgba(255, 255, 255, .2);
    border-radius: 999px;
    color: rgba(255, 255, 255, .92);
    background: rgba(255, 255, 255, .09);
    font-size: .82rem;
    font-weight: 600;
    letter-spacing: .04em;
    text-transform: uppercase;
}

.clinic-copy h1 {
    max-width: 570px;
    margin-bottom: 20px;
    font-size: clamp(2.5rem, 4vw, 4.4rem);
    font-weight: 700;
    line-height: 1.06;
    letter-spacing: -.055em;
}

.clinic-copy > p {
    max-width: 520px;
    color: rgba(255, 255, 255, .76);
    font-size: 1.08rem;
    line-height: 1.7;
}

.feature-list {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 16px;
    margin-top: 38px;
}

.feature-item {
    display: flex;
    gap: 13px;
    padding: 16px;
    border: 1px solid rgba(255, 255, 255, .13);
    border-radius: 17px;
    background: rgba(255, 255, 255, .07);
    backdrop-filter: blur(10px);
}

.feature-item > span {
    width: 38px;
    height: 38px;
    flex: 0 0 auto;
    display: grid;
    place-items: center;
    border-radius: 11px;
    color: #d5fff8;
    background: rgba(255, 255, 255, .12);
}

.feature-item strong,
.feature-item small {
    display: block;
}

.feature-item strong {
    margin-bottom: 4px;
    font-size: .92rem;
}

.feature-item small {
    color: rgba(255, 255, 255, .66);
    font-size: .76rem;
    line-height: 1.45;
}

.security-note {
    position: relative;
    z-index: 2;
    display: flex;
    align-items: center;
    gap: 10px;
    color: rgba(255, 255, 255, .62);
    font-size: .78rem;
}

.panel-decoration {
    position: absolute;
    border-radius: 50%;
    background: rgba(255, 255, 255, .06);
    filter: blur(1px);
}

.decoration-one {
    width: 240px;
    height: 240px;
    top: -90px;
    right: -70px;
}

.decoration-two {
    width: 100px;
    height: 100px;
    top: 25%;
    right: 12%;
}

.form-panel {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 54px 7%;
    background:
        radial-gradient(circle at 80% 15%, rgba(8, 127, 115, .06), transparent 25%),
        #f9fcfb;
}

.login-card {
    width: 100%;
    max-width: 470px;
}

.welcome {
    margin-bottom: 36px;
}

.welcome-icon {
    width: 54px;
    height: 54px;
    display: grid;
    place-items: center;
    margin-bottom: 22px;
    border-radius: 16px;
    color: var(--primary);
    background: var(--soft);
    font-size: 1.45rem;
}

.welcome h2 {
    margin-bottom: 9px;
    font-size: 2rem;
    font-weight: 700;
    letter-spacing: -.035em;
}

.welcome p {
    margin: 0;
    color: var(--muted);
}

.form-label {
    margin-bottom: 8px;
    color: #294657;
    font-size: .88rem;
    font-weight: 600;
}

.custom-input {
    border: 1px solid var(--line);
    border-radius: 13px;
    background: #fff;
    box-shadow: 0 4px 14px rgba(24, 68, 65, .025);
    transition: border-color .2s, box-shadow .2s;
}

.custom-input:focus-within {
    border-color: rgba(8, 127, 115, .75);
    box-shadow: 0 0 0 4px rgba(8, 127, 115, .09);
}

.custom-input .input-group-text,
.custom-input .form-control,
.password-toggle {
    min-height: 53px;
    border: 0;
    background: transparent;
}

.custom-input .input-group-text {
    padding-left: 17px;
    color: #8a9ba5;
}

.custom-input .form-control {
    color: var(--navy);
    font-size: .93rem;
    box-shadow: none;
}

.custom-input .form-control::placeholder {
    color: #a0adb4;
}

.password-toggle {
    padding-right: 17px;
    color: #82939d;
}

.password-toggle:hover,
.password-toggle:focus {
    color: var(--primary);
}

.forgot-link,
.support a {
    color: var(--primary);
    font-size: .82rem;
    font-weight: 600;
    text-decoration: none;
}

.forgot-link:hover,
.support a:hover {
    color: var(--primary-dark);
    text-decoration: underline;
}

.form-check-label {
    color: var(--muted);
    font-size: .86rem;
}

.form-check-input:checked {
    border-color: var(--primary);
    background-color: var(--primary);
}

.form-check-input:focus {
    border-color: var(--primary);
    box-shadow: 0 0 0 .2rem rgba(8, 127, 115, .12);
}

.btn-login {
    min-height: 54px;
    border-radius: 13px;
    color: #fff;
    background: var(--primary);
    font-weight: 600;
    box-shadow: 0 11px 24px rgba(8, 127, 115, .2);
    transition: transform .2s, background .2s, box-shadow .2s;
}

.btn-login:hover,
.btn-login:focus {
    color: #fff;
    background: var(--primary-dark);
    transform: translateY(-1px);
    box-shadow: 0 14px 28px rgba(8, 127, 115, .25);
}

.support {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    margin-top: 34px;
    padding-top: 26px;
    border-top: 1px solid #e6eeec;
    color: #80909a;
    font-size: .82rem;
}

.form-panel footer {
    margin-top: 48px;
    color: #95a3aa;
    font-size: .75rem;
    text-align: center;
}

.mobile-brand {
    width: 100%;
    max-width: 470px;
    margin-bottom: 42px;
    color: var(--navy);
}

.mobile-brand .brand-icon {
    color: #fff;
    background: var(--primary);
}

.was-validated .form-control:invalid {
    background-image: none;
}

.was-validated .custom-input:has(.form-control:invalid) {
    border-color: #dc3545;
}

@media (max-width: 1199.98px) {
    .clinic-panel {
        padding: 44px;
    }

    .feature-list {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 991.98px) {
    .login-page {
        display: block;
    }

    .form-panel {
        padding: 38px 24px;
    }
}

@media (max-width: 575.98px) {
    .form-panel {
        justify-content: flex-start;
        padding: 28px 20px;
    }

    .mobile-brand {
        margin-bottom: 48px;
    }

    .welcome {
        margin-bottom: 30px;
    }

    .welcome h2 {
        font-size: 1.7rem;
    }

    .form-panel footer {
        margin-top: 38px;
    }
}
