:root {
    --accent: #0891b2;
    --accent-2: #0e7490;
    --accent-gradient: linear-gradient(135deg, #22d3ee 0%, #0891b2 50%, #0e7490 100%);
    --accent-glow: rgba(8, 145, 178, 0.4);

    --ink: #0a1a1e;
    --ink-2: #0d2d33;

    --bg: #f0feff;
    --card: rgba(255, 255, 255, 0.97);
    --text: #0a1a1e;
    --muted: #4e7d8a;
    --border: #cff8fe;

    --soft: #ecfeff;
    --error: #ef4444;
    --success: #10b981;
    --warning: #f59e0b;
    --info: #3b82f6;

    --r: 24px;
    /* More rounded card */
    --r2: 12px;
    /* More rounded inputs */
    --h: 56px;
    /* Taller inputs */

    --shadow: 0 10px 30px -10px rgba(8, 80, 100, .12);
    --shadow-lg: 0 25px 50px -12px rgba(8, 80, 100, 0.18);
    --shadow-btn: 0 10px 20px -5px rgba(8, 145, 178, 0.4);

    --ring: 0 0 0 4px rgba(8, 145, 178, .18);

    --font: "Almarai", "Noto Kufi Arabic", "Cairo", "Segoe UI", sans-serif;
    --transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html,
body {
    height: 100%;
    overflow-x: hidden;
}

body {
    font-family: var(--font);
    background:
        radial-gradient(1000px 500px at 10% -10%, rgba(34, 211, 238, .12), transparent 70%),
        radial-gradient(800px 400px at 90% 90%, rgba(8, 145, 178, .08), transparent 70%),
        linear-gradient(180deg, #f0feff 0%, #e0f9fd 100%);
    color: var(--text);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 28px;
    position: relative;
    min-height: 100vh;
}

body::before {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background:
        radial-gradient(circle at 20% 80%, rgba(34, 211, 238, .06) 0%, transparent 50%),
        radial-gradient(circle at 80% 20%, rgba(8, 145, 178, .04) 0%, transparent 50%);
    pointer-events: none;
    z-index: 0;
}

body[data-signup-page] {
    align-items: flex-start;
}

.wrap {
    width: min(420px, 100%);
    animation: floatIn 0.6s ease both;
    position: relative;
    z-index: 1;
}

.card {
    background: var(--card);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border: 1px solid rgba(255, 255, 255, 0.6);
    border-radius: var(--r);
    box-shadow: var(--shadow-lg);
    padding: 32px 28px 24px;
    position: relative;
    overflow: hidden;
    transition: var(--transition);
}

.card::before {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: var(--accent-gradient);
    z-index: 1;
}

.card::after {
    content: "";
    position: absolute;
    inset: 0;
    background:
        radial-gradient(380px 160px at 50% -10%, rgba(34, 211, 238, .08), transparent 70%);
    pointer-events: none;
}

.card>* {
    position: relative;
    z-index: 2;
}

.logo {
    display: flex;
    justify-content: center;
    margin-top: 2px;
    margin-bottom: -40px;
    animation: fadeUp 0.8s ease 0.1s both, float 5s ease-in-out 1s infinite;
}

.logo img {
    width: 190px;
    height: auto;
    transition: transform 0.3s ease;
}

.logo img:hover {
    transform: scale(1.05);
}

.title {
    text-align: center;
    font-weight: 700;
    font-size: 23px;
    letter-spacing: .2px;
    line-height: 1.35;
    margin-bottom: 10px;
    animation: fadeUp 0.6s ease 0.15s both;
}

.title .to {
    display: block;
    color: var(--accent);
    background: var(--accent-gradient);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
    font-weight: 800;
}

.forgot-subtitle {
    color: var(--muted);
    font-size: 13px;
    font-weight: 600;
    line-height: 1.7;
    margin-bottom: 20px;
    text-align: center;
}

.field {
    margin-top: 14px;
}

.forgot-hint {
    color: var(--muted);
    font-size: 12px;
    font-weight: 500;
    line-height: 1.6;
    margin-top: 8px;
}

.control {
    position: relative;
}

.input {
    width: 100%;
    height: var(--h);
    border-radius: var(--r2);
    border: 1px solid var(--border);
    background: #f9fbfa;
    color: var(--text);
    outline: none;
    padding: 0 16px;
    font-size: 16px;
    font-weight: 500;
    text-align: start;
    transition: var(--transition);
}

.input::placeholder {
    color: #8a948e;
    font-weight: 400;
}

.input:focus {
    border-color: var(--accent);
    background: #ffffff;
    box-shadow: var(--ring);
    transform: translateY(-2px);
}

.input-pass {
    background: var(--soft);
    border-color: #e7ece8;
}

.hasToggle .input {
    padding-inline-end: 52px;
}

.toggle {
    position: absolute;
    top: 50%;
    inset-inline-end: 12px;
    transform: translateY(-50%);
    width: 40px;
    height: 40px;
    border-radius: 12px;
    border: 0;
    background: transparent;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: var(--transition);
    z-index: 2;
}

.toggle:hover {
    background: rgba(8, 145, 178, .08);
}

.toggle:active {
    transform: translateY(-50%) scale(.98);
}

.toggle i {
    color: var(--accent);
    font-size: 14px;
}

.row {
    display: flex;
    align-items: center;
    justify-content: flex-start;
    margin-top: 14px;
}

.remember {
    display: flex;
    align-items: center;
    gap: 10px;
    color: var(--muted);
    font-weight: 600;
    user-select: none;
    cursor: pointer;
}

.remember input {
    width: 18px;
    height: 18px;
    accent-color: var(--accent);
    cursor: pointer;
}

.btn {
    width: 100%;
    height: 58px;
    margin-top: 20px;
    border: none;
    border-radius: 18px;
    color: #ffffff;
    font-weight: 700;
    font-size: 16px;
    cursor: pointer;
    background: var(--accent-gradient);
    box-shadow: var(--shadow-btn);
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    transition: var(--transition);
    position: relative;
    overflow: hidden;
    letter-spacing: 0.3px;
}

.btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, .2), transparent);
    transition: 0.5s;
}

.btn:hover {
    filter: brightness(1.08);
    transform: translateY(-3px) scale(1.01);
    box-shadow: 0 15px 30px -5px rgba(8, 145, 178, 0.45);
}

.btn:hover::before {
    left: 100%;
}

.btn:active {
    transform: translateY(0);
}

.btn[disabled] {
    opacity: .65;
    cursor: not-allowed;
    filter: grayscale(.15);
    transform: none !important;
}

.skip-link {
    position: fixed;
    inset-block-start: 10px;
    inset-inline-start: 10px;
    z-index: 10001;
    min-height: 40px;
    padding: 10px 14px;
    border-radius: 12px;
    background: var(--accent);
    color: #fff;
    font-weight: 700;
    text-decoration: none;
    transform: translateY(-140%);
    transition: transform .2s ease;
}

.skip-link:focus {
    transform: translateY(0);
}

.spinner {
    width: 18px;
    height: 18px;
    border-radius: 50%;
    border: 2px solid rgba(255, 255, 255, .45);
    border-top-color: #fff;
    display: none;
    animation: spin 1s linear infinite;
}

.btn.isLoading .spinner {
    display: inline-block;
}

.btn__loading[hidden] {
    display: none;
}

.btn__loading {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    margin-inline-start: 5px;
}

.change-password-card {
    padding-block-end: 26px;
}

.change-password-note {
    text-align: center;
}

.password-meter[hidden],
.password-strength-text[hidden] {
    display: none;
}

.password-meter {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 6px;
    margin-top: 10px;
}

.password-meter__bar {
    height: 6px;
    border-radius: 999px;
    background: #dbe8ec;
    transition: background-color .2s ease, opacity .2s ease;
}

.password-meter[data-strength="1"] .password-meter__bar:nth-child(1) {
    background: var(--error);
}

.password-meter[data-strength="2"] .password-meter__bar:nth-child(-n+2) {
    background: var(--warning);
}

.password-meter[data-strength="3"] .password-meter__bar {
    background: var(--success);
}

.password-strength-text {
    margin-top: 7px;
    font-size: 13px;
    font-weight: 700;
    text-align: start;
}

.password-strength-text.weak {
    color: var(--error);
}

.password-strength-text.medium {
    color: var(--warning);
}

.password-strength-text.strong {
    color: var(--success);
}

@keyframes spin {
    to {
        transform: rotate(360deg);
    }
}

.forgot {
    text-align: center;
    margin-top: 12px;
}

.forgot a {
    color: var(--ink);
    font-weight: 700;
    text-decoration: none;
    position: relative;
    transition: var(--transition);
}

.forgot a::after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--accent);
    transition: width 0.3s ease;
}

.forgot a:hover::after {
    width: 100%;
}

.forgot a:hover {
    color: var(--accent);
}

.auth-switch {
    display: flex;
    align-items: center;
    justify-content: center;
    flex-wrap: wrap;
    gap: 7px;
    color: var(--muted);
    font-size: 13px;
    font-weight: 600;
    line-height: 1.6;
}

.signup-wrap {
    width: min(520px, 100%);
}

.signup-card {
    padding-block-end: 26px;
}

.signup-card .logo {
    margin-top: 0;
    margin-bottom: 18px;
    min-height: 116px;
    align-items: center;
    animation: fadeUp 0.8s ease 0.1s both;
}

.signup-card .logo img {
    width: min(148px, 42vw);
    height: 116px;
    object-fit: contain;
}

.signup-card .title {
    margin-top: 0;
}

.signup-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0 12px;
}

.signup-card .field {
    margin-top: 12px;
}

.signup-card .btn {
    margin-top: 18px;
}

.ltr {
    direction: ltr;
    text-align: left;
}

html[dir="rtl"] .ltr {
    text-align: right;
}

.err[hidden] {
    display: none;
}

.err {
    margin-top: 8px;
    padding: 10px 12px;
    border-radius: 12px;
    border: 1px solid #fecaca;
    background: #fff7ed;
    color: #9a3412;
    font-weight: 600;
    font-size: 13px;
    animation: shake 0.5s ease;
}

.err--success {
    border-color: #34d399;
    background: #d1fae5;
    color: #065f46;
}

.login-alert[hidden] {
    display: none;
}

.login-alert {
    position: fixed;
    inset: 0;
    z-index: 10000;
    display: grid;
    place-items: center;
    padding: 20px;
    background: rgba(5, 20, 24, .44);
}

.login-alert__panel {
    width: min(360px, 100%);
    border: 1px solid rgba(8, 145, 178, .16);
    border-radius: 20px;
    background: var(--card);
    box-shadow: var(--shadow-lg);
    padding: 24px;
    text-align: center;
}

.login-alert__title {
    color: var(--text);
    font-size: 20px;
    line-height: 1.35;
    margin-bottom: 10px;
}

.login-alert__message {
    color: var(--muted);
    font-size: 15px;
    line-height: 1.65;
    margin-bottom: 20px;
}

.login-alert__button {
    min-width: 128px;
    height: 44px;
    border: 0;
    border-radius: 14px;
    color: #fff;
    background: var(--accent-gradient);
    font-weight: 700;
    cursor: pointer;
}

.login-offline {
    background: linear-gradient(180deg, #071c22 0%, #040f13 100%);
}

.offline-card {
    width: min(380px, calc(100vw - 32px));
    border: 1px solid rgba(255, 255, 255, .12);
    border-radius: 24px;
    background: rgba(255, 255, 255, .08);
    box-shadow: 0 20px 60px rgba(0, 0, 0, .32);
    color: #fff;
    padding: 42px 30px;
    text-align: center;
}

.offline-icon {
    width: 56px;
    height: 56px;
    display: grid;
    place-items: center;
    margin: 0 auto 16px;
    border-radius: 50%;
    background: #0891b2;
    color: #fff;
    font-size: 30px;
    font-weight: 800;
}

.offline-card h1 {
    font-size: 24px;
    line-height: 1.35;
    margin-bottom: 10px;
}

.offline-card p {
    color: #b6c9cf;
    font-size: 15px;
    line-height: 1.65;
    margin-bottom: 24px;
}

.offline-retry {
    width: 100%;
    min-height: 48px;
    border: 0;
    border-radius: 14px;
    background: var(--accent-gradient);
    color: #fff;
    font-size: 16px;
    font-weight: 700;
    cursor: pointer;
}

@keyframes shake {

    0%,
    100% {
        transform: translateX(0);
    }

    20%,
    60% {
        transform: translateX(-5px);
    }

    40%,
    80% {
        transform: translateX(5px);
    }
}




/* نافذة التحميل */
#loading-overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(5px);
    -webkit-backdrop-filter: blur(5px);
    align-items: center;
    justify-content: center;
    z-index: 9999;
    animation: fadeIn 0.3s ease;
}

.loading-content {
    text-align: center;
    animation: floatIn 0.5s ease;
}

.loading-spinner {
    width: 60px;
    height: 60px;
    margin: 0 auto 20px;
}

.loading-spinner svg {
    width: 100%;
    height: 100%;
    animation: rotate 2s linear infinite;
}

.loading-text {
    font-weight: 600;
    color: var(--text);
    font-size: 16px;
}

/* زر التثبيت */
#install-button {
    position: fixed;
    bottom: 20px;
    right: 20px;
    background: var(--accent-gradient);
    color: white;
    border: none;
    border-radius: 50px;
    padding: 12px 24px;
    font-weight: 600;
    cursor: pointer;
    box-shadow: 0 4px 15px rgba(8, 145, 178, .3);
    display: none;
    z-index: 1000;
    transition: var(--transition);
}

#install-button:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(8, 145, 178, .4);
}

#install-button i {
    margin-right: 8px;
}

/* فاحص الاتصال */
#connection-checker {
    visibility: hidden;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(255, 255, 255, 0.98);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 9998;
}

.connection-content {
    text-align: center;
    max-width: 90%;
}

.connection-spinner {
    width: 50px;
    height: 50px;
    border: 3px solid #cff8fe;
    border-top-color: var(--accent);
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin: 0 auto 20px;
}

.reconnect {
    border: none;
    outline: none;
    color: #fff;
    cursor: pointer;
    font-weight: 500;
    font-size: 0.95rem;
    padding: 12px 24px;
    border-radius: 50px;
    background: var(--accent-gradient);
    margin-top: 20px;
    transition: var(--transition);
}

.reconnect:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 15px rgba(8, 145, 178, .3);
}

/* أنيميشن */
@keyframes floatIn {
    from {
        opacity: 0;
        transform: translateY(16px) scale(0.95);
    }

    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

@keyframes fadeUp {
    from {
        opacity: 0;
        transform: translateY(8px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes fadeIn {
    from {
        opacity: 0;
    }

    to {
        opacity: 1;
    }
}

@keyframes rotate {
    from {
        transform: rotate(0deg);
    }

    to {
        transform: rotate(360deg);
    }
}

/* الطباعة */
@media print {
    .card {
        box-shadow: none;
        border: 1px solid #ddd;
    }

    .btn,
    .toggle,
    #install-button {
        display: none !important;
    }
}

/* الأجهزة الصغيرة */
@media (max-width: 420px) {
    body {
        padding: 16px;
    }

    .logo img {
        width: 170px;
    }

    .title {
        font-size: 22px;
    }

    .card {
        padding: 22px 18px 18px;
    }

    .signup-grid {
        grid-template-columns: 1fr;
        gap: 0;
    }

    #install-button {
        bottom: 10px;
        right: 10px;
        padding: 10px 20px;
        font-size: 14px;
    }
}

/* الوضع الداكن */
@media (prefers-color-scheme: dark) {
    :root {
        --bg: #061a1e;
        --card: #0a2328;
        --text: #e0f9fd;
        --muted: #7ec8d8;
        --border: rgba(8, 145, 178, .25);
        --soft: rgba(255, 255, 255, .05);
        --shadow-lg: 0 18px 50px rgba(0, 20, 30, .65);
    }

    body {
        background:
            radial-gradient(800px 500px at 12% -10%, rgba(8, 145, 178, .17), transparent 60%),
            linear-gradient(180deg, #071c22 0%, #040f13 100%);
    }

    .input {
        background: rgba(255, 255, 255, .04);
        color: var(--text);
    }

    .input::placeholder {
        color: rgba(226, 232, 240, .55);
    }

    .input-pass {
        background: rgba(255, 255, 255, .06);
    }

    .btn {
        color: #ffffff;
    }

    .forgot a {
        color: #dfe6e1;
    }

    #loading-overlay {
        background: rgba(13, 20, 16, 0.95);
    }

    #connection-checker {
        background: rgba(13, 20, 16, 0.98);
    }
}

html[data-theme="dark"] {
    --bg: #061a1e;
    --card: #0a2328;
    --text: #e0f9fd;
    --muted: #7ec8d8;
    --border: rgba(8, 145, 178, .25);
    --soft: rgba(255, 255, 255, .05);
    --shadow-lg: 0 18px 50px rgba(0, 20, 30, .65);
}

html[data-theme="dark"] body {
    background:
        radial-gradient(800px 500px at 12% -10%, rgba(8, 145, 178, .17), transparent 60%),
        linear-gradient(180deg, #071c22 0%, #040f13 100%);
}

html[data-theme="dark"] .input {
    background: rgba(255, 255, 255, .04);
    color: var(--text);
}

html[data-theme="dark"] .input::placeholder {
    color: rgba(226, 232, 240, .55);
}

html[data-theme="dark"] .input-pass {
    background: rgba(255, 255, 255, .06);
}

html[data-theme="dark"] .forgot a {
    color: #dfe6e1;
}

@keyframes float {

    0%,
    100% {
        transform: translateY(0);
    }

    50% {
        transform: translateY(-8px);
    }
}



/* تقليل الحركة */
@media (prefers-reduced-motion: reduce) {

    *,
    :before,
    :after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
}

/* عالي التباين */
@media (prefers-contrast: high) {
    :root {
        --accent: #006080;
        --accent-2: #004d66;
        --border: #000000;
    }
}

/* إمكانية الوصول */
.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

.input:focus-visible {
    outline: 2px solid var(--accent);
    outline-offset: 2px;
}

.btn:focus-visible {
    outline: 2px solid var(--accent);
    outline-offset: 2px;
}

/* Login page v8: serious clinical auth surface */
body[data-login-page] {
    --login-ink: #10262e;
    --login-text: #314a55;
    --login-muted: #647b85;
    --login-line: rgba(18, 99, 115, .16);
    --login-line-strong: rgba(8, 137, 150, .34);
    --login-surface: rgba(255, 255, 255, .98);
    --login-soft: #f3fafb;
    --login-soft-2: #e8f7f9;
    --login-primary: #078996;
    --login-primary-dark: #076d78;
    --login-danger: #dc2626;
    --login-shadow: 0 24px 70px rgba(15, 64, 72, .12);
    min-height: 100dvh;
    padding: 24px;
    display: grid;
    place-items: center;
    overflow-x: hidden;
    background:
        radial-gradient(circle at 12% -10%, rgba(8, 137, 150, .13), transparent 300px),
        radial-gradient(circle at 90% 106%, rgba(15, 159, 122, .10), transparent 340px),
        linear-gradient(180deg, #ffffff 0%, #f4fafb 45%, #eef8fa 100%);
    color: var(--login-text);
}

body[data-login-page]::before {
    content: "";
    position: fixed;
    inset: 0;
    z-index: 0;
    background-image:
        linear-gradient(rgba(8, 137, 150, .055) 1px, transparent 1px),
        linear-gradient(90deg, rgba(8, 137, 150, .045) 1px, transparent 1px);
    background-size: 34px 34px;
    mask-image: linear-gradient(180deg, rgba(0, 0, 0, .54), transparent 82%);
    pointer-events: none;
}

body[data-login-page] main {
    width: 100%;
    position: relative;
    z-index: 1;
}

body[data-login-page] .wrap {
    width: min(920px, 100%);
    padding: 0;
    animation: none;
}

body[data-login-page] .card {
    width: 100%;
    min-height: 520px;
    display: grid;
    grid-template-columns: minmax(280px, .9fr) minmax(320px, 420px);
    align-items: stretch;
    gap: 0;
    padding: 0;
    border: 1px solid var(--login-line);
    border-radius: 24px;
    background: var(--login-surface);
    box-shadow: var(--login-shadow);
    overflow: hidden;
    backdrop-filter: blur(18px);
    -webkit-backdrop-filter: blur(18px);
}

body[data-login-page] .card::before {
    inset: 0 auto 0 0;
    width: 40%;
    height: auto;
    background:
        linear-gradient(135deg, rgba(7, 137, 150, .96), rgba(7, 109, 120, .96)),
        radial-gradient(circle at 24% 18%, rgba(255, 255, 255, .22), transparent 220px);
}

[dir="rtl"] body[data-login-page] .card::before {
    inset: 0 0 0 auto;
}

body[data-login-page] .card::after {
    content: "Mustshar Cloud";
    position: absolute;
    inset-block: 0;
    inset-inline-start: 0;
    width: 40%;
    padding: 44px 36px;
    display: flex;
    align-items: flex-end;
    color: rgba(255, 255, 255, .92);
    font-size: 28px;
    font-weight: 950;
    line-height: 1.18;
    background:
        radial-gradient(circle at 22% 16%, rgba(255, 255, 255, .16), transparent 180px),
        linear-gradient(180deg, transparent 0%, rgba(4, 43, 50, .18) 100%);
    pointer-events: none;
}

[dir="rtl"] body[data-login-page] .card::after {
    inset-inline-start: auto;
    inset-inline-end: 0;
}

body[data-login-page] .card > * {
    z-index: 2;
}

body[data-login-page] .logo,
body[data-login-page] .title,
body[data-login-page] form {
    grid-column: 2;
}

[dir="rtl"] body[data-login-page] .logo,
[dir="rtl"] body[data-login-page] .title,
[dir="rtl"] body[data-login-page] form {
    grid-column: 1;
}

body[data-login-page] .logo {
    align-self: end;
    justify-content: center;
    margin: 0;
    padding: 42px 40px 10px;
    min-height: 120px;
    animation: none;
}

body[data-login-page] .logo img {
    width: min(132px, 42vw);
    max-height: 104px;
    object-fit: contain;
    filter: drop-shadow(0 10px 18px rgba(15, 64, 72, .08));
}

body[data-login-page] .logo img:hover {
    transform: none;
}

body[data-login-page] .card br {
    display: none;
}

body[data-login-page] .title {
    margin: 0;
    padding: 0 42px 14px;
    color: var(--login-ink);
    font-size: 26px;
    font-weight: 950;
    line-height: 1.25;
    letter-spacing: 0;
    text-align: center;
    animation: none;
}

body[data-login-page] .title .to {
    margin-top: 2px;
    color: var(--login-primary);
    background: none;
    -webkit-background-clip: initial;
    background-clip: initial;
}

body[data-login-page] #edit-form-login {
    padding: 0 42px 42px;
}

body[data-login-page] .field {
    margin: 0 0 12px;
}

body[data-login-page] .input {
    height: 50px;
    border: 1px solid var(--login-line);
    border-radius: 14px;
    background: var(--login-soft);
    color: var(--login-ink);
    padding: 0 15px;
    font-size: 14px;
    font-weight: 800;
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, .76);
    transform: none;
}

body[data-login-page] .input-pass {
    background: var(--login-soft);
    border-color: var(--login-line);
}

body[data-login-page] .input::placeholder {
    color: #7d9199;
    font-weight: 750;
}

body[data-login-page] .input:focus {
    border-color: var(--login-line-strong);
    background: #fff;
    box-shadow: 0 0 0 4px rgba(8, 137, 150, .105);
    transform: none;
}

body[data-login-page] .hasToggle .input {
    padding-inline-end: 54px;
}

body[data-login-page] .toggle {
    width: 38px;
    height: 38px;
    inset-inline-end: 8px;
    border-radius: 12px;
    color: var(--login-primary);
    background: transparent;
}

body[data-login-page] .toggle:hover,
body[data-login-page] .toggle:focus-visible {
    background: var(--login-soft-2);
}

body[data-login-page] .row {
    margin: 2px 0 0;
}

body[data-login-page] .remember {
    width: 100%;
    min-height: 40px;
    padding: 8px 10px;
    border: 1px solid var(--login-line);
    border-radius: 13px;
    background: #fbfefe;
    color: var(--login-muted);
    font-size: 12.5px;
    font-weight: 850;
}

body[data-login-page] .remember input {
    width: 17px;
    height: 17px;
    accent-color: var(--login-primary);
}

body[data-login-page] .btn {
    height: 50px;
    margin-top: 14px;
    border-radius: 14px;
    background: linear-gradient(180deg, #0797a6, var(--login-primary-dark));
    box-shadow: 0 14px 28px rgba(7, 137, 150, .20);
    font-size: 14px;
    font-weight: 950;
    letter-spacing: 0;
}

body[data-login-page] .btn::before {
    display: none;
}

body[data-login-page] .btn:hover,
body[data-login-page] .btn:focus-visible {
    filter: none;
    transform: translateY(-1px);
    box-shadow: 0 18px 36px rgba(7, 137, 150, .24);
}

body[data-login-page] .forgot {
    margin-top: 12px;
}

body[data-login-page] .forgot a {
    color: var(--login-primary-dark);
    font-size: 12.5px;
    font-weight: 900;
}

body[data-login-page] .auth-switch {
    margin-top: 14px;
    padding-top: 14px;
    border-top: 1px solid var(--login-line);
    color: var(--login-muted);
    font-size: 12.5px;
    font-weight: 800;
}

body[data-login-page] .err {
    margin-top: 7px;
    padding: 8px 10px;
    border-radius: 11px;
    border-color: rgba(220, 38, 38, .18);
    background: #fff7f7;
    color: #b91c1c;
    font-size: 12px;
    font-weight: 850;
}

body[data-login-page] .login-alert {
    background: rgba(4, 29, 35, .52);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
}

body[data-login-page] .login-alert__panel {
    width: min(380px, calc(100vw - 32px));
    border: 1px solid var(--login-line);
    border-radius: 20px;
    background: #fff;
    box-shadow: 0 24px 64px rgba(15, 64, 72, .22);
}

body[data-login-page] .login-alert__title {
    color: var(--login-ink);
    font-weight: 950;
}

body[data-login-page] .login-alert__button {
    border-radius: 13px;
    background: linear-gradient(180deg, #0797a6, var(--login-primary-dark));
    font-weight: 950;
}

html[data-theme="dark"] body[data-login-page],
[data-theme="dark"] body[data-login-page] {
    --login-ink: #eef9fb;
    --login-text: #d4e8ee;
    --login-muted: #9bb3bc;
    --login-line: rgba(128, 186, 199, .22);
    --login-line-strong: rgba(128, 186, 199, .38);
    --login-surface: rgba(17, 28, 42, .96);
    --login-soft: #111d2b;
    --login-soft-2: #13283a;
    background:
        radial-gradient(circle at 12% -10%, rgba(8, 137, 150, .18), transparent 300px),
        linear-gradient(180deg, #0e1724 0%, #101827 100%);
}

html[data-theme="dark"] body[data-login-page] .card,
[data-theme="dark"] body[data-login-page] .card,
html[data-theme="dark"] body[data-login-page] .input,
[data-theme="dark"] body[data-login-page] .input,
html[data-theme="dark"] body[data-login-page] .remember,
[data-theme="dark"] body[data-login-page] .remember,
html[data-theme="dark"] body[data-login-page] .login-alert__panel,
[data-theme="dark"] body[data-login-page] .login-alert__panel {
    background: var(--login-surface);
}

html[data-theme="dark"] body[data-login-page] .input:focus,
[data-theme="dark"] body[data-login-page] .input:focus {
    background: #152235;
}

@media (max-width: 820px) {
    body[data-login-page] {
        padding: 16px;
    }

    body[data-login-page] .wrap {
        width: min(440px, 100%);
    }

    body[data-login-page] .card {
        min-height: 0;
        display: block;
        border-radius: 22px;
    }

    body[data-login-page] .card::before,
    body[data-login-page] .card::after {
        display: none;
    }

    body[data-login-page] .logo {
        min-height: auto;
        padding: 30px 28px 10px;
    }

    body[data-login-page] .logo img {
        width: 126px;
        max-height: 96px;
    }

    body[data-login-page] .title {
        padding: 0 28px 14px;
        font-size: 23px;
    }

    body[data-login-page] #edit-form-login {
        padding: 0 28px 30px;
    }
}

@media (max-width: 420px) {
    body[data-login-page] {
        padding: 10px;
    }

    body[data-login-page] .wrap {
        width: 100%;
    }

    body[data-login-page] .card {
        border-radius: 18px;
    }

    body[data-login-page] .logo {
        padding: 22px 20px 8px;
    }

    body[data-login-page] .logo img {
        width: 112px;
        max-height: 84px;
    }

    body[data-login-page] .title {
        padding: 0 20px 12px;
        font-size: 20px;
    }

    body[data-login-page] #edit-form-login {
        padding: 0 18px 22px;
    }

    body[data-login-page] .input,
    body[data-login-page] .btn {
        height: 48px;
    }
}

/* Login page v9: compact clinical card, no split panel */
body[data-login-page] {
    --login-ink: #10232a;
    --login-text: #2d4650;
    --login-muted: #607681;
    --login-line: rgba(9, 111, 128, .18);
    --login-line-strong: rgba(7, 137, 150, .42);
    --login-surface: rgba(255, 255, 255, .98);
    --login-soft: #f5fbfc;
    --login-soft-2: #e8f7f9;
    --login-primary: #078996;
    --login-primary-dark: #056b76;
    --login-shadow: 0 26px 70px rgba(17, 76, 88, .14);
    min-height: 100dvh;
    padding: 28px 16px;
    display: flex !important;
    align-items: center;
    justify-content: center;
    background:
        radial-gradient(circle at 50% 10%, rgba(8, 137, 150, .10), transparent 340px),
        linear-gradient(180deg, #ffffff 0%, #f7fbfc 52%, #edf8fa 100%);
    color: var(--login-text);
}

body[data-login-page]::before {
    opacity: .48;
    background-image:
        linear-gradient(rgba(8, 137, 150, .045) 1px, transparent 1px),
        linear-gradient(90deg, rgba(8, 137, 150, .035) 1px, transparent 1px);
    background-size: 36px 36px;
    mask-image: linear-gradient(180deg, rgba(0, 0, 0, .45), transparent 82%);
}

body[data-login-page] main {
    width: 100%;
    min-height: calc(100dvh - 56px);
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    z-index: 1;
}

body[data-login-page] .wrap {
    width: min(430px, 100%);
    max-width: 430px;
    padding: 0;
}

body[data-login-page] .card {
    position: relative;
    width: 100%;
    min-height: 0;
    display: block !important;
    padding: 0;
    overflow: hidden;
    border: 1px solid var(--login-line);
    border-radius: 26px;
    background:
        linear-gradient(180deg, rgba(255, 255, 255, .99), rgba(250, 254, 255, .98));
    box-shadow: var(--login-shadow);
    text-align: center;
    backdrop-filter: blur(14px);
    -webkit-backdrop-filter: blur(14px);
}

body[data-login-page] .card::before {
    content: "";
    position: absolute;
    inset: 0 0 auto;
    width: 100% !important;
    height: 5px !important;
    display: block !important;
    background: linear-gradient(90deg, #0a8f9b, #0bb3c2, #08717c);
    pointer-events: none;
}

body[data-login-page] .card::after {
    display: none !important;
    content: none !important;
}

body[data-login-page] .card > * {
    position: relative;
    z-index: 1;
}

body[data-login-page] .logo,
body[data-login-page] .title,
body[data-login-page] form,
[dir="rtl"] body[data-login-page] .logo,
[dir="rtl"] body[data-login-page] .title,
[dir="rtl"] body[data-login-page] form {
    grid-column: auto !important;
}

body[data-login-page] .logo {
    min-height: 0;
    margin: 0;
    padding: 34px 34px 8px;
    display: flex;
    align-items: center;
    justify-content: center;
}

body[data-login-page] .logo img {
    width: 120px;
    max-width: 44vw;
    max-height: 92px;
    object-fit: contain;
    filter: drop-shadow(0 10px 18px rgba(15, 64, 72, .08));
}

body[data-login-page] .card br {
    display: none !important;
}

body[data-login-page] .title {
    margin: 0;
    padding: 0 34px 16px;
    color: var(--login-ink);
    font-size: 27px;
    font-weight: 950;
    line-height: 1.22;
    letter-spacing: 0;
    text-align: center;
}

body[data-login-page] .title .to {
    display: block;
    margin-top: 2px;
    color: var(--login-primary);
    font-size: 22px;
    font-weight: 950;
}

body[data-login-page] .title::after {
    content: "دخول آمن لحسابك";
    display: block;
    margin-top: 10px;
    color: var(--login-muted);
    font-size: 13px;
    font-weight: 800;
    line-height: 1.6;
}

body[data-login-page] #edit-form-login {
    padding: 0 34px 34px;
}

body[data-login-page] .field {
    margin: 0 0 12px;
}

body[data-login-page] .control {
    position: relative;
}

body[data-login-page] .input {
    width: 100%;
    height: 52px;
    border: 1px solid var(--login-line);
    border-radius: 15px;
    background: #fff;
    color: var(--login-ink);
    padding: 0 15px;
    font-size: 14px;
    font-weight: 850;
    box-shadow: 0 1px 0 rgba(255, 255, 255, .84), inset 0 1px 0 rgba(255, 255, 255, .72);
    transition: border-color .16s ease, box-shadow .16s ease, background .16s ease;
    transform: none !important;
}

body[data-login-page] .input::placeholder {
    color: #788e98;
    font-weight: 760;
}

body[data-login-page] .input:focus {
    border-color: var(--login-line-strong);
    background: #fff;
    box-shadow: 0 0 0 4px rgba(8, 137, 150, .105);
    outline: 0;
}

body[data-login-page] .hasToggle .input {
    padding-inline-end: 54px;
}

body[data-login-page] .toggle {
    width: 38px;
    height: 38px;
    inset-inline-end: 8px;
    border: 0;
    border-radius: 12px;
    color: var(--login-primary);
    background: transparent;
}

body[data-login-page] .toggle:hover,
body[data-login-page] .toggle:focus-visible {
    background: var(--login-soft-2);
}

body[data-login-page] .row {
    margin: 2px 0 0;
    display: block;
}

body[data-login-page] .remember {
    width: 100%;
    min-height: 42px;
    padding: 9px 11px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 9px;
    border: 1px solid var(--login-line);
    border-radius: 14px;
    background: var(--login-soft);
    color: var(--login-muted);
    font-size: 12.5px;
    font-weight: 850;
}

body[data-login-page] .remember input {
    width: 17px;
    height: 17px;
    accent-color: var(--login-primary);
}

body[data-login-page] .btn {
    width: 100%;
    height: 52px;
    margin-top: 14px;
    border: 0;
    border-radius: 15px;
    background: linear-gradient(180deg, #0799a8, var(--login-primary-dark));
    color: #fff;
    box-shadow: 0 14px 28px rgba(7, 137, 150, .22);
    font-size: 14px;
    font-weight: 950;
    letter-spacing: 0;
}

body[data-login-page] .btn::before {
    display: none !important;
}

body[data-login-page] .btn:hover,
body[data-login-page] .btn:focus-visible {
    filter: none;
    transform: translateY(-1px);
    box-shadow: 0 18px 34px rgba(7, 137, 150, .25);
}

body[data-login-page] .forgot {
    margin-top: 12px;
    text-align: center;
}

body[data-login-page] .forgot a {
    color: var(--login-primary-dark);
    font-size: 12.5px;
    font-weight: 900;
    text-decoration: none;
}

body[data-login-page] .forgot a:hover,
body[data-login-page] .forgot a:focus-visible {
    text-decoration: underline;
}

body[data-login-page] .auth-switch {
    margin-top: 14px;
    padding-top: 14px;
    border-top: 1px solid var(--login-line);
    color: var(--login-muted);
    font-size: 12.5px;
    font-weight: 800;
}

body[data-login-page] .auth-switch span {
    display: inline-block;
    margin-inline-end: 5px;
}

body[data-login-page] .err {
    margin-top: 7px;
    padding: 8px 10px;
    border-radius: 11px;
    border: 1px solid rgba(220, 38, 38, .18);
    background: #fff7f7;
    color: #b91c1c;
    font-size: 12px;
    font-weight: 850;
}

html[data-theme="dark"] body[data-login-page],
[data-theme="dark"] body[data-login-page] {
    --login-ink: #eef9fb;
    --login-text: #d4e8ee;
    --login-muted: #9bb3bc;
    --login-line: rgba(128, 186, 199, .24);
    --login-line-strong: rgba(128, 186, 199, .40);
    --login-surface: rgba(17, 28, 42, .98);
    --login-soft: #121f2e;
    --login-soft-2: #172b3d;
    background:
        radial-gradient(circle at 50% 8%, rgba(8, 137, 150, .18), transparent 320px),
        linear-gradient(180deg, #0e1724 0%, #101827 100%);
}

html[data-theme="dark"] body[data-login-page] .card,
[data-theme="dark"] body[data-login-page] .card,
html[data-theme="dark"] body[data-login-page] .input,
[data-theme="dark"] body[data-login-page] .input,
html[data-theme="dark"] body[data-login-page] .login-alert__panel,
[data-theme="dark"] body[data-login-page] .login-alert__panel {
    background: var(--login-surface);
}

html[data-theme="dark"] body[data-login-page] .remember,
[data-theme="dark"] body[data-login-page] .remember {
    background: var(--login-soft);
}

@media (max-width: 520px) {
    body[data-login-page] {
        padding: 12px;
        align-items: center;
    }

    body[data-login-page] main {
        min-height: calc(100dvh - 24px);
    }

    body[data-login-page] .wrap {
        width: 100%;
    }

    body[data-login-page] .card {
        border-radius: 22px;
    }

    body[data-login-page] .logo {
        padding: 28px 24px 8px;
    }

    body[data-login-page] .logo img {
        width: 108px;
        max-height: 82px;
    }

    body[data-login-page] .title {
        padding: 0 24px 14px;
        font-size: 23px;
    }

    body[data-login-page] .title .to {
        font-size: 19px;
    }

    body[data-login-page] #edit-form-login {
        padding: 0 20px 26px;
    }

    body[data-login-page] .input,
    body[data-login-page] .btn {
        height: 50px;
    }
}

/* Login page v10: professional form controls */
body[data-login-page] .login-field {
    margin: 0 0 14px;
    text-align: start;
}

body[data-login-page] .login-label {
    position: static !important;
    width: auto !important;
    height: auto !important;
    padding: 0 !important;
    margin: 0 2px 7px !important;
    overflow: visible !important;
    clip: auto !important;
    white-space: normal !important;
    border: 0 !important;
    display: block;
    color: #395865;
    font-size: 12.5px;
    font-weight: 900;
    line-height: 1.5;
}

body[data-login-page] .control {
    position: relative;
}

body[data-login-page] .control::before {
    position: absolute;
    inset-inline-start: 13px;
    top: 50%;
    z-index: 2;
    width: 30px;
    height: 30px;
    display: grid;
    place-items: center;
    border-radius: 10px;
    background: #edf9fb;
    color: var(--login-primary);
    font-family: "Font Awesome 7 Free", "Font Awesome 5 Free", FontAwesome;
    font-size: 13px;
    font-weight: 900;
    line-height: 1;
    transform: translateY(-50%);
    pointer-events: none;
}

body[data-login-page] .control-email::before {
    content: "\f3cd";
}

body[data-login-page] .control-password::before {
    content: "\f023";
}

body[data-login-page] .input,
body[data-login-page] .input-pass {
    height: 54px;
    padding-inline-start: 54px;
    padding-inline-end: 16px;
    border: 1px solid #c8e7ee;
    border-radius: 16px;
    background:
        linear-gradient(180deg, #ffffff 0%, #fbfdfe 100%);
    color: var(--login-ink);
    text-align: start;
    direction: inherit;
    font-size: 14.5px;
    font-weight: 850;
    box-shadow:
        0 1px 0 rgba(255, 255, 255, .9),
        0 8px 20px rgba(12, 98, 112, .045),
        inset 0 1px 0 rgba(255, 255, 255, .86);
}

body[data-login-page] .hasToggle .input {
    padding-inline-start: 54px;
    padding-inline-end: 58px;
}

body[data-login-page] .input:hover {
    border-color: rgba(8, 137, 150, .42);
    background: #fff;
}

body[data-login-page] .input:focus {
    border-color: #078996;
    background: #fff;
    box-shadow:
        0 0 0 4px rgba(8, 137, 150, .12),
        0 10px 22px rgba(12, 98, 112, .08);
}

body[data-login-page] .input::placeholder {
    color: #8da0a8;
    font-size: 13.5px;
    font-weight: 750;
}

body[data-login-page] .toggle {
    right: auto;
    left: auto;
    inset-inline-end: 9px;
    top: 50%;
    z-index: 3;
    width: 38px;
    height: 38px;
    display: grid;
    place-items: center;
    border: 1px solid transparent;
    border-radius: 12px;
    color: #087f8c;
    background: transparent;
    transform: translateY(-50%);
}

body[data-login-page] .toggle:hover,
body[data-login-page] .toggle:focus-visible {
    border-color: #c8e7ee;
    background: #edf9fb;
}

body[data-login-page] .hasToggle.control-password::before {
    display: none;
}

body[data-login-page] .hasToggle .input {
    padding-inline-start: 16px;
}

body[data-login-page] .remember {
    justify-content: space-between;
    padding: 10px 13px;
    border-color: #cce8ee;
    background: #f8fcfd;
    text-align: start;
}

body[data-login-page] .remember input {
    appearance: none;
    -webkit-appearance: none;
    flex: 0 0 auto;
    width: 19px;
    height: 19px;
    margin: 0;
    border: 1.5px solid #9bc9d2;
    border-radius: 6px;
    background: #fff;
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, .85);
}

body[data-login-page] .remember input:checked {
    border-color: var(--login-primary);
    background:
        linear-gradient(135deg, transparent 52%, #fff 52% 62%, transparent 62%) 6px 7px / 8px 8px no-repeat,
        linear-gradient(45deg, transparent 46%, #fff 46% 60%, transparent 60%) 4px 9px / 7px 7px no-repeat,
        var(--login-primary);
}

body[data-login-page] .err[hidden] {
    display: none !important;
}

body[data-login-page] .err:not([hidden]) {
    margin-top: 8px;
}

html[data-theme="dark"] body[data-login-page] .login-label,
[data-theme="dark"] body[data-login-page] .login-label {
    color: #bfd5dc;
}

html[data-theme="dark"] body[data-login-page] .control::before,
[data-theme="dark"] body[data-login-page] .control::before {
    background: #172b3d;
    color: #7bdbe7;
}

html[data-theme="dark"] body[data-login-page] .input,
[data-theme="dark"] body[data-login-page] .input,
html[data-theme="dark"] body[data-login-page] .input-pass,
[data-theme="dark"] body[data-login-page] .input-pass {
    border-color: rgba(128, 186, 199, .24);
    background: #101b2a;
}

html[data-theme="dark"] body[data-login-page] .remember,
[data-theme="dark"] body[data-login-page] .remember {
    border-color: rgba(128, 186, 199, .24);
    background: #121f2e;
}

@media (max-width: 520px) {
    body[data-login-page] .login-label {
        font-size: 12px;
    }

    body[data-login-page] .input,
    body[data-login-page] .input-pass {
        height: 52px;
    }
}

/* Forgot password v2: compact recovery surface */
body[data-forgot-page] {
    --forgot-ink: #10232a;
    --forgot-text: #304b55;
    --forgot-muted: #637b86;
    --forgot-line: rgba(9, 111, 128, .18);
    --forgot-line-strong: rgba(7, 137, 150, .42);
    --forgot-primary: #078996;
    --forgot-primary-dark: #056b76;
    --forgot-soft: #f5fbfc;
    --forgot-shadow: 0 26px 70px rgba(17, 76, 88, .14);
    min-height: 100dvh;
    padding: 28px 16px;
    display: flex !important;
    align-items: center;
    justify-content: center;
    overflow-x: hidden;
    background:
        radial-gradient(circle at 50% 8%, rgba(8, 137, 150, .10), transparent 340px),
        linear-gradient(180deg, #ffffff 0%, #f7fbfc 54%, #edf8fa 100%);
    color: var(--forgot-text);
}

body[data-forgot-page]::before {
    content: "";
    position: fixed;
    inset: 0;
    z-index: 0;
    background-image:
        linear-gradient(rgba(8, 137, 150, .045) 1px, transparent 1px),
        linear-gradient(90deg, rgba(8, 137, 150, .035) 1px, transparent 1px);
    background-size: 36px 36px;
    mask-image: linear-gradient(180deg, rgba(0, 0, 0, .45), transparent 82%);
    pointer-events: none;
}

body[data-forgot-page] .wrap {
    position: relative;
    z-index: 1;
    width: min(440px, 100%);
    max-width: 440px;
    padding: 0;
}

body[data-forgot-page] .card {
    position: relative;
    width: 100%;
    min-height: 0;
    padding: 0;
    overflow: hidden;
    border: 1px solid var(--forgot-line);
    border-radius: 26px;
    background: linear-gradient(180deg, rgba(255, 255, 255, .99), rgba(250, 254, 255, .98));
    box-shadow: var(--forgot-shadow);
    text-align: center;
}

body[data-forgot-page] .card::before {
    content: "";
    position: absolute;
    inset: 0 0 auto;
    width: 100%;
    height: 5px;
    display: block;
    background: linear-gradient(90deg, #0a8f9b, #0bb3c2, #08717c);
    pointer-events: none;
}

body[data-forgot-page] .logo {
    min-height: 0;
    margin: 0;
    padding: 34px 34px 8px;
    display: flex;
    align-items: center;
    justify-content: center;
}

body[data-forgot-page] .logo img {
    width: 118px;
    max-width: 44vw;
    max-height: 90px;
    object-fit: contain;
    filter: drop-shadow(0 10px 18px rgba(15, 64, 72, .08));
}

body[data-forgot-page] .title {
    margin: 0;
    padding: 0 34px 8px;
    color: var(--forgot-ink);
    font-size: 25px;
    font-weight: 950;
    line-height: 1.25;
    letter-spacing: 0;
    text-align: center;
}

body[data-forgot-page] .title .to {
    display: block;
    margin-top: 2px;
    color: var(--forgot-primary);
    font-size: 19px;
    font-weight: 950;
}

body[data-forgot-page] .forgot-subtitle {
    width: auto;
    margin: 0;
    padding: 0 34px 18px;
    color: var(--forgot-muted);
    font-size: 13.5px;
    font-weight: 800;
    line-height: 1.75;
    text-align: center;
}

body[data-forgot-page] #edit-form-login {
    padding: 0 34px 0;
}

body[data-forgot-page] .forgot-field {
    margin: 0 0 14px;
    text-align: start;
}

body[data-forgot-page] .forgot-label {
    position: static !important;
    width: auto !important;
    height: auto !important;
    padding: 0 !important;
    margin: 0 2px 7px !important;
    overflow: visible !important;
    clip: auto !important;
    white-space: normal !important;
    border: 0 !important;
    display: block;
    color: #395865;
    font-size: 12.5px;
    font-weight: 900;
    line-height: 1.5;
}

body[data-forgot-page] .control {
    position: relative;
}

body[data-forgot-page] .control::before {
    content: "\f0e0";
    position: absolute;
    inset-inline-start: 13px;
    top: 50%;
    z-index: 2;
    width: 30px;
    height: 30px;
    display: grid;
    place-items: center;
    border-radius: 10px;
    background: #edf9fb;
    color: var(--forgot-primary);
    font-family: "Font Awesome 7 Free", "Font Awesome 5 Free", FontAwesome;
    font-size: 13px;
    font-weight: 900;
    line-height: 1;
    transform: translateY(-50%);
    pointer-events: none;
}

body[data-forgot-page] .input {
    width: 100%;
    height: 54px;
    padding-inline-start: 54px;
    padding-inline-end: 16px;
    border: 1px solid #c8e7ee;
    border-radius: 16px;
    background: linear-gradient(180deg, #ffffff 0%, #fbfdfe 100%);
    color: var(--forgot-ink);
    text-align: start;
    font-size: 14.5px;
    font-weight: 850;
    box-shadow:
        0 1px 0 rgba(255, 255, 255, .9),
        0 8px 20px rgba(12, 98, 112, .045),
        inset 0 1px 0 rgba(255, 255, 255, .86);
    transition: border-color .16s ease, box-shadow .16s ease, background .16s ease;
}

body[data-forgot-page] .input::placeholder {
    color: #8da0a8;
    font-size: 13.5px;
    font-weight: 750;
}

body[data-forgot-page] .input:hover {
    border-color: rgba(8, 137, 150, .42);
    background: #fff;
}

body[data-forgot-page] .input:focus {
    border-color: var(--forgot-primary);
    background: #fff;
    box-shadow:
        0 0 0 4px rgba(8, 137, 150, .12),
        0 10px 22px rgba(12, 98, 112, .08);
    outline: 0;
}

body[data-forgot-page] .forgot-hint {
    margin: 8px 2px 0;
    padding: 0;
    color: var(--forgot-muted);
    font-size: 12.5px;
    font-weight: 760;
    line-height: 1.65;
    text-align: start;
}

body[data-forgot-page] .btn {
    width: 100%;
    height: 52px;
    margin-top: 2px;
    border: 0;
    border-radius: 15px;
    background: linear-gradient(180deg, #0799a8, var(--forgot-primary-dark));
    color: #fff;
    box-shadow: 0 14px 28px rgba(7, 137, 150, .22);
    font-size: 14px;
    font-weight: 950;
    letter-spacing: 0;
}

body[data-forgot-page] .btn:hover,
body[data-forgot-page] .btn:focus-visible {
    filter: none;
    transform: translateY(-1px);
    box-shadow: 0 18px 34px rgba(7, 137, 150, .25);
}

body[data-forgot-page] .btn__loading[hidden] {
    display: none !important;
}

body[data-forgot-page] .forgot {
    margin: 16px 34px 34px;
    padding-top: 14px;
    border-top: 1px solid var(--forgot-line);
    text-align: center;
}

body[data-forgot-page] .forgot a {
    color: var(--forgot-primary-dark);
    font-size: 12.5px;
    font-weight: 950;
    text-decoration: none;
}

body[data-forgot-page] .forgot a:hover,
body[data-forgot-page] .forgot a:focus-visible {
    text-decoration: underline;
}

body[data-forgot-page] .err {
    margin-top: 8px;
    padding: 8px 10px;
    border-radius: 11px;
    border: 1px solid rgba(220, 38, 38, .18);
    background: #fff7f7;
    color: #b91c1c;
    font-size: 12px;
    font-weight: 850;
}

body[data-forgot-page] .err[hidden] {
    display: none !important;
}

body[data-forgot-page] .err--success {
    border-color: rgba(5, 150, 105, .22);
    background: #f0fdf7;
    color: #047857;
}

html[data-theme="dark"] body[data-forgot-page],
[data-theme="dark"] body[data-forgot-page] {
    --forgot-ink: #eef9fb;
    --forgot-text: #d4e8ee;
    --forgot-muted: #9bb3bc;
    --forgot-line: rgba(128, 186, 199, .24);
    --forgot-line-strong: rgba(128, 186, 199, .40);
    background:
        radial-gradient(circle at 50% 8%, rgba(8, 137, 150, .18), transparent 320px),
        linear-gradient(180deg, #0e1724 0%, #101827 100%);
}

html[data-theme="dark"] body[data-forgot-page] .card,
[data-theme="dark"] body[data-forgot-page] .card,
html[data-theme="dark"] body[data-forgot-page] .input,
[data-theme="dark"] body[data-forgot-page] .input {
    background: #101b2a;
}

html[data-theme="dark"] body[data-forgot-page] .forgot-label,
[data-theme="dark"] body[data-forgot-page] .forgot-label {
    color: #bfd5dc;
}

html[data-theme="dark"] body[data-forgot-page] .control::before,
[data-theme="dark"] body[data-forgot-page] .control::before {
    background: #172b3d;
    color: #7bdbe7;
}

@media (max-width: 520px) {
    body[data-forgot-page] {
        padding: 12px;
    }

    body[data-forgot-page] .wrap {
        width: 100%;
    }

    body[data-forgot-page] .card {
        border-radius: 22px;
    }

    body[data-forgot-page] .logo {
        padding: 28px 24px 8px;
    }

    body[data-forgot-page] .logo img {
        width: 106px;
        max-height: 80px;
    }

    body[data-forgot-page] .title {
        padding: 0 24px 8px;
        font-size: 22px;
    }

    body[data-forgot-page] .title .to {
        font-size: 18px;
    }

    body[data-forgot-page] .forgot-subtitle,
    body[data-forgot-page] #edit-form-login {
        padding-inline: 20px;
    }

    body[data-forgot-page] .forgot {
        margin: 15px 20px 26px;
    }

    body[data-forgot-page] .input,
    body[data-forgot-page] .btn {
        height: 50px;
    }
}

/* Signup page v2: professional owner registration */
body[data-signup-page] {
    --signup-ink: #10232a;
    --signup-text: #304b55;
    --signup-muted: #637b86;
    --signup-line: rgba(9, 111, 128, .18);
    --signup-line-strong: rgba(7, 137, 150, .42);
    --signup-primary: #078996;
    --signup-primary-dark: #056b76;
    --signup-soft: #f5fbfc;
    --signup-shadow: 0 26px 70px rgba(17, 76, 88, .14);
    min-height: 100dvh;
    padding: 24px 16px;
    display: flex !important;
    align-items: center;
    justify-content: center;
    overflow-x: hidden;
    background:
        radial-gradient(circle at 50% 8%, rgba(8, 137, 150, .10), transparent 360px),
        linear-gradient(180deg, #ffffff 0%, #f7fbfc 54%, #edf8fa 100%);
    color: var(--signup-text);
}

body[data-signup-page]::before {
    content: "";
    position: fixed;
    inset: 0;
    z-index: 0;
    background-image:
        linear-gradient(rgba(8, 137, 150, .045) 1px, transparent 1px),
        linear-gradient(90deg, rgba(8, 137, 150, .035) 1px, transparent 1px);
    background-size: 36px 36px;
    mask-image: linear-gradient(180deg, rgba(0, 0, 0, .45), transparent 82%);
    pointer-events: none;
}

body[data-signup-page] main {
    position: relative;
    z-index: 1;
    width: 100%;
    min-height: calc(100dvh - 48px);
    display: flex;
    align-items: center;
    justify-content: center;
}

body[data-signup-page] .signup-wrap {
    width: min(760px, 100%);
    max-width: 760px;
    padding: 0;
}

body[data-signup-page] .signup-card {
    position: relative;
    width: 100%;
    min-height: 0;
    padding: 0;
    overflow: hidden;
    border: 1px solid var(--signup-line);
    border-radius: 26px;
    background: linear-gradient(180deg, rgba(255, 255, 255, .99), rgba(250, 254, 255, .98));
    box-shadow: var(--signup-shadow);
    text-align: center;
}

body[data-signup-page] .signup-card::before {
    content: "";
    position: absolute;
    inset: 0 0 auto;
    width: 100%;
    height: 5px;
    display: block;
    background: linear-gradient(90deg, #0a8f9b, #0bb3c2, #08717c);
    pointer-events: none;
}

body[data-signup-page] .logo {
    min-height: 0;
    margin: 0;
    padding: 30px 34px 6px;
    display: flex;
    align-items: center;
    justify-content: center;
}

body[data-signup-page] .logo img {
    width: 112px;
    max-width: 34vw;
    max-height: 86px;
    object-fit: contain;
    filter: drop-shadow(0 10px 18px rgba(15, 64, 72, .08));
}

body[data-signup-page] .title {
    margin: 0;
    padding: 0 34px 7px;
    color: var(--signup-ink);
    font-size: 26px;
    font-weight: 950;
    line-height: 1.22;
    letter-spacing: 0;
    text-align: center;
}

body[data-signup-page] .title .to {
    display: inline-block;
    margin-inline-start: 5px;
    color: var(--signup-primary);
    font-weight: 950;
}

body[data-signup-page] .forgot-subtitle {
    width: auto;
    margin: 0;
    padding: 0 34px 18px;
    color: var(--signup-muted);
    font-size: 13.5px;
    font-weight: 800;
    line-height: 1.75;
    text-align: center;
}

body[data-signup-page] #signup-form {
    padding: 0 34px 0;
    text-align: start;
}

body[data-signup-page] .signup-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 12px;
}

body[data-signup-page] .signup-field {
    margin: 0 0 13px;
    text-align: start;
}

body[data-signup-page] .signup-label {
    position: static !important;
    width: auto !important;
    height: auto !important;
    padding: 0 !important;
    margin: 0 2px 7px !important;
    overflow: visible !important;
    clip: auto !important;
    white-space: normal !important;
    border: 0 !important;
    display: block;
    color: #395865;
    font-size: 12.5px;
    font-weight: 900;
    line-height: 1.5;
}

body[data-signup-page] .control {
    position: relative;
}

body[data-signup-page] .control::before {
    position: absolute;
    inset-inline-start: 13px;
    top: 50%;
    z-index: 2;
    width: 30px;
    height: 30px;
    display: grid;
    place-items: center;
    border-radius: 10px;
    background: #edf9fb;
    color: var(--signup-primary);
    font-family: "Font Awesome 7 Free", "Font Awesome 5 Free", FontAwesome;
    font-size: 13px;
    font-weight: 900;
    line-height: 1;
    transform: translateY(-50%);
    pointer-events: none;
}

body[data-signup-page] .control-name::before {
    content: "\f007";
}

body[data-signup-page] .control-email::before {
    content: "\f0e0";
}

body[data-signup-page] .control-phone::before {
    content: "\f095";
}

body[data-signup-page] .control-password::before,
body[data-signup-page] .control-confirm::before {
    content: "\f023";
}

body[data-signup-page] .input,
body[data-signup-page] .input-pass {
    width: 100%;
    height: 52px;
    padding-inline-start: 54px;
    padding-inline-end: 16px;
    border: 1px solid #c8e7ee;
    border-radius: 16px;
    background: linear-gradient(180deg, #ffffff 0%, #fbfdfe 100%);
    color: var(--signup-ink);
    text-align: start;
    font-size: 14px;
    font-weight: 850;
    box-shadow:
        0 1px 0 rgba(255, 255, 255, .9),
        0 8px 20px rgba(12, 98, 112, .045),
        inset 0 1px 0 rgba(255, 255, 255, .86);
    transition: border-color .16s ease, box-shadow .16s ease, background .16s ease;
    transform: none !important;
}

body[data-signup-page] .hasToggle .input {
    padding-inline-start: 54px;
    padding-inline-end: 58px;
}

body[data-signup-page] .input::placeholder {
    color: #8da0a8;
    font-size: 13px;
    font-weight: 750;
}

body[data-signup-page] .input:hover {
    border-color: rgba(8, 137, 150, .42);
    background: #fff;
}

body[data-signup-page] .input:focus {
    border-color: var(--signup-primary);
    background: #fff;
    box-shadow:
        0 0 0 4px rgba(8, 137, 150, .12),
        0 10px 22px rgba(12, 98, 112, .08);
    outline: 0;
}

body[data-signup-page] .toggle {
    right: auto;
    left: auto;
    inset-inline-end: 9px;
    top: 50%;
    z-index: 3;
    width: 38px;
    height: 38px;
    display: grid;
    place-items: center;
    border: 1px solid transparent;
    border-radius: 12px;
    color: #087f8c;
    background: transparent;
    transform: translateY(-50%);
}

body[data-signup-page] .toggle:hover,
body[data-signup-page] .toggle:focus-visible {
    border-color: #c8e7ee;
    background: #edf9fb;
}

body[data-signup-page] .hasToggle.control-password::before {
    display: none;
}

body[data-signup-page] .hasToggle .input {
    padding-inline-start: 16px;
}

body[data-signup-page] .password-meter {
    height: auto;
    margin: 8px 2px 0;
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 6px;
}

body[data-signup-page] .password-meter[hidden],
body[data-signup-page] .password-strength-text[hidden] {
    display: none !important;
}

body[data-signup-page] .password-meter__bar {
    height: 5px;
    border-radius: 999px;
    background: #dbecef;
}

body[data-signup-page] .password-strength-text {
    margin: 7px 2px 0;
    font-size: 12px;
    font-weight: 850;
}

body[data-signup-page] .change-password-note {
    margin: 3px 2px 14px;
    padding: 10px 12px;
    border: 1px solid #d5edf2;
    border-radius: 13px;
    background: #f8fcfd;
    color: var(--signup-muted);
    font-size: 12.5px;
    font-weight: 800;
    line-height: 1.7;
    text-align: start;
}

body[data-signup-page] .btn {
    width: 100%;
    height: 52px;
    margin-top: 0;
    border: 0;
    border-radius: 15px;
    background: linear-gradient(180deg, #0799a8, var(--signup-primary-dark));
    color: #fff;
    box-shadow: 0 14px 28px rgba(7, 137, 150, .22);
    font-size: 14px;
    font-weight: 950;
    letter-spacing: 0;
}

body[data-signup-page] .btn:hover,
body[data-signup-page] .btn:focus-visible {
    filter: none;
    transform: translateY(-1px);
    box-shadow: 0 18px 34px rgba(7, 137, 150, .25);
}

body[data-signup-page] .btn__loading[hidden] {
    display: none !important;
}

body[data-signup-page] .auth-switch {
    margin: 16px 34px 34px;
    padding-top: 14px;
    border-top: 1px solid var(--signup-line);
    color: var(--signup-muted);
    font-size: 12.5px;
    font-weight: 850;
    text-align: center;
}

body[data-signup-page] .auth-switch a {
    color: var(--signup-primary-dark);
    font-weight: 950;
    text-decoration: none;
}

body[data-signup-page] .auth-switch a:hover,
body[data-signup-page] .auth-switch a:focus-visible {
    text-decoration: underline;
}

body[data-signup-page] .err {
    margin-top: 8px;
    padding: 8px 10px;
    border-radius: 11px;
    border: 1px solid rgba(220, 38, 38, .18);
    background: #fff7f7;
    color: #b91c1c;
    font-size: 12px;
    font-weight: 850;
}

body[data-signup-page] .err[hidden] {
    display: none !important;
}

body[data-signup-page] .login-alert {
    background: rgba(4, 29, 35, .52);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
}

body[data-signup-page] .login-alert__panel {
    width: min(390px, calc(100vw - 32px));
    border: 1px solid var(--signup-line);
    border-radius: 20px;
    background: #fff;
    box-shadow: 0 24px 64px rgba(15, 64, 72, .22);
}

html[data-theme="dark"] body[data-signup-page],
[data-theme="dark"] body[data-signup-page] {
    --signup-ink: #eef9fb;
    --signup-text: #d4e8ee;
    --signup-muted: #9bb3bc;
    --signup-line: rgba(128, 186, 199, .24);
    --signup-line-strong: rgba(128, 186, 199, .40);
    background:
        radial-gradient(circle at 50% 8%, rgba(8, 137, 150, .18), transparent 320px),
        linear-gradient(180deg, #0e1724 0%, #101827 100%);
}

html[data-theme="dark"] body[data-signup-page] .signup-card,
[data-theme="dark"] body[data-signup-page] .signup-card,
html[data-theme="dark"] body[data-signup-page] .input,
[data-theme="dark"] body[data-signup-page] .input,
html[data-theme="dark"] body[data-signup-page] .input-pass,
[data-theme="dark"] body[data-signup-page] .input-pass,
html[data-theme="dark"] body[data-signup-page] .login-alert__panel,
[data-theme="dark"] body[data-signup-page] .login-alert__panel {
    background: #101b2a;
}

html[data-theme="dark"] body[data-signup-page] .signup-label,
[data-theme="dark"] body[data-signup-page] .signup-label {
    color: #bfd5dc;
}

html[data-theme="dark"] body[data-signup-page] .control::before,
[data-theme="dark"] body[data-signup-page] .control::before {
    background: #172b3d;
    color: #7bdbe7;
}

html[data-theme="dark"] body[data-signup-page] .change-password-note,
[data-theme="dark"] body[data-signup-page] .change-password-note {
    border-color: rgba(128, 186, 199, .24);
    background: #121f2e;
}

@media (max-width: 760px) {
    body[data-signup-page] {
        min-height: 100dvh;
        height: auto;
        padding: max(14px, env(safe-area-inset-top)) 12px max(16px, env(safe-area-inset-bottom));
        align-items: flex-start;
        justify-content: center;
        overflow-y: auto;
    }

    body[data-signup-page] main {
        min-height: 0;
        height: auto;
        display: block;
    }

    body[data-signup-page] .signup-wrap {
        width: 100%;
    }

    body[data-signup-page] .signup-card {
        border-radius: 22px;
        margin: 0 auto;
    }

    body[data-signup-page] .logo {
        padding: 26px 22px 6px;
    }

    body[data-signup-page] .logo img {
        width: 104px;
        max-height: 78px;
    }

    body[data-signup-page] .title {
        padding: 0 22px 7px;
        font-size: 22px;
    }

    body[data-signup-page] .title .to {
        display: block;
        margin: 2px 0 0;
        font-size: 18px;
    }

    body[data-signup-page] .forgot-subtitle,
    body[data-signup-page] #signup-form {
        padding-inline: 20px;
    }

    body[data-signup-page] .signup-grid {
        grid-template-columns: 1fr;
        gap: 0;
    }

    body[data-signup-page] .auth-switch {
        margin: 15px 20px 26px;
    }

    body[data-signup-page] .input,
    body[data-signup-page] .input-pass,
    body[data-signup-page] .btn {
        height: 50px;
    }
}
