/* ==========================================================================
   Mimarse Estudio — rieles, carro y resortes
   ========================================================================== */

:root {
    /* Marca */
    --navy: #1B2945;
    --navy-deep: #131E35;
    --navy-line: rgba(255, 255, 255, 0.22);
    --on-navy: #FFFFFF;
    --on-navy-soft: #C3CCDE;

    /* Suelo de aluminio */
    --ground: #EEF1F5;
    --surface: #FFFFFF;
    --ink: #172139;
    --ink-soft: #4A5572;
    --rail: #BCC4D2;

    /* Carro de maple: solo para lo activo */
    --maple: #D6B283;
    --maple-deep: #B8915C;

    /* Resortes */
    --spring-red: #D2463C;
    --spring-yellow: #E3AA2B;
    --spring-green: #3A9566;
    --spring-blue: #4079CF;

    --font-display: 'Jost', 'Futura', 'Century Gothic', sans-serif;
    --font-body: 'Figtree', 'Segoe UI', system-ui, sans-serif;

    --wrap: 1180px;
    --gutter: clamp(1rem, 4vw, 2.5rem);
    --radius: 14px;
    --radius-sm: 10px;
    --ease-out: cubic-bezier(0.16, 1, 0.3, 1);
    --ease-snap: cubic-bezier(0.34, 1.56, 0.64, 1);
    --header-h: 68px;
}

*,
*::before,
*::after {
    box-sizing: border-box;
}

* {
    margin: 0;
    padding: 0;
}

html {
    scroll-behavior: smooth;
    scroll-padding-top: calc(var(--header-h) + 12px);
    -webkit-text-size-adjust: 100%;
    accent-color: var(--navy);
    scrollbar-color: var(--rail) var(--ground);
}

body {
    font-family: var(--font-body);
    font-size: 1.0625rem;
    line-height: 1.6;
    color: var(--ink);
    background: var(--ground);
    overflow-x: clip;
}

img,
svg {
    display: block;
    max-width: 100%;
}

ul {
    list-style: none;
}

button {
    font: inherit;
}

a {
    color: inherit;
    text-underline-offset: 0.2em;
    text-decoration-thickness: 1px;
}

::selection {
    background: var(--navy);
    color: var(--on-navy);
}

:focus-visible {
    outline: 3px solid var(--spring-blue);
    outline-offset: 3px;
    border-radius: 6px;
}

.hero :focus-visible,
.reviews :focus-visible,
.contact :focus-visible,
.site-header :focus-visible {
    outline-color: var(--on-navy);
}

.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

.skip-link {
    position: absolute;
    left: 1rem;
    top: -4rem;
    z-index: 2000;
    background: var(--surface);
    color: var(--navy);
    padding: 0.75rem 1rem;
    border-radius: var(--radius-sm);
    font-weight: 600;
}

.skip-link:focus {
    top: 1rem;
}

.wrap {
    max-width: var(--wrap);
    margin: 0 auto;
    padding: 0 var(--gutter);
}

.section-title {
    font-family: var(--font-display);
    font-weight: 400;
    font-size: clamp(2.1rem, 5vw, 3.4rem);
    line-height: 1.05;
    letter-spacing: -0.02em;
    text-wrap: balance;
}

.section-intro {
    color: var(--ink-soft);
    max-width: 52ch;
    margin-top: 0.9rem;
}

/* --------------------------------------------------------------------------
   Botones
   -------------------------------------------------------------------------- */

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.6rem;
    min-height: 48px;
    padding: 0.75rem 1.4rem;
    border-radius: var(--radius-sm);
    border: 1px solid transparent;
    font: 600 1rem/1.2 var(--font-body);
    text-decoration: none;
    cursor: pointer;
    transition: background-color 0.2s ease, color 0.2s ease, border-color 0.2s ease, transform 0.2s var(--ease-out);
}

.btn svg {
    width: 20px;
    height: 20px;
    flex: none;
}

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

.btn-sm {
    min-height: 44px;
    padding: 0.55rem 1rem;
    font-size: 0.95rem;
}

.btn-lg {
    min-height: 56px;
    padding: 0.9rem 1.6rem;
    font-size: 1.08rem;
}

.btn-light {
    background: var(--on-navy);
    color: var(--navy);
}

.btn-light:hover {
    background: var(--ground);
}

.btn-ghost-light {
    color: var(--on-navy);
    border-color: var(--navy-line);
}

.btn-ghost-light:hover {
    border-color: var(--on-navy);
}

.btn-ghost-light svg[aria-hidden] {
    transition: transform 0.25s var(--ease-out);
}

.btn-ghost-light:hover svg {
    transform: translateX(3px);
}

.btn-navy {
    background: var(--navy);
    color: var(--on-navy);
}

.btn-navy:hover {
    background: var(--navy-deep);
}

/* --------------------------------------------------------------------------
   Rieles (dos líneas finas con topes)
   -------------------------------------------------------------------------- */

.rails {
    position: relative;
    height: 12px;
    margin: 0 var(--gutter);
    border-top: 1px solid var(--navy-line);
    border-bottom: 1px solid var(--navy-line);
}

.rails::before,
.rails::after {
    content: '';
    position: absolute;
    top: 50%;
    width: 14px;
    height: 14px;
    border: 1px solid var(--navy-line);
    border-radius: 50%;
    background: var(--navy);
    transform: translateY(-50%);
}

.rails::before {
    left: 0;
}

.rails::after {
    right: 0;
}

/* --------------------------------------------------------------------------
   Header
   -------------------------------------------------------------------------- */

.site-header {
    position: sticky;
    top: 0;
    z-index: 1000;
    background: var(--navy);
    color: var(--on-navy);
    transition: box-shadow 0.3s ease;
}

.site-header.is-scrolled {
    box-shadow: 0 6px 24px rgba(0, 0, 0, 0.18);
}

.nav {
    max-width: var(--wrap);
    margin: 0 auto;
    padding: 0 var(--gutter);
    height: var(--header-h);
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
}

.brand {
    display: flex;
    align-items: center;
    gap: 0.7rem;
    text-decoration: none;
    min-height: 44px;
}

.brand-badge {
    display: grid;
    place-items: center;
    width: 40px;
    height: 40px;
    border: 1px solid var(--navy-line);
    border-radius: 50%;
}

.brand-badge svg {
    width: 22px;
    height: 18px;
}

.brand-name {
    font-family: var(--font-display);
    font-size: 1.3rem;
    font-weight: 400;
    letter-spacing: 0.01em;
}

.brand-name span {
    font-weight: 300;
    font-size: 0.72rem;
    letter-spacing: 0.32em;
    text-transform: uppercase;
    margin-left: 0.25rem;
    color: var(--on-navy-soft);
}

.nav-links {
    display: flex;
    align-items: center;
    gap: 0.25rem;
}

.nav-links a:not(.btn) {
    display: inline-flex;
    align-items: center;
    min-height: 44px;
    padding: 0 0.85rem;
    text-decoration: none;
    font-weight: 500;
    color: var(--on-navy-soft);
    transition: color 0.2s ease;
}

.nav-links a:not(.btn):hover {
    color: var(--on-navy);
}

.nav-cta {
    margin-left: 0.75rem;
}

.menu-btn {
    display: none;
    width: 44px;
    height: 44px;
    place-items: center;
    background: none;
    border: 1px solid var(--navy-line);
    border-radius: var(--radius-sm);
    color: var(--on-navy);
    cursor: pointer;
}

.menu-btn svg {
    width: 22px;
    height: 22px;
}

/* --------------------------------------------------------------------------
   Hero
   -------------------------------------------------------------------------- */

.hero {
    background: var(--navy);
    color: var(--on-navy);
    padding-top: clamp(2rem, 6vw, 4.5rem);
}

.hero-inner {
    max-width: var(--wrap);
    margin: 0 auto;
    padding: 0 var(--gutter);
    display: grid;
    grid-template-columns: 1fr 1.05fr;
    align-items: end;
    gap: clamp(2rem, 5vw, 4.5rem);
}

.hero-copy {
    padding-bottom: clamp(2.5rem, 6vw, 5rem);
}

.hero-title {
    font-family: var(--font-display);
    font-weight: 300;
    font-size: clamp(3.8rem, 11vw, 6rem);
    line-height: 0.95;
    letter-spacing: -0.03em;
}

.hero-title-sub {
    display: block;
    margin-top: 0.9rem;
    font-size: 0.95rem;
    font-weight: 400;
    letter-spacing: 0.5em;
    text-transform: uppercase;
    color: var(--on-navy-soft);
}

.hero-lead {
    margin-top: 2rem;
    font-family: var(--font-display);
    font-size: clamp(1.35rem, 2.4vw, 1.7rem);
    line-height: 1.3;
    max-width: 22ch;
}

.hero-text {
    margin-top: 0.8rem;
    color: var(--on-navy-soft);
    max-width: 40ch;
}

.hero-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
    margin-top: 2rem;
}

/* La foto del equipo va sobre el carro, que corre por los rieles */
.hero-carriage {
    position: relative;
    padding-bottom: 14px;
    animation: carriage-in 1.1s var(--ease-out) both;
}

.hero-carriage img {
    width: 100%;
    height: auto;
    aspect-ratio: 1024 / 842;
    object-fit: cover;
    border-radius: var(--radius) var(--radius) 4px 4px;
}

.carriage-base {
    position: absolute;
    left: -3%;
    right: -3%;
    bottom: 0;
    height: 14px;
    border-radius: 7px 7px 0 0;
    background: linear-gradient(var(--maple), var(--maple-deep));
}

@keyframes carriage-in {
    from {
        transform: translateX(-6%);
        opacity: 0;
    }
}

/* --------------------------------------------------------------------------
   Clases y horarios
   -------------------------------------------------------------------------- */

.sedes {
    padding: clamp(4rem, 9vw, 7rem) 0;
}

.sedes-head {
    margin-bottom: 2.5rem;
}

/* Selector de sede: tope, resorte, carro */
.switch {
    --carriage-x: 0px;
    --carriage-w: 0px;
    position: relative;
    display: grid;
    grid-template-columns: minmax(3rem, 1fr) auto auto;
    align-items: stretch;
    max-width: 620px;
    padding: 6px 0;
    border-top: 1px solid var(--rail);
    border-bottom: 1px solid var(--rail);
    margin-bottom: 3rem;
}

.switch-stop {
    position: absolute;
    left: 0;
    top: 100%;
    width: 16px;
    height: 16px;
    border: 1px solid var(--rail);
    border-radius: 50%;
    background: var(--surface);
    transform: translateY(-50%);
    z-index: 2;
}

.switch-spring {
    position: absolute;
    left: 14px;
    top: 100%;
    transform: translateY(-50%);
    overflow: visible;
    z-index: 3;
    pointer-events: none;
}

/* Vuelta de atrás del resorte (más tenue) y de adelante */
.coil-back {
    fill: none;
    stroke: #A8362E;
    stroke-opacity: 0.5;
    stroke-width: 1.3;
    stroke-linecap: round;
}

.coil-front {
    fill: none;
    stroke: var(--spring-red);
    stroke-width: 1.8;
    stroke-linecap: round;
    stroke-linejoin: round;
}

.switch-carriage {
    position: absolute;
    top: 6px;
    bottom: 6px;
    left: 0;
    width: var(--carriage-w);
    transform: translateX(var(--carriage-x));
    background: var(--maple);
    border-radius: var(--radius-sm);
    box-shadow: 0 6px 14px -6px rgba(120, 84, 38, 0.55);
    transition: transform 0.55s var(--ease-snap);
    opacity: 0;
}

.switch.is-ready .switch-carriage {
    opacity: 1;
}

/* Pie del carro: baja hasta el riel, donde se engancha el resorte */
.switch-carriage::after {
    content: '';
    position: absolute;
    left: 6px;
    bottom: -7px;
    width: 10px;
    height: 7px;
    border-radius: 0 0 3px 3px;
    background: var(--maple-deep);
}

.switch-tab {
    position: relative;
    z-index: 2;
    grid-row: 1;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    justify-content: center;
    min-height: 64px;
    min-width: 11rem;
    padding: 0.6rem 1.25rem;
    background: none;
    border: 0;
    border-radius: var(--radius-sm);
    color: var(--ink-soft);
    text-align: left;
    cursor: pointer;
    transition: color 0.25s ease;
}

.switch-tab:nth-of-type(1) {
    grid-column: 2;
}

.switch-tab:nth-of-type(2) {
    grid-column: 3;
}

.switch-tab:hover,
.switch-tab[aria-selected="true"] {
    color: var(--navy);
}

.switch-name {
    font-family: var(--font-display);
    font-size: 1.5rem;
    font-weight: 400;
    line-height: 1.1;
}

.switch-addr {
    font-size: 0.85rem;
    font-weight: 500;
    line-height: 1.3;
}

/* Panel de cada sede */
.sede[hidden] {
    display: none;
}

.sede:focus-visible {
    outline-offset: 12px;
}

.sede.is-entering {
    animation: sede-in 0.45s var(--ease-out);
}

@keyframes sede-in {
    from {
        opacity: 0;
        transform: translateY(10px);
    }
}

.sede-grid {
    display: grid;
    grid-template-columns: minmax(0, 0.8fr) minmax(0, 1.2fr);
    gap: clamp(2rem, 5vw, 4rem);
}

.sede-title {
    font-family: var(--font-display);
    font-weight: 400;
    font-size: clamp(1.7rem, 3vw, 2.2rem);
    line-height: 1.1;
    letter-spacing: -0.01em;
}

.sede-addr {
    display: flex;
    align-items: flex-start;
    gap: 0.5rem;
    margin-top: 1rem;
    font-weight: 500;
}

.sede-addr svg {
    width: 20px;
    height: 20px;
    flex: none;
    margin-top: 0.2em;
    color: var(--ink-soft);
}

.sede-addr a {
    text-decoration: underline;
    text-decoration-color: var(--rail);
}

.sede-addr a:hover {
    text-decoration-color: currentColor;
}

.sede-note {
    margin-top: 1rem;
    color: var(--ink-soft);
    max-width: 34ch;
}

/* Lista de clases apoyada en rieles */
.class-list {
    border-top: 1px solid var(--rail);
}

.class-row {
    display: grid;
    grid-template-columns: 24px minmax(8rem, 12rem) 1fr;
    align-items: baseline;
    column-gap: 1rem;
    padding: 1.1rem 0;
    border-bottom: 1px solid var(--rail);
}

.class-row::before {
    content: '';
    align-self: start;
    margin-top: 0.6rem;
    width: 24px;
    height: 10px;
    background: var(--swatch, var(--rail));
    -webkit-mask: var(--spring-mask) center / 100% 100% no-repeat;
    mask: var(--spring-mask) center / 100% 100% no-repeat;
}

/* En Fit cada actividad lleva su ícono propio en lugar del resorte */
.class-row.has-icon {
    grid-template-columns: 44px minmax(8rem, 12rem) 1fr;
}

.class-row.has-icon::before {
    display: none;
}

.class-row-icon {
    align-self: start;
    width: 44px;
    height: 44px;
    margin-top: -0.6rem;
    padding: 3px;
    border-radius: 50%;
    color: var(--navy);
    background: rgba(27, 41, 69, 0.08);
    background: color-mix(in srgb, var(--swatch, var(--navy)) 17%, transparent);
}

.class-row-name {
    font-family: var(--font-display);
    font-size: 1.2rem;
    font-weight: 500;
    line-height: 1.25;
    color: var(--navy);
}

.class-row-desc {
    color: var(--ink-soft);
}

/* Resorte chico que marca el color de cada clase */
:root {
    --spring-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 10'%3E%3Cpath d='M4.65 8.60 L4.40 8.42 L4.20 7.91 L4.09 7.12 L4.11 6.11 L4.28 5.00 L4.60 3.89 L5.07 2.88 L5.67 2.09 L6.36 1.58 L7.10 1.40 M9.55 8.60 L9.30 8.42 L9.10 7.91 L8.99 7.12 L9.01 6.11 L9.18 5.00 L9.50 3.89 L9.97 2.88 L10.57 2.09 L11.26 1.58 L12.00 1.40 M14.45 8.60 L14.20 8.42 L14.00 7.91 L13.89 7.12 L13.91 6.11 L14.08 5.00 L14.40 3.89 L14.87 2.88 L15.47 2.09 L16.16 1.58 L16.90 1.40 M19.35 8.60 L19.10 8.42 L18.90 7.91 L18.79 7.12 L18.81 6.11 L18.97 5.00 L19.30 3.89 L19.77 2.88 L20.37 2.09 L21.06 1.58 L21.80 1.40' fill='none' stroke='black' stroke-opacity='0.5' stroke-width='1' stroke-linecap='round'/%3E%3Cpath d='M0 5.00 L2.20 1.40 M2.20 1.40 L2.94 1.58 L3.63 2.09 L4.23 2.88 L4.70 3.89 L5.03 5.00 L5.19 6.11 L5.21 7.12 L5.10 7.91 L4.90 8.42 L4.65 8.60 M7.10 1.40 L7.84 1.58 L8.53 2.09 L9.13 2.88 L9.60 3.89 L9.93 5.00 L10.09 6.11 L10.11 7.12 L10.00 7.91 L9.80 8.42 L9.55 8.60 M12.00 1.40 L12.74 1.58 L13.43 2.09 L14.03 2.88 L14.50 3.89 L14.83 5.00 L14.99 6.11 L15.01 7.12 L14.90 7.91 L14.70 8.42 L14.45 8.60 M16.90 1.40 L17.64 1.58 L18.33 2.09 L18.93 2.88 L19.40 3.89 L19.73 5.00 L19.89 6.11 L19.91 7.12 L19.80 7.91 L19.60 8.42 L19.35 8.60 M21.80 1.40 L24.00 5.00' fill='none' stroke='black' stroke-width='1.4' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
}

[data-spring="red"] { --swatch: var(--spring-red); }
[data-spring="yellow"] { --swatch: var(--spring-yellow); }
[data-spring="green"] { --swatch: var(--spring-green); }
[data-spring="blue"] { --swatch: var(--spring-blue); }

/* Grilla */
.schedule {
    margin-top: clamp(3rem, 6vw, 4.5rem);
}

.schedule-head {
    display: flex;
    flex-wrap: wrap;
    align-items: baseline;
    justify-content: space-between;
    gap: 0.75rem 2rem;
    margin-bottom: 1.25rem;
}

.schedule-title {
    font-family: var(--font-display);
    font-weight: 400;
    font-size: 1.5rem;
}

/* Grilla con el estilo original del estudio: celdas grises separadas y horas en marino */
.table-wrap {
    overflow-x: auto;
    background: var(--surface);
    border-radius: 15px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.2);
    padding: 1rem;
}

.schedule-table {
    width: 100%;
    min-width: 700px;
    border-collapse: separate;
    border-spacing: 5px;
    font-variant-numeric: tabular-nums;
}

.schedule-table th,
.schedule-table td {
    padding: 15px;
    text-align: center;
    vertical-align: middle;
    border-radius: 10px;
}

.schedule-table thead th {
    background: transparent;
    color: var(--navy);
    font-weight: 700;
    text-transform: uppercase;
    font-size: 0.9rem;
    letter-spacing: 1px;
}

.schedule-table td {
    background: #F8F9FA;
    border: 1px solid #EEEEEE;
    color: var(--ink);
}

.schedule-table tbody th {
    font-weight: 700;
    background: var(--navy);
    color: var(--on-navy);
}

.class-name {
    display: inline-block;
    font-weight: 600;
    color: var(--navy);
    font-size: 0.95rem;
    line-height: 1.3;
}

.t-short {
    display: none;
    text-decoration: none;
}

.sedes-cta {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 1rem 2rem;
    margin-top: 3rem;
    padding-top: 2rem;
    border-top: 1px solid var(--rail);
}

.sedes-cta p {
    font-family: var(--font-display);
    font-size: 1.3rem;
    max-width: 36ch;
}

/* --------------------------------------------------------------------------
   Reseñas
   -------------------------------------------------------------------------- */

.reviews {
    background: var(--navy);
    color: var(--on-navy);
    padding: clamp(4rem, 9vw, 7rem) 0;
}

.reviews .section-title {
    max-width: 16ch;
    margin-bottom: 3rem;
}

.quotes {
    columns: 3 18rem;
    column-gap: clamp(1.5rem, 3vw, 3rem);
}

.quote {
    break-inside: avoid;
    padding: 1.5rem 0;
    border-top: 1px solid var(--navy-line);
}

.quote blockquote p {
    color: var(--on-navy);
    font-size: 1.02rem;
}

.quote-lead {
    column-span: all;
    padding: 0 0 2.5rem;
    border-top: 0;
}

.quote-lead blockquote p {
    font-family: var(--font-display);
    font-weight: 300;
    font-size: clamp(1.45rem, 3vw, 2.2rem);
    line-height: 1.3;
    max-width: 34ch;
    text-wrap: pretty;
}

.quote-author {
    margin-top: 0.7rem;
    font-size: 0.9rem;
    font-weight: 600;
    color: var(--on-navy-soft);
}

.quote-author::before {
    content: '';
    display: inline-block;
    width: 18px;
    height: 1px;
    margin-right: 0.5rem;
    vertical-align: middle;
    background: currentColor;
}

/* --------------------------------------------------------------------------
   Equipo
   -------------------------------------------------------------------------- */

.team {
    padding: clamp(4rem, 9vw, 7rem) 0;
}

.team .section-title {
    margin-bottom: 2.5rem;
}

.team-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: clamp(1.5rem, 3vw, 2.5rem) clamp(1rem, 2.5vw, 2rem);
}

.person img {
    width: 100%;
    height: auto;
    aspect-ratio: 4 / 5;
    object-fit: cover;
    border-radius: var(--radius);
    background: var(--surface);
}

.person-name {
    margin-top: 0.9rem;
    font-family: var(--font-display);
    font-weight: 500;
    font-size: 1.3rem;
    line-height: 1.2;
    color: var(--navy);
}

.person-role {
    margin-top: 0.15rem;
    color: var(--ink-soft);
    font-size: 0.95rem;
}

/* --------------------------------------------------------------------------
   Contacto
   -------------------------------------------------------------------------- */

.contact {
    background: var(--navy);
    color: var(--on-navy);
    padding-top: clamp(4rem, 9vw, 7rem);
    padding-bottom: 2.5rem;
}

.contact-grid {
    display: grid;
    grid-template-columns: 1.2fr 1fr;
    gap: clamp(2.5rem, 6vw, 5rem);
    align-items: center;
    padding-bottom: clamp(3rem, 6vw, 4.5rem);
}

.contact-title {
    font-family: var(--font-display);
    font-weight: 300;
    font-size: clamp(3.2rem, 9vw, 6rem);
    line-height: 0.95;
    letter-spacing: -0.03em;
}

.contact-text {
    margin-top: 1.25rem;
    color: var(--on-navy-soft);
    max-width: 38ch;
}

.contact-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
    margin-top: 2rem;
}

.places {
    display: grid;
    gap: 0;
}

.place {
    padding: 1.4rem 0;
    border-top: 1px solid var(--navy-line);
}

.place:last-child {
    border-bottom: 1px solid var(--navy-line);
}

.place-name {
    font-family: var(--font-display);
    font-weight: 400;
    font-size: 1.4rem;
}

.place-addr {
    margin-top: 0.25rem;
    color: var(--on-navy-soft);
}

.place-link {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    min-height: 44px;
    font-weight: 600;
    text-decoration: none;
}

.place-link svg {
    width: 18px;
    height: 18px;
    transition: transform 0.25s var(--ease-out);
}

.place-link:hover svg {
    transform: translateX(3px);
}

.site-footer {
    background: var(--navy-deep);
    color: var(--on-navy-soft);
    font-size: 0.9rem;
    padding: 1rem var(--gutter) 6rem;
    align-items: center;
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    gap: 0.5rem 2rem;
}

.site-footer a {
    display: inline-block;
    padding: 0.7rem 0;
    color: var(--on-navy);
    font-weight: 600;
}

/* --------------------------------------------------------------------------
   WhatsApp flotante
   -------------------------------------------------------------------------- */

.wa-float {
    position: fixed;
    right: max(1rem, env(safe-area-inset-right));
    bottom: max(1rem, env(safe-area-inset-bottom));
    z-index: 900;
    display: inline-flex;
    align-items: center;
    gap: 0.55rem;
    min-height: 56px;
    padding: 0 1.3rem 0 1.1rem;
    border-radius: 999px;
    background: #12803D;
    color: #FFFFFF;
    font-weight: 600;
    text-decoration: none;
    box-shadow: 0 10px 24px -8px rgba(0, 0, 0, 0.3);
    transform: translateY(0);
    transition: transform 0.35s var(--ease-out), opacity 0.35s ease, background-color 0.2s ease;
}

.wa-float svg {
    width: 26px;
    height: 26px;
}

.wa-float:hover {
    background: #0F7236;
}

.wa-float.is-hidden {
    opacity: 0;
    transform: translateY(24px);
    pointer-events: none;
}

/* --------------------------------------------------------------------------
   Responsive
   -------------------------------------------------------------------------- */

@media (max-width: 1020px) {
    .team-grid {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }
}

@media (max-width: 900px) {
    .menu-btn {
        display: grid;
    }

    .nav-links {
        position: absolute;
        top: var(--header-h);
        left: 0;
        right: 0;
        flex-direction: column;
        align-items: stretch;
        gap: 0;
        padding: 0.5rem var(--gutter) 1.25rem;
        background: var(--navy);
        border-top: 1px solid var(--navy-line);
        box-shadow: 0 16px 30px -12px rgba(0, 0, 0, 0.3);
        display: none;
    }

    .nav-links.is-open {
        display: flex;
    }

    .nav-links a:not(.btn) {
        min-height: 52px;
        padding: 0;
        font-size: 1.1rem;
        border-bottom: 1px solid var(--navy-line);
    }

    .nav-cta {
        margin: 1rem 0 0;
    }

    .nav-cta .btn {
        width: 100%;
    }

    .hero-inner {
        grid-template-columns: 1fr;
        gap: 0;
    }

    .hero-copy {
        padding-bottom: 2.5rem;
    }

    .sede-grid {
        grid-template-columns: 1fr;
        gap: 2rem;
    }

    .contact-grid {
        grid-template-columns: 1fr;
    }


}

/* Celular y tablet chica: la grilla entera entra en el ancho de la pantalla.
   script.js calcula --grid-font para que la palabra más larga entre sin cortarse. */
@media (max-width: 760px) {
    .table-wrap {
        margin: 0 calc(var(--gutter) * -1 + 6px);
        padding: 3px;
        border-radius: 12px;
        overflow: visible;
    }

    .schedule-table {
        min-width: 0;
        table-layout: fixed;
        border-spacing: 2px;
    }

    .schedule-table th,
    .schedule-table td {
        padding: 8px 2px;
        border-radius: 6px;
        font-size: var(--grid-font, 0.7rem);
        line-height: 1.2;
        overflow-wrap: normal;
        word-break: normal;
        hyphens: manual;
    }

    .schedule-table thead th {
        font-size: var(--grid-font, 0.7rem);
        letter-spacing: 0;
        padding: 6px 0;
    }

    .schedule-table thead th:first-child,
    .schedule-table tbody th {
        width: 2.1rem;
        font-size: 0.66rem;
    }

    .class-name {
        font-size: var(--grid-font, 0.7rem);
        line-height: 1.2;
    }

    .t-full {
        display: none;
    }

    .t-short {
        display: inline;
    }
}

@media (max-width: 640px) {
    body {
        font-size: 1rem;
    }

    .brand-name span {
        display: none;
    }

    .hero-title {
        font-size: clamp(3.4rem, 19vw, 4.6rem);
    }

    .hero-actions .btn {
        flex: 1 1 100%;
    }

    .switch {
        grid-template-columns: 3.25rem 1fr 1fr;
    }

    .switch-tab {
        min-width: 0;
        padding: 0.55rem 0.8rem;
    }

    .switch-name {
        font-size: 1.3rem;
    }

    .switch-addr {
        font-size: 0.8125rem;
    }

    .class-row {
        grid-template-columns: 24px 1fr;
        row-gap: 0.25rem;
    }

    .class-row.has-icon {
        grid-template-columns: 44px 1fr;
    }

    .class-row-desc {
        grid-column: 2;
    }

    .team-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .contact-actions .btn {
        flex: 1 1 100%;
    }

    .wa-float {
        padding: 0;
        width: 56px;
        justify-content: center;
    }

    .wa-float span {
        position: absolute;
        width: 1px;
        height: 1px;
        overflow: hidden;
        clip: rect(0, 0, 0, 0);
    }
}

@media (prefers-reduced-motion: reduce) {
    html {
        scroll-behavior: auto;
    }

    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
}
