﻿/* === Общие стили === */
body {
  font-family: Arial, sans-serif;
  margin: 0;
  padding: 0;
  background-color: #f9f9f9;
}

#root {
  width: auto;
  margin: 0 auto;
}

.entrances-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 20px;
  align-items: flex-start;
}

/* === Подъезды === */
.pod-block {
  display: inline-block;
  vertical-align: top;
  margin: 0 8px 16px 0;
  border: 3px solid #ccc;  /* возвращаем рамку */
  padding: 10px;
  border-radius: 6px;
  background-color: #fff;
}

/* === Строки этажей === */
.floor-row {
  display: flex;
  align-items: flex-start;
  margin-bottom: 5px;
  position: relative;
}

.floor-number {
  font-size: 16px;
  width: 30px;
  font-weight: bold;
  margin-right: 10px;
  text-align: center;
}

/* Контейнер квартир */
.floor-item-container {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  flex-grow: 1;
  align-items: flex-start;
}

/* === Квартира (ячейка) === */
.floor-item {
  min-width: 30px;
  height: 40px;
  display: flex;
  flex-direction: column;
  justify-content: flex-start;
  align-items: flex-start;
  padding: 2px;
  background-color: #f1f1f1;
  border: 1px solid #ddd;
  font-size: 12px;
  border-radius: 4px;
  cursor: pointer;
  overflow: hidden;
  transition: width 0.5s ease, opacity 0.5s ease, background-color 0.3s ease;
}

.floor-item:hover {
  transform: scale(1.05);
}

/* === Номер квартиры === */
.kv-background {
  font-size: 12px;
  font-weight: bold;
  align-self: flex-start;
  z-index: 1;
  opacity: 0.3;  /* прозрачность как раньше */
  transition: color 0.3s ease;
}

/* === Значение внутри квартиры === */
.value-span {
  position: relative;
  z-index: 2;
  align-self: flex-end;
  font-size: 12px;
}

/* === Итоги по этажу === */
.floor-total {
  background: none !important;
  border: none !important;
  box-shadow: none !important;
  width: auto !important;
  min-width: 60px;
  margin-left: auto;
  text-align: right;
  font-weight: 600;
  color: #333;
  transition: opacity 0.5s ease, color 0.5s ease;
  flex-shrink: 0;
}

.floor-total .value-span {
  display: inline-block;
  min-width: 60px;
  text-align: right;
}

/* === Итоги по стоякам и подъезду === */
.stand-container, .floor-total-container {
  display: flex;
  gap: 5px;
  flex-wrap: wrap;
}

.stand-container .floor-total, .floor-total-container .floor-total {
  min-width: 60px;
  flex-shrink: 0;
  text-align: right;
}

/* === Всплывающая подсказка === */
.fio-tooltip {
  position: absolute;
  background: rgba(0, 0, 0, 0.8);
  color: #fff;
  padding: 4px 6px;
  border-radius: 4px;
  font-size: 18px;
  pointer-events: none;
  display: none;
  z-index: 1000;
  max-width: 300px;
  white-space: pre-line;
}

/* === Кнопки выбора === */
#root button {
  cursor: pointer;
  border: 1px solid #ccc;
  padding: 5px 10px;
  font-size: 14px;
  transition: background-color 0.3s ease;
}

#root button.bg-blue-500 {
  background-color: #3b82f6;
  color: #fff;
}

/* === Цвет долга для итогов и номеров квартир === */
.green { color: green !important; }
.red { color: red !important; }
.black { color: black !important; }
#root button:nth-child(2) {
    display: none;
}
