/* ============================================================
   TLC MINISTRIES — SHARED STYLES
   Palette pulled from the TLC logo:
     - Black & warm paper as structural anchors
     - Deep sky blue (the dove) + sage green (the olive branch)
       as equal-weight accents
     - Soft gold reserved for grace notes only

   To re-theme the site, change the values in :root below.
   ============================================================ */

:root {
  /* ---- Brand colors ---- */
  --ink:        #0d0d0d;   /* logo black — header, footer, hard accents */
  --ink-soft:   #4a4a4a;
  --paper:      #f6f3ec;   /* warm off-white background */
  --paper-deep: #e8e3d4;
  --rule:       #d6d2c4;   /* divider lines */

  --sky:        #2c5870;   /* deep sky — pulled from the dove */
  --sky-dk:     #1c3e54;
  --sky-light:  #7ec5dc;   /* the lighter dove highlight */
  --sky-tint:   #e8eef0;   /* fill backgrounds */

  --sage:       #6a8d6a;   /* balanced olive branch green */
  --sage-dk:    #4a6845;
  --sage-light: #9ab896;   /* the leaf lightness */
  --sage-tint:  #e9efe5;   /* fill backgrounds */

  --gold:       #c9a961;   /* grace notes only — eyebrows, highlights */
  --gold-soft:  #e8d8a8;

  /* ---- Typography ---- */
  --font-display: 'Cormorant Garamond', 'Garamond', serif;
  --font-body:    'Cardo', 'Georgia', serif;
  --font-mono:    'IBM Plex Mono', monospace;

  /* ---- Layout ---- */
  --max-w: 1180px;
  --gutter: clamp(1.25rem, 4vw, 3rem);
}

/* ---- Reset ---- */
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: var(--font-body);
  font-size: 18px;
  line-height: 1.65;
  color: var(--ink);
  background: var(--paper);
  background-image:
    radial-gradient(ellipse at top left, rgba(44, 88, 112, 0.04), transparent 50%),
    radial-gradient(ellipse at bottom right, rgba(106, 141, 106, 0.04), transparent 50%);
  background-attachment: fixed;
}
img { max-width: 100%; display: block; }
a { color: var(--sky); text-decoration: underline; text-decoration-thickness: 1px; text-underline-offset: 3px; }
a:hover { color: var(--sky-dk); }

/* ---- Typography ---- */
h1, h2, h3, h4 {
  font-family: var(--font-display);
  font-weight: 500;
  line-height: 1.15;
  letter-spacing: -0.01em;
  color: var(--ink);
  margin: 0 0 0.5em;
}
h1 { font-size: clamp(2.5rem, 6vw, 4.5rem); font-weight: 400; }
h2 { font-size: clamp(2rem, 4vw, 3rem); color: var(--sky); }
h3 { font-size: clamp(1.4rem, 2.5vw, 1.75rem); }
h4 { font-size: 1.15rem; font-family: var(--font-body); font-weight: 700; letter-spacing: 0.05em; text-transform: uppercase; color: var(--sky); }
p { margin: 0 0 1em; }
.eyebrow {
  font-family: var(--font-mono);
  font-size: 0.75rem;
  letter-spacing: 0.25em;
  text-transform: uppercase;
  color: var(--sage);
  margin: 0 0 1rem;
  display: inline-block;
}

/* ---- Layout containers ---- */
.container {
  max-width: var(--max-w);
  margin: 0 auto;
  padding: 0 var(--gutter);
}
section { padding: clamp(3rem, 7vw, 6rem) 0; }
.divider {
  text-align: center;
  margin: 2rem auto;
  color: var(--gold);
  font-size: 1.5rem;
  letter-spacing: 1rem;
}
.divider::before { content: "✦ ✦ ✦"; }

/* ============================================================
   HEADER / NAV  (black — matches logo background)
   ============================================================ */
.site-header {
  background: var(--ink);
  border-bottom: 1px solid var(--ink);
  position: sticky;
  top: 0;
  z-index: 100;
}
.site-header .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-top: 1rem;
  padding-bottom: 1rem;
  gap: 2rem;
}
.brand {
  font-family: var(--font-display);
  font-size: 1.5rem;
  font-weight: 500;
  text-decoration: none;
  color: var(--paper);
  letter-spacing: 0.02em;
}
.brand small {
  display: block;
  font-family: var(--font-mono);
  font-size: 0.65rem;
  letter-spacing: 0.3em;
  text-transform: uppercase;
  color: var(--sky-light);
  margin-top: 2px;
}
.nav { display: flex; gap: clamp(1rem, 2vw, 2rem); align-items: center; }
.nav a {
  font-family: var(--font-body);
  text-decoration: none;
  color: var(--paper);
  font-size: 1rem;
  position: relative;
  padding: 0.25rem 0;
}
.nav a::after {
  content: "";
  position: absolute;
  left: 0; right: 0; bottom: -2px;
  height: 1px;
  background: var(--sky-light);
  transform: scaleX(0);
  transform-origin: right;
  transition: transform 0.3s ease;
}
.nav a:hover::after, .nav a.active::after { transform: scaleX(1); transform-origin: left; }
.nav a.active { color: var(--sky-light); }

.nav-toggle {
  display: none;
  background: none;
  border: 1px solid var(--paper);
  color: var(--paper);
  padding: 0.5rem 0.75rem;
  cursor: pointer;
  font-family: var(--font-mono);
  font-size: 0.75rem;
  letter-spacing: 0.15em;
  text-transform: uppercase;
}

@media (max-width: 820px) {
  .nav-toggle { display: block; }
  .nav {
    display: none;
    position: absolute;
    top: 100%; left: 0; right: 0;
    flex-direction: column;
    background: var(--ink);
    padding: 1.5rem var(--gutter);
    border-bottom: 1px solid var(--rule);
    gap: 1rem;
  }
  .nav.open { display: flex; }
  .nav a { font-size: 1.25rem; }
}

/* ============================================================
   BUTTONS — Sky and Sage as equal-weight primary actions
   ============================================================ */
.btn {
  display: inline-block;
  padding: 0.85rem 1.75rem;
  font-family: var(--font-body);
  font-size: 1rem;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  text-decoration: none;
  border: 1px solid var(--ink);
  background: transparent;
  color: var(--ink);
  cursor: pointer;
  transition: all 0.25s ease;
}
.btn:hover { background: var(--ink); color: var(--paper); }

.btn-primary { background: var(--sky); border-color: var(--sky); color: var(--paper); }
.btn-primary:hover { background: var(--sky-dk); border-color: var(--sky-dk); color: var(--paper); }

.btn-sage { background: var(--sage); border-color: var(--sage); color: var(--paper); }
.btn-sage:hover { background: var(--sage-dk); border-color: var(--sage-dk); color: var(--paper); }

.btn-gold { background: var(--gold); border-color: var(--gold); color: var(--ink); }
.btn-gold:hover { background: var(--gold-soft); border-color: var(--gold-soft); color: var(--ink); }

/* ============================================================
   HERO
   ============================================================ */
.hero {
  padding: clamp(4rem, 9vw, 8rem) 0 clamp(3rem, 6vw, 5rem);
  position: relative;
  overflow: hidden;
}
.hero-grid {
  display: grid;
  grid-template-columns: 1.2fr 1fr;
  gap: clamp(2rem, 5vw, 5rem);
  align-items: center;
}
@media (max-width: 820px) {
  .hero-grid { grid-template-columns: 1fr; }
}
.hero h1 {
  font-style: italic;
  font-weight: 300;
}
.hero h1 em {
  font-style: normal;
  color: var(--sky);
  display: block;
}

/* ============================================================
   CARDS
   ============================================================ */
.card {
  background: rgba(255, 255, 255, 0.55);
  border: 1px solid var(--rule);
  padding: clamp(1.5rem, 3vw, 2.25rem);
  position: relative;
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}
.card:hover {
  transform: translateY(-3px);
  box-shadow: 0 12px 24px -10px rgba(13, 13, 13, 0.18);
}
.card-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 1.5rem;
}
.card-date {
  font-family: var(--font-mono);
  font-size: 0.8rem;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--gold);
  margin-bottom: 0.5rem;
}
.card h3 { margin-bottom: 0.5rem; color: var(--ink); }
.card-meta {
  font-size: 0.9rem;
  color: var(--ink-soft);
  font-style: italic;
  margin-bottom: 1rem;
}

/* ============================================================
   WELCOME POPUP — gentle bottom slide-up card for first-time
   visitors. Triggered 30s after page load on the home page.
   ============================================================ */
#welcomePopup {
  position: fixed;
  bottom: 16px;
  left: 16px;
  right: 16px;
  z-index: 9999;
  pointer-events: none;
  display: flex;
  justify-content: center;
}
.welcome-popup-card {
  background: var(--paper);
  border: 1px solid var(--sage);
  border-radius: 12px;
  padding: 1.5rem 1.5rem 1.25rem;
  max-width: 440px;
  width: 100%;
  box-shadow: 0 12px 40px rgba(13, 13, 13, 0.18);
  position: relative;
  pointer-events: auto;
  transform: translateY(120%);
  opacity: 0;
  transition: transform 0.45s cubic-bezier(0.2, 0.9, 0.3, 1.1), opacity 0.3s ease;
}
#welcomePopup.welcome-visible .welcome-popup-card {
  transform: translateY(0);
  opacity: 1;
}
#welcomePopup.welcome-leaving .welcome-popup-card {
  transform: translateY(40%);
  opacity: 0;
  transition: transform 0.3s ease, opacity 0.3s ease;
}
.welcome-close {
  position: absolute;
  top: 6px;
  right: 8px;
  background: transparent;
  border: 0;
  color: var(--ink-soft);
  font-size: 1.5rem;
  line-height: 1;
  cursor: pointer;
  padding: 6px 12px;
}
.welcome-close:hover { color: var(--ink); }
.welcome-eyebrow {
  font-family: var(--font-mono);
  font-size: 0.65rem;
  letter-spacing: 0.25em;
  text-transform: uppercase;
  color: var(--sage);
  margin-bottom: 0.5rem;
}
.welcome-title {
  font-family: var(--font-display);
  font-size: 1.5rem;
  font-style: italic;
  font-weight: 500;
  color: var(--sky);
  margin: 0 0 0.5rem;
}
.welcome-body {
  font-size: 0.95rem;
  color: var(--ink-soft);
  margin: 0 0 1.25rem;
  line-height: 1.5;
}
.welcome-actions {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.5rem;
}
.welcome-actions .welcome-btn-soft {
  grid-column: span 2;
}
.welcome-btn {
  display: block;
  text-align: center;
  padding: 0.7rem 1rem;
  border-radius: 8px;
  text-decoration: none;
  font-family: var(--font-mono);
  font-size: 0.7rem;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  transition: all 0.2s ease;
  border: 1px solid transparent;
}
.welcome-btn-primary {
  background: var(--sky);
  color: var(--paper);
}
.welcome-btn-primary:hover { background: var(--sky-dk); }
.welcome-btn-sage {
  background: var(--sage);
  color: var(--paper);
}
.welcome-btn-sage:hover { background: var(--sage-dk); }
.welcome-btn-soft {
  background: transparent;
  color: var(--sky);
  border: 1px solid var(--sky);
}
.welcome-btn-soft:hover {
  background: var(--sky-tint);
}

/* Hide popup when running as installed PWA (app home already has these CTAs) */
@media (display-mode: standalone) {
  #welcomePopup { display: none; }
}

/* ============================================================
   APP HOME (Linktree-style) — only shown when running as PWA
   Hidden in regular browsers, visible when installed
   ============================================================ */
.app-home { display: none; }

/* Detect PWA standalone mode and show app home, hide website hero */
@media (display-mode: standalone) {
  .app-home { display: block; }
  .website-only { display: none !important; }
}

.app-home {
  padding: 1.5rem 1.25rem 3rem;
  max-width: 480px;
  margin: 0 auto;
}
.app-home-header {
  text-align: center;
  padding: 2rem 0 1.5rem;
}
.app-home-logo {
  width: 120px;
  height: 120px;
  margin: 0 auto 1.25rem;
  background: var(--ink);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1.5rem;
}
.app-home-logo img { width: 100%; height: auto; }
.app-home-title {
  font-family: var(--font-display);
  font-size: 2rem;
  font-style: italic;
  color: var(--ink);
  margin: 0 0 0.25rem;
}
.app-home-subtitle {
  font-family: var(--font-mono);
  font-size: 0.7rem;
  letter-spacing: 0.25em;
  text-transform: uppercase;
  color: var(--sage);
}
.app-home-divider {
  height: 1px;
  background: var(--rule);
  margin: 1.5rem 0;
}

/* Tile groups */
.app-tiles {
  display: grid;
  gap: 0.65rem;
}
.app-tile-section-title {
  font-family: var(--font-mono);
  font-size: 0.65rem;
  letter-spacing: 0.25em;
  text-transform: uppercase;
  color: var(--sage);
  margin: 1.5rem 0 0.75rem;
  text-align: center;
}

/* Big primary tiles (sky and sage backgrounds) */
.app-tile-primary {
  display: flex;
  align-items: center;
  gap: 0.85rem;
  padding: 1rem 1.1rem;
  border-radius: 12px;
  text-decoration: none;
  transition: transform 0.15s ease;
}
.app-tile-primary:active { transform: scale(0.98); }
.app-tile-primary.sky  { background: var(--sky);  color: var(--paper); }
.app-tile-primary.sage { background: var(--sage); color: var(--paper); }
.app-tile-primary .tile-icon {
  width: 38px; height: 38px; border-radius: 50%;
  background: rgba(255,255,255,0.15);
  display: flex; align-items: center; justify-content: center;
  font-size: 1.05rem; flex-shrink: 0;
}
.app-tile-primary .tile-text { flex: 1; }
.app-tile-primary .tile-label {
  font-family: var(--font-display);
  font-style: italic;
  font-size: 1.05rem;
  font-weight: 500;
}
.app-tile-primary .tile-sub {
  font-size: 0.75rem;
  opacity: 0.8;
  margin-top: 1px;
}
.app-tile-primary .tile-arrow {
  opacity: 0.7;
  font-size: 1.1rem;
}

/* White tiles */
.app-tile {
  display: flex;
  align-items: center;
  gap: 0.85rem;
  padding: 0.9rem 1rem;
  border-radius: 12px;
  background: rgba(255,255,255,0.7);
  border: 1px solid var(--rule);
  text-decoration: none;
  color: var(--ink);
  transition: transform 0.15s ease;
}
.app-tile:active { transform: scale(0.98); }
.app-tile .tile-icon {
  width: 36px; height: 36px; border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  font-size: 1rem; flex-shrink: 0;
  background: var(--sky-tint);
  color: var(--sky);
}
.app-tile .tile-icon.sage  { background: var(--sage-tint);     color: var(--sage); }
.app-tile .tile-icon.gold  { background: rgba(201,169,97,0.15); color: var(--gold); }
.app-tile .tile-icon.gray  { background: var(--paper-deep);    color: var(--ink-soft); }
.app-tile .tile-text { flex: 1; }
.app-tile .tile-label {
  font-family: var(--font-display);
  font-size: 1rem;
  color: var(--ink);
  font-weight: 500;
}
.app-tile .tile-sub {
  font-size: 0.72rem;
  color: var(--ink-soft);
  margin-top: 1px;
}
.app-tile .tile-arrow {
  color: var(--sky);
  font-size: 1rem;
}

/* Social row at bottom of app home */
.app-socials {
  display: flex;
  gap: 0.75rem;
  justify-content: center;
  margin-top: 1.75rem;
}
.app-socials a {
  width: 40px; height: 40px;
  border-radius: 50%;
  border: 1px solid var(--sky);
  color: var(--sky);
  display: flex; align-items: center; justify-content: center;
  text-decoration: none;
  transition: all 0.15s ease;
}
.app-socials a:active { background: var(--sky); color: var(--paper); }
.app-socials svg { width: 18px; height: 18px; fill: currentColor; }

/* Hide site header & footer in app mode (cleaner Linktree feel) */
@media (display-mode: standalone) {
  .site-header { display: none; }
  /* Keep footer for full site nav, but make it less prominent */
  .site-footer .footer-cta,
  .site-footer .footer-give-grid,
  .site-footer .footer-section-title { display: none; }
}

/* ============================================================
   HERO PHOTO FRAME — sage green border that adapts to any image
   ============================================================
   Used on the homepage hero. Drop in any photo (tall, wide,
   square, the dove, a group photo) and the frame fits naturally
   around it with a graceful sage border and breathing room.
   ============================================================ */
.hero-photo-frame {
  display: inline-block;
  padding: 14px;
  border: 1px solid var(--sage);
  background: var(--paper);
  position: relative;
  max-width: 100%;
  margin: 0 auto;
}
.hero-photo-frame::before {
  content: "";
  position: absolute;
  inset: 6px;
  border: 1px solid var(--sage-light);
  pointer-events: none;
}
.hero-photo-frame img {
  display: block;
  max-width: 100%;
  width: auto;
  height: auto;
  max-height: 480px;
}
/* Keep the frame centered within its column */
.hero-grid > .hero-photo-frame {
  justify-self: center;
}

/* ============================================================
   PHOTOS — site-wide photo handling
   ============================================================
   Three photo styles to cover every context. Each one auto-
   fits images of any size or aspect ratio. Just point `src`
   at a path — no manual resizing or cropping needed.

   .photo-portrait   — round circle (team members, headshots)
   .photo-rect       — rectangle (blog cards, event tiles)
   .photo-feature    — large flexible image (hero, post features)

   Each has a sibling .photo-fallback that shows when no image
   is provided — clean placeholders that match the palette.
   ============================================================ */

.photo-portrait {
  width: 180px;
  height: 180px;
  margin: 0 auto 1rem;
  border-radius: 50%;
  border: 3px solid var(--sage-light);
  padding: 4px;
  background: var(--sky-tint);
  background-clip: content-box;
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-display);
  font-size: 3rem;
  color: var(--sky);
  font-style: italic;
}
.photo-portrait img {
  width: 100%;
  height: 100%;
  border-radius: 50%;
  object-fit: cover;   /* fills circle, crops as needed, no distortion */
  display: block;
}

/* Smaller variant for board/honorary tiles */
.photo-portrait-sm {
  width: 130px;
  height: 130px;
  font-size: 2.2rem;
}

.photo-rect {
  aspect-ratio: 4 / 3;
  background: linear-gradient(135deg, var(--sky-tint), var(--sage-tint));
  border: 1px solid var(--rule);
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-display);
  font-size: 3rem;
  color: var(--sky);
  font-style: italic;
  overflow: hidden;
}
.photo-rect img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.photo-feature {
  border: 1px solid var(--rule);
  padding: 0.75rem;
  background: rgba(255, 255, 255, 0.5);
  position: relative;
  max-width: 480px;
  margin: 0 auto 2.5rem;
}
.photo-feature::before {
  content: "";
  position: absolute;
  inset: -8px;
  border: 1px solid var(--sage-light);
  pointer-events: none;
}
.photo-feature img {
  width: 100%;
  height: auto;
  display: block;
}
.photo-feature .photo-fallback-feature {
  aspect-ratio: 4 / 5;
  background: linear-gradient(135deg, var(--sky-tint), var(--sage-tint));
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-display);
  font-size: 5rem;
  color: var(--sky);
  font-style: italic;
}

/* ============================================================
   PERSON CARD — text styling
   (Photo styling lives in the PHOTOS section above)
   ============================================================ */
.person { text-align: center; }
.person h4 {
  color: var(--ink);
  text-transform: none;
  letter-spacing: 0;
  font-family: var(--font-display);
  font-size: 1.4rem;
  font-weight: 500;
  margin-bottom: 0.25rem;
}
.person .role {
  font-family: var(--font-mono);
  font-size: 0.75rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--sage);
  margin-bottom: 0.75rem;
}
.person p { font-size: 0.95rem; color: var(--ink-soft); }

/* ============================================================
   FORMS
   ============================================================ */
form { display: grid; gap: 1.25rem; max-width: 640px; }
.form-row { display: grid; gap: 0.4rem; }
label {
  font-family: var(--font-mono);
  font-size: 0.75rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--ink-soft);
}
input, textarea, select {
  font-family: var(--font-body);
  font-size: 1rem;
  padding: 0.75rem 1rem;
  background: rgba(255, 255, 255, 0.7);
  border: 1px solid var(--rule);
  color: var(--ink);
  width: 100%;
}
input:focus, textarea:focus, select:focus {
  outline: none;
  border-color: var(--sky);
  background: rgba(255, 255, 255, 0.95);
}
textarea { min-height: 140px; resize: vertical; }
.checkbox-row { display: flex; align-items: center; gap: 0.5rem; }
.checkbox-row input { width: auto; }
.checkbox-row label { letter-spacing: 0.05em; text-transform: none; font-family: var(--font-body); font-size: 0.95rem; color: var(--ink); }

/* ============================================================
   LIVESTREAM EMBED
   ============================================================ */
.video-wrap {
  position: relative;
  padding-bottom: 56.25%;
  height: 0;
  overflow: hidden;
  border: 1px solid var(--rule);
  background: var(--ink);
}
.video-wrap iframe {
  position: absolute;
  top: 0; left: 0; width: 100%; height: 100%;
  border: 0;
}

/* ============================================================
   FOOTER (matches the black header — bookends the page)
   ============================================================ */
.site-footer {
  background: var(--ink);
  color: var(--paper);
  padding: clamp(3rem, 6vw, 5rem) 0 2rem;
  margin-top: 4rem;
}
.site-footer h4 { color: var(--sky-light); }
.site-footer a { color: var(--paper); text-decoration: none; }
.site-footer a:hover { color: var(--sage-light); }

/* Beefed-up footer: section title divider */
.footer-section-title {
  color: var(--sky-light) !important;
  font-family: var(--font-mono);
  font-size: 0.7rem;
  letter-spacing: 0.25em;
  text-transform: uppercase;
  margin: 2rem 0 1rem;
  padding-bottom: 0.5rem;
  border-bottom: 1px solid rgba(126, 197, 220, 0.2);
}

/* Give tiles grid in footer */
.footer-give-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 0.75rem;
  margin-bottom: 2.5rem;
}
.footer-give-tile {
  display: flex !important;
  align-items: center;
  gap: 0.75rem;
  padding: 0.85rem 1rem;
  background: rgba(246, 243, 236, 0.05);
  border: 1px solid rgba(246, 243, 236, 0.15);
  border-radius: 6px;
  transition: all 0.2s ease;
}
.footer-give-tile:hover {
  background: rgba(126, 197, 220, 0.1);
  border-color: var(--sky-light);
  color: var(--paper) !important;
}
.footer-give-icon {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: var(--sky);
  color: var(--paper);
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-display);
  font-style: italic;
  font-weight: 500;
  font-size: 1.1rem;
  flex-shrink: 0;
}
.footer-give-text { display: flex; flex-direction: column; }
.footer-give-text strong {
  font-family: var(--font-display);
  font-style: italic;
  font-weight: 500;
  font-size: 1rem;
  color: var(--paper);
}
.footer-give-text small {
  font-size: 0.75rem;
  color: rgba(246, 243, 236, 0.6);
  margin-top: 1px;
}

/* Footer newsletter form */
.footer-newsletter {
  margin-bottom: 2.5rem;
  max-width: 540px;
}
.footer-newsletter-form {
  display: grid;
  grid-template-columns: 1fr 1fr auto;
  gap: 0.5rem;
}
@media (max-width: 600px) {
  .footer-newsletter-form { grid-template-columns: 1fr; }
}
.footer-newsletter-form input {
  background: rgba(246, 243, 236, 0.08);
  border: 1px solid rgba(246, 243, 236, 0.2);
  color: var(--paper);
  padding: 0.7rem 0.9rem;
  font-family: var(--font-body);
  font-size: 0.95rem;
  border-radius: 4px;
}
.footer-newsletter-form input::placeholder { color: rgba(246, 243, 236, 0.45); }
.footer-newsletter-form input:focus {
  outline: none;
  border-color: var(--sky-light);
  background: rgba(246, 243, 236, 0.12);
}
.footer-newsletter-form button {
  background: var(--sky);
  border: 1px solid var(--sky);
  color: var(--paper);
  padding: 0.7rem 1.5rem;
  font-family: var(--font-mono);
  font-size: 0.75rem;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  cursor: pointer;
  border-radius: 4px;
  transition: background 0.2s ease;
}
.footer-newsletter-form button:hover { background: var(--sky-dk); }
.footer-newsletter-form button:disabled {
  opacity: 0.6;
  cursor: not-allowed;
}
.footer-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 2.5rem;
  margin-bottom: 3rem;
}
.footer-grid ul { list-style: none; padding: 0; margin: 0; display: grid; gap: 0.5rem; }
.footer-cta {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
  margin-bottom: 2rem;
}
.footer-cta .btn { border-color: var(--paper); color: var(--paper); }
.footer-cta .btn:hover { background: var(--paper); color: var(--ink); }
.footer-cta .btn-primary { background: var(--sky); border-color: var(--sky); color: var(--paper); }
.footer-cta .btn-primary:hover { background: var(--sky-dk); border-color: var(--sky-dk); }
.footer-cta .btn-sage { background: var(--sage); border-color: var(--sage); color: var(--paper); }
.footer-cta .btn-sage:hover { background: var(--sage-dk); border-color: var(--sage-dk); }
.socials {
  display: flex;
  gap: 1rem;
  flex-wrap: wrap;
  margin-top: 1rem;
}
.socials a {
  width: 42px; height: 42px;
  display: inline-flex;
  align-items: center; justify-content: center;
  border: 1px solid var(--sky-light);
  border-radius: 50%;
  transition: all 0.2s ease;
  color: var(--sky-light);
}
.socials a:hover { background: var(--sky-light); color: var(--ink); }
.socials svg { width: 18px; height: 18px; fill: currentColor; }
.footer-fine {
  border-top: 1px solid rgba(246, 243, 236, 0.15);
  padding-top: 1.5rem;
  font-size: 0.85rem;
  color: rgba(246, 243, 236, 0.6);
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 1rem;
}

/* ============================================================
   UTILITIES
   ============================================================ */
.text-center { text-align: center; }
.muted { color: var(--ink-soft); }
.lead { font-size: 1.2rem; line-height: 1.6; }
.pullquote {
  font-family: var(--font-display);
  font-style: italic;
  font-size: clamp(1.5rem, 3vw, 2.25rem);
  line-height: 1.3;
  color: var(--sky);
  border-left: 3px solid var(--sage);
  padding-left: 1.5rem;
  margin: 2rem 0;
  max-width: 720px;
}
.section-head { text-align: center; margin-bottom: 3rem; }
.section-head h2 { margin-bottom: 0.5rem; }

/* Section tints — alternate sky and sage for visual rhythm */
.section-sky-tint  { background: var(--sky-tint);  border-top: 1px solid var(--rule); border-bottom: 1px solid var(--rule); }
.section-sage-tint { background: var(--sage-tint); border-top: 1px solid var(--rule); border-bottom: 1px solid var(--rule); }
.section-gold-tint { background: rgba(201, 169, 97, 0.08); border-top: 1px solid var(--rule); border-bottom: 1px solid var(--rule); }

/* ============================================================
   PWA — Install button + iOS hint
   ============================================================ */
.pwa-install-btn {
  display: none;   /* shown by pwa.js when install is available */
  align-items: center;
  gap: 0.5rem;
  background: var(--sage);
  border: 1px solid var(--sage);
  color: var(--paper);
  padding: 0.5rem 1rem;
  font-family: var(--font-mono);
  font-size: 0.7rem;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  cursor: pointer;
  text-decoration: none;
  transition: all 0.2s ease;
}
.pwa-install-btn:hover { background: var(--sage-dk); color: var(--paper); }
.pwa-install-btn::before {
  content: "↓";
  font-family: var(--font-body);
  font-weight: bold;
}

/* iOS install hint — small floating card */
.ios-hint-card {
  position: fixed;
  bottom: 16px;
  left: 16px;
  right: 16px;
  background: var(--paper);
  border: 1px solid var(--sky);
  padding: 1.25rem 1.25rem 1rem;
  border-radius: 12px;
  z-index: 9999;
  box-shadow: 0 8px 32px rgba(13, 13, 13, 0.18);
  max-width: 420px;
  margin: 0 auto;
  animation: slideUp 0.4s ease;
}
.ios-hint-close {
  position: absolute;
  top: 8px; right: 8px;
  background: transparent;
  border: 0;
  font-size: 1.5rem;
  line-height: 1;
  color: var(--ink-soft);
  cursor: pointer;
  padding: 4px 10px;
}
.ios-hint-close:hover { color: var(--ink); }
@keyframes slideUp {
  from { transform: translateY(100%); opacity: 0; }
  to { transform: translateY(0); opacity: 1; }
}

/* Hide install button when running as installed app */
@media (display-mode: standalone) {
  .pwa-install-btn { display: none !important; }
}

@keyframes fadeUp {
  from { opacity: 0; transform: translateY(12px); }
  to   { opacity: 1; transform: translateY(0); }
}
main > section { animation: fadeUp 0.7s ease both; }
main > section:nth-child(2) { animation-delay: 0.1s; }
main > section:nth-child(3) { animation-delay: 0.2s; }
