:root {
  --bg: #f3efe5;
  --panel: rgba(255, 252, 246, 0.88);
  --panel-border: rgba(80, 66, 38, 0.12);
  --text: #1f1c16;
  --muted: #665d4f;
  --accent: #0d6b5d;
  --accent-strong: #08483f;
  --secondary: #e6dbc1;
  --shadow: 0 20px 45px rgba(50, 35, 18, 0.12);
  --page-gutter: clamp(0.75rem, 1.5vw, 1.5rem);
  --site-width: 1440px;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  font-family: "Segoe UI", Tahoma, Geneva, Verdana, sans-serif;
  color: var(--text);
  background:
    radial-gradient(circle at top left, rgba(255, 255, 255, 0.75), transparent 30%),
    linear-gradient(135deg, #efe4ce, #f5f1e7 55%, #ddebe4);
  min-height: 100vh;
}

.global-toolbar {
  position: sticky;
  top: 0;
  z-index: 20;
  padding: var(--page-gutter) var(--page-gutter) 0;
}

.connection-toolbar {
  position: relative;
  z-index: 10;
  padding: 0.7rem var(--page-gutter) 0;
}

.connection-toolbar[hidden] {
  display: none;
}

.toolbar-inner {
  width: 100%;
  max-width: var(--site-width);
  margin: 0 auto;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
  padding: 0.9rem 1.1rem;
  background: rgba(255, 252, 246, 0.8);
  border: 1px solid rgba(80, 66, 38, 0.12);
  border-radius: 18px;
  box-shadow: 0 10px 30px rgba(50, 35, 18, 0.08);
  backdrop-filter: blur(14px);
}

.connection-inner {
  background: rgba(232, 244, 239, 0.82);
}

.toolbar-brand {
  color: var(--text);
  text-decoration: none;
  font-weight: 700;
  letter-spacing: 0.04em;
}

.toolbar-nav {
  display: flex;
  gap: 0.5rem;
  flex-wrap: wrap;
}

.toolbar-auth {
  display: flex;
  gap: 0.65rem;
  align-items: center;
  flex-wrap: wrap;
}

.toolbar-actions {
  display: flex;
  gap: 0.75rem;
  align-items: center;
  flex-wrap: wrap;
}

.toolbar-link {
  color: var(--text);
  text-decoration: none;
  padding: 0.55rem 0.8rem;
  border-radius: 999px;
  transition: background 0.15s ease, transform 0.15s ease;
}

.toolbar-link:hover {
  background: rgba(13, 107, 93, 0.1);
  transform: translateY(-1px);
}

.toolbar-link.is-active {
  background: var(--accent);
  color: white;
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.14);
}

.toolbar-link.is-active:hover {
  background: var(--accent-strong);
}

.toolbar-user {
  color: var(--muted);
  font-size: 0.92rem;
}

.service-status-icon {
  width: 2rem;
  height: 2rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  box-shadow: inset 0 0 0 1px rgba(31, 28, 22, 0.08);
  flex: 0 0 auto;
}

.service-status-icon svg {
  width: 100%;
  height: 100%;
  display: block;
}

.service-status-icon circle {
  transition: fill 0.15s ease;
}

.service-status-icon text {
  font-family: "Segoe UI", Tahoma, Geneva, Verdana, sans-serif;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.03em;
  fill: #ffffff;
  text-transform: lowercase;
}

.service-status-icon.is-connected circle {
  fill: #9ad9ac;
}

.service-status-icon.is-disconnected circle {
  fill: #f3a8a8;
}

.toolbar-button {
  padding: 0.7rem 1rem;
}

.connection-copy {
  display: flex;
  flex-direction: column;
  gap: 0.2rem;
}

.connection-label {
  font-size: 0.78rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--accent);
  font-weight: 700;
}

.connection-detail {
  color: var(--muted);
  font-size: 0.94rem;
}

.page-shell {
  width: 100%;
  max-width: var(--site-width);
  margin: 0 auto;
  padding: 2rem var(--page-gutter) 3rem;
}


.hero-home {
  min-height: 60vh;
  align-items: center;
}

.hero,
.panel {
  background: var(--panel);
  border: 1px solid var(--panel-border);
  border-radius: 24px;
  box-shadow: var(--shadow);
  backdrop-filter: blur(14px);
}

.hero {
  display: grid;
  grid-template-columns: 1.4fr 1fr;
  gap: 1.5rem;
  padding: 2rem;
  margin-bottom: 1.5rem;
}

.hero-copy h1,
.panel h2 {
  margin: 0;
}

.eyebrow,
.section-label {
  margin: 0 0 0.5rem;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  font-size: 0.78rem;
  color: var(--accent);
  font-weight: 700;
}

.lede {
  max-width: 62ch;
  color: var(--muted);
  line-height: 1.6;
}

.hero-actions {
  display: flex;
  gap: 1rem;
  align-items: center;
  margin-top: 1.5rem;
}

.primary-button,
.secondary-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.55rem;
  border: none;
  border-radius: 999px;
  padding: 0.85rem 1.25rem;
  font-size: 0.98rem;
  cursor: pointer;
  text-decoration: none;
  transition: transform 0.15s ease, opacity 0.15s ease, background 0.15s ease;
}

.primary-button {
  background: var(--accent);
  color: white;
}

.secondary-button {
  background: var(--secondary);
  color: var(--text);
}

.primary-button:hover,
.secondary-button:hover {
  transform: translateY(-1px);
}

.primary-button:disabled,
.secondary-button:disabled {
  opacity: 0.55;
  cursor: not-allowed;
  transform: none;
}

.primary-button.is-loading::before,
.secondary-button.is-loading::before {
  content: "";
  width: 0.95em;
  height: 0.95em;
  border: 2px solid currentColor;
  border-right-color: transparent;
  border-radius: 50%;
  animation: button-spinner 0.7s linear infinite;
}

@keyframes button-spinner {
  to {
    transform: rotate(360deg);
  }
}

.status-badge {
  display: inline-flex;
  padding: 0.45rem 0.75rem;
  border-radius: 999px;
  background: rgba(13, 107, 93, 0.1);
  color: var(--accent-strong);
  font-weight: 600;
}

.hero-card {
  border-radius: 20px;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.95), rgba(248, 241, 228, 0.88));
  padding: 1.5rem;
  border: 1px solid rgba(80, 66, 38, 0.08);
}

.hero-card ol {
  margin: 1rem 0 0;
  padding-left: 1.1rem;
  color: var(--muted);
  line-height: 1.7;
}

.panel {
  padding: 1.5rem;
  margin-bottom: 1.25rem;
}

.invoice-workspace {
  display: block;
}

.invoice-tabs {
  margin-bottom: 1.25rem;
}

.invoice-tab-panel {
  margin-bottom: 0;
}

.subpanel {
  padding: 1.25rem 0;
  border-top: 1px solid rgba(80, 66, 38, 0.1);
}

.subpanel:first-child {
  padding-top: 0;
  border-top: none;
}

.subpanel:last-child {
  padding-bottom: 0;
}

.panel-heading {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  align-items: end;
  margin-bottom: 1rem;
}

.muted {
  color: var(--muted);
}

.grid-form {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1rem;
}

.grid-form label {
  display: flex;
  flex-direction: column;
  gap: 0.45rem;
  font-weight: 600;
}

.grid-form input {
  border: 1px solid rgba(80, 66, 38, 0.16);
  border-radius: 14px;
  padding: 0.8rem 0.95rem;
  font-size: 0.98rem;
  background: rgba(255, 255, 255, 0.78);
}

.grid-form select {
  border: 1px solid rgba(80, 66, 38, 0.16);
  border-radius: 14px;
  padding: 0.65rem 0.75rem;
  font-size: 0.98rem;
  background: rgba(255, 255, 255, 0.78);
  min-height: 13rem;
}

.grid-form select:not([multiple]) {
  min-height: auto;
  height: 3rem;
}

.customer-activity-controls {
  grid-template-columns: minmax(12rem, 1fr) minmax(14rem, 2fr) auto;
  align-items: end;
}

.unsent-invoice-controls {
  grid-template-columns: minmax(9rem, 0.8fr) minmax(9rem, 0.8fr) minmax(16rem, 2fr) minmax(12rem, 1fr) auto;
  align-items: end;
}

.table-sort-button {
  appearance: none;
  border: 0;
  padding: 0;
  background: transparent;
  color: inherit;
  font: inherit;
  font-weight: inherit;
  cursor: pointer;
  text-align: left;
  white-space: nowrap;
}

.table-sort-button:hover,
.table-sort-button:focus-visible {
  color: var(--accent-strong);
  text-decoration: underline;
}

.table-sort-button span {
  display: inline-block;
  min-width: 0.8rem;
  margin-left: 0.25rem;
  font-size: 0.7em;
}

.field-help {
  color: var(--muted);
  font-size: 0.88rem;
  font-weight: 500;
}

.status-good {
  color: var(--accent-strong);
  font-weight: 700;
}

.status-bad {
  color: #8f2b2b;
  font-weight: 700;
}

.nexus-status-button {
  border: 0;
  padding: 0;
  background: transparent;
  color: var(--text);
  font: inherit;
  font-weight: 700;
  text-decoration: underline;
  text-decoration-style: dotted;
  text-underline-offset: 0.2rem;
  cursor: pointer;
}

.nexus-status-button:hover,
.nexus-status-button:focus-visible {
  color: var(--accent-strong);
}

.nexus-status-button.status-bad {
  color: #8f2b2b;
}

.nexus-status-button.status-good {
  color: var(--accent-strong);
}

.report-dialog {
  width: min(44rem, calc(100vw - 2rem));
  max-height: calc(100vh - 2rem);
  border: 1px solid rgba(80, 66, 38, 0.18);
  border-radius: 16px;
  padding: 1.25rem;
  color: var(--text);
  background: #fffdf8;
  box-shadow: 0 24px 80px rgba(35, 29, 18, 0.28);
}

.report-dialog::backdrop {
  background: rgba(28, 24, 17, 0.58);
}

.report-dialog__header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 1rem;
}

.report-dialog__header h2 {
  margin: 0;
}

.report-dialog__body {
  margin-top: 1.25rem;
}

.rule-detail-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.8rem;
}

.rule-detail-grid > div {
  padding: 0.8rem;
  border-radius: 10px;
  background: rgba(247, 243, 234, 0.8);
}

.rule-detail-grid span,
.rule-detail-grid strong {
  display: block;
}

.rule-comparison-list {
  padding-left: 1.25rem;
}

.gl-severity {
  display: inline-flex;
  padding: 0.25rem 0.5rem;
  border-radius: 999px;
  font-size: 0.78rem;
  font-weight: 800;
  text-transform: uppercase;
}

.gl-severity--high {
  color: #7c2020;
  background: #f7dddd;
}

.gl-severity--medium {
  color: #72520d;
  background: #f7eccb;
}

.gl-issue-details {
  margin-top: 1.25rem;
}

#issuesTableBody small {
  display: block;
  margin-top: 0.2rem;
  color: var(--muted);
}

#salesTaxItemTableBody small {
  display: block;
  margin-top: 0.2rem;
  color: var(--muted);
}

.field-span-2 {
  grid-column: span 2;
}

.admin-switcher,
.admin-shared-settings {
  margin-bottom: 1.25rem;
}

.admin-subtitle {
  margin: 0;
}

.env-toggle {
  display: inline-flex;
  align-items: center;
  gap: 0.85rem;
  padding: 0.8rem 1rem;
  border: 1px solid rgba(80, 66, 38, 0.12);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.72);
  font-weight: 600;
}

.env-toggle input {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

.env-slider {
  position: relative;
  width: 3.5rem;
  height: 2rem;
  border-radius: 999px;
  background: rgba(13, 107, 93, 0.18);
  transition: background 0.15s ease;
}

.env-slider::after {
  content: "";
  position: absolute;
  top: 0.2rem;
  left: 0.2rem;
  width: 1.6rem;
  height: 1.6rem;
  border-radius: 50%;
  background: white;
  box-shadow: 0 4px 12px rgba(31, 28, 22, 0.16);
  transition: transform 0.15s ease;
}

.env-toggle input:checked + .env-slider {
  background: rgba(13, 107, 93, 0.42);
}

.env-toggle input:checked + .env-slider::after {
  transform: translateX(1.5rem);
}

.settings-tabs {
  display: flex;
  gap: 0.75rem;
  flex-wrap: wrap;
  margin-bottom: 1rem;
}

.settings-tab {
  border: 1px solid rgba(80, 66, 38, 0.12);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.72);
  color: var(--text);
  padding: 0.75rem 1rem;
  font-size: 0.95rem;
  cursor: pointer;
}

.settings-tab.is-active {
  background: rgba(13, 107, 93, 0.12);
  border-color: rgba(13, 107, 93, 0.28);
  color: var(--accent-strong);
}

.tab-panel {
  display: none;
  margin-bottom: 1.25rem;
}

.tab-panel.is-active {
  display: block;
}

.form-actions {
  display: flex;
  gap: 0.75rem;
  align-items: end;
}

.table-controls {
  margin-bottom: 1rem;
}

.status-highlight {
  display: inline-block;
  padding: 0.35rem 0.7rem;
  border-radius: 999px;
  color: var(--accent-strong);
  background: rgba(13, 107, 93, 0.12);
  box-shadow: 0 0 0 0 rgba(13, 107, 93, 0.26);
  animation: statusPulse 1.4s ease-in-out infinite;
}

@keyframes statusPulse {
  0%,
  100% {
    transform: translateY(0);
    box-shadow: 0 0 0 0 rgba(13, 107, 93, 0.18);
    background: rgba(13, 107, 93, 0.1);
  }

  50% {
    transform: translateY(-1px);
    box-shadow: 0 0 0 12px rgba(13, 107, 93, 0);
    background: rgba(13, 107, 93, 0.2);
  }
}

.table-wrap {
  overflow-x: auto;
}

.table-input {
  width: 100%;
  min-width: 6rem;
  border: 1px solid rgba(80, 66, 38, 0.16);
  border-radius: 8px;
  padding: 0.45rem 0.55rem;
  background: rgba(255, 255, 255, 0.82);
  color: var(--text);
  font: inherit;
}

.time-description-input {
  min-width: 18rem;
}

.time-hours-input {
  max-width: 7rem;
}

.table-checkbox {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  white-space: nowrap;
  font-weight: 600;
  color: var(--muted);
}

.table-checkbox input {
  margin: 0;
}

.invoice-loading-row td {
  padding: 0;
}

.invoice-loading-panel {
  display: grid;
  gap: 1rem;
  padding: 1.25rem;
  background: linear-gradient(135deg, rgba(232, 244, 239, 0.92), rgba(255, 252, 246, 0.92));
  border: 1px solid rgba(13, 107, 93, 0.14);
}

.invoice-loading-header {
  display: flex;
  gap: 0.85rem;
  align-items: center;
}

.invoice-loading-header strong {
  display: block;
  color: var(--accent-strong);
}

.invoice-loading-header small {
  display: block;
  margin-top: 0.2rem;
  color: var(--muted);
}

.invoice-loading-spinner {
  width: 2.25rem;
  height: 2.25rem;
  border: 3px solid rgba(13, 107, 93, 0.18);
  border-top-color: var(--accent);
  border-radius: 50%;
  animation: button-spinner 0.8s linear infinite;
  flex: 0 0 auto;
}

.invoice-loading-skeleton {
  display: grid;
  grid-template-columns: 0.7fr 1.3fr 1fr 0.9fr;
  gap: 0.65rem;
}

.invoice-loading-skeleton span {
  height: 0.75rem;
  border-radius: 999px;
  background: linear-gradient(90deg, rgba(13, 107, 93, 0.08), rgba(13, 107, 93, 0.22), rgba(13, 107, 93, 0.08));
  background-size: 220% 100%;
  animation: skeletonSweep 1.1s ease-in-out infinite;
}

@keyframes skeletonSweep {
  0% {
    background-position: 120% 0;
  }

  100% {
    background-position: -120% 0;
  }
}

.selection-list {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.75rem;
  margin-top: 1rem;
}

.selection-row {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  gap: 0.75rem;
  align-items: start;
  padding: 0.85rem;
  border: 1px solid rgba(80, 66, 38, 0.12);
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.64);
}

.selection-row input {
  margin-top: 0.2rem;
}

.selection-row span {
  min-width: 0;
}

.selection-row small {
  display: block;
  margin-top: 0.25rem;
  color: var(--muted);
  line-height: 1.4;
}

.invoice-display {
  min-height: 220px;
}

.invoice-paper {
  background: rgba(255, 255, 255, 0.78);
  border: 1px solid rgba(80, 66, 38, 0.12);
  border-radius: 16px;
  padding: 1.25rem;
}

.invoice-display-header {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  align-items: flex-start;
  margin-bottom: 1.25rem;
}

.invoice-display-header h2 {
  margin: 0 0 0.75rem;
}

.invoice-total-block {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
  align-items: flex-end;
  color: var(--muted);
}

.invoice-total-block strong {
  color: var(--text);
  font-size: 2rem;
  line-height: 1;
}

.invoice-meta-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 0.75rem;
  margin-bottom: 1.25rem;
}

.invoice-meta-card {
  display: flex;
  flex-direction: column;
  gap: 0.3rem;
  padding: 0.85rem;
  border: 1px solid rgba(80, 66, 38, 0.1);
  border-radius: 12px;
  background: rgba(255, 252, 246, 0.72);
}

.invoice-meta-card span {
  color: var(--muted);
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.invoice-meta-card strong {
  font-size: 0.94rem;
  line-height: 1.35;
}

.invoice-totals {
  width: min(360px, 100%);
  margin: 1rem 0 0 auto;
  display: flex;
  flex-direction: column;
  gap: 0.45rem;
}

.invoice-totals div {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  padding-top: 0.45rem;
  border-top: 1px solid rgba(80, 66, 38, 0.1);
}

.invoice-totals span {
  color: var(--muted);
}

.table-toggle {
  padding: 0.45rem 0.75rem;
  font-size: 0.86rem;
}

.deposit-group-row td {
  background: rgba(13, 107, 93, 0.08);
  border-top: 1px solid rgba(13, 107, 93, 0.16);
}

.deposit-group-summary {
  display: flex;
  gap: 1rem;
  align-items: center;
  flex-wrap: wrap;
}

.deposit-group-summary strong {
  color: var(--accent-strong);
}

.deposit-group-summary span {
  color: var(--muted);
  font-weight: 600;
}

.client-group-row td {
  background: rgba(13, 107, 93, 0.08);
  border-top: 1px solid rgba(13, 107, 93, 0.16);
}

.client-group-summary {
  display: flex;
  gap: 1rem;
  align-items: center;
  flex-wrap: wrap;
}

.client-group-summary strong {
  color: var(--accent-strong);
}

.client-group-summary span {
  color: var(--muted);
  font-weight: 600;
}

.send-invoice-form {
  margin-bottom: 1rem;
}

.deposit-group-total {
  color: var(--accent-strong);
  font-weight: 700;
  text-align: right;
  white-space: nowrap;
}

.detail-row td {
  background: rgba(255, 255, 255, 0.46);
}

.payment-detail {
  display: flex;
  flex-direction: column;
  gap: 1rem;
  padding: 0.5rem 0;
}

.payment-detail-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 0.75rem;
}

.payment-detail-section h3 {
  margin: 0 0 0.75rem;
}

.detail-chip-list {
  display: flex;
  gap: 0.5rem;
  flex-wrap: wrap;
}

.detail-chip {
  display: inline-flex;
  padding: 0.45rem 0.65rem;
  border-radius: 999px;
  background: rgba(13, 107, 93, 0.1);
  color: var(--accent-strong);
  font-weight: 600;
}

.docs-answer {
  display: flex;
  flex-direction: column;
  gap: 1rem;
  align-items: flex-start;
  line-height: 1.6;
}

.docs-answer p {
  margin: 0;
}

.docs-solution {
  display: grid;
  gap: 0.75rem;
}

.docs-solution h3 {
  margin: 0.25rem 0 0;
  font-size: 1rem;
}

.docs-solution ul {
  margin: 0;
  padding-left: 1.25rem;
}

.docs-solution li + li {
  margin-top: 0.35rem;
}

.docs-results {
  display: grid;
  gap: 0.85rem;
}

.docs-result-card {
  padding: 1rem;
  border: 1px solid rgba(80, 66, 38, 0.1);
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.64);
}

.docs-result-card h3 {
  margin: 0 0 0.5rem;
}

.docs-result-card a {
  color: var(--accent-strong);
}

.docs-result-card p {
  margin: 0 0 0.75rem;
  color: var(--muted);
  line-height: 1.55;
}

table {
  width: 100%;
  border-collapse: collapse;
}

th,
td {
  text-align: left;
  padding: 0.85rem 0.65rem;
  border-bottom: 1px solid rgba(80, 66, 38, 0.1);
}

thead th {
  font-size: 0.84rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--muted);
}

.empty-state {
  text-align: center;
  color: var(--muted);
  padding: 1.5rem 0.5rem;
}

.log-box {
  margin: 0;
  padding: 1rem;
  border-radius: 16px;
  background: #1f261f;
  color: #d3f8dd;
  min-height: 140px;
  overflow: auto;
}

.dashboard-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1rem;
}

.dashboard-grid--stats {
  align-items: stretch;
}

.dashboard-filter-form {
  display: flex;
  align-items: end;
  flex-wrap: wrap;
  gap: 0.75rem;
}

.dashboard-filter-form label {
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
  color: var(--muted);
  font-size: 0.82rem;
  font-weight: 700;
}

.dashboard-filter-form input {
  border: 1px solid rgba(80, 66, 38, 0.16);
  border-radius: 14px;
  padding: 0.72rem 0.85rem;
  font-size: 0.95rem;
  background: rgba(255, 255, 255, 0.78);
  min-width: 9.75rem;
}

.dashboard-status {
  margin: -0.25rem 0 1rem;
}

.dashboard-card {
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.95), rgba(246, 240, 228, 0.9));
  border: 1px solid rgba(80, 66, 38, 0.08);
  border-radius: 18px;
  padding: 1.25rem;
  min-height: 200px;
  display: flex;
  flex-direction: column;
  gap: 0.9rem;
}

.dashboard-card--wide {
  grid-column: span 2;
}

.dashboard-card--tall {
  grid-row: span 2;
}

.dashboard-card h3 {
  margin: 0 0 0.65rem;
}

.dashboard-copy {
  color: var(--muted);
  line-height: 1.6;
}

.dashboard-metric {
  display: flex;
  flex-direction: column;
  gap: 0.15rem;
}

.metric-value {
  font-size: 2.5rem;
  font-weight: 700;
  line-height: 1;
}

.metric-label {
  color: var(--muted);
  font-size: 0.92rem;
}

.metric-row {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  align-items: center;
  border-top: 1px solid rgba(80, 66, 38, 0.08);
  padding-top: 0.75rem;
}

.bar-chart {
  display: flex;
  flex-direction: column;
  gap: 0.8rem;
}

.bar-row {
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
}

.bar-meta,
.bar-caption {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
}

.bar-caption {
  color: var(--muted);
  font-size: 0.88rem;
}

.bar-track {
  width: 100%;
  height: 12px;
  border-radius: 999px;
  background: rgba(13, 107, 93, 0.12);
  overflow: hidden;
}

.bar-fill {
  height: 100%;
  border-radius: 999px;
  background: linear-gradient(90deg, #0d6b5d, #2fa38d);
}

.daily-receipts-list {
  display: grid;
  gap: 0.45rem;
  max-height: 360px;
  overflow: auto;
  padding-right: 0.25rem;
}

.receipt-day-row {
  display: grid;
  grid-template-columns: minmax(5.75rem, 0.8fr) minmax(8rem, 1.5fr) minmax(5.75rem, auto) minmax(4.5rem, auto);
  gap: 0.75rem;
  align-items: center;
  width: 100%;
  border: 1px solid rgba(80, 66, 38, 0.1);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.62);
  color: var(--text);
  padding: 0.55rem 0.65rem;
  font: inherit;
  text-align: left;
  cursor: pointer;
}

.receipt-day-row:hover,
.receipt-day-row.is-active {
  border-color: rgba(13, 107, 93, 0.34);
  background: rgba(13, 107, 93, 0.1);
}

.receipt-day-date {
  font-weight: 700;
}

.receipt-day-track {
  height: 10px;
  border-radius: 999px;
  background: rgba(13, 107, 93, 0.12);
  overflow: hidden;
}

.receipt-day-fill {
  display: block;
  height: 100%;
  border-radius: 999px;
  background: linear-gradient(90deg, #0d6b5d, #2fa38d);
}

.receipt-day-row small {
  color: var(--muted);
  text-align: right;
}

.receipt-drilldown {
  display: grid;
  gap: 0.75rem;
  border-top: 1px solid rgba(80, 66, 38, 0.1);
  padding-top: 0.9rem;
}

.receipt-drilldown-heading {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  align-items: baseline;
  flex-wrap: wrap;
}

.receipt-drilldown-heading h4 {
  margin: 0;
}

.receipt-list {
  display: grid;
  gap: 0.55rem;
}

.receipt-row {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  padding: 0.7rem 0;
  border-top: 1px solid rgba(80, 66, 38, 0.08);
}

.receipt-row:first-child {
  border-top: none;
}

.receipt-row span,
.receipt-row small {
  display: block;
  color: var(--muted);
  margin-top: 0.2rem;
}

.comparison-grid {
  display: grid;
  grid-template-columns: 1.3fr 1fr 1fr 1fr;
  gap: 0.65rem 1rem;
  align-items: center;
}

.comparison-header {
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--muted);
  font-weight: 700;
}

.report-table-wrap {
  margin-top: 1.25rem;
}

.line-chart {
  width: 100%;
  min-height: 320px;
  overflow-x: auto;
}

.line-chart svg {
  display: block;
  width: 100%;
  min-width: 720px;
  height: auto;
}

.dashboard-revenue-line-chart {
  min-height: 240px;
}

.dashboard-revenue-line-chart svg {
  min-width: 620px;
}

.dashboard-revenue-line {
  fill: none;
  stroke: #0d6b5d;
  stroke-width: 4;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.dashboard-revenue-point {
  fill: #ffffff;
  stroke: #0d6b5d;
  stroke-width: 4;
}

.chart-grid-line {
  stroke: rgba(80, 66, 38, 0.14);
  stroke-width: 1;
}

.chart-axis-label {
  fill: var(--muted);
  font-size: 13px;
}

.line-chart-legend {
  display: flex;
  justify-content: flex-end;
  gap: 0.65rem 1rem;
  flex-wrap: wrap;
}

.line-chart-legend span {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  color: var(--muted);
  font-size: 0.9rem;
  font-weight: 700;
}

.line-chart-legend i {
  width: 1.5rem;
  height: 3px;
  border-radius: 999px;
}

@media (max-width: 840px) {
  .toolbar-inner {
    flex-direction: column;
    align-items: stretch;
  }

  .toolbar-nav {
    justify-content: center;
  }

  .toolbar-actions {
    justify-content: center;
  }

  .toolbar-auth {
    justify-content: center;
  }

  .hero {
    grid-template-columns: 1fr;
  }

  .panel-heading,
  .grid-form {
    grid-template-columns: 1fr;
    display: grid;
  }

  .form-actions,
  .hero-actions {
    flex-direction: column;
    align-items: stretch;
  }

  .dashboard-grid {
    grid-template-columns: 1fr;
  }

  .selection-list {
    grid-template-columns: 1fr;
  }

  .invoice-display-header {
    flex-direction: column;
  }

  .invoice-total-block {
    align-items: flex-start;
  }

  .invoice-meta-grid {
    grid-template-columns: 1fr;
  }

  .payment-detail-grid {
    grid-template-columns: 1fr;
  }

  .dashboard-card--wide {
    grid-column: span 1;
  }

  .comparison-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}
