/* Mexico Residency Partners
   Palette sampled from the logo:
   navy #132B47, terracotta #BD5C39, gold #CFAF7C, cream #FDF8F2 */
:root {
  --navy: #132B47;
  --navy-deep: #0C1E34;
  --navy-soft: #243A58;
  --terracotta: #BD5C39;
  --terracotta-deep: #8E4328;
  --gold: #CFAF7C;
  --gold-deep: #8C7040;
  --cream: #FDF8F2;
  --paper: #FFFCFA;
  --sand: #F3EBE1;
  --ink: #1A2430;
  --muted: #5A6572;
  --line: #E6DDD2;
  --radius: 16px;
  --shadow: 0 18px 44px rgba(19, 43, 71, 0.08);
  --font-head: "Libre Baskerville", "Iowan Old Style", Palatino, Georgia, serif;
  --font-body: "Source Sans 3", "Segoe UI", system-ui, sans-serif;
  --header-h: 96px;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: calc(var(--header-h) + 12px); }
body {
  margin: 0;
  font-family: var(--font-body);
  font-size: 1.075rem;
  line-height: 1.65;
  color: var(--ink);
  background: var(--paper);
  -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; height: auto; display: block; }
a { color: var(--navy); }
h1, h2, h3 {
  font-family: var(--font-head);
  color: var(--navy);
  line-height: 1.18;
  font-weight: 700;
  margin: 0 0 0.55em;
  letter-spacing: -0.01em;
}
h1 { font-size: clamp(2.35rem, 5vw, 3.55rem); line-height: 1.12; }
h2 { font-size: clamp(1.8rem, 3vw, 2.45rem); }
h3 { font-size: 1.28rem; margin-bottom: 0.35em; }
p { margin: 0 0 1em; }

.container { width: min(1100px, calc(100% - 2.5rem)); margin-inline: auto; }
.sr-only {
  position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0,0,0,0); white-space: nowrap; border: 0;
}
.skip-link {
  position: absolute; left: -9999px; top: 0;
  background: var(--navy); color: #fff; padding: .6rem 1rem; z-index: 100;
}
.skip-link:focus { left: 1rem; top: 1rem; }

.eyebrow {
  font-family: var(--font-body);
  font-size: .78rem;
  font-weight: 700;
  letter-spacing: .16em;
  text-transform: uppercase;
  color: var(--terracotta-deep);
  margin: 0 0 .7rem;
}
.eyebrow-light { color: var(--gold); }
.rule {
  display: block; width: 56px; height: 3px;
  background: linear-gradient(90deg, var(--terracotta), var(--gold));
  border-radius: 2px; margin: .35rem 0 0;
}
.rule-center { margin-inline: auto; }

.btn {
  display: inline-flex; align-items: center; justify-content: center;
  min-height: 48px; padding: .75rem 1.3rem;
  border-radius: 999px; text-decoration: none; font-weight: 650;
  border: 1.5px solid transparent; cursor: pointer;
  font-family: var(--font-body); font-size: 1rem; line-height: 1;
}
.btn-primary { background: var(--navy); color: #fff; }
.btn-primary:hover { background: var(--navy-deep); }
.btn-ghost { background: transparent; color: var(--navy); border-color: rgba(19, 43, 71, .3); }
.btn-ghost:hover { border-color: var(--navy); background: #fff; }
.btn-terra { background: var(--terracotta-deep); color: #fff; border: 0; }
.btn-terra:hover { background: #743620; }
.btn:focus-visible, a:focus-visible, button:focus-visible,
input:focus-visible, select:focus-visible, textarea:focus-visible, summary:focus-visible {
  outline: 3px solid var(--gold); outline-offset: 2px;
}
.text-link { font-weight: 650; color: var(--terracotta-deep); }

.site-header {
  position: sticky; top: 0; z-index: 40;
  background: rgba(253, 248, 242, .96);
  backdrop-filter: saturate(140%) blur(10px);
  border-bottom: 1px solid var(--line);
  box-shadow: inset 0 3px 0 var(--navy);
}
.header-inner {
  display: flex; align-items: center; justify-content: space-between;
  min-height: var(--header-h); gap: 1rem;
}
.brand { display: flex; align-items: center; text-decoration: none; color: inherit; }
.brand-lockup { height: 84px; width: auto; }
.brand-mark { display: none; height: 52px; width: 52px; }
.site-nav ul {
  display: flex; gap: .15rem 1.05rem; list-style: none; margin: 0; padding: 0; align-items: center;
}
.site-nav a { text-decoration: none; color: var(--navy); font-weight: 600; font-size: .98rem; }
.site-nav a:hover { color: var(--terracotta-deep); }
.nav-cta {
  background: var(--navy); color: #fff !important;
  padding: .45rem .9rem; border-radius: 999px;
}
.nav-cta:hover { background: var(--navy-deep); color: #fff !important; }
.nav-toggle, .nav-toggle-label { display: none; }

.hero {
  background:
    radial-gradient(820px 380px at 92% -8%, rgba(189, 92, 57, .12), transparent 58%),
    radial-gradient(700px 320px at 0% 100%, rgba(207, 175, 124, .22), transparent 55%),
    linear-gradient(180deg, var(--cream) 0%, var(--paper) 100%);
  padding: 2.6rem 0 3.4rem;
}
.hero-inner {
  display: grid; grid-template-columns: 1.05fr .95fr; gap: 2.2rem; align-items: center;
}
.tagline {
  font-family: var(--font-head);
  font-size: 1.15rem;
  color: var(--navy);
  margin: -.2rem 0 1rem;
}
.lede { font-size: 1.16rem; color: var(--muted); max-width: 38rem; }
.hero-actions { display: flex; flex-wrap: wrap; gap: .75rem; margin-top: 1.35rem; }
.hero-logo {
  justify-self: center;
  width: min(520px, 100%);
  background: var(--cream);
  border-radius: 18px;
  padding: .4rem;
}

.section { padding: 4.4rem 0; }
.section-head { max-width: 40rem; margin-bottom: 2rem; }
.section-head.center { text-align: center; margin-inline: auto; }
.section-head.center .section-intro { margin-inline: auto; }
.section-intro { font-size: 1.12rem; color: #24303a; max-width: 42rem; }

.how { background: #fff; }
.steps {
  list-style: none; margin: 0; padding: 0;
  display: grid; gap: .85rem;
  counter-reset: step;
}
.steps li {
  display: grid; grid-template-columns: auto 1fr; gap: 1rem 1.15rem;
  align-items: start;
  background: var(--cream);
  border-radius: var(--radius);
  padding: 1.05rem 1.15rem 1rem;
  border-left: 4px solid var(--terracotta);
}
.steps li::before {
  counter-increment: step;
  content: counter(step);
  font-family: var(--font-head);
  font-size: 1.55rem;
  color: var(--terracotta-deep);
  line-height: 1;
  width: 2rem;
  padding-top: .15rem;
}
.steps h3 { margin: 0 0 .25rem; font-size: 1.15rem; }
.steps p { margin: 0; color: var(--muted); }

.services { background: var(--sand); }
.service-grid {
  list-style: none; margin: 0; padding: 0;
  display: grid; grid-template-columns: repeat(3, 1fr); gap: 1rem;
}
.service-grid li {
  background: #fff;
  border-radius: var(--radius);
  padding: 1.35rem 1.2rem 1.2rem;
  border-top: 4px solid var(--gold);
  box-shadow: 0 10px 28px rgba(19, 43, 71, .05);
  display: flex; flex-direction: column;
}
.service-grid li.core { border-top-color: var(--terracotta); }
.badge {
  align-self: flex-start;
  font-size: .72rem; font-weight: 700; letter-spacing: .12em; text-transform: uppercase;
  color: var(--navy); background: #F6E7C8; border-radius: 999px;
  padding: .28rem .55rem; margin-bottom: .7rem;
}
.badge-quiet { background: var(--sand); color: var(--navy-soft); }
.service-grid p { color: var(--muted); margin: 0 0 .9rem; flex: 1; }
.service-grid .text-link { margin-top: auto; }

.car { background: #fff; }
.split { display: grid; grid-template-columns: .9fr 1.1fr; gap: 2.4rem; align-items: start; }
.prose p { font-size: 1.1rem; color: #24303a; }
.callout {
  background: var(--cream);
  border-radius: var(--radius);
  padding: 1.25rem 1.3rem 1.1rem;
  border-top: 4px solid var(--navy);
  margin-top: .4rem;
}
.callout p:last-child { margin-bottom: 0; }
.callout strong { color: var(--navy); }

.who { background: var(--cream); }
.role-grid {
  list-style: none; margin: 0; padding: 0;
  display: grid; grid-template-columns: 1fr 1fr; gap: 1rem;
}
.role-grid li {
  background: #fff;
  border-radius: var(--radius);
  padding: 1.2rem 1.2rem 1.05rem;
  box-shadow: 0 8px 22px rgba(19, 43, 71, .04);
}
.role-grid h3 { font-size: 1.12rem; }
.role-kicker {
  display: block; font-family: var(--font-body);
  font-size: .72rem; font-weight: 700; letter-spacing: .14em;
  text-transform: uppercase; color: var(--gold-deep); margin-bottom: .35rem;
}
.role-grid p { margin: 0; color: var(--muted); }
.role-grid li.span { grid-column: 1 / -1; }

.faq { background: #fff; }
.faq-list { display: grid; gap: .65rem; max-width: 46rem; }
.faq-list details {
  background: var(--cream);
  border-radius: 12px;
  padding: .85rem 1.05rem;
  border: 1px solid transparent;
}
.faq-list details[open] { background: #fff; border-color: var(--line); }
.faq-list summary {
  cursor: pointer; font-weight: 700; color: var(--navy);
  font-size: 1.05rem; list-style: none;
  display: flex; justify-content: space-between; gap: 1rem; align-items: center;
}
.faq-list summary::-webkit-details-marker { display: none; }
.faq-list summary::after {
  content: "+"; font-family: var(--font-head); font-size: 1.4rem;
  color: var(--terracotta); line-height: 1; flex: none;
}
.faq-list details[open] summary::after { content: "\2013"; }
.faq-list details p { margin: .7rem 0 0; color: #24303a; }

.contact { background: var(--navy-deep); color: #F4EFE6; }
.contact h2, .contact h3 { color: #fff; }
.contact-inner { display: grid; grid-template-columns: .85fr 1.15fr; gap: 2.5rem; align-items: start; }
.contact-lede { color: #D5D0C6; max-width: 28rem; }
.contact-list { list-style: none; margin: 1.4rem 0 0; padding: 0; display: grid; gap: .95rem; }
.contact-label {
  display: block; font-size: .75rem; letter-spacing: .14em; text-transform: uppercase;
  color: var(--gold); font-weight: 700; margin-bottom: .15rem;
}
.contact-list a { color: #fff; font-weight: 650; }
.form-card {
  background: #fff; color: var(--ink);
  border-radius: 18px; padding: 1.6rem 1.5rem 1.4rem;
  box-shadow: var(--shadow);
}
.form-card h3 { color: var(--navy); }
.form-intro { color: var(--muted); font-size: .95rem; }
.req { color: var(--terracotta-deep); }
.optional { color: var(--muted); font-weight: 500; font-size: .9rem; }
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: .9rem; }
.field { margin-bottom: .85rem; }
.field label { display: block; font-weight: 650; margin-bottom: .3rem; font-size: .95rem; }
.field input, .field select, .field textarea {
  width: 100%; font: inherit; color: var(--ink);
  background: var(--cream); border: 1px solid #DDD4C6; border-radius: 10px;
  padding: .7rem .8rem;
}
.field textarea { resize: vertical; min-height: 130px; }
.field input[aria-invalid="true"], .field select[aria-invalid="true"], .field textarea[aria-invalid="true"] {
  border-color: var(--terracotta-deep); background: #FBF4F2;
}
.field-error { min-height: 1.1em; margin: .25rem 0 0; color: var(--terracotta-deep); font-size: .88rem; }
.form-actions { display: flex; flex-wrap: wrap; align-items: center; gap: .8rem 1rem; }
.form-status { margin: 0; font-size: .95rem; }
.form-status.is-error { color: var(--terracotta-deep); }
.form-status.is-success { color: #2E5A3C; }
.hp { position: absolute; left: -9999px; height: 0; overflow: hidden; }
button:disabled { opacity: .7; cursor: progress; }

.site-footer { background: var(--navy); color: #E7E1D6; padding: 1.7rem 0 1.9rem; }
.footer-inner { display: grid; gap: .7rem; }
.footer-brand { display: flex; align-items: center; gap: .8rem; }
.footer-brand img { width: 48px; height: 48px; }
.footer-name { font-family: var(--font-head); color: #fff; font-size: 1.05rem; margin: 0; }
.disclaimer { margin: 0; max-width: 46rem; color: #D9D2C6; font-size: .98rem; }
.parent, .legal { margin: 0; }
.parent a { color: var(--gold); font-weight: 650; }
.legal { color: #C9C2B6; }
.footer-meta { display: flex; flex-wrap: wrap; gap: .4rem 1.2rem; align-items: baseline; }

.simple-page { background: var(--cream); min-height: 100vh; }
.simple {
  min-height: 100vh; display: grid; place-content: center; justify-items: center;
  text-align: center; padding: 2rem 1.25rem; max-width: 38rem; margin: 0 auto;
}
.simple img { width: min(280px, 80vw); height: auto; margin-bottom: .6rem; }
.simple p { color: var(--muted); }

@media (max-width: 900px) {
  :root { --header-h: 74px; }
  .hero-inner, .split, .contact-inner, .service-grid, .role-grid { grid-template-columns: 1fr; }
  .role-grid li.span { grid-column: auto; }
  .hero { padding-top: 1.6rem; }
  .hero-logo { order: -1; }
  .section { padding: 3.1rem 0; }
  .form-row { grid-template-columns: 1fr; }
  .brand-lockup { display: block; height: 58px; }
  .brand-mark { display: none; }
  .nav-toggle-label {
    display: flex; width: 44px; height: 44px; align-items: center; justify-content: center; cursor: pointer;
  }
  .nav-toggle-label span, .nav-toggle-label span::before, .nav-toggle-label span::after {
    display: block; width: 22px; height: 2px; background: var(--navy); position: relative; border-radius: 2px;
  }
  .nav-toggle-label span::before, .nav-toggle-label span::after { content: ""; position: absolute; left: 0; }
  .nav-toggle-label span::before { top: -7px; }
  .nav-toggle-label span::after { top: 7px; }
  .site-nav {
    display: none; position: absolute; left: 0; right: 0; top: var(--header-h);
    background: var(--cream); border-bottom: 1px solid var(--line); padding: .5rem 1.25rem 1rem;
  }
  .site-nav ul { flex-direction: column; align-items: flex-start; gap: .15rem; }
  .site-nav a { display: inline-block; padding: .5rem 0; }
  .nav-toggle:checked ~ .site-nav { display: block; }
  .nav-cta { margin-top: .25rem; }
}

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