/* Styles for the editable page sections, added on top of site.css (the original website's stylesheet). */

.narrow { max-width: 860px; }
.page-hero.center { text-align: center; }
.page-intro { margin-top: 4px; }
.page-hero.center .page-intro { text-align: center; }
.block-buttons { margin-top: 26px; }

/* Rich text written in the admin editor */
.rich > div > * + * { margin-top: 16px; }
.rich h2 { font-size: 26px; font-weight: 700; margin-top: 30px; }
.rich h3 { font-size: 21px; font-weight: 700; margin-top: 24px; }
.rich ul, .rich ol { padding-left: 22px; list-style: revert; }
.rich li + li { margin-top: 6px; }
.rich blockquote { margin: 0; padding: 4px 0 4px 18px; border-left: 4px solid var(--pink); font-style: italic; }
.rich a { text-decoration: underline; }

/* Text with photo: photo on the right */
.split.flip > :first-child { order: 2; }

/* Header: full-width sliding photos with the text on top */
.hero-banner { position: relative; min-height: min(78vh, 640px); display: flex; align-items: flex-end; overflow: hidden; background: var(--ink); color: #fff; }
.hero-banner .hero-slides { position: absolute; inset: 0; aspect-ratio: auto; border-radius: 0; }
.hero-banner::after { content: ""; position: absolute; inset: 0; background: linear-gradient(180deg, rgba(23, 17, 28, .1) 30%, rgba(23, 17, 28, .78)); pointer-events: none; }
.hero-banner-text { position: relative; z-index: 1; width: 100%; padding-bottom: 64px; }
.hero-banner .hero-title, .hero-banner .hero-lead { color: #fff; max-width: 22em; }
.hero-banner .hero-lead { max-width: 36em; margin-bottom: 26px; }
.hero-banner .hero-dots { z-index: 2; bottom: 22px; }

/* Header: centred text only */
.hero-centered { text-align: center; padding: 30px 0; }
.hero-centered .hero-lead { margin: 0 auto 26px; }

/* Columns (Vision & Mission) */
.cols { display: grid; gap: 56px; }
.cols-1 { grid-template-columns: 1fr; }
.cols-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.cols-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 32px; }
.cols-cards { gap: 24px; }
.cols-cards .col { background: var(--surface); border-radius: var(--radius-lg); padding: 34px 32px; box-shadow: var(--shadow); }
.cols-coloured { gap: 24px; }
.cols-coloured .col { background: var(--c); color: #fff; border-radius: var(--radius-lg); padding: 36px 34px; }
.cols-coloured .col .title, .cols-coloured .col .text { color: #fff; }

/* Numbers strip adapts to how many figures there are */
.stats-grid { grid-template-columns: repeat(var(--n, 5), minmax(0, 1fr)); }
.band-title { color: #fff; margin-bottom: 26px; }

/* Thematic areas: pink band with round icons */
.ring-band { background: var(--pink); color: #fff; }
.ring-band .title { color: #fff; }
.band-intro { text-align: center; max-width: 760px; margin: -6px auto 30px; }
.rings { display: grid; grid-template-columns: repeat(auto-fit, minmax(190px, 1fr)); gap: 30px 22px; }
.ring-item { display: block; text-align: center; color: #fff; }
.ring-item:hover { color: #fff; }
.ring { width: 100px; height: 100px; border-radius: 50%; border: 3px solid currentColor; display: grid; place-items: center; margin: 0 auto 16px; transition: background .15s, color .15s; }
.ring svg { width: 46px; height: 46px; stroke-width: 1.6; }
a.ring-item[href]:hover .ring { background: #fff; color: var(--pink); }
.ring-item h3 { font-size: 21px; font-weight: 700; margin-bottom: 8px; }
.ring-item p { font-size: 15px; line-height: 1.55; }

.project-photo { width: calc(100% + 60px); max-width: none; margin: -32px -30px 22px; aspect-ratio: 16 / 9; object-fit: cover; border-radius: var(--radius-lg) var(--radius-lg) 0 0; }
.project { overflow: hidden; }

/* Simple lists for publications and news */
.doc-list { display: grid; gap: 12px; }
.doc-list li a { display: block; background: var(--surface); border-radius: 14px; padding: 16px 20px; box-shadow: var(--shadow); color: var(--ink); }
.doc-list li a:hover { color: var(--pink); }
.doc-list strong { color: var(--pink); margin-right: 10px; }

/* News cards and story page */
.post-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(290px, 1fr)); gap: 22px; }
.post-card { display: flex; flex-direction: column; background: var(--surface); border-radius: var(--radius); overflow: hidden; box-shadow: var(--shadow); color: var(--ink); }
.post-card:hover { color: var(--ink); transform: translateY(-3px); transition: transform .15s; }
.post-card img { width: 100%; aspect-ratio: 16 / 10; object-fit: cover; }
.post-card-body { padding: 20px 22px 24px; }
.post-card h3 { font-size: 21px; font-weight: 700; margin: 4px 0 8px; }
.post-card p { color: var(--ink-2); font-size: 15.5px; line-height: 1.55; }
.post-date { color: var(--muted); font-size: 14.5px; font-weight: 500; }
.post-image { margin: 18px 0 28px; aspect-ratio: 16 / 9; }
.post-body > div > * + * { margin-top: 16px; }
.link-back { display: inline-block; margin-bottom: 18px; font-weight: 600; }
.link-back::before { content: "\2190  "; }

/* Gallery: single row */
.gallery-strip { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.gallery-strip a:nth-child(n+5) { display: none; }

/* Row of photos adapts to 2-4 photos */
.photo-row { grid-template-columns: repeat(var(--n, 3), minmax(0, 1fr)); }

.quote-centered { text-align: center; }
.quote-centered blockquote { font-size: clamp(20px, 2.4vw, 26px); color: var(--ink); }
.cta-text { max-width: 640px; margin: -8px auto 26px; text-align: center; }
.bg-dark .cta-text { color: #D6CEDC; }
.bank-details p { font-size: 18px; font-weight: 600; color: var(--ink); margin-bottom: 8px; }

@media (max-width: 1000px) {
  .stats-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}
@media (max-width: 900px) {
  .cols-2, .cols-3 { grid-template-columns: 1fr; gap: 32px; }
  .split.flip > :first-child { order: 0; }
  .gallery-strip { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 640px) {
  .photo-row { grid-template-columns: 1fr; }
  .hero-banner-text { padding-bottom: 54px; }
  .stats-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

/* Outline buttons stay visible on dark bands */
.bg-dark .btn-outline, .hero-banner .btn-outline { border-color: #fff; color: #fff; }
.bg-dark .btn-outline:hover, .hero-banner .btn-outline:hover { background: #fff; color: var(--ink); }

/* Impact cards: one row for up to four figures; five or more keep the 3 + 2 layout */
.impact-grid.n-1 { grid-template-columns: minmax(0, 1fr); }
.impact-grid.n-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.impact-grid.n-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.impact-grid.n-4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.impact-grid.n-1 > *, .impact-grid.n-2 > *, .impact-grid.n-3 > *, .impact-grid.n-4 > * { grid-column: auto; }
@media (max-width: 1000px) {
  .impact-grid.n-3, .impact-grid.n-4 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 640px) {
  .impact-grid[class*="n-"] { grid-template-columns: minmax(0, 1fr); }
}

/* Less space between a page's title and its first section */
.page-title-wrap + .section, .page-title-wrap + div > .section { padding-top: 18px; }
