:root {
  --ink: #10151a;
  --muted: #67717b;
  --line: #d8dde2;
  --paper: #f4f5f6;
  --panel: #ffffff;
  --brand: #cf2029;
  --brand-dark: #a81720;
  --brand-soft: #fce8e9;
  --steel: #2c333a;
  --steel-soft: #eceff1;
  --danger: #cf2029;
  --amber: #f2b705;
  --green: #287345;
  --shadow: 0 18px 40px rgba(16, 21, 26, 0.1);
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: Arial, Helvetica, sans-serif;
}

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

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

.topbar {
  align-items: center;
  background: var(--ink);
  border-bottom: 3px solid var(--brand);
  color: #fff;
  display: grid;
  gap: 18px;
  grid-template-columns: minmax(230px, 1fr) auto minmax(180px, auto);
  min-height: 72px;
  padding: 12px clamp(16px, 4vw, 42px);
  position: sticky;
  top: 0;
  z-index: 10;
}

.brand,
.user-menu,
.nav,
.photo-actions,
.filter-form {
  align-items: center;
  display: flex;
}

.brand {
  gap: 12px;
}

.brand-icon {
  align-items: center;
  background: var(--brand);
  border: 1px solid rgba(255, 255, 255, 0.24);
  border-radius: 8px;
  color: #fff;
  display: inline-flex;
  height: 42px;
  justify-content: center;
  width: 42px;
}

.brand small,
.hint,
.page-title p,
.metric-row small,
.photo-meta small,
.list-item span,
.dropzone span {
  color: var(--muted);
}

.topbar .brand small,
.topbar .user-menu {
  color: rgba(255, 255, 255, 0.72);
}

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

.nav {
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 8px;
  gap: 4px;
  padding: 4px;
}

.nav a {
  border-radius: 6px;
  color: rgba(255, 255, 255, 0.72);
  padding: 9px 12px;
  white-space: nowrap;
}

.nav a.active {
  background: var(--brand);
  box-shadow: 0 1px 4px rgba(16, 21, 26, 0.24);
  color: #fff;
}

.user-menu {
  gap: 10px;
  justify-content: end;
}

.layout {
  margin: 0 auto;
  max-width: 1220px;
  padding: 28px clamp(16px, 4vw, 42px) 52px;
}

.login-layout {
  min-height: 100vh;
  padding: clamp(22px, 5vw, 64px);
}

.login-panel {
  align-items: stretch;
  display: grid;
  gap: 22px;
  grid-template-columns: minmax(0, 1.1fr) minmax(310px, 430px);
  margin: 0 auto;
  max-width: 980px;
  min-height: calc(100vh - 128px);
}

.login-copy {
  background:
    linear-gradient(135deg, rgba(207, 32, 41, 0.94), rgba(16, 21, 26, 0.95)),
    repeating-linear-gradient(90deg, transparent, transparent 24px, rgba(255, 255, 255, 0.12) 25px);
  align-items: flex-start;
  border-radius: 8px;
  color: #fff;
  display: flex;
  flex-direction: column;
  justify-content: center;
  overflow: hidden;
  padding: clamp(28px, 6vw, 54px);
  position: relative;
  text-align: left;
}

.login-copy h1 {
  font-size: clamp(34px, 6vw, 58px);
  line-height: 1;
  margin: 0 0 18px;
}

.login-copy p {
  color: rgba(255, 255, 255, 0.82);
  font-size: 18px;
  line-height: 1.55;
  margin: 0;
  max-width: 540px;
}

.card,
.info-panel,
.list-panel,
.empty-state,
.photo-card {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 8px;
  box-shadow: var(--shadow);
}

.login-card,
.card {
  display: grid;
  gap: 16px;
  padding: 22px;
}

.login-card {
  align-self: center;
}

label {
  color: #2c333a;
  display: grid;
  gap: 7px;
  font-weight: 700;
}

input,
select,
textarea {
  background: #fff;
  border: 1px solid #cfd6de;
  border-radius: 7px;
  color: var(--ink);
  min-height: 44px;
  padding: 10px 12px;
  width: 100%;
}

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

input:focus,
select:focus,
textarea:focus {
  border-color: var(--brand);
  box-shadow: 0 0 0 3px rgba(207, 32, 41, 0.14);
  outline: 0;
}

.primary-button,
.secondary-button,
.icon-button {
  align-items: center;
  border: 0;
  border-radius: 7px;
  cursor: pointer;
  display: inline-flex;
  font-weight: 800;
  gap: 8px;
  justify-content: center;
}

.primary-button {
  background: var(--brand);
  color: #fff;
  min-height: 46px;
  padding: 11px 16px;
}

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

.secondary-button {
  background: var(--steel-soft);
  border: 1px solid var(--line);
  color: var(--ink);
  min-height: 40px;
  padding: 9px 13px;
}

.icon-button {
  background: var(--steel-soft);
  color: var(--ink);
  height: 40px;
  width: 40px;
}

.danger {
  color: var(--danger);
}

.flash {
  align-items: center;
  border-radius: 8px;
  display: flex;
  gap: 10px;
  margin: 0 0 20px;
  padding: 12px 14px;
}

.flash.success {
  background: #e9f4eb;
  border: 1px solid #c9e2cf;
  color: var(--green);
}

.flash.error {
  background: var(--brand-soft);
  border: 1px solid #f0b8bc;
  color: var(--danger);
}

.rule-alert {
  align-items: flex-start;
  background: #fff8df;
  border: 1px solid #efd77d;
  border-radius: 8px;
  display: flex;
  gap: 10px;
  padding: 12px;
}

.rule-alert svg {
  color: var(--brand);
  flex: 0 0 auto;
  margin-top: 2px;
}

.rule-alert div {
  display: grid;
  gap: 4px;
}

.rule-alert span {
  color: #5f5362;
  line-height: 1.4;
}

.cnh-fields {
  border: 1px solid var(--line);
  border-radius: 8px;
  display: grid;
  gap: 14px;
  padding: 14px;
}

.section-head.compact {
  display: grid;
  gap: 3px;
}

.section-head.compact h2 {
  font-size: 16px;
  margin: 0;
}

.section-head.compact span,
.user-summary small {
  color: var(--muted);
  line-height: 1.4;
}

.page-title {
  align-items: end;
  display: flex;
  gap: 18px;
  justify-content: space-between;
  margin-bottom: 22px;
}

.page-title h1,
.section-head h2 {
  margin: 0;
}

.page-title p {
  color: var(--brand);
  font-weight: 800;
  letter-spacing: 0;
  margin: 0 0 4px;
  text-transform: uppercase;
}

.grid {
  display: grid;
  gap: 20px;
}

.two-columns {
  grid-template-columns: minmax(0, 1fr) minmax(290px, 380px);
}

.form-stack {
  display: grid;
  gap: 16px;
}

.dropzone {
  align-items: center;
  background: linear-gradient(180deg, #fff, #fafafa);
  border: 2px dashed #b9c0c7;
  border-radius: 8px;
  justify-items: center;
  min-height: 168px;
  padding: 24px;
  text-align: center;
}

.dropzone input,
.position-card input {
  height: 1px;
  opacity: 0;
  padding: 0;
  position: absolute;
  width: 1px;
}

.field-group {
  display: grid;
  gap: 12px;
}

.field-group p {
  color: var(--muted);
  line-height: 1.45;
  margin: 4px 0 0;
}

.close-checklist {
  border-top: 1px solid var(--line);
  padding-top: 14px;
}

.check-question {
  border: 1px solid var(--line);
  border-radius: 8px;
  display: grid;
  gap: 10px;
  margin: 0;
  padding: 12px;
}

.check-question legend {
  font-weight: 800;
  padding: 0 6px;
}

.check-question label {
  align-items: center;
  display: flex;
  flex-direction: row;
  font-weight: 700;
  gap: 8px;
}

.check-question input {
  min-height: auto;
  width: auto;
}

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

.position-card {
  align-items: start;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 8px;
  display: grid;
  gap: 8px;
  grid-template-columns: 24px minmax(0, 1fr) auto;
  min-height: 126px;
  padding: 14px;
  position: relative;
}

.position-card:active {
  transform: translateY(1px);
}

.position-card:hover {
  border-color: var(--brand);
  box-shadow: 0 0 0 3px rgba(207, 32, 41, 0.08);
}

.position-card svg {
  color: var(--brand);
}

.position-card span {
  font-weight: 900;
}

.position-card small {
  color: var(--muted);
  font-weight: 400;
  grid-column: 2 / 3;
  line-height: 1.35;
  overflow-wrap: anywhere;
}

.camera-button {
  align-items: center;
  background: var(--brand);
  border: 0;
  border-radius: 7px;
  color: #fff;
  cursor: pointer;
  display: inline-flex;
  grid-column: 3;
  grid-row: 1 / span 2;
  height: 42px;
  justify-content: center;
  width: 42px;
}

.camera-button:hover {
  background: var(--brand-dark);
}

.camera-extra {
  gap: 9px;
}

.position-preview {
  aspect-ratio: 4 / 3;
  border-radius: 6px;
  display: block;
  grid-column: 1 / -1;
  height: auto;
  object-fit: cover;
  width: 100%;
}

.selected-files {
  display: grid;
  gap: 8px;
}

.file-chip {
  align-items: center;
  background: #f7f8f9;
  border: 1px solid var(--line);
  border-radius: 7px;
  display: flex;
  gap: 10px;
  min-height: 38px;
  padding: 8px 10px;
}

.file-chip span {
  flex: 1;
  overflow-wrap: anywhere;
}

.camera-open {
  overflow: hidden;
}

.camera-modal {
  align-items: center;
  display: grid;
  inset: 0;
  justify-items: center;
  padding: 18px;
  position: fixed;
  z-index: 50;
}

.camera-modal.is-hidden {
  display: none;
}

.camera-backdrop {
  background: rgba(16, 21, 26, 0.78);
  inset: 0;
  position: absolute;
}

.camera-panel {
  background: var(--panel);
  border: 1px solid rgba(255, 255, 255, 0.22);
  border-radius: 8px;
  box-shadow: 0 24px 64px rgba(0, 0, 0, 0.34);
  display: grid;
  gap: 12px;
  max-width: 760px;
  overflow: hidden;
  padding: 12px;
  position: relative;
  width: min(100%, 760px);
}

.camera-head,
.camera-actions {
  align-items: center;
  display: flex;
  gap: 10px;
  justify-content: space-between;
}

.camera-video {
  aspect-ratio: 4 / 3;
  background: var(--steel);
  border-radius: 7px;
  display: block;
  object-fit: cover;
  width: 100%;
}

.check-row {
  align-items: center;
  display: flex;
  gap: 10px;
  font-weight: 700;
}

.check-row input {
  min-height: auto;
  width: auto;
}

.check-list {
  border: 1px solid var(--line);
  border-radius: 8px;
  display: grid;
  gap: 8px;
  max-height: 280px;
  overflow: auto;
  padding: 12px;
}

.is-hidden {
  display: none;
}

.info-panel {
  align-content: start;
  display: grid;
  gap: 18px;
  padding: 22px;
}

.info-panel h2 {
  margin: 0;
}

.info-panel p {
  color: var(--muted);
  line-height: 1.55;
  margin: 0;
}

.metric-row {
  align-items: center;
  border-top: 1px solid var(--line);
  display: flex;
  gap: 12px;
  padding-top: 18px;
}

.metric-row span {
  color: var(--brand);
  font-size: 38px;
  font-weight: 900;
}

.section-head {
  margin: 34px 0 14px;
}

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

.photo-card {
  overflow: hidden;
}

.photo-thumb {
  aspect-ratio: 4 / 3;
  background: var(--steel);
  display: block;
  overflow: hidden;
}

.photo-thumb img {
  display: block;
  height: 100%;
  object-fit: cover;
  width: 100%;
}

.photo-meta {
  display: grid;
  gap: 12px;
  padding: 14px;
}

.photo-title {
  align-items: start;
  display: flex;
  gap: 8px;
  justify-content: space-between;
}

.badge {
  border-radius: 999px;
  display: inline-flex;
  font-size: 12px;
  font-weight: 900;
  padding: 4px 8px;
  white-space: nowrap;
}

.badge-row {
  align-items: center;
  display: inline-flex;
  flex-wrap: wrap;
  gap: 6px;
  justify-content: flex-end;
}

.badge.problem {
  background: var(--brand-soft);
  color: var(--danger);
}

.badge.active {
  background: #e9f4eb;
  color: var(--green);
}

.badge.warning {
  background: #fff8df;
  color: #7a5c00;
}

.inspection-summary {
  background: #f7f8f9;
  border: 1px solid var(--line);
  border-radius: 8px;
  display: grid;
  gap: 6px;
  padding: 12px;
}

.inspection-summary .badge {
  justify-self: start;
}

.inspection-summary small {
  color: var(--muted);
}

.notice-panel {
  background: #fff8df;
  border: 1px solid #efd77d;
  border-radius: 8px;
  display: grid;
  gap: 14px;
  margin-bottom: 18px;
  padding: 16px;
}

.notice-title {
  align-items: flex-start;
  display: flex;
  gap: 10px;
}

.notice-title svg {
  color: var(--brand);
  flex: 0 0 auto;
  margin-top: 2px;
}

.notice-title div {
  display: grid;
  gap: 3px;
}

.notice-title span,
.notice-item span {
  color: var(--muted);
}

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

.notice-item {
  background: rgba(255, 255, 255, 0.72);
  border: 1px solid rgba(122, 92, 0, 0.18);
  border-radius: 8px;
  align-items: center;
  display: grid;
  gap: 10px;
  grid-template-columns: minmax(0, 1fr) minmax(260px, auto) auto;
  padding: 12px;
}

.notice-item > div {
  display: grid;
  gap: 4px;
}

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

.notice-item.compact {
  grid-template-columns: minmax(0, 1fr) minmax(300px, 1.2fr);
}

.claim-note {
  background: rgba(255, 255, 255, 0.72);
  border: 1px solid rgba(122, 92, 0, 0.14);
  border-radius: 7px;
  display: grid;
  gap: 5px;
  padding: 10px;
}

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

.inspection-row {
  align-items: center;
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 8px;
  box-shadow: var(--shadow);
  display: grid;
  gap: 14px;
  grid-template-columns: minmax(260px, 1fr) minmax(330px, 1.1fr) auto;
  padding: 14px;
}

.inspection-row > div:first-child {
  display: grid;
  gap: 5px;
}

.inspection-row > div:first-child .badge {
  justify-self: start;
}

.inspection-row > div:first-child span:last-child {
  color: var(--muted);
}

.inspection-row dl {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.inspection-row .claim-note,
.vehicle-check-photos,
.vehicle-review-form {
  grid-column: 1 / -1;
}

.inspection-row-actions {
  align-items: center;
  display: flex;
  gap: 8px;
  justify-content: flex-end;
}

.form-actions,
.vehicle-review-form {
  align-items: center;
  display: flex;
  gap: 10px;
}

.vehicle-review-form {
  align-items: end;
  border-top: 1px solid var(--line);
  padding-top: 12px;
}

.vehicle-review-form label {
  flex: 1;
}

.vehicle-check-photos {
  display: grid;
  gap: 10px;
  grid-template-columns: repeat(auto-fill, minmax(120px, 1fr));
}

.vehicle-check-photo {
  background: var(--steel-soft);
  border: 1px solid var(--line);
  border-radius: 7px;
  display: grid;
  gap: 6px;
  overflow: hidden;
}

.vehicle-check-photo img {
  aspect-ratio: 4 / 3;
  display: block;
  object-fit: cover;
  width: 100%;
}

.vehicle-check-photo span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 700;
  padding: 0 8px 8px;
}

.detail-summary {
  align-items: start;
  display: grid;
  gap: 14px;
  grid-template-columns: minmax(0, 1fr) auto;
  margin-bottom: 22px;
}

.detail-summary article {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 8px;
  box-shadow: var(--shadow);
  display: grid;
  gap: 14px;
  padding: 16px;
}

.detail-summary .badge {
  justify-self: start;
}

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

.qr-form p {
  color: var(--muted);
  line-height: 1.55;
  margin: 0;
}

.qr-panel {
  align-content: start;
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 8px;
  box-shadow: var(--shadow);
  display: grid;
  gap: 14px;
  justify-items: center;
  padding: 22px;
  text-align: center;
}

.qr-cut-card {
  aspect-ratio: 1 / 1;
  background: #fff;
  border: 2px dashed var(--ink);
  display: grid;
  gap: 12px;
  grid-template-rows: auto minmax(0, 1fr);
  justify-items: center;
  padding: 16px;
  width: min(100%, 360px);
}

.qr-owner {
  font-size: 18px;
  line-height: 1.2;
  max-width: 100%;
  overflow-wrap: anywhere;
}

.qr-code-box {
  align-items: center;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 8px;
  display: grid;
  height: 100%;
  justify-items: center;
  padding: 14px;
  width: 100%;
}

.qr-code-box img {
  display: block;
  height: auto;
  max-height: 100%;
  max-width: 100%;
  width: 100%;
}

.qr-panel strong {
  overflow-wrap: anywhere;
}

.qr-actions {
  align-items: center;
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  justify-content: center;
}

.claim-note small {
  color: var(--muted);
  font-weight: 800;
}

.claim-note p {
  line-height: 1.45;
  margin: 0;
}

.accident-fields {
  background: var(--brand-soft);
  border: 1px solid #f0b8bc;
  border-radius: 8px;
  display: grid;
  gap: 10px;
  padding: 12px;
}

.accident-fields.is-hidden {
  display: none;
}

.accident-fields small {
  color: var(--danger);
  line-height: 1.4;
}

.admin-close-modal {
  align-items: center;
  display: grid;
  inset: 0;
  justify-items: center;
  padding: 18px;
  position: fixed;
  z-index: 60;
}

.admin-close-modal.is-hidden {
  display: none;
}

.admin-close-backdrop {
  background: rgba(16, 21, 26, 0.78);
  inset: 0;
  position: absolute;
}

.admin-close-panel {
  background: var(--panel);
  border-radius: 8px;
  box-shadow: 0 24px 64px rgba(0, 0, 0, 0.34);
  display: grid;
  gap: 14px;
  max-width: 540px;
  padding: 18px;
  position: relative;
  width: min(100%, 540px);
}

.admin-close-panel p {
  background: #f7f8f9;
  border: 1px solid var(--line);
  border-radius: 7px;
  color: var(--muted);
  font-weight: 800;
  margin: 0;
  padding: 10px;
}

dl {
  display: grid;
  gap: 8px;
  margin: 0;
}

dt {
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
  text-transform: uppercase;
}

dd {
  margin: 2px 0 0;
  overflow-wrap: anywhere;
}

.problem-text {
  background: #fff8df;
  border: 1px solid #efd77d;
  border-radius: 7px;
  line-height: 1.45;
  margin: 0;
  padding: 10px;
}

.photo-actions {
  border-top: 1px solid var(--line);
  gap: 10px;
  justify-content: space-between;
  padding-top: 12px;
}

.photo-actions span {
  color: var(--muted);
  font-size: 13px;
}

.claim-form {
  border-top: 1px solid var(--line);
  display: grid;
  gap: 10px;
  padding-top: 12px;
}

.claim-form textarea {
  min-height: 82px;
}

.filter-form {
  gap: 10px;
}

.list-panel {
  align-content: start;
  display: grid;
  overflow: hidden;
}

.list-item {
  align-items: flex-start;
  border-bottom: 1px solid var(--line);
  display: flex;
  gap: 14px;
  justify-content: space-between;
  min-height: 74px;
  padding: 14px 16px;
}

.list-item:last-child {
  border-bottom: 0;
}

.list-item div {
  display: grid;
  gap: 3px;
}

.user-summary {
  min-width: 0;
}

.list-actions {
  align-items: center;
  display: flex !important;
  flex-wrap: wrap;
  gap: 8px;
  justify-content: flex-end;
}

.cancel-form {
  align-items: start;
}

.cancel-form p {
  color: var(--muted);
  line-height: 1.45;
  margin: 4px 0 0;
}

.empty-state {
  align-items: center;
  color: var(--muted);
  display: grid;
  gap: 10px;
  justify-items: center;
  padding: 36px;
}

svg {
  height: 18px;
  width: 18px;
}

.term-body {
  background: #e9ecef;
}

.term-page {
  margin: 0 auto;
  max-width: 900px;
  padding: 26px 16px;
}

.term-actions {
  align-items: center;
  display: flex;
  gap: 10px;
  justify-content: flex-end;
  margin-bottom: 16px;
}

.term-sheet {
  background: #fff;
  border: 1px solid var(--line);
  box-shadow: var(--shadow);
  color: #111;
  min-height: 1122px;
  padding: 70px 64px;
}

.term-sheet header {
  border-bottom: 2px solid var(--ink);
  margin-bottom: 34px;
  padding-bottom: 18px;
  text-align: center;
}

.term-logo {
  display: block;
  height: auto;
  margin: 0 auto 18px;
  max-height: 120px;
  max-width: 340px;
  object-fit: contain;
  width: auto;
}

.term-sheet h1 {
  font-size: 28px;
  margin: 0;
  text-transform: uppercase;
}

.term-sheet p {
  font-size: 18px;
  line-height: 1.75;
  margin: 0 0 22px;
  text-align: justify;
}

.term-date {
  margin-top: 42px !important;
}

.term-signature {
  margin: 110px auto 0;
  max-width: 520px;
  text-align: center;
}

.term-signature div {
  border-top: 1px solid #111;
  height: 1px;
  margin-bottom: 12px;
}

.term-signature strong,
.term-signature span {
  display: block;
}

.term-signature span {
  color: var(--muted);
  margin-top: 4px;
}

@media (max-width: 860px) {
  .topbar,
  .login-panel,
  .two-columns {
    grid-template-columns: 1fr;
  }

  .topbar {
    position: static;
  }

  .nav,
  .user-menu,
  .page-title,
  .filter-form {
    justify-content: start;
  }

  .nav,
  .page-title,
  .filter-form,
  .notice-item {
    align-items: stretch;
    flex-wrap: wrap;
  }

  .notice-item {
    grid-template-columns: 1fr;
  }

  .notice-item.compact,
  .inspection-row,
  .detail-summary {
    grid-template-columns: 1fr;
  }

  .inspection-row dl,
  .detail-summary dl {
    grid-template-columns: 1fr;
  }

  .form-actions,
  .vehicle-review-form {
    align-items: stretch;
    flex-direction: column;
  }

  .inspection-row-actions {
    justify-content: start;
  }

  .qr-panel {
    order: -1;
  }

  .notice-item .secondary-button {
    justify-self: start;
  }

  .list-actions {
    justify-content: flex-end;
  }

  .login-panel {
    min-height: auto;
  }

  .login-copy {
    min-height: 340px;
  }

  .info-panel {
    order: -1;
  }
}

@media (max-width: 520px) {
  body {
    font-size: 16px;
  }

  .layout,
  .login-layout {
    padding-left: 14px;
    padding-right: 14px;
  }

  .layout {
    padding-top: 18px;
  }

  .login-layout {
    padding-top: 14px;
  }

  .login-panel {
    gap: 14px;
  }

  .login-copy {
    min-height: 220px;
    padding: 26px 22px;
  }

  .login-copy h1 {
    font-size: 34px;
  }

  .login-copy p {
    font-size: 16px;
  }

  .card,
  .info-panel {
    padding: 16px;
  }

  .term-page {
    padding: 0;
  }

  .term-actions {
    padding: 12px;
  }

  .term-sheet {
    border: 0;
    box-shadow: none;
    min-height: auto;
    padding: 36px 22px;
  }

  input,
  select,
  textarea {
    font-size: 16px;
    min-height: 50px;
  }

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

  .secondary-button {
    min-height: 46px;
  }

  .upload-form .primary-button {
    bottom: 10px;
    box-shadow: 0 12px 28px rgba(16, 21, 26, 0.24);
    position: sticky;
    z-index: 5;
  }

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

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

  .position-card {
    align-items: center;
    grid-template-columns: 24px minmax(0, 1fr) 54px;
    min-height: 86px;
  }

  .position-card small {
    grid-column: 2;
  }

  .camera-button {
    height: 46px;
    width: 46px;
  }

  .position-preview {
    grid-column: 1 / -1;
    grid-row: auto;
    height: auto;
    width: 100%;
  }

  .dropzone {
    min-height: 118px;
    padding: 18px;
  }

  .camera-actions {
    align-items: stretch;
    flex-direction: column-reverse;
  }

  .camera-actions .secondary-button,
  .camera-actions .primary-button {
    width: 100%;
  }

  .rule-alert {
    padding: 12px;
  }

  .page-title {
    align-items: stretch;
    flex-direction: column;
  }

  .page-title h1 {
    font-size: 26px;
  }

  .topbar {
    gap: 12px;
    padding: 12px 14px;
  }

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

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

  .user-menu {
    justify-content: space-between;
  }
}

@media print {
  @page {
    margin: 18mm;
    size: A4 portrait;
  }

  body,
  .term-body {
    background: #fff;
  }

  .no-print {
    display: none !important;
  }

  .term-page {
    max-width: none;
    padding: 0;
  }

  .term-sheet {
    border: 0;
    box-shadow: none;
    min-height: auto;
    padding: 0;
  }

  .qr-panel,
  .qr-code-box {
    border: 0;
    box-shadow: none;
  }

  .topbar,
  .page-title,
  .qr-form,
  .qr-actions,
  .flash {
    display: none !important;
  }

  .layout {
    max-width: none;
    padding: 0;
  }

  .qr-panel {
    padding: 0;
  }

  .qr-cut-card {
    border: 2px dashed #000;
    width: 90mm;
  }
}
