/* security-flows-1.3 — screens behind locked security-1.0 rows.
   Frame, card, and rows quoted from locked security-1.0 / guests-1.0 /
   notifications-1.2. Fields quoted from guests-1.0 hs-lab/hs-field.
   Primary button quoted from locked setup-2.1 .cx-go + #continue pin.
   Confirm sheet uses the locked Stall 1.19 sheet shell. Existing tokens only.
   No invented rules, helper text, or fields. */

/* ---- carried from locked security-1.0 (hero, scrim, stage, card, rows, link) ---- */
.hero { position: absolute; inset: 0; width: 390px; height: 844px; object-fit: cover; object-position: center top; display: block; z-index: 0; }
.hero-scrim {
  position: absolute; inset: 0; z-index: 1; pointer-events: none;
  background:
    linear-gradient(0deg, color-mix(in srgb, var(--color-night) 70%, transparent) 0, color-mix(in srgb, var(--color-night) 28%, transparent) 220px, transparent 420px);
}

.stage {
  position: absolute;
  z-index: 2;
  top: 160px;
  /* Empty step/photo zone: locked setup-1.12 portrait+name (170–403.8, fonts loaded) = 243.8px, so the card top stays at 427.8. */
  padding-top: 243.8px;
  left: 0; right: 0;
  bottom: 52px;
  overflow-x: hidden;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
  overscroll-behavior: contain;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.card {
  width: 350px;
  margin: 24px auto 0;
  background: rgba(20, 19, 26, 0.55);
  -webkit-backdrop-filter: blur(28px) saturate(1.2);
          backdrop-filter: blur(28px) saturate(1.2);
  border-radius: 16px;
  box-shadow: inset 0 0.5px 0 rgba(244, 239, 232, 0.12);
  overflow: hidden;
}

.row {
  appearance: none;
  display: flex;
  align-items: center;
  gap: 12px;
  width: 100%;
  min-height: 44px;
  padding: 9px 16px;
  background: none;
  border: 0;
  border-top: 0.5px solid rgba(244, 239, 232, 0.10);
  color: inherit;
  text-align: left;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}
.row:first-child { border-top: 0; }
.row .aff {
  flex: 0 0 12px;
  width: 12px;
  height: 12px;
  display: grid;
  place-items: center;
  color: var(--color-text-muted);
  opacity: 0.45;
}
.row .aff svg { display: block; }
.row:focus-visible {
  outline: 1px solid color-mix(in srgb, var(--color-solar) 46%, var(--color-text));
  outline-offset: -2px;
}
.row.is-link {
  text-decoration: none;
  color: inherit;
}
.row .lk {
  flex: 1 1 auto;
  font: 500 var(--type-status)/1.25 var(--font-ui);
  color: var(--color-text);
  letter-spacing: 0.01em;
}
.row.is-link .aff svg { width: 5px; height: 8px; stroke-width: 1.2; }

/* ---- quoted guests-1.0 field row (label over hs-field) ---- */
.row.field-row,
.row.msg-row {
  flex-direction: column;
  align-items: stretch;
  gap: 0;
  cursor: default;
  min-height: 0;
}
.row.msg-row { padding: 16px; }
.hs-lab {
  display: block;
  margin: 14px 0 4px;
  font: 600 var(--type-label)/1 var(--font-ui);
  letter-spacing: var(--type-label-tracking);
  text-transform: uppercase;
  color: var(--color-chart-name);
}
.hs-lab:first-child,
.row.field-row .hs-lab { margin-top: 0; }
.hs-field {
  width: 100%;
  height: 44px;
  padding: 0 0 2px;
  border: 0;
  border-bottom: 0.5px solid rgba(244, 239, 232, 0.22);
  background: transparent;
  color: var(--color-text);
  font: 500 16px/1 var(--font-ui);
  letter-spacing: 0.01em;
  outline: none;
  border-radius: 0;
  color-scheme: dark;
}
.hs-field:focus {
  border-bottom-color: color-mix(in srgb, var(--color-solar) 46%, var(--color-text));
}
.hs-actions {
  margin: 18px 0 8px;
  display: grid;
  gap: 4px;
}
.hs-btn {
  appearance: none;
  display: grid;
  place-items: center;
  width: 100%;
  height: 44px;
  border: 0;
  background: none;
  color: color-mix(in srgb, var(--color-solar) 46%, var(--color-text));
  font: 500 15px/1 var(--font-ui);
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}
.hs-btn:focus-visible {
  outline: 1px solid color-mix(in srgb, var(--color-solar) 46%, var(--color-text));
  outline-offset: 2px;
}

.msg-title {
  margin: 0;
  font: 400 var(--type-title)/1.2 var(--font-display);
  font-variation-settings: "SOFT" 50, "opsz" 72;
  letter-spacing: -0.01em;
  color: var(--color-text);
}
.msg-line {
  margin: 8px 0 0;
  font: 500 var(--type-status)/1.4 var(--font-ui);
  color: var(--color-text);
  letter-spacing: 0.01em;
}
.row.msg-row .msg-line:first-child { margin-top: 0; }

/* ---- quoted locked setup-2.1 / comms-1.1 .cx-go, pinned like wizard Next/Done ---- */
.cx-go {
  appearance: none;
  display: grid;
  place-items: center;
  height: 40px;
  padding: 0 18px;
  border-radius: 20px;
  border: 0;
  cursor: pointer;
  font: 600 var(--type-status)/1 var(--font-ui);
  letter-spacing: .02em;
  color: var(--color-night);
  background: color-mix(in srgb, var(--color-solar) 46%, var(--color-text));
  width: 350px;
  margin: 16px auto 0;
  -webkit-tap-highlight-color: transparent;
}
.cx-go:disabled { opacity: .35; cursor: default; }
.cx-go:focus-visible {
  outline: 1px solid color-mix(in srgb, var(--color-solar) 46%, var(--color-text));
  outline-offset: 2px;
}
#continue {
  position: absolute;
  top: 575.61px;
  left: 20px;
  margin: 0;
}

/* Views: unused cards/button hidden */
.view { display: none; }
.app[data-view="change"] #view-change,
.app[data-view="forgot"] #view-forgot,
.app[data-view="forgot-sent"] #view-forgot-sent,
.app[data-view="sign-out"] #view-sign-out,
.app[data-view="signed-out"] #view-signed-out { display: block; }
.app[data-view="sign-out"] #continue { display: none; }
.app[data-view="sign-out"] #sheet-root { display: block; }

/* Confirm uses locked details.css sheet shell; keep it short (title + actions). */
#sheet-root[hidden] { display: none; }
#confirm-sheet { max-height: none; }
#confirm-sheet .sheet-body { flex: 0 0 auto; overflow: visible; padding-bottom: 28px; }
#confirm-sheet .sheet-title { margin: 12px 0 8px; }

/* Signed-out only: a signed-out person should not see the Account menu.
   The mark stays; there is still no page title. Other views are unchanged.
   Keep the shared 44px header band so the mark does not jump up when the
   menu leaves the layout (loop 1). */
.app[data-view="signed-out"] .topbar { height: 44px; }
.app[data-view="signed-out"] #menu-btn { display: none; }

/* ---- 1.3: Set new password (reset link) and mismatch hint ---- */
/* Reuse #view-change minus Current password. Hint type quoted from locked guests-1.0 .hs-hint
   (Dex production places the server error under the card in this type). */
.app[data-view="reset"] #view-change,
.app[data-view="reset-done"] #view-reset-done { display: block; }
.app[data-view="reset"] #row-current { display: none; }

.hs-hint {
  width: 350px;
  margin: 8px auto 0;
  font: 500 12px/1.4 var(--font-ui);
  color: var(--color-text-muted);
  flex-shrink: 0;
}
.hs-hint[hidden] { display: none !important; }

/* Reset arrives from an emailed link (public). Hide the Account menu, same as signed-out.
   Keep the shared 44px header band so the mark does not jump. */
.app[data-view="reset"] .topbar,
.app[data-view="reset-done"] .topbar { height: 44px; }
.app[data-view="reset"] #menu-btn,
.app[data-view="reset-done"] #menu-btn { display: none; }
