:root {
  /* Цветовая схема в стиле кондиционирования и охлаждения */
  --primary: #0088cc; /* Голубой цвет охлаждения */
  --primary-hover: #00aaff;
  --primary-light: #e6f7ff;
  --accent: #00cc88; /* Зеленый цвет свежести */
  --accent-hover: #00ee99;
  --accent-light: #e6fff7;
  --secondary: #3366ff; /* Синий цвет неба */
  --secondary-hover: #5588ff;
  --text: #003366;
  --text-light: #6699cc;
  --text-dark: #001933;
  --border: #99ccff;
  --border-dark: #66aaff;
  --white: #ffffff;
  --bg-light: #f0f9ff;
  --bg-card: #ffffff;
  --bg-frost: #e6f2ff; /* Цвет инея */
  --bg-ice: #f0f8ff; /* Цвет льда */
  --shadow: rgba(0, 136, 204, 0.1);
  --shadow-hover: rgba(0, 136, 204, 0.15);
}

/* SVG background с тематикой кондиционирования и воздушных потоков */
body::before {
  content: '';
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-image: url("data:image/svg+xml,%3Csvg width='100' height='100' viewBox='0 0 100 100' xmlns='http://www.w3.org/2000/svg'%3E%3Cdefs%3E%3ClinearGradient id='a' x1='0%25' y1='0%25' x2='100%25' y2='100%25'%3E%3Cstop offset='0%25' stop-color='%230088cc' stop-opacity='0.03'/%3E%3Cstop offset='100%25' stop-color='%2300cc88' stop-opacity='0.03'/%3E%3C/linearGradient%3E%3C/defs%3E%3Cg fill='url(%23a)'%3E%3Cpath d='M0 0h100v100H0z'/%3E%3C/g%3E%3Cg fill='%230088cc' fill-opacity='0.05'%3E%3Ccircle cx='20' cy='20' r='15'/%3E%3Ccircle cx='80' cy='80' r='10'/%3E%3Ccircle cx='50' cy='50' r='8'/%3E%3Ccircle cx='30' cy='70' r='12'/%3E%3Ccircle cx='70' cy='30' r='9'/%3E%3C/g%3E%3Cpath d='M0 50 Q 25 40, 50 50 T 100 50' stroke='%2300cc88' stroke-width='0.5' stroke-opacity='0.1' fill='none'/%3E%3Cpath d='M0 30 Q 25 20, 50 30 T 100 30' stroke='%230088cc' stroke-width='0.5' stroke-opacity='0.1' fill='none'/%3E%3Cpath d='M0 70 Q 25 60, 50 70 T 100 70' stroke='%233366ff' stroke-width='0.5' stroke-opacity='0.1' fill='none'/%3E%3C/svg%3E");
  background-size: 400px 400px;
  z-index: -1;
  pointer-events: none;
}

/* Основной фон с градиентом прохлады */
body {
  background: linear-gradient(135deg, var(--bg-frost) 0%, var(--bg-light) 50%, var(--bg-ice) 100%);
  min-height: 100vh;
  margin: 0 auto;
  color: var(--text);
  font-family: 'Segoe UI', 'Roboto', 'Helvetica Neue', Arial, sans-serif;
  line-height: 1.6;
  scrollbar-width: thin;
  scrollbar-color: var(--primary) var(--bg-light);
}

/* Кастомный скроллбар */
::-webkit-scrollbar {
  width: 12px;
}

::-webkit-scrollbar-track {
  background: var(--bg-light);
  border-radius: 6px;
}

::-webkit-scrollbar-thumb {
  background: linear-gradient(to bottom, var(--primary), var(--accent));
  border-radius: 6px;
  border: 2px solid var(--bg-light);
}

::-webkit-scrollbar-thumb:hover {
  background: linear-gradient(to bottom, var(--primary-hover), var(--accent-hover));
}

/* Общие стили таблиц */
.bodyline {
  background-color: var(--white);
  border: 2px solid var(--border);
  border-radius: 12px;
  box-shadow: 0 4px 20px var(--shadow);
}

.forumline {
  background: linear-gradient(135deg, var(--white), var(--bg-frost));
  border: 2px solid var(--border);
  border-radius: 10px;
  overflow: hidden;
  transition: all 0.3s ease;
}

.forumline:hover {
  box-shadow: 0 6px 25px var(--shadow-hover);
  transform: translateY(-2px);
  border-color: var(--primary);
}

/* Строки таблиц */
.row1, .row2, .row3 {
  background-color: var(--white);
  transition: all 0.2s ease;
}

.row1:hover, .row2:hover {
  background-color: var(--primary-light);
}

.row3 {
  background-color: var(--bg-frost);
}

.row3:hover {
  background-color: var(--accent-light);
}

.inputrow {
  background: linear-gradient(135deg, var(--primary-light), var(--accent-light));
  border-top: 1px solid var(--border);
}

/* Ячейки с иконками */
td.rowpic {
  background: linear-gradient(to right, var(--primary-light), transparent);
  position: relative;
}

td.rowpic::before {
  content: '??';
  position: absolute;
  left: 10px;
  top: 50%;
  transform: translateY(-50%);
  opacity: 0.5;
}

/* Заголовки таблиц */
th {
  color: var(--white);
  font-size: 14px;
  font-weight: 600;
  background: linear-gradient(135deg, var(--primary), var(--secondary));
  padding: 14px 16px;
  text-align: left;
  position: relative;
  overflow: hidden;
}

th::after {
  content: '???';
  position: absolute;
  right: 16px;
  opacity: 0.7;
}

th::before {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
  animation: airflow 3s linear infinite;
}

@keyframes airflow {
  0% { left: -100%; }
  100% { left: 100%; }
}

/* Категории */
td.cat, td.catHead, td.catBottom, td.categorybar {
  background: linear-gradient(135deg, var(--primary), var(--primary-hover));
  color: var(--white);
  font-weight: 600;
  padding: 12px 16px;
  position: relative;
}

td.cat::before, td.catHead::before {
  content: '??';
  margin-right: 8px;
}

/* Заголовки */
.maintitle, h1, h2 {
  font-weight: 700;
  font-size: 24px;
  font-family: 'Segoe UI', 'Trebuchet MS', Verdana, sans-serif;
  color: var(--text-dark);
  line-height: 1.3;
  margin: 1em 0;
  padding-left: 20px;
  position: relative;
}

.maintitle::before, h1::before, h2::before {
  content: '??';
  position: absolute;
  left: 0;
  top: 50%;
  transform: translateY(-50%);
}

/* Ссылки */
a:link, a:visited {
  text-decoration: none;
  color: var(--primary);
  transition: all 0.2s ease;
  position: relative;
  font-weight: 500;
}

a:hover, a:active {
  color: var(--accent);
  text-decoration: none;
}

a:hover::after {
  content: '';
  position: absolute;
  bottom: -2px;
  left: 0;
  width: 100%;
  height: 2px;
  background: linear-gradient(to right, var(--primary), var(--accent));
  border-radius: 1px;
}

/* Ссылки форума */
a.forumlink, a.forumlink:visited {
  color: var(--secondary);
  font-weight: 600;
}

a.forumlink:hover {
  color: var(--accent-hover);
}

a.forumlink:hover::after {
  background: linear-gradient(to right, var(--secondary), var(--accent));
}

/* Текст сообщений */
.postbody {
  font-size: 14px;
  line-height: 1.7;
  color: var(--text);
}

a.postlink:link, a.postlink:visited {
  color: var(--primary);
}

a.postlink:hover {
  color: var(--accent);
}

/* Код и цитаты */
.code {
  font-family: 'Consolas', 'Monaco', 'Courier New', monospace;
  font-size: 13px;
  color: var(--text-dark);
  background: linear-gradient(135deg, var(--bg-frost), var(--white));
  border: 2px solid var(--border);
  border-radius: 8px;
  padding: 15px;
  margin: 10px 0;
  position: relative;
  overflow: hidden;
}

.code::before {
  content: '??';
  position: absolute;
  right: 10px;
  top: 10px;
  opacity: 0.3;
  font-size: 20px;
}

.quote {
  font-family: 'Segoe UI', Verdana, Arial, sans-serif;
  font-size: 13px;
  color: var(--text);
  line-height: 1.6;
  background: linear-gradient(135deg, var(--accent-light), var(--white));
  border: 2px solid var(--accent);
  border-radius: 8px;
  padding: 15px;
  margin: 10px 0;
  position: relative;
}

.quote::before {
  content: '??';
  position: absolute;
  left: -10px;
  top: -10px;
  background: var(--white);
  border-radius: 50%;
  width: 24px;
  height: 24px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 12px;
  border: 2px solid var(--accent);
  box-shadow: 0 2px 8px var(--shadow);
}

/* Формы */
input, textarea, select {
  color: var(--text-dark);
  font: normal 14px 'Segoe UI', Verdana, Arial, sans-serif;
  background: var(--white);
  border: 2px solid var(--border);
  border-radius: 6px;
  padding: 10px 12px;
  transition: all 0.3s ease;
}

input:focus, textarea:focus, select:focus {
  outline: none;
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(0, 136, 204, 0.2);
}

textarea {
  min-height: 100px;
  resize: vertical;
  background-image: linear-gradient(transparent 39px, var(--border) 40px);
  background-size: 100% 40px;
  line-height: 40px;
  background-attachment: local;
  padding-left: 15px;
}

/* Кнопки */
input.button {
  background: linear-gradient(135deg, var(--primary), var(--secondary));
  color: var(--white);
  font-size: 14px;
  font-weight: 600;
  border: none;
  border-radius: 6px;
  padding: 12px 24px;
  cursor: pointer;
  transition: all 0.3s ease;
  position: relative;
  overflow: hidden;
}

input.button::before {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.3), transparent);
  transition: left 0.5s ease;
}

input.button:hover::before {
  left: 100%;
}

input.button:hover {
  background: linear-gradient(135deg, var(--primary-hover), var(--secondary-hover));
  transform: translateY(-2px);
  box-shadow: 0 4px 15px rgba(0, 136, 204, 0.3);
}

/* Дополнительные эффекты холода */
.forumline::after {
  content: '';
  position: absolute;
  top: 0;
  right: 0;
  width: 20px;
  height: 100%;
  background: linear-gradient(to left, rgba(0, 136, 204, 0.1), transparent);
  pointer-events: none;
}

/* Температурные индикаторы (для рейтингов или статусов) */
.temp-hot {
  color: #ff6666;
  background: linear-gradient(135deg, #fff0f0, #ffe6e6);
}

.temp-cool {
  color: var(--primary);
  background: linear-gradient(135deg, var(--primary-light), #e6f2ff);
}

.temp-optimal {
  color: var(--accent);
  background: linear-gradient(135deg, var(--accent-light), #e6fff7);
}

/* Иконки для разных разделов */
[class*="cooling"]::before { content: '?? '; }
[class*="ventilation"]::before { content: '?? '; }
[class*="installation"]::before { content: '?? '; }
[class*="maintenance"]::before { content: '??? '; }
[class*="repair"]::before { content: '? '; }

/* Адаптивность */
@media (max-width: 768px) {
  body {
    max-width: 95%;
    padding: 10px;
  }
  
  body::before {
    background-size: 300px 300px;
  }
  
  .maintitle, h1, h2 {
    font-size: 20px;
    padding-left: 30px;
  }
  
  th, td.cat, td.catHead, td.catBottom {
    padding: 10px 12px;
  }
  
  .forumline {
    border-radius: 8px;
  }
  
  input.button {
    padding: 10px 20px;
  }
}

/* Анимация пузырьков воздуха (для интерактивных элементов) */
@keyframes bubble {
  0% {
    transform: translateY(0) scale(1);
    opacity: 0;
  }
  50% {
    opacity: 0.3;
  }
  100% {
    transform: translateY(-20px) scale(1.2);
    opacity: 0;
  }
}

.bubble-effect::after {
  content: '0';
  position: absolute;
  color: var(--primary);
  animation: bubble 2s ease-in-out infinite;
  font-size: 8px;
}

/* Стили для показателей температуры */
.temp-display {
  font-family: 'Courier New', monospace;
  font-weight: bold;
  background: linear-gradient(135deg, #001933, #003366);
  color: var(--white);
  padding: 5px 10px;
  border-radius: 4px;
  display: inline-block;
  border: 1px solid var(--border);
}

.temp-display::after {
  content: '°C';
  font-size: 0.8em;
  margin-left: 2px;
}

/* Стили для системных сообщений */
.system-message {
  background: linear-gradient(135deg, var(--primary-light), var(--accent-light));
  border-left: 4px solid var(--primary);
  border-radius: 0 8px 8px 0;
  padding: 12px 16px;
  margin: 10px 0;
  position: relative;
}

.system-message::before {
  content: '??';
  position: absolute;
  left: -25px;
  top: 50%;
  transform: translateY(-50%);
  background: var(--white);
  border-radius: 50%;
  width: 20px;
  height: 20px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 10px;
  border: 2px solid var(--primary);
}