:root {
    --bg-main: #eef6ff;
    --bg-soft: #f8fbff;
    --card: rgba(255, 255, 255, 0.88);
    --card-strong: #ffffff;
    --primary: #0f172a;
    --secondary: #0d9488;
    --accent: #2563eb;
    --ink: #1e293b;
    --muted: #64748b;
    --line: rgba(148, 163, 184, 0.22);
    --shadow: 0 25px 55px rgba(15, 23, 42, 0.14);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: "Segoe UI", "Inter", sans-serif;
}

body {
    min-height: 100vh;
    background:
        radial-gradient(circle at top left, rgba(37, 99, 235, 0.22), transparent 30%),
        radial-gradient(circle at bottom right, rgba(13, 148, 136, 0.18), transparent 30%),
        linear-gradient(135deg, #edf5ff 0%, #f8f9ff 45%, #ebfffb 100%);
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 24px;
    color: var(--ink);
}

.auth-shell {
    width: min(1180px, 100%);
    display: grid;
    grid-template-columns: 1.15fr 0.95fr;
    background: rgba(255, 255, 255, 0.38);
    border: 1px solid rgba(148, 163, 184, 0.15);
    border-radius: 32px;
    box-shadow: var(--shadow);
    backdrop-filter: blur(14px);
    overflow: hidden;
}

.brand-panel {
    background: linear-gradient(160deg, rgba(15, 23, 42, 0.96), rgba(30, 64, 175, 0.92));
    color: white;
    padding: 42px 38px;
    position: relative;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.brand-panel::before,
.brand-panel::after {
    content: "";
    position: absolute;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.08);
}

.brand-panel::before {
    width: 280px;
    height: 280px;
    right: -70px;
    top: -70px;
}

.brand-panel::after {
    width: 200px;
    height: 200px;
    left: -50px;
    bottom: -50px;
}

.brand-badge {
    position: relative;
    z-index: 1;
    display: inline-flex;
    align-self: flex-start;
    background: rgba(255, 255, 255, 0.12);
    border: 1px solid rgba(255,255,255,0.15);
    color: #e2e8f0;
    padding: 8px 14px;
    border-radius: 999px;
    font-size: 12px;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    margin-bottom: 20px;
}

.brand-mark {
    position: relative;
    z-index: 1;
    width: 78px;
    height: 78px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 22px;
    background: linear-gradient(135deg, rgba(45,212,191,0.95), rgba(59,130,246,0.95));
    box-shadow: 0 18px 35px rgba(13, 148, 136, 0.35);
    font-size: 2.2rem;
    font-weight: 800;
    margin-bottom: 18px;
}

.brand-panel h1 {
    position: relative;
    z-index: 1;
    font-size: clamp(2.2rem, 3vw, 3rem);
    line-height: 1.1;
    letter-spacing: -0.06em;
    margin-bottom: 12px;
}

.brand-panel p {
    position: relative;
    z-index: 1;
    max-width: 500px;
    color: rgba(255,255,255,0.8);
    font-size: 1rem;
    line-height: 1.7;
    margin-bottom: 26px;
}

.feature-list {
    position: relative;
    z-index: 1;
    display: grid;
    gap: 16px;
}

.feature-item {
    display: flex;
    align-items: center;
    gap: 14px;
    background: rgba(255, 255, 255, 0.08);
    border: 1px solid rgba(255,255,255,0.12);
    border-radius: 18px;
    padding: 14px 16px;
}

.feature-icon {
    width: 42px;
    height: 42px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(255,255,255,0.14);
    color: #dbeafe;
    font-size: 1rem;
}

.feature-item strong {
    display: block;
    font-size: 0.96rem;
    margin-bottom: 4px;
}

.feature-item small {
    display: block;
    color: rgba(255,255,255,0.72);
}

.auth-card {
    background: rgba(255, 255, 255, 0.9);
    backdrop-filter: blur(12px);
    border-radius: 0;
    padding: 34px 36px 26px;
    width: 100%;
    color: var(--primary);
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.logo {
    width: 68px;
    height: 68px;
    background: linear-gradient(135deg, #0d9488, #2563eb);
    border-radius: 20px;
    display: flex;
    justify-content: center;
    align-items: center;
    margin: 0 auto 18px;
    box-shadow: 0 18px 35px rgba(37, 99, 235, 0.18);
}

.logo span {
    font-size: 1.9rem;
    font-weight: 800;
    color: white;
}

h2 {
    text-align: center;
    margin-bottom: 8px;
    font-size: clamp(1.7rem, 2vw, 2.1rem);
    letter-spacing: -0.05em;
    color: var(--primary);
}

.subtitle {
    text-align: center;
    color: var(--muted);
    margin-bottom: 24px;
    font-size: 0.95rem;
}

.auth-toggle {
    display: grid;
    grid-template-columns: repeat(4, minmax(0,1fr));
    gap: 6px;
    background: #eef2ff;
    border: 1px solid rgba(99, 102, 241, 0.08);
    border-radius: 16px;
    padding: 6px;
    margin-bottom: 22px;
}

.auth-toggle button {
    background: transparent;
    border: none;
    border-radius: 12px;
    padding: 10px 8px;
    color: var(--muted);
    cursor: pointer;
    transition: all 0.25s ease;
    font-size: 0.78rem;
    font-weight: 700;
}

.auth-toggle button.active {
    background: linear-gradient(135deg, #0d9488, #2563eb);
    color: #fff;
    box-shadow: 0 10px 20px rgba(37, 99, 235, 0.18);
}

.auth-form {
    display: none;
}

.auth-form.active {
    display: block;
}

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

label {
    display: block;
    margin-bottom: 8px;
    font-size: 0.82rem;
    font-weight: 700;
    color: var(--ink);
}

.input-icon {
    position: relative;
}

.input-icon i {
    position: absolute;
    top: 50%;
    left: 16px;
    transform: translateY(-50%);
    color: #7c8aa5;
    font-size: 0.92rem;
}

input {
    width: 100%;
    padding: 14px 16px 14px 42px;
    border-radius: 14px;
    border: 1px solid var(--line);
    background: var(--bg-soft);
    color: var(--primary);
    outline: none;
    transition: all 0.2s ease;
    font-size: 0.96rem;
}

input::placeholder {
    color: #8aa0b8;
}

input:focus {
    border-color: rgba(37, 99, 235, 0.5);
    box-shadow: 0 0 0 4px rgba(37, 99, 235, 0.08);
    background: #fff;
}

.btn-primary {
    width: 100%;
    padding: 15px 18px;
    background: linear-gradient(135deg, #0d9488, #2563eb);
    border: none;
    border-radius: 14px;
    color: white;
    font-size: 0.96rem;
    font-weight: 700;
    cursor: pointer;
    margin-top: 8px;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
    box-shadow: 0 15px 25px rgba(37, 99, 235, 0.2);
}

.btn-primary:hover {
    transform: translateY(-1px);
    box-shadow: 0 18px 30px rgba(13, 148, 136, 0.22);
}

.footer {
    font-size: 0.76rem;
    text-align: center;
    margin-top: 22px;
    color: var(--muted);
}

.footer a {
    color: var(--accent);
    text-decoration: none;
    font-weight: 600;
}

@media (max-width: 900px) {
    .auth-shell {
        grid-template-columns: 1fr;
    }

    .brand-panel {
        padding: 30px 24px;
    }

    .auth-card {
        padding: 26px 22px 20px;
    }
}

@media (max-width: 520px) {
    .auth-toggle {
        grid-template-columns: repeat(2, minmax(0,1fr));
    }

    body {
        padding: 12px;
    }
}
