/* =============================================================
   1. Tokens
   ============================================================= */
:root {
  --bg:        #faf6ee;
  --bg-2:      #eef0e5;
  --paper:     #ffffff;
  --ink:       #2b2823;
  --ink-soft:  #46423a;
  --ink-mute:  #8b8579;
  --accent:    #7f9c82;
  --accent-2:  #c98a72;
  --gold:      #c9a961;
  --line:      rgba(43,40,35,0.13);
  --line-soft: rgba(43,40,35,0.07);
  --cream:     #faf6ee;

  --serif: "Fraunces", "Georgia", serif;
  --sans:  "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", system-ui, sans-serif;
  --script: "Caveat", cursive;

  --ease-out:    cubic-bezier(0.16, 1, 0.3, 1);
  --ease-in:     cubic-bezier(0.7, 0, 0.84, 0);
  --ease-soft:   cubic-bezier(0.25, 0.46, 0.45, 0.94);
  --ease-bounce: cubic-bezier(0.34, 1.56, 0.64, 1);

  --nav-h: 76px;
  --container: 1240px;
}

@property --mesh-x { syntax: "<percentage>"; inherits: false; initial-value: 30%; }
@property --mesh-y { syntax: "<percentage>"; inherits: false; initial-value: 30%; }

/* =============================================================
   2. Reset & base
   ============================================================= */
*, *::before, *::after { box-sizing: border-box; margin: 0; }
html { -webkit-text-size-adjust: 100%; tab-size: 2; scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }

body {
  font-family: var(--sans);
  font-size: 16px;
  line-height: 1.65;
  color: var(--ink-soft);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
  overflow-x: clip;
  overscroll-behavior-y: none;
}

img, svg, video { display: block; max-width: 100%; }
img { height: auto; }
button { font: inherit; color: inherit; cursor: pointer; border: 0; background: none; }
a { color: inherit; text-decoration: none; }
p { text-wrap: pretty; }
ul, ol { list-style: none; padding: 0; }
h1, h2, h3, h4 { font-family: var(--serif); text-wrap: balance; line-height: 1.08; letter-spacing: -0.01em; color: var(--ink); font-weight: 500; overflow-wrap: break-word; word-break: break-word; }
::selection { background: var(--accent); color: var(--ink); }

:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
  border-radius: 4px;
}

.skip-link {
  position: fixed; top: -100px; left: 1rem; z-index: 9999;
  padding: .7rem 1.2rem; background: var(--ink); color: var(--cream);
  border-radius: 8px; font-weight: 500; font-size: .9rem;
  transition: top .3s var(--ease-out);
}
.skip-link:focus { top: 1rem; }

/* =============================================================
   3. Utilities
   ============================================================= */
.container { width: 100%; max-width: var(--container); margin-inline: auto; padding-inline: 1.4rem; }
@media (min-width: 720px)  { .container { padding-inline: 2.4rem; } }
@media (min-width: 1280px) { .container { padding-inline: 3.2rem; } }

.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;
}

.eyebrow {
  display: inline-flex; align-items: center;
  font-family: var(--script); font-size: 1.9rem; font-weight: 400;
  color: var(--accent); margin-bottom: -.3rem; line-height: 1;
}

.section { padding-block: clamp(4.4rem, 9vw, 8.5rem); position: relative; }
.section-tight { padding-block: clamp(2.4rem, 5vw, 4rem); }
.section-head { max-width: 640px; margin-bottom: clamp(2.4rem, 5vw, 4rem); }
.section-head.is-center { margin-inline: auto; text-align: center; }
.section-title { font-size: clamp(2.1rem, 4.2vw, 3.4rem); letter-spacing: -0.02em; }
.section-lede { margin-top: 1rem; color: var(--ink-mute); font-size: 1.1rem; max-width: 56ch; }
.section-head.is-center .section-lede { margin-inline: auto; }

.bg-sand { background: var(--bg-2); }
.bg-paper { background: var(--paper); }

/* =============================================================
   4. Typography
   ============================================================= */
h1 { font-size: clamp(2.6rem, 7vw, 5.4rem); letter-spacing: -0.025em; }
h2 { font-size: clamp(1.8rem, 3.6vw, 2.8rem); letter-spacing: -0.02em; }
h3 { font-size: clamp(1.2rem, 2vw, 1.5rem); }
em, i { font-style: italic; color: var(--accent); }

.lede { font-size: 1.15rem; color: var(--ink-mute); max-width: 60ch; }

.prose { max-width: 66ch; color: var(--ink-soft); }
.prose p + p { margin-top: 1.2em; }
.prose h2, .prose h3 { margin-top: 2em; margin-bottom: .6em; }
.prose a { color: var(--accent); text-decoration: underline; text-underline-offset: 3px; }
.prose blockquote {
  font-family: var(--serif); font-style: italic; font-size: 1.4rem; line-height: 1.4;
  color: var(--ink); border-left: 3px solid var(--accent); padding-left: 1.4rem;
  margin: 2em 0;
}

.dropcap::first-letter {
  float: left; font-family: var(--serif); font-style: italic; color: var(--accent);
  font-size: 4.2rem; line-height: .8; margin: .1rem .5rem -.1rem 0;
}

/* =============================================================
   5. Components
   ============================================================= */

/* Buttons */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: .55rem;
  padding: .95rem 1.8rem; border-radius: 999px; font-weight: 600; font-size: .92rem;
  letter-spacing: .01em;
  transition: transform .35s var(--ease-out), box-shadow .35s var(--ease-out), background .3s, border-color .3s, color .3s;
  white-space: nowrap;
}
.btn:hover { transform: translateY(-2px); }
.btn:active { transform: translateY(0); transition-duration: .12s; }
.btn-primary { background: var(--ink); color: var(--cream); }
.btn-primary:hover { background: var(--accent); color: var(--ink); }
.btn-ghost { background: transparent; color: var(--ink); border: 1px solid var(--line); }
.btn-ghost:hover { border-color: var(--ink); background: var(--paper); }
.btn-dark { background: var(--ink); color: var(--cream); }
.btn-dark:hover { background: var(--accent); color: var(--ink); }
.btn-sm { padding: .68rem 1.35rem; font-size: .82rem; }
.btn-wa { background: var(--accent-2); color: var(--ink); }
.btn-wa:hover { background: #b8735c; color: var(--cream); }
.btn svg { width: 1.1em; height: 1.1em; flex-shrink: 0; }

/* Cards */
.card {
  background: var(--paper); border-radius: 18px; overflow: hidden;
  border: 1px solid var(--line-soft);
  transition: box-shadow .5s var(--ease-soft), border-color .5s var(--ease-soft), transform .1s;
}
.card-img-wrap { position: relative; overflow: hidden; aspect-ratio: 4/5; background: var(--bg-2); }
.card-img-wrap img { width: 100%; height: 100%; object-fit: cover; transition: transform .9s var(--ease-soft), filter .5s; filter: saturate(.85) sepia(.08) contrast(1.02) brightness(1.02); }
.card:hover .card-img-wrap img { transform: scale(1.05); filter: saturate(1) sepia(.04) contrast(1.04) brightness(1.03); }
.card:hover {
  box-shadow: 0 30px 60px -24px rgba(43,40,35,0.2), 0 0 0 1px rgba(127,156,130,0.14), 0 10px 24px -12px rgba(127,156,130,0.12);
  border-color: rgba(127,156,130,0.32);
}
.card-body { padding: 1.6rem 1.7rem 1.8rem; }
.card-tag {
  display: inline-block; font-size: .68rem; letter-spacing: .14em; text-transform: uppercase;
  color: #9c5a42; font-weight: 700; margin-bottom: .6rem;
}
.card-title { font-size: 1.3rem; margin-bottom: .5rem; }
.card-text { color: var(--ink-mute); font-size: .95rem; }

/* Tilt (JS adds --rx/--ry via inline style) */
.has-tilt {
  --rx: 0deg; --ry: 0deg;
  transform: perspective(1000px) rotateX(var(--rx)) rotateY(var(--ry));
  transform-style: preserve-3d;
}

/* Badges */
.badge {
  display: inline-flex; align-items: center; gap: .4rem;
  padding: .3rem .7rem; border-radius: 999px; font-size: .72rem; font-weight: 700;
  letter-spacing: .04em; text-transform: uppercase;
  background: rgba(201,138,114,0.18); color: #9c5a42;
}
.badge.is-mio { background: rgba(127,156,130,0.16); color: #4f6b52; }

/* Nav */
.nav {
  position: fixed; top: 0; inset-inline: 0; z-index: 100;
  height: var(--nav-h);
  background: var(--paper);
  box-shadow: 0 1px 0 var(--line);
  transition: box-shadow .4s var(--ease-out);
}
.nav-inner { height: 100%; display: flex; align-items: center; justify-content: space-between; gap: 1rem; }
.nav.is-scrolled {
  background: rgba(255,255,255,0.94);
  backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px);
  box-shadow: 0 1px 0 var(--line);
}
.nav-brand { font-family: var(--script); font-size: 1.7rem; font-weight: 600; color: var(--accent); display: flex; align-items: flex-start; flex-direction: column; line-height: 1; }
.nav-brand small { font-family: var(--sans); font-size: .62rem; letter-spacing: .12em; text-transform: uppercase; color: var(--ink-mute); font-weight: 500; margin-top: .2rem; }
@media (max-width: 539px) { .nav-brand { font-size: 1.4rem; } }

.brand-seal { display: block; max-width: 220px; margin-inline: auto; mix-blend-mode: multiply; }
.nav-links { display: none; align-items: center; gap: 1.9rem; }
@media (min-width: 960px) { .nav-links { display: flex; } }
.nav-link {
  position: relative; padding: .3rem 0; font-size: .94rem; font-weight: 500; color: var(--ink-soft);
}
.nav-link::after {
  content: ""; position: absolute; left: 0; right: 0; bottom: -2px; height: 1px; background: var(--accent);
  transform: scaleX(0); transform-origin: right; transition: transform .45s var(--ease-out);
}
.nav-link:hover::after, .nav-link.is-active::after { transform: scaleX(1); transform-origin: left; }
.nav-dropdown { position: relative; }
.nav-dropdown-menu {
  position: absolute; top: calc(100% + 1rem); left: 50%; transform: translate(-50%, 8px);
  min-width: 220px; background: var(--paper); border: 1px solid var(--line); border-radius: 14px;
  padding: .5rem; box-shadow: 0 24px 50px -14px rgba(36,31,25,0.22);
  opacity: 0; pointer-events: none; transition: opacity .3s var(--ease-out), transform .3s var(--ease-out);
}
.nav-dropdown:hover .nav-dropdown-menu,
.nav-dropdown:focus-within .nav-dropdown-menu {
  opacity: 1; pointer-events: auto; transform: translate(-50%, 0);
}
.nav-dropdown-menu a { display: block; padding: .65rem .8rem; border-radius: 8px; font-size: .92rem; }
.nav-dropdown-menu a:hover { background: var(--bg-2); }
.nav-actions { display: flex; align-items: center; gap: .8rem; }
.nav-actions .btn { display: none; }
@media (min-width: 720px) { .nav-actions .btn { display: inline-flex; } }

.nav-burger {
  display: grid; place-items: center; width: 42px; height: 42px; border-radius: 50%;
}
@media (min-width: 960px) { .nav-burger { display: none; } }
.nav-burger span { display: block; width: 20px; height: 1.5px; background: var(--ink); position: relative; }
.nav-burger span::before, .nav-burger span::after {
  content: ""; position: absolute; left: 0; width: 20px; height: 1.5px; background: var(--ink); transition: transform .3s var(--ease-out);
}
.nav-burger span::before { top: -6px; }
.nav-burger span::after { top: 6px; }

.nav-mobile {
  position: fixed; inset: 0; z-index: 95; background: var(--bg-2);
  display: flex; flex-direction: column; padding: calc(var(--nav-h) + 1.5rem) 1.6rem 2rem;
  clip-path: inset(0 0 100% 0); transition: clip-path .6s var(--ease-soft);
  overflow-y: auto;
}
.nav-mobile[data-open="true"] { clip-path: inset(0); }
.nav-mobile a { display: block; padding: 1rem 0; font-family: var(--serif); font-size: 1.7rem; border-bottom: 1px solid var(--line); }
.nav-mobile .nav-mobile-sub a { font-family: var(--sans); font-size: 1.1rem; padding-left: 1rem; border-bottom: none; color: var(--ink-mute); }
.nav-mobile-foot { margin-top: auto; padding-top: 2rem; display: flex; gap: .8rem; flex-wrap: wrap; }

/* Forms */
.field { position: relative; margin-bottom: 1.1rem; }
.field input, .field textarea, .field select {
  width: 100%; padding: 1.5rem 1rem .6rem; border: 1px solid var(--line); border-radius: 12px;
  background: var(--paper); color: inherit; font-family: var(--sans); font-size: 1rem;
  transition: border-color .3s;
}
.field textarea { min-height: 130px; resize: vertical; }
.field input:focus, .field textarea:focus, .field select:focus { border-color: var(--accent); }
.field label {
  position: absolute; left: 1rem; top: 1.15rem; pointer-events: none;
  transition: all .25s var(--ease-out); color: var(--ink-mute); font-size: .98rem;
}
.field input:focus + label, .field input:not(:placeholder-shown) + label,
.field textarea:focus + label, .field textarea:not(:placeholder-shown) + label,
.field select:focus + label, .field select.has-value + label {
  top: .5rem; font-size: .68rem; letter-spacing: .1em; text-transform: uppercase; color: var(--accent);
}
.field-row { display: grid; gap: 1.1rem; }
@media (min-width: 640px) { .field-row.cols-2 { grid-template-columns: 1fr 1fr; } }

.form-card { background: var(--paper); border: 1px solid var(--line-soft); border-radius: 24px; padding: clamp(1.6rem, 4vw, 2.6rem); position: relative; overflow: hidden; }
.cta-form { transition: opacity .55s var(--ease-out), transform .55s var(--ease-soft); }
.cta-form.is-sent { opacity: 0; transform: translateY(-12px); pointer-events: none; position: absolute; }
.cta-submit { position: relative; width: 100%; }
.cta-form-spinner, .cta-form-check { position: absolute; inset: 0; display: grid; place-items: center; opacity: 0; pointer-events: none; }
.cta-form.is-sending .cta-form-label { opacity: 0; }
.cta-form.is-sending .cta-form-spinner { opacity: 1; }
.cta-form-spinner::after {
  content: ""; width: 18px; height: 18px; border: 1.5px solid rgba(255,255,255,0.35); border-top-color: var(--cream);
  border-radius: 50%; animation: spin .9s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }
.cta-success {
  position: absolute; inset: 0; display: grid; place-items: center; text-align: center; padding: 2rem;
  opacity: 0; pointer-events: none; transition: opacity .7s var(--ease-out) .15s, transform .8s var(--ease-soft) .15s;
  transform: translateY(10px); background: var(--paper);
}
.cta-success.is-visible { opacity: 1; pointer-events: auto; transform: translateY(0); }
.cta-success h3 { margin-bottom: .5rem; }
.cta-success p { color: var(--ink-mute); }
.form-note { font-size: .82rem; color: var(--ink-mute); margin-top: .8rem; }

/* Footer */
.footer { background: #100d0a; color: var(--cream); padding-block: clamp(3rem, 6vw, 5rem) 2rem; border-top: 1px solid var(--line); }
.footer a { color: var(--cream); }
.footer-grid { display: grid; gap: 2.6rem; margin-bottom: 3rem; }
@media (min-width: 720px) { .footer-grid { grid-template-columns: 1.4fr 1fr 1fr 1fr; } }
.footer-brand { font-family: var(--serif); font-size: 1.5rem; margin-bottom: .8rem; }
.footer-tagline { color: rgba(255,250,240,0.6); max-width: 32ch; }
.footer h4 { font-family: var(--sans); font-size: .78rem; letter-spacing: .12em; text-transform: uppercase; color: rgba(255,250,240,0.55); margin-bottom: 1rem; font-weight: 600; }
.footer-links a { display: block; padding: .35rem 0; color: rgba(255,250,240,0.85); transition: color .3s; }
.footer-links a:hover { color: var(--gold); }
.footer-bottom { display: flex; flex-wrap: wrap; gap: 1rem; justify-content: space-between; align-items: center; padding-top: 2rem; border-top: 1px solid rgba(255,250,240,0.14); font-size: .82rem; color: rgba(255,250,240,0.55); }
.footer-social { display: flex; gap: .9rem; }
.footer-social a { width: 38px; height: 38px; border: 1px solid rgba(255,250,240,0.25); border-radius: 50%; display: grid; place-items: center; transition: background .3s, border-color .3s; }
.footer-social a:hover { background: var(--accent); border-color: var(--accent); }

/* Floating WhatsApp button */
.wa-float {
  position: fixed; right: 1.3rem; bottom: 1.3rem; z-index: 90;
  width: 58px; height: 58px; border-radius: 50%; background: var(--accent-2); color: var(--ink);
  display: grid; place-items: center; box-shadow: 0 14px 30px rgba(0,0,0,0.28);
  transition: transform .4s var(--ease-bounce);
}
.wa-float:hover { transform: scale(1.08); }
.wa-float svg { width: 28px; height: 28px; }

/* =============================================================
   6. Sections
   ============================================================= */

/* Hero */
.hero {
  position: relative; min-height: 100svh; display: flex; align-items: flex-end;
  padding-top: calc(var(--nav-h) + 2rem); overflow: hidden;
}
.hero-bg { position: absolute; inset: 0; z-index: -2; }
.hero-bg img { width: 100%; height: 100%; object-fit: cover; animation: ambientZoom 30s ease-in-out infinite; filter: saturate(.85) sepia(.08) contrast(1.02) brightness(1.03); }
@keyframes ambientZoom {
  0%, 100% { transform: scale(1.04) translate3d(0,0,0); }
  50%      { transform: scale(1.12) translate3d(-1%,-1%,0); }
}
.hero-bg::after {
  content: ""; position: absolute; inset: 0;
  background: linear-gradient(0deg, rgba(250,246,238,0.94) 0%, rgba(250,246,238,0.58) 46%, rgba(250,246,238,0.72) 100%);
}
.hero-content { position: relative; z-index: 1; padding-block: clamp(2.4rem, 6vw, 4.2rem); max-width: 760px; }
.hero-eyebrow { color: var(--accent); font-size: .82rem; letter-spacing: .18em; text-transform: uppercase; font-weight: 600; display: flex; align-items: center; gap: .6rem; margin-bottom: 1.2rem; }
.hero-eyebrow::before { content: ""; width: 26px; height: 1px; background: var(--accent); }
.hero-title { color: var(--ink); font-size: clamp(2.6rem, 6.4vw, 4.8rem); max-width: 16ch; }
.hero-title em { color: var(--accent-2); font-style: normal; font-family: var(--script); font-size: 1.2em; }
.hero-sub { color: var(--ink-soft); font-size: 1.15rem; max-width: 46ch; margin-top: 1.3rem; }
.hero-actions { display: flex; flex-wrap: wrap; gap: 1rem; margin-top: 2.2rem; }
.hero-meta { display: flex; flex-wrap: wrap; gap: 1.6rem; margin-top: 2.6rem; color: var(--ink-mute); font-size: .88rem; }
.hero-meta span { display: flex; align-items: center; gap: .5rem; }
.hero-meta svg { width: 1.1em; height: 1.1em; color: var(--accent); }

/* Manifesto / intro split */
.manifesto { display: grid; gap: 2.4rem; align-items: start; }
@media (min-width: 960px) { .manifesto { grid-template-columns: .8fr 1.6fr; gap: 5rem; } }
.manifesto-num { font-family: var(--serif); font-style: italic; font-size: 3.4rem; color: var(--accent); line-height: 1; }

/* Marquee */
.marquee {
  overflow: hidden; position: relative; padding-block: 1.6rem;
  border-block: 1px solid var(--line); background: var(--bg-2);
  display: flex; flex-wrap: nowrap; align-items: center;
}
.marquee::before, .marquee::after { content: ""; position: absolute; top: 0; bottom: 0; width: 90px; z-index: 2; pointer-events: none; }
.marquee::before { left: 0; background: linear-gradient(90deg, var(--bg-2), transparent); }
.marquee::after { right: 0; background: linear-gradient(270deg, var(--bg-2), transparent); }
.marquee-track {
  display: inline-flex; flex-shrink: 0; align-items: center; gap: 2.8rem; white-space: nowrap; will-change: transform;
  font-family: var(--script); font-weight: 600; font-size: 2.3rem; color: var(--ink-soft);
}
.marquee-track span.dot { color: var(--accent); }

/* Gallery teaser strip (home) — one larger tile + two square tiles */
.teaser-grid { display: grid; gap: 1rem; grid-template-columns: 1fr 1fr; }
.teaser-grid .card-img-wrap { border-radius: 18px; aspect-ratio: 1; }
.teaser-grid .teaser-lg { grid-row: 1 / 3; aspect-ratio: auto; }
@media (min-width: 720px) { .teaser-grid { grid-template-columns: 1.3fr 1fr 1fr; } .teaser-grid .teaser-lg { grid-row: auto; aspect-ratio: 4/5; } }

/* Bento highlight grid (home) — one featured card + two smaller below */
.highlight-grid { display: grid; gap: 1.3rem; grid-template-columns: 1fr; }
@media (min-width: 720px) { .highlight-grid { grid-template-columns: repeat(2, 1fr); } }
.highlight-grid .card-feature { grid-column: 1 / -1; }
@media (min-width: 720px) {
  .card-feature { display: grid; grid-template-columns: 1.15fr 1fr; }
  .card-feature .card-img-wrap { aspect-ratio: auto; height: 100%; }
  .card-feature .card-body { display: flex; flex-direction: column; justify-content: center; padding: clamp(1.8rem, 3vw, 3rem); }
  .card-feature .card-title { font-size: clamp(1.6rem, 2.4vw, 2.1rem); }
}

/* Class page hero-strip */
.page-hero { position: relative; padding-top: calc(var(--nav-h) + 3.4rem); padding-bottom: clamp(2.4rem, 5vw, 4rem); overflow: hidden; }
.page-hero-grid { display: grid; gap: 2.4rem; align-items: center; }
@media (min-width: 960px) { .page-hero-grid { grid-template-columns: 1fr .9fr; gap: 4rem; } }
.page-hero-figure { border-radius: 26px; overflow: hidden; aspect-ratio: 4/5; }
.page-hero-figure img { width: 100%; height: 100%; object-fit: cover; filter: saturate(.85) sepia(.08) contrast(1.02) brightness(1.02); }

/* Portrait frame — decorative offset block + handwritten signature (Sobre mí) */
.portrait-frame { position: relative; }
.portrait-frame::before {
  content: ""; position: absolute; inset: 1.4rem -1.4rem -1.4rem 1.4rem;
  background: var(--accent-2); opacity: .22; border-radius: 26px; z-index: -1;
}
.portrait-signature {
  position: absolute; left: -.8rem; bottom: -1.1rem; z-index: 2;
  background: var(--paper); padding: .65rem 1.4rem; border-radius: 999px;
  font-family: var(--script); font-size: 1.35rem; color: var(--accent);
  box-shadow: 0 16px 32px -12px rgba(43,40,35,0.28);
  transform: rotate(-3deg);
  animation: signatureFloat 5s ease-in-out infinite;
}
@keyframes signatureFloat {
  0%, 100% { transform: rotate(-3deg) translateY(0); }
  50%      { transform: rotate(-2deg) translateY(-6px); }
}
.portrait-frame .page-hero-figure img { animation: portraitBreathe 9s ease-in-out infinite; }
@keyframes portraitBreathe {
  0%, 100% { transform: scale(1.02); }
  50%      { transform: scale(1.07); }
}
@media (max-width: 719px) { .portrait-signature { font-size: 1.15rem; padding: .55rem 1.1rem; } }

/* Program list */
.program-list { display: flex; flex-direction: column; gap: 0; margin-top: 1.4rem; }
.program-item { display: flex; gap: 1.1rem; padding-block: 1.1rem; border-bottom: 1px solid var(--line); }
.program-item svg { flex-shrink: 0; width: 1.3rem; height: 1.3rem; color: var(--accent); margin-top: .15rem; }

/* Sticky sidebar (class pages) */
.split-layout { display: grid; gap: 3rem; align-items: start; }
@media (min-width: 960px) { .split-layout { grid-template-columns: 1.5fr 1fr; } }

.contact-split { display: grid; gap: 2rem; align-items: stretch; }
@media (min-width: 960px) { .contact-split { grid-template-columns: 1fr 1fr; } }
.contact-info-card { display: flex; flex-direction: column; }
.location-card {
  margin-top: auto; padding-top: 1.8rem;
  display: flex; flex-direction: column; gap: .8rem; align-items: flex-start;
  border-top: 1px solid var(--line);
}
.location-card svg { width: 1.6rem; height: 1.6rem; color: var(--accent); }
.location-card-text strong { display: block; font-family: var(--serif); font-size: 1.1rem; color: var(--ink); margin-bottom: .2rem; }
.location-card-text p { color: var(--ink-mute); font-size: .92rem; }
.sidebar-card { position: relative; }
@media (min-width: 960px) { .sidebar-card { position: sticky; top: calc(var(--nav-h) + 1.6rem); } }
.info-row { display: flex; flex-wrap: wrap; justify-content: space-between; gap: .3rem .8rem; padding-block: .7rem; border-bottom: 1px solid var(--line); font-size: .93rem; }
.info-row dt { color: var(--ink-mute); }
.info-row dd { font-weight: 600; overflow-wrap: break-word; word-break: break-word; min-width: 0; text-align: right; }

/* Steps (encargos) */
.steps { display: grid; gap: 1.6rem; counter-reset: step; }
@media (min-width: 720px) { .steps { grid-template-columns: repeat(4, 1fr); } }
.step { position: relative; padding-top: 1rem; }
.step::before {
  counter-increment: step; content: counter(step, decimal-leading-zero);
  font-family: var(--serif); font-style: italic; font-size: 2.2rem; color: var(--accent);
  display: block; margin-bottom: .6rem;
}

/* Gallery */
.gallery-filters { display: flex; flex-wrap: wrap; gap: .7rem; margin-bottom: 2rem; }
.filter-btn {
  padding: .6rem 1.2rem; border-radius: 999px; border: 1px solid var(--line); font-size: .88rem; font-weight: 600;
  color: var(--ink-mute); transition: all .3s var(--ease-out);
}
.filter-btn:hover { border-color: var(--accent); color: var(--ink); }
.filter-btn.is-active { background: var(--ink); color: var(--cream); border-color: var(--ink); }

.masonry { display: grid; grid-template-columns: repeat(2, 1fr); gap: 1.1rem; }
@media (min-width: 640px)  { .masonry { grid-template-columns: repeat(3, 1fr); } }
@media (min-width: 1024px) { .masonry { grid-template-columns: repeat(4, 1fr); } }
.masonry-item {
  aspect-ratio: 4 / 5; position: relative; border-radius: 18px; overflow: hidden;
  cursor: zoom-in;
}
.masonry-item img { width: 100%; height: 100%; object-fit: cover; display: block; transition: transform .8s var(--ease-soft), filter .5s; filter: saturate(.85) sepia(.08) contrast(1.02) brightness(1.02); }
.masonry-item:hover img { transform: scale(1.06); filter: saturate(1) sepia(.04) contrast(1.04) brightness(1.03); }
.masonry-item.is-hidden { display: none; }
.masonry-caption {
  position: absolute; inset: auto 0 0 0; padding: 1.6rem .9rem .8rem;
  background: linear-gradient(0deg, rgba(20,17,13,0.82), transparent);
  color: var(--cream); opacity: 0; transition: opacity .4s;
  display: flex; justify-content: space-between; align-items: flex-end; gap: .6rem;
}
.masonry-item:hover .masonry-caption { opacity: 1; }
.masonry-caption span { font-size: .85rem; font-weight: 600; }

/* Lightbox */
.lightbox {
  position: fixed; inset: 0; z-index: 200; background: rgba(20,17,13,0.94);
  display: none; align-items: center; justify-content: center; padding: 4vh 4vw;
}
.lightbox[data-open="true"] { display: flex; }
.lightbox-inner { max-width: 1100px; width: 100%; max-height: 90vh; position: relative; }
.lightbox-inner img { width: 100%; height: 100%; max-height: 82vh; object-fit: contain; border-radius: 10px; }
.lightbox-caption { color: var(--cream); text-align: center; margin-top: 1rem; font-size: .95rem; opacity: .85; }
.lightbox-close, .lightbox-prev, .lightbox-next {
  position: fixed; color: var(--cream); width: 46px; height: 46px; border-radius: 50%;
  display: grid; place-items: center; background: rgba(255,255,255,0.08); transition: background .3s;
}
.lightbox-close:hover, .lightbox-prev:hover, .lightbox-next:hover { background: rgba(255,255,255,0.18); }
.lightbox-close { top: 1.6rem; right: 1.6rem; }
.lightbox-prev { left: 1.6rem; top: 50%; transform: translateY(-50%); }
.lightbox-next { right: 1.6rem; top: 50%; transform: translateY(-50%); }

/* Instagram section */
.insta-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: .7rem; }
@media (min-width: 720px) { .insta-grid { grid-template-columns: repeat(6, 1fr); } }
.insta-item { position: relative; aspect-ratio: 1; border-radius: 14px; overflow: hidden; }
.insta-item img { width: 100%; height: 100%; object-fit: cover; transition: transform .6s var(--ease-soft); }
.insta-item:hover img { transform: scale(1.1); }
.insta-item::after {
  content: ""; position: absolute; inset: 0; background: rgba(127,156,130,0.5);
  opacity: 0; transition: opacity .3s; display: grid; place-items: center;
}
.insta-item:hover::after { opacity: 1; }

/* Instagram — real captions, own design (own cards, not Meta's widget chrome) */
.insta-real-grid { display: grid; grid-template-columns: 1fr; gap: 1.1rem; }
@media (min-width: 640px)  { .insta-real-grid { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1100px) { .insta-real-grid { grid-template-columns: repeat(3, 1fr); } }
.insta-real-card {
  display: flex; flex-direction: column; gap: 1.2rem;
  padding: 1.9rem; border-radius: 18px; min-height: 200px;
  border: 1px solid var(--line-soft);
  transition: transform .4s var(--ease-out), box-shadow .4s var(--ease-out);
}
.insta-real-card:hover { transform: translateY(-4px); box-shadow: 0 24px 48px -20px rgba(36,31,25,0.22); }
.insta-real-icon { width: 1.6rem; height: 1.6rem; color: var(--accent); flex-shrink: 0; }
.insta-real-quote { font-family: var(--serif); font-style: italic; font-size: 1.05rem; line-height: 1.5; color: var(--ink); flex-grow: 1; }
.insta-real-link { font-size: .82rem; font-weight: 600; letter-spacing: .04em; color: var(--ink-mute); }
.insta-real-card:hover .insta-real-link { color: var(--accent); }
.insta-real-card.is-tone-1 { background: var(--paper); }
.insta-real-card.is-tone-2 { background: linear-gradient(155deg, var(--paper) 55%, rgba(127,156,130,0.1)); }
.insta-real-card.is-tone-3 { background: linear-gradient(155deg, var(--paper) 55%, rgba(201,138,114,0.14)); }

/* Testimonials */
.testi-grid { display: grid; gap: 1.4rem; }
@media (min-width: 720px) { .testi-grid { grid-template-columns: repeat(3, 1fr); } }
.testi-card { background: var(--paper); border: 1px solid var(--line-soft); border-radius: 20px; padding: 1.8rem; }
.testi-quote { font-family: var(--serif); font-style: italic; font-size: 1.08rem; color: var(--ink); margin-bottom: 1.1rem; }
.testi-name { font-weight: 700; font-size: .92rem; }
.testi-role { font-size: .82rem; color: var(--ink-mute); }

/* FAQ */
.faq-item { border-bottom: 1px solid var(--line); }
.faq-q { display: flex; justify-content: space-between; align-items: center; padding-block: 1.3rem; text-align: left; width: 100%; font-family: var(--serif); font-size: 1.15rem; gap: 1rem; }
.faq-q svg { flex-shrink: 0; width: 1.2rem; height: 1.2rem; transition: transform .35s var(--ease-out); color: var(--accent); }
.faq-item[data-open="true"] .faq-q svg { transform: rotate(45deg); }
.faq-a { max-height: 0; overflow: hidden; transition: max-height .4s var(--ease-out); color: var(--ink-mute); }
.faq-a-inner { padding-bottom: 1.3rem; max-width: 62ch; }

/* Blog list */
.post-grid { display: grid; gap: 2rem; }
@media (min-width: 720px) { .post-grid { grid-template-columns: repeat(3, 1fr); } }
.post-card-img { aspect-ratio: 16/10; }

/* Blog article */
.article-head { padding-top: calc(var(--nav-h) + 3rem); padding-bottom: 2.4rem; max-width: 760px; margin-inline: auto; text-align: center; }
.article-meta { display: flex; justify-content: center; gap: 1rem; color: var(--ink-mute); font-size: .88rem; margin-top: 1rem; }
.article-figure { max-width: 1000px; margin-inline: auto; border-radius: 22px; overflow: hidden; aspect-ratio: 16/9; margin-bottom: 3rem; }
.article-figure img { width: 100%; height: 100%; object-fit: cover; filter: saturate(.85) sepia(.08) contrast(1.02) brightness(1.02); }
.article-body { max-width: 700px; margin-inline: auto; }
.article-author { display: flex; align-items: center; gap: 1rem; margin-top: 3.5rem; padding-top: 2rem; border-top: 1px solid var(--line); }
.article-author img { width: 56px; height: 56px; border-radius: 50%; object-fit: cover; }

/* Reading progress */
.scroll-progress { position: fixed; top: 0; left: 0; right: 0; height: 2px; z-index: 150; background: rgba(43,40,35,0.08); pointer-events: none; }
.scroll-progress span { display: block; height: 100%; background: var(--accent); transform-origin: 0 0; transform: scaleX(0); }

/* Map — CSS dark-mode filter (Google's embed has no native dark theme) */
.map-frame { border-radius: 22px; overflow: hidden; aspect-ratio: 16/9; border: 1px solid var(--line); background: var(--bg-2); }
.map-frame iframe { width: 100%; height: 100%; border: 0; }

/* Credits */
.credits-list li { padding-block: .8rem; border-bottom: 1px solid var(--line); font-size: .92rem; color: var(--ink-mute); }
.credits-list a { color: var(--accent); text-decoration: underline; text-underline-offset: 2px; }

/* =============================================================
   7. Effects
   ============================================================= */
[data-reveal] {
  opacity: 0; transform: translateY(36px);
  transition: opacity .8s var(--ease-soft), transform .8s var(--ease-soft);
}
[data-reveal].is-revealed { opacity: 1; transform: none; }
[data-reveal][data-split] { opacity: 1; transform: none; }

.has-tilt { transition: transform .55s var(--ease-soft); }
.has-tilt:hover { transition-duration: .15s; }

@view-transition { navigation: auto; }
::view-transition-old(root), ::view-transition-new(root) {
  animation-duration: .55s; animation-timing-function: cubic-bezier(0.16, 1, 0.3, 1);
}
::view-transition-old(root) { animation-name: fadeOutUp; }
::view-transition-new(root) { animation-name: fadeInUp; }
@keyframes fadeOutUp { to { opacity: 0; transform: translateY(-10px); } }
@keyframes fadeInUp  { from { opacity: 0; transform: translateY(10px); } }

/* =============================================================
   8. Responsive helpers
   ============================================================= */
.hide-mobile { display: none; }
@media (min-width: 720px) { .hide-mobile { display: initial; } }
.only-mobile { display: initial; }
@media (min-width: 720px) { .only-mobile { display: none; } }

/* =============================================================
   9. Reduced motion — only intrusive effects
   ============================================================= */
@media (prefers-reduced-motion: reduce) {
  .hero-bg img { animation: none; }
  [data-reveal] { transition-duration: .25s; }
}
