/* ---------------------------------- *
     Элементы поста
 * ---------------------------------- */
.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"], #vkshare, #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, #vkshare:hover, #update-torrent:hover {
  background-color: #ccc;
  background: linear-gradient(to bottom, #ddd, #ccc);
  border: 1px solid #ddd;
}

input[type="submit"]:active, input[type="button"]:active, input[type="reset"]:active, #vkshare:active, #update-torrent:active {
  background-color: #bbb;
  background: linear-gradient(to bottom, #ccc, #bbb);
  border: 1px solid #ccc;
  transform: translateY(1px);
  box-shadow: inset 0 1px 2px rgba(0,0,0,0.2);
}
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;
}

/* Вспомогательные классы для инлайн-стилей */
.form-hidden {
  display: none;
}

.pagination-small {
  padding: 1px 6px 5px;
}

.nav-padding-left {
  padding-left: 8px;
}

.mod-td-padding {
  padding: 0px 0px 0px 4px;
}

.mod-td-padding-pipe {
  padding: 0px 4px 2px 4px;
}

.mod-td-padding-zero {
  padding: 0px 0px 0px 0px;
}

.mod-td-padding-small {
  padding: 0px 0px 0px 3px;
}

.search-td-padding {
  padding: 0px 4px 2px 4px;
}

.search-input-width {
  width: 150px;
}

.search-submit-width {
  width: 30px;
}

.submit-button-width {
  width: 100px;
}

.post-float-left {
  float: left;
}

.post-float-left-text {
  float: left;
  padding: 4px 0 3px;
}

.post-float-left-no-text {
  float: left;
  padding-top: 5px;
}

.post-float-right {
  float: right;
}

.post-float-right-text {
  float: right;
  padding: 3px 2px 4px;
}

.post-float-right-no-text {
  float: right;
  padding: 1px 6px 2px;
}

.rating-padding {
  padding-left: 30px;
}

.rating,
.post_rating {
  margin: 0 4px;
}

.rating-positive {
  color: green;
}

.rating-negative {
  color: red;
}

.rating-zero {
  color: #BBBBBB;
}

.post-rating-padding {
  padding-left: 30px;
}

/* ---------------------------------- *
     Окно плюсов и минусов
 * ---------------------------------- */
#rate .scrollable_rate {
  float: left;
  position:relative;
  overflow:hidden;
  width:340px;
  height:390px;
  padding-bottom:0;
  box-sizing:border-box;
}

#rate .headerrr {
  background:#e9eef4;
  border-bottom:1px solid #c8d2df;
  position:relative;
  z-index:2;
  min-height:36px;
  overflow:hidden;
}

#rate .plus1 {
  width:170px;
  float:left;
  padding:8px 12px;
  box-sizing:border-box;
  font-size:13px;
  font-weight:600;
  color:#2f3b47;
}

#rate .minus1 {
  margin-left:170px;
  padding:8px 12px;
  box-sizing:border-box;
  font-size:13px;
  font-weight:600;
  color:#2f3b47;
}

#rate .rate-plus-label {
  color:#2f7a3e;
}

#rate .rate-minus-label {
  color:#d64545;
}

#rate .plus {
  width:170px;
  float:left;
  padding:4px 12px 6px;
  height:100%;
  box-sizing:border-box;
  overflow:hidden;
  line-height:1.2;
  font-size:14px;
}

#rate .minus {
  margin-left:170px;
  padding:4px 12px 6px;
  border-left:2px solid #c8d2df;
  box-shadow: -1px 0 0 rgba(0,0,0,0.04) inset;
  height:100%;
  width:170px;
  box-sizing:border-box;
  overflow:hidden;
  line-height:1.2;
  font-size:14px;
}

#rate.rate1 {
  width:340px;
  height:390px;
  display:none;
  position: fixed;
  left: 50%;
  background:#f3f5f8;
  font:13px Verdana,Arial,sans-serif;
  border-radius: 8px;
  border: 2px solid #95a2b5;
  box-shadow:0 8px 18px rgba(23,42,77,.18);
  overflow:hidden;
}

#rate a,
#rate a:visited {
  color:#2f5f8a;
  text-decoration:none;
}

#rate a:hover {
  color:#1f4a71;
  text-decoration:underline;
}

.close {
  position:absolute;
  right:8px;
  top:6px;
  opacity:.75;
}

#rate .close:hover {
  opacity:1;
}

#rate .scrollable_rate .items {
  width:20000em;
  position:absolute;
  top:36px;
  bottom:24px;
  left:0;
  z-index:1;
}

#rate .itemsdiv {
  float:left;
  width:340px;
  height:100%;
  box-sizing: border-box;
}

#rate .plus a,
#rate .minus a {
  display:block;
  white-space:nowrap;
  overflow:hidden;
  text-overflow:ellipsis;
  margin:2px 0;
  padding:2px 0;
}

.innershager {
  position: relative;
  width:340px;
  height:390px;
  overflow:hidden;
  background:#f3f5f8;
  border-radius:8px;
}

#rate #slider {
  position:absolute;
  left:8px;
  right:8px;
  bottom:8px;
  margin:0;
}

#rate #slider.ui-slider {
  height:8px;
  border:1px solid #b8c4d3;
  background:#dfe5ed;
  border-radius:10px;
}

#rate #slider .ui-slider-handle {
  width:12px;
  height:12px;
  top:-3px;
  border:1px solid #6f8097;
  border-radius:50%;
  background:#ffffff;
}

/* Конец плюсоминусов */

.enemy-cell {
  background-color: #f0d9d9;
  padding: 5px;
}

.hr1-margin {
  margin: 5px 0 4px;
}

.stats-link {
  text-decoration: none !important;
}

.user-stats-hidden {
  display: none;
}

.poster-btn-padding-text {
  padding: 2px 6px 4px;
}

.poster-btn-padding-no-text {
  padding: 2px 5px;
}

.split-row-hidden {
  display: none;
}

.split-input-width {
  width: 500px;
}

.table-padding-top {
  padding-top: 2px;
}

.admin-float-left {
  float: left;
}

.admin-float-right {
  float: right;
}

/* Условные стили для скрытия элементов */
.hide-flags .flag img {
  display: none;
}

.hide-avatar .avatar {
  display: none;
}

.hide-rank-img .rank_img {
  display: none;
}

.hide-post-img img.postImg,
.hide-post-img div.postImg-wrap {
  display: none;
}

.hide-smile .smile {
  display: none;
}

.hide-signature .signature {
  display: none;
}

/* Стили для поля комментария */
.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: 17px;
  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;
}

/* Кнопка "Спасибо" */
.thanks-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 70px;
  height: 17px;
  background: #4682b4;
  color: #fff;
  text-decoration: none;
  border: 1px solid #000000;
  border-radius: 3px;
  cursor: pointer;
  user-select: none;
}

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

.thanks-btn--disabled {
  pointer-events: none;
  opacity: 0.5;
}

/* Стили для подписи изображения в Fancybox */
.img-caption {
  display: inline-flex;
  align-items: center;
  gap: 15px;
  flex-wrap: wrap;
  justify-content: center;
}

.img-caption-link {
  color: #5eb0ef;
  text-decoration: none;
  font-size: 13px;
}

.img-caption-link:hover {
  text-decoration: none !important;
}