/* [project]/app/globals.css [app-client] (css) */
@layer properties {
  @supports (((-webkit-hyphens: none)) and (not (margin-trim: inline))) or ((-moz-orient: inline) and (not (color: rgb(from red r g b)))) {
    *, :before, :after, ::backdrop {
      --tw-rotate-x: initial;
      --tw-rotate-y: initial;
      --tw-rotate-z: initial;
      --tw-skew-x: initial;
      --tw-skew-y: initial;
    }
  }
}

@layer theme {
  :root, :host {
    --font-sans: ui-sans-serif, system-ui, sans-serif, "Apple Color Emoji",
      "Segoe UI Emoji", "Segoe UI Symbol", "Noto Color Emoji";
    --font-mono: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono",
      "Courier New", monospace;
    --spacing: .25rem;
    --default-font-family: var(--font-sans);
    --default-mono-font-family: var(--font-mono);
  }
}

@layer base {
  *, :after, :before, ::backdrop {
    box-sizing: border-box;
    border: 0 solid;
    margin: 0;
    padding: 0;
  }

  ::file-selector-button {
    box-sizing: border-box;
    border: 0 solid;
    margin: 0;
    padding: 0;
  }

  html, :host {
    -webkit-text-size-adjust: 100%;
    tab-size: 4;
    line-height: 1.5;
    font-family: var(--default-font-family, ui-sans-serif, system-ui, sans-serif, "Apple Color Emoji", "Segoe UI Emoji", "Segoe UI Symbol", "Noto Color Emoji");
    font-feature-settings: var(--default-font-feature-settings, normal);
    font-variation-settings: var(--default-font-variation-settings, normal);
    -webkit-tap-highlight-color: transparent;
  }

  hr {
    height: 0;
    color: inherit;
    border-top-width: 1px;
  }

  abbr:where([title]) {
    -webkit-text-decoration: underline dotted;
    text-decoration: underline dotted;
  }

  h1, h2, h3, h4, h5, h6 {
    font-size: inherit;
    font-weight: inherit;
  }

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

  b, strong {
    font-weight: bolder;
  }

  code, kbd, samp, pre {
    font-family: var(--default-mono-font-family, ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace);
    font-feature-settings: var(--default-mono-font-feature-settings, normal);
    font-variation-settings: var(--default-mono-font-variation-settings, normal);
    font-size: 1em;
  }

  small {
    font-size: 80%;
  }

  sub, sup {
    vertical-align: baseline;
    font-size: 75%;
    line-height: 0;
    position: relative;
  }

  sub {
    bottom: -.25em;
  }

  sup {
    top: -.5em;
  }

  table {
    text-indent: 0;
    border-color: inherit;
    border-collapse: collapse;
  }

  :-moz-focusring {
    outline: auto;
  }

  progress {
    vertical-align: baseline;
  }

  summary {
    display: list-item;
  }

  ol, ul, menu {
    list-style: none;
  }

  img, svg, video, canvas, audio, iframe, embed, object {
    vertical-align: middle;
    display: block;
  }

  img, video {
    max-width: 100%;
    height: auto;
  }

  button, input, select, optgroup, textarea {
    font: inherit;
    font-feature-settings: inherit;
    font-variation-settings: inherit;
    letter-spacing: inherit;
    color: inherit;
    opacity: 1;
    background-color: #0000;
    border-radius: 0;
  }

  ::file-selector-button {
    font: inherit;
    font-feature-settings: inherit;
    font-variation-settings: inherit;
    letter-spacing: inherit;
    color: inherit;
    opacity: 1;
    background-color: #0000;
    border-radius: 0;
  }

  :where(select:is([multiple], [size])) optgroup {
    font-weight: bolder;
  }

  :where(select:is([multiple], [size])) optgroup option {
    padding-inline-start: 20px;
  }

  ::file-selector-button {
    margin-inline-end: 4px;
  }

  ::placeholder {
    opacity: 1;
  }

  @supports (not ((-webkit-appearance: -apple-pay-button))) or (contain-intrinsic-size: 1px) {
    ::placeholder {
      color: currentColor;
    }

    @supports (color: color-mix(in lab, red, red)) {
      ::placeholder {
        color: color-mix(in oklab, currentcolor 50%, transparent);
      }
    }
  }

  textarea {
    resize: vertical;
  }

  ::-webkit-search-decoration {
    -webkit-appearance: none;
  }

  ::-webkit-date-and-time-value {
    min-height: 1lh;
    text-align: inherit;
  }

  ::-webkit-datetime-edit {
    display: inline-flex;
  }

  ::-webkit-datetime-edit-fields-wrapper {
    padding: 0;
  }

  ::-webkit-datetime-edit {
    padding-block: 0;
  }

  ::-webkit-datetime-edit-year-field {
    padding-block: 0;
  }

  ::-webkit-datetime-edit-month-field {
    padding-block: 0;
  }

  ::-webkit-datetime-edit-day-field {
    padding-block: 0;
  }

  ::-webkit-datetime-edit-hour-field {
    padding-block: 0;
  }

  ::-webkit-datetime-edit-minute-field {
    padding-block: 0;
  }

  ::-webkit-datetime-edit-second-field {
    padding-block: 0;
  }

  ::-webkit-datetime-edit-millisecond-field {
    padding-block: 0;
  }

  ::-webkit-datetime-edit-meridiem-field {
    padding-block: 0;
  }

  ::-webkit-calendar-picker-indicator {
    line-height: 1;
  }

  :-moz-ui-invalid {
    box-shadow: none;
  }

  button, input:where([type="button"], [type="reset"], [type="submit"]) {
    appearance: button;
  }

  ::file-selector-button {
    appearance: button;
  }

  ::-webkit-inner-spin-button {
    height: auto;
  }

  ::-webkit-outer-spin-button {
    height: auto;
  }

  [hidden]:where(:not([hidden="until-found"])) {
    display: none !important;
  }
}

@layer components;

@layer utilities {
  .sr-only {
    clip-path: inset(50%);
    white-space: nowrap;
    border-width: 0;
    width: 1px;
    height: 1px;
    margin: -1px;
    padding: 0;
    position: absolute;
    overflow: hidden;
  }

  .start {
    inset-inline-start: var(--spacing);
  }

  .hidden {
    display: none;
  }

  .table {
    display: table;
  }

  .transform {
    transform: var(--tw-rotate-x, ) var(--tw-rotate-y, ) var(--tw-rotate-z, ) var(--tw-skew-x, ) var(--tw-skew-y, );
  }
}

:root {
  --paper: #ece4d8;
  --paper-deep: #ded2c3;
  --cream: #fffbf4;
  --ink: #342f2b;
  --muted: #6f665f;
  --terracotta: #9f513e;
  --terracotta-dark: #793b2d;
  --sage: #68755f;
  --line: #483a3029;
  --shadow: 0 22px 70px #3d2d2224;
  --glass-bg: #fffbf49e;
  --glass-bg-strong: #fffbf4d1;
  --glass-bg-soft: #fffbf470;
  --glass-border: #fff9;
  --glass-border-soft: #fff6;
  --glass-blur: blur(24px) saturate(180%);
  --glass-blur-strong: blur(40px) saturate(180%);
  --glass-shadow: 0 8px 32px #4332231a;
  --font-ui: "Microsoft YaHei UI", "PingFang SC", "Microsoft YaHei",
    "Noto Sans CJK SC", Arial, sans-serif;
  --font-reading: "Kaiti SC", STKaiti, KaiTi, "KaiTi_GB2312", "FZKai-Z03",
    "Noto Serif CJK SC", SimSun, serif;
  --font-editorial: "Iowan Old Style", "Palatino Linotype", "Book Antiqua",
    Georgia, "Times New Roman", serif;
}

* {
  box-sizing: border-box;
}

html {
  background: var(--paper);
}

body {
  background: radial-gradient(circle at 18% 3%, #fffcf6e6, transparent 28rem),
    var(--paper);
  color: var(--ink);
  font-family: var(--font-ui);
  margin: 0;
}

button, input, textarea, select {
  color: inherit;
  font: inherit;
}

button {
  cursor: pointer;
  border: 0;
}

.app-shell {
  min-height: 100vh;
}

.topbar {
  -webkit-backdrop-filter: blur(20px) saturate(160%);
  z-index: 10;
  background: #fffbf4d6;
  border-bottom: 1px solid #795c461a;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  height: 72px;
  padding: 0 clamp(24px, 5vw, 80px);
  display: grid;
  position: sticky;
  top: 0;
}

.brand {
  text-align: left;
  background: none;
  justify-self: start;
  align-items: center;
  gap: 12px;
  padding: 0;
  display: flex;
}

.brand-mark {
  background: var(--terracotta);
  color: #fff;
  border-radius: 50% 50% 46% 54%;
  justify-content: center;
  align-items: center;
  width: 34px;
  height: 34px;
  font-family: Songti SC, Noto Serif CJK SC, serif;
  font-size: 16px;
  display: flex;
  transform: rotate(-5deg);
}

.brand strong, .brand small {
  display: block;
}

.brand strong {
  letter-spacing: .16em;
  font-family: Songti SC, Noto Serif CJK SC, serif;
  font-size: 16px;
}

.brand small {
  color: var(--muted);
  letter-spacing: .08em;
  margin-top: 1px;
  font-size: 11px;
}

.main-nav {
  align-items: center;
  gap: 20px;
  display: flex;
}

.main-nav button {
  color: var(--muted);
  background: none;
  padding: 8px 4px;
  font-size: 13px;
  position: relative;
}

.main-nav button:after {
  background: var(--terracotta);
  content: "";
  border-radius: 2px;
  width: 18px;
  height: 2px;
  transition: transform .18s;
  position: absolute;
  bottom: 3px;
  left: 50%;
  transform: translateX(-50%)scaleX(0);
}

.main-nav button.active {
  color: var(--ink);
}

.main-nav button.active:after {
  transform: translateX(-50%)scaleX(1);
}

.header-actions {
  justify-self: end;
  align-items: center;
  gap: 10px;
  display: flex;
}

.admin-entry-button {
  color: var(--muted);
  background: none;
  border: 1px solid #9a6d583d;
  border-radius: 999px;
  padding: 9px 14px;
  font-size: 11px;
  transition: background .16s, border-color .16s, color .16s;
}

.admin-entry-button:hover {
  color: var(--terracotta-dark);
  background: #bd6f5212;
  border-color: #9a6d586b;
}

.admin-mode-badge {
  color: var(--terracotta-dark);
  letter-spacing: .08em;
  background: #bd6f521a;
  border-radius: 999px;
  padding: 7px 10px;
  font-size: 11px;
}

.primary-button {
  background: var(--terracotta);
  color: #fff;
  border-radius: 999px;
  justify-content: center;
  align-items: center;
  gap: 6px;
  padding: 10px 16px;
  font-size: 12px;
  transition: background .16s, transform .16s;
  display: inline-flex;
}

.primary-button:hover {
  background: var(--terracotta-dark);
  transform: translateY(-1px);
}

.primary-button:disabled {
  cursor: not-allowed;
  opacity: .55;
  transform: none;
}

.hero {
  grid-template-columns: minmax(360px, .88fr) minmax(420px, 1.12fr);
  align-items: center;
  gap: clamp(18px, 2.5vw, 38px);
  max-width: 1280px;
  min-height: clamp(330px, 40vh, 440px);
  margin: 0 auto;
  padding: 28px clamp(28px, 7vw, 110px);
  display: grid;
  position: relative;
}

.hero:before {
  content: "";
  border: 1px solid #bd6f5224;
  border-radius: 50%;
  width: 310px;
  height: 310px;
  position: absolute;
  top: -94px;
  left: -100px;
}

.eyebrow {
  color: var(--terracotta);
  letter-spacing: .24em;
  text-transform: uppercase;
  margin: 0 0 18px;
  font-size: 12px;
  font-weight: 700;
}

.hero h1 {
  letter-spacing: -.05em;
  margin: 0;
  font-family: Songti SC, Noto Serif CJK SC, serif;
  font-size: clamp(42px, 4.8vw, 64px);
  font-weight: 500;
  line-height: 1.16;
}

.hero-copy {
  z-index: 2;
  max-width: 540px;
  padding-left: clamp(0px, 1vw, 14px);
  position: relative;
}

.hero-elements {
  filter: drop-shadow(0 22px 24px #5b43301c);
  object-fit: contain;
  object-position: center;
  opacity: .96;
  pointer-events: none;
  width: 100%;
  height: clamp(260px, 29vw, 350px);
  transform: rotate(.5deg);
}

.hero h1 em {
  color: var(--terracotta);
  font-style: normal;
  position: relative;
}

.hero h1 em:after {
  content: "";
  background: #bd6f5242;
  width: 92%;
  height: 8px;
  position: absolute;
  bottom: -8px;
  left: 4%;
  transform: rotate(-1deg);
}

.hero-note {
  color: var(--muted);
  max-width: 460px;
  margin: 16px 0 0;
  font-family: Songti SC, Noto Serif CJK SC, serif;
  font-size: 16px;
  line-height: 1.9;
}

.memory-section {
  background: linear-gradient(#f8f3eb 0%, #eee6da 100%);
  border-radius: 18px 18px 0 0;
  min-height: 520px;
  padding: 56px clamp(28px, 7vw, 110px) 110px;
  position: relative;
  box-shadow: 0 -10px 40px #4937270d;
}

.section-heading {
  justify-content: space-between;
  align-items: end;
  max-width: 1160px;
  margin: 0 auto 38px;
  display: flex;
}

.section-heading .eyebrow {
  margin-bottom: 9px;
}

.section-heading h2, .section-intro h1 {
  margin: 0;
  font-family: Songti SC, Noto Serif CJK SC, serif;
  font-size: clamp(30px, 4vw, 46px);
  font-weight: 500;
}

.text-button {
  color: var(--terracotta);
  background: none;
  padding: 8px 0;
  font-size: 12px;
}

.memory-timeline {
  max-width: 1160px;
  margin: 0 auto;
  position: relative;
}

.memory-timeline:before {
  content: "";
  background: linear-gradient(#bd6f522e, #9a6d588c 8%, #9a6d5852 92%, #bd6f5214);
  width: 1px;
  position: absolute;
  top: 10px;
  bottom: 16px;
  left: 127px;
}

.timeline-entry {
  grid-template-columns: 102px 52px minmax(0, 1fr);
  min-width: 0;
  padding-bottom: 70px;
  scroll-margin-top: 110px;
  display: grid;
  position: relative;
}

.timeline-entry:last-child {
  padding-bottom: 12px;
}

.timeline-month-spacer {
  display: block;
}

.timeline-month-card {
  color: #fffdf8;
  text-align: center;
  background: #884838;
  border: 0;
  border-radius: 7px;
  align-self: start;
  margin-top: 10px;
  padding: 11px 10px 10px;
  box-shadow: 0 9px 22px #43322321;
}

.timeline-month-card strong, .timeline-month-card small {
  display: block;
}

.timeline-month-card strong {
  letter-spacing: .04em;
  font-family: Songti SC, Noto Serif CJK SC, serif;
  font-size: 18px;
  font-weight: 500;
}

.timeline-month-card small {
  color: #ffffffdb;
  letter-spacing: .08em;
  border-top: 1px solid #ffffff6b;
  margin-top: 5px;
  padding-top: 5px;
  font-size: 9px;
}

.timeline-tone-1 .timeline-month-card {
  color: #fffdf8;
  background: #5f746c;
}

.timeline-tone-2 .timeline-month-card {
  color: #fffdf8;
  background: #934a39;
}

.timeline-tone-3 .timeline-month-card {
  color: #fffdf8;
  background: #697257;
}

.timeline-rail-node {
  z-index: 2;
  justify-content: center;
  align-items: center;
  padding-top: 25px;
  display: flex;
  position: relative;
}

.timeline-rail-node:before {
  border: 3px solid var(--cream);
  color: #884838;
  content: "";
  background: currentColor;
  border-radius: 50%;
  width: 11px;
  height: 11px;
  box-shadow: 0 0 0 1px;
}

.timeline-rail-node i {
  display: none;
}

.timeline-tone-1 .timeline-rail-node:before {
  color: #5f746c;
}

.timeline-tone-2 .timeline-rail-node:before {
  color: #934a39;
}

.timeline-tone-3 .timeline-rail-node:before {
  color: #697257;
}

.timeline-month-start .timeline-rail-node:before {
  width: 15px;
  height: 15px;
}

.timeline-memory {
  --letter-margin: 47px;
  background: linear-gradient(90deg,
      transparent 0 var(--letter-margin),
      #c3675a33 var(--letter-margin)
        calc(var(--letter-margin) + 1px),
      transparent calc(var(--letter-margin) + 1px)),
    repeating-linear-gradient(180deg,
      transparent 0 31px,
      #6685971a 31px 32px),
    linear-gradient(135deg, #fffdf8 0%, #faf3e9 100%);
  border: 1px solid #6f533e29;
  border-radius: 2px 8px 8px 2px;
  min-width: 0;
  padding: 24px 22px 32px 70px;
  position: relative;
  overflow: hidden;
  box-shadow: 0 18px 38px #49372717, 0 2px 3px #4937270d;
}

.timeline-memory:before {
  content: "";
  opacity: .75;
  background: repeating-linear-gradient(110deg, #9a6d5833 0 18px, #fffdf7e0 18px 34px);
  height: 12px;
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
}

.timeline-memory-header {
  z-index: 1;
  justify-content: space-between;
  align-items: flex-start;
  margin-bottom: 20px;
  display: flex;
  position: relative;
}

.timeline-memory-meta {
  flex-wrap: wrap;
  align-items: center;
  gap: 8px 18px;
  display: flex;
}

.timeline-memory-meta span {
  color: var(--muted);
  letter-spacing: .04em;
  align-items: center;
  gap: 6px;
  font-size: 12px;
  display: inline-flex;
}

.timeline-memory-header h3 {
  margin: 6px 0 0;
  font-family: Songti SC, Noto Serif CJK SC, serif;
  font-size: 25px;
  font-weight: 500;
}

.timeline-photo-group {
  text-align: left;
  background: none;
  align-items: center;
  width: 100%;
  min-height: 150px;
  padding: 5px 22px 10px 4px;
  display: flex;
  position: relative;
}

.timeline-photo {
  flex: 0 0 clamp(130px, 15vw, 190px);
  margin-right: -14px;
  transition: margin .22s, transform .22s;
  display: block;
  position: relative;
  transform: rotate(-1deg);
}

.timeline-photo:nth-child(2n) {
  transform: rotate(1.2deg)translateY(3px);
}

.timeline-photo-group:hover .timeline-photo {
  margin-right: 3px;
  transform: rotate(0)translateY(-2px);
}

.timeline-photo .photo-surface {
  aspect-ratio: 4 / 3;
  border: 4px solid #fffcf6eb;
  border-radius: 3px;
  box-shadow: 0 10px 25px #4332232b;
}

.timeline-photo-empty {
  color: var(--muted);
  background: #bd6f5212;
  border: 1px dashed #bd6f5257;
  justify-content: center;
  align-items: center;
  width: 174px;
  height: 112px;
  font-size: 13px;
  display: flex;
}

.timeline-photo-more {
  background: var(--ink);
  border: 3px solid var(--cream);
  color: #fff;
  z-index: 8;
  border-radius: 50%;
  justify-content: center;
  align-items: center;
  width: 34px;
  height: 34px;
  margin-left: -3px;
  font-size: 12px;
  display: flex;
  position: relative;
}

.timeline-story {
  color: #403934e6;
  max-width: 760px;
  margin: 0;
  font-family: Songti SC, Noto Serif CJK SC, serif;
  font-size: 15px;
  line-height: 1.9;
}

.timeline-memory-footer {
  border-top: 1px solid var(--line);
  align-items: center;
  gap: 12px;
  margin-top: 18px;
  padding-top: 13px;
  display: flex;
  position: relative;
}

.timeline-memory-footer > span {
  color: var(--muted);
  font-size: 12px;
}

.photo-surface {
  aspect-ratio: 4 / 3;
  background: #c5b4a2;
  border-radius: 5px;
  width: 100%;
  position: relative;
  overflow: hidden;
  box-shadow: 0 18px 50px #4332232b;
}

.photo-surface img {
  object-fit: cover;
  width: 100%;
  height: 100%;
  display: block;
}

.memory-placeholder {
  width: 100%;
  height: 100%;
  position: relative;
  overflow: hidden;
}

.placeholder-sun {
  filter: blur(2px);
  background: #ffebb48c;
  border-radius: 50%;
  width: 10%;
  height: 14%;
  position: absolute;
  top: 18%;
  right: 18%;
}

.placeholder-horizon {
  background: #ffffff24;
  width: 100%;
  height: 2px;
  position: absolute;
  top: 55%;
  left: 0;
}

.placeholder-figure {
  background: #32363594;
  border-radius: 50% 50% 20% 20%;
  width: 6%;
  height: 22%;
  position: absolute;
  bottom: 18%;
}

.figure-one {
  left: 36%;
}

.figure-two {
  left: 44%;
  transform: scale(.86);
}

.placeholder-grain {
  mix-blend-mode: overlay;
  opacity: .45;
  background-image: radial-gradient(#ffffff2b .7px, #0000 .7px);
  background-size: 5px 5px;
  position: absolute;
  inset: 0;
}

.placeholder-label {
  color: #ffffffd6;
  letter-spacing: .12em;
  text-align: left;
  font-family: Songti SC, serif;
  font-size: 12px;
  position: absolute;
  bottom: 16px;
  left: 18px;
}

.placeholder-label small {
  letter-spacing: 0;
  opacity: .72;
  margin-top: 3px;
  font-family: sans-serif;
  font-size: 8px;
  display: block;
}

.memory-comment-meta {
  align-items: center;
  gap: 6px;
  display: inline-flex;
}

.memory-comment-meta:before {
  background: var(--terracotta);
  content: "";
  opacity: .72;
  border-radius: 50%;
  width: 4px;
  height: 4px;
}

.avatars {
  display: flex;
}

.avatar {
  border: 2px solid var(--cream);
  color: #fff;
  border-radius: 50%;
  flex: none;
  justify-content: center;
  align-items: center;
  width: 34px;
  height: 34px;
  font-size: 11px;
  display: inline-flex;
}

.avatars .avatar + .avatar {
  margin-left: -8px;
}

.people-page {
  max-width: 1240px;
  margin: 0 auto;
  padding: 78px clamp(28px, 6vw, 80px) 110px;
}

.section-intro {
  max-width: none;
  margin-bottom: 48px;
}

.section-intro > p:last-child {
  color: var(--muted);
  max-width: 760px;
  margin-top: 20px;
  font-family: Songti SC, Noto Serif CJK SC, serif;
  font-size: 15px;
  line-height: 1.8;
}

.people-admin-panel {
  background: linear-gradient(120deg, #fffcf6fa, #f3eadecc);
  border: 1px solid #9f513e2e;
  border-radius: 12px;
  justify-content: space-between;
  align-items: flex-end;
  gap: 28px;
  margin-bottom: 28px;
  padding: 22px 24px;
  display: flex;
  box-shadow: 0 12px 32px #4937270f;
}

.people-admin-copy {
  align-items: center;
  gap: 13px;
  display: flex;
}

.people-admin-copy strong, .people-admin-copy small {
  display: block;
}

.people-admin-copy strong {
  color: var(--ink);
  margin-bottom: 4px;
  font-size: 15px;
}

.people-admin-copy small {
  color: var(--muted);
  font-size: 12px;
}

.people-admin-fields {
  flex: 0 560px;
  align-items: flex-end;
  gap: 10px;
  display: flex;
}

.people-admin-fields label {
  flex: 1;
}

.people-admin-fields label > span {
  color: var(--muted);
  margin: 0 0 7px 2px;
  font-size: 11px;
  display: block;
}

.people-admin-fields input {
  color: var(--ink);
  font: inherit;
  background: #fffdf8db;
  border: 1px solid #59463829;
  border-radius: 7px;
  outline: none;
  width: 100%;
  height: 42px;
  padding: 0 12px;
}

.people-admin-fields input:focus {
  border-color: #9f513e8c;
  box-shadow: 0 0 0 3px #9f513e14;
}

.people-admin-fields .people-initials-field {
  flex: 0 0 92px;
}

.people-admin-fields .primary-button {
  white-space: nowrap;
  height: 42px;
}

.people-grid {
  grid-template-columns: repeat(auto-fit, minmax(310px, 1fr));
  gap: 16px;
  display: grid;
}

.person-card-wrap {
  position: relative;
}

.person-card {
  text-align: left;
  background: linear-gradient(135deg, #fffdf8f5, #f7f0e6b8);
  border: 1px solid #9a6d581f;
  border-radius: 10px;
  align-items: center;
  width: 100%;
  min-height: 172px;
  padding: 25px 28px;
  transition: border-color .18s, box-shadow .18s, transform .18s;
  display: flex;
  position: relative;
  overflow: hidden;
  box-shadow: 0 10px 28px #4937270e;
}

.person-card:hover {
  border-color: #9a6d583d;
  transform: translateY(-3px);
  box-shadow: 0 16px 36px #49372717;
}

.person-portrait {
  color: #fff;
  border-radius: 50%;
  justify-content: center;
  align-items: center;
  width: 90px;
  height: 90px;
  margin-right: 22px;
  font-family: Songti SC, serif;
  font-size: 30px;
  display: flex;
  position: relative;
}

.person-portrait i {
  opacity: .5;
  border: 1px solid #ffffffa6;
  border-radius: 50%;
  width: 100px;
  height: 100px;
  position: absolute;
  transform: translate(5px, -4px);
}

.person-card-copy strong, .person-stats, .person-recent {
  display: block;
}

.person-card-copy strong {
  margin-bottom: 9px;
  font-family: Songti SC, serif;
  font-size: 25px;
}

.person-stats {
  color: var(--muted);
  align-items: center;
  gap: 8px;
  font-size: 11px;
  display: flex;
}

.person-stats i {
  background: var(--terracotta);
  opacity: .65;
  border-radius: 50%;
  width: 3px;
  height: 3px;
}

.person-recent {
  flex-wrap: wrap;
  gap: 5px;
  max-width: 280px;
  margin-top: 14px;
  display: flex;
}

.person-recent em {
  color: var(--muted);
  text-overflow: ellipsis;
  white-space: nowrap;
  background: #fffcf6b8;
  border: 1px solid #9a6d5826;
  max-width: 92px;
  padding: 4px 7px;
  font-size: 11px;
  font-style: normal;
  overflow: hidden;
}

.person-index {
  color: #3f383129;
  letter-spacing: .1em;
  font-family: Georgia, serif;
  font-size: 12px;
  position: absolute;
  top: 14px;
  right: 16px;
}

.person-delete-button {
  color: var(--terracotta);
  z-index: 2;
  background: #fffcf6f0;
  border: 1px solid #9f513e3d;
  border-radius: 999px;
  padding: 6px 11px;
  font-size: 11px;
  transition: background .16s, border-color .16s, color .16s;
  position: absolute;
  bottom: 14px;
  right: 14px;
}

.person-delete-button:hover {
  background: var(--terracotta);
  border-color: var(--terracotta);
  color: #fff;
}

.modal-backdrop {
  background: #2d2620a3;
  width: 100%;
  height: 100%;
  position: absolute;
  inset: 0;
}

.memory-modal, .create-modal {
  z-index: 50;
  position: fixed;
  inset: 0;
}

.create-modal {
  z-index: 60;
}

.confirm-modal {
  pointer-events: auto;
  z-index: 100;
  justify-content: center;
  align-items: center;
  display: flex;
  position: fixed;
  inset: 0;
}

.confirm-modal .modal-backdrop {
  z-index: 0;
}

.confirm-sheet {
  background: var(--cream);
  box-shadow: var(--shadow);
  z-index: 1;
  border-radius: 6px;
  width: 100%;
  max-width: min(420px, 100vw - 40px);
  padding: 34px 32px 28px;
  position: relative;
}

.confirm-sheet .eyebrow {
  margin-bottom: 8px;
}

.confirm-sheet h2 {
  margin: 0 0 12px;
  font-family: Songti SC, serif;
  font-size: 24px;
  font-weight: 500;
}

.confirm-sheet > p {
  color: var(--muted);
  margin: 0;
  font-size: 14px;
  line-height: 1.7;
}

.confirm-actions {
  justify-content: flex-end;
  gap: 14px;
  margin-top: 28px;
  display: flex;
}

.confirm-actions > button:first-child {
  color: var(--muted);
  background: none;
  font-size: 12px;
}

.danger-button {
  background: var(--terracotta-dark);
  color: #f7f1e8;
  letter-spacing: .04em;
  min-height: 40px;
  padding: 0 18px;
  font-size: 12px;
}

.danger-button:hover {
  filter: brightness(.96);
}

.danger-button:disabled {
  cursor: not-allowed;
  opacity: .55;
}

.memory-detail {
  background: var(--cream);
  box-shadow: var(--shadow);
  border-radius: 10px;
  flex-direction: column;
  width: min(1320px, 100vw - 64px);
  height: calc(100vh - 48px);
  display: flex;
  position: absolute;
  top: 24px;
  left: 50%;
  overflow: hidden;
  transform: translateX(-50%);
}

.detail-header {
  border-bottom: 1px solid var(--line);
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  min-height: 72px;
  padding: 8px 26px;
  display: grid;
}

.close-button {
  color: var(--muted);
  background: none;
  justify-self: start;
  font-size: 12px;
}

.detail-heading {
  text-align: center;
}

.detail-heading span, .detail-heading p {
  color: var(--muted);
  font-size: 11px;
}

.detail-heading h2 {
  margin: 2px 0;
  font-family: Songti SC, serif;
  font-size: 23px;
  font-weight: 500;
}

.detail-heading p {
  margin: 0;
}

.detail-header > .avatars {
  justify-self: end;
}

.detail-header-actions {
  justify-self: end;
  align-items: center;
  gap: 18px;
  display: flex;
}

.detail-body-empty {
  grid-template-columns: minmax(0, 1fr);
}

.photo-caption {
  color: #3f38319e;
  background: none;
  margin: 0;
  padding: 0;
  font-family: Songti SC, serif;
  font-size: 12px;
}

.photo-caption-empty {
  color: #3f383161;
  text-underline-offset: 4px;
  -webkit-text-decoration: underline #3f383133;
  text-decoration: underline #3f383133;
}

.photo-meta {
  flex-wrap: wrap;
  justify-content: center;
  align-items: center;
  gap: 12px 16px;
  max-width: min(640px, 100%);
  margin-top: 18px;
  display: flex;
}

.caption-editor {
  gap: 12px;
  width: 100%;
  max-width: min(520px, 100%);
  margin-top: 18px;
  display: grid;
}

.caption-editor input {
  border: 1px solid var(--line);
  color: var(--ink);
  background: #fffcf6c7;
  border-radius: 4px;
  width: 100%;
  padding: 12px 14px;
  font-family: Songti SC, serif;
  font-size: 14px;
}

.caption-editor-actions {
  justify-content: flex-end;
  align-items: center;
  gap: 14px;
  display: flex;
}

.caption-editor-actions > span {
  color: var(--muted);
  margin-right: auto;
  font-size: 11px;
}

.caption-editor-actions .primary-button {
  min-height: 34px;
  padding: 0 16px;
}

.stage-wrap-empty {
  min-height: 280px;
}

.edit-sheet-footer {
  border-top: 1px solid var(--line);
  justify-content: space-between;
  align-items: center;
  margin-top: 28px;
  padding-top: 24px;
  display: flex;
}

.edit-sheet-footer > div {
  align-items: center;
  gap: 16px;
  display: flex;
}

.edit-sheet-footer > div > button:first-child {
  color: var(--muted);
  background: none;
}

.edit-sheet-footer .danger-text {
  color: var(--terracotta-dark);
  background: none;
  font-size: 12px;
}

.gallery-view {
  background: var(--cream);
  flex: 1;
  min-height: 0;
  padding: 46px clamp(28px, 6vw, 86px) 90px;
  overflow-y: auto;
}

.gallery-summary {
  border-bottom: 1px solid var(--line);
  justify-content: space-between;
  align-items: flex-end;
  max-width: 1180px;
  margin: 0 auto 28px;
  padding-bottom: 28px;
  display: flex;
}

.gallery-summary .eyebrow {
  margin-bottom: 10px;
}

.gallery-summary > div:first-child {
  flex: auto;
  min-width: 0;
}

.gallery-summary h3 {
  max-width: 700px;
  margin: 0;
  font-family: Songti SC, serif;
  font-size: clamp(20px, 2.5vw, 30px);
  font-weight: 500;
  line-height: 1.55;
}

.gallery-facts {
  flex: none;
  gap: 28px;
  display: flex;
}

.gallery-facts span {
  color: var(--muted);
  text-align: center;
  font-size: 11px;
}

.gallery-facts strong {
  color: var(--ink);
  margin-bottom: 3px;
  font-family: Georgia, serif;
  font-size: 25px;
  font-weight: 400;
  display: block;
}

.gallery-toolbar {
  justify-content: space-between;
  align-items: center;
  max-width: 1180px;
  margin: 0 auto 22px;
  display: flex;
}

.gallery-toolbar > div {
  align-items: center;
  gap: 10px;
  display: flex;
}

.gallery-manage-button, .gallery-archive-button {
  border: 1px solid var(--line);
  color: var(--muted);
  background: none;
  border-radius: 999px;
  padding: 10px 15px;
  font-size: 11px;
}

.gallery-manage-button.active {
  background: var(--paper);
  color: var(--ink);
}

.gallery-archive-button {
  color: var(--terracotta-dark);
  border-color: #bd6f5259;
}

.upload-progress {
  background: var(--paper-deep);
  border-radius: 999px;
  max-width: 1180px;
  height: 4px;
  margin: 0 auto 28px;
  position: relative;
}

.upload-progress > span {
  background: var(--terracotta);
  border-radius: inherit;
  height: 100%;
  transition: width .16s;
  display: block;
}

.upload-progress p {
  color: var(--muted);
  text-align: right;
  margin: 7px 0 0;
  font-size: 9px;
}

.upload-progress-sheet {
  margin: 26px 0 18px;
}

.event-photo-grid {
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 18px;
  max-width: 1180px;
  margin: 0 auto;
  display: grid;
}

.gallery-photo-card {
  min-width: 0;
  transition: opacity .16s, transform .16s;
}

.gallery-photo-card[draggable="true"] {
  cursor: grab;
}

.gallery-photo-card[draggable="true"]:active {
  cursor: grabbing;
  opacity: .7;
  transform: scale(.98);
}

.gallery-photo-card.selected .photo-surface {
  outline: 3px solid var(--terracotta);
  outline-offset: 3px;
}

.gallery-photo-main {
  text-align: left;
  background: none;
  width: 100%;
  padding: 0;
  display: block;
  position: relative;
}

.gallery-photo-main .photo-surface {
  aspect-ratio: 1 / .82;
  border-radius: 3px;
  transition: box-shadow .18s, transform .18s;
  box-shadow: 0 12px 34px #43322324;
}

.gallery-photo-main:hover .photo-surface {
  transform: translateY(-2px);
  box-shadow: 0 18px 44px #43322333;
}

.gallery-photo-number, .gallery-select-mark {
  -webkit-backdrop-filter: blur(8px);
  backdrop-filter: blur(8px);
  background: #fffcf6e0;
  border-radius: 999px;
  padding: 6px 8px;
  font-size: 10px;
  position: absolute;
}

.gallery-photo-number {
  top: 10px;
  left: 10px;
}

.gallery-select-mark {
  background: #fffcf6f2;
  border: 1px solid #3f383147;
  justify-content: center;
  align-items: center;
  width: 26px;
  height: 26px;
  padding: 0;
  font-size: 12px;
  display: flex;
  top: 10px;
  right: 10px;
}

.gallery-photo-card.selected .gallery-select-mark {
  background: var(--terracotta);
  border-color: var(--terracotta);
  color: #fff;
}

.gallery-card-actions {
  justify-content: space-between;
  align-items: center;
  padding: 10px 2px 0;
  display: flex;
}

.gallery-card-actions button {
  color: var(--muted);
  background: none;
  padding: 5px;
  font-size: 11px;
}

.gallery-card-actions button:disabled {
  cursor: default;
  opacity: .4;
}

.gallery-card-actions > span {
  gap: 5px;
  display: flex;
}

.gallery-empty {
  background: var(--paper);
  border: 1px dashed #bd6f526b;
  border-radius: 4px;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  width: min(680px, 100%);
  min-height: 330px;
  margin: 40px auto;
  display: flex;
}

.gallery-empty > span {
  color: var(--terracotta);
  margin-bottom: 12px;
  font-size: 34px;
}

.gallery-empty strong {
  font-family: Songti SC, serif;
  font-size: 20px;
  font-weight: 500;
}

.gallery-empty small {
  color: var(--muted);
  margin-top: 7px;
}

.gallery-empty-readonly {
  cursor: default;
  border-style: solid;
  min-height: 260px;
}

.detail-body {
  flex: 1;
  grid-template-columns: 78px minmax(0, 1fr);
  min-height: 0;
  display: grid;
}

.photo-strip {
  border-right: 1px solid var(--line);
  flex-direction: column;
  align-items: center;
  gap: 12px;
  padding: 22px 14px;
  display: flex;
  overflow-y: auto;
}

.photo-strip > button {
  opacity: .52;
  background: none;
  padding: 0;
  transition: opacity .16s;
  position: relative;
}

.photo-strip > button.active {
  opacity: 1;
}

.photo-strip .photo-surface {
  box-shadow: none;
  border-radius: 2px;
  width: 48px;
}

.photo-strip > button > span {
  background: var(--terracotta);
  color: #fff;
  border-radius: 50%;
  width: 18px;
  height: 18px;
  font-size: 9px;
  line-height: 18px;
  position: absolute;
  top: -6px;
  right: -6px;
}

.stage-wrap {
  background: radial-gradient(circle at 50% 42%, #fffcf685, #0000 60%), #d9d0c4;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  min-width: 0;
  min-height: min(62vh, 620px);
  padding: 30px 72px 26px;
  display: flex;
}

.photo-stage {
  width: 100%;
  max-width: min(760px, 100%);
  position: relative;
}

.photo-stage .photo-surface {
  aspect-ratio: 4 / 3;
  max-height: 520px;
  box-shadow: 0 26px 80px #2d231c3d;
}

.photo-stage .photo-surface img {
  object-fit: contain;
  background: #c5b4a2;
}

.photo-stage .photo-surface[role="button"] {
  cursor: zoom-in;
  outline: none;
  transition: box-shadow .18s, transform .18s;
}

.photo-stage .photo-surface[role="button"]:hover, .photo-stage .photo-surface[role="button"]:focus-visible {
  transform: translateY(-2px);
  box-shadow: 0 30px 88px #2d231c4d;
}

.photo-nav-button {
  -webkit-backdrop-filter: blur(12px);
  backdrop-filter: blur(12px);
  color: var(--ink);
  z-index: 3;
  background: #fffcf6d1;
  border: 1px solid #ffffffa6;
  border-radius: 50%;
  justify-content: center;
  align-items: center;
  width: 48px;
  height: 48px;
  padding: 0 0 4px;
  font-family: Georgia, serif;
  font-size: 34px;
  transition: background .16s, transform .16s;
  display: flex;
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  box-shadow: 0 10px 28px #2d231c29;
}

.photo-nav-button:hover {
  background: var(--cream);
  transform: translateY(-50%)scale(1.06);
}

.photo-nav-previous {
  left: -62px;
}

.photo-nav-next {
  right: -62px;
}

.photo-position {
  -webkit-backdrop-filter: blur(8px);
  backdrop-filter: blur(8px);
  color: #fff;
  letter-spacing: .08em;
  z-index: 2;
  background: #2d262094;
  border-radius: 999px;
  padding: 6px 9px;
  font-size: 11px;
  position: absolute;
  bottom: 12px;
  right: 12px;
}

.photo-lightbox {
  z-index: 200;
  background: #181513f5;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  padding: 64px 92px 54px;
  display: flex;
  position: fixed;
  inset: 0;
}

.photo-lightbox-topbar {
  color: #ffffffb8;
  letter-spacing: .08em;
  justify-content: space-between;
  align-items: center;
  font-size: 13px;
  display: flex;
  position: absolute;
  top: 22px;
  left: 30px;
  right: 30px;
}

.photo-lightbox-topbar button {
  color: #ffffffe0;
  background: #ffffff17;
  border: 1px solid #ffffff29;
  border-radius: 999px;
  padding: 9px 16px;
  font-size: 13px;
  transition: background .16s, color .16s;
}

.photo-lightbox-topbar button:hover {
  color: #fff;
  background: #ffffff2b;
}

.photo-lightbox-stage {
  justify-content: center;
  align-items: center;
  width: 100%;
  max-width: 1500px;
  height: min(78vh, 900px);
  display: flex;
  position: relative;
}

.photo-lightbox-canvas {
  cursor: zoom-in;
  touch-action: none;
  width: 100%;
  height: 100%;
  position: absolute;
  inset: 0;
  overflow: hidden;
}

.photo-lightbox-canvas.is-zoomed {
  cursor: grab;
}

.photo-lightbox-canvas.is-zoomed:active {
  cursor: grabbing;
}

.photo-lightbox-canvas img {
  backface-visibility: hidden;
  object-fit: contain;
  pointer-events: none;
  transform-origin: center;
  -webkit-user-select: none;
  user-select: none;
  will-change: transform;
  width: 100%;
  max-width: 100%;
  height: 100%;
  display: block;
  transform: translate3d(0, 0, 0)scale(1);
}

.photo-lightbox-canvas:not(.is-zoomed) img {
  box-shadow: 0 28px 100px #00000061;
}

.photo-zoom-controls {
  -webkit-backdrop-filter: blur(12px);
  backdrop-filter: blur(12px);
  z-index: 4;
  background: #1d1916ad;
  border: 1px solid #ffffff29;
  border-radius: 999px;
  align-items: center;
  display: flex;
  position: absolute;
  bottom: 14px;
  left: 50%;
  overflow: hidden;
  transform: translateX(-50%);
}

.photo-lightbox-loading {
  -webkit-backdrop-filter: blur(8px);
  backdrop-filter: blur(8px);
  color: #fffc;
  font-family: var(--font-ui);
  pointer-events: none;
  z-index: 4;
  background: #1d19169e;
  border-radius: 999px;
  padding: 8px 13px;
  font-size: 11px;
  position: absolute;
  top: 14px;
  left: 50%;
  transform: translateX(-50%);
}

.photo-zoom-controls button {
  color: #ffffffeb;
  font-family: var(--font-ui);
  background: none;
  min-width: 44px;
  height: 42px;
  padding: 0 12px;
  font-size: 18px;
}

.photo-zoom-controls button:hover {
  background: #ffffff1f;
}

.photo-zoom-controls button:disabled {
  cursor: default;
  opacity: .35;
}

.photo-zoom-controls .photo-zoom-value {
  border-left: 1px solid #ffffff1f;
  border-right: 1px solid #ffffff1f;
  min-width: 64px;
  font-size: 11px;
}

.photo-lightbox-nav {
  color: #fff;
  z-index: 2;
  background: #ffffff1a;
  border: 1px solid #ffffff29;
  border-radius: 50%;
  justify-content: center;
  align-items: center;
  width: 50px;
  height: 50px;
  font-size: 24px;
  transition: background .16s, transform .16s;
  display: flex;
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
}

.photo-lightbox-nav:hover {
  background: #fff3;
  transform: translateY(-50%)scale(1.06);
}

.photo-lightbox-previous {
  left: -68px;
}

.photo-lightbox-next {
  right: -68px;
}

.photo-lightbox-caption {
  color: #ffffffc2;
  text-align: center;
  max-width: 720px;
  margin: 18px 0 0;
  font-family: Songti SC, Noto Serif CJK SC, serif;
  font-size: 14px;
  line-height: 1.7;
}

.detail-scroll {
  background: none;
  min-width: 0;
  overflow-y: auto;
}

.below-photo {
  background: var(--cream);
  grid-template-columns: minmax(220px, .72fr) minmax(360px, 1.28fr);
  gap: 52px;
  max-width: 1120px;
  margin: 0 auto;
  padding: 64px 54px 90px;
  display: grid;
}

.below-photo > * {
  min-width: 0;
}

.note-label {
  color: var(--terracotta);
  letter-spacing: .14em;
  margin-bottom: 14px;
  font-size: 12px;
  font-weight: 700;
  display: block;
}

.story-block {
  border-right: 1px solid var(--line);
  min-width: 0;
  margin: 0;
  padding-right: 48px;
}

.story-block p {
  overflow-wrap: anywhere;
  word-break: break-word;
  max-width: 100%;
  margin: 0;
  font-family: Songti SC, serif;
  font-size: 15px;
  line-height: 1.9;
}

.story-photo-meta {
  border-top: 1px solid var(--line);
  margin-top: 26px;
  padding-top: 20px;
}

.story-photo-meta .photo-meta {
  justify-content: flex-start;
  margin-top: 0;
}

.story-photo-meta .caption-editor {
  margin-top: 0;
}

.photo-original-download {
  color: var(--terracotta-dark);
  border: 1px solid #9a6d5847;
  border-radius: 999px;
  align-items: center;
  gap: 7px;
  margin-top: 16px;
  padding: 9px 14px;
  font-size: 12px;
  transition: background .16s, border-color .16s, transform .16s;
  display: inline-flex;
}

.photo-original-download:hover {
  background: #bd6f5214;
  border-color: #9a6d587a;
  transform: translateY(-1px);
}

.photo-original-download span {
  font-family: Georgia, serif;
  font-size: 16px;
  line-height: 1;
}

.comments-heading {
  justify-content: space-between;
  align-items: flex-start;
  margin-bottom: 28px;
  padding-top: 48px;
  display: flex;
}

.photo-event-comments {
  min-width: 0;
}

.photo-event-comments .comments-heading {
  padding-top: 0;
}

.comments-heading .note-label {
  margin-bottom: 8px;
}

.comments-heading h3 {
  margin: 0;
  font-family: Songti SC, serif;
  font-size: 24px;
  font-weight: 500;
}

.comment-list {
  border-top: 1px solid var(--line);
}

.comment-row {
  border-bottom: 1px solid var(--line);
  align-items: flex-start;
  gap: 12px;
  width: 100%;
  min-width: 0;
  padding: 20px 0;
  display: flex;
}

.comment-row > div {
  flex: 1;
  min-width: 0;
}

.comment-row header {
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: center;
  gap: 8px 14px;
  display: flex;
}

.comment-row strong {
  font-size: 12px;
}

.comment-row time {
  color: var(--muted);
  font-size: 11px;
}

.comment-meta {
  align-items: center;
  gap: 12px;
  display: flex;
}

.comment-actions {
  align-items: center;
  gap: 14px;
  margin-top: 8px;
  display: flex;
}

.comment-delete, .comment-edit {
  color: var(--terracotta-dark);
  text-underline-offset: 3px;
  background: none;
  padding: 0;
  font-size: 12px;
  font-weight: 600;
  text-decoration: underline;
}

.comment-delete:hover, .comment-edit:hover {
  color: var(--ink);
}

.comment-edit-form {
  gap: 10px;
  margin-top: 8px;
  display: grid;
}

.comment-edit-form textarea {
  background: var(--paper);
  border: 1px solid var(--line);
  resize: vertical;
  border-radius: 4px;
  width: 100%;
  min-height: 88px;
  padding: 12px;
}

.comment-edit-actions {
  justify-content: flex-end;
  align-items: center;
  gap: 12px;
  display: flex;
}

.comment-edit-actions > span {
  color: var(--muted);
  margin-right: auto;
  font-size: 11px;
}

.comment-edit-actions .primary-button {
  min-height: 34px;
  padding: 0 14px;
}

.comment-row p {
  color: var(--muted);
  overflow-wrap: anywhere;
  word-break: break-word;
  max-width: 100%;
  margin: 6px 0 0;
  font-size: 13px;
  line-height: 1.7;
}

.breakable-copy {
  overflow-wrap: anywhere;
  white-space: pre-wrap;
  word-break: break-all;
  min-width: 0;
  max-width: 100%;
}

.comment-form {
  margin-top: 26px;
}

.comment-form textarea {
  background: var(--paper);
  border: 1px solid var(--line);
  resize: vertical;
  border-radius: 3px;
  outline: none;
  width: 100%;
  min-height: 104px;
  padding: 14px;
}

.comment-form textarea:focus {
  border-color: #bd6f528c;
}

.comment-form > div {
  justify-content: space-between;
  align-items: center;
  margin-top: 12px;
  display: flex;
}

.comment-form > div > span {
  color: var(--muted);
  font-size: 11px;
}

.comment-form .primary-button {
  padding: 10px 14px;
  font-size: 11px;
}

.comment-avatar {
  flex-shrink: 0;
  width: 28px;
  height: 28px;
  margin-top: 2px;
  font-size: 11px;
}

.comment-author {
  color: var(--ink);
  font-size: 11px;
  font-weight: 600;
}

.comment-author-picker {
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  margin-bottom: 12px;
  display: flex;
}

.comment-author-label {
  color: var(--muted);
  white-space: nowrap;
  font-size: 11px;
}

.comment-author-options {
  flex-wrap: wrap;
  gap: 6px;
  display: flex;
}

.comment-author-hint {
  color: var(--terracotta-dark);
  flex-basis: 100%;
  margin: 2px 0 0;
  font-size: 11px;
}

.author-chip {
  border: 1px solid var(--line);
  color: var(--muted);
  cursor: pointer;
  background: none;
  border-radius: 100px;
  align-items: center;
  gap: 6px;
  padding: 4px 10px 4px 4px;
  font-size: 11px;
  transition: all .15s;
  display: flex;
}

.author-chip .avatar {
  width: 20px;
  height: 20px;
  font-size: 9px;
}

.author-chip:hover {
  color: var(--ink);
  border-color: #bd6f5266;
}

.author-chip-active {
  background: var(--terracotta);
  border-color: var(--terracotta);
  color: #fff;
}

.author-chip-active .avatar {
  box-shadow: 0 0 0 2px #fff6;
}

.empty-copy {
  color: var(--muted);
  font-family: Songti SC, serif;
  font-size: 13px;
  line-height: 1.8;
}

.create-sheet {
  background: var(--cream);
  box-shadow: var(--shadow);
  border-radius: 6px 0 0 6px;
  width: min(620px, 100%);
  height: 100%;
  padding: 42px clamp(28px, 5vw, 58px);
  position: absolute;
  top: 0;
  right: 0;
  overflow-y: auto;
}

.create-sheet header {
  justify-content: space-between;
  align-items: flex-start;
  margin-bottom: 35px;
  display: flex;
}

.create-sheet header .eyebrow {
  margin-bottom: 7px;
}

.create-sheet header h2 {
  margin: 0;
  font-family: Songti SC, serif;
  font-size: 34px;
  font-weight: 500;
}

.create-sheet header > button {
  color: var(--muted);
  background: none;
  font-size: 26px;
}

.form-row {
  grid-template-columns: 1fr 1fr;
  gap: 16px;
  display: grid;
}

.field {
  margin-bottom: 20px;
  display: block;
}

.field > span, .people-picker legend {
  color: var(--muted);
  margin-bottom: 8px;
  font-size: 11px;
  display: block;
}

.field input, .field textarea {
  background: var(--paper);
  border: 1px solid #0000;
  border-radius: 3px;
  outline: none;
  width: 100%;
  padding: 14px;
}

.field textarea {
  resize: vertical;
  min-height: 112px;
}

.field input:focus, .field textarea:focus {
  border-color: #bd6f5273;
}

.people-picker {
  border: 0;
  margin: 0 0 24px;
  padding: 0;
}

.people-picker > div {
  flex-wrap: wrap;
  gap: 8px;
  display: flex;
}

.people-picker label {
  background: var(--paper);
  cursor: pointer;
  border: 1px solid #0000;
  border-radius: 999px;
  align-items: center;
  gap: 6px;
  padding: 5px 10px 5px 5px;
  font-size: 11px;
  display: flex;
}

.people-picker label:has(input:checked) {
  background: #f9eee8;
  border-color: #bd6f5273;
}

.people-picker input {
  opacity: 0;
  width: 0;
  height: 0;
  position: absolute;
}

.people-picker .avatar {
  border: 0;
  width: 26px;
  height: 26px;
}

.photo-upload {
  cursor: pointer;
  border: 1px dashed #bd6f526b;
  border-radius: 4px;
  align-items: center;
  gap: 14px;
  padding: 20px;
  display: flex;
  position: relative;
}

.photo-upload-block {
  gap: 14px;
  display: grid;
}

.photo-upload input {
  opacity: 0;
  width: 0;
  height: 0;
  position: absolute;
}

.upload-icon {
  color: var(--terracotta);
  background: #f4e1d7;
  border-radius: 50%;
  justify-content: center;
  align-items: center;
  width: 44px;
  height: 44px;
  font-size: 20px;
  display: flex;
}

.photo-upload strong, .photo-upload small {
  display: block;
}

.photo-upload strong {
  margin-bottom: 5px;
  font-size: 12px;
}

.photo-upload small {
  color: var(--muted);
  font-size: 11px;
}

.draft-photo-grid {
  grid-template-columns: repeat(auto-fill, minmax(112px, 1fr));
  gap: 14px;
  margin: 0;
  padding: 0;
  list-style: none;
  display: grid;
}

.draft-photo-card {
  gap: 8px;
  display: grid;
}

.draft-photo-thumb {
  aspect-ratio: 1;
  position: relative;
  overflow: hidden;
}

.draft-photo-thumb img {
  object-fit: cover;
  width: 100%;
  height: 100%;
  display: block;
}

.draft-photo-thumb > span {
  color: #f7f1e8;
  letter-spacing: .04em;
  background: #2d26208c;
  padding: 2px 6px;
  font-size: 10px;
  position: absolute;
  top: 8px;
  left: 8px;
}

.draft-photo-remove {
  color: var(--muted);
  background: #fffcf6e0;
  border-radius: 50%;
  justify-content: center;
  align-items: center;
  width: 22px;
  height: 22px;
  font-size: 14px;
  line-height: 1;
  display: flex;
  position: absolute;
  top: 8px;
  right: 8px;
}

.draft-photo-remove:hover {
  color: var(--terracotta-dark);
}

.create-sheet > footer {
  border-top: 1px solid var(--line);
  justify-content: flex-end;
  align-items: center;
  gap: 18px;
  margin-top: 30px;
  padding-top: 25px;
  display: flex;
}

.create-sheet > footer > button:first-child {
  color: var(--muted);
  background: none;
  font-size: 11px;
}

.admin-login-sheet {
  background: var(--cream);
  box-shadow: var(--shadow);
  border-radius: 12px;
  width: min(440px, 100vw - 36px);
  padding: 34px 36px 30px;
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
}

.admin-login-sheet header {
  justify-content: space-between;
  align-items: flex-start;
  margin-bottom: 18px;
  display: flex;
}

.admin-login-sheet header .eyebrow {
  margin-bottom: 6px;
}

.admin-login-sheet header h2 {
  margin: 0;
  font-family: Songti SC, Noto Serif CJK SC, serif;
  font-size: 28px;
  font-weight: 500;
}

.admin-login-sheet header > button {
  color: var(--muted);
  background: none;
  font-size: 24px;
}

.admin-login-sheet > p {
  color: var(--muted);
  margin: 0 0 24px;
  font-size: 12px;
  line-height: 1.8;
}

.admin-login-error {
  color: var(--terracotta-dark);
  margin: -8px 0 18px;
  font-size: 11px;
}

.admin-login-sheet footer {
  border-top: 1px solid var(--line);
  justify-content: flex-end;
  align-items: center;
  gap: 16px;
  margin-top: 26px;
  padding-top: 20px;
  display: flex;
}

.admin-login-sheet footer > button:first-child {
  color: var(--muted);
  background: none;
  font-size: 11px;
}

.toast {
  background: var(--ink);
  color: #fff;
  z-index: 100;
  border-radius: 999px;
  padding: 13px 20px;
  font-size: 12px;
  position: fixed;
  bottom: 26px;
  left: 50%;
  transform: translateX(-50%);
  box-shadow: 0 12px 40px #261e1840;
}

.loading-state {
  flex-direction: column;
  justify-content: center;
  align-items: center;
  min-height: 70vh;
  display: flex;
}

.loading-state span {
  border: 1px solid #bd6f5240;
  border-top-color: var(--terracotta);
  border-radius: 50%;
  width: 34px;
  height: 34px;
  animation: 1.2s linear infinite turn;
}

.loading-state p {
  color: var(--muted);
  margin-top: 14px;
  font-family: Songti SC, serif;
  font-size: 12px;
}

.hero h1, .hero-note, .section-intro h1, .timeline-memory-header h3, .timeline-story, .placeholder-label, .section-intro > p:last-child, .person-portrait, .person-card-copy strong, .confirm-sheet h2, .detail-heading h2, .photo-caption, .caption-editor input, .gallery-summary h3, .gallery-empty strong, .photo-lightbox-caption, .story-block p, .comments-heading h3, .comment-row p, .empty-copy, .create-sheet header h2, .admin-login-sheet header h2, .loading-state p {
  font-family: var(--font-reading);
}

.brand-mark, .brand strong, .person-index, .gallery-facts strong, .photo-nav-button, .photo-original-download span, .placeholder-label small, .timeline-memory-meta, .timeline-memory-footer, .gallery-facts span, .note-label, .comment-row header, .comment-form, .detail-heading p, .photo-meta, .text-button, .primary-button, .danger-button, .close-button {
  font-family: var(--font-ui);
}

@keyframes turn {
  to {
    transform: rotate(360deg);
  }
}

@media (max-width: 900px) {
  .gallery-view {
    padding: 34px 24px 80px;
  }

  .gallery-summary {
    flex-direction: column;
    align-items: flex-start;
    gap: 22px;
  }

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

  .topbar {
    grid-template-columns: 1fr auto;
    padding: 0 22px;
  }

  .hero {
    grid-template-columns: minmax(0, 1fr) minmax(280px, 48%);
    gap: 28px;
    min-height: auto;
    padding-top: 34px;
  }

  .hero-copy {
    padding-bottom: 0;
  }

  .hero-elements {
    height: 300px;
  }

  .main-nav {
    z-index: 20;
    -webkit-backdrop-filter: blur(16px);
    backdrop-filter: blur(16px);
    background: #fffcf6eb;
    border: 1px solid #fffc;
    border-radius: 999px;
    gap: 20px;
    padding: 0 18px;
    position: fixed;
    bottom: 16px;
    left: 50%;
    transform: translateX(-50%);
    box-shadow: 0 8px 30px #43322324;
  }

  .hero {
    min-height: 440px;
    padding-top: 34px;
  }

  .hero-elements {
    opacity: .9;
    width: 100%;
  }

  .memory-timeline:before {
    left: 103px;
  }

  .timeline-entry {
    grid-template-columns: 82px 42px minmax(0, 1fr);
    padding-bottom: 56px;
  }

  .timeline-month-card {
    padding-left: 7px;
    padding-right: 7px;
  }

  .timeline-memory {
    padding-left: 16px;
  }

  .detail-body {
    grid-template-columns: minmax(0, 1fr);
    overflow: hidden;
  }

  .photo-strip {
    border: 0;
    flex-direction: row;
    order: 2;
    padding: 14px 20px;
    overflow-x: auto;
  }

  .detail-scroll {
    order: 1;
  }

  .stage-wrap {
    min-height: 46vh;
    padding: 20px;
  }

  .photo-nav-button {
    width: 42px;
    height: 42px;
  }

  .photo-nav-previous {
    left: 12px;
  }

  .photo-nav-next {
    right: 12px;
  }

  .photo-lightbox {
    padding: 62px 24px 44px;
  }

  .photo-lightbox-stage {
    height: min(76vh, 780px);
  }

  .photo-lightbox-nav {
    background: #1815138f;
  }

  .photo-lightbox-previous {
    left: 12px;
  }

  .photo-lightbox-next {
    right: 12px;
  }

  .below-photo {
    grid-template-columns: 1fr;
    gap: 36px;
    padding: 46px 36px 70px;
  }

  .story-block {
    border-bottom: 1px solid var(--line);
    border-right: 0;
    padding: 0 0 34px;
  }

  .detail-header {
    grid-template-columns: 1fr auto;
    min-height: 68px;
  }

  .detail-heading {
    display: none;
  }
}

@media (max-width: 620px) {
  .photo-lightbox {
    padding: 58px 10px 38px;
  }

  .photo-lightbox-topbar {
    top: 14px;
    left: 16px;
    right: 16px;
  }

  .photo-lightbox-stage {
    height: 72vh;
  }

  .photo-lightbox-nav {
    width: 42px;
    height: 42px;
    font-size: 20px;
  }

  .photo-lightbox-previous {
    left: 8px;
  }

  .photo-lightbox-next {
    right: 8px;
  }

  .photo-lightbox-caption {
    margin-top: 12px;
    padding: 0 16px;
    font-size: 13px;
  }

  .photo-zoom-controls {
    bottom: 10px;
  }

  .photo-zoom-controls button {
    height: 40px;
  }

  .hero {
    text-align: center;
    grid-template-columns: 1fr;
    gap: 18px;
    padding-top: 28px;
  }

  .hero-copy {
    max-width: 100%;
    margin: 0 auto;
    padding-bottom: 0;
  }

  .hero-note {
    max-width: 420px;
    margin-left: auto;
    margin-right: auto;
  }

  .memory-timeline:before {
    left: 73px;
  }

  .timeline-entry {
    grid-template-columns: 58px 30px minmax(0, 1fr);
    padding-bottom: 46px;
  }

  .timeline-month-card {
    margin-top: 11px;
    padding: 9px 4px 8px;
  }

  .timeline-month-card strong {
    font-size: 16px;
  }

  .timeline-month-card small {
    letter-spacing: .04em;
    font-size: 9px;
  }

  .timeline-rail-node {
    padding-top: 22px;
  }

  .timeline-rail-node:before {
    width: 9px;
    height: 9px;
  }

  .timeline-month-start .timeline-rail-node:before {
    width: 13px;
    height: 13px;
  }

  .timeline-memory {
    --letter-margin: 24px;
    padding: 20px 8px 24px 38px;
  }

  .timeline-memory-header h3 {
    font-size: 21px;
  }

  .timeline-photo-group {
    scrollbar-width: none;
    min-height: 108px;
    padding-right: 8px;
    overflow-x: auto;
  }

  .timeline-photo {
    flex-basis: 120px;
  }

  .timeline-photo-group:hover .timeline-photo {
    margin-right: -14px;
    transform: rotate(-1deg);
  }

  .timeline-photo-group:hover .timeline-photo:nth-child(2n) {
    transform: rotate(1.2deg)translateY(3px);
  }

  .timeline-memory-footer {
    flex-wrap: wrap;
    align-items: flex-start;
  }

  .gallery-toolbar {
    flex-direction: column;
    align-items: flex-start;
    gap: 12px;
  }

  .gallery-toolbar > div {
    width: 100%;
  }

  .gallery-toolbar .primary-button, .gallery-manage-button {
    flex: 1;
  }

  .gallery-archive-button {
    width: 100%;
  }

  .gallery-photo-main .photo-surface {
    aspect-ratio: 1;
  }

  .brand small {
    display: none;
  }

  .primary-button {
    padding: 11px 14px;
  }

  .hero {
    align-items: flex-start;
    min-height: 472px;
    padding: 42px 24px 34px;
  }

  .hero h1 {
    font-size: 39px;
  }

  .hero-elements {
    object-fit: contain;
    object-position: center;
    opacity: .9;
    width: 100%;
    height: 220px;
  }

  .hero-note {
    margin-top: 18px;
    font-size: 14px;
  }

  .section-heading {
    flex-direction: column;
    align-items: flex-start;
    gap: 10px;
  }

  .people-admin-panel {
    flex-direction: column;
    align-items: stretch;
    gap: 18px;
  }

  .people-admin-fields {
    flex-wrap: wrap;
    flex: none;
    align-items: stretch;
  }

  .people-admin-fields label {
    min-width: 180px;
  }

  .people-admin-fields .people-initials-field {
    flex: 0 0 86px;
    min-width: 86px;
  }

  .people-admin-fields .primary-button {
    flex: 1 0 100%;
  }

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

  .person-card {
    min-height: 128px;
  }

  .person-portrait {
    width: 72px;
    height: 72px;
  }

  .memory-detail {
    width: 100%;
    height: 100%;
    inset: 0;
    transform: none;
  }

  .detail-header {
    padding: 16px 20px;
  }

  .detail-header > .avatars, .detail-header-actions .avatars {
    display: none;
  }

  .edit-sheet-footer {
    flex-direction: column;
    align-items: flex-start;
    gap: 18px;
  }

  .edit-sheet-footer > div {
    justify-content: flex-end;
    width: 100%;
  }

  .stage-wrap {
    min-height: 38vh;
  }

  .below-photo {
    padding: 38px 20px 64px;
  }

  .comments-heading {
    flex-direction: column;
    align-items: flex-start;
    gap: 18px;
  }

  .form-row {
    grid-template-columns: 1fr;
    gap: 0;
  }

  body {
    background: #f4ede3;
  }

  .app-shell {
    padding-bottom: calc(72px + env(safe-area-inset-bottom));
  }

  .topbar {
    height: 62px;
    padding: 0 14px;
  }

  .brand {
    gap: 8px;
    min-width: 0;
  }

  .brand-mark {
    width: 32px;
    height: 32px;
    font-size: 14px;
  }

  .brand > span:last-child {
    min-width: 0;
  }

  .brand strong {
    letter-spacing: .1em;
    text-overflow: ellipsis;
    white-space: nowrap;
    font-size: 13px;
    overflow: hidden;
  }

  .header-actions {
    gap: 7px;
  }

  .header-actions .admin-mode-badge {
    display: none;
  }

  .header-actions .primary-button {
    border-radius: 50%;
    width: 38px;
    height: 38px;
    padding: 0;
    font-size: 20px;
  }

  .header-actions .primary-button .button-label {
    display: none;
  }

  .header-actions .text-button {
    padding: 10px 2px;
    font-size: 11px;
  }

  .admin-entry-button {
    min-height: 38px;
    padding: 8px 12px;
  }

  .main-nav {
    bottom: max(10px, env(safe-area-inset-bottom));
    justify-content: space-around;
    gap: 4px;
    width: min(230px, 100vw - 32px);
    padding: 4px;
    box-shadow: 0 10px 34px #372a2133;
  }

  .main-nav button {
    border-radius: 999px;
    min-width: 86px;
    min-height: 42px;
    padding: 10px 18px;
    font-size: 13px;
  }

  .main-nav button.active {
    background: #9f513e17;
  }

  .main-nav button:after {
    bottom: 5px;
  }

  .hero {
    text-align: left;
    gap: 8px;
    min-height: auto;
    padding: 30px 20px 24px;
  }

  .hero:before {
    width: 190px;
    height: 190px;
    top: -72px;
    left: -92px;
  }

  .hero-copy {
    margin: 0;
  }

  .hero .eyebrow {
    margin-bottom: 12px;
  }

  .hero h1 {
    letter-spacing: -.04em;
    font-size: clamp(34px, 10.2vw, 41px);
    line-height: 1.18;
  }

  .hero-note {
    max-width: 330px;
    margin: 18px 0 0;
    font-size: 14px;
    line-height: 1.75;
  }

  .hero-elements {
    object-position: right center;
    width: 100%;
    height: 158px;
    margin: -4px 0 0;
  }

  .memory-section {
    border-radius: 16px 16px 0 0;
    padding: 38px 14px 32px;
  }

  .section-heading {
    margin-bottom: 26px;
  }

  .section-heading .eyebrow {
    margin-bottom: 7px;
  }

  .section-heading h2 {
    font-size: 31px;
    line-height: 1.3;
  }

  .memory-timeline:before {
    top: 18px;
    bottom: 8px;
    left: 11px;
  }

  .timeline-entry {
    grid-template-rows: auto auto;
    grid-template-columns: 24px minmax(0, 1fr);
    padding-bottom: 38px;
  }

  .timeline-month-card {
    border-radius: 999px;
    grid-area: 1 / 2;
    justify-self: start;
    align-items: center;
    gap: 8px;
    width: max-content;
    margin: 0 0 10px;
    padding: 7px 12px;
    display: inline-flex;
  }

  .timeline-month-card strong {
    font-size: 15px;
    line-height: 1;
  }

  .timeline-month-card small {
    border-top: 0;
    border-left: 1px solid #ffffff6b;
    margin: 0;
    padding: 0 0 0 8px;
    font-size: 8px;
  }

  .timeline-month-spacer {
    grid-area: 1 / 2;
    height: 0;
  }

  .timeline-rail-node {
    grid-area: 1 / 1 / span 2;
    justify-content: flex-start;
    align-items: flex-start;
    padding: 18px 0 0 6px;
  }

  .timeline-month-start .timeline-rail-node {
    padding-top: 12px;
  }

  .timeline-memory {
    --letter-margin: 22px;
    border-radius: 2px 7px 7px 2px;
    grid-area: 2 / 2;
    padding: 22px 12px 24px 34px;
  }

  .timeline-memory:before {
    height: 10px;
  }

  .timeline-memory-header {
    margin-bottom: 12px;
  }

  .timeline-memory-meta {
    gap: 5px 12px;
  }

  .timeline-memory-meta span {
    letter-spacing: 0;
    font-size: 11px;
  }

  .timeline-memory-header h3 {
    margin-top: 5px;
    font-size: 23px;
    line-height: 1.35;
  }

  .timeline-photo-group {
    min-height: 104px;
    padding: 3px 5px 8px 0;
    overflow: visible;
  }

  .timeline-photo {
    flex-basis: calc(50% + 6px);
    min-width: 0;
    max-width: 144px;
    margin-right: -14px;
  }

  .timeline-photo .photo-surface {
    border-width: 3px;
  }

  .timeline-photo-more {
    flex: 0 0 32px;
    width: 32px;
    height: 32px;
  }

  .timeline-story {
    margin-top: 3px;
    font-size: 15px;
    line-height: 1.75;
  }

  .timeline-memory-footer {
    gap: 9px;
    margin-top: 15px;
    padding-top: 12px;
  }

  .timeline-memory-footer .avatars {
    scrollbar-width: none;
    max-width: 100%;
    padding-right: 3px;
    overflow-x: auto;
  }

  .timeline-memory-footer > span {
    font-size: 11px;
  }

  .people-page {
    padding: 38px 16px 32px;
  }

  .section-intro {
    margin-bottom: 30px;
  }

  .section-intro .eyebrow {
    margin-bottom: 13px;
  }

  .section-intro h1 {
    font-size: clamp(31px, 9.5vw, 38px);
    line-height: 1.38;
  }

  .section-intro > p:last-child {
    margin-top: 16px;
    font-size: 14px;
    line-height: 1.75;
  }

  .people-admin-panel {
    margin-bottom: 20px;
    padding: 18px;
  }

  .people-admin-copy {
    align-items: flex-start;
  }

  .people-admin-fields {
    grid-template-columns: minmax(0, 1fr) 82px;
    gap: 12px 9px;
    display: grid;
  }

  .people-admin-fields label, .people-admin-fields .people-initials-field {
    min-width: 0;
  }

  .people-admin-fields .people-initials-field {
    width: auto;
  }

  .people-admin-fields .primary-button {
    grid-column: 1 / -1;
    min-height: 44px;
  }

  .people-grid {
    gap: 12px;
  }

  .person-card {
    min-height: 120px;
    padding: 18px 50px 18px 18px;
  }

  .person-portrait {
    width: 62px;
    height: 62px;
    margin-right: 17px;
    font-size: 24px;
  }

  .person-portrait i {
    width: 68px;
    height: 68px;
  }

  .person-card-copy strong {
    font-size: 22px;
  }

  .person-recent {
    margin-top: 10px;
  }

  .person-recent em:nth-child(n+3) {
    display: none;
  }

  .person-delete-button {
    min-height: 34px;
    bottom: 12px;
    right: 12px;
  }

  .memory-detail {
    border-radius: 0;
    height: 100dvh;
  }

  .detail-header {
    min-height: 60px;
    padding: 8px 14px;
  }

  .close-button, .detail-header-actions .text-button {
    min-height: 40px;
    padding: 0 4px;
    font-size: 12px;
  }

  .gallery-view {
    padding: 26px 14px calc(86px + env(safe-area-inset-bottom));
  }

  .gallery-summary {
    gap: 18px;
    margin-bottom: 20px;
    padding-bottom: 20px;
  }

  .gallery-summary .eyebrow {
    margin-bottom: 8px;
  }

  .gallery-summary h3 {
    font-size: 20px;
    line-height: 1.65;
  }

  .gallery-facts {
    gap: 24px;
  }

  .gallery-facts strong {
    font-size: 23px;
  }

  .gallery-toolbar {
    margin-bottom: 18px;
  }

  .gallery-toolbar .primary-button, .gallery-manage-button, .gallery-archive-button {
    min-height: 42px;
  }

  .event-photo-grid {
    gap: 10px 8px;
  }

  .gallery-photo-number {
    top: 7px;
    left: 7px;
  }

  .photo-strip {
    display: none;
  }

  .stage-wrap {
    min-height: auto;
    padding: 14px 10px;
  }

  .photo-stage .photo-surface {
    max-height: 62dvh;
  }

  .photo-nav-button {
    background: #fffcf6e6;
    width: 40px;
    height: 40px;
  }

  .photo-nav-previous {
    left: 8px;
  }

  .photo-nav-next {
    right: 8px;
  }

  .below-photo {
    padding: 30px 18px calc(78px + env(safe-area-inset-bottom));
    gap: 30px;
  }

  .story-block {
    padding-bottom: 28px;
  }

  .story-block p, .comment-row p {
    font-size: 14px;
    line-height: 1.8;
  }

  .comments-heading {
    gap: 10px;
    margin-bottom: 20px;
  }

  .comments-heading h3 {
    font-size: 22px;
  }

  .comment-row {
    padding: 17px 0;
  }

  .comment-author-picker {
    align-items: flex-start;
    display: block;
  }

  .comment-author-label {
    margin-bottom: 9px;
    display: block;
  }

  .comment-author-options {
    scrollbar-width: none;
    flex-wrap: nowrap;
    width: 100%;
    padding-bottom: 6px;
    overflow-x: auto;
  }

  .author-chip {
    flex: none;
    min-height: 34px;
  }

  .comment-form textarea {
    min-height: 112px;
    font-size: 16px;
  }

  .photo-lightbox {
    padding-bottom: calc(34px + env(safe-area-inset-bottom));
  }

  .photo-lightbox-topbar button {
    min-height: 40px;
  }

  .create-sheet {
    padding: 28px 20px calc(28px + env(safe-area-inset-bottom));
    border-radius: 0;
    width: 100%;
  }

  .create-sheet header {
    margin-bottom: 26px;
  }

  .create-sheet header h2 {
    font-size: 30px;
  }

  .field input, .field textarea {
    font-size: 16px;
  }

  .photo-upload {
    padding: 16px;
  }

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

  .admin-login-sheet {
    width: calc(100vw - 28px);
    padding: 28px 22px 24px;
  }

  .confirm-sheet {
    max-width: calc(100vw - 28px);
    padding: 28px 22px 24px;
  }

  .toast {
    bottom: calc(74px + env(safe-area-inset-bottom));
    text-align: center;
    border-radius: 12px;
    width: max-content;
    max-width: calc(100vw - 28px);
  }
}

@media (max-width: 380px) {
  .brand strong {
    max-width: 118px;
  }

  .hero h1 {
    font-size: 33px;
  }

  .timeline-memory {
    padding-left: 31px;
    padding-right: 10px;
  }

  .timeline-photo {
    flex-basis: calc(50% + 10px);
  }

  .person-card {
    padding-left: 15px;
  }
}

.visitor-gate {
  color: #3f3731;
  background: radial-gradient(circle at 18% 18%, #c9785b1a, #0000 30rem), #f7f1e7;
  grid-template-columns: minmax(360px, .86fr) minmax(480px, 1.14fr);
  min-height: 100svh;
  display: grid;
  overflow: hidden;
}

.visitor-gate-card {
  z-index: 1;
  flex-direction: column;
  justify-content: center;
  width: min(31rem, 100% - 5rem);
  margin: 0 auto;
  display: flex;
  position: relative;
}

.visitor-gate-mark {
  color: #fffaf2;
  background: #bd694b;
  border-radius: 50%;
  place-items: center;
  width: 3.4rem;
  height: 3.4rem;
  margin-bottom: 2.2rem;
  font-family: Georgia, serif;
  font-size: 1.35rem;
  display: grid;
}

.visitor-gate-kicker {
  color: #bd694b;
  letter-spacing: .24em;
  margin: 0 0 .8rem;
  font-size: .78rem;
  font-weight: 700;
}

.visitor-gate h1 {
  letter-spacing: .015em;
  margin: 0;
  font-family: Georgia, Noto Serif SC, serif;
  font-size: clamp(3rem, 5vw, 5.2rem);
  font-weight: 400;
}

.visitor-gate-copy {
  color: #766b62;
  max-width: 28rem;
  margin: 1.25rem 0 2.5rem;
  font-family: KaiTi, STKaiti, Noto Serif SC, serif;
  font-size: 1.08rem;
  line-height: 1.9;
}

.visitor-gate form {
  gap: .75rem;
  display: grid;
}

.visitor-gate label {
  color: #665b52;
  font-size: .85rem;
  font-weight: 600;
}

.visitor-gate input {
  color: #3f3731;
  width: 100%;
  min-height: 3.4rem;
  font: inherit;
  background: #fffcf6db;
  border: 1px solid #785d493d;
  border-radius: .7rem;
  outline: none;
  padding: 0 1rem;
}

.visitor-gate input:focus {
  border-color: #bd694b;
  box-shadow: 0 0 0 3px #bd694b1f;
}

.visitor-gate button {
  color: #fffaf2;
  min-height: 3.5rem;
  font: inherit;
  cursor: pointer;
  background: #403831;
  border: 0;
  border-radius: .7rem;
  margin-top: .3rem;
}

.visitor-gate button:disabled {
  cursor: default;
  opacity: .55;
}

.visitor-gate-error {
  color: #a84532;
  margin: 0;
  font-size: .88rem;
}

.visitor-gate-note {
  color: #9a8d81;
  margin: 1.2rem 0 0;
  font-size: .78rem;
}

.visitor-gate-scene {
  background: linear-gradient(90deg, #f7f1e7e6, #0000 16%), #e5d8c66b;
  place-items: center;
  min-height: 100%;
  display: grid;
}

.visitor-gate-scene img {
  filter: drop-shadow(0 2rem 2rem #4d3a2b1f);
  width: min(82%, 58rem);
  height: auto;
}

@media (max-width: 760px) {
  .visitor-gate {
    padding: max(1.5rem, env(safe-area-inset-top)) 1.25rem
      max(1.5rem, env(safe-area-inset-bottom));
    grid-template-columns: 1fr;
    align-content: center;
  }

  .visitor-gate-card {
    width: min(100%, 29rem);
  }

  .visitor-gate-mark {
    width: 3rem;
    height: 3rem;
    margin-bottom: 1.5rem;
  }

  .visitor-gate-copy {
    margin-bottom: 1.7rem;
  }

  .visitor-gate-scene {
    display: none;
  }
}

.timeline-month-1 .timeline-month-card {
  background: #657681;
}

.timeline-month-2 .timeline-month-card {
  background: #8a6271;
}

.timeline-month-3 .timeline-month-card {
  background: #69816d;
}

.timeline-month-4 .timeline-month-card {
  background: #5f817d;
}

.timeline-month-5 .timeline-month-card {
  background: #a37643;
}

.timeline-month-6 .timeline-month-card {
  background: #ad654d;
}

.timeline-month-7 .timeline-month-card {
  background: #91493d;
}

.timeline-month-8 .timeline-month-card {
  background: #9c693d;
}

.timeline-month-9 .timeline-month-card {
  background: #747e58;
}

.timeline-month-10 .timeline-month-card {
  background: #98573f;
}

.timeline-month-11 .timeline-month-card {
  background: #76594d;
}

.timeline-month-12 .timeline-month-card {
  background: #73515d;
}

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

.memory-tools {
  justify-content: space-between;
  align-items: center;
  gap: 18px;
  max-width: 1160px;
  margin: -12px auto 30px;
  display: flex;
}

.memory-search {
  width: 100%;
  max-width: 360px;
  display: block;
  position: relative;
}

.memory-search input {
  color: var(--ink);
  font: inherit;
  background: #fffcf6bd;
  border: 1px solid #80604b33;
  border-radius: 999px;
  outline: none;
  width: 100%;
  min-height: 42px;
  padding: 0 42px 0 17px;
}

.memory-search input:focus {
  border-color: var(--terracotta);
  box-shadow: 0 0 0 3px #bd6f521a;
}

.memory-search button {
  color: var(--muted);
  background: none;
  width: 36px;
  height: 36px;
  font-size: 20px;
  position: absolute;
  top: 3px;
  right: 5px;
}

.memory-year-filter {
  scrollbar-width: none;
  gap: 7px;
  display: flex;
  overflow-x: auto;
}

.memory-year-filter button {
  color: var(--muted);
  background: #fffcf6a8;
  border: 1px solid #80604b2e;
  border-radius: 999px;
  flex: none;
  min-height: 36px;
  padding: 0 14px;
  font-size: 12px;
}

.memory-year-filter button.active {
  background: var(--terracotta-dark);
  border-color: var(--terracotta-dark);
  color: #fffaf3;
}

.memory-empty-state {
  text-align: center;
  background: #fffcf6b3;
  border: 1px dashed #80604b3d;
  border-radius: 10px;
  margin-left: 154px;
  padding: 54px 28px;
}

.memory-empty-state strong {
  font-family: KaiTi, STKaiti, serif;
  font-size: 22px;
  font-weight: 500;
  display: block;
}

.memory-empty-state p {
  color: var(--muted);
  margin: 10px 0 6px;
}

.photo-surface {
  background-color: #c5b4a2;
  background-image: linear-gradient(100deg, #0000 20%, #ffffff3d 45%, #0000 70%), none;
  background-position: 0 0, 0 0;
  background-repeat: repeat, repeat;
  background-size: 220% 100%;
  background-attachment: scroll, scroll;
  background-origin: padding-box, padding-box;
  background-clip: border-box, border-box;
  animation: 1.4s ease-in-out infinite photo-placeholder;
}

.photo-surface img {
  animation: .26s both photo-reveal;
}

@keyframes photo-placeholder {
  from {
    background-position: 100% 0;
  }

  to {
    background-position: -100% 0;
  }
}

@keyframes photo-reveal {
  from {
    opacity: 0;
  }

  to {
    opacity: 1;
  }
}

@media (max-width: 760px) {
  .memory-tools {
    flex-direction: column;
    align-items: stretch;
    gap: 12px;
    margin: -8px 0 24px;
  }

  .memory-search {
    max-width: none;
  }

  .memory-search input {
    font-size: 16px;
  }

  .memory-year-filter {
    margin: 0 -14px;
    padding: 0 14px 4px;
  }

  .memory-empty-state {
    margin-left: 24px;
    padding: 42px 18px;
  }
}

@property --tw-rotate-x {
  syntax: "*";
  inherits: false
}

@property --tw-rotate-y {
  syntax: "*";
  inherits: false
}

@property --tw-rotate-z {
  syntax: "*";
  inherits: false
}

@property --tw-skew-x {
  syntax: "*";
  inherits: false
}

@property --tw-skew-y {
  syntax: "*";
  inherits: false
}

/*# sourceMappingURL=app_globals_0jn8.0u.css.map*/