/**
 * Home News Kerala - Website Entry Popup Advertisement Styles
 * Strict separation of concerns per AGENTS.md
 */

/* Modal Backdrop */
.site-popup-ad-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: rgba(15, 23, 42, 0.75);
    backdrop-filter: blur(5px);
    -webkit-backdrop-filter: blur(5px);
    z-index: 99999;
    display: none;
    align-items: center;
    justify-content: center;
    padding: 20px;
    opacity: 0;
    transition: opacity 0.35s cubic-bezier(0.4, 0, 0.2, 1);
}

.site-popup-ad-overlay.active {
    display: flex;
    opacity: 1;
}

/* Modal Dialog Box */
.site-popup-ad-dialog {
    position: relative;
    background: #ffffff;
    width: 100%;
    max-width: 580px;
    border-radius: 16px;
    overflow: hidden;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.35);
    transform: scale(0.92) translateY(20px);
    transition: transform 0.35s cubic-bezier(0.34, 1.56, 0.64, 1);
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.site-popup-ad-overlay.active .site-popup-ad-dialog {
    transform: scale(1) translateY(0);
}

/* Close Button */
.site-popup-close-btn {
    position: absolute;
    top: 14px;
    right: 14px;
    z-index: 10;
    background: rgba(15, 23, 42, 0.75);
    color: #ffffff;
    border: 2px solid rgba(255, 255, 255, 0.8);
    width: 36px;
    height: 36px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    font-size: 1rem;
    transition: all 0.2s ease;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.2);
}

.site-popup-close-btn:hover {
    background: #dc2626;
    border-color: #dc2626;
    transform: rotate(90deg);
}

/* Header Badge */
.site-popup-badge-wrap {
    position: absolute;
    top: 14px;
    left: 14px;
    z-index: 10;
}

.site-popup-badge {
    background: #dc2626;
    color: #ffffff;
    font-size: 0.75rem;
    font-weight: 800;
    padding: 4px 10px;
    border-radius: 6px;
    letter-spacing: 0.5px;
    text-transform: uppercase;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
}

/* Banner Image Wrap */
.site-popup-media-wrap {
    width: 100%;
    max-height: 290px;
    background: #0f172a;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    position: relative;
}

.site-popup-img {
    width: 100%;
    height: 100%;
    max-height: 290px;
    object-fit: cover;
    display: block;
    transition: transform 0.4s ease;
}

.site-popup-media-wrap:hover .site-popup-img {
    transform: scale(1.02);
}

/* Content Area */
.site-popup-content {
    padding: 20px 24px 22px;
    text-align: left;
    background: #ffffff;
}

.site-popup-title {
    font-size: 1.25rem;
    font-weight: 800;
    color: #0f172a;
    margin: 0 0 6px;
    line-height: 1.35;
}

.site-popup-subtitle {
    font-size: 0.95rem;
    color: #475569;
    margin: 0 0 16px;
    line-height: 1.5;
}

.site-popup-meta-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    flex-wrap: wrap;
    border-top: 1px solid #f1f5f9;
    padding-top: 14px;
}

.site-popup-offer {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 0.85rem;
    font-weight: 700;
    color: #15803d;
    background: #dcfce7;
    padding: 6px 12px;
    border-radius: 6px;
}

.site-popup-cta-btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: #dc2626;
    color: #ffffff;
    font-weight: 700;
    font-size: 0.95rem;
    padding: 10px 20px;
    border-radius: 8px;
    text-decoration: none;
    transition: background 0.2s ease, transform 0.15s ease;
}

.site-popup-cta-btn:hover {
    background: #b91c1c;
    color: #ffffff;
    transform: translateY(-1px);
}

/* Mobile Adjustments */
@media (max-width: 576px) {
    .site-popup-ad-dialog {
        max-width: 95%;
        border-radius: 12px;
    }
    .site-popup-media-wrap {
        max-height: 200px;
    }
    .site-popup-title {
        font-size: 1.1rem;
    }
    .site-popup-subtitle {
        font-size: 0.85rem;
    }
    .site-popup-meta-row {
        flex-direction: column;
        align-items: stretch;
    }
    .site-popup-cta-btn {
        justify-content: center;
    }
}
