/* Module layouts (issue #227: the base, the menu and the shared components are in design.css; colors are its tokens). */
.notice{background:var(--surface);border:1px solid var(--line);border-radius:12px;padding:28px;margin-top:20px}.notice-head{display:flex;justify-content:space-between;gap:20px;align-items:flex-start;border-bottom:1px solid var(--line);padding-bottom:14px}.notice-head h2{margin:6px 0 4px;text-transform:capitalize}.notice-meta{text-align:right;font-size:12px;line-height:1.8;color:var(--text-2)}.notice-unit{margin:16px 0 4px}.notices-actions{margin-top:18px}@media(max-width:700px){.notice{padding:16px}.notice-head{flex-direction:column}.notice-meta{text-align:left}}@media print{.notice{border:0;border-radius:0;margin:0;padding:0;break-after:page}.notice:last-child{break-after:auto}}.slips{display:grid;grid-template-columns:1fr 1fr;gap:14px}.slip{border:1px dashed var(--border-strong);border-radius:8px;padding:12px 14px;font-size:12px;break-inside:avoid}.slip-title{font-weight:650;color:var(--text-2);margin-bottom:6px;text-transform:uppercase;letter-spacing:.6px;font-size:11px}.slip div:not(.slip-title){display:flex;justify-content:space-between;gap:12px;padding:3px 0;border-bottom:1px solid var(--border)}.slip div span{color:var(--muted)}.slip div strong{text-align:right;font-weight:600}@media(max-width:700px){.slips{grid-template-columns:1fr}}.mapping-grid{display:grid;grid-template-columns:repeat(3,1fr);gap:12px 14px;align-items:end;margin-bottom:8px}@media(max-width:700px){.mapping-grid{grid-template-columns:1fr}}.temp-password{font:600 22px/1.4 ui-monospace,SFMono-Regular,Menlo,Consolas,monospace;letter-spacing:1px;background:var(--surface-3);border:1px dashed var(--border-strong);border-radius:8px;padding:12px;text-align:center;user-select:all}.password-field{position:relative;display:block}.password-field input{padding-right:46px}.reveal{position:absolute;top:50%;right:6px;transform:translateY(-50%);width:34px;height:34px;border:0;border-radius:6px;background:transparent center/20px no-repeat url(eye.svg)}.reveal:hover{background-color:var(--surface-3)}.reveal:focus-visible{outline:2px solid var(--teal);outline-offset:1px}.reveal.shown{background-image:url(eye-off.svg)}
.scope-bar{display:flex;align-items:flex-end;gap:18px;margin-bottom:20px}.scope-bar label{min-width:300px}.scope-bar p{margin:0 0 10px}@media(max-width:700px){.scope-bar{display:block}.scope-bar label{min-width:0}}
.slip .ips{float:right;margin:0 0 6px 12px;text-align:center}.slip .ips svg{display:block;width:34mm;height:34mm}.slip .ips figcaption{font-size:9px;letter-spacing:.5px;color:var(--text-2);margin-top:2px}.slip::after{content:"";display:block;clear:both}
.print-title{margin:0 0 12px;font-weight:600;color:var(--text-2)}
.card-grid{display:grid;grid-template-columns:1fr 1fr;gap:14px 24px}.address-grid{display:grid;grid-template-columns:2fr 1fr 1fr 1fr;gap:14px;align-items:end;margin-bottom:18px}.address-grid .wide{grid-column:span 1}.address-grid .checks{grid-column:1/-1;display:flex;flex-wrap:wrap;gap:10px 22px}.check{display:flex;align-items:center;gap:8px;font-size:12px}.check input{width:auto}@media(max-width:700px){.card-grid,.address-grid{grid-template-columns:1fr}}
.kinds{border:1px solid var(--line);border-radius:8px;padding:10px 12px;display:flex;flex-wrap:wrap;gap:8px 18px}.kinds legend{font-size:12px;color:var(--muted);padding:0 4px}
.tabs{display:flex;flex-wrap:wrap;gap:6px;margin:0 0 20px;border-bottom:1px solid var(--line)}.tabs button{border:0;background:none;padding:10px 14px;color:var(--muted);border-bottom:2px solid transparent;margin-bottom:-1px}.tabs button.active{color:var(--primary);border-bottom-color:var(--teal);font-weight:650}.facts>div{display:flex;justify-content:space-between;gap:16px;padding:9px 0;border-bottom:1px solid var(--border);font-size:12px}.facts>div:last-child{border:0}.facts span{color:var(--muted)}.facts strong{text-align:right;font-weight:600}.actions.wrap{flex-wrap:wrap;margin:0 0 20px}button.link{border:0;background:none;padding:0;color:var(--primary);font-weight:600;text-align:left;cursor:pointer}button.link:hover{text-decoration:underline}
.today{list-style:none;margin:0;padding:0}.today-item{display:flex;justify-content:space-between;gap:16px;align-items:flex-start;padding:12px 0;border-bottom:1px solid var(--border)}.today-item:last-child{border:0}.today-item .count{min-width:34px;text-align:center;background:var(--primary-soft);color:var(--primary);border-radius:20px;padding:4px 10px;font-weight:700}.chips{display:flex;flex-wrap:wrap;gap:6px 8px;margin-top:8px;align-items:center}.chip{border:1px solid var(--line);background:var(--surface);border-radius:16px;padding:5px 11px;font-size:12px;color:var(--text-2);cursor:pointer}.chip:hover{border-color:var(--teal);color:var(--primary)}
.filters{display:flex;flex-wrap:wrap;gap:8px;margin-bottom:16px}.filters select,.filters input{width:auto;min-width:140px;padding:8px}.filters input[name=q]{min-width:220px}a.button{display:inline-block;text-decoration:none;font-size:13px}.status.new{background:var(--primary-soft);color:var(--primary)}.status.sent{background:var(--warning-soft);color:var(--warning)}.status.done{background:var(--success-soft);color:var(--success)}.status.closed{background:var(--border);color:var(--muted)}.inline{display:flex;gap:6px}.inline input{flex:1}textarea{width:100%;border:1px solid var(--border-strong);border-radius:6px;padding:11px;font:inherit;color:var(--text)}.signatures{display:grid;grid-template-columns:repeat(3,1fr);gap:20px;margin-top:48px}.signatures div{border-top:1px solid var(--text-2);padding-top:6px;text-align:center;font-size:12px;color:var(--text-2)}
.cal-bar{display:flex;justify-content:space-between;flex-wrap:wrap;gap:10px;margin-bottom:14px}.cal-title{font-size:16px;margin-left:8px}.cal-grid{display:grid;grid-template-columns:repeat(7,minmax(0,1fr));border-top:1px solid var(--line);border-left:1px solid var(--line)}.cal-head{padding:8px;font-size:11px;font-weight:650;color:var(--muted);text-transform:uppercase;border-right:1px solid var(--line);border-bottom:1px solid var(--line);background:var(--surface-2)}.cal-cell{min-height:110px;padding:6px;border-right:1px solid var(--line);border-bottom:1px solid var(--line);display:flex;flex-direction:column;gap:4px;min-width:0}.cal-cell.week{min-height:260px}.cal-cell.other{background:var(--surface-2);color:var(--muted-2)}.cal-cell.other .cal-day .link{color:var(--muted-2)}.cal-cell.today,.today-box{background:var(--primary-soft)}.cal-cell.today .cal-day .link{font-weight:750;color:var(--teal)}.cal-day{display:flex;justify-content:space-between;align-items:center}.cal-add{border:0;background:none;color:var(--teal);font-size:16px;padding:0 4px}.duty{display:block;width:100%;text-align:left;border:0;border-left:3px solid var(--teal);background:var(--primary-soft);border-radius:4px;padding:3px 6px;font-size:11px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;color:var(--text-2)}.duty.private{border-left-color:var(--warning);background:var(--warning-soft)}.duty.done{opacity:.55;text-decoration:line-through}.duty-card{display:grid;grid-template-columns:150px 1fr;gap:12px;padding:12px 0;border-bottom:1px solid var(--border)}.duty-card.done{opacity:.6}.duty-card.done .link{text-decoration:line-through}.rich p{margin:4px 0}.rich ul{margin:4px 0;padding-left:20px}.toolbar{display:flex;gap:6px}.toolbar button{padding:4px 10px}@media(max-width:700px){.cal-cell{min-height:70px}.duty{font-size:10px}.duty-card{grid-template-columns:1fr}}
.journal-text{white-space:pre-line;display:inline-block;max-width:420px}td .journal-text{white-space:pre-line}.print-only{display:none}@media print{.print-only{display:block;margin:0 0 12px}}
.print-only{display:none}@media print{.print-only{display:block;margin:0 0 12px}.cards{grid-template-columns:repeat(4,1fr);gap:8px;margin-bottom:12px}.card{padding:8px}.card strong{font-size:16px;margin:4px 0}}
.status.urgent{background:var(--danger-soft);color:var(--danger)}td.num{text-align:right;white-space:nowrap}.buildings-map{height:380px;border:1px solid var(--line);border-radius:10px;z-index:0}.map-legend{display:flex;flex-wrap:wrap;gap:16px;margin-top:10px;font-size:12px;color:var(--muted)}.map-key{display:flex;align-items:center;gap:6px}.map-key i{width:10px;height:10px;border-radius:50%;display:inline-block}.map-key i.late{background:var(--danger)}.map-key i.overdue{background:var(--warning)}.map-key i.ok{background:var(--primary)}@media print{.buildings-map,.map-legend{display:none}}.form-grid{display:grid;grid-template-columns:1fr 1fr;gap:12px}.form-grid .wide{grid-column:1/-1}@media(max-width:700px){.form-grid{grid-template-columns:1fr}}.ubl-table select{min-width:200px;max-width:280px;display:block}.ubl-table .ubl-fund{margin-top:6px}.ubl-table .ubl-note{display:block;max-width:300px;margin-top:4px}.notice-head h2.as-written{text-transform:none}table.rates{width:auto;margin:12px 0 0 auto;font-size:13px;color:var(--muted)}table.rates td{padding:2px 0 2px 18px;border:0}
.check-table td{padding:6px 8px;vertical-align:top}.check-table td:first-child input{width:64px}.check-table td:nth-child(2){min-width:340px}.check-table td:nth-child(2) input{width:100%}.check-table td:nth-child(4) input{min-width:200px}.wrap{white-space:normal;display:inline-block;max-width:520px}
.board-title{font-size:34px;letter-spacing:-.8px;margin:28px 0 14px}.board-body{font-size:17px;line-height:1.6}.board-sign{margin-top:48px;text-align:right}
.attachments{margin-top:18px;border-top:1px solid var(--line);padding-top:6px}.attach-items{margin:6px 0;padding-left:18px;line-height:1.9}.attach-add{display:inline-block;cursor:pointer;margin-top:6px}

/* A proposal read from a PDF or a photo (issue #103); the form column never grows past the screen. */
#invoice-form { grid-template-columns: minmax(0, 1fr); }
.scan-note { overflow-wrap: anywhere; border: 1px solid var(--line); border-radius: 8px; padding: 10px 14px; margin: 0 0 14px; background: var(--surface-2); }
.scan-note p { margin: 4px 0; }
.scan-text { white-space: pre-wrap; max-height: 260px; overflow: auto; font-size: 12px; margin: 6px 0; }
@media (max-width: 700px) { .total-row { flex-wrap: wrap; gap: 12px; } }
/* Contacts of a unit (issue #107). */
.contact-card { border: 1px solid var(--line); border-radius: 8px; padding: 10px 12px; margin: 0 0 10px; }
.contact-head { display: flex; justify-content: space-between; gap: 10px; align-items: flex-start; flex-wrap: wrap; }
.contact-card .chips { margin-top: 6px; }
.contact-slot form { margin-top: 10px; }
.consent-history { margin: 6px 0 0; padding-left: 18px; font-size: 12px; }
/* The public voting page (issue #109): one column, big buttons, made for a phone. */
.vote-body { background: var(--bg); }
.vote-page { max-width: 560px; margin: 0 auto; padding: 24px 16px 40px; display: grid; gap: 14px; }
.vote-head { display: block; margin: 0; }
.vote-head h1 { font-size: 24px; letter-spacing: -.4px; margin: 6px 0; }
.vote-note { white-space: pre-line; color: var(--text-2); }
.vote-card { background: white; border: 1px solid var(--line); border-radius: 12px; padding: 16px; }
.vote-card h2 { margin-bottom: 6px; }
.vote-options { display: grid; gap: 10px; margin-top: 12px; }
.vote-option { font: inherit; font-size: 17px; padding: 14px; border-radius: 10px; border: 1px solid var(--border-strong); background: white; color: var(--text-2); text-align: left; }
.vote-option.chosen { background: var(--teal); border-color: var(--teal); color: white; font-weight: 650; }
.vote-option:disabled { opacity: .6; }
.vote-demo { background: var(--warning-soft); border: 1px solid var(--warning-line); color: #92400e; border-radius: 8px; padding: 10px; }
.vote-done { background: var(--success-soft); color: var(--success); border-radius: 8px; padding: 12px; }
.vote-foot { text-align: center; }
.vote-result { display: grid; grid-template-columns: 1fr auto; gap: 4px 10px; margin: 10px 0; }
.vote-bar { grid-column: 1 / -1; height: 8px; background: var(--border); border-radius: 4px; overflow: hidden; }
.vote-bar i { display: block; height: 100%; background: var(--teal); }
.vote-bar i.w0{width:0%}.vote-bar i.w5{width:5%}.vote-bar i.w10{width:10%}.vote-bar i.w15{width:15%}.vote-bar i.w20{width:20%}.vote-bar i.w25{width:25%}.vote-bar i.w30{width:30%}.vote-bar i.w35{width:35%}.vote-bar i.w40{width:40%}.vote-bar i.w45{width:45%}.vote-bar i.w50{width:50%}.vote-bar i.w55{width:55%}.vote-bar i.w60{width:60%}.vote-bar i.w65{width:65%}.vote-bar i.w70{width:70%}.vote-bar i.w75{width:75%}.vote-bar i.w80{width:80%}.vote-bar i.w85{width:85%}.vote-bar i.w90{width:90%}.vote-bar i.w95{width:95%}.vote-bar i.w100{width:100%}
.poll-share textarea { font-size: 13px; margin-bottom: 8px; }
#poll-options { display: grid; gap: 6px; margin-bottom: 8px; }
.approval { margin: 0 0 6px; display: grid; gap: 6px; justify-items: start; max-width: 280px; white-space: normal; }
.approval .status { white-space: normal; line-height: 1.4; }
.approval .actions { flex-wrap: wrap; }
/* Dashboard tiles (issue #113, colours #115): the app's own palette; red only when something waits. */
.tile-groups { display: grid; grid-template-columns: 2fr 2fr 3fr; gap: 16px; margin-bottom: 20px; }
.tile-group { background: white; border: 1px solid var(--line); border-radius: 12px; padding: 12px 14px 14px; }
.tile-group h3 { margin: 0 0 8px; font-size: 11px; letter-spacing: .8px; text-transform: uppercase; font-weight: 700; color: var(--muted); }
.tile-row { display: flex; gap: 8px; }
.tile { flex: 1; background: var(--primary-soft); border: 1px solid transparent; border-radius: 8px; color: var(--text-2); padding: 10px 8px; display: grid; gap: 2px; text-align: center; font: inherit; }
.tile:hover { border-color: var(--teal); }
.tile strong { font-size: 26px; font-weight: 700; color: var(--teal); }
.tile span { font-size: 12px; color: var(--muted); }
.tile.waiting { background: var(--danger-soft); }
.tile.waiting strong { color: var(--danger); }
@media (max-width: 1050px) { .tile-groups { grid-template-columns: 1fr; } }
/* Offers of contractors in a vote (issue #122) */
#offer-rows { display: grid; gap: 12px; width: 100%; }
.offer-row { display: grid; grid-template-columns: minmax(0, 2fr) minmax(0, 1fr); gap: 8px 12px; padding-bottom: 12px; border-bottom: 1px solid var(--line); }
.offer-row .wide { grid-column: 1 / -1; }
.vote-offer { padding: 10px 0; border-bottom: 1px solid var(--line); line-height: 1.6; }
.vote-offer:last-child { border-bottom: 0; }
@media (max-width: 700px) { .offer-row { grid-template-columns: minmax(0, 1fr); } }
/* The worker's page (issue #126) */
.done-card { border-color: var(--success-line); }
.worker-share { margin-top: 10px; }
.worker-share .vote-note, .modal-note { overflow-wrap: anywhere; white-space: pre-line; }
.done-form { margin-top: 10px; }
.wrap-text { white-space: pre-line; overflow-wrap: anywhere; display: inline-block; max-width: 420px; }
.talk-log { display: grid; gap: 6px; margin: 10px 0; }
.talk-log p { margin: 0; white-space: pre-line; overflow-wrap: anywhere; max-width: 640px; }
.talk-log p.assistant, .talk-log p.manager { justify-self: end; text-align: right; }

.notice-viber{display:flex;gap:14px;align-items:center;border:1px solid var(--border-strong);border-radius:8px;padding:10px 12px;margin:14px 0;break-inside:avoid}.notice-viber img{flex:none}.notice-viber p{margin:4px 0}
.production .demo-note,.production .demo-banner,.production .sidebar-bottom .pill,.production .sidebar-bottom>p{display:none}
.notice-viber{justify-content:space-between}.notice-viber-link{font-size:15px;font-weight:700;margin:6px 0}.notice-viber figure{margin:0;text-align:center;flex:none}.notice-viber figcaption{font-size:10px;color:var(--muted)}.qr-link{font-size:12px;align-self:center;color:var(--muted)}
.link-line{display:block;overflow-wrap:anywhere}
.assistant-page{background:var(--bg);margin:0}.assistant-main{max-width:760px;margin:0 auto;padding:16px;display:grid;gap:16px}.assistant-head{display:flex;justify-content:space-between;align-items:center;gap:12px}.assistant-head h1{margin:2px 0 0}
.assistant-log{display:grid;gap:10px;max-height:60vh;overflow-y:auto;padding:4px}.assistant-bubble{max-width:88%;padding:10px 12px;border-radius:12px;background:var(--surface-3)}.assistant-bubble p{margin:0;overflow-wrap:anywhere}.assistant-bubble.mine{justify-self:end;background:var(--primary);color:#fff}.assistant-bubble.ai{justify-self:start}
.assistant-proposal{display:grid;gap:8px;margin-top:10px}.assistant-proposal textarea{min-height:60px}.assistant-order{display:flex;gap:8px;margin-top:12px;align-items:flex-end}.assistant-order textarea{flex:1;min-height:52px}
.assistant-rule{display:flex;justify-content:space-between;gap:12px;align-items:center;border-top:1px solid var(--border);padding:10px 0}.assistant-rule p{margin:0}
/* The two windows in the corners, like a messenger (issue #166) */
.dock{position:fixed;bottom:16px;z-index:40;display:flex;flex-direction:column;gap:8px;max-width:calc(100vw - 32px)}.dock-left{left:16px;align-items:flex-start}.dock-right{right:16px;align-items:flex-end}
.dock-button{border:0;border-radius:999px;padding:10px 16px;background:var(--teal);color:#fff;font-weight:600;box-shadow:0 4px 14px rgba(0,0,0,.18);cursor:pointer;display:flex;gap:8px;align-items:center}.dock-button.active{background:var(--primary-hover)}
.dock-badge{background:var(--danger);color:#fff;border-radius:999px;min-width:20px;padding:1px 6px;font-size:12px;text-align:center}
.dock-panel{width:380px;max-width:calc(100vw - 32px);height:min(560px,calc(100vh - 110px));background:#fff;border:1px solid var(--border);border-radius:14px;box-shadow:0 10px 30px rgba(0,0,0,.18);display:flex;flex-direction:column;overflow:hidden}
.dock-head{display:flex;justify-content:space-between;align-items:center;gap:8px;padding:10px 12px;background:var(--teal);color:#fff}.dock-head strong{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.dock-close{border:0;background:transparent;color:#fff;font-size:20px;line-height:1;cursor:pointer;padding:0 6px}
.dock-body{flex:1;overflow-y:auto;padding:10px;display:grid;gap:8px;align-content:start}
.dock-talk{display:grid;gap:2px;text-align:left;border:1px solid var(--border);border-radius:10px;background:#fff;padding:8px 10px;cursor:pointer}.dock-talk:hover{background:var(--primary-soft)}
.dock-back{justify-self:start;border:1px solid var(--teal);border-radius:999px;background:#fff;color:var(--teal);cursor:pointer;padding:5px 12px;font:inherit;font-weight:700;font-size:15px}.dock-back:hover{background:var(--primary-soft)}  /* bold, so it is seen (issue #215) */
.dock-search{width:100%;box-sizing:border-box;padding:7px 10px;border:1px solid var(--border-strong);border-radius:10px;font:inherit;position:sticky;top:-10px;z-index:2;
  background:#fff;box-shadow:0 -10px 0 #fff,0 4px 8px -6px rgba(0,0,0,.25)}
.dock-panel{position:relative}
.dock-top{position:absolute;right:16px;bottom:16px;z-index:3;width:38px;height:38px;border-radius:50%;border:0;background:var(--teal);color:#fff;font-size:18px;
  cursor:pointer;box-shadow:0 4px 12px rgba(0,0,0,.25)}
.dock-results{display:grid;gap:6px}
.dock-log{margin:0;max-height:none}.dock-log p{background:var(--surface-3);border-radius:10px;padding:6px 8px;max-width:85%}.dock-log p.manager,.dock-log p.assistant{background:var(--primary-soft)}
.dock-reply{display:flex;gap:8px;align-items:flex-end}.dock-reply textarea{flex:1;min-height:48px}
.dock-body .assistant-chat,.dock-body .assistant-rules{margin:0;padding:10px;box-shadow:none}.dock-body .assistant-log{max-height:none}.dock-body h2{font-size:15px}
@media (max-width:700px){.dock-panel{position:fixed;inset:0;width:auto;max-width:none;height:auto;border-radius:0;z-index:41}.dock{bottom:12px}.dock-left{left:12px}.dock-right{right:12px}body.dock-open .dock-button{display:none}}
/* The building's thread (issue #178) */
.thread-day{font-size:13px;color:var(--muted);margin:16px 0 6px;text-transform:uppercase;letter-spacing:.04em}.thread-item{display:grid;grid-template-columns:28px 1fr;gap:8px;padding:8px 0;border-top:1px solid var(--border)}
.thread-item p{margin:0}.thread-icon{font-size:18px;line-height:1.4;text-align:center}.thread-item.mail_in .thread-icon,.thread-item.message_in .thread-icon{color:var(--teal)}
.dock-tabs{display:flex;gap:4px;padding:8px 10px 0;border-bottom:1px solid var(--border)}.dock-tabs button{border:0;background:none;padding:6px 10px;border-radius:8px 8px 0 0;color:var(--muted);cursor:pointer}.dock-tabs button.active{background:var(--primary-soft);color:var(--primary);font-weight:650}
/* The assistants in the small windows (issue #189): like a messenger, the talk scrolls and opens on the last message,
   the box to write in stays at the bottom. */
#dock-ai-body,#dock-rules-body{display:flex;flex-direction:column;overflow:hidden}#dock-ai-body>*,#dock-rules-body>*{flex:none}
#dock-ai-body .assistant-chat,#dock-rules-body .assistant-chat{flex:1 1 auto;min-height:0;display:flex;flex-direction:column}
#dock-ai-body .assistant-log,#dock-rules-body .assistant-log{flex:1 1 auto;min-height:0;overflow-y:auto;max-height:none}
#dock-ai-body .assistant-order,#dock-rules-body .assistant-order{flex:none}#dock-rules-body .assistant-rules[open]{max-height:40%;overflow-y:auto}
/* A bigger window on a computer (issue #198): half the screen at most, so the two fit side by side; not on a phone. */
.dock-head-buttons{display:flex;align-items:center;gap:2px}.dock-widen{font-size:17px}
.dock-panel.wide{width:min(760px,calc(50vw - 24px));height:min(88vh,calc(100vh - 90px))}
@media (max-width:700px){.dock-widen{display:none}.dock-panel.wide{width:auto;height:auto}}
/* Issue #227: module components in the new design (these come after the module rules above, so they win). */
.bar-track i.w5{width:5%}.bar-track i.w10{width:10%}.bar-track i.w15{width:15%}.bar-track i.w20{width:20%}.bar-track i.w25{width:25%}.bar-track i.w30{width:30%}.bar-track i.w35{width:35%}.bar-track i.w40{width:40%}.bar-track i.w45{width:45%}.bar-track i.w50{width:50%}.bar-track i.w55{width:55%}.bar-track i.w60{width:60%}.bar-track i.w65{width:65%}.bar-track i.w70{width:70%}.bar-track i.w75{width:75%}.bar-track i.w80{width:80%}.bar-track i.w85{width:85%}.bar-track i.w90{width:90%}.bar-track i.w95{width:95%}.bar-track i.w100{width:100%}
.today{display:grid;gap:2px}.today-item{padding:12px 0;align-items:center}.today-item strong{font-weight:600;font-size:13.5px;color:var(--text)}
.today-item .count{min-width:30px;padding:3px 9px;font-size:12.5px;border-radius:999px}
.chip{border:1px solid var(--border);background:var(--surface);border-radius:999px;padding:3px 10px;font-size:12.5px;color:var(--text-2);transition:all var(--fast) var(--ease)}
.chip:hover{border-color:var(--primary-line);background:var(--primary-soft);color:var(--primary)}
.tabs{gap:2px;margin:0 0 20px;border-bottom:1px solid var(--border);overflow-x:auto;flex-wrap:nowrap;scrollbar-width:none}
.tabs button{padding:10px 12px;font-size:13.5px;font-weight:500;color:var(--muted);white-space:nowrap;border-radius:var(--r) var(--r) 0 0;transition:color var(--fast) var(--ease)}
.tabs button:hover{color:var(--text)}
.tabs button.active{color:var(--primary);border-bottom-color:var(--primary);font-weight:600}
.filters{gap:8px;align-items:center;padding:10px;margin-bottom:16px;background:var(--surface-2);border:1px solid var(--border);border-radius:var(--r-lg)}
.filters select,.filters input{min-height:34px;padding:6px 10px;font-size:13px}
textarea{border-radius:var(--r);padding:9px 11px;min-height:38px}
.scope-bar{align-items:center;padding:12px 14px;margin:24px 0 20px;background:var(--surface);border:1px solid var(--border);border-radius:var(--r-lg);box-shadow:var(--shadow-xs)}
.scope-bar label{display:flex;align-items:center;gap:10px;min-width:320px}
.scope-bar label select{flex:1}
.scope-bar p{margin:0}
.status.new{border-color:var(--primary-line)}.status.sent{border-color:var(--warning-line)}.status.done{border-color:var(--success-line)}.status.closed{border-color:var(--border);background:var(--surface-3)}
.notice{border-radius:var(--r-lg);box-shadow:var(--shadow-xs)}
.actions.wrap{margin:0 0 16px}
@media(max-width:640px){.scope-bar{display:grid;gap:8px}.scope-bar label{min-width:0;display:grid}}

/* the corner windows start right of the menu (issue #227) */
body:has(.app-shell:not([hidden])) .dock-left{left:calc(var(--sidebar-w) + 16px)}
body:has(.app-shell.collapsed:not([hidden])) .dock-left{left:calc(var(--sidebar-w-collapsed) + 16px)}
@media (max-width:900px){body:has(.app-shell:not([hidden])) .dock-left{left:12px}}
/* the "more" menu of a table row (issue #227) */
td .actions,td .actions.wrap{display:flex;flex-wrap:nowrap;margin:0;max-width:none}
.row-menu{position:relative}
.row-menu>summary{list-style:none;width:30px;height:30px;color:var(--muted);border:1px solid var(--border);background:var(--surface)}
.row-menu>summary::-webkit-details-marker{display:none}
.row-menu[open]>summary{background:var(--surface-3);color:var(--text)}
.row-menu-list{position:absolute;right:0;top:calc(100% + 4px);z-index:15;min-width:190px;display:grid;gap:1px;padding:5px;background:var(--surface);
  border:1px solid var(--border);border-radius:var(--r-lg);box-shadow:var(--shadow-lg);animation:modal-in .14s var(--ease)}
.row-menu-list>button,.row-menu-list>a{justify-content:flex-start;width:100%;min-height:32px;border:0!important;box-shadow:none!important;background:none;
  color:var(--text-2);font-weight:500;border-radius:var(--r-sm);padding:6px 10px!important;text-align:left}
.row-menu-list>button:hover,.row-menu-list>a:hover{background:var(--surface-3);color:var(--text)}
.table-wrap:has(.row-menu[open]){overflow:visible}
/* AI troškovi (issue #288): the owner's screen */
.ai-cost-head{display:flex;flex-wrap:wrap;gap:8px 16px;align-items:center;margin-bottom:12px}
.ai-cost-figures{grid-template-columns:repeat(auto-fit,minmax(220px,1fr));gap:0 24px;margin-bottom:8px}
.ai-cost-bar{display:block;width:160px;max-width:30vw;height:8px;border:0;border-radius:4px;background:var(--primary-soft);appearance:none;-webkit-appearance:none;overflow:hidden}
.ai-cost-bar::-webkit-progress-bar{background:var(--primary-soft)}
.ai-cost-bar::-webkit-progress-value{background:var(--primary);border-radius:4px}
.ai-cost-bar::-moz-progress-bar{background:var(--primary);border-radius:4px}
/* the AI assistant and the conversations in the new design (issue #227): a dark header like the menu, the AI on the left, you on the right */
.dock-button{background:var(--sidebar);border:1px solid var(--sidebar-3);padding:9px 16px;box-shadow:var(--shadow-md);font-size:13.5px;transition:transform var(--fast) var(--ease),background var(--fast) var(--ease)}
.dock-button:hover{transform:translateY(-1px);background:var(--sidebar-2)}
.dock-button.active{background:var(--primary);border-color:var(--primary)}
.dock-panel{border-radius:var(--r-xl);border:1px solid var(--border);box-shadow:var(--shadow-lg);animation:modal-in .18s var(--ease)}
.dock-head{background:var(--sidebar);padding:12px 14px;color:var(--sidebar-strong)}
.dock-head strong{font-weight:600;font-size:14px}
.dock-close,.dock-widen{border-radius:var(--r-sm);opacity:.8}.dock-close:hover,.dock-widen:hover{opacity:1;background:rgba(255,255,255,.08)}
.dock-body{padding:12px;gap:8px;background:var(--surface)}
.dock-tabs{padding:8px 12px 0;background:var(--surface)}
.dock-tabs button{padding:7px 12px;font-weight:500}
.dock-tabs button.active{background:var(--primary-soft);color:var(--primary);font-weight:600}
.dock-talk{border-radius:var(--r-lg);padding:10px 12px;transition:border-color var(--fast) var(--ease),background var(--fast) var(--ease)}
.dock-talk:hover{border-color:var(--primary-line);background:var(--primary-soft)}
.dock-search{border-radius:var(--r);min-height:36px}
.dock-back{border-color:var(--border-strong);color:var(--text-2);font-size:13.5px;font-weight:600;padding:5px 12px}
.dock-back:hover{background:var(--surface-3)}
.dock-top{background:var(--sidebar)}
.dock-log{gap:8px}
.dock-log p,.assistant-bubble{border-radius:14px;padding:9px 12px;line-height:1.5;font-size:13.5px;box-shadow:var(--shadow-xs)}
.dock-log p{background:var(--surface-3);border-bottom-left-radius:4px}
.dock-log p.manager,.dock-log p.assistant{background:var(--primary);color:#fff;border-bottom-left-radius:14px;border-bottom-right-radius:4px}
.dock-log p.manager .help,.dock-log p.assistant .help{color:rgba(255,255,255,.75)}
.assistant-log{gap:10px;padding:6px 2px}
.assistant-bubble{background:var(--surface-3);border-bottom-left-radius:4px}
.assistant-bubble.mine{background:var(--primary);color:#fff;border-bottom-left-radius:14px;border-bottom-right-radius:4px}
.assistant-bubble.mine .help{color:rgba(255,255,255,.75)}
.assistant-proposal{padding:10px;margin-top:10px;border:1px solid var(--primary-line);border-radius:var(--r-lg);background:var(--primary-soft)}
.assistant-order{padding-top:10px;border-top:1px solid var(--border)}
.assistant-order textarea,.dock-reply textarea{border-radius:var(--r-lg)}
.assistant-page .vote-card,.assistant-chat{background:var(--surface);border:1px solid var(--border);border-radius:var(--r-xl);box-shadow:var(--shadow-xs)}
.vote-card{border-radius:var(--r-xl);box-shadow:var(--shadow-xs)}

/* ---- the "+" of the AI window: a photo, a camera shot or a file with the message (issue #245) ---- */
.assistant-order{align-items:flex-end}
.assistant-attach{position:relative;flex:none}
.assistant-plus{width:40px;height:40px;border:1px solid var(--border);border-radius:999px;background:var(--surface);color:var(--text-2)}
.assistant-plus[aria-expanded="true"]{background:var(--primary-soft);color:var(--primary);border-color:var(--primary-line)}
.assistant-menu{position:absolute;bottom:calc(100% + 8px);left:0;z-index:30;display:grid;gap:2px;min-width:240px;padding:6px;
  background:var(--surface);border:1px solid var(--border);border-radius:var(--r-lg);box-shadow:var(--shadow-md)}
.assistant-menu[hidden]{display:none}
.assistant-menu button{display:flex;align-items:center;gap:10px;padding:9px 10px;border:0;border-radius:var(--r);background:none;text-align:left;
  font-size:13.5px;color:var(--text)}
.assistant-menu button:hover,.assistant-menu button:focus-visible{background:var(--surface-2)}
.assistant-menu .icon{width:17px;height:17px;color:var(--text-2)}
.assistant-compose{flex:1;min-width:0;display:grid;gap:6px}
.assistant-compose textarea{width:100%}
.assistant-chosen{display:flex;align-items:center;gap:6px;max-width:100%;padding:3px 4px 3px 10px;border-radius:999px;background:var(--surface-3);
  font-size:12.5px;color:var(--text-2)}
.assistant-chosen>span{min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.assistant-chosen .icon{width:14px;height:14px;flex:none}
.assistant-chosen .icon-button{width:26px;height:26px}
.assistant-photo img{display:block;max-width:min(240px,100%);max-height:180px;border-radius:10px;margin-bottom:6px}
.assistant-file{display:inline-flex;align-items:center;gap:6px;margin-bottom:6px;font-size:13px;color:inherit;text-decoration:underline;overflow-wrap:anywhere}
.assistant-file .icon{width:14px;height:14px;flex:none}
.assistant-file span{opacity:.75;text-decoration:none}
.assistant-bubble.mine .assistant-file{color:#fff}

.mailbox-states{display:grid;grid-template-columns:repeat(auto-fit,minmax(180px,1fr));gap:10px;margin:0 0 18px}.mailbox-states>div{display:flex;flex-direction:column;align-items:flex-start;gap:6px;border:1px solid var(--border);border-radius:8px;padding:10px 12px;background:var(--surface-2);min-width:0}.mailbox-states .error{overflow-wrap:anywhere}.mailbox-step{border-top:1px solid var(--border);padding-top:14px;margin-top:14px}.step-number{display:inline-flex;align-items:center;justify-content:center;width:22px;height:22px;border-radius:50%;background:var(--primary-soft);color:var(--primary);font-size:12px;font-weight:700;margin-right:6px}.mailbox-switch{display:flex;justify-content:space-between;align-items:center;gap:14px;padding:10px 0;border-bottom:1px solid var(--border)}.mailbox-switch button{flex:none}.mailbox-problem{border:1px solid var(--warning-line);background:var(--warning-soft);border-radius:8px;padding:10px 12px;margin:0 0 14px}@media(max-width:700px){.mailbox-states{grid-template-columns:1fr 1fr}.mailbox-switch{flex-direction:column;align-items:stretch}}
.money-status{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:10px;margin:0 0 14px}.money-chip{display:flex;flex-direction:column;align-items:flex-start;gap:5px;text-align:left;border:1px solid var(--border);border-radius:8px;padding:10px 12px;background:var(--surface-2);color:var(--text);cursor:pointer;min-width:0}.money-chip:hover{border-color:var(--primary)}.money-chip>span:first-child{font-weight:600;font-size:13px}.money-chip .help{overflow-wrap:anywhere}.finance-error{border:1px solid var(--danger-line);background:var(--danger-soft);border-radius:8px;padding:12px 14px}.finance-error p{margin:6px 0}@media(max-width:700px){.money-status{grid-template-columns:1fr}}
