/* static/ads.css */

.ads-container {
    max-width: 1000px; /* Wider than about/rules for larger banners */
    margin: 0 auto;
    padding: 1em;
    color: #f0f0f0;
}

.page-title {
    text-align: center;
    font-size: 1.8em;
    margin: 0.8em 0;
    color: #fff;
    text-shadow: 0 0 5px rgba(35, 130, 95, 0.7);
}

.ads-intro {
    background: #1f1f1f;
    padding: 1.2em;
    border-radius: 8px;
    margin-bottom: 1.2em;
    font-size: 0.95em;
    border-left: 4px solid #23825f;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.3);
}

.ads-intro p {
    margin: 0.5em 0;
    line-height: 1.5;
}

.ads-intro a {
    color: #50c878;
    text-decoration: none;
    transition: color 0.2s ease;
}

.ads-intro a:hover {
    color: #fff;
    text-decoration: underline;
}

.ads-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr); /* Two columns, equal width */
    gap: 1.5em; /* Space between ads */
    margin-top: 1em;
}

.ad-item {
    display: block;
    text-align: center;
    background: #1f1f1f;
    padding: 1em;
    border-radius: 8px;
    border-left: 4px solid #23825f;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.3);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.ad-item:hover {
    transform: scale(1.02); /* Slight zoom on hover */
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.4);
}

.ad-banner {
    width: 400px; /* Fixed width for uniformity */
    height: 125px; /* Fixed height for large rectangles */
    object-fit: cover; /* Crops image to fit without stretching */
    border-radius: 5px;
    display: block;
    margin: 0 auto;
}

.no-ads {
    grid-column: span 2; /* Spans both columns */
    text-align: center;
    font-size: 1em;
    padding: 1em;
    background: #1f1f1f;
    border-radius: 8px;
    border-left: 4px solid #23825f;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.3);
}

/* Responsive */
@media (max-width: 800px) {
    .ads-container {
        padding: 0.5em;
        max-width: 100%;
    }

    .ads-grid {
        grid-template-columns: 1fr; /* Single column on smaller screens */
        gap: 1em;
    }

    .page-title {
        font-size: 1.5em;
    }

    .ads-intro {
        font-size: 0.9em;
        padding: 1em;
    }

    .ad-banner {
        width: 100%; /* Full width on mobile */
        height: 150px; /* Slightly smaller height for mobile */
    }

    .no-ads {
        grid-column: span 1;
    }
}
