/* ==========================================================================
   SECCIÓN DE COMENTARIOS Y UGC - BLOG TUASEGÚRATE
   Optimizado para CRO, Interacción de Usuarios y E-E-A-T SEO
   ========================================================================== */

.tuasegurate-comments-section {
  background-color: #f8fafc;
  border-top: 1px solid #e2e8f0;
  border-bottom: 1px solid #e2e8f0;
  padding: 4rem 1rem;
  font-family: 'Inter Tight', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  color: #2d3748;
}

.tuasegurate-comments-container {
  max-width: 860px;
  margin: 0 auto;
}

.tuasegurate-comments-header {
  margin-bottom: 2.5rem;
  text-align: left;
}

.tuasegurate-comments-header h3 {
  font-size: 1.75rem;
  font-weight: 700;
  color: #0d295d;
  margin-bottom: 0.5rem;
  display: flex;
  align-items: center;
  gap: 10px;
}

.tuasegurate-comments-header p {
  color: #64748b;
  font-size: 1rem;
  margin: 0;
}

/* Lista de Comentarios / Preguntas */
.tuasegurate-comments-list {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
  margin-bottom: 3rem;
}

.comment-card {
  background: #ffffff;
  border: 1px solid #e2e8f0;
  border-radius: 12px;
  padding: 1.5rem;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.04);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.comment-card:hover {
  box-shadow: 0 6px 18px rgba(13, 41, 93, 0.08);
}

.comment-card-top {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 0.75rem;
}

.comment-author-info {
  display: flex;
  align-items: center;
  gap: 12px;
}

.comment-avatar {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: #edf6f5;
  color: #177a72;
  font-weight: 700;
  font-size: 1.1rem;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 2px solid #bce2df;
}

.comment-author-name {
  font-weight: 700;
  font-size: 1.05rem;
  color: #0d295d;
  margin: 0;
}

.comment-date {
  font-size: 0.82rem;
  color: #94a3b8;
}

.comment-stars {
  color: #f59e0b;
  font-size: 1rem;
  letter-spacing: 2px;
}

.comment-body {
  font-size: 0.96rem;
  line-height: 1.6;
  color: #334155;
  margin: 0;
}

/* Respuesta oficial del mediador (E-E-A-T) */
.comment-reply {
  margin-top: 1.25rem;
  padding: 1rem 1.25rem;
  background-color: #f0f7f6;
  border-left: 4px solid #177a72;
  border-radius: 0 8px 8px 0;
}

.reply-header {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 0.35rem;
}

.reply-badge {
  background: #177a72;
  color: #ffffff;
  font-size: 0.72rem;
  font-weight: 700;
  text-transform: uppercase;
  padding: 2px 8px;
  border-radius: 4px;
  letter-spacing: 0.5px;
}

.reply-author {
  font-weight: 700;
  font-size: 0.92rem;
  color: #0d295d;
}

.reply-body {
  font-size: 0.92rem;
  color: #2c3e50;
  line-height: 1.55;
  margin: 0;
}

/* Formulario para Dejar Comentario */
.comment-form-card {
  background: #ffffff;
  border: 1px solid #cbd5e1;
  border-radius: 14px;
  padding: 2rem;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.05);
}

.comment-form-title {
  font-size: 1.35rem;
  font-weight: 700;
  color: #0d295d;
  margin-bottom: 0.5rem;
}

.comment-form-subtitle {
  font-size: 0.9rem;
  color: #64748b;
  margin-bottom: 1.5rem;
}

/* Selector interactivo de estrellas */
.rating-select-group {
  margin-bottom: 1.25rem;
}

.rating-select-label {
  font-size: 0.9rem;
  font-weight: 600;
  color: #334155;
  margin-bottom: 0.35rem;
  display: block;
}

.star-rating-widget {
  display: inline-flex;
  flex-direction: row-reverse;
  gap: 4px;
}

.star-rating-widget input {
  display: none;
}

.star-rating-widget label {
  font-size: 1.8rem;
  color: #cbd5e1;
  cursor: pointer;
  transition: color 0.15s ease, transform 0.15s ease;
}

.star-rating-widget label:hover,
.star-rating-widget label:hover ~ label,
.star-rating-widget input:checked ~ label {
  color: #f59e0b;
}

.star-rating-widget label:hover {
  transform: scale(1.15);
}

.comment-input-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1rem;
  margin-bottom: 1rem;
}

.comment-field-group {
  display: flex;
  flex-direction: column;
  margin-bottom: 1rem;
}

.comment-field-group label {
  font-size: 0.88rem;
  font-weight: 600;
  color: #334155;
  margin-bottom: 0.35rem;
}

.comment-field-group input,
.comment-field-group textarea {
  font-family: inherit;
  font-size: 0.95rem;
  padding: 0.75rem 1rem;
  border: 1px solid #cbd5e1;
  border-radius: 8px;
  background: #ffffff;
  color: #1e293b;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.comment-field-group input:focus,
.comment-field-group textarea:focus {
  outline: none;
  border-color: #177a72;
  box-shadow: 0 0 0 3px rgba(23, 122, 114, 0.15);
}

.comment-moderation-notice {
  background: #eff6ff;
  border: 1px solid #bfdbfe;
  border-radius: 8px;
  padding: 0.75rem 1rem;
  font-size: 0.84rem;
  color: #1e40af;
  margin-bottom: 1.25rem;
  display: flex;
  align-items: flex-start;
  gap: 8px;
}

.comment-consent-check {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  margin-bottom: 1.25rem;
  font-size: 0.85rem;
  color: #475569;
}

.comment-consent-check input {
  margin-top: 3px;
  accent-color: #177a72;
}

.comment-consent-check a {
  color: #177a72;
  text-decoration: underline;
}

.comment-submit-btn {
  background: #0d295d;
  color: #ffffff;
  font-weight: 700;
  font-size: 0.95rem;
  padding: 0.85rem 1.75rem;
  border: none;
  border-radius: 8px;
  cursor: pointer;
  transition: all 0.2s ease;
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.comment-submit-btn:hover {
  background: #177a72;
  box-shadow: 0 4px 14px rgba(23, 122, 114, 0.3);
}

.comment-feedback-alert {
  display: none;
  padding: 1rem;
  border-radius: 8px;
  margin-bottom: 1rem;
  font-size: 0.92rem;
}

.comment-feedback-alert.success {
  background: #dcfce7;
  border: 1px solid #86efac;
  color: #166534;
}

.comment-feedback-alert.error {
  background: #fee2e2;
  border: 1px solid #fca5a5;
  color: #991b1b;
}

@media (max-width: 767px) {
  .comment-input-grid {
    grid-template-columns: 1fr;
  }
  .tuasegurate-comments-section {
    padding: 2.5rem 1rem;
  }
  .comment-form-card {
    padding: 1.25rem;
  }
}
