:root {
  --paper: #f1eee5;
  --paper-deep: #e7e2d6;
  --ink: #0a0a0a;
  --muted: #69675f;
  --blue: #2450ff;
  --blue-dark: #173bd1;
  --white: #ffffff;
  --success: #0c7655;
  --warning: #c95c26;
  --danger: #bb2f27;
  --line: rgba(10, 10, 10, 0.2);
  --font: "Archivo", "Arial Narrow", Arial, sans-serif;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  min-width: 320px;
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--font);
  font-size: 15px;
  line-height: 1.4;
}

body.drawer-open {
  overflow: hidden;
}

button,
input,
select,
textarea {
  color: inherit;
  font: inherit;
}

button,
a,
input,
select,
textarea {
  -webkit-tap-highlight-color: transparent;
}

button {
  cursor: pointer;
}

a {
  color: inherit;
}

:focus-visible {
  outline: 3px solid var(--blue);
  outline-offset: 3px;
}

.visually-hidden {
  position: absolute !important;
  width: 1px !important;
  height: 1px !important;
  padding: 0 !important;
  margin: -1px !important;
  overflow: hidden !important;
  clip: rect(0, 0, 0, 0) !important;
  white-space: nowrap !important;
  border: 0 !important;
}

.skip-link {
  position: fixed;
  z-index: 100;
  top: 12px;
  left: 12px;
  padding: 10px 14px;
  background: var(--blue);
  color: var(--white);
  transform: translateY(-160%);
}

.skip-link:focus {
  transform: translateY(0);
}

.app-header {
  position: sticky;
  z-index: 30;
  top: 0;
  display: grid;
  grid-template-columns: minmax(220px, 1fr) auto minmax(220px, 1fr);
  align-items: center;
  min-height: 72px;
  padding: 0 clamp(18px, 3vw, 48px);
  border-bottom: 1px solid var(--ink);
  background: rgba(241, 238, 229, 0.95);
  backdrop-filter: blur(14px);
}

.brand {
  display: inline-flex;
  gap: 8px;
  align-items: baseline;
  width: fit-content;
  text-decoration: none;
  letter-spacing: -0.04em;
}

.brand-word {
  font-size: 1.12rem;
  font-stretch: condensed;
  font-weight: 800;
}

.brand-divider {
  color: var(--blue);
  font-weight: 800;
}

.brand-product {
  font-size: 0.76rem;
  font-weight: 650;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.dataset-state {
  display: flex;
  gap: 8px;
  align-items: center;
  max-width: 420px;
  color: var(--muted);
  font-size: 0.72rem;
  font-weight: 650;
  letter-spacing: 0.03em;
  text-align: center;
}

.state-dot {
  width: 7px;
  height: 7px;
  flex: 0 0 auto;
  border-radius: 50%;
  background: var(--warning);
}

.state-dot.is-live {
  background: var(--success);
  box-shadow: 0 0 0 4px rgba(12, 118, 85, 0.12);
}

.header-actions {
  display: flex;
  gap: 20px;
  align-items: center;
  justify-self: end;
}

.test-mode-banner {
  position: sticky;
  z-index: 29;
  top: 72px;
  display: flex;
  gap: 18px;
  align-items: center;
  justify-content: center;
  min-height: 38px;
  padding: 8px 18px;
  background: var(--blue);
  color: var(--white);
  font-size: 0.7rem;
  letter-spacing: 0.04em;
}

.test-mode-banner[hidden] {
  display: none;
}

.test-mode-banner strong {
  font-weight: 800;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.hosted-mode-banner {
  background: var(--ink);
}

.button,
.rule-button,
.page-button {
  border: 0;
  border-radius: 0;
  background: transparent;
}

.button {
  display: inline-flex;
  gap: 24px;
  align-items: center;
  justify-content: space-between;
  min-height: 44px;
  padding: 0 16px;
  font-size: 0.72rem;
  font-weight: 750;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  transition: background 160ms ease, color 160ms ease, transform 160ms ease;
}

.button:hover:not(:disabled) {
  transform: translateY(-2px);
}

.button:disabled,
.rule-button:disabled,
.page-button:disabled {
  cursor: not-allowed;
  opacity: 0.4;
}

.button-ink {
  background: var(--ink);
  color: var(--paper);
}

.button-ink:hover:not(:disabled) {
  background: var(--blue);
}

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

.button-blue:hover:not(:disabled) {
  background: var(--blue-dark);
}

.button-paper {
  border: 1px solid var(--ink);
  background: var(--paper);
}

.rule-button {
  padding: 4px 0;
  border-bottom: 1px solid currentColor;
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.rule-button:hover:not(:disabled) {
  color: var(--blue);
}

#workspace {
  width: min(1600px, 100%);
  margin: 0 auto;
  padding: 0 clamp(18px, 3vw, 48px) clamp(70px, 8vw, 120px);
}

.dashboard-head {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(260px, 0.35fr);
  gap: 40px;
  align-items: end;
  min-height: 205px;
  padding: 34px 0 26px;
  border-bottom: 1px solid var(--ink);
}

.section-index {
  margin: 0 0 20px;
  font-size: 0.67rem;
  font-weight: 720;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.dashboard-head h1 {
  max-width: 850px;
  margin: 0;
  font-size: clamp(2.8rem, 5vw, 5rem);
  font-stretch: condensed;
  font-weight: 760;
  letter-spacing: -0.075em;
  line-height: 0.82;
}

.dashboard-head h1 span {
  color: var(--blue);
}

.dashboard-note {
  max-width: 320px;
  margin: 0 0 8px;
  font-size: clamp(1.05rem, 1.5vw, 1.35rem);
  font-weight: 520;
  letter-spacing: -0.025em;
}

.metrics {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  border-bottom: 1px solid var(--ink);
}

.metrics article {
  min-height: 112px;
  padding: 17px 24px 15px 0;
  border-right: 1px solid var(--ink);
}

.metrics article:not(:first-child) {
  padding-left: 24px;
}

.metrics article:last-child {
  border-right: 0;
}

.metrics .metric-blue {
  padding-right: 24px;
  background: var(--blue);
  color: var(--white);
}

.metric-label,
.metrics small {
  display: block;
}

.metric-label {
  font-size: 0.68rem;
  font-weight: 720;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.metrics strong {
  display: block;
  margin: 7px 0 2px;
  font-size: clamp(2.2rem, 3vw, 3.3rem);
  font-stretch: condensed;
  font-weight: 740;
  letter-spacing: -0.065em;
  line-height: 0.95;
}

.metrics small {
  color: var(--muted);
  font-size: 0.72rem;
}

.metrics .metric-blue small {
  color: rgba(255, 255, 255, 0.72);
}

.insight-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(360px, 0.85fr);
  border-bottom: 1px solid var(--ink);
}

.insight-panel {
  min-width: 0;
  min-height: 330px;
  padding: 28px 30px 30px 0;
  border-right: 1px solid var(--ink);
}

.insight-panel + .insight-panel {
  padding-right: 0;
  padding-left: 30px;
  border-right: 0;
}

.insight-heading {
  display: flex;
  gap: 22px;
  align-items: flex-start;
  justify-content: space-between;
  margin-bottom: 24px;
}

.insight-heading .section-index {
  margin-bottom: 9px;
}

.insight-heading h2 {
  margin: 0;
  font-size: clamp(1.45rem, 2.3vw, 2.5rem);
  font-stretch: condensed;
  font-weight: 720;
  letter-spacing: -0.05em;
  line-height: 0.95;
}

.insight-heading > span {
  color: var(--muted);
  font-size: 0.62rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.sector-chart {
  display: grid;
  gap: 12px;
}

.sector-row {
  display: grid;
  grid-template-columns: minmax(100px, 0.65fr) minmax(120px, 1.35fr) 34px;
  gap: 14px;
  align-items: center;
}

.sector-row strong {
  overflow: hidden;
  font-size: 0.7rem;
  font-weight: 670;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.sector-bar {
  height: 10px;
  background: rgba(10, 10, 10, 0.1);
}

.sector-bar i {
  display: block;
  height: 100%;
  background: var(--blue);
}

.sector-row span {
  font-size: 0.72rem;
  font-weight: 730;
  text-align: right;
}

.status-chart {
  display: grid;
  grid-template-columns: 150px minmax(0, 1fr);
  gap: 26px;
  align-items: center;
}

.status-donut {
  position: relative;
  display: grid;
  width: 150px;
  height: 150px;
  place-items: center;
  border-radius: 50%;
  background: conic-gradient(var(--paper-deep) 0 100%);
}

.status-donut::after {
  position: absolute;
  width: 88px;
  height: 88px;
  border-radius: 50%;
  background: var(--paper);
  content: "";
}

.status-donut > span {
  position: relative;
  z-index: 1;
  text-align: center;
}

.status-donut strong,
.status-donut small {
  display: block;
}

.status-donut strong {
  font-size: 1.75rem;
  font-stretch: condensed;
  font-weight: 740;
  letter-spacing: -0.06em;
}

.status-donut small {
  color: var(--muted);
  font-size: 0.58rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.status-legend {
  display: grid;
  gap: 8px;
}

.legend-row {
  display: grid;
  grid-template-columns: 8px minmax(0, 1fr) auto;
  gap: 9px;
  align-items: center;
  font-size: 0.67rem;
}

.legend-row i {
  width: 8px;
  height: 8px;
}

.legend-row span {
  overflow: hidden;
  color: var(--muted);
  text-overflow: ellipsis;
  white-space: nowrap;
}

.legend-row strong {
  font-weight: 730;
}

.work-panel {
  padding-top: 34px;
}

.panel-top {
  display: grid;
  grid-template-columns: minmax(280px, 0.55fr) minmax(0, 1fr);
  gap: 32px;
  align-items: end;
  padding-bottom: 18px;
}

.panel-top .section-index {
  margin-bottom: 12px;
}

.panel-top h2,
.drawer-header h2,
.send-dialog h2 {
  margin: 0;
  font-stretch: condensed;
  font-weight: 720;
  letter-spacing: -0.055em;
  line-height: 0.95;
}

.panel-top h2 {
  font-size: clamp(2rem, 3vw, 3.2rem);
}

.workflow-tabs {
  display: grid;
  grid-template-columns: repeat(5, minmax(130px, 1fr));
  border: 1px solid var(--ink);
}

.workflow-tab {
  min-height: 52px;
  padding: 0 16px;
  border: 0;
  border-right: 1px solid var(--ink);
  background: transparent;
  font-size: 0.71rem;
  font-weight: 720;
  letter-spacing: 0.05em;
  text-align: left;
  text-transform: uppercase;
}

.workflow-tab:last-child {
  border-right: 0;
}

.workflow-tab span {
  float: right;
  color: var(--muted);
}

.workflow-tab.is-active {
  background: var(--ink);
  color: var(--paper);
}

.workflow-tab.is-active span {
  color: var(--paper);
}

.filters {
  display: grid;
  grid-template-columns: minmax(280px, 1.45fr) repeat(3, minmax(150px, 0.7fr)) auto;
  border-top: 1px solid var(--ink);
  border-bottom: 1px solid var(--ink);
}

.filters label {
  position: relative;
  border-right: 1px solid var(--line);
}

.filters input,
.filters select,
.pagination select {
  width: 100%;
  min-height: 50px;
  padding: 0 38px 0 13px;
  border: 0;
  border-radius: 0;
  background: transparent;
  font-size: 0.77rem;
  font-weight: 600;
  outline: 0;
}

.filters input:focus,
.filters select:focus {
  background: var(--white);
}

.search-field > span:last-child {
  position: absolute;
  top: 50%;
  right: 15px;
  color: var(--blue);
  font-size: 1.3rem;
  transform: translateY(-54%);
}

.filters > .rule-button {
  align-self: center;
  margin: 0 14px;
}

.result-line {
  display: flex;
  justify-content: space-between;
  padding: 13px 0;
  color: var(--muted);
  font-size: 0.68rem;
  font-weight: 670;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.empty-state {
  display: grid;
  place-items: center;
  min-height: 310px;
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  text-align: center;
}

.empty-state[hidden] {
  display: none;
}

.empty-state strong {
  display: block;
  font-size: 1.3rem;
}

.empty-state p {
  margin: 6px 0 0;
  color: var(--muted);
}

.table-shell {
  border-top: 1px solid var(--ink);
  border-bottom: 1px solid var(--ink);
}

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

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

th,
td {
  padding: 15px 14px;
  border-right: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  text-align: left;
  vertical-align: middle;
}

th:last-child,
td:last-child {
  border-right: 0;
}

thead th {
  padding-top: 10px;
  padding-bottom: 10px;
  color: var(--muted);
  font-size: 0.63rem;
  font-weight: 720;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

tbody tr {
  transition: background 140ms ease;
}

tbody tr:hover {
  background: var(--white);
}

tbody td:nth-child(1) {
  width: 30%;
}

tbody td:nth-child(2) {
  width: 21%;
}

tbody td:nth-child(3) {
  width: 24%;
}

tbody td:nth-child(4) {
  width: 10%;
}

tbody td:nth-child(5) {
  width: 15%;
}

.company-cell strong,
.company-cell small,
.contact-cell span,
.contact-cell a {
  display: block;
}

.company-cell strong {
  overflow: hidden;
  font-size: 0.92rem;
  font-weight: 690;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.company-cell small,
.contact-cell span,
.contact-cell a {
  margin-top: 3px;
  color: var(--muted);
  font-size: 0.71rem;
}

.contact-cell a {
  width: fit-content;
  text-underline-offset: 3px;
}

.contact-cell .missing {
  color: var(--warning);
}

.finding-cell p {
  display: -webkit-box;
  max-width: 430px;
  margin: 6px 0 0;
  overflow: hidden;
  color: var(--muted);
  font-size: 0.71rem;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}

.status-pill {
  display: inline-flex;
  align-items: center;
  padding: 4px 7px;
  border: 1px solid currentColor;
  font-size: 0.61rem;
  font-weight: 730;
  letter-spacing: 0.08em;
  line-height: 1;
  text-transform: uppercase;
}

.status-none,
.status-unreachable {
  color: var(--danger);
}

.status-old,
.status-weak {
  color: var(--warning);
}

.status-mid {
  color: #8b6710;
}

.status-solid {
  color: var(--success);
}

.opportunity {
  display: flex;
  gap: 10px;
  align-items: center;
}

.opportunity strong {
  min-width: 28px;
  font-size: 1.05rem;
}

.score-track {
  width: 54px;
  height: 4px;
  background: rgba(10, 10, 10, 0.12);
}

.score-track i {
  display: block;
  height: 100%;
  background: var(--blue);
}

.row-actions {
  display: flex;
  gap: 14px;
  align-items: center;
}

.row-action {
  padding: 0 0 3px;
  border: 0;
  border-bottom: 1px solid currentColor;
  background: transparent;
  font-size: 0.67rem;
  font-weight: 720;
  letter-spacing: 0.05em;
  text-transform: uppercase;
}

.row-action.primary {
  color: var(--blue);
}

.row-action:hover {
  color: var(--blue);
}

.pagination {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 58px;
  padding: 0 14px;
  color: var(--muted);
  font-size: 0.7rem;
  font-weight: 650;
}

.pagination > div {
  display: flex;
  gap: 14px;
  align-items: center;
}

.pagination select {
  min-height: 36px;
  padding: 0 24px 0 8px;
}

.page-button {
  width: 34px;
  height: 34px;
  border: 1px solid var(--ink);
}

.page-button:hover:not(:disabled) {
  background: var(--ink);
  color: var(--paper);
}

.site-footer {
  display: grid;
  grid-template-columns: 1fr auto auto;
  gap: 42px;
  align-items: end;
  min-height: 150px;
  padding: 36px clamp(18px, 3vw, 48px);
  background: var(--ink);
  color: var(--paper);
  font-size: 0.72rem;
}

.site-footer strong,
.site-footer span {
  display: block;
}

.site-footer span {
  margin-top: 4px;
  color: rgba(241, 238, 229, 0.55);
}

.site-footer a {
  text-underline-offset: 4px;
}

.detail-drawer {
  position: fixed;
  z-index: 60;
  inset: 0;
  visibility: hidden;
  pointer-events: none;
}

.detail-drawer.is-open {
  visibility: visible;
  pointer-events: auto;
}

.drawer-backdrop {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  border: 0;
  background: rgba(10, 10, 10, 0.62);
  opacity: 0;
  transition: opacity 180ms ease;
}

.detail-drawer.is-open .drawer-backdrop {
  opacity: 1;
}

.drawer-panel {
  position: absolute;
  top: 0;
  right: 0;
  display: flex;
  width: min(720px, 100%);
  height: 100%;
  flex-direction: column;
  background: var(--paper);
  box-shadow: -24px 0 80px rgba(0, 0, 0, 0.25);
  transform: translateX(100%);
  transition: transform 240ms ease;
}

.detail-drawer.is-open .drawer-panel {
  transform: translateX(0);
}

.drawer-header {
  display: flex;
  justify-content: space-between;
  padding: 30px 34px 24px;
  border-bottom: 1px solid var(--ink);
}

.drawer-header .section-index {
  margin-bottom: 12px;
}

.drawer-header h2 {
  max-width: 560px;
  font-size: clamp(2rem, 4vw, 3.5rem);
}

.drawer-header p:last-child {
  margin: 9px 0 0;
  color: var(--muted);
  font-size: 0.78rem;
}

.drawer-close {
  width: 38px;
  height: 38px;
  flex: 0 0 auto;
  border: 1px solid var(--ink);
  border-radius: 0;
  background: transparent;
  font-size: 1.4rem;
}

.drawer-close:hover {
  background: var(--ink);
  color: var(--paper);
}

.drawer-body {
  overflow-y: auto;
  padding: 0 34px 38px;
}

.finding-card {
  display: grid;
  grid-template-columns: 120px minmax(0, 1fr);
  gap: 22px;
  padding: 25px 0;
  border-bottom: 1px solid var(--ink);
}

.finding-card > span,
.mail-editor label > span,
.contact-details dt {
  color: var(--muted);
  font-size: 0.63rem;
  font-weight: 720;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.finding-card p {
  margin: 10px 0 0;
  font-size: 1.08rem;
  font-weight: 520;
  letter-spacing: -0.015em;
}

.contact-details {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  margin: 0;
  padding: 18px 0;
  border-bottom: 1px solid var(--ink);
}

.contact-details div {
  min-width: 0;
  padding: 6px 18px 6px 0;
}

.contact-details dd {
  margin: 5px 0 0;
  overflow: hidden;
  font-size: 0.78rem;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.contact-details a {
  text-underline-offset: 3px;
}

.mail-editor {
  padding: 28px 0 0;
}

.call-editor {
  padding: 28px 0;
  border-bottom: 1px solid var(--ink);
}

.call-editor > header,
.call-fields {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}

.call-editor > header {
  align-items: end;
  margin-bottom: 16px;
}

.call-editor h3 {
  margin: 0;
  font-size: 1.35rem;
  letter-spacing: -0.04em;
}

.call-editor header span {
  color: var(--muted);
  font-size: 0.68rem;
  text-align: right;
}

.call-editor label,
.dialog-field {
  display: block;
}

.call-editor label > span,
.dialog-field > span {
  display: block;
  margin-bottom: 6px;
  color: var(--muted);
  font-size: 0.63rem;
  font-weight: 720;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.call-editor input,
.call-editor textarea,
.dialog-field input {
  width: 100%;
  border: 1px solid var(--ink);
  border-radius: 0;
  background: var(--white);
  outline: 0;
}

.call-editor input,
.dialog-field input {
  height: 46px;
  padding: 0 13px;
}

.call-editor textarea {
  min-height: 110px;
  padding: 13px;
  line-height: 1.5;
  resize: vertical;
}

.call-editor input:focus,
.call-editor textarea:focus,
.dialog-field input:focus {
  border-color: var(--blue);
  box-shadow: inset 0 0 0 1px var(--blue);
}

.call-note-field {
  margin-top: 14px;
}

.call-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 16px;
}

.call-actions .button {
  min-width: 150px;
}

.mail-editor > header {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  margin-bottom: 16px;
}

.mail-editor h3 {
  margin: 0;
  font-size: 1.35rem;
  letter-spacing: -0.04em;
}

.mail-editor label {
  display: block;
  margin-top: 13px;
}

.mail-editor input,
.mail-editor textarea {
  width: 100%;
  margin-top: 6px;
  border: 1px solid var(--ink);
  border-radius: 0;
  background: var(--white);
  outline: 0;
}

.mail-editor input {
  height: 46px;
  padding: 0 13px;
}

.mail-editor textarea {
  min-height: 285px;
  padding: 13px;
  line-height: 1.52;
  resize: vertical;
}

.mail-editor input:focus,
.mail-editor textarea:focus {
  border-color: var(--blue);
  box-shadow: inset 0 0 0 1px var(--blue);
}

.mail-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 18px;
}

.mail-actions .button {
  min-width: 180px;
}

.workflow-actions {
  display: flex;
  gap: 22px;
  align-items: center;
  margin-top: 26px;
  padding-top: 22px;
  border-top: 1px solid var(--ink);
}

.drawer-status-note {
  margin: 16px 0 0;
  color: var(--muted);
  font-size: 0.72rem;
}

.send-dialog {
  width: min(520px, calc(100% - 32px));
  padding: 0;
  border: 1px solid var(--ink);
  border-radius: 0;
  background: var(--paper);
  color: var(--ink);
  box-shadow: 20px 20px 0 var(--blue);
}

.send-dialog::backdrop {
  background: rgba(10, 10, 10, 0.68);
}

.send-dialog form {
  padding: 30px;
}

.send-dialog .section-index {
  margin-bottom: 14px;
}

.send-dialog h2 {
  font-size: 2.2rem;
}

.send-dialog p:not(.section-index) {
  margin: 18px 0 0;
  color: var(--muted);
}

.dialog-field {
  margin-top: 20px;
}

.dialog-actions {
  display: flex;
  justify-content: flex-end;
  gap: 24px;
  align-items: center;
  margin-top: 28px;
}

.drop-overlay {
  position: fixed;
  z-index: 90;
  inset: 0;
  display: grid;
  place-items: center;
  background: rgba(36, 80, 255, 0.94);
  color: var(--white);
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transition: opacity 150ms ease;
}

.drop-overlay.is-visible {
  opacity: 1;
  visibility: visible;
}

.drop-overlay div {
  padding: 45px 70px;
  border: 1px solid var(--white);
  text-align: center;
}

.drop-overlay strong,
.drop-overlay span {
  display: block;
}

.drop-overlay strong {
  font-size: 2rem;
  letter-spacing: -0.04em;
}

.drop-overlay span {
  margin-top: 8px;
}

.toast {
  position: fixed;
  z-index: 100;
  right: 22px;
  bottom: 22px;
  max-width: min(390px, calc(100vw - 44px));
  padding: 14px 18px;
  background: var(--ink);
  color: var(--paper);
  font-size: 0.77rem;
  opacity: 0;
  transform: translateY(14px);
  transition: opacity 150ms ease, transform 150ms ease;
  pointer-events: none;
}

.toast.is-visible {
  opacity: 1;
  transform: translateY(0);
}

.toast.is-error {
  background: var(--danger);
}

@media (max-width: 1050px) {
  .app-header {
    grid-template-columns: 1fr auto;
  }

  .dataset-state {
    display: none;
  }

  .dashboard-head {
    grid-template-columns: 1fr;
    min-height: 205px;
  }

  .dashboard-note {
    max-width: 560px;
  }

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

  .metrics article:nth-child(even) {
    border-right: 0;
  }

  .metrics article:nth-child(-n + 4) {
    border-bottom: 1px solid var(--ink);
  }

  .metrics article:last-child {
    grid-column: 1 / -1;
  }

  .panel-top {
    grid-template-columns: 1fr;
  }

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

  .insight-panel,
  .insight-panel + .insight-panel {
    min-height: 0;
    padding: 26px 0;
    border-right: 0;
    border-bottom: 1px solid var(--ink);
  }

  .insight-panel + .insight-panel {
    border-bottom: 0;
  }

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

  .filters > * {
    border-bottom: 1px solid var(--line);
  }

  table {
    min-width: 900px;
  }
}

@media (max-width: 680px) {
  .app-header {
    min-height: 64px;
    padding: 0 16px;
  }

  .test-mode-banner {
    top: 64px;
    gap: 4px;
    align-items: flex-start;
    flex-direction: column;
  }

  .header-actions {
    gap: 12px;
  }

  .header-actions > .rule-button {
    display: none;
  }

  .button {
    gap: 12px;
    padding: 0 12px;
  }

  #workspace {
    padding-right: 16px;
    padding-left: 16px;
  }

  .dashboard-head {
    min-height: 190px;
    padding-top: 32px;
  }

  .dashboard-head h1 {
    font-size: clamp(2.7rem, 13vw, 4.5rem);
  }

  .metrics article {
    min-height: 110px;
    padding: 18px 14px 16px 0;
  }

  .metrics article:not(:first-child) {
    padding-left: 14px;
  }

  .metrics strong {
    font-size: 2.7rem;
  }

  .status-chart {
    grid-template-columns: 120px minmax(0, 1fr);
    gap: 18px;
  }

  .status-donut {
    width: 120px;
    height: 120px;
  }

  .status-donut::after {
    width: 70px;
    height: 70px;
  }

  .sector-row {
    grid-template-columns: minmax(90px, 0.85fr) minmax(90px, 1.15fr) 30px;
    gap: 9px;
  }

  .panel-top {
    padding-bottom: 18px;
  }

  .workflow-tabs {
    grid-template-columns: 1fr;
  }

  .workflow-tab {
    border-right: 0;
    border-bottom: 1px solid var(--ink);
  }

  .workflow-tab:last-child {
    border-bottom: 0;
  }

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

  .filters label {
    border-right: 0;
  }

  .filters > .rule-button {
    justify-self: start;
    margin: 13px;
  }

  .result-line {
    gap: 12px;
    align-items: flex-start;
  }

  .result-line span:last-child {
    text-align: right;
  }

  .pagination {
    gap: 20px;
    align-items: flex-start;
    flex-direction: column;
    padding: 14px;
  }

  .site-footer {
    grid-template-columns: 1fr;
    gap: 18px;
  }

  .drawer-header {
    padding: 24px 20px 20px;
  }

  .drawer-body {
    padding: 0 20px 28px;
  }

  .call-editor > header,
  .call-fields {
    grid-template-columns: 1fr;
  }

  .call-editor header span {
    text-align: left;
  }

  .finding-card {
    grid-template-columns: 1fr;
    gap: 6px;
  }

  .contact-details {
    grid-template-columns: 1fr;
  }

  .mail-actions,
  .workflow-actions {
    align-items: stretch;
    flex-direction: column;
  }

  .mail-actions .button {
    width: 100%;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    scroll-behavior: auto !important;
    transition-duration: 0.01ms !important;
  }
}
