/* ============================================================
   Shared theme for index.php + the four detail pages
   (spirituality.php, company.php, politics.php, trust.php)
   ============================================================ */

:root {
  --bg: #ffffff;
  --ink: #0c1a33;
  --muted: rgba(12,26,51,.70);
  --blue: #0b2a5b;              /* brand navy: buttons, accents */
  --blue-hover: #16407f;
  --gold: #b58e4a;              /* restrained accent on light backgrounds */
  --gold-light: #d8b878;        /* accent on dark backgrounds */
  --panel: #f3f6fa;
  --serif: "Source Serif 4", Georgia, "Times New Roman", serif;
  --sans: "Manrope", system-ui, -apple-system, "Segoe UI", sans-serif;
  --pattern: none;              /* filled in by js/pattern.js */
}
* { box-sizing: border-box; margin: 0; padding: 0; }
html, body { background: var(--bg); color: var(--ink); font-family: var(--sans); -webkit-font-smoothing: antialiased; }
a { color: inherit; }
[hidden] { display: none !important; }

/* ---- header (logo + emblems + nav/back) ---- */
.header {
  position: relative; z-index: 6;
  display: flex; align-items: center; justify-content: space-between; gap: 24px;
  padding: env(safe-area-inset-top, 0) clamp(20px, 5vw, 80px) 0;
  height: 96px;
}
.logo { display: flex; align-items: center; text-decoration: none; }
.logo img { height: 48px; width: auto; display: block; }
.logo-fallback { font-family: var(--serif); font-weight: 600; font-size: 1.5rem; letter-spacing: -.005em; color: var(--blue); }

.logo-group { display: flex; align-items: center; gap: clamp(10px, 1.6vw, 22px); }
.emblems { display: flex; align-items: center; gap: clamp(8px, 1.2vw, 16px); padding-left: clamp(10px, 1.6vw, 20px); border-left: 1px solid rgba(12,26,51,.15); }
.emblems img {
  height: 120px; width: auto; object-fit: cover; display: block; margin-top: 10%;
  filter: drop-shadow(0 1px 2px rgba(12,26,51,.12));
}

.nav { display: flex; align-items: center; gap: clamp(22px, 3vw, 40px); }
.nav a.link {
  text-decoration: none; font-size: .9rem; font-weight: 600; padding: 8px 0; color: var(--ink);
  background: linear-gradient(var(--gold), var(--gold)) left bottom / 0 2px no-repeat;
  transition: background-size .3s ease, color .2s;
}
.nav a.link:hover { background-size: 100% 2px; color: var(--blue); }

.btn {
  font: 600 .92rem var(--sans); letter-spacing: .01em; cursor: pointer; text-decoration: none;
  display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  padding: 14px 28px; border-radius: 4px;
  background: var(--blue); color: #fff; border: 1px solid var(--blue);
  transition: background .25s, border-color .25s, color .25s;
}
.btn:hover { background: var(--blue-hover); border-color: var(--blue-hover); }
.btn svg { width: 16px; height: 16px; transition: transform .25s; }
.btn:hover svg { transform: translateY(2px); }
.btn.ghost {
  background: rgba(255,255,255,.88); color: var(--blue); padding: 11px 24px;
  border-color: rgba(11,42,91,.35);
  box-shadow: 0 4px 14px rgba(12,26,51,.10);
  backdrop-filter: blur(6px); -webkit-backdrop-filter: blur(6px);
}
.btn.ghost:hover { background: var(--blue); color: #fff; border-color: var(--blue); }

/* ---- back link (top-left, on the four detail pages) ---- */
.back {
  display: inline-flex; align-items: center; gap: 8px;
  font: 600 .9rem var(--sans); letter-spacing: .01em; color: var(--blue); background: #fff;
  border: 1px solid rgba(11,42,91,.35); padding: 11px 20px; border-radius: 4px;
  text-decoration: none; cursor: pointer;
  transition: background .25s, color .25s, border-color .25s;
}
.back svg { width: 16px; height: 16px; }
.back:hover { background: var(--blue); color: #fff; border-color: var(--blue); }
.back:focus-visible, .btn:focus-visible, .nav a:focus-visible { outline: 3px solid var(--blue-hover); outline-offset: 4px; }

/* ================= DETAIL PAGES (spirituality / company / politics / trust) ================= */
.page-wrap { position: relative; min-height: 100vh; overflow-x: hidden; }
.page-pattern {
  position: absolute; inset: 0; z-index: 0; pointer-events: none;
  background-image: var(--pattern); background-size: 150px auto; opacity: .35;
}
.page-header { position: relative; z-index: 2; }
.page-header .back { position: absolute; left: clamp(20px, 5vw, 80px); top: max(24px, env(safe-area-inset-top, 0)); }

/* ---- breadcrumb ---- */
.breadcrumb {
  position: relative; z-index: 1; max-width: 1080px; margin: 0 auto;
  padding: 22px 24px 0; font-size: .85rem; color: var(--muted);
}
.breadcrumb a { color: var(--blue); font-weight: 600; text-decoration: none; }
.breadcrumb a:hover { text-decoration: underline; }
.breadcrumb .sep { margin: 0 8px; color: var(--gold-light); }
.breadcrumb .current { color: var(--muted); }

.page-hero {
  position: relative; z-index: 1;
  max-width: 780px; margin: 0 auto; text-align: center;
  padding: clamp(24px, 5vh, 48px) 24px clamp(24px, 5vh, 40px);
}
.page-hero .bar { width: 48px; height: 2px; background: var(--gold); margin: 0 auto 24px; }
.page-hero h1 {
  font-family: var(--serif); font-weight: 500; letter-spacing: -.02em;
  font-size: clamp(2.4rem, 5vw, 3.6rem); color: var(--blue); line-height: 1.1;
}
.page-hero .tagline { margin-top: 16px; font-size: 1.1rem; color: var(--muted); font-style: italic; }

/* ---- placeholder media box: swap the div for a real <img> once photos exist ---- */
.media-box {
  position: relative; width: 100%; aspect-ratio: 16 / 8; border-radius: 10px; overflow: hidden;
  background: linear-gradient(135deg, rgba(11,42,91,.07), rgba(181,142,74,.10));
  border: 1px dashed rgba(11,42,91,.28);
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 10px;
  color: var(--muted); text-align: center; padding: 20px;
}
.media-box svg { width: 34px; height: 34px; color: var(--gold); opacity: .85; }
.media-box span { font-size: .82rem; font-weight: 600; letter-spacing: .02em; }
.hero-media { max-width: 1080px; margin: 0 auto 8px; padding: 0 24px; position: relative; z-index: 1; }
.hero-media .media-box { aspect-ratio: 16 / 6; }

.page-main { position: relative; z-index: 1; max-width: 1080px; margin: 0 auto; padding: 0 24px 100px; }
.page-section { padding: clamp(32px, 6vh, 56px) 0; border-top: 1px solid rgba(12,26,51,.10); }
.page-section:first-child { border-top: none; }
.page-section .label {
  display: block; font-size: .78rem; font-weight: 700; letter-spacing: .08em; text-transform: uppercase;
  color: var(--gold); margin-bottom: 10px;
}
.page-section h2 {
  font-family: var(--serif); font-weight: 500; font-size: clamp(1.5rem, 3vw, 2.1rem);
  color: var(--ink); margin-bottom: 14px; letter-spacing: -.01em;
}
.page-section p { font-size: 1.02rem; line-height: 1.75; color: var(--muted); max-width: 70ch; }
.page-section p + p { margin-top: 14px; }
.page-section ul { margin-top: 10px; padding-left: 22px; color: var(--muted); line-height: 1.8; }
.page-section .placeholder-note {
  display: inline-block; margin-top: 14px; font-size: .82rem; color: var(--gold);
  border: 1px dashed var(--gold-light); border-radius: 4px; padding: 6px 10px;
}

/* ---- split section: text on one side, placeholder image on the other ---- */
.split { display: grid; grid-template-columns: 1.1fr 1fr; gap: clamp(28px, 4vw, 56px); align-items: center; }
.split.reverse .split-media { order: 2; }
.split-media .media-box { aspect-ratio: 4 / 3; }
@media (max-width: 760px) {
  .split { grid-template-columns: 1fr; }
  .split.reverse .split-media { order: 0; }
}

/* ---- pull quote ---- */
.quote-block { max-width: 760px; margin: 0 auto; padding: clamp(32px, 6vh, 56px) 0; text-align: center; border-top: 1px solid rgba(12,26,51,.10); }
.quote-block blockquote {
  font-family: var(--serif); font-style: italic; color: var(--blue);
  font-size: clamp(1.25rem, 2.4vw, 1.6rem); line-height: 1.55;
}
.quote-block cite { display: block; margin-top: 14px; font-size: .82rem; color: var(--muted); font-style: normal; }

/* ---- closing CTA band ---- */
.cta-band { position: relative; z-index: 1; background: var(--panel); padding: clamp(40px, 7vh, 64px) 24px; text-align: center; }
.cta-band h3 { font-family: var(--serif); font-weight: 500; font-size: clamp(1.4rem, 2.6vw, 1.9rem); color: var(--blue); margin-bottom: 10px; }
.cta-band p { color: var(--muted); max-width: 60ch; margin: 0 auto 22px; line-height: 1.65; }

@media (max-width: 800px) {
  .nav .contact { display: none; }
  .emblems { padding-left: 8px; gap: 6px; }
  .emblems img { height: 28px; max-width: 28px; }
}
@media (max-width: 480px) {
  .emblems img:nth-child(4) { display: none; }
}