/* /public/css/panel-municipal.css (Versión "Gubernamental" Final) */
@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700&display=swap');

:root {
    --municipal-bg: #f8f9fa;
    --municipal-surface: #ffffff;
    --municipal-border: #e9ecef;
    --municipal-primary: #003366;      /* Azul institucional oscuro */
    --municipal-accent: #d4af37;       /* Dorado/amarillo sutil */
    --municipal-text: #212529;
    --municipal-text-muted: #6c757d;
}

.portal-body {
    background-color: var(--municipal-bg) !important;
    color: var(--municipal-text) !important;
    font-family: 'Inter', sans-serif;
    overflow-y: hidden;
}

/* --- Layout y Sidebar --- */
.portal-grid {
    display: grid;
    grid-template-columns: 260px 1fr;
    height: 100vh;
}
.portal-sidebar {
    background-color: var(--municipal-surface);
    border-right: 1px solid var(--municipal-border);
    display: flex;
    flex-direction: column;
    padding: 1rem;
}
.sidebar-header {
    display: flex; align-items: center; justify-content: center; gap: 0.75rem;
    font-size: 1.2rem; font-weight: 700; color: var(--municipal-primary);
    margin-bottom: 2rem; padding: 1rem 0;
    border-bottom: 1px solid var(--municipal-border);
}
.sidebar-nav {
    display: flex;
    flex-direction: column;
    gap: 0.5rem; /* Espacio entre los botones */
}
.nav-item {
    display: flex; /* ✅ CORRECCIÓN CLAVE DE LAYOUT */
    align-items: center; /* ✅ CORRECCIÓN CLAVE DE LAYOUT */
    gap: 0.75rem; /* ✅ CORRECCIÓN CLAVE DE LAYOUT */
    padding: 0.75rem 1rem; /* ✅ CORRECCIÓN CLAVE DE LAYOUT */
    border-radius: 6px; /* ✅ CORRECCIÓN CLAVE DE LAYOUT */
    text-decoration: none;
    color: var(--municipal-text-muted);
    transition: all 0.2s ease;
    font-weight: 500;
}
.nav-item:hover {
    background-color: var(--municipal-bg);
    color: var(--municipal-text);
}
.nav-item.active {
    background-color: var(--municipal-accent);
    color: var(--municipal-primary);
    font-weight: 700;
}
.sidebar-footer { margin-top: auto; padding-top: 1rem; border-top: 1px solid var(--municipal-border); }
.user-details { display: flex; flex-direction: column; }
.user-rank { font-size: 0.8em; color: var(--municipal-text-muted); }

/* --- Contenido Principal --- */
.portal-main { padding: 1.5rem 2rem; overflow-y: auto; }
.main-header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 2rem; }
.main-header h1 { font-size: 1.75rem; font-weight: 700; color: var(--municipal-text); }

.header-search { position: relative; } /* Necesario para el ícono */
.header-search input {
    background-color: var(--municipal-surface);
    border: 1px solid var(--municipal-border);
    color: var(--municipal-text);
    width: 350px;
    padding-left: 2.5rem;
}
.header-search input:focus {
    border-color: var(--municipal-accent);
    box-shadow: 0 0 0 3px rgba(212, 175, 55, 0.25);
}
.header-search i { position: absolute; left: 0.8rem; top: 50%; transform: translateY(-50%); color: var(--municipal-text-muted); }

/* --- Tarjetas, Tablas y Componentes --- */
.widget {
    background-color: transparent;
    border: none;
    padding: 0;
}
.search-results-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(350px, 1fr));
    gap: 1.5rem;
}
.result-card, .card {
    background-color: var(--municipal-surface);
    border: 1px solid var(--municipal-border);
    box-shadow: 0 1px 3px rgba(0,0,0,0.04);
    transition: all 0.2s ease;
}
.result-card:hover {
    border-color: var(--municipal-accent);
    transform: translateY(-4px);
    box-shadow: 0 8px 16px rgba(0,0,0,0.08);
}
.table { color: var(--municipal-text); }
.table thead th {
    background-color: var(--municipal-bg);
    border-bottom: 2px solid var(--municipal-border);
    color: var(--municipal-text-muted);
}
.table-hover tbody tr:hover {
    background-color: #eef2ff;
    color: var(--municipal-primary);
}
.badge-pagada { background-color: #198754 !important; color: white; }
.badge-pendiente { background-color: #ffc107 !important; color: #1a1a1a; }

/* Modales */
.modal-content { background-color: var(--municipal-surface); color: var(--municipal-text); }
.modal-header, .modal-footer { border-color: var(--municipal-border); }
.form-control:focus { border-color: var(--municipal-accent); box-shadow: 0 0 0 0.25rem rgb(212 175 55 / 25%); }
.btn-close { filter: none; }

/* AÑADE ESTO AL FINAL de public/css/panel-municipal.css */

.sidebar-logo {
    height: 40px; /* Ajusta la altura del logo */
    width: auto;  /* El ancho se ajustará automáticamente */
}
