/* ==========================================
   Variables y Reset
   ========================================== */
:root {
    --primary-color: #c3d500;
    --primary-dark: #9caa03;
    --secondary-color: #00cad1;
    --dark: #1a1a1a;
    --gray-dark: #333333;
    --gray: #666666;
    --gray-light: #f5f5f5;
    --white: #ffffff;
    --transition: all 0.3s ease;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    line-height: 1.6;
    color: var(--gray-dark);
    background: var(--white);
    overflow-x: hidden;
}

img {
    max-width: 100%;
    height: auto;
}

a {
    text-decoration: none;
    color: inherit;
    transition: var(--transition);
}

/* ==========================================
   Utilidades
   ========================================== */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

.section-title {
    font-size: 2.5rem;
    font-weight: 700;
    color: var(--dark);
    margin-bottom: 1rem;
    text-align: center;
}

.section-subtitle {
    font-size: 1.125rem;
    color: var(--gray);
    text-align: center;
    margin-bottom: 3rem;
}

/* Botones */
.btn {
    display: inline-block;
    padding: 14px 32px;
    border-radius: 8px;
    font-weight: 600;
    font-size: 1rem;
    cursor: pointer;
    transition: var(--transition);
    border: none;
    text-align: center;
}

.btn-primary {
    background: var(--primary-color);
    color: var(--dark);
}

.btn-primary:hover {
    background: var(--primary-dark);
    color: var(--white);
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(195, 213, 0, 0.3);
}

.btn-secondary {
    background: transparent;
    color: var(--dark);
    border: 2px solid var(--dark);
}

.btn-secondary:hover {
    background: var(--dark);
    color: var(--white);
}

.btn-primary-large {
    padding: 18px 48px;
    font-size: 1.125rem;
    background: var(--primary-color);
    color: var(--dark);
}

.btn-primary-large:hover {
    background: var(--primary-dark);
    color: var(--white);
    transform: translateY(-2px);
    box-shadow: 0 10px 30px rgba(195, 213, 0, 0.4);
}

/* ==========================================
   Header & Navigation
   ========================================== */
.header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
    z-index: 1000;
    transition: var(--transition);
}

.nav-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    height: 70px;
}

.logo-text {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--dark);
}

.nav-menu {
    display: flex;
    list-style: none;
    gap: 2rem;
}

.nav-menu a {
    font-weight: 500;
    color: var(--gray-dark);
    position: relative;
}

.nav-menu a::after {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--primary-color);
    transition: width 0.3s ease;
}

.nav-menu a:hover::after {
    width: 100%;
}

.menu-toggle {
    display: none;
    flex-direction: column;
    gap: 5px;
    background: none;
    border: none;
    cursor: pointer;
}

.menu-toggle span {
    width: 25px;
    height: 3px;
    background: var(--dark);
    transition: var(--transition);
}

/* ==========================================
   Hero Section
   ========================================== */
.hero {
    margin-top: 70px;
    padding: 100px 20px;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 60px;
    align-items: center;
    max-width: 1200px;
    margin-left: auto;
    margin-right: auto;
    min-height: calc(100vh - 70px);
}

.hero-content {
    animation: fadeInLeft 0.8s ease;
}

.hero-title {
    font-size: 3.5rem;
    font-weight: 700;
    color: var(--dark);
    line-height: 1.2;
    margin-bottom: 1.5rem;
}

.hero-title::first-line {
    color: var(--primary-color);
}

.hero-subtitle {
    font-size: 1.25rem;
    color: var(--gray);
    margin-bottom: 2.5rem;
    line-height: 1.8;
}

.hero-cta {
    display: flex;
    gap: 1rem;
}

.hero-image {
    position: relative;
    animation: fadeInRight 0.8s ease;
}

.hero-card {
    width: 100%;
    height: 500px;
    border-radius: 20px;
    position: relative;
    overflow: hidden;
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--secondary-color) 100%);
}

.hero-card img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 20px;
    display: block;
}

.hero-card::before {
    content: '';
    position: absolute;
    top: -50%;
    right: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle, rgba(255,255,255,0.1) 0%, transparent 70%);
    animation: rotate 20s linear infinite;
    z-index: 1;
}

/* ==========================================
   Intro Section
   ========================================== */
.intro {
    padding: 80px 20px;
    background: var(--gray-light);
}

.intro-content {
    max-width: 800px;
    margin: 0 auto;
    text-align: center;
}

.intro-content h2 {
    font-size: 2.5rem;
    color: var(--dark);
    margin-bottom: 1.5rem;
}

.intro-content p {
    font-size: 1.125rem;
    color: var(--gray);
    margin-bottom: 1.5rem;
    line-height: 1.8;
}

.intro-content strong {
    color: var(--primary-dark);
    font-weight: 600;
}

/* ==========================================
   Services Section
   ========================================== */
.services {
    padding: 100px 20px;
}

.services-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
    margin-top: 3rem;
}

.service-card {
    background: var(--white);
    padding: 0;
    border-radius: 12px;
    border: 1px solid #e5e5e5;
    transition: var(--transition);
    text-align: center;
    overflow: hidden;
    display: flex;
    flex-direction: column;
}

.service-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.1);
    border-color: var(--primary-color);
}

.service-image {
    width: 100%;
    height: 200px;
    object-fit: cover;
    display: block;
}

.service-icon {
    font-size: 3rem;
    margin: 1.5rem 0 1rem 0;
}

.service-card h3,
.service-card p {
    padding: 0 2.5rem;
}

.service-card p {
    padding-bottom: 2.5rem;
}

.service-card h3 {
    font-size: 1.5rem;
    color: var(--dark);
    margin-bottom: 1rem;
}

.service-card p {
    color: var(--gray);
    line-height: 1.8;
}

/* ==========================================
   Benefits Section
   ========================================== */
.benefits {
    padding: 100px 20px;
    background: linear-gradient(135deg, #f8f9fa 0%, var(--gray-light) 100%);
}

.benefits-header {
    margin-bottom: 4rem;
}

.benefits-content {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 3rem;
    max-width: 1000px;
    margin: 0 auto;
}

.benefit-item {
    position: relative;
    padding-left: 80px;
}

.benefit-number {
    position: absolute;
    left: 0;
    top: 0;
    font-size: 3rem;
    font-weight: 700;
    color: var(--primary-color);
    opacity: 0.3;
}

.benefit-item h3 {
    font-size: 1.5rem;
    color: var(--dark);
    margin-bottom: 0.75rem;
}

.benefit-item p {
    color: var(--gray);
    line-height: 1.8;
}

/* ==========================================
   Resources Section
   ========================================== */
.resources {
    padding: 100px 20px;
}

.resources-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
    margin-top: 3rem;
}

.resource-card {
    background: var(--white);
    padding: 2rem;
    border-radius: 12px;
    border: 1px solid #e5e5e5;
    transition: var(--transition);
}

.resource-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 30px rgba(0, 0, 0, 0.1);
}

.resource-tag {
    display: inline-block;
    padding: 6px 16px;
    background: var(--primary-color);
    color: var(--dark);
    border-radius: 20px;
    font-size: 0.875rem;
    font-weight: 600;
    margin-bottom: 1rem;
}

.resource-card h3 {
    font-size: 1.5rem;
    color: var(--dark);
    margin-bottom: 1rem;
}

.resource-card p {
    color: var(--gray);
    margin-bottom: 1.5rem;
    line-height: 1.8;
}

.resource-link {
    color: var(--secondary-color);
    font-weight: 600;
}

.resource-link:hover {
    color: var(--primary-dark);
}

/* ==========================================
   FAQ Section
   ========================================== */
.faq {
    padding: 100px 20px;
    background: var(--gray-light);
}

.faq-container {
    max-width: 800px;
    margin: 0 auto;
    margin-top: 3rem;
}

.faq-item {
    background: var(--white);
    border-radius: 12px;
    margin-bottom: 1rem;
    overflow: hidden;
    border: 1px solid #e5e5e5;
}

.faq-question {
    width: 100%;
    padding: 1.5rem 2rem;
    background: none;
    border: none;
    text-align: left;
    font-size: 1.125rem;
    font-weight: 600;
    color: var(--dark);
    cursor: pointer;
    display: flex;
    justify-content: space-between;
    align-items: center;
    transition: var(--transition);
}

.faq-question:hover {
    color: var(--primary-dark);
}

.faq-icon {
    font-size: 1.5rem;
    font-weight: 300;
    transition: var(--transition);
}

.faq-item.active .faq-icon {
    transform: rotate(45deg);
}

.faq-answer {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease;
}

.faq-item.active .faq-answer {
    max-height: 500px;
}

.faq-answer p {
    padding: 0 2rem 1.5rem 2rem;
    color: var(--gray);
    line-height: 1.8;
}

/* ==========================================
   CTA Section
   ========================================== */
.cta-section {
    padding: 100px 20px;
    background: linear-gradient(135deg, var(--dark) 0%, var(--gray-dark) 100%);
    color: var(--white);
}

.cta-content {
    text-align: center;
    max-width: 700px;
    margin: 0 auto;
}

.cta-content h2 {
    font-size: 2.5rem;
    margin-bottom: 1.5rem;
}

.cta-content p {
    font-size: 1.25rem;
    margin-bottom: 2.5rem;
    opacity: 0.9;
}

/* ==========================================
   Footer
   ========================================== */
.footer {
    background: var(--dark);
    color: var(--white);
    padding: 60px 20px 30px;
}

.footer-content {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 3rem;
    margin-bottom: 3rem;
}

.footer-section h4 {
    font-size: 1.25rem;
    margin-bottom: 1rem;
    color: var(--primary-color);
}

.footer-section p,
.footer-section ul {
    color: rgba(255, 255, 255, 0.7);
    line-height: 1.8;
}

.footer-section ul {
    list-style: none;
}

.footer-section ul li {
    margin-bottom: 0.5rem;
}

.footer-section a:hover {
    color: var(--primary-color);
}

.footer-bottom {
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    padding-top: 2rem;
    text-align: center;
    color: rgba(255, 255, 255, 0.5);
}

/* ==========================================
   Animaciones
   ========================================== */
@keyframes fadeInLeft {
    from {
        opacity: 0;
        transform: translateX(-30px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes fadeInRight {
    from {
        opacity: 0;
        transform: translateX(30px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes rotate {
    from {
        transform: rotate(0deg);
    }
    to {
        transform: rotate(360deg);
    }
}

/* ==========================================
   Responsive
   ========================================== */
@media (max-width: 968px) {
    .hero {
        grid-template-columns: 1fr;
        padding: 60px 20px;
    }

    .hero-title {
        font-size: 2.5rem;
    }

    .hero-image {
        display: none;
    }

    .section-title {
        font-size: 2rem;
    }

    .services-grid,
    .resources-grid {
        grid-template-columns: 1fr;
    }

    .benefits-content {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 768px) {
    .nav-menu {
        position: absolute;
        top: 70px;
        left: -100%;
        width: 100%;
        flex-direction: column;
        background: var(--white);
        padding: 2rem;
        box-shadow: 0 10px 20px rgba(0, 0, 0, 0.1);
        transition: left 0.3s ease;
    }

    .nav-menu.active {
        left: 0;
    }

    .menu-toggle {
        display: flex;
    }

    .hero-cta {
        flex-direction: column;
    }

    .btn {
        width: 100%;
        text-align: center;
    }

    .hero-title {
        font-size: 2rem;
    }

    .footer-content {
        grid-template-columns: 1fr;
    }
}

/* ==========================================
   Modales Legales (Google Ads Compliance)
   ========================================== */
.legal-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.8);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 10000;
    padding: 20px;
    overflow-y: auto;
}

.legal-content {
    background: var(--white);
    border-radius: 12px;
    padding: 40px;
    max-width: 700px;
    width: 100%;
    max-height: 90vh;
    overflow-y: auto;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
    position: relative;
}

.legal-content h2 {
    font-size: 2rem;
    color: var(--dark);
    margin-bottom: 1.5rem;
}

.legal-content p {
    color: var(--gray);
    line-height: 1.8;
    margin-bottom: 1rem;
}

.legal-content strong {
    color: var(--dark);
    font-weight: 600;
}

.legal-content .btn {
    margin-top: 2rem;
}

/* ==========================================
   Optimizaciones Google Ads 2025
   ========================================== */

/* Velocidad de carga - Preload crítico */
.hero-card {
    will-change: transform;
    transform: translateZ(0);
}

/* Mobile-first - Touch targets */
@media (max-width: 768px) {
    .btn {
        min-height: 44px;
        min-width: 44px;
    }
    
    .nav-menu a {
        padding: 12px 0;
        display: block;
    }
}

/* Accesibilidad - Focus visible */
a:focus-visible,
button:focus-visible {
    outline: 3px solid var(--primary-color);
    outline-offset: 2px;
}

/* Performance - Contenido crítico primero */
.hero-content {
    content-visibility: auto;
}

/* Cumplimiento Google Ads - Transparencia */
.footer-bottom p:last-child {
    font-size: 0.875rem;
    margin-top: 1rem;
    padding-top: 1rem;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

/* ==========================================
   Modales de Posts/Artículos
   ========================================== */
.post-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.85);
    display: flex;
    justify-content: center;
    align-items: flex-start;
    z-index: 10001;
    padding: 20px;
    overflow-y: auto;
    animation: fadeIn 0.3s ease;
}

@keyframes fadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

.post-modal-content {
    background: var(--white);
    border-radius: 12px;
    max-width: 900px;
    width: 100%;
    margin: 40px auto;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
    position: relative;
    animation: slideUp 0.3s ease;
}

@keyframes slideUp {
    from {
        transform: translateY(30px);
        opacity: 0;
    }
    to {
        transform: translateY(0);
        opacity: 1;
    }
}

.post-modal-close {
    position: absolute;
    top: 20px;
    right: 20px;
    background: var(--dark);
    color: var(--white);
    border: none;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    font-size: 24px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 10;
    transition: var(--transition);
    line-height: 1;
}

.post-modal-close:hover {
    background: var(--primary-dark);
    transform: rotate(90deg);
}

.post-article {
    padding: 0;
}

.post-header {
    padding: 60px 60px 40px 60px;
    border-bottom: 2px solid var(--gray-light);
}

.post-tag {
    display: inline-block;
    padding: 8px 20px;
    background: var(--primary-color);
    color: var(--dark);
    border-radius: 20px;
    font-size: 0.875rem;
    font-weight: 600;
    margin-bottom: 20px;
}

.post-header h1 {
    font-size: 2.5rem;
    color: var(--dark);
    margin: 0 0 20px 0;
    line-height: 1.2;
}

.post-meta {
    display: flex;
    gap: 20px;
    color: var(--gray);
    font-size: 0.9rem;
}

.post-meta span {
    display: flex;
    align-items: center;
    gap: 6px;
}

.post-image {
    width: 100%;
    height: 400px;
    overflow: hidden;
    margin: 0;
}

.post-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.post-body {
    padding: 40px 60px 60px 60px;
    line-height: 1.8;
    color: var(--gray-dark);
}

.post-body h2 {
    font-size: 1.75rem;
    color: var(--dark);
    margin: 40px 0 20px 0;
    padding-top: 20px;
    border-top: 1px solid var(--gray-light);
}

.post-body h2:first-of-type {
    margin-top: 0;
    padding-top: 0;
    border-top: none;
}

.post-body h3 {
    font-size: 1.25rem;
    color: var(--dark);
    margin: 30px 0 15px 0;
}

.post-body p {
    margin-bottom: 20px;
    font-size: 1.0625rem;
}

.post-body ul {
    margin: 20px 0;
    padding-left: 30px;
}

.post-body ul li {
    margin-bottom: 12px;
    line-height: 1.8;
}

.post-body strong {
    color: var(--dark);
    font-weight: 600;
}

.post-footer {
    background: var(--gray-light);
    padding: 30px;
    border-radius: 8px;
    margin-top: 40px;
    border-left: 4px solid var(--primary-color);
}

.post-footer p {
    margin: 0;
    font-size: 1rem;
}

/* Responsive para modales de posts */
@media (max-width: 768px) {
    .post-modal {
        padding: 10px;
    }

    .post-modal-content {
        margin: 20px auto;
        border-radius: 8px;
    }

    .post-header {
        padding: 40px 30px 30px 30px;
    }

    .post-header h1 {
        font-size: 1.75rem;
    }

    .post-meta {
        flex-direction: column;
        gap: 10px;
    }

    .post-image {
        height: 250px;
    }

    .post-body {
        padding: 30px 30px 40px 30px;
    }

    .post-body h2 {
        font-size: 1.5rem;
    }

    .post-body h3 {
        font-size: 1.125rem;
    }

    .post-modal-close {
        top: 10px;
        right: 10px;
        width: 35px;
        height: 35px;
        font-size: 20px;
    }
}

