/* =========================================================================
   ST PHILOMENA GIFTS — stylesheet
   -------------------------------------------------------------------------
   Design language: "holy card" — ivory paper, Marian blue, gold leaf,
   chapel-arch framed images, and small Latin inscriptions.
   All colours and type sizes live in the :root variables below.
   ========================================================================= */

:root {
  /* Paper & ink */
  --paper:      #FAF6EC;
  --paper-deep: #F1EAD9;
  --ink:        #2E2921;
  --ink-soft:   #5C5443;

  /* Marian blues (from the watercolour artwork) */
  --blue:       #33517E;
  --blue-deep:  #22375A;
  --blue-mist:  #E2E9F3;

  /* Gold leaf */
  --gold:       #B08A2E;
  --gold-deep:  #8C6C22;
  --gold-pale:  #E2D2A4;

  /* Saint Philomena's colours — martyrdom & purity (used sparingly) */
  --rose:       #A34A52;
  --tile:       #C3714F;   /* terracotta, for the catacomb tiles */

  --hairline:   rgba(46, 41, 33, 0.16);
  --shadow:     0 18px 40px -24px rgba(34, 55, 90, 0.45);

  --font-display: "Cormorant Garamond", "Times New Roman", serif;
  --font-body:    "EB Garamond", Georgia, serif;

  --measure: 62ch;
}

/* ---------- Reset-lite ---------- */
*, *::before, *::after { box-sizing: border-box; }
* { margin: 0; }
html { scroll-behavior: smooth; }
img, svg { display: block; max-width: 100%; }
button { font: inherit; cursor: pointer; }
input, textarea, select { font: inherit; }

body {
  font-family: var(--font-body);
  font-size: 1.125rem;
  line-height: 1.7;
  color: var(--ink);
  background-color: var(--paper);
  background-image: radial-gradient(120% 90% at 50% 0%, rgba(226, 233, 243, 0.55) 0%, rgba(226, 233, 243, 0) 55%);
  background-repeat: no-repeat;
  -webkit-font-smoothing: antialiased;
}

::selection { background: var(--gold-pale); color: var(--ink); }

a { color: var(--blue); text-decoration-color: rgba(51, 81, 126, 0.4); text-underline-offset: 3px; }
a:hover { color: var(--blue-deep); text-decoration-color: var(--gold); }

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

/* ---------- Type ---------- */
h1, h2, h3 {
  font-family: var(--font-display);
  font-weight: 500;
  line-height: 1.12;
  color: var(--ink);
  text-wrap: balance;
}
h1 { font-size: clamp(2.6rem, 6.5vw, 4.4rem); }
h2 { font-size: clamp(2rem, 4.5vw, 3rem); }
h3 { font-size: clamp(1.35rem, 2.6vw, 1.7rem); }
h1 em, h2 em { font-style: italic; font-weight: 500; color: var(--blue); }

.eyebrow {
  display: block;
  font-family: var(--font-body);
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.38em;
  text-transform: uppercase;
  color: var(--gold-deep);
  margin-bottom: 1.1rem;
}

.lead {
  font-size: clamp(1.2rem, 2.2vw, 1.35rem);
  color: var(--ink-soft);
  max-width: var(--measure);
}

p { max-width: var(--measure); }
.center { text-align: center; }
.center p, .center .lead { margin-inline: auto; }

.latin {
  font-family: var(--font-display);
  font-style: italic;
  color: var(--blue);
}

/* Illuminated first letter for long-form pages */
.dropcap::first-letter {
  font-family: var(--font-display);
  font-size: 3.4em;
  font-weight: 500;
  color: var(--gold-deep);
  float: left;
  line-height: 0.82;
  padding-right: 0.12em;
  padding-top: 0.06em;
}

/* ---------- Layout ---------- */
.container { max-width: 1120px; margin-inline: auto; padding-inline: clamp(1.25rem, 5vw, 2.5rem); }
.container--narrow { max-width: 820px; }

.section { padding-block: clamp(4rem, 9vw, 6.5rem); }
.section--tight { padding-block: clamp(2.5rem, 6vw, 4rem); }

.section--blue {
  background: var(--blue-deep);
  background-image: radial-gradient(90% 120% at 50% 0%, rgba(51, 81, 126, 0.6) 0%, rgba(34, 55, 90, 0) 70%);
  color: #F3EEDF;
}
.section--blue h2, .section--blue h3 { color: #FBF7EA; }
.section--blue h2 em { color: var(--gold-pale); }
.section--blue .eyebrow { color: var(--gold-pale); }
.section--blue .lead, .section--blue p { color: #DCE1E8; }
.section--blue a { color: var(--gold-pale); text-decoration-color: rgba(226, 210, 164, 0.5); }
.section--blue a:hover { color: #F0E3BE; }

.section--deep { background: var(--paper-deep); }

/* Gold divider: line — star — line */
.divider {
  display: flex;
  align-items: center;
  gap: 1rem;
  max-width: 340px;
  margin: 1.6rem auto;
  color: var(--gold);
}
.divider::before, .divider::after {
  content: "";
  flex: 1;
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--gold-pale));
}
.divider::after { background: linear-gradient(90deg, var(--gold-pale), transparent); }
.divider span { font-size: 0.9rem; line-height: 1; }
.divider--left { margin-inline: 0; }

/* ---------- Buttons ---------- */
.btn {
  display: inline-block;
  padding: 0.85rem 1.9rem;
  font-family: var(--font-body);
  font-size: 0.85rem;
  font-weight: 600;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  text-decoration: none;
  border: 1px solid var(--blue-deep);
  background: var(--blue-deep);
  color: #FAF6EC;
  transition: background 0.25s ease, color 0.25s ease, transform 0.25s ease, box-shadow 0.25s ease;
}
.btn:hover {
  background: var(--blue);
  color: #FFFDF6;
  transform: translateY(-2px);
  box-shadow: var(--shadow);
}
.btn--ghost { background: transparent; color: var(--blue-deep); }
.btn--ghost:hover { background: var(--blue-deep); color: #FAF6EC; }
.btn--gold { background: transparent; border-color: var(--gold); color: var(--gold-pale); }
.btn--gold:hover { background: var(--gold); border-color: var(--gold); color: var(--blue-deep); }
.btn--small { padding: 0.55rem 1.2rem; font-size: 0.76rem; }
.btn-row { display: flex; flex-wrap: wrap; gap: 0.9rem; margin-top: 2rem; }

/* ---------- Header ---------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(250, 246, 236, 0.92);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--hairline);
}
.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.5rem;
  padding-block: 0.85rem;
}
.brand {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  text-decoration: none;
  color: var(--ink);
}
.brand svg { width: 34px; height: 34px; color: var(--gold); flex-shrink: 0; }
.brand-text { display: flex; flex-direction: column; line-height: 1.05; }
.brand-name {
  font-family: var(--font-display);
  font-size: 1.45rem;
  font-weight: 600;
  letter-spacing: 0.01em;
  color: var(--blue-deep);
}
.brand-motto {
  font-size: 0.66rem;
  letter-spacing: 0.42em;
  text-transform: uppercase;
  color: var(--gold-deep);
  margin-top: 0.2rem;
}

.site-nav { display: flex; gap: clamp(1rem, 2.5vw, 2rem); }
.site-nav a {
  font-size: 0.82rem;
  font-weight: 600;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  text-decoration: none;
  color: var(--ink-soft);
  padding-block: 0.4rem;
  border-bottom: 1px solid transparent;
}
.site-nav a:hover { color: var(--blue-deep); border-bottom-color: var(--gold-pale); }
.site-nav a[aria-current="page"] { color: var(--blue-deep); border-bottom-color: var(--gold); }

.nav-toggle {
  display: none;
  background: none;
  border: 1px solid var(--hairline);
  padding: 0.45rem 0.9rem;
  font-size: 0.78rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--blue-deep);
}

@media (max-width: 760px) {
  .nav-toggle { display: inline-block; }
  .site-nav {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    flex-direction: column;
    gap: 0;
    background: var(--paper);
    border-bottom: 1px solid var(--hairline);
    padding: 0.5rem 0 1rem;
  }
  .site-nav.is-open { display: flex; }
  .site-nav a { padding: 0.85rem clamp(1.25rem, 5vw, 2.5rem); border-bottom: 1px solid var(--hairline); }
}

/* ---------- Framed images (the shop motif) ---------- */
/* Every picture is shown as if it were a framed print: thin gold frame,
   ivory mat, soft shadow. Add .frame--arch for a chapel-window top. */
.frame {
  background: #FFFEFA;
  border: 1px solid var(--gold);
  box-shadow: inset 0 0 0 1px rgba(176, 138, 46, 0.25), var(--shadow);
  padding: clamp(10px, 2.2vw, 18px);
}
.frame img { width: 100%; height: auto; }
.frame--arch, .frame--arch img { border-radius: 999px 999px 0 0; }
.frame--arch { padding-bottom: clamp(14px, 2.6vw, 24px); }

.caption {
  margin-top: 0.9rem;
  text-align: center;
  font-size: 0.95rem;
  font-style: italic;
  color: var(--ink-soft);
}

/* ---------- Hero ---------- */
.hero { padding-block: clamp(3rem, 7vw, 5.5rem); }
.hero-grid {
  display: grid;
  grid-template-columns: 1.05fr 0.85fr;
  gap: clamp(2.5rem, 6vw, 5rem);
  align-items: center;
}
.hero-art { max-width: 430px; justify-self: center; width: 100%; }
@media (max-width: 860px) {
  .hero-grid { grid-template-columns: 1fr; }
  .hero-art { max-width: 340px; }
}

/* Motto strip — the words on Saint Philomena's tomb */
.motto-strip {
  background: var(--blue-deep);
  color: #EDE6D2;
  text-align: center;
  padding-block: 1.6rem;
}
.motto-strip .latin {
  color: var(--gold-pale);
  font-size: clamp(1.3rem, 3vw, 1.7rem);
  letter-spacing: 0.12em;
}
.motto-strip p { max-width: none; font-size: 0.98rem; margin-top: 0.3rem; color: #C8CFDA; }

/* ---------- Card grids ---------- */
.grid-3 {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(270px, 100%), 1fr));
  gap: clamp(1.4rem, 3vw, 2.2rem);
  margin-top: clamp(2.2rem, 5vw, 3.5rem);
}
.grid-2 {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(320px, 100%), 1fr));
  gap: clamp(1.4rem, 3vw, 2.2rem);
  margin-top: clamp(2.2rem, 5vw, 3.5rem);
}

/* Collection cards (home page) */
.collection-card {
  display: block;
  text-decoration: none;
  color: var(--ink);
  background: #FFFEFA;
  border: 1px solid var(--hairline);
  border-top: 3px solid var(--gold);
  padding: 2.4rem 1.9rem 2.1rem;
  text-align: center;
  transition: transform 0.3s ease, box-shadow 0.3s ease, border-color 0.3s ease;
}
.collection-card:hover { transform: translateY(-4px); box-shadow: var(--shadow); border-color: var(--gold-pale); border-top-color: var(--gold); }
.collection-card svg { width: 58px; height: 58px; margin: 0 auto 1.3rem; color: var(--blue); }
.collection-card h3 { margin-bottom: 0.6rem; color: var(--blue-deep); }
.collection-card p { font-size: 1rem; color: var(--ink-soft); margin-inline: auto; }
.collection-card .go {
  display: inline-block;
  margin-top: 1.2rem;
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.24em;
  text-transform: uppercase;
  color: var(--gold-deep);
}

/* ---------- Product cards (shop) ---------- */
.product-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(min(255px, 100%), 1fr));
  gap: clamp(1.6rem, 3.5vw, 2.4rem);
  margin-top: clamp(2rem, 4vw, 3rem);
}
.product-card { display: flex; flex-direction: column; }
.product-card .frame { cursor: zoom-in; transition: transform 0.3s ease, box-shadow 0.3s ease; }
.product-card .frame:hover { transform: translateY(-4px); }
.product-card .frame img { aspect-ratio: 4 / 5; object-fit: cover; object-position: top center; }
.product-body { padding-top: 1.1rem; display: flex; flex-direction: column; flex: 1; }
.product-kicker {
  font-size: 0.7rem;
  font-weight: 600;
  letter-spacing: 0.3em;
  text-transform: uppercase;
  color: var(--gold-deep);
  margin-bottom: 0.35rem;
}
.product-name { font-size: 1.4rem; margin-bottom: 0.3rem; }
.product-price { font-style: italic; color: var(--blue); margin-bottom: 0.55rem; }
.product-desc { font-size: 1rem; color: var(--ink-soft); flex: 1; }
.product-actions { display: flex; flex-wrap: wrap; gap: 0.6rem; margin-top: 1.1rem; }

/* Filter chips */
.chip-row { display: flex; flex-wrap: wrap; gap: 0.6rem; margin-top: 2rem; }
.chip {
  border: 1px solid var(--hairline);
  background: transparent;
  color: var(--ink-soft);
  padding: 0.5rem 1.2rem;
  font-size: 0.8rem;
  font-weight: 600;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  border-radius: 999px;
  transition: all 0.2s ease;
}
.chip:hover { border-color: var(--gold); color: var(--blue-deep); }
.chip.is-active { background: var(--blue-deep); border-color: var(--blue-deep); color: var(--paper); }

/* ---------- Prayers ---------- */
.prayer-list { display: grid; gap: 1.8rem; margin-top: clamp(2rem, 4vw, 3rem); }
.prayer-card {
  background: #FFFEFA;
  border: 1px solid var(--hairline);
  padding: clamp(1.6rem, 4vw, 2.4rem);
  display: grid;
  grid-template-columns: 86px 1fr;
  gap: clamp(1.2rem, 3vw, 2rem);
}
.prayer-card.is-today { border: 1px solid var(--gold); box-shadow: inset 0 0 0 1px rgba(176, 138, 46, 0.25), var(--shadow); }
.prayer-date {
  text-align: center;
  border-right: 1px solid var(--hairline);
  padding-right: 1rem;
  align-self: start;
}
.prayer-date .day { font-family: var(--font-display); font-size: 2.5rem; line-height: 1; color: var(--blue-deep); }
.prayer-date .month { display: block; font-size: 0.72rem; letter-spacing: 0.3em; text-transform: uppercase; color: var(--gold-deep); margin-top: 0.3rem; }
.today-badge {
  display: inline-block;
  margin-bottom: 0.7rem;
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.3em;
  text-transform: uppercase;
  color: #FFFDF6;
  background: var(--rose);
  padding: 0.28rem 0.75rem;
  border-radius: 999px;
}
.prayer-card h3 { color: var(--blue-deep); }
.prayer-card .prayer-sub { font-style: italic; color: var(--gold-deep); margin: 0.2rem 0 0.9rem; }
.prayer-text {
  margin-top: 1.1rem;
  padding: 1.1rem 1.4rem;
  border-left: 2px solid var(--gold);
  background: var(--paper);
  font-style: italic;
  color: var(--ink);
}
/* The inset always has a light background, so its text stays dark
   even inside dark blue sections. */
.prayer-text p, .section--blue .prayer-text p { max-width: none; color: var(--ink); }
@media (max-width: 560px) {
  .prayer-card { grid-template-columns: 1fr; }
  .prayer-date { text-align: left; border-right: 0; border-bottom: 1px solid var(--hairline); padding: 0 0 0.8rem; display: flex; align-items: baseline; gap: 0.7rem; }
}

/* ---------- Saint Philomena page ---------- */
.seal { width: min(320px, 78vw); margin-inline: auto; color: var(--gold); }
.section--blue .seal { color: var(--gold-pale); }

/* The three terracotta tiles found sealing her tomb */
.tiles { display: flex; flex-wrap: wrap; justify-content: center; gap: 0.9rem; margin-block: 2.2rem; }
.tile {
  background: var(--tile);
  background-image: linear-gradient(160deg, rgba(255, 235, 210, 0.25), rgba(90, 40, 20, 0.18));
  color: #FBEEDF;
  border: 1px solid rgba(90, 40, 20, 0.35);
  box-shadow: var(--shadow);
  width: 138px;
  height: 138px;
  display: grid;
  place-items: center;
  font-family: var(--font-display);
  font-size: 1.6rem;
  letter-spacing: 0.2em;
  text-align: center;
  transform: rotate(-1.2deg);
}
.tile:nth-child(2) { transform: rotate(0.8deg); }
.tile:nth-child(3) { transform: rotate(-0.6deg); }
.tile-caption { text-align: center; font-size: 1rem; color: var(--ink-soft); font-style: italic; }
.tile-caption strong { font-style: normal; color: var(--blue-deep); }

/* Symbol cards */
.symbol-card {
  background: #FFFEFA;
  border: 1px solid var(--hairline);
  padding: 2rem 1.6rem;
  text-align: center;
}
.symbol-card svg { width: 52px; height: 52px; margin: 0 auto 1.1rem; color: var(--gold-deep); }
.symbol-card h3 { font-size: 1.35rem; color: var(--blue-deep); margin-bottom: 0.45rem; }
.symbol-card p { font-size: 0.98rem; color: var(--ink-soft); margin-inline: auto; }

/* Timeline */
.timeline { list-style: none; padding: 0; margin: clamp(2rem, 4vw, 3rem) 0 0; border-left: 1px solid var(--gold-pale); }
.timeline li { position: relative; padding: 0 0 2.2rem 2rem; }
.timeline li:last-child { padding-bottom: 0; }
.timeline li::before {
  content: "";
  position: absolute;
  left: -5px;
  top: 0.55em;
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: var(--gold);
  box-shadow: 0 0 0 4px var(--paper);
}
.timeline .year { font-family: var(--font-display); font-size: 1.5rem; color: var(--blue-deep); display: block; }

/* ---------- Two-column feature ---------- */
.feature-grid {
  display: grid;
  grid-template-columns: 0.85fr 1.15fr;
  gap: clamp(2.5rem, 6vw, 5rem);
  align-items: center;
}
.feature-grid--flip { grid-template-columns: 1.15fr 0.85fr; }
.feature-art { max-width: 380px; width: 100%; justify-self: center; }
@media (max-width: 860px) {
  .feature-grid, .feature-grid--flip { grid-template-columns: 1fr; }
  .feature-art { max-width: 320px; }
}

/* ---------- Forms (contact) ---------- */
.form-grid { display: grid; gap: 1.2rem; margin-top: 1.8rem; }
.form-field label {
  display: block;
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--blue-deep);
  margin-bottom: 0.45rem;
}
.form-field input, .form-field textarea {
  width: 100%;
  padding: 0.8rem 1rem;
  background: #FFFEFA;
  border: 1px solid var(--hairline);
  color: var(--ink);
}
.form-field input:focus, .form-field textarea:focus { border-color: var(--gold); outline: none; box-shadow: 0 0 0 1px var(--gold); }
.hp-field { position: absolute; left: -9999px; }

.info-list { list-style: none; padding: 0; display: grid; gap: 1.3rem; margin-top: 1.8rem; }
.info-list li { padding-left: 1.6rem; position: relative; }
.info-list li::before { content: "✦"; position: absolute; left: 0; color: var(--gold); font-size: 0.8rem; top: 0.35em; }
.info-list strong { color: var(--blue-deep); }

/* ---------- Lightbox ---------- */
dialog.lightbox {
  border: none;
  background: transparent;
  padding: 0;
  max-width: min(92vw, 760px);
}
dialog.lightbox::backdrop { background: rgba(34, 55, 90, 0.88); backdrop-filter: blur(3px); }
dialog.lightbox .frame { margin: 0; }
dialog.lightbox img { max-height: 80vh; width: auto; margin-inline: auto; }
.lightbox-close {
  display: block;
  margin: 1rem auto 0;
  background: transparent;
  border: 1px solid var(--gold-pale);
  color: var(--gold-pale);
  padding: 0.5rem 1.4rem;
  font-size: 0.78rem;
  letter-spacing: 0.24em;
  text-transform: uppercase;
}
.lightbox-close:hover { background: var(--gold-pale); color: var(--blue-deep); }

/* ---------- Footer ---------- */
.site-footer { background: var(--blue-deep); color: #C8CFDA; }
.footer-grid {
  display: grid;
  grid-template-columns: 1.3fr 0.8fr 1fr;
  gap: clamp(2rem, 5vw, 4rem);
  padding-block: clamp(3rem, 6vw, 4.5rem) 2.5rem;
}
@media (max-width: 760px) { .footer-grid { grid-template-columns: 1fr; } }
.site-footer h3 {
  color: var(--gold-pale);
  font-size: 0.8rem;
  font-family: var(--font-body);
  font-weight: 600;
  letter-spacing: 0.3em;
  text-transform: uppercase;
  margin-bottom: 1.1rem;
}
.site-footer p { font-size: 1rem; }
.site-footer a { color: #E5E9F0; text-decoration: none; }
.site-footer a:hover { color: var(--gold-pale); }
.footer-links { list-style: none; padding: 0; display: grid; gap: 0.55rem; font-size: 1rem; }
.footer-brand { display: flex; align-items: center; gap: 0.7rem; margin-bottom: 1rem; }
.footer-brand svg { width: 30px; height: 30px; color: var(--gold-pale); }
.footer-brand span { font-family: var(--font-display); font-size: 1.4rem; font-weight: 600; color: #FBF7EA; }
.footer-bottom {
  border-top: 1px solid rgba(226, 210, 164, 0.2);
  padding-block: 1.4rem;
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 0.6rem;
  font-size: 0.9rem;
  color: #9BA6B8;
}
.footer-bottom .latin { color: var(--gold-pale); font-size: 0.95rem; }

/* ---------- Scroll reveal (respects reduced motion) ---------- */
.reveal { opacity: 0; transform: translateY(18px); transition: opacity 0.7s ease, transform 0.7s ease; }
.reveal.in { opacity: 1; transform: none; }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation: none !important; transition: none !important; }
  .reveal { opacity: 1; transform: none; }
}

/* ---------- Small utilities ---------- */
.mt-1 { margin-top: 1rem; }
.mt-2 { margin-top: 2rem; }
.note { font-size: 0.95rem; color: var(--ink-soft); font-style: italic; }
