@font-face {
  font-family: "Smiley Sans";
  src: url("./fonts/SmileySans-Oblique.woff2") format("woff2");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}

:root {
  --color-bg: #171918;
  --color-ink: #f2eee4;
  --color-muted: #a9b0ad;
  --color-header: #242725;
  --color-panel: #202321;
  --color-accent: #d8c7a0;
  --color-teal: #8bc9c0;
  --shadow: 0 22px 58px rgba(0, 0, 0, 0.34);
  --page-x: clamp(18px, 4vw, 56px);
  --content: 1240px;
  --header-height: 68px;
}

* {
  box-sizing: border-box;
}

html {
  height: 100%;
  min-height: 100%;
  background: var(--color-bg);
}

body {
  height: 100vh;
  min-height: 100vh;
  margin: 0;
  overflow: hidden;
  color: var(--color-ink);
  font-family: "Smiley Sans", "PingFang SC", "Microsoft YaHei", sans-serif;
  background:
    radial-gradient(circle at 18% 8%, rgba(216, 199, 160, 0.1), transparent 28%),
    linear-gradient(180deg, #202321 0%, var(--color-bg) 58%, #101211 100%);
}

a {
  color: inherit;
  text-decoration: none;
}

.site-header {
  width: 100%;
  height: var(--header-height);
  padding: 0 var(--page-x);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  background: var(--color-header);
  border: 0;
  color: var(--color-muted);
  font-size: 18px;
  line-height: 1;
}

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

.blog-link {
  color: var(--color-teal);
}

.blog-link:hover {
  color: var(--color-accent);
}

.memorial {
  width: min(var(--content), calc(100vw - var(--page-x) - var(--page-x)));
  height: calc(100vh - var(--header-height));
  margin: 0 auto;
  padding: clamp(44px, 7vh, 78px) 0 clamp(74px, 10vh, 96px);
  display: flex;
  flex-direction: column;
  align-items: center;
}

h1 {
  max-width: 100%;
  margin: 0;
  color: var(--color-ink);
  font-size: clamp(28px, 3.45vw, 64px);
  font-weight: 400;
  line-height: 1;
  letter-spacing: 0;
  text-align: center;
  white-space: nowrap;
}

.image-stack {
  width: 100%;
  margin-top: clamp(30px, 6vh, 54px);
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: clamp(18px, 3vw, 34px);
  align-items: center;
}

.memory-image {
  display: block;
  width: 100%;
  height: auto;
  object-fit: contain;
  border: 1px solid rgba(242, 238, 228, 0.12);
  border-radius: 8px;
  background: var(--color-panel);
  box-shadow: var(--shadow);
  filter: brightness(0.82) saturate(0.9) contrast(0.98);
}

.signature {
  position: fixed;
  right: clamp(16px, 3vw, 34px);
  bottom: clamp(16px, 3vw, 28px);
  z-index: 2;
  max-width: calc(100vw - 32px);
  color: var(--color-muted);
  font-size: clamp(14px, 1.6vw, 18px);
  line-height: 1;
  text-align: right;
}

@media (max-width: 720px) {
  :root {
    --header-height: 58px;
  }

  .site-header {
    font-size: 16px;
  }

  .memorial {
    width: calc(100vw - 32px);
    padding-top: 44px;
    padding-bottom: 78px;
  }

  h1 {
    font-size: clamp(20px, 6.4vw, 34px);
    text-align: left;
    white-space: normal;
  }

  .image-stack {
    grid-template-columns: 1fr;
    margin-top: 30px;
    gap: 18px;
  }
}
