@import url('https://fonts.googleapis.com/css2?family=Cairo:wght@300;400;600;700&display=swap');

:root {
    --auth-bg: linear-gradient(135deg, #0f172a 0%, #312e81 50%, #7c3aed 100%);
    --auth-card-bg: rgba(255, 255, 255, 0.08);
    --auth-border: rgba(255, 255, 255, 0.15);
    --auth-text: #f8fafc;
    --auth-muted: rgba(248, 250, 252, 0.75);
    --auth-primary: #38bdf8;
    --auth-primary-dark: #0ea5e9;
    --auth-shadow: 0 25px 60px rgba(15, 23, 42, 0.35);
}

body.auth-layout {
    min-height: 100vh;
    background: var(--auth-bg);
    font-family: 'Cairo', 'Segoe UI', sans-serif;
    color: var(--auth-text);
    padding: 0;
    margin: 0;
}

.auth-main {
    min-height: 100vh;
    padding: 48px 16px;
}

.auth-page {
    width: 100%;
}

.auth-brand h1 {
    font-weight: 700;
    letter-spacing: 0.5px;
    color: var(--auth-text);
}

.auth-brand p {
    color: var(--auth-muted);
    margin-top: 4px;
}

.auth-card {
    background: var(--auth-card-bg);
    border: 1px solid var(--auth-border);
    border-radius: 24px;
    padding: 40px 32px;
    backdrop-filter: blur(18px);
    box-shadow: var(--auth-shadow);
    color: var(--auth-text);
    width: 100%;
    max-width: 520px;
    margin: 0 auto;
}

.auth-card--wide {
    padding: 48px 56px;
    max-width: 680px;
}

.auth-card--wide > h2 {
    font-size: 1.65rem;
}
.auth-input-group {
    direction: ltr;
    align-items: stretch;
}

.auth-input-group .input-group-text {
    background: rgba(15, 23, 42, 0.65);
    border: 1px solid rgba(255, 255, 255, 0.1);
    color: var(--auth-text);
    font-weight: 600;
    padding: 0 22px;
    border-radius: 16px 0 0 16px;
}

.auth-input-group .form-control {
    border-left: none;
    border-top-left-radius: 0;
    border-bottom-left-radius: 0;
    border-radius: 0 16px 16px 0;
    font-size: 1.15rem;
}

.auth-phone-input {
    direction: ltr !important;
    text-align: left;
    letter-spacing: 0.2em;
}

[dir="rtl"] .auth-phone-input {
    text-align: left;
}

.auth-card .form-label {
    color: var(--auth-text);
    font-weight: 500;
}

.auth-card .form-control,
.auth-card .form-select {
    background-color: rgba(15, 23, 42, 0.35);
    border: 1px solid rgba(255, 255, 255, 0.08);
    color: var(--auth-text);
    padding: 12px 16px;
    border-radius: 14px;
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.auth-card .form-control:focus,
.auth-card .form-select:focus {
    border-color: var(--auth-primary);
    box-shadow: 0 0 0 3px rgba(56, 189, 248, 0.25);
}

.auth-card .form-control::placeholder {
    color: rgba(248, 250, 252, 0.45);
}

.auth-card .form-check-input {
    background-color: transparent;
    border: 1px solid rgba(255, 255, 255, 0.3);
}

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

.auth-card .btn-primary {
    background: var(--auth-primary);
    border-color: var(--auth-primary);
    font-weight: 600;
    padding: 12px 0;
    border-radius: 16px;
    box-shadow: 0 10px 30px rgba(14, 165, 233, 0.45);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.auth-card .btn-primary:hover {
    background: var(--auth-primary-dark);
    border-color: var(--auth-primary-dark);
    transform: translateY(-1px);
}

.auth-card .btn-primary:disabled {
    opacity: 0.75;
    box-shadow: none;
}

.auth-card .alert {
    border-radius: 16px;
    border: none;
    padding: 14px 18px;
}

.auth-card .alert-success {
    background: rgba(34, 197, 94, 0.15);
    color: #dcfce7;
}

.auth-card .alert-danger {
    background: rgba(248, 113, 113, 0.18);
    color: #fee2e2;
}

.auth-card .alert-info {
    background: rgba(56, 189, 248, 0.15);
    color: #e0f2fe;
}

.auth-card .btn-link {
    color: var(--auth-primary);
    font-weight: 600;
    text-decoration: none;
}

.auth-card .btn-link:hover {
    text-decoration: underline;
}

.auth-card .spinner-border {
    color: #fff;
}

.auth-card small,
.auth-card .text-muted {
    color: var(--auth-muted) !important;
}

@media (max-width: 576px) {
    .auth-card {
        padding: 28px 20px;
    }

    .auth-card--wide {
        padding: 32px 22px;
    }

    body.auth-layout {
        padding: 24px 12px;
    }
}

