/* Miss República Dominicana Landing Page Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    background: url('https://d39et91hh3679e.cloudfront.net/images/fondoestrellas1.png') center center fixed;
    background-size: cover;
    background-repeat: no-repeat;
    background-color: #1e3c72; /* Fallback color */
    min-height: 100vh;
    color: #fff;
    font-weight: 400;
    line-height: 1.6;
}

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

/* Header */
.header {
    text-align: center;
    padding: 20px 0;
}

.logo {
    max-width: 300px;
    width: 100%;
    height: auto;
}

/* Desktop Layout */
.main-content {
    display: grid;
    grid-template-columns: 320px 1fr 320px;
    grid-template-rows: auto 1fr auto;
    gap: 20px;
    margin: 20px auto;
    min-height: 600px;
    max-width: 1500px; /* Más espacio para los anuncios */
}

/* Ad Containers */
.ad-container {
    display: flex;
    justify-content: center;
    align-items: center;
    background: transparent; /* Eliminar fondo que puede interferir */
    border-radius: 8px;
    padding: 15px; /* Más padding para los anuncios */
    overflow: visible; /* Asegurar que el contenido no se corte */
}

.ad-top {
    grid-column: 1 / -1;
    min-height: 110px; /* Más altura para banners 970x90 */
    width: 100%;
}

.ad-left {
    grid-column: 1;
    grid-row: 2;
    min-height: 280px; /* Más altura para banners 300x250 */
    min-width: 320px; /* Ancho mínimo garantizado */
}

.ad-right {
    grid-column: 3;
    grid-row: 2;
    min-height: 280px; /* Más altura para banners 300x250 */
    min-width: 320px; /* Ancho mínimo garantizado */
}

.ad-bottom {
    grid-column: 1 / -1;
    min-height: 110px; /* Más altura para banners 970x90 */
    width: 100%;
}

/* Video Player Container */
.video-container {
    grid-column: 2;
    grid-row: 2;
    position: relative;
    background-color: #000;
    border-radius: 8px;
    overflow: hidden;
    width: 100%;
    aspect-ratio: 16/9;
    max-width: 800px;
    margin: 0 auto;
}

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

/* Event Title */
.event-title {
    text-align: center;
    margin: 20px 0;
    font-family: 'Playfair Display', serif;
}

.event-title h1 {
    font-size: 2.5em;
    font-weight: 700;
    letter-spacing: 1px;
    margin-bottom: 10px;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.5);
    background: linear-gradient(45deg, #ffd700, #fff, #ffd700);
    background-size: 200% 200%;
    background-clip: text;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    animation: golden-shine 3s ease-in-out infinite;
}

.event-title p {
    font-family: 'Inter', sans-serif;
    font-size: 1.2em;
    font-weight: 500;
    color: #f0f0f0;
    text-shadow: 1px 1px 2px rgba(0, 0, 0, 0.7);
    margin-bottom: 15px;
}

.channel-logo {
    max-width: 200px;
    width: 100%;
    height: auto;
    margin: 10px auto;
    display: block;
}

/* Footer */
.footer {
    background-color: rgba(0, 0, 0, 0.8);
    text-align: center;
    padding: 20px;
    margin-top: 40px;
    backdrop-filter: blur(10px);
    border-top: 1px solid rgba(255, 215, 0, 0.3);
}

.footer p {
    color: #f0f0f0;
    font-family: 'Inter', sans-serif;
    font-size: 14px;
    font-weight: 400;
    letter-spacing: 0.5px;
}

/* Mobile and Tablet Styles */
@media (max-width: 1024px) {
    .container {
        padding: 10px;
    }
    
    .logo {
        max-width: 250px;
    }
    
    .main-content {
        display: block;
        margin: 10px 0;
    }
    
    .ad-container {
        margin: 10px 0;
    }
    
    .ad-top, .ad-bottom {
        min-height: 50px;
    }
    
    .ad-left, .ad-right {
        display: none; /* Hide side ads on mobile */
    }
    
    .video-container {
        height: auto;
        margin: 20px 0;
        aspect-ratio: 16/9;
        max-width: 100%;
        min-height: 200px;
    }
    
    .event-title h1 {
        font-size: 1.8em;
    }
    
    .event-title p {
        font-size: 1em;
        padding: 0 10px;
    }
    
    .footer {
        margin-top: 20px;
        padding: 15px 10px;
    }
}

/* Desktop specific styles */
@media (min-width: 1025px) {
    .desktop-ad {
        display: block !important;
        visibility: visible !important;
        opacity: 1 !important;
        position: relative !important;
        z-index: 1 !important;
    }
    
    .mobile-ad {
        display: none !important;
    }
    
    .video-container {
        aspect-ratio: 16/9;
        min-height: 400px;
    }
    
    /* Asegurar que los contenedores de anuncios desktop tengan el espacio adecuado */
    .ad-container.ad-left,
    .ad-container.ad-right {
        min-width: 320px;
        max-width: 350px;
    }
    
    .ad-container.ad-top,
    .ad-container.ad-bottom {
        min-height: 110px;
        justify-content: center;
    }
    
    /* Asegurar que los divs internos de anuncios no tengan restricciones */
    .desktop-ad > div,
    .desktop-ad div[id*="div-gpt-ad"] {
        width: auto !important;
        height: auto !important;
        max-width: none !important;
        max-height: none !important;
        position: relative !important;
        overflow: visible !important;
    }
}

/* iPad and Medium tablets in landscape */
@media (min-width: 768px) and (max-width: 1024px) {
    .container {
        padding: 15px;
    }
    
    .logo {
        max-width: 280px;
    }
    
    .main-content {
        display: block; /* Usar layout vertical como mobile */
        margin: 15px 0;
    }
    
    .ad-container {
        margin: 15px 0;
    }
    
    .ad-top, .ad-bottom {
        min-height: 60px; /* Ajustar para anuncios mobile */
    }
    
    .ad-left, .ad-right {
        display: none; /* Ocultar anuncios laterales en iPad */
    }
    
    .video-container {
        height: auto;
        margin: 20px 0;
        aspect-ratio: 16/9;
        max-width: 100%;
        min-height: 300px; /* Más altura para iPad */
    }
    
    .event-title h1 {
        font-size: 2em;
    }
    
    .event-title p {
        font-size: 1.1em;
    }
    
    .channel-logo {
        max-width: 180px;
    }
}

/* Mobile phones */
@media (max-width: 767px) {
    .header {
        padding: 10px 0;
    }
    
    .logo {
        max-width: 200px;
    }
    
    .video-container {
        min-height: 180px;
        margin: 15px 0;
    }
    
    .event-title h1 {
        font-size: 1.5em;
        letter-spacing: 0.5px;
    }
    
    .event-title p {
        font-size: 0.9em;
    }
    
    .channel-logo {
        max-width: 150px;
    }
    
    .container {
        padding: 10px;
    }
}

/* Very small mobile phones */
@media (max-width: 480px) {
    .logo {
        max-width: 180px;
    }
    
    .video-container {
        min-height: 160px;
    }
    
    .event-title h1 {
        font-size: 1.3em;
    }
    
    .event-title p {
        font-size: 0.9em;
    }
    
    .channel-logo {
        max-width: 120px;
    }
    
    .container {
        padding: 8px;
    }
}

/* Animations */
.fade-in {
    animation: fadeIn 1s ease-in;
}

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

@keyframes golden-shine {
    0% {
        background-position: 0% 50%;
    }
    50% {
        background-position: 100% 50%;
    }
    100% {
        background-position: 0% 50%;
    }
}