:root {
  color-scheme: light;
  font-family: Arial, "Microsoft YaHei", sans-serif;
  color: #1f2933;
  background: #f4f7f9;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
}

header {
  background: #183b56;
  color: #fff;
  padding: 18px 28px;
}

h1 {
  margin: 0 0 12px;
  font-size: 24px;
}

nav {
  display: flex;
  align-items: center;
  gap: 16px;
  flex-wrap: wrap;
}

nav a {
  color: #dbeafe;
  text-decoration: none;
}

.spacer {
  flex: 1;
}

main {
  max-width: 1180px;
  margin: 0 auto;
  padding: 28px;
}

.panel {
  background: #fff;
  border: 1px solid #d9e2ec;
  border-radius: 8px;
  padding: 22px;
  margin-bottom: 20px;
}

.narrow {
  max-width: 460px;
  margin: 48px auto;
}

.grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 18px;
}

.toolbar {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  align-items: flex-start;
  flex-wrap: wrap;
}

.badge {
  display: inline-flex;
  align-items: center;
  border-radius: 999px;
  padding: 6px 10px;
  background: #e0f2fe;
  color: #075985;
  font-size: 13px;
  font-weight: 700;
}

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

.download-grid.compact {
  grid-template-columns: 1fr;
  margin-top: 12px;
}

.operation-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 14px;
}

.operation-card {
  border: 1px solid #d9e2ec;
  border-radius: 8px;
  padding: 18px;
  background: #f8fafc;
}

.operation-card strong {
  display: block;
  font-size: 18px;
  margin-bottom: 8px;
}

.operation-card p {
  margin: 0;
  color: #475569;
  line-height: 1.55;
}

.download-card,
.metric {
  border: 1px solid #d9e2ec;
  border-radius: 8px;
  padding: 14px;
  background: #f8fafc;
}

.download-card {
  display: grid;
  gap: 6px;
  color: #0f172a;
  text-decoration: none;
}

.template-section + .template-section {
  margin-top: 20px;
}

.template-section h4 {
  margin: 0 0 10px;
}

.template-toggle {
  margin: 8px 0 12px;
}

.archived-row {
  background: #f8fafc;
  color: #64748b;
}

.download-card span,
.metric span {
  color: #64748b;
  font-size: 13px;
}

.metric strong {
  display: block;
  margin-top: 6px;
  font-size: 20px;
}

.muted {
  color: #64748b;
}

.error {
  color: #b42318;
}

.error-box {
  background: #fef3f2;
  border: 1px solid #fecdca;
  color: #7a271a;
  border-radius: 6px;
  padding: 12px 16px;
  margin: 12px 0;
}

.warning {
  background: #fff7ed;
  border: 1px solid #fed7aa;
  border-radius: 6px;
  padding: 12px 16px;
  margin: 12px 0;
}

.info-box {
  background: #eff6ff;
  border: 1px solid #bfdbfe;
  border-radius: 6px;
  padding: 12px 16px;
  margin: 12px 0;
}

.generating-box {
  display: flex;
  align-items: center;
  gap: 14px;
}

.spinner {
  width: 28px;
  height: 28px;
  border: 3px solid #bfdbfe;
  border-top-color: #1f4d78;
  border-radius: 50%;
  flex: 0 0 auto;
  animation: spin 0.8s linear infinite;
}

@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}

.p3-task-list {
  display: grid;
  border-top: 1px solid #d9e2ec;
  margin-top: 12px;
}

.status-detail {
  display: block;
  color: #64748b;
  font-size: 12px;
  line-height: 1.45;
  margin-top: 4px;
  max-width: 260px;
}

.p3-task-row {
  display: grid;
  grid-template-columns: 28px minmax(0, 1fr) auto auto;
  align-items: center;
  gap: 12px;
  padding: 12px 0;
  border-bottom: 1px solid #e2e8f0;
}

.p3-task-row:last-child {
  border-bottom: 0;
}

.p3-task-row .spinner {
  width: 20px;
  height: 20px;
  border-width: 2px;
}

.p3-task-main {
  min-width: 0;
}

.p3-task-main strong,
.p3-task-main span {
  display: block;
}

.p3-task-main span {
  color: #64748b;
  font-size: 13px;
  overflow-wrap: anywhere;
  margin-top: 3px;
}

.p3-task-marker {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: #f59e0b;
  justify-self: center;
}

.p3-task-row .button-link {
  padding: 7px 11px;
}

@media (max-width: 640px) {
  .p3-task-row {
    grid-template-columns: 24px minmax(0, 1fr);
  }

  .p3-task-row .status-pill,
  .p3-task-row .button-link {
    grid-column: 2;
    justify-self: start;
  }
}

.generated-files {
  border: 1px solid #d9e2ec;
  border-radius: 8px;
  padding: 14px;
  margin: 14px 0;
  background: #f8fafc;
}

.generated-files > strong {
  display: block;
  margin-bottom: 10px;
}

.generated-package {
  background: #fff;
  border: 1px solid #d9e2ec;
  border-radius: 6px;
  padding: 10px 12px;
}

.generated-package + .generated-package {
  margin-top: 8px;
}

.generated-package summary {
  cursor: pointer;
  font-weight: 700;
}

.generated-package ul {
  margin: 8px 0 0;
  padding-left: 20px;
}

.danger-zone {
  border-color: #fecaca;
}

.stack,
.upload {
  display: grid;
  gap: 14px;
}

.upload-drop-form {
  grid-template-columns: 1fr auto;
  align-items: center;
}

.upload-drop-form.auto-upload-form {
  grid-template-columns: 1fr;
}

.upload-dropzone {
  position: relative;
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 4px 14px;
  align-items: center;
  min-height: 112px;
  border: 2px dashed #9fb3c8;
  border-radius: 8px;
  padding: 20px;
  background: #f8fafc;
  cursor: pointer;
  transition: border-color 0.15s ease, background 0.15s ease, box-shadow 0.15s ease;
}

.upload-dropzone:hover,
.upload-dropzone.is-dragover {
  border-color: #0f766e;
  background: #ecfdf5;
  box-shadow: 0 0 0 3px rgba(15, 118, 110, 0.12);
}

.upload-dropzone.upload-selected {
  border-color: #1f4d78;
  background: #eff6ff;
}

.upload-dropzone.upload-invalid {
  border-color: #b42318;
  background: #fef3f2;
}

.upload-dropzone.is-uploading {
  cursor: progress;
  opacity: 0.78;
}

.upload-dropzone.is-uploading .upload-input {
  cursor: progress;
}

.upload-input {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  opacity: 0;
  cursor: pointer;
}

.upload-icon {
  grid-row: span 2;
  display: inline-grid;
  place-items: center;
  width: 58px;
  height: 58px;
  border-radius: 8px;
  background: #0f766e;
  color: #fff;
  font-size: 13px;
  font-weight: 800;
  letter-spacing: 0.03em;
}

.upload-title {
  font-size: 18px;
  font-weight: 800;
  color: #0f172a;
}

.upload-hint {
  color: #64748b;
  font-size: 14px;
  font-weight: 400;
}

label {
  display: grid;
  gap: 6px;
  font-weight: 600;
}

.check {
  display: inline-flex;
  align-items: center;
  justify-content: flex-start;
  gap: 9px;
  min-height: 44px;
  padding: 10px 12px;
  border: 1px solid #d7e0ea;
  border-radius: 6px;
  background: #f8fafc;
  color: #102033;
  line-height: 1.35;
  cursor: pointer;
}

.check input[type="checkbox"] {
  flex: 0 0 auto;
  width: 17px;
  height: 17px;
  margin: 0;
  accent-color: #0f766e;
}

.check:hover {
  border-color: #9fb3c8;
  background: #f1f5f9;
}

.check:has(input[type="checkbox"]:focus-visible) {
  outline: 2px solid #99f6e4;
  outline-offset: 2px;
}

input,
button,
select {
  font: inherit;
}

button.danger {
  background: #b42318;
}

button.secondary-action {
  background: #475569;
}

button.small-action {
  padding: 7px 10px;
}

input[type="text"],
input[type="password"],
input[type="number"],
input[type="date"],
input:not([type]),
select,
textarea {
  width: 100%;
  border: 1px solid #bcccdc;
  border-radius: 6px;
  padding: 10px 12px;
  background: #fff;
}

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

.p2-form {
  display: grid;
  gap: 18px;
}

.form-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 14px 16px;
  align-items: start;
}

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

.p2-form .panel h3 {
  margin-top: 0;
}

.p2-form .panel {
  margin-bottom: 0;
}

.p2-form .panel > .muted {
  margin: 10px 0 0;
}

.p2-form .check.wide {
  max-width: 100%;
}

.p2-form select,
.p2-form input,
.p2-form textarea {
  min-height: 42px;
}

input[type="file"] {
  border: 1px dashed #9fb3c8;
  border-radius: 6px;
  padding: 18px;
  background: #f8fafc;
}

.upload-dropzone input[type="file"] {
  border: 0;
  border-radius: 0;
  padding: 0;
  background: transparent;
}

button {
  width: fit-content;
  border: 0;
  border-radius: 6px;
  padding: 10px 16px;
  background: #0f766e;
  color: white;
  cursor: pointer;
}

.button-link {
  display: inline-block;
  width: fit-content;
  border-radius: 6px;
  padding: 10px 16px;
  background: #0f766e;
  color: white;
  text-decoration: none;
}

.button-link.secondary {
  background: #1f4d78;
  margin-left: 8px;
}

.button-row {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  margin: 14px 0;
}

.button-row .button-link.secondary {
  margin-left: 0;
}

.dev-code {
  display: inline-flex;
  align-items: center;
  width: fit-content;
  border: 1px solid #cbd5e1;
  border-radius: 999px;
  padding: 4px 8px;
  margin-left: 8px;
  background: #f8fafc;
  color: #475569;
  font-size: 12px;
  font-weight: 700;
}

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

.package-card {
  border: 1px solid #d9e2ec;
  border-radius: 8px;
  padding: 14px;
  background: #fff;
}

.package-card span {
  display: inline-flex;
  margin-bottom: 8px;
  font-size: 12px;
  font-weight: 700;
  color: #475569;
}

.package-card strong {
  display: block;
  margin-bottom: 6px;
}

.package-card p {
  margin: 0;
  color: #64748b;
  font-size: 13px;
  line-height: 1.5;
}

.package-card.available {
  border-color: #99f6e4;
  background: #f0fdfa;
}

.package-card.review {
  border-color: #fed7aa;
  background: #fff7ed;
}

.package-card.pending {
  border-color: #bfdbfe;
  background: #eff6ff;
}

.process-flow {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  gap: 10px;
  margin: 16px 0;
}

.process-step {
  border: 1px solid #d9e2ec;
  border-radius: 8px;
  padding: 12px;
  background: #f8fafc;
  min-height: 104px;
}

.process-step span {
  display: inline-flex;
  justify-content: center;
  align-items: center;
  width: 26px;
  height: 26px;
  border-radius: 50%;
  background: #94a3b8;
  color: #fff;
  font-weight: 700;
}

.process-step strong,
.process-step small {
  display: block;
}

.process-step strong {
  margin-top: 8px;
}

.process-step small {
  margin-top: 4px;
  color: #64748b;
  line-height: 1.4;
}

.process-step.done {
  border-color: #99f6e4;
  background: #f0fdfa;
}

.process-step.done span {
  background: #0f766e;
}

.process-step.active {
  border-color: #bfdbfe;
  background: #eff6ff;
}

.process-step.active span {
  background: #1f4d78;
}

.process-step.error {
  border-color: #fecdca;
  background: #fef3f2;
}

.process-step.error span {
  background: #b42318;
}

.case-meta {
  border: 1px solid #d9e2ec;
  border-radius: 8px;
  padding: 14px;
  margin: 16px 0;
  background: #f8fafc;
}

.case-meta-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 12px;
}

.case-meta-grid span,
.case-meta-grid strong {
  display: block;
}

.case-meta-grid span {
  color: #64748b;
  font-size: 13px;
}

.case-meta-grid strong {
  margin-top: 4px;
}

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

.step-card {
  border: 1px solid #d9e2ec;
  border-radius: 8px;
  padding: 14px;
  background: #fff;
}

.step-card span {
  display: inline-flex;
  justify-content: center;
  align-items: center;
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: #0f766e;
  color: #fff;
  font-weight: 700;
}

.step-card strong {
  display: block;
  margin-top: 10px;
}

.step-card p {
  margin: 6px 0 0;
  color: #64748b;
  font-size: 13px;
}

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

.source-grid div {
  border-left: 4px solid #0f766e;
  padding: 8px 12px;
  background: #f8fafc;
}

.source-grid strong,
.source-grid span {
  display: block;
}

.source-grid span {
  margin-top: 4px;
  color: #64748b;
  font-size: 13px;
}

.settings-nav {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  margin-top: 16px;
}

.settings-nav a {
  border: 1px solid #bcccdc;
  border-radius: 999px;
  padding: 7px 12px;
  color: #0f172a;
  background: #f8fafc;
  text-decoration: none;
  font-weight: 700;
  font-size: 13px;
}

.section-header {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  align-items: flex-start;
  flex-wrap: wrap;
  margin-bottom: 14px;
}

.section-header h3 {
  margin-bottom: 4px;
}

.admin-kpi-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 12px;
}

.admin-kpi {
  border: 1px solid #d9e2ec;
  border-radius: 8px;
  padding: 14px;
  background: #f8fafc;
}

.admin-kpi span,
.admin-kpi strong,
.admin-kpi small {
  display: block;
}

.admin-kpi span {
  color: #64748b;
  font-size: 13px;
  font-weight: 700;
}

.admin-kpi strong {
  margin-top: 6px;
  font-size: 20px;
  color: #0f172a;
}

.admin-kpi small {
  margin-top: 6px;
  color: #64748b;
  line-height: 1.4;
}

.admin-overview-drawer {
  border: 1px solid #d9e2ec;
  border-radius: 8px;
  background: #f8fafc;
}

.admin-overview-drawer summary {
  cursor: pointer;
  display: flex;
  justify-content: space-between;
  gap: 16px;
  align-items: center;
  padding: 14px 16px;
}

.admin-overview-drawer summary span {
  font-weight: 800;
  color: #0f172a;
}

.admin-overview-drawer summary small {
  color: #64748b;
}

.admin-overview-drawer[open] {
  padding-bottom: 16px;
}

.admin-overview-drawer[open] summary {
  border-bottom: 1px solid #d9e2ec;
  margin-bottom: 14px;
}

.admin-overview-drawer .section-header,
.admin-overview-drawer .admin-kpi-grid {
  margin-left: 16px;
  margin-right: 16px;
}

.admin-logic-drawer {
  margin-bottom: 18px;
}

.admin-logic-drawer .grid {
  padding: 0 16px 16px;
}

.admin-drawer {
  border: 1px solid #d9e2ec;
  border-radius: 8px;
  padding: 0;
  margin: 12px 0 16px;
  background: #f8fafc;
}

.admin-drawer summary {
  cursor: pointer;
  padding: 12px 14px;
  font-weight: 700;
}

.admin-drawer .admin-form {
  margin: 0;
  padding: 0 14px 14px;
}

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

.status-pill {
  display: inline-flex;
  align-items: center;
  border-radius: 999px;
  padding: 4px 8px;
  background: #e2e8f0;
  color: #475569;
  font-size: 12px;
  font-weight: 700;
}

.status-pill.ok {
  background: #dcfce7;
  color: #166534;
}

.status-pill.draft {
  background: #fef3c7;
  color: #92400e;
}

.status-pill.danger {
  background: #fee2e2;
  color: #991b1b;
}

.admin-form {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 12px;
  margin: 14px 0 18px;
}

.admin-form .wide {
  grid-column: span 2;
}

.admin-form button {
  align-self: end;
}

.role-picker {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
}

.role-picker strong {
  width: 100%;
}

.role-badge {
  display: inline-flex;
  border-radius: 999px;
  padding: 3px 8px;
  margin: 0 4px 4px 0;
  background: #e0f2fe;
  color: #075985;
  font-size: 12px;
  font-weight: 700;
}

.inline-form {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin: 0;
}

.cleanup-form {
  margin-top: 8px;
  flex-wrap: wrap;
}

.cleanup-form label {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.cleanup-form input[type="number"] {
  width: 86px;
}

@media (max-width: 640px) {
  .form-grid {
    grid-template-columns: 1fr;
  }

  .check {
    width: 100%;
  }
}

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

.row-actions a {
  color: #0f766e;
  font-weight: 700;
  text-decoration: none;
}

.template-actions {
  display: grid;
  gap: 8px;
}

.subtemplate-grid {
  display: grid;
  gap: 12px;
  min-width: 420px;
}

.subtemplate-card {
  border: 1px solid #dbeafe;
  border-radius: 8px;
  background: #f8fbff;
  padding: 12px;
}

.subtemplate-head {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 10px;
  margin-bottom: 6px;
}

.subtemplate-head strong {
  color: #0f172a;
}

.subtemplate-meta {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
  color: #64748b;
  font-size: 13px;
  margin: 8px 0;
}

.template-group {
  border: 1px solid #e2e8f0;
  border-radius: 8px;
  margin: 12px 0 18px;
  overflow: hidden;
}

.template-group-title {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  padding: 12px 14px;
  background: #f8fafc;
  border-bottom: 1px solid #e2e8f0;
}

.template-group-title span {
  color: #64748b;
  font-size: 13px;
}

.template-group table {
  margin: 0;
}

.draft-box {
  border: 1px solid #bfdbfe;
  border-radius: 8px;
  padding: 10px;
  background: #eff6ff;
}

.draft-box strong,
.draft-box span {
  display: block;
}

.draft-box span {
  color: #64748b;
  font-size: 13px;
  margin: 4px 0 8px;
}

.inline-upload {
  display: flex;
  gap: 8px;
  align-items: center;
  flex-wrap: wrap;
}

.inline-upload input[type="file"] {
  max-width: 240px;
  padding: 8px;
}

.inline-upload input[name="version"] {
  width: 150px;
}

.inline-upload button {
  padding: 8px 10px;
}

table {
  width: 100%;
  border-collapse: collapse;
  margin: 12px 0 22px;
  font-size: 14px;
}

th,
td {
  border-bottom: 1px solid #e2e8f0;
  text-align: left;
  padding: 10px;
  vertical-align: top;
}

th {
  background: #f1f5f9;
  color: #334155;
}

th.select-column,
td.select-column {
  width: 44px;
  min-width: 44px;
  padding-left: 8px;
  padding-right: 8px;
  text-align: center;
  vertical-align: middle;
}

.select-column input[type="checkbox"] {
  width: 18px;
  height: 18px;
  margin: 0;
  vertical-align: middle;
  accent-color: #0f766e;
  cursor: pointer;
}

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

pre {
  max-height: 520px;
  overflow: auto;
  background: #0f172a;
  color: #e2e8f0;
  border-radius: 6px;
  padding: 16px;
  font-size: 13px;
}

.p5-form {
  display: grid;
  gap: 18px;
}

.p5-module-list {
  display: grid;
  gap: 12px;
}

.p5-module-card {
  border: 1px solid #d9e1ea;
  border-radius: 12px;
  background: #fff;
  overflow: hidden;
}

.p5-module-card[open] {
  border-color: #9bb8d4;
  box-shadow: 0 5px 18px rgba(35, 70, 105, 0.08);
}

.p5-module-card summary {
  display: grid;
  grid-template-columns: minmax(170px, 0.35fr) minmax(260px, 1fr);
  align-items: center;
  gap: 18px;
  padding: 14px 16px;
  cursor: pointer;
  background: #f7f9fc;
}

.p5-module-card summary > span {
  display: grid;
  gap: 3px;
}

.p5-module-card summary small,
.p5-snapshot-card span,
.cell-zh,
.p5-included li span {
  display: block;
  color: #5e6b78;
  margin-top: 3px;
}

.p5-module-body {
  padding: 16px;
}

.p5-preset-toolbar {
  display: grid;
  gap: 10px;
  margin: 0 0 18px;
  padding: 14px;
  border: 1px solid #d9e6f2;
  border-radius: 10px;
  background: #f7fbff;
}

.p5-preset-heading {
  display: grid;
  grid-template-columns: minmax(220px, 360px) minmax(180px, 1fr);
  align-items: end;
  gap: 14px;
}

.p5-preset-status {
  padding-bottom: 10px;
  color: #40566c;
  font-size: 14px;
}

.p5-preset-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.p5-preset-new-form {
  display: grid;
  grid-template-columns: minmax(220px, 360px) auto auto;
  align-items: end;
  gap: 8px;
  padding: 10px;
  border-radius: 8px;
  background: #eef5fb;
}

.p5-preset-new-form[hidden] {
  display: none;
}

.p5-preset-new-form button {
  margin-bottom: 1px;
}

.p5-preset-actions button {
  padding: 8px 12px;
  font-size: 13px;
}

.p5-preset-unsaved,
.p5-preset-missing {
  margin: 0;
  padding: 9px 11px;
  border-radius: 7px;
  font-size: 13px;
}

.p5-preset-unsaved {
  color: #7a4b00;
  background: #fff4d6;
}

.p5-preset-missing {
  color: #7d3515;
  background: #fff0e8;
}

.p5-package-price {
  max-width: 320px;
  margin-bottom: 14px;
}

.p5-included {
  margin: 12px 0 16px;
  padding: 14px 16px;
  border-radius: 10px;
  background: #f6f8fb;
}

.p5-included ul {
  columns: 2;
  column-gap: 32px;
  margin-bottom: 0;
}

.p5-included li {
  break-inside: avoid;
  margin-bottom: 8px;
}

.p5-price-table input {
  min-width: 130px;
  width: 100%;
}

.p5-price-table th:first-child,
.p5-price-table td:first-child {
  width: 58px;
  text-align: center;
}

.p5-price-table th:last-child,
.p5-price-table td:last-child {
  width: 190px;
}

.p5-total-row td {
  background: #edf4fb;
}

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

.commercial-summary-grid > div,
.p5-snapshot-card {
  display: grid;
  gap: 4px;
  padding: 12px 14px;
  border: 1px solid #e0e6ed;
  border-radius: 10px;
  background: #f9fafc;
}

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

.p5-snapshot-card small {
  color: #6c7884;
}

@media (max-width: 720px) {
  .upload-drop-form {
    grid-template-columns: 1fr;
  }

  .upload-dropzone {
    grid-template-columns: 1fr;
    text-align: center;
    justify-items: center;
  }

  main {
    padding: 16px;
  }
  table {
    display: block;
    overflow-x: auto;
  }
  .admin-form .wide {
    grid-column: span 1;
  }
  .p5-module-card summary,
  .p5-preset-heading,
  .p5-preset-new-form,
  .commercial-summary-grid,
  .p5-snapshot-modules {
    grid-template-columns: 1fr;
  }
  .p5-included ul {
    columns: 1;
  }
}
