:root {
  --orange: #f46a16;
  --orange-dark: #d95308;
  --orange-soft: #fff1e8;
  --ink: #151922;
  --slate: #242a35;
  --muted: #687180;
  --line: #e5e8ec;
  --surface: #f5f6f8;
  --white: #fff;
  --success: #198754;
  --success-soft: #eaf7f0;
  --danger: #b42318;
  --danger-soft: #fff0ee;
  --shadow: 0 24px 70px rgba(21, 25, 34, 0.12);
  --shadow-soft: 0 12px 35px rgba(21, 25, 34, 0.08);
  --radius-lg: 28px;
  --radius-md: 18px;
  --radius-sm: 12px;
  --content: 1180px;
  color-scheme: light;
  font-family: Inter, -apple-system, BlinkMacSystemFont, "Segoe UI", Arial, sans-serif;
  font-synthesis: none;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
}

* {
  box-sizing: border-box;
}

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

body {
  margin: 0;
  min-width: 320px;
  min-height: 100vh;
  color: var(--ink);
  background: var(--surface);
}

button,
input {
  font: inherit;
}

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

a {
  color: inherit;
}

img {
  display: block;
  max-width: 100%;
}

svg {
  display: block;
}

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

.public-page {
  position: relative;
  overflow-x: hidden;
  background:
    radial-gradient(circle at 9% 22%, rgba(244, 106, 22, 0.11) 0, rgba(244, 106, 22, 0) 28rem),
    linear-gradient(180deg, #fff 0, #f7f7f8 40rem, #f1f3f5 100%);
}

.public-page::before {
  position: absolute;
  z-index: 0;
  top: 92px;
  right: -175px;
  width: 480px;
  height: 480px;
  border: 1px solid rgba(244, 106, 22, 0.14);
  border-radius: 50%;
  box-shadow:
    0 0 0 55px rgba(244, 106, 22, 0.035),
    0 0 0 120px rgba(244, 106, 22, 0.02);
  content: "";
  pointer-events: none;
}

.site-header,
.admin-header {
  position: relative;
  z-index: 5;
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: min(calc(100% - 48px), var(--content));
  min-height: 92px;
  margin: 0 auto;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 13px;
  min-width: 0;
  text-decoration: none;
}

.brand-mark {
  display: grid;
  flex: 0 0 auto;
  width: 62px;
  height: 42px;
  place-items: center;
  border-radius: 10px 10px 10px 2px;
  color: var(--white);
  background: var(--orange);
  box-shadow: 0 7px 18px rgba(244, 106, 22, 0.25);
  font-size: 17px;
  font-weight: 900;
  letter-spacing: -0.8px;
  line-height: 1;
}

.brand-copy {
  display: grid;
  min-width: 0;
  line-height: 1.15;
}

.brand-copy strong {
  overflow: hidden;
  max-width: 260px;
  color: var(--ink);
  font-size: 14px;
  font-weight: 800;
  letter-spacing: -0.1px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.brand-copy span {
  margin-top: 5px;
  color: var(--muted);
  font-size: 11px;
  font-weight: 650;
  letter-spacing: 0.075em;
  text-transform: uppercase;
}

.brand-light .brand-copy strong {
  color: var(--white);
}

.brand-light .brand-copy span {
  color: #aeb5c0;
}

.header-note {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  color: #525b68;
  font-size: 13px;
  font-weight: 650;
}

.header-note::before {
  display: grid;
  width: 21px;
  height: 24px;
  place-items: center;
  border: 2px solid var(--orange);
  border-radius: 10px 10px 12px 12px;
  color: var(--orange);
  content: "✓";
  font-size: 12px;
  font-weight: 900;
}

.public-shell {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: minmax(0, 0.82fr) minmax(560px, 1.18fr);
  gap: clamp(44px, 7vw, 100px);
  align-items: start;
  width: min(calc(100% - 48px), var(--content));
  margin: 58px auto 90px;
}

.intro-panel {
  position: sticky;
  top: 38px;
  padding-top: 54px;
}

.eyebrow {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 17px;
  color: var(--orange-dark);
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.eyebrow > span {
  width: 28px;
  height: 2px;
  border-radius: 2px;
  background: currentColor;
}

.eyebrow.light {
  color: #ff9b60;
}

.eyebrow.centered {
  justify-content: center;
}

.intro-panel h1,
.success-card h1,
.admin-title-row h1,
.detail-title-row h1 {
  margin: 0;
  color: var(--ink);
  font-size: clamp(38px, 4.2vw, 60px);
  font-weight: 820;
  letter-spacing: -0.055em;
  line-height: 1.03;
}

.intro-panel > p {
  max-width: 510px;
  margin: 26px 0 0;
  color: #5e6672;
  font-size: 17px;
  line-height: 1.65;
}

.intro-facts {
  display: grid;
  gap: 14px;
  margin-top: 42px;
}

.intro-fact {
  display: flex;
  align-items: center;
  gap: 14px;
  color: #66707c;
  font-size: 14px;
}

.intro-fact::before {
  display: grid;
  flex: 0 0 auto;
  width: 38px;
  height: 38px;
  place-items: center;
  border: 1px solid #ffd6bd;
  border-radius: 12px;
  color: var(--orange);
  background: var(--orange-soft);
  font-size: 11px;
  font-weight: 850;
}

.intro-fact:nth-child(1)::before { content: "01"; }
.intro-fact:nth-child(2)::before { content: "02"; }
.intro-fact:nth-child(3)::before { content: "03"; }

.intro-fact strong {
  color: var(--ink);
  font-weight: 750;
}

.form-card {
  padding: clamp(28px, 4vw, 48px);
  border: 1px solid rgba(21, 25, 34, 0.07);
  border-radius: var(--radius-lg);
  background: rgba(255, 255, 255, 0.97);
  box-shadow: var(--shadow);
}

.form-card-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  padding-bottom: 27px;
  margin-bottom: 30px;
  border-bottom: 1px solid var(--line);
}

.step-badge {
  display: inline-flex;
  align-items: center;
  height: 31px;
  padding: 0 13px;
  border-radius: 99px;
  color: var(--orange-dark);
  background: var(--orange-soft);
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0.07em;
  text-transform: uppercase;
}

.form-card-heading p {
  margin: 0;
  color: var(--muted);
  font-size: 12px;
}

.required-dot,
.field label > span,
.field legend > span {
  color: var(--orange-dark);
}

.questionnaire,
.login-card {
  display: grid;
  gap: 27px;
}

.field-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 18px;
}

.field {
  min-width: 0;
}

.field > label,
.field > legend {
  display: block;
  padding: 0;
  margin: 0 0 6px;
  color: var(--ink);
  font-size: 14px;
  font-weight: 750;
}

.field-hint {
  margin: 0 0 10px;
  color: #7a828e;
  font-size: 12px;
}

.field input[type="text"],
.field input[type="tel"],
.field input[type="password"],
.field input[type="search"] {
  width: 100%;
  height: 52px;
  padding: 0 15px;
  border: 1px solid #d8dce2;
  border-radius: var(--radius-sm);
  outline: none;
  color: var(--ink);
  background: #fff;
  font-size: 15px;
  transition: border-color 160ms ease, box-shadow 160ms ease, background 160ms ease;
}

.field input::placeholder,
.search-form input::placeholder {
  color: #a6acb5;
  opacity: 1;
}

.field input:hover {
  border-color: #b6bdc7;
}

.field input:focus {
  border-color: var(--orange);
  box-shadow: 0 0 0 4px rgba(244, 106, 22, 0.12);
}

.field input[aria-invalid="true"] {
  border-color: var(--danger);
  background: #fffafa;
}

.plate-input,
.plate-badge {
  letter-spacing: 0.075em;
  text-transform: uppercase;
}

.field-error {
  margin: 7px 0 0;
  color: var(--danger);
  font-size: 12px;
  font-weight: 650;
}

.frequency-fieldset {
  padding: 0;
  border: 0;
}

.radio-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 9px;
}

.radio-option {
  position: relative;
  display: flex !important;
  align-items: center;
  gap: 10px;
  min-height: 48px;
  padding: 9px 12px;
  margin: 0 !important;
  border: 1px solid #dde1e6;
  border-radius: 11px;
  color: #444c58 !important;
  background: #fafbfc;
  cursor: pointer;
  font-size: 12px !important;
  font-weight: 650 !important;
  line-height: 1.25;
  transition: border-color 150ms ease, background 150ms ease, transform 150ms ease;
}

.radio-option:hover {
  border-color: #ffc39e;
  background: #fffaf6;
}

.radio-option:has(input:checked) {
  border-color: var(--orange);
  color: var(--ink) !important;
  background: var(--orange-soft);
}

.radio-option input {
  position: absolute;
  width: 1px;
  height: 1px;
  opacity: 0;
}

.radio-control {
  position: relative;
  flex: 0 0 auto;
  width: 17px;
  height: 17px;
  border: 1.5px solid #aeb5bf;
  border-radius: 50%;
  background: #fff;
}

.radio-option input:checked + .radio-control {
  border: 5px solid var(--orange);
}

.radio-option input:focus-visible + .radio-control {
  box-shadow: 0 0 0 4px rgba(244, 106, 22, 0.18);
}

.file-drop {
  display: flex !important;
  align-items: center;
  gap: 14px;
  min-height: 94px;
  padding: 17px;
  margin: 0 !important;
  border: 1.5px dashed #c9ced5;
  border-radius: 14px;
  background: #fafbfc;
  cursor: pointer;
  transition: border-color 160ms ease, background 160ms ease;
}

.file-drop:hover,
.file-drop.is-dragging {
  border-color: var(--orange);
  background: #fff9f5;
}

.file-drop.has-file {
  border-style: solid;
  border-color: #78bf98;
  background: #f5fbf8;
}

.file-drop.has-error {
  border-color: var(--danger);
  background: var(--danger-soft);
}

.file-drop input {
  position: absolute;
  width: 1px;
  height: 1px;
  opacity: 0;
}

.file-drop input:focus-visible ~ .file-copy strong {
  outline: 3px solid rgba(244, 106, 22, 0.2);
  outline-offset: 4px;
  border-radius: 4px;
}

.file-icon {
  display: grid;
  flex: 0 0 auto;
  width: 46px;
  height: 46px;
  place-items: center;
  border-radius: 13px;
  color: var(--orange);
  background: var(--orange-soft);
}

.file-icon::before {
  content: "↑";
  font-size: 23px;
  font-weight: 500;
  line-height: 1;
}

.has-file .file-icon {
  color: var(--success);
  background: var(--success-soft);
}

.has-file .file-icon::before {
  content: "✓";
}

.file-copy {
  display: grid;
  min-width: 0;
}

.file-copy strong {
  color: var(--ink);
  font-size: 13px;
  font-weight: 750;
}

.file-copy span {
  margin-top: 3px;
  color: #7c8490;
  font-size: 11px;
  font-weight: 500;
}

.file-button {
  flex: 0 0 auto;
  padding: 8px 11px;
  margin-left: auto;
  border: 1px solid #e0e3e7;
  border-radius: 9px;
  color: #4e5662;
  background: #fff;
  font-size: 11px;
  font-weight: 750;
}

.file-status {
  margin: 7px 0 0;
  overflow: hidden;
  color: #7a828d;
  font-size: 11px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.file-status.error {
  color: var(--danger);
  font-weight: 650;
}

.honeypot {
  position: absolute !important;
  left: -10000px !important;
  width: 1px !important;
  height: 1px !important;
  overflow: hidden !important;
}

.consent {
  display: flex;
  align-items: flex-start;
  gap: 11px;
  color: #606976;
  cursor: pointer;
  font-size: 11px;
  line-height: 1.55;
}

.consent input {
  position: absolute;
  width: 1px;
  height: 1px;
  opacity: 0;
}

.check-control {
  position: relative;
  display: grid;
  flex: 0 0 auto;
  width: 19px;
  height: 19px;
  margin-top: 1px;
  place-items: center;
  border: 1.5px solid #bbc1ca;
  border-radius: 5px;
  background: #fff;
}

.consent input:checked + .check-control {
  border-color: var(--orange);
  color: #fff;
  background: var(--orange);
}

.consent input:checked + .check-control::after {
  content: "✓";
  font-size: 12px;
  font-weight: 900;
}

.consent input:focus-visible + .check-control {
  box-shadow: 0 0 0 4px rgba(244, 106, 22, 0.18);
}

.primary-button,
.secondary-button,
.export-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 11px;
  border: 0;
  border-radius: 12px;
  text-decoration: none;
  cursor: pointer;
  font-weight: 750;
  transition: transform 150ms ease, background 150ms ease, box-shadow 150ms ease;
}

.primary-button {
  width: 100%;
  min-height: 55px;
  padding: 0 22px;
  color: #fff;
  background: var(--orange);
  box-shadow: 0 10px 25px rgba(244, 106, 22, 0.24);
  font-size: 14px;
}

.primary-button:hover,
.export-button:hover {
  background: var(--orange-dark);
  transform: translateY(-1px);
}

.primary-button:active,
.secondary-button:active,
.export-button:active {
  transform: translateY(0);
}

.primary-button:focus-visible,
.secondary-button:focus-visible,
.export-button:focus-visible,
.logout-button:focus-visible,
.back-link:focus-visible,
.person-name:focus-visible,
.person-phone:focus-visible,
.table-action a:focus-visible {
  outline: 3px solid rgba(244, 106, 22, 0.32);
  outline-offset: 3px;
}

.primary-button[disabled] {
  cursor: wait;
  opacity: 0.72;
  transform: none;
}

.button-arrow {
  font-size: 21px;
  font-weight: 500;
  line-height: 1;
}

.spinner {
  display: none;
  width: 18px;
  height: 18px;
  border: 2px solid rgba(255, 255, 255, 0.45);
  border-top-color: #fff;
  border-radius: 50%;
  animation: spin 700ms linear infinite;
}

.primary-button.is-loading .spinner {
  display: block;
}

.primary-button.is-loading .button-arrow {
  display: none;
}

.form-footnote {
  margin: -14px 0 0;
  color: #9096a0;
  font-size: 10px;
  text-align: center;
}

.alert {
  position: relative;
  display: flex;
  gap: 12px;
  padding: 14px 16px 14px 48px;
  margin-bottom: 25px;
  border: 1px solid transparent;
  border-radius: 12px;
  font-size: 12px;
}

.alert::before {
  position: absolute;
  top: 13px;
  left: 16px;
  display: grid;
  width: 22px;
  height: 22px;
  place-items: center;
  border-radius: 50%;
  font-weight: 900;
}

.alert > div {
  display: grid;
  gap: 2px;
}

.alert strong {
  color: var(--ink);
  font-weight: 800;
}

.alert-error {
  border-color: #ffd2cc;
  color: #8c2c22;
  background: var(--danger-soft);
}

.alert-error::before {
  color: #fff;
  background: var(--danger);
  content: "!";
}

.alert-success {
  border-color: #c9ead8;
  color: #28744c;
  background: var(--success-soft);
}

.alert-success::before {
  color: #fff;
  background: var(--success);
  content: "✓";
}

.alert.compact {
  margin: 0;
}

.site-footer {
  position: relative;
  z-index: 1;
  display: flex;
  justify-content: space-between;
  width: min(calc(100% - 48px), var(--content));
  padding: 25px 0 32px;
  margin: 0 auto;
  border-top: 1px solid rgba(21, 25, 34, 0.09);
  color: #7f8792;
  font-size: 11px;
}

/* Success */
.success-page {
  display: flex;
  min-height: 100vh;
  flex-direction: column;
}

.success-shell {
  position: relative;
  z-index: 1;
  display: grid;
  flex: 1;
  width: min(calc(100% - 48px), 700px);
  padding: 60px 0 90px;
  margin: 0 auto;
  place-items: center;
}

.success-card {
  width: 100%;
  padding: clamp(42px, 7vw, 76px);
  border: 1px solid rgba(21, 25, 34, 0.07);
  border-radius: var(--radius-lg);
  background: #fff;
  box-shadow: var(--shadow);
  text-align: center;
}

.success-icon {
  display: grid;
  width: 82px;
  height: 82px;
  margin: 0 auto 26px;
  place-items: center;
  border: 8px solid #effaf4;
  border-radius: 50%;
  color: #fff;
  background: var(--success);
  box-shadow: 0 12px 28px rgba(25, 135, 84, 0.18);
  font-size: 34px;
  font-weight: 800;
}

.success-card h1 {
  font-size: clamp(35px, 5vw, 50px);
}

.success-card > p {
  max-width: 460px;
  margin: 20px auto 0;
  color: var(--muted);
  font-size: 16px;
  line-height: 1.65;
}

.success-divider {
  width: 70px;
  height: 1px;
  margin: 30px auto;
  background: var(--line);
}

.secondary-button {
  min-height: 48px;
  padding: 0 19px;
  border: 1px solid #dfe3e7;
  color: var(--ink);
  background: #fff;
  font-size: 13px;
}

.secondary-button:hover {
  border-color: #ffba8f;
  color: var(--orange-dark);
  background: #fff9f5;
}

.secondary-button.small {
  min-height: 42px;
  margin-top: 15px;
}

/* Admin login */
.admin-login-page {
  background: var(--ink);
}

.login-shell {
  display: grid;
  grid-template-columns: minmax(370px, 0.9fr) minmax(480px, 1.1fr);
  min-height: 100vh;
}

.login-aside {
  position: relative;
  display: flex;
  min-height: 100vh;
  padding: clamp(32px, 5vw, 72px);
  overflow: hidden;
  flex-direction: column;
  justify-content: space-between;
  background:
    radial-gradient(circle at 0 100%, rgba(244, 106, 22, 0.26), transparent 37%),
    var(--ink);
}

.login-aside::after {
  position: absolute;
  right: -180px;
  bottom: -180px;
  width: 500px;
  height: 500px;
  border: 1px solid rgba(244, 106, 22, 0.2);
  border-radius: 50%;
  box-shadow: 0 0 0 65px rgba(244, 106, 22, 0.04), 0 0 0 140px rgba(244, 106, 22, 0.025);
  content: "";
}

.login-aside-copy {
  position: relative;
  z-index: 1;
  max-width: 510px;
  padding: 60px 0;
}

.login-aside-copy h1 {
  margin: 0;
  color: #fff;
  font-size: clamp(44px, 5vw, 68px);
  font-weight: 820;
  letter-spacing: -0.055em;
  line-height: 0.98;
}

.login-aside-copy p {
  max-width: 450px;
  margin: 26px 0 0;
  color: #aeb5c0;
  font-size: 16px;
  line-height: 1.7;
}

.login-security {
  position: relative;
  z-index: 1;
  display: flex;
  align-items: center;
  gap: 10px;
  margin: 0;
  color: #8f98a7;
  font-size: 12px;
}

.login-security::before {
  display: grid;
  width: 22px;
  height: 22px;
  place-items: center;
  border: 1px solid #687180;
  border-radius: 50%;
  content: "•";
}

.login-main {
  display: grid;
  min-height: 100vh;
  padding: 40px;
  place-items: center;
  background: #f5f6f7;
}

.login-card {
  width: min(100%, 440px);
  padding: clamp(32px, 5vw, 52px);
  border: 1px solid #e4e7eb;
  border-radius: 24px;
  background: #fff;
  box-shadow: var(--shadow-soft);
}

.login-card-heading {
  margin-bottom: 4px;
  text-align: center;
}

.login-icon {
  position: relative;
  width: 54px;
  height: 54px;
  margin: 0 auto 20px;
  border-radius: 16px;
  background: var(--orange-soft);
}

.login-icon::before,
.login-icon::after {
  position: absolute;
  left: 50%;
  content: "";
  transform: translateX(-50%);
}

.login-icon::before {
  top: 12px;
  width: 13px;
  height: 13px;
  border: 3px solid var(--orange);
  border-radius: 50%;
}

.login-icon::after {
  bottom: 10px;
  width: 27px;
  height: 13px;
  border: 3px solid var(--orange);
  border-bottom: 0;
  border-radius: 14px 14px 0 0;
}

.login-card-heading h2 {
  margin: 0;
  font-size: 25px;
  letter-spacing: -0.03em;
}

.login-card-heading p {
  margin: 7px 0 0;
  color: var(--muted);
  font-size: 13px;
}

.input-with-icon {
  position: relative;
}

.input-with-icon::before {
  position: absolute;
  z-index: 1;
  top: 50%;
  left: 17px;
  width: 7px;
  height: 7px;
  border: 2px solid #8c95a1;
  border-radius: 50%;
  content: "";
  transform: translateY(-65%);
  pointer-events: none;
}

.input-with-icon::after {
  position: absolute;
  z-index: 1;
  top: 50%;
  left: 15px;
  width: 13px;
  height: 7px;
  border: 2px solid #8c95a1;
  border-bottom: 0;
  border-radius: 8px 8px 0 0;
  content: "";
  transform: translateY(35%);
  pointer-events: none;
}

.input-with-icon input {
  padding-left: 45px !important;
}

.back-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  color: #747d89;
  font-size: 12px;
  font-weight: 650;
  text-decoration: none;
}

.back-link:hover {
  color: var(--orange-dark);
}

/* Admin dashboard */
.admin-page {
  background: #f3f4f6;
}

.admin-header {
  width: 100%;
  min-height: 74px;
  padding: 0 max(24px, calc((100% - var(--content)) / 2));
  background: var(--ink);
}

.admin-header .brand-mark {
  width: 56px;
  height: 38px;
  font-size: 15px;
}

.logout-button {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-height: 38px;
  padding: 0 14px;
  border: 1px solid #3a414d;
  border-radius: 9px;
  color: #d3d7dd;
  background: transparent;
  cursor: pointer;
  font-size: 12px;
  font-weight: 700;
  transition: border-color 150ms ease, color 150ms ease, background 150ms ease;
}

.logout-button::before {
  content: "↪";
  font-size: 16px;
}

.logout-button:hover {
  border-color: #6a7280;
  color: #fff;
  background: #242a35;
}

.admin-shell {
  width: min(calc(100% - 48px), var(--content));
  padding: 54px 0 70px;
  margin: 0 auto;
}

.admin-title-row,
.detail-title-row {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 28px;
}

.admin-title-row h1,
.detail-title-row h1 {
  font-size: clamp(32px, 4vw, 45px);
}

.admin-title-row p,
.detail-title-row p {
  margin: 10px 0 0;
  color: var(--muted);
  font-size: 14px;
}

.export-button {
  min-height: 44px;
  padding: 0 17px;
  color: #fff;
  background: var(--orange);
  box-shadow: 0 8px 20px rgba(244, 106, 22, 0.2);
  font-size: 12px;
  white-space: nowrap;
}

.export-button::before {
  content: "↓";
  font-size: 16px;
}

.stat-card {
  display: inline-flex;
  align-items: center;
  gap: 15px;
  min-width: 190px;
  padding: 17px 20px;
  margin-top: 30px;
  border: 1px solid #e1e4e8;
  border-radius: 15px;
  background: #fff;
  box-shadow: 0 5px 18px rgba(21, 25, 34, 0.04);
}

.stat-icon {
  position: relative;
  width: 42px;
  height: 42px;
  border-radius: 12px;
  background: var(--orange-soft);
}

.stat-icon::before {
  position: absolute;
  top: 9px;
  left: 16px;
  width: 9px;
  height: 9px;
  border: 2px solid var(--orange);
  border-radius: 50%;
  content: "";
}

.stat-icon::after {
  position: absolute;
  bottom: 8px;
  left: 10px;
  width: 21px;
  height: 10px;
  border: 2px solid var(--orange);
  border-bottom: 0;
  border-radius: 11px 11px 0 0;
  content: "";
}

.stat-card > div:last-child {
  display: grid;
}

.stat-card span {
  color: var(--muted);
  font-size: 11px;
  font-weight: 650;
}

.stat-card strong {
  margin-top: 1px;
  color: var(--ink);
  font-size: 23px;
  line-height: 1.1;
}

.data-card,
.detail-card {
  margin-top: 28px;
  border: 1px solid #e1e4e8;
  border-radius: 19px;
  overflow: hidden;
  background: #fff;
  box-shadow: 0 8px 30px rgba(21, 25, 34, 0.045);
}

.data-toolbar {
  display: flex;
  align-items: center;
  gap: 15px;
  padding: 18px 20px;
  border-bottom: 1px solid var(--line);
}

.search-form {
  position: relative;
  display: flex;
  width: min(100%, 570px);
}

.search-form::before {
  position: absolute;
  z-index: 1;
  top: 12px;
  left: 15px;
  width: 11px;
  height: 11px;
  border: 2px solid #8d95a0;
  border-radius: 50%;
  content: "";
  pointer-events: none;
}

.search-form::after {
  position: absolute;
  z-index: 1;
  top: 24px;
  left: 27px;
  width: 7px;
  height: 2px;
  border-radius: 2px;
  background: #8d95a0;
  content: "";
  transform: rotate(45deg);
  pointer-events: none;
}

.search-form input {
  width: 100%;
  height: 42px;
  padding: 0 98px 0 43px;
  border: 1px solid #d8dce2;
  border-radius: 10px;
  outline: 0;
  color: var(--ink);
  background: #fafbfc;
  font-size: 12px;
}

.search-form input:focus {
  border-color: var(--orange);
  box-shadow: 0 0 0 3px rgba(244, 106, 22, 0.11);
  background: #fff;
}

.search-form button {
  position: absolute;
  top: 5px;
  right: 5px;
  height: 32px;
  padding: 0 14px;
  border: 0;
  border-radius: 7px;
  color: #fff;
  background: var(--slate);
  cursor: pointer;
  font-size: 11px;
  font-weight: 700;
}

.clear-search {
  color: var(--orange-dark);
  font-size: 11px;
  font-weight: 700;
  white-space: nowrap;
}

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

.submissions-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 12px;
}

.submissions-table th {
  padding: 12px 14px;
  color: #7a828e;
  background: #fafbfc;
  font-size: 10px;
  font-weight: 800;
  letter-spacing: 0.055em;
  text-align: left;
  text-transform: uppercase;
  white-space: nowrap;
}

.submissions-table td {
  max-width: 210px;
  padding: 13px 14px;
  border-top: 1px solid #edf0f2;
  color: #555e6a;
  line-height: 1.4;
  vertical-align: middle;
}

.submissions-table tbody tr {
  transition: background 130ms ease;
}

.submissions-table tbody tr:hover {
  background: #fffaf7;
}

.table-photo {
  display: block;
  width: 56px;
  height: 43px;
  border-radius: 8px;
  overflow: hidden;
  background: #e7e9ec;
}

.table-photo img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.person-name,
.person-phone {
  display: block;
  max-width: 205px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.person-name {
  color: var(--ink);
  font-weight: 750;
  text-decoration: none;
}

.person-name:hover {
  color: var(--orange-dark);
}

.person-phone {
  margin-top: 3px;
  color: #7b8490;
  font-size: 11px;
  text-decoration: none;
}

.person-phone:hover {
  text-decoration: underline;
}

.plate-badge {
  display: inline-flex;
  align-items: center;
  min-height: 27px;
  padding: 0 8px;
  border: 1px solid #d2d6db;
  border-radius: 6px;
  color: var(--ink);
  background: #fff;
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 11px;
  font-weight: 800;
  white-space: nowrap;
}

.plate-badge.large {
  min-height: 39px;
  padding: 0 13px;
  border-width: 2px;
  font-size: 15px;
}

.submissions-table time {
  color: #737c88;
  white-space: nowrap;
}

.table-action {
  width: 48px;
}

.table-action a {
  display: grid;
  width: 31px;
  height: 31px;
  place-items: center;
  border: 1px solid #e1e4e8;
  border-radius: 8px;
  color: #68717d;
  text-decoration: none;
}

.table-action a:hover {
  border-color: #ffbc93;
  color: var(--orange-dark);
  background: var(--orange-soft);
}

.pagination {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 20px;
  padding: 18px;
  border-top: 1px solid var(--line);
  font-size: 11px;
}

.pagination a,
.pagination .disabled {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-weight: 700;
  text-decoration: none;
}

.pagination a:hover {
  color: var(--orange-dark);
}

.pagination .disabled {
  color: #bbc0c7;
}

.page-number {
  color: var(--muted);
}

.empty-state {
  display: grid;
  min-height: 340px;
  padding: 50px 24px;
  place-items: center;
  align-content: center;
  text-align: center;
}

.empty-icon {
  position: relative;
  width: 62px;
  height: 62px;
  border-radius: 18px;
  background: var(--orange-soft);
}

.empty-icon::before {
  position: absolute;
  inset: 15px 18px;
  border: 2px solid var(--orange);
  border-radius: 3px;
  content: "";
}

.empty-icon::after {
  position: absolute;
  top: 25px;
  left: 24px;
  width: 14px;
  height: 7px;
  border-top: 2px solid var(--orange);
  border-bottom: 2px solid var(--orange);
  content: "";
}

.empty-state h2 {
  margin: 17px 0 0;
  font-size: 20px;
}

.empty-state p {
  max-width: 370px;
  margin: 7px 0 0;
  color: var(--muted);
  font-size: 13px;
}

/* Submission detail */
.detail-shell {
  max-width: 1050px;
}

.detail-back {
  justify-content: flex-start;
  margin-bottom: 28px;
}

.detail-title-row {
  align-items: center;
}

.detail-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.12fr) minmax(350px, 0.88fr);
  gap: 24px;
}

.detail-card {
  min-width: 0;
}

.detail-card-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 60px;
  padding: 0 20px;
  border-bottom: 1px solid var(--line);
}

.detail-card-heading h2 {
  margin: 0;
  font-size: 14px;
  letter-spacing: -0.01em;
}

.detail-card-heading a {
  display: grid;
  width: 32px;
  height: 32px;
  place-items: center;
  border: 1px solid var(--line);
  border-radius: 8px;
  color: #626b77;
  text-decoration: none;
}

.detail-card-heading a:hover {
  border-color: #ffbc93;
  color: var(--orange-dark);
  background: var(--orange-soft);
}

.detail-photo {
  position: relative;
  display: block;
  min-height: 420px;
  overflow: hidden;
  color: #fff;
  background: #e9ebee;
  text-decoration: none;
}

.detail-photo img {
  width: 100%;
  height: 100%;
  min-height: 420px;
  max-height: 600px;
  object-fit: contain;
  background: #20242b;
}

.detail-photo span {
  position: absolute;
  right: 15px;
  bottom: 15px;
  padding: 7px 11px;
  border-radius: 8px;
  background: rgba(21, 25, 34, 0.78);
  font-size: 10px;
  font-weight: 700;
  backdrop-filter: blur(6px);
}

.detail-list {
  margin: 0;
}

.detail-list > div {
  display: grid;
  grid-template-columns: 135px 1fr;
  gap: 18px;
  padding: 18px 20px;
  border-top: 1px solid #edf0f2;
}

.detail-list > div:first-child {
  border-top: 0;
}

.detail-list dt {
  color: #7d8692;
  font-size: 11px;
  font-weight: 650;
}

.detail-list dd {
  min-width: 0;
  margin: 0;
  overflow-wrap: anywhere;
  color: var(--ink);
  font-size: 13px;
  font-weight: 650;
}

.detail-list dd a {
  color: var(--orange-dark);
  text-decoration: none;
}

.detail-list dd a:hover {
  text-decoration: underline;
}

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

@media (max-width: 1040px) {
  .public-shell {
    grid-template-columns: minmax(0, 0.7fr) minmax(530px, 1.3fr);
    gap: 38px;
  }

  .intro-panel h1 {
    font-size: 42px;
  }

  .intro-facts {
    display: none;
  }

  .submissions-table th,
  .submissions-table td {
    padding-right: 10px;
    padding-left: 10px;
  }

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

@media (max-width: 820px) {
  .public-shell {
    display: block;
    margin-top: 22px;
  }

  .intro-panel {
    position: static;
    padding: 32px 0 44px;
  }

  .intro-panel h1 {
    max-width: 640px;
    font-size: clamp(36px, 8vw, 52px);
  }

  .intro-panel > p {
    margin-top: 18px;
  }

  .login-shell {
    grid-template-columns: 1fr;
  }

  .login-aside {
    min-height: auto;
    padding: 26px;
  }

  .login-aside-copy,
  .login-security {
    display: none;
  }

  .login-main {
    min-height: calc(100vh - 94px);
  }

  .table-scroll {
    overflow: visible;
  }

  .submissions-table,
  .submissions-table tbody,
  .submissions-table tr,
  .submissions-table td {
    display: block;
    width: 100%;
  }

  .submissions-table thead {
    display: none;
  }

  .submissions-table tbody {
    display: grid;
    gap: 13px;
    padding: 15px;
  }

  .submissions-table tr {
    position: relative;
    padding: 14px 54px 14px 85px;
    border: 1px solid var(--line);
    border-radius: 13px;
  }

  .submissions-table td {
    max-width: none;
    padding: 5px 0;
    border: 0;
  }

  .submissions-table td::before {
    display: inline-block;
    width: 120px;
    color: #8a929d;
    content: attr(data-label);
    font-size: 10px;
    font-weight: 700;
  }

  .submissions-table td:first-child {
    position: absolute;
    top: 14px;
    left: 14px;
    width: 58px;
  }

  .submissions-table td:first-child::before,
  .submissions-table td:nth-child(2)::before,
  .submissions-table .table-action::before {
    display: none;
  }

  .submissions-table td:nth-child(2) {
    padding-bottom: 9px;
  }

  .table-action {
    position: absolute;
    top: 15px;
    right: 14px;
    width: 31px !important;
  }

  .person-name,
  .person-phone {
    max-width: none;
  }
}

@media (max-width: 620px) {
  .site-header,
  .admin-header,
  .public-shell,
  .site-footer,
  .admin-shell {
    width: min(calc(100% - 28px), var(--content));
  }

  .site-header {
    min-height: 78px;
  }

  .brand {
    gap: 9px;
  }

  .brand-mark {
    width: 54px;
    height: 38px;
    font-size: 15px;
  }

  .brand-copy strong {
    max-width: 190px;
    font-size: 12px;
  }

  .brand-copy span {
    font-size: 9px;
  }

  .header-note {
    display: none;
  }

  .public-shell {
    margin-bottom: 50px;
  }

  .intro-panel {
    padding: 25px 3px 33px;
  }

  .intro-panel h1 {
    font-size: 37px;
  }

  .intro-panel > p {
    font-size: 14px;
    line-height: 1.6;
  }

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

  .form-card-heading {
    padding-bottom: 20px;
    margin-bottom: 25px;
  }

  .questionnaire {
    gap: 25px;
  }

  .field-grid,
  .radio-grid {
    grid-template-columns: 1fr;
    gap: 10px;
  }

  .radio-option {
    min-height: 46px;
  }

  .file-drop {
    align-items: flex-start;
  }

  .file-button {
    display: none;
  }

  .site-footer {
    display: grid;
    gap: 5px;
  }

  .success-shell {
    width: min(calc(100% - 28px), 700px);
    padding: 35px 0 60px;
  }

  .success-card {
    padding: 42px 22px;
    border-radius: 20px;
  }

  .success-card h1 {
    font-size: 35px;
  }

  .login-main {
    padding: 22px 14px;
  }

  .login-card {
    padding: 30px 20px;
    border-radius: 20px;
  }

  .admin-header {
    width: 100%;
    min-height: 68px;
    padding: 0 14px;
  }

  .admin-header .brand-copy strong {
    display: none;
  }

  .admin-header .brand-copy span {
    margin-top: 0;
  }

  .logout-button {
    padding: 0 11px;
  }

  .admin-shell {
    padding: 37px 0 50px;
  }

  .admin-title-row,
  .detail-title-row {
    align-items: flex-start;
    flex-direction: column;
  }

  .admin-title-row h1,
  .detail-title-row h1 {
    font-size: 34px;
  }

  .export-button {
    width: 100%;
  }

  .stat-card {
    width: 100%;
  }

  .data-toolbar {
    align-items: stretch;
    flex-direction: column;
  }

  .search-form {
    width: 100%;
  }

  .submissions-table tbody {
    padding: 10px;
  }

  .submissions-table tr {
    padding-right: 42px;
    padding-left: 78px;
  }

  .submissions-table td::before {
    display: block;
    width: auto;
    margin-bottom: 2px;
  }

  .pagination {
    gap: 12px;
  }

  .detail-photo,
  .detail-photo img {
    min-height: 280px;
  }

  .detail-list > div {
    grid-template-columns: 1fr;
    gap: 5px;
  }
}

@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;
  }
}
