body.cb-body {
    background-image: url('../img/fondo_tuff.png');
    background-size: cover;
    background-attachment: fixed;
    background-position: center;
    background-repeat: no-repeat;
    position: relative;
}

/* The background wave effect was removed as requested */

:root {
    --cb-blue-primary: #0085C8;
    --cb-blue-dark: #003D73;
    --cb-blue-light: #E3F2FD;
    --cb-white: #ffffff;
    --cb-bg-gray: #f8f9fa;
}

/* Hero override for this page */
.cb-body .hero-imagen-fondo {
    background-image: url('../img/basico/fondoCB.webp');
}

/* Hero overrides removed to fix mobile bugs and consolidate design */

/* Wave dividers were removed as requested */

.section-transition-bar {
    background-color: transparent; /* Totally clear to see the body wave */
    width: 100%;
    height: 70px;
    display: flex;
    align-items: center;
    position: relative;
    z-index: 5;
    margin-top: 20px; /* Separado del hero */
    margin-bottom: 20px;
    cursor: pointer;
}

.section-label-mockup {
    background-color: #0085C8;
    color: #ffffff;
    padding: 1rem 4rem;
    border-radius: 50px 0 0 50px;
    font-weight: 800;
    text-transform: uppercase;
    box-shadow: -10px 5px 20px rgba(0,0,0,0.15);
    position: absolute;
    right: 0;
    top: 50%;
    transform: translateY(-50%);
    font-size: 1rem;
    letter-spacing: 2px;
}

.section-label-mockup--left {
    right: auto;
    left: 0;
    border-radius: 0 50px 50px 0;
    box-shadow: 10px 5px 20px rgba(0,0,0,0.15);
}

/* GENERAL SECTION LAYOUT */
.cb-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 1.5rem;
}

.cb-section {
    padding: 0 0 6rem;
    background-color: transparent;
    position: relative;
    z-index: 1;
}

.cb-intro-container {
    background: #0085C8;
    color: white;
    padding: 6rem 10%;
    margin-bottom: 5rem;
    position: relative;
    box-shadow: 0 10px 30px rgba(0,0,0,0.15);
    overflow: hidden;
}

.cb-intro-container::after {
    content: '';
    position: absolute;
    bottom: -50px;
    right: -100px;
    width: 600px;
    height: 400px;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 50%;
    transform: rotate(15deg);
}

.cb-intro-container--blue {
    background-color: #0085C8;
}

.cb-intro-container .cb-section__text {
    color: white;
}

/* Wavy divider at the bottom of intro if needed */
.cb-intro-container + .cb-container {
    margin-top: -3rem;
    position: relative;
    z-index: 2;
}

/* Mockup background stripes effect */
.cb-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: repeating-linear-gradient(
        -45deg,
        rgba(0, 133, 200, 0.03),
        rgba(0, 133, 200, 0.03) 100px,
        transparent 100px,
        transparent 200px
    );
    pointer-events: none;
    z-index: 0;
}

.cb-grid-2 {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: center;
    position: relative;
    z-index: 1;
}

.cb-illustration {
    width: 100%;
    aspect-ratio: 16/9;
    border-radius: 100px 500px 500px 100px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.2);
    overflow: hidden;
    position: relative;
}

.cb-illustration--right {
    border-radius: 500px 100px 100px 500px;
}

.cb-illustration img {
    width: 100%;
    display: block;
    height: 100%;
    object-fit: cover;
}

.cb-year-badge {
    margin-left: auto;
    margin-right: 10%;
    background: #003D73;
    color: white;
    padding: 0.7rem 1.5rem;
    border-radius: 12px;
    font-weight: 800;
    font-size: 0.9rem;
    display: flex;
    align-items: center;
    box-shadow: 0 4px 10px rgba(0,0,0,0.15);
    transition: background 0.3s;
}

.cb-year-badge:hover {
    background: #005A8C;
}

.cb-section__text {
    font-size: 1.35rem;
    line-height: 1.6;
    font-weight: 500;
}

/* TABS SYSTEM */
.cb-tabs-container {
    margin-top: 4rem;
    text-align: center;
}

.cb-plan-de-box {
    background-color: transparent;
    display: inline-block;
    padding: 0;
    border-radius: 0;
    box-shadow: none;
    width: 100%;
    max-width: 600px;
    margin-bottom: 2rem;
}

.cb-plan-de-title {
    color: #003D73;
    font-size: 2.2rem;
    font-weight: 900;
    margin-bottom: 1.5rem;
    text-transform: uppercase;
    letter-spacing: 2px;
}

.cb-tabs-header {
    background-color: rgba(0, 133, 200, 0.05);
    display: flex;
    padding: 8px;
    border-radius: 16px;
    backdrop-filter: blur(10px);
    border: 1px solid rgba(0, 133, 200, 0.15);
    box-shadow: 0 4px 15px rgba(0,0,0,0.05);
}

.cb-tab-btn {
    flex: 1;
    padding: 0.8rem 1.5rem;
    border: none;
    background: transparent;
    color: #003D73;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    font-size: 1.1rem;
    border-radius: 12px;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.cb-tab-btn:hover:not(.active) {
    background-color: rgba(0, 133, 200, 0.1);
    transform: translateY(-2px);
}

.cb-tab-btn.active {
    background-color: #003D73;
    color: white;
    box-shadow: 0 8px 15px rgba(0, 61, 115, 0.2);
    transform: scale(1.05);
}

.cb-tab-content {
    display: none;
    animation: fadeIn 0.5s ease;
}

.cb-tab-content.active {
    display: block;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(10px); }
    to { opacity: 1; transform: translateY(0); }
}

/* CURRICULUM GRID */
.cb-section-title {
    font-size: 2.5rem;
    color: #444;
    margin: 3rem 0;
    font-weight: 700;
    letter-spacing: 2px;
}

.cb-curriculum-grid {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 3rem 2rem;
    margin-top: 3rem;
    padding: 1rem;
}

.cb-curriculum-grid--talleres {
    gap: 3.5rem 2.5rem;
}

.cb-card {
    background: transparent;
    border: none;
    backdrop-filter: none;
    -webkit-backdrop-filter: none;
    border-radius: 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    width: auto;
    min-width: 140px;
    max-width: 195px;
    gap: 0.8rem;
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    padding: 1rem;
    box-shadow: none;
    cursor: default;
    pointer-events: auto;
    position: relative;
    overflow: visible;
}

/* Solo hover en dispositivos que lo soporten (computadoras) */
@media (hover: hover) {
    .cb-card:hover {
        transform: translateY(-8px) scale(1.08);
    }
    
    .cb-card:hover .cb-card__subject-icon {
        background: linear-gradient(135deg, #E3F2FD 0%, #FFFFFF 100%) !important;
        box-shadow: 0 15px 30px rgba(0, 133, 200, 0.3);
        border-color: #0085C8 !important;
        color: #003D73 !important;
    }
}

.cb-card__header {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.8rem;
    width: 100%;
}

.cb-card__subject-icon {
    flex-shrink: 0;
    width: 120px;
    height: 120px;
    background: linear-gradient(135deg, #ffffff 0%, #f0f7ff 100%);
    color: #003D73;
    border-radius: 50%;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    font-size: 2.8rem; 
    box-shadow: 0 10px 25px rgba(0, 78, 142, 0.15);
    border: 4px solid #0085C8;
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    position: relative;
    line-height: 0 !important;
}

/* Perfect centering for Font Awesome glyphs */
.cb-card__subject-icon::before {
    display: inline-block !important;
    line-height: 0 !important;
    margin: 0 !important;
    padding: 0 !important;
    vertical-align: middle !important;
}

/* Sutil brillo interno para mantener el look premium */
.cb-card__subject-icon::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, rgba(255,255,255,0.4) 0%, transparent 60%);
    pointer-events: none;
    border-radius: 50%; /* CORREGIDO: Asegura que el brillo sea circular y no cuadrado */
}

.cb-card__title {
    font-size: 1rem;
    font-weight: 800;
    color: #333;
    line-height: 1.2;
    max-width: 100%;
    word-wrap: break-word;
    overflow-wrap: break-word;
    hyphens: none; /* Desactivado para evitar cortes feos como ALGORIT-MOS */
    text-transform: uppercase;
    padding: 0 4px;
    text-align: center;
}

.cb-card__hours {
    display: none !important;
}

.cb-card--hours-display {
    background-color: #003D73;
    color: white;
    font-weight: 700;
    font-size: 1.2rem;
    box-shadow: 0 8px 20px rgba(0,0,0,0.2);
    cursor: default;
}

.cb-card--hours-display:hover {
    transform: none;
    box-shadow: 0 8px 20px rgba(0,0,0,0.2);
}

/* Syllabus Detail Section */
.syllabus-detail {
    max-height: 0;
    overflow: hidden;
    transition: all 0.5s cubic-bezier(0.4, 0, 0.2, 1);
    background-color: #f1f8ff;
    border-radius: 20px;
    margin: 2rem 10% 0;
    opacity: 0;
    transform: translateY(-20px);
}

.syllabus-detail.active {
    max-height: 2000px;
    padding: 3rem;
    opacity: 1;
    transform: translateY(0);
    box-shadow: 0 15px 40px rgba(0,0,0,0.1);
    border: 2px solid #e1effe;
}

.syllabus-detail__content {
    max-width: 1000px;
    margin: 0 auto;
}

.syllabus-detail__title {
    color: var(--cb-blue-dark);
    margin-bottom: 2.5rem;
    text-align: center;
    font-size: 2.2rem;
    font-weight: 800;
}

.syllabus-detail__grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2.5rem;
}

.syllabus-detail__item {
    background: white;
    padding: 1.5rem;
    border-radius: 15px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.05);
    transition: transform 0.3s;
}

.syllabus-detail__item:hover {
    transform: translateY(-5px);
}

.syllabus-detail__item h4 {
    color: var(--cb-blue-primary);
    margin-bottom: 1rem;
    font-size: 1.3rem;
    font-weight: 700;
}

.syllabus-detail__item p {
    color: #555;
    line-height: 1.6;
    font-size: 1.05rem;
}

/* FOOTER UPDATES (PREMIUM) */

.cb-footer {
    background-color: var(--cb-blue-primary);
    color: white;
    padding: 4rem 10% 2rem;
}

.cb-footer__container {
    display: flex;
    justify-content: space-between;
    align-items: flex-end;
    gap: 4rem;
}

.cb-footer__links {
    display: flex;
    flex-direction: column;
    gap: 0.8rem;
}

.cb-footer__links a {
    color: white;
    text-decoration: none;
    font-size: 1.1rem;
    transition: opacity 0.3s;
}

.cb-footer__links a:hover {
    opacity: 0.7;
}

.cb-footer__redes {
    display: flex;
    gap: 1.5rem;
    margin-top: 2rem;
    font-size: 1.8rem;
}

.cb-footer__mapa {
    flex-grow: 1;
    max-width: 450px;
    height: 200px;
    border-radius: 15px;
    overflow: hidden;
    box-shadow: 0 10px 25px rgba(0,0,0,0.2);
}

.cb-footer__mapa iframe {
    width: 100%;
    height: 100%;
    border: none;
}

.cb-footer__bottom {
    margin-top: 3rem;
    padding-top: 2rem;
    border-top: 1px solid rgba(255,255,255,0.2);
    text-align: center;
    font-size: 1rem;
    opacity: 0.8;
}

/* RESPONSIVE */
@media (max-width: 768px) {
    .cb-grid-2 { 
        grid-template-columns: 1fr; 
        gap: 2rem; 
    }
    
    .cb-illustration { 
        order: -1; 
        border-radius: 20px;
        aspect-ratio: 4/3;
        margin: 0 auto 1.5rem; /* Center with margin */
        width: 90%;
        max-width: 400px;
    }
    
    .cb-intro-container {
        padding: 3rem 0;
        margin-left: -5%;
        margin-right: -5%;
        width: 110%;
        border-radius: 0;
        box-shadow: none;
    }

    .cb-intro-container .cb-grid-2 {
        padding: 0 10%;
    }

    .cb-section { padding: 3rem 0; }
    
    .cb-curriculum-grid { 
        display: grid;
        grid-template-columns: repeat(2, 1fr); 
        gap: 1.2rem 0.8rem;
        padding: 0 8px;
    }
    
    .cb-card {
        min-height: 140px;
        height: auto;
        padding: 1rem 0.6rem;
        font-size: 0.9rem;
        margin: 0;
        width: 100%;
        max-width: none;
        background: transparent;
        box-shadow: none;
        border: none;
        backdrop-filter: none;
    }

    .cb-card__subject-icon {
        width: 85px;
        height: 85px;
        font-size: 2rem;
        border-width: 3px;
    }

    .cb-card__title {
        font-size: 0.85rem;
    }

    .cb-card__hours {
        font-size: 0.65rem;
        padding: 0.1rem 0.4rem;
        top: 8px;
        right: 8px;
    }

    .cb-section-title {
        font-size: 1.8rem;
        margin: 2rem 0;
        text-align: center;
    }

    .cb-footer__container { flex-direction: column; align-items: center; text-align: center; }
    .cb-footer__mapa { width: 100%; }

    .cb-plan-de-box {
        max-width: 90%;
    }
}
