*,
*::before,
*::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

:root {
    --bg: 245 247 250;
    --fg: 20 23 30;
    --card: 255 255 255;
    --primary: 14 165 233;
    --primary-hover: 12 140 200;
    --muted: 234 236 240;
    --muted-fg: 100 116 139;
    --border: 222 226 230;
    --glass: rgba(255, 255, 255, 0.8);
}

.dark {
    --bg: 14 17 22;
    --fg: 230 230 230;
    --card: 26 29 36;
    --primary: 34 211 238;
    --primary-hover: 45 220 250;
    --muted: 42 47 58;
    --muted-fg: 156 163 175;
    --border: 42 47 58;
    --glass: rgba(26, 29, 36, 0.8);
}

body {
    font-family: 'Space Grotesk', sans-serif;
    background-color: rgb(var(--bg));
    color: rgb(var(--fg));
    min-height: 100vh;
    display: flex;
    transition: background-color .2s;
}

/* Layout */
.login-container {
    display: flex;
    width: 100%;
    min-height: 100vh;
}

/* Lewa strona - Teksty */
.brand-section {
    flex: 1;
    background: linear-gradient(135deg, rgb(var(--primary)), #0369a1);
    color: white;
    padding: 4rem;
    display: flex;
    flex-direction: column;
    justify-content: center;
    position: relative;
    overflow: hidden;
}

.brand-section::before {
    content: '';
    position: absolute;
    top: -10%;
    right: -10%;
    width: 300px;
    height: 300px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 50%;
    filter: blur(60px);
}

.brand-content {
    position: relative;
    z-index: 2;
    max-width: 500px;
}

.brand-logo {
    font-size: 2rem;
    font-weight: 700;
    margin-bottom: 3rem;
    display: block;
    text-decoration: none;
    color: white;
}

.brand-content h2 {
    font-size: 2.5rem;
    line-height: 1.2;
    margin-bottom: 1.5rem;
}

.benefit-list {
    list-style: none;
    margin-top: 2rem;
}

.benefit-item {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-bottom: 1.25rem;
    font-size: 1.1rem;
    opacity: 0.9;
}

.benefit-item svg {
    width: 1.5rem;
    height: 1.5rem;
    flex-shrink: 0;
}

/* Prawa strona - Formularz */
.form-section {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 2rem;
    background-color: rgb(var(--bg));
}

.form-card {
    width: 100%;
    max-width: 400px;
}

.form-header {
    margin-bottom: 2rem;
}

.form-header h1 {
    font-size: 1.75rem;
    font-weight: 700;
    margin-bottom: 0.5rem;
}

.form-header p {
    color: rgb(var(--muted-fg));
}

.input-group {
    margin-bottom: 1.25rem;
}

.input-group label {
    display: block;
    font-size: 0.9rem;
    font-weight: 500;
    margin-bottom: 0.5rem;
}

.input-field {
    width: 100%;
    padding: 0.75rem 1rem;
    border-radius: 0.5rem;
    border: 1px solid rgb(var(--border));
    background-color: rgb(var(--card));
    color: rgb(var(--fg));
    font-family: inherit;
    font-size: 1rem;
    outline: none;
    transition: border-color .2s, box-shadow .2s;
}

.input-field:focus {
    border-color: rgb(var(--primary));
    box-shadow: 0 0 0 3px rgba(14, 165, 233, 0.15);
}

.form-options {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1.5rem;
    font-size: 0.85rem;
}

.remember-me {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    cursor: pointer;
}

.forgot-pass {
    color: rgb(var(--primary));
    text-decoration: none;
    font-weight: 500;
}

.submit-btn {
    width: 100%;
    padding: 0.875rem;
    border: none;
    border-radius: 0.5rem;
    background-color: rgb(var(--primary));
    color: white;
    font-family: inherit;
    font-weight: 600;
    font-size: 1rem;
    cursor: pointer;
    transition: background-color .2s;
}

.submit-btn:hover {
    background-color: #0284c7;
}

.divider {
    display: flex;
    align-items: center;
    margin: 1.5rem 0;
    color: rgb(var(--muted-fg));
    font-size: 0.8rem;
}

.divider::before,
.divider::after {
    content: '';
    flex: 1;
    height: 1px;
    background-color: rgb(var(--border));
}

.divider span {
    padding: 0 1rem;
}

.social-login {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1rem;
}

.social-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 0.625rem;
    border: 1px solid rgb(var(--border));
    border-radius: 0.5rem;
    background: rgb(var(--card));
    color: rgb(var(--fg));
    cursor: pointer;
    font-family: inherit;
    font-size: 0.9rem;
    transition: background-color .2s;
}

.social-btn:hover {
    background-color: rgb(var(--muted));
}

.footer-text {
    text-align: center;
    margin-top: 2rem;
    font-size: 0.9rem;
    color: rgb(var(--muted-fg));
}

.footer-text a {
    color: rgb(var(--primary));
    text-decoration: none;
    font-weight: 600;
}

/* Toggle Theme button position on login page */
.theme-switch {
    position: absolute;
    top: 2rem;
    right: 2rem;
}

/* Responsywność */
@media (max-width: 900px) {
    .brand-section {
        display: none;
    }

    .form-section {
        padding: 1rem;
    }
}