#cbg-prices-view { min-width: 0; }
.cbg-prices-layout .cbg-prices-card { grid-column: 1; grid-row: 1; }
.cbg-prices-layout .cbg-prices-filter-card {
  grid-column: 2;
  grid-row: 1;
  z-index: 2;
  max-height: none;
  overflow: visible;
}
.cbg-prices-card {
  min-width: 0;
  padding: 20px;
  border: 1px solid var(--price-line, #d7e5dc);
  border-radius: 20px;
  background: #fff;
  box-shadow: 0 14px 38px rgba(27,79,60,.07);
}
.cbg-prices-heading { display: flex; align-items: start; justify-content: space-between; flex-wrap: wrap; gap: 14px; }
.cbg-prices-heading-actions { display: flex; align-items: center; justify-content: flex-end; flex-wrap: wrap; gap: 10px; }
.cbg-prices-heading h2 { margin: 0; color: #194f3b; font-size: 1.25rem; }
.cbg-prices-heading p { margin: 5px 0 0; color: #63786f; font-size: .86rem; line-height: 1.5; }
.cbg-prices-demo {
  flex: 0 0 auto;
  padding: 5px 10px;
  border: 1px solid #dfb668;
  border-radius: 999px;
  background: #fff4dd;
  color: #765319;
  font-size: .78rem;
  font-weight: 800;
}
.cbg-prices-controls { display: flex; flex-direction: column; align-items: stretch; gap: 14px; margin-top: 18px; }
.cbg-prices-server-picker { display: grid; flex: 1 1 100%; width: 100%; max-width: none; min-width: 0; gap: 5px; }
.cbg-prices-controls label,.cbg-prices-category-filter > span { color: #4f6255; font-size: .88rem; font-weight: 700; }
.cbg-prices-name-filter,.cbg-prices-category-filter { display: grid; gap: 5px; min-width: 0; }
.cbg-prices-controls .cbg-prices-name-filter input { padding-right: 12px; }
.cbg-prices-category-buttons { display: grid; grid-template-columns: repeat(3,minmax(0,1fr)); gap: 6px; }
.cbg-prices-controls .cbg-prices-category-buttons button { min-width: 0; padding: 7px 4px; white-space: nowrap; }
.cbg-prices-controls .cbg-prices-category-buttons button[aria-pressed="true"] { background: #236b50; border-color: #236b50; color: #fff; }
.cbg-prices-combobox { position: relative; min-width: 0; }
.cbg-prices-controls input {
  min-width: 0;
  width: 100%;
  min-height: 40px;
  padding: 7px 42px 7px 12px;
  border: 1px solid #cbded2;
  border-radius: 10px;
  background: #fbfdfb;
  color: #263b2d;
  font: inherit;
}
.cbg-prices-controls input::-webkit-search-cancel-button { display: none; }
#cbg-prices-server-clear {
  position: absolute;
  top: 4px;
  right: 4px;
  width: 32px;
  min-height: 32px;
  padding: 0;
  border: 0;
  border-radius: 7px;
  background: transparent;
  color: #64776a;
  font-size: 1.3rem;
  line-height: 1;
}
.cbg-prices-server-options {
  position: absolute;
  z-index: 15;
  top: calc(100% + 5px);
  left: 0;
  right: 0;
  max-height: 294px;
  overflow-y: auto;
  padding: 5px;
  border: 1px solid #cbded2;
  border-radius: 11px;
  background: #fff;
  box-shadow: 0 14px 30px rgba(25,67,43,.17);
}
.cbg-prices-controls .cbg-prices-server-options button {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 10px;
  width: 100%;
  min-height: 40px;
  padding: 7px 10px;
  border: 0;
  border-radius: 8px;
  background: #fff;
  color: #294634;
  text-align: left;
  cursor: pointer;
}
.cbg-prices-controls .cbg-prices-server-options button:hover,.cbg-prices-controls .cbg-prices-server-options button.is-active,
.cbg-prices-controls .cbg-prices-server-options button[aria-selected="true"] { background: #eaf5ed; }
.cbg-prices-server-options strong { min-width: 0; overflow-wrap: anywhere; }
.cbg-prices-server-options span { min-width: 0; overflow-wrap: anywhere; color: #66776c; font-size: .78rem; }
.cbg-prices-server-empty { margin: 0; padding: 12px; color: #6c7d72; font-size: .86rem; text-align: center; }
.cbg-prices-controls button,.cbg-prices-status button,#cbg-prices-refresh {
  min-height: 40px;
  padding: 7px 15px;
  border: 1px solid #b9d4c8;
  border-radius: 10px;
  background: #fff;
  color: #236b50;
  font: inherit;
  font-weight: 700;
  cursor: pointer;
}
.cbg-prices-controls button:disabled,#cbg-prices-refresh:disabled { opacity: .5; cursor: wait; }
.cbg-prices-controls :focus-visible,.cbg-prices-status button:focus-visible,#cbg-prices-refresh:focus-visible {
  outline: 3px solid rgba(43,122,90,.28);
  outline-offset: 2px;
}
.cbg-prices-status {
  display: flex;
  align-items: center;
  justify-content: center;
  flex-wrap: wrap;
  gap: 10px;
  min-height: 130px;
  margin-top: 14px;
  padding: 18px;
  border-radius: 12px;
  background: #f7faf7;
  color: #526359;
  text-align: center;
}
.cbg-prices-status.is-error { background: #fff5f2; color: #884539; }
.cbg-prices-grid { position: relative; z-index: 1; max-width: 100%; margin-top: 12px; overflow-x: auto; border: 1px solid #e7eee8; border-radius: 12px; }
.cbg-prices-table { width: 100%; border-collapse: collapse; table-layout: fixed; color: #2f4035; font-size: 14px; }
.cbg-prices-table th,.cbg-prices-table td { height: 40px; padding: 7px 12px; border-bottom: 1px solid #edf1ee; vertical-align: middle; text-align: left; overflow-wrap: anywhere; }
.cbg-prices-table thead th { height: 36px; background: #f4f8f5; color: #5c6d61; font-size: 12px; font-weight: 700; }
.cbg-prices-table tbody tr:last-child > * { border-bottom: 0; }
.cbg-prices-table tbody tr:hover { background: #fbfdfb; }
.cbg-prices-table thead th:nth-child(1) { width: 24%; }
.cbg-prices-table thead th:nth-child(2) { width: 12%; }
.cbg-prices-table thead th:nth-child(3) { width: 10%; }
.cbg-prices-table thead th:nth-child(4) { width: 20%; }
.cbg-prices-table thead th:nth-child(5) { width: 12%; }
.cbg-prices-table thead th:nth-child(6) { width: 22%; }
.cbg-prices-row th { color: #245238; font-weight: 700; }
.cbg-prices-price,.cbg-prices-time { font-variant-numeric: tabular-nums; white-space: nowrap; }
.cbg-prices-price { color: #91502f; }
.cbg-prices-time { color: #647368; }
.cbg-prices-value { color: #91502f; font-weight: 700; }
.cbg-prices-trend { min-height: 28px; padding: 3px 8px; border: 1px solid #c8ddce; border-radius: 7px; background: #f5fbf6; color: #266146; font: inherit; font-weight: 700; cursor: pointer; white-space: nowrap; }
.cbg-prices-trend:hover { background: #e7f3e9; }
.cbg-prices-trend:disabled { border-color: #dce5df; background: #f4f6f4; color: #7c8a80; cursor: not-allowed; }
.cbg-prices-trend-hint { display: block; margin-top: 3px; color: #738177; font-size: 11px; white-space: nowrap; }
.cbg-prices-trend:focus-visible,.cbg-prices-history-dialog button:focus-visible,.cbg-prices-history-point:focus-visible { outline: 3px solid rgba(43,122,90,.28); outline-offset: 2px; }
.cbg-prices-catalog-status { margin: 10px 0 0; color: #63786f; font-size: 12px; line-height: 1.5; }
.cbg-prices-catalog-status.is-error { color: #884539; }
.cbg-prices-note { margin: 17px 0 0; color: #6c7d72; font-size: .78rem; line-height: 1.5; }
.cbg-prices-history-dialog { width: min(820px,calc(100vw - 28px)); max-width: none; max-height: calc(100dvh - 28px); margin: auto; padding: 0; overflow: auto; border: 1px solid #d7e5dc; border-radius: 16px; background: #fff; box-shadow: 0 22px 70px rgba(25,57,34,.28); }
.cbg-prices-history-dialog::backdrop { background: rgba(24,45,31,.46); }
.cbg-prices-history-panel { padding: 20px; }
.cbg-prices-history-panel > header { display: flex; align-items: flex-start; justify-content: space-between; gap: 16px; }
.cbg-prices-history-panel h2,.cbg-prices-history-panel p { margin: 0; }
.cbg-prices-history-panel h2 { color: #24563a; font-size: 21px; line-height: 1.3; }
.cbg-prices-history-eyebrow { margin-bottom: 3px !important; color: #718077; font-size: 12px; }
.cbg-prices-history-panel button { min-height: 34px; padding: 5px 11px; border: 1px solid #c7d8cb; border-radius: 9px; background: #f7fbf8; color: #245b37; font: inherit; font-weight: 700; cursor: pointer; }
#cbg-prices-history-close { flex: 0 0 auto; white-space: nowrap; }
.cbg-prices-history-ranges { display: flex; flex-wrap: wrap; gap: 7px; margin-top: 16px; }
.cbg-prices-history-ranges button[aria-pressed="true"] { border-color: #568e68; background: #deeee2; }
.cbg-prices-history-state { display: flex; align-items: center; justify-content: center; gap: 10px; min-height: 250px; color: #627168; text-align: center; }
.cbg-prices-history-chart { width: 100%; min-height: 250px; border: 1px solid #e4ece6; border-radius: 12px; overflow: hidden; }
.cbg-prices-history-chart svg { display: block; width: 100%; height: auto; }
.cbg-prices-history-grid { stroke: #e7eee9; stroke-width: 1; }
.cbg-prices-history-axis { fill: #708078; font-size: 11px; }
.cbg-prices-history-line { fill: none; stroke: #257459; stroke-width: 2.5; stroke-linecap: round; stroke-linejoin: round; }
.cbg-prices-history-dot { fill: #257459; stroke: #fff; stroke-width: 2; pointer-events: none; }
.cbg-prices-history-point { fill: transparent; cursor: pointer; }
.cbg-prices-history-details { margin-top: 10px; color: #536b58; font-size: 12px; }
.cbg-prices-history-details summary { cursor: pointer; font-weight: 700; }
.cbg-prices-history-details ol { max-height: 130px; margin: 7px 0 0; padding-left: 24px; overflow-y: auto; }
.cbg-prices-history-details li { padding: 3px 0; overflow-wrap: anywhere; }
.cbg-prices-history-tooltip { position: fixed; z-index: 2; width: max-content; max-width: min(320px,calc(100vw - 48px)); padding: 7px 10px; border-radius: 8px; background: #263d30; color: #fff; font-size: 12px; overflow-wrap: anywhere; pointer-events: none; visibility: hidden; }
.cbg-prices-history-tooltip.is-visible { visibility: visible; }
.cbg-prices-history-window { margin-top: 8px !important; color: #718077; font-size: 12px; }
@media (max-width: 700px) { .cbg-prices-table { min-width: 680px; font-size: 13px; } }
@media (max-width: 1100px) {
  .cbg-prices-layout .cbg-prices-filter-card { order: 1; width: 100%; box-sizing: border-box; }
  .cbg-prices-layout .cbg-prices-card { order: 2; width: 100%; box-sizing: border-box; min-width: 0; }
}
@media (max-width: 390px) {
  .cbg-prices-card { padding: 15px; border-radius: 16px; }
  .cbg-prices-heading { flex-wrap: wrap; }
  .cbg-prices-controls { flex-wrap: wrap; }
  .cbg-prices-history-panel { padding: 14px; }
}
