.postprofile .profile-mopedgarage {
    display: block;
    width: 100%;
    margin-top: 8px;
    box-sizing: border-box;
}

.postprofile .profile-mopedgarage .mopedgarage-post-slider {
    display: block;
    width: 100%;
    box-sizing: border-box;
}

.postprofile .profile-mopedgarage .mopedgarage-post-slider__top {
    display: flex;
    align-items: flex-start;
    justify-content: center;
    gap: 4px;
    width: 100%;
}

.postprofile .profile-mopedgarage .mopedgarage-post-slider__viewport {
    flex: 0 0 50%;
    max-width: 50%;
    min-width: 50%;
}

.postprofile .profile-mopedgarage .mopedgarage-post-slider__nav {
    flex: 0 0 18px;
    width: 18px;
    height: 24px;
    margin: 0;
    padding: 0;
    border: 1px solid #b9c8d3;
    border-radius: 4px;
    background: #edf3f7;
    color: #4f6b81;
    font-size: 16px;
    line-height: 22px;
    text-align: center;
    cursor: pointer;
}

.postprofile .profile-mopedgarage .mopedgarage-post-slider__nav:hover {
    background: #dde8ef;
}

.postprofile .profile-mopedgarage .mopedgarage-post-slider__status {
    margin-top: 4px;
    text-align: center;
    font-size: 10px;
    color: #4f6b81;
}

.postprofile .profile-mopedgarage .mopedgarage-post-slide {
    display: none;
    width: 100%;
}

.postprofile .profile-mopedgarage .mopedgarage-post-slide.is-active {
    display: block;
}

.postprofile .profile-mopedgarage .mopedgarage-post-slide__image {
    display: block;
    width: 100%;
    border: 1px solid #c7d7e2;
    border-radius: 6px;
    overflow: hidden;
    background: #edf3f7;
    line-height: 0;
}

.postprofile .profile-mopedgarage .mopedgarage-post-slide__image img {
    display: block;
    width: 100%;
    height: auto;
    max-width: 100%;
}

.postprofile .profile-mopedgarage .mopedgarage-post-slide__body {
    margin-top: 4px;
    font-size: 11px;
    line-height: 1.35;
    color: #2f3f4c;
    word-break: break-word;
}

.postprofile .profile-mopedgarage .mopedgarage-post-slide__title {
    margin: 0 0 3px 0;
    font-weight: 700;
    color: #105289;
}

.postprofile .profile-mopedgarage .mopedgarage-post-slide__line {
    margin-top: 2px;
}

.postprofile .profile-mopedgarage .mopedgarage-post-slide__label {
    font-weight: 700;
    color: #4f6b81;
}

.mopedgarage-nav-item span {
    text-transform: none;
}

.mopedgarage-search-form .submit-buttons,
.mopedgarage-search-embed-panel .submit-buttons,
#ucp_mopedgarage .submit-buttons {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 8px;
    margin-top: 10px;
}

.mopedgarage-search-form .submit-buttons .button1,
.mopedgarage-search-form .submit-buttons .button2,
.mopedgarage-search-form .submit-buttons .button,
.mopedgarage-search-embed-panel .submit-buttons .button1,
.mopedgarage-search-embed-panel .submit-buttons .button2,
.mopedgarage-search-embed-panel .submit-buttons .button,
.mopedgarage-search-actions .button2,
#ucp_mopedgarage .submit-buttons .button1,
#ucp_mopedgarage .submit-buttons .button2,
.mopedgarage-upload-actions .button2 {
    display: inline-block;
    box-sizing: border-box;
    min-height: 0;
    text-decoration: none;
    white-space: nowrap;
    vertical-align: middle;
}

.mopedgarage-search-form .fields1 dl,
.mopedgarage-search-embed-panel .fields1 dl,
#ucp_mopedgarage dl {
    overflow: hidden;
}

.mopedgarage-gallery-grid,
.mopedgarage-cards,
.mopedgarage-ucp-grid {
    display: flex;
    flex-wrap: wrap;
    gap: 16px;
}

.mopedgarage-gallery-card,
.mopedgarage-card,
.mopedgarage-bike-card {
    box-sizing: border-box;
    border: 1px solid #d9e2e9;
    border-radius: 6px;
    background: #f7fbfd;
}

.mopedgarage-gallery-card {
    flex: 1 1 calc(25% - 16px);
    min-width: 220px;
}

.mopedgarage-card {
    flex: 1 1 calc(25% - 16px);
    min-width: 220px;
}

.mopedgarage-bike-card {
    flex: 1 1 calc(50% - 16px);
    min-width: 300px;
}

.mopedgarage-gallery-card__image,
.mopedgarage-card__image {
    background: #eef5f9;
    text-align: center;
}

.mopedgarage-gallery-card__image img,
.mopedgarage-card__image img,
.mopedgarage-upload-preview {
    display: block;
    width: 100%;
    height: auto;
}

.mopedgarage-gallery-card__body,
.mopedgarage-card__body,
.mopedgarage-bike-card__header,
.mopedgarage-bike-card__body {
    padding: 12px;
}

.mopedgarage-bike-card__title,
.mopedgarage-gallery-card__title,
.mopedgarage-card__title {
    margin-top: 0;
}

.mopedgarage-upload-preview-wrap {
    margin-top: 8px;
}

.mopedgarage-upload-preview-wrap.is-hidden {
    display: none;
}

.mopedgarage-upload-preview-link {
    display: inline-block;
    max-width: 320px;
}

.mopedgarage-upload-preview {
    max-width: 320px;
    border: 1px solid #c7d7e2;
    border-radius: 4px;
}

.mopedgarage-upload-actions {
    margin-top: 8px;
}

.mopedgarage-upload-actions .button2 + .button2 {
    margin-left: 6px;
}

.mopedgarage-upload-widget .js-mopedgarage-file-input {
    position: absolute;
    left: -9999px;
    width: 1px;
    height: 1px;
    opacity: 0;
    pointer-events: none;
}

.mopedgarage-lightbox[hidden] {
    display: none !important;
}

.mopedgarage-lightbox {
    position: fixed;
    inset: 0;
    z-index: 9999;
}

.mopedgarage-lightbox__backdrop {
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, 0.82);
}

.mopedgarage-lightbox__dialog {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 24px;
    box-sizing: border-box;
}

.mopedgarage-lightbox__content {
    position: relative;
    display: flex;
    flex-direction: column;
    align-items: center;
    max-width: min(96vw, 1400px);
    max-height: calc(100vh - 48px);
    width: auto;
    box-sizing: border-box;
    z-index: 1;
}

.mopedgarage-lightbox__image {
    display: block;
    max-width: 100%;
    max-height: calc(100vh - 110px);
    width: auto;
    height: auto;
    border-radius: 8px;
    box-shadow: 0 8px 30px rgba(0, 0, 0, 0.45);
    background: #111;
}

.mopedgarage-lightbox__caption {
    margin-top: 10px;
    max-width: 100%;
    color: #fff;
    text-align: center;
    line-height: 1.4;
}

.mopedgarage-lightbox__close {
    position: absolute;
    top: 12px;
    right: 12px;
    z-index: 2;
    width: 40px;
    height: 40px;
    padding: 0;
    border: 0;
    border-radius: 999px;
    background: rgba(0, 0, 0, 0.65);
    color: #fff;
    font-size: 28px;
    line-height: 40px;
    text-align: center;
    cursor: pointer;
}

.mopedgarage-lightbox__close:hover {
    background: rgba(0, 0, 0, 0.8);
}

@media (max-width: 900px) {
    .mopedgarage-gallery-card,
    .mopedgarage-card,
    .mopedgarage-bike-card {
        flex: 1 1 calc(50% - 16px);
    }
}

@media (max-width: 700px) {
    .mopedgarage-lightbox__dialog {
        padding: 12px;
    }

    .mopedgarage-lightbox__content {
        max-width: 100%;
        max-height: calc(100vh - 24px);
    }

    .mopedgarage-lightbox__image {
        max-height: calc(100vh - 80px);
    }

    .mopedgarage-lightbox__close {
        top: 8px;
        right: 8px;
    }
}

@media (max-width: 600px) {
    .mopedgarage-gallery-card,
    .mopedgarage-card,
    .mopedgarage-bike-card {
        flex: 1 1 100%;
        min-width: 0;
    }
}

/* Keep the Mopedgarage quick-link in normal case even when the board style uppercases nav labels */
.mopedgarage-nav-item > a,
.mopedgarage-nav-item > a:link,
.mopedgarage-nav-item > a:visited,
.mopedgarage-nav-item > a:hover,
.mopedgarage-nav-item > a:focus,
.mopedgarage-nav-item .mopedgarage-nav-label,
.mopedgarage-nav-item span {
    text-transform: none !important;
}
