/* ============================================
   Listo! Plumbing — Valencia, Spain
   Professional Residential Plumbing Website
   ============================================ */

:root {
    --blue-900: #0c2d5a;
    --blue-700: #164e8a;
    --blue-600: #1a6bb5;
    --blue-500: #2185d0;
    --blue-400: #4da3e8;
    --blue-100: #dbeafe;
    --blue-50: #eff6ff;
    --orange-500: #f97316;
    --orange-600: #ea580c;
    --orange-400: #fb923c;
    --gray-900: #111827;
    --gray-700: #374151;
    --gray-500: #6b7280;
    --gray-300: #d1d5db;
    --gray-100: #f3f4f6;
    --gray-50: #f9fafb;
    --white: #ffffff;
    --radius: 10px;
    --radius-lg: 16px;
    --shadow-sm: 0 1px 3px rgba(0,0,0,0.08);
    --shadow-md: 0 4px 12px rgba(0,0,0,0.1);
    --shadow-lg: 0 10px 30px rgba(0,0,0,0.12);
    --transition: 0.25s ease;
}

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

html {
    scroll-behavior: smooth;
    scroll-padding-top: 80px;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
    color: var(--gray-700);
    line-height: 1.6;
    background: var(--white);
    overflow-x: hidden;
}

.container {
    max-width: 1140px;
    margin: 0 auto;
    padding: 0 24px;
}

img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }

/* ---- Buttons ---- */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 12px 28px;
    border-radius: var(--radius);
    font-weight: 600;
    font-size: 1rem;
    cursor: pointer;
    transition: all var(--transition);
    border: 2px solid transparent;
    text-decoration: none;
    white-space: nowrap;
}
.btn-cta {
    background: var(--orange-500);
    color: var(--white);
    border-color: var(--orange-500);
}
.btn-cta:hover {
    background: var(--orange-600);
    border-color: var(--orange-600);
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(249, 115, 22, 0.35);
}
.btn-outline {
    background: transparent;
    color: var(--white);
    border-color: var(--white);
}
.btn-outline:hover {
    background: var(--white);
    color: var(--blue-700);
}
.btn-lg {
    padding: 16px 36px;
    font-size: 1.1rem;
}
.btn-nav-cta {
    background: var(--orange-500);
    color: var(--white);
    padding: 8px 20px;
    font-size: 0.9rem;
    border-radius: var(--radius);
}
.btn-nav-cta:hover {
    background: var(--orange-600);
}

.pulse {
    animation: pulse 2.5s infinite;
}
@keyframes pulse {
    0% { box-shadow: 0 0 0 0 rgba(249, 115, 22, 0.5); }
    70% { box-shadow: 0 0 0 14px rgba(249, 115, 22, 0); }
    100% { box-shadow: 0 0 0 0 rgba(249, 115, 22, 0); }
}

/* ---- Navbar ---- */
.navbar {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    background: rgba(255, 255, 255, 0.97);
    backdrop-filter: blur(10px);
    box-shadow: var(--shadow-sm);
    transition: all var(--transition);
}
.navbar.scrolled {
    box-shadow: var(--shadow-md);
}
.nav-container {
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 84px;
}
.logo {
    display: flex;
    align-items: center;
    gap: 10px;
    font-weight: 800;
    font-size: 1.3rem;
    color: var(--blue-700);
    flex-shrink: 0;
}
.logo-icon { font-size: 1.5rem; }
.logo-img {
    height: 64px;
    width: auto;
    flex-shrink: 0;
}
.logo-text {
    font-weight: 800;
    font-size: 1.2rem;
    color: var(--primary, #0a4d8c);
    letter-spacing: -0.01em;
}
img.flag-img,
.flag-img {
    width: 22px !important;
    height: 16px !important;
    max-width: 22px !important;
    max-height: 16px !important;
    object-fit: cover;
    border-radius: 2px;
    box-shadow: 0 0 0 1px rgba(0, 0, 0, 0.1);
    vertical-align: middle;
    display: inline-block;
    flex-shrink: 0;
}
.lang-btn img.flag-img {
    width: 26px !important;
    height: 19px !important;
    max-width: 26px !important;
    max-height: 19px !important;
}
.footer .logo-img {
    height: 48px;
    filter: brightness(0) invert(1);
    opacity: 0.85;
}
.nav-links {
    display: flex;
    list-style: none;
    gap: 32px;
}
.nav-links a {
    font-weight: 500;
    font-size: 0.95rem;
    color: var(--gray-700);
    transition: color var(--transition);
    position: relative;
}
.nav-links a::after {
    content: '';
    position: absolute;
    bottom: -4px;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--blue-500);
    transition: width var(--transition);
}
.nav-links a:hover { color: var(--blue-600); }
.nav-links a:hover::after { width: 100%; }

.nav-right {
    display: flex;
    align-items: center;
    gap: 12px;
}

/* Language Selector */
.lang-selector {
    position: relative;
}
.lang-btn {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 6px 12px;
    background: var(--gray-100);
    border: 1px solid var(--gray-300);
    border-radius: var(--radius);
    cursor: pointer;
    font-size: 0.85rem;
    font-weight: 500;
    color: var(--gray-700);
    transition: all var(--transition);
}
.lang-btn:hover {
    background: var(--blue-50);
    border-color: var(--blue-400);
}
.lang-arrow { font-size: 0.7rem; }
.lang-dropdown {
    display: none;
    position: absolute;
    top: calc(100% + 6px);
    right: 0;
    background: var(--white);
    border: 1px solid var(--gray-300);
    border-radius: var(--radius);
    box-shadow: var(--shadow-md);
    list-style: none;
    min-width: 150px;
    overflow: hidden;
    z-index: 10;
}
.lang-dropdown.open { display: block; }
.lang-dropdown li {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 16px;
    cursor: pointer;
    font-size: 0.9rem;
    transition: background var(--transition);
}
.lang-dropdown li:hover {
    background: var(--blue-50);
}

/* Hamburger */
.hamburger {
    display: none;
    flex-direction: column;
    gap: 5px;
    background: none;
    border: none;
    cursor: pointer;
    padding: 4px;
}
.hamburger span {
    width: 24px;
    height: 2.5px;
    background: var(--gray-700);
    border-radius: 2px;
    transition: all var(--transition);
}

/* ---- Hero ---- */
.hero {
    position: relative;
    min-height: 92vh;
    display: flex;
    align-items: center;
    background: linear-gradient(135deg, #0a1e3d 0%, #0c2d5a 25%, #164e8a 50%, #1a6bb5 75%, #0c2d5a 100%);
    background-size: 300% 300%;
    animation: heroGradient 12s ease infinite;
    overflow: hidden;
}
@keyframes heroGradient {
    0% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
    100% { background-position: 0% 50%; }
}
.hero-overlay {
    position: absolute;
    inset: 0;
    background:
        radial-gradient(ellipse at 20% 80%, rgba(33,133,208,0.2) 0%, transparent 50%),
        radial-gradient(ellipse at 80% 20%, rgba(77,163,232,0.15) 0%, transparent 50%),
        radial-gradient(ellipse at 50% 50%, rgba(255,255,255,0.03) 0%, transparent 70%);
}

/* Floating plumbing icons */
.hero-floats {
    position: absolute;
    inset: 0;
    pointer-events: none;
    z-index: 1;
}
.float-icon {
    position: absolute;
    left: var(--x);
    top: var(--y);
    font-size: 2.4rem;
    opacity: 0.12;
    animation: floatUpDown var(--dur) ease-in-out var(--delay) infinite;
    filter: grayscale(0.3);
}
.float-icon.sm {
    font-size: 1.4rem;
    opacity: 0.08;
}
@keyframes floatUpDown {
    0%, 100% { transform: translateY(0) rotate(0deg); }
    25% { transform: translateY(-18px) rotate(5deg); }
    50% { transform: translateY(-30px) rotate(-3deg); }
    75% { transform: translateY(-12px) rotate(2deg); }
}

/* Wave at hero bottom */
.hero-wave {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    z-index: 1;
    line-height: 0;
}
.hero-wave svg {
    width: 100%;
    height: 80px;
}
.hero-content {
    position: relative;
    z-index: 2;
    text-align: center;
    color: var(--white);
    padding: 120px 0 80px;
}
.hero h1 {
    font-size: clamp(2.2rem, 5vw, 3.5rem);
    font-weight: 800;
    line-height: 1.15;
    margin-bottom: 20px;
}
.hero-subtitle {
    font-size: clamp(1rem, 2.5vw, 1.25rem);
    opacity: 0.9;
    max-width: 600px;
    margin: 0 auto 36px;
    line-height: 1.7;
}
.hero-buttons {
    display: flex;
    gap: 16px;
    justify-content: center;
    flex-wrap: wrap;
    margin-bottom: 50px;
}
.hero-trust {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 32px;
    flex-wrap: wrap;
}
.trust-item {
    display: flex;
    flex-direction: column;
    align-items: center;
}
.trust-number {
    font-size: 1.8rem;
    font-weight: 800;
}
.trust-item span:last-child {
    font-size: 0.85rem;
    opacity: 0.8;
}
.trust-divider {
    width: 1px;
    height: 40px;
    background: rgba(255,255,255,0.3);
}

/* ---- Sections Common ---- */
.section-title {
    font-size: clamp(1.6rem, 3vw, 2.2rem);
    font-weight: 800;
    color: var(--blue-900);
    text-align: center;
    margin-bottom: 12px;
}
.section-subtitle {
    text-align: center;
    color: var(--gray-500);
    font-size: 1.05rem;
    max-width: 560px;
    margin: 0 auto 48px;
}

/* ---- Services ---- */
.services {
    padding: 90px 0;
    background: var(--gray-50);
}
.services-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 28px;
}
.service-card {
    background: var(--white);
    padding: 36px 28px;
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-sm);
    transition: all var(--transition);
    border: 1px solid var(--gray-100);
}
.service-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-lg);
    border-color: var(--blue-100);
}
.service-icon {
    font-size: 2.4rem;
    margin-bottom: 16px;
}
.service-card h3 {
    font-size: 1.15rem;
    font-weight: 700;
    color: var(--blue-900);
    margin-bottom: 10px;
}
.service-card p {
    font-size: 0.93rem;
    color: var(--gray-500);
    line-height: 1.65;
}

/* ---- Pool Section ---- */
.pool-section {
    padding: 90px 0;
    background: var(--white);
}
.pool-content {
    display: grid;
    grid-template-columns: 1.2fr 0.8fr;
    gap: 60px;
    align-items: center;
}
.pool-section .section-title {
    text-align: left;
}
.pool-intro {
    font-size: 1.05rem;
    color: var(--gray-500);
    margin-bottom: 28px;
    line-height: 1.7;
}
.pool-features {
    list-style: none;
    margin-bottom: 32px;
}
.pool-features li {
    padding: 10px 0 10px 28px;
    position: relative;
    font-size: 0.95rem;
    color: var(--gray-700);
}
.pool-features li::before {
    content: '✓';
    position: absolute;
    left: 0;
    color: var(--blue-500);
    font-weight: 700;
}
.pool-visual {
    display: flex;
    align-items: center;
    justify-content: center;
}
.pool-image-placeholder {
    width: 100%;
    aspect-ratio: 1;
    max-width: 380px;
    background: linear-gradient(135deg, var(--blue-100), var(--blue-50));
    border-radius: var(--radius-lg);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 12px;
}
.pool-emoji {
    font-size: 5rem;
}
.pool-image-placeholder p {
    font-weight: 700;
    color: var(--blue-700);
    font-size: 1.1rem;
}

/* ---- Areas ---- */
.areas {
    padding: 90px 0;
    background: var(--blue-900);
    color: var(--white);
}
.areas .section-title {
    color: var(--white);
}
.areas .section-subtitle {
    color: rgba(255,255,255,0.7);
}
.areas-grid {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 14px;
}
.area-tag {
    padding: 10px 22px;
    background: rgba(255,255,255,0.1);
    border: 1px solid rgba(255,255,255,0.2);
    border-radius: 50px;
    font-size: 0.95rem;
    font-weight: 500;
    transition: all var(--transition);
}
.area-tag:hover {
    background: rgba(255,255,255,0.2);
}

/* ---- About ---- */
.about {
    padding: 90px 0;
    background: var(--gray-50);
}
.about-content {
    max-width: 720px;
    margin: 0 auto;
}
.about .section-title {
    margin-bottom: 24px;
}
.about-text p {
    font-size: 1.02rem;
    line-height: 1.75;
    margin-bottom: 20px;
    color: var(--gray-700);
}
.about-features {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 14px;
    margin-top: 28px;
}
.about-feature {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 0.95rem;
    font-weight: 500;
}
.about-feature-icon {
    color: var(--blue-500);
    font-weight: 700;
    font-size: 1.1rem;
}

/* ---- Appointment Form ---- */
.appointment {
    padding: 90px 0;
    background: var(--white);
}
.appointment-form {
    max-width: 680px;
    margin: 0 auto;
}
.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
}
.form-group {
    margin-bottom: 20px;
}
.form-group.full-width {
    grid-column: 1 / -1;
}
.form-group label {
    display: block;
    font-weight: 600;
    font-size: 0.9rem;
    color: var(--gray-700);
    margin-bottom: 6px;
}
.form-group input,
.form-group select,
.form-group textarea {
    width: 100%;
    padding: 12px 16px;
    border: 1.5px solid var(--gray-300);
    border-radius: var(--radius);
    font-size: 1rem;
    font-family: inherit;
    color: var(--gray-900);
    transition: border-color var(--transition);
    background: var(--white);
}
.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
    outline: none;
    border-color: var(--blue-500);
    box-shadow: 0 0 0 3px rgba(33, 133, 208, 0.12);
}
.form-group textarea {
    resize: vertical;
}
.captcha-group label {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
}
.captcha-group label strong {
    color: var(--blue-600);
    font-size: 1.1rem;
}
.captcha-group input {
    max-width: 160px;
}
.form-submit {
    width: 100%;
    margin-top: 8px;
}
.form-success {
    text-align: center;
    max-width: 480px;
    margin: 0 auto;
    padding: 40px;
}
.success-icon {
    font-size: 3rem;
    display: block;
    margin-bottom: 16px;
}
.form-success h3 {
    font-size: 1.4rem;
    color: var(--blue-900);
    margin-bottom: 10px;
}
.form-success p {
    color: var(--gray-500);
}

/* ---- Contact ---- */
.contact {
    padding: 90px 0;
    background: var(--gray-50);
}
.contact-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 48px;
    align-items: start;
}
.contact .section-title {
    text-align: left;
    margin-bottom: 32px;
}
.contact-item {
    display: flex;
    gap: 16px;
    margin-bottom: 24px;
}
.contact-icon {
    font-size: 1.5rem;
    flex-shrink: 0;
    margin-top: 2px;
}
.contact-photo {
    width: 52px;
    height: 52px;
    border-radius: 50%;
    object-fit: cover;
    flex-shrink: 0;
    border: 2px solid var(--blue-400);
}
.contact-item strong {
    display: block;
    font-size: 0.85rem;
    color: var(--gray-500);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 4px;
}
.contact-item p {
    font-size: 1rem;
    color: var(--gray-900);
}
.contact-item a {
    color: var(--blue-600);
    transition: color var(--transition);
}
.contact-item a:hover {
    color: var(--blue-700);
}
.contact-map {
    display: flex;
    align-items: center;
    justify-content: center;
}
.map-placeholder {
    width: 100%;
    height: 320px;
    background: var(--gray-100);
    border-radius: var(--radius-lg);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 8px;
    font-size: 2rem;
    color: var(--gray-500);
    border: 2px dashed var(--gray-300);
}
.map-placeholder p {
    font-size: 1rem;
    font-weight: 600;
}

/* ---- Floating CTA ---- */
.floating-cta {
    position: fixed;
    bottom: 28px;
    right: 28px;
    z-index: 900;
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 14px 24px;
    background: var(--orange-500);
    color: var(--white);
    border-radius: 50px;
    font-weight: 700;
    font-size: 1rem;
    box-shadow: 0 6px 24px rgba(249, 115, 22, 0.4);
    transition: all var(--transition);
    opacity: 0;
    transform: translateY(20px);
    pointer-events: none;
}
.floating-cta.visible {
    opacity: 1;
    transform: translateY(0);
    pointer-events: all;
}
.floating-cta:hover {
    background: var(--orange-600);
    transform: translateY(-2px);
    box-shadow: 0 8px 28px rgba(249, 115, 22, 0.5);
}
.floating-cta-icon { font-size: 1.2rem; }

/* ---- Footer ---- */
.footer {
    background: var(--gray-900);
    color: rgba(255,255,255,0.7);
    padding: 48px 0 24px;
}
.footer-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-bottom: 28px;
    border-bottom: 1px solid rgba(255,255,255,0.1);
}
.footer-brand {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
}
.footer-brand .logo-text {
    color: var(--white);
    font-weight: 700;
    font-size: 1.15rem;
}
.footer-brand p {
    width: 100%;
    font-size: 0.85rem;
    margin-top: 4px;
}
.footer-links {
    display: flex;
    gap: 24px;
}
.footer-links a {
    font-size: 0.9rem;
    transition: color var(--transition);
}
.footer-links a:hover { color: var(--white); }
.footer-bottom {
    text-align: center;
    padding-top: 24px;
    font-size: 0.85rem;
}

/* ---- Responsive ---- */
/* ---- Scroll Reveal ---- */
.reveal {
    opacity: 0;
    transform: translateY(24px);
    transition: opacity 0.6s ease, transform 0.6s ease;
}
.reveal.revealed {
    opacity: 1;
    transform: translateY(0);
}

/* ---- Responsive ---- */
@media (max-width: 900px) {
    .services-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    .pool-content {
        grid-template-columns: 1fr;
        gap: 40px;
    }
    .pool-section .section-title {
        text-align: center;
    }
    .pool-text { text-align: center; }
    .pool-features li { text-align: left; }
    .contact-grid {
        grid-template-columns: 1fr;
    }
    .about-features {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 768px) {
    .nav-links {
        display: none;
        position: absolute;
        top: 84px;
        left: 0;
        right: 0;
        background: var(--white);
        flex-direction: column;
        padding: 20px 24px;
        gap: 0;
        box-shadow: var(--shadow-md);
    }
    .nav-links.open { display: flex; }
    .nav-links a {
        padding: 12px 0;
        border-bottom: 1px solid var(--gray-100);
    }
    .hamburger { display: flex; }
    .hamburger.open span:nth-child(1) {
        transform: translateY(7.5px) rotate(45deg);
    }
    .hamburger.open span:nth-child(2) { opacity: 0; }
    .hamburger.open span:nth-child(3) {
        transform: translateY(-7.5px) rotate(-45deg);
    }
    .services-grid {
        grid-template-columns: 1fr;
    }
    .form-row {
        grid-template-columns: 1fr;
    }
    .hero-trust {
        gap: 20px;
    }
    .trust-divider { display: none; }
    .footer-content {
        flex-direction: column;
        gap: 20px;
        text-align: center;
    }
    .footer-brand { justify-content: center; }
    .footer-brand p { text-align: center; }
    .footer-links {
        flex-wrap: wrap;
        justify-content: center;
    }
    .floating-cta-text { display: none; }
    .floating-cta { padding: 14px; border-radius: 50%; }
}
