/* 222 Commission — The Hernandez Family
   Palette: Guatemala flag blue, warm bamboo gold, and textile plum on a warm paper background. */

:root {
  --paper: #fbf8f3;
  --paper-2: #f3ece1;
  --ink: #1d2433;
  --ink-soft: #4a5263;
  --line: #e4dccf;
  --blue: #2f7fc1;
  --blue-deep: #1f5a8c;
  --sky: #4997d0;
  --gold: #c08a2d;
  --gold-soft: #f2e2c2;
  --plum: #7a2e6a;
  --white: #ffffff;
  --radius: 14px;
  --shadow: 0 1px 2px rgb(29 36 51 / 0.06), 0 8px 24px rgb(29 36 51 / 0.08);
  --serif: "Fraunces", Georgia, "Times New Roman", serif;
  --sans: "Source Sans 3", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --max: 1120px;
}

*,
*::before,
*::after { box-sizing: border-box; }

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

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 1.125rem;
  line-height: 1.65;
}

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

a { color: var(--blue-deep); text-underline-offset: 3px; }
a:hover { color: var(--plum); }

h1, h2, h3, h4 {
  font-family: var(--serif);
  font-weight: 600;
  line-height: 1.15;
  letter-spacing: -0.01em;
  margin: 0 0 0.5em;
  color: var(--ink);
}
h1 { font-size: clamp(2.4rem, 5vw + 1rem, 4rem); }
h2 { font-size: clamp(1.8rem, 2.5vw + 1rem, 2.6rem); }
h3 { font-size: 1.35rem; }

p { margin: 0 0 1.1em; }

.container { width: min(var(--max), 100% - 2rem); margin-inline: auto; }
.narrow { width: min(760px, 100% - 2rem); margin-inline: auto; }

/* Heading for screen readers and search engines only. */
.visually-hidden {
  position: absolute !important; 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: -999px; top: 0;
  background: var(--ink); color: var(--white); padding: 0.5rem 1rem; z-index: 100;
}
.skip-link:focus { left: 1rem; top: 1rem; }

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

/* ---------- Header ---------- */

.flag-bar {
  height: 6px;
  background: linear-gradient(90deg, var(--sky) 0 33.33%, var(--white) 33.33% 66.66%, var(--sky) 66.66% 100%);
}

.site-header {
  position: sticky; top: 0; z-index: 50;
  background: rgb(251 248 243 / 0.92);
  backdrop-filter: saturate(1.4) blur(8px);
  border-bottom: 1px solid var(--line);
}
.site-header .container {
  display: flex; align-items: center; justify-content: space-between; gap: 1rem;
  min-height: 72px;
}

.brand { display: flex; align-items: center; gap: 0.75rem; text-decoration: none; color: var(--ink); }
.brand-mark {
  width: 44px; height: 30px; border-radius: 4px; flex: none;
  background: linear-gradient(90deg, var(--sky) 0 33.33%, var(--white) 33.33% 66.66%, var(--sky) 66.66%);
  box-shadow: inset 0 0 0 1px rgb(0 0 0 / 0.08);
}
.brand-text { display: flex; flex-direction: column; line-height: 1.1; }
.brand-name { font-family: var(--serif); font-weight: 600; font-size: 1.2rem; }
.brand-sub { font-size: 0.78rem; letter-spacing: 0.08em; text-transform: uppercase; color: var(--ink-soft); }

.nav-toggle { display: none; }

.site-nav ul { display: flex; gap: 0.25rem; list-style: none; margin: 0; padding: 0; align-items: center; }
.site-nav a {
  display: block; padding: 0.5rem 0.85rem; border-radius: 999px;
  color: var(--ink); text-decoration: none; font-weight: 600; font-size: 1rem;
}
.site-nav a:hover { background: var(--paper-2); color: var(--ink); }
.site-nav a[aria-current="page"] { color: var(--blue-deep); background: rgb(73 151 208 / 0.12); }
.site-nav .nav-cta { background: var(--gold); color: var(--white); }
.site-nav .nav-cta:hover, .site-nav .nav-cta[aria-current="page"] { background: #a8761f; color: var(--white); }

@media (max-width: 820px) {
  .nav-toggle {
    display: inline-flex; align-items: center; gap: 0.4rem;
    background: none; border: 1px solid var(--line); border-radius: 999px;
    padding: 0.45rem 0.9rem; font: inherit; font-weight: 600; font-size: 0.95rem; color: var(--ink);
    cursor: pointer;
  }
  .nav-toggle svg { width: 18px; height: 18px; }
  .site-nav {
    position: absolute; left: 0; right: 0; top: 100%;
    background: var(--paper); border-bottom: 1px solid var(--line);
    display: none;
  }
  .site-nav.open { display: block; }
  .site-nav ul { flex-direction: column; align-items: stretch; padding: 0.5rem 1rem 1rem; }
  .site-nav a { padding: 0.75rem 1rem; border-radius: 10px; }
}

/* ---------- Buttons ---------- */

.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 0.5rem;
  padding: 0.8rem 1.4rem; border-radius: 999px; border: 2px solid transparent;
  font: inherit; font-weight: 700; font-size: 1rem; text-decoration: none; cursor: pointer;
  transition: background 0.15s, color 0.15s, border-color 0.15s, transform 0.15s;
}
.btn:active { transform: translateY(1px); }
.btn-primary { background: var(--blue-deep); color: var(--white); }
.btn-primary:hover { background: var(--ink); color: var(--white); }
.btn-gold { background: var(--gold); color: var(--white); }
.btn-gold:hover { background: #a8761f; color: var(--white); }
.btn-ghost { border-color: var(--ink); color: var(--ink); background: transparent; }
.btn-ghost:hover { background: var(--ink); color: var(--white); }
.btn svg { width: 18px; height: 18px; }

/* ---------- Home hero ---------- */

.hero { padding: clamp(2.5rem, 6vw, 5rem) 0 clamp(3rem, 6vw, 5rem); }
.hero .container {
  display: grid; grid-template-columns: 1.05fr 1fr; gap: clamp(2rem, 5vw, 4.5rem); align-items: center;
}
.eyebrow {
  display: inline-block; font-size: 0.85rem; font-weight: 700; letter-spacing: 0.12em;
  text-transform: uppercase; color: var(--plum); margin-bottom: 1rem;
}
.hero h1 { margin-bottom: 0.3em; }
.hero h1 em { font-style: italic; color: var(--blue-deep); }
.hero .lead { font-size: 1.25rem; color: var(--ink-soft); max-width: 34ch; }
.hero-actions { display: flex; flex-wrap: wrap; gap: 0.75rem; margin-top: 1.75rem; }

.hero-photo { position: relative; }
.hero-photo img {
  border-radius: 24px; box-shadow: var(--shadow); width: 100%; aspect-ratio: 1 / 1; object-fit: cover;
}
.hero-photo::before {
  content: ""; position: absolute; inset: -14px 14px 14px -14px; z-index: -1;
  border-radius: 28px; background: var(--gold-soft);
}
.hero-photo figcaption {
  position: absolute; left: 1rem; bottom: 1rem;
  background: rgb(255 255 255 / 0.92); border-radius: 999px; padding: 0.4rem 0.9rem;
  font-size: 0.9rem; font-weight: 600; color: var(--ink);
  display: flex; align-items: center; gap: 0.4rem;
}
.hero-photo figcaption svg { width: 16px; height: 16px; color: var(--plum); }

@media (max-width: 820px) {
  .hero .container { grid-template-columns: 1fr; }
  .hero-photo { order: -1; max-width: 520px; margin: 0.5rem auto 0; padding-left: 10px; }
  .hero-photo::before { inset: -10px 10px 10px 0; }
  .hero .lead { max-width: none; }
}

/* ---------- Sections ---------- */

.section { padding: clamp(3rem, 7vw, 5.5rem) 0; }
.section-alt { background: var(--paper-2); }
.section-head { max-width: 640px; margin-bottom: 2.25rem; }
.section-head p { color: var(--ink-soft); font-size: 1.15rem; }

.vision {
  background: var(--ink); color: #e9ecf3;
  padding: clamp(3rem, 7vw, 5.5rem) 0;
}
.vision blockquote { margin: 0; max-width: 860px; }
.vision blockquote p {
  font-family: var(--serif); font-size: clamp(1.5rem, 2.2vw + 0.8rem, 2.25rem);
  line-height: 1.3; color: var(--white);
}
.vision blockquote p::before { content: "\201C"; color: var(--gold); }
.vision blockquote p::after { content: "\201D"; color: var(--gold); }
.vision cite { font-style: normal; color: #b7c0d1; font-weight: 600; }

.cards { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1.25rem; }
.card {
  background: var(--white); border: 1px solid var(--line); border-radius: var(--radius);
  padding: 1.75rem; display: flex; flex-direction: column; gap: 0.5rem;
  text-decoration: none; color: var(--ink); transition: transform 0.15s, box-shadow 0.15s;
}
a.card:hover { transform: translateY(-3px); box-shadow: var(--shadow); color: var(--ink); }
.card .icon {
  width: 48px; height: 48px; border-radius: 12px; display: grid; place-items: center;
  background: rgb(73 151 208 / 0.12); color: var(--blue-deep); margin-bottom: 0.5rem;
}
.card:nth-child(2) .icon { background: rgb(122 46 106 / 0.1); color: var(--plum); }
.card:nth-child(3) .icon { background: var(--gold-soft); color: #8a611a; }
.card .icon svg { width: 24px; height: 24px; }
.card h3 { margin: 0; }
.card p { margin: 0; color: var(--ink-soft); font-size: 1.02rem; }
.card .more { margin-top: auto; padding-top: 0.75rem; font-weight: 700; color: var(--blue-deep); font-size: 1rem; }

@media (max-width: 820px) { .cards { grid-template-columns: 1fr; } }

/* ---------- Page header (inner pages) ---------- */

.page-hero {
  padding: clamp(3rem, 7vw, 5rem) 0 clamp(2rem, 4vw, 3rem);
  background:
    radial-gradient(1200px 300px at 10% 0%, rgb(73 151 208 / 0.12), transparent 70%),
    radial-gradient(900px 300px at 90% 0%, rgb(192 138 45 / 0.12), transparent 70%);
  border-bottom: 1px solid var(--line);
}
.page-hero p { color: var(--ink-soft); font-size: 1.2rem; max-width: 60ch; margin: 0; }

/* ---------- Prose (About / Statement of Faith) ---------- */

.prose { padding: clamp(2.5rem, 5vw, 4rem) 0; }
.prose h2 { margin-top: 2.25rem; }
.prose h2:first-child { margin-top: 0; }
.prose h3 { margin-top: 1.75rem; color: var(--blue-deep); }
.prose .dropcap::first-letter {
  float: left; font-family: var(--serif); font-size: 3.6rem; line-height: 0.9;
  padding: 0.35rem 0.6rem 0 0; color: var(--plum);
}
.pull {
  border-left: 4px solid var(--gold); padding: 0.5rem 0 0.5rem 1.25rem; margin: 2rem 0;
  font-family: var(--serif); font-size: 1.35rem; line-height: 1.4; color: var(--ink);
}
.pull cite { display: block; margin-top: 0.4rem; font-family: var(--sans); font-style: normal; font-size: 1rem; color: var(--ink-soft); }

.toc {
  display: flex; flex-wrap: wrap; gap: 0.5rem; margin: 0 0 2.5rem; padding: 0; list-style: none;
}
.toc a {
  display: block; padding: 0.35rem 0.85rem; border-radius: 999px; background: var(--white);
  border: 1px solid var(--line); text-decoration: none; font-size: 0.95rem; font-weight: 600; color: var(--ink);
}
.toc a:hover { border-color: var(--blue); color: var(--blue-deep); }

.beliefs { display: grid; gap: 1rem; }
.belief {
  background: var(--white); border: 1px solid var(--line); border-radius: var(--radius);
  padding: 1.5rem 1.75rem; scroll-margin-top: 96px;
}
.belief h2 { font-size: 1.4rem; margin: 0 0 0.4rem; color: var(--blue-deep); }
.belief p { margin: 0; }
.belief .refs { margin-top: 0.6rem; font-size: 0.95rem; color: var(--plum); font-weight: 600; }

/* ---------- Prayer letters ---------- */

.letters-layout { display: grid; grid-template-columns: 1.3fr 1fr; gap: 2.5rem; align-items: start; }
@media (max-width: 900px) { .letters-layout { grid-template-columns: 1fr; } }

.letter-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 0.85rem; }
.letter {
  display: flex; align-items: center; gap: 1rem;
  background: var(--white); border: 1px solid var(--line); border-radius: var(--radius);
  padding: 1rem 1.25rem; text-decoration: none; color: var(--ink); transition: box-shadow 0.15s, transform 0.15s;
}
.letter:hover { box-shadow: var(--shadow); transform: translateY(-2px); color: var(--ink); }
.letter .date {
  flex: none; width: 64px; height: 64px; border-radius: 12px; background: rgb(73 151 208 / 0.12);
  display: flex; flex-direction: column; align-items: center; justify-content: center; line-height: 1.05;
  color: var(--blue-deep);
}
.letter .date b { font-family: var(--serif); font-size: 1.25rem; }
.letter .date small { font-size: 0.8rem; font-weight: 700; letter-spacing: 0.06em; }
.letter .title { font-weight: 700; display: block; }
.letter .meta { color: var(--ink-soft); font-size: 0.95rem; }
.letter .dl { margin-left: auto; color: var(--blue-deep); flex: none; }
.letter .dl svg { width: 22px; height: 22px; }
.letter-latest { border-color: var(--gold); background: linear-gradient(0deg, var(--white), #fffaf0); }
.badge {
  display: inline-block; margin-left: 0.4rem; padding: 0.05rem 0.5rem; border-radius: 999px;
  background: var(--gold); color: var(--white); font-size: 0.72rem; font-weight: 700; letter-spacing: 0.06em;
  text-transform: uppercase; vertical-align: 2px;
}

/* ---------- Signup form ---------- */

.signup {
  background: var(--white); border: 1px solid var(--line); border-radius: 20px;
  padding: clamp(1.5rem, 3vw, 2.25rem); box-shadow: var(--shadow);
  position: relative; overflow: hidden; scroll-margin-top: 96px;
}
.signup::before {
  content: ""; position: absolute; inset: 0 0 auto 0; height: 6px;
  background: linear-gradient(90deg, var(--sky) 0 33.33%, var(--white) 33.33% 66.66%, var(--sky) 66.66%);
  border-bottom: 1px solid var(--line);
}
.signup h2, .signup h3 { margin-top: 0.25rem; }
.signup p { color: var(--ink-soft); }

.field-row { display: grid; grid-template-columns: 1fr 1fr; gap: 0.75rem; }
@media (max-width: 480px) { .field-row { grid-template-columns: 1fr; } }
.field { display: flex; flex-direction: column; gap: 0.3rem; margin-bottom: 0.9rem; min-width: 0; }
.field label { font-weight: 700; font-size: 0.95rem; }
.field label .req { color: var(--plum); }
.field input {
  width: 100%; min-width: 0;
  font: inherit; font-size: 1rem; padding: 0.75rem 0.9rem; border-radius: 10px;
  border: 1.5px solid var(--line); background: var(--paper); color: var(--ink);
}
.field input:focus { outline: none; border-color: var(--blue); background: var(--white); box-shadow: 0 0 0 4px rgb(73 151 208 / 0.18); }
.hp { position: absolute !important; left: -10000px !important; width: 1px; height: 1px; overflow: hidden; }
.signup .btn { width: 100%; margin-top: 0.25rem; }
.form-status { margin: 0.9rem 0 0; font-weight: 600; min-height: 1.5em; }
.form-status.ok { color: #1f7a4d; }
.form-status.err { color: #b42318; }
.signup.done form { display: none; }
.privacy { font-size: 0.9rem; color: var(--ink-soft); margin: 0.75rem 0 0; }

.signup-band { padding: clamp(3rem, 7vw, 5rem) 0; }
.signup-band .container {
  display: grid; grid-template-columns: 1fr 1fr; gap: clamp(2rem, 5vw, 4rem); align-items: center;
}
@media (max-width: 820px) { .signup-band .container { grid-template-columns: 1fr; } }

/* ---------- Donate ---------- */

.give {
  display: grid; grid-template-columns: 1.2fr 1fr; gap: 2rem; align-items: center;
  background: var(--white); border: 1px solid var(--line); border-radius: 20px; padding: clamp(1.5rem, 4vw, 3rem);
  box-shadow: var(--shadow);
}
.give .ways { display: grid; gap: 0.75rem; }
.give .way { display: flex; gap: 0.75rem; align-items: flex-start; }
.give .way svg { width: 22px; height: 22px; flex: none; color: var(--plum); margin-top: 0.2rem; }
@media (max-width: 820px) { .give { grid-template-columns: 1fr; } }

.cta-band {
  background: linear-gradient(135deg, var(--blue-deep), #173e61); color: var(--white);
  border-radius: 24px; padding: clamp(2rem, 5vw, 3.5rem);
  display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 1.5rem;
}
.cta-band h2 { color: var(--white); margin: 0 0 0.25rem; }
.cta-band p { margin: 0; color: #d7e4f1; }

/* ---------- Footer ---------- */

.site-footer { background: var(--ink); color: #b7c0d1; padding: 3rem 0 2rem; margin-top: 0; font-size: 1rem; }
.site-footer .container { display: grid; grid-template-columns: 1.4fr 1fr 1fr; gap: 2rem; }
.site-footer h4 { color: var(--white); font-family: var(--sans); font-size: 0.85rem; letter-spacing: 0.12em; text-transform: uppercase; margin-bottom: 0.9rem; }
.site-footer a { color: #e3e8f0; text-decoration: none; }
.site-footer a:hover { color: var(--gold-soft); text-decoration: underline; }
.site-footer ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 0.45rem; }
.site-footer .brand-name { color: var(--white); font-size: 1.35rem; display: block; margin-bottom: 0.4rem; }
.social { display: flex; gap: 0.6rem; margin-top: 1rem; }
.social a {
  width: 42px; height: 42px; border-radius: 50%; display: grid; place-items: center;
  background: rgb(255 255 255 / 0.08); color: var(--white);
}
.social a:hover { background: var(--gold); color: var(--white); text-decoration: none; }
.social svg { width: 20px; height: 20px; }
.footer-base {
  grid-column: 1 / -1; border-top: 1px solid rgb(255 255 255 / 0.1); padding-top: 1.25rem; margin-top: 1rem;
  display: flex; flex-wrap: wrap; justify-content: space-between; gap: 0.5rem; font-size: 0.9rem;
}
@media (max-width: 820px) { .site-footer .container { grid-template-columns: 1fr; } }

/* ---------- 404 ---------- */
.notfound { text-align: center; padding: clamp(4rem, 10vw, 8rem) 0; }
.notfound .actions { display: flex; flex-wrap: wrap; gap: 0.75rem; justify-content: center; margin-top: 1.5rem; }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { transition: none !important; scroll-behavior: auto !important; }
}
