@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700;800&display=swap');

:root {
    --blue-900: #0D47A1;
    --blue-700: #1565C0;
    --blue-600: #1976D2;
    --blue-500: #2196F3;
    --blue-400: #42A5F5;
    --blue-100: #BBDEFB;
    --blue-50:  #E3F2FD;
    --text-dark: #1E293B;
    --text-muted: #64748B;
    --white: #FFFFFF;
}

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

html, body {
    height: 100%;
    font-family: 'Inter', sans-serif;
}

/* ===================================
   LAYOUT PRINCIPAL (DOIS PAINÉIS)
=================================== */
.login-wrapper {
    display: flex;
    min-height: 100vh;
}

/* ===================================
   PAINEL ESQUERDO — BRANDING
=================================== */
.login-brand-panel {
    width: 45%;
    background: linear-gradient(150deg, #0D47A1 0%, #1565C0 50%, #1976D2 100%);
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    padding: 48px 52px;
    position: relative;
    overflow: hidden;
}

.login-brand-panel::before {
    content: '';
    position: absolute;
    top: -80px;
    right: -80px;
    width: 300px;
    height: 300px;
    background: rgba(255,255,255,0.06);
    border-radius: 50%;
}

.login-brand-panel::after {
    content: '';
    position: absolute;
    bottom: -100px;
    left: -60px;
    width: 350px;
    height: 350px;
    background: rgba(255,255,255,0.04);
    border-radius: 50%;
}

.brand-content {
    position: relative;
    z-index: 1;
}

.brand-logo {
    width: 64px;
    height: 64px;
    background: rgba(255,255,255,0.15);
    border: 2px solid rgba(255,255,255,0.3);
    border-radius: 16px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.8rem;
    color: white;
    margin-bottom: 20px;
    backdrop-filter: blur(10px);
}

.brand-title {
    font-size: 2.4rem;
    font-weight: 700;
    color: white;
    letter-spacing: -0.5px;
    margin-bottom: 10px;
}

.brand-title strong {
    font-weight: 800;
    color: #90CAF9;
}

.brand-tagline {
    color: rgba(255,255,255,0.75);
    font-size: 0.95rem;
    line-height: 1.5;
    margin-bottom: 40px;
    max-width: 320px;
}

.brand-features {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.feature-item {
    display: flex;
    align-items: center;
    gap: 12px;
    color: rgba(255,255,255,0.9);
    font-size: 0.9rem;
}

.feature-item i {
    color: #90CAF9;
    font-size: 1rem;
    flex-shrink: 0;
}

.brand-footer {
    position: relative;
    z-index: 1;
}

.brand-footer p {
    color: rgba(255,255,255,0.4);
    font-size: 0.78rem;
    margin: 0;
}

/* ===================================
   PAINEL DIREITO — FORMULÁRIO
=================================== */
.login-form-panel {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    background-color: #F8FAFF;
    padding: 40px 24px;
}

.form-wrapper {
    width: 100%;
    max-width: 400px;
}

.form-header {
    margin-bottom: 28px;
}

.form-header h2 {
    font-size: 1.7rem;
    font-weight: 700;
    color: var(--text-dark);
    letter-spacing: -0.3px;
    margin-bottom: 6px;
}

.form-header p {
    color: var(--text-muted);
    font-size: 0.9rem;
    margin: 0;
}

/* ===================================
   CAMPOS DO FORMULÁRIO
=================================== */
.input-group-custom label {
    display: block;
    font-size: 0.85rem;
    font-weight: 500;
    color: var(--text-dark);
    margin-bottom: 6px;
}

.input-icon-wrapper {
    position: relative;
    display: flex;
    align-items: center;
}

.input-icon {
    position: absolute;
    left: 14px;
    color: var(--text-muted);
    font-size: 0.9rem;
    z-index: 1;
    pointer-events: none;
}

.custom-input {
    padding: 12px 44px 12px 40px;
    border: 1.5px solid #E2E8F0;
    border-radius: 10px;
    font-size: 0.9rem;
    color: var(--text-dark);
    background: white;
    width: 100%;
    transition: border-color 0.2s, box-shadow 0.2s;
    font-family: 'Inter', sans-serif;
}

.custom-input::placeholder {
    color: #CBD5E1;
}

.custom-input:focus {
    outline: none;
    border-color: var(--blue-500);
    box-shadow: 0 0 0 3px rgba(33, 150, 243, 0.12);
}

.toggle-password {
    position: absolute;
    right: 14px;
    background: none;
    border: none;
    color: var(--text-muted);
    cursor: pointer;
    font-size: 0.9rem;
    padding: 0;
    line-height: 1;
    transition: color 0.2s;
}

.toggle-password:hover {
    color: var(--blue-600);
}

/* ===================================
   LINKS
=================================== */
.forgot-link {
    font-size: 0.83rem;
    color: var(--blue-600);
    font-weight: 500;
    text-decoration: none;
    transition: color 0.2s;
}

.forgot-link:hover { color: var(--blue-900); }

/* ===================================
   BOTÃO DE LOGIN
=================================== */
.btn-login {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    background: linear-gradient(135deg, var(--blue-700), var(--blue-500));
    color: white;
    border: none;
    border-radius: 10px;
    padding: 13px 24px;
    font-size: 0.95rem;
    font-weight: 600;
    font-family: 'Inter', sans-serif;
    cursor: pointer;
    box-shadow: 0 4px 15px rgba(21, 101, 192, 0.3);
    transition: all 0.2s;
}

.btn-login:hover {
    background: linear-gradient(135deg, var(--blue-900), var(--blue-700));
    box-shadow: 0 6px 20px rgba(21, 101, 192, 0.4);
    transform: translateY(-1px);
    color: white;
}

/* ===================================
   FOOTER DO FORM
=================================== */
.form-footer {
    margin-top: 24px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 12px;
}

.form-footer > p {
    font-size: 0.85rem;
    color: var(--text-muted);
    margin: 0;
    text-align: center;
}

.signup-link {
    color: var(--blue-700);
    font-weight: 600;
    text-decoration: none;
}

.signup-link:hover { color: var(--blue-900); }

.back-link {
    font-size: 0.82rem;
    color: var(--text-muted);
    text-decoration: none;
    display: flex;
    align-items: center;
    gap: 4px;
    transition: color 0.2s;
}

.back-link:hover { color: var(--blue-700); }

/* ===================================
   RESPONSIVIDADE
=================================== */
@media (max-width: 768px) {
    .login-brand-panel {
        display: none;
    }
    .login-form-panel {
        width: 100%;
    }
}

@media (max-width: 400px) {
    .form-wrapper {
        padding: 0 8px;
    }
}
