:root {
  --bg: #f6f8fb;
  --panel: #ffffff;
  --panel-2: #eef4f0;
  --ink: #101820;
  --muted: #62706a;
  --line: #d9e2dd;
  --brand: #0b3d2e;
  --brand-2: #176b4f;
  --accent: #d79b28;
  --danger: #b42318;
  --shadow: 0 18px 45px rgba(16, 24, 32, 0.09);
}

* { box-sizing: border-box; }

html {
  background: var(--bg);
  color: var(--ink);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

body {
  margin: 0;
  min-height: 100vh;
  background: linear-gradient(180deg, rgba(11, 61, 46, 0.08), transparent 340px), var(--bg);
}

.boot-screen {
  align-items: center;
  display: flex;
  justify-content: center;
  min-height: 100vh;
  padding: 24px;
}

.boot-card {
  align-items: center;
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 8px;
  box-shadow: var(--shadow);
  display: grid;
  gap: 10px;
  justify-items: center;
  max-width: 340px;
  padding: 28px;
  text-align: center;
}

.boot-card p {
  color: var(--muted);
  font-weight: 750;
  margin: 0;
}

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

button {
  min-height: 44px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--panel);
  color: var(--ink);
  font-weight: 850;
  cursor: pointer;
}

button:disabled { opacity: 0.45; cursor: not-allowed; }

input, select, textarea {
  width: 100%;
  min-height: 44px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fbfdfc;
  color: var(--ink);
  padding: 10px 11px;
  outline: none;
}

input:focus, select:focus, textarea:focus {
  border-color: var(--brand-2);
  box-shadow: 0 0 0 3px rgba(23, 107, 79, 0.14);
}

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

label {
  display: grid;
  gap: 6px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 850;
}

a { color: inherit; }

h1, h2, h3, p { margin-top: 0; }
h1 { font-size: clamp(34px, 6vw, 68px); line-height: 0.98; letter-spacing: 0; margin-bottom: 18px; }
h2 { font-size: 22px; margin-bottom: 12px; }
h3 { font-size: 18px; margin-bottom: 10px; }

.topbar {
  position: sticky;
  top: 0;
  z-index: 8;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  min-height: 70px;
  padding: max(12px, env(safe-area-inset-top)) 18px 12px;
  border-bottom: 1px solid rgba(217, 226, 221, 0.78);
  background: rgba(246, 248, 251, 0.92);
  backdrop-filter: blur(14px);
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-weight: 950;
  text-decoration: none;
}

.brand-mark {
  display: grid;
  place-items: center;
  width: 38px;
  height: 38px;
  border-radius: 8px;
  background: var(--brand);
  color: #fff;
  font-size: 13px;
}

.public-nav, .app-nav {
  display: flex;
  align-items: center;
  gap: 8px;
  justify-content: flex-end;
  max-width: min(100%, calc(100vw - 210px));
  overflow-x: auto;
  padding-bottom: 4px;
  scrollbar-width: thin;
}

.public-nav a {
  color: var(--muted);
  font-size: 14px;
  font-weight: 850;
  text-decoration: none;
  padding: 10px;
}

.app-nav button {
  flex: 0 0 auto;
  width: auto;
  min-height: 38px;
  padding: 8px 10px;
  white-space: nowrap;
}

.nav-tab.active {
  background: var(--brand);
  border-color: var(--brand);
  color: #fff;
}

.primary-action {
  background: var(--brand);
  border-color: var(--brand);
  color: #fff;
}

.subtle-action {
  align-self: flex-start;
  background: var(--soft);
  border-color: var(--line);
  color: var(--muted);
  margin-bottom: 10px;
}

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

.danger-action {
  color: var(--danger);
  border-color: rgba(180, 35, 24, 0.28);
}

.danger-action:hover {
  background: rgba(180, 35, 24, 0.08);
}

.marketing, .app-shell {
  width: min(1180px, 100%);
  margin: 0 auto;
  padding: 22px 16px 92px;
}

.hero {
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(340px, 0.9fr);
  gap: 24px;
  align-items: center;
  min-height: calc(100vh - 95px);
}

.hero-copy p {
  max-width: 660px;
  color: var(--muted);
  font-size: 18px;
  line-height: 1.55;
}

.eyebrow {
  margin: 0 0 8px;
  color: var(--brand-2);
  font-size: 11px;
  font-weight: 950;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.hero-actions {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  margin-top: 24px;
}

.hero-actions button {
  width: auto;
  padding-inline: 18px;
}

.hero-product {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  box-shadow: var(--shadow);
  padding: 16px;
}

.preview-top {
  display: grid;
  gap: 6px;
  padding: 18px;
  border-radius: 8px;
  background: var(--brand);
  color: #fff;
  margin-bottom: 12px;
}

.preview-top span { color: rgba(255, 255, 255, 0.72); font-weight: 850; }
.preview-top strong { font-size: 36px; }

.preview-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 14px 4px;
  border-bottom: 1px solid var(--line);
  font-weight: 850;
}

.preview-row.muted {
  color: var(--muted);
  border-bottom: 0;
}

.value-band, .price-grid, .summary-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 12px;
}

.value-band article, .price-card, .panel, .metric {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.94);
  box-shadow: var(--shadow);
}

.value-band article, .price-card {
  padding: 18px;
}

.value-band p, .price-card p, .muted-copy {
  color: var(--muted);
  line-height: 1.5;
}

.pricing { padding-top: 70px; }
.section-heading { margin-bottom: 18px; }

.price-card strong {
  display: block;
  font-size: 42px;
  margin: 10px 0;
}

.price-card strong span {
  color: var(--muted);
  font-size: 16px;
}

.price-card button {
  margin-top: 14px;
  width: 100%;
}

.price-card.featured {
  border-color: rgba(11, 61, 46, 0.42);
  box-shadow: 0 18px 45px rgba(11, 61, 46, 0.16);
}

.trust-strip {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 14px;
}

.trust-strip span {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.72);
  color: var(--muted);
  font-size: 12px;
  font-weight: 900;
  padding: 9px 11px;
}

.workspace-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 12px;
}

.workspace-bar h1 {
  font-size: 30px;
  margin: 0;
}

.workspace-actions {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 8px;
  flex-wrap: wrap;
}

.workspace-actions button {
  width: auto;
  min-height: 38px;
  padding: 8px 12px;
}

.status-pill {
  flex: 0 0 auto;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--panel);
  padding: 8px 10px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 850;
}

.billing-status-banner {
  align-items: center;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 8px;
  display: flex;
  gap: 12px;
  justify-content: space-between;
  margin-bottom: 12px;
  padding: 12px;
}

.billing-status-banner.ok {
  border-color: #a6dec1;
}

.billing-status-banner.warn {
  background: #fff2cf;
  border-color: #f0d48c;
}

.billing-status-banner div {
  display: grid;
  gap: 3px;
}

.billing-status-banner strong {
  font-size: 14px;
}

.billing-status-banner span {
  color: var(--muted);
  font-size: 13px;
  font-weight: 750;
}

.billing-status-banner button {
  flex: 0 0 auto;
  min-height: 36px;
  padding: 7px 11px;
}

.cloud-error-banner {
  background: #fde8e5;
  border: 1px solid #f2b8b0;
  border-radius: 8px;
  color: #8f2b1d;
  margin: 0 0 12px;
  padding: 12px;
}

.cloud-error-banner strong,
.cloud-error-banner span {
  display: block;
}

.cloud-error-banner span {
  font-size: 13px;
  font-weight: 800;
  line-height: 1.4;
  margin-top: 4px;
  overflow-wrap: anywhere;
}

.summary-grid {
  grid-template-columns: 1.4fr repeat(3, 1fr);
  margin-bottom: 12px;
}

.onboarding-panel {
  margin-bottom: 12px;
}

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

.onboarding-item {
  align-items: start;
  background: #fbfdfc;
  border: 1px solid var(--line);
  border-radius: 8px;
  display: grid;
  gap: 8px;
  grid-template-columns: auto minmax(0, 1fr) auto;
  padding: 12px;
}

.onboarding-item.done {
  background: #f4fbf7;
}

.onboarding-item span {
  border: 1px solid #f0d48c;
  border-radius: 999px;
  color: #73510b;
  font-size: 11px;
  font-weight: 950;
  padding: 4px 7px;
  text-transform: uppercase;
}

.onboarding-item.done span {
  border-color: #a6dec1;
  color: #0b5d3f;
}

.onboarding-item strong,
.onboarding-item p {
  margin: 0;
}

.onboarding-item p {
  color: var(--muted);
  font-size: 13px;
  line-height: 1.35;
}

.onboarding-item button {
  min-height: 34px;
  padding: 6px 9px;
}

.metric {
  display: grid;
  gap: 6px;
  padding: 14px;
}

.metric span, .cost-lines span, .list-row span, .arr-card span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 850;
}

.metric strong {
  font-size: 24px;
  line-height: 1;
}

.metric.primary {
  background: var(--brand);
  color: #fff;
  border-color: var(--brand);
}

.metric.primary span { color: rgba(255, 255, 255, 0.72); }

.toolbar {
  display: grid;
  grid-template-columns: 1fr 180px 1.2fr 150px;
  gap: 10px;
  margin-bottom: 12px;
}

.approval-panel {
  margin-bottom: 12px;
}

.unassigned-time-panel {
  background: #fffbeb;
  border-color: #f0d985;
  margin-bottom: 12px;
}

.unassigned-time-panel .approval-item {
  background: #fffef7;
  border-color: #f0d985;
}

.unassigned-time-panel .assignment-summary {
  color: #7a5b00;
  font-weight: 850;
}

.approval-queue {
  display: grid;
  gap: 10px;
}

.approval-item {
  align-items: center;
  background: #fbfdfc;
  border: 1px solid var(--line);
  border-radius: 8px;
  display: grid;
  gap: 10px;
  grid-template-columns: auto minmax(0, 1fr) auto;
  padding: 12px;
}

.approval-item p {
  color: var(--muted);
  margin: 4px 0 0;
}

.approval-item button {
  min-height: 36px;
  padding: 7px 11px;
}

.payroll-readiness-card {
  border: 1px solid var(--line);
  border-radius: 8px;
  display: grid;
  gap: 4px;
  margin-bottom: 12px;
  padding: 12px;
}

.payroll-readiness-card.ok {
  background: #e6f7ef;
  border-color: #a6dec1;
  color: #0b5d3f;
}

.payroll-readiness-card.warn {
  background: #fff2cf;
  border-color: #f0d48c;
  color: #73510b;
}

.payroll-readiness-card span {
  font-size: 13px;
  font-weight: 750;
  line-height: 1.4;
}

.payroll-preview-grid {
  display: grid;
  gap: 8px;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  margin: 10px 0 12px;
}

.payroll-preview-grid div {
  background: #f8faf7;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 10px;
}

.payroll-preview-grid span {
  color: var(--muted);
  display: block;
  font-size: 12px;
  font-weight: 850;
}

.payroll-preview-grid strong {
  color: var(--ink);
  display: block;
  font-size: 16px;
  margin-top: 3px;
}

.status-pill.status-submitted {
  background: #fff2cf;
  border-color: #f0d48c;
  color: #73510b;
}

.status-pill.status-approved {
  background: #e6f7ef;
  border-color: #a6dec1;
  color: #0b5d3f;
}

.status-pill.status-rejected {
  background: #fde8e5;
  border-color: #f2b8b0;
  color: var(--danger);
}

.main-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.35fr) minmax(310px, 0.65fr);
  gap: 12px;
}

.panel {
  padding: 14px;
}

.panel-title {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 10px;
}

.panel-title button {
  width: auto;
  padding-inline: 12px;
}

.side-stack {
  display: grid;
  gap: 12px;
  align-content: start;
}

.day-list, .list-stack {
  display: grid;
  gap: 8px;
}

.day-row {
  display: grid;
  grid-template-columns: 110px repeat(3, minmax(82px, 1fr)) 86px 96px;
  gap: 8px;
  align-items: end;
  padding: 10px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fbfdfc;
}

.day-name {
  align-self: center;
  font-weight: 950;
}

.day-total {
  align-self: center;
  text-align: right;
}

.day-total span {
  display: block;
  color: var(--muted);
  font-size: 11px;
  font-weight: 850;
}

.day-total strong { font-size: 15px; }

.rate-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  margin-top: 10px;
}

.worker-checklist-field {
  display: grid;
  gap: 8px;
  margin: 0;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
}

.worker-checklist-field legend {
  padding: 0 4px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 850;
}

.worker-checklist {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(170px, 1fr));
  gap: 8px;
}

.worker-check-row {
  display: flex;
  align-items: center;
  gap: 9px;
  min-height: 48px;
  padding: 9px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fbfdfc;
  cursor: pointer;
}

.worker-check-row:has(input:checked) {
  border-color: var(--brand-2);
  background: var(--panel-2);
}

.worker-check-row input {
  flex: 0 0 auto;
  width: 18px;
  min-height: 18px;
  accent-color: var(--brand);
}

.worker-check-row span {
  display: grid;
  gap: 2px;
}

.worker-check-row small {
  color: var(--muted);
}

.cost-lines {
  display: grid;
  gap: 8px;
  margin-top: 12px;
  padding-top: 12px;
  border-top: 1px solid var(--line);
}

.cost-lines div, .list-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.list-row {
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fbfdfc;
}

.system-job-row {
  background: #fffdf5;
  border-color: #f4d99a;
}

.system-pill {
  align-items: center;
  background: #fff2bf;
  border: 1px solid #f4d99a;
  border-radius: 999px;
  color: #6d4b00;
  display: inline-flex;
  font-size: 12px;
  font-weight: 850;
  min-height: 32px;
  padding: 5px 9px;
}

.empty-state {
  background: #fbfdfc;
  border: 1px dashed var(--line);
  border-radius: 8px;
  display: grid;
  gap: 8px;
  padding: 14px;
}

.empty-state strong,
.empty-state p {
  margin: 0;
}

.empty-state p {
  color: var(--muted);
  line-height: 1.45;
}

.empty-state button {
  justify-self: start;
  min-height: 36px;
  padding: 7px 11px;
}

.site-pulse-row {
  align-items: flex-start;
}

.job-health-row {
  align-items: flex-start;
}

.job-health-row > div:first-child {
  display: grid;
  gap: 3px;
}

.job-health-row .button-row {
  justify-content: flex-end;
  margin-top: 6px;
}

.job-health-row .button-row button {
  min-height: 32px;
  padding: 5px 8px;
}

.team-row {
  align-items: flex-start;
}

.team-status-row {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 7px;
}

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

.health-pill {
  border-radius: 999px;
  display: inline-flex;
  font-size: 12px;
  font-weight: 950;
  justify-content: center;
  margin-bottom: 4px;
  padding: 5px 9px;
}

.health-green {
  background: #e6f7ef;
  color: #0b5d3f;
}

.health-yellow {
  background: #fff2cf;
  color: #73510b;
}

.health-red {
  background: #fee7e7;
  color: #8a1515;
}

.progress-pill {
  border: 1px solid var(--line);
  border-radius: 999px;
  flex: 0 0 auto;
  font-size: 12px;
  font-weight: 950;
  padding: 6px 9px;
}

.pulse-summary {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 10px;
}

.progress-blocked {
  background: #fee7e7;
  border-color: #f7b9b9;
  color: #8a1515;
}

.progress-delayed {
  background: #fff2cf;
  border-color: #f0d48c;
  color: #73510b;
}

.progress-completed {
  background: #e6f7ef;
  border-color: #a6dec1;
  color: #0b5d3f;
}

.progress-on-track {
  background: #edf4f0;
  border-color: #c9ddd4;
  color: #244f3f;
}

.booking-grid {
  display: grid;
  gap: 10px;
}

.booking-card {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(180px, 0.55fr) auto;
  gap: 12px;
  align-items: center;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fbfdfc;
}

.booking-card h3 {
  margin: 8px 0 6px;
}

.booking-card p {
  margin: 0;
  color: var(--muted);
}

.booking-meta {
  display: grid;
  gap: 4px;
}

.booking-meta span,
.status-pill.small {
  color: var(--muted);
  font-size: 12px;
  font-weight: 850;
}

.status-pill.small {
  display: inline-block;
  width: fit-content;
  padding: 5px 8px;
}

.plan-pack {
  display: grid;
  gap: 10px;
  line-height: 1.45;
}

.plan-pack p {
  margin: 0;
}

.billing-plan-grid,
.billing-addon-grid,
.billing-revenue-grid {
  display: grid;
  gap: 10px;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  margin: 18px 0;
}

.billing-revenue-grid {
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

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

.panel-subtitle {
  align-items: center;
  display: flex;
  justify-content: space-between;
  gap: 12px;
  margin-top: 18px;
}

.panel-subtitle h3 {
  margin: 0;
}

.panel-subtitle span {
  color: var(--brand-2);
  font-weight: 900;
}

.addon-bundle-row {
  align-items: center;
  display: flex;
  gap: 12px;
  justify-content: space-between;
  margin-top: 8px;
}

.addon-bundle-row p {
  margin: 0;
}

.billing-plan-option,
.billing-addon-option {
  align-items: flex-start;
  background: #fff;
  border: 1px solid var(--line);
  display: flex;
  gap: 6px;
  min-height: 132px;
  padding: 14px;
  text-align: left;
  white-space: normal;
}

.billing-plan-option {
  flex-direction: column;
}

.billing-addon-option {
  cursor: pointer;
  min-height: 104px;
}

.billing-addon-option input {
  margin-top: 4px;
}

.billing-addon-option span {
  display: grid;
  gap: 5px;
}

.billing-plan-option span {
  color: var(--brand-2);
  font-weight: 900;
}

.billing-plan-option .web-price {
  color: var(--primary);
}

.web-discount-banner {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  padding: 12px;
  border: 1px solid #8ed7b4;
  border-radius: 6px;
  background: #edfff5;
  color: #064e3b;
}

.web-discount-banner span {
  color: #37665a;
}

.billing-plan-option em,
.billing-addon-option em {
  color: var(--ink);
  font-size: 13px;
  font-style: normal;
  font-weight: 800;
}

.billing-plan-option small,
.billing-addon-option small {
  color: var(--muted);
  font-size: 13px;
  line-height: 1.35;
}

.billing-plan-option.active,
.billing-addon-option.active {
  border-color: rgba(11, 61, 46, 0.52);
  box-shadow: inset 0 0 0 1px rgba(11, 61, 46, 0.2);
}

.link-list {
  display: grid;
  gap: 6px;
}

.link-list a {
  color: var(--brand-2);
  overflow-wrap: anywhere;
}

.plan-resource-button {
  justify-content: flex-start;
  width: 100%;
  color: var(--brand);
  text-align: left;
  overflow-wrap: anywhere;
}

.list-row strong, .list-row span {
  display: block;
}

.usage-meter {
  border: 1px solid var(--line);
  border-radius: 8px;
  display: grid;
  gap: 8px;
  margin-bottom: 12px;
  padding: 12px;
  background: #fff;
}

.usage-meter-top {
  display: flex;
  justify-content: space-between;
  gap: 10px;
}

.usage-meter-top span,
.usage-meter p {
  color: var(--muted);
  margin: 0;
}

.usage-meter-track {
  background: #edf4f0;
  border-radius: 999px;
  height: 8px;
  overflow: hidden;
}

.usage-meter-track span {
  background: var(--brand-2);
  display: block;
  height: 100%;
}

.launch-checklist {
  display: grid;
  gap: 16px;
}

.launch-group {
  display: grid;
  gap: 10px;
}

.launch-group h3 {
  margin: 0;
}

.launch-test-panel {
  border-top: 1px solid var(--line);
  display: grid;
  gap: 12px;
  margin-top: 8px;
  padding-top: 16px;
}

.launch-test-panel h3 {
  margin: 0;
}

.beta-test-panel {
  background: #fbfdfc;
  border: 1px solid var(--line);
  border-radius: 8px;
  margin-bottom: 14px;
  padding: 14px;
}

.beta-test-summary {
  align-items: center;
  background: #edf7f1;
  border: 1px solid rgba(11, 61, 46, 0.14);
  border-radius: 8px;
  display: flex;
  gap: 12px;
  justify-content: space-between;
  padding: 12px;
}

.beta-test-summary strong {
  font-size: 20px;
}

.beta-test-summary span {
  color: var(--muted);
  font-weight: 800;
}

.phone-launch-panel {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 8px;
  margin-bottom: 14px;
  padding: 14px;
}

.phone-launch-summary {
  background: #edf7f1;
  border: 1px solid rgba(11, 61, 46, 0.14);
  border-radius: 8px;
  color: var(--brand);
  font-weight: 850;
  overflow-wrap: anywhere;
  padding: 12px;
}

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

.phone-launch-grid article {
  background: #fbfdfc;
  border: 1px solid var(--line);
  border-radius: 8px;
  display: grid;
  gap: 6px;
  padding: 12px;
}

.phone-launch-grid strong,
.phone-launch-grid p {
  margin: 0;
}

.phone-launch-grid p {
  color: var(--muted);
  line-height: 1.4;
}

.launch-item.warn span {
  background: #fff2cf;
  border-color: #f0d48c;
  color: #73510b;
}

.launch-warning {
  background: #fff2cf;
  border: 1px solid #f0d48c;
  border-radius: 8px;
  color: #73510b;
  display: grid;
  gap: 4px;
  margin-bottom: 14px;
  padding: 12px;
}

.launch-warning.ok {
  background: #e6f7ef;
  border-color: #a6dec1;
  color: #0b5d3f;
}

.launch-warning span {
  font-weight: 750;
}

.launch-config-panel {
  margin-bottom: 16px;
}

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

.launch-config-item {
  background: #fff;
  border: 1px solid #f0d48c;
  border-radius: 8px;
  display: grid;
  gap: 6px;
  padding: 12px;
}

.launch-config-item.ready {
  border-color: #a6dec1;
}

.launch-config-item span {
  color: #73510b;
  font-size: 11px;
  font-weight: 950;
  text-transform: uppercase;
}

.launch-config-item.ready span {
  color: #0b5d3f;
}

.launch-config-item strong,
.launch-config-item p {
  margin: 0;
}

.launch-config-item p {
  color: var(--muted);
  font-size: 13px;
  line-height: 1.4;
}

.launch-item {
  align-items: center;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 8px;
  display: flex;
  gap: 12px;
  padding: 12px;
}

.launch-item span {
  border: 1px solid var(--line);
  border-radius: 999px;
  color: var(--muted);
  flex: 0 0 auto;
  font-size: 12px;
  font-weight: 900;
  padding: 5px 8px;
}

.launch-item.done span {
  background: #e6f7ef;
  border-color: rgba(11, 61, 46, 0.18);
  color: var(--brand-2);
}

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

.policy-grid article {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 12px;
}

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

.button-link {
  align-items: center;
  border: 1px solid var(--line);
  border-radius: 999px;
  color: var(--ink);
  display: inline-flex;
  font-weight: 850;
  min-height: 40px;
  padding: 0 14px;
  text-decoration: none;
}

.list-stat {
  text-align: right;
  flex: 0 0 auto;
}

.arr-card {
  display: grid;
  gap: 4px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fbfdfc;
  margin-top: 8px;
}

.insight-box {
  display: grid;
  gap: 8px;
  color: var(--ink);
  line-height: 1.45;
}

.insight-box > p {
  margin: 0;
  padding: 10px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fbfdfc;
}

.ai-panel {
  background: linear-gradient(145deg, #102f28 0%, #0f4234 62%, #165844 100%);
  border-color: rgba(255, 255, 255, 0.12);
  color: #fff;
}

.ai-panel .eyebrow,
.ai-panel h2 {
  color: #fff;
}

.ai-panel button {
  background: rgba(255, 255, 255, 0.12);
  border-color: rgba(255, 255, 255, 0.24);
  color: #fff;
}

.ai-brief {
  display: grid;
  gap: 12px;
}

.ai-brief-top {
  align-items: center;
  display: flex;
  gap: 10px;
}

.ai-brief-top strong {
  display: block;
  font-size: 18px;
}

.ai-brief-top span:not(.ai-orb) {
  color: rgba(255, 255, 255, 0.72);
}

.ai-orb {
  align-items: center;
  background: #baf7d2;
  border-radius: 999px;
  color: #10382e;
  display: inline-flex;
  flex: 0 0 auto;
  font-size: 12px;
  font-weight: 950;
  height: 38px;
  justify-content: center;
  width: 38px;
}

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

.ai-data-strip {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.ai-data-strip span {
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 999px;
  color: rgba(255, 255, 255, 0.72);
  font-size: 11px;
  font-weight: 900;
  padding: 5px 8px;
}

.ai-data-strip .ai-quality {
  color: #10382e;
}

.ai-quality-strong {
  background: #baf7d2 !important;
  border-color: #baf7d2 !important;
}

.ai-quality-medium {
  background: #ffe6a8 !important;
  border-color: #ffe6a8 !important;
}

.ai-quality-thin {
  background: #ffc9c9 !important;
  border-color: #ffc9c9 !important;
}

.ai-metric-grid span {
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 8px;
  color: rgba(255, 255, 255, 0.74);
  padding: 9px;
}

.ai-metric-grid strong {
  color: #fff;
  display: block;
}

.ai-chip-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.ai-chip-row span {
  background: rgba(255, 255, 255, 0.12);
  border-radius: 999px;
  color: #fff;
  font-size: 12px;
  font-weight: 900;
  padding: 6px 9px;
}

.ai-brief p {
  color: #fff;
  font-size: 15px;
  font-weight: 850;
  margin: 0;
}

.ai-next-action {
  background: #baf7d2;
  border-radius: 8px;
  color: #10382e;
  font-weight: 950;
  padding: 10px;
}

.ai-answer-card,
.ai-answer,
.ai-answer-head {
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 8px;
  color: #fff;
  display: grid;
  gap: 5px;
  padding: 10px;
}

.ai-answer-list {
  display: grid;
  gap: 8px;
  margin-top: 8px;
}

.ai-answer.pending {
  opacity: 0.72;
}

.ai-answer span {
  color: rgba(255, 255, 255, 0.78);
}

.ai-answer small {
  color: rgba(255, 255, 255, 0.54);
  font-size: 11px;
  font-weight: 850;
}

.ai-answer-head {
  align-items: center;
  display: flex;
  justify-content: space-between;
  margin-top: 10px;
}

.ai-answer-head span {
  color: rgba(255, 255, 255, 0.72);
  font-size: 12px;
  font-weight: 900;
}

.ai-answer-head button {
  min-height: 30px;
  padding-inline: 10px;
  width: auto;
}

.ai-disclaimer {
  color: rgba(255, 255, 255, 0.58);
  font-size: 11px;
  font-weight: 800;
  line-height: 1.35;
  margin: 10px 0 0;
}

.ai-ask {
  display: grid;
  gap: 8px;
  grid-template-columns: minmax(0, 1fr) auto;
  margin-top: 12px;
}

.ai-ask input {
  background: rgba(255, 255, 255, 0.12);
  border-color: rgba(255, 255, 255, 0.22);
  color: #fff;
  min-height: 40px;
}

.ai-ask input::placeholder {
  color: rgba(255, 255, 255, 0.56);
}

.ai-ask button {
  min-height: 40px;
  padding-inline: 14px;
  width: auto;
}

.ai-suggestions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 8px;
}

.ai-suggestions button {
  background: rgba(255, 255, 255, 0.08);
  border-color: rgba(255, 255, 255, 0.18);
  color: rgba(255, 255, 255, 0.86);
  font-size: 12px;
  min-height: 34px;
  padding-inline: 10px;
  width: auto;
}

.ai-action-list {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 10px;
}

.ai-action-list button {
  background: #fff;
  border-color: rgba(255, 255, 255, 0.28);
  color: var(--brand);
  font-size: 12px;
  min-height: 34px;
  padding-inline: 10px;
  width: auto;
}

.ai-action-list span {
  color: rgba(255, 255, 255, 0.7);
  font-size: 13px;
  font-weight: 800;
}

.ai-risk-list,
.ai-question-list {
  display: grid;
  gap: 8px;
}

.ai-risk-list article {
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 8px;
  display: grid;
  gap: 3px;
  padding: 9px;
}

.ai-risk-list strong {
  color: #fff;
}

.ai-risk-list span,
.ai-question-list span {
  color: rgba(255, 255, 255, 0.72);
}

.ai-question-list span {
  border-left: 3px solid #baf7d2;
  padding-left: 9px;
}

.ai-brief small {
  color: rgba(255, 255, 255, 0.68);
}

.ai-brief.empty strong,
.ai-brief.empty span {
  color: #fff;
}

.mini-row {
  padding: 10px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fbfdfc;
  color: var(--muted);
  font-weight: 850;
}

.worker-phone {
  max-width: 520px;
  margin: 0 auto;
}

.worker-phone h2 {
  font-size: 32px;
}

.compact-title {
  margin-bottom: 8px;
}

.compact-title span {
  color: var(--muted);
  font-size: 13px;
  font-weight: 900;
}

.worker-ready-card {
  background: #fbfdfc;
  border: 1px solid var(--line);
  border-radius: 8px;
  display: grid;
  gap: 6px;
  margin: 10px 0;
  padding: 12px;
}

.worker-ready-list {
  display: grid;
  gap: 6px;
}

.worker-ready-item {
  align-items: center;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 8px;
  display: grid;
  gap: 8px;
  grid-template-columns: auto minmax(0, 1fr);
  padding: 9px;
}

.worker-ready-item span {
  border-radius: 999px;
  color: #73510b;
  background: #fff2cf;
  font-size: 11px;
  font-weight: 950;
  padding: 4px 7px;
  text-transform: uppercase;
}

.worker-ready-item.done span {
  background: #e6f7ef;
  color: var(--brand-2);
}

.worker-ready-item strong,
.worker-ready-item small {
  display: block;
}

.worker-ready-item small {
  color: var(--muted);
  font-weight: 800;
  line-height: 1.35;
}

.clock-card {
  background: #eef7f2;
  border: 1px solid rgba(11, 61, 46, 0.14);
  border-radius: 8px;
  display: grid;
  gap: 10px;
  margin: 10px 0;
  padding: 12px;
}

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

.clock-summary span {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 8px;
  color: var(--muted);
  padding: 10px;
}

.clock-summary strong {
  color: var(--ink);
  display: block;
  font-size: 20px;
}

.geo-card {
  background: rgba(255, 255, 255, 0.72);
  border: 1px solid rgba(11, 61, 46, 0.12);
  border-radius: 8px;
  display: grid;
  gap: 10px;
  padding: 10px;
}

.geo-card > div:first-child {
  display: grid;
  gap: 3px;
}

.submit-receipt {
  background: #e6f7ef;
  border: 1px solid #a6dec1;
  border-radius: 8px;
  color: #0b5d3f;
  display: grid;
  gap: 4px;
  margin: 10px 0;
  padding: 10px;
}

.submit-receipt span {
  font-size: 13px;
  font-weight: 800;
}

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

.proof-summary span {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 8px;
  color: var(--muted);
  overflow-wrap: anywhere;
  padding: 10px;
}

.proof-summary strong {
  color: var(--ink);
  display: block;
}

.report-panel {
  max-width: 980px;
  margin: 0 auto;
}

.payroll-report-panel {
  margin-top: 14px;
}

.payroll-preview-table {
  margin-top: 14px;
}

.button-row.compact {
  margin-top: 0;
}

.button-row.compact button {
  width: auto;
  flex: 0 0 auto;
  padding-inline: 12px;
}

.report-sheet {
  display: grid;
  gap: 14px;
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
}

.report-head {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  align-items: flex-start;
  border-bottom: 1px solid var(--line);
  padding-bottom: 12px;
}

.report-head h2 {
  margin: 0;
}

.report-head strong {
  font-size: 28px;
}

.report-head span {
  color: var(--muted);
  display: block;
  font-size: 12px;
  font-weight: 850;
  margin-top: 4px;
}

.report-attention {
  border: 1px solid var(--line);
  border-radius: 8px;
  display: grid;
  gap: 4px;
  padding: 10px;
}

.report-attention.ok {
  background: #e6f7ef;
  border-color: #a6dec1;
  color: #0b5d3f;
}

.report-attention.warn {
  background: #fff2cf;
  border-color: #f0d48c;
  color: #73510b;
}

.report-attention span {
  font-size: 13px;
  font-weight: 750;
}

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

.report-table th,
.report-table td {
  padding: 10px;
  border-bottom: 1px solid var(--line);
  text-align: left;
  vertical-align: top;
}

.report-table td span {
  display: block;
  color: var(--muted);
  font-size: 12px;
  margin-top: 3px;
}

.button-row {
  display: flex;
  gap: 8px;
  margin-top: 10px;
}

.button-row button { flex: 1; }

.billing-panel {
  max-width: 620px;
}

.action-bar {
  position: fixed;
  left: 50%;
  bottom: 0;
  z-index: 6;
  display: grid;
  grid-template-columns: 1.15fr repeat(4, 0.9fr);
  gap: 8px;
  width: min(1180px, 100%);
  transform: translateX(-50%);
  padding: 10px 16px max(10px, env(safe-area-inset-bottom));
  border-top: 1px solid rgba(217, 226, 221, 0.86);
  background: rgba(246, 248, 251, 0.94);
  backdrop-filter: blur(14px);
}

dialog {
  width: min(430px, calc(100vw - 24px));
  max-height: min(760px, calc(100dvh - 32px));
  border: 0;
  border-radius: 8px;
  margin: auto;
  overflow: hidden;
  padding: 0;
  box-shadow: var(--shadow);
}

dialog::backdrop { background: rgba(16, 24, 32, 0.35); }

#jobDialog {
  width: min(760px, calc(100vw - 24px));
}

.dialog-card {
  display: grid;
  gap: 12px;
  max-height: min(760px, calc(100dvh - 32px));
  overflow: auto;
  padding: 16px;
}

.dialog-card > h2 {
  position: sticky;
  top: -16px;
  z-index: 3;
  margin: 0 -16px;
  padding: 16px 16px 12px;
  border-bottom: 1px solid var(--line);
  background: #fff;
}

.dialog-card > .button-row {
  position: sticky;
  bottom: -16px;
  z-index: 2;
  margin: 0 -16px -16px;
  padding: 12px 16px 16px;
  border-top: 1px solid var(--line);
  background: #fff;
}

.legal-consent {
  display: grid;
  grid-template-columns: 20px minmax(0, 1fr);
  align-items: start;
  gap: 10px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: #f7faf8;
}

.legal-consent input {
  width: 18px;
  height: 18px;
  margin: 2px 0 0;
}

.legal-consent span {
  line-height: 1.45;
}

.legal-consent a {
  color: var(--primary);
  font-weight: 700;
}

.confirm-card {
  gap: 14px;
}

.confirm-card h2,
.confirm-card p {
  margin: 0;
}

.confirm-card #confirmMessage {
  white-space: pre-line;
}

.toast {
  position: fixed;
  left: 50%;
  bottom: 86px;
  z-index: 9;
  max-width: calc(100vw - 32px);
  transform: translateX(-50%) translateY(18px);
  opacity: 0;
  pointer-events: none;
  border-radius: 999px;
  background: #101820;
  color: #fff;
  padding: 10px 12px;
  font-size: 13px;
  font-weight: 850;
  transition: opacity 160ms ease, transform 160ms ease;
}

.toast.show {
  opacity: 1;
  transform: translateX(-50%) translateY(0);
}

.policy-page { background: var(--bg); }

.policy {
  width: min(760px, 100%);
  margin: 0 auto;
  padding: 28px 16px;
  line-height: 1.55;
}

.back-link {
  color: var(--brand-2);
  font-weight: 900;
  text-decoration: none;
}

.admin-command-bar {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 20px;
  padding: 4px 2px 18px;
}

.admin-command-bar h2,
.admin-attention-panel h2,
.admin-audit-panel h2 { margin-bottom: 0; }

.admin-command-bar .muted-copy { margin-bottom: 0; }

.admin-metric-band {
  margin-bottom: 16px;
  overflow: hidden;
  border: 1px solid #c9d8d0;
  border-radius: 8px;
  background: #fff;
  box-shadow: 0 10px 28px rgba(16, 24, 32, 0.06);
}

.admin-metric-grid {
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
}

.admin-metric {
  display: grid;
  align-content: center;
  min-height: 112px;
  padding: 16px;
  border-right: 1px solid var(--line);
}

.admin-metric:last-child { border-right: 0; }

.admin-metric span,
.admin-metric small {
  color: var(--muted);
  font-size: 11px;
  font-weight: 800;
}

.admin-metric strong {
  margin: 4px 0;
  font-size: 25px;
  line-height: 1;
}

.admin-metric-money {
  background: var(--brand);
  color: #fff;
}

.admin-metric-money span,
.admin-metric-money small { color: #cae3d8; }

.admin-operations-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.7fr) minmax(330px, 0.8fr);
  gap: 16px;
  align-items: start;
}

.admin-attention-panel,
.admin-directory-panel { grid-column: 1; }

.admin-collapse-panel {
  display: block;
}

.admin-collapse-summary {
  align-items: center;
  cursor: pointer;
  display: flex;
  gap: 12px;
  justify-content: space-between;
  list-style: none;
}

.admin-collapse-summary::-webkit-details-marker {
  display: none;
}

.admin-collapse-summary::after {
  color: var(--brand);
  content: "Open";
  font-size: 12px;
  font-weight: 900;
  text-transform: uppercase;
}

.admin-collapse-panel[open] .admin-collapse-summary {
  margin-bottom: 12px;
}

.admin-collapse-panel[open] .admin-collapse-summary::after {
  content: "Close";
}

.admin-collapse-summary span {
  display: grid;
  gap: 3px;
}

.admin-collapse-summary strong {
  font-size: 18px;
}

.admin-collapse-summary em {
  color: var(--muted);
  font-style: normal;
  font-weight: 850;
}

.admin-attention-panel {
  display: grid;
  grid-template-columns: minmax(180px, 0.32fr) minmax(0, 1fr);
  gap: 18px;
}

.admin-attention-list {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
}

.admin-attention-item {
  display: grid;
  grid-template-columns: 10px minmax(0, 1fr) auto;
  align-items: center;
  gap: 10px;
  min-height: 64px;
  padding: 10px;
  text-align: left;
}

.admin-attention-item span:nth-child(2) {
  display: grid;
  gap: 3px;
  min-width: 0;
}

.admin-attention-item strong,
.admin-attention-item small {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.admin-attention-item small {
  color: var(--muted);
  font-size: 11px;
}

.admin-attention-item em {
  color: var(--brand-2);
  font-size: 11px;
  font-style: normal;
}

.admin-health-dot,
.admin-health i {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #2f855a;
}

.admin-attention-item.critical .admin-health-dot,
.admin-health.critical i { background: var(--danger); }

.admin-attention-item.watch .admin-health-dot,
.admin-health.watch i { background: var(--accent); }

.admin-all-clear {
  display: grid;
  align-content: center;
  min-height: 64px;
  padding: 12px;
  border: 1px solid #b9dec9;
  border-radius: 8px;
  background: #eefaf3;
}

.admin-all-clear span {
  color: var(--muted);
  font-size: 12px;
}

.admin-filter-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 190px;
  gap: 10px;
  margin-bottom: 12px;
}

.admin-customer-table {
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 8px;
}

.admin-customer-header,
.admin-customer-row {
  display: grid;
  grid-template-columns: minmax(190px, 1.35fr) minmax(100px, 0.6fr) minmax(150px, 0.9fr) minmax(130px, 0.8fr) 54px;
  align-items: center;
  gap: 12px;
}

.admin-customer-header {
  padding: 9px 12px;
  background: #edf3f0;
  color: var(--muted);
  font-size: 10px;
  font-weight: 900;
  text-transform: uppercase;
}

.admin-customer-row {
  width: 100%;
  min-height: 68px;
  padding: 10px 12px;
  border: 0;
  border-top: 1px solid var(--line);
  border-radius: 0;
  text-align: left;
}

.admin-customer-row:hover,
.admin-customer-row.active { background: #f0f7f3; }

.admin-customer-row.active { box-shadow: inset 3px 0 var(--brand-2); }

.admin-customer-row > span,
.admin-customer-name {
  display: grid;
  gap: 3px;
  min-width: 0;
}

.admin-customer-row small {
  overflow: hidden;
  color: var(--muted);
  font-size: 11px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.admin-health {
  display: flex !important;
  align-items: center;
  justify-content: start;
  gap: 7px !important;
  color: var(--muted);
  font-size: 11px;
}

.admin-row-arrow {
  color: var(--brand-2);
  font-size: 11px;
  text-align: right;
}

.admin-support-column {
  position: sticky;
  top: 86px;
  grid-column: 2;
  grid-row: 1 / span 2;
  display: grid;
  gap: 16px;
}

.admin-customer-detail,
.admin-control-form {
  display: grid;
  gap: 10px;
}

.admin-detail-identity { display: grid; gap: 3px; }

.admin-detail-identity span,
.admin-empty-detail span {
  color: var(--muted);
  font-size: 12px;
}

.admin-detail-alert {
  display: grid;
  gap: 2px;
  padding: 10px;
  border: 1px solid #efc3bf;
  border-radius: 6px;
  background: #fff1ef;
  color: #812018;
  font-size: 12px;
}

.admin-detail-alert.healthy {
  border-color: #b9dec9;
  background: #eefaf3;
  color: #185c39;
}

.admin-detail-metrics {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 6px;
}

.admin-detail-metrics span {
  display: grid;
  gap: 3px;
  min-width: 0;
  padding: 8px;
  border: 1px solid var(--line);
  border-radius: 6px;
  color: var(--muted);
  font-size: 10px;
}

.admin-detail-metrics strong {
  overflow: hidden;
  color: var(--ink);
  font-size: 13px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.admin-control-form {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  margin: 14px 0 10px;
  padding-top: 14px;
  border-top: 1px solid var(--line);
}

.admin-control-form label:last-child { grid-column: 1 / -1; }

.admin-empty-detail {
  display: grid;
  gap: 3px;
  padding: 14px;
  border: 1px dashed var(--line);
  border-radius: 6px;
}

.admin-audit-panel .list-stack {
  max-height: 280px;
  overflow: auto;
}

.admin-incidents-panel .list-stack {
  max-height: 300px;
  overflow: auto;
}

.admin-incident {
  border-left: 3px solid var(--danger);
}

.admin-incident.feedback {
  border-left-color: var(--accent);
}

.report-problem-button {
  position: fixed;
  right: max(14px, env(safe-area-inset-right));
  bottom: max(14px, env(safe-area-inset-bottom));
  z-index: 7;
  min-height: 40px;
  padding: 9px 12px;
  border-color: rgba(11, 61, 46, 0.34);
  background: #fff;
  color: var(--brand);
  box-shadow: 0 8px 24px rgba(16, 24, 32, 0.14);
  font-size: 12px;
}

.feedback-card {
  width: min(520px, calc(100vw - 28px));
}

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

.plan-viewer-page {
  background: var(--bg);
  overflow: hidden;
}

.plan-viewer-header,
.plan-viewer-title,
.plan-viewer-actions {
  display: flex;
  align-items: center;
}

.plan-viewer-header {
  justify-content: space-between;
  gap: 12px;
  min-height: 68px;
  padding: 12px 16px;
  border-bottom: 1px solid var(--line);
  background: var(--panel);
}

.plan-viewer-actions {
  gap: 8px;
}

.plan-viewer-main {
  display: grid;
  grid-template-rows: auto minmax(0, 1fr);
  height: calc(100vh - 68px);
}

.plan-viewer-title {
  justify-content: space-between;
  gap: 16px;
  padding: 12px 16px;
}

.plan-viewer-title h1 {
  margin: 0;
  font-size: 24px;
  line-height: 1.1;
}

.plan-viewer-title p {
  margin: 0;
  color: var(--muted);
}

#planViewerFrame {
  width: 100%;
  height: 100%;
  min-height: 0;
  border: 0;
  background: #fff;
}

.plan-viewer-fallback {
  position: fixed;
  right: 16px;
  bottom: 16px;
  max-width: 380px;
  border: 1px solid var(--line);
  background: var(--panel);
  box-shadow: var(--shadow);
}

.founding-offer-callout {
  display: grid;
  gap: 4px;
  padding: 12px;
  border: 1px solid #b8e1cf;
  border-radius: 6px;
  background: #eefaf4;
  color: var(--brand);
}

.pricing-founding-offer { margin-bottom: 14px; }
.pricing-currency-note { margin: 12px 0 0; color: var(--muted); font-size: 13px; }

.founding-claim-panel {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(180px, 260px) auto;
  align-items: end;
  gap: 10px;
  margin: 12px 0;
  padding: 12px;
  border: 1px solid #b8e1cf;
  border-radius: 6px;
  background: #eefaf4;
}

.founding-claim-panel > div { display: grid; gap: 4px; color: var(--brand); }
.founding-country-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; max-height: 520px; overflow: auto; padding-right: 4px; }
.founding-country-card { display: grid; gap: 5px; padding: 12px; border: 1px solid var(--line); border-radius: 6px; background: var(--panel); }
.founding-country-card span { color: var(--muted); }
.industry-funnel-grid { display: grid; gap: 8px; }
.industry-funnel-card { display: grid; grid-template-columns: minmax(200px, 1fr) 2fr; gap: 12px; padding: 12px; border: 1px solid var(--line); border-radius: 6px; background: var(--panel); }
.industry-funnel-card > div:first-child { display: grid; gap: 4px; }
.industry-funnel-card span { color: var(--muted); }
.industry-funnel-stages { display: grid; grid-template-columns: repeat(6, minmax(64px, 1fr)); gap: 6px; }
.industry-funnel-stages span { display: grid; gap: 2px; padding: 8px; border-radius: 5px; background: var(--soft); font-size: 12px; }
.industry-funnel-stages strong { color: var(--ink); font-size: 17px; }

[hidden] { display: none !important; }

html[data-marketing-recording="true"] .report-problem-button,
html[data-marketing-recording="true"] #hardLogoutBtn,
html[data-marketing-recording="true"] #logoutBtn,
html[data-marketing-recording="true"] #rolePreviewBtn { display: none !important; }

html[data-marketing-recording="true"] .topbar {
  position: sticky;
  top: 0;
  z-index: 8;
  box-shadow: 0 4px 16px rgba(16, 24, 32, 0.08);
}

@media (max-width: 960px) {
  .topbar { align-items: flex-start; flex-direction: column; }
  .public-nav, .app-nav { justify-content: flex-start; width: 100%; max-width: 100%; }
  .hero, .main-grid, .toolbar { grid-template-columns: 1fr; }
  .summary-grid, .value-band, .price-grid, .billing-plan-grid, .billing-addon-grid, .billing-revenue-grid, .launch-config-grid, .onboarding-list, .payroll-preview-grid { grid-template-columns: repeat(2, 1fr); }
  .metric.primary { grid-column: 1 / -1; }
  .day-row { grid-template-columns: repeat(2, 1fr); }
  .day-name, .day-total { grid-column: 1 / -1; }
  .day-total {
    display: flex;
    justify-content: space-between;
    text-align: left;
    padding-top: 8px;
    border-top: 1px solid var(--line);
  }
  .admin-metric-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .admin-metric:nth-child(3) { border-right: 0; }
  .admin-metric:nth-child(-n + 3) { border-bottom: 1px solid var(--line); }
  .admin-operations-grid { grid-template-columns: 1fr; }
  .admin-support-column {
    position: static;
    grid-column: 1;
    grid-row: auto;
  }
}

@media (max-width: 600px) {
  h1 { font-size: 38px; }
  .marketing, .app-shell { padding-inline: 12px; }
  .panel-title {
    align-items: flex-start;
    flex-direction: column;
  }
  .panel-title .button-row,
  .button-row {
    flex-wrap: wrap;
    width: 100%;
  }
  .panel-title .button-row button,
  .button-row button,
  .button-row.compact button {
    flex: 1 1 140px;
    min-width: 0;
  }
  .summary-grid, .value-band, .price-grid, .billing-plan-grid, .billing-addon-grid, .billing-revenue-grid, .launch-config-grid, .onboarding-list, .policy-grid, .proof-summary, .payroll-preview-grid, .rate-grid, .day-row { grid-template-columns: 1fr; }
  .onboarding-item { grid-template-columns: 1fr; }
  .hero { min-height: auto; padding-top: 18px; }
  .hero-product { min-width: 0; }
  .workspace-bar { align-items: flex-start; flex-direction: column; }
  .workspace-actions { justify-content: flex-start; }
  .billing-status-banner { align-items: flex-start; flex-direction: column; }
  .approval-item { grid-template-columns: 1fr; }
  .action-bar {
    grid-template-columns: repeat(5, 1fr);
    gap: 5px;
    padding-inline: 8px;
  }
  .action-bar button {
    min-width: 0;
    padding-inline: 4px;
    font-size: 12px;
  }
  .addon-bundle-row {
    align-items: flex-start;
    flex-direction: column;
  }
  .list-row {
    align-items: flex-start;
    flex-direction: column;
  }
  .booking-card {
    grid-template-columns: 1fr;
    align-items: flex-start;
  }
  .list-stat { text-align: left; }
  .admin-command-bar,
  .admin-attention-panel {
    align-items: stretch;
    flex-direction: column;
    grid-template-columns: 1fr;
  }
  .admin-command-bar { display: flex; }
  .admin-command-bar .button-row { width: 100%; }
  .admin-command-bar .button-row button { flex: 1; }
  .admin-metric-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .admin-metric { min-height: 100px; padding: 12px; }
  .admin-metric:nth-child(2n) { border-right: 0; }
  .admin-metric:nth-child(3) { border-right: 1px solid var(--line); }
  .admin-metric:nth-child(-n + 4) { border-bottom: 1px solid var(--line); }
  .admin-attention-list { grid-template-columns: 1fr; }
  .admin-filter-row { grid-template-columns: 1fr; }
  .admin-customer-header { display: none; }
  .admin-customer-row {
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 8px;
  }
  .admin-customer-row > span:nth-child(3),
  .admin-customer-row > span:nth-child(4) { display: none !important; }
  .admin-row-arrow { grid-column: 2; grid-row: 1 / span 2; align-self: center; }
  .admin-detail-metrics { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .admin-control-form { grid-template-columns: 1fr; }
  .admin-control-form label:last-child { grid-column: auto; }
  .report-problem-button {
    right: 10px;
    bottom: calc(72px + env(safe-area-inset-bottom));
  }
  .plan-viewer-header,
  .plan-viewer-title {
    align-items: flex-start;
    flex-direction: column;
  }
  .plan-viewer-main {
    height: calc(100vh - 132px);
  }
  .plan-viewer-fallback {
    right: 10px;
    bottom: 10px;
    left: 10px;
    max-width: none;
  }
  .founding-claim-panel, .founding-country-grid { grid-template-columns: 1fr; align-items: stretch; }
  .industry-funnel-card { grid-template-columns: 1fr; }
  .industry-funnel-stages { grid-template-columns: repeat(3, 1fr); }
}

@media print {
  body {
    background: #fff;
  }
  .topbar,
  .workspace-bar,
  .app-panel-view:not(#reportsView),
  .panel-title button,
  .toast {
    display: none !important;
  }
  .app-shell {
    padding: 0;
  }
  .panel,
  .report-sheet {
    box-shadow: none;
    border: 0;
  }
}
