/* --- OVERLAY --- */
.woo-popup-overlay {
    display: flex;
    position: fixed;
    inset: 0;
    z-index: 999999;
    background: rgba(0, 0, 0, 0.7);
    backdrop-filter: blur(4px);
    justify-content: center;
    align-items: center;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s ease, visibility 0.3s ease;
}
.woo-popup-overlay.woo-popup-visible {
    opacity: 1;
    visibility: visible;
}

/* --- POPUP CONTAINER --- */
.woo-popup-container {
    background: #fff;
    max-width: 800px;
    width: 90vw;
    border-radius: 8px;
    overflow: hidden;
    display: grid;
    grid-template-columns: 1fr 1fr;
    position: relative;
    transform: translateY(30px);
    transition: transform 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}
.woo-popup-overlay.woo-popup-visible .woo-popup-container {
    transform: translateY(0);
}

/* --- LEFT COLUMN (content) --- */
.woo-popup-content {
    padding: 48px 40px;
    display: flex;
    flex-direction: column;
    justify-content: center;
}
.woo-popup-content h2 {
    font-family: 'Georgia', serif;
    font-size: 2rem;
    margin: 0;
}
.woo-popup-content .subtitle {
    font-family: 'Georgia', serif;
    font-style: italic;
    font-size: 1.1rem;
    margin: 4px 0 8px;
}
.woo-popup-content .headline {
    font-size: 1.4rem;
    font-weight: 700;
    margin: 0 0 16px;
}
.woo-popup-content p {
    color: #666;
    line-height: 1.6;
    margin: 0 0 24px;
}

/* --- EMAIL INPUT --- */
.woo-popup-input {
    border: none;
    border-bottom: 2px solid #333;
    padding: 12px 0;
    font-size: 1rem;
    width: 100%;
    outline: none;
    background: transparent;
    margin-bottom: 20px;
    box-shadow: none;
}
.woo-popup-input:focus {
    box-shadow: none;
    border-color: #000;
}

/* --- CTA BUTTON --- */
.woo-popup-cta {
    background: #1a1a1a;
    color: #fff;
    border: none;
    padding: 16px 32px;
    font-size: 0.85rem;
    letter-spacing: 3px;
    text-transform: uppercase;
    cursor: pointer;
    width: 100%;
    transition: background 0.2s;
}
.woo-popup-cta:hover {
    background: #333;
}
.woo-popup-cta:disabled {
    opacity: 0.7;
    cursor: not-allowed;
}

/* --- RIGHT COLUMN (image) --- */
.woo-popup-image {
    background-size: cover;
    background-position: center;
    min-height: 400px;
}

/* --- CLOSE BUTTON --- */
.woo-popup-close {
    position: absolute;
    top: 16px;
    left: 16px;
    font-size: 24px;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: #fff;
    border: 2px solid #000;
    color: #000;
    z-index: 2;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

/* --- EDGE TAB BUTTON --- */
.woo-popup-tab {
    position: fixed;
    left: 0;
    bottom: 0;
    z-index: 999998;
    background: #F4845F;
    color: #fff;
    font-weight: 700;
    font-size: 1rem;
    padding: 14px 24px;
    border-radius: 0 8px 0 0;
    cursor: pointer;
    box-shadow: 2px -2px 8px rgba(0,0,0,0.15);
    transition: transform 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    transform: translateY(0);
}
.woo-popup-tab .tab-text-mobile {
    display: none;
}
.woo-popup-tab .tab-text-desktop {
    display: inline;
}
@media (hover: hover) {
    .woo-popup-tab:hover {
        transform: translateY(-4px);
    }
}
.woo-popup-tab.woo-popup-tab-hidden {
    transform: translateY(150%);
}
.woo-popup-tab .tab-close {
    position: absolute;
    top: -10px;
    right: -10px;
    width: 26px;
    height: 26px;
    background: #fff;
    border: 2px solid #F4845F;
    border-radius: 50%;
    font-size: 16px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #F4845F;
    font-weight: bold;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

/* --- MOBILE --- */
@media (max-width: 768px) {
    .woo-popup-container {
        grid-template-columns: 1fr;
        max-height: 90vh;
        overflow-y: auto;
    }
    .woo-popup-image {
        min-height: 200px;
        order: -1;
    }
    .woo-popup-content {
        padding: 32px 24px;
    }
    .woo-popup-tab {
        width: 170px;
        height: 170px;
        padding: 0;
        border-radius: 0;
        transform: translate(-50%, 50%) rotate(45deg);
        display: flex;
        justify-content: center;
        align-items: flex-start;
        box-shadow: 0 0 20px rgba(0,0,0,0.3);
    }
    .woo-popup-tab.woo-popup-tab-hidden {
        transform: translate(-50%, 150%) rotate(45deg);
    }
    .woo-popup-tab .tab-text-desktop {
        display: none;
    }
    .woo-popup-tab .tab-text-mobile {
        display: inline;
        margin-top: 25px;
        font-size: 1.1rem;
        letter-spacing: 1px;
    }
    .woo-popup-tab .tab-close {
        transform: rotate(-45deg);
        top: -12px;
        right: 32px;
        width: 28px;
        height: 28px;
        font-size: 16px;
        box-shadow: 0 2px 4px rgba(0,0,0,0.2);
    }
}

/* --- SUCCESS STATE --- */
.woo-popup-success {
    text-align: center;
    padding: 0;
}
.woo-popup-coupon-display {
    background: #f5f5f5;
    border: 2px dashed #333;
    padding: 16px;
    font-size: 1.5rem;
    font-weight: 700;
    letter-spacing: 2px;
    margin: 16px 0;
    user-select: all;
}

/* --- ANIMATION --- */

/* --- NO SCROLL WHEN POPUP OPEN --- */
body.woo-popup-no-scroll {
    overflow: hidden;
}
