/**
 * Latido y Raqueta - Custom Styles
 * Theme: Latido y Raqueta
 * Version: 1.0.0
 */

/* === GLOBAL RESET === */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    overflow-x: hidden;
    margin: 0;
    padding: 0;
}

/* Aplicar Roboto a todos los elementos */
body, p, div, span, a, li, td, th, label, input, textarea, select, button {
    font-family: 'Roboto', sans-serif !important;
}

/* Ajuste específico para la página home */
.home-page-content {
    padding-top: 0 !important;
}

.home-page-content .wp-block-post-content {
    padding-top: 0;
}

/* === CSS VARIABLES (Fallback for older browsers) === */
:root {
    --azul-oscuro: #0a2540;
    --azul-medio: #1e4a6f;
    --azul-claro: #5da3d8;
    --azul-muy-claro: #a8d5f5;
    --rojo-corazon: #c73542;
    --dorado: #d4af37;
    --beige: #f5f1e8;
    --blanco: #ffffff;
}

/* === ANIMATIONS === */
@keyframes heartbeat {
    0%, 100% { transform: scale(1); }
    10% { transform: scale(1.1); }
    20% { transform: scale(1); }
    30% { transform: scale(1.15); }
    40% { transform: scale(1); }
}

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

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

@keyframes float {
    0%, 100% { transform: translateY(0px); }
    50% { transform: translateY(-20px); }
}

/* === NAVIGATION === */
.site-header {
    position: fixed;
    top: 0;
    width: 100%;
    background: rgba(10, 37, 64, 0.95);
    backdrop-filter: blur(10px);
    z-index: 1000;
    padding: 1.2rem 5%;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.1);
}

.site-header .wp-block-navigation {
    max-width: 1400px;
    margin: 0 auto;
}

.site-header a {
    color: var(--blanco);
    font-weight: 500;
    position: relative;
}

.site-header a::after {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--dorado);
    transition: width 0.3s;
}

.site-header a:hover::after {
    width: 100%;
}

.site-header a:hover {
    color: var(--dorado);
}

/* Heart icon animation */
.heart-icon {
    color: var(--rojo-corazon);
    animation: heartbeat 2s infinite;
}

/* === HERO SECTION === */
.hero-section {
    min-height: 100vh;
    background: linear-gradient(135deg, var(--azul-oscuro) 0%, var(--azul-medio) 50%, var(--azul-claro) 100%);
    display: flex;
    align-items: center;
    padding: 120px 5% 60px;
    position: relative;
    overflow: hidden;
}

.hero-section::before {
    content: '';
    position: absolute;
    width: 600px;
    height: 600px;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(212, 175, 55, 0.15) 0%, transparent 70%);
    top: -200px;
    right: -200px;
    animation: float 6s ease-in-out infinite;
}

.hero-section::after {
    content: '';
    position: absolute;
    width: 400px;
    height: 400px;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(199, 53, 66, 0.15) 0%, transparent 70%);
    bottom: -100px;
    left: -100px;
    animation: float 8s ease-in-out infinite;
}

/* === STATS SECTION === */
.stats-section {
    background: var(--azul-oscuro);
    padding: 4rem 5%;
    color: var(--blanco);
}

.stat-number {
    font-family: 'Playfair Display', serif;
    font-size: 3.5rem;
    color: var(--dorado);
    margin-bottom: 0.5rem;
}

.stat-label {
    font-size: 1.1rem;
    color: var(--azul-muy-claro);
}

/* === SECTION STYLING === */
.section-label {
    color: var(--rojo-corazon);
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 2px;
    font-size: 0.9rem;
    margin-bottom: 1rem;
    display: block;
}

/* === CARDS === */
.via-card,
.evidencia-card,
.impacto-card,
.ubicacion-card {
    transition: transform 0.3s, box-shadow 0.3s;
}

.via-card:hover,
.evidencia-card:hover,
.impacto-card:hover,
.ubicacion-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.12);
}

.via-card {
    background: var(--blanco);
    border-radius: 20px;
    padding: 3rem;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.08);
    position: relative;
    overflow: hidden;
}

.via-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 5px;
    background: linear-gradient(90deg, var(--azul-claro), var(--rojo-corazon));
}

/* === HIGHLIGHT BOX === */
.highlight-box {
    background: linear-gradient(135deg, var(--azul-claro), var(--azul-medio));
    color: var(--blanco);
    padding: 2.5rem;
    border-radius: 20px;
    box-shadow: 0 10px 40px rgba(30, 74, 111, 0.2);
}

.highlight-box h4 {
    font-family: 'Playfair Display', serif;
    font-size: 1.8rem;
    margin-bottom: 1rem;
}

.highlight-box ul {
    list-style: none;
    padding: 0;
}

.highlight-box li {
    padding: 0.8rem 0;
    padding-left: 2rem;
    position: relative;
}

.highlight-box li::before {
    content: '✓';
    position: absolute;
    left: 0;
    color: var(--dorado);
    font-weight: bold;
    font-size: 1.3rem;
}

/* === EVIDENCIA SECTION === */
.evidencia-section {
    background: var(--azul-oscuro);
    color: var(--blanco);
}

.evidencia-card {
    background: rgba(255, 255, 255, 0.05);
    backdrop-filter: blur(10px);
    border-radius: 15px;
    padding: 2.5rem;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.evidencia-number {
    font-family: 'Playfair Display', serif;
    font-size: 3rem;
    color: var(--dorado);
    font-weight: bold;
    margin-bottom: 1rem;
}

/* === IMPACTO SECTION === */
.impacto-item {
    background: linear-gradient(135deg, var(--beige), var(--blanco));
    padding: 2.5rem;
    border-radius: 20px;
    border-left: 5px solid var(--rojo-corazon);
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.05);
}

.impacto-icon {
    color: var(--rojo-corazon);
    font-size: 2rem;
}

/* === MI HISTORIA SECTION === */
.mi-historia-section {
    background: linear-gradient(135deg, var(--azul-medio), var(--azul-oscuro));
    color: var(--blanco);
}

.historia-foto {
    width: 300px;
    height: 300px;
    border-radius: 20px;
    background: var(--beige);
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
    border: 5px solid rgba(255, 255, 255, 0.1);
    object-fit: cover;
}

.historia-destacado {
    background: rgba(212, 175, 55, 0.15);
    padding: 2rem;
    border-radius: 15px;
    border-left: 4px solid var(--dorado);
    margin-top: 2rem;
}

.historia-destacado p {
    font-style: italic;
    color: var(--blanco);
    font-size: 1.2rem;
}

/* === UBICACIONES === */
.ubicacion-numero {
    width: 60px;
    height: 60px;
    background: linear-gradient(135deg, var(--azul-claro), var(--azul-medio));
    color: var(--blanco);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-family: 'Playfair Display', serif;
    font-size: 1.5rem;
    font-weight: bold;
    margin: 0 auto 1.5rem;
}

/* === CONTACTO/CTA === */
.contacto-section {
    background: linear-gradient(135deg, var(--rojo-corazon), #a02832);
    color: var(--blanco);
    text-align: center;
    padding: 6rem 5%;
}

/* === FOOTER === */
.site-footer {
    background: var(--azul-oscuro);
    color: var(--blanco);
    padding: 4rem 5% 2rem;
}

.footer-section h4 {
    font-family: 'Playfair Display', serif;
    font-size: 1.5rem;
    margin-bottom: 1.5rem;
    color: var(--dorado);
}

.footer-section a {
    color: var(--azul-muy-claro);
    text-decoration: none;
    transition: color 0.3s;
}

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

.social-links a {
    width: 40px;
    height: 40px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 50%;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    margin: 0 0.5rem;
    transition: all 0.3s;
}

.social-links a:hover {
    background: var(--dorado);
    transform: translateY(-3px);
}

/* === RESPONSIVE === */

/* Tablets y pantallas medianas */
@media (max-width: 1024px) {
    body {
        padding-top: 70px;
    }

    .site-header {
        padding: 1rem 3%;
    }

    .hero-section {
        padding: 100px 3% 50px;
    }

    .via-card,
    .impacto-item,
    .evidencia-card {
        padding: 2rem;
    }
}

/* Móviles y pantallas pequeñas */
@media (max-width: 768px) {
    body {
        padding-top: 65px;
        font-size: 16px;
    }

    .site-header {
        padding: 0.8rem 4%;
    }

    .hero-section {
        min-height: 70vh;
        padding: 80px 4% 40px;
    }

    .stat-number {
        font-size: 2.5rem;
    }

    .stat-label {
        font-size: 0.95rem;
    }

    .via-card,
    .impacto-item,
    .evidencia-card {
        margin-bottom: 1.5rem;
        padding: 1.8rem;
    }

    .highlight-box {
        padding: 2rem;
    }

    .evidencia-number {
        font-size: 2.5rem;
    }

    /* Mejorar legibilidad de textos en móvil */
    h1 {
        font-size: 2rem !important;
        line-height: 1.2 !important;
    }

    h2 {
        font-size: 1.75rem !important;
        line-height: 1.3 !important;
    }

    h3 {
        font-size: 1.4rem !important;
        line-height: 1.3 !important;
    }

    h4 {
        font-size: 1.2rem !important;
        line-height: 1.4 !important;
    }

    p {
        font-size: 1rem !important;
        line-height: 1.6 !important;
        margin-bottom: 1rem !important;
    }

    /* Espaciado para listas */
    ul, ol {
        padding-left: 1.5rem !important;
        margin-bottom: 1.5rem !important;
    }

    li {
        margin-bottom: 0.5rem !important;
        line-height: 1.6 !important;
    }

    /* Botones más grandes y táctiles en móvil */
    .wp-block-button__link,
    .wp-element-button {
        padding: 1rem 2rem !important;
        font-size: 1.1rem !important;
        min-height: 48px;
        display: inline-flex;
        align-items: center;
        justify-content: center;
    }

    /* Columnas apiladas en móvil */
    .wp-block-columns {
        flex-direction: column !important;
    }

    .wp-block-column {
        flex-basis: 100% !important;
        margin-bottom: 1.5rem;
    }

    /* Tablas responsive */
    table {
        display: block;
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
        font-size: 0.9rem;
    }

    /* Separadores con más espacio */
    .wp-block-separator {
        margin: 2rem 0 !important;
    }

    /* Contacto cards más compactas */
    .contact-profile {
        margin-bottom: 2rem;
    }

    /* Historia foto más pequeña en móvil */
    .historia-foto {
        width: 100%;
        max-width: 250px;
        height: auto;
    }

    /* Footer más compacto */
    .site-footer {
        padding: 3rem 4% 1.5rem;
    }

    .footer-section h4 {
        font-size: 1.3rem;
    }
}

/* Móviles muy pequeños */
@media (max-width: 480px) {
    body {
        padding-top: 60px;
    }

    .site-header {
        padding: 0.7rem 3%;
    }

    h1 {
        font-size: 1.75rem !important;
    }

    h2 {
        font-size: 1.5rem !important;
    }

    h3 {
        font-size: 1.25rem !important;
    }

    .via-card,
    .impacto-item,
    .evidencia-card,
    .highlight-box {
        padding: 1.5rem;
    }

    .stat-number {
        font-size: 2rem;
    }

    .evidencia-number {
        font-size: 2rem;
    }

    /* Botones a ancho completo en pantallas muy pequeñas */
    .wp-block-buttons {
        flex-direction: column !important;
        align-items: stretch !important;
    }

    .wp-block-button {
        margin: 0.5rem 0 !important;
        width: 100%;
    }

    .wp-block-button__link {
        width: 100%;
    }
}

/* Mejoras de accesibilidad táctil */
@media (hover: none) and (pointer: coarse) {
    /* Asegurar que enlaces y botones sean fáciles de tocar */
    a, button, .wp-block-button__link {
        min-height: 44px;
        min-width: 44px;
        display: inline-flex;
        align-items: center;
        justify-content: center;
    }

    /* Aumentar área táctil de navegación */
    .site-header .wp-block-navigation__container a {
        padding: 0.8rem 1rem;
    }
}

/* === SCROLL ANIMATIONS === */
.animate-on-scroll {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.6s ease-out, transform 0.6s ease-out;
}

.animate-on-scroll.animated {
    opacity: 1;
    transform: translateY(0);
}

/* === CONTACT FORM STYLES === */
.contact-form-wrapper {
    max-width: 900px;
    margin: 0 auto;
    background: var(--blanco);
    padding: 3rem;
    border-radius: 20px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.08);
}

.form-intro {
    margin-bottom: 2.5rem;
    text-align: center;
}

.intro-text {
    font-size: 1.1rem;
    color: var(--azul-medio);
    line-height: 1.7;
}

.form-row {
    margin-bottom: 1.8rem;
}

.form-row-double {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1.5rem;
}

.form-field {
    position: relative;
}

.form-field label {
    display: block;
    margin-bottom: 0.5rem;
    color: var(--azul-oscuro);
    font-weight: 500;
    font-size: 0.95rem;
}

.form-control {
    width: 100%;
    padding: 0.9rem 1.2rem;
    border: 2px solid #e0e0e0;
    border-radius: 10px;
    font-size: 1rem;
    transition: all 0.3s ease;
    background-color: var(--beige);
    color: var(--azul-oscuro);
}

.form-control:focus {
    outline: none;
    border-color: var(--azul-claro);
    background-color: var(--blanco);
    box-shadow: 0 0 0 3px rgba(93, 163, 216, 0.1);
}

.form-control::placeholder {
    color: #999;
}

textarea.form-control {
    resize: vertical;
    min-height: 150px;
}

.checkbox-field {
    display: flex;
    align-items: flex-start;
    gap: 0.8rem;
}

.checkbox-field .wpcf7-list-item {
    margin: 0;
}

.checkbox-field input[type="checkbox"] {
    margin-top: 3px;
    margin-right: 0.5rem;
    width: 18px;
    height: 18px;
    cursor: pointer;
}

.checkbox-field span {
    font-size: 0.9rem;
    color: var(--azul-medio);
    line-height: 1.5;
}

.checkbox-field a {
    color: var(--azul-claro);
    text-decoration: underline;
    transition: color 0.3s;
}

.checkbox-field a:hover {
    color: var(--rojo-corazon);
}

.form-submit-row {
    text-align: center;
    margin-top: 2.5rem;
}

.submit-button {
    background: linear-gradient(135deg, var(--rojo-corazon), #a02832);
    color: var(--blanco);
    padding: 1rem 3rem;
    font-size: 1.1rem;
    font-weight: 600;
    border: none;
    border-radius: 50px;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 5px 20px rgba(199, 53, 66, 0.3);
}

.submit-button:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 30px rgba(199, 53, 66, 0.4);
    background: linear-gradient(135deg, #a02832, var(--rojo-corazon));
}

.submit-button:active {
    transform: translateY(-1px);
}

/* Fix Contact Form 7 wrapping */
.contact-form-wrapper .wpcf7-form p {
    margin: 0 !important;
}

.contact-form-wrapper br {
    display: none !important;
}

.contact-form-wrapper .wpcf7-form-control-wrap {
    display: block;
    width: 100%;
}

/* Contact Form 7 validation messages */
.wpcf7-not-valid-tip {
    color: #d32f2f;
    font-size: 0.85rem;
    margin-top: 0.3rem;
    display: block;
}

.wpcf7-form-control.wpcf7-not-valid {
    border-color: #d32f2f !important;
    background-color: #ffebee;
}

.wpcf7-response-output {
    margin: 1.5rem 0 0;
    padding: 1rem 1.5rem;
    border-radius: 10px;
    font-weight: 500;
}

.wpcf7-mail-sent-ok {
    background-color: #d4edda;
    border: 2px solid #28a745;
    color: #155724;
}

.wpcf7-validation-errors,
.wpcf7-mail-sent-ng {
    background-color: #f8d7da;
    border: 2px solid #dc3545;
    color: #721c24;
}

/* Loading spinner */
.wpcf7-spinner {
    margin-left: 1rem;
    vertical-align: middle;
}

/* Responsive Contact Form */
@media (max-width: 768px) {
    .contact-form-wrapper {
        padding: 2rem 1.5rem;
        border-radius: 15px;
    }

    .form-row-double {
        grid-template-columns: 1fr;
        gap: 1.2rem;
    }

    .form-control {
        padding: 0.8rem 1rem;
    }

    .submit-button {
        width: 100%;
        padding: 1.1rem 2rem;
    }

    .intro-text {
        font-size: 1rem;
    }
}

@media (max-width: 480px) {
    .contact-form-wrapper {
        padding: 1.5rem 1rem;
    }

    .form-field label {
        font-size: 0.9rem;
    }

    .form-control {
        font-size: 0.95rem;
    }
}

/* === HOMEPAGE IMPROVEMENTS === */

/* Hero Section Enhancements */
.hero-section-home {
    position: relative;
    overflow: hidden;
}

.hero-section-home .wp-block-cover__background {
    animation: gradientShift 15s ease infinite;
}

@keyframes gradientShift {
    0%, 100% { opacity: 0.4; }
    50% { opacity: 0.6; }
}

.hero-cta-button .wp-block-button__link {
    transform: scale(1);
    transition: all 0.3s ease;
}

.hero-cta-button .wp-block-button__link:hover {
    transform: scale(1.05);
    box-shadow: 0 10px 30px rgba(212, 175, 55, 0.4);
}

.hero-image-placeholder {
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
    padding: 2rem;
    border-radius: 20px;
    border: 3px dashed rgba(255, 255, 255, 0.3);
    min-height: 400px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
}

.hero-image-placeholder:hover {
    border-color: var(--dorado);
    background: rgba(212, 175, 55, 0.1);
}

.hero-image-placeholder img {
    object-fit: cover;
    width: 100%;
    height: 100%;
}

/* Via Cards Hover Effects */
.via-card {
    transition: all 0.3s ease;
    cursor: pointer;
}

.via-card:hover {
    transform: translateY(-10px) scale(1.02);
}

/* Stats Section Animation */
.stat-item {
    text-align: center;
    transition: transform 0.3s ease;
}

.stat-item:hover {
    transform: scale(1.1);
}

.stat-number {
    font-family: 'Playfair Display', serif;
    font-weight: 900;
    line-height: 1;
    margin-bottom: 1rem;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.3);
}

/* Benefits List Styling */
.benefits-list li {
    padding: 1rem 0;
    border-bottom: 1px solid rgba(30, 74, 111, 0.1);
    transition: all 0.3s ease;
}

.benefits-list li:hover {
    padding-left: 1rem;
    background: rgba(93, 163, 216, 0.05);
    border-left: 4px solid var(--azul-claro);
}

.benefits-list li:last-child {
    border-bottom: none;
}

/* CTA Section Styling */
.cta-section-home {
    text-align: center;
    position: relative;
    overflow: hidden;
}

.cta-section-home::before {
    content: '♥';
    position: absolute;
    font-size: 20rem;
    color: rgba(255, 255, 255, 0.05);
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    animation: heartbeat 2s infinite;
    pointer-events: none;
}

/* Section Label Styling */
.section-label {
    display: inline-block;
    padding: 0.5rem 1.5rem;
    background: rgba(199, 53, 66, 0.1);
    border-radius: 50px;
    font-size: 0.9rem;
}

/* Responsive Improvements for Homepage */
@media (max-width: 768px) {
    .hero-section-home {
        min-height: 80vh !important;
    }

    .hero-image-placeholder {
        min-height: 250px;
        margin-top: 2rem;
    }

    .stat-number {
        font-size: 3rem !important;
    }

    .via-card {
        margin-bottom: 2rem;
    }
}

@media (max-width: 480px) {
    .hero-section-home {
        min-height: 70vh !important;
    }

    .stat-number {
        font-size: 2.5rem !important;
    }

    .benefits-list li {
        font-size: 1rem;
        padding: 0.8rem 0;
    }
}

/* Hero Content Box Styling */
.hero-content-box {
    border-radius: 20px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.4);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.hero-section-home .wp-block-cover__image-background {
    object-position: center right;
}

@media (max-width: 768px) {
    .hero-content-box {
        padding: 2rem 1.5rem !important;
    }

    .hero-section-home .wp-block-cover__image-background {
        object-position: center center;
    }
}
