/* The hiring manager's review screen, copied from SmartSearch.RecruitOS
   ClientApp/src/components/HiringManagerReview/hiringManagerReview.css (commit 6919b328, 2026-09-02),
   lines 59-745: the card, action bar, state panels and reject sheet. Its :root tokens are scoped to the
   phone screen here, and its html/body rules are left out so they don't restyle the story page.
   phone.css adapts the fixed-position pieces to the phone frame. Em dashes in the comments are
   hyphens here. */
.reviewScreen {
  --hmr-purple: #200940;
  --hmr-purple-2: #3a1e63;
  --hmr-pink: #ef118e;
  --hmr-ink: #241436;
  --hmr-muted: #6e6480;
  --hmr-line: #ece7f3;
  --hmr-bg: #f4f2f8;
  --hmr-approve: #16a34a;
  --hmr-reject: #e11d48;
}

.hmr *,
.hmr *::before,
.hmr *::after {
  box-sizing: border-box;
}

/* ── App shell ──────────────────────────────────────────────────────────────── */
.hmr {
  /* Plain in-flow column. min-height (not height) so state panels can centre in
     a full viewport while long content simply grows and the document scrolls. */
  display: flex;
  flex-direction: column;
  min-height: 100svh;
  min-height: 100dvh;
}

.hmr-visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  margin: -1px;
  padding: 0;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
  border: 0;
}

/* ── Header (in-flow shell row - never sticky, never scrolls away) ──────────── */
.hmr-header {
  position: relative; /* stacking context for the dropdown menu */
  flex: 0 0 auto;
  z-index: 30;
  display: flex;
  align-items: center;
  gap: 12px;
  padding: max(env(safe-area-inset-top), 10px) 16px 10px;
  background: var(--hmr-purple);
  color: #fff;
}

.hmr-header__logo {
  display: block;
  height: 26px;
  width: auto;
}

.hmr-wordmark {
  font-weight: 700;
  font-size: 19px;
  letter-spacing: -0.01em;
  color: #fff;
}

.hmr-wordmark span {
  color: var(--hmr-pink);
}

.hmr-header__job {
  flex: 1;
  min-width: 0;
  text-align: center;
  font-size: 14px;
  font-weight: 500;
  color: #cfc6e6;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.hmr-header__nav {
  position: relative;
  margin-left: auto;
}

.hmr-header__menu-toggle {
  display: grid;
  place-items: center;
  width: 40px;
  height: 40px;
  border: none;
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.1);
  color: #fff;
  cursor: pointer;
  touch-action: manipulation;
}

.hmr-header__menu-toggle:active {
  transform: scale(0.94);
}

.hmr-header__menu-scrim {
  position: fixed;
  inset: 0;
  z-index: 39;
  border: none;
  background: transparent;
}

.hmr-header__menu {
  position: absolute;
  top: calc(100% + 8px);
  right: 0;
  z-index: 40;
  display: flex;
  flex-direction: column;
  min-width: 190px;
  padding: 6px;
  background: #fff;
  border-radius: 14px;
  box-shadow: 0 12px 34px rgba(32, 9, 64, 0.22);
}

.hmr-header__menu-link {
  touch-action: manipulation;
  padding: 12px 14px;
  border-radius: 10px;
  font-size: 15px;
  font-weight: 500;
  color: var(--hmr-ink);
  text-decoration: none;
}

.hmr-header__menu-link.is-active {
  color: var(--hmr-pink);
}

.hmr-header__menu-link:active {
  background: var(--hmr-bg);
}

/* ── Body / layout ──────────────────────────────────────────────────────────── */
/* Middle shell row. Hosts either a state panel or the CardStack.
   min-height:0 is essential: without it the flex children can't shrink and the
   inner scroller never scrolls. */
.hmr-body {
  flex: 1 1 auto;
  min-height: 0;
  display: flex;
  flex-direction: column;
  width: 100%;
}

/* Full-height state panels (loading / error / closed / caught up) centre in
   the body. */
.hmr-body > .hmr-panel {
  flex: 1 1 auto;
}

.hmr-stack {
  flex: 1 1 auto;
  display: flex;
  flex-direction: column;
}

/* Content column (alert + animated card + complete panel). NOT a scroller - the
   document scrolls. Bottom padding clears the fixed action bar. */
.hmr-scroll {
  flex: 1 1 auto;
  display: flex;
  flex-direction: column;
  padding: 16px 16px calc(104px + env(safe-area-inset-bottom));
}

.hmr-scroll > .hmr-panel {
  flex: 1 1 auto;
}

/* Positioning context for popLayout card exits; constrains card width. */
.hmr-stack__area {
  position: relative;
  width: 100%;
  max-width: 620px;
  margin: 0 auto;
}

/* ── Candidate card ─────────────────────────────────────────────────────────── */
.hmr-cardwrap {
  touch-action: pan-y;
  will-change: transform;
}

.hmr-card {
  background: #fff;
  border-radius: 20px;
  padding: 22px 20px 20px;
  box-shadow: 0 6px 26px rgba(32, 9, 64, 0.08), 0 1px 2px rgba(32, 9, 64, 0.06);
}

.hmr-card__position {
  margin: 0 0 10px;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--hmr-pink);
}

.hmr-card__head {
  margin-bottom: 4px;
}

.hmr-card__name {
  display: flex;
  align-items: center;
  gap: 8px;
  margin: 0;
  font-size: 23px;
  font-weight: 700;
  line-height: 1.2;
  color: var(--hmr-ink);
}

.hmr-card__linkedin {
  display: inline-flex;
  color: #0a66c2;
}

.hmr-card__title {
  margin: 8px 0 0;
  font-size: 16px;
  font-weight: 600;
  color: #3d3357;
}

.hmr-card__company {
  margin: 2px 0 0;
  font-size: 14px;
  color: var(--hmr-muted);
}

.hmr-card__info {
  margin: 18px 0 0;
  padding: 4px 0 0;
  border-top: 1px solid var(--hmr-line);
}

.hmr-card__info-row {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  padding: 9px 0;
}

.hmr-card__info-row dt {
  font-size: 14px;
  color: var(--hmr-muted);
}

.hmr-card__info-row dd {
  margin: 0;
  font-size: 14px;
  font-weight: 600;
  text-align: right;
  color: var(--hmr-ink);
}

.hmr-card__section {
  margin-top: 16px;
}

.hmr-card__section-title {
  margin: 0 0 6px;
  font-size: 13px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.03em;
  color: var(--hmr-muted);
}

.hmr-card__highlight {
  font-size: 15px;
  line-height: 1.55;
  color: #372c50;
}

.hmr-card__highlight :first-child {
  margin-top: 0;
}

.hmr-card__highlight :last-child {
  margin-bottom: 0;
}

.hmr-card__resume {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-top: 18px;
  padding: 11px 16px;
  border: 1px solid var(--hmr-line);
  border-radius: 12px;
  background: #faf8fd;
  color: var(--hmr-purple-2);
  font-size: 15px;
  font-weight: 600;
  cursor: pointer;
  touch-action: manipulation;
}

.hmr-card__resume:active {
  transform: scale(0.98);
  background: #f1ecf7;
}

.hmr-card__comment {
  margin-top: 20px;
}

.hmr-card__comment label {
  display: block;
  margin-bottom: 6px;
  font-size: 13px;
  font-weight: 600;
  color: var(--hmr-muted);
}

.hmr-card__comment textarea {
  width: 100%;
  padding: 12px 14px;
  border: 1px solid var(--hmr-line);
  border-radius: 12px;
  background: #fff;
  color: var(--hmr-ink);
  font-size: 16px; /* >=16px: no iOS focus zoom */
  line-height: 1.45;
  resize: vertical;
}

.hmr-card__comment textarea:focus {
  outline: none;
  border-color: var(--hmr-pink);
  box-shadow: 0 0 0 3px rgba(239, 17, 142, 0.15);
}

/* ── Action bar (in-flow bottom shell row - never overlaps content) ─────────── */
/* Pinned to the BOTTOM of the viewport. Approve/reject are always reachable
   regardless of scroll position (the epic's disappearing-buttons defect). While
   the iOS keyboard is open this sits behind the keyboard and reappears on close -
   that is benign, unlike pinned top chrome.

   No background or top border: a white slab across the bottom ate too much of a
   phone screen. The buttons float over the page instead, and their shadow is what
   lifts them off the content. pointer-events are re-enabled per button so the
   transparent gap between them does not swallow taps on the card behind. */
.hmr-actions {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 20;
  padding: 10px 16px calc(10px + env(safe-area-inset-bottom));
  pointer-events: none;
}

.hmr-actions__inner {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 40px;
  max-width: 620px;
  margin: 0 auto;
}

.hmr-actions__btn {
  pointer-events: auto;
  display: grid;
  place-items: center;
  width: 62px;
  height: 62px;
  border: none;
  border-radius: 50%;
  cursor: pointer;
  touch-action: manipulation;
  transition: transform 0.12s ease;
  box-shadow: 0 6px 18px rgba(32, 9, 64, 0.22);
}

.hmr-actions__btn:active {
  transform: scale(0.92);
  transition-duration: 0.05s; /* press-down reads as instant */
}

/* The reject button keeps a white fill: it is now floating over page background
   rather than sitting on a white bar, so it still needs a body of its own. */
.hmr-actions__btn--reject {
  background: #fff;
  color: var(--hmr-reject);
}

.hmr-actions__btn--approve {
  background: var(--hmr-approve);
  color: #fff;
}

/* ── State panels ───────────────────────────────────────────────────────────── */
.hmr-panel {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 10px;
  padding: 32px 24px;
  justify-content: center; /* fills its shell row via flex:1 (see .hmr-body/.hmr-scroll) */
}

.hmr-panel__badge {
  display: grid;
  place-items: center;
  width: 76px;
  height: 76px;
  margin-bottom: 6px;
  border-radius: 50%;
  background: rgba(22, 163, 74, 0.12);
  color: var(--hmr-approve);
  font-size: 30px;
  font-weight: 700;
}

.hmr-panel__badge--muted {
  background: #ece7f3;
  color: var(--hmr-purple-2);
}

.hmr-panel__title {
  margin: 0;
  font-size: 23px;
  font-weight: 700;
  color: var(--hmr-ink);
}

.hmr-panel__sub {
  margin: 0;
  max-width: 30ch;
  font-size: 15px;
  line-height: 1.5;
  color: var(--hmr-muted);
}

.hmr-panel__btn {
  margin-top: 10px;
  min-height: 48px;
  padding: 12px 22px;
  border: none;
  border-radius: 12px;
  background: var(--hmr-purple);
  color: #fff;
  font-size: 15px;
  font-weight: 600;
  cursor: pointer;
  touch-action: manipulation;
}

.hmr-panel__links {
  display: flex;
  gap: 10px;
  margin-top: 18px;
}

.hmr-panel__link {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  touch-action: manipulation;
  padding: 10px 18px;
  border: 1px solid var(--hmr-line);
  border-radius: 999px;
  background: #fff;
  font-size: 14px;
  font-weight: 600;
  color: var(--hmr-purple-2);
  text-decoration: none;
}

/* ── Alert row ──────────────────────────────────────────────────────────────── */
.hmr-stack__alert {
  width: 100%;
  max-width: 620px;
  margin: 0 auto 12px;
}

.hmr-stack__retry {
  padding: 6px 12px;
  border: none;
  border-radius: 8px;
  background: var(--hmr-purple);
  color: #fff;
  font: inherit;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  touch-action: manipulation;
}

.hmr-stack__retry:active {
  transform: scale(0.96);
}

/* ── Bottom sheet (reject reasons / résumé) ─────────────────────────────────── */
.hmr-sheet-layer {
  position: fixed;
  inset: 0;
  z-index: 50;
  display: flex;
  align-items: flex-end;
}

.hmr-sheet__scrim {
  position: fixed;
  inset: 0;
  border: none;
  padding: 0;
  background: rgba(20, 10, 32, 0.4);
}

@supports (backdrop-filter: blur(2px)) or (-webkit-backdrop-filter: blur(2px)) {
  .hmr-sheet__scrim {
    background: rgba(20, 10, 32, 0.32);
    -webkit-backdrop-filter: blur(3px);
    backdrop-filter: blur(3px);
  }
}

.hmr-sheet {
  position: relative;
  z-index: 1;
  width: 100%;
  max-width: 620px;
  margin: 0 auto;
  padding: 16px 18px calc(20px + env(safe-area-inset-bottom));
  background: #fff;
  border-radius: 22px 22px 0 0;
  box-shadow: 0 -10px 40px rgba(20, 10, 32, 0.25);
}

.hmr-sheet--tall {
  min-height: 62svh;
}

/* Sheet chrome: title block on the left, actions (download, close) on the right.
   There is deliberately NO drag grip. A grip is the standard native affordance,
   but these sheets cannot be dragged - on the web it read as a handle people
   tried and failed to pull down, which left the resume feeling inescapable.
   An explicit close button carries the affordance instead; tapping the scrim
   and pressing Escape both still work. */
.hmr-sheet__head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 2px;
}

.hmr-sheet__head-actions {
  flex: 0 0 auto;
  display: flex;
  align-items: center;
  gap: 8px;
}

.hmr-sheet__close {
  flex: 0 0 auto;
  display: grid;
  place-items: center;
  width: 44px;
  height: 44px;
  padding: 0;
  border: none;
  border-radius: 50%;
  background: #f2eff7;
  color: var(--hmr-ink);
  cursor: pointer;
  touch-action: manipulation;
  transition: transform 0.12s ease, background 0.12s ease;
}

.hmr-sheet__close:active {
  transform: scale(0.92);
  background: #e7e1f0;
  transition-duration: 0.05s;
}

.hmr-sheet__title {
  margin: 0;
  font-size: 19px;
  font-weight: 700;
  color: var(--hmr-ink);
}

.hmr-sheet__subtitle {
  margin: 4px 0 14px;
  font-size: 14px;
  color: var(--hmr-muted);
}

.hmr-sheet__reasons {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-bottom: 18px;
}

.hmr-reason {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 13px 14px;
  border: 1.5px solid var(--hmr-line);
  border-radius: 12px;
  cursor: pointer;
  touch-action: manipulation;
}

.hmr-reason.is-selected {
  border-color: var(--hmr-pink);
  background: rgba(239, 17, 142, 0.05);
}

.hmr-reason input {
  position: absolute;
  opacity: 0;
  width: 1px;
  height: 1px;
}

.hmr-reason__box {
  flex: 0 0 auto;
  display: grid;
  place-items: center;
  width: 22px;
  height: 22px;
  border: 2px solid #cbc2dd;
  border-radius: 7px;
  color: #fff;
  transition: background 0.12s ease, border-color 0.12s ease;
}

.hmr-reason.is-selected .hmr-reason__box {
  border-color: var(--hmr-pink);
  background: var(--hmr-pink);
}

/* The real checkbox is visually hidden so the row stays keyboard-operable, which
   means the focus ring would land on a 1x1 invisible input. Move it to the visible
   proxy box instead (WCAG 2.4.7). :focus-visible, not :focus-within, so the ring
   appears for keyboard use and not on tap. */
.hmr-reason:has(input:focus-visible) .hmr-reason__box {
  outline: 2px solid var(--hmr-pink);
  outline-offset: 2px;
}

.hmr-reason__label {
  font-size: 15px;
  color: var(--hmr-ink);
}

.hmr-sheet__other {
  width: 100%;
  margin-top: 4px;
  padding: 12px 14px;
  border: 1.5px solid var(--hmr-line);
  border-radius: 12px;
  font-size: 16px;
  color: var(--hmr-ink);
}

.hmr-sheet__other:focus {
  outline: none;
  border-color: var(--hmr-pink);
}

.hmr-sheet__actions {
  display: flex;
  gap: 12px;
}

.hmr-sheet__actions button {
  min-height: 48px;
  touch-action: manipulation;
}

.hmr-sheet__actions button:active {
  transform: scale(0.98);
}

/* ── Résumé viewer ──────────────────────────────────────────────────────────── */
