:root {
  --blue: #1a6b9c;
  --blue-dark: #14557d;
  --blue-deep: #0c3d5c;
  --blue-light: #e8f4fa;
  --accent: #2d9cdb;
  --orange: #e85d04;
  --bg: #f4f8fb;
  --card: #ffffff;
  --text: #1a2b3c;
  --muted: #5a6d7e;
  --border: #d4e2ec;
  --radius: 16px;
  --nav-h: 64px;
  --top-h: 56px;
  --safe-b: env(safe-area-inset-bottom, 0px);
  --safe-t: env(safe-area-inset-top, 0px);
}

*, *::before, *::after { box-sizing: border-box; }

html, body {
  margin: 0;
  height: 100%;
  font-family: "Plus Jakarta Sans", system-ui, sans-serif;
  background: var(--bg);
  color: var(--text);
  -webkit-font-smoothing: antialiased;
  -webkit-tap-highlight-color: transparent;
}

body { overflow: hidden; }

#app {
  display: flex;
  flex-direction: column;
  height: 100dvh;
  max-width: 520px;
  margin: 0 auto;
  background: var(--bg);
  box-shadow: 0 0 0 1px var(--border);
}

.topbar {
  flex-shrink: 0;
  padding-top: var(--safe-t);
  background: rgba(255,255,255,.96);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border);
  z-index: 50;
}

.topbar-inner {
  display: flex;
  align-items: center;
  gap: 8px;
  height: var(--top-h);
  padding: 0 12px;
}

.brand {
  display: flex;
  align-items: center;
  gap: 8px;
  flex: 1;
  min-width: 0;
}

.brand-logo { height: 28px; width: auto; }

.brand-tag {
  font-size: 0.62rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  padding: 3px 8px;
  border-radius: 999px;
  background: linear-gradient(135deg, var(--blue), var(--accent));
  color: #fff;
}

.lang-pills {
  display: flex;
  gap: 2px;
  background: var(--blue-light);
  padding: 3px;
  border-radius: 8px;
  flex-shrink: 0;
}

.lang-pills button {
  border: none;
  background: transparent;
  color: var(--muted);
  font-size: 0.62rem;
  font-weight: 700;
  padding: 5px 7px;
  border-radius: 6px;
  font-family: inherit;
  cursor: pointer;
}

.lang-pills button.active {
  background: #fff;
  color: var(--blue-dark);
  box-shadow: 0 1px 4px rgba(12,61,92,.12);
}

.icon-btn {
  border: none;
  background: var(--blue-light);
  color: var(--blue);
  width: 36px;
  height: 36px;
  border-radius: 10px;
  display: grid;
  place-items: center;
  cursor: pointer;
  flex-shrink: 0;
}

.icon-btn.hidden { display: none; }

.main {
  flex: 1;
  overflow: hidden;
  position: relative;
}

.view {
  position: absolute;
  inset: 0;
  overflow-y: auto;
  overflow-x: hidden;
  -webkit-overflow-scrolling: touch;
  padding: 16px 14px calc(var(--nav-h) + var(--safe-b) + 16px);
  opacity: 0;
  pointer-events: none;
  transform: translateY(8px);
  transition: opacity .22s ease, transform .22s ease;
}

.view-active {
  opacity: 1;
  pointer-events: auto;
  transform: none;
}

.view-fds {
  padding: 0 0 calc(var(--nav-h) + var(--safe-b));
  overflow: hidden;
}

.view-fds iframe {
  width: 100%;
  height: 100%;
  border: none;
  background: #fff;
  display: block;
  overflow: hidden;
}

/* Home */
.hero-card {
  background: linear-gradient(145deg, var(--blue-deep) 0%, var(--blue) 55%, var(--accent) 100%);
  color: #fff;
  border-radius: var(--radius);
  padding: 22px 18px;
  margin-bottom: 14px;
  box-shadow: 0 16px 40px rgba(12,61,92,.22);
}

.hero-eyebrow {
  margin: 0 0 8px;
  font-size: 0.68rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  opacity: 0.85;
}

.hero-card h1 {
  margin: 0 0 10px;
  font-size: 1.65rem;
  font-weight: 800;
  letter-spacing: -0.03em;
  line-height: 1.08;
}

.hero-lead {
  margin: 0;
  font-size: 0.84rem;
  line-height: 1.5;
  opacity: 0.92;
}

.stats-scroll {
  display: flex;
  gap: 8px;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  padding-bottom: 4px;
  margin-bottom: 14px;
  scrollbar-width: none;
}

.stats-scroll::-webkit-scrollbar { display: none; }

.stat-pill {
  flex: 0 0 auto;
  scroll-snap-align: start;
  min-width: 42%;
  padding: 12px 14px;
  border-radius: 12px;
  background: var(--card);
  border: 1px solid var(--border);
}

.stat-pill strong {
  display: block;
  font-size: 1.2rem;
  font-weight: 800;
  color: var(--blue);
  letter-spacing: -0.02em;
  font-variant-numeric: tabular-nums;
}

.stat-pill span {
  font-size: 0.7rem;
  font-weight: 600;
  color: var(--muted);
}

.tile-grid {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.tile {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 4px;
  text-align: left;
  width: 100%;
  padding: 16px;
  border-radius: var(--radius);
  border: 1px solid var(--border);
  background: var(--card);
  cursor: pointer;
  font-family: inherit;
  transition: transform .15s, box-shadow .15s, border-color .15s;
}

.tile:active { transform: scale(0.98); }

.tile-primary {
  background: linear-gradient(135deg, #fff 0%, var(--blue-light) 100%);
  border-color: #bcd3e6;
}

.tile-icon { font-size: 1.3rem; line-height: 1; }

.tile-title {
  font-size: 0.95rem;
  font-weight: 800;
  color: var(--blue-deep);
}

.tile-desc {
  font-size: 0.78rem;
  color: var(--muted);
  line-height: 1.4;
}

.fine-print {
  margin: 16px 4px 0;
  font-size: 0.68rem;
  color: var(--muted);
  text-align: center;
  line-height: 1.45;
}

/* Products */
.products-news-wrap {
  padding: 0 0 12px;
}

.news-pill {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  width: 100%;
  padding: 10px 14px;
  border-radius: 100px;
  border: 1px solid rgba(255, 255, 255, 0.22);
  background: linear-gradient(135deg, var(--blue-deep) 0%, #1a6b9c 55%, #2380b0 100%);
  color: #fff;
  font-size: 0.82rem;
  font-weight: 700;
  cursor: pointer;
  box-shadow: 0 6px 20px rgba(15, 40, 70, 0.28);
  transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s;
  font-family: inherit;
  line-height: 1.2;
}

.news-pill:hover {
  transform: translateY(-1px);
  box-shadow: 0 10px 28px rgba(15, 40, 70, 0.35);
  border-color: rgba(255, 255, 255, 0.38);
}

.news-pill:focus-visible {
  outline: 2px solid #fff;
  outline-offset: 2px;
}

.news-pill-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #4ade80;
  box-shadow: 0 0 0 0 rgba(74, 222, 128, 0.55);
  animation: newsPulse 2.2s ease infinite;
  flex-shrink: 0;
}

.news-pill-label { letter-spacing: -0.01em; }

.news-pill-count {
  font-size: 0.72rem;
  font-weight: 800;
  padding: 2px 7px;
  border-radius: 100px;
  background: rgba(255, 255, 255, 0.2);
  color: #fff;
  border: 1px solid rgba(255, 255, 255, 0.25);
}

@keyframes newsPulse {
  0%, 100% { box-shadow: 0 0 0 0 rgba(74, 222, 128, 0.5); }
  50% { box-shadow: 0 0 0 5px rgba(74, 222, 128, 0); }
}

.news-sheet {
  position: fixed;
  inset: 0;
  z-index: 200;
  pointer-events: none;
  visibility: hidden;
}

.news-sheet.open {
  pointer-events: auto;
  visibility: visible;
}

.news-sheet-backdrop {
  position: absolute;
  inset: 0;
  border: none;
  padding: 0;
  background: rgba(15, 23, 42, 0.55);
  backdrop-filter: blur(6px);
  opacity: 0;
  transition: opacity 0.25s ease;
}

.news-sheet.open .news-sheet-backdrop {
  opacity: 1;
}

.news-sheet-panel {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  max-height: 85vh;
  display: flex;
  flex-direction: column;
  background: var(--card);
  border-radius: 20px 20px 0 0;
  border: 1px solid var(--border);
  box-shadow: 0 -12px 48px rgba(15, 23, 42, 0.22);
  transform: translateY(100%);
  transition: transform 0.28s cubic-bezier(0.22, 1, 0.36, 1);
  overflow: hidden;
}

.news-sheet.open .news-sheet-panel {
  transform: translateY(0);
}

.news-sheet-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
  padding: 18px 18px 12px;
  border-bottom: 1px solid var(--border);
  flex-shrink: 0;
}

.news-sheet-head h2 {
  margin: 0;
  font-size: 1.05rem;
  font-weight: 800;
  color: var(--blue-deep);
}

.news-sheet-head p {
  margin: 4px 0 0;
  font-size: 0.78rem;
  color: var(--muted);
}

.news-sheet-body {
  padding: 12px 18px calc(18px + var(--safe-b));
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.news-item {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px 10px;
  width: 100%;
  padding: 12px 14px;
  border-radius: 12px;
  background: var(--bg);
  border: 1px solid var(--border);
  text-align: left;
  font: inherit;
  color: inherit;
  transition: border-color 0.2s, box-shadow 0.2s;
}

button.news-item {
  cursor: pointer;
  -webkit-appearance: none;
  appearance: none;
}

.news-item--static {
  cursor: default;
}

button.news-item:active {
  border-color: rgba(26, 107, 156, 0.4);
  box-shadow: 0 2px 8px rgba(26, 107, 156, 0.12);
}

.news-item-name {
  flex: 1;
  min-width: 0;
  display: block;
  font-size: 0.88rem;
  font-weight: 700;
  line-height: 1.35;
  color: var(--text);
}

.news-item-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.news-tag {
  font-size: 0.68rem;
  font-weight: 700;
  padding: 3px 8px;
  border-radius: 100px;
  background: var(--blue-light);
  color: var(--blue-dark);
}

.news-tag.pro {
  background: #fef3c7;
  color: #92400e;
}

.news-empty {
  text-align: center;
  padding: 24px 12px;
}

.news-empty-icon {
  font-size: 1.5rem;
  margin-bottom: 8px;
  opacity: 0.5;
}

.news-empty h3 {
  margin: 0 0 6px;
  font-size: 0.95rem;
}

.news-empty p {
  margin: 0;
  font-size: 0.82rem;
  color: var(--muted);
  line-height: 1.45;
}

.search-bar {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 12px 14px;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 12px;
  margin-bottom: 12px;
  color: var(--muted);
  min-width: 0;
  max-width: 100%;
}

.search-bar input {
  flex: 1;
  border: none;
  outline: none;
  font-size: 0.92rem;
  font-family: inherit;
  background: transparent;
  color: var(--text);
  min-width: 0;
}

.search-bar .scan-btn {
  flex-shrink: 0;
  width: 38px;
  height: 38px;
  border-radius: 10px;
  border: 1px solid var(--border);
  background: var(--blue-light);
  color: var(--blue-dark);
  display: grid;
  place-items: center;
  padding: 0;
}

.search-bar .scan-btn:active {
  background: var(--blue);
  color: #fff;
  border-color: var(--blue);
}

.chip-row {
  display: flex;
  gap: 6px;
  overflow-x: auto;
  padding-bottom: 12px;
  scrollbar-width: none;
}

.chip-row::-webkit-scrollbar { display: none; }

.products-catalogue-notice {
  margin-bottom: 12px;
  padding: 10px 12px;
  border-radius: 10px;
  background: rgba(26, 107, 156, 0.08);
  border: 1px solid rgba(26, 107, 156, 0.15);
}

.catalogue-notice-text {
  margin: 0 0 8px;
  font-size: 0.78rem;
  line-height: 1.45;
  color: var(--blue-dark);
  text-align: center;
}

.catalogue-contact-hint {
  margin: 0;
  font-size: 0.76rem;
  line-height: 1.5;
  color: var(--muted);
  text-align: center;
}

.catalogue-contact-link {
  color: var(--blue);
  font-weight: 700;
  text-decoration: none;
}

.catalogue-contact-link:active {
  opacity: 0.75;
}

.catalogue-contact-sep {
  color: var(--muted);
  font-weight: 500;
}

.chip {
  flex-shrink: 0;
  border: 1px solid var(--border);
  background: var(--card);
  color: var(--muted);
  font-size: 0.72rem;
  font-weight: 700;
  padding: 7px 12px;
  border-radius: 999px;
  font-family: inherit;
  cursor: pointer;
}

.chip.active {
  background: var(--blue);
  border-color: var(--blue);
  color: #fff;
}

/* Catalogue v2 — filtres retail & gammes */
.filter-retail-group { margin-bottom: 6px; }

.filter-retail-group .chip-retail.active {
  background: linear-gradient(135deg, #3b82f6, #1e40af);
  border-color: transparent;
  color: #fff;
}

.filter-retail-group .chip-60s {
  border-color: #99f6e4;
  color: #0f766e;
}

.filter-retail-group .chip-60s.active {
  background: linear-gradient(135deg, #14b8a6, #0f766e);
  border-color: transparent;
  color: #fff;
}

.filter-retail-group .chip-chem {
  border-color: #fdba74;
  color: #c2410c;
}

.filter-retail-group .chip-chem.active {
  background: linear-gradient(135deg, #fb923c, #c2410c);
  border-color: transparent;
  color: #fff;
}

.product-card-badges {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
  margin-bottom: 6px;
  max-width: 100%;
  min-width: 0;
  width: 100%;
}

.product-card-body {
  flex: 1;
  min-width: 0;
  overflow: hidden;
}

.product-card-body h3 {
  margin: 0 0 4px;
  font-size: 0.84rem;
  font-weight: 800;
  line-height: 1.25;
  color: var(--blue-deep);
  word-break: break-word;
  overflow-wrap: anywhere;
}

.v2-chip {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 0.52rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.02em;
  padding: 2px 6px;
  border-radius: 100px;
  line-height: 1.2;
  border: 1px solid transparent;
  white-space: nowrap;
  flex: 0 0 auto;
  max-width: 100%;
  overflow: hidden;
  text-overflow: ellipsis;
  box-sizing: border-box;
}

.v2-retail { background: #dbeafe; color: #1e40af; }
.v2-60s { background: #ccfbf1; color: #0f766e; }
.v2-chem { background: #ffedd5; color: #c2410c; }
.v2-pro { background: #f3e8ff; color: #6b21a8; }
.v2-fds { background: #dcfce7; color: #166534; }
.v2-formats {
  background: rgba(255, 255, 255, 0.92);
  color: var(--blue-dark);
  border: 1px solid var(--border);
  flex: 0 1 auto;
  max-width: 100%;
}

.product-card-visual .emoji-fallback {
  font-size: 1.4rem;
  line-height: 1;
}

/* Placeholder verre dépoli (maquette produits-v2) */
.v2-ph {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  padding: 10px 10px 52px;
  overflow: hidden;
}

.v2-ph::before {
  content: "";
  position: absolute;
  width: 100px;
  height: 100px;
  border-radius: 50%;
  top: -30px;
  right: -30px;
  background: rgba(255, 255, 255, 0.35);
  pointer-events: none;
}

.v2-ph-top {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 6px;
  position: relative;
  z-index: 2;
  flex-shrink: 0;
}

.v2-ph-sector {
  font-size: 0.52rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  padding: 4px 8px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.72);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
  border: 1px solid rgba(255, 255, 255, 0.8);
  color: var(--blue-deep);
}

.v2-ph-soon {
  font-size: 0.48rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  padding: 3px 6px;
  border-radius: 6px;
  background: rgba(15, 23, 42, 0.06);
  color: rgba(15, 23, 42, 0.45);
  white-space: nowrap;
}

.v2-ph-body {
  flex: 1;
  display: flex;
  flex-direction: column;
  justify-content: center;
  position: relative;
  z-index: 2;
  padding: 6px 0;
  min-height: 0;
}

.v2-ph-name {
  font-size: clamp(0.72rem, 2.8vw, 0.85rem);
  font-weight: 800;
  letter-spacing: -0.02em;
  line-height: 1.15;
  color: var(--blue-deep);
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
  margin: 0;
}

.v2-ph-foot {
  position: relative;
  z-index: 2;
  margin-top: auto;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  align-content: center;
  gap: 3px;
  min-height: 34px;
  padding-top: 4px;
  padding-bottom: 2px;
}

.v2-ph--pack {
  background: linear-gradient(180deg, #f3f7fb 0%, #eef4f9 52%, #e2ebf4 100%);
}

.v2-ph-body--pack {
  flex: 1;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  min-height: 0;
  padding: 0 0 2px;
}

.v2-ph-pack-media {
  flex: 1;
  min-height: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 4px 8px 2px;
}

.v2-ph-pack-media img {
  display: block;
  width: auto;
  height: auto;
  max-width: 88%;
  max-height: 100%;
  object-fit: contain;
}

.v2-ph-name--pack {
  font-size: clamp(0.72rem, 2.4vw, 0.82rem);
  -webkit-line-clamp: 2;
  text-align: center;
  flex-shrink: 0;
  padding: 0 4px;
}

.v2-chip-format {
  background: rgba(12, 61, 92, 0.92);
  color: #fff;
  font-weight: 800;
}

.v2-ph-glass {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 3;
  padding: 8px 10px 10px;
  background: rgba(255, 255, 255, 0.58);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-top: 1px solid rgba(255, 255, 255, 0.75);
  display: flex;
  align-items: center;
  justify-content: center;
  pointer-events: none;
}

.v2-ph-glass > img {
  display: block;
  height: 18px;
  width: auto;
  max-width: 78%;
  max-height: none;
  object-fit: contain;
}

.v2-ph.cat-auto {
  background: linear-gradient(145deg, #dbeafe 0%, #bfdbfe 40%, #60a5fa33 100%);
}
.v2-ph.cat-menage {
  background: linear-gradient(145deg, #dcfce7 0%, #bbf7d0 45%, #4ade8033 100%);
}
.v2-ph.cat-peinture {
  background: linear-gradient(145deg, #ffedd5 0%, #fdba74 50%, #fb923c33 100%);
}
.v2-ph.cat-sanitaire {
  background: linear-gradient(145deg, #cffafe 0%, #67e8f9 45%, #06b6d433 100%);
}
.v2-ph.cat-batiment {
  background: linear-gradient(145deg, #e7e5e4 0%, #d6d3d1 50%, #a8a29e33 100%);
}
.v2-ph.cat-industrie {
  background: linear-gradient(145deg, #e2e8f0 0%, #cbd5e1 50%, #64748b33 100%);
}

@media (min-width: 640px) {
  .product-list {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 14px;
  }
}

.detail-desc {
  margin: 0 0 10px;
  font-size: 0.82rem;
  line-height: 1.45;
  color: var(--muted);
  word-break: break-word;
  overflow-wrap: anywhere;
}

.detail-badges {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-bottom: 8px;
  max-width: 100%;
  min-width: 0;
}

.pro-desc {
  margin: 0 0 16px;
  font-size: 0.88rem;
  line-height: 1.5;
  color: var(--text);
}

.variant-picker {
  margin-bottom: 16px;
  max-width: 100%;
  min-width: 0;
}

.variant-picker label {
  display: block;
  font-size: 0.68rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--muted);
  margin-bottom: 8px;
}

.variant-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  max-width: 100%;
}

.variant-chip {
  font-family: inherit;
  font-size: 0.82rem;
  font-weight: 600;
  padding: 9px 14px;
  border-radius: 12px;
  border: 2px solid var(--border);
  background: #fff;
  cursor: pointer;
  max-width: 100%;
  box-sizing: border-box;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
}

.variant-chip.active {
  border-color: var(--blue);
  background: var(--blue-light);
  color: var(--blue-dark);
}

.variant-chip-note {
  cursor: default;
  font-size: 0.68rem;
  font-weight: 500;
  padding: 7px 10px;
  border-style: dashed;
  background: #f8fafc;
  color: var(--muted);
  flex: 1 1 100%;
  width: 100%;
  max-width: 100%;
  line-height: 1.35;
  text-align: left;
  box-sizing: border-box;
}

.sku-panel {
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 14px 16px;
  margin-bottom: 16px;
  max-width: 100%;
  box-sizing: border-box;
}

.sku-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
}

.sku-row + .sku-row {
  margin-top: 10px;
  padding-top: 10px;
  border-top: 1px dashed var(--border);
}

.sku-label {
  font-size: 0.72rem;
  color: var(--muted);
  flex-shrink: 0;
}

.sku-row strong,
.sku-value {
  font-size: 0.82rem;
  font-weight: 700;
  word-break: break-word;
  text-align: right;
  flex: 1;
  min-width: 0;
  line-height: 1.3;
}

.sku-row-ean {
  flex-direction: column;
  align-items: stretch;
  gap: 10px;
}

.sku-row-ean > div {
  min-width: 0;
}

.sku-row-ean strong {
  display: block;
  text-align: left;
  font-size: 0.88rem;
  font-variant-numeric: tabular-nums;
  letter-spacing: 0.02em;
}

.btn-copy-ean {
  background: var(--blue-light);
  color: var(--blue-dark);
  border: 1px solid #bcd3e6;
  flex-shrink: 0;
  width: 100%;
  text-align: center;
  padding: 10px 12px;
  font-size: 0.75rem;
}

.fds-block {
  background: linear-gradient(135deg, var(--blue-deep), var(--blue));
  color: #fff;
  border-radius: 14px;
  padding: 14px 16px;
  margin-top: 8px;
  overflow: hidden;
  max-width: 100%;
  box-sizing: border-box;
}

.fds-block h3 {
  margin: 0 0 8px;
  font-size: 0.88rem;
  color: #fff;
  word-break: break-word;
  overflow-wrap: anywhere;
}

.fds-block .fds-portal-note {
  margin: 0 0 12px;
  font-size: 0.72rem;
  line-height: 1.45;
  padding: 10px 12px;
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.14);
  border: 1px solid rgba(255, 255, 255, 0.28);
  color: #fff;
  word-break: break-word;
  overflow-wrap: anywhere;
}

.fds-block .fds-langs-label {
  font-size: 0.68rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: rgba(255, 255, 255, 0.85);
  margin: 0 0 6px;
}

.fds-block .fds-langs {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
  margin-bottom: 12px;
  max-width: 100%;
  min-width: 0;
}

.fds-block .lang-dot {
  background: rgba(255, 255, 255, 0.2);
  color: #fff;
  flex-shrink: 0;
}

.fds-block .btn-dl.btn-full {
  background: #fff;
  color: var(--blue-deep);
  white-space: normal;
  word-wrap: break-word;
  overflow-wrap: anywhere;
  line-height: 1.35;
  font-size: 0.78rem;
  padding: 12px 14px;
  margin-top: 0;
  width: 100%;
  box-sizing: border-box;
  hyphens: auto;
}

.product-list {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  min-width: 0;
  max-width: 100%;
  align-items: start;
}

.product-card {
  display: flex;
  flex-direction: column;
  padding: 0;
  background: transparent;
  border: none;
  border-radius: 0;
  cursor: pointer;
  transition: transform .15s ease, box-shadow .15s ease;
  min-width: 0;
  max-width: 100%;
  box-sizing: border-box;
  box-shadow: none;
}

.product-card:active {
  transform: scale(0.98);
}

.product-card.is-ph-card:active,
.product-card.has-packshot-card:active {
  transform: translateY(-2px);
}

.product-card.is-ph-card,
.product-card.has-packshot-card {
  background: transparent;
  border: none;
  box-shadow: none;
}

.product-card-visual {
  position: relative;
  width: 100%;
  aspect-ratio: 1 / 1;
  border-radius: 14px;
  background: linear-gradient(165deg, #eef4f9 0%, #f8fafc 45%, #fff 100%);
  display: flex;
  flex-direction: column;
  align-items: stretch;
  justify-content: center;
  overflow: hidden;
  flex-shrink: 0;
  border: 1px solid var(--border);
  box-shadow: 0 4px 16px rgba(20, 85, 125, 0.08);
}

.product-card.is-ph-card .product-card-visual {
  aspect-ratio: 4 / 5;
}

.product-card-visual.has-packshot {
  background: transparent;
}

.product-card-visual.is-genz-ph {
  padding: 0;
  background: transparent;
}

.product-card-visual-media {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  min-height: 0;
  padding: 28px 10px 10px;
  box-sizing: border-box;
}

.product-card-visual-media img {
  display: block;
  width: auto;
  height: auto;
  max-width: 88%;
  max-height: 88%;
  object-fit: contain;
}

.product-card-visual-badges {
  position: absolute;
  top: 8px;
  left: 8px;
  z-index: 2;
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
  max-width: calc(100% - 16px);
}

.product-card-body-grid {
  display: none;
}

.product-card-body-split {
  display: none;
}

.product-card-body {
  padding: 12px 14px 14px;
  flex: 1;
  min-width: 0;
  overflow: hidden;
}

.product-card-body p {
  margin: 0;
  font-size: 0.72rem;
  color: var(--muted);
  word-break: break-word;
  overflow-wrap: anywhere;
}

.product-card-meta {
  display: flex;
  gap: 4px;
  margin-top: 6px;
  flex-wrap: wrap;
}

.lang-dot {
  font-size: 0.6rem;
  font-weight: 800;
  padding: 2px 6px;
  border-radius: 4px;
  background: var(--blue-light);
  color: var(--blue-dark);
}

.empty-state {
  text-align: center;
  padding: 32px 16px;
  color: var(--muted);
  font-size: 0.88rem;
}

.empty-state h3 {
  margin: 0 0 8px;
  color: var(--text);
  font-size: 1rem;
}

/* Product detail */
.detail-card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 16px;
  margin-bottom: 12px;
  overflow: hidden;
  max-width: 100%;
  box-sizing: border-box;
}

.detail-badge {
  display: inline-block;
  font-size: 0.62rem;
  font-weight: 800;
  text-transform: uppercase;
  padding: 4px 10px;
  border-radius: 999px;
  background: var(--blue-light);
  color: var(--blue-dark);
  margin-bottom: 10px;
  max-width: 100%;
  word-break: break-word;
  line-height: 1.35;
}

#product-detail {
  max-width: 100%;
  overflow: hidden;
}

.detail-card h2 {
  margin: 0 0 10px;
  font-size: 1rem;
  font-weight: 800;
  letter-spacing: -0.02em;
  line-height: 1.3;
  word-break: break-word;
  overflow-wrap: anywhere;
  color: var(--blue-deep);
}

.detail-path {
  font-size: 0.72rem;
  color: var(--muted);
  margin-bottom: 12px;
  word-break: break-all;
}

.fds-list { display: flex; flex-direction: column; gap: 8px; }

.fds-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 12px 14px;
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: 12px;
  min-width: 0;
  max-width: 100%;
  box-sizing: border-box;
}

.fds-row-info {
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-width: 0;
  flex: 1;
}

.fds-row-info strong {
  font-size: 0.82rem;
  color: var(--blue-deep);
}

.fds-row-info span {
  font-size: 0.68rem;
  color: var(--muted);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.fds-actions { display: flex; gap: 6px; flex-shrink: 0; }

.fds-actions .btn {
  white-space: nowrap;
}

.btn {
  border: none;
  font-family: inherit;
  font-size: 0.72rem;
  font-weight: 700;
  padding: 8px 12px;
  border-radius: 8px;
  cursor: pointer;
  white-space: normal;
  word-break: break-word;
  max-width: 100%;
  box-sizing: border-box;
}

.btn-open {
  background: var(--blue-light);
  color: var(--blue-dark);
  border: 1px solid #bcd3e6;
}

.btn-dl {
  background: var(--blue);
  color: #fff;
}

.btn-full {
  display: block;
  width: 100%;
  max-width: 100%;
  text-align: center;
  padding: 12px 14px;
  font-size: 0.82rem;
  margin-top: 8px;
  white-space: normal;
  line-height: 1.35;
  box-sizing: border-box;
}

.fds-row-lang {
  justify-content: flex-start;
}

.fds-portal-note {
  margin: 0 0 12px;
  font-size: 0.75rem;
  color: var(--muted);
  line-height: 1.45;
  padding: 10px 12px;
  border-radius: 10px;
  background: #fff8e6;
  border: 1px solid #f0d9a8;
}

.fds-langs-label {
  margin: 0 0 8px;
  font-size: 0.72rem;
  font-weight: 700;
  color: var(--blue-deep);
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.hidden { display: none !important; }

/* Contact */
.contact-hero {
  margin-bottom: 16px;
}

.contact-hero h2 {
  margin: 0 0 8px;
  font-size: 1.25rem;
  font-weight: 800;
  color: var(--blue-deep);
}

.contact-hero p {
  margin: 0;
  font-size: 0.88rem;
  color: var(--muted);
}

.contact-quick {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 8px;
  margin-bottom: 8px;
}

.contact-quick-btn {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  padding: 12px 6px;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 12px;
  text-decoration: none;
  color: var(--blue-deep);
  font-size: 0.68rem;
  font-weight: 700;
  text-align: center;
  transition: border-color .15s;
}

.contact-quick-btn:active { border-color: var(--accent); }

.contact-quick-ico { font-size: 1.25rem; line-height: 1; }

.contact-general-line {
  margin: 0 0 18px;
  text-align: center;
  font-size: 0.72rem;
  color: var(--muted);
}

.contact-section-head {
  margin-bottom: 12px;
}

.contact-section-head h3 {
  margin: 0 0 4px;
  font-size: 1rem;
  font-weight: 800;
  color: var(--blue-deep);
}

.contact-section-head p {
  margin: 0;
  font-size: 0.78rem;
  color: var(--muted);
  line-height: 1.45;
}

.team-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-bottom: 14px;
}

.team-card {
  display: flex;
  gap: 12px;
  padding: 14px;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 14px;
}

.team-card-partner {
  border-color: #bcd3e6;
  background: linear-gradient(135deg, #fff 0%, #f0f8fc 100%);
}

.team-avatar {
  flex-shrink: 0;
  width: 44px;
  height: 44px;
  border-radius: 12px;
  background: var(--blue);
  color: #fff;
  font-size: 0.85rem;
  font-weight: 800;
  display: flex;
  align-items: center;
  justify-content: center;
  letter-spacing: 0.02em;
}

.team-card-partner .team-avatar {
  background: var(--blue-deep);
}

.team-body {
  flex: 1;
  min-width: 0;
}

.team-badge {
  display: inline-block;
  margin-bottom: 4px;
  padding: 2px 8px;
  border-radius: 999px;
  background: var(--blue-light);
  color: var(--blue-dark);
  font-size: 0.6rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.team-name {
  margin: 0 0 2px;
  font-size: 0.92rem;
  font-weight: 800;
  color: var(--blue-deep);
  line-height: 1.25;
}

.team-role {
  margin: 0 0 10px;
  font-size: 0.72rem;
  color: var(--muted);
  line-height: 1.4;
}

.team-actions {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
}

.btn-team-call,
.btn-team-mail {
  display: inline-block;
  padding: 7px 12px;
  border-radius: 8px;
  font-size: 0.68rem;
  font-weight: 700;
  text-decoration: none;
  border: none;
  font-family: inherit;
}

.btn-team-call {
  background: var(--blue-light);
  color: var(--blue-dark);
  border: 1px solid #bcd3e6;
}

.btn-team-mail {
  background: var(--blue);
  color: #fff;
}

.team-ops-card,
.location-card {
  padding: 14px 16px;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 14px;
  margin-bottom: 12px;
}

.team-ops-card h4,
.location-card h4 {
  margin: 0 0 6px;
  font-size: 0.88rem;
  font-weight: 800;
  color: var(--blue-deep);
}

.team-ops-card p {
  margin: 0 0 10px;
  font-size: 0.75rem;
  color: var(--muted);
  line-height: 1.45;
}

.ops-names {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.ops-name {
  padding: 4px 10px;
  border-radius: 999px;
  background: var(--blue-light);
  color: var(--blue-dark);
  font-size: 0.68rem;
  font-weight: 600;
}

.location-card address {
  font-style: normal;
  font-size: 0.78rem;
  color: var(--text);
  line-height: 1.55;
  margin-bottom: 8px;
}

.location-hours {
  margin: 0 0 10px;
  font-size: 0.72rem;
  color: var(--muted);
}

.btn-location-map {
  display: inline-block;
  padding: 10px 14px;
  background: var(--blue-light);
  color: var(--blue-dark);
  border: 1px solid #bcd3e6;
  border-radius: 10px;
  font-size: 0.75rem;
  font-weight: 700;
  text-decoration: none;
  font-family: inherit;
}

/* Bottom nav */
.bottom-nav {
  flex-shrink: 0;
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  background: rgba(255,255,255,.97);
  backdrop-filter: blur(12px);
  border-top: 1px solid var(--border);
  padding: 6px 4px calc(6px + var(--safe-b));
  z-index: 50;
}

.nav-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2px;
  border: none;
  background: transparent;
  color: var(--muted);
  font-size: 0.58rem;
  font-weight: 700;
  padding: 6px 4px;
  border-radius: 10px;
  font-family: inherit;
  cursor: pointer;
}

.nav-item .nav-ico { font-size: 1.15rem; line-height: 1; }

.nav-item.active {
  color: var(--blue);
  background: var(--blue-light);
}

.toast {
  position: fixed;
  bottom: calc(var(--nav-h) + var(--safe-b) + 12px);
  left: 50%;
  transform: translateX(-50%);
  background: var(--blue-deep);
  color: #fff;
  font-size: 0.78rem;
  font-weight: 600;
  padding: 10px 16px;
  border-radius: 10px;
  z-index: 100;
  max-width: 90%;
  text-align: center;
  box-shadow: 0 8px 24px rgba(0,0,0,.2);
  transition: opacity .2s;
}

.toast.hidden { opacity: 0; pointer-events: none; }

.skeleton {
  height: 72px;
  border-radius: 14px;
  background: linear-gradient(90deg, #e8eef3 25%, #f4f8fb 50%, #e8eef3 75%);
  background-size: 200% 100%;
  animation: shimmer 1.2s infinite;
}

@keyframes shimmer {
  0% { background-position: 200% 0; }
  100% { background-position: -200% 0; }
}

/* Lecteur PDF intégré (FDS) */
body.pdf-open { overflow: hidden; }

.pdf-viewer {
  position: fixed;
  inset: 0;
  z-index: 200;
  display: flex;
  flex-direction: column;
  background: #1a2a36;
}

.pdf-viewer-toolbar {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: calc(8px + var(--safe-t)) 10px 8px;
  background: var(--blue-deep);
  color: #fff;
  flex-shrink: 0;
}

.pdf-toolbar-btn {
  border: none;
  background: rgba(255,255,255,.12);
  color: #fff;
  font-size: 1.1rem;
  font-weight: 700;
  width: 36px;
  height: 36px;
  border-radius: 8px;
  cursor: pointer;
  font-family: inherit;
  line-height: 1;
}

.pdf-page-info,
.pdf-zoom-info {
  font-size: 0.75rem;
  font-weight: 600;
  white-space: nowrap;
}

.pdf-page-info { flex: 1; min-width: 0; }

.pdf-zoom-controls {
  display: flex;
  align-items: center;
  gap: 6px;
}

.pdf-viewer-body {
  flex: 1;
  overflow: auto;
  -webkit-overflow-scrolling: touch;
  padding: 12px;
}

.pdf-status {
  color: #cbd5e1;
  text-align: center;
  margin-top: 2rem;
  font-size: 0.9rem;
}

.pdf-page-wrap {
  display: flex;
  justify-content: center;
  margin: 0 auto 12px;
}

.pdf-page-canvas {
  display: block;
  max-width: 100%;
  height: auto;
  box-shadow: 0 4px 24px rgba(0,0,0,.35);
  border-radius: 4px;
}

.pdf-iframe {
  width: 100%;
  min-height: calc(100vh - 120px);
  height: 100%;
  border: 0;
  background: #fff;
  border-radius: 4px;
}

.pdf-viewer-toolbar .hidden {
  display: none !important;
}

/* Téléphone : inchangé (max-width 520px sur #app).
   Tablette : classes posées par JS (écran physique + largeur viewport, insensible au clavier). */
body.tablet-device {
  background: #dfe8ef;
}

#app.wide-shell {
  max-width: min(100%, 720px);
  box-shadow: 0 0 0 1px var(--border), 0 12px 40px rgba(12, 61, 92, 0.08);
}

#app.wide-shell .tile-grid {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

#app.wide-shell .stats-scroll {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  overflow: visible;
  scroll-snap-type: none;
}

#app.wide-shell .stat-pill {
  min-width: 0;
}

#app.wide-shell .contact-hero + #contact-panel,
#app.wide-shell #contact-panel {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  align-items: start;
}

#app.wide-shell .contact-hero {
  grid-column: 1 / -1;
}

@media (min-width: 960px) {
  #app.wide-shell {
    max-width: min(100%, 1180px);
  }
}

#app.catalogue-split .main {
  display: grid;
  grid-template-columns: minmax(300px, 38%) minmax(0, 1fr);
}

#app.catalogue-split #view-products,
#app.catalogue-split #view-product {
  position: relative;
  inset: auto;
  opacity: 1;
  pointer-events: auto;
  transform: none;
  height: 100%;
  min-height: 0;
  overflow-y: auto;
  overflow-x: hidden;
}

#app.catalogue-split #view-products {
  border-right: 1px solid var(--border);
  padding-right: 10px;
}

#app.catalogue-split #view-product {
  padding-left: 10px;
}

#app.catalogue-split .product-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

#app.catalogue-split .product-card {
  display: grid;
  grid-template-columns: 72px minmax(0, 1fr);
  gap: 10px;
  align-items: center;
  padding: 10px;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 14px;
}

#app.catalogue-split .product-card.is-ph-card {
  background: var(--card);
  border: 1px solid var(--border);
}

#app.catalogue-split .product-card-visual {
  width: 72px;
  height: 72px;
  min-height: 72px;
  aspect-ratio: 1 / 1;
  border-radius: 10px;
}

#app.catalogue-split .product-card-visual.is-genz-ph {
  aspect-ratio: 1 / 1;
}

#app.catalogue-split .product-card.is-ph-card .product-card-visual {
  box-shadow: none;
}

#app.catalogue-split .product-card-body,
#app.catalogue-split .product-card-body-split {
  display: block;
  padding: 0;
}

#app.catalogue-split .product-card-body-grid {
  display: none;
}

#app.catalogue-split .product-card.has-packshot-card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 14px;
}

#app.catalogue-split .product-card.has-packshot-card .product-card-visual {
  border: none;
  box-shadow: none;
}

#app.catalogue-split .v2-ph-name,
#app.catalogue-split .v2-ph-soon,
#app.catalogue-split .v2-ph-foot,
#app.catalogue-split .v2-ph-glass {
  display: none;
}

#app.catalogue-split .v2-ph {
  padding: 6px;
}

#app.catalogue-split .v2-ph-sector {
  font-size: 0.46rem;
  padding: 2px 5px;
}

#app.catalogue-split .product-card-body h3,
#app.catalogue-split .product-card-body-split h3 {
  font-size: 0.82rem;
  margin-bottom: 2px;
}

#app.catalogue-split .product-card-body p,
#app.catalogue-split .product-card-body-split p {
  font-size: 0.68rem;
}

#app.catalogue-split .product-card-visual-badges {
  display: none;
}

.product-card-selected {
  border-color: var(--blue);
  box-shadow: 0 0 0 2px rgba(26, 107, 156, 0.22);
  background: #f7fbfe;
}

/* Paysage téléphone uniquement (pas tablette, même avec clavier ouvert) */
@media (min-width: 521px) and (max-height: 559px) {
  body:not(.tablet-device) {
    background: #111827;
  }
}

/* Devis catalogue (aligné site vitrine) */
.product-card {
  position: relative;
}

.quote-card-btn {
  position: absolute;
  top: 8px;
  right: 8px;
  z-index: 6;
  border: 0;
  border-radius: 999px;
  padding: 6px 11px;
  font-size: 0.68rem;
  font-weight: 700;
  cursor: pointer;
  background: var(--blue);
  color: #fff;
  box-shadow: 0 3px 10px rgba(12, 61, 92, 0.28);
  font-family: inherit;
}

.quote-card-btn.is-in {
  background: #157347;
}

.quote-sheet-box {
  margin-top: 18px;
  padding: 14px;
  border: 1px solid var(--border);
  border-radius: 14px;
  background: var(--bg);
}

.quote-sheet-label {
  margin: 0 0 8px;
  font-size: 0.82rem;
  font-weight: 700;
}

.quote-sheet-colisage {
  margin: 0 0 10px;
  font-size: 0.86rem;
  color: var(--blue-deep);
}

.quote-sheet-box .quote-qty {
  margin-bottom: 10px;
}

body.has-quote-dock .quote-dock {
  bottom: calc(52px + env(safe-area-inset-bottom, 0px));
  z-index: 120;
}

body.has-quote-dock #app .main {
  padding-bottom: 8px;
}

[data-theme="dark"] .quote-card-btn.is-in {
  background: #15803d;
}
