/* Estilos generales */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    --primary-color: #4a6fa5;
    --secondary-color: #166088;
    --accent-color: #db5461;
    --light-color: #f8f9fa;
    --dark-color: #343a40;
    --success-color: #28a745;
    --warning-color: #ffc107;
    --danger-color: #dc3545;
    --border-radius: 8px;
    --box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    --transition: all 0.3s ease;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    line-height: 1.6;
    color: var(--dark-color);
    background-color: #f5f7fa;
}

.container {
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* Navegación */
.navbar {
    background-color: white;
    box-shadow: var(--box-shadow);
    position: sticky;
    top: 0;
    z-index: 1000;
}

.nav-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem 2rem;
    max-width: 1200px;
    margin: 0 auto;
}

.nav-brand h1 {
    color: var(--primary-color);
    font-size: 1.5rem;
    margin-bottom: 0.2rem;
}

.nav-brand p {
    color: var(--dark-color);
    font-size: 0.8rem;
    opacity: 0.8;
}

.nav-toggle {
    display: none;
    background: none;
    border: none;
    font-size: 1.5rem;
    color: var(--primary-color);
    cursor: pointer;
}

.nav-menu {
    display: flex;
    list-style: none;
}

.nav-menu li {
    margin-left: 1.5rem;
}

.nav-menu a {
    text-decoration: none;
    color: var(--dark-color);
    font-weight: 500;
    padding: 0.5rem 0.8rem;
    border-radius: var(--border-radius);
    transition: var(--transition);
    display: flex;
    align-items: center;
}

.nav-menu a i {
    margin-right: 0.5rem;
}

.nav-menu a:hover,
.nav-menu a.active {
    background-color: var(--primary-color);
    color: white;
}

/* Hero Section */
.hero {
    background: linear-gradient(rgba(74, 111, 165, 0.9), rgba(22, 96, 136, 0.9)), url('https://images.unsplash.com/photo-1518717758536-85ae29035b6d?ixlib=rb-1.2.1&auto=format&fit=crop&w=1350&q=80');
    background-size: cover;
    background-position: center;
    color: white;
    padding: 5rem 2rem;
    text-align: center;
}

.hero-content {
    max-width: 800px;
    margin: 0 auto;
}

.hero h1 {
    font-size: 3.5rem;
    margin-bottom: 1rem;
}

.highlight {
    color: #ffd166;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.3);
}

.subtitle {
    font-size: 1.5rem;
    margin-bottom: 1rem;
    opacity: 0.9;
}

.date {
    font-size: 1.1rem;
    margin-bottom: 2rem;
    background-color: rgba(255, 255, 255, 0.2);
    display: inline-block;
    padding: 0.5rem 1.5rem;
    border-radius: var(--border-radius);
}

.hero-buttons {
    display: flex;
    justify-content: center;
    gap: 1rem;
    flex-wrap: wrap;
}

.btn {
    display: inline-block;
    padding: 0.8rem 1.8rem;
    border-radius: var(--border-radius);
    text-decoration: none;
    font-weight: 600;
    transition: var(--transition);
    border: none;
    cursor: pointer;
    font-size: 1rem;
}

.btn-primary {
    background-color: var(--accent-color);
    color: white;
}

.btn-primary:hover {
    background-color: #c44550;
    transform: translateY(-3px);
    box-shadow: 0 6px 12px rgba(0, 0, 0, 0.15);
}

.btn-secondary {
    background-color: transparent;
    color: white;
    border: 2px solid white;
}

.btn-secondary:hover {
    background-color: white;
    color: var(--primary-color);
    transform: translateY(-3px);
}

/* Secciones comunes */
.section-header {
    text-align: center;
    margin-bottom: 3rem;
    padding-top: 3rem;
}

.section-header h2 {
    color: var(--primary-color);
    font-size: 2.2rem;
    margin-bottom: 0.5rem;
}

.section-header p {
    color: var(--dark-color);
    font-size: 1.1rem;
    opacity: 0.8;
}

.bg-light {
    background-color: var(--light-color);
    padding: 4rem 0;
}

.text-center {
    text-align: center;
    margin-top: 2rem;
}

/* Cards */
.card {
    background-color: white;
    border-radius: var(--border-radius);
    box-shadow: var(--box-shadow);
    margin-bottom: 2rem;
    overflow: hidden;
}

.card-header {
    background-color: var(--primary-color);
    color: white;
    padding: 1.5rem;
}

.card-header h2 {
    margin: 0;
    display: flex;
    align-items: center;
}

.card-header h2 i {
    margin-right: 0.8rem;
}

.card-body {
    padding: 2rem;
}

/* Grids */
.summary-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2rem;
    margin-bottom: 3rem;
}

.summary-card {
    background-color: white;
    border-radius: var(--border-radius);
    padding: 1.8rem;
    box-shadow: var(--box-shadow);
    transition: var(--transition);
    text-align: center;
}

.summary-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.1);
}

.summary-icon {
    font-size: 2.5rem;
    color: var(--primary-color);
    margin-bottom: 1rem;
}

.summary-card h3 {
    color: var(--primary-color);
    margin-bottom: 1rem;
    font-size: 1.3rem;
}

.summary-card p, .summary-card li {
    text-align: left;
    margin-bottom: 0.5rem;
}

.summary-card ul {
    list-style-position: inside;
    text-align: left;
}

.video-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: 2rem;
    margin-bottom: 2rem;
}

.video-card {
    background-color: white;
    border-radius: var(--border-radius);
    overflow: hidden;
    box-shadow: var(--box-shadow);
}

.video-container {
    position: relative;
    padding-bottom: 56.25%; /* 16:9 aspect ratio */
    height: 0;
    overflow: hidden;
}

.video-container iframe {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    border: none;
}

.video-info {
    padding: 1.5rem;
}

.video-info h3 {
    color: var(--primary-color);
    margin-bottom: 0.5rem;
}

/* Análisis */
.analysis-container {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 3rem;
    align-items: center;
}

.analysis-text p {
    margin-bottom: 1.5rem;
    font-size: 1.1rem;
    line-height: 1.8;
}

.chart-container {
    background-color: white;
    padding: 1.5rem;
    border-radius: var(--border-radius);
    box-shadow: var(--box-shadow);
}

.chart-container h4 {
    color: var(--primary-color);
    margin-bottom: 1.5rem;
    text-align: center;
}

.chart-bar {
    margin-bottom: 1.2rem;
}

.chart-label {
    font-size: 0.9rem;
    margin-bottom: 0.3rem;
    color: var(--dark-color);
}

.chart-bar-bg {
    height: 25px;
    background-color: #e9ecef;
    border-radius: 12.5px;
    overflow: hidden;
    position: relative;
}

.chart-bar-fill {
    height: 100%;
    background-color: var(--primary-color);
    border-radius: 12.5px;
    transition: width 1s ease;
}

.chart-bar-fill.negative {
    background-color: var(--danger-color);
}

.chart-bar-fill::after {
    content: attr(data-value);
    position: absolute;
    right: 10px;
    top: 50%;
    transform: translateY(-50%);
    color: white;
    font-size: 0.8rem;
    font-weight: bold;
}

/* Página de ficha de datos */
.page-header {
    background-color: var(--primary-color);
    color: white;
    padding: 3rem 0;
    text-align: center;
}

.page-header h1 {
    font-size: 2.5rem;
    margin-bottom: 1rem;
}

.page-header p {
    font-size: 1.2rem;
    opacity: 0.9;
}

.info-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 1.5rem;
}

.info-item {
    display: flex;
    flex-direction: column;
    padding: 1rem;
    background-color: #f8f9fa;
    border-radius: var(--border-radius);
}

.info-label {
    font-weight: bold;
    color: var(--primary-color);
    margin-bottom: 0.3rem;
}

.info-value {
    font-size: 1.1rem;
}

.info-list {
    list-style-type: none;
}

.info-list li {
    padding: 0.8rem 0;
    border-bottom: 1px solid #eee;
    display: flex;
    align-items: flex-start;
}

.info-list li i {
    color: var(--primary-color);
    margin-right: 1rem;
    margin-top: 0.2rem;
}

.problem-section {
    margin-bottom: 2.5rem;
    padding-bottom: 2rem;
    border-bottom: 1px solid #eee;
}

.problem-section:last-child {
    border-bottom: none;
}

.problem-section h3 {
    color: var(--secondary-color);
    margin-bottom: 1.2rem;
    display: flex;
    align-items: center;
}

.problem-section h3 i {
    margin-right: 0.8rem;
}

.problem-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 1.2rem;
    margin-bottom: 1.5rem;
}

.problem-item {
    padding: 1rem;
    border-radius: var(--border-radius);
    border-left: 5px solid var(--primary-color);
}

.problem-item.high {
    border-left-color: var(--danger-color);
    background-color: rgba(220, 53, 69, 0.05);
}

.problem-item.medium-high {
    border-left-color: var(--warning-color);
    background-color: rgba(255, 193, 7, 0.05);
}

.problem-item.medium {
    border-left-color: #ff9800;
    background-color: rgba(255, 152, 0, 0.05);
}

.problem-item.low {
    border-left-color: #17a2b8;
    background-color: rgba(23, 162, 184, 0.05);
}

.problem-label {
    font-weight: bold;
    margin-bottom: 0.3rem;
}

.problem-note {
    font-style: italic;
    background-color: #f8f9fa;
    padding: 0.8rem;
    border-radius: var(--border-radius);
    display: flex;
    align-items: center;
}

.problem-note i {
    margin-right: 0.8rem;
    color: var(--primary-color);
}

.analysis-box {
    background-color: #f8f9fa;
    padding: 2rem;
    border-radius: var(--border-radius);
    border-left: 5px solid var(--primary-color);
}

.analysis-box p {
    margin-bottom: 1.2rem;
}

.document-links {
    display: flex;
    flex-wrap: wrap;
    gap: 1rem;
}

.document-link {
    display: inline-flex;
    align-items: center;
    background-color: var(--primary-color);
    color: white;
    padding: 0.8rem 1.5rem;
    border-radius: var(--border-radius);
    text-decoration: none;
    transition: var(--transition);
}

.document-link i {
    margin-right: 0.8rem;
}

.document-link:hover {
    background-color: var(--secondary-color);
    transform: translateY(-3px);
}

/* Footer */
.footer {
    background-color: var(--dark-color);
    color: white;
    padding: 3rem 0 1rem;
    margin-top: 4rem;
}

.footer-container {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2rem;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 2rem;
}

.footer-section h3 {
    color: white;
    margin-bottom: 1.5rem;
    font-size: 1.3rem;
    display: flex;
    align-items: center;
}

.footer-section h3 i {
    margin-right: 0.8rem;
}

.footer-section p {
    margin-bottom: 1rem;
    opacity: 0.8;
    line-height: 1.6;
}

.footer-section ul {
    list-style: none;
}

.footer-section ul li {
    margin-bottom: 0.8rem;
}

.footer-section ul li a {
    color: #ddd;
    text-decoration: none;
    transition: var(--transition);
}

.footer-section ul li a:hover {
    color: white;
    padding-left: 0.5rem;
}

.footer-bottom {
    text-align: center;
    padding-top: 2rem;
    margin-top: 2rem;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    opacity: 0.7;
    font-size: 0.9rem;
}

/* Responsive */
@media (max-width: 992px) {
    .analysis-container {
        grid-template-columns: 1fr;
    }
    
    .hero h1 {
        font-size: 2.8rem;
    }
    
    .section-header h2 {
        font-size: 1.8rem;
    }
}

@media (max-width: 768px) {
    .nav-toggle {
        display: block;
    }
    
    .nav-menu {
        position: fixed;
        top: 70px;
        left: -100%;
        flex-direction: column;
        background-color: white;
        width: 100%;
        text-align: center;
        transition: var(--transition);
        box-shadow: var(--box-shadow);
        z-index: 999;
        padding: 1rem 0;
    }
    
    .nav-menu.active {
        left: 0;
    }
    
    .nav-menu li {
        margin: 0.5rem 0;
    }
    
    .nav-menu a {
        justify-content: center;
    }
    
    .hero-buttons {
        flex-direction: column;
        align-items: center;
    }
    
    .btn {
        width: 100%;
        max-width: 300px;
        text-align: center;
    }
}

@media (max-width: 576px) {
    .hero h1 {
        font-size: 2.2rem;
    }
    
    .subtitle {
        font-size: 1.2rem;
    }
    
    .summary-grid,
    .video-grid {
        grid-template-columns: 1fr;
    }
    
    .container,
    .nav-container {
        padding: 0 1rem;
    }
}
/* Estilos para la página de sesiones */
.session-counter {
    background-color: rgba(255, 255, 255, 0.2);
    padding: 0.8rem 1.5rem;
    border-radius: var(--border-radius);
    display: inline-block;
    margin-top: 1rem;
    font-size: 1.1rem;
}

.session-counter span {
    font-weight: bold;
    color: #ffd166;
    font-size: 1.5rem;
}

.filter-container {
    margin-bottom: 1.5rem;
}

.filter-buttons {
    display: flex;
    flex-wrap: wrap;
    gap: 0.8rem;
    margin-top: 1rem;
}

.filter-btn {
    padding: 0.5rem 1.2rem;
    background-color: #e9ecef;
    border: none;
    border-radius: 20px;
    cursor: pointer;
    transition: var(--transition);
    font-weight: 500;
}

.filter-btn.active,
.filter-btn:hover {
    background-color: var(--primary-color);
    color: white;
}

.table-responsive {
    overflow-x: auto;
}

.sessions-table {
    width: 100%;
    border-collapse: collapse;
}

.sessions-table th,
.sessions-table td {
    padding: 1rem;
    text-align: left;
    border-bottom: 1px solid #dee2e6;
}

.sessions-table th {
    background-color: #f8f9fa;
    font-weight: 600;
    color: var(--primary-color);
}

.sessions-table tr:hover {
    background-color: #f8f9fa;
}

.sessions-table td:last-child {
    text-align: center;
}

.sessions-table i {
    color: var(--primary-color);
}

.session-video-section {
    margin-bottom: 3rem;
    padding-bottom: 2rem;
    border-bottom: 1px solid #eee;
}

.session-video-section:last-child {
    border-bottom: none;
}

.session-title-right {
    text-align: right;
    color: var(--primary-color);
    margin-bottom: 1.5rem;
    padding-right: 1rem;
    font-size: 1.5rem;
}

.errata-section {
    background-color: #fff3cd;
    border-left: 5px solid #ffc107;
    padding: 1.5rem;
    margin: 2rem 0;
    border-radius: var(--border-radius);
}

.errata-section h3 {
    color: #856404;
    margin-bottom: 1rem;
}

/* Estilos para la página de evolución */
.timeline {
    position: relative;
    max-width: 1000px;
    margin: 0 auto;
}

.timeline::after {
    content: '';
    position: absolute;
    width: 6px;
    background-color: var(--primary-color);
    top: 0;
    bottom: 0;
    left: 50%;
    margin-left: -3px;
}

.timeline-item {
    padding: 10px 40px;
    position: relative;
    width: 50%;
    box-sizing: border-box;
}

.timeline-item::after {
    content: '';
    position: absolute;
    width: 20px;
    height: 20px;
    background-color: white;
    border: 4px solid var(--primary-color);
    border-radius: 50%;
    top: 15px;
    z-index: 1;
}

.timeline-item.left {
    left: 0;
}

.timeline-item.right {
    left: 50%;
}

.timeline-item.left::after {
    right: -13px;
}

.timeline-item.right::after {
    left: -13px;
}

.timeline-content {
    padding: 20px;
    background-color: white;
    border-radius: var(--border-radius);
    box-shadow: var(--box-shadow);
}

.timeline-date {
    font-weight: bold;
    color: var(--primary-color);
    margin-bottom: 0.5rem;
}

.progress-item {
    margin-bottom: 1.5rem;
    padding: 1rem;
    background-color: #f8f9fa;
    border-radius: var(--border-radius);
    border-left: 5px solid var(--success-color);
}

.progress-item.negative {
    border-left-color: var(--danger-color);
}

.progress-item.neutral {
    border-left-color: var(--warning-color);
}

.strategy-category {
    margin-bottom: 2.5rem;
}

.strategy-category h3 {
    color: var(--primary-color);
    border-bottom: 2px solid var(--primary-color);
    padding-bottom: 0.5rem;
    margin-bottom: 1.5rem;
}

.strategy-list {
    list-style-type: none;
}

.strategy-list li {
    padding: 0.8rem 0;
    border-bottom: 1px solid #eee;
    display: flex;
    align-items: flex-start;
}

.strategy-list li i {
    color: var(--success-color);
    margin-right: 1rem;
    margin-top: 0.2rem;
}

/* Estilos para la página de recursos */
.resources-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 1.5rem;
}

.resource-card {
    background-color: white;
    border-radius: var(--border-radius);
    padding: 1.5rem;
    box-shadow: var(--box-shadow);
    transition: var(--transition);
    border-top: 5px solid var(--primary-color);
}

.resource-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.1);
}

.resource-icon {
    font-size: 2rem;
    color: var(--primary-color);
    margin-bottom: 1rem;
}

.resource-card h3 {
    color: var(--primary-color);
    margin-bottom: 1rem;
}

.resource-links {
    margin-top: 1.5rem;
}

.resource-link {
    display: block;
    padding: 0.8rem;
    background-color: #f8f9fa;
    border-radius: var(--border-radius);
    margin-bottom: 0.8rem;
    text-decoration: none;
    color: var(--dark-color);
    transition: var(--transition);
    display: flex;
    align-items: center;
}

.resource-link i {
    margin-right: 0.8rem;
    color: var(--primary-color);
}

.resource-link:hover {
    background-color: var(--primary-color);
    color: white;
}

.resource-link:hover i {
    color: white;
}

.infographics-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    gap: 1.5rem;
    margin-top: 2rem;
}

.infographic-item {
    background-color: white;
    border-radius: var(--border-radius);
    overflow: hidden;
    box-shadow: var(--box-shadow);
    transition: var(--transition);
}

.infographic-item:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.1);
}

.infographic-item img {
    width: 100%;
    height: 200px;
    object-fit: cover;
}

.infographic-label {
    padding: 1rem;
    text-align: center;
    font-weight: 500;
    color: var(--primary-color);
}

/* Estilos para la página del juego */
.game-container {
    max-width: 900px;
    margin: 0 auto;
    background-color: white;
    border-radius: var(--border-radius);
    box-shadow: var(--box-shadow);
    padding: 2rem;
    margin-bottom: 3rem;
}

.game-header {
    text-align: center;
    margin-bottom: 2rem;
}

.game-header h2 {
    color: var(--primary-color);
    margin-bottom: 1rem;
}

.game-canvas-container {
    position: relative;
    margin-bottom: 1.5rem;
}

#gameCanvas {
    display: block;
    margin: 0 auto;
    border: 3px solid var(--primary-color);
    border-radius: var(--border-radius);
    background-color: #f0f8ff;
}

.game-controls {
    display: flex;
    justify-content: center;
    gap: 1rem;
    margin-top: 1.5rem;
}

.game-btn {
    padding: 0.8rem 1.5rem;
    background-color: var(--primary-color);
    color: white;
    border: none;
    border-radius: var(--border-radius);
    cursor: pointer;
    font-weight: 600;
    transition: var(--transition);
    display: flex;
    align-items: center;
}

.game-btn i {
    margin-right: 0.5rem;
}

.game-btn:hover {
    background-color: var(--secondary-color);
    transform: translateY(-3px);
}

.game-instructions {
    background-color: #f8f9fa;
    padding: 1.5rem;
    border-radius: var(--border-radius);
    margin-top: 2rem;
}

.game-instructions h3 {
    color: var(--primary-color);
    margin-bottom: 1rem;
}

.phase-list {
    list-style-type: none;
    counter-reset: phase-counter;
}

.phase-list li {
    counter-increment: phase-counter;
    margin-bottom: 1rem;
    padding-left: 2.5rem;
    position: relative;
}

.phase-list li::before {
    content: counter(phase-counter);
    position: absolute;
    left: 0;
    top: 0;
    background-color: var(--primary-color);
    color: white;
    width: 24px;
    height: 24px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.9rem;
    font-weight: bold;
}

/* Responsive para la línea de tiempo */
@media (max-width: 768px) {
    .timeline::after {
        left: 31px;
    }

    .timeline-item {
        width: 100%;
        padding-left: 70px;
        padding-right: 25px;
    }

    .timeline-item.right {
        left: 0;
    }

    .timeline-item.left::after,
    .timeline-item.right::after {
        left: 18px;
    }
}

/* Responsive para la tabla */
@media (max-width: 768px) {
    .sessions-table {
        font-size: 0.9rem;
    }
    
    .sessions-table th,
    .sessions-table td {
        padding: 0.8rem 0.5rem;
    }
}

/* Ajustes para móviles */
@media (max-width: 576px) {
    .filter-buttons {
        justify-content: center;
    }
    
    .game-controls {
        flex-direction: column;
        align-items: center;
    }
    
    .game-btn {
        width: 100%;
        max-width: 250px;
        justify-content: center;
    }
    
    .resources-grid,
    .infographics-grid {
        grid-template-columns: 1fr;
    }
}