:root {
  color-scheme: light;
  --ink: #24302f;
  --muted: #5c6966;
  --paper: #fffaf2;
  --paper-strong: #fff4df;
  --sun: #f6b94d;
  --coral: #df6b57;
  --leaf: #3f7d68;
  --sky: #d9eff2;
  --blue: #2f5c80;
  --line: rgba(36, 48, 47, 0.14);
  --shadow: 0 18px 48px rgba(62, 51, 31, 0.16);
  --radius: 8px;
  --header-height: 65px;
  font-family:
    Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI",
    sans-serif;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  line-height: 1.6;
}

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

a {
  color: inherit;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 10;
  min-height: var(--header-height);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  padding: 14px clamp(18px, 4vw, 56px);
  background: rgba(255, 250, 242, 0.9);
  border-bottom: 1px solid var(--line);
  backdrop-filter: blur(14px);
}

.brand,
.nav-links,
.hero-actions,
.card-actions,
.form-footer,
.split-heading {
  display: flex;
  align-items: center;
}

.brand {
  gap: 10px;
  min-width: 0;
  font-weight: 800;
  text-decoration: none;
}

.brand-mark {
  width: 18px;
  height: 18px;
  flex: 0 0 auto;
  border-radius: 50%;
  background:
    linear-gradient(135deg, var(--sun), var(--coral) 52%, var(--leaf) 53%),
    var(--sun);
  box-shadow: 0 0 0 4px rgba(246, 185, 77, 0.2);
}

.nav-links {
  gap: clamp(12px, 3vw, 28px);
  color: var(--muted);
  font-size: 0.95rem;
  font-weight: 700;
}

.nav-links a,
.text-link,
.site-footer a {
  text-decoration: none;
}

.nav-links a:hover,
.text-link:hover,
.site-footer a:hover {
  color: var(--coral);
}

.hero {
  position: relative;
  min-height: calc(86vh - var(--header-height));
  display: grid;
  align-items: end;
  overflow: hidden;
  background: #f8d982;
}

.hero-media {
  position: absolute;
  inset: 0;
}

.hero-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center 45%;
}

.hero::after {
  content: "";
  position: absolute;
  inset: 0;
  background:
    linear-gradient(90deg, rgba(36, 48, 47, 0.72), rgba(36, 48, 47, 0.28) 50%, rgba(36, 48, 47, 0.04)),
    linear-gradient(0deg, rgba(255, 250, 242, 0.96), rgba(255, 250, 242, 0) 34%);
}

.hero-content {
  position: relative;
  z-index: 1;
  width: min(720px, calc(100% - 36px));
  margin: 0 0 clamp(70px, 11vh, 120px) clamp(18px, 7vw, 96px);
  color: white;
  text-shadow: 0 2px 18px rgba(0, 0, 0, 0.22);
}

.eyebrow {
  margin: 0 0 10px;
  color: var(--coral);
  font-size: 0.78rem;
  font-weight: 850;
  letter-spacing: 0;
  text-transform: uppercase;
}

.hero .eyebrow {
  color: #ffe08a;
}

h1,
h2,
h3,
p {
  overflow-wrap: anywhere;
}

h1,
h2,
h3 {
  margin: 0;
  line-height: 1.04;
}

h1 {
  font-size: clamp(3rem, 12vw, 7.8rem);
}

h2 {
  font-size: clamp(2rem, 5vw, 4.1rem);
}

h3 {
  font-size: 1.18rem;
}

.hero-dates {
  margin: 12px 0 0;
  font-size: clamp(1.1rem, 3vw, 1.6rem);
  font-weight: 800;
}

.hero-copy {
  max-width: 620px;
  margin: 22px 0 0;
  font-size: clamp(1.05rem, 2vw, 1.28rem);
}

.hero-actions {
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 30px;
}

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  padding: 11px 18px;
  border: 1px solid transparent;
  border-radius: var(--radius);
  font-weight: 850;
  text-decoration: none;
  cursor: pointer;
}

.button-primary {
  background: var(--coral);
  color: white;
  box-shadow: 0 10px 24px rgba(122, 51, 38, 0.24);
}

.button-primary:hover {
  background: #c85745;
}

.button-secondary {
  background: rgba(255, 255, 255, 0.9);
  color: var(--ink);
}

.button-light {
  background: #fff;
  border-color: var(--line);
  color: var(--blue);
}

.section {
  padding: clamp(58px, 9vw, 108px) 0;
}

.section-inner {
  width: min(1160px, calc(100% - 36px));
  margin: 0 auto;
}

.section-intro {
  background: var(--paper);
  padding-top: 42px;
}

.intro-grid,
.story-layout,
.form-layout {
  display: grid;
  grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.1fr);
  gap: clamp(30px, 7vw, 82px);
}

.intro-grid p,
.section-heading p,
.form-layout > div > p {
  color: var(--muted);
  font-size: 1.08rem;
}

.story-copy p {
  color: var(--muted);
  font-size: 1.06rem;
}

.details-panel {
  align-self: start;
  padding: 28px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: white;
  box-shadow: var(--shadow);
}

.details-panel dl {
  display: grid;
  gap: 16px;
  margin: 22px 0 0;
}

.details-panel dt {
  color: var(--coral);
  font-size: 0.78rem;
  font-weight: 850;
  text-transform: uppercase;
}

.details-panel dd {
  margin: 2px 0 0;
  color: var(--ink);
  font-weight: 750;
}

.photo-band {
  background: linear-gradient(180deg, var(--sky), #fef8ec);
}

.section-heading {
  max-width: 760px;
  margin-bottom: 28px;
}

.split-heading {
  max-width: none;
  justify-content: space-between;
  gap: 18px;
}

.text-link {
  color: var(--blue);
  font-weight: 850;
}

.photo-grid,
.tribute-grid,
.nonprofit-grid {
  display: grid;
  gap: 18px;
}

.photo-grid {
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

.photo-filters {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin: 0 0 12px;
}

.filter-button {
  min-height: 38px;
  padding: 8px 13px;
  border: 1px solid rgba(36, 48, 47, 0.18);
  border-radius: var(--radius);
  background: rgba(255, 255, 255, 0.78);
  color: var(--blue);
  font: inherit;
  font-size: 0.92rem;
  font-weight: 850;
  cursor: pointer;
}

.filter-button:hover,
.filter-button.is-active {
  border-color: var(--coral);
  background: var(--coral);
  color: white;
}

.gallery-count {
  min-height: 26px;
  margin: 0 0 18px;
  color: var(--muted);
  font-weight: 750;
}

.photo-card {
  margin: 0;
  overflow: hidden;
  border-radius: var(--radius);
  background: white;
  box-shadow: var(--shadow);
}

.photo-card img {
  width: 100%;
  aspect-ratio: 4 / 5;
  object-fit: cover;
}

.photo-card figcaption {
  padding: 14px;
  color: var(--muted);
  font-weight: 750;
}

.tribute-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.tribute-card,
.nonprofit-card {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: white;
  box-shadow: var(--shadow);
}

.tribute-card {
  padding: 26px;
}

.tribute-message {
  margin: 0 0 20px;
  color: var(--ink);
  font-size: 1.08rem;
}

.tribute-name {
  margin: 0;
  font-weight: 850;
}

.tribute-relationship {
  margin: 2px 0 0;
  color: var(--muted);
}

.donate-band {
  background: #f9eabf;
}

.nonprofit-grid {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.nonprofit-card {
  display: flex;
  min-width: 0;
  flex-direction: column;
  padding: 18px;
}

.nonprofit-image {
  display: grid;
  min-height: 150px;
  place-items: center;
  margin-bottom: 18px;
  border-radius: var(--radius);
  background: var(--paper-strong);
}

.nonprofit-image img {
  width: 112px;
  height: 112px;
}

.nonprofit-card p {
  flex: 1;
  color: var(--muted);
}

.card-actions {
  flex-wrap: wrap;
  gap: 10px;
}

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

.tribute-form {
  display: grid;
  gap: 16px;
  padding: 24px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: white;
  box-shadow: var(--shadow);
}

.field-group {
  display: grid;
  gap: 7px;
}

label {
  color: var(--ink);
  font-weight: 850;
}

label span {
  color: var(--muted);
  font-weight: 650;
}

input,
textarea {
  width: 100%;
  border: 1px solid rgba(36, 48, 47, 0.2);
  border-radius: var(--radius);
  padding: 12px 13px;
  color: var(--ink);
  font: inherit;
  background: #fffdfa;
}

textarea {
  resize: vertical;
}

input:focus,
textarea:focus {
  outline: 3px solid rgba(246, 185, 77, 0.45);
  border-color: var(--coral);
}

.checkbox-row {
  display: grid;
  grid-template-columns: 20px minmax(0, 1fr);
  gap: 10px;
  align-items: start;
  color: var(--muted);
  font-weight: 650;
}

.checkbox-row input {
  width: 18px;
  height: 18px;
  margin-top: 4px;
}

.form-footer {
  flex-wrap: wrap;
  gap: 14px;
}

.form-status {
  min-height: 24px;
  margin: 0;
  color: var(--muted);
  font-weight: 750;
}

.form-status.is-warning {
  color: #9a4f13;
}

.site-footer {
  display: flex;
  justify-content: space-between;
  gap: 18px;
  padding: 28px clamp(18px, 4vw, 56px);
  background: var(--ink);
  color: white;
}

.site-footer p {
  margin: 0;
}

@media (max-width: 860px) {
  :root {
    --header-height: 113px;
  }

  .site-header {
    align-items: flex-start;
    flex-direction: column;
  }

  .nav-links {
    width: 100%;
    overflow-x: auto;
    padding-bottom: 2px;
  }

  .hero {
    min-height: 780px;
  }

  .hero::after {
    background:
      linear-gradient(180deg, rgba(36, 48, 47, 0.62), rgba(36, 48, 47, 0.26) 48%, rgba(255, 250, 242, 0.94)),
      linear-gradient(0deg, rgba(255, 250, 242, 0.98), rgba(255, 250, 242, 0) 30%);
  }

  .hero-content {
    margin: 0 auto 76px;
  }

  .intro-grid,
  .story-layout,
  .form-layout,
  .tribute-grid,
  .nonprofit-grid {
    grid-template-columns: 1fr;
  }

  .photo-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 540px) {
  .hero {
    min-height: 720px;
  }

  .hero-actions,
  .button {
    width: 100%;
  }

  .photo-grid {
    grid-template-columns: 1fr;
  }

  .split-heading,
  .site-footer {
    align-items: flex-start;
    flex-direction: column;
  }
}
