.rb-ad-detail {
    padding-top: 28px;
    padding-bottom: 64px;
}

.rb-ad-detail__breadcrumb {
    display: flex;
    gap: 8px;
    align-items: center;
    margin-bottom: 20px;
    font-size: 13px;
    color: var(--rb-text-muted);
}

.rb-ad-detail__breadcrumb a {
    color: inherit;
    text-decoration: none;
}

.rb-ad-detail__header {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 32px;
    margin-bottom: 28px;
}

.rb-ad-detail__header h1 {
    max-width: 900px;
    margin: 6px 0 0;
    font-size: clamp(34px, 5vw, 58px);
    line-height: 1;
    letter-spacing: -.045em;
}

.rb-ad-detail__premium {
    display: inline-flex;
    padding: 5px 9px;
    font-size: 10px;
    font-weight: 900;
    letter-spacing: .08em;
    text-transform: uppercase;
    color: #fff;
    background: var(--rb-primary);
    border-radius: 4px;
}

.rb-ad-detail__price {
    flex-shrink: 0;
    font-size: clamp(26px, 3vw, 38px);
}

.rb-ad-detail__layout {
    display: grid;
    grid-template-columns:
        minmax(0, 1fr)
        340px;
    gap: 28px;
    align-items: start;
}


/* =========================================================
   GALLERY
   ========================================================= */

.rb-ad-gallery {
    margin-bottom: 30px;
}

.rb-ad-gallery__main {
    display: block;
    width: 100%;
    padding: 0;
    overflow: hidden;
    cursor: zoom-in;
    background: #111;
    border: 0;
    border-radius: 12px;
    aspect-ratio: 16 / 10;
}

.rb-ad-gallery__main img {
    width: 100%;
    height: 100%;
    object-fit: contain;
}

.rb-ad-gallery__placeholder {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 480px;
    font-size: 34px;
    font-weight: 900;
    letter-spacing: .12em;
    color: #8c8f94;
    background: #eceef0;
    border-radius: 12px;
}

.rb-ad-gallery__thumbs {
    display: grid;
    grid-template-columns:
        repeat(
            auto-fill,
            minmax(90px, 1fr)
        );
    gap: 10px;
    margin-top: 10px;
}

.rb-ad-gallery__thumb {
    padding: 0;
    overflow: hidden;
    cursor: pointer;
    background: #111;
    border: 2px solid transparent;
    border-radius: 7px;
    aspect-ratio: 4 / 3;
}

.rb-ad-gallery__thumb.is-active {
    border-color: var(--rb-primary);
}

.rb-ad-gallery__thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.rb-ad-gallery__thumbs--single {
    display: none;
}


/* =========================================================
   DETAIL SECTIONS
   ========================================================= */

.rb-ad-detail-section {
    margin-top: 22px;
    padding: 26px;
    background: var(--rb-surface);
    border: 1px solid var(--rb-border);
    border-radius: 10px;
}

.rb-ad-detail-section h2 {
    margin: 0 0 20px;
    font-size: 22px;
}

.rb-ad-detail__description {
    font-size: 16px;
    line-height: 1.7;
}

.rb-ad-specifications {
    margin: 0;
}

.rb-ad-specifications__row {
    display: grid;
    grid-template-columns:
        minmax(160px, .8fr)
        minmax(0, 1.2fr);
    gap: 24px;
    padding: 12px 0;
    border-bottom: 1px solid var(--rb-border);
}

.rb-ad-specifications__row:last-child {
    border-bottom: 0;
}

.rb-ad-specifications dt {
    color: var(--rb-text-muted);
}

.rb-ad-specifications dd {
    margin: 0;
    font-weight: 700;
}


/* =========================================================
   SELLER
   ========================================================= */

.rb-seller-card {
    position: sticky;
    top: 24px;
    padding: 26px;
    background: var(--rb-surface);
    border: 1px solid var(--rb-border);
    border-radius: 12px;
}

.rb-seller-card__seller {
    padding-bottom: 20px;
}

.rb-seller-card__eyebrow {
    font-size: 10px;
    font-weight: 900;
    letter-spacing: .1em;
    text-transform: uppercase;
    color: var(--rb-text-muted);
}

.rb-seller-card h2 {
    margin: 8px 0 10px;
    font-size: 25px;
    line-height: 1.2;
}

.rb-seller-card__trust {
    display: inline-flex;
    padding: 5px 8px;
    font-size: 11px;
    font-weight: 800;
    background: #f0f0f1;
    border-radius: 4px;
}


/* =========================================================
   SELLER LOCATION
   ========================================================= */

.rb-seller-card__location {
    display: grid;
    gap: 5px;
    padding: 18px 0;
    border-top: 1px solid var(--rb-border);
    border-bottom: 1px solid var(--rb-border);
}

.rb-seller-card__location-label {
    font-size: 10px;
    font-weight: 900;
    letter-spacing: .08em;
    text-transform: uppercase;
    color: var(--rb-text-muted);
}

.rb-seller-card__location strong {
    font-size: 15px;
    line-height: 1.4;
}


/* =========================================================
   CONTACTS
   ========================================================= */

.rb-seller-card__contacts {
    display: grid;
    gap: 14px;
    margin-top: 20px;
}

.rb-contact-reveal {
    display: grid;
    gap: 7px;
}

.rb-contact-reveal__label {
    font-size: 10px;
    font-weight: 900;
    letter-spacing: .07em;
    text-transform: uppercase;
    color: var(--rb-text-muted);
}

.rb-contact-button {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    min-height: 44px;
    padding: 11px 14px;
    box-sizing: border-box;
    cursor: pointer;
    font-size: 13px;
    font-weight: 800;
    text-align: center;
    text-decoration: none;
    color: inherit;
    background: var(--rb-background);
    border: 1px solid var(--rb-border);
    border-radius: 7px;
    transition:
        color .15s ease,
        border-color .15s ease,
        background-color .15s ease,
        transform .15s ease;
}

.rb-contact-button:hover {
    color: var(--rb-primary);
    border-color: var(--rb-primary);
    transform: translateY(-1px);
}

.rb-contact-reveal__button:disabled {
    cursor: wait;
    opacity: .65;
    transform: none;
}

.rb-contact-reveal__result {
    width: 100%;
}

.rb-contact-reveal__result[hidden] {
    display: none;
}

.rb-contact-button--revealed {
    justify-content: flex-start;
    text-align: left;
    overflow-wrap: anywhere;
}

a.rb-contact-button--revealed:hover {
    color: var(--rb-primary);
}

.rb-seller-card__empty {
    margin: 20px 0 0;
    color: var(--rb-text-muted);
}


/* =========================================================
   LIGHTBOX
   ========================================================= */

.rb-gallery-lightbox {
    width: 100vw;
    max-width: none;
    height: 100vh;
    max-height: none;
    margin: 0;
    padding: 40px 70px;
    background: rgba(0, 0, 0, .94);
    border: 0;
}

.rb-gallery-lightbox::backdrop {
    background: rgba(0, 0, 0, .9);
}

.rb-gallery-lightbox[open] {
    display: flex;
    align-items: center;
    justify-content: center;
}

.rb-gallery-lightbox img {
    max-width: 100%;
    max-height: calc(100vh - 80px);
    object-fit: contain;
}

.rb-gallery-lightbox__close,
.rb-gallery-lightbox__nav {
    position: fixed;
    z-index: 2;
    width: 48px;
    height: 48px;
    cursor: pointer;
    font-size: 25px;
    color: #fff;
    background: rgba(255, 255, 255, .1);
    border: 0;
    border-radius: 50%;
}

.rb-gallery-lightbox__close {
    top: 20px;
    right: 20px;
}

.rb-gallery-lightbox__nav {
    top: 50%;
    transform: translateY(-50%);
}

.rb-gallery-lightbox__nav--prev {
    left: 18px;
}

.rb-gallery-lightbox__nav--next {
    right: 18px;
}


/* =========================================================
   RESPONSIVE
   ========================================================= */

@media (max-width: 900px) {
    .rb-ad-detail__layout {
        grid-template-columns: 1fr;
    }

    .rb-seller-card {
        position: static;
    }
}

@media (max-width: 620px) {
    .rb-ad-detail__header {
        display: block;
    }

    .rb-ad-detail__price {
        display: block;
        margin-top: 16px;
    }

    .rb-ad-specifications__row {
        grid-template-columns: 1fr;
        gap: 3px;
    }

    .rb-ad-gallery__placeholder {
        min-height: 300px;
    }

    .rb-gallery-lightbox {
        padding: 20px;
    }

    .rb-seller-card {
        padding: 22px;
    }
}