:root {
  color-scheme: dark;
  --red: #db0d26;
  --bg: #0a0b0f;
  --surface: #17181e;
  --muted: #afb0b8;
}
* {
  box-sizing: border-box;
}
body {
  margin: 0;
  background: var(--bg);
  color: #fff;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  font-size: 17px;
  line-height: 1.5;
}
button,
input,
textarea,
select {
  font: inherit;
}
button,
a,
input,
textarea,
select {
  touch-action: manipulation;
}
button {
  cursor: pointer;
  color: inherit;
}
button:disabled {
  cursor: default;
  opacity: 0.45;
}
a {
  color: inherit;
}
.app {
  max-width: 460px;
  margin: auto;
  min-height: 100dvh;
  padding: calc(24px + env(safe-area-inset-top)) 21px
    calc(110px + env(safe-area-inset-bottom));
}
.logo {
  width: 182px;
  height: auto;
  display: block;
}
.top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 28px;
  gap: 14px;
}
.eyebrow {
  font-size: 11px;
  letter-spacing: 1.5px;
  text-transform: uppercase;
  font-weight: 750;
  color: var(--muted);
  margin: 0 0 12px;
}
.title {
  font:
    700 44px/1.05 Georgia,
    serif;
  letter-spacing: -1.4px;
  margin: 22px 0;
}
h2 {
  font:
    700 32px/1.12 Georgia,
    serif;
  margin: 18px 0;
}
h3 {
  font-size: 19px;
  margin: 0 0 6px;
}
p {
  margin: 0 0 22px;
}
.muted {
  color: var(--muted);
}
.red {
  color: var(--red);
}
.card {
  background: var(--surface);
  border-radius: 25px;
  padding: 22px;
  margin: 22px 0;
}
.photo {
  display: block;
  width: 100%;
  height: 350px;
  border: 0;
  border-radius: 25px;
  overflow: hidden;
  position: relative;
  text-align: left;
  padding: 24px;
  margin: 18px 0;
  background: var(--surface);
}
.photo > img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.photo:after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(transparent 20%, rgba(0, 0, 0, 0.85));
}
.photo > span {
  position: absolute;
  bottom: 24px;
  left: 24px;
  right: 24px;
  z-index: 1;
}
.photo h2 {
  margin: 8px 0;
}
.pill {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: #17181edc;
  border: 1px solid #ffffff15;
  border-radius: 40px;
  padding: 8px 14px;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 1.5px;
}
.pill img {
  width: 95px;
}
.row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
}
.stack {
  display: grid;
  gap: 16px;
}
.quest {
  display: flex;
  gap: 14px;
  align-items: center;
  text-align: left;
  border: 0;
  width: 100%;
  background: var(--surface);
  border-radius: 20px;
  padding: 18px;
  margin: 14px 0;
}
.quest .status {
  margin-left: auto;
  color: var(--red);
  font-size: 14px;
}
.primary {
  border: 1px solid #ff496255;
  background: var(--red);
  box-shadow: inset 0 1px 0 #ffffff40;
  border-radius: 40px;
  min-height: 56px;
  width: 100%;
  padding: 14px 22px;
  font-size: 15px;
  font-weight: 750;
}
.glass {
  border: 1px solid #ffffff24;
  background: #25262dc0;
  backdrop-filter: blur(22px);
  border-radius: 40px;
  padding: 12px 18px;
  min-height: 44px;
}
.bottom {
  position: fixed;
  bottom: calc(18px + env(safe-area-inset-bottom));
  left: 50%;
  transform: translateX(-50%);
  width: min(90%, 390px);
  display: flex;
  background: #202128dd;
  backdrop-filter: blur(24px);
  border: 1px solid #ffffff24;
  border-radius: 45px;
  padding: 6px;
  z-index: 5;
  box-shadow: 0 6px 30px #0006;
}
.bottom button {
  border: 0;
  background: transparent;
  flex: 1;
  border-radius: 40px;
  padding: 12px 4px;
  color: #f4f3fa;
  font-size: 12px;
}
.bottom button.active {
  background: #484951;
  color: var(--red);
  font-weight: 700;
}
.bottom svg {
  display: block;
  margin: 0 auto 4px;
  width: 25px;
  height: 25px;
}
.sticky {
  position: sticky;
  bottom: 110px;
  margin-top: 28px;
  z-index: 3;
}
.error {
  color: #ff6176;
  border-left: 2px solid var(--red);
  padding: 10px;
  margin: 12px 0;
}
.field {
  display: grid;
  gap: 7px;
  font-size: 13px;
  color: var(--muted);
}
input,
textarea,
select {
  width: 100%;
  border: 1px solid #ffffff18;
  border-radius: 16px;
  padding: 15px;
  background: var(--surface);
  color: white;
  min-width: 0;
}
textarea {
  min-height: 96px;
  resize: vertical;
}
input:focus,
textarea:focus,
select:focus,
button:focus-visible {
  outline: 2px solid var(--red);
  outline-offset: 3px;
}
progress {
  width: 100%;
  height: 6px;
  accent-color: var(--red);
  margin: 16px 0 24px;
}
.modal {
  position: fixed;
  inset: 0;
  background: #000b;
  z-index: 10;
  display: flex;
  align-items: flex-end;
  justify-content: center;
}
.sheet {
  width: min(100%, 460px);
  max-height: 90dvh;
  overflow: auto;
  padding: 25px 24px calc(30px + env(safe-area-inset-bottom));
  border-radius: 32px 32px 0 0;
  background: var(--bg);
  border: 1px solid #ffffff20;
}
.stats {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 12px;
}
.stats .card {
  margin: 0;
  padding: 18px;
}
.stat {
  font:
    700 32px Georgia,
    serif;
}
.admin {
  max-width: 1100px;
  margin: auto;
  padding: 30px 24px;
}
.admin .title {
  font-size: 38px;
}
.admin .stats {
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  margin: 24px 0;
}
.admin nav {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}
.admin nav button.active {
  background: var(--red);
}
.admin .split {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 24px;
}
.scroll-table {
  overflow: auto;
}
table {
  border-collapse: collapse;
  width: 100%;
  font-size: 13px;
}
th,
td {
  text-align: left;
  padding: 12px;
  border-bottom: 1px solid #ffffff18;
  vertical-align: top;
}
code {
  font-family: ui-monospace, monospace;
  overflow-wrap: anywhere;
}
.tiny {
  font-size: 12px;
}
.notice {
  padding: 16px 0;
  border-bottom: 1px solid #ffffff18;
}
.check {
  display: flex;
  align-items: center;
  gap: 10px;
}
.check input {
  width: 20px;
}
.empty {
  padding: 35px 0;
  color: var(--muted);
}
@media (max-width: 650px) {
  .admin .split {
    grid-template-columns: 1fr;
  }
  .title {
    font-size: 42px;
  }
}
@media (prefers-reduced-motion: no-preference) {
  button {
    transition:
      background 0.15s,
      opacity 0.15s;
  }
}
