/* Catalog style "demo29" — rating + comments add-on (loaded instead of _rate.css): frosted panels, a soft gradient score, round glass numbers. Mirrors /demo29/. */
/*
 * Cards: the score and the comment count as quiet small caps under the meta line. Post: the rating
 * is a centred frosted panel with a large light-italic score in an azure → lilac → amber gradient
 * and the 1–10 scale as round glass buttons (picked = filled with the gradient, a soft glow);
 * comments are frosted bubbles with a gradient initial dot, the form has dark glass fields.
 */

/* card counters */
.post__stats { display: flex; flex-wrap: wrap; justify-content: center; align-items: center; gap: 6px 18px; margin: -4px 0 14px; color: var(--mute); font-size: 13px; letter-spacing: 0.12em; text-transform: uppercase; }
.post__rating { display: inline-flex; align-items: baseline; gap: 3px; color: var(--ink); }
.post__rating-avg { font: italic 400 20px/1 var(--serif); letter-spacing: 0; }
.post__rating-max { color: var(--mute); font-size: 11px; }
.post__comments { color: var(--soft); text-decoration: none; }
.post__comments:hover { color: #fff; text-decoration: underline; text-underline-offset: 4px; }

.post__flash { margin: 44px 0 0; }

/* rating */
.rating, .comments { margin-top: 56px; }
.rating { padding: 34px 30px; border: 1px solid var(--edge); border-radius: calc(var(--r) + 8px); background: var(--glass); text-align: center; -webkit-backdrop-filter: blur(26px); backdrop-filter: blur(26px); }
.rating__title, .comments__title { margin: 0 0 16px; font: italic 300 36px/1.15 var(--serif); color: #fff; text-align: center; }
.rating__score { display: flex; justify-content: center; align-items: baseline; flex-wrap: wrap; gap: 0 8px; margin: 0 0 22px; }
.rating__avg { font: italic 300 92px/1 var(--serif); background: linear-gradient(100deg, #8fe1fb, #cdb9ff 50%, #ffc89e); -webkit-background-clip: text; background-clip: text; color: transparent; }
.rating__max { color: var(--mute); font-size: 18px; }
.rating__count { flex-basis: 100%; margin-top: 6px; color: var(--mute); font-size: 13px; letter-spacing: 0.16em; text-transform: uppercase; }
.rating__form { display: flex; flex-direction: column; align-items: center; gap: 18px; }
.rating__scale { display: flex; flex-wrap: wrap; justify-content: center; gap: 8px; min-width: 0; margin: 0; padding: 0; border: 0; }
.rating__legend { width: 100%; margin-bottom: 14px; padding: 0; color: var(--soft); font-size: 15px; text-align: center; }
.rating__opt { position: relative; }
.rating__input { position: absolute; opacity: 0; width: 1px; height: 1px; margin: 0; }
.rating__num { display: grid; place-items: center; width: 48px; height: 48px; border: 1px solid var(--edge-2); border-radius: 50%; background: rgb(255 255 255 / 0.04); color: var(--ink); font: 400 22px/1 var(--serif); cursor: pointer; transition: background 0.6s ease, border-color 0.6s ease, box-shadow 0.6s ease, color 0.6s ease; }
.rating__opt:hover .rating__num { border-color: rgb(255 255 255 / 0.45); background: rgb(255 255 255 / 0.08); }
.rating__input:checked + .rating__num { border-color: transparent; background: linear-gradient(135deg, #4cc9f0, #b79cff 55%, #f4a261); color: #0b0c14; font-weight: 500; box-shadow: 0 0 30px -4px rgb(183 156 255 / 0.8); }
.rating__input:focus-visible + .rating__num { outline: 2px solid var(--azure); outline-offset: 4px; }
.rating__submit { min-height: 44px; }
.rating__mine { margin: 0 auto; max-width: 46ch; padding: 18px 22px; border-radius: 22px; background: rgb(183 156 255 / 0.1); color: var(--soft); line-height: 1.6; }
.rating__mine-score { display: inline-grid; place-items: center; min-width: 42px; height: 42px; margin: 0 6px; padding: 0 8px; border-radius: 50%; background: linear-gradient(135deg, #4cc9f0, #b79cff 55%, #f4a261); color: #0b0c14; font: 500 22px/1 var(--serif); vertical-align: middle; }

/* comments */
.comments__title { display: flex; justify-content: center; align-items: baseline; gap: 12px; }
.comments__count { color: var(--mute); font: 400 15px/1 var(--sans); letter-spacing: 0.1em; }
.comments__list { display: grid; gap: 14px; margin: 0 0 28px; padding: 0; list-style: none; }
.comment { position: relative; padding: 20px 24px 20px 66px; border: 1px solid var(--edge); border-radius: var(--r); background: var(--glass); -webkit-backdrop-filter: blur(20px); backdrop-filter: blur(20px); }
.comment::before { content: ""; position: absolute; left: 24px; top: 24px; width: 22px; height: 22px; border-radius: 50%; background: linear-gradient(135deg, #4cc9f0, #b79cff 55%, #f4a261); filter: blur(0.5px); box-shadow: 0 0 18px -2px rgb(183 156 255 / 0.7); }
.comment__meta { display: flex; flex-wrap: wrap; align-items: baseline; gap: 4px 14px; margin: 0 0 6px; color: var(--mute); font-size: 13px; }
.comment__author { color: #fff; font: italic 400 21px/1.2 var(--serif); }
.comment__body { color: var(--soft); overflow-wrap: anywhere; }
.comments__empty { margin: 0 0 24px; color: var(--mute); text-align: center; font: italic 300 20px/1.4 var(--serif); }
.comment-form { display: grid; gap: 18px; padding: 28px 30px; border: 1px solid var(--edge); border-radius: calc(var(--r) + 8px); background: var(--glass); -webkit-backdrop-filter: blur(26px); backdrop-filter: blur(26px); }
.comment-form__field { display: grid; gap: 8px; margin: 0; }
.comment-form__label { color: var(--mute); font-size: 12px; letter-spacing: 0.2em; text-transform: uppercase; }
.comment-form__input, .comment-form__text { width: 100%; min-width: 0; padding: 12px 16px; border: 1px solid var(--edge-2); border-radius: 16px; background: rgb(0 0 0 / 0.35); color: var(--ink); font: inherit; }
.comment-form__input { max-width: 380px; }
.comment-form__text { min-height: 130px; resize: vertical; }
.comment-form__input:focus, .comment-form__text:focus { outline: none; border-color: var(--azure); box-shadow: 0 0 0 4px rgb(76 201 240 / 0.18); }
.comment-form__actions { display: flex; flex-wrap: wrap; align-items: center; gap: 10px 18px; margin: 0; }
.comment-form__submit { min-height: 44px; }
.comment-form__note { color: var(--mute); font-size: 13px; }

@media (max-width: 640px) {
    .rating { padding: 26px 16px; }
    .rating__avg { font-size: 72px; }
    .rating__num { width: 44px; height: 44px; font-size: 20px; }
    .comment-form { padding: 22px 18px; }
    .comment { padding: 18px 18px 18px 54px; }
    .comment::before { left: 18px; top: 22px; width: 18px; height: 18px; }
}
