/* Shared sleek password gate — password field + Confirm / Cancel only */
.password-modal {
  position: fixed;
  inset: 0;
  z-index: 120;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 1rem;
  background: rgba(0, 0, 0, 0.72);
  box-sizing: border-box;
}

.password-modal.is-open {
  display: flex;
}

.password-modal[hidden] {
  display: none !important;
}

.password-dialog {
  width: min(340px, 100%);
  border: 1px solid #2f2f2f;
  border-radius: 12px;
  padding: 0.58rem 0.68rem;
  background: rgba(9, 9, 9, 0.96);
  box-shadow: 0 14px 36px rgba(0, 0, 0, 0.52);
  font-family: Arial, sans-serif;
  color: #fff;
  box-sizing: border-box;
}

.password-error {
  margin: 0;
  min-height: 0;
  color: #ffb4b4;
  font-size: 0.82rem;
  line-height: 1.25;
}

.password-error:empty {
  display: none;
}

.password-error:not(:empty) {
  margin-bottom: 0.42rem;
}

.password-input {
  display: block;
  width: 100%;
  box-sizing: border-box;
  border: 1px solid #363636;
  background: rgba(10, 9, 7, 0.88);
  color: #fff;
  border-radius: 8px;
  padding: 0.56rem 0.66rem;
  font: inherit;
  font-size: 0.95rem;
}

.password-input::placeholder {
  color: rgba(255, 255, 255, 0.45);
}

.password-actions {
  display: flex;
  gap: 0.5rem;
  margin-top: 0.48rem;
}

.password-button {
  flex: 1;
  appearance: none;
  border: 1px solid rgba(212, 175, 55, 0.52);
  background: linear-gradient(180deg, rgba(120, 175, 220, 0.24), rgba(9, 18, 28, 0.84));
  color: #e8f4ff;
  border-radius: 8px;
  padding: 0.46rem 0.72rem;
  font: inherit;
  font-weight: 700;
  font-size: 0.88rem;
  cursor: pointer;
  box-shadow:
    inset 0 0 0 1px rgba(255, 255, 255, 0.08),
    0 6px 14px rgba(0, 0, 0, 0.22);
}

.password-button-secondary {
  border-color: rgba(212, 175, 55, 0.35);
  background: linear-gradient(180deg, rgba(30, 30, 30, 0.92), rgba(12, 12, 12, 0.96));
  color: rgba(232, 244, 255, 0.88);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.04);
}

.password-button:disabled {
  opacity: 0.55;
  cursor: wait;
}

.password-faceid-row {
  display: flex;
  flex-direction: column;
  gap: 0.42rem;
  margin-top: 0.45rem;
}

.password-button-faceid,
.password-button-faceid-setup {
  width: 100%;
  border-color: rgba(212, 175, 55, 0.62);
  background: linear-gradient(180deg, rgba(212, 175, 55, 0.2), rgba(40, 32, 12, 0.9));
  color: #ffe08a;
}

.password-button-faceid[hidden],
.password-button-faceid-setup[hidden],
.password-button-faceid-skip[hidden] {
  display: none;
}

@media (min-width: 769px) {
  .password-faceid-row {
    display: none;
  }
}
