/* CSS Variables & Design Tokens */
:root {
    --color-teal: #1A6384;      /* Primario */
    --color-navy: #223F54;      /* Primario Oscuro */
    --color-brown: #7C5942;     /* Primario Café */
    --color-tan: #D9AF8B;       /* Secundario Arena */
    --color-grey-light: #DDDDE1; /* Secundario Gris */
    
    /* Mapping existing tokens to new official colors */
    --color-navy-dark: var(--color-navy);
    --color-tan-light: var(--color-tan);
    --color-slate: var(--color-teal);
    --color-bg: #F9F6F0; 
    --color-white: #ffffff;
    --color-text: #223F54;
    --color-text-light: #7C5942;

    --font-sans: 'Roboto', sans-serif;
    --font-serif: 'Playfair Display', serif;

    --transition: 0.3s cubic-bezier(0.25, 0.46, 0.45, 0.94);
    --shadow-sm: 0 4px 6px rgba(15, 44, 65, 0.05);
    --shadow-md: 0 10px 20px rgba(15, 44, 65, 0.08);
    --shadow-lg: 0 25px 40px rgba(15, 44, 65, 0.12);

    --border-radius: 12px;
}

/* Reset & Global */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

p {
    text-align: justify;
    text-justify: inter-word;
}

html {
    scroll-behavior: auto;
}

body {
    font-family: var(--font-sans);
    color: var(--color-text);
    background-color: var(--color-bg);
    line-height: 1.6;
    overflow-x: hidden;
    opacity: 1;
    transition: opacity 0.18s cubic-bezier(0.25, 1, 0.5, 1);
}

body.fade-out-active {
    opacity: 0;
}

h1, h2, h3, h4, .logo-text h1, .logo-text h2 {
    font-family: var(--font-serif);
    color: var(--color-navy);
}

a {
    text-decoration: none;
    color: inherit;
}

li {
    list-style: none;
}

img {
    max-width: 100%;
    display: block;
}

/* Typography Utility */
.text-center { text-align: center; }
.section-tag {
    display: inline-block;
    font-size: 0.85rem;
    text-transform: uppercase;
    letter-spacing: 2px;
    font-weight: 600;
    color: var(--color-tan);
    margin-bottom: 1rem;
}
.section-title {
    font-size: 2.5rem;
    margin-bottom: 3rem;
    position: relative;
    display: inline-block;
}
.section-title::after {
    content: '';
    position: absolute;
    bottom: -10px;
    left: 50%;
    transform: translateX(-50%);
    width: 60px;
    height: 3px;
    background-color: var(--color-tan);
}
.container {
    width: 90%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 6rem 0;
}

/* Buttons */
.btn-primary, .btn-secondary {
    display: inline-block;
    padding: 0.8rem 1.8rem;
    border-radius: 30px;
    font-weight: 500;
    transition: var(--transition);
    cursor: pointer;
    font-family: var(--font-sans);
}
.btn-primary {
    background-color: var(--color-navy);
    color: var(--color-white);
    border: 2px solid var(--color-navy);
}
.btn-primary:hover {
    background-color: var(--color-tan);
    border-color: var(--color-tan);
    color: var(--color-navy-dark);
}
.btn-secondary {
    background-color: transparent;
    color: var(--color-white);
    border: 2px solid var(--color-tan);
    animation: pulse-glow 2.2s infinite cubic-bezier(0.25, 1, 0.5, 1);
}
.btn-secondary:hover {
    background-color: var(--color-tan);
    color: var(--color-navy);
    animation: none;
    transform: scale(1.05);
}

@keyframes pulse-glow {
    0% {
        transform: scale(1);
        box-shadow: 0 0 0 0 rgba(217, 175, 139, 0.4);
    }
    70% {
        transform: scale(1.04);
        box-shadow: 0 0 0 14px rgba(217, 175, 139, 0);
    }
    100% {
        transform: scale(1);
        box-shadow: 0 0 0 0 rgba(217, 175, 139, 0);
    }
}

/* Navigation */
.navbar {
    position: fixed;
    top: 0;
    width: 100%;
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    z-index: 1000;
    transition: var(--transition);
    box-shadow: var(--shadow-sm);
}
.nav-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 90%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 1rem 0;
}
.logo {
    display: flex;
    align-items: center;
    gap: 0.8rem;
}
.navbar-logo-img {
    height: 75px; /* Slightly larger height for desktop to catch attention */
    display: block;
    transition: var(--transition);
}
.logo-icon {
    width: 45px;
    height: 45px;
    border: 3px solid var(--color-navy);
    border-radius: 50%;
    display: flex;
    justify-content: center;
    align-items: center;
    position: relative;
}
/* Creating the A with the wave */
.logo-icon::before {
    content: '';
    position: absolute;
    width: 2px;
    height: 20px;
    background: var(--color-navy);
    transform: rotate(25deg);
    left: 14px;
    top: 10px;
}
.logo-icon::after {
    content: '';
    position: absolute;
    width: 2px;
    height: 20px;
    background: var(--color-navy);
    transform: rotate(-25deg);
    right: 14px;
    top: 10px;
}
.logo-wave {
    width: 20px;
    height: 6px;
    border-radius: 10px;
    background: var(--color-tan);
    position: absolute;
    top: 25px;
}

.logo-text h1 {
    font-family: var(--font-sans);
    font-size: 1.4rem;
    font-weight: 700;
    letter-spacing: 2px;
    margin: 0;
    line-height: 1;
}
.logo-text span {
    font-size: 0.6rem;
    letter-spacing: 1.5px;
    color: var(--color-tan);
    font-weight: 500;
}

.nav-menu {
    display: flex;
    align-items: center;
    gap: 2rem;
}
.nav-link {
    font-size: 0.95rem;
    font-weight: 500;
    color: var(--color-text);
    transition: var(--transition);
    position: relative;
}
.nav-link:hover {
    color: var(--color-slate);
}
.nav-link::after {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 0;
    width: 0;
    height: 2px;
    background-color: var(--color-tan);
    transition: var(--transition);
}
.nav-link:hover::after {
    width: 100%;
}

.menu-toggle {
    display: none;
    flex-direction: column;
    gap: 5px;
    cursor: pointer;
}
.bar {
    width: 25px;
    height: 2px;
    background-color: var(--color-navy);
    transition: var(--transition);
}

/* Hero Section */
.hero {
    height: 100vh;
    min-height: 600px;
    background: url('./assets/Arenas/WhatsApp Image 2026-03-31 at 06.57.52.jpeg') center/cover no-repeat;
    position: relative;
    display: flex;
    align-items: center;
}
.hero-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, rgba(15, 44, 65, 0.85) 0%, rgba(46, 107, 142, 0.6) 100%);
}
.hero-content {
    position: relative;
    width: 90%;
    max-width: 1000px;
    margin: 0 auto;
    color: var(--color-white);
    padding-top: 5rem;
    z-index: 2;
}
.sub-heading {
    font-family: var(--font-sans);
    font-size: 1rem;
    letter-spacing: 3px;
    color: var(--color-tan);
    margin-bottom: 1rem;
}
.main-heading {
    font-size: 4.5rem;
    line-height: 1.1;
    margin-bottom: 1.5rem;
    color: var(--color-white);
    font-weight: 500;
}
.accent-text {
    color: var(--color-tan-light);
    font-style: italic;
}
.hero-desc {
    font-size: 1.25rem;
    max-width: 600px;
    margin-bottom: 2.5rem;
    opacity: 0.9;
}

/* About Section Reimagined */
.about {
    background-color: var(--color-white);
    padding: 8rem 0;
}
.about-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    margin-bottom: 4rem;
    align-items: stretch;
}

.about-column {
    background-color: var(--color-white);
    border-radius: var(--border-radius);
    overflow: hidden;
    box-shadow: var(--shadow-md);
    transition: transform 0.4s cubic-bezier(0.25, 1, 0.5, 1), box-shadow 0.4s cubic-bezier(0.25, 1, 0.5, 1), border-color 0.4s ease;
    border: 1px solid rgba(34, 63, 84, 0.05);
    display: flex;
    flex-direction: column;
    cursor: pointer;
}

.about-column:hover {
    transform: translateY(-8px);
    box-shadow: var(--shadow-lg), 0 15px 35px rgba(34, 63, 84, 0.08);
    border-color: rgba(217, 175, 139, 0.25);
}




.column-content-box {
    padding: 3rem;
    flex-grow: 1;
    display: flex;
    flex-direction: column;
}

.column-content-box h2 {
    font-size: 2rem;
    color: var(--color-navy-dark);
    font-family: 'Playfair Display', serif;
    margin-top: 0.5rem;
    margin-bottom: 1.5rem;
    font-weight: 700;
}

.column-content-box p {
    font-size: 1.05rem;
    line-height: 1.8;
    color: var(--color-text);
    margin-bottom: 1.2rem;
    text-align: justify;
}

.signatures {
    margin-top: auto;
    padding-top: 1.5rem;
    border-top: 1px solid var(--color-grey-light);
    text-align: right;
}

.signature-text {
    font-family: 'Playfair Display', serif;
    font-style: italic;
    font-size: 1.35rem;
    color: var(--color-tan);
    margin: 0;
    text-align: right;
}

.highlight-quote {
    font-weight: 600;
    color: var(--color-navy);
    border-left: 4px solid var(--color-tan);
    padding-left: 1.5rem;
    margin-top: auto;
    padding-top: 0.5rem;
    padding-bottom: 0.5rem;
    font-style: italic;
    line-height: 1.6;
    text-align: left;
}

.vision-mission-row {
    display: flex;
    gap: 3rem;
    margin-top: 2rem;
}

.vm-item {
    flex: 1;
    background-color: var(--color-navy);
    color: var(--color-white);
    padding: 2.5rem 3rem;
    border-radius: var(--border-radius);
    position: relative;
    overflow: hidden;
    box-shadow: var(--shadow-md);
    border: 1px solid rgba(255, 255, 255, 0.08);
    transition: border-color 0.3s ease;
}

.vm-item:hover {
    border-color: rgba(217, 175, 139, 0.3); /* Subtle gold border highlight on hover */
}

.vm-header {
    display: flex;
    align-items: center;
    gap: 1.5rem;
    margin-bottom: 1.8rem;
}

.vm-icon {
    font-size: 2.2rem;
    background: rgba(255, 255, 255, 0.1);
    width: 60px;
    height: 60px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    color: var(--color-tan);
}

.vm-icon .material-symbols-outlined {
    font-size: 1.8rem;
}

.vm-item h3 {
    color: var(--color-tan);
    font-size: 1.8rem;
    margin: 0;
    font-family: 'Playfair Display', serif;
}

.vm-body {
    display: flex;
    flex-direction: column;
    gap: 1.2rem;
    text-align: justify;
}

.vm-intro {
    font-size: 1.1rem;
    line-height: 1.7;
    font-weight: 500;
    color: var(--color-white);
    margin: 0;
}

.vm-detail {
    font-size: 0.98rem;
    line-height: 1.7;
    color: var(--color-grey-light);
    font-weight: 300;
    margin: 0;
}

@media (max-width: 992px) {
    .about-grid {
        grid-template-columns: 1fr;
        gap: 3rem;
    }
    .history-media-panel {
        height: 380px; /* Reduced height on tablet/mobile for better balance */
    }
    .vision-mission-row {
        flex-direction: column;
    }
}

/* Values Section Reimagined */
.values {
    background-color: var(--color-white);
    padding: 8rem 0;
}

.values-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1.8rem;
    margin-top: 3.5rem;
}

.value-card {
    padding: 3.5rem 2rem;
    text-align: center;
    color: var(--color-white);
    border-radius: var(--border-radius);
    box-shadow: 0 8px 24px rgba(34, 63, 84, 0.08);
    transition: transform 0.4s cubic-bezier(0.25, 1, 0.5, 1), box-shadow 0.4s cubic-bezier(0.25, 1, 0.5, 1), border-color 0.4s ease;
    border: 1px solid rgba(255, 255, 255, 0.08);
    cursor: pointer;
    position: relative;
    overflow: hidden;
}

.value-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 15px 35px rgba(34, 63, 84, 0.18);
    border-color: rgba(255, 255, 255, 0.25);
}

.value-icon {
    margin-bottom: 1.5rem;
    display: flex;
    justify-content: center;
    align-items: center;
    transition: transform 0.4s cubic-bezier(0.25, 1, 0.5, 1);
}

.value-card:hover .value-icon {
    transform: scale(1.1);
}

.value-icon .material-symbols-outlined {
    font-size: 4rem;
    color: rgba(255, 255, 255, 0.95);
    font-weight: 200;
}

.value-card h3 {
    font-size: 1.45rem;
    font-family: 'Playfair Display', serif;
    color: var(--color-white);
    margin-bottom: 0;
}

/* Specific Colors from the Logo Book/Image */
.v-etica { background-color: var(--color-navy); } /* Dark Navy */
.v-empatia { background-color: var(--color-teal); } /* Teal */
.v-lealtad { background-color: #1a2c3a; } /* Deep Dark Navy */
.v-autocuidado { background-color: var(--color-brown); } /* Brown */
.v-compromiso { 
    background-color: var(--color-tan); 
    color: var(--color-navy) !important;
} /* Sand Tan */
.v-compromiso h3, .v-compromiso .value-icon .material-symbols-outlined {
    color: var(--color-navy) !important;
}
.v-perseverancia { background-color: #634735; } /* Variation of Brown */

@media (max-width: 992px) {
    .values-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 1.5rem;
    }
}

@media (max-width: 600px) {
    .values-grid {
        grid-template-columns: 1fr;
        gap: 1.2rem;
    }
}


/* Founders Section */
.founders {
    background-color: var(--color-bg);
}
.founders-heading {
    text-align: center;
    max-width: 700px;
    margin: 0 auto 4rem;
}
.founders-heading .section-tag {
    display: block;
    text-align: center;
    margin: 0 auto 1rem;
}
.founders-heading .section-title {
    display: block;
    text-align: center;
    margin: 0 auto 2.5rem;
}
.founders-heading .section-subtitle,
.section-subtitle {
    color: var(--color-teal);
    font-size: 1.1rem;
    text-align: center !important;
    text-align-last: center !important;
    margin: 0 auto;
}
.founders-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 3rem;
    margin-bottom: 4rem;
}

/* Specialty Team Groups */
.specialty-teams {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 3rem;
    margin-top: 0;
}

.specialty-group {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.specialty-group-label {
    display: flex;
    align-items: center;
    gap: 0.85rem;
    padding-bottom: 0.85rem;
    border-bottom: 2px solid var(--color-tan);
}

.specialty-group-label span {
    font-family: var(--font-serif);
    font-size: 1.15rem;
    font-weight: 600;
    color: var(--color-navy);
    letter-spacing: 0.02em;
}

.specialty-group-icon {
    width: 36px;
    height: 36px;
    object-fit: contain;
    border-radius: 50%;
    border: 2px solid var(--color-tan);
    padding: 3px;
    background: var(--color-white);
}

.specialty-team-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1.5rem;
}

.founder-card {
    background: var(--color-white);
    border-radius: var(--border-radius);
    overflow: hidden;
    box-shadow: var(--shadow-sm);
    transition: var(--transition);
}
.founder-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-lg);
}
.founder-img-wrapper {
    width: 100%;
    height: 350px;
    background: linear-gradient(135deg, var(--color-slate) 0%, var(--color-navy) 100%);
    position: relative;
    overflow: hidden;
    display: flex;
    justify-content: center;
    align-items: center;
}

.column-image-wrapper {
    position: relative;
    width: 100%;
    height: 320px;
    overflow: hidden;
}

.column-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.8s cubic-bezier(0.25, 1, 0.5, 1);
}

.about-column:hover .column-img {
    transform: scale(1.05);
}

/* Wave Animation Overlay for Sand Image */
.wave-overlay {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    overflow: hidden;
    z-index: 2;
}

.wave-wash-wrapper {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 185px; /* Controls how high the wave surges up the sand */
    will-change: transform, opacity;
}

.wave-svg {
    position: absolute;
    bottom: -15px; /* Cover bottom edge */
    left: 0;
    width: 200%; /* Make it twice as wide so it can slide horizontally */
    height: 100%;
    display: block;
}

/* Specific properties for each wave layer */
.wave-wet-sand {
    fill: rgba(25, 18, 12, 0.48); /* Rich wet sand darkening */
    mix-blend-mode: multiply; /* Darkens the underlying sand texture realistically */
    filter: blur(3px); /* Soft wet edge in the sand */
}

.wave-water {
    /* Uses SVG oceanGradient defined in HTML defs */
    mix-blend-mode: normal;
    filter: blur(1px) drop-shadow(0 -3px 8px rgba(255, 255, 255, 0.35));
}

.wave-foam {
    /* Uses crisp white fill defined in HTML */
    mix-blend-mode: normal;
    filter: blur(0.6px) drop-shadow(0 2px 6px rgba(255, 255, 255, 0.7));
}

.wave-foam-trail {
    /* Uses foamGradient defined in HTML */
    mix-blend-mode: screen;
    filter: blur(2px);
}

/* Animations */
/* 1. Horizontal sliding ripple */
@keyframes wave-ripple-left {
    0% { transform: translateX(0); }
    100% { transform: translateX(-50%); }
}

@keyframes wave-ripple-right {
    0% { transform: translateX(-50%); }
    100% { transform: translateX(0); }
}

.wave-wet-sand {
    animation: wave-ripple-left 18s linear infinite;
}

.wave-water {
    animation: wave-ripple-right 13s linear infinite;
}

.wave-foam {
    animation: wave-ripple-left 10s linear infinite;
}

.wave-foam-trail {
    animation: wave-ripple-right 12s linear infinite;
}

/* 2. Vertical washing (Up and Down) */
@keyframes wave-wash-wet-cycle {
    0%, 8% {
        transform: translateY(88%);
        opacity: 0.25;
    }
    32% {
        transform: translateY(8%); /* Surges high up the sand */
        opacity: 0.95;
    }
    44%, 54% {
        transform: translateY(11%);
        opacity: 0.9;
    }
    82% {
        transform: translateY(55%); /* Wet sand lingers while water recedes */
        opacity: 0.55;
    }
    100% {
        transform: translateY(88%);
        opacity: 0.25;
    }
}

@keyframes wave-wash-water-cycle {
    0%, 10% {
        transform: translateY(86%);
        opacity: 0.4;
    }
    33% {
        transform: translateY(10%); /* Surges high and visibly over the bottom third */
        opacity: 0.96;
    }
    43%, 50% {
        transform: translateY(14%);
        opacity: 0.92;
    }
    78%, 100% {
        transform: translateY(86%);
        opacity: 0.4;
    }
}

@keyframes wave-wash-foam-cycle {
    0%, 10% {
        transform: translateY(84%);
        opacity: 0.35;
    }
    32% {
        transform: translateY(8%); /* Foam crest leads the wave surge */
        opacity: 1;
    }
    42%, 50% {
        transform: translateY(12%);
        opacity: 0.95;
    }
    76%, 100% {
        transform: translateY(84%);
        opacity: 0.35;
    }
}

@keyframes wave-wash-foam-trail-cycle {
    0%, 12% {
        transform: translateY(86%);
        opacity: 0.2;
    }
    34% {
        transform: translateY(11%); /* Aerated foam trail right behind main crest */
        opacity: 0.9;
    }
    44%, 52% {
        transform: translateY(15%);
        opacity: 0.85;
    }
    78%, 100% {
        transform: translateY(86%);
        opacity: 0.2;
    }
}

.wave-wash-wet {
    animation: wave-wash-wet-cycle 8.5s cubic-bezier(0.35, 0, 0.25, 1) infinite;
}

.wave-wash-water {
    animation: wave-wash-water-cycle 8.5s cubic-bezier(0.35, 0, 0.25, 1) infinite;
}

.wave-wash-foam {
    animation: wave-wash-foam-cycle 8.5s cubic-bezier(0.35, 0, 0.25, 1) infinite;
}

.wave-wash-foam-trail {
    animation: wave-wash-foam-trail-cycle 8.5s cubic-bezier(0.35, 0, 0.25, 1) infinite;
}

.founder-placeholder {
    font-size: 5rem;
    color: rgba(255, 255, 255, 0.2);
    font-family: var(--font-serif);
}
.founder-info {
    padding: 2rem;
    text-align: center;
}
.founder-badge {
    display: inline-block;
    font-size: 0.72rem;
    font-weight: 700;
    color: var(--color-tan);
    text-transform: uppercase;
    letter-spacing: 1.5px;
    margin-bottom: 0.5rem;
}
.founder-info h3 {
    font-size: 1.5rem;
    margin-bottom: 0.2rem;
}
.founder-info .role {
    color: var(--color-tan);
    font-size: 0.85rem;
    text-transform: uppercase;
    letter-spacing: 1px;
    font-weight: 600;
    margin-bottom: 1rem;
}
.founder-info .bio {
    color: var(--color-text-light);
    font-size: 0.9rem;
}

.collaborators {
    text-align: center;
    background: var(--color-white);
    padding: 1.5rem;
    border-radius: var(--border-radius);
    border: 1px dashed var(--color-tan);
    color: var(--color-navy);
}

/* CTA Section */
.cta-contact {
    background: url('./assets/Arenas/contacto-bg.jpg') center/cover no-repeat fixed;
    padding: 10rem 0;
}
@media (max-width: 992px), (hover: none) {
    .cta-contact {
        background-attachment: scroll;
        padding: 6rem 0;
    }
}
.cta-box {
    background: linear-gradient(135deg, rgba(34, 63, 84, 0.82) 0%, rgba(15, 44, 65, 0.85) 100%);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border: 1px solid rgba(217, 175, 139, 0.25);
    border-radius: var(--border-radius);
    padding: 6rem 3rem;
    color: var(--color-white);
    max-width: 800px;
    margin: 0 auto;
    box-shadow: var(--shadow-lg), 0 0 45px rgba(26, 99, 132, 0.25), inset 0 1px 0 rgba(255, 255, 255, 0.12);
    position: relative;
    overflow: hidden;
    transition: transform 0.5s cubic-bezier(0.25, 1, 0.5, 1), box-shadow 0.5s cubic-bezier(0.25, 1, 0.5, 1), border-color 0.5s ease;
}
.cta-box:hover {
    transform: translateY(-6px);
    border-color: rgba(217, 175, 139, 0.5);
    box-shadow: var(--shadow-xl), 0 0 60px rgba(26, 99, 132, 0.35), inset 0 1px 0 rgba(255, 255, 255, 0.22);
}
.cta-box::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle, rgba(200,161,125,0.08) 0%, transparent 60%);
    animation: rotateSlowly 22s linear infinite;
}
@keyframes rotateSlowly {
    100% { transform: rotate(360deg); }
}
.cta-icon {
    width: 90px;
    height: 90px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--color-tan) 0%, #b88d67 100%);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 2rem;
    box-shadow: 0 10px 25px rgba(217, 175, 139, 0.3);
    position: relative;
    z-index: 2;
    transition: transform 0.4s cubic-bezier(0.25, 1, 0.5, 1);
}
.cta-box:hover .cta-icon {
    transform: scale(1.08) rotate(-4deg);
}
.cta-icon .material-symbols-outlined {
    font-size: 3rem;
    color: var(--color-navy);
    font-weight: 400;
}
.cta-box h2 {
    font-family: var(--font-serif);
    font-size: 2.6rem;
    color: var(--color-white);
    margin-bottom: 1.2rem;
    position: relative;
    z-index: 2;
    letter-spacing: 0.5px;
}
.cta-box p {
    font-size: 1.15rem;
    margin-bottom: 2.8rem;
    color: #e5edf5;
    position: relative;
    z-index: 2;
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
}
.btn-cta {
    display: inline-block;
    padding: 1.1rem 3rem;
    background: linear-gradient(135deg, var(--color-tan) 0%, #c4966e 100%);
    color: var(--color-navy-dark);
    font-weight: 700;
    border-radius: 40px;
    font-size: 1.05rem;
    text-transform: uppercase;
    letter-spacing: 1px;
    transition: all 0.4s cubic-bezier(0.25, 1, 0.5, 1);
    position: relative;
    z-index: 2;
    border: none;
    box-shadow: 0 8px 25px rgba(217, 175, 139, 0.35);
    animation: pulse-glow 2.2s infinite cubic-bezier(0.25, 1, 0.5, 1);
}
.btn-cta:hover {
    background: var(--color-white);
    color: var(--color-navy);
    transform: translateY(-4px) scale(1.03);
    box-shadow: 0 12px 30px rgba(255, 255, 255, 0.25);
    animation: none;
}

/* Services - Reimagined */
.services {
    background-color: var(--color-navy);
    padding: 10rem 0;
    position: relative;
    overflow: hidden;
}

.services::after {
    content: '';
    position: absolute;
    bottom: -150px;
    right: -150px;
    width: 400px;
    height: 400px;
    background: radial-gradient(circle, rgba(200, 161, 125, 0.05) 0%, transparent 70%);
    z-index: 1;
}

.services-header {
    margin-bottom: 5rem;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
}

.specialties-main-title {
    font-family: var(--font-serif);
    font-size: 3.8rem;
    color: var(--color-tan);
    letter-spacing: 2px;
    margin-bottom: 0.1rem;
    text-shadow: 0 4px 10px rgba(0,0,0,0.1);
}

.title-accent-line {
    width: 80px;
    height: 3px;
    background-color: var(--color-teal);
    margin: 1.5rem 0;
    border-radius: 5px;
}

.services-header .section-subtitle {
    color: var(--color-white);
    opacity: 0.95;
    font-size: 1.25rem;
    max-width: 700px;
    font-family: var(--font-sans);
}

.services-container {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 3rem;
    margin-top: 5rem;
    position: relative;
    z-index: 2;
}

/* Highlight for Club Arenas */
.featured-panel {
    border-top: 5px solid var(--color-teal);
    background: rgba(255, 255, 255, 0.05);
}

.service-panel {
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: var(--border-radius);
    padding: 3.5rem 2.5rem;
    transition: all 0.5s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    display: flex;
    flex-direction: column;
}

.service-panel:hover {
    transform: translateY(-15px);
    border-color: var(--color-tan);
}

.panel-psicopedagogia:hover {
    background-color: #1c3344 !important;
    box-shadow: 0 20px 45px rgba(34, 63, 84, 0.4);
}

.panel-clinica:hover {
    background: linear-gradient(135deg, #579cb9 0%, #1e7094 100%) !important;
    box-shadow: 0 20px 45px rgba(26, 99, 132, 0.4);
}

.panel-formacion:hover {
    background-color: #e5e5e8 !important;
    box-shadow: 0 20px 45px rgba(0, 0, 0, 0.15);
}

.panel-club:hover {
    background-color: #e5e5e8 !important;
    box-shadow: 0 20px 45px rgba(0, 0, 0, 0.15);
}

.service-header {
    margin-bottom: 3rem;
}

.service-icon img {
    height: 80px;
    width: auto;
    object-fit: contain;
    border-radius: 8px;
    transition: var(--transition);
}

.custom-logo-club img {
    height: 80px; /* Match the height of other service icons for visual harmony */
}

.service-panel:hover .service-icon img {
    transform: scale(1.1);
}

.service-panel h3 {
    font-family: 'Playfair Display', serif;
    font-size: 2.2rem;
    color: var(--color-white);
    margin-bottom: 0.8rem;
}

.service-tagline {
    font-family: 'Playfair Display', serif;
    font-style: italic;
    color: var(--color-tan);
    font-size: 1.1rem;
    opacity: 0.9;
    line-height: 1.4;
}

.service-body {
    flex-grow: 1;
    display: flex;
    flex-direction: column;
    gap: 2rem;
}

.service-sub-item h4 {
    color: var(--color-tan-light);
    font-size: 1rem;
    text-transform: uppercase;
    letter-spacing: 1.5px;
    margin-bottom: 0.5rem;
}

.service-sub-item p {
    font-size: 1rem;
    line-height: 1.6;
    color: rgba(255, 255, 255, 0.85);
    text-align: justify;
}

.service-subtopics-list {
    margin-top: 1rem;
    padding-left: 0.9rem;
    border-left: 2px solid rgba(217, 175, 139, 0.35);
    display: flex;
    flex-direction: column;
    gap: 0.9rem;
}

.service-subtopic-entry .subtopic-title {
    font-size: 0.88rem;
    font-weight: 700;
    color: #D9AF8B !important;
    letter-spacing: 0.5px;
    margin-bottom: 0.25rem;
    line-height: 1.4;
}

.service-subtopic-entry .subtopic-desc {
    font-size: 0.92rem;
    line-height: 1.5;
    color: rgba(255, 255, 255, 0.88) !important;
    text-align: justify;
    text-justify: inter-word;
    margin-bottom: 0;
}

.service-features {
    display: flex;
    flex-wrap: wrap;
    gap: 0.8rem;
    margin-top: auto;
    padding-top: 2rem;
    border-top: 1px solid rgba(255, 255, 255, 0.05);
}

.feat-tag {
    display: inline-flex;
    align-items: center;
    gap: 0.45rem;
    background: rgba(200, 161, 125, 0.1);
    color: var(--color-tan);
    font-size: 0.75rem;
    padding: 0.4rem 0.8rem;
    border-radius: 4px;
    font-weight: 600;
    letter-spacing: 0.5px;
    border: 1px solid rgba(200, 161, 125, 0.2);
    vertical-align: middle;
}

.feat-tag .material-symbols-outlined {
    font-size: 1.1rem;
    line-height: 1;
    display: inline-block;
    color: currentColor;
    font-variation-settings: 'FILL' 0, 'wght' 300, 'GRAD' 0, 'opsz' 24;
}

@media (max-width: 1200px) {
    .services-container {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 768px) {
    .services-container {
        grid-template-columns: 1fr;
    }
    .service-panel {
        padding: 2.5rem 2rem;
    }
}


/* Footer */
footer {
    background-color: var(--color-bg);
    padding-top: 4rem;
}
.footer-grid {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr 1fr;
    gap: 3rem;
    padding: 0 0 3rem;
}
.footer-brand {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
}
.footer-brand img {
    margin: 0 auto 1rem;
}
.footer-brand p {
    color: var(--color-text-light);
    margin-top: 0.8rem;
    max-width: 300px;
    margin-left: auto;
    margin-right: auto;
    text-align: center !important;
    text-align-last: center !important;
    line-height: 1.5;
}
footer h3 {
    font-family: var(--font-sans);
    font-size: 1.1rem;
    margin-bottom: 1.5rem;
}
.footer-links ul {
    display: flex;
    flex-direction: column;
    gap: 0.8rem;
}
.footer-links a {
    color: var(--color-text-light);
    transition: var(--transition);
}
.hero-tagline {
    font-size: 1.95rem;
    color: var(--color-white);
    margin-top: 1.5rem;
    margin-bottom: 2.5rem;
    font-family: var(--font-sans);
    opacity: 0.95;
    font-weight: 300;
    line-height: 1.4;
}

/* Service Panels - Rigorous Brand Palette & Contrast */
.panel-psicopedagogia { background-color: #223F54 !important; } /* Navy */
.panel-clinica { background: linear-gradient(135deg, #4A8EAB 0%, #1A6384 100%) !important; } /* Soft Blue to Teal Gradient */
.panel-formacion { background-color: #DDDDE1 !important; }       /* Silver/Grey */
.panel-club { background-color: #DDDDE1 !important; }            /* Silver/Grey */

/* Text Overrides for Dark Backgrounds (01, 02) */
.panel-psicopedagogia h3, .panel-psicopedagogia p, .panel-psicopedagogia h4,
.panel-clinica h3, .panel-clinica p, .panel-clinica h4 {
    color: #FFFFFF !important;
}

.panel-psicopedagogia .service-tagline {
    color: #D9AF8B !important; /* Sand accent on dark */
}

.panel-psicopedagogia .feat-tag {
    background: rgba(217, 175, 139, 0.15) !important;
    border: 1px solid rgba(217, 175, 139, 0.3) !important;
    color: #D9AF8B !important;
}

/* Specific for Teal/Blue Panel (02) - High Contrast White */
.panel-clinica .service-tagline {
    color: rgba(255, 255, 255, 0.9) !important;
}

.panel-clinica .feat-tag {
    background: rgba(255, 255, 255, 0.15) !important;
    border: 1px solid rgba(255, 255, 255, 0.25) !important;
    color: #FFFFFF !important;
}

/* Text Overrides for Light Backgrounds (03, 04) */
.panel-formacion h3, .panel-formacion h4, .panel-formacion .service-tagline,
.panel-club h3, .panel-club h4, .panel-club .service-tagline {
    color: #223F54 !important; /* Navy on Silver/Tan */
}

.panel-formacion p, .panel-club p {
    color: #223F54 !important;
    font-weight: 400;
}

/* High Contrast Tags for Light Backgrounds (03, 04) */
.panel-formacion .feat-tag, .panel-club .feat-tag {
    background: rgba(34, 63, 84, 0.08) !important;
    border: 1px solid rgba(34, 63, 84, 0.25) !important;
    color: #223F54 !important;
}

.service-icon.custom-isotipo img {
    border: 2px solid rgba(255, 255, 255, 0.2);
    box-shadow: var(--shadow-md);
}
.footer-contact p {
    color: var(--color-text-light);
    margin-bottom: 0.8rem;
}
.contact-link {
    color: var(--color-navy);
    font-weight: 600;
}
.social-links {
    display: flex;
    gap: 1.2rem;
    margin-top: 1rem;
}

.social-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 45px;
    height: 45px;
    background-color: var(--color-navy);
    color: var(--color-white);
    border-radius: 50%;
    border: 1px solid rgba(255, 255, 255, 0.1);
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.social-icon svg {
    width: 22px;
    height: 22px;
    transition: transform 0.3s ease;
}

.social-icon:hover {
    transform: translateY(-5px) scale(1.1);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.15);
    color: var(--color-white);
}

.social-icon:hover svg {
    transform: scale(1.1);
}

.social-icon.wa:hover { background-color: #25D366; border-color: #25D366; }
.social-icon.ig:hover { background-color: #E1306C; border-color: #E1306C; }
.social-icon.fb:hover { background-color: #1877F2; border-color: #1877F2; }
.footer-bottom {
    padding: 1.5rem 0;
    border-top: 1px solid rgba(0,0,0,0.05);
    color: var(--color-text-light);
    font-size: 0.9rem;
}

/* Responsive Design */
@media (max-width: 992px) {
    .section-grid {
        grid-template-columns: 1fr;
    }
    .about-visual {
        order: -1;
        height: 400px;
    }
    .founders-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    .specialty-teams {
        grid-template-columns: 1fr;
    }
    .specialty-team-grid {
        grid-template-columns: 1fr 1fr;
    }
    .footer-grid {
        grid-template-columns: 1fr 1fr;
    }
}

@media (max-width: 768px) {
    .navbar-logo-img {
        height: 62px; /* Scale logo down slightly on mobile screen heights */
    }
    .menu-toggle {
        display: flex;
    }
    .nav-menu {
        position: fixed;
        left: -100%;
        top: 70px;
        flex-direction: column;
        background: var(--color-white);
        width: 100%;
        text-align: center;
        transition: 0.3s;
        box-shadow: 0 10px 15px rgba(0,0,0,0.05);
        padding: 2rem 0;
    }
    .nav-menu.active {
        left: 0;
    }
    .nav-menu li {
        width: 100%;
    }
    .nav-menu .btn-primary {
        margin-left: 0;
        margin-top: 1rem;
    }

    .main-heading {
        font-size: 3rem;
    }
    .values-grid {
        grid-template-columns: 1fr;
    }
    .services-grid {
        grid-template-columns: 1fr;
    }
    .founders-grid {
        grid-template-columns: 1fr;
    }
    .specialty-teams {
        grid-template-columns: 1fr;
    }
    .specialty-team-grid {
        grid-template-columns: 1fr;
    }
    .footer-grid {
        grid-template-columns: 1fr;
    }
}

/* --- Interactive Tooltips for Tags --- */
.feat-tag {
    position: relative;
    cursor: help; /* Cursor changes to help icon */
}

/* Tooltip text box */
.feat-tag::before {
    content: attr(data-tooltip);
    position: absolute;
    bottom: 135%; /* Positioned above the tag */
    left: 50%;
    transform: translateX(-50%) translateY(10px) scale(0.85);
    background-color: #223F54; /* Navy brand color for maximum consistency */
    color: #ffffff !important;
    padding: 0.8rem 1rem;
    border-radius: 8px;
    font-size: 0.8rem;
    font-weight: 400;
    line-height: 1.4;
    width: 220px;
    white-space: normal;
    text-align: center;
    box-shadow: 0 10px 25px rgba(15, 44, 65, 0.25);
    border: 1px solid rgba(255, 255, 255, 0.12);
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.2), transform 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.2);
    z-index: 1000;
}

/* Tooltip small arrow */
.feat-tag::after {
    content: '';
    position: absolute;
    bottom: 120%; /* Positioned right below the bubble */
    left: 50%;
    transform: translateX(-50%) translateY(10px) scale(0.85);
    border-width: 6px 6px 0;
    border-style: solid;
    border-color: #223F54 transparent transparent; /* Navy brand color */
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.2), transform 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.2);
    z-index: 1000;
}

/* Hover or tap state triggers animation */
.feat-tag:hover::before,
.feat-tag:hover::after,
.feat-tag.tooltip-active::before,
.feat-tag.tooltip-active::after {
    opacity: 1;
    transform: translateX(-50%) translateY(0) scale(1);
}

/* Responsive adjustment for small viewports */
@media (max-width: 600px) {
    .feat-tag::before {
        width: 200px;
        font-size: 0.78rem;
        padding: 0.65rem 0.85rem;
        bottom: 135%;
    }
    .feat-tag.tag-activity::before {
        width: 230px;
    }
    .feat-tag::after {
        bottom: 120%;
    }
}

/* --- System Cursor Hide for Desktop --- */
@media (pointer: fine) {
    body, a, button, [data-cursor-text], .founder-card, .feat-tag, .menu-toggle, .logo, .logo img {
        cursor: none !important;
    }
}

/* --- Custom Mouse Cursor --- */
.custom-cursor {
    position: fixed;
    left: -50px;
    top: -50px;
    width: 32px;
    height: 32px;
    border: 2px solid transparent;
    border-radius: 50%;
    pointer-events: none;
    z-index: 99999;
    transform: translate(-50%, -50%);
    transition: width 0.3s cubic-bezier(0.25, 1, 0.5, 1), height 0.3s cubic-bezier(0.25, 1, 0.5, 1), background-color 0.3s ease, border-color 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    background-color: transparent;
    opacity: 0;
}

/* Center dot - hidden as we now use the hourglass SVG */
.custom-cursor::after {
    display: none;
}

.custom-cursor.initialized {
    opacity: 1;
}

/* Hourglass SVG styles */
.hourglass-icon {
    position: absolute;
    width: 28px;
    height: 28px;
    pointer-events: none;
    transform: scale(1) rotate(0deg);
    transition: transform 0.3s cubic-bezier(0.25, 1, 0.5, 1), opacity 0.3s ease;
    transform-origin: center center;
}

/* Elegant brand colors for parts of the hourglass SVG */
.hourglass-icon .hg-accent {
    color: var(--color-tan); /* Tan/Gold for the plates */
}
.hourglass-icon .hg-glass {
    color: var(--color-navy); /* Navy for the glass frame structure */
}
.hourglass-icon .hg-sand-top,
.hourglass-icon .hg-sand-bot,
.hourglass-icon .hg-drip {
    color: var(--color-tan); /* Tan/Gold for the sand content and falling drip */
}

/* Hourly hourglass flipping animation triggered by user clicks */
@keyframes hourglass-flip {
    0% { transform: scale(1) rotate(0deg); }
    50% { transform: scale(1.2) rotate(90deg); }
    100% { transform: scale(1) rotate(180deg); }
}

.hourglass-icon.flipping {
    animation: hourglass-flip 0.6s cubic-bezier(0.25, 1, 0.5, 1) forwards;
}

/* Expanded state on standard hoverable elements */
.custom-cursor.active {
    width: 50px;
    height: 50px;
    border-color: var(--color-teal);
    background-color: rgba(26, 99, 132, 0.08);
}

.custom-cursor.active .hourglass-icon,
.custom-cursor.has-text .hourglass-icon {
    opacity: 0;
    transform: scale(0) rotate(90deg);
}

/* Large filled state with text inside */
.custom-cursor.has-text {
    width: 58px;
    height: 58px;
    background-color: rgba(34, 63, 84, 0.72); /* Translucent navy to see elements behind */
    border-color: rgba(34, 63, 84, 0.8);
    backdrop-filter: blur(5px);
    -webkit-backdrop-filter: blur(5px);
    box-shadow: 0 8px 20px rgba(34, 63, 84, 0.15);
}

.cursor-text {
    position: absolute;
    color: #ffffff;
    font-family: var(--font-sans);
    font-size: 0.62rem; /* Adjusted for smaller size */
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 1px;
    opacity: 0;
    transform: scale(0.8);
    transition: opacity 0.2s ease, transform 0.2s ease;
    pointer-events: none;
    white-space: nowrap;
}

.custom-cursor.has-text .cursor-text {
    opacity: 1;
    transform: scale(1);
}

/* Hide custom cursor on mobile touchscreens */
@media (pointer: coarse) {
    .custom-cursor {
        display: none !important;
    }
}

/* --- Scroll Parallax Decor Shapes --- */
.parallax-shape {
    position: absolute;
    border-radius: 50%;
    filter: blur(80px);
    pointer-events: none;
    z-index: 0;
    opacity: 0.15;
    transition: transform 0.1s ease-out;
}

.shape-hero-1 {
    top: 15%;
    left: 10%;
    width: 300px;
    height: 300px;
    background-color: var(--color-teal);
}

.shape-hero-2 {
    bottom: 20%;
    right: 15%;
    width: 350px;
    height: 350px;
    background-color: var(--color-tan);
}

.shape-about-1 {
    top: 10%;
    right: 5%;
    width: 400px;
    height: 400px;
    background-color: var(--color-tan);
    opacity: 0.08;
}

.shape-about-2 {
    bottom: 15%;
    left: -5%;
    width: 320px;
    height: 320px;
    background-color: var(--color-brown);
    opacity: 0.06;
}

.shape-values-1 {
    top: 30%;
    left: 10%;
    width: 380px;
    height: 380px;
    background-color: var(--color-teal);
    opacity: 0.1;
}

.shape-values-2 {
    bottom: 10%;
    right: 5%;
    width: 300px;
    height: 300px;
    background-color: var(--color-tan);
    opacity: 0.12;
}

/* Relative positioning and clipping for parallax containers */
.hero, .about, .values {
    position: relative;
    overflow: hidden;
}

/* --- Navbar Magnetic Wobble Animation --- */
.magnetic-wobble-active {
    animation: magnetic-wobble 0.65s ease-out;
}

@keyframes magnetic-wobble {
    0% { transform: translate(var(--wobble-x, 0px), var(--wobble-y, 0px)); }
    20% { transform: translate(calc(var(--wobble-x, 0px) * -0.5), calc(var(--wobble-y, 0px) * -0.5)); }
    40% { transform: translate(calc(var(--wobble-x, 0px) * 0.25), calc(var(--wobble-y, 0px) * 0.25)); }
    60% { transform: translate(calc(var(--wobble-x, 0px) * -0.12), calc(var(--wobble-y, 0px) * -0.12)); }
    80% { transform: translate(calc(var(--wobble-x, 0px) * 0.05), calc(var(--wobble-y, 0px) * 0.05)); }
    100% { transform: translate(0, 0); }
}

/* --- Specialty Detail Modal (Awwwards Style) --- */
.service-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    z-index: 10000;
    display: flex;
    align-items: center;
    justify-content: center;
    pointer-events: none;
    opacity: 0;
    transition: opacity 0.5s cubic-bezier(0.25, 1, 0.5, 1);
}

.service-modal.active {
    pointer-events: auto;
    opacity: 1;
}

.modal-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(34, 63, 84, 0.65); /* Transparent Navy overlay */
    backdrop-filter: blur(15px);
    -webkit-backdrop-filter: blur(15px);
    transition: opacity 0.5s ease;
}

.modal-wrapper {
    position: relative;
    width: 92%;
    max-width: 900px;
    height: 82vh;
    background-color: var(--color-white);
    border-radius: var(--border-radius);
    box-shadow: var(--shadow-lg);
    border: 1px solid rgba(255, 255, 255, 0.15);
    overflow: hidden;
    display: flex;
    flex-direction: column;
    transform: translateY(40px) scale(0.96);
    transition: transform 0.5s cubic-bezier(0.25, 1, 0.5, 1);
    z-index: 2;
}

.service-modal.active .modal-wrapper {
    transform: translateY(0) scale(1);
}

.modal-close-btn {
    position: absolute;
    top: 1.5rem;
    right: 1.5rem;
    width: 44px;
    height: 44px;
    border-radius: 50%;
    background-color: var(--color-navy);
    color: #ffffff;
    border: none;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    box-shadow: var(--shadow-sm);
    transition: all 0.3s cubic-bezier(0.25, 1, 0.5, 1);
    z-index: 10;
}

.modal-close-btn:hover {
    transform: scale(1.1) rotate(90deg);
    background-color: var(--color-teal);
}

.modal-content-container {
    padding: 3.5rem 3rem;
    overflow-y: auto;
    height: 100%;
    display: flex;
    flex-direction: column;
    gap: 2.2rem;
}

/* Modal Typography */
.modal-header-section {
    display: flex;
    align-items: center;
    gap: 1.8rem;
    border-bottom: 1.5px solid var(--color-grey-light);
    padding-bottom: 1.8rem;
}

.modal-icon img {
    height: 80px;
    width: 80px;
    object-fit: cover;
    border-radius: 8px;
    border: 1px solid var(--color-grey-light);
}

.modal-header-text h2 {
    font-family: var(--font-serif);
    font-size: 2.2rem;
    color: var(--color-navy);
    line-height: 1.1;
    margin-bottom: 0.3rem;
}

.modal-header-text .tagline {
    font-family: var(--font-serif);
    font-style: italic;
    color: var(--color-teal);
    font-size: 1.15rem;
}

.modal-intro-text {
    margin-bottom: 2rem;
}

.modal-intro-text p {
    font-size: 1.05rem;
    line-height: 1.75;
    color: var(--color-text);
    text-align: justify;
    text-justify: inter-word;
    margin-bottom: 1.25rem;
}

.modal-intro-text p:last-child {
    margin-bottom: 0;
}

.modal-sub-items-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 1.5rem;
}

.modal-sub-item-card {
    background-color: var(--color-bg);
    padding: 1.8rem;
    border-radius: 8px;
    border-left: 5px solid var(--color-tan);
    transition: transform 0.3s ease;
}

.modal-sub-item-card:hover {
    transform: translateX(4px);
}

.modal-sub-item-card h4 {
    font-family: var(--font-sans);
    font-size: 1.05rem;
    letter-spacing: 0.5px;
    color: var(--color-navy);
    margin-bottom: 0.8rem;
    font-weight: 700;
    line-height: 1.4;
    text-align: justify;
    text-justify: inter-word;
}

.modal-sub-item-card p {
    font-size: 0.98rem;
    line-height: 1.6;
    color: var(--color-text-light);
    text-align: justify;
    text-justify: inter-word;
    margin-bottom: 0.8rem;
}

.modal-sub-item-card p:last-child {
    margin-bottom: 0;
}

/* Modal Subtopics (shifted to the right) */
.modal-sub-item-card.is-subtopic {
    margin-left: 2.2rem;
    background-color: #F8FAF9;
    border-left: 4px solid var(--color-teal);
    border-top: 1px solid rgba(15, 44, 65, 0.05);
    border-right: 1px solid rgba(15, 44, 65, 0.05);
    border-bottom: 1px solid rgba(15, 44, 65, 0.05);
    box-shadow: 0 4px 15px rgba(15, 44, 65, 0.03);
}

.modal-sub-item-card.is-subtopic h4 {
    color: var(--color-navy);
    font-size: 1rem;
}

@media (max-width: 768px) {
    .modal-sub-item-card.is-subtopic {
        margin-left: 1rem;
        padding: 1.4rem;
    }
}

/* Modal Subtopic Bullet List */
.modal-subtopic-bullets {
    list-style: none;
    padding: 0;
    margin: 0.8rem 0 0 0;
    display: flex;
    flex-direction: column;
    gap: 0.65rem;
}

.modal-subtopic-bullets li {
    position: relative;
    padding-left: 1.4rem;
    font-size: 0.98rem;
    line-height: 1.6;
    color: var(--color-text-light);
    text-align: justify;
    text-justify: inter-word;
}

.modal-subtopic-bullets li::before {
    content: "•";
    position: absolute;
    left: 0.2rem;
    top: 0;
    color: var(--color-navy);
    font-weight: bold;
    font-size: 1.1rem;
}

/* Modal Distinctive Closing Box */
.modal-closing-box {
    margin-top: 1.8rem;
    padding: 1.8rem 2rem;
    background: linear-gradient(135deg, rgba(34, 63, 84, 0.04) 0%, rgba(197, 168, 128, 0.12) 100%);
    border-left: 5px solid var(--color-navy);
    border-radius: 8px;
    border-top: 1px solid rgba(34, 63, 84, 0.08);
    border-right: 1px solid rgba(34, 63, 84, 0.08);
    border-bottom: 1px solid rgba(34, 63, 84, 0.08);
    display: flex;
    align-items: flex-start;
    gap: 1.2rem;
    box-shadow: 0 4px 15px rgba(15, 44, 65, 0.04);
}

.modal-closing-icon {
    flex-shrink: 0;
    color: var(--color-navy);
    display: flex;
    align-items: center;
    justify-content: center;
    width: 44px;
    height: 44px;
    background-color: rgba(34, 63, 84, 0.08);
    border-radius: 50%;
}

.modal-closing-icon .material-symbols-outlined {
    font-size: 1.7rem;
    color: var(--color-navy);
}

.modal-closing-content p {
    margin: 0;
    font-size: 1rem;
    line-height: 1.7;
    color: var(--color-navy);
    text-align: justify;
    text-justify: inter-word;
}

@media (max-width: 768px) {
    .modal-closing-box {
        padding: 1.3rem 1.4rem;
        flex-direction: column;
        gap: 0.8rem;
    }
}

.modal-cta-box {
    display: flex;
    justify-content: center;
    margin-top: 1rem;
}

#modal-cta-btn {
    text-decoration: none;
    font-size: 0.95rem;
    font-weight: bold;
}

/* Link at service card bottom style */
.btn-read-more {
    margin-top: auto;
    padding-top: 1.8rem;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--color-tan);
    transition: var(--transition);
    cursor: pointer;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.panel-formacion .btn-read-more, .panel-club .btn-read-more {
    color: var(--color-navy) !important;
}

.service-panel:hover .btn-read-more {
    gap: 0.75rem;
}

.panel-psicopedagogia:hover .btn-read-more, .panel-clinica:hover .btn-read-more {
    color: var(--color-white) !important;
}

.panel-formacion:hover .btn-read-more, .panel-club:hover .btn-read-more {
    color: var(--color-teal) !important;
}

.btn-read-more .material-symbols-outlined {
    font-size: 1.05rem;
    transition: transform 0.3s ease;
}

.service-panel:hover .btn-read-more .material-symbols-outlined {
    transform: translateX(3px);
}

/* Responsiveness overrides */
@media (max-width: 768px) {
    .modal-content-container {
        padding: 3rem 1.8rem;
        gap: 1.8rem;
    }
    .modal-header-section {
        flex-direction: column;
        align-items: flex-start;
        gap: 0.8rem;
    }
    .modal-header-text h2 {
        font-size: 1.8rem;
    }
}

/* Founder/Professional Profile Modal Styles */
.founder-modal-content {
    display: flex;
    flex-direction: column;
    gap: 2rem;
}

.founder-modal-header {
    display: flex;
    align-items: center;
    gap: 2.2rem;
    border-bottom: 1.5px solid var(--color-grey-light);
    padding-bottom: 2rem;
}

.founder-modal-img {
    width: 140px;
    height: 140px;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: var(--shadow-md);
    flex-shrink: 0;
    border: 3px solid var(--color-tan);
    background-color: var(--color-bg);
}

.founder-modal-img img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: top center;
}

.founder-modal-title {
    display: flex;
    flex-direction: column;
    gap: 0.3rem;
}

.founder-modal-tag {
    font-size: 0.72rem;
    letter-spacing: 1.5px;
    font-weight: bold;
    color: var(--color-tan);
    text-transform: uppercase;
}

.founder-modal-title h2 {
    font-family: var(--font-serif);
    font-size: 2.3rem;
    color: var(--color-navy);
    line-height: 1.15;
    margin: 0;
}

.founder-modal-role {
    color: var(--color-teal);
    font-size: 1.1rem;
    font-weight: 600;
    letter-spacing: 0.5px;
    margin: 0;
}

.founder-modal-colegiado {
    color: var(--color-text-light);
    font-size: 0.95rem;
    font-weight: 500;
    margin: 0;
}

.founder-modal-trajectory {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.founder-modal-trajectory-item {
    font-size: 0.98rem;
    line-height: 1.65;
    color: var(--color-text);
    margin: 0;
    text-align: justify;
    text-justify: inter-word;
}

.founder-modal-bio strong,
.founder-modal-trajectory-item strong {
    font-weight: 700;
    color: var(--color-navy);
}

.founder-modal-body {
    display: flex;
    flex-direction: column;
    gap: 1.8rem;
}

.founder-modal-section h3 {
    font-family: var(--font-serif);
    font-size: 1.3rem;
    color: var(--color-navy);
    margin-bottom: 0.6rem;
    position: relative;
    padding-left: 0.8rem;
    font-weight: 700;
}

.founder-modal-section h3::before {
    content: '';
    position: absolute;
    left: 0;
    top: 0.3rem;
    bottom: 0.3rem;
    width: 3px;
    background-color: var(--color-tan);
    border-radius: 2px;
}

.founder-modal-bio {
    font-size: 1.05rem;
    line-height: 1.75;
    color: var(--color-text);
    margin: 0;
    text-align: justify;
}

.founder-modal-placeholder {
    font-size: 0.98rem;
    line-height: 1.7;
    color: var(--color-text-light);
    background-color: var(--color-bg);
    padding: 1.2rem;
    border-radius: 8px;
    border-left: 4px solid var(--color-teal);
    margin: 0;
    font-style: italic;
    text-align: justify;
}

/* Responsiveness for Founder Modal */
@media (max-width: 768px) {
    .founder-modal-header {
        flex-direction: column;
        align-items: center;
        text-align: center;
        gap: 1.2rem;
    }
    .founder-modal-title h2 {
        font-size: 1.9rem;
    }
    .founder-modal-img {
        width: 120px;
        height: 120px;
    }
}

/* --- Botones de enlace en paneles de servicio (WhatsApp / Instagram / Ver detalles) --- */
.btn-service-link {
    display: inline-block;
    align-self: flex-start;
    margin-top: auto;
    padding: 0.9rem 1.6rem;
    background-color: var(--color-navy);
    color: var(--color-white) !important;
    border-radius: 50px;
    font-size: 0.85rem;
    font-weight: 600;
    line-height: 1.4;
    letter-spacing: 0.5px;
    text-decoration: none;
    cursor: pointer;
    border: none;
    font-family: inherit;
    transition: var(--transition);
}

.btn-service-link:hover {
    background-color: var(--color-teal);
    transform: translateY(-2px);
}

/* En panel-psicopedagogia (fondo Navy #223F54), cápsula azul con contraste nítido */
.panel-psicopedagogia .btn-service-link {
    background-color: #162B3A;
    border: 1px solid rgba(255, 255, 255, 0.25);
    color: #FFFFFF !important;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.panel-psicopedagogia .btn-service-link:hover {
    background-color: var(--color-teal);
    border-color: var(--color-teal);
    transform: translateY(-2px);
}

/* En panel-clinica (fondo Teal/Blue), cápsula Navy institucional */
.panel-clinica .btn-service-link {
    background-color: var(--color-navy);
    border: 1px solid rgba(255, 255, 255, 0.15);
    color: #FFFFFF !important;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.panel-clinica .btn-service-link:hover {
    background-color: #162B3A;
    transform: translateY(-2px);
}

/* --- Club ARENAS: actividades realizadas --- */
.club-activities {
    margin-top: 0;
    padding-top: 0.5rem;
    margin-bottom: 1.5rem;
    border-top: none;
}

.feat-tag.tag-activity {
    font-size: 0.85rem;
    padding: 0.55rem 1.15rem;
    gap: 0.55rem;
}

.feat-tag.tag-activity .material-symbols-outlined {
    font-size: 1.25rem;
    font-variation-settings: 'FILL' 0, 'wght' 300, 'GRAD' 0, 'opsz' 24;
}

.feat-tag.tag-activity::before {
    width: 280px;
    text-align: left;
    white-space: pre-line;
}

.club-grid-features {
    margin-bottom: 1.5rem;
}
