/* Ad Container */
.display-ad-container {
    /*display: flex;*/
    justify-content: center;
    width: 100%;
    padding: 20px 0;
    box-sizing: border-box;
    background-color: #f8f8f8; /* Optional background */
}

/* Ad Block Styling */
.display-ad-block {
    display: flex;
    flex-direction: row;
    flex-wrap: wrap;
    background-color: white;
    border: 1px solid #e0e0e0;
    border-radius: 5px;
    max-width: 728px;
    width: 100%;
    overflow: hidden;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

/* Image Styling */
.display-ad-image {
    width: 100%; /* Ensures the image takes up full width of container */
    height: 100%;
    max-height: 300px; /* Limits the height of the image */
    object-fit: cover; /* Crops the image to fit the container */
    object-position: center; /* Centers the image if it's cropped */
}

/* Ad Content Styling */
.display-ad-content {
    padding: 20px;
    box-sizing: border-box;
    text-align: center;
}

.display-ad-title {
    font-size: 1.25rem;
    font-weight: bold;
    margin-bottom: 10px;
    color: #333;
}

.display-ad-description {
    font-size: 0.9rem;
    color: #555;
    margin-bottom: 15px;
}

.display-ad-button {
    background-color: #007bff;
    color: white;
    text-decoration: none;
    padding: 10px 15px;
    border-radius: 3px;
    font-size: 0.9rem;
    text-align: center;
    transition: background-color 0.3s ease;
    display: inline-block;
}

.display-ad-button:hover {
    background-color: #0056b3;
}


/* Ad Space */
.ad-space {
    background-color: #f0f4fa;
    padding: 20px;
    text-align: center;
    border-radius: 10px;
    box-shadow: 0 4px 10px rgba(0, 64, 128, 0.1);
}

/* Sticky Bottom Ad (Mobile Only) */
.sticky-bottom-ad {
    background-color: #f0f4fa;
    padding: 15px;
    text-align: center;
    box-shadow: 0 -4px 10px rgba(0, 64, 128, 0.1);
    position: fixed;
    bottom: 0;
    width: 100%;
}

.sticky-bottom-ad p {
    margin: 0;
    font-size: 1.2rem;
    color: #666;
}

.mobile-only {
    display: none;
}

/* Vertical Ad Space (Desktop) */
.vertical-ad-space {
    width: 100%;
    background-color: #f0f4fa;
    padding: 20px;
    border-radius: 10px;
    text-align: center;
    box-shadow: 0 4px 10px rgba(0, 64, 128, 0.1);
}

/* Horizontal Ad Spaces */
.horizontal-ad-space {
    background-color: #f0f4fa;
    padding: 15px;
    text-align: center;
    border-radius: 10px;
    margin-top: 20px;  /* Space above the ad */
    margin-bottom: 20px; /* Space below the ad */
    box-shadow: 0 4px 10px rgba(0, 64, 128, 0.1);
}

/* Basic styling for the popup */
#popup {
    display: none;
    position: fixed;
    left: 50%;
    top: 50%;
    transform: translate(-50%, -50%);
    z-index: 1000;
}

#popup .display-ad-container {
    padding: 0;
    border-radius: 5px;
}

#popup .display-ad-block {
    flex-wrap: nowrap;
}

#ad-popup-overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5);
    z-index: 999;
}

/* Style for the close button */
#popUp-close {
    background-color: #f44336; /* Red background */
    border: none;
    color: white; /* White text */
    padding: 10px 20px;
    text-align: center;
    font-size: 16px;
    cursor: pointer;
    border-radius: 5px;
    margin-top: 20px;
    transition: background-color 0.3s ease;
}

/* Close button hover effect */
#popUp-close:hover {
    background-color: #d32f2f; /* Darker red on hover */
}

/* Responsive Design */
@media (max-width: 768px) {
    .display-ad-block {
        flex-direction: column;
    }

    .display-ad-image {
        width: 100%;
        height: 100%;
        max-height: 200px; /* Limit height on smaller screens */
    }

    .display-ad-content {
        padding: 15px;
    }

    .display-ad-title {
        font-size: 1.1rem;
    }

    .display-ad-description {
        font-size: 0.85rem;
    }

    .display-ad-button {
        font-size: 0.85rem;
        padding: 8px 12px;
    }
}
