/* FRANCO Quadros */
:root {
  --bg: #EDF1F7;
  --surface: #FFFFFF;
  --surface-2: #F4F7FB;
  --surface-3: #E7ECF3;
  --text: #3A4256;
  --title: #2B3245;
  --muted: #8C95A8;
  --line: #E3E8F0;
  --primary: #2E8BE6;
  --primary-soft: #E3F0FD;
  --accent: #6F0AD4;
  --accent-ink: #FFFFFF;
  --accent-soft: #F1E6FC;
  --accent-text: #6F0AD4;
  --green: #2DBE8C;
  --blue: #5B8DEF;
  --orange: #F7A25C;
  --pink: #FAD0D3;
  --pink-ink: #E5646E;
  --peach: #FCDDBB;
  --peach-ink: #EE8B3A;
  --danger: #E5545F;
  --danger-soft: #FCE4E6;
  --ok: #26A97A;
  --ok-soft: #DDF5EC;
  --warn: #D9822B;
  --warn-soft: #FFEEDB;
  --shadow: 0 1px 2px rgba(43,50,69,.06), 0 2px 8px rgba(43,50,69,.05);
  --shadow-lg: 0 18px 50px rgba(43,50,69,.20), 0 2px 8px rgba(43,50,69,.08);
  --overlay: rgba(31,38,56,.45);
  --radius: 8px;
  --font-d: 'Open Sans', system-ui, sans-serif;
  --font: 'Open Sans', system-ui, -apple-system, 'Segoe UI', sans-serif;
  color-scheme: light;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #12161F; --surface: #1C222E; --surface-2: #171C26; --surface-3: #262E3C;
    --text: #D9DEE8; --title: #F1F4F9; --muted: #8590A5; --line: #2A3242;
    --primary-soft: #18304A; --accent-soft: #2A1648; --accent-text: #B48AF2; --pink: #4A2328; --pink-ink: #FF8A93; --peach: #4A3420; --peach-ink: #FFAE66;
    --danger: #FF6B75; --danger-soft: #3A1A1E; --ok: #45CC97; --ok-soft: #133327; --warn: #FFAA55; --warn-soft: #3A2A16;
    --shadow: 0 1px 2px rgba(0,0,0,.4); --shadow-lg: 0 18px 50px rgba(0,0,0,.6);
    --overlay: rgba(0,0,0,.6); color-scheme: dark;
  }
}
:root[data-theme="dark"] {
  --bg: #12161F; --surface: #1C222E; --surface-2: #171C26; --surface-3: #262E3C;
  --text: #D9DEE8; --title: #F1F4F9; --muted: #8590A5; --line: #2A3242;
  --primary-soft: #18304A; --accent-soft: #2A1648; --accent-text: #B48AF2; --pink: #4A2328; --pink-ink: #FF8A93; --peach: #4A3420; --peach-ink: #FFAE66;
  --danger: #FF6B75; --danger-soft: #3A1A1E; --ok: #45CC97; --ok-soft: #133327; --warn: #FFAA55; --warn-soft: #3A2A16;
  --shadow: 0 1px 2px rgba(0,0,0,.4); --shadow-lg: 0 18px 50px rgba(0,0,0,.6);
  --overlay: rgba(0,0,0,.6); color-scheme: dark;
}

* { box-sizing: border-box; }
html, body { height: 100%; }
body { margin: 0; background: var(--bg); color: var(--text); font: 15px/1.45 var(--font); -webkit-font-smoothing: antialiased; }
button, input, textarea, select { font: inherit; color: inherit; }
a { color: inherit; }
img { max-width: 100%; display: block; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }

/* ---------- botões e campos ---------- */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; height: 38px; padding: 0 14px; border-radius: 10px; border: 1px solid transparent; background: var(--surface-3); color: var(--text); font-weight: 600; cursor: pointer; white-space: nowrap; text-decoration: none; transition: background .12s, opacity .12s; }
.btn:hover { background: var(--line); }
.btn:disabled { opacity: .5; cursor: default; }
.btn-primary { background: var(--accent); color: var(--accent-ink); }
.btn-primary:hover { background: #5A08AD; }
.btn-ghost { background: transparent; }
.btn-ghost:hover { background: var(--surface-3); }
.btn-danger { background: var(--danger-soft); color: var(--danger); }
.btn-danger:hover { background: var(--danger); color: #fff; }
.btn-sm { height: 32px; padding: 0 10px; font-size: 14px; border-radius: 8px; }
.btn-block { width: 100%; justify-content: flex-start; }
.icon-btn { display: inline-grid; place-items: center; width: 34px; height: 34px; border-radius: 8px; border: 0; background: transparent; cursor: pointer; color: var(--muted); }
.icon-btn:hover { background: var(--surface-3); color: var(--text); }
.input, textarea.input, select.input { width: 100%; padding: 9px 11px; border-radius: 9px; border: 1px solid var(--line); background: var(--surface); outline: none; }
.input:focus { border-color: var(--accent); box-shadow: 0 0 0 3px var(--accent-soft); }
textarea.input { resize: vertical; min-height: 80px; line-height: 1.5; }
.field { margin-bottom: 14px; }
.field label { display: block; font-size: 13px; font-weight: 600; color: var(--muted); margin-bottom: 5px; }
.row { display: flex; gap: 8px; align-items: center; }
.muted { color: var(--muted); }
.small { font-size: 13px; }
svg.i { width: 18px; height: 18px; flex: none; stroke: currentColor; fill: none; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
svg.i-sm { width: 14px; height: 14px; }

/* ---------- login ---------- */
.login { min-height: 100vh; display: grid; grid-template-columns: 1.1fr 1fr; }
.login-art { background: #0B0A0F; color: #fff; padding: 48px; display: flex; flex-direction: column; justify-content: space-between; overflow: hidden; position: relative; }
.login-art h1 { font: 800 clamp(40px, 5.5vw, 76px)/.95 var(--font-d); letter-spacing: -.03em; margin: 0; max-width: 9ch; }
.login-art h1 em { font-style: normal; color: #B48AF2; }
.login-3d { position: absolute; inset: 0; z-index: 0; background: radial-gradient(55% 55% at 65% 40%, #3B0A8F66, #0B0A0F 70%); }
.login-art > :not(.login-3d) { position: relative; z-index: 1; }
.login-art h1, .login-art p { text-shadow: 0 2px 18px rgba(11,10,15,.85); }
.login-art p { color: rgba(255,255,255,.82); max-width: 38ch; margin: 18px 0 0; }
.login-cols { position: absolute; right: -40px; bottom: 60px; display: flex; gap: 14px; opacity: .9; transform: rotate(-8deg); }
.login-cols div { width: 120px; border-radius: 10px; background: rgba(255,255,255,.95); padding: 10px; display: flex; flex-direction: column; gap: 8px; }
.login-cols span { display: block; height: 34px; border-radius: 6px; background: #E7ECF3; }
.login-cols span.a { background: var(--accent); }
.login-form { display: grid; place-items: center; padding: 32px; }
.login-form form { width: 100%; max-width: 360px; }
.login-form h2 { font: 700 26px var(--font-d); margin: 0 0 6px; letter-spacing: -.02em; }
.erro-box { background: var(--danger-soft); color: var(--danger); padding: 10px 12px; border-radius: 9px; font-size: 14px; margin-bottom: 12px; }
@media (max-width: 820px) { .login { grid-template-columns: 1fr; } .login-art { min-height: 220px; padding: 28px; } .login-cols { display: none; } }

/* ---------- layout ---------- */
.topbar { position: sticky; top: 0; z-index: 30; height: 56px; display: flex; align-items: center; gap: 12px; padding: 0 20px; background: var(--surface); color: var(--title); border-bottom: 1px solid var(--line); box-shadow: 0 1px 3px rgba(43,50,69,.04); }
.topbar .icon-btn { color: var(--muted); }
.topbar .icon-btn:hover { background: var(--surface-3); color: var(--title); }
.brand { display: flex; align-items: center; gap: 10px; text-decoration: none; font: 800 18px var(--font-d); letter-spacing: -.02em; }
.brand-mark { width: 28px; height: 28px; border-radius: 8px; background: #2B3245; display: flex; gap: 2px; padding: 5px; align-items: flex-start; }
.brand-mark i { display: block; width: 4px; border-radius: 1.5px; background: #fff; }
.brand-mark i:first-child { height: 16px; background: var(--accent); } .brand-mark i:nth-child(2) { height: 11px; } .brand-mark i:nth-child(3) { height: 7px; }
.brand b { color: var(--accent-text); font-weight: 800; }
.brand { color: var(--title); }
.topnav { display: flex; gap: 2px; margin-left: 16px; }
.topnav a { color: #5E6780; text-decoration: none; padding: 8px 10px; border-radius: 6px; font-weight: 700; font-size: 12.5px; text-transform: uppercase; letter-spacing: .02em; }
.topnav a:hover { color: var(--title); background: var(--surface-3); }
.topnav a.on { color: var(--accent-text); }
.spacer { flex: 1; }
.avatar { display: inline-grid; place-items: center; width: 28px; height: 28px; border-radius: 50%; font: 700 11px var(--font-d); color: #0A0A0A; flex: none; letter-spacing: .02em; text-transform: uppercase; box-shadow: 0 0 0 2px var(--surface); }
.avatar.lg { width: 36px; height: 36px; font-size: 13px; }
.avatar.xs { width: 22px; height: 22px; font-size: 9px; }
.topbar .avatar { box-shadow: 0 0 0 2px var(--surface); cursor: pointer; border: 0; }
.avatars { display: flex; }
.avatars .avatar + .avatar { margin-left: -6px; }

.page { max-width: 1180px; margin: 0 auto; padding: 32px 20px 64px; }
.page-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 16px; margin-bottom: 22px; flex-wrap: wrap; }
.page-head h1 { font: 800 34px/1 var(--font-d); margin: 0; letter-spacing: -.03em; }
.section-title { font: 700 13px var(--font-d); text-transform: uppercase; letter-spacing: .08em; color: var(--muted); margin: 32px 0 12px; display: flex; align-items: center; gap: 8px; }

/* ---------- home ---------- */
.boards { display: grid; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: 14px; }
.board-tile { position: relative; background: var(--surface); border-radius: var(--radius); padding: 16px 16px 14px; min-height: 118px; text-decoration: none; display: flex; flex-direction: column; justify-content: space-between; box-shadow: var(--shadow); border: 1px solid var(--line); overflow: hidden; transition: transform .12s, box-shadow .12s; }
.board-tile:hover { transform: translateY(-2px); box-shadow: var(--shadow-lg); }
.board-tile::before { content: ""; position: absolute; inset: 0 0 auto 0; height: 6px; background: var(--c, var(--accent)); }
.board-tile h3 { font: 700 18px/1.15 var(--font-d); margin: 4px 0 0; letter-spacing: -.01em; overflow-wrap: anywhere; }
.board-tile .meta { display: flex; gap: 10px; font-size: 13px; color: var(--muted); align-items: center; }
.board-tile .late { color: var(--danger); font-weight: 600; }
.board-tile.new { border: 1.5px dashed var(--line); background: transparent; box-shadow: none; align-items: center; justify-content: center; color: var(--muted); font-weight: 600; cursor: pointer; }
.board-tile.new::before { display: none; }
.board-tile.new:hover { color: var(--text); border-color: var(--accent); }
.board-tile .tag { font-size: 11px; font-weight: 700; text-transform: uppercase; letter-spacing: .06em; color: var(--muted); }
.tasks { background: var(--surface); border-radius: var(--radius); border: 1px solid var(--line); overflow: hidden; }
.task { display: flex; align-items: center; gap: 12px; padding: 11px 14px; border-top: 1px solid var(--line); text-decoration: none; }
.task:first-child { border-top: 0; }
.task:hover { background: var(--surface-2); }
.task .dot { width: 10px; height: 10px; border-radius: 3px; flex: none; }
.task .t { flex: 1; min-width: 0; }
.task .t b { display: block; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.task .t span { font-size: 13px; color: var(--muted); }
.empty { padding: 28px; text-align: center; color: var(--muted); }

/* ---------- quadro ---------- */
.board-page { height: calc(100vh - 56px); display: flex; flex-direction: column; }
.board-bar { display: flex; align-items: center; gap: 10px; padding: 12px 16px; flex-wrap: wrap; border-bottom: 1px solid var(--line); background: var(--surface); }
.board-bar .swatch { width: 12px; height: 28px; border-radius: 4px; background: var(--c); flex: none; }
.board-title { font: 800 22px var(--font-d); letter-spacing: -.02em; margin: 0; padding: 2px 6px; border-radius: 6px; cursor: text; }
.board-title:hover { background: var(--surface-3); }
.board-title-input { font: 800 22px var(--font-d); letter-spacing: -.02em; padding: 2px 6px; border-radius: 6px; border: 1px solid var(--accent); background: var(--surface); outline: none; }
.pill { display: inline-flex; align-items: center; gap: 5px; font-size: 12px; font-weight: 600; padding: 3px 8px; border-radius: 99px; background: var(--surface-3); color: var(--muted); }
.pill.warn { background: var(--warn-soft); color: var(--warn); }
.filters { display: flex; gap: 8px; align-items: center; }
.filters .input { width: 190px; height: 32px; padding: 0 10px; }
.filters .btn.on { background: var(--accent-soft); color: var(--text); border-color: var(--accent); }

.lanes { flex: 1; display: flex; align-items: flex-start; gap: 12px; padding: 16px; overflow-x: auto; overflow-y: hidden; }
.lane { width: 284px; flex: none; max-height: 100%; display: flex; flex-direction: column; background: var(--surface-2); border-radius: 14px; border: 1px solid var(--line); }
.lane-head { display: flex; align-items: center; gap: 6px; padding: 10px 8px 6px 12px; cursor: grab; }
.lane-head h3 { flex: 1; font: 700 15px var(--font-d); margin: 0; padding: 3px 4px; border-radius: 6px; overflow-wrap: anywhere; }
.lane-head h3:hover { background: var(--surface-3); }
.lane-head .count { font-size: 12px; color: var(--muted); font-weight: 600; }
.lane-head input { flex: 1; font: 700 15px var(--font-d); padding: 3px 4px; border-radius: 6px; border: 1px solid var(--accent); background: var(--surface); outline: none; min-width: 0; }
.cards { flex: 1; overflow-y: auto; padding: 4px 8px; min-height: 8px; display: flex; flex-direction: column; gap: 8px; }
.lane-foot { padding: 6px 8px 8px; }
.add-card-btn { width: 100%; justify-content: flex-start; color: var(--muted); background: transparent; }
.add-card-btn:hover { background: var(--surface-3); color: var(--text); }
.composer textarea { width: 100%; border: 1px solid var(--accent); border-radius: 10px; padding: 9px 10px; resize: none; min-height: 64px; background: var(--surface); outline: none; box-shadow: var(--shadow); }
.composer .row { margin-top: 8px; }
.add-lane { width: 284px; flex: none; }
.add-lane > .btn { width: 100%; justify-content: flex-start; height: 44px; background: rgba(127,127,127,.12); border: 1.5px dashed var(--line); color: var(--muted); }
.add-lane > .btn:hover { color: var(--text); border-color: var(--accent); }
.add-lane .composer { background: var(--surface-2); padding: 8px; border-radius: 14px; border: 1px solid var(--line); }
.add-lane .composer input { width: 100%; }

.card { position: relative; background: var(--surface); border-radius: 10px; box-shadow: var(--shadow); border: 1px solid transparent; cursor: pointer; overflow: hidden; }
.card:hover { border-color: var(--accent); }
.card .cover { height: 30px; }
.card .body { padding: 9px 11px 10px; }
.card .ttl { font-weight: 500; overflow-wrap: anywhere; }
.card.done .ttl { color: var(--muted); }
.labels { display: flex; flex-wrap: wrap; gap: 4px; margin-bottom: 6px; }
.label { display: inline-flex; align-items: center; height: 18px; padding: 0 7px; border-radius: 5px; font-size: 11px; font-weight: 700; color: #fff; background: var(--c); max-width: 100%; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; }
.label.dark-ink { color: #0A0A0A; }
.label.blank { min-width: 36px; }
.badges { display: flex; flex-wrap: wrap; gap: 4px 10px; align-items: center; margin-top: 7px; font-size: 12px; color: var(--muted); }
.badges:empty { display: none; }
.badge { display: inline-flex; align-items: center; gap: 4px; }
.badge.due { padding: 2px 6px; border-radius: 5px; font-weight: 600; }
.badge.due.late { background: var(--danger); color: #fff; }
.badge.due.soon { background: var(--warn-soft); color: var(--warn); }
.badge.due.ok { background: var(--ok); color: #fff; }
.badge.lock { color: var(--warn); }
.badges .avatars { margin-left: auto; }
.card.sortable-ghost { opacity: .35; }
.card.sortable-chosen { box-shadow: var(--shadow-lg); }
.card.sortable-drag { transform: rotate(2deg); }
.lane.sortable-ghost { opacity: .35; }
.no-drag .lane-head { cursor: default; }

/* ---------- modal ---------- */
.overlay { position: fixed; inset: 0; z-index: 60; background: var(--overlay); display: flex; justify-content: center; align-items: flex-start; padding: 48px 16px; overflow-y: auto; animation: fade .12s ease-out; }
@keyframes fade { from { opacity: 0; } }
.modal { width: 100%; max-width: 820px; background: var(--surface); border-radius: 16px; box-shadow: var(--shadow-lg); position: relative; animation: rise .16s ease-out; }
@keyframes rise { from { transform: translateY(10px); opacity: 0; } }
.modal.sm { max-width: 440px; }
.modal-pad { padding: 22px 24px; }
.modal-close { position: absolute; top: 10px; right: 10px; z-index: 2; }
.modal h2 { font: 700 20px var(--font-d); margin: 0 0 16px; letter-spacing: -.01em; }
.modal-cover { height: 84px; border-radius: 16px 16px 0 0; }
.card-head { padding: 20px 56px 4px 24px; }
.card-title { font: 700 22px/1.2 var(--font-d); letter-spacing: -.01em; width: 100%; border: 1px solid transparent; border-radius: 8px; background: transparent; padding: 4px 6px; margin-left: -7px; resize: none; overflow: hidden; outline: none; }
.card-title:hover:not([readonly]) { background: var(--surface-2); }
.card-title:focus { border-color: var(--accent); background: var(--surface); }
.card-sub { font-size: 13px; color: var(--muted); }
.card-sub b { color: var(--text); text-decoration: underline; text-decoration-color: var(--line); }
.card-grid { display: grid; grid-template-columns: 1fr 180px; gap: 24px; padding: 12px 24px 24px; }
.card-main { min-width: 0; }
.card-side h4 { font-size: 12px; text-transform: uppercase; letter-spacing: .06em; color: var(--muted); margin: 0 0 6px; font-weight: 700; }
.card-side .btn { margin-bottom: 6px; height: 34px; font-weight: 500; }
.card-side .btn.on { background: var(--warn-soft); color: var(--warn); }
.meta-row { display: flex; flex-wrap: wrap; gap: 18px; margin-bottom: 18px; }
.meta-row h4 { font-size: 12px; color: var(--muted); margin: 0 0 6px; font-weight: 600; }
.meta-row .labels .label { height: 30px; padding: 0 10px; font-size: 13px; border-radius: 6px; }
.add-chip { display: inline-grid; place-items: center; width: 30px; height: 30px; border-radius: 6px; background: var(--surface-3); border: 0; cursor: pointer; color: var(--muted); }
.add-chip:hover { color: var(--text); background: var(--line); }
.due-chip { display: inline-flex; align-items: center; gap: 8px; height: 32px; padding: 0 10px; border-radius: 6px; background: var(--surface-3); border: 0; cursor: pointer; font-weight: 500; }
.due-chip input { width: 16px; height: 16px; accent-color: var(--ok); margin: 0; }
.due-chip .tag { font-size: 11px; font-weight: 700; padding: 2px 6px; border-radius: 4px; }
.due-chip .tag.late { background: var(--danger); color: #fff; } .due-chip .tag.ok { background: var(--ok); color: #fff; } .due-chip .tag.soon { background: var(--warn); color: #0A0A0A; }
.notice { display: flex; gap: 8px; align-items: center; background: var(--warn-soft); color: var(--warn); font-size: 13px; font-weight: 600; padding: 8px 12px; border-radius: 9px; margin-bottom: 16px; }
.block { margin-bottom: 26px; }
.block-head { display: flex; align-items: center; gap: 10px; margin-bottom: 10px; }
.block-head h3 { font: 700 16px var(--font-d); margin: 0; flex: 1; }
.desc { white-space: pre-wrap; overflow-wrap: anywhere; cursor: pointer; padding: 10px 12px; border-radius: 9px; background: var(--surface-2); min-height: 56px; }
.desc.empty-desc { color: var(--muted); }
.desc a, .comment-text a { color: inherit; text-decoration: underline; text-decoration-color: var(--accent); text-underline-offset: 2px; overflow-wrap: anywhere; }
.progress { display: flex; align-items: center; gap: 10px; font-size: 12px; color: var(--muted); margin-bottom: 8px; }
.progress .bar { flex: 1; height: 7px; border-radius: 9px; background: var(--surface-3); overflow: hidden; }
.progress .bar i { display: block; height: 100%; background: var(--accent); transition: width .2s; }
.progress.full .bar i { background: var(--ok); }
.check-item { display: flex; align-items: flex-start; gap: 10px; padding: 5px 6px; border-radius: 8px; }
.check-item:hover { background: var(--surface-2); }
.check-item input[type=checkbox] { width: 17px; height: 17px; margin: 2px 0 0; accent-color: var(--ok); flex: none; }
.check-item span { flex: 1; overflow-wrap: anywhere; cursor: text; }
.check-item.feito span { text-decoration: line-through; color: var(--muted); }
.check-item .icon-btn { width: 26px; height: 26px; opacity: 0; }
.check-item:hover .icon-btn { opacity: 1; }
.attachments { display: grid; gap: 8px; }
.att { display: flex; align-items: center; gap: 12px; padding: 6px; border-radius: 10px; }
.att:hover { background: var(--surface-2); }
.att .thumb { width: 84px; height: 60px; border-radius: 7px; background: var(--surface-3); display: grid; place-items: center; overflow: hidden; flex: none; font: 700 12px var(--font-d); color: var(--muted); text-transform: uppercase; text-decoration: none; }
.att .thumb img { width: 100%; height: 100%; object-fit: cover; }
.att .info { flex: 1; min-width: 0; }
.att .info a { font-weight: 600; text-decoration: none; display: block; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.att .info a:hover { text-decoration: underline; }
.drop { display: flex; align-items: center; justify-content: center; flex-wrap: wrap; gap: 4px; margin-top: 8px; border: 1.5px dashed var(--line); border-radius: 10px; padding: 14px; text-align: center; color: var(--muted); font-size: 14px; cursor: pointer; }
.drop.over, .drop:hover { border-color: var(--accent); color: var(--text); background: var(--accent-soft); }
.comment { display: flex; gap: 10px; margin-bottom: 14px; }
.comment .c-body { flex: 1; min-width: 0; }
.comment .c-meta { font-size: 13px; color: var(--muted); }
.comment .c-meta b { color: var(--text); margin-right: 6px; }
.comment-text { background: var(--surface-2); padding: 8px 11px; border-radius: 9px; margin-top: 4px; white-space: pre-wrap; overflow-wrap: anywhere; }
.comment .c-actions { font-size: 12px; margin-top: 3px; }
.comment .c-actions button { background: none; border: 0; padding: 0; color: var(--muted); cursor: pointer; text-decoration: underline; margin-right: 8px; }
.activity { font-size: 13px; color: var(--muted); display: flex; gap: 8px; align-items: flex-start; margin-bottom: 8px; }
.activity b { color: var(--text); }
.tabs { display: flex; gap: 4px; margin-bottom: 12px; }
.tabs button { background: none; border: 0; padding: 6px 10px; border-radius: 7px; cursor: pointer; font-weight: 600; color: var(--muted); }
.tabs button.on { background: var(--surface-3); color: var(--text); }
@media (max-width: 720px) {
  .overlay { padding: 0; }
  .modal { border-radius: 0; min-height: 100%; }
  .modal-cover { border-radius: 0; }
  .card-grid { grid-template-columns: 1fr; }
  .card-side { order: -1; display: flex; flex-wrap: wrap; gap: 6px; }
  .card-side h4 { width: 100%; margin-top: 6px; }
  .card-side .btn { width: auto; margin: 0; }
  .lane, .add-lane { width: 82vw; }
  .filters .input { width: 130px; }
  .topnav a span { display: none; }
}

/* ---------- popover ---------- */
.pop { position: fixed; z-index: 80; width: 300px; max-height: min(520px, calc(100vh - 24px)); overflow-y: auto; background: var(--surface); border-radius: 12px; box-shadow: var(--shadow-lg); border: 1px solid var(--line); padding: 12px; animation: rise .12s ease-out; }
.pop h4 { text-align: center; font-size: 14px; margin: 0 0 10px; color: var(--muted); font-weight: 600; }
.pop .list-opt { display: flex; align-items: center; gap: 10px; width: 100%; padding: 7px 8px; border: 0; background: transparent; border-radius: 8px; cursor: pointer; text-align: left; }
.pop .list-opt:hover { background: var(--surface-2); }
.pop .list-opt .grow { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.pop .list-opt .check { color: var(--ok); }
.pop .sep { height: 1px; background: var(--line); margin: 8px -12px; }
.label-opt { display: flex; gap: 6px; align-items: center; margin-bottom: 5px; }
.label-opt .label { flex: 1; height: 32px; font-size: 13px; cursor: pointer; border: 2px solid transparent; }
.label-opt .label.sel { border-color: var(--text); }
.colors { display: grid; grid-template-columns: repeat(6, 1fr); gap: 6px; }
.colors button { height: 30px; border-radius: 6px; border: 2px solid transparent; cursor: pointer; }
.colors button.sel { border-color: var(--text); box-shadow: inset 0 0 0 2px var(--surface); }
.pop .menu-item { display: flex; gap: 10px; align-items: center; width: 100%; padding: 8px; border: 0; background: none; border-radius: 8px; cursor: pointer; text-align: left; }
.pop .menu-item:hover { background: var(--surface-2); }
.pop .menu-item.danger { color: var(--danger); }

/* ---------- tabela usuários ---------- */
.table { width: 100%; border-collapse: collapse; background: var(--surface); border-radius: var(--radius); overflow: hidden; border: 1px solid var(--line); }
.table th { text-align: left; font-size: 12px; text-transform: uppercase; letter-spacing: .06em; color: var(--muted); padding: 10px 14px; background: var(--surface-2); }
.table td { padding: 10px 14px; border-top: 1px solid var(--line); vertical-align: middle; }
.table tr.off td { opacity: .5; }
.role { font-size: 12px; font-weight: 700; padding: 2px 8px; border-radius: 99px; }
.role.admin { background: #2B3245; color: #C9A8F7; }
.role.equipe { background: var(--accent-soft); color: var(--text); }
.role.cliente { background: var(--surface-3); color: var(--muted); }
@media (max-width: 720px) { .table .hide-sm { display: none; } }
.seg { display: inline-flex; background: var(--surface-3); border-radius: 9px; padding: 3px; gap: 2px; }
.seg button { border: 0; background: transparent; padding: 6px 12px; border-radius: 7px; cursor: pointer; font-weight: 600; font-size: 14px; color: var(--muted); }
.seg button.on { background: var(--surface); color: var(--text); box-shadow: var(--shadow); }
.choice { display: flex; gap: 10px; align-items: flex-start; padding: 10px; border: 1px solid var(--line); border-radius: 10px; cursor: pointer; margin-bottom: 8px; }
.choice:has(input:checked) { border-color: var(--accent); background: var(--accent-soft); }
.choice input { margin-top: 3px; accent-color: var(--primary); }
.choice b { display: block; }
.choice span { font-size: 13px; color: var(--muted); }
.switch { display: flex; align-items: center; gap: 10px; cursor: pointer; }
.switch input { width: 18px; height: 18px; accent-color: var(--accent); }

/* ---------- toasts ---------- */
#toasts { position: fixed; bottom: 18px; left: 50%; transform: translateX(-50%); z-index: 100; display: flex; flex-direction: column; gap: 8px; align-items: center; pointer-events: none; }
.toast { background: #2B3245; color: #fff; padding: 10px 16px; border-radius: 10px; box-shadow: var(--shadow-lg); font-size: 14px; animation: rise .16s ease-out; max-width: 90vw; }
.toast.err { background: var(--danger); }
.loading { display: grid; place-items: center; padding: 80px; color: var(--muted); }
.sortable-fallback { opacity: 1 !important; box-shadow: var(--shadow-lg) !important; transform: rotate(2deg); }
.brand { white-space: nowrap; }
@media (max-width: 720px) {
  .topbar { padding: 0 10px; gap: 6px; }
  .brand { font-size: 16px; }
  .topnav { margin-left: 4px; }
  .board-bar { padding: 10px 12px; gap: 8px; }
  .board-bar .spacer { display: none; }
  .board-title { font-size: 19px; }
  .filters { order: 10; width: 100%; }
  .filters .input { flex: 1; width: auto; }
  .lanes { padding: 12px; scroll-snap-type: x mandatory; }
  .lane, .add-lane { scroll-snap-align: start; }
  .page { padding: 22px 14px 48px; }
  .page-head h1 { font-size: 28px; }
}

/* ---------- painel (tela inicial) ---------- */
.dash { max-width: 1320px; margin: 0 auto; padding: 22px 20px 56px; }
.dash-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 16px; }
.panel { background: var(--surface); border-radius: var(--radius); box-shadow: var(--shadow); padding: 16px 18px; position: relative; min-width: 0; display: flex; flex-direction: column; }
.panel-head { display: flex; align-items: center; gap: 8px; margin-bottom: 14px; }
.panel-head h3 { margin: 0; font-size: 14px; font-weight: 700; color: var(--primary); flex: 1; }
.panel-head .sub { display: block; font-size: 11px; font-weight: 400; color: var(--muted); margin-top: 1px; }
.panel .kebab { width: 26px; height: 26px; color: var(--muted); }
.panel.span2 { grid-row: span 2; }
.chip-toggle { display: inline-flex; background: var(--primary-soft); border-radius: 99px; padding: 2px; }
.chip-toggle button { border: 0; background: transparent; color: var(--primary); font-size: 12px; font-weight: 600; padding: 3px 10px; border-radius: 99px; cursor: pointer; }
.chip-toggle button.on { background: var(--surface); box-shadow: var(--shadow); }

.me-card { flex-direction: row; align-items: center; gap: 14px; min-height: 84px; }
.me-card .avatar { width: 52px; height: 52px; font-size: 17px; }
.me-card b { display: block; color: var(--title); font-size: 15px; }
.me-card .info > span { display: block; font-size: 12.5px; color: var(--muted); line-height: 1.4; }

.tile { border-radius: var(--radius); padding: 16px 18px; color: #fff; display: flex; align-items: center; gap: 14px; min-height: 84px; box-shadow: var(--shadow); text-decoration: none; position: relative; border: 0; cursor: pointer; text-align: left; font: inherit; }
.tile:hover { filter: brightness(1.04); }
.tile .t-name { font-size: 16px; font-weight: 600; flex: 1; }
.tile .t-num { font-size: 34px; font-weight: 300; line-height: 1; }
.tile .t-desc { font-size: 11.5px; line-height: 1.3; max-width: 92px; opacity: .95; }
.tile.green { background: var(--green); } .tile.blue { background: var(--blue); } .tile.orange { background: var(--orange); }
.tile .kebab-dot { position: absolute; top: 8px; right: 8px; opacity: .8; }

.circles { display: flex; justify-content: space-around; gap: 8px; text-align: center; flex: 1; align-items: flex-start; }
.circle-stat { display: flex; flex-direction: column; align-items: center; gap: 8px; border: 0; background: none; cursor: pointer; padding: 0; font: inherit; color: inherit; min-width: 0; }
.circle-stat small { font-size: 10.5px; text-transform: uppercase; letter-spacing: .05em; color: var(--muted); font-weight: 600; max-width: 92px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.circle-stat .c { width: 64px; height: 64px; border-radius: 50%; display: grid; place-items: center; font-size: 26px; font-weight: 300; transition: transform .12s; }
.circle-stat:hover .c { transform: scale(1.06); }
.c.pink { background: var(--pink); color: var(--pink-ink); }
.c.peach { background: var(--peach); color: var(--peach-ink); }
.c.mint { background: var(--ok-soft); color: var(--ok); }
.c.sky { background: var(--primary-soft); color: var(--primary); }
.circles-row { display: flex; align-items: center; gap: 12px; }
.circles-row .note { font-size: 11.5px; color: var(--muted); line-height: 1.4; max-width: 120px; }
.panel-foot { font-size: 11.5px; color: var(--muted); text-align: center; margin-top: 12px; }

.plist { display: flex; flex-direction: column; gap: 12px; }
.pitem { display: flex; gap: 10px; align-items: flex-start; text-decoration: none; min-width: 0; }
.pitem:hover b { color: var(--primary); }
.pitem .star { color: #F2A33A; flex: none; margin-top: 1px; }
.pitem .star.off { color: var(--muted); }
.pitem .dot { width: 10px; height: 10px; border-radius: 3px; flex: none; margin-top: 5px; }
.pitem b { display: block; font-weight: 600; font-size: 13.5px; color: var(--title); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.pitem .txt > span { display: block; font-size: 12px; color: var(--muted); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.pitem .txt { min-width: 0; flex: 1; }
.pitem .num { color: var(--muted); font-weight: 400; margin-right: 4px; }
.kind { display: inline-block; font-size: 11px; font-weight: 600; padding: 1px 6px; border-radius: 4px; background: var(--surface-3); color: var(--text); margin-right: 6px; }
.mention { color: var(--primary); font-weight: 600; }
.pitem .txt > .quote { white-space: normal; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; color: var(--text); font-size: 12.5px; }

.donut-wrap { display: flex; align-items: center; gap: 16px; flex: 1; }
.donut-num { font-size: 38px; font-weight: 300; color: var(--primary); line-height: 1; }
.donut-cap { font-size: 11.5px; color: var(--muted); line-height: 1.35; margin-top: 4px; max-width: 120px; }
.donut { width: 112px; height: 112px; flex: none; margin-left: auto; }
.empty-sm { font-size: 13px; color: var(--muted); padding: 8px 0; }

@media (max-width: 1100px) { .dash-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } .panel.span2 { grid-row: auto; } }
@media (max-width: 640px) { .dash-grid { grid-template-columns: 1fr; } .dash { padding: 14px 12px 40px; } }

/* refinos do estilo de referência */
.page-head h1 { font-weight: 700; font-size: 26px; letter-spacing: -.01em; color: var(--title); }
.board-title, .board-title-input { font-weight: 700; font-size: 19px; letter-spacing: 0; color: var(--title); }
.lane { border-radius: 8px; background: var(--surface-3); border: 0; }
.lane-head h3 { font-size: 13px; font-weight: 700; text-transform: uppercase; letter-spacing: .03em; color: #5E6780; }
.card { border-radius: 6px; }
.btn { border-radius: 6px; }
.btn-primary { color: #fff; }
.modal { border-radius: 10px; }
.board-bar { box-shadow: 0 1px 3px rgba(43,50,69,.04); }
.section-title { font-size: 12px; }
.topnav a svg { display: none; }
@media (max-width: 720px) { .topnav a svg { display: block; } }
.topbar-cta { margin-right: 4px; }
@media (max-width: 720px) { .topbar-cta span { display: none; } .topbar-cta { width: 34px; padding: 0; } }
.wordmark { font-weight: 800; letter-spacing: .04em; font-size: 19px; }
.wordmark b { color: var(--accent-text); font-weight: 800; }
.login-art .wordmark b { color: #B48AF2; }
.login-art .wordmark { color: #fff; }

.pitem > .avatar { margin-top: 1px; }
.tile .t-ico { opacity: .9; }

/* capa com imagem */
.card .cover-img { background: var(--surface-3); aspect-ratio: 16 / 10; max-height: 190px; overflow: hidden; }
.card .cover-img img { width: 100%; height: 100%; object-fit: cover; pointer-events: none; }
.modal-cover-img { display: block; background: #12161F; border-radius: 10px 10px 0 0; overflow: hidden; text-align: center; }
.modal-cover-img img { max-height: 260px; width: auto; max-width: 100%; margin: 0 auto; object-fit: contain; }
.link-btn { display: inline-flex; align-items: center; gap: 5px; margin-top: 4px; padding: 0; border: 0; background: none; font-size: 12.5px; font-weight: 600; color: var(--primary); cursor: pointer; }
.link-btn:hover { text-decoration: underline; }
.link-btn.on { color: var(--ok); }
.cover-pick { display: grid; grid-template-columns: repeat(3, 1fr); gap: 6px; }
.cover-pick button { padding: 0; border: 2px solid transparent; border-radius: 6px; overflow: hidden; cursor: pointer; aspect-ratio: 4 / 3; background: var(--surface-3); }
.cover-pick button.sel { border-color: var(--primary); }
.cover-pick img { width: 100%; height: 100%; object-fit: cover; }
