/* Driver-only outer layout. Preserve field spacing, themes and navigation. */
body.driver-body {
  --driver-edge-left: env(safe-area-inset-left, 0px);
  --driver-edge-right: env(safe-area-inset-right, 0px);
  box-sizing: border-box;
  min-width: 0;
  margin-left: 0 !important;
  margin-right: 0 !important;
  padding-left: 0 !important;
  padding-right: 0 !important;
}

body.driver-body .page,
body.driver-body .driver-page,
body.driver-body .topbar-inner,
body.driver-body .driver-section-tabs {
  box-sizing: border-box;
  width: 100% !important;
  max-width: none !important;
  min-width: 0;
  margin-left: 0 !important;
  margin-right: 0 !important;
  padding-left: var(--driver-edge-left) !important;
  padding-right: var(--driver-edge-right) !important;
}

body.driver-body .topbar {
  box-sizing: border-box;
  padding-left: 0 !important;
  padding-right: 0 !important;
}

/* Apply the safe inset once when tabs are in normal document flow. */
body.driver-body:not(.driver-form-locked) .driver-page .driver-section-tabs {
  padding-left: 0 !important;
  padding-right: 0 !important;
}

body.driver-body .driver-login-panel,
body.driver-body .driver-page > .panel,
body.driver-body #tripForm {
  box-sizing: border-box;
  width: 100% !important;
  max-width: none !important;
  min-width: 0;
  margin-left: 0 !important;
  margin-right: 0 !important;
}

body.driver-body .driver-login-visual,
body.driver-body .driver-login-content,
body.driver-body .driver-login-inline-field,
body.driver-body #tripForm .panel-body,
body.driver-body #tripForm .grid,
body.driver-body #tripForm .field {
  box-sizing: border-box;
  min-width: 0;
}

body.driver-body .driver-login-content input:not([type="checkbox"]):not([type="radio"]):not([type="file"]):not([type="hidden"]),
body.driver-body #tripForm input:not([type="checkbox"]):not([type="radio"]):not([type="file"]):not([type="hidden"]),
body.driver-body #tripForm select,
body.driver-body #tripForm textarea {
  box-sizing: border-box;
  min-width: 0;
  max-width: 100%;
}
