:root {
  --bg: #f4f7f8;
  --surface: #fff;
  --text: #132126;
  --muted: #637780;
  --line: #d9e4e8;
  --brand: #176875;
  --brand-dark: #0f4d58;
  --brand-accent: #d92d20;
  --soft: #f8fbfc;
  --red: #b4352b;
  --red-bg: #ffe8e5;
  --amber: #8a6200;
  --amber-bg: #fff2c8;
  --green: #176b39;
  --green-bg: #e4f4ea;
}

* { box-sizing: border-box; }
body { margin: 0; background: var(--bg); color: var(--text); font: 14px/1.42 "Segoe UI", Arial, sans-serif; }
button, input, select, textarea { font: inherit; }
a { color: inherit; text-decoration: none; }

.login-shell { min-height: 100vh; display: grid; place-items: center; padding: 24px; }
.login-card { width: min(420px, 100%); display: grid; gap: 14px; background: var(--surface); border: 1px solid var(--line); border-radius: 10px; padding: 26px; box-shadow: 0 18px 44px rgba(19,33,38,.08); }
.login-card h1 { margin: 6px 0 0; font-size: 30px; }
.brand { display: flex; gap: 11px; align-items: center; }
.brand.brand-stack { display: grid; gap: 4px; align-items: start; }
.brand-wordmark { width: 206px; height: 38px; display: block; overflow: hidden; }
.brand-wordmark.large { width: 300px; height: 54px; }
.brand-wordmark.report { width: 220px; height: 40px; }
.brand-wordmark img { width: 100%; height: 100%; object-fit: contain; object-position: left center; display: block; }
.login-card .brand.brand-stack { justify-items: center; }
.login-card .brand-wordmark.large { width: min(320px, 100%); justify-self: center; }
.login-card .brand-wordmark img { object-position: center center; }
.brand-mark { width: 34px; height: 34px; display: block; flex: 0 0 auto; overflow: hidden; }
.brand-mark.large { width: 42px; height: 42px; }
.brand-mark img { width: 100%; height: 100%; object-fit: contain; display: block; }
.brand strong, .brand small { display: block; }
.brand small, .hint, .role small, .top small, td small { color: var(--muted); }
.side { margin-bottom: 18px; }
.side .brand-wordmark { width: 206px; height: 38px; }
.side small { padding-left: 1px; color: #a9d6e5; font-size: 18px; line-height: 1.15; font-weight: 500; }

label { display: grid; gap: 5px; color: var(--muted); font-size: 12px; font-weight: 700; }
input, select, textarea { width: 100%; min-height: 34px; border: 1px solid var(--line); border-radius: 7px; padding: 6px 8px; background: #fff; color: var(--text); }
textarea { min-height: 52px; resize: vertical; }
input:focus, select:focus, textarea:focus { outline: 2px solid rgba(23,104,117,.16); border-color: var(--brand); }

button, .primary, .ghost, .danger { min-height: 34px; border-radius: 7px; padding: 0 12px; border: 1px solid transparent; cursor: pointer; }
.primary { background: var(--brand); color: #fff; }
.primary:hover { background: var(--brand-dark); }
button:disabled, .primary:disabled { cursor: not-allowed; opacity: .45; }
.ghost { background: #fff; color: var(--text); border-color: var(--line); }
.danger { background: var(--red-bg); color: var(--red); border-color: #ffc8c1; }
.small { min-height: 28px; padding: 0 9px; }
.full { width: 100%; }

.shell { min-height: 100vh; display: grid; grid-template-columns: 246px minmax(0, 1fr); }
aside { position: sticky; top: 0; height: 100vh; padding: 18px 12px; background: #102d36; color: #fff; display: flex; flex-direction: column; }
nav { display: grid; gap: 4px; }
nav a { min-height: 38px; display: flex; align-items: center; border-radius: 8px; padding: 0 12px; color: #d7e8ed; }
nav a:hover { background: rgba(255,255,255,.08); }
nav a.active { background: #fff; color: #102d36; font-weight: 700; }
.sidebar-meeting { margin-top: auto; margin-bottom: 10px; border: 1px solid rgba(169,214,229,.24); border-radius: 10px; padding: 13px; display: grid; gap: 7px; background: linear-gradient(180deg, rgba(255,255,255,.055), rgba(255,255,255,.025)); box-shadow: inset 0 1px 0 rgba(255,255,255,.04); }
.sidebar-meeting.is-active { border-color: rgba(221,82,72,.52); background: linear-gradient(180deg, rgba(180,53,43,.18), rgba(255,255,255,.025)); }
.sidebar-meeting span { color: #9eb9c1; font-size: 11px; font-weight: 800; text-transform: uppercase; letter-spacing: .08em; }
.sidebar-meeting strong { color: #fff; font-size: 15px; line-height: 1.2; }
.sidebar-meeting small { color: #b8d0d7; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.sidebar-meeting form { margin-top: 5px; }
.sidebar-meeting-button { width: 100%; min-height: 42px; border: 1px solid rgba(255,255,255,.14); border-radius: 9px; background: #17834c; color: #fff; font-size: 17px; font-weight: 900; display: inline-flex; align-items: center; justify-content: center; gap: 10px; box-shadow: 0 10px 22px rgba(0,0,0,.18), inset 0 1px 0 rgba(255,255,255,.18); }
.sidebar-meeting-button::before { content: ""; width: 0; height: 0; border-top: 7px solid transparent; border-bottom: 7px solid transparent; border-left: 11px solid currentColor; transform: translateX(1px); }
.sidebar-meeting-button:hover { background: #1a9657; color: #fff; }
.sidebar-meeting.is-active .sidebar-meeting-button { background: #b4352b; }
.sidebar-meeting.is-active .sidebar-meeting-button::before { width: 13px; height: 13px; border: 0; background: currentColor; border-radius: 2px; transform: none; }
.sidebar-meeting.is-active .sidebar-meeting-button:hover { background: #c63d32; }
.role { margin-top: auto; border: 1px solid rgba(255,255,255,.14); border-radius: 8px; padding: 12px; display: grid; gap: 4px; }
.sidebar-meeting + .role { margin-top: 0; }
.role span { font-weight: 700; }
.role small { color: #b8d0d7; }
.logout-button { width: 100%; min-height: 30px; margin-top: 6px; border: 1px solid rgba(255,255,255,.16); border-radius: 7px; background: transparent; color: #b8d0d7; font-weight: 700; }
.logout-button:hover { background: rgba(255,255,255,.07); color: #fff; }

.main { min-width: 0; padding: 22px; }
.top { display: flex; justify-content: space-between; align-items: flex-start; gap: 16px; margin-bottom: 16px; }
.top p { margin: 0 0 5px; color: var(--muted); font-size: 11px; text-transform: uppercase; letter-spacing: .08em; }
h1, h2, h3 { margin: 0; letter-spacing: 0; }
h1 { font-size: 30px; line-height: 1.1; }
h2 { font-size: 18px; margin-bottom: 12px; }

.rate-note { border: 1px solid var(--line); border-radius: 999px; background: #fff; color: var(--muted); padding: 7px 11px; font-size: 12px; font-weight: 700; }
.cockpit-grid { display: grid; grid-template-columns: minmax(320px, 1.05fr) minmax(320px, 1fr); gap: 14px; margin-bottom: 14px; }
.cockpit-grid .agenda-panel { grid-column: 1 / -1; }
.panel-head { margin-bottom: 12px; }
.panel-head p { margin: 0 0 4px; color: var(--muted); font-size: 11px; text-transform: uppercase; letter-spacing: .08em; font-weight: 800; }
.signal-grid, .metrics { display: grid; grid-template-columns: repeat(3, minmax(120px, 1fr)); gap: 10px; }
.metrics { grid-template-columns: repeat(6, minmax(140px, 1fr)); margin-bottom: 14px; }
.metric { min-height: 98px; background: var(--surface); border: 1px solid var(--line); border-radius: 8px; padding: 13px; display: grid; align-content: space-between; }
.metric span { color: var(--muted); font-size: 12px; font-weight: 700; }
.metric strong { font-size: 25px; line-height: 1; }
.metric.red { background: var(--red-bg); border-color: #ffc8c1; }
.metric.amber { background: var(--amber-bg); border-color: #edd38b; }
.metric.green { background: var(--green-bg); border-color: #bdddc9; }

.panel { background: var(--surface); border: 1px solid var(--line); border-radius: 8px; padding: 14px; margin-bottom: 14px; }
.compact summary { cursor: pointer; font-weight: 700; }
.closed-block summary { cursor: pointer; color: var(--muted); font-size: 13px; font-weight: 700; }
.closed-block[open] summary { color: #38515a; }
.closed-block { margin-top: 14px; }
.closed-block[open] { background: #fbfdfe; }
.tiles { display: grid; grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); gap: 9px; }
.compact-tiles { grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); }
.tile { border: 1px solid var(--line); border-radius: 8px; padding: 13px; background: #f8fbfc; }
.tile span, .tile strong, .tile small { display: block; }
.tile strong { margin-top: 8px; font-size: 24px; }
.danger { display: grid; grid-template-columns: minmax(0, 1fr) minmax(280px, max-content); gap: 16px; align-items: center; margin: 7px 0; padding: 11px 14px; border: 1px solid #e2ebee; border-left: 3px solid #b94a42; border-radius: 7px; background: #fff; color: var(--text); }
.danger:hover { background: #f8fbfc; border-color: #d2e0e5; border-left-color: var(--red); }
.danger strong, .danger-main > span, .danger small { display: block; }
.danger strong { color: #9e332c; }
.danger-main > span { color: #24343a; }
.danger small { color: var(--muted); }
.danger-main { min-width: 0; }
.danger-tags { display: flex; justify-content: flex-end; flex-wrap: wrap; gap: 7px; max-width: 560px; }
.danger-badge { min-height: 30px; display: inline-flex; align-items: center; white-space: nowrap; border: 1px solid #e3ecef; border-radius: 999px; background: #f6f8f9; color: #40555e; padding: 0 12px; font-size: 12px; font-weight: 800; }
.danger-badge.badge-red { background: #fff7f6; border-color: #edc8c3; color: #8f3b34; }
.danger-badge.badge-amber { background: #fffaf0; border-color: #ead9a7; color: #7a5a0b; }
.danger-badge.badge-muted { background: #f5f8f9; border-color: #e2ebee; color: #5f747d; }
.money-panel { display: grid; gap: 10px; align-content: start; }
.money-line { display: grid; grid-template-columns: 120px minmax(150px, 1fr) minmax(120px, .8fr) 54px; gap: 8px; align-items: center; min-height: 42px; border: 1px solid var(--line); border-radius: 8px; padding: 8px 10px; background: var(--soft); }
.money-line span, .money-line small { color: var(--muted); font-size: 12px; font-weight: 700; }
.money-line strong, .money-line b { font-size: 18px; }
.money-line.green { border-color: #bdddc9; background: var(--green-bg); }
.money-line.red { border-color: #ffc8c1; background: var(--red-bg); }
.money-donut-card { width: min(760px, 100%); justify-self: center; display: grid; grid-template-columns: 190px minmax(320px, 1fr); gap: 22px; align-items: center; padding: 8px 0 14px; }
.money-donut { width: 174px; aspect-ratio: 1; border-radius: 50%; background: conic-gradient(var(--green) 0 var(--incoming-deg), var(--red) var(--incoming-deg) 360deg); position: relative; box-shadow: inset 0 0 0 1px rgba(19,33,38,.08); }
.money-donut::after { content: ""; position: absolute; inset: 42px; border-radius: 50%; background: var(--surface); border: 1px solid var(--line); }
.money-donut-values { display: grid; gap: 2px; }
.money-figure { display: grid; grid-template-columns: 112px minmax(0, 1fr); gap: 2px 12px; align-items: baseline; padding: 8px 0; border-bottom: 1px solid #eef3f5; background: transparent; color: var(--text); }
.money-figure:last-child { border-bottom: 0; }
.money-figure span { grid-row: span 2; color: var(--muted); font-size: 12px; font-weight: 700; }
.money-figure strong { font-size: 24px; line-height: 1; font-weight: 700; letter-spacing: 0; }
.money-figure small { grid-column: 2; color: var(--muted); font-size: 13px; font-weight: 650; }
.money-figure.tone-green strong { color: var(--green); }
.money-figure.tone-red strong { color: var(--red); }
.meeting-lock { display: flex; justify-content: space-between; align-items: center; gap: 12px; background: #fbfdfe; }
.meeting-lock strong, .meeting-lock span { display: block; }
.meeting-lock span { color: var(--muted); }
.report-top, .report-action-panel, .report-doc { max-width: 1120px; width: 100%; }
.report-action-panel { display: flex; align-items: center; justify-content: space-between; gap: 16px; }
.report-action-panel h2 { margin-bottom: 3px; }
.report-action-panel small { color: var(--muted); font-weight: 700; }
.report-send-button { min-height: 40px; padding: 0 16px; font-weight: 800; }
.admin-mail-grid { display: grid; grid-template-columns: minmax(340px, .8fr) minmax(520px, 1.2fr); gap: 14px; align-items: stretch; max-width: 1480px; margin-bottom: 14px; }
.admin-mail-grid .panel { margin: 0; }
.admin-mail-panel, .admin-invite-panel, .admin-user-panel, .admin-lower-grid { max-width: 1480px; }
.settings-form textarea { min-height: 76px; resize: vertical; }
.invite-form textarea { min-height: 76px; resize: vertical; }
.recipients-form { display: grid; grid-template-columns: minmax(220px, 1fr) 132px; gap: 10px; align-items: end; }
.recipients-form .primary { width: 100%; }
.invite-form { display: grid; gap: 10px; }
.invite-actions { display: grid; grid-template-columns: minmax(240px, 1fr) 132px; gap: 10px; align-items: end; }
.invite-actions .primary { width: 100%; }
.user-create-form { display: grid; grid-template-columns: minmax(150px, 1fr) minmax(170px, 1fr) minmax(220px, 1.25fr) 150px minmax(150px, .85fr) 132px; gap: 10px; align-items: end; }
.user-create-form .primary { width: 100%; }
.admin-mail-grid .primary, .admin-user-panel .primary, .admin-compact-panel .ghost, .admin-row-actions .text-btn { min-height: 30px; height: 30px; border-radius: 6px; padding: 0 10px; font-size: 13px; font-weight: 750; }
.admin-compact-panel .ghost, .admin-row-actions .quiet-btn { background: #f4f8f9; border-color: #dce7eb; color: #38515a; }
.admin-row-actions .text-btn { min-width: 82px; }
.admin-row-actions .delete-btn { background: #fff6f4; border-color: #f0d2cd; color: #a33a31; }
.admin-row-actions .save-btn { background: var(--brand); border-color: var(--brand); color: #fff; }
.admin-lower-grid { display: grid; grid-template-columns: minmax(520px, 1.15fr) minmax(340px, .85fr); gap: 14px; }
.admin-compact-panel { padding: 12px 14px; }
.admin-compact-panel h2 { font-size: 17px; }
.admin-list { display: grid; gap: 6px; }
.admin-row { min-height: 42px; display: grid; grid-template-columns: minmax(0, 1fr) max-content; gap: 12px; align-items: center; padding: 7px 0; border-top: 1px solid #edf2f4; }
.admin-row:first-child { border-top: 0; }
.admin-row strong, .admin-row span { display: block; }
.admin-row strong { font-size: 13px; }
.admin-row span, .admin-row small { color: var(--muted); font-size: 12px; }
.admin-row small { white-space: nowrap; }
.admin-row-actions { display: inline-flex; align-items: center; justify-content: flex-end; gap: 6px; }
.admin-row-actions form { display: inline-flex; margin: 0; }
.admin-user-edit-row { grid-template-columns: minmax(130px, 1fr) minmax(120px, .9fr) 130px minmax(120px, .9fr) max-content; gap: 10px; align-items: end; padding: 10px 0; }
.admin-user-edit-row label { min-width: 0; }
.admin-user-edit-row .admin-row-actions { justify-content: flex-end; }
.compact-empty { margin: 0; }

.filters, .create-grid { display: grid; grid-template-columns: minmax(240px, 1fr) repeat(3, minmax(140px, 190px)) auto; gap: 8px; align-items: end; margin-bottom: 12px; }
.create-grid { grid-template-columns: repeat(4, minmax(160px, 1fr)); align-items: end; margin-top: 12px; }
.table { overflow: auto; background: var(--surface); border: 1px solid var(--line); border-radius: 8px; }
table { width: 100%; min-width: 1120px; border-collapse: collapse; table-layout: fixed; font-size: 13px; }
.task-table { min-width: 1320px; }
.task-table.with-money { min-width: 1500px; }
th { position: sticky; top: 0; z-index: 1; text-align: left; padding: 8px 10px; color: #38515a; background: #eef5f7; border-bottom: 1px solid var(--line); font-size: 11px; }
th .sort-link { display: inline-flex; gap: 4px; align-items: center; color: #38515a; }
th .sort-link:hover, th .sort-link.active { color: var(--brand-dark); }
td { vertical-align: middle; padding: 9px 10px; border-bottom: 1px solid #e8eef1; }
tr:hover { background: #f9fbfc; }
.task-table tbody tr, .task-table tr.row-red, .task-table tr.row-yellow, .task-table tr.row-green { background: #fff; }
.task-table tbody tr:hover, .task-table tr.row-red:hover, .task-table tr.row-yellow:hover, .task-table tr.row-green:hover { background: #f9fbfc; }
.task-table tr.is-saving td:first-child { box-shadow: inset 3px 0 0 #bfd0d6; }
.task-table tr.save-error td:first-child { box-shadow: inset 3px 0 0 var(--red); }
.task-table tr:target { outline: 2px solid var(--brand); outline-offset: -2px; background: #eef9fb; }
.task-table tr:target td:first-child { box-shadow: inset 3px 0 0 var(--brand); }
.task-table .c-risk { width: 58px; }
.task-table .c-project { width: 215px; }
.task-table .c-issue { width: auto; }
.task-table .c-next { width: 340px; }
.task-table .c-owner { width: 136px; }
.task-table .c-status { width: 180px; }
.task-table .c-date { width: 150px; }
.task-table .c-money { width: 210px; }
.task-table .c-actions { width: 84px; }
.task-table th:first-child { text-align: center; }
.task-table th:last-child { text-align: center; }
.closed-task-table { min-width: 980px; }
.closed-task-table .c-project { width: 260px; }
.closed-task-table .c-issue { width: auto; }
.closed-task-table .c-closed-date { width: 145px; }
.closed-task-table .c-owner { width: 150px; }
.closed-task-table .c-actions { width: 84px; }
.closed-task-table .closed-row, .closed-task-table .closed-row:hover { background: #fff; }
.closed-task-table th:first-child { text-align: left; }
.closed-date { color: var(--muted); font-weight: 700; white-space: nowrap; }
.project-cell { font-weight: 650; }
.row-project { display: block; font-weight: 700; line-height: 1.35; }
.row-id { display: none; }
.task-cell, .next-cell { line-height: 1.45; overflow-wrap: anywhere; }
.next-cell { color: #42565e; }
.actions-cell { text-align: center; white-space: nowrap; vertical-align: middle; padding-left: 6px; padding-right: 6px; }
.row-actions { display: inline-flex; gap: 5px; align-items: center; justify-content: center; vertical-align: middle; }
.row-actions form { display: inline-flex; margin: 0; }
.risk-cell { text-align: center; vertical-align: middle; }
.icon-btn { width: 34px; min-width: 34px; height: 32px; min-height: 32px; padding: 0; margin: 0; border-radius: 7px; border: 1px solid var(--line); display: inline-grid; place-items: center; cursor: pointer; font-weight: 800; font-size: 12px; line-height: 1; background: #eef5f7; color: #38515a; }
.text-btn { height: 32px; min-height: 32px; padding: 0 10px; margin: 0; border-radius: 7px; border: 1px solid var(--line); display: inline-flex; align-items: center; justify-content: center; cursor: pointer; font-weight: 800; white-space: nowrap; }
.quiet-btn, .save-btn, .close-btn, .reopen-btn { background: #eef5f7; color: #38515a; border-color: #d9e4e8; }
.quiet-btn:hover, .save-btn:hover, .close-btn:hover, .reopen-btn:hover { background: #dfeaec; }
.delete-btn { background: #fff3f1; color: var(--red); border-color: #ffd8d2; }
.delete-btn:hover { background: #ffe5e0; }
.delete-text-btn { background: var(--red-bg); color: var(--red); border-color: #ffc8c1; }
.edit-link, .cancel-link { min-height: 32px; padding: 0 10px; border: 1px solid var(--line); border-radius: 7px; background: #fff; display: inline-flex; align-items: center; justify-content: center; font-weight: 700; white-space: nowrap; }
.delete { width: 42px; }
.money { display: grid; grid-template-columns: minmax(112px, 1fr) 70px; gap: 6px; }
.money input, .money select { min-width: 0; }
.table-control { width: 100%; min-height: 34px; border-color: transparent; background: transparent; border-radius: 6px; padding: 5px 7px; line-height: 1.35; }
.task-table tr:hover .table-control, .table-control:focus { border-color: var(--line); background: #fff; }
.table-control:invalid { border-color: #f1b2a9; background: #fff8f7; }
textarea.table-control { resize: none; overflow: hidden; }
.amount-control { text-align: right; font-variant-numeric: tabular-nums; }
.date-empty { position: relative; min-height: 34px; display: flex; align-items: flex-start; }
.date-empty .empty-date-control { position: absolute; inset: 0; opacity: 0; cursor: pointer; }
.date-picker { position: relative; display: inline-flex; align-items: center; gap: 5px; max-width: 100%; min-height: 34px; cursor: pointer; }
.date-input-hidden { position: absolute; inset: 0; opacity: 0; cursor: pointer; }
.date-picker .pill { margin-top: 0; max-width: calc(100% - 24px); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.date-plus { width: 18px; height: 18px; border: 1px solid var(--line); border-radius: 5px; display: inline-grid; place-items: center; color: var(--muted); background: #fff; font-size: 12px; font-weight: 800; }
.date-picker:hover .date-plus { border-color: #bfd0d6; color: var(--brand-dark); }
.project-control { font-weight: 650; }
.task-control, .next-control { min-height: 58px; }
.next-control { color: #42565e; }
.editing-row { background: #fffef7; }
.status-chip { display: inline-flex; min-height: 24px; align-items: center; border-radius: 999px; background: #eef5f7; color: #38515a; padding: 3px 8px; font-size: 12px; font-weight: 800; }
.type-pill { display: inline-flex; border-radius: 999px; background: #e9f0f2; color: #38515a; padding: 3px 8px; font-size: 12px; font-weight: 700; }
.task-cards { display: none; }
.pill, .risk { display: inline-flex; margin-top: 5px; border-radius: 999px; padding: 3px 8px; font-size: 12px; font-weight: 700; }
.risk-square { width: 30px; min-width: 30px; height: 30px; min-height: 30px; display: inline-block; border-radius: 8px; border: 1px solid transparent; padding: 0; color: transparent; font-size: 0; line-height: 0; vertical-align: middle; cursor: pointer; appearance: none; -webkit-appearance: none; background-image: none; box-shadow: inset 0 0 0 1px rgba(255,255,255,.35); }
.risk-square option { background: #fff !important; color: var(--text); font-size: 13px; }
.risk-square option:checked { background: #eef5f7 !important; color: var(--text); }
.risk-red { background: #e8847c; border-color: #d46a61; }
.risk-yellow { background: #e8c85e; border-color: #d7b447; }
.risk-green { background: #78bd93; border-color: #5ca778; }
.red { background: var(--red-bg); color: var(--red); }
.amber { background: var(--amber-bg); color: var(--amber); }
.green { background: var(--green-bg); color: var(--green); }
.muted { background: #e9f0f2; color: var(--muted); }
.empty { color: var(--muted); padding: 12px; }
.closed-empty { padding: 10px 14px; }
.closed-empty summary { margin: 0; }
.error { color: var(--red); background: var(--red-bg); border: 1px solid #ffc8c1; border-radius: 7px; padding: 9px; }

.report-cover, .report-section { background: var(--surface); border: 1px solid var(--line); border-radius: 8px; padding: 18px; margin-bottom: 14px; }
.report-cover h1 { font-size: 38px; }
.report-brand { display: inline-flex; align-items: center; margin-bottom: 16px; color: #38515a; font-weight: 800; }
.meeting-report-block { display: grid; grid-template-columns: repeat(3, minmax(120px, 1fr)); gap: 8px; margin: 14px 0; }
.meeting-report-block > div { border: 1px solid var(--line); border-radius: 8px; padding: 9px 10px; background: #fbfdfe; }
.meeting-report-block strong, .meeting-report-block span { display: block; }
.meeting-report-block strong { color: var(--muted); font-size: 11px; }
.meeting-report-block span { margin-top: 4px; font-weight: 800; }
.report-summary { display: grid; grid-template-columns: repeat(4, minmax(130px, 1fr)); gap: 10px; margin: 16px 0; }
.report-money { display: grid; gap: 8px; }
.report-table { min-width: 0; table-layout: fixed; }
.report-table td { vertical-align: middle; }
.report-table .r-risk { width: 52px; }
.report-table .r-project { width: 20%; }
.report-table .r-issue { width: auto; }
.report-table .r-owner { width: 14%; }
.report-table .r-status { width: 14%; }
.report-table .r-date { width: 10%; }
.report-table .r-closed-date { width: 14%; }
.report-table td small { display: block; margin-top: 3px; line-height: 1.35; }
.report-risk-cell { text-align: center; vertical-align: middle; }
.report-risk-dot { width: 24px; min-width: 24px; height: 24px; min-height: 24px; cursor: default; }
.active-report-table th:first-child { text-align: center; }
.closed-report-table .r-project { width: 24%; }
.closed-report-table .r-issue { width: auto; }
.closed-report-table .r-owner { width: 16%; }
.section-head { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; margin-bottom: 12px; }
.section-head h2 { margin-bottom: 0; }
.section-head small { color: var(--muted); font-weight: 700; }
.admin-journal-panel { max-width: 1480px; }
.audit-section-head { align-items: flex-end; }
.audit-list { border: 1px solid var(--line); border-radius: 8px; overflow: hidden; background: #fff; }
.audit-head, .audit-row { display: grid; grid-template-columns: minmax(150px, .85fr) minmax(280px, 2fr) minmax(120px, .6fr) 150px; gap: 14px; align-items: center; }
.audit-head { min-height: 34px; padding: 8px 14px; background: #edf5f7; color: #38515a; font-size: 11px; font-weight: 850; letter-spacing: .04em; text-transform: uppercase; border-bottom: 1px solid #d7e4e8; }
.audit-row { min-height: 42px; padding: 8px 14px; border-bottom: 1px solid #edf2f4; }
.audit-row:last-child { border-bottom: 0; }
.audit-row strong, .audit-row span, .audit-row small, .audit-row time { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.audit-row strong { color: #0c2230; font-size: 13px; font-weight: 800; }
.audit-row span { color: #40555e; font-size: 12px; }
.audit-row small, .audit-row time { color: var(--muted); font-size: 12px; font-weight: 650; }
.audit-row time { text-align: right; }
.pager { display: flex; gap: 6px; align-items: center; justify-content: flex-end; margin-top: 12px; }
.pager a, .pager span { min-width: 32px; min-height: 30px; display: inline-flex; align-items: center; justify-content: center; border: 1px solid var(--line); border-radius: 7px; padding: 0 10px; background: #fff; color: #38515a; font-weight: 700; }
.pager a.active { background: var(--brand); border-color: var(--brand); color: #fff; }
.pager span { color: var(--muted); background: #f5f8f9; }

@media print {
  aside, .top form, .filters, details { display: none !important; }
  .shell { display: block; }
  .main { padding: 0; }
  .panel, .report-cover, .report-section, .table { border: 0; }
  .report-cover, .report-section { page-break-after: always; break-after: page; }
  .report-section:last-child { page-break-after: auto; break-after: auto; }
  .report-table { min-width: 0; font-size: 10px; }
}

@media (max-width: 1100px) {
  .shell { grid-template-columns: 1fr; }
  aside { position: static; height: auto; overflow: hidden; max-width: 100vw; }
  nav { display: flex; overflow-x: auto; max-width: 100%; min-width: 0; }
  nav a { white-space: nowrap; }
  .role, .sidebar-meeting, aside form, .side { display: none; }
  .metrics { grid-template-columns: repeat(2, minmax(140px, 1fr)); }
  .cockpit-grid { grid-template-columns: 1fr; }
  .signal-grid { grid-template-columns: repeat(2, minmax(120px, 1fr)); }
  .filters, .create-grid, .user-create-form, .recipients-form, .invite-actions, .admin-mail-grid, .admin-lower-grid, .admin-user-edit-row { grid-template-columns: 1fr; }
  .meeting-lock { align-items: stretch; flex-direction: column; }
  .meeting-report-block { grid-template-columns: repeat(2, minmax(120px, 1fr)); }
  .danger { grid-template-columns: 1fr; }
  .danger-tags { justify-content: flex-start; max-width: none; }
}

@media (max-width: 700px) {
  body { overflow-x: hidden; }
  .main { padding: 22px; }
  .top { display: block; }
  .rate-note { display: inline-flex; margin-top: 10px; }
  nav { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 5px; overflow: visible; }
  nav a { min-width: 0; min-height: 34px; justify-content: center; padding: 0 6px; white-space: normal; text-align: center; }
  .table { display: none; }
  .task-cards { display: grid; gap: 10px; }
  .task-card { background: #fff; border: 1px solid var(--line); border-radius: 8px; padding: 12px; display: grid; gap: 8px; }
  .task-card.hot { border-color: #ffc8c1; background: #fffafa; }
  .task-card div, .task-card footer { display: flex; justify-content: space-between; gap: 8px; flex-wrap: wrap; }
  .task-card p { margin: 0; }
  .task-card small { color: var(--muted); }
  .compact { display: none; }
  .money-line { grid-template-columns: 1fr; align-items: start; }
  .meeting-report-block { grid-template-columns: 1fr; }
}
