/**
 * EUROPALIA - Estilos Customizados
 * Complementa Tailwind CSS
 */

/* ==================== */
/* BASE STYLES          */
/* ==================== */
/* Reset CSS (margin, padding, box-sizing) handled by Tailwind Preflight */
/* scroll-behavior: smooth defined in head.php */

body {
    font-family: 'Source Sans 3', system-ui, sans-serif;
    color: #2C3E50;
    line-height: 1.6;
    overflow-x: hidden;
}

h1, h2, h3, h4, h5, h6 {
    font-family: 'Playfair Display', Georgia, serif;
    font-weight: 600;
    line-height: 1.2;
}

/* ==================== */
/* CONTAINER SYSTEM     */
/* ==================== */

.container {
    width: 100%;
    margin-left: auto;
    margin-right: auto;
}

@media (max-width: 768px) {
    .container {
        padding-left: 1rem !important;
        padding-right: 1rem !important;
        max-width: 100% !important;
    }
}

@media (min-width: 769px) and (max-width: 1024px) {
    .container {
        padding-left: 2rem !important;
        padding-right: 2rem !important;
        max-width: 95% !important;
    }
}

@media (min-width: 1025px) {
    .container {
        max-width: 1200px !important;
        padding-left: 2rem !important;
        padding-right: 2rem !important;
    }
}

/* ==================== */
/* MOBILE TYPOGRAPHY    */
/* ==================== */

@media (max-width: 768px) {
    h1 {
        font-size: clamp(1.75rem, 6vw, 2.25rem) !important;
        line-height: 1.2 !important;
    }
    h2 {
        font-size: clamp(1.5rem, 5vw, 1.875rem) !important;
        line-height: 1.3 !important;
    }
    h3 {
        font-size: clamp(1.125rem, 4vw, 1.25rem) !important;
        line-height: 1.4 !important;
    }
    p {
        font-size: clamp(0.875rem, 3.5vw, 1rem) !important;
        line-height: 1.5 !important;
    }

    .py-16 {
        padding-top: 3rem !important;
        padding-bottom: 3rem !important;
    }
    .py-20 {
        padding-top: 4rem !important;
        padding-bottom: 4rem !important;
    }
    .mb-8 {
        margin-bottom: 1.5rem !important;
    }
    .mb-6 {
        margin-bottom: 1rem !important;
    }
}

@media (max-width: 640px) {
    input, textarea, select {
        font-size: 16px !important;
    }

    .icon-mobile {
        width: 2rem !important;
        height: 2rem !important;
    }
}

@media (hover: none) {
    .hover\:scale-105 {
        transform: none !important;
    }
}

/* ==================== */
/* FAQ STYLES           */
/* ==================== */

.faq-button {
    white-space: normal !important;
    word-wrap: break-word !important;
    text-align: left !important;
    overflow-wrap: break-word !important;
    padding-right: 2.5rem !important;
}

.faq-answer {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.4s ease, padding 0.4s ease;
}

.faq-answer.open {
    max-height: 500px;
}

/* ==================== */
/* CUSTOM COMPONENTS    */
/* ==================== */

.btn-primary {
    background: linear-gradient(135deg, #1E3A5F 0%, #152942 100%);
    color: white;
    font-weight: 600;
    padding: 0.875rem 2rem;
    border-radius: 0.5rem;
    transition: all 0.3s ease;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 44px;
    text-decoration: none;
    border: none;
    cursor: pointer;
}

.btn-primary:hover {
    background: linear-gradient(135deg, #152942 0%, #0f1d2d 100%);
    transform: translateY(-2px);
    box-shadow: 0 10px 30px rgba(30, 58, 95, 0.3);
}

.btn-outline {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0.875rem 2rem;
    background: transparent;
    border: 2px solid #1E3A5F;
    color: #1E3A5F;
    font-weight: 600;
    border-radius: 0.5rem;
    transition: all 0.3s ease;
}

.btn-outline:hover {
    background: #1E3A5F;
    color: white;
}

/* ==================== */
/* TRUST BADGES         */
/* ==================== */

.trust-badge {
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(212, 168, 83, 0.3);
    border-radius: 50px;
    padding: 0.5rem 1rem;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.875rem;
    color: #4A5568;
}

.trust-badge .stars {
    color: #D4A853;
}

/* ==================== */
/* ANIMATIONS           */
/* ==================== */

/* @keyframes fadeInUp and float - already defined in head.php */

@keyframes pulseGlow {
    0%, 100% {
        box-shadow: 0 0 10px rgba(212, 168, 83, 0.5);
    }
    50% {
        box-shadow: 0 0 25px rgba(212, 168, 83, 0.8);
    }
}

.animate-fade-in-up {
    animation: fadeInUp 0.8s ease-out forwards;
}

.animate-float {
    animation: float 6s ease-in-out infinite;
}

.animate-pulse-glow {
    animation: pulseGlow 2s ease-in-out infinite;
}

.delay-100 { animation-delay: 0.1s; }
.delay-200 { animation-delay: 0.2s; }
.delay-300 { animation-delay: 0.3s; }
.delay-400 { animation-delay: 0.4s; }

/* ==================== */
/* HERO PATTERN         */
/* ==================== */

.hero-pattern {
    background-color: #F8F9FA;
    background-image:
        radial-gradient(at 20% 20%, rgba(30, 58, 95, 0.03) 0%, transparent 50%),
        radial-gradient(at 80% 80%, rgba(212, 168, 83, 0.05) 0%, transparent 50%);
}

.gradient-text {
    background: linear-gradient(135deg, #1E3A5F 0%, #D4A853 100%);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

/* ==================== */
/* HEADER               */
/* ==================== */

.header-scrolled {
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.1);
}

/* ==================== */
/* SERVICE CARDS        */
/* ==================== */

.service-card {
    background: white;
    border-radius: 1rem;
    padding: 2rem;
    transition: all 0.4s ease;
    border: 1px solid transparent;
    position: relative;
    overflow: hidden;
}

.service-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 20px 40px rgba(30, 58, 95, 0.15);
    border-color: rgba(212, 168, 83, 0.3);
}

.service-icon {
    width: 4rem;
    height: 4rem;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 1rem;
    margin-bottom: 1.5rem;
    font-size: 2rem;
}

/* ==================== */
/* PORTFOLIO            */
/* ==================== */

.portfolio-item {
    position: relative;
    border-radius: 1rem;
    overflow: hidden;
    cursor: pointer;
}

.portfolio-item img {
    transition: transform 0.5s ease;
}

.portfolio-item:hover img {
    transform: scale(1.1);
}

.portfolio-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(to top, rgba(30, 58, 95, 0.95) 0%, rgba(30, 58, 95, 0.5) 50%, transparent 100%);
    opacity: 0;
    transition: opacity 0.4s ease;
}

.portfolio-item:hover .portfolio-overlay {
    opacity: 1;
}

/* X Cloak for Alpine */
[x-cloak] { display: none !important; }

/* ==================== */
/* BEFORE-AFTER SLIDER  */
/* ==================== */

.before-after-container {
    position: relative;
    overflow: hidden;
    border-radius: 1rem;
    cursor: col-resize;
    touch-action: pan-y;
}

.before-after-container img {
    display: block;
    width: 100%;
    height: auto;
    pointer-events: none;
}

.before-image {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    overflow: hidden;
}

.before-image img {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.slider-handle {
    position: absolute;
    top: 0;
    bottom: 0;
    width: 4px;
    background: white;
    cursor: col-resize;
    z-index: 10;
    box-shadow: 0 0 10px rgba(0,0,0,0.3);
}

.slider-handle::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 44px;
    height: 44px;
    background: white;
    border-radius: 50%;
    box-shadow: 0 2px 10px rgba(0,0,0,0.2);
}

.slider-handle::after {
    content: '\25C0 \25B6';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    font-size: 12px;
    color: #1E3A5F;
    white-space: nowrap;
    letter-spacing: 2px;
}

.before-label, .after-label {
    position: absolute;
    top: 1rem;
    padding: 0.5rem 1rem;
    background: rgba(0,0,0,0.7);
    color: white;
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    border-radius: 0.25rem;
    z-index: 5;
}

.before-label {
    left: 1rem;
}

.after-label {
    right: 1rem;
}

/* ==================== */
/* LIGHTBOX             */
/* ==================== */

.lightbox-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.95);
    z-index: 9999;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 2rem;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
}

.lightbox-overlay.active {
    opacity: 1;
    visibility: visible;
}

.lightbox-content {
    max-width: 90vw;
    max-height: 90vh;
    position: relative;
}

.lightbox-content img {
    max-width: 100%;
    max-height: 85vh;
    object-fit: contain;
    border-radius: 0.5rem;
}

.lightbox-close {
    position: absolute;
    top: -3rem;
    right: 0;
    color: white;
    font-size: 2rem;
    cursor: pointer;
    transition: transform 0.2s ease;
}

.lightbox-close:hover {
    transform: scale(1.1);
}

.lightbox-nav {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    color: white;
    font-size: 3rem;
    cursor: pointer;
    padding: 1rem;
    transition: all 0.2s ease;
    user-select: none;
}

.lightbox-nav:hover {
    color: #D4A853;
}

.lightbox-prev {
    left: -4rem;
}

.lightbox-next {
    right: -4rem;
}

.lightbox-caption {
    text-align: center;
    color: white;
    margin-top: 1rem;
    font-size: 0.875rem;
}

/* ==================== */
/* WHATSAPP FLOAT BTN   */
/* ==================== */

.whatsapp-float {
    position: fixed;
    bottom: 6rem;
    right: 1.5rem;
    width: 60px;
    height: 60px;
    background: #25D366;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 2rem;
    box-shadow: 0 4px 20px rgba(37, 211, 102, 0.4);
    z-index: 999;
    transition: all 0.3s ease;
    cursor: pointer;
}

.whatsapp-float:hover {
    transform: scale(1.1);
    box-shadow: 0 6px 30px rgba(37, 211, 102, 0.5);
}

.whatsapp-float svg {
    width: 32px;
    height: 32px;
}

@media (max-width: 768px) {
    .whatsapp-float {
        bottom: 5.5rem;
        right: 1rem;
        width: 56px;
        height: 56px;
    }

    .whatsapp-float svg {
        width: 28px;
        height: 28px;
    }
}

/* ==================== */
/* MOBILE STICKY CTA    */
/* ==================== */

.mobile-sticky-cta {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    background: white;
    padding: 0.75rem 1rem;
    box-shadow: 0 -4px 20px rgba(0, 0, 0, 0.1);
    z-index: 998;
    display: none;
}

@media (max-width: 768px) {
    .mobile-sticky-cta {
        display: block;
    }

    body {
        padding-bottom: 70px;
    }
}

/* ==================== */
/* TESTIMONIALS         */
/* ==================== */

/* Fix CTA to footer seam on some browsers */
.cta-final::after {
    content: "";
    position: absolute;
    left: 0;
    right: 0;
    bottom: -4px;
    height: 4px;
    background: #171717;
    pointer-events: none;
}

.cta-final {
    margin-bottom: -4px;
}

.cta-final + footer {
    margin-top: -4px;
    box-shadow: 0 -4px 0 #171717;
}

.testimonial-card {
    background: white;
    border-radius: 1rem;
    padding: 2rem;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.05);
    position: relative;
}

.testimonial-card::before {
    content: '\201C';
    position: absolute;
    top: 1rem;
    left: 1.5rem;
    font-size: 4rem;
    color: rgba(212, 168, 83, 0.2);
    font-family: Georgia, serif;
    line-height: 1;
}

.stars {
    color: #D4A853;
}

/* ==================== */
/* ZONE CARDS           */
/* ==================== */

.zone-card {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 1rem 1.5rem;
    background: white;
    border-radius: 0.5rem;
    border: 1px solid #E5E7EB;
    transition: all 0.3s ease;
    text-decoration: none;
    color: inherit;
}

.zone-card:hover {
    border-color: #D4A853;
    box-shadow: 0 4px 15px rgba(212, 168, 83, 0.15);
    transform: translateX(4px);
}

/* ==================== */
/* PROCESS STEPS        */
/* ==================== */

.process-step {
    position: relative;
    padding-left: 4rem;
}

.process-step::before {
    content: attr(data-step);
    position: absolute;
    left: 0;
    top: 0;
    width: 3rem;
    height: 3rem;
    background: linear-gradient(135deg, #1E3A5F 0%, #152942 100%);
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 1.25rem;
}

/* ==================== */
/* CONTACT FORM         */
/* ==================== */

.form-input {
    width: 100%;
    padding: 0.875rem 1rem;
    border: 1px solid #E5E7EB;
    border-radius: 0.5rem;
    font-size: 1rem;
    transition: all 0.3s ease;
}

.form-input:focus {
    outline: none;
    border-color: #1E3A5F;
    box-shadow: 0 0 0 3px rgba(30, 58, 95, 0.1);
}

.form-label {
    display: block;
    margin-bottom: 0.5rem;
    font-weight: 500;
    color: #2C3E50;
}

/* ==================== */
/* STAT NUMBERS         */
/* ==================== */

.stat-number {
    font-family: 'Playfair Display', serif;
    font-weight: 700;
    font-size: 2.5rem;
    background: linear-gradient(135deg, #1E3A5F 0%, #D4A853 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

@media (max-width: 768px) {
    .stat-number {
        font-size: 2rem;
    }
}

/* ==================== */
/* SECTION DIVIDER      */
/* ==================== */

.section-divider {
    width: 80px;
    height: 4px;
    background: linear-gradient(90deg, #D4A853, #1E3A5F);
    border-radius: 2px;
    margin: 0 auto;
}

/* ==================== */
/* BTN-SECONDARY        */
/* ==================== */

.btn-secondary {
    background: linear-gradient(135deg, #D4A853 0%, #B8923F 100%);
    color: #1E3A5F;
    font-weight: 600;
    padding: 0.875rem 2rem;
    border-radius: 0.5rem;
    transition: all 0.3s ease;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 44px;
    text-decoration: none;
    border: none;
    cursor: pointer;
}

.btn-secondary:hover {
    background: linear-gradient(135deg, #B8923F 0%, #9A7A33 100%);
    transform: translateY(-2px);
    box-shadow: 0 10px 30px rgba(212, 168, 83, 0.3);
}

/* ==================== */
/* BTN-WHATSAPP         */
/* ==================== */

.btn-whatsapp {
    background: #25D366;
    color: white;
    font-weight: 600;
    padding: 0.875rem 2rem;
    border-radius: 0.5rem;
    transition: all 0.3s ease;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 44px;
    text-decoration: none;
    border: none;
    cursor: pointer;
}

.btn-whatsapp:hover {
    background: #128C7E;
    transform: translateY(-2px);
    box-shadow: 0 10px 30px rgba(37, 211, 102, 0.3);
}

/* ==================== */
/* SERVICE CARD HOVER   */
/* ==================== */

.service-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 4px;
    background: linear-gradient(90deg, #D4A853, #1E3A5F);
    transform: scaleX(0);
    transform-origin: left;
    transition: transform 0.4s ease;
}

.service-card:hover::before {
    transform: scaleX(1);
}
