/* ═══ VEXO — Auth Pages ═══ */

:root {
    --bg-base: #0A0A0F;
    --text-primary: #FFFFFF;
    --text-secondary: #A1A1AA;
    --text-muted: #52525B;
    --accent-primary: #6366F1;
    --accent-secondary: #A855F7;
    --border-subtle: rgba(255, 255, 255, 0.08);
    --border-hover: rgba(255, 255, 255, 0.15);
    --glass-bg: rgba(255, 255, 255, 0.03);
    --glass-hover: rgba(255, 255, 255, 0.05);
    --danger: #EF4444;
}

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

body {
    font-family: 'Cairo', system-ui, sans-serif;
    background: var(--bg-base);
    color: var(--text-primary);
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 40px 20px;
    overflow-x: hidden;
    -webkit-font-smoothing: antialiased;
}

.auth-bg {
    position: fixed;
    inset: 0;
    z-index: 0;
    pointer-events: none;
    overflow: hidden;
}

.auth-bg::before {
    content: '';
    position: absolute;
    inset: -20%;
    background:
        radial-gradient(circle at 20% 20%, rgba(99, 102, 241, 0.25) 0%, transparent 45%),
        radial-gradient(circle at 80% 80%, rgba(168, 85, 247, 0.2) 0%, transparent 45%),
        radial-gradient(circle at 50% 50%, rgba(59, 130, 246, 0.15) 0%, transparent 50%);
    filter: blur(80px);
    animation: bgFloat 25s ease-in-out infinite;
}

@keyframes bgFloat {
    0%, 100% { transform: scale(1) rotate(0deg); }
    50% { transform: scale(1.15) rotate(8deg); }
}

.auth-bg::after {
    content: '';
    position: absolute;
    inset: 0;
    background-image:
        linear-gradient(rgba(255, 255, 255, 0.02) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255, 255, 255, 0.02) 1px, transparent 1px);
    background-size: 60px 60px;
    mask-image: radial-gradient(ellipse at center, black 30%, transparent 75%);
    -webkit-mask-image: radial-gradient(ellipse at center, black 30%, transparent 75%);
}

.auth-card {
    position: relative;
    z-index: 1;
    width: 100%;
    max-width: 460px;
    background: rgba(20, 20, 28, 0.7);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 1px solid var(--border-subtle);
    border-radius: 24px;
    padding: 40px;
    box-shadow: 0 24px 60px rgba(0, 0, 0, 0.5), 0 0 0 1px rgba(255, 255, 255, 0.03) inset;
}

.auth-header { text-align: center; margin-bottom: 32px; }

.auth-logo {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    font-weight: 900;
    font-size: 1.6rem;
    margin-bottom: 12px;
    letter-spacing: 0.02em;
}

.auth-logo-mark {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    border-radius: 12px;
    background: linear-gradient(135deg, var(--accent-primary), var(--accent-secondary));
    font-family: 'Inter', sans-serif;
    font-size: 1.1rem;
    box-shadow: 0 8px 24px rgba(99, 102, 241, 0.4);
}

.auth-subtitle { color: var(--text-secondary); font-size: 0.95rem; }

.form-group { margin-bottom: 18px; }

.form-label {
    display: block;
    font-weight: 600;
    font-size: 0.9rem;
    margin-bottom: 8px;
    color: var(--text-primary);
}

.form-control {
    width: 100%;
    padding: 12px 16px;
    background: var(--glass-bg);
    border: 1px solid var(--border-subtle);
    border-radius: 12px;
    color: var(--text-primary);
    font-family: inherit;
    font-size: 0.95rem;
    transition: all 0.2s;
}

.form-control:focus {
    outline: none;
    border-color: var(--accent-primary);
    background: var(--glass-hover);
    box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.15);
}

.form-control[dir="ltr"] { direction: ltr; text-align: left; }
.form-control::placeholder { color: var(--text-muted); }

.subdomain-group {
    display: flex;
    direction: ltr;
    background: var(--glass-bg);
    border: 1px solid var(--border-subtle);
    border-radius: 12px;
    overflow: hidden;
    transition: all 0.2s;
}

.subdomain-group:focus-within {
    border-color: var(--accent-primary);
    background: var(--glass-hover);
    box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.15);
}

.subdomain-group input {
    flex: 1;
    padding: 12px 16px;
    background: transparent;
    border: none;
    color: var(--text-primary);
    font-family: inherit;
    font-size: 0.95rem;
}

.subdomain-group input:focus { outline: none; }
.subdomain-group input::placeholder { color: var(--text-muted); }

.subdomain-group .suffix {
    padding: 12px 16px;
    background: rgba(255, 255, 255, 0.03);
    color: var(--text-muted);
    font-family: 'Inter', sans-serif;
    font-size: 0.9rem;
    display: flex;
    align-items: center;
    border-left: 1px solid var(--border-subtle);
}

.hint { display: block; color: var(--text-muted); font-size: 0.8rem; margin-top: 6px; }

.form-check { display: flex; align-items: center; gap: 8px; margin-bottom: 24px; cursor: pointer; }
.form-check input { width: 18px; height: 18px; accent-color: var(--accent-primary); }
.form-check span { font-size: 0.9rem; color: var(--text-secondary); }

.btn-primary {
    width: 100%;
    padding: 14px;
    border: none;
    border-radius: 12px;
    background: linear-gradient(135deg, var(--accent-primary), var(--accent-secondary));
    color: white;
    font-family: inherit;
    font-size: 1rem;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.3s;
    box-shadow: 0 8px 24px rgba(99, 102, 241, 0.35);
    margin-top: 8px;
}

.btn-primary:hover { transform: translateY(-2px); box-shadow: 0 12px 32px rgba(99, 102, 241, 0.5); }
.btn-primary:active { transform: translateY(0); }

.auth-footer { text-align: center; margin-top: 24px; color: var(--text-secondary); font-size: 0.9rem; }

.auth-footer a {
    color: var(--accent-primary);
    text-decoration: none;
    font-weight: 600;
    transition: color 0.2s;
}

.auth-footer a:hover { color: var(--accent-secondary); }

.validation-summary {
    background: rgba(239, 68, 68, 0.1);
    border: 1px solid rgba(239, 68, 68, 0.3);
    color: var(--danger);
    padding: 12px 16px;
    border-radius: 12px;
    margin-bottom: 20px;
    font-size: 0.9rem;
}

.validation-summary:empty { display: none; }
.validation-summary ul { list-style: none; padding: 0; }

.field-error {
    color: var(--danger);
    font-size: 0.8rem;
    margin-top: 6px;
    display: block;
}

.field-error:empty { display: none; }

.fade-in {
    opacity: 0;
    transform: translateY(20px);
    animation: fadeInUp 0.8s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

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

.auth-form > * {
    opacity: 0;
    animation: fadeInUp 0.7s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

.auth-form > *:nth-child(1) { animation-delay: 0.10s; }
.auth-form > *:nth-child(2) { animation-delay: 0.14s; }
.auth-form > *:nth-child(3) { animation-delay: 0.18s; }
.auth-form > *:nth-child(4) { animation-delay: 0.22s; }
.auth-form > *:nth-child(5) { animation-delay: 0.26s; }
.auth-form > *:nth-child(6) { animation-delay: 0.30s; }
.auth-form > *:nth-child(7) { animation-delay: 0.34s; }
.auth-form > *:nth-child(8) { animation-delay: 0.38s; }