/* ========================================
   PALETA DE COLORES
   ======================================== */
:root {
    /* Colores principales */
    --primary-orange: #FF6500;
    --primary-blue: #1E3E62;
    --dark-blue: #0B192C;
    --black: #000000;
    
    /* Variaciones de colores */
    --orange-light: #FF8533;
    --orange-dark: #CC5100;
    --blue-light: #2A5480;
    --blue-dark: #162D47;
    
    /* Colores de fondo */
    --bg-primary: #0B192C;
    --bg-secondary: #1E3E62;
    --bg-light: #f8f9fa;
    --bg-dark: #000000;
    
    /* Colores de texto */
    --text-light: #ffffff;
    --text-dark: #000000;
    --text-muted: #6c757d;
    
    /* Colores de estado */
    --success: #28a745;
    --warning: #ffc107;
    --danger: #dc3545;
    --info: #17a2b8;
    
    /* Sombras */
    --shadow-sm: 0 2px 4px rgba(0, 0, 0, 0.1);
    --shadow-md: 0 4px 8px rgba(0, 0, 0, 0.15);
    --shadow-lg: 0 8px 16px rgba(0, 0, 0, 0.2);
    
    /* Bordes */
    --border-radius: 8px;
    --border-radius-lg: 12px;
}

/* Tema Oscuro */
[data-bs-theme="dark"] {
    /* Fondos oscuros */
    --bg-light: #0B192C;
    --bg-primary: #000000;
    --bg-secondary: #1E3E62;
    
    /* Textos en modo oscuro */
    --text-dark: #ffffff;
    --text-muted: #b0b0b0;
    
    /* Sombras más sutiles para modo oscuro */
    --shadow-sm: 0 2px 4px rgba(0, 0, 0, 0.5);
    --shadow-md: 0 4px 8px rgba(0, 0, 0, 0.6);
    --shadow-lg: 0 8px 16px rgba(0, 0, 0, 0.7);
}

/* ========================================
   ESTILOS GENERALES
   ======================================== */
body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background-color: var(--bg-light);
    color: var(--text-dark);
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

main {
    flex: 1;
}

/* ========================================
   NAVBAR
   ======================================== */
.navbar {
    background: linear-gradient(135deg, var(--dark-blue) 0%, var(--primary-blue) 100%) !important;
    box-shadow: var(--shadow-md);
    padding: 1rem 0;
}

.navbar-brand {
    font-weight: 700;
    font-size: 1.5rem;
    color: var(--text-light) !important;
    transition: color 0.3s ease;
}

.navbar-brand:hover {
    color: var(--primary-orange) !important;
}

.navbar-brand i {
    color: var(--primary-orange);
    margin-right: 0.5rem;
}

.nav-link {
    color: var(--text-light) !important;
    font-weight: 500;
    transition: all 0.3s ease;
    position: relative;
    padding: 0.5rem 1rem !important;
}

.nav-link:hover {
    color: var(--primary-orange) !important;
}

.nav-link::after {
    content: '';
    position: absolute;
    width: 0;
    height: 2px;
    bottom: 0;
    left: 50%;
    background-color: var(--primary-orange);
    transition: all 0.3s ease;
    transform: translateX(-50%);
}

.nav-link:hover::after {
    width: 80%;
}



/* ========================================
   HERO SECTION
   ======================================== */
.hero-section {
    background: linear-gradient(135deg, var(--dark-blue) 0%, var(--primary-blue) 100%);
    color: var(--text-light);
    padding: 4rem 0;
    margin-bottom: 3rem;
    border-radius: var(--border-radius-lg);
    box-shadow: var(--shadow-lg);
}

.hero-section h1 {
    font-size: 3rem;
    font-weight: 700;
    margin-bottom: 1rem;
}

.hero-section .lead {
    font-size: 1.25rem;
    margin-bottom: 2rem;
    opacity: 0.9;
}

.hero-section .highlight {
    color: var(--primary-orange);
    font-weight: 700;
}

/* ========================================
   TARJETAS
   ======================================== */
.card {
    border: none;
    border-radius: var(--border-radius-lg);
    box-shadow: var(--shadow-sm);
    transition: all 0.3s ease;
    /* Eliminado height: 100% para permitir altura automática */
}

.card:hover {
    transform: translateY(-8px);
    box-shadow: var(--shadow-lg);
}

.card-header {
    background: linear-gradient(135deg, var(--primary-blue) 0%, var(--dark-blue) 100%);
    color: var(--text-light);
    font-weight: 700;
    border-radius: var(--border-radius-lg) var(--border-radius-lg) 0 0 !important;
    padding: 1.25rem;
}

.card-header i {
    color: var(--primary-orange);
    margin-right: 0.5rem;
    font-size: 1.5rem;
}

.card-body {
    padding: 1.5rem;
}

/* Estilo específico para cards con contenido compacto */
.card-body.py-3 {
    padding-top: 0.75rem !important;
    padding-bottom: 0.75rem !important;
}

/* Estilo para cards sin padding en el body (tablas) */
.card-body.p-0 {
    padding: 0 !important;
}

.card-title {
    color: var(--primary-blue);
    font-weight: 700;
    margin-bottom: 1rem;
}

.card-text {
    color: var(--text-muted);
    line-height: 1.6;
}

/* Estilos específicos para la tabla dentro del card */
.card .table-responsive {
    border-radius: 0 0 var(--border-radius-lg) var(--border-radius-lg);
}

.card .table {
    margin-bottom: 0;
}

.card .table thead th {
    background-color: #f8f9fa;
    border-bottom: 2px solid #dee2e6;
    font-weight: 600;
    color: var(--primary-blue);
    padding: 1rem 0.75rem;
}

.card .table tbody td {
    padding: 0.75rem;
    vertical-align: middle;
}

.card .table tbody tr:hover {
    background-color: rgba(0, 123, 255, 0.05);
}

/* Estilos para badges dentro de la tabla */
.card .badge {
    font-size: 0.75em;
    padding: 0.35em 0.65em;
}

/* Estilos para cards de texto centrado (sin resultados) */
.card.text-center .card-body {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
}

/* Responsive adjustments */
@media (max-width: 768px) {
    .card-header {
        padding: 1rem;
    }
    
    .card-body {
        padding: 1rem;
    }
    
    .card-body.py-3 {
        padding-top: 0.5rem !important;
        padding-bottom: 0.5rem !important;
    }
    
    .card .table thead th,
    .card .table tbody td {
        padding: 0.5rem 0.25rem;
        font-size: 0.875rem;
    }
}

/* Estilos para el card de resumen compacto */
.search-summary-card .card-body {
    padding: 0.75rem 1rem;
}

.search-summary-card .row {
    align-items: center;
}

.search-summary-card h4 {
    margin-bottom: 0.25rem;
    font-size: 1.5rem;
}

.search-summary-card .small {
    font-size: 0.8rem;
}

/* Tarjeta disponible */
.card.available {
    border-left: 4px solid var(--success);
}

/* Tarjeta próximamente */
.card.coming-soon {
    border-left: 4px solid var(--warning);
    opacity: 0.8;
}

.card.coming-soon .card-header {
    background: linear-gradient(135deg, #6c757d 0%, #495057 100%);
}


/* ========================================
   SECCIONES
   ======================================== */
.section-title {
    color: var(--primary-blue);
    font-weight: 700;
    margin-bottom: 2rem;
    position: relative;
    padding-bottom: 1rem;
}

.section-title::after {
    content: '';
    position: absolute;
    width: 80px;
    height: 4px;
    background-color: var(--primary-orange);
    bottom: 0;
    left: 0;
}

.text-center .section-title::after {
    left: 50%;
    transform: translateX(-50%);
}



/* ========================================
   FOOTER
   ======================================== */
footer {
    background: linear-gradient(135deg, var(--black) 0%, var(--dark-blue) 100%);
    color: var(--text-light);
    padding: 2rem 0;
    margin-top: auto;
    flex-shrink: 0;
    position: relative;
    z-index: 100;
}

/* Estilos para el contenido del footer */
.footer-content {
    position: relative;
    z-index: 101;
}

footer a {
    color: var(--primary-orange);
    text-decoration: none;
    transition: color 0.3s ease;
}

footer a:hover {
    color: var(--orange-light);
    text-decoration: underline;
}

/* Estilos para los enlaces de navegación del footer */
.footer-links {
    list-style: none;
    padding: 0;
    margin: 0;
}

.footer-links li {
    margin-bottom: 0.5rem;
}

.footer-links a {
    color: var(--text-light);
    opacity: 0.8;
    transition: all 0.3s ease;
}

.footer-links a:hover {
    color: var(--primary-orange);
    opacity: 1;
    padding-left: 5px;
}

/* Estilos para la información de copyright */
.footer-info {
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    padding-top: 1.5rem;
    margin-top: 1.5rem;
    font-size: 0.9rem;
    opacity: 0.7;
}

/* Estilos para íconos sociales en el footer */
.social-links {
    display: flex;
    gap: 1rem;
    justify-content: center;
}

.social-links a {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 50%;
    transition: all 0.3s ease;
}

.social-links a:hover {
    background: var(--primary-orange);
    transform: translateY(-3px);
}

/* Responsive design */
@media (max-width: 768px) {
    footer {
        padding: 1.5rem 0;
    }
    
    .footer-content {
        text-align: center;
    }
    
    .footer-links {
        margin: 1rem 0;
    }
    
    .social-links {
        margin: 1rem 0;
    }
    
    .footer-info {
        text-align: center;
        padding-top: 1rem;
        margin-top: 1rem;
    }
}

/* ========================================
   ALERTAS
   ======================================== */
.alert {
    border-radius: var(--border-radius);
    border: none;
}

.alert-warning {
    background-color: #fff3cd;
    color: #856404;
    border-left: 4px solid var(--warning);
}

.alert-info {
    background-color: #d1ecf1;
    color: #0c5460;
    border-left: 4px solid var(--info);
}

/* ========================================
   FORMULARIOS
   ======================================== */
.form-control:focus {
    border-color: var(--primary-orange);
    box-shadow: 0 0 0 0.2rem rgba(255, 101, 0, 0.25);
}

.form-label {
    color: var(--primary-blue);
    font-weight: 600;
}

/* ========================================
   UTILIDADES
   ======================================== */
.text-orange {
    color: var(--primary-orange) !important;
}

.text-primary-blue {
    color: var(--primary-blue) !important;
}

.bg-primary-blue {
    background-color: var(--primary-blue) !important;
}

.bg-dark-blue {
    background-color: var(--dark-blue) !important;
}

/* ========================================
   ANIMACIONES
   ======================================== */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.fade-in {
    animation: fadeIn 0.6s ease-in-out;
}


/* ========================================
   AJUSTES PARA TEMA OSCURO
   ======================================== */
[data-bs-theme="dark"] body {
    background-color: #0B192C;
    background-image: 
        radial-gradient(circle at 20% 50%, rgba(30, 62, 98, 0.1) 0%, transparent 50%),
        radial-gradient(circle at 80% 80%, rgba(255, 101, 0, 0.05) 0%, transparent 50%);
    color: var(--text-light);
}

[data-bs-theme="dark"] .card {
    background: linear-gradient(145deg, #1a2332 0%, #0f1a2a 100%);
    color: var(--text-light);
    border: 1px solid rgba(255, 101, 0, 0.1);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.6);
}

[data-bs-theme="dark"] .card:hover {
    border-color: rgba(255, 101, 0, 0.3);
    box-shadow: 0 8px 24px rgba(255, 101, 0, 0.2);
}

[data-bs-theme="dark"] .card-body {
    background: transparent;
}

[data-bs-theme="dark"] .card-text {
    color: #b0b0b0;
}

[data-bs-theme="dark"] .card-title {
    color: var(--primary-orange);
}

[data-bs-theme="dark"] .hero-section {
    background: linear-gradient(135deg, #000000 0%, #0B192C 50%, #1E3E62 100%);
    box-shadow: 0 8px 32px rgba(255, 101, 0, 0.15);
}

[data-bs-theme="dark"] .navbar {
    background: linear-gradient(135deg, #000000 0%, #0B192C 100%) !important;
    border-bottom: 1px solid rgba(255, 101, 0, 0.1);
}

[data-bs-theme="dark"] .feature-box h4,
[data-bs-theme="dark"] .feature-box h5 {
    color: var(--primary-orange);
}

[data-bs-theme="dark"] .section-title {
    color: var(--primary-orange);
}

[data-bs-theme="dark"] h1,
[data-bs-theme="dark"] h2,
[data-bs-theme="dark"] h3 {
    color: var(--text-light);
}

[data-bs-theme="dark"] .text-muted {
    color: #b0b0b0 !important;
}

[data-bs-theme="dark"] .alert-warning {
    background-color: rgba(255, 193, 7, 0.15);
    color: #ffc107;
    border-left: 4px solid #ffc107;
}

[data-bs-theme="dark"] .alert-info {
    background-color: rgba(23, 162, 184, 0.15);
    color: #17a2b8;
    border-left: 4px solid #17a2b8;
}

[data-bs-theme="dark"] .form-control {
    background-color: #1a2332;
    border-color: rgba(255, 101, 0, 0.2);
    color: var(--text-light);
}

[data-bs-theme="dark"] .form-control:focus {
    background-color: #0f1a2a;
    border-color: var(--primary-orange);
    color: var(--text-light);
    box-shadow: 0 0 0 0.2rem rgba(255, 101, 0, 0.25);
}

[data-bs-theme="dark"] .form-label {
    color: var(--primary-orange);
}

[data-bs-theme="dark"] .btn-outline-secondary {
    color: #b0b0b0;
    border-color: #6c757d;
}

[data-bs-theme="dark"] .btn-outline-secondary:hover {
    background-color: #6c757d;
    border-color: #6c757d;
    color: var(--text-light);
}

/* Card footer en modo oscuro */
[data-bs-theme="dark"] .card-footer {
    background-color: rgba(0, 0, 0, 0.2);
    border-top: 1px solid rgba(255, 101, 0, 0.1);
}

/* Badges en modo oscuro */
[data-bs-theme="dark"] .badge.bg-success {
    background-color: #28a745 !important;
    color: var(--text-light) !important;
}

/* Estilos para tablas en modo oscuro */
[data-bs-theme="dark"] .table {
    color: var(--text-light);
}

[data-bs-theme="dark"] .table-striped > tbody > tr:nth-of-type(odd) {
    background-color: rgba(255, 101, 0, 0.05);
}

/* Links en modo oscuro */
[data-bs-theme="dark"] a:not(.btn):not(.nav-link):not(.navbar-brand) {
    color: var(--primary-orange);
}

[data-bs-theme="dark"] a:not(.btn):not(.nav-link):not(.navbar-brand):hover {
    color: var(--orange-light);
}

/* Scrollbar en modo oscuro */
[data-bs-theme="dark"] ::-webkit-scrollbar {
    width: 10px;
    height: 10px;
}

[data-bs-theme="dark"] ::-webkit-scrollbar-track {
    background: #0B192C;
}

[data-bs-theme="dark"] ::-webkit-scrollbar-thumb {
    background: var(--primary-orange);
    border-radius: 5px;
}

[data-bs-theme="dark"] ::-webkit-scrollbar-thumb:hover {
    background: var(--orange-light);
}
/* ========================================
   RESPONSIVE
   ======================================== */
@media (max-width: 768px) {
    .hero-section h1 {
        font-size: 2rem;
    }
    
    .hero-section .lead {
        font-size: 1rem;
    }
    
    .btn-primary,
    .btn-outline-primary {
        padding: 0.5rem 1.5rem;
        font-size: 0.9rem;
    }
}

.hover-card {
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.hover-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 0.5rem 1rem rgba(0, 0, 0, 0.15) !important;
}

/* Sección Acerca de - Tema Claro */
.about-section {
    background-color: #f8f9fa;
    border: 1px solid rgba(0, 0, 0, 0.05);
}

/* Sección Acerca de - Tema Oscuro */
[data-bs-theme="dark"] .about-section {
    background: linear-gradient(145deg, #0f1a2a 0%, #162332 100%);
    border: 1px solid rgba(255, 101, 0, 0.15);
}

[data-bs-theme="dark"] .about-section h2,
[data-bs-theme="dark"] .about-section h5 {
    color: var(--primary-orange);
}

[data-bs-theme="dark"] .about-section .text-muted {
    color: #b0b0b0 !important;
}
