.ad-container {
    margin: 16px 0;
    text-align: center;
}

.ad-banner {
    display: block;
    width: 100%;
    border-radius: 12px;
    overflow: hidden;
    background: linear-gradient(135deg, #f3f4f6 0%, #e5e7eb 100%);
    position: relative;
    text-decoration: none;
    transition: transform 0.2s, box-shadow 0.2s;
}

.ad-banner:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 24px rgba(0,0,0,0.12);
}

.ad-banner img {
    display: block;
    width: 100%;
    height: auto;
    margin: 0 auto;
    object-fit: cover;
    object-position: center;
    border-radius: 12px;
}

@media (max-width: 768px) {
    .ad-banner img {
        width: 100%;
        height: auto;
    }
}

.ad-label {
    position: absolute;
    top: 8px;
    right: 8px;
    background: rgba(0, 0, 0, 0.6);
    color: white;
    font-size: 10px;
    padding: 2px 6px;
    border-radius: 3px;
    z-index: 10;
    pointer-events: none;
}

.ad-text {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
    min-height: 80px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    font-size: 16px;
    font-weight: 500;
    text-align: center;
    position: relative;
}

.ad-text .ad-label {
    top: 8px;
    right: 8px;
}

.ad-placeholder {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 80px;
    background: linear-gradient(135deg, #f3f4f6 0%, #e5e7eb 100%);
    border-radius: 12px;
    color: #9ca3af;
    font-size: 13px;
}

.ad-placeholder svg {
    width: 20px;
    height: 20px;
    margin-right: 8px;
    opacity: 0.5;
}

.ad-sidebar {
    background: #fff;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 2px 8px rgba(0,0,0,0.06);
}

.ad-sidebar .ad-banner {
    border-radius: 0;
}

.ad-sidebar .ad-banner img {
    width: 100%;
    height: auto;
}

.ad-loading {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 80px;
    background: #f9fafb;
    border-radius: 12px;
}

.ad-loading::after {
    content: "";
    width: 24px;
    height: 24px;
    border: 2px solid #e5e7eb;
    border-top-color: #3b82f6;
    border-radius: 50%;
    animation: ad-spin 0.8s linear infinite;
}

@keyframes ad-spin {
    to { transform: rotate(360deg); }
}

@media (max-width: 768px) {
    .ad-text {
        padding: 16px;
        font-size: 14px;
        min-height: 60px;
    }
    
    .ad-placeholder {
        min-height: 60px;
        font-size: 12px;
    }
}
