/* ---------------------------------- *
     Элементы поста
 * ---------------------------------- */
.post-align, .post-br, .post-hr, .postImgAligned {
  display: block;
}

.sp-wrap, .post-hr {
  margin: 8px auto;
}

.c-wrap, .q-wrap {
  margin: 8px auto;
}

.c-wrap .c-head p {
  display: none; 
}

.c-body, .q, .sp-wrap, .sp-head, .sp-body {
  border: solid #C3CBD1;
  border-width: 1px 1px 1px 2px;
  word-spacing: normal;
}

.sp-body {
  border-bottom: 1px solid #C3CBD1;
}

.q-wrap .q-wrap, .sp-wrap .sp-wrap {
  margin: 2px auto 4px;
}

.c-head, .q-head {
  padding: 0 1px;
  font-size: 14px;
  color: #444444;
  text-align: left !important;
}

.c-body, .q, .sp-body {
  padding: 2px 6px;
}

.c-wrap, .q-wrap, .sp-wrap {
  width: 98%;
  clear: both;
  position: relative; 
}

/* Стили для цитат */
.q {
  position: relative;
  display: inline-block;
  max-width: 98%;
  color: #222;
  background: #F8F8F8;
  border-left: 5px solid #3c618b;
  border-radius: 6px;
  padding: 10px 15px;
  font-style: italic;
  box-shadow: 0 0 10px rgba(94, 94, 94, 0.3);
  margin: 5px 0;
  transition: max-height 0.3s ease-in-out;
}

/* Стили для заголовка цитаты */
.q-head {
  padding: 0 1px;
  font-size: 13px;
  color: #444444;
  margin-bottom: -5px;
}

/* Раскрытие цитаты */
.q.expanded {
  max-height: 1000px; 
  overflow-y: auto; 
}

/* Кнопка "Показать полностью" */
.show-more {
  position: absolute;
  bottom: 0;
  left: -2px;
  right: 0;
  width: calc(100% + 2px);
  background: rgba(192, 191, 191, 1);
  padding: 5px 0;
  border-radius: 0 0 6px 6px;
  cursor: pointer;
  z-index: 1;
  font-size: 12px;
  color: #0a0a0a;
  text-align: center;
  transition: opacity 0.3s ease-in-out, background 0.3s ease-in-out; 
}

/* Кнопка в развернутом состоянии */
.q.expanded .show-more {
  opacity: 0; 
}

/* Кнопка при наведении в развернутом состоянии */
.q.expanded .show-more:hover {
  opacity: 1; 
  background: rgba(66, 65, 65, 0.7); 
  transition: none; 
}

/* Эффект при наведении */
.show-more:hover {
  background: rgba(66, 65, 65, 1);
}

.post-align {
  margin: 8px auto;
}

.post-br {
  line-height: 12px;
}

.post-b {
  font-weight: bold;
}

.post-u {
  text-decoration: underline;
}

.post-i {
  font-style: italic;
}

.post-s {
  text-decoration: line-through;
}

/* ---------------------------------- *
     Блоки кода
 * ---------------------------------- */
.c-body {
  font-size: 15px;
  font-family: monospace, Courier, "Courier New";
  color: #006600;
  background: #FAFAFA;
  word-spacing: normal;
}

@media (max-width: 1920px) {
  .c-body {
    font-size: 13px;
  }
}

/* ---------------------------------- *
     Блоки цитат
 * ---------------------------------- */
.q {
  color: #2E2E2E;
}

.q {
  background: #FAFAFA;
}

.q .q {
  background: #F5F5F5;
}

.q .q .q {
  background: #FAFAFA;
}

.q .q .q .q {
  background: #F5F5F5;
}

.q .q .q .q .q {
  background: #FAFAFA;
}

.q .q .q .q .q .q {
  background: #F5F5F5;
}

.mod {
  font-family: sans-serif;
  font-size: 12px;
  color: #000000;
  line-height: 125%;
}

.exclamation {
  font-weight: bold;
  font-family: Times New Roman, Verdana;
  font-size: 45px;
  color: #ffffff;
}

td.ModTable {
  background-color: #ff6060;
}

/* ---------------------------------- *
     Спойлер
 * ---------------------------------- */
.sp-wrap {
  padding: 0;
  background: #E9E9E6;
  border-radius: 4px;
}

.sp-head {
  border-width: 0;
  font-size: 12px;
  padding: 3px 14px 4px;
  margin-left: 3px;
  line-height: 15px;
  font-weight: bold;
  color: #2A2A2A;
  cursor: pointer;
}

@media (max-width: 1920px) {
  .sp-head {
    font-size: 11px;
  }
}

.sp-body {
  border-width: 1px 0 0 0;
  display: none;
  font-weight: normal;
  background: #F5F5F5;
  border-bottom: 1px solid #C3CBD1;
  background: #F5F5F5;
  padding: 6px 8px;
}

.sp-head:hover {
  background-color: #b8b8b8; /* Фон при наведении */
  color: #000000;
  transition: all 0.2s ease-in-out; /* Плавное изменение цвета */
}

/* ---------------------------------- *
     Списки
 * ---------------------------------- */
.post_body ul, .post_body ol {
  margin: 8px auto 8px 8px;
}

.post_body li {
  margin: 0px 4px 1px 24px;
}

/* ---------------------------------- *
     Картинки в постах
 * ---------------------------------- */
img.smile, img.postImg {
  vertical-align: text-bottom;
}

img.postImg {
  margin: 2px 2px 0 0;
}

img.postImgAligned {
  margin: 4px 4px 2px;
}

var.img-left {
  float: left;
  clear: left;
}

var.img-right {
  float: right;
  clear: right;
}

/* ---------------------------------- *
     Прочее, связанное с BBCode
 * ---------------------------------- */
.post-pre {
  white-space: pre-wrap;
  word-wrap: break-word;
  font-family: monospace;
  max-width: 100%;
  overflow: auto;
  box-sizing: border-box;
}

a.postLink-name, a.postLink-name:visited {
  text-decoration: none;
}

/* ---------------------------------- *
     Инфобоксы
 * ---------------------------------- */
 
.box {
  display: inline-block; /* Делает блок адаптивным по ширине */
  border: 1px solid #000; /* Цвет рамки по умолчанию */
  background-color: #f9f9f9; /* Цвет фона по умолчанию */
  padding: 10px; /* Внутренние отступы */
  margin: 10px 0; /* Отступы сверху и снизу */
  border-radius: 5px; /* Скругление углов */
  box-shadow: 2px 2px 5px rgba(0, 0, 0, 0.1); /* Легкая тень */
  max-width: 100%; /* Ограничение по ширине, чтобы не выходило за пределы контейнера */
  word-wrap: break-word; /* Перенос длинных слов */
}
 
.infobox {
  border: 1px solid #CDD5D8;
  background: #EFEFEF;
  padding: 1px;
}

.infobox h1 {
  background: #D1D7DC;
  font-size: 1.2em;
  padding: 0px 0.6em 2px;
}

/* ---------------------------------- *
     Инпуты, кнопки, формы
 * ---------------------------------- */
input, textarea, select {
  font-family: Verdana, sans-serif;
}

select, input {
  font-size: 12px;
}

textarea {
  font-size: 14px;
}

@media screen and (max-width: 1920px) {
  textarea {
    font-size: 13px;
  }
}

input.mainoption, input.main,
input.liteoption, input.lite {
  font-size: 11px;
  border: 1px solid;
  background: #FAFAFA;
  padding-left: 10px;
  padding-right: 10px;
  cursor: pointer;
}

input[type="submit"], input[type="button"], input[type="reset"], #vk-share, #update-torrent {
  font-size: 11px;
  font-family: Tahoma;
  color: #fff;
  font-weight: bold;
  text-transform: uppercase;
  box-shadow: 0px 1px 3px #000;
  border-radius: 3px;
  background-color: #ddd;
  background: linear-gradient(to bottom, #eee, #ddd);
  border: 1px solid #fff;
  text-shadow: 0px 1px 1px #fff;
  color: #333;
}

input.mainoption, input.main {
  font-weight: bold; 
}

input.button, .buttons input {
  border: 1px solid;
  background: #FFFFFF;
}

/* Кнопки форматирования текста (B, I, U, S) */
.format-btn {
  width: 25px;
}

input.long {
  padding-left: 20px;
  padding-right: 20px;
}

input.button, .buttons input,
input.mainoption, input.main, input.liteoption, input.lite {
  border-color: #dab26a;
  border-style: solid;
}

input[type="submit"]:hover, input[type="button"]:hover, input[type="reset"]:hover, #vk-share:hover, #update-torrent:hover {
  background-color: #ccc;
  background: linear-gradient(to bottom, #ddd, #ccc);
  border: 1px solid #ddd;
}

/* "gte IE 7" in page_header.tpl */
input[type="checkbox"] {
  margin-bottom: 0px;
}

input[type="radio"] {
  margin-bottom: -2px;
}

input[disabled="disabled"] {
  color: #808080;
}

input.hint {
  color: #999999;
  font-style: italic;
  text-indent: 0.3em;
}

input.error {
  color: #FF0000;
  font-weight: bold;
}

input.found {
  font-weight: bold;
}

.cat input[type="text"] {
  background: #FCFCFC;
}

optgroup, option, fieldset, legend {
  font-family: Verdana, sans-serif;
}

optgroup {
  font-size: 13px;
  letter-spacing: 0px;
  font-weight: bold;
  font-style: italic;
  color: #005A88;
  background: #DEE3E7;
}

optgroup option {
  color: #000000;
  background: #FFFFFF;
}

option {
  font-size: 13px;
}

legend {
  padding: 0 2px 2px;
  font-size: 13px;
  color: #000066;
}

legend a {
  text-decoration: none;
}

fieldset > legend {
  margin-left: 6px;
}

.has_sf {
  color: #333333;
  background: #F5F5F5;
  font-weight: bold;
}

input.pOrdSel {
  border: 0px solid #EFEFEF;
  width: 18px;
  overflow: hidden;
  color: #333333;
  background: transparent;
  font-size: 12px;
  font-family: Arial, sans-serif;
  cursor: pointer;
}

textarea.editor {
  display: block;
  width: 98%;
}

#subject-input {
  width: 98%;
  box-sizing: border-box; 
  padding: 2px 4px;
  font-size: 13px;
}

.fieldsets td {
  vertical-align: top;
  white-space: nowrap;
}

.fieldsets fieldset {
  margin: 4px 4px;
}

.fieldsets fieldset div {
  padding: 3px 6px 4px;
}

.fieldsets div p {
  margin-bottom: 1px;
}

.fieldsets div > p {
  margin-bottom: 2px;
}

.fieldsets .select {
  margin-bottom: 3px;
}

table.my_downloads {
  margin-bottom: 2px;
}

.my_downloads td {
  padding: 1px 8px 2px 0 !important;
}

select.text_color option {
  background: #ECECEC;
}

select.text_size option.em {
  font-weight: bold;
  background: #ECECEC;
}

.fldSet1 {
  margin: 2px 4px 1px 4px;
  padding: 0px;
}

.fldSetCont1 {
  margin: 0px;
  padding: 3px 8px 4px 8px;
}

.fldSetCont2 {
  margin: 0px;
  padding: 2px 8px 4px 8px;
}

.fldSetCont3 {
  margin: 0px;
  padding: 6px 8px 8px 8px;
}

.hl_only_new {
  color: #993300;
}

.select-action {
  background: #F5F5F5;
}

/* ================================== *
     Счетчик символов для заголовка темы
 * ================================== */
.subject-char-counter {
  font-size: 11px;
  color: #666;
  text-align: left;
  margin-top: 2px;
}

.subject-char-counter.over-limit {
  color: #ff0000;
  font-weight: bold;
}

/* Статусы пользователя */
.user-status-online {
  color: #008000; 
}
.user-status-offline {
  color: #c9372c; 
}
.user-status-hidden {
  color: #ff9800; 
}

/* ================================== *
     Кнопки в шапке темы
 * ================================== */
#share-button {
  float: left;
  margin-top: 2px;
}

#share-button button {
  margin-left: 5px;
  cursor: pointer;
}

#update-torrent {
  background: #6979f2;
  border-color: #000000;
  color: #fff;
}

#update-torrent:hover {
  background: #3d8b40;
  border-color: #45a049;
}

/* Стили для поля комментария */
.comment-field-container {
  display: inline-block;
  margin: 0 5px;
}

.comment-input {
  width: 200px;
  padding: 4px 6px;
  border: 1px solid #ccc;
  border-radius: 3px;
  font-size: 12px;
  transition: all 0.3s ease;
  cursor: pointer;
}

.comment-input:focus {
  outline: none;
  border-color: #007acc;
  box-shadow: 0 0 5px rgba(0, 122, 204, 0.3);
}

.comment-textarea {
  width: 300px;
  min-height: 80px;
  max-height: 200px;
  padding: 6px;
  border: 1px solid #007acc;
  border-radius: 4px;
  font-size: 12px;
  font-family: Arial, sans-serif;
  resize: vertical;
  box-shadow: 0 0 8px rgba(0, 122, 204, 0.3);
  background-color: #fff;
}

.comment-textarea:focus {
  outline: none;
  border-color: #005580;
  box-shadow: 0 0 10px rgba(0, 122, 204, 0.4);
}

/* ================================== *
     Кнопка скачивания торрента
 * ================================== */
.download-torrent-btn {
  display: inline-block;
  width: 115px;
  background: #4682b4;
  color: #fff;
  border: 2px solid #a5afb4;
  border-radius: 4px;
  font-size: 18px;
  line-height: 50px;
  cursor: pointer;
  transition: background 0.3s;
}

.download-torrent-btn:hover {
  background: #d64545;
  color: #fff;
  text-decoration: none;
}

.download-torrent-btn.disabled {
  background: white;
  color: #666;
  cursor: not-allowed;
  border-color: #a5afb4;
  text-decoration: line-through;
}

.download-torrent-btn.disabled:hover {
  background: white;
  color: #666;
  text-decoration: line-through;
}

/* ================================== *
     Информация о размере торрент-файла
 * ================================== */
.torrent-size-info {
  margin-top: 8px;
}