/* PRODIMED Produits — page liste + page détail. Palette : bleu marine PRODIMED. */

:root {
    --pdp-navy: #0b1b3f;
    --pdp-blue: #17357f;
    --pdp-line: #e3e8f2;
    --pdp-soft: #f4f7fc;
    --pdp-text: #4b5565;
    --pdp-ease: cubic-bezier(.22, .61, .36, 1);
}

@keyframes pdp-rise { from { opacity: 0; transform: translateY(28px); } to { opacity: 1; transform: translateY(0); } }
@keyframes pdp-shine { from { transform: translateX(-130%) skewX(-18deg); } to { transform: translateX(260%) skewX(-18deg); } }

.pdp-wrap { max-width: 1240px; margin: 0 auto; padding: 0 24px; }

/* fil d'Ariane */
.pdp-breadcrumb { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; margin: 0 0 26px; font-size: 14px; color: #6b7585; }
.pdp-breadcrumb a { color: var(--pdp-blue); text-decoration: none; font-weight: 600; }
.pdp-breadcrumb a:hover { text-decoration: underline; }
.pdp-breadcrumb strong { color: var(--pdp-navy); }
.pdp-breadcrumb span { opacity: .5; }
.pdp-breadcrumb-light { justify-content: center; color: rgba(255,255,255,.7); }
.pdp-breadcrumb-light a { color: #fff; }
.pdp-breadcrumb-light strong { color: #fff; }

/* ---------- LISTE ---------- */
.pdp-shop { padding: 56px 0 90px; background: #fff; }
.pdp-layout { display: grid; grid-template-columns: 290px 1fr; gap: 36px; align-items: start; }

.pdp-side { position: sticky; top: 100px; display: grid; gap: 18px; }
.pdp-box { background: #fff; border: 1px solid var(--pdp-line); border-radius: 10px; padding: 18px; box-shadow: 0 2px 10px rgba(11,27,63,.04); }
.pdp-box h3 { margin: 0 0 12px; font-size: 14px; letter-spacing: .1em; text-transform: uppercase; color: var(--pdp-navy); }

.pdp-search input {
    width: 100%; box-sizing: border-box; padding: 12px 14px 12px 40px;
    border: 1px solid var(--pdp-line); border-radius: 8px; font: inherit; font-size: 15px; color: var(--pdp-navy);
    background: #fff url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='18' height='18' fill='none' stroke='%2317357f' stroke-width='2' stroke-linecap='round'%3E%3Ccircle cx='8' cy='8' r='6'/%3E%3Cpath d='m13 13 4 4'/%3E%3C/svg%3E") 13px 50% no-repeat;
    transition: border-color .25s, box-shadow .25s;
}
.pdp-search input:focus { outline: none; border-color: var(--pdp-blue); box-shadow: 0 0 0 4px rgba(23,53,127,.12); }

.pdp-filter { list-style: none; margin: 0; padding: 0; display: grid; gap: 4px; }
.pdp-filter button {
    display: flex; justify-content: space-between; align-items: center; width: 100%;
    padding: 10px 12px; border: 0; border-radius: 7px; background: transparent; cursor: pointer;
    font: inherit; font-size: 15px; color: var(--pdp-text); text-align: left;
    transition: background-color .25s, color .25s, padding-left .25s;
}
.pdp-filter button em { font-style: normal; font-size: 12px; font-weight: 700; min-width: 24px; text-align: center; padding: 2px 7px; border-radius: 99px; background: var(--pdp-soft); color: var(--pdp-blue); transition: inherit; }
.pdp-filter button:hover { background: var(--pdp-soft); color: var(--pdp-navy); padding-left: 16px; }
.pdp-filter button.is-active { background: var(--pdp-navy); color: #fff; padding-left: 16px; }
.pdp-filter button.is-active em { background: rgba(255,255,255,.18); color: #fff; }

.pdp-help { background: linear-gradient(135deg, var(--pdp-navy), var(--pdp-blue)); border: 0; color: #fff; }
.pdp-help h3 { color: #fff; }
.pdp-help p { margin: 0 0 14px; font-size: 14px; color: rgba(255,255,255,.82); line-height: 1.5; }
.pdp-help .btn { display: block; text-align: center; background: #fff; color: var(--pdp-navy); border-color: #fff; }

.pdp-count { margin: 0 0 18px; color: var(--pdp-text); font-size: 15px; }
.pdp-count strong { color: var(--pdp-navy); font-size: 18px; }

.pdp-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 22px; }
.pdp-grid-3 { grid-template-columns: repeat(3, 1fr); }

.pdp-card {
    position: relative; display: flex; flex-direction: column; overflow: hidden;
    background: #fff; border: 1px solid var(--pdp-line); border-radius: 10px;
    text-decoration: none; color: inherit;
    transition: transform .4s var(--pdp-ease), box-shadow .4s var(--pdp-ease), border-color .3s;
}
.pdp-card::before { /* trait de couleur qui se dessine en haut */
    content: ""; position: absolute; left: 0; top: 0; height: 3px; width: 100%; z-index: 2;
    background: linear-gradient(90deg, var(--pdp-blue), #2DD4BF); transform: scaleX(0); transform-origin: left; transition: transform .5s var(--pdp-ease);
}
.pdp-card:hover { transform: translateY(-8px); box-shadow: 0 22px 44px rgba(11,27,63,.14); border-color: rgba(23,53,127,.35); }
.pdp-card:hover::before { transform: scaleX(1); }

.pdp-card-img {
    position: relative; display: flex; align-items: center; justify-content: center; overflow: hidden;
    height: 210px; padding: 18px; box-sizing: border-box;
    background: radial-gradient(circle at 50% 40%, #fff 0%, var(--pdp-soft) 100%);
}
.pdp-card-img img { max-width: 100%; max-height: 100%; width: auto; height: auto; object-fit: contain; transition: transform .6s var(--pdp-ease); }
.pdp-card:hover .pdp-card-img img { transform: scale(1.09); }
.pdp-card-img::after { /* reflet au survol */
    content: ""; position: absolute; top: 0; bottom: 0; left: 0; width: 35%;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,.7), transparent); transform: translateX(-130%) skewX(-18deg); pointer-events: none;
}
.pdp-card:hover .pdp-card-img::after { animation: pdp-shine .9s ease; }
.pdp-noimg { display: flex; align-items: center; justify-content: center; width: 96px; height: 96px; border-radius: 50%; background: var(--pdp-navy); color: #fff; font-size: 30px; font-weight: 700; letter-spacing: .04em; }

.pdp-card-body { display: flex; flex-direction: column; gap: 8px; flex: 1; padding: 18px 20px 20px; }
.pdp-tags { display: flex; flex-wrap: wrap; gap: 6px; }
.pdp-tag { display: inline-block; padding: 3px 10px; border-radius: 99px; background: rgba(23,53,127,.08); color: var(--pdp-blue); font-size: 11px; font-weight: 700; letter-spacing: .07em; text-transform: uppercase; }
.pdp-card-title { font-size: 19px; font-weight: 700; line-height: 1.25; color: var(--pdp-navy); }
.pdp-meta { font-size: 13px; font-weight: 600; color: #7a8494; }
.pdp-card-text { font-size: 14px; line-height: 1.55; color: var(--pdp-text); }
.pdp-more { margin-top: auto; padding-top: 6px; font-size: 14px; font-weight: 700; color: var(--pdp-blue); }
.pdp-more i { display: inline-block; font-style: normal; transition: transform .3s var(--pdp-ease); }
.pdp-card:hover .pdp-more i { transform: translateX(6px); }

.pdp-empty { padding: 40px; text-align: center; color: var(--pdp-text); background: var(--pdp-soft); border-radius: 10px; }

/* apparition en cascade (si JS) */
html.pdp-js .pdp-card { opacity: 0; }
html.pdp-js .pdp-card.pdp-in { animation: pdp-rise .6s var(--pdp-ease) both; animation-delay: var(--d, 0ms); }

/* ---------- DÉTAIL ---------- */
.pdp-hero { padding-bottom: 54px; }
.pdp-detail { padding: 60px 0 40px; }
.pdp-detail-grid { display: grid; grid-template-columns: 5fr 6fr; gap: 54px; align-items: start; }
.pdp-gallery { position: sticky; top: 100px; }
.pdp-gallery-frame {
    display: flex; align-items: center; justify-content: center; min-height: 420px; padding: 36px; overflow: hidden;
    background: radial-gradient(circle at 50% 35%, #fff, var(--pdp-soft)); border: 1px solid var(--pdp-line); border-radius: 14px;
    box-shadow: 0 14px 40px rgba(11,27,63,.08);
}
.pdp-gallery-frame img { max-width: 100%; height: auto; max-height: 420px; object-fit: contain; transition: transform .7s var(--pdp-ease); }
.pdp-gallery-frame:hover img { transform: scale(1.07) rotate(-1deg); }
.pdp-gallery-frame .pdp-noimg { width: 150px; height: 150px; font-size: 48px; }

.pdp-info { animation: pdp-rise .7s var(--pdp-ease) both; }
.pdp-facts { display: flex; flex-wrap: wrap; gap: 14px; margin: 16px 0 22px; }
.pdp-facts div { padding: 12px 18px; border: 1px solid var(--pdp-line); border-left: 3px solid var(--pdp-blue); border-radius: 6px; background: var(--pdp-soft); }
.pdp-facts dt { margin: 0; font-size: 11px; letter-spacing: .1em; text-transform: uppercase; color: #7a8494; }
.pdp-facts dd { margin: 2px 0 0; font-size: 16px; font-weight: 700; color: var(--pdp-navy); }
.pdp-facts a { color: var(--pdp-blue); text-decoration: none; }
.pdp-facts a:hover { text-decoration: underline; }
.pdp-content { font-size: 16px; line-height: 1.75; color: var(--pdp-text); }
.pdp-content p { margin: 0 0 14px; }
.pdp-actions { display: flex; flex-wrap: wrap; gap: 12px; margin: 26px 0 8px; }

.pdp-docs { margin-top: 30px; padding-top: 24px; border-top: 1px solid var(--pdp-line); }
.pdp-docs h3 { margin: 0 0 14px; font-size: 14px; letter-spacing: .1em; text-transform: uppercase; color: var(--pdp-navy); }
.pdp-doc {
    display: flex; align-items: center; gap: 14px; margin-bottom: 10px; padding: 14px 16px;
    border: 1px solid var(--pdp-line); border-radius: 8px; text-decoration: none; color: var(--pdp-navy); font-weight: 700;
    transition: transform .3s var(--pdp-ease), box-shadow .3s, border-color .3s;
}
.pdp-doc small { display: block; margin-top: 2px; font-weight: 500; font-size: 13px; color: #7a8494; }
.pdp-doc:hover { transform: translateX(6px); border-color: var(--pdp-blue); box-shadow: 0 8px 22px rgba(11,27,63,.1); }
.pdp-doc-ico { display: inline-flex; align-items: center; justify-content: center; width: 44px; height: 44px; border-radius: 8px; background: #c0392b; color: #fff; font-size: 12px; font-weight: 800; letter-spacing: .05em; }

.pdp-related { padding: 40px 0 70px; background: var(--pdp-soft); }
.pdp-related h2 { margin: 0 0 26px; text-align: center; color: var(--pdp-navy); }

/* ---------- RESPONSIVE ---------- */
@media (max-width: 1080px) {
    .pdp-grid, .pdp-grid-3 { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 900px) {
    .pdp-layout { grid-template-columns: 1fr; }
    .pdp-side { position: static; }
    .pdp-detail-grid { grid-template-columns: 1fr; gap: 30px; }
    .pdp-gallery { position: static; }
}
@media (max-width: 600px) {
    .pdp-grid, .pdp-grid-3 { grid-template-columns: 1fr; }
    .pdp-shop { padding: 36px 0 60px; }
    .pdp-gallery-frame { min-height: 280px; }
}
@media (prefers-reduced-motion: reduce) {
    html.pdp-js .pdp-card { opacity: 1; animation: none !important; }
    .pdp-card, .pdp-card *, .pdp-info, .pdp-doc { transition: none !important; animation: none !important; }
}

.pdp-search .screen-reader-text { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.pdp-actions .pdp-back { background: transparent; color: var(--pdp-navy); border: 1.5px solid var(--pdp-navy); }
.pdp-actions .pdp-back:hover { background: var(--pdp-navy); color: #fff; }

/* ---------- TABLE DES RÉFÉRENCES ---------- */
.pdp-refs { padding: 70px 0 90px; background: var(--pdp-soft); }
.pdp-refs-label { display: block; text-align: center; font-size: 12px; font-weight: 700; letter-spacing: .16em; text-transform: uppercase; color: var(--pdp-blue); }
.pdp-refs h2 { margin: 8px 0 10px; text-align: center; color: var(--pdp-navy); }
.pdp-refs-intro { max-width: 640px; margin: 0 auto 30px; text-align: center; color: var(--pdp-text); }
.pdp-refs-intro a { color: var(--pdp-blue); font-weight: 700; }
.pdp-refs-tools { display: grid; gap: 14px; margin-bottom: 22px; }
.pdp-refs-search input { background-color: #fff; }
.pdp-refs-brands { display: flex; flex-wrap: wrap; gap: 8px; }
.pdp-refs-brands button { display: inline-flex; align-items: center; gap: 8px; padding: 8px 16px; border: 1px solid var(--pdp-line); border-radius: 99px; background: #fff; color: var(--pdp-navy); font: inherit; font-size: 14px; font-weight: 600; cursor: pointer; transition: background-color .25s, color .25s, transform .25s, border-color .25s; }
.pdp-refs-brands button em { font-style: normal; font-size: 12px; padding: 1px 8px; border-radius: 99px; background: var(--pdp-soft); color: var(--pdp-blue); }
.pdp-refs-brands button:hover { transform: translateY(-2px); border-color: var(--pdp-blue); }
.pdp-refs-brands button.is-active { background: var(--pdp-navy); color: #fff; border-color: var(--pdp-navy); }
.pdp-refs-brands button.is-active em { background: rgba(255,255,255,.2); color: #fff; }

.pdp-table-wrap { overflow-x: auto; background: #fff; border: 1px solid var(--pdp-line); border-radius: 10px; box-shadow: 0 6px 22px rgba(11,27,63,.06); }
.pdp-table { width: 100%; border-collapse: collapse; font-size: 14px; }
.pdp-table th { position: sticky; top: 0; padding: 14px 16px; text-align: left; background: var(--pdp-navy); color: #fff; font-size: 12px; letter-spacing: .1em; text-transform: uppercase; white-space: nowrap; }
.pdp-table td { padding: 12px 16px; border-top: 1px solid var(--pdp-line); color: var(--pdp-text); vertical-align: top; }
.pdp-table tbody tr { transition: background-color .2s; }
.pdp-table tbody tr:hover { background: #eef3fc; }
.pdp-table td:first-child { font-family: ui-monospace, Menlo, Consolas, monospace; font-size: 13px; color: var(--pdp-navy); white-space: nowrap; }
.pdp-table td:nth-child(2) { color: var(--pdp-navy); font-weight: 600; }
.pdp-brandpill { display: inline-block; padding: 2px 10px; border-radius: 99px; background: rgba(23,53,127,.08); color: var(--pdp-blue); font-size: 12px; font-weight: 700; }
.pdp-stock { display: inline-flex; align-items: center; gap: 7px; font-weight: 600; white-space: nowrap; }
.pdp-stock::before { content: ""; width: 9px; height: 9px; border-radius: 50%; background: #9aa4b5; }
.pdp-stock.is-in { color: #15803d; }
.pdp-stock.is-in::before { background: #22c55e; box-shadow: 0 0 0 4px rgba(34,197,94,.18); }
.pdp-refs-empty { padding: 30px; text-align: center; color: var(--pdp-text); }
.pdp-pager { display: flex; flex-wrap: wrap; justify-content: center; gap: 6px; margin-top: 22px; }
.pdp-pager button { min-width: 38px; height: 38px; padding: 0 12px; border: 1px solid var(--pdp-line); border-radius: 8px; background: #fff; color: var(--pdp-navy); font: inherit; font-weight: 600; cursor: pointer; transition: background-color .2s, color .2s, transform .2s; }
.pdp-pager button:hover:not(:disabled) { transform: translateY(-2px); border-color: var(--pdp-blue); }
.pdp-pager button.is-active { background: var(--pdp-navy); color: #fff; border-color: var(--pdp-navy); }
.pdp-pager button:disabled { opacity: .4; cursor: default; }
.pdp-pager .gap { align-self: center; color: #7a8494; }
@media (max-width: 700px) {
    .pdp-table th:nth-child(4), .pdp-table td:nth-child(4) { display: none; }
    .pdp-table td, .pdp-table th { padding: 10px 10px; }
}
