:root {
  --bg: #0e1020;
  --bg-soft: #171a31;
  --panel: #1d2140;
  --panel-2: #252a52;
  --line: #313869;
  --text: #eef0ff;
  --muted: #a3a8d4;
  --brand: #6c8cff;
  --brand-2: #b06cff;
  --accent: #46e0c0;
  --warn: #ffb454;
  --danger: #ff6b8a;
  --radius: 16px;
  --shadow: 0 12px 40px rgba(0,0,0,.45);
}

* { box-sizing: border-box; }
html, body { margin: 0; height: 100%; }
body {
  font-family: 'Plus Jakarta Sans', system-ui, -apple-system, sans-serif;
  background:
    radial-gradient(1200px 600px at 12% -10%, rgba(108,140,255,.25), transparent 60%),
    radial-gradient(1000px 500px at 100% 0%, rgba(176,108,255,.20), transparent 55%),
    var(--bg);
  color: var(--text);
  -webkit-font-smoothing: antialiased;
}
.boot { display: grid; place-items: center; height: 100vh; color: var(--muted); }

button { font-family: inherit; cursor: pointer; border: none; }
input, textarea, select { font-family: inherit; }

/* ---------- buttons ---------- */
.btn {
  border-radius: 12px; padding: 10px 16px; font-weight: 700; font-size: 14px;
  background: var(--panel-2); color: var(--text); border: 1px solid var(--line);
  transition: transform .12s ease, box-shadow .2s, background .2s;
}
.btn:hover { transform: translateY(-1px); }
.btn:active { transform: translateY(0) scale(.98); }
.btn.primary {
  background: linear-gradient(135deg, var(--brand), var(--brand-2));
  border: none; box-shadow: 0 8px 22px rgba(108,140,255,.4);
}
.btn.ghost { background: transparent; }
.btn.tiny { padding: 6px 10px; font-size: 12px; border-radius: 9px; }
.btn.danger { color: var(--danger); }

/* ---------- auth ---------- */
.auth-wrap { min-height: 100vh; display: grid; place-items: center; padding: 24px; }
.auth-card {
  width: 100%; max-width: 420px; background: rgba(29,33,64,.85);
  backdrop-filter: blur(12px); border: 1px solid var(--line);
  border-radius: 22px; padding: 32px; box-shadow: var(--shadow);
  animation: pop .5s cubic-bezier(.2,.9,.3,1.4);
}
.brand-logo { font-size: 40px; }
.auth-card h1 { margin: 8px 0 2px; font-size: 26px; letter-spacing: -.5px; }
.auth-card .sub { color: var(--muted); margin: 0 0 22px; font-size: 14px; }
.field { margin-bottom: 14px; }
.field label { display: block; font-size: 12.5px; font-weight: 600; color: var(--muted); margin-bottom: 6px; }
.field input, .field textarea, .field select {
  width: 100%; padding: 12px 14px; border-radius: 12px; font-size: 14.5px;
  background: var(--bg-soft); border: 1px solid var(--line); color: var(--text);
  transition: border .2s, box-shadow .2s;
}
.field input:focus, .field textarea:focus, .field select:focus {
  outline: none; border-color: var(--brand); box-shadow: 0 0 0 3px rgba(108,140,255,.25);
}
.emoji-row { display: flex; flex-wrap: wrap; gap: 8px; }
.emoji-pick, .color-pick {
  width: 42px; height: 42px; border-radius: 12px; font-size: 20px; display: grid; place-items: center;
  background: var(--bg-soft); border: 2px solid transparent;
}
.emoji-pick.sel { border-color: var(--brand); background: var(--panel-2); transform: scale(1.08); }
.color-pick { border: 3px solid transparent; }
.color-pick.sel { border-color: #fff; transform: scale(1.12); }
.auth-error { color: var(--danger); font-size: 13px; min-height: 18px; margin: 4px 0 8px; }
.switch { text-align: center; color: var(--muted); font-size: 13.5px; margin-top: 16px; }
.switch a { color: var(--brand); font-weight: 700; cursor: pointer; }

/* ---------- shell ---------- */
header.top {
  position: sticky; top: 0; z-index: 30;
  display: flex; align-items: center; gap: 16px; padding: 14px 22px;
  background: rgba(14,16,32,.7); backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--line);
}
.logo { font-weight: 800; font-size: 19px; letter-spacing: -.5px; display: flex; align-items: center; gap: 8px; }
.tabs { display: flex; gap: 6px; margin-left: 10px; }
.tab {
  background: transparent; color: var(--muted); padding: 9px 15px; border-radius: 11px;
  font-weight: 700; font-size: 14px; border: 1px solid transparent; transition: .2s;
}
.tab:hover { color: var(--text); }
.tab.active { color: var(--text); background: var(--panel); border-color: var(--line); }
.tab .pill { background: var(--brand); color: #fff; font-size: 11px; padding: 1px 7px; border-radius: 999px; margin-left: 6px; }
.spacer { flex: 1; }
.me { display: flex; align-items: center; gap: 6px; }
.profile-menu { position: relative; }
.profile-btn {
  display: flex; align-items: center; gap: 10px; background: transparent; border: none;
  color: inherit; cursor: pointer; padding: 5px 9px; border-radius: 11px; transition: background .15s;
}
.profile-btn:hover { background: var(--panel); }
.profile-btn .caret { color: var(--muted); font-size: 16px; transition: transform .2s; }
.profile-menu:hover .caret, .profile-menu.open .caret { transform: rotate(180deg); }
.profile-menu .dropdown {
  position: absolute; right: 0; top: calc(100% + 8px); min-width: 180px;
  background: var(--panel-2); border: 1px solid var(--line); border-radius: 12px;
  box-shadow: var(--shadow); padding: 6px; z-index: 40;
  opacity: 0; visibility: hidden; transform: translateY(-6px); transition: opacity .15s, transform .15s, visibility .15s;
}
.profile-menu:hover .dropdown, .profile-menu.open .dropdown { opacity: 1; visibility: visible; transform: translateY(0); }
.dd-item {
  display: flex; align-items: center; gap: 9px; width: 100%; text-align: left;
  background: transparent; border: none; color: var(--text); cursor: pointer;
  font-size: 14px; font-weight: 600; padding: 10px 11px; border-radius: 9px; transition: background .15s;
}
.dd-item:hover { background: var(--panel); }
.avatar {
  width: 34px; height: 34px; border-radius: 50%; display: grid; place-items: center;
  font-size: 17px; color: #fff; box-shadow: 0 4px 12px rgba(0,0,0,.3);
}
.avatar.lg { width: 54px; height: 54px; font-size: 27px; border-radius: 50%; }
.me .name { font-weight: 700; font-size: 14px; }

/* live profile preview (registration + edit profile) */
.profile-preview {
  display: flex; align-items: center; gap: 14px; background: var(--bg-soft);
  border: 1px solid var(--line); border-radius: 14px; padding: 12px 14px; margin-bottom: 16px;
}
.profile-preview .pv-name { font-weight: 700; font-size: 16px; letter-spacing: -.2px; }
.profile-preview .pv-sub { color: var(--muted); font-size: 12.5px; margin-top: 1px; }

main { padding: 26px 22px 80px; max-width: 1200px; margin: 0 auto; }
.view-head { display: flex; align-items: center; gap: 12px; margin-bottom: 18px; }
.view-head h2 { margin: 0; font-size: 22px; letter-spacing: -.5px; }
.view-head p { margin: 2px 0 0; color: var(--muted); font-size: 13.5px; }

/* ---------- board ---------- */
.board { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; }
@media (max-width: 760px) { .board { grid-template-columns: 1fr; } }
.column { background: rgba(23,26,49,.6); border: 1px solid var(--line); border-radius: var(--radius); padding: 14px; }
.column h3 { margin: 2px 4px 12px; font-size: 14px; letter-spacing: .3px; text-transform: uppercase; color: var(--muted); display: flex; align-items: center; gap: 8px; }
.column h3 .dot { width: 9px; height: 9px; border-radius: 50%; }
.col-planned .dot { background: var(--warn); }
.col-doing .dot { background: var(--accent); }
.col-list { min-height: 60px; display: flex; flex-direction: column; gap: 12px; }
.col-list.drag-over { outline: 2px dashed var(--brand); outline-offset: 4px; border-radius: 12px; }

/* ---------- card ---------- */
.card {
  background: linear-gradient(180deg, var(--panel), var(--bg-soft));
  border: 1px solid var(--line); border-radius: 14px; padding: 14px;
  box-shadow: 0 6px 18px rgba(0,0,0,.25); cursor: grab;
  animation: cardIn .35s cubic-bezier(.2,.9,.3,1.2) both;
  transition: transform .15s, box-shadow .2s, opacity .3s;
}
.card:hover { transform: translateY(-3px); box-shadow: 0 14px 30px rgba(0,0,0,.4); }
.card.sortable-ghost { opacity: .35; }
.card.sortable-chosen { cursor: grabbing; }
.card.leaving { animation: cardOut .45s forwards; }
.card-top { display: flex; align-items: center; gap: 9px; margin-bottom: 9px; }
.card-top .who { font-size: 12.5px; color: var(--muted); font-weight: 600; }
.card-top .avatar { width: 26px; height: 26px; font-size: 13px; }
.card h4 { margin: 0 0 6px; font-size: 16px; line-height: 1.3; letter-spacing: -.3px; }
.card .desc { color: var(--muted); font-size: 13px; margin: 0 0 10px; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.badges { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 10px; }
.badge { font-size: 11.5px; font-weight: 700; padding: 3px 9px; border-radius: 999px; display: inline-flex; align-items: center; gap: 5px; }
.badge.due { background: rgba(255,180,84,.16); color: var(--warn); }
.badge.due.overdue { background: rgba(255,107,138,.18); color: var(--danger); }
.badge.due.soon { background: rgba(70,224,192,.16); color: var(--accent); }
.reactions { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; }
.react {
  background: var(--bg-soft); border: 1px solid var(--line); border-radius: 999px;
  padding: 4px 9px; font-size: 13px; display: inline-flex; align-items: center; gap: 5px;
  transition: transform .12s, background .2s, border .2s;
}
.react:hover { transform: scale(1.12); }
.react.mine { background: rgba(108,140,255,.2); border-color: var(--brand); }
.react .n { font-size: 12px; font-weight: 700; color: var(--muted); }
.react.add { color: var(--muted); font-weight: 800; }
.react.burst { animation: burst .4s; }
.card-foot { display: flex; align-items: center; gap: 10px; margin-top: 12px; padding-top: 11px; border-top: 1px solid var(--line); }
.seen { display: flex; align-items: center; gap: 6px; font-size: 12px; color: var(--muted); }
.seen .stack { display: flex; }
.seen .stack .avatar { width: 22px; height: 22px; font-size: 11px; margin-left: -7px; border: 2px solid var(--bg-soft); }
.seen .stack .avatar:first-child { margin-left: 0; }
.foot-actions { margin-left: auto; display: flex; gap: 6px; }
.icon-btn { background: var(--bg-soft); border: 1px solid var(--line); border-radius: 9px; padding: 6px 9px; font-size: 13px; color: var(--muted); transition: .15s; }
.icon-btn:hover { color: var(--text); transform: translateY(-1px); }
.icon-btn.go { color: var(--accent); border-color: rgba(70,224,192,.4); }

.empty { text-align: center; color: var(--muted); padding: 30px 10px; font-size: 13.5px; }
.empty .big { font-size: 34px; display: block; margin-bottom: 8px; }

/* ---------- archive / activity ---------- */
.list { display: flex; flex-direction: column; gap: 10px; }
.arch-card { display: flex; align-items: center; gap: 14px; background: var(--panel); border: 1px solid var(--line); border-radius: 13px; padding: 14px 16px; animation: cardIn .3s both; }
.arch-card .check { width: 30px; height: 30px; border-radius: 50%; background: rgba(70,224,192,.18); color: var(--accent); display: grid; place-items: center; font-weight: 800; }
.arch-card h4 { margin: 0; font-size: 15px; }
.arch-card .meta { color: var(--muted); font-size: 12.5px; margin-top: 2px; }
.arch-card .reacts-mini { margin-left: auto; display: flex; gap: 4px; font-size: 13px; color: var(--muted); }

.feed { display: flex; flex-direction: column; gap: 4px; }
.feed-item { display: flex; align-items: center; gap: 12px; padding: 11px 14px; border-radius: 12px; transition: background .2s; }
.feed-item:hover { background: var(--panel); }
.feed-item .ico { width: 30px; height: 30px; border-radius: 9px; display: grid; place-items: center; font-size: 15px; background: var(--bg-soft); }
.feed-item .txt { font-size: 13.5px; }
.feed-item .txt b { font-weight: 700; }
.feed-item .when { margin-left: auto; color: var(--muted); font-size: 12px; white-space: nowrap; }

/* ---------- modal ---------- */
.scrim { position: fixed; inset: 0; background: rgba(6,7,18,.62); backdrop-filter: blur(4px); z-index: 50; display: grid; place-items: center; padding: 20px; animation: fade .2s; }
.modal {
  width: 100%; max-width: 540px; max-height: 90vh; overflow: auto;
  background: var(--panel); border: 1px solid var(--line); border-radius: 20px;
  box-shadow: var(--shadow); padding: 24px; animation: pop .35s cubic-bezier(.2,.9,.3,1.3);
}
.modal h3 { margin: 0 0 4px; font-size: 20px; letter-spacing: -.4px; }
.modal .close { position: absolute; }
.modal-head { display: flex; align-items: flex-start; gap: 12px; margin-bottom: 16px; }
.modal-head .x { margin-left: auto; background: var(--bg-soft); border-radius: 9px; padding: 6px 10px; color: var(--muted); border: 1px solid var(--line); }
.row { display: flex; gap: 12px; }
.row .field { flex: 1; }
.detail-section { margin-top: 18px; }
.detail-section .lbl { font-size: 12px; text-transform: uppercase; letter-spacing: .4px; color: var(--muted); font-weight: 700; margin-bottom: 8px; }
.viewer-list { display: flex; flex-direction: column; gap: 8px; }
.viewer-list .v { display: flex; align-items: center; gap: 9px; font-size: 13.5px; }
.share-link { display: flex; gap: 8px; margin-top: 8px; }
.share-link input { flex: 1; }
.toast {
  position: fixed; bottom: 24px; left: 50%; transform: translateX(-50%);
  background: var(--panel-2); border: 1px solid var(--line); color: var(--text);
  padding: 12px 18px; border-radius: 12px; font-size: 14px; font-weight: 600;
  box-shadow: var(--shadow); z-index: 80; animation: toastIn .3s;
}

/* fab */
.fab {
  position: fixed; right: 26px; bottom: 26px; z-index: 25;
  background: linear-gradient(135deg, var(--brand), var(--brand-2));
  color: #fff; border-radius: 16px; padding: 14px 20px; font-weight: 800; font-size: 15px;
  box-shadow: 0 12px 30px rgba(108,140,255,.5); display: flex; align-items: center; gap: 8px;
  transition: transform .15s;
}
.fab:hover { transform: translateY(-3px) scale(1.03); }

/* ---------- animations ---------- */
@keyframes pop { from { opacity: 0; transform: scale(.92) translateY(8px); } to { opacity: 1; transform: none; } }
@keyframes fade { from { opacity: 0; } to { opacity: 1; } }
@keyframes cardIn { from { opacity: 0; transform: translateY(14px) scale(.97); } to { opacity: 1; transform: none; } }
@keyframes cardOut { to { opacity: 0; transform: translateX(40px) scale(.85); } }
@keyframes burst { 0% { transform: scale(1); } 40% { transform: scale(1.5); } 100% { transform: scale(1); } }
@keyframes toastIn { from { opacity: 0; transform: translate(-50%, 12px); } to { opacity: 1; transform: translate(-50%, 0); } }

/* ====================== WEEKLY BOARD ====================== */
.weeknav { display: flex; align-items: center; justify-content: center; gap: 18px; margin-bottom: 22px; }
.weeknav .wk { text-align: center; min-width: 200px; }
.weeknav .wk-label { font-weight: 800; font-size: 19px; letter-spacing: -.4px; }
.weeknav .wk-sub { color: var(--muted); font-size: 12.5px; margin-top: 2px; }
.weeknav .wk-sub a { color: var(--brand); font-weight: 700; cursor: pointer; }

.person-row {
  background: rgba(23,26,49,.6); border: 1px solid var(--line); border-radius: var(--radius);
  padding: 16px 18px; margin-bottom: 16px; animation: cardIn .3s both;
}
.person-row.mine { border-color: rgba(108,140,255,.5); box-shadow: 0 0 0 1px rgba(108,140,255,.15); }
.person-head { display: flex; align-items: center; gap: 10px; margin-bottom: 14px; }
.person-name { font-weight: 700; font-size: 16px; }
.person-name .you { color: var(--brand); font-weight: 700; font-size: 13px; }

.cols { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; }
@media (max-width: 720px) { .cols { grid-template-columns: 1fr; } }
.col-title {
  margin: 0 0 10px; font-size: 12.5px; text-transform: uppercase; letter-spacing: .4px;
  color: var(--muted); font-weight: 700;
}
.items { display: flex; flex-direction: column; gap: 9px; }
.empty-line { color: var(--muted); font-size: 13px; padding: 6px 2px; font-style: italic; }

.item { background: linear-gradient(180deg, var(--panel), var(--bg-soft)); border: 1px solid var(--line); border-radius: 12px; padding: 10px 12px; }
.item-main { display: flex; align-items: flex-start; gap: 10px; }
.item-body { flex: 1; font-size: 14px; line-height: 1.4; padding-top: 1px; }
.item.done .item-body { text-decoration: line-through; color: var(--muted); }

/* checkbox */
.chk { position: relative; display: inline-flex; cursor: pointer; flex-shrink: 0; margin-top: 1px; }
.chk input { position: absolute; opacity: 0; width: 0; height: 0; }
.chk .box {
  width: 19px; height: 19px; border-radius: 6px; border: 2px solid var(--line);
  display: inline-block; transition: .15s; background: var(--bg-soft);
}
.chk input:not(:disabled) + .box:hover { border-color: var(--brand); }
.chk input:checked + .box { background: linear-gradient(135deg, var(--brand), var(--brand-2)); border-color: transparent; }
.chk input:checked + .box::after { content: '✓'; color: #fff; font-size: 13px; font-weight: 800; display: grid; place-items: center; height: 100%; }
.chk input:disabled + .box { opacity: .7; cursor: default; }

.row-tools { display: flex; gap: 2px; opacity: 0; transition: opacity .15s; }
.item:hover .row-tools { opacity: 1; }
.mini { background: transparent; border: none; color: var(--muted); cursor: pointer; font-size: 13px; padding: 2px 5px; border-radius: 6px; }
.mini:hover { background: var(--panel-2); color: var(--text); }

.item-foot { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; margin-top: 9px; padding-left: 29px; }
.chip {
  background: var(--bg-soft); border: 1px solid var(--line); border-radius: 999px; color: var(--muted);
  font-size: 12px; font-weight: 600; padding: 3px 9px; cursor: pointer; transition: .15s;
}
.chip:hover { color: var(--text); transform: translateY(-1px); }
.chip.on { background: rgba(108,140,255,.18); border-color: var(--brand); color: var(--text); }
.seen { display: inline-flex; align-items: center; gap: 4px; font-size: 12px; color: var(--muted); margin-left: auto; }
.seen.muted-seen { opacity: .6; }
.seen .stack { display: flex; }
.seen .stack .avatar.xs { margin-left: -6px; border: 2px solid var(--bg-soft); }
.seen .stack .avatar.xs:first-child { margin-left: 0; }
.avatar.xs { width: 20px; height: 20px; font-size: 10px; box-shadow: none; }
.avatar.sm { width: 28px; height: 28px; font-size: 14px; }

/* comments */
.thread { margin: 10px 0 2px; padding: 10px 0 2px 29px; border-top: 1px dashed var(--line); }
.no-comments { color: var(--muted); font-size: 12.5px; font-style: italic; margin-bottom: 8px; }
.comment { display: flex; gap: 9px; margin-bottom: 10px; }
.c-main { flex: 1; min-width: 0; }
.c-head { display: flex; align-items: baseline; gap: 7px; }
.c-head b { font-size: 13.5px; }
.c-time { color: var(--muted); font-size: 11.5px; }
.c-body { font-size: 13.5px; line-height: 1.4; margin: 2px 0 4px; }
.c-actions { display: flex; gap: 12px; }
.c-act { background: transparent; border: none; color: var(--muted); cursor: pointer; font-size: 12px; font-weight: 600; padding: 0; }
.c-act:hover { color: var(--text); }
.c-act.liked { color: var(--danger); }
.replies { margin-top: 10px; padding-left: 12px; border-left: 2px solid var(--line); }

.add-item, .comment-form { display: flex; gap: 7px; margin-top: 9px; }
.add-item input, .comment-form input {
  flex: 1; padding: 8px 11px; border-radius: 9px; font-size: 13.5px;
  background: var(--bg-soft); border: 1px solid var(--line); color: var(--text);
}
.add-item input:focus, .comment-form input:focus { outline: none; border-color: var(--brand); box-shadow: 0 0 0 3px rgba(108,140,255,.2); }
.comment-form { margin-top: 8px; }
.reply-form { margin-top: 8px; }
.edit-form { display: flex; gap: 7px; flex: 1; }
.edit-form input { flex: 1; padding: 7px 10px; border-radius: 8px; font-size: 14px; background: var(--bg-soft); border: 1px solid var(--brand); color: var(--text); }
.btn.tiny { padding: 7px 12px; font-size: 12.5px; border-radius: 9px; }
.react.burst { animation: burst .4s; }

/* ===== calendar timeline ===== */
.calendar { background: rgba(23,26,49,.6); border: 1px solid var(--line); border-radius: var(--radius); padding: 14px 16px; margin-bottom: 22px; }
.cal-head { display: flex; align-items: baseline; gap: 12px; margin-bottom: 10px; }
.cal-year { font-weight: 800; font-size: 17px; }
.cal-hint { color: var(--muted); font-size: 12px; }
.cal-strip { display: flex; gap: 3px; overflow-x: auto; padding-bottom: 6px; }
.cal-col { display: flex; flex-direction: column; align-items: center; flex: 0 0 auto; }
.cal-month { font-size: 10px; color: var(--muted); height: 14px; width: 16px; text-align: left; overflow: visible; white-space: nowrap; }
.cal-cell {
  width: 14px; height: 30px; border-radius: 4px; border: 1px solid var(--line); cursor: pointer;
  background: color-mix(in srgb, var(--brand) calc(var(--i) * 100%), var(--bg-soft));
  transition: transform .1s, box-shadow .15s;
}
.cal-cell:hover { transform: scaleY(1.12); }
.cal-cell.current { outline: 2px solid var(--accent); outline-offset: 1px; }
.cal-cell.viewed { box-shadow: 0 0 0 2px var(--text); border-color: var(--text); }

/* ===== person row / card ===== */
.row-top { display: flex; justify-content: flex-end; margin-bottom: 12px; }
.add-task-btn { font-size: 13.5px; padding: 9px 15px; }
.cols { display: grid; grid-template-columns: 1fr 1px 1fr; gap: 18px; align-items: start; }
@media (max-width: 720px) { .cols { grid-template-columns: 1fr; } .divider { height: 1px; width: 100%; } }
.divider { background: var(--line); align-self: stretch; width: 1px; }
.row-foot { display: flex; align-items: center; gap: 9px; margin-top: 14px; padding-top: 12px; border-top: 1px solid var(--line); }
.row-foot .foot-name { font-size: 13.5px; font-weight: 600; color: var(--muted); }
.row-foot .you { color: var(--brand); }

/* ===== item ===== */
.status-dot { width: 13px; height: 13px; border-radius: 50%; border: none; flex-shrink: 0; margin-top: 4px; padding: 0; cursor: default; box-shadow: 0 0 0 3px rgba(255,255,255,.04); }
.status-dot.editable { cursor: pointer; }
.status-dot.editable:hover { transform: scale(1.25); }
.item-content { flex: 1; min-width: 0; }
.item-title { font-size: 14.5px; line-height: 1.35; font-weight: 600; }
.item.done .item-title { text-decoration: line-through; color: var(--muted); }
.item-details { color: var(--muted); font-size: 13px; margin-top: 3px; line-height: 1.4; }
.badges { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 7px; }
.status-badge { font-size: 11px; font-weight: 800; padding: 2px 9px; border-radius: 999px; color: var(--sc); background: color-mix(in srgb, var(--sc) 18%, transparent); }
.badge.due { font-size: 11px; font-weight: 700; padding: 2px 9px; border-radius: 999px; background: var(--bg-soft); color: var(--muted); }
.status-note { font-size: 12.5px; color: var(--muted); margin-top: 7px; padding-left: 9px; border-left: 2px solid var(--sc); font-style: italic; }

/* attachments on a card */
.attachments { display: flex; flex-wrap: wrap; gap: 7px; margin-top: 9px; }
.att { display: inline-flex; align-items: center; gap: 4px; background: var(--bg-soft); border: 1px solid var(--line); border-radius: 8px; padding: 4px 8px; font-size: 12px; }
.att a { color: var(--text); text-decoration: none; }
.att a:hover { color: var(--brand); }
.att.img { padding: 0; overflow: hidden; }
.att.img img { display: block; width: 72px; height: 56px; object-fit: cover; }
.att-x { background: rgba(0,0,0,.4); border: none; color: #fff; cursor: pointer; border-radius: 6px; font-size: 10px; padding: 1px 5px; margin-left: 2px; }

/* ===== add/edit modal extras ===== */
.seg { display: flex; gap: 6px; }
.seg button { flex: 1; padding: 9px; border-radius: 10px; background: var(--bg-soft); border: 1px solid var(--line); color: var(--muted); font-weight: 700; font-size: 13px; cursor: pointer; }
.seg button.on { background: var(--panel-2); border-color: var(--brand); color: var(--text); }
.status-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 7px; }
.status-opt { padding: 8px 6px; border-radius: 9px; background: var(--bg-soft); border: 1.5px solid var(--line); color: var(--text); font-weight: 700; font-size: 12.5px; cursor: pointer; border-left: 4px solid var(--sc); }
.status-opt.on { background: color-mix(in srgb, var(--sc) 20%, var(--bg-soft)); border-color: var(--sc); }
.att-list { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 8px; }
.att-chip { display: inline-flex; align-items: center; gap: 6px; background: var(--bg-soft); border: 1px solid var(--line); border-radius: 8px; padding: 4px 8px; font-size: 12px; }
.att-chip button { background: transparent; border: none; color: var(--muted); cursor: pointer; font-size: 12px; }
.att-chip button:hover { color: var(--danger); }
.att-empty { color: var(--muted); font-size: 12.5px; font-style: italic; }
.att-add { display: flex; gap: 7px; margin-bottom: 8px; }
.att-add input { flex: 1; padding: 8px 11px; border-radius: 9px; font-size: 13px; background: var(--bg-soft); border: 1px solid var(--line); color: var(--text); }
.file-btn { display: inline-block; cursor: pointer; font-size: 13px; font-weight: 700; color: var(--brand); padding: 6px 0; }

/* ===== outline icons ===== */
.ic { width: 15px; height: 15px; display: inline-block; vertical-align: -3px; }
.ic.fill { fill: currentColor; }
.icon-chip { display: inline-flex; align-items: center; gap: 5px; }
.icon-chip .ic { width: 14px; height: 14px; }
.icon-chip .cnt:empty { display: none; }
.mini { display: inline-flex; align-items: center; }
.mini .ic { width: 14px; height: 14px; }
.seen .ic { width: 14px; height: 14px; }
.c-act.like { display: inline-flex; align-items: center; gap: 4px; }
.c-act .ic { width: 13px; height: 13px; }
.c-act.like.liked { color: var(--danger); }

/* ===== rich-text editor (details) ===== */
.rte { border: 1px solid var(--line); border-radius: 10px; overflow: hidden; background: var(--bg-soft); }
.rte-toolbar { display: flex; flex-wrap: wrap; gap: 2px; padding: 6px; border-bottom: 1px solid var(--line); }
.rte-btn { background: transparent; border: 1px solid transparent; border-radius: 7px; color: var(--muted); font-size: 13px; padding: 4px 9px; cursor: pointer; min-width: 30px; }
.rte-btn:hover { background: var(--panel-2); color: var(--text); }
.hl-swatch { background: #ffe27a; color: #222; padding: 0 4px; border-radius: 3px; font-weight: 800; }
.rte-input { min-height: 76px; max-height: 240px; overflow-y: auto; padding: 10px 12px; font-size: 14px; line-height: 1.5; outline: none; color: var(--text); }
.rte-input:focus { box-shadow: inset 0 0 0 2px rgba(108,140,255,.3); }
.rte-input:empty:before { content: attr(data-ph); color: var(--muted); pointer-events: none; }
.rte-input ul, .rte-input ol { margin: 6px 0; padding-left: 22px; }
.rte-input mark { background: #ffe27a; color: #222; }

/* rendered rich details on a card */
.rte-content ul, .rte-content ol { margin: 4px 0; padding-left: 20px; }
.rte-content li { margin: 1px 0; }
.rte-content mark { background: #ffe27a; color: #222; padding: 0 2px; border-radius: 2px; }
.rte-content b, .rte-content strong { color: var(--text); }
