/* ============================================================
   product-2026.css — page layer for the rebuilt product detail
   page (root /product.html), on the NWCA 2026 design system.

   Loads AFTER /shared_components/css/nwca-2026-core.css.
   Chrome (masthead/drawer/footer), page-head, tables, badges,
   alerts, skeletons, empty-state all come from core — this file
   only adds product-page-specific layout.
   ============================================================ */

/* ── Page scaffold ─────────────────────────────────────────── */
.pdp-section { padding: 26px 0; }
.pdp-section + .pdp-section { border-top: 1px solid var(--line); }

.pdp-grid {
    display: grid;
    grid-template-columns: minmax(0, 1.1fr) minmax(0, 0.9fr);
    gap: 36px;
    align-items: start;
}

/* ── Gallery ───────────────────────────────────────────────── */
.pdp-stage {
    margin: 0;
    background: var(--card);
    border: 1px solid var(--line);
    border-radius: var(--radius);
    box-shadow: var(--shadow-card);
    aspect-ratio: 1 / 1;
    display: grid;
    place-items: center;
    overflow: hidden;
}
.pdp-stage img {
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
    display: block;
}
.pdp-thumbs {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-top: 12px;
}
.pdp-thumb {
    width: 76px;
    height: 76px;
    padding: 4px;
    background: var(--card);
    border: 1.5px solid var(--line-strong);
    border-radius: var(--radius-sm);
    cursor: pointer;
    display: grid;
    place-items: center;
    overflow: hidden;
}
.pdp-thumb img { max-width: 100%; max-height: 100%; object-fit: contain; display: block; }
.pdp-thumb:hover { border-color: var(--green-700); }
.pdp-thumb[aria-pressed="true"] {
    border-color: var(--green-700);
    box-shadow: 0 0 0 2px var(--green-100);
}
.pdp-thumb-label {
    display: block;
    font-size: 10.5px;
    font-weight: 700;
    color: var(--ink-soft);
    margin-top: 2px;
}

/* ── Side rail blocks ──────────────────────────────────────── */
.pdp-block { margin-bottom: 26px; }
.pdp-block-title {
    font-size: 15px;
    font-weight: 800;
    margin: 0 0 10px;
    display: flex;
    align-items: baseline;
    gap: 8px;
}
.pdp-block-title .pdp-count {
    font-size: 12.5px;
    font-weight: 600;
    color: var(--ink-soft);
}

/* Color swatches */
.pdp-swatches {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(64px, 1fr));
    gap: 8px;
}
.pdp-swatch {
    background: none;
    border: 1.5px solid transparent;
    border-radius: var(--radius-sm);
    padding: 5px 3px 4px;
    cursor: pointer;
    text-align: center;
    min-height: 44px;
}
.pdp-swatch img {
    width: 42px;
    height: 42px;
    border-radius: 8px;
    border: 1px solid var(--line-strong);
    object-fit: cover;
    display: block;
    margin: 0 auto;
}
.pdp-swatch-name {
    display: block;
    font-size: 10.5px;
    font-weight: 600;
    color: var(--ink-soft);
    margin-top: 4px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}
.pdp-swatch:hover { border-color: var(--line-strong); background: var(--green-50); }
.pdp-swatch[aria-pressed="true"] {
    border-color: var(--green-700);
    background: var(--green-50);
}
.pdp-swatch[aria-pressed="true"] .pdp-swatch-name { color: var(--green-900); font-weight: 800; }
.pdp-selected-color {
    font-size: 13.5px;
    color: var(--ink-soft);
    margin: 10px 0 0;
}
.pdp-selected-color strong { color: var(--ink); }

/* Inventory size grid */
.pdp-inv-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(118px, 1fr));
    gap: 8px;
}
.pdp-inv-cell {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 5px;
    background: var(--card);
    border: 1px solid var(--line);
    border-radius: var(--radius-sm);
    padding: 9px 11px;
}
.pdp-inv-size { font-weight: 800; font-size: 14px; }
.pdp-inv-note { font-size: 12px; color: var(--ink-soft); margin: 10px 0 0; }

/* CTA card (desktop right rail) */
.pdp-cta-card {
    background: var(--card);
    border: 1px solid var(--line);
    border-radius: var(--radius);
    box-shadow: var(--shadow-card);
    padding: 20px;
    position: sticky;
    top: 86px;
}
.pdp-cta-card h2 { font-size: 17px; font-weight: 800; margin: 0 0 4px; }
.pdp-cta-card p { font-size: 13.5px; color: var(--ink-soft); margin: 0 0 14px; }
.pdp-cta-card .btn { width: 100%; justify-content: center; margin-bottom: 9px; }
.pdp-cta-phone {
    text-align: center;
    font-size: 13.5px;
    color: var(--ink-soft);
    margin: 4px 0 0;
}
.pdp-cta-phone a {
    color: var(--green-900);
    font-weight: 800;
    text-decoration: none;
    padding: 6px 4px;
    display: inline-block;
}
.pdp-cta-phone a:hover { text-decoration: underline; }

/* ── Mobile sticky CTA bar ─────────────────────────────────── */
.pdp-mobile-cta {
    display: none;
    position: fixed;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 200; /* under drawer (230+) and modals (260) */
    background: var(--card);
    border-top: 1px solid var(--line-strong);
    box-shadow: 0 -6px 18px -8px rgba(24, 34, 25, 0.25);
    padding: 10px 12px calc(10px + env(safe-area-inset-bottom, 0px));
    gap: 8px;
}
.pdp-mobile-cta .btn { flex: 1 1 0; justify-content: center; padding: 11px 8px; font-size: 13.5px; }
.pdp-mobile-cta[hidden] { display: none !important; } /* [hidden] must beat the ≤960px display:flex */

/* ── Decoration configurator (3 questions → one live price) ── */
.pdp-panel-note {
    font-size: 13.5px;
    color: var(--ink-soft);
    margin: 0 0 14px;
}
.pdp-panel-foot {
    font-size: 12.5px;
    color: var(--ink-soft);
    margin: 12px 0 0;
}

.pdp-cfg {
    background: var(--card);
    border: 1px solid var(--line);
    border-radius: var(--radius);
    box-shadow: var(--shadow-card);
    padding: 20px;
}
.pdp-cfg-q { margin: 0 0 20px; }
.pdp-cfg-q-title {
    font-size: 15px;
    font-weight: 800;
    margin: 0 0 10px;
    display: flex;
    align-items: center;
    gap: 9px;
}
.pdp-cfg-q-num {
    flex: 0 0 auto;
    width: 24px;
    height: 24px;
    border-radius: 50%;
    background: var(--green-700);
    color: #fff;
    font-size: 13px;
    font-weight: 800;
    display: grid;
    place-items: center;
}

/* Quantity / ink steppers — 44px targets */
.pdp-cfg-stepper {
    display: inline-flex;
    align-items: stretch;
    gap: 6px;
}
.pdp-cfg-step {
    width: 44px;
    min-height: 44px;
    font-size: 20px;
    font-weight: 800;
    color: var(--green-900);
    background: var(--card);
    border: 1.5px solid var(--line-strong);
    border-radius: var(--radius-sm);
    cursor: pointer;
}
.pdp-cfg-step:hover { border-color: var(--green-700); background: var(--green-50); }
.pdp-cfg-stepper input {
    width: 92px;
    min-height: 44px;
    padding: 8px 10px;
    font-size: 16px;
    font-weight: 800;
    text-align: center;
    border: 1.5px solid var(--line-strong);
    border-radius: var(--radius-sm);
    background: var(--card);
    color: var(--ink);
}
.pdp-cfg-stepper input:focus,
.pdp-cfg-step:focus-visible {
    outline: none;
    border-color: var(--green-700);
    box-shadow: 0 0 0 3px rgba(47, 125, 59, 0.15);
}
.pdp-cfg-stepper-sm input { width: 64px; }
.pdp-cfg-hint {
    display: inline-block;
    font-size: 12.5px;
    color: var(--ink-soft);
    margin-left: 10px;
}

/* Placement chips */
.pdp-cfg-chiprow {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}
.pdp-cfg-chip {
    min-height: 44px;
    padding: 8px 14px;
    text-align: left;
    background: var(--card);
    border: 1.5px solid var(--line-strong);
    border-radius: var(--radius-sm);
    cursor: pointer;
}
.pdp-cfg-chip:hover { border-color: var(--green-700); background: var(--green-50); }
.pdp-cfg-chip[aria-pressed="true"] {
    border-color: var(--green-700);
    background: var(--green-50);
    box-shadow: 0 0 0 2px var(--green-100);
}
.pdp-cfg-chip-label {
    display: block;
    font-size: 14px;
    font-weight: 800;
    color: var(--ink);
}
.pdp-cfg-chip[aria-pressed="true"] .pdp-cfg-chip-label { color: var(--green-900); }
.pdp-cfg-chip-sub {
    display: block;
    font-size: 11.5px;
    font-weight: 600;
    color: var(--ink-soft);
}

/* SCP ink-colors row */
.pdp-cfg-ink {
    margin-top: 14px;
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 10px;
}
.pdp-cfg-ink label { font-size: 13.5px; font-weight: 700; }
.pdp-cfg-ink .pdp-cfg-hint { margin-left: 0; }

/* SCP safety-stripes row */
.pdp-cfg-stripe {
    margin-top: 10px;
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 10px;
}
.pdp-cfg-stripe-label {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    font-size: 13.5px;
    font-weight: 700;
    cursor: pointer;
}
.pdp-cfg-stripe-label input { width: 16px; height: 16px; cursor: pointer; accent-color: var(--green-700); }
.pdp-cfg-stripe .pdp-cfg-hint { margin-left: 0; }
/* Safety-stripes example image (reuses .pdp-thumb idiom; ~square front+back photo, click to enlarge) */
.pdp-cfg-stripe-example {
    flex: 0 0 auto;
    display: grid;
    place-items: center;
    width: 76px;
    height: 76px;
    padding: 4px;
    background: var(--card);
    border: 1.5px solid var(--line-strong);
    border-radius: var(--radius-sm);
    overflow: hidden;
    cursor: zoom-in;
    text-decoration: none;
}
.pdp-cfg-stripe-example img {
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
    display: block;
    transition: transform 0.18s ease;
}
.pdp-cfg-stripe-example:hover,
.pdp-cfg-stripe-example:focus-visible {
    border-color: var(--green-700);
    box-shadow: 0 0 0 2px var(--green-100);
    outline: none;
}
@media (hover: hover) {
    .pdp-cfg-stripe-example:hover img { transform: scale(1.12); }
}
@media (prefers-reduced-motion: reduce) {
    .pdp-cfg-stripe-example img { transition: none; }
    .pdp-cfg-stripe-example:hover img { transform: none; }
}

/* Method chips — always rendered (states swap, no layout jumps) */
.pdp-cfg-methods {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(190px, 1fr));
    gap: 10px;
}
.pdp-cfg-method {
    min-height: 96px;
    padding: 12px 14px;
    text-align: left;
    background: var(--card);
    border: 1.5px solid var(--line-strong);
    border-radius: var(--radius-sm);
    cursor: pointer;
    display: flex;
    flex-direction: column;
    gap: 3px;
}
.pdp-cfg-method:hover { border-color: var(--green-700); }
.pdp-cfg-method[aria-pressed="true"] {
    border-color: var(--green-700);
    background: var(--green-50);
    box-shadow: 0 0 0 2px var(--green-100);
}
.pdp-cfg-method-name {
    font-size: 12px;
    font-weight: 800;
    letter-spacing: 0.05em;
    text-transform: uppercase;
    color: var(--green-700);
}
.pdp-cfg-method-price {
    font-family: var(--font-display);
    font-size: 22px;
    font-weight: 800;
    color: var(--ink);
    line-height: 1.2;
}
.pdp-cfg-method-per { font-size: 13px; font-weight: 700; color: var(--ink-soft); }
.pdp-cfg-method-note { font-size: 12px; color: var(--ink-soft); }
.pdp-cfg-method.is-unavailable,
.pdp-cfg-method.is-belowmin { background: var(--paper-deep); }
.pdp-cfg-method.is-unavailable .pdp-cfg-method-price,
.pdp-cfg-method.is-belowmin .pdp-cfg-method-price {
    font-family: var(--font-body);
    font-size: 13.5px;
    font-weight: 700;
    color: var(--ink-soft);
}
.pdp-cfg-method.is-error { border-color: var(--bad); }
.pdp-cfg-method.is-error .pdp-cfg-method-price {
    font-family: var(--font-body);
    font-size: 13.5px;
    font-weight: 800;
    color: var(--bad);
}
.pdp-cfg-price-skel {
    display: inline-block;
    width: 84px;
    height: 22px;
    border-radius: 6px;
}

/* Total block */
.pdp-cfg-total {
    margin-top: 18px;
    padding: 16px 18px;
    background: var(--paper-deep);
    border: 1px solid var(--line);
    border-radius: var(--radius-sm);
}
.pdp-cfg-total-big {
    font-family: var(--font-display);
    font-size: 34px;
    font-weight: 800;
    color: var(--green-900);
    margin: 0;
    line-height: 1.1;
}
.pdp-cfg-total-sub {
    font-size: 14.5px;
    font-weight: 700;
    color: var(--ink);
    margin: 4px 0 0;
}
.pdp-cfg-total-tier {
    font-size: 12px;
    font-weight: 800;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    color: var(--green-700);
    margin-left: 6px;
}
.pdp-cfg-total-lines {
    list-style: none;
    margin: 10px 0 0;
    padding: 0;
    font-size: 13px;
    color: var(--ink-soft);
}
.pdp-cfg-total-lines li { padding: 2px 0; }
.pdp-cfg-total-lines .is-ltm { font-weight: 700; color: var(--ink); }
.pdp-cfg-total-lines .is-nudge { font-weight: 700; color: var(--green-900); }
.pdp-cfg-total-foot {
    font-size: 12.5px;
    font-weight: 700;
    color: var(--ink-soft);
    margin: 10px 0 0;
}
.pdp-cfg-total-msg {
    font-size: 14px;
    color: var(--ink);
    margin: 0;
}
.pdp-cfg-total .alert { margin: 0 0 10px; }
.pdp-cfg-total .btn { margin-top: 10px; }

/* Add-to-quote actions under the total block (Phase 2 quote-cart) */
.pdp-cfg-actions {
    margin-top: 14px;
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 10px 14px;
}
.pdp-cfg-actions .btn[disabled] {
    opacity: 0.55;
    cursor: not-allowed;
}
.pdp-cfg-add-reason {
    flex: 1 1 100%;
    font-size: 12.5px;
    font-weight: 700;
    color: var(--ink-soft);
}

/* "See every quantity price" expandable */
.pdp-cfg-expand { margin-top: 14px; }
.pdp-cfg-expand-btn {
    background: none;
    border: none;
    padding: 10px 2px;
    min-height: 44px;
    font-family: var(--font-body);
    font-size: 14px;
    font-weight: 800;
    color: var(--green-900);
    cursor: pointer;
    text-decoration: underline;
    text-underline-offset: 3px;
}
.pdp-cfg-expand-btn:hover { color: var(--green-700); }
.pdp-cfg-matrix { margin-top: 8px; }
.pdp-cfg-matrix .alert { margin: 4px 0; }

/* Notes teaser */
.pdp-cfg-teaser {
    margin: 16px 0 0;
    padding-top: 14px;
    border-top: 1px dashed var(--line-strong);
    font-size: 13px;
    color: var(--ink-soft);
}

/* ── Product details bullets ───────────────────────────────── */
.pdp-details-list {
    margin: 0;
    padding-left: 20px;
    font-size: 14px;
    line-height: 1.75;
    color: var(--ink-soft);
    columns: 2;
    column-gap: 40px;
}
.pdp-details-list li { break-inside: avoid; }

/* ── Related products ──────────────────────────────────────── */
.pdp-related-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 16px;
}
.pdp-related-card {
    background: var(--card);
    border: 1px solid var(--line);
    border-radius: var(--radius);
    box-shadow: var(--shadow-card);
    overflow: hidden;
    text-decoration: none;
    color: var(--ink);
    display: flex;
    flex-direction: column;
}
.pdp-related-card:hover { border-color: var(--green-700); }
.pdp-related-photo {
    background: var(--paper-deep);
    aspect-ratio: 1 / 1;
    display: grid;
    place-items: center;
    overflow: hidden;
}
.pdp-related-photo img { max-width: 88%; max-height: 88%; object-fit: contain; }
.pdp-related-photo.is-pending {
    /* SanMar hasn't photographed the style yet — styled tile instead of
       their blue "image not yet available" badge */
    font-size: 12.5px; font-weight: 600; color: var(--ink-soft);
    border: 1.4px dashed var(--line-strong); border-radius: var(--radius-sm);
    margin: 10px;
}
.pdp-related-body { padding: 12px 14px 14px; }
.pdp-related-style {
    font-size: 11.5px;
    font-weight: 800;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    color: var(--green-700);
    display: block;
}
.pdp-related-name {
    font-size: 14px;
    font-weight: 700;
    margin: 3px 0 0;
    line-height: 1.35;
}
.pdp-related-card:hover .pdp-related-name { color: var(--green-900); }

/* ── Loading skeleton layout ───────────────────────────────── */
.pdp-skeleton-grid {
    display: grid;
    grid-template-columns: minmax(0, 1.1fr) minmax(0, 0.9fr);
    gap: 36px;
}
.pdp-skeleton-grid .skeleton-block { min-height: 420px; }

/* ── Responsive ────────────────────────────────────────────── */
@media (max-width: 960px) {
    .pdp-grid,
    .pdp-skeleton-grid { grid-template-columns: 1fr; gap: 24px; }
    .pdp-cta-card { position: static; }
    .pdp-cta-card .btn-cta { display: none; } /* mobile bar covers the quote CTA */
    .pdp-mobile-cta { display: flex; }
    body.pdp-has-mobile-cta { padding-bottom: 76px; }
    .pdp-skeleton-grid .skeleton-block { min-height: 280px; }
    .pdp-details-list { columns: 1; }
}

@media (max-width: 560px) {
    .pdp-thumb { width: 64px; height: 64px; }
    .pdp-cfg { padding: 14px 12px; }
    .pdp-cfg-methods { grid-template-columns: 1fr 1fr; }
    .pdp-cfg-method { min-height: 88px; padding: 10px 11px; }
    .pdp-cfg-total-big { font-size: 28px; }
    .pdp-cfg-hint { display: block; margin: 8px 0 0; }
}

@media (max-width: 400px) {
    .pdp-cfg-methods { grid-template-columns: 1fr; }
}
