/* comments.css — Commentaires d'une recette (page recette.php). */

.comments { margin-top: 40px; padding-top: 10px; }
.comments h2 { border-bottom: 2px solid var(--primary-light, rgba(249, 115, 22, 0.15)); padding-bottom: 10px; margin: 0 0 12px 0; display: flex; align-items: center; gap: 10px; }
.cm-count { background: #f1f5f9; color: #475569; border-radius: 999px; font-size: 0.8rem; padding: 2px 10px; font-weight: 700; }

.cm-list { list-style: none; margin: 0; padding: 0; }
.cm { padding: 12px 14px; margin: 0 0 10px 0; background: #fff; border: 1px solid var(--border, #e5e7eb); border-radius: 12px; }
.cm-head { display: flex; align-items: baseline; flex-wrap: wrap; gap: 4px 10px; margin-bottom: 4px; }
.cm-name { font-weight: 800; color: var(--text-main, #1f2937); }
.cm-date { font-size: 0.8rem; color: var(--text-muted, #6b7280); }
.cm-del { margin-left: auto; background: none; border: none; color: #9ca3af; font-size: 0.85rem; cursor: pointer; padding: 10px 6px; }
.cm-del:hover { color: #b91c1c; }
.cm-del.confirm { color: #fff; background: #dc2626; border-radius: 8px; padding: 8px 12px; font-weight: 700; }
/* Le texte est affiché tel quel (jamais interprété comme du HTML) ; les retours à la ligne sont conservés */
.cm-body { white-space: pre-wrap; overflow-wrap: anywhere; line-height: 1.5; }
.cm-empty { color: var(--text-muted, #6b7280); margin: 6px 0 14px 0; }

.cm-form { margin-top: 14px; }
.cm-form textarea { width: 100%; box-sizing: border-box; padding: 12px 14px; border: 1px solid var(--border, #d1d5db); border-radius: 12px; font-family: inherit; font-size: 16px; line-height: 1.4; resize: vertical; min-height: 84px; }
.cm-form textarea:focus { outline: 2px solid var(--primary, #f97316); border-color: transparent; }
.cm-actions { display: flex; align-items: center; justify-content: space-between; margin-top: 8px; }
.cm-left { font-size: 0.8rem; color: #9ca3af; }
.cm-left.low { color: #b45309; font-weight: 700; }
.cm-send { min-height: 44px; padding: 0 22px; border: none; border-radius: 12px; background: var(--primary, #f97316); color: #fff; font-weight: 700; font-size: 1rem; cursor: pointer; }
.cm-send:disabled { opacity: 0.55; cursor: default; }
.cm-err { color: #b91c1c; font-size: 0.9rem; margin-top: 6px; }
.cm-err:empty { display: none; }
.cm-hint { color: var(--text-muted, #6b7280); font-size: 0.85rem; }
