body {
    /* Gradiente usando tu fondo oscuro corporativo hacia un tono ligeramente más claro */
    background: linear-gradient(135deg, var(--bg-body) 0%, #1e293b 100%);
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 100vh;
    margin: 0;
    font-family: var(--font-family);
}

.auth-container {
    background: rgba(30, 41, 59, 0.7); /* Basado en tu --bg-card con transparencia */
    backdrop-filter: blur(10px);
    border: 1px solid var(--border);
    border-radius: 15px;
    width: 100%;
    max-width: 500px;
    padding: 40px;
    box-shadow: 0 15px 35px rgba(0, 0, 0, 0.5);
    border-top: 4px solid var(--primary); /* Toque de amarillo Cestber */
}

.auth-tabs {
    display: flex;
    margin-bottom: 30px;
    border-bottom: 1px solid var(--border);
}

.auth-tab {
    flex: 1;
    text-align: center;
    padding: 10px;
    color: var(--text-muted);
    cursor: pointer;
    font-weight: bold;
    transition: all 0.3s ease;
}

.auth-tab.active {
    color: var(--primary); /* Texto activo en amarillo */
    border-bottom: 2px solid var(--primary); /* Línea activa en amarillo */
}

.auth-form {
    display: none;
}

.auth-form.active {
    display: block;
}

.btn-full {
    width: 100%;
    padding: 12px;
    font-size: 1.1rem;
    font-weight: bold;
    color: #000; /* Texto NEGRO sobre fondo amarillo para máximo contraste */
    background: var(--primary); /* Botón amarillo Cestber */
    border: none;
    border-radius: var(--radius);
    cursor: pointer;
    margin-top: 20px;
    transition: background 0.3s ease;
}

.btn-full:hover {
    background: #e6bb00; /* Amarillo un poco más oscuro al pasar el ratón */
}

.btn-back {
    position: absolute;
    top: 25px;
    left: 25px;
    color: var(--text-muted);
    text-decoration: none;
    font-weight: bold;
    font-size: 0.95rem;
    display: flex;
    align-items: center;
    gap: 8px;
    transition: color 0.3s ease, transform 0.3s ease;
}

.btn-back:hover {
    color: var(--primary); /* Se ilumina en amarillo Cestber */
    transform: translateX(-5px); /* Pequeño efecto de movimiento hacia atrás */
}

/* =========================================
   SIDEBAR PORTAL PROVEEDORES
========================================= */
.sidebar {
    width: 260px;
    background: rgba(255, 255, 255, 0.02);
    border-right: 1px solid var(--border);
    height: 100vh;
    position: fixed;
    top: 0;
    left: 0;
    padding: 20px 0;
    display: flex;
    flex-direction: column;
}

.nav-links {
    list-style: none;
    padding: 0;
    margin: 0;
}

.nav-links li {
    width: 100%;
}

.nav-link {
    display: block;
    padding: 15px 25px;
    color: var(--text-muted);
    text-decoration: none;
    font-weight: bold;
    transition: all 0.3s ease;
    border-left: 4px solid transparent;
}

.nav-link:hover {
    background: rgba(253, 207, 0, 0.05);
    color: var(--text-main);
}

.nav-link.active {
    background: rgba(253, 207, 0, 0.1);
    color: var(--primary);
    border-left: 4px solid var(--primary);
}

.main-content {
    margin-left: 260px;
    padding: 30px;
    min-height: 100vh;
}

/* Tarjetas de Oportunidades (Requerimientos de Cestber) */
.rfq-card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 20px;
    margin-bottom: 20px;
    transition: transform 0.2s, border-color 0.2s;
    border-left: 4px solid var(--info);
}

.rfq-card:hover {
    transform: translateY(-3px);
    border-color: var(--primary);
}

.rfq-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 15px;
    border-bottom: 1px solid var(--border);
    padding-bottom: 10px;
}

/* =======================================================
   RESPONSIVE / MÓVIL  (cajón lateral) — gana por ser el último CSS
   ======================================================= */
.menu-toggle {
    display: none;
    position: fixed;
    top: 14px;
    left: 14px;
    z-index: 1001;
    width: 44px;
    height: 44px;
    border: none;
    border-radius: 10px;
    background: var(--primary, #fdcf00);
    color: #0f1a20;
    font-size: 1.3rem;
    cursor: pointer;
    align-items: center;
    justify-content: center;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.4);
}

.sidebar-overlay {
    display: none;
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.55);
    backdrop-filter: blur(2px);
    z-index: 90;
}

@media (max-width: 1024px) {
    .menu-toggle {
        display: inline-flex;
    }

    .sidebar {
        z-index: 100;
        transform: translateX(-100%);
        transition: transform 0.3s ease;
        box-shadow: 4px 0 24px rgba(0, 0, 0, 0.5);
    }

    body.sidebar-open .sidebar {
        transform: translateX(0);
    }

    body.sidebar-open .sidebar-overlay {
        display: block;
    }

    .main-content {
        margin-left: 0;
        padding: 70px 18px 24px;
    }
}

@media (max-width: 768px) {
    .main-content div[style*="grid-template-columns"] {
        grid-template-columns: 1fr !important;
    }

    .main-content [style*="min-width"] {
        min-width: 0 !important;
    }

    .form-row {
        flex-direction: column;
        gap: 0;
    }

    /* font-size 16px evita el zoom automático de iOS al enfocar */
    .form-control,
    input,
    select,
    textarea {
        font-size: 16px !important;
    }

    .main-content [style*="overflow-x"] {
        -webkit-overflow-scrolling: touch;
    }

    .rfq-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 8px;
    }
}

@media (max-width: 480px) {
    .sidebar {
        width: 84vw;
        max-width: 300px;
    }
}