* { margin: 0; padding: 0; box-sizing: border-box; }

:root {
  --bg: #faf9f7;
  --card-bg: #ffffff;
  --ink: #1c1a17;
  --muted: #8a857d;
  --line: #e8e4de;
  --accent: #5d2a5f;      /* plum, Hinge-ish */
  --accent-soft: #f3ecf3;
  --like: #e0435c;
  --pass: #33302b;
  --super: #5d2a5f;
  --good: #2e9e6f;
}

html, body { height: 100%; }

body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  background: var(--bg);
  color: var(--ink);
  display: flex;
  flex-direction: column;
  align-items: center;
  min-height: 100vh;
  overflow-x: hidden;
  -webkit-user-select: none;
  user-select: none;
}

header { width: 100%; max-width: 480px; padding: 20px 20px 0; }
.brand-row { display: flex; align-items: center; justify-content: space-between; }
header h1 { font-size: 26px; letter-spacing: -0.5px; }
header h1 span { color: var(--accent); }
.tagline { color: var(--muted); font-size: 13.5px; margin-top: 2px; }

/* profile switcher */
#profile-bar { display: flex; gap: 6px; align-items: center; }
#profile-bar button {
  border: 1px solid var(--line);
  background: #fff; color: var(--ink);
  border-radius: 8px; padding: 5px 12px;
  font-size: 13px; font-weight: 600; cursor: pointer;
}
#profile-bar button.active {
  background: var(--accent); border-color: var(--accent); color: #fff;
}
#profile-bar button.add { color: var(--muted); font-weight: 700; padding: 5px 9px; }

/* tabs: Hinge-style underline */
#tabs {
  display: flex; gap: 26px;
  margin: 16px 0 0;
  width: 100%; max-width: 480px;
  padding: 0 20px;
  border-bottom: 1px solid var(--line);
}
.tab {
  background: none; border: none;
  color: var(--muted); padding: 10px 2px 12px;
  font-size: 14.5px; font-weight: 600; cursor: pointer;
  border-bottom: 2.5px solid transparent;
  margin-bottom: -1px;
}
.tab.active { color: var(--ink); border-bottom-color: var(--accent); }
.pill {
  background: var(--accent-soft); color: var(--accent);
  border-radius: 8px; padding: 1px 7px; font-size: 12px; margin-left: 2px;
}

main { width: 100%; max-width: 480px; padding: 8px 16px 40px; flex: 1; }
.view { display: none; }
.view.active { display: block; }
.hidden { display: none !important; }

/* ---------- Card stack ---------- */
#card-stack {
  position: relative;
  height: 520px;
  margin: 14px auto 0;
  max-width: 420px;
  touch-action: none;
}

.card {
  position: absolute; inset: 0;
  background: var(--card-bg);
  color: var(--ink);
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 22px 22px 18px;
  box-shadow: 0 6px 24px rgba(35, 25, 15, 0.09);
  display: flex; flex-direction: column;
  cursor: grab;
  will-change: transform;
}
.card.behind {
  transform: scale(0.96) translateY(12px);
  filter: brightness(0.985);
  pointer-events: none;
}
.card.dragging { cursor: grabbing; transition: none; }
.card.animate { transition: transform 0.3s ease, opacity 0.3s ease; }

.card .top-row {
  display: flex; justify-content: space-between; align-items: center;
  margin-bottom: 12px;
}
.card .match {
  font-size: 12px; font-weight: 700;
  color: var(--accent); background: var(--accent-soft);
  padding: 4px 11px; border-radius: 8px;
}
.card .top-right { display: flex; align-items: center; gap: 8px; }
.card .field-tag {
  font-size: 11px; font-weight: 700; text-transform: uppercase;
  letter-spacing: 0.7px; color: var(--muted);
}
/* "New to Jobsy", not "newly posted" — the two dates differ and the card keeps
   them apart. Green rather than the brand purple so it doesn't read as another
   match score sitting next to the real one. */
.fresh {
  font-size: 10px; font-weight: 800; text-transform: uppercase;
  letter-spacing: 0.6px; color: #1f6d43; background: #dff3e6;
  padding: 3px 7px; border-radius: 6px; white-space: nowrap;
}
.card h2 {
  font-family: Georgia, "Times New Roman", serif;
  font-size: 25px; line-height: 1.16; font-weight: 700;
  margin-bottom: 5px; letter-spacing: -0.2px;
}
.card .company { font-size: 15px; font-weight: 600; color: #55504a; margin-bottom: 12px; }

.card .desc-chips { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 14px; }
.card .desc-chips span {
  font-size: 12px; font-weight: 600; color: #55504a;
  border: 1px solid var(--line); background: #faf9f7;
  border-radius: 8px; padding: 4px 9px;
}

.card .facts { display: flex; flex-direction: column; gap: 8px; font-size: 14.5px; }
.card .facts div { display: flex; align-items: center; gap: 9px; }
.card .facts .icon { width: 20px; text-align: center; }

.card .why {
  margin-top: 14px; padding: 11px 13px;
  background: var(--accent-soft); border-radius: 10px;
  font-size: 13px; color: var(--accent); line-height: 1.45;
}
.card .why b { font-weight: 700; }

.card .desc {
  margin-top: 12px; font-size: 13px; color: #55504a; line-height: 1.5;
}

.card .posted { margin-top: auto; font-size: 12px; color: var(--muted); padding-top: 10px; }
.card .open-link {
  margin-top: 6px; font-size: 13.5px; font-weight: 700; color: var(--accent);
  text-decoration: none;
}
.card .open-link:hover { text-decoration: underline; }

.stamp {
  position: absolute; top: 34px;
  font-size: 30px; font-weight: 800; letter-spacing: 2px;
  padding: 3px 13px; border: 4px solid; border-radius: 8px;
  opacity: 0; transform: rotate(-16deg);
  pointer-events: none; background: rgba(255,255,255,0.85);
}
.stamp.like { left: 18px; color: var(--good); border-color: var(--good); }
.stamp.pass { right: 18px; color: var(--like); border-color: var(--like); transform: rotate(16deg); }
.stamp.super { left: 50%; top: 45%; transform: translateX(-50%) rotate(-8deg); color: var(--super); border-color: var(--super); }

/* ---------- Controls ---------- */
#controls { display: flex; justify-content: center; align-items: center; gap: 16px; margin-top: 20px; }
.ctl {
  width: 60px; height: 60px; border-radius: 50%;
  border: 1px solid var(--line); font-size: 24px; cursor: pointer;
  box-shadow: 0 3px 12px rgba(35,25,15,0.1);
  transition: transform 0.12s;
  background: #fff;
}
.ctl:active { transform: scale(0.88); }
.ctl.like { color: var(--like); font-size: 27px; }
.ctl.pass { color: var(--pass); }
.ctl.super { color: var(--super); font-size: 26px; }
.ctl.undo { width: 46px; height: 46px; font-size: 18px; color: var(--muted); }

#deck-status { text-align: center; margin-top: 14px; font-size: 12.5px; color: var(--muted); }

/* ---------- recent swipes ----------
   Collapsed by default and sitting under the deck. It replaced the Likes tab,
   and the change of shape is the point: a tab invites browsing, a folded strip
   at the bottom of the screen is somewhere you go when you've just made a
   mistake. */
.recent { margin: 20px auto 0; max-width: 460px; }
.recent > summary {
  cursor: pointer; font-size: 12.5px; font-weight: 700; color: var(--muted);
  padding: 9px 12px; border: 1px solid var(--line); border-radius: 10px;
  list-style: none; user-select: none;
}
.recent > summary::-webkit-details-marker { display: none; }
.recent > summary::after { content: ' ▾'; }
.recent[open] > summary::after { content: ' ▴'; }
.recent > summary:hover { color: var(--ink); border-color: var(--muted); }
.recent ul { list-style: none; margin: 10px 0 0; padding: 0; }

.rs-row {
  display: flex; align-items: center; gap: 10px;
  padding: 9px 4px; border-bottom: 1px solid var(--line);
}
.rs-row:last-child { border-bottom: none; }
.rs-mark {
  flex: none; width: 22px; height: 22px; border-radius: 50%;
  display: grid; place-items: center; font-size: 11px; font-weight: 800;
}
.rs-mark.like  { background: #dff3e6; color: #1f6d43; }
.rs-mark.super { background: var(--accent-soft); color: var(--accent); }
.rs-mark.pass  { background: #f0eeea; color: #8a857d; }
.rs-main { flex: 1; min-width: 0; }
.rs-title { font-size: 13.5px; font-weight: 600; line-height: 1.3; }
.rs-title a { color: var(--ink); text-decoration: none; }
.rs-title a:hover { color: var(--accent); }
.rs-meta { font-size: 11.5px; color: var(--muted); margin-top: 2px; }
.rs-link { color: var(--accent); text-decoration: none; font-weight: 600; }
.rs-link:hover { text-decoration: underline; }
.rs-state.waiting { font-style: italic; }
.rs-undo {
  flex: none; font-size: 11.5px; font-weight: 700; color: var(--muted);
  background: none; border: 1px solid var(--line); border-radius: 7px;
  padding: 5px 10px; cursor: pointer;
}
.rs-undo:hover { color: var(--accent); border-color: var(--accent); }

#empty-deck { text-align: center; padding: 90px 20px; }
#empty-deck h2 { font-size: 25px; margin-bottom: 12px; }
#empty-deck p { color: #55504a; margin-bottom: 8px; }

/* ---------- shared section headings ---------- */
#personalize h2 { margin: 16px 0 4px; font-size: 21px; }
.hint { color: var(--muted); font-size: 13.5px; margin-bottom: 12px; }

/* ---------- Personalize ---------- */
.insight-block { margin: 18px 0; }
.insight-block h3 { font-size: 15px; margin-bottom: 10px; }
.chips { list-style: none; display: flex; flex-wrap: wrap; gap: 8px; }
.chips li {
  background: #eef7f1; border: 1px solid #bfe3cf;
  border-radius: 8px; padding: 5px 12px; font-size: 13px;
}
.chips.negative li { background: #fdf0f2; border-color: #f3c3cc; }
.chips.stated li { background: var(--accent-soft); border-color: #d9c3da; }
.chips .x {
  background: none; border: none; cursor: pointer;
  color: inherit; opacity: 0.5; font-size: 12px;
  margin-left: 5px; padding: 0 2px;
}
.chips .x:hover { opacity: 1; }
#stats-line { font-size: 14px; color: #55504a; }

.ghost-btn {
  background: #fff; border: 1px solid var(--line);
  color: var(--ink); border-radius: 10px; padding: 9px 20px;
  font-size: 14px; cursor: pointer; margin-top: 10px;
}
.ghost-btn:hover { border-color: var(--accent); color: var(--accent); }
.ghost-btn.danger { color: #b3495c; }
.ghost-btn.danger:hover { border-color: var(--like); color: var(--like); }

.mini-btn {
  background: #fff; border: 1px solid var(--line);
  color: var(--ink); border-radius: 8px;
  padding: 4px 12px; font-size: 12px; cursor: pointer;
  margin-left: 8px; vertical-align: middle;
}
.mini-btn:hover { border-color: var(--accent); color: var(--accent); }

.live-dot {
  font-size: 11px; font-weight: 700; color: var(--accent);
  background: var(--accent-soft);
  border-radius: 8px; padding: 2px 9px;
  margin-left: 6px; vertical-align: middle;
  animation: pulse 2.4s ease-in-out infinite;
}
@keyframes pulse {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.5; }
}

/* ---------- Setup wizard ---------- */
.overlay {
  position: fixed; inset: 0; z-index: 50;
  background: rgba(30, 25, 20, 0.45);
  backdrop-filter: blur(4px);
  display: flex; align-items: center; justify-content: center;
  padding: 18px;
}
.sheet {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 16px;
  width: 100%; max-width: 460px;
  max-height: 88vh; overflow-y: auto;
  padding: 26px 24px 22px;
  box-shadow: 0 22px 60px rgba(35,25,15,0.3);
}
.sheet h2 { font-size: 22px; margin-bottom: 6px; font-family: Georgia, serif; }
.sheet h3 { font-size: 14px; margin: 18px 0 8px; }

.choice-chips { display: flex; flex-wrap: wrap; gap: 8px; }
.choice-chips button {
  background: #fff;
  border: 1px solid var(--line);
  color: var(--ink);
  border-radius: 9px; padding: 7px 13px;
  font-size: 13.5px; cursor: pointer;
  transition: all 0.15s;
}
.choice-chips button:hover { border-color: var(--accent); }
.choice-chips button.on {
  background: var(--accent); border-color: var(--accent);
  color: #fff; font-weight: 600;
}

.text-input {
  width: 100%;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 10px; padding: 9px 14px;
  color: var(--ink); font-size: 13.5px;
  margin-bottom: 10px;
}
.text-input::placeholder { color: #b6b0a7; }

.selected-row { margin-bottom: 8px; }
.selected-row:empty { display: none; }

.sub-label { font-size: 12px; color: var(--muted); margin: 6px 0 6px 2px; }
.optional-tag {
  font-size: 11px; font-weight: 600; color: var(--muted);
  border: 1px solid var(--line); border-radius: 7px; padding: 1px 7px;
  margin-left: 5px; vertical-align: middle;
}
#ob-field-results button { border-style: dashed; }

.ob-pay-row { display: flex; flex-direction: column; gap: 10px; }
.pay-input {
  display: flex; align-items: center; gap: 6px;
  background: #fff; border: 1px solid var(--line);
  border-radius: 10px; padding: 8px 14px;
  width: fit-content; font-size: 15px;
}
.pay-input input {
  background: none; border: none; color: var(--ink);
  font-size: 15px; width: 110px; outline: none;
}
.pay-input input::placeholder { color: #b6b0a7; }
.pay-input input::-webkit-outer-spin-button,
.pay-input input::-webkit-inner-spin-button { -webkit-appearance: none; }
.pay-input span { color: var(--muted); }

.sheet textarea {
  width: 100%; margin-top: 4px;
  background: #fff; border: 1px solid var(--line);
  border-radius: 10px; padding: 12px 14px;
  color: var(--ink); font-size: 13.5px; font-family: inherit;
  resize: vertical;
}
.sheet textarea::placeholder { color: #b6b0a7; }

.ob-file-row { display: flex; align-items: center; gap: 10px; margin: 12px 0 4px; flex-wrap: wrap; }
.file-btn {
  border: 1.5px dashed #cfc9c0;
  border-radius: 10px; padding: 7px 14px;
  font-size: 13px; cursor: pointer; color: #55504a;
}
.file-btn:hover { border-color: var(--accent); color: var(--accent); }

.solid-btn {
  background: var(--accent); border: none; color: #fff;
  border-radius: 10px; padding: 10px 22px;
  font-size: 14.5px; font-weight: 700; cursor: pointer;
}
.solid-btn:active { transform: scale(0.96); }
.solid-btn.small { padding: 8px 16px; font-size: 13px; }

.ob-nav { display: flex; justify-content: space-between; margin-top: 24px; gap: 10px; }

.ob-kw-add { display: flex; gap: 8px; margin-top: 12px; }
.ob-kw-add input {
  flex: 1; background: #fff; border: 1px solid var(--line);
  border-radius: 10px; padding: 8px 14px;
  color: var(--ink); font-size: 13.5px;
}
.ob-kw-add input::placeholder { color: #b6b0a7; }

/* ---------- toast ---------- */
#toast {
  position: fixed; bottom: 26px; left: 50%; transform: translateX(-50%);
  background: var(--ink); color: #fff;
  border-radius: 10px; padding: 11px 18px;
  font-size: 13.5px; z-index: 99;
  max-width: 88vw; text-align: center;
  box-shadow: 0 8px 24px rgba(0,0,0,0.25);
}

/* ---------- AI: loading over the card stack ---------- */
#ai-loading {
  position: absolute; inset: 0;
  display: flex; flex-direction: column;
  align-items: center; justify-content: safe center; gap: 16px;
  z-index: 5;
  background: var(--bg); /* opaque so the old status/card don't show through */
  /* setAiBusy() hides the card stack, which collapses #discover to ~60px.
     Centring inside a box shorter than its content overflows *both* ways —
     the spinner and step list ended up drawn over the tab bar. Hold the
     stack's height so there's room to centre in, and use `safe center` so
     content that still doesn't fit grows downward, never up over the tabs. */
  min-height: 520px;
  padding: 32px 12px 24px;
}
#discover { position: relative; }
.ai-spinner {
  width: 42px; height: 42px; border-radius: 50%;
  border: 3px solid var(--line); border-top-color: var(--accent);
  animation: spin 0.8s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }
#ai-loading-msg { color: var(--muted); font-size: 14px; font-weight: 600; }

/* Live progress: the running step list, so a slow call reads as slow rather
   than broken, and a failure says which step failed. */
.ai-steps {
  list-style: none; margin: 14px 0 0; padding: 0;
  display: flex; flex-direction: column; gap: 7px;
  width: 100%; max-width: 320px; text-align: left;
}
.ai-steps .step {
  display: grid; grid-template-columns: 16px 1fr; gap: 8px;
  font-size: 13px; line-height: 1.4; color: #8a847c;
}
.ai-steps .step.done   { color: #55504a; }
.ai-steps .step.active { color: var(--ink); font-weight: 600; }
.ai-steps .step.failed { color: #8a3320; }
.step-icon { text-align: center; font-size: 12px; padding-top: 1px; }
.step.done .step-icon { color: #1f6f43; }
.step-label em { font-style: normal; font-weight: 400; color: #a09a92; font-size: 12px; }
.step-note {
  grid-column: 2; font-size: 12px; font-weight: 400; color: #8a847c; margin-top: 1px;
}
.step.failed .step-note { color: #8a3320; }
.step.active .dot {
  display: inline-block; width: 7px; height: 7px; border-radius: 50%;
  background: var(--accent); animation: pulse 1s ease-in-out infinite;
}
@keyframes pulse { 0%, 100% { opacity: 1; } 50% { opacity: 0.25; } }

.ai-elapsed { margin-top: 12px; font-size: 12px; color: #a09a92; font-variant-numeric: tabular-nums; }
.ai-slow {
  margin-top: 6px; font-size: 12px; line-height: 1.5; color: #8a5a12;
  background: #fbf1de; border: 1px solid #eddab0; border-radius: 10px;
  padding: 7px 11px; max-width: 320px;
}

/* ---------- AI: profile card in Personalize ---------- */
/* ---------- interest threads ---------- */
.thread-tag {
  display: inline-block; font-size: 11px; font-weight: 600; letter-spacing: .02em;
  color: #6b4d86; background: var(--accent-soft); border: 1px solid #e0d3e1;
  border-radius: 999px; padding: 3px 10px; margin-bottom: 8px;
}
.thread-tag.wild { color: #8a5a12; background: #fbf1de; border-color: #eddab0; }

.thread-list { list-style: none; margin: 12px 0 0; padding: 0; display: flex; flex-direction: column; gap: 10px; }
.thread {
  border: 1px solid var(--line); border-radius: 12px; padding: 11px 13px; background: #fff;
}
.thread.probation { border-color: #eddab0; background: #fffdf7; }
.thread.wildcard { border-style: dashed; background: #fcfaff; }
.thread-head { display: flex; align-items: baseline; justify-content: space-between; gap: 10px; }
.thread-label { font-weight: 600; font-size: 14px; color: var(--ink); }
.thread-slots { font-size: 12px; color: #7c766e; white-space: nowrap; }
.thread-summary { font-size: 13px; line-height: 1.5; color: #55504a; margin: 6px 0 0; }
.thread-meta { font-size: 12px; color: #7c766e; margin-top: 6px; }
.thread-actions { display: flex; gap: 6px; margin-top: 9px; }
.thread-empty { font-size: 13px; color: #7c766e; line-height: 1.5; }

.ai-status {
  font-size: 13px; line-height: 1.5; border-radius: 10px;
  padding: 9px 12px; margin: 4px 0 12px;
}
.ai-status.on   { color: #1f6f43; background: #e8f5ec; border: 1px solid #b9e2c6; }
.ai-status.warn { color: #8a5a12; background: #fbf1de; border: 1px solid #eddab0; }
.ai-status.off  { color: #8a3320; background: #fbe8e2; border: 1px solid #eec2b4; }
.ai-prose {
  font-size: 14px; line-height: 1.6; color: #3f3b35;
  background: var(--accent-soft); border: 1px solid #e0d3e1;
  border-radius: 12px; padding: 14px 16px; white-space: pre-wrap;
}
.ai-settings { display: flex; flex-direction: column; gap: 8px; margin-top: 12px; }
.ai-toggle {
  display: flex; align-items: center; gap: 8px;
  font-size: 13px; color: #55504a; cursor: pointer;
}
.ai-toggle input[type="checkbox"] { width: 15px; height: 15px; accent-color: var(--accent); }
.ai-toggle select {
  border: 1px solid var(--line); border-radius: 8px;
  padding: 4px 8px; font-size: 13px; background: #fff; color: var(--ink);
}

/* ---------- AI: profile review editor ---------- */
#ai-review .sheet h2 { font-size: 21px; }
.ai-prose-edit {
  width: 100%; margin-top: 4px;
  background: #fff; border: 1px solid var(--line);
  border-radius: 12px; padding: 14px 16px;
  color: var(--ink); font-size: 14px; line-height: 1.6;
  font-family: inherit; resize: vertical;
}
.ai-prose-edit::placeholder { color: #b6b0a7; }
#ai-review-changes {
  background: var(--accent-soft); border: 1px solid #e0d3e1;
  border-radius: 10px; padding: 11px 14px; color: var(--accent);
  font-size: 13.5px; line-height: 1.5; margin-bottom: 14px;
}
#ai-review-changes:empty { display: none; }

/* AI: superlike is now the heart (love it most) */
.ctl.super { color: var(--like); }

/* Résumé + lock sections in Personalize */
.resume-name { font-size: 14px; font-weight: 600; color: #3f3b35; }
.resume-preview {
  margin-top: 8px; font-size: 12.5px; color: var(--muted);
  background: #faf9f7; border: 1px solid var(--line); border-radius: 10px;
  padding: 10px 12px; line-height: 1.5; white-space: pre-wrap;
}
.lock-error { color: var(--like); font-size: 13px; margin: 4px 0 0; }

@media (max-height: 780px) {
  #card-stack { height: 460px; }
  #ai-loading { min-height: 460px; }
}

/* ---------- followed job boards + digest ---------- */
.board-add-row { display: flex; gap: 8px; align-items: center; margin: 10px 0 4px; }
.board-add-row .text-input { margin-bottom: 0; flex: 1; min-width: 0; }

.board-msg {
  font-size: 12.5px; line-height: 1.5; margin: 6px 0 0;
  border-radius: 9px; padding: 7px 10px;
}
.board-msg.good { color: #1f6f43; background: #eef7f1; border: 1px solid #cfe6d9; }
.board-msg.warn { color: #8a5a12; background: #fbf1de; border: 1px solid #eddab0; }
.board-msg.bad  { color: #8a3320; background: #fbeeea; border: 1px solid #eecdc3; }

.board-list { list-style: none; margin: 10px 0 0; padding: 0; }
.board-list li {
  display: grid; grid-template-columns: 1fr auto; align-items: baseline;
  gap: 2px 10px; padding: 8px 0; border-bottom: 1px solid var(--line);
}
.board-list li:last-child { border-bottom: 0; }
.board-name { font-weight: 600; font-size: 14px; }
.board-meta { grid-column: 1; font-size: 12px; color: var(--muted); }
.board-list .x {
  grid-row: 1 / span 2; align-self: center;
  background: none; border: 0; color: var(--muted);
  font-size: 14px; cursor: pointer; padding: 4px 6px; line-height: 1;
}
.board-list .x:hover { color: var(--like); }
.board-empty { color: var(--muted); font-size: 13px; border-bottom: 0 !important; }

/* ---------- discover: mode + view toggles, list view ---------- */
#discover-modes { display: flex; gap: 8px; align-items: center; margin: 12px 0 2px; }
.seg {
  display: flex; border: 1px solid var(--line); border-radius: 10px;
  background: #fff; overflow: hidden;
}
#seg-mode { flex: 1; }
.seg-btn {
  flex: 1; border: 0; background: none; cursor: pointer;
  padding: 7px 12px; font-size: 13px; font-weight: 600; color: var(--muted);
  white-space: nowrap;
}
.seg-btn + .seg-btn { border-left: 1px solid var(--line); }
.seg-btn.on { background: var(--accent); color: #fff; }
.seg-btn:disabled { opacity: 0.45; cursor: not-allowed; }
#mode-note:empty { display: none; }
#mode-note { margin: 4px 2px 0; }

.job-list { list-style: none; margin: 12px 0 0; padding: 0; }
.job-row {
  display: flex; gap: 12px; align-items: center;
  background: #fff; border: 1px solid var(--line); border-radius: 12px;
  padding: 12px 14px; margin-bottom: 8px;
  transition: opacity .2s, transform .2s;
}
.job-row.done { opacity: 0; transform: translateX(30px); }
.job-row.empty { display: block; color: var(--muted); font-size: 13.5px; }
.jr-main { flex: 1; min-width: 0; }
.jr-title { font-weight: 700; font-size: 15px; line-height: 1.25; }
.jr-title .fresh { margin-right: 6px; vertical-align: 1px; }
.jr-title a { color: var(--ink); text-decoration: none; }
.jr-title a:hover { color: var(--accent); }
.jr-co { font-size: 13.5px; font-weight: 600; color: #55504a; margin-top: 1px; }
.jr-meta { font-size: 12px; color: var(--muted); margin-top: 3px; }
.jr-acts { display: flex; gap: 6px; flex-shrink: 0; }
.jr-btn {
  width: 38px; height: 38px; border-radius: 50%;
  border: 1px solid var(--line); background: #fff;
  font-size: 16px; cursor: pointer; line-height: 1;
}
.jr-btn:active { transform: scale(0.88); }
.jr-btn.like { color: var(--good); }
.jr-btn.pass { color: var(--pass); }
.jr-btn.super { color: var(--super); }


/* ---------- app password gate ----------
   Full-screen because it is not dismissible: there is nothing useful behind it
   until the session exists. */
.gate-box {
  background: var(--card-bg); border: 1px solid var(--line); border-radius: 14px;
  padding: 28px 24px; width: min(360px, 90vw); text-align: center;
  box-shadow: 0 6px 24px rgba(35, 25, 15, 0.09);
}
.gate-box h1 { font-size: 30px; letter-spacing: -0.5px; margin-bottom: 4px; }
.gate-box h1 span { color: var(--accent); }
.gate-box .hint { margin-bottom: 16px; }
.gate-box .text-input { width: 100%; margin-bottom: 12px; text-align: center; }
.gate-box .primary-btn { width: 100%; }
.gate-msg { color: var(--like); font-size: 13px; margin-top: 10px; font-weight: 600; }
.gate-box .sub-label { margin-top: 12px; }
