/* ============================================
   CHE MATE — shared stylesheet
   Palette from the Argentine flag, per brandbook.
   ============================================ */

:root {
  --che-blue: #4679f2;
  --sky-blue: #7db2ff;
  --off-white: #f2f2f2;
  --sun-yellow: #facd46;
  --sun-yellow-deep: #ebb92c;
  --ink: #1b1a1a;
  --white: #ffffff;
  --border: #e0e0e0;
  --graphite: #4a4a4a;
  --graphite-light: #7a7a7a;
  --sky-wash: #eaf2ff;

  --container: 1240px;
  --radius: 10px;
  --radius-pill: 999px;
  --shadow-rest: 0 1px 2px rgba(27,26,26,0.06);
  --shadow-raised: 0 8px 24px rgba(27,26,26,0.10);
}

/* ---- Reset ---- */
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: 'Inter', system-ui, -apple-system, sans-serif;
  color: var(--ink);
  background: var(--white);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}
h1, h2, h3, h4 {
  font-family: 'Arvo', Georgia, serif;
  margin: 0 0 16px;
  line-height: 1.15;
  max-width: 20ch;
}
p { margin: 0 0 16px; max-width: 68ch; }
img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
ul { margin: 0; padding: 0; list-style: none; }
button { font-family: inherit; cursor: pointer; }

h1 { font-size: 34px; font-weight: 700; }
h2 { font-size: 28px; font-weight: 700; }
h3 { font-size: 24px; font-weight: 700; }
h4 { font-size: 20px; font-weight: 400; }
@media (min-width: 768px) {
  h1 { font-size: 56px; line-height: 62px; }
  h2 { font-size: 42px; line-height: 50px; }
  h3 { font-size: 30px; line-height: 40px; }
  h4 { font-size: 22px; line-height: 30px; }
}

.eyebrow {
  font-family: 'Inter', sans-serif;
  font-weight: 700;
  font-size: 12px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  display: block;
  margin-bottom: 12px;
}
.eyebrow--yellow { color: var(--sun-yellow); }
.eyebrow--blue { color: var(--che-blue); }

.body-large { font-size: 18px; line-height: 30px; }
@media (min-width: 768px) { .body-large { font-size: 19px; line-height: 32px; } }

/* On Che Blue backgrounds, body copy needs to be 19px+ semibold for contrast */
.on-blue .body-large { font-weight: 600; color: var(--white); }

.container {
  max-width: var(--container);
  margin: 0 auto;
  padding: 0 24px;
}
@media (min-width: 768px) { .container { padding: 0 40px; } }
@media (min-width: 1024px) { .container { padding: 0 48px; } }

section { padding: 56px 0; }
@media (min-width: 768px) { section { padding: 72px 0; } }
@media (min-width: 1024px) { section { padding: 96px 0; } }

.bg-white { background: var(--white); }
.bg-off-white { background: var(--off-white); }
.bg-ink { background: var(--ink); color: var(--white); }
.bg-blue { background: var(--che-blue); color: var(--white); }
.bg-sky-wash { background: var(--sky-wash); }

/* ---- Buttons ---- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  height: 52px;
  padding: 0 28px;
  border-radius: var(--radius);
  font-weight: 600;
  font-size: 17px;
  border: none;
  transition: background 150ms, transform 150ms, color 150ms;
  white-space: nowrap;
}
@media (min-width: 768px) { .btn { height: 52px; } }
.btn:hover { transform: translateY(-1px); }
.btn-primary { background: var(--sun-yellow); color: var(--ink); }
.btn-primary:hover { background: var(--sun-yellow-deep); }
.btn-outline-light {
  background: transparent; color: var(--white);
  border: 2px solid rgba(255,255,255,0.9);
}
.btn-outline-light:hover { background: rgba(255,255,255,0.12); }
.btn-outline-dark {
  background: transparent; color: var(--ink);
  border: 2px solid var(--che-blue);
}
.btn-outline-dark:hover { background: var(--sky-wash); }
.btn-full { width: 100%; }

.link-arrow {
  color: var(--ink);
  font-weight: 600;
  text-decoration: underline;
  text-decoration-color: var(--che-blue);
  text-decoration-thickness: 2px;
  text-underline-offset: 3px;
  transition: text-decoration-color 150ms;
}
.link-arrow:hover { text-decoration-color: var(--sun-yellow); text-decoration-thickness: 3px; }

/* ---- Nav ---- */
.nav {
  position: sticky; top: 0; z-index: 100;
  background: var(--white);
  border-bottom: 1px solid var(--border);
  height: 64px;
}
@media (min-width: 768px) { .nav { height: 76px; } }
.nav.is-scrolled { box-shadow: var(--shadow-rest); }
.nav-inner {
  max-width: var(--container);
  margin: 0 auto;
  height: 100%;
  padding: 0 20px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}
.nav-brand { display: flex; align-items: center; gap: 10px; }
.nav-brand img { height: 32px; }
@media (min-width: 768px) { .nav-brand img { height: 40px; } }
.nav-locale { font-size: 12px; color: var(--graphite-light); display: none; }
@media (min-width: 900px) { .nav-locale { display: block; } }
.nav-links {
  display: none;
  align-items: center;
  gap: 28px;
  font-size: 16px;
  font-weight: 500;
}
@media (min-width: 1024px) { .nav-links { display: flex; } }
.nav-links a { position: relative; padding: 4px 0; }
.nav-links a.active::after {
  content: ''; position: absolute; left: 0; right: 0; bottom: -6px;
  height: 3px; background: var(--sun-yellow);
}
.nav-dropdown { position: relative; }
/* Invisible bridge across the gap between the trigger and the panel, so moving
   the cursor down (or diagonally) into the menu never crosses a dead zone that
   closes it. Sized to cover the panel's width and the full 8px gap. */
.nav-dropdown::after {
  content: ''; position: absolute; top: 100%; left: 0;
  width: 240px; height: 16px; pointer-events: auto;
}
.nav-dropdown-panel {
  display: none;
  position: absolute; top: 100%; left: 0; margin-top: 8px;
  background: var(--white); border: 1px solid var(--border); border-radius: var(--radius);
  box-shadow: var(--shadow-raised);
  min-width: 220px; padding: 8px 0; z-index: 50;
}
.nav-dropdown:hover .nav-dropdown-panel,
.nav-dropdown:focus-within .nav-dropdown-panel { display: block; }
.nav-dropdown-panel a { display: block; padding: 10px 20px; font-size: 15px; }
.nav-dropdown-panel a:hover { background: var(--off-white); }
.nav-dropdown-panel hr { border: none; border-top: 1px solid var(--border); margin: 6px 0; }
.nav-dropdown-panel .all-link { color: var(--che-blue); font-weight: 600; }

.nav-right { display: flex; align-items: center; gap: 16px; }
.nav-phone { display: none; text-align: right; }
@media (min-width: 1024px) { .nav-phone { display: block; } }
.nav-phone .label { font-size: 12px; font-weight: 700; letter-spacing: 0.1em; color: var(--graphite-light); text-transform: uppercase; }
.nav-phone a { font-family: 'Arvo', serif; font-weight: 700; font-size: 19px; color: var(--che-blue); display: flex; align-items: center; gap: 6px; }

.nav-mobile-phone {
  display: flex; align-items: center; justify-content: center;
  width: 40px; height: 40px; border-radius: 50%;
  background: var(--sky-wash); color: var(--che-blue);
}
@media (min-width: 1024px) { .nav-mobile-phone { display: none; } }

.hamburger {
  display: flex; flex-direction: column; gap: 5px;
  width: 24px; background: none; border: none; padding: 0;
}
@media (min-width: 1024px) { .hamburger { display: none; } }
.hamburger span { height: 2px; width: 100%; background: var(--ink); border-radius: 2px; }

.mobile-menu {
  display: none;
  position: fixed; inset: 0; z-index: 200;
  background: var(--white);
  padding: 20px;
  overflow-y: auto;
}
.mobile-menu.is-open { display: block; }
.mobile-menu-header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 24px; }
.mobile-menu a.mm-link {
  display: block; font-family: 'Arvo', serif; font-size: 20px; padding: 14px 0;
  border-bottom: 1px solid var(--border);
}
.mobile-menu .mm-group summary { font-family: 'Arvo', serif; font-size: 20px; padding: 14px 0; border-bottom: 1px solid var(--border); cursor: pointer; list-style: none; }
.mobile-menu .mm-group summary::-webkit-details-marker { display: none; }
.mobile-menu .mm-group[open] summary { border-bottom: none; }
.mobile-menu .mm-group .mm-sub { padding-left: 12px; border-bottom: 1px solid var(--border); }
.mobile-menu .mm-group .mm-sub a { padding: 10px 0; font-size: 16px; font-family: 'Inter', sans-serif; }
.mobile-menu-cta { position: sticky; bottom: 0; background: var(--white); padding-top: 16px; }

/* ---- Sticky mobile call bar ---- */
.call-bar {
  display: none;
  position: fixed; bottom: 0; left: 0; right: 0; z-index: 90;
  height: 68px;
  background: var(--ink);
  box-shadow: 0 -2px 12px rgba(27,26,26,0.18);
}
@media (max-width: 767px) { .call-bar { display: flex; } }
.call-bar a {
  flex: 1; display: flex; align-items: center; justify-content: center; gap: 8px;
  font-weight: 600; font-size: 16px;
}
.call-bar .call-now { background: var(--sun-yellow); color: var(--ink); }
.call-bar .text-us { color: var(--white); border-left: 1px solid rgba(255,255,255,0.15); }
body.has-call-bar { padding-bottom: 68px; }
@media (min-width: 768px) { body.has-call-bar { padding-bottom: 0; } }

/* ---- Hero ---- */
.hero {
  position: relative;
  min-height: 420px;
  display: flex; align-items: center;
  overflow: hidden;
  color: var(--white);
}
.hero--tall { min-height: 560px; }
@media (min-width: 768px) { .hero--tall { min-height: 640px; } }
.hero-bg { position: absolute; inset: 0; z-index: 0; }
.hero-bg img { width: 100%; height: 100%; object-fit: cover; }
.hero-bg::after {
  content: ''; position: absolute; inset: 0;
  background: linear-gradient(180deg, rgba(27,26,26,0.62) 0%, rgba(27,26,26,0.82) 100%);
}
.hero-content { position: relative; z-index: 1; max-width: 700px; padding: 48px 0; }
.hero-buttons { display: flex; flex-wrap: wrap; gap: 12px; margin: 24px 0 16px; }
.hero-note { display: flex; align-items: flex-start; gap: 8px; font-weight: 600; }
.check { color: var(--sun-yellow); flex-shrink: 0; margin-top: 3px; }

/* ---- Split hero (home) ---- */
.hero-split {
  background: var(--che-blue); color: var(--white);
  padding: 48px 0;
}
@media (min-width: 1024px) { .hero-split { padding: 80px 0; } }
.hero-split .container {
  display: grid; grid-template-columns: 1fr; gap: 32px; align-items: center;
}
@media (min-width: 900px) { .hero-split .container { grid-template-columns: 1.1fr 1fr; gap: 48px; } }
.hero-split-img { border-radius: var(--radius); overflow: hidden; }
.hero-split-img img { width: 100%; height: 100%; object-fit: cover; aspect-ratio: 4/5; }
@media (max-width: 899px) { .hero-split-img img { aspect-ratio: 16/10; } }

/* ---- Trust bar ---- */
.trust-bar {
  background: var(--ink); color: var(--white);
  padding: 24px 0;
}
.trust-bar .container {
  display: grid; grid-template-columns: 1fr 1fr; gap: 16px 24px;
  font-size: 15px; font-weight: 500;
}
@media (min-width: 900px) { .trust-bar .container { grid-template-columns: repeat(4, 1fr); } }
.trust-bar .item { display: flex; align-items: flex-start; gap: 8px; }
.trust-bar .item svg { flex-shrink: 0; margin-top: 2px; color: var(--che-blue); }

/* ---- CTA band ---- */
.cta-band { background: var(--che-blue); color: var(--white); text-align: center; }
.cta-band .container { max-width: 780px; }
.cta-band .buttons { display: flex; flex-wrap: wrap; justify-content: center; gap: 12px; margin: 24px 0; }
.cta-band .foot-note { font-weight: 600; display: flex; align-items: center; justify-content: center; gap: 8px; }
.cta-band .foot-note .check { color: var(--sun-yellow); }

/* ---- Footer ---- */
footer { background: var(--ink); color: var(--white); padding: 64px 0 32px; }
.footer-grid { display: grid; grid-template-columns: 1fr; gap: 40px; }
@media (min-width: 768px) { .footer-grid { grid-template-columns: 1.4fr 1fr 1fr 1fr; gap: 32px; } }
.footer-grid h5 { font-size: 12px; font-weight: 700; letter-spacing: 0.1em; text-transform: uppercase; color: var(--sun-yellow); margin: 0 0 16px; }
.footer-grid ul li { margin-bottom: 10px; }
.footer-grid ul a { color: rgba(255,255,255,0.85); font-size: 15px; }
.footer-grid ul a:hover { color: var(--white); text-decoration: underline; }
.footer-brand img { height: 36px; margin-bottom: 16px; }
.footer-brand p { color: rgba(255,255,255,0.7); font-size: 15px; }
.footer-phone { font-family: 'Arvo', serif; font-weight: 700; font-size: 20px; color: var(--sun-yellow); display: block; margin-bottom: 6px; }
.footer-email { color: var(--white); display: block; margin-bottom: 12px; }
.footer-mobile-note { font-size: 14px; color: rgba(255,255,255,0.55); }
.footer-bottom {
  margin-top: 48px; padding-top: 24px; border-top: 1px solid rgba(255,255,255,0.1);
  display: flex; flex-direction: column; gap: 8px;
  font-size: 14px; color: rgba(255,255,255,0.5);
}
@media (min-width: 600px) { .footer-bottom { flex-direction: row; justify-content: space-between; } }

/* ---- Cards ---- */
.grid { display: grid; gap: 24px; }
.grid-2 { grid-template-columns: 1fr; }
.grid-3 { grid-template-columns: 1fr; }
.grid-4 { grid-template-columns: 1fr; }
@media (min-width: 640px) { .grid-2 { grid-template-columns: 1fr 1fr; } .grid-4 { grid-template-columns: 1fr 1fr; } }
@media (min-width: 900px) { .grid-3 { grid-template-columns: repeat(3, 1fr); } .grid-4 { grid-template-columns: repeat(4, 1fr); } }

.card {
  background: var(--white); border: 1px solid var(--border); border-radius: var(--radius);
  padding: 32px; transition: box-shadow 200ms, border-color 200ms;
}
.card:hover { box-shadow: var(--shadow-raised); border-color: var(--che-blue); }
.card-icon { color: var(--che-blue); margin-bottom: 16px; }
.card h4 { margin-bottom: 8px; }
.card .desc { color: var(--graphite); font-size: 17px; margin-bottom: 16px; }
.card ul.bullets li { display: flex; gap: 8px; font-size: 15px; margin-bottom: 8px; color: var(--ink); }
.card ul.bullets svg { color: var(--che-blue); flex-shrink: 0; margin-top: 3px; }
.card .learn { margin-top: 16px; display: inline-flex; align-items: center; gap: 4px; }
.card .learn svg { transition: transform 150ms; }
.card:hover .learn svg { transform: translateX(4px); }

.testimonial-card {
  background: var(--off-white); border-radius: var(--radius); padding: 32px;
}
.testimonial-card .stars { color: var(--sun-yellow); margin-bottom: 12px; }
.testimonial-card blockquote { margin: 0 0 16px; font-size: 18px; font-style: normal; }
.testimonial-card .attribution { border-top: 1px solid var(--border); padding-top: 12px; }
.testimonial-card .name { font-weight: 600; font-size: 16px; }
.testimonial-card .meta { font-size: 14px; color: var(--graphite-light); }

.chip {
  display: inline-flex; align-items: center; padding: 12px 22px;
  border-radius: var(--radius-pill); background: var(--white); border: 1px solid var(--border);
  font-weight: 500; font-size: 16px; transition: background 150ms, border-color 150ms, color 150ms;
}
.chip:hover { background: var(--sky-wash); border-color: var(--che-blue); }
.chip--dark { background: transparent; border-color: rgba(255,255,255,0.25); color: var(--white); }
.chip--dark:hover { background: var(--white); color: var(--ink); }
.chip-row { display: flex; flex-wrap: wrap; gap: 12px; }
.chip-row--center { justify-content: center; }

.step-marker {
  width: 56px; height: 56px; border-radius: 50%; background: var(--sun-yellow);
  color: var(--ink); font-family: 'Arvo', serif; font-weight: 700; font-size: 24px;
  display: flex; align-items: center; justify-content: center; margin-bottom: 16px;
}

.stat { text-align: center; }
.stat .num { font-family: 'Arvo', serif; font-weight: 700; font-size: 40px; color: var(--che-blue); }
@media (min-width: 768px) { .stat .num { font-size: 56px; } }
.stat .label { font-size: 16px; color: var(--graphite); margin-top: 8px; }

/* ---- FAQ ---- */
.faq-row { border-bottom: 1px solid var(--border); padding: 24px 0; }
.faq-row summary {
  display: flex; align-items: center; justify-content: space-between; gap: 16px;
  font-family: 'Arvo', serif; font-weight: 700; font-size: 19px; cursor: pointer; list-style: none;
}
.faq-row summary::-webkit-details-marker { display: none; }
.faq-row summary .icon { color: var(--che-blue); flex-shrink: 0; font-size: 22px; line-height: 1; }
.faq-row[open] summary .icon::before { content: '−'; }
.faq-row:not([open]) summary .icon::before { content: '+'; }
.faq-row .answer { padding-top: 14px; color: var(--graphite); font-size: 17px; }

.faq-panel { display: grid; grid-template-columns: 1fr; gap: 32px; }
@media (min-width: 900px) { .faq-panel { grid-template-columns: 1fr 2fr; } }
.faq-side { align-self: start; }
@media (min-width: 900px) { .faq-side { position: sticky; top: 100px; } }

.faq-category h3 { margin-top: 40px; margin-bottom: 8px; font-size: 22px; }
.faq-category:first-child h3 { margin-top: 0; }

/* ---- Form ---- */
.form-card { background: var(--white); border: 1px solid var(--border); border-radius: var(--radius); padding: 32px 24px; }
@media (min-width: 640px) { .form-card { padding: 40px; } }
.form-field { margin-bottom: 20px; }
.form-field label { display: block; font-weight: 500; font-size: 15px; margin-bottom: 6px; }
.form-field input, .form-field select, .form-field textarea {
  width: 100%; height: 52px; border: 1px solid var(--border); border-radius: var(--radius);
  padding: 0 16px; font-family: inherit; font-size: 16px; background: var(--white);
}
.form-field textarea { height: auto; padding: 14px 16px; resize: vertical; }
.form-field input:focus, .form-field select:focus, .form-field textarea:focus {
  outline: none; border-color: var(--che-blue); box-shadow: 0 0 0 2px var(--che-blue);
}
.form-field .helper { font-size: 13px; color: var(--graphite-light); margin-top: 4px; }
.form-success { display: none; text-align: center; padding: 40px 20px; }
.form-success.is-visible { display: block; }
.form-success .check-icon { width: 56px; height: 56px; border-radius: 50%; background: var(--sky-wash); color: var(--che-blue); display: flex; align-items: center; justify-content: center; margin: 0 auto 16px; }

/* ---- Utility ---- */
.text-center { text-align: center; }
.mx-auto { margin-left: auto; margin-right: auto; }
.max-640 { max-width: 640px; }
.max-720 { max-width: 720px; }
.max-780 { max-width: 780px; }
.section-head { margin-bottom: 40px; }
.section-head.text-center p { margin-left: auto; margin-right: auto; }
.two-col { display: grid; grid-template-columns: 1fr; gap: 32px; align-items: center; }
@media (min-width: 900px) { .two-col { grid-template-columns: 5fr 7fr; gap: 48px; } }
.two-col.reverse { direction: rtl; }
.two-col.reverse > * { direction: ltr; }
.two-col img { border-radius: var(--radius); width: 100%; aspect-ratio: 4/3; object-fit: cover; }
.divider { height: 1px; background: var(--border); margin: 24px 0; }

.image-slot {
  background: var(--sky-wash); border-radius: var(--radius); aspect-ratio: 4/3;
  display: flex; align-items: center; justify-content: center;
}
.hero-bg.image-slot::after { display: none; }
.hero-bg.image-slot { background: linear-gradient(135deg, var(--che-blue), var(--sky-blue)); }

.callout-panel { background: var(--sky-wash); border-radius: var(--radius); padding: 32px 24px; }
@media (min-width: 640px) { .callout-panel { padding: 40px; } }

/* ---- Scroll reveal ---- */
.reveal { opacity: 0; transform: translateY(20px); transition: opacity 500ms cubic-bezier(0.16,1,0.3,1), transform 500ms cubic-bezier(0.16,1,0.3,1); }
.reveal.is-visible { opacity: 1; transform: translateY(0); }
@media (prefers-reduced-motion: reduce) {
  .reveal { opacity: 1; transform: none; transition: none; }
  html { scroll-behavior: auto; }
}

/* ---- Accessibility ---- */
a:focus-visible, button:focus-visible, input:focus-visible, select:focus-visible, textarea:focus-visible, summary:focus-visible {
  outline: 3px solid var(--ink);
  outline-offset: 2px;
  box-shadow: 0 0 0 4px var(--sun-yellow);
}
.skip-link {
  position: absolute; left: -9999px; top: 0; z-index: 999;
  background: var(--sun-yellow); color: var(--ink); padding: 12px 20px; font-weight: 600;
}
.skip-link:focus { left: 12px; top: 12px; }
.sr-only {
  position: absolute; width: 1px; height: 1px; overflow: hidden;
  clip: rect(0,0,0,0); white-space: nowrap; margin: -1px;
}

/* ---- Response panel (area pages) ---- */
.response-panel { background: var(--sky-wash); border-radius: var(--radius); padding: 24px 32px; display: inline-block; }
.response-panel strong { color: var(--che-blue); }
