/* Isolated lock-screen stylesheet. No QR Studio application styles are loaded here. */
* { box-sizing: border-box; }
html {
  min-width: 0;
  min-height: 100%;
  background: #f2f4f6;
  color-scheme: light;
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
}
body {
  margin: 0;
  min-width: 0;
  min-height: 100vh;
  min-height: 100svh;
  overflow-x: hidden;
  color: #15181d;
  background: #f2f4f6;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Inter, Helvetica, Arial, sans-serif;
  -webkit-font-smoothing: antialiased;
}
button, input { font: inherit; }
button { -webkit-tap-highlight-color: transparent; }
svg { display: block; }

.access-shell {
  width: 100%;
  min-height: 100vh;
  min-height: 100svh;
  display: flex;
  align-items: flex-start;
  justify-content: center;
  padding-top: max(18px, calc(env(safe-area-inset-top) + 12px));
  padding-right: max(12px, env(safe-area-inset-right));
  padding-bottom: max(20px, calc(env(safe-area-inset-bottom) + 12px));
  padding-left: max(12px, env(safe-area-inset-left));
}

.access-card {
  width: 100%;
  max-width: 480px;
  margin: 0 auto;
  overflow: hidden;
  background: #ffffff;
  border: 1px solid #d9dee4;
  border-radius: 20px;
  box-shadow: 0 18px 48px rgba(24, 32, 42, 0.10), 0 2px 8px rgba(24, 32, 42, 0.05);
}

.access-header {
  min-height: 66px;
  display: flex;
  align-items: center;
  gap: 11px;
  padding: 13px 16px;
  background: #fbfcfd;
  border-bottom: 1px solid #e8ebef;
}
.brand-mark {
  width: 38px;
  height: 38px;
  flex: 0 0 38px;
  display: grid;
  place-items: center;
  border-radius: 10px;
  background: #15181d;
}
.brand-mark svg { width: 22px; height: 22px; color: #fff; fill: none; }
.brand-copy { min-width: 0; display: grid; gap: 2px; }
.brand-copy strong { font-size: 14px; line-height: 1.15; letter-spacing: -0.01em; }
.brand-copy span { color: #7a828d; font-size: 11px; line-height: 1.25; }

.access-body { padding: 24px 18px 22px; }
.security-badge {
  width: fit-content;
  display: inline-flex;
  align-items: center;
  gap: 7px;
  min-height: 28px;
  padding: 0 10px;
  margin-bottom: 18px;
  border: 1px solid #dfe4e8;
  border-radius: 999px;
  background: #f8fafb;
  color: #606974;
  font-size: 10px;
  font-weight: 800;
  letter-spacing: 0.045em;
  text-transform: uppercase;
}
.security-badge span {
  width: 7px;
  height: 7px;
  flex: 0 0 7px;
  border-radius: 50%;
  background: #24833b;
  box-shadow: 0 0 0 3px rgba(36, 131, 59, 0.10);
}
.lock-icon {
  width: 44px;
  height: 44px;
  display: grid;
  place-items: center;
  margin-bottom: 16px;
  border: 1px solid #dfe3e7;
  border-radius: 12px;
  background: #f7f8fa;
}
.lock-icon svg { width: 22px; height: 22px; fill: #383f48; }

.access-copy { min-width: 0; }
.eyebrow {
  margin: 0 0 7px;
  color: #69727d;
  font-size: 10px;
  font-weight: 800;
  letter-spacing: 0.09em;
  text-transform: uppercase;
}
h1 {
  margin: 0;
  color: #12151a;
  font-size: 27px;
  line-height: 1.08;
  letter-spacing: -0.035em;
  overflow-wrap: normal;
  word-break: normal;
}
.description {
  margin: 10px 0 0;
  color: #69727d;
  font-size: 13px;
  line-height: 1.5;
}

.access-form { margin-top: 23px; }
.field-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 8px;
}
.field-head label { color: #30363d; font-size: 12px; font-weight: 750; }
.field-head span { color: #8a929b; font-size: 10px; white-space: nowrap; }
.input-wrap { position: relative; width: 100%; }
.input-wrap input {
  display: block;
  width: 100%;
  height: 56px;
  min-height: 56px;
  padding: 0 54px 0 15px;
  border: 1px solid #cfd5db;
  border-radius: 12px;
  outline: none;
  background: #fff;
  color: #16191d;
  font-size: 16px;
  font-weight: 600;
  letter-spacing: 0.02em;
  -webkit-appearance: none;
  appearance: none;
}
.input-wrap input::placeholder { color: #9ca3ac; font-weight: 450; letter-spacing: 0; }
.input-wrap input:focus { border-color: #59636e; box-shadow: 0 0 0 4px rgba(31, 38, 46, 0.07); }
.reveal-button {
  position: absolute;
  top: 6px;
  right: 6px;
  width: 44px;
  height: 44px;
  display: grid;
  place-items: center;
  padding: 0;
  border: 0;
  border-radius: 9px;
  background: transparent;
  color: #707985;
  touch-action: manipulation;
}
.reveal-button svg { width: 19px; height: 19px; fill: currentColor; }
.field-help { margin: 7px 1px 0; color: #89919a; font-size: 10.5px; line-height: 1.35; }
.field-error {
  min-height: 20px;
  margin: 7px 1px 2px;
  color: #b42318;
  font-size: 11.5px;
  font-weight: 650;
  line-height: 1.35;
}
.submit-button {
  width: 100%;
  min-height: 56px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  margin: 5px 0 0;
  padding: 0 16px;
  border: 0;
  border-radius: 12px;
  background: #15181d;
  color: #fff;
  font-size: 13px;
  font-weight: 760;
  cursor: pointer;
  touch-action: manipulation;
  box-shadow: 0 7px 18px rgba(21, 24, 29, 0.14);
}
.submit-button svg { width: 17px; height: 17px; fill: currentColor; }
.submit-button:active:not(:disabled) { transform: translateY(1px); }
.submit-button:disabled { opacity: 0.62; cursor: wait; }

.access-footer {
  min-height: 46px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-wrap: wrap;
  gap: 7px;
  padding: 10px 14px;
  border-top: 1px solid #e8ebef;
  background: #fafbfc;
  color: #8a929c;
  font-size: 9.5px;
  font-weight: 650;
  line-height: 1.25;
  text-align: center;
}
.access-footer i { width: 3px; height: 3px; border-radius: 50%; background: #b3b9c0; }

.access-form.access-denied .input-wrap { animation: shake 0.28s ease; }
.access-form.access-denied input { border-color: #c9342d; box-shadow: 0 0 0 4px rgba(201, 52, 45, 0.07); }
html.access-success .access-card { opacity: 0.62; transform: scale(0.996); transition: opacity 0.14s ease, transform 0.14s ease; }

@keyframes shake {
  0%, 100% { transform: translateX(0); }
  30% { transform: translateX(-4px); }
  70% { transform: translateX(4px); }
}

/* Narrow iPhones: reduce density without changing the page's positioning model. */


/* Desktop/tablet enhancement. Mobile does not inherit a collapsed desktop grid. */
@media (min-width: 700px) {
  .access-shell {
    align-items: center;
    padding: max(32px, env(safe-area-inset-top)) max(24px, env(safe-area-inset-right)) max(32px, env(safe-area-inset-bottom)) max(24px, env(safe-area-inset-left));
  }
  .access-card { max-width: 520px; border-radius: 22px; }
  .access-header { min-height: 76px; padding: 17px 20px; }
  .access-body { padding: 32px 32px 29px; }
  .security-badge { margin-bottom: 20px; }
  .lock-icon { width: 48px; height: 48px; margin-bottom: 20px; }
  h1 { font-size: 29px; }
  .description { font-size: 13.5px; }
  .access-form { margin-top: 27px; }
  .access-footer { min-height: 49px; font-size: 10px; }
  .reveal-button:hover { background: #f2f4f6; }
  .submit-button:hover:not(:disabled) { filter: brightness(1.1); }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; }
}

/* Extra narrow-screen hardening */
.access-card,
.access-header,
.access-body,
.access-form,
.input-wrap { min-width: 0; max-width: 100%; }
.brand-copy strong,
.brand-copy span,
.description,
.field-help,
.field-error { overflow-wrap: anywhere; }

@supports not (overflow-x: clip) { html, body { overflow-x: hidden; } }

/* Mobile access screen cleanup */
@media (max-width: 560px) {
  html, body { max-width: 100%; overflow-x: clip; }
  .access-shell {
    width: 100%;
    max-width: 100%;
    min-height: 100svh;
    padding:
      max(12px, calc(env(safe-area-inset-top) + 8px))
      max(11px, env(safe-area-inset-right))
      max(14px, env(safe-area-inset-bottom))
      max(11px, env(safe-area-inset-left));
    align-items: start;
  }
  .access-card {
    width: 100%;
    max-width: 100%;
    border-radius: 19px;
    overflow: hidden;
  }
  .access-header {
    min-height: 62px;
    padding: 11px 13px;
  }
  .brand-mark { width: 36px; height: 36px; flex-basis: 36px; }
  .brand-copy { min-width: 0; }
  .brand-copy strong,
  .brand-copy span { overflow-wrap: anywhere; }
  .access-body { padding: 20px 16px 19px; }
  .security-badge { margin-bottom: 15px; max-width: 100%; }
  .lock-icon { margin-bottom: 14px; }
  .access-copy h1,
  h1 { font-size: 24px; overflow-wrap: anywhere; }
  .description { font-size: 12.5px; overflow-wrap: anywhere; }
  .access-form { width: 100%; max-width: 100%; margin-top: 20px; }
  .field-head {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 8px;
    flex-wrap: wrap;
  }
  .field-head span { white-space: normal; text-align: right; }
  .input-wrap,
  .input-wrap input { width: 100%; max-width: 100%; min-width: 0; }
  .input-wrap input { font-size: 16px; }
  .field-help,
  .field-error { overflow-wrap: anywhere; }
  .submit-button { width: 100%; max-width: 100%; min-width: 0; }
  .access-footer { flex-wrap: wrap; justify-content: center; text-align: center; }
}

@media (max-width: 360px) {
  .access-shell {
    padding-left: max(9px, env(safe-area-inset-left));
    padding-right: max(9px, env(safe-area-inset-right));
  }
  .access-body { padding: 18px 14px 17px; }
  .field-head span { display: none; }
  .access-footer i { display: none; }
}

/* Center QR Studio as one identity block; do not let icon width bias the header. */
.access-header {
  display: flex !important;
  justify-content: center !important;
  align-items: center !important;
}
.access-brand {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 11px;
  width: fit-content;
  max-width: 100%;
  margin-inline: auto;
}
.access-brand .brand-mark { flex: 0 0 38px; }
.access-brand .brand-mark .qr-studio-mark {
  display: block !important;
  width: 22px !important;
  height: 22px !important;
  margin: 0 !important;
  transform: none !important;
}
@media (max-width: 560px) {
  .access-brand {
    display: grid;
    grid-template-columns: 1fr;
    justify-items: center;
    gap: 6px;
    text-align: center;
  }
  .access-brand .brand-mark { width: 36px; height: 36px; flex-basis: 36px; }
  .access-brand .brand-copy { text-align: center; justify-items: center; }
  .access-brand .brand-mark .qr-studio-mark { width: 22px !important; height: 22px !important; }
}
