:root {
  color-scheme: light;
  --bg: #f4f7f3;
  --surface: #ffffff;
  --ink: #171717;
  --muted: #5e625d;
  --line: #d8ded6;
  --green: #1f6f54;
  --green-dark: #174a3d;
  --gold: #b97820;
  --red: #a33d32;
  --blue: #294a7a;
  --shadow: 0 18px 50px rgba(22, 24, 24, 0.08);
}

* {
  box-sizing: border-box;
}

[hidden] {
  display: none !important;
}

body {
  margin: 0;
  padding-bottom: 118px;
  background: var(--bg);
  color: var(--ink);
  font-family:
    Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI",
    sans-serif;
  line-height: 1.5;
}

a {
  color: inherit;
}

button,
input,
select {
  font: inherit;
}

.topbar {
  position: sticky;
  top: 0;
  z-index: 5;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  min-height: 64px;
  padding: 0 28px;
  border-bottom: 1px solid var(--line);
  background: rgba(244, 247, 243, 0.94);
  backdrop-filter: blur(12px);
}

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

.brand-mark {
  display: inline-grid;
  width: 34px;
  height: 34px;
  place-items: center;
  border-radius: 7px;
  background: var(--ink);
  color: var(--surface);
  font-weight: 800;
}

.topnav {
  display: none;
  gap: 20px;
  color: var(--muted);
  font-size: 0.94rem;
}

.topnav a {
  text-decoration: none;
}

.language-control {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin: 0;
  color: var(--muted);
  font-size: 0.84rem;
  font-weight: 720;
}

.language-control select {
  width: auto;
  min-height: 34px;
  padding: 6px 26px 6px 9px;
  background-color: var(--surface);
  font-size: 0.86rem;
}

main {
  width: min(1120px, calc(100vw - 32px));
  margin: 0 auto;
  padding: 26px 0 54px;
}

.upload-hero {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 18px;
  align-items: stretch;
  min-height: min(620px, calc(100svh - 184px));
  padding: 24px 0 18px;
}

.eyebrow,
.kicker,
.status-label {
  display: block;
  margin: 0 0 8px;
  color: var(--green);
  font-size: 0.76rem;
  font-weight: 800;
  letter-spacing: 0;
  text-transform: uppercase;
}

h1,
h2,
p {
  margin: 0;
}

h1 {
  max-width: 760px;
  margin: 0 auto;
  font-size: clamp(2.2rem, 4.5vw, 4.4rem);
  line-height: 1.02;
  text-align: center;
}

h2 {
  font-size: 1.1rem;
  line-height: 1.2;
}

.lead {
  max-width: 660px;
  margin-top: 16px;
  color: var(--muted);
  font-size: 1.1rem;
}

.upload-copy {
  display: grid;
  align-content: end;
  min-height: 90px;
}

.upload-shortcut {
  display: grid;
  gap: 12px;
  min-height: min(430px, 54svh);
  align-content: center;
  justify-items: center;
  margin: 0;
  padding: 30px;
  border: 2px dashed rgba(31, 111, 84, 0.45);
  border-radius: 8px;
  background: linear-gradient(180deg, #ffffff 0%, #eef7f0 100%);
  box-shadow: var(--shadow);
  color: var(--ink);
  text-align: center;
  cursor: pointer;
}

.upload-shortcut:hover {
  border-color: var(--green);
  background: linear-gradient(180deg, #ffffff 0%, #e7f2ec 100%);
}

.upload-shortcut input {
  position: absolute;
  width: 1px;
  height: 1px;
  opacity: 0;
}

body.upload-drag-active .upload-shortcut {
  border-color: var(--green-dark);
  background: #e6f4eb;
  box-shadow: 0 18px 70px rgba(31, 111, 84, 0.18);
}

.upload-icon {
  display: inline-grid;
  width: 58px;
  height: 58px;
  place-items: center;
  border-radius: 8px;
  background: var(--green-dark);
  color: var(--surface);
  font-size: 2rem;
  font-weight: 750;
  line-height: 1;
}

.upload-shortcut-title {
  max-width: 340px;
  font-size: 1.45rem;
  font-weight: 800;
}

.upload-shortcut-copy {
  max-width: 360px;
  color: var(--muted);
  font-size: 0.95rem;
  font-weight: 560;
}

.clerk-confirmations,
.clerk-requirements {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(190px, 1fr));
  gap: 12px;
  margin: 0 0 16px;
}

.clerk-confirmations[hidden],
.clerk-requirements[hidden] {
  display: none;
}

.confirmation-card,
.requirement-card {
  display: grid;
  gap: 6px;
  min-height: 106px;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface);
  box-shadow: var(--shadow);
}

.requirement-card {
  border-left: 4px solid var(--line);
}

.requirement-card[data-requirement-status="ready"] {
  border-left-color: var(--green);
}

.requirement-card[data-requirement-status="review"] {
  border-left-color: var(--blue);
}

.requirement-card[data-requirement-status="missing"],
.requirement-card[data-requirement-status="blocked"] {
  border-left-color: var(--gold);
}

.confirmation-card span,
.requirement-card span {
  color: var(--muted);
  font-size: 0.78rem;
  font-weight: 800;
  text-transform: uppercase;
}

.confirmation-card strong,
.requirement-card strong {
  display: block;
  font-size: 1.05rem;
}

.requirement-card p {
  color: var(--muted);
  font-size: 0.88rem;
}

.confirmation-card button,
.requirement-card button {
  justify-self: start;
  min-height: 32px;
  padding: 6px 10px;
  background: #edf2f6;
  color: var(--blue);
  font-size: 0.82rem;
}

.service-status-panel {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(360px, 0.92fr) auto;
  gap: 16px;
  align-items: center;
  margin: 0 0 18px;
  padding: 18px;
  border: 1px solid var(--line);
  border-left: 4px solid #7a5c21;
  border-radius: 8px;
  background: var(--surface);
  box-shadow: var(--shadow);
}

.service-status-panel[hidden] {
  display: none;
}

.service-status-panel[data-status="public_ready"] {
  border-left-color: var(--green);
}

.service-status-panel[data-status="blocked_launch_requirements"] {
  border-left-color: var(--red);
}

.service-status-panel p {
  margin-top: 6px;
  color: var(--muted);
}

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

.service-facts div {
  display: grid;
  gap: 3px;
  min-height: 68px;
  padding: 10px 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fbfaf7;
}

.service-facts dt {
  color: var(--muted);
  font-size: 0.76rem;
  font-weight: 800;
  text-transform: uppercase;
}

.service-facts dd {
  margin: 0;
  color: var(--ink);
  font-weight: 760;
  overflow-wrap: anywhere;
}

.service-action {
  min-width: 132px;
  margin-top: 0;
  text-align: center;
  text-decoration: none;
}

.app-grid {
  display: grid;
  grid-template-columns: minmax(230px, 0.8fr) minmax(340px, 1.25fr) minmax(280px, 0.95fr);
  gap: 16px;
  align-items: start;
}

.app-grid[data-focused="true"] {
  grid-template-columns: minmax(0, 760px);
  justify-content: center;
}

.app-grid[hidden],
.seo-summary[hidden] {
  display: none;
}

.app-grid[data-focused="true"] [data-workflow-panel] {
  display: none;
}

.app-grid[data-focused="true"][data-active-panel="case"] [data-workflow-panel="case"],
.app-grid[data-focused="true"][data-active-panel="documents"] [data-workflow-panel="documents"],
.app-grid[data-focused="true"][data-active-panel="costs"] [data-workflow-panel="costs"],
.app-grid[data-focused="true"][data-active-panel="triage"] [data-workflow-panel="triage"] {
  display: grid;
  grid-column: 1;
  order: 0;
}

.document-panel {
  order: -2;
  grid-column: span 2;
}

.intake-panel {
  order: -1;
}

.costs-panel {
  order: 1;
  grid-column: span 2;
}

.triage-panel {
  order: 2;
}

.panel {
  min-width: 0;
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface);
  box-shadow: var(--shadow);
}

.panel-heading {
  display: flex;
  min-height: 44px;
  align-items: start;
  justify-content: space-between;
  gap: 14px;
  margin-bottom: 16px;
}

label {
  display: grid;
  gap: 6px;
  margin-bottom: 14px;
  color: var(--muted);
  font-size: 0.9rem;
  font-weight: 650;
}

input,
select,
textarea {
  width: 100%;
  min-height: 42px;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: #fbfaf7;
  color: var(--ink);
  padding: 9px 10px;
}

input:focus,
select:focus,
textarea:focus,
button:focus-visible {
  outline: 3px solid rgba(31, 111, 84, 0.2);
  outline-offset: 2px;
}

textarea {
  resize: vertical;
}

.dropzone {
  display: grid;
  min-height: 176px;
  place-items: center;
  align-content: center;
  padding: 22px;
  border: 1px dashed rgba(31, 111, 84, 0.48);
  border-radius: 8px;
  background: #f7fbf8;
  text-align: center;
  cursor: pointer;
}

.dropzone-title {
  color: var(--ink);
  font-size: 1.05rem;
}

.dropzone-copy {
  margin-top: 4px;
  color: var(--muted);
  font-size: 0.86rem;
  font-weight: 500;
}

.doc-summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 44px;
  margin-top: 10px;
  color: var(--muted);
  font-size: 0.88rem;
}

.file-list {
  display: grid;
  gap: 8px;
  margin: 8px 0 0;
  padding: 0;
  list-style: none;
}

.file-list li {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  min-height: 38px;
  padding: 9px 10px;
  border: 1px solid var(--line);
  border-radius: 6px;
  color: var(--muted);
  font-size: 0.86rem;
}

.file-list li > div {
  display: grid;
  min-width: 0;
  gap: 2px;
}

.file-list strong {
  color: var(--ink);
  overflow-wrap: anywhere;
}

.file-status {
  flex: 0 0 auto;
  max-width: 48%;
  color: var(--blue);
  font-size: 0.78rem;
  font-weight: 760;
  text-align: right;
}

.file-status-needs_ocr,
.file-status-extraction_failed,
.file-status-skipped_too_large,
.file-status-unsupported_type {
  color: var(--red);
}

.text-capture {
  margin-top: 14px;
}

.human-correction {
  margin-top: 14px;
}

.acknowledgement-list {
  display: grid;
  gap: 10px;
  margin: 16px 0;
}

.acknowledgement-list label {
  display: grid;
  grid-template-columns: 18px 1fr;
  align-items: start;
  color: var(--ink);
  font-size: 0.84rem;
  font-weight: 620;
}

.acknowledgement-list input {
  width: 18px;
  min-height: 18px;
  margin-top: 2px;
  accent-color: var(--green);
}

.acknowledgement-list a {
  color: var(--green-dark);
  font-weight: 780;
}

.turnstile-check,
.access-gate-check {
  display: grid;
  gap: 12px;
  margin: 0 0 16px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: #f7f4ed;
}

.turnstile-check[hidden],
.access-gate-check[hidden] {
  display: none;
}

.turnstile-check strong {
  display: block;
  font-size: 0.86rem;
}

.turnstile-check p,
.access-gate-check p {
  margin: 4px 0 0;
  color: var(--muted);
  font-size: 0.8rem;
  line-height: 1.45;
}

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

.cost-table {
  width: 100%;
  border-collapse: collapse;
  min-width: 660px;
}

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

.cost-table th {
  color: var(--muted);
  font-size: 0.78rem;
  text-transform: uppercase;
}

.cost-table input {
  min-height: 36px;
}

.pill {
  display: inline-flex;
  align-items: center;
  min-height: 28px;
  padding: 4px 9px;
  border-radius: 999px;
  color: var(--surface);
  font-size: 0.78rem;
  font-weight: 760;
}

.warning {
  background: var(--gold);
}

.danger {
  background: var(--red);
}

.readiness-list {
  display: grid;
  gap: 10px;
  margin-bottom: 16px;
}

.readiness-list label {
  grid-template-columns: 18px 1fr;
  align-items: center;
  margin: 0;
  font-weight: 620;
}

.readiness-list input {
  width: 18px;
  min-height: 18px;
  accent-color: var(--green);
}

button {
  min-height: 40px;
  border: 1px solid transparent;
  border-radius: 6px;
  padding: 9px 13px;
  cursor: pointer;
  font-weight: 750;
}

.primary-button {
  width: 100%;
  background: var(--green-dark);
  color: var(--surface);
}

a.primary-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  text-decoration: none;
}

.secondary-button,
#clear-files {
  background: #efeee9;
  color: var(--ink);
}

.secondary-button {
  margin-top: 14px;
}

.packet-output {
  min-height: 172px;
  max-height: 520px;
  overflow: auto;
  margin: 14px 0 0;
  padding: 0;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: #fbfaf7;
  color: var(--ink);
  font-size: 0.86rem;
}

.seo-summary {
  display: grid;
  gap: 8px;
  max-width: 760px;
  margin: 34px 0 0;
  padding: 0 0 16px;
}

.seo-summary p {
  color: var(--muted);
}

.seo-discovery {
  display: grid;
  gap: 14px;
  margin: 42px 0 0;
  padding: 22px 0 0;
  border-top: 1px solid var(--line);
}

.seo-discovery h2 {
  max-width: 520px;
  font-size: 1.05rem;
}

.seo-discovery-links,
.seo-related-links {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.seo-discovery-links a,
.seo-related-links a {
  display: inline-flex;
  min-height: 34px;
  align-items: center;
  padding: 7px 10px;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: rgba(255, 255, 255, 0.72);
  color: var(--green-dark);
  font-size: 0.86rem;
  font-weight: 720;
  text-decoration: none;
}

body.seo-page {
  padding-bottom: 48px;
}

.seo-nav {
  display: flex;
  align-items: center;
  gap: 18px;
  color: var(--muted);
  font-size: 0.9rem;
  font-weight: 680;
}

.seo-nav a {
  text-decoration: none;
}

.seo-main {
  max-width: 980px;
  padding-top: 54px;
}

.seo-hero {
  display: grid;
  justify-items: center;
  gap: 16px;
  padding: 40px 0 38px;
  text-align: center;
}

.seo-lead {
  max-width: 720px;
  color: var(--muted);
  font-size: 1.08rem;
}

.seo-cta {
  width: auto;
  min-width: min(100%, 260px);
  min-height: 48px;
  margin-top: 8px;
  padding: 12px 18px;
}

.seo-panels {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
  margin-top: 12px;
}

.seo-panel,
.seo-faq {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface);
  box-shadow: var(--shadow);
}

.seo-panel {
  padding: 22px;
}

.seo-panel h2,
.seo-faq h2 {
  font-size: 1.18rem;
}

.seo-panel ul {
  display: grid;
  gap: 10px;
  margin: 16px 0 0;
  padding-left: 20px;
  color: var(--muted);
}

.seo-faq {
  display: grid;
  gap: 0;
  margin-top: 16px;
  padding: 22px;
}

.seo-faq details {
  border-top: 1px solid var(--line);
  padding: 14px 0;
}

.seo-faq details:first-of-type {
  margin-top: 14px;
}

.seo-faq summary {
  cursor: pointer;
  font-weight: 780;
}

.seo-faq p {
  margin-top: 8px;
  color: var(--muted);
}

.seo-related {
  display: grid;
  gap: 12px;
  margin-top: 20px;
  padding-top: 18px;
  border-top: 1px solid var(--line);
}

.seo-related h2 {
  font-size: 1.02rem;
}

.clerk-shell {
  position: fixed;
  right: auto;
  bottom: 16px;
  left: 50%;
  z-index: 20;
  display: grid;
  width: min(920px, calc(100vw - 32px));
  overflow: hidden;
  transform: translateX(-50%);
  border: 1px solid rgba(23, 23, 23, 0.12);
  border-radius: 8px;
  background: var(--surface);
  box-shadow: 0 16px 60px rgba(14, 22, 18, 0.16);
}

.clerk-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 12px 14px;
  border-bottom: 1px solid var(--line);
  background: #f9fbf8;
}

.clerk-header div {
  display: grid;
  gap: 2px;
}

.clerk-header strong {
  font-size: 0.94rem;
}

.clerk-header span {
  color: var(--muted);
  font-size: 0.78rem;
}

.clerk-toggle {
  min-height: 32px;
  padding: 6px 10px;
  background: #edf2f6;
  color: var(--blue);
  font-size: 0.8rem;
}

.clerk-thread {
  display: grid;
  gap: 8px;
  max-height: 190px;
  overflow: auto;
  padding: 12px 14px;
}

.clerk-message {
  width: fit-content;
  max-width: min(430px, 86%);
  padding: 9px 11px;
  border-radius: 8px;
  font-size: 0.9rem;
}

.clerk-message-assistant {
  background: #edf5ee;
  color: var(--green-dark);
}

.clerk-message-user {
  justify-self: end;
  background: #eef2f7;
  color: var(--blue);
}

.clerk-composer {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 8px;
  padding: 10px;
  border-top: 1px solid var(--line);
}

.clerk-composer input {
  min-height: 40px;
  background: #fbfcfb;
}

.clerk-composer button {
  min-width: 78px;
  background: var(--green-dark);
  color: var(--surface);
}

.clerk-shell[data-collapsed="true"] .clerk-thread {
  display: none;
}

.clerk-shell[data-collapsed="true"] .clerk-header {
  border-bottom: 0;
  padding-bottom: 0;
}

.clerk-shell[data-collapsed="true"] .clerk-header span {
  display: none;
}

.analysis-result {
  display: grid;
  gap: 14px;
  padding: 14px;
}

.analysis-summary {
  display: grid;
  gap: 6px;
  padding: 12px;
  border-radius: 6px;
  background: #eef4ef;
}

.analysis-summary strong {
  color: var(--green-dark);
  text-transform: capitalize;
}

.analysis-summary span {
  color: var(--muted);
}

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

.metric-grid div {
  display: grid;
  gap: 4px;
  padding: 10px;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: var(--surface);
}

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

.metric-grid strong {
  font-size: 1rem;
}

.kb-grid {
  display: grid;
  gap: 8px;
}

.kb-grid div {
  display: grid;
  gap: 3px;
  padding: 10px;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: var(--surface);
}

.kb-grid span,
.export-actions span {
  color: var(--muted);
  font-size: 0.78rem;
}

.kb-grid strong {
  overflow-wrap: anywhere;
  font-size: 0.88rem;
}

.review-note {
  display: grid;
  gap: 6px;
  padding: 10px;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: var(--surface);
}

.review-note strong {
  font-size: 0.9rem;
}

.review-note span {
  color: var(--muted);
  font-size: 0.78rem;
}

.review-note p {
  margin: 2px 0 0;
  white-space: pre-wrap;
  overflow-wrap: anywhere;
}

.result-section {
  display: grid;
  gap: 8px;
}

.result-section h3 {
  margin: 0;
  font-size: 0.94rem;
}

.result-list {
  display: grid;
  gap: 8px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.result-list li {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 10px;
  align-items: start;
  padding: 10px;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: var(--surface);
}

.result-list li > div {
  display: grid;
  gap: 4px;
}

.result-list li span {
  color: var(--muted);
}

.severity-badge {
  display: inline-grid;
  min-width: 74px;
  min-height: 26px;
  place-items: center;
  border-radius: 999px;
  color: var(--surface);
  font-size: 0.72rem;
  font-weight: 780;
}

.severity-high {
  background: var(--red);
}

.severity-medium-high {
  background: var(--gold);
}

.severity-medium {
  background: var(--blue);
}

.severity-low {
  background: var(--green);
}

.letter-output {
  max-height: 240px;
  overflow: auto;
  margin: 0;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: #171717;
  color: #f3f0e8;
  white-space: pre-wrap;
}

.export-actions {
  display: grid;
  gap: 8px;
  padding-top: 4px;
}

.export-actions .secondary-button {
  width: 100%;
  margin-top: 0;
}

.policy-page {
  max-width: 980px;
}

.policy-hero {
  padding: 30px 0 20px;
}

.policy-hero h1 {
  max-width: 760px;
  font-size: clamp(2.2rem, 5vw, 4.1rem);
}

.policy-date {
  margin-top: 14px;
  color: var(--muted);
  font-size: 0.9rem;
}

.policy-grid {
  display: grid;
  gap: 14px;
  padding-bottom: 40px;
}

.policy-grid article {
  display: grid;
  gap: 10px;
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface);
  box-shadow: var(--shadow);
}

.policy-grid h2 {
  font-size: 1.05rem;
}

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

.policy-grid ul {
  padding-left: 18px;
}

.policy-grid code {
  color: var(--ink);
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 0.9em;
}

.launch-status-panel {
  border-left: 4px solid #7a5c21;
}

.launch-status-panel[data-status="public_ready"] {
  border-left-color: #28724f;
}

.launch-status-panel[data-status="blocked_missing_operator_contact"] {
  border-left-color: #a33f2a;
}

.operator-list {
  display: grid;
  gap: 8px;
  margin: 0;
}

.operator-list div {
  display: grid;
  gap: 3px;
  padding: 10px 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fbfaf7;
}

.operator-list dt {
  color: var(--muted);
  font-size: 0.78rem;
  font-weight: 800;
  text-transform: uppercase;
}

.operator-list dd {
  margin: 0;
  color: var(--ink);
  overflow-wrap: anywhere;
}

.operator-list a {
  color: var(--accent-dark);
  font-weight: 800;
}

.readiness-blockers {
  display: grid;
  gap: 6px;
}

@media (max-width: 980px) {
  .upload-hero,
  .app-grid,
  .seo-panels {
    grid-template-columns: 1fr;
  }

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

  .document-panel,
  .costs-panel {
    grid-column: span 1;
  }

  .clerk-confirmations {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 640px) {
  body {
    padding-bottom: 118px;
  }

  .topbar {
    align-items: center;
    flex-direction: row;
    gap: 12px;
    min-height: 58px;
    padding: 10px 12px;
  }

  .topnav {
    width: 100%;
    justify-content: space-between;
    gap: 10px;
  }

  .seo-nav {
    max-width: 62vw;
    justify-content: flex-end;
    gap: 10px;
    font-size: 0.78rem;
  }

  .seo-nav a:nth-child(n + 2) {
    display: none;
  }

  .language-control {
    width: auto;
    justify-content: space-between;
  }

  .service-facts {
    grid-template-columns: 1fr;
  }

  main {
    width: min(100% - 20px, 1180px);
    padding-top: 20px;
  }

  h1 {
    font-size: clamp(2.1rem, 12vw, 3.25rem);
  }

  .seo-main {
    padding-top: 24px;
  }

  .seo-hero {
    padding: 26px 0 28px;
  }

  .panel {
    padding: 14px;
  }

  .upload-hero {
    min-height: calc(100svh - 176px);
    padding-top: 16px;
  }

  .upload-copy {
    min-height: auto;
  }

  .upload-shortcut {
    min-height: min(360px, 50svh);
    padding: 24px 18px;
  }

  .clerk-shell {
    right: auto;
    bottom: 10px;
    left: 50%;
    width: calc(100vw - 20px);
  }

  .clerk-header {
    padding: 8px 10px;
  }

  .clerk-thread {
    max-height: 112px;
    padding: 8px 10px;
  }

  .clerk-composer {
    grid-template-columns: minmax(0, 1fr) auto;
    padding: 8px;
  }

  .clerk-composer input {
    min-height: 38px;
  }

  .clerk-composer button {
    min-width: 68px;
    padding-right: 10px;
    padding-left: 10px;
  }

  .clerk-message {
    font-size: 0.84rem;
  }

  .clerk-shell[data-collapsed="true"] .clerk-header span {
    display: none;
  }

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