/* Evotic Edge — Ratings composable (Phase 2026-05-20) */

.evo-rating-block {
  display: flex;
  flex-direction: column;
  gap: 12px;
  padding: 14px;
  border-radius: 14px;
  background: rgba(103, 80, 164, 0.04);
  border: 1px solid rgba(103, 80, 164, 0.12);
  margin: 12px 0;
  font-family: Nunito, sans-serif;
}

.evo-rating-summary {
  display: flex;
  align-items: center;
  gap: 6px;
  font-weight: 800;
  font-size: 15px;
  color: #1C1C2E;
}
.evo-rating-avg { color: #6750A4; }
.evo-rating-avg .fa-star { margin-right: 4px; }
.evo-rating-count { color: #6C6C7A; font-weight: 600; }
.evo-rating-empty { color: #6C6C7A; font-style: italic; font-weight: 600; font-size: 13px; }

/* Picker */
.evo-rating-picker {
  display: flex;
  flex-direction: column;
  gap: 8px;
  padding: 10px;
  background:var(--card-bg);
  border-radius: 10px;
  border: 1px solid #EDE9E0;
}
.evo-rating-picker-stars {
  display: flex;
  align-items: center;
  gap: 4px;
}
.evo-star {
  font-size: 26px;
  line-height: 1;
  color: #7F67BE;
  background: transparent;
  border: none;
  padding: 0 2px;
  cursor: default;
  transition: transform 80ms ease;
}
.evo-star-off { color: #D8D8D8; }
.evo-star-int { cursor: pointer; }
.evo-star-int:hover,
.evo-star-int:focus {
  transform: scale(1.18);
  outline: none;
}
.evo-star-int:active { transform: scale(0.95); }
.evo-star-clear {
  margin-left: 8px;
  background: transparent;
  border: none;
  color: #B0B0B8;
  cursor: pointer;
  padding: 4px 6px;
  border-radius: 6px;
  font-size: 13px;
}
.evo-star-clear:hover { color: #E53935; background: rgba(229, 57, 53, 0.08); }

.evo-rating-textarea {
  width: 100%;
  box-sizing: border-box;
  min-height: 60px;
  max-height: 120px;
  resize: vertical;
  padding: 8px 10px;
  border-radius: 8px;
  border: 1px solid #EDE9E0;
  font-family: Nunito, sans-serif;
  font-size: 13px;
  color: #1C1C2E;
  background: #FAFAF6;
}
.evo-rating-textarea:focus {
  border-color: #6750A4;
  outline: none;
  background:var(--card-bg);
}

.evo-rating-actions {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}
.evo-rating-submit {
  appearance: none;
  border: none;
  background: linear-gradient(135deg, #6750A4 0%, #7F67BE 100%);
  color: #fff;
  font-family: Nunito, sans-serif;
  font-weight: 800;
  font-size: 13px;
  padding: 9px 16px;
  border-radius: 999px;
  cursor: pointer;
  box-shadow: 0 2px 8px rgba(103, 80, 164, 0.32);
  display: inline-flex;
  align-items: center;
  gap: 6px;
}
.evo-rating-submit:disabled {
  opacity: 0.45;
  cursor: not-allowed;
  box-shadow: none;
}
.evo-rating-submit:not(:disabled):active { transform: scale(0.97); }
.evo-rating-err { color: #E53935; font-size: 12px; font-weight: 700; }

.evo-rating-hint {
  font-size: 13px;
  color: #6C6C7A;
  font-weight: 600;
  padding: 8px 4px;
}
.evo-rating-hint a { color: #6750A4; font-weight: 800; }

/* Liste commentaires */
.evo-rating-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.evo-rating-item {
  display: flex;
  gap: 10px;
  padding: 10px;
  background:var(--card-bg);
  border-radius: 10px;
  border: 1px solid #F0EDE5;
}
.evo-rating-avatar {
  flex-shrink: 0;
  width: 34px;
  height: 34px;
  border-radius: 50%;
  object-fit: cover;
}
.evo-rating-avatar-fb {
  background: linear-gradient(135deg, #6750A4, #7F67BE);
  color: #fff;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-weight: 800;
  font-size: 14px;
}
.evo-rating-item-body { flex: 1; min-width: 0; }
.evo-rating-item-head {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
  margin-bottom: 4px;
}
.evo-rating-item-pseudo { font-weight: 800; font-size: 13px; color: #1C1C2E; }
.evo-rating-item-stars .evo-star { font-size: 13px; padding: 0 1px; }
.evo-rating-item-time { color: #9A9AAC; font-size: 11px; font-weight: 600; margin-left: auto; }
.evo-rating-item-comment { font-size: 13px; color: #3C3C4E; line-height: 1.45; }

/* Loading / spinner */
.evo-rating-loading {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 22px;
}
.evo-rating-spinner {
  width: 20px;
  height: 20px;
  border: 2.5px solid rgba(103, 80, 164, 0.2);
  border-top-color: #6750A4;
  border-radius: 50%;
  animation: evo-rating-spin 0.7s linear infinite;
}
@keyframes evo-rating-spin { to { transform: rotate(360deg); } }
