/* ========================================
   AWAVIVA AGUA - CSS PROFESIONAL 2026
   Diseño Empresarial de Nivel Premium
   ======================================== */

:root {
    --primary: #27c1bf;
    --primary-dark: #1fa9a7;
    --primary-light: #4dd4d1;
    --dark: #0f0f23;
    --dark-light: #1a1a3e;
    --white: #ffffff;
    --gray-50: #f9fafb;
    --gray-100: #f3f4f6;
    --gray-200: #e5e7eb;
    --gray-300: #d1d5db;
    --gray-400: #9ca3af;
    --gray-500: #6b7280;
    --gray-600: #4b5563;
    --gray-700: #374151;
    --gray-800: #1f2937;
    --gray-900: #111827;
    --text-primary: #1f2937;
    --text-secondary: #6b7280;
    --shadow-xs: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
    --shadow-sm: 0 1px 3px 0 rgba(0, 0, 0, 0.1), 0 1px 2px 0 rgba(0, 0, 0, 0.06);
    --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
    --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
    --shadow-xl: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
    --transition-fast: 150ms cubic-bezier(0.4, 0, 0.2, 1);
    --transition-base: 200ms cubic-bezier(0.4, 0, 0.2, 1);
    --transition-slow: 300ms cubic-bezier(0.4, 0, 0.2, 1);
}

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

html {
    scroll-behavior: smooth;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Century Gothic', 'Trebuchet MS', sans-serif;
    color: var(--text-primary);
    background-color: var(--white);
    line-height: 1.6;
    font-size: 16px;
}

/* ========== HEADER ========== */
.header {
    background: var(--white);
    padding: 1rem 0;
    position: sticky;
    top: 0;
    z-index: 1000;
    box-shadow: var(--shadow-md);
    border-bottom: 3px solid var(--primary);
    transition: var(--transition-base);
}

.header.scrolled {
    box-shadow: var(--shadow-lg);
    padding: 0.75rem 0;
}

.navbar {
    max-width: 1400px;
    margin: 0 auto;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0 2rem;
}

@media (max-width: 1024px) {
    .navbar {
        padding: 0 1.5rem;
    }
}

@media (max-width: 768px) {
    .navbar {
        padding: 0 1rem;
    }
}

.nav-container {
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: 100%;
}

.logo img {
    height: 50px;
    width: auto;
    transition: var(--transition-base);
    filter: drop-shadow(0 2px 8px rgba(39, 193, 191, 0.15));
}

.logo img:hover {
    transform: scale(1.08);
    filter: drop-shadow(0 4px 12px rgba(39, 193, 191, 0.3));
}

.nav-menu {
    display: flex;
    list-style: none;
    gap: 3rem;
    align-items: center;
}

.nav-menu a {
    color: var(--text-primary);
    text-decoration: none;
    font-weight: 600;
    font-size: 0.95rem;
    position: relative;
    transition: color var(--transition-base);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.nav-menu a::after {
    content: '';
    position: absolute;
    bottom: -8px;
    left: 0;
    width: 0;
    height: 2px;
    background: linear-gradient(90deg, var(--primary), var(--primary-light));
    transition: width var(--transition-base);
}

.nav-menu a:hover {
    color: var(--primary);
}

.nav-menu a:hover::after {
    width: 100%;
}

.hamburger {
    display: none;
    flex-direction: column;
    cursor: pointer;
    gap: 6px;
}

.hamburger span {
    width: 25px;
    height: 3px;
    background: var(--text-primary);
    border-radius: 2px;
    transition: var(--transition-base);
}

.hamburger.active span:nth-child(1) {
    transform: rotate(45deg) translate(10px, 10px);
}

.hamburger.active span:nth-child(2) {
    opacity: 0;
}

.hamburger.active span:nth-child(3) {
    transform: rotate(-45deg) translate(7px, -7px);
}

@media (max-width: 768px) {
    .hamburger {
        display: flex;
    }
    
    .nav-menu {
        position: absolute;
        top: 70px;
        left: 0;
        right: 0;
        background: var(--white);
        flex-direction: column;
        gap: 0;
        max-height: 0;
        overflow: hidden;
        transition: max-height var(--transition-base);
        box-shadow: var(--shadow-lg);
    }
    
    .nav-menu.active {
        max-height: 400px;
    }
    
    .nav-menu a {
        padding: 1rem 2rem;
        display: block;
        border-bottom: 1px solid var(--gray-100);
    }
    
    .nav-menu a::after {
        display: none;
    }
}

/* ========== HERO ========== */
.hero {
    position: relative;
    min-height: 600px;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    background: linear-gradient(135deg, var(--dark) 0%, var(--dark-light) 100%);
}

.hero::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 1200 600"><defs><pattern id="grid" width="100" height="100" patternUnits="userSpaceOnUse"><path d="M 100 0 L 0 0 0 100" fill="none" stroke="rgba(39,193,191,0.03)" stroke-width="1"/></pattern></defs><rect width="1200" height="600" fill="url(%23grid)"/></svg>');
    opacity: 1;
}

.hero-video {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    opacity: 0.2;
}

.hero-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(135deg, rgba(15, 15, 35, 0.8) 0%, rgba(31, 169, 167, 0.2) 100%);
    z-index: 1;
}

.hero-content {
    position: relative;
    z-index: 2;
    text-align: center;
    max-width: 900px;
    padding: 0 2rem;
    animation: fadeInUp 0.8s ease-out;
}

.hero-title {
    font-size: clamp(2.5rem, 8vw, 64px);
    font-weight: 900;
    color: var(--white);
    margin-bottom: 1.5rem;
    line-height: 1.1;
    text-shadow: 0 4px 20px rgba(0, 0, 0, 0.5);
    letter-spacing: -1px;
}

.hero-title span {
    background: linear-gradient(135deg, var(--primary-light), var(--primary));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.hero-subtitle {
    font-size: clamp(1rem, 3vw, 20px);
    color: rgba(255, 255, 255, 0.95);
    margin-bottom: 2.5rem;
    animation: fadeInUp 0.8s ease-out 0.2s both;
    text-shadow: 0 2px 10px rgba(0, 0, 0, 0.3);
}

.hero-btn {
    display: inline-block;
    padding: 1rem 3rem;
    background: linear-gradient(135deg, var(--primary), var(--primary-dark));
    color: var(--white);
    text-decoration: none;
    border-radius: 50px;
    font-weight: 700;
    font-size: 1rem;
    transition: var(--transition-base);
    box-shadow: 0 10px 30px rgba(39, 193, 191, 0.3);
    text-transform: uppercase;
    letter-spacing: 1px;
    animation: fadeInUp 0.8s ease-out 0.4s both;
    border: 2px solid transparent;
    cursor: pointer;
}

.hero-btn:hover {
    transform: translateY(-3px);
    box-shadow: 0 15px 40px rgba(39, 193, 191, 0.5);
    background: linear-gradient(135deg, var(--primary-dark), var(--primary));
}

.hero-btn:active {
    transform: translateY(-1px);
}

@media (max-width: 768px) {
    .hero {
        min-height: 400px;
    }
    
    .hero-content {
        padding: 0 1rem;
    }
}

/* ========== SECCIONES ========== */
section {
    scroll-margin-top: 80px;
}

.container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 2rem;
}

@media (max-width: 768px) {
    .container {
        padding: 0 1rem;
    }
}

.section-title {
    text-align: center;
    margin-bottom: 4rem;
}

.section-title h2 {
    font-size: clamp(2rem, 5vw, 48px);
    font-weight: 900;
    color: var(--dark);
    margin-bottom: 1rem;
    letter-spacing: -0.5px;
}

.section-title h2 span {
    color: var(--primary);
}

.section-title p {
    font-size: 1.1rem;
    color: var(--text-secondary);
    opacity: 0.9;
}

/* ========== CARACTERÍSTICAS ========== */
.caracteristicas {
    padding: 5rem 0;
    background: linear-gradient(135deg, var(--gray-50) 0%, var(--white) 100%);
}

.caracteristicas-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2rem;
}

@media (max-width: 1024px) {
    .caracteristicas-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 640px) {
    .caracteristicas-grid {
        grid-template-columns: 1fr;
    }
}

.caracteristica-card {
    background: var(--white);
    padding: 2.5rem;
    border-radius: 12px;
    text-align: center;
    transition: var(--transition-base);
    box-shadow: var(--shadow-sm);
    border-left: 4px solid var(--primary);
    position: relative;
    overflow: hidden;
}

.caracteristica-card::before {
    content: '';
    position: absolute;
    top: -50%;
    right: -50%;
    width: 200px;
    height: 200px;
    background: radial-gradient(circle, rgba(39, 193, 191, 0.08), transparent);
    border-radius: 50%;
    transition: var(--transition-slow);
}

.caracteristica-card:hover {
    transform: translateY(-8px);
    box-shadow: var(--shadow-lg);
    border-left-color: var(--primary-dark);
}

.caracteristica-card:hover::before {
    top: -25%;
    right: -25%;
}

.caracteristica-card i {
    font-size: 3rem;
    color: var(--primary);
    margin-bottom: 1.5rem;
    display: block;
    transition: var(--transition-base);
}

.caracteristica-card:hover i {
    transform: scale(1.15) rotate(-10deg);
    color: var(--primary-dark);
}

.caracteristica-card h3 {
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--dark);
    margin-bottom: 1rem;
}

.caracteristica-card p {
    font-size: 0.95rem;
    color: var(--text-secondary);
    line-height: 1.6;
}

/* ========== SERVICIOS ========== */
.servicios {
    padding: 6rem 0;
    background: var(--white);
}

.servicios-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2.5rem;
}

@media (max-width: 1024px) {
    .servicios-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 640px) {
    .servicios-grid {
        grid-template-columns: 1fr;
    }
}

.servicio-card {
    background: var(--white);
    border-radius: 12px;
    overflow: hidden;
    box-shadow: var(--shadow-md);
    transition: var(--transition-base);
    border-top: 4px solid var(--primary);
}

.servicio-card:hover {
    transform: translateY(-12px);
    box-shadow: var(--shadow-xl);
}

.servicio-imagen {
    position: relative;
    width: 100%;
    height: 200px;
    overflow: hidden;
    background: linear-gradient(135deg, var(--primary-light), var(--primary));
}

.servicio-imagen img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: var(--transition-slow);
}

.servicio-card:hover .servicio-imagen img {
    transform: scale(1.1);
}

.servicio-icon {
    position: absolute;
    top: 1.25rem;
    right: 1.25rem;
    width: 60px;
    height: 60px;
    background: var(--white);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.875rem;
    color: var(--primary);
    box-shadow: var(--shadow-md);
    z-index: 10;
}

.servicio-content {
    padding: 2rem;
}

.servicio-content h3 {
    font-size: 1.375rem;
    font-weight: 700;
    color: var(--dark);
    margin-bottom: 1rem;
}

.servicio-content p {
    font-size: 0.95rem;
    color: var(--text-secondary);
    margin-bottom: 1.5rem;
    line-height: 1.6;
}

.servicio-lista {
    list-style: none;
}

.servicio-lista li {
    font-size: 0.9rem;
    color: var(--text-secondary);
    margin-bottom: 0.75rem;
    padding-left: 1.75rem;
    position: relative;
}

.servicio-lista li::before {
    content: '✓';
    position: absolute;
    left: 0;
    color: var(--primary);
    font-weight: 900;
    font-size: 1rem;
}

/* ========== TESTIMONIOS ========== */
.testimonios {
    padding: 6rem 0;
    background: var(--gray-50);
}

.testimonios-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2rem;
}

@media (max-width: 1024px) {
    .testimonios-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 640px) {
    .testimonios-grid {
        grid-template-columns: 1fr;
    }
}

.testimonio-card {
    background: var(--white);
    padding: 2rem;
    border-radius: 12px;
    box-shadow: var(--shadow-sm);
    transition: var(--transition-base);
    border-left: 4px solid var(--primary);
}

.testimonio-card:hover {
    transform: translateY(-6px);
    box-shadow: var(--shadow-lg);
    border-left-color: var(--primary-dark);
}

.testimonio-header {
    display: flex;
    gap: 1rem;
    margin-bottom: 1.5rem;
}

.testimonio-header img {
    width: 50px;
    height: 50px;
    border-radius: 50%;
    object-fit: cover;
    border: 3px solid var(--primary);
}

.testimonio-info h4 {
    font-size: 0.95rem;
    font-weight: 700;
    color: var(--dark);
}

.testimonio-info p {
    font-size: 0.85rem;
    color: var(--text-secondary);
    opacity: 0.8;
}

.testimonio-stars {
    color: #ffc107;
    font-size: 0.9rem;
    margin-bottom: 1rem;
}

.testimonio-text {
    font-size: 0.9rem;
    color: var(--text-secondary);
    line-height: 1.6;
    font-style: italic;
}

/* ========== CONTACTO ========== */
.contacto {
    padding: 6rem 0;
    background: linear-gradient(135deg, var(--dark) 0%, var(--dark-light) 100%);
    color: var(--white);
}

.contacto-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: center;
}

@media (max-width: 768px) {
    .contacto-content {
        grid-template-columns: 1fr;
        gap: 2rem;
    }
}

.contacto-info {
    display: flex;
    flex-direction: column;
    gap: 2rem;
}

.contacto-item {
    display: flex;
    gap: 1.5rem;
    align-items: flex-start;
}

.contacto-item i {
    font-size: 1.875rem;
    color: var(--primary);
    min-width: 40px;
    text-align: center;
}

.contacto-item h4 {
    font-size: 1.1rem;
    font-weight: 700;
    margin-bottom: 0.5rem;
}

.contacto-item p,
.contacto-item a {
    font-size: 0.95rem;
    color: rgba(255, 255, 255, 0.9);
    text-decoration: none;
}

.contacto-item a:hover {
    color: var(--primary);
}

/* ========== FOOTER ========== */
.footer {
    background: var(--dark);
    color: var(--white);
    padding: 3rem 0 1rem;
    border-top: 3px solid var(--primary);
}

.footer-content {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2.5rem;
    margin-bottom: 2rem;
}

.footer-section h4 {
    font-size: 1rem;
    font-weight: 700;
    margin-bottom: 1.5rem;
    color: var(--primary);
}

.footer-section ul {
    list-style: none;
}

.footer-section ul li {
    margin-bottom: 0.75rem;
}

.footer-section a {
    color: rgba(255, 255, 255, 0.8);
    text-decoration: none;
    font-size: 0.9rem;
    transition: var(--transition-base);
}

.footer-section a:hover {
    color: var(--primary);
}

.footer-bottom {
    text-align: center;
    padding-top: 1.5rem;
    border-top: 1px solid rgba(39, 193, 191, 0.2);
    font-size: 0.85rem;
    color: rgba(255, 255, 255, 0.7);
}

/* ========== WHATSAPP WIDGET ========== */
.whatsapp-widget {
    position: fixed;
    bottom: 2rem;
    right: 2rem;
    width: 60px;
    height: 60px;
    background: linear-gradient(135deg, var(--primary), var(--primary-dark));
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--white);
    font-size: 1.875rem;
    text-decoration: none;
    box-shadow: 0 10px 30px rgba(39, 193, 191, 0.4);
    transition: var(--transition-base);
    z-index: 999;
}

.whatsapp-widget:hover {
    transform: scale(1.15) rotate(10deg);
    box-shadow: 0 15px 40px rgba(39, 193, 191, 0.6);
}

@media (max-width: 640px) {
    .whatsapp-widget {
        width: 50px;
        height: 50px;
        font-size: 1.5rem;
        bottom: 1rem;
        right: 1rem;
    }
}

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

@keyframes slideInLeft {
    from {
        opacity: 0;
        transform: translateX(-30px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes slideInRight {
    from {
        opacity: 0;
        transform: translateX(30px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

/* ========== UTILIDADES ========== */
.text-center {
    text-align: center;
}

.mt-1 { margin-top: 0.5rem; }
.mt-2 { margin-top: 1rem; }
.mt-4 { margin-top: 2rem; }

.mb-1 { margin-bottom: 0.5rem; }
.mb-2 { margin-bottom: 1rem; }
.mb-4 { margin-bottom: 2rem; }

/* ========== ACCESIBILIDAD ========== */
@media (prefers-reduced-motion: reduce) {
    * {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
}

/* ========== PRINT ========== */
@media print {
    .header,
    .footer,
    .whatsapp-widget {
        display: none;
    }
}
