/* Task Tracker shared look. Every design page links this file.
   Type: Geist (text) + Instrument Serif (page titles and big dates). Both saved locally, no font requests out.
   Buttons are kept exactly as the owner approved on 1 Dec (green pill Update, big green Send/Save). */
@font-face { font-family:"Geist"; src:url("../fonts/geist-latin.woff2") format("woff2"); font-weight:100 900; font-display:swap; }
@font-face { font-family:"Instrument Serif"; src:url("../fonts/instrument-serif-latin.woff2") format("woff2"); font-weight:400; font-display:swap; }
@font-face { font-family:"Inter"; src:url("../fonts/inter-latin.woff2") format("woff2"); font-weight:400 700; font-display:swap; }
@font-face { font-family:"Geist Mono"; src:url("../fonts/geist-mono-latin.woff2") format("woff2"); font-weight:100 900; font-display:swap; }
@font-face { font-family:"Instrument Serif"; font-style:italic; src:url("../fonts/instrument-serif-italic-latin.woff2") format("woff2"); font-weight:400; font-display:swap; }

:root {
  --sans:"Geist",system-ui,-apple-system,"Segoe UI",Roboto,sans-serif;
  --serif:"Instrument Serif",Georgia,"Times New Roman",serif;
  --date:"Inter",system-ui,sans-serif;          /* dates: the older font the owner liked (1 Dec) */
  --num:"Inter",system-ui,sans-serif; /* numbers in the date font: the separate number font was removed (owner, 2 Dec) */
  --bg:#f4f2ec; --card:#fff; --ink:#16201c; --sub:#5f6a65; --faint:#5d6661; --line:#e7e3da; --well:#f6f4ef;
  --brand:#1f6b52; --brand-dark:#17543f; --brand-soft:#e4f0ea; --brand-ink:#fff;
  --late:#b3362a; --late-soft:#fbe9e6; --early:#1f7a3d; --early-soft:#e5f3e8;
  --blue:#2257b3; --blue-soft:#e6eefb; --amber:#8f5d00; --amber-soft:#fbf0d9; --violet:#6741b0; --violet-soft:#efe9fa;
  --r-card:20px; --r-ctl:14px;
  --shadow:0 1px 2px rgba(22,32,28,.04), 0 6px 20px rgba(22,32,28,.05);
}
* { box-sizing:border-box; -webkit-tap-highlight-color:transparent; }
html { overflow-x:clip; }
body { margin:0; background:var(--bg); color:var(--ink); font:16px/24px var(--sans); -webkit-font-smoothing:antialiased; text-rendering:optimizeLegibility; }
button, input, textarea, select { font:inherit; color:inherit; }
button { cursor:pointer; }
:focus-visible { outline:2px solid var(--brand); outline-offset:2px; }
svg.i { width:16px; height:16px; flex:none; fill:none; stroke:currentColor; stroke-width:1.8; stroke-linecap:round; stroke-linejoin:round; }

/* type scale */
.t-display { font-family:var(--serif); font-weight:400; font-size:44px; line-height:48px; letter-spacing:-.01em; margin:0; }
.t-title   { font-family:var(--serif); font-weight:400; font-size:28px; line-height:32px; letter-spacing:-.005em; margin:0; }
.t-h       { font-size:20px; line-height:28px; font-weight:600; letter-spacing:-.012em; margin:0; }
.t-body    { font-size:16px; line-height:24px; }
.t-small   { font-size:14px; line-height:20px; color:var(--sub); }
.t-label   { font-size:12px; line-height:16px; font-weight:600; letter-spacing:.09em; text-transform:uppercase; color:var(--faint); }
.num       { font-family:var(--num); font-variant-numeric:tabular-nums; letter-spacing:-.02em; }
.date      { font-family:var(--date); font-weight:600; font-variant-numeric:tabular-nums; letter-spacing:-.01em; }

/* stage: a symbol and its words, never a box, never a dot (owner, 1 Dec) */
.st-0 { color:#5d6763; } .st-1 { color:var(--blue); } .st-2 { color:var(--amber); } .st-3 { color:var(--early); } .st-x { color:var(--violet); } .st-sa { color:#7a5c00; }
.stage-txt { display:inline-flex; align-items:center; gap:8px; font-weight:600; font-size:16px; line-height:24px; }
.stage-txt svg.i { width:20px; height:20px; }

/* late / early marker */
.tag { display:inline-flex; align-items:center; gap:5px; border-radius:999px; padding:3px 10px; font-size:14px; line-height:20px; font-weight:600; white-space:nowrap; }
.tag svg.i { width:13px; height:13px; }
.tag.late { background:var(--late-soft); color:var(--late); }
.tag.early { background:var(--early-soft); color:var(--early); }

/* buttons: kept as approved */
.update { flex:none; min-width:132px; padding:0 24px; display:inline-flex; align-items:center; justify-content:center; gap:8px; min-height:52px; border:0; border-radius:999px; background:var(--ink); color:#fff; font-weight:600; font-size:16px; box-shadow:0 4px 12px rgba(22,32,28,.18); }
.update:hover { background:#000; }
.update svg.i { width:18px; height:18px; stroke-width:2; }
.big { display:flex; align-items:center; justify-content:center; gap:8px; width:100%; min-height:52px; margin-top:20px; border:0; border-radius:14px; background:var(--ink); color:#fff; font-weight:600; font-size:16px; }
.big:hover:not(:disabled) { background:#000; }
.big:disabled { background:#dcdcd6; color:#8a8f8c; cursor:not-allowed; }
.ghost { display:inline-flex; align-items:center; gap:8px; min-height:44px; padding:0 16px; border:1.5px solid var(--line); border-radius:999px; background:#fff; font-weight:600; font-size:14px; }
.ghost:hover { border-color:#cfc9bd; }

/* inputs */
textarea, input[type=text], input[type=email], input[type=date], input[type=search], select {
  width:100%; border:1.5px solid #9a958a; border-radius:var(--r-ctl); padding:12px 14px; background:#fff; font-size:16px; line-height:24px; }
textarea:focus, input:focus, select:focus { border-color:var(--brand); outline:none; }
textarea:focus-visible, input:focus-visible { outline:2px solid var(--brand); outline-offset:2px; }
textarea { min-height:92px; resize:vertical; }
.field { display:block; margin-top:18px; }
.field > span { display:block; font-size:14px; line-height:20px; font-weight:600; color:var(--sub); margin-bottom:8px; }
.find { display:flex; align-items:center; gap:10px; background:var(--card); border:1.5px solid #9a958a; border-radius:16px; padding:0 14px; min-height:50px; }
.find:focus-within { border-color:var(--brand); }
.find svg.i { width:18px; height:18px; color:var(--faint); }
.find input { flex:1; min-width:0; border:0; padding:12px 0; background:none; font-size:16px; }
.find input::-webkit-search-cancel-button { display:none; }

/* option rows (stages, sort, project): plain rows with a symbol and a tick */
.opts { border-top:1px solid var(--line); }
.opt { display:flex; align-items:center; gap:12px; width:100%; border:0; border-bottom:1px solid var(--line); background:none; padding:0 4px; min-height:52px; font-size:16px; font-weight:400; text-align:left; }
.opt svg.i { width:20px; height:20px; }
.opt .lbl { flex:1; color:var(--ink); }
.opt .cnt { color:var(--faint); font-size:14px; font-family:var(--num); }
.opt .tick { color:var(--brand); visibility:hidden; }
.opt[aria-pressed="true"] .lbl { font-weight:600; }
.opt[aria-pressed="true"] .tick { visibility:visible; }

/* sheet on a phone, centred dialog on a computer */
.scrim { position:fixed; inset:0; background:rgba(16,24,20,.36); opacity:0; pointer-events:none; transition:opacity .2s; z-index:40; }
.scrim.on { opacity:1; pointer-events:auto; }
.sheet { position:fixed; left:0; right:0; bottom:0; max-width:480px; margin:0 auto; background:var(--card); border-radius:24px 24px 0 0; padding:8px 20px 28px; transform:translateY(100%); transition:transform .25s cubic-bezier(.2,.8,.2,1); z-index:41; max-height:92vh; overflow:auto; }
.sheet.on { transform:none; }
.grab { width:36px; height:4px; border-radius:2px; background:#dcd8d0; margin:0 auto 16px; }
.sh { display:flex; align-items:center; justify-content:space-between; gap:8px; }
.sh h3 { margin:0; font-family:var(--serif); font-weight:400; font-size:28px; line-height:32px; }
.x { border:0; background:var(--late-soft); color:var(--late); border-radius:50%; width:44px; height:44px; display:grid; place-items:center; flex:none; }
.x:hover { background:#f6d5d0; }
.x svg.i { width:18px; height:18px; stroke-width:2.2; }
/* Cancel: always red, always with its cross (owner, 1 Dec: "cancel button could be in red ... crosses ... in red") */
.cancel { display:flex; align-items:center; justify-content:center; gap:8px; width:100%; min-height:48px; margin-top:10px; border:1.5px solid #efc9c3; border-radius:14px; background:#fff; color:var(--late); font-weight:600; font-size:16px; }
.cancel:hover { background:var(--late-soft); }
.cancel svg.i { width:16px; height:16px; stroke-width:2.2; }
.shsub { color:var(--sub); font-size:14px; line-height:20px; margin:4px 0 20px; overflow:hidden; text-overflow:ellipsis; white-space:nowrap; }
@media (min-width:900px) {
  .sheet { top:50%; bottom:auto; left:50%; right:auto; width:480px; margin:0; border-radius:24px; padding:20px 24px 28px; transform:translate(-50%,-46%) scale(.98); opacity:0; pointer-events:none; transition:transform .2s, opacity .2s; }
  .sheet.on { transform:translate(-50%,-50%); opacity:1; pointer-events:auto; }
  .grab { display:none; }
}

/* update kinds */
.tiles { display:grid; grid-template-columns:repeat(3,1fr); gap:10px; }
.tile { display:flex; flex-direction:column; align-items:center; gap:8px; padding:16px 4px; border:1.5px solid var(--line); background:#fff; border-radius:18px; font-size:14px; font-weight:600; }
.tile svg.i { width:24px; height:24px; }
.tile span { color:var(--ink); }
.tile.update-k { color:var(--brand); } .tile.blocker { color:var(--late); } .tile.feedback { color:var(--blue); }
.tile[aria-pressed="true"].update-k { border-color:var(--brand); background:var(--brand-soft); }
.tile[aria-pressed="true"].blocker { border-color:var(--late); background:var(--late-soft); }
.tile[aria-pressed="true"].feedback { border-color:var(--blue); background:var(--blue-soft); }
.reason { margin-top:20px; padding:14px; border-radius:16px; background:#fff6e5; }
.reason > span { display:flex; align-items:center; gap:6px; font-size:14px; font-weight:600; color:#8a5a00; }
.reason textarea { margin-top:10px; min-height:76px; }
.hint { display:flex; align-items:center; gap:6px; color:var(--faint); font-size:14px; line-height:20px; margin-top:8px; }
.hint svg.i { width:13px; height:13px; }

.toast { position:fixed; left:50%; bottom:28px; transform:translate(-50%,16px); background:var(--ink); color:#fff; border-radius:999px; padding:12px 18px; display:flex; align-items:center; gap:8px; font-size:16px; font-weight:400; opacity:0; transition:.2s; z-index:60; white-space:nowrap; }
.toast svg.i { color:#7fd4ac; }
.toast.on { opacity:1; transform:translate(-50%,0); }
[hidden] { display:none !important; }
@keyframes tt-spin { to { transform:rotate(360deg); } }
.st-1 > svg.i, svg.i.s-spin { animation:tt-spin 2.4s linear infinite; transform-origin:50% 50%; }
@media (prefers-reduced-motion: reduce) { .sheet, .scrim, .toast, .detail, .drawer, .dscrim { transition:none !important; } .st-1 > svg.i, svg.i.s-spin { animation:none; } }
@media print { .st-1 > svg.i, svg.i.s-spin { animation:none; } }
.sheet:not(.on) { visibility:hidden; transition:transform .25s, opacity .2s, visibility 0s .25s; }
.tag.over { background:var(--late); color:#fff; }
.toast .undo { border:0; background:none; color:#9fe0c0; font-weight:600; margin-left:6px; padding:4px 6px; min-height:32px; cursor:pointer; }
