
.rbmg-container {
    width: 100%;
    padding: 20px 16px 48px;
}

.rbmg-page-header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 16px;
    flex-wrap: wrap;
    margin-bottom: 18px;
}
.rbmg-page-title {
    font-size: 1.6rem;
    font-weight: 700;
    margin: 0;
    display: flex;
    align-items: center;
    gap: 10px;
}
.rbmg-page-title i { color: var(--primary, var(--rb-primary, #3b82f6)); }
.rbmg-page-sub {
    margin: 4px 0 0;
    color: var(--rb-text-muted, #6b7280);
    font-size: .9rem;
}

.rbmg-breadcrumb {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
    font-size: .85rem;
    margin-bottom: 16px;
    color: var(--rb-text-muted, #6b7280);
}
.rbmg-breadcrumb a { color: inherit; text-decoration: none; }
.rbmg-breadcrumb a:hover { color: var(--primary, #3b82f6); }
.rbmg-crumb-sep { font-size: .65rem; opacity: .5; }

.rbmg-container .rb-avatar--xs,
.rbmg-container .rb-avatar--sm {
    border-radius: var(--av-br, 50%);
}
.rbmg-container .rb-avatar--xs {
    --av-sz: 18px;
    --av-fs: 9px;
    width: 18px;
    height: 18px;
    font-size: 9px;
}
.rbmg-container .rb-avatar--sm {
    --av-sz: 24px;
    --av-fs: 11px;
    width: 24px;
    height: 24px;
    font-size: 11px;
}

.rbmg-crumb-row { display: flex; align-items: flex-start; gap: 10px; }
.rbmg-crumb-row .rbmg-breadcrumb { flex: 1; min-width: 0; }
.rbmg-back {
    flex: 0 0 auto;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 34px;
    height: 34px;
    margin-top: -6px;
    border-radius: var(--radius, 8px);
    background: var(--surface-2, rgba(127, 127, 127, .1));
    border: 1px solid var(--border, var(--rb-border, #e5e7eb));
    color: inherit;
    text-decoration: none;
    font-size: .85rem;
    transition: background .15s, border-color .15s, transform .15s;
}
.rbmg-back:hover {
    border-color: var(--primary, #3b82f6);
    color: var(--primary, #3b82f6);
    transform: translateX(-2px);
}
.rbmg-back:focus-visible { outline: 2px solid var(--primary, #3b82f6); outline-offset: 2px; }

.rbmg-layout {
    display: grid;
    grid-template-columns: 250px 1fr;
    gap: 20px;
    align-items: start;
}
.rbmg-cat-card { padding: 0; overflow: hidden; }
.rbmg-cat-head {
    padding: 12px 14px;
    font-weight: 700;
    font-size: .8rem;
    text-transform: uppercase;
    letter-spacing: .04em;
    border-bottom: 1px solid var(--border, var(--rb-border, #e5e7eb));
    display: flex;
    align-items: center;
    gap: 8px;
}
.rbmg-cat-list { display: flex; flex-direction: column; padding: 6px; }
.rbmg-cat-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
    padding: 8px 12px;
    border-radius: var(--radius, 8px);
    text-decoration: none;
    color: inherit;
    font-size: .9rem;
    transition: background .15s;
}
.rbmg-cat-item:hover { background: var(--surface-2, var(--rb-surface-2, rgba(127,127,127,.08))); }
.rbmg-cat-item.active {
    background: var(--surface-2, rgba(127,127,127,.10));
    color: var(--primary, #3b82f6);
    font-weight: 600;
}
.rbmg-cat-count {
    font-size: .72rem;
    background: var(--bg-elev, rgba(127,127,127,.14));
    color: var(--rb-text-muted, #6b7280);
    border-radius: 999px;
    padding: 1px 8px;
}

.rbmg-sortbar {
    display: flex;
    gap: 6px;
    flex-wrap: wrap;
    margin-bottom: 16px;
}
.rbmg-sort-tab i { margin-right: 6px; opacity: .75; }
.rbmg-sort-tab {
    padding: 6px 12px;
    border-radius: var(--radius, 8px);
    font-size: .85rem;
    text-decoration: none;
    color: var(--rb-text-muted, #6b7280);
    border: 1px solid transparent;
    transition: all .15s;
}
.rbmg-sort-tab:hover { background: var(--surface-2, rgba(127,127,127,.08)); }
.rbmg-sort-tab.active {
    background: var(--primary, #3b82f6);
    color: #fff;
}

.rbmg-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
    gap: 14px;
}
.rbmg-card {
    display: flex;
    flex-direction: column;
    border-radius: var(--radius-lg, 12px);
    overflow: hidden;
    background: var(--surface-2, var(--rb-surface, #fff));
    border: 1px solid var(--border, var(--rb-border, #e5e7eb));
    text-decoration: none;
    color: inherit;
    transition: transform .15s, box-shadow .15s, border-color .15s;
}
.rbmg-card:hover {
    transform: translateY(-3px);
    box-shadow: var(--rb-shadow, 0 6px 20px rgba(0,0,0,.12));
    border-color: var(--primary, #3b82f6);
}
.rbmg-thumb-wrap {
    position: relative;
    aspect-ratio: 1 / 1;
    background: var(--surface-2, #f1f5f9);
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}
.rbmg-thumb-img { width: 100%; height: 100%; object-fit: cover; display: block; }
.rbmg-thumb-icon { font-size: 2.4rem; color: var(--rb-text-muted, #9ca3af); opacity: .6; }
.rbmg-badge-featured {
    position: absolute;
    top: 8px;
    left: 8px;
    background: rgba(0,0,0,.6);
    color: #fbbf24;
    width: 26px; height: 26px;
    border-radius: 50%;
    display: flex; align-items: center; justify-content: center;
    font-size: .75rem;
}
.rbmg-card-body { padding: 10px 12px; }
.rbmg-card-title {
    font-weight: 600;
    font-size: .92rem;
    line-height: 1.3;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}
.rbmg-card-meta {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-top: 6px;
    font-size: .78rem;
    color: var(--rb-text-muted, #6b7280);
}
.rbmg-card-author { display: flex; align-items: center; gap: 6px; overflow: hidden; }
.rbmg-card-author span:last-child { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.rbmg-card-views { white-space: nowrap; }

.rbmg-empty {
    text-align: center;
    padding: 64px 20px;
    border: 1px dashed var(--border, var(--rb-border, #e5e7eb));
    border-radius: var(--radius-lg, 12px);
}
.rbmg-empty > i { font-size: 2.6rem; color: var(--rb-text-muted, #9ca3af); opacity: .35; }
.rbmg-empty-title { font-weight: 700; margin: 14px 0 4px; }
.rbmg-empty-hint { color: var(--rb-text-muted, #6b7280); margin: 0 0 16px; }

.rbmg-pagination {
    display: flex;
    gap: 6px;
    flex-wrap: wrap;
    justify-content: center;
    margin-top: 24px;
}
.rbmg-page-link {
    min-width: 36px;
    height: 36px;
    padding: 0 10px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: var(--radius, 8px);
    border: 1px solid var(--border, var(--rb-border, #e5e7eb));
    text-decoration: none;
    color: inherit;
    font-size: .88rem;
}
.rbmg-page-link:hover { background: var(--surface-2, rgba(127,127,127,.08)); }
.rbmg-page-link.active {
    background: var(--primary, #3b82f6);
    color: #fff;
    border-color: var(--primary, #3b82f6);
}
.rbmg-page-gap { align-self: center; color: var(--rb-text-muted, #9ca3af); }

.rbmg-view-grid {
    display: grid;
    grid-template-columns: 1fr 340px;
    gap: 20px;
    align-items: start;
}
.rbmg-stage {
    background: var(--surface-2, var(--rb-surface, #111));
    border: 1px solid var(--border, var(--rb-border, #e5e7eb));
    border-radius: var(--radius-lg, 12px);
    overflow: hidden;
}
.rbmg-stage-media {
    position: relative;
    background: #0b0b0f;
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 320px;
}
.rbmg-stage-img {
    max-width: 100%;
    max-height: 76vh;
    display: block;
    cursor: zoom-in;
}
.rbmg-stage-placeholder { font-size: 4rem; color: rgba(255,255,255,.3); padding: 60px; }
.rbmg-nav {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    width: 52px; height: 52px;
    border-radius: 50%;
    background: rgba(0,0,0,.45);
    border: 1px solid rgba(255,255,255,.18);
    color: #fff;
    font-size: 1.25rem;
    display: flex; align-items: center; justify-content: center;
    text-decoration: none;
    z-index: 3;
    opacity: .8;
    backdrop-filter: blur(2px);
    transition: background .15s, opacity .15s, border-color .15s, transform .15s;
}
.rbmg-nav:hover {
    background: rgba(0,0,0,.85);
    border-color: var(--primary, #f97316);
    opacity: 1;
}
.rbmg-nav:focus-visible { outline: 2px solid var(--primary, #f97316); outline-offset: 2px; opacity: 1; }
.rbmg-nav-prev { left: 14px; }
.rbmg-nav-next { right: 14px; }
.rbmg-nav-prev:hover { transform: translateY(-50%) translateX(-2px); }
.rbmg-nav-next:hover { transform: translateY(-50%) translateX(2px); }

.rbmg-stage-count {
    position: absolute;
    top: 12px; left: 12px;
    z-index: 3;
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 6px 11px;
    border-radius: 999px;
    background: rgba(0,0,0,.55);
    border: 1px solid rgba(255,255,255,.16);
    color: #fff;
    font-size: .8rem;
    font-weight: 600;
    line-height: 1;
    backdrop-filter: blur(2px);
    pointer-events: none;
}
.rbmg-count-item { display: inline-flex; align-items: center; gap: 5px; }
.rbmg-count-item i { font-size: .78rem; opacity: .85; }
.rbmg-count-pos {
    padding-left: 10px;
    border-left: 1px solid rgba(255,255,255,.22);
    opacity: .8;
    font-variant-numeric: tabular-nums;
}

.rbmg-fullscreen {
    position: absolute;
    right: 12px; bottom: 12px;
    z-index: 3;
    width: 38px; height: 38px;
    display: flex; align-items: center; justify-content: center;
    border-radius: 8px;
    background: rgba(0,0,0,.55);
    border: 1px solid rgba(255,255,255,.16);
    color: #fff;
    font-size: .9rem;
    cursor: pointer;
    opacity: .8;
    backdrop-filter: blur(2px);
    transition: background .15s, opacity .15s, border-color .15s;
}
.rbmg-fullscreen:hover { background: rgba(0,0,0,.85); border-color: var(--primary, #f97316); opacity: 1; }
.rbmg-fullscreen:focus-visible { outline: 2px solid var(--primary, #f97316); outline-offset: 2px; opacity: 1; }

.rbmg-strip {
    display: flex;
    gap: 8px;
    padding: 10px;
    overflow-x: auto;
    scrollbar-width: thin;
    background: var(--surface-2, rgba(0,0,0,.15));
    border-top: 1px solid var(--border, var(--rb-border, #e5e7eb));
}
.rbmg-strip-item {
    position: relative;
    flex: 0 0 auto;
    width: 88px;
    height: 62px;
    border-radius: 6px;
    overflow: hidden;
    background: #0b0b0f;
    border: 2px solid transparent;
    display: flex;
    align-items: center;
    justify-content: center;
    text-decoration: none;
    opacity: .65;
    transition: opacity .15s, border-color .15s, transform .15s;
}
.rbmg-strip-item img { width: 100%; height: 100%; object-fit: cover; display: block; }
.rbmg-strip-icon { color: rgba(255,255,255,.45); font-size: 1.2rem; }
.rbmg-strip-item:hover { opacity: 1; transform: translateY(-2px); }
.rbmg-strip-item.active {
    opacity: 1;
    border-color: var(--primary, #f97316);
    box-shadow: 0 0 0 1px var(--primary, #f97316);
}
.rbmg-strip-item:focus-visible { outline: 2px solid var(--primary, #f97316); outline-offset: 1px; opacity: 1; }
.rbmg-strip-play {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    font-size: .7rem;
    text-shadow: 0 1px 3px rgba(0,0,0,.8);
    background: rgba(0,0,0,.2);
    pointer-events: none;
}
.rbmg-open-full {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 10px;
    font-size: .85rem;
    text-decoration: none;
    color: var(--rb-text-muted, #6b7280);
    border-top: 1px solid var(--border, var(--rb-border, #e5e7eb));
}
.rbmg-open-full:hover { color: var(--primary, #3b82f6); }

.rbmg-info-card { padding: 18px; }
.rbmg-view-title { font-size: 1.3rem; font-weight: 700; margin: 0 0 14px; }
.rbmg-uploader {
    display: flex;
    align-items: center;
    gap: 10px;
    padding-bottom: 14px;
    margin-bottom: 14px;
    border-bottom: 1px solid var(--border, var(--rb-border, #e5e7eb));
    text-decoration: none;
    color: inherit;
}
.rbmg-uploader:hover .rbmg-uploader-name { color: var(--primary, #3b82f6); }
.rbmg-uploader-name { font-weight: 600; }
.rbmg-description.bbcode-content :is(img) { max-width: 100%; height: auto; }
.rbmg-uploader-meta { font-size: .76rem; color: var(--rb-text-muted, #6b7280); }
.rbmg-section-label {
    text-transform: uppercase;
    font-size: .72rem;
    letter-spacing: .05em;
    color: var(--rb-text-muted, #9ca3af);
    font-weight: 700;
    margin: 16px 0 8px;
}
.rbmg-description { font-size: .92rem; line-height: 1.55; word-break: break-word; }
.rbmg-detail-list { list-style: none; margin: 0; padding: 0; }
.rbmg-detail-list li {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 7px 0;
    font-size: .88rem;
    border-bottom: 1px solid var(--border, rgba(127,127,127,.12));
}
.rbmg-detail-list li > span { color: var(--rb-text-muted, #6b7280); display: flex; align-items: center; gap: 8px; }
.rbmg-detail-list li a { color: var(--primary, #3b82f6); text-decoration: none; }
.rbmg-actions { display: flex; gap: 8px; margin-top: 18px; flex-wrap: wrap; }
.rbmg-inline-form { display: inline; }

.rbmg-btn {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 8px 14px;
    border-radius: var(--radius, 8px);
    border: 1px solid var(--border-strong, var(--rb-border, #d1d5db));
    background: var(--surface-2, transparent);
    color: inherit;
    text-decoration: none;
    cursor: pointer;
    font-size: .9rem;
}
.rbmg-btn:hover { background: var(--surface-2, rgba(127,127,127,.08)); }
.rbmg-btn-danger,
.rb-button.rbmg-btn-danger {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 8px 14px;
    border-radius: var(--radius, 8px);
    border: 1px solid var(--rb-danger, #dc2626);
    background: var(--rb-danger, #dc2626);
    color: #fff;
    cursor: pointer;
    font-size: .9rem;
}
.rbmg-btn-danger:hover,
.rb-button.rbmg-btn-danger:hover { filter: brightness(0.92); color: #fff; }

.rbmg-form-wrap { width: 100%; }
.rbmg-form-card { padding: 22px; }
.rbmg-form-card .rbmg-form { max-width: 860px; }
.rbmg-form-title { font-size: 1.3rem; font-weight: 700; margin: 0 0 18px; display: flex; align-items: center; gap: 10px; }
.rbmg-field { margin-bottom: 16px; }
.rbmg-field label { display: block; font-weight: 600; margin-bottom: 6px; font-size: .9rem; }
.rbmg-field input[type="text"],
.rbmg-field input[type="file"],
.rbmg-field select,
.rbmg-field textarea {
    width: 100%;
    padding: 10px 12px;
    border-radius: var(--radius, 8px);
    border: 1px solid var(--border-strong, var(--rb-border, #d1d5db));
    background: var(--input, var(--surface-2, transparent));
    color: inherit;
    font: inherit;
}
.rbmg-field textarea { resize: vertical; }
.rbmg-field-hint { font-size: .78rem; color: var(--rb-text-muted, #6b7280); margin: 6px 0 0; }
.rbmg-form-actions { display: flex; justify-content: flex-end; gap: 10px; margin-top: 8px; }
.rbmg-alert {
    display: flex;
    gap: 10px;
    padding: 12px 14px;
    border-radius: var(--radius, 8px);
    margin-bottom: 18px;
    font-size: .88rem;
}
.rbmg-alert ul { margin: 0; padding-left: 18px; }
.rbmg-alert-error {
    background: rgba(220,38,38,.08);
    border: 1px solid var(--rb-danger, #dc2626);
    color: var(--rb-danger, #dc2626);
}
.rbmg-alert-info {
    align-items: center;
    background: rgba(59,130,246,.08);
    border: 1px solid var(--primary, #3b82f6);
    color: var(--primary, #3b82f6);
}

.rbmg-lightbox {
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,.9);
    display: none;
    align-items: center;
    justify-content: center;
    z-index: 9999;
    cursor: zoom-out;
}
.rbmg-lightbox.open { display: flex; }
.rbmg-lightbox img { max-width: 94vw; max-height: 94vh; box-shadow: 0 10px 40px rgba(0,0,0,.5); }
.rbmg-lightbox-close {
    position: absolute;
    top: 18px; right: 22px;
    color: #fff;
    font-size: 1.6rem;
    background: none;
    border: none;
    cursor: pointer;
}

.rbmg-w-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 6px; }
.rbmg-w-thumb {
    display: block;
    aspect-ratio: 1 / 1;
    border-radius: var(--radius-sm, 6px);
    overflow: hidden;
    background: var(--surface-2, #f1f5f9);
}
.rbmg-w-thumb img { width: 100%; height: 100%; object-fit: cover; display: block; }
.rbmg-w-icon { width: 100%; height: 100%; display: flex; align-items: center; justify-content: center; color: var(--rb-text-muted, #9ca3af); }
.rbmg-w-stats { list-style: none; margin: 0; padding: 0; }
.rbmg-w-stats li { display: flex; align-items: center; justify-content: space-between; padding: 7px 2px; font-size: .88rem; }
.rbmg-w-stat-label { color: var(--rb-text-muted, #6b7280); display: flex; align-items: center; gap: 8px; }
.rbmg-w-stat-value { font-weight: 700; }

.rbmg-header-actions { display: flex; gap: 8px; flex-wrap: wrap; }
.rbmg-album-card .rbmg-thumb-wrap { aspect-ratio: 4 / 3; }
.rbmg-album-count {
    position: absolute;
    bottom: 8px;
    right: 8px;
    background: rgba(0,0,0,.62);
    color: #fff;
    font-size: .72rem;
    padding: 2px 8px;
    border-radius: 999px;
    display: flex;
    align-items: center;
    gap: 5px;
}
.rbmg-album-priv {
    position: absolute;
    top: 8px;
    right: 8px;
    background: rgba(0,0,0,.55);
    color: #fff;
    width: 26px; height: 26px;
    border-radius: 50%;
    display: flex; align-items: center; justify-content: center;
    font-size: .72rem;
}
.rbmg-album-header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 16px;
    flex-wrap: wrap;
    padding: 18px;
    margin-bottom: 18px;
}
.rbmg-album-head-main { min-width: 0; }
.rbmg-album-meta {
    display: flex;
    align-items: center;
    gap: 16px;
    flex-wrap: wrap;
    margin-top: 8px;
    font-size: .85rem;
    color: var(--rb-text-muted, #6b7280);
}
.rbmg-album-meta a { color: inherit; text-decoration: none; }
.rbmg-album-meta a:hover { color: var(--primary, #3b82f6); }
.rbmg-priv-badge {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 2px 10px;
    border-radius: 999px;
    background: var(--surface-2, rgba(127,127,127,.1));
}
.rbmg-album-desc { margin: 12px 0 0; line-height: 1.5; word-break: break-word; }

.rb-button.rbmg-watching, .rbmg-btn.rbmg-watching {
    border-color: var(--primary, #3b82f6);
    color: var(--primary, #3b82f6);
}

.rbmg-stage-video { max-width: 100%; max-height: 76vh; display: block; background: #000; }
.rbmg-stage-audio {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 18px;
    padding: 48px 24px;
    width: 100%;
    color: rgba(255,255,255,.55);
}
.rbmg-stage-audio i { font-size: 3rem; }
.rbmg-stage-audio audio { width: min(90%, 480px); }
.rbmg-stage-embed { width: 100%; aspect-ratio: 16 / 9; }
.rbmg-stage-embed iframe { width: 100%; height: 100%; border: 0; display: block; }

.rbmg-stage-media:fullscreen {
    width: 100vw;
    height: 100vh;
    background: #000;
}
.rbmg-stage-media:fullscreen .rbmg-stage-img,
.rbmg-stage-media:fullscreen .rbmg-stage-video {
    max-width: 100vw;
    max-height: 100vh;
    object-fit: contain;
    cursor: default;
}
.rbmg-stage-media:fullscreen .rbmg-stage-embed { width: min(100vw, 177.78vh); }
.rbmg-play-badge {
    position: absolute;
    top: 50%; left: 50%;
    transform: translate(-50%, -50%);
    width: 46px; height: 46px;
    border-radius: 50%;
    background: rgba(0,0,0,.55);
    color: #fff;
    display: flex; align-items: center; justify-content: center;
    font-size: .95rem;
    pointer-events: none;
}
.rbmg-or {
    display: flex;
    align-items: center;
    gap: 0;
    text-align: center;
    color: var(--rb-text-muted, #9ca3af);
    font-size: .76rem;
    text-transform: uppercase;
    letter-spacing: .06em;
    margin: 4px 0;
}
.rbmg-or::before, .rbmg-or::after { content: ""; flex: 1; height: 1px; background: var(--border, var(--rb-border, #e5e7eb)); }
.rbmg-or span { padding: 0 12px; }

.rbmg-engage {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    flex-wrap: wrap;
    margin: 16px 0 4px;
    padding-top: 14px;
    border-top: 1px solid var(--border, var(--rb-border, #e5e7eb));
}
.rbmg-stars-static { display: inline-flex; align-items: center; gap: 3px; }
.rbmg-stars .on, .rbmg-rate-star.on { color: #f59e0b; }
.rbmg-stars .off, .rbmg-rate-star.off { color: var(--rb-text-muted, #cbd5e1); opacity: .55; }
.rbmg-rating-num { font-weight: 700; margin-left: 6px; }
.rbmg-rating-count { color: var(--rb-text-muted, #6b7280); font-size: .82rem; }
.rbmg-rate-form { display: flex; align-items: center; gap: 8px; margin-top: 8px; }
.rbmg-rate-label { font-size: .8rem; color: var(--rb-text-muted, #6b7280); }
.rbmg-rate-stars { display: inline-flex; }
.rbmg-rate-star {
    background: none; border: none; cursor: pointer; padding: 2px;
    font-size: 1.05rem; line-height: 1;
}
.rbmg-rate-star:hover, .rbmg-rate-star:hover ~ .rbmg-rate-star { color: #f59e0b; }
.rbmg-react-form { margin: 0; }
.rbmg-react-btn {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    padding: 8px 14px;
    border-radius: 999px;
    border: 1px solid var(--border-strong, var(--rb-border, #d1d5db));
    background: var(--surface-2, transparent);
    color: inherit;
    cursor: pointer;
    font-size: .88rem;
}
.rbmg-react-btn:hover { border-color: var(--rb-danger, #ef4444); color: var(--rb-danger, #ef4444); }
.rbmg-react-btn.reacted {
    border-color: var(--rb-danger, #ef4444);
    background: rgba(239,68,68,.1);
    color: var(--rb-danger, #ef4444);
}
.rbmg-react-btn.reacted .fa-heart { color: var(--rb-danger, #ef4444); }
.rbmg-react-count { font-weight: 700; }

.rbmg-comments { padding: 18px; margin-top: 20px; }
.rbmg-comments-head {
    display: flex;
    align-items: center;
    gap: 8px;
    font-weight: 700;
    font-size: 1.05rem;
    margin-bottom: 16px;
}
.rbmg-comments-count {
    background: var(--bg-elev, rgba(127,127,127,.14));
    color: var(--rb-text-muted, #6b7280);
    border-radius: 999px;
    padding: 0 9px;
    font-size: .8rem;
}
.rbmg-comments-empty { color: var(--rb-text-muted, #6b7280); margin: 0 0 16px; }
.rbmg-comment-list { list-style: none; margin: 0 0 18px; padding: 0; }
.rbmg-comment { display: flex; gap: 12px; padding: 14px 0; border-bottom: 1px solid var(--border, rgba(127,127,127,.12)); }
.rbmg-comment-body { flex: 1; min-width: 0; }
.rbmg-comment-head { display: flex; align-items: baseline; gap: 10px; flex-wrap: wrap; }
.rbmg-comment-author { font-weight: 600; text-decoration: none; color: inherit; }
.rbmg-comment-author:hover { color: var(--primary, #3b82f6); }
.rbmg-comment-date { font-size: .76rem; color: var(--rb-text-muted, #9ca3af); }
.rbmg-comment-text { margin-top: 5px; line-height: 1.5; word-break: break-word; }
.rbmg-comment-actions { display: flex; align-items: center; gap: 14px; margin-top: 8px; }
.rbmg-comment-edit summary {
    cursor: pointer; font-size: .78rem; color: var(--rb-text-muted, #6b7280); list-style: none;
}
.rbmg-comment-edit summary:hover { color: var(--primary, #3b82f6); }
.rbmg-comment-edit-form { margin-top: 8px; display: flex; flex-direction: column; gap: 8px; }
.rbmg-comment-edit-form textarea,
.rbmg-comment-form textarea {
    width: 100%;
    padding: 10px 12px;
    border-radius: var(--radius, 8px);
    border: 1px solid var(--border-strong, var(--rb-border, #d1d5db));
    background: var(--input, var(--surface-2, transparent));
    color: inherit;
    font: inherit;
    resize: vertical;
}
.rbmg-btn-sm { align-self: flex-start; padding: 6px 12px; font-size: .82rem; }
.rbmg-comment-del {
    background: none; border: none; cursor: pointer; padding: 0;
    font-size: .78rem; color: var(--rb-danger, #dc2626);
    display: inline-flex; align-items: center; gap: 5px;
}
.rbmg-comment-form { display: flex; flex-direction: column; gap: 10px; }
.rbmg-comment-form-actions { display: flex; justify-content: flex-end; }
.rbmg-comments-login { color: var(--rb-text-muted, #6b7280); }
.rbmg-comments-login a { color: var(--primary, #3b82f6); }

@media (max-width: 900px) {
    .rbmg-layout { grid-template-columns: 1fr; }
    .rbmg-sidebar { order: 2; }
    .rbmg-view-grid { grid-template-columns: 1fr; }
}
@media (max-width: 520px) {
    .rbmg-grid { grid-template-columns: repeat(auto-fill, minmax(140px, 1fr)); }
    .rbmg-page-title { font-size: 1.3rem; }
    .rbmg-nav { width: 40px; height: 40px; font-size: 1rem; }
    .rbmg-nav-prev { left: 6px; }
    .rbmg-nav-next { right: 6px; }
    .rbmg-stage-count { top: 8px; left: 8px; font-size: .72rem; gap: 8px; padding: 5px 9px; }
    .rbmg-fullscreen { right: 8px; bottom: 8px; width: 34px; height: 34px; }
    .rbmg-strip-item { width: 68px; height: 50px; }
}
