/* Trigger button in the price list row */
.bc-schedule-modal__trigger {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  margin: 0.35rem 0 0;
  padding: 0.35rem 0.75rem;
  border: 1px solid #c9d4de;
  border-radius: 999px;
  background: #f4f8fb;
  color: #1f3a4d;
  font-size: 0.8rem;
  font-weight: 600;
  line-height: 1.2;
  cursor: pointer;
  transition: background 0.15s ease, border-color 0.15s ease, color 0.15s ease;
  font-size: 11px;
}

.bc-schedule-modal__trigger:hover,
.bc-schedule-modal__trigger:focus {
  background: #e8f1f7;
  border-color: #9db4c7;
  color: #102735;
  outline: none;
}

.bc-schedule-modal__trigger-icon {
  width: 0.85rem;
  height: 0.85rem;
  border-radius: 50%;
  border: 1.5px solid currentColor;
  position: relative;
  flex-shrink: 0;
}

.bc-schedule-modal__trigger-icon::after {
  content: '';
  position: absolute;
  top: 0.12rem;
  left: 0.28rem;
  width: 0.2rem;
  height: 0.35rem;
  border-right: 1.5px solid currentColor;
  border-bottom: 1.5px solid currentColor;
}

.moreAnalize .bc-schedule-modal__trigger {
  margin-left: 0.35rem;
  vertical-align: middle;
}

/* Dialog shell — hide title bar (Close button remains in footer) */
.bc-schedule-modal-dialog .ui-dialog-titlebar {
  display: none;
}

.bc-schedule-modal-dialog .ui-dialog-content {
  padding: 1rem !important;
  background: #f7f9fb;
  max-height: calc(100vh - 5rem);
  overflow-y: auto;
  box-sizing: border-box;
}

.bc-schedule-modal-dialog .ui-dialog-buttonpane {
  margin: 0;
  border: 0;
  border-top: 1px solid #e4eaf0;
  background: #fff;
  border-radius: 0 0 12px 12px;
  padding: 0.75rem 1rem;
}

.bc-schedule-modal-dialog .ui-dialog-buttonpane .ui-dialog-buttonset {
  float: none;
  display: flex;
  justify-content: stretch;
  width: 100%;
}

.bc-schedule-modal-dialog .ui-dialog-buttonpane button {
  width: 100%;
  margin: 0 !important;
}

.bc-schedule-modal-dialog {
  border: 0 !important;
  border-radius: 12px !important;
  overflow: hidden;
  box-shadow: 0 18px 50px rgba(16, 39, 53, 0.22) !important;
  max-width: calc(100vw - 1rem) !important;
  width: min(640px, calc(100vw - 1rem)) !important;
  box-sizing: border-box !important;
  left: 50% !important;
  transform: translateX(-50%);
}

/* Modal body */
.bc-schedule-modal {
  position: relative;
  width: 100%;
  max-width: 100%;
  min-width: 0;
  padding: 0.25rem 0 0.5rem;
  color: #243542;
  font-size: 0.95rem;
  line-height: 1.45;
  box-sizing: border-box;
}

.bc-schedule-modal__focus-start {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.bc-schedule-modal__intro {
  margin-bottom: 1rem;
}

.bc-schedule-modal__analyze-title {
  margin: 0 0 0.5rem;
  font-size: 1.1rem;
  font-weight: 700;
  color: #1f3a4d;
  line-height: 1.3;
  word-break: break-word;
}

.bc-schedule-modal__lead {
  margin: 0;
  color: #4d6170;
  font-size: 0.92rem;
  word-break: break-word;
}

.bc-schedule-modal__form {
  margin: 0 0 0.85rem;
  padding: 1rem;
  border-radius: 12px;
  background: #fff;
  border: 1px solid #e4eaf0;
  box-shadow: 0 1px 2px rgba(16, 39, 53, 0.04);
  box-sizing: border-box;
  overflow-x: hidden;
}

.bc-schedule-modal__grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 0.9rem;
  width: 100%;
  min-width: 0;
}

.bc-schedule-modal__field {
  display: grid;
  gap: 0.35rem;
  min-width: 0;
}

.bc-schedule-modal__field label {
  font-weight: 650;
  font-size: 0.88rem;
  color: #1f3a4d;
}

.bc-schedule-modal__hint {
  font-size: 0.78rem;
  color: #6b7f8d;
}

.bc-schedule-modal__field input,
.bc-schedule-modal__field select {
  width: 100%;
  max-width: 100%;
  min-width: 0;
  box-sizing: border-box;
  padding: 0.65rem 0.75rem;
  border: 1px solid #c9d4de;
  border-radius: 8px;
  background: #fbfcfd;
  color: #1f3a4d;
  font: inherit;
  transition: border-color 0.15s ease, box-shadow 0.15s ease, background 0.15s ease;
}

/* date / time inputs — avoid native overflow on narrow screens */
.bc-schedule-modal__datetime {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.75rem;
  width: 100%;
  min-width: 0;
}

.bc-schedule-modal__field input[type='date'],
.bc-schedule-modal__field input[type='time'] {
  display: block;
  width: 100%;
  max-width: 100%;
  min-width: 0;
  -webkit-appearance: none;
  appearance: none;
  font-size: 16px;
  line-height: 1.3;
  overflow: hidden;
}

.bc-schedule-modal__field input[type='date']::-webkit-calendar-picker-indicator,
.bc-schedule-modal__field input[type='time']::-webkit-calendar-picker-indicator {
  margin-left: 0.25rem;
  flex-shrink: 0;
}

.bc-schedule-modal__field input:hover,
.bc-schedule-modal__field select:hover {
  border-color: #9db4c7;
}

.bc-schedule-modal__field input:focus,
.bc-schedule-modal__field select:focus {
  outline: none;
  border-color: #2f5a73;
  background: #fff;
  box-shadow: 0 0 0 3px rgba(47, 90, 115, 0.18);
}

.bc-schedule-modal__field input.is-invalid,
.bc-schedule-modal__field select.is-invalid {
  border-color: #c62828;
  box-shadow: 0 0 0 3px rgba(198, 40, 40, 0.12);
}

.bc-schedule-modal__actions {
  margin-top: 1rem;
}

.bc-schedule-modal__submit {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  width: 100%;
  min-width: 0;
  padding: 0.75rem 1rem !important;
  border: 0 !important;
  border-radius: 8px !important;
  background: transparent  !important;
  color: #000 !important;
  font-weight: 650 !important;
  font-size: 0.9rem !important;
  line-height: 1.35 !important;
  white-space: normal;
  text-align: center;
  cursor: pointer;
  transition: background 0.15s ease, transform 0.1s ease;
  margin: 0;
  box-sizing: border-box;
}
 
.bc-schedule-modal__submit:disabled {
  opacity: 0.75;
  cursor: wait;
}

.bc-schedule-modal__spinner {
  display: none;
  width: 1rem;
  height: 1rem;
  border: 2px solid rgba(255, 255, 255, 0.35);
  border-top-color: #fff;
  border-radius: 50%;
  animation: bc-schedule-spin 0.7s linear infinite;
}

.bc-schedule-modal__submit.is-loading .bc-schedule-modal__spinner {
  display: inline-block;
}

@keyframes bc-schedule-spin {
  to {
    transform: rotate(360deg);
  }
}

/* Status banners */
.bc-schedule-modal__status {
  min-height: 0;
  margin-bottom: 0.75rem;
}

.bc-schedule-modal__status:empty {
  display: none;
}

.bc-schedule-modal__status span {
  display: block;
  padding: 0.7rem 0.85rem;
  border-radius: 8px;
  font-size: 0.88rem;
  font-weight: 550;
}

.bc-schedule-modal__status.is-loading span {
  background: #eef5fa;
  color: #2f5a73;
  border: 1px solid #d3e3ef;
}

.bc-schedule-modal__status.is-success span {
  background: #eaf7ef;
  color: #1b5e20;
  border: 1px solid #c8e6c9;
}

.bc-schedule-modal__status.is-error span {
  background: #fdecea;
  color: #b42318;
  border: 1px solid #f5c6c2;
}

.bc-schedule-modal__status.is-info span {
  background: #f4f6f8;
  color: #4d6170;
  border: 1px solid #dde5ec;
}

/* Results */
.bc-schedule-modal__results-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 0.75rem;
  margin-bottom: 0.65rem;
}

.bc-schedule-modal__results-title {
  margin: 0;
  font-size: 0.95rem;
  font-weight: 700;
  color: #1f3a4d;
}

.bc-schedule-modal__results-count {
  margin: 0;
  font-size: 0.8rem;
  color: #6b7f8d;
}

.bc-schedule-modal__cards {
  display: grid;
  gap: 0.75rem;
}

.bc-schedule-card {
  display: grid;
  gap: 0.85rem;
  padding: 1rem 1.05rem;
  border-radius: 12px;
  background: #fff;
  border: 1px solid #e4eaf0;
  box-shadow: 0 1px 2px rgba(16, 39, 53, 0.04);
}

.bc-schedule-card__label {
  margin: 0 0 0.2rem;
  font-size: 0.72rem;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: #6b7f8d;
  font-weight: 650;
}

.bc-schedule-card__deadline {
  margin: 0 0 0.45rem;
  font-size: 1.25rem;
  line-height: 1.25;
  font-weight: 750;
  color: #1f3a4d;
}

.bc-schedule-card__test {
  margin: 0;
  color: #4d6170;
  font-size: 0.9rem;
}

.bc-schedule-card__meta {
  display: flex;
  flex-wrap: wrap;
  gap: 0.65rem 1.25rem;
  margin: 0;
  padding-top: 0.75rem;
  border-top: 1px dashed #e4eaf0;
}

.bc-schedule-card__meta>div {
  display: grid;
  gap: 0.1rem;
}

.bc-schedule-card__meta dt {
  margin: 0;
  font-size: 0.7rem;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: #6b7f8d;
  font-weight: 650;
}

.bc-schedule-card__meta dd {
  margin: 0;
  font-size: 0.9rem;
  font-weight: 600;
  color: #1f3a4d;
}

.bc-schedule-modal__empty-state {
  text-align: center;
  padding: 1.35rem 1rem;
  border-radius: 12px;
  background: #fff;
  border: 1px dashed #c9d4de;
}

.bc-schedule-modal__empty-icon {
  width: 2.25rem;
  height: 2.25rem;
  margin: 0 auto 0.7rem;
  border-radius: 50%;
  border: 2px solid #9db4c7;
  position: relative;
}

.bc-schedule-modal__empty-icon::before,
.bc-schedule-modal__empty-icon::after {
  content: '';
  position: absolute;
  background: #9db4c7;
  border-radius: 1px;
}

.bc-schedule-modal__empty-icon::before {
  width: 2px;
  height: 0.7rem;
  left: 50%;
  top: 0.4rem;
  transform: translateX(-50%);
}

.bc-schedule-modal__empty-icon::after {
  width: 2px;
  height: 0.2rem;
  left: 50%;
  bottom: 0.4rem;
  transform: translateX(-50%);
}

.bc-schedule-modal__empty-title {
  margin: 0 0 0.25rem;
  font-weight: 700;
  color: #1f3a4d;
}

.bc-schedule-modal__empty-text {
  margin: 0;
  color: #6b7f8d;
  font-size: 0.88rem;
}


td.views-field.views-field-field-loinc {
  width: 30px;
}

/* Mobile / small screens */
@media (max-width: 640px) {
  .bc-schedule-modal-dialog {
    width: calc(100vw - 0.75rem) !important;
    max-width: calc(100vw - 0.75rem) !important;
    margin: 0 !important;
    border-radius: 10px !important;
  }

  .bc-schedule-modal-dialog .ui-dialog-content {
    padding: 0.75rem !important;
    max-height: calc(100vh - 4.5rem);
  }

  .bc-schedule-modal-dialog .ui-dialog-buttonpane {
    padding: 0.65rem 0.75rem;
  }

  .bc-schedule-modal__form {
    padding: 0.75rem;
  }

  .bc-schedule-modal__grid {
    gap: 0.75rem;
  }

  .bc-schedule-modal__field input,
  .bc-schedule-modal__field select,
  .bc-schedule-modal__field input[type='date'],
  .bc-schedule-modal__field input[type='time'] {
    font-size: 16px;
    max-width: 100%;
  }

  .bc-schedule-modal__datetime {
    grid-template-columns: 1fr;
  }

  .bc-schedule-modal__field input[type='date'],
  .bc-schedule-modal__field input[type='time'] {
    padding-left: 0.5rem;
    padding-right: 0.5rem;
  }

  .bc-schedule-modal__analyze-title {
    font-size: 1rem;
  }

  .bc-schedule-modal__lead {
    font-size: 0.85rem;
  }

  .bc-schedule-modal__submit {
    font-size: 0.85rem !important;
    padding: 0.7rem 0.75rem !important;
  }

  .bc-schedule-card__deadline {
    font-size: 1.1rem;
  }

  .bc-schedule-modal__results-head {
    flex-direction: column;
    align-items: flex-start;
    gap: 0.25rem;
  }
}

@media (max-width: 380px) {
  .bc-schedule-modal__trigger {
    font-size: 10px;
    padding: 0.3rem 0.55rem;
  }
}

span.bc-schedule-modal__submit-label {
  display: table;
  background: url(/themes/thex/images/icons/arrow-right.svg) right center no-repeat;
  padding-right: 60px;
}