/* SIPANTAS v2. Layout follows DESIGN.md (title-block header, hairlines instead of shadows); the font and rounded
   corners are the earlier ones, which the owner kept (23 Sep 2026), and the colors are the Dashboard's (28 Sep 2026).
   Mobile first: phones get a bottom tab bar, laptops the menu inside the header.
   Sized for older eyes: body 18px, nothing readable under 15px (14px only for tags and badges),
   every tap target at least 44px. */
:root {
  /* The Dashboard's colors ("Poster Kantor"), on every page since 28 Sep 2026 (owner's request): warm paper, cream
     panels, navy ink, terracotta for anything you can press, mustard for warnings, teal for a deal's stages. */
  --bg: #f3ede2; --sheet: #fbf7f0; --ink: #1c2a48; --ink-2: #33405c; --muted: #4a5263;  /* muted passes 6.7:1 */
  --line: #e6dccb; --field: #8a8171; --edge: #d4c4a8;  /* form borders pass 3:1; edge: buttons, tags, chart axes */
  --terra: #d9623b; --must: #e8b33a; --teal: #2a8c82;  /* fills and bars */
  --act: #bb4c28; --act-press: #9c3c1c; --act-soft: #f7e2d7;  /* terracotta a shade darker, so white text passes AA */
  --amber: #8a5d00; --amber-soft: #f8ebc8;  /* mustard, darkened for text */
  --green: #1f6b63;  /* teal, darkened for text */
  --tint: #ebe2d2;  /* progress tracks and info messages */
  --r: 14px;  /* panel corners */
}
* { box-sizing: border-box; }
body {
  margin: 0; background: var(--bg); color: var(--ink);
  font: 18px/1.5 system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  -webkit-font-smoothing: antialiased; padding-bottom: 80px;
}
a { color: var(--act); }
h1 { margin: 0; font-size: 26px; line-height: 1.2; letter-spacing: -.01em; }
h2 { margin: 0 0 12px; font-size: 20px; line-height: 1.3; }
small { font-size: 15px; }
b, .num { font-variant-numeric: tabular-nums; }  /* dates and counts line up */
.muted { color: var(--muted); }
.ok { color: var(--green); }
.empty { color: var(--muted); padding: 16px 0; }
:focus-visible { outline: 2px solid var(--act); outline-offset: 1px; }

/* The header is laid out like a drawing's title block, its cells split by hairlines, on the Dashboard's navy. */
header { display: flex; align-items: stretch; color: #fff; background: var(--ink); }
header .brand, header .who, header .today { display: flex; flex-direction: column; justify-content: center; padding: 8px 16px; }
header .brand {  /* the logo, then the name */
  flex-direction: row; align-items: center; gap: 10px;
  color: #fff; text-decoration: none; border-right: 1px solid rgba(255, 255, 255, .2);
}
header .brand span { display: flex; flex-direction: column; }header .brand b { font-size: 20px; line-height: 1.2; letter-spacing: .6px; }
header small { opacity: .9; }
header .who { margin-left: auto; text-align: right; font-size: 17px; line-height: 1.3; border-left: 1px solid rgba(255, 255, 255, .2); }
header .today { display: none; text-align: right; line-height: 1.3; border-left: 1px solid rgba(255, 255, 255, .2); }
header .out {  /* Keluar: the whole cell is the tap target */
  display: flex; align-items: center; padding: 0 16px; color: #fff; opacity: .88; font-size: 15px; text-decoration: none;
  border-left: 1px solid rgba(255, 255, 255, .2); transition: opacity 120ms;
}
header .out:hover { opacity: 1; }
nav.top { display: none; }
nav.top a {
  display: flex; align-items: center; padding: 0 16px; min-height: 58px; color: #fff; opacity: .88;
  font-size: 17px; text-decoration: none; transition: opacity 120ms;
}
nav.top a:hover { opacity: 1; }
nav.top a.on { opacity: 1; font-weight: 600; box-shadow: inset 0 -3px 0 var(--terra); }

.preview {
  display: flex; flex-wrap: wrap; align-items: center; gap: 10px;
  padding: 8px 16px; background: var(--amber-soft); border-bottom: 1px solid var(--edge); font-size: 14px;
}
.preview form { display: inline; }
.preview select, .preview button { padding: 6px 8px; font-size: 14px; width: auto; }
/* A message is a tinted box with a 4px rule in its color: navy for news, mustard for a warning. */
.flash {
  max-width: 1040px; margin: 14px auto -2px; padding: 12px 16px; border-radius: 10px;
  background: var(--tint); color: var(--ink); box-shadow: inset 4px 0 0 var(--ink);
}
.flash.warn { background: var(--amber-soft); color: var(--amber); box-shadow: inset 4px 0 0 var(--amber); }
main > .flash { margin: 0 0 12px; }  /* a note inside a page, such as the SLF dates on a project */

main { max-width: 1040px; margin: 0 auto; padding: 16px; }
.page-head { display: flex; flex-wrap: wrap; gap: 10px; align-items: flex-start; margin-bottom: 16px; }
.page-head > div:first-child { flex: 1 1 200px; }
.page-head p { margin: 6px 0 0; }
.page-head .back { margin-bottom: 12px; }  /* back is always top left, above the title */

/* A warning that opens in the page, in place, before a step the app can't undo (Tandai batal, Hapus).
   No browser pop-up: some browsers block them. */
.confirm > summary, .kelola > summary { list-style: none; }
.confirm > summary::-webkit-details-marker, .kelola > summary::-webkit-details-marker { display: none; }
.confirm[open] > summary { background: var(--amber-soft); border-color: var(--edge); color: var(--amber); }
.confirm-box {
  margin-top: 8px; padding: 14px 16px; background: var(--amber-soft); color: var(--ink);
  border: 1px solid var(--edge); border-radius: 10px; font-size: 17px; font-weight: 400; text-align: left;
}
.confirm-box p { margin: 0 0 12px; }
.confirm-box b { color: var(--amber); }
.confirm .confirm-box form { display: flex; flex-wrap: wrap; gap: 8px; justify-content: flex-end; }
.confirm-box label { flex-basis: 100%; font-weight: 600; color: var(--ink-2); }  /* Batalkan deal's reason */
.confirm-box label input { margin: 6px 0 4px; font-weight: 400; }
.actions { display: flex; flex-wrap: wrap; gap: 8px; }
/* A lead's moves: Tandai batal on the left, the moves forward pushed right. An open warning takes its own line. */
.lead-moves { display: flex; flex-wrap: wrap; align-items: flex-start; gap: 8px; }
.lead-moves .confirm + * { margin-left: auto; }
.lead-moves .confirm[open] { flex-basis: 100%; }
.lead-moves .actions { flex: 1 1 auto; justify-content: flex-end; }  /* fills its line, buttons hug the right */
.survey { display: flex; gap: 8px; }  /* the survey's date box stays beside its button */
.survey input[name=tgl_survey] { flex: 0 1 9em; width: 9em; min-width: 0; }
.actions form { display: inline; }

/* Every button is at least 44px tall: 27px of text plus padding and border. */
button, .btn {
  font: inherit; font-weight: 500; padding: 10px 16px; border-radius: 10px; border: 1px solid var(--edge);
  background: var(--sheet); color: var(--ink-2); cursor: pointer; text-decoration: none; display: inline-block;
  transition: background-color 120ms, border-color 120ms, color 120ms;
}
button:hover, .btn:hover { background: var(--bg); }
button.primary, .btn.primary { background: var(--act); border-color: var(--act); color: #fff; }
button.primary:hover, .btn.primary:hover { background: var(--act-press); border-color: var(--act-press); }
/* The selected tab is tinted, so it never looks like a solid action (27 Sep 2026). The one action among the
   tabs, "+ Lead baru", is solid ink rather than terracotta, so it can't be taken for the current tab (owner's request). */
.btn[aria-current=page] { background: var(--act-soft); border-color: var(--act); color: var(--act-press); font-weight: 600; }
nav.filters .btn.primary { background: var(--ink-2); border-color: var(--ink-2); }
nav.filters .btn.primary:hover { background: var(--ink); border-color: var(--ink); }
button:disabled { opacity: .45; cursor: not-allowed; }
.btn.big { padding: 12px 22px; font-size: 20px; }
.btn.small { padding: 9px 12px; font-size: 16px; }
input, select { font: inherit; padding: 10px 12px; border: 1px solid var(--field); border-radius: 10px; background: var(--sheet); width: 100%; color: var(--ink); }
input:focus, select:focus { outline: 2px solid var(--act); outline-offset: 1px; border-color: var(--act); }
input[type=checkbox] { width: 28px; height: 28px; margin: 0; accent-color: var(--act); cursor: pointer; }
/* The browser's own calendar for a date box (base.html): invisible, laid over the box, so it opens right there. */
input.cal { position: absolute; opacity: 0; pointer-events: none; padding: 0; border: 0; margin: 0; }

.filters { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 16px; }
.filters > * { flex: 1 1 220px; }  /* one field per line on phones, so nothing gets cut off */
.filters button, .filters .btn { flex: 0 0 auto; }
nav.filters .btn { padding-left: 12px; padding-right: 12px; }  /* + Lead baru and both tabs fit one phone line */

/* Progress: 4px, round ends, terracotta on a light track, like the Dashboard's bars. */
.bar { display: block; height: 4px; border-radius: 999px; background: var(--tint); overflow: hidden; }
.bar i { display: block; height: 100%; background: var(--terra); }

/* Summary dashboard: one panel per department, then new deals per month, in the colors of the stage dots
   (grey to teal, 28 Sep 2026; DESIGN.md › Summary). Values sit at each bar's tip; axes are a warm hairline.
   --c and --p also draw the dots on Marketing's rows and the other panels' titles (see the stage labels). */
.dash {
  --axis: var(--edge); --c: var(--teal); --p: 50;  /* Processing's dot */
  display: grid; gap: 12px; margin-bottom: 16px; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
}
.viz.finalize { --c: #1d6e66; --p: 75; } .viz.selesai { --c: #0f5a52; --p: 100; }
/* Marketing's rows are always Potential, Survey, then Deal berjalan (the deals in hand, with Processing's dot) */
.viz.marketing .hbar:nth-child(1) { --c: #7d8799; --p: 0; }
.viz.marketing .hbar:nth-child(2) { --c: #4f9a91; --p: 25; }
.viz.marketing .hbar > span:first-child { display: flex; align-items: center; gap: 7px; }
.viz { margin: 0; background: var(--sheet); border: 1px solid var(--line); border-radius: var(--r); padding: 14px 16px; }
.viz figcaption { margin-bottom: 12px; font-weight: 600; }
/* The title opens the department's list: ink, with a muted › to show it goes somewhere. */
.viz figcaption a {  /* 44px to tap */
  position: relative; display: inline-flex; align-items: center; gap: 7px;
  padding: 10px 0; margin: -10px 0; color: var(--ink); text-decoration: none;
}
.viz figcaption a span { color: var(--muted); }
.viz figcaption a:hover { text-decoration: underline; }
.viz figcaption small { display: block; font-weight: 400; color: var(--muted); }
.viz .count { float: right; font-size: 28px; line-height: 1.1; }
/* A panel's labels share one column, as wide as the longest one (at most 62%), so its bars start together. */
.hbars { display: grid; grid-template-columns: fit-content(62%) 1fr; gap: 8px 10px; }
.hbar { display: grid; grid-column: 1 / -1; grid-template-columns: 110px 1fr; grid-template-columns: subgrid; align-items: center; font-size: 16px; }
.hbar .track { display: flex; align-items: center; gap: 6px; min-height: 18px; border-left: 1px solid var(--axis); }
.hbars.plain .track { border-left: 0; }  /* every count is 1: a list, no bars */
.hbar i { height: 16px; border-radius: 0 4px 4px 0; background: var(--c); }
.cols .plot { display: flex; align-items: flex-end; gap: 2px; height: 124px; border-bottom: 1px solid var(--axis); }
.cols .plot > div { flex: 1; display: flex; flex-direction: column; align-items: center; gap: 4px; font-size: 16px; }
/* each month's deals stacked by jenis pekerjaan from the bottom, a 2px gap between them, the top one rounded */
.cols .stack { display: flex; flex-direction: column-reverse; gap: 2px; width: 60%; max-width: 24px; }
.cols .stack i { background: var(--k); }
.cols .stack i:last-child { border-radius: 4px 4px 0 0; }
.cols .axis { display: flex; gap: 2px; padding-top: 4px; font-size: 15px; color: var(--muted); }
.cols .axis span { flex: 1; text-align: center; }
.cols .axis small { display: block; }
.cols .axis .full { display: none; }  /* phones get ’26: twelve columns leave no room for 2026 */
.hbar b, .cols b { font-weight: 600; }
/* Jenis pekerjaan in Templates order (SLF, PBG, Lainnya): teal, gold and violet, which pass the colour-blind and
   3:1 checks together (DESIGN.md › Color). ponytail: three slots; a fourth jenis in Templates needs a fourth colour */
.jenis-1 { --k: #0e8e83; } .jenis-2 { --k: #b8860b; } .jenis-3 { --k: #7a5cb8; }
.legend { display: flex; flex-wrap: wrap; gap: 4px 16px; margin: -4px 0 12px; font-size: 15px; color: var(--ink-2); }
.legend span::before { content: ""; display: inline-block; width: 12px; height: 12px; margin-right: 6px; border-radius: 3px; background: var(--k); vertical-align: -1px; }
.hbar:hover i, .cols .plot > div:hover i { filter: brightness(1.15); }

/* Dashboard, "Poster Kantor" (picked with /design-shotgun, 28 Sep 2026; DESIGN.md › Dashboard): the office
   screen's own look. Its colors became the whole app's the same day (see :root); its type (Plus Jakarta Sans) and
   poster layout stay its own. On a 1920x1080 screen it fits without scrolling; on phones it stacks. Everything is
   scoped to .poster, since the app uses some of the same class names (.tiles on the project page). */
main.wide { max-width: none; padding: 0; }
body.kiosk { padding-bottom: 0; }  /* the office screen's account: no tab bar to make room for */
.poster {
  --pmuted: #5c6475;  /* its own muted, for big type on a wall screen */
  display: grid; gap: 14px 18px; padding: 20px 30px; background: var(--bg); color: var(--ink);
  font-family: "Plus Jakarta Sans", system-ui, sans-serif; grid-template-columns: 0.95fr 1.25fr 0.8fr; grid-template-rows: auto auto 1fr auto;
}
body.kiosk .poster { height: 100vh; grid-template-rows: auto auto minmax(0, 1fr) auto; }  /* one screen, never a scrollbar */
body.kiosk .poster .map { flex: 1 1 0; min-height: 0; }  /* pills under the map shrink it rather than grow the page */
.poster b { font-variant-numeric: normal; }  /* big numbers take proportional figures */
.poster h2 { margin: 0 0 4px; font-size: 24px; font-weight: 800; }
.poster .top { grid-column: 1 / -1; display: flex; justify-content: space-between; align-items: baseline; gap: 12px; }
.poster .top h1 { margin: 0; font-weight: 800; font-size: 44px; letter-spacing: -.02em; }
.poster .top h1 em { font-style: normal; color: var(--terra); }
.poster .hero { grid-row: 2 / 4; background: var(--ink); color: var(--sheet); border-radius: 28px; padding: 34px 36px; display: flex; flex-direction: column; gap: 16px; }
.poster .hero b { font-weight: 800; font-size: 260px; line-height: .85; letter-spacing: -.05em; }
.poster .hero p { font-size: 36px; font-weight: 700; line-height: 1.15; margin: 10px 0 0; }
.poster .hero small { font-size: 20px; color: #c9d1e6; font-weight: 500; }
.poster .sky { display: flex; gap: 6px; align-items: flex-end; margin-top: auto; padding-bottom: 18px; border-bottom: 2px solid rgba(251, 247, 240, .25); }
.poster .sk { width: 64px; height: 64px; stroke: rgba(251, 247, 240, .5); stroke-width: 1.6; fill: none; stroke-linecap: round; stroke-linejoin: round; }
.poster .sk:nth-child(3), .poster .sk:nth-child(4) { width: 84px; height: 84px; }
.poster .tiles { grid-column: 2 / 4; display: grid; grid-template-columns: 1.3fr 1fr 1fr 1fr; gap: 18px; }
.poster .tile { border-radius: 24px; padding: 20px 22px; color: var(--sheet); }
.poster .tile b { display: block; font-weight: 800; font-size: 84px; line-height: .95; letter-spacing: -.03em; }
.poster .tile span { font-weight: 700; font-size: 20px; }
.poster .t1 { background: var(--terra); } .poster .t2 { background: var(--must); color: var(--ink); }
.poster .t3 { background: var(--teal); } .poster .t4 { background: var(--sheet); color: var(--ink); border: 2px solid var(--ink); }
.poster .mapbox, .poster .speed, .poster .icons { background: var(--sheet); border-radius: 28px; }
.poster .mapbox { padding: 20px 24px; display: flex; flex-direction: column; }
.poster .mapbox > p { margin: 0 0 8px; color: var(--pmuted); font-size: 16px; }
.poster .map { width: 100%; height: auto; max-height: 440px; flex: 1; }
.poster .land { fill: #efe4d0; stroke: #d4c4a8; stroke-width: 1.2; stroke-linejoin: round; }
.poster .bubs circle { stroke: var(--sheet); stroke-width: 3; }  /* a province's badge */
.poster .bubs circle.big { fill: var(--terra); } .poster .bubs circle.mid { fill: var(--must); } .poster .bubs circle.sml { fill: var(--teal); }
.poster .bubs text { font-weight: 800; font-family: "Plus Jakarta Sans", system-ui, sans-serif; fill: var(--sheet); }
.poster .bubs text.mid { fill: var(--ink); }
.poster .lab text { font: 700 19px "Plus Jakarta Sans", system-ui, sans-serif; fill: var(--ink); paint-order: stroke; stroke: var(--sheet); stroke-width: 5px; stroke-linejoin: round; }
.poster .tops { display: grid; grid-template-columns: auto 1fr auto; gap: 6px 12px; align-items: center; margin-top: 10px; font-size: 17px; }
.poster .tops h3 { grid-column: 1 / -1; margin: 0; font-size: 16px; font-weight: 700; color: var(--pmuted); }
.poster .tops span { font-weight: 700; } .poster .tops b { font-weight: 800; text-align: right; }
.poster .tops i { display: block; height: 12px; min-width: 4px; border-radius: 6px; background: var(--terra); }
.poster .away { display: flex; flex-wrap: wrap; gap: 8px; margin: 8px 0 0; }
.poster .away span { border: 2px solid var(--ink); border-radius: 999px; padding: 4px 14px; font-weight: 700; font-size: 17px; }
.poster .away em { font-style: normal; font-weight: 600; font-size: 16px; color: var(--pmuted); align-self: center; }
.poster .speed { padding: 20px 24px; display: flex; flex-direction: column; align-items: center; justify-content: center; text-align: center; }
.poster .gauge { width: 100%; max-width: 330px; height: auto; }
.poster .gauge .track, .poster .gauge .value { fill: none; stroke-width: 18; }
.poster .gauge .track { stroke: #e9dfcd; } .poster .gauge .value { stroke: var(--terra); }
.poster .gauge .tk line { stroke: #b9ad97; stroke-width: 2; stroke-linecap: round; }
.poster .gauge .nd { stroke: var(--ink); stroke-width: 5; stroke-linecap: round; fill: var(--ink); }
.poster .speed b { font-size: 76px; font-weight: 800; line-height: 1; margin-top: -10px; }
.poster .speed p { margin: 4px 0 0; font-weight: 700; font-size: 19px; } .poster .speed small { color: var(--pmuted); font-size: 16px; }
.poster .bottom { grid-column: 1 / -1; display: grid; grid-template-columns: 1.7fr 1fr 1fr; gap: 18px; }
.poster .icons { padding: 16px 24px; display: grid; grid-template-columns: repeat(7, 1fr); gap: 10px; align-items: center; }
.poster .b { display: grid; justify-items: center; gap: 2px; text-align: center; }
.poster .disc { width: 74px; height: 74px; border-radius: 50%; display: grid; place-items: center; background: #8a8f99; }  /* Lainnya, the last */
.poster .b:nth-child(1) .disc { background: var(--terra); } .poster .b:nth-child(2) .disc { background: var(--must); }
.poster .b:nth-child(3) .disc { background: var(--teal); } .poster .b:nth-child(4) .disc { background: var(--ink); }
.poster .b:nth-child(5) .disc { background: #b04a73; } .poster .b:nth-child(6) .disc { background: #6c8fc7; }
.poster .ic { width: 44px; height: 44px; stroke: #fff; stroke-width: 2.2; fill: none; stroke-linecap: round; stroke-linejoin: round; }
.poster .b b { font-size: 32px; font-weight: 800; line-height: 1.05; } .poster .nm { font-weight: 600; font-size: 15px; color: var(--pmuted); }
.poster .yearsbox { background: var(--ink); color: var(--sheet); border-radius: 28px; padding: 16px 22px 30px; }
.poster .yearsbox h2 { font-size: 20px; }
.poster .yrs { display: flex; align-items: flex-end; gap: 6px; height: 130px; }
.poster .yrs div { flex: 1; height: 100%; display: flex; flex-direction: column; justify-content: flex-end; align-items: center; position: relative; }
.poster .yrs b { font-weight: 800; font-size: 15px; margin-bottom: 3px; }
.poster .yrs i { width: 78%; max-width: 24px; border-radius: 6px 6px 0 0; background: var(--must); }
.poster .yrs span { position: absolute; bottom: -22px; font-size: 12px; color: #c9d1e6; }
@media (max-width: 900px) {
  .poster { grid-template-columns: minmax(0, 1fr); padding: 16px; } .poster .hero { grid-row: auto; } .poster .hero b { font-size: 150px; }
  .poster .top { flex-direction: column; gap: 6px; } .poster .top h1 { font-size: 30px; }
  .poster .tiles { grid-column: auto; grid-template-columns: 1fr 1fr; } .poster .tile b { font-size: 56px; }
  .poster .sky { flex-wrap: wrap; } .poster .sk { width: 44px; height: 44px; } .poster .sk:nth-child(3), .poster .sk:nth-child(4) { width: 56px; height: 56px; }
  .poster .bottom { grid-template-columns: minmax(0, 1fr); } .poster .icons { grid-template-columns: repeat(4, minmax(0, 1fr)); padding: 14px; }
  .poster .disc { width: 58px; height: 58px; } .poster .ic { width: 34px; height: 34px; }
}

/* Summary: one row per project, one bar for all its checklist steps. */
.meter { display: grid; grid-template-columns: 1fr auto; align-items: center; gap: 2px 10px; }
.meter small { grid-column: 1 / -1; }
.meter b { font-size: 17px; }

.block { background: var(--sheet); border: 1px solid var(--line); border-radius: var(--r); padding: 14px 16px; margin-bottom: 12px; }
.grid { display: grid; gap: 16px; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); }
.grid .wide { grid-column: 1 / -1; }

/* Project page ("Papan berkas", DESIGN.md › Project page). The profile card: title, facts, the two PICs
   with call and WhatsApp buttons, then the note and folder, split by hairlines. */
.profile .ph { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 10px; }
.kv { display: grid; grid-template-columns: 1fr 1fr; gap: 10px 16px; margin: 14px 0 0; padding-top: 14px; border-top: 1px solid var(--line); }
.kv > div:first-child { grid-column: 1 / -1; }  /* the address gets the whole line on phones */
.kv dt { font-size: 15px; color: var(--muted); }
.kv dd { margin: 0; }
/* the client's history (Riwayat klien) reuses the PICs' hairline rows */
.people, .jobs { margin-top: 14px; border-top: 1px solid var(--line); }
.people > div, .jobs > div { padding-top: 12px; }
.people > div + div, .jobs > div + div { margin-top: 12px; border-top: 1px solid var(--line); }
.people b, .people small, .jobs b, .jobs small, .foot small { display: block; }
.people small, .jobs small, .foot small { color: var(--muted); }
.two { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; margin: 10px 0 0; }
.two .btn { text-align: center; }
.foot { display: flex; flex-wrap: wrap; align-items: center; gap: 12px; margin-top: 14px; padding-top: 14px; border-top: 1px solid var(--line); }
.foot p { flex: 1 1 240px; margin: 0; }

/* The checklist: documents and steps as tiles; one still open is bold, with a dark border. */
.block { position: relative; }  /* holds the Kelola button in its corner */
.tally { display: grid; grid-template-columns: auto 1fr auto; align-items: center; gap: 12px; margin: 8px 0 0; font-weight: 600; color: var(--ink-2); }
.tally b { font-size: 28px; line-height: 1.1; color: var(--ink); }
.kelola > summary { position: absolute; top: 10px; right: 12px; }
.kelola[open] > summary { background: var(--act-soft); border-color: var(--act); color: var(--act-press); }
.tiles { display: grid; gap: 8px; margin-top: 14px; }  /* one column, numbered straight down (owner's request, 27 Sep 2026) */
.tiles .it { padding: 10px; border: 2px solid var(--ink-2); border-radius: 10px; background: var(--sheet); }
.tiles .it.done { padding: 11px; border: 1px solid var(--line); background: var(--bg); }
.tick {
  display: grid; grid-template-columns: 28px 1fr; align-items: start; gap: 2px 8px; min-height: 44px; cursor: pointer;
  font-size: 16px; line-height: 1.3; font-weight: 700; overflow-wrap: break-word;
}
.tick input { grid-row: span 2; }
.tick .n { color: var(--muted); font-weight: 600; font-variant-numeric: tabular-nums; }  /* its place in the block */
.tick small { grid-column: 2; font-size: 15px; font-weight: 400; color: var(--ink-2); }
.done .tick { font-weight: 400; color: var(--ink-2); }
.done .tick small { color: var(--muted); }
/* Kelola: each item's number, date box and Hapus, under its name. */
.mng { display: none; flex-wrap: wrap; align-items: center; gap: 8px; margin-top: 8px; }
.kelola[open] ~ div .mng { display: flex; }
.mng label { display: flex; align-items: center; gap: 8px; font-size: 15px; color: var(--muted); }
.mng input[name=selesai] { width: 7.5em; padding: 8px 10px; }
.mng select { width: auto; min-height: 44px; padding: 8px 10px; }  /* nomor: moves the item in its block */
.mng .confirm[open] { flex-basis: 100%; }  /* the warning takes the whole width once it opens */
.mng .confirm > summary { display: inline-block; }
.item { padding: 12px 0; border-top: 1px solid var(--line); }  /* Riwayat */
.item:first-of-type { border-top: 0; }
.item small { display: block; }

.list { background: var(--sheet); border: 1px solid var(--line); border-radius: var(--r); overflow: hidden; }
.list .row {
  display: grid; gap: 4px 12px; padding: 12px 14px; border-top: 1px solid var(--line);
  color: inherit; text-decoration: none; grid-template-columns: 1fr auto; transition: background-color 120ms;
}
.list .row:first-child { border-top: 0; }
.list .row:hover { background: var(--bg); }
.list .row small { display: block; color: var(--muted); }
.due { color: var(--amber); font-weight: 600; }  /* an SLF that needs renewal, in lists and on a job's profile */
.phone-label { margin-right: 6px; font-size: 15px; color: var(--muted); }  /* which date it is; laptops have heads */
.list .row b { font-size: 19px; line-height: 1.25; }
.list .head { display: none; }
.list .row > *:nth-child(even) { text-align: right; }
.list.progress .row { grid-template-columns: 1fr; gap: 6px; }
.list.progress .row > * { text-align: left; }

/* Jenis tags are outlined pills. */
.tag {
  display: inline-block; padding: 2px 9px; border-radius: 999px; vertical-align: middle; font-size: 14px; font-weight: 600;
  border: 1px solid var(--edge); background: var(--sheet); color: var(--ink-2);
}
/* Stage labels ("Titik tahap", picked with /design-shotgun on 27 Sep 2026): the stage's name in its dark tone after
   a dot that fills as the project moves (empty, a quarter, half, three quarters, full with a tick), grey to the
   Dashboard's teal (28 Sep 2026; it was green); batal is a red ring with a slash. The fill tells the stages apart
   without color; the text passes AA and the dots 3:1 on cream (DESIGN.md › Color). The Summary's Marketing rows and
   panel titles wear the same dots. */
.badge {
  position: relative; display: inline-flex; align-items: center; gap: 7px; vertical-align: middle;
  font-size: 15px; font-weight: 600; line-height: 1.3; white-space: nowrap;
}
.s-potential  { --c: #7d8799; --p: 0;   color: var(--muted); }
.s-survey     { --c: #4f9a91; --p: 25;  color: #34706a; }
.s-processing { --c: var(--teal); --p: 50; color: #1f6b63; }
.s-finalize   { --c: #1d6e66; --p: 75;  color: #175a53; }
.s-selesai    { --c: #0f5a52; --p: 100; color: #0f5a52; }
.s-batal      { --c: #d92d20; --p: 0;   color: #b42318; }
.badge::before, .viz.marketing .hbar > span:first-child::before, .viz.processing figcaption a::before,
.viz.finalize figcaption a::before, .viz.selesai figcaption a::before {
  content: ""; flex: none; box-sizing: border-box; width: 18px; height: 18px; border-radius: 50%;
  border: 2px solid var(--c); background: conic-gradient(var(--c) calc(var(--p) * 1%), transparent 0);
}
.s-selesai::after, .viz.selesai figcaption a::after {  /* the tick on a full dot */
  content: ""; position: absolute; left: 6px; top: 50%; margin-top: -6px; width: 4px; height: 8px;
  border: solid #fff; border-width: 0 2px 2px 0; transform: rotate(45deg);
}
.s-batal::after {  /* the slash through batal's ring */
  content: ""; position: absolute; left: 8px; top: 50%; margin-top: -8px; width: 2px; height: 16px;
  background: var(--c); transform: rotate(45deg);
}

.filters.add { margin: 14px 0 0; padding-top: 14px; border-top: 1px dashed var(--line); }
.filters.add input[name=nama], .filters.add .cari { flex: 3 1 220px; }

/* A dropdown you can search (base.html; owner's request, 27 Sep 2026): a text box shaped like a select, over a list
   shaped like the browser's own, with its headings. */
.cari { position: relative; }
.cari > input {
  padding-right: 36px; cursor: pointer;
  background: var(--sheet) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8'%3E%3Cpath d='M1 1l5 5 5-5' fill='none' stroke='%2333405c' stroke-width='2'/%3E%3C/svg%3E") no-repeat right 12px center;
}
.cari > ul {
  position: absolute; z-index: 20; left: 0; right: 0; top: calc(100% + 4px); max-height: min(320px, 50vh);
  overflow-y: auto; margin: 0; padding: 4px 0; list-style: none;
  background: var(--sheet); border: 1px solid var(--field); border-radius: 10px;
}
.cari li { padding: 12px; font-size: 16px; font-weight: 400; line-height: 1.3; color: var(--ink); cursor: pointer; }  /* 44px to tap */
.cari li.grup { padding-bottom: 4px; font-weight: 700; cursor: default; }
.cari .grup ~ [role=option] { padding-left: 24px; }  /* places sit under their province */
.cari li.on { background: var(--act); color: #fff; }
.cari li[aria-disabled], .cari li.kosong { color: var(--muted); cursor: default; }

.form label { display: block; margin-bottom: 16px; font-size: 16px; font-weight: 600; color: var(--ink-2); }
.form label input, .form label select { margin-top: 6px; font-weight: 400; color: var(--ink); }
.form label.check { display: flex; align-items: center; gap: 10px; font-weight: 400; }
.form label.check input { width: 28px; flex: none; }
.form h2 { margin-top: 24px; }

.login { max-width: 420px; margin: 40px auto; background: var(--sheet); border: 1px solid var(--line); border-radius: var(--r); padding: 28px; text-align: center; }
.login .btn { margin: 18px 0; }
.login img { display: block; margin: 0 auto 10px; }
.login .small { font-size: 15px; }

nav.bottom {
  position: fixed; bottom: 0; left: 0; right: 0; display: flex; background: var(--sheet);
  border-top: 1px solid var(--line); padding-bottom: env(safe-area-inset-bottom);
}
nav.bottom a { flex: 1; text-align: center; padding: 13px 2px; font-size: 15px; color: var(--ink-2); text-decoration: none; }
nav.bottom a.on { color: var(--act); font-weight: 700; box-shadow: inset 0 3px 0 var(--act); }

@media (prefers-reduced-motion: reduce) { * { transition: none !important; } }

@media (min-width: 720px) {
  body { padding-bottom: 0; }
  nav.top { display: flex; flex: 1; }  /* pushes the person, date and Keluar right, even with no menu (Masuk) */
  nav.bottom { display: none; }
  header .today { display: flex; }
  main { padding: 24px; }
  .list .row { grid-template-columns: 2.1fr .9fr 1.7fr 1fr 1.3fr; align-items: center; }
  .list .row > *:nth-child(even) { text-align: left; }
  .list .head { display: grid; font-size: 15px; font-weight: 600; color: var(--ink-2); background: var(--bg); padding: 10px 14px; }
  .list .head:hover { background: var(--bg); }
  .list.progress .row { grid-template-columns: 2.2fr 2fr 1.6fr; gap: 6px 24px; }
  .list.moved .row { grid-template-columns: 2.4fr 1fr 1fr 1fr; }  /* a Selesai tab: no SLF column */
  .list.leads .row { grid-template-columns: 2fr .8fr .9fr 1.3fr 1.1fr 1.4fr; }  /* Marketing: + Tanggal Survey */
  .phone-label { display: none; }
  .viz.wide { grid-column: span 2; }
  .cols .axis .full { display: block; }
  .cols .axis .short { display: none; }
  .kv { grid-template-columns: 2fr 1fr 1fr 1fr; }
  .kv > div:first-child { grid-column: auto; }
  .people { display: grid; grid-template-columns: 1fr 1fr; gap: 24px; }
  .people > div + div { margin-top: 0; border-top: 0; }
  .two { max-width: 340px; }
  .tick { font-size: 17px; }
  .cari li { padding-top: 9px; padding-bottom: 9px; }  /* a mouse needs less; closer to the browser's own list */
}
