/* Senior Citizen — accessible stylesheet.
   Design priorities: large readable type, strong contrast, big tap targets,
   clear focus rings, and a layout that reflows down to 320px. */

:root {
  --ink:        #1b2430;
  --ink-soft:   #46525f;
  --paper:      #ffffff;
  --ground:     #f4f6f8;
  --line:       #d3dae1;
  --brand:      #0b5d4a;   /* deep green — 7.4:1 on white */
  --brand-dark: #07402f;
  --brand-tint: #e7f2ee;
  --accent:     #8a3a00;   /* warm brown — 7.2:1 on white */
  --accent-tint:#fdf0e4;
  --focus:      #b34700;
  --radius:     10px;
}

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

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

body {
  margin: 0;
  background: var(--ground);
  color: var(--ink);
  font: 400 1.125rem/1.65 "Segoe UI", system-ui, -apple-system, "Helvetica Neue", Arial, sans-serif;
}

.wrap { width: min(1120px, 100% - 2.5rem); margin-inline: auto; }

h1, h2, h3 { line-height: 1.25; color: var(--ink); margin: 0 0 .6em; }
h1 { font-size: clamp(1.9rem, 4.5vw, 2.6rem); }
h2 { font-size: clamp(1.45rem, 3vw, 1.85rem); }
h3 { font-size: 1.25rem; }
p  { margin: 0 0 1rem; max-width: 68ch; }

a { color: var(--brand); text-decoration-thickness: 2px; text-underline-offset: 3px; }
a:hover { color: var(--brand-dark); }

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

.visually-hidden {
  position: absolute; width: 1px; height: 1px;
  padding: 0; margin: -1px; overflow: hidden;
  clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}

.skip {
  position: absolute; left: -9999px; top: 0; z-index: 100;
  background: var(--brand); color: #fff; padding: 1rem 1.5rem;
  font-weight: 700; text-decoration: none;
}
.skip:focus { left: 0; }

/* ---------- Header ---------- */
.site-header { background: var(--paper); border-bottom: 1px solid var(--line); }

.header-inner {
  display: flex; flex-wrap: wrap; gap: 1rem 2rem;
  align-items: center; justify-content: space-between;
  padding: 1.25rem 0;
}

.brand {
  display: flex; align-items: center; gap: .85rem;
  text-decoration: none; color: inherit;
}
.brand-mark { font-size: 2.4rem; line-height: 1; }
.brand-name { display: block; font-size: 1.65rem; font-weight: 700; color: var(--brand); }
.brand-tag  { display: block; font-size: 1rem; color: var(--ink-soft); }

.search { display: flex; gap: .5rem; flex: 1 1 22rem; max-width: 30rem; }
.search input {
  flex: 1; min-width: 0; font: inherit; font-size: 1.05rem;
  padding: .75rem .9rem; border: 2px solid var(--line);
  border-radius: var(--radius); background: var(--paper); color: var(--ink);
}
.search input:focus { border-color: var(--brand); }
.search button {
  font: inherit; font-weight: 700; cursor: pointer;
  padding: .75rem 1.4rem; border: 2px solid var(--brand);
  background: var(--brand); color: #fff; border-radius: var(--radius);
}
.search button:hover { background: var(--brand-dark); border-color: var(--brand-dark); }

.site-nav { background: var(--brand); }
.site-nav ul {
  display: flex; flex-wrap: wrap; list-style: none; margin: 0; padding: 0;
}
.site-nav a {
  display: block; padding: .95rem 1.15rem;
  color: #fff; font-weight: 600; text-decoration: none;
}
.site-nav a:hover, .site-nav a:focus-visible { background: var(--brand-dark); color: #fff; }

/* ---------- Breadcrumbs ---------- */
.crumbs { background: var(--paper); border-bottom: 1px solid var(--line); font-size: 1rem; }
.crumbs ol { display: flex; flex-wrap: wrap; gap: .5rem; list-style: none; margin: 0; padding: .75rem 0; }
.crumbs li + li::before { content: "›"; margin-right: .5rem; color: var(--ink-soft); }

/* ---------- Sections ---------- */
section { padding: 3rem 0; }
section.tinted { background: var(--paper); border-block: 1px solid var(--line); }

.hero { background: var(--brand-tint); border-bottom: 1px solid var(--line); padding: 3.5rem 0; }
.hero p.lead { font-size: 1.3rem; color: var(--ink-soft); max-width: 60ch; }

.lead { font-size: 1.2rem; color: var(--ink-soft); }

/* ---------- Cards ---------- */
.grid {
  display: grid; gap: 1.5rem; list-style: none; margin: 0; padding: 0;
  grid-template-columns: repeat(auto-fill, minmax(min(100%, 21rem), 1fr));
}

.card {
  display: flex; flex-direction: column; gap: .5rem;
  background: var(--paper); border: 2px solid var(--line);
  border-radius: var(--radius); padding: 1.5rem;
}
.card:hover { border-color: var(--brand); }
.card h2, .card h3 { margin-bottom: .25rem; font-size: 1.35rem; }
.card h2 a, .card h3 a { text-decoration: none; }
.card h2 a:hover, .card h3 a:hover { text-decoration: underline; }
.card p { margin: 0; }
.card .card-icon { font-size: 2.2rem; line-height: 1; }
.card .meta { margin-top: auto; padding-top: .75rem; font-size: 1rem; color: var(--ink-soft); }

.badges { display: flex; flex-wrap: wrap; gap: .5rem; margin: 0; padding: 0; list-style: none; }
.badge {
  display: inline-block; font-size: .95rem; font-weight: 600;
  padding: .2rem .7rem; border-radius: 999px;
  background: var(--brand-tint); color: var(--brand-dark);
  border: 1px solid #b9d6cc;
}
.badge.warn { background: var(--accent-tint); color: var(--accent); border-color: #e8c9a8; }

/* ---------- Buttons ---------- */
.btn {
  display: inline-block; font-weight: 700; text-decoration: none; cursor: pointer;
  padding: .85rem 1.6rem; border-radius: var(--radius);
  border: 2px solid var(--brand); background: var(--brand); color: #fff;
  font-size: 1.1rem;
}
.btn:hover { background: var(--brand-dark); border-color: var(--brand-dark); color: #fff; }
.btn.secondary { background: var(--paper); color: var(--brand); }
.btn.secondary:hover { background: var(--brand-tint); color: var(--brand-dark); }
.btn-row { display: flex; flex-wrap: wrap; gap: 1rem; margin-top: 1.5rem; }

/* ---------- Listing detail ---------- */
.detail { display: grid; gap: 2.5rem; grid-template-columns: minmax(0, 2fr) minmax(0, 1fr); align-items: start; }
@media (max-width: 46rem) { .detail { grid-template-columns: 1fr; } }

.panel {
  background: var(--paper); border: 2px solid var(--line);
  border-radius: var(--radius); padding: 1.5rem;
}
.panel h2 { font-size: 1.2rem; }
.panel dl { margin: 0; }
.panel dt { font-weight: 700; margin-top: 1rem; }
.panel dt:first-child { margin-top: 0; }
.panel dd { margin: 0; }

.notice {
  background: var(--accent-tint); border: 2px solid #e8c9a8;
  border-left-width: 8px; border-radius: var(--radius);
  padding: 1.25rem 1.5rem; margin: 1.5rem 0;
}
.notice.good { background: var(--brand-tint); border-color: #b9d6cc; }
.notice :last-child { margin-bottom: 0; }

/* ---------- Forms ---------- */
.form { max-width: 40rem; }
.field { margin-bottom: 1.5rem; }
.field label { display: block; font-weight: 700; margin-bottom: .4rem; }
.field .hint { display: block; font-weight: 400; font-size: 1rem; color: var(--ink-soft); }
.field input, .field select, .field textarea {
  width: 100%; font: inherit; padding: .8rem .9rem;
  border: 2px solid var(--line); border-radius: var(--radius);
  background: var(--paper); color: var(--ink);
}
.field input:focus, .field select:focus, .field textarea:focus { border-color: var(--brand); }
.field.error input, .field.error textarea, .field.error select { border-color: #a4262c; }
.field .err { display: block; color: #a4262c; font-weight: 700; margin-top: .35rem; }

/* ---------- Footer ---------- */
.site-footer { background: var(--ink); color: #e7ecf1; margin-top: 3rem; padding: 3rem 0 2rem; }
.site-footer h2 { color: #fff; font-size: 1.2rem; }
.site-footer a { color: #a8dccb; }
.site-footer a:hover { color: #fff; }
.site-footer p { color: #cdd6de; }
.footer-grid { display: grid; gap: 2.5rem; grid-template-columns: repeat(auto-fit, minmax(min(100%, 17rem), 1fr)); }
.footer-grid ul { list-style: none; margin: 0; padding: 0; }
.footer-grid li { padding: .3rem 0; }
.disclaimer { margin-top: 2.5rem; padding-top: 1.5rem; border-top: 1px solid #3a4654; font-size: 1rem; }
.copy { color: #9aa7b4; }

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

@media print {
  .site-nav, .search, .site-footer, .skip, .crumbs { display: none; }
  body { background: #fff; font-size: 12pt; }
}
