@font-face { font-family: "Plus Jakarta Sans"; src: url("fonts/plus-jakarta-sans-latin-400-normal.woff2") format("woff2"); font-weight: 400; font-display: swap; }
@font-face { font-family: "Plus Jakarta Sans"; src: url("fonts/plus-jakarta-sans-latin-500-normal.woff2") format("woff2"); font-weight: 500; font-display: swap; }
@font-face { font-family: "Plus Jakarta Sans"; src: url("fonts/plus-jakarta-sans-latin-600-normal.woff2") format("woff2"); font-weight: 600; font-display: swap; }
@font-face { font-family: "Plus Jakarta Sans"; src: url("fonts/plus-jakarta-sans-latin-700-normal.woff2") format("woff2"); font-weight: 700; font-display: swap; }
@font-face { font-family: "Plus Jakarta Sans"; src: url("fonts/plus-jakarta-sans-latin-800-normal.woff2") format("woff2"); font-weight: 800; font-display: swap; }
:root {
  --bg: #f3f4f7; --card: #fff; --ink: #16181d; --muted: #5d6370; --line: #e2e5eb;
  --brand: #0E6B5C; --brand-ink: #fff; --brand-soft: #E3F3EE; --ok: #137a4b; --ok-soft: #e3f4ea;
  --warn: #a3520a; --warn-soft: #fdf0e1; --danger: #c0352b; --r: 12px;
  font-family: "Plus Jakarta Sans", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
}
* { box-sizing: border-box; }
html, body { margin: 0; background: var(--bg); color: var(--ink); }
body { padding-bottom: env(safe-area-inset-bottom); -webkit-tap-highlight-color: transparent; }
button, input, textarea { font: inherit; color: inherit; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }

.topbar { position: sticky; top: 0; z-index: 20; display: flex; align-items: center; justify-content: space-between; gap: 8px;
  padding: calc(10px + env(safe-area-inset-top)) 16px 10px; background: var(--card); border-bottom: 1px solid var(--line); }
.brand { display: flex; align-items: center; gap: 8px; font-weight: 650; font-size: 17px; }
.logo { width: 30px; height: 30px; display: block; }
#appName { font-weight: 800; letter-spacing: -.4px; }
#appName b { font-weight: 800; color: var(--brand); }
.brand .tag { font-size: 12px; font-weight: 600; color: var(--muted); border-left: 1px solid var(--line); padding-left: 8px; margin-left: 2px; }
@media (max-width: 420px) { .brand .tag { display: none; } }
.top-actions { display: flex; align-items: center; gap: 8px; position: relative; }
.seg { display: flex; border: 1px solid var(--line); border-radius: 8px; overflow: hidden; }
.seg button { border: 0; background: none; padding: 6px 10px; font-size: 13px; font-weight: 600; color: var(--muted); cursor: pointer; }
.seg button[aria-pressed="true"] { background: var(--brand-soft); color: var(--brand); }
.menu { position: absolute; right: 0; top: 44px; background: var(--card); border: 1px solid var(--line); border-radius: 10px; box-shadow: 0 8px 24px rgba(0,0,0,.12); min-width: 180px; padding: 6px; }
.menu button { display: block; width: 100%; text-align: left; border: 0; background: none; padding: 10px 12px; border-radius: 6px; cursor: pointer; }
.menu button:hover { background: var(--bg); }

.tabs { position: sticky; top: calc(51px + env(safe-area-inset-top)); z-index: 15; display: flex; background: var(--card); border-bottom: 1px solid var(--line); }
.tabs button { flex: 1; border: 0; background: none; padding: 12px 4px; font-weight: 600; font-size: 14px; color: var(--muted); border-bottom: 2px solid transparent; cursor: pointer; }
.tabs button[aria-selected="true"] { color: var(--brand); border-bottom-color: var(--brand); }

.layout { max-width: 1280px; margin: 0 auto; padding: 14px; }
.pane { display: none; }
body[data-view="edit"] .pane-edit, body[data-view="match"] .pane-match, body[data-view="preview"] .pane-preview { display: block; }

.card { background: var(--card); border: 1px solid var(--line); border-radius: var(--r); padding: 16px; margin-bottom: 14px; }
/* Section titles: a tinted band with a green marker, so each part of the form is easy to spot while typing. */
.card { overflow: hidden; }
.card > h2:first-child { display: flex; align-items: center; gap: 10px; margin: -16px -16px 14px; padding: 12px 16px; background: var(--brand-soft); color: var(--brand); border-bottom: 1px solid #CFE8DF; font-size: 13px; font-weight: 800; text-transform: uppercase; letter-spacing: .08em; }
.card > h2:first-child::before { content: ""; width: 4px; height: 16px; border-radius: 2px; background: var(--brand); flex: none; }
.card h2 { font-size: 16px; margin: 0 0 12px; }
.card h3 { font-size: 14px; margin: 14px 0 8px; }
.muted { color: var(--muted); font-size: 14px; line-height: 1.5; margin: 0 0 12px; }
.small { font-size: 12.5px; }
.field { display: block; margin-bottom: 12px; }
.field > span { display: block; font-size: 12.5px; font-weight: 600; color: var(--muted); margin-bottom: 5px; }
.field input, .field textarea, .fake { width: 100%; border: 1px solid var(--line); border-radius: 8px; padding: 10px 11px; background: #fbfbfd; font-size: 15px; }
.fake { color: var(--muted); }
.field textarea { resize: vertical; line-height: 1.45; }
.field input:focus, .field textarea:focus { outline: none; border-color: var(--brand); background: #fff; box-shadow: 0 0 0 3px var(--brand-soft); }
.grid2 { display: grid; grid-template-columns: 1fr; gap: 0 12px; }
.grid2.tight { grid-template-columns: 1fr 1fr; }
@media (min-width: 560px) { .grid2 { grid-template-columns: 1fr 1fr; } }
.check { display: flex; align-items: center; gap: 8px; font-size: 14px; margin: -2px 0 12px; }
.check input { width: 18px; height: 18px; accent-color: var(--brand); }
.item { border: 1px solid var(--line); border-radius: 10px; padding: 12px; margin-bottom: 12px; }
.item-head { display: flex; justify-content: space-between; align-items: center; gap: 8px; margin-bottom: 10px; font-size: 14px; }
.item-head b { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.item-head span { display: flex; gap: 12px; flex-shrink: 0; }
.link { border: 0; background: none; color: var(--brand); font-size: 13px; font-weight: 600; cursor: pointer; padding: 4px 0; }
.link.danger { color: var(--danger); }

.btn { border: 1px solid transparent; border-radius: 9px; padding: 10px 16px; font-weight: 600; font-size: 14px; cursor: pointer; display: inline-flex; align-items: center; justify-content: center; gap: 8px; }
.btn.primary { background: var(--brand); color: var(--brand-ink); }
.btn.ghost { background: var(--card); border-color: var(--line); }
.btn.danger { background: var(--danger); color: #fff; }
.btn.ai { background: var(--brand-soft); color: var(--brand); }
.btn.block { display: flex; width: 100%; }
.btn:active { transform: scale(.98); }
.ai-left { font-size: 12.5px; color: var(--muted); margin: 8px 0 0; }
.spin { width: 14px; height: 14px; border: 2px solid currentColor; border-right-color: transparent; border-radius: 50%; animation: spin .7s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
.notice { background: #FDF1DC; color: #7A4A00; border-radius: 10px; padding: 10px 12px; font-size: 13.5px; margin: 0 0 12px; }
.err { color: var(--danger); font-size: 13px; margin: -6px 0 10px; }

.score { display: flex; align-items: center; gap: 14px; }
.score h2 { margin: 0; }
.ring { --p: 0; width: 72px; height: 72px; border-radius: 50%; display: grid; place-items: center;
  background: conic-gradient(var(--brand) calc(var(--p) * 1%), var(--line) 0); }
.ring span { width: 56px; height: 56px; border-radius: 50%; background: var(--card); display: grid; place-items: center; font-weight: 700; font-size: 17px; }
.chips { display: flex; flex-wrap: wrap; gap: 6px; }
.chip { border: 0; border-radius: 999px; padding: 6px 11px; font-size: 13px; font-weight: 600; }
.chip.ok { background: var(--ok-soft); color: var(--ok); }
.chip.miss { background: var(--warn-soft); color: var(--warn); cursor: pointer; }
.quote { background: var(--bg); border-radius: 8px; padding: 12px; line-height: 1.5; font-size: 14px; margin: 0 0 12px; }
.tips { margin: 0; padding-left: 18px; line-height: 1.5; font-size: 14px; }
.tips li { margin-bottom: 6px; }

/* CV paper preview: the .cvpage design (cv.css), scaled to fit the screen */
.paper-wrap { position: relative; overflow: hidden; margin-bottom: 14px; }
.paper-bar { display: flex; align-items: center; justify-content: flex-end; gap: 10px; margin-bottom: 10px; font-size: 13px; font-weight: 600; color: var(--muted); }
.paper { transform-origin: top left; box-shadow: 0 1px 3px rgba(0,0,0,.12), 0 6px 20px rgba(0,0,0,.06); }
.measure { position: absolute; left: -10000px; top: 0; visibility: hidden; pointer-events: none; }
.toast { position: fixed; left: 50%; bottom: calc(20px + env(safe-area-inset-bottom)); transform: translate(-50%, 30px); opacity: 0; transition: .25s;
  background: #16181d; color: #fff; padding: 10px 16px; border-radius: 10px; font-size: 14px; pointer-events: none; z-index: 50; max-width: 90vw; }
.toast.show { opacity: 1; transform: translate(-50%, 0); }
.modal-back { position: fixed; inset: 0; background: rgba(10,12,20,.45); display: grid; place-items: center; z-index: 40; padding: 20px; }
.modal-back[hidden] { display: none; }
.modal { background: var(--card); border-radius: 14px; padding: 20px; max-width: 420px; width: 100%; }
.modal h2 { margin: 0 0 10px; font-size: 18px; }
.modal p { line-height: 1.5; }
.modal-actions { display: flex; justify-content: flex-end; gap: 8px; margin-top: 16px; }

.desk-only { display: none; }
@media (min-width: 960px) {
  .desk-only { display: inline-flex; }
  /* On a computer the menu is a toolbar: every action is visible, no "⋯" click needed. */
  #btnMenu { display: none; }
  .menu, .menu[hidden] { position: static; display: flex; align-items: center; gap: 2px; background: none; border: 0; box-shadow: none; padding: 0; min-width: 0; }
  .menu button { width: auto; padding: 9px 12px; font-size: 14px; font-weight: 600; color: var(--muted); white-space: nowrap; }
  .menu button:hover { background: var(--bg); color: var(--ink); }
  .menu #btnProMenu { color: var(--brand); background: var(--brand-soft); margin: 0 6px; }
  .menu #btnProMenu::before { content: "★ "; }
  .menu #btnAccount { border: 1px solid var(--line); }
  .mob-only { display: none !important; }
  .tabs { justify-content: flex-start; padding-left: max(14px, calc((100vw - 1280px) / 2 + 14px)); }
  .tabs button { flex: 0 0 auto; padding: 12px 18px; }
  .tabs [data-tab="preview"] { display: none; }
  .layout { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.05fr); gap: 20px; align-items: start; }
  .pane-preview { display: block !important; position: sticky; top: 116px; max-height: calc(100vh - 130px); overflow: auto; }
  body[data-view="preview"] .pane-edit { display: block; }
}
.card h3:first-child { margin-top: 0; }
.hint { background: var(--warn-soft); color: var(--warn); border-radius: 10px; padding: 10px 12px; font-size: 13.5px; line-height: 1.45; margin: 0 0 12px; }
.photo-row { display: flex; align-items: center; gap: 14px; margin-bottom: 6px; }
.photo-thumb { width: 64px; height: 64px; border-radius: 50%; background: var(--brand-soft); color: var(--brand); display: grid; place-items: center; font-size: 26px; overflow: hidden; flex-shrink: 0; border: 1px solid var(--line); }
.photo-thumb img { width: 100%; height: 100%; object-fit: cover; }
.photo-ctl { display: flex; flex-direction: column; gap: 6px; font-size: 14px; }
.photo-btns { display: flex; align-items: center; gap: 14px; }
.photo-ctl .check { margin: 0; }
.small-btn { padding: 7px 12px; font-size: 13px; }
.crop { display: flex; justify-content: center; }
.crop canvas { border-radius: 12px; touch-action: none; cursor: grab; background: #222; }
.photo-thumb { cursor: pointer; }
.chip.preset { background: var(--brand-soft); color: var(--brand); cursor: pointer; }
.order { list-style: none; margin: 0; padding: 0; counter-reset: o; }
.order li { display: flex; align-items: center; justify-content: space-between; gap: 8px; padding: 8px 0; border-top: 1px solid var(--line); font-size: 14px; counter-increment: o; }
.order li:first-child { border-top: 0; }
.order li > span:first-child::before { content: counter(o) ". "; color: var(--muted); }
.order-btns { display: flex; gap: 6px; }
.icon-btn { width: 34px; height: 34px; border: 1px solid var(--line); border-radius: 8px; background: var(--card); font-size: 15px; cursor: pointer; }
.icon-btn[aria-disabled="true"] { opacity: .35; pointer-events: none; }
.custom-card .item-head { margin-bottom: 12px; }
.pro-points { margin: 0 0 14px; padding-left: 20px; line-height: 1.6; font-size: 14px; }
.key-box { border-top: 1px solid var(--line); margin-top: 16px; padding-top: 14px; }
.pro-on { color: var(--brand); font-weight: 700; }
a.btn { text-decoration: none; }
.btn:disabled { opacity: .6; }
.g-btn { display: flex; justify-content: center; min-height: 44px; margin: 6px 0 4px; }
.or { display: flex; align-items: center; gap: 10px; color: var(--muted); font-size: 13px; margin: 12px 0; }
.or::before, .or::after { content: ""; flex: 1; height: 1px; background: var(--line); }
.auth-alt { text-align: center; font-size: 14px; color: var(--muted); margin: 14px 0 0; }
.btn.block + .muted.small { text-align: center; }
#btnAccount { max-width: 220px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

/* Main download button matches the website calls to action. */
#btnPdfTop, #btnPdfMob { text-transform: uppercase; letter-spacing: .06em; font-weight: 800; }

/* Phones and tablets: every tap target at least about 40px high, so fingers hit the right control. */
@media (pointer: coarse) {
  .link { min-height: 40px; padding: 8px 10px; display: inline-flex; align-items: center; }
  .chip { min-height: 40px; padding-left: 14px; padding-right: 14px; }
  input[type="checkbox"] { width: 22px; height: 22px; }
  .brand { min-height: 40px; }
}
