/* Parque de Milo — Centro de Bienestar Canino
   Design system: design-system/parque-de-milo/MASTER.md
   Motion & materials follow design-system/parque-de-milo/SKILL.md (Apple design) */
:root {
  /* Brand */
  --forest: #004421;
  --green: #2b6c53;
  --cream: #fbeedb;
  --white: #ffffff;
  --orange: #de6c21;
  --teal: #1f8892;
  /* Text-safe variants (≥4.5:1 on cream) */
  --orange-ink: #a94c0d;
  --teal-ink: #17707a;
  --ink: #12301f;
  --muted: #3d5a4a;
  --hairline: rgba(0, 68, 33, .10);

  /* Materials: only floating layers get depth; bigger surfaces read thicker */
  --glass: rgba(251, 238, 219, .72);
  --glass-light: rgba(255, 255, 255, .9); /* menu/card sit over busy content: keep text legible */
  --shadow-chip: 0 2px 10px rgba(0, 68, 33, .08);
  --shadow-float: 0 10px 30px rgba(0, 68, 33, .14);
  --shadow-sheet: 0 24px 60px rgba(0, 68, 33, .22);

  /* Shape & layout */
  --radius: 24px;
  --radius-lg: 32px;
  --max: 72.5rem;
  --header-h: 4.5rem;

  /* Motion: critically damped spring (damping 1.0, response ≈0.4s) sampled for CSS */
  --spring: linear(0, .186 10%, .465 20%, .682 30%, .821 40%, .903 50%, .949 60%, .973 70%, .986 80%, .993 90%, 1);
  --spring-dur: 500ms;
  --press: 100ms ease-out;

  --font-head: "Outfit", system-ui, sans-serif;
  --font-body: "Nunito Sans", system-ui, sans-serif;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: calc(var(--header-h) + 1rem); interpolate-size: allow-keywords; }
body {
  margin: 0;
  font-family: var(--font-body);
  font-size: 1.0625rem;
  line-height: 1.6;
  letter-spacing: 0;
  color: var(--ink);
  background: var(--cream);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}
img { max-width: 100%; display: block; }
a { color: var(--green); }
a, button, select, summary { touch-action: manipulation; -webkit-tap-highlight-color: transparent; }

/* Type: tracking and leading tighten as size grows */
h1, h2, h3, h4 { font-family: var(--font-head); color: var(--forest); margin: 0 0 .5em; text-wrap: balance; font-optical-sizing: auto; }
h1 { font-size: clamp(2.6rem, 6.4vw, 4.75rem); line-height: 1.04; letter-spacing: -.03em; font-weight: 700; }
h2 { font-size: clamp(2rem, 4.2vw, 3.1rem); line-height: 1.08; letter-spacing: -.022em; font-weight: 700; }
h3 { font-size: 1.3rem; line-height: 1.25; letter-spacing: -.01em; font-weight: 600; }
p { margin: 0 0 1em; text-wrap: pretty; }

.container { width: min(var(--max), 100% - 2rem); margin-inline: auto; }
.skip { position: absolute; left: -999px; top: .5rem; background: var(--forest); color: var(--white); padding: .6rem 1rem; border-radius: .6rem; z-index: 100; }
.skip:focus { left: .5rem; }
:focus-visible { outline: 3px solid var(--orange); outline-offset: 3px; border-radius: 8px; }

/* ── Header: translucent material, content scrolls underneath ── */
.site-header { position: sticky; top: 0; z-index: 50; background: var(--glass); backdrop-filter: blur(20px) saturate(180%); -webkit-backdrop-filter: blur(20px) saturate(180%); }
/* Scroll-edge effect instead of a hard divider — only once content is underneath */
.site-header::after { content: ""; position: absolute; left: 0; right: 0; top: 100%; height: 18px; background: linear-gradient(rgba(0, 68, 33, .08), transparent); opacity: 0; transition: opacity 200ms ease; pointer-events: none; }
.site-header.scrolled::after { opacity: 1; }
.nav { display: flex; align-items: center; justify-content: space-between; gap: 1rem; min-height: var(--header-h); }
.brand { display: flex; align-items: center; gap: .75rem; text-decoration: none; color: var(--forest); min-height: 44px; }
.brand img { width: 52px; height: 52px; }
.brand span { font-family: var(--font-head); font-weight: 700; line-height: 1.1; font-size: 1.05rem; letter-spacing: -.01em; }
.brand small { display: block; font-weight: 500; font-size: .72rem; letter-spacing: .1em; text-transform: uppercase; color: var(--green); margin-top: 2px; }
.nav-links { display: flex; align-items: center; gap: 2px; list-style: none; margin: 0; padding: 0; }
.nav-links a { display: flex; align-items: center; min-height: 44px; padding: 0 .8rem; border-radius: 999px; text-decoration: none; color: var(--forest); font-weight: 700; font-size: .94rem; transition: background 150ms ease, transform var(--press); }
.nav-links a:hover { background: rgba(43, 108, 83, .09); }
.nav-links a:active { transform: scale(.96); }
.nav-links a[aria-current="page"] { background: var(--forest); color: var(--white); }
.nav-toggle { display: none; width: 48px; height: 48px; place-items: center; background: none; border: 0; border-radius: 14px; cursor: pointer; color: var(--forest); transition: background 150ms ease, transform var(--press); }
.nav-toggle:active { transform: scale(.92); background: rgba(43, 108, 83, .1); }
.nav-toggle svg { width: 26px; height: 26px; }

/* Mobile menu: a sheet that materializes from the toggle and returns the same way */
@media (max-width: 1060px) {
  .nav-toggle { display: grid; }
  .nav-links {
    position: absolute; top: calc(100% + .5rem); right: 1rem; left: 1rem;
    flex-direction: column; align-items: stretch; gap: 2px; padding: .6rem;
    background: var(--glass-light); backdrop-filter: blur(24px) saturate(180%); -webkit-backdrop-filter: blur(24px) saturate(180%);
    border: 1px solid rgba(255, 255, 255, .6); border-radius: var(--radius); box-shadow: var(--shadow-sheet);
    max-height: calc(100dvh - var(--header-h) - 2rem); overflow-y: auto;
    transform-origin: top right;
    opacity: 0; visibility: hidden; transform: scale(.92) translateY(-8px);
    transition: opacity 180ms ease, transform var(--spring-dur) var(--spring), visibility 0s linear var(--spring-dur);
  }
  .nav-links.open { opacity: 1; visibility: visible; transform: none; transition: opacity 180ms ease, transform var(--spring-dur) var(--spring), visibility 0s; }
  .nav-links a { min-height: 50px; padding: 0 1rem; font-size: 1.08rem; border-radius: 14px; }
}

/* ── Buttons: feedback on press-down, instantly. Labels 18px bold (large-text contrast on orange) ── */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: .6rem; min-height: 52px; padding: .75rem 1.6rem; border-radius: 999px; font-family: var(--font-head); font-weight: 700; font-size: 1.125rem; line-height: 1.2; letter-spacing: -.005em; text-decoration: none; border: 2px solid transparent; cursor: pointer; transition: background 150ms ease, color 150ms ease, transform var(--press); }
.btn:active { transform: scale(.97); }
.btn[disabled] { opacity: .6; cursor: progress; transform: none; }
.btn-primary { background: var(--orange); color: var(--white); }
.btn-primary:hover { background: #c95e1a; }
.btn-outline { border-color: var(--forest); color: var(--forest); background: transparent; }
.btn-outline:hover { background: var(--forest); color: var(--white); }
.btn-light { background: var(--cream); color: var(--forest); }
.btn-light:hover { background: var(--white); }
.btn svg { width: 22px; height: 22px; flex: none; }
.btn-row { display: flex; flex-wrap: wrap; align-items: center; gap: .75rem 1.5rem; }
.btn-row.center { justify-content: center; }

/* Text link with chevron — the quiet secondary action */
.link-more { display: inline-flex; align-items: center; gap: .3rem; min-height: 44px; font-family: var(--font-head); font-weight: 700; font-size: 1.125rem; color: var(--green); text-decoration: none; }
.link-more::after { content: "›"; font-size: 1.4em; line-height: 1; transition: transform 200ms var(--spring); }
.link-more:hover { text-decoration: underline; text-underline-offset: 4px; }
.link-more:hover::after { transform: translateX(3px); }
.link-more:active { opacity: .7; }

/* ── Sections ── */
section { padding: 6.5rem 0; }
.bg-white { background: var(--white); }
.bg-green { background: var(--green); color: var(--white); }
.bg-forest { background: var(--forest); color: var(--white); }
.bg-green h2, .bg-green h3, .bg-forest h2, .bg-forest h3 { color: var(--white); }
.bg-green a:not(.btn), .bg-forest a:not(.btn) { color: var(--cream); }
.eyebrow { display: inline-block; font-family: var(--font-head); font-weight: 600; font-size: .8rem; letter-spacing: .14em; text-transform: uppercase; color: var(--orange-ink); margin-bottom: .9rem; }
.eyebrow.teal { color: var(--teal-ink); }
.bg-green .eyebrow, .bg-forest .eyebrow { color: var(--cream); }
.lead { font-size: clamp(1.15rem, 1.6vw, 1.3rem); line-height: 1.55; max-width: 60ch; color: var(--muted); }
.bg-green .lead, .bg-forest .lead { color: rgba(255, 255, 255, .9); }
.center { text-align: center; }
.center .lead { margin-inline: auto; }
.section-head { margin-bottom: 3.5rem; }

/* Wave divider echoing the logo's hills */
.wave { display: block; width: 100%; height: 70px; margin-bottom: -1px; }

/* ── Hero ── */
.hero { padding: 4.5rem 0 3rem; position: relative; overflow: hidden; }
.hero::before { content: ""; position: absolute; left: 50%; top: -260px; width: 900px; aspect-ratio: 1; translate: -50% 0; border-radius: 50%; background: radial-gradient(circle, rgba(222, 108, 33, .14), transparent 62%); pointer-events: none; }
.hero-center { position: relative; text-align: center; max-width: 54rem; }
.hero-center .lead { margin: 0 auto 2rem; }
.hero h1 span { color: var(--orange); }
.hero-media { position: relative; margin-top: 3.5rem; }
.hero-video { display: block; width: 100%; height: auto; aspect-ratio: 16 / 9; object-fit: cover; border-radius: var(--radius-lg); background: var(--forest); }
.video-toggle { position: absolute; top: 1rem; right: 1rem; display: grid; place-items: center; width: 44px; height: 44px; padding: 0; border: 0; border-radius: 50%; background: rgba(0, 68, 33, .72); color: var(--white); cursor: pointer; transition: background 150ms ease, transform var(--press); }
.video-toggle[hidden] { display: none; }
.video-toggle:hover { background: var(--forest); }
.video-toggle:active { transform: scale(.92); }
.video-toggle svg { width: 22px; height: 22px; }
.video-toggle .icon-play, .video-toggle.paused .icon-pause { display: none; }
.video-toggle.paused .icon-play { display: block; }
/* Floating card: a light material over the photo */
.float-card { position: absolute; left: 1.5rem; bottom: 1.5rem; display: flex; gap: .75rem; align-items: center; max-width: 290px; padding: .85rem 1.1rem; border-radius: 20px; background: var(--glass-light); backdrop-filter: blur(20px) saturate(180%); -webkit-backdrop-filter: blur(20px) saturate(180%); border: 1px solid rgba(255, 255, 255, .7); box-shadow: var(--shadow-float); }
.float-card img { width: 46px; height: 46px; flex: none; }
.float-card strong { display: block; font-family: var(--font-head); color: var(--forest); line-height: 1.2; letter-spacing: -.01em; }
.float-card span { font-size: .86rem; color: var(--muted); line-height: 1.3; display: block; font-weight: 600; }
.page-hero { padding: 4.5rem 0 4rem; }
.page-hero .lead { margin-bottom: 0; }
@media (max-width: 760px) {
  .hero { padding-top: 3rem; }
  /* Below the video on phones, so it doesn't cover the dogs */
  .float-card { position: static; max-width: none; margin-top: .75rem; }
}

/* Photo placeholders — replace each .ph with <img class="photo" src="..." alt="..." width="..." height="..." loading="lazy"> */
.ph { position: relative; border-radius: var(--radius-lg); background: linear-gradient(140deg, var(--green), var(--forest)); aspect-ratio: 4 / 3; display: grid; place-items: center; color: rgba(251, 238, 219, .9); overflow: hidden; }
.ph.tall { aspect-ratio: 4 / 5; }
.ph::before { content: ""; width: min(34%, 180px); aspect-ratio: 1; background: url("paw.svg") center / contain no-repeat; opacity: .22; }
.ph::after { content: attr(data-label); position: absolute; top: 1rem; right: 1.25rem; font-size: .82rem; font-weight: 700; }
.photo { border-radius: var(--radius-lg); width: 100%; height: 100%; object-fit: cover; }

/* ── Grids & tiles (flat; depth is reserved for floating layers) ── */
.grid { display: grid; gap: 1.25rem; }
.grid-2 { grid-template-columns: repeat(2, 1fr); }
.grid-3 { grid-template-columns: repeat(3, 1fr); }
.grid-4 { grid-template-columns: repeat(4, 1fr); }
@media (max-width: 960px) { .grid-3, .grid-4 { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 640px) { .grid-2, .grid-3, .grid-4 { grid-template-columns: 1fr; } }
.card { position: relative; background: var(--white); border-radius: var(--radius); padding: 2rem; display: flex; flex-direction: column; transition: transform var(--press), box-shadow 250ms ease; }
.card.flat, .bg-white .card, .bg-white .fact { background: var(--cream); }
.card h2 { font-size: clamp(1.5rem, 2.4vw, 1.9rem); }
.card:has(.card-link) p:last-of-type { flex-grow: 1; } /* aligns "Ver más" links */
.card .icon { width: 52px; height: 52px; border-radius: 15px; display: grid; place-items: center; background: var(--cream); color: var(--orange); margin-bottom: 1.25rem; }
.card .icon svg { width: 28px; height: 28px; }
/* Whole tile is clickable via the stretched link; it responds on press */
.card-link { font-family: var(--font-head); font-weight: 700; text-decoration: none; color: var(--orange-ink); display: inline-flex; gap: .3rem; align-items: center; min-height: 44px; }
.card-link::after { content: ""; position: absolute; inset: 0; border-radius: var(--radius); }
.card:has(.card-link):hover { box-shadow: var(--shadow-float); }
.card:has(.card-link):hover .card-link { text-decoration: underline; text-underline-offset: 4px; }
.card:has(.card-link:active) { transform: scale(.98); }
.card-teal { border-top: 6px solid var(--teal); }
.card .tag { align-self: flex-start; background: rgba(31, 136, 146, .12); color: var(--teal-ink); font-weight: 700; font-size: .82rem; border-radius: 999px; padding: .25rem .75rem; margin-bottom: .9rem; }
.bg-green .card, .bg-forest .card { color: var(--ink); }
.bg-green .card h3, .bg-forest .card h3 { color: var(--forest); }

/* Expandable program details (Formación): height springs open from its current value */
.programs { align-items: start; }
.more { margin-top: .5rem; border-top: 1px solid var(--hairline); }
.more summary { display: flex; align-items: center; justify-content: space-between; gap: .75rem; min-height: 56px; padding-top: .75rem; cursor: pointer; list-style: none; font-family: var(--font-head); font-weight: 700; font-size: 1.05rem; color: var(--teal-ink); border-radius: 12px; }
.more summary::-webkit-details-marker { display: none; }
.more summary::after { content: ""; flex: none; width: 34px; height: 34px; border-radius: 50%; background: rgba(31, 136, 146, .12) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%2317707a' stroke-width='2.5' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E") center / 18px no-repeat; transition: transform var(--spring-dur) var(--spring); }
.more[open] summary::after { transform: rotate(180deg); }
.more summary:active::after { scale: .9; }
.more .when-open, .more[open] .when-closed { display: none; }
.more[open] .when-open { display: inline; }
.more::details-content { block-size: 0; overflow: clip; transition: block-size var(--spring-dur) var(--spring), content-visibility var(--spring-dur) allow-discrete; }
.more[open]::details-content { block-size: auto; }
.more-body { padding-top: 1rem; }
.more-body h4 { color: var(--forest); font-size: 1.05rem; letter-spacing: -.005em; margin: 1.1rem 0 .35rem; }
.more-body h4:first-child { margin-top: 0; }
.more-body .chips li { background: var(--cream); }

/* Split layout */
.split { display: grid; grid-template-columns: 1fr 1fr; gap: 3.5rem; align-items: center; }
@media (max-width: 860px) { .split { grid-template-columns: 1fr; gap: 2rem; } }

/* Lists */
.check { list-style: none; padding: 0; margin: 0 0 1.4em; }
.check li { position: relative; padding-left: 2.1rem; margin-bottom: .65rem; }
.check li::before { content: ""; position: absolute; left: 0; top: .2em; width: 22px; height: 22px; border-radius: 50%; background: var(--orange) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='white' stroke-width='3.5' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M5 12l5 5L20 7'/%3E%3C/svg%3E") center / 13px no-repeat; }
.chips { display: flex; flex-wrap: wrap; gap: .5rem; list-style: none; padding: 0; margin: 0 0 1.4em; }
.chips li { background: var(--white); color: var(--forest); border-radius: 999px; padding: .35rem .9rem; font-weight: 700; font-size: .9rem; }

/* Proof strip */
.facts { display: grid; grid-template-columns: repeat(4, 1fr); gap: 1rem; }
.fact { background: var(--white); border-radius: var(--radius); padding: 1.6rem 1.25rem; text-align: center; }
.fact svg { width: 30px; height: 30px; color: var(--orange); margin: 0 auto .6rem; display: block; }
.fact strong { display: block; font-family: var(--font-head); font-size: 1.5rem; letter-spacing: -.015em; color: var(--forest); line-height: 1.2; }
.fact span { font-size: .95rem; color: var(--muted); font-weight: 600; }
@media (max-width: 760px) { .facts { grid-template-columns: repeat(2, 1fr); } }

/* Steps */
.steps { counter-reset: step; list-style: none; padding: 0; margin: 0; display: grid; gap: .75rem; }
.steps li { counter-increment: step; position: relative; padding: 1.35rem 1.35rem 1.35rem 5rem; background: var(--white); border-radius: var(--radius); }
.bg-white .steps li { background: var(--cream); }
.steps li::before { content: counter(step); position: absolute; left: 1.35rem; top: 1.25rem; width: 40px; height: 40px; border-radius: 50%; background: var(--forest); color: var(--white); font-family: var(--font-head); font-weight: 700; display: grid; place-items: center; }
.steps h3 { margin-bottom: .25em; font-size: 1.15rem; }
.steps p { margin: 0; color: var(--muted); }

/* Highlight tile (cortisol protocol) */
.highlight { background: var(--white); border-radius: var(--radius-lg); padding: 3rem; }
@media (max-width: 640px) { .highlight { padding: 1.75rem 1.4rem; } }

/* Trust logos */
.trust { padding: 3.5rem 0 1rem; }
.trust p { text-align: center; font-weight: 700; color: var(--muted); margin-bottom: 1.25rem; }
.logos { display: grid; grid-template-columns: repeat(5, 1fr); gap: 1rem; }
.logo-ph { border: 2px dashed rgba(0, 68, 33, .22); border-radius: 18px; min-height: 84px; display: grid; place-items: center; text-align: center; padding: .75rem; color: var(--green); font-weight: 700; font-size: .9rem; }
@media (max-width: 860px) { .logos { grid-template-columns: repeat(2, 1fr); } }

/* Certification badge */
.cert { display: flex; gap: 1.25rem; align-items: center; background: rgba(31, 136, 146, .08); border: 2px solid var(--teal); border-radius: var(--radius); padding: 1.4rem 1.6rem; }
.cert h2 { font-size: 1.3rem; letter-spacing: -.01em; margin-bottom: .2em; }
.cert p { margin: 0; }
.cert .logo-ph { flex: none; width: 110px; min-height: 80px; border-color: var(--teal); color: var(--teal-ink); }
@media (max-width: 560px) { .cert { flex-direction: column; text-align: center; } }

/* CTA band */
.cta { position: relative; overflow: hidden; background: var(--forest); color: var(--white); border-radius: var(--radius-lg); padding: 3.5rem; display: grid; grid-template-columns: 1fr auto; gap: 2rem; align-items: center; }
.cta::after { content: ""; position: absolute; right: -60px; bottom: -80px; width: 260px; aspect-ratio: 1; background: url("paw.svg") center / contain no-repeat; opacity: .06; pointer-events: none; }
.cta h2 { color: var(--white); margin-bottom: .3em; }
.cta p { margin: 0; opacity: .9; }
@media (max-width: 760px) { .cta { grid-template-columns: 1fr; padding: 2.25rem 1.5rem; } }

/* ── Forms ── */
.form { display: grid; gap: 1.1rem; }
.form label { font-weight: 700; color: var(--forest); display: block; margin-bottom: .35rem; }
.req { color: var(--orange-ink); }
.form-note { font-size: .9rem; color: var(--muted); margin: 0; }
.form input, .form select, .form textarea { width: 100%; min-height: 50px; font: inherit; padding: .75rem 1rem; border-radius: 14px; border: 2px solid rgba(0, 68, 33, .18); background: var(--white); color: var(--ink); transition: border-color 150ms ease, box-shadow 150ms ease; }
.form input:focus, .form select:focus, .form textarea:focus { border-color: var(--green); outline: none; box-shadow: 0 0 0 4px rgba(43, 108, 83, .2); }
.form input:user-invalid, .form textarea:user-invalid { border-color: #b3261e; }
.form textarea { min-height: 150px; resize: vertical; }
.form .row { display: grid; grid-template-columns: 1fr 1fr; gap: 1.1rem; }
@media (max-width: 560px) { .form .row { grid-template-columns: 1fr; } }
.hp { position: absolute; left: -9999px; }
.notice { display: none; padding: 1rem 1.25rem; border-radius: 14px; font-weight: 700; margin-bottom: 1.25rem; }
.notice:target { display: block; }
#enviado { background: rgba(43, 108, 83, .15); color: var(--forest); }
#error, #limite { background: rgba(222, 108, 33, .15); color: #7a3508; }

.contact-list { list-style: none; padding: 0; margin: 0 0 1.5rem; display: grid; gap: 1rem; }
.contact-list li { display: flex; gap: .9rem; align-items: flex-start; }
.contact-list svg { width: 26px; height: 26px; flex: none; color: var(--orange); margin-top: 2px; }
.map { width: 100%; height: 320px; border: 0; border-radius: var(--radius); }

/* ── Footer ── */
.site-footer { background: var(--forest); color: rgba(255, 255, 255, .86); padding: 4rem 0 1.75rem; font-size: .97rem; }
.site-footer a { color: var(--white); text-decoration: none; display: inline-block; padding: 3px 0; }
.site-footer a:hover { text-decoration: underline; text-underline-offset: 3px; }
.footer-grid { display: grid; grid-template-columns: 1.4fr 1fr 1fr 1fr; gap: 2.25rem; }
.footer-title { color: var(--cream); font-size: .85rem; letter-spacing: .12em; text-transform: uppercase; }
.footer-grid ul { list-style: none; padding: 0; margin: 0; display: grid; gap: .35rem; }
.footer-logo { width: 96px; background: var(--cream); border-radius: 50%; margin-bottom: 1rem; }
.social { display: flex; gap: .75rem; margin-top: .9rem; }
.site-footer .social a { width: 44px; height: 44px; padding: 0; border-radius: 50%; background: rgba(255, 255, 255, .12); display: grid; place-items: center; transition: background 150ms ease, transform var(--press); }
.site-footer .social a:hover { background: rgba(255, 255, 255, .22); }
.site-footer .social a:active { transform: scale(.92); }
.social svg { width: 20px; height: 20px; }
.copy { border-top: 1px solid rgba(255, 255, 255, .14); margin-top: 3rem; padding-top: 1.4rem; font-size: .88rem; display: flex; flex-wrap: wrap; justify-content: space-between; gap: .6rem; }
@media (max-width: 860px) { .footer-grid { grid-template-columns: 1fr 1fr; } }
@media (max-width: 520px) { .footer-grid { grid-template-columns: 1fr; } .site-footer { padding-bottom: 6.5rem; } }

/* Floating WhatsApp */
.wa-float { position: fixed; right: 1.25rem; bottom: 1.25rem; z-index: 60; width: 60px; height: 60px; border-radius: 50%; background: #25d366; color: var(--white); display: grid; place-items: center; box-shadow: var(--shadow-float); transition: transform var(--press); }
.wa-float:active { transform: scale(.92); }
.wa-float svg { width: 32px; height: 32px; }

/* Scroll reveal — springs in once; only when JS runs, so content is never hidden without it */
.js .reveal { opacity: 0; transform: translateY(28px); transition: opacity 400ms ease, transform 700ms var(--spring); transition-delay: var(--d, 0ms); }
.js .reveal.in { opacity: 1; transform: none; }

@media (max-width: 640px) { section { padding: 4.5rem 0; } }

/* ── Status pages (404.html, en-construccion.html) ── */
.status { padding: 4.5rem 0 6rem; text-align: center; }
.status .lead { margin-inline: auto; }
.status .btn-row { justify-content: center; margin-top: 2.25rem; }
.status-code { display: flex; justify-content: center; align-items: center; gap: .04em; font-family: var(--font-head); font-weight: 700; font-size: clamp(6.5rem, 24vw, 12rem); line-height: 1; letter-spacing: -.04em; color: var(--forest); margin-bottom: 1.25rem; }
.status-code svg { width: .8em; height: .8em; fill: var(--orange); transform: rotate(-14deg); }
.quick-links { list-style: none; padding: 0; margin: 3rem auto 0; display: flex; flex-wrap: wrap; justify-content: center; gap: .6rem; }
.quick-links a { display: inline-block; padding: .55rem 1.1rem; border-radius: 999px; background: var(--white); box-shadow: inset 0 0 0 1px var(--hairline); color: var(--forest); font-weight: 600; text-decoration: none; transition: transform var(--press); }
.quick-links a:hover { background: var(--forest); color: var(--white); }
.quick-links a:active { transform: scale(.97); }
/* Paw prints walking in from the left, one step at a time */
.trail { display: flex; justify-content: center; gap: 1.4rem; margin-bottom: 2.5rem; }
.trail svg { width: 48px; height: 48px; fill: var(--teal); opacity: .15; transform: rotate(90deg); animation: step 3s infinite; }
.trail svg:nth-child(odd) { transform: translateY(14px) rotate(90deg); }
.trail svg:nth-child(2) { animation-delay: .4s; }
.trail svg:nth-child(3) { animation-delay: .8s; }
.trail svg:nth-child(4) { animation-delay: 1.2s; }
.trail svg:nth-child(5) { animation-delay: 1.6s; }
@keyframes step { 0%, 100% { opacity: .15; } 15%, 55% { opacity: 1; } }

/* ── Legal text (privacidad.html): a readable column; wide tables scroll sideways on phones ── */
.legal { max-width: 52rem; }
.legal h2 { font-size: clamp(1.5rem, 2.6vw, 1.9rem); margin: 3rem 0 1rem; scroll-margin-top: calc(var(--header-h) + 1rem); }
.legal h2:first-child { margin-top: 0; }
.legal p, .legal li { line-height: 1.65; }
.legal ol, .legal ul { padding-left: 1.4rem; margin-bottom: 1rem; }
.legal li { margin-bottom: .35rem; }
.table-wrap { overflow-x: auto; margin: 1.25rem 0 1.5rem; border-radius: 16px; border: 1px solid var(--hairline); }
.legal table { width: 100%; min-width: 34rem; border-collapse: collapse; font-size: .95rem; }
.legal th, .legal td { text-align: left; vertical-align: top; padding: .8rem 1rem; border-bottom: 1px solid var(--hairline); }
.legal thead th { background: var(--cream); color: var(--forest); font-family: var(--font-head); font-weight: 600; }
.legal tbody th { font-weight: 700; color: var(--forest); }
.legal tbody tr:last-child > * { border-bottom: 0; }

/* ── Cookie notice: analytics only start after "Aceptar" (privacy policy, section 5) ── */
.cookie-bar { position: fixed; z-index: 60; left: 1rem; right: 1rem; bottom: 1rem; max-width: 34rem; padding: 1.1rem 1.25rem; border-radius: 20px; background: var(--white); color: var(--ink); box-shadow: var(--shadow-sheet); font-size: .95rem; }
.cookie-bar p { margin: 0 0 .9rem; line-height: 1.5; }
.cookie-bar a { color: var(--teal-ink); font-weight: 600; }
.cookie-bar .btn-row { gap: .6rem; }
.cookie-bar .btn { min-height: 44px; padding: .5rem 1.2rem; font-size: 1rem; }

/* ── Accessibility preferences ── */
/* Reduced motion: gentle cross-fades instead of movement, not "no feedback" */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .js .reveal { transform: none; transition: opacity 200ms ease; }
  .nav-links, .nav-links.open { transform: none !important; }
  .btn:active, .card:has(.card-link:active), .nav-links a:active, .wa-float:active { transform: none; }
  .more::details-content, .more summary::after, .link-more::after { transition: none; }
}
/* Reduced transparency: frosted layers become solid */
@media (prefers-reduced-transparency: reduce) {
  .site-header { background: var(--cream); backdrop-filter: none; -webkit-backdrop-filter: none; }
  .nav-links, .float-card { background: var(--white) !important; backdrop-filter: none !important; -webkit-backdrop-filter: none !important; }
}
/* Increased contrast: solid surfaces with defined borders */
@media (prefers-contrast: more) {
  .site-header { background: var(--cream); border-bottom: 2px solid var(--forest); }
  .card, .fact, .steps li, .highlight, .float-card { border: 2px solid var(--forest); }
  .lead, .fact span, .steps p, .float-card span { color: var(--ink); }
}

/* ── Inscripción (inscripcion.html) ── */
[hidden] { display: none !important; }
.narrow { width: min(48rem, 100% - 2rem); }
.form-section { padding-top: 0; }
.form fieldset { border: 0; padding: 0; margin: 0; min-width: 0; display: grid; gap: 1.1rem; }
.form legend { font-weight: 700; color: var(--forest); padding: 0; margin-bottom: .35rem; }
.form .step { padding-top: 1.75rem; border-top: 1px solid var(--hairline); }
.form .step:first-of-type { padding-top: 0; border-top: 0; }
.form .step > legend { font-family: var(--font-head); font-size: 1.35rem; line-height: 1.25; letter-spacing: -.01em; margin-bottom: .9rem; }
.choices { display: grid; gap: .6rem; }
.choice-row { display: flex; flex-wrap: wrap; gap: .6rem; }
.choice-row .choice { flex: 1 1 9rem; }
.form .choice { display: flex; gap: .8rem; align-items: flex-start; margin: 0; padding: .9rem 1rem; border-radius: 16px; border: 2px solid rgba(0, 68, 33, .18); background: var(--white); font-weight: 600; cursor: pointer; transition: border-color 150ms ease, background 150ms ease; }
.form .choice:hover { border-color: rgba(43, 108, 83, .5); }
.form .choice:has(:checked) { border-color: var(--green); background: rgba(43, 108, 83, .08); }
.form .choice strong { display: block; color: var(--forest); }
.form .choice small { display: block; color: var(--muted); font-size: .92rem; }
.form .choice input, .form .check-field input { width: 22px; height: 22px; min-height: 0; margin: .15rem 0 0; padding: 0; flex: none; accent-color: var(--green); }
.check-field { display: flex; gap: .75rem; align-items: flex-start; }
.form .check-field label { margin: 0; }
.form .help { display: block; color: var(--muted); font-size: .9rem; font-weight: 400; margin-top: .3rem; }
.form input[type=file] { padding: .6rem; }
.summary { background: var(--cream); border-radius: 16px; padding: 1.1rem 1.25rem; }
.summary p:last-child { margin-bottom: 0; }
.alert { margin: 0; padding: 1rem 1.25rem; border-radius: 14px; font-weight: 700; background: rgba(222, 108, 33, .15); color: #7a3508; }
.alert a { color: inherit; }
.form-done { display: grid; gap: .5rem; justify-items: start; }
.form-done h2:focus { outline: none; }
.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; }
.choices-block { display: grid; gap: 1.75rem; }
.form ::placeholder, .form select:has(option[value=""]:checked) { color: #6b7f74; opacity: 1; }
.form select option { color: var(--ink); }
.form .file-pick { display: flex; align-items: center; justify-content: space-between; gap: 1rem; min-height: 50px; margin: 0; padding: .45rem .45rem .45rem 1rem; border-radius: 14px; border: 2px dashed rgba(0, 68, 33, .25); background: var(--white); color: #6b7f74; font-weight: 400; cursor: pointer; }
.form .file-pick:hover { border-color: var(--green); }
.form input.sr-only:focus-visible + .file-pick { outline: 3px solid var(--orange); outline-offset: 3px; }
.file-name { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.file-btn { flex: none; padding: .45rem 1rem; border-radius: 999px; background: var(--cream); color: var(--forest); font-weight: 700; }
.form .sub-title { font-family: var(--font-head); font-size: 1.1rem; letter-spacing: -.005em; margin-bottom: .6rem; }
.schedule-wrap { overflow-x: auto; }
.schedule { width: 100%; border-collapse: separate; border-spacing: 4px; text-align: center; }
.schedule th { font-size: .85rem; font-weight: 700; color: var(--forest); padding: .2rem; }
.schedule tbody th { text-align: left; padding-right: .5rem; }
.schedule tbody td { background: var(--cream); border-radius: 10px; padding: 0; }
.schedule td:has(:checked) { background: rgba(43, 108, 83, .18); }
.form .schedule input { width: 22px; height: 22px; min-height: 0; margin: .55rem auto; padding: 0; display: block; accent-color: var(--green); cursor: pointer; }
@media (max-width: 420px) { .schedule th { font-size: .75rem; } .schedule tbody th { padding-right: .2rem; } }
.form .page { display: grid; gap: 1.1rem; }
.form-progress { margin: 0; font-family: var(--font-head); font-weight: 600; font-size: .85rem; letter-spacing: .12em; text-transform: uppercase; color: var(--orange-ink); }
.form-nav { display: flex; gap: .75rem; }
.form-nav .btn { flex: 1; }
.summary .form-note { white-space: pre-line; }
.form .check-required { padding: 1rem 1.1rem; border: 2px solid var(--green); border-radius: 16px; background: rgba(43, 108, 83, .07); }
.form .check-field label a { font-weight: 800; color: var(--forest); text-decoration-thickness: 2px; text-underline-offset: 3px; }
.doc-link { display: inline-flex; align-items: center; gap: .45rem; margin-top: .6rem; padding: .45rem 1rem; border-radius: 999px; background: var(--forest); color: var(--white) !important; font-weight: 700; font-size: .92rem; text-decoration: none; transition: background 150ms ease, transform var(--press); }
.doc-link:hover { background: var(--green); }
.doc-link:active { transform: scale(.97); }
.doc-link svg { width: 18px; height: 18px; flex: none; }
.district-pick { display: grid; grid-template-columns: repeat(3, 1fr); gap: .6rem; }
.district-pick .help { grid-column: 1 / -1; margin-top: 0; }
@media (max-width: 640px) { .district-pick { grid-template-columns: 1fr; } }

/* Esqueleto mientras carga el formulario */
.skeleton.card { display: grid; gap: 1.1rem; }
.sk { height: 50px; border-radius: 14px; background: linear-gradient(90deg, rgba(0, 68, 33, .07) 25%, rgba(0, 68, 33, .14) 50%, rgba(0, 68, 33, .07) 75%) 0 0 / 200% 100%; animation: sk-brillo 1.4s ease-in-out infinite; }
.sk-step { height: 14px; width: 7rem; border-radius: 7px; }
.sk-title { height: 28px; width: 12rem; border-radius: 8px; }
.sk-row { display: flex; gap: .6rem; }
.sk-row .sk { flex: 1; }
.sk-area { height: 110px; }
.sk-btn { height: 52px; border-radius: 999px; }
@keyframes sk-brillo { to { background-position: -200% 0; } }
@media (prefers-reduced-motion: reduce) { .sk { animation: none; } .trail svg { animation: none; opacity: .7; } }
html:not(.js) .skeleton { display: none; }
