/* Players arrive from the dark game; keep sign-in quiet and readable. */
:root {
  color-scheme: dark;
  --ground: oklch(18% 0.008 165);
  --surface: oklch(22% 0.008 165);
  --line: oklch(38% 0.008 165);
  --text: oklch(93% 0.008 85);
  --muted: oklch(72% 0.008 165);
  --brass: oklch(79% 0.07 83);
  --ink: oklch(20% 0.008 165);
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', system-ui, sans-serif;
  color: var(--text);
  background: var(--ground);
}
* {
  box-sizing: border-box;
}
body {
  margin: 0;
  min-height: 100svh;
}
[hidden] {
  display: none !important;
}
a {
  color: inherit;
  text-underline-offset: 4px;
}
button,
input,
select {
  font: inherit;
}
button,
.button {
  cursor: pointer;
  min-height: 46px;
  padding: 12px 18px;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: var(--surface);
  color: var(--text);
  font-size: 14px;
  text-decoration: none;
}
button:hover,
.button:hover {
  border-color: var(--muted);
}
button:active,
.button:active {
  background: var(--line);
}
button:disabled {
  opacity: 0.55;
  cursor: wait;
}
:focus-visible {
  outline: 2px solid var(--brass);
  outline-offset: 4px;
}
.primary {
  background: var(--text);
  color: var(--ink);
  border-color: var(--text);
  font-weight: 600;
}
.primary:hover {
  background: oklch(85% 0.008 85);
}
.primary:active {
  background: oklch(78% 0.008 85);
}
.quiet {
  background: transparent;
}
h1 {
  font-size: 28px;
  font-weight: 550;
  line-height: 1.2;
  letter-spacing: -0.8px;
  margin: 0;
}
h2 {
  font-size: 22px;
  font-weight: 550;
  letter-spacing: -0.4px;
  margin: 0 0 16px;
}
p {
  line-height: 1.6;
  max-width: 65ch;
}
.help,
.muted {
  color: var(--muted);
}
.help {
  font-size: 12px;
}
.login-layout,
.admin-layout:has(#owner-login:not([hidden])) {
  min-height: 100svh;
  display: grid;
  align-items: center;
  padding: 48px 24px;
}
.login-panel,
.owner-login {
  width: min(100%, 360px);
  margin: 0 auto;
}
.brand {
  display: inline-block;
  margin-bottom: 24px;
  color: var(--muted);
  font-size: 14px;
  text-decoration: none;
}
.brand:hover {
  color: var(--text);
}
label {
  display: block;
  font-size: 13px;
  font-weight: 500;
  margin: 0 0 10px;
}
input,
select {
  width: 100%;
  background: var(--surface);
  border: 1px solid var(--line);
  color: var(--text);
  border-radius: 6px;
  padding: 13px 14px;
  min-height: 48px;
  font-size: 16px;
}
input::placeholder {
  color: var(--muted);
  opacity: 0.8;
}
input[aria-invalid] {
  border-color: oklch(78% 0.1 40);
}
#login-form {
  margin-top: 36px;
}
#login-form .primary {
  width: 100%;
}
.check {
  display: flex;
  align-items: center;
  gap: 9px;
  font-weight: 400;
  min-height: 44px;
  margin: 4px 0 16px;
  color: var(--muted);
  cursor: pointer;
}
.check input {
  width: 16px;
  height: 16px;
  min-height: 0;
  margin: 0;
  accent-color: var(--brass);
}
.status {
  color: oklch(83% 0.075 60);
  font-size: 13px;
}
.status:empty {
  display: none;
}
.subtle-link {
  color: var(--muted);
  font-size: 13px;
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  margin-top: 14px;
  text-decoration: none;
}
.subtle-link:hover {
  color: var(--text);
  text-decoration: underline;
}
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  clip-path: inset(50%);
  overflow: hidden;
}
@media (prefers-reduced-motion: no-preference) {
  button,
  a {
    transition:
      background 0.16s ease-out,
      border-color 0.16s ease-out,
      color 0.16s ease-out;
  }
}

.notice-body {
  background: oklch(17% 0.015 160);
}
.notice-layout {
  min-height: 100svh;
  display: grid;
  place-items: center;
  padding: 32px 24px;
}
.notice-panel {
  position: relative;
  width: min(100%, 480px);
  padding: 48px 40px 52px;
  border: 1px solid oklch(39% 0.025 160);
  border-radius: 3px;
  background: oklch(22% 0.019 160);
  box-shadow:
    inset 0 0 0 7px oklch(19% 0.017 160),
    0 18px 60px oklch(10% 0.008 160 / 0.35);
}
.notice-panel::before,
.notice-panel::after {
  content: '';
  position: absolute;
  top: 13px;
  bottom: 13px;
  width: 4px;
  border-block: 4px solid oklch(49% 0.025 160);
}
.notice-panel::before {
  left: 13px;
}
.notice-panel::after {
  right: 13px;
}
.notice-brand {
  margin: 0 0 48px;
  font-size: 22px;
  font-weight: 700;
  letter-spacing: -0.8px;
}
.notice-brand span {
  margin-left: 12px;
  color: var(--muted);
  font-size: 10px;
  font-weight: 500;
  letter-spacing: 2px;
  vertical-align: middle;
}
.notice-code {
  display: inline-block;
  margin: 0 0 20px;
  padding: 6px 10px;
  color: var(--ink);
  background: var(--brass);
  font-size: 12px;
  font-weight: 650;
  letter-spacing: 1.5px;
}
.notice-panel h1 {
  max-width: 13ch;
  font-size: 32px;
  line-height: 1.15;
}
.notice-detail {
  max-width: 28ch;
  margin: 18px 0 0;
  color: var(--muted);
  font-size: 14px;
}
.notice-panel .button {
  display: inline-flex;
  align-items: center;
  margin-top: 32px;
}
@media (max-width: 440px) {
  .notice-panel {
    padding: 38px 28px 42px;
  }
  .notice-panel h1 {
    font-size: 28px;
  }
  .notice-brand {
    margin-bottom: 36px;
  }
}

/* Illustrated visitor and staff entrances. Art is decorative; the form leads. */
.illustrated-layout,
.admin-layout:has(#owner-login:not([hidden])) {
  width: min(1120px, 100%);
  margin: auto;
  min-height: 100svh;
  padding: 48px;
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(300px, 0.9fr);
  gap: clamp(40px, 7vw, 100px);
  align-items: center;
}
.portal-art {
  margin: 0;
  min-width: 0;
}
.portal-art img {
  display: block;
  width: 100%;
  height: auto;
  max-height: 740px;
  object-fit: contain;
  object-position: center;
  -webkit-mask-image: linear-gradient(to bottom, #000 68%, #000c 82%, transparent 100%);
  mask-image: linear-gradient(to bottom, #000 68%, #000c 82%, transparent 100%);
  transform-origin: 50% 75%;
}
.admin-layout > .portal-art {
  display: none;
}
.admin-layout:has(#owner-login:not([hidden])) > .portal-art {
  display: block;
}
.portal-wordmark {
  display: block;
  margin-bottom: 80px;
  font:
    700 32px Georgia,
    serif;
  color: var(--brass);
  text-decoration: none;
}
.portal-wordmark span {
  margin-left: 12px;
  font:
    11px system-ui,
    sans-serif;
  letter-spacing: 2px;
  color: var(--muted);
}
.portal-eyebrow {
  font-size: 10px;
  letter-spacing: 2px;
  color: var(--brass);
  margin-bottom: 16px;
}
.illustrated-layout h1,
.owner-login h1 {
  font:
    400 clamp(34px, 4vw, 48px)/1.1 Georgia,
    serif;
  letter-spacing: -1.5px;
}
.illustrated-layout .primary,
.owner-login .primary {
  background: var(--brass);
  border-color: var(--brass);
}
.illustrated-layout .primary:hover,
.owner-login .primary:hover {
  background: oklch(86% 0.065 83);
}
.illustrated-layout .notice-panel {
  width: 100%;
  padding: 0;
  background: none;
  border: 0;
  box-shadow: none;
}
.illustrated-layout .notice-panel::before,
.illustrated-layout .notice-panel::after {
  content: none;
}
.notice-brand {
  color: var(--brass);
}
.illustrated-layout .notice-code {
  background: none;
  color: var(--brass);
  padding: 0;
  font:
    400 72px/1 Georgia,
    serif;
  letter-spacing: -3px;
}
.notice-panel:has(.notice-code) .notice-detail {
  max-width: 30ch;
}
body:has(.notice-code) .notice-code {
  font-size: clamp(24px, 5vw, 64px);
  letter-spacing: 0;
}
@media (max-width: 700px) {
  .illustrated-layout,
  .admin-layout:has(#owner-login:not([hidden])) {
    grid-template-columns: 1fr;
    gap: 32px;
    padding: 28px 24px 48px;
  }
  .portal-art {
    order: 2;
    width: min(280px, 100%);
    margin: auto;
  }
  .portal-art img {
    max-height: none;
  }
  .portal-wordmark {
    margin-bottom: 40px;
  }
  .illustrated-layout .notice-panel {
    width: min(360px, 100%);
    margin: auto;
  }
  .notice-brand {
    margin-bottom: 32px;
  }
}

@media (prefers-reduced-motion: no-preference) {
  .portal-art {
    animation: portrait-enter 600ms cubic-bezier(0.23, 1, 0.32, 1) both;
  }
  .portal-art img {
    animation: portrait-drift 7s ease-in-out 600ms infinite alternate;
  }
}
@keyframes portrait-enter {
  from {
    opacity: 0;
    transform: translateY(14px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}
@keyframes portrait-drift {
  from {
    transform: translateY(0) rotate(-0.4deg);
  }
  to {
    transform: translateY(-7px) rotate(0.4deg);
  }
}
