/* HOPE Tameside – Hope for Paediatric Epilepsy
   Brand colours from the charity's 2014–16 website: HOPE purple (#5D3099) and
   the yellow of the jigsaw logo. Headings: Fredoka. Text: Nunito. */

:root {
  --purple: #5b2c91;
  --purple-700: #45206f;
  --purple-900: #2c1449;
  --purple-100: #efe8f8;
  --purple-50: #f8f5fc;
  --yellow: #ffd93b;
  --yellow-300: #ffe680;
  --yellow-100: #fff6cc;
  --ink: #1f1830;
  --muted: #5d5570;
  --line: #e6dff0;
  --white: #fff;
  --do: #1e7a4c;
  --do-bg: #e7f6ee;
  --dont: #b4232f;
  --dont-bg: #fdecee;

  --font-head: "Fredoka", "Trebuchet MS", system-ui, sans-serif;
  --font-body: "Nunito", system-ui, -apple-system, "Segoe UI", sans-serif;

  --radius-sm: 12px;
  --radius: 22px;
  --radius-lg: 32px;
  --shadow-sm: 0 1px 2px rgba(44, 20, 73, .06), 0 2px 8px rgba(44, 20, 73, .06);
  --shadow: 0 2px 4px rgba(44, 20, 73, .05), 0 12px 32px rgba(44, 20, 73, .10);
  --wrap: 1160px;
  --gutter: clamp(16px, 4vw, 32px);
}

/* ---------- Base ---------- */

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

html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } *, *::before, *::after { transition: none !important; animation: none !important; } }

body {
  margin: 0;
  font-family: var(--font-body);
  font-size: 1.0625rem;
  line-height: 1.65;
  color: var(--ink);
  background: var(--white);
  text-rendering: optimizeLegibility;
}

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

h1, h2, h3, h4 {
  font-family: var(--font-head);
  font-weight: 600;
  line-height: 1.15;
  color: var(--purple-900);
  margin: 0 0 .5em;
  letter-spacing: -.01em;
}
h1 { font-size: clamp(2.2rem, 5vw, 3.6rem); }
h2 { font-size: clamp(1.7rem, 3.4vw, 2.5rem); }
h3 { font-size: clamp(1.25rem, 2.2vw, 1.5rem); }
h4 { font-size: 1.125rem; }

p { margin: 0 0 1em; }
ul, ol { margin: 0 0 1em; padding-left: 1.25em; }
li { margin-bottom: .35em; }
strong, b { font-weight: 800; }

a { color: var(--purple); text-decoration-thickness: 2px; text-underline-offset: 3px; }
a:hover { color: var(--purple-700); text-decoration-color: var(--yellow); }

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

.wrap { width: 100%; max-width: var(--wrap); margin: 0 auto; padding: 0 var(--gutter); }
.narrow { max-width: 780px; }

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

.skip-link {
  position: absolute; left: 12px; top: -60px; z-index: 100;
  background: var(--purple); color: #fff; padding: 10px 16px; border-radius: 10px; font-weight: 700;
}
.skip-link:focus { top: 12px; }

/* ---------- The name: H, O, P and E picked out in yellow, as in HOPE's logo ---------- */

.hope-name b {
  font-weight: inherit;
  color: var(--yellow);
  /* On light backgrounds yellow needs an outline to be readable, like the logo's lettering. */
  -webkit-text-stroke: .055em var(--purple-900);
  paint-order: stroke fill;
}
.page-hero .hope-name b,
.section-purple .hope-name b,
.donate-band .hope-name b,
.site-footer .hope-name b { -webkit-text-stroke: 0; }

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

.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: .5em;
  font-family: var(--font-head); font-weight: 600; font-size: 1.05rem; line-height: 1;
  padding: .85em 1.5em; border-radius: 999px; border: 2px solid transparent;
  text-decoration: none; cursor: pointer; transition: transform .15s ease, background-color .15s ease, box-shadow .15s ease;
}
.btn:hover { transform: translateY(-2px); }
.btn-primary { background: var(--purple); color: #fff; box-shadow: 0 6px 16px rgba(91, 44, 145, .28); }
.btn-primary:hover { background: var(--purple-700); color: #fff; }
.btn-yellow, .btn-donate { background: var(--yellow); color: var(--purple-900); box-shadow: 0 6px 16px rgba(255, 196, 0, .35); }
.btn-yellow:hover, .btn-donate:hover { background: var(--yellow-300); color: var(--purple-900); }
.btn-ghost { background: transparent; color: var(--purple); border-color: var(--purple); }
.btn-ghost:hover { background: var(--purple-50); color: var(--purple-700); }
.btn-light { background: #fff; color: var(--purple-900); }
.btn-light:hover { background: var(--purple-50); color: var(--purple-900); }
.btn-row { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 1.5em; }

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

.site-header {
  position: sticky; top: 0; z-index: 50;
  background: rgba(255, 255, 255, .92);
  backdrop-filter: saturate(160%) blur(10px);
  -webkit-backdrop-filter: saturate(160%) blur(10px);
  border-bottom: 1px solid var(--line);
}
.header-inner { display: flex; align-items: center; justify-content: space-between; gap: 16px; min-height: 76px; }

.brand { display: flex; align-items: center; gap: 12px; flex: none; text-decoration: none; color: var(--purple-900); }
.brand img { width: 54px; height: auto; }
.brand-text { display: flex; flex-direction: column; line-height: 1.1; white-space: nowrap; }
.brand-name { font-family: var(--font-head); font-weight: 700; font-size: 1.35rem; color: var(--purple); }
.brand-tag { font-size: .8rem; font-weight: 700; color: var(--muted); }
.brand-tag .hope-name b { -webkit-text-stroke-width: .09em; }

.site-nav { display: flex; align-items: center; gap: 20px; }
.site-nav ul { display: flex; align-items: center; gap: 2px; list-style: none; margin: 0; padding: 0; }
.site-nav li { margin: 0; }
.site-nav ul a {
  display: block; padding: 8px 12px; border-radius: 999px;
  font-weight: 700; font-size: .98rem; color: var(--ink); text-decoration: none; white-space: nowrap;
  transition: background-color .15s ease, color .15s ease;
}
.site-nav ul a:hover { background: var(--purple-50); color: var(--purple); }
.site-nav ul a[aria-current="page"] { background: var(--purple-100); color: var(--purple); }
.btn-donate { padding: .7em 1.3em; }

.nav-toggle { display: none; }

@media (max-width: 1220px) {
  .nav-toggle {
    display: inline-flex; align-items: center; justify-content: center;
    width: 48px; height: 48px; border-radius: 14px; border: 0;
    background: var(--purple-50); cursor: pointer;
  }
  .nav-toggle-bars, .nav-toggle-bars::before, .nav-toggle-bars::after {
    display: block; width: 22px; height: 2.5px; border-radius: 2px; background: var(--purple); position: relative;
    transition: transform .2s ease, background-color .2s ease;
  }
  .nav-toggle-bars::before, .nav-toggle-bars::after { content: ""; position: absolute; left: 0; }
  .nav-toggle-bars::before { top: -7px; }
  .nav-toggle-bars::after { top: 7px; }
  .nav-open .nav-toggle-bars { background: transparent; }
  .nav-open .nav-toggle-bars::before { transform: translateY(7px) rotate(45deg); }
  .nav-open .nav-toggle-bars::after { transform: translateY(-7px) rotate(-45deg); }

  .site-nav {
    display: none; position: absolute; left: 0; right: 0; top: 100%;
    flex-direction: column; align-items: stretch; gap: 12px;
    padding: 12px var(--gutter) 20px; background: #fff;
    border-bottom: 1px solid var(--line); box-shadow: var(--shadow);
  }
  .nav-open .site-nav { display: flex; }
  .site-nav ul { flex-direction: column; align-items: stretch; }
  .site-nav ul a { padding: 12px 14px; border-radius: 12px; font-size: 1.05rem; }
  .btn-donate { align-self: flex-start; }
}
@media (max-width: 420px), (min-width: 1221px) and (max-width: 1400px) { .brand-tag { display: none; } }
@media (min-width: 1221px) and (max-width: 1400px) { .site-nav { gap: 12px; } .site-nav ul a { padding: 8px 9px; font-size: .95rem; } }

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

.section { padding: clamp(56px, 8vw, 104px) 0; }
.section-tight { padding: clamp(40px, 6vw, 72px) 0; }
.section-lilac { background: var(--purple-50); }
.section-purple { background: var(--purple); color: #fff; }
.section-purple h2, .section-purple h3 { color: #fff; }
.section-purple a:not(.btn) { color: var(--yellow); }

.eyebrow {
  display: inline-flex; align-items: center; gap: 8px;
  font-family: var(--font-head); font-weight: 600; font-size: .95rem; letter-spacing: .04em; text-transform: uppercase;
  color: var(--purple); margin-bottom: .8em;
}
.eyebrow::before {
  content: ""; width: 18px; height: 18px; flex: none;
  background: var(--yellow);
  -webkit-mask: url("../img/piece.svg") center / contain no-repeat; mask: url("../img/piece.svg") center / contain no-repeat;
}
.section-purple .eyebrow { color: var(--yellow); }

.section-head { max-width: 720px; margin-bottom: clamp(28px, 4vw, 48px); }
.section-head.center { margin-left: auto; margin-right: auto; text-align: center; }
.lead { font-size: clamp(1.1rem, 1.8vw, 1.3rem); color: var(--muted); }
.section-purple .lead { color: #e9defa; }

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

.page-hero {
  position: relative; overflow: hidden;
  background: linear-gradient(135deg, var(--purple) 0%, var(--purple-700) 100%);
  color: #fff; padding: clamp(48px, 7vw, 88px) 0 clamp(56px, 8vw, 96px);
}
.page-hero h1 { color: #fff; max-width: 16ch; }
.page-hero .lead { color: #eadff9; max-width: 640px; margin: 0; }
.page-hero .eyebrow { color: var(--yellow); }
.page-hero::after {
  content: ""; position: absolute; right: -60px; bottom: -70px; width: 320px; height: 320px;
  background: var(--yellow); opacity: .95; transform: rotate(-14deg);
  -webkit-mask: url("../img/piece.svg") center / contain no-repeat; mask: url("../img/piece.svg") center / contain no-repeat;
}
.page-hero::before {
  content: ""; position: absolute; right: 230px; top: -40px; width: 140px; height: 140px;
  background: rgba(255, 255, 255, .08); transform: rotate(18deg);
  -webkit-mask: url("../img/piece.svg") center / contain no-repeat; mask: url("../img/piece.svg") center / contain no-repeat;
}
.page-hero .wrap { position: relative; z-index: 1; }
@media (max-width: 720px) { .page-hero::after { width: 120px; height: 120px; right: -48px; bottom: -58px; } .page-hero::before { display: none; } .page-hero { padding-bottom: 72px; } }

.breadcrumb { font-size: .95rem; margin-bottom: 1em; }
.breadcrumb a { color: var(--yellow); }

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

.hero { position: relative; overflow: hidden; background: var(--purple-50); padding: clamp(40px, 6vw, 80px) 0 clamp(56px, 8vw, 96px); }
.hero-grid { display: grid; grid-template-columns: 1fr 1.15fr; gap: clamp(28px, 5vw, 64px); align-items: center; }
.hero h1 { font-size: clamp(2.5rem, 6vw, 4.4rem); color: var(--purple-900); }
.hero .lead { color: var(--muted); max-width: 34em; }
.hero-photo { position: relative; }
.hero-photo .frame {
  position: relative; z-index: 1; border-radius: var(--radius-lg); overflow: hidden;
  box-shadow: var(--shadow); border: 6px solid #fff; transform: rotate(1.5deg);
}
.hero-photo .frame img { width: 100%; aspect-ratio: 950 / 320; object-fit: cover; }
.hero-photo .piece {
  position: absolute; z-index: 0; background: var(--yellow);
  -webkit-mask: url("../img/piece.svg") center / contain no-repeat; mask: url("../img/piece.svg") center / contain no-repeat;
}
.hero-photo .piece-1 { width: 150px; height: 150px; right: -36px; top: -54px; transform: rotate(16deg); }
.hero-photo .piece-2 { width: 110px; height: 110px; left: -40px; bottom: -48px; transform: rotate(-20deg); background: var(--purple); opacity: .9; }
.hero-photo .badge {
  position: relative; z-index: 2; margin: -18px 0 0 24px; width: fit-content;
  background: #fff; border-radius: 18px; padding: 12px 16px; box-shadow: var(--shadow);
  display: flex; align-items: center; gap: 12px; max-width: 290px;
}
.hero-photo .badge strong { font-family: var(--font-head); font-size: 1.9rem; color: var(--purple); line-height: 1; }
.hero-photo .badge span { font-size: .92rem; font-weight: 700; color: var(--muted); line-height: 1.3; }
@media (max-width: 900px) {
  .hero-grid { grid-template-columns: 1fr; }
  .hero-photo { margin: 12px 8px 32px; }
}

/* ---------- Cards & grids ---------- */

.grid { display: grid; gap: clamp(16px, 2.4vw, 28px); }
.grid-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.grid-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.grid-4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
@media (max-width: 960px) { .grid-3, .grid-4 { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 640px) { .grid-2, .grid-3, .grid-4 { grid-template-columns: 1fr; } }

.card {
  position: relative; background: #fff; border: 1px solid var(--line); border-radius: var(--radius);
  padding: clamp(22px, 3vw, 32px); box-shadow: var(--shadow-sm);
}
.card > :last-child { margin-bottom: 0; }
.card h3 { margin-bottom: .4em; }
.card-link { text-decoration: none; color: inherit; display: flex; flex-direction: column; transition: transform .2s ease, box-shadow .2s ease; }
.card-link:hover { transform: translateY(-4px); box-shadow: var(--shadow); color: inherit; }
.card-link .more { margin-top: auto; padding-top: .8em; font-family: var(--font-head); font-weight: 600; color: var(--purple); }
.card-link .more::after { content: " →"; }
.card-lilac { background: var(--purple-50); border-color: transparent; }
.card-yellow { background: var(--yellow-100); border-color: transparent; }

.icon-blob {
  width: 58px; height: 58px; border-radius: 18px; margin-bottom: 18px;
  display: grid; place-items: center; background: var(--purple-100); color: var(--purple);
}
.icon-blob svg { width: 28px; height: 28px; }
.card-yellow .icon-blob { background: var(--yellow); color: var(--purple-900); }

/* Split: text beside an image */
.split { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(28px, 5vw, 72px); align-items: center; }
.split.reverse > :first-child { order: 2; }
@media (max-width: 860px) { .split { grid-template-columns: 1fr; } .split.reverse > :first-child { order: 0; } }

.photo-card { border-radius: var(--radius-lg); overflow: hidden; box-shadow: var(--shadow); background: var(--purple-50); }
.photo-card img { width: 100%; }
.photo-soft { background: linear-gradient(160deg, var(--purple-100), var(--yellow-100)); display: grid; place-items: center; padding: 24px; }
.photo-soft img { width: auto; max-height: 420px; border-radius: 16px; }

/* ---------- Text blocks ---------- */

.prose { max-width: 760px; }
.prose h2 { margin-top: 1.6em; }
.prose h3 { margin-top: 1.4em; color: var(--purple); }
.prose > :first-child { margin-top: 0; }
.prose ul li::marker { color: var(--purple); }

.quote {
  position: relative; margin: 0; padding: clamp(22px, 3vw, 32px) clamp(22px, 3vw, 32px) clamp(22px, 3vw, 32px) clamp(56px, 6vw, 72px);
  background: #fff; border-radius: var(--radius); border: 1px solid var(--line); box-shadow: var(--shadow-sm);
}
.quote::before {
  content: "“"; position: absolute; left: 18px; top: 4px;
  font-family: var(--font-head); font-size: 4.5rem; line-height: 1; color: var(--yellow);
  -webkit-text-stroke: 2px var(--purple);
}
.quote p { margin-bottom: .6em; }
.quote footer, .quote cite { display: block; font-style: normal; font-weight: 800; color: var(--purple); }
.quote.big { font-family: var(--font-head); font-size: clamp(1.3rem, 2.6vw, 1.8rem); line-height: 1.35; font-weight: 500; color: var(--purple-900); }
.quote-wall { columns: 2 340px; column-gap: clamp(16px, 2.4vw, 28px); }
.quote-wall .quote { break-inside: avoid; margin-bottom: clamp(16px, 2.4vw, 28px); }

.callout {
  display: flex; gap: 16px; align-items: flex-start;
  background: var(--yellow-100); border-radius: var(--radius); padding: 20px 24px; margin: 1.5em 0;
}
.callout svg { flex: none; width: 28px; height: 28px; color: var(--purple); margin-top: 2px; }
.callout p:last-child { margin-bottom: 0; }

.chips { display: flex; flex-wrap: wrap; gap: 8px; list-style: none; padding: 0; margin: 0 0 1em; }
.chips li { margin: 0; padding: 7px 14px; border-radius: 999px; background: var(--purple-50); color: var(--purple-900); font-weight: 700; font-size: .95rem; }
.section-lilac .chips li, .card-lilac .chips li { background: #fff; box-shadow: var(--shadow-sm); }

.pill-list { list-style: none; padding: 0; display: grid; gap: 10px; }
.pill-list li { margin: 0; padding: 14px 18px 14px 50px; background: #fff; border: 1px solid var(--line); border-radius: 16px; position: relative; }
.pill-list li::before {
  content: ""; position: absolute; left: 16px; top: 17px; width: 20px; height: 20px; background: var(--purple);
  -webkit-mask: url("../img/piece.svg") center / contain no-repeat; mask: url("../img/piece.svg") center / contain no-repeat;
}

/* Seizure types */
.type-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 14px; }
.type { background: #fff; border-radius: 18px; padding: 18px 20px; border: 1px solid var(--line); }
.type h4 { color: var(--purple); margin-bottom: .3em; }
.type p { margin: 0; font-size: .98rem; color: var(--muted); }

/* First aid */
.firstaid { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(16px, 2.4vw, 28px); }
@media (max-width: 760px) { .firstaid { grid-template-columns: 1fr; } }
.firstaid .card { border: 0; }
.firstaid .do { background: var(--do-bg); }
.firstaid .dont { background: var(--dont-bg); }
.firstaid h3 { display: flex; align-items: center; gap: 10px; }
.firstaid .do h3 { color: var(--do); }
.firstaid .dont h3 { color: var(--dont); }
.firstaid ul { list-style: none; padding: 0; margin: 0; }
.firstaid li { position: relative; padding-left: 34px; margin-bottom: .7em; font-weight: 600; }
.firstaid li::before {
  position: absolute; left: 0; top: 1px; width: 24px; height: 24px; border-radius: 50%;
  display: grid; place-items: center; font-size: .85rem; font-weight: 800; color: #fff;
}
.firstaid .do li::before { content: "✓"; background: var(--do); }
.firstaid .dont li::before { content: "✕"; background: var(--dont); }

/* ---------- Heroes (stories) ---------- */

.hero-card { overflow: hidden; padding: 0; }
.hero-card .avatar {
  aspect-ratio: 4 / 3; display: grid; place-items: center; overflow: hidden;
  background: linear-gradient(150deg, var(--purple-100), var(--yellow-100));
}
.hero-card .avatar img { width: 100%; height: 100%; object-fit: cover; object-position: center 20%; }
.hero-card .avatar .initial {
  width: 112px; height: 112px; display: grid; place-items: center;
  font-family: var(--font-head); font-weight: 700; font-size: 3.2rem; color: var(--purple-900);
  background: var(--yellow);
  -webkit-mask: url("../img/piece.svg") center / contain no-repeat; mask: url("../img/piece.svg") center / contain no-repeat;
}
.hero-card .body { padding: 22px 24px 24px; display: flex; flex-direction: column; flex: 1; }
.hero-card .body p { color: var(--muted); font-size: .98rem; }

.story { display: grid; grid-template-columns: minmax(0, 1fr) 300px; gap: clamp(28px, 5vw, 64px); align-items: start; }
@media (max-width: 900px) { .story { grid-template-columns: 1fr; } .story aside { order: -1; max-width: 420px; } }
.story aside { position: sticky; top: 100px; }
.story-photo { border-radius: var(--radius-lg); overflow: hidden; box-shadow: var(--shadow); background: linear-gradient(150deg, var(--purple-100), var(--yellow-100)); }
.story-photo .initial-lg {
  aspect-ratio: 1; display: grid; place-items: center;
  font-family: var(--font-head); font-weight: 700; font-size: 6rem; color: var(--purple);
}
.signoff { margin-top: 2em; padding-top: 1.2em; border-top: 2px dashed var(--line); font-weight: 800; color: var(--purple); }
.signoff span { display: block; font-weight: 600; color: var(--muted); }
.memorial { background: var(--purple-50); border-radius: var(--radius); padding: 18px 22px; font-weight: 700; color: var(--purple-900); }
.source-note { font-size: .95rem; color: var(--muted); }

.story-nav { display: flex; justify-content: space-between; gap: 16px; flex-wrap: wrap; margin-top: 3em; }

/* ---------- Sessions ---------- */

.session { display: flex; flex-direction: column; gap: 6px; }
.session .when {
  align-self: flex-start; font-family: var(--font-head); font-weight: 600; font-size: .9rem;
  letter-spacing: .03em; text-transform: uppercase; color: var(--purple-900);
  background: var(--yellow); border-radius: 999px; padding: 6px 14px; margin-bottom: 8px;
}
.session address { font-style: normal; color: var(--muted); }

/* ---------- Timeline (news) ---------- */

.timeline { list-style: none; padding: 0; margin: 0; position: relative; }
.timeline::before { content: ""; position: absolute; left: 15px; top: 8px; bottom: 8px; width: 3px; background: var(--purple-100); border-radius: 3px; }
.timeline > li { position: relative; padding-left: 52px; margin-bottom: clamp(20px, 3vw, 32px); }
.timeline > li::before {
  content: ""; position: absolute; left: 3px; top: 22px; width: 28px; height: 28px; background: var(--yellow);
  -webkit-mask: url("../img/piece.svg") center / contain no-repeat; mask: url("../img/piece.svg") center / contain no-repeat;
}
.news-card { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 24px; align-items: start; }
.news-card img { width: 180px; border-radius: 14px; }
@media (max-width: 680px) { .news-card { grid-template-columns: 1fr; } .news-card img { width: 100%; max-width: 300px; } }

/* ---------- Gallery ---------- */

.album + .album { margin-top: clamp(40px, 6vw, 64px); }
.album-head { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; flex-wrap: wrap; margin-bottom: 18px; }
.album-head h2 { font-size: clamp(1.4rem, 2.6vw, 1.9rem); margin: 0; }
.album-head span { color: var(--muted); font-weight: 700; }
.photos { display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 14px; }
.photos button {
  padding: 0; border: 0; background: var(--purple-50); border-radius: 18px; overflow: hidden; cursor: zoom-in;
  aspect-ratio: 3 / 2; box-shadow: var(--shadow-sm); transition: transform .2s ease, box-shadow .2s ease;
}
.photos button:hover { transform: translateY(-3px) rotate(-.6deg); box-shadow: var(--shadow); }
.photos img { width: 100%; height: 100%; object-fit: cover; }

.lightbox { border: 0; padding: 0; background: transparent; max-width: min(92vw, 900px); }
.lightbox::backdrop { background: rgba(28, 12, 48, .86); }
.lightbox img { border-radius: 18px; width: auto; max-width: 100%; max-height: 80vh; margin: 0 auto; image-rendering: auto; }
.lightbox p { color: #fff; text-align: center; margin: 12px 0 0; font-weight: 700; }
.lightbox .close {
  position: fixed; top: 16px; right: 16px; width: 48px; height: 48px; border-radius: 50%; border: 0;
  background: #fff; color: var(--purple-900); font-size: 1.6rem; line-height: 1; cursor: pointer;
}

/* ---------- Supporters ---------- */

.thanks-list { list-style: none; padding: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 14px; }
.thanks-list li { margin: 0; background: #fff; border: 1px solid var(--line); border-radius: 18px; padding: 16px 18px; }
.thanks-list strong { display: block; color: var(--purple); font-family: var(--font-head); font-weight: 600; font-size: 1.08rem; }
.thanks-list span { color: var(--muted); font-size: .97rem; }
.amount { display: inline-block; font-family: var(--font-head); font-weight: 600; color: var(--purple-900); background: var(--yellow); border-radius: 999px; padding: 2px 10px; font-size: .95rem; }
.logo-row { display: flex; flex-wrap: wrap; gap: 16px; align-items: center; }
.logo-row img { height: 90px; width: auto; border-radius: 12px; background: #fff; padding: 6px; border: 1px solid var(--line); }

/* ---------- Links list ---------- */

.link-list { list-style: none; padding: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 12px; }
.link-list li { margin: 0; }
.link-list a {
  display: flex; flex-direction: column; gap: 2px; height: 100%; padding: 16px 18px; border-radius: 16px;
  background: #fff; border: 1px solid var(--line); text-decoration: none; color: var(--ink); transition: border-color .15s ease, transform .15s ease;
}
.link-list a:hover { border-color: var(--purple); transform: translateY(-2px); }
.link-list strong { color: var(--purple); }
.link-list strong::after { content: " ↗"; font-weight: 600; }
.link-list span { color: var(--muted); font-size: .95rem; }

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

.donate-band { position: relative; overflow: hidden; border-radius: var(--radius-lg); background: var(--purple); color: #fff; padding: clamp(32px, 5vw, 56px); }
.donate-band h2 { color: #fff; }
.donate-band p { color: #eadff9; max-width: 560px; }
.donate-band::after {
  content: ""; position: absolute; right: -40px; top: -40px; width: 260px; height: 260px; background: var(--yellow); transform: rotate(22deg);
  -webkit-mask: url("../img/piece.svg") center / contain no-repeat; mask: url("../img/piece.svg") center / contain no-repeat;
}
.donate-band > * { position: relative; z-index: 1; }
@media (max-width: 640px) { .donate-band::after { width: 150px; height: 150px; right: -50px; top: -50px; } }
.paypal-form { margin: 0; }

/* Contact */
.contact-big { font-family: var(--font-head); font-weight: 600; font-size: clamp(1.8rem, 4vw, 2.6rem); color: var(--purple); text-decoration: none; }
.contact-big:hover { color: var(--purple-700); }
.roles { list-style: none; padding: 0; margin: 0; }
.roles li { display: flex; justify-content: space-between; gap: 12px; padding: 12px 0; border-bottom: 1px solid var(--line); margin: 0; }
.roles li span:first-child { color: var(--muted); font-weight: 700; }
.roles li span:last-child { font-weight: 800; text-align: right; }

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

.site-footer { background: var(--purple-900); color: #ddd2ee; padding: clamp(48px, 7vw, 80px) 0 0; margin-top: 0; }
.site-footer a { color: #fff; }
.site-footer a:hover { color: var(--yellow); }
.footer-grid { display: grid; grid-template-columns: 1.3fr 1fr .8fr; gap: clamp(28px, 4vw, 56px); }
@media (max-width: 860px) { .footer-grid { grid-template-columns: 1fr; } }
.footer-logo { display: inline-block; background: #fff; border-radius: 22px; padding: 10px 14px; margin-bottom: 16px; }
.footer-logo img { width: 92px; }
.footer-title { color: #fff; font-size: 1.2rem; margin-bottom: .8em; }
.footer-urgent { font-size: .95rem; color: var(--yellow-300); }
.footer-links { list-style: none; padding: 0; margin: 0; }
.footer-links a { text-decoration: none; font-weight: 700; }
.footer-legal { border-top: 1px solid rgba(255, 255, 255, .12); margin-top: clamp(32px, 5vw, 56px); padding-top: 20px; padding-bottom: 28px; font-size: .9rem; color: #b9a9d4; }
.footer-legal p { margin: 0; }

/* ---------- Utilities ---------- */

.center { text-align: center; }
.mt-0 { margin-top: 0 !important; }
.mb-0 { margin-bottom: 0; }
.muted { color: var(--muted); }
.stack > * + * { margin-top: clamp(16px, 2.4vw, 28px); }

/* ---------- Phones and tablets ---------- */

/* Open menu: scrolls on short screens, and the page behind stays still. */
@media (max-width: 1220px) {
  .site-nav { max-height: calc(100dvh - 64px); overflow-y: auto; overscroll-behavior: contain; }
  body.nav-open { overflow: hidden; }
}

/* Story pages: the photo sits above the story at a sensible size; the
   initial-only placeholder (no photo archived) is left out on small screens. */
@media (max-width: 900px) {
  .story aside { position: static; max-width: 260px; }
  .story aside:has(.initial-lg) { display: none; }
}

@media (max-width: 640px) {
  .header-inner { min-height: 64px; }
  .brand img { width: 46px; }
  .brand-name { font-size: 1.2rem; }
  .nav-toggle { width: 44px; height: 44px; }

  .section { padding: 48px 0; }
  .section-tight { padding: 32px 0; }
  .section-head { margin-bottom: 24px; }

  /* The archived photos are small: two per row keeps them sharp. */
  .photos { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
  .photos button { border-radius: 14px; }

  .hero-photo .badge { margin-left: 12px; max-width: calc(100% - 24px); }
  .hero-photo .badge strong { font-size: 1.6rem; }

  .icon-blob { width: 48px; height: 48px; border-radius: 14px; margin-bottom: 14px; }
  .icon-blob svg { width: 24px; height: 24px; }

  .btn-row .btn, .story-nav .btn { flex: 1 1 auto; }
  .lightbox .close { top: 10px; right: 10px; }
}

/* Comfortable tap targets for small links. */
.footer-links li { margin: 0; }
.footer-links a { display: inline-block; padding: 9px 0; }
.site-footer a[href^="tel:"] { display: inline-block; padding: 4px 0; }
.breadcrumb a { display: inline-block; padding: 6px 0; }
