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

body {
    background: #0a0a0f;
    color: #d4d4d4;
    font-family: "Rubik", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}

/* Subtle gradient background */
body::before {
    content: '';
    position: fixed;
    inset: 0;
    background:
        radial-gradient(ellipse 60% 50% at 20% 80%, rgba(255, 107, 53, 0.06) 0%, transparent 70%),
        radial-gradient(ellipse 50% 40% at 80% 20%, rgba(99, 102, 241, 0.05) 0%, transparent 70%);
    pointer-events: none;
}

.login-container {
    width: 100%;
    max-width: 420px;
    padding: 1.5rem;
    position: relative;
    z-index: 1;
}

.login-card {
    background: rgba(20, 20, 30, 0.85);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 1.25rem;
    padding: 2.5rem 2rem 2rem;
    backdrop-filter: blur(20px);
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5);
}

/* Header */
.login-header {
    text-align: center;
    margin-bottom: 1.75rem;
}

.logo {
    width: 56px;
    height: 56px;
    border-radius: 12px;
    margin-bottom: 0.75rem;
    filter: drop-shadow(0 0 16px rgba(255, 107, 53, 0.3));
}

.login-header h1 {
    font-size: 1.75rem;
    font-weight: 700;
    background: linear-gradient(135deg, #ff6b35, #ff8f5e);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    letter-spacing: -0.02em;
}

.subtitle {
    color: #666;
    font-size: 0.8rem;
    text-transform: uppercase;
    letter-spacing: 0.12em;
    margin-top: 0.25rem;
}

/* Tabs */
.tab-switcher {
    display: flex;
    background: rgba(10, 10, 18, 0.6);
    border-radius: 0.5rem;
    padding: 3px;
    margin-bottom: 1.5rem;
}

.tab {
    flex: 1;
    padding: 0.5rem 1rem;
    border: none;
    border-radius: 0.4rem;
    background: transparent;
    color: #666;
    font-size: 0.875rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s;
    font-family: inherit;
}

.tab.active {
    background: #ff6b35;
    color: #000;
    box-shadow: 0 2px 8px rgba(255, 107, 53, 0.3);
}

.tab:not(.active):hover {
    color: #999;
}

/* Messages */
.msg {
    padding: 0.75rem 1rem;
    border-radius: 0.5rem;
    font-size: 0.85rem;
    margin-bottom: 1rem;
    border: 1px solid;
}

.msg-error {
    background: rgba(220, 38, 38, 0.1);
    border-color: rgba(220, 38, 38, 0.3);
    color: #f87171;
}

.msg-success {
    background: rgba(34, 197, 94, 0.1);
    border-color: rgba(34, 197, 94, 0.3);
    color: #4ade80;
}

/* Form */
.input-group {
    margin-bottom: 1.25rem;
}

.input-group label {
    display: block;
    font-size: 0.8rem;
    color: #888;
    margin-bottom: 0.4rem;
    font-weight: 500;
}

.input-group input {
    width: 100%;
    padding: 0.75rem 1rem;
    background: rgba(15, 15, 22, 0.9);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 0.5rem;
    color: #e0e0e0;
    font-size: 0.95rem;
    font-family: inherit;
    transition: border-color 0.2s;
    outline: none;
}

.input-group input:focus {
    border-color: rgba(255, 107, 53, 0.5);
    box-shadow: 0 0 0 3px rgba(255, 107, 53, 0.08);
}

.input-group input::placeholder {
    color: #444;
}

.hint {
    display: block;
    font-size: 0.72rem;
    color: #555;
    margin-top: 0.3rem;
}

/* Buttons */
.btn-primary {
    width: 100%;
    padding: 0.75rem;
    border: none;
    border-radius: 0.5rem;
    background: linear-gradient(135deg, #ff6b35, #e55a25);
    color: #000;
    font-size: 0.95rem;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.2s;
    font-family: inherit;
    margin-top: 0.25rem;
}

.btn-primary:hover:not(:disabled) {
    background: linear-gradient(135deg, #ff7f50, #ff6b35);
    box-shadow: 0 4px 16px rgba(255, 107, 53, 0.3);
    transform: translateY(-1px);
}

.btn-primary:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.btn-primary.loading {
    position: relative;
    color: transparent;
}

.btn-primary.loading::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 18px;
    height: 18px;
    margin: -9px 0 0 -9px;
    border: 2px solid rgba(0, 0, 0, 0.2);
    border-top-color: #000;
    border-radius: 50%;
    animation: spin 0.6s linear infinite;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

.btn-link {
    display: block;
    width: 100%;
    background: none;
    border: none;
    color: #666;
    font-size: 0.8rem;
    cursor: pointer;
    padding: 0.75rem 0 0;
    font-family: inherit;
    transition: color 0.2s;
}

.btn-link:hover {
    color: #ff6b35;
}

/* Mobile */
@media (max-width: 480px) {
    .login-container { padding: 1rem; }
    .login-card { padding: 2rem 1.5rem 1.5rem; }
}

/* Remember Me */
.remember-group {
    margin: 0.75rem 0 0;
}
.remember-label {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    color: #9ca3af;
    cursor: pointer;
    font-size: 0.875rem;
    user-select: none;
}
.remember-label input[type="checkbox"] {
    width: 1rem;
    height: 1rem;
    accent-color: var(--primary, #ff6b35);
    cursor: pointer;
}
