/* ------------------------------------------------------------
   Immaculate Conception Preparatory School
   Colours: Marian blue and white, with gold for the stars in
   the motto (Ad astra per aspera).
   ------------------------------------------------------------ */

:root {
  --ink: #14234a;
  --marian: #2346a6;
  --marian-deep: #18347f;
  --sky: #edf3fc;
  --paper: #ffffff;
  --gold: #e3b23c;
  --gold-soft: #fff6df;
  --muted: #55607b;
  --line: #d4ddee;

  --serif: "Young Serif", Georgia, "Times New Roman", serif;
  --sans: "Figtree", system-ui, -apple-system, "Segoe UI", sans-serif;

  --wrap: 72rem;
  --gutter: clamp(1.25rem, 4vw, 2.5rem);
  --section: clamp(3.5rem, 8vw, 6.5rem);
}

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

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

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 1.0625rem;
  line-height: 1.65;
}

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

a { color: var(--marian); text-underline-offset: .18em; text-decoration-thickness: 1px; }
a:hover { color: var(--marian-deep); text-decoration-thickness: 2px; }

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

h1, h2 {
  font-family: var(--serif);
  font-weight: 400;
  line-height: 1.12;
  letter-spacing: -.01em;
  margin: 0 0 .5em;
  text-wrap: balance;
}
h1 { font-size: clamp(2.5rem, 5.4vw, 4.25rem); }
h2 { font-size: clamp(1.85rem, 3.4vw, 2.6rem); }
h3 { font-size: 1.1875rem; font-weight: 600; line-height: 1.3; margin: 0 0 .4em; }
p { margin: 0 0 1em; }

.wrap { width: min(100% - 2 * var(--gutter), var(--wrap)); margin-inline: auto; }
.narrow > * { max-width: 44rem; }
.lede { font-size: 1.25rem; line-height: 1.55; color: var(--muted); max-width: 38rem; }
.muted { color: var(--muted); }

.skip-link {
  position: absolute; left: 1rem; top: -4rem; z-index: 10;
  background: var(--ink); color: #fff; padding: .6rem 1rem; border-radius: 4px;
}
.skip-link:focus { top: 1rem; }

/* Buttons ------------------------------------------------- */
.btn {
  display: inline-block;
  padding: .8rem 1.35rem;
  border-radius: 6px;
  border: 2px solid var(--marian);
  font: 600 1rem/1.2 var(--sans);
  text-decoration: none;
  cursor: pointer;
}
.btn--primary { background: var(--marian); color: #fff; }
.btn--primary:hover { background: var(--marian-deep); border-color: var(--marian-deep); color: #fff; }
.btn--ghost { background: transparent; color: var(--marian); }
.btn--ghost:hover { background: var(--sky); color: var(--marian-deep); }
.btn--light { background: #fff; color: var(--marian-deep); border-color: #fff; }
.btn--light:hover { background: var(--gold-soft); border-color: var(--gold-soft); color: var(--marian-deep); }
.btn[aria-disabled="true"] { opacity: .55; cursor: not-allowed; }
.actions { display: flex; flex-wrap: wrap; gap: .75rem; margin-top: 1.75rem; }
.text-link { font-weight: 600; }

/* Announcement bar and header ----------------------------- */
.notice { background: var(--marian-deep); color: #fff; font-size: .9375rem; }
.notice p { margin-block: 0; padding: .55rem 0; text-align: center; }
.notice a { color: #fff; font-weight: 600; }
.notice a:hover { color: var(--gold-soft); }

.site-header { border-bottom: 1px solid var(--line); background: var(--paper); position: relative; z-index: 5; }
.site-header__inner { display: flex; align-items: center; justify-content: space-between; gap: 1.5rem; padding-block: .9rem; }
.brand { display: flex; align-items: center; gap: .75rem; color: var(--ink); text-decoration: none; font-family: var(--serif); font-size: 1.0625rem; line-height: 1.2; }
.brand img { width: 52px; height: 52px; object-fit: contain; }
.brand:hover { color: var(--ink); }

.site-nav { display: flex; align-items: center; gap: 1.25rem; }
.site-nav ul { display: flex; gap: 1.1rem; list-style: none; margin: 0; padding: 0; }
.site-nav ul a { color: var(--ink); text-decoration: none; font-weight: 500; padding-block: .35rem; border-bottom: 2px solid transparent; }
.site-nav ul a:hover { color: var(--marian); border-bottom-color: var(--line); }
.site-nav ul a[aria-current="page"] { color: var(--marian); border-bottom-color: var(--gold); }
.site-nav .btn { padding: .6rem 1.1rem; }

.nav-toggle {
  display: none;
  font: 600 1rem var(--sans); color: var(--ink);
  background: none; border: 2px solid var(--line); border-radius: 6px; padding: .5rem .9rem; cursor: pointer;
}

@media (max-width: 64rem) {
  .nav-toggle { display: block; }
  .site-nav {
    display: none;
    position: absolute; left: 0; right: 0; top: 100%;
    flex-direction: column; align-items: stretch; gap: 1rem;
    background: var(--paper); border-bottom: 1px solid var(--line);
    padding: 1rem var(--gutter) 1.5rem;
  }
  .site-nav.is-open { display: flex; }
  .site-nav ul { flex-direction: column; gap: 0; }
  .site-nav ul a { display: block; padding: .75rem 0; border-bottom: 1px solid var(--line); }
  .site-nav ul a[aria-current="page"] { border-bottom-color: var(--line); box-shadow: inset 3px 0 0 var(--gold); padding-left: .75rem; }
  .site-nav .btn { text-align: center; }
}

/* Arched portrait (the signature element) ----------------- */
.arch { width: 100%; height: auto; overflow: visible; display: block; }
.arch__frame { fill: none; stroke: var(--gold); stroke-width: .6; stroke-dasharray: .6 2.2; stroke-linecap: round; }
.arch__motto { font-family: var(--serif); font-size: 6.2px; letter-spacing: .12em; fill: var(--marian-deep); }
.arch__star { fill: var(--gold); transform-box: fill-box; transform-origin: center; }

@media (prefers-reduced-motion: no-preference) {
  .arch__star { animation: star-in .7s cubic-bezier(.2,.8,.2,1.2) both; animation-delay: calc(.35s + var(--i) * .16s); }
  @keyframes star-in { from { opacity: 0; scale: .2; } to { opacity: 1; scale: 1; } }
}

.star-mark { width: 1rem; height: 1rem; fill: var(--gold); flex: none; }

/* Home: hero ---------------------------------------------- */
.hero { padding-block: clamp(2.5rem, 6vw, 5rem) var(--section); }
.hero__grid { display: grid; grid-template-columns: 1.15fr .85fr; gap: clamp(2rem, 6vw, 5rem); align-items: center; }
.hero h1 { max-width: 12ch; }
.hero__figure { margin: 0; max-width: 26rem; justify-self: end; width: 100%; }
.hero__figure blockquote { margin: 1.25rem 0 0; padding-left: 1rem; border-left: 3px solid var(--gold); }
.hero__figure blockquote p { font-family: var(--serif); font-size: 1.125rem; line-height: 1.45; margin-bottom: .5rem; }
.hero__figure cite { font-style: normal; font-size: .9375rem; color: var(--muted); }
.hero__figure cite strong { color: var(--ink); font-weight: 600; }

@media (max-width: 52rem) {
  .hero__grid { grid-template-columns: 1fr; }
  .hero__figure { justify-self: start; max-width: 22rem; }
}

/* Sections ------------------------------------------------ */
.section { padding-block: var(--section); }
.section--sky { background: var(--sky); }
.section__intro { max-width: 40rem; margin-bottom: clamp(2rem, 4vw, 3rem); }

.split { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(1.5rem, 6vw, 5rem); align-items: center; }
.split--top { align-items: start; }
.split--reverse > :first-child { order: 2; }
@media (max-width: 52rem) {
  .split { grid-template-columns: 1fr; }
  .split--reverse > :first-child { order: 0; }
}

.arched-photo { border-radius: 999px 999px 6px 6px; aspect-ratio: 4 / 5; object-fit: cover; width: 100%; max-width: 26rem; background: var(--line); }

/* Reasons grid */
.reasons { display: grid; grid-template-columns: repeat(3, 1fr); gap: 2.25rem 2.5rem; list-style: none; margin: 0; padding: 0; }
.reasons li { border-top: 1px solid var(--line); padding-top: 1.25rem; }
.reasons h3 { display: flex; gap: .55rem; align-items: center; }
.reasons p { color: var(--muted); margin: 0; }
@media (max-width: 60rem) { .reasons { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 36rem) { .reasons { grid-template-columns: 1fr; } }

/* Starred list */
.star-list { list-style: none; padding: 0; margin: 0 0 1.5rem; display: grid; gap: .6rem; }
.star-list li { display: flex; gap: .6rem; align-items: baseline; }
.star-list .star-mark { width: .8rem; height: .8rem; transform: translateY(.1rem); }
.star-list--cols { grid-template-columns: repeat(2, minmax(0, 1fr)); column-gap: 1.5rem; }
@media (max-width: 30rem) { .star-list--cols { grid-template-columns: 1fr; } }

/* News */
.news-head { display: flex; justify-content: space-between; align-items: end; gap: 1rem; flex-wrap: wrap; margin-bottom: 2rem; }
.news-head h2 { margin: 0; }
.news-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 2rem; list-style: none; margin: 0; padding: 0; }
@media (max-width: 56rem) { .news-grid { grid-template-columns: 1fr 1fr; } }
@media (max-width: 36rem) { .news-grid { grid-template-columns: 1fr; } }
.news-item img { aspect-ratio: 3 / 2; object-fit: cover; width: 100%; border-radius: 6px; background: var(--line); margin-bottom: 1rem; }
.news-item p { font-size: .9375rem; color: var(--muted); margin: 0 0 .3rem; }
.news-item h3 { font-family: var(--serif); font-weight: 400; font-size: 1.375rem; line-height: 1.25; }
.news-item h3 a { color: var(--ink); text-decoration: none; }
.news-item h3 a:hover { color: var(--marian); text-decoration: underline; }

/* Call to action band */
.cta { background: var(--marian-deep); color: #fff; padding-block: var(--section); }
.cta__inner { display: grid; grid-template-columns: 1.4fr auto; gap: 2rem; align-items: center; }
.cta h2 { color: #fff; }
.cta p { color: #d8e2f7; max-width: 36rem; margin: 0; }
@media (max-width: 48rem) { .cta__inner { grid-template-columns: 1fr; } }

/* Inner pages --------------------------------------------- */
.page-head { background: var(--sky); padding-block: clamp(2.5rem, 6vw, 4.5rem); border-bottom: 1px solid var(--line); }
.page-head h1 { font-size: clamp(2.25rem, 4.6vw, 3.5rem); max-width: 20ch; }
.page-head .lede { margin: 0; }
.page-body > section { padding-block: clamp(2.75rem, 6vw, 4.5rem); }
.page-body > section + section { border-top: 1px solid var(--line); }
.prose { max-width: 42rem; }
.wrap.prose { max-width: none; }
.wrap.prose > * { max-width: 42rem; }
.prose h2 { font-size: clamp(1.6rem, 3vw, 2.1rem); }
.prose h3 { margin-top: 1.5em; }
.prose ul, .prose ol { padding-left: 1.25rem; }
.prose li { margin-bottom: .35em; }

.pullquote { margin: 0; padding: 1.5rem 0 1.5rem 1.5rem; border-left: 3px solid var(--gold); }
.pullquote p { font-family: var(--serif); font-size: clamp(1.35rem, 2.6vw, 1.75rem); line-height: 1.35; }
.pullquote cite { font-style: normal; color: var(--muted); }

.post-meta { color: var(--muted); margin-bottom: .5rem; }
.post-body { padding-block: clamp(2.5rem, 5vw, 4rem); }
.post-image { border-radius: 6px; margin-bottom: 2rem; width: 100%; }

.news-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 2.5rem; }
.news-list .news-item { display: grid; grid-template-columns: minmax(0, 18rem) 1fr; gap: 1.75rem; align-items: start; }
.news-list .news-item img { margin: 0; }
@media (max-width: 40rem) { .news-list .news-item { grid-template-columns: 1fr; } }

/* Contact details */
.details { display: grid; gap: 1.25rem; margin: 0; }
.details dt { font-weight: 600; }
.details dd { margin: 0; }
.map { width: 100%; aspect-ratio: 4 / 3; border: 0; border-radius: 6px; background: var(--line); }

/* Forms */
.form { display: grid; grid-template-columns: 1fr 1fr; gap: 1.1rem 1.25rem; max-width: 44rem; }
.form .full { grid-column: 1 / -1; }
.form label { display: block; font-weight: 600; margin-bottom: .35rem; }
.form .hint { font-weight: 400; color: var(--muted); font-size: .9375rem; }
.form input, .form select, .form textarea {
  width: 100%; font: inherit; color: var(--ink);
  padding: .7rem .8rem; border: 1.5px solid #b9c5dc; border-radius: 6px; background: #fff;
}
.form input:focus, .form select:focus, .form textarea:focus { outline: 3px solid var(--gold); outline-offset: 1px; border-color: var(--marian); }
.form textarea { min-height: 8rem; resize: vertical; }
.form .consent { display: flex; gap: .6rem; align-items: start; font-weight: 400; }
.form .consent input { width: auto; margin-top: .35rem; }
.form .honeypot { position: absolute; left: -9999px; }
@media (max-width: 36rem) { .form { grid-template-columns: 1fr; } }

/* Placeholder notes for unfinished content */
.todo {
  border: 2px dashed var(--gold); background: var(--gold-soft);
  padding: .9rem 1.1rem; border-radius: 6px; margin: 1.25rem 0; font-size: .9375rem; max-width: 42rem;
}

/* Footer ---------------------------------------------------- */
.site-footer { background: var(--sky); border-top: 1px solid var(--line); padding-top: clamp(3rem, 6vw, 4.5rem); font-size: .9688rem; }
.site-footer__grid { display: grid; grid-template-columns: 1.4fr 1fr 1fr 1.3fr; gap: 2rem; }
.site-footer img { width: 64px; height: 64px; object-fit: contain; margin-bottom: .9rem; }
.site-footer__name { font-family: var(--serif); font-size: 1.125rem; margin-bottom: .4rem; }
.site-footer h2 { font-family: var(--sans); font-size: 1rem; font-weight: 600; margin-bottom: .8rem; letter-spacing: 0; }
.site-footer ul { list-style: none; margin: 0; padding: 0; display: grid; gap: .45rem; }
.site-footer address { font-style: normal; }
.site-footer address p { margin-bottom: .45rem; }
.site-footer__base { display: flex; justify-content: space-between; flex-wrap: wrap; gap: .5rem 1.5rem; border-top: 1px solid var(--line); margin-top: 2.5rem; padding-block: 1.25rem; color: var(--muted); font-size: .875rem; }
.site-footer__base p { margin: 0; }
@media (max-width: 56rem) { .site-footer__grid { grid-template-columns: 1fr 1fr; } }
@media (max-width: 34rem) { .site-footer__grid { grid-template-columns: 1fr; } }

/* ---------- Additions for full page content ---------- */

.section-title { margin-bottom: 1.5rem; }

/* Values, levels, activities: reuse .reasons, allow 2 columns */
.reasons--two { grid-template-columns: repeat(2, 1fr); }
@media (max-width: 36rem) { .reasons--two { grid-template-columns: 1fr; } }
.reasons .meta { display: block; font-size: .9375rem; color: var(--marian); font-weight: 600; margin-bottom: .35rem; }

/* Leadership */
.people { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(10.5rem, 1fr)); gap: 1.5rem 1.75rem; }
.people li { border-top: 3px solid var(--gold); padding-top: .9rem; }
.people strong { display: block; font-family: var(--serif); font-weight: 400; font-size: 1.25rem; line-height: 1.25; }
.people span { color: var(--muted); }

/* Term activities */
.terms { display: grid; grid-template-columns: repeat(3, 1fr); gap: 2rem; }
.terms h3 { font-family: var(--serif); font-weight: 400; font-size: 1.5rem; padding-bottom: .5rem; border-bottom: 1px solid var(--line); }
.terms ul { padding-left: 1.1rem; margin: 0; }
.terms li { margin-bottom: .35rem; }
@media (max-width: 52rem) { .terms { grid-template-columns: 1fr; } }

/* Houses */
.houses { display: flex; flex-wrap: wrap; gap: .75rem; list-style: none; padding: 0; margin: 1.5rem 0 0; }
.houses li { font-family: var(--serif); font-size: 1.375rem; padding: .5rem 1.4rem; border: 1.5px solid var(--marian); border-radius: 999px 999px 6px 6px; color: var(--marian-deep); }

/* Key dates: a real sequence, so numbered */
.steps { list-style: none; counter-reset: step; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(4, 1fr); gap: 1.5rem; }
.steps li { counter-increment: step; border-top: 3px solid var(--marian); padding-top: .9rem; }
.steps li::before { content: counter(step); display: block; font-weight: 600; color: var(--marian); font-size: .9375rem; margin-bottom: .25rem; }
.steps strong { display: block; font-family: var(--serif); font-weight: 400; font-size: 1.5rem; line-height: 1.2; }
.steps span { color: var(--muted); }
@media (max-width: 48rem) { .steps { grid-template-columns: 1fr 1fr; } }

/* Downloads and resources */
.downloads { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(15rem, 1fr)); gap: 1rem 2rem; }
.downloads li { border-top: 1px solid var(--line); padding-top: .9rem; }
.downloads h3 { margin-bottom: .2rem; }
.downloads p { margin: 0 0 .3rem; color: var(--muted); font-size: .9688rem; }

/* FAQ */
.faq { max-width: 44rem; border-top: 1px solid var(--line); }
.faq details { border-bottom: 1px solid var(--line); }
.faq summary { cursor: pointer; padding: 1.1rem 2rem 1.1rem 0; font-weight: 600; font-size: 1.125rem; list-style: none; position: relative; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; position: absolute; right: .25rem; top: .9rem; font-size: 1.5rem; font-weight: 400; color: var(--marian); }
.faq details[open] summary::after { content: "\2212"; }
.faq details p { margin: 0 0 1.2rem; color: var(--muted); max-width: 38rem; }

/* Events */
.events { list-style: none; margin: 0; padding: 0; display: grid; gap: 0; max-width: 48rem; border-top: 1px solid var(--line); }
.events li { display: grid; grid-template-columns: 5rem 1fr; gap: 1.25rem; padding: 1.1rem 0; border-bottom: 1px solid var(--line); align-items: start; }
.events time { font-family: var(--serif); font-size: 1.125rem; line-height: 1.1; color: var(--marian-deep); }
.events time b { display: block; font-weight: 400; font-size: 2rem; }
.events h3 { margin-bottom: .2rem; }
.events p { margin: 0; color: var(--muted); }

/* Scripture */
.scripture { margin: 2rem 0 0; padding: 0; }
.scripture p { font-family: var(--serif); font-size: clamp(1.5rem, 3vw, 2rem); line-height: 1.3; margin-bottom: .4rem; color: var(--marian-deep); }
.scripture cite { font-style: normal; color: var(--muted); }

.news-item .summary { color: var(--ink); font-size: 1rem; }

.news-list .news-item.no-image { display: block; }
@media (min-width: 40rem) { .news-list .news-item.no-image { padding-left: 19.75rem; } }
.prose > h3:first-child { margin-top: 0; }

/* Photos from the old site */
.photo { width: 100%; border-radius: 6px; background: var(--line); }
.people img { width: 100%; aspect-ratio: 4 / 5; object-fit: cover; object-position: top; border-radius: 999px 999px 6px 6px; margin-bottom: .9rem; background: var(--line); }
.people li:has(img) { border-top: 0; padding-top: 0; }
.gallery { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(4, 1fr); gap: .75rem; }
.gallery a { display: block; border-radius: 6px; overflow: hidden; }
.gallery img { width: 100%; aspect-ratio: 1; object-fit: cover; transition: transform .3s ease; }
.gallery a:hover img { transform: scale(1.03); }
@media (prefers-reduced-motion: reduce) { .gallery img { transition: none; } }
@media (max-width: 48rem) { .gallery { grid-template-columns: repeat(2, 1fr); } }
