/* ===================================
   IMPORTAÇÃO DE FONTES
   =================================== */

/* Figtree do Google Fonts (online) */
@import url('https://fonts.googleapis.com/css2?family=Figtree:wght@300;400;500;600;700&display=swap');

/* Nephilm Sans Local - usando os arquivos .otf que você já adicionou */
@font-face {
    font-family: 'NephilmSans';
    src: url('../fonts/nephilm-sans/Nephilm.otf') format('opentype');
    font-weight: 400;
    font-style: normal;
    font-display: swap;
}

@font-face {
    font-family: 'NephilmSans';
    src: url('../fonts/nephilm-sans/Nephilm.otf') format('opentype');
    font-weight: 500;
    font-style: normal;
    font-display: swap;
}

@font-face {
    font-family: 'NephilmSans';
    src: url('../fonts/nephilm-sans/Nephilm.otf') format('opentype');
    font-weight: 600;
    font-style: normal;
    font-display: swap;
}

@font-face {
    font-family: 'NephilmSans';
    src: url('../fonts/nephilm-sans/Nephilm.otf') format('opentype');
    font-weight: 700;
    font-style: normal;
    font-display: swap;
}

@font-face {
    font-family: 'NephilmSans';
    src: url('../fonts/nephilm-sans/Nephilm.otf') format('opentype');
    font-weight: 800;
    font-style: normal;
    font-display: swap;
}

@font-face {
    font-family: 'NephilmSans';
    src: url('../fonts/nephilm-sans/Nephilm.otf') format('opentype');
    font-weight: 900;
    font-style: normal;
    font-display: swap;
}

@font-face {
    font-family: 'NephilmSans';
    src: url('../fonts/nephilm-sans/Nephilm Italic.otf') format('opentype');
    font-weight: 400;
    font-style: italic;
    font-display: swap;
}

/* ===================================
   RESET & BASE STYLES
   =================================== */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    /* Cores Principais */
    --primary-blue: #00285d;
    --primary-blue-light: #003d82;
    --primary-blue-dark: #001a40;

    /* Tons de Cinza */
    --gray-50: #f9fafb;
    --gray-100: #f3f4f6;
    --gray-200: #e5e7eb;
    --gray-300: #d1d5db;
    --gray-400: #9ca3af;
    --gray-500: #6b7280;
    --gray-600: #4b5563;
    --gray-700: #374151;
    --gray-800: #1f2937;
    --gray-900: #111827;

    /* Cores de Suporte */
    --white: #ffffff;
    --accent: #3b82f6;
    --success: #10b981;
    --error: #ef4444;

    /* Sombras */
    --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
    --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
    --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
    --shadow-xl: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);

    /* Transições */
    --transition-fast: 150ms cubic-bezier(0.4, 0, 0.2, 1);
    --transition-base: 300ms cubic-bezier(0.4, 0, 0.2, 1);
    --transition-slow: 500ms cubic-bezier(0.4, 0, 0.2, 1);

    /* Fontes */
    --font-banner: 'NephilmSans', 'Noto Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    --font-body: 'Figtree', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
}

body {
    font-family: var(--font-body);
    background: var(--gray-50);
    color: var(--gray-900);
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

/* ===================================
   CONTAINER PRINCIPAL
   =================================== */
.login-container {
    display: flex;
    min-height: 100vh;
    overflow: hidden;
}

/* ===================================
   BANNER LATERAL ESQUERDO
   =================================== */
.login-banner {
    flex: 1;
    position: relative;

    /* ========================================
       COMO TROCAR A IMAGEM DE FUNDO:
       ========================================
       1. Coloque sua imagem na pasta: public/images/backgrounds/
       2. Renomeie sua imagem para: login-background.png
          (ou altere o nome abaixo na linha background-image)
       3. Formatos aceitos: .png, .jpg, .jpeg, .webp
       4. Tamanho recomendado: 1920x1080 ou superior
       ======================================== */

    background-image: url('../images/backgrounds/login-background.png');
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;

    display: flex;
    align-items: center;
    justify-content: center;
    padding: 4rem;
    overflow: hidden;
}

/* Overlay escuro sobre a imagem para melhor legibilidade do texto */
.login-banner::after {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(135deg,
            rgba(0, 26, 64, 0.85) 0%,
            rgba(0, 40, 93, 0.75) 50%,
            rgba(0, 61, 130, 0.85) 100%);
    pointer-events: none;
    z-index: 1;
}

/* Padrão de fundo animado (opcional - pode remover se quiser apenas a imagem) */
.login-banner::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: repeating-linear-gradient(45deg,
            transparent,
            transparent 10px,
            rgba(255, 255, 255, 0.02) 10px,
            rgba(255, 255, 255, 0.02) 20px);
    animation: slidePattern 20s linear infinite;
    z-index: 1;
}

@keyframes slidePattern {
    0% {
        transform: translate(0, 0);
    }

    100% {
        transform: translate(50px, 50px);
    }
}

.banner-overlay {
    position: absolute;
    inset: 0;
    background: radial-gradient(circle at 30% 50%, rgba(59, 130, 246, 0.1) 0%, transparent 60%);
    pointer-events: none;
    z-index: 1;
}

.banner-content {
    position: relative;
    z-index: 2;
    max-width: 600px;
    animation: fadeInUp 0.8s ease-out;
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.banner-title {
    font-family: var(--font-banner);
    font-size: 4rem;
    font-weight: 900;
    color: var(--white);
    letter-spacing: 0.02em;
    margin-bottom: 1.5rem;
    text-shadow: 0 4px 20px rgba(0, 0, 0, 0.4), 0 2px 10px rgba(0, 0, 0, 0.3);
    line-height: 1.1;
    -webkit-text-stroke: 0.5px rgba(255, 255, 255, 0.3);
}

.banner-subtitle {
    font-family: var(--font-banner);
    font-size: 1.25rem;
    color: rgba(255, 255, 255, 0.95);
    font-weight: 400;
    margin-bottom: 0.5rem;
    text-shadow: 0 2px 10px rgba(0, 0, 0, 0.2);
}

.banner-features {
    margin-top: 3rem;
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.feature-item {
    display: flex;
    align-items: center;
    gap: 1rem;
    color: var(--white);
    font-size: 1rem;
    opacity: 0;
    animation: fadeInLeft 0.6s ease-out forwards;
}

.feature-item:nth-child(1) {
    animation-delay: 0.3s;
}

.feature-item:nth-child(2) {
    animation-delay: 0.5s;
}

.feature-item:nth-child(3) {
    animation-delay: 0.7s;
}

@keyframes fadeInLeft {
    from {
        opacity: 0;
        transform: translateX(-20px);
    }

    to {
        opacity: 1;
        transform: translateX(0);
    }
}

.feature-icon {
    width: 40px;
    height: 40px;
    background: rgba(255, 255, 255, 0.15);
    backdrop-filter: blur(10px);
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    border: 1px solid rgba(255, 255, 255, 0.2);
    transition: all var(--transition-base);
}

.feature-item:hover .feature-icon {
    background: rgba(255, 255, 255, 0.25);
    transform: translateY(-2px);
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.2);
}

/* ===================================
   SEÇÃO DO FORMULÁRIO
   =================================== */
.login-form-section {
    flex: 0 0 550px;
    background: var(--white);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 3rem;
    box-shadow: var(--shadow-xl);
    position: relative;
    z-index: 10;
}

.login-form-wrapper {
    width: 100%;
    max-width: 420px;
    animation: fadeIn 0.6s ease-out;
}

@keyframes fadeIn {
    from {
        opacity: 0;
    }

    to {
        opacity: 1;
    }
}

/* Logo */
.logo-container {
    text-align: center;
    margin-bottom: 2.5rem;
}

.logo {
    display: inline-flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.75rem 1.5rem;
    background: var(--gray-50);
    border-radius: 12px;
    border: 2px solid var(--gray-100);
    transition: all var(--transition-base);
}

.logo:hover {
    border-color: var(--primary-blue);
    background: rgba(0, 40, 93, 0.03);
    transform: translateY(-2px);
    box-shadow: var(--shadow-md);
}

.logo-text {
    font-family: var(--font-body);
    font-size: 1.5rem;
    font-weight: 600;
    color: var(--primary-blue);
    letter-spacing: -0.01em;
}

/* Header do Formulário */
.form-header {
    text-align: left;
    margin-bottom: 2rem;
}

.form-title {
    font-size: 1.75rem;
    font-weight: 600;
    color: var(--gray-900);
    margin-bottom: 0.5rem;
}

.form-description {
    font-size: 0.95rem;
    color: var(--gray-500);
    font-weight: 400;
}

/* Links de Ajuda */
.help-links {
    background: var(--gray-50);
    border: 1px solid var(--gray-200);
    border-radius: 12px;
    padding: 1rem;
    margin-bottom: 2rem;
    text-align: center;
}

.help-link {
    display: block;
    font-size: 0.875rem;
    color: var(--gray-600);
    text-decoration: none;
    margin-bottom: 0.5rem;
}

.help-link-secondary {
    display: inline-block;
    font-size: 0.875rem;
    color: var(--primary-blue);
    text-decoration: none;
    font-weight: 500;
    transition: all var(--transition-fast);
}

.help-link-secondary:hover {
    color: var(--primary-blue-light);
    text-decoration: underline;
}

/* ===================================
   FORMULÁRIO
   =================================== */
.login-form {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.form-group {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.label-wrapper {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.form-label {
    font-size: 0.875rem;
    font-weight: 500;
    color: var(--gray-700);
}

.forgot-password {
    font-size: 0.875rem;
    color: var(--primary-blue);
    text-decoration: none;
    font-weight: 500;
    transition: color var(--transition-fast);
}

.forgot-password:hover {
    color: var(--primary-blue-light);
    text-decoration: underline;
}

.form-input {
    width: 100%;
    padding: 0.875rem 1rem;
    font-size: 0.95rem;
    border: 2px solid var(--gray-200);
    border-radius: 10px;
    background: var(--white);
    color: var(--gray-900);
    transition: all var(--transition-fast);
    font-family: inherit;
}

.form-input:focus {
    outline: none;
    border-color: var(--primary-blue);
    box-shadow: 0 0 0 3px rgba(0, 40, 93, 0.1);
}

.form-input::placeholder {
    color: var(--gray-400);
}

/* Password Input */
.password-wrapper {
    position: relative;
}

.toggle-password {
    position: absolute;
    right: 1rem;
    top: 50%;
    transform: translateY(-50%);
    background: none;
    border: none;
    cursor: pointer;
    color: var(--gray-400);
    padding: 0.5rem;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: color var(--transition-fast);
}

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

/* Checkbox */
.checkbox-group {
    margin-top: -0.5rem;
}

.checkbox-label {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    cursor: pointer;
    user-select: none;
}

.checkbox-label input[type="checkbox"] {
    position: absolute;
    opacity: 0;
    cursor: pointer;
}

.checkbox-custom {
    width: 20px;
    height: 20px;
    border: 2px solid var(--gray-300);
    border-radius: 6px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all var(--transition-fast);
    flex-shrink: 0;
}

.checkbox-label input[type="checkbox"]:checked~.checkbox-custom {
    background: var(--primary-blue);
    border-color: var(--primary-blue);
}

.checkbox-label input[type="checkbox"]:checked~.checkbox-custom::after {
    content: '✓';
    color: var(--white);
    font-size: 0.75rem;
    font-weight: 600;
}

.checkbox-text {
    font-size: 0.875rem;
    color: var(--gray-600);
}

/* Botão de Submit */
.btn-submit {
    width: 100%;
    padding: 1rem 1.5rem;
    background: linear-gradient(135deg, var(--primary-blue) 0%, var(--primary-blue-light) 100%);
    color: var(--white);
    border: none;
    border-radius: 10px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.75rem;
    transition: all var(--transition-base);
    box-shadow: 0 4px 12px rgba(0, 40, 93, 0.3);
    margin-top: 0.5rem;
}

.btn-submit:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(0, 40, 93, 0.4);
}

.btn-submit:active {
    transform: translateY(0);
}

.btn-submit svg {
    transition: transform var(--transition-base);
}

.btn-submit:hover svg {
    transform: translateX(4px);
}

/* Footer */
.login-footer {
    margin-top: 2.5rem;
    text-align: center;
    padding-top: 2rem;
    border-top: 1px solid var(--gray-200);
}

.login-footer p {
    font-size: 0.8rem;
    color: var(--gray-500);
}

/* ===================================
   RESPONSIVE
   =================================== */
@media (max-width: 1024px) {
    .login-banner {
        flex: 0 0 45%;
        padding: 2.5rem;
    }

    .banner-title {
        font-size: 3rem;
    }

    .login-form-section {
        flex: 1;
    }
}

@media (max-width: 768px) {
    .login-container {
        flex-direction: column;
    }

    .login-banner {
        flex: none;
        min-height: 40vh;
        padding: 2rem;
    }

    .banner-title {
        font-size: 2.5rem;
    }

    .banner-subtitle {
        font-size: 1rem;
    }

    .banner-features {
        margin-top: 2rem;
        gap: 1rem;
    }

    .feature-item {
        font-size: 0.9rem;
    }

    .login-form-section {
        flex: none;
        padding: 2rem;
    }

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

@media (max-width: 480px) {
    .banner-title {
        font-size: 2rem;
    }

    .login-form-section {
        padding: 1.5rem;
    }

    .form-title {
        font-size: 1.5rem;
    }
}