*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

:root {
  --red: #e63946;
  --red-dark: #c1121f;
  --orange: #f4841f;
  --green: #2a9d5c;
  --blue: #1d6fa4;
  --gray-light: #f5f6f8;
  --gray-border: #dde1e7;
  --gray-text: #666;
  --text: #222;
  --star: #f4c430;
}

body,
.merged-bc-page {
  font-family: 'Lato', sans-serif;
  background: #fff;
  color: var(--text);
  font-size: 14px;
}

#bcUploadSection {
  display: none;
}

#bcUploadSection.bc-visible {
  display: block;
}

/* ─────────────────────────────────────
   NAVBAR / BREADCRUMB
───────────────────────────────────── */
.navbar {
  display: flex;
  align-items: center;
  gap: 0;
  padding: 0 48px;
  border-bottom: 1px solid var(--gray-border);
  background: #fff;
  height: 48px;
}

.navbar-hamburger {
  font-size: 18px;
  color: #333;
  cursor: pointer;
  padding: 0 16px 0 0;
  border: none;
  background: none;
  line-height: 48px;
}

.navbar-items {
  display: flex;
  align-items: center;
  gap: 0;
  flex: 1;
}

.navbar-item {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 0 18px;
  height: 48px;
  font-size: 13.5px;
  font-weight: 600;
  color: #222;
  cursor: pointer;
  border-bottom: 2px solid transparent;
  white-space: nowrap;
  transition: color .15s, border-color .15s;
  text-decoration: none;
}

.navbar-item:hover,
.navbar-item.active {
  color: var(--red);
  border-bottom-color: var(--red);
}

.navbar-badge-express {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  color: var(--red);
  font-size: 13.5px;
  font-weight: 700;
}

.navbar-badge-express::before {
  content: "⏱";
  font-size: 13px;
}

.breadcrumb {
  padding: 10px 48px;
  font-size: 12px;
  color: #888;
  border-bottom: 1px solid var(--gray-border);
}

.breadcrumb a {
  color: #888;
  text-decoration: none;
}

.breadcrumb a:hover {
  text-decoration: underline;
}

.breadcrumb span {
  color: #333;
}

/* ─────────────────────────────────────
   MAIN LAYOUT
───────────────────────────────────── */
.product-page {
  display: grid;
  grid-template-columns: 420px 1fr 300px;
  gap: 40px;
  max-width: 1400px;
  margin: 24px auto;
  padding: 0 48px;
  align-items: start;
}

.gallery {
  position: sticky;
  top: 20px;
}

.sidebar {
  position: relative;
  overflow: visible;
}

/* ─────────────────────────────────────
   GALLERY
───────────────────────────────────── */
.badge-topsale {
  position: absolute;
  top: 14px;
  right: 14px;
  background: var(--red);
  color: #fff;
  font-size: 12px;
  font-weight: 700;
  padding: 5px 12px;
  border-radius: 4px;
  letter-spacing: .5px;
  z-index: 2;
}

.gallery-main {
  position: relative;
  background: #e8edf5;
  border-radius: 10px;
  overflow: hidden;
  aspect-ratio: 1 / 0.85;
}

.carousel-track {
  display: flex;
  height: 100%;
  transition: transform .4s cubic-bezier(.4, 0, .2, 1);
}

.carousel-slide {
  min-width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
}

.carousel-slide img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.carousel-arrow {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  background: rgba(255, 255, 255, .92);
  border: 1px solid var(--gray-border);
  border-radius: 50%;
  width: 36px;
  height: 36px;
  font-size: 22px;
  line-height: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  color: #444;
  z-index: 10;
  box-shadow: 0 2px 8px rgba(0, 0, 0, .12);
  transition: background .15s, color .15s;
  padding: 0;
}

.carousel-arrow:hover {
  background: #fff;
  color: var(--red);
}

.carousel-prev {
  left: 10px;
}

.carousel-next {
  right: 10px;
}

.carousel-dots {
  position: absolute;
  bottom: 12px;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  gap: 6px;
  z-index: 10;
}

.carousel-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: rgba(255, 255, 255, .5);
  border: 1.5px solid rgba(255, 255, 255, .8);
  cursor: pointer;
  transition: background .2s, transform .2s;
}

.carousel-dot.active {
  background: #fff;
  transform: scale(1.3);
}

.gallery-thumbs {
  display: flex;
  gap: 8px;
  margin-top: 10px;
}

.thumb {
  width: 72px;
  height: 52px;
  border-radius: 6px;
  border: 2px solid transparent;
  overflow: hidden;
  cursor: pointer;
  background: #e8edf5;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: border-color .2s;
}

.thumb.active {
  border-color: var(--red);
}

.thumb:hover {
  border-color: #aaa;
}

.thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: 4px;
}

/* ─────────────────────────────────────
   PRODUCT CENTER
───────────────────────────────────── */
.product-title {
  font-family: 'Nunito', sans-serif;
  font-size: 26px;
  font-weight: 800;
  color: #1a1a2e;
  margin-bottom: 10px;
  line-height: 1.2;
}

.reviews-row {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 24px;
}

.stars {
  color: var(--star);
  font-size: 17px;
  letter-spacing: 1px;
}

.rating-text {
  font-size: 13px;
  color: #555;
}

.badge-verified {
  background: #e8f4fd;
  color: var(--blue);
  border: 1px solid #b3d7f0;
  font-size: 11px;
  font-weight: 600;
  padding: 2px 8px;
  border-radius: 20px;
  display: flex;
  align-items: center;
  gap: 4px;
}

.badge-verified::before {
  content: "✓";
  font-weight: 800;
}

.product-form {
  display: flex;
  flex-direction: column;
  gap: 1px;
}

.form-row {
  display: grid;
  grid-template-columns: 160px 1fr auto;
  align-items: center;
  gap: 12px;
}

.form-label {
  font-size: 13px;
  font-weight: 600;
  color: #333;
}

.form-label .required {
  color: var(--red);
  margin-left: 2px;
}

.select-wrap {
  position: relative;
}

.select-wrap select {
  width: 100%;
  appearance: none;
  -webkit-appearance: none;
  background: #fff;
  border: 1.5px solid var(--gray-border);
  border-radius: 6px;
  padding: 9px 36px 9px 12px;
  font-size: 13px;
  color: #333;
  cursor: pointer;
  font-family: 'Lato', sans-serif;
  transition: border-color .2s, box-shadow .2s;
  outline: none;
}

.select-wrap select:hover {
  border-color: #aaa;
}

.select-wrap select:focus {
  border-color: var(--blue);
  box-shadow: 0 0 0 3px rgba(29, 111, 164, .1);
}

.select-wrap::after {
  content: "▾";
  position: absolute;
  right: 12px;
  top: 50%;
  transform: translateY(-50%);
  color: #666;
  pointer-events: none;
  font-size: 13px;
}

.help-btn {
  width: 22px;
  height: 22px;
  border-radius: 50%;
  border: 1.5px solid var(--gray-border);
  background: #fff;
  color: #aaa;
  font-size: 12px;
  font-weight: 700;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  transition: border-color .2s, color .2s;
}

.help-btn:hover {
  border-color: var(--blue);
  color: var(--blue);
}

.divider {
  border: none;
  border-top: 1px solid var(--gray-border);
  margin: 4px 0;
}

.tooltip-container {
  position: relative;
  display: inline-flex;
}

.tooltip-content {
  display: none;
  position: absolute;
  bottom: calc(100% + 8px);
  left: 50%;
  transform: translateX(-50%);
  background: #333;
  color: #fff;
  font-size: 11px;
  padding: 6px 10px;
  border-radius: 0;           /* ← carré */
  white-space: normal;        /* ← retour à la ligne */
  width: max-content;
  max-width: 280px;           /* ← largeur max lisible */
  z-index: 100;
  pointer-events: none;
}

.tooltip-container:hover .tooltip-content {
  display: block;
}

/* ─────────────────────────────────────
   RIGHT SIDEBAR
───────────────────────────────────── */
.price-box {
  position: sticky;
  top: 20px;
  z-index: 30;
  background: #fff;
  border: 1.5px solid var(--gray-border);
  border-radius: 10px;
  padding: 20px;
  margin-bottom: 12px;
}

.price-main {
  font-family: 'Nunito', sans-serif;
  font-size: 30px;
  font-weight: 900;
  color: var(--red);
  text-align: center;
  line-height: 1;
  margin-bottom: 6px;
}

.price-ht {
  font-size: 16px;
  font-weight: 600;
}

.delivery-dates {
  text-align: center;
  font-size: 12px;
  color: #666;
  margin-bottom: 16px;
  line-height: 1.5;
}

.delivery-dates strong {
  color: #222;
  font-weight: 700;
}

.btn-cart {
  width: 100%;
  background: var(--red);
  color: #fff;
  border: none;
  border-radius: 8px;
  padding: 14px;
  font-size: 15px;
  font-weight: 800;
  font-family: 'Nunito', sans-serif;
  letter-spacing: .3px;
  cursor: pointer;
  transition: background .2s, transform .1s;
}

.btn-cart:hover {
  background: var(--red-dark);
}

.btn-cart:active {
  transform: scale(.98);
}

.shipping-info {
  border: 1.5px solid #b3e6cc;
  border-radius: 10px;
  padding: 14px 16px;
  margin-top: 12px;
  background: #f0fbf4;
}

.shipping-title {
  color: var(--green);
  font-weight: 700;
  font-size: 13px;
  margin-bottom: 6px;
  display: flex;
  align-items: center;
  gap: 8px;
}

.shipping-desc,
.devis-desc {
  font-size: 11.5px;
  color: #555;
  line-height: 1.6;
}

.promo-box {
  border: 1.5px dashed var(--red);
  border-radius: 10px;
  padding: 14px 16px;
  margin-top: 12px;
  text-align: center;
  font-size: 13px;
  color: #444;
  line-height: 1.6;
}

.promo-box strong {
  color: var(--red);
}

.devis-box {
  border: 1.5px solid var(--gray-border);
  border-radius: 10px;
  padding: 16px;
  margin-top: 12px;
  background: var(--gray-light);
}

.devis-title {
  font-size: 13px;
  font-weight: 700;
  color: #333;
  margin-bottom: 6px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.devis-title a {
  color: var(--blue);
  text-decoration: none;
  font-weight: 600;
  font-size: 13px;
}

.devis-title a:hover {
  text-decoration: underline;
}

/* ─────────────────────────────────────
   SIDE UPLOAD
───────────────────────────────────── */
.bc-side-upload {
  display: none;
  margin-bottom: 16px;
}

.bc-side-upload.bc-visible {
  display: block;
}

.bc-side-upload-inner {
  background: #fff;
  border: 1px solid var(--gray-border);
  border-radius: 10px;
  padding: 16px;
}

.bc-side-upload-title {
  font-family: 'Nunito', sans-serif;
  font-size: 20px;
  font-weight: 800;
  color: #1a1a2e;
  margin-bottom: 6px;
}

.bc-side-upload-subtitle {
  font-size: 13px;
  color: #555;
  line-height: 1.5;
  margin-bottom: 14px;
}

.bc-side-upload .bc-field {
  margin-bottom: 14px;
}

.bc-side-upload .bc-file-input,
.bc-side-upload .bc-select,
.bc-side-upload .bc-gabarit-select {
  width: 100%;
}

.bc-side-upload .bc-preview-btn {
  width: 100%;
  justify-content: center;
}

.bc-side-upload #cardPreviewBox {
  width: 100%;
  max-width: 260px;
  height: 165px;
}

/* ─────────────────────────────────────
   UPLOAD SECTION
───────────────────────────────────── */
.upload-section {
  max-width: 1400px;
  margin: 0 auto 32px;
  padding: 0 48px;
}

.upload-box {
  border: 1.5px solid var(--gray-border);
  border-radius: 10px;
  padding: 20px 24px 16px;
  max-width: 660px;
  margin: 0 auto;
  background: #fff;
}

.upload-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  width: 100%;
  background: #ebebeb;
  border: none;
  border-radius: 50px;
  padding: 16px 24px;
  font-size: 15px;
  font-family: 'Lato', sans-serif;
  font-weight: 500;
  color: #333;
  cursor: pointer;
  transition: background .2s;
}

.upload-btn:hover {
  background: #ddd;
}

.upload-btn .pencil-icon {
  font-size: 17px;
}

.upload-link {
  display: block;
  text-align: right;
  margin-top: 10px;
  font-size: 13px;
  color: #555;
  text-decoration: underline;
  cursor: pointer;
}

.upload-link:hover {
  color: var(--blue);
}

/* ─────────────────────────────────────
   ADVANCED UPLOAD PANEL
───────────────────────────────────── */
.bc-upload-panel {
  max-width: 1400px;
  margin: 20px auto 0;
  padding: 0 48px;
}

.bc-upload-panel-inner {
  background: #fff;
  border: 1px solid #e5e7eb;
  border-radius: 12px;
  padding: 18px;
}

.bc-upload-grid {
  display: grid;
  grid-template-columns: 1fr 320px;
  gap: 18px;
}

.bc-field {
  margin-bottom: 14px;
}

.bc-label {
  display: block;
  font-size: 15px;
  font-weight: 600;
  color: #334155;
  margin-bottom: 8px;
}

.bc-help {
  display: block;
  color: #64748b;
  font-size: 13px;
  margin-top: 6px;
}

.bc-file-input,
.bc-select {
  width: 100%;
  height: 46px;
  border: 1px solid #d6dde5;
  border-radius: 10px;
  padding: 0 14px;
  background: #fff;
}

.bc-radio-group {
  display: flex;
  gap: 18px;
  flex-wrap: wrap;
}

.bc-inline-option {
  display: flex;
  align-items: center;
  gap: 8px;
}

.bc-preview-btn {
  height: 44px;
  border-radius: 10px;
  border: 1px solid #d6dde5;
  background: #fff;
  color: #15335b;
  padding: 0 16px;
  font-weight: 600;
  cursor: pointer;
}

.bc-gabarit-download {
  min-height: 44px;
  padding: 10px 14px;
  border-radius: 10px;
  background: #f8fafc;
  border: 1px dashed #cbd5e1;
  color: #15335b;
  width: 100%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  text-decoration: none;
}

.bc-gabarit-or {
  margin: 10px 0;
  text-align: center;
  color: #94a3b8;
}

.bc-gabarit-select {
  width: 100%;
  height: 44px;
  border: 1px solid #d6dde5;
  border-radius: 10px;
  padding: 0 12px;
}

.bc-gabarit-help-link {
  display: inline-block;
  margin-top: 10px;
  color: #2563eb;
  text-decoration: none;
}

.bc-file-validation {
  display: none;
}

.bc-file-validation.show {
  display: block;
  padding: 12px 14px;
  border-radius: 10px;
  margin-bottom: 14px;
}

.bc-file-validation.danger {
  background: #fef2f2;
  color: #b91c1c;
}

.bc-file-validation.success {
  background: #ecfdf5;
  color: #166534;
}

.bc-preview-hidden {
  display: none;
}

.bc-preview-visible {
  display: block;
}

.bc-preview-actions {
  text-align: right;
  margin-bottom: 8px;
}

.bc-preview-trash {
  width: 36px;
  height: 36px;
  border: 1px solid #d6dde5;
  border-radius: 50%;
  background: #fff;
  cursor: pointer;
}

.bc-hidden {
  display: none !important;
}

/* ─────────────────────────────────────
   ANALYSIS PANEL
───────────────────────────────────── */
.analysis-panel {
  max-width: 660px;
  margin: 12px auto 0;
  border: 1.5px solid var(--gray-border);
  border-radius: 10px;
  overflow: hidden;
  background: #fff;
  box-shadow: 0 4px 16px rgba(0, 0, 0, .07);
  animation: slideDown .3s ease;
}

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

.analysis-header {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 14px 18px;
  background: #f5f6f8;
  border-bottom: 1px solid var(--gray-border);
  font-weight: 700;
  font-size: 14px;
  color: #222;
}

.analysis-header-icon {
  font-size: 17px;
}

.analysis-header-title {
  flex: 1;
}

.analysis-close {
  background: none;
  border: none;
  color: #aaa;
  font-size: 16px;
  cursor: pointer;
  padding: 0 4px;
  line-height: 1;
  transition: color .15s;
}

.analysis-close:hover {
  color: var(--red);
}

.analysis-file-info {
  padding: 10px 18px;
  font-size: 12.5px;
  color: #666;
  background: #fafbfc;
  border-bottom: 1px solid var(--gray-border);
  display: flex;
  gap: 16px;
  flex-wrap: wrap;
}

.analysis-file-info span {
  display: flex;
  align-items: center;
  gap: 5px;
}

.analysis-loading {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 22px 18px;
  font-size: 13.5px;
  color: #666;
}

.analysis-spinner {
  width: 22px;
  height: 22px;
  border: 3px solid #e8edf5;
  border-top-color: var(--red);
  border-radius: 50%;
  animation: spin .7s linear infinite;
  flex-shrink: 0;
}

@keyframes spin {
  to { transform: rotate(360deg); }
}

.analysis-results {
  padding: 16px 18px;
}

.analysis-result-row {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  padding: 10px 0;
  border-bottom: 1px solid #f0f2f5;
  font-size: 13.5px;
}

.analysis-result-row:last-child {
  border-bottom: none;
}

.analysis-result-icon {
  width: 22px;
  height: 22px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 12px;
  flex-shrink: 0;
  margin-top: 1px;
  font-weight: 700;
}

.icon-ok { background: #d4f0e0; color: #1a6b3c; }
.icon-warn { background: #fff3cd; color: #856404; }
.icon-error { background: #fde8e8; color: #a10000; }
.icon-info { background: #e8f4fd; color: #1d6fa4; }

.analysis-result-body {
  flex: 1;
}

.analysis-result-label {
  font-weight: 700;
  color: #222;
  margin-bottom: 2px;
  display: flex;
  align-items: center;
  gap: 8px;
}

.analysis-result-value {
  color: #555;
  font-size: 13px;
}

.analysis-result-advice {
  margin-top: 4px;
  font-size: 12px;
  color: #888;
  font-style: italic;
}

.tag-ok,
.tag-warn,
.tag-error,
.tag-info {
  padding: 2px 8px;
  border-radius: 20px;
  font-size: 11px;
  font-weight: 600;
}

.tag-ok { background: #d4f0e0; color: #1a6b3c; }
.tag-warn { background: #fff3cd; color: #856404; }
.tag-error { background: #fde8e8; color: #a10000; }
.tag-info { background: #e8f4fd; color: #1d6fa4; }

.analysis-score-bar {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 14px 18px;
  background: #f5f6f8;
  border-top: 1px solid var(--gray-border);
  font-size: 13px;
  color: #555;
}

.analysis-score-label {
  font-weight: 700;
  color: #222;
}

.score-dots {
  display: flex;
  gap: 4px;
}

.score-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
}

.analysis-actions {
  display: flex;
  gap: 10px;
  padding: 14px 18px;
  border-top: 1px solid var(--gray-border);
  background: #fafbfc;
}

.btn-analysis-continue {
  flex: 1;
  background: var(--red);
  color: #fff;
  border: none;
  border-radius: 7px;
  padding: 11px 16px;
  font-size: 13.5px;
  font-weight: 700;
  font-family: 'Lato', sans-serif;
  cursor: pointer;
  transition: background .2s;
}

.btn-analysis-continue:hover {
  background: var(--red-dark);
}

.btn-analysis-reupload {
  background: #fff;
  color: #555;
  border: 1.5px solid var(--gray-border);
  border-radius: 7px;
  padding: 11px 16px;
  font-size: 13px;
  font-weight: 600;
  font-family: 'Lato', sans-serif;
  cursor: pointer;
  transition: border-color .2s, color .2s;
}

.btn-analysis-reupload:hover {
  border-color: #aaa;
  color: #222;
}

/* ─────────────────────────────────────
   TABS
───────────────────────────────────── */
.tabs-section {
  max-width: 1400px;
  margin: 0 auto;
  padding: 0 48px;
}

.tabs-nav {
  display: flex;
  gap: 0;
  margin-bottom: 0;
}

.tab-btn {
  padding: 13px 22px;
  font-size: 13.5px;
  font-family: 'Lato', sans-serif;
  font-weight: 600;
  background: #f0f2f5;
  border: 1px solid var(--gray-border);
  border-bottom: none;
  color: #666;
  cursor: pointer;
  margin-right: -1px;
  position: relative;
  top: 1px;
  border-radius: 6px 6px 0 0;
  transition: background .15s, color .15s;
}

.tab-btn:hover {
  background: #e4e8ed;
  color: #222;
}

.tab-btn.active {
  background: #fff;
  color: #1a1a2e;
  font-weight: 700;
  border-color: var(--gray-border);
  border-bottom: 2px solid #fff;
  z-index: 2;
}

.tab-btn[data-tab="details"].active {
  border-top: 3px solid #1d6fa4;
  color: #1d6fa4;
}

.tab-btn[data-tab="aide"].active {
  border-top: 3px solid #f4841f;
  color: #f4841f;
}

.tab-btn[data-tab="gabarits"].active {
  border-top: 3px solid #2a9d5c;
  color: #2a9d5c;
}

.tab-btn[data-tab="avis"].active {
  border-top: 3px solid #e63946;
  color: #e63946;
}

.tabs-content {
  border: 1px solid var(--gray-border);
  border-radius: 0 6px 6px 6px;
  padding: 36px 40px 44px;
  background: #fff;
}

.tab-panel {
  display: none;
}

.tab-panel.active {
  display: block;
}

/* ─────────────────────────────────────
   CONTENT PANELS
───────────────────────────────────── */
.details-title {
  font-family: 'Nunito', sans-serif;
  font-size: 22px;
  font-weight: 800;
  color: #1a1a2e;
  margin-bottom: 18px;
  line-height: 1.3;
}

.details-text,
.aide-text,
.gabarits-text {
  font-size: 13.5px;
  color: #444;
  line-height: 1.8;
  margin-bottom: 10px;
}

.details-text strong,
.aide-text strong,
.aide-intro strong {
  color: #222;
}

.details-spacer {
  height: 16px;
}

.details-list,
.gabarits-list {
  list-style: disc;
  padding-left: 28px;
  margin: 8px 0 16px;
}

.details-list li,
.gabarits-list li {
  font-size: 13.5px;
  color: #444;
  line-height: 2.1;
}

.details-note {
  background: #fff8f0;
  border-left: 3px solid #f4841f;
  padding: 12px 16px;
  border-radius: 0 6px 6px 0;
  font-size: 13px;
  color: #555;
  margin: 16px 0;
  line-height: 1.7;
}

.details-promo {
  background: #f0f7fd;
  border-left: 3px solid #1d6fa4;
  padding: 12px 16px;
  border-radius: 0 6px 6px 0;
  font-size: 13px;
  color: #1d6fa4;
  margin: 16px 0;
  font-weight: 600;
}

.details-ref {
  font-size: 12px;
  color: #aaa;
  margin-top: 20px;
}

.aide-intro {
  font-size: 13.5px;
  color: #444;
  line-height: 1.8;
  margin-bottom: 14px;
}

.aide-phone {
  display: inline-block;
  background: #f0f7fd;
  border: 1px solid #b3d7f0;
  border-radius: 6px;
  padding: 8px 16px;
  font-size: 13px;
  color: #1d6fa4;
  font-weight: 600;
  margin-top: 8px;
}

.gabarits-intro {
  font-size: 13.5px;
  color: #444;
  margin-bottom: 16px;
  line-height: 1.7;
}

.gabarit-files-box {
  border: 1px solid var(--gray-border);
  border-radius: 8px;
  overflow: hidden;
  margin-bottom: 28px;
}

.gabarit-file-row {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 11px 16px;
  font-size: 13px;
  color: #333;
  border-bottom: 1px solid var(--gray-border);
  cursor: pointer;
  transition: background .15s;
  text-decoration: none;
}

.gabarit-file-row:last-of-type {
  border-bottom: none;
}

.gabarit-file-row:hover {
  background: #f5f6f8;
}

.gabarit-aide-link {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 11px 16px;
  font-size: 13px;
  color: var(--red);
  font-weight: 600;
  border-top: 1px solid var(--gray-border);
  cursor: pointer;
  transition: background .15s;
}

.gabarit-aide-link:hover {
  background: #fff5f5;
}

.gabarits-section-title {
  font-weight: 700;
  font-size: 14px;
  color: #222;
  margin: 24px 0 12px;
}

.legend-row {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  font-size: 13.5px;
  color: #444;
  line-height: 1.7;
  margin-bottom: 12px;
}

.legend-dot {
  width: 14px;
  height: 14px;
  border-radius: 50%;
  flex-shrink: 0;
  margin-top: 3px;
}

.avis-summary {
  display: flex;
  align-items: center;
  gap: 32px;
  margin-bottom: 28px;
  padding-bottom: 24px;
  border-bottom: 1px solid var(--gray-border);
}

.avis-score-big {
  font-family: 'Nunito', sans-serif;
  font-size: 56px;
  font-weight: 900;
  color: #1a1a2e;
  line-height: 1;
}

.avis-score-sub {
  font-size: 13px;
  color: #888;
  margin-top: 4px;
}

.avis-stars-big {
  color: var(--star);
  font-size: 24px;
  letter-spacing: 2px;
}

.avis-bars {
  flex: 1;
}

.avis-bar-row {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 5px;
}

.avis-bar-label {
  font-size: 12px;
  color: #888;
  width: 42px;
  text-align: right;
  flex-shrink: 0;
}

.avis-bar-track {
  flex: 1;
  height: 8px;
  background: #eee;
  border-radius: 10px;
  overflow: hidden;
}

.avis-bar-fill {
  height: 100%;
  background: var(--star);
  border-radius: 10px;
}

.avis-bar-count {
  font-size: 12px;
  color: #888;
  width: 28px;
  flex-shrink: 0;
}

.avis-list {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.avis-item {
  border: 1.5px solid var(--gray-border);
  border-radius: 8px;
  padding: 16px 20px;
}

.avis-item-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 8px;
}

.avis-item-stars {
  color: var(--star);
  font-size: 14px;
}

.avis-item-date {
  font-size: 11.5px;
  color: #aaa;
}

.avis-item-name {
  font-weight: 700;
  font-size: 13px;
  margin-bottom: 4px;
}

.avis-item-text {
  font-size: 13px;
  color: #555;
  line-height: 1.6;
}

/* ─────────────────────────────────────
   CARD PREVIEW / MODALS
───────────────────────────────────── */
#cardPreviewBox,
#cardPreviewBoxModal {
  perspective: 1000px;
  width: 270px;
  height: 170px;
  position: relative;
  transition: transform .8s;
  transform-style: preserve-3d;
  cursor: pointer;
  margin: auto;
}

.card-face {
  position: absolute;
  inset: 0;
  backface-visibility: hidden;
  border-radius: 10px;
  overflow: hidden;
  background: #fff;
}

.card-face.back {
  transform: rotateY(180deg);
}

.bc-modal-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(15, 23, 42, .55);
  opacity: 0;
  visibility: hidden;
  transition: .25s;
  z-index: 1040;
}

.bc-modal-backdrop.show {
  opacity: 1;
  visibility: visible;
}

.bc-preview-modal {
  position: fixed;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
  opacity: 0;
  visibility: hidden;
  transition: .25s;
  z-index: 1050;
}

.bc-preview-modal.show {
  opacity: 1;
  visibility: visible;
}

.bc-preview-modal-dialog {
  width: min(560px, 100%);
  background: #fff;
  border-radius: 16px;
  overflow: hidden;
  box-shadow: 0 20px 60px rgba(15, 23, 42, .25);
}

.bc-preview-modal-head,
.bc-preview-modal-foot {
  padding: 16px 18px;
  border-bottom: 1px solid #e5e7eb;
}

.bc-preview-modal-foot {
  border-bottom: 0;
  border-top: 1px solid #e5e7eb;
  text-align: right;
}

.bc-preview-modal-body {
  padding: 18px;
}

.bc-modal-close {
  border: 0;
  background: transparent;
  font-size: 28px;
  line-height: 1;
  float: right;
  cursor: pointer;
}

#gabaritModal {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(15, 23, 42, .55);
  z-index: 1060;
  align-items: center;
  justify-content: center;
  padding: 16px;
}

.gabarit-box {
  width: min(980px, 100%);
  max-height: 92vh;
  overflow: auto;
  background: #fff;
  border-radius: 16px;
}

/* ─────────────────────────────────────
   RESPONSIVE
───────────────────────────────────── */
@media (max-width: 1100px) {
  .product-page {
    grid-template-columns: 400px 1fr 280px;
    gap: 20px;
  }
}

@media (max-width: 900px) {
  .product-page {
    grid-template-columns: 1fr;
    padding: 0 16px;
  }

  .gallery,
  .sidebar,
  .price-box {
    position: static;
  }

  .navbar,
  .upload-section,
  .tabs-section,
  .bc-upload-panel,
  .breadcrumb {
    padding-left: 16px;
    padding-right: 16px;
  }

  .bc-upload-grid {
    grid-template-columns: 1fr;
  }

  .bc-side-upload {
    display: block;
  }
}

.gallery-product {
  width: 100%;
  max-width: 455px;
}

.product-gallery-main {
  position: relative;
  background: #eef2f7;
  border-radius: 14px;
  min-height: 345px;
  overflow: hidden;
  padding: 18px 18px 44px;
}

.product-carousel-track {
  position: relative;
  width: 100%;
  height: 100%;
}

.product-carousel-slide {
  display: none;
  width: 100%;
  height: 100%;
}

.product-carousel-slide.is-active {
  display: block;
}

.product-slide-inner {
  width: 100%;
  height: 280px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.product-slide-image {
  display: block;
  max-width: 78%;
  max-height: 210px;
  width: auto;
  height: auto;
  object-fit: contain;
  margin: 0 auto;
  filter: drop-shadow(0 18px 22px rgba(0, 0, 0, 0.16));
}

.badge-topsale {
  position: absolute;
  top: 16px;
  right: 16px;
  z-index: 5;
  background: #ef434f;
  color: #fff;
  border-radius: 6px;
  font-size: 13px;
  font-weight: 700;
  padding: 8px 14px;
  line-height: 1;
}

.product-carousel-arrow {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 38px;
  height: 38px;
  border: 0;
  border-radius: 999px;
  background: #fff;
  box-shadow: 0 4px 16px rgba(0,0,0,.12);
  color: #666;
  font-size: 24px;
  line-height: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 6;
  cursor: pointer;
}

.product-carousel-arrow.carousel-prev {
  left: 12px;
}

.product-carousel-arrow.carousel-next {
  right: 12px;
}

.product-carousel-dots {
  position: absolute;
  left: 50%;
  bottom: 14px;
  transform: translateX(-50%);
  display: flex;
  gap: 8px;
}

.product-carousel-dots .carousel-dot {
  width: 8px;
  height: 8px;
  border-radius: 999px;
  background: #d6dde7;
  display: inline-block;
  cursor: pointer;
}

.product-carousel-dots .carousel-dot.active {
  background: #ffffff;
  border: 1px solid #d2d9e3;
}

.product-gallery-thumbs {
  display: flex;
  gap: 10px;
  margin-top: 12px;
  align-items: center;
  flex-wrap: wrap;
}

.product-thumb {
  width: 58px;
  height: 44px;
  border: 2px solid transparent;
  border-radius: 8px;
  background: #eef2f7;
  padding: 4px;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.product-thumb.active {
  border-color: #ef434f;
  background: #fff;
}

.product-thumb img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  border-radius: 4px;
  display: block;
}

#cardPreviewBox,
#cardPreviewBoxModal {
    position: relative;
    width: 260px;
    height: 165px;
    margin: 0 auto;
    perspective: 1200px;
    transform-style: preserve-3d;
    transition: width .2s ease, height .2s ease, transform .4s ease;
}

#cardPreviewBox.is-portrait,
#cardPreviewBoxModal.is-portrait {
    width: 180px;
    height: 280px;
}

#cardPreviewBox.is-landscape,
#cardPreviewBoxModal.is-landscape {
    width: 280px;
    height: 180px;
}

#cardPreviewBox .card-face,
#cardPreviewBoxModal .card-face {
    position: absolute;
    inset: 0;
    backface-visibility: hidden;
    border-radius: 10px;
    overflow: hidden;
    background: #fff;
    box-shadow: 0 8px 24px rgba(0,0,0,.12);
}

#cardPreviewBox .card-face.back,
#cardPreviewBoxModal .card-face.back {
    transform: rotateY(180deg);
}

#cardPreviewBox img,
#cardPreviewBoxModal img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    background: #fff;
    display: block;
}