/* core-ui.css — стили для плагинов «Умная Смета» v2.0 */

/* ===== Плагин-вкладки (уже используют .tab-btn) ===== */

/* ===== Секции плагинов в карточке комнаты ===== */
.plugin-room-section {
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: 8px;
  margin-bottom: 10px;
  overflow: hidden;
}
.plugin-room-section-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 14px;
  background: var(--bg-card-2);
  cursor: pointer;
  user-select: none;
  font-size: 14px;
  font-weight: 600;
  color: var(--text-strong);
  gap: 8px;
}
.plugin-room-section-head:active {
  background: var(--bg-hover);
}
.plugin-room-section-body {
  padding: 12px 14px;
  border-top: 1px solid var(--border);
}
.plugin-room-section.collapsed .plugin-room-section-body {
  display: none;
}
.plugin-room-section.collapsed .plugin-room-section-head .chevron {
  transform: rotate(-90deg);
}

/* ===== Электрика / точки ===== */
.ep-point {
  cursor: pointer;
}
.ep-point:hover {
  opacity: 0.85;
}
.ep-legend {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  font-size: 12px;
  color: var(--text-2);
  margin-top: 8px;
}
.ep-legend span {
  display: inline-flex;
  align-items: center;
  gap: 4px;
}

/* ===== Таблица расчёта кабеля ===== */
.cable-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 13px;
  margin-top: 10px;
}
.cable-table th,
.cable-table td {
  padding: 6px 8px;
  border-bottom: 1px solid var(--border);
  text-align: left;
}
.cable-table th {
  font-size: 11px;
  color: var(--text-3);
  text-transform: uppercase;
}
.cable-table td.num {
  text-align: right;
  font-variant-numeric: tabular-nums;
}
.cable-table tfoot td {
  font-weight: 600;
  border-top: 1px solid var(--border);
  padding-top: 8px;
}

/* ===== Кнопки плагинов в top-actions ===== */
#pane-obmer .top-actions [data-plugin-btn] {
  flex: 1;
  min-width: 120px;
}


/* ===== Полировка: много вкладок на телефоне ===== */
.tab-bar {
  display: flex !important;
  flex-wrap: nowrap;
  overflow-x: auto;
  overflow-y: hidden;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
  grid-template-columns: none !important;
}
.tab-bar::-webkit-scrollbar { display: none; }
.tab-bar .tab-btn {
  flex: 1 0 auto;
  min-width: 56px;
  max-width: 88px;
  padding: 6px 6px 5px;
  font-size: 10px;
}
.tab-bar .tab-btn .ico { font-size: 18px; }
@media (max-width: 400px) {
  .tab-bar .tab-btn { min-width: 48px; font-size: 9px; padding: 6px 4px 4px; }
  .tab-bar .tab-btn .ico { font-size: 17px; }
  .tab-bar .tab-btn span:not(.ico) {
    max-width: 52px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
  }
}

/* ===== Полировка: карточки модулей ===== */
.plugin-hint {
  font-size: 12px;
  color: var(--text-3);
  line-height: 1.4;
  margin: 0 0 10px;
}
