/* Approved workspace layout. Existing editors and integration controls stay intact. */
:root {
  font-family: "Segoe UI Variable Text", "Segoe UI", Arial, sans-serif;
  --bg: #fff;
  --surface: #fff;
  --surface-soft: #f3f6f4;
  --line: #e3e8e6;
  --line-strong: #ced8d2;
  --text: #26312f;
  --muted: #63716d;
  --accent: #315d4c;
  --accent-soft: #e7eee9;
  --progress: #8ba994;
  --shadow: 0 12px 36px #23312a12;
}
:root[data-theme="slate"] {
  --surface-soft: #f3f5f8; --line: #e1e6ed; --line-strong: #cbd5df;
  --text: #29343f; --muted: #606f80; --accent: #3c5d79;
  --accent-soft: #e8eef4; --progress: #829cb1;
}
:root[data-theme="sand"] {
  --surface-soft: #f8f5f1; --line: #e9e2d9; --line-strong: #d9cdbf;
  --text: #39332c; --muted: #75695d; --accent: #77563a;
  --accent-soft: #f0e9df; --progress: #b39a7e;
}
:root[data-theme="rose"] {
  --surface-soft: #faf3f6; --line: #ecdde4; --line-strong: #d8bdc9;
  --text: #3f2d36; --muted: #79606c; --accent: #92516e;
  --accent-soft: #f4e3eb; --progress: #ba8da2;
}
:root[data-theme="contrast"] {
  --surface-soft: #eef2f7; --line: #b7c3d2; --line-strong: #8493a6;
  --text: #152335; --muted: #40546d; --accent: #164b83;
  --accent-soft: #dce8f7; --progress: #416fa3;
}
[hidden] { display: none !important; }
body { min-width: 0; font-size: 15px; line-height: 1.5; }
button, input, select, textarea { font-family: inherit; }
button, a, input, select, textarea { touch-action: manipulation; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; }
button { transition: background .15s, border-color .15s; }
button:disabled { cursor: not-allowed; }
h1, h2, h3, h4, strong { font-weight: 600; }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0; }
.app { grid-template-columns: 188px minmax(0, 1fr); min-height: 100dvh; }
.sidebar { background: var(--surface-soft); color: var(--text); padding: 30px 12px 20px; border-right: 1px solid var(--line); gap: 28px; }
.sidebar-footer { font-size: 12px; color: var(--muted); font-weight: 400; overflow-wrap: anywhere; }
.sidebar-collapse-btn { background: transparent; color: var(--muted); width: 24px; height: 24px; }
.sidebar-collapse-btn:hover { background: var(--accent-soft); }
.logo-stack { align-items: flex-start; padding: 0 12px; gap: 12px; }
.logo-stack img { max-width: 128px; max-height: 30px; object-fit: contain; filter: none; }
.nav-link { background: transparent; color: var(--muted); border: 0; border-radius: 5px; padding: 10px 12px; font-size: 14px; font-weight: 400; }
.nav-link.active, .nav-link:hover { background: var(--accent-soft); color: var(--accent); }
.nav-link.active { font-weight: 600; }
.nav-link b { font-weight: 400; color: inherit; }
.nav-section-title { color: var(--muted); font-size: 11px; font-weight: 500; letter-spacing: .06em; }
.main { display: flex; flex-direction: column; }
.preview-banner { padding: 8px 32px; font-size: 12px; color: var(--muted); background: var(--surface-soft); border-bottom: 1px solid var(--line); }
.topbar { min-height: 68px; padding: 16px 32px; gap: 20px; flex-wrap: wrap; }
.topbar h1 { font-size: 18px; font-weight: 500; }
.topbar-actions { gap: 8px; }
.topbar-actions .btn { padding: 7px 10px; font-size: 12px; }
.content { width: 100%; max-width: 1480px; padding: 32px 40px 60px; overflow: visible; }
.btn, .mini-btn, .icon-btn { font-weight: 500; box-shadow: none; }
.btn { font-size: 14px; border-radius: 5px; }
.btn.green, .btn.red { background: var(--accent); color: white; }
.btn.green:hover, .btn.red:hover { filter: brightness(.95); }
.btn.secondary, .mini-btn { color: var(--accent); background: var(--surface); border: 1px solid var(--line-strong); }
.btn.secondary:hover, .mini-btn:hover { background: var(--surface-soft); }
.mini-btn.danger { color: #9a4038; border-color: #edd6d3; background: #fcf7f6; }
.panel { border-color: var(--line); box-shadow: none; }
.panel-head { border-color: var(--line); }
.panel-head h2, .panel-head h3 { font-size: 19px; font-weight: 600; }
.field span, .client-summary-field > span { color: var(--muted); font-size: 13px; font-weight: 400; }
.field input, .field select, .field textarea, input, select, textarea { color: var(--text); }
.field input, .field select, .field textarea { font-size: 15px; border-color: var(--line-strong); }
.save-indicator { border-radius: 6px; box-shadow: none; font-size: 12px; padding: 7px 12px; }
.save-indicator strong { font-weight: 400; }
.save-indicator.saved { background: var(--surface-soft); color: var(--muted); border: 1px solid var(--line); }
.save-indicator.error { color: #9a4038; background: #fff0ed; }
.client-overview-layout { display: block; }
.client-overview-layout > .panel { border: 0; background: transparent; }
.overview-intro h2 { font-size: 29px; letter-spacing: -.7px; margin: 0; }
.overview-intro p { margin: 8px 0 24px; }
.client-overview-layout .panel-head { padding: 0; border: 0; margin-bottom: 24px; }
.filters { flex-wrap: wrap; gap: 16px; }
.filters input { min-width: 0; }
.filters .inline-check { font-size: 13px; font-weight: 400; }
.client-deployment-filter { display: flex; align-items: center; gap: 7px; color: var(--muted); font-size: 13px; }
.client-deployment-filter select { min-width: 120px; padding: 7px 9px; border: 1px solid var(--line-strong); border-radius: 5px; background: var(--surface); font: inherit; }
.overview-labels, .project-main { display: grid; grid-template-columns: 1.08fr .85fr 1.6fr .9fr minmax(140px, .8fr); gap: 24px; }
.overview-labels { color: var(--muted); font-size: 12px; padding: 0 20px 10px; }
.project-card { border: 1px solid var(--line); border-radius: 9px; margin-bottom: 16px; background: var(--surface); overflow: clip; }
.project-main { padding: 20px; align-items: start; }
.project-main > div { min-width: 0; }
.project-deployment-field { --status-dot: #94a3b8; display: grid; gap: 4px; font-size: 12px; color: var(--muted); }
.project-deployment-field + .project-deployment-field { margin-top: 10px; }
.project-deployment-field[data-status-value="Produkcia"],
.project-deployment-field[data-status-value="V prevádzke"] { --status-dot: #26834a; }
.project-deployment-field[data-status-value="Develop"] { --status-dot: #387aca; }
.project-deployment-field[data-status-value="Localhost"] { --status-dot: #8b63b8; }
.project-deployment-field[data-status-value="Testovanie"] { --status-dot: #bd841e; }
.project-deployment-control { display: flex; align-items: center; gap: 7px; }
.project-deployment-control::before { content: ""; flex: 0 0 7px; width: 7px; height: 7px; border-radius: 50%; background: var(--status-dot); }
.project-deployment-field select { appearance: none; -webkit-appearance: none; width: 100%; min-width: 0; font: inherit; color: var(--text); padding: 5px 3px; border: 0; border-radius: 3px; background: transparent; box-shadow: none; cursor: pointer; }
.project-deployment-field select:hover { background: var(--surface-soft); }
.project-deployment-field select:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.project-status-field[data-status-tone="waiting"] { --status-dot: #bd841e; }
.project-status-field[data-status-tone="progress"] { --status-dot: #387aca; }
.project-status-field[data-status-tone="done"], .project-status-field[data-status-value="Môže sa robiť"] { --status-dot: #26834a; }
.project-status-field[data-status-tone="blocked"] { --status-dot: #bd4a40; }
.project-status-field[data-status-tone="archived"] { --status-dot: #64748b; }
.project-identity .client-tag-list { margin: 0 0 8px; }
.project-name { margin: 0 0 10px; font-size: 18px; line-height: 1.35; }
.project-name button, .project-name a, .task-link { background: none; border: 0; padding: 0; color: var(--accent); text-align: left; font: inherit; font-weight: 500; }
.project-name button, .project-name a { font-weight: 600; }
.task-link:hover, .project-name button:hover, .project-name a:hover { text-decoration: underline; }
.project-phase { display: block; font-size: 14px; font-weight: 500; }
.project-progress { display: flex; align-items: center; gap: 10px; margin: 12px 0 6px; font-size: 13px; color: var(--muted); }
.project-progress .progress { width: 90px; height: 4px; margin: 0; }
.progress { height: 4px; background: var(--line); }
.progress > span, .task-card-progress > span, .client-finance-bar > span { background: var(--progress); }
.project-main small { display: block; font-size: 12px; color: var(--muted); margin-top: 6px; line-height: 1.55; }
.project-current, .waiting-person { font-size: 14px; line-height: 1.6; }
.project-main .status-select { font-size: 12px; max-width: 100%; padding: 5px 7px; border: 0; font-weight: 500; }
.project-footer { display: grid; grid-template-columns: minmax(0, 1fr) minmax(180px, .55fr); align-items: start; gap: 24px; background: var(--surface-soft); padding: 12px 20px; border-top: 1px solid var(--line); font-size: 12px; }
.project-footer .reminder-pills { margin: 0; }
.project-team { color: var(--muted); text-align: right; line-height: 1.65; }
.project-footer-tools { display: flex; align-items: flex-start; justify-content: flex-end; flex-wrap: wrap; gap: 12px; min-width: 0; }
.project-footer-tools .project-team { flex: 1; min-width: 0; }
.project-reminders-area { display: grid; grid-template-columns: 28px minmax(0, 1fr); align-items: start; gap: 12px; min-width: 0; }
.project-reminders-area .project-reminder-error { grid-column: 2; }
.project-add-reminder { display: inline-flex; align-items: center; justify-content: center; flex: 0 0 28px; width: 28px; height: 28px; padding: 0; border: 1px solid var(--line-strong); border-radius: 4px; color: var(--accent); background: var(--surface); }
.project-add-reminder:hover { background: var(--accent-soft); }
.project-reminder-error { flex-basis: 100%; color: #b42318; }
.reminder-color-fieldset { min-width: 0; margin: 0; padding: 0; border: 0; }
.reminder-edit-modal .modal-footer-actions { flex-wrap: wrap; gap: 8px; }
.reminder-edit-modal .modal-footer-actions .btn { max-width: 100%; white-space: normal; }
.project-reminders-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; min-width: 0; }
.project-reminders-grid .project-reminder-note { width: 100%; min-width: 0; padding: 12px 14px; text-align: left; font: inherit; cursor: pointer; }
.project-reminder-note:hover { filter: brightness(.98); }
.project-reminder-note:focus-visible { outline: 0; box-shadow: inset 0 0 0 2px var(--reminder-border); }
.project-reminder-note strong { display: block; font-size: 12px; font-weight: 500; line-height: 1.6; overflow-wrap: anywhere; }
.project-reminder-note small { display: block; margin-top: 6px; font-size: 11px; line-height: 1.5; overflow-wrap: anywhere; }
.project-more { border-top: 1px solid var(--line); padding: 8px 20px; }
summary { cursor: pointer; color: var(--accent); font-size: 13px; }
.project-more-content { display: flex; align-items: center; flex-wrap: wrap; gap: 16px; padding: 14px 0; font-size: 13px; }
.project-more-content .client-project-description-text { flex-basis: 100%; }
.project-extra { max-width: 100%; table-layout: fixed; }
.client-overview-tasks { border-top: 1px solid var(--line); padding: 8px 16px; }
.client-overview-tasks h4 { margin: 0 0 4px; font-size: 13px; }
.client-overview-tasks p { margin: 0; font-size: 13px; }
.client-overview-task-list { margin: 0; padding-left: 18px; }
.client-overview-task-list li { padding: 0; color: var(--muted); }
.client-overview-task-list li + li { border-top: 1px solid var(--line); }
.client-overview-task { display: grid; grid-template-columns: minmax(0, 2fr) minmax(80px, .7fr) minmax(110px, .8fr) 90px minmax(150px, 1fr) minmax(140px, 1fr); align-items: center; gap: 10px; width: 100%; padding: 5px 4px; border: 0; border-radius: 4px; background: transparent; color: var(--text); font-size: 12px; font-weight: 400; line-height: 1.4; text-align: left; cursor: pointer; }
.client-overview-task:hover { background: var(--surface-soft); }
.client-overview-task > span { min-width: 0; overflow-wrap: anywhere; }
.client-overview-task-title { color: var(--accent); font-weight: 600; }
.client-overview-task-date { white-space: nowrap; }
.client-overview-task-progress { display: block; width: 80px; height: 6px; overflow: hidden; border-radius: 3px; background: var(--line); }
.client-overview-task-progress > span { display: block; height: 100%; border-radius: inherit; background: var(--accent); }
.client-overview-task-status { justify-self: start; padding: 2px 7px; border-radius: 12px; background: var(--accent-soft); }
.client-overview-task-status[data-tone="todo"] { background: #eef2f6; color: #475467; }
.client-overview-task-status[data-tone="planned"] { background: #e0f2fe; color: #075985; }
.client-overview-task-status[data-tone="progress"] { background: #dbeafe; color: #1d4ed8; }
.client-overview-task-status[data-tone="approval"] { background: #ede9fe; color: #6d28d9; }
.client-overview-task-status[data-tone="client"] { background: #ffedd5; color: #c2410c; }
.client-overview-task-status[data-tone="waiting"] { background: #fef3c7; color: #92400e; }
.client-overview-task-status[data-tone="done"] { background: #dcfce7; color: #166534; }
.client-overview-task-status[data-tone="blocked"] { background: #fee2e2; color: #b91c1c; }
.client-overview-task-status[data-tone="archived"] { background: #e5e7eb; color: #4b5563; }
.task-card.archived, .task-tag.archived { background: #f3f4f6; color: #4b5563; border-color: #9ca3af; }
[data-task-status-tone="todo"] { --task-status-bg: #eef2f6; --task-status-text: #475467; }
[data-task-status-tone="planned"] { --task-status-bg: #e0f2fe; --task-status-text: #075985; }
[data-task-status-tone="progress"] { --task-status-bg: #dbeafe; --task-status-text: #1d4ed8; }
[data-task-status-tone="approval"] { --task-status-bg: #ede9fe; --task-status-text: #6d28d9; }
[data-task-status-tone="client"] { --task-status-bg: #ffedd5; --task-status-text: #c2410c; }
[data-task-status-tone="waiting"] { --task-status-bg: #fef3c7; --task-status-text: #92400e; }
[data-task-status-tone="done"] { --task-status-bg: #dcfce7; --task-status-text: #166534; }
[data-task-status-tone="blocked"] { --task-status-bg: #fee2e2; --task-status-text: #b91c1c; }
[data-task-status-tone="archived"] { --task-status-bg: #e5e7eb; --task-status-text: #4b5563; }
.task-detail-grid .task-status-select, .task-status-select option { background-color: var(--task-status-bg); color: var(--task-status-text); font-weight: 600; }
.client-kanban.task-view-list { display: block; overflow: visible; }
.client-task-detail-list { padding-right: 4px; }
.client-task-detail-list { list-style: none; padding-left: 0; }
.client-task-selectable { display: flex; align-items: center; gap: 8px; }
.client-task-selectable > .client-overview-task { flex: 1; min-width: 0; }
.client-task-selectable > input[type="checkbox"] { flex: 0 0 15px; width: 15px; height: 15px; margin: 0; accent-color: var(--accent); cursor: pointer; }
.client-task-selectable.is-selected { background: var(--accent-soft); }
.client-task-bulk { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 12px; padding: 8px 0 12px; font-size: 12px; }
.client-task-bulk .inline-check { white-space: nowrap; }
.client-task-bulk select { min-width: 160px; padding: 5px 8px; font-size: 12px; }
.client-task-bulk select.task-status-select { background-color: var(--task-status-bg); color: var(--task-status-text); }
.client-task-bulk-message { flex-basis: 100%; margin: 0; color: var(--muted); }
.client-overview-feed { margin: 0; padding: 8px 0; border: 0; }
.client-overview-feed > strong { margin-bottom: 4px; color: var(--muted); font-weight: 500; }
.client-overview-feed > div { gap: 0; }
.client-overview-feed-item { gap: 3px; padding: 7px 4px; border: 0; border-bottom: 1px solid var(--line); border-radius: 0; background: transparent; color: var(--text); font-weight: 400; }
.client-overview-feed-item:last-child { border-bottom: 0; }
.client-overview-feed-item:hover { background: var(--surface-soft); }
.client-overview-feed-item.closed-reminder { background: transparent; border-left: 0; }
.client-overview-feed-item .client-feed-preview { display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 2; overflow: hidden; color: var(--text); font-size: 12px; font-weight: 500; line-height: 1.45; overflow-wrap: anywhere; white-space: normal; }
.client-overview-feed-item small { color: var(--muted); font-size: 11px; font-weight: 400; line-height: 1.4; overflow-wrap: anywhere; white-space: normal; }
@media (max-width: 1000px) {
  .client-overview-task { grid-template-columns: minmax(0, 2fr) minmax(0, 1fr) minmax(0, 1fr); }
  .client-overview-task-title { grid-column: 1 / -1; }
}
@media (max-width: 600px) {
  .project-reminders-grid { grid-template-columns: minmax(0, 1fr); }
  .client-overview-tasks { padding: 8px 12px; }
  .client-overview-task { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 3px 8px; padding: 6px 2px; }
  .client-overview-task-progress { grid-column: 1 / -1; }
}
.client-project-description-text { font-size: 15px; line-height: 1.7; color: var(--text); font-weight: 400; white-space: pre-wrap; text-align: left; }
.client-breadcrumb { display: flex; align-items: center; gap: 12px; color: var(--muted); font-size: 13px; margin-bottom: 28px; }
.client-breadcrumb select { max-width: min(420px, 60vw); border: 0; background: transparent; padding: 7px; font-size: 13px; }
.client-detail-hero { position: static; display: flex; flex-direction: row; justify-content: space-between; align-items: start; gap: 24px; margin: 0 0 26px; padding: 0; }
.client-detail-hero::before, .client-detail-hero-spacer { display: none; }
.client-detail-hero h2 { font-size: 32px; line-height: 1.25; letter-spacing: -.7px; margin: 0; font-weight: 600; }
.client-title-line { display: flex; align-items: center; gap: 14px; flex-wrap: wrap; }
.client-project-intro { font-size: 14px; color: var(--muted); line-height: 1.6; max-width: 75ch; margin: 10px 0 0; }
.client-hero-progress { width: 175px; flex-shrink: 0; margin-top: 8px; font-size: 12px; color: var(--muted); }
.client-hero-progress > span { display: flex; justify-content: space-between; gap: 12px; margin-bottom: 12px; }
.client-hero-progress strong { white-space: nowrap; }
.client-detail-panel { border: 0; border-radius: 0; overflow: visible; }
.client-detail-panel > .panel-body { padding: 0; display: block; }
.client-summary-card { display: grid; grid-template-columns: repeat(5, minmax(0,1fr)); gap: 24px; background: transparent; border: 0; padding: 0; margin-bottom: 26px; }
.client-summary-field { border: 0; background: transparent; padding: 0; min-width: 0; }
.client-summary-field input, .client-summary-field select { width: 100%; padding: 8px; border: 1px solid var(--line-strong); border-radius: 5px; font-size: 14px; font-weight: 400; background: var(--surface); }
.client-tabs { display: flex; gap: 28px; overflow-x: auto; border-bottom: 1px solid var(--line); margin: 0 0 28px; }
.client-tabs button { white-space: nowrap; padding: 13px 0; border-bottom: 2px solid transparent; background: transparent; color: var(--muted); font-size: 14px; }
.client-tabs button[aria-current="page"] { border-bottom-color: var(--accent); color: var(--accent); font-weight: 600; }
.client-tab-content h3 { font-size: 18px; margin: 0 0 16px; font-weight: 600; }
.section-heading { display: flex; align-items: center; justify-content: space-between; gap: 20px; }
.section-heading h3 { margin: 0; }
.workspace-overview-grid { display: grid; grid-template-columns: minmax(0,1fr) 290px; gap: 40px; }
.workspace-overview-grid > div, .workspace-context { min-width: 0; }
.focus-row { display: flex; gap: 18px; align-items: center; padding: 18px 0; border-bottom: 1px solid var(--line); }
.focus-row > div { flex: 1; min-width: 0; }
.focus-row small { display: block; margin-top: 6px; color: var(--muted); font-size: 12px; line-height: 1.6; }
.workspace-scope { margin-top: 32px; max-width: 70ch; }
.overview-discussion > .section-heading { margin-bottom: 16px; flex-wrap: wrap; }
.overview-discussion > .section-heading h3 { margin: 0; }
.overview-note-list { display: grid; gap: 12px; }
.overview-note { min-width: 0; padding: 16px 0; border-bottom: 1px solid var(--line); }
.overview-reminder { position: relative; padding: 18px 20px; border: 0; border-radius: 4px; background: var(--reminder-bg, #fff7ed); color: var(--reminder-text, #7c2d12); clip-path: polygon(0 0, calc(100% - 18px) 0, 100% 18px, 100% 100%, 0 100%); }
.overview-reminder::after { content: ""; position: absolute; top: 0; right: 0; width: 18px; height: 18px; background: color-mix(in srgb, var(--reminder-border, #f59e0b) 28%, var(--reminder-bg, #fff7ed)); clip-path: polygon(0 0, 100% 100%, 0 100%); border-bottom-left-radius: 2px; pointer-events: none; }
.overview-reminder .muted, .overview-reminder small { color: var(--reminder-muted, #9a3412); }
.overview-reminder .task-link, .overview-reminder .client-text-more, .overview-reminder .client-text-less { color: var(--reminder-text, #7c2d12); }
.overview-reminder .mini-btn { background: transparent; border-color: color-mix(in srgb, var(--reminder-border, #f59e0b) 30%, transparent); color: var(--reminder-text, #7c2d12); }
.overview-note .client-note-text, .client-note-text { margin: 0 0 12px; white-space: pre-wrap; overflow-wrap: anywhere; font-size: 14px; line-height: 1.65; }
.overview-note-context { display: block; margin-bottom: 10px; font-size: 13px; text-align: left; }
.overview-note-reason { font-size: 13px; line-height: 1.6; overflow-wrap: anywhere; }
.overview-note-footer { display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 10px 16px; }
.overview-note-footer small { color: var(--muted); font-size: 12px; line-height: 1.6; }
.overview-note-actions, .overview-compose-actions { display: flex; align-items: center; flex-wrap: wrap; gap: 8px; }
.overview-comment-compose { display: grid; gap: 10px; margin-bottom: 16px; }
.overview-comment-compose textarea { width: 100%; min-height: 88px; resize: vertical; line-height: 1.65; }
.overview-compose-actions { justify-content: flex-end; }
.overview-older-comments { margin-top: 16px; }
.overview-older-comments > summary { padding: 8px 0; }
.client-text-expand { margin-bottom: 12px; }
.client-text-expand > summary { list-style: none; color: var(--text); font-size: 14px; line-height: 1.65; overflow-wrap: anywhere; }
.client-text-expand > summary::-webkit-details-marker { display: none; }
.client-text-more, .client-text-less { display: block; color: var(--accent); font-size: 13px; margin-top: 6px; }
.client-text-less, .client-text-expand[open] .client-text-preview, .client-text-expand[open] .client-text-more { display: none; }
.client-text-expand[open] .client-text-less { display: block; margin: 0 0 10px; }
.workspace-context { border-left: 1px solid var(--line); padding-left: 28px; }
.workspace-context section + section { border-top: 1px solid var(--line); margin-top: 24px; padding-top: 24px; }
.workspace-context h3 { font-size: 15px; }
.workspace-context p { font-size: 14px; line-height: 1.6; }
.workspace-context small { display: block; color: var(--muted); margin-top: 5px; }
.workspace-context .task-link { font-size: 13px; }
.workspace-context .drive-document-item { flex-wrap: wrap; padding: 10px 0; border: 0; }
.workspace-context .drive-document-copy { flex: 1; min-width: 0; }
.workspace-context .drive-document-actions { width: 100%; justify-content: flex-start; }
.client-detail-toolbar { margin: 24px 0; flex-wrap: wrap; }
.quick-links { flex-wrap: wrap; }
.quick-link { font-size: 13px; font-weight: 500; background: var(--surface-soft); color: var(--accent); border-color: var(--line); }
.client-resource-stack { display: grid; gap: 32px; }
.drive-documents-panel, .gmail-emails-panel, .client-finance-panel { border: 0; background: transparent; padding: 0; box-shadow: none; }
.drive-document-item { border-color: var(--line); padding: 16px 0; }
.drive-document-copy strong { font-size: 15px; font-weight: 500; white-space: normal; }
.drive-document-copy small { font-size: 12px; }
.drive-documents-head, .gmail-emails-head { padding: 0 0 12px; border-color: var(--line); }
.kanban-head { display: flex; flex-wrap: wrap; align-items: center; gap: 18px; margin-bottom: 20px; }
.kanban-head h3 { margin: 0; margin-right: auto; }
.view-switch { display: flex; padding: 3px; border-radius: 6px; background: var(--surface-soft); }
.view-switch button { background: transparent; color: var(--muted); padding: 6px 12px; border-radius: 4px; font-size: 13px; }
.view-switch button[aria-pressed="true"] { background: var(--surface); color: var(--accent); box-shadow: 0 1px 3px #233b2015; }
.task-filters { display: flex; align-items: center; flex-wrap: wrap; gap: 20px; margin-bottom: 24px; color: var(--muted); font-size: 13px; }
.task-filters select { padding: 7px; background: var(--surface); border: 1px solid var(--line-strong); border-radius: 5px; }
.client-kanban { max-width: 100%; }
.client-kanban.task-view-cards { display: grid; grid-template-columns: minmax(0,1fr); overflow: visible; gap: 18px; }
.client-kanban .task-column { background: var(--surface-soft); border: 0; border-radius: 8px; padding: 17px; min-width: 0; }
.task-view-cards .task-column { width: 100%; flex-basis: auto; }
.task-view-cards .task-column.collapsed { min-height: 0; display: flex; flex-direction: row; align-items: center; gap: 16px; }
.task-view-cards .collapsed-phase-label { display: flex; flex-wrap: wrap; align-items: center; gap: 16px; writing-mode: horizontal-tb; transform: none; }
.task-view-cards .phase-task-cards { display: grid; grid-template-columns: repeat(auto-fill,minmax(min(100%,300px),1fr)); gap: 14px; }
.client-kanban.task-view-kanban { display: flex; align-items: stretch; gap: 16px; overflow-x: auto; padding-bottom: 18px; }
.task-view-kanban .task-column { flex: 0 0 290px; width: 290px; }
.task-view-kanban .task-column.collapsed { flex-basis: 70px; width: 70px; }
.task-column-head { margin-bottom: 14px; align-items: start; }
.task-column-head h4 { color: var(--accent); font-size: 14px; font-weight: 600; }
.task-column-head span, .kanban-workflow-phase { font-size: 12px; font-weight: 400; }
.phase-toggle { color: var(--muted); background: transparent; }
.phase-add-task { position: static; width: auto; height: auto; margin-top: 8px; padding: 6px 8px; border: 0; color: var(--accent); background: transparent; font-size: 13px; font-weight: 400; box-shadow: none; }
.ui-icon { display: inline-block; flex: 0 0 16px; width: 16px; height: 16px; vertical-align: middle; pointer-events: none; }
.has-ui-icon { display: inline-flex; align-items: center; justify-content: center; gap: 6px; white-space: nowrap; }
.nav-link > .ui-icon { width: 18px; height: 18px; flex-basis: 18px; }
.phase-add-task.has-ui-icon { justify-content: flex-start; }
.modal-close.has-ui-icon, .icon-btn.has-ui-icon, .phase-toggle.has-ui-icon { gap: 0; }
.task-card { padding: 16px; background: var(--surface); border: 1px solid var(--line-strong); border-radius: 7px; box-shadow: none; min-width: 0; margin: 0; }
.task-view-kanban .task-card { margin-bottom: 14px; }
.task-card:hover { border-color: var(--progress); box-shadow: 0 3px 12px #2d50300c; }
.task-card.progress, .task-card.done, .task-card.planned, .task-card.waiting, .task-card.blocked { background: var(--surface); border-color: var(--line-strong); }
.task-card strong { display: block; font-size: 15px; font-weight: 500; line-height: 1.5; margin: 12px 0; }
.task-card-tags { gap: 8px; flex-wrap: wrap; padding-right: 20px; }
.task-card-percent { margin-left: auto; color: var(--muted); font-size: 12px; font-variant-numeric: tabular-nums; }
.task-tag, .status-pill, .client-tag-chip, .offer-status-badge { font-size: 12px; font-weight: 500; border-radius: 4px; box-shadow: none; }
.task-tag { color: var(--muted); background: var(--surface-soft); border: 0; }
.task-tag.waiting, .task-tag.client, .task-tag.approval { color: #86652e; background: #faf3e6; }
.task-tag.blocked { color: #95463f; background: #faeeec; }
.task-tag.done { color: #396749; background: #eaf2eb; }
.task-tag.progress { color: var(--accent); background: var(--accent-soft); }
.task-tag.priority { background: var(--surface-soft); color: var(--muted); }
.task-next-step { font-size: 13px; line-height: 1.6; color: var(--muted); margin: 0 0 16px; }
.task-card-progress { height: 3px; }
.task-meta, .task-card-footer { font-size: 12px; font-weight: 400; color: var(--muted); }
.task-card-footer:empty { display: none; }
.task-assignee-badge { background: var(--accent-soft); color: var(--accent); font-weight: 500; box-shadow: none; }
.task-column.drop-target { outline: 2px solid var(--accent); outline-offset: -2px; }
.reading-layout { max-width: 78ch; margin-left: 0; }
.client-rich-note { border: 0; background: transparent; padding: 20px 0; }
.client-rich-editor, .meeting-note-body { font-size: 16px; line-height: 1.75; max-width: 70ch; }
.client-rich-editor { min-height: 100px; border-color: var(--line); background: var(--surface); }
.client-rich-note-head { flex-wrap: wrap; }
.client-meeting-note { padding: 24px 0; border: 0; border-top: 1px solid var(--line); background: var(--surface); box-shadow: none; }
.meeting-note-body h1, .meeting-note-body h2, .meeting-note-body h3 { font-size: 23px; font-weight: 600; line-height: 1.4; margin: 28px 0 14px; }
.meeting-note-body p, .meeting-note-body li { line-height: 1.75; }
.meeting-note-body strong { font-weight: 600; }
.global-feed-controls { grid-template-columns: minmax(0,1fr) 290px; gap: 32px; margin-bottom: 30px; }
.client-info-card { border-color: var(--line); background: var(--surface-soft); box-shadow: none; }
.client-feed { max-width: 78ch; }
.feed-item { border: 0; border-bottom: 1px solid var(--line); border-radius: 0; background: transparent; padding: 20px 0; }
.feed-item strong, .activity-item strong { font-weight: 500; font-size: 14px; }
.feed-item p, .activity-item p { font-size: 14px; line-height: 1.7; overflow-wrap: anywhere; }
.client-finance-panel { max-width: 1000px; margin-top: 24px; }
.client-finance-offer-card { border: 0; border-bottom: 1px solid var(--line); background: transparent; border-radius: 0; padding: 20px 0; }
.client-finance-grid { gap: 24px; padding: 24px 0; }
.client-finance-stat { border: 0; background: transparent; padding: 0; }
.client-finance-stat strong { font-size: 24px; font-weight: 500; font-variant-numeric: tabular-nums; }
.client-finance-stat span, .client-finance-stat small { color: var(--muted); font-size: 13px; }
.has-task-dialog { overflow: hidden; }
.task-modal-backdrop { padding: 24px; background: #23312a66; }
.task-modal[data-task-detail-id] { width: min(1180px,calc(100vw - 48px)); height: min(860px,calc(100dvh - 48px)); max-height: calc(100dvh - 48px); grid-template-columns: minmax(0,1fr) 320px; border-radius: 12px; box-shadow: 0 24px 90px #182d2733; }
.task-modal-main { padding: 28px 32px; }
.task-detail-head h2 { font-size: 28px; line-height: 1.3; letter-spacing: -.5px; font-weight: 600; }
.task-client-name { font-weight: 500; font-size: 13px; color: var(--muted); }
.task-type-pill { font-weight: 400; font-size: 12px; margin: 0; }
.task-detail-grid { grid-template-columns: repeat(3,minmax(0,1fr)); gap: 18px; }
.task-detail-grid .field:has([data-task-detail-field="title"]), .task-detail-grid .field:has([data-task-detail-field="blockedReason"]) { grid-column: 1/-1; }
.task-detail-grid textarea { min-height: 115px; line-height: 1.65; }
.task-detail-columns { grid-template-columns: minmax(0,1fr); gap: 28px; }
.task-activity { padding: 24px; border-left: 1px solid var(--line); background: var(--surface-soft); overflow-y: auto; }
.task-activity-head h3 { font-size: 16px; font-weight: 600; }
.task-comment-box { padding: 18px 0; border-color: var(--line); }
.task-comment-box textarea { min-height: 95px; background: var(--surface); font-size: 14px; line-height: 1.6; }
.activity-item { padding-bottom: 24px; }
.theme-options { display: grid; grid-template-columns: repeat(3,minmax(0,1fr)); gap: 14px; }
.new-task-modal { width: min(1180px,calc(100vw - 48px)); grid-template-columns: minmax(0,1fr) 320px; }
.theme-option { display: grid; gap: 10px; padding: 16px; text-align: left; color: var(--text); background: var(--surface); border: 1px solid var(--line-strong); border-radius: 7px; }
.theme-option[aria-pressed="true"] { outline: 2px solid var(--accent); outline-offset: 2px; }
.theme-option small { font-size: 13px; color: var(--muted); }
.theme-sample { display: block; height: 44px; border-radius: 4px; border-left: 14px solid; }
.theme-sage { background: #e7eee9; border-color: #315d4c; }
.theme-slate { background: #e8eef4; border-color: #3c5d79; }
.theme-sand { background: #f0e9df; border-color: #77563a; }
.theme-rose { background: #f4e3eb; border-color: #92516e; }
.theme-contrast { background: #dce8f7; border-color: #164b83; }
.settings-grid { gap: 24px; }
.settings-tabs { border: 0; padding: 0 0 16px; border-bottom: 1px solid var(--line); background: transparent; border-radius: 0; }
.settings-tab { font-weight: 500; }
.settings-tab.active { color: var(--accent); background: var(--accent-soft); }
.task-tag.progress, .status-pill.progress { height: auto; overflow: visible; }
.login-panel { max-width: 100%; }
@media (max-width: 1180px) {
  .app { grid-template-columns: 166px minmax(0,1fr); }
  .content { padding: 28px; }
  .overview-labels, .project-main { gap: 16px; }
  .client-summary-card { grid-template-columns: repeat(3,minmax(0,1fr)); gap: 18px; }
  .task-modal[data-task-detail-id] { grid-template-columns: minmax(0,1fr) 285px; }
  .new-task-modal { grid-template-columns: minmax(0,1fr) 240px; }
  .task-detail-grid { grid-template-columns: repeat(2,minmax(0,1fr)); }
  .workspace-overview-grid { grid-template-columns: minmax(0,1fr) 240px; gap: 24px; }
  .workspace-context { padding-left: 20px; }
}
@media (max-width: 760px) {
  .app, .app:has(.sidebar--collapsed) { display: block; }
  .sidebar, .sidebar--collapsed { position: static; padding: 12px; border-right: 0; border-bottom: 1px solid var(--line); gap: 10px; }
  .sidebar .logo-stack, .sidebar .sidebar-footer, .sidebar .sidebar-collapse-btn, .nav-section-title { display: none; }
  .sidebar .nav { display: flex; gap: 4px; overflow-x: auto; padding: 0; }
  .sidebar .nav-link, .sidebar .nav-link.subitem { flex-shrink: 0; width: auto; display: flex; align-items: center; gap: 6px; white-space: nowrap; padding: 8px 10px; }
  .sidebar--collapsed .nav-link span { display: inline; }
  .sidebar--collapsed .nav-link { width: auto; }
  .sidebar--collapsed .nav-link::after { display: none; }
  .topbar { padding: 14px 20px; gap: 10px; }
  .topbar h1 { font-size: 16px; }
  .content { padding: 24px 20px 50px; }
  .overview-labels { display: none; }
  .project-main { grid-template-columns: repeat(2,minmax(0,1fr)); gap: 20px; padding: 17px; }
  .project-main > :nth-child(3), .project-main > :nth-child(4), .project-main > :nth-child(5) { grid-column: 1/-1; }
  .project-main [data-label]::before { display: block; content: attr(data-label); font-size: 12px; color: var(--muted); margin-bottom: 6px; }
  .project-footer { display: block; padding: 12px 17px; }
  .project-team { display: block; margin-top: 12px; text-align: left; }
  .project-footer-tools { margin-top: 12px; }
  .project-footer-tools .project-team { margin-top: 0; }
  .client-detail-hero { gap: 18px; flex-wrap: wrap; }
  .client-detail-hero h2 { font-size: 29px; }
  .client-hero-progress { width: 150px; }
  .client-summary-card { grid-template-columns: repeat(2,minmax(0,1fr)); gap: 18px; }
  .client-tabs { gap: 24px; margin-bottom: 24px; }
  .workspace-overview-grid { grid-template-columns: minmax(0,1fr); gap: 30px; }
  .workspace-context { border-left: 0; padding: 24px 0 0; border-top: 1px solid var(--line); }
  .focus-row { align-items: start; flex-direction: column; gap: 10px; }
  .drive-document-item { flex-wrap: wrap; }
  .drive-document-copy { min-width: 0; }
  .drive-document-actions { flex-wrap: wrap; }
  .client-finance-grid { grid-template-columns: repeat(2,minmax(0,1fr)); }
  .client-finance-panel-head, .client-finance-offer-card { flex-wrap: wrap; }
  .client-finance-head-actions { flex-wrap: wrap; }
  .global-feed-controls { grid-template-columns: minmax(0,1fr); }
  .task-modal-backdrop { padding: 10px; }
  .task-modal[data-task-detail-id] { display: block; width: calc(100vw - 20px); height: auto; max-height: calc(100dvh - 20px); overflow-y: auto; }
  .new-task-modal { display: block; width: calc(100vw - 20px); height: auto; max-height: calc(100dvh - 20px); overflow-y: auto; }
  .new-task-modal .task-modal-main { overflow: visible; padding: 23px 20px; }
  .task-modal[data-task-detail-id] .task-modal-main { overflow: visible; padding: 23px 20px; }
  .task-detail-head { flex-wrap: wrap; }
  .task-detail-head h2 { font-size: 23px; }
  .task-modal-actions { margin-left: auto; }
  .task-detail-grid { grid-template-columns: repeat(2,minmax(0,1fr)); gap: 14px; }
  .task-activity { overflow: visible; border-left: 0; border-top: 1px solid var(--line); padding: 23px 20px; }
  .inline-form { flex-wrap: wrap; }
  .inline-form input { min-width: 0; max-width: 100%; }
  .theme-options { grid-template-columns: minmax(0,1fr); }
  .settings-grid { grid-template-columns: minmax(0,1fr); }
  .grid-table { font-size: 13px; }
}
@media (prefers-reduced-motion: reduce) { button, .app, .sidebar { transition: none; } }
