:root {
  color-scheme: dark;
  background: #000;
}

html,
body {
  width: 100%;
  min-width: 320px;
  height: 100%;
  min-height: 100%;
  margin: 0;
  overflow: hidden;
  background: #000;
}

.gallery-embed {
  width: 100vw;
  height: 100vh;
  height: 100dvh;
  overflow: hidden;
  background: #000;
}

.gallery-embed__frame {
  display: block;
  width: 100%;
  height: 100%;
  border: 0;
  background: #000;
}

.gallery-embed__frame[hidden] {
  display: none;
}

.gallery-auth,
.gallery-welcome,
.gallery-lock {
  position: fixed;
  inset: 0;
  z-index: 10;
  display: grid;
  place-items: center;
  padding: 24px;
  box-sizing: border-box;
  background: #050505;
  color: #fff;
  font-family: Georgia, 'Times New Roman', serif;
}

.gallery-auth[hidden],
.gallery-welcome[hidden],
.gallery-lock[hidden] {
  display: none;
}

.gallery-auth__card,
.gallery-welcome__card,
.gallery-lock__card {
  width: min(520px, 100%);
  padding: clamp(24px, 5vw, 42px);
  box-sizing: border-box;
  border: 1px solid #303030;
  background: #111;
}

.gallery-auth__card {
  max-height: calc(100dvh - 48px);
  overflow-y: auto;
}

.gallery-auth h1,
.gallery-welcome h1,
.gallery-lock h1 {
  margin: 0 0 14px;
  font-size: clamp(25px, 5vw, 38px);
  line-height: 1.05;
  font-weight: 400;
}

.gallery-auth__lead,
.gallery-welcome span,
.gallery-lock p:not(.gallery-lock__brand) {
  margin: 0;
  color: #b9b9b9;
  line-height: 1.6;
}

.gallery-auth__tabs {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  margin-top: 28px;
  border: 1px solid #383838;
}

.gallery-auth__tabs button {
  min-height: 46px;
  padding: 0 12px;
  border: 0;
  background: transparent;
  color: #a9a9a9;
  font: inherit;
  font-size: 13px;
  font-weight: 800;
  cursor: pointer;
}

.gallery-auth__tabs button + button {
  border-left: 1px solid #383838;
}

.gallery-auth__tabs button[aria-selected='true'] {
  background: #aeff00;
  color: #050505;
}

.gallery-auth__form {
  display: grid;
  gap: 16px;
  margin-top: 22px;
}

.gallery-auth__form[hidden] {
  display: none;
}

.gallery-auth__form label {
  display: grid;
  gap: 7px;
  color: #dedede;
  font-size: 12px;
  font-weight: 700;
}

.gallery-auth__form input {
  width: 100%;
  min-height: 46px;
  padding: 0 13px;
  box-sizing: border-box;
  border: 1px solid #3b3b3b;
  border-radius: 0;
  outline: none;
  background: #080808;
  color: #fff;
  font: inherit;
  font-size: 15px;
}

.gallery-auth__form input:focus {
  border-color: #aeff00;
  box-shadow: 0 0 0 1px #aeff00;
}

.gallery-auth__form button {
  min-height: 48px;
  margin-top: 4px;
  padding: 0 18px;
  border: 1px solid #aeff00;
  background: #aeff00;
  color: #050505;
  font: inherit;
  font-size: 13px;
  font-weight: 900;
  cursor: pointer;
}

.gallery-auth__form button:disabled {
  cursor: wait;
  opacity: 0.65;
}

.gallery-auth__help,
.gallery-auth__status {
  margin: -8px 0 0;
  color: #919191;
  font-size: 12px;
  line-height: 1.45;
}

.gallery-auth__status {
  min-height: 18px;
  margin-top: 16px;
}

.gallery-auth__status[data-state='error'] {
  color: #ff7272;
}

.gallery-auth__status[data-state='success'] {
  color: #aeff00;
}

.gallery-auth__home {
  display: inline-block;
  margin-top: 16px;
  color: #cfcfcf;
  font-size: 12px;
  text-underline-offset: 4px;
}

.gallery-welcome {
  z-index: 9;
  text-align: center;
}

.gallery-welcome__card {
  border-color: #aeff00;
}

.gallery-welcome__card > p {
  margin: 0 0 18px;
  color: #aeff00;
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0.16em;
}

.gallery-lock__brand {
  margin: 0 0 18px;
  color: #aeff00;
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0.16em;
}

.gallery-lock__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 28px;
}

.gallery-lock #gallery-lock-countdown {
  margin-top: 22px;
  color: #aeff00;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
}

.gallery-lock #gallery-lock-countdown-note {
  margin-top: 8px;
  font-size: 12px;
}

.gallery-lock__actions button,
.gallery-lock__actions a {
  min-height: 44px;
  padding: 0 16px;
  border: 1px solid #aeff00;
  background: #aeff00;
  color: #050505;
  font: inherit;
  font-size: 13px;
  font-weight: 800;
  text-decoration: none;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.gallery-lock__actions a {
  border-color: #444;
  background: transparent;
  color: #fff;
}

@media (max-width: 560px) {
  .gallery-auth,
  .gallery-welcome,
  .gallery-lock {
    align-items: stretch;
    padding: 0;
  }

  .gallery-auth__card,
  .gallery-welcome__card,
  .gallery-lock__card {
    width: 100%;
    min-height: 100dvh;
    max-height: 100dvh;
    border: 0;
    display: flex;
    flex-direction: column;
    justify-content: center;
  }

  .gallery-auth__card {
    justify-content: flex-start;
    padding-top: max(30px, env(safe-area-inset-top));
    padding-bottom: max(30px, env(safe-area-inset-bottom));
  }

  .gallery-lock__actions {
    flex-direction: column;
  }
}
