/* Estilos específicos para el Panel de Administración */
.admin-body {
    background-color: #f4f7f6;
    transition: background-color 0.3s ease, color 0.3s ease;
}

/* MODO OSCURO */
body.dark-mode .admin-body {
    background-color: #121212;
    color: #e0e0e0;
}

body.dark-mode .sidebar-admin,
body.dark-mode .admin-main-panel,
body.dark-mode .admin-card-option,
body.dark-mode .bg-light,
body.dark-mode .card,
body.dark-mode .modal-content {
    background-color: #1e1e1e !important;
    border-color: #333 !important;
    color: #e0e0e0 !important;
}

body.dark-mode .admin-card-option h5,
body.dark-mode .text-dark,
body.dark-mode h3,
body.dark-mode h4 {
    color: #a0a0a0 !important; /* Softer grey for titles in dark mode */
}

/* General text color for dark mode */
body.dark-mode .form-label,
body.dark-mode,
body.dark-mode p,
body.dark-mode span,
body.dark-mode small,
body.dark-mode label,
body.dark-mode a:not(.btn), /* Exclude buttons from this general rule */
body.dark-mode .text-muted { /* Ensure text-muted also becomes light */
    color: #e0e0e0 !important;
}

/* Table styling for dark mode */
body.dark-mode .table {
    color: #e0e0e0;
    border-color: #333;
}

body.dark-mode .form-control,
body.dark-mode .form-select {
    background-color: #2d2d2d;
    border-color: #444;
    color: #fff;
}

body.dark-mode .form-control:focus {
    background-color: #333;
    color: #fff;
}

/* Sidebar Navigation Links - Light Mode */
.sidebar-admin .nav-link {
    color: #343a40 !important; /* Ensure dark text in light mode */
}

.sidebar-admin .nav-link.active {
    background-color: var(--azul-marino); /* Active state background in light mode */
    color: white !important;
}

.sidebar-admin .nav-link:hover {
    background-color: var(--verde-institucional); /* Hover background in light mode */
    color: white !important;
}

/* Sidebar Navigation Links - Dark Mode */
body.dark-mode .sidebar-admin .nav-link {
    color: #e0e0e0 !important; /* White for dark mode */
}

body.dark-mode .sidebar-admin .nav-link.active {
    background-color: #007bff !important; /* Active state background in dark mode (Bootstrap primary blue) */
    color: #ffffff !important;
}

body.dark-mode .sidebar-admin .nav-link:hover {
    background-color: #333333 !important; /* Darker hover for dark mode */
    color: #ffffff !important;
}

/* Table specific dark mode styles */
body.dark-mode .table {
    background-color: #1e1e1e !important; /* Main table background */
}

body.dark-mode .table thead th {
    background-color: #282828 !important; /* Table header background */
    border-color: #333 !important;
    color: #ffffff !important;
}

body.dark-mode .table tbody tr {
    background-color: #1e1e1e !important; /* Default row background */
}

body.dark-mode .table tbody tr:nth-of-type(odd) {
    background-color: #222222 !important; /* Alternate row background */
}

body.dark-mode .table tbody tr:hover {
    background-color: #333333 !important; /* Row hover background */
}

body.dark-mode .table td,
body.dark-mode .table th {
    border-color: #333 !important; /* Cell borders */
}

/* Adjust badge colors for dark mode if they are light in light mode */
body.dark-mode .badge.bg-info {
    background-color: #0dcaf0 !important; /* Bootstrap info color */
    color: #121212 !important; /* Dark text for light badge */
}

body.dark-mode .badge.bg-warning {
    background-color: #ffc107 !important; /* Bootstrap warning color */
    color: #121212 !important; /* Dark text for light badge */
}

body.dark-mode .badge.bg-success {
    background-color: #198754 !important; /* Bootstrap success color */
    color: #ffffff !important;
}

body.dark-mode .badge.bg-primary {
    background-color: #0d6efd !important; /* Bootstrap primary color */
    color: #ffffff !important;
}

body.dark-mode .badge.bg-secondary {
    background-color: #6c757d !important; /* Bootstrap secondary color */
    color: #ffffff !important;
}

body.dark-mode .badge.bg-dark {
    background-color: #343a40 !important; /* Bootstrap dark color */
    color: #ffffff !important;
}


/* Sidebar Navigation Links - Dark Mode */
body.dark-mode .sidebar-admin .nav-link {
    color: #e0e0e0 !important; /* White for dark mode */
}


.admin-card-option {
    background: #ffffff;
    border: none;
    border-radius: 12px;
    padding: 2rem;
    text-align: center;
    text-decoration: none !important;
    transition: all 0.3s ease;
    box-shadow: 0 4px 12px rgba(0,0,0,0.05);
    display: block;
    background-color: #f8f9fa; /* Explicit light background to ensure visibility */
    height: 100%;
    border-bottom: 5px solid transparent;
}

.admin-card-option:hover {
    transform: translateY(-8px);
    box-shadow: 0 12px 25px rgba(0,0,0,0.1);
}

.admin-card-option i {
    font-size: 3rem;
    margin-bottom: 1.5rem;
    display: block;
}

.admin-card-option h5 {
    color: #007bff; /* Attractive blue for titles in light mode */
    font-weight: 700;
    margin-bottom: 0.5rem;
}

.admin-card-option p {
    color: #000; /* Texto en negro para modo claro */
    font-size: 0.9rem;
    margin-bottom: 0;
}

.sidebar-admin {
    background: #ffffff;
    border-radius: 12px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.05);
    padding: 1.5rem;
    position: sticky;
    top: 100px;
}

.admin-main-panel {
    background: #ffffff;
    border-radius: 12px;
    box-shadow: 0 4px 20px rgba(0,0,0,0.08);
    padding: 2rem;
    min-height: 400px; /* Ensure panel takes up space */
}

.stats-pill {
    background: #f8f9fa;
    border-radius: 8px;
    padding: 10px 15px;
    border-left: 4px solid #108c35;
    margin-bottom: 10px;
}

/* Estilos para el Stepper de Noticias */
.news-stepper .nav-link {
    border-radius: 0;
    border-bottom: 3px solid transparent;
    color: #6c757d !important;
    font-weight: 600;
    background: none !important;
    box-shadow: none !important;
    transform: none !important;
}

.news-stepper .nav-link.active {
    color: var(--azul-marino) !important;
    border-bottom-color: var(--verde-institucional);
}

.news-stepper .step-number {
    display: inline-flex;
    width: 25px;
    height: 25px;
    background: #e9ecef;
    border-radius: 50%;
    align-items: center;
    justify-content: center;
    font-size: 0.75rem;
    margin-right: 8px;
}

.news-stepper .nav-link.active .step-number {
    background: var(--verde-institucional);
    color: white;
}

.textarea-editorial {
    font-family: 'Lora', serif;
    font-size: 1.1rem;
    line-height: 1.6;
}

/* Estilo para el recuadro de prioridad visual */
.priority-highlight-box {
    background-color: #fff9db;
    border: 2px solid #ffec99;
    color: #856404;
    transition: all 0.3s ease;
}

body.dark-mode .priority-highlight-box {
    background-color: #2d2a15 !important;
    border-color: #ffd43b !important;
    color: #ffe066 !important;
}