/**
 * @file
 * Styles pour la popup de confirmation de taille Haqihana.
 */

/* Overlay de fond */
.hsc-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.6);
  z-index: 99999;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.3s ease, visibility 0.3s ease;
}

.hsc-overlay.hsc-visible {
  opacity: 1;
  visibility: visible;
}

/* Popup container */
.hsc-popup {
  background: #fff;
  border-radius: 12px;
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.3);
  max-width: 500px;
  width: 90%;
  max-height: 90vh;
  overflow-y: auto;
  position: relative;
  transform: scale(0.9);
  transition: transform 0.3s ease;
}

.hsc-overlay.hsc-visible .hsc-popup {
  transform: scale(1);
}

/* Bouton de fermeture */
.hsc-close {
  position: absolute;
  top: 10px;
  right: 15px;
  background: none;
  border: none;
  font-size: 28px;
  color: #666;
  cursor: pointer;
  line-height: 1;
  padding: 0;
  transition: color 0.2s ease;
}

.hsc-close:hover {
  color: #333;
}

/* Header */
.hsc-header {
  background: #19212e;
  color: #fff;
  padding: 20px 25px;
  border-radius: 12px 12px 0 0;
}

.hsc-header h3 {
  margin: 0;
  font-size: 1.4em;
  font-weight: 600;
  color: #fff;
}

/* Contenu */
.hsc-content {
  padding: 25px;
}

.hsc-message {
  color: #555;
  font-size: 1em;
  line-height: 1.5;
  margin-bottom: 20px;
}

/* Taille sélectionnée */
.hsc-size-selected {
  background: #f5f5f5;
  padding: 15px 20px;
  border-radius: 8px;
  margin-bottom: 15px;
  border-left: 4px solid #19212e;
}

.hsc-size-value {
  display: inline-block;
  background: #19212e;
  color: #fff;
  padding: 4px 12px;
  border-radius: 4px;
  font-weight: bold;
  margin-left: 5px;
}

/* Plage de taille */
.hsc-size-range {
  background: #f0f2f5;
  padding: 12px 15px;
  border-radius: 6px;
  margin-bottom: 20px;
  font-size: 0.95em;
}

.hsc-size-range p {
  margin: 0;
}

/* Calculateur inline */
.hsc-calculator {
  background: #fff8e1;
  padding: 20px;
  border-radius: 8px;
  margin-bottom: 15px;
  border: 1px solid #ffe082;
}

.hsc-measurement-reminder {
  color: #666;
  font-size: 0.9em;
  margin-bottom: 15px;
  line-height: 1.4;
}

.hsc-input-group {
  margin-bottom: 10px;
}

.hsc-input-group label {
  display: block;
  margin-bottom: 8px;
  font-weight: 500;
  color: #333;
}

.hsc-input-wrapper {
  display: flex;
  align-items: center;
  gap: 8px;
}

#hsc-chest-input {
  width: 100px;
  padding: 10px 12px;
  border: 2px solid #ddd;
  border-radius: 6px;
  font-size: 1.1em;
  text-align: center;
  transition: border-color 0.2s ease;
}

#hsc-chest-input:focus {
  outline: none;
  border-color: #19212e;
}

.hsc-unit {
  color: #666;
  font-weight: 500;
}

/* Résultat du calcul */
.hsc-calc-result {
  margin-top: 12px;
  padding: 12px;
  border-radius: 6px;
  font-size: 0.95em;
  line-height: 1.4;
  display: none;
}

.hsc-calc-result:not(:empty) {
  display: block;
}

.hsc-calc-result.hsc-match {
  background: #e8f5e9;
  color: #2e7d32;
  border: 1px solid #a5d6a7;
}

.hsc-calc-result.hsc-no-match {
  background: #fff3e0;
  color: #e65100;
  border: 1px solid #ffcc80;
}

/* Lien vers le guide */
.hsc-guide-link {
  text-align: center;
  margin-bottom: 5px;
}

.hsc-link {
  color: #1976D2;
  text-decoration: none;
  font-size: 0.95em;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  transition: color 0.2s ease;
}

.hsc-link:hover {
  color: #0d47a1;
  text-decoration: underline;
}

/* Boutons d'action */
.hsc-actions {
  display: flex;
  gap: 12px;
  padding: 20px 25px;
  background: #f9f9f9;
  border-radius: 0 0 12px 12px;
  border-top: 1px solid #eee;
}

.hsc-btn {
  flex: 1;
  padding: 14px 20px;
  border: none;
  border-radius: 8px;
  font-size: 1em;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s ease;
}

.hsc-btn-cancel {
  background: #fff;
  color: #666;
  border: 2px solid #ddd;
}

.hsc-btn-cancel:hover {
  background: #f5f5f5;
  border-color: #bbb;
  color: #333;
}

.hsc-btn-confirm {
  background: #19212e;
  color: #fff;
}

.hsc-btn-confirm:hover {
  background: #2a3544;
  box-shadow: 0 2px 8px rgba(25, 33, 46, 0.4);
}

/* Responsive */
@media (max-width: 480px) {
  .hsc-popup {
    width: 95%;
    max-height: 95vh;
  }
  
  .hsc-header {
    padding: 15px 20px;
  }
  
  .hsc-header h3 {
    font-size: 1.2em;
  }
  
  .hsc-content {
    padding: 20px;
  }
  
  .hsc-actions {
    flex-direction: column;
    padding: 15px 20px;
  }
  
  .hsc-btn {
    padding: 12px 16px;
  }
}
