/* ===========================================================
   Carpa Financieros — shared stylesheet
   Palette sampled from the live site.
   =========================================================== */

@import url('https://fonts.googleapis.com/css2?family=Cormorant+Garamond:ital,wght@0,400;0,500;0,600;1,400&family=Jost:wght@300;400;500&display=swap');

:root {
  --taupe:      #b9a590;   /* primary page background       */
  --taupe-dark: #ad9880;   /* subtle section contrast       */
  --cream:      #ece4da;   /* light sections / footer       */
  --cream-soft: #f3ede5;   /* lightest panels               */
  --ink:        #36302a;   /* headings, buttons, body ink   */
  --ink-soft:   #5b5147;   /* secondary text                */
  --ink-muted:  #837564;   /* hints / required labels       */
  --line:       #6f6356;   /* hairline borders on taupe     */
  --line-cream: #cbbda9;   /* hairline borders on cream     */

  --serif: 'Cormorant Garamond', Georgia, 'Times New Roman', serif;
  --sans:  'Jost', 'Helvetica Neue', Arial, sans-serif;

  --maxw: 1280px;
  --gutter: clamp(22px, 5vw, 88px);
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: var(--sans);
  font-weight: 400;
  background: var(--taupe);
  color: var(--ink);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  font-size: 18px;
  line-height: 1.6;
}

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

a { color: inherit; text-decoration: none; }

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

/* ---------- Typography ---------- */
h1, h2, h3 {
  font-family: var(--serif);
  font-weight: 500;
  margin: 0;
  line-height: 1.05;
  letter-spacing: 0.005em;
  text-wrap: balance;
}

h1 { font-size: clamp(2.8rem, 6vw, 5rem); }
h2 { font-size: clamp(2.1rem, 4vw, 3.3rem); }
h3 { font-size: clamp(1.5rem, 2.4vw, 2rem); }

p { margin: 0 0 1em; text-wrap: pretty; }

.eyebrow {
  font-family: var(--sans);
  font-weight: 400;
  font-size: 0.78rem;
  letter-spacing: 0.28em;
  text-transform: uppercase;
  color: var(--ink-muted);
  margin: 0 0 1.4rem;
}

.lead { font-size: clamp(1.05rem, 1.6vw, 1.3rem); color: var(--ink-soft); }

/* ---------- Header ---------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: var(--taupe);
  border-bottom: 1px solid rgba(54,48,42,0.10);
}
.site-header.on-cream { background: var(--cream); border-bottom-color: rgba(54,48,42,0.08); }

.site-header .wrap {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 88px;
  position: relative;
}
.brand {
  font-family: var(--serif);
  font-weight: 500;
  font-size: 1.85rem;
  letter-spacing: 0.01em;
  color: var(--ink);
  white-space: nowrap;
  flex: none;
}
.nav {
  display: flex;
  align-items: center;
  gap: clamp(20px, 3vw, 46px);
  font-family: var(--serif);
  font-size: 1.28rem;
}
.nav a {
  position: relative;
  padding-bottom: 2px;
  color: var(--ink);
  transition: opacity .2s ease;
}
.nav a::after {
  content: '';
  position: absolute;
  left: 0; right: 100%; bottom: -1px;
  height: 1px; background: var(--ink);
  transition: right .28s ease;
}
.nav a:hover::after { right: 0; }
.nav a[aria-current="page"]::after { right: 0; }

/* Mobile menu toggle (hidden on desktop) */
.menu-toggle {
  display: none;
  width: 46px; height: 46px;
  margin-right: -8px;
  border: none;
  background: transparent;
  cursor: pointer;
  position: relative;
  z-index: 60;
}
.menu-toggle span {
  position: absolute;
  left: 11px; right: 11px;
  height: 2px;
  background: var(--ink);
  border-radius: 2px;
  transition: transform .3s ease, opacity .2s ease, top .3s ease;
}
.menu-toggle span:nth-child(1) { top: 16px; }
.menu-toggle span:nth-child(2) { top: 22px; }
.menu-toggle span:nth-child(3) { top: 28px; }
.site-header[data-open] .menu-toggle span:nth-child(1) { top: 22px; transform: rotate(45deg); }
.site-header[data-open] .menu-toggle span:nth-child(2) { opacity: 0; }
.site-header[data-open] .menu-toggle span:nth-child(3) { top: 22px; transform: rotate(-45deg); }

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: .6em;
  font-family: var(--sans);
  font-size: 1rem;
  letter-spacing: 0.02em;
  padding: 1.05em 2.4em;
  border-radius: 999px;
  white-space: nowrap;
  border: 1px solid var(--ink);
  background: var(--ink);
  color: var(--cream);
  cursor: pointer;
  transition: background .25s ease, color .25s ease, transform .25s ease;
}
.btn:hover { background: transparent; color: var(--ink); }
.btn--ghost { background: transparent; color: var(--ink); }
.btn--ghost:hover { background: var(--ink); color: var(--cream); }

/* ---------- Section rhythm ---------- */
section { padding-block: clamp(64px, 9vw, 130px); }
.section--cream { background: var(--cream); color: var(--ink); }

.section-head { max-width: 60ch; margin-bottom: clamp(36px, 5vw, 60px); }

/* ---------- Hero (full-bleed, veil + overlaid white text) ---------- */
.hero-full {
  position: relative;
  width: 100%;
  min-height: clamp(540px, 82vh, 880px);
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  overflow: hidden;
  padding-block: 0;
}
.hero-full__img { position: absolute; inset: 0; z-index: 0; }
.hero-full__img img { width: 100%; height: 100%; object-fit: cover; }
.hero-full::after {
  content: '';
  position: absolute; inset: 0; z-index: 1;
  background:
    radial-gradient(125% 95% at 50% 48%, rgba(26,21,17,0.40) 0%, rgba(26,21,17,0.52) 58%, rgba(26,21,17,0.64) 100%),
    linear-gradient(180deg, rgba(26,21,17,0.34) 0%, rgba(26,21,17,0.40) 50%, rgba(26,21,17,0.66) 100%);
}
.hero-full__inner {
  position: relative;
  z-index: 2;
  max-width: clamp(620px, 88vw, 1240px);
  padding-inline: var(--gutter);
  color: #f6f1ea;
}
.hero-full__inner h1 {
  color: #fdfbf7;
  max-width: 32ch;
  margin-inline: auto;
  font-size: clamp(2.8rem, 5vw, 4.2rem);
  text-shadow: 0 2px 40px rgba(18,14,10,0.6);
}
.hero-full__sub {
  margin: 1.5rem auto 0;
  max-width: 66ch;
  font-family: var(--sans);
  font-weight: 300;
  font-size: clamp(1.1rem, 1.7vw, 1.42rem);
  line-height: 1.5;
  color: rgba(248,243,236,0.94);
  text-shadow: 0 2px 28px rgba(18,14,10,0.6);
}

/* ---------- Split (text + image) ---------- */
.split {
  display: grid;
  grid-template-columns: 1.05fr 1fr;
  gap: clamp(36px, 6vw, 92px);
  align-items: center;
}
.split--rev .split__media { order: -1; }
.split__media {
  aspect-ratio: 4 / 5;
  overflow: hidden;
  border-radius: 4px;
}
.split__media img { width: 100%; height: 100%; object-fit: cover; }

/* feature bullet list */
.checklist { list-style: none; margin: 0; padding: 0; }
.checklist li {
  position: relative;
  padding: 1.05rem 0 1.05rem 2.2rem;
  border-bottom: 1px solid rgba(54,48,42,0.16);
  font-size: 1.12rem;
  line-height: 1.45;
}
.checklist li:first-child { border-top: 1px solid rgba(54,48,42,0.16); }
.checklist li::before {
  content: '';
  position: absolute;
  left: 2px; top: 1.55rem;
  width: 9px; height: 9px;
  border: 1px solid var(--ink);
  transform: rotate(45deg);
}
.checklist strong { font-weight: 500; }

/* ---------- Reasons grid ---------- */
.reasons {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: clamp(28px, 3.4vw, 54px) clamp(34px, 4vw, 70px);
}
.reason h3 {
  font-size: 1.7rem;
  margin-bottom: .5rem;
  padding-bottom: .7rem;
  border-bottom: 1px solid rgba(54,48,42,0.22);
}
.reason p { color: var(--ink-soft); font-size: 1.02rem; margin: 0; }

/* ---------- Steps ---------- */
.steps {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: clamp(26px, 3vw, 50px);
}
.step__media { aspect-ratio: 3 / 4; overflow: hidden; border-radius: 4px; }
.step__media img { width: 100%; height: 100%; object-fit: cover; transition: transform .9s ease; }
.step:hover .step__media img { transform: scale(1.04); }
.step__num {
  font-family: var(--serif);
  font-size: 1.05rem;
  letter-spacing: .04em;
  color: var(--ink-muted);
  margin: 1.4rem 0 .5rem;
}
.step h3 { font-size: 1.85rem; margin-bottom: .6rem; }
.step p { color: var(--ink-soft); font-size: 1.02rem; margin: 0; }

/* ---------- FAQ ---------- */
.faq { max-width: 940px; }
.faq details {
  border-bottom: 1px solid rgba(54,48,42,0.2);
}
.faq details:first-of-type { border-top: 1px solid rgba(54,48,42,0.2); }
.faq summary {
  list-style: none;
  cursor: pointer;
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 2rem;
  padding: 1.5rem 0;
  font-family: var(--serif);
  font-size: clamp(1.3rem, 2vw, 1.65rem);
  font-weight: 500;
  color: var(--ink);
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary .ico {
  flex: none;
  width: 26px; height: 26px;
  position: relative;
  margin-top: .35em;
}
.faq summary .ico::before,
.faq summary .ico::after {
  content: '';
  position: absolute;
  background: var(--ink);
  left: 50%; top: 50%;
  transition: transform .3s ease, opacity .3s ease;
}
.faq summary .ico::before { width: 18px; height: 1.5px; transform: translate(-50%,-50%); }
.faq summary .ico::after  { width: 1.5px; height: 18px; transform: translate(-50%,-50%); }
.faq details[open] summary .ico::after { transform: translate(-50%,-50%) scaleY(0); opacity: 0; }
.faq .faq__body {
  padding: 0 3.4rem 1.8rem 0;
  color: var(--ink-soft);
  font-size: 1.08rem;
  max-width: 80ch;
}
.faq .faq__body p:last-child { margin-bottom: 0; }

/* ---------- CTA band ---------- */
.cta { text-align: center; }
.cta .wrap { display: flex; flex-direction: column; align-items: center; }
.cta p { max-width: 52ch; font-size: clamp(1.15rem, 2vw, 1.5rem); color: var(--ink-soft); }
.cta h2 { margin: .4rem 0 2rem; }

/* ---------- Contact page ---------- */
.contact {
  min-height: calc(100vh - 88px);
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: clamp(40px, 6vw, 100px);
  align-items: center;
  padding-block: clamp(60px, 9vw, 120px);
}
.contact__intro { max-width: 30ch; }
.contact__intro h1 { font-size: clamp(2.6rem, 5vw, 4.2rem); margin-bottom: 1.4rem; }
.contact__intro p { color: var(--ink-soft); font-size: 1.15rem; max-width: 34ch; }

.field { margin-bottom: 1.7rem; }
.field label {
  display: block;
  font-size: 1.06rem;
  margin-bottom: .6rem;
  color: var(--ink);
}
.field label .req { color: var(--ink-muted); font-size: .92rem; margin-left: .4rem; }
.field input,
.field textarea {
  width: 100%;
  font-family: var(--sans);
  font-size: 1.05rem;
  color: var(--ink);
  background: transparent;
  border: 1px solid var(--line);
  border-radius: 26px;
  padding: 1.05rem 1.5rem;
  transition: border-color .2s ease, background .2s ease;
}
.field textarea { border-radius: 24px; min-height: 150px; resize: vertical; }
.field input:focus,
.field textarea:focus {
  outline: none;
  border-color: var(--ink);
  background: rgba(236,228,218,0.18);
}
.field input::placeholder, .field textarea::placeholder { color: rgba(54,48,42,0.35); }

.form-status { margin-top: 1.2rem; font-size: 1.02rem; min-height: 1.4em; }
.form-status.ok { color: #2f5d3a; }
.form-status.err { color: #8a3324; }

/* ---------- Footer ---------- */
.site-footer {
  background: var(--cream);
  color: var(--ink);
  padding-block: clamp(56px, 8vw, 96px);
}
.site-footer .wrap {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 40px;
  flex-wrap: wrap;
}
.site-footer .brand-lg {
  font-family: var(--serif);
  font-weight: 500;
  font-size: clamp(2.6rem, 6vw, 4.6rem);
  line-height: 1;
  color: var(--ink);
}
.foot-col h4 {
  font-family: var(--serif);
  font-weight: 500;
  font-size: 1.5rem;
  margin: 0 0 1rem;
}
.foot-col a, .foot-col p { color: var(--ink-soft); margin: 0 0 .4rem; font-size: 1.05rem; }
.foot-col a:hover { color: var(--ink); }

/* ---------- Reveal on scroll ---------- */
.reveal { opacity: 0; transform: translateY(26px); transition: opacity .8s ease, transform .8s ease; }
.reveal.in { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) {
  .reveal { opacity: 1; transform: none; transition: none; }
  html { scroll-behavior: auto; }
}

/* ---------- Responsive ---------- */
@media (max-width: 920px) {
  .reasons { grid-template-columns: repeat(2, 1fr); }
  .steps   { grid-template-columns: 1fr; max-width: 520px; }
  .split   { grid-template-columns: 1fr; gap: 34px; }
  .split--rev .split__media { order: 0; }
  .split__media { aspect-ratio: 16/11; }
  .contact { grid-template-columns: 1fr; min-height: 0; gap: 32px; }
}

/* ===== Tablet / mobile: hamburger nav ===== */
@media (max-width: 760px) {
  .menu-toggle { display: block; }

  .nav {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    background: var(--cream);
    border-bottom: 1px solid rgba(54,48,42,0.12);
    box-shadow: 0 16px 40px rgba(40,33,26,0.18);
    padding: 8px 0 14px;
    font-size: 1.5rem;
    /* collapsed state */
    opacity: 0;
    visibility: hidden;
    transform: translateY(-10px);
    transition: opacity .25s ease, transform .25s ease, visibility .25s;
  }
  .site-header[data-open] .nav {
    opacity: 1;
    visibility: visible;
    transform: none;
  }
  .nav a {
    padding: 14px var(--gutter);
    border-bottom: 1px solid rgba(54,48,42,0.08);
  }
  .nav a:last-child { border-bottom: none; }
  .nav a::after { display: none; }
  .nav a[aria-current="page"] { color: var(--ink); font-style: italic; }
  .site-header { position: sticky; }
}

@media (max-width: 680px) {
  body { font-size: 16px; }
  .site-header .wrap { height: 64px; }
  .brand { font-size: 1.4rem; }
  .reasons { grid-template-columns: 1fr; gap: 30px; }
  .steps { max-width: 100%; }

  /* hero a bit shorter, type tuned for narrow screens */
  .hero-full { min-height: clamp(460px, 78vh, 640px); }
  .hero-full__inner h1 { font-size: clamp(2.2rem, 8.5vw, 2.9rem); max-width: 15ch; }
  .hero-full__sub { font-size: 1.06rem; max-width: 34ch; margin-top: 1.1rem; }

  h1 { font-size: clamp(2.3rem, 9vw, 3rem); }
  h2 { font-size: clamp(1.9rem, 7vw, 2.5rem); }

  section { padding-block: clamp(52px, 14vw, 80px); }

  /* checklist & faq breathing room */
  .checklist li { font-size: 1.05rem; padding-left: 1.9rem; }
  .faq summary { font-size: 1.22rem; gap: 1rem; }
  .faq .faq__body { padding-right: 1.4rem; }

  /* steps slightly less tall on phones */
  .step__media { aspect-ratio: 4/3; }

  /* contact form */
  .contact { padding-block: 48px 64px; }
  .contact__intro h1 { font-size: clamp(2.3rem, 10vw, 3.2rem); }
  .field input, .field textarea { font-size: 16px; } /* avoid iOS zoom-on-focus */
  .btn { width: 100%; }

  /* footer stacks left-aligned */
  .site-footer .wrap { flex-direction: column; align-items: flex-start; gap: 28px; }
  .site-footer .brand-lg { font-size: clamp(2.4rem, 11vw, 3.4rem); }
}

@media (max-width: 380px) {
  .brand { font-size: 1.25rem; }
  .hero-full__inner h1 { font-size: clamp(2rem, 9vw, 2.5rem); }
}
