@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700;800&display=swap');

*, *::before, *::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html, body {
    height: 100%;
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    background: #ffffff;
    overflow-x: hidden;
}

::selection {
    background-color: var(--aqp-primary-color);
    color: #fff;
}

::-moz-selection {
    background-color: var(--aqp-primary-color);
    color: #fff;
}

/* Global scrollbars */
::-webkit-scrollbar {
    width: 8px;
    height: 8px;
}

::-webkit-scrollbar-track {
    background: var(--aqp-secondary-color);
}

::-webkit-scrollbar-thumb {
    background: var(--aqp-primary-color);
    border-radius: 10px;
}

::-webkit-scrollbar-thumb:hover {
    opacity: 0.9;
}

* {
    scrollbar-width: thin;
    scrollbar-color: var(--aqp-primary-color) var(--aqp-secondary-color);
}

/* --- Hide WP admin bar --- */
#wpadminbar {
    display: none !important;
}

html {
    margin-top: 0 !important;
}

/* ═══════════════════════════════════════
   HEADER — floating, fixed at top
═══════════════════════════════════════ */
.aqp-header {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    padding: 12px 16px;
    background: linear-gradient(180deg, rgba(244, 244, 244, 0.8) 0%, rgba(244, 244, 244, 0) 100%);
    pointer-events: none; /* Allow clicks to pass through empty areas */
}

.aqp-header-inner {
    width: 100%;
    max-width: 1845px;
    margin: 0 auto;
    background: #fff;
    border-radius: 16px;
    padding: 10px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
    pointer-events: auto;
    border: 1px solid rgba(255, 255, 255, 0.8);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
}

.aqp-header-logo-wrap {
    display: flex;
    align-items: center;
}

.aqp-header-logo {
    height: 38px;
    width: auto;
    display: block;
    transition: transform 0.2s ease;
}

.aqp-header-logo:hover {
    transform: scale(1.02);
}

/* Timer Mount Point */
#aqp-header-timer-portal {
    display: flex;
    align-items: center;
}

/* ═══════════════════════════════════════
   MAIN CONTENT — sits above footer
═══════════════════════════════════════ */
.aqp-page-wrap {
    padding-top: 100px; /* Safe padding for floating header */
    padding-bottom: 80px;
    min-height: 100vh;
    position: relative;
    z-index: 10;
    background: #ffffff;
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.15);
    /* The revealing effect for the fixed footer at bottom of page with extra 20px gap */
    margin-bottom: calc(var(--aqp-footer-height, 100px) + 20px); 
}

/* Specific fix for React app container to ensure it doesn't overlap header */
.aquapass-app-container {
    background: transparent !important;
}

/* ═══════════════════════════════════════
   FOOTER — fixed at bottom, hidden under page
═══════════════════════════════════════ */
.aqp-footer {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    z-index: 5; /* BELOW .aqp-page-wrap */
    padding: 0 16px 12px;
}

.aqp-footer-inner {
    width: 100%;
    max-width: 1845px;
    margin: 0 auto;
    background: var(--aqp-primary-color);
    padding: 16px 28px;
    border-radius: 24px;
    display: flex;
    align-items: center;
    gap: 24px;
    color: #fff;
    box-shadow: 0 -4px 30px rgba(var(--aqp-primary-color-rgb), 0.15);
}

/* Round icon */
.aqp-footer-icon {
    width: 44px;
    height: 44px;
    border-radius: 50%;
    flex-shrink: 0;
    object-fit: cover;
    border: 2px solid rgba(255, 255, 255, 0.2);
}

/* Location text */
.aqp-footer-location {
    font-size: 13px;
    font-weight: 500;
    color: rgba(255, 255, 255, 0.95);
    flex-shrink: 1;
    max-width: 400px;
    line-height: 1.4;
}

/* Nav links */
.aqp-footer-links {
    display: flex;
    align-items: center;
    gap: 0 20px;
    margin-left: auto;
}

.aqp-footer-links a {
    font-size: 13px;
    font-weight: 600;
    color: rgba(255, 255, 255, 0.9);
    text-decoration: none;
    white-space: nowrap;
    transition: all 0.2s ease;
    border-bottom: 1px solid transparent;
}

.aqp-footer-links a:hover {
    color: #fff;
    border-bottom: 1px solid rgba(255, 255, 255, 0.5);
}

/* Payment icons */
.aqp-footer-payments {
    display: flex;
    align-items: center;
    gap: 0;
    flex-shrink: 0;
}

.aqp-payment-badge {
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.15);
    border-radius: 8px;
    padding: 6px 10px;
    font-size: 11px;
    font-weight: 800;
    color: #fff;
    letter-spacing: 0.04em;
    white-space: nowrap;
    text-transform: uppercase;
}

.aqp-payment-badge.mastercard {
    background: linear-gradient(135deg, rgba(235, 90, 0, 0.4), rgba(235, 90, 0, 0.2));
    border-color: rgba(235, 90, 0, 0.3);
}

.aqp-payment-badge.plata {
    background: rgba(255, 255, 255, 0.15);
}

.aqp-footer-badge {
    height: 32px;
    width: auto;
    object-fit: contain;
    padding: 2px 8px;
    transition: all 0.2s ease;
}

/* Responsive */
@media (max-width: 1024px) {
    .aqp-footer-links {
        gap: 0 16px;
    }
}

.aqp-footer-badge {
    height: 38px;
    width: auto;
    max-width: 100%;
    object-fit: contain;
}

@media (max-width: 1200px) {
    .aqp-footer-inner {
        justify-content: center;
        gap: 20px;
        padding: 24px;
    }
    .aqp-footer-links {
        margin-left: 0;
        width: 100%;
        flex-wrap: wrap;
    }
    .aqp-footer-location {
        width: 100%;
        max-width: 100%;
    }
}

@media (max-width: 768px) {
    .aqp-header-inner {
        padding: 8px;
    }
    .aqp-header-logo {
        height: 28px;
    }
    .aqp-footer-inner {
        flex-direction: column;
        text-align: center;
        gap: 16px;
        padding: 24px;
        border-radius: 0;
    }
    .aqp-footer {
        padding: 0;
        z-index: 5;
    }
    .aqp-footer-links {
        margin-left: 0;
        justify-content: center;
        width: 100%;
    }
    .aqp-page-wrap {
        padding-top: 80px;
        margin-bottom: var(--aqp-footer-height, 220px); /* Mobile footer is taller, default higher fallback */
    }
}

/* ═══════════════════════════════════════
   STEPPER DESIGN
═══════════════════════════════════════ */
.aqp-stepper-wrap {
    background: #fff;
    border-bottom: 1px solid rgba(0, 0, 0, 0.05);
    padding: 20px 0;
}

.aqp-stepper-container {
    padding: 0 16px;
}

.aqp-stepper-inner {
    max-width: 1845px;
    margin: 0 auto;
}

.aqp-stepper-steps {
    display: flex;
    justify-content: space-between;
    align-items: center;
    max-width: 900px;
    margin: 0 auto;
    position: relative;
}

.aqp-step-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    position: relative;
    z-index: 10;
    flex: 1;
}

.aqp-step-circle-wrap {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    margin-bottom: 10px;
}

.aqp-step-circle {
    width: 38px;
    height: 38px;
    border-radius: 50%;
    background: #f1f5f9;
    color: #94a3b8;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 800;
    font-size: 15px;
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    border: 3px solid #fff;
    box-shadow: 0 0 0 1px #e2e8f0;
    z-index: 2;
}

.aqp-step-connector {
    height: 4px;
    background: #f1f5f9;
    position: absolute;
    top: 17px;
    left: calc(50% + 20px);
    right: calc(-50% + 20px);
    z-index: 1;
    transition: background 0.4s ease;
    border-radius: 2px;
}

.aqp-step-label {
    font-size: 13px;
    font-weight: 700;
    color: #64748b;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    transition: all 0.3s ease;
}

/* --- States --- */

/* Active */
.aqp-step-item.active .aqp-step-circle {
    background: var(--aqp-primary-color);
    color: #fff;
    transform: scale(1.15);
    box-shadow: 0 4px 12px rgba(var(--aqp-primary-color-rgb), 0.35);
    border-color: #fff;
}

.aqp-step-item.active .aqp-step-label {
    color: #1e293b;
    transform: translateY(2px);
}

/* Past */
.aqp-step-item.past .aqp-step-circle {
    background: #fff;
    color: var(--aqp-primary-color);
    border-color: var(--aqp-primary-color);
    box-shadow: 0 0 0 1px var(--aqp-primary-color);
}

.aqp-step-item.past .aqp-step-connector {
    background: var(--aqp-primary-color);
}

.aqp-step-item.past .aqp-step-label {
    color: #94a3b8;
}

/* Responsive Stepper */
@media (max-width: 640px) {
    .aqp-step-label {
        font-size: 10px;
    }
    .aqp-step-circle {
        width: 32px;
        height: 32px;
        font-size: 13px;
    }
    .aqp-step-connector {
        top: 14px;
    }
}

@media (max-width: 640px) {
    .aqp-footer-links {
        flex-direction: column;
        gap: 8px;
    }
}

/* ═══════════════════════════════════════
   BUTTONS — Water fill effect
═══════════════════════════════════════ */
.btn-water-fill {
    position: relative;
    overflow: hidden;
    z-index: 1;
    isolation: isolate;
}

.btn-water-fill::before,
.btn-water-fill::after {
    content: '';
    position: absolute;
    left: 0;
    width: 200%; /* Double width for seamless horizontal scroll */
    height: 150%; /* Taller than button to allow for wave amplitude and full coverage */
    background: var(--aqp-secondary-color);
    bottom: -150%; /* Start fully below the button */
    z-index: -1;
    transition: bottom 0.9s cubic-bezier(0.4, 0, 0.2, 1);
    
    /* SVG Wave Mask that fills the BOTTOM part */
    -webkit-mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 800 120' preserveAspectRatio='none'%3E%3Cpath d='M0,40 C150,0 250,80 400,40 C550,0 650,80 800,40 L800,120 L0,120 Z' fill='black'/%3E%3C/svg%3E");
    mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 800 120' preserveAspectRatio='none'%3E%3Cpath d='M0,40 C150,0 250,80 400,40 C550,0 650,80 800,40 L800,120 L0,120 Z' fill='black'/%3E%3C/svg%3E");
    -webkit-mask-size: 50% 100%;
    mask-size: 50% 100%;
    -webkit-mask-repeat: repeat-x;
    mask-repeat: repeat-x;
    
    animation: wave-horizontal 4s infinite linear;
    pointer-events: none;
}

.btn-water-fill::after {
    opacity: 0.4;
    transition-duration: 1.1s;
    animation-duration: 7s;
    animation-direction: reverse;
    bottom: -160%;
}

.btn-water-fill::before {
    content: '';
    position: absolute;
    left: 50%;
    bottom: -160%;
    background-color: var(--aqp-secondary-color);
    border-radius: 40%;
    z-index: -1;
    transform: translateX(-50%) translateY(0) rotate(0deg);
}

.btn-water-fill:hover::before { 
    bottom: -19%; /* Rise up so the wave peaks are near the top */
}

.btn-water-fill:hover::after {
    bottom: -20%;
}

@keyframes wave-horizontal {
    from { -webkit-mask-position: 0 0; mask-position: 0 0; }
    to { -webkit-mask-position: 50% 0; mask-position: 50% 0; }
}

/* React App Reset Overrides */
.aquapass-app-container {
    background: transparent !important;
}

/* Custom fix for footer at 1023px and below */
@media (max-width: 1023px) {
    .aqp-footer {
        position: relative !important;
        bottom: auto !important;
        left: auto !important;
        right: auto !important;
        z-index: 10 !important;
        margin-top: 24px !important; /* Small gap from footer */
    }
    
    .aqp-page-wrap {
        position: relative !important;
        z-index: 20 !important;
        margin-bottom: 0 !important;
        padding-bottom: 0 !important; /* Remove extra empty spaces */
    }
    
    /* Ensure fixed bottom blocks are on top of the footer */
    .fixed.bottom-0 {
        z-index: 9999 !important;
    }
}

