/* Shared mini-combo styles */

/* Bitacora activity modal */
.activity-info .combo-field {
  position: relative;
}
.activity-info .combo-trigger {
  position: relative;
  cursor: pointer;
}
.activity-info .combo-trigger .input,
.activity-info .combo-trigger input {
  padding-right: 58px;
  cursor: pointer;
}
.activity-info .combo-chevron {
  position: absolute;
  right: 15px;
  top: 50%;
  width: 8px;
  height: 8px;
  border-right: 2px solid rgba(17, 24, 39, 0.72);
  border-bottom: 2px solid rgba(17, 24, 39, 0.72);
  transform: translateY(-60%) rotate(45deg);
  pointer-events: none;
}
.activity-info .combo-clear-btn {
  position: absolute;
  right: 30px;
  top: 50%;
  width: 24px;
  height: 24px;
  transform: translateY(-50%);
  border: 0;
  border-radius: 0;
  background: transparent;
  color: #475569;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0;
  box-sizing: border-box;
  cursor: pointer;
}
.activity-info .combo-clear-btn svg {
  display: block;
  width: 16px;
  height: 16px;
}
.activity-info .combo-clear-btn:hover {
  background: #e2e8f0;
  color: #334155;
  border-radius: 999px;
}
.activity-info .combo-panel {
  position: absolute;
  top: auto;
  bottom: calc(100% - 1px);
  left: 0;
  right: 0;
  z-index: 18;
  max-height: 220px;
  overflow: auto;
  padding: 8px;
  border: 1px solid rgba(15, 23, 42, 0.08);
  border-bottom: 0;
  border-radius: 12px 12px 0 0;
  background: #fff;
  box-shadow: 0 2px 10px rgba(15, 23, 42, 0.06);
}
.activity-info .combo-field.is-open .combo-trigger .input,
.activity-info .combo-field.is-open .combo-trigger input {
  border-top-color: transparent;
}
.activity-info .combo-toolbar {
  position: sticky;
  top: 0;
  z-index: 1;
  margin-bottom: 6px;
  background: #fff;
  cursor: text;
}
.activity-info .combo-search-icon {
  position: absolute;
  left: 14px;
  top: 50%;
  width: 16px;
  height: 16px;
  transform: translateY(-50%);
  z-index: 2;
  pointer-events: none;
  cursor: text;
  background: no-repeat center / 16px 16px url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 24 24' fill='none' stroke='%2364748b' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Ccircle cx='11' cy='11' r='7'/%3E%3Cpath d='m20 20-3.5-3.5'/%3E%3C/svg%3E");
}
.activity-info .combo-search-input {
  padding-left: 38px !important;
  padding-right: 12px;
  cursor: text !important;
}
.activity-info .combo-list {
  display: grid;
  gap: 4px;
}
.activity-info .combo-panel[hidden] {
  display: none !important;
}
.activity-info .combo-option {
  display: grid;
  gap: 2px;
  width: 100%;
  padding: 9px 10px;
  border: 0;
  border-radius: 10px;
  background: transparent;
  color: #0f172a;
  font: inherit;
  text-align: left;
  cursor: pointer;
}
.activity-info .combo-option:hover,
.activity-info .combo-option.is-active {
  background: #eff6ff;
}
.activity-info .combo-option strong {
  font: inherit;
  font-weight: 400;
  line-height: inherit;
}
.activity-info .combo-option.is-active strong,
.activity-info .combo-option:hover strong {
  font-weight: 600;
}
.activity-info .combo-empty {
  padding: 10px;
  font-size: 12px;
  color: #64748b;
}
:root[data-theme="dark"] .activity-info .combo-panel {
  background: #0c1520;
  border-color: #223148;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.18);
}
@media (max-width: 720px) and (hover: none) {
  .activity-info .combo-field.is-open,
  .activity-info .plant-search-field.is-open {
    position: relative;
    z-index: 1000;
  }
  .activity-info .combo-panel,
  .activity-info .plant-search-panel {
    z-index: 1001;
    transform: translateZ(0);
  }
}

/* Reporte incidencias filters */
.search-filters-location .combo-field,
.dash-filters-main .combo-field,
#modal .ri-location-grid .combo-field {
  position: relative;
}
.search-filters-location .combo-trigger,
.dash-filters-main .combo-trigger,
#modal .ri-location-grid .combo-trigger {
  position: relative;
  display: block;
  width: 100%;
  cursor: pointer;
}
.search-filters-location .combo-trigger .input,
.search-filters-location .combo-trigger input,
.dash-filters-main .combo-trigger .input,
.dash-filters-main .combo-trigger input,
#modal .ri-location-grid .combo-trigger .input,
#modal .ri-location-grid .combo-trigger input {
  width: 100%;
  box-sizing: border-box;
  padding-right: 58px;
  cursor: pointer;
}
.search-filters-location .combo-chevron,
.dash-filters-main .combo-chevron,
#modal .ri-location-grid .combo-chevron {
  position: absolute;
  right: 15px;
  top: 50%;
  width: 8px;
  height: 8px;
  border-right: 2px solid rgba(17, 24, 39, 0.72);
  border-bottom: 2px solid rgba(17, 24, 39, 0.72);
  transform: translateY(-60%) rotate(45deg);
  pointer-events: none;
}
.search-filters-location .combo-clear-btn,
.dash-filters-main .combo-clear-btn,
#modal .ri-location-grid .combo-clear-btn {
  position: absolute;
  right: 30px;
  top: 50%;
  width: 24px;
  height: 24px;
  transform: translateY(-50%);
  border: 0;
  border-radius: 0;
  background: transparent;
  color: #475569;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0;
  box-sizing: border-box;
  cursor: pointer;
}
.search-filters-location .combo-clear-btn:hover,
.dash-filters-main .combo-clear-btn:hover,
#modal .ri-location-grid .combo-clear-btn:hover {
  background: #e2e8f0;
  color: #334155;
  border-radius: 999px;
}
.search-filters-location .combo-panel,
.dash-filters-main .combo-panel,
#modal .ri-location-grid .combo-panel {
  position: absolute;
  top: calc(100% - 1px);
  bottom: auto;
  left: 0;
  right: 0;
  z-index: 81;
  overflow: hidden;
  padding: 8px;
  border: 1px solid rgba(15, 23, 42, 0.08);
  border-top: 0;
  border-radius: 0 0 12px 12px;
  background: #fff;
  box-shadow: 0 2px 10px rgba(15, 23, 42, 0.06);
}
.search-filters-location .combo-field.is-open .combo-trigger .input,
.search-filters-location .combo-field.is-open .combo-trigger input,
.dash-filters-main .combo-field.is-open .combo-trigger .input,
.dash-filters-main .combo-field.is-open .combo-trigger input,
#modal .ri-location-grid .combo-field.is-open .combo-trigger .input,
#modal .ri-location-grid .combo-field.is-open .combo-trigger input {
  border-bottom-left-radius: 0;
  border-bottom-right-radius: 0;
  border-bottom-color: transparent;
}
.search-filters-location .combo-toolbar,
.dash-filters-main .combo-toolbar,
#modal .ri-location-grid .combo-toolbar {
  position: sticky;
  top: 0;
  z-index: 1;
  padding: 8px;
  margin-bottom: 6px;
  background: #fff;
  cursor: text;
  overflow: visible;
}
.search-filters-location .combo-search-icon,
.dash-filters-main .combo-search-icon,
#modal .ri-location-grid .combo-search-icon {
  position: absolute;
  left: 14px;
  top: 50%;
  width: 16px;
  height: 16px;
  transform: translateY(-50%);
  z-index: 2;
  pointer-events: none;
  cursor: text;
  background: no-repeat center / 16px 16px url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 24 24' fill='none' stroke='%2364748b' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Ccircle cx='11' cy='11' r='7'/%3E%3Cpath d='m20 20-3.5-3.5'/%3E%3C/svg%3E");
}
.search-filters-location .combo-search-input,
.dash-filters-main .combo-search-input,
#modal .ri-location-grid .combo-search-input {
  display: block;
  width: 100%;
  box-sizing: border-box;
  padding-left: 38px !important;
  padding-right: 12px;
  border-radius: 10px !important;
  cursor: text !important;
}
.search-filters-location .combo-list,
.dash-filters-main .combo-list,
#modal .ri-location-grid .combo-list {
  display: grid;
  gap: 4px;
  max-height: 220px;
  overflow: auto;
}
.search-filters-location .combo-option,
.dash-filters-main .combo-option,
#modal .ri-location-grid .combo-option {
  display: grid;
  gap: 2px;
  width: 100%;
  padding: 9px 10px;
  border: 0;
  border-radius: 10px;
  background: transparent;
  color: #0f172a;
  font: inherit;
  text-align: left;
  cursor: pointer;
}
.search-filters-location .combo-option strong,
.dash-filters-main .combo-option strong,
#modal .ri-location-grid .combo-option strong {
  font: inherit;
  font-weight: 400;
  line-height: inherit;
}
.search-filters-location .combo-option:hover,
.search-filters-location .combo-option.is-active,
.dash-filters-main .combo-option:hover,
.dash-filters-main .combo-option.is-active,
#modal .ri-location-grid .combo-option:hover,
#modal .ri-location-grid .combo-option.is-active {
  background: #eff6ff;
}
.search-filters-location .combo-option:hover strong,
.search-filters-location .combo-option.is-active strong,
.dash-filters-main .combo-option:hover strong,
.dash-filters-main .combo-option.is-active strong,
#modal .ri-location-grid .combo-option:hover strong,
#modal .ri-location-grid .combo-option.is-active strong {
  font-weight: 600;
}
.search-filters-location .combo-empty,
.dash-filters-main .combo-empty,
#modal .ri-location-grid .combo-empty {
  padding: 10px;
  font-size: 12px;
  color: #64748b;
}
:root[data-theme="dark"] .search-filters-location .combo-panel,
:root[data-theme="dark"] .dash-filters-main .combo-panel,
:root[data-theme="dark"] #modal .ri-location-grid .combo-panel {
  background: #121926;
  border-color: #253244;
  box-shadow: 0 14px 34px rgba(0, 0, 0, 0.4);
}
:root[data-theme="dark"] #modal .ri-location-grid .combo-toolbar {
  background: #121926;
}
:root[data-theme="dark"] #modal .ri-location-grid .combo-option {
  color: #e5eefb;
}
:root[data-theme="dark"] #modal .ri-location-grid .combo-option:hover,
:root[data-theme="dark"] #modal .ri-location-grid .combo-option.is-active {
  background: #1d2b40;
}
:root[data-theme="dark"] #modal .ri-location-grid .combo-empty {
  color: #93a4bb;
}
@media (max-width: 768px) {
  #modal .ri-location-grid .combo-panel {
    top: calc(100% - 1px);
    bottom: auto;
    border-top: 0;
    border-bottom: 1px solid rgba(15, 23, 42, 0.08);
    border-radius: 0 0 12px 12px;
    max-height: 240px;
  }
  #modal .ri-location-grid .combo-field.is-open .combo-trigger .input,
  #modal .ri-location-grid .combo-field.is-open .combo-trigger input {
    border-top-left-radius: 10px;
    border-top-right-radius: 10px;
    border-top-color: var(--ui-line);
    border-bottom-left-radius: 0;
    border-bottom-right-radius: 0;
    border-bottom-color: transparent;
  }
  #modal .ri-location-grid .combo-toolbar {
    margin-bottom: 4px;
  }
  #modal .ri-location-grid .combo-option {
    padding: 10px;
  }
  :root[data-theme="dark"] #modal .ri-location-grid .combo-panel {
    border-bottom-color: #253244;
  }
}

/* Reporte servicio */
#sec_info .srv-combo-field {
  position: relative;
}
#sec_info .srv-combo-trigger {
  position: relative;
  display: block;
  width: 100%;
  padding: 0;
  border: 0;
  background: transparent;
  cursor: pointer;
}
#sec_info .srv-combo-trigger .input,
#sec_info .srv-combo-display {
  width: 100%;
  padding-right: 58px;
  cursor: pointer;
}
#sec_info .srv-combo-actions {
  position: absolute;
  top: 50%;
  right: 15px;
  transform: translateY(-50%);
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: var(--muted);
}
#sec_info .srv-combo-clear {
  inline-size: 24px;
  block-size: 24px;
  border: 0;
  background: transparent;
  border-radius: 999px;
  color: inherit;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
}
#sec_info .srv-combo-clear:hover {
  background: color-mix(in srgb, var(--line) 72%, transparent);
}
#sec_info .srv-combo-chevron {
  width: 8px;
  height: 8px;
  border-right: 2px solid currentColor;
  border-bottom: 2px solid currentColor;
  transform: translateY(-60%) rotate(45deg);
}
#sec_info .srv-combo-panel,
.srv-combo-panel.srv-combo-floating {
  border: 1px solid rgba(15, 23, 42, 0.08);
  border-bottom: 0;
  border-radius: 12px 12px 0 0;
  background: #fff;
  box-shadow: 0 2px 10px rgba(15, 23, 42, 0.06);
}
#sec_info .srv-combo-panel {
  position: absolute;
  bottom: calc(100% - 1px);
  left: 0;
  right: 0;
  z-index: 35;
  max-height: 220px;
  overflow: auto;
  padding: 8px;
}
#sec_info .srv-combo-panel[hidden],
.srv-combo-panel.srv-combo-floating[hidden] {
  display: none !important;
}
.srv-combo-panel.srv-combo-floating {
  display: flex;
  flex-direction: column;
  overflow: hidden;
  overscroll-behavior: contain;
  touch-action: pan-y;
}
#sec_info .srv-combo-field.is-open .srv-combo-trigger .input {
  border-top-left-radius: 0;
  border-top-right-radius: 0;
  border-top-color: transparent;
}
#sec_info .srv-combo-toolbar,
.srv-combo-panel.srv-combo-floating .srv-combo-toolbar {
  position: relative;
  padding: 10px;
  margin-bottom: 6px;
  border-bottom: 1px solid var(--line);
  background: #fff;
  cursor: text;
}
.srv-combo-panel.srv-combo-floating .srv-combo-toolbar {
  flex: 0 0 auto;
}
#sec_info .srv-combo-search-icon,
.srv-combo-panel.srv-combo-floating .srv-combo-search-icon {
  position: absolute;
  left: 14px;
  top: 50%;
  width: 16px;
  height: 16px;
  transform: translateY(-50%);
  z-index: 2;
  color: var(--muted);
  pointer-events: none;
  cursor: text;
}
#sec_info .srv-combo-search,
.srv-combo-panel.srv-combo-floating .srv-combo-search {
  width: 100%;
  padding-left: 38px;
}
#sec_info .srv-combo-list {
  display: grid;
  gap: 4px;
  padding: 0;
  max-height: 260px;
  overflow: auto;
}
.srv-combo-panel.srv-combo-floating .srv-combo-list {
  flex: 1 1 auto;
  min-height: 0;
  display: grid;
  gap: 4px;
  padding: 0 8px 8px;
  max-height: none;
  overflow: auto;
  -webkit-overflow-scrolling: touch;
  overscroll-behavior: contain;
  touch-action: pan-y;
}
#sec_info .srv-combo-option,
#sec_info .srv-combo-empty,
.srv-combo-panel.srv-combo-floating .srv-combo-option,
.srv-combo-panel.srv-combo-floating .srv-combo-empty {
  width: 100%;
  border: 0;
  background: transparent;
  color: #0f172a;
  text-align: left;
  padding: 9px 10px;
  border-radius: 10px;
  font: inherit;
}
#sec_info .srv-combo-option,
.srv-combo-panel.srv-combo-floating .srv-combo-option {
  cursor: pointer;
}
#sec_info .srv-combo-option:hover,
#sec_info .srv-combo-option.is-active,
.srv-combo-panel.srv-combo-floating .srv-combo-option:hover,
.srv-combo-panel.srv-combo-floating .srv-combo-option.is-active {
  background: #eff6ff;
}
#sec_info .srv-combo-empty,
.srv-combo-panel.srv-combo-floating .srv-combo-empty {
  color: #64748b;
}
:root[data-theme="light"] #sec_info .srv-combo-option:hover,
:root[data-theme="light"] #sec_info .srv-combo-option.is-active,
:root[data-theme="light"] .srv-combo-panel.srv-combo-floating .srv-combo-option:hover,
:root[data-theme="light"] .srv-combo-panel.srv-combo-floating .srv-combo-option.is-active {
  background: #edf4ff;
}
:root[data-theme="dark"] #sec_info .srv-combo-panel,
:root[data-theme="dark"] .srv-combo-panel.srv-combo-floating {
  background: #0c1520;
  border-color: #223148;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.18);
}
:root[data-theme="dark"] #sec_info .srv-combo-toolbar,
:root[data-theme="dark"] .srv-combo-panel.srv-combo-floating .srv-combo-toolbar {
  background: #0c1520;
  border-bottom-color: #223148;
}
:root[data-theme="dark"] #sec_info .srv-combo-option,
:root[data-theme="dark"] #sec_info .srv-combo-empty,
:root[data-theme="dark"] .srv-combo-panel.srv-combo-floating .srv-combo-option,
:root[data-theme="dark"] .srv-combo-panel.srv-combo-floating .srv-combo-empty {
  color: #e5eefb;
}
:root[data-theme="dark"] #sec_info .srv-combo-option:hover,
:root[data-theme="dark"] #sec_info .srv-combo-option.is-active,
:root[data-theme="dark"] .srv-combo-panel.srv-combo-floating .srv-combo-option:hover,
:root[data-theme="dark"] .srv-combo-panel.srv-combo-floating .srv-combo-option.is-active {
  background: #1d2b40;
}
:root[data-theme="dark"] #sec_info .srv-combo-empty,
:root[data-theme="dark"] .srv-combo-panel.srv-combo-floating .srv-combo-empty {
  color: #93a4bb;
}
@media (max-width: 680px) {
  #sec_info .srv-combo-panel {
    position: absolute;
    bottom: calc(100% - 1px);
    margin-top: 0;
  }
}
@media (max-width: 720px) {
  #sec_info .srv-combo-field.is-open {
    position: relative;
    z-index: 1000;
    isolation: isolate;
  }
  #sec_info .srv-combo-panel {
    z-index: 1001;
    transform: translateZ(0);
    -webkit-transform: translateZ(0);
    backface-visibility: hidden;
    -webkit-backface-visibility: hidden;
  }
}
@supports (-webkit-touch-callout: none) {
  #sec_info .srv-combo-field.is-open {
    position: relative;
    z-index: 1000;
    isolation: isolate;
  }
  #sec_info .srv-combo-panel {
    z-index: 1001;
    transform: translateZ(0);
    -webkit-transform: translateZ(0);
    backface-visibility: hidden;
    -webkit-backface-visibility: hidden;
  }
}
