.osha-forms-incident-form fieldset { border: 1px solid #ddd; padding: 12px; margin: 12px 0; }
.osha-forms-incident-form legend { padding: 0 6px; }
.osha-forms-incident-form input[type="text"],
.osha-forms-incident-form input[type="email"],
.osha-forms-incident-form input[type="date"],
.osha-forms-incident-form input[type="time"],
.osha-forms-incident-form input[type="number"],
.osha-forms-incident-form select,
.osha-forms-incident-form textarea { width: 100%; max-width: 520px; }
.osha-forms-incident-form button { padding: 10px 14px; }
.osha-forms-rates ul { margin-left: 18px; }
.notice.notice-success { padding: 10px; background: #e7f7ee; border-left: 4px solid #00a32a; }
.notice.notice-error { padding: 10px; background: #fde8e8; border-left: 4px solid #d63638; }


.osha-forms-incident-form fieldset,
.osha-forms-company-settings fieldset {
  border: 1px solid #d0d7de;
  padding: 16px;
  margin: 0 0 18px;
  border-radius: 8px;
}
.osha-forms-incident-form input[type=text],
.osha-forms-incident-form input[type=date],
.osha-forms-incident-form input[type=time],
.osha-forms-incident-form input[type=email],
.osha-forms-incident-form input[type=number],
.osha-forms-incident-form select,
.osha-forms-company-settings input[type=text],
.osha-forms-company-settings input[type=number],
.osha-forms-company-settings select,
.osha-forms-company-settings textarea,
.osha-forms-incident-form textarea {
  width: min(100%, 720px);
  max-width: 100%;
}
.osha-forms-company-settings .notice,
.osha-forms-incident-form .notice {
  padding: 10px 12px;
  margin: 0 0 12px;
  border-radius: 6px;
  background: #ecfdf3;
  border: 1px solid #a7f3d0;
}


/* OSHA workflow page cards */
.osha-workflow-card{
  background: #ffffff;
  border: 1px solid #d0d7de;
  border-radius: 16px;
  color: #0b1220;
}
.osha-workflow-card h1,
.osha-workflow-card h2,
.osha-workflow-card h3,
.osha-workflow-card h4,
.osha-workflow-card h5,
.osha-workflow-card h6,
.osha-workflow-card p,
.osha-workflow-card li,
.osha-workflow-card label,
.osha-workflow-card legend,
.osha-workflow-card strong,
.osha-workflow-card span,
.osha-workflow-card td,
.osha-workflow-card th {
  color: inherit;
}
.osha-workflow-card .button,
.osha-workflow-card button,
.osha-workflow-card input[type="submit"],
.osha-workflow-card input[type="button"]{
  color:#ffffff !important;
}
.osha-inline-incident-divider{
  display:none;
  width:100%;
  height:5px;
  margin:14px 0 20px 0;
  border-radius:3px;
  background:#000000;
}

/* Dark mode tuning to match Build Safe dashboard cards */
[data-bsd-theme="dark"] .osha-workflow-card{
  background: #081a44 !important;
  border-color: #15326a !important;
  color: #eef4ff !important;
  box-shadow: none !important;
}
[data-bsd-theme="dark"] .osha-workflow-card h1,
[data-bsd-theme="dark"] .osha-workflow-card h2,
[data-bsd-theme="dark"] .osha-workflow-card h3,
[data-bsd-theme="dark"] .osha-workflow-card h4,
[data-bsd-theme="dark"] .osha-workflow-card h5,
[data-bsd-theme="dark"] .osha-workflow-card h6,
[data-bsd-theme="dark"] .osha-workflow-card p,
[data-bsd-theme="dark"] .osha-workflow-card li,
[data-bsd-theme="dark"] .osha-workflow-card label,
[data-bsd-theme="dark"] .osha-workflow-card legend,
[data-bsd-theme="dark"] .osha-workflow-card strong,
[data-bsd-theme="dark"] .osha-workflow-card span,
[data-bsd-theme="dark"] .osha-workflow-card td,
[data-bsd-theme="dark"] .osha-workflow-card th,
[data-bsd-theme="dark"] .osha-workflow-card .notice,
[data-bsd-theme="dark"] .osha-workflow-card a:not(.button){
  color: #eef4ff !important;
}
[data-bsd-theme="dark"] .osha-workflow-card .widefat,
[data-bsd-theme="dark"] .osha-workflow-card .widefat td,
[data-bsd-theme="dark"] .osha-workflow-card .widefat th{
  background: transparent !important;
  color: #eef4ff !important;
  border-color: #102b5e !important;
}
[data-bsd-theme="dark"] .osha-workflow-card .widefat thead th{
  background: #1e5ea8 !important;
  color: #ffffff !important;
}
[data-bsd-theme="dark"] .osha-workflow-card fieldset{
  border-color: #234887 !important;
}
[data-bsd-theme="dark"] .osha-workflow-card input[type="text"],
[data-bsd-theme="dark"] .osha-workflow-card input[type="email"],
[data-bsd-theme="dark"] .osha-workflow-card input[type="password"],
[data-bsd-theme="dark"] .osha-workflow-card input[type="search"],
[data-bsd-theme="dark"] .osha-workflow-card input[type="url"],
[data-bsd-theme="dark"] .osha-workflow-card input[type="tel"],
[data-bsd-theme="dark"] .osha-workflow-card input[type="number"],
[data-bsd-theme="dark"] .osha-workflow-card input[type="date"],
[data-bsd-theme="dark"] .osha-workflow-card input[type="time"],
[data-bsd-theme="dark"] .osha-workflow-card textarea,
[data-bsd-theme="dark"] .osha-workflow-card select{
  background:#0a1f52 !important;
  color:#eef4ff !important;
  border-color:#234887 !important;
}
[data-bsd-theme="dark"] .osha-workflow-card input::placeholder,
[data-bsd-theme="dark"] .osha-workflow-card textarea::placeholder{
  color:#b8c7e6 !important;
}
[data-bsd-theme="dark"] .osha-workflow-card .button,
[data-bsd-theme="dark"] .osha-workflow-card button,
[data-bsd-theme="dark"] .osha-workflow-card input[type="submit"],
[data-bsd-theme="dark"] .osha-workflow-card input[type="button"]{
  background: var(--bsd-button-bg) !important;
  color: var(--bsd-button-text) !important;
}
[data-bsd-theme="dark"] .osha-inline-incident-divider{
  background:#000000 !important;
  box-shadow: 0 0 0 1px #244a8b !important;
}


/* Workflow page heading */
.osha-workflow-title{
  color: var(--bsd-text);
  align-self: center;
}
[data-bsd-theme="dark"] .osha-workflow-title{
  color: #eef4ff !important;
}

/* Ensure incidents card also gets dark mode surface */
[data-bsd-theme="dark"] .osha-workflow-incidents-card{
  background: #081a44 !important;
  border-color: #15326a !important;
  color: #eef4ff !important;
}
[data-bsd-theme="dark"] .osha-workflow-incidents-card *{
  color: inherit;
}
[data-bsd-theme="dark"] .osha-workflow-incidents-card .button,
[data-bsd-theme="dark"] .osha-workflow-incidents-card button,
[data-bsd-theme="dark"] .osha-workflow-incidents-card input[type="submit"],
[data-bsd-theme="dark"] .osha-workflow-incidents-card input[type="button"]{
  background: var(--bsd-button-bg) !important;
  color: #ffffff !important;
  border: 0 !important;
}
[data-bsd-theme="dark"] .osha-workflow-incidents-card a.button,
[data-bsd-theme="dark"] .osha-workflow-incidents-card a.button:visited{
  color:#ffffff !important;
  text-decoration:none !important;
}


/* v2.1.5 harden incidents card dark mode */
[data-bsd-theme="dark"] .osha-forms-incidents-manager > div,
[data-bsd-theme="dark"] .osha-workflow-incidents-card{
  background: #081a44 !important;
  border: 1px solid #15326a !important;
  color: #eef4ff !important;
}
[data-bsd-theme="dark"] .osha-forms-incidents-manager > div *,
[data-bsd-theme="dark"] .osha-workflow-incidents-card *{
  color: inherit;
}
[data-bsd-theme="dark"] .osha-forms-incidents-manager .button,
[data-bsd-theme="dark"] .osha-forms-incidents-manager button,
[data-bsd-theme="dark"] .osha-forms-incidents-manager input[type="submit"],
[data-bsd-theme="dark"] .osha-forms-incidents-manager input[type="button"],
[data-bsd-theme="dark"] .osha-workflow-incidents-card .button,
[data-bsd-theme="dark"] .osha-workflow-incidents-card button,
[data-bsd-theme="dark"] .osha-workflow-incidents-card input[type="submit"],
[data-bsd-theme="dark"] .osha-workflow-incidents-card input[type="button"]{
  background: var(--bsd-button-bg) !important;
  color: #ffffff !important;
  border: 0 !important;
}
[data-bsd-theme="dark"] .osha-forms-incidents-manager a.button,
[data-bsd-theme="dark"] .osha-forms-incidents-manager a.button:visited,
[data-bsd-theme="dark"] .osha-workflow-incidents-card a.button,
[data-bsd-theme="dark"] .osha-workflow-incidents-card a.button:visited{
  color: #ffffff !important;
  text-decoration: none !important;
}
[data-bsd-theme="dark"] .osha-forms-incidents-manager .widefat,
[data-bsd-theme="dark"] .osha-forms-incidents-manager .widefat td,
[data-bsd-theme="dark"] .osha-forms-incidents-manager .widefat th{
  background: transparent !important;
  color: #eef4ff !important;
  border-color: #102b5e !important;
}
[data-bsd-theme="dark"] .osha-forms-incidents-manager .widefat thead th{
  background: #1e5ea8 !important;
  color: #ffffff !important;
}


/* v2.1.5 incidents card dark text + table heading alignment */
[data-bsd-theme="dark"] .osha-forms-incidents-manager h2,
[data-bsd-theme="dark"] .osha-workflow-incidents-card h2,
[data-bsd-theme="dark"] .osha-forms-incidents-manager label,
[data-bsd-theme="dark"] .osha-workflow-incidents-card label{
  color: #eef4ff !important;
}
[data-bsd-theme="dark"] .osha-forms-incidents-manager input::placeholder,
[data-bsd-theme="dark"] .osha-workflow-incidents-card input::placeholder{
  color: #b8c7e6 !important;
  opacity: 1 !important;
}
.osha-forms-incidents-manager .widefat thead th,
.osha-workflow-incidents-card .widefat thead th{
  text-align: left !important;
}
