:root {
    --amber: #FFCC4D;
    --amber-hover: #FFC12E;
    --zinc-950: #09090b;
    --zinc-900: #18181b;
    --zinc-800: #27272a;
    --zinc-400: #a1a1aa;
    --zinc-200: #e4e4e7;
    --zinc-100: #f4f4f5;
    --zinc-50: #fafafa;
    --page-bg: #fafafa;
    --card-bg: #ffffff;
    --text-main: var(--zinc-900);
    --border-color: var(--zinc-100);
}

@media (prefers-color-scheme: dark) {
    :root {
        --page-bg: var(--zinc-950);
        --card-bg: var(--zinc-900);
        --text-main: #fafafa;
        --border-color: var(--zinc-800);
    }
}

* { box-sizing: border-box; }

body {
    margin: 0;
    font-family: 'Nunito Sans', system-ui, -apple-system, 'Segoe UI', Roboto, Arial, sans-serif;
    background: var(--page-bg);
    color: var(--text-main);
}

.page {
    position: relative;
    min-height: 100svh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 16px;
    overflow: hidden;
}

.blob {
    position: absolute;
    border-radius: 999px;
    background: rgba(255, 204, 77, 0.14);
    filter: blur(90px);
    pointer-events: none;
}
.blob-1 { top: -10%; left: -5%; width: 260px; height: 260px; }
.blob-2 { bottom: 8%; right: -10%; width: 380px; height: 380px; background: rgba(255, 204, 77, 0.10); }
.blob-3 { top: 18%; right: 8%; width: 140px; height: 140px; background: rgba(255, 204, 77, 0.12); }

.card {
    position: relative;
    z-index: 1;
    display: flex;
    width: 100%;
    max-width: 950px;
    border-radius: 16px;
    overflow: hidden;
    background: var(--card-bg);
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.08);
    border: 1px solid var(--border-color);
}

.banner {
    display: none;
    width: 42%;
    background-image: linear-gradient(rgba(20,22,20,0.72), rgba(20,22,20,0.82)), url('../img/banner.png');
    background-size: cover;
    background-position: center;
}

.banner-overlay {
    height: 100%;
    display: flex;
    flex-direction: column;
    padding: 48px 40px;
    color: #fff;
    border-right: 1px solid rgba(0,0,0,0.1);
}

.banner-logo {
    display: flex;
    align-items: center;
    justify-content: center;
    height: 200px;
    margin-bottom: 32px;
}
.banner-logo img { max-height: 100%; max-width: 100%; object-fit: contain; }

.feature-list {
    margin-top: auto;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.feature {
    display: flex;
    align-items: center;
    gap: 16px;
    padding: 16px;
    border-radius: 10px;
    background: rgba(255,255,255,0.1);
    border: 1px solid rgba(255,255,255,0.15);
}

.feature-icon {
    flex-shrink: 0;
    width: 44px;
    height: 44px;
    border-radius: 8px;
    background: var(--amber);
    color: var(--zinc-950);
    display: flex;
    align-items: center;
    justify-content: center;
}
.feature-icon svg { width: 22px; height: 22px; }

.feature-text h4 {
    margin: 0 0 2px;
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.02em;
}
.feature-text p {
    margin: 0;
    font-size: 10px;
    font-weight: 500;
    color: rgba(255,255,255,0.6);
    line-height: 1.3;
}

.form-panel {
    flex: 1;
    display: flex;
    flex-direction: column;
    padding: 32px 24px;
}

.form-header {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
}

.form-logo {
    width: 84px;
    height: 84px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 16px;
}
.form-logo img { max-width: 100%; max-height: 100%; object-fit: contain; }

.form-header h1 {
    margin: 0;
    font-size: 22px;
    font-weight: 700;
    letter-spacing: -0.01em;
}
.form-header .subtitle {
    margin: 6px 0 0;
    font-size: 12px;
    font-weight: 500;
    color: var(--zinc-400);
}

.error-banner {
    margin-top: 20px;
    padding: 12px 16px;
    border-radius: 8px;
    background: #fef2f2;
    border: 1px solid #fecaca;
    color: #b91c1c;
    font-size: 12px;
    font-weight: 600;
    text-align: center;
}

#login-form {
    margin-top: 24px;
    display: flex;
    flex-direction: column;
    gap: 18px;
}

.field { display: flex; flex-direction: column; gap: 6px; }
.field label {
    font-size: 13px;
    font-weight: 600;
    color: var(--text-main);
}

.input-wrap {
    position: relative;
    display: flex;
    align-items: center;
}
.input-icon {
    position: absolute;
    left: 12px;
    width: 16px;
    height: 16px;
    color: var(--zinc-400);
    pointer-events: none;
}
.input-wrap input {
    width: 100%;
    height: 44px;
    padding: 0 40px;
    border-radius: 8px;
    border: 1px solid var(--zinc-200);
    background: var(--card-bg);
    color: var(--text-main);
    font-size: 14px;
    font-family: inherit;
    outline: none;
    transition: border-color 0.15s;
}
.input-wrap input:focus {
    border-color: var(--amber);
    box-shadow: 0 0 0 3px rgba(255,204,77,0.25);
}
.input-wrap input.invalid { border-color: #ef4444; }

.toggle-pass {
    position: absolute;
    right: 10px;
    background: none;
    border: none;
    padding: 4px;
    cursor: pointer;
    color: var(--zinc-400);
    display: flex;
}
.toggle-pass svg { width: 18px; height: 18px; }

.field-row {
    display: flex;
    justify-content: flex-end;
}
.forgot-link {
    font-size: 12px;
    font-weight: 600;
    color: #b45309;
    text-decoration: none;
}
.forgot-link:hover { color: var(--amber-hover); }

.submit-btn {
    position: relative;
    height: 48px;
    border: none;
    border-radius: 8px;
    background: var(--amber);
    color: var(--zinc-950);
    font-size: 14px;
    font-weight: 700;
    letter-spacing: 0.01em;
    cursor: pointer;
    transition: background 0.2s;
    display: flex;
    align-items: center;
    justify-content: center;
}
.submit-btn:hover { background: var(--amber-hover); }
.submit-btn:disabled { opacity: 0.7; cursor: not-allowed; }

.btn-spinner {
    width: 18px;
    height: 18px;
    border: 2px solid rgba(9,9,11,0.25);
    border-top-color: var(--zinc-950);
    border-radius: 50%;
    animation: spin 0.7s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }

.hint {
    margin: 16px 0 0;
    text-align: center;
    font-size: 11px;
    color: var(--zinc-400);
}

.footer {
    margin-top: auto;
    padding-top: 28px;
    border-top: 1px solid var(--border-color);
    text-align: center;
}
.footer p {
    margin: 0;
    font-size: 10px;
    font-weight: 500;
    color: var(--zinc-400);
    text-transform: uppercase;
    letter-spacing: 0.25em;
}

@media (min-width: 1024px) {
    .banner { display: block; }
    .form-panel { padding: 48px; }
}
