/* Agregado para carpeta test: marquee de marcas, FAQ, legales, blog */

.marcas-section { padding: 70px 0; background: var(--gray-light); overflow: hidden; }
.marcas-class { max-width: 1100px; margin: 0 auto; padding: 0 20px; text-align: center; }
.marcas-class h2 { font-size: 2.2em; color: var(--primary-color); margin-bottom: 10px; }
.marcas-subtitle { color: #666; margin-bottom: 40px; }

.marcas-marquee {
    position: relative;
    width: 100%;
    overflow: hidden;
    -webkit-mask-image: linear-gradient(90deg, transparent, #000 8%, #000 92%, transparent);
    mask-image: linear-gradient(90deg, transparent, #000 8%, #000 92%, transparent);
}
.marcas-marquee-track {
    display: flex;
    width: max-content;
    animation: marcas-scroll 40s linear infinite;
}
.marcas-marquee:hover .marcas-marquee-track { animation-play-state: paused; }
.marcas-marquee-track span {
    display: inline-flex;
    align-items: center;
    white-space: nowrap;
    font-weight: bold;
    font-size: 1.15rem;
    color: var(--dark-blue);
    background: var(--white);
    border: 1px solid #e2e2e2;
    border-radius: 30px;
    padding: 10px 22px;
    margin: 0 10px;
}
@keyframes marcas-scroll {
    from { transform: translateX(0); }
    to { transform: translateX(-50%); }
}
@media (prefers-reduced-motion: reduce) {
    .marcas-marquee-track { animation: none; }
}

/* FAQ */
.faq-section { padding: 60px 0; }
.faq-section .container, .faq-list { max-width: 850px; margin: 0 auto; padding: 0 20px; }
.faq-section h2 { text-align: center; margin-bottom: 10px; }
.faq-section .section-subtitle { text-align: center; color: #666; margin-bottom: 30px; }
.faq-item {
    border: 1px solid #e2e2e2;
    border-radius: 8px;
    margin-bottom: 12px;
    background: var(--white);
    overflow: hidden;
}
.faq-question {
    width: 100%;
    text-align: left;
    background: none;
    border: none;
    padding: 18px 20px;
    font-size: 1.05rem;
    font-weight: bold;
    color: var(--text-color);
    cursor: pointer;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 10px;
}
.faq-question:hover { color: var(--primary-color); }
.faq-question .faq-icon { flex-shrink: 0; font-size: 1.3rem; transition: transform 0.25s ease; color: var(--primary-color); }
.faq-item.active .faq-question .faq-icon { transform: rotate(45deg); }
.faq-answer {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease, padding 0.3s ease;
    padding: 0 20px;
}
.faq-item.active .faq-answer {
    max-height: 500px;
    padding: 0 20px 20px;
}
.faq-answer p { color: #555; }

/* Páginas legales */
.legal-page { padding: 140px 20px 80px; max-width: 850px; margin: 0 auto; }
.legal-page h1 { color: var(--dark-blue); margin-bottom: 8px; }
.legal-page .legal-updated { color: #888; font-size: 0.9rem; margin-bottom: 30px; }
.legal-page h2 { margin-top: 30px; margin-bottom: 12px; color: var(--text-color); }
.legal-page p, .legal-page li { color: #444; margin-bottom: 12px; }
.legal-page ul { padding-left: 22px; }
.legal-page .legal-highlight {
    background: var(--gray-light);
    border-left: 4px solid var(--primary-color);
    padding: 16px 20px;
    border-radius: 4px;
    margin: 20px 0;
}

/* Blog */
.blog-hero { padding: 140px 20px 40px; text-align: center; max-width: 900px; margin: 0 auto; }
.blog-hero h1 { color: var(--dark-blue); }
.blog-hero p { color: #666; margin-top: 10px; }
.blog-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(min(280px, 100%), 1fr));
    gap: 24px;
    max-width: 1100px;
    margin: 0 auto;
    padding: 20px 20px 80px;
}
.blog-card {
    background: var(--white);
    border: 1px solid #e2e2e2;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 2px 6px rgba(0,0,0,0.06);
    display: flex;
    flex-direction: column;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}
.blog-card:hover { transform: translateY(-4px); box-shadow: 0 6px 16px rgba(0,0,0,0.1); }
.blog-card-body { padding: 20px; display: flex; flex-direction: column; flex: 1; }
.blog-card-date { color: var(--primary-color); font-size: 0.85rem; font-weight: bold; margin-bottom: 8px; }
.blog-card h3 { margin-bottom: 10px; }
.blog-card p { color: #555; flex: 1; margin-bottom: 14px; }
.blog-card .btn { align-self: flex-start; }

.blog-article { padding: 140px 20px 80px; max-width: 780px; margin: 0 auto; }
.blog-article .blog-card-date { display: block; margin-bottom: 10px; }
.blog-article h1 { color: var(--dark-blue); margin-bottom: 20px; }
.blog-article h2 { margin-top: 28px; margin-bottom: 12px; }
.blog-article p, .blog-article li { color: #444; margin-bottom: 14px; }
.blog-article ul { padding-left: 22px; }
.blog-article table { width: 100%; border-collapse: collapse; margin: 18px 0; }
.blog-article th, .blog-article td { border: 1px solid #e2e2e2; padding: 10px 14px; text-align: left; }
.blog-article th { background: var(--gray-light); }
.blog-back { display: inline-block; margin-bottom: 20px; color: var(--primary-color); font-weight: bold; text-decoration: none; }
.blog-back:hover { text-decoration: underline; }

/* Logo agrandado 40% y centrado en el header, +30% adicional luego */
.logo img {
    height: 14.56vh; /* 8vh original + 40% + 30% */
    max-height: 78px;
    margin-left: 0;
}

@media (max-width: 480px) {
    .logo img {
        max-height: 57px;
    }
}

@media (min-width: 769px) {
    .main-header .container {
        display: grid;
        grid-template-columns: 1fr auto 1fr;
        align-items: center;
    }
    .main-header .container .main-logo-nav {
        grid-column: 2;
        justify-self: center;
    }
    .main-header .container .main-nav {
        grid-column: 3;
        justify-self: end;
    }
    .main-header .container .menu-toggle {
        grid-column: 1;
    }
}

/* Botón flotante de WhatsApp: -50% de tamaño + texto "Contactate ahora" debajo (solo /test) */
.whatsapp-widget {
    position: fixed;
    bottom: 20px;
    right: 20px;
    z-index: 1000;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 6px;
}

.whatsapp-widget .whatsapp-float {
    position: static;
    width: 6vh;
    height: 6vh;
}

.whatsapp-widget .whatsapp-float img {
    width: 4vh;
    height: 4vh;
}

.whatsapp-caption {
    background-color: #25D366;
    color: #fff;
    font-size: 0.75rem;
    font-weight: bold;
    padding: 4px 12px;
    border-radius: 20px;
    white-space: nowrap;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.25);
}

/* Rediseño de "Nuestros Servicios de Reparación de Electrodomésticos" (solo /test) */
.featured-services-section {
    padding: 70px 0 90px;
}

.featured-services-section h2 {
    font-size: 2.2em;
    margin-bottom: 45px;
}

.service-cards {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(min(300px, 100%), 1fr));
    gap: 30px;
    width: 100%;
    align-items: stretch;
}

.service-card {
    width: 100%;
    height: 100%;
    padding: 24px;
    border-radius: 16px;
    background-color: var(--white);
    border: 1px solid #ececec;
    box-shadow: 0 4px 14px rgba(0, 0, 0, 0.06);
    text-align: left;
}

.service-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 16px 30px rgba(0, 0, 0, 0.12);
    border-color: transparent;
}

.gallery-container {
    width: 100%;
    background-color: var(--gray-light);
    box-shadow: none;
}

.gallery-container-main-photo {
    height: 200px;
    padding: 0;
}

.main-service-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.thumbnail-nav {
    gap: 8px;
    padding: 10px;
    background-color: var(--white);
}

.thumbnail {
    width: 46px;
    height: 46px;
    object-fit: cover;
    flex-shrink: 0;
}

.service-card h3 {
    font-size: 1.3em;
    margin: 4px 0 10px;
}

.service-card p {
    font-size: 0.92em;
    line-height: 1.6;
    color: #555;
}

.featured-services-section .btn-whatsapp {
    margin-top: 10px;
}

/* Logos de marcas dentro del Hero (solo /test) */
.hero-brands {
    margin-top: 28px;
    max-width: 100%;
}

.hero-brands-label {
    font-size: 0.85rem;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: #fff;
    opacity: 0.85;
    margin-bottom: 12px;
    text-shadow: 1px 1px 2px rgba(0, 0, 0, 0.5);
}

.hero-brands-marquee {
    position: relative;
    width: 100%;
    overflow: hidden;
    -webkit-mask-image: linear-gradient(90deg, transparent, #000 10%, #000 90%, transparent);
    mask-image: linear-gradient(90deg, transparent, #000 10%, #000 90%, transparent);
}

.hero-brands-track {
    display: flex;
    align-items: center;
    width: max-content;
    animation: marcas-scroll 35s linear infinite;
}

.hero-brands-marquee:hover .hero-brands-track {
    animation-play-state: paused;
}

.hero-brand-item {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: #fff;
    border-radius: 10px;
    padding: 8px 14px;
    margin-right: 12px;
    box-shadow: 0 3px 10px rgba(0, 0, 0, 0.25);
    height: 44px;
    flex-shrink: 0;
}

.hero-brand-item img {
    height: 22px;
    width: auto;
    max-width: 90px;
    object-fit: contain;
    display: block;
}

@media (prefers-reduced-motion: reduce) {
    .hero-brands-track { animation: none; }
}

@media (max-width: 768px) {
    .hero-brand-item { height: 38px; padding: 6px 10px; }
    .hero-brand-item img { height: 18px; }
}

/* Rediseño de "¿Por qué elegir nuestro Servicio Técnico...?" (solo /test) */
.why-choose-us-section {
    padding: 80px 0 70px;
}

.why-choose-us-section h2 {
    font-size: 2.2em;
    margin-bottom: 45px;
}

.features-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(min(300px, 100%), 1fr));
    gap: 30px;
    align-items: stretch;
    width: 100%;
}

.feature-item,
.feature-item-second {
    flex-direction: column;
    width: 100%;
    height: 100%;
    background-color: rgba(255, 255, 255, 0.08);
    border: 1px solid rgba(255, 255, 255, 0.15);
}

.feature-image {
    width: 100%;
    height: 200px;
}

.feature-content {
    width: 100%;
    padding: 28px 24px;
    align-items: center;
    text-align: center;
}

.feature-content h3 {
    font-size: 1.25em;
}

.feature-content p {
    font-size: 0.95em;
}

@media (max-width: 1000px) {
    .feature-image { width: 100%; height: 200px; }
    .feature-content { width: 100%; text-align: center; padding: 24px; }
}

/* Hero: evitar que el contenido se corte en pantallas bajas (solo /test) */
.hero-section {
    height: auto;
    min-height: 100vh;
    max-height: none;
    overflow: visible;
    padding: 110px 0 50px;
}

@media (max-width: 768px) {
    .hero-section { padding: 90px 0 40px; }
}

/* Fix: la regla global ".container" en mobile (pensada solo para el header)
   rompía el contenedor de la sección FAQ, empujando el acordeón fuera
   de la pantalla y generando scroll horizontal (solo /test) */
@media (max-width: 768px) {
    .faq-section .container {
        display: block;
    }
}

/* Crédito de agencia en el footer, chico y discreto */
.footer-credit {
    font-size: 11px;
    margin-top: 4px;
    opacity: 0.6;
}

.footer-credit a {
    color: inherit;
    text-decoration: none;
}

.footer-credit a:hover {
    text-decoration: underline;
}

/* Botón "Ver más" a la landing page dedicada dentro de la tarjeta de servicio */
.service-card-link {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    margin-top: 14px;
    padding: 10px 20px;
    border-radius: 50px;
    border: 2px solid var(--primary-color);
    background-color: transparent;
    color: var(--primary-color);
    font-size: 0.85em;
    font-weight: 600;
    text-decoration: none;
    transition: all 0.25s ease;
}

.service-card-link::after {
    content: "\2192";
    transition: transform 0.25s ease;
}

.service-card-link:hover {
    background-color: var(--primary-color);
    color: var(--white);
    transform: translateY(-2px);
    box-shadow: 0 6px 14px rgba(0, 123, 255, 0.25);
}

.service-card-link:hover::after {
    transform: translateX(3px);
}
