/* ===========================================================================
   Rozzo — app UI. Friendly (rounded type, chunky 3D buttons, Rozzo himself)
   on top of a calm, functional layout. Palette comes from the character:
   green glasses, mustard sweater, navy trousers, lavender backdrop.
   The résumé paper itself is styled in resume.css.
   =========================================================================== */
:root {
  --ink: #1e2442; --ink-2: #4a5070; --ink-3: #767c98; --ink-4: #a4a9c0;
  --line: #e8e6f2; --line-2: #d8d5e8; --line-3: #c3bfdb;
  --bg: #f8f7fd; --surface: #fff; --surface-2: #f4f3fa; --surface-3: #eeedf7;
  --lav: #e2dff1; --lav-2: #eceaf8; --lav-3: #f5f4fc; --lav-deep: #8a81c9; --lav-ink: #4f4596; --lav-line: #c9c3ea;
  --green: #49a52c; --green-lip: #37811f; --green-2: #e9f6e2; --green-ink: #2d6a16; --green-line: #b9e0a6;
  --mustard: #eea235; --mustard-lip: #c9831f; --mustard-2: #fdf2e1; --mustard-ink: #7d4e0c; --mustard-line: #f3cf96;
  --navy: #2e395f; --navy-lip: #1b2342;
  --red: #dd4b50; --red-lip: #b3363b; --red-2: #fdeced; --red-ink: #9b2328;
  --blue: #3b76d8; --blue-2: #e8effc;
  --r-sm: 12px; --r: 16px; --r-lg: 20px; --r-xl: 28px;
  --sh-1: 0 1px 2px rgba(30,36,66,.06);
  --sh-2: 0 10px 28px rgba(30,36,66,.08);
  --sh-3: 0 24px 64px rgba(30,36,66,.18);
  --font: "Nunito", ui-rounded, system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --top-h: 64px;
  --ease: cubic-bezier(.22,1,.36,1);
}
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; background: var(--bg); }
body { margin: 0; min-height: 100vh; font-family: var(--font); font-weight: 600; font-size: 15px; line-height: 1.45; color: var(--ink); background: var(--bg); -webkit-font-smoothing: antialiased; -moz-osx-font-smoothing: grayscale; }
h1, h2, h3, h4 { margin: 0; font-weight: 900; letter-spacing: -.01em; line-height: 1.15; text-wrap: balance; }
p { margin: 0; }
button, input, select, textarea { font: inherit; color: inherit; }
button { cursor: pointer; -webkit-tap-highlight-color: transparent; }
img { max-width: 100%; }
a { color: var(--green-ink); }
.ic { width: 20px; height: 20px; flex: 0 0 auto; display: inline-block; vertical-align: middle; }
[hidden] { display: none !important; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
:focus-visible { outline: 3px solid var(--lav-deep); outline-offset: 2px; border-radius: 10px; }
.spacer { flex: 1 1 auto; }
.muted { color: var(--ink-3); }
.nowrap { white-space: nowrap; }

/* ---------- buttons (3D lip, pressed on :active) ---------- */
.btn {
  --b-bg: var(--surface); --b-fg: var(--ink); --b-bd: var(--line-2); --b-lip: var(--line-2);
  position: relative; display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  min-height: 44px; padding: 0 18px; border-radius: 14px;
  background: var(--b-bg); color: var(--b-fg); border: 2px solid var(--b-bd);
  box-shadow: 0 4px 0 var(--b-lip);
  font-weight: 800; font-size: 15px; line-height: 1; letter-spacing: .01em; white-space: nowrap;
  transition: transform .08s, box-shadow .08s, filter .15s, background .15s;
  user-select: none; text-decoration: none;
}
.btn .ic { width: 18px; height: 18px; }
.btn:hover { filter: brightness(1.04); }
.btn:active:not([disabled]) { transform: translateY(4px); box-shadow: 0 0 0 var(--b-lip); }
.btn[disabled], .btn.is-disabled { --b-bg: var(--surface-3); --b-fg: var(--ink-4); --b-bd: var(--line); --b-lip: var(--line); cursor: not-allowed; filter: none; }
.btn-primary { --b-bg: var(--green); --b-fg: #fff; --b-bd: var(--green); --b-lip: var(--green-lip); }
.btn-ai { --b-bg: var(--mustard); --b-fg: #2a1a02; --b-bd: var(--mustard); --b-lip: var(--mustard-lip); }
.btn-navy { --b-bg: var(--navy); --b-fg: #fff; --b-bd: var(--navy); --b-lip: var(--navy-lip); }
.btn-danger { --b-bg: var(--red); --b-fg: #fff; --b-bd: var(--red); --b-lip: var(--red-lip); }
.btn-secondary { --b-bg: var(--surface); --b-fg: var(--ink); --b-bd: var(--line-2); --b-lip: var(--line-2); }
.btn-soft { --b-bg: var(--lav-2); --b-fg: var(--lav-ink); --b-bd: var(--lav-line); --b-lip: var(--lav-line); }
.btn-ghost { --b-bg: transparent; --b-fg: var(--ink-2); --b-bd: transparent; --b-lip: transparent; box-shadow: none; }
.btn-ghost:hover { background: var(--surface-3); filter: none; }
.btn-ghost:active:not([disabled]) { transform: none; }
.btn-sm { min-height: 36px; padding: 0 13px; font-size: 13.5px; border-radius: 12px; box-shadow: 0 3px 0 var(--b-lip); gap: 6px; }
.btn-sm .ic { width: 16px; height: 16px; }
.btn-sm:active:not([disabled]) { transform: translateY(3px); }
.btn-lg { min-height: 52px; padding: 0 26px; font-size: 17px; border-radius: 16px; }
.btn-block { width: 100%; }
.btn .spin { width: 18px; height: 18px; border: 3px solid currentColor; border-right-color: transparent; border-radius: 50%; animation: spin .8s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
.icon-btn { width: 40px; height: 40px; border-radius: 12px; border: 0; background: transparent; color: var(--ink-3); display: inline-flex; align-items: center; justify-content: center; transition: background .15s, color .15s; flex: 0 0 auto; }
.icon-btn:hover { background: var(--surface-3); color: var(--ink); }
.icon-btn.danger:hover { background: var(--red-2); color: var(--red); }
.icon-btn .ic { width: 20px; height: 20px; }
.icon-btn.sm { width: 32px; height: 32px; border-radius: 10px; }
.icon-btn.sm .ic { width: 17px; height: 17px; }
.link-btn { background: none; border: 0; padding: 4px 2px; color: var(--green-ink); font-weight: 800; display: inline-flex; align-items: center; gap: 6px; }
.link-btn:hover { text-decoration: underline; }
.link-btn .ic { width: 16px; height: 16px; }

/* ---------- form controls ---------- */
.field { display: flex; flex-direction: column; gap: 6px; min-width: 0; }
.field > label, .label { font-size: 13.5px; font-weight: 800; color: var(--ink-2); }
.field .hint, .hint { font-weight: 600; color: var(--ink-3); font-size: 12.5px; }
.input, .textarea, .select {
  width: 100%; min-width: 0; font-size: 16px; font-weight: 700; line-height: 1.35; color: var(--ink);
  background: var(--surface-2); border: 2px solid var(--line); border-radius: 14px; padding: 11px 14px;
  transition: border-color .15s, background .15s, box-shadow .15s; appearance: none; -webkit-appearance: none;
}
.input::placeholder, .textarea::placeholder { color: var(--ink-4); font-weight: 600; }
.input:hover, .textarea:hover, .select:hover { border-color: var(--line-2); }
.input:focus, .textarea:focus, .select:focus { outline: none; border-color: var(--lav-deep); background: #fff; box-shadow: 0 0 0 4px rgba(138,129,201,.18); }
.input[disabled] { opacity: .55; }
.textarea { resize: vertical; min-height: 96px; line-height: 1.5; }
.select { padding-right: 38px; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23767c98' stroke-width='2.4' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E"); background-repeat: no-repeat; background-position: right 12px center; background-size: 18px; cursor: pointer; }
.grid-2 { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; }
.grid-3 { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 14px; }
.stack { display: flex; flex-direction: column; gap: 14px; }
.row { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.check { display: inline-flex; align-items: center; gap: 10px; font-weight: 700; font-size: 14.5px; cursor: pointer; user-select: none; }
.check input { appearance: none; -webkit-appearance: none; width: 22px; height: 22px; border-radius: 7px; border: 2px solid var(--line-3); background: #fff; display: inline-grid; place-content: center; margin: 0; cursor: pointer; transition: .15s; }
.check input:checked { background: var(--green); border-color: var(--green); }
.check input:checked::after { content: ""; width: 10px; height: 6px; border-left: 3px solid #fff; border-bottom: 3px solid #fff; transform: translateY(-1px) rotate(-45deg); }
.seg { display: inline-flex; background: var(--surface-3); border-radius: 14px; padding: 4px; gap: 4px; }
.seg button { border: 0; background: transparent; padding: 8px 16px; border-radius: 10px; font-weight: 800; color: var(--ink-2); font-size: 14px; }
.seg button.on { background: #fff; color: var(--ink); box-shadow: 0 1px 0 var(--line-2), 0 2px 6px rgba(30,36,66,.08); }

/* ---------- chips ---------- */
.chips { display: flex; flex-wrap: wrap; gap: 8px; }
.chip { display: inline-flex; align-items: center; gap: 6px; min-height: 38px; padding: 0 14px; border-radius: 999px; background: #fff; border: 2px solid var(--line-2); box-shadow: 0 3px 0 var(--line-2); color: var(--ink-2); font-weight: 800; font-size: 14px; transition: transform .08s, box-shadow .08s, background .15s, border-color .15s, color .15s; }
.chip .ic { width: 16px; height: 16px; }
.chip:hover { border-color: var(--line-3); }
.chip:active { transform: translateY(3px); box-shadow: 0 0 0 var(--line-2); }
.chip.on { background: var(--lav-2); border-color: var(--lav-deep); box-shadow: 0 3px 0 var(--lav-deep); color: var(--lav-ink); }
.chip.sm { min-height: 32px; padding: 0 11px; font-size: 13px; }
.tag { display: inline-flex; align-items: center; gap: 5px; padding: 3px 10px; border-radius: 999px; font-size: 12px; font-weight: 800; background: var(--surface-3); color: var(--ink-2); }
.tag.green { background: var(--green-2); color: var(--green-ink); }
.tag.mustard { background: var(--mustard-2); color: var(--mustard-ink); }
.tag.lav { background: var(--lav-2); color: var(--lav-ink); }
.tag.red { background: var(--red-2); color: var(--red-ink); }
.tag .ic { width: 13px; height: 13px; }

/* ---------- cards ---------- */
.card { background: var(--surface); border: 2px solid var(--line); border-radius: var(--r-lg); }
.card-pad { padding: 20px; }
.card-title { display: flex; align-items: center; gap: 10px; font-size: 18px; font-weight: 900; }
.card-title .ic { width: 22px; height: 22px; color: var(--lav-deep); }
.card-sub { color: var(--ink-3); font-size: 14px; margin-top: 4px; }
.tip { display: flex; gap: 12px; align-items: flex-start; padding: 12px 14px; border-radius: 16px; background: var(--lav-3); border: 2px solid var(--lav-2); color: var(--ink-2); font-size: 14px; }
.tip .tip-av { width: 34px; height: 34px; border-radius: 50%; background: var(--lav); flex: 0 0 auto; object-fit: cover; }
.tip b { color: var(--ink); }
.callout { display: flex; gap: 10px; align-items: flex-start; padding: 12px 14px; border-radius: 14px; background: var(--green-2); color: var(--green-ink); font-size: 14px; font-weight: 700; }
.callout .ic { width: 18px; height: 18px; margin-top: 1px; }
.callout.warn { background: var(--mustard-2); color: var(--mustard-ink); }
.callout.info { background: var(--blue-2); color: #234b8f; }
.empty { text-align: center; padding: 26px 16px; border: 2px dashed var(--line-2); border-radius: 18px; color: var(--ink-3); font-weight: 700; }
.empty .btn { margin-top: 12px; }

/* ---------- app shell ---------- */
.shell { min-height: 100vh; display: flex; flex-direction: column; }
.topbar { position: sticky; top: 0; z-index: 50; height: var(--top-h); display: flex; align-items: center; gap: 16px; padding: 0 20px; background: rgba(255,255,255,.94); backdrop-filter: saturate(1.4) blur(10px); -webkit-backdrop-filter: saturate(1.4) blur(10px); border-bottom: 2px solid var(--line); }
.brand { display: inline-flex; align-items: center; gap: 10px; background: none; border: 0; padding: 0; text-decoration: none; flex: 0 0 auto; }
.brand-av { width: 40px; height: 40px; border-radius: 50%; background: var(--lav); object-fit: cover; object-position: 50% 12%; }
.brand-word { font-size: 27px; font-weight: 900; color: var(--green); letter-spacing: -.03em; line-height: 1; transform: translateY(-1px); }
.nav { display: flex; align-items: center; gap: 4px; margin-left: 14px; }
.nav-item { display: inline-flex; align-items: center; gap: 8px; height: 42px; padding: 0 14px; border-radius: 12px; border: 2px solid transparent; background: transparent; color: var(--ink-2); font-weight: 800; font-size: 15px; transition: background .15s, color .15s, border-color .15s; }
.nav-item .ic { width: 20px; height: 20px; }
.nav-item:hover { background: var(--surface-3); color: var(--ink); }
.nav-item.on { background: var(--lav-2); border-color: var(--lav-line); color: var(--lav-ink); }
.topbar-actions { margin-left: auto; display: flex; align-items: center; gap: 10px; }
.save-chip { display: inline-flex; align-items: center; gap: 6px; font-size: 13px; font-weight: 800; color: var(--ink-3); padding: 0 6px; transition: color .2s; }
.save-chip .ic { width: 16px; height: 16px; color: var(--green); }
.save-chip.busy { color: var(--ink-4); }
.save-chip.busy .ic { color: var(--ink-4); }
.ai-chip { display: inline-flex; align-items: center; gap: 6px; height: 30px; padding: 0 10px; border-radius: 999px; font-size: 12.5px; font-weight: 800; background: var(--mustard-2); color: var(--mustard-ink); }
.ai-chip .ic { width: 14px; height: 14px; }
.ai-chip.off { background: var(--surface-3); color: var(--ink-3); }
.view { flex: 1 1 auto; min-width: 0; }
.bottomnav { display: none; }
.page { max-width: 1320px; margin: 0 auto; padding: 24px 24px 64px; }
.page-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 16px; flex-wrap: wrap; margin-bottom: 20px; }
.page-head h1 { font-size: 30px; }
.page-head p { color: var(--ink-3); margin-top: 6px; font-size: 15.5px; max-width: 62ch; }
/* entrance animations fill "backwards" only: a finished animation must not leave the block on its own layer,
   or a dropdown inside it ends up underneath the next block */
.view-enter { animation: viewIn .35s var(--ease) backwards; }
@keyframes viewIn { from { transform: translateY(8px); } to { transform: none; } }

/* ---------- Rozzo stage (video loops on his exact lavender backdrop) ---------- */
.rz-stage { position: relative; aspect-ratio: 3 / 4; background: var(--lav); border-radius: var(--r-xl); overflow: hidden; isolation: isolate; flex: 0 0 auto; }
.rz-stage > img, .rz-stage > video { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; display: block; pointer-events: none; }
.rz-stage > video { opacity: 0; transition: opacity .28s ease; }
.rz-stage > video.on { opacity: 1; }
.rz-stage.round { border-radius: 50%; aspect-ratio: 1; }
.rz-stage.round > img, .rz-stage.round > video { object-position: 50% 14%; transform: scale(1.35); transform-origin: 50% 18%; }
.rz-av { width: 44px; height: 44px; border-radius: 50%; background: var(--lav); object-fit: cover; object-position: 50% 12%; flex: 0 0 auto; }

/* speech bubble with a tail pointing at Rozzo */
.bubble { position: relative; background: #fff; border: 2px solid var(--line-2); border-radius: 20px; padding: 16px 20px; font-size: 19px; font-weight: 800; line-height: 1.42; color: var(--ink); min-height: 60px; }
.bubble::before { content: ""; position: absolute; left: -11px; top: 26px; width: 18px; height: 18px; background: #fff; border-left: 2px solid var(--line-2); border-bottom: 2px solid var(--line-2); transform: rotate(45deg); border-bottom-left-radius: 4px; }
.bubble.typing::after { content: ""; display: inline-block; width: 3px; height: 1em; margin-left: 2px; vertical-align: -2px; background: var(--lav-deep); border-radius: 2px; animation: caret .8s steps(1) infinite; }
@keyframes caret { 50% { opacity: 0; } }
.bubble strong { color: var(--green-ink); }
.bubble.flat::before { display: none; }

/* ---------- progress ---------- */
.progress { position: relative; height: 16px; background: var(--line); border-radius: 999px; overflow: hidden; flex: 1 1 auto; }
.progress > span { position: absolute; left: 0; top: 0; bottom: 0; background: var(--green); border-radius: 999px; transition: width .6s var(--ease); }
.progress > span::after { content: ""; position: absolute; left: 8px; right: 8px; top: 4px; height: 4px; border-radius: 999px; background: rgba(255,255,255,.32); }

/* ---------- résumé paper previews ---------- */
.paper-view { position: relative; overflow: hidden; border-radius: 14px; background: var(--surface-3); }
.paper-view .paper { position: absolute; top: 0; left: 0; transform-origin: 0 0; box-shadow: 0 1px 2px rgba(30,36,66,.08), 0 6px 18px rgba(30,36,66,.08); }
.preview-card { display: flex; flex-direction: column; gap: 12px; padding: 14px; }
.bubble-av { display: none; }
.preview-head { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.preview-head .t { font-weight: 900; font-size: 15px; }
.preview-head .s { color: var(--ink-3); font-size: 13px; font-weight: 700; }
.preview-scroll { max-height: calc(100vh - var(--top-h) - 170px); overflow: auto; border-radius: 14px; scrollbar-width: thin; }
.preview-actions { display: flex; gap: 8px; flex-wrap: wrap; }
.page-meter { display: inline-flex; align-items: center; gap: 6px; font-size: 12.5px; font-weight: 800; color: var(--ink-3); }
.page-meter.over { color: var(--mustard-ink); }

/* ---------- toast ---------- */
.toast { position: fixed; left: 50%; bottom: 24px; z-index: 400; display: flex; align-items: center; gap: 14px; max-width: min(560px, calc(100vw - 32px)); padding: 12px 14px 12px 18px; border-radius: 16px; background: var(--navy); color: #fff; font-weight: 700; font-size: 14.5px; box-shadow: var(--sh-3); transform: translate(-50%, 20px); opacity: 0; pointer-events: none; transition: opacity .25s, transform .25s var(--ease); }
.toast.show { opacity: 1; transform: translate(-50%, 0); pointer-events: auto; }
.toast.ok { background: #235e19; }
.toast.err { background: #8c2227; }
.toast button { background: rgba(255,255,255,.14); border: 0; color: #fff; font-weight: 900; border-radius: 10px; padding: 7px 12px; font-size: 13.5px; }
.toast button:hover { background: rgba(255,255,255,.24); }

/* ---------- modal / sheet ---------- */
.scrim { position: fixed; inset: 0; z-index: 300; background: rgba(24,28,52,.45); backdrop-filter: blur(2px); display: flex; align-items: center; justify-content: center; padding: 20px; animation: fadeIn .2s ease both; }
@keyframes fadeIn { from { opacity: 0; } }
.modal { position: relative; width: min(560px, 100%); max-height: calc(100vh - 40px); display: flex; flex-direction: column; background: #fff; border-radius: 24px; box-shadow: var(--sh-3); animation: popIn .28s var(--ease) both; overflow: hidden; }
.modal.wide { width: min(880px, 100%); }
.modal.xwide { width: min(1100px, 100%); }
@keyframes popIn { from { opacity: .4; transform: translateY(14px) scale(.98); } to { opacity: 1; transform: none; } }
.modal-head { display: flex; align-items: center; gap: 12px; padding: 18px 18px 6px 22px; }
.modal-head h2 { font-size: 21px; flex: 1 1 auto; }
.modal-body { padding: 10px 22px 20px; overflow: auto; }
.modal-foot { display: flex; align-items: center; justify-content: flex-end; gap: 10px; padding: 14px 22px 20px; border-top: 2px solid var(--line); flex-wrap: wrap; }
.modal-foot .left { margin-right: auto; }
.zoom-scrim { align-items: flex-start; overflow: auto; padding: 72px 20px 40px; }
.zoom-bar { position: fixed; top: 14px; left: 50%; transform: translateX(-50%); z-index: 2; display: flex; gap: 10px; align-items: center; background: #fff; padding: 6px; border-radius: 18px; box-shadow: var(--sh-2); }
.zoom-paper { margin: 0 auto; box-shadow: var(--sh-3); transform-origin: top center; }

/* ---------- loader ---------- */
.boot { position: fixed; inset: 0; z-index: 500; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 18px; background: var(--bg); transition: opacity .35s, visibility .35s; }
.boot.hide { opacity: 0; visibility: hidden; }
.boot .rz-stage { width: 150px; }
.boot-word { font-size: 34px; font-weight: 900; color: var(--green); letter-spacing: -.03em; }
.boot-bar { width: 160px; height: 10px; border-radius: 99px; background: var(--line); overflow: hidden; }
.boot-bar span { display: block; height: 100%; width: 40%; border-radius: 99px; background: var(--green); animation: bootSlide 1s ease-in-out infinite; }
@keyframes bootSlide { 0% { transform: translateX(-100%); } 100% { transform: translateX(260%); } }

/* busy overlay: Rozzo writes, then thumbs up */
.busy { position: fixed; inset: 0; z-index: 350; display: flex; align-items: center; justify-content: center; padding: 20px; background: rgba(248,247,253,.86); backdrop-filter: blur(4px); animation: fadeIn .2s ease both; }
.busy-card { width: min(360px, 100%); display: flex; flex-direction: column; align-items: center; gap: 14px; text-align: center; background: #fff; border: 2px solid var(--line); border-radius: 26px; padding: 22px 22px 24px; box-shadow: var(--sh-3); }
.busy-card .rz-stage { width: 170px; }
.busy-msg { font-size: 18px; font-weight: 900; }
.busy-bar { width: 180px; height: 10px; border-radius: 99px; background: var(--line); overflow: hidden; }
.busy-bar span { display: block; height: 100%; width: 40%; border-radius: 99px; background: var(--mustard); animation: bootSlide 1s ease-in-out infinite; }
.busy.done .busy-bar { visibility: hidden; }

/* confetti */
.confetti { position: fixed; top: -16px; width: 10px; height: 14px; border-radius: 3px; z-index: 450; pointer-events: none; }
@keyframes fall { to { transform: translateY(106vh) rotate(720deg); opacity: .3; } }

/* =========================================================================
   COACH — focused, lesson-style flow with Rozzo
   ======================================================================= */
.coach { min-height: 100vh; display: flex; flex-direction: column; background: var(--bg); }
.coach-top { position: sticky; top: 0; z-index: 40; display: flex; align-items: center; gap: 16px; height: 72px; padding: 0 22px; background: rgba(248,247,253,.94); backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px); }
.coach-top .brand-av { width: 34px; height: 34px; }
.coach-chapter { font-weight: 900; font-size: 14px; color: var(--ink-2); white-space: nowrap; min-width: 0; overflow: hidden; text-overflow: ellipsis; }
.coach-chapter small { color: var(--ink-3); font-weight: 800; font-size: 13px; margin-left: 4px; }
.coach-body { flex: 1 1 auto; display: grid; grid-template-columns: minmax(0, 1fr) 380px; gap: 28px; width: 100%; max-width: 1320px; margin: 0 auto; padding: 18px 24px 140px; align-items: start; }
.coach.no-side .coach-body { grid-template-columns: minmax(0, 1fr); max-width: 980px; }
.coach.no-side .coach-side { display: none; }
.coach-main { min-width: 0; display: flex; flex-direction: column; gap: 22px; }
.coach-talk { display: flex; align-items: flex-end; gap: 22px; }
.coach-talk .rz-stage { width: 190px; }
.coach-talk .bubble { flex: 1 1 auto; margin-bottom: 24px; }
.coach-answer { min-height: 60px; }
.coach-answer.enter > * { animation: viewIn .35s var(--ease) backwards; }
.coach-side { position: sticky; top: 90px; }
.coach-side .card { padding: 14px; }
.coach-foot { position: fixed; left: 0; right: 0; bottom: 0; z-index: 45; background: #fff; border-top: 2px solid var(--line); padding: 14px 22px calc(14px + env(safe-area-inset-bottom, 0px)); }
.coach-foot-in { max-width: 1320px; margin: 0 auto; display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; gap: 12px; }
.cf-side { display: flex; align-items: center; gap: 12px; min-width: 0; }
.cf-end { justify-content: flex-end; }
/* the Rozzo logo in the middle of the bar */
.foot-brand { display: inline-flex; align-items: center; gap: 8px; user-select: none; }
.foot-brand img { width: 34px; height: 34px; border-radius: 50%; background: var(--lav); object-fit: cover; object-position: 50% 12%; }
.foot-brand span { font-size: 24px; font-weight: 900; color: var(--green); letter-spacing: -.03em; line-height: 1; transform: translateY(-1px); }
.coach-foot .hintline { color: var(--ink-3); font-size: 13.5px; font-weight: 700; }
.kbd { display: inline-block; padding: 1px 6px; border-radius: 6px; border: 1.5px solid var(--line-2); border-bottom-width: 3px; font-size: 11.5px; font-weight: 900; color: var(--ink-2); background: #fff; }

/* coach answer widgets */
.q-input { font-size: 20px; font-weight: 800; padding: 15px 18px; border-radius: 16px; }
.q-area { font-size: 17px; font-weight: 700; min-height: 150px; border-radius: 16px; padding: 14px 16px; }
.q-hint { margin-top: 10px; color: var(--ink-3); font-size: 13.5px; font-weight: 700; }
.q-card { background: #fff; border: 2px solid var(--line); border-radius: 20px; padding: 18px; }
.choice-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 14px; }
.choice { position: relative; display: flex; flex-direction: column; align-items: flex-start; gap: 6px; text-align: left; padding: 18px 18px 16px; border-radius: 20px; background: #fff; border: 2px solid var(--line-2); box-shadow: 0 4px 0 var(--line-2); transition: transform .08s, box-shadow .08s, border-color .15s, background .15s; min-height: 100%; }
.choice:hover { border-color: var(--line-3); background: var(--lav-3); }
.choice:active { transform: translateY(4px); box-shadow: 0 0 0 var(--line-2); }
.choice.on { border-color: var(--lav-deep); background: var(--lav-2); box-shadow: 0 4px 0 var(--lav-deep); }
.choice .c-ic { width: 46px; height: 46px; border-radius: 14px; display: grid; place-items: center; background: var(--lav-2); color: var(--lav-ink); margin-bottom: 4px; }
.choice .c-ic .ic { width: 24px; height: 24px; }
.choice .c-ic.green { background: var(--green-2); color: var(--green-ink); }
.choice .c-ic.mustard { background: var(--mustard-2); color: var(--mustard-ink); }
.choice h4 { font-size: 17px; font-weight: 900; }
.choice p { color: var(--ink-3); font-size: 14px; font-weight: 700; }
.choice .c-count { position: absolute; top: 12px; right: 12px; }
.choice .c-check { position: absolute; top: 12px; right: 12px; width: 26px; height: 26px; border-radius: 50%; border: 2px solid var(--line-2); background: #fff; display: grid; place-items: center; color: transparent; }
.choice.on .c-check { background: var(--lav-deep); border-color: var(--lav-deep); color: #fff; }
.choice.done { border-color: var(--green-line); }
.choice.done .c-check { background: var(--green); border-color: var(--green); color: #fff; }
.choice .c-check .ic { width: 15px; height: 15px; }
.look-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: 16px; }
.look { display: flex; flex-direction: column; gap: 8px; padding: 10px; border-radius: 18px; background: #fff; border: 2px solid var(--line-2); box-shadow: 0 4px 0 var(--line-2); text-align: left; transition: transform .08s, box-shadow .08s, border-color .15s; }
.look:active { transform: translateY(4px); box-shadow: 0 0 0 var(--line-2); }
.look:hover { border-color: var(--line-3); }
.look.on { border-color: var(--green); box-shadow: 0 4px 0 var(--green-lip); }
.look .paper-view { aspect-ratio: 210 / 250; }
.look b { font-weight: 900; font-size: 14.5px; padding: 0 4px; }
.look span { color: var(--ink-3); font-size: 12.5px; font-weight: 700; padding: 0 4px 2px; margin-top: -6px; }
.contact-card { display: grid; gap: 14px; }
.phone-row { display: grid; grid-template-columns: 132px minmax(0, 1fr); gap: 10px; }
.job-card { display: grid; gap: 14px; }
.date-row { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; }
.date-pair { display: grid; grid-template-columns: minmax(0, 1.1fr) minmax(0, 1fr); gap: 8px; }
.ac-wrap { position: relative; }
.ac-wrap:focus-within { z-index: 60; } /* the open list sits above everything after it */
.ac-list { position: absolute; left: 0; right: 0; top: calc(100% + 6px); z-index: 30; background: #fff; border: 2px solid var(--line-2); border-radius: 16px; box-shadow: var(--sh-2); padding: 6px; display: none; max-height: 290px; overflow: auto; }
.ac-list.show { display: block; }
.ac-item { display: block; width: 100%; text-align: left; border: 0; background: none; padding: 10px 12px; border-radius: 10px; font-weight: 700; font-size: 15px; color: var(--ink); }
.ac-item:hover, .ac-item.hl { background: var(--lav-2); color: var(--lav-ink); }
.added-list { display: grid; gap: 8px; margin-top: 14px; }
.added { display: flex; align-items: center; gap: 10px; padding: 10px 10px 10px 14px; border-radius: 14px; background: #fff; border: 2px solid var(--line); font-weight: 700; animation: viewIn .3s var(--ease) backwards; }
.added .ic-lead { width: 18px; height: 18px; color: var(--green); }
.added .t { flex: 1 1 auto; min-width: 0; overflow-wrap: anywhere; }
.inline-add { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 10px; align-items: start; }
.bullet-review { display: grid; gap: 8px; }
.bullet-review .b { display: flex; gap: 10px; align-items: flex-start; background: #fff; border: 2px solid var(--line); border-radius: 14px; padding: 10px 10px 10px 14px; }
.bullet-review .b .dot { width: 8px; height: 8px; border-radius: 50%; background: var(--green); margin-top: 9px; flex: 0 0 auto; }
.bullet-review .b textarea { flex: 1 1 auto; border: 0; background: transparent; resize: none; font-weight: 700; font-size: 15.5px; line-height: 1.45; padding: 2px 0; min-height: 0; overflow: hidden; }
.bullet-review .b textarea:focus { outline: none; }
.sum-options { display: grid; gap: 12px; }
.sum-opt { display: block; width: 100%; text-align: left; padding: 16px 18px; border-radius: 18px; background: #fff; border: 2px solid var(--line-2); box-shadow: 0 4px 0 var(--line-2); font-weight: 700; font-size: 15px; line-height: 1.5; color: var(--ink); transition: transform .08s, box-shadow .08s, border-color .15s, background .15s; }
.sum-opt .tag { margin-bottom: 8px; }
.sum-opt:active { transform: translateY(4px); box-shadow: 0 0 0 var(--line-2); }
.sum-opt.on { border-color: var(--lav-deep); background: var(--lav-3); box-shadow: 0 4px 0 var(--lav-deep); }

/* upload drop zone */
.drop { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 10px; text-align: center; padding: 30px 20px; border-radius: 22px; border: 3px dashed var(--line-3); background: #fff; cursor: pointer; transition: border-color .15s, background .15s; }
.drop:hover, .drop.over { border-color: var(--green); background: var(--green-2); }
.drop .d-ic { width: 60px; height: 60px; border-radius: 18px; background: var(--green-2); color: var(--green-ink); display: grid; place-items: center; }
.drop .d-ic .ic { width: 30px; height: 30px; }
.drop b { font-size: 18px; font-weight: 900; }
.drop span { color: var(--ink-3); font-weight: 700; font-size: 14px; }
.paste-row { display: flex; justify-content: center; margin-top: 10px; }
.paste-box { margin-top: 14px; }
.found-tags { display: flex; flex-wrap: wrap; gap: 6px; }
.found-tags .tag { font-size: 12.5px; padding: 4px 10px; }

/* chapter card (between sections) */
.chapter { display: flex; flex-direction: column; align-items: center; text-align: center; gap: 16px; padding: 8px 0 20px; animation: viewIn .4s var(--ease) backwards; }
.chapter .rz-stage { width: 230px; }
.chapter-kicker { display: inline-flex; align-items: center; gap: 8px; padding: 6px 14px; border-radius: 999px; background: var(--green-2); color: var(--green-ink); font-weight: 900; font-size: 13.5px; }
.chapter h2 { font-size: 34px; }
.chapter p { color: var(--ink-2); font-size: 17px; font-weight: 700; max-width: 46ch; }
.verdict { display: flex; align-items: center; gap: 20px; flex-wrap: wrap; }

/* score ring */
.ring { position: relative; width: 132px; height: 132px; flex: 0 0 auto; }
.ring svg { width: 100%; height: 100%; transform: rotate(-90deg); }
.ring .track { fill: none; stroke: var(--line); stroke-width: 12; }
.ring .arc { fill: none; stroke: var(--green); stroke-width: 12; stroke-linecap: round; transition: stroke-dashoffset 1s var(--ease); }
.ring.fair .arc { stroke: var(--mustard); }
.ring.poor .arc { stroke: var(--red); }
.ring .num { position: absolute; inset: 0; display: flex; flex-direction: column; align-items: center; justify-content: center; font-weight: 900; font-size: 38px; line-height: 1; }
.ring .num small { font-size: 13px; color: var(--ink-3); font-weight: 800; margin-top: 4px; }
.ring.sm { width: 64px; height: 64px; }
.ring.sm .num { font-size: 20px; }
.ring.sm .num small { display: none; }
.ring.sm .track, .ring.sm .arc { stroke-width: 11; }
.band { display: inline-flex; align-items: center; gap: 6px; padding: 5px 12px; border-radius: 999px; font-weight: 900; font-size: 13.5px; background: var(--green-2); color: var(--green-ink); }
.band.fair { background: var(--mustard-2); color: var(--mustard-ink); }
.band.poor { background: var(--red-2); color: var(--red-ink); }

/* =========================================================================
   HOME — score, Rozzo's plan, breakdown, tailor, preview
   ======================================================================= */
.home { display: grid; grid-template-columns: minmax(0, 1fr) 400px; gap: 24px; align-items: start; }
.home-col { display: flex; flex-direction: column; gap: 20px; min-width: 0; }
.home-side { position: sticky; top: calc(var(--top-h) + 20px); }
.hero { display: grid; grid-template-columns: 200px minmax(0, 1fr); gap: 24px; align-items: center; padding: 22px; }
.hero .rz-stage { width: 200px; }
.hero-main { display: flex; flex-direction: column; gap: 16px; min-width: 0; }
.hero-score { display: flex; align-items: center; gap: 18px; flex-wrap: wrap; }
.hero-score h1 { font-size: 26px; }
.hero-score .sub { color: var(--ink-3); font-size: 14.5px; margin-top: 4px; }
.hero .bubble { font-size: 16.5px; }
.hero .bubble::before { top: -11px; left: 30px; transform: rotate(135deg); }
.hero-actions { display: flex; gap: 10px; flex-wrap: wrap; }
.plan-item { display: grid; grid-template-columns: auto minmax(0, 1fr) auto; gap: 14px; align-items: center; padding: 14px 0; border-top: 2px solid var(--line); }
.plan-item:first-of-type { border-top: 0; }
.plan-gain { min-width: 54px; height: 36px; padding: 0 10px; border-radius: 12px; display: grid; place-items: center; background: var(--green-2); color: var(--green-ink); font-weight: 900; font-size: 15px; }
.plan-item b { font-weight: 900; font-size: 15.5px; }
.plan-item .t { color: var(--ink-3); font-size: 13.5px; margin-top: 2px; }
.plan-form { grid-column: 2 / -1; display: grid; gap: 10px; padding-top: 4px; }
.params { display: grid; gap: 14px; margin-top: 14px; }
.param-top { display: flex; justify-content: space-between; gap: 12px; font-size: 14.5px; }
.param-top b { font-weight: 900; }
.param-top span { font-weight: 900; color: var(--ink-3); font-variant-numeric: tabular-nums; }
.meter { height: 10px; border-radius: 99px; background: var(--line); overflow: hidden; margin: 7px 0 5px; }
.meter > span { display: block; height: 100%; border-radius: 99px; background: var(--green); }
.param.fair .meter > span { background: var(--mustard); }
.param.poor .meter > span { background: var(--red); }
.param-tip { color: var(--ink-3); font-size: 13.5px; }
.kw { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 8px; }
.kw .tag { cursor: default; }
.kw .tag.add { cursor: pointer; background: var(--mustard-2); color: var(--mustard-ink); border: 0; }
.kw .tag.add:hover { filter: brightness(.97); }
.weak { display: flex; gap: 12px; align-items: flex-start; padding: 12px 0; border-top: 2px solid var(--line); }
.weak:first-of-type { border-top: 0; }
.weak .flag { width: 26px; height: 26px; border-radius: 9px; background: var(--mustard-2); color: var(--mustard-ink); display: grid; place-items: center; font-weight: 900; flex: 0 0 auto; }
.weak .why { color: var(--mustard-ink); font-size: 13px; font-weight: 800; margin-top: 3px; }
.home-2 { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 20px; align-items: start; }
.checklist { display: grid; gap: 4px; margin-top: 8px; }
.checklist button { display: flex; align-items: center; gap: 10px; width: 100%; text-align: left; border: 0; background: none; padding: 8px 8px; border-radius: 12px; font-weight: 800; font-size: 14.5px; color: var(--ink); }
.checklist button:hover { background: var(--surface-3); }
.checklist .st { width: 24px; height: 24px; border-radius: 50%; border: 2px solid var(--line-2); display: grid; place-items: center; flex: 0 0 auto; color: #fff; }
.checklist .st.done { background: var(--green); border-color: var(--green); }
.checklist .st .ic { width: 14px; height: 14px; }
.checklist .n { margin-left: auto; color: var(--ink-3); font-size: 13px; }
.jd { min-height: 120px; }

/* =========================================================================
   EDITOR — sections list · form · live preview
   ======================================================================= */
.editor { display: grid; grid-template-columns: 230px minmax(0, 1fr) 400px; gap: 24px; align-items: start; }
.ed-nav { position: sticky; top: calc(var(--top-h) + 20px); display: flex; flex-direction: column; gap: 2px; }
.ed-nav-title { font-size: 12.5px; font-weight: 900; letter-spacing: .06em; text-transform: uppercase; color: var(--ink-3); padding: 0 12px 8px; }
.ed-link { display: flex; align-items: center; gap: 10px; width: 100%; padding: 9px 12px; border-radius: 12px; border: 2px solid transparent; background: none; text-align: left; font-weight: 800; font-size: 14.5px; color: var(--ink-2); transition: background .15s, color .15s; }
.ed-link .ic { width: 19px; height: 19px; color: var(--ink-3); }
.ed-link:hover { background: var(--surface-3); color: var(--ink); }
.ed-link.on { background: var(--lav-2); border-color: var(--lav-line); color: var(--lav-ink); }
.ed-link.on .ic { color: var(--lav-ink); }
.ed-link .st { margin-left: auto; width: 20px; height: 20px; border-radius: 50%; display: grid; place-items: center; }
.ed-link .st.done { background: var(--green); color: #fff; }
.ed-link .st.done .ic { width: 12px; height: 12px; color: #fff; }
.ed-link .st.count { width: auto; min-width: 22px; padding: 0 6px; border-radius: 99px; background: var(--surface-3); color: var(--ink-3); font-size: 12px; }
.ed-nav-extra { margin-top: 14px; padding-top: 14px; border-top: 2px solid var(--line); display: grid; gap: 8px; }
.ed-main { min-width: 0; display: flex; flex-direction: column; gap: 18px; }
.ed-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 14px; flex-wrap: wrap; }
.ed-head h1 { font-size: 28px; }
.ed-head p { color: var(--ink-3); margin-top: 6px; max-width: 60ch; }
.ed-chips { display: none; }
.ed-pager { display: flex; justify-content: space-between; gap: 10px; margin-top: 4px; flex-wrap: wrap; }
.ed-preview { position: sticky; top: calc(var(--top-h) + 20px); }
.ed-preview .card { padding: 14px; }
.entry { background: #fff; border: 2px solid var(--line); border-radius: 18px; transition: border-color .15s, box-shadow .15s; }
.entry.open { border-color: var(--line-2); box-shadow: var(--sh-2); }
.entry-head { display: flex; align-items: center; gap: 10px; padding: 12px 12px 12px 16px; cursor: pointer; user-select: none; }
.entry-head .e-ic { width: 38px; height: 38px; border-radius: 12px; background: var(--lav-2); color: var(--lav-ink); display: grid; place-items: center; flex: 0 0 auto; }
.entry-head .e-ic .ic { width: 20px; height: 20px; }
.entry-head .e-t { flex: 1 1 auto; min-width: 0; }
.entry-head .e-t b { display: block; font-weight: 900; font-size: 15.5px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.entry-head .e-t span { display: block; color: var(--ink-3); font-size: 13px; font-weight: 700; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.entry-head .chev { transition: transform .2s; color: var(--ink-3); }
.entry.open .entry-head .chev { transform: rotate(180deg); }
.entry-body { display: none; padding: 4px 16px 18px; }
.entry.open .entry-body { display: grid; gap: 14px; }
.bullets { display: grid; gap: 8px; margin: 0; padding: 0; list-style: none; }
.bullet { display: grid; grid-template-columns: 10px minmax(0, 1fr) auto; gap: 10px; align-items: start; }
.bullet .dot { width: 8px; height: 8px; border-radius: 50%; background: var(--ink-4); margin-top: 19px; }
.bullet .textarea { min-height: 50px; padding: 10px 12px; font-size: 15px; font-weight: 700; }
.bullet .b-tools { display: flex; flex-direction: column; gap: 2px; padding-top: 4px; }
.suggest { display: grid; gap: 8px; padding: 14px; border-radius: 16px; background: var(--mustard-2); }
.suggest-t { display: flex; align-items: center; gap: 8px; font-weight: 900; font-size: 13.5px; color: var(--mustard-ink); }
.suggest-t .ic { width: 17px; height: 17px; }
.sugg { display: flex; gap: 8px; align-items: flex-start; text-align: left; border: 0; background: rgba(255,255,255,.75); border-radius: 12px; padding: 9px 12px; font-weight: 700; font-size: 14px; color: var(--ink); transition: background .15s; }
.sugg:hover { background: #fff; }
.sugg .ic { width: 16px; height: 16px; color: var(--mustard-ink); margin-top: 2px; }
.photo-up { display: flex; align-items: center; gap: 14px; flex-wrap: wrap; }
.photo-thumb { width: 68px; height: 68px; border-radius: 50%; object-fit: cover; background: var(--surface-3); display: grid; place-items: center; color: var(--ink-3); border: 2px solid var(--line); }
.skill-rate { display: grid; gap: 8px; }
.skill-row { display: grid; grid-template-columns: minmax(0, 1fr) auto auto; gap: 12px; align-items: center; background: #fff; border: 2px solid var(--line); border-radius: 14px; padding: 8px 8px 8px 14px; }
.skill-row .n { font-weight: 800; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.lv { display: inline-flex; gap: 4px; }
.lv button { width: 26px; height: 14px; border-radius: 5px; border: 0; background: var(--line-2); padding: 0; transition: background .15s, transform .1s; }
.lv button:hover { transform: translateY(-1px); }
.lv button.on { background: var(--green); }
.lv-l { width: 88px; text-align: right; font-size: 12.5px; font-weight: 900; color: var(--ink-3); }
.count-line { display: flex; align-items: center; gap: 10px; font-weight: 800; color: var(--ink-2); font-size: 14px; }
/* skills step: describe what you're good at; the skills found are added as they type */
.sk-desc textarea { min-height: 84px; resize: none; line-height: 1.45; overflow: hidden; }
.sk-found { display: flex; align-items: flex-start; gap: 6px; margin-top: 2px; font-size: 13.5px; font-weight: 700; line-height: 1.45; color: var(--green-ink); }
.sk-found:empty { display: none; }
.sk-found svg { flex: 0 0 auto; width: 16px; height: 16px; margin-top: 2px; }
.sk-found b { font-weight: 800; }
.sk-found.busy::after { content: "Rozzo is reading…"; margin-left: 6px; color: var(--ink-3); }
.count-line .meter { flex: 1 1 auto; max-width: 180px; margin: 0; }
.role-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(170px, 1fr)); gap: 10px; }

/* =========================================================================
   DESIGN — template gallery
   ======================================================================= */
.design-controls { display: flex; flex-wrap: wrap; align-items: center; gap: 14px 22px; margin-bottom: 20px; padding: 14px 16px; background: #fff; border: 2px solid var(--line); border-radius: 20px; }
.design-controls .grp { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.design-controls .grp > .label { margin-right: 2px; }
.swatches { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; }
.swatch { width: 30px; height: 30px; border-radius: 50%; border: 3px solid #fff; box-shadow: 0 0 0 2px var(--line-2); padding: 0; transition: transform .12s, box-shadow .12s; }
.swatch:hover { transform: scale(1.08); }
.swatch.on { box-shadow: 0 0 0 3px var(--ink); }
.swatch.auto { background: conic-gradient(#e0484e, #eea235, #49a52c, #3b76d8, #8a81c9, #e0484e); }
.tpl-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: 20px; }
.tpl { position: relative; display: flex; flex-direction: column; gap: 10px; padding: 10px 10px 14px; background: #fff; border: 2px solid var(--line); border-radius: 22px; transition: border-color .15s, box-shadow .15s, transform .15s; }
.tpl:hover { border-color: var(--line-2); box-shadow: var(--sh-2); transform: translateY(-2px); }
.tpl.on { border-color: var(--green); box-shadow: 0 0 0 3px var(--green-2); }
.tpl .paper-view { aspect-ratio: 210 / 262; cursor: pointer; }
.tpl-info { display: flex; align-items: flex-start; justify-content: space-between; gap: 10px; padding: 0 6px; }
.tpl-info b { font-weight: 900; font-size: 16px; }
.tpl-info p { color: var(--ink-3); font-size: 13px; font-weight: 700; margin-top: 2px; }
.tpl-tags { display: flex; gap: 6px; flex-wrap: wrap; padding: 0 6px; }
.tpl-actions { display: flex; gap: 8px; padding: 0 6px; }
.tpl-actions .btn { flex: 1 1 auto; }
.tpl-badge { position: absolute; top: 18px; left: 18px; z-index: 2; }

/* =========================================================================
   RESPONSIVE
   ======================================================================= */
@media (max-width: 1280px) {
  .coach-body { grid-template-columns: minmax(0, 1fr) 340px; }
}
@media (max-width: 1120px) {
  .coach-body { grid-template-columns: minmax(0, 1fr); max-width: 900px; }
  .coach-side { display: none; }
  .only-wide { display: none !important; }
}
@media (min-width: 1121px) { .only-narrow { display: none !important; } }
/* pages inside the app shell size themselves to the content area (the left panel takes part of the window) */
.view { container: view / inline-size; }
@container view (max-width: 1280px) {
  .editor { grid-template-columns: 210px minmax(0, 1fr) 360px; }
  .home { grid-template-columns: minmax(0, 1fr) 360px; }
}
@container view (max-width: 1120px) {
  .editor { grid-template-columns: 210px minmax(0, 1fr); }
  .ed-preview { display: none; }
}
@container view (max-width: 980px) {
  .home { grid-template-columns: minmax(0, 1fr); }
  .home-side { position: static; }
  .home-2 { grid-template-columns: minmax(0, 1fr); }
}
@container view (max-width: 760px) {
  .hero { grid-template-columns: 130px minmax(0, 1fr); gap: 18px; }
  .hero .rz-stage { width: 130px; }
}
@media (max-width: 860px) {
  :root { --top-h: 58px; }
  .topbar { padding: 0 14px; gap: 10px; }
  .brand-word { font-size: 24px; }
  .brand-av { width: 36px; height: 36px; }
  .save-chip span { display: none; }
  .bottomnav { display: flex; position: fixed; left: 0; right: 0; bottom: 0; z-index: 60; background: #fff; border-top: 2px solid var(--line); padding: 6px 6px calc(6px + env(safe-area-inset-bottom, 0px)); justify-content: space-around; }
  .bottomnav .nav-item { flex-direction: column; gap: 2px; height: 54px; min-width: 64px; padding: 0 8px; font-size: 11.5px; border-radius: 14px; }
  .bottomnav .nav-item .ic { width: 23px; height: 23px; }
  .view { padding-bottom: 84px; }
  .page { padding: 16px 16px 40px; }
  .page-head h1, .ed-head h1 { font-size: 25px; }
  .editor { grid-template-columns: minmax(0, 1fr); gap: 14px; }
  .ed-nav { display: none; }
  .ed-chips { display: flex; gap: 8px; overflow-x: auto; margin: 0 -16px; padding: 2px 16px 6px; scrollbar-width: none; }
  .ed-chips::-webkit-scrollbar { display: none; }
  .ed-chips .chip { flex: 0 0 auto; }
  .hero { grid-template-columns: 110px minmax(0, 1fr); gap: 16px; padding: 16px; }
  .hero .rz-stage { width: 110px; }
  .hero-score h1 { font-size: 21px; }
  .coach-top { height: 62px; padding: 0 12px; gap: 10px; }
  .coach-body { padding: 10px 16px 130px; }
  .coach-talk { gap: 12px; align-items: flex-start; }
  .coach-talk .rz-stage { width: 112px; border-radius: 22px; }
  .coach-talk .bubble { margin: 18px 0 0; font-size: 17px; padding: 13px 15px; }
  .coach-talk .bubble::before { top: 22px; }
  .coach-foot { padding: 10px 14px calc(10px + env(safe-area-inset-bottom, 0px)); }
  .coach-foot .hintline { display: none; }
  .coach-top .coach-chapter, .coach-top .ai-chip { display: none; }
  .coach-top #co-prev { padding: 0 10px; }
  .coach-top #co-prev .lbl { display: none; }
  .chapter .rz-stage { width: 170px; }
  .chapter h2 { font-size: 27px; }
  .toast { bottom: calc(84px + env(safe-area-inset-bottom, 0px)); }
  .coach ~ .toast, body.in-coach .toast { bottom: calc(96px + env(safe-area-inset-bottom, 0px)); }
}
@media (max-width: 560px) {
  .grid-2, .grid-3, .date-row { grid-template-columns: minmax(0, 1fr); }
  .phone-row { grid-template-columns: 112px minmax(0, 1fr); }
  .topbar-actions .btn-sm { padding: 0 11px; }
  .topbar-actions .btn .lbl { display: none; }
  .hero { grid-template-columns: minmax(0, 1fr); }
  .hero .rz-stage { width: 120px; }
  .ring { width: 110px; height: 110px; }
  .ring .num { font-size: 32px; }
  .plan-item { grid-template-columns: auto minmax(0, 1fr); }
  .plan-item .plan-act { grid-column: 2; }
  .plan-form { grid-column: 1 / -1; }
  .coach-talk .rz-stage { width: 96px; }
  /* phones: just Rozzo's face, so it stays in the middle without crowding Back and Continue */
  .foot-brand img { width: 32px; height: 32px; }
  .foot-brand span { display: none; }
  .coach-foot-in.has-skip { display: flex; flex-wrap: wrap; row-gap: 10px; }
  .coach-foot-in.has-skip .cf-side { display: contents; }
  .coach-foot-in.has-skip .foot-brand { display: none; }
  .coach-foot-in.has-skip #co-next { order: -1; flex: 1 1 100%; }
  .coach-foot-in.has-skip #co-skip { flex: 1 1 auto; }
  .coach-body { padding-bottom: 200px; }
  .hero #home-stage { display: none; }
  .hero .bubble-av { display: block; float: left; width: 38px; height: 38px; margin: -2px 10px 2px -4px; }
  .coach-talk .bubble { font-size: 16px; }
  .q-input { font-size: 18px; }
  .choice-grid { grid-template-columns: minmax(0, 1fr); }
  .look-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .tpl-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
  .tpl { padding: 8px 8px 12px; border-radius: 18px; }
  .tpl-info p, .tpl-tags { display: none; }
  .tpl-actions .btn-secondary { display: none; }
  .modal { border-radius: 22px; }
  .modal-body { padding: 8px 16px 16px; }
  .modal-foot { padding: 12px 16px 16px; }
  .skill-row { grid-template-columns: minmax(0, 1fr) auto; }
  .skill-row .lv-l { display: none; }
  .design-controls { padding: 12px; }
}
/* ---------- micro-interactions: small, quick, and all from a visible starting point ---------- */
.view.enter > * { animation: viewIn .38s var(--ease) both; }
.choice { transition: transform .14s var(--ease), box-shadow .14s var(--ease), border-color .15s, background .15s; }
.choice:hover { transform: translateY(-2px); }
.choice:active { transform: translateY(4px); }
.btn-primary:not([disabled]):hover, .btn-ai:not([disabled]):hover, .btn-navy:not([disabled]):hover { transform: translateY(-1px); box-shadow: 0 5px 0 var(--b-lip); }
.chip.on { animation: chipPop .3s var(--ease); }
@keyframes chipPop { 45% { transform: scale(1.07); } }
.found-tags .tag { animation: tagPop .45s var(--ease) both; animation-delay: calc(var(--i, 0) * 70ms); }
@keyframes tagPop { from { transform: translateY(4px) scale(.7); } }
.save-chip.just .ic { animation: savedPop .55s var(--ease); }
@keyframes savedPop { 35% { transform: scale(1.35) rotate(-10deg); } }
.meter > span { transition: width .7s var(--ease); }
.ring .num { font-variant-numeric: tabular-nums; }
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .001ms !important; animation-iteration-count: 1 !important; transition-duration: .001ms !important; }
  .choice:hover, .btn:hover { transform: none !important; }
}

/* =========================================================================
   ACCOUNTS + JOBS
   ======================================================================= */
.acct-slot { display: inline-flex; }
.acct-btn { width: 40px; height: 40px; border-radius: 50%; border: 2px solid var(--green-lip); background: var(--green); color: #fff; font-weight: 900; font-size: 14.5px; letter-spacing: .02em; display: inline-flex; align-items: center; justify-content: center; box-shadow: 0 3px 0 var(--green-lip); padding: 0; transition: transform .08s, box-shadow .08s; }
.acct-btn:active { transform: translateY(3px); box-shadow: 0 0 0 var(--green-lip); }
.acct-btn.lg { width: 44px; height: 44px; font-size: 16px; box-shadow: none; flex: 0 0 auto; }
.acct-menu { position: fixed; z-index: 90; width: min(292px, calc(100vw - 24px)); background: #fff; border: 2px solid var(--line); border-radius: 18px; box-shadow: var(--sh-3); padding: 8px; animation: popIn .2s var(--ease) both; }
.acct-who { display: flex; gap: 12px; align-items: center; padding: 8px 8px 12px; border-bottom: 2px solid var(--line); margin-bottom: 6px; }
.acct-who > div { min-width: 0; }
.acct-who b { display: block; font-size: 15.5px; overflow-wrap: anywhere; }
.acct-who span { display: block; font-size: 13px; color: var(--ink-3); overflow-wrap: anywhere; }
.acct-menu [role=menuitem] { display: flex; align-items: center; gap: 12px; width: 100%; padding: 10px; border: 0; background: transparent; border-radius: 12px; font-weight: 800; color: var(--ink-2); text-align: left; }
.acct-menu [role=menuitem] .ic { color: var(--ink-3); }
.acct-menu [role=menuitem]:hover, .acct-menu [role=menuitem]:focus-visible { background: var(--surface-3); color: var(--ink); outline: none; }
.acct-menu [role=menuitem].danger, .acct-menu [role=menuitem].danger .ic { color: var(--red-ink); }
.save-chip.warn { color: var(--mustard-ink); }
.save-chip.warn .ic { color: var(--mustard); }
.modal.auth-modal { width: min(520px, 100%); }
.pw-wrap { position: relative; }
.pw-wrap .input { padding-right: 50px; }
.pw-wrap .icon-btn { position: absolute; right: 6px; top: 50%; transform: translateY(-50%); }
.auth-switch { text-align: center; color: var(--ink-3); font-size: 14.5px; }
.auth-emp { text-align: center; margin-top: -6px; }
.auth-emp a { font-weight: 800; }

.switch { appearance: none; -webkit-appearance: none; width: 52px; height: 30px; border-radius: 999px; background: var(--line-3); position: relative; flex: 0 0 auto; cursor: pointer; transition: background .2s; margin: 0; border: 0; }
.switch::after { content: ""; position: absolute; top: 3px; left: 3px; width: 24px; height: 24px; border-radius: 50%; background: #fff; box-shadow: 0 2px 4px rgba(30,36,66,.22); transition: transform .2s var(--ease); }
.switch:checked { background: var(--green); }
.switch:checked::after { transform: translateX(22px); }
.switch-row { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 14px 16px; border: 2px solid var(--line); border-radius: 16px; cursor: pointer; }
.switch-row > span { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.switch-row.compact { border: 0; padding: 0; justify-content: flex-start; gap: 12px; }

.page.jobs { max-width: 1400px; }
.jb-invite { display: grid; grid-template-columns: 140px minmax(0, 1fr); gap: 22px; align-items: center; padding: 18px 22px; margin-bottom: 18px; background: var(--lav-3); border-color: var(--lav-line); }
.jb-invite .rz-stage { width: 140px; }
.jb-invite h2 { font-size: 22px; }
.jb-invite p { color: var(--ink-2); margin: 6px 0 14px; max-width: 64ch; }
.jb-profile { display: flex; align-items: center; gap: 14px 22px; flex-wrap: wrap; padding: 14px 18px; margin-bottom: 18px; }
.jb-profile .switch-row b { font-size: 15px; }
.jb-facts { display: flex; flex-wrap: wrap; gap: 8px 18px; flex: 1 1 260px; color: var(--ink-2); font-weight: 700; font-size: 14px; }
.jb-facts > span { display: inline-flex; align-items: center; gap: 6px; }
.jb-facts .ic { width: 17px; height: 17px; color: var(--lav-deep); }
.jb-warn { margin-bottom: 14px; align-items: center; flex-wrap: wrap; }
.jb-warn > div { flex: 1 1 240px; }
.jb-tabs { margin-bottom: 14px; max-width: 100%; overflow-x: auto; scrollbar-width: none; }
.jb-tabs::-webkit-scrollbar { display: none; }
.jb-tabs button { display: inline-flex; align-items: center; gap: 7px; white-space: nowrap; }
.jb-n:empty { display: none; }
.jb-n { min-width: 22px; height: 20px; padding: 0 6px; border-radius: 999px; background: var(--lav-2); color: var(--lav-ink); font-size: 12px; display: inline-flex; align-items: center; justify-content: center; }
.jb-filters { position: relative; display: flex; flex-direction: column; gap: 10px; margin-bottom: 16px; }
/* the filters read like chips: each as wide as its label, "City ▾", "Pune +1 ▾" */
.jb-chips { position: relative; display: flex; flex-wrap: wrap; align-items: center; gap: 8px; }
.jb-chips > .select { flex: 0 0 auto; width: auto; min-width: 0; }
.jb-clearall { flex: 0 0 auto; padding: 0 6px; }
.jb-search { position: relative; display: block; min-width: 0; }
.jb-search .ic { position: absolute; left: 14px; top: 50%; transform: translateY(-50%); color: var(--ink-3); width: 18px; height: 18px; pointer-events: none; }
.jb-search .input { padding-left: 42px; width: 100%; }

.jb-note { display: flex; align-items: center; gap: 8px; color: var(--ink-3); font-size: 13.5px; font-weight: 700; margin-bottom: 10px; }
.jb-note .ic { width: 16px; height: 16px; color: var(--lav-deep); }
#jb-list.loading { opacity: .55; pointer-events: none; transition: opacity .15s; }

.job-list { display: flex; flex-direction: column; gap: 12px; }
.job-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 14px; align-items: stretch; }
@container view (max-width: 1240px) { .job-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
@container view (max-width: 940px) { .job-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@container view (max-width: 600px) { .job-grid { grid-template-columns: minmax(0, 1fr); gap: 12px; } }
.job-grid .job { grid-template-columns: 52px minmax(0, 1fr) auto; grid-template-rows: auto 1fr; grid-template-areas: "logo pct save" "main main main"; gap: 12px 10px; padding: 16px 14px 16px 16px; height: 100%; }
.job-grid .job-logo { grid-area: logo; width: 52px; height: 52px; border-radius: 15px; }
.job-grid .job-pct, .job-grid .job-pct-none { grid-area: pct; position: static; transform: none; align-self: center; justify-self: start; border: 0; }
.job-grid .job-save { grid-area: save; margin: -4px -4px 0 0; }
.job-grid .job-main { grid-area: main; display: flex; flex-direction: column; min-width: 0; }
.job-grid .job h3 { font-size: 16.5px; line-height: 1.3; }
.job-grid .job-facts { flex-direction: column; gap: 5px; margin-top: 10px; }
.job-grid .job-tags { margin-top: auto; padding-top: 12px; }
.job-grid .job.app { grid-template-areas: "logo pct save" "main main main" "acts acts acts"; grid-template-rows: auto 1fr auto; }
.job-grid .job.app .app-acts { grid-area: acts; flex-direction: row; flex-wrap: wrap; }
.job-grid .job.app .app-acts .btn { flex: 1 1 auto; justify-content: center; }
.job-grid .app-date { margin-top: 8px; font-size: 12.5px; }
.job-grid .job.skel { min-height: 230px; }
.job-grid .job.skel .job-main { padding-top: 6px; }
.job { display: grid; grid-template-columns: 60px minmax(0, 1fr) auto; gap: 16px; align-items: start; padding: 16px 14px 16px 18px; background: #fff; border: 2px solid var(--line); border-radius: 20px; box-shadow: 0 3px 0 var(--line); cursor: pointer; transition: border-color .15s, transform .08s, box-shadow .08s; }
.job:hover { border-color: var(--line-3); }
.job:active { transform: translateY(2px); box-shadow: 0 1px 0 var(--line); }
.job.app, .job.skel { cursor: default; }
.job.app:active, .job.skel:active { transform: none; box-shadow: 0 3px 0 var(--line); }
.job-main { min-width: 0; }
.job h3 { font-size: 17px; font-weight: 900; line-height: 1.25; overflow-wrap: anywhere; }
.job-co { color: var(--ink-2); font-weight: 700; margin-top: 3px; overflow-wrap: anywhere; }
.job-facts { display: flex; flex-wrap: wrap; gap: 6px 16px; margin-top: 10px; font-size: 13.5px; color: var(--ink-2); font-weight: 700; }
.job-facts > span { display: inline-flex; align-items: center; gap: 6px; min-width: 0; overflow-wrap: anywhere; }
.job-facts .ic { width: 16px; height: 16px; color: var(--ink-3); }
.job-facts.lg { font-size: 14.5px; gap: 8px 20px; margin-top: 0; }
.job-tags { display: flex; flex-wrap: wrap; gap: 6px 8px; margin-top: 10px; align-items: center; }
.tag.blue { background: var(--blue-2); color: #234b8f; }
.job-logo { position: relative; width: 56px; height: 56px; border-radius: 16px; background: #fff; box-shadow: inset 0 0 0 1.5px var(--line); color: var(--lav-ink); display: flex; align-items: center; justify-content: center; font-weight: 900; font-size: 18px; flex: 0 0 auto; align-self: start; }
.job-logo img { width: 100%; height: 100%; object-fit: contain; border-radius: inherit; display: block; }
.job-logo.fb { background: var(--lav-2); box-shadow: none; }
.job-logo.lg { width: 60px; height: 60px; font-size: 20px; }
/* the match score sits on the company logo */
.job-pct { height: 26px; padding: 0 10px; border-radius: 999px; display: inline-flex; align-items: center; gap: 4px; white-space: nowrap; font-size: 11.5px; font-weight: 800; letter-spacing: .01em; line-height: 1; }
.job-pct-none { display: block; }
.job-pct b { font-size: 13px; font-weight: 900; }
.job-pct.hi { background: var(--green); color: #fff; }
.job-pct.mid { background: var(--mustard); color: #2a1a02; }
.job-pct.lo { background: var(--surface-3); color: var(--ink-2); }
.job-match { width: 60px; height: 60px; border-radius: 18px; display: flex; flex-direction: column; align-items: center; justify-content: center; line-height: 1; border: 2px solid; flex: 0 0 auto; }
.job-match b { font-size: 18px; font-weight: 900; }
.job-match span { font-size: 10px; font-weight: 800; text-transform: uppercase; letter-spacing: .07em; margin-top: 3px; }
.job-match.hi { background: var(--green-2); color: var(--green-ink); border-color: var(--green-line); }
.job-match.mid { background: var(--mustard-2); color: var(--mustard-ink); border-color: var(--mustard-line); }
.job-match.lo { background: var(--surface-2); color: var(--ink-3); border-color: var(--line-2); }
.job-save { margin: -6px -4px 0 0; }
.job-save.on { color: var(--green); }
.job.skel .job-logo, .job.skel i { background: var(--surface-3); animation: skel 1.1s ease-in-out infinite alternate; }
.job.skel i { display: block; height: 13px; border-radius: 7px; margin: 5px 0 11px; }
@keyframes skel { from { opacity: .5; } to { opacity: 1; } }
.job-list.mini { gap: 8px; margin-top: 12px; }
.job-list.mini .job { grid-template-columns: 50px minmax(0, 1fr) auto; gap: 12px; padding: 12px 10px 12px 12px; box-shadow: none; border-radius: 16px; }
.job-list.mini .job-match, .job-list.mini .job-logo { width: 50px; height: 50px; border-radius: 14px; }
.job-list.mini .job { grid-template-areas: "logo main save" "pct main save"; grid-template-rows: auto 1fr; row-gap: 6px; }
.job-list.mini .job-logo { grid-area: logo; } .job-list.mini .job-main { grid-area: main; } .job-list.mini .job-save { grid-area: save; }
.job-list.mini .job-pct, .job-list.mini .job-pct-none { grid-area: pct; justify-self: center; align-self: start; }
.job-list.mini .job-pct { height: 20px; padding: 0 6px; font-size: 0; gap: 0; }
.job-list.mini .job-pct b { font-size: 11.5px; }
.job-list.mini .job-match b { font-size: 15px; }
.job-list.mini .job-match span { font-size: 9px; }
.job-list.mini h3 { font-size: 15.5px; }
.job-list.mini .job-facts { margin-top: 6px; font-size: 13px; }
.job-list.mini .job-facts > span:nth-child(n+3), .job-list.mini .job-tags { display: none; }
.job.app { grid-template-columns: 56px minmax(0, 1fr) auto; }
.app-acts { display: flex; flex-direction: column; gap: 8px; align-items: stretch; }
.app-date { font-size: 13px; font-weight: 700; }
.app-note { display: flex; gap: 8px; align-items: center; margin-top: 10px; padding: 8px 12px; border-radius: 12px; background: var(--blue-2); color: #234b8f; font-size: 13.5px; font-weight: 700; }
.app-note.ok { background: var(--green-2); color: var(--green-ink); }
.app-note .ic { width: 16px; height: 16px; }

.pager { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; margin-top: 18px; }
.pager-count { color: var(--ink-3); font-weight: 800; font-size: 14px; }
.pager-btns { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; }
.pager-n { min-width: 40px; height: 40px; border-radius: 12px; border: 2px solid transparent; background: transparent; font-weight: 800; color: var(--ink-2); padding: 0 8px; }
.pager-n:hover { background: var(--surface-3); }
.pager-n.on { background: var(--lav-2); border-color: var(--lav-line); color: var(--lav-ink); }
.pager-gap { color: var(--ink-4); padding: 0 2px; font-weight: 800; }

.modal.job-modal .modal-head h2 { font-size: 22px; }
.jd { display: flex; flex-direction: column; gap: 18px; }
.jd-co { display: flex; align-items: center; gap: 14px; flex-wrap: wrap; }
.jd-co > div:not(.job-logo) { flex: 1 1 200px; min-width: 0; }
.jd-co b { display: block; font-size: 16.5px; }
.jd-co span { display: inline-flex; align-items: center; gap: 5px; color: var(--ink-3); font-size: 14px; }
.jd-co span .ic { width: 15px; height: 15px; }
.jd h3 { font-size: 16px; margin-bottom: 8px; }
.jd-desc { color: var(--ink-2); white-space: pre-line; font-size: 15px; line-height: 1.6; overflow-wrap: anywhere; }
.jd-why { padding: 16px; border-radius: 18px; background: var(--lav-3); border: 2px solid var(--lav-line); }
.jd-why-head { display: flex; align-items: center; gap: 14px; margin-bottom: 12px; }
.jd-why-head b { display: block; font-size: 17px; }
.jd-why-head span { color: var(--ink-3); font-size: 13.5px; }
.jd-why ul { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 8px; }
.jd-why li { display: flex; gap: 10px; align-items: flex-start; font-size: 14.5px; font-weight: 700; color: var(--ink-2); }
.jd-why li .ic { width: 18px; height: 18px; margin-top: 1px; flex: 0 0 auto; }
.jd-why li.ok .ic { color: var(--green); }
.jd-why li.no .ic { color: var(--ink-4); }
.jd-why .hint { margin-top: 10px; }
.jd-sim { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
.jd-sim-item { display: flex; flex-direction: column; gap: 2px; text-align: left; padding: 12px 14px; border: 2px solid var(--line); border-radius: 14px; background: #fff; min-width: 0; }
.jd-sim-item:hover { border-color: var(--line-3); }
.jd-sim-item b { font-size: 14.5px; overflow-wrap: anywhere; }
.jd-sim-item span { font-size: 13px; color: var(--ink-2); overflow-wrap: anywhere; }
.jd-status { font-size: 13.5px; padding: 9px 14px; }
.jd-save.on { --b-bg: var(--green-2); --b-fg: var(--green-ink); --b-bd: var(--green-line); --b-lip: var(--green-line); }
.apply { display: grid; grid-template-columns: minmax(0, 250px) minmax(0, 1fr); gap: 22px; align-items: start; }
.apply-prev { border-radius: 12px; border: 2px solid var(--line); overflow: hidden; max-height: 380px; overflow-y: auto; }

@media (max-width: 860px) {
  .jb-chips { flex-wrap: nowrap; overflow-x: auto; scrollbar-width: none; padding: 2px 0 4px; }
  .jb-chips::-webkit-scrollbar { display: none; }
  .jb-invite { grid-template-columns: 96px minmax(0, 1fr); gap: 16px; padding: 16px; }
  .jb-invite .rz-stage { width: 96px; border-radius: 20px; }
  .jb-invite h2 { font-size: 19px; }
}
@media (max-width: 560px) {
  .topbar-actions { gap: 8px; }
  .acct-btn { width: 36px; height: 36px; font-size: 13.5px; }
  .job { grid-template-columns: 50px minmax(0, 1fr) auto; gap: 12px; padding: 14px 10px 14px 14px; }
  .job-match, .job-logo { width: 50px; height: 50px; border-radius: 14px; }
  .job-match b { font-size: 15px; }
  .job-match span { font-size: 9px; }
  .job h3 { font-size: 16px; }
  .job.app { grid-template-columns: 50px minmax(0, 1fr); }
  .job-pct { font-size: 0; gap: 0; padding: 0 7px; }
  .job-pct b { font-size: 12px; }
  .app-acts { grid-column: 1 / -1; flex-direction: row; }
  .app-acts .btn { flex: 1 1 auto; }
  .jb-invite { grid-template-columns: minmax(0, 1fr); }
  .jb-invite .rz-stage { display: none; }
  .jb-profile { padding: 14px; }
  .jb-profile .btn { width: 100%; }
  .jd-sim { grid-template-columns: minmax(0, 1fr); }
  .pager { justify-content: center; }
  .pager-btns .lbl { display: none; }
  .modal.job-modal .modal-foot .spacer { display: none; }
  .modal.job-modal .modal-foot > .btn, .modal.job-modal .modal-foot > a.btn { flex: 1 1 auto; }
  .apply { grid-template-columns: minmax(0, 1fr); }
}

/* =========================================================================
   LEFT PANEL — modelled on the Ezygo dashboard: a 256px drawer on the page
   background with pill items and tinted groups; by default it rests as a 72px
   rail (the tints stay as pills) and opens OVER the page on hover. The menu
   button pins it open. Phones: off-canvas drawer + bottom bar with "More".
   ======================================================================= */
:root { --drawer-w: 256px; --rail-w: 72px; --sh-e1: 0 1px 2px rgba(30,36,66,.22), 0 1px 3px 1px rgba(30,36,66,.10); --sh-e2: 0 1px 2px rgba(30,36,66,.24), 0 2px 6px 2px rgba(30,36,66,.12); }
.topbar { padding: 0 16px 0 8px; gap: 8px; background: rgba(248,247,253,.92); border-bottom: 0; transition: box-shadow .2s; }
.topbar.scrolled { box-shadow: 0 1px 0 var(--line), 0 8px 20px rgba(30,36,66,.05); }
.tb-menu { width: 48px; height: 48px; border-radius: 50%; color: var(--ink-2); }
.tb-menu:hover { background: rgba(30,36,66,.07); }
.tb-menu .ic { width: 22px; height: 22px; }
.shell-body { display: flex; align-items: flex-start; flex: 1 1 auto; min-width: 0; }
.drawer-space { flex: 0 0 var(--drawer-w); align-self: stretch; transition: flex-basis .22s var(--ease); }
.drawer { position: fixed; z-index: 55; top: var(--top-h); bottom: 0; left: 0; width: var(--drawer-w); display: flex; flex-direction: column; padding: 6px 8px 10px; background: var(--bg); overflow: hidden; transition: width .22s var(--ease), box-shadow .22s var(--ease); }
.drawer-head { display: none; }
.drawer-scroll { flex: 1 1 auto; min-height: 0; overflow-y: auto; overflow-x: hidden; scrollbar-width: thin; }
.drawer-nav { display: flex; flex-direction: column; gap: 2px; padding: 2px 0 8px; }
.dnav-item { display: flex; align-items: center; gap: 14px; width: 100%; height: 42px; padding: 0 12px 0 14px; border: 0; border-radius: 21px; background: transparent; color: var(--ink-2); font-weight: 700; font-size: 15px; text-align: left; white-space: nowrap; transition: background .15s, color .15s; }
.dnav-item .ic { width: 22px; height: 22px; flex: 0 0 auto; color: var(--ink-2); }
.dnav-item:hover { background: rgba(30,36,66,.06); }
.dnav-item.on { background: var(--green-2); color: var(--green-ink); font-weight: 800; }
.dnav-item.on .ic { color: var(--green); }
.dnav-l { overflow: hidden; text-overflow: ellipsis; }
.dnav-n { margin-left: auto; font-size: 12.5px; font-weight: 800; color: var(--ink-3); }
.dnav-n:empty { display: none; }
.navsec { background: var(--sbg); border-radius: 16px; padding: 4px 6px 8px; margin: 8px 4px; }
.navsec-h { font-size: 11px; font-weight: 900; letter-spacing: .08em; text-transform: uppercase; color: var(--sfg); padding: 8px 10px 4px; white-space: nowrap; }
.navsec .dnav-item { color: var(--ink); }
.navsec .dnav-item:hover { background: rgba(255,255,255,.62); }
.navsec .dnav-item.on { background: #fff; color: var(--ink); box-shadow: 0 1px 2px rgba(30,36,66,.14); }
.navsec .dnav-item.on .ic { color: var(--sfg); }
.navsec .dnav-item.on .dnav-n { color: var(--sfg); }
.drawer-note { margin: 6px 8px 4px; padding: 12px 14px; border-radius: 16px; background: #fff; border: 2px solid var(--line); color: var(--ink-3); font-size: 13px; line-height: 1.45; }
.drawer-note b { display: block; color: var(--ink); font-size: 14px; margin-bottom: 2px; }
.drawer-note .link-btn { padding: 4px 0 0; font-size: 13.5px; }
.drawer-act-wrap { flex: none; padding: 10px 0 4px 4px; }
.drawer-act { display: inline-flex; align-items: center; gap: 12px; height: 56px; max-width: 100%; padding: 0 20px 0 16px; border: 0; border-radius: 16px; background: #fff; box-shadow: var(--sh-e1); color: var(--ink); font-weight: 800; font-size: 15px; white-space: nowrap; text-decoration: none; transition: box-shadow .2s var(--ease), padding .22s var(--ease), width .22s var(--ease); }
.drawer-act:hover { box-shadow: var(--sh-e2); }
.drawer-act .ic { width: 24px; height: 24px; color: var(--green); }
.drawer-act .dot { width: 12px; height: 12px; border-radius: 50%; background: var(--green); box-shadow: 0 0 0 5px var(--green-2); flex: 0 0 auto; margin: 0 4px 0 6px; }
.drawer-act .dot.off { background: var(--ink-4); box-shadow: 0 0 0 5px var(--surface-3); }
.drawer-scrim { position: fixed; inset: 0; z-index: 115; background: rgba(24,28,52,.42); animation: fadeIn .2s both; }

@media (min-width: 861px) {
  .shell.rail .drawer-space { flex-basis: var(--rail-w); }
  .shell.rail .drawer { border-radius: 0 18px 18px 0; }
  .shell.rail .drawer:hover, .shell.rail .drawer:has(:focus-visible) { width: var(--drawer-w); box-shadow: var(--sh-e2); }
  .shell.rail .drawer:not(:hover):not(:has(:focus-visible)) { width: var(--rail-w); }
  .shell.rail .drawer:not(:hover):not(:has(:focus-visible)) .navsec { width: 52px; padding: 6px 0; margin: 10px auto; border-radius: 22px; }
  .shell.rail .drawer:not(:hover):not(:has(:focus-visible)) .navsec-h,
  .shell.rail .drawer:not(:hover):not(:has(:focus-visible)) .dnav-l,
  .shell.rail .drawer:not(:hover):not(:has(:focus-visible)) .dnav-n,
  .shell.rail .drawer:not(:hover):not(:has(:focus-visible)) .drawer-note { display: none; }
  .shell.rail .drawer:not(:hover):not(:has(:focus-visible)) .dnav-item { justify-content: center; width: 40px; height: 40px; padding: 0; margin: 0 auto; border-radius: 50%; }
  .shell.rail .drawer:not(:hover):not(:has(:focus-visible)) .drawer-act-wrap { padding-left: 0; display: flex; justify-content: center; }
  .shell.rail .drawer:not(:hover):not(:has(:focus-visible)) .drawer-act { width: 48px; height: 48px; padding: 0; justify-content: center; }
  .shell.rail .drawer:not(:hover):not(:has(:focus-visible)) .drawer-act .dot { margin: 0; }
}
@media (max-width: 860px) {
  .drawer-space { display: none; }
  .drawer { top: 0; z-index: 120; width: min(286px, 84vw); padding: calc(12px + env(safe-area-inset-top, 0px)) 10px 14px; border-radius: 0 18px 18px 0; box-shadow: var(--sh-e2); transform: translateX(-104%); transition: transform .24s var(--ease); }
  .shell.drawer-open .drawer { transform: none; }
  .drawer-head { display: flex; align-items: center; justify-content: space-between; padding: 0 0 6px 8px; }
  .drawer-head .brand-word { font-size: 24px; }
  .topbar { padding: 0 12px 0 4px; gap: 4px; }
}
@media (max-width: 560px) {
  .topbar .brand-av { display: none; }
  .tb-menu { width: 44px; height: 44px; }
}
@media (min-width: 861px) { .topbar { padding-left: 12px; } }   /* the menu button sits right above the rail icons */
/* touch screens keep a hover look after a tap; only real pointers get hover styles here */
@media (hover: none) {
  .nav-item:hover { background: transparent; color: var(--ink-2); }
  .nav-item.on:hover { background: var(--lav-2); color: var(--lav-ink); }
  .dnav-item:hover { background: transparent; }
  .navsec .dnav-item:hover { background: transparent; }
  .dnav-item.on:hover { background: var(--green-2); }
  .navsec .dnav-item.on:hover { background: #fff; }
}

.drawer-emp { display: flex; align-items: center; gap: 12px; margin: 10px 4px 4px; padding: 11px 14px; border-radius: 16px; background: #e7eaf4; color: #2e395f; font-size: 14px; font-weight: 700; text-decoration: none; white-space: nowrap; }
.drawer-emp .ic { width: 20px; height: 20px; flex: 0 0 auto; }
.drawer-emp b { font-weight: 900; }
.drawer-emp:hover { background: #dde2f0; }
@media (min-width: 861px) {
  .shell.rail .drawer:not(:hover):not(:has(:focus-visible)) .drawer-emp { width: 44px; height: 44px; padding: 0; margin: 10px auto 4px; justify-content: center; border-radius: 50%; }
}

.jb-bar { display: flex; align-items: center; justify-content: space-between; gap: 10px 14px; flex-wrap: wrap; margin-bottom: 14px; }
.jb-bar .jb-tabs { margin-bottom: 0; }
.jb-view button { display: inline-flex; align-items: center; gap: 6px; }
.jb-view .ic { width: 18px; height: 18px; }
@media (max-width: 560px) { .jb-bar .jb-tabs { flex: 1 1 100%; } .jb-view { margin-left: auto; } }

.rz-menu { width: auto; min-width: 210px; max-width: min(300px, calc(100vw - 16px)); }
.rz-menu [role=menuitem][disabled] { opacity: .45; cursor: default; }
.rz-menu-sep { height: 2px; background: var(--line); margin: 4px 6px; }

/* ---------- My résumés: saved résumés and cover letters ---------- */
.dc-tabs { margin-top: 18px; }
.dc-list { margin-top: 18px; }
.dc-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(232px, 1fr)); gap: 16px; }
.dc-card { position: relative; display: flex; flex-direction: column; min-width: 0; background: var(--surface); border: 2px solid var(--line); border-radius: var(--r-lg); box-shadow: 0 3px 0 var(--line); overflow: hidden; }
.dc-card.active { border-color: var(--lav-line); box-shadow: 0 3px 0 var(--lav-line); }
.dc-thumb { display: block; width: 100%; padding: 14px 16px 0; margin: 0; background: var(--surface-2); border: 0; cursor: pointer; }
.dc-thumb [data-paper] { aspect-ratio: 210 / 228; border-radius: 10px 10px 0 0; }
.dc-thumb:hover [data-paper] .paper { box-shadow: 0 1px 2px rgba(30,36,66,.1), 0 10px 26px rgba(30,36,66,.14); }
.dc-thumb:focus-visible { outline: 3px solid var(--lav-deep); outline-offset: -3px; }
.dc-info { padding: 12px 14px 2px; min-width: 0; }
.dc-title { font-weight: 900; font-size: 15.5px; line-height: 1.3; overflow-wrap: anywhere; }
.dc-tags { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 8px; margin-top: 6px; font-size: 12.5px; font-weight: 700; }
.dc-acts { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; padding: 10px 12px 12px; margin-top: auto; }
.dc-acts .spacer { flex: 1 1 auto; }
.dc-new { align-items: center; justify-content: center; gap: 8px; min-height: 300px; padding: 26px 18px; text-align: center; background: var(--surface-2); border-style: dashed; border-color: var(--line-2); box-shadow: none; cursor: pointer; font: inherit; color: var(--ink); }
.dc-new:hover { background: var(--green-2); border-color: var(--green-line); }
.dc-new:focus-visible { outline: 3px solid var(--lav-deep); outline-offset: 2px; }
.dc-plus { width: 54px; height: 54px; border-radius: 16px; display: flex; align-items: center; justify-content: center; background: var(--surface); color: var(--green); box-shadow: 0 2px 0 var(--line); }
.dc-plus .ic { width: 24px; height: 24px; }
.dc-new b { font-size: 16px; font-weight: 900; }
.dc-new > span:last-child { max-width: 220px; font-size: 13px; font-weight: 700; color: var(--ink-3); line-height: 1.4; }
.dc-card.skel .dc-thumb { height: 236px; background: var(--surface-3); animation: skel 1.1s ease-in-out infinite alternate; }
.dc-card.skel i { display: block; height: 12px; border-radius: 6px; margin: 6px 0 12px; background: var(--surface-3); animation: skel 1.1s ease-in-out infinite alternate; }
.dc-card.skel i:first-child { width: 70%; } .dc-card.skel i:last-child { width: 45%; }
.ex-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(190px, 1fr)); gap: 12px; }
.ex-grid .choice { padding: 14px 14px 12px; }
.ex-grid .choice h4 { font-size: 15px; }
.ex-grid .choice p { font-size: 12.5px; }
/* the cover letter editor: fields on the left, the letter in the résumé's design on the right */
.le-grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 430px); gap: 20px; align-items: start; margin-top: 18px; }
.le-prev { position: sticky; top: 16px; min-width: 0; }
.le-para { display: flex; align-items: flex-start; gap: 8px; }
.le-para .textarea { flex: 1 1 auto; min-width: 0; min-height: 96px; }
@media (max-width: 960px) { .le-grid { grid-template-columns: minmax(0, 1fr); } .le-prev { position: static; } }
@media (max-width: 600px) { .dc-grid { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 10px; } .dc-thumb { padding: 10px 10px 0; } .dc-acts .btn { flex: 1 1 100%; justify-content: center; } .dc-new { min-height: 220px; } }
@media (max-width: 380px) { .dc-grid { grid-template-columns: minmax(0, 1fr); } }

/* ---------- Apply with Rozzo ---------- */
.page.apply-pg { max-width: 1180px; }
.ap-head { display: flex; align-items: center; gap: 14px; margin: 10px 0 16px; }
.ap-head .job-logo { width: 60px; height: 60px; }
.ap-title h1 { font-size: 26px; line-height: 1.2; }
.ap-title p { color: var(--ink-2); font-weight: 700; margin-top: 4px; }
.ap-steps { display: flex; flex-wrap: wrap; gap: 8px; list-style: none; margin: 0 0 18px; padding: 0; }
.ap-steps li { display: inline-flex; align-items: center; gap: 8px; height: 36px; padding: 0 14px 0 6px; border-radius: 999px; background: var(--surface-2); color: var(--ink-3); font-weight: 800; font-size: 14px; }
.ap-steps li span { width: 26px; height: 26px; border-radius: 50%; display: flex; align-items: center; justify-content: center; background: var(--surface); font-size: 13px; }
.ap-steps li.on { background: var(--lav-2); color: var(--lav-ink); }
.ap-steps li.on span { background: var(--lav-ink); color: #fff; }
.ap-steps li.done { background: var(--green-2); color: var(--green-ink); }
.ap-steps li.done span { background: var(--green); color: #fff; }
.ap-grid { display: grid; grid-template-columns: minmax(0, 300px) minmax(0, 1fr); gap: 22px; align-items: start; }
.ap-rozzo { position: sticky; top: 16px; display: flex; flex-direction: column; gap: 14px; }
.ap-stage { width: 100%; aspect-ratio: 1 / 1.15; border-radius: 28px; overflow: hidden; background: var(--lav-2); }
.ap-bubble { font-weight: 800; font-size: 16px; line-height: 1.45; }
.ap-body { min-width: 0; }
.ap-body.enter { animation: viewIn .3s var(--ease) backwards; }
.ap-h { font-size: 20px; margin-bottom: 14px; }
.ap-choices { display: grid; gap: 10px; }
.ap-choice { display: flex; align-items: flex-start; gap: 12px; padding: 14px 16px; border: 2px solid var(--line); border-radius: 18px; background: var(--surface); cursor: pointer; }
.ap-choice:has(input:checked) { border-color: var(--lav-deep); background: var(--lav-3); }
.ap-choice input { margin-top: 12px; accent-color: var(--lav-ink); width: 18px; height: 18px; flex: 0 0 auto; }
.ap-choice .c-ic { width: 42px; height: 42px; border-radius: 12px; display: flex; align-items: center; justify-content: center; background: var(--lav-2); color: var(--lav-ink); flex: 0 0 auto; }
.ap-choice .c-t { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.ap-choice .c-t b { font-size: 16px; }
.ap-choice .c-t span { color: var(--ink-3); font-weight: 700; font-size: 13.5px; }
.ap-pick { margin-top: 14px; }
.ap-drop { display: flex; flex-direction: column; align-items: center; gap: 6px; margin-top: 14px; padding: 26px 18px; border: 2px dashed var(--line-3); border-radius: 18px; background: var(--surface-2); text-align: center; cursor: pointer; color: var(--ink-2); }
.ap-drop:hover { border-color: var(--lav-deep); background: var(--lav-3); }
.ap-drop .ic { width: 28px; height: 28px; color: var(--lav-ink); }
.ap-drop span { font-size: 13px; font-weight: 700; color: var(--ink-3); }
.ap-err { margin-top: 10px; color: var(--red-ink); font-weight: 700; font-size: 14px; }
.ap-foot { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; margin-top: 20px; padding-top: 16px; border-top: 2px solid var(--line); }
.ap-fit { display: flex; align-items: center; gap: 18px; padding: 14px; border-radius: 18px; background: var(--surface-2); margin-bottom: 14px; }
.ap-ring { --c: var(--ink-3); flex: 0 0 auto; width: 92px; height: 92px; border-radius: 50%; display: flex; flex-direction: column; align-items: center; justify-content: center; background: radial-gradient(closest-side, var(--surface) 78%, transparent 80% 100%), conic-gradient(var(--c) calc(var(--p) * 1%), var(--line) 0); }
.ap-ring.hi { --c: var(--green); } .ap-ring.mid { --c: var(--mustard); }
.ap-ring b { font-size: 22px; font-weight: 900; line-height: 1; } .ap-ring span { font-size: 12px; font-weight: 800; color: var(--ink-3); }
.ap-fit-t { display: grid; gap: 6px; font-weight: 700; font-size: 14px; color: var(--ink-2); min-width: 0; }
.ap-fit-t .ic { width: 16px; height: 16px; vertical-align: -3px; color: var(--green); }
.ap-sug { padding: 14px 0; border-top: 2px solid var(--line); }
.ap-sug h3 { font-size: 16px; } .ap-sug p { color: var(--ink-2); font-size: 14px; font-weight: 600; margin: 4px 0 10px; line-height: 1.5; }
.ap-sug.warn h3 { color: var(--red-ink); }
.ap-chip { cursor: pointer; border: 2px solid var(--line); background: var(--surface); }
.ap-chip.on { background: var(--green-2); color: var(--green-ink); border-color: var(--green-line); }
.ap-copy { border: 0; padding: 14px 0 0; margin: 0; border-top: 2px solid var(--line); display: grid; gap: 8px; font-weight: 700; font-size: 14px; }
.ap-copy legend { font-weight: 900; font-size: 16px; padding: 0; margin-bottom: 6px; }
.ap-copy input { accent-color: var(--lav-ink); margin-right: 6px; }
.ap-wait { display: flex; align-items: center; gap: 10px; padding: 30px 0; font-weight: 800; color: var(--ink-2); }
.ap-send { display: grid; grid-template-columns: minmax(0, 220px) minmax(0, 1fr); gap: 18px; align-items: start; }
.ap-paper [data-ap-paper] { aspect-ratio: 210 / 297; border-radius: 12px; }
.ap-sum-row { display: flex; gap: 10px; align-items: flex-start; padding: 12px; border-radius: 14px; background: var(--surface-2); }
.ap-sum-row .ic { width: 20px; height: 20px; color: var(--lav-ink); flex: 0 0 auto; margin-top: 2px; }
.ap-sum-row b { display: block; } .ap-sum-row span { display: block; color: var(--ink-3); font-size: 13px; font-weight: 700; margin-top: 2px; overflow-wrap: anywhere; }
.ap-done { display: flex; flex-direction: column; align-items: center; text-align: center; gap: 10px; padding: 24px 10px; }
.ap-done > .ic { width: 54px; height: 54px; padding: 12px; border-radius: 50%; background: var(--green-2); color: var(--green); }
.ap-done p { color: var(--ink-2); font-weight: 700; max-width: 44ch; }
.ap-pill { position: fixed; left: 50%; bottom: calc(18px + env(safe-area-inset-bottom, 0px)); transform: translateX(-50%); z-index: 95; display: flex; align-items: center; gap: 4px; max-width: calc(100vw - 24px); padding: 4px 4px 4px 4px; border-radius: 999px; background: var(--navy); color: #fff; box-shadow: var(--sh-3); }
.ap-pill-go { display: inline-flex; align-items: center; gap: 8px; min-width: 0; padding: 8px 12px; border: 0; background: none; color: inherit; font: inherit; font-weight: 700; cursor: pointer; }
.ap-pill-go span { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.ap-pill .icon-btn { color: #fff; }
.spin { width: 18px; height: 18px; border-radius: 50%; border: 3px solid var(--line-2); border-top-color: var(--lav-ink); animation: spin .8s linear infinite; display: inline-block; flex: 0 0 auto; }
@container view (max-width: 860px) { .ap-grid { grid-template-columns: minmax(0, 1fr); } .ap-rozzo { position: static; flex-direction: row; align-items: center; } .ap-stage { width: 96px; flex: 0 0 96px; border-radius: 20px; } .ap-bubble { font-size: 15px; } .ap-send { grid-template-columns: minmax(0, 1fr); } .ap-paper { max-width: 240px; } }
@media (max-width: 600px) { .ap-title h1 { font-size: 21px; } .ap-steps li { height: 32px; font-size: 13px; padding-right: 10px; } .ap-steps li span { width: 22px; height: 22px; } .ap-pill { bottom: calc(76px + env(safe-area-inset-bottom, 0px)); } }

/* ---------- Coach: talk to Rozzo (the conversation itself is css/assist.css) ---------- */
.page.chat-pg { max-width: 1320px; padding-bottom: 20px; }
.chat-grid { display: grid; grid-template-columns: minmax(0, 360px) minmax(0, 1fr); gap: 24px; align-items: stretch; height: calc(100dvh - var(--top-h) - 44px); min-height: 520px; }
.chat-side { display: flex; flex-direction: column; gap: 14px; min-height: 0; }
.chat-stage { flex: 1 1 auto; min-height: 0; border-radius: 32px; overflow: hidden; background: var(--lav-2); }
.chat-stage.rz-stage { aspect-ratio: auto; width: 100%; }
.chat-who { display: flex; flex-direction: column; align-items: center; text-align: center; }
.chat-who b { font-size: 22px; font-weight: 900; }
.chat-who span { color: var(--ink-3); font-weight: 700; }
.chat-main { min-width: 0; min-height: 0; }
@container view (max-width: 980px) { .chat-grid { grid-template-columns: minmax(0, 240px) minmax(0, 1fr); gap: 16px; } }
@container view (max-width: 700px) {
  .chat-grid { grid-template-columns: minmax(0, 1fr); grid-template-rows: auto minmax(0, 1fr); height: calc(100dvh - var(--top-h) - 110px); gap: 10px; }
  .chat-side { flex-direction: row; align-items: center; gap: 12px; }
  .chat-stage { flex: 0 0 76px; height: 76px; border-radius: 22px; }
  .chat-who { align-items: flex-start; text-align: left; }
  .chat-who b { font-size: 18px; }
}

/* the "continue applying" pill steps up when the chat bar is at the bottom */
html.rzx-minibar .ap-pill { bottom: calc(76px + env(safe-area-inset-bottom, 0px)); }
@media (max-width: 600px) { html.rzx-minibar .ap-pill { bottom: calc(140px + env(safe-area-inset-bottom, 0px)); } }

/* ---------- Jobs where you'd be a top applicant ---------- */
.tp { margin-bottom: 18px; padding: 0; overflow: hidden; border-top: 4px solid var(--mustard); }
.tp-head { padding: 18px 22px 8px; }
.tp-kicker { display: inline-flex; align-items: center; gap: 6px; font-size: 13.5px; font-weight: 800; color: var(--mustard-ink); }
.tp-kicker .ic { width: 16px; height: 16px; color: var(--mustard); }
.tp-head h2 { font-size: 22px; margin-top: 4px; }
.tp-head p { color: var(--ink-3); font-weight: 700; font-size: 14px; margin-top: 2px; }
.tp-list { list-style: none; margin: 0; padding: 0 22px; }
.tp-item { display: grid; grid-template-columns: 56px minmax(0, 1fr) auto auto; gap: 14px; align-items: start; padding: 16px 0; border-top: 2px solid var(--line); }
.tp-item:first-child { border-top: 0; }
.tp-title { padding: 0; border: 0; background: none; font: inherit; font-size: 17px; font-weight: 900; color: var(--lav-ink); text-align: left; cursor: pointer; line-height: 1.3; }
.tp-title:hover { text-decoration: underline; }
.tp-co { color: var(--ink); font-weight: 700; margin-top: 2px; }
.tp-sig { display: inline-flex; align-items: center; gap: 6px; margin-top: 6px; color: var(--ink-2); font-weight: 700; font-size: 14px; }
.tp-sig .ic { width: 17px; height: 17px; color: var(--green); }
.tp-meta { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 12px; margin-top: 6px; font-size: 13.5px; font-weight: 700; color: var(--ink-3); }
.tp-early { color: var(--green-ink); }
.tp-apply { display: inline-flex; align-items: center; gap: 5px; padding: 0; border: 0; background: none; font: inherit; font-weight: 800; color: var(--lav-ink); cursor: pointer; }
.tp-apply .ic { width: 15px; height: 15px; }
.tp-apply:hover { text-decoration: underline; }
.tp-item .job-pct { align-self: start; margin-top: 2px; }
.tp-x { align-self: start; margin: -4px -6px 0 0; }
.tp-all { display: flex; align-items: center; justify-content: center; gap: 8px; width: 100%; padding: 14px; border: 0; border-top: 2px solid var(--line); background: var(--surface); font: inherit; font-weight: 900; font-size: 15px; color: var(--ink); cursor: pointer; }
.tp-all:hover { background: var(--surface-2); }
.tp-all .ic { width: 18px; height: 18px; }
@container view (max-width: 600px) { .tp-head { padding: 16px 16px 6px; } .tp-list { padding: 0 16px; } .tp-item { grid-template-columns: 48px minmax(0, 1fr) auto; } .tp-item .job-logo { width: 48px; height: 48px; } .tp-item .job-pct { grid-column: 2; grid-row: 2; justify-self: start; } .tp-x { grid-column: 3; grid-row: 1; } }

/* ---------- "update your other résumés too?" ---------- */
.sync-grid { display: grid; grid-template-columns: minmax(0, 1.3fr) minmax(0, 1fr); gap: 14px; margin-top: 14px; }
.sync-box { margin: 0; padding: 10px 14px 12px; border: 2px solid var(--line); border-radius: 16px; display: grid; gap: 8px; align-content: start; max-height: 340px; overflow: auto; }
.sync-box legend { padding: 0 6px; font-weight: 900; font-size: 15px; }
.sync-box .check { align-items: flex-start; font-size: 14px; }
@media (max-width: 640px) { .sync-grid { grid-template-columns: minmax(0, 1fr); } }

/* ---------- résumé tools: section order, checks, improve-text stepper, per-entry help ---------- */
.ord-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; }
.ord-item { display: flex; align-items: center; gap: 10px; padding: 8px 8px 8px 12px; border: 2px solid var(--line); border-radius: 14px; background: var(--surface); }
.ord-n { width: 26px; height: 26px; border-radius: 50%; display: flex; align-items: center; justify-content: center; background: var(--lav-2); color: var(--lav-ink); font-weight: 900; font-size: 13px; flex: 0 0 auto; }
.rz-flagged { outline: 3px solid var(--mustard) !important; outline-offset: 2px; border-radius: 12px; }
.rz-flag-tip { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 10px; margin: 8px 0 4px; padding: 12px 12px 12px 14px; border-radius: 14px; background: var(--mustard-2); border: 2px solid var(--mustard-line); color: var(--mustard-ink); }
.rz-flag-tip > div:first-child { display: flex; flex-direction: column; gap: 2px; min-width: 0; flex: 1 1 240px; }
.rz-flag-tip b { font-weight: 900; } .rz-flag-tip span { font-weight: 700; font-size: 14px; }
.paper-view .rs-flag { background: #fde8b3; box-shadow: 0 0 0 3px #fde8b3; border-radius: 3px; }
.chk-kinds { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 10px; }
.chk-k { display: inline-flex; align-items: center; gap: 6px; padding: 6px 12px; border-radius: 999px; background: var(--surface-2); font-weight: 700; font-size: 13.5px; color: var(--ink-2); }
.chk-k b { color: var(--mustard-ink); font-weight: 900; }
.rsn-list { display: grid; gap: 10px; }
.rsn { display: flex; gap: 12px; align-items: flex-start; padding: 12px 14px; border: 2px solid var(--line); border-radius: 16px; cursor: pointer; }
.rsn:has(input:checked) { border-color: var(--green-line); background: #f7fcf4; }
.rsn input { margin-top: 3px; width: 18px; height: 18px; accent-color: var(--green); flex: 0 0 auto; }
.rsn-b { color: var(--ink-3); text-decoration: line-through; text-decoration-color: var(--line-3); font-size: 14px; }
.rsn-a { color: var(--ink); font-weight: 700; margin-top: 4px; }
.rsn-w { display: flex; align-items: center; gap: 6px; margin-top: 6px; font-size: 13px; font-weight: 700; color: var(--green-ink); }
.rsn-w .ic { width: 15px; height: 15px; }
.rv-h { display: flex; align-items: center; gap: 8px; font-size: 16px; margin: 14px 0 6px; color: var(--mustard-ink); } .rv-h.ok { color: var(--green-ink); }
.rv-h .ic { width: 18px; height: 18px; }
.rv { margin: 0; padding-left: 20px; display: grid; gap: 6px; font-weight: 600; }
.insp { display: grid; gap: 8px; }
.sugg.done { opacity: .55; }

/* ---------- share link, version history ---------- */
.sh-link { display: flex; gap: 8px; margin-top: 12px; } .sh-link .input { flex: 1 1 auto; min-width: 0; font-size: 14px; }
.vh { display: grid; gap: 8px; }
.vh-row { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 10px 12px; border: 2px solid var(--line); border-radius: 14px; }
.vh-row > div { display: flex; flex-direction: column; } .vh-row span { font-size: 13px; }

/* public demo copy: a small "Demo" tag after the brand (html data-demo is set by the deploy bundle) */
html[data-demo] .brand-word::after { content: "Demo"; display: inline-block; margin-left: 8px; padding: 2px 7px; border-radius: 999px; background: #FEF7E0; color: #8a5a00; font-size: 11px; font-weight: 800; letter-spacing: .02em; vertical-align: middle; transform: translateY(-3px); }
