/* Small shared UX refinements; existing clinic theme variables remain in charge. */
button:focus-visible,
input:focus-visible,
select:focus-visible,
textarea:focus-visible,
summary:focus-visible,
a:focus-visible,
[tabindex]:focus-visible {
  outline: 3px solid var(--accent, #146b60);
  outline-offset: 3px;
}
header :focus-visible { outline-color: #fff; }
.searchBox:focus-within,
.brandBox:focus-within {
  border-color: var(--muted, #727970);
  box-shadow: none;
}
.searchBox input:focus-visible,
.brandBox input:focus-visible {
  outline: none;
}
.btn {
  min-height: 36px;
  padding: 8px 12px;
  border-radius: 10px;
  line-height: 1.25;
}
.iconBtn { border-radius: 10px; }
.formActions { align-items: center; flex-wrap: wrap; overflow: visible; }
.publishStatus {
  flex: 0 0 100%;
  margin: 0;
  font-size: 13px;
  line-height: 1.5;
  overflow-wrap: anywhere;
}
.publishStatus:empty { display: none; }
.publishStatus[data-state="pending"] { color: var(--muted, #666); }
.publishStatus[data-state="success"] { color: var(--accent-ink, #146b60); }
.publishStatus[data-state="error"] { color: var(--danger, #a83a30); }
#publishBtn:disabled { cursor: wait; opacity: .7; }
.paneHead { flex-shrink: 0; overflow: visible; }
.searchRow { flex-wrap: wrap; }
.searchBox { min-width: 160px; }
.searchBox input { min-width: 0; }
.list, .dropzone { min-height: 0; }
.list > .card, #dbSentinel { flex-shrink: 0; }
.empty .btn { margin-top: 12px; }
.filterRanges {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: 12px;
  align-items: stretch;
}
.filterRanges .thcRow { display: block; }
.rangeGroup {
  min-width: 0;
  padding: 9px 11px;
  border: 1px solid var(--line, #e5e1d6);
  border-radius: 12px;
  background: var(--accent-soft, #e4efec);
}
.rangeHead {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 8px;
  margin-bottom: 7px;
}
.rangeTitle {
  color: var(--ink, #22302c);
  font-size: 11px;
  font-weight: 800;
  letter-spacing: .045em;
  text-transform: uppercase;
}
.rangeHint { color: var(--muted, #6b7a73); font-size: 10.5px; }
.rangeInputs { display: block; min-width: 0; }
.rangeField { display: flex; align-items: center; gap: 5px; min-width: 0; color: var(--muted, #6b7a73); font-size: 11px; }
.rangeField span { white-space: nowrap; }
.rangeField input {
  width: 100%;
  min-width: 0;
  height: 32px;
  padding: 5px 8px;
  border: 1px solid var(--line, #e5e1d6);
  border-radius: 8px;
  background: var(--panel, #fff);
  font-size: 13px;
  font-variant-numeric: tabular-nums;
}
.rangeField input:focus { outline: none; border-color: var(--accent, #146b60); box-shadow: 0 0 0 2px var(--accent-soft, #e4efec); }
.thcPresets { display: flex; align-items: center; flex-wrap: wrap; gap: 5px; margin-top: 7px; }
.thcPresets .chip { padding: 3px 9px; font-size: 10.5px; }
.priceNote { margin-top: 3px; color: var(--muted, #6b7a73); font-size: 10.5px; line-height: 1.35; }
.thcVal { min-width: 0; text-align: left; font-size: 10.5px; color: var(--muted, #6b7a73); font-weight: 600; }
.dualReadouts { display: flex; justify-content: space-between; gap: 8px; margin: 0 1px 2px; }
.dualBound {
  color: var(--accent-ink, #146b60);
  font-size: 11px;
  font-weight: 750;
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}
.dualBoundMax { text-align: right; }
.dualRange { position: relative; height: 44px; margin: 0 4px; touch-action: pan-y; }
.dualTrack { position: absolute; left: 12.5px; right: 12.5px; top: 19px; height: 6px; }
.dualRail, .dualFill { position: absolute; top: 0; height: 6px; border-radius: 99px; }
.dualRail { inset: 0; background: #d7e1db; box-shadow: inset 0 1px 2px rgba(18,53,47,.1); }
.dualFill { left: 0; width: 100%; background: var(--accent, #146b60); }
.dualRange input[type="range"] {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 44px;
  margin: 0;
  padding: 0;
  appearance: none;
  -webkit-appearance: none;
  background: transparent;
  pointer-events: none;
  touch-action: pan-y;
}
.dualRange input[type="range"]::-webkit-slider-runnable-track {
  height: 6px;
  border: 0;
  background: transparent;
}
.dualRange input[type="range"]::-moz-range-track {
  height: 6px;
  border: 0;
  background: transparent;
}
.dualRange input[type="range"]::-webkit-slider-thumb {
  width: 25px;
  height: 25px;
  margin-top: -9.5px;
  border: 3px solid var(--panel, #fff);
  border-radius: 50%;
  background: var(--accent, #146b60);
  box-shadow: 0 1px 4px rgba(18,53,47,.26), 0 0 0 1px rgba(14,82,72,.32);
  appearance: none;
  -webkit-appearance: none;
  pointer-events: auto;
  cursor: grab;
}
.dualRange input[type="range"]::-moz-range-thumb {
  width: 19px;
  height: 19px;
  border: 3px solid var(--panel, #fff);
  border-radius: 50%;
  background: var(--accent, #146b60);
  box-shadow: 0 1px 4px rgba(18,53,47,.26), 0 0 0 1px rgba(14,82,72,.32);
  pointer-events: auto;
  cursor: grab;
}
.dualRange input[type="range"]:active::-webkit-slider-thumb { cursor: grabbing; }
.dualRange input[type="range"]:active::-moz-range-thumb { cursor: grabbing; }
.dualRange input[type="range"]:focus-visible { outline: none; }
.dualRange input[type="range"]:focus-visible::-webkit-slider-thumb {
  box-shadow: 0 0 0 4px var(--accent-soft, #e4efec), 0 0 0 6px var(--accent, #146b60);
}
.dualRange input[type="range"]:focus-visible::-moz-range-thumb {
  box-shadow: 0 0 0 4px var(--accent-soft, #e4efec), 0 0 0 6px var(--accent, #146b60);
}
.dualRange input[type="range"]:disabled::-webkit-slider-thumb {
  background: #9eaaa3;
  cursor: not-allowed;
}
.dualRange input[type="range"]:disabled::-moz-range-thumb {
  background: #9eaaa3;
  cursor: not-allowed;
}
.dualActions { display: flex; align-items: center; gap: 6px; margin-top: 2px; }
.dualActions .chip { padding: 3px 9px; font-size: 10.5px; }
.dualRange input[type="range"]:disabled { cursor: not-allowed; }
.rangeGroup:has(.dualRange input:disabled) .dualBound { color: var(--muted, #6b7a73); }
.rangeGroup:has(.dualRange input:disabled) .dualFill { background: #9eaaa3; }
.actionMenu { position: relative; flex-shrink: 0; }
.actionMenu[open] { z-index: 20; }
.actionMenu > summary {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  list-style: none;
  cursor: pointer;
  user-select: none;
}
.actionMenu > summary::-webkit-details-marker { display: none; }
.actionMenuItems {
  position: absolute;
  top: calc(100% + 6px);
  right: 0;
  z-index: 30;
  display: flex;
  flex-direction: column;
  gap: 2px;
  width: 200px;
  max-width: calc(100vw - 32px);
  max-height: min(60vh, 360px);
  overflow-y: auto;
  padding: 6px;
  border: 1px solid var(--line, #e5e1d6);
  border-radius: 12px;
  background: var(--panel, #fff);
  box-shadow: 0 8px 24px rgba(18, 53, 47, .16);
}
.actionMenu:not([open]) > .actionMenuItems { display: none; }
.actionMenuItems .btn,
.actionMenuItems .btn.primary {
  width: 100%;
  border-color: transparent;
  background: transparent;
  color: var(--ink, #22302c);
  text-align: left;
  white-space: nowrap;
}
.actionMenuItems .btn:hover { background: var(--accent-soft, #e4efec); }
.actionMenuItems .btn.danger { color: var(--danger, #a83a30); }
.actionMenuItems .btn:focus-visible { outline-offset: -3px; }
.links a[role="button"] { border-radius: 4px; }
@media (max-width: 900px) {
  .formActions { overflow: visible; gap: 6px; }
  .pane { min-height: 460px; }
}
@media (max-width: 600px) {
  header .tabs { width: 100%; margin-left: 0; }
  header .tab { flex: 1; padding: 8px 10px; }
  .paneHead, .filters { padding-left: 12px; padding-right: 12px; }
  .list, .dropzone { padding-left: 12px; padding-right: 12px; }
  .btn { min-height: 40px; }
  .brandBox { flex: 1; min-width: 120px; }
  .logo .dot { flex-shrink: 0; }
  .cName { overflow-wrap: anywhere; }
  .card .cActions { gap: 4px; }
  .filterRanges { grid-template-columns: minmax(0, 1fr); gap: 8px; }
  .filters .filterRanges { display: none; }
  .filters.open .filterRanges { display: grid; }
  .filters.open .filterRanges .thcRow { display: block; }
  .rangeGroup { padding: 9px; }
  .dualRange { height: 48px; }
  .dualRange input[type="range"] { height: 48px; }
  .dualTrack { top: 21px; left: 14px; right: 14px; }
  .dualRange input[type="range"]::-webkit-slider-thumb { width: 28px; height: 28px; margin-top: -11px; }
  .dualRange input[type="range"]::-moz-range-thumb { width: 22px; height: 22px; }
}
@media (max-width: 900px) {
  .filters .filterRanges { display: none; }
  .filters.open .filterRanges { display: grid; grid-template-columns: minmax(0, 1fr); }
  .filters.open .filterRanges .thcRow { display: block; }
}
