:root {
  color-scheme: dark;
  --black: #10090e;
  --ink: #fff0de;
  --muted: #d3b6b5;
  --gold: #f5cf87;
  --gold-deep: #a27743;
  --border: #684247;
  --pink: #ff9baa;
  --green: #c0e1bf;
}
* { box-sizing: border-box; }
[hidden] { display: none !important; }
body {
  margin: 0;
  min-height: 100vh;
  background:
    repeating-linear-gradient(110deg, transparent 0 7px, #ff88ac02 7px 8px),
    radial-gradient(ellipse at 50% 14rem, #3b1427, transparent 36rem),
    var(--black);
  color: var(--ink);
  font: 16px/1.55 system-ui, sans-serif;
}
main { max-width: 42rem; margin: auto; padding: .85rem .85rem max(2rem, env(safe-area-inset-bottom)); }
.hero {
  position: relative;
  isolation: isolate;
  display: grid;
  place-items: center;
  min-height: 17rem;
  overflow: hidden;
  margin-bottom: 1rem;
  text-align: center;
  border: 1px solid var(--gold-deep);
  border-radius: 1.4rem;
  background:
    linear-gradient(180deg, #1f081322 0%, #1709126e 43%, #16080ff2 100%),
    url("/scene.png") center 53% / cover no-repeat,
    #321222;
  box-shadow: 0 10px 32px #0008, 0 0 25px #f0497b3d, inset 0 0 3rem #230c18;
}
.hero::before {
  content: "";
  position: absolute;
  inset: .42rem;
  pointer-events: none;
  border: 1px solid #ffd48c59;
  border-radius: 1.04rem;
}
.hero-inner { padding: 1.05rem .7rem .65rem; }
.crest {
  display: block;
  width: 4.7rem;
  aspect-ratio: 1;
  object-fit: cover;
  margin: 0 auto .65rem;
  border: 1px solid #ffe0ab;
  border-radius: 50%;
  box-shadow: 0 0 0 4px #2a121ccc, 0 0 18px #ffc7778a;
}
.hero-label {
  margin: 0;
  color: #fff0d4;
  font-size: .64rem;
  font-weight: 800;
  letter-spacing: .21em;
  text-transform: uppercase;
  text-shadow: 0 2px 8px #000;
}
h1, h2, h3 { margin: 0; font-family: Georgia, "Times New Roman", serif; font-weight: 600; line-height: 1.12; color: var(--gold); }
h1 {
  margin: .35rem 0 .5rem;
  font-size: clamp(2rem, 8vw, 3.6rem);
  letter-spacing: -.055em;
  color: #ffe3ae;
  text-shadow: 0 2px 2px #230913, 0 0 18px #ffc66655;
}
h1 em {
  color: #ffe0e9;
  white-space: nowrap;
  font-weight: inherit;
  text-shadow: 0 0 5px #ff7da8, 0 0 16px #ff2d75, 0 0 32px #ff3275;
}
.hero-ornament { display: flex; gap: .55rem; align-items: center; justify-content: center; color: var(--gold); font-size: .9rem; }
.hero-ornament::before, .hero-ornament::after { content: ""; width: 2.65rem; height: 1px; background: linear-gradient(90deg, transparent, #e5ae69); }
.hero-ornament::after { transform: rotate(180deg); }
nav { display: flex; gap: .35rem; padding: .35rem; border-radius: .85rem; background: #130b11; border: 1px solid #633544; }
nav button { flex: 1; }
nav button:not(.active) { background: transparent; color: var(--muted); border-color: transparent; box-shadow: none; }
article {
  position: relative;
  margin: .95rem 0;
  padding: 1.05rem;
  overflow-wrap: anywhere;
  border: 1px solid var(--border);
  border-radius: 1.05rem;
  background: linear-gradient(117deg, #2e1421, #1c1018 60%, #170f15);
  box-shadow: 0 7px 24px #0005;
}
article::before { content: ""; position: absolute; inset: 0 auto 0 0; width: 2px; border-radius: 1.05rem; background: linear-gradient(transparent, #fc789d95 25%, #a84f6a00 90%); pointer-events: none; }
h2 { display: flex; gap: .6rem; align-items: center; font-size: 1.55rem; }
h3 { margin: .9rem 0 .35rem; font-size: 1.65rem; color: var(--ink); }
article p { margin: .65rem 0; }
.icon { display: inline-grid; place-items: center; flex: 0 0 2rem; height: 2rem; border: 1px solid #b8815980; border-radius: .65rem; color: var(--gold); background: #4b2233; font: 1rem/1 system-ui, sans-serif; box-shadow: inset 0 0 9px #f75d9233; }
#recipient { border-color: #d99178; box-shadow: 0 0 28px #e7437950; }
#recipient-link { display: inline-block; margin: .25rem 0 .65rem; }
#waiting p, #deadline, #sync-status, small { color: var(--muted); }
#deadline, #sync-status { font-size: .9rem; }
p.budget { display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: .3rem .65rem; background: #171015; padding: .52rem .72rem; border: 1px solid #88704b; border-radius: .55rem; color: var(--muted); font-size: .81rem; }
.budget strong { color: var(--gold); font-size: .95rem; white-space: nowrap; }
label { display: block; margin: .85rem 0; color: var(--ink); font-weight: 650; font-size: .9rem; }
small { font-weight: 400; }
input, textarea, button { font: inherit; }
input, textarea { display: block; width: 100%; min-height: 44px; margin-top: .35rem; padding: .66rem .75rem; background: #150d14; color: var(--ink); border: 1px solid #774d59; border-radius: .6rem; font-size: 16px; font-weight: 400; }
input::placeholder, textarea::placeholder { color: #b997a4; }
textarea { resize: vertical; }
input[readonly], textarea[readonly] { background: #20141c; border-color: #563742; }
textarea[readonly] { resize: none; }
button, .primary-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  min-height: 44px;
  padding: .58rem .85rem;
  color: #281320;
  background: linear-gradient(165deg, #ffe3a8, #dfac63);
  border: 1px solid #ffe0a4;
  border-radius: .63rem;
  box-shadow: 0 3px 16px #f9b95231;
  font-size: .88rem;
  font-weight: 800;
  text-align: center;
  text-decoration: none;
}
form button { width: 100%; margin-top: .2rem; }
button.secondary { background: #26121e; color: #f7d59e; border-color: #875663; box-shadow: inset 0 0 12px #ff67981a; }
button:active, .primary-link:active { filter: brightness(.9); }
button:disabled { opacity: .55; cursor: default; }
a { color: var(--gold); text-underline-offset: .18em; }
:focus-visible { outline: 2px solid var(--pink); outline-offset: 2px; }
.actions { display: flex; gap: .52rem; flex-wrap: wrap; }
#notice:empty { display: none; }
#notice { margin: .85rem 0; padding: .66rem .8rem; border-left: 2px solid var(--pink); border-radius: .25rem .65rem .65rem .25rem; background: #331827; overflow-wrap: anywhere; }
#roster { list-style: none; margin: 0; padding: 0; }
#roster li { display: flex; flex-flow: column; gap: .08rem; padding: .46rem 0; border-top: 1px solid #5b3944; }
#roster li span { font-size: .8rem; }
.roster-ready { color: var(--green); }
.roster-pending { color: #ffadba; }
.pre-line { white-space: pre-wrap; }
@media (min-width: 520px) {
  main { padding-top: 1.4rem; }
  .hero { min-height: 19rem; }
  article { padding: 1.3rem; }
}
@media (max-width: 350px) {
  main { padding-inline: .65rem; }
  .hero { min-height: 15rem; }
  h1 { font-size: 1.86rem; }
}

