
/*
  Richmond Montessori School - site styles
  Matches the school's final flyer design ("1B"):
  deep green band, ivory page, logo in a circle over the band's edge,
  Cormorant Garamond headings, Inter body text, thin hairline rules.

  To change a colour everywhere, change it once in :root below.
*/

:root {
  --green: #2F5A4B;   /* band, buttons, labels */
  --ivory: #F5F2EC;   /* page background, text on green */
  --ink: #1C241F;     /* main text */
  --muted: #5E655F;   /* secondary text */
  --rule: #D8D2C6;    /* hairline dividers and box borders */
  --white: #FFFFFF;   /* small boxes */

  --serif: "Cormorant Garamond", Garamond, "Times New Roman", serif;
  --sans: "Inter", system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif;

  --radius: 4px;
  --seal: 128px;      /* size of the logo circle */
}

/* ---------- Base ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--ivory);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 1rem;
  font-weight: 400;
  line-height: 1.6;
  font-variant-numeric: lining-nums;
  overflow-wrap: break-word;
}
img { max-width: 100%; height: auto; display: block; }
a { color: var(--green); text-underline-offset: 3px; }
a:hover { color: var(--ink); }
p { margin: 0 0 1rem; }

h1, h2, h3 {
  font-family: var(--serif);
  font-weight: 600;
  line-height: 1.1;
  font-variant-numeric: lining-nums;
  margin: 0 0 0.5em;
  color: var(--ink);
}
h1 { font-size: clamp(2.5rem, 6.4vw, 4.25rem); letter-spacing: -0.005em; }
h2 { font-size: clamp(1.9rem, 3.6vw, 2.5rem); }
h3 { font-size: 1.55rem; }

:focus-visible { outline: 2px solid var(--green); outline-offset: 3px; }
.on-green :focus-visible { outline-color: var(--ivory); }

.sr-only {
  position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}
.skip-link {
  position: absolute; left: 1rem; top: -4rem; z-index: 100;
  background: var(--ivory); color: var(--ink); padding: 0.75rem 1rem;
  border: 1px solid var(--green); border-radius: var(--radius);
}
.skip-link:focus { top: 1rem; }

.wrap { width: 100%; max-width: 1120px; margin: 0 auto; padding: 0 1.5rem; }
.narrow { max-width: 680px; }
.center { text-align: center; }

/* Small uppercase letter-spaced label, as on the flyer */
.label {
  font-family: var(--sans);
  font-weight: 600;
  font-size: 0.75rem;
  letter-spacing: 3px;
  text-transform: uppercase;
  color: var(--green);
  margin: 0 0 1rem;
}
.tagline {
  font-family: var(--serif);
  font-style: italic;
  font-weight: 500;
  font-size: clamp(1.25rem, 2.4vw, 1.6rem);
  line-height: 1.35;
}
.muted { color: var(--muted); }
.small { font-size: 0.875rem; }

.rule { border: 0; border-top: 1px solid var(--rule); margin: 0 auto; max-width: 1072px; }

/* ---------- Top bar (green, above the band) ---------- */
.topbar { background: var(--green); color: var(--ivory); }
.topbar .wrap {
  display: flex; flex-direction: column; align-items: center; gap: 0.6rem;
  padding-top: 1.1rem; padding-bottom: 0.4rem;
}
.brand {
  color: var(--ivory); text-decoration: none;
  font-family: var(--serif); font-weight: 600; font-size: 1.3rem; line-height: 1.2;
}
.brand:hover { color: var(--ivory); text-decoration: underline; }
.nav ul { list-style: none; margin: 0; padding: 0; display: flex; gap: 0.25rem 1.5rem; flex-wrap: wrap; justify-content: center; }
.nav a {
  display: inline-block; padding: 0.55rem 0.1rem;
  color: var(--ivory); text-decoration: none;
  font-size: 0.75rem; font-weight: 600; letter-spacing: 2px; text-transform: uppercase;
  border-bottom: 1px solid transparent;
}
.nav a:hover, .nav a[aria-current="page"] { color: var(--ivory); border-bottom-color: var(--ivory); }
@media (min-width: 760px) {
  .topbar .wrap { flex-direction: row; justify-content: space-between; padding-top: 1.25rem; }
  .topbar-min .wrap { justify-content: center; }
}

/* ---------- Green band (page title area) ---------- */
.band {
  background: var(--green); color: var(--ivory); text-align: center;
  padding: 3rem 0 calc(var(--seal) / 2 + 2.25rem);
}
.band h1, .band h2 { color: var(--ivory); max-width: 15em; margin-left: auto; margin-right: auto; }
.band .label { color: var(--ivory); }
.band .tagline { margin: 0 auto; max-width: 32em; }
.band-home { padding-top: 3.75rem; --seal: 168px; padding-bottom: calc(168px / 2 + 3rem); }
.band-home h1 { font-size: clamp(2.75rem, 7vw, 4.75rem); }

/* ---------- Logo circle over the band's bottom edge ---------- */
.seal {
  position: relative; z-index: 1;
  width: var(--seal); height: var(--seal);
  margin: calc(var(--seal) / -2) auto 0;
  border-radius: 50%;
  background: var(--white);
  border: 1.5px solid var(--green);
  display: flex; align-items: center; justify-content: center;
}
.seal img { width: 66%; height: auto; }
.seal-home { --seal: 168px; }

/* ---------- Sections ---------- */
.section { padding: 2.75rem 0; }
.section-tight { padding: 2rem 0; }
.section > .wrap > h2:first-child, .section .label + h2 { margin-top: 0; }

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center;
  min-height: 48px; padding: 0.8rem 1.75rem;
  border: 1.5px solid var(--green); border-radius: var(--radius);
  background: var(--green); color: var(--ivory);
  font-family: var(--sans); font-size: 0.8rem; font-weight: 600;
  letter-spacing: 2px; text-transform: uppercase; text-decoration: none; text-align: center;
}
.btn:hover { background: var(--ink); border-color: var(--ink); color: var(--ivory); }
.btn-outline { background: transparent; color: var(--green); }
.btn-outline:hover { background: var(--green); border-color: var(--green); color: var(--ivory); }
.btn-row { display: flex; flex-wrap: wrap; gap: 0.75rem; justify-content: center; }
.btn-row .btn { min-width: 12rem; }
@media (max-width: 420px) { .btn-row .btn { width: 100%; } }

/* ---------- Campus cards (home) ---------- */
.campuses { display: grid; gap: 1rem; grid-template-columns: 1fr; margin-top: 2rem; text-align: center; }
@media (min-width: 640px) { .campuses { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1000px) { .campuses { grid-template-columns: repeat(4, 1fr); } }
.campus {
  background: var(--white); border: 1px solid var(--rule); border-radius: var(--radius);
  padding: 1.6rem 1.25rem 1.4rem; display: flex; flex-direction: column; align-items: center;
}
.campus h3 { margin-bottom: 0.35rem; }
.campus .ages { color: var(--muted); font-size: 0.875rem; margin-bottom: 0.75rem; }
.campus address { font-style: normal; font-size: 0.9rem; line-height: 1.5; margin-bottom: 1.1rem; }
.text-link {
  margin-top: auto; color: var(--green);
  font-size: 0.75rem; font-weight: 600; letter-spacing: 2px; text-transform: uppercase;
  text-decoration: underline; text-decoration-thickness: 1px; text-underline-offset: 5px;
  padding: 0.4rem 0;
}
.tag {
  display: inline-block; font-size: 0.68rem; font-weight: 600; letter-spacing: 2px; text-transform: uppercase;
  color: var(--green); border: 1px solid var(--green); border-radius: var(--radius);
  padding: 0.15rem 0.5rem; margin-bottom: 0.7rem;
}

/* ---------- Footer ---------- */
.site-footer { border-top: 1px solid var(--rule); padding: 2.5rem 0 2rem; text-align: center; color: var(--muted); font-size: 0.9rem; }
.site-footer .footer-name { font-family: var(--serif); font-weight: 600; font-size: 1.35rem; color: var(--ink); margin-bottom: 0.4rem; }
.site-footer p { margin-bottom: 0.35rem; }
.site-footer a { color: var(--green); }
.site-footer .footer-base { margin-top: 1rem; font-size: 0.8rem; }

/* ---------- Book a Tour: campus picker ---------- */
.picker { display: none; gap: 0.6rem; grid-template-columns: repeat(2, 1fr); margin: 1.5rem auto 0; max-width: 960px; }
.picker-ready .picker { display: grid; }
@media (min-width: 860px) { .picker { grid-template-columns: repeat(4, 1fr); } }
.picker button {
  font: inherit; color: var(--ink); background: var(--white); cursor: pointer; text-align: center;
  border: 1px solid var(--rule); border-radius: var(--radius); padding: 0.9rem 0.75rem; min-height: 48px;
}
.picker button:hover { border-color: var(--green); }
.picker button[aria-pressed="true"] { background: var(--green); border-color: var(--green); color: var(--ivory); }
.picker button[aria-pressed="true"] .p-ages { color: var(--ivory); }
.picker .p-name { display: block; font-family: var(--serif); font-size: 1.3rem; font-weight: 600; line-height: 1.15; }
.picker .p-ages { display: block; font-size: 0.78rem; color: var(--muted); margin-top: 0.2rem; }

.campus-panel { padding: 2.5rem 0 0; text-align: center; max-width: 860px; margin: 0 auto; }
.campus-panel + .campus-panel { border-top: 1px solid var(--rule); margin-top: 2.5rem; }
.picker-ready .campus-panel + .campus-panel { border-top: 0; margin-top: 0; }
.campus-panel h2 { margin-bottom: 0.4rem; }
.campus-panel h2:focus { outline: none; }
.campus-meta { color: var(--muted); margin-bottom: 1.5rem; }
.campus-meta p, .campus-meta address { margin: 0 0 0.2rem; font-style: normal; }

/* ---------- Embeds (Cal.com, Google Forms) and placeholders ---------- */
.embed { background: var(--white); border: 1px solid var(--rule); border-radius: var(--radius); overflow: hidden; }
.embed-frame { display: block; width: 100%; height: 760px; border: 0; }
.embed-ph { padding: clamp(2rem, 6vw, 3.25rem) 1.5rem; text-align: center; }
.embed-ph p { margin: 0 auto; max-width: 30rem; }
.embed-ph .big { font-family: var(--serif); font-size: clamp(1.5rem, 3.4vw, 1.9rem); font-weight: 600; line-height: 1.2; margin-bottom: 0.5rem; }
.notice {
  background: var(--white); border: 1px solid var(--rule); border-top: 3px solid var(--green);
  border-radius: var(--radius); padding: 1.75rem 1.5rem; text-align: center;
  font-family: var(--serif); font-size: clamp(1.4rem, 3vw, 1.75rem); font-weight: 600; line-height: 1.3;
}

/* ---------- Family Circle (referral) ---------- */
.reward { display: grid; gap: 1rem; grid-template-columns: 1fr; max-width: 640px; margin: 0 auto; }
@media (min-width: 560px) { .reward { grid-template-columns: 1fr 1fr; } }
.reward div { background: var(--white); border: 1px solid var(--rule); border-radius: var(--radius); padding: 1.5rem 1.25rem; text-align: center; }
.reward .amount { display: block; font-family: var(--serif); font-weight: 600; font-size: 2.75rem; line-height: 1; color: var(--green); font-variant-numeric: lining-nums; margin-bottom: 0.4rem; }
.steps { list-style: none; margin: 1.5rem auto 0; padding: 0; display: grid; gap: 1.5rem; max-width: 960px; counter-reset: step; }
@media (min-width: 760px) { .steps { grid-template-columns: repeat(3, 1fr); } }
.steps li { counter-increment: step; text-align: center; }
.steps li::before {
  content: counter(step); display: block; font-family: var(--serif); font-weight: 600; font-size: 2rem;
  line-height: 1; color: var(--green); font-variant-numeric: lining-nums; margin-bottom: 0.5rem;
}
.steps strong { display: block; font-weight: 600; margin-bottom: 0.25rem; }
.steps span { color: var(--muted); font-size: 0.925rem; }
.eligibility { font-weight: 500; }

/* ---------- Long text (privacy, terms) ---------- */
.prose { max-width: 700px; margin: 0 auto; }
.prose h2 { font-size: 1.65rem; margin: 2rem 0 0.5rem; }
.prose h2:first-child { margin-top: 0; }
.prose ul { padding-left: 1.25rem; margin: 0 0 1rem; }
.prose li { margin-bottom: 0.35rem; }
.draft-flag {
  display: inline-block; border: 1px solid var(--ivory); color: var(--ivory); border-radius: var(--radius);
  font-size: 0.7rem; font-weight: 600; letter-spacing: 2px; text-transform: uppercase;
  padding: 0.25rem 0.6rem; margin-bottom: 1rem;
}

@media (prefers-reduced-motion: reduce) { * { scroll-behavior: auto !important; transition: none !important; } }
.mt { margin-top: 1.25rem; }

.seal .seal-svg{width:66%;height:auto;display:block;}

/* ---------- Forms (Apply, Refer) ---------- */
.form-card {
  background: var(--white); border: 1px solid var(--rule); border-radius: var(--radius);
  padding: clamp(1.5rem, 4vw, 2.5rem); max-width: 760px; margin: 0 auto; text-align: left;
}
.form-card fieldset { border: 0; padding: 0; margin: 0 0 2rem; }
.form-card fieldset:last-of-type { margin-bottom: 1.5rem; }
.form-card legend {
  font-family: var(--serif); font-weight: 600; font-size: 1.55rem; line-height: 1.2;
  color: var(--ink); padding: 0; margin-bottom: 1rem; width: 100%;
  border-bottom: 1px solid var(--rule); padding-bottom: 0.5rem;
}
.fields { display: grid; gap: 1rem 1.25rem; grid-template-columns: 1fr; }
@media (min-width: 620px) { .fields { grid-template-columns: 1fr 1fr; } .field-wide { grid-column: 1 / -1; } }
.field label, .field .field-label {
  display: block; font-size: 0.8rem; font-weight: 600; letter-spacing: 1px; text-transform: uppercase;
  color: var(--ink); margin-bottom: 0.35rem;
}
.field .opt { font-weight: 400; text-transform: none; letter-spacing: 0; color: var(--muted); }
.field input, .field select, .field textarea {
  width: 100%; font: inherit; font-size: 1rem; color: var(--ink); background: var(--ivory);
  border: 1px solid var(--rule); border-radius: var(--radius); padding: 0.7rem 0.8rem; min-height: 48px;
}
.field textarea { min-height: 110px; resize: vertical; }
.field select { appearance: none; -webkit-appearance: none; padding-right: 2.2rem;
  background-image: linear-gradient(45deg, transparent 50%, var(--green) 50%), linear-gradient(135deg, var(--green) 50%, transparent 50%);
  background-position: calc(100% - 18px) 50%, calc(100% - 12px) 50%; background-size: 6px 6px; background-repeat: no-repeat; }
.field input:focus, .field select:focus, .field textarea:focus { outline: 2px solid var(--green); outline-offset: 1px; border-color: var(--green); background: var(--white); }
.field .hint { font-size: 0.8rem; color: var(--muted); margin: 0.3rem 0 0; }
.field .err { display: none; font-size: 0.8rem; color: #9B2C1F; margin: 0.3rem 0 0; }
.field.invalid input, .field.invalid select, .field.invalid textarea { border-color: #9B2C1F; }
.field.invalid .err { display: block; }
.check { display: flex; gap: 0.7rem; align-items: flex-start; font-size: 0.925rem; }
.check input { width: 20px; height: 20px; min-height: 0; margin-top: 0.15rem; accent-color: var(--green); flex: none; }
.check label { font-size: 0.925rem; font-weight: 400; letter-spacing: 0; text-transform: none; margin: 0; }
.hp { position: absolute; left: -10000px; width: 1px; height: 1px; overflow: hidden; }
.form-actions { text-align: center; }
.form-actions .btn { min-width: 14rem; cursor: pointer; }
.form-actions .btn[disabled] { opacity: 0.6; cursor: wait; }
.form-actions .small { margin-top: 0.9rem; }
.form-status { margin-top: 1rem; text-align: center; font-size: 0.95rem; }
.form-status.error { color: #9B2C1F; }
.form-done { text-align: center; }
.form-done h2 { margin-bottom: 0.5rem; }
.form-done[hidden], .form-card[hidden] { display: none; }
.preview-flag {
  display: block; max-width: 760px; margin: 0 auto 1rem; text-align: center; font-size: 0.85rem;
  background: #FFF8E1; border: 1px solid #E6D9A8; border-radius: var(--radius); padding: 0.6rem 1rem; color: var(--ink);
}
.preview-flag[hidden] { display: none; }
.cal-box { min-height: 520px; }
.cal-box .embed-ph a { font-weight: 600; }

.seal img { width: 66%; height: auto; }
