/**
 * Homepage Sections Styles - Monitor Latino
 */

/* 1. DESTACADOS DE LA SEMANA */
.ml-top5-section {
    position: relative;
    background: #000;
    padding: 50px 24px;
    margin: 0;
    overflow: hidden;
}
.ml-top5-section::before {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background:
        radial-gradient(120% 90% at 50% -10%, #1f1f26 0%, rgba(10,10,13,0) 55%),
        linear-gradient(180deg, #0e0e12 0%, #08080b 100%);
    opacity: 1;
    z-index: 0;
}
.ml-top5-container {
    position: relative;
    z-index: 2;
    max-width: 1200px;
    margin: 0 auto;
}
.ml-top5-title {
    text-align: center;
    font-size: 32px;
    font-weight: 800;
    color: #fff;
    margin: 0 0 24px 0;
}
.ml-top5-btn-wrap {
    text-align: center;
    margin-top: 30px;
}
.ml-top5-btn {
    display: inline-block;
    background: #FFC508;
    color: #000;
    padding: 12px 36px;
    border-radius: 60px;
    text-decoration: none;
    font-weight: 700;
    font-size: 14px;
    transition: all 0.3s ease;
}
.ml-top5-btn:hover {
    background: #fff;
    transform: translateY(-2px);
}

/* 1.b DIGITAL LATINO VIDEOS (shortcode [digital_latino_videos]) */
.ml-top5-section {
    --dl-accent: #0981FB; /* azul de marca Digital Latino — no está en paleta global */
}
.dl-header-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
}
.dl-country-info {
    display: flex;
    align-items: center;
    gap: 10px;
}
.dl-country-flag {
    width: 40px;
    height: auto;
    border-radius: 3px;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.3);
}
.dl-country-name {
    font-size: 16px;
    font-weight: var(--ml-font-weight-semibold);
    color: var(--dl-accent);
    text-transform: uppercase;
    letter-spacing: 1px;
}
.dl-cierre-info {
    font-size: 18px;
    font-weight: 300;
    color: var(--dl-accent);
    letter-spacing: 0.5px;
}
.dl-videos-grid-sc {
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    gap: 16px;
    margin-top: 20px;
}
.dl-video-card-sc {
    background: transparent;
    border: 1.5px solid rgba(255, 197, 8, 0.55);
    border-radius: 14px;
    overflow: hidden;
    transition: transform 0.4s ease, box-shadow 0.4s ease, border-color 0.4s ease;
    cursor: pointer;
}
.dl-video-card-sc:hover {
    border-color: var(--ml-primary-start);
    transform: translateY(-8px);
    box-shadow: var(--ml-shadow-glow);
}
.dl-video-wrapper-sc {
    position: relative;
    aspect-ratio: 9/16;
    background: #000;
}
.dl-video-wrapper-sc video {
    width: 100%;
    height: 100%;
    object-fit: cover;
}
.dl-video-info-sc {
    padding: 12px;
}
.dl-video-title-sc {
    font-size: 13px;
    font-weight: var(--ml-font-weight-bold);
    color: var(--ml-light);
    margin: 0 0 4px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.dl-video-artists-sc {
    font-size: 11px;
    color: var(--ml-gray-dark);
    margin: 0;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
/* Dots del carrusel (sólo visibles en mobile) */
.dl-carousel-dots { display: none; }
.dl-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.3);
    cursor: pointer;
    transition: background 0.3s ease, transform 0.3s ease;
}
.dl-dot.is-active {
    background: var(--ml-primary);
    transform: scale(1.25);
}

.dl-error,
.dl-empty {
    text-align: center;
    color: var(--ml-gray);
    padding: 24px;
}
.dl-error {
    color: #ff6b6b;
}
@media (max-width: 1024px) {
    .dl-videos-grid-sc { grid-template-columns: repeat(3, 1fr); }
}
@media (max-width: 768px) {
    /* Carrusel horizontal con scroll-snap */
    .dl-videos-grid-sc {
        display: flex;
        grid-template-columns: none;
        gap: 14px;
        overflow-x: auto;
        scroll-snap-type: x mandatory;
        -webkit-overflow-scrolling: touch;
        scrollbar-width: none;
        padding: 4px 2px 6px;
        scroll-padding-left: 2px;
    }
    .dl-videos-grid-sc::-webkit-scrollbar { display: none; }
    .dl-video-card-sc {
        flex: 0 0 62%;
        max-width: 250px;
        scroll-snap-align: center;
    }
    .dl-carousel-dots {
        display: flex;
        justify-content: center;
        align-items: center;
        gap: 8px;
        margin-top: 18px;
    }
    .dl-header-row {
        flex-direction: column;
        gap: 10px;
        align-items: flex-start;
    }
}

/* 3. SOLUCIONES PARA */
.ml-soluciones-section {
    background: #0d0d1a;
    padding: 50px 24px;
}
.ml-soluciones-container {
    max-width: 1260px;
    margin: 0 auto;
}
.ml-soluciones-title {
    font-family: var(--wp--preset--font-family--funnel-display, "Funnel Display", sans-serif);
    font-size: 32px;
    font-weight: 800;
    color: #ffffff;
    margin: 0 0 30px 0;
    line-height: 1.2;
}
.ml-soluciones-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 16px;
}
.ml-solucion-card {
    position: relative;
    border-radius: 12px;
    overflow: hidden;
    text-decoration: none;
    display: block;
    aspect-ratio: 1;
    transition: transform 0.3s ease, box-shadow 0.3s ease, border-color 0.3s ease;
    border: 2px solid transparent;
    background: #1a1a2e;
}
.ml-solucion-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 12px 28px rgba(255, 197, 8, 0.25);
    border-color: #FFC508;
}
.ml-solucion-card:hover .ml-solucion-img {
    filter: none;
    transform: scale(1.05);
}
.ml-solucion-img {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    filter: grayscale(30%) brightness(0.7);
    transition: filter 0.3s ease, transform 0.3s ease;
}
.ml-solucion-overlay {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    padding: 20px 14px;
    background: linear-gradient(to top, rgba(0,0,0,0.9) 0%, transparent 100%);
    text-align: center;
}
.ml-solucion-name {
    font-size: 16px;
    font-weight: 700;
    color: #ffffff;
    margin: 0;
    text-transform: uppercase;
}
@media (max-width: 1024px) {
    .ml-soluciones-grid { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 768px) {
    .ml-soluciones-grid { grid-template-columns: repeat(2, 1fr); }
}

/* 4. PRODUCTOS — 3-col grid + featured card + CTA hover */
.ml-productos-section {
    background: #12121f;
    padding: 80px 24px;
}
.ml-productos-container {
    max-width: 1260px;
    margin: 0 auto;
}
.ml-productos-header {
    text-align: center;
    margin-bottom: 56px;
}
.ml-productos-title {
    font-size: 42px;
    font-weight: 800;
    color: #ffffff;
    margin: 0 0 14px 0;
    letter-spacing: -0.5px;
    line-height: 1.15;
}
.ml-productos-subtitle {
    font-size: 17px;
    color: rgba(255,255,255,0.65);
    margin: 0;
}
.ml-productos-grid {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 20px;
}
.ml-productos-grid > .ml-producto-card {
    flex: 0 0 calc((100% - 40px) / 3);
    max-width: calc((100% - 40px) / 3);
}
/* Card base */
.ml-producto-card {
    position: relative;
    background: rgba(255,255,255,0.03);
    border: 1px solid rgba(255,255,255,0.08);
    border-radius: 16px;
    padding: 32px 28px 28px;
    text-decoration: none !important;
    transition: transform 0.3s ease, background 0.3s ease, border-color 0.3s ease, box-shadow 0.3s ease;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    overflow: hidden;
}
.ml-producto-card,
.ml-producto-card * {
    text-decoration: none !important;
}
.ml-producto-card:hover {
    background: rgba(255, 197, 8, 0.05);
    border-color: rgba(255, 197, 8, 0.4);
    transform: translateY(-4px);
    box-shadow: 0 12px 32px rgba(0,0,0,0.3), 0 0 24px rgba(255,197,8,0.1);
}
/* Icon */
.ml-producto-icon {
    width: 56px;
    height: 56px;
    background: rgba(255, 197, 8, 0.12);
    border: 1px solid rgba(255, 197, 8, 0.2);
    border-radius: 14px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 0 20px;
    color: #FFC508;
    transition: all 0.3s ease;
}
.ml-producto-icon svg {
    width: 26px !important;
    height: 26px !important;
}
.ml-producto-card:hover .ml-producto-icon {
    background: #FFC508;
    color: #0a0a0a;
    transform: scale(1.05);
}
/* Title (was h4 with uppercase tiny) */
.ml-producto-name {
    font-size: 19px;
    font-weight: 700;
    color: #ffffff;
    margin: 0 0 8px 0;
    text-transform: none;
    letter-spacing: 0;
    line-height: 1.25;
}
/* Description */
.ml-producto-desc {
    font-size: 14px;
    color: rgba(255,255,255,0.6);
    margin: 0 0 20px;
    line-height: 1.55;
    flex: 1;
}
/* CTA inline (Ver más →) */
.ml-producto-cta {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    color: #FFC508;
    font-size: 13px;
    font-weight: 600;
    letter-spacing: 0.3px;
    transition: gap 0.3s ease;
    margin-top: auto;
}
.ml-producto-card:hover .ml-producto-cta {
    gap: 10px;
}
.ml-producto-cta svg {
    width: 14px;
    height: 14px;
    transition: transform 0.3s ease;
}
.ml-producto-card:hover .ml-producto-cta svg {
    transform: translateX(2px);
}

/* Featured card (first card / .is-featured) */
.ml-producto-card.is-featured {
    background:
        linear-gradient(135deg, rgba(255,197,8,0.10) 0%, rgba(255,138,0,0.06) 100%),
        rgba(255,255,255,0.03);
    border: 1px solid rgba(255, 197, 8, 0.35);
}
.ml-producto-card.is-featured::before {
    content: 'Producto estrella';
    position: absolute;
    top: 16px;
    right: 16px;
    font-size: 10px;
    font-weight: 700;
    color: #FFC508;
    letter-spacing: 1.5px;
    text-transform: uppercase;
    padding: 5px 10px;
    background: rgba(255, 197, 8, 0.12);
    border: 1px solid rgba(255, 197, 8, 0.3);
    border-radius: 60px;
}
.ml-producto-card.is-featured .ml-producto-icon {
    background: linear-gradient(135deg, #FFC508 0%, #FF8A00 100%);
    color: #000;
    border-color: transparent;
    box-shadow: 0 6px 20px rgba(255, 197, 8, 0.25);
}
.ml-producto-card.is-featured:hover .ml-producto-icon {
    transform: scale(1.05) rotate(-3deg);
}

/* Responsive */
@media (max-width: 1024px) {
    .ml-productos-grid > .ml-producto-card {
        flex-basis: calc((100% - 20px) / 2);
        max-width: calc((100% - 20px) / 2);
    }
    .ml-productos-title { font-size: 36px; }
}
@media (max-width: 768px) {
    .ml-productos-section { padding: 60px 20px; }
    .ml-productos-title { font-size: 28px; }
    .ml-productos-subtitle { font-size: 15px; }
    .ml-soluciones-title { font-size: 24px; }
    .ml-cta-title { font-size: 24px; }
    .ml-top5-title { font-size: 24px; }
    .ml-producto-card { padding: 28px 22px 24px; }
    .ml-producto-name { font-size: 17px; }
}
@media (max-width: 480px) {
    .ml-productos-grid { gap: 14px; }
    .ml-productos-grid > .ml-producto-card { flex-basis: 100%; max-width: 100%; }
    .ml-soluciones-grid { grid-template-columns: 1fr 1fr; gap: 10px; }
    .ml-top5-section { padding: 32px 16px; }
    .ml-soluciones-section { padding: 32px 16px; }
    .ml-productos-section { padding: 40px 16px; }
    .ml-cta-section { padding: 40px 16px; }
    .ml-producto-card.is-featured::before {
        font-size: 9px;
        padding: 4px 8px;
    }
}

/* 5. LOGOS */
.ml-logos-section {
    background: rgba(255,255,255,0.02);
    border-top: 1px solid rgba(255,255,255,0.05);
    border-bottom: 1px solid rgba(255,255,255,0.05);
    padding: 30px 24px;
    text-align: center;
}
.ml-logos-title {
    font-size: 0.8rem;
    color: #666;
    text-transform: uppercase;
    letter-spacing: 3px;
    margin-bottom: 24px;
}
.ml-logos-grid {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 40px;
    flex-wrap: wrap;
    max-width: 1000px;
    margin: 0 auto;
}
.ml-logo-item {
    font-size: 1rem;
    font-weight: 700;
    color: #555;
    letter-spacing: 1px;
    transition: color 0.3s ease;
}
.ml-logo-item:hover {
    color: #FFC508;
}

/* 6. CTA FINAL */
.ml-cta-section {
    background: #0d0d1a;
    padding: 60px 24px;
    text-align: center;
}
.ml-cta-container {
    max-width: 700px;
    margin: 0 auto;
}
.ml-cta-title {
    font-size: 32px;
    font-weight: 800;
    color: #ffffff;
    margin: 0 0 16px 0;
    line-height: 1.2;
}
.ml-cta-text {
    font-size: 15px;
    color: rgba(255,255,255,0.6);
    margin: 0 0 24px 0;
}
.ml-cta-btn {
    display: inline-block;
    background: #FFC508;
    color: #000;
    padding: 14px 36px;
    border-radius: 60px;
    text-decoration: none;
    font-weight: 700;
    font-size: 14px;
    transition: all 0.3s ease;
}
.ml-cta-btn:hover {
    background: #fff;
    transform: translateY(-2px);
}
