:root {
  --ink: #1d2924;
  --muted: #66716c;
  --line: #dce2de;
  --line-strong: #c5cec8;
  --surface: #ffffff;
  --surface-soft: #f5f7f5;
  --surface-active: #f3f8f4;
  --green: #244d3b;
  --green-2: #316a50;
  --header-green: #213249;
  --header-green-active: #2a3d57;
  --brand-gold: #d2ad57;
  --gold: #997934;
  --danger: #bd2929;
  --row-label-width: 220px;
  --year-width: 118px;
  --actions-width: 148px;
  --month-width: 100px;
  color-scheme: light;
  font-family: Inter, "Segoe UI", Arial, sans-serif;
}

* { box-sizing: border-box; }

body {
  margin: 0;
  min-width: 0;
  overflow-x: hidden;
  background: #eef2ef;
  color: var(--ink);
}

button, input, select { font: inherit; }
button { cursor: pointer; }
button:disabled { cursor: not-allowed; }

.app-header {
  display: flex;
  align-items: center;
  justify-content: flex-start;
  gap: 28px;
  min-height: 68px;
  padding: 0 32px;
  background: var(--header-green);
  color: #fff;
}

.brand { display: flex; align-items: center; color: inherit; text-decoration: none; }
.brand strong { color: var(--brand-gold); font-size: 19px; font-weight: 600; letter-spacing: .09em; }
.home-nav-action { display: inline-flex; flex: 0 0 auto; align-items: center; gap: 6px; min-height: 36px; margin-left: -12px; border: 0; border-left: 1px solid rgba(220, 227, 231, .28); padding: 0 12px; color: #dce3e7; background: transparent; font-size: 12px; font-weight: 600; white-space: nowrap; }
.home-nav-action:hover { color: #fff; background: rgba(255, 255, 255, .06); }
.home-nav-action:focus-visible { border-radius: 4px; outline: 2px solid rgba(210, 173, 87, .9); outline-offset: 2px; }
.home-nav-action svg { width: 17px; height: 17px; }

.main-nav { display: flex; align-self: stretch; min-width: 0; margin-right: auto; }
.main-nav button { flex: 0 0 auto; border: 0; border-bottom: 3px solid transparent; padding: 0 17px; background: transparent; color: #dce3e7; white-space: nowrap; }
.main-nav button.active { border-bottom-color: var(--brand-gold); background: var(--header-green-active); color: #fff; font-weight: 650; }
.main-nav button:disabled { opacity: .62; }
.session-controls { display: flex; align-items: center; gap: 9px; color: #dce3e7; font-size: 12px; white-space: nowrap; }
.session-user-role::before { content: "·"; margin-right: 9px; color: #aebbc5; }
.logout-action { border: 0; padding: 4px 0; background: transparent; color: #df9696; font: inherit; font-weight: 600; text-decoration: none; }
.logout-action:hover { color: #ffd0d0; text-decoration: underline; text-underline-offset: 3px; }
.logout-action:focus-visible { border-radius: 3px; outline: 2px solid rgba(255, 208, 208, .8); outline-offset: 3px; }
body:not(.is-authenticated) .app-header,
body:not(.is-authenticated) main { visibility: hidden; }
.login-modal { width: min(400px, calc(100vw - 32px)); padding: 0; border: 1px solid var(--line); border-radius: 10px; box-shadow: 0 18px 55px rgba(18, 29, 24, .22); }
.login-modal::backdrop { background: rgba(20, 31, 27, .56); }
.login-modal form { display: grid; gap: 15px; padding: 27px; }
.login-modal h2 { margin: -7px 0 4px; font-size: 23px; font-weight: 600; }
.login-modal .modal-actions { margin-top: 2px; }
.login-modal .button { width: 100%; }

main { min-width: 0; padding: 21px 32px 48px; }
.page-heading { display: flex; justify-content: space-between; align-items: end; gap: 32px; max-width: 1800px; margin: 0 auto 14px; }
.eyebrow { margin: 0 0 7px; color: var(--gold); font-size: 12px; font-weight: 800; letter-spacing: .11em; text-transform: uppercase; }
h1 { margin: 0; font-size: 30px; font-weight: 700; }
.intro { max-width: 720px; margin: 8px 0 0; color: var(--muted); }
.year-controls label { display: block; margin-bottom: 7px; color: var(--muted); font-size: 12px; font-weight: 700; }
.year-controls > div { display: flex; gap: 9px; }
select, .button { min-height: 38px; border: 1px solid var(--line-strong); border-radius: 7px; background: #fff; color: var(--ink); }
select { min-width: 112px; padding: 0 34px 0 12px; font-weight: 550; }
.button { padding: 8px 13px; font-weight: 550; }
.button:hover { border-color: #9eaaa2; background: #f8faf8; }
.button.primary { border-color: var(--green); background: var(--green); color: #fff; }
.button.primary:hover { background: var(--green-2); }
.button.destructive { border-color: #8f5555; background: #8f5555; color: #fff; }
.button.destructive:hover { border-color: #7d4545; background: #7d4545; }
#new-year { border: 1.5px solid #6f887b; background: #eef2ef; color: #17211c; font-weight: 550; }
#new-year:hover { border-color: #526f61; background: #e5ece7; color: #111814; }
.button.danger { color: var(--danger); }

.notice { max-width: 1800px; margin: 0 auto 16px; padding: 11px 14px; border: 1px solid #cadbcf; border-radius: 8px; background: #eff8f1; color: #255038; }
.notice.error { border-color: #e1bdbd; background: #fff2f2; color: #8c2525; }
.budget-status { max-width: 1800px; margin: 0 auto 16px; padding: 11px 14px; border: 1px solid #d4ddd7; border-radius: 8px; background: #f5f7f6; color: #405047; }
.budget-status.error { border-color: #e1bdbd; background: #fff7f7; color: #7a3030; }
.budget-status button { margin-left: 10px; }
.budget-card[aria-busy="true"] { opacity: .72; }
.budget-card button:disabled, .year-controls button:disabled, .year-controls select:disabled { cursor: wait; opacity: .62; }

.budget-card { width: 100%; max-width: 1800px; margin: auto; overflow: hidden; border: 1px solid var(--line); border-radius: 12px; background: var(--surface); box-shadow: 0 8px 26px rgba(36, 61, 48, .07); }
.card-heading { display: flex; justify-content: space-between; align-items: center; gap: 16px; padding: 20px 22px 16px; border-bottom: 1px solid var(--line); }
.card-heading h2 { margin: 0; font-size: 18px; font-weight: 650; }
.card-heading p { margin: 6px 0 0; color: var(--muted); font-size: 13px; }
.legend { color: var(--muted); font-size: 12px; white-space: nowrap; }
.budget-scroll-instruction { display: none; }
.incomplete-dot { color: var(--danger); font-size: 10px; }

.horizontal-scroll-cue {
  --scroll-cue-left: inset 0 0 0 transparent;
  --scroll-cue-right: inset 0 0 0 transparent;
  box-shadow: var(--scroll-cue-left), var(--scroll-cue-right);
}
.horizontal-scroll-cue.can-scroll-left { --scroll-cue-left: inset 13px 0 12px -13px rgba(33, 50, 73, .3); }
.horizontal-scroll-cue.can-scroll-right { --scroll-cue-right: inset -13px 0 12px -13px rgba(33, 50, 73, .3); }

.table-scroll { width: 100%; max-height: calc(100vh - 245px); min-height: 420px; overflow: auto; overscroll-behavior-inline: contain; scrollbar-gutter: stable; -webkit-overflow-scrolling: touch; }
.budget-table { width: max-content; min-width: 100%; border-collapse: separate; border-spacing: 0; table-layout: fixed; }
.budget-table th, .budget-table td { height: 40px; border-right: 1px solid var(--line); border-bottom: 1px solid var(--line); padding: 4px 7px; background: var(--surface); font-size: 14px; vertical-align: middle; }
.budget-table th { position: sticky; top: 0; z-index: 8; height: 38px; border-bottom: 2px solid #b5c1bb; background: #e2e8e5; color: #3f4d46; font-size: 10px; font-weight: 600; letter-spacing: .03em; text-align: right; text-transform: uppercase; }
.budget-table th:first-child { text-align: left; }
.budget-table tbody tr:hover > td { background: #fafcfb; }

.sticky-1 { position: sticky; left: 0; z-index: 5; width: var(--row-label-width); min-width: var(--row-label-width); max-width: var(--row-label-width); border-right: 2px solid #aab8c1 !important; box-shadow: none; }
.sticky-2 { position: sticky; left: var(--row-label-width); z-index: 4; width: var(--year-width); min-width: var(--year-width); max-width: var(--year-width); text-align: right; }
.sticky-3 { position: sticky; left: calc(var(--row-label-width) + var(--year-width)); z-index: 4; width: var(--actions-width); min-width: var(--actions-width); max-width: var(--actions-width); box-shadow: 8px 0 10px -10px rgba(35, 50, 58, .68); }
thead .sticky-1, thead .sticky-2, thead .sticky-3 { z-index: 12; background: #dfe6e3; }
.month-cell { width: var(--month-width); min-width: var(--month-width); max-width: var(--month-width); text-align: right; font-variant-numeric: tabular-nums; }
.row-label { font-size: 12.5px; font-weight: 580; line-height: 1.22; }
.row-label .block-toggle { display: inline-grid; place-items: center; width: 22px; height: 22px; margin-right: 5px; border: 0; border-radius: 5px; background: #eaf0ec; color: var(--green); }
.row-label .block-toggle:hover { background: #dfe9e2; }
.detail-name .block-toggle { display: inline-grid; place-items: center; width: 22px; height: 22px; margin-right: 6px; border: 0; border-radius: 5px; background: #eaf0ec; color: var(--green); }
.detail-name .block-toggle:hover { background: #dfe9e2; }
.formula-row td { background: #f7f9f7; font-weight: 600; }
.result-row td { background: #edf4ef; font-weight: 600; }
.final-row td { border-top: 2px solid var(--green); background: #e8f1eb; font-weight: 600; }
.active-row td { background: var(--surface-active) !important; }
.active-row .sticky-1 { box-shadow: inset 4px 0 var(--gold); }
.partial-value { color: #7a837e; }
.partial-marker { position: relative; display: inline-block; width: auto; height: auto; margin-left: 4px; border: 0; padding: 0; background: transparent; color: var(--danger); font-size: 10px; line-height: 1; cursor: help; }

.actions { display: flex; align-items: center; gap: 4px; white-space: nowrap; }
.text-action { min-height: 27px; border: 1px solid #aeb8bf; padding: 3px 7px; border-radius: 5px; background: #f8fafb; color: #293947; font-size: 11px; font-weight: 600; line-height: 1.2; }
.text-action:hover { border-color: #81909b; background: #edf2f5; }
.text-action.toggle { border-color: #9cabb7; background: #f1f5f7; color: #213249; }
.text-action.save { border-color: #316a50; background: #316a50; color: #fff; }
.text-action.save:hover { border-color: #244d3b; background: #244d3b; }
.text-action.cancel { border-color: #d5a9ad; background: #fff3f3; color: #9a3037; }
.text-action.cancel:hover { border-color: #bd7f85; background: #fde8e9; }
.text-action.secondary { color: #4f5b64; }
.menu-wrap { position: relative; }
.menu-button { display: grid; place-items: center; width: 29px; height: 29px; border: 1px solid transparent; border-radius: 6px; background: transparent; color: #4d5952; font-weight: 800; }
.menu-button:hover, .menu-button[aria-expanded="true"] { border-color: var(--line); background: #f1f4f2; }
.action-menu { position: fixed; z-index: 40; min-width: 205px; padding: 5px; border: 1px solid var(--line-strong); border-radius: 8px; background: #fff; box-shadow: 0 12px 28px rgba(24, 38, 30, .18); }
.action-menu button { width: 100%; border: 0; border-radius: 5px; padding: 9px 10px; background: transparent; color: var(--ink); font-size: 12px; text-align: left; }
.action-menu button:hover { background: var(--surface-soft); }
.action-menu button.danger { color: var(--danger); }
.sticky-3.menu-elevated { z-index: 50; }
.detail-actions.menu-elevated { position: relative; z-index: 50; }

.cell-input { width: 100%; min-width: 0; height: 30px; border: 1px solid #9daaa1; border-radius: 5px; padding: 4px 6px; background: #fff; text-align: right; font-variant-numeric: tabular-nums; }
.cell-input:focus, .detail-input:focus { outline: 2px solid rgba(49, 106, 80, .23); border-color: var(--green-2); }
.info-wrap { display: inline-block; }
.info-button { display: inline-grid; place-items: center; width: 20px; height: 20px; margin-left: 3px; border: 0; border-radius: 50%; background: transparent; color: #62736a; font-size: 13px; }
.floating-tooltip { position: fixed; z-index: 1000; width: max-content; max-width: min(280px, calc(100vw - 16px)); padding: 9px 11px; border-radius: 7px; background: #1e2b24; color: #fff; box-shadow: 0 10px 26px rgba(21, 33, 27, .24); font-size: 11px; font-weight: 500; line-height: 1.45; pointer-events: none; }
.floating-tooltip[hidden] { display: none; }

.detail-row > td { height: auto; padding: 0; background: #e9eef1 !important; }
.detail-panel { position: sticky; left: 0; width: calc(100vw - 106px); min-width: 700px; max-width: 1696px; margin: 10px 12px 12px; border: 1px solid #c8d2d8; border-radius: 9px; padding: 14px 16px 16px; background: #f8fafb; box-shadow: 0 5px 15px rgba(42, 57, 66, .08); }
.detail-heading { display: flex; justify-content: space-between; align-items: center; gap: 18px; margin-bottom: 11px; }
.detail-heading h3 { margin: 0; font-size: 14px; font-weight: 650; }
.detail-heading p { margin: 4px 0 0; color: var(--muted); font-size: 12px; }
.detail-scroll { max-width: 100%; overflow-x: auto; overscroll-behavior-inline: contain; border: 1px solid var(--line); border-radius: 8px; background: #fff; -webkit-overflow-scrolling: touch; }
.detail-table { width: max-content; min-width: 100%; border-collapse: separate; border-spacing: 0; table-layout: fixed; }
.detail-table th, .detail-table td { height: 36px; border-right: 1px solid var(--line); border-bottom: 1px solid var(--line); padding: 4px 6px; background: #fff; font-size: 11.5px; }
.detail-table th { position: sticky; top: 0; z-index: 3; background: #edf1ee; color: #5b675f; font-size: 9.5px; font-weight: 650; text-transform: uppercase; }
.detail-table .detail-name { position: sticky; left: 0; z-index: 2; width: 205px; min-width: 205px; background: inherit; text-align: left; }
.detail-table th.detail-name { z-index: 4; background: #e8ede9; }
.detail-table .detail-year { width: 112px; min-width: 112px; text-align: right; }
.detail-table .detail-actions { box-sizing: border-box; width: 158px; min-width: 158px; max-width: 158px; padding-left: 8px; padding-right: 8px; text-align: left; }
.detail-table th.detail-actions { text-align: left; }
.detail-table .detail-actions .actions { justify-content: flex-start; }
.detail-table .detail-month { width: 94px; min-width: 94px; padding-left: 6px; padding-right: 6px; text-align: right; font-variant-numeric: tabular-nums; }
.detail-table .person-name { position: sticky; left: 0; z-index: 2; width: 158px; min-width: 158px; background: inherit; text-align: left; }
.detail-table th.person-name { z-index: 4; background: #e8ede9; }
.detail-table .person-role { width: 165px; min-width: 165px; text-align: left; }
.detail-table .person-base { width: 116px; min-width: 116px; text-align: right; }
.detail-table .person-period { width: 86px; min-width: 86px; text-align: center; }
.detail-table strong { font-weight: 600; }
.detail-input { width: 100%; height: 28px; border: 1px solid #9daaa1; border-radius: 5px; padding: 3px 5px; background: #fff; }
.detail-input.number { text-align: right; }
.detail-subtitle td { height: 35px; background: #f0f4f1; color: #3f4c45; font-weight: 600; }
.computed td { background: #f8faf8; color: #4d5852; }
.coefficient { display: flex; align-items: center; flex-wrap: wrap; gap: 7px; padding: 8px 10px; border: 1px solid var(--line); border-radius: 7px; background: #fff; }
.coefficient label { font-size: 12px; font-weight: 700; }
.coefficient input { width: 85px; }
.add-button { margin-top: 12px; }
.empty-state { padding: 17px; color: var(--muted); font-size: 12px; text-align: center; }

.modal { width: min(470px, calc(100vw - 32px)); border: 0; border-radius: 11px; padding: 0; box-shadow: 0 22px 55px rgba(18, 28, 23, .28); }
.modal::backdrop { background: rgba(20, 31, 25, .48); }
.modal form { padding: 23px; }
.modal h2 { margin: 0 0 10px; font-size: 19px; }
.modal p { margin: 0; color: var(--muted); line-height: 1.5; }
.modal-actions { display: flex; justify-content: flex-end; gap: 8px; margin-top: 22px; }

.dashboard-page-heading { align-items: end; }
.dashboard-period { display: flex; align-items: end; gap: 18px; }
.dashboard-period label, .dashboard-chart-control label { display: block; margin-bottom: 7px; color: var(--muted); font-size: 12px; font-weight: 600; }
.dashboard-period-copy { display: grid; gap: 4px; padding-bottom: 2px; }
.dashboard-period-copy strong { font-size: 14px; font-weight: 600; }
.dashboard-period-copy span { color: var(--muted); font-size: 12px; }
.dashboard-period-copy i { color: var(--gold); font-size: 9px; font-style: normal; }
.dashboard-kpis { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 14px; max-width: 1800px; margin: 0 auto 14px; }
.dashboard-kpi, .dashboard-card { border: 1px solid var(--line); border-radius: 12px; background: var(--surface); box-shadow: 0 8px 24px rgba(36, 61, 48, .06); }
.dashboard-kpi { min-height: 145px; padding: 18px 19px 16px; }
.dashboard-kpi h2 { min-height: 34px; margin: 0; color: #4f5d56; font-size: 13px; font-weight: 600; line-height: 1.3; }
.dashboard-kpi-value { margin: 12px 0 10px; color: var(--ink); font-size: clamp(22px, 2vw, 28px); font-weight: 600; font-variant-numeric: tabular-nums; letter-spacing: -.02em; }
.dashboard-kpi-variance { display: flex; align-items: baseline; gap: 7px; color: var(--muted); font-size: 12px; font-variant-numeric: tabular-nums; }
.dashboard-kpi-variance strong { font-weight: 600; }
.dashboard-direction { font-size: 16px; font-weight: 600; line-height: 1; }
.dashboard-direction.favorable { color: var(--green-2); }
.dashboard-direction.unfavorable { color: var(--danger); }
.dashboard-summary-grid { display: grid; grid-template-columns: minmax(0, .82fr) minmax(0, 1.18fr); gap: 14px; max-width: 1800px; margin: 0 auto 14px; }
.dashboard-card { overflow: hidden; }
.forecast-content { width: min(100%, 1680px); margin: 0 auto; }
.forecast-chart-card { max-width: none; margin: 0 0 14px; }
.forecast-card { max-width: none; }
.forecast-boundary { stroke: #997934; stroke-width: 1.5; stroke-dasharray: 4 4; }
.forecast-boundary-label { fill: #69766e; font-size: 10px; font-weight: 600; }
.forecast-boundary-legend { color: #69766e; font-size: 11px; }
.forecast-table-wrap { width: 100%; max-height: calc(100vh - 245px); min-height: 360px; overflow: auto; overscroll-behavior-inline: contain; -webkit-overflow-scrolling: touch; }
.forecast-table { width: max-content; min-width: 1120px; margin-inline: auto; border-left: 1px solid var(--line); }
.forecast-table thead { position: static; }
.forecast-table th { position: sticky; top: 0; z-index: 8; }
.forecast-table tbody .sticky-1 { position: sticky; left: 0; z-index: 9; background: var(--surface); border-right: 2px solid #aab8c1 !important; }
.forecast-table tbody .formula-row > .sticky-1 { background: #f7f9f7; }
.forecast-table tbody .result-row > .sticky-1 { background: #edf4ef; }
.forecast-table tbody .final-row > .sticky-1 { background: #e8f1eb; }
.forecast-table thead .sticky-1 { position: sticky; top: 0; left: 0; z-index: 12; background: #dfe6e3; border-right: 2px solid #aab8c1 !important; }
.forecast-table tbody .sticky-2 { position: sticky; left: var(--row-label-width); z-index: 8; width: var(--year-width); min-width: var(--year-width); max-width: var(--year-width); background: var(--surface); }
.forecast-table tbody .formula-row > .sticky-2 { background: #f7f9f7; }
.forecast-table tbody .result-row > .sticky-2 { background: #edf4ef; }
.forecast-table tbody .final-row > .sticky-2 { background: #e8f1eb; }
.forecast-table thead .sticky-2 { position: sticky; top: 0; left: var(--row-label-width); z-index: 11; width: var(--year-width); min-width: var(--year-width); max-width: var(--year-width); background: #dfe6e3; }
.forecast-table th:nth-child(n+3), .forecast-table td:nth-child(n+2) { text-align: right; font-variant-numeric: tabular-nums; }
.forecast-table th:last-child, .forecast-table td:last-child { text-align: left; width: 168px; }
.forecast-editor-row > td { height: auto; padding: 0; background: #e9eef1 !important; }
.forecast-editor { min-width: 640px; margin: 10px 12px 12px; border: 1px solid #c8d2d8; border-radius: 9px; padding: 14px 16px 16px; background: #f8fafb; }
.forecast-edit-table th:first-child, .forecast-edit-table td:first-child { width: 150px; text-align: left; }
.forecast-edit-table th:last-child, .forecast-edit-table td:last-child { width: 180px; text-align: left; }
.forecast-budget-source { color: var(--muted); font-size: 12px; }
.forecast-variance { white-space: nowrap; }
.cashflow-page-heading { align-items: end; }
.cashflow-actions { display: flex; align-items: end; justify-content: flex-end; gap: 8px; }
.cashflow-mode-switch { display: inline-flex; gap: 3px; padding: 2px; border: 1px solid var(--line); border-radius: 8px; background: #f4f7f5; }
.cashflow-mode-switch .button { min-height: 30px; padding: 4px 10px; border-color: transparent; background: transparent; font-size: 12px; }
.cashflow-mode-switch .button.active { border-color: #9cabb7; background: #fff; color: #213249; }
.cashflow-create-plan { min-height: 30px; padding: 4px 10px; font-size: 12px; white-space: nowrap; }
.cashflow-metrics { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 14px; max-width: 1680px; margin: 0 auto 14px; }
.cashflow-metric { min-height: 96px; padding: 13px 15px; border: 1px solid var(--line); border-radius: 11px; background: var(--surface); box-shadow: 0 8px 24px rgba(36, 61, 48, .06); }
.cashflow-metric h2 { min-height: 0; margin: 0; color: #4f5d56; font-size: 13px; font-weight: 600; line-height: 1.3; }
.cashflow-metric strong { display: block; margin-top: 6px; font-size: clamp(20px, 1.8vw, 25px); font-weight: 600; font-variant-numeric: tabular-nums; letter-spacing: -.02em; }
.cashflow-metric span { display: block; margin-top: 3px; color: var(--muted); font-size: 11.5px; }
.cashflow-balance-panel { display: grid; grid-template-columns: minmax(260px, .8fr) minmax(500px, 1.2fr); gap: 20px; max-width: 1680px; margin: 0 auto 14px; padding: 16px 18px; border: 1px solid #c8d2d8; border-radius: 11px; background: #f7faf8; box-shadow: 0 8px 24px rgba(36, 61, 48, .05); }
.cashflow-balance-panel h2 { margin: 0; font-size: 17px; font-weight: 600; }
.cashflow-balance-panel p { margin: 6px 0 0; color: var(--muted); font-size: 13px; line-height: 1.45; }
.cashflow-balance-form { display: grid; grid-template-columns: repeat(3, minmax(160px, 1fr)); align-items: end; gap: 10px; }
.cashflow-balance-form label, .cashflow-balance-total { display: grid; gap: 6px; min-width: 0; color: var(--muted); font-size: 12px; font-weight: 600; }
.cashflow-balance-form input { min-width: 0; min-height: 38px; border: 1px solid var(--line-strong); border-radius: 7px; padding: 0 10px; color: var(--ink); font: inherit; font-variant-numeric: tabular-nums; }
.cashflow-balance-total { grid-template-rows: auto 38px; }
.cashflow-balance-total strong { display: flex; align-items: center; min-height: 38px; border: 1px solid #b9cfc0; border-radius: 7px; padding: 0 10px; background: #e8f3eb; color: var(--ink); font-size: 15px; font-weight: 600; font-variant-numeric: tabular-nums; }
.cashflow-balance-form-actions { grid-column: 1 / -1; display: flex; justify-content: flex-end; gap: 8px; }
.cashflow-balance-form-actions .button { min-height: 38px; flex: 0 1 132px; }
.cashflow-card { max-width: 1680px; }
.cashflow-table-wrap { width: 100%; max-height: calc(100vh - 245px); min-height: 360px; overflow: auto; overscroll-behavior-inline: contain; scrollbar-gutter: stable; -webkit-overflow-scrolling: touch; }
.cashflow-table { --row-label-width: 240px; width: max-content; min-width: 1120px; margin-inline: auto; border-left: 1px solid var(--line); }
.cashflow-table th { position: sticky; top: 0; z-index: 8; font-size: 10.5px; letter-spacing: .04em; }
.cashflow-table thead .sticky-1 { position: sticky; top: 0; left: 0; z-index: 12; background: #dfe6e3; border-right: 2px solid #aab8c1 !important; }
.cashflow-table tbody .sticky-1 { position: sticky; left: 0; z-index: 9; background: var(--surface); border-right: 2px solid #aab8c1 !important; }
.cashflow-table th:not(.sticky-1), .cashflow-table td:not(.sticky-1) { width: 112px; min-width: 112px; max-width: 112px; text-align: right; font-variant-numeric: tabular-nums; }
.cashflow-value-input { width: 100%; min-width: 0; border: 0; background: transparent; color: inherit; font: inherit; font-variant-numeric: tabular-nums; text-align: right; }
.cashflow-value-input:focus { outline: 2px solid #71907d; outline-offset: 2px; background: #fff; }
.cashflow-period-week { display: grid; gap: 3px; line-height: 1.1; text-align: center; text-transform: none; }
.cashflow-period-week span:first-child { color: #3f4d46; font-size: 11px; font-weight: 600; letter-spacing: 0; }
.cashflow-period-week span:last-child { color: #69766e; font-size: 10px; font-weight: 600; letter-spacing: .01em; }
.cashflow-table .cashflow-outflow { color: #46534d; }
.cashflow-table .cashflow-net-row > td { background: #f7f9f7; font-weight: 600; }
.cashflow-table .cashflow-ending-row > td { border-top: 2px solid var(--green); background: #e8f1eb; font-weight: 600; }
.cashflow-table .cashflow-net-row > .sticky-1 { background: #f7f9f7; }
.cashflow-table .cashflow-ending-row > .sticky-1 { background: #e8f1eb; }
.cashflow-table .cashflow-tax-parent > td { border-top: 3px solid #91ad9d; border-bottom: 1px solid #b7cbbd; background: #e0eee5; color: #253e30; font-weight: 600; }
.cashflow-table .cashflow-tax-parent > .sticky-1 { background: #e0eee5; box-shadow: inset 5px 0 #71907d; }
.cashflow-tax-toggle { display: inline-grid; place-items: center; width: 22px; height: 22px; margin-right: 6px; border: 1px solid #89a695; border-radius: 5px; background: #d2e5d9; color: #294c37; font-size: 14px; font-weight: 600; line-height: 1; }
.cashflow-tax-detail > td { height: 37px; border-bottom-color: #d5e1d9; background: #f3f8f4; color: #52635a; }
.cashflow-table .cashflow-tax-detail > .sticky-1 { padding-left: 48px; background: #f3f8f4; box-shadow: inset 5px 0 #bed1c4; font-weight: 500; }
.cashflow-tax-detail-last > td { border-bottom: 3px solid #9eb9a8; }
.dashboard-card-heading { display: flex; align-items: center; justify-content: space-between; gap: 18px; padding: 17px 19px 14px; border-bottom: 1px solid var(--line); }
.dashboard-card-heading .eyebrow { margin-bottom: 5px; }
.dashboard-card-heading h2 { margin: 0; font-size: 17px; font-weight: 600; }
.dashboard-card-heading > span { color: var(--muted); font-size: 11px; white-space: nowrap; }
.dashboard-margin-list { padding: 2px 19px 6px; }
.dashboard-margin-row { display: flex; align-items: center; justify-content: space-between; gap: 20px; min-height: 47px; border-bottom: 1px solid var(--line); }
.dashboard-margin-row:last-child { border-bottom: 0; }
.dashboard-margin-row span { color: #46534d; font-size: 13px; }
.dashboard-margin-row strong { font-size: 16px; font-weight: 600; font-variant-numeric: tabular-nums; }
.dashboard-variance-list { padding: 2px 19px 6px; }
.dashboard-variance-row { display: grid; grid-template-columns: minmax(150px, 1fr) auto auto; align-items: center; gap: 13px; min-height: 47px; border-bottom: 1px solid var(--line); }
.dashboard-variance-row:last-child { border-bottom: 0; }
.dashboard-variance-name { color: #46534d; font-size: 13px; }
.dashboard-variance-amount { display: inline-flex; align-items: baseline; justify-content: flex-end; gap: 6px; font-size: 14px; font-weight: 600; font-variant-numeric: tabular-nums; white-space: nowrap; }
.dashboard-variance-percent { min-width: 68px; color: var(--muted); font-size: 12px; font-variant-numeric: tabular-nums; text-align: right; }
.dashboard-chart-card { max-width: 1800px; margin: 0 auto; }
.dashboard-chart-heading { align-items: end; }
.dashboard-chart-control select { min-width: 210px; }
.dashboard-chart-legend { display: flex; justify-content: flex-end; gap: 17px; padding: 11px 20px 0; color: var(--muted); font-size: 12px; }
.dashboard-chart-legend span { display: inline-flex; align-items: center; gap: 7px; }
.dashboard-chart-legend i { display: inline-block; width: 25px; border-top: 2px solid var(--green-2); }
.dashboard-chart-legend .budget-line { border-top-color: #426b8f; border-top-style: dashed; }
.dashboard-chart { min-height: 280px; padding: 4px 14px 14px; overflow-x: auto; overscroll-behavior-inline: contain; -webkit-overflow-scrolling: touch; }
.dashboard-chart svg { display: block; width: 100%; min-width: 760px; height: 270px; }
.dashboard-chart .chart-grid { stroke: #dce2de; stroke-width: 1; }
.dashboard-chart .chart-axis-label { fill: #6a756f; font-size: 10px; font-family: inherit; }
.dashboard-chart .chart-month { fill: #55615b; font-size: 10px; font-family: inherit; text-anchor: middle; }
.dashboard-chart .chart-actual { fill: none; stroke: var(--green-2); stroke-width: 2.5; stroke-linecap: round; stroke-linejoin: round; }
.dashboard-chart .chart-budget { fill: none; stroke: #426b8f; stroke-width: 2; stroke-dasharray: 7 5; stroke-linecap: round; stroke-linejoin: round; }
.dashboard-chart .chart-actual-point { fill: var(--green-2); }
.dashboard-chart .chart-budget-point { fill: #426b8f; }

/* Fakto puslapis perima patvirtintą bendrą UI bazę, bet turi savą Actual informacinę architektūrą. */
.actual-page-heading { align-items: end; }
.actual-year-control label { display: block; margin-bottom: 7px; color: var(--muted); font-size: 12px; font-weight: 700; }
.actual-toolbar { display: flex; justify-content: space-between; align-items: center; gap: 18px; max-width: 1800px; margin: 0 auto 14px; padding: 12px 14px; border: 1px solid var(--line); border-radius: 10px; background: rgba(255, 255, 255, .72); }
.month-statuses { display: flex; align-items: center; flex-wrap: wrap; gap: 6px; }
.month-status { min-width: 49px; border: 1px solid var(--line); border-radius: 6px; padding: 6px 8px; background: #fff; color: #52605a; font-size: 11px; text-align: center; }
.month-status.closed strong { color: var(--green-2); }
.month-status.pending { color: #929b96; }
.actual-actions { display: flex; flex-wrap: wrap; justify-content: flex-end; gap: 7px; }
.button.compare { border-color: #81909b; color: #213249; }
.actual-table-scroll { max-height: none; min-height: 0; }
.actual-table { --actual-label-width: 300px; --actual-ytd-width: 124px; }
.actual-table .actual-label { position: sticky; left: 0; z-index: 5; width: var(--actual-label-width); min-width: var(--actual-label-width); max-width: var(--actual-label-width); border-right: 2px solid #aab8c1 !important; text-align: left; }
.actual-table .actual-ytd { position: sticky; left: var(--actual-label-width); z-index: 4; width: var(--actual-ytd-width); min-width: var(--actual-ytd-width); max-width: var(--actual-ytd-width); border-right: 2px solid #c4ced3 !important; background: #f5f8f6; text-align: right; font-variant-numeric: tabular-nums; }
.actual-table thead .actual-label, .actual-table thead .actual-ytd { z-index: 12; background: #dfe6e3; }
.actual-table .month-cell { width: 108px; min-width: 108px; max-width: 108px; }
.actual-toggle { display: flex; align-items: center; width: 100%; min-height: 30px; border: 0; padding: 2px 0; background: transparent; color: inherit; font-weight: inherit; text-align: left; }
.actual-toggle .chevron { display: inline-grid; place-items: center; flex: 0 0 23px; height: 23px; margin-right: 6px; border-radius: 5px; background: #eaf0ec; color: var(--green); }
.actual-toggle:hover .chevron { background: #dfe9e2; }
.account-row td { height: 36px; background: #f8faf9; color: #56625c; font-size: 12px; }
.account-row .actual-label { padding-left: 38px; font-weight: 500; }
.account-code { display: inline-block; min-width: 58px; color: #33433b; font-weight: 650; font-variant-numeric: tabular-nums; }
.rental-level-row td { background: #f3f6f4; font-weight: 600; }
.rental-level-row .actual-label { padding-left: 22px; }
.rental-account-row .actual-label { padding-left: 60px; }
.actual-table .formula-row td { background: #f7f9f7; }
.actual-table .result-row td { border-top: 1px solid #aebbb4; background: #edf4ef; }
.actual-table .final-row td { border-top: 2px solid var(--green); background: #e8f1eb; }
.unassigned-card { max-width: 1800px; margin: 18px auto 0; overflow: hidden; border: 1px solid #cdd2d0; border-left: 4px solid #b4772d; border-radius: 10px; background: #e8ebea; box-shadow: 0 6px 18px rgba(42, 49, 46, .05); }
.unassigned-heading { display: flex; justify-content: space-between; align-items: center; gap: 20px; padding: 16px 18px 13px; border-bottom: 1px solid #cbd0ce; }
.unassigned-heading h2 { margin: 0; font-size: 17px; font-weight: 600; }
.unassigned-warning-icon { margin-right: 5px; color: var(--danger); }
.unassigned-heading > p { margin: 0; color: #68716d; font-size: 12px; }
.unassigned-scroll { max-width: 100%; overflow: auto; overscroll-behavior-inline: contain; -webkit-overflow-scrolling: touch; }
.control-table th, .control-table td { background: #f3f4f4; }
.control-table .actual-ytd { background: #ecefee; }

.comparison-page-heading { align-items: end; }
.comparison-controls { display: flex; align-items: end; justify-content: flex-end; gap: 9px; }
.comparison-controls label { display: block; margin-bottom: 7px; color: var(--muted); font-size: 12px; font-weight: 700; }
.comparison-controls select { min-width: 132px; }
.comparison-controls .comparison-back { white-space: nowrap; }
.comparison-note { max-width: 1800px; min-height: 19px; margin: -3px auto 12px; color: var(--muted); font-size: 12px; }
.comparison-card { max-width: 1180px; }
.comparison-table-wrap { max-width: 100%; overflow-x: auto; overscroll-behavior-inline: contain; -webkit-overflow-scrolling: touch; }
.comparison-table { width: 100%; min-width: 780px; }
.comparison-table th, .comparison-table td { text-align: right; font-variant-numeric: tabular-nums; }
.comparison-table th:first-child, .comparison-table td:first-child { width: 36%; min-width: 275px; border-right: 2px solid #aab8c1 !important; text-align: left; }
.comparison-table th:not(:first-child), .comparison-table td:not(:first-child) { width: 16%; }
.comparison-table tbody td:nth-child(3) { color: #426b8f; }
.comparison-table .formula-row td { background: #f7f9f7; }
.comparison-table .result-row td { border-top: 1px solid #aebbb4; background: #edf4ef; font-weight: 600; }
.comparison-table .final-row td { border-top: 2px solid var(--green); background: #e8f1eb; font-weight: 600; }
.comparison-table .variance-value { display: inline-flex; align-items: baseline; justify-content: flex-end; gap: 7px; }
.variance-arrow { font-size: 18px; font-weight: 800; line-height: 1; }
.variance-arrow.favorable { color: var(--green-2); }
.variance-arrow.unfavorable { color: var(--danger); }

.admin-page-heading { align-items: flex-start; }
.admin-page-heading .intro { font-size: 13px; line-height: 1.5; }
.admin-tabs { display: flex; max-width: 1800px; margin: 0 auto 14px; overflow: hidden; border: 1px solid var(--line); border-radius: 10px; background: rgba(255, 255, 255, .76); }
.admin-tabs button { flex: 0 0 auto; min-height: 45px; border: 0; border-bottom: 3px solid transparent; padding: 0 17px; background: transparent; color: #425049; font-weight: 550; white-space: nowrap; }
.admin-tabs button:hover:not(:disabled) { background: #f4f7f5; }
.admin-tabs button.active { border-bottom-color: var(--brand-gold); background: #edf2ef; color: var(--ink); font-weight: 600; }
.admin-tabs button:disabled { color: #929b96; cursor: not-allowed; }
.admin-notice { margin-bottom: 14px; }
.admin-section { max-width: 1800px; margin: 0 auto; }
.admin-section[hidden], .admin-card[hidden] { display: none; }
.admin-import-grid { display: grid; grid-template-columns: minmax(0, .9fr) minmax(0, 1.1fr); align-items: start; gap: 14px; }
.admin-card { overflow: hidden; border: 1px solid var(--line); border-radius: 12px; background: var(--surface); box-shadow: 0 8px 24px rgba(36, 61, 48, .06); }
.admin-card + .admin-card, .admin-import-history { margin-top: 14px; }
.admin-card-heading { display: flex; align-items: flex-start; justify-content: space-between; gap: 18px; padding: 18px 20px 15px; border-bottom: 1px solid var(--line); }
.admin-card-heading h2 { margin: 0; font-size: 18px; font-weight: 600; }
.admin-card-heading p { margin: 6px 0 0; color: var(--muted); font-size: 12px; line-height: 1.5; }
.prototype-badge { flex: 0 0 auto; border: 1px solid #c5b780; border-radius: 999px; padding: 4px 8px; background: #fffaf0; color: #765f24; font-size: 10px; font-weight: 600; letter-spacing: .04em; text-transform: uppercase; }
.prototype-note { margin: 16px 20px 0; border: 1px solid #d7ccaa; border-radius: 8px; padding: 10px 12px; background: #fffbf2; color: #675a35; font-size: 12px; line-height: 1.45; }
.import-scenario { display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: end; gap: 9px; margin: 14px 20px 0; }
.import-scenario label { display: block; margin-bottom: 6px; color: var(--muted); font-size: 11px; font-weight: 600; }
.import-scenario select { width: 100%; }
.import-dropzone { margin: 14px 20px 20px; border: 1px dashed #aebbb4; border-radius: 10px; padding: 24px 18px; background: #f8faf8; text-align: center; }
.import-dropzone-icon { display: grid; place-items: center; width: 38px; height: 38px; margin: 0 auto 10px; border-radius: 50%; background: #e8efea; color: var(--green); font-size: 20px; }
.import-dropzone strong { display: block; font-size: 14px; font-weight: 600; }
.import-dropzone p { margin: 6px auto 14px; max-width: 520px; color: var(--muted); font-size: 12px; line-height: 1.5; }
.import-file-actions { display: flex; justify-content: center; flex-wrap: wrap; gap: 8px; }
.selected-file { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-top: 15px; border-top: 1px solid var(--line); padding-top: 12px; color: #46534d; font-size: 12px; text-align: left; }
.selected-file strong { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.selected-file span { flex: 0 0 auto; color: var(--muted); }
.import-check-body { padding: 17px 20px 20px; }
.import-result-banner { display: flex; align-items: flex-start; gap: 10px; margin-bottom: 15px; border: 1px solid #cbd9cf; border-radius: 8px; padding: 11px 12px; background: #f2f8f4; color: #28523a; font-size: 12px; line-height: 1.45; }
.import-result-banner.warning { border-color: #dfca8f; background: #fff9eb; color: #725919; }
.import-result-banner.error { border-color: #e0b7b7; background: #fff2f2; color: #8c2525; }
.import-result-icon { flex: 0 0 auto; font-size: 15px; font-weight: 600; }
.import-summary-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0 20px; margin: 0; }
.import-summary-grid div { display: grid; grid-template-columns: minmax(120px, 1fr) auto; gap: 12px; border-bottom: 1px solid var(--line); padding: 9px 0; }
.import-summary-grid dt { color: var(--muted); font-size: 11px; }
.import-summary-grid dd { margin: 0; font-size: 12px; font-weight: 600; text-align: right; }
.import-finance-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 9px; margin-top: 15px; }
.import-finance-item { border: 1px solid var(--line); border-radius: 8px; padding: 11px; background: var(--surface-soft); }
.import-finance-item span { display: block; margin-bottom: 6px; color: var(--muted); font-size: 10px; text-transform: uppercase; }
.import-finance-item strong { font-size: 14px; font-weight: 600; font-variant-numeric: tabular-nums; }
.admin-actions { display: flex; justify-content: flex-end; flex-wrap: wrap; gap: 8px; margin-top: 17px; }
.admin-success { margin-top: 14px; border-color: #bcd3c4; }
.admin-success-body { display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: center; gap: 20px; padding: 18px 20px; }
.admin-success-copy h2 { margin: 0 0 6px; font-size: 17px; font-weight: 600; }
.admin-success-copy p { margin: 0; color: var(--muted); font-size: 12px; line-height: 1.5; }
.admin-success-facts { display: flex; flex-wrap: wrap; gap: 8px 18px; margin-top: 11px; color: #3f4c45; font-size: 12px; }
.admin-success-facts strong { font-weight: 600; }
.admin-success-actions { display: flex; flex-wrap: wrap; justify-content: flex-end; gap: 8px; }
.admin-table-wrap { max-width: 100%; overflow-x: auto; overscroll-behavior-inline: contain; -webkit-overflow-scrolling: touch; }
.admin-table { width: 100%; min-width: 760px; }
.admin-table th, .admin-table td { text-align: left; }
.admin-table td { font-size: 12px; }
.admin-table td.numeric, .admin-table th.numeric { text-align: right; font-variant-numeric: tabular-nums; }
.admin-history-body { padding: 16px 20px 20px; }
.admin-history-message { margin: 0; color: var(--muted); font-size: 12px; }
.import-history-current h3, .import-history-previous h3 { margin: 0 0 10px; font-size: 14px; font-weight: 600; }
.import-month-statuses { display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); border: 1px solid var(--line); border-radius: 8px; overflow: hidden; }
.import-month-status { display: flex; justify-content: space-between; gap: 8px; min-height: 36px; border-right: 1px solid var(--line); border-bottom: 1px solid var(--line); padding: 9px 10px; color: #4a5750; font-size: 11px; }
.import-month-status:nth-child(6n) { border-right: 0; }
.import-month-status:nth-last-child(-n + 6) { border-bottom: 0; }
.import-month-status strong { color: var(--green); font-size: 10.5px; font-weight: 600; }
.import-history-previous { margin-top: 16px; }
.import-history-previous ul { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 8px; margin: 0; padding: 0; list-style: none; }
.import-history-previous li { display: flex; justify-content: space-between; gap: 8px; border: 1px solid var(--line); border-radius: 7px; padding: 9px 10px; color: #4a5750; font-size: 11px; }
.import-history-previous strong { font-weight: 600; }
.import-history-previous span { color: var(--muted); white-space: nowrap; }

.mapping-heading { display: flex; align-items: flex-end; justify-content: space-between; gap: 22px; margin-bottom: 14px; }
.mapping-heading h2 { margin: 0; font-size: 20px; font-weight: 600; }
.mapping-heading p { max-width: 850px; margin: 7px 0 0; color: var(--muted); font-size: 12px; line-height: 1.5; }
.mapping-filters { display: flex; flex: 0 0 auto; gap: 7px; }
.mapping-filter { min-height: 36px; border: 1px solid var(--line-strong); border-radius: 7px; padding: 7px 11px; background: #fff; color: #45524c; font-weight: 550; }
.mapping-filter.active { border-color: #91a79a; background: #eaf1ec; color: var(--green); font-weight: 600; }
.mapping-table { min-width: 900px; }
.mapping-table th:nth-child(1) { width: 13%; }
.mapping-table th:nth-child(2) { width: 32%; }
.mapping-table th:nth-child(3) { width: 39%; }
.mapping-table th:nth-child(4) { width: 16%; }
.mapping-code { font-weight: 600; font-variant-numeric: tabular-nums; white-space: nowrap; }
.mapping-category { color: #37463f; }
.mapping-category.unassigned { color: var(--danger); font-weight: 600; }
.mapping-category.excluded { color: #69756f; font-style: italic; }
.mapping-select { width: 100%; min-width: 270px; }
.mapping-actions { display: flex; align-items: center; gap: 6px; white-space: nowrap; }
.mapping-actions .button { padding: 6px 9px; font-size: 11px; }
.mapping-empty { padding: 25px !important; color: var(--muted); text-align: center !important; }

.users-heading { display: flex; align-items: flex-end; justify-content: space-between; gap: 22px; margin-bottom: 14px; }
.users-heading h2 { margin: 0; font-size: 20px; font-weight: 600; }
.users-heading p { max-width: 850px; margin: 7px 0 0; color: var(--muted); font-size: 12px; line-height: 1.5; }
.users-heading > .button { flex: 0 0 auto; }
.users-card .admin-table-wrap { padding-bottom: 10px; }
.users-table { min-width: 780px; table-layout: fixed; }
.users-table th:nth-child(1) { width: 20%; }
.users-table th:nth-child(2) { width: 16%; }
.users-table th:nth-child(3) { width: 14%; }
.users-table th:nth-child(4) { width: 11%; }
.users-table th:nth-child(5) { width: 18%; }
.users-table th:nth-child(6) { width: 21%; }
.user-name { display: inline; font-weight: 600; }
.current-user-label { display: inline-block; margin-left: 7px; border-radius: 999px; padding: 2px 6px; background: #eef2f0; color: #59665f; font-size: 9px; font-weight: 600; text-transform: uppercase; }
.user-username, .user-last-login { font-variant-numeric: tabular-nums; }
.user-username { color: #3f4d46; }
.user-last-login { white-space: nowrap; }
.role-badge, .user-status { display: inline-flex; align-items: center; min-height: 24px; border: 1px solid var(--line); border-radius: 999px; padding: 3px 8px; font-size: 10.5px; font-weight: 600; white-space: nowrap; }
.role-badge { background: #f3f6f4; color: #3e4c45; }
.role-administrator { border-color: #b8c3cc; background: #eef3f7; color: #31495f; }
.role-accounting { border-color: #c7d3cb; background: #f0f6f2; color: #315540; }
.user-status.active { border-color: #bfd1c5; background: #edf6f0; color: #2f5d3e; }
.user-status.disabled { border-color: #d0d5d2; background: #f3f4f3; color: #707a75; }
.user-actions { display: flex; align-items: center; gap: 6px; white-space: nowrap; }
.user-actions .button { padding: 6px 9px; font-size: 11px; }
.user-toggle { border-color: #c3cbc6; background: #f7f8f7; color: #4d5953; }
.user-delete { border-color: #d5c1c1; background: #fffafa; color: #784646; }
.user-delete:hover { border-color: #bd9e9e; background: #fff4f4; }

.user-modal { width: min(620px, calc(100vw - 32px)); max-height: calc(100svh - 32px); overflow-y: auto; }
.user-modal form { padding: 22px 23px 23px; }
.user-modal-heading { display: flex; align-items: flex-start; justify-content: space-between; gap: 18px; margin-bottom: 18px; }
.user-modal-heading .eyebrow { margin-bottom: 5px; }
.user-modal-heading h2 { margin: 0; }
.modal-close { display: grid; place-items: center; flex: 0 0 auto; width: 36px; height: 36px; border: 1px solid var(--line); border-radius: 7px; background: #fff; color: #56625c; font-size: 22px; line-height: 1; }
.modal-close:hover { background: #f5f7f5; }
.user-form-grid, .user-password-fields { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; }
.user-field { display: grid; gap: 6px; min-width: 0; color: #435049; font-size: 11px; font-weight: 600; }
.user-field input, .user-field select { box-sizing: border-box; width: 100%; min-width: 0; min-height: 40px; border: 1px solid var(--line-strong); border-radius: 7px; padding: 8px 10px; background: #fff; color: var(--ink); font: inherit; font-size: 13px; font-weight: 500; }
.user-field select { padding-right: 34px; }
.user-field input:focus, .user-field select:focus { border-color: #718b7c; outline: 2px solid rgba(74, 105, 86, .14); outline-offset: 1px; }
.user-active-field { display: flex; align-items: center; gap: 9px; min-height: 40px; align-self: end; color: #435049; font-size: 12px; font-weight: 600; }
.user-active-field input { width: 18px; height: 18px; accent-color: var(--green); }
.user-password-action { display: flex; align-items: center; gap: 12px; margin-top: 17px; border-top: 1px solid var(--line); padding-top: 16px; }
.user-password-action p { font-size: 11px; }
.user-password-fields { margin-top: 17px; border-top: 1px solid var(--line); padding-top: 16px; }
.user-password-action[hidden], .user-password-fields[hidden], .user-form-error[hidden] { display: none; }
.user-form-error { margin-top: 15px; border: 1px solid #d9b9b9; border-radius: 7px; padding: 9px 11px; background: #fff5f5; color: #842e2e; font-size: 12px; line-height: 1.4; }

.analysis-sticky-header { position: fixed; top: 0; z-index: 80; overflow: hidden; border-bottom: 1px solid #aeb9b3; background: #dfe6e3; box-shadow: 0 5px 13px rgba(35, 50, 58, .13); pointer-events: none; }
.analysis-sticky-header[hidden] { display: none; }
.analysis-sticky-header-inner { overflow: hidden; }
.analysis-sticky-header table { margin: 0; }
.analysis-sticky-header th { position: static; }
.analysis-sticky-header .actual-label, .analysis-sticky-header .actual-ytd { position: relative; left: 0; z-index: 2; }

@media (max-width: 1100px) {
  :root { --row-label-width: 200px; --year-width: 112px; --actions-width: 144px; --month-width: 96px; }
  .app-header { padding: 0 22px; }
  .main-nav button { padding: 0 12px; }
  main { padding: 18px 20px 40px; }
  .detail-panel { width: calc(100vw - 66px); }
  .budget-scroll-instruction { display: block; }
  .actual-toolbar { align-items: flex-start; flex-direction: column; }
  .actual-actions { justify-content: flex-start; }
  .comparison-page-heading { align-items: flex-start; flex-direction: column; }
  .comparison-controls { justify-content: flex-start; flex-wrap: wrap; }
  .dashboard-kpis { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .dashboard-summary-grid { grid-template-columns: 1fr; }
  .admin-import-grid { grid-template-columns: 1fr; }
  .mapping-heading, .users-heading { align-items: flex-start; flex-direction: column; }
}

@media (max-width: 820px) {
  .card-heading { align-items: flex-start; flex-direction: column; }
  .dashboard-card-heading { align-items: flex-start; flex-direction: column; }
  .month-status { min-width: 45px; padding-right: 6px; padding-left: 6px; }
  .unassigned-heading { align-items: flex-start; flex-direction: column; gap: 8px; }
}

@media (max-width: 700px) {
  .app-header { align-items: stretch; flex-direction: column; gap: 0; padding: 14px 20px 0; }
  .home-nav-action { position: absolute; top: 14px; left: 112px; min-height: 34px; margin-left: 0; padding: 0 9px; }
  .main-nav { min-height: 54px; overflow-x: auto; overscroll-behavior-inline: contain; scrollbar-width: thin; -webkit-overflow-scrolling: touch; }
  .session-controls { position: absolute; top: 15px; right: 20px; }
  .session-user-role { display: none; }
  .logout-action { padding: 3px 0; }
  .user-actions { align-items: stretch; flex-direction: column; white-space: normal; }
  .user-actions .button { width: 100%; }
}

@media (min-width: 601px) and (max-width: 900px) {
  :root { --row-label-width: 180px; --year-width: 104px; --actions-width: 124px; }
  .detail-table .detail-actions { width: 128px; min-width: 128px; max-width: 128px; padding-right: 5px; padding-left: 5px; }
  .mapping-table { width: 100%; min-width: 0; table-layout: fixed; }
  .mapping-table th:nth-child(1) { width: 15%; }
  .mapping-table th:nth-child(2) { width: 30%; }
  .mapping-table th:nth-child(3) { width: 42%; }
  .mapping-table th:nth-child(4) { width: 13%; }
  .mapping-table th, .mapping-table td { overflow-wrap: anywhere; }
  .mapping-select { min-width: 0; }
  .mapping-actions { align-items: stretch; flex-direction: column; gap: 4px; white-space: normal; }
  .mapping-actions .button { width: 100%; padding: 5px 4px; font-size: 10.5px; }
  .users-table { width: 100%; min-width: 0; }
  .users-table th, .users-table td { overflow-wrap: anywhere; }
  .user-actions { gap: 4px; }
  .user-actions .button { min-height: 34px; padding: 5px 7px; font-size: 10.5px; }
}

@media (max-width: 600px) {
  :root {
    --row-label-width: 168px;
    --year-width: 98px;
    --actions-width: 136px;
    --month-width: 92px;
  }

  .app-header { min-height: 0; padding: 12px 12px 0; }
  .brand { min-height: 34px; }
  .brand strong { font-size: 17px; }
  .home-nav-action { top: 12px; left: 102px; font-size: 11px; }
  .main-nav { width: calc(100% + 24px); min-height: 50px; margin: 0 -12px; padding: 0 4px; }
  .main-nav button { min-height: 50px; padding: 0 13px; }

  main { padding: 15px 12px 32px; }
  .page-heading { align-items: flex-start; flex-direction: column; gap: 16px; margin-bottom: 12px; }
  h1 { font-size: 26px; }
  .eyebrow { margin-bottom: 5px; font-size: 11px; }

  .year-controls, .actual-year-control, .dashboard-period, .dashboard-period > div { width: 100%; }
  .year-controls > div { flex-wrap: wrap; }
  .year-controls select { flex: 1 1 112px; }
  #new-year { flex: 1 1 auto; }
  select, .button { min-height: 42px; }

  .users-heading > .button { width: 100%; }
  .users-table { min-width: 820px; }
  .users-table th, .users-table td { overflow-wrap: normal; }
  .user-actions { flex-direction: row; white-space: nowrap; }
  .user-actions .button { width: auto; min-height: 38px; padding: 6px 8px; font-size: 11px; }
  .user-modal { width: calc(100vw - 24px); max-height: calc(100svh - 24px); }
  .user-modal form { padding: 17px 15px 18px; }
  .user-form-grid, .user-password-fields { grid-template-columns: 1fr; gap: 12px; }
  .user-active-field { align-self: auto; min-height: 42px; }
  .user-password-action { align-items: flex-start; flex-direction: column; }
  .user-password-action .button { width: 100%; }

  .budget-card, .dashboard-kpi, .dashboard-card, .unassigned-card { border-radius: 10px; }
  .card-heading { gap: 10px; padding: 16px 14px 13px; }
  .card-heading h2 { font-size: 16px; }
  .card-heading p { line-height: 1.45; }
  .legend { white-space: normal; }
  .notice { margin-bottom: 12px; }

  .table-scroll { max-height: calc(100svh - 230px); min-height: 360px; }
  .actual-table-scroll { max-height: calc(100svh - 230px); min-height: 360px; }
  .budget-table th { position: sticky; top: 0; z-index: 8; }
  .budget-table .sticky-1 { position: sticky; top: auto; left: 0; z-index: 5; }
  .budget-table thead .sticky-1 { top: 0; z-index: 12; }
  .sticky-3 { position: static; top: auto; left: auto; z-index: auto; }
  .budget-table .sticky-2,
  .budget-table thead .sticky-2 { position: static; left: auto; z-index: auto; }
  .budget-table thead .sticky-2,
  .budget-table thead .sticky-3 { position: sticky; top: 0; left: auto; z-index: 8; }
  .forecast-table tbody .sticky-2 { position: static; left: auto; z-index: auto; width: auto; min-width: 0; max-width: none; }
  .forecast-table thead .sticky-2 { position: sticky; top: 0; left: auto; z-index: 8; width: auto; min-width: 0; max-width: none; }
  .cashflow-page-heading { align-items: flex-start; }
  .cashflow-actions { width: 100%; justify-content: flex-start; flex-wrap: wrap; }
  .cashflow-mode-switch { flex: 0 1 auto; }
  .cashflow-mode-switch .button { min-height: 28px; padding: 3px 8px; font-size: 12px; }
  .cashflow-metrics { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; margin-bottom: 10px; }
  .cashflow-metric { min-height: 90px; padding: 12px; }
  .cashflow-metric strong { margin-top: 5px; font-size: 21px; }
  .cashflow-metric span { margin-top: 2px; font-size: 11px; }
  .cashflow-balance-panel { grid-template-columns: 1fr; gap: 12px; margin-bottom: 10px; padding: 14px; }
  .cashflow-balance-form { grid-template-columns: 1fr; }
  .cashflow-balance-form-actions { justify-content: stretch; }
  .cashflow-balance-form-actions .button { min-height: 38px; flex: 1 1 0; }
  .cashflow-table-wrap { max-height: calc(100svh - 230px); min-height: 360px; }
  .cashflow-table { --row-label-width: 168px; min-width: 1120px; margin-inline: 0; }
  .cashflow-table .sticky-1 { position: sticky; left: 0; }
  .cashflow-table thead .sticky-1 { top: 0; z-index: 12; }
  .budget-table th, .budget-table td { font-size: 13px; }
  .budget-table th { font-size: 9px; }
  .row-label { font-size: 12px; }

  .detail-panel { width: calc(100vw - 42px); min-width: 0; margin: 8px; padding: 12px; }
  .detail-heading { align-items: flex-start; flex-direction: column; gap: 9px; }
  .detail-heading h3 { font-size: 13px; }
  .detail-table .detail-name { width: 170px; min-width: 170px; }
  .detail-table .detail-actions { width: 158px; min-width: 158px; max-width: 158px; padding-right: 8px; padding-left: 8px; }
  .detail-table .person-name { width: 145px; min-width: 145px; }
  .modal form { padding: 19px; }
  .modal-actions { flex-wrap: wrap; }

  .dashboard-kpis { grid-template-columns: 1fr; gap: 10px; margin-bottom: 10px; }
  .dashboard-page-heading, .dashboard-card-heading { align-items: flex-start; flex-direction: column; }
  .dashboard-period { align-items: flex-start; flex-direction: column; }
  .dashboard-kpi { min-height: 0; padding: 16px; }
  .dashboard-kpi h2 { min-height: 0; }
  .dashboard-kpi-value { margin: 9px 0 8px; font-size: 25px; }
  .dashboard-summary-grid { gap: 10px; margin-bottom: 10px; }
  .dashboard-card-heading { gap: 10px; padding: 15px 14px 12px; }
  .dashboard-card-heading h2 { font-size: 16px; }
  .dashboard-margin-list, .dashboard-variance-list { padding-right: 14px; padding-left: 14px; }
  .dashboard-variance-row { grid-template-columns: minmax(110px, 1fr) auto auto; gap: 8px; }
  .dashboard-variance-percent { min-width: 54px; }
  .dashboard-chart-control, .dashboard-chart-control select { width: 100%; min-width: 0; }
  .dashboard-chart-legend { justify-content: flex-start; padding-right: 14px; padding-left: 14px; }
  .dashboard-chart { min-height: 250px; padding-right: 8px; padding-left: 8px; }
  .dashboard-chart svg { min-width: 660px; height: 245px; }

  .actual-toolbar { gap: 12px; padding: 10px; }
  .month-statuses { width: 100%; flex-wrap: nowrap; overflow-x: auto; overscroll-behavior-inline: contain; padding-bottom: 4px; -webkit-overflow-scrolling: touch; }
  .month-status { flex: 0 0 auto; }
  .actual-actions { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); width: 100%; }
  .actual-actions .button { width: 100%; }
  .actual-actions .compare { grid-column: 1 / -1; }
  .actual-table { --actual-label-width: 148px; --actual-ytd-width: 98px; }
  .actual-table .actual-label { top: auto; z-index: 5; }
  .actual-table thead .actual-label { top: 0; left: 0; z-index: 12; }
  .actual-table .actual-ytd,
  .actual-table thead .actual-ytd { position: static; left: auto; z-index: auto; }
  .actual-table thead .actual-ytd { position: sticky; top: 0; left: auto; z-index: 8; }
  .actual-table .month-cell { width: 96px; min-width: 96px; max-width: 96px; }
  .account-row .actual-label { padding-left: 30px; }
  .rental-level-row .actual-label { padding-left: 14px; }
  .rental-account-row .actual-label { padding-left: 38px; }
  .unassigned-heading { align-items: flex-start; flex-direction: column; gap: 8px; padding: 14px; }

  .comparison-controls { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); width: 100%; gap: 9px; }
  .comparison-controls > div, .comparison-controls select { width: 100%; min-width: 0; }
  .comparison-controls .comparison-back { grid-column: 1 / -1; width: 100%; }
  .comparison-note { margin-top: 0; line-height: 1.45; }
  .comparison-table { min-width: 720px; }
  .comparison-table th:first-child, .comparison-table td:first-child { min-width: 240px; }
  .comparison-table th:first-child, .comparison-table td:first-child { position: sticky; top: auto; left: 0; z-index: 5; }
  .comparison-table th:first-child { z-index: 6; }
  .analysis-sticky-header { display: none; }

  .admin-tabs { flex-wrap: nowrap; overflow-x: auto; overscroll-behavior-inline: contain; -webkit-overflow-scrolling: touch; }
  .admin-tabs button { min-height: 43px; padding: 0 13px; }
  .admin-card { border-radius: 10px; }
  .admin-card-heading { flex-direction: column; gap: 9px; padding: 16px 14px 13px; }
  .prototype-note, .import-scenario, .import-dropzone { margin-right: 14px; margin-left: 14px; }
  .import-scenario { grid-template-columns: 1fr; }
  .import-scenario .button { width: 100%; }
  .import-dropzone { padding: 20px 13px; }
  .selected-file { align-items: flex-start; flex-direction: column; }
  .import-check-body { padding: 15px 14px 17px; }
  .import-summary-grid { grid-template-columns: 1fr; }
  .import-finance-grid { grid-template-columns: 1fr; }
  .admin-success-body { align-items: flex-start; grid-template-columns: 1fr; padding: 16px 14px; }
  .admin-success-actions { justify-content: flex-start; }
  .mapping-filters { width: 100%; }
  .mapping-filter { flex: 1 1 0; }
  .admin-history-body { padding: 14px; }
  .import-month-statuses { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .import-month-status:nth-child(6n) { border-right: 1px solid var(--line); }
  .import-month-status:nth-last-child(-n + 6) { border-bottom: 1px solid var(--line); }
  .import-month-status:nth-child(2n) { border-right: 0; }
  .import-month-status:nth-last-child(-n + 2) { border-bottom: 0; }
  .import-history-previous ul { grid-template-columns: 1fr; }
}

@media (max-width: 380px) {
  :root { --row-label-width: 154px; --year-width: 92px; --actions-width: 132px; }
  main { padding-right: 10px; padding-left: 10px; }
  .dashboard-kpi-value { font-size: 23px; }
  .dashboard-kpi-variance { flex-wrap: wrap; }
  .dashboard-variance-row { grid-template-columns: minmax(98px, 1fr) auto; }
  .dashboard-variance-percent { grid-column: 2; }
  .actual-table { --actual-label-width: 140px; --actual-ytd-width: 92px; }
}
/* Patvirtintas SOLVAT Pradžios puslapio etalonas. */
#home-view { min-height: 100vh; }
#home-view .page-shell { position: relative; min-height: 100vh; overflow: hidden; color: #10263b; background: radial-gradient(circle at 12% 60%, rgba(100,161,121,.07), transparent 28%), radial-gradient(circle at 88% 68%, rgba(61,142,159,.06), transparent 30%), linear-gradient(180deg,#fff 0%,#fdfefe 100%); }
#home-view .portal-topbar { position: relative; z-index: 5; display: flex; align-items: center; justify-content: space-between; padding: 40px 5.2vw 0; }
#home-view .portal-brand { border: 0; padding: 0; color: #c78e24; background: transparent; font-size: 44px; font-weight: 500; letter-spacing: .08em; line-height: 1; cursor: pointer; }
#home-view .portal-user { display: flex; align-items: center; gap: 14px; }
#home-view .user-avatar { position: relative; width: 48px; height: 48px; border-radius: 50%; display: grid; place-items: center; font-size: 17px; font-weight: 500; color: #0c4a33; background: linear-gradient(145deg,#eef5f0,#dfece4); }
#home-view .status-dot { position: absolute; right: 2px; bottom: 2px; width: 11px; height: 11px; border-radius: 50%; background: #2e8b57; box-shadow: 0 0 0 2px #fff; }
#home-view .user-copy { display: flex; flex-direction: column; gap: 3px; min-width: 145px; }
#home-view .user-copy strong { font-size: 16px; font-weight: 600; }
#home-view .user-copy span { font-size: 14px; color: #6f7d8c; }
#home-view .user-divider { width: 1px; height: 40px; background: #dfe4e8; margin: 0 6px; }
#home-view .logout-button { border: 0; padding: 8px 0; color: #12613b; background: transparent; display: inline-flex; align-items: center; gap: 8px; cursor: pointer; font-weight: 500; }
#home-view .logout-button:hover { color: #0b4b2d; }
#home-view .logout-icon { font-size: 21px; transform: rotate(180deg); }
#home-view .portal-main { position: relative; z-index: 3; width: min(1060px, calc(100% - 48px)); margin: 68px auto 0; }
#home-view .welcome { text-align: center; margin-bottom: 52px; }
#home-view .welcome h1 { margin: 0; color: #1e3040; font-size: 44px; line-height: 1.12; font-weight: 400; letter-spacing: -.02em; }
#home-view .welcome p { margin: 14px 0 0; color: #758293; font-size: 20px; }
#home-view .tool-grid { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 28px 36px; }
#home-view .tool-card { --accent: #2f8e55; position: relative; min-height: 242px; display: grid; grid-template-columns: 132px 1fr 54px; align-items: center; gap: 28px; width: 100%; padding: 26px 28px 26px 34px; color: #10263b; text-align: left; border: 1px solid color-mix(in srgb, var(--accent) 24%, white); border-left: 4px solid var(--accent); border-radius: 18px; background: radial-gradient(circle at 90% 88%, color-mix(in srgb, var(--accent) 9%, transparent) 0 26%, transparent 27%), linear-gradient(135deg, rgba(255,255,255,.96), color-mix(in srgb, var(--accent) 4%, white)); box-shadow: 0 12px 28px rgba(41,61,73,.09); transition: transform .18s ease, box-shadow .18s ease; cursor: pointer; }
#home-view .tool-card[hidden] { display: none; }
#home-view .tool-card:hover { transform: translateY(-2px); box-shadow: 0 16px 34px rgba(41,61,73,.12); }
#home-view .card-pricing { --accent: #2865c8; } #home-view .card-cash { --accent: #c18a17; } #home-view .card-planner { --accent: #7656a6; } #home-view .card-admin { --accent: #148b93; }
#home-view .tool-icon { width: 118px; height: 118px; border-radius: 22px; display: grid; place-items: center; color: var(--accent); background: linear-gradient(145deg,#fff,color-mix(in srgb,var(--accent) 9%,white)); border: 1px solid color-mix(in srgb,var(--accent) 13%,white); box-shadow: 0 8px 18px rgba(41,61,73,.08); }
#home-view .tool-icon svg { width: 70px; height: 70px; }
#home-view .tool-copy { display: flex; flex-direction: column; }
#home-view .tool-copy strong { margin: 0 0 18px; color: color-mix(in srgb,var(--accent) 88%, #183047); font-size: 29px; line-height: 1.16; font-weight: 500; }
#home-view .tool-copy span { color: #5f6d7b; font-size: 17px; line-height: 1.55; }
#home-view .tool-arrow { align-self: end; justify-self: end; width: 52px; height: 52px; border-radius: 50%; display: grid; place-items: center; color: var(--accent); background: rgba(255,255,255,.92); box-shadow: 0 8px 20px rgba(57,72,84,.10); font-size: 42px; line-height: 1; font-weight: 300; }
#home-view .portal-footer { position: relative; z-index: 3; display: flex; align-items: center; justify-content: center; gap: 16px; margin: 98px 40px 0; padding: 26px 0 28px; border-top: 1px solid #e8ecef; color: #7c8794; font-size: 14px; }
#home-view .footer-shield { margin-left: 8px; color: #2f8e55; font-size: 18px; }
#home-view .bg-shape { position: absolute; z-index: 1; pointer-events: none; filter: blur(.1px); } #home-view .bg-left { left: -120px; bottom: 85px; width: 390px; height: 360px; border-radius: 46% 54% 0 0 / 58% 50% 0 0; background: radial-gradient(circle at 36% 36%, rgba(124,170,134,.16) 0 28%, transparent 29%), linear-gradient(150deg, rgba(123,165,139,.18), rgba(209,231,214,.06)); transform: rotate(-9deg); } #home-view .bg-right { right: -120px; bottom: 18px; width: 430px; height: 340px; border-radius: 55% 45% 0 0 / 55% 52% 0 0; background: linear-gradient(150deg, rgba(115,185,183,.10), rgba(214,234,230,.02)); transform: rotate(11deg); } #home-view .bg-lines { position: absolute; z-index: 1; right: 2%; top: 18%; width: 320px; height: 220px; opacity: .32; background: repeating-radial-gradient(ellipse at 100% 50%, transparent 0 11px, rgba(74,130,148,.12) 12px 13px); mask-image: linear-gradient(90deg,transparent,#000 38%); }
body.home-active > .app-header { display: none; }
@media (max-width: 900px) { #home-view .portal-topbar { padding: 26px 24px 0; align-items: flex-start; } #home-view .portal-brand { font-size: 28px; } #home-view .user-copy span, #home-view .user-divider { display: none; } #home-view .user-copy { min-width: auto; } #home-view .portal-main { width: min(760px,calc(100% - 32px)); margin-top: 54px; } #home-view .welcome { margin-bottom: 34px; } #home-view .welcome h1 { font-size: 36px; } #home-view .tool-grid { grid-template-columns: 1fr; gap: 20px; } #home-view .tool-card { min-height: 190px; } #home-view .portal-footer { margin-top: 60px; flex-wrap: wrap; gap: 8px 12px; } }
@media (max-width: 620px) { #home-view .portal-topbar { gap: 16px; } #home-view .portal-user { gap: 9px; } #home-view .user-avatar { width: 40px; height: 40px; font-size: 14px; } #home-view .user-copy strong, #home-view .logout-button { font-size: 14px; } #home-view .portal-main { margin-top: 46px; } #home-view .welcome h1 { font-size: 31px; } #home-view .welcome p { font-size: 17px; } #home-view .tool-card { grid-template-columns: 84px 1fr 44px; gap: 18px; padding: 22px 18px 22px 22px; min-height: 160px; border-radius: 16px; } #home-view .tool-icon { width: 80px; height: 80px; border-radius: 18px; } #home-view .tool-icon svg { width: 48px; height: 48px; } #home-view .tool-copy strong { margin-bottom: 10px; font-size: 22px; } #home-view .tool-copy span { font-size: 15px; } #home-view .tool-arrow { width: 42px; height: 42px; font-size: 34px; } #home-view .portal-footer { margin-left: 18px; margin-right: 18px; font-size: 12px; } }
@media (max-width: 460px) { #home-view .portal-topbar { padding-left: 18px; padding-right: 18px; } #home-view .portal-brand { font-size: 24px; letter-spacing: .09em; } #home-view .user-copy { display: none; } #home-view .tool-card { grid-template-columns: 70px 1fr 38px; gap: 14px; } #home-view .tool-icon { width: 66px; height: 66px; } #home-view .tool-icon svg { width: 40px; height: 40px; } #home-view .tool-copy strong { font-size: 20px; } #home-view .tool-copy span { font-size: 14px; } }

/* Kainininkas V1: existing page, card and horizontal-table language. */
.pricing-view { width: min(1440px, calc(100% - 48px)); margin: 0 auto; padding: 34px 0 64px; }
.pricing-heading { align-items: center; }
.pricing-heading-actions, .pricing-toolbar, .pricing-toolbar-controls, .pricing-price-mode, .pricing-category-filters, .pricing-card-actions { display: flex; align-items: center; gap: 9px; }
.pricing-toolbar { justify-content: space-between; margin: 22px 0 14px; padding: 14px; border: 1px solid var(--line); border-radius: 10px; background: #fff; }
.pricing-search { display: flex; align-items: center; gap: 10px; min-width: min(100%, 440px); color: var(--muted); font-size: 12px; font-weight: 600; }
.pricing-search input { width: 100%; }
.pricing-status-filter { display: flex; align-items: center; gap: 6px; color: var(--muted); font-size: 12px; font-weight: 600; }.pricing-status-filter select { min-width: 112px; }
.pricing-price-mode { padding: 3px; border: 1px solid var(--line); border-radius: 7px; background: #f6f8f7; }
.pricing-price-mode button, .pricing-category-filter { border: 0; border-radius: 5px; padding: 8px 10px; color: #53615a; background: transparent; font: inherit; font-size: 12px; font-weight: 600; cursor: pointer; }
.pricing-price-mode button.active, .pricing-category-filter.active { color: #fff; background: #426b8f; }
.pricing-category-filters { overflow-x: auto; padding: 2px 0 14px; }
.pricing-category-filter { flex: 0 0 auto; border: 1px solid var(--line); background: #fff; }
.pricing-categories { display: grid; gap: 18px; }
.pricing-category-card { overflow: hidden; border: 1px solid var(--line); border-radius: 10px; background: #fff; box-shadow: 0 5px 16px rgba(30,55,43,.05); }
.pricing-category-heading { display: grid; grid-template-columns: 160px minmax(0, 1fr) auto; align-items: center; gap: 18px; min-height: 131px; padding: 13px 16px; border-bottom: 1px solid var(--line); }
.pricing-category-image { box-sizing: border-box; width: 160px; height: 105px; padding: 6px; object-fit: contain; border-radius: 6px; background: #eef2ef; }
.pricing-category-heading h2 { margin: 0; font-size: 18px; font-weight: 600; }
.pricing-category-heading p { margin: 4px 0 0; color: var(--muted); font-size: 12px; }
.pricing-table-wrap { overflow-x: auto; }
.pricing-table { width: 100%; min-width: 900px; border-collapse: collapse; font-size: 14px; }
.pricing-table th, .pricing-table td { padding: 10px 12px; border-bottom: 1px solid #e7ece8; vertical-align: middle; text-align: left; }
.pricing-table th { color: #627068; background: #f7f9f7; font-size: 11px; font-weight: 600; white-space: nowrap; }
.pricing-table tbody tr:last-child td { border-bottom: 0; }
.pricing-table .price-before { color: #26322c; font-weight: 600; white-space: nowrap; }.pricing-table .price-vat, .pricing-calculator .price-vat { color: #426b8f; font-weight: 600; white-space: nowrap; }
.pricing-table .cost-cell { color: #37584a; font-weight: 600; white-space: nowrap; }
.pricing-table .pricing-row-actions { width: 1%; white-space: nowrap; }.pricing-row-actions .button { margin: 0 2px 0 0; padding: 5px 7px; font-size: 12px; line-height: 1.2; }
.pricing-table .muted-cell { color: #89938d; }
.pricing-drag-column, .pricing-drag-cell { width: 1%; padding-right: 2px !important; padding-left: 8px !important; }.pricing-drag-handle { min-width: 28px; min-height: 30px; border: 1px solid var(--line); border-radius: 5px; color: #627068; background: #f7f9f7; font: inherit; font-size: 16px; line-height: 1; cursor: grab; touch-action: none; }.pricing-drag-handle:active { cursor: grabbing; }.pricing-dragging { opacity: .55; }.pricing-drop-target { box-shadow: inset 0 3px 0 #426b8f; }
.pricing-status { display: inline-flex; border-radius: 999px; padding: 3px 8px; font-size: 11px; font-weight: 600; white-space: nowrap; }
.pricing-status-active { color: #276447; background: #e8f4ed; }.pricing-status-out_of_stock { color: #8a4e18; background: #fff3e5; }.pricing-status-made_to_order { color: #426b8f; background: #eaf0f6; }.pricing-status-inactive { color: #69726d; background: #eff1f0; }
.pricing-empty { margin: 0; padding: 24px; color: var(--muted); text-align: center; }
.pricing-modal { width: min(620px, calc(100vw - 32px)); }.pricing-file-field { grid-column: 1 / -1; }.pricing-file-field small { display: block; margin-top: 6px; color: var(--muted); }.pricing-product-modal { width: min(1240px, calc(100vw - 32px)); }.pricing-product-modal form { padding: 18px 20px 20px; }.pricing-product-modal .user-modal-heading { margin-bottom: 14px; }.pricing-product-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 10px 12px; }.pricing-product-modal .user-field { gap: 5px; font-size: 13px; }.pricing-product-modal .user-field input, .pricing-product-modal .user-field select, .pricing-product-modal .user-field textarea { font-size: 15px; line-height: 1.25; }.pricing-product-modal .user-field input, .pricing-product-modal .user-field select { min-height: 39px; }.pricing-product-modal .user-field input[readonly] { border-color: #cbd4ce; background: #f2f5f3; color: #37584a; font-weight: 600; }.pricing-note-field { grid-column: 1 / -1; }.pricing-note-field textarea { box-sizing: border-box; width: 100%; min-height: 62px; border: 1px solid var(--line-strong); border-radius: 7px; padding: 8px 10px; resize: vertical; }.pricing-product-actions { align-items: center; justify-content: space-between; margin-top: 16px; }.pricing-product-actions-end { display: flex; gap: 8px; margin-left: auto; }.pricing-product-delete { border-color: #d5b5b5; background: #fff5f5; color: var(--danger); }.pricing-product-delete:hover { border-color: #bd9292; background: #ffecec; }
.pricing-pdf-modal { width: min(520px, calc(100vw - 32px)); }.pricing-pdf-options { display: flex; gap: 18px; margin: 0 0 16px; border: 1px solid var(--line); border-radius: 8px; padding: 12px 14px; }.pricing-pdf-options legend { padding: 0 5px; color: var(--muted); font-size: 12px; font-weight: 600; }.pricing-pdf-options label { display: inline-flex; align-items: center; gap: 7px; color: var(--ink); font-size: 14px; }.pricing-pdf-options input { margin: 0; }.pricing-pdf-help { margin: 12px 0 0; color: var(--muted); font-size: 12px; line-height: 1.45; }
.pricing-calculator { margin-top: 14px; padding: 13px; border: 1px solid var(--line); border-radius: 8px; background: #f8faf8; }.pricing-calculator h3 { margin: 0; font-size: 15px; font-weight: 600; }.pricing-calculator > p { margin: 4px 0 10px; font-size: 13px; }.pricing-calculator-grid { display: grid; grid-template-columns: repeat(2, minmax(0,1fr)); gap: 12px; }.pricing-calculator-side { display: grid; grid-template-columns: minmax(160px, .8fr) minmax(225px, 1.2fr); align-items: start; gap: 10px; }.pricing-calculator output { display: block; align-self: start; min-height: 40px; color: #37584a; font-size: 13px; line-height: 1.4; }.pricing-design-result { display: grid; gap: 5px; padding: 9px; border: 1px solid var(--line); border-radius: 6px; background: #fff; }.pricing-design-row { display: flex; align-items: center; justify-content: space-between; gap: 10px; }.pricing-design-row span { color: var(--muted); }.pricing-design-row strong { color: #37584a; font-weight: 600; text-align: right; }.pricing-design-gross { width: 112px; min-height: 34px; border: 1px solid #9daaa1; border-radius: 5px; padding: 5px 8px; color: var(--ink); font: inherit; text-align: right; }.pricing-design-actions { display: flex; justify-content: flex-end; margin-top: 2px; }.pricing-cost-history { margin-top: 10px; color: var(--muted); font-size: 13px; }.pricing-cost-history ul { display: flex; flex-wrap: wrap; gap: 7px; margin: 5px 0 0; padding: 0; list-style: none; }.pricing-cost-history li { padding: 4px 7px; border: 1px solid var(--line); border-radius: 5px; background: #fff; }.pricing-negotiation-facts { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 8px; margin: 0 0 16px; }.pricing-negotiation-facts div { padding: 9px; border: 1px solid var(--line); border-radius: 6px; background: #f8faf8; }.pricing-negotiation-facts span { display: block; color: var(--muted); font-size: 11px; }.pricing-negotiation-facts strong { display: block; margin-top: 3px; color: #37584a; font-size: 14px; font-weight: 600; }.pricing-negotiation-result-ok { color: #276447 !important; }.pricing-negotiation-result-warning { color: #9b571c !important; }
@media (min-width: 761px) and (max-width: 1100px) { .pricing-category-heading { grid-template-columns: 130px minmax(0, 1fr) auto; min-height: 112px; gap: 15px; }.pricing-category-image { width: 130px; height: 90px; }.pricing-product-modal { width: min(900px, calc(100vw - 24px)); }.pricing-product-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }.pricing-calculator-grid { grid-template-columns: 1fr; } }
@media (max-width: 760px) { .pricing-view { width: min(100% - 24px, 1440px); padding-top: 22px; }.pricing-heading { align-items: flex-start; gap: 14px; }.pricing-heading-actions { flex-wrap: wrap; justify-content: flex-end; }.pricing-toolbar { align-items: stretch; flex-direction: column; }.pricing-toolbar-controls { justify-content: space-between; }.pricing-search { min-width: 0; align-items: flex-start; flex-direction: column; }.pricing-category-heading { grid-template-columns: 100px minmax(0, 1fr); min-height: 92px; padding: 10px; }.pricing-category-image { width: 100px; height: 70px; }.pricing-card-actions { grid-column: 1 / -1; }.pricing-product-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }.pricing-calculator-grid { grid-template-columns: 1fr; } }
@media (max-width: 480px) { .pricing-price-mode { width: 100%; }.pricing-price-mode button { flex: 1; padding-left: 6px; padding-right: 6px; }.pricing-toolbar-controls, .pricing-negotiation-facts, .pricing-pdf-options { align-items: stretch; flex-direction: column; display: flex; }.pricing-product-grid, .pricing-calculator-side { grid-template-columns: 1fr; }.pricing-category-heading h2 { font-size: 16px; } }

/* Kasos aparato knyga V1: atskiras portalų modulis, naudojantis bendrą finansinių lentelių kalbą. */
body.cash-register-active .main-nav { display: none; }
.cash-register-view { width: min(1800px, calc(100% - 48px)); margin: 0 auto; padding: 20px 0 36px; }
.cash-register-heading { align-items: end; margin-bottom: 4px; gap: 12px; }
.cash-register-heading .intro { margin-bottom: 0; }
.cash-register-period { display: flex; align-items: end; gap: 10px; }
.cash-register-period label { display: grid; gap: 6px; color: var(--muted); font-size: 12px; font-weight: 650; }
.cash-register-period select { min-width: 132px; }
.cash-register-summary-section { margin-bottom: 2px; }
.cash-register-summary-section > h2 { margin: 0 0 6px; font-size: 1rem; }
.cash-register-summary { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 9px; margin: 0 auto 8px; }
.cash-register-metric { min-height: 55px; border: 1px solid var(--line); border-radius: 9px; padding: 9px 10px; background: var(--surface); box-shadow: 0 3px 8px rgba(36, 61, 48, .05); }
.cash-register-metric span { display: block; color: #2f3b35; font-size: 12px; line-height: 1.2; font-weight: 600; text-transform: uppercase; letter-spacing: .01em; }
.cash-register-metric strong { display: block; margin-top: 4px; color: var(--ink); font-size: 17.5px; line-height: 1.2; font-weight: 700; font-variant-numeric: tabular-nums; text-align: right; }
.cash-register-metric.warning { border-color: #d9bd8e; background: #fffaf0; }
.cash-register-card { max-width: none; overflow: hidden; }
.cash-register-card .card-heading { padding: 10px 14px 9px; gap: 8px; }
.cash-register-card .card-heading h2 { margin: 0; font-size: 17px; }
.cash-register-card .card-heading p { margin: 3px 0 0; font-size: 11.5px; }
.cash-register-table-wrap { width: 100%; max-height: calc(100vh - 220px); min-height: 350px; overflow: auto; overscroll-behavior-inline: contain; -webkit-overflow-scrolling: touch; }
.cash-register-table { --cash-register-day-width: 64px; width: max-content; min-width: 1505px; margin-inline: auto; border-collapse: separate; border-spacing: 0; border-left: 1px solid var(--line); font-size: 13.5px; }
.cash-register-table th, .cash-register-table td { min-width: 114px; border-right: 1px solid var(--line); border-bottom: 1px solid var(--line); padding: 3px 8px; background: var(--surface); color: #33413a; text-align: right; vertical-align: middle; font-variant-numeric: tabular-nums; line-height: 1.15; }
.cash-register-table th { position: sticky; top: 0; z-index: 8; min-height: 36px; height: 36px; background: #d7e2db; color: #29352f; font-size: 11.5px; font-weight: 700; text-align: center; text-transform: none; white-space: nowrap; border-bottom: 2px solid #bdc8bf; line-height: 1.1; }
.cash-register-table th:nth-child(2), .cash-register-table th:nth-child(3), .cash-register-table th:nth-child(4), .cash-register-table th:nth-child(5), .cash-register-table th:nth-child(9), .cash-register-table th:nth-child(10), .cash-register-table th:nth-child(11), .cash-register-table th:nth-child(14) { white-space: normal; }
.cash-register-table .sticky-day, .cash-register-table th.sticky-day, .cash-register-table thead .sticky-day { font-size: 12px; }
.cash-register-table thead .sticky-day { position: sticky; top: 0; left: 0; z-index: 12; width: var(--cash-register-day-width); min-width: var(--cash-register-day-width); background: #d2ddd6; text-align: left; }
.cash-register-table tbody .sticky-day { position: sticky; left: 0; z-index: 7; width: var(--cash-register-day-width); min-width: var(--cash-register-day-width); background: var(--surface); color: var(--ink); text-align: left; }
.cash-register-table tbody tr { height: 32px; }
.cash-register-table tbody tr:nth-child(even) td { background: #fbfcfb; }
.cash-register-table tbody tr:nth-child(even) .sticky-day { background: #fbfcfb; }
.cash-register-table .cash-register-weekend td { background: #f4f6f4; color: #77837c; }
.cash-register-table .cash-register-weekend .sticky-day { background: #f4f6f4; }
.cash-register-table .cash-register-editing td { background: #f4f8f5; }
.cash-register-table .cash-register-editing .sticky-day { background: #eef5f0; }
.cash-register-table .cash-register-computed { background: #f5f8f6; color: #486057; font-weight: 600; }
.cash-register-actions-heading, .cash-register-actions-cell { min-width: 90px !important; text-align: left !important; white-space: nowrap; }
.cash-register-actions { display: flex; align-items: center; gap: 4px; }
.cash-register-actions .button.compact, .cash-register-actions-cell > .button.compact { box-sizing: border-box; height: 26px; min-height: 26px; border-radius: 4px; padding: 0 9px; font-size: 12px; line-height: 1; }
.cash-register-readonly { color: var(--muted); font-size: 11px; }
.cash-register-input { box-sizing: border-box; width: 100%; min-width: 102px; height: 26px; border: 1px solid #9daaa1; border-radius: 4px; padding: 2px 6px; background: #fff; color: var(--ink); text-align: right; font: inherit; font-variant-numeric: tabular-nums; }
.cash-register-input:focus { outline: 2px solid rgba(49, 106, 80, .23); border-color: var(--green-2); }
.cash-register-input::placeholder { color: #98a39d; font-size: 10px; }
.cash-register-difference { display: inline-flex; min-width: 64px; justify-content: flex-end; border-radius: 5px; padding: 2px 4px; }
.cash-register-difference.warning { background: #fff0e2; color: #944a12; font-weight: 600; }
.cash-register-suggestion { display: block; margin-top: 3px; color: #728076; font-size: 9px; font-weight: 600; line-height: 1.2; }
.cash-register-table th:nth-child(1), .cash-register-table td:nth-child(1) { min-width: 64px; width: 64px; }
.cash-register-table th:nth-child(2), .cash-register-table td:nth-child(2) { min-width: 106px; width: 106px; }
.cash-register-table th:nth-child(3), .cash-register-table td:nth-child(3) { min-width: 120px; width: 120px; }
.cash-register-table th:nth-child(4), .cash-register-table td:nth-child(4) { min-width: 106px; width: 106px; }
.cash-register-table th:nth-child(5), .cash-register-table td:nth-child(5) { min-width: 105px; width: 105px; }
.cash-register-table th:nth-child(6), .cash-register-table td:nth-child(6) { min-width: 105px; width: 105px; }
.cash-register-table th:nth-child(7), .cash-register-table td:nth-child(7) { min-width: 95px; width: 95px; }
.cash-register-table th:nth-child(8), .cash-register-table td:nth-child(8) { min-width: 95px; width: 95px; }
.cash-register-table th:nth-child(9), .cash-register-table td:nth-child(9) { min-width: 114px; width: 114px; }
.cash-register-table th:nth-child(10), .cash-register-table td:nth-child(10) { min-width: 104px; width: 104px; }
.cash-register-table th:nth-child(11), .cash-register-table td:nth-child(11) { min-width: 105px; width: 105px; }
.cash-register-table th:nth-child(12), .cash-register-table td:nth-child(12) { min-width: 95px; width: 95px; }
.cash-register-table th:nth-child(13), .cash-register-table td:nth-child(13) { min-width: 95px; width: 95px; }
.cash-register-table th:nth-child(14), .cash-register-table td:nth-child(14) { min-width: 109px; width: 109px; }
.cash-register-table th:nth-child(15), .cash-register-table td:nth-child(15) { min-width: 90px; width: 90px; }
.cash-register-table tbody .sticky-day strong { font-size: 13.5px; font-weight: 600; }
@media (max-width: 900px) {
  .cash-register-summary { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .cash-register-view { width: min(1800px, calc(100% - 32px)); padding-top: 22px; }
  .cash-register-table-wrap { max-height: none; min-height: 280px; }
  .cash-register-table { min-width: 1505px; font-size: 13px; }
}
@media (max-width: 620px) {
  .cash-register-view { width: min(1800px, calc(100% - 24px)); padding-top: 20px; }
  .cash-register-heading { align-items: flex-start; gap: 12px; margin-bottom: 2px; }
  .cash-register-heading .intro { max-width: 100%; }
  .cash-register-period { width: 100%; }
  .cash-register-period label { flex: 1; }
  .cash-register-period select { min-width: 0; width: 100%; }
  .cash-register-summary { gap: 8px; }
  .cash-register-metric { min-height: 62px; padding: 8px 9px; }
  .cash-register-metric span { font-size: 11.5px; }
  .cash-register-metric strong { font-size: 16.5px; }
  .cash-register-card .card-heading { padding: 9px 11px; gap: 6px; }
  .cash-register-card .card-heading h2 { font-size: 16px; }
  .cash-register-card .card-heading p { margin-top: 2px; font-size: 11px; }
  .cash-register-table { min-width: 1436px; font-size: 13px; }
  .cash-register-table th { min-height: 36px; height: 36px; font-size: 10.5px; }
  .cash-register-table th:nth-child(1), .cash-register-table td:nth-child(1) { min-width: 56px; width: 56px; }
  .cash-register-table th:nth-child(2), .cash-register-table td:nth-child(2) { min-width: 90px; width: 90px; }
  .cash-register-table th:nth-child(3), .cash-register-table td:nth-child(3) { min-width: 104px; width: 104px; }
  .cash-register-table th:nth-child(4), .cash-register-table td:nth-child(4), .cash-register-table th:nth-child(5), .cash-register-table td:nth-child(5), .cash-register-table th:nth-child(6), .cash-register-table td:nth-child(6) { min-width: 94px; width: 94px; }
  .cash-register-table th:nth-child(7), .cash-register-table td:nth-child(7), .cash-register-table th:nth-child(8), .cash-register-table td:nth-child(8), .cash-register-table th:nth-child(12), .cash-register-table td:nth-child(12), .cash-register-table th:nth-child(13), .cash-register-table td:nth-child(13) { min-width: 82px; width: 82px; }
  .cash-register-table th:nth-child(9), .cash-register-table td:nth-child(9), .cash-register-table th:nth-child(14), .cash-register-table td:nth-child(14) { min-width: 102px; width: 102px; }
  .cash-register-table th:nth-child(10), .cash-register-table td:nth-child(10), .cash-register-table th:nth-child(11), .cash-register-table td:nth-child(11) { min-width: 94px; width: 94px; }
  .cash-register-actions-heading, .cash-register-actions-cell { min-width: 84px !important; }
}
@media (max-width: 420px) { .cash-register-period { align-items: stretch; flex-direction: column; } }

/* Planeris */
.planner-view { width: min(1180px, calc(100% - 48px)); margin: 0 auto; padding-top: 28px; }
.planner-heading { align-items: center; margin-bottom: 16px; }
.planner-summary { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; margin-bottom: 14px; }
.planner-metric { min-height: 90px; display: flex; align-items: baseline; justify-content: center; gap: 9px; border: 1px solid var(--line); border-radius: 10px; padding: 20px; background: var(--surface); box-shadow: 0 4px 14px rgba(32, 49, 40, .05); }
.planner-metric strong { font-size: 32px; line-height: 1; font-variant-numeric: tabular-nums; }
.planner-metric span { color: var(--muted); font-size: 13px; font-weight: 700; }
.planner-metric.danger strong, .planner-metric.danger span { color: var(--danger); }
.planner-metric.warning strong, .planner-metric.warning span { color: #a65b08; }
.planner-metric.neutral strong { color: #25598d; }
.planner-filters { display: grid; grid-template-columns: minmax(260px, .75fr) minmax(430px, 1.25fr); gap: 12px; margin-bottom: 20px; }
.planner-filters fieldset { min-width: 0; margin: 0; border: 1px solid var(--line); border-radius: 10px; padding: 10px 12px 12px; background: var(--surface); }
.planner-filters legend { padding: 0 4px; color: var(--muted); font-size: 11px; font-weight: 800; text-transform: uppercase; }
.planner-filter-buttons { display: flex; gap: 7px; }
.planner-filter-buttons button { min-height: 36px; border: 1px solid var(--line-strong); border-radius: 7px; padding: 0 14px; background: #fff; color: #46534d; font-weight: 650; }
.planner-filter-buttons button.active { border-color: var(--green); background: var(--green); color: #fff; }
.planner-filters select { display: none; width: 100%; }
.planner-groups { display: grid; gap: 22px; }
.planner-group { min-width: 0; }
.planner-group-heading { display: flex; align-items: center; gap: 8px; margin: 0 0 7px 2px; color: #526059; font-size: 12px; font-weight: 800; letter-spacing: .045em; text-transform: uppercase; }
.planner-group-heading::before { content: ""; width: 3px; height: 17px; border-radius: 3px; background: #87928c; }
.planner-group.overdue .planner-group-heading { color: var(--danger); }.planner-group.overdue .planner-group-heading::before { background: #d73535; }
.planner-group.today .planner-group-heading { color: #a65b08; }.planner-group.today .planner-group-heading::before { background: #e47e0f; }
.planner-group.upcoming .planner-group-heading { color: #8a6b0b; }.planner-group.upcoming .planner-group-heading::before { background: #d4a20e; }
.planner-group.later .planner-group-heading { color: #316a9f; }.planner-group.later .planner-group-heading::before { background: #3779bd; }
.planner-task-list { display: grid; gap: 7px; }
.planner-row { display: grid; grid-template-columns: 34px minmax(0, 1fr) auto 108px 34px 34px; align-items: center; gap: 10px; min-height: 54px; border: 1px solid var(--line); border-radius: 9px; padding: 6px 10px; background: var(--surface); box-shadow: 0 2px 7px rgba(32, 49, 40, .035); }
.planner-row.completed { opacity: .64; background: #f5f7f5; }.planner-row.completed .planner-task-title { text-decoration: line-through; }
.planner-checkbox { width: 34px; height: 34px; display: grid; place-items: center; margin: 0; cursor: pointer; }
.planner-checkbox input { width: 19px; height: 19px; margin: 0; accent-color: var(--green-2); cursor: pointer; }
.planner-task-title { min-width: 0; border: 0; padding: 4px 0; overflow: hidden; color: var(--ink); background: transparent; font-weight: 650; line-height: 1.3; text-align: left; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; }
.planner-task-title:hover { color: var(--green-2); text-decoration: underline; text-underline-offset: 3px; }
.planner-deadline-badge { border: 1px solid var(--line-strong); border-radius: 6px; padding: 4px 8px; background: #f7f9f7; color: #526059; font-size: 11px; font-weight: 750; white-space: nowrap; }
.planner-deadline-badge.overdue { border-color: #efb2b2; background: #fff3f3; color: #b52b2b; }.planner-deadline-badge.today { border-color: #efbd88; background: #fff6ec; color: #a75308; }.planner-deadline-badge.upcoming { border-color: #ead18a; background: #fffbea; color: #80620a; }.planner-deadline-badge.later { border-color: #b7d0e8; background: #f1f7fd; color: #2f6598; }
.planner-deadline-date { color: var(--muted); font-size: 12px; font-variant-numeric: tabular-nums; white-space: nowrap; }
.planner-note-indicator, .planner-row-action { width: 34px; height: 34px; display: grid; place-items: center; border: 0; border-radius: 6px; background: transparent; color: #65716b; font-size: 18px; }
.planner-note-indicator[hidden] { display: block; visibility: hidden; }.planner-row-action:hover, .planner-note-indicator:hover { background: #f0f3f1; color: var(--ink); }
.planner-empty { border: 1px dashed #bdc7c1; border-radius: 12px; padding: 44px 22px; background: rgba(255,255,255,.7); text-align: center; }
.planner-empty h2 { margin: 0 0 8px; font-size: 21px; }.planner-empty p { margin: 0 0 20px; color: var(--muted); }
.planner-task-fields { display: grid; gap: 14px; }.planner-task-fields textarea { box-sizing: border-box; width: 100%; border: 1px solid var(--line-strong); border-radius: 7px; padding: 9px 10px; resize: vertical; font: inherit; }.planner-task-fields small { align-self: end; color: var(--muted); font-size: 11px; }
.planner-task-fields .user-field { display: grid; gap: 6px; }.planner-task-fields .user-field > span, .planner-task-fields .user-field > label { font-size: 13px; font-weight: 650; }.planner-task-fields .user-field small { text-align: right; }
.planner-date-field { display: flex; align-items: stretch; gap: 6px; min-width: 0; }
.planner-date-field > input { flex: 1; min-width: 0; }
.planner-date-trigger { position: relative; display: grid; place-items: center; flex: 0 0 44px; min-height: 44px; border: 1px solid var(--line-strong); border-radius: 7px; background: #fff; color: #526059; overflow: hidden; }
.planner-date-trigger:hover { background: #f0f3f1; color: var(--ink); }
.planner-date-trigger:focus-within { outline: 2px solid #718b7c; outline-offset: 2px; }
.planner-date-trigger svg { width: 21px; height: 21px; pointer-events: none; }
/* Keep a real, focusable date input over the icon for native mobile pickers. */
.planner-date-trigger input[type="date"] { position: absolute; inset: 0; width: 100%; height: 100%; padding: 0; border: 0; opacity: 0; cursor: pointer; font-size: 16px; }
.planner-date-trigger input[type="date"]::-webkit-calendar-picker-indicator { position: absolute; inset: 0; width: 100%; height: 100%; margin: 0; padding: 0; cursor: pointer; }
.planner-note-preview { border: 1px solid #cbd9e5; border-radius: 7px; padding: 10px 12px; background: #f5f9fd; color: var(--muted); font-size: 12px; }.planner-note-preview strong { display: block; margin-bottom: 6px; color: var(--ink); }.planner-note-preview a { display: block; overflow-wrap: anywhere; color: #225f99; }
.planner-task-actions { align-items: center; justify-content: space-between; }.planner-task-actions > div { display: flex; gap: 8px; margin-left: auto; }.planner-delete-button { border-color: #d5b5b5; background: #fff5f5; color: var(--danger); }
#home-view .planner-home-secondary { margin-top: 3px; color: #7a8791; font-size: 14px; }.card-planner.has-overdue .planner-home-secondary { color: var(--danger) !important; font-weight: 700; }

@media (max-width: 760px) {
  .planner-view { width: calc(100% - 24px); padding-top: 20px; }
  .planner-heading { align-items: center; gap: 12px; }.planner-heading .eyebrow { display: none; }.planner-heading h1 { font-size: 25px; }.planner-heading .button { padding-inline: 11px; }
  .planner-summary { gap: 7px; }.planner-metric { min-height: 68px; flex-direction: column; align-items: center; gap: 3px; padding: 10px 5px; }.planner-metric strong { font-size: 25px; }.planner-metric span { font-size: 11px; }
  .planner-filters { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; }.planner-filter-buttons { display: none; }.planner-filters select { display: block; min-width: 0; }
  .planner-groups { gap: 18px; }.planner-row { grid-template-columns: 34px minmax(0, 1fr) 34px 30px; grid-template-areas: "check title note action" "check status date date"; gap: 3px 7px; padding: 7px 8px; }.planner-checkbox { grid-area: check; }.planner-task-title { grid-area: title; }.planner-deadline-badge { grid-area: status; justify-self: start; }.planner-deadline-date { grid-area: date; font-size: 11px; }.planner-note-indicator { grid-area: note; }.planner-row-action { grid-area: action; }
}
@media (max-width: 420px) {
  .planner-heading .button { min-height: 36px; font-size: 13px; }.planner-filters fieldset { padding: 8px; }.planner-filters legend { font-size: 10px; }.planner-filters select { height: 38px; padding-left: 9px; font-size: 13px; }
  .planner-task-actions { align-items: stretch; flex-direction: column-reverse; }.planner-task-actions > div { width: 100%; margin: 0; }.planner-task-actions > div .button { flex: 1; }.planner-delete-button { width: 100%; }
}
