:root {
  --ink: #18211f;
  --muted: #71807b;
  --line: #dce6e1;
  --paper: #f7faf8;
  --white: #ffffff;
  --mint: #b9efd8;
  --green: #267d5d;
  --green-soft: #e6f6ee;
  --orange: #c76238;
  --red-soft: #fbe7e3;
  --maintenance-surface: rgba(255, 255, 255, .82);
  --maintenance-text: #18211f;
  --maintenance-muted: rgba(24, 33, 31, .66);
  --maintenance-border: rgba(24, 33, 31, .1);
  --maintenance-chip: rgba(199, 98, 56, .1);
  --maintenance-shadow: 0 24px 70px rgba(24, 33, 31, .1);
}

* { box-sizing: border-box; }

[hidden] { display: none !important; }

.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  margin: -1px;
  padding: 0;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
  border: 0;
}

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

button, input, select { font: inherit; }
button { cursor: pointer; }
button:disabled { cursor: wait; opacity: .55; }

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

.shell { padding: 34px 0 72px; }

.site-header,
.admin-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}

.site-nav {
  display: flex;
  align-items: center;
  gap: 22px;
}

.site-header { margin-bottom: 58px; }

.maintenance-notice {
  position: relative;
  display: flex;
  min-height: 380px;
  max-width: 880px;
  flex-direction: column;
  justify-content: center;
  overflow: hidden;
  margin: 82px 0 56px;
  border: 1px solid var(--maintenance-border);
  border-radius: 24px;
  background: var(--maintenance-surface);
  box-shadow: var(--maintenance-shadow);
  padding: clamp(32px, 7vw, 64px);
  backdrop-filter: saturate(180%) blur(24px);
  -webkit-backdrop-filter: saturate(180%) blur(24px);
}

.maintenance-notice::after {
  position: absolute;
  width: 300px;
  height: 300px;
  right: -112px;
  bottom: -152px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(185, 239, 216, .72), rgba(185, 239, 216, 0) 68%);
  content: '';
  pointer-events: none;
}

.maintenance-notice > * { position: relative; z-index: 1; }
.maintenance-notice .eyebrow { margin: 28px 0 12px; }

.maintenance-status {
  display: inline-flex;
  width: max-content;
  min-height: 32px;
  align-items: center;
  gap: 8px;
  border-radius: 999px;
  background: var(--maintenance-chip);
  color: var(--orange);
  padding: 6px 12px;
  font-size: 12px;
  font-weight: 700;
}

.maintenance-status-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--orange);
  box-shadow: 0 0 0 0 rgba(199, 98, 56, .34);
  animation: maintenance-pulse 2s ease-out infinite;
}

.maintenance-notice h1 {
  max-width: 720px;
  margin: 0;
  color: var(--maintenance-text);
  font-size: clamp(36px, 6vw, 64px);
  font-weight: 760;
  letter-spacing: -.035em;
  line-height: 1.08;
}

.maintenance-notice h1 span { color: var(--green); }

.maintenance-notice p {
  max-width: 620px;
  margin: 24px 0 0;
  color: var(--maintenance-muted);
  font-size: 15px;
  line-height: 1.75;
}

.maintenance-notice .maintenance-detail {
  margin-top: 8px;
  font-size: 12px;
}

.maintenance-action {
  display: inline-flex;
  width: max-content;
  min-height: 44px;
  align-items: center;
  margin-top: 28px;
  border-radius: 12px;
  background: var(--ink);
  color: var(--white);
  padding: 11px 18px;
  font-size: 13px;
  font-weight: 700;
  text-decoration: none;
  transition: transform 300ms cubic-bezier(.34, 1.56, .64, 1), background 150ms ease;
}

.maintenance-action:hover { background: var(--green); transform: translateY(-1px); }
.maintenance-action:focus-visible { outline: 3px solid var(--mint); outline-offset: 3px; }

.maintenance-pending .hero,
.maintenance-pending .price-menu,
.maintenance-mode .hero,
.maintenance-mode .price-menu { display: none; }

.maintenance-mode .lookup-section { margin-top: 56px; }

@keyframes maintenance-pulse {
  70% { box-shadow: 0 0 0 9px rgba(199, 98, 56, 0); }
  100% { box-shadow: 0 0 0 0 rgba(199, 98, 56, 0); }
}

@media (prefers-color-scheme: dark) {
  :root {
    --maintenance-surface: rgba(28, 28, 30, .94);
    --maintenance-text: #f5f5f7;
    --maintenance-muted: rgba(235, 235, 245, .66);
    --maintenance-border: rgba(255, 255, 255, .1);
    --maintenance-chip: rgba(255, 159, 10, .14);
    --maintenance-shadow: 0 24px 70px rgba(0, 0, 0, .3);
  }

  .maintenance-status { color: #ff9f0a; }
  .maintenance-status-dot { background: #ff9f0a; }
}

@media (prefers-reduced-motion: reduce) {
  .maintenance-status-dot { animation: none; }
  .maintenance-action { transition-duration: .01ms; }
}

.brand {
  color: var(--ink);
  font-size: 16px;
  font-weight: 800;
  text-decoration: none;
}

.eyebrow {
  margin-bottom: 16px;
  color: var(--green);
  font-family: "SFMono-Regular", Consolas, monospace;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 1.6px;
}

.hero {
  max-width: 760px;
  padding-bottom: 48px;
}

.hero h1 {
  max-width: 700px;
  margin: 0 0 22px;
  font-size: clamp(42px, 7vw, 72px);
  line-height: 1.06;
  font-weight: 800;
}

.hero h1 span { color: var(--green); }

.hero p {
  max-width: 560px;
  margin: 0;
  color: var(--muted);
  font-size: 15px;
  line-height: 1.8;
}

.price-menu {
  display: grid;
  grid-template-columns: 220px minmax(0, 1fr);
  gap: 42px;
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  padding: 24px 0;
  margin-bottom: 40px;
}

.price-menu-head .eyebrow { margin-bottom: 9px; }
.price-menu-head h2 { margin: 0 0 7px; font-size: 17px; }
.price-menu-head p { margin: 0; color: var(--muted); font-size: 11px; line-height: 1.7; }
.price-menu-list { display: grid; gap: 0; }
.price-row {
  display: grid;
  grid-template-columns: 100px minmax(0, 1fr);
  gap: 16px;
  align-items: center;
  border-bottom: 1px solid var(--line);
  padding: 10px 0;
  font-size: 12px;
}
.price-row:last-child { border-bottom: 0; }
.price-row strong { font-size: 12px; }
.price-row span { color: var(--muted); }

.text-link,
.ghost {
  color: var(--ink);
  font-size: 12px;
  font-weight: 700;
  text-decoration: none;
}

.text-link {
  border-bottom: 1px solid var(--ink);
  padding-bottom: 4px;
}

.workbench {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 280px;
  gap: 48px;
  border-top: 1px solid var(--line);
  padding-top: 40px;
}

.section-head {
  display: flex;
  align-items: flex-start;
  gap: 18px;
  margin-bottom: 20px;
}

.section-head.compact { margin-top: 38px; }

.service-choice { margin-top: 0; margin-bottom: 24px; }
.service-choice .service-options { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.service-choice .notice { margin-top: 8px; }

.step {
  padding-top: 4px;
  color: var(--green);
  font-family: "SFMono-Regular", Consolas, monospace;
  font-size: 11px;
  font-weight: 600;
}

.section-head h2,
.queue-head h2 {
  margin: 0 0 5px;
  font-size: 18px;
}

.section-head p,
.queue-head span {
  margin: 0;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.6;
}

.dropzone {
  display: flex;
  min-height: 172px;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  border: 1.5px dashed #a7bdb2;
  background: rgba(255, 255, 255, .58);
  cursor: pointer;
  transition: border-color .2s ease, background .2s ease;
}

.dropzone:hover,
.dropzone.drag {
  border-color: var(--green);
  background: var(--green-soft);
}

.dropzone input { display: none; }

.upload-icon {
  margin-bottom: 13px;
  color: var(--green);
  font-size: 30px;
  line-height: 1;
}

.dropzone strong { font-size: 14px; }
.dropzone small { margin-top: 8px; color: var(--muted); font-size: 12px; }

.file-list {
  display: grid;
  gap: 8px;
  margin-top: 12px;
}

.file-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  min-width: 0;
  border-bottom: 1px solid var(--line);
  padding: 9px 0;
}

.file-item strong {
  min-width: 0;
  overflow: hidden;
  font-size: 12px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.file-item small {
  flex: 0 0 auto;
  color: var(--muted);
  font-size: 11px;
}

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

.field {
  display: block;
  color: var(--muted);
  font-size: 12px;
}

input,
select {
  display: block;
  width: 100%;
  margin-top: 8px;
  border: 1px solid var(--line);
  border-radius: 0;
  background: var(--white);
  color: var(--ink);
  padding: 12px;
  font-size: 13px;
}

input:focus,
select:focus {
  outline: 2px solid var(--mint);
  border-color: var(--green);
}

.choice-group {
  margin: 22px 0 0;
  border: 0;
  padding: 0;
}

.choice-group legend {
  margin-bottom: 9px;
  color: var(--muted);
  font-size: 12px;
}

.payment-choice {
  border-top: 1px solid var(--line);
  padding-top: 22px;
}

.payment-methods {
  grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
}

.payment-unavailable {
  display: block;
  grid-column: 1 / -1;
  padding: 12px;
  color: var(--orange);
  font-size: 13px;
  text-align: center;
}

.segmented {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  border: 1px solid var(--line);
  background: var(--white);
}

.segmented label { position: relative; }

.segmented input {
  position: absolute;
  width: 1px;
  height: 1px;
  margin: -1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
}

.segmented span {
  display: block;
  padding: 12px;
  color: var(--muted);
  text-align: center;
  font-size: 13px;
  cursor: pointer;
}

.segmented input:checked + span {
  background: var(--ink);
  color: var(--white);
}

.quote-box {
  margin-top: 28px;
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  padding: 18px 0 15px;
}

.quote-heading {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 17px;
  color: var(--muted);
  font-size: 12px;
}

.quote-note {
  margin: -7px 0 16px;
  color: var(--muted);
  font-size: 11px;
  line-height: 1.6;
}

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

.quote-grid small,
.result-details dt {
  display: block;
  color: var(--muted);
  font-size: 11px;
}

.quote-grid strong {
  display: block;
  margin-top: 7px;
  font-family: "SFMono-Regular", Consolas, monospace;
  font-size: 20px;
  font-weight: 500;
}

.quote-grid em {
  color: var(--muted);
  font-family: inherit;
  font-size: 11px;
  font-style: normal;
}

.quote-total { text-align: right; }
.quote-total strong { font-size: 25px; }

.form-actions {
  display: grid;
  grid-template-columns: minmax(0, .8fr) minmax(0, 1.2fr);
  gap: 10px;
  margin-top: 20px;
}

.primary,
.secondary {
  display: flex;
  min-height: 50px;
  align-items: center;
  justify-content: space-between;
  border: 0;
  padding: 14px 17px;
  font-weight: 700;
}

.primary { background: var(--ink); color: var(--white); }
.primary:hover { background: var(--green); }

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

.secondary:hover { border-color: var(--green); color: var(--green); }

.form-message {
  min-height: 20px;
  margin: 12px 0 0;
  color: var(--muted);
  font-size: 12px;
}

.form-message.loading { color: var(--green); }
.form-message.success { color: var(--green); }
.form-message.error,
.error { color: var(--orange); }

.notice {
  max-width: 620px;
  margin: 10px 0 0;
  color: var(--muted);
  font-size: 11px;
  line-height: 1.7;
}

.side-note {
  height: max-content;
  border-left: 1px solid var(--line);
  padding: 4px 0 0 26px;
}

.status-line { display: flex; align-items: center; gap: 8px; }
.status-line strong { font-size: 13px; }
.status-dot { width: 8px; height: 8px; border-radius: 50%; background: #52c68e; }

.side-note p {
  margin: 18px 0;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.8;
}

.mini-rule { height: 1px; margin: 24px 0 14px; background: var(--line); }
.side-note > span { color: var(--muted); font-family: monospace; font-size: 11px; }

.result {
  display: flex;
  max-width: 720px;
  gap: 28px;
  margin-top: 48px;
  background: var(--mint);
  padding: 30px;
}

.result-mark { color: var(--green); font-size: 28px; }
.result h2 { margin: 0 0 7px; font-size: 27px; }
.result p { margin: 0 0 20px; color: #42665a; font-size: 13px; line-height: 1.7; }

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

.result-details dd {
  margin: 7px 0 0;
  color: var(--ink);
  font-family: monospace;
  font-size: 17px;
  font-weight: 600;
}

.result-details div:nth-child(2) dd { letter-spacing: 2px; }

.ghost {
  border: 0;
  background: transparent;
  padding: 0;
}

.result .ghost {
  margin-top: 24px;
  border-bottom: 1px solid var(--ink);
  padding-bottom: 3px;
}

.result-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 20px;
  margin-top: 24px;
}

.result-actions .primary {
  display: inline-flex;
  min-height: 42px;
  align-items: center;
  gap: 20px;
  padding: 11px 14px;
  color: var(--white);
  text-decoration: none;
}

.result-actions .ghost { margin-top: 0; }

.lookup-section {
  max-width: 720px;
  margin-top: 70px;
  border-top: 1px solid var(--line);
  padding-top: 34px;
}

.lookup-form {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: end;
  gap: 10px;
}

.lookup-form .secondary { min-height: 46px; }

.status-result {
  margin-top: 22px;
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  padding: 20px 0;
}

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

.status-summary small {
  display: block;
  color: var(--muted);
  font-size: 11px;
}

.status-summary strong {
  display: block;
  margin-top: 7px;
  font-family: monospace;
  font-size: 15px;
  font-weight: 600;
}

.status-timeline {
  display: grid;
  gap: 0;
  margin: 24px 0 20px;
}

.status-step {
  display: flex;
  min-height: 34px;
  align-items: flex-start;
  gap: 12px;
  color: var(--muted);
  font-size: 12px;
}

.status-step-dot {
  width: 9px;
  height: 9px;
  flex: 0 0 auto;
  margin-top: 3px;
  border: 1px solid #a7bdb2;
  border-radius: 50%;
  background: var(--white);
}

.status-step:not(:last-child) .status-step-dot::after {
  display: block;
  width: 1px;
  height: 25px;
  margin: 8px 0 0 3px;
  background: var(--line);
  content: '';
}

.status-step.done,
.status-step.active { color: var(--ink); }

.status-step.done .status-step-dot,
.status-step.active .status-step-dot {
  border-color: var(--green);
  background: var(--green);
}

.status-step strong { font-weight: 600; }

.status-result > .text-button { display: inline-block; }

.payment-result-page { max-width: 820px; }

.payment-result {
  max-width: 720px;
  margin-top: 90px;
  border-top: 1px solid var(--line);
  padding-top: 34px;
}

.payment-result h1 { margin: 0 0 10px; font-size: clamp(30px, 5vw, 48px); }
.payment-result > p { max-width: 560px; margin: 0; color: var(--muted); font-size: 14px; line-height: 1.8; }
.payment-result-details { margin-top: 32px; grid-template-columns: repeat(3, minmax(0, 1fr)); }
.payment-result.has-error { border-color: var(--orange); }

/* Admin */
.admin-body { background: #f1f5f3; }
.admin-shell { padding: 48px 0 72px; }

.login-view {
  width: min(420px, 100%);
  margin: 12vh auto 0;
  border-top: 1px solid var(--line);
  padding-top: 34px;
}

.login-view h1 { margin: 0 0 10px; font-size: 35px; }
.login-view > p { margin: 0 0 28px; color: var(--muted); font-size: 13px; line-height: 1.7; }
.login-view .primary { width: 100%; margin-top: 18px; }

.admin-header {
  align-items: flex-end;
  border-bottom: 1px solid var(--line);
  padding-bottom: 28px;
}

.admin-header h1 { margin: 0; font-size: 36px; }
.header-actions { display: flex; align-items: center; gap: 22px; }

.stats {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  border-bottom: 1px solid var(--line);
}

.stats div { padding: 23px 18px 22px 0; }
.stats small { display: block; margin-bottom: 11px; color: var(--muted); font-size: 12px; }
.stats strong { font-family: monospace; font-size: 27px; font-weight: 500; }

.settings-section {
  border-bottom: 1px solid var(--line);
  padding: 32px 0 34px;
}

.printer-status-section {
  position: relative;
  background: linear-gradient(135deg, rgba(185, 239, 216, .18), rgba(255, 255, 255, 0));
}

.printer-status-panel {
  display: flex;
  max-width: 760px;
  align-items: center;
  justify-content: space-between;
  gap: 32px;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: rgba(255, 255, 255, .72);
  padding: 22px;
  box-shadow: 0 8px 28px rgba(24, 33, 31, .06);
}

.printer-status-copy { min-width: 0; }

.printer-state-pill {
  display: inline-flex;
  min-height: 26px;
  align-items: center;
  border-radius: 999px;
  background: var(--green-soft);
  color: var(--green);
  padding: 4px 10px;
  font-size: 10px;
  font-weight: 800;
  letter-spacing: .04em;
}

.printer-status-copy > strong {
  display: block;
  margin-top: 13px;
  font-size: 17px;
}

.printer-status-copy > p {
  max-width: 470px;
  margin: 7px 0 0;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.7;
}

.printer-toggle {
  min-width: 210px;
  border-left: 1px solid var(--line);
  padding: 8px 0 8px 24px;
}

.printer-status-section.is-fault {
  background: linear-gradient(135deg, rgba(199, 98, 56, .1), rgba(255, 255, 255, 0));
}

.printer-status-section.is-fault .printer-state-pill {
  background: var(--red-soft);
  color: var(--orange);
}

.printer-status-section.is-fault .printer-status-panel { border-color: rgba(199, 98, 56, .28); }

.settings-section .section-head { margin-bottom: 22px; }
.settings-form { max-width: 760px; }
.settings-form > .field { max-width: 250px; }

.rate-table {
  overflow-x: auto;
  margin-top: 22px;
  border-top: 1px solid var(--line);
}

.rate-head,
.rate-row {
  display: grid;
  grid-template-columns: 100px repeat(3, minmax(120px, 1fr));
  align-items: center;
  gap: 10px;
  min-width: 560px;
  border-bottom: 1px solid var(--line);
  padding: 10px 0;
}

.rate-head { color: var(--muted); font-size: 11px; }
.rate-row strong { font-size: 12px; }
.rate-row input { margin-top: 0; }

.settings-actions {
  display: flex;
  align-items: center;
  gap: 18px;
  margin-top: 18px;
}

.settings-actions .secondary { min-height: 42px; }
.quiet { color: var(--muted); font-size: 11px; }

.payment-settings-section { background: rgba(255, 255, 255, .24); }

.toggle-field {
  display: flex;
  align-items: center;
  gap: 12px;
  cursor: pointer;
  color: var(--ink);
  font-size: 13px;
}

.toggle-field > input {
  position: absolute;
  width: 1px;
  height: 1px;
  margin: -1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
}

.toggle-control {
  position: relative;
  width: 40px;
  height: 22px;
  flex: 0 0 auto;
  border-radius: 11px;
  background: #cbd6d1;
  transition: background .2s ease;
}

.toggle-control::after {
  position: absolute;
  top: 3px;
  left: 3px;
  width: 16px;
  height: 16px;
  border-radius: 50%;
  background: var(--white);
  content: '';
  transition: transform .2s ease;
}

.toggle-field > input:checked + .toggle-control { background: var(--green); }
.toggle-field > input:checked + .toggle-control::after { transform: translateX(18px); }
.toggle-field > input:focus-visible + .toggle-control { outline: 2px solid var(--mint); }
.toggle-field strong { display: block; font-size: 13px; }
.toggle-field small { display: block; margin-top: 4px; color: var(--muted); font-size: 11px; }

.payment-fields {
  display: grid;
  grid-template-columns: minmax(0, 1.4fr) minmax(140px, .7fr) minmax(0, 1fr);
  gap: 12px;
  margin-top: 22px;
}

.field-note { display: block; margin-top: 5px; color: var(--muted); font-size: 10px; }

.notification-fields {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: 12px;
  margin-top: 24px;
}

.notification-events {
  margin: 24px 0 0;
  border: 0;
  padding: 0;
}

.notification-events legend {
  margin-bottom: 12px;
  color: var(--muted);
  font-size: 11px;
}

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

.notification-event {
  min-height: 72px;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: rgba(255, 255, 255, .72);
  padding: 14px;
}

.notification-actions { flex-wrap: wrap; }

.payment-method-editor { margin-top: 26px; }
.payment-editor-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.payment-editor-head strong { display: block; font-size: 12px; }
.payment-editor-head small { display: block; margin-top: 4px; color: var(--muted); font-size: 11px; }
.payment-method-list { display: grid; gap: 8px; margin-top: 12px; }

.payment-method-row {
  display: grid;
  grid-template-columns: 68px minmax(100px, .8fr) minmax(120px, 1fr) 36px;
  gap: 8px;
  align-items: center;
}

.payment-method-row input { margin-top: 0; padding: 10px; font-size: 12px; }
.method-enabled { display: flex; align-items: center; gap: 5px; color: var(--muted); font-size: 11px; }
.method-enabled input { width: auto; margin: 0; }
.remove-method { padding: 7px 10px; color: var(--orange); }

.callback-urls {
  display: grid;
  gap: 10px;
  margin-top: 26px;
  border-top: 1px solid var(--line);
  padding-top: 18px;
}

.callback-urls div { display: grid; grid-template-columns: 110px minmax(0, 1fr); gap: 12px; align-items: center; }
.callback-urls small { color: var(--muted); font-size: 11px; }
.callback-urls code { overflow-wrap: anywhere; color: var(--ink); font-family: monospace; font-size: 11px; }
.settings-hint { margin: 18px 0 0; color: var(--muted); font-size: 11px; line-height: 1.6; }
.settings-hint.success { color: var(--green); }
.settings-hint.error { color: var(--orange); }
.quiet.success { color: var(--green); }

.special-rate-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
  max-width: 760px;
  margin-top: 18px;
}

.queue { padding-top: 34px; }
.queue-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 16px; }
.queue-head h2 { margin-bottom: 4px; }
.icon-button { border: 1px solid var(--line); background: var(--white); color: var(--ink); padding: 8px 11px; font-size: 18px; line-height: 1; }
.icon-button:hover { border-color: var(--green); color: var(--green); }

.jobs { border-top: 1px solid var(--line); }

.job {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 110px minmax(190px, 280px);
  gap: 22px;
  align-items: start;
  border-bottom: 1px solid var(--line);
  padding: 19px 0;
}

.job-title-row { display: flex; align-items: center; gap: 12px; }
.job-name { font-family: monospace; font-size: 13px; font-weight: 700; }
.job-meta { margin-top: 7px; color: var(--muted); font-size: 11px; line-height: 1.6; }

.admin-file-list {
  margin-top: 12px;
  gap: 0;
}

.admin-file-list li {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  max-width: 560px;
  padding: 6px 0;
  color: var(--ink);
  font-size: 11px;
}

.admin-file-list li span {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.admin-file-list a,
.text-button {
  border: 0;
  background: transparent;
  color: var(--green);
  padding: 0;
  font-size: 11px;
  font-weight: 700;
  text-decoration: none;
  white-space: nowrap;
}

.admin-file-list a:hover,
.text-button:hover { color: var(--ink); }

.job-amount {
  font-family: monospace;
  font-size: 16px;
  font-weight: 500;
}

.job-amount small {
  display: block;
  margin-top: 5px;
  color: var(--muted);
  font-family: inherit;
  font-size: 10px;
}

.job-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 12px;
  padding-top: 2px;
}

.badge {
  display: inline-block;
  background: #e0eae5;
  color: var(--green);
  padding: 5px 8px;
  font-family: monospace;
  font-size: 10px;
  font-weight: 500;
}

.badge.downloaded { background: #e7f0f8; color: #3c6685; }
.badge.printing { background: #fff0e9; color: #bd5630; }
.badge.completed,
.badge.collected { background: #dff5e8; color: #25704e; }
.badge.failed,
.badge.canceled { background: var(--red-soft); color: #a73b33; }

.badge.awaiting_payment { background: #fff5db; color: #9b6c17; }
.payment-badge { display: inline-block; padding: 5px 8px; font-family: monospace; font-size: 10px; }
.payment-badge.paid { background: #dff5e8; color: #25704e; }
.payment-badge.pending { background: #fff5db; color: #9b6c17; }
.payment-badge.payment-warning { background: var(--red-soft); color: #a73b33; }
.locked { color: var(--muted); font-size: 10px; }

.job > .error {
  grid-column: 1 / -1;
  margin-top: -10px;
  font-size: 11px;
}

.empty { padding: 44px 0; color: var(--muted); font-size: 13px; }

.upload-progress {
  margin-top: 18px;
  padding: 18px 20px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: rgba(255, 255, 255, .72);
}

.upload-progress-head,
.upload-progress-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.upload-progress-head { font-size: 13px; }
.upload-progress-head span,
.upload-progress-meta { color: var(--muted); font-size: 11px; }

.upload-progress-track {
  height: 6px;
  margin: 13px 0 10px;
  overflow: hidden;
  border-radius: 999px;
  background: #e5e8e6;
}

.upload-progress-bar {
  display: block;
  width: 0;
  height: 100%;
  border-radius: inherit;
  background: var(--green);
  transition: width .18s ease;
}

.upload-retry { margin-top: 14px; }

.performance-section { margin-bottom: 34px; }
.performance-head { align-items: flex-end; }

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

.performance-card {
  min-width: 0;
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: rgba(255, 255, 255, .62);
}

.performance-card-head {
  display: flex;
  justify-content: space-between;
  gap: 8px;
  margin-bottom: 14px;
  font-size: 12px;
}

.performance-card-head span { color: var(--muted); font-size: 10px; }
.performance-values { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; margin: 0; }
.performance-values div { min-width: 0; }
.performance-values dt { color: var(--muted); font-size: 9px; }
.performance-values dd { margin: 4px 0 0; font-family: monospace; font-size: 11px; }
.performance-empty { grid-column: 1 / -1; padding: 18px 0; color: var(--muted); font-size: 12px; }
.performance-meta { margin-top: 12px; }

.admin-file-actions {
  display: inline-flex;
  align-items: center;
  justify-content: flex-end;
  gap: 12px;
  margin-left: auto;
}

.file-delete-button {
  border: 0;
  background: transparent;
  color: #a73b33;
  padding: 0;
  font: inherit;
  font-size: 11px;
  cursor: pointer;
}

.file-delete-button:hover { color: #701f19; }
.file-delete-button:disabled { cursor: wait; opacity: .45; }
.file-deleted { color: #a73b33; }
.admin-file-list li.is-deleted > span { color: var(--muted); text-decoration: line-through; }

@media (max-width: 760px) {
  .shell,
  .admin-shell { width: min(100% - 36px, 1120px); padding-top: 26px; }
  .site-header { margin-bottom: 42px; }
  .maintenance-notice { min-height: 430px; margin: 48px 0 42px; border-radius: 20px; }
  .maintenance-notice h1 { font-size: clamp(34px, 11vw, 48px); }
  .site-nav { gap: 12px; }
  .site-nav .text-link { font-size: 11px; }
  .hero h1 { font-size: 46px; }
  .price-menu { display: block; padding: 22px 0; }
  .price-menu-list { margin-top: 15px; }
  .service-choice .service-options { grid-template-columns: 1fr; }
  .special-rate-grid { grid-template-columns: 1fr; }
  .workbench { display: block; }
  .side-note { margin-top: 40px; border-top: 1px solid var(--line); border-left: 0; padding: 24px 0 0; }
  .form-actions { grid-template-columns: 1fr; }
  .quote-grid { gap: 10px; }
  .quote-grid strong { font-size: 18px; }
  .quote-total strong { font-size: 22px; }
  .result { padding: 23px; }
  .result-details { grid-template-columns: 1fr 1fr; }
  .result-details div:last-child { grid-column: 1 / -1; }
  .lookup-form { grid-template-columns: 1fr; }
  .lookup-form .secondary { width: 100%; }
  .status-summary { grid-template-columns: 1fr 1fr; }
  .status-summary div:last-child { grid-column: 1 / -1; }
  .payment-result { margin-top: 54px; }
  .payment-result-details { grid-template-columns: 1fr 1fr; }
  .payment-fields { grid-template-columns: 1fr; }
  .notification-fields,
  .notification-event-grid { grid-template-columns: 1fr; }
  .printer-status-panel { align-items: stretch; flex-direction: column; gap: 20px; }
  .printer-toggle { min-width: 0; border-top: 1px solid var(--line); border-left: 0; padding: 20px 0 0; }
  .payment-method-row { grid-template-columns: 58px minmax(80px, .8fr) minmax(100px, 1fr) 34px; gap: 5px; }
  .payment-method-row input { padding: 9px 6px; font-size: 11px; }
  .callback-urls div { grid-template-columns: 1fr; gap: 5px; }
  .admin-header { align-items: flex-start; flex-direction: column; }
  .admin-header h1 { font-size: 30px; }
  .header-actions { width: 100%; justify-content: space-between; }
  .stats { grid-template-columns: 1fr 1fr; }
  .stats div { padding: 19px 8px 18px 0; }
  .rate-table { overflow-x: visible; }
  .rate-head,
  .rate-row {
    grid-template-columns: 52px repeat(3, minmax(0, 1fr));
    gap: 4px;
    min-width: 0;
  }
  .rate-head { font-size: 10px; }
  .rate-row input { padding: 10px 6px; font-size: 12px; }
  .job { grid-template-columns: minmax(0, 1fr) auto; gap: 10px; }
  .job-amount { grid-column: 2; grid-row: 1; text-align: right; }
  .job-actions { grid-column: 1 / -1; justify-content: flex-start; }
  .job > .error { grid-column: 1 / -1; }
  .performance-grid { grid-template-columns: 1fr 1fr; }
  .upload-progress-meta { align-items: flex-start; flex-direction: column; gap: 4px; }
  .admin-file-actions { gap: 9px; }
}
