/* Custom styles for Lido Azzurro landing page */

/* Smooth scrolling */
html {
    scroll-behavior: smooth;
}

/* Custom animations */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes pulse {
    0%, 100% {
        transform: scale(1);
    }
    50% {
        transform: scale(1.05);
    }
}

/* Target card highlight animation */
.target-card.highlighted {
    animation: pulse 2s infinite;
    border: 2px solid #0077be;
    box-shadow: 0 0 20px rgba(0, 119, 190, 0.3);
}

/* FAQ accordion animations */
.faq-item .faq-answer {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease-out;
}

.faq-item .faq-answer.open {
    max-height: 200px;
    transition: max-height 0.3s ease-in;
}

.faq-item .faq-icon.rotate {
    transform: rotate(180deg);
}

/* Countdown timer styling */
#countdown {
    font-family: 'Courier New', monospace;
    letter-spacing: 2px;
}

.countdown-expired {
    color: #dc2626 !important;
}

/* Sticky CTA safe area for iOS */
#sticky-cta {
    padding-bottom: env(safe-area-inset-bottom, 1rem);
}

/* Modal overlay blur effect */
#calendar-modal {
    backdrop-filter: blur(5px);
}

/* Tally iframe responsive adjustments */
#tally-iframe {
    min-height: 600px;
    border-radius: 0.5rem;
}

/* Loading states */
.loading {
    opacity: 0.7;
    pointer-events: none;
}

/* Custom scrollbar for modal on webkit browsers */
#calendar-modal .overflow-auto::-webkit-scrollbar {
    width: 8px;
}

#calendar-modal .overflow-auto::-webkit-scrollbar-track {
    background: #f1f1f1;
    border-radius: 4px;
}

#calendar-modal .overflow-auto::-webkit-scrollbar-thumb {
    background: #0077be;
    border-radius: 4px;
}

#calendar-modal .overflow-auto::-webkit-scrollbar-thumb:hover {
    background: #004d7a;
}

/* CTA hover effects */
.cta-track {
    transition: all 0.3s ease;
}

.cta-track:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 119, 190, 0.3);
}

/* Hero section background pattern */
.bg-gradient-to-br {
    background-image: 
        radial-gradient(circle at 20% 80%, rgba(255, 255, 255, 0.1) 0%, transparent 50%),
        radial-gradient(circle at 80% 20%, rgba(255, 255, 255, 0.1) 0%, transparent 50%);
}

/* Form section styling */
#form-section .bg-gray-50 {
    border: 1px solid #e5e7eb;
}

/* Mobile logo responsive fixes */
@media (max-width: 768px) {
    .logo-mobile {
        height: 2.5rem; /* h-10 equivalent */
        width: auto;
        max-width: 120px;
        object-fit: contain;
        object-position: left center;
    }
}

@media (min-width: 769px) {
    .logo-desktop {
        height: 3rem; /* h-12 equivalent */
        width: auto;
        object-fit: contain;
    }
}

/* Header CTA Button - Mobile and Desktop */
.header-cta-btn {
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    line-height: 1.2 !important;
    white-space: nowrap !important;
}

@media (max-width: 768px) {
    .header-cta-btn {
        font-size: 0.875rem !important; /* text-sm */
        padding: 0.5rem 1rem !important; /* px-4 py-2 */
        max-width: 40% !important;
        min-height: 2.5rem !important;
    }
}

@media (min-width: 769px) {
    .header-cta-btn {
        font-size: 1rem !important; /* text-base */
        padding: 0.75rem 1.5rem !important; /* px-6 py-3 */
        min-height: 3rem !important;
    }
}

/* Cookie banner slide-up animation */
#cookie-banner {
    transform: translateY(100%);
    transition: transform 0.3s ease-out;
}

#cookie-banner.show {
    transform: translateY(0);
}

/* Testimonial cards hover effect */
.testimonial-card {
    transition: transform 0.2s ease;
}

.testimonial-card:hover {
    transform: translateY(-2px);
}

/* Mobile optimizations */
@media (max-width: 768px) {
    /* Increase touch targets on mobile */
    .cta-track, .faq-question, button {
        min-height: 44px;
        display: flex;
        align-items: center;
        justify-content: center;
    }
    
    /* Optimize text sizes for mobile reading */
    h1 {
        font-size: 2rem;
        line-height: 1.2;
    }
    
    h2 {
        font-size: 1.75rem;
        line-height: 1.3;
    }
    
    /* Improve spacing on mobile */
    .container {
        padding-left: 1rem;
        padding-right: 1rem;
    }
    
    /* Modal full screen on mobile */
    #calendar-modal .max-w-4xl {
        max-width: 95vw;
        margin: 1rem;
    }
    
    /* Sticky CTA bottom spacing */
    body {
        padding-bottom: 80px; /* Account for sticky CTA height */
    }
}

/* Print styles */
@media print {
    #sticky-cta,
    #calendar-modal,
    #cookie-banner {
        display: none !important;
    }
    
    /* Optimize for print */
    .bg-gradient-to-br {
        background: #87ceeb !important;
        color: #000 !important;
    }
    
    a {
        color: #000 !important;
        text-decoration: underline !important;
    }
}

/* High contrast mode support */
@media (prefers-contrast: high) {
    .bg-lido-blue {
        background-color: #000080 !important;
    }
    
    .text-lido-blue {
        color: #000080 !important;
    }
    
    .border-lido-blue {
        border-color: #000080 !important;
    }
}

/* Reduced motion support */
@media (prefers-reduced-motion: reduce) {
    * {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
    
    html {
        scroll-behavior: auto;
    }
}

/* Focus indicators for accessibility */
*:focus {
    outline: 2px solid #0077be;
    outline-offset: 2px;
}

/* Skip link styling */
.sr-only:not(:focus):not(:active) {
    clip: rect(0 0 0 0);
    clip-path: inset(50%);
    height: 1px;
    overflow: hidden;
    position: absolute;
    white-space: nowrap;
    width: 1px;
}
