/* =========================================
   Dental Clinic SaaS - Login Page
   ========================================= */
.dental-login-page {
    position: relative;
    isolation: isolate;
    min-height: 100vh;
    overflow: hidden;
    background: #edf5ff;
}

.dental-login-background {
    position: absolute;
    inset: 0;
    z-index: -2;

    background-image: url("../images/dental-clinic-bg.png");
    background-size: cover;
    background-position: center center;
    background-repeat: no-repeat;
}

.dental-login-overlay {
    position: absolute;
    inset: 0;
    z-index: -1;

    background: linear-gradient(
        90deg,
        rgba(239, 247, 255, 0.85) 0%,
        rgba(239, 247, 255, 0.70) 38%,
        rgba(239, 247, 255, 0.18) 70%,
        rgba(239, 247, 255, 0.05) 100%
    );

    pointer-events: none;
}

.dental-login-content {
    position: relative;
    z-index: 1;
}

/* Brand */

.dental-brand {
    display: flex;
    align-items: center;
    gap: 15px;
    margin-bottom: 26px;
}

.dental-brand-icon {
    width: 60px;
    height: 60px;
    flex: 0 0 60px;
    display: grid;
    place-items: center;
    color: var(--dental-blue);
}

.dental-brand-icon svg {
    width: 100%;
    height: 100%;
}

.dental-brand-name {
    font-size: clamp(23px, 2.2vw, 34px);
    font-weight: 800;
    line-height: 1.15;
    letter-spacing: -0.8px;
}

.dental-brand-name span {
    color: #3988d5;
}

.dental-brand-subtitle {
    margin-top: 7px;
    font-size: 11px;
    font-weight: 800;
    letter-spacing: 2.5px;
    color: #344866;
}

/* Main layout */

.dental-login-layout {
    display: grid;
    grid-template-columns: minmax(360px, 590px) minmax(220px, 1fr);
    align-items: center;
    gap: clamp(25px, 4vw, 65px);
    flex: 1;
    padding-bottom: 26px;
}

/* Login card */

.dental-login-card {
    width: 100%;
    padding: clamp(26px, 3.2vw, 43px);
    border: 1px solid rgba(255, 255, 255, 0.88);
    border-radius: 24px;

    background: rgba(255, 255, 255, 0.86);
    -webkit-backdrop-filter: blur(16px);
    backdrop-filter: blur(16px);

    box-shadow:
        0 20px 65px rgba(36, 75, 125, 0.12),
        0 2px 10px rgba(255, 255, 255, 0.45);
}

.dental-card-heading {
    margin-bottom: 28px;
    text-align: center;
}

.dental-eyebrow {
    margin: 0 0 12px;
    color: #46678f;
    font-size: 12px;
    font-weight: 800;
    letter-spacing: 2px;
}

.dental-login-card h1 {
    margin: 0;
    color: #14365f;
    font-size: clamp(30px, 3vw, 40px);
    font-weight: 800;
    letter-spacing: -1.2px;
}

.dental-login-subtitle {
    margin: 10px 0 0;
    color: var(--dental-muted);
    font-size: 15px;
}

/* Form */

.dental-form-group {
    margin-bottom: 21px;
}

.dental-form-group label {
    display: block;
    margin-bottom: 8px;
    color: #1b385e;
    font-size: 13px;
    font-weight: 750;
}

.dental-input-wrap {
    position: relative;
    display: flex;
    align-items: center;
}

.dental-input-icon {
    position: absolute;
    z-index: 1;
    left: 15px;
    display: flex;
    color: #315e97;
    pointer-events: none;
}

.dental-input-icon svg {
    width: 21px;
    height: 21px;
}

.dental-login-card .dental-login-input {
    width: 100%;
    min-height: 53px;
    padding: 12px 46px 12px 48px;
    border: 1px solid #d6e3f5;
    border-radius: 12px;
    background: rgba(235, 243, 255, 0.88);
    color: #18385f;
    font-size: 15px;
    box-shadow: none;
    transition:
        border-color 0.2s ease,
        box-shadow 0.2s ease,
        background 0.2s ease;
}

.dental-login-card .dental-login-input::placeholder {
    color: #8295b0;
    opacity: 1;
}

.dental-login-card .dental-login-input:focus {
    border-color: #5593df;
    background: #fff;
    box-shadow: 0 0 0 4px rgba(50, 116, 202, 0.13);
    outline: none;
}

.dental-password-toggle {
    position: absolute;
    right: 10px;
    top: 50%;
    transform: translateY(-50%);

    display: grid;
    place-items: center;
    width: 35px;
    height: 35px;
    padding: 7px;

    border: 0;
    border-radius: 8px;
    background: transparent;
    color: #45678f;
    cursor: pointer;
}

.dental-password-toggle:hover {
    background: rgba(48, 104, 177, 0.1);
}

.dental-password-toggle:focus-visible {
    outline: 2px solid var(--dental-blue);
    outline-offset: 2px;
}

.dental-password-toggle svg {
    width: 21px;
    height: 21px;
}

/* Sign-in button */

.dental-signin-button {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;

    width: 100%;
    min-height: 54px;
    margin-top: 8px;
    padding: 13px 18px;

    border: 1px solid #245bb0;
    border-radius: 12px;

    background: linear-gradient(110deg, #2866c1, #1c56a9);
    color: #fff;

    font-family: inherit;
    font-size: 16px;
    font-weight: 750;
    cursor: pointer;

    box-shadow: 0 7px 18px rgba(36, 91, 176, 0.17);
    transition:
        transform 0.2s ease,
        box-shadow 0.2s ease,
        background 0.2s ease;
}

.dental-signin-button svg {
    width: 23px;
    height: 23px;
}

.dental-signin-button:hover {
    background: linear-gradient(110deg, #1e58ad, #15458f);
    box-shadow: 0 10px 23px rgba(36, 91, 176, 0.24);
    transform: translateY(-1px);
}

.dental-signin-button:focus-visible {
    outline: 3px solid rgba(36, 91, 176, 0.35);
    outline-offset: 3px;
}

.dental-signin-button:active {
    transform: translateY(0);
}

/* Setup note and alerts */

.dental-setup-note {
    display: flex;
    align-items: flex-start;
    justify-content: center;
    gap: 8px;

    margin-top: 24px;
    color: #627b9c;
    font-size: 12px;
    line-height: 1.7;
    text-align: center;
}

.dental-setup-icon {
    color: #3684d5;
}

.dental-login-card .alert {
    overflow-wrap: anywhere;
    border-radius: 10px;
    font-size: 13px;
}

/* Welcome message */

.dental-welcome-message {
    max-width: 360px;
    align-self: center;
    justify-self: start;
    padding: 18px;
    color: #2169b7;
}

.dental-welcome-script {
    font-family: "Segoe Print", "Bradley Hand", cursive;
    font-size: clamp(29px, 3.1vw, 46px);
    font-weight: 600;
    font-style: italic;
    line-height: 1.22;
    text-shadow: 0 1px 10px rgba(255, 255, 255, 0.55);
    transform: rotate(-5deg);
}

.dental-welcome-tooth {
    display: inline-block;
    margin-left: 6px;
    color: #2a83cf;
    font-size: 0.8em;
}

.dental-welcome-line {
    width: 75%;
    height: 4px;
    margin: 18px 0 14px 22px;
    border-radius: 100%;
    background: #3985cc;
    transform: rotate(-8deg);
}

.dental-welcome-message p {
    margin: 20px 0 0;
    color: #45688d;
    font-size: 15px;
    line-height: 1.7;
}

/* Feature strip */

.dental-feature-row {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0;
    padding: 15px 0 24px;
}

.dental-feature {
    display: flex;
    align-items: center;
    gap: 12px;
    min-width: 0;
    padding: 8px 23px;
    border-right: 1px solid rgba(47, 104, 165, 0.19);
}

.dental-feature:first-child {
    padding-left: 0;
}

.dental-feature:last-child {
    border-right: 0;
}

.dental-feature-icon {
    display: flex;
    flex: 0 0 34px;
    color: #1678d1;
}

.dental-feature-icon svg {
    width: 34px;
    height: 34px;
}

.dental-feature strong,
.dental-feature small {
    display: block;
}

.dental-feature strong {
    color: #17365c;
    font-size: 13px;
    font-weight: 800;
}

.dental-feature small {
    margin-top: 4px;
    color: #5c7697;
    font-size: 11px;
}

/* Footer */

.dental-login-footer {
    margin: 0 calc(-1 * clamp(22px, 6vw, 100px));
    padding: 15px 20px;
    background: rgba(30, 87, 151, 0.17);
    color: #35587f;
    font-size: 12px;
    text-align: center;
}

/* Tablet */

@media (max-width: 1050px) {
    .dental-login-content {
        padding-left: 32px;
        padding-right: 32px;
    }

    .dental-login-layout {
        grid-template-columns: minmax(340px, 520px) minmax(150px, 1fr);
        gap: 15px;
    }

    .dental-login-card {
        padding: 30px;
    }

    .dental-welcome-message {
        padding: 5px;
    }

    .dental-feature {
        padding-left: 13px;
        padding-right: 13px;
    }

    .dental-login-footer {
        margin-left: -32px;
        margin-right: -32px;
    }
}

/* Mobile */

@media (max-width: 700px) {
    .dental-login-page {
        overflow: auto;
    }

    .dental-login-background {
        background-position: 68% center;
    }

    .dental-login-overlay {
        background: rgba(239, 247, 255, 0.84);
    }

    .dental-login-content {
        min-height: 100vh;
        min-height: 100dvh;
        padding: 23px 16px 0;
    }

    .dental-brand {
        justify-content: center;
        gap: 10px;
        margin-bottom: 22px;
    }

    .dental-brand-icon {
        width: 45px;
        height: 45px;
        flex-basis: 45px;
    }

    .dental-brand-name {
        font-size: 23px;
        letter-spacing: -0.6px;
    }

    .dental-brand-subtitle {
        font-size: 8px;
        letter-spacing: 1.5px;
    }

    .dental-login-layout {
        display: flex;
        flex-direction: column;
        justify-content: center;
        gap: 10px;
        padding: 0 0 20px;
    }

    .dental-login-card {
        width: 100%;
        max-width: 470px;
        margin: 0 auto;
        padding: 26px 21px;
        border-radius: 20px;
        background: rgba(255, 255, 255, 0.94);
    }

    .dental-card-heading {
        margin-bottom: 23px;
    }

    .dental-login-card h1 {
        font-size: 32px;
    }

    .dental-welcome-message {
        display: none;
    }

    .dental-feature-row {
        justify-content: center;
        gap: 12px 0;
        padding: 10px 0 20px;
    }

    .dental-feature {
        width: 50%;
        padding: 9px 10px;
        border-right: 0;
    }

    .dental-feature:first-child {
        padding-left: 10px;
    }

    .dental-feature-icon {
        flex-basis: 29px;
    }

    .dental-feature-icon svg {
        width: 29px;
        height: 29px;
    }

    .dental-feature strong {
        font-size: 12px;
    }

    .dental-feature small {
        font-size: 10px;
    }

    .dental-login-footer {
        margin-left: -16px;
        margin-right: -16px;
        padding: 14px 12px;
    }
}

/* Small phones */

@media (max-width: 380px) {
    .dental-brand-name {
        font-size: 20px;
    }

    .dental-brand-subtitle {
        font-size: 7px;
        letter-spacing: 1.1px;
    }

    .dental-login-card {
        padding: 23px 16px;
    }

    .dental-login-card h1 {
        font-size: 29px;
    }

    .dental-feature {
        gap: 8px;
        padding-left: 5px;
        padding-right: 5px;
    }
}

/* Accessibility: reduce motion if requested by the device */

@media (prefers-reduced-motion: reduce) {
    .dental-login-card *,
    .dental-login-card *::before,
    .dental-login-card *::after {
        transition: none !important;
    }
}



/* Remove scrollbar from the login page */
html:has(.dental-login-page),
body:has(.dental-login-page) {
    margin: 0;
    padding: 0;
    overflow: hidden;
}

.dental-login-page {
    width: 100%;
    height: 100vh;
    height: 100dvh;
    min-height: 0;
    overflow: hidden;
}

.dental-login-content {
    width: 100%;
    height: 100%;
    min-height: 0;
    padding-top: 20px;
    padding-bottom: 0;
}

.dental-login-layout {
    flex: 1;
    min-height: 0;
    padding-bottom: 12px;
}

.dental-login-footer {
    flex-shrink: 0;
}

/* Keep scrolling available on smaller mobile screens */
@media (max-width: 700px) {
    html:has(.dental-login-page),
    body:has(.dental-login-page) {
        overflow: auto;
    }

    .dental-login-page {
        height: auto;
        min-height: 100vh;
        min-height: 100dvh;
        overflow: visible;
    }

    .dental-login-content {
        height: auto;
        min-height: 100vh;
        min-height: 100dvh;
    }
}