/* =========================================================================
   David Terrenos — site styles ("rancho" direction)
   Served under a strict CSP: no inline style anywhere, so every visual rule
   lives here. Mobile-first; breakpoints: 40em (640px), 56.25em (900px),
   64em (1024px, desktop header), 75em (1200px).
   Sections:
     1. Tokens            9. Property types
     2. Base             10. Cómo funciona
     3. Type helpers     11. Sobre David
     4. Layout + prose   12. Contacto + form
     5. Buttons + links  13. Footer
     6. Header + nav     14. Mobile call bar
     7. Hero             15. 404 page
     8. Sarape stripe    16. Utilities, motion, print
   ========================================================================= */

/* 1. Tokens ---------------------------------------------------------------
   Contrast (WCAG 2.x), checked for every text/background pair used:
   leather on sand 13.3, leather on card 16.3, muted on card 6.9, muted on
   sand 5.6, muted on sand-deep 5.1, teal on card 6.7, teal on sand 5.5,
   teal on sand-deep 5.0, chile on sand 5.3, chile on card 6.5, chile on
   sand-deep 4.8, white on chile 6.7, white on ranch 6.3, white on
   turquoise 5.0, cream on leather 15.1, cream-muted on leather 11.4, sun on
   leather 9.1, orange on leather 5.6, sun on agave 6.9, sage on agave 9.7,
   leather on orange 5.6, leather on sun 9.1, whatsapp-ink on whatsapp 6.3,
   input border on white 4.7 (non-text 3:1). Sun yellow and orange are
   never used as text on light backgrounds. */
:root {
  /* Brand (plans/PROGRAM-listings.md "Brand direction") */
  --leather: #2B1A12;
  --chile: #A8321F;          /* primary CTA */
  --ranch: #3F6B2E;
  --agave: #23391B;
  --turquoise: #1C7C7D;
  --teal: #146465;           /* links */
  --orange: #E07A2E;         /* fill/accent only on light backgrounds */
  --sun: #F2B632;            /* fill/accent only on light backgrounds */
  --sand: #F1E4CC;           /* page */
  --card: #FFFCF5;

  /* Supporting shades */
  --leather-deep: #1C110B;
  --leather-raised: #3A2519;
  --leather-line: #4A3426;
  --chile-deep: #8A2818;
  --ranch-deep: #33582A;
  --ranch-light: #4F7F3A;
  --teal-deep: #0D4546;
  --sand-deep: #EAD9BB;
  --cream: #FBF3E4;          /* text on dark */
  --cream-muted: #E3D3BC;    /* secondary text on dark */
  --sage: #DCE6D2;           /* secondary text on agave */
  --muted: #6B5443;          /* secondary text on light */
  --line: #DCC6A3;           /* card border */
  --stitch: #C9A77C;         /* dashed "stitched leather" seam */
  --field-line: #8A6E50;     /* form control border */
  --pink: #C2457A;           /* sarape only */
  --black-tile: #111111;     /* plate tile only */
  --notice: #E3EED9;
  --whatsapp: #25D366;
  --whatsapp-hover: #3BDB78;
  --whatsapp-ink: #123B22;
  --chat-bg: #ECE5D8;
  --chat-bubble: #D9FDD3;
  --white: #FFFFFF;

  /* Type */
  --font-display: "Alfa Slab One", Rockwell, "Roboto Slab", "Courier New", Georgia, serif;
  --font-label: "Barlow Condensed", "Arial Narrow", "Roboto Condensed", "Helvetica Neue", Arial, sans-serif;
  --font-body: "Barlow", system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif;

  /* Shape and space */
  --radius: 6px;
  --radius-card: 8px;
  --gutter: 1rem;
  --wrap-max: 75rem;
  --shadow-photo: 0 14px 32px rgba(0, 0, 0, 0.45);
  --shadow-card: 0 6px 16px rgba(43, 26, 18, 0.18);
  --mobile-bar-space: 5.5rem;

  /* Focus ring colour; dark regions switch it to --sun. */
  --focus-ring: var(--leather);

  /* Sarape: 7 bands, repeated 3 times across the width. */
  --sarape: repeating-linear-gradient(90deg,
    var(--chile) 0 4.762%,
    var(--orange) 4.762% 9.524%,
    var(--sun) 9.524% 14.286%,
    var(--ranch-light) 14.286% 19.048%,
    var(--turquoise) 19.048% 23.81%,
    var(--pink) 23.81% 28.571%,
    var(--leather) 28.571% 33.333%);

  /* Star bullet (data: URIs are allowed by the kit's img-src). */
  --star-chile: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath fill='%23A8321F' d='M12 2l2.9 6.9 7.1.4-5.5 4.7 1.7 7-6.2-3.7L5.8 21l1.7-7L2 9.3l7.1-.4z'/%3E%3C/svg%3E");
  --chevron: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%232B1A12' stroke-width='2.6' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E");
}

/* 2. Base ---------------------------------------------------------------- */
*,
*::before,
*::after { box-sizing: border-box; }

html {
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
}

body {
  margin: 0;
  min-height: 100vh;
  background: var(--sand);
  color: var(--leather);
  font-family: var(--font-body);
  font-size: 1rem;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3, h4, p, ul, ol, figure, blockquote { margin: 0; }

h1, h2, h3, h4 {
  font-family: var(--font-display);
  font-weight: 400;
  line-height: 1.12;
  overflow-wrap: break-word;
}

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

button, input, select, textarea { font: inherit; color: inherit; }

a { color: var(--teal); text-underline-offset: 0.15em; }
a:hover { color: var(--teal-deep); }

:focus-visible {
  outline: 3px solid var(--focus-ring);
  outline-offset: 3px;
}

::selection { background: var(--sun); color: var(--leather); }

[id] { scroll-margin-top: 1rem; }

[hidden] { display: none !important; }

/* 3. Type helpers --------------------------------------------------------- */
.eyebrow {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  margin: 0 0 0.5rem;
  color: var(--chile);
  font-family: var(--font-label);
  font-size: 0.9375rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  line-height: 1.2;
  text-transform: uppercase;
}
.eyebrow .icon-star { flex: none; width: 14px; height: 14px; }
.eyebrow--orange { color: var(--orange); }   /* on leather only */
.eyebrow--sun { color: var(--sun); }         /* on agave/leather only */

.section-head { max-width: 46rem; margin-bottom: 1.75rem; }
.section-head h2 { font-size: clamp(1.6875rem, 1.2rem + 2vw, 2.75rem); }
.section-lede {
  margin-top: 0.625rem;
  color: var(--muted);
  font-size: 1.0625rem;
  max-width: 40rem;
}

.icon { flex: none; width: 18px; height: 18px; }

/* 4. Layout + prose -------------------------------------------------------- */
.wrap {
  width: 100%;
  max-width: calc(var(--wrap-max) + 2 * var(--gutter));
  margin-inline: auto;
  padding-inline: var(--gutter);
}

.section { padding-block: 3rem; }
.section--contact { background: var(--sand-deep); }

/* Long text (privacy policy, legal pages). */
.prose {
  max-width: 46rem;
  margin-inline: auto;
  padding-block: 2.5rem 3.5rem;
  font-size: 1.0625rem;
  line-height: 1.65;
}
.prose h1 {
  font-size: clamp(2rem, 1.5rem + 2vw, 2.75rem);
  line-height: 1.08;
  margin-bottom: 1rem;
}
.prose h2 {
  font-size: clamp(1.375rem, 1.15rem + 0.9vw, 1.75rem);
  margin: 2.25rem 0 0.75rem;
}
.prose h3 {
  font-family: var(--font-label);
  font-size: 1.25rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  margin: 1.75rem 0 0.5rem;
}
.prose p,
.prose ul,
.prose ol { margin: 0 0 1rem; }
.prose ul,
.prose ol { padding-left: 1.375rem; }
.prose li + li { margin-top: 0.375rem; }
.prose li::marker { color: var(--chile); }
.prose a { color: var(--teal); text-decoration: underline; }
.prose a:hover { color: var(--teal-deep); }
.prose strong { font-weight: 700; }
.prose hr { border: 0; border-top: 1px dashed var(--stitch); margin: 2rem 0; }
.prose .lede,
.prose .prose-meta { color: var(--muted); }
.prose table { width: 100%; border-collapse: collapse; margin: 0 0 1.25rem; font-size: 0.9375rem; }
.prose th,
.prose td { text-align: left; vertical-align: top; padding: 0.5rem 0.625rem; border-bottom: 1px solid var(--line); }
.prose th { font-family: var(--font-label); font-weight: 700; letter-spacing: 0.04em; text-transform: uppercase; }

/* "Stitched leather" card: border plus a dashed seam inside it. */
.stitched {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--radius-card);
  outline: 1.5px dashed var(--stitch);
  outline-offset: -9px;
}

/* 5. Buttons + links -------------------------------------------------------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  min-height: 48px;
  padding: 0.5rem 1.25rem;
  border: 2px solid transparent;
  border-radius: var(--radius);
  background: var(--leather);
  color: var(--cream);
  font-family: var(--font-label);
  font-size: 1.125rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  line-height: 1.1;
  text-align: center;
  text-decoration: none;
  text-transform: uppercase;
  cursor: pointer;
}
.btn:hover { text-decoration: none; }
.btn--sm { min-height: 44px; padding-inline: 1rem; font-size: 1.0625rem; }
.btn--lg { min-height: 54px; padding-inline: 1.5rem; font-size: 1.1875rem; }
.btn--block { display: flex; width: 100%; }

.btn--primary { background: var(--chile); color: var(--white); }
.btn--primary:hover { background: var(--chile-deep); color: var(--white); }
/* Alias used by the secondary pages' shell. */
.btn-call { background: var(--chile); color: var(--white); }
.btn-call:hover { background: var(--chile-deep); color: var(--white); }

.btn--green { background: var(--ranch); color: var(--white); }
.btn--green:hover { background: var(--ranch-deep); color: var(--white); }

.btn--whatsapp { background: var(--whatsapp); color: var(--whatsapp-ink); }
.btn--whatsapp:hover { background: var(--whatsapp-hover); color: var(--whatsapp-ink); }

.btn--outline-sun { background: transparent; border-color: var(--sun); color: var(--sun); }
.btn--outline-sun:hover { background: var(--sun); color: var(--leather); }

.btn--outline-cream { background: transparent; border-color: var(--cream-muted); color: var(--cream); }
.btn--outline-cream:hover { background: var(--cream); color: var(--leather); }

.btn--outline { background: transparent; border-color: var(--teal); color: var(--teal); }
.btn--outline:hover { background: var(--teal); color: var(--white); }

.btn:disabled,
.btn[aria-disabled="true"] { opacity: 0.6; cursor: progress; }

/* Links inside a sentence: grow the touch area to 44px without moving text. */
.inline-target {
  display: inline-block;
  padding-block: 0.8125rem;
  margin-block: -0.8125rem;
}

.text-link {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  color: var(--teal);
  font-weight: 700;
  text-decoration: underline;
}

.card-link {
  display: inline-flex;
  align-items: center;
  gap: 0.375rem;
  min-height: 44px;
  margin-top: auto;
  color: var(--teal);
  font-family: var(--font-label);
  font-size: 1.125rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-decoration: none;
  text-transform: uppercase;
}
.card-link:hover { color: var(--teal-deep); text-decoration: underline; }

/* Skip link */
.skip-link {
  position: absolute;
  left: 1rem;
  top: -10rem;
  z-index: 100;
  padding: 0.75rem 1rem;
  border-radius: var(--radius);
  background: var(--sun);
  color: var(--leather);
  font-weight: 700;
}
.skip-link:focus { top: 0.75rem; color: var(--leather); }

/* 6. Header + nav ------------------------------------------------------------ */
.topbar { display: none; }

.site-header {
  --focus-ring: var(--sun);
  position: relative;
  z-index: 40;
  background: var(--leather);
  border-bottom: 1px solid var(--leather-line);
  color: var(--cream);
}
.site-header__inner {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 0.25rem 1.5rem;
  padding-block: 0.75rem;
}

.brand { display: inline-flex; flex: none; border-radius: 10px; }
.brand img { width: 168px; height: auto; }

.nav-toggle {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  min-width: 44px;
  min-height: 44px;
  padding: 0 0.875rem;
  border: 1px solid var(--leather-line);
  border-radius: var(--radius);
  background: var(--leather-raised);
  color: var(--cream);
  font-family: var(--font-label);
  font-size: 1.0625rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  cursor: pointer;
}
.nav-toggle .icon { width: 20px; height: 20px; }

/* Without JavaScript the links show as a wrapping row under the logo. */
.site-nav { flex-basis: 100%; }
.site-nav__links {
  display: flex;
  flex-wrap: wrap;
  gap: 0 1.125rem;
  list-style: none;
  padding: 0;
}
.site-nav__links a {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  color: var(--cream);
  font-family: var(--font-label);
  font-size: 1.0625rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-decoration: none;
  text-transform: uppercase;
}
.site-nav__links a:hover { color: var(--sun); text-decoration: underline; text-decoration-thickness: 2px; text-underline-offset: 0.3em; }
.site-nav__actions { display: none; }

/* With JavaScript (js/site.js adds .has-js-nav) the nav collapses behind the
   Menú button below the desktop breakpoint. */
@media (max-width: 63.99em) {
  .has-js-nav .site-nav { display: none; }
  .has-js-nav.is-open .site-nav {
    display: block;
    margin-top: 0.5rem;
    padding: 0.25rem 0 1rem;
    border-top: 1px solid var(--leather-line);
  }
  .has-js-nav.is-open .site-nav__links { flex-direction: column; gap: 0; }
  .has-js-nav.is-open .site-nav__links a {
    width: 100%;
    min-height: 52px;
    border-bottom: 1px dashed var(--leather-line);
    font-size: 1.1875rem;
  }
  .has-js-nav.is-open .site-nav__actions {
    display: grid;
    gap: 0.625rem;
    margin-top: 1rem;
  }
  .has-js-nav.is-open .site-nav__actions .btn { min-height: 52px; }
}

/* Flatter shell variant (secondary pages): .brand and .site-nav sit directly
   in .site-header, the nav holds bare links, the footer holds <p> rows.
   Same look as the home page's shell. */
.site-header:has(> .brand) {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 0.25rem 1.5rem;
  padding: 0.75rem max(var(--gutter), calc((100% - var(--wrap-max)) / 2));
}
.site-nav:has(> a) {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0 1.125rem;
}
.site-nav > a:not(.btn) {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  color: var(--cream);
  font-family: var(--font-label);
  font-size: 1.0625rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-decoration: none;
  text-transform: uppercase;
}
.site-nav > a:not(.btn):hover { color: var(--sun); text-decoration: underline; text-decoration-thickness: 2px; text-underline-offset: 0.3em; }
.site-nav > .btn { min-height: 44px; margin-block: 0.25rem; padding-inline: 1rem; font-size: 1.0625rem; }

/* 7. Hero ---------------------------------------------------------------- */
.hero {
  --focus-ring: var(--sun);
  position: relative;
  overflow: hidden;
  padding: 1.25rem 0 2.5rem;
  background:
    radial-gradient(ellipse 60% 70% at 85% 15%, rgba(224, 122, 46, 0.14), transparent 70%),
    var(--leather);
  color: var(--cream);
}
.hero__star {
  position: absolute;
  top: -5rem;
  right: -7rem;
  width: 28rem;
  height: 28rem;
  color: var(--sun);
  opacity: 0.07;
  pointer-events: none;
}
.hero__inner {
  position: relative;
  display: grid;
  gap: 1.5rem;
}
.hero__media {
  position: relative;
  order: -1;
  width: 100%;
  max-width: 32.5rem;
  justify-self: center;
}
.photo-frame {
  aspect-ratio: 5 / 4;
  overflow: hidden;
  border: 6px solid var(--cream);
  border-radius: var(--radius);
  background: #A9D3F0;
  box-shadow: var(--shadow-photo);
}
.photo-frame img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: 50% 35%;
}
.hero__tag {
  position: absolute;
  left: -6px;
  bottom: 1.125rem;
  padding: 0.5rem 0.875rem;
  border-radius: 4px;
  background: var(--chile);
  color: var(--white);
  font-family: var(--font-label);
  font-size: 1rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  box-shadow: 0 6px 16px rgba(0, 0, 0, 0.35);
  transform: rotate(-2deg);
}
.hero h1 {
  margin: 0.25rem 0 1rem;
  color: var(--cream);
  font-size: clamp(2.25rem, 1.4rem + 3.8vw, 4.625rem);
  line-height: 1.04;
}
.hero__accent { color: var(--sun); }
.hero__lede {
  max-width: 34rem;
  margin-bottom: 1.5rem;
  color: var(--cream-muted);
  font-size: 1.0625rem;
}
.hero__actions { display: grid; gap: 0.625rem; }
.hero__call { display: none; }
.hero__points {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem 1.5rem;
  margin-top: 1.5rem;
  padding: 0;
  list-style: none;
  color: var(--cream-muted);
  font-size: 0.9375rem;
}
.hero__points li { display: flex; align-items: center; gap: 0.5rem; }
.hero__points svg { flex: none; color: var(--sun); }

/* 8. Sarape stripe ------------------------------------------------------------ */
.sarape {
  height: 10px;
  background: var(--sarape);
}

/* 9. Property types ------------------------------------------------------------ */
.type-grid {
  display: grid;
  gap: 1.25rem;
}
.type-card {
  --accent: var(--chile);
  display: flex;
  flex-direction: column;
  overflow: hidden;
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--radius-card);
}
.type-card--land { --accent: var(--chile); }
.type-card--house { --accent: var(--turquoise); }
.type-card--traila { --accent: var(--ranch); }
.type-card__art {
  aspect-ratio: 2 / 1;
  background: #A9D3F0;
  border-bottom: 4px solid var(--accent);
}
.type-card__art svg { display: block; width: 100%; height: 100%; }
.type-card__body {
  display: flex;
  flex: 1;
  flex-direction: column;
  gap: 0.625rem;
  padding: 1.25rem 1.25rem 1rem;
}
.type-card h3 { font-size: 1.5rem; }
.type-card__body > p { color: var(--muted); }

.check-list {
  display: grid;
  gap: 0.5rem;
  margin: 0.25rem 0 0.5rem;
  padding: 0;
  list-style: none;
}
.check-list li {
  position: relative;
  padding-left: 1.5rem;
}
.check-list li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.3em;
  width: 14px;
  height: 14px;
  background: var(--star-chile) center / contain no-repeat;
}

.ask-card {
  display: grid;
  gap: 1.25rem;
  margin-top: 2rem;
  padding: 1.75rem 1.5rem;
}
.ask-card h3 { font-size: clamp(1.375rem, 1.1rem + 1vw, 1.75rem); }
.ask-card__text > p { margin-top: 0.5rem; color: var(--muted); }
.ask-card__text > .ask-card__tip {
  margin-top: 1rem;
  color: var(--leather);
  font-family: var(--font-label);
  font-size: 1.0625rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}
.ask-list {
  counter-reset: ask;
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-top: 0.5rem;
  padding: 0;
  list-style: none;
}
.ask-list li {
  counter-increment: ask;
  padding: 0.375rem 0.75rem;
  border: 1.5px solid var(--line);
  border-radius: var(--radius);
  background: var(--sand);
  font-weight: 500;
}
.ask-list li::before {
  content: counter(ask) ". ";
  color: var(--chile);
  font-family: var(--font-label);
  font-weight: 700;
}
.ask-card__actions {
  display: grid;
  gap: 0.625rem;
  align-content: center;
}
.ask-card__actions .text-link { justify-self: center; }

/* 10. Cómo funciona -------------------------------------------------------------- */
.band-agave {
  --focus-ring: var(--sun);
  padding-block: 3rem;
  background: var(--agave);
  color: var(--cream);
}
.band-agave h2 { font-size: clamp(1.6875rem, 1.2rem + 2vw, 2.75rem); }
.band-agave a:not(.btn) { color: var(--sun); }
.como {
  display: grid;
  gap: 2rem;
}
.steps {
  display: grid;
  gap: 1.25rem;
  margin-top: 1.5rem;
  padding: 0;
  list-style: none;
}
.steps li { display: flex; align-items: flex-start; gap: 1rem; }
.steps__num {
  display: grid;
  place-items: center;
  flex: none;
  width: 48px;
  height: 48px;
  border-radius: var(--radius);
  background: var(--orange);
  color: var(--leather);
  font-family: var(--font-display);
  font-size: 1.375rem;
  box-shadow: inset 0 0 0 2px rgba(255, 255, 255, 0.4);
}
.steps h3 {
  margin-bottom: 0.25rem;
  font-family: var(--font-label);
  font-size: 1.25rem;
  font-weight: 700;
  letter-spacing: 0.03em;
  line-height: 1.2;
  text-transform: uppercase;
}
.steps p { color: var(--sage); }

.chat-card {
  display: flex;
  flex-direction: column;
  gap: 0.875rem;
  width: 100%;
  max-width: 26rem;
  margin-inline: auto;
  padding: 1.25rem;
  border-radius: var(--radius-card);
  background: var(--chat-bg);
  color: var(--leather);
  box-shadow: 0 14px 30px rgba(0, 0, 0, 0.3);
  --focus-ring: var(--leather);
}
.chat-card__label {
  font-family: var(--font-label);
  font-size: 1rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}
.chat-bubble {
  align-self: flex-end;
  max-width: 19rem;
  padding: 0.625rem 0.875rem 0.375rem;
  border-radius: 14px 14px 4px 14px;
  background: var(--chat-bubble);
  box-shadow: 0 1px 1px rgba(0, 0, 0, 0.12);
}
.chat-bubble__meta {
  display: flex;
  justify-content: flex-end;
  color: var(--teal);
}
.chat-card__note { color: var(--muted); font-size: 0.875rem; }

/* 11. Sobre David ------------------------------------------------------------------ */
.about-card {
  display: grid;
  gap: 1.5rem;
  padding: 1.5rem;
}
.about-card__photo {
  aspect-ratio: 4 / 3;
  overflow: hidden;
  border: 5px solid var(--white);
  border-radius: var(--radius);
  background: var(--cream-muted);
  box-shadow: var(--shadow-card);
}
.about-card__photo img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: 43% 40%;
}
.about-card__text { display: flex; flex-direction: column; gap: 0.75rem; }
.about-card__text .eyebrow { margin: 0; }
.about-card h2 { font-size: clamp(1.625rem, 1.2rem + 1.6vw, 2.25rem); }
.about-card__text > p:not(.eyebrow) { color: var(--muted); }
.about-card__text .about-card__lead { color: var(--leather); font-size: 1.125rem; }
.about-card__text .about-card__social { color: var(--leather); }
.about-card__social a { font-weight: 700; }

/* Plate-tile letters, like the licence-plate "DAVID" in his office. */
.plate-tiles { display: flex; gap: 3px; }
.plate-tiles span {
  display: grid;
  place-items: center;
  width: 24px;
  height: 34px;
  border-radius: 3px;
  color: var(--cream);
  font-family: var(--font-label);
  font-size: 1.3125rem;
  font-weight: 700;
  line-height: 1;
  box-shadow: inset 0 0 0 1.5px rgba(255, 255, 255, 0.45);
}
.plate-tiles span:nth-child(1) { background: var(--turquoise); }
.plate-tiles span:nth-child(2) { background: var(--chile); }
.plate-tiles span:nth-child(3) { background: var(--black-tile); }
.plate-tiles span:nth-child(4) { background: var(--orange); color: var(--leather); }
.plate-tiles span:nth-child(5) { background: var(--ranch-light); }

/* 12. Contacto + form -------------------------------------------------------------- */
.notice {
  display: none;
  margin-bottom: 1.5rem;
  padding: 1rem 1.25rem;
  border-left: 6px solid var(--ranch);
  border-radius: var(--radius-card);
  background: var(--notice);
  color: var(--leather);
}
.notice:target { display: block; }
.notice h3 { margin-bottom: 0.25rem; font-size: 1.375rem; }

.contact-grid {
  display: grid;
  gap: 1.5rem;
  align-items: start;
}

.form-card { padding: 1.5rem 1.25rem; }
.form-card h3 { font-size: 1.5rem; }
.form-hint { margin-top: 0.375rem; color: var(--muted); }
.form-grid {
  display: grid;
  gap: 1rem;
  margin-top: 1.25rem;
}
.field { display: flex; flex-direction: column; gap: 0.375rem; min-width: 0; }
.field label {
  font-family: var(--font-label);
  font-size: 1.0625rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  line-height: 1.2;
  text-transform: uppercase;
}
.field__opt {
  color: var(--muted);
  font-family: var(--font-body);
  font-size: 0.9375rem;
  font-weight: 400;
  letter-spacing: 0;
  text-transform: none;
}
.field input,
.field select,
.field textarea {
  width: 100%;
  min-height: 48px;
  padding: 0.625rem 0.875rem;
  border: 1.5px solid var(--field-line);
  border-radius: var(--radius);
  background: var(--white);
  color: var(--leather);
}
.field textarea { min-height: 7.5rem; resize: vertical; }
.field select {
  -webkit-appearance: none;
  appearance: none;
  padding-right: 2.75rem;
  background: var(--white) var(--chevron) right 0.875rem center / 16px 16px no-repeat;
  cursor: pointer;
}
.field input::placeholder,
.field textarea::placeholder { color: var(--muted); opacity: 1; }
.field input:focus-visible,
.field select:focus-visible,
.field textarea:focus-visible {
  border-color: var(--teal);
  outline-offset: 1px;
}

.consent {
  display: flex;
  align-items: flex-start;
  gap: 0.75rem;
  padding: 0.875rem 1rem;
  border-radius: var(--radius);
  background: var(--sand);
  font-size: 0.9375rem;
}
.consent input {
  flex: none;
  width: 1.375rem;
  height: 1.375rem;
  margin: 0.125rem 0 0;
  accent-color: var(--chile);
  cursor: pointer;
}
.consent { cursor: pointer; }

.form-actions {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  margin-top: 1.25rem;
}
.form-actions .btn { width: 100%; }
.form-status { min-height: 1.5em; font-weight: 700; }
.form-status[data-state="ok"] { color: var(--ranch); }
.form-status[data-state="error"] { color: var(--chile); }
.form-privacy { margin-top: 0.75rem; color: var(--muted); font-size: 0.875rem; }

.contact-aside { display: grid; gap: 1.5rem; }

.call-card {
  --focus-ring: var(--sun);
  position: relative;
  overflow: hidden;
  padding: 2rem 1.5rem 1.5rem;
  border-radius: var(--radius-card);
  background: var(--leather);
  color: var(--cream);
}
.call-card::before {
  content: "";
  position: absolute;
  inset: 0 0 auto;
  height: 8px;
  background: var(--sarape);
}
.call-card h3 { font-size: 1.5rem; }
.call-card__lead { margin-top: 0.25rem; color: var(--cream-muted); }
.call-card__phone {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  margin: 0.5rem 0 1rem;
  color: var(--sun);
  font-family: var(--font-display);
  font-size: clamp(1.5rem, 1.2rem + 1.4vw, 2rem);
  text-decoration: none;
}
.call-card__phone:hover { color: var(--sun); text-decoration: underline; }
.call-card__phone:empty { display: none; }
.call-card__actions { display: grid; gap: 0.625rem; }

.office-card {
  overflow: hidden;
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--radius-card);
}
.office-card__map {
  aspect-ratio: 8 / 3;
  background: #E8D9BC;
  border-bottom: 4px solid var(--turquoise);
}
.office-card__map svg { display: block; width: 100%; height: 100%; }
.office-card__body {
  display: grid;
  gap: 0.625rem;
  padding: 1.25rem 1.5rem 1.5rem;
}
.office-card__body .eyebrow { margin: 0; }
.office-card h3 { font-size: 1.375rem; }
.office-line {
  display: flex;
  align-items: flex-start;
  gap: 0.625rem;
}
.office-line .icon { width: 20px; height: 20px; margin-top: 0.125rem; color: var(--chile); }
.office-line:has(> .office-line__text:empty) { display: none; }

/* 13. Footer -------------------------------------------------------------------- */
.site-footer {
  --focus-ring: var(--sun);
  position: relative;
  padding: calc(12px + 2.5rem) 0 2rem;
  background: var(--leather);
  color: var(--cream-muted);
}
.site-footer::before {
  content: "";
  position: absolute;
  inset: 0 0 auto;
  height: 12px;
  background: var(--sarape);
}
.site-footer a { color: var(--cream); }
.site-footer a:hover { color: var(--sun); }
.site-footer__grid { display: grid; gap: 2rem; }
.site-footer__brand img { width: 200px; height: auto; }
.site-footer__brand p { margin-top: 0.75rem; }
.site-footer__title {
  margin-bottom: 0.5rem;
  color: var(--sun);
  font-family: var(--font-label);
  font-size: 1.125rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}
.site-footer__nav ul,
.site-footer__contact ul {
  display: grid;
  gap: 0;
  padding: 0;
  list-style: none;
}
.site-footer__nav a,
.site-footer__contact a {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
}
.site-footer__contact li:has(> a:empty),
.site-footer__text:empty { display: none; }
.site-footer__text { padding-block: 0.375rem; }

/* <!--g2:social-links--> renders ul.g2-social-links > li > a > svg */
.g2-social-links {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin: 1rem 0 0;
  padding: 0;
  list-style: none;
}
.g2-social-links a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  border-radius: var(--radius);
  background: var(--leather-raised);
  color: var(--cream);
}
.g2-social-links a:hover { background: var(--leather-line); color: var(--sun); }
.g2-social-links svg { width: 24px; height: 24px; }

.site-footer__legal {
  display: grid;
  gap: 0.75rem;
  margin-top: 2.5rem;
  padding-top: 1.5rem;
  /* A 1px rule inside the gutters (a border would run under the padding). */
  background: linear-gradient(var(--leather-line), var(--leather-line)) var(--gutter) 0 / calc(100% - 2 * var(--gutter)) 1px no-repeat;
  font-size: 0.9375rem;
}
.site-footer__legal p { max-width: 62rem; }
.site-footer__bottom {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem 1.5rem;
  margin-top: 0.5rem;
}
.site-footer__bottom a {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
}
.eho {
  display: inline-flex;
  align-items: center;
  gap: 0.625rem;
  color: var(--cream);
  font-weight: 700;
}
.eho img {
  width: 34px;
  height: 34px;
  padding: 3px;
  border-radius: 4px;
  background: var(--cream);
}
.credit { font-size: 0.875rem; }

/* Footer variant: <p> rows directly in .site-footer (secondary pages). */
.site-footer:not(:has(> .wrap)) {
  display: grid;
  gap: 0.5rem;
  padding-inline: max(var(--gutter), calc((100% - var(--wrap-max)) / 2));
}
.site-footer > p { display: flex; flex-wrap: wrap; align-items: center; gap: 0.625rem; }
.site-footer > p:empty { display: none; }
.site-footer > p > a { display: inline-flex; align-items: center; min-height: 44px; }
.site-footer > p > img {
  width: 34px;
  height: 34px;
  padding: 3px;
  border-radius: 4px;
  background: var(--cream);
}

/* 14. Mobile call bar ------------------------------------------------------------ */
.mobile-bar {
  --focus-ring: var(--sun);
  position: fixed;
  right: 0;
  bottom: 0;
  left: 0;
  z-index: 50;
  display: flex;
  gap: 0.625rem;
  padding: 0.625rem var(--gutter) calc(0.75rem + env(safe-area-inset-bottom, 0px));
  background: var(--leather);
  border-top: 3px solid var(--chile);
  box-shadow: 0 -6px 18px rgba(0, 0, 0, 0.25);
}
.mobile-bar .btn { min-height: 52px; font-size: 1.125rem; }
.mobile-bar__call { flex: 1 1 0; }
.mobile-bar__wa { flex: 0 0 auto; }
/* Room under the footer so the fixed bar never covers it (footer keeps its
   leather background all the way down). */
body.has-mobile-bar .site-footer { padding-bottom: calc(2rem + var(--mobile-bar-space) + env(safe-area-inset-bottom, 0px)); }

/* 15. 404 page ------------------------------------------------------------------- */
.page-404 {
  max-width: 40rem;
  margin-inline: auto;
  padding-block: 3.5rem 4.5rem;
  text-align: center;
}
.page-404::before {
  content: "";
  display: block;
  width: 56px;
  height: 56px;
  margin: 0 auto 1.25rem;
  background: var(--star-chile) center / contain no-repeat;
}
.page-404 .eyebrow { justify-content: center; }
.page-404 h1 {
  margin-bottom: 1rem;
  font-size: clamp(2.25rem, 1.5rem + 3.5vw, 4rem);
  line-height: 1.05;
}
.page-404 p:not(.eyebrow) { margin-bottom: 1rem; color: var(--muted); font-size: 1.125rem; }
.page-404__actions,
.page-404 .actions,
.page-404 p:has(> .btn) {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0.75rem;
  margin-top: 1.75rem;
}

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

/* Honeypot: off-screen, never type=hidden (kit rule). */
.hp {
  position: absolute;
  left: -10000px;
  width: 1px;
  height: 1px;
  overflow: hidden;
}

/* ---- 640px ---- */
@media (min-width: 40em) {
  :root { --gutter: 1.5rem; }
  .sarape { height: 12px; }
  .photo-frame { aspect-ratio: 1 / 1; border-width: 8px; }
  .hero__tag { left: -10px; bottom: 1.75rem; font-size: 1.125rem; padding: 0.625rem 1.125rem; }
  .hero__actions { display: flex; flex-wrap: wrap; gap: 0.75rem; }
  .eyebrow { font-size: 1.0625rem; }

  .type-card { display: grid; grid-template-columns: minmax(0, 15rem) minmax(0, 1fr); }
  .type-card__art { aspect-ratio: auto; border-bottom: 0; border-right: 4px solid var(--accent); }

  .ask-card { padding: 2rem; }
  .ask-card__actions { grid-template-columns: 1fr 1fr; }
  .ask-card__actions .text-link { grid-column: 1 / -1; }

  .about-card { grid-template-columns: minmax(0, 14rem) minmax(0, 1fr); align-items: center; padding: 2rem; }
  .about-card__photo { aspect-ratio: 4 / 5; }

  .form-card { padding: 2rem; }
  .form-grid { grid-template-columns: 1fr 1fr; }
  .field--full { grid-column: 1 / -1; }
  .form-actions { flex-direction: row; align-items: center; flex-wrap: wrap; }
  .form-actions .btn { width: auto; }
  .form-status { flex: 1 1 14rem; }

  .site-footer__grid { grid-template-columns: 1fr 1fr; }
  .site-footer__brand { grid-column: 1 / -1; }
}

/* ---- 900px ---- */
@media (min-width: 56.25em) {
  body { font-size: 1.0625rem; }
  .section { padding-block: 4.5rem; }
  .band-agave { padding-block: 4.5rem; }

  .hero { padding: 3.5rem 0 4rem; }
  .hero__inner {
    grid-template-columns: minmax(0, 1.1fr) minmax(0, 0.9fr);
    gap: 3rem;
    align-items: center;
  }
  .hero__media { order: 0; }
  .hero__lede { font-size: 1.25rem; }
  .hero__points { font-size: 1rem; }
  .hero__star { top: -6rem; right: -4rem; width: 36rem; height: 36rem; }

  .section-lede { font-size: 1.125rem; }

  .type-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 1.5rem; }
  .type-card { display: flex; }
  .type-card__art { aspect-ratio: 2 / 1; min-height: 0; border-right: 0; border-bottom: 4px solid var(--accent); }
  .type-card__body { padding: 1.375rem 1.5rem 1.25rem; }
  .type-card h3 { font-size: 1.625rem; }

  .ask-card {
    grid-template-columns: minmax(0, 1fr) minmax(16rem, 20rem);
    gap: 2.5rem;
    align-items: center;
    padding: 2.25rem 2.5rem;
  }
  .ask-card__actions { grid-template-columns: 1fr; }

  .como {
    grid-template-columns: minmax(0, 1.15fr) minmax(0, 1fr);
    gap: 3rem;
    align-items: center;
  }
  .steps { gap: 1.5rem; margin-top: 2rem; }
  .steps h3 { font-size: 1.375rem; }

  .about-card { grid-template-columns: minmax(0, 20rem) minmax(0, 1fr); gap: 2.5rem; padding: 2.5rem; }
  .about-card__photo { transform: rotate(-1.5deg); }

  .contact-grid { grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr); gap: 2rem; }

  .site-footer__grid { grid-template-columns: minmax(0, 1.3fr) minmax(0, 1fr) minmax(0, 1.2fr); }
  .site-footer__brand { grid-column: auto; }
}

/* ---- 1024px: desktop header, no bottom bar ---- */
@media (min-width: 64em) {
  .topbar {
    --focus-ring: var(--sun);
    display: block;
    background: var(--leather-deep);
    color: var(--cream-muted);
    font-size: 0.875rem;
  }
  .topbar__inner {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    gap: 0.25rem 1.5rem;
    padding-block: 0.375rem;
  }
  .topbar a { color: var(--sun); font-weight: 700; text-decoration: none; }
  .topbar a:hover { color: var(--sun); text-decoration: underline; }

  .site-header__inner { flex-wrap: nowrap; padding-block: 1rem; }
  .brand img { width: 190px; }
  .nav-toggle { display: none; }
  .site-nav,
  .has-js-nav .site-nav {
    display: flex;
    flex-basis: auto;
    align-items: center;
    gap: 1.5rem;
  }
  .site-nav__links { flex-wrap: nowrap; gap: 0 1.375rem; }
  .site-nav__actions { display: flex; gap: 0.625rem; }
  .site-nav__wa { display: none; }

  .hero__call { display: inline-flex; }

  .mobile-bar { display: none; }
  body.has-mobile-bar .site-footer { padding-bottom: 2rem; }
}

/* ---- 1200px ---- */
@media (min-width: 75em) {
  .brand img { width: 210px; }
  .site-nav { gap: 1.75rem; }
  .site-nav__links { gap: 0 1.75rem; }
  .site-nav__wa { display: inline-flex; }
}

/* Motion: nothing moves for people who ask for less. */
@media (prefers-reduced-motion: no-preference) {
  html { scroll-behavior: smooth; }
  .btn,
  .card-link,
  .site-nav__links a,
  .g2-social-links a {
    transition: background-color 0.15s ease, color 0.15s ease, border-color 0.15s ease;
  }
}

/* Windows high contrast: keep the cards and the seam visible. */
@media (forced-colors: active) {
  .btn { border-color: ButtonText; }
  .stitched,
  .type-card,
  .office-card { border-color: CanvasText; }
}

@media print {
  .topbar,
  .nav-toggle,
  .site-nav,
  .mobile-bar,
  .hero__star,
  .sarape { display: none !important; }
  body.has-mobile-bar .site-footer { padding-bottom: 2rem; }
  .hero,
  .band-agave,
  .site-footer,
  .call-card { background: none; color: #000; }
}

/* Turnstile bot check (kit /kit/lead-guard.js renders into [data-g2-turnstile]
   when the server has TURNSTILE_* set). Reserve the widget's height so the
   submit button does not jump when it loads; empty when the check is off. */
.turnstile-slot:not(:empty) { min-height: 65px; margin-block: 0.25rem 0.75rem; }
