/* Styled to match the church's previous Weebly site (theme fonts, colours and spacing). */
:root {
  --gold: #dea227;        /* buttons, links, current menu item */
  --title-gold: #dfb33e;  /* site name */
  --mustard: #caa900;     /* "Find us" footer band */
  --heading: #42514c;
  --ink: #2a2a2a;
  --muted: #8e8e8e;
  --line: #d0d0d0;
  --paper: #fff;
  --pale: #f9f9f9;
  --display: "Metamorphous", Georgia, serif;
  --serif: "Gentium Basic", Georgia, serif;
  --banner: "Lora", Georgia, serif;
  --menu: "Montserrat", system-ui, sans-serif;
  --ui: "Raleway", system-ui, sans-serif;
}
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; font: 18px/1.85 var(--serif); color: var(--ink); background: var(--paper); }
img { max-width: 100%; display: block; }
a { color: var(--gold); text-decoration: none; }
a:hover { text-decoration: underline; }
:focus-visible { outline: 2px solid var(--gold); outline-offset: 2px; }
h1, h2, h3 { font-family: var(--display); font-weight: 400; line-height: 1.25; color: var(--heading); margin: 0 0 0.5em; }
h1 { font-size: clamp(2rem, 5vw, 2.6rem); } h2 { font-size: clamp(1.6rem, 4vw, 2.1rem); } h3 { font-size: 1.3rem; }
h2 a, h3 a { color: inherit; }
.band-plain h2 a { color: var(--gold); }
p { margin: 0 0 1em; }
.wrap { width: min(100% - 3rem, 912px); margin-inline: auto; }
.narrow { max-width: 760px; }
.center { text-align: center; }
.skip { position: absolute; left: -999px; } .skip:focus { left: 1rem; top: 1rem; background: #fff; padding: 0.5rem 1rem; z-index: 10; }

/* Header: centred gold name, small spaced menu between hairlines */
.site-header { background: var(--paper); text-align: center; padding: 52px 1rem 25px; }
.brand { display: inline-block; font: 36px/1.25 var(--display); letter-spacing: 3px; color: var(--title-gold); text-decoration: none; }
.brand:hover { text-decoration: none; color: var(--gold); }
.site-header nav { display: flex; flex-wrap: wrap; justify-content: center; align-items: center; margin-top: 18px; }
.site-header nav::before, .site-header nav::after { content: ""; flex: 0 1 140px; height: 1px; background: var(--line); margin: 0 1.5rem; }
.menu { display: flex; flex-wrap: wrap; justify-content: center; list-style: none; margin: 0; padding: 0; }
.menu > li { position: relative; }
.menu-label { background: none; border: 0; cursor: default; }
.site-header nav a, .menu-label { display: block; font: 400 11px var(--menu); letter-spacing: 1px; text-transform: uppercase; color: var(--muted); padding: 10px 14px; text-decoration: none; }
.site-header nav a:hover, .has-sub:hover > .menu-label { color: var(--gold); background: #f6f6f6; }
.site-header nav a.current, .menu-label.current { background: #f6f6f6; color: var(--gold); }
/* Drop-down menus: open on hover, or when a link inside has keyboard focus */
.sub { display: none; position: absolute; top: 100%; left: 0; z-index: 30; min-width: 200px; list-style: none; margin: 0; padding: 0; background: #f6f6f6; text-align: left; box-shadow: 0 6px 14px rgb(0 0 0 / 0.08); }
.has-sub:hover > .sub, .has-sub:focus-within > .sub { display: block; }
.menu > li:nth-last-child(-n+2) > .sub { left: auto; right: 0; }
.site-header .sub a { color: var(--gold); padding: 9px 14px; line-height: 1.4; text-transform: none; font-size: 12px; letter-spacing: 0.2px; }
.sub li + li { border-top: 1px solid #e4e4e4; }
.site-header .sub a:hover, .site-header .sub a[aria-current] { background: #e8e8e8; color: #484848; }
/* Phones and tablets can't hover: tapping a heading (or the arrow beside a link) opens its list below the menu */
.sub-toggle { display: none; }
@media (max-width: 760px), (hover: none) {
  .menu { position: relative; }
  .menu > li { position: static; display: flex; align-items: center; }
  .menu-label { cursor: pointer; }
  .menu-label::after { content: " ▾"; }
  .sub-toggle { display: block; border: 0; background: none; color: var(--muted); padding: 10px 8px 10px 0; margin-left: -10px; font-size: 11px; cursor: pointer; }
  .sub-toggle::before { content: "▾"; }
  .has-sub:hover > .sub, .has-sub:focus-within > .sub { display: none; }
  .menu .has-sub.open > .sub { display: block; left: 0; right: 0; top: 100%; min-width: 0; text-align: center; }
}
@media (max-width: 760px) { .site-header nav::before, .site-header nav::after { display: none; } .site-header { padding-top: 32px; } .brand { font-size: 28px; } }

/* Buttons (Weebly's Raleway, spaced capitals) */
.button { display: inline-block; font: 600 11px var(--ui); letter-spacing: 2px; text-transform: uppercase; color: #fff; background: var(--gold); padding: 10px 25px; text-decoration: none; }
.button:hover { text-decoration: none; filter: brightness(1.08); }
.button-dark { background: rgb(50 50 50 / 0.85); font-size: 9px; padding: 8px 18px; }

/* Home banner */
.hero { position: relative; background: #3b3a36; color: #fff; text-align: center; padding: 5rem 0; overflow: hidden; }
.hero.has-image { min-height: 460px; display: flex; align-items: center; }
.hero > img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.hero::after { content: ""; position: absolute; inset: 0; background: rgb(0 0 0 / 0.12); }
.hero .wrap { position: relative; z-index: 1; max-width: 640px; }
.hero h1 { font: 400 clamp(2.2rem, 5vw, 50px)/1.2 var(--banner); color: #fff; margin: 0 0 1.4rem; text-shadow: 0 1px 10px rgb(0 0 0 / 0.35); }
.hero .buttons { display: flex; flex-direction: column; align-items: center; gap: 10px; margin: 0; }

/* Page title strip on inner pages */
.page-head { text-align: center; padding: 3rem 0 1rem; }
.page-head h1 { margin-bottom: 0.2em; }
.page-head p { color: var(--muted); margin: 0; font-style: italic; }

/* Full-width bands built from [[section]] markers */
.band { position: relative; padding: 60px 0; background: var(--paper); text-align: center; overflow: hidden; }
.band-inner { position: relative; z-index: 1; }
.band-head h2 { color: var(--title-gold); }
.band-pale { background: #f2f1ec url(/media/photos/bg-pale-pattern.jpg) center / cover; }
.band-pale h2, .band-pale .label { color: var(--title-gold); }
.band-gold { background: var(--mustard); color: #fff; }
.band-photo { color: #fff; padding: 70px 0; }
.band-bg { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.band-photo::before { content: ""; position: absolute; inset: 0; background: rgb(0 0 0 / 0.18); z-index: 1; }
.band-gold h2, .band-photo h2, .band-gold a, .band-photo a { color: #fff; }
.band-photo h2 { text-shadow: 0 1px 8px rgb(0 0 0 / 0.3); }
.band-photo p { font-size: 16px; text-shadow: 0 1px 6px rgb(0 0 0 / 0.35); }
.band-photo hr, .band hr { border: 0; border-top: 1px solid rgb(255 255 255 / 0.5); margin: 2rem 0; }
.band p:last-child { margin-bottom: 0; }
.cols { display: grid; gap: 2rem; align-items: center; }
@media (min-width: 760px) {
  .cols-2 { grid-template-columns: 1fr 1fr; }
  .cols-3 { grid-template-columns: repeat(3, 1fr); }
  .band-plain .cols-2 .col > p:not(.label) { text-align: justify; }
  .cols .col > blockquote p { text-align: center; }
}
.label { font: 400 11px/1.9 var(--serif); letter-spacing: 0.5px; text-transform: uppercase; margin-bottom: 1.2em; }
.label strong { font-weight: 700; }
.band-photo .label { font-size: 12px; }
.cols .col > .label { margin-bottom: 0.4em; }
blockquote { margin: 0; padding: 0 1.2rem; font-size: 16px; line-height: 1.9; position: relative; }
blockquote::before, blockquote::after { font: 44px/1 var(--banner); color: var(--ink); position: absolute; }
blockquote::before { content: "“"; left: 0; top: -0.2em; }
blockquote::after { content: "”"; right: 0; bottom: -0.6em; }
blockquote p { margin: 0; }
.figs { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 200px), 1fr)); gap: 8px; margin: 1.5rem 0; }
.figs figure { margin: 0; }
.figs img { width: 100%; aspect-ratio: 4 / 3; object-fit: cover; }
.figs:has(figure:nth-child(3)) img { aspect-ratio: 1; }
.band .figs { gap: 16px; }
figure { margin: 1.5rem 0; } figure img { margin: 0 auto; max-height: 80vh; }
.band figure img { max-height: 420px; }
figcaption { text-align: center; color: var(--muted); font-size: 0.85rem; margin-top: 0.5rem; }
.welcome .col > figure:only-child { margin: 0; }

/* More band colours */
.band-tan { background: #d3c8b1; }
.band-tan h2, .band-tan h1 { color: #fff; }
.band-cream { background: #f8e9d0; }
.band-texture { background: #efe6d2; }
.band-empty { padding: 0; min-height: clamp(220px, 40vw, 420px); }
.band-photo blockquote::before, .band-photo blockquote::after { color: #fff; }
.band .buttons, .prose .buttons { display: flex; flex-wrap: wrap; gap: 12px; justify-content: center; margin: 1.5rem 0; }
.band iframe.map, .prose iframe.map { display: block; width: 100%; aspect-ratio: 4 / 3; border: 0; margin: 1rem 0; }
.figs img[src$=".png"], .figs:has(figure:nth-child(5)) img { object-fit: contain; }
.figs:has(figure:nth-child(5)) { grid-template-columns: repeat(auto-fit, minmax(min(100%, 110px), 1fr)); }

/* Pages laid out in bands (About, Join Us …): text reads left to right like the Weebly pages */
.page-bands .band { text-align: left; padding: 50px 0; }
.page-bands .band-empty { padding: 0; }
.page-bands h1 { text-align: center; font-size: clamp(2rem, 5vw, 44px); margin-bottom: 0.8em; }
.page-bands h2 { color: var(--title-gold); margin: 1.2em 0 0.4em; }
.page-bands h2 { text-align: left; }
.page-bands .band-head > h2:first-child { text-align: center; }
.page-bands .col h2 { text-align: left; }
.page-bands .col > :first-child, .page-bands .band-head > :first-child { margin-top: 0; }
.page-bands .cols { align-items: start; }
.page-bands .band:not(.band-photo) p:not(.label):not(.buttons) { text-align: justify; }
.page-bands .label { text-align: left; font-size: 13px; color: var(--heading); }
.page-bands .band-photo { text-align: center; }
.band-tall { min-height: clamp(320px, 42vw, 520px); display: flex; align-items: center; }
.band-stone { background: #ebe8e1; }
.band-dark { background: #2b1616; color: #fff; }
.band-dark h1, .band-dark h2, .band-dark a { color: #fff; }
.band-plain hr, .band-cream hr, .band-stone hr { border-top-color: var(--line); }
.band-photo .enquiry { color: var(--ink); background: rgb(255 255 255 / 0.93); max-width: 680px; margin-inline: auto; }
figure a img { transition: opacity 0.15s; } figure a:hover img { opacity: 0.85; }
figure.small { margin: 0.5rem 0 1rem; } figure.small img { width: auto; max-width: 150px; margin: 0; }
/* Signatures that text wraps around, as on the Weebly team pages */
figure.small.right { float: right; margin: 0 0 0.25rem 1rem; }
figure.small.left { float: left; margin: 0 1rem 0.25rem 0; }
.col, .band-head { display: flow-root; }
.visually-hidden { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.page-bands .col h1 { text-align: left; font-size: clamp(1.8rem, 4vw, 2.3rem); }
.page-bands .band-photo h1 { color: #fff; font-family: var(--banner); text-shadow: 0 1px 10px rgb(0 0 0 / 0.35); margin-bottom: 0.2em; }
.page-bands .band-photo h2 { color: #fff; }
.page-bands .band-photo blockquote { max-width: 760px; margin: 0 auto; }
.page-bands .band-photo blockquote p, .page-bands .band-photo p { font-size: 16px; }
.page-bands .band-tan h2, .page-bands .band-photo .col h2 { color: #fff; }
.page-bands .band-photo .col h2 { text-align: center; }
.page-bands .cols-3 .col h2 { font-size: 1.35rem; text-align: center; color: var(--heading); }
.page-bands .band-photo .cols-3 .col h2 { font-size: clamp(1.4rem, 3vw, 1.9rem); color: #fff; }
.page-bands .band:not(.band-photo) .cols-3 .col p:not(.label) { text-align: center; }
.page-bands .col .figs { grid-template-columns: 1fr; }
.page-bands .col .figs img { aspect-ratio: auto; }
.page-bands .cols-3 .col > figure img { width: 100%; aspect-ratio: 3 / 2; object-fit: cover; }

/* Service times, events, news on the home page */
.services { margin: 0 auto; max-width: 680px; text-align: center; }
.services div { padding: 0.9rem 0; border-bottom: 1px solid var(--line); }
.services div:last-child { border: 0; }
.services dt { font: 400 1.15rem var(--display); color: var(--heading); } .services dd { margin: 0; }
.band .events, .band .cards { text-align: left; margin-bottom: 2rem; }
.empty { color: var(--muted); font-style: italic; }
.meta { color: var(--muted); font: 400 11px/1.6 var(--menu); letter-spacing: 1px; text-transform: uppercase; margin: 0 0 0.4rem; }

.section { padding: 2rem 0 3rem; }
.section-head { display: flex; align-items: baseline; justify-content: space-between; gap: 1rem; border-bottom: 1px solid var(--line); margin-bottom: 1.25rem; }
.back { margin-top: 2.5rem; font: 400 11px var(--menu); letter-spacing: 1px; text-transform: uppercase; }

.cards { display: grid; grid-template-columns: repeat(auto-fill, minmax(16rem, 1fr)); gap: 1.5rem; }
.card { display: block; background: var(--paper); border: 1px solid #e6e6e6; overflow: hidden; color: inherit; text-decoration: none; transition: box-shadow 0.15s; }
.card:hover { box-shadow: 0 4px 16px rgb(0 0 0 / 0.08); text-decoration: none; }
.card img { width: 100%; aspect-ratio: 3 / 2; object-fit: cover; }
.card.picture-only { display: flex; flex-direction: column; }
.card.picture-only img { flex: 1 1 auto; aspect-ratio: 1 / 1; min-height: 0; object-position: top; }
.card div { padding: 1rem 1.2rem; } .card h3 { margin-bottom: 0.3em; } .card p:last-child { margin: 0; font-size: 16px; line-height: 1.6; }

.events { list-style: none; margin: 0; padding: 0; }
.event { display: flex; gap: 1.25rem; padding: 1.1rem 0; border-bottom: 1px solid var(--line); }
.event:last-child { border: 0; }
.event .date { flex: none; width: 4.2rem; height: 4.2rem; background: var(--gold); color: #fff; text-align: center; display: flex; flex-direction: column; justify-content: center; line-height: 1.1; }
.event .date span { font: 400 10px var(--menu); text-transform: uppercase; letter-spacing: 1px; } .event .date strong { font: 400 1.6rem var(--display); }
.event h3 { margin-bottom: 0.15em; } .event .prose p { margin: 0.4em 0 0; }

.prose h2 { margin-top: 1.5em; text-align: center; } .prose .lead { margin-bottom: 1.5rem; }
.prose ul { padding-left: 1.25rem; }
article.prose > p:not(.label):not(.back) { text-align: justify; }
article.prose .label { text-align: center; }
article.prose blockquote { margin: 2rem 0; text-align: center; }

.photos { display: grid; grid-template-columns: repeat(auto-fill, minmax(12rem, 1fr)); gap: 6px; }
.photos img { width: 100%; aspect-ratio: 1; object-fit: cover; transition: opacity 0.15s; }
.photos a:hover img { opacity: 0.85; }
dialog#lightbox { border: 0; padding: 0; background: transparent; max-width: 96vw; max-height: 96vh; color: #fff; text-align: center; }
dialog#lightbox::backdrop { background: rgb(0 0 0 / 0.88); }
dialog#lightbox img { max-width: 96vw; max-height: 82vh; margin: 0 auto; }
dialog#lightbox p { margin: 0.6rem 0; min-height: 1.5em; }
dialog#lightbox button { font: 600 11px var(--ui); letter-spacing: 2px; text-transform: uppercase; background: var(--gold); color: #fff; border: 0; padding: 10px 25px; cursor: pointer; }

.docs { list-style: none; margin: 0 0 2.5rem; padding: 0; }
.docs a { display: flex; align-items: center; gap: 1rem; padding: 0.85rem 1rem; background: var(--paper); border: 1px solid #e6e6e6; margin-bottom: 0.5rem; text-decoration: none; }
.docs a:hover { border-color: var(--gold); }
.docs .pdf { flex: none; font: 600 10px var(--ui); letter-spacing: 1px; background: var(--gold); color: #fff; padding: 0.5rem 0.45rem; }
.docs strong { display: block; color: var(--ink); } .docs small { color: var(--muted); }

.group { margin: 2.5rem 0 1rem; text-align: center; } .group:first-child { margin-top: 0; }

/* Footer: gold "Find us" band with map, then a pale strip */
.find-us { background: var(--mustard); color: #fff; padding: 70px 0; }
.find-us-inner { display: grid; gap: 2rem; align-items: center; }
@media (min-width: 760px) { .find-us-inner { grid-template-columns: 1fr 1fr; } }
.find-us h2 { color: #fff; }
.find-us p { font-size: 16px; line-height: 1.8; margin-bottom: 0.6em; text-align: justify; }
.find-us a { color: #fff; text-decoration: underline; }
.map { width: 100%; aspect-ratio: 3 / 2; border: 0; background: #e8e3c4; }
.site-footer { background: var(--pale); padding: 2rem 0; font: 400 11px var(--menu); letter-spacing: 1px; text-transform: uppercase; color: var(--muted); }
.site-footer .wrap { display: flex; flex-wrap: wrap; gap: 0.6rem 1.6rem; justify-content: center; }
.site-footer a { color: var(--muted); } .site-footer a:hover { color: var(--gold); }

/* Enquiry forms */
.enquiry { background: var(--pale); border: 1px solid #e6e6e6; padding: 1.5rem; margin: 1.75rem 0; font-size: 16px; text-align: left; }
.enquiry p { margin: 0 0 1rem; } .enquiry label { display: block; font: 400 11px var(--menu); letter-spacing: 1px; text-transform: uppercase; color: var(--muted); margin-bottom: 0.3rem; }
.enquiry input, .enquiry textarea { font: inherit; width: 100%; padding: 8px; min-height: 35px; border: 1px solid var(--line); background: #fff; color: inherit; }
.enquiry input:focus, .enquiry textarea:focus { border-color: var(--gold); outline: none; }
.enquiry button { font: 600 11px var(--ui); letter-spacing: 2px; text-transform: uppercase; background: var(--gold); color: #fff; border: 0; padding: 12px 28px; cursor: pointer; }
.enquiry.sent { background: #f6f1df; border-color: #e7d8a6; } .form-errors { background: #fbeae7; border: 1px solid #e0a59c; padding: 0.6rem 1rem; margin-bottom: 1rem; } .form-errors p { margin: 0.15rem 0; }
.hp { position: absolute; left: -9999px; }

.pager { display: flex; justify-content: space-between; align-items: center; gap: 1rem; margin-top: 2.5rem; padding-top: 1.25rem; border-top: 1px solid var(--line); font: 400 11px var(--menu); letter-spacing: 1px; text-transform: uppercase; } .pager span { color: var(--muted); }

/* A PDF attached to a news post: shown inline on larger screens, a button everywhere (phones can't show PDFs in a page). */
.pdf-embed { margin: 2rem 0; text-align: center; }
.pdf-embed iframe { display: none; width: 100%; height: 85vh; border: 1px solid #ddd; background: #f4f4f4; margin-bottom: 1rem; }
@media (min-width: 760px) and (hover: hover) { .pdf-embed iframe { display: block; } }

/* Repeating events and the past events list */
.event .repeats { margin: 0.1em 0 0; font: 400 10px var(--menu); letter-spacing: 1px; text-transform: uppercase; color: var(--gold); }
.events.past .event .date { background: var(--muted); }
.section .more { margin-top: 2rem; }
