.comments-section {
    background: #fff;
    border-radius: 8px;
    padding: 1.5rem;
    box-shadow: 0 2px 8px rgba(0,0,0,0.06);
    margin-top: 1.5rem;
}
.comments-section h4 {
    margin-bottom: 1rem;
    color: #228B22;
}
#comments-list {
    margin-top: 1rem;
}
.comment-item {
    border-bottom: 1px solid #eee;
    padding: 0.5rem 0;
    font-size: 1rem;
}
.comment-item .comment-name {
    font-weight: bold;
    color: #228B22;
    margin-right: 0.5rem;
}
.comment-item .comment-text {
    color: #333;
}
/* Botón 'Leer Muestra Gratis' igual que 'Comprar Ahora' */
.btn-large.btn-secondary {
    background: linear-gradient(90deg, #228B22 0%, #FFED4E 100%);
    color: #fff;
    border: none;
    font-weight: 700;
    padding: 1rem 2.5rem;
    font-size: 1.1rem;
    width: 100%;
    margin-bottom: 1rem;
    border-radius: 6px;
    box-shadow: 0 2px 8px rgba(34,139,34,0.08);
    transition: all 0.25s;
    display: block;
}
.btn-large.btn-secondary:hover {
    /* Mantener fondo y color de texto en hover */
    background: linear-gradient(90deg, #228B22 0%, #FFED4E 100%) !important;
    color: #fff !important;
    filter: brightness(1.08);
    box-shadow: 0 4px 16px rgba(34,139,34,0.15);
}
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    line-height: 1.6;
    color: #333;
}

.container {
    max-width: 1000px;
    margin: 0 auto;
    padding: 0 20px;
}

/* Encabezado */
.header {
    /* Try the image inside a 'header' folder first, then fallback to root header.png */
    background-image: url('header/header.png'), url('header.png');
    background-size: cover, cover;
    background-position: center center, center center;
    background-repeat: no-repeat, no-repeat;
    background-color: #FFED4E;
    padding: 0 20px;
    position: sticky;
    top: 0;
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
    z-index: 1000;
    height: 180px;
    display: flex;
    align-items: center;
}

/* Mostrar botón hamburguesa en todas las resoluciones */
.menu-toggle {
    display: flex;
    flex-direction: column;
    justify-content: space-around;
    width: 45px;
    height: 45px;
    background: rgba(34, 139, 34, 0.9);
    border: none;
    border-radius: 8px;
    cursor: pointer;
    padding: 10px;
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    right: 20px;
    z-index: 1200;
    box-shadow: 0 2px 8px rgba(0,0,0,0.3);
}

.menu-toggle span {
    width: 100%;
    height: 3px;
    background: #fff;
    border-radius: 2px;
    transition: all 0.3s;
}

.menu-toggle:hover {
    background: rgba(34, 139, 34, 1);
}

.header .container {
    width: auto;
    max-width: none;
    padding: 0;
    display: flex;
    justify-content: flex-start;
}

/* Header navigation: usar menú desplegable */
.header nav {
    position: fixed;
    top: 75px;
    right: 20px;
    width: 220px;
    background: rgba(255, 237, 78, 0.5);
    backdrop-filter: blur(8px);
    padding: 0.5rem 0;
    border-radius: 8px;
    box-shadow: 0 4px 20px rgba(0,0,0,0.5);
    transition: all 0.3s ease;
    z-index: 1100;
    opacity: 0;
    visibility: hidden;
    transform: translateY(-10px);
}

.header nav.active {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.header-nav ul {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 0;
    margin: 0;
    padding: 0;
    align-items: stretch;
}

.header-nav li {
    width: 100%;
    text-align: left;
    border-bottom: 1px solid rgba(34, 139, 34, 0.2);
}

.header-nav li:last-child {
    border-bottom: none;
}

.header-nav a {
    display: block;
    padding: 0.85rem 1.2rem;
    font-size: 1rem;
    width: 100%;
    background: transparent !important;
    color: #228B22 !important;
    text-decoration: none;
    transition: all 0.2s ease;
    font-weight: 700;
    border-radius: 0;
    box-shadow: none;
}

.header-nav a:hover {
    background: rgba(34, 139, 34, 0.15) !important;
    color: #1a6b1a !important;
}

/* Main navigation centered below header */
.main-nav {
    display: flex;
    justify-content: center;
    background: transparent;
    padding: 0.6rem 0;
}

.main-nav ul {
    list-style: none;
    display: flex;
    gap: 1rem;
    margin: 0;
    padding: 0;
}

.main-nav a {
    color: #DC143C;
    text-decoration: none;
    transition: all 0.25s;
    font-weight: 700;
    background: transparent;
    padding: 0.4rem 1rem;
    border-radius: 6px;
    border: 2px solid #DC143C;
    font-size: 1rem;
}

.main-nav a:hover {
    background: #DC143C;
    color: white;
    transform: translateY(-2px);
}

/* Responsive: mobile adjustments */
@media (max-width: 600px) {
    .main-nav {
        padding: 0.4rem 0;
    }

    .main-nav ul {
        flex-direction: column;
        gap: 0.5rem;
        align-items: center;
    }

    .main-nav a {
        padding: 0.5rem 0.8rem;
        font-size: 0.95rem;
        min-width: 140px;
        text-align: center;
    }

    .header {
        height: 160px;
        min-height: 160px;
        background-image: url('header-movil.png');
        background-size: contain;
        background-position: center center;
    }
    
    .menu-toggle {
        top: 50%;
        transform: translateY(-50%);
        right: 10px;
    }
    
    .header nav {
        top: 75px;
        right: 10px;
        width: 200px;
        background: rgba(255, 237, 78, 0.75);
    }
    
    .header nav a {
        text-shadow: 0 0 8px rgba(255, 237, 78, 0.9), 0 0 12px rgba(255, 237, 78, 0.6);
    }
}

@media (max-width: 360px) {
    .header {
        height: 120px;
        min-height: 120px;
    }
    
    .menu-toggle {
        width: 40px;
        height: 40px;
    }
    
    .header nav {
        width: 180px;
    }

    .main-nav a {
        font-size: 0.9rem;
        padding: 0.35rem 0.6rem;
        min-width: 110px;
    }
}

.header-title {
    display: none;
}

/* Keep .main-nav styles for fallback if used elsewhere (left as-is) */

/* Sección Hero */
.hero {
    background: linear-gradient(135deg, #FFD700 0%, #90EE90 100%);
    color: #333;
    padding: 5rem 0;
    text-align: center;
}

.hero h2 {
    font-size: 3rem;
    margin-bottom: 1rem;
}

.hero p {
    font-size: 1.2rem;
    margin-bottom: 2rem;
}

/* Sección del Libro */
.book-section {
    padding: 4rem 0;
    background: #f8f9fa;
}

.book-section h2 {
    text-align: center;
    font-size: 2.5rem;
    margin-bottom: 3rem;
    color: #333;
}

.book-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 3rem;
    align-items: start;
}

.book-cover {
    text-align: center;
}

.book-cover img {
    width: 100%;
    max-width: 300px;
    border-radius: 10px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.2);
    transition: transform 0.3s;
}

.book-cover img:hover {
    transform: scale(1.05);
}

.book-info h3 {
    font-size: 2rem;
    margin-bottom: 0.5rem;
    color: #228B22;
}

.book-info .author {
    color: #666;
    margin-bottom: 1rem;
    font-size: 1.1rem;
}

.book-info .description {
    margin-bottom: 1.5rem;
    font-size: 1rem;
    line-height: 1.8;
}

.book-details {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1rem;
    margin-bottom: 2rem;
    background: white;
    padding: 1rem;
    border-radius: 8px;
}

.detail {
    text-align: center;
}

.detail .label {
    display: block;
    font-weight: 600;
    color: #228B22;
    margin-bottom: 0.5rem;
}

.detail .value {
    display: block;
    font-size: 1.1rem;
    color: #333;
}

.price-section {
    background: white;
    padding: 1.5rem;
    border-radius: 8px;
    margin-bottom: 1.5rem;
}

.price {
    font-size: 2.5rem;
    font-weight: bold;
    color: #DC143C;
    margin-bottom: 1rem;
}

.testimonials {
    background: white;
    padding: 1.5rem;
    border-radius: 8px;
}

.testimonials h4 {
    margin-bottom: 1rem;
    color: #333;
}

.testimonial {
    padding: 1rem;
    margin-bottom: 1rem;
    border-left: 4px solid #228B22;
    padding-left: 1rem;
}

.testimonial p {
    margin-bottom: 0.5rem;
}

.author-test {
    color: #666;
    font-size: 0.9rem;
    font-weight: 600;
}

/* Sección de Proyecto */
.project-section {
    padding: 4rem 0;
}

.project-section h2 {
    text-align: center;
    font-size: 2.5rem;
    margin-bottom: 3rem;
    color: #333;
}

.project-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 3rem;
    align-items: center;
}

.project-image img {
    width: 100%;
    border-radius: 10px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.2);
}

.project-info h3 {
    font-size: 2rem;
    margin-bottom: 1rem;
    color: #228B22;
}

.project-info p {
    margin-bottom: 1.5rem;
    line-height: 1.8;
}

.project-features {
    list-style: none;
    margin-bottom: 2rem;
}

.project-features li {
    padding: 0.5rem 0;
    font-size: 1.1rem;
    color: #333;
}

/* Estilos para Proyect Reo */
.project-intro {
    max-width: 900px;
    margin: 0 auto 3rem;
    text-align: justify;
}

.project-intro p {
    margin-bottom: 1.2rem;
    line-height: 1.8;
    color: #333;
}

.project-intro blockquote {
    margin: 2rem 0;
    padding: 1.5rem;
    background: rgba(255, 237, 78, 0.15);
    border-left: 4px solid #228B22;
    font-style: italic;
    color: #555;
}

.project-gallery {
    margin: 2rem 0;
}

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

.gallery-grid img {
    width: 100%;
    height: 250px;
    object-fit: cover;
    border-radius: 8px;
    cursor: pointer;
    transition: transform 0.3s, box-shadow 0.3s;
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
}

.gallery-grid img:hover {
    transform: scale(1.05);
    box-shadow: 0 8px 24px rgba(0,0,0,0.2);
}

.project-separator {
    text-align: center;
    margin: 3rem 0 2rem;
}

.project-separator h3 {
    font-size: 2rem;
    color: #228B22;
    margin-bottom: 1rem;
}

.project-footer {
    text-align: center;
    margin-top: 3rem;
}

/* Sección de Redes Sociales */
.social-section {
    padding: 4rem 0;
    background: linear-gradient(135deg, #FFD700 0%, #90EE90 100%);
    color: #333;
}

.social-section h2 {
    text-align: center;
    font-size: 2.5rem;
    margin-bottom: 0.5rem;
}

.social-section .subtitle {
    text-align: center;
    margin-bottom: 3rem;
    font-size: 1.1rem;
    opacity: 0.9;
}

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

.social-btn {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 2rem;
    background: rgba(34, 139, 34, 0.1);
    border: 2px solid rgba(34, 139, 34, 0.3);
    border-radius: 10px;
    text-decoration: none;
    color: #333;
    transition: all 0.3s;
    backdrop-filter: blur(10px);
}

.social-btn:hover {
    background: rgba(34, 139, 34, 0.2);
    border-color: rgba(34, 139, 34, 0.6);
    transform: translateY(-5px);
}

/* Media section: gallery and video */
.media-section {
    padding: 3.5rem 0;
    background: #fff;
}

.media-section h2 {
    text-align: center;
    font-size: 2.2rem;
    margin-bottom: 0.5rem;
}

.media-section .subtitle {
    text-align: center;
    margin-bottom: 2rem;
    color: #666;
}

.media-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1rem;
    align-items: start;
}

.media-item {
    background: linear-gradient(180deg, rgba(255,255,255,0.9), #fff);
    border-radius: 8px;
    overflow: hidden;
    text-align: center;
    box-shadow: 0 8px 24px rgba(0,0,0,0.08);
    position: relative;
}

.media-item img {
    width: 100%;
    height: 160px;
    object-fit: cover;
    display: block;
    cursor: pointer;
}

.media-item figcaption {
    padding: 0.6rem 0.8rem;
    font-size: 0.95rem;
    color: #333;
}

.video-thumb { position: relative; }
.play-overlay {
    position: absolute;
    right: 10px;
    bottom: 10px;
    background: rgba(220,20,60,0.95);
    color: white;
    border: none;
    width: 44px;
    height: 44px;
    border-radius: 50%;
    font-size: 1.1rem;
    cursor: pointer;
    box-shadow: 0 6px 18px rgba(0,0,0,0.2);
}
.book-cover img {
    width: 100%;
    max-width: 320px;
    border-radius: 10px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.2);
    transition: transform 0.3s;
    margin-bottom: 1.2rem;
}

/* Modal / Lightbox */
.media-modal {
    position: fixed;
    inset: 0;
    display: none;
    align-items: center;
    justify-content: center;
    background: rgba(0,0,0,0.75);
    z-index: 2000;
    padding: 2rem;
}

.media-modal.open { display: flex; }

.media-modal .modal-content {
    max-width: 450px;
    width: 90%;
    max-height: 90vh;
    overflow-y: auto;
    overflow-x: hidden;
    border-radius: 8px;
    background: #111;
    padding: 1.5rem;
    position: relative;
}

.media-modal img, .media-modal video, .media-modal iframe {
    width: 100%;
    height: auto;
    display: block;
}

.media-modal .modal-close {
    position: absolute;
    right: 8px;
    top: 8px;
    background: rgba(255,255,255,0.08);
    color: #fff;
    border: none;
    width: 36px;
    height: 36px;
    border-radius: 6px;
    cursor: pointer;
}

@media (max-width: 600px) {
    .media-item img { height: 130px; }
    .media-modal .modal-content { max-width: 92%; }
}

.social-btn .icon {
    font-size: 2rem;
}

.social-btn .text {
    font-weight: 600;
    font-size: 1rem;
}

/* Newsletter */
.newsletter-section {
    padding: 3rem 0;
    background: #f8f9fa;
    text-align: center;
}

.newsletter-section h3 {
    font-size: 1.8rem;
    margin-bottom: 0.5rem;
    color: #333;
}

.newsletter-section p {
    margin-bottom: 1.5rem;
    color: #666;
}

.newsletter-form {
    display: flex;
    gap: 0.5rem;
    max-width: 500px;
    margin: 0 auto;
}

.newsletter-form input {
    flex: 1;
    padding: 0.75rem;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 1rem;
}

.newsletter-form input:focus {
    outline: none;
    border-color: #667eea;
    box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.1);
}

/* Botones */
.btn {
    background: linear-gradient(135deg, #228B22 0%, #FFD700 100%);
    color: white;
    padding: 0.75rem 2rem;
    border: none;
    border-radius: 4px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: transform 0.3s, box-shadow 0.3s;
    text-decoration: none;
    display: inline-block;
}

.btn:hover {
    transform: scale(1.05);
    box-shadow: 0 4px 12px rgba(34, 139, 34, 0.4);
}

.btn:active {
    transform: scale(0.95);
}

.btn-large {
    padding: 1rem 2.5rem;
    font-size: 1.1rem;
    width: 100%;
    margin-bottom: 1rem;
    box-sizing: border-box;
    min-width: 220px;
    max-width: 100%;
}

.btn-secondary {
    background: white;
    color: #228B22;
    border: 2px solid #228B22;
    width: 100%;
}

.btn-secondary:hover {
    background: #f0f0f0;
}

/* Pie de página */
.footer {
    background: #333;
    color: white;
    text-align: center;
    padding: 2rem 0;
}

.footer p {
    margin: 0.5rem 0;
}

/* Responsive */
@media (max-width: 768px) {
    .header h1 {
        font-size: 1.3rem;
    }

    .header nav ul {
        gap: 1rem;
        flex-direction: column;
    }

    .hero h2 {
        font-size: 2rem;
    }

    .book-content,
    .project-content {
        grid-template-columns: 1fr;
    }

    .book-section h2,
    .project-section h2,
    .social-section h2 {
        font-size: 1.8rem;
    }

    .book-details {
        grid-template-columns: 1fr;
    }

    .gallery-grid {
        grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
        gap: 0.5rem;
    }

    .gallery-grid img {
        height: 150px;
    }

    .project-intro {
        text-align: left;
    }

    .project-separator h3 {
        font-size: 1.5rem;
    }

    .newsletter-form {
        flex-direction: column;
    }

    .social-links {
        grid-template-columns: repeat(2, 1fr);
    }
}
