/* ===== RESET & BASE ===== */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
  --brand: #6366F1;
  --brand-dark: #4F46E5;
  --brand-light: #EEF2FF;
  --text: #111827;
  --text-secondary: #6B7280;
  --border: #E5E7EB;
  --bg: #F9FAFB;
  --card: #FFFFFF;
  --danger: #EF4444;
  --radius: 10px;
  --shadow: 0 1px 4px rgba(0,0,0,.08), 0 4px 16px rgba(0,0,0,.06);
  --shadow-lg: 0 8px 32px rgba(0,0,0,.12);
  --sidebar-w: 230px;
  --topbar-h: 58px;
}

html, body { height:100%; font-family:-apple-system,BlinkMacSystemFont,'Segoe UI',Roboto,sans-serif; font-size:14px; color:var(--text); background:var(--bg); line-height:1.5; }
.hidden { display:none !important; }

/* ===== SCREENS ===== */
.screen { display:none; height:100vh; }
.screen.active { display:flex; }

/* ===== AUTH ===== */
#auth-screen { align-items:center; justify-content:center; background:linear-gradient(135deg,#EEF2FF 0%,#F9FAFB 60%,#E0E7FF 100%); }

.auth-box { background:var(--card); border-radius:16px; box-shadow:var(--shadow-lg); padding:36px; width:400px; max-width:95vw; }
.auth-logo { display:flex; align-items:center; gap:10px; font-size:20px; font-weight:700; color:var(--brand); margin-bottom:28px; }
.auth-tabs { display:flex; gap:4px; background:var(--bg); border-radius:8px; padding:4px; margin-bottom:24px; }
.auth-tab { flex:1; padding:7px; border:none; background:transparent; border-radius:6px; cursor:pointer; font-size:13px; font-weight:500; color:var(--text-secondary); transition:all .15s; }
.auth-tab.active { background:var(--card); color:var(--text); box-shadow:0 1px 3px rgba(0,0,0,.1); }
.auth-form { display:none; flex-direction:column; gap:14px; }
.auth-form.active { display:flex; }
.auth-error { color:var(--danger); font-size:13px; min-height:18px; }
.auth-message { color:var(--text-secondary); font-size:13px; min-height:18px; }
.auth-message.success { color:#047857; }
.auth-message.error { color:var(--danger); }
.auth-form-title { font-size:17px; font-weight:700; }
.auth-form-note { color:var(--text-secondary); font-size:13px; }
.auth-link { align-self:flex-start; border:0; background:transparent; color:var(--brand); cursor:pointer; font:inherit; padding:0; }
.auth-link:hover { text-decoration:underline; }
.auth-back { align-self:center; }
.invite-summary { color:var(--text-secondary); font-size:13px; background:var(--bg); border-radius:8px; padding:10px 12px; }

/* ===== LAYOUT ===== */
#app-screen { flex-direction:row; overflow:hidden; }

/* ===== SIDEBAR ===== */
.sidebar { width:var(--sidebar-w); min-width:var(--sidebar-w); background:var(--card); border-right:1px solid var(--border); display:flex; flex-direction:column; padding:16px 10px; gap:2px; overflow-y:auto; transition:transform .2s ease,box-shadow .2s ease; }
.sidebar-logo { display:flex; align-items:center; gap:10px; font-size:16px; font-weight:700; color:var(--brand); padding:4px 8px 16px; }
.sidebar-pin-btn { margin-left:auto; width:28px; height:28px; border:0; border-radius:7px; background:transparent; color:var(--text-secondary); cursor:pointer; opacity:.55; }
.sidebar-pin-btn:hover,.sidebar-pin-btn.active { background:var(--brand-light); color:var(--brand); opacity:1; }
#app-screen.sidebar-auto .sidebar { position:absolute; inset:0 auto 0 0; z-index:100; transform:translateX(calc(-100% + 18px)); box-shadow:8px 0 20px transparent; }
#app-screen.sidebar-auto .sidebar:hover,#app-screen.sidebar-auto .sidebar:focus-within { transform:translateX(0); box-shadow:8px 0 24px rgba(0,0,0,.14); }
#app-screen.sidebar-auto .main { margin-left:18px; }
.sidebar-nav { display:flex; flex-direction:column; gap:2px; }

.sidebar-section-title { font-size:10px; font-weight:700; text-transform:uppercase; letter-spacing:.06em; color:var(--text-secondary); padding:10px 12px 6px; margin-top:4px; }

.dept-filters { display:flex; flex-direction:column; gap:2px; margin-bottom:4px; }
.dept-filter-item {
  display:flex; align-items:center; gap:8px; padding:6px 12px;
  border-radius:8px; cursor:pointer; font-size:13px; font-weight:500; color:var(--text-secondary);
  transition:background .1s; user-select:none;
}
.dept-filter-item:hover { background:var(--bg); }
/* Чекбокс — видимый, справа */
.dept-filter-item input[type=checkbox] {
  margin-left:auto;
  width:15px; height:15px;
  accent-color:var(--brand);
  cursor:pointer;
  flex-shrink:0;
}
.dept-filter-item input:checked + .dept-label { color:var(--text); font-weight:600; }
.dept-label { flex:1; }
.dept-dot { width:10px; height:10px; border-radius:50%; flex-shrink:0; }

.nav-item { display:flex; align-items:center; gap:10px; padding:9px 12px; border-radius:8px; border:none; background:transparent; cursor:pointer; font-size:13.5px; font-weight:500; color:var(--text-secondary); text-align:left; width:100%; transition:all .15s; font-family:inherit; }
.nav-item:hover { background:var(--bg); color:var(--text); }
.nav-item.active { background:var(--brand-light); color:var(--brand); }
.board-filter.active-board { background:var(--brand-light); color:var(--brand); }
.board-filter.disabled { opacity:.45; cursor:not-allowed; }
.board-filter.disabled input { pointer-events:none; }

.sidebar-bottom { display:flex; flex-direction:column; gap:2px; padding-top:10px; border-top:1px solid var(--border); margin-top:auto; }
.user-avatar-wrap { display:flex; align-items:center; gap:10px; padding:8px 12px; border-radius:8px; cursor:pointer; transition:background .15s; }
.user-avatar-wrap:hover { background:var(--bg); }
.user-info { display:flex; flex-direction:column; min-width:0; }
.user-info span:first-child { font-size:13px; font-weight:600; white-space:nowrap; overflow:hidden; text-overflow:ellipsis; max-width:120px; }

/* ===== AVATAR ===== */
.avatar { width:36px; height:36px; border-radius:50%; background:var(--brand); color:white; display:flex; align-items:center; justify-content:center; font-weight:700; font-size:14px; flex-shrink:0; overflow:hidden; position:relative; }
.avatar.large { width:72px; height:72px; font-size:34px; }
.preset-animal { line-height:1; }
.preset-mark { position:absolute; right:-1px; bottom:-1px; min-width:14px; height:14px; border-radius:7px; display:flex; align-items:center; justify-content:center; padding:0 3px; background:var(--av-fg,currentColor); color:white; border:1px solid white; font-size:7px; font-weight:800; letter-spacing:-.02em; }
.avatar .preset-mark { right:1px; bottom:1px; }
.avatar.large .preset-mark { right:4px; bottom:4px; min-width:20px; height:20px; border-radius:10px; font-size:9px; }

/* ===== ROLE BADGE ===== */
.role-badge { font-size:10px; font-weight:600; padding:1px 6px; border-radius:4px; background:var(--brand-light); color:var(--brand); text-transform:uppercase; letter-spacing:.04em; width:fit-content; }

/* ===== DEPT BADGE ===== */
.dept-badge { display:inline-block; font-size:11px; font-weight:600; padding:2px 8px; border-radius:4px; }

/* ===== MAIN ===== */
.main { flex:1; display:flex; flex-direction:column; overflow:hidden; }

/* ===== TOPBAR ===== */
.topbar { height:var(--topbar-h); display:flex; align-items:center; justify-content:space-between; padding:0 20px; border-bottom:1px solid var(--border); background:var(--card); gap:12px; flex-shrink:0; }
.topbar-left { display:flex; align-items:center; gap:6px; }
.topbar-left h2 { font-size:15px; font-weight:600; min-width:180px; }
.topbar-right { display:flex; align-items:center; gap:8px; min-width:0; }

/* ===== FILTER WRAP ===== */
.filter-wrap { position:relative; }
.btn-ghost.icon-text { display:flex; align-items:center; gap:6px; font-size:13px; padding:7px 12px; }
.filter-count { background:var(--brand); color:white; border-radius:10px; font-size:10px; font-weight:700; padding:1px 5px; min-width:18px; text-align:center; }

.filter-dropdown { position:absolute; top:calc(100% + 6px); right:0; background:var(--card); border:1px solid var(--border); border-radius:10px; box-shadow:var(--shadow-lg); min-width:180px; z-index:200; overflow:hidden; }
.filter-drop-item { display:flex; align-items:center; gap:8px; padding:9px 14px; cursor:pointer; user-select:none; font-size:13px; transition:background .1s; }
.filter-drop-item:hover { background:var(--bg); }
.filter-drop-item input { accent-color:var(--brand); cursor:pointer; }
.pinned-tags { display:flex; gap:6px; max-width:440px; overflow:auto; padding:2px 0; }
.pinned-tag { border:1px solid rgba(17,24,39,.08); background:rgba(17,24,39,.03); color:var(--text-secondary); border-radius:999px; padding:5px 9px; font-size:12px; font-weight:600; cursor:pointer; white-space:nowrap; }
.pinned-tag::before { content:''; display:inline-block; width:7px; height:7px; border-radius:50%; background:var(--tag); margin-right:5px; }
.pinned-tag.active { background:rgba(99,102,241,.12); color:var(--brand); border-color:rgba(99,102,241,.28); }

/* ===== CALENDAR VIEWS ===== */
.calendar-view { display:none; flex:1; overflow:auto; padding:20px 20px 20px 20px; }
.calendar-view.active { display:flex; flex-direction:column; }

/* ===== DEPT NAV TABS ===== */
.dept-nav-tabs { display:flex; gap:6px; padding:0 0 12px; overflow-x:auto; flex-shrink:0; }
.dept-nav-tab { border:1.5px solid var(--border); background:var(--card); border-radius:999px; padding:5px 12px; font-size:12px; font-weight:600; cursor:pointer; white-space:nowrap; color:var(--text-secondary); transition:all .15s; }
.dept-nav-tab:hover { border-color:#D1D5DB; color:var(--text); }
.dept-nav-tab.active { background:var(--dept,var(--brand)); border-color:var(--dept,var(--brand)); color:white; }

/* ===== MONTH QUICK ADD ===== */
.month-quick-add-bar { display:flex; gap:8px; align-items:center; padding-bottom:12px; flex-shrink:0; }
.month-quick-add-bar input[type=text] { flex:1; padding:9px 12px; border:1.5px solid var(--border); border-radius:8px; font-size:14px; font-family:inherit; outline:none; transition:border-color .15s; }
.month-quick-add-bar input[type=text]:focus { border-color:var(--brand); background:white; }
.month-quick-add-bar input[type=date] { padding:9px 12px; border:1.5px solid var(--border); border-radius:8px; font-size:13px; font-family:inherit; outline:none; width:160px; }
.month-quick-add-bar input[type=date]:focus { border-color:var(--brand); }

/* ===== WEEK VIEW ===== */
.week-board { display:grid; grid-template-columns:repeat(7,minmax(160px,1fr)); gap:10px; min-width:980px; align-items:start; }
.day-column { background:var(--card); border:1px solid var(--border); border-radius:12px; min-height:180px; height:auto; display:flex; flex-direction:column; overflow:visible; }
.day-column.today-col { border-color:rgba(99,102,241,.5); box-shadow:0 0 0 3px rgba(99,102,241,.08); }
.day-sticky-tools { position:sticky; top:-20px; z-index:8; background:var(--card); border-radius:11px 11px 0 0; padding-bottom:1px; }
.day-column-head { position:static; background:var(--card); display:flex; align-items:center; justify-content:space-between; gap:8px; padding:8px 9px; border-bottom:1px solid var(--border); }
.day-column-head > div { display:flex; align-items:center; gap:6px; flex-wrap:wrap; }
.day-sources { display:flex; gap:3px; align-items:center; }
.day-source-dot { width:8px; height:8px; border-radius:50%; flex-shrink:0; }
.day-board-stripe { height:3px; border-radius:2px 2px 0 0; flex-shrink:0; }
.dept-board-btn { font-family:inherit; }
.dept-board-btn.active { background:var(--brand-light); color:var(--brand); }
.dept-dot { display:inline-block; width:10px; height:10px; border-radius:50%; flex-shrink:0; }
.wdh-name { font-size:10px; text-transform:uppercase; letter-spacing:.05em; color:var(--text-secondary); font-weight:600; }
.day-num { display:inline-flex; align-items:center; justify-content:center; width:24px; height:24px; border-radius:50%; font-size:14px; font-weight:700; }
.today-col .day-num { background:var(--brand); color:white; }
.quick-add-btn { width:26px; height:26px; border:none; border-radius:8px; background:var(--brand-light); color:var(--brand); font-size:18px; line-height:1; cursor:pointer; }
.quick-add-btn:hover { background:#E0E7FF; }
.day-ticket-list { padding:7px; display:flex; flex-direction:column; gap:6px; flex:0 0 auto; overflow:visible; }
.day-create-entry:focus { outline:none; border-color:var(--brand); color:var(--text); }

/* ── TICKET (week) ─────────────────────────────────── */
.week-ticket {
  position:relative;
  border-radius:8px;
  padding:7px 8px 38px;
  cursor:pointer;
  border-left:3px solid transparent;
  box-shadow:0 1px 3px rgba(0,0,0,.08);
  overflow:visible;
  user-select:none;
  transition:box-shadow .12s, transform .12s;
  display:flex;
  flex-direction:column;
  gap:4px;
  width:100%;
  box-sizing:border-box;
  min-height:76px;
}
.week-ticket:hover { box-shadow:0 4px 14px rgba(0,0,0,.16); transform:translateY(-1px); z-index:10; }
.week-ticket:active { cursor:grabbing; }
.week-ticket.done-ticket,
.month-ticket.done-ticket { filter:grayscale(.35); opacity:.72; }
.week-ticket.done-ticket .t-title,
.month-ticket.done-ticket { color:#6B7280; }

.ticket-done-btn { position:absolute; right:7px; bottom:7px; width:auto; height:24px; padding:0 9px; border:1px solid color-mix(in srgb,var(--brand) 38%,var(--border)); border-radius:999px; background:var(--brand-light); color:var(--brand); font-size:10px; font-weight:700; line-height:1; display:flex; align-items:center; justify-content:center; cursor:pointer; box-shadow:0 1px 2px rgba(0,0,0,.06); }
.ticket-done-btn:hover { border-color:var(--brand); filter:brightness(.97); }
.done-ticket .ticket-done-btn { background:#D1FAE5; color:#047857; border-color:#6EE7B7; }
.t-main { display:flex; flex-direction:column; gap:4px; min-width:0; }
.t-top-row { display:flex; align-items:center; gap:4px; flex-wrap:nowrap; min-width:0; }
.t-time { font-size:10px; font-weight:700; color:var(--text-secondary); flex-shrink:0; white-space:nowrap; }
.t-dots { display:flex; gap:3px; flex:1; }
.tdot { display:inline-block; width:7px; height:7px; border-radius:50%; flex-shrink:0; }
.t-views-badge { display:flex; align-items:center; gap:2px; font-size:10px; font-weight:600; color:var(--text-secondary); background:rgba(0,0,0,.06); border-radius:4px; padding:1px 4px; white-space:nowrap; flex-shrink:0; }

/* Заголовок — показывает весь текст, без обрезки */
.t-title {
  font-size:12.5px;
  font-weight:600;
  line-height:1.35;
  color:var(--text);
  white-space:normal;
  word-break:break-word;
  flex:1;
  max-height:4.1em;
  overflow:hidden;
}

.t-bottom-row { display:flex; align-items:center; justify-content:space-between; gap:4px; }
.t-author { font-size:10px; color:var(--text-secondary); white-space:nowrap; overflow:hidden; text-overflow:ellipsis; max-width:70%; }
.t-members { display:flex; }
.inline-assignee-picker { position:relative; min-width:0; width:140px; }
.t-top-row .inline-assignee-picker { margin-left:auto; }
.inline-assignee-search { width:100%; height:24px; padding:2px 6px; border:1px solid rgba(17,24,39,.15); border-radius:5px; background:rgba(255,255,255,.78); color:var(--text); font:inherit; font-size:9px; outline:none; }
.inline-assignee-search:focus { border-color:var(--brand); }
.assignee-selected-list { display:flex; flex-wrap:wrap; gap:3px; margin-bottom:3px; }
.assignee-selected-chip { display:flex; align-items:center; min-width:0; max-width:100%; padding:2px 3px 2px 6px; border-radius:999px; background:var(--brand-light); color:var(--brand); font-size:9px; line-height:16px; }
.assignee-selected-chip>span { overflow:hidden; text-overflow:ellipsis; white-space:nowrap; }
.assignee-selected-chip button { flex:0 0 auto; width:16px; height:16px; padding:0; border:0; background:transparent; color:inherit; font-size:13px; line-height:16px; cursor:pointer; }
.assignee-search-results { position:absolute; top:calc(100% + 3px); right:0; z-index:30; width:190px; max-height:190px; overflow:auto; padding:4px; border:1px solid var(--border); border-radius:7px; background:var(--card); box-shadow:var(--shadow-lg); }
.assignee-search-results>span { display:block; padding:7px; color:var(--text-secondary); font-size:11px; }
.assignee-search-option { width:100%; display:flex; align-items:center; gap:7px; padding:6px; border:0; border-radius:5px; background:transparent; color:var(--text); font:inherit; font-size:11px; text-align:left; cursor:pointer; }
.assignee-search-option:hover { background:var(--brand-light); }
.tmini-av { width:16px; height:16px; border-radius:50%; display:inline-flex; align-items:center; justify-content:center; font-size:8px; font-weight:700; color:white; border:1px solid white; margin-left:-4px; flex-shrink:0; position:relative; overflow:hidden; }
.tmini-av:first-child { margin-left:0; }
.tmini-av.preset-av { background:var(--av-bg,#F3F4F6); color:var(--av-fg,inherit); font-size:11px; }
.tmini-av .preset-mark { display:none; }
.ticket-progress-mini { height:4px; border-radius:999px; background:rgba(17,24,39,.08); overflow:hidden; }
.ticket-progress-mini span { display:block; height:100%; border-radius:999px; background:#6366F1; }
.done-ticket .ticket-progress-mini span { background:#9CA3AF; }
.t-status { font-size:9px; line-height:1.2; color:var(--text-secondary); font-weight:600; }
.t-status-row { display:flex; align-items:center; justify-content:space-between; gap:6px; color:var(--text-secondary); font-size:9px; font-weight:600; }
.t-tags { display:flex; gap:3px; overflow:hidden; }
.mini-tag { display:inline-flex; align-items:center; max-width:76px; overflow:hidden; text-overflow:ellipsis; white-space:nowrap; border-radius:999px; background:rgba(17,24,39,.04); color:var(--text-secondary); padding:1px 5px; }
.mini-tag::before { content:''; width:6px; height:6px; border-radius:50%; background:var(--tag); margin-right:4px; flex-shrink:0; }

/* ── MONTH TICKET ─── */
.month-ticket { position:relative; border-radius:5px; padding:6px 7px 38px; font-size:11px; font-weight:500; margin-bottom:2px; cursor:pointer; white-space:normal; overflow:visible; text-overflow:ellipsis; transition:opacity .1s; border-left:3px solid transparent; }
.month-ticket:hover { opacity:.85; }
.month-ticket-main { display:flex; align-items:flex-start; gap:5px; min-width:0; }
.month-ticket-title { flex:1; min-width:0; overflow-wrap:anywhere; }
.month-ticket-controls { display:flex; margin-top:5px; }
.month-ticket-controls .inline-assignee-picker { width:100%; }
.month-ticket-controls .inline-assignee-search { font-size:10px; }
.month-done-btn { right:7px; bottom:7px; }
.mt-time { font-size:10px; opacity:.7; font-weight:600; }
.mt-status { display:block; font-size:9px; color:var(--text-secondary); margin-top:1px; }

/* ===== MONTH GRID ===== */
.month-grid { display:grid; grid-template-columns:repeat(7,1fr); gap:1px; background:var(--border); border-radius:var(--radius); overflow:visible; flex:1; }
.month-day-head { background:var(--card); padding:8px; text-align:center; font-size:11px; font-weight:700; color:var(--text-secondary); text-transform:uppercase; letter-spacing:.05em; }
.month-cell { background:var(--card); padding:7px; min-height:100px; position:relative; cursor:pointer; transition:background .1s; overflow:visible; }
.month-cell:hover { background:#FAFAFA; }
.month-cell.other-month .cell-day-num { color:#D1D5DB; }
.month-cell.today .cell-day-num { background:var(--brand); color:white; border-radius:50%; }
.cell-day-num { font-size:13px; font-weight:600; color:var(--text); margin-bottom:4px; width:24px; height:24px; display:flex; align-items:center; justify-content:center; }
.month-more { font-size:11px; color:var(--text-secondary); margin-top:2px; cursor:pointer; }

/* ===== YEAR VIEW ===== */
.year-grid { display:grid; grid-template-columns:repeat(4,1fr); gap:16px; flex:1; }
.year-month-card { background:var(--card); border-radius:var(--radius); border:1px solid var(--border); padding:12px; cursor:pointer; transition:box-shadow .15s,transform .15s; }
.year-month-card:hover { box-shadow:var(--shadow); transform:translateY(-2px); }
.year-month-title { font-size:12px; font-weight:700; margin-bottom:8px; text-transform:capitalize; }
.year-mini-grid { display:grid; grid-template-columns:repeat(7,1fr); gap:2px; }
.year-mini-head { font-size:8px; text-align:center; color:var(--text-secondary); font-weight:600; padding:1px 0; }
.year-mini-day { width:100%; aspect-ratio:1; display:flex; align-items:center; justify-content:center; font-size:8.5px; border-radius:3px; position:relative; }
.year-mini-day.other { color:#D1D5DB; }
.year-mini-day.today { background:var(--brand); color:white; border-radius:50%; }
.year-mini-day.has-tickets::after { content:''; position:absolute; bottom:1px; left:50%; transform:translateX(-50%); width:4px; height:4px; background:var(--brand); border-radius:50%; }
.year-mini-day.today.has-tickets::after { background:white; }

/* ===== FIELDS ===== */
.field { display:flex; flex-direction:column; gap:5px; }
.field label { font-size:11px; font-weight:700; color:var(--text-secondary); text-transform:uppercase; letter-spacing:.04em; }
.field input, .field select, .field textarea { padding:9px 12px; border:1.5px solid var(--border); border-radius:8px; font-size:14px; color:var(--text); background:var(--bg); outline:none; transition:border-color .15s; font-family:inherit; }
.field input:focus, .field select:focus, .field textarea:focus { border-color:var(--brand); background:white; }
.field input[disabled] { opacity:.5; cursor:not-allowed; }
.field-row { display:flex; gap:12px; }
.field-row .field { flex:1; }
.req { color:var(--danger); }
.field-hint { font-size:11px; color:var(--text-secondary); line-height:1.4; }
.ticket-board-banner { display:flex; align-items:center; gap:6px; padding:8px 12px; border-radius:8px; font-size:13px; font-weight:500; }
.ticket-board-banner strong { font-weight:700; }

/* Source badge on king-board */
.t-source-badge {
  display:inline-flex; align-items:center; gap:4px;
  font-size:9px; font-weight:800; text-transform:uppercase; letter-spacing:.06em;
  color:var(--src,var(--brand));
  background:rgba(0,0,0,.04);
  border:1px solid rgba(0,0,0,.07);
  border-radius:4px;
  padding:1px 5px;
  align-self:flex-start;
}
.t-source-badge::before {
  content:'';
  display:inline-block; width:6px; height:6px;
  border-radius:50%;
  background:var(--src,var(--brand));
  flex-shrink:0;
}
.mt-source {
  font-size:9px; font-weight:700; text-transform:uppercase;
  letter-spacing:.04em; opacity:.85;
}
.board-custom-item { cursor:pointer; }
.board-custom-item.active-board { background:var(--brand-light); color:var(--brand); }

/* ===== BUTTONS ===== */
.btn-primary { background:var(--brand); color:white; border:none; border-radius:8px; padding:9px 18px; font-size:14px; font-weight:600; cursor:pointer; transition:background .15s,transform .1s; white-space:nowrap; font-family:inherit; }
.btn-primary:hover { background:var(--brand-dark); }
.btn-primary:active { transform:scale(.97); }
.btn-primary.full { width:100%; padding:11px; }
.btn-primary.small { padding:6px 12px; font-size:12px; }

.btn-ghost { background:transparent; color:var(--text); border:1.5px solid var(--border); border-radius:8px; padding:9px 18px; font-size:14px; font-weight:500; cursor:pointer; transition:background .15s,border-color .15s; white-space:nowrap; font-family:inherit; }
.btn-ghost:hover { background:var(--bg); border-color:#D1D5DB; }
.btn-ghost.small { padding:5px 10px; font-size:12px; }
.btn-ghost.danger { color:var(--danger); }
.btn-ghost.danger:hover { background:#FEF2F2; border-color:#FCA5A5; }

.icon-btn { display:flex; align-items:center; justify-content:center; width:34px; height:34px; border-radius:8px; border:none; background:transparent; cursor:pointer; color:var(--text-secondary); transition:background .15s,color .15s; }
.icon-btn:hover { background:var(--bg); color:var(--text); }

/* ===== MODALS ===== */
.modal-overlay { position:fixed; inset:0; background:rgba(0,0,0,.4); display:flex; align-items:center; justify-content:center; z-index:1000; backdrop-filter:blur(2px); }
.modal-overlay.hidden { display:none; }
.modal { background:var(--card); border-radius:16px; box-shadow:var(--shadow-lg); width:480px; max-width:95vw; max-height:90vh; display:flex; flex-direction:column; overflow:hidden; animation:modal-in .18s ease; }
.modal.wide { width:560px; }
.modal.small { width:360px; }
@keyframes modal-in { from { opacity:0; transform:scale(.96) translateY(8px); } to { opacity:1; transform:scale(1) translateY(0); } }
.modal-header { display:flex; align-items:center; justify-content:space-between; padding:18px 20px 14px; border-bottom:1px solid var(--border); }
.modal-header h3 { font-size:16px; font-weight:700; }
.modal-body { padding:20px; overflow-y:auto; display:flex; flex-direction:column; gap:14px; flex:1; }
.modal-footer { display:flex; align-items:center; padding:14px 20px; border-top:1px solid var(--border); gap:8px; }

/* ===== FIRST-LOGIN TOUR ===== */
.onboarding-overlay { padding:76px 20px 16px calc(var(--sidebar-w) + 20px); }
.onboarding-modal { width:440px; }
.onboarding-step { color:var(--brand); font-size:12px; font-weight:700; }
.onboarding-modal h2 { font-size:22px; line-height:1.25; }
.onboarding-modal p { color:var(--text); font-size:14px; line-height:1.55; }
.onboarding-example { padding:12px; border-radius:8px; background:var(--brand-light); color:var(--brand); font-size:13px; line-height:1.45; }
.onboarding-progress { display:flex; gap:5px; padding-top:4px; }
.onboarding-progress span { width:24px; height:4px; border-radius:4px; background:var(--border); }
.onboarding-progress span.active { background:var(--brand); }
.onboarding-spacer { flex:1; }
.onboarding-highlight { position:relative; z-index:1001; outline:3px solid var(--brand); outline-offset:3px; pointer-events:none; }
@media(max-width:760px){
  .onboarding-overlay { padding:14px; }
  .onboarding-highlight { position:static; z-index:auto; outline:none; }
}
@media(max-width:400px){
  .onboarding-actions { flex-wrap:wrap; }
  .onboarding-actions .onboarding-spacer { flex-basis:100%; }
}

/* ===== TAGS ===== */
.tags-chips, .members-chips { display:flex; flex-wrap:wrap; gap:6px; min-height:28px; }
.tag-chip { display:inline-flex; align-items:center; gap:5px; padding:3px 10px; border-radius:20px; font-size:12px; font-weight:600; cursor:default; border:1px solid transparent; }
.tag-remove { font-size:14px; line-height:1; margin-left:2px; opacity:.6; cursor:pointer; }
.tag-remove:hover { opacity:1; }

/* Member chips */
.member-chip { display:inline-flex; align-items:center; gap:6px; padding:3px 10px 3px 4px; border-radius:20px; font-size:12px; font-weight:500; background:var(--bg); border:1px solid var(--border); }
.mchip-av { width:22px; height:22px; border-radius:50%; display:inline-flex; align-items:center; justify-content:center; font-size:9px; font-weight:700; color:white; flex-shrink:0; position:relative; overflow:hidden; }
.mchip-av.small { width:20px; height:20px; font-size:9px; }
.mchip-av.preset-av { background:var(--av-bg,#F3F4F6); color:var(--av-fg,inherit); font-size:15px; }
.mchip-av.small.preset-av { font-size:14px; }
.mchip-av .preset-mark { display:none; }

.tags-select-wrap, .members-wrap { display:flex; flex-direction:column; gap:8px; }
.member-actions { display:flex; flex-wrap:wrap; gap:6px; }

/* Progress preview */
.progress-preview { display:flex; flex-wrap:wrap; gap:6px; margin-top:4px; }
.progress-step { display:flex; align-items:center; gap:6px; font-size:12px; color:var(--text-secondary); border:1px solid var(--border); border-radius:999px; padding:4px 8px; background:white; }
.progress-dot { width:10px; height:10px; border-radius:50%; background:#D1D5DB; flex-shrink:0; }
.progress-step.active .progress-dot { background:#D1D5DB; }
.progress-step.current { background:var(--brand-light); border-color:rgba(99,102,241,.35); }
.progress-step.current .progress-dot { background:var(--brand); }
.progress-step.current .progress-label { color:var(--text); font-weight:700; }

/* Comments */
.comments-section { background:var(--bg); border:1px solid var(--border); border-radius:10px; padding:14px; display:flex; flex-direction:column; gap:10px; }
.comments-header { font-size:12px; font-weight:700; color:var(--text-secondary); text-transform:uppercase; letter-spacing:.04em; }
.comments-list { display:flex; flex-direction:column; gap:8px; max-height:220px; overflow:auto; }
.comment-item { background:var(--card); border:1px solid var(--border); border-radius:8px; padding:8px 10px; }
.comment-meta { display:flex; justify-content:space-between; gap:8px; font-size:11px; color:var(--text-secondary); margin-bottom:4px; }
.comment-meta strong { color:var(--text); }
.comment-text { font-size:13px; white-space:pre-wrap; word-break:break-word; }
.empty-comments { color:var(--text-secondary); font-size:13px; }
.comment-form { display:flex; gap:8px; align-items:flex-end; }
.comment-form textarea { flex:1; padding:8px 10px; border:1.5px solid var(--border); border-radius:8px; resize:vertical; font-family:inherit; background:white; }

/* Tags management */
.tag-manage-item { display:flex; align-items:center; gap:10px; padding:8px 0; border-bottom:1px solid var(--border); }
.tag-manage-item:last-child { border-bottom:none; }
.tag-color-dot { width:12px; height:12px; border-radius:50%; flex-shrink:0; }
.tag-manage-name { flex:1; font-size:13px; font-weight:500; }
.tag-delete-btn { border:none; background:none; color:var(--text-secondary); cursor:pointer; font-size:16px; padding:2px 6px; border-radius:4px; transition:color .1s,background .1s; }
.tag-delete-btn:hover { color:var(--danger); background:#FEF2F2; }
.new-tag-form { display:flex; gap:8px; align-items:center; margin-top:12px; padding-top:12px; border-top:1px solid var(--border); }
.new-tag-form input[type=text] { flex:1; padding:8px 12px; border:1.5px solid var(--border); border-radius:8px; font-size:13px; outline:none; font-family:inherit; }
.new-tag-form input[type=text]:focus { border-color:var(--brand); }
.new-tag-form input[type=color] { width:36px; height:36px; border:1.5px solid var(--border); border-radius:8px; cursor:pointer; padding:2px; background:white; }

/* Tag picker / member picker items */
.tag-picker-item { display:flex; align-items:center; gap:10px; padding:9px 4px; border-bottom:1px solid var(--border); cursor:pointer; border-radius:6px; transition:background .1s; user-select:none; }
.tag-picker-item:last-child { border-bottom:none; }
.tag-picker-item:hover { background:var(--bg); }
.tag-picker-item input[type=checkbox] { width:16px; height:16px; cursor:pointer; accent-color:var(--brand); flex-shrink:0; }

/* ===== TICKET META ===== */
.ticket-meta { font-size:12px; color:var(--text-secondary); line-height:2; display:flex; flex-direction:column; gap:2px; }
.ticket-meta strong { color:var(--text); }

/* ===== ANALYTICS ===== */
.analytics-section { background:var(--bg); border-radius:10px; padding:14px; display:flex; flex-direction:column; gap:12px; border:1px solid var(--border); }
.analytics-header { display:flex; align-items:center; gap:6px; font-size:12px; font-weight:700; color:var(--text-secondary); text-transform:uppercase; letter-spacing:.04em; }
.analytics-stats { display:grid; grid-template-columns:repeat(3,1fr); gap:10px; }
.stat-card { background:var(--card); border-radius:8px; padding:10px 12px; border:1px solid var(--border); text-align:center; }
.stat-value { font-size:20px; font-weight:700; color:var(--text); }
.stat-label { font-size:11px; color:var(--text-secondary); margin-top:2px; }
.analytics-update-info { font-size:11px; color:var(--text-secondary); text-align:right; }

/* ===== EXPORT MODAL ===== */
.export-options { display:flex; flex-direction:column; gap:8px; margin:8px 0 12px; }
.export-option { display:flex; align-items:center; gap:8px; font-size:13px; cursor:pointer; padding:6px 0; }
.export-option input { accent-color:var(--brand); width:16px; height:16px; cursor:pointer; }

/* ===== PROFILE ===== */
.profile-avatar-section { display:flex; align-items:center; gap:16px; }
.profile-avatar-actions { display:flex; flex-direction:column; gap:6px; }
.avatar-note { color:var(--text-secondary); font-size:13px; max-width:260px; line-height:1.4; }
.avatar-preset-grid { display:grid; grid-template-columns:repeat(10,1fr); gap:6px; }
.avatar-preset-btn { height:38px; border:1.5px solid var(--border); background:var(--av-bg,var(--card)); color:var(--av-fg,var(--text)); border-radius:10px; cursor:pointer; font-size:20px; display:flex; align-items:center; justify-content:center; transition:background .12s,border-color .12s,transform .12s; position:relative; overflow:hidden; }
.avatar-preset-btn:hover { transform:translateY(-1px); }
.avatar-preset-btn.active { border-color:var(--brand); background:var(--brand-light); }
.avatar-preset-btn .preset-mark { right:1px; bottom:1px; }
.divider { height:1px; background:var(--border); margin:4px 0; }
.admin-section { display:flex; flex-direction:column; gap:10px; padding-bottom:16px; border-bottom:1px solid var(--border); }
.admin-section:last-child { border-bottom:0; }
.admin-section h4 { font-size:14px; }
.admin-row { display:flex; align-items:center; gap:8px; padding:9px 0; border-bottom:1px solid var(--border); }
.admin-row:last-child { border-bottom:0; }
.admin-row-main { flex:1; min-width:0; }
.admin-row-main strong, .admin-row-main span { display:block; overflow:hidden; text-overflow:ellipsis; }
.admin-row-main span { color:var(--text-secondary); font-size:12px; }
.admin-row select { padding:6px; border:1px solid var(--border); border-radius:7px; background:white; }
.invite-result { padding:10px; border-radius:8px; background:var(--brand-light); word-break:break-all; }
.invite-result input { width:100%; margin:6px 0 10px; padding:8px; border:1px solid var(--border); border-radius:7px; background:var(--card); color:var(--text); }
.team-invite-note { color:var(--text-secondary); font-size:13px; }
.team-invite-actions { display:flex; flex-wrap:wrap; gap:8px; }
.team-invite-error { color:var(--danger); font-size:13px; }

/* ===== DRAG ===== */
.dragging { opacity:.5; transform:scale(1.03) translateY(-2px) !important; box-shadow:var(--shadow-lg) !important; z-index:999; }
.drop-target { background:rgba(99,102,241,.06) !important; outline:2px dashed var(--brand); outline-offset:-2px; }

/* ===== SCROLLBAR ===== */
::-webkit-scrollbar { width:5px; height:5px; }
::-webkit-scrollbar-track { background:transparent; }
::-webkit-scrollbar-thumb { background:#D1D5DB; border-radius:3px; }
::-webkit-scrollbar-thumb:hover { background:#9CA3AF; }

/* Account preference controls remain available in both designs. */
.new-design-only { display:none; }
.design-switch { display:flex; align-items:center; justify-content:space-between; gap:8px; padding:10px 12px; cursor:pointer; font-size:13px; color:var(--text); }
.design-switch small { display:block; color:var(--text-secondary); font-size:10px; margin-top:3px; }
.design-switch input { appearance:none; width:34px; height:20px; border-radius:12px; background:var(--border); flex-shrink:0; cursor:pointer; position:relative; }
.design-switch input::after { content:''; position:absolute; width:14px; height:14px; left:3px; top:3px; border-radius:50%; background:white; transition:transform .15s; }
.design-switch input:checked { background:var(--brand); }
.design-switch input:checked::after { transform:translateX(14px); }
.design-switch input:disabled { opacity:.5; cursor:wait; }
.design-save-message { font-size:11px; color:var(--text-secondary); padding:0 12px; }
.design-save-message:empty { display:none; }
.design-stats-note { font-size:12px; color:var(--text-secondary); line-height:1.5; }
.design-stat-counts { display:flex; flex-wrap:wrap; gap:12px; margin:10px 0; }
.design-stat-counts>div { flex:1; min-width:130px; background:var(--bg); border:1px solid var(--border); padding:14px; border-radius:8px; }
.design-stat-counts strong { font-size:28px; display:block; }
.design-stat-counts span { font-size:12px; color:var(--text-secondary); }

/* Opt-in Kinopoisk design. The classic styles above are preserved. */
html[data-design=new] { color-scheme:dark; --brand:#ff6600; --brand-dark:#ed5c00; --brand-light:#302217; --text:#f7f7f7; --text-secondary:#aaa; --border:#343434; --bg:#0d0d0d; --card:#191919; --shadow:0 2px 8px #0003; --shadow-lg:0 15px 50px #0008; --sidebar-w:200px; }
html[data-design=new] body { font-family:Arial,Helvetica,sans-serif; }
html[data-design=new] .new-design-only { display:block; }
html[data-design=new] .sidebar { padding:24px 12px 12px; }
html[data-design=new] .sidebar-logo { color:var(--text); font-size:23px; letter-spacing:-1px; padding-bottom:24px; }
html[data-design=new] .sidebar-logo svg>rect:first-child { fill:var(--brand); }
html[data-design=new] .project-heading { padding:24px 24px 18px; }
html[data-design=new] .project-heading>span { color:var(--text-secondary); font-size:10px; text-transform:uppercase; letter-spacing:1.3px; }
html[data-design=new] .project-heading h1 { margin-top:18px; font-size:clamp(26px,3vw,40px); line-height:1.05; letter-spacing:-1.4px; text-transform:uppercase; }
html[data-design=new] .topbar { height:auto; min-height:58px; flex-wrap:wrap; padding:12px 24px; background:var(--bg); border-top:1px solid var(--border); }
html[data-design=new] .topbar-left,html[data-design=new] .topbar-right { flex-wrap:wrap; }
html[data-design=new] .topbar-left h2 { min-width:0; }
html[data-design=new] .calendar-view { padding:20px 24px; }
html[data-design=new] .project-board-picker { display:flex; flex-wrap:wrap; align-items:center; gap:10px 18px; padding:14px 24px 0; font-size:12px; }
html[data-design=new] .project-board-picker>span { color:var(--text-secondary); font-size:11px; }
html[data-design=new] .project-board-picker label { display:flex; align-items:center; gap:6px; cursor:pointer; }
html[data-design=new] .project-board-picker input { accent-color:var(--board-color); width:15px; height:15px; }
html[data-design=new] .dept-nav-tabs { padding-bottom:16px; }
html[data-design=new] .dept-nav-tab { border-radius:6px; }
html[data-design=new] .week-board { gap:9px; }
html[data-design=new] .day-column { border:0; background:transparent; box-shadow:none; }
html[data-design=new] .day-sticky-tools { background:var(--bg); }
html[data-design=new] .day-column-head { background:var(--bg); padding:0; border-bottom:1px solid var(--border); }
html[data-design=new] .today-col .day-column-head { border-color:var(--brand); }
html[data-design=new] .day-date-button { display:flex; align-items:center; flex-wrap:wrap; gap:8px; width:100%; border:0; background:transparent; color:var(--text); padding:10px 6px; text-align:left; cursor:pointer; font:inherit; }
html[data-design=new] .day-date-button:hover { background:var(--card); }
html[data-design=new] .day-num { font-size:25px; font-weight:500; background:transparent; width:auto; height:auto; border-radius:0; }
html[data-design=new] .today-col .day-num { color:var(--brand); }
html[data-design=new] .day-create-entry { margin:8px 0 5px; padding:9px 7px; border:1px solid var(--border); border-radius:5px; background:var(--card); color:var(--text-secondary); text-align:left; font:inherit; font-size:12px; cursor:text; }
html[data-design=new] .day-create-entry:hover { border-color:var(--brand); color:var(--text); }
html[data-design=new] .day-ticket-list { padding:6px 0; gap:9px; }
html[data-design=new] .week-ticket { background:color-mix(in srgb,var(--ticket-color) 17%,#252525)!important; border-left:0!important; border-top:4px solid var(--ticket-color); padding:12px 10px 42px; min-height:130px; box-shadow:none; }
html[data-design=new] .t-main { gap:8px; }
html[data-design=new] .t-title { font-size:13px; }
html[data-design=new] .t-time,html[data-design=new] .t-status-row { font-size:11px; }
html[data-design=new] .t-source-badge { color:color-mix(in srgb,var(--src) 65%,white); background:transparent; padding-left:0; }
html[data-design=new] .week-ticket.done-ticket { filter:none; opacity:.8; }
html[data-design=new] .week-ticket.done-ticket .t-title { color:var(--text); }
html[data-design=new] .ticket-progress-mini { background:#ffffff14; }
html[data-design=new] .ticket-progress-mini span { background:var(--ticket-color,var(--brand)); }
html[data-design=new] .ticket-done-btn { background:var(--card); color:var(--text-secondary); border-color:var(--text-secondary); }
html[data-design=new] .inline-assignee-search { background:var(--card); color:var(--text); border-color:var(--border); }
html[data-design=new] .done-ticket .ticket-done-btn { color:#5fd4ad; border-color:#5fd4ad; }
html[data-design=new] input:not([type=checkbox]):not([type=color]),html[data-design=new] textarea,html[data-design=new] select { background:var(--bg); color:var(--text); border-color:var(--border); }
html[data-design=new] .btn-primary { color:#111; }
html[data-design=new] .btn-ghost,html[data-design=new] .icon-btn { color:var(--text-secondary); }
html[data-design=new] .btn-ghost:hover,html[data-design=new] .icon-btn:hover { background:#292929; color:var(--text); }
html[data-design=new] .modal,html[data-design=new] .modal-header,html[data-design=new] .modal-footer,html[data-design=new] .comment-item { background:var(--card); color:var(--text); }
html[data-design=new] .tag-chip,html[data-design=new] .member-chip,html[data-design=new] .mini-tag { color:var(--text)!important; background:#ffffff12; }
html[data-design=new] .month-cell,html[data-design=new] .mini-month,html[data-design=new] .stat-card { background:var(--card); }
html[data-design=new] .month-cell:hover { background:#252525; }
html[data-design=new] .month-ticket { color:var(--text); }
html[data-design=new] .month-cell.other-month { background:var(--bg); opacity:.6; }
html[data-design=new] .pinned-tag.active { background:var(--brand-light); border-color:var(--brand); }
html[data-design=new] .board-custom-item.active-board { background:var(--brand-light); color:var(--brand); }
html[data-design=new] .quick-add-btn:hover { background:var(--brand-light); }
html[data-design=new] .modal-overlay { background:#000a; }
html[data-design=new] #auth-screen { background:var(--bg); }
@media(max-width:760px){
 html[data-design=new] { --sidebar-w:164px; }
 html[data-design=new] .project-heading { padding:18px 14px; }
 html[data-design=new] .topbar { padding:10px 14px; }
 html[data-design=new] .calendar-view { padding:14px; }
 html[data-design=new] .project-board-picker { padding:12px 14px 0; }
}
html[data-design=new] .week-board { grid-template-columns:repeat(7,minmax(110px,1fr)); min-width:820px; }
html[data-design=new] .week-board .day-column { min-width:0; }
html[data-design=new] .dept-nav-tabs { display:none; }
html[data-design=new] .progress-step { background:var(--bg); }
html[data-design=new] .month-ticket .mt-source { color:color-mix(in srgb,var(--ticket-color) 65%,white)!important; }
html[data-design=new] .filter-count { color:#111; }

/* Shared functionality for both themes. */
.project-heading { padding:18px 20px 12px; flex-shrink:0; }
.project-heading>span { font-size:11px; color:var(--text-secondary); }
.project-heading h1 { margin:6px 0 0; font-size:26px; }
.topbar { height:auto; min-height:var(--topbar-h); padding-top:10px; padding-bottom:10px; flex-wrap:wrap; }
.topbar-left,.topbar-right { flex-wrap:wrap; }
.calendar-jump { display:flex; flex-direction:column; gap:2px; font-size:10px; color:var(--text-secondary); }
.calendar-jump input { max-width:145px; font:inherit; font-size:12px; padding:4px; border:1px solid var(--border); border-radius:5px; background:var(--card); color:var(--text); }
.project-board-picker { display:flex; flex-wrap:wrap; align-items:center; gap:10px 18px; padding:12px 20px 0; font-size:12px; flex-shrink:0; }
.project-board-picker label { display:flex; align-items:center; gap:6px; cursor:pointer; }
.project-board-picker input { accent-color:var(--board-color); }
.dept-nav-tabs { display:none; }
.day-date-button { display:flex; align-items:center; gap:8px; width:100%; border:0; background:transparent; color:var(--text); padding:8px 4px; cursor:pointer; font:inherit; }
.day-create-entry { margin:6px; padding:7px; border:1px solid var(--border); border-radius:5px; background:var(--card); color:var(--text-secondary); text-align:left; font:inherit; font-size:12px; cursor:text; }
.t-progress-labels { font-size:11px; color:var(--text-secondary); overflow-wrap:anywhere; }
.t-tags { display:flex; flex-wrap:wrap; gap:4px; }
.progress-step { cursor:pointer; color:var(--text); font:inherit; font-size:12px; }
.progress-step[aria-pressed=true]::before { content:'✓'; }
.progress-step[aria-pressed=true] { border-color:var(--brand); background:var(--brand-light); }
.inline-check { display:flex!important; flex-direction:row; align-items:center; gap:8px; font-size:12px!important; cursor:pointer; }
.inline-check input[type=checkbox] { width:16px; height:16px; flex:0 0 16px; accent-color:var(--brand); }
.board-members { display:flex; flex-wrap:wrap; gap:10px 16px; max-height:180px; overflow:auto; }
#custom-boards-list { margin-bottom:20px; }
#custom-boards-sidebar { max-height:35vh; overflow:auto; }
#custom-boards-sidebar .nav-item { flex-shrink:0; text-align:left; }
#ticket-tag-options { margin:8px 0; }
.tag-chip { color:var(--text); border:1px solid var(--tag,var(--border)); background:var(--card); cursor:pointer; }
#month-view { min-height:0; overflow-y:auto; overflow-anchor:none; }
.month-section { flex:none; margin-bottom:24px; }
.month-section h3 { position:sticky; top:0; z-index:1; background:var(--bg); padding:12px 0; font-size:20px; }
.month-grid { flex:none; grid-template-columns:repeat(7,minmax(0,1fr)); }
.month-cell { min-height:120px; overflow:visible; }
.month-cell-head { display:flex; align-items:center; justify-content:space-between; margin-bottom:6px; }
.month-cell .cell-day-num { border:0; background:transparent; color:var(--text); cursor:pointer; font:inherit; }
.month-cell .quick-add-btn { opacity:1; }
.month-ticket { white-space:normal; overflow:visible; text-overflow:clip; overflow-wrap:anywhere; line-height:1.45; padding:7px; margin-bottom:5px; }
.month-load-more { flex:none; margin:0 0 20px; }
#ticket-status[hidden] { display:none; }
@media(max-width:900px){ .topbar-left h2 { min-width:0; }.month-grid { min-width:700px; }.month-section h3 { position:static; } }
.t-tags .mini-tag { max-width:100%; white-space:normal; overflow-wrap:anywhere; }
.project-heading { position:relative; padding-right:70px!important; }
.board-settings-gear { position:absolute; top:24px; right:24px; font-size:25px; width:36px; height:36px; }
.board-sidebar-row { display:flex; align-items:center; gap:2px; }
.board-sidebar-row .nav-item { min-width:0; flex:1; }
.board-sidebar-row .nav-item>span:last-child { overflow-wrap:anywhere; }
.board-sidebar-row>.icon-btn { flex:none; font-size:19px; }
.board-color-palette { display:flex; flex-wrap:wrap; gap:8px; }
.board-color-swatch { width:32px; height:32px; border-radius:50%; border:2px solid transparent; cursor:pointer; color:#fff; font-weight:800; text-shadow:0 1px 3px #000; }
.board-color-swatch[aria-pressed=true] { outline:2px solid var(--text); outline-offset:2px; border-color:var(--card); }
.board-color-swatch:focus-visible { outline:3px solid var(--brand); outline-offset:3px; }
