/* Variables de color */
:root {
    --primary: #2563eb;
    --primary-dark: #1d4ed8;
    --secondary: #f59e0b;
    --secondary-dark: #d97706;
    --accent: #10b981;
    --dark: #1e293b;
    --light: #f8fafc;
    --gray: #64748b;
    --gradient-primary: linear-gradient(135deg, #2563eb 0%, #10b981 100%);
    --gradient-secondary: linear-gradient(135deg, #f59e0b 0%, #f97316 100%);
}

/* Tipografía */
body {
    font-family: 'Poppins', sans-serif;
    color: var(--dark);
    line-height: 1.6;
}

h1, h2, h3, h4, h5, h6 {
    font-family: 'Playfair Display', serif;
}

/* Navbar */
.navbar {
    transition: all 0.3s ease;
    padding: 1rem 0;
}

.navbar.scrolled {
    background: rgba(255, 255, 255, 0.98) !important;
    box-shadow: 0 2px 20px rgba(0,0,0,0.1);
    padding: 0.5rem 0;
}

.nav-link {
    font-weight: 500;
    color: var(--dark) !important;
    transition: color 0.3s ease;
}

.nav-link:hover, .nav-link.active {
    color: var(--primary) !important;
}

/* Hero Section */
.hero-section {
    min-height: 100vh;
    padding-top: 80px;
    background: linear-gradient(135deg, #f0f9ff 0%, #ffffff 100%);
    position: relative;
    overflow: hidden;
}

.hero-section::before {
    content: '';
    position: absolute;
    top: -50%;
    right: -20%;
    width: 800px;
    height: 800px;
    background: radial-gradient(circle, rgba(37, 99, 235, 0.1) 0%, transparent 70%);
    border-radius: 50%;
}

/* Cards */
.hover-card {
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.hover-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 40px rgba(0,0,0,0.1) !important;
}

.icon-box {
    width: 60px;
    height: 60px;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* Botones */
.btn-primary {
    background-color: var(--primary);
    border-color: var(--primary);
    font-weight: 600;
    padding: 0.75rem 1.5rem;
    transition: all 0.3s ease;
}

.btn-primary:hover {
    background-color: var(--primary-dark);
    border-color: var(--primary-dark);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(37, 99, 235, 0.4);
}

.btn-warning {
    background-color: var(--secondary);
    border-color: var(--secondary);
    color: #fff;
    font-weight: 600;
    padding: 0.75rem 1.5rem;
    transition: all 0.3s ease;
}

.btn-warning:hover {
    background-color: var(--secondary-dark);
    border-color: var(--secondary-dark);
    color: #fff;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(245, 158, 11, 0.4);
}

/* Cookie Banner */
.cookie-banner {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    background: var(--dark);
    color: white;
    padding: 1.5rem 0;
    z-index: 9999;
    display: none;
    box-shadow: 0 -4px 20px rgba(0,0,0,0.2);
}

.cookie-banner.show {
    display: block;
}

/* Formularios */
.form-control, .form-select {
    padding: 0.75rem 1rem;
    border: 2px solid #e2e8f0;
    border-radius: 0.5rem;
    transition: all 0.3s ease;
}

.form-control:focus, .form-select:focus {
    border-color: var(--primary);
    box-shadow: 0 0 0 0.2rem rgba(37, 99, 235, 0.25);
}

/* Secciones */
section {
    padding: 5rem 0;
}

.bg-light {
    background-color: var(--light) !important;
}

/* Imágenes */
.img-fluid {
    border-radius: 1rem;
}

/* Utilidades */
.text-primary {
    color: var(--primary) !important;
}

.text-warning {
    color: var(--secondary) !important;
}

.bg-primary {
    background-color: var(--primary) !important;
}

/* Blog Cards */
.blog-card {
    overflow: hidden;
    border-radius: 1rem;
    box-shadow: 0 4px 6px rgba(0,0,0,0.05);
    transition: all 0.3s ease;
}

.blog-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 12px 24px rgba(0,0,0,0.1);
}

.blog-card img {
    transition: transform 0.3s ease;
}

.blog-card:hover img {
    transform: scale(1.05);
}

/* Stats Counter */
.stat-item {
    padding: 2rem;
}

/* Footer */
footer a {
    transition: color 0.3s ease;
}

footer a:hover {
    color: var(--secondary) !important;
}

/* Responsive */
@media (max-width: 768px) {
    .hero-section {
        padding-top: 100px;
        text-align: center;
    }
    
    .hero-section .d-flex.gap-3 {
        justify-content: center;
    }
    
    section {
        padding: 3rem 0;
    }
    
    .display-4 {
        font-size: 2rem;
    }
}

/* Animaciones */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.animate-fade-in {
    animation: fadeInUp 0.8s ease forwards;
}

/* Loading lazy placeholder */
img[loading="lazy"] {
    background: linear-gradient(90deg, #f0f0f0 25%, #e0e0e0 50%, #f0f0f0 75%);
    background-size: 200% 100%;
    animation: loading 1.5s infinite;
}

@keyframes loading {
    0% { background-position: 200% 0; }
    100% { background-position: -200% 0; }
}

img[loading="lazy"][src] {
    animation: none;
    background: transparent;
}

/* Páginas legales */
.legal-content {
    background: white;
    padding: 3rem;
    border-radius: 1rem;
    box-shadow: 0 4px 6px rgba(0,0,0,0.05);
}

.legal-content h2 {
    color: var(--primary);
    margin-top: 2rem;
    margin-bottom: 1rem;
}

.legal-content h3 {
    color: var(--dark);
    margin-top: 1.5rem;
    margin-bottom: 0.75rem;
}

.legal-content p, .legal-content li {
    color: var(--gray);
    margin-bottom: 0.75rem;
}

/* Servicios detail */
.service-detail {
    padding: 2rem;
    border-left: 4px solid var(--primary);
    background: var(--light);
    border-radius: 0 0.5rem 0.5rem 0;
    margin-bottom: 2rem;
}

/* Proceso steps */
.step {
    position: relative;
    padding-left: 4rem;
    margin-bottom: 2rem;
}

.step::before {
    content: attr(data-step);
    position: absolute;
    left: 0;
    top: 0;
    width: 3rem;
    height: 3rem;
    background: var(--gradient-primary);
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
    font-size: 1.2rem;
}

.step:not(:last-child)::after {
    content: '';
    position: absolute;
    left: 1.5rem;
    top: 3rem;
    width: 2px;
    height: calc(100% - 1rem);
    background: #e2e8f0;
}