:root {
  --ink: #17212b;
  --muted: #65727f;
  --line: #dfe5e8;
  --soft: #f3f6f7;
  --paper: #ffffff;
  --brand: #0f766e;
  --brand-dark: #0a5a54;
  --danger: #b42318;
  --danger-dark: #8d1b13;
  --focus: #1d75bd;
  --shadow: 0 16px 42px rgb(19 36 49 / 8%);
}

* {
  box-sizing: border-box;
}

html {
  min-width: 320px;
  background: var(--paper);
  color: var(--ink);
  font-family: Inter, ui-sans-serif, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  line-height: 1.5;
}

body {
  min-height: 100vh;
  margin: 0;
  background: var(--paper);
}

button,
input,
textarea {
  font: inherit;
}

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

a {
  color: inherit;
}

img {
  display: block;
  max-width: 100%;
}

[hidden] {
  display: none !important;
}

:focus-visible {
  outline: 3px solid color-mix(in srgb, var(--focus) 70%, white);
  outline-offset: 3px;
}

.shell {
  width: min(1120px, calc(100% - 32px));
  margin-inline: auto;
}

.narrow {
  width: min(650px, 100%);
  margin-inline: auto;
}

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

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

.site-header {
  border-bottom: 1px solid rgb(223 229 232 / 90%);
  background: rgb(255 255 255 / 92%);
  backdrop-filter: blur(10px);
}

.header-inner {
  display: flex;
  min-height: 68px;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}

.brand {
  color: var(--ink);
  font-size: 1.22rem;
  font-weight: 800;
  letter-spacing: -0.025em;
  text-decoration: none;
}

.site-nav {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 18px;
  color: #3f4d59;
  font-size: 0.92rem;
  font-weight: 600;
}

.site-nav > a {
  text-decoration: none;
}

.site-nav > a:hover,
.link-button:hover,
.text-link:hover {
  color: var(--brand);
}

.nav-form {
  margin: 0;
}

.link-button {
  padding: 0;
  border: 0;
  background: transparent;
  color: #3f4d59;
  cursor: pointer;
  font-weight: 600;
}

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

.site-main {
  min-height: calc(100vh - 68px);
  padding-block: 56px 72px;
}

h1,
h2,
h3,
p {
  margin-top: 0;
}

h1,
h2,
h3 {
  color: var(--ink);
  line-height: 1.15;
  letter-spacing: -0.025em;
}

h1 {
  margin-bottom: 16px;
  font-size: clamp(2rem, 5vw, 3.35rem);
}

h2 {
  margin-bottom: 12px;
  font-size: clamp(1.35rem, 3vw, 1.75rem);
}

h3 {
  margin-bottom: 8px;
  font-size: 1.05rem;
}

.eyebrow {
  margin-bottom: 8px;
  color: var(--brand);
  font-size: 0.73rem;
  font-weight: 800;
  letter-spacing: 0.13em;
  text-transform: uppercase;
}

.lede {
  max-width: 760px;
  color: #43515e;
  font-size: clamp(1.06rem, 2vw, 1.22rem);
}

.muted,
.form-note,
.table-note {
  color: var(--muted);
}

.form-note {
  margin: 0;
  font-size: 0.87rem;
}

.preserve-lines,
.table-note {
  white-space: pre-line;
}

.break-word {
  overflow-wrap: anywhere;
}

.panel {
  border: 1px solid var(--line);
  border-radius: 14px;
  background: var(--paper);
  box-shadow: var(--shadow);
}

.panel {
  padding: 26px;
}

.auth-card {
  padding: clamp(28px, 6vw, 48px);
  background: transparent;
}

.panel > :last-child,
.auth-card > :last-child {
  margin-bottom: 0;
}

.panel-heading,
.page-heading,
.action-panel {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 24px;
}

.panel-heading {
  margin-bottom: 20px;
}

.panel-heading h2,
.panel-heading p,
.page-heading h1,
.page-heading p,
.action-panel h2,
.action-panel p {
  margin-bottom: 0;
}

.page-heading {
  align-items: center;
  margin-bottom: 30px;
}

.page-heading h1 {
  font-size: clamp(2rem, 4.5vw, 3rem);
}

.campaign-heading {
  align-items: flex-end;
}

.two-column {
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(280px, 0.85fr);
  gap: 24px;
}

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

.crm-layout {
  display: grid;
  grid-template-columns: minmax(0, 2fr) minmax(260px, 0.8fr);
  align-items: start;
  gap: 24px;
}

.crm-entry-grid {
  align-items: start;
}

.section-gap {
  margin-top: 24px;
}

.stack-form {
  display: grid;
  gap: 11px;
}

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

.form-field {
  display: grid;
  align-content: start;
  gap: 7px;
}

.form-field-wide {
  grid-column: 1 / -1;
}

.stack-form label,
.grow-field label,
.field-label {
  color: #34434f;
  font-size: 0.91rem;
  font-weight: 700;
}

input,
textarea {
  width: 100%;
  border: 1px solid #bdc7ce;
  border-radius: 7px;
  background: white;
  color: var(--ink);
}

input,
textarea {
  padding: 11px 12px;
}

input[type="file"] {
  padding: 9px;
  background: var(--soft);
}

input:focus,
textarea:focus {
  border-color: var(--focus);
  outline: 2px solid rgb(29 117 189 / 16%);
}

textarea {
  min-height: 92px;
  resize: vertical;
}

.inline-form {
  display: flex;
  align-items: flex-end;
  gap: 16px;
}

.grow-field {
  display: grid;
  flex: 1;
  gap: 8px;
}

.button,
button.button {
  display: inline-flex;
  min-height: 44px;
  align-items: center;
  justify-content: center;
  width: fit-content;
  padding: 10px 17px;
  border: 1px solid var(--brand);
  border-radius: 7px;
  background: var(--brand);
  color: white;
  cursor: pointer;
  font-weight: 750;
  line-height: 1.2;
  text-align: center;
  text-decoration: none;
}

.button:hover {
  border-color: var(--brand-dark);
  background: var(--brand-dark);
}

.button:disabled {
  cursor: not-allowed;
  opacity: 0.55;
}

.button-secondary {
  border-color: #bdc7ce;
  background: white;
  color: #34434f;
}

.button-secondary:hover {
  border-color: #87949e;
  background: var(--soft);
  color: var(--ink);
}

.button-danger {
  border-color: var(--danger);
  background: var(--danger);
}

.button-danger:hover {
  border-color: var(--danger-dark);
  background: var(--danger-dark);
}

.button-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px;
}

.button-row form {
  margin: 0;
}

.text-link {
  color: #0869b2;
  font-weight: 700;
  text-underline-offset: 3px;
}

.notice,
.flash {
  padding: 12px 14px;
  border: 1px solid #b8d6d2;
  border-radius: 7px;
  background: #edf8f6;
  color: #174b46;
}

.notice-error,
.flash-error {
  border-color: #f2b8b5;
  background: #fff1f0;
  color: #8f1d15;
}

.flash-success {
  border-color: #afd7bb;
  background: #effaf2;
  color: #1e6432;
}

.flash-stack {
  display: grid;
  margin-bottom: 24px;
  gap: 9px;
}

.steps {
  display: grid;
  margin: 18px 0;
  padding-left: 24px;
  gap: 11px;
}

.steps li::marker {
  color: var(--brand);
  font-weight: 800;
}

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

table {
  width: 100%;
  border-collapse: collapse;
  text-align: left;
}

th,
td {
  padding: 13px 12px;
  border-bottom: 1px solid var(--line);
  vertical-align: top;
}

th {
  color: #52616d;
  font-size: 0.73rem;
  letter-spacing: 0.07em;
  text-transform: uppercase;
}

tbody tr:last-child td {
  border-bottom: 0;
}

.table-note {
  max-width: 420px;
  margin: 6px 0 0;
  font-size: 0.86rem;
}

td small.muted {
  display: block;
  margin-top: 3px;
}

.align-right {
  text-align: right;
}

.empty-cell {
  padding: 32px 12px;
  color: var(--muted);
  text-align: center;
}

.badge {
  display: inline-flex;
  align-items: center;
  padding: 4px 9px;
  border: 1px solid #d2dadd;
  border-radius: 999px;
  background: var(--soft);
  color: #42515d;
  font-size: 0.78rem;
  font-weight: 700;
  white-space: nowrap;
}

.empty-state {
  padding-block: 32px;
  color: var(--muted);
  text-align: center;
}

.empty-state > :last-child {
  margin-bottom: 0;
}

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

.stat-card {
  display: flex;
  min-height: 126px;
  flex-direction: column;
  justify-content: space-between;
  padding: 20px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: var(--paper);
  box-shadow: var(--shadow);
  color: var(--muted);
  text-decoration: none;
}

.stat-card strong {
  color: var(--ink);
  font-size: 2rem;
  line-height: 1;
}

.stat-card:hover {
  border-color: #aebbc2;
  transform: translateY(-1px);
}

.compact-list,
.activity-list {
  margin: 0;
  padding: 0;
  list-style: none;
}

.compact-list li,
.activity-list li {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 18px;
  padding: 13px 0;
  border-bottom: 1px solid var(--line);
}

.compact-list li:last-child,
.activity-list li:last-child {
  padding-bottom: 0;
  border-bottom: 0;
}

.compact-list span,
.activity-list p,
.activity-list time {
  display: block;
  margin: 3px 0 0;
  color: var(--muted);
  font-size: 0.86rem;
}

.compact-activity li {
  padding-block: 10px;
}

.member-page-heading {
  margin-bottom: 24px;
}

.member-summary {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  margin-bottom: 52px;
  gap: 14px;
}

.summary-card {
  display: grid;
  min-height: 148px;
  align-content: space-between;
  padding: 20px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: #fafbfb;
  gap: 8px;
}

.summary-card-primary {
  border-color: #abd6d0;
  background: #eff9f7;
}

.summary-card span {
  color: #4d5c67;
  font-size: 0.82rem;
  font-weight: 750;
}

.summary-card strong {
  color: var(--ink);
  font-size: clamp(2.45rem, 5vw, 3.5rem);
  line-height: 1;
  letter-spacing: -0.055em;
}

.summary-card-primary strong {
  color: var(--brand-dark);
}

.summary-card small {
  color: var(--muted);
  font-size: 0.8rem;
}

.history-section {
  margin-top: 46px;
}

.history-section-heading,
.response-heading,
.response-title,
.request-history-main,
.screenshot-group-heading,
.screenshot-card figcaption {
  display: flex;
  align-items: flex-start;
}

.history-section-heading,
.response-heading,
.screenshot-group-heading,
.screenshot-card figcaption {
  justify-content: space-between;
}

.history-section-heading {
  margin-bottom: 18px;
  gap: 24px;
}

.history-section-heading h2,
.history-section-heading p,
.response-heading h3,
.response-heading p,
.request-history-item h3,
.request-history-item p,
.screenshot-group-heading strong,
.screenshot-group-heading span,
.screenshot-card figcaption strong,
.screenshot-card figcaption span {
  margin-bottom: 0;
}

.history-section-heading .muted {
  margin-top: 6px;
}

.section-count {
  padding: 5px 10px;
  border-radius: 999px;
  background: var(--soft);
  color: #52616d;
  font-size: 0.78rem;
  font-weight: 750;
  white-space: nowrap;
}

.campaign-response-list,
.request-history-list {
  display: grid;
  gap: 14px;
}

.campaign-response-card,
.request-history-item {
  padding: 22px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: var(--paper);
}

.campaign-response-card {
  border-left-width: 4px;
}

.response-responded {
  border-left-color: var(--brand);
}

.response-missing {
  border-left-color: #d18d1f;
}

.response-undelivered {
  border-left-color: #a6b0b7;
}

.response-heading {
  gap: 20px;
}

.response-title {
  min-width: 0;
  gap: 12px;
}

.response-title p,
.request-history-main p {
  margin-top: 5px;
  color: var(--muted);
  font-size: 0.84rem;
}

.response-marker {
  flex: 0 0 auto;
  width: 10px;
  height: 10px;
  margin-top: 5px;
  border-radius: 50%;
  background: #a6b0b7;
}

.response-responded .response-marker {
  background: var(--brand);
}

.response-missing .response-marker {
  background: #d18d1f;
}

.response-badge,
.request-status {
  display: inline-flex;
  flex: 0 0 auto;
  align-items: center;
  padding: 5px 10px;
  border-radius: 999px;
  font-size: 0.76rem;
  font-weight: 800;
  line-height: 1.2;
  white-space: nowrap;
}

.response-badge-responded,
.request-status-approved {
  background: #e7f6f2;
  color: #0b625a;
}

.response-badge-missing,
.request-status-pending {
  background: #fff4dc;
  color: #80540c;
}

.response-badge-undelivered {
  background: var(--soft);
  color: #5c6973;
}

.request-status-rejected {
  background: #fcedeb;
  color: #982319;
}

.response-links,
.screenshot-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 9px 16px;
}

.response-links {
  margin-top: 12px;
  font-size: 0.86rem;
}

.response-note {
  margin: 18px 0 0;
  padding: 13px 15px;
  border-radius: 9px;
  background: var(--soft);
  color: #52616d;
  font-size: 0.9rem;
}

.screenshot-group-heading {
  margin-top: 22px;
  padding-top: 18px;
  border-top: 1px solid var(--line);
  gap: 16px;
}

.screenshot-group-heading span {
  color: var(--muted);
  font-size: 0.82rem;
}

.screenshot-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  margin-top: 12px;
  gap: 12px;
}

.screenshot-card {
  min-width: 0;
  margin: 0;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 11px;
  background: #fafbfb;
}

.screenshot-preview {
  display: block;
  overflow: hidden;
  border-bottom: 1px solid var(--line);
  background: var(--soft);
}

.screenshot-preview img {
  width: 100%;
  aspect-ratio: 4 / 3;
  object-fit: contain;
}

.screenshot-card figcaption {
  padding: 12px;
  gap: 12px;
}

.screenshot-card figcaption span {
  display: block;
  margin-top: 3px;
  color: var(--muted);
  font-size: 0.74rem;
}

.screenshot-actions {
  justify-content: flex-end;
  font-size: 0.78rem;
  font-weight: 750;
}

.screenshot-actions form {
  margin: 0;
}

.screenshot-actions a,
.screenshot-actions button {
  padding: 0;
  border: 0;
  background: transparent;
  color: #0869b2;
  cursor: pointer;
  font: inherit;
  text-decoration: underline;
  text-underline-offset: 3px;
}

.screenshot-actions button {
  color: var(--danger);
}

.request-history-item {
  display: grid;
  gap: 13px;
}

.request-history-main {
  gap: 14px;
}

.request-history-item h3 a {
  text-underline-offset: 3px;
}

.request-note {
  padding-left: 14px;
  border-left: 2px solid var(--line);
  color: #44525e;
  font-size: 0.9rem;
}

.empty-state-bordered {
  border: 1px dashed #cbd4d9;
  border-radius: 14px;
}

.member-record > summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  cursor: pointer;
  gap: 20px;
  list-style: none;
}

.member-record > summary::-webkit-details-marker {
  display: none;
}

.member-record > summary::after {
  color: var(--muted);
  content: "+";
  font-size: 1.4rem;
  line-height: 1;
}

.member-record[open] > summary::after {
  content: "−";
}

.member-record > summary small {
  display: block;
  margin-top: 3px;
  color: var(--muted);
  font-size: 0.82rem;
  font-weight: 400;
}

.member-record-grid {
  margin-top: 24px;
  padding-top: 24px;
  border-top: 1px solid var(--line);
}

.member-access-panel {
  padding-left: 24px;
  border-left: 1px solid var(--line);
}

.profile-links {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 10px;
  font-size: 0.86rem;
}

.access-panel {
  display: grid;
  align-content: start;
  gap: 18px;
}

.access-panel h2,
.access-panel p,
.access-panel form {
  margin-bottom: 0;
}

.csv-columns {
  overflow-x: auto;
  padding: 10px 12px;
  border-radius: 7px;
  background: var(--soft);
  font-size: 0.82rem;
  white-space: nowrap;
}

.action-panel {
  align-items: center;
}

.detail-stack {
  display: grid;
  gap: 24px;
}

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

.definition-grid > div {
  display: grid;
  padding: 15px;
  border-radius: 8px;
  background: var(--soft);
  gap: 3px;
}

.definition-grid span {
  color: var(--muted);
  font-size: 0.8rem;
}

.divider-top {
  padding-top: 22px;
  border-top: 1px solid var(--line);
}

.confirm-card {
  text-align: center;
}

.confirm-card .button-row {
  justify-content: center;
}

.confirm-number {
  color: var(--brand);
  font-size: clamp(3rem, 8vw, 5rem);
  font-weight: 850;
  line-height: 1;
}

.monospace {
  font-family: ui-monospace, SFMono-Regular, Consolas, monospace;
  font-size: 0.82rem;
}

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

@media (max-width: 840px) {
  .site-main {
    padding-top: 40px;
  }

  .two-column,
  .campaign-grid,
  .crm-layout {
    grid-template-columns: 1fr;
  }

  .member-access-panel {
    padding-top: 24px;
    padding-left: 0;
    border-top: 1px solid var(--line);
    border-left: 0;
  }

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

  .site-nav {
    gap: 12px;
  }
}

@media (max-width: 620px) {
  .shell {
    width: min(100% - 22px, 1120px);
  }

  .header-inner {
    min-height: auto;
    flex-direction: column;
    align-items: flex-start;
    padding-block: 15px;
    gap: 10px;
  }

  .site-nav {
    width: 100%;
    flex-wrap: wrap;
    justify-content: flex-start;
    gap: 8px 14px;
  }

  .site-main {
    padding-block: 32px 52px;
  }

  .panel,
  .auth-card {
    padding: 20px;
  }

  .page-heading,
  .panel-heading,
  .action-panel,
  .inline-form,
  .campaign-heading {
    align-items: stretch;
    flex-direction: column;
  }

  .page-heading .button,
  .inline-form .button,
  .action-panel > .button {
    width: 100%;
  }

  .stat-grid,
  .member-summary,
  .definition-grid,
  .form-grid {
    grid-template-columns: 1fr;
  }

  .member-summary {
    margin-bottom: 42px;
  }

  .summary-card {
    min-height: 126px;
  }

  .history-section-heading,
  .response-heading,
  .request-history-main,
  .screenshot-group-heading,
  .screenshot-card figcaption {
    flex-direction: column;
    gap: 10px;
  }

  .response-badge {
    align-self: flex-start;
  }

  .screenshot-actions {
    justify-content: flex-start;
  }

  .stat-card {
    min-height: 105px;
  }

  th,
  td {
    padding-inline: 9px;
  }
}
