/* ============================================================
   Peoples Community Bank of Monticello — site styles
   Clean rebuild matching the 2024 design (Divi-free).
   ============================================================ */

:root {
  /* Brand gold (#bb9431) is only 2.84:1 on white, so it is used for decoration and on dark
     backgrounds. --gold is the accessible shade (4.9:1 on white) for text and button fills. */
  --gold-brand: #bb9431;
  --gold: #8a6d21;
  --gold-dark: #6f5718;

  /* Gold FILLS (buttons, CTA band, calculator header). Two WCAG-AA options:
     Option A (current): darker gold with white text  -> --fill: var(--gold);      --on-fill: #fff;
     Option B:           brand gold with dark text     -> --fill: var(--gold-brand); --on-fill: #1f1f1f; --fill-hover: #a68229; */
  --fill: var(--gold);
  --fill-hover: var(--gold-dark);
  --on-fill: #fff;
  --navy: #222d35;
  --ink: #6b6b6b;
  --ink-strong: rgba(0, 0, 0, 0.6);
  --footer-bg: #2f2b2a;
  --light: #f7f7f5;
  --white: #fff;
  --font-body: "Open Sans", Helvetica, Arial, sans-serif;
  --font-head: "Encode Sans Semi Expanded", "Open Sans", sans-serif;
  --container: 1200px;
}

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

html { scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { transition-duration: 0.01ms !important; animation-duration: 0.01ms !important; }
}

body {
  margin: 0;
  font-family: var(--font-body);
  font-size: 14px;
  font-weight: 500;
  line-height: 1.8;
  color: var(--ink);
  background: var(--white);
}

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

h1, h2, h3, h4 {
  font-family: var(--font-head);
  font-weight: 700;
  color: var(--navy);
  line-height: 1.2;
  margin: 0 0 0.6em;
}

h2 { font-size: 35px; }
h3 { font-size: 22px; }

p { margin: 0 0 1.2em; }

a { color: var(--gold); text-decoration: none; }
a:hover { color: var(--gold-dark); }

.container {
  max-width: var(--container);
  margin: 0 auto;
  padding: 0 24px;
}

.visually-hidden {
  position: absolute; width: 1px; height: 1px;
  margin: -1px; padding: 0; 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: var(--white); padding: 10px 18px; z-index: 200;
}
.skip-link:focus { left: 0; color: var(--white); }

/* ---------- Buttons ---------- */
.btn {
  display: inline-block;
  font-family: var(--font-body);
  font-size: 14px;
  font-weight: 700;
  line-height: 1;
  padding: 15px 25px;
  border: 2px solid transparent;
  border-radius: 1px;
  cursor: pointer;
  transition: background-color .2s ease, color .2s ease, border-color .2s ease;
}
.btn--gold { background: var(--fill); color: var(--on-fill); }
.btn--gold:hover { background: var(--fill-hover); color: var(--on-fill); }
.btn--outline { background: transparent; border-color: var(--gold-brand); color: var(--ink-strong); padding: 10px 20px; }
.btn--outline:hover { background: var(--gold); color: var(--white); }
.btn--white-outline { background: transparent; border-color: var(--white); color: var(--white); padding: 15px 25px; }
.btn--white-outline:hover { background: var(--white); color: var(--navy); }

/* ---------- Top bar ---------- */
.topbar { background: var(--white); }
.topbar__inner { display: flex; justify-content: flex-end; padding-bottom: 12px; border-bottom: 1px solid var(--navy); }

/* ---------- FDIC official digital sign ---------- */
.fdic-band { background: #ecedee; margin-bottom: 5px; }
.fdic-band__inner { display: flex; align-items: center; gap: 10px; padding: 6px 24px; }
.fdic-band__logo { flex: 0 0 auto; fill: #003256; fill-rule: evenodd; }
.fdic-band__text {
  font-family: "Source Sans Pro", "Source Sans 3", "Open Sans", Helvetica, Arial, sans-serif;
  font-style: italic; font-weight: 400; font-size: 14px; line-height: 1.2; color: #000;
}

/* ---------- Header / nav ---------- */
.site-header {
  background: var(--white);
  position: sticky;
  top: 0;
  z-index: 100;
  box-shadow: 0 1px 0 rgba(0,0,0,.06);
}
.site-header__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}
.site-logo img { display: block; }

.primary-nav { display: flex; }
.nav-menu {
  display: flex;
  align-items: center;
  gap: 28px;
  list-style: none;
  margin: 0;
  padding: 0;
}
.nav-link {
  display: inline-block;
  background: none;
  border: 0;
  font-family: var(--font-body);
  font-size: 14px;
  font-weight: 700;
  color: var(--ink-strong);
  padding: 31px 0;
  cursor: pointer;
}
.nav-link:hover, .nav-link.is-active { color: var(--gold); }
.nav-caret { font-size: 11px; position: relative; top: -2px; }

.nav-item--has-sub { position: relative; }
.sub-menu {
  position: absolute;
  top: 100%;
  left: 0;
  min-width: 240px;
  background: var(--white);
  border-top: 3px solid var(--gold-brand);
  box-shadow: 0 8px 24px rgba(0,0,0,.12);
  list-style: none;
  margin: 0;
  padding: 8px 0;
  opacity: 0;
  visibility: hidden;
  transform: translateY(8px);
  /* visibility flips instantly when opening (so keyboard Tab lands inside), delayed when closing */
  transition: opacity .2s ease, transform .2s ease, visibility 0s linear .2s;
}
.nav-item--has-sub.is-open .sub-menu,
.nav-item--has-sub:hover:not(.is-dismissed) .sub-menu { transition-delay: 0s; }
.nav-item--has-sub:hover:not(.is-dismissed) .sub-menu,
.nav-item--has-sub.is-open .sub-menu {
  opacity: 1; visibility: visible; transform: translateY(0);
}
.sub-link {
  display: block;
  padding: 10px 20px;
  font-size: 14px;
  font-weight: 600;
  color: var(--ink-strong);
}
.sub-link:hover, .sub-link.is-active { color: var(--gold); background: var(--light); }

.nav-item--ob .btn--ob { margin-left: 8px; }

.nav-toggle { display: none; background: none; border: 0; padding: 10px; cursor: pointer; }
.nav-toggle__bar { display: block; width: 26px; height: 3px; background: var(--navy); margin: 5px 0; transition: transform .2s; }

/* ---------- Heroes ---------- */
.page-hero {
  background: var(--navy) center/cover no-repeat;
  padding: 120px 0;
  position: relative;
}
.page-hero::before { content: ""; position: absolute; inset: 0; background: rgba(20, 22, 26, 0.35); }
.page-hero .container { position: relative; }
.page-hero__title { font-size: 65px; color: var(--white); margin: 0; }

.home-hero {
  /* The banner image itself carries the gold tint (baked in) — no CSS overlay, matching the live site. */
  background: #222 center/cover no-repeat;
  position: relative;
  padding: 160px 0 180px;
}
.home-hero .container { position: relative; max-width: var(--container); }
.home-hero__eyebrow {
  color: var(--white); font-weight: 700; letter-spacing: .3em;
  text-transform: uppercase; font-size: 14px; margin-bottom: 18px; opacity: .85;
}
.home-hero__title { font-size: 65px; color: var(--white); max-width: 700px; margin-bottom: 20px; }
.home-hero__text { color: var(--white); max-width: 560px; font-size: 15px; margin-bottom: 32px; }

/* ---------- Sections ---------- */
.section { padding: 90px 0; }
.section--light { background: var(--light); }
.section--tinted { background: var(--light) center/cover no-repeat; position: relative; }
.section--tinted::before { content: ""; position: absolute; inset: 0; background: rgba(248, 248, 248, 0.88); }
.section--tinted > .container { position: relative; }

.eyebrow {
  display: flex; align-items: center; justify-content: center; gap: 16px;
  color: var(--gold); font-weight: 700; font-size: 14px;
  letter-spacing: .25em; text-transform: uppercase;
  margin-bottom: 12px;
}
.eyebrow::before, .eyebrow::after { content: ""; width: 70px; height: 1px; background: var(--gold-brand); }
.eyebrow--left { justify-content: flex-start; }
.eyebrow--left::before { display: none; }
.eyebrow--left::after { width: 45px; }
.eyebrow--light { color: var(--white); }
.eyebrow--light::after, .eyebrow--light::before { background: var(--gold-brand); }
.text-gold { color: var(--gold-brand); } /* only used on dark backgrounds */

.section-title { text-align: center; margin-bottom: 50px; }
.section-title--left { text-align: left; }

/* ---------- Two-column (image + text) ---------- */
.split { display: grid; grid-template-columns: 5fr 7fr; gap: 60px; align-items: center; }
.split__media img { display: block; width: 100%; box-shadow: 0 10px 30px rgba(0,0,0,.12); }

/* ---------- Card grids ---------- */
.card-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 24px; }
.card-grid--3 { grid-template-columns: repeat(3, 1fr); }

.card {
  background: var(--white);
  padding: 40px 28px 48px;
  box-shadow: 0 6px 24px rgba(0,0,0,.07);
  text-align: center;
  position: relative;
}
.card::after {
  content: "";
  position: absolute;
  right: 14px;
  bottom: 14px;
  width: 0; height: 0;
  border-left: 15px solid transparent;
  border-bottom: 15px solid var(--gold-brand);
}
.card__icon { width: 90px; margin: 0 auto 20px; display: block; }
.card__title { font-size: 20px; }
.card ul { padding-left: 0; list-style: none; margin: 12px 0 0; }
.card ul li { padding: 3px 0; font-weight: 600; color: #666; }
.card ul li::before { content: "– "; }

/* Linked cards (homepage services): title is the link, whole card is the click target */
.card__link { color: inherit; text-decoration: none; }
.card__link::after { content: ""; position: absolute; inset: 0; }
.card--linked { transition: transform .15s ease, box-shadow .15s ease; }
.card--linked:hover, .card--linked:focus-within { transform: translateY(-3px); box-shadow: 0 10px 28px rgba(0,0,0,.12); }
.card--linked:hover .card__link, .card--linked:focus-within .card__link { color: var(--gold, #8a6d21); text-decoration: underline; }
.card__link:focus-visible { outline: 2px solid var(--gold, #8a6d21); outline-offset: 2px; }

/* Plain blurb (icon + title + text, no card box) */
.blurb { text-align: center; padding: 0 16px; }
.blurb img { width: 60px; margin: 0 auto 16px; display: block; }
.blurb h3 { font-size: 20px; }

.photo-card { background: var(--white); overflow: hidden; }
.photo-card img { display: block; width: 100%; aspect-ratio: 480 / 411; object-fit: cover; box-shadow: 0 4px 16px rgba(0,0,0,.15); }
.photo-card__body { padding: 24px 8px; }
.photo-card__title { font-size: 22px; }

/* Elevated white panel wrapping a grid (Our Services on home) */
.panel { background: var(--white); box-shadow: 0 10px 40px rgba(0,0,0,.08); padding: 40px 30px; }

/* Pricing-style cards (checking accounts) */
.plan-card { text-align: center; background: var(--white); padding: 44px 30px; box-shadow: 0 6px 24px rgba(0,0,0,.07); }
.plan-card__price { font-family: var(--font-head); font-size: 28px; color: var(--gold); font-weight: 700; margin: 6px 0 14px; }

.center-cta { text-align: center; margin-top: 50px; }

/* ---------- CTA band ---------- */
.cta-band { background: var(--fill); padding: 70px 0; }
.cta-band__inner { display: flex; align-items: center; justify-content: space-between; gap: 40px; }
.cta-band__title { color: var(--on-fill); font-size: 40px; margin-bottom: 12px; }
.cta-band__text p { color: var(--on-fill); max-width: 640px; margin: 0; }

/* ---------- Footer ---------- */
.site-footer { background: var(--footer-bg); color: #b5b0ad; }
.site-footer__cols {
  display: grid;
  grid-template-columns: 4fr 2fr 2fr 2fr;
  gap: 40px;
  padding: 70px 24px;
}
.footer-brand img { max-width: 420px; width: 100%; }
.footer-col__title {
  color: var(--white); font-family: var(--font-body); font-size: 14px;
  letter-spacing: .15em; text-transform: uppercase;
  border-bottom: 1px solid rgba(255,255,255,.25);
  padding-bottom: 12px; margin-bottom: 16px;
}
.footer-col ul { list-style: none; margin: 0; padding: 0; }
.footer-col li { padding: 4px 0; }
.footer-col li::before { content: "\2022"; color: var(--gold-brand); margin-right: 10px; }
.footer-col a { color: #cfcac6; font-weight: 500; }
.footer-col a:hover { color: var(--gold-brand); }

.site-footer__bottom {
  border-top: 1px solid rgba(255,255,255,.12);
  padding: 24px 0;
  text-align: center;
  font-size: 13px;
}
.site-footer__bottom p { margin: 4px 0; }
.site-footer__bottom a { color: #cfcac6; }
.site-footer__bottom a:hover { color: var(--gold-brand); }

/* ---------- Contact page ---------- */
.contact-cards { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; }
.contact-card { text-align: center; background: var(--white); padding: 44px 30px; box-shadow: 0 6px 24px rgba(0,0,0,.07); }
.contact-card a { font-size: 18px; }

.map-embed iframe { width: 100%; height: 420px; border: 0; display: block; }

/* ---------- Responsive ---------- */
@media (max-width: 1080px) {
  .home-hero__title, .page-hero__title { font-size: 48px; }
  .card-grid { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 900px) {
  .nav-toggle { display: block; }
  .primary-nav {
    position: absolute; top: 100%; left: 0; right: 0;
    background: var(--white);
    display: none;
    box-shadow: 0 12px 24px rgba(0,0,0,.12);
  }
  .primary-nav.is-open { display: block; }
  .nav-menu { flex-direction: column; align-items: stretch; gap: 0; padding: 12px 0; }
  .nav-link { padding: 14px 24px; width: 100%; text-align: left; }
  .sub-menu {
    position: static; opacity: 1; visibility: visible; transform: none;
    box-shadow: none; border-top: 0; display: none; padding-left: 16px;
  }
  .nav-item--has-sub.is-open .sub-menu { display: block; }
  .nav-item--ob { padding: 14px 24px; }
  .split { grid-template-columns: 1fr; gap: 32px; }
  .cta-band__inner { flex-direction: column; align-items: flex-start; }
  .site-footer__cols { grid-template-columns: 1fr 1fr; }
  .footer-brand { grid-column: 1 / -1; }
}

@media (max-width: 640px) {
  .home-hero__title, .page-hero__title { font-size: 36px; }
  h2, .cta-band__title { font-size: 28px; }
  .section { padding: 60px 0; }
  .card-grid, .card-grid--3, .contact-cards { grid-template-columns: 1fr; }
  .site-footer__cols { grid-template-columns: 1fr; }
}

/* ---------- Split variant (image right) ---------- */
.split--reverse { grid-template-columns: 7fr 5fr; }
.split--reverse .split__media { order: 2; }
@media (max-width: 900px) { .split--reverse { grid-template-columns: 1fr; } .split--reverse .split__media { order: 0; } }

/* ---------- App store badges ---------- */
.badges { display: flex; gap: 14px; align-items: center; flex-wrap: wrap; margin-top: 10px; }
.badges img { height: 48px; width: auto; }

/* ---------- FAQ accordion ---------- */
.faq { max-width: 900px; margin: 0 auto; }
.faq details {
  background: var(--white);
  box-shadow: 0 4px 16px rgba(0,0,0,.06);
  margin-bottom: 12px;
  border-left: 3px solid var(--gold-brand);
}
.faq summary {
  cursor: pointer;
  list-style: none;
  padding: 18px 48px 18px 22px;
  font-family: var(--font-head);
  font-weight: 700;
  color: var(--navy);
  font-size: 16px;
  position: relative;
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; position: absolute; right: 20px; top: 50%; transform: translateY(-50%); color: var(--gold); font-size: 22px; font-weight: 700; }
.faq details[open] summary::after { content: "\2212"; }
.faq .faq__body { padding: 0 22px 18px; }

/* ---------- Numbered steps ---------- */
.step-num { display: inline-block; font-family: var(--font-head); font-weight: 700; color: var(--gold); font-size: 30px; margin-right: 8px; }

/* ---------- Fine print ---------- */
.fine-print { font-size: 13px; }
.fine-print h2 { font-size: 26px; }
.legal-logos { display: flex; gap: 20px; align-items: center; margin-top: 20px; }
.legal-logos img { height: 44px; width: auto; }

/* ---------- Privacy disclosure table ---------- */
.disclosure-table { width: 100%; border-collapse: collapse; margin: 24px 0; font-size: 14px; }
.disclosure-table th { background: var(--navy); color: var(--white); text-align: left; padding: 12px 14px; font-family: var(--font-head); }
.disclosure-table td { border: 1px solid #e2ded8; padding: 12px 14px; vertical-align: top; }
.disclosure-table tr:nth-child(even) td { background: var(--light); }

.prose h2 { font-size: 26px; margin-top: 1.6em; }
.prose h3 { font-size: 18px; margin-top: 1.4em; }
.prose ul { margin: 0 0 1.2em; padding-left: 22px; }
.prose { max-width: 860px; margin: 0 auto; }

/* ---------- Loan calculator ---------- */
.calc { max-width: 900px; margin: 0 auto; box-shadow: 0 10px 40px rgba(0,0,0,.12); background: var(--white); }
.calc__header { background: var(--fill); color: var(--on-fill); text-align: center; padding: 22px; }
.calc__header h2 { color: var(--on-fill); margin: 0; font-size: 28px; }
.calc__body { padding: 30px; background: #f7f7f7; }
.calc__grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; }
.calc-field label { display: block; font-weight: 700; color: var(--ink-strong); margin-bottom: 8px; }
.calc-field .calc-input { display: flex; }
.calc-field .calc-input .prefix { background: #eee; border: 1px solid #ccc; border-right: 0; padding: 10px 12px; }
.calc-field input[type="number"], .calc-field select {
  width: 100%; padding: 10px 12px; border: 1px solid #ccc; font-family: var(--font-body); font-size: 15px; background: var(--white);
}
.calc-field input[type="range"] { width: 100%; margin-top: 12px; accent-color: var(--gold); }
.calc__results { display: grid; grid-template-columns: 1fr 1fr; gap: 24px; margin-top: 30px; align-items: center; }
.calc-stat { background: var(--white); padding: 22px; box-shadow: 0 4px 16px rgba(0,0,0,.06); text-align: center; }
.calc-stat__label { font-weight: 700; color: var(--ink-strong); }
.calc-stat__value { font-family: var(--font-head); font-size: 26px; color: var(--gold); font-weight: 700; }
.calc__chart-wrap { max-width: 320px; margin: 0 auto; }
.video-embed { position: relative; padding-bottom: 56.25%; height: 0; max-width: 900px; margin: 0 auto; }
.video-embed iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }
@media (max-width: 900px) { .calc__grid, .calc__results { grid-template-columns: 1fr; } }

/* ---------- Full-bleed 50/50 feature rows (Loans, Zelle FAQ) ---------- */
.feature { display: grid; grid-template-columns: 1fr 1fr; }
.feature__media { background: center/cover no-repeat; min-height: 480px; }
.feature__panel { padding: 100px 8vw 100px 6vw; }
.feature__panel--dark { background: #1b1b1b; }
.feature__panel--dark h2 { color: var(--white); }
.feature__panel--dark p { color: #9d9d9d; }
.feature--media-right .feature__media { order: 2; }
@media (max-width: 900px) {
  .feature { grid-template-columns: 1fr; }
  .feature__media { min-height: 320px; order: 0 !important; }
  .feature__panel { padding: 60px 24px; }
}

/* ---------- Dark FAQ accordion (Zelle) ---------- */
.faq--dark details { background: transparent; box-shadow: none; border-left: 0; border-bottom: 1px solid rgba(255,255,255,.15); margin-bottom: 0; }
.faq--dark summary { color: var(--white); font-size: 19px; padding-left: 0; }
.faq--dark summary::after { color: var(--gold-brand); }
.faq--dark .faq__body { padding-left: 0; }
.faq--dark .faq__body p, .faq--dark .faq__body li { color: #9d9d9d; }
.faq--dark a { color: var(--gold-brand); }

/* ---------- Native video ---------- */
.video-native { max-width: 1060px; margin: 0 auto; }
.video-native video { width: 100%; display: block; }

/* ============================================================
   Accessibility (WCAG 2.1/2.2 AA)
   ============================================================ */

/* Visible keyboard focus everywhere (never rely on the browser default being present) */
:focus-visible { outline: 3px solid var(--navy); outline-offset: 3px; }
.feature__panel--dark :focus-visible,
.site-footer :focus-visible,
.cta-band :focus-visible,
.home-hero :focus-visible,
.page-hero :focus-visible { outline-color: var(--white); }
.skip-link:focus { outline: 3px solid var(--gold-brand); }

/* Links inside running text must not rely on color alone */
main p a:not(.btn),
main li a:not(.btn),
main td a:not(.btn),
.fine-print a:not(.btn) { text-decoration: underline; text-underline-offset: 2px; }

/* Dark panels: brand gold is readable here (6:1) */
.feature__panel--dark .eyebrow { color: var(--gold-brand); }

/* Headings that are structurally h2 but styled like the old h3 cards */
.contact-card__title { font-size: 22px; }

/* Header is sticky only on larger screens so it never covers content when zoomed or on phones */
.site-header { position: relative; }
@media (min-width: 901px) {
  .site-header { position: sticky; top: 0; }
}

/* Text alternative / transcript blocks */
.transcript { margin-top: 18px; }
.transcript summary { cursor: pointer; font-weight: 700; color: var(--navy); }
.transcript ol { margin: 12px 0 0; padding-left: 22px; }

/* Screen-reader-only helper used by the new-tab / PDF link notices */
.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;
}

/* Reflow at 320px / 400% zoom (WCAG 1.4.10) */
.calc__results > * { min-width: 0; }
.calc-stat__value { overflow-wrap: anywhere; }
.disclosure-table th, .disclosure-table td { overflow-wrap: anywhere; hyphens: auto; }
@media (max-width: 640px) {
  .calc__body { padding: 20px 14px; }
  .calc-stat__value { font-size: 21px; }
  .disclosure-table { font-size: 13px; }
  .disclosure-table th, .disclosure-table td { padding: 8px 6px; }
}
.cta-band .btn--white-outline { border-color: var(--on-fill); color: var(--on-fill); }
.cta-band .btn--white-outline:hover { background: var(--on-fill); color: var(--fill); }

/* ---------- Contact page: 4-up cards + hours ---------- */
.contact-cards--4 { grid-template-columns: repeat(4, 1fr); }
.contact-card__email { font-size: 15px !important; overflow-wrap: normal; word-break: normal; }
svg.card__icon { height: 90px; }
.hours-card { margin-top: 24px; background: var(--white); padding: 44px 30px; box-shadow: 0 6px 24px rgba(0,0,0,.07); text-align: center; }
.hours-table { width: 100%; max-width: 560px; margin: 18px auto 0; border-collapse: collapse; font-size: 16px; }
.hours-table th, .hours-table td { padding: 10px 14px; border-bottom: 1px solid #e6e6e3; text-align: left; }
.hours-table thead th { color: var(--navy); font-weight: 700; border-bottom: 2px solid var(--navy); }
.hours-table tbody th { font-weight: 600; color: var(--navy); }
.hours-table tbody tr:last-child th, .hours-table tbody tr:last-child td { border-bottom: 0; }
@media (max-width: 1080px) { .contact-cards--4 { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 640px) {
  .contact-cards--4 { grid-template-columns: 1fr; }
  .hours-table { font-size: 15px; }
  .hours-table th, .hours-table td { padding: 8px 8px; }
}
