.comments-section {
  font-size: 16px;
  padding: 56px 0 72px;
  border-top: 1px solid rgba(212, 175, 55, 0.12);
  background: linear-gradient(180deg, var(--bg) 0%, #0d0d0d 100%);
}

.comments-section__lead {
  margin: 0 0 32px;
  text-align: center;
  color: var(--text-muted);
  font-size: 0.95rem;
  max-width: 520px;
  margin-inline: auto;
}

.comments-widget_section .as-comment-section {
  max-width: var(--container);
  margin: 0 auto;
  background: none;
  border-radius: 0;
  box-shadow: none;
  font-family: var(--font-body);
  color: var(--text-muted);
}

.comments-widget_section .as-comment-section h2 {
  font-family: var(--font-display);
  font-size: clamp(1.75rem, 4vw, 2.35rem);
  font-weight: 400;
  letter-spacing: 0.02em;
  text-align: center;
  color: var(--text);
  margin: 0 0 12px;
  text-transform: uppercase;
}

.comments-widget_section .as-comment-section h2 .gold {
  color: var(--gold);
}

.comments-widget_section .as-comment-section p,
.comments-widget_section .as-comment-section span {
  color: var(--text-muted);
  font-size: 0.95rem;
  line-height: 1.65;
}

.comments-widget_section .as-comment-form {
  display: flex;
  flex-direction: column;
  gap: 20px;
  padding: 28px;
  border-radius: var(--radius);
  border: 1px solid var(--border-gold);
  background: var(--bg-card);
  box-shadow: 0 16px 40px rgba(0, 0, 0, 0.45);
  margin-bottom: 24px;
}

.comments-widget_section .as-comment-input-wrapper {
  margin: 0;
  position: relative;
}

.comments-widget_section .as-comment-input,
.as-modal-overlay.as-show .as-comment-input {
  appearance: none;
  width: 100%;
  min-height: 120px;
  padding: 16px 18px;
  border-radius: var(--radius);
  border: 1px solid rgba(212, 175, 55, 0.35);
  background: var(--bg-card-2);
  color: var(--text);
  font-size: 1rem;
  line-height: 1.55;
  resize: vertical;
  transition:
    border-color 0.2s ease,
    box-shadow 0.2s ease;
}

.comments-widget_section .as-comment-section ::placeholder,
.as-modal-overlay.as-show .as-comment-input::placeholder {
  color: rgba(255, 255, 255, 0.38);
}

.comments-widget_section .as-comment-input:focus,
.as-modal-overlay.as-show .as-comment-input:focus {
  outline: none;
  border-color: var(--gold);
  box-shadow: 0 0 0 3px rgba(212, 175, 55, 0.18);
}

.comments-widget_section .as-main-btn,
.as-modal-overlay.as-show .as-main-btn {
  padding: 14px 28px;
  border-radius: 999px;
  font-family: var(--font-display);
  font-weight: 400;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  font-size: 0.9rem;
  cursor: pointer;
  transition:
    transform 0.2s ease,
    box-shadow 0.2s ease,
    opacity 0.2s ease;
  border: none;
}

.comments-widget_section .as-comment-form .as-main-btn {
  align-self: flex-end;
}

.comments-widget_section .as-main-btn--submit,
.as-modal-overlay.as-show .as-main-btn--submit {
  background: linear-gradient(135deg, var(--gold-light), var(--gold));
  color: #0a0a0a;
  box-shadow: 0 12px 32px rgba(212, 175, 55, 0.35);
}

.comments-widget_section .as-main-btn--submit:hover,
.comments-widget_section .as-main-btn--submit:focus-visible,
.as-modal-overlay.as-show .as-main-btn--submit:hover,
.as-modal-overlay.as-show .as-main-btn--submit:focus-visible {
  transform: translateY(-2px);
  box-shadow: 0 16px 40px rgba(212, 175, 55, 0.45);
}

.comments-widget_section .as-main-btn--cancel,
.as-modal-overlay.as-show .as-main-btn--cancel {
  background: var(--bg-card-2);
  color: var(--text-muted);
  border: 1px solid rgba(255, 255, 255, 0.15);
}

.comments-widget_section .as-comments {
  display: flex;
  flex-direction: column;
  gap: 18px;
}

.comments-widget_section .as-comment {
  padding: 24px;
  border-radius: var(--radius);
  border: 1px solid rgba(212, 175, 55, 0.22);
  background: var(--bg-card);
  box-shadow: 0 12px 36px rgba(0, 0, 0, 0.35);
}

.comments-widget_section .as-comment-inner {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.comments-widget_section .as-comment-head {
  display: flex;
  align-items: center;
  gap: 14px;
}

.comments-widget_section .as-comment-top {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
}

.comments-widget_section .as-top-dot {
  color: rgba(255, 255, 255, 0.35);
  line-height: 1;
}

.comments-widget_section .as-avatar {
  flex-shrink: 0;
  width: 52px;
  height: 52px;
  border-radius: 50%;
  object-fit: cover;
  border: 2px solid var(--border-gold);
  box-shadow: 0 8px 20px rgba(212, 175, 55, 0.2);
}

.comments-widget_section .as-comment-top strong {
  color: var(--text);
  font-weight: 600;
  font-size: 1rem;
}

.comments-widget_section .as-comment-text {
  color: rgba(255, 255, 255, 0.82);
  font-size: 0.95rem;
  line-height: 1.7;
  margin: 0;
}

.comments-widget_section .as-comment-text b {
  color: var(--gold-light);
  font-weight: 600;
}

.comments-widget_section .as-timestamp {
  font-size: 0.82rem;
  color: rgba(255, 255, 255, 0.45);
}

.comments-widget_section .as-comment-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px;
  margin-top: 14px;
}

.comments-widget_section .as-action-btn {
  appearance: none;
  background: var(--bg-card-2);
  border: 1px solid rgba(255, 255, 255, 0.12);
  color: var(--text-muted);
  border-radius: 999px;
  padding: 0 14px 0 32px;
  height: 34px;
  font-size: 0.85rem;
  cursor: pointer;
  position: relative;
  transition:
    border-color 0.2s ease,
    color 0.2s ease,
    background 0.2s ease;
}

.comments-widget_section .as-action-btn:hover,
.comments-widget_section .as-action-btn:focus-visible {
  border-color: var(--border-gold);
  color: var(--gold-light);
}

.comments-widget_section .as-like-btn::before {
  content: "👍";
  position: absolute;
  left: 10px;
  top: 50%;
  transform: translateY(-50%);
}

.comments-widget_section .as-dislike-btn::before {
  content: "👎";
  position: absolute;
  left: 10px;
  top: 50%;
  transform: translateY(-50%);
}

.comments-widget_section .as-reply-btn::before {
  content: "💬";
  position: absolute;
  left: 10px;
  top: 50%;
  transform: translateY(-50%);
}

.comments-widget_section .as-comment--reply {
  margin-left: 0;
  margin-top: 12px;
  padding: 18px 20px;
  border-left: 3px solid var(--gold-dark);
  background: var(--bg-card-2);
}

.as-modal-overlay {
  display: none;
  position: fixed;
  inset: 0;
  justify-content: center;
  align-items: center;
  padding: 20px;
  background: rgba(0, 0, 0, 0.72);
  backdrop-filter: blur(4px);
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.25s ease;
  z-index: 9999;
}

.as-modal-overlay.as-show {
  display: flex;
  pointer-events: all;
  opacity: 1;
}

.as-modal-overlay .as-modal {
  width: min(92vw, 480px);
  background: var(--bg-card);
  border: 1px solid var(--border-gold);
  border-radius: var(--radius);
  padding: 24px;
  box-shadow: 0 24px 56px rgba(0, 0, 0, 0.55);
  animation: asModalPop 0.28s ease forwards;
}

.as-modal-overlay .as-modal__title {
  margin: 0 0 14px;
  font-family: var(--font-display);
  font-size: 1.35rem;
  font-weight: 400;
  color: var(--text);
  text-transform: uppercase;
}

.as-modal-overlay .as-modal__actions {
  display: flex;
  justify-content: flex-end;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 16px;
}

.as-modal-overlay.as-show .as-comment-input {
  min-height: 110px;
}

@keyframes asModalPop {
  from {
    opacity: 0;
    transform: scale(0.94) translateY(8px);
  }
  to {
    opacity: 1;
    transform: scale(1) translateY(0);
  }
}

@media (max-width: 767px) {
  .comments-section {
    padding: 40px 0 56px;
  }

  .comments-widget_section .as-comment-form {
    padding: 20px 16px;
  }

  .comments-widget_section .as-comment {
    padding: 18px 16px;
  }
}
