/* Focused foreman and laborer home workspace. Loaded last to stay isolated from legacy home themes. */
html body#strongholdApp:not(.login-active) #homeFeed:has(.field-home-dashboard) {
  max-width: none;
  padding: 16px 18px 28px;
  background: #e7eef0;
}

.field-home-dashboard {
  width: min(1180px, 100%);
  margin: 0 auto;
  color: #17313a;
}

.field-home-dashboard button,
.field-home-dashboard select {
  font: inherit;
  letter-spacing: 0;
}

.field-home-hero {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  min-height: 132px;
  padding: 24px 28px;
  border: 1px solid #c3d2d7;
  border-left: 6px solid #2c7a68;
  border-radius: 8px;
  background: linear-gradient(100deg, #f9fbfb 0%, #eef4f4 67%, #e2edeb 100%);
  box-shadow: 0 10px 24px rgba(27, 54, 64, .09);
}

.field-home-identity {
  display: flex;
  align-items: center;
  gap: 18px;
  min-width: 0;
}

.field-home-avatar {
  display: grid;
  flex: 0 0 64px;
  width: 64px;
  height: 64px;
  place-items: center;
  border-radius: 50%;
  color: #fff;
  background: #173f4a;
  box-shadow: inset 0 0 0 5px rgba(255, 255, 255, .16);
  font-family: var(--display-font, inherit);
  font-size: 30px;
  font-weight: 800;
}

.field-home-avatar.employee-profile-photo-frame,
.field-crew-avatar.employee-profile-photo-frame {
  overflow: hidden;
  padding: 0;
}

.field-home-avatar.employee-profile-photo-frame > img,
.field-crew-avatar.employee-profile-photo-frame > img {
  width: 100%;
  height: 100%;
}

.field-home-identity p,
.field-home-identity h2,
.field-home-identity span,
.field-home-section-head p,
.field-home-section-head h3 {
  margin: 0;
}

.field-home-identity p {
  margin-bottom: 3px;
  color: #667b83;
  font-size: 13px;
  font-weight: 700;
}

.field-home-identity h2 {
  color: #122d36;
  font-size: clamp(25px, 3vw, 37px);
  line-height: 1.08;
}

.field-home-identity > div > span {
  display: block;
  margin-top: 6px;
  color: #506870;
  font-size: 14px;
}

.field-home-hero-side {
  display: flex;
  align-items: center;
  gap: 18px;
}

.field-role-badge,
.field-role-select {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-height: 38px;
  padding: 7px 11px;
  border: 1px solid #b9cbd0;
  border-radius: 6px;
  color: #29444d;
  background: rgba(255, 255, 255, .78);
  font-size: 12px;
  font-weight: 800;
}

.field-role-badge img {
  width: 18px;
  height: 18px;
}

.field-role-select select {
  min-width: 116px;
  height: 30px;
  margin-left: 4px;
  border: 0;
  color: #17313a;
  background: transparent;
  font-weight: 800;
}

.field-home-counts {
  display: flex;
  gap: 8px;
}

.field-home-counts span {
  display: grid;
  min-width: 82px;
  padding: 8px 12px;
  border: 1px solid #c3d3d6;
  border-radius: 6px;
  background: rgba(255, 255, 255, .72);
  text-align: center;
}

.field-home-counts strong {
  color: #183943;
  font-size: 22px;
  line-height: 1.2;
}

.field-home-counts small {
  margin-top: 4px;
  color: #63777d;
  font-size: 10px;
  font-weight: 800;
  text-transform: uppercase;
}

.field-home-layout {
  display: grid;
  grid-template-columns: minmax(0, 1.75fr) minmax(300px, .8fr);
  gap: 16px;
  margin-top: 16px;
  align-items: start;
}

.field-home-main,
.field-home-sidebar {
  display: grid;
  gap: 16px;
  min-width: 0;
}

.field-home-section {
  min-width: 0;
  padding: 18px;
  border: 1px solid #c7d4d8;
  border-radius: 8px;
  background: #f8fafb;
  box-shadow: 0 7px 18px rgba(26, 51, 61, .07);
}

.field-home-section-head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 14px;
  margin-bottom: 14px;
}

.field-home-section-head .eyebrow {
  color: #627780;
  font-size: 10px;
  font-weight: 900;
  text-transform: uppercase;
}

.field-home-section-head h3 {
  margin-top: 2px;
  color: #17313a;
  font-size: 20px;
}

.field-home-section-head > span {
  padding: 5px 9px;
  border-radius: 999px;
  color: #526a72;
  background: #e9eff1;
  font-size: 11px;
  font-weight: 800;
}

.field-job-list,
.field-task-list {
  display: grid;
  gap: 10px;
}

.field-job-card {
  --field-tone: #5e7680;
  display: grid;
  grid-template-columns: 40px minmax(0, 1fr) auto;
  gap: 14px;
  align-items: center;
  min-height: 116px;
  padding: 14px;
  border: 1px solid #ccd7da;
  border-left: 4px solid var(--field-tone);
  border-radius: 7px;
  background: #fff;
}

.field-job-card.tone-production { --field-tone: #3f78b3; }
.field-job-card.tone-service { --field-tone: #c77b25; }
.field-job-card.tone-inspection { --field-tone: #4a8b78; }
.field-job-card.tone-prebid { --field-tone: #7a7f91; }
.field-job-card.is-live { box-shadow: 0 5px 16px rgba(39, 74, 85, .1); }

.field-job-order {
  display: grid;
  width: 36px;
  height: 36px;
  place-items: center;
  border-radius: 50%;
  color: #fff;
  background: var(--field-tone);
  font-size: 14px;
  font-weight: 900;
}

.field-job-copy {
  min-width: 0;
}

.field-job-labels {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-bottom: 5px;
}

.field-job-labels span {
  padding: 3px 7px;
  border-radius: 999px;
  color: #52686f;
  background: #edf2f3;
  font-size: 9px;
  font-weight: 900;
  text-transform: uppercase;
}

.field-job-labels .field-job-state {
  color: #fff;
  background: var(--field-tone);
}

.field-job-copy > strong {
  display: block;
  overflow-wrap: anywhere;
  color: #17313a;
  font-size: 16px;
  line-height: 1.25;
}

.field-job-copy > p,
.field-job-meta span {
  display: flex;
  align-items: center;
  gap: 6px;
  color: #5a7078;
  font-size: 12px;
}

.field-job-copy > p {
  margin: 5px 0 0;
}

.field-job-copy img,
.field-job-meta img {
  width: 14px;
  height: 14px;
  opacity: .7;
}

.field-job-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 6px 16px;
  margin-top: 8px;
}

.field-job-progress {
  display: flex;
  align-items: center;
  gap: 9px;
  margin-top: 9px;
}

.field-job-progress > span {
  width: min(180px, 55%);
  height: 6px;
  overflow: hidden;
  border-radius: 999px;
  background: #e2e9eb;
}

.field-job-progress i {
  display: block;
  height: 100%;
  background: #3f8b67;
}

.field-job-progress b {
  color: #536a72;
  font-size: 10px;
}

html body#strongholdApp:not(.login-active) .field-home-dashboard button.field-job-open {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  min-width: 112px;
  min-height: 42px;
  padding: 9px 13px;
  border: 1px solid #224b58;
  border-radius: 6px;
  color: #fff;
  background: #224b58;
  box-shadow: none;
  font-size: 12px;
  font-weight: 900;
}

.field-job-open img {
  width: 15px;
  filter: brightness(0) invert(1);
}

.field-task-row {
  display: grid;
  grid-template-columns: 34px minmax(0, 1fr) auto;
  gap: 11px;
  align-items: center;
  padding: 11px 12px;
  border: 1px solid #d1dbde;
  border-radius: 6px;
  background: #fff;
}

.field-task-row.warn { border-left: 4px solid #c8952f; }
.field-task-row.risk { border-left: 4px solid #bd4c43; }

.field-task-check,
.field-card-icon {
  display: grid;
  width: 34px;
  height: 34px;
  place-items: center;
  border-radius: 6px;
  background: #e8eef0;
}

.field-task-check img,
.field-card-icon img {
  width: 18px;
  height: 18px;
}

.field-task-row > div:nth-child(2) {
  min-width: 0;
}

.field-task-row strong,
.field-task-row small {
  display: block;
}

.field-task-row strong {
  overflow-wrap: anywhere;
  color: #213b44;
  font-size: 13px;
}

.field-task-row small {
  margin-top: 3px;
  color: #687b82;
  font-size: 10px;
}

.field-task-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 5px;
}

html body#strongholdApp:not(.login-active) .field-task-actions button {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  min-width: 0;
  min-height: 32px;
  padding: 6px 9px;
  border: 1px solid #b9c8cd;
  border-radius: 5px;
  color: #29464f;
  background: #f4f7f8;
  box-shadow: none;
  font-size: 10px;
  font-weight: 900;
}

.field-task-actions button img {
  width: 13px;
  height: 13px;
}

.field-home-mini-empty,
.field-home-empty {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 15px;
  border: 1px dashed #bdcdd1;
  border-radius: 7px;
  color: #526a72;
  background: #f1f5f6;
}

.field-home-empty-icon {
  display: grid;
  flex: 0 0 42px;
  width: 42px;
  height: 42px;
  place-items: center;
  border-radius: 50%;
  background: #dcebe3;
}

.field-home-empty img,
.field-home-mini-empty img {
  width: 22px;
  height: 22px;
}

.field-home-empty strong,
.field-home-empty p,
.field-home-mini-empty strong,
.field-home-mini-empty small {
  display: block;
  margin: 0;
}

.field-home-empty strong,
.field-home-mini-empty strong { color: #27434c; font-size: 13px; }
.field-home-empty p,
.field-home-mini-empty small { margin-top: 3px; color: #687b82; font-size: 11px; }

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

.field-crew-head {
  display: flex;
  align-items: center;
  gap: 10px;
}

.field-crew-head small,
.field-crew-head strong {
  display: block;
}

.field-crew-head small {
  color: #6a7d83;
  font-size: 9px;
  font-weight: 900;
  text-transform: uppercase;
}

.field-crew-head strong {
  margin-top: 2px;
  color: #1d3942;
  font-size: 15px;
}

.field-crew-members {
  display: grid;
  gap: 6px;
}

.field-crew-members > span {
  display: grid;
  grid-template-columns: 28px minmax(0, 1fr) auto;
  align-items: center;
  gap: 8px;
  min-width: 0;
  padding: 7px;
  border-radius: 6px;
  background: #eef3f4;
}

.field-crew-members > span.is-me {
  box-shadow: inset 3px 0 #3f8b67;
  background: #e8f1ed;
}

.field-crew-members i,
.field-crew-avatar {
  display: grid;
  width: 28px;
  height: 28px;
  place-items: center;
  border-radius: 50%;
  color: #fff;
  background: #526f79;
  font-style: normal;
  font-size: 11px;
  font-weight: 900;
}

.field-crew-members b {
  overflow-wrap: anywhere;
  color: #29444d;
  font-size: 11px;
}

.field-crew-members small {
  color: #71838a;
  font-size: 9px;
}

html body#strongholdApp:not(.login-active) button.field-vehicle-card {
  display: grid;
  grid-template-columns: 36px minmax(0, 1fr) auto 16px;
  gap: 10px;
  align-items: center;
  width: 100%;
  min-height: 72px;
  padding: 10px;
  border: 1px solid #ccd8db;
  border-radius: 7px;
  color: #243f48;
  background: #f3f7f7;
  box-shadow: none;
  text-align: left;
}

.field-vehicle-card > span:nth-child(2) small,
.field-vehicle-card > span:nth-child(2) strong,
.field-vehicle-card > span:nth-child(2) em,
.field-vehicle-facts b,
.field-vehicle-facts small {
  display: block;
}

.field-vehicle-card > span:nth-child(2) small {
  color: #708188;
  font-size: 9px;
  font-weight: 900;
  text-transform: uppercase;
}

.field-vehicle-card > span:nth-child(2) strong {
  margin-top: 2px;
  overflow-wrap: anywhere;
  color: #1e3a43;
  font-size: 13px;
}

.field-vehicle-card > span:nth-child(2) em {
  margin-top: 2px;
  color: #697c83;
  font-size: 10px;
  font-style: normal;
}

.field-vehicle-facts {
  text-align: right;
}

.field-vehicle-facts b,
.field-vehicle-facts small {
  color: #5f747b;
  font-size: 9px;
}

.field-card-chevron {
  width: 15px;
  height: 15px;
}

.field-home-tool-grid {
  display: grid;
  gap: 7px;
}

html body#strongholdApp:not(.login-active) .field-home-tool-grid > button {
  display: grid;
  grid-template-columns: 30px minmax(0, 1fr) 14px;
  gap: 9px;
  align-items: center;
  width: 100%;
  min-height: 54px;
  padding: 9px 10px;
  border: 1px solid #c9d5d8;
  border-radius: 6px;
  color: #29444d;
  background: #f4f7f8;
  box-shadow: none;
  text-align: left;
}

.field-home-tool-grid > button > img:first-child {
  width: 20px;
  height: 20px;
}

.field-home-tool-grid > button > img:last-child {
  width: 14px;
  height: 14px;
}

.field-home-tool-grid strong,
.field-home-tool-grid small {
  display: block;
}

.field-home-tool-grid strong {
  color: #244049;
  font-size: 11px;
}

.field-home-tool-grid small {
  margin-top: 2px;
  color: #718289;
  font-size: 9px;
}

@media (max-width: 980px) {
  html body#strongholdApp:not(.login-active) #homeFeed:has(.field-home-dashboard) { padding: 12px; }
  .field-home-hero { align-items: flex-start; }
  .field-home-hero-side { align-items: flex-end; flex-direction: column; }
  .field-home-layout { grid-template-columns: minmax(0, 1fr); }
  .field-home-sidebar { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .field-home-tools { grid-column: 1 / -1; }
  .field-home-tool-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}

@media (max-width: 680px) {
  html body#strongholdApp:not(.login-active) #homeFeed:has(.field-home-dashboard) { padding: 8px; }
  .field-home-dashboard { width: 100%; }
  .field-home-hero { display: grid; min-height: 0; padding: 16px; gap: 14px; }
  .field-home-avatar { flex-basis: 48px; width: 48px; height: 48px; font-size: 22px; }
  .field-home-identity { gap: 11px; }
  .field-home-identity h2 { font-size: 24px; }
  .field-home-identity > div > span { font-size: 11px; }
  .field-home-hero-side { align-items: stretch; flex-direction: row; justify-content: space-between; }
  .field-home-counts { margin-left: auto; }
  .field-home-counts span { min-width: 68px; padding: 7px 8px; }
  .field-home-layout { margin-top: 8px; gap: 8px; }
  .field-home-main,
  .field-home-sidebar { gap: 8px; }
  .field-home-sidebar { grid-template-columns: minmax(0, 1fr); }
  .field-home-tools { grid-column: auto; }
  .field-home-section { padding: 13px; }
  .field-home-section-head { margin-bottom: 10px; }
  .field-job-card { grid-template-columns: 32px minmax(0, 1fr); gap: 9px; padding: 11px; }
  .field-job-order { width: 30px; height: 30px; }
  .field-job-open { grid-column: 1 / -1; width: 100%; }
  .field-task-row { grid-template-columns: 30px minmax(0, 1fr); }
  .field-task-actions { grid-column: 1 / -1; justify-content: flex-start; padding-left: 41px; }
  .field-home-tool-grid { grid-template-columns: minmax(0, 1fr); }
}

@media (max-width: 430px) {
  .field-home-hero-side { display: grid; }
  .field-role-badge,
  .field-role-select { width: 100%; justify-content: center; }
  .field-home-counts { width: 100%; margin: 0; }
  .field-home-counts span { flex: 1; }
  .field-job-copy > strong { font-size: 14px; }
  .field-job-meta { display: grid; gap: 4px; }
  .field-vehicle-facts { display: none; }
  html body#strongholdApp:not(.login-active) button.field-vehicle-card { grid-template-columns: 36px minmax(0, 1fr) 16px; }
}
