/* The BodyEvolving Legacy — starter page styles */

:root {
  --cream: #f4eee4;
  --paper: #fbf6ee;
  --card: #fffbf5;
  --ink: #2a241c;
  --ink-soft: #5c5348;
  --ink-faint: #7a7166;
  --gold: #c4963a;
  --gold-soft: #d4b36a;
  --gold-deep: #8a5e1c;
  --bronze: #6b4518;
  --navy: #1b2433;
  --navy-deep: #121820;
  --line: rgba(42, 36, 28, 0.12);
  --line-strong: rgba(42, 36, 28, 0.2);
  --shadow: 0 10px 30px rgba(26, 28, 36, 0.06);
  --header-h: 4.25rem;
  --measure: 40rem;
  --wide: 66rem;
  --radius: 1.1rem;
}

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

html {
  scroll-behavior: smooth;
}

html:focus-within {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  color: var(--ink);
  background: var(--cream);
  font-family: "Source Sans 3", "Segoe UI", system-ui, sans-serif;
  font-size: 1.125rem;
  font-weight: 400;
  line-height: 1.65;
  letter-spacing: 0.01em;
  text-rendering: optimizeLegibility;
  -webkit-font-smoothing: antialiased;
}

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

a {
  color: var(--gold-deep);
  text-underline-offset: 0.18em;
  text-decoration-thickness: 1px;
}

a:hover {
  color: var(--bronze);
}

a:focus-visible,
button:focus-visible {
  outline: 2px solid var(--gold-deep);
  outline-offset: 3px;
}

h1, h2, h3, .brand-name, .pillar-title {
  font-family: "Playfair Display", "Palatino Linotype", Palatino, Georgia, serif;
  font-weight: 500;
  letter-spacing: 0.01em;
  line-height: 1.2;
  color: var(--ink);
}

.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.skip {
  position: absolute;
  left: 1rem;
  top: -3rem;
  z-index: 100;
  background: var(--navy);
  color: var(--paper);
  padding: 0.5rem 0.9rem;
  border-radius: 0.4rem;
}

.skip:focus {
  top: 0.75rem;
  color: var(--paper);
}

/* Header */

.site-header {
  position: sticky;
  top: 0;
  z-index: 20;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem 1.5rem;
  flex-wrap: wrap;
  min-height: var(--header-h);
  padding: 0.7rem 1.5rem;
  background: rgba(251, 246, 238, 0.92);
  background: color-mix(in srgb, var(--paper) 88%, transparent);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--line);
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 0.7rem;
  color: var(--ink);
  text-decoration: none;
  min-width: 0;
}

.brand:hover {
  color: var(--ink);
}

.brand-mark {
  width: 2.35rem;
  height: 2.35rem;
  border-radius: 50%;
  object-fit: cover;
  flex-shrink: 0;
  box-shadow: 0 0 0 1px rgba(196, 150, 58, 0.45), 0 2px 8px rgba(26, 28, 36, 0.12);
}

.brand-name {
  font-size: 1.05rem;
  font-weight: 500;
  letter-spacing: 0.02em;
  white-space: nowrap;
}

.site-nav {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem 1.15rem;
  font-size: 0.92rem;
  font-weight: 500;
  letter-spacing: 0.02em;
}

.site-nav a {
  color: var(--ink-soft);
  text-decoration: none;
  padding: 0.2rem 0;
  border-bottom: 1px solid transparent;
}

.site-nav a:hover,
.site-nav a:focus-visible {
  color: var(--ink);
  border-bottom-color: var(--gold);
}

/* Hero */

.hero {
  position: relative;
  margin: 0;
  background:
    linear-gradient(180deg, #1c2a3c 0%, #4a3a3a 32%, #e39a48 62%, #c97a3a 100%);
  overflow: hidden;
}

.hero-image {
  width: 100%;
  height: min(72vh, 46rem);
  object-fit: cover;
  object-position: center 46%;
}

.hero-fade {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: 4.5rem;
  background: linear-gradient(180deg, transparent, var(--cream));
  pointer-events: none;
}

/* Shared section layout */

main {
  display: block;
}

.section {
  width: min(var(--wide), calc(100% - 2.5rem));
  margin: 0 auto;
  padding: 4.25rem 0 0;
  scroll-margin-top: calc(var(--header-h) + 0.75rem);
}

.section:last-of-type {
  padding-bottom: 4.5rem;
}

.kicker {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.7rem;
  margin: 0 0 0.85rem;
  color: var(--gold-deep);
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

.plumb {
  display: inline-block;
  width: 1px;
  height: 1.35rem;
  background: linear-gradient(180deg, transparent, var(--gold), transparent);
}

.section h2 {
  margin: 0 0 1rem;
  text-align: center;
  font-size: clamp(1.85rem, 3.4vw, 2.55rem);
  font-weight: 500;
}

.lede,
.prose {
  width: min(var(--measure), 100%);
  margin: 0 auto;
  text-align: center;
  color: var(--ink-soft);
  font-size: 1.14rem;
}

/* Pillars */

.pillars {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.15rem;
  margin: 2.4rem 0 0;
}

.pillar {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 1.7rem 1.45rem 1.6rem;
  box-shadow: var(--shadow);
  text-align: center;
}

.pillar-icon {
  width: 3rem;
  height: 3rem;
  margin: 0 auto 1.05rem;
  color: var(--gold-deep);
}

.pillar-title {
  margin: 0 0 0.55rem;
  font-size: 1.28rem;
  font-weight: 500;
}

.pillar p {
  margin: 0;
  color: var(--ink-soft);
  font-size: 1.02rem;
  line-height: 1.55;
}

/* Path of levity */

.path {
  margin-top: 4.25rem;
}

.path .prose {
  font-size: 1.16rem;
  line-height: 1.7;
}

/* Connect */

.connect {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1.15rem;
  margin-top: 2.2rem;
}

.card {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 1.85rem 1.5rem 1.7rem;
  box-shadow: var(--shadow);
  text-align: center;
  scroll-margin-top: calc(var(--header-h) + 0.75rem);
}

.card h3 {
  margin: 0 0 0.4rem;
  font-size: 1.55rem;
  font-weight: 500;
}

.card p {
  margin: 0 0 1.2rem;
  color: var(--ink-soft);
}

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  min-height: 2.75rem;
  padding: 0.55rem 1.2rem;
  border-radius: 999px;
  background: var(--bronze);
  color: #fbf6ee;
  text-decoration: none;
  font-size: 0.98rem;
  font-weight: 600;
  letter-spacing: 0.02em;
  transition: background 0.15s ease, transform 0.15s ease;
}

.button:hover,
.button:focus-visible {
  background: var(--gold-deep);
  color: #fffaf2;
}

.button svg {
  width: 1.1rem;
  height: 1.1rem;
  flex-shrink: 0;
}

.button-ghost {
  background: transparent;
  color: var(--bronze);
  box-shadow: inset 0 0 0 1.5px var(--bronze);
}

.button-ghost:hover,
.button-ghost:focus-visible {
  background: color-mix(in srgb, var(--gold) 16%, transparent);
  color: var(--bronze);
}

/* Articles */

.articles {
  margin-top: 3.5rem;
  background: var(--card);
  border: 1px dashed color-mix(in srgb, var(--gold-deep) 45%, var(--line-strong));
  border-radius: var(--radius);
  padding: 2.4rem 1.5rem 2.2rem;
  text-align: center;
}

.articles h2 {
  margin-bottom: 0.75rem;
}

.articles p {
  margin: 0 auto;
  width: min(32rem, 100%);
  color: var(--ink-soft);
}

/* Footer */

.site-footer {
  margin-top: 0;
  padding: 2.6rem 1.5rem 2.4rem;
  background: var(--navy);
  color: #d9d0c3;
  text-align: center;
}

.footer-mark {
  width: 3rem;
  height: 3rem;
  margin: 0 auto 1rem;
  border-radius: 50%;
  box-shadow: 0 0 0 1px rgba(212, 179, 106, 0.45);
}

.site-footer p {
  margin: 0.2rem 0;
  font-size: 0.95rem;
}

.site-footer .copyright {
  color: #f3eadc;
  font-family: "Playfair Display", Georgia, serif;
  font-size: 1rem;
}

.contact-placeholder {
  color: #c9bfb1;
  font-size: 0.92rem;
}

/* Responsive */

@media (max-width: 800px) {
  .pillars,
  .connect {
    grid-template-columns: 1fr;
  }

  .hero-image {
    height: min(62vh, 28rem);
    object-position: center 48%;
  }

  .section {
    width: min(var(--wide), calc(100% - 2rem));
    padding-top: 3.25rem;
  }

  .section:last-of-type {
    padding-bottom: 3.4rem;
  }
}

@media (max-width: 640px) {
  body {
    font-size: 1.05rem;
  }

  .site-header {
    padding: 0.65rem 1rem 0.75rem;
    justify-content: center;
  }

  .brand-name {
    font-size: 0.98rem;
  }

  .site-nav {
    width: 100%;
    justify-content: center;
    gap: 0.25rem 0.9rem;
    font-size: 0.86rem;
  }

  .hero-image {
    height: auto;
    min-height: 0;
    max-height: none;
    aspect-ratio: 16 / 9;
    object-fit: cover;
    object-position: center center;
  }

  .hero-fade {
    height: 2.6rem;
  }
}

@media (prefers-reduced-motion: reduce) {
  html,
  html:focus-within {
    scroll-behavior: auto;
  }

  .button {
    transition: none;
  }
}
