/* Scoped under .carbid-app -- see the comment at the top of style.css. */

.carbid-app .detail-wrap { max-width: 1400px; margin: 0 auto; padding: 20px 20px 60px; }

.carbid-app .crumb { font-size: 13px; margin-bottom: 14px; }
.carbid-app .crumb a { color: var(--accent); text-decoration: none; font-weight: 700; }
.carbid-app .crumb a:hover { text-decoration: underline; }

.carbid-app .detail-hero { margin-bottom: 18px; }
/* color explicit, not inherited -- Woodmart's base.min.css has its own
   bare `h1 { color: var(--wd-title-color); }` rule, which (being a rule
   that targets the element directly, however low its specificity) always
   wins over an inherited color. On this page's WP context that variable
   resolves to a color meant for a dark hero banner, rendering the title
   invisible against our light background -- confirmed live 2026-08-24. */
.carbid-app .detail-title { font-size: 24px; font-weight: 800; margin: 0; line-height: 1.2; color: var(--text); }
.carbid-app .detail-hero-meta { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; font-size: 12.5px; color: var(--text-muted); }

/* Title + "Sekti" watchlist toggle (account/watch.php / unwatch.php) share
   one row, per Karolis -- the toggle belongs right next to the car's own
   name, not buried further down the page. */
.carbid-app .detail-title-row { display: flex; align-items: flex-start; justify-content: space-between; gap: 14px; margin-bottom: 9px; }
.carbid-app .watch-toggle-form { flex: none; margin: 0; }
.carbid-app .watch-toggle-btn {
    display: flex; align-items: center; gap: 6px; padding: 8px 14px; border-radius: 7px;
    border: 1px solid var(--border); background: var(--surface); color: var(--text-muted);
    font-size: 12.5px; font-weight: 700; font-family: inherit; cursor: pointer; white-space: nowrap;
}
.carbid-app .watch-toggle-btn:hover { border-color: var(--accent); color: var(--accent-deep); }
.carbid-app .watch-toggle-btn.is-watched { background: var(--accent-soft); border-color: var(--accent); color: var(--accent-deep); }

@media (max-width: 640px) {
    .carbid-app .detail-title-row { flex-direction: column; align-items: stretch; }
    .carbid-app .watch-toggle-btn { width: 100%; justify-content: center; }
}
.carbid-app .src-chip { display: inline-block; font-size: 10.5px; font-weight: 700; padding: 3px 8px; border-radius: 4px; letter-spacing: 0.02em; text-decoration: none; border: 1.5px solid transparent; }
.carbid-app .src-chip.src-copart { background: var(--navy); border-color: #fff; color: #fff; }
.carbid-app .src-chip.src-iaai { background: #fff; border-color: var(--iaai-red); color: var(--iaai-red); }
.carbid-app .chip-pill { font-size: 11px; font-weight: 800; padding: 3px 9px; border-radius: 20px; }
.carbid-app .chip-pill.ok { background: var(--accent-soft); color: var(--accent-deep); }
.carbid-app .chip-pill.warn { background: var(--warn-bg); color: var(--warn-fg); }
.carbid-app .chip-pill.danger { background: var(--danger-soft); color: var(--danger); }

.carbid-app .detail-grid { display: grid; grid-template-columns: minmax(0, 1.15fr) minmax(0, 1fr) 320px; gap: 18px; align-items: start; margin-bottom: 20px; }
@media (max-width: 1180px) { .carbid-app .detail-grid { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); } .carbid-app .detail-rail { grid-column: 1 / -1; position: static !important; } }
@media (max-width: 700px) { .carbid-app .detail-grid { grid-template-columns: 1fr; } .carbid-app .detail-gallery-col { position: static !important; } }

.carbid-app .card-surface { background: var(--surface); border: 1px solid var(--border-soft); border-radius: 10px; box-shadow: var(--shadow); }
/* top: calc(...--wd-header-h + 92px) -- 92px was calibrated against
   header.site sticking at the very top of the viewport (top:0); now that
   header.site itself sticks at var(--wd-header-h) instead (see style.css's
   matching comment on why), this needs to clear that SAME extra offset too,
   or it ends up positioned too high, overlapping both sticky headers above
   it. */
.carbid-app .detail-gallery-col { display: flex; flex-direction: column; gap: 16px; min-width: 0; position: sticky; top: calc(var(--wd-header-h, 0px) + 92px); }
.carbid-app .detail-main { display: flex; flex-direction: column; gap: 16px; min-width: 0; }
.carbid-app .section { padding: 18px 20px; }
.carbid-app .section-title { font-size: 12px; font-weight: 800; text-transform: uppercase; letter-spacing: 0.04em; color: var(--text-faint); margin: 0 0 14px; }

.carbid-app .d-gallery-main { position: relative; background: var(--surface); border-radius: 10px 10px 0 0; overflow: hidden; display: flex; align-items: center; justify-content: center; }
.carbid-app .d-gallery-main img { display: block; width: 100%; height: auto; }
.carbid-app .d-gallery-main img.is-zoomable { cursor: zoom-in; }

/* Small "Didinti" (Enlarge) hint pinned to the main photo's corner -- makes
   the click-to-zoom affordance discoverable without a permanent overlay
   covering the photo itself. */
.carbid-app .zoom-hint {
    position: absolute; right: 12px; bottom: 12px; z-index: 2; display: flex; align-items: center; gap: 5px;
    padding: 5px 10px; border-radius: 999px; background: rgba(0,0,0,0.55); color: #fff;
    font-size: 11px; font-weight: 700; pointer-events: none;
}

/* Full-screen photo lightbox (detail.php's own inline script). Hidden by
   default; .open makes it a fixed, full-viewport overlay above everything
   else on the page (including the Woodmart theme chrome this page renders
   inside, see docs/DECISIONS.md 2026-08-20 theme integration). */
.carbid-app .lightbox {
    display: none; position: fixed; inset: 0; z-index: 9999; background: rgba(10,14,15,0.94);
    align-items: center; justify-content: center;
}
.carbid-app .lightbox.open { display: flex; }
.carbid-app .lightbox-stage { max-width: 92vw; max-height: 88vh; overflow: hidden; display: flex; align-items: center; justify-content: center; }
.carbid-app .lightbox-stage img {
    max-width: 92vw; max-height: 88vh; display: block; cursor: zoom-in; transition: transform 0.12s ease-out;
    user-select: none;
}
.carbid-app .lightbox-stage img.zoomed { cursor: zoom-out; }
.carbid-app .lightbox-close {
    position: fixed; top: 18px; right: 22px; z-index: 3; width: 40px; height: 40px; border: none; border-radius: 50%;
    background: rgba(255,255,255,0.12); color: #fff; font-size: 24px; line-height: 1; cursor: pointer;
    display: flex; align-items: center; justify-content: center;
}
.carbid-app .lightbox-close:hover { background: var(--accent); }
.carbid-app .lightbox-nav {
    position: fixed; top: 50%; transform: translateY(-50%); z-index: 3; width: 46px; height: 46px; border: none;
    border-radius: 50%; background: rgba(255,255,255,0.12); color: #fff; font-size: 26px; line-height: 1; cursor: pointer;
    display: flex; align-items: center; justify-content: center;
}
.carbid-app .lightbox-nav:hover { background: var(--accent); }
.carbid-app .lightbox-nav-prev { left: 18px; }
.carbid-app .lightbox-nav-next { right: 18px; }
.carbid-app .lightbox-counter {
    position: fixed; bottom: 20px; left: 50%; transform: translateX(-50%); z-index: 3;
    padding: 5px 14px; border-radius: 999px; background: rgba(255,255,255,0.12); color: #fff;
    font-size: 12.5px; font-weight: 700; letter-spacing: 0.02em;
}

@media (max-width: 640px) {
    .carbid-app .lightbox-nav { width: 38px; height: 38px; font-size: 22px; }
    .carbid-app .lightbox-nav-prev { left: 8px; }
    .carbid-app .lightbox-nav-next { right: 8px; }
    .carbid-app .lightbox-close { top: 10px; right: 10px; }
    .carbid-app .zoom-hint { right: 8px; bottom: 8px; font-size: 10px; padding: 4px 8px; }
}

.carbid-app .gallery-nav { position: absolute; top: 50%; transform: translateY(-50%); z-index: 3; width: 38px; height: 38px; border: none; border-radius: 50%; background: rgba(0,0,0,0.45); color: #fff; font-size: 22px; line-height: 1; cursor: pointer; display: flex; align-items: center; justify-content: center; }
.carbid-app .gallery-nav:hover { background: var(--accent); }
.carbid-app .gallery-nav-prev { left: 12px; }
.carbid-app .gallery-nav-next { right: 12px; }

.carbid-app .d-thumbs { display: flex; flex-wrap: wrap; gap: 8px; padding: 10px; }
.carbid-app .d-thumb { flex: none; width: 78px; height: 56px; object-fit: cover; border-radius: 6px; cursor: pointer; border: 2px solid transparent; opacity: 0.7; }
.carbid-app .d-thumb:hover { opacity: 1; }
.carbid-app .d-thumb.active { border-color: var(--accent); opacity: 1; }

.carbid-app .meta-grid-lg { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px 22px; }
.carbid-app .meta-grid-lg.cols-2 { grid-template-columns: repeat(2, 1fr); }
@media (max-width: 700px) { .carbid-app .meta-grid-lg { grid-template-columns: repeat(2, 1fr); } }

.carbid-app .description { font-size: 14px; line-height: 1.6; color: var(--text-muted); margin: 0; }

/* Same var(--wd-header-h) reasoning as .detail-gallery-col above. */
.carbid-app .detail-rail { display: flex; flex-direction: column; gap: 16px; position: sticky; top: calc(var(--wd-header-h, 0px) + 92px); }
.carbid-app .bid-card, .carbid-app .contact-card, .carbid-app .calc-card { padding: 18px 20px; }
.carbid-app .countdown-lg { display: flex; align-items: center; gap: 6px; margin-bottom: 10px; font-size: 16px; font-weight: 800; color: var(--accent-deep); }
.carbid-app .countdown-lg-icon { flex: 0 0 auto; }
.carbid-app .countdown-lg.is-urgent { color: var(--danger); }
.carbid-app .countdown-ended-lg { display: inline-block; margin-bottom: 14px; font-size: 13px; }
.carbid-app .price-lg { font-size: 26px; display: block; }

/* Buy Now's own cell in the bid rail -- visually separated from the
   auction price/bid-calculator below it since a Buy Now lot is still a
   live auction underneath and both CTAs render side by side (per
   Karolis, 2026-08-24). */
.carbid-app .buy-now-cell { border: 1px solid var(--border); border-radius: 9px; background: var(--bg); padding: 14px; margin-bottom: 14px; }
.carbid-app .buy-now-cell .price-label-final .pl-line2 { font-size: 9.5px; }

/* Deposit gate (per Karolis, 2026-08-24): shown in place of the Jamam!/
   Pirkti dabar button when the customer's inexauto.com Account Funds
   balance doesn't cover 10% of the final price yet. */
.carbid-app .deposit-gate { margin-top: 12px; }
.carbid-app .deposit-gate-note { margin: 6px 0 0; font-size: 11.5px; color: var(--text-muted); text-align: center; line-height: 1.4; }
.carbid-app .deposit-gate-note a { color: var(--accent); font-weight: 700; text-decoration: none; }
.carbid-app .deposit-gate-note a:hover { text-decoration: underline; }
.carbid-app .bid-hint { font-size: 11.5px; color: var(--text-faint); text-align: center; margin: 10px 0 0; }

.carbid-app .bid-calc { display: flex; flex-direction: column; gap: 10px; }
.carbid-app .bid-calc-field { display: block; }
.carbid-app .bid-calc-field .price-label { margin-bottom: 4px; }
.carbid-app .bid-calc-input-wrap { display: flex; align-items: center; gap: 6px; background: var(--bg); border: 1px solid var(--border); border-radius: 7px; padding: 0 10px; height: 38px; }
.carbid-app .bid-calc-suffix { flex: none; font-weight: 700; color: var(--text-faint); font-size: 13px; }
.carbid-app .bid-calc-input { flex: 1; min-width: 0; border: none; background: transparent; outline: none; font-size: 15px; font-weight: 700; color: var(--text); height: 100%; font-family: inherit; }
.carbid-app .bid-calc-input::-webkit-outer-spin-button, .carbid-app .bid-calc-input::-webkit-inner-spin-button { margin: 0; }

.carbid-app .extra-services { display: flex; flex-direction: column; gap: 8px; margin-top: 10px; }
.carbid-app .toggle-row { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 9px 12px; border: 1px solid var(--border); border-radius: 9px; background: var(--bg); cursor: pointer; transition: border-color 0.15s, background 0.15s; }
.carbid-app .toggle-row.is-on { border-color: var(--accent); background: var(--accent-soft); }
.carbid-app .toggle-row-label { display: flex; align-items: baseline; gap: 7px; font-size: 12.5px; line-height: 1.3; }
.carbid-app .toggle-row-price { font-weight: 800; color: var(--text); white-space: nowrap; }
.carbid-app .toggle-row-text { color: var(--text-muted); }

.carbid-app .toggle-switch { position: relative; flex: none; display: inline-block; }
.carbid-app .toggle-switch input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.carbid-app .toggle-track { display: block; width: 38px; height: 22px; background: var(--border); border-radius: 999px; position: relative; transition: background 0.15s; }
.carbid-app .toggle-thumb { position: absolute; top: 2px; left: 2px; width: 18px; height: 18px; border-radius: 50%; background: #fff; box-shadow: 0 1px 2px rgba(0,0,0,0.25); transition: transform 0.15s; }
.carbid-app .toggle-switch.is-on .toggle-track { background: var(--accent); }
.carbid-app .toggle-switch.is-on .toggle-thumb { transform: translateX(16px); }
.carbid-app .toggle-switch input:focus-visible + .toggle-track { outline: 2px solid var(--accent); outline-offset: 2px; }

.carbid-app .contact-card p { margin: 0 0 10px; font-size: 13px; color: var(--text-muted); }
.carbid-app .ghost-btn { display: block; text-align: center; border: 1.5px solid var(--accent); color: var(--accent); font-weight: 800; font-size: 12.5px; padding: 9px; border-radius: 7px; text-decoration: none; }
.carbid-app .ghost-btn:hover { background: var(--accent); color: #fff; }

.carbid-app .calc-total { font-size: 24px; font-weight: 800; color: var(--accent); margin-bottom: 12px; }
.carbid-app .calc-grid { display: grid; grid-template-columns: 1fr auto; gap: 0; margin: 0; font-size: 12px; }
.carbid-app .calc-grid dt { padding: 6px 0; color: var(--text-muted); border-bottom: 1px solid var(--border-soft); }
.carbid-app .calc-grid dd { padding: 6px 0; margin: 0; font-weight: 700; text-align: right; border-bottom: 1px solid var(--border-soft); }
.carbid-app .calc-grid dt.total, .carbid-app .calc-grid dd.total { border-top: 2px solid var(--border); border-bottom: none; font-size: 14px; font-weight: 800; color: var(--accent); padding-top: 10px; }
.carbid-app .calc-note { font-size: 10.5px; color: var(--text-faint); margin: 10px 0 0; }

.carbid-app .related-wrap { margin-top: 6px; }
