/* SM Repair 49 - Stylesheet Thème Clair & Professionnel */
@import url('https://fonts.googleapis.com/css2?family=Plus+Jakarta+Sans:wght@300;400;500;600;700;800&family=Outfit:wght@500;600;700;800;900&display=swap');

:root {
  --primary: #0284c7;
  --primary-dark: #0369a1;
  --primary-light: #e0f2fe;
  --accent-green: #16a34a;
  --accent-green-dark: #15803d;
  --accent-green-light: #ecfdf5;
  --bg-page: #f8fafc;
  --bg-card: #ffffff;
  --border-card: #e2e8f0;
  --text-main: #0f172a;
  --text-muted: #64748b;
}

body {
  font-family: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, sans-serif;
  background-color: var(--bg-page);
  color: var(--text-main);
  overflow-x: hidden;
  scroll-behavior: smooth;
}

h1, h2, h3, h4, .font-heading {
  font-family: 'Outfit', sans-serif;
}

/* Navigation Header */
.site-nav {
  background: #ffffff;
  border-bottom: 1px solid #e2e8f0;
  box-shadow: 0 1px 3px 0 rgba(0, 0, 0, 0.05);
}

/* Clean Professional Cards */
.pro-card {
  background: #ffffff;
  border: 1px solid #e2e8f0;
  border-radius: 16px;
  box-shadow: 0 1px 3px 0 rgba(0, 0, 0, 0.04), 0 1px 2px -1px rgba(0, 0, 0, 0.03);
  transition: all 0.25s cubic-bezier(0.16, 1, 0.3, 1);
}

.pro-card:hover {
  transform: translateY(-3px);
  border-color: #cbd5e1;
  box-shadow: 0 10px 20px -5px rgba(0, 0, 0, 0.08);
}

/* Pulsing Badge Indicator */
.pulse-indicator {
  position: relative;
}
.pulse-indicator::before {
  content: '';
  position: absolute;
  top: 50%;
  left: 0;
  transform: translateY(-50%);
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background-color: #16a34a;
  box-shadow: 0 0 0 0 rgba(22, 163, 74, 0.7);
  animation: pulse-ring 2s infinite;
}

@keyframes pulse-ring {
  0% {
    box-shadow: 0 0 0 0 rgba(22, 163, 74, 0.7);
  }
  70% {
    box-shadow: 0 0 0 8px rgba(22, 163, 74, 0);
  }
  100% {
    box-shadow: 0 0 0 0 rgba(22, 163, 74, 0);
  }
}

/* Floating Action Buttons */
.floating-btn {
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.15);
  transition: all 0.25s ease;
}
.floating-btn:hover {
  transform: scale(1.08) translateY(-2px);
}
.floating-container-right {
  bottom: calc(1rem + env(safe-area-inset-bottom, 0px));
}
.floating-container-left {
  bottom: calc(1rem + env(safe-area-inset-bottom, 0px));
}
@media (max-width: 640px) {
  .floating-container-right {
    bottom: calc(0.75rem + env(safe-area-inset-bottom, 0px));
  }
  .floating-container-left {
    bottom: calc(0.75rem + env(safe-area-inset-bottom, 0px));
  }
}

/* Custom Scrollbar */
::-webkit-scrollbar {
  width: 8px;
}
::-webkit-scrollbar-track {
  background: #f1f5f9;
}
::-webkit-scrollbar-thumb {
  background: #cbd5e1;
  border-radius: 4px;
}
::-webkit-scrollbar-thumb:hover {
  background: #94a3b8;
}

/* Accordion */
.accordion-header[aria-expanded="true"] .accordion-icon {
  transform: rotate(180deg);
}
.accordion-icon {
  transition: transform 0.25s ease;
}

/* Device Catalog Cards */
.device-catalog-card {
  background: #ffffff;
  border: 1.5px solid #e2e8f0;
  border-radius: 18px;
  padding: 16px 12px 14px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: space-between;
  transition: all 0.25s cubic-bezier(0.16, 1, 0.3, 1);
  cursor: pointer;
  position: relative;
  min-height: 215px;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.04);
}

.device-catalog-card:hover {
  transform: translateY(-4px);
  border-color: #0284c7;
  box-shadow: 0 10px 25px -5px rgba(2, 132, 199, 0.15);
}

.device-catalog-card.active {
  border-color: #0284c7;
  border-width: 2px;
  background-color: #f0f9ff;
  box-shadow: 0 8px 24px -4px rgba(2, 132, 199, 0.22);
}

.device-catalog-card .device-img-wrap {
  height: 120px;
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
}

.device-catalog-card img {
  max-height: 110px;
  max-width: 120px;
  object-fit: contain;
  transition: transform 0.25s ease;
}

.device-catalog-card:hover img,
.device-catalog-card.active img {
  transform: scale(1.08);
}

.device-brand-label {
  display: block;
  font-size: 0.78rem;
  color: #64748b;
  font-weight: 600;
  text-align: center;
  margin-top: 8px;
  line-height: 1.2;
  text-transform: uppercase;
}

.device-model-label {
  display: block;
  font-size: 0.9rem;
  color: #0f172a;
  font-weight: 800;
  text-align: center;
  line-height: 1.2;
}

.device-price-pill {
  margin-top: 10px;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 5px 12px;
  border-radius: 9999px;
  background-color: #f1f5f9;
  border: 1px solid #e2e8f0;
  font-size: 0.75rem;
  font-weight: 800;
  color: #0284c7;
  transition: all 0.2s ease;
}

.device-catalog-card:hover .device-price-pill,
.device-catalog-card.active .device-price-pill {
  background-color: #0284c7;
  border-color: #0284c7;
  color: #ffffff;
}

/* Service Checkboxes (Atelier MS Repair style) */
.service-checkbox-label {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 9px 12px;
  background: #ffffff;
  border: 1px solid #cbd5e1;
  border-radius: 10px;
  cursor: pointer;
  transition: all 0.2s ease;
  user-select: none;
  font-size: 0.82rem;
  font-weight: 500;
  color: #1e293b;
}

.service-checkbox-label:hover {
  border-color: #16a34a;
  background: #f0fdf4;
}

.service-checkbox-label input[type="checkbox"] {
  accent-color: #16a34a;
  width: 16px;
  height: 16px;
  cursor: pointer;
}

.service-checkbox-label.active {
  border-color: #16a34a;
  background: #ecfdf5;
  color: #14532d;
  font-weight: 700;
  box-shadow: 0 1px 3px rgba(22, 163, 74, 0.15);
}

/* ============================================================
   STYLE 2: CONFIGURATEUR ATELIER 2 COLONNES (APPLE STORE STYLE)
   ============================================================ */
.category-pill {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 10px 14px;
  background-color: #f8fafc;
  border: 1.5px solid #e2e8f0;
  border-radius: 12px;
  color: #334155;
  font-size: 0.8rem;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
  user-select: none;
}

.category-pill:hover {
  background-color: #f1f5f9;
  border-color: #cbd5e1;
  color: #0f172a;
}

.category-pill.active {
  background-color: #0284c7;
  border-color: #0284c7;
  color: #ffffff;
  box-shadow: 0 4px 12px rgba(2, 132, 199, 0.25);
}

.category-pill.active i {
  color: #ffffff !important;
}

/* Repair Interactive Tiles */
.repair-tile-card {
  position: relative;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  min-height: 96px;
  padding: 12px 14px;
  background-color: #ffffff;
  border: 2px solid #e2e8f0;
  border-radius: 16px;
  cursor: pointer;
  transition: all 0.2s ease;
  user-select: none;
}

.repair-tile-card:hover {
  border-color: #94a3b8;
  background-color: #f8fafc;
  transform: translateY(-2px);
}

.repair-tile-card.active {
  border-color: #0284c7;
  background-color: #f0f9ff;
  box-shadow: 0 4px 14px rgba(2, 132, 199, 0.12);
}

.tile-check-icon {
  position: absolute;
  top: 10px;
  right: 10px;
  width: 20px;
  height: 20px;
  border-radius: 50%;
  background-color: #e2e8f0;
  color: #94a3b8;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 10px;
  transition: all 0.2s ease;
}

.repair-tile-card.active .tile-check-icon {
  background-color: #0284c7;
  color: #ffffff;
}

.tile-icon {
  font-size: 1.35rem;
  margin-bottom: 6px;
  transition: transform 0.2s ease;
}

.repair-tile-card:hover .tile-icon {
  transform: scale(1.1);
}

.tile-title {
  font-size: 0.8rem;
  font-weight: 700;
  color: #0f172a;
  line-height: 1.25;
}

.tile-price {
  font-size: 0.75rem;
  font-weight: 600;
  color: #64748b;
  margin-top: 4px;
}

.repair-tile-card.active .tile-price {
  color: #0369a1;
  font-weight: 800;
}

/* Image preview bounce / fade */
#preview-device-img {
  transition: transform 0.3s ease, opacity 0.25s ease;
}

#preview-device-img.switching {
  opacity: 0.3;
  transform: scale(0.95);
}

/* Catalog Filter Tabs */
.catalog-tab-btn {
  background-color: #ffffff;
  border: 1px solid #cbd5e1;
  color: #475569;
  transition: all 0.2s ease;
}

.catalog-tab-btn:hover {
  background-color: #f1f5f9;
  color: #0f172a;
}

.catalog-tab-btn.active {
  background-color: #0284c7 !important;
  color: #ffffff !important;
  border-color: #0284c7 !important;
  box-shadow: 0 2px 4px rgba(2, 132, 199, 0.2);
}

/* ============================================================
   STYLE 3: RECHERCHE EXPRESS & TABLEAU DE BORD IMMÉDIAT
   ============================================================ */
.quick-model-chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 7px 14px;
  border-radius: 9999px;
  background-color: #ffffff;
  border: 1.5px solid #e2e8f0;
  color: #334155;
  font-size: 0.78rem;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
  user-select: none;
}

.quick-model-chip:hover {
  border-color: #0284c7;
  color: #0284c7;
  background-color: #f0f9ff;
  transform: translateY(-1px);
}

.quick-model-chip.active {
  background-color: #0284c7;
  border-color: #0284c7;
  color: #ffffff;
  box-shadow: 0 3px 10px rgba(2, 132, 199, 0.25);
}

.price-service-card {
  background: #ffffff;
  border: 1.5px solid #e2e8f0;
  border-radius: 18px;
  padding: 18px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 14px;
  transition: all 0.2s ease;
}

.price-service-card:hover {
  border-color: #0284c7;
  box-shadow: 0 8px 24px rgba(2, 132, 199, 0.08);
  transform: translateY(-2px);
}

/* Modal Animation */
@keyframes modalPop {
  0% {
    opacity: 0;
    transform: scale(0.95) translateY(10px);
  }
  100% {
    opacity: 1;
    transform: scale(1) translateY(0);
  }
}

.modal-animate {
  animation: modalPop 0.25s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

/* ============================================================
   TARIFS PAR MODÈLE (STYLE MINIMALISTE - FOND BLANC ÉPURÉ)
   ============================================================ */
.tarifs-brand-pill {
  padding: 8px 18px;
  border-radius: 9999px;
  font-size: 0.82rem;
  font-weight: 600;
  background-color: #f8fafc;
  color: #475569;
  border: 1.5px solid #e2e8f0;
  cursor: pointer;
  transition: all 0.2s ease;
  user-select: none;
}

.tarifs-brand-pill:hover {
  border-color: #0284c7;
  color: #0284c7;
  background-color: #f0f9ff;
}

.tarifs-brand-pill.active {
  background-color: #0284c7;
  color: #ffffff;
  border-color: #0284c7;
  font-weight: 700;
  box-shadow: 0 4px 12px rgba(2, 132, 199, 0.25);
}

.model-accordion-item {
  transition: background-color 0.2s ease;
  background-color: #ffffff;
}

.model-accordion-header {
  padding: 16px 20px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  cursor: pointer;
  user-select: none;
  transition: background-color 0.15s ease;
}

.model-accordion-header:hover {
  background-color: #f8fafc;
}

.model-accordion-item.open .model-accordion-header {
  background-color: #f0f9ff;
}

.model-accordion-header h4 {
  color: #020617 !important; /* Ultra-noir pour lisibilité maximale */
}

.model-accordion-body {
  padding: 8px 20px 20px 20px;
  background-color: #fafafa;
  animation: fadeInDown 0.2s ease-out;
  color: #0f172a !important;
}

.model-accordion-body .border-b span:first-child {
  color: #0f172a !important;
  font-weight: 700 !important;
}

.model-accordion-body .price-value {
  color: #0369a1 !important;
  font-weight: 900 !important;
}

@keyframes fadeInDown {
  from {
    opacity: 0;
    transform: translateY(-4px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.btn-rdv-mint {
  background-color: #0284c7;
  color: #ffffff;
  font-weight: 800;
  font-size: 0.85rem;
  padding: 10px 22px;
  border-radius: 12px;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  transition: all 0.2s ease;
  box-shadow: 0 4px 14px rgba(2, 132, 199, 0.25);
  cursor: pointer;
}

.btn-rdv-mint:hover {
  background-color: #0369a1;
  transform: translateY(-1px);
  box-shadow: 0 6px 18px rgba(2, 132, 199, 0.35);
}

.custom-dark-scrollbar::-webkit-scrollbar {
  width: 6px;
}
.custom-dark-scrollbar::-webkit-scrollbar-track {
  background: #f8fafc;
}
.custom-dark-scrollbar::-webkit-scrollbar-thumb {
  background: #cbd5e1;
  border-radius: 3px;
}
.custom-dark-scrollbar::-webkit-scrollbar-thumb:hover {
  background: #94a3b8;
}

/* Impression optimisée pour la Fiche Colis A4 */
#colis-signature-canvas {
  touch-action: none;
  -webkit-touch-callout: none;
  -webkit-user-select: none;
  user-select: none;
}

@media print {
  body * {
    visibility: hidden !important;
  }
  #fiche-colis-modal,
  #fiche-colis-printable,
  #fiche-colis-printable * {
    visibility: visible !important;
  }
  #fiche-colis-modal {
    position: absolute !important;
    left: 0 !important;
    top: 0 !important;
    width: 100% !important;
    height: auto !important;
    background: transparent !important;
    padding: 0 !important;
    margin: 0 !important;
    display: block !important;
  }
  #fiche-colis-printable {
    position: absolute !important;
    left: 0 !important;
    top: 0 !important;
    width: 100% !important;
    padding: 10mm 15mm !important;
    margin: 0 !important;
    box-shadow: none !important;
    border: none !important;
    background: #ffffff !important;
    color: #000000 !important;
    page-break-inside: avoid !important;
  }
  .no-print {
    display: none !important;
  }
}
