/* Video Popup Modal - 24-Hour Website Delivery */

/* DEFAULT DESKTOP STYLES - Used by desktop AND desktop mode on mobile */
.video-popup-btn {
    position: fixed !important;
    top: 20px !important;
    right: 20px !important;
    left: auto !important;
    transform: none !important;
    z-index: 9999;
    background: linear-gradient(135deg, #D4AF37, #F4D03F);
    color: #00205B;
    padding: 12px 24px !important;
    border-radius: 50px;
    font-weight: 700;
    font-size: 0.95rem !important;
    text-decoration: none;
    box-shadow: 0 4px 15px rgba(212, 175, 55, 0.4);
    transition: all 0.3s ease;
    cursor: pointer;
    border: none;
    display: flex;
    align-items: center;
    gap: 8px;
    width: auto !important;
    max-width: none !important;
}

.video-popup-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(212, 175, 55, 0.6);
}

.video-popup-btn:active {
    transform: translateY(0);
}

/* MOBILE VIEW ONLY - actual mobile browser (not desktop mode) */
@media screen and (max-width: 480px) {
    .video-popup-btn {
        top: 100px !important; /* Below header and navigation */
        left: 50% !important;
        right: auto !important;
        transform: translateX(-50%) !important;
        padding: 8px 16px !important;
        font-size: 0.85rem !important;
        width: calc(100% - 30px) !important;
        max-width: 300px !important;
        justify-content: center;
        z-index: 999 !important; /* Lower than navigation menu */
    }

    /* Push ticker down on MOBILE VIEW ONLY - subtract 20px */
    .appwt-reviews-banner-wrapper {
        margin-top: 120px !important; /* Reduced by 20px (was 140px, now 120px) */
    }
}

/* Video Modal Overlay */
.video-modal-overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.9);
    z-index: 99999;
    opacity: 0;
    transition: opacity 0.3s ease;
    overflow-y: auto;
    padding: 20px;
}

.video-modal-overlay.active {
    display: flex;
    opacity: 1;
    align-items: center;
    justify-content: center;
}

/* Modal Content */
.video-modal-content {
    position: relative;
    max-width: 500px;
    width: 100%;
    background: #1a1a1a;
    border-radius: 20px;
    padding: 20px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5);
    transform: scale(0.9);
    transition: transform 0.3s ease;
    overflow: visible;
    z-index: 1;
}

.video-modal-overlay.active .video-modal-content {
    transform: scale(1);
}

/* Close Button - DEFAULT DESKTOP */
.video-modal-close {
    position: absolute;
    top: 10px;
    right: 10px;
    width: 60px;
    height: 60px;
    background: rgba(255, 0, 0, 0.9);
    color: #FFFFFF;
    border: 3px solid #FFFFFF;
    border-radius: 50%;
    font-size: 36px;
    font-weight: 700;
    cursor: pointer;
    display: flex !important;
    align-items: center;
    justify-content: center;
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.8);
    transition: all 0.3s ease;
    z-index: 999999;
    line-height: 1;
    opacity: 1 !important;
    visibility: visible !important;
}

.video-modal-close:hover {
    background: #FF0000;
    color: #FFFFFF;
    transform: scale(1.1) rotate(90deg);
    box-shadow: 0 8px 30px rgba(255, 0, 0, 0.6);
}

/* Close Button - MOBILE VIEW ONLY */
@media screen and (max-width: 480px) {
    .video-modal-close {
        top: 60px;
        left: 50%;
        right: auto;
        transform: translateX(-50%);
        width: 50px;
        height: 50px;
        font-size: 30px;
    }

    .video-modal-close:hover {
        transform: translateX(-50%) scale(1.1) rotate(90deg);
    }
}

/* Video Container */
.video-modal-video {
    position: relative;
    width: 100%;
    aspect-ratio: 9/16;
    background: #000;
    border-radius: 12px;
    overflow: hidden;
    margin-bottom: 15px;
    z-index: 1;
}

.video-modal-video video {
    width: 100%;
    height: 100%;
    object-fit: contain;
}

/* Modal Title */
.video-modal-title {
    color: #F4D03F;
    font-size: 1.3rem;
    font-weight: 700;
    margin-bottom: 15px;
    text-align: center;
}

@media screen and (max-width: 480px) {
    .video-modal-title {
        font-size: 1.1rem;
    }
}

/* Modal Links */
.video-modal-links {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.video-modal-link {
    display: block;
    text-align: center;
    padding: 12px 20px;
    border-radius: 10px;
    text-decoration: none;
    font-weight: 600;
    font-size: 1rem;
    transition: all 0.3s ease;
}

.video-modal-link.primary {
    background: linear-gradient(135deg, #00205B, #8B7FB8);
    color: white;
}

.video-modal-link.primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 15px rgba(0, 32, 91, 0.4);
}

.video-modal-link.secondary {
    background: rgba(212, 175, 55, 0.1);
    color: #D4AF37;
    border: 2px solid #D4AF37;
}

.video-modal-link.secondary:hover {
    background: rgba(212, 175, 55, 0.2);
}

@media screen and (max-width: 480px) {
    .video-modal-overlay {
        padding: 10px;
    }

    .video-modal-content {
        max-width: 100%;
        padding: 15px;
    }
}

/* Prevent body scroll when modal is open */
body.video-modal-open {
    overflow: hidden;
}

/* DESKTOP ONLY - Add 20px to space ABOVE ticker */
@media screen and (min-width: 481px) {
    .appwt-reviews-banner-wrapper {
        margin-top: 50px !important; /* Add 20px (was 30px, now 50px) */
    }
}

/* Change hamburger button to ROW layout */
.mobile-menu-toggle {
    flex-direction: row !important;
    align-items: center !important;
    gap: 10px !important;
}

/* Hamburger icon wrapper - keeps 3 lines stacked vertically */
.hamburger-icon {
    display: flex;
    flex-direction: column;
    gap: 4px;
    position: relative;
    width: 24px;
    height: 18px;
}

/* Position hamburger lines for proper X animation */
.hamburger-icon span {
    position: absolute !important;
    width: 100% !important;
}

.hamburger-icon span:nth-child(1) {
    top: 0 !important;
}

.hamburger-icon span:nth-child(2) {
    top: 50% !important;
    transform: translateY(-50%) !important;
}

.hamburger-icon span:nth-child(3) {
    bottom: 0 !important;
}

/* MENU text to the RIGHT of hamburger using ::after */
.mobile-menu-toggle::after {
    content: "MENU";
    font-size: 0.85rem;
    font-weight: 700;
    color: #FFFFFF;
    letter-spacing: 0.5px;
    text-transform: uppercase;
    white-space: nowrap;
}

/* Fix X animation when menu is open - lines cross in center */
.mobile-menu-toggle.active .hamburger-icon span:nth-child(1) {
    top: 9px !important;
    bottom: auto !important;
    transform: rotate(45deg) !important;
}

.mobile-menu-toggle.active .hamburger-icon span:nth-child(2) {
    opacity: 0 !important;
}

.mobile-menu-toggle.active .hamburger-icon span:nth-child(3) {
    top: 9px !important;
    bottom: auto !important;
    transform: rotate(-45deg) !important;
}
