/**
 * LIT Conversion Features CSS
 * - Weekend Countdown Timer
 * - Exit Intent Popup
 * - Social Share Buttons
 * - Testimonial Carousel
 * - Print Styles
 */

/* =====================================================
   WEEKEND COUNTDOWN TIMER
   ===================================================== */
.weekend-countdown {
    padding: 12px 20px;
    text-align: center;
    font-weight: 600;
    font-size: 0.9rem;
    transition: all 0.3s ease;
}

.countdown-normal {
    background: var(--gray-100);
    color: var(--gray-700);
}

.countdown-soon {
    background: var(--primary-light);
    color: var(--primary-dark);
}

.countdown-active {
    background: linear-gradient(135deg, var(--primary), #f59e0b);
    color: white;
    animation: pulse-glow 2s ease-in-out infinite;
}

.countdown-urgent {
    background: linear-gradient(135deg, #ef4444, #f97316);
    color: white;
    animation: pulse-glow 1s ease-in-out infinite;
}

@keyframes pulse-glow {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.9; }
}

.countdown-message {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}

/* =====================================================
   EXIT INTENT POPUP
   ===================================================== */
.exit-popup {
    position: fixed;
    inset: 0;
    z-index: 10000;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(0, 0, 0, 0.7);
    backdrop-filter: blur(4px);
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
    padding: 16px;
}

.exit-popup.active {
    opacity: 1;
    visibility: visible;
}

.popup-content {
    background: white;
    border-radius: 24px;
    max-width: 480px;
    width: 100%;
    position: relative;
    overflow: hidden;
    animation: popup-slide-up 0.4s ease-out;
    box-shadow: 0 25px 50px rgba(0, 0, 0, 0.25);
}

@keyframes popup-slide-up {
    from {
        transform: translateY(20px);
        opacity: 0;
    }
    to {
        transform: translateY(0);
        opacity: 1;
    }
}

.popup-close {
    position: absolute;
    top: 16px;
    right: 16px;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: var(--gray-100);
    border: none;
    cursor: pointer;
    font-size: 1.25rem;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--gray-600);
    transition: all 0.2s;
    z-index: 10;
}

.popup-close:hover {
    background: var(--gray-200);
    color: var(--gray-900);
}

.popup-header {
    background: linear-gradient(135deg, var(--primary), #f59e0b);
    padding: 32px 24px;
    text-align: center;
    color: white;
}

.popup-header .popup-emoji {
    font-size: 3rem;
    margin-bottom: 12px;
}

.popup-header h3 {
    font-size: 1.5rem;
    font-weight: 800;
    margin-bottom: 8px;
}

.popup-header p {
    opacity: 0.95;
    font-size: 1rem;
}

.popup-body {
    padding: 24px;
}

.popup-benefits {
    margin-bottom: 24px;
}

.popup-benefits li {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 8px 0;
    font-size: 0.95rem;
    color: var(--gray-700);
}

.popup-benefits li::before {
    content: '✓';
    color: var(--success);
    font-weight: 700;
}

.popup-form {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.popup-form input[type="email"] {
    padding: 14px 18px;
    border: 2px solid var(--gray-200);
    border-radius: 50px;
    font-size: 16px;
    transition: border-color 0.2s;
}

.popup-form input[type="email"]:focus {
    outline: none;
    border-color: var(--primary);
}

.popup-form .btn {
    padding: 14px 24px;
    background: var(--primary);
    color: white;
    border: none;
    border-radius: 50px;
    font-weight: 600;
    font-size: 1rem;
    cursor: pointer;
    transition: all 0.2s;
}

.popup-form .btn:hover {
    background: var(--primary-dark);
    transform: translateY(-2px);
}

.popup-footer {
    text-align: center;
    padding-top: 16px;
    font-size: 0.85rem;
    color: var(--gray-500);
}

.popup-footer a {
    color: var(--gray-500);
    text-decoration: underline;
}

/* =====================================================
   SOCIAL SHARE BUTTONS
   ===================================================== */
.share-buttons {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
}

.share-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    padding: 8px 14px;
    border-radius: 50px;
    font-size: 0.8rem;
    font-weight: 600;
    cursor: pointer;
    border: none;
    transition: all 0.2s;
    text-decoration: none;
}

.share-btn:hover {
    transform: translateY(-2px);
}

.share-btn-facebook {
    background: #1877f2;
    color: white;
}

.share-btn-facebook:hover {
    background: #0d65d9;
}

.share-btn-twitter {
    background: #1da1f2;
    color: white;
}

.share-btn-twitter:hover {
    background: #0c8de4;
}

.share-btn-whatsapp {
    background: #25d366;
    color: white;
}

.share-btn-whatsapp:hover {
    background: #1da854;
}

.share-btn-copy {
    background: var(--gray-200);
    color: var(--gray-700);
}

.share-btn-copy:hover {
    background: var(--gray-300);
}

/* Compact share icons (for event cards) */
.share-icons {
    display: flex;
    gap: 4px;
}

.share-icon {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--gray-100);
    color: var(--gray-600);
    cursor: pointer;
    border: none;
    transition: all 0.2s;
    font-size: 0.9rem;
}

.share-icon:hover {
    background: var(--primary);
    color: white;
    transform: scale(1.1);
}

/* =====================================================
   TESTIMONIAL CAROUSEL
   ===================================================== */
.testimonial-carousel {
    position: relative;
    max-width: 800px;
    margin: 0 auto;
    overflow: hidden;
}

.carousel-track {
    display: flex;
    transition: transform 0.5s ease;
}

.testimonial-slide {
    flex: 0 0 100%;
    padding: 0 16px;
}

.testimonial-card-large {
    background: var(--gray-50);
    border-radius: 24px;
    padding: 40px;
    text-align: center;
}

.testimonial-stars {
    color: #fbbf24;
    font-size: 1.25rem;
    margin-bottom: 20px;
}

.testimonial-text-large {
    font-size: 1.25rem;
    line-height: 1.7;
    color: var(--gray-700);
    font-style: italic;
    margin-bottom: 24px;
}

.testimonial-author-large {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 16px;
}

.testimonial-avatar-large {
    width: 56px;
    height: 56px;
    border-radius: 50%;
    background: var(--primary);
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 1.25rem;
}

.testimonial-author-info h4 {
    font-weight: 700;
    color: var(--gray-900);
}

.testimonial-author-info p {
    font-size: 0.9rem;
    color: var(--gray-500);
}

/* Carousel navigation */
.carousel-nav {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 16px;
    margin-top: 24px;
}

.carousel-prev,
.carousel-next {
    width: 44px;
    height: 44px;
    border-radius: 50%;
    background: var(--gray-100);
    border: none;
    cursor: pointer;
    font-size: 1.25rem;
    color: var(--gray-600);
    transition: all 0.2s;
}

.carousel-prev:hover,
.carousel-next:hover {
    background: var(--primary);
    color: white;
}

.carousel-dots {
    display: flex;
    gap: 8px;
}

.carousel-dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: var(--gray-300);
    border: none;
    cursor: pointer;
    transition: all 0.2s;
    padding: 0;
}

.carousel-dot.active,
.carousel-dot:hover {
    background: var(--primary);
    transform: scale(1.2);
}

/* =====================================================
   SAVE FOR LATER BUTTON
   ===================================================== */
.save-btn {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 8px 14px;
    border-radius: 50px;
    font-size: 0.85rem;
    font-weight: 500;
    cursor: pointer;
    border: 1px solid var(--gray-200);
    background: white;
    color: var(--gray-600);
    transition: all 0.2s;
}

.save-btn:hover {
    border-color: var(--primary);
    color: var(--primary);
}

.save-btn.saved {
    background: var(--primary-light);
    border-color: var(--primary);
    color: var(--primary);
}

/* =====================================================
   HOW IT WORKS SECTION
   ===================================================== */
.how-it-works {
    padding: 60px 0;
    background: var(--gray-50);
}

.steps-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 32px;
    max-width: 900px;
    margin: 0 auto;
}

.step-card {
    text-align: center;
    position: relative;
}

.step-number {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    background: var(--primary);
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 800;
    font-size: 1.25rem;
    margin: 0 auto 16px;
}

.step-icon {
    font-size: 2.5rem;
    margin-bottom: 12px;
}

.step-title {
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--gray-900);
    margin-bottom: 8px;
}

.step-description {
    font-size: 0.95rem;
    color: var(--gray-600);
    line-height: 1.6;
}

/* Connector lines (desktop) */
@media (min-width: 768px) {
    .step-card:not(:last-child)::after {
        content: '';
        position: absolute;
        top: 24px;
        right: -16px;
        width: 32px;
        height: 2px;
        background: var(--gray-300);
    }
}

/* =====================================================
   PRINT STYLES
   ===================================================== */
@media print {
    /* Hide non-essential elements */
    .header,
    .footer,
    .newsletter-section,
    .insider-section,
    .exit-popup,
    .back-to-top,
    .sticky-cta,
    .mobile-menu-btn,
    .mobile-nav,
    .share-buttons,
    .save-btn,
    .btn,
    .unlock-overlay,
    .locked-section,
    nav,
    button {
        display: none !important;
    }

    /* Reset backgrounds for print */
    body {
        background: white;
        color: black;
        font-size: 12pt;
    }

    .hero,
    .section {
        background: white !important;
        color: black !important;
        padding: 20pt 0;
    }

    /* Make event cards print-friendly */
    .event-card,
    .news-card {
        break-inside: avoid;
        page-break-inside: avoid;
        border: 1px solid #ccc;
        box-shadow: none;
        margin-bottom: 16pt;
    }

    .event-image,
    .news-image {
        height: auto;
        max-height: 150pt;
    }

    /* Show URLs for links */
    a[href^="http"]::after {
        content: " (" attr(href) ")";
        font-size: 9pt;
        color: #666;
    }

    /* Print header */
    .print-header {
        display: block !important;
        text-align: center;
        padding: 20pt 0;
        border-bottom: 2pt solid var(--primary);
        margin-bottom: 20pt;
    }

    .print-header h1 {
        font-size: 18pt;
        margin-bottom: 4pt;
    }

    .print-header p {
        font-size: 10pt;
        color: #666;
    }

    /* Page setup */
    @page {
        margin: 0.75in;
    }

    /* Grid adjustments */
    .events-grid,
    .news-grid {
        display: block;
    }
}

/* Print-only elements (hidden on screen) */
.print-only {
    display: none;
}

@media print {
    .print-only {
        display: block !important;
    }
}

/* =====================================================
   ACCESSIBILITY IMPROVEMENTS
   ===================================================== */

/* Better focus indicators */
:focus-visible {
    outline: 3px solid var(--primary);
    outline-offset: 2px;
}

/* Reduce motion for users who prefer it */
@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }

    .carousel-track {
        transition: none;
    }
}

/* High contrast mode improvements */
@media (prefers-contrast: high) {
    .btn-primary {
        border: 2px solid black;
    }

    .event-card,
    .news-card {
        border: 2px solid black;
    }
}
