/* The Index / lock.css
 * The gate in front of a client study. It is the first and sometimes the only
 * thing a stranger sees of this project, so it is built like a panel on any
 * other page rather than like an error.
 */

.lock {
  max-width: var(--col-panel); margin: 0 auto; padding: 40px 0 72px;
  display: grid; place-items: center;
}
/* `display` here would otherwise beat the hidden attribute and leave the gate
   sitting on top of the study it just opened. */
.lock[hidden] { display: none; }

.lock__card {
  width: 100%; max-width: 560px;
  background: var(--panel-fill);
  border: 1px solid var(--panel-line);
  border-radius: var(--radius-card);
  padding: 56px 40px 44px;
  text-align: center;
}

.lock__mark {
  margin: 0; font-size: clamp(34px, 6vw, 46px); line-height: 1; font-weight: 600;
  letter-spacing: -.035em; color: var(--ink);
  display: flex; align-items: center; justify-content: center; gap: .2em;
}
.lock__mark .mf-logo {
  flex: none; width: auto; height: .74em; color: #66B037;
  transform: translateY(-.015em);
}

.lock__gloss {
  max-width: 420px; margin: 20px auto 0;
  font-size: 16px; line-height: 1.45; letter-spacing: -.012em; color: var(--ink-soft);
}

/* The four facts a recruiter scans for before deciding whether to ask. */
.lock__facts {
  margin: 28px 0 0; padding: 18px 0;
  border-top: 1px solid var(--line); border-bottom: 1px solid var(--line);
  display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px;
}
.lock__facts div { display: flex; flex-direction: column; gap: 4px; min-width: 0; }
.lock__facts dt {
  font-family: var(--font-mono); font-size: 9.5px; letter-spacing: .09em;
  text-transform: uppercase; color: var(--marker-text);
}
.lock__facts dd { margin: 0; font-size: 13px; line-height: 17px; color: var(--ink); }

.lock__why {
  margin: 24px auto 0; max-width: 440px;
  font-size: 13.5px; line-height: 21px; color: var(--body); text-align: left;
}
.lock__why strong { color: var(--ink); font-weight: 500; }

/* --- the control ---------------------------------------------------------- */

.lock__form { margin: 26px 0 0; display: flex; gap: 8px; align-items: flex-end; text-align: left; }
.lock__field { flex: 1 1 auto; display: flex; flex-direction: column; gap: 6px; min-width: 0; }
.lock__field input {
  width: 100%; box-sizing: border-box;
  height: 40px; padding: 0 13px;
  background: var(--ground);
  border: 1px solid var(--line); border-radius: var(--radius-control, 9px);
  font-family: inherit; font-size: 14px; letter-spacing: .02em; color: var(--ink);
  transition: border-color 160ms var(--ease-expo, ease), box-shadow 160ms var(--ease-expo, ease);
}
.lock__field input::placeholder { color: var(--marker-text); letter-spacing: 0; }
.lock__field input:focus {
  outline: none; border-color: var(--mf-green, #66B037);
  box-shadow: 0 0 0 3px color-mix(in srgb, #66B037 22%, transparent);
}

.lock__go {
  flex: none; height: 40px; padding: 0 17px;
  border: 1px solid transparent; border-radius: var(--radius-control, 9px);
  background: var(--ink); color: var(--ground);
  font-family: inherit; font-size: 13.5px; font-weight: 500; letter-spacing: -.005em;
  cursor: pointer;
  transition: opacity 160ms var(--ease-expo, ease), transform 160ms var(--ease-expo, ease);
}
.lock__go:hover { opacity: .88; }
.lock__go:active { transform: translateY(1px); }
.lock__go:disabled { opacity: .5; cursor: default; transform: none; }

/* Several megabytes come down on submit, so the wait gets a reading. */
.lock__bar {
  margin: 14px 0 0; height: 2px; border-radius: 2px;
  background: color-mix(in srgb, var(--ink) 10%, transparent); overflow: hidden;
}
.lock__bar i {
  display: block; height: 100%; width: 100%;
  background: var(--mf-green, #66B037);
  transform: scaleX(0); transform-origin: left;
  transition: transform 420ms var(--ease-expo, ease);
}

.lock__note {
  margin: 12px 0 0; min-height: 34px;
  font-size: 12.5px; line-height: 17px; color: var(--ink-muted); text-align: left;
}
.lock__note.is-bad { color: var(--mf-red, #D1410C); }

/* Ticking this keeps the phrase on this machine so the page opens on click.
   It is for whoever owns the site, not for a visitor, so it sits quietly. */
.lock__keep {
  margin: 10px 0 0; display: flex; align-items: center; gap: 8px;
  font-size: 12.5px; color: var(--ink-muted); cursor: pointer; user-select: none;
}
.lock__keep input { width: 14px; height: 14px; margin: 0; accent-color: #66B037; cursor: pointer; }
.lock__keep:hover { color: var(--ink-soft); }

.lock__forget {
  margin: 14px 0 0; font-size: 12px; line-height: 17px; color: var(--ink-muted); text-align: left;
}
.lock__forget button {
  padding: 0; border: 0; background: none; cursor: pointer;
  font: inherit; color: var(--ink);
  text-decoration: underline; text-underline-offset: .2em;
}

/* --- the way out ---------------------------------------------------------- */

.lock__ask {
  margin: 20px 0 0; padding-top: 20px; border-top: 1px solid var(--line);
  display: flex; flex-direction: column; gap: 4px; align-items: center;
}
.lock__ask a { font-size: 14.5px; font-weight: 500; color: var(--ink); text-decoration: none; }
.lock__ask a:hover { text-decoration: underline; text-underline-offset: .22em; }

.lock__else { margin: 18px 0 0; font-size: 12.5px; line-height: 18px; color: var(--ink-muted); }
.lock__else a { color: var(--ink); text-decoration: underline; text-underline-offset: .2em; }

@media (max-width: 560px) {
  .lock__card { padding: 40px 22px 34px; }
  .lock__facts { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px 12px; }
  .lock__form { flex-direction: column; align-items: stretch; }
  .lock__go { width: 100%; }
}
