body, * {
  margin: 0;
  padding: 0;
  border: 0;
}

#backdrop {
  position: absolute;
  min-height: 100%;
  font-size: 20px;
  font-family: 'Roboto';

  background: var(--color-bkgrd);
  color: var(--color-text);

  -webkit-touch-callout: none;    /* prevent selection of all contained elements */
  -webkit-user-select: none;
  -khtml-user-select: none;
  -moz-user-select: none;
  -ms-user-select: none;
  -o-user-select: none;
  user-select: none;

  -webkit-user-drag: none;        /* prevent dragging of all contained elements */
  -khtml-user-drag: none;
  -moz-user-drag: none;
  -ms-user-drag: none;
  -o-user-drag: none;
  user-drag: none;
}

#backdrop p {
  margin-top: 0.5em;
}
#backdrop a {
  color: color-mix(in hsl, var(--color-light), #000 40%);
}
#backdrop a:hover {
  color: color-mix(in hsl, var(--color-dark), #fff 70%);
}

.atlas-btn {
  color: var(--color-text);
  background-color: var(--color-mid);
  display: inline;
  font-size: 0.9rem;
  font-weight: bold;
  padding: 0.3rem 0.7rem;
  margin-left: 0.5rem;
  cursor: pointer;
}
.atlas-btn:hover {
  color: var(--color-mid);
  background-color: var(--color-text);
}

/* -------------------- AUTH -------------------- */

#pm-login-btn {
  position: absolute;
  left: 1.25rem;
  top: 1.25rem;
  width: 2.5rem;
  height: 2.5rem;
  border: solid 1px var(--color-text);
  border-radius: 0.25rem;
  background-color: #f7f7ff;
  box-shadow: inset 0 0 1rem #c0c0d0;
  text-align: center;
  cursor: pointer;
}
#pm-login-btn:hover {
  background-color: #ffffff;
  box-shadow: inset 0 0 1rem #c0c0ff;
}
#pm-btn-icon {
  width: 1.75rem;
  margin-top: 0.25rem;
  pointer-events: none;
}

#pm-login-form {
  text-align: center;
  border: solid 1px #000000;
  padding: 0.8rem;
  width: fit-content;
  position: absolute;
  left: 1rem;
  top: 1rem;
  background-color: #ffffff;
  color: var(--color-dark);
  border-radius: 0.5rem;
  box-shadow: 0.25rem 0.25rem 0.5rem 0.1rem color-mix(in hsl, var(--color-bkgrd) 30%, #000);
  z-index: 5;
  font-size: 1.3rem;
  font-weight: bold;
}
.label-minor {
  font-size: 1rem;
}

.btn {
  width: fit-content;
  font-size: 1rem;
  background-color: var(--color-mid);
  color: var(--color-light);
  padding: 0.25rem 1rem;
  text-align: center;
  border-radius: 0.3rem;
  text-decoration: none;
  cursor: pointer;
}
.btn:hover {
  color: var(--color-dark);
}

#login-btn, #logout-btn {
  display: inline-block;
  margin-top: 0.5rem;
}

#close {
  position: absolute;
  top: 0.25em;
  right: 0.5em;
  color: color-mix(in hsl, var(--color-dark) 30%, #fff);
  cursor: pointer;
}
#close:hover {
  color: color: var(--color-dark);
}

.log-input {
  width: 16rem;
  margin: 5px;
  font-size: 16px;
  padding: 3px;
  border: solid 1px #c0c0c0;
}
#pswd {
  margin-left: unset;
}

#pswd-view {
  display: inline-block;
  height: 1.15rem;
  width: 0.15rem;
  margin: 0 0.25rem 0.4rem -1.85rem;
  padding: 0.3rem 0.6rem 0 0.3rem;
  font-size: 1.5rem;
  font-variant: super;
  vertical-align: bottom;
}

#reset-pswd {
  display: inline-block;
  width: fit-content;
  text-decoration: underline;
  color: color-mix(in hsl, var(--color-light), var(--color-dark) 70%);
  cursor: pointer;
  font-size: 1rem;
}
#reset-pswd:hover {
  color: color-mix(in hsl, var(--color-light) 70%, var(--color-dark));
}
.action {width: 100%;}
.action .error {
  margin: 0.5em;
  font-size: 1.1rem;
  font-weight: bold;
  text-align: center;
  color: #ff0000;
}
.inactive { color: #c0c0c0; !important }
.hidden { display: none; }

/* -------------------- HEADER -------------------- */

#header {
  text-align: center;
  margin: 1.5rem 1.5rem 0.5rem 1.5rem;
}
#header-title {
  position: relative;
  display: inline-flex;
  flex-direction: column;
}
#acct-logo {
  width: 8rem;
  margin-right: 0.75rem;
  vertical-align: top;
}

#atlas-desc {
  width: 90%;
  margin: 0.5rem auto 1rem auto;
  font-size: 1.1rem;
  font-weight: normal;
  text-align: left;
}

#pm-logo {
  width: 15rem;
  height: 5rem;
  margin-left: calc(50% - 7.5rem);
  display: none;
}
#user-lock {
  height: 5rem;
  display: none;  
}

#token {
  font-size: 0.8em;
  border: solid 1px var(--color-text);
  margin-top: 1rem;
  padding: 0.25rem;
  width: 12rem;
  background-color: #fff !important;
  color: var(--color-dark);
}
input::placeholder {              /* Chrome, Firefox, Opera, Safari 10.1+ */
  color: color-mix(in hsl, var(--color-dark) 30%, #fff);
  opacity: 1;                /* Firefox */
}
input::-ms-input-placeholder {    /* Internet Explorer 10-11 */
  color: color-mix(in hsl, var(--color-dark) 30%, #fff);
}
input::-ms-input-placeholder {    /* Microsoft Edge */
  color: color-mix(in hsl, var(--color-dark) 30%, #fff);
}

#lock-msg {
  margin-top: 0.25rem;
  font-size: 1.1rem;
  font-weight: bold;
  padding: 0.25rem;
  color: #ff0000;
  background-color: rgba(255,255,255, 0.6);
}
#lock-msg:empty {
  background-color: transparent;
}

/* -------------------- CONTENT -------------------- */

#atlas-mask {
  display: none;
  position: fixed !important;
  margin: 0 !important;
  padding: 0 !important;
  border: 0 !important;
  top: 0 !important;
  left: 0 !important;
  width: 100vw !important;
  height: 100% !important;
  z-index: 1000 !important;
}
#atlas {
  position: relative;
  width: 90%;
  margin-left: auto;
  margin-right: auto;
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}

.info {
  position: relative;
  display: flex;
  width: 100%;
  min-height: 14rem;
  text-align: left;
  flex-direction: row;
  gap: 1rem;
}
.launcher {
  position: relative;
  float: left;
  font-size: 0.9rem;
  width: 14.5rem;
  max-width: 14.5rem;
  height: 12.5rem;
  max-height: 12.5rem;
  border: 3px solid var(--color-text);
  background-color: var(--color-mid);
  flex: 1 0 auto;
}

/* http://www.mademyday.de/css-height-equals-width-with-pure-css.html */
.launcher:before {
  content: "";
  display: block;
  padding-top: 84%;
}

.case {
  position: absolute;
  width: 100%;
  height: 100%;
  top: 0;
  left: 0;
  bottom: 0;
  right: 0;
  overflow: hidden;
}
.mat {
  width: 100%;
  height: 100%;
  z-index: 1;
}
.puz {
  position: absolute;
  width: calc(100% - 2rem);
  min-width: 85%;
  height: calc(100% - 2.25rem);
  object-fit: cover;
  left: 0;
  right: 0;
  top: 0;
  bottom: 0;
  margin: auto;
  border: 1px solid #000000;
  z-index: 2;
}

.spot {
  position: absolute;
  display: block;
  width: 30%;
  height: auto;
  left: 0;
  right: 0;
  top: 0;
  bottom: 0;
  margin: auto;
  z-index: 3;
  cursor: pointer;
}
.score {
  position: absolute;
  display: block;
  visibility: hidden;
  left: 0;
  right: 0;
  top: 60%;
  bottom: 0;
  margin: auto;
  width: 32%;
  height: 1.15rem;
  border: 2px solid var(--color-bkgrd);
  border-radius: 0.625rem;
  text-align: center;
  font-weight: bold;
  background-color: var(--color-text);
  color: var(--color-bkgrd);
  z-index: 4;
}
.puz-desc {
  display: table;
  font-size: 1.1rem;
}
.dropdown {
  display: inline-block;
  font-size: 1em;
  width: 7em;
  padding: 0.1rem 0.2rem;
  background-color: #fff;
  border: solid 1px var(--color-dark);
  border-radius: 0.25rem;
  color: var(--color-dark);
}
.boxtop { float: right; }

/* -------------------- FOOTER -------------------- */

hr {
  width: 80%;
  margin-left: 10%;
  border-top: 1px solid var(--color-text);
}
#footer {
  width: 100%;
  padding: 2rem 0 1rem 0;
  font-size: 0.8rem;
  text-align: center;
  background-color: var(--color-bkgrd);
}
#footer p {
  font-size: 0.9rem;
}
#footer img {
  width: 14rem;
  margin: 0 !important;
}

@media screen and (max-width: 1440px), screen and (max-height: 1440px) {
  #backdrop { font-size: 19px; }

}
@media screen and (max-width: 1280px), screen and (max-height: 1280px) {
  #backdrop { font-size: 18px; }

}
@media screen and (max-width:  720px), screen and (max-height:  720px) {
  #backdrop { font-size: 17px; }
  #atlas { gap: 2.5rem; }
  .info { flex-direction: column; }
}
