/* Geist ships with the app (SIL Open Font Licence, fonts/GEIST-LICENSE.txt):
   no wait on Google Fonts before the first screen, and it works offline. */
@font-face {
  font-family: "Geist";
  src: url("../fonts/Geist-Variable.woff2") format("woff2");
  font-weight: 100 900;
  font-style: normal;
  font-display: swap;
}

/* The real app (novit-app): sign-in and first run, and the few pieces the
   demo doesn't have. Uses the app's own colours (app.css). */

.panel { display: none; }                   /* demo controls: not in the real app */
.stage { justify-content: center; }

.row-danger, .row-danger svg { color: var(--red); }
.btn-fill.btn-danger { background: var(--red); color: var(--on-red); }

.gate {
  position: fixed; inset: 0; z-index: 50; overflow: hidden;
  display: flex; flex-direction: column;
  background: var(--app-bg); color: var(--label);
  font-family: var(--font-ui); font-size: 17px; line-height: 1.4;
  -webkit-font-smoothing: antialiased;
  /* The status bar band stays put; only the content below it scrolls, so
     nothing slides under the clock when the keyboard pushes the form up. */
  padding-top: env(safe-area-inset-top);
}
.gate-inner {
  flex: 1; min-height: 0; overflow-y: auto; overscroll-behavior: contain;
  width: 100%; max-width: 448px; margin: 0 auto; box-sizing: border-box;
  padding: 24px 24px max(env(safe-area-inset-bottom), 24px);
  display: flex; flex-direction: column;
}
.gate-top { flex: 1; display: flex; flex-direction: column; justify-content: center; align-items: flex-start; padding: 48px 0 32px; }
.gate-mark { width: 68px; height: 44px; color: var(--label); }
.gate-title { font-family: var(--font-display); font-weight: 700; font-size: 44px; letter-spacing: -1.2px; line-height: 1; margin: 20px 0 12px; }
.gate-h { font-family: var(--font-display); font-weight: 700; font-size: 30px; letter-spacing: -0.6px; line-height: 1.1; margin: 8px 0 8px; }
.gate-lede { color: var(--label-2); margin: 0 0 8px; max-width: 32ch; }
.gate-actions { display: flex; flex-direction: column; gap: 12px; padding-bottom: 8px; }
.gate-form { display: flex; flex-direction: column; padding: 16px 0 24px; }
.gate-label { font-size: 15px; font-weight: 600; margin: 18px 0 6px; }
.gate-hint, .gate-fine { font-size: 13px; color: var(--label-2); margin: 6px 0 0; }
.gate-fine { text-align: center; }
.gate-input {
  font: inherit; color: inherit; background: var(--cell); width: 100%; box-sizing: border-box;
  border: 0; border-radius: 12px; box-shadow: inset 0 0 0 1px var(--field-edge);
  padding: 13px 14px; min-height: 50px; -webkit-appearance: none; appearance: none;
}
.gate-input:focus { outline: none; box-shadow: inset 0 0 0 2px var(--tint); }
.gate-code { font-size: 28px; letter-spacing: 8px; font-variant-numeric: tabular-nums; text-align: center; }
.gate-at { position: relative; }
.gate-at span { position: absolute; left: 14px; top: 50%; transform: translateY(-50%); color: var(--label-2); }
.gate-at .gate-input { padding-left: 32px; }
.gate-check { display: flex; gap: 10px; align-items: flex-start; margin-top: 16px; font-size: 15px; }
.gate-check input { width: 22px; height: 22px; margin: 0; flex: none; accent-color: var(--tint); }
.gate-check a { color: var(--tint); }
.gate-invited { margin: 14px 0 0; padding: 12px 14px; border-radius: 12px; background: var(--tint-soft); color: var(--label); font-size: 15px; }
.gate-error { color: var(--red); font-size: 15px; margin: 14px 0 0; }
.gate-btn {
  font: inherit; font-weight: 600; border: 0; border-radius: 14px; min-height: 52px; width: 100%;
  display: inline-flex; align-items: center; justify-content: center; gap: 8px; cursor: pointer;
}
.gate-form .gate-btn { margin-top: 24px; }
.gate-fill { background: var(--pop); color: var(--on-pop); }
.gate-fill:disabled { opacity: .5; }
.gate-apple { background: #000; color: #fff; }
.gate-apple svg { width: 20px; height: 20px; }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) .gate-apple { background: #fff; color: #000; } }
.gate-back, .gate-link {
  font: inherit; font-size: 16px; background: none; border: 0; color: var(--tint); padding: 10px 0; cursor: pointer; align-self: flex-start;
}
.gate-link { align-self: center; margin-top: 8px; }
.gate-btn:active, .gate-back:active, .gate-link:active { opacity: .7; }
