/* News Pages Styles */

/* Espaciado para botón fijo - Solo en páginas de noticias */
.news-page {
    padding-bottom: 40px; /* Espacio reducido ya que el footer maneja el espaciado */
}

.news-article {
    padding-bottom: 40px; /* Espacio reducido ya que el footer maneja el espaciado */
}

/* Link Color Management */
a {
    color: inherit;
    text-decoration: none;
}

a:link {
    color: inherit;
    text-decoration: none;
}

a:visited {
    color: inherit;
    text-decoration: none;
}

a:hover {
    color: inherit;
    text-decoration: none;
}

a:active {
    color: inherit;
    text-decoration: none;
}

/* Internal Links Styling - Bold and Underline for specific pages */
.news-content a {
    font-weight: bold;
    text-decoration: underline;
    color: inherit;
}

.news-content a:hover {
    font-weight: bold;
    text-decoration: underline;
    color: inherit;
}

.news-content a:visited {
    font-weight: bold;
    text-decoration: underline;
    color: inherit;
}

/* News Article Layout */
.news-article {
    max-width: 800px;
    margin: 0 auto;
    padding: 40px 20px;
}

.news-page {
    max-width: 1200px;
    margin: 0 auto;
    padding: 40px 20px;
}

/* News Header */
.news-header {
    text-align: center;
    margin-bottom: 40px;
}

.page-header {
    text-align: center;
    margin-bottom: 50px;
}

.news-title {
    font-size: 36px;
    font-weight: 700;
    color: #FFD700;
    margin-bottom: 20px;
    line-height: 1.2;
}

.page-title {
    font-size: 42px;
    font-weight: 700;
    color: #FFD700;
    margin-bottom: 20px;
}

.page-subtitle {
    font-size: 18px;
    color: #ccc;
    margin-bottom: 30px;
}

/* News Meta Information */
.news-meta {
    display: flex;
    justify-content: center;
    gap: 20px;
    margin-bottom: 30px;
    color: #ccc;
}

/* News Images */
.news-image {
    width: 100%;
    max-width: 600px;
    height: 400px;
    object-fit: cover;
    border-radius: 15px;
    margin: 0 auto 30px;
    display: block;
}

.article-image {
    width: 100%;
    height: 400px;
    object-fit: cover;
    border-radius: 15px;
    margin: 0 auto 30px;
    display: block;
}

/* News Content */
.news-content {
    background: rgba(26, 26, 51, 0.8);
    padding: 30px;
    border-radius: 20px;
    line-height: 1.8;
    font-size: 16px;
}

.article-content {
    background: rgba(26, 26, 51, 0.8);
    padding: 0 30px 30px;
    border-radius: 20px;
    line-height: 1.8;
    font-size: 16px;
}

.news-content h2 {
    color: #FFD700;
    font-size: 24px;
    margin: 30px 0 15px;
}

.article-content h2 {
    color: #FFD700;
    font-size: 20px;
    margin: 25px 0 15px;
}

.news-content p {
    margin-bottom: 20px;
}

.article-content p {
    margin-bottom: 15px;
}

/* FAQ Accordion */
.faq-section {
    margin-top: 40px;
    background: linear-gradient(135deg, rgba(47, 35, 101, 0.95), rgba(24, 16, 62, 0.95));
    border-radius: 24px;
    padding: 30px;
    box-shadow: 0 20px 45px rgba(18, 10, 45, 0.45);
}

.faq-section > h2 {
    margin-top: 0;
    font-size: 26px;
    line-height: 1.3;
    display: flex;
    align-items: center;
    gap: 12px;
}

.faq-accordion {
    margin-top: 20px;
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.faq-item {
    border: 1px solid rgba(255, 255, 255, 0.15);
    border-radius: 18px;
    background: rgba(18, 10, 45, 0.6);
    overflow: hidden;
    transition: border-color 0.3s ease, box-shadow 0.3s ease;
}

.faq-item.open {
    border-color: rgba(255, 215, 0, 0.8);
    box-shadow: 0 12px 30px rgba(255, 215, 0, 0.18);
}

.faq-question {
    width: 100%;
    background: transparent;
    border: none;
    color: white;
    text-align: left;
    padding: 18px 60px 18px 55px;
    font-size: 18px;
    font-weight: 700;
    cursor: pointer;
    position: relative;
    transition: color 0.3s ease, background 0.3s ease;
}

.faq-question:hover,
.faq-question:focus-visible {
    outline: none;
    color: #FFD700;
    background: rgba(255, 255, 255, 0.05);
}

.faq-number {
    position: absolute;
    left: 24px;
    top: 50%;
    transform: translateY(-50%);
    color: #FFD700;
    font-size: 18px;
    font-weight: 700;
}

.faq-toggle-icon {
    position: absolute;
    right: 24px;
    top: 50%;
    transform: translateY(-50%) rotate(0deg);
    width: 34px;
    height: 34px;
    border-radius: 50%;
    border: 2px solid rgba(255, 215, 0, 0.75);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: #FFD700;
    transition: transform 0.3s ease, background 0.3s ease, color 0.3s ease;
}

.faq-toggle-icon::before {
    content: '➜';
    font-size: 16px;
}

.faq-item.open .faq-toggle-icon {
    background: #FFD700;
    color: #2F1F63;
    transform: translateY(-50%) rotate(90deg);
}

.faq-answer {
    padding: 0 30px 24px 55px;
    color: rgba(255, 255, 255, 0.9);
    font-size: 16px;
    line-height: 1.7;
    animation: faqFadeIn 0.25s ease;
}

.faq-answer p {
    margin-bottom: 0;
}

.faq-answer[hidden] {
    display: none;
}

@keyframes faqFadeIn {
    from {
        opacity: 0;
        transform: translateY(-6px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Back Link */
.back-link {
    display: inline-block;
    background: #8B5CF6;
    color: white;
    padding: 12px 30px;
    border-radius: 25px;
    text-decoration: none;
    font-weight: 600;
    margin-bottom: 30px;
    transition: all 0.3s ease;
}

.back-link:link {
    color: white;
    text-decoration: none;
}

.back-link:visited {
    color: white;
    text-decoration: none;
}

.back-link:hover {
    color: white;
    text-decoration: none;
}

.back-link:active {
    color: white;
    text-decoration: none;
}

.back-link:hover {
    background: #A855F7;
    transform: translateY(-2px);
}

/* Read More Link */
.read-more-link {
    display: inline-block;
    background: linear-gradient(135deg, #8B5CF6, #A855F7);
    color: white;
    padding: 10px 25px;
    border-radius: 20px;
    text-decoration: none;
    font-weight: 600;
    margin-top: 20px;
    transition: all 0.3s ease;
}

.read-more-link:link {
    color: white;
    text-decoration: none;
}

.read-more-link:visited {
    color: white;
    text-decoration: none;
}

.read-more-link:hover {
    color: white;
    text-decoration: none;
}

.read-more-link:active {
    color: white;
    text-decoration: none;
}

.read-more-link:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(139, 92, 246, 0.4);
}

/* News Grid */
.news-grid {
    display: grid;
    gap: 40px;
    margin-bottom: 50px;
}

/* News Article Cards */
.news-article {
    background: rgba(26, 26, 51, 0.8);
    border-radius: 20px;
    overflow: hidden;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    cursor: pointer;
}

.news-article[data-article-url]:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 40px rgba(255, 215, 0, 0.2);
}

.article-header {
    padding: 30px 30px 20px;
    text-align: center;
}

.article-title {
    font-size: 28px;
    font-weight: 700;
    color: #FFD700;
    margin-bottom: 15px;
    line-height: 1.3;
}

.article-meta {
    display: flex;
    justify-content: center;
    gap: 20px;
    margin-bottom: 20px;
    color: #ccc;
    font-size: 14px;
}

/* Game List */
.game-list {
    background: rgba(51, 26, 77, 0.6);
    padding: 20px;
    border-radius: 15px;
    margin: 20px 0;
}

.game-list ol {
    color: #FFD700;
    font-weight: 600;
}

.game-list li {
    margin-bottom: 10px;
    color: white;
}

/* VR Features */
.vr-features {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 20px;
    margin: 30px 0;
}

.vr-feature {
    background: rgba(51, 26, 77, 0.6);
    padding: 20px;
    border-radius: 15px;
    text-align: center;
}

.vr-feature h3 {
    color: #FFD700;
    margin-bottom: 10px;
}

/* Highlight Boxes */
.warning-box {
    background: linear-gradient(135deg, #ff6b6b, #ee5a52);
    color: white;
    padding: 20px;
    border-radius: 10px;
    margin: 20px 0;
    border-left: 5px solid #d63031;
    box-shadow: 0 4px 15px rgba(255, 107, 107, 0.3);
    text-align: center;
}

.highlight-box {
    background: linear-gradient(135deg, #00b894, #00a085);
    color: white;
    padding: 25px;
    border-radius: 15px;
    margin: 25px 0;
    text-align: center;
    box-shadow: 0 6px 20px rgba(0, 184, 148, 0.3);
}

.demo-button {
    display: inline-block;
    background: #fdcb6e;
    color: #2d3436;
    padding: 15px 30px;
    border-radius: 25px;
    text-decoration: none;
    font-weight: bold;
    font-size: 18px;
    margin-top: 15px;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(253, 203, 110, 0.4);
}

.demo-button:hover {
    background: #e17055;
    color: white;
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(225, 112, 85, 0.4);
}

.info-box {
    background: linear-gradient(135deg, #74b9ff, #0984e3);
    color: white;
    padding: 20px;
    border-radius: 10px;
    margin: 20px 0;
    border-left: 5px solid #0984e3;
    box-shadow: 0 4px 15px rgba(116, 185, 255, 0.3);
    text-align: center;
}

.tip-box {
    background: linear-gradient(135deg, #a29bfe, #6c5ce7);
    color: white;
    padding: 20px;
    border-radius: 10px;
    margin: 20px 0;
    border-left: 5px solid #6c5ce7;
    box-shadow: 0 4px 15px rgba(162, 155, 254, 0.3);
    text-align: center;
}

/* Game Screenshots */
.game-screenshot {
    width: 100%;
    max-width: 600px;
    height: auto;
    border-radius: 15px;
    margin: 20px auto;
    display: block;
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.15);
    transition: transform 0.3s ease;
}

.game-screenshot:hover {
    transform: scale(1.02);
}

.screenshot-caption {
    text-align: center;
    font-style: italic;
    color: #666;
    margin-top: 10px;
    font-size: 14px;
}

/* Responsive Design */
@media (max-width: 768px) {
    .page-title {
        font-size: 32px;
    }
    
    .news-title {
        font-size: 28px;
    }
    
    .article-title {
        font-size: 24px;
    }
    
    .news-meta,
    .article-meta {
        flex-direction: column;
        gap: 10px;
    }
    
    .vr-features {
        grid-template-columns: 1fr;
    }
    
    .news-article {
        padding: 20px;
    }
    
    .news-content,
    .article-content {
        padding: 20px;
    }
    
    /* Botones en modo móvil - Columna con menor interlineado */
    .highlight-box,
    .warning-box,
    .info-box,
    .tip-box,
    .featured-section,
    .cta-box {
        text-align: center;
        padding: 15px;
        margin: 15px 0;
    }
    
    .article-cta-button {
        display: block;
        width: 100%;
        padding: 14px 25px;
        font-size: 16px;
        margin: 15px 0;
    }
    
    .featured-section h3,
    .cta-box h3 {
        font-size: 20px;
    }
    
    .cta-box p {
        font-size: 16px;
    }
    
    .highlight-box p,
    .warning-box p,
    .info-box p,
    .tip-box p {
        margin-bottom: 10px;
        line-height: 1.4;
    }
    
    .highlight-box h3,
    .warning-box h3,
    .info-box h3,
    .tip-box h3 {
        margin-bottom: 8px;
        line-height: 1.3;
    }
    
    .highlight-box ul,
    .warning-box ul,
    .info-box ul,
    .tip-box ul {
        text-align: left;
        margin: 10px 0;
        padding-left: 20px;
    }
    
    .highlight-box li,
    .warning-box li,
    .info-box li,
    .tip-box li {
        margin-bottom: 5px;
        line-height: 1.4;
    }
    
    /* Botones de demo y enlaces */
    .demo-button {
        display: block;
        width: 100%;
        margin: 10px 0;
        padding: 12px 20px;
        font-size: 16px;
        text-align: center;
    }
    
    .read-more-link {
        display: block;
        width: 100%;
        margin: 15px 0;
        padding: 12px 20px;
        text-align: center;
    }
    
    .back-link {
        display: block;
        width: 100%;
        text-align: center;
        margin-bottom: 20px;
    }
    
    /* Tablas responsivas */
    table {
        width: 100%;
        font-size: 14px;
    }
    
    table th,
    table td {
        padding: 8px 4px;
        text-align: center;
        word-wrap: break-word;
    }
    
    /* Enlaces internos en modo móvil */
    .news-content a,
    .article-content a {
        display: inline-block;
        margin: 5px 0;
        padding: 8px 12px;
        border-radius: 5px;
        text-align: center;
        word-wrap: break-word;
    }
    
    /* Espaciado reducido para listas */
    .news-content ul,
    .article-content ul,
    .news-content ol,
    .article-content ol {
        margin: 10px 0;
        padding-left: 20px;
    }
    
    .news-content li,
    .article-content li {
        margin-bottom: 8px;
        line-height: 1.4;
    }
    
    /* Imágenes responsivas */
    .news-image,
    .article-image,
    .game-screenshot {
        width: 100%;
        height: auto;
        max-height: 250px;
        object-fit: cover;
    }
    
    /* Espaciado móvil para botón fijo - Reducido porque el footer maneja el espaciado */
    .news-page,
    .news-article {
        padding-bottom: 40px; /* Espacio reducido ya que el footer maneja el espaciado */
    }
    
    .faq-section {
        padding: 20px;
    }

    .faq-question {
        padding: 16px 52px 16px 48px;
        font-size: 16px;
    }

    .faq-number {
        left: 18px;
    }

    .faq-toggle-icon {
        right: 16px;
        width: 30px;
        height: 30px;
    }

    .faq-answer {
        padding: 0 22px 20px 48px;
        font-size: 15px;
    }
}

/* Espaciado desktop para botón fijo - Reducido porque el footer maneja el espaciado */
@media (min-width: 769px) {
    .news-page,
    .news-article {
        padding-bottom: 40px; /* Espacio reducido ya que el footer maneja el espaciado */
    }
}

/* Espaciado adicional para secciones específicas */
.news-grid {
    margin-bottom: 40px;
}

.news-content,
.article-content {
    margin-bottom: 30px;
}

/* Asegurar que el último elemento tenga espacio suficiente */
.news-content > *:last-child,
.article-content > *:last-child {
    margin-bottom: 20px;
}

/* Espaciado para el botón "Volver" */
.back-link {
    margin-bottom: 30px;
}

/* Footer en noticias - Sobre el botón fijo para evitar espacio en blanco */
main + .footer {
    position: relative;
    z-index: 1001; /* Sobre el botón fijo (z-index: 1000) */
    margin-bottom: 0; /* Sin espacio extra ya que está sobre el botón */
}

/* Asegurar que el body tenga suficiente espacio para el footer */
body:has(.news-article) {
    padding-bottom: 0;
}

/* Ajustar el main para que el footer sea visible */
.news-article {
    margin-bottom: 0;
}

/* Asegurar que el footer se muestre correctamente en noticias */
body:has(.news-article) .footer {
    margin-top: 40px;
}
