/* =========================================================
   DLE 21 COMMENTS
   Blogzine / Bootstrap 5.3.8
   Основной класс: .thread__item
   ========================================================= */


/* =========================================================
   01. COMMENT ITEM
   ========================================================= */

.thread__item {
    display: flex;
    width: 100%;

    margin-top: 1.5rem;
    margin-bottom: 1.5rem;

    padding: 1rem;

    border: 1px solid var(--bs-border-color);
    border-radius: var(--bs-border-radius);

    background-color: var(--bs-body-bg);

    position: relative;
}

.thread__item:first-child {
    margin-top: 0;
}

.thread__item:last-child {
    margin-bottom: 2rem;
}

.thread__item + .thread__item {
    margin-top: 2rem;
}


/* =========================================================
   02. REPLY / CHILD COMMENT
   ========================================================= */

.thread__item--reply {
    margin-left: 3.5rem;
    width: calc(100% - 3.5rem);
}

.thread__item--reply + .thread__item--reply {
    margin-top: 1.75rem;
}

.thread__item--reply:last-child {
    margin-bottom: 2rem;
}


/* =========================================================
   03. AVATAR
   ========================================================= */

.thread__avatar {
    flex: 0 0 52px;
    width: 52px;
    min-width: 52px;
    text-align: center;
}

.thread__avatar-img {
    display: block;
    width: 52px;
    height: 52px;
    object-fit: cover;
    border-radius: 50%;
    border: 1px solid var(--bs-border-color);
    background-color: var(--bs-secondary-bg);
}

.thread__avatar-placeholder {
    display: flex;
    align-items: center;
    justify-content: center;

    width: 52px;
    height: 52px;

    border: 1px solid var(--bs-border-color);
    border-radius: 50%;

    background-color: var(--bs-secondary-bg);
    color: var(--bs-secondary-color);

    font-size: 1.25rem;
    line-height: 1;
}


/* =========================================================
   04. ONLINE
   ========================================================= */

.thread__online-wrap {
    text-align: center;
}

.thread__online {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: .3rem;

    margin-top: .4rem;

    font-size: .7rem;
    line-height: 1;

    color: var(--bs-success);

    white-space: nowrap;
}

.thread__online-dot {
    display: inline-block;

    width: 6px;
    height: 6px;
    flex: 0 0 6px;

    border-radius: 50%;

    background-color: var(--bs-success);

    box-shadow: 0 0 0 3px rgba(var(--bs-success-rgb), .12);
}


/* =========================================================
   05. CONTENT
   ========================================================= */

.thread__content {
    flex: 1 1 auto;
    min-width: 0;
    margin-left: 1rem;
}


/* =========================================================
   06. HEADER
   ========================================================= */

.thread__header {
    display: flex;
    align-items: center;
    justify-content: space-between;

    gap: .75rem;
    flex-wrap: wrap;

    min-width: 0;
}

.thread__author-row {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: .5rem;
}


/* =========================================================
   07. AUTHOR
   ========================================================= */

.thread__author {
    display: inline-flex;
    align-items: center;

    min-width: 0;

    font-weight: 600;
    line-height: 1.4;
}

.thread__author a {
    color: var(--bs-body-color);
    text-decoration: none;
    transition: color .2s ease;
}

.thread__author a:hover {
    color: var(--bs-primary);
}


/* =========================================================
   08. AUTHOR BADGE
   ========================================================= */

.thread__author-badge {
    display: inline-flex;
    align-items: center;
    gap: .3rem;

    padding: .25rem .55rem;

    border-radius: var(--bs-border-radius-pill);

    background-color: var(--bs-primary-bg-subtle);
    color: var(--bs-primary-text-emphasis);

    font-size: .7rem;
    font-weight: 600;
    line-height: 1;
}

.thread__author-badge i {
    color: var(--bs-primary);
    font-size: .75rem;
}


/* =========================================================
   09. DATE
   ========================================================= */

.thread__date {
    display: inline-block;

    color: var(--bs-secondary-color);

    font-size: .78rem;
    line-height: 1.4;

    white-space: nowrap;
}


/* =========================================================
   10. GROUP
   ========================================================= */

.thread__group {
    margin-top: .15rem;

    color: var(--bs-secondary-color);

    font-size: .75rem;
    line-height: 1.4;
}


/* =========================================================
   11. NEWS / PUBLICATION
   ========================================================= */

.thread__news {
    margin-top: .75rem;

    padding: .7rem .85rem;

    border: 1px solid var(--bs-border-color);
    border-radius: var(--bs-border-radius);

    background-color: var(--bs-tertiary-bg);
}

.thread__news-label {
    display: flex;
    align-items: center;
    gap: .3rem;

    margin-bottom: .25rem;

    color: var(--bs-secondary-color);

    font-size: .7rem;
    font-weight: 600;
    line-height: 1.3;

    text-transform: uppercase;
    letter-spacing: .02em;
}

.thread__news-label i {
    color: var(--bs-primary);
    font-size: .85rem;
}

.thread__news-title {
    color: var(--bs-body-color);

    font-size: .85rem;
    font-weight: 600;
    line-height: 1.5;

    overflow-wrap: anywhere;
}


/* =========================================================
   12. COMMENT TEXT
   ========================================================= */

.thread__text {
    margin-top: .7rem;
    margin-bottom: .9rem;

    color: var(--bs-body-color);

    font-size: 1rem;
    line-height: 1.7;

    overflow-wrap: anywhere;
}

.thread__text p {
    margin-top: 0;
    margin-bottom: .75rem;
}

.thread__text p:last-child {
    margin-bottom: 0;
}

.thread__text a {
    color: var(--bs-primary);
    text-decoration: underline;
    text-decoration-color: rgba(var(--bs-primary-rgb), .35);
    text-underline-offset: 2px;

    transition: color .2s ease, text-decoration-color .2s ease;
}

.thread__text a:hover {
    color: var(--bs-primary-text-emphasis);
    text-decoration-color: currentColor;
}

.thread__text img {
    max-width: 100%;
    height: auto;
    border-radius: var(--bs-border-radius);
}

.thread__text blockquote {
    margin: 1rem 0;
    padding: .75rem 1rem;

    border-left: 3px solid var(--bs-primary);

    background-color: var(--bs-tertiary-bg);

    border-radius: 0 var(--bs-border-radius) var(--bs-border-radius) 0;

    color: var(--bs-secondary-color);
}


/* =========================================================
   13. COMMENT IMAGES
   ========================================================= */

.thread__images {
    display: flex;
    align-items: flex-start;
    flex-wrap: wrap;
    gap: .5rem;

    margin-top: .75rem;
}

.thread__images img {
    display: block;

    max-width: 100%;
    height: auto;

    border-radius: var(--bs-border-radius);
    border: 1px solid var(--bs-border-color);

    transition: transform .2s ease, box-shadow .2s ease;
}

.thread__images img:hover {
    transform: translateY(-1px);
    box-shadow: 0 .5rem 1rem rgba(var(--bs-dark-rgb), .08);
}


/* =========================================================
   14. SIGNATURE
   ========================================================= */

.thread__signature {
    margin-top: .8rem;
    padding-top: .75rem;

    border-top: 1px solid var(--bs-border-color);

    color: var(--bs-secondary-color);

    font-size: .85rem;
    line-height: 1.6;
}


/* =========================================================
   15. COMMENT FOOTER
   ========================================================= */

.thread__footer {
    display: flex;
    align-items: center;
    flex-wrap: wrap;

    gap: .4rem;

    margin-top: 1rem;

    min-height: 32px;
}


/* =========================================================
   16. BASE FOOTER BUTTON
   ========================================================= */

.thread__btn {
    --thread-btn-color: var(--bs-secondary-color);
    --thread-btn-bg: var(--bs-secondary-bg);
    --thread-btn-hover-color: var(--bs-secondary-text-emphasis);
    --thread-btn-hover-bg: var(--bs-secondary-bg);

    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: .25rem;

    min-height: 32px;
    padding: .3rem .65rem;

    border: 1px solid transparent;
    border-radius: var(--bs-border-radius-pill);

    background-color: var(--thread-btn-bg);
    color: var(--thread-btn-color);

    font-size: .78rem;
    font-weight: 500;
    line-height: 1;

    white-space: nowrap;
    cursor: pointer;
    user-select: none;

    transition:
        color .2s ease,
        background-color .2s ease,
        border-color .2s ease,
        box-shadow .2s ease,
        transform .2s ease;
}

.thread__btn i {
    display: inline-block;
    font-size: .9rem;
    line-height: 1;
    transition: color .2s ease, transform .2s ease;
}

.thread__btn-label {
    display: inline-block;
    line-height: 1;
}

.thread__btn:hover {
    color: var(--thread-btn-hover-color);
    background-color: var(--thread-btn-hover-bg);
    transform: translateY(-1px);
    box-shadow: 0 .25rem .75rem rgba(var(--bs-dark-rgb), .08);
}

.thread__btn:active {
    transform: translateY(0);
    box-shadow: none;
}


/* =========================================================
   17. QUOTE
   ========================================================= */

.thread__btn--quote {
    --thread-btn-color: var(--bs-primary);
    --thread-btn-bg: var(--bs-primary-bg-subtle);
    --thread-btn-hover-color: var(--bs-primary-text-emphasis);
    --thread-btn-hover-bg: var(--bs-primary-bg-subtle);

    border-color: rgba(var(--bs-primary-rgb), .15);
}

.thread__btn--quote i {
    color: var(--bs-primary);
}


/* =========================================================
   18. REPLY
   ========================================================= */

.thread__btn--reply {
    --thread-btn-color: var(--bs-success);
    --thread-btn-bg: var(--bs-success-bg-subtle);
    --thread-btn-hover-color: var(--bs-success-text-emphasis);
    --thread-btn-hover-bg: var(--bs-success-bg-subtle);

    border-color: rgba(var(--bs-success-rgb), .15);
}

.thread__btn--reply i {
    color: var(--bs-success);
}


/* =========================================================
   19. REPLY COUNT
   ========================================================= */

.thread__btn--count {
    --thread-btn-color: var(--bs-info);
    --thread-btn-bg: var(--bs-info-bg-subtle);
    --thread-btn-hover-color: var(--bs-info-text-emphasis);
    --thread-btn-hover-bg: var(--bs-info-bg-subtle);

    border-color: rgba(var(--bs-info-rgb), .15);
}

.thread__btn--count i {
    color: var(--bs-info);
}


/* =========================================================
   20. COMPLAINT
   ========================================================= */

.thread__btn--complaint {
    --thread-btn-color: var(--bs-warning-text-emphasis);
    --thread-btn-bg: var(--bs-warning-bg-subtle);
    --thread-btn-hover-color: var(--bs-warning-text-emphasis);
    --thread-btn-hover-bg: var(--bs-warning-bg-subtle);

    border-color: rgba(var(--bs-warning-rgb), .2);
}

.thread__btn--complaint i {
    color: var(--bs-warning);
}


/* =========================================================
   21. EDIT
   ========================================================= */

.thread__btn--edit {
    --thread-btn-color: var(--bs-info);
    --thread-btn-bg: var(--bs-info-bg-subtle);
    --thread-btn-hover-color: var(--bs-info-text-emphasis);
    --thread-btn-hover-bg: var(--bs-info-bg-subtle);

    border-color: rgba(var(--bs-info-rgb), .15);
}

.thread__btn--edit i {
    color: var(--bs-info);
}


/* =========================================================
   22. DELETE
   ========================================================= */

.thread__btn--delete {
    --thread-btn-color: var(--bs-danger);
    --thread-btn-bg: var(--bs-danger-bg-subtle);
    --thread-btn-hover-color: var(--bs-danger-text-emphasis);
    --thread-btn-hover-bg: var(--bs-danger-bg-subtle);

    border-color: rgba(var(--bs-danger-rgb), .15);
}

.thread__btn--delete i {
    color: var(--bs-danger);
}


/* =========================================================
   23. RATING CONTAINER
   ========================================================= */

.thread__rating {
    display: inline-flex;
    align-items: center;
    gap: .2rem;

    min-height: 32px;
    padding: .15rem;

    border: 1px solid var(--bs-border-color);
    border-radius: var(--bs-border-radius-pill);

    background-color: var(--bs-tertiary-bg);
}


/* =========================================================
   24. RATING SCORE
   ========================================================= */

.thread__rating-score {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: .3rem;

    min-height: 30px;
    padding: .3rem .6rem;

    border-radius: var(--bs-border-radius-pill);

    background-color: var(--bs-warning-bg-subtle);
    color: var(--bs-warning-text-emphasis);

    font-size: .78rem;
    font-weight: 600;
    line-height: 1;
}

.thread__rating-score i {
    color: var(--bs-warning);
}


/* =========================================================
   25. RATING BUTTON
   ========================================================= */

.thread__rating-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: .3rem;

    min-height: 30px;
    padding: .3rem .6rem;

    border-radius: var(--bs-border-radius-pill);

    font-size: .78rem;
    font-weight: 600;
    line-height: 1;

    cursor: pointer;
    user-select: none;

    transition:
        color .2s ease,
        background-color .2s ease,
        transform .2s ease,
        box-shadow .2s ease;
}


/* =========================================================
   26. LIKE
   ========================================================= */

.thread__rating-btn--up {
    background-color: var(--bs-success-bg-subtle);
    color: var(--bs-success-text-emphasis);
}

.thread__rating-btn--up i {
    color: var(--bs-success);
}

.thread__rating-btn--up:hover {
    background-color: var(--bs-success);
    color: #fff;
    transform: translateY(-1px);
    box-shadow: 0 .25rem .6rem rgba(var(--bs-success-rgb), .2);
}

.thread__rating-btn--up:hover i {
    color: #fff;
}


/* =========================================================
   27. DISLIKE
   ========================================================= */

.thread__rating-btn--down {
    background-color: var(--bs-danger-bg-subtle);
    color: var(--bs-danger-text-emphasis);
}

.thread__rating-btn--down i {
    color: var(--bs-danger);
}

.thread__rating-btn--down:hover {
    background-color: var(--bs-danger);
    color: #fff;
    transform: translateY(-1px);
    box-shadow: 0 .25rem .6rem rgba(var(--bs-danger-rgb), .2);
}

.thread__rating-btn--down:hover i {
    color: #fff;
}


/* =========================================================
   28. POSITIVE / NEGATIVE COMMENT
   ========================================================= */

.thread__rating.is-positive {
    border-color: rgba(var(--bs-success-rgb), .25);
}

.thread__rating.is-negative {
    border-color: rgba(var(--bs-danger-rgb), .25);
}


/* =========================================================
   29. RATING PLUS / MINUS
   ========================================================= */

.ratingtypeplusminus {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 1rem;
}


/* =========================================================
   30. MASS ACTION
   ========================================================= */

.thread__mass {
    display: inline-flex;
    align-items: center;

    min-height: 32px;

    margin-left: auto;
}

.thread__mass a,
.thread__mass button,
.thread__mass label {
    display: inline-flex;
    align-items: center;
    justify-content: center;

    min-height: 32px;
    padding: .3rem .6rem;

    border: 1px solid var(--bs-border-color);
    border-radius: var(--bs-border-radius-pill);

    background-color: var(--bs-body-bg);
    color: var(--bs-secondary-color);

    font-size: .75rem;
    line-height: 1;

    text-decoration: none;
    cursor: pointer;

    transition:
        color .2s ease,
        background-color .2s ease,
        border-color .2s ease;
}

.thread__mass a:hover,
.thread__mass button:hover,
.thread__mass label:hover {
    color: var(--bs-primary);
    background-color: var(--bs-primary-bg-subtle);
    border-color: rgba(var(--bs-primary-rgb), .2);
}


/* =========================================================
   31. FOCUS
   ========================================================= */

.thread__btn:focus-visible,
.thread__rating-btn:focus-visible,
.thread__mass a:focus-visible,
.thread__mass button:focus-visible,
.thread__mass label:focus-visible {
    outline: 0;
    box-shadow: 0 0 0 .2rem rgba(var(--bs-primary-rgb), .2);
}


/* =========================================================
   32. DARK MODE
   ========================================================= */

[data-bs-theme="dark"] .thread__btn {
    box-shadow: none;
}

[data-bs-theme="dark"] .thread__btn:hover {
    box-shadow: 0 .25rem .75rem rgba(0, 0, 0, .2);
}

[data-bs-theme="dark"] .thread__news,
[data-bs-theme="dark"] .thread__rating {
    background-color: var(--bs-tertiary-bg);
    border-color: var(--bs-border-color);
}

[data-bs-theme="dark"] .thread__mass a,
[data-bs-theme="dark"] .thread__mass button,
[data-bs-theme="dark"] .thread__mass label {
    background-color: var(--bs-body-bg);
    border-color: var(--bs-border-color);
}


/* =========================================================
   33. TABLET
   ========================================================= */

@media (max-width: 991.98px) {

    .thread__item--reply {
        margin-left: 2.5rem;
        width: calc(100% - 2.5rem);
    }

}


/* =========================================================
   34. MOBILE
   ========================================================= */

@media (max-width: 767.98px) {

    .thread__item {
        margin-top: 1.25rem;
        margin-bottom: 1.5rem;
        padding: .85rem;
    }

    .thread__item + .thread__item {
        margin-top: 1.75rem;
    }

    .thread__item:last-child {
        margin-bottom: 2rem;
    }

    .thread__content {
        margin-left: .75rem;
    }

    .thread__item--reply {
        margin-left: 1.5rem;
        width: calc(100% - 1.5rem);
    }

    .thread__item--reply + .thread__item--reply {
        margin-top: 1.5rem;
    }

    .thread__header {
        align-items: flex-start;
        flex-direction: column;
        gap: .2rem;
    }

    .thread__footer {
        gap: .3rem;
    }

    .thread__mass {
        margin-left: 0;
    }

}


/* =========================================================
   35. SMALL MOBILE
   ========================================================= */

@media (max-width: 575.98px) {

    .thread__avatar {
        flex-basis: 44px;
        width: 44px;
        min-width: 44px;
    }

    .thread__avatar-img,
    .thread__avatar-placeholder {
        width: 44px;
        height: 44px;
    }

    .thread__content {
        margin-left: .65rem;
    }

    .thread__item--reply {
        margin-left: .75rem;
        width: calc(100% - .75rem);
    }

    .thread__item {
        margin-top: 1rem;
        margin-bottom: 1.25rem;
        padding: .75rem;
    }

    .thread__item + .thread__item {
        margin-top: 1.5rem;
    }

    .thread__text {
        font-size: .95rem;
        line-height: 1.65;
    }

    .thread__footer {
        gap: .25rem;
    }

    /*
       На телефоне текст кнопок скрывается
       через Bootstrap .d-none .d-md-inline.
       Поэтому кнопка превращается в компактную иконку.
    */

    .thread__btn {
        width: 34px;
        min-width: 34px;
        min-height: 34px;
        padding: 0;
    }

    .thread__btn i {
        font-size: .9rem;
    }

    .thread__rating {
        min-height: 34px;
    }

    .thread__rating-btn,
    .thread__rating-score {
        min-height: 31px;
        padding: .3rem .5rem;
    }

    .thread__mass {
        width: 100%;
        margin-top: .2rem;
    }

}


/* =========================================================
   36. VERY SMALL SCREEN
   ========================================================= */

@media (max-width: 399.98px) {

    .thread__avatar {
        flex-basis: 40px;
        width: 40px;
        min-width: 40px;
    }

    .thread__avatar-img,
    .thread__avatar-placeholder {
        width: 40px;
        height: 40px;
        font-size: 1rem;
    }

    .thread__content {
        margin-left: .55rem;
    }

    .thread__item--reply {
        margin-left: .5rem;
        width: calc(100% - .5rem);
    }

    .thread__btn {
        width: 32px;
        min-width: 32px;
        min-height: 32px;
    }

    .thread__rating {
        min-height: 32px;
    }

    .thread__rating-btn,
    .thread__rating-score {
        min-height: 29px;
    }

}


/* =========================================================
   37. REDUCED MOTION
   ========================================================= */

@media (prefers-reduced-motion: reduce) {

    .thread__btn,
    .thread__btn i,
    .thread__rating-btn,
    .thread__images img {
        transition: none;
    }

}


/* =========================================================
   38. PRINT
   ========================================================= */

@media print {

    .thread__footer {
        display: none;
    }

    .thread__item {
        margin-top: 1rem;
        margin-bottom: 1rem;
    }

    .thread__item--reply {
        margin-left: 1rem;
        width: auto;
    }

    .thread__text {
        color: #000;
    }

}


/* =========================================================
   BLOGZINE — PREMIUM COMMENTS
   Дополнительный слой поверх базовых стилей comments.css
   ========================================================= */

:root {
  --thread-surface: var(--obs-card, #fffdf9);
  --thread-paper: var(--obs-paper, #f8f5ef);
  --thread-line: var(--obs-line, #e9e1d4);
  --thread-ink: var(--obs-ink, #211f1c);
  --thread-muted: var(--obs-muted, #827b70);
  --thread-gold: var(--obs-gold, #c6a15b);
  --thread-gold-dark: var(--obs-gold-dark, #9d7940);
  --thread-elevation: 0 12px 34px rgba(44, 35, 22, .055), 0 2px 8px rgba(44, 35, 22, .035);
}

.thread__item {
  position: relative;
  isolation: isolate;
  gap: 0;
  margin: 0 0 1.1rem;
  padding: clamp(1rem, 2vw, 1.35rem);
  overflow: visible;
  border: 1px solid var(--thread-line);
  border-radius: 18px;
  background:
    radial-gradient(circle at 0 0, rgba(198, 161, 91, .075), transparent 34%),
    var(--thread-surface);
  box-shadow: var(--thread-elevation);
  transition: border-color .22s ease, box-shadow .22s ease, transform .22s ease;
}

.thread__item::before {
  content: "";
  position: absolute;
  z-index: -1;
  inset: 12px auto 12px 0;
  width: 3px;
  border-radius: 0 4px 4px 0;
  background: linear-gradient(180deg, rgba(198, 161, 91, .85), rgba(198, 161, 91, .12));
  opacity: .7;
}

.thread__item:hover {
  border-color: rgba(198, 161, 91, .42);
  box-shadow: 0 16px 38px rgba(44, 35, 22, .085), 0 3px 10px rgba(44, 35, 22, .04);
  transform: translateY(-1px);
}

.thread__item:first-child,
.thread__item + .thread__item,
.thread__item:last-child {
  margin-top: 0;
  margin-bottom: 1.1rem;
}

.thread__item--reply {
  width: calc(100% - 3.25rem);
  margin-left: 3.25rem !important;
  border-radius: 15px;
  background: color-mix(in srgb, var(--thread-surface) 94%, var(--thread-paper));
  box-shadow: 0 5px 18px rgba(44, 35, 22, .035);
}

.thread__item--reply::after {
  content: "";
  position: absolute;
  top: -1.15rem;
  left: -1.85rem;
  width: 1.15rem;
  height: calc(100% + 1.15rem);
  border-left: 1px solid rgba(198, 161, 91, .45);
  border-bottom: 1px solid rgba(198, 161, 91, .45);
  border-bottom-left-radius: 12px;
  pointer-events: none;
}

.thread__avatar {
  position: relative;
  flex: 0 0 54px;
  width: 54px;
  min-width: 54px;
  text-align: center;
}

.thread__avatar-img,
.thread__avatar-placeholder {
  width: 54px;
  height: 54px;
  border: 2px solid var(--thread-surface);
  outline: 1px solid rgba(198, 161, 91, .48);
  box-shadow: 0 4px 12px rgba(35, 29, 20, .10);
}

.thread__avatar-img { object-fit: cover; }

.thread__avatar-placeholder {
  display: grid;
  place-items: center;
  background: linear-gradient(145deg, rgba(198,161,91,.18), rgba(198,161,91,.06));
  color: var(--thread-gold-dark);
  font-size: 1.3rem;
}

.thread__online-wrap { margin-top: .42rem; }
.thread__online {
  gap: .35rem;
  color: #27845b;
  font-size: .65rem;
  font-weight: 700;
  letter-spacing: .045em;
  text-transform: uppercase;
}
.thread__online-dot {
  width: 7px;
  height: 7px;
  flex-basis: 7px;
  box-shadow: 0 0 0 3px rgba(39, 132, 91, .12);
}

.thread__content {
  margin-left: 1.1rem;
}

.thread__header {
  align-items: flex-start;
  gap: .35rem 1rem;
}

.thread__author-row { gap: .55rem; }
.thread__author {
  color: var(--thread-ink);
  font-size: .98rem;
  font-weight: 800;
  letter-spacing: -.015em;
}
.thread__author a { color: inherit; }
.thread__author a:hover { color: var(--thread-gold-dark); }

.thread__author-badge {
  padding: .32rem .58rem;
  border: 1px solid rgba(198, 161, 91, .24);
  border-radius: 999px;
  background: rgba(198, 161, 91, .12);
  color: var(--thread-gold-dark);
  font-size: .65rem;
  font-weight: 800;
  letter-spacing: .035em;
  text-transform: uppercase;
}
.thread__author-badge i { color: var(--thread-gold-dark); }

.thread__date {
  padding-top: .12rem;
  color: var(--thread-muted);
  font-size: .75rem;
  font-weight: 600;
  font-variant-numeric: tabular-nums;
}

.thread__group {
  margin-top: .22rem;
  color: var(--thread-muted);
  font-size: .7rem;
  font-weight: 600;
}

.thread__news {
  margin-top: .9rem;
  padding: .75rem .9rem;
  border: 1px solid rgba(198, 161, 91, .2);
  border-radius: 12px;
  background: linear-gradient(110deg, rgba(198, 161, 91, .10), rgba(198, 161, 91, .035));
}
.thread__news-label {
  color: var(--thread-gold-dark);
  font-size: .64rem;
  font-weight: 800;
  letter-spacing: .08em;
}
.thread__news-title {
  font-size: .84rem;
  font-weight: 750;
  line-height: 1.45;
}

.thread__text {
  margin: .9rem 0 .85rem;
  color: var(--thread-ink);
  font-size: .94rem;
  line-height: 1.75;
  overflow-wrap: anywhere;
}
.thread__text p { margin-bottom: .7rem; }
.thread__text ul,
.thread__text ol { padding-left: 1.35rem; }
.thread__text blockquote {
  padding: .85rem 1rem;
  border-left: 3px solid var(--thread-gold);
  border-radius: 0 12px 12px 0;
  background: rgba(198, 161, 91, .08);
  color: var(--thread-muted);
}
.thread__text pre {
  max-width: 100%;
  overflow-x: auto;
  padding: .9rem;
  border: 1px solid var(--thread-line);
  border-radius: 10px;
  background: var(--thread-paper);
}
.thread__text table { display: block; max-width: 100%; overflow-x: auto; }

.thread__images { gap: .65rem; margin-top: .85rem; }
.thread__images img {
  max-height: 240px;
  border-radius: 12px;
  border: 1px solid var(--thread-line);
  box-shadow: 0 5px 16px rgba(35, 29, 20, .07);
}

.thread__signature {
  margin-top: .95rem;
  padding-top: .75rem;
  border-top: 1px dashed var(--thread-line);
  color: var(--thread-muted);
  font-size: .78rem;
  line-height: 1.6;
}

.thread__footer {
  gap: .45rem;
  margin-top: 1rem;
  padding-top: .8rem;
  border-top: 1px solid color-mix(in srgb, var(--thread-line) 72%, transparent);
}

.thread__btn {
  min-height: 34px;
  padding: .42rem .72rem;
  border: 1px solid var(--thread-line);
  border-radius: 999px;
  font-size: .72rem;
  font-weight: 700;
  letter-spacing: .005em;
}
.thread__btn i { font-size: .82rem; }
.thread__btn:hover { transform: translateY(-2px); }

.thread__btn--quote {
  --thread-btn-color: var(--thread-gold-dark);
  --thread-btn-bg: rgba(198,161,91,.12);
  --thread-btn-hover-color: #fff;
  --thread-btn-hover-bg: var(--thread-gold-dark);
  border-color: rgba(198,161,91,.22);
}
.thread__btn--quote i { color: var(--thread-gold-dark); }
.thread__btn--quote:hover i { color: #fff; }

.thread__rating {
  gap: .22rem;
  min-height: 34px;
  padding: .12rem;
  border-color: var(--thread-line);
  background: var(--thread-paper);
}
.thread__rating-score,
.thread__rating-btn {
  min-height: 30px;
  padding: .34rem .62rem;
  font-size: .72rem;
  font-weight: 800;
}

.thread__mass { margin-left: auto; }
.thread__mass a,
.thread__mass button,
.thread__mass label {
  min-height: 34px;
  padding: .4rem .7rem;
  border-radius: 999px;
  font-weight: 700;
}

.thread__btn:focus-visible,
.thread__rating-btn:focus-visible,
.thread__mass a:focus-visible,
.thread__mass button:focus-visible,
.thread__mass label:focus-visible {
  outline: 3px solid rgba(198, 161, 91, .35);
  outline-offset: 2px;
  box-shadow: none;
}

/* Тёмная тема: поддерживаем атрибут Bootstrap и классы темы */
html[data-bs-theme="dark"] .thread__item,
[data-bs-theme="dark"] .thread__item,
html.dark-mode .thread__item,
body.dark-mode .thread__item {
  --thread-surface: #20211f;
  --thread-paper: #181a19;
  --thread-line: #3a3b37;
  --thread-ink: #f0eee9;
  --thread-muted: #aaa69d;
  --thread-gold: #d2b16f;
  --thread-gold-dark: #d2b16f;
  background:
    radial-gradient(circle at 0 0, rgba(210, 177, 111, .09), transparent 36%),
    var(--thread-surface);
  border-color: var(--thread-line);
  box-shadow: 0 12px 32px rgba(0,0,0,.22);
}
html[data-bs-theme="dark"] .thread__item--reply,
[data-bs-theme="dark"] .thread__item--reply,
html.dark-mode .thread__item--reply,
body.dark-mode .thread__item--reply {
  background: #242522;
}
html[data-bs-theme="dark"] .thread__avatar-img,
[data-bs-theme="dark"] .thread__avatar-img,
html.dark-mode .thread__avatar-img,
body.dark-mode .thread__avatar-img {
  border-color: #242522;
}
html[data-bs-theme="dark"] .thread__news,
[data-bs-theme="dark"] .thread__news,
html.dark-mode .thread__news,
body.dark-mode .thread__news {
  background: linear-gradient(110deg, rgba(210,177,111,.12), rgba(210,177,111,.04));
  border-color: rgba(210,177,111,.2);
}
html[data-bs-theme="dark"] .thread__btn,
[data-bs-theme="dark"] .thread__btn,
html.dark-mode .thread__btn,
body.dark-mode .thread__btn {
  border-color: #41423d;
}
html[data-bs-theme="dark"] .thread__btn--quote,
[data-bs-theme="dark"] .thread__btn--quote,
html.dark-mode .thread__btn--quote,
body.dark-mode .thread__btn--quote {
  --thread-btn-color: #e1c486;
  --thread-btn-bg: rgba(210,177,111,.12);
  --thread-btn-hover-color: #fff;
  --thread-btn-hover-bg: #947342;
  border-color: rgba(210,177,111,.22);
}
html[data-bs-theme="dark"] .thread__rating,
[data-bs-theme="dark"] .thread__rating,
html.dark-mode .thread__rating,
body.dark-mode .thread__rating {
  background: #181a19;
  border-color: #41423d;
}
html[data-bs-theme="dark"] .thread__mass a,
html[data-bs-theme="dark"] .thread__mass button,
html[data-bs-theme="dark"] .thread__mass label,
html.dark-mode .thread__mass a,
html.dark-mode .thread__mass button,
html.dark-mode .thread__mass label,
body.dark-mode .thread__mass a,
body.dark-mode .thread__mass button,
body.dark-mode .thread__mass label {
  background: #20211f;
  color: #d6d2c9;
  border-color: #41423d;
}

@media (max-width: 767.98px) {
  .thread__item { padding: .9rem; border-radius: 15px; }
  .thread__item--reply { width: calc(100% - 1.5rem); margin-left: 1.5rem !important; }
  .thread__item--reply::after { left: -.95rem; width: .55rem; }
  .thread__content { margin-left: .8rem; }
  .thread__header { flex-direction: row; align-items: flex-start; }
  .thread__date { font-size: .7rem; }
}
@media (max-width: 575.98px) {
  .thread__item { padding: .78rem; margin-bottom: .85rem !important; }
  .thread__avatar { flex-basis: 42px; width: 42px; min-width: 42px; }
  .thread__avatar-img,
  .thread__avatar-placeholder { width: 42px; height: 42px; }
  .thread__content { margin-left: .65rem; }
  .thread__header { flex-direction: column; gap: .18rem; }
  .thread__author { font-size: .9rem; }
  .thread__text { margin-top: .7rem; font-size: .9rem; line-height: 1.65; }
  .thread__footer { gap: .35rem; }
  .thread__mass { width: auto; margin-left: 0; }
}
@media (prefers-reduced-motion: reduce) {
  .thread__item,
  .thread__btn,
  .thread__rating-btn,
  .thread__images img { transition: none !important; transform: none !important; }
}
