:root {
  --color-bg: #faf7f2;
  --color-text: #2e2b28;
  --color-muted: #6b655d;
  --color-rule: #d8d0c4;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  background: var(--color-bg);
  color: var(--color-text);
  font-family: Georgia, "Times New Roman", serif;
  line-height: 1.6;
}

.page {
  max-width: 640px;
  margin: 0 auto;
  padding: 4rem 1.5rem 5rem;
}

.header {
  text-align: center;
  margin-bottom: 3rem;
}

.headshot {
  width: 400px;
  height: 400px;
  object-fit: cover;
  border-radius: 50%;
  margin-bottom: 1.5rem;
}

.name {
  font-size: 2rem;
  font-weight: normal;
  letter-spacing: 0.02em;
  margin: 0 0 0.5rem;
}

.dates {
  color: var(--color-muted);
  font-size: 1.05rem;
  margin: 0;
}

.obituary {
  font-size: 1.1rem;
}

.obituary p {
  margin: 0 0 1.25rem;
}

.service-details {
  display: grid;
  grid-template-columns: 80px 1fr;
  column-gap: 1.5rem;
}

.service {
  display: grid;
  grid-template-columns: subgrid;
  grid-column: 1 / -1;
  margin-bottom: 2rem;
  padding-bottom: 2rem;
  border-bottom: 1px solid var(--color-rule);
}

.first {
  padding-top: 2rem;
  border-top: 1px solid var(--color-rule);
}

.service h2,
.extra h2 {
  font-size: 1.1rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--color-muted);
  margin: 0 0 1rem;

  white-space: nowrap;
}

.service-facts {
  display: grid;
  grid-template-columns: subgrid;
  grid-column: 1 / -1;
  row-gap: 0.4rem;
  column-gap: 1.5rem;
  margin: 0;
}

.service-facts dt {
  color: var(--color-muted);
  margin-left: 12px;
}

.service-facts dd {
  margin: 0;
  text-align: left;
}

.rsvp {
    grid-column: 2;
    grid-row: 1;
    justify-self: end;

    margin: 0;
}

.rsvp a {
    background: white;
    border: 1px solid black;
    border-radius: 4px;
    padding: 8px 12px;
    text-decoration: underline;
    font-weight: bold;
}

.service-note-dancing {
    grid-column: 1 / -1;
    margin-top: 2rem;
    max-width: 300px;
}

.obituary + .extra {
  margin-top: 3rem;
  padding-top: 2rem;
  border-top: 1px solid var(--color-rule);
}

.extra {
  text-align: center;
}

.extra p {
  margin: 0 auto 1rem;
  max-width: 450px;
}

.extra a,
section a {
  color: var(--color-text);
}

.extra + .extra {
  margin-top: 2rem;
  padding-top: 2rem;
  border-top: 1px solid var(--color-rule);
}

@media (max-width: 480px) {
  .page {
    padding: 3rem 1.25rem 4rem;
  }
  .name {
    font-size: 1.6rem;
  }
}

.schedules {
    justify-self: start;
    margin-bottom: 0;;
}

section ul {
    justify-self: start;
}