.hub-wrap { max-width: 960px; padding: 12px 10px 40px; }
.tabs { display: flex; gap: 6px; flex-wrap: wrap; margin-bottom: 12px; }
.tabs a {
    padding: 8px 14px;
    border-radius: 8px;
    border: 1px solid var(--border);
    background: var(--bg-card);
    color: var(--text-muted);
    text-decoration: none;
    font-size: 12px;
}
.tabs a.active { background: var(--accent); border-color: var(--accent); color: #fff; }
.tabs a:hover:not(.active) { color: var(--text); border-color: var(--accent); }
.hub-note { font-size: 12px; color: var(--text-muted); margin-bottom: 12px; }
.hub-note a { color: var(--accent); text-decoration: none; }
.hub-note a:hover { text-decoration: underline; }
.hub-stats { display: flex; flex-wrap: wrap; gap: 10px; margin-bottom: 16px; }
.hub-stat { background: var(--bg-card); border: 1px solid var(--border); border-radius: 10px; padding: 12px 16px; min-width: 120px; }
.hub-stat .num { font-size: 22px; font-weight: 700; color: var(--accent); }
.hub-stat .lbl { font-size: 11px; color: var(--text-muted); margin-top: 4px; }
.hub-stats--panel { margin-top: 4px; margin-bottom: 0; }

.hub-filter-toggle {
    margin: 0 0 14px;
    border: 1px solid var(--border);
    border-radius: 10px;
    background: var(--bg-card);
    overflow: hidden;
}
.hub-filter-toggle > summary {
    list-style: none;
    cursor: pointer;
    padding: 10px 14px;
    font-size: 12px;
    font-weight: 700;
    letter-spacing: .06em;
    text-transform: uppercase;
    color: var(--text-muted);
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}
.hub-filter-toggle > summary::-webkit-details-marker { display: none; }
.hub-filter-toggle > summary::after {
    content: '▾';
    font-size: 11px;
    opacity: .7;
}
.hub-filter-toggle[open] > summary::after { content: '▴'; }
.hub-filter-toggle[open] > summary {
    border-bottom: 1px solid var(--border);
}

.rb-filter-panel {
    display: flex;
    flex-direction: column;
    gap: 8px;
    padding: 10px;
}
.hub-city-tabs { margin-bottom: 0; }
.rb-filter-chips {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 8px 10px;
}
.rb-filter-meta-line {
    font-size: 11px;
    color: var(--text-muted);
    line-height: 1.35;
}
.rb-chip-tabs {
    display: flex;
    flex-wrap: wrap;
    gap: 4px;
}
.rb-chip-tabs a {
    padding: 4px 10px;
    border-radius: 999px;
    border: 1px solid var(--border);
    background: transparent;
    color: var(--text-muted);
    text-decoration: none;
    font-size: 11px;
    line-height: 1.35;
    white-space: nowrap;
}
.rb-chip-tabs a.active {
    background: var(--accent);
    border-color: var(--accent);
    color: #fff;
    font-weight: 600;
}
.rb-chip-tabs a:hover:not(.active) {
    border-color: var(--accent);
    color: var(--text);
}
.hub-tag-row .hub-tag-pill.active {
    box-shadow: 0 0 0 1px rgba(244, 114, 182, .55);
}
.hub-filter-bar { margin-bottom: 0; }

.set-badge {
    font-size: 10px;
    padding: 2px 7px;
    border-radius: 10px;
    background: rgba(45, 212, 191, .14);
    color: #5eead4;
    border: 1px solid rgba(45, 212, 191, .45);
}
.hub-src-tag {
    display: inline-block;
    font-size: 9px;
    font-weight: 700;
    text-transform: uppercase;
    padding: 2px 6px;
    border-radius: 999px;
    background: #253047;
    color: #93c5fd;
    border: 1px solid rgba(147, 197, 253, .25);
}
.hub-src-tag.gs { background: rgba(110, 231, 168, .12); color: #6ee7a8; border-color: rgba(110, 231, 168, .35); }
.hub-src-tag.rb { background: rgba(251, 191, 36, .12); color: #fcd34d; border-color: rgba(251, 191, 36, .35); }
.hub-src-tag.rg { background: rgba(167, 139, 250, .12); color: #c4b5fd; border-color: rgba(167, 139, 250, .35); }

.hub-links { margin: 0 0 16px; font-size: 12px; }
.hub-links a { margin-right: 12px; font-size: 12px; text-decoration: none; }
.hub-links a:hover { text-decoration: underline; }
.hub-filter-bar {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin: 0 0 14px;
}
.hub-filter-box {
    position: relative;
    min-width: 92px;
    border-radius: 10px;
    border: 1px solid var(--border);
    background: var(--bg-card);
}
.hub-filter-box > summary {
    list-style: none;
    cursor: pointer;
    display: flex;
    flex-direction: column;
    gap: 2px;
    padding: 6px 10px 7px;
    min-height: 42px;
    box-sizing: border-box;
}
.hub-filter-box > summary::-webkit-details-marker { display: none; }
.hub-filter-box > summary::marker { content: ''; }
.hub-filter-label {
    font-size: 9px;
    letter-spacing: .06em;
    text-transform: uppercase;
    color: var(--text-muted);
    line-height: 1.1;
}
.hub-filter-value {
    font-size: 12px;
    font-weight: 700;
    color: var(--text);
    line-height: 1.15;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    max-width: 120px;
}
.hub-filter-box--source { border-color: rgba(59, 130, 246, .65); }
.hub-filter-box--date,
.hub-filter-box--stars { border-color: rgba(234, 179, 8, .65); }
.hub-filter-box--category { border-color: rgba(168, 85, 247, .65); }
.hub-filter-box--hidden { border-color: rgba(239, 68, 68, .65); }
.hub-filter-box.is-active,
.hub-filter-box[open] { box-shadow: 0 0 0 1px rgba(255, 255, 255, .04); }
.hub-filter-menu {
    position: absolute;
    top: calc(100% + 4px);
    left: 0;
    z-index: 20;
    min-width: 100%;
    max-width: 240px;
    max-height: 260px;
    overflow: auto;
    padding: 4px;
    border-radius: 8px;
    border: 1px solid var(--card-border);
    background: var(--bg-card);
    box-shadow: 0 10px 28px rgba(0, 0, 0, .45);
}
.hub-filter-menu a {
    display: block;
    padding: 6px 8px;
    border-radius: 6px;
    color: var(--text-muted);
    text-decoration: none;
    font-size: 11px;
    line-height: 1.25;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.hub-filter-menu a:hover { background: rgba(255, 255, 255, .04); color: var(--text); }
.hub-filter-menu a.active { background: var(--accent); color: #fff; font-weight: 600; }
.hub-filter-count { opacity: .7; font-size: 10px; margin-left: 4px; }
.hub-day { margin: 14px 0 6px; font-size: 13px; font-weight: 700; color: var(--text-muted); letter-spacing: .04em; }
.hub-day-count { font-weight: 500; opacity: .85; }
.hub-day-cards { margin-bottom: 4px; }
.card.hub-card-give { border-left: 3px solid rgba(110, 231, 168, .45); }
.card.hub-card-rb, .card.hub-card-randombeast { border-left: 3px solid rgba(251, 191, 36, .45); }
.card.hub-card-tscan { border-left: 3px solid rgba(244, 114, 182, .45); }

.cards { display: flex; flex-direction: column; gap: 4px; margin-top: 10px; }
.card {
    position: relative;
    background: var(--card);
    border: 1px solid var(--card-border);
    border-radius: 8px;
    min-height: 100px;
    overflow: hidden;
    transition: border-color .15s, box-shadow .15s;
}
.card.is-hidden-mode { opacity: .55; border-color: #7f1d1d; }
.card.has-textmatch { border-color: var(--textmatch-border); box-shadow: 0 0 0 1px rgba(239, 68, 68, .35); }
.card.has-city { border-color: rgba(8, 145, 178, .45); box-shadow: 0 0 0 1px rgba(8, 145, 178, .35); }
.card.has-minusword {
    background-image: linear-gradient(145deg, var(--minusword-bg-start) 0%, var(--minusword-bg-mid) 45%, var(--minusword-bg-end) 100%);
}
.card.has-desired { border-color: var(--wish-border); box-shadow: 0 0 0 1px rgba(34, 197, 94, .25); }
.card:hover, .card:has(> .card-details[open]) { border-color: var(--hover-border); box-shadow: 0 4px 20px rgba(0, 0, 0, .35); }

.card-details { display: block; }
.card-summary { list-style: none; cursor: pointer; outline: none; padding: 0; margin: 0; }
.card-summary::-webkit-details-marker { display: none; }
.card-summary::marker { content: ''; display: none; }

.card:not(.rb-card) .card-row,
.rb-card .card-row {
    display: flex;
    align-items: flex-start;
    min-height: 100px;
    gap: 8px;
    padding: 6px 8px;
    position: relative;
}
.rb-card .card-row { padding: 6px 6px 6px 8px; }

.card-thumb {
    width: 72px;
    height: 88px;
    flex-shrink: 0;
    background: var(--thumb-bg);
    border-radius: 6px;
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-top: 1px;
    position: relative;
}
.card-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}
.card-thumb.has-video::after {
    content: '▶';
    position: absolute;
    right: 4px;
    bottom: 4px;
    z-index: 2;
    width: 22px;
    height: 22px;
    border-radius: 5px;
    background: rgba(0, 0, 0, .65);
    color: #fff;
    font-size: 10px;
    line-height: 22px;
    text-align: center;
    pointer-events: none;
    box-shadow: 0 1px 4px rgba(0, 0, 0, .35);
}
.rb-card .card-thumb img { object-position: center 33%; }
.card-thumb .no-img { font-size: 9px; color: var(--text-muted); text-align: center; padding: 4px; line-height: 1.3; }

.card-main {
    flex: 1;
    min-width: 0;
    min-height: 88px;
    height: 88px;
    display: flex;
    flex-direction: column;
    box-sizing: border-box;
    padding: 1px 96px 0 0;
}
.rb-card .card-main { padding: 1px 108px 0 0; }

.card-top {
    flex-shrink: 0;
    display: flex;
    align-items: flex-start;
    gap: 6px;
    min-width: 0;
    line-height: 1.15;
}
.card-id { font-size: 10px; color: var(--muted); font-family: ui-monospace, monospace; flex-shrink: 0; }
.card-title { font-size: 13px; font-weight: 600; margin: 0; line-height: 1.15; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; flex: 1; color: var(--text); }

.card-middle {
    flex: 1;
    min-height: 0;
    overflow: hidden;
    display: flex;
    align-items: center;
    pointer-events: none;
}
.card-snippet { font-size: 11px; color: var(--snippet); width: 100%; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; line-height: 1.25; margin: 0; }

.card-actions {
    flex-shrink: 0;
    margin-top: auto;
    display: flex;
    align-items: center;
    gap: 6px;
    flex-wrap: wrap;
    padding-right: 8px;
}
.rb-card .card-actions { padding-right: 48px; }

.card-dates {
    position: absolute;
    top: 6px;
    right: 8px;
    z-index: 3;
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 2px;
    pointer-events: none;
}
.rb-card .card-dates { right: 6px; }

.card-date { font-size: 10px; background: var(--chip-bg); color: var(--chip-accent); padding: 2px 6px; border-radius: 4px; white-space: nowrap; }
.card-views, .card-members { font-size: 10px; background: var(--badge-green-bg); color: var(--badge-green-text); padding: 2px 6px; border-radius: 4px; white-space: nowrap; pointer-events: auto; }
.card-members a { color: inherit; text-decoration: none; }
.card-members a:hover { text-decoration: underline; }

.src-badge, .ch-badge, .rb-badge, .wish-badge, .textmatch-badge, .city-badge, .minusword-badge, .new-badge {
    font-size: 10px;
    padding: 2px 7px;
    border-radius: 10px;
}
.src-badge { background: var(--chip-bg); color: var(--chip-accent); }
.ch-badge { background: #1e3a5f; color: #93c5fd; }
.rb-badge-status { background: var(--bg-elevated); color: var(--text-muted); border: 1px solid var(--border); }
.wish-badge { background: rgba(234, 179, 8, .15); color: #fde68a; }
.textmatch-badge { background: var(--textmatch-bg); color: var(--textmatch-text); border: 1px solid var(--textmatch-border); }
.city-badge { background: rgba(8, 145, 178, .18); color: #a5f3fc; border: 1px solid rgba(8, 145, 178, .45); }
.minusword-badge { background: var(--minusword-tag-bg); color: var(--minusword-text); border: 1px solid var(--minusword-tag-border); }

.btn-details {
    background: var(--chip-bg);
    border: 1px solid var(--chip-border);
    color: var(--chip-accent);
    padding: 2px 8px;
    font-size: 10px;
    border-radius: 10px;
    line-height: 1.4;
    pointer-events: none;
}
.card-details[open] .btn-details { background: var(--accent); border-color: var(--accent); color: #fff; }

.btn-open-app {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(180deg, #6b93f2 0%, var(--accent) 100%);
    border: 1px solid #4a7de8;
    color: #fff !important;
    text-decoration: none;
    pointer-events: auto;
}
.btn-open-app-inline { padding: 2px 8px; font-size: 10px; border-radius: 10px; }

.card-corner-stack {
    position: absolute;
    right: 8px;
    bottom: 6px;
    z-index: 4;
    display: flex;
    align-items: center;
    gap: 5px;
    max-width: calc(100% - 16px);
    pointer-events: none;
}
.rb-card .card-corner-stack { right: 6px; }

.prize-value-badge {
    pointer-events: auto;
    display: inline-flex;
    align-items: center;
    gap: 4px;
    max-width: 140px;
    padding: 2px 7px;
    border-radius: 8px;
    font-size: 10px;
    font-weight: 700;
    line-height: 1.2;
    border: 1px solid transparent;
    box-shadow: 0 0 0 1px rgba(0, 0, 0, .25);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.prize-value-badge .prize-stars { flex-shrink: 0; letter-spacing: -0.04em; font-size: 9px; }
.prize-value-badge .prize-label { overflow: hidden; text-overflow: ellipsis; }
.prize-value-badge.prize-tier-0 { background: rgba(100, 116, 139, .22); border-color: rgba(148, 163, 184, .45); color: #cbd5e1; }
.prize-value-badge.prize-tier-1 { background: rgba(59, 130, 246, .18); border-color: rgba(96, 165, 250, .55); color: #bfdbfe; }
.prize-value-badge.prize-tier-2 { background: rgba(34, 197, 94, .16); border-color: rgba(74, 222, 128, .55); color: #bbf7d0; }
.prize-value-badge.prize-tier-3 { background: rgba(234, 179, 8, .2); border-color: rgba(250, 204, 21, .65); color: #fef08a; }
.prize-value-badge.prize-tier-4 { background: rgba(249, 115, 22, .22); border-color: rgba(251, 146, 60, .65); color: #fed7aa; }
.prize-value-badge.prize-tier-5 {
    background: linear-gradient(135deg, rgba(234, 88, 12, .35), rgba(250, 204, 21, .35));
    border-color: rgba(253, 224, 71, .85);
    color: #fff7cc;
    text-shadow: 0 0 8px rgba(250, 204, 21, .45);
}

.card-popover { border-top: 1px solid var(--card-border); background: var(--popover-bg); padding: 8px 10px; max-height: none; overflow: visible; }
.popover-lazy { font-size: 11px; color: var(--muted); padding: 2px 0; }
.popover-text { font-size: 12px; color: var(--content); margin: 0 0 6px; line-height: 1.45; word-break: break-word; }
.popover-text br { display: block; margin-bottom: 1px; content: ""; line-height: 1.1; }
.popover-text a { color: #93c5fd; }
.popover-meta-line { font-size: 10px; color: var(--muted); margin: 0 0 4px; line-height: 1.2; }
.channels-title { font-size: 10px; text-transform: uppercase; letter-spacing: .05em; color: var(--muted); margin-bottom: 6px; }
.channels-block { margin-bottom: 10px; }
.channel-rows { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 6px; }
.channel-row {
    display: flex;
    align-items: center;
    gap: 8px;
    background: var(--bg-elevated);
    border: 1px solid var(--border);
    border-radius: 8px;
    padding: 6px 8px;
}
.channel-photo {
    width: 28px;
    height: 28px;
    border-radius: 50%;
    object-fit: cover;
    flex-shrink: 0;
    background: var(--thumb-bg);
}
.channel-photo-placeholder {
    display: inline-block;
    border: 1px solid var(--border);
}
.channel-info { flex: 1; min-width: 0; }
.channel-name {
    display: block;
    color: #93c5fd;
    text-decoration: none;
    font-size: 13px;
    font-weight: 600;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
span.channel-name { color: var(--text); }
.channel-name:hover { text-decoration: underline; }
.channel-link {
    font-size: 10px;
    color: var(--muted);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    margin-top: 1px;
}
.channel-link a { color: var(--muted); text-decoration: none; }
.channel-link a:hover { color: #93c5fd; text-decoration: underline; }
.detail-preview-row {
    display: flex;
    flex-wrap: wrap;
    align-items: flex-start;
    gap: 8px;
    margin: 0 0 10px;
}
.detail-preview-photo {
    width: 72px;
    height: 88px;
    border-radius: 6px;
    object-fit: cover;
    display: block;
    background: var(--thumb-bg);
    border: 1px solid var(--border);
}
.detail-preview-video {
    width: 112px;
    height: 63px;
    border-radius: 6px;
    object-fit: cover;
    display: block;
    background: #000;
    border: 1px solid var(--border);
}
.detail-catalog-block {
    margin-top: 10px;
    padding: 8px 10px;
    border: 1px solid var(--border);
    border-radius: 8px;
    background: var(--bg-elevated);
}
.detail-catalog-title {
    font-size: 10px;
    text-transform: uppercase;
    letter-spacing: .05em;
    color: var(--muted);
    margin-bottom: 4px;
}
.detail-catalog-path {
    font-size: 11px;
    color: var(--text);
    font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
    word-break: break-word;
}
.popover-links { margin-top: 10px; }

.card-expanded-panel { font-size: 12px; color: var(--content); }
.detail-channels-title { font-size: 10px; text-transform: uppercase; letter-spacing: .05em; color: var(--muted); margin-bottom: 6px; }
.detail-channels-list { list-style: none; margin: 0 0 10px; padding: 0; }
.detail-channels-list a { color: #93c5fd; text-decoration: none; font-size: 13px; font-weight: 600; }
.detail-text-scroll { font-size: 12px; line-height: 1.45; color: var(--content); word-break: break-word; }
.detail-text-scroll a { color: #93c5fd; }
.detail-tg-link { color: var(--accent); text-decoration: none; font-weight: 600; }

.members-popover {
    position: absolute;
    z-index: 100;
    min-width: 220px;
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 10px;
    padding: 12px;
    box-shadow: 0 12px 40px rgba(0, 0, 0, .5);
}
