/* Deacon Bruck. Change colours here. */
:root {
  --navy: #122670;
  --gold: #f5a91f;
  --gold-deep: #8a5300;   /* amber dark enough to read on ivory */
  --ivory: #faf6ec;
  --white: #fffdf8;
  --ink: #1b2442;
  --muted: #565a6c;
  --line: #e4dac3;
  --name: "Cinzel", "Cardo", Georgia, serif;
  --serif: "Cardo", "Iowan Old Style", Georgia, serif;
}

@font-face { font-family: "Cardo"; src: url("fonts/cardo-regular.woff") format("woff"); font-weight: 400; font-display: swap; }
@font-face { font-family: "Cardo"; src: url("fonts/cardo-italic.woff") format("woff"); font-style: italic; font-weight: 400; font-display: swap; }

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; text-size-adjust: 100%; background: var(--ivory); }
body { margin: 0; font-family: var(--serif); color: var(--ink); line-height: 1.7; }
h1, h2, p, ul { margin: 0; }
ul { padding: 0; list-style: none; }

.page { min-height: 100vh; min-height: 100svh; display: flex; flex-direction: column; }

/* Introduction */
.intro {
  background: var(--navy);
  color: var(--ivory);
  text-align: center;
  padding: calc(2rem + env(safe-area-inset-top)) 1.5rem 1.75rem;
}
.portrait {
  display: block;
  width: 7.5rem;
  height: 7.5rem;
  margin: 0 auto 1rem;
  border-radius: 50%;
  object-fit: cover;
  border: 2px solid var(--gold);
  padding: 5px;
}
h1 { font-family: var(--name); font-size: clamp(1.85rem, 9vw, 2.6rem); font-weight: 700; line-height: 1.2; text-wrap: balance; }
.subtitle { color: var(--gold); font-size: 1.1rem; margin-top: .35rem; letter-spacing: .02em; }
.bio { font-style: italic; font-size: 1.2rem; line-height: 1.5; max-width: 19rem; margin: .8rem auto 0; text-wrap: balance; }

/* Interlaced band, inspired by the headpieces of Ge'ez manuscripts */
.band { height: 24px; flex: none; background: var(--navy) url("images/band.svg") repeat-x center; }

.content { flex: 1; display: flex; flex-direction: column; padding: 1.75rem 1.25rem calc(1.5rem + env(safe-area-inset-bottom)); }
main { width: 100%; max-width: 34rem; margin: 0 auto; }

/* Social links */
.socials { display: grid; grid-template-columns: 1fr 1fr; gap: .75rem; }
.social {
  display: flex;
  align-items: center;
  gap: .75rem;
  min-height: 3.75rem;
  padding: .5rem 1.1rem;
  border-radius: 999px;
  background: var(--white);
  border: 1px solid var(--line);
  color: var(--navy);
  text-decoration: none;
  font-size: 1.15rem;
  -webkit-tap-highlight-color: transparent;
  transition: background-color .25s, color .25s, border-color .25s, transform .25s;
}
.icon { width: 1.35rem; height: 1.35rem; flex: none; fill: currentColor; color: var(--gold-deep); transition: color .25s; }
@media (hover: hover) {
  .social:hover { background: var(--navy); border-color: var(--navy); color: var(--ivory); transform: translateY(-2px); }
  .social:hover .icon { color: var(--gold); }
}
.social:active { background: var(--navy); color: var(--ivory); transform: scale(.98); }
.social:active .icon { color: var(--gold); }
.social:focus-visible { outline: 3px solid var(--gold-deep); outline-offset: 3px; }

/* About */
.about { margin-top: 2.75rem; padding: 0 .25rem; }
h2 { color: var(--navy); font-size: 1.75rem; font-weight: 400; line-height: 1.2; margin-bottom: .75rem; }
h2::after { content: ""; display: block; width: 2.5rem; height: 2px; margin-top: .6rem; background: var(--gold); }
.about p { font-size: 1.125rem; }
.about p + p { margin-top: 1rem; }

.about p.closing { margin-top: 2rem; font-family: var(--name); font-weight: 700; font-size: 1.15rem; line-height: 1.6; color: var(--navy); text-align: center; text-wrap: balance; }

footer { margin-top: auto; padding-top: 2.5rem; text-align: center; color: var(--muted); font-size: .95rem; }

.visually-hidden { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }

/* Very narrow phones */
@media (max-width: 22.4rem) { .socials { grid-template-columns: 1fr; } }

/* Desktop: the introduction becomes a navy side panel */
@media (min-width: 60rem) {
  .page { display: grid; grid-template-columns: minmax(24rem, 42%) 24px 1fr; align-items: stretch; }
  .intro { position: sticky; top: 0; height: 100vh; display: flex; overflow: auto; padding: 2rem; }
  .intro-inner { margin: auto; }
  .portrait { width: 13rem; height: 13rem; margin-bottom: 1.75rem; padding: 7px; }
  h1 { font-size: clamp(2.2rem, 3.6vw, 3.4rem); }
  .subtitle { font-size: 1.25rem; }
  .bio { font-size: 1.4rem; max-width: 22rem; margin-top: 1.25rem; }
  .band { position: sticky; top: 0; height: 100vh; background-image: url("images/band-vertical.svg"); background-repeat: repeat-y; }
  .content { justify-content: center; padding: 4rem 3rem 2rem; }
  main { margin: auto; }
  .social { min-height: 4.25rem; padding-inline: 1.5rem; }
  .about { margin-top: 3.5rem; }
  .about p { font-size: 1.2rem; }
  footer { margin-top: 0; }
}

/* One quiet entrance on load */
@media (prefers-reduced-motion: no-preference) {
  .intro-inner { animation: arrive .8s ease-out both; }
  .band { animation: weave 1.2s .2s ease-out both; }
  @keyframes arrive { from { opacity: .001; transform: translateY(8px); } }
  @keyframes weave { from { clip-path: inset(0 50%); } to { clip-path: inset(0); } }
  @media (min-width: 60rem) {
    .band { animation-name: unroll; }
    @keyframes unroll { from { clip-path: inset(0 0 100% 0); } to { clip-path: inset(0); } }
  }
}
@media (prefers-reduced-motion: reduce) { .social, .icon { transition: none; } }
