/* BOAT Design System v1
   Central visual layer for the soft-launch UI. This file intentionally sits
   after legacy styles so panel logic and element placement remain untouched. */

:root {
  --boat-bg: #eef4fb;
  --boat-surface: rgba(255, 255, 255, 0.94);
  --boat-surface-strong: #ffffff;
  --boat-surface-soft: #f7fbff;
  --boat-ink: #0b1830;
  --boat-text: #25344f;
  --boat-muted: #687792;
  --boat-line: rgba(88, 115, 150, 0.2);
  --boat-line-strong: rgba(39, 67, 105, 0.28);
  --boat-primary: #0f62fe;
  --boat-primary-dark: #073a91;
  --boat-primary-soft: #e7f0ff;
  --boat-cyan: #13c2d8;
  --boat-green: #16a34a;
  --boat-amber: #d97706;
  --boat-red: #dc2626;
  --boat-radius: 14px;
  --boat-radius-sm: 9px;
  --boat-shadow: 0 18px 45px rgba(15, 35, 70, 0.12);
  --boat-shadow-sm: 0 8px 22px rgba(15, 35, 70, 0.09);
  --boat-focus: 0 0 0 3px rgba(15, 98, 254, 0.18);
  --boat-font: "Nunito Sans", "Inter", "Segoe UI", Arial, sans-serif;
  --boat-control-height: 40px;
  --boat-complete-bg: #dcfce7;
  --boat-complete-text: #166534;
  --boat-review-bg: #fef3c7;
  --boat-review-text: #92400e;
}

html,
body {
  background:
    radial-gradient(circle at 8% 10%, rgba(19, 194, 216, 0.12), transparent 32%),
    radial-gradient(circle at 96% 3%, rgba(15, 98, 254, 0.12), transparent 30%),
    var(--boat-bg);
  color: var(--boat-text);
  font-family: var(--boat-font);
}

button,
input,
select,
textarea {
  font-family: var(--boat-font);
}

button,
.secondary-button,
.danger-button,
.ghost-button,
.compact-action-button,
.compact-download-button {
  min-height: var(--boat-control-height);
  height: var(--boat-control-height);
  border-radius: 9px;
  border: 1px solid transparent;
  font-weight: 850;
  letter-spacing: 0;
  transition: transform 140ms ease, box-shadow 140ms ease, border-color 140ms ease, background 140ms ease;
}

button.field-help-button,
button.icon-button,
button.nav-item,
button.marketing-nav-item,
button.break-type-trigger {
  height: auto;
}

button:not(.field-help-button):not(.icon-button):not(.nav-item):not(.marketing-nav-item):not(.break-type-trigger),
.secondary-button {
  box-shadow: 0 8px 18px rgba(15, 98, 254, 0.12);
}

button:not(:disabled):hover,
.secondary-button:not(:disabled):hover,
.ghost-button:not(:disabled):hover {
  transform: translateY(-1px);
}

button:focus-visible,
input:focus,
select:focus,
textarea:focus {
  outline: none;
  box-shadow: var(--boat-focus);
  border-color: rgba(15, 98, 254, 0.58) !important;
}

input,
select,
textarea {
  min-height: var(--boat-control-height);
  border: 1px solid var(--boat-line-strong);
  border-radius: 9px;
  background: linear-gradient(180deg, #ffffff 0%, #f9fbff 100%);
  color: var(--boat-ink);
  font-size: 13px;
  font-weight: 700;
}

input:not([type="checkbox"]):not([type="radio"]),
select,
input[type="file"] {
  height: var(--boat-control-height);
}

.searchable-select-trigger,
.report-entity-trigger,
.break-type-trigger,
.standard-select,
.template-download-button,
.compact-download-button,
.admin-export-button {
  min-height: var(--boat-control-height) !important;
  height: var(--boat-control-height) !important;
  border-radius: 9px !important;
  border: 1px solid var(--boat-line-strong) !important;
  font-weight: 850 !important;
}

.searchable-select-trigger,
.report-entity-trigger,
.standard-select {
  background: linear-gradient(180deg, #ffffff 0%, #f9fbff 100%) !important;
  color: var(--boat-ink) !important;
  box-shadow: none !important;
}

.searchable-select-trigger::after,
.report-entity-trigger::after {
  content: "v";
  float: right;
  color: var(--boat-muted);
  font-size: 12px;
  line-height: 1.2;
}

.searchable-select-menu,
.report-entity-menu,
.break-type-menu,
.boat-entity-context-menu {
  z-index: 9998 !important;
  border: 1px solid var(--boat-line-strong) !important;
  border-radius: 12px !important;
  background: #ffffff !important;
  box-shadow: 0 18px 48px rgba(15, 23, 42, 0.18) !important;
}

.searchable-select-option,
.report-entity-option {
  min-height: 32px;
  border-radius: 8px;
  font-weight: 800;
}

.searchable-select-option:hover,
.report-entity-option:hover {
  background: var(--boat-primary-soft) !important;
  color: var(--boat-primary-dark) !important;
}

.status-chip,
.badge,
.pill,
.message.success,
.template-status-popover.success {
  border-radius: 999px;
}

.status-chip.complete,
.badge.complete,
.pill.complete,
.message.success {
  background: var(--boat-complete-bg) !important;
  color: var(--boat-complete-text) !important;
}

.status-chip.review,
.badge.review,
.pill.review {
  background: var(--boat-review-bg) !important;
  color: var(--boat-review-text) !important;
}

.file-drop-label,
label:has(input[type="file"]) {
  min-height: 40px;
}

textarea {
  min-height: 82px;
  line-height: 1.45;
}

button:disabled,
input:disabled,
select:disabled,
textarea:disabled,
input[readonly],
textarea[readonly],
.is-disabled,
.field-disabled,
.condition-disabled,
label:has(input:disabled),
label:has(select:disabled),
label:has(textarea:disabled) {
  cursor: not-allowed !important;
}

input:disabled,
select:disabled,
textarea:disabled,
input[readonly],
textarea[readonly],
.is-disabled input,
.is-disabled select,
.is-disabled textarea,
.field-disabled input,
.field-disabled select,
.field-disabled textarea,
.condition-disabled input,
.condition-disabled select,
.condition-disabled textarea {
  border-color: #d7dde8 !important;
  background: linear-gradient(180deg, #f1f5f9 0%, #e8edf4 100%) !important;
  color: #7b8798 !important;
  box-shadow: none !important;
}

button:disabled,
.secondary-button:disabled,
.danger-button:disabled,
.ghost-button:disabled,
.compact-action-button:disabled,
.compact-download-button:disabled {
  border-color: #d7dde8 !important;
  background: #e8edf4 !important;
  color: #7b8798 !important;
  box-shadow: none !important;
  transform: none !important;
}

label:has(input:disabled),
label:has(select:disabled),
label:has(textarea:disabled) {
  color: #7b8798 !important;
}

label {
  color: var(--boat-text);
  font-size: 12px;
  font-weight: 850;
}

.app-shell {
  height: 100vh;
  overflow: hidden;
  background:
    linear-gradient(135deg, rgba(5, 22, 50, 0.02), rgba(15, 98, 254, 0.04)),
    var(--boat-bg);
}

.sidebar {
  background:
    linear-gradient(180deg, #061328 0%, #0a2244 54%, #071a34 100%) !important;
  border-right: 1px solid rgba(255, 255, 255, 0.08);
  box-shadow: 16px 0 42px rgba(2, 8, 23, 0.18);
}

.sidebar-brand {
  min-height: 112px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
  background:
    linear-gradient(135deg, rgba(19, 194, 216, 0.16), transparent 50%),
    linear-gradient(180deg, rgba(255, 255, 255, 0.06), transparent);
}

.sidebar-logo-img {
  filter: drop-shadow(0 10px 18px rgba(0, 0, 0, 0.18));
}

.sidebar-nav {
  gap: 6px !important;
  padding: 18px 12px !important;
}

.nav-item {
  position: relative;
  min-height: 38px;
  border: 1px solid transparent !important;
  border-radius: 10px !important;
  color: rgba(226, 239, 255, 0.78) !important;
  background: transparent !important;
  font-size: 12px;
  font-weight: 850;
  text-align: left;
}

.nav-item:hover {
  background: rgba(255, 255, 255, 0.08) !important;
  color: #ffffff !important;
}

.nav-item.active {
  background: linear-gradient(135deg, rgba(15, 98, 254, 0.95), rgba(19, 194, 216, 0.68)) !important;
  color: #ffffff !important;
  border-color: rgba(255, 255, 255, 0.18) !important;
  box-shadow: 0 12px 24px rgba(15, 98, 254, 0.25);
}

.nav-item.active::before {
  content: "";
  position: absolute;
  left: -7px;
  top: 9px;
  bottom: 9px;
  width: 3px;
  border-radius: 999px;
  background: #67e8f9;
}

.nav-child {
  margin-left: 14px !important;
  padding-left: 18px !important;
  opacity: 0.92;
}

.nav-child::after {
  content: "";
  position: absolute;
  left: 8px;
  top: 50%;
  width: 6px;
  height: 1px;
  background: rgba(148, 213, 255, 0.44);
}

.nav-group-label {
  margin: 12px 8px 2px;
  color: rgba(148, 213, 255, 0.72);
  font-size: 10px;
  font-weight: 950;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.sidebar-footer {
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  background: rgba(0, 0, 0, 0.12);
}

.workspace {
  min-width: 0;
  overflow: hidden;
  background: var(--boat-bg);
}

.workspace-header {
  box-sizing: border-box;
  width: 100%;
  min-height: 92px;
  padding: 18px 22px !important;
  display: flex !important;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  border-bottom: 1px solid var(--boat-line);
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.98), rgba(247, 251, 255, 0.94));
  backdrop-filter: blur(14px);
}

.workspace-header > div:first-child {
  min-width: 0;
  flex: 1 1 auto;
}

.workspace-header h2 {
  color: var(--boat-ink);
  font-size: 22px;
  font-weight: 950;
  letter-spacing: 0;
  margin: 4px 0 0 !important;
}

.workspace-header p:not(.eyebrow) {
  color: var(--boat-muted);
  font-weight: 750;
  max-width: none !important;
  margin: 4px 0 0 !important;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.workspace-status {
  flex: 0 0 auto;
  min-width: 160px;
  border: 1px solid var(--boat-line);
  border-radius: 12px;
  background: #ffffff;
  box-shadow: var(--boat-shadow-sm);
}

.workspace-status span {
  color: var(--boat-muted);
  font-size: 10px;
  font-weight: 950;
  letter-spacing: 0.12em;
}

.workspace-status strong {
  color: var(--boat-primary-dark);
}

.rdp-clean-panel {
  overflow: visible !important;
}

.rdp-clean-panel .panel-note {
  display: block !important;
  width: 100% !important;
  max-width: none !important;
  margin: 8px 0 0 !important;
  padding: 9px 12px !important;
  border: 1px solid #dbe7f3 !important;
  border-radius: 10px !important;
  background: #f5f7fb !important;
  color: #1f2937 !important;
  font-weight: 800 !important;
  white-space: normal !important;
  overflow: visible !important;
  text-overflow: clip !important;
}

#rdpConfigForm.rdp-clean-form {
  display: grid !important;
  grid-template-columns: 190px 210px minmax(260px, 1fr) 160px 190px 142px 148px !important;
  grid-auto-flow: row !important;
  align-items: end !important;
  justify-content: start !important;
  justify-items: stretch !important;
  column-gap: 10px !important;
  row-gap: 10px !important;
  width: 100% !important;
  max-width: 100% !important;
  margin: 12px 0 0 !important;
  padding: 0 !important;
  overflow: visible !important;
}

#rdpConfigForm.rdp-clean-form > label {
  width: 100% !important;
  max-width: none !important;
  min-width: 0 !important;
  margin: 0 !important;
  justify-self: stretch !important;
}

#rdpConfigForm.rdp-clean-form label:has(#rdpEntitySelect) {
  grid-column: 1 !important;
  grid-row: 2 !important;
}

#rdpConfigForm.rdp-clean-form label:has(#rdpConnectionTypeSelect) {
  grid-column: 1 !important;
  grid-row: 1 !important;
}

#rdpConfigForm.rdp-clean-form label:has(#rdpAddressInput) {
  grid-column: 2 / 6 !important;
  grid-row: 1 !important;
}

#rdpConfigForm.rdp-clean-form label:has(#rdpUsernameInput) {
  grid-column: 2 / 4 !important;
  grid-row: 2 !important;
}

#rdpConfigForm.rdp-clean-form label:has(#rdpPasswordInput) {
  grid-column: 4 / 6 !important;
  grid-row: 2 !important;
}

#rdpConfigForm.rdp-clean-form #testRdpButton {
  grid-column: 6 !important;
  grid-row: 2 !important;
}

#rdpConfigForm.rdp-clean-form button[type="submit"] {
  grid-column: 7 !important;
  grid-row: 2 !important;
}

#rdpConfigForm.rdp-clean-form button[type="submit"],
#rdpConfigForm.rdp-clean-form #testRdpButton {
  width: 100% !important;
  min-width: 0 !important;
  height: var(--boat-control-height, 38px) !important;
  margin: 0 !important;
  padding-inline: 10px !important;
  justify-self: stretch !important;
  white-space: nowrap !important;
}

#rdpConfigForm.rdp-clean-form #rdpMessage {
  grid-column: 1 / -1 !important;
  grid-row: 3 !important;
}

#emailSettingsForm {
  grid-template-columns: minmax(170px, 220px) minmax(180px, 240px) 100px minmax(180px, 240px) minmax(180px, 240px) max-content 126px !important;
  align-items: end !important;
  column-gap: 7px !important;
  row-gap: 4px !important;
}

#emailSettingsForm .smtp-security-group {
  display: inline-flex !important;
  align-items: center !important;
  justify-content: flex-start !important;
  gap: 10px !important;
  width: auto !important;
  height: 40px !important;
  min-height: 40px !important;
  margin: 0 !important;
  padding: 0 !important;
  white-space: nowrap !important;
}

#emailSettingsForm .smtp-security-group label {
  display: inline-flex !important;
  align-items: center !important;
  gap: 5px !important;
  margin: 0 !important;
  white-space: nowrap !important;
}

#emailSettingsForm .smtp-security-group input {
  width: 14px !important;
  height: 14px !important;
  min-height: 14px !important;
}

#emailSettingsForm button[type="submit"] {
  width: 126px !important;
  min-width: 126px !important;
  justify-self: start !important;
  margin-left: 10px !important;
  white-space: nowrap !important;
}

#emailSettingsForm #emailSettingsMessage {
  grid-column: 1 / -1 !important;
}

.view-control-form .access-control-table-wrap {
  max-height: none !important;
  overflow: visible !important;
}

.view-control-form .access-control-table {
  min-width: 0 !important;
  width: 100% !important;
}

#boatHelpWidget,
.boat-help-widget {
  width: 24px !important;
  height: 24px !important;
  z-index: 2147482500 !important;
}

#boatHelpFab,
.boat-help-fab {
  width: 24px !important;
  min-width: 24px !important;
  max-width: 24px !important;
  height: 24px !important;
  min-height: 24px !important;
  max-height: 24px !important;
  aspect-ratio: 1 / 1 !important;
  padding: 0 !important;
  border-radius: 50% !important;
  font-size: 12px !important;
  line-height: 1 !important;
  transform: none !important;
}

#boatHelpPanel,
.boat-help-panel {
  top: 32px !important;
  z-index: 2147482600 !important;
}

.workspace-view {
  gap: 14px !important;
  padding: 14px !important;
  overflow: auto;
}

.execution-panel,
.dashboard-grid article,
.entity-row,
.manual-volume-upload-card,
.use-my-volume-box,
.about-story-card,
.marketing-async-card {
  border: 1px solid var(--boat-line) !important;
  border-radius: var(--boat-radius) !important;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.98), rgba(249, 252, 255, 0.96)) !important;
  box-shadow: var(--boat-shadow-sm);
}

.execution-panel {
  padding: 14px !important;
}

.execution-panel:hover,
.dashboard-grid article:hover {
  border-color: rgba(15, 98, 254, 0.26) !important;
}

.section-title {
  align-items: start;
  gap: 10px;
  padding-bottom: 10px;
  margin-bottom: 10px;
  border-bottom: 1px solid rgba(88, 115, 150, 0.14);
}

.eyebrow,
.section-title .eyebrow,
.panel-copy .eyebrow {
  color: var(--boat-primary) !important;
  font-size: 10px !important;
  font-weight: 950 !important;
  letter-spacing: 0.12em !important;
}

.section-title h2,
.section-title h3 {
  color: var(--boat-ink) !important;
  font-size: 17px !important;
  font-weight: 950 !important;
  letter-spacing: 0 !important;
}

.entity-form,
.auth-form,
.settings-form,
.compact-form,
.export-form {
  gap: 10px !important;
}

.entity-form label,
.auth-form label,
.settings-form label,
.compact-form label,
.export-form label {
  gap: 5px;
}

.table-wrap {
  border: 1px solid var(--boat-line);
  border-radius: 12px;
  background: #ffffff;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.8);
}

.data-table {
  border-collapse: separate !important;
  border-spacing: 0 !important;
  color: var(--boat-text);
}

.data-table th {
  position: sticky;
  top: 0;
  z-index: 2;
  background: linear-gradient(180deg, #0b3a78, #0a2e61) !important;
  color: #ffffff !important;
  border-bottom: 1px solid rgba(255, 255, 255, 0.12) !important;
  font-size: 11px !important;
  font-weight: 950 !important;
  letter-spacing: 0.02em;
}

.data-table td {
  border-bottom: 1px solid rgba(88, 115, 150, 0.14) !important;
  color: var(--boat-text);
  font-size: 12px !important;
  font-weight: 700;
}

.data-table tbody tr:nth-child(even) td {
  background: rgba(247, 251, 255, 0.72);
}

.data-table tbody tr:hover td {
  background: #edf6ff !important;
}

.field-help-button {
  width: 15px !important;
  height: 15px !important;
  min-height: 15px !important;
  padding: 0 !important;
  border-radius: 999px !important;
  border: 1px solid #bfdbfe !important;
  background: #eff6ff !important;
  color: #0f62fe !important;
  box-shadow: none !important;
  font-size: 10px !important;
  font-weight: 950 !important;
  line-height: 1 !important;
  vertical-align: middle;
  transform: none !important;
}

.action-toast {
  right: 22px !important;
  bottom: 22px !important;
  top: auto !important;
  border-radius: 14px !important;
  border: 1px solid rgba(34, 197, 94, 0.28) !important;
  background: linear-gradient(180deg, #ecfdf5, #ffffff) !important;
  color: #064e3b !important;
  box-shadow: 0 24px 70px rgba(15, 23, 42, 0.18) !important;
}

.action-toast.failed {
  border-color: rgba(220, 38, 38, 0.28) !important;
  background: linear-gradient(180deg, #fef2f2, #ffffff) !important;
  color: #7f1d1d !important;
}

.modal,
.boat-upload-map-overlay,
.attendance-modal-overlay,
.app-confirm-overlay {
  backdrop-filter: blur(6px);
}

.boat-upload-map-card,
.app-confirm-card,
.attendance-modal-card {
  border-radius: 18px !important;
  border: 1px solid rgba(148, 163, 184, 0.32) !important;
  box-shadow: 0 30px 86px rgba(15, 23, 42, 0.28) !important;
}

/* Marketing refresh */
.marketing-shell {
  background:
    radial-gradient(circle at 18% 12%, rgba(19, 194, 216, 0.16), transparent 30%),
    linear-gradient(135deg, #f7fbff 0%, #eef6ff 58%, #e8f1ff 100%) !important;
}

.marketing-sidebar {
  border-right: 1px solid rgba(88, 115, 150, 0.16) !important;
  box-shadow: 16px 0 50px rgba(15, 35, 70, 0.08);
}

.marketing-nav-item {
  border-radius: 11px !important;
  font-weight: 900 !important;
}

.marketing-nav-item.active {
  background: linear-gradient(135deg, #0f62fe, #13c2d8) !important;
  color: #ffffff !important;
  box-shadow: 0 14px 28px rgba(15, 98, 254, 0.22);
}

.marketing-topbar {
  border-bottom: 1px solid rgba(88, 115, 150, 0.16) !important;
  background: rgba(255, 255, 255, 0.72) !important;
  backdrop-filter: blur(14px);
}

.panel-copy h1,
.panel-copy h2 {
  color: var(--boat-ink) !important;
  font-weight: 950 !important;
  letter-spacing: 0 !important;
  max-width: 820px;
  margin-bottom: 14px !important;
  line-height: 0.98 !important;
  text-wrap: balance;
  background: linear-gradient(135deg, #061328 0%, #0f3f82 54%, #0f62fe 100%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent !important;
}

.panel-copy h1 {
  font-size: 44px !important;
}

.panel-copy h2 {
  font-size: 36px !important;
}

.panel-copy p {
  position: relative;
  max-width: 760px;
  margin-top: 0 !important;
  padding-left: 16px;
  color: #3f526f !important;
  font-size: 16px;
  font-weight: 760;
  line-height: 1.5;
}

.panel-copy > p:not(.eyebrow)::before {
  content: "";
  position: absolute;
  left: 0;
  top: 5px;
  bottom: 5px;
  width: 4px;
  border-radius: 999px;
  background: linear-gradient(180deg, var(--boat-primary), var(--boat-cyan));
}

.panel-copy .eyebrow {
  display: inline-flex;
  align-items: center;
  width: fit-content;
  min-height: 24px;
  margin-bottom: 12px !important;
  padding: 4px 10px;
  border: 1px solid rgba(15, 98, 254, 0.15);
  border-radius: 999px;
  background: rgba(231, 240, 255, 0.86);
  box-shadow: 0 8px 20px rgba(15, 98, 254, 0.08);
}

.marketing-proof-points {
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(0, 0.95fr);
  gap: 9px;
  max-width: 760px;
  margin: 20px 0 0;
  padding: 0;
  list-style: none;
}

.marketing-proof-points li {
  position: relative;
  padding: 8px 12px 8px 34px;
  border: 1px solid rgba(15, 98, 254, 0.14);
  border-radius: 11px;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.82), rgba(239, 246, 255, 0.72));
  color: #233653;
  font-size: 13px;
  font-weight: 850;
  line-height: 1.3;
  box-shadow: 0 8px 20px rgba(15, 35, 70, 0.06);
}

.marketing-proof-points li:first-child {
  grid-column: 1 / -1;
  padding-top: 11px;
  padding-bottom: 11px;
  border-color: rgba(15, 98, 254, 0.24);
  background: linear-gradient(135deg, rgba(231, 240, 255, 0.96), rgba(236, 253, 255, 0.84));
  color: #0f2f5f;
  font-size: 15px;
}

.marketing-proof-points li:nth-child(2),
.marketing-proof-points li:nth-child(3) {
  font-size: 12px;
}

.marketing-proof-points li::before {
  content: "";
  position: absolute;
  left: 12px;
  top: 50%;
  width: 10px;
  height: 10px;
  border-radius: 999px;
  background: linear-gradient(135deg, var(--boat-primary), var(--boat-cyan));
  box-shadow: 0 0 0 4px rgba(15, 98, 254, 0.1);
  transform: translateY(-50%);
}

.marketing-proof-points li:first-child::before {
  width: 12px;
  height: 12px;
}

#heroPanel .panel-copy h1,
#pricingPanel .panel-copy h2 {
  font-size: 46px !important;
}

#aiPanel .panel-copy h2,
#insightsPanel .panel-copy h2 {
  max-width: 780px;
}

.hero-dashboard-preview,
.module-visual,
.pricing-launch-image,
.about-story-card,
.faq-answer-panel,
.contact-card,
.demo-form-card {
  border: 1px solid rgba(88, 115, 150, 0.18) !important;
  border-radius: 18px !important;
  background: rgba(255, 255, 255, 0.74) !important;
  box-shadow: var(--boat-shadow);
}

.marketing-flow-image,
.kpi-flow-image,
.hero-dashboard-preview img {
  border-radius: 14px;
}

/* LMS assessment engine: keep the control set readable in two rows. */
#lmsConfigForm {
  display: grid !important;
  grid-template-columns: minmax(180px, 210px) minmax(220px, 270px) minmax(130px, 150px) minmax(120px, 140px) 142px !important;
  column-gap: 14px !important;
  row-gap: 10px !important;
  align-items: end !important;
  justify-content: start !important;
}

#lmsConfigForm label,
#lmsConfigForm .searchable-select {
  width: 100% !important;
  max-width: none !important;
  min-width: 0 !important;
}

#lmsConfigForm label:nth-of-type(1) {
  grid-column: 1 !important;
  grid-row: 1 !important;
}

#lmsConfigForm label:nth-of-type(2) {
  grid-column: 2 !important;
  grid-row: 1 !important;
}

#lmsConfigForm label:nth-of-type(3) {
  grid-column: 3 !important;
  grid-row: 1 !important;
}

#lmsConfigForm label:nth-of-type(4) {
  grid-column: 4 !important;
  grid-row: 1 !important;
}

#lmsConfigForm label:nth-of-type(5) {
  grid-column: 1 !important;
  grid-row: 2 !important;
}

#lmsConfigForm label:nth-of-type(6) {
  grid-column: 2 !important;
  grid-row: 2 !important;
}

#lmsConfigForm label:nth-of-type(7) {
  grid-column: 3 !important;
  grid-row: 2 !important;
}

#lmsConfigForm button[type="submit"] {
  grid-column: 4 !important;
  grid-row: 2 !important;
  min-width: 142px !important;
  width: 142px !important;
}

#lmsConfigForm #generateLmsButton {
  grid-column: 5 !important;
  grid-row: 2 !important;
  min-width: 142px !important;
  width: 142px !important;
  margin-top: 0 !important;
}

#lmsConfigForm .message {
  grid-column: 1 / -1 !important;
  grid-row: 3 !important;
  min-height: 0 !important;
}

/* Admin > Entity Configuration: Capacity controls need breathing room. */
.entity-config-capacity-box .entity-config-capacity-row {
  display: grid !important;
  grid-template-columns: minmax(170px, 190px) minmax(170px, 190px) minmax(170px, 190px) !important;
  column-gap: 18px !important;
  row-gap: 8px !important;
  align-items: end !important;
  justify-content: start !important;
}

.entity-config-capacity-box .entity-config-capacity-row label {
  min-width: 0 !important;
  width: 100% !important;
  max-width: none !important;
}

.entity-config-capacity-box #workingDaysInput,
.entity-config-capacity-box #productiveMinutesInput,
.entity-config-capacity-box #otPercentageInput {
  width: 100% !important;
  min-width: 0 !important;
}

/* Admin > Entity Configuration: Fetch Family controls should not collide. */
.entity-config-fetch-family .entity-config-fetch-row {
  display: grid !important;
  grid-template-columns: minmax(180px, 200px) minmax(190px, 220px) minmax(190px, 220px) minmax(190px, 220px) 40px !important;
  column-gap: 16px !important;
  row-gap: 10px !important;
  align-items: end !important;
  justify-content: start !important;
}

.entity-config-fetch-family .entity-config-fetch-row label {
  min-width: 0 !important;
  width: 100% !important;
  max-width: none !important;
}

.entity-config-fetch-family .entity-config-fetch-row label:nth-of-type(1) {
  grid-column: 1 !important;
}

.entity-config-fetch-family .entity-config-fetch-row label:nth-of-type(2) {
  grid-column: 2 !important;
}

.entity-config-fetch-family .entity-config-fetch-row label:nth-of-type(3) {
  grid-column: 3 !important;
}

.entity-config-fetch-family .entity-config-fetch-row label:nth-of-type(4) {
  grid-column: 4 !important;
}

.entity-config-fetch-family .entity-config-extra-fetch:not(.hidden):nth-of-type(5) {
  grid-column: 1 !important;
  grid-row: 2 !important;
}

.entity-config-fetch-family .entity-config-extra-fetch:not(.hidden):nth-of-type(6) {
  grid-column: 2 !important;
  grid-row: 2 !important;
}

.entity-config-fetch-family #addFetchConventionButton {
  grid-column: 5 !important;
  width: 40px !important;
  min-width: 40px !important;
  padding-inline: 0 !important;
}

.entity-config-fetch-family #fetchDaysBehindInput,
.entity-config-fetch-family .fetch-convention-input {
  width: 100% !important;
  min-width: 0 !important;
}

/* Admin cleanup: remove empty View & Access local lockbar and keep fields compact. */
.view-access-panel .view-access-lockbar {
  display: none !important;
  padding: 0 !important;
  border: 0 !important;
  background: transparent !important;
  box-shadow: none !important;
}

.access-control-table .inline-field {
  display: inline-flex !important;
  align-items: center !important;
  gap: 8px !important;
  white-space: nowrap !important;
  width: auto !important;
}

.access-control-table .inline-field input {
  width: 68px !important;
  min-width: 68px !important;
}

.access-control-table .volume-variance-fields {
  display: inline-flex !important;
  flex-wrap: nowrap !important;
  align-items: center !important;
  gap: 10px !important;
  white-space: nowrap !important;
}

/* Admin > People: disposition controls should read left-to-right inside each card. */
#editorPicklistForm .disposition-scope-row.disposition-entity-row {
  grid-template-columns: 116px 118px minmax(0, 1fr) !important;
  column-gap: 6px !important;
  row-gap: 6px !important;
  align-items: end !important;
}

#editorPicklistForm .disposition-scope-row.disposition-entity-row > div:first-child {
  grid-column: 1 / -1 !important;
}

#editorPicklistForm .disposition-scope-row.disposition-entity-row > label {
  grid-column: 1 !important;
  width: 116px !important;
  max-width: 116px !important;
}

#editorPicklistForm .disposition-scope-row.disposition-entity-row > button {
  grid-column: 2 !important;
  width: 118px !important;
  min-width: 118px !important;
  justify-self: start !important;
}

#editorPicklistForm .disposition-scope-row:not(.disposition-entity-row):not(.disposition-download-row) {
  grid-template-columns: minmax(230px, 1fr) 116px 118px !important;
  column-gap: 8px !important;
  row-gap: 6px !important;
  align-items: end !important;
}

#editorPicklistForm .disposition-scope-row:not(.disposition-entity-row):not(.disposition-download-row) > div:first-child {
  grid-column: 1 / -1 !important;
}

#editorPicklistForm .disposition-scope-row:not(.disposition-entity-row):not(.disposition-download-row) > label:first-of-type {
  grid-column: 1 !important;
  width: 100% !important;
}

#editorPicklistForm .disposition-scope-row:not(.disposition-entity-row):not(.disposition-download-row) > label:nth-of-type(2) {
  grid-column: 2 !important;
  width: 116px !important;
  max-width: 116px !important;
}

#editorPicklistForm .disposition-scope-row:not(.disposition-entity-row):not(.disposition-download-row) > button {
  grid-column: 3 !important;
  width: 118px !important;
  min-width: 118px !important;
  justify-self: start !important;
}

#editorPicklistForm #editorPicklistEntityCountInput,
#editorPicklistForm #editorPicklistProcedureCountInput {
  width: 100% !important;
  min-width: 0 !important;
}

/* Admin > Dailies: Outgoing email settings is rebuilt into two clean rows. */
.boat-email-settings-clean-panel {
  overflow: visible !important;
}

#emailSettingsForm.boat-email-settings-clean-form {
  display: grid !important;
  grid-template-columns: 220px 240px 104px 184px 126px !important;
  column-gap: 10px !important;
  row-gap: 8px !important;
  align-items: end !important;
  justify-content: start !important;
  justify-items: start !important;
  width: max-content !important;
  max-width: 100% !important;
  margin-inline: 0 auto !important;
}

#emailSettingsForm.boat-email-settings-clean-form > label,
#emailSettingsForm.boat-email-settings-clean-form .smtp-security-group,
#emailSettingsForm.boat-email-settings-clean-form button {
  justify-self: start !important;
}

#emailSettingsForm.boat-email-settings-clean-form .boat-email-from-field {
  grid-column: 1 !important;
  grid-row: 1 !important;
}

#emailSettingsForm.boat-email-settings-clean-form .boat-email-host-field {
  grid-column: 2 !important;
  grid-row: 1 !important;
}

#emailSettingsForm.boat-email-settings-clean-form .boat-email-port-field {
  grid-column: 3 !important;
  grid-row: 1 !important;
}

#emailSettingsForm.boat-email-settings-clean-form .boat-email-user-field {
  grid-column: 1 !important;
  grid-row: 2 !important;
}

#emailSettingsForm.boat-email-settings-clean-form .boat-email-pass-field {
  grid-column: 2 !important;
  grid-row: 2 !important;
}

#emailSettingsForm.boat-email-settings-clean-form .boat-email-security-field {
  grid-column: 3 / 5 !important;
  grid-row: 2 !important;
  display: inline-flex !important;
  align-items: center !important;
  gap: 10px !important;
  align-self: end !important;
  margin: 0 !important;
  padding-bottom: 2px !important;
  white-space: nowrap !important;
}

#emailSettingsForm.boat-email-settings-clean-form .boat-email-security-field label {
  display: inline-flex !important;
  align-items: center !important;
  gap: 5px !important;
  margin: 0 !important;
  white-space: nowrap !important;
}

#emailSettingsForm.boat-email-settings-clean-form .boat-email-save-button {
  grid-column: 5 !important;
  grid-row: 2 !important;
  width: 126px !important;
  min-width: 126px !important;
  margin: 0 !important;
  align-self: end !important;
}

#emailSettingsForm.boat-email-settings-clean-form .boat-email-message-field {
  grid-column: 1 / -1 !important;
  grid-row: 3 !important;
}

/* Hide empty generated boxes after controls are intentionally removed. */
.entity-config-form > .entity-config-selector,
.entity-config-form .entity-config-relocation-staging.hidden:empty {
  display: none !important;
  padding: 0 !important;
  border: 0 !important;
  background: transparent !important;
  box-shadow: none !important;
}

@media (max-width: 980px) {
  .app-shell {
    grid-template-columns: 84px 1fr !important;
  }

  .nav-item {
    font-size: 11px;
  }

  .workspace-view {
    padding: 10px !important;
  }

  .panel-copy h1 {
    font-size: 34px !important;
  }

  .panel-copy h2 {
    font-size: 30px !important;
  }

  .marketing-proof-points {
    grid-template-columns: 1fr;
  }

  .marketing-proof-points li:first-child {
    grid-column: auto;
  }
}
