.ma-page {
  min-height: 100vh;
  background: #f8f9fa;
  padding-top: 1rem;
  padding-bottom: 30px;
}

@media (min-width: 768px) {
  .ma-page {
    padding-top: 2rem;
  }
}

.ma-root {
  display: grid;
  gap: 20px;
}

/* En-tête (fil d’Ariane, titre, fiche, lien galerie, onglets résine/alu) : styles partagés dans medaille-epoxy.css (classes me-*) */

.ma-loading {
  background: #fff;
  border: 1px solid #e5e7eb;
  border-radius: 12px;
  padding: 18px;
  color: #64748b;
}

.ma-grid {
  display: grid;
  gap: 12px;
}

@media (min-width: 968px) {
  .ma-grid {
    grid-template-columns: 1fr 1fr;
    gap: 16px;
    align-items: start;
  }
}

.ma-card {
  background: #fff;
  border: 1px solid #e5e7eb;
  border-radius: 12px;
  padding: 10px;
  box-shadow: 0 2px 8px rgba(0,0,0,.06);
}

.ma-preview-wrap {
  background: #f5f5f5;
  border-radius: 8px;
  padding: 10px;
  display: flex;
  gap: 12px;
  justify-content: center;
  align-items: flex-start;
  box-shadow: inset 0 2px 8px rgba(0,0,0,.05);
  overflow: hidden;
}

.ma-preview-col {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
}

.ma-preview-col h4 {
  margin: 0;
  font-size: 11px;
  font-weight: 700;
  color: #2c3e50;
}

.ma-medal {
  width: 180px;
  height: 180px;
  position: relative;
  display: grid;
  place-items: center;
}

@media (max-width: 640px) {
  .ma-medal {
    width: 130px;
    height: 130px;
  }
}

.ma-medal__mask {
  position: absolute;
  inset: 0;
  background: #cccccc;
  -webkit-mask-repeat: no-repeat;
  -webkit-mask-size: contain;
  -webkit-mask-position: center;
  mask-repeat: no-repeat;
  mask-size: contain;
  mask-position: center;
  z-index: 1;
}

.ma-medal__base {
  width: 100%;
  height: 100%;
  object-fit: contain;
  filter: drop-shadow(0 4px 8px rgba(0,0,0,0.2));
  z-index: 2;
}

.ma-medal__text {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  font-weight: 800;
  color: #fff;
  text-align: center;
  z-index: 10;
  width: 78%;
  max-height: 70%;
  overflow: hidden;
  white-space: nowrap;
  line-height: 1.2;
  padding: 0 8px;
  box-sizing: border-box;
  pointer-events: none;
}

.ma-panel {
  background: #fff;
  border: 1px solid #e5e7eb;
  border-radius: 12px;
  padding: 10px;
  box-shadow: 0 2px 8px rgba(0,0,0,.06);
}

.ma-panel h3 {
  margin: 0 0 8px;
  font-size: 13px;
  font-weight: 800;
  color: #1e293b;
}

.ma-pills {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.ma-pill-btn {
  border-radius: 999px;
  padding: 6px 10px;
  border: 1px solid #d1d5db;
  background: #fff;
  color: #4b5563;
  font-size: 11px;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.ma-pill-btn.is-active {
  border: 2px solid #0f172a;
  background: #e5f2ff;
  color: #111827;
}

.ma-swatches {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

.ma-swatch {
  position: relative;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  border: 2px solid #e0e0e0;
  cursor: pointer;
}

.ma-swatch.is-active {
  border: 3px solid #2c3e50;
  box-shadow: 0 0 0 2px rgba(52,152,219,0.2);
}

.ma-input, .ma-select {
  width: 100%;
  padding: 6px 8px;
  border-radius: 6px;
  border: 2px solid #e2e8f0;
  font-size: 12px;
  font-family: inherit;
  box-sizing: border-box;
  height: 48px;
  min-height: 48px;
  line-height: 1.25;
}

.ma-help {
  font-size: 10px;
  color: #475569;
  margin: 4px 0 0;
}

.ma-price-box {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 12px;
  padding: 12px;
  background: #f8f9fa;
  border-radius: 6px;
  border: 2px solid #e0e0e0;
}

.ma-price-box strong {
  font-size: 14px;
  color: #1e293b;
}

.ma-price {
  font-size: 24px;
  font-weight: 900;
  color: #27ae60;
}

.ma-cta {
  width: 100%;
  padding: 12px 18px;
  border-radius: 6px;
  border: none;
  background: linear-gradient(135deg, var(--primary-500, #0ea5e9) 0%, var(--primary-700, #0369a1) 100%);
  color: #fff;
  font-weight: 800;
  font-size: 14px;
  cursor: pointer;
  box-shadow: 0 2px 8px rgba(14,165,233,0.3);
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.ma-cta__inner {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
}

.ma-cta__icon {
  flex-shrink: 0;
  display: block;
}

.ma-cta__label {
  line-height: 1.2;
}

.ma-modal {
  position: fixed;
  inset: 0;
  z-index: 20000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 18px;
  background: rgba(0,0,0,.5);
}

.ma-modal__panel {
  width: min(420px, 100%);
  background: #fff;
  border-radius: 16px;
  padding: 22px;
  text-align: center;
  box-shadow: 0 20px 60px rgba(0,0,0,.3);
}

.ma-modal__actions {
  display: flex;
  gap: 10px;
  margin-top: 14px;
}

.ma-btn {
  flex: 1;
  padding: 12px;
  border-radius: 12px;
  font-weight: 800;
  border: 2px solid var(--primary-500);
  background: #fff;
  color: var(--primary-700);
  cursor: pointer;
}

.ma-btn--primary {
  border: none;
  background: linear-gradient(135deg, var(--primary-500), var(--primary-700));
  color: #fff;
}

.ma-banners {
  display: grid;
  gap: 10px;
}

.ma-banner-item {
  background: #fff;
  border: 1px solid #e5e7eb;
  border-radius: 12px;
  padding: 12px 14px;
}

.ma-banner-item summary {
  cursor: pointer;
  font-weight: 900;
  color: #111827;
}

.ma-banner-item p {
  margin: 10px 0 0;
  color: #475569;
  line-height: 1.6;
}

