/**
 * CliniCore - Login Screen, Evidence Branding & Dev Quick Login
 */

.logout-form {
    display: flex;
    margin: 0;
}

.login-page {
    overflow: auto;
    background: #eef5f3;
}

.login-shell {
    display: grid;
    min-height: 100vh;
    grid-template-columns: minmax(420px, 1.05fr) minmax(420px, .95fr);
}

.login-showcase {
    position: relative;
    display: flex;
    min-height: 100vh;
    overflow: hidden;
    flex-direction: column;
    padding: 40px clamp(34px, 5vw, 76px);
    color: #ecfffa;
    background:
        radial-gradient(circle at 84% 18%, rgba(87, 205, 188, .28), transparent 24%),
        radial-gradient(circle at 10% 90%, rgba(87, 205, 188, .12), transparent 30%),
        linear-gradient(145deg, #0b3533, #0f5551 58%, #14756d);
}

.login-page.evidence-branding .login-showcase {
    background:
        radial-gradient(circle at 84% 18%, rgba(228, 211, 184, .24), transparent 25%),
        radial-gradient(circle at 12% 88%, rgba(78, 164, 151, .18), transparent 32%),
        linear-gradient(145deg, #102f2d, #174b47 58%, #247f77);
}

.clinic-logo-monogram {
    display: grid;
    width: 58px;
    height: 58px;
    place-items: center;
    border-radius: 18px;
    color: #fffaf1;
    background: linear-gradient(145deg, #318f85, #175f59);
    box-shadow: 0 10px 24px rgba(23, 95, 89, .18);
    font-size: 1.45rem;
    font-weight: 850;
}

.login-showcase::before,
.login-showcase::after {
    position: absolute;
    border: 1px solid rgba(255, 255, 255, .08);
    border-radius: 50%;
    content: "";
}

.login-showcase::before {
    top: -110px;
    right: -80px;
    width: 420px;
    height: 420px;
}

.login-showcase::after {
    right: 15%;
    bottom: -210px;
    width: 520px;
    height: 520px;
}

.login-brand {
    position: relative;
    z-index: 2;
    display: flex;
    align-items: center;
    gap: 12px;
}

.login-brand > div:nth-child(2) {
    display: flex;
    flex-direction: column;
}

.login-brand strong {
    color: white;
    font-size: 1.08rem;
}

.login-brand small {
    margin-top: 2px;
    color: rgba(236, 255, 250, .52);
    font-size: .64rem;
}

.login-brand .version-pill {
    margin-left: auto;
}

.login-showcase-copy {
    position: relative;
    z-index: 2;
    max-width: 650px;
    margin: auto 0;
    padding: 70px 0;
}

.login-eyebrow {
    color: #91e7da;
    font-size: .66rem;
    font-weight: 760;
    letter-spacing: .13em;
    text-transform: uppercase;
}

.login-showcase-copy h1 {
    max-width: 620px;
    margin-top: 15px;
    font-size: clamp(2.3rem, 4.4vw, 4.2rem);
    font-weight: 770;
    letter-spacing: -.055em;
    line-height: 1.03;
}

.login-showcase-copy > p {
    max-width: 590px;
    margin-top: 22px;
    color: rgba(236, 255, 250, .68);
    font-size: .9rem;
    line-height: 1.75;
}

.login-feature-grid {
    display: grid;
    margin-top: 38px;
    grid-template-columns: repeat(3, 1fr);
    gap: 10px;
}

.login-feature-grid div {
    display: flex;
    min-height: 115px;
    flex-direction: column;
    justify-content: flex-end;
    padding: 16px;
    border: 1px solid rgba(255, 255, 255, .09);
    border-radius: 14px;
    background: rgba(255, 255, 255, .055);
    backdrop-filter: blur(10px);
}

.login-feature-grid strong {
    color: #fff;
    font-size: .72rem;
}

.login-feature-grid span {
    margin-top: 6px;
    color: rgba(236, 255, 250, .52);
    font-size: .59rem;
    line-height: 1.55;
}

.login-showcase-footer {
    position: relative;
    z-index: 2;
    display: flex;
    align-items: center;
    gap: 10px;
}

.login-showcase-footer > div {
    display: flex;
    flex-direction: column;
}

.login-showcase-footer strong {
    font-size: .68rem;
}

.login-showcase-footer small {
    margin-top: 3px;
    color: rgba(236, 255, 250, .45);
    font-size: .58rem;
}

.login-form-area {
    display: grid;
    min-height: 100vh;
    place-items: center;
    padding: 34px;
    background:
        radial-gradient(circle at 80% 10%, rgba(64, 172, 158, .08), transparent 24%),
        #f5f9f8;
}

.login-card {
    width: min(460px, 100%);
    padding: 34px;
    border: 1px solid #dce8e5;
    border-radius: 22px;
    background: #fff;
    box-shadow: 0 24px 70px rgba(16, 64, 59, .1);
}

.login-card-heading {
    margin-bottom: 26px;
}

.login-card-heading h2 {
    margin-top: 7px;
    color: #17312f;
    font-size: 1.65rem;
    letter-spacing: -.04em;
}

.login-card-heading p {
    margin-top: 7px;
    color: #758783;
    font-size: .7rem;
}

.login-alert {
    display: flex;
    align-items: center;
    margin-bottom: 18px;
    padding: 11px 12px;
    border: 1px solid #f3cdd1;
    border-radius: 10px;
    color: #aa3743;
    background: #fff0f1;
    font-size: .66rem;
    font-weight: 620;
    gap: 8px;
}

.login-alert svg {
    width: 17px;
    height: 17px;
}

.login-form .field-group label {
    color: #29413e;
}

.login-input {
    position: relative;
    display: flex;
    height: 47px;
    align-items: center;
    border: 1px solid #dce8e5;
    border-radius: 11px;
    background: #f9fbfa;
    transition: border-color .15s ease, box-shadow .15s ease, background .15s ease;
}

.login-input:focus-within {
    border-color: rgba(20, 125, 120, .45);
    background: #fff;
    box-shadow: 0 0 0 4px rgba(20, 125, 120, .07);
}

.login-input > svg {
    width: 17px;
    height: 17px;
    margin-left: 13px;
    color: #81938f;
}

.login-input input {
    min-width: 0;
    flex: 1;
    height: 100%;
    padding: 0 12px;
    border: 0;
    outline: 0;
    color: #17312f;
    background: transparent;
    font-size: .75rem;
}

.password-toggle {
    display: grid;
    width: 40px;
    height: 40px;
    place-items: center;
    border: 0;
    color: #81938f;
    background: transparent;
    cursor: pointer;
}

.password-toggle svg {
    width: 17px;
    height: 17px;
}

.login-submit {
    width: 100%;
    min-height: 46px;
    margin-top: 4px;
}

.first-access {
    display: grid;
    margin-top: 24px;
    padding-top: 20px;
    grid-template-columns: 1fr auto;
    align-items: center;
    border-top: 1px solid #e5eeec;
    gap: 6px;
}

.first-access span {
    grid-row: 1 / 3;
    color: #84948f;
    font-size: .6rem;
    font-weight: 650;
    text-transform: uppercase;
}

.first-access code {
    padding: 3px 7px;
    border-radius: 6px;
    color: #146e69;
    background: #eaf7f4;
    font-family: "Cascadia Code", Consolas, monospace;
    font-size: .62rem;
    text-align: right;
}

/* Localhost Dev Quick Login */
.dev-quick-login-card {
    margin-top: 24px;
    padding-top: 20px;
    border-top: 1px dashed #d0deda;
}

.dev-quick-login-header {
    margin-bottom: 12px;
}

.dev-quick-pill {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 4px 10px;
    border-radius: 999px;
    background: #e6f6f3;
    color: #106f66;
    font-size: .62rem;
    font-weight: 700;
    letter-spacing: .04em;
    text-transform: uppercase;
}

.dev-quick-pulse {
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background: #14b8a6;
    box-shadow: 0 0 0 2px rgba(20, 184, 166, .25);
    animation: livePulse 2s infinite;
}

.dev-quick-hint {
    margin-top: 6px;
    font-size: .68rem;
    color: #718480;
}

.dev-quick-users-list {
    display: flex;
    flex-direction: column;
    gap: 8px;
    margin-top: 10px;
}

.dev-quick-user-form {
    margin: 0;
    padding: 0;
}

.dev-quick-user-item {
    width: 100%;
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 9px 12px;
    border: 1px solid #dce8e5;
    border-radius: 12px;
    background: #fdfefe;
    cursor: pointer;
    text-align: left;
    transition: all .18s ease;
    font-family: inherit;
    box-sizing: border-box;
}

.dev-quick-user-item:hover {
    border-color: #147d78;
    background: #f4faf8;
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(20, 125, 120, .08);
}

.dev-quick-user-item:active {
    transform: translateY(0);
}

.dev-quick-avatar {
    width: 32px;
    height: 32px;
    border-radius: 9px;
    background: linear-gradient(135deg, #103c3b, #1d6159);
    color: #ecfffa;
    display: grid;
    place-items: center;
    font-size: .75rem;
    font-weight: 700;
    flex-shrink: 0;
}

.dev-quick-info {
    flex: 1;
    min-width: 0;
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.dev-quick-title-row {
    display: flex;
    align-items: center;
    gap: 6px;
    flex-wrap: wrap;
}

.dev-quick-name {
    font-size: .74rem;
    color: #17312f;
    font-weight: 650;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.dev-quick-role-badge {
    display: inline-block;
    padding: 1px 6px;
    border-radius: 5px;
    font-size: .58rem;
    font-weight: 600;
    background: #eef4f2;
    color: #3b5753;
}

.dev-quick-role-badge.dev-role-superadmin {
    background: #e0f2fe;
    color: #0369a1;
}

.dev-quick-role-badge.dev-role-manager {
    background: #fef3c7;
    color: #92400e;
}

.dev-quick-role-badge.dev-role-reception {
    background: #f3e8ff;
    color: #6b21a8;
}

.dev-quick-role-badge.dev-role-professional {
    background: #e0f7f3;
    color: #0f766e;
}

.dev-quick-email {
    font-size: .63rem;
    color: #7b8e8a;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.dev-quick-enter-btn {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 5px 10px;
    border-radius: 7px;
    background: #147d78;
    color: #fff;
    font-size: .65rem;
    font-weight: 650;
    flex-shrink: 0;
    transition: background .15s ease;
}

.dev-quick-user-item:hover .dev-quick-enter-btn {
    background: #0f6662;
}

@media (max-width: 900px) {
    .login-shell {
        grid-template-columns: 1fr;
    }

    .login-showcase {
        display: none;
    }

    .login-form-area {
        min-height: 100vh;
    }
}

@media (max-width: 700px) {
    .login-form-area {
        padding: 18px;
    }

    .login-card {
        padding: 25px 20px;
        border-radius: 18px;
    }
}
