/**
 * Styles pour les commentaires - Mon-Theme-ACA
 * Design simple et épuré
 */

/* Variables CSS pour les commentaires */
:root {
  --teal-green: #2d9b8a;
  --light-green: #a8e6cf;
  --dark-teal: #1f6b5c;
  --white: #ffffff;
  --light-gray: #f8f9fa;
  --medium-gray: #6c757d;
  --dark-gray: #343a40;
  --success-green: #28a745;
  --warning-orange: #fd7e14;
  --comment-bg: #f9fbf9;
}

/* Container principal des commentaires */
.theme-comments-area {
  margin-top: 3rem;
  padding: 0;
}

/* Titre principal des commentaires */
.theme-comments-title {
  color: var(--dark-teal);
  font-size: 1.5rem;
  font-weight: 700;
  margin-bottom: 1.5rem;
}

/* Liste des commentaires */
.theme-comment-list {
  margin: 0;
  padding: 0;
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

/* Commentaire individuel */
.theme-comment-list .comment {
  background: var(--comment-bg);
  padding: 1rem;
  border-radius: 8px;
  border-left: 3px solid var(--teal-green);
}

/* Header du commentaire avec avatar et infos */
.comment-header {
  display: flex;
  align-items: flex-start;
  margin-bottom: 0.75rem;
}

.comment-author .avatar {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  margin-right: 0.75rem;
  object-fit: cover;
  object-position: center;
  display: block;
  flex-shrink: 0;
  border: 2px solid var(--light-green);
  background-color: var(--light-gray);
}

.comment-author-info {
  flex-grow: 1;
}

.theme-comment-list .comment-author .fn {
  color: var(--dark-teal);
  font-weight: 600;
  font-size: 1rem;
  margin: 0;
  display: block;
}

.theme-comment-list .comment-metadata {
  color: var(--medium-gray);
  font-size: 0.75rem;
  margin: 0;
  line-height: 1.2;
}

.theme-comment-list .comment-metadata a {
  color: var(--medium-gray);
  text-decoration: none;
}

/* Contenu du commentaire */
.theme-comment-list .comment-content {
  color: var(--dark-gray);
  line-height: 1.6;
  margin: 0;
  font-size: 0.95rem;
}

.theme-comment-list .comment-content p {
  margin: 0;
}

/* Commentaires imbriqués (réponses) */
.theme-comment-list .children {
  margin-left: 2rem;
  margin-top: 1rem;
}

.theme-comment-list .children .comment {
  border-left-color: var(--light-green);
  background: rgba(168, 230, 207, 0.1);
}

/* Formulaire de commentaire */
.theme-comment-form {
  background: var(--white);
  border-radius: 8px;
  padding: 1.5rem;
  margin-top: 2rem;
  border: 1px solid #e9ecef;
}

.theme-comment-form h3,
.comment-respond h3 {
  color: var(--dark-teal);
  font-size: 1.25rem;
  font-weight: 600;
  margin-bottom: 1rem;
}

.theme-comment-form .comment-notes {
  color: var(--medium-gray);
  margin-bottom: 1rem;
  font-size: 0.9rem;
}

.theme-comment-form .comment-form-comment,
.theme-comment-form .comment-form-author,
.theme-comment-form .comment-form-email,
.theme-comment-form .comment-form-url {
  margin-bottom: 1rem;
}

.theme-comment-form label {
  color: var(--dark-gray);
  font-weight: 500;
  margin-bottom: 0.25rem;
  display: block;
  font-size: 0.875rem;
}

.theme-comment-form input[type="text"],
.theme-comment-form input[type="email"],
.theme-comment-form input[type="url"],
.theme-comment-form textarea {
  border: 1px solid #d1d5db;
  border-radius: 4px;
  padding: 0.5rem;
  width: 100%;
  background: var(--white);
  color: var(--dark-gray);
  font-family: inherit;
  font-size: 0.95rem;
  box-sizing: border-box;
}

.theme-comment-form input[type="text"]:focus,
.theme-comment-form input[type="email"]:focus,
.theme-comment-form input[type="url"]:focus,
.theme-comment-form textarea:focus {
  border-color: var(--teal-green);
  outline: none;
}

.theme-comment-form textarea {
  min-height: 100px;
  resize: vertical;
  font-family: inherit;
}

.theme-comment-form .form-submit {
  text-align: left;
  margin-top: 1.5rem;
}

.btn-success-green,
.theme-comment-form input[type="submit"],
.theme-comment-form #submit,
.comment-form input[type="submit"] {
  background: var(--teal-green);
  color: var(--white);
  border: none;
  border-radius: 8px;
  padding: 0.75rem 1.5rem;
  font-weight: 600;
  font-size: 0.95rem;
  cursor: pointer;
  transition: all 0.3s ease;
  text-transform: none;
  letter-spacing: normal;
  font-family: inherit;
  box-shadow: 0 2px 4px rgba(45, 155, 138, 0.2);
  min-width: 160px;
  position: relative;
  overflow: hidden;
}

.btn-success-green:hover,
.theme-comment-form input[type="submit"]:hover,
.theme-comment-form #submit:hover,
.comment-form input[type="submit"]:hover {
  background: var(--dark-teal);
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.btn-success-green:focus,
.theme-comment-form input[type="submit"]:focus,
.theme-comment-form #submit:focus,
.comment-form input[type="submit"]:focus {
  outline: none;
  background: var(--dark-teal);
  box-shadow: 0 0 0 3px rgba(168, 230, 207, 0.3);
}

.btn-success-green:active,
.theme-comment-form input[type="submit"]:active,
.theme-comment-form #submit:active,
.comment-form input[type="submit"]:active {
  transform: translateY(0);
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.1);
}

/* Animation pour le bouton lors de la soumission */
.btn-success-green:disabled,
.theme-comment-form input[type="submit"]:disabled,
.theme-comment-form #submit:disabled,
.comment-form input[type="submit"]:disabled {
  background: var(--medium-gray);
  cursor: not-allowed;
  transform: none;
  box-shadow: none;
}

/* Message "pas de commentaires" */
.no-comments {
  color: var(--warning-orange);
  font-weight: 500;
  margin: 1rem 0;
}

/* Classes utilitaires */
.text-dark-teal {
  color: var(--dark-teal) !important;
}

.text-medium-gray {
  color: var(--medium-gray) !important;
}

/* Responsive pour les commentaires */
@media (max-width: 768px) {
  .theme-comment-list .children {
    margin-left: 1rem;
  }

  .comment-author .avatar {
    width: 35px;
    height: 35px;
    border-radius: 50%;
    object-fit: cover;
    object-position: center;
    border: 2px solid var(--light-green);
  }
}

@media (max-width: 480px) {
  .theme-comment-list .children {
    margin-left: 0.5rem;
  }
}

/* Liste des commentaires */
.theme-comment-list {
  margin: 0;
  padding: 0;
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}

/* Commentaire individuel */
.theme-comment-list .comment {
  background: var(--comment-bg);
  border-radius: 12px;
  padding: 1.5rem;
  margin-bottom: 0;
  border: none;
  transition: all 0.3s ease;
  position: relative;
}

.theme-comment-list .comment:hover {
  transform: translateY(-1px);
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.08);
}

/* Header du commentaire avec avatar et infos */
.comment-header {
  display: flex;
  align-items: center;
  margin-bottom: 0.75rem;
}

.comment-author .avatar {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  margin-right: 0.75rem;
  object-fit: cover;
}

.comment-author-info {
  flex-grow: 1;
}

.theme-comment-list .comment-author .fn {
  color: var(--dark-teal);
  font-weight: 600;
  font-size: 1rem;
  margin: 0;
  display: block;
}

.theme-comment-list .comment-metadata {
  color: var(--medium-gray);
  font-size: 0.75rem;
  margin: 0;
  line-height: 1.2;
}

.theme-comment-list .comment-metadata a {
  color: var(--medium-gray);
  text-decoration: none;
  transition: color 0.2s ease;
}

.theme-comment-list .comment-metadata a:hover {
  color: var(--teal-green);
}

/* Contenu du commentaire */
.theme-comment-list .comment-content {
  color: var(--dark-gray);
  line-height: 1.6;
  margin: 0;
  font-size: 0.95rem;
}

.theme-comment-list .comment-content p {
  margin: 0;
}

/* Bouton de réponse */
.theme-comment-list .reply {
  text-align: right;
  margin-top: 1rem;
}

.theme-comment-list .reply a {
  background: var(--teal-green);
  color: var(--white);
  padding: 0.4rem 0.8rem;
  border-radius: 20px;
  font-size: 0.8rem;
  font-weight: 500;
  text-decoration: none;
  transition: all 0.2s ease;
  display: inline-block;
}

.theme-comment-list .reply a:hover {
  background: var(--dark-teal);
  transform: scale(1.05);
}

/* Commentaires imbriqués (réponses) */
.theme-comment-list .children {
  margin-left: 2rem;
  margin-top: 1.5rem;
  padding-left: 1rem;
  border-left: 2px solid var(--light-green);
}

.theme-comment-list .children .comment {
  background: rgba(168, 230, 207, 0.1);
}

/* Formulaire de commentaire */
.theme-comment-form {
  background: var(--white);
  border-radius: 12px;
  padding: 2rem;
  margin-top: 2rem;
  border: 1px solid var(--light-green);
}

.theme-comment-form h3,
.comment-respond h3 {
  color: var(--dark-teal);
  font-size: 1.25rem;
  font-weight: 600;
  margin-bottom: 1.5rem;
  text-align: left;
}

.theme-comment-form .comment-notes {
  background: var(--light-green);
  color: var(--dark-teal);
  padding: 1rem;
  border-radius: 8px;
  margin-bottom: 1.5rem;
  font-size: 0.9rem;
}

.theme-comment-form .comment-form-comment,
.theme-comment-form .comment-form-author,
.theme-comment-form .comment-form-email,
.theme-comment-form .comment-form-url {
  margin-bottom: 1rem;
}

.theme-comment-form label {
  color: var(--dark-gray);
  font-weight: 500;
  margin-bottom: 0.25rem;
  display: block;
  font-size: 0.875rem;
}

.theme-comment-form input[type="text"],
.theme-comment-form input[type="email"],
.theme-comment-form input[type="url"],
.theme-comment-form textarea {
  border: 1px solid #d1d5db;
  border-radius: 6px;
  padding: 0.75rem 1rem;
  width: 100%;
  background: var(--white);
  color: var(--dark-gray);
  font-family: inherit;
  font-size: 0.95rem;
  transition: all 0.2s ease;
  box-sizing: border-box;
}

.theme-comment-form input[type="text"]:focus,
.theme-comment-form input[type="email"]:focus,
.theme-comment-form input[type="url"]:focus,
.theme-comment-form textarea:focus {
  border-color: var(--teal-green);
  outline: none;
  box-shadow: 0 0 0 3px rgba(45, 155, 138, 0.1);
}

.theme-comment-form textarea {
  min-height: 100px;
  resize: vertical;
  font-family: inherit;
}

.theme-comment-form .form-submit {
  text-align: left;
  margin-top: 1.5rem;
}

.btn-success-green,
.theme-comment-form input[type="submit"],
.theme-comment-form #submit,
.comment-form input[type="submit"] {
  background: var(--teal-green);
  color: var(--white);
  border: none;
  border-radius: 8px;
  padding: 0.75rem 1.5rem;
  font-weight: 600;
  font-size: 0.95rem;
  cursor: pointer;
  transition: all 0.3s ease;
  text-transform: none;
  letter-spacing: normal;
  font-family: inherit;
  box-shadow: 0 2px 4px rgba(45, 155, 138, 0.2);
  min-width: 160px;
  position: relative;
  overflow: hidden;
}

.btn-success-green:hover,
.theme-comment-form input[type="submit"]:hover,
.theme-comment-form #submit:hover,
.comment-form input[type="submit"]:hover {
  background: var(--dark-teal);
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.btn-success-green:focus,
.theme-comment-form input[type="submit"]:focus,
.theme-comment-form #submit:focus,
.comment-form input[type="submit"]:focus {
  outline: none;
  background: var(--dark-teal);
  box-shadow: 0 0 0 3px rgba(168, 230, 207, 0.3);
}

.btn-success-green:active,
.theme-comment-form input[type="submit"]:active,
.theme-comment-form #submit:active,
.comment-form input[type="submit"]:active {
  transform: translateY(0);
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.1);
}

/* Animation pour le bouton lors de la soumission */
.btn-success-green:disabled,
.theme-comment-form input[type="submit"]:disabled,
.theme-comment-form #submit:disabled,
.comment-form input[type="submit"]:disabled {
  background: var(--medium-gray);
  cursor: not-allowed;
  transform: none;
  box-shadow: none;
}

/* Message "pas de commentaires" */
.no-comments {
  background: var(--warning-orange);
  color: var(--white);
  padding: 1rem 1.5rem;
  border-radius: 8px;
  font-weight: 600;
  text-align: center;
  margin: 2rem 0;
}

/* Navigation des commentaires */
.comment-navigation {
  background: var(--light-gray);
  padding: 1rem;
  border-radius: 8px;
  margin: 1.5rem 0;
  text-align: center;
}

.comment-navigation a {
  background: var(--teal-green);
  color: var(--white);
  padding: 0.5rem 1rem;
  border-radius: 20px;
  margin: 0 0.5rem;
  font-weight: 500;
  text-decoration: none;
  transition: all 0.2s ease;
}

.comment-navigation a:hover {
  background: var(--dark-teal);
}

/* Classes utilitaires */
.text-dark-teal {
  color: var(--dark-teal) !important;
}

.text-medium-gray {
  color: var(--medium-gray) !important;
}

.avatar-40 {
  border-radius: 30px;
  margin: 5px;
}

/* Responsive pour les commentaires */
@media (max-width: 768px) {
  .theme-comments-area {
    padding: 2rem 1.5rem;
    margin-top: 2rem;
  }

  .theme-comments-title {
    font-size: 1.5rem;
  }

  .theme-comment-form {
    padding: 1.5rem;
  }

  .theme-comment-list .children {
    margin-left: 1rem;
  }

  .btn-success-green {
    width: 100%;
    padding: 1rem;
  }

  .comment-header {
    flex-direction: row;
    align-items: flex-start;
  }

  .comment-author .avatar {
    width: 35px;
    height: 35px;
  }
}

@media (max-width: 480px) {
  .theme-comments-area {
    padding: 1.5rem 1rem;
  }

  .theme-comment-list .children {
    margin-left: 0.5rem;
    padding-left: 0.5rem;
  }
}
