* { box-sizing: border-box; }

body {
    margin: 0;
    font-family: 'Inter', ui-sans-serif, system-ui, sans-serif;
    color: #0b1424;
}

.auth-page {
    position: relative;
    isolation: isolate;
    min-height: 100vh;
    display: grid;
    place-items: center;
    padding: 24px;
    overflow: hidden;
    background: #08111f;
}

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

.auth-page__bg-image {
    position: absolute;
    inset: 0;
}

.auth-page__bg-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
}

.auth-page__overlay--dark {
    position: absolute;
    inset: 0;
    background: rgba(8, 17, 31, 0.7);
}

.auth-page__overlay--gradient {
    position: absolute;
    inset: 0;
    background: linear-gradient(to bottom, rgba(8, 17, 31, 0.4), rgba(8, 17, 31, 0.55), #08111f);
}

.auth-page__glow--purple-left {
    position: absolute;
    top: -128px;
    left: 25%;
    width: 280px;
    height: 900px;
    transform: rotate(-12deg);
    background: linear-gradient(to bottom, rgba(124, 45, 146, 0.4), rgba(124, 45, 146, 0.1), transparent);
    filter: blur(40px);
}

.auth-page__glow--purple-right {
    position: absolute;
    top: -128px;
    right: 25%;
    width: 280px;
    height: 900px;
    transform: rotate(12deg);
    background: linear-gradient(to bottom, rgba(124, 45, 146, 0.4), rgba(124, 45, 146, 0.1), transparent);
    filter: blur(40px);
}

.auth-page__glow--orange {
    position: absolute;
    top: 33%;
    left: 50%;
    width: 700px;
    height: 600px;
    transform: translateX(-50%);
    border-radius: 50%;
    background: rgba(255, 107, 0, 0.25);
    filter: blur(120px);
}

.auth-page__dots {
    position: absolute;
    inset: 0;
    opacity: 0.08;
    background-image: radial-gradient(circle at 1px 1px, #ffffff 1px, transparent 0);
    background-size: 32px 32px;
}

.auth-card {
    position: relative;
    z-index: 1;
    width: min(980px, 95vw);
    min-height: 520px;
    background: rgba(255, 255, 255, 0.2);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 1px solid rgba(255, 255, 255, 0.18);
    border-radius: 24px;
    overflow: hidden;
    display: grid;
    grid-template-columns: 320px 1fr;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.35);
}

.auth-side {
    background: rgba(11, 20, 36, 0.82);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border-right: 1px solid rgba(255, 255, 255, 0.08);
    color: #fff;
    padding: 42px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    position: relative;
    overflow: hidden;
}

.auth-side::before {
    content: '';
    position: absolute;
    top: -80px;
    right: -60px;
    width: 220px;
    height: 220px;
    border-radius: 50%;
    background: rgba(124, 45, 146, 0.35);
    filter: blur(60px);
    pointer-events: none;
}

.auth-side::after {
    content: '';
    position: absolute;
    bottom: -40px;
    left: -40px;
    width: 180px;
    height: 180px;
    border-radius: 50%;
    background: rgba(255, 107, 0, 0.25);
    filter: blur(50px);
    pointer-events: none;
}

.auth-side > * { position: relative; z-index: 1; }

.brand {
    font-size: 22px;
    font-weight: 800;
    letter-spacing: -0.02em;
    color: #fff;
}

.side-title {
    font-size: 34px;
    font-weight: 800;
    margin: 0 0 10px;
    letter-spacing: -0.02em;
}

.side-subtitle {
    margin: 0;
    color: rgba(255, 255, 255, 0.75);
    line-height: 1.5;
}

.side-btn {
    border: 2px solid rgba(255, 255, 255, 0.7);
    border-radius: 12px;
    color: #fff;
    text-decoration: none;
    text-align: center;
    font-weight: 700;
    padding: 12px 16px;
    display: inline-block;
    background: rgba(255, 255, 255, 0.05);
    transition: background 0.2s, border-color 0.2s, color 0.2s;
}

.side-btn:hover {
    background: #ff6b00;
    border-color: #ff6b00;
}

.auth-content {
    padding: 48px 56px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    color: #fff;
}

.title {
    margin: 0;
    font-size: 42px;
    font-weight: 800;
    text-align: center;
    color: #fff;
    letter-spacing: -0.02em;
}

.title--sm { font-size: 38px; }

.subtitle {
    margin: 8px 0 30px;
    color: rgba(255, 255, 255, 0.75);
    text-align: center;
}

.field {
    width: 100%;
    margin-bottom: 14px;
    border: 1px solid rgba(255, 255, 255, 0.25);
    background: rgba(255, 255, 255, 0.95);
    height: 52px;
    border-radius: 12px;
    padding: 0 16px;
    font-size: 16px;
    font-family: inherit;
    color: #0b1424;
    transition: border-color 0.2s, box-shadow 0.2s, background 0.2s;
}

.field::placeholder { color: #5a6473; }

.field:focus {
    outline: none;
    border-color: #ff6b00;
    background: #fff;
    box-shadow: 0 0 0 3px rgba(255, 107, 0, 0.25);
}

.row-inline {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-top: 8px;
    margin-bottom: 20px;
    font-size: 14px;
    color: rgba(255, 255, 255, 0.75);
}

.row-inline label {
    color: rgba(255, 255, 255, 0.85);
    cursor: pointer;
}

.row-inline--center {
    justify-content: center;
    margin-top: 18px;
    margin-bottom: 0;
}

.row-inline a {
    color: #ffb066;
    text-decoration: none;
    font-weight: 600;
    transition: color 0.2s;
}

.row-inline a:hover { color: #ff6b00; }

.submit-btn {
    border: 0;
    border-radius: 12px;
    background: linear-gradient(to right, #ff6b00, #ff8a3d);
    color: #fff;
    height: 52px;
    width: min(280px, 100%);
    display: block;
    margin: 0 auto;
    font-size: 18px;
    font-weight: 700;
    font-family: inherit;
    cursor: pointer;
    box-shadow: 0 10px 40px -10px rgba(255, 107, 0, 0.7);
    transition: transform 0.2s, box-shadow 0.2s;
}

.submit-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 15px 50px -10px rgba(255, 107, 0, 0.85);
}

a.submit-btn {
    line-height: 52px;
    text-decoration: none;
    text-align: center;
}

.error-code {
    margin: 0 0 24px;
    text-align: center;
    font-size: 72px;
    font-weight: 800;
    letter-spacing: 0.04em;
    background: linear-gradient(to right, #ffb066, #ff6b00, #ff8a3d);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
    filter: drop-shadow(0 0 24px rgba(255, 107, 0, 0.35));
}

.auth-actions {
    display: flex;
    gap: 12px;
    justify-content: center;
    flex-wrap: wrap;
}

.auth-actions .submit-btn {
    margin: 0;
    width: auto;
    min-width: min(210px, 100%);
    padding: 0 24px;
}

.btn-outline {
    border: 2px solid rgba(255, 255, 255, 0.7);
    border-radius: 12px;
    color: #fff;
    text-decoration: none;
    text-align: center;
    font-weight: 700;
    font-size: 16px;
    padding: 0 24px;
    height: 52px;
    line-height: 48px;
    min-width: min(210px, 100%);
    background: rgba(255, 255, 255, 0.05);
    transition: background 0.2s, border-color 0.2s, transform 0.2s;
}

.btn-outline:hover {
    background: rgba(255, 255, 255, 0.12);
    border-color: #fff;
    transform: translateY(-2px);
}

.brand a {
    display: block;
    text-decoration: none;
}

.alert {
    padding: 12px;
    border-radius: 12px;
    margin-bottom: 14px;
    font-size: 14px;
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
}

.alert-danger {
    background: rgba(255, 227, 227, 0.92);
    border: 1px solid rgba(255, 201, 201, 0.8);
    color: #a61e1e;
}

.alert-success {
    background: rgba(230, 252, 245, 0.92);
    border: 1px solid rgba(195, 250, 232, 0.8);
    color: #087f5b;
}

@media (max-width: 900px) {
    .auth-card { grid-template-columns: 1fr; }
    .auth-side {
        padding: 28px;
        gap: 26px;
        border-right: 0;
        border-bottom: 1px solid rgba(255, 255, 255, 0.08);
    }
    .auth-content { padding: 36px 24px; }
    .title { font-size: 32px; }
    .title--sm { font-size: 32px; }
    .submit-btn { width: 100%; }
    .auth-actions { flex-direction: column; align-items: stretch; }
    .error-code { font-size: 56px; }
}
