:root {
  --bg: #f6efe4;
  --bg-accent: #ffd8a8;
  --panel: rgba(255, 251, 245, 0.8);
  --text: #1d1a16;
  --muted: #6f6458;
  --line: rgba(29, 26, 22, 0.12);
  --strong: #cb5f2d;
  --strong-dark: #8f3815;
  --shadow: 0 24px 80px rgba(81, 41, 16, 0.16);
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  min-height: 100vh;
  background:
    radial-gradient(circle at top left, rgba(255, 255, 255, 0.8), transparent 28%),
    radial-gradient(circle at bottom right, rgba(203, 95, 45, 0.24), transparent 24%),
    linear-gradient(135deg, var(--bg), #f9f4ea 44%, var(--bg-accent));
  color: var(--text);
  font-family: "Space Grotesk", sans-serif;
}

.shell {
  width: min(1080px, calc(100% - 32px));
  margin: 0 auto;
  padding: 48px 0 64px;
}

.hero {
  max-width: 720px;
  margin-bottom: 28px;
}

.eyebrow {
  margin: 0 0 12px;
  color: var(--strong-dark);
  font-family: "IBM Plex Mono", monospace;
  font-size: 0.82rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
}

h1,
h2,
p {
  margin-top: 0;
}

h1 {
  margin-bottom: 16px;
  font-size: clamp(2.6rem, 7vw, 5.2rem);
  line-height: 0.94;
  letter-spacing: -0.05em;
}

.lede {
  max-width: 56ch;
  color: var(--muted);
  font-size: 1.05rem;
  line-height: 1.6;
}

.panel {
  backdrop-filter: blur(18px);
  background: var(--panel);
  border: 1px solid rgba(255, 255, 255, 0.66);
  border-radius: 28px;
  box-shadow: var(--shadow);
  padding: 24px;
}

.panel + .panel {
  margin-top: 18px;
}

.form {
  display: grid;
  gap: 16px;
}

label span {
  display: block;
  margin-bottom: 8px;
  font-size: 0.94rem;
}

input {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: 18px;
  padding: 16px 18px;
  background: rgba(255, 255, 255, 0.9);
  color: var(--text);
  font: inherit;
}

input:focus {
  outline: 2px solid rgba(203, 95, 45, 0.28);
  border-color: rgba(203, 95, 45, 0.5);
}

button,
.back-link {
  border: 0;
  border-radius: 999px;
  padding: 14px 18px;
  background: linear-gradient(135deg, #d56a31, #b74b1a);
  color: #fff8f0;
  cursor: pointer;
  font: inherit;
  font-weight: 700;
  text-decoration: none;
  transition: transform 140ms ease, opacity 140ms ease;
}

button:hover,
.back-link:hover {
  transform: translateY(-1px);
}

button:disabled {
  cursor: wait;
  opacity: 0.7;
}

.ghost-button {
  background: transparent;
  border: 1px solid var(--line);
  color: var(--text);
  font-weight: 500;
}

.hidden {
  display: none;
}

.result,
.error,
.empty-state,
.link-side p,
.result-meta {
  font-family: "IBM Plex Mono", monospace;
}

.result {
  margin-top: 18px;
  padding: 18px;
  border-radius: 20px;
  background: rgba(255, 255, 255, 0.78);
}

.result-label {
  margin-bottom: 8px;
  color: var(--strong-dark);
}

.result a,
.link-card a {
  color: var(--strong-dark);
  font-weight: 700;
  word-break: break-all;
}

.error {
  margin-top: 18px;
  color: #9d1a18;
}

.panel-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 16px;
}

.links {
  display: grid;
  gap: 14px;
}

.link-card {
  display: grid;
  gap: 10px;
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: 20px;
  background: rgba(255, 255, 255, 0.62);
}

.link-code {
  margin-bottom: 8px;
  color: var(--muted);
  font-family: "IBM Plex Mono", monospace;
  text-transform: uppercase;
  letter-spacing: 0.12em;
}

.link-side {
  color: var(--muted);
  display: grid;
  gap: 6px;
  font-size: 0.9rem;
}

.not-found-page {
  display: grid;
  place-items: center;
  padding: 24px;
}

.not-found {
  max-width: 540px;
  padding: 36px;
  border-radius: 28px;
  background: rgba(255, 251, 245, 0.88);
  box-shadow: var(--shadow);
}

.checkin-page {
  background:
    radial-gradient(circle at top left, rgba(255, 240, 215, 0.48), transparent 22%),
    radial-gradient(circle at bottom right, rgba(167, 115, 68, 0.28), transparent 24%),
    linear-gradient(135deg, #f4eadb 0%, #eadcc7 35%, #d7c0a0 100%);
  color: #261a12;
  font-family: "Manrope", sans-serif;
}

.checkin-shell {
  min-height: 100vh;
  display: grid;
  place-items: center;
  padding: 20px;
}

.checkin-card {
  position: relative;
  overflow: hidden;
  width: min(620px, 100%);
  padding: 24px;
  border: 1px solid rgba(74, 49, 31, 0.12);
  border-radius: 28px;
  background:
    linear-gradient(145deg, rgba(255, 250, 243, 0.92), rgba(241, 230, 210, 0.9)),
    rgba(255, 250, 243, 0.84);
  box-shadow: 0 24px 64px rgba(74, 49, 31, 0.16);
}

.checkin-card::before {
  content: "";
  position: absolute;
  inset: 12px;
  border: 1px solid rgba(116, 80, 53, 0.08);
  border-radius: 20px;
  pointer-events: none;
}

.checkin-topline {
  position: relative;
  z-index: 1;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 18px;
}

.checkin-kicker,
.checkin-label {
  margin: 0;
  color: #8f6542;
  font-size: 0.72rem;
  letter-spacing: 0.22em;
  text-transform: uppercase;
}

.checkin-pill {
  border: 1px solid rgba(116, 80, 53, 0.14);
  border-radius: 999px;
  padding: 8px 12px;
  color: #5f4129;
  background: rgba(255, 255, 255, 0.38);
  font-size: 0.78rem;
}

.checkin-overline {
  margin: 0 0 10px;
  color: #9e744f;
  font-size: 0.74rem;
  letter-spacing: 0.24em;
  text-transform: uppercase;
}

.checkin-card h1 {
  margin-bottom: 10px;
  color: #2d1b11;
  font-family: "Cormorant Garamond", serif;
  font-size: clamp(2.4rem, 6vw, 3.6rem);
  line-height: 0.92;
  letter-spacing: -0.05em;
}

.checkin-copy {
  max-width: 34rem;
  color: #6d5340;
  font-size: 0.95rem;
  line-height: 1.6;
}

.checkin-panel {
  margin-top: 18px;
  padding: 18px;
  border: 1px solid rgba(116, 80, 53, 0.12);
  border-radius: 22px;
  background:
    linear-gradient(180deg, rgba(255, 254, 251, 0.92), rgba(247, 237, 221, 0.88));
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.5);
}

.checkin-panel-head {
  display: grid;
  gap: 8px;
  margin-bottom: 14px;
}

.checkin-note {
  margin: 0;
  color: #7c5f49;
  font-size: 0.95rem;
  line-height: 1.5;
}

.checkin-prompt {
  margin: 0 0 16px;
  color: #23150d;
  font-size: clamp(1.2rem, 3.2vw, 1.7rem);
  font-weight: 700;
  line-height: 1.2;
}

.checkin-form {
  display: grid;
  gap: 8px;
}

.checkin-form label {
  color: #6f543f;
  font-size: 0.92rem;
}

.checkin-row {
  display: grid;
  gap: 10px;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: stretch;
}

.checkin-form input {
  min-height: 48px;
  border-color: rgba(116, 80, 53, 0.16);
  background: rgba(255, 255, 255, 0.92);
  color: #24180e;
  border-radius: 16px;
  padding: 12px 16px;
}

.checkin-form input:focus {
  outline: 2px solid rgba(192, 150, 104, 0.26);
  border-color: rgba(176, 128, 77, 0.58);
}

.checkin-form button {
  min-height: 48px;
  min-width: 152px;
  background: linear-gradient(135deg, #b9844d, #9f6430);
  box-shadow: 0 16px 30px rgba(159, 100, 48, 0.22);
}

.checkin-status,
.checkin-error {
  margin-top: 18px;
  font-family: "Manrope", sans-serif;
  line-height: 1.6;
}

.checkin-status {
  color: #3e6d34;
}

.checkin-error {
  color: #a23a32;
}

@media (max-width: 767px) {
  .checkin-card {
    padding: 18px;
    border-radius: 24px;
  }

  .checkin-card h1 {
    font-size: clamp(2rem, 12vw, 3rem);
  }

  .checkin-topline {
    align-items: flex-start;
    flex-direction: column;
  }

  .checkin-row {
    grid-template-columns: 1fr;
  }

  .checkin-form button {
    width: 100%;
    min-width: 0;
  }
}
