/* Chaves de recursos e histórico compacto da OS — 2026-09-27 */
.settings-features .feature-switch-row {
  min-height: 72px;
  cursor: pointer;
}

.feature-switch-copy {
  min-width: 0;
}

.feature-switch {
  position: relative;
  width: 52px;
  height: 30px;
  flex: 0 0 52px;
}

.feature-switch input {
  position: absolute;
  inset: 0;
  width: 100% !important;
  height: 100% !important;
  margin: 0;
  opacity: 0;
  cursor: pointer;
  z-index: 2;
}

.feature-switch i {
  position: absolute;
  inset: 0;
  border-radius: 999px;
  background: #cbd6df;
  transition: background .18s ease;
}

.feature-switch i::after {
  content: "";
  position: absolute;
  top: 3px;
  left: 3px;
  width: 24px;
  height: 24px;
  border-radius: 50%;
  background: #fff;
  box-shadow: 0 2px 7px rgba(22, 56, 88, .22);
  transition: transform .18s ease;
}

.feature-switch input:checked + i {
  background: #0874bd;
}

.feature-switch input:checked + i::after {
  transform: translateX(22px);
}

.feature-switch input:focus-visible + i {
  outline: 3px solid rgba(8, 116, 189, .22);
  outline-offset: 2px;
}

.feature-confirm-dialog {
  width: min(91vw, 430px);
}

.feature-confirm-dialog .dialog-card {
  text-align: center;
}

.feature-confirm-icon {
  width: 54px;
  height: 54px;
  display: grid;
  place-items: center;
  margin: 0 auto 14px;
  border-radius: 17px;
  background: #e6f3fb;
  color: #0768ae;
  font-size: 25px;
  font-weight: 900;
}

.feature-confirm-icon.disable {
  background: #fff2dd;
  color: #a36700;
}

.feature-confirm-dialog h2 {
  margin: 7px 0 9px;
  color: #153966;
  font-size: 21px;
}

.feature-confirm-dialog p {
  margin: 0;
  color: #5f7489;
  font-size: 14px;
  line-height: 1.55;
}

.order-history-button {
  width: 100%;
  min-height: 68px;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto 16px;
  align-items: center;
  gap: 10px;
  margin-top: 15px;
  padding: 13px 15px;
  border: 1px solid #d6e3ed;
  border-radius: 15px;
  background: #fff;
  color: #153d64;
  text-align: left;
  box-shadow: 0 6px 18px rgba(23, 58, 97, .05);
}

.order-history-button b,
.order-history-button small {
  display: block;
}

.order-history-button b {
  font-size: 15px;
}

.order-history-button small {
  margin-top: 4px;
  color: #718398;
  font-size: 11px;
}

.order-history-button strong {
  color: #0768ae;
  font-size: 12px;
  white-space: nowrap;
}

.order-history-button i {
  color: #0870ba;
  font-size: 22px;
  font-style: normal;
}

.order-history-dialog {
  width: min(92vw, 560px);
}

.order-history-dialog .dialog-card {
  max-height: 82dvh;
  display: flex;
  flex-direction: column;
}

.order-history-dialog .dialog-head {
  flex: 0 0 auto;
}

.order-history-dialog .dialog-head p {
  margin: 5px 0 0;
  color: #718398;
  font-size: 12px;
}

.order-history-list {
  min-height: 0;
  overflow-y: auto;
  padding-right: 2px;
}

.order-history-list .event-item {
  padding: 14px;
}

.order-history-list .event-item b {
  font-size: 13px;
  line-height: 1.4;
}

.order-history-list .event-item small {
  margin-top: 5px;
  font-size: 11px;
  line-height: 1.4;
}

.notification-dialog {
  width: min(92vw, 480px);
}

.notification-dialog .dialog-card {
  max-height: 84dvh;
  display: flex;
  flex-direction: column;
}

.notification-dialog .dialog-head {
  flex: 0 0 auto;
}

.notification-dialog .dialog-head p {
  margin: 5px 0 0;
  color: #718398;
  font-size: 12px;
  line-height: 1.4;
}

.notification-list {
  display: grid;
  gap: 9px;
  min-height: 0;
  overflow-y: auto;
  padding: 2px;
}

.notification-item {
  width: 100%;
  min-height: 78px;
  display: grid;
  grid-template-columns: 46px minmax(0, 1fr) 14px;
  align-items: center;
  gap: 11px;
  padding: 12px;
  border: 1px solid #d9e5ee;
  border-radius: 15px;
  background: #fff;
  color: #123b66;
  text-align: left;
}

.notification-item:hover,
.notification-item:focus-visible {
  border-color: #69afe0;
  background: #f7fbfe;
}

.notification-kind {
  width: 46px;
  height: 46px;
  display: grid;
  place-items: center;
  border-radius: 14px;
  background: #e7f3fb;
  color: #0870ba;
  font-size: 16px;
  font-weight: 900;
}

.notification-item.charge .notification-kind {
  background: #fff0dc;
  color: #a85e00;
}

.notification-item.stock .notification-kind {
  background: #ecf8ef;
  color: #168242;
}

.notification-item.task .notification-kind {
  background: #f0edff;
  color: #5f45d8;
}

.notification-item b,
.notification-item small {
  display: block;
}

.notification-item b {
  font-size: 14px;
  line-height: 1.35;
}

.notification-item small {
  margin-top: 4px;
  color: #6b7f94;
  font-size: 11px;
  line-height: 1.4;
}

.notification-item > i {
  color: #0870ba;
  font-size: 22px;
  font-style: normal;
}

.notification-list .empty-state {
  min-height: 180px;
  padding: 25px 14px;
}

.notification-settings-link {
  width: 100%;
  min-height: 46px;
  margin-top: 12px;
  border: 1px solid #cfe1ee;
  border-radius: 13px;
  background: #eef7fc;
  color: #0868ac;
  font-size: 13px;
  font-weight: 800;
}

@media (max-width: 480px) {
  .feature-confirm-dialog .dialog-actions {
    grid-template-columns: 1fr 1fr;
  }

  .order-history-dialog {
    width: calc(100vw - 22px);
  }

  .order-history-dialog .dialog-card {
    max-height: 86dvh;
    padding: 20px 16px;
  }

  .notification-dialog {
    width: calc(100vw - 22px);
  }

  .notification-dialog .dialog-card {
    max-height: 86dvh;
    padding: 20px 16px;
  }
}
