:root {
    --primary-blue: #1e40af;
    --secondary-blue: #3b82f6;
    --accent-gold: #f59e0b;
    --dark-bg: #1f2937;
    --light-bg: #f8fafc;
}

/* ===== HERO SECTION - ALTURAS OPTIMIZADAS ===== */
.hero-section {
    height: 70vh !important; 
    min-height: 500px;
    position: relative;
    overflow: hidden;
}

.carousel-background {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
}

/* ===== CAROUSEL CAPTION - ESCRITORIO ===== */
.carousel-caption {
    position: absolute !important;
    top: 50% !important;
    left: 50% !important;
    transform: translate(-50%, -50%) !important;
    text-align: center !important;
    width: 100% !important;
    color: white !important;
    text-shadow: 2px 2px 10px rgba(0,0,0,0.9) !important;
    z-index: 100 !important;
    opacity: 1 !important;
    visibility: visible !important;
    display: block !important;
    padding: 0 30px !important;
}

.carousel-caption h1 {
    font-size: 3.5rem !important;
    font-weight: 800 !important;
    margin-bottom: 1rem !important;
    line-height: 1.2 !important;
    color: white !important;
    opacity: 1 !important;
    visibility: visible !important;
    display: block !important;
}

.carousel-caption p.lead {
    font-size: 1.8rem !important;
    color: #9ca8ff !important;
    font-weight: 600 !important;
    text-shadow: 2px 2px 8px rgba(0,0,0,0.9) !important;
    margin-bottom: 2rem !important;
    line-height: 1.4 !important;
    opacity: 1 !important;
    visibility: visible !important;
    display: block !important;
    background-color: rgba(0,0,0,0.3) !important;
    padding: 10px 20px !important;
    border-radius: 10px !important;
    backdrop-filter: blur(5px) !important;
}

.carousel-caption .btn {
    opacity: 1 !important;
    visibility: visible !important;
    display: inline-block !important;
}

/* ELIMINAR CUALQUIER CLASE QUE OCULTE LOS SUBTÍTULOS */
.carousel-caption p,
.carousel-caption .lead,
.subtitle-visible {
    opacity: 1 !important;
    visibility: visible !important;
    display: block !important;
}

/* DESACTIVAR CUALQUIER d-none DE BOOTSTRAP */
.carousel-caption.d-none {
    display: block !important;
}

.carousel-caption .d-none {
    display: block !important;
}

.carousel-caption .d-md-block {
    display: block !important;
}

/* ===== DISTRIBUCIÓN MÓVIL - TÍTULO IZQUIERDA / BOTÓN DERECHA ===== */

/* MÓVILES LANDSCAPE y PORTRAIT (hasta 767px) */
@media (max-width: 767px) {
    .carousel-caption {
        display: flex !important;
        flex-direction: column !important;
        justify-content: center !important;
        align-items: flex-start !important;
        text-align: left !important;
        padding: 0 20px !important;
        top: 50% !important;
        left: 0 !important;
        transform: translateY(-50%) !important;
        width: 100% !important;
        height: 100% !important;
    }
    
    .carousel-caption-content {
        width: 100% !important;
        display: flex !important;
        flex-direction: column !important;
        justify-content: space-between !important;
        height: 70% !important;
        padding: 20px 0 !important;
    }
    
    .carousel-caption h1 {
        font-size: 1.8rem !important;
        margin-bottom: 0.8rem !important;
        line-height: 1.1 !important;
        text-align: left !important;
        width: 100% !important;
    }
    
    .carousel-caption p.lead {
        font-size: 1.1rem !important;
        margin-bottom: 1rem !important;
        font-weight: 500 !important;
        line-height: 1.3 !important;
        padding: 8px 12px !important;
        background-color: rgba(0,0,0,0.5) !important;
        text-align: left !important;
        width: 90% !important;
    }
    
    .carousel-caption .btn-container {
        width: 100% !important;
        display: flex !important;
        justify-content: flex-end !important;
        margin-top: auto !important;
    }
    
    .carousel-caption .btn {
        padding: 0.7rem 1.8rem !important;
        font-size: 0.9rem !important;
        align-self: flex-end !important;
        margin-left: auto !important;
    }
}

/* MÓVILES MUY PEQUEÑOS (hasta 400px) */
@media (max-width: 400px) {
    .carousel-caption {
        padding: 0 15px !important;
    }
    
    .carousel-caption h1 {
        font-size: 0.8rem !important;
        margin-bottom: 0.6rem !important;
        margin-top: 1rem !important;
    }
    
    .carousel-caption p.lead {
        font-size: 0.6rem !important;
        margin-bottom: 0.5rem !important;
        padding: 6px 10px !important;
        width: 95% !important;
    }
    
    .carousel-caption .btn {
        padding: 0.6rem 1.5rem !important;
        font-size: 0.85rem !important;
    }
}

/* ===== RESPONSIVE HERO HEIGHTS ===== */

/* ESCRITORIO (más de 1200px) */
@media (min-width: 1200px) {
    .hero-section {
        height: 80vh !important;
        min-height: 600px;
    }
}

/* TABLETS LANDSCAPE (992px - 1199px) */
@media (min-width: 992px) and (max-width: 1199px) {
    .hero-section {
        height: 75vh !important;
        min-height: 550px;
    }
}

/* TABLETS PORTRAIT (768px - 991px) */
@media (min-width: 768px) and (max-width: 991px) {
    .hero-section {
        height: 60vh !important;
        min-height: 450px;
    }
    
    .carousel-caption {
        width: 90% !important;
        padding: 0 20px !important;
        top: 50% !important;
    }
    
    .carousel-caption h1 {
        font-size: 2.2rem !important;
        margin-bottom: 0.7rem !important;
    }
    
    .carousel-caption p.lead {
        font-size: 1.3rem !important;
        margin-bottom: 1.3rem !important;
        padding: 6px 12px !important;
    }
}

/* MÓVILES LANDSCAPE (576px - 767px) */
@media (min-width: 576px) and (max-width: 767px) {
    .hero-section {
        height: 55vh !important;
        min-height: 400px;
    }
}

/* MÓVILES PORTRAIT (hasta 575px) */
@media (max-width: 575px) {
    .hero-section {
        height: 50vh !important;
        min-height: 350px;
    }
}

/* ===== MENÚ STICKY ===== */
.navbar.sticky-top {
    top: 56px;
    z-index: 1020;
}

/* ===== PÁGINAS MENÚ ===== */
.page-header {
    padding: 2rem 0;
}

.page-icon {
    text-align: center;
}

.page-content {
    font-size: 1.1rem;
    line-height: 1.7;
}

.page-content h2 {
    color: var(--bs-primary);
    margin-top: 2rem;
    margin-bottom: 1rem;
}

.page-content p {
    margin-bottom: 1.5rem;
}

/* ===== VALUE PROPOSITIONS ===== */
.value-card {
    background: white;
    border-radius: 15px;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    border: none;
    height: 100%;
}

.value-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 25px rgba(0,0,0,0.1);
    border-color: var(--bs-primary);
}

.value-icon {
    color: var(--bs-primary);
}

/* ===== BOTONES ===== */
.btn-primary {
    background: linear-gradient(135deg, var(--bs-primary), var(--bs-info));
    border: none;
    border-radius: 50px;
    font-weight: 600;
    transition: all 0.3s ease;
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(59, 130, 246, 0.4);
}

/* ===== BOTONES CIRCULARES ADMIN ===== */
.btn-circle {
    width: 28px;
    height: 28px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
    font-size: 11px;
    padding: 0;
    border: 2px solid transparent;
    transition: all 0.3s ease;
    text-decoration: none;
}

.btn-circle.btn-sm {
    width: 26px;
    height: 26px;
    font-size: 10px;
}

.btn-circle:hover {
    transform: scale(1.1);
    border-color: currentColor;
    text-decoration: none;
}

.btn-circle.btn-primary {
    background-color: #0d6efd;
    color: white;
}

.btn-circle.btn-info {
    background-color: #0dcaf0;
    color: white;
}

.btn-circle.btn-success {
    background-color: #198754;
    color: white;
}

.btn-circle.btn-warning {
    background-color: #ffc107;
    color: #000;
}

.btn-circle.btn-danger {
    background-color: #dc3545;
    color: white;
}

/* ===== UTILIDADES ===== */
.d-flex.gap-1 {
    gap: 4px !important;
}

.tooltip {
    font-size: 11px;
}

.table-hover tbody tr:hover {
    background-color: rgba(0, 0, 0, 0.025);
}

.badge {
    font-size: 0.75em;
    font-weight: 500;
}

form.d-inline .btn-circle {
    line-height: 1;
}

/* FORZAR COLOR DE TEXTO EN BOTONES CIRCULARES */
.btn-circle:not(.btn-warning) {
    color: white !important;
}

form.d-inline .btn-circle:not(.btn-warning) {
    color: white !important;
}
