/* AdSense Compliance CSS for LearnSavvy
 * This file contains styles to ensure proper ad display and compliance with AdSense policies
 */

/* General ad container styling */
.ad-container {
    margin: 30px 0;
    padding: 15px;
    background-color: #f9f9f9;
    border-radius: 8px;
    text-align: center;
    clear: both;
    overflow: hidden;
    transition: all 0.3s ease;
    max-width: 100%;
}

/* Ad label styling for compliance */
.ad-label {
    font-size: 0.7rem;
    color: #999;
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-bottom: 10px;
    text-align: center;
    display: block;
}

/* Specific ad placement styles */
.header-ad {
    margin-top: 0;
    margin-bottom: 30px;
}

.sidebar-ad {
    margin: 20px 0;
}

.in-content-ad {
    margin: 30px 0;
    padding: 20px;
}

.footer-ad {
    margin-bottom: 0;
    margin-top: 30px;
}

/* Responsive ad containers */
.responsive-ad {
    display: block;
    width: 100%;
    height: auto;
    overflow: hidden;
}

/* Sticky sidebar ad for desktop */
.sticky-sidebar-ad {
    position: sticky;
    top: 20px;
    margin-top: 40px;
}

/* Mobile-specific ad styles */
@media (max-width: 768px) {
    .ad-container {
        padding: 10px;
        margin: 20px 0;
    }
    
    .sticky-sidebar-ad {
        position: static;
    }
    
    .mobile-ad {
        display: block;
    }
    
    .desktop-only-ad {
        display: none;
    }
}

@media (min-width: 769px) {
    .mobile-ad {
        display: none;
    }
    
    .desktop-only-ad {
        display: block;
    }
}

/* Sticky bottom ad for mobile */
.sticky-bottom-ad {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    background: white;
    box-shadow: 0 -2px 10px rgba(0,0,0,0.1);
    z-index: 1000;
    padding: 10px;
    margin: 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    border-top-left-radius: 8px;
    border-top-right-radius: 8px;
}

.sticky-ad-close {
    position: absolute;
    top: 5px;
    right: 10px;
    font-size: 20px;
    cursor: pointer;
    color: #999;
}

/* Native ad styling */
.native-ad {
    background: transparent;
    padding: 0;
    margin: 30px 0;
}

.native-ad .ad-label {
    margin-bottom: 5px;
}

/* In-feed ad styling */
.in-feed-ad {
    margin: 40px 0;
    padding: 0;
    background: transparent;
}

/* Ad testing variations */
.ad-test-a {
    border-left: 3px solid transparent;
}

.ad-test-b {
    border-left: 3px solid #4285f4;
    padding-left: 22px;
}

/* Ensure ads don't overflow their containers */
.adsbygoogle {
    max-width: 100%;
    overflow: hidden;
}

/* Cookie consent related styling */
.cookie-consent-ad-notice {
    font-size: 0.8rem;
    color: #666;
    margin-top: 5px;
}

/* Affiliate disclosure styling */
.affiliate-disclosure {
    font-size: 0.8rem;
    color: #666;
    padding: 10px;
    background-color: #f5f5f5;
    border-radius: 5px;
    margin: 20px 0;
}

/* High-contrast mode for accessibility */
@media (prefers-contrast: high) {
    .ad-container {
        border: 1px solid #000;
    }
    
    .ad-label {
        color: #000;
        font-weight: bold;
    }
}

/* Reduce motion for users who prefer reduced motion */
@media (prefers-reduced-motion: reduce) {
    .ad-container {
        transition: none;
    }
}

/* Print styles - hide ads when printing */
@media print {
    .ad-container {
        display: none !important;
    }
}
