:root {
  color-scheme: light;
  --ink: #17202f;
  --deep: #0e3f46;
  --muted: #637083;
  --line: #d7e0e5;
  --soft: #f5f8f7;
  --paper: #fffdf8;
  --panel: #ffffff;
  --accent: #0d7772;
  --accent-dark: #075955;
  --gold: #d4922f;
  --coral: #c85f46;
  --warn: #9f3a38;
  --focus: #d4922f;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

html[data-theme="blue"] {
  --ink: #13213a;
  --deep: #123765;
  --muted: #5d6b82;
  --line: #d6e2f1;
  --soft: #f4f8fe;
  --paper: #f7faff;
  --panel: #ffffff;
  --accent: #235dac;
  --accent-dark: #123f7c;
  --gold: #5c9ae0;
  --coral: #63b3c8;
  --warn: #a33a3a;
  --focus: #6ea8e8;
}

html[data-theme="studio"] {
  --ink: #162033;
  --deep: #17345f;
  --muted: #647086;
  --line: #d8e2ee;
  --soft: #f6f8fb;
  --paper: #fbfcff;
  --panel: #ffffff;
  --accent: #1f5fae;
  --accent-dark: #143f7c;
  --gold: #8ab7e8;
  --coral: #4eb5c3;
  --warn: #9c3f3f;
  --focus: #8ab7e8;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  min-height: 100vh;
  overflow-x: hidden;
  background:
    linear-gradient(90deg, rgb(13 119 114 / 0.08) 1px, transparent 1px),
    linear-gradient(180deg, rgb(212 146 47 / 0.09) 1px, transparent 1px),
    linear-gradient(145deg, #f7fbf9 0%, #fff9ef 42%, #f8fafc 100%);
  background-size: 72px 72px, 72px 72px, auto;
  color: var(--ink);
}

html[data-theme="blue"] body {
  background:
    linear-gradient(90deg, rgb(35 93 172 / 0.07) 1px, transparent 1px),
    linear-gradient(180deg, rgb(92 154 224 / 0.08) 1px, transparent 1px),
    radial-gradient(circle at top left, rgb(35 93 172 / 0.14), transparent 34rem),
    linear-gradient(145deg, #f7faff 0%, #edf5ff 46%, #ffffff 100%);
  background-size: 72px 72px, 72px 72px, auto, auto;
}

html[data-theme="studio"] body {
  background:
    linear-gradient(90deg, rgb(31 95 174 / 0.055) 1px, transparent 1px),
    linear-gradient(180deg, rgb(78 181 195 / 0.055) 1px, transparent 1px),
    radial-gradient(circle at 14% 0%, rgb(138 183 232 / 0.22), transparent 26rem),
    radial-gradient(circle at 92% 12%, rgb(78 181 195 / 0.14), transparent 24rem),
    linear-gradient(145deg, #fbfcff 0%, #f1f6fc 48%, #ffffff 100%);
  background-size: 76px 76px, 76px 76px, auto, auto, auto;
}

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

.app-shell,
.admin-shell {
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
}

.account-bar {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  align-items: center;
  padding: 14px 0 0;
  color: var(--muted);
  font-size: 0.92rem;
}

.account-bar a {
  color: var(--accent-dark);
  font-weight: 800;
  text-decoration: none;
}

.account-links {
  display: flex;
  flex-wrap: wrap;
  gap: 12px 18px;
  justify-content: flex-end;
}

.intro {
  position: relative;
  isolation: isolate;
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(320px, 380px);
  gap: 38px;
  align-items: end;
  min-height: 430px;
  padding: 64px 24px 36px;
}

.intro > * {
  min-width: 0;
}

.intro::before {
  content: "";
  position: absolute;
  inset: 18px 0 0;
  z-index: -1;
  border-radius: 8px;
  background:
    linear-gradient(90deg, rgb(247 251 249 / 0.98) 0%, rgb(247 251 249 / 0.88) 46%, rgb(247 251 249 / 0.34) 78%, transparent 100%),
    linear-gradient(180deg, rgb(255 255 255 / 0.32), rgb(255 255 255 / 0.72)),
    url("/assets/policy-cover.png") right 4rem center / min(260px, 24vw) auto no-repeat;
}

html[data-theme="blue"] .intro::before {
  background:
    linear-gradient(90deg, rgb(247 250 255 / 0.98) 0%, rgb(247 250 255 / 0.9) 47%, rgb(247 250 255 / 0.36) 78%, transparent 100%),
    linear-gradient(180deg, rgb(255 255 255 / 0.34), rgb(255 255 255 / 0.76)),
    url("/assets/policy-cover-blue.png") right 4rem center / min(260px, 24vw) auto no-repeat;
}

html[data-theme="studio"] .intro::before {
  background:
    linear-gradient(90deg, rgb(251 252 255 / 0.98) 0%, rgb(251 252 255 / 0.9) 47%, rgb(251 252 255 / 0.34) 78%, transparent 100%),
    linear-gradient(180deg, rgb(255 255 255 / 0.34), rgb(255 255 255 / 0.76)),
    url("/assets/policy-cover-blue.png") right 4rem center / min(260px, 24vw) auto no-repeat;
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin: 0 0 14px;
  color: var(--deep);
  font-size: 0.78rem;
  font-weight: 850;
  letter-spacing: 0;
  text-transform: uppercase;
}

.eyebrow::before {
  content: "";
  width: 30px;
  height: 3px;
  border-radius: 999px;
  background: var(--gold);
}

h1,
h2 {
  margin: 0;
  letter-spacing: 0;
}

h1 {
  max-width: 800px;
  font-size: clamp(2.15rem, 4.4vw, 4.75rem);
  line-height: 0.98;
  color: var(--ink);
  overflow-wrap: break-word;
}

h2 {
  font-size: 1.5rem;
}

.lede {
  max-width: 720px;
  margin: 20px 0 0;
  color: #435264;
  font-size: 1.14rem;
  line-height: 1.65;
}

.trust-panel,
.form-panel,
.preview-panel,
.success-panel,
.admin-login,
.admin-table-wrap {
  background: rgb(255 255 255 / 0.92);
  border: 1px solid rgb(14 63 70 / 0.16);
  border-radius: 8px;
  box-shadow: 0 24px 70px rgb(23 32 47 / 0.11);
  backdrop-filter: blur(4px);
}

html[data-theme="studio"] .trust-panel,
html[data-theme="studio"] .form-panel,
html[data-theme="studio"] .preview-panel,
html[data-theme="studio"] .success-panel,
html[data-theme="studio"] .admin-login,
html[data-theme="studio"] .admin-table-wrap {
  background: rgb(255 255 255 / 0.95);
  border-color: rgb(31 95 174 / 0.16);
  box-shadow: 0 22px 58px rgb(22 32 51 / 0.09);
}

.trust-panel {
  position: relative;
  overflow: hidden;
  min-width: 0;
  padding: 24px 24px 22px;
  border-top: 5px solid var(--accent);
}

.trust-panel::after {
  content: "";
  position: absolute;
  inset: auto 0 0;
  height: 5px;
  background: linear-gradient(90deg, var(--gold), var(--coral), var(--accent));
}

html[data-theme="blue"] .trust-panel::after {
  background: linear-gradient(90deg, #235dac, #5c9ae0, #63b3c8);
}

html[data-theme="studio"] .trust-panel::after {
  background: linear-gradient(90deg, #1f5fae, #8ab7e8, #4eb5c3);
}

.trust-panel strong,
.next-steps strong {
  display: block;
  margin-bottom: 10px;
  color: #102032;
  font-size: 1.05rem;
}

.trust-panel ul,
.next-steps ul {
  margin: 0;
  padding-left: 0;
  color: var(--muted);
  line-height: 1.55;
  list-style: none;
}

.trust-panel li,
.next-steps li {
  position: relative;
  padding: 9px 0 9px 30px;
  overflow-wrap: break-word;
}

.trust-panel li::before,
.next-steps li::before {
  content: "";
  position: absolute;
  top: 16px;
  left: 4px;
  width: 11px;
  height: 11px;
  border: 2px solid var(--gold);
  border-radius: 50%;
  background: #fff;
}

.workspace {
  padding: 12px 0 56px;
}

.progress {
  display: grid;
  grid-template-columns: minmax(180px, 1fr) auto;
  gap: 14px;
  align-items: center;
  margin-bottom: 16px;
}

.bar {
  height: 10px;
  overflow: hidden;
  background: rgb(14 63 70 / 0.12);
  border-radius: 999px;
}

.bar span {
  display: block;
  height: 100%;
  width: 0;
  background: linear-gradient(90deg, var(--accent), var(--gold));
  transition: width 180ms ease;
}

html[data-theme="blue"] .bar span {
  background: linear-gradient(90deg, #235dac, #5c9ae0);
}

html[data-theme="studio"] .bar span {
  background: linear-gradient(90deg, #1f5fae, #8ab7e8);
}

.progress p,
.notice {
  margin: 0;
  color: var(--muted);
  font-size: 0.92rem;
}

.form-panel,
.preview-panel,
.success-panel {
  padding: clamp(22px, 3.2vw, 38px);
}

.form-panel {
  border-top: 1px solid rgb(14 63 70 / 0.24);
}

.step-heading {
  display: grid;
  gap: 8px;
  margin-bottom: 26px;
}

.step-heading p {
  margin: 0;
  color: var(--muted);
}

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

.field,
.option-group {
  display: grid;
  gap: 8px;
  min-width: 0;
}

.option-group {
  grid-column: 1 / -1;
  padding: 0;
  border: 0;
}

.option-group legend {
  margin-bottom: 8px;
}

label span,
legend {
  color: var(--ink);
  font-weight: 760;
}

input,
select {
  width: 100%;
  min-height: 48px;
  border: 1px solid #c8d4da;
  border-radius: 7px;
  padding: 11px 13px;
  background: #fff;
  color: var(--ink);
  box-shadow: inset 0 1px 0 rgb(23 32 47 / 0.03);
}

input:focus,
select:focus,
textarea:focus,
button:focus,
a:focus {
  outline: 3px solid color-mix(in srgb, var(--focus), transparent 55%);
  outline-offset: 2px;
}

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

.option,
.check-row {
  display: flex;
  gap: 10px;
  align-items: center;
  min-height: 50px;
  padding: 13px;
  border: 1px solid #c8d4da;
  border-radius: 8px;
  background: #fffdfa;
  transition: border-color 140ms ease, background 140ms ease, box-shadow 140ms ease;
}

.option:hover,
.check-row:hover {
  border-color: color-mix(in srgb, var(--accent), transparent 55%);
  background: #f5fbfa;
}

.option:has(input:checked),
.check-row:has(input:checked) {
  border-color: var(--accent);
  background: #eef9f7;
  box-shadow: 0 0 0 1px rgb(13 119 114 / 0.18);
}

html[data-theme="blue"] .option:hover,
html[data-theme="blue"] .check-row:hover {
  background: #f4f8ff;
}

html[data-theme="blue"] .option:has(input:checked),
html[data-theme="blue"] .check-row:has(input:checked),
html[data-theme="blue"] .segmented .active,
html[data-theme="blue"] .status-pill {
  background: #edf5ff;
}

html[data-theme="studio"] .option,
html[data-theme="studio"] .check-row {
  background: #ffffff;
}

html[data-theme="studio"] .option:hover,
html[data-theme="studio"] .check-row:hover {
  background: #f6f9fd;
}

html[data-theme="studio"] .option:has(input:checked),
html[data-theme="studio"] .check-row:has(input:checked),
html[data-theme="studio"] .segmented .active,
html[data-theme="studio"] .status-pill {
  background: #edf5ff;
  box-shadow: 0 0 0 1px rgb(31 95 174 / 0.16);
}

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

.actions,
.table-toolbar,
.admin-header,
.inline-form {
  display: flex;
  gap: 12px;
  align-items: center;
}

.actions {
  justify-content: flex-end;
  margin: 26px 0 18px;
  flex-wrap: wrap;
}

button,
.link-button {
  min-height: 46px;
  border: 0;
  border-radius: 7px;
  padding: 12px 20px;
  font-weight: 820;
  text-decoration: none;
  cursor: pointer;
}

.table-button {
  min-height: 42px;
  min-width: 132px;
  padding: 10px 16px;
  white-space: nowrap;
}

.primary {
  background: var(--accent);
  color: #fff;
  box-shadow: 0 12px 26px color-mix(in srgb, var(--accent), transparent 76%);
}

.primary:hover {
  background: var(--accent-dark);
}

.secondary {
  border: 1px solid var(--line);
  background: #fff;
  color: var(--ink);
}

.danger {
  background: #fae8e4;
  color: var(--warn);
}

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

.notice {
  position: relative;
  min-height: 48px;
  padding: 12px 0 12px 18px;
  border-top: 0;
  border-left: 0;
  line-height: 1.45;
}

.notice:empty {
  display: none;
}

.notice::before {
  content: "";
  position: absolute;
  top: 12px;
  bottom: 12px;
  left: 0;
  width: 3px;
  min-height: 24px;
  border-radius: 999px;
  background: var(--gold);
}

.error {
  margin: 0 0 16px;
  padding: 12px 14px;
  border: 1px solid #e3aaa8;
  border-radius: 7px;
  background: #fff5f2;
  color: var(--warn);
  font-weight: 750;
}

.success-panel {
  max-width: 720px;
  border-top: 5px solid var(--accent);
}

.preview-panel {
  border-top: 5px solid var(--accent);
}

.preview-copy {
  max-width: 720px;
  margin: 12px 0 22px;
  color: var(--muted);
  line-height: 1.65;
}

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

.preview-card {
  min-height: 142px;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 16px;
  background: color-mix(in srgb, var(--paper), white 58%);
}

.preview-card span {
  display: block;
  margin-bottom: 8px;
  color: var(--muted);
  font-size: 0.8rem;
  font-weight: 820;
  text-transform: uppercase;
}

.preview-card strong {
  display: block;
  color: var(--deep);
  line-height: 1.25;
}

.preview-card p {
  margin: 10px 0 0;
  color: var(--muted);
  font-size: 0.93rem;
  line-height: 1.45;
}

.preview-assurance {
  margin-top: 18px;
  padding: 16px 18px;
  border-left: 4px solid var(--gold);
  background: color-mix(in srgb, var(--paper), white 46%);
}

.preview-assurance strong {
  display: block;
  color: var(--deep);
}

.preview-assurance p {
  margin: 6px 0 0;
  color: var(--muted);
  line-height: 1.55;
}

.success-panel p {
  color: var(--muted);
}

.next-steps {
  margin-top: 24px;
  padding-top: 20px;
  border-top: 1px solid var(--line);
}

.honeypot {
  position: absolute;
  left: -9999px;
}

.admin-shell {
  padding: 40px 0;
}

.admin-shell h1 {
  font-size: clamp(2rem, 4vw, 3.2rem);
}

.admin-header {
  justify-content: space-between;
  margin-bottom: 24px;
}

.admin-header > div,
.admin-table-wrap,
.readable-lede {
  min-width: 0;
}

.admin-login,
.admin-table-wrap {
  padding: 22px;
}

.inline-form {
  align-items: end;
  margin-top: 8px;
}

.login-copy {
  max-width: 620px;
  margin-bottom: 18px;
}

.login-copy p {
  margin: 8px 0 0;
  color: var(--muted);
}

.supporting-strip {
  display: flex;
  flex-wrap: wrap;
  gap: 10px 16px;
  margin: 16px 0 10px;
}

.supporting-strip span {
  position: relative;
  padding-left: 16px;
  color: var(--deep);
  font-size: 0.86rem;
  font-weight: 780;
}

.supporting-strip span::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.62em;
  width: 6px;
  height: 6px;
  border-radius: 999px;
  background: var(--gold);
}

.readable-page {
  max-width: 860px;
}

.readable-page h2 {
  margin-top: 24px;
}

.readable-page p {
  color: var(--muted);
  line-height: 1.7;
}

.readable-page .readable-lede {
  max-width: none;
  margin: 0 0 10px;
  color: #435264;
}

.login-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  align-items: end;
}

.login-grid label {
  display: grid;
  gap: 8px;
}

.login-grid [hidden],
.auth-helper-actions[hidden] {
  display: none !important;
}

.table-toolbar {
  justify-content: space-between;
  margin-bottom: 16px;
  gap: 18px;
}

.admin-nav {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 0 0 16px;
  padding: 8px;
  border: 1px solid color-mix(in srgb, var(--line), white 18%);
  border-radius: 8px;
  background: rgb(255 255 255 / 0.74);
  box-shadow: 0 12px 32px rgb(23 32 47 / 0.06);
  backdrop-filter: blur(4px);
}

.admin-nav[hidden] {
  display: none;
}

.admin-nav button {
  flex: 1 1 150px;
  min-height: 42px;
  padding: 10px 14px;
  border: 1px solid transparent;
  background: transparent;
  color: var(--muted);
  box-shadow: none;
}

.admin-nav button:hover,
.admin-nav button.active {
  border-color: color-mix(in srgb, var(--accent), transparent 50%);
  background: color-mix(in srgb, var(--accent), white 92%);
  color: var(--accent-dark);
}

.table-scroll {
  overflow-x: auto;
  max-width: 100%;
}

.metrics-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
  margin-bottom: 18px;
}

.settings-panel {
  display: grid;
  grid-template-columns: minmax(220px, 1fr) minmax(420px, 0.95fr);
  gap: 18px;
  align-items: end;
  margin-bottom: 18px;
  padding-bottom: 18px;
  border-bottom: 1px solid var(--line);
}

.settings-form {
  display: grid;
  grid-template-columns: minmax(180px, 1fr) minmax(132px, auto);
  gap: 12px;
  align-items: end;
  margin: 0;
}

.generator-settings-form {
  grid-template-columns: minmax(160px, 220px) minmax(220px, 1fr) minmax(132px, auto);
}

.admin-user-form {
  grid-template-columns: minmax(240px, 1fr) minmax(132px, auto);
  margin-bottom: 16px;
}

.password-form {
  grid-template-columns: repeat(2, minmax(180px, 1fr)) minmax(96px, auto);
}

.settings-form button {
  min-width: 96px;
}

.security-grid {
  display: grid;
  grid-template-columns: minmax(180px, 1fr) auto;
  gap: 12px;
  align-items: end;
}

.backup-actions {
  display: grid;
  grid-template-columns: repeat(3, minmax(132px, 1fr));
  gap: 12px;
}

.retention-controls {
  display: grid;
  grid-template-columns: minmax(260px, 0.45fr) minmax(260px, 1fr);
  gap: 12px;
  align-items: end;
}

.retention-controls label {
  display: grid;
  gap: 8px;
}

.retention-controls .muted {
  align-self: center;
}

.retention-controls button {
  min-width: 160px;
}

.security-grid label {
  display: grid;
  gap: 8px;
}

.security-grid [hidden] {
  display: none !important;
}

.seo-content {
  margin: 28px 0 0;
  padding: 30px 0 0;
  border-top: 1px solid var(--line);
}

.seo-content h2 {
  max-width: 760px;
  margin: 0 0 18px;
  font-size: clamp(1.45rem, 2.2vw, 2rem);
}

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

.seo-grid article {
  min-width: 0;
}

.seo-grid h3 {
  margin: 0 0 8px;
  font-size: 1rem;
}

.seo-grid p {
  margin: 0;
  color: var(--muted);
  line-height: 1.65;
}

.metric-card {
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 14px;
  background: color-mix(in srgb, var(--paper), white 62%);
  text-align: left;
  color: inherit;
  box-shadow: none;
}

.metric-card:hover,
.metric-card.active {
  border-color: color-mix(in srgb, var(--accent), transparent 45%);
  background: color-mix(in srgb, var(--accent), white 92%);
}

.metrics-grid strong,
.metric-card strong {
  display: block;
  color: var(--deep);
  font-size: 1.55rem;
}

.metrics-grid span,
.metric-card span {
  color: var(--muted);
  font-size: 0.88rem;
}

.toolbar-actions {
  display: grid;
  grid-template-columns: minmax(240px, 1fr) minmax(170px, 220px) minmax(132px, auto);
  align-items: stretch;
}

.account-actions {
  display: flex;
  gap: 12px;
  margin-top: 14px;
}

.segmented,
.auth-mode-switch {
  display: flex;
  gap: 8px;
  margin: 14px 0;
}

.segmented .active,
.auth-mode-switch .active {
  border-color: var(--accent);
  background: #eef9f7;
  color: var(--accent-dark);
}

.wide-action {
  margin-top: 14px;
}

.auth-mode-switch {
  max-width: 420px;
}

.auth-mode-switch button {
  flex: 1 1 0;
}

.auth-helper-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 18px;
  margin: 12px 0 2px;
}

.text-button {
  min-height: auto;
  padding: 0;
  border: 0;
  background: transparent;
  color: var(--accent-dark);
  box-shadow: none;
  font-weight: 800;
  text-align: left;
}

.text-button:hover {
  text-decoration: underline;
}

textarea {
  width: 100%;
  min-height: 150px;
  border: 1px solid #c8d4da;
  border-radius: 7px;
  padding: 11px 13px;
  background: #fff;
  color: var(--ink);
  font: inherit;
  line-height: 1.5;
  resize: vertical;
  box-shadow: inset 0 1px 0 rgb(23 32 47 / 0.03);
}

.contact-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 340px;
  gap: 18px;
  align-items: start;
  min-width: 0;
}

.contact-form {
  max-width: 820px;
  min-width: 0;
}

.contact-fields {
  margin-top: 18px;
}

.message-field {
  grid-column: 1 / -1;
}

.contact-aside {
  position: sticky;
  top: 24px;
  min-width: 0;
}

.status-pill {
  display: inline-flex;
  border: 1px solid rgb(13 119 114 / 0.28);
  border-radius: 999px;
  padding: 4px 9px;
  background: #eef9f7;
  color: var(--accent-dark);
  font-weight: 800;
}

.detail-panel {
  width: min(860px, calc(100vw - 32px));
  max-height: calc(100vh - 48px);
  overflow: auto;
}

.users-panel {
  margin-top: 18px;
}

.modal-overlay {
  position: fixed;
  inset: 0;
  z-index: 20;
  display: grid;
  place-items: center;
  padding: 24px;
  background: rgb(19 33 58 / 0.48);
}

.modal-overlay[hidden] {
  display: none;
}

html[data-theme="blue"] .modal-overlay {
  background: rgb(12 38 78 / 0.46);
}

.detail-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 240px;
  gap: 18px;
}

.detail-notes {
  grid-column: 1 / -1;
}

.responses-list {
  display: grid;
  gap: 18px;
}

.response-section {
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 16px;
  background: color-mix(in srgb, var(--paper), white 62%);
}

.response-section h3 {
  margin: 0 0 12px;
  color: var(--deep);
  font-size: 1rem;
}

.response-section dl {
  display: grid;
  gap: 10px;
  margin: 0;
}

.response-row {
  display: grid;
  grid-template-columns: minmax(180px, 0.9fr) minmax(0, 1.1fr);
  gap: 12px;
  padding-top: 10px;
  border-top: 1px solid color-mix(in srgb, var(--line), transparent 35%);
}

.response-row:first-child {
  padding-top: 0;
  border-top: 0;
}

.response-row dt {
  color: var(--muted);
  font-weight: 760;
}

.response-row dd {
  margin: 0;
  color: var(--ink);
  line-height: 1.45;
}

.message-cell {
  max-width: 360px;
  white-space: pre-wrap;
  line-height: 1.45;
}

.compact-actions {
  margin: 0;
}

.row-actions {
  display: grid;
  grid-template-columns: 1fr;
  gap: 8px;
  align-items: stretch;
  width: 132px;
}

.row-actions .table-button {
  width: 100%;
}

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

table {
  width: 100%;
  border-collapse: collapse;
  min-width: 880px;
}

th:first-child,
td:first-child {
  width: 108px;
}

.date-cell {
  white-space: nowrap;
  line-height: 1.35;
}

.date-cell span {
  color: var(--muted);
  font-size: 0.92rem;
}

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

.admin-table-wrap th,
.admin-table-wrap td {
  padding-inline: 8px;
}

th {
  color: var(--muted);
  font-size: 0.8rem;
  text-transform: uppercase;
}

td span {
  color: var(--muted);
}

@media (max-width: 820px) {
  .app-shell,
  .admin-shell {
    width: 100%;
    padding-inline: 16px;
  }

  .intro,
  .fields,
  .option-grid,
  .preview-grid,
  .seo-grid,
  .metrics-grid {
    grid-template-columns: 1fr;
  }

  .intro {
    gap: 20px;
    min-height: 0;
    padding: 44px 16px 34px;
  }

  h1 {
    max-width: 100%;
    font-size: clamp(1.9rem, 8vw, 2.25rem);
    line-height: 1.06;
  }

  .trust-panel {
    padding: 22px 20px 20px;
  }

  .admin-shell h1 {
    font-size: 1.55rem;
    line-height: 1.08;
    max-width: 100%;
    overflow-wrap: break-word;
  }

  .intro::before {
    inset: 8px 0 0;
    background:
      linear-gradient(180deg, rgb(247 250 255 / 0.96) 0%, rgb(247 250 255 / 0.88) 66%, rgb(247 250 255 / 0.98) 100%),
      url("/assets/policy-cover-blue.png") right -1.5rem top 1.5rem / 160px auto no-repeat;
  }

  .account-bar,
  .account-links,
  .account-actions,
  .segmented,
  .supporting-strip,
  .detail-grid,
  .settings-panel,
  .table-toolbar {
    align-items: stretch;
    flex-direction: column;
  }

  .detail-grid {
    display: flex;
  }

  .response-row {
    grid-template-columns: 1fr;
    gap: 4px;
  }

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

  .actions,
  .admin-header,
  .inline-form {
    align-items: stretch;
    flex-direction: column;
  }

  .toolbar-actions {
    display: grid;
    grid-template-columns: 1fr;
    width: 100%;
  }

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

  .backup-actions,
  .retention-controls {
    grid-template-columns: 1fr;
  }

  .settings-panel,
  .settings-form,
  .generator-settings-form,
  .admin-user-form,
  .password-form {
    grid-template-columns: 1fr;
  }

  .toolbar-actions input,
  .toolbar-actions select,
  .toolbar-actions .link-button {
    width: 100%;
  }

  .login-grid {
    display: flex;
  }

  .actions button,
  .inline-form button,
  .link-button {
    width: 100%;
    text-align: center;
  }

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

  .contact-aside {
    position: static;
  }

  .contact-form,
  .contact-aside,
  .admin-header > div,
  input,
  select,
  textarea {
    min-width: 0;
  }

  .contact-form {
    width: calc(100vw - 32px);
    max-width: calc(100vw - 32px);
    overflow: hidden;
  }

  .contact-form .field,
  .contact-form .readable-lede {
    width: 100%;
    max-width: 100%;
  }
}
