:root {
  --ink: #162f2c;
  --ink-soft: #4f625f;
  --green: #174d47;
  --green-dark: #123c37;
  --green-soft: #e8f0ec;
  --lime: #dce9c8;
  --orange: #e77742;
  --orange-soft: #faeadf;
  --blue: #4b7fa7;
  --blue-soft: #e8f1f7;
  --paper: #f7f7f2;
  --white: #ffffff;
  --line: #dee3dc;
  --line-dark: #cdd5cd;
  --shadow: 0 18px 55px rgba(28, 55, 50, 0.09);
  --radius-lg: 26px;
  --radius-md: 16px;
  --radius-sm: 11px;
  --font-sans: "Microsoft YaHei", "PingFang SC", "Noto Sans SC", sans-serif;
  --font-serif: "Noto Serif SC", "Songti SC", "STSong", serif;
}

* {
  box-sizing: border-box;
}

html {
  min-width: 320px;
  scroll-behavior: smooth;
}

html.is-sorting-page {
  scroll-behavior: auto;
}

body {
  margin: 0;
  color: var(--ink);
  font-family: var(--font-sans);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

button,
input,
textarea {
  font: inherit;
}

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

button {
  color: inherit;
}

a {
  color: inherit;
  text-decoration: none;
}

svg {
  display: block;
}

[hidden] {
  display: none !important;
}

::selection {
  color: var(--white);
  background: var(--green);
}

.public-page {
  min-height: 100vh;
  overflow-x: hidden;
  background:
    radial-gradient(circle at 9% 8%, rgba(220, 233, 200, 0.72), transparent 27rem),
    radial-gradient(circle at 92% 22%, rgba(231, 119, 66, 0.1), transparent 25rem),
    var(--paper);
}

.public-page::before {
  position: fixed;
  z-index: -1;
  inset: 0;
  pointer-events: none;
  content: "";
  opacity: 0.25;
  background-image: linear-gradient(rgba(23, 77, 71, 0.055) 1px, transparent 1px),
    linear-gradient(90deg, rgba(23, 77, 71, 0.055) 1px, transparent 1px);
  background-size: 46px 46px;
  mask-image: linear-gradient(to bottom, #000 0%, transparent 70%);
}

.site-header,
.public-shell,
.site-footer {
  width: min(1240px, calc(100% - 64px));
  margin-inline: auto;
}

.site-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 98px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 13px;
}

.brand-mark {
  display: grid;
  width: 43px;
  height: 43px;
  color: var(--white);
  background: var(--green);
  border-radius: 13px;
  place-items: center;
  box-shadow: 0 8px 20px rgba(23, 77, 71, 0.18);
}

.brand-mark svg {
  width: 25px;
  height: 25px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.7;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.brand > span:last-child {
  display: grid;
  gap: 2px;
}

.brand strong {
  font-family: var(--font-serif);
  font-size: 18px;
  font-weight: 700;
  letter-spacing: 0.04em;
}

.brand small {
  color: #75827f;
  font-size: 8px;
  font-weight: 700;
  letter-spacing: 0.17em;
}

.quiet-link {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 14px;
  color: #5d6d69;
  font-size: 13px;
  border-radius: 10px;
  transition: color 160ms ease, background 160ms ease;
}

.quiet-link:hover {
  color: var(--green);
  background: rgba(255, 255, 255, 0.7);
}

.quiet-link svg {
  width: 18px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.7;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.hero {
  display: grid;
  grid-template-columns: minmax(0, 1.04fr) minmax(400px, 0.96fr);
  gap: clamp(38px, 7vw, 96px);
  align-items: center;
  min-height: 475px;
  padding: 46px 0 66px;
}

.eyebrow {
  display: flex;
  align-items: center;
  gap: 9px;
  margin: 0 0 20px;
  color: #71827c;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.18em;
  text-transform: uppercase;
}

.eyebrow span {
  display: block;
  width: 22px;
  height: 2px;
  background: var(--orange);
}

.hero h1 {
  margin: 0;
  font-family: var(--font-serif);
  font-size: clamp(46px, 5vw, 72px);
  font-weight: 700;
  line-height: 1.16;
  letter-spacing: -0.04em;
}

.hero h1 em {
  color: var(--orange);
  font-style: normal;
}

.hero-description {
  max-width: 585px;
  margin: 24px 0 0;
  color: var(--ink-soft);
  font-size: 15px;
  line-height: 1.9;
}

.trust-row {
  display: flex;
  flex-wrap: wrap;
  gap: 18px 26px;
  margin-top: 28px;
}

.trust-row span {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  color: #4d615c;
  font-size: 12px;
}

.trust-row svg {
  width: 17px;
  height: 17px;
  padding: 2px;
  color: var(--green);
  fill: none;
  stroke: currentColor;
  stroke-width: 2.2;
  stroke-linecap: round;
  stroke-linejoin: round;
  background: rgba(23, 77, 71, 0.1);
  border-radius: 50%;
}

.hero-orbit {
  position: relative;
  min-height: 375px;
  isolation: isolate;
}

.hero-orbit::before {
  position: absolute;
  z-index: -1;
  top: 50%;
  left: 50%;
  width: 305px;
  height: 305px;
  content: "";
  transform: translate(-50%, -50%);
  background: var(--lime);
  border-radius: 44% 56% 64% 36% / 42% 42% 58% 58%;
  box-shadow: inset 0 0 0 1px rgba(23, 77, 71, 0.06);
  animation: blob 12s ease-in-out infinite alternate;
}

.orbit-ring {
  position: absolute;
  top: 50%;
  left: 50%;
  border: 1px solid rgba(23, 77, 71, 0.14);
  border-radius: 50%;
}

.orbit-ring-one {
  width: 360px;
  height: 360px;
  transform: translate(-50%, -50%);
}

.orbit-ring-two {
  width: 445px;
  height: 445px;
  border-style: dashed;
  transform: translate(-50%, -50%) rotate(8deg);
}

.orbit-card {
  position: absolute;
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 14px 17px;
  background: rgba(255, 255, 255, 0.94);
  border: 1px solid rgba(255, 255, 255, 0.9);
  border-radius: 16px;
  box-shadow: 0 14px 40px rgba(32, 68, 60, 0.13);
}

.orbit-card div {
  display: grid;
  gap: 3px;
}

.orbit-card strong {
  color: #243d39;
  font-size: 12px;
}

.orbit-card small {
  color: #7a8985;
  font-size: 9px;
}

.orbit-card-main {
  top: 50%;
  left: 50%;
  width: 245px;
  padding: 22px;
  transform: translate(-50%, -50%);
}

.orbit-card-main strong {
  font-family: var(--font-serif);
  font-size: 17px;
}

.orbit-icon {
  display: grid;
  flex: 0 0 48px;
  width: 48px;
  height: 48px;
  color: var(--white);
  background: var(--green);
  border-radius: 14px;
  place-items: center;
}

.orbit-icon svg {
  width: 25px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.6;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.orbit-card-time {
  top: 9%;
  right: 0;
  animation: float 5s ease-in-out infinite;
}

.orbit-card-image {
  bottom: 7%;
  left: 0;
  animation: float 6s 800ms ease-in-out infinite;
}

.status-dot {
  width: 9px;
  height: 9px;
  background: #54a57b;
  border: 3px solid #dbf0e5;
  border-radius: 50%;
  box-sizing: content-box;
}

.mini-image {
  position: relative;
  display: block;
  width: 35px;
  height: 35px;
  overflow: hidden;
  background: #f5d9c9;
  border-radius: 9px;
}

.mini-image::before {
  position: absolute;
  right: 6px;
  bottom: -9px;
  width: 31px;
  height: 27px;
  content: "";
  background: #e38b55;
  border-radius: 50% 50% 0 0;
  transform: rotate(-24deg);
}

.submission-layout {
  display: grid;
  grid-template-columns: minmax(0, 1.45fr) minmax(290px, 0.55fr);
  gap: 25px;
  align-items: start;
  padding-bottom: 90px;
}

.form-card,
.side-card {
  background: rgba(255, 255, 255, 0.92);
  border: 1px solid rgba(218, 225, 217, 0.9);
  box-shadow: var(--shadow);
}

.form-card {
  min-height: 650px;
  padding: clamp(27px, 4vw, 48px);
  border-radius: var(--radius-lg);
}

.card-heading {
  display: flex;
  align-items: start;
  justify-content: space-between;
  gap: 20px;
  margin-bottom: 35px;
}

.section-number {
  margin: 0 0 9px;
  color: #8b9894;
  font-size: 9px;
  font-weight: 700;
  letter-spacing: 0.18em;
  text-transform: uppercase;
}

.card-heading h2,
.side-card h2,
.success-view h2,
.auth-form h2 {
  margin: 0;
  font-family: var(--font-serif);
  font-size: 28px;
  line-height: 1.35;
}

.required-hint {
  padding-top: 20px;
  color: #8c9995;
  font-size: 10px;
  white-space: nowrap;
}

.required-hint i,
.field label > i {
  color: var(--orange);
  font-style: normal;
}

.field {
  margin-bottom: 24px;
}

.field label,
.label-row label {
  display: block;
  margin-bottom: 9px;
  color: #354d48;
  font-size: 12px;
  font-weight: 700;
}

.field label span,
.label-row label span {
  margin-left: 5px;
  color: #929e9a;
  font-size: 10px;
  font-weight: 400;
}

.input-shell {
  display: flex;
  align-items: center;
  gap: 11px;
  height: 52px;
  padding: 0 16px;
  background: #fbfcf9;
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  transition: border-color 160ms ease, box-shadow 160ms ease, background 160ms ease;
}

.input-shell:focus-within {
  background: var(--white);
  border-color: #5c8f87;
  box-shadow: 0 0 0 3px rgba(23, 77, 71, 0.08);
}

.input-shell > svg {
  flex: 0 0 19px;
  width: 19px;
  color: #8b9994;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.7;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.input-shell input {
  min-width: 0;
  width: 100%;
  height: 100%;
  padding: 0;
  color: var(--ink);
  background: transparent;
  border: 0;
  outline: 0;
}

.input-shell input::placeholder,
textarea::placeholder {
  color: #a6b0ad;
}

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

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

.record-template-picker button {
  display: grid;
  gap: 3px;
  min-height: 62px;
  padding: 11px 13px;
  text-align: left;
  cursor: pointer;
  background: #f7faf7;
  border: 1px solid #e2e8e1;
  border-radius: 11px;
}

.record-template-picker strong {
  color: var(--ink);
  font-size: 11px;
}

.record-template-picker span {
  color: #879590;
  font-size: 8px;
}

.record-template-picker button.active {
  color: var(--white);
  background: var(--green);
  border-color: var(--green);
  box-shadow: 0 8px 20px rgba(23, 77, 71, 0.15);
}

.record-template-picker button.active strong,
.record-template-picker button.active span {
  color: var(--white);
}

.multi-select {
  position: relative;
}

.multi-select-toggle {
  width: 100%;
  min-height: 49px;
  padding: 0 36px 0 13px;
  overflow: hidden;
  color: #899692;
  font-size: 11px;
  text-align: left;
  text-overflow: ellipsis;
  white-space: nowrap;
  cursor: pointer;
  background: #fbfcf9;
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
}

.multi-select-toggle::after {
  position: absolute;
  top: 50%;
  right: 14px;
  content: "⌄";
  color: #6d7f7a;
  transform: translateY(-56%);
}

.multi-select-toggle.has-value {
  color: var(--ink);
}

.multi-select-panel {
  position: absolute;
  z-index: 20;
  top: calc(100% + 5px);
  right: 0;
  left: 0;
  max-height: 220px;
  padding: 7px;
  overflow-y: auto;
  background: var(--white);
  border: 1px solid #dce4dd;
  border-radius: 10px;
  box-shadow: 0 14px 35px rgba(23, 77, 71, 0.16);
}

.multi-select-panel label {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 9px;
  color: #536761;
  font-size: 10px;
  cursor: pointer;
  border-radius: 7px;
}

.multi-select-panel label:hover {
  background: #f1f6f2;
}

.multi-select-panel input {
  width: 15px;
  height: 15px;
  accent-color: var(--green);
}

.linked-multi-field {
  padding: 10px;
  background: #f8faf7;
  border: 1px solid #e3e9e2;
  border-radius: 11px;
}

.linked-multi-field > label {
  display: block;
  margin-bottom: 7px;
}

.linked-selection-hint {
  display: block;
  margin-bottom: 6px;
  color: #83918d;
  font-size: 9px;
}

.linked-selection-hint.has-value {
  color: var(--green);
  font-weight: 700;
}

.linked-option-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.linked-option-grid label {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 7px 9px;
  color: #536761;
  font-size: 9px;
  cursor: pointer;
  background: var(--white);
  border: 1px solid #dfe6df;
  border-radius: 8px;
}

.linked-option-grid label:has(input:checked) {
  color: var(--green);
  font-weight: 700;
  background: var(--green-soft);
  border-color: #bfd4ca;
}

.linked-option-grid input {
  width: 14px;
  height: 14px;
  accent-color: var(--green);
}

.product-tree-select {
  position: relative;
}

.product-tree-panel {
  padding: 9px;
  max-height: min(62vh, 520px);
  overflow-y: auto;
}

.product-tree-panel input.product-tree-search {
  width: 100%;
  height: 49px;
  min-height: 49px;
  padding: 0 13px;
  font-size: 11px;
  background: #fbfcf9;
  border: 1px solid #dfe6df;
  border-radius: 9px;
  outline: 0;
  box-sizing: border-box;
}

.product-tree-search-hint {
  margin: 6px 2px 9px;
  color: #8b9995;
  font-size: 9px;
}

.product-tree-empty {
  display: block;
  padding: 16px 10px;
  color: #97a49f;
  font-size: 10px;
  text-align: center;
}

.product-tree-group {
  border-bottom: 1px solid #edf1ec;
}

.product-tree-group:last-child {
  border-bottom: 0;
}

.product-tree-product {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 9px 7px;
  cursor: pointer;
}

.product-tree-product input,
.product-tree-fixtures input {
  width: 15px;
  height: 15px;
  accent-color: var(--green);
}

.product-tree-product strong {
  color: #425b54;
  font-size: 10px;
}

.product-tree-fixtures {
  display: flex;
  flex-wrap: wrap;
  gap: 5px;
  padding: 0 8px 10px 31px;
}

.product-tree-fixtures label {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 6px 8px;
  color: #60736d;
  font-size: 9px;
  cursor: pointer;
  background: #f5f8f4;
  border-radius: 7px;
}

.product-tree-no-fixture {
  display: inline-flex;
  align-items: center;
  padding: 7px 9px;
  color: #8a673f;
  font-size: 9px;
  background: #fbf2df;
  border-radius: 7px;
}

.product-fixture-summary {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 8px;
}

.product-fixture-summary-item {
  padding: 7px 9px;
  color: var(--green);
  font-size: 9px;
  background: var(--green-soft);
  border-radius: 7px;
}

.product-fixture-summary-item.missing {
  color: #a85c37;
  background: var(--orange-soft);
}

.field-span-two {
  grid-column: 1 / -1;
}

.form-input,
.form-select,
.calculated-field {
  width: 100%;
  height: 49px;
  padding: 0 13px;
  color: var(--ink);
  font-size: 11px;
  background: #fbfcf9;
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  outline: 0;
  transition: border-color 160ms ease, box-shadow 160ms ease, background 160ms ease;
}

.form-input:focus,
.form-select:focus {
  background: var(--white);
  border-color: #5c8f87;
  box-shadow: 0 0 0 3px rgba(23, 77, 71, 0.08);
}

.select-search-input {
  width: 100%;
  height: 34px;
  margin-bottom: 6px;
  padding: 0 10px;
  font-size: 9px;
  background: #f7faf7;
  border: 1px solid #e1e7e0;
  border-radius: 8px;
  outline: 0;
}

.select-search-input:focus {
  background: var(--white);
  border-color: #7ca49d;
}

.searchable-select {
  position: relative;
}

.searchable-select-native {
  position: absolute !important;
  width: 1px !important;
  height: 1px !important;
  opacity: 0;
  pointer-events: none;
}

.searchable-select-toggle {
  width: 100%;
  min-height: 49px;
  padding: 0 38px 0 13px;
  overflow: hidden;
  color: #899692;
  font-size: 11px;
  text-align: left;
  text-overflow: ellipsis;
  white-space: nowrap;
  cursor: pointer;
  background: #fbfcf9;
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
}

.searchable-select-toggle::after {
  position: absolute;
  top: 50%;
  right: 14px;
  content: "⌄";
  color: #6d7f7a;
  transform: translateY(-56%);
}

.searchable-select-toggle.has-value {
  color: var(--ink);
}

.searchable-select-panel {
  position: absolute;
  z-index: 25;
  top: calc(100% + 6px);
  right: 0;
  left: 0;
  padding: 10px;
  background: var(--white);
  border: 1px solid #dce4dd;
  border-radius: 11px;
  box-shadow: 0 16px 38px rgba(23, 77, 71, 0.18);
}

.searchable-select-search {
  width: 100%;
  height: 49px;
  padding: 0 13px;
  font-size: 11px;
  background: #f7faf7;
  border: 1px solid #dce5de;
  border-radius: 9px;
  outline: 0;
}

.searchable-select-search:focus {
  background: var(--white);
  border-color: #6d9e94;
  box-shadow: 0 0 0 3px rgba(23, 77, 71, 0.08);
}

.searchable-select-hint {
  margin: 6px 2px 8px;
  color: #8b9995;
  font-size: 9px;
}

.searchable-select-options {
  display: grid;
  max-height: 220px;
  overflow-y: auto;
}

.searchable-select-option {
  padding: 10px;
  color: #4d625c;
  font-size: 10px;
  text-align: left;
  cursor: pointer;
  background: transparent;
  border: 0;
  border-radius: 7px;
}

.searchable-select-option:hover,
.searchable-select-option.selected {
  color: var(--green);
  font-weight: 700;
  background: var(--green-soft);
}

.searchable-select-empty {
  padding: 14px 10px;
  color: #96a39f;
  font-size: 10px;
  text-align: center;
}

.form-input[readonly] {
  color: #6f807b;
  background: #f4f7f3;
}

.form-select {
  cursor: pointer;
  appearance: none;
  background-image:
    linear-gradient(45deg, transparent 50%, #7d8b87 50%),
    linear-gradient(135deg, #7d8b87 50%, transparent 50%);
  background-position:
    calc(100% - 16px) 21px,
    calc(100% - 11px) 21px;
  background-repeat: no-repeat;
  background-size: 5px 5px, 5px 5px;
}

.form-multiselect {
  height: auto;
  min-height: 92px;
  padding-block: 7px;
  cursor: default;
}

.date-time-control {
  display: grid;
  grid-template-columns: minmax(0, 1.25fr) minmax(100px, 0.75fr);
  gap: 7px;
}

.time-input-group {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr) auto;
  align-items: center;
  gap: 4px;
  height: 49px;
  padding: 0 8px;
  background: #fbfcf9;
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
}

.time-input-group input,
.time-input-group select {
  min-width: 0;
  width: 100%;
  height: 36px;
  padding: 0;
  color: var(--ink);
  font-size: 11px;
  font-weight: 700;
  text-align: center;
  background: transparent;
  border: 0;
  outline: 0;
  appearance: textfield;
}

.time-input-group select {
  cursor: pointer;
  appearance: auto;
}

.time-input-group input::-webkit-inner-spin-button,
.time-input-group input::-webkit-outer-spin-button {
  margin: 0;
  appearance: none;
}

.time-input-group span {
  color: #8a9894;
  font-size: 8px;
}

.calculated-field {
  display: flex;
  align-items: center;
  gap: 8px;
  background: #eef4ef;
}

.calculated-field input {
  flex: 1;
  min-width: 0;
  padding: 0;
  color: var(--green);
  font-weight: 700;
  background: transparent;
  border: 0;
  outline: 0;
}

.calculated-field span {
  color: #7c8f89;
  font-size: 9px;
}

.field-help,
.field-meta {
  color: #8e9a97;
  font-size: 10px;
}

.field-help {
  margin: 8px 0 0;
}

textarea {
  display: block;
  width: 100%;
  min-height: 105px;
  padding: 14px 16px;
  color: var(--ink);
  line-height: 1.7;
  resize: vertical;
  background: #fbfcf9;
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  outline: 0;
  transition: border-color 160ms ease, box-shadow 160ms ease, background 160ms ease;
}

textarea:focus {
  background: var(--white);
  border-color: #5c8f87;
  box-shadow: 0 0 0 3px rgba(23, 77, 71, 0.08);
}

.field-meta {
  display: flex;
  justify-content: space-between;
  margin-top: 7px;
}

.label-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.label-row > span {
  color: #909c98;
  font-size: 10px;
}

.upload-zone {
  position: relative;
  display: flex !important;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  min-height: 156px;
  padding: 23px !important;
  overflow: hidden;
  text-align: center;
  background:
    linear-gradient(var(--white), var(--white)) padding-box,
    repeating-linear-gradient(90deg, #c9d4cc 0 7px, transparent 7px 13px) border-box;
  border: 1px dashed transparent !important;
  border-radius: 14px;
  cursor: pointer;
  transition: background 160ms ease, transform 160ms ease, border-color 160ms ease;
}

.upload-zone:hover,
.upload-zone.dragging {
  background: #f5f9f5;
  border-color: #7a9e95 !important;
}

.upload-zone.dragging {
  transform: scale(0.993);
}

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

.upload-icon {
  display: grid;
  width: 42px;
  height: 42px;
  margin-bottom: 10px;
  color: var(--green);
  background: var(--green-soft);
  border-radius: 12px;
  place-items: center;
}

.upload-icon svg {
  width: 23px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.upload-zone > strong {
  margin-bottom: 4px;
  color: #38504b;
  font-size: 12px;
}

.upload-zone > small {
  color: #95a09d;
  font-size: 9px;
  font-weight: 400;
}

.file-message {
  min-height: 16px;
  margin: 8px 0 0;
  color: #7c8c87;
  font-size: 10px;
}

.file-message.success {
  color: #39785e;
}

.file-message.error {
  color: #bd5d35;
}

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

.preview-card {
  position: relative;
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 0;
  padding: 8px 36px 8px 8px;
  background: #f8faf6;
  border: 1px solid #e4e9e3;
  border-radius: 11px;
}

.preview-visual {
  flex: 0 0 42px;
  width: 42px;
  height: 42px;
  overflow: hidden;
  background: #e9eeea;
  border-radius: 8px;
}

.preview-visual img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.preview-info {
  display: grid;
  min-width: 0;
  gap: 3px;
}

.preview-info strong {
  overflow: hidden;
  color: #435651;
  font-size: 10px;
  font-weight: 600;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.preview-info small {
  color: #8e9b97;
  font-size: 9px;
}

.remove-image {
  position: absolute;
  top: 50%;
  right: 8px;
  display: grid;
  width: 23px;
  height: 23px;
  padding: 0;
  color: #82908c;
  cursor: pointer;
  background: transparent;
  border: 0;
  border-radius: 50%;
  transform: translateY(-50%);
  place-items: center;
}

.remove-image:hover {
  color: #a85031;
  background: var(--orange-soft);
}

.remove-image svg {
  width: 14px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
  stroke-linecap: round;
}

.form-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  padding-top: 6px;
}

.privacy-note {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  color: #8d9995;
  font-size: 10px;
}

.privacy-note svg {
  width: 16px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.7;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.primary-button,
.secondary-button,
.export-button,
.filter-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  min-height: 46px;
  padding: 0 20px;
  color: var(--white);
  font-size: 12px;
  font-weight: 700;
  cursor: pointer;
  background: var(--green);
  border: 0;
  border-radius: 10px;
  box-shadow: 0 9px 18px rgba(23, 77, 71, 0.13);
  transition: background 160ms ease, transform 160ms ease, box-shadow 160ms ease, opacity 160ms ease;
}

.primary-button:hover,
.export-button:hover,
.filter-button:hover {
  background: var(--green-dark);
  box-shadow: 0 12px 24px rgba(23, 77, 71, 0.18);
  transform: translateY(-1px);
}

.primary-button:disabled {
  cursor: wait;
  opacity: 0.7;
}

.primary-button svg {
  width: 18px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.primary-button.loading span::after {
  display: inline-block;
  width: 11px;
  height: 11px;
  margin-left: 8px;
  content: "";
  vertical-align: -1px;
  border: 2px solid rgba(255, 255, 255, 0.38);
  border-top-color: var(--white);
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
}

.primary-button.wide {
  width: 100%;
  min-height: 51px;
}

.form-alert {
  min-height: 20px;
  margin: 12px 0 0;
  color: #b05732;
  font-size: 11px;
  line-height: 1.6;
  text-align: right;
}

.form-alert:not(:empty) {
  padding: 11px 13px;
  font-size: 14px;
  font-weight: 700;
  text-align: left;
  background: #fff0e8;
  border: 1px solid #f0c6b4;
  border-radius: 10px;
}

.field-invalid {
  padding: 9px;
  margin: -9px -9px 9px;
  background: #fff8f4;
  border: 1px solid #e9a98f;
  border-radius: 11px;
  box-shadow: 0 0 0 3px rgba(200, 92, 52, 0.08);
}

.field-invalid input,
.field-invalid select,
.field-invalid textarea,
.field-invalid .searchable-select-toggle,
.field-invalid .multi-select-toggle {
  border-color: #d87551 !important;
}

.side-panel {
  display: grid;
  gap: 18px;
}

.side-card {
  padding: 30px 28px;
  border-radius: var(--radius-lg);
}

.side-card h2 {
  font-size: 22px;
  line-height: 1.55;
}

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

.steps li {
  position: relative;
  display: grid;
  grid-template-columns: 38px 1fr;
  gap: 11px;
  padding-bottom: 23px;
}

.steps li:last-child {
  padding-bottom: 0;
}

.steps li:not(:last-child)::after {
  position: absolute;
  top: 30px;
  bottom: 8px;
  left: 16px;
  width: 1px;
  content: "";
  background: #dce3dd;
}

.steps li > span {
  z-index: 1;
  display: grid;
  width: 32px;
  height: 32px;
  color: var(--green);
  font-size: 9px;
  font-weight: 700;
  background: var(--green-soft);
  border: 4px solid var(--white);
  border-radius: 50%;
  box-shadow: 0 0 0 1px #d2dfd7;
  place-items: center;
}

.steps strong {
  display: block;
  margin: 3px 0 5px;
  color: #324b46;
  font-size: 12px;
}

.steps p {
  margin: 0;
  color: #899691;
  font-size: 10px;
  line-height: 1.7;
}

.time-card {
  display: flex;
  align-items: center;
  gap: 16px;
  min-height: 112px;
  padding: 22px 26px;
  overflow: hidden;
  color: var(--white);
  background: var(--green);
  border-radius: var(--radius-lg);
  box-shadow: 0 16px 35px rgba(23, 77, 71, 0.18);
}

.clock-visual {
  position: relative;
  flex: 0 0 55px;
  width: 55px;
  height: 55px;
  border: 1px solid rgba(255, 255, 255, 0.22);
  border-radius: 50%;
}

.clock-visual::before,
.clock-visual::after {
  position: absolute;
  top: 50%;
  left: 50%;
  width: 1px;
  height: 19px;
  content: "";
  background: var(--lime);
  transform-origin: 50% 0;
}

.clock-visual::before {
  transform: rotate(32deg);
}

.clock-visual::after {
  height: 14px;
  transform: rotate(126deg);
}

.clock-visual span {
  position: absolute;
  inset: 8px;
  border: 1px dashed rgba(255, 255, 255, 0.14);
  border-radius: 50%;
}

.clock-visual i {
  position: absolute;
  top: 50%;
  left: 50%;
  width: 6px;
  height: 6px;
  background: var(--lime);
  border-radius: 50%;
  transform: translate(-50%, -50%);
}

.time-card > div:last-child {
  display: grid;
  gap: 2px;
}

.time-card small {
  color: rgba(255, 255, 255, 0.62);
  font-size: 9px;
  letter-spacing: 0.08em;
}

.time-card strong {
  font-family: var(--font-serif);
  font-size: 23px;
  font-variant-numeric: tabular-nums;
}

.time-card div > span {
  color: rgba(255, 255, 255, 0.7);
  font-size: 9px;
}

.success-view {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  min-height: 550px;
  text-align: center;
  animation: fadeUp 500ms ease both;
}

.success-icon {
  display: grid;
  width: 76px;
  height: 76px;
  margin-bottom: 22px;
  color: var(--white);
  background: var(--green);
  border: 9px solid var(--green-soft);
  border-radius: 50%;
  box-sizing: content-box;
  place-items: center;
}

.success-icon svg {
  width: 34px;
  fill: none;
  stroke: currentColor;
  stroke-width: 2.2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.success-view > p:not(.section-number) {
  max-width: 400px;
  margin: 13px auto 0;
  color: #758580;
  font-size: 12px;
  line-height: 1.8;
}

.success-details {
  display: grid;
  grid-template-columns: repeat(3, minmax(100px, 1fr));
  width: min(500px, 100%);
  margin: 30px 0;
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}

.success-details div {
  padding: 18px 10px;
}

.success-details div:not(:last-child) {
  border-right: 1px solid var(--line);
}

.success-details dt {
  margin-bottom: 6px;
  color: #8b9894;
  font-size: 9px;
}

.success-details dd {
  margin: 0;
  color: #314a45;
  font-size: 11px;
  font-weight: 700;
}

.secondary-button {
  color: var(--green);
  background: var(--green-soft);
  box-shadow: none;
}

.secondary-button:hover {
  background: #dce9e2;
}

.site-footer {
  display: flex;
  justify-content: space-between;
  padding: 25px 0 34px;
  color: #8f9b97;
  font-size: 9px;
  letter-spacing: 0.06em;
  border-top: 1px solid rgba(23, 77, 71, 0.09);
}

/* Admin */
.admin-page {
  min-height: 100vh;
  background:
    radial-gradient(circle at 8% 4%, rgba(220, 233, 200, 0.33), transparent 30rem),
    #f3f5f1;
}

.admin-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 74px;
  padding: 0 max(28px, calc((100vw - 1280px) / 2));
  color: var(--white);
  background: #142f2c;
}

.brand-light .brand-mark {
  width: 37px;
  height: 37px;
  color: var(--green);
  background: var(--lime);
  border-radius: 11px;
  box-shadow: none;
}

.brand-light .brand-mark svg {
  width: 22px;
}

.brand-light small {
  color: rgba(255, 255, 255, 0.48);
}

.admin-nav {
  display: flex;
  align-items: center;
  gap: 9px;
}

.nav-submit,
.nav-logout {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  min-height: 36px;
  padding: 0 12px;
  color: rgba(255, 255, 255, 0.72);
  font-size: 11px;
  cursor: pointer;
  background: transparent;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 8px;
  transition: color 160ms ease, border-color 160ms ease, background 160ms ease;
}

.admin-role-badge {
  padding: 6px 9px;
  color: rgba(255, 255, 255, 0.72);
  font-size: 8px;
  background: rgba(255, 255, 255, 0.07);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 12px;
}

.nav-submit:hover,
.nav-logout:hover {
  color: var(--white);
  background: rgba(255, 255, 255, 0.07);
  border-color: rgba(255, 255, 255, 0.2);
}

.nav-submit svg,
.nav-logout svg {
  width: 15px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.7;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.auth-loading {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  min-height: calc(100vh - 74px);
  color: #71807c;
  font-size: 12px;
}

.spinner {
  display: inline-block;
  width: 22px;
  height: 22px;
  border: 2px solid rgba(255, 255, 255, 0.25);
  border-top-color: var(--white);
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
}

.spinner.dark {
  border-color: rgba(23, 77, 71, 0.15);
  border-top-color: var(--green);
}

.auth-view {
  display: grid;
  min-height: calc(100vh - 74px);
  padding: 44px 24px;
  place-items: center;
}

.auth-card {
  display: grid;
  grid-template-columns: 1.02fr 0.98fr;
  width: min(980px, 100%);
  min-height: 580px;
  overflow: hidden;
  background: var(--white);
  border-radius: 28px;
  box-shadow: 0 28px 80px rgba(20, 47, 44, 0.13);
}

.auth-art {
  position: relative;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  padding: 56px;
  overflow: hidden;
  color: var(--white);
  background:
    radial-gradient(circle at 80% 20%, rgba(220, 233, 200, 0.16), transparent 30%),
    #174d47;
}

.auth-art::before {
  position: absolute;
  right: -105px;
  bottom: -105px;
  width: 350px;
  height: 350px;
  content: "";
  border: 1px solid rgba(255, 255, 255, 0.09);
  border-radius: 50%;
  box-shadow: 0 0 0 48px rgba(255, 255, 255, 0.025), 0 0 0 98px rgba(255, 255, 255, 0.018);
}

.auth-art-content {
  z-index: 1;
}

.eyebrow.light {
  color: rgba(255, 255, 255, 0.56);
}

.eyebrow.light span {
  background: var(--lime);
}

.auth-art h1 {
  margin: 0;
  font-family: var(--font-serif);
  font-size: clamp(40px, 4vw, 53px);
  line-height: 1.25;
}

.auth-art-content > p:last-child {
  max-width: 340px;
  margin-top: 22px;
  color: rgba(255, 255, 255, 0.62);
  font-size: 12px;
  line-height: 1.9;
}

.auth-chart {
  z-index: 1;
  display: flex;
  align-items: end;
  gap: 8px;
  height: 120px;
  padding: 0 20px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.18);
}

.auth-chart span {
  flex: 1;
  background: rgba(220, 233, 200, 0.23);
  border-radius: 4px 4px 0 0;
}

.auth-chart .auth-bar-1 {
  height: 38%;
}

.auth-chart .auth-bar-2 {
  height: 58%;
}

.auth-chart .auth-bar-3 {
  height: 47%;
}

.auth-chart .auth-bar-4 {
  height: 78%;
}

.auth-chart .auth-bar-5 {
  height: 66%;
}

.auth-chart .auth-bar-6 {
  height: 92%;
}

.auth-chart span:nth-child(5),
.auth-chart span:nth-child(6) {
  background: rgba(220, 233, 200, 0.58);
}

.auth-form-wrap {
  display: grid;
  padding: 55px;
  place-items: center;
}

.auth-form {
  width: 100%;
  max-width: 340px;
}

.auth-form h2 {
  font-size: 30px;
}

.auth-description {
  margin: 10px 0 30px;
  color: #7e8e89;
  font-size: 11px;
  line-height: 1.8;
}

.password-shell {
  padding-right: 8px;
}

.password-toggle {
  flex: 0 0 auto;
  padding: 6px 8px;
  color: #748580;
  font-size: 9px;
  cursor: pointer;
  background: transparent;
  border: 0;
  border-radius: 6px;
}

.password-toggle:hover {
  color: var(--green);
  background: var(--green-soft);
}

.setup-warning {
  margin: -8px 0 20px;
  padding: 10px 12px;
  color: #9d632e;
  font-size: 9px;
  line-height: 1.7;
  background: #fff8e9;
  border-left: 2px solid #e2a95e;
  border-radius: 3px 7px 7px 3px;
}

.dashboard {
  width: min(1280px, calc(100% - 56px));
  margin: 0 auto;
  padding: 52px 0 72px;
  animation: fadeUp 420ms ease both;
}

.dashboard-heading {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 20px;
  margin-bottom: 28px;
}

.eyebrow.dark {
  margin-bottom: 12px;
  color: #82908c;
}

.dashboard-heading h1 {
  margin: 0;
  font-family: var(--font-serif);
  font-size: 38px;
  letter-spacing: -0.03em;
}

.dashboard-heading > div > p:last-child {
  margin: 8px 0 0;
  color: #7a8985;
  font-size: 11px;
}

.live-badge {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 8px 12px;
  color: #447760;
  font-size: 9px;
  background: #e7f1e9;
  border: 1px solid #d5e7da;
  border-radius: 20px;
}

.live-badge i {
  width: 6px;
  height: 6px;
  background: #55a077;
  border-radius: 50%;
  box-shadow: 0 0 0 3px rgba(85, 160, 119, 0.13);
}

.stats-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 14px;
  margin-bottom: 20px;
}

.stat-card {
  display: grid;
  grid-template-columns: 44px 1fr auto;
  gap: 13px;
  align-items: center;
  min-height: 108px;
  padding: 22px;
  background: var(--white);
  border: 1px solid #e3e7e1;
  border-radius: 16px;
  box-shadow: 0 6px 20px rgba(28, 55, 50, 0.035);
}

.stat-card.stat-primary {
  color: var(--white);
  background: var(--green);
  border-color: var(--green);
}

.stat-icon {
  display: grid;
  width: 43px;
  height: 43px;
  color: var(--green);
  background: var(--green-soft);
  border-radius: 12px;
  place-items: center;
}

.stat-primary .stat-icon {
  color: var(--green);
  background: var(--lime);
}

.stat-icon.orange {
  color: #b55c35;
  background: var(--orange-soft);
}

.stat-icon.blue {
  color: var(--blue);
  background: var(--blue-soft);
}

.stat-icon.green {
  color: #3f8062;
  background: #e8f2ea;
}

.stat-icon svg {
  width: 22px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.6;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.stat-card > div:nth-child(2) {
  display: grid;
  gap: 2px;
}

.stat-card span {
  color: #7d8d88;
  font-size: 9px;
}

.stat-card strong {
  font-family: var(--font-serif);
  font-size: 26px;
  line-height: 1.15;
}

.stat-card small {
  align-self: end;
  padding-bottom: 3px;
  color: #9aa5a1;
  font-size: 8px;
}

.stat-primary span,
.stat-primary small {
  color: rgba(255, 255, 255, 0.55);
}

.backup-card {
  display: grid;
  grid-template-columns: 46px minmax(0, 1fr) auto;
  gap: 14px;
  align-items: center;
  padding: 16px 18px;
  margin-bottom: 18px;
  background:
    linear-gradient(120deg, rgba(232, 241, 237, 0.95), rgba(250, 248, 239, 0.92)),
    var(--white);
  border: 1px solid #dce5df;
  border-radius: 16px;
}

.backup-icon {
  display: grid;
  width: 42px;
  height: 42px;
  color: var(--green);
  background: var(--white);
  border: 1px solid #dce5df;
  border-radius: 12px;
  place-items: center;
}

.backup-icon svg {
  width: 22px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.6;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.backup-copy {
  display: grid;
  gap: 5px;
  min-width: 0;
}

.backup-copy > div {
  display: flex;
  align-items: baseline;
  flex-wrap: wrap;
  gap: 7px 12px;
}

.backup-copy strong {
  font-family: var(--font-serif);
  font-size: 15px;
}

.backup-copy span {
  color: #527069;
  font-size: 10px;
  font-weight: 700;
}

.backup-copy p {
  margin: 0;
  color: #73847f;
  font-size: 10px;
}

.backup-copy code {
  max-width: 100%;
  overflow: hidden;
  color: #7c8d88;
  font-family: var(--font-sans);
  font-size: 9px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.backup-card .backup-run-button {
  width: auto;
  min-width: 88px;
  padding-inline: 17px;
}

.records-card {
  background: var(--white);
  border: 1px solid #e1e6e0;
  border-radius: 20px;
  box-shadow: 0 12px 38px rgba(28, 55, 50, 0.05);
}

.records-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  padding: 23px 25px 16px;
}

.records-title {
  display: flex;
  align-items: baseline;
  gap: 11px;
}

.records-title h2 {
  margin: 0;
  font-family: var(--font-serif);
  font-size: 21px;
}

.records-title span {
  color: #8c9995;
  font-size: 9px;
}

.toolbar-actions {
  display: flex;
  align-items: center;
  gap: 8px;
}

.icon-button {
  display: grid;
  width: 36px;
  height: 36px;
  padding: 0;
  color: #61726d;
  cursor: pointer;
  background: #f4f7f3;
  border: 1px solid #e1e6e0;
  border-radius: 9px;
  place-items: center;
}

.icon-button:hover {
  color: var(--green);
  background: var(--green-soft);
}

.icon-button svg {
  width: 17px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.7;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.icon-button.spinning svg {
  animation: spin 0.7s linear infinite;
}

.export-button {
  min-height: 36px;
  padding: 0 13px;
  font-size: 10px;
  border-radius: 9px;
  box-shadow: none;
}

.export-button svg {
  width: 15px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.7;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.record-type-bar {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
  padding: 0 25px 14px;
}

.record-type-bar button {
  padding: 8px 13px;
  color: #687b76;
  font-size: 9px;
  cursor: pointer;
  background: #f4f7f3;
  border: 1px solid #e1e7e0;
  border-radius: 999px;
}

.record-type-bar button.active {
  color: var(--white);
  font-weight: 700;
  background: var(--green);
  border-color: var(--green);
}

.filters {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 0 25px 18px;
  border-bottom: 1px solid #edf0ec;
}

.search-field {
  display: flex;
  flex: 1;
  align-items: center;
  gap: 8px;
  max-width: 360px;
  height: 37px;
  padding: 0 11px;
  background: #f8faf7;
  border: 1px solid #e0e5df;
  border-radius: 9px;
}

.search-field:focus-within {
  border-color: #86a99e;
  box-shadow: 0 0 0 3px rgba(23, 77, 71, 0.06);
}

.search-field svg {
  width: 16px;
  color: #8d9b97;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
  stroke-linecap: round;
}

.search-field input {
  width: 100%;
  height: 100%;
  color: var(--ink);
  font-size: 10px;
  background: transparent;
  border: 0;
  outline: 0;
}

.search-field input::placeholder {
  color: #9ba5a2;
}

.date-field {
  display: flex;
  align-items: center;
  gap: 5px;
  height: 37px;
  padding: 0 8px;
  color: #81908b;
  font-size: 9px;
  background: #f8faf7;
  border: 1px solid #e0e5df;
  border-radius: 9px;
}

.date-field input {
  width: 105px;
  color: #4f625d;
  font-size: 9px;
  background: transparent;
  border: 0;
  outline: 0;
}

.filter-button {
  min-height: 37px;
  padding: 0 15px;
  font-size: 10px;
  border-radius: 9px;
  box-shadow: none;
}

.reset-button {
  height: 37px;
  padding: 0 7px;
  color: #7a8985;
  font-size: 9px;
  cursor: pointer;
  background: transparent;
  border: 0;
}

.reset-button:hover {
  color: var(--green);
}

.table-head {
  display: grid;
  grid-template-columns: minmax(260px, 1fr) 145px minmax(190px, 0.75fr) 68px;
  gap: 20px;
  padding: 14px 25px;
  color: #98a39f;
  font-size: 8px;
  font-weight: 700;
  letter-spacing: 0.06em;
  background: #fbfcfa;
  border-bottom: 1px solid #edf0ec;
}

.records-loading {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  min-height: 280px;
  color: #7d8b87;
  font-size: 10px;
}

.empty-state {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  min-height: 300px;
  text-align: center;
}

.empty-state > span {
  display: grid;
  width: 52px;
  height: 52px;
  color: #7b9690;
  background: #eef4ef;
  border-radius: 16px;
  place-items: center;
}

.empty-state svg {
  width: 25px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.5;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.empty-state h3 {
  margin: 14px 0 4px;
  font-family: var(--font-serif);
  font-size: 17px;
}

.empty-state p {
  margin: 0;
  color: #8f9b97;
  font-size: 9px;
}

.submission-row {
  display: grid;
  grid-template-columns: minmax(260px, 1fr) 145px minmax(190px, 0.75fr) 68px;
  gap: 20px;
  align-items: center;
  min-height: 89px;
  padding: 14px 25px;
  border-bottom: 1px solid #edf0ec;
  transition: background 140ms ease;
  content-visibility: auto;
  contain-intrinsic-size: 110px;
}

.submission-row:hover {
  background: #fcfdfb;
}

.submission-row.record-deleting {
  pointer-events: none;
  background: #fff8f4;
  opacity: 0.5;
}

.submission-row.record-removing {
  overflow: hidden;
  animation: record-collapse 220ms ease forwards;
}

@keyframes record-collapse {
  to {
    min-height: 0;
    max-height: 0;
    padding-top: 0;
    padding-bottom: 0;
    opacity: 0;
    transform: translateX(14px);
  }
}

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

.record-main {
  display: flex;
  align-items: center;
  min-width: 0;
  gap: 12px;
}

.account-avatar {
  display: grid;
  flex: 0 0 39px;
  width: 39px;
  height: 39px;
  color: var(--green);
  font-family: var(--font-serif);
  font-size: 16px;
  font-weight: 700;
  background: var(--green-soft);
  border-radius: 12px;
  place-items: center;
}

.record-copy {
  min-width: 0;
}

.record-account-row {
  display: flex;
  align-items: center;
  gap: 5px;
}

.record-account-row strong {
  overflow: hidden;
  color: #27413c;
  font-size: 12px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.copy-button {
  display: grid;
  width: 21px;
  height: 21px;
  padding: 0;
  color: #9ba6a2;
  cursor: pointer;
  opacity: 0;
  background: transparent;
  border: 0;
  border-radius: 5px;
  transition: opacity 140ms ease, background 140ms ease;
  place-items: center;
}

.submission-row:hover .copy-button,
.copy-button:focus {
  opacity: 1;
}

.copy-button:hover {
  color: var(--green);
  background: var(--green-soft);
}

.copy-button svg {
  width: 13px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.7;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.record-copy p {
  display: -webkit-box;
  max-width: 430px;
  margin: 4px 0 0;
  overflow: hidden;
  color: #71817d;
  font-size: 9px;
  line-height: 1.55;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}

.record-copy p.muted-note {
  color: #a0aaa7;
}

.record-form-badges {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
  margin-top: 4px;
}

.record-form-badges span {
  padding: 3px 6px;
  color: #60766f;
  font-size: 7px;
  background: #eff4f0;
  border-radius: 5px;
}

.record-detail-button {
  flex: 0 0 auto;
  opacity: 0;
}

.submission-row:hover .record-detail-button {
  opacity: 1;
}

.record-time {
  display: grid;
  gap: 3px;
}

.record-time strong {
  color: #405651;
  font-size: 10px;
  font-variant-numeric: tabular-nums;
}

.record-time small {
  color: #909c98;
  font-size: 8px;
}

.record-gallery {
  display: flex;
  align-items: center;
  gap: 5px;
}

.thumbnail-button {
  position: relative;
  flex: 0 0 38px;
  width: 38px;
  height: 38px;
  padding: 0;
  overflow: hidden;
  cursor: zoom-in;
  background: #edf1ed;
  border: 0;
  border-radius: 8px;
}

.thumbnail-button img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 200ms ease;
}

.thumbnail-button:hover img {
  transform: scale(1.06);
}

.more-images {
  position: absolute;
  inset: 0;
  display: grid;
  color: var(--white);
  font-size: 10px;
  font-weight: 700;
  background: rgba(20, 47, 44, 0.55);
  place-items: center;
}

.image-count {
  align-self: end;
  margin-left: 2px;
  padding-bottom: 2px;
  color: #929d99;
  font-size: 8px;
  white-space: nowrap;
}

.no-image {
  padding: 5px 8px;
  color: #9da7a4;
  font-size: 8px;
  background: #f5f7f4;
  border-radius: 6px;
}

.record-number {
  color: #9aa5a1;
  font-family: ui-monospace, "SFMono-Regular", Consolas, monospace;
  font-size: 8px;
  text-align: right;
}

.pagination {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  padding: 18px;
  border-top: 1px solid #edf0ec;
}

.pagination button {
  display: grid;
  width: 30px;
  height: 30px;
  padding: 0;
  color: #647570;
  cursor: pointer;
  background: #f6f8f5;
  border: 1px solid #e3e8e1;
  border-radius: 8px;
  place-items: center;
}

.pagination button:hover:not(:disabled) {
  color: var(--green);
  background: var(--green-soft);
}

.pagination button:disabled {
  cursor: default;
  opacity: 0.35;
}

.pagination button svg {
  width: 15px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.pagination span {
  color: #7e8e89;
  font-size: 9px;
}

.image-dialog {
  width: min(980px, calc(100vw - 40px));
  max-width: none;
  max-height: calc(100vh - 40px);
  padding: 0;
  overflow: hidden;
  color: var(--white);
  background: #112a27;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 18px;
  box-shadow: 0 30px 100px rgba(0, 0, 0, 0.35);
}

.image-dialog::backdrop {
  background: rgba(8, 20, 18, 0.76);
}

.dialog-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 15px 18px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.dialog-head > div {
  display: grid;
  gap: 3px;
}

.dialog-head strong {
  max-width: 700px;
  overflow: hidden;
  font-size: 11px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.dialog-head small {
  color: rgba(255, 255, 255, 0.48);
  font-size: 8px;
}

.dialog-head button {
  display: grid;
  width: 32px;
  height: 32px;
  padding: 0;
  color: rgba(255, 255, 255, 0.66);
  cursor: pointer;
  background: rgba(255, 255, 255, 0.06);
  border: 0;
  border-radius: 8px;
  place-items: center;
}

.dialog-head button:hover {
  color: var(--white);
  background: rgba(255, 255, 255, 0.11);
}

.dialog-head svg,
.dialog-nav svg {
  width: 16px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.dialog-body {
  position: relative;
  display: grid;
  min-height: 280px;
  max-height: calc(100vh - 190px);
  background: #0a1c1a;
  place-items: center;
}

.dialog-body img {
  display: block;
  max-width: 100%;
  max-height: calc(100vh - 190px);
  object-fit: contain;
}

.image-viewer-actions {
  position: absolute;
  z-index: 3;
  left: 12px;
  bottom: 12px;
  display: flex;
  max-width: calc(100% - 24px);
  align-items: center;
  gap: 10px;
  padding: 8px 10px;
  border-radius: 10px;
  background: rgba(8, 20, 18, 0.82);
  color: #fff;
  font-size: 10px;
}

.image-viewer-actions a {
  flex: 0 0 auto;
  padding: 5px 9px;
  border: 1px solid rgba(255, 255, 255, 0.28);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.12);
  color: #fff;
  font-weight: 700;
  text-decoration: none;
}

.image-viewer-actions span {
  color: rgba(255, 255, 255, 0.82);
  line-height: 1.4;
}

.dialog-nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 18px;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
}

.dialog-nav button {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 6px 9px;
  color: rgba(255, 255, 255, 0.65);
  font-size: 9px;
  cursor: pointer;
  background: transparent;
  border: 0;
  border-radius: 6px;
}

.dialog-nav button:hover:not(:disabled) {
  color: var(--white);
  background: rgba(255, 255, 255, 0.06);
}

.dialog-nav button:disabled {
  cursor: default;
  opacity: 0.35;
}

.dialog-nav span {
  color: rgba(255, 255, 255, 0.45);
  font-size: 8px;
}

.toast {
  position: fixed;
  z-index: 100;
  right: 24px;
  bottom: 24px;
  padding: 11px 15px;
  color: var(--white);
  font-size: 10px;
  pointer-events: none;
  background: #213d38;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 9px;
  box-shadow: 0 12px 35px rgba(20, 47, 44, 0.23);
  opacity: 0;
  transform: translateY(10px);
  transition: opacity 180ms ease, transform 180ms ease;
}

.toast.visible {
  opacity: 1;
  transform: translateY(0);
}

.header-actions {
  display: flex;
  align-items: center;
  gap: 12px;
}

.user-chip {
  display: flex;
  align-items: center;
  gap: 9px;
  padding: 6px 8px 6px 7px;
  background: rgba(255, 255, 255, 0.72);
  border: 1px solid rgba(23, 77, 71, 0.1);
  border-radius: 12px;
}

.user-chip > span {
  display: grid;
  width: 30px;
  height: 30px;
  color: var(--green);
  font-family: var(--font-serif);
  font-size: 13px;
  font-weight: 700;
  background: var(--green-soft);
  border-radius: 9px;
  place-items: center;
}

.user-chip > div {
  display: grid;
  gap: 1px;
}

.user-chip strong {
  max-width: 110px;
  overflow: hidden;
  color: #314a45;
  font-size: 10px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.user-chip small {
  color: #8a9894;
  font-size: 8px;
}

.user-chip button {
  padding: 5px 7px;
  color: #7b8985;
  font-size: 8px;
  cursor: pointer;
  background: transparent;
  border: 0;
  border-radius: 6px;
}

.user-chip button:hover {
  color: #a15031;
  background: var(--orange-soft);
}

.member-login-view {
  max-width: 500px;
  min-height: 570px;
  margin: 0 auto;
  padding-top: 15px;
}

.lock-label {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  margin-top: 17px;
  padding: 6px 9px;
  color: #66837c;
  font-size: 9px;
  background: var(--green-soft);
  border-radius: 15px;
}

.lock-label svg,
.login-help svg {
  width: 14px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.7;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.login-intro {
  margin: -10px 0 27px;
  color: #788984;
  font-size: 11px;
  line-height: 1.8;
}

.login-help {
  display: flex;
  align-items: center;
  gap: 7px;
  margin-top: 23px;
  padding-top: 17px;
  color: #8a9793;
  font-size: 9px;
  border-top: 1px solid #edf0ec;
}

.admin-tabs {
  display: flex;
  gap: 8px;
  margin-bottom: 18px;
}

.admin-tab {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-height: 39px;
  padding: 0 15px;
  color: #7b8b86;
  font-size: 10px;
  font-weight: 700;
  cursor: pointer;
  background: rgba(255, 255, 255, 0.58);
  border: 1px solid #dfe5de;
  border-radius: 10px;
}

.admin-tab svg {
  width: 16px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.7;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.admin-tab.active {
  color: var(--white);
  background: var(--green);
  border-color: var(--green);
  box-shadow: 0 8px 18px rgba(23, 77, 71, 0.13);
}

.user-management {
  animation: fadeUp 300ms ease both;
}

.user-overview {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  padding: 28px;
  margin-bottom: 16px;
  background:
    radial-gradient(circle at 85% 20%, rgba(220, 233, 200, 0.62), transparent 17rem),
    var(--white);
  border: 1px solid #e1e6e0;
  border-radius: 18px;
}

.user-overview h2 {
  margin: 0;
  font-family: var(--font-serif);
  font-size: 23px;
}

.user-overview > div:first-child > p:last-child {
  margin: 7px 0 0;
  color: #7d8d88;
  font-size: 10px;
}

.user-overview-actions {
  display: flex;
  align-items: center;
  gap: 16px;
}

.user-overview-actions > span {
  color: #73847f;
  font-size: 9px;
}

.user-overview-actions > span strong {
  color: var(--green);
  font-family: var(--font-serif);
  font-size: 21px;
}

.user-table-card {
  overflow: hidden;
  background: var(--white);
  border: 1px solid #e1e6e0;
  border-radius: 18px;
  box-shadow: 0 12px 38px rgba(28, 55, 50, 0.05);
}

.user-table-head,
.user-row {
  display: grid;
  grid-template-columns:
    minmax(170px, 1.15fr)
    minmax(72px, 0.45fr)
    82px
    minmax(115px, 0.7fr)
    minmax(115px, 0.7fr)
    78px
    minmax(145px, 0.85fr);
  gap: 18px;
  align-items: center;
  padding: 14px 22px;
}

.user-shift-filter {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  margin: 0 0 12px;
  padding: 12px 16px;
  border: 1px solid #e1e8e3;
  border-radius: 14px;
  background: #f8faf7;
}

.user-shift-filter > span {
  margin-right: 3px;
  color: #73817d;
  font-size: 9px;
  font-weight: 700;
}

.user-shift-filter button {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 7px 11px;
  border: 1px solid #dce5df;
  border-radius: 999px;
  background: #fff;
  color: #526560;
  font-size: 9px;
  font-weight: 700;
  cursor: pointer;
}

.user-shift-filter button b {
  min-width: 20px;
  padding: 2px 5px;
  border-radius: 999px;
  background: #edf2ef;
  color: #5c716a;
  font-size: 8px;
  text-align: center;
}

.user-shift-filter button.active {
  border-color: #4f8371;
  background: #174d47;
  color: #fff;
}

.user-shift-filter button.active b {
  background: rgba(255, 255, 255, 0.18);
  color: #fff;
}

.user-filter-empty {
  padding: 34px 18px;
  color: #7d8a86;
  font-size: 11px;
  text-align: center;
}

.subadmin-head {
  grid-template-columns: minmax(160px, 1fr) minmax(130px, 0.8fr) minmax(100px, 0.6fr) 80px minmax(150px, 0.8fr);
}

.user-table-head {
  color: #98a39f;
  font-size: 8px;
  font-weight: 700;
  letter-spacing: 0.06em;
  background: #fbfcfa;
  border-bottom: 1px solid #edf0ec;
}

.user-row {
  min-height: 72px;
  border-bottom: 1px solid #edf0ec;
}

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

.user-row-identity {
  display: flex;
  align-items: center;
  min-width: 0;
  gap: 10px;
}

.user-row-identity > div {
  display: grid;
  gap: 2px;
  min-width: 0;
}

.user-position-badge {
  width: fit-content;
  padding: 2px 6px;
  color: #9a5d38;
  font-size: 8px;
  font-weight: 700;
  background: var(--orange-soft);
  border-radius: 8px;
}

.user-role-pill,
.user-shift-pill {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: fit-content;
  min-height: 24px;
  padding: 4px 9px;
  border-radius: 999px;
  font-size: 9px;
  font-weight: 800;
  white-space: nowrap;
}

.user-role-pill {
  background: #eef3f0;
  color: #526760;
}

.user-role-pill.role-inspector {
  background: #fff1d5;
  color: #8a5e12;
}

.user-role-pill.role-debugger {
  background: #e5f1eb;
  color: #24614f;
}

.user-role-pill.role-supervisor {
  background: #e7ecf7;
  color: #3f5b8f;
}

.user-shift-pill {
  border: 1px solid transparent;
}

.user-shift-pill.shift-a {
  border-color: #b9d9cc;
  background: #e9f6ef;
  color: #23624f;
}

.user-shift-pill.shift-b {
  border-color: #c4d3ec;
  background: #edf3fc;
  color: #3e6197;
}

.user-row-avatar {
  display: grid;
  flex: 0 0 34px;
  width: 34px;
  height: 34px;
  color: var(--green);
  font-family: var(--font-serif);
  font-size: 14px;
  font-weight: 700;
  background: var(--green-soft);
  border-radius: 10px;
  place-items: center;
}

.user-row-identity strong {
  display: block;
  overflow: hidden;
  color: #314a45;
  font-size: 11px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.user-row-identity small,
.user-row-meta small {
  color: #909c98;
  font-size: 8px;
}

.user-row-login {
  color: #647772;
  font-family: ui-monospace, "SFMono-Regular", Consolas, monospace;
  font-size: 9px;
}

.user-row-meta {
  display: grid;
  gap: 3px;
}

.user-row-meta strong {
  color: #405651;
  font-size: 10px;
}

.status-pill {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  width: fit-content;
  padding: 5px 8px;
  color: #39785e;
  font-size: 8px;
  background: #e8f3eb;
  border-radius: 12px;
}

.status-pill::before {
  width: 5px;
  height: 5px;
  content: "";
  background: currentColor;
  border-radius: 50%;
}

.status-pill.inactive {
  color: #9b7157;
  background: #f7eee7;
}

.user-row-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 5px;
  justify-content: flex-end;
}

.text-button {
  padding: 6px 8px;
  color: #617570;
  font-size: 8px;
  cursor: pointer;
  background: #f4f7f3;
  border: 1px solid #e3e8e2;
  border-radius: 7px;
}

.text-button:hover {
  color: var(--green);
  background: var(--green-soft);
}

.text-button:disabled {
  color: #aeb8b5;
  cursor: not-allowed;
  background: #f1f4f1;
}

.text-button:disabled:hover {
  color: #aeb8b5;
  background: #f1f4f1;
}

.text-button.danger:hover {
  color: #a95134;
  background: var(--orange-soft);
}

.user-dialog,
.credential-dialog {
  width: min(520px, calc(100vw - 32px));
  padding: 0;
  color: var(--ink);
  background: var(--white);
  border: 0;
  border-radius: 20px;
  box-shadow: 0 30px 100px rgba(8, 20, 18, 0.28);
}

.user-dialog::backdrop,
.credential-dialog::backdrop {
  background: rgba(8, 20, 18, 0.62);
}

.user-dialog .dialog-head {
  color: var(--white);
  background: var(--green);
}

.user-dialog-body {
  padding: 24px 26px 10px;
}

.user-dialog-body input[type="text"] {
  width: 100%;
  height: 45px;
  padding: 0 12px;
  color: var(--ink);
  background: #fbfcf9;
  border: 1px solid var(--line);
  border-radius: 9px;
  outline: 0;
}

.user-dialog-body input[type="text"]:focus {
  border-color: #6e978e;
  box-shadow: 0 0 0 3px rgba(23, 77, 71, 0.07);
}

.password-action-row {
  display: flex;
  gap: 7px;
}

.password-action-row input {
  flex: 1;
  min-width: 0;
}

.small-button {
  min-height: 45px;
  padding: 0 12px;
  white-space: nowrap;
}

.active-toggle {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 13px;
  cursor: pointer;
  background: #f8faf7;
  border: 1px solid #e3e8e2;
  border-radius: 10px;
}

.active-toggle input {
  position: absolute;
  opacity: 0;
}

.active-toggle > span {
  position: relative;
  flex: 0 0 34px;
  width: 34px;
  height: 19px;
  background: #c9d2ce;
  border-radius: 12px;
  transition: background 160ms ease;
}

.active-toggle > span::after {
  position: absolute;
  top: 3px;
  left: 3px;
  width: 13px;
  height: 13px;
  content: "";
  background: var(--white);
  border-radius: 50%;
  transition: transform 160ms ease;
}

.active-toggle input:checked + span {
  background: var(--green);
}

.active-toggle input:checked + span::after {
  transform: translateX(15px);
}

.active-toggle > div {
  display: grid;
  gap: 2px;
}

.active-toggle strong {
  font-size: 10px;
}

.active-toggle small {
  color: #8d9995;
  font-size: 8px;
}

.user-dialog-footer {
  display: flex;
  justify-content: flex-end;
  gap: 8px;
  padding: 16px 26px 24px;
}

.options-hint {
  color: #7e8e89;
  font-size: 9px;
}

.custom-field-builder {
  display: grid;
  grid-template-columns: minmax(180px, 1fr) 150px auto auto;
  align-items: end;
  gap: 10px;
  padding: 15px 17px;
  margin-bottom: 14px;
  background: var(--white);
  border: 1px solid #e1e6e0;
  border-radius: 14px;
}

.custom-field-builder > div {
  display: grid;
  gap: 5px;
}

.custom-field-builder label {
  color: #5f716c;
  font-size: 8px;
  font-weight: 700;
}

.custom-field-builder input[type="text"],
.custom-field-builder select {
  height: 39px;
  padding: 0 10px;
  color: var(--ink);
  font-size: 10px;
  background: #f9fbf8;
  border: 1px solid #dfe5de;
  border-radius: 8px;
  outline: 0;
}

.custom-field-builder .primary-button {
  min-height: 39px;
  padding: 0 13px;
  font-size: 9px;
  border-radius: 8px;
}

.inline-checkbox {
  display: flex !important;
  align-items: center;
  gap: 6px;
  height: 39px;
  white-space: nowrap;
}

.inline-checkbox input {
  width: 15px;
  height: 15px;
  accent-color: var(--green);
}

.option-layout {
  display: grid;
  grid-template-columns: 235px minmax(0, 1fr);
  gap: 14px;
}

.product-map-admin-card {
  display: block;
  margin-bottom: 14px;
  padding: 0;
  overflow: hidden;
  background: linear-gradient(120deg, #eef5f0, #faf8ef);
  border: 1px solid #dce6df;
  border-radius: 14px;
}

.product-map-card-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  padding: 15px 17px;
}

.product-map-toggle {
  display: flex;
  flex: 1 1 auto;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  min-width: 0;
  padding: 0;
  color: inherit;
  font: inherit;
  text-align: left;
  cursor: pointer;
  background: transparent;
  border: 0;
}

.product-map-toggle-copy {
  display: grid;
  gap: 3px;
  min-width: 0;
}

.product-map-toggle-copy > strong {
  color: #213f39;
  font-family: var(--font-serif);
  font-size: 17px;
}

.product-map-toggle-copy > small {
  overflow: hidden;
  color: #71827d;
  font-size: 10px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.product-map-toggle-action {
  display: inline-flex;
  flex: 0 0 auto;
  align-items: center;
  gap: 7px;
  padding: 7px 10px;
  color: #4f6e65;
  font-size: 9px;
  background: rgba(255, 255, 255, 0.72);
  border: 1px solid #dbe5dd;
  border-radius: 9px;
}

.product-map-toggle-action i {
  width: 7px;
  height: 7px;
  border-right: 1.5px solid currentColor;
  border-bottom: 1.5px solid currentColor;
  transform: rotate(45deg) translateY(-1px);
  transition: transform 160ms ease;
}

.product-map-admin-card.expanded .product-map-toggle-action i {
  transform: rotate(225deg) translate(-1px, -1px);
}

.product-map-toggle:focus-visible {
  outline: 3px solid rgba(31, 103, 91, 0.22);
  outline-offset: 3px;
  border-radius: 8px;
}

.product-map-card-body {
  padding: 13px 17px 17px;
  border-top: 1px solid #dfe8e1;
}

.product-map-admin-card h3 {
  margin: 3px 0 4px;
  font-family: var(--font-serif);
  font-size: 17px;
}

.product-map-admin-card p:last-child {
  margin: 0;
  color: #71827d;
  font-size: 10px;
}

.product-map-admin-card #productMapSummary {
  margin: 0;
  color: #71827d;
  font-size: 10px;
}

.product-map-admin-card .primary-button {
  flex: 0 0 auto;
}

.product-map-search {
  display: flex;
  align-items: center;
  gap: 9px;
  margin-top: 12px;
  color: #61746e;
  font-size: 10px;
}

.product-map-search span {
  flex: 0 0 auto;
}

.product-map-search input {
  width: min(100%, 360px);
  height: 40px;
  padding: 0 12px;
  color: var(--ink);
  font: inherit;
  background: rgba(255, 255, 255, 0.86);
  border: 1px solid #d6e0d8;
  border-radius: 9px;
  outline: 0;
}

.product-map-search input:focus {
  border-color: #6d9e94;
  box-shadow: 0 0 0 3px rgba(23, 77, 71, 0.08);
}

.product-map-preview {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(230px, 1fr));
  gap: 8px;
  margin-top: 10px;
}

.product-map-preview-item {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  align-items: start;
  gap: 9px;
  padding: 9px 10px;
  background: rgba(255, 255, 255, 0.8);
  border: 1px solid #e0e8e1;
  border-radius: 9px;
}

.product-map-preview-item > strong {
  color: var(--green);
  font-size: 10px;
  white-space: nowrap;
}

.product-map-preview-item > div {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
}

.product-map-preview-item span {
  padding: 3px 6px;
  color: #5d706a;
  font-size: 8px;
  background: #eef4ef;
  border-radius: 6px;
}

.product-map-preview-item span.no-fixture {
  color: #8a673f;
  background: #fbf2df;
}

.product-map-preview-empty {
  grid-column: 1 / -1;
  padding: 18px;
  color: #87958f;
  font-size: 10px;
  text-align: center;
  background: rgba(255, 255, 255, 0.65);
  border-radius: 9px;
}

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

.product-fixture-bulk-text {
  width: 100%;
  min-height: min(48vh, 440px);
  padding: 13px;
  color: var(--ink);
  font-family: "Microsoft YaHei", "PingFang SC", sans-serif;
  font-size: 14px;
  line-height: 1.65;
  resize: vertical;
  background: #fbfcf9;
  border: 1px solid #dfe6df;
  border-radius: 10px;
}

.product-fixture-bulk-text:focus {
  border-color: #6d9e94;
  box-shadow: 0 0 0 3px rgba(23, 77, 71, 0.08);
  outline: 0;
}

.product-fixture-entry-count {
  margin: 6px 0 0;
  color: var(--green);
  font-size: 10px;
  font-weight: 700;
}

.product-fixture-entry-count.has-error {
  color: #a85c37;
}

.option-field-list {
  display: grid;
  align-content: start;
  gap: 6px;
  padding: 12px;
  background: var(--white);
  border: 1px solid #e1e6e0;
  border-radius: 16px;
}

.option-field-group-title {
  margin: 10px 4px 2px;
  padding-top: 9px;
  color: var(--green);
  font-family: var(--font-serif);
  font-size: 11px;
  border-top: 1px solid #e7ece6;
}

.option-field-row {
  position: relative;
  display: flex;
  align-items: center;
  gap: 2px;
  min-width: 0;
}

.option-field-drag,
.option-drag-handle {
  flex: 0 0 22px;
  width: 22px;
  height: 28px;
  padding: 0;
  color: #91a09c;
  font-size: 15px;
  line-height: 1;
  cursor: grab;
  touch-action: none;
  user-select: none;
  background: transparent;
  border: 0;
  border-radius: 6px;
}

.option-field-drag:hover,
.option-drag-handle:hover {
  color: var(--green);
  background: var(--green-soft);
}

.option-field-row .option-field-button {
  flex: 1;
  min-width: 0;
  overflow: hidden;
  padding-right: 50px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.option-field-tools {
  position: absolute;
  top: 50%;
  right: 4px;
  display: flex;
  gap: 1px;
  transform: translateY(-50%);
}

.option-field-delete {
  display: grid;
  width: 20px;
  height: 20px;
  padding: 0;
  color: #9baba6;
  font-size: 13px;
  cursor: pointer;
  background: transparent;
  border: 0;
  border-radius: 50%;
  place-items: center;
}

.option-field-delete:hover {
  color: #a84f32;
  background: var(--orange-soft);
}

.option-field-button {
  padding: 12px 13px;
  color: #667772;
  font-size: 10px;
  text-align: left;
  cursor: pointer;
  background: transparent;
  border: 0;
  border-radius: 9px;
}

.option-field-button:hover {
  color: var(--green);
  background: #f3f7f3;
}

.option-field-button.active {
  color: var(--white);
  font-weight: 700;
  background: var(--green);
}

.option-editor-card {
  padding: 22px;
  background: var(--white);
  border: 1px solid #e1e6e0;
  border-radius: 16px;
}

.option-editor-head {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  padding-bottom: 17px;
  border-bottom: 1px solid #edf0ec;
}

.option-editor-head h3 {
  margin: 0;
  font-family: var(--font-serif);
  font-size: 18px;
}

.option-editor-head p {
  margin: 4px 0 0;
  color: #8a9793;
  font-size: 8px;
}

.option-add-form {
  display: flex;
  gap: 7px;
}

.option-add-form input {
  width: 190px;
  height: 37px;
  padding: 0 10px;
  font-size: 10px;
  background: #f9fbf8;
  border: 1px solid #dfe5de;
  border-radius: 8px;
  outline: 0;
}

.option-add-form input:focus {
  border-color: #72978f;
}

.option-add-form .primary-button {
  min-height: 37px;
  padding: 0 12px;
  font-size: 9px;
  border-radius: 8px;
}

.option-list {
  display: grid;
  gap: 7px;
  padding-top: 15px;
}

.option-bulk-toolbar {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 9px;
  margin-top: 14px;
  padding: 9px 10px;
  background: #f5f8f4;
  border: 1px solid #e3e9e2;
  border-radius: 9px;
}

.option-search-field {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-top: 14px;
  padding: 0 11px;
  background: #fbfcf9;
  border: 1px solid #e1e7e0;
  border-radius: 9px;
}

.option-search-field svg {
  width: 16px;
  fill: none;
  stroke: #82918c;
  stroke-width: 1.7;
}

.option-search-field input {
  width: 100%;
  height: 38px;
  padding: 0;
  font-size: 10px;
  background: transparent;
  border: 0;
  outline: 0;
}

.option-bulk-toolbar > span {
  color: #7d8d88;
  font-size: 9px;
}

.option-bulk-toolbar > div {
  display: flex;
  flex-wrap: wrap;
  gap: 5px;
  margin-left: auto;
}

.option-select-all {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: #536761;
  font-size: 9px;
  cursor: pointer;
}

.option-select-all input,
.option-row-select {
  width: 15px;
  height: 15px;
  accent-color: var(--green);
}

.option-row {
  display: grid;
  grid-template-columns: 22px 28px 34px minmax(0, 1fr) 70px minmax(150px, auto);
  align-items: center;
  gap: 10px;
  min-height: 47px;
  padding: 7px 9px;
  background: #f9fbf8;
  border: 1px solid #e8ece7;
  border-radius: 9px;
}

.option-row.is-drag-origin,
.option-field-row.is-drag-origin {
  opacity: 0.2;
}

.sort-ghost {
  position: fixed;
  z-index: 1000;
  top: 0;
  left: 0;
  margin: 0 !important;
  overflow: hidden;
  pointer-events: none;
  opacity: 0.97;
  background: var(--white);
  border-radius: 9px;
  box-shadow: 0 14px 38px rgba(23, 77, 71, 0.22);
  will-change: transform;
}

.option-field-row.sort-ghost {
  padding: 4px;
  border: 1px solid #dce5df;
  border-radius: 10px;
}

.sort-ghost * {
  pointer-events: none !important;
}

.option-row.sort-target-before,
.option-field-row.sort-target-before {
  box-shadow: inset 0 3px 0 var(--green);
}

.option-row.sort-target-after,
.option-field-row.sort-target-after {
  box-shadow: inset 0 -3px 0 var(--green);
}

.option-list.is-sorting,
.option-field-list.is-sorting {
  cursor: grabbing;
}

.sort-ghost * {
  cursor: grabbing;
}

.option-order {
  color: #96a19e;
  font-family: ui-monospace, "SFMono-Regular", Consolas, monospace;
  font-size: 8px;
}

.option-row > strong {
  overflow: hidden;
  color: #3e554f;
  font-size: 10px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.option-row-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 5px;
}

.option-status {
  width: fit-content;
  padding: 4px 7px;
  color: #40785f;
  font-size: 8px;
  background: #e8f3eb;
  border-radius: 10px;
}

.option-status.inactive {
  color: #956b50;
  background: #f7eee7;
}

.credential-dialog {
  padding: 30px;
  text-align: center;
}

.credential-icon {
  display: grid;
  width: 54px;
  height: 54px;
  margin: 0 auto 14px;
  color: var(--green);
  background: var(--green-soft);
  border-radius: 16px;
  place-items: center;
}

.credential-icon svg {
  width: 25px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.7;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.credential-dialog h3 {
  margin: 0;
  font-family: var(--font-serif);
  font-size: 22px;
}

.credential-dialog > p {
  margin: 8px auto 20px;
  color: #7c8c87;
  font-size: 10px;
  line-height: 1.7;
}

.credential-box {
  display: grid;
  grid-template-columns: 80px 1fr;
  gap: 11px 14px;
  padding: 17px;
  text-align: left;
  background: #f6f9f5;
  border: 1px solid #e2e8e1;
  border-radius: 12px;
}

.credential-box span {
  color: #8b9894;
  font-size: 9px;
}

.credential-box strong {
  overflow-wrap: anywhere;
  color: #2e4943;
  font-family: ui-monospace, "SFMono-Regular", Consolas, monospace;
  font-size: 11px;
  user-select: all;
}

.credential-actions {
  display: flex;
  justify-content: center;
  gap: 8px;
  margin-top: 20px;
}

.record-dialog {
  width: min(760px, calc(100vw - 32px));
  max-height: calc(100vh - 40px);
  padding: 0;
  overflow: hidden;
  color: var(--ink);
  background: var(--white);
  border: 0;
  border-radius: 20px;
  box-shadow: 0 30px 100px rgba(8, 20, 18, 0.3);
}

.record-dialog::backdrop {
  background: rgba(8, 20, 18, 0.66);
}

.record-dialog .dialog-head {
  color: var(--white);
  background: var(--green);
}

.record-dialog-body {
  max-height: calc(100vh - 120px);
  padding: 24px;
  overflow-y: auto;
}

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

.record-detail-item {
  min-height: 68px;
  padding: 12px;
  background: #f7faf6;
  border: 1px solid #e6ebe5;
  border-radius: 9px;
}

.record-detail-item.wide {
  grid-column: span 2;
}

.record-detail-item.full {
  grid-column: 1 / -1;
}

.record-detail-item span {
  display: block;
  margin-bottom: 5px;
  color: #8a9893;
  font-size: 8px;
}

.record-detail-item strong,
.record-detail-item p {
  margin: 0;
  color: #334d47;
  font-size: 10px;
  line-height: 1.7;
  white-space: pre-wrap;
}

.record-detail-images {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 7px;
  margin-top: 15px;
}

.record-detail-images button {
  aspect-ratio: 1.3;
  padding: 0;
  overflow: hidden;
  cursor: zoom-in;
  background: #edf1ed;
  border: 0;
  border-radius: 9px;
}

.record-detail-images img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.today-section {
  padding: 0 0 80px;
}

.pending-confirmation-section {
  margin-top: 22px;
  padding: 24px;
  background: var(--white);
  border: 1px solid #e1e6e0;
  border-radius: 20px;
  box-shadow: 0 12px 38px rgba(28, 55, 50, 0.05);
}

.pending-confirmation-list {
  display: grid;
  gap: 10px;
}

.pending-confirmation-card {
  padding: 14px;
  background: #fbfcf9;
  border: 1px solid #e5eae4;
  border-radius: 12px;
}

.pending-confirmation-card h3 {
  margin: 0 0 5px;
  font-size: 14px;
}

.pending-confirmation-card p {
  margin: 3px 0;
  color: #697c76;
  font-size: 10px;
}

.pending-confirmation-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
  margin-top: 10px;
}

.today-heading {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 20px;
  margin-bottom: 16px;
  padding: 27px 30px;
  background:
    radial-gradient(circle at 86% 10%, rgba(220, 233, 200, 0.58), transparent 16rem),
    var(--white);
  border: 1px solid #e1e6e0;
  border-radius: 19px;
}

.today-heading h2 {
  margin: 0;
  font-family: var(--font-serif);
  font-size: 25px;
}

.today-heading > div > p:last-child {
  margin: 6px 0 0;
  color: #7d8d88;
  font-size: 10px;
}

.today-heading .secondary-button {
  gap: 6px;
  min-height: 37px;
  padding: 0 12px;
}

.today-heading .secondary-button svg {
  width: 14px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
}

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

.today-record-card {
  padding: 0;
  overflow: hidden;
  background: rgba(255, 255, 255, 0.94);
  border: 1px solid #e1e6e0;
  border-radius: 16px;
  box-shadow: 0 8px 24px rgba(28, 55, 50, 0.045);
  content-visibility: auto;
  contain-intrinsic-size: 132px;
  transition:
    border-color 160ms ease,
    box-shadow 160ms ease;
}

.today-record-card.expanded {
  border-color: #bdcfc4;
  box-shadow: 0 12px 30px rgba(28, 55, 50, 0.075);
}

.today-record-summary {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 11px 14px;
  width: 100%;
  padding: 16px;
  color: inherit;
  font: inherit;
  text-align: left;
  cursor: pointer;
  appearance: none;
  background: transparent;
  border: 0;
}

.today-record-summary:hover {
  background: #fbfcf9;
}

.today-record-summary:focus-visible {
  outline: 3px solid rgba(31, 103, 91, 0.25);
  outline-offset: -3px;
}

.today-summary-top {
  display: flex;
  grid-column: 1 / -1;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  min-width: 0;
}

.today-summary-identity {
  display: flex;
  align-items: center;
  min-width: 0;
  gap: 9px;
}

.today-summary-identity > div {
  min-width: 0;
}

.today-summary-identity strong {
  display: block;
  overflow: hidden;
  color: #314a45;
  font-size: 12px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.today-summary-identity small {
  display: block;
  margin-top: 2px;
  color: #8d9995;
  font-size: 8px;
}

.today-summary-meta {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 7px;
  min-width: 0;
}

.today-summary-meta > span {
  min-width: 0;
  padding: 7px 8px;
  background: #f7f9f6;
  border-radius: 8px;
}

.today-summary-meta small {
  display: block;
  margin-bottom: 3px;
  color: #8d9995;
  font-size: 7px;
}

.today-summary-meta strong {
  display: block;
  overflow: hidden;
  color: #3e554f;
  font-size: 9px;
  font-weight: 600;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.today-summary-toggle {
  display: flex;
  align-items: center;
  align-self: end;
  gap: 5px;
  padding: 6px 8px;
  color: #55736a;
  font-size: 8px;
  white-space: nowrap;
  background: #edf3ee;
  border-radius: 9px;
}

.today-summary-toggle i {
  width: 6px;
  height: 6px;
  border-right: 1.5px solid currentColor;
  border-bottom: 1.5px solid currentColor;
  transform: rotate(45deg) translateY(-1px);
  transition: transform 160ms ease;
}

.today-record-card.expanded .today-summary-toggle i {
  transform: rotate(225deg) translate(-1px, -1px);
}

.today-record-body {
  padding: 0 16px 16px;
  border-top: 1px solid #edf0ec;
}

.today-record-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding-bottom: 13px;
  border-bottom: 1px solid #edf0ec;
}

.today-record-head > div {
  display: flex;
  align-items: center;
  min-width: 0;
  gap: 9px;
}

.today-record-avatar {
  display: grid;
  flex: 0 0 34px;
  width: 34px;
  height: 34px;
  color: var(--green);
  font-family: var(--font-serif);
  font-size: 14px;
  font-weight: 700;
  background: var(--green-soft);
  border-radius: 10px;
  place-items: center;
}

.today-record-head strong {
  display: block;
  color: #314a45;
  font-size: 11px;
}

.today-record-head small {
  color: #8d9995;
  font-size: 8px;
}

.today-duration {
  flex: 0 0 auto;
  padding: 5px 7px;
  color: #46725f;
  font-size: 8px;
  background: #eaf3ec;
  border-radius: 12px;
}

.today-detail-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 7px;
  padding-top: 13px;
}

.today-detail {
  min-width: 0;
  padding: 8px;
  background: #f8faf7;
  border-radius: 8px;
}

.today-detail.full {
  grid-column: 1 / -1;
}

.today-detail span {
  display: block;
  margin-bottom: 3px;
  color: #8d9995;
  font-size: 7px;
}

.today-detail strong {
  color: #3e554f;
  font-size: 9px;
  font-weight: 600;
  line-height: 1.6;
  white-space: pre-wrap;
}

.today-image-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 6px;
  margin-top: 10px;
}

.today-image-grid button {
  aspect-ratio: 1;
  padding: 0;
  overflow: hidden;
  cursor: zoom-in;
  background: #edf1ed;
  border: 0;
  border-radius: 8px;
}

.today-image-grid img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.today-image-dialog {
  position: relative;
  width: min(900px, calc(100vw - 28px));
  max-width: none;
  max-height: calc(100vh - 28px);
  padding: 0;
  overflow: hidden;
  background: #0d2521;
  border: 0;
  border-radius: 16px;
}

.today-image-dialog::backdrop {
  background: rgba(8, 20, 18, 0.78);
}

.today-image-dialog > button {
  position: absolute;
  z-index: 2;
  top: 10px;
  right: 10px;
  display: grid;
  width: 34px;
  height: 34px;
  padding: 0;
  color: var(--white);
  cursor: pointer;
  background: rgba(8, 20, 18, 0.72);
  border: 0;
  border-radius: 9px;
  place-items: center;
}

.today-image-dialog > button svg {
  width: 17px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
  stroke-linecap: round;
}

.today-image-dialog img {
  display: block;
  max-width: 100%;
  max-height: calc(100vh - 28px);
  margin: auto;
  object-fit: contain;
}

.today-image-dialog .image-viewer-actions {
  left: 10px;
  bottom: 10px;
}

.option-empty {
  padding: 35px;
  color: #8a9793;
  font-size: 10px;
  text-align: center;
}

.requirements-card {
  padding: 12px;
  background: var(--white);
  border: 1px solid #e1e6e0;
  border-radius: 16px;
}

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

.requirement-group-title {
  grid-column: 1 / -1;
  margin: 12px 0 2px;
  padding: 8px 2px 4px;
  color: var(--green);
  font-family: var(--font-serif);
  font-size: 14px;
  border-bottom: 1px solid #e7ece6;
}

.requirement-group-title:first-child {
  margin-top: 0;
}

.requirement-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 52px;
  padding: 10px 13px;
  background: #f8faf7;
  border: 1px solid #e7ebe6;
  border-radius: 9px;
}

.requirement-row > div {
  display: grid;
  gap: 2px;
}

.requirement-row strong {
  color: #3b534d;
  font-size: 10px;
}

.requirement-row small {
  color: #8e9b97;
  font-size: 8px;
}

.requirement-switch {
  position: relative;
  display: block;
  flex: 0 0 38px;
  width: 38px;
  height: 22px;
  cursor: pointer;
}

.requirement-switch input {
  position: absolute;
  opacity: 0;
}

.requirement-switch span {
  position: absolute;
  inset: 0;
  background: #cbd3cf;
  border-radius: 14px;
  transition: background 160ms ease;
}

.requirement-switch span::after {
  position: absolute;
  top: 3px;
  left: 3px;
  width: 16px;
  height: 16px;
  content: "";
  background: var(--white);
  border-radius: 50%;
  transition: transform 160ms ease;
}

.requirement-switch input:checked + span {
  background: var(--green);
}

.requirement-switch input:checked + span::after {
  transform: translateX(16px);
}

.record-editor-dialog {
  width: min(760px, calc(100vw - 28px));
  max-height: calc(100vh - 28px);
  padding: 0;
  overflow: hidden;
  color: var(--ink);
  background: var(--white);
  border: 0;
  border-radius: 20px;
  box-shadow: 0 30px 100px rgba(8, 20, 18, 0.3);
}

.record-editor-dialog::backdrop {
  background: rgba(8, 20, 18, 0.68);
}

.record-editor-dialog .dialog-head {
  color: var(--white);
  background: var(--green);
}

.record-editor-body {
  max-height: calc(100vh - 145px);
  padding: 22px 24px 5px;
  overflow-y: auto;
}

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

.record-editor-dialog .field input[type="text"],
.record-editor-dialog .field input[type="file"] {
  width: 100%;
}

.record-editor-dialog .field input[type="text"] {
  height: 49px;
  padding: 0 12px;
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  outline: 0;
}

.record-editor-dialog .field input[type="file"] {
  padding: 10px;
  font-size: 10px;
  background: #f8faf7;
  border: 1px dashed #ccd6ce;
  border-radius: 9px;
}

.dashboard-analytics {
  animation: fadeUp 300ms ease both;
}

.dashboard-only {
  max-width: 1320px;
}

.dashboard-only-heading {
  padding: 0;
  margin-bottom: 12px;
  background: transparent;
  border: 0;
  box-shadow: none;
  align-items: center;
}

.dashboard-only-heading > div:last-child {
  display: flex;
  align-items: center;
  gap: 8px;
  color: #84928e;
  font-size: 8px;
}

.dashboard-login-card {
  min-height: 540px;
}

.analytics-heading {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 20px;
  margin-bottom: 15px;
  padding: 25px 28px;
  background:
    radial-gradient(circle at 88% 20%, rgba(220, 233, 200, 0.66), transparent 18rem),
    var(--white);
  border: 1px solid #e1e6e0;
  border-radius: 18px;
}

.analytics-heading h2 {
  margin: 0;
  font-family: var(--font-serif);
  font-size: 25px;
}

.analytics-heading > div:first-child > p:last-child {
  margin: 6px 0 0;
  color: #7c8c87;
  font-size: 10px;
}

.analytics-actions {
  display: flex;
  align-items: center;
  gap: 8px;
}

.range-tabs {
  display: flex;
  padding: 3px;
  background: #edf2ed;
  border-radius: 9px;
}

.range-tabs button {
  min-height: 30px;
  padding: 0 10px;
  color: #748680;
  font-size: 8px;
  cursor: pointer;
  background: transparent;
  border: 0;
  border-radius: 7px;
}

.range-tabs button.active {
  color: var(--white);
  font-weight: 700;
  background: var(--green);
}

.analytics-stats {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 11px;
  margin-bottom: 13px;
}

.analytics-stats article {
  display: grid;
  grid-template-columns: 1fr auto;
  align-items: end;
  min-height: 103px;
  padding: 18px;
  background: var(--white);
  border: 1px solid #e1e6e0;
  border-radius: 14px;
}

.analytics-stats article:first-child {
  color: var(--white);
  background: var(--green);
  border-color: var(--green);
}

.analytics-stats span {
  grid-column: 1 / -1;
  align-self: start;
  color: #7f8f8a;
  font-size: 8px;
}

.analytics-stats article:first-child span,
.analytics-stats article:first-child small {
  color: rgba(255, 255, 255, 0.58);
}

.analytics-stats strong {
  font-family: var(--font-serif);
  font-size: 27px;
  line-height: 1;
}

.analytics-stats small {
  padding-bottom: 2px;
  color: #94a09c;
  font-size: 8px;
}

.analytics-matrix-card,
.machine-detail,
.template-report-card {
  background: var(--white);
  border: 1px solid #e1e6e0;
  border-radius: 17px;
  box-shadow: 0 10px 30px rgba(28, 55, 50, 0.045);
}

.template-report-card {
  margin-top: 13px;
  padding: 18px 21px;
}

.template-report-stats {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 8px;
  margin-top: 13px;
}

.template-report-stats article {
  display: grid;
  gap: 2px;
  padding: 11px;
  background: #f7faf7;
  border-radius: 9px;
}

.template-report-stats span,
.template-report-stats small {
  color: #80908b;
  font-size: 8px;
}

.template-report-stats strong {
  font-family: var(--font-serif);
  font-size: 21px;
}

.template-report-trend {
  display: grid;
  gap: 6px;
  margin-top: 13px;
}

.template-trend-row {
  display: grid;
  grid-template-columns: 38px minmax(0, 1fr) minmax(0, 1fr);
  gap: 5px;
  align-items: center;
}

.template-trend-row span {
  color: #82908c;
  font-size: 8px;
}

.template-trend-row i,
.template-trend-row b {
  display: block;
  min-width: 2px;
  height: 7px;
  background: var(--green);
  border-radius: 5px;
}

.template-trend-row b {
  background: var(--orange);
}

.trend-card {
  padding: 19px 21px 15px;
  margin-bottom: 13px;
  background: var(--white);
  border: 1px solid #e1e6e0;
  border-radius: 17px;
  box-shadow: 0 10px 30px rgba(28, 55, 50, 0.045);
}

.trend-card-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 15px;
}

.trend-card-head h3 {
  margin: 0;
  font-family: var(--font-serif);
  font-size: 19px;
}

.trend-card-head p {
  margin: 4px 0 0;
  color: #879590;
  font-size: 10px;
}

.trend-chart-wrap {
  position: relative;
  height: 260px;
  margin-top: 14px;
}

#liveTrendChart {
  display: block;
  width: 100%;
  height: 100%;
}

.trend-legend {
  display: flex;
  flex-wrap: wrap;
  gap: 7px 13px;
  padding-top: 10px;
  border-top: 1px solid #edf0ec;
}

.trend-legend span {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  color: #6f817c;
  font-size: 10px;
}

.trend-legend i {
  width: 9px;
  height: 3px;
  border-radius: 3px;
}

.analytics-matrix-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 15px;
  padding: 19px 21px 14px;
  border-bottom: 1px solid #edf0ec;
}

.analytics-matrix-head > div {
  display: flex;
  align-items: baseline;
  gap: 10px;
}

.analytics-matrix-head h3 {
  margin: 0;
  font-family: var(--font-serif);
  font-size: 19px;
}

.analytics-matrix-head span,
.analytics-matrix-head small {
  color: #8b9894;
  font-size: 8px;
}

.analytics-table-wrap {
  min-height: 180px;
  overflow-x: auto;
}

.analytics-table {
  width: 100%;
  min-width: 700px;
  border-collapse: collapse;
}

.analytics-table th {
  padding: 11px 10px;
  color: #7d8d88;
  font-size: 8px;
  font-weight: 700;
  text-align: center;
  background: #fafcf9;
  border-bottom: 1px solid #e9ede8;
}

.analytics-table th:first-child {
  position: sticky;
  left: 0;
  z-index: 2;
  min-width: 110px;
  text-align: left;
  background: #fafcf9;
}

.analytics-table td {
  padding: 10px;
  text-align: center;
  border-bottom: 1px solid #eef1ed;
}

.analytics-table td:first-child {
  position: sticky;
  left: 0;
  z-index: 1;
  text-align: left;
  background: var(--white);
}

.machine-link {
  padding: 6px 8px;
  color: var(--green);
  font-size: 10px;
  font-weight: 700;
  cursor: pointer;
  background: var(--green-soft);
  border: 0;
  border-radius: 7px;
}

.machine-link:hover {
  color: var(--white);
  background: var(--green);
}

.analytics-cell {
  display: inline-grid;
  gap: 1px;
  min-width: 55px;
  padding: 5px 7px;
  border-radius: 7px;
}

.analytics-cell.has-data {
  background: #edf5ef;
}

.analytics-cell strong {
  color: #36564e;
  font-size: 9px;
}

.analytics-cell small {
  color: #83938e;
  font-size: 7px;
}

.analytics-cell.empty {
  color: #b0bab6;
  font-size: 8px;
}

.machine-detail {
  margin-top: 14px;
  padding: 21px;
  animation: fadeUp 260ms ease both;
}

.machine-detail-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 15px;
}

.machine-detail-head h3 {
  margin: 0;
  font-family: var(--font-serif);
  font-size: 23px;
}

.machine-detail-head span {
  color: #8c9995;
  font-size: 8px;
}

.machine-detail-actions {
  display: flex;
  align-items: center;
  gap: 7px;
}

.machine-detail-actions .secondary-button.locked {
  color: var(--white);
  background: var(--orange);
  border-color: var(--orange);
}

.machine-quick-switch {
  display: flex;
  gap: 6px;
  padding: 9px 0 2px;
  margin: 8px 0 10px;
  overflow-x: auto;
  scrollbar-width: thin;
  scroll-snap-type: x proximity;
  border-top: 1px solid #edf0ec;
  border-bottom: 1px solid #edf0ec;
}

.machine-quick-switch button {
  flex: 0 0 auto;
  min-width: 42px;
  height: 32px;
  padding: 0 9px;
  color: #5b706a;
  font-size: 9px;
  cursor: pointer;
  scroll-snap-align: start;
  background: #f5f8f4;
  border: 1px solid #dfe6df;
  border-radius: 8px;
}

.machine-quick-switch button.active {
  color: var(--white);
  font-weight: 700;
  background: var(--green);
  border-color: var(--green);
}

.machine-detail-stats {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
  margin: 17px 0;
}

.machine-detail-stats > div {
  display: grid;
  gap: 4px;
  padding: 12px;
  background: #f7faf6;
  border-radius: 9px;
}

.machine-detail-stats span {
  color: #8e9b97;
  font-size: 8px;
}

.machine-detail-stats strong {
  color: #314b45;
  font-family: var(--font-serif);
  font-size: 17px;
}

.machine-detail-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 11px;
}

.machine-breakdown-card,
.machine-recent-card {
  padding: 15px;
  background: #fbfcfa;
  border: 1px solid #e8ece7;
  border-radius: 11px;
}

.machine-breakdown-card h4,
.machine-recent-card h4 {
  margin: 0 0 12px;
  color: #46615a;
  font-size: 10px;
}

.method-bar-row {
  display: grid;
  grid-template-columns: 90px minmax(0, 1fr) auto;
  align-items: center;
  gap: 8px;
  margin-bottom: 9px;
}

.method-bar-row > span {
  overflow: hidden;
  color: #5d716b;
  font-size: 8px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.reason-analysis-list,
#machineReasonAnalysis,
#liveReasonAnalysis {
  display: grid;
  gap: 6px;
}

.reason-analysis-row {
  overflow: hidden;
  border: 1px solid #e5eae4;
  border-radius: 9px;
}

.reason-analysis-row > button {
  display: flex;
  align-items: center;
  justify-content: flex-start;
  gap: 10px;
  width: 100%;
  padding: 10px;
  text-align: left;
  cursor: pointer;
  background: #f8faf7;
  border: 0;
}

.reason-color-dot {
  flex: 0 0 8px;
  width: 8px;
  height: 8px;
  border-radius: 50%;
}

.reason-analysis-row > button strong {
  color: #46615a;
  font-size: 10px;
}

.reason-analysis-row > button small {
  margin-left: auto;
  color: #7c8d88;
  font-size: 8px;
  white-space: nowrap;
}

.machine-reason-chart {
  height: 175px;
}

.machine-reason-chart canvas {
  display: block;
  width: 100%;
  height: 100%;
}

.machine-reason-chart-legend {
  display: flex;
  flex-wrap: wrap;
  gap: 7px 12px;
  padding-top: 8px;
  border-top: 1px solid #edf0ec;
}

.machine-reason-chart-legend span {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  color: #6f817c;
  font-size: 8px;
}

.machine-reason-chart-legend i {
  width: 10px;
  height: 3px;
  border-radius: 3px;
}

.reason-analysis-row.active {
  border-color: #b8cec5;
}

.reason-analysis-row.active > button {
  color: var(--white);
  background: var(--green);
}

.reason-analysis-row.active > button strong,
.reason-analysis-row.active > button small {
  color: var(--white);
}

.reason-sub-list {
  display: grid;
  gap: 1px;
  padding: 7px 8px 8px 22px;
  background: #f4f8f4;
}

.reason-sub-list > div {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  padding: 6px 4px;
  border-bottom: 1px solid #e5ebe5;
}

.reason-sub-list > div:last-child {
  border-bottom: 0;
}

.reason-sub-list span {
  color: #61746e;
  font-size: 9px;
}

.reason-sub-list small {
  color: #879590;
  font-size: 8px;
  white-space: nowrap;
}

.method-bar {
  height: 7px;
  overflow: hidden;
  background: #e7ede8;
  border-radius: 5px;
}

.method-bar i {
  display: block;
  height: 100%;
  background: linear-gradient(90deg, #4f8878, #89ad80);
  border-radius: inherit;
}

.method-bar-row > small {
  color: #71847e;
  font-size: 7px;
  white-space: nowrap;
}

.daily-bars {
  display: flex;
  align-items: flex-end;
  gap: 5px;
  min-height: 112px;
  padding-top: 8px;
}

.daily-bar {
  display: flex;
  flex: 1;
  flex-direction: column;
  align-items: center;
  justify-content: flex-end;
  min-width: 14px;
  height: 100px;
  gap: 4px;
}

.daily-bar i {
  width: 100%;
  min-height: 2px;
  background: #d5e4d0;
  border-radius: 4px 4px 0 0;
}

.daily-bar span {
  color: #8f9b97;
  font-size: 6px;
  white-space: nowrap;
  transform: rotate(-35deg);
}

.machine-recent-card {
  margin-top: 11px;
}

.machine-bottom-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: 11px;
  margin-top: 11px;
}

.machine-bottom-grid .machine-recent-card {
  min-width: 0;
  margin-top: 0;
}

#machineDetailSection,
#liveMachineDetail {
  margin-top: 12px;
  margin-bottom: 14px;
}

.recent-mini-row {
  display: grid;
  grid-template-columns: 85px 1fr auto;
  align-items: center;
  gap: 9px;
  padding: 9px 0;
  border-bottom: 1px solid #edf0ec;
}

.recent-mini-row:last-child {
  border-bottom: 0;
}

.recent-mini-row time {
  color: #748680;
  font-size: 8px;
}

.recent-4m-row {
  grid-template-columns: 82px 68px 100px minmax(0, 1fr) auto;
}

.recent-4m-machine,
.recent-4m-category {
  overflow: hidden;
  font-size: 8px;
  font-weight: 700;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.recent-4m-machine {
  color: var(--green);
}

.recent-4m-category {
  color: #a25f38;
}

.recent-mini-row strong {
  overflow: hidden;
  color: #3d554f;
  font-size: 8px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.recent-mini-row span {
  color: #8d9995;
  font-size: 7px;
}

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

@keyframes blob {
  0% { border-radius: 44% 56% 64% 36% / 42% 42% 58% 58%; transform: translate(-50%, -50%) rotate(-2deg); }
  100% { border-radius: 56% 44% 38% 62% / 55% 46% 54% 45%; transform: translate(-50%, -50%) rotate(3deg); }
}

@keyframes float {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-7px); }
}

@keyframes fadeUp {
  from { opacity: 0; transform: translateY(8px); }
  to { opacity: 1; transform: translateY(0); }
}

@media (max-width: 1050px) {
  .hero {
    grid-template-columns: minmax(0, 1fr) minmax(340px, 0.8fr);
    gap: 25px;
  }

  .orbit-ring-two {
    width: 390px;
    height: 390px;
  }

  .submission-layout {
    grid-template-columns: minmax(0, 1.2fr) minmax(270px, 0.6fr);
  }

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

  .filters {
    flex-wrap: wrap;
  }

  .search-field {
    max-width: none;
    flex-basis: 100%;
  }

  .table-head,
  .submission-row {
    grid-template-columns: minmax(230px, 1fr) 130px minmax(160px, 0.7fr) 60px;
    gap: 14px;
  }
}

@media (max-width: 820px) {
  .site-header,
  .public-shell,
  .site-footer {
    width: min(100% - 36px, 680px);
  }

  .site-header {
    height: 82px;
  }

  .hero {
    grid-template-columns: 1fr;
    padding-top: 34px;
  }

  .hero-copy {
    position: relative;
    z-index: 2;
  }

  .hero-orbit {
    width: min(100%, 470px);
    min-height: 330px;
    margin: -5px auto 0;
  }

  .hero-orbit::before {
    width: 245px;
    height: 245px;
  }

  .orbit-ring-one {
    width: 295px;
    height: 295px;
  }

  .orbit-ring-two {
    width: 350px;
    height: 350px;
  }

  .orbit-card-time {
    top: 4%;
    right: 4%;
  }

  .orbit-card-image {
    bottom: 1%;
    left: 2%;
  }

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

  .side-panel {
    grid-template-columns: 1fr 0.55fr;
  }

  .side-card,
  .time-card {
    min-height: 100%;
  }

  .time-card {
    flex-direction: column;
    align-items: start;
    justify-content: center;
  }

  .auth-card {
    grid-template-columns: 1fr;
    max-width: 560px;
  }

  .auth-art {
    min-height: 250px;
    padding: 35px;
  }

  .auth-art h1 {
    font-size: 36px;
  }

  .auth-art-content > p:last-child {
    display: none;
  }

  .auth-chart {
    position: absolute;
    right: 30px;
    bottom: 0;
    width: 180px;
    height: 90px;
    opacity: 0.5;
  }

  .auth-form-wrap {
    padding: 40px;
  }

  .dashboard {
    width: min(100% - 32px, 720px);
    padding-top: 34px;
  }

  .table-head {
    display: none;
  }

  .submission-row {
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 10px 15px;
    padding: 17px 20px;
  }

  .record-main {
    grid-column: 1;
  }

  .record-time {
    grid-column: 2;
    grid-row: 1;
    text-align: right;
  }

  .record-gallery {
    grid-column: 1 / -1;
    grid-row: 2;
    padding-left: 51px;
  }

  .record-number {
    position: absolute;
    pointer-events: none;
    opacity: 0;
  }
}

@media (max-width: 560px) {
  .hero-orbit {
    display: none;
  }

  .hero {
    min-height: 0;
    padding-bottom: 28px;
  }

  .hero-description {
    line-height: 1.75;
  }

  .site-header,
  .public-shell,
  .site-footer {
    width: calc(100% - 28px);
  }

  .brand strong {
    font-size: 15px;
  }

  .brand small {
    font-size: 7px;
  }

  .brand-mark {
    width: 38px;
    height: 38px;
  }

  .quiet-link {
    padding: 8px;
    font-size: 0;
  }

  .quiet-link svg {
    width: 20px;
  }

  .hero {
    padding: 20px 0 38px;
  }

  .hero h1 {
    font-size: 41px;
  }

  .hero-description {
    font-size: 13px;
  }

  .trust-row {
    gap: 10px 14px;
  }

  .trust-row span {
    font-size: 10px;
  }

  .hero-orbit {
    min-height: 290px;
    transform: scale(0.9);
  }

  .hero-orbit::before {
    width: 220px;
    height: 220px;
  }

  .orbit-ring-one {
    width: 270px;
    height: 270px;
  }

  .orbit-ring-two {
    width: 320px;
    height: 320px;
  }

  .orbit-card-main {
    width: 225px;
  }

  .orbit-card-time {
    top: 0;
    right: -1%;
  }

  .orbit-card-image {
    bottom: 0;
    left: 0;
  }

  .submission-layout {
    gap: 15px;
    padding-bottom: 55px;
  }

  .form-card {
    min-height: 0;
    padding: 24px 18px;
    border-radius: 20px;
  }

  .card-heading {
    margin-bottom: 27px;
  }

  .card-heading h2 {
    font-size: 24px;
  }

  .required-hint {
    display: none;
  }

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

  .form-fields-grid {
    grid-template-columns: 1fr;
  }

  .field-span-two {
    grid-column: 1;
  }

  .form-input,
  .form-select,
  .calculated-field,
  .time-input-group {
    min-height: 54px;
  }

  .date-time-control {
    grid-template-columns: 1fr;
    gap: 6px;
  }

  .time-input-group {
    padding: 0 12px;
  }

  .time-input-group input,
  .time-input-group select,
  .form-input,
  .form-select,
  .calculated-field input,
  .public-page textarea,
  .public-page .input-shell input {
    font-size: 16px;
  }

  .time-input-group span {
    font-size: 10px;
  }

  .form-footer {
    position: sticky;
    z-index: 5;
    bottom: 8px;
    padding: 10px;
    background: rgba(255, 255, 255, 0.92);
    border: 1px solid rgba(220, 226, 219, 0.9);
    border-radius: 13px;
    box-shadow: 0 10px 30px rgba(23, 77, 71, 0.12);
  }

  .primary-button {
    min-height: 51px;
    font-size: 13px;
  }

  .form-footer {
    flex-direction: column;
    align-items: stretch;
  }

  .privacy-note {
    justify-content: center;
  }

  .primary-button {
    width: 100%;
  }

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

  .time-card {
    min-height: 108px;
    flex-direction: row;
    align-items: center;
  }

  .success-details {
    grid-template-columns: 1fr;
  }

  .success-details div:not(:last-child) {
    border-right: 0;
    border-bottom: 1px solid var(--line);
  }

  .site-footer {
    padding-bottom: 24px;
  }

  .admin-header {
    height: 66px;
    padding: 0 14px;
  }

  .brand-light strong {
    font-size: 14px;
  }

  .admin-nav {
    gap: 5px;
  }

  .nav-submit,
  .nav-logout {
    width: 34px;
    min-width: 34px;
    padding: 0;
    justify-content: center;
    font-size: 0;
  }

  .auth-view {
    padding: 24px 13px;
  }

  .auth-card {
    border-radius: 20px;
  }

  .auth-art {
    min-height: 215px;
    padding: 28px;
  }

  .auth-art h1 {
    font-size: 31px;
  }

  .auth-chart {
    right: 20px;
    width: 130px;
  }

  .auth-form-wrap {
    padding: 32px 25px;
  }

  .dashboard {
    width: calc(100% - 22px);
    padding: 28px 0 44px;
  }

  .dashboard-heading {
    align-items: start;
  }

  .dashboard-heading h1 {
    font-size: 32px;
  }

  .live-badge {
    margin-top: 24px;
    padding: 7px 9px;
    font-size: 0;
  }

  .live-badge i {
    margin: 2px;
  }

  .stats-grid {
    gap: 9px;
  }

  .stat-card {
    grid-template-columns: 36px 1fr;
    gap: 9px;
    min-height: 92px;
    padding: 14px;
  }

  .stat-card small {
    display: none;
  }

  .stat-icon {
    width: 36px;
    height: 36px;
    border-radius: 10px;
  }

  .stat-icon svg {
    width: 19px;
  }

  .stat-card strong {
    font-size: 21px;
  }

  .records-toolbar {
    align-items: start;
    padding: 18px 15px 14px;
  }

  .records-title {
    display: grid;
    gap: 4px;
  }

  .records-title h2 {
    font-size: 19px;
  }

  .export-button {
    width: 36px;
    min-width: 36px;
    padding: 0;
    font-size: 0;
  }

  .backup-card {
    grid-template-columns: 38px minmax(0, 1fr);
    gap: 11px;
    padding: 14px;
  }

  .backup-icon {
    width: 36px;
    height: 36px;
  }

  .backup-copy code {
    white-space: normal;
    overflow-wrap: anywhere;
  }

  .backup-card .backup-run-button {
    grid-column: 1 / -1;
    width: 100%;
    min-width: 0;
    padding-inline: 12px;
    font-size: 11px;
  }

  .filters {
    gap: 6px;
    padding: 0 15px 15px;
  }

  .date-field {
    flex: 1;
    min-width: 0;
    padding: 0 6px;
  }

  .date-field input {
    min-width: 0;
    width: 100%;
    font-size: 8px;
  }

  .filter-button {
    padding: 0 12px;
  }

  .submission-row {
    padding: 16px 14px;
  }

  .account-avatar {
    flex-basis: 35px;
    width: 35px;
    height: 35px;
  }

  .record-copy p {
    max-width: 195px;
  }

  .record-gallery {
    padding-left: 47px;
    overflow-x: auto;
  }

  .thumbnail-button {
    flex-basis: 35px;
    height: 35px;
  }

  .image-count {
    display: none;
  }

  .image-dialog {
    width: calc(100vw - 20px);
  }

  .dialog-head strong {
    max-width: 250px;
  }

  .toast {
    right: 14px;
    bottom: 14px;
    left: 14px;
    text-align: center;
  }
}

@media (max-width: 820px) {
  .option-layout {
    grid-template-columns: 1fr;
  }

  .option-field-list {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .option-field-button {
    padding: 10px 5px;
    text-align: center;
  }

  .user-table-head {
    display: none;
  }

  .user-row {
    grid-template-columns: minmax(0, 1fr) auto auto;
    gap: 9px 15px;
  }

  .user-row-identity {
    grid-column: 1;
  }

  .user-row-login {
    grid-column: 1;
    grid-row: 2;
    padding-left: 44px;
  }

  .user-row-role {
    grid-column: 1;
    grid-row: 3;
    margin-left: 44px;
  }

  .user-row-shift {
    grid-column: 2;
    grid-row: 3;
    justify-self: end;
  }

  .user-row-meta {
    grid-column: 2;
    grid-row: 1;
    text-align: right;
  }

  .user-row > .status-pill {
    grid-column: 3;
    grid-row: 1;
    justify-self: end;
  }

  .user-row-actions {
    grid-column: 1 / -1;
    grid-row: 4;
    justify-content: flex-start;
    padding-left: 44px;
  }
}

@media (max-width: 560px) {
  .header-actions {
    gap: 5px;
  }

  .user-chip {
    padding: 4px;
    border: 0;
    background: transparent;
  }

  .user-chip > div {
    display: none;
  }

  .user-chip button {
    display: block;
    padding: 5px 6px;
    font-size: 8px;
  }

  .member-login-view {
    min-height: 0;
  }

  .admin-tabs {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
  }

  .admin-tab {
    justify-content: center;
  }

  .user-overview {
    align-items: flex-start;
    padding: 21px 17px;
  }

  .user-overview h2 {
    font-size: 20px;
  }

  .user-overview-actions {
    flex-direction: column;
    align-items: flex-end;
    gap: 9px;
  }

  .user-overview-actions .primary-button {
    width: auto;
    min-height: 37px;
    padding: 0 11px;
  }

  .user-dialog-body {
    padding: 20px 18px 8px;
  }

  .user-dialog-footer {
    padding: 14px 18px 20px;
  }

  .user-row {
    padding: 14px 15px;
  }

  .user-row-actions {
    padding-left: 0;
  }

  .option-field-list {
    grid-template-columns: 1fr;
  }

  .option-overview {
    gap: 9px;
  }

  .options-hint {
    display: none;
  }

  .option-editor-card {
    padding: 16px 13px;
  }

  .option-editor-head {
    display: grid;
  }

  .option-add-form {
    width: 100%;
  }

  .option-add-form input {
    flex: 1;
    width: auto;
    min-width: 0;
  }

  .option-row {
    grid-template-columns: 22px 28px 34px minmax(0, 1fr);
  }

  .option-status {
    display: none;
  }

  .option-row-actions {
    grid-column: 1 / -1;
    justify-content: flex-start;
    padding-left: 28px;
  }

  .credential-dialog {
    padding: 24px 18px;
  }

  .record-dialog-body {
    padding: 16px;
  }

  .record-detail-grid {
    grid-template-columns: 1fr 1fr;
  }

  .record-detail-item.wide {
    grid-column: span 2;
  }

  .record-detail-images {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

@media (max-width: 820px) {
  .today-list {
    grid-template-columns: 1fr;
  }

  .requirements-list {
    grid-template-columns: 1fr;
  }

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

  .analytics-heading {
    align-items: flex-start;
  }
}

@media (max-width: 560px) {
  .today-section {
    padding-bottom: 55px;
  }

  .today-heading {
    align-items: flex-start;
    padding: 20px 17px;
  }

  .today-heading h2 {
    font-size: 21px;
  }

  .today-record-card {
    padding: 0;
  }

  .today-record-summary {
    padding: 14px;
  }

  .today-record-body {
    padding: 0 14px 14px;
  }

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

  .today-summary-meta > span:last-child {
    grid-column: 1 / -1;
  }

  .today-image-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .admin-tabs {
    grid-template-columns: repeat(2, 1fr);
  }

  .record-editor-grid {
    grid-template-columns: 1fr;
  }

  .record-editor-body {
    padding: 18px 14px 4px;
  }

  .record-editor-dialog .field input[type="text"],
  .record-editor-dialog .form-input,
  .record-editor-dialog .form-select {
    font-size: 16px;
  }

  .custom-field-builder {
    grid-template-columns: 1fr 1fr;
  }

  .custom-field-builder > div:first-child {
    grid-column: 1 / -1;
  }

  .custom-field-builder .primary-button {
    width: 100%;
  }

  .analytics-heading {
    display: grid;
    padding: 20px 17px;
  }

  .trend-card {
    padding: 17px 13px 13px;
  }

  .trend-card-head {
    align-items: flex-start;
  }

  .trend-chart-wrap {
    height: 220px;
  }

  .analytics-actions {
    justify-content: space-between;
  }

  .range-tabs {
    flex: 1;
  }

  .range-tabs button {
    flex: 1;
  }

  .analytics-matrix-head {
    align-items: flex-start;
  }

  .machine-detail {
    padding: 16px;
  }

  .machine-detail-grid {
    grid-template-columns: 1fr;
  }

  .machine-bottom-grid {
    grid-template-columns: 1fr;
  }

  .machine-detail-stats {
    gap: 6px;
  }
}

@media (max-width: 620px) {
  .recent-4m-row {
    grid-template-columns: 68px minmax(0, 1fr);
  }

  .recent-4m-row time {
    grid-row: 1 / span 4;
  }

  .recent-4m-row > strong,
  .recent-4m-row > .recent-4m-machine,
  .recent-4m-row > .recent-4m-category,
  .recent-4m-row > span:last-child {
    grid-column: 2;
  }

  .product-map-card-head {
    align-items: stretch;
    flex-direction: column;
    gap: 11px;
  }

  .product-map-toggle {
    align-items: flex-start;
  }

  .product-map-toggle-action {
    margin-top: 2px;
  }

  .product-map-admin-card .primary-button {
    width: 100%;
  }

  .product-map-search {
    align-items: stretch;
    flex-direction: column;
  }

  .product-map-search input {
    width: 100%;
  }

  .product-map-preview {
    grid-template-columns: 1fr;
  }

  .record-template-picker {
    grid-template-columns: 1fr;
  }

  .record-template-picker button {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    min-height: 47px;
    gap: 12px;
  }
}

@media (max-width: 820px) {
  input:not([type="checkbox"]):not([type="radio"]):not([type="hidden"]),
  select,
  textarea,
  .form-input,
  .form-select,
  .multi-select-toggle,
  .searchable-select-toggle,
  .searchable-select-search,
  .product-tree-search,
  .select-search-input {
    font-size: 16px !important;
    line-height: 1.35;
  }

  button,
  a,
  input,
  select,
  textarea {
    touch-action: manipulation;
  }
}

body.dashboard-page,
body.dashboard-page .dashboard,
body.dashboard-page button,
body.dashboard-page input,
body.dashboard-page select,
body.dashboard-page textarea {
  font-family: "Microsoft YaHei", "PingFang SC", sans-serif !important;
  font-weight: 700;
}

body.dashboard-page h1,
body.dashboard-page h2,
body.dashboard-page h3,
body.dashboard-page h4,
body.dashboard-page strong {
  font-family: "Microsoft YaHei", "PingFang SC", sans-serif !important;
  font-weight: 700 !important;
}

body.dashboard-page .dashboard-heading,
body.dashboard-page .dashboard-heading *,
body.dashboard-page .analytics-heading,
body.dashboard-page .analytics-heading *,
body.dashboard-page .analytics-stats article:not(:first-child),
body.dashboard-page .analytics-stats article:not(:first-child) *,
body.dashboard-page .trend-card,
body.dashboard-page .trend-card *,
body.dashboard-page .analytics-matrix-card,
body.dashboard-page .analytics-matrix-card *,
body.dashboard-page .machine-detail,
body.dashboard-page .machine-detail *,
body.dashboard-page .template-report-card,
body.dashboard-page .template-report-card * {
  color: #111111 !important;
}

body.dashboard-page .analytics-stats article:first-child,
body.dashboard-page .analytics-stats article:first-child *,
body.dashboard-page .range-tabs button.active,
body.dashboard-page .machine-quick-switch button.active,
body.dashboard-page .reason-analysis-row.active > button,
body.dashboard-page .reason-analysis-row.active > button *,
body.dashboard-page .machine-detail-actions .secondary-button.locked {
  color: #ffffff !important;
}

@media (min-width: 1500px) {
  body.dashboard-page .dashboard,
  body.dashboard-page .dashboard-only {
    width: calc(100% - 48px);
    max-width: none;
    padding-top: 24px;
    padding-bottom: 42px;
  }

  body.dashboard-page .dashboard-heading {
    margin-bottom: 18px;
  }

  body.dashboard-page .dashboard-heading h1 {
    font-size: 46px;
    letter-spacing: -0.015em;
  }

  body.dashboard-page .dashboard-heading > div > p:last-child,
  body.dashboard-page .eyebrow.dark,
  body.dashboard-page .live-badge {
    font-size: 14px;
  }

  body.dashboard-page .analytics-heading {
    margin-bottom: 12px;
    padding: 20px 24px;
  }

  body.dashboard-page .analytics-heading h2 {
    font-size: 30px;
  }

  body.dashboard-page .analytics-heading > div:first-child > p:last-child {
    font-size: 13px;
  }

  body.dashboard-page .analytics-stats {
    gap: 13px;
    margin-bottom: 14px;
  }

  body.dashboard-page .analytics-stats article {
    min-height: 106px;
    padding: 16px 20px;
  }

  body.dashboard-page .analytics-stats span {
    font-size: 12px;
  }

  body.dashboard-page .analytics-stats strong {
    font-size: 36px;
  }

  body.dashboard-page .analytics-stats small {
    font-size: 11px;
  }

  body.dashboard-page .range-tabs button {
    min-height: 36px;
    font-size: 12px;
  }

  body.dashboard-page .trend-card {
    padding: 20px 22px 15px;
  }

  body.dashboard-page .trend-card-head h3,
  body.dashboard-page .analytics-matrix-head h3 {
    font-size: 24px;
  }

  body.dashboard-page .trend-card-head p,
  body.dashboard-page .trend-legend span,
  body.dashboard-page .analytics-matrix-head span,
  body.dashboard-page .analytics-matrix-head small {
    font-size: 12px;
  }

  body.dashboard-page .trend-chart-wrap {
    height: 285px;
  }

  body.dashboard-page .machine-detail {
    padding: 20px 22px;
  }

  body.dashboard-page .machine-detail-head h3 {
    font-size: 31px;
  }

  body.dashboard-page .machine-detail-head span,
  body.dashboard-page .machine-detail-stats span {
    font-size: 12px;
  }

  body.dashboard-page .machine-detail-stats strong {
    font-size: 25px;
  }

  body.dashboard-page .machine-breakdown-card h4,
  body.dashboard-page .machine-recent-card h4 {
    font-size: 16px;
  }

  body.dashboard-page .reason-analysis-row > button strong,
  body.dashboard-page .reason-sub-list span,
  body.dashboard-page .recent-mini-row strong {
    font-size: 12px;
  }

  body.dashboard-page .reason-analysis-row > button small,
  body.dashboard-page .reason-sub-list small,
  body.dashboard-page .recent-mini-row time,
  body.dashboard-page .recent-4m-category,
  body.dashboard-page .recent-4m-machine {
    font-size: 10px;
  }

  body.dashboard-page .machine-quick-switch button {
    min-width: 48px;
    height: 36px;
    font-size: 12px;
  }

  body.dashboard-page .analytics-table th,
  body.dashboard-page .analytics-table td {
    font-size: 10px;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    scroll-behavior: auto !important;
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}

.recycle-dialog {
  width: min(860px, calc(100vw - 32px));
}

.recycle-dialog-body {
  max-height: min(72vh, 720px);
  overflow-y: auto;
}

.recycle-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 14px;
  color: #65746f;
  font-size: 13px;
}

.recycle-list {
  display: grid;
  gap: 10px;
}

.recycle-empty {
  padding: 36px 20px;
  border: 1px dashed #cbd7d2;
  border-radius: 14px;
  color: #71817c;
  text-align: center;
}

.recycle-item {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 14px;
  align-items: center;
  padding: 14px 16px;
  border: 1px solid #e0e9e5;
  border-radius: 14px;
  background: #fff;
}

.recycle-item-copy {
  min-width: 0;
}

.recycle-item-head {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
}

.recycle-item-head strong {
  color: #172b25;
  font-size: 15px;
}

.recycle-item-head span {
  padding: 3px 8px;
  border-radius: 999px;
  background: #edf5f1;
  color: #39785e;
  font-size: 11px;
}

.recycle-item p {
  overflow: hidden;
  margin: 7px 0 0;
  color: #566762;
  font-size: 12px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.recycle-item small {
  display: block;
  margin-top: 7px;
  color: #83918d;
  font-size: 11px;
}

.recycle-item-actions {
  display: flex;
  gap: 8px;
}

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

  .recycle-item-actions {
    justify-content: flex-end;
  }
}

/* 检验、调试、班长任务中心 */
.notification-bell {
  position: relative;
  display: grid;
  width: 42px;
  height: 42px;
  padding: 0;
  place-items: center;
  border: 1px solid rgba(255, 255, 255, 0.26);
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.12);
  color: #fff;
  cursor: pointer;
}

.notification-bell svg {
  width: 21px;
  fill: none;
  stroke: currentColor;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 1.8;
}

.notification-bell span {
  position: absolute;
  top: -4px;
  right: -4px;
  min-width: 20px;
  height: 20px;
  padding: 0 5px;
  border: 2px solid #174d47;
  border-radius: 999px;
  background: #f0b44d;
  color: #222;
  font-size: 11px;
  font-weight: 800;
  line-height: 16px;
}

.notification-panel {
  position: fixed;
  z-index: 90;
  top: 74px;
  right: max(18px, calc((100vw - 1180px) / 2));
  width: min(380px, calc(100vw - 28px));
  max-height: min(70vh, 620px);
  overflow: auto;
  padding: 16px;
  border: 1px solid #dbe7e2;
  border-radius: 18px;
  background: #fff;
  box-shadow: 0 18px 55px rgba(20, 47, 44, 0.22);
}

.notification-panel[hidden],
.workflow-panel[hidden] {
  display: none !important;
}

.notification-panel-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 12px;
}

.notification-panel-head div {
  display: grid;
  gap: 4px;
}

.notification-panel-head small,
.notification-item small {
  color: #72827d;
  font-size: 12px;
}

.notification-list {
  display: grid;
  gap: 8px;
  margin-bottom: 10px;
}

.notification-item {
  display: grid;
  width: 100%;
  gap: 4px;
  padding: 12px;
  border: 1px solid #e2ebe7;
  border-radius: 12px;
  background: #f8fbf9;
  color: #1d312e;
  text-align: left;
  cursor: pointer;
}

.notification-item.unread {
  border-color: #e8c477;
  background: #fff9e9;
}

.notification-item span {
  font-size: 13px;
  line-height: 1.45;
}

.notification-empty,
.workflow-empty {
  margin: 0;
  padding: 24px 12px;
  color: #788781;
  text-align: center;
}

.task-center-entry {
  display: grid;
  grid-template-columns: 28px minmax(0, 1fr) auto auto;
  align-items: center;
  width: 100%;
  gap: 10px;
  margin: 0 0 16px;
  padding: 15px 17px;
  border: 1px solid #b8d8cc;
  border-radius: 16px;
  background: #eff8f4;
  color: #174d47;
  text-align: left;
  box-shadow: 0 7px 20px rgba(23, 77, 71, 0.08);
  cursor: pointer;
}

.task-center-entry:hover {
  border-color: #74a999;
  background: #e7f4ee;
}

.task-center-entry svg {
  width: 25px;
  fill: none;
  stroke: currentColor;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 1.8;
}

.task-center-entry > span {
  font-size: 16px;
  font-weight: 800;
}

.task-center-entry b {
  min-width: 26px;
  height: 26px;
  padding: 0 7px;
  border-radius: 999px;
  background: #174d47;
  color: #fff;
  font-size: 13px;
  line-height: 26px;
  text-align: center;
}

.task-center-entry em {
  color: #557a6f;
  font-size: 13px;
  font-style: normal;
}

.workflow-panel {
  margin-bottom: 18px;
  padding: 18px;
  border: 1px solid #cfe2da;
  border-radius: 18px;
  background: #f7fbf9;
}

.workflow-role-head,
.workflow-task-head,
.workflow-task-card-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
}

.workflow-role-head h3,
.workflow-task-head h3 {
  margin: 3px 0 0;
  color: #173b36;
  font-size: 21px;
}

.workflow-shift {
  flex: 0 0 auto;
  padding: 7px 11px;
  border-radius: 999px;
  background: #e1f0e9;
  color: #276654;
  font-size: 13px;
  font-weight: 700;
}

.workflow-form-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 15px;
  margin-top: 18px;
}

.workflow-content-block {
  padding: 14px;
  border: 1px solid #e8cf9d;
  border-radius: 14px;
  background: #fffbf2;
}

.task-center-dialog,
.task-detail-dialog {
  width: min(960px, calc(100vw - 28px));
  max-height: min(90vh, 960px);
  padding: 0;
  overflow: hidden;
  border: 0;
  border-radius: 20px;
  background: #fff;
  box-shadow: 0 30px 90px rgba(13, 44, 40, 0.35);
}

.task-center-dialog::backdrop,
.task-detail-dialog::backdrop {
  background: rgba(8, 31, 28, 0.58);
}

.task-detail-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 14px;
  padding: 18px 20px;
  border-bottom: 1px solid #e5eeea;
  background: #f6faf8;
}

.task-detail-head div {
  display: grid;
  gap: 4px;
}

.task-detail-head strong {
  color: #173b36;
  font-size: 18px;
}

.task-detail-head small {
  color: #6d7e78;
  font-size: 13px;
}

.task-detail-head button {
  display: grid;
  width: 38px;
  height: 38px;
  flex: 0 0 auto;
  padding: 0;
  place-items: center;
  border: 1px solid #d6e3de;
  border-radius: 50%;
  background: #fff;
  cursor: pointer;
}

.task-detail-head svg {
  width: 20px;
  fill: none;
  stroke: #31534c;
  stroke-linecap: round;
  stroke-width: 2;
}

.task-center-dialog-body,
.task-detail-body {
  max-height: calc(90vh - 76px);
  overflow: auto;
  padding: 18px;
  overscroll-behavior: contain;
}

html.task-detail-open,
body.task-detail-open {
  overflow: hidden;
}

.workflow-task-panel {
  min-height: 180px;
}

.workflow-task-head p {
  margin: 5px 0 0;
  color: #6f807a;
  font-size: 13px;
  line-height: 1.5;
}

.task-module-tabs {
  display: flex;
  gap: 8px;
  margin: 14px 0;
  padding: 4px;
  border-radius: 13px;
  background: #eef4f1;
}

.task-module-tabs button {
  display: flex;
  flex: 1;
  align-items: center;
  justify-content: center;
  gap: 7px;
  padding: 10px 12px;
  border: 0;
  border-radius: 10px;
  background: transparent;
  color: #50645e;
  font-weight: 700;
  cursor: pointer;
}

.task-module-tabs button span {
  min-width: 22px;
  padding: 2px 6px;
  border-radius: 999px;
  background: #dce8e3;
  font-size: 11px;
}

.task-module-tabs button.active {
  background: #fff;
  color: #174d47;
  box-shadow: 0 3px 12px rgba(23, 77, 71, 0.1);
}

.task-module-tabs button.active span {
  background: #174d47;
  color: #fff;
}

.task-center-module + .task-center-module {
  margin-top: 18px;
}

.task-center-module-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin: 0 2px 9px;
}

.task-center-module-head h3 {
  margin: 0;
  color: #29443e;
  font-size: 16px;
}

.task-center-module-head span {
  color: #6e827a;
  font-size: 12px;
}

.task-entry-list {
  display: grid;
  gap: 9px;
}

.task-entry-button {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: center;
  width: 100%;
  gap: 8px 12px;
  padding: 14px;
  border: 1px solid #dce8e3;
  border-radius: 13px;
  background: #fff;
  color: #213b35;
  text-align: left;
  cursor: pointer;
}

.task-entry-button:hover {
  border-color: #9fc5b7;
  background: #f8fcfa;
}

.task-entry-button > strong {
  overflow: hidden;
  font-size: 15px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.task-entry-button .task-accordion-icon {
  grid-column: 3;
  grid-row: 1 / span 2;
  color: #5d7e73;
  font-size: 13px;
  font-weight: 700;
}

.task-type-badge {
  width: fit-content;
  padding: 4px 8px;
  border-radius: 999px;
  background: #e4f1eb;
  color: #28614f;
  font-size: 11px;
  font-weight: 800;
}

.task-type-badge.four-m {
  background: #fff0cf;
  color: #875b10;
}

.task-summary-meta {
  grid-column: 2;
  overflow: hidden;
  color: #6e8079;
  font-size: 12px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.workflow-task-card {
  padding: 16px;
  border: 1px solid #dce7e2;
  border-radius: 15px;
  background: #fff;
}

.task-detail-body > .workflow-task-card {
  border: 0;
  padding: 0;
}

.workflow-task-card-head > div {
  display: grid;
  gap: 4px;
}

.workflow-task-card-head span {
  color: #71817c;
  font-size: 12px;
}

.workflow-status {
  flex: 0 0 auto;
  padding: 5px 9px;
  border-radius: 999px;
  background: #e9f2ee;
  color: #386a5a;
  font-size: 11px;
}

.workflow-status.status-pending_supervisor,
.workflow-status.status-pending_debug {
  background: #fff0cf;
  color: #825710;
}

.workflow-status.status-completed {
  background: #dff1e6;
  color: #246341;
}

.workflow-content-sections {
  display: grid;
  gap: 10px;
  margin-top: 14px;
}

.workflow-content-card {
  display: grid;
  gap: 9px;
  padding: 13px;
  border-radius: 12px;
  background: #f6faf8;
}

.workflow-content-card > div {
  display: grid;
  gap: 3px;
}

.workflow-content-card h4 {
  margin: 0;
  color: #60736c;
  font-size: 12px;
}

.workflow-content-card p {
  margin: 0;
  color: #263b36;
  line-height: 1.55;
  white-space: pre-wrap;
}

.workflow-content-card .needs-adjustment-row {
  padding: 10px;
  border-radius: 10px;
  background: #fff8e9;
}

.workflow-inline-form,
.workflow-debug-form {
  display: grid;
  gap: 14px;
  margin-top: 14px;
  padding: 15px;
  border: 1px solid #d8e6e0;
  border-radius: 14px;
  background: #f8fbf9;
}

.workflow-debug-heading {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  justify-content: space-between;
  gap: 8px;
}

.workflow-debug-heading strong {
  color: #173f37;
  font-size: 16px;
}

.workflow-debug-heading span {
  color: #708079;
  font-size: 12px;
}

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

.workflow-inherited-item {
  display: grid;
  gap: 3px;
  padding: 10px;
  border-radius: 10px;
  background: #fff;
}

.workflow-inherited-item span {
  color: #7a8984;
  font-size: 11px;
}

.workflow-inherited-item strong {
  overflow-wrap: anywhere;
  color: #263f38;
  font-size: 13px;
}

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

.workflow-time-field {
  display: grid;
  gap: 7px;
  color: #536861;
  font-size: 12px;
  font-weight: 700;
}

.workflow-time-field .date-time-control {
  display: grid;
  gap: 7px;
}

.workflow-time-field .form-input,
.workflow-time-field .time-select {
  min-height: 46px;
  padding: 8px 10px;
  border: 1px solid #cfddd7;
  border-radius: 10px;
  background: #fff;
  color: #263b35;
}

.workflow-time-field .time-input-group {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr) auto;
  align-items: center;
  gap: 6px;
}

.workflow-duration {
  grid-column: 1 / -1;
  margin: 0;
  padding: 10px 12px;
  border-radius: 10px;
  background: #e7f2ed;
  color: #23604f;
  font-weight: 700;
}

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

.workflow-debug-field {
  display: grid;
  gap: 7px;
  color: #51665f;
  font-size: 12px;
  font-weight: 700;
}

.workflow-debug-field textarea {
  width: 100%;
  min-height: 92px;
  padding: 11px;
  resize: vertical;
  border: 1px solid #cfddd7;
  border-radius: 10px;
  color: #263b35;
  font: inherit;
  line-height: 1.55;
}

.workflow-debug-field textarea.workflow-readonly-field {
  background: #f0f4f2;
}

.workflow-debug-summary {
  margin: 0;
  color: #677b74;
  font-size: 12px;
}

.workflow-debug-photo {
  display: grid;
  gap: 8px;
}

.workflow-debug-photo small {
  color: #74857f;
  font-size: 12px;
}

.workflow-file-input {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  clip-path: inset(50%);
}

.workflow-file-picker {
  display: flex;
  align-items: center;
  gap: 12px;
  min-height: 72px;
  padding: 13px 15px;
  border: 1px dashed #a9c8bd;
  border-radius: 12px;
  background: #f4faf7;
  cursor: pointer;
}

.workflow-file-picker:hover,
.workflow-file-picker:focus-within {
  border-color: #518c78;
  background: #ecf7f2;
}

.workflow-file-picker.processing {
  pointer-events: none;
  border-color: #c39d4b;
  background: #fff8e7;
  opacity: 0.88;
}

.workflow-file-picker-icon {
  display: grid;
  width: 40px;
  height: 40px;
  flex: 0 0 auto;
  place-items: center;
  border-radius: 10px;
  background: #dcefe7;
}

.workflow-file-picker-icon svg {
  width: 24px;
  fill: none;
  stroke: #27614f;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 1.8;
}

.workflow-file-picker > span:last-child {
  display: grid;
  gap: 3px;
}

.workflow-file-picker strong {
  color: #23493f;
}

.workflow-debug-photo-preview,
.workflow-images {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(78px, 1fr));
  gap: 8px;
  margin-top: 8px;
}

.workflow-debug-photo-preview button,
.workflow-images button {
  position: relative;
  overflow: hidden;
  padding: 0;
  border: 1px solid #d2e1da;
  border-radius: 10px;
  background: #fff;
  cursor: pointer;
}

.workflow-debug-photo-preview button.uploaded {
  border-color: #59a17f;
  box-shadow: 0 0 0 2px rgba(89, 161, 127, 0.16);
  cursor: pointer;
}

.workflow-debug-photo-preview button.uploaded::after {
  position: absolute;
  right: 4px;
  bottom: 4px;
  padding: 2px 5px;
  border-radius: 6px;
  background: rgba(18, 58, 52, 0.88);
  color: #fff;
  content: "删除";
  font-size: 9px;
  font-weight: 800;
  pointer-events: none;
}

.workflow-debug-photo-preview img,
.workflow-images img {
  display: block;
  width: 100%;
  aspect-ratio: 1;
  object-fit: cover;
}

@media (max-width: 760px) {
  .workflow-form-grid,
  .workflow-content-sections,
  .workflow-debug-grid,
  .workflow-inherited-grid,
  .workflow-time-grid {
    grid-template-columns: 1fr;
  }

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

  .task-center-dialog,
  .task-detail-dialog {
    width: calc(100vw - 12px);
    max-height: 94dvh;
    margin: auto;
    border-radius: 15px;
  }

  .task-center-dialog-body,
  .task-detail-body {
    max-height: calc(94dvh - 72px);
    padding: 12px;
  }

  .task-detail-head {
    padding: 14px;
  }

  .notification-panel {
    top: 68px;
    right: 10px;
    width: calc(100vw - 20px);
  }

  .task-center-entry {
    grid-template-columns: 25px minmax(0, 1fr) auto;
  }

  .task-center-entry em {
    display: none;
  }

  .task-entry-button {
    grid-template-columns: auto minmax(0, 1fr) auto;
    padding: 12px;
  }
}

@media (max-width: 430px) {
  .workflow-panel {
    padding: 13px;
  }

  .workflow-role-head {
    align-items: flex-start;
  }

  .workflow-shift {
    font-size: 11px;
  }

  .workflow-inherited-grid {
    grid-template-columns: 1fr;
  }

  .task-center-module-head span {
    display: none;
  }
}

.app-update-notice {
  position: fixed;
  z-index: 200;
  left: 50%;
  bottom: max(18px, env(safe-area-inset-bottom));
  width: min(520px, calc(100vw - 28px));
  padding: 12px 16px;
  transform: translateX(-50%);
  border: 1px solid rgba(255, 255, 255, 0.22);
  border-radius: 12px;
  background: rgba(18, 58, 52, 0.95);
  box-shadow: 0 12px 35px rgba(8, 31, 28, 0.28);
  color: #fff;
  font-size: 13px;
  font-weight: 700;
  line-height: 1.5;
  text-align: center;
}

.app-update-notice[hidden] {
  display: none;
}
