:root {
    --community-panel: linear-gradient(180deg, rgba(12, 12, 18, 0.96), rgba(4, 18, 15, 0.96));
    --community-border: rgba(0, 255, 159, 0.18);
    --community-text: #e8f6ff;
    --community-muted: rgba(232, 246, 255, 0.66);
    --community-green: #00ff9f;
    --community-pink: #ff00ff;
}

.community-shell {
    width: min(1480px, calc(100vw - 40px));
    margin: 0 auto;
    display: grid;
    gap: 18px;
}

.community-hero,
.community-panel,
.member-card,
.message-sidebar,
.message-thread,
.stats-grid article,
.stats-list {
    border: 1px solid var(--community-border);
    border-radius: 20px;
    background: var(--community-panel);
    box-shadow: 0 0 24px rgba(0, 255, 159, 0.08), 0 0 28px rgba(255, 0, 255, 0.06);
}

.community-hero,
.community-panel,
.message-sidebar,
.message-thread,
.stats-list {
    padding: 20px;
}

.community-headline h1,
.community-panel h1,
.community-panel h2,
.message-thread h1 {
    margin: 0;
    color: var(--community-text);
}

.community-headline p,
.community-subtle,
.member-meta,
.message-meta,
.empty-note,
.stats-list li span {
    color: var(--community-muted);
}

.community-headline {
    display: flex;
    justify-content: space-between;
    gap: 14px;
    align-items: end;
    flex-wrap: wrap;
}

.community-kpis,
.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(170px, 1fr));
    gap: 12px;
}

.community-kpis article,
.stats-grid article {
    padding: 14px;
}

.community-kpis strong,
.stats-grid strong {
    display: block;
    margin-top: 6px;
    color: var(--community-green);
    font-size: 1.45rem;
}

.member-filter-form {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(170px, 1fr));
    gap: 12px;
}

.member-filter-form label,
.message-compose label {
    display: grid;
    gap: 6px;
    color: #d6d8de;
    font-size: 0.92rem;
}

.member-filter-form input,
.member-filter-form select,
.message-compose select,
.message-compose textarea {
    width: 100%;
    min-height: 44px;
    padding: 9px 12px;
    border-radius: 12px;
    border: 1px solid rgba(255, 0, 255, 0.18);
    background: rgba(0, 0, 0, 0.45);
    color: var(--community-text);
}

.message-compose textarea {
    min-height: 110px;
    resize: vertical;
}

.message-compose-label {
    color: #d6d8de;
    font-size: 0.92rem;
}

.message-attachment-control {
    display: grid;
    gap: 8px;
}

.message-file-drop {
    position: relative;
    display: flex;
    align-items: center;
    gap: 12px;
    min-height: 76px;
    padding: 12px;
    border-radius: 18px;
    border: 1px solid rgba(0, 229, 255, 0.26);
    background:
        linear-gradient(135deg, rgba(0, 255, 159, 0.08), rgba(255, 0, 255, 0.1)),
        rgba(3, 9, 20, 0.82);
    cursor: pointer;
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.05);
    transition: border-color 160ms ease, box-shadow 160ms ease, transform 160ms ease;
}

.message-compose .message-file-drop {
    display: flex;
    gap: 12px;
}

.message-file-drop:hover {
    border-color: rgba(0, 255, 159, 0.52);
    box-shadow: 0 0 22px rgba(0, 255, 159, 0.1), inset 0 1px 0 rgba(255, 255, 255, 0.08);
}

.message-file-drop:active {
    transform: translateY(1px);
}

.message-file-input {
    position: absolute;
    inset: 0;
    opacity: 0;
    cursor: pointer;
}

.message-file-input:focus-visible ~ .message-file-drop__icon,
.message-file-input:focus-visible ~ .message-file-drop__copy {
    outline: 2px solid rgba(0, 229, 255, 0.76);
    outline-offset: 3px;
}

.message-file-drop__icon {
    width: 46px;
    height: 46px;
    flex: 0 0 46px;
    border-radius: 16px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: #050510;
    font-size: 1.6rem;
    font-weight: 900;
    background: linear-gradient(135deg, rgba(139, 92, 246, 0.98), rgba(0, 229, 255, 0.96));
    box-shadow: 0 0 18px rgba(139, 92, 246, 0.28), 0 0 18px rgba(0, 229, 255, 0.18);
}

.message-file-drop__copy {
    display: grid;
    gap: 4px;
    min-width: 0;
}

.message-file-drop__copy strong {
    color: var(--community-text);
    font-size: 1rem;
}

.message-file-drop__copy small {
    color: var(--community-muted);
    line-height: 1.35;
    overflow-wrap: anywhere;
}

.filter-actions,
.message-compose__actions,
.member-actions,
.member-tags,
.message-toolbar {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
    align-items: center;
}

.neon-button,
.ghost-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 44px;
    padding: 0 14px;
    border-radius: 999px;
    text-decoration: none;
    cursor: pointer;
}

.neon-button {
    border: 0;
    color: #050505;
    background: linear-gradient(135deg, var(--community-pink), var(--community-green));
    font-weight: 800;
}

.ghost-button {
    border: 1px solid rgba(0, 255, 159, 0.22);
    color: var(--community-text);
    background: rgba(255, 255, 255, 0.02);
}

.ghost-button--danger {
    border-color: rgba(255, 69, 130, 0.42);
    color: #ffd7e7;
    background: rgba(255, 69, 130, 0.08);
}

.message-safety-actions {
    display: inline-flex;
    gap: 8px;
    flex-wrap: wrap;
    align-items: center;
}

.message-safety-action {
    min-height: 38px;
    padding-inline: 12px;
}

.message-safety-status {
    min-height: 20px;
    color: var(--community-muted);
    font-size: 0.82rem;
    overflow-wrap: anywhere;
}

.message-safety-status[data-tone="success"] {
    color: var(--community-green);
}

.message-safety-status[data-tone="warning"],
.message-safety-status[data-tone="error"] {
    color: #ff8fb8;
}

.members-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 14px;
}

.member-card {
    padding: 16px;
    display: grid;
    gap: 10px;
}

.member-card__banner {
    display: block;
    width: 100%;
    height: 96px;
    border-radius: 14px;
    overflow: hidden;
    border: 1px solid rgba(0, 255, 159, 0.18);
    background: rgba(0, 0, 0, 0.42);
}

.member-card .member-card__banner img {
    width: 100%;
    height: 100%;
    border: 0;
    border-radius: inherit;
    object-fit: cover;
}

.member-card__top,
.contact-card,
.message-row {
    display: flex;
    gap: 10px;
    align-items: flex-start;
}

.member-card img,
.contact-card img,
.message-row img,
.stats-user img {
    width: 48px;
    height: 48px;
    border-radius: 14px;
    object-fit: cover;
    border: 1px solid rgba(0, 255, 159, 0.22);
}

.member-card .member-avatar-button img {
    width: 56px;
    height: 56px;
    border-radius: 16px;
}

.member-card h3 {
    margin: 0;
    font-size: 1rem;
}

.member-card-link {
    min-height: 44px;
    background: none;
    border: 0;
    padding: 0 8px;
    margin: 0;
    font: inherit;
    color: inherit;
    cursor: pointer;
    text-align: left;
    display: inline-flex;
    align-items: center;
}

.presence-dot {
    width: 9px;
    height: 9px;
    border-radius: 999px;
    display: inline-block;
    margin-right: 6px;
    box-shadow: 0 0 14px currentColor;
}

.presence-dot--online {
    color: var(--community-green);
    background: var(--community-green);
}

.presence-dot--offline {
    color: #6d7385;
    background: #6d7385;
}

.member-tag,
.pill {
    display: inline-flex;
    align-items: center;
    padding: 5px 9px;
    border-radius: 999px;
    background: rgba(255, 0, 255, 0.08);
    border: 1px solid rgba(255, 0, 255, 0.14);
    font-size: 0.8rem;
}

.messages-layout {
    display: grid;
    grid-template-columns: minmax(292px, 360px) minmax(0, 1fr);
    gap: 16px;
    align-items: stretch;
}

.message-sidebar {
    display: grid;
    gap: 14px;
    align-content: start;
}

.mailbox-tabs {
    display: grid;
    gap: 8px;
}

.mailbox-tab {
    justify-content: space-between;
    width: 100%;
    font-weight: 700;
}

.mailbox-tab.is-active {
    border-color: rgba(255, 0, 255, 0.3);
    box-shadow: inset 0 0 0 1px rgba(255, 0, 255, 0.2);
}

.mailbox-tab__count {
    min-width: 22px;
    height: 22px;
    padding: 0 7px;
    border-radius: 999px;
    background: rgba(0, 255, 159, 0.16);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 0.8rem;
}

.mailbox-filters {
    display: grid;
    gap: 8px;
}

.mailbox-filters label {
    display: grid;
    gap: 6px;
    color: #d6d8de;
    font-size: 0.92rem;
}

.mailbox-filters__toggle {
    position: relative;
    display: inline-flex;
    align-items: center;
    grid-template-columns: none;
    gap: 10px;
    min-height: 58px;
    padding: 10px 12px;
    border-radius: 16px;
    border: 1px solid rgba(0, 229, 255, 0.2);
    background:
        linear-gradient(135deg, rgba(0, 229, 255, 0.08), rgba(255, 0, 255, 0.08)),
        rgba(4, 8, 18, 0.82);
    color: #d6d8de;
    cursor: pointer;
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.05);
    transition: border-color 160ms ease, box-shadow 160ms ease, background 160ms ease;
}

.mailbox-filters .mailbox-filters__toggle {
    display: flex;
    gap: 10px;
}

.mailbox-filters__toggle:hover,
.mailbox-filters__toggle.is-active {
    border-color: rgba(0, 255, 159, 0.48);
    box-shadow: 0 0 18px rgba(0, 255, 159, 0.1), inset 0 1px 0 rgba(255, 255, 255, 0.08);
}

.mailbox-filters__toggle-input {
    position: absolute;
    width: 1px;
    height: 1px;
    opacity: 0;
    pointer-events: none;
}

.mailbox-filters__toggle-track {
    position: relative;
    flex: 0 0 46px;
    width: 46px;
    height: 26px;
    border-radius: 999px;
    border: 1px solid rgba(255, 255, 255, 0.16);
    background: rgba(8, 12, 24, 0.9);
    box-shadow: inset 0 0 10px rgba(0, 0, 0, 0.48);
}

.mailbox-filters__toggle-knob {
    position: absolute;
    top: 3px;
    left: 3px;
    width: 18px;
    height: 18px;
    border-radius: 999px;
    background: rgba(183, 195, 216, 0.9);
    box-shadow: 0 0 10px rgba(183, 195, 216, 0.2);
    transition: transform 180ms ease, background 180ms ease, box-shadow 180ms ease;
}

.mailbox-filters__toggle-input:checked + .mailbox-filters__toggle-track {
    border-color: rgba(0, 255, 159, 0.62);
    background: linear-gradient(135deg, rgba(0, 255, 159, 0.34), rgba(255, 0, 255, 0.22));
}

.mailbox-filters__toggle-input:checked + .mailbox-filters__toggle-track .mailbox-filters__toggle-knob {
    transform: translateX(20px);
    background: #fff;
    box-shadow: 0 0 14px rgba(0, 255, 159, 0.52);
}

.mailbox-filters__toggle-input:focus-visible + .mailbox-filters__toggle-track {
    outline: 2px solid rgba(0, 229, 255, 0.8);
    outline-offset: 3px;
}

.mailbox-filters__toggle-copy {
    display: grid;
    gap: 2px;
    min-width: 0;
}

.mailbox-filters__toggle-copy strong {
    color: var(--community-text);
    line-height: 1.1;
}

.mailbox-filters__toggle-copy small {
    color: var(--community-muted);
    font-size: 0.74rem;
    line-height: 1.25;
}

.mailbox-filters select {
    width: 100%;
    min-height: 42px;
    padding: 9px 12px;
    border-radius: 12px;
    border: 1px solid rgba(0, 255, 159, 0.24);
    background:
        linear-gradient(120deg, rgba(255, 0, 255, 0.08), rgba(0, 255, 159, 0.07)),
        rgba(0, 0, 0, 0.5);
    color: var(--community-text);
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.06);
}

.mailbox-filters select:hover {
    border-color: rgba(0, 255, 159, 0.46);
}

.mailbox-filters select:focus-visible {
    outline: 2px solid rgba(0, 255, 159, 0.72);
    outline-offset: 2px;
}

.contact-list,
.thread-list,
.stats-list ul {
    display: grid;
    gap: 8px;
}

.contact-card {
    padding: 10px;
    border-radius: 14px;
    text-decoration: none;
    color: inherit;
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid transparent;
}

.contact-card[data-active="true"] {
    border-color: rgba(255, 0, 255, 0.24);
    background: rgba(255, 0, 255, 0.08);
}

.contact-unread {
    min-width: 22px;
    height: 22px;
    padding: 0 7px;
    border-radius: 999px;
    background: rgba(255, 0, 255, 0.18);
    color: #fff;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 0.8rem;
}

.message-thread {
    display: grid;
    gap: 14px;
}

.thread-list {
    max-height: 420px;
    overflow: auto;
    padding-right: 4px;
}

.message-row {
    padding: 10px;
    border-radius: 14px;
    background: rgba(255, 255, 255, 0.02);
}

.message-row--mine {
    border: 1px solid rgba(0, 255, 159, 0.2);
}

.message-row--theirs {
    border: 1px solid rgba(255, 0, 255, 0.18);
}

.message-bubble {
    display: grid;
    gap: 6px;
}

.message-body {
    line-height: 1.55;
    white-space: pre-wrap;
}

.message-attachment {
    display: inline-flex;
    max-width: min(320px, 70vw);
    border-radius: 10px;
    overflow: hidden;
    border: 1px solid rgba(255, 0, 255, 0.2);
}

.message-attachment img {
    display: block;
    width: 100%;
    height: auto;
    object-fit: cover;
}

.message-attachment-preview {
    display: grid;
    grid-template-columns: 96px minmax(0, 1fr) auto;
    gap: 12px;
    align-items: center;
    min-height: 112px;
    padding: 10px;
    border-radius: 18px;
    border: 1px solid rgba(0, 255, 159, 0.26);
    background:
        linear-gradient(135deg, rgba(0, 229, 255, 0.12), rgba(255, 0, 255, 0.1)),
        rgba(3, 9, 20, 0.86);
}

.message-attachment-preview[hidden] {
    display: none !important;
}

.message-attachment-preview__frame {
    width: 96px;
    aspect-ratio: 1;
    border-radius: 16px;
    overflow: hidden;
    border: 1px solid rgba(0, 255, 159, 0.28);
    background: rgba(0, 0, 0, 0.4);
}

.message-attachment-preview img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.message-attachment-preview__meta {
    display: grid;
    gap: 3px;
    min-width: 0;
}

.message-attachment-preview__meta strong,
.message-attachment-preview__meta span {
    overflow-wrap: anywhere;
}

.message-attachment-preview__meta span {
    color: var(--community-muted);
    font-size: 0.82rem;
}

.message-attachment-preview.is-error {
    border-color: rgba(255, 90, 120, 0.46);
}

.message-attachment-preview.is-error .message-attachment-preview__frame {
    display: none;
}

.message-attachment-preview__remove {
    white-space: nowrap;
}

.message-archive-toggle {
    margin-left: auto;
}

.stats-list ul {
    list-style: none;
    margin: 0;
    padding: 0;
}

.stats-list li,
.stats-user {
    display: flex;
    justify-content: space-between;
    gap: 10px;
    align-items: center;
    padding: 10px 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}

.stats-list li:last-child,
.stats-user:last-child {
    border-bottom: 0;
}

.stats-user {
    justify-content: flex-start;
}

.stats-user__meta {
    display: grid;
    gap: 4px;
}

/* ===== Stats Refresh ===== */
.stats-shell {
    position: relative;
}

.stats-shell::before {
    content: "";
    position: absolute;
    inset: 0;
    border-radius: 24px;
    pointer-events: none;
    background:
        radial-gradient(540px circle at 14% 8%, rgba(255, 0, 255, 0.13), transparent 62%),
        radial-gradient(640px circle at 88% 12%, rgba(0, 255, 159, 0.1), transparent 62%);
    opacity: 0.75;
}

.stats-shell > * {
    position: relative;
    z-index: 1;
}

.stats-hero {
    display: grid;
    gap: 16px;
}

.stats-headline {
    align-items: center;
}

.stats-range-badge {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 8px 14px;
    border-radius: 999px;
    border: 1px solid rgba(255, 0, 255, 0.32);
    background: rgba(255, 0, 255, 0.1);
    color: var(--community-text);
    font-weight: 700;
    letter-spacing: 0.02em;
    box-shadow: 0 0 14px rgba(255, 0, 255, 0.2);
}

.stats-range-form {
    display: flex;
    flex-wrap: wrap;
    align-items: end;
    gap: 12px;
}

.stats-range-form label {
    display: grid;
    gap: 6px;
    color: #d6d8de;
    font-size: 0.92rem;
    min-width: 190px;
}

.stats-range-form select,
.stats-range-form input[type="date"] {
    width: 100%;
    min-height: 42px;
    padding: 9px 12px;
    border-radius: 12px;
    border: 1px solid rgba(255, 0, 255, 0.3);
    background: rgba(0, 0, 0, 0.5);
    color: var(--community-text);
}

.stats-range-form select:hover,
.stats-range-form input[type="date"]:hover {
    border-color: rgba(0, 255, 159, 0.45);
}

.stats-range-form select:focus-visible,
.stats-range-form input[type="date"]:focus-visible {
    outline: 2px solid rgba(0, 255, 159, 0.75);
    outline-offset: 2px;
}

.stats-custom-range {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.stats-custom-range[hidden] {
    display: none !important;
}

.stats-custom-range label {
    min-width: 160px;
}

.stats-filter-submit {
    min-height: 42px;
    padding: 0 18px;
}

.stats-segment-switch {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.stats-segment-link {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 40px;
    padding: 0 14px;
    border-radius: 999px;
    text-decoration: none;
    border: 1px solid rgba(0, 255, 159, 0.24);
    background: rgba(255, 255, 255, 0.02);
    color: var(--community-text);
    font-weight: 700;
    transition: border-color 0.2s ease, box-shadow 0.2s ease, transform 0.2s ease;
}

.stats-segment-link:hover {
    border-color: rgba(0, 255, 159, 0.5);
    box-shadow: 0 0 16px rgba(0, 255, 159, 0.15);
    transform: translateY(-1px);
}

.stats-segment-link.is-active {
    border-color: rgba(255, 0, 255, 0.42);
    background: rgba(255, 0, 255, 0.1);
    box-shadow: 0 0 18px rgba(255, 0, 255, 0.2);
}

.stats-grid--overview article {
    backdrop-filter: blur(6px);
    -webkit-backdrop-filter: blur(6px);
}

.stats-segment-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 14px;
}

.stats-segment-card {
    border: 1px solid var(--community-border);
    border-radius: 20px;
    background: var(--community-panel);
    box-shadow: 0 0 24px rgba(0, 255, 159, 0.08), 0 0 28px rgba(255, 0, 255, 0.06);
    padding: 20px;
    display: grid;
    gap: 10px;
}

.stats-segment-card header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 10px;
}

.stats-segment-card h2 {
    margin: 0;
    color: var(--community-text);
    font-size: 1.28rem;
}

.stats-score {
    min-width: 64px;
    height: 40px;
    padding: 0 12px;
    border-radius: 999px;
    border: 1px solid rgba(0, 255, 159, 0.5);
    background: rgba(0, 255, 159, 0.12);
    color: var(--community-green);
    font-size: 1.08rem;
    font-weight: 800;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    text-shadow: 0 0 12px rgba(0, 255, 159, 0.25);
}

.stats-segment-card ul {
    list-style: none;
    margin: 0;
    padding: 0;
    display: grid;
    gap: 8px;
}

.stats-segment-card li {
    display: flex;
    justify-content: space-between;
    gap: 10px;
    align-items: center;
    padding: 8px 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}

.stats-segment-card li:last-child {
    border-bottom: 0;
}

.stats-segment-card li span {
    color: var(--community-muted);
}

.stats-rank-card {
    display: grid;
    gap: 12px;
}

.stats-rank-card h2 {
    margin: 0;
    color: var(--community-text);
}

.stats-rank-value {
    width: fit-content;
    min-width: 86px;
    height: 48px;
    padding: 0 16px;
    border-radius: 14px;
    border: 1px solid rgba(255, 0, 255, 0.5);
    background: linear-gradient(120deg, rgba(255, 0, 255, 0.18), rgba(0, 255, 159, 0.14));
    color: var(--community-text);
    font-size: 1.42rem;
    font-weight: 900;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 0 20px rgba(255, 0, 255, 0.18), 0 0 18px rgba(0, 255, 159, 0.16);
}

.stats-lists-two {
    grid-template-columns: repeat(2, minmax(0, 1fr));
}

.stats-shell .stats-list h3 {
    margin: 16px 0 8px;
    color: var(--community-text);
}

.stats-shell .stats-list li strong {
    color: var(--community-green);
}

.stats-segment-focus {
    border: 1px solid var(--community-border);
    border-radius: 20px;
    background: var(--community-panel);
    box-shadow: 0 0 24px rgba(0, 255, 159, 0.08), 0 0 28px rgba(255, 0, 255, 0.06);
    padding: 20px;
    display: grid;
    gap: 12px;
}

.stats-segment-focus__header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 12px;
}

.stats-segment-focus__header h2 {
    margin: 0;
    color: var(--community-text);
}

.stats-segment-focus__grid {
    display: grid;
    grid-template-columns: minmax(260px, 1fr) minmax(300px, 1.15fr);
    gap: 16px;
}

.stats-segment-focus__list {
    list-style: none;
    margin: 0;
    padding: 0;
    display: grid;
    gap: 8px;
}

.stats-segment-focus__list li {
    display: flex;
    justify-content: space-between;
    gap: 10px;
    align-items: center;
    padding: 9px 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}

.stats-segment-focus__list li:last-child {
    border-bottom: 0;
}

.stats-segment-focus__list li span {
    color: var(--community-muted);
}

.stats-mini-chart {
    display: grid;
    gap: 10px;
}

.stats-mini-chart__row {
    display: grid;
    gap: 6px;
}

.stats-mini-chart__labels {
    display: flex;
    justify-content: space-between;
    gap: 10px;
    align-items: center;
}

.stats-mini-chart__labels span {
    color: var(--community-muted);
}

.stats-mini-chart__labels strong {
    color: var(--community-green);
}

.stats-mini-chart__track {
    width: 100%;
    height: 12px;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.06);
    overflow: hidden;
    border: 1px solid rgba(255, 0, 255, 0.16);
}

.stats-mini-chart__track span {
    display: block;
    height: 100%;
    border-radius: 999px;
    background: linear-gradient(90deg, rgba(255, 0, 255, 0.88), rgba(0, 255, 159, 0.95));
    box-shadow: 0 0 12px rgba(0, 255, 159, 0.2), 0 0 14px rgba(255, 0, 255, 0.18);
}

.scraper-bridge-panel {
    display: grid;
    gap: 12px;
}

.scraper-bridge-header {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    gap: 10px;
    align-items: center;
}

.scraper-bridge-header h2 {
    margin: 0;
}

.scraper-bridge-chips {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.scraper-chip {
    appearance: none;
    background: rgba(8, 13, 26, 0.72);
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 7px;
    min-height: 36px;
    padding: 6px 10px;
    border-radius: 999px;
    border: 1px solid rgba(255, 255, 255, 0.16);
    color: rgba(232, 246, 255, 0.74);
    font: inherit;
    font-size: 0.76rem;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    transition: border-color 160ms ease, color 160ms ease, background 160ms ease, box-shadow 160ms ease, transform 160ms ease;
}

.scraper-chip::before {
    content: "";
    width: 7px;
    height: 7px;
    flex: 0 0 7px;
    border-radius: 999px;
    background: rgba(183, 195, 216, 0.58);
    box-shadow: 0 0 10px rgba(183, 195, 216, 0.16);
}

.scraper-chip:hover {
    border-color: rgba(0, 229, 255, 0.42);
    color: rgba(255, 255, 255, 0.92);
    background: rgba(15, 30, 56, 0.88);
}

.scraper-chip:active {
    transform: translateY(1px);
}

.scraper-chip:focus-visible {
    outline: 2px solid rgba(0, 229, 255, 0.78);
    outline-offset: 3px;
}

.scraper-chip.is-active {
    border-color: rgba(0, 255, 159, 0.58);
    color: #04150f;
    background: linear-gradient(120deg, rgba(0, 255, 159, 0.94), rgba(255, 0, 255, 0.86));
    box-shadow: 0 0 16px rgba(0, 255, 159, 0.2), 0 0 14px rgba(255, 0, 255, 0.2);
}

.scraper-chip.is-active::before {
    background: rgba(4, 21, 15, 0.74);
    box-shadow: 0 0 10px rgba(4, 21, 15, 0.22);
}

.scraper-chip.is-selected {
    border-color: rgba(0, 229, 255, 0.8);
    color: #fff;
    box-shadow: 0 0 0 2px rgba(0, 229, 255, 0.18), 0 0 18px rgba(0, 229, 255, 0.18);
}

.scraper-chip.is-active.is-selected {
    color: #04150f;
    box-shadow: 0 0 0 2px rgba(0, 229, 255, 0.22), 0 0 18px rgba(0, 255, 159, 0.22), 0 0 18px rgba(255, 0, 255, 0.18);
}

.scraper-bridge-config {
    list-style: none;
    margin: 0;
    padding: 0;
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 8px;
}

.scraper-bridge-config li {
    display: flex;
    justify-content: space-between;
    gap: 8px;
    border: 1px solid rgba(255, 0, 255, 0.16);
    border-radius: 12px;
    padding: 9px 10px;
    background: rgba(0, 0, 0, 0.38);
}

.scraper-bridge-config li span {
    color: var(--community-muted);
    font-size: 0.83rem;
}

.scraper-bridge-config li strong {
    color: var(--community-green);
}

.scraper-bridge-table-wrap {
    overflow-x: auto;
}

.scraper-bridge-table {
    width: 100%;
    border-collapse: collapse;
    min-width: 760px;
}

.scraper-bridge-table th,
.scraper-bridge-table td {
    text-align: left;
    padding: 8px 10px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
    white-space: nowrap;
}

.scraper-bridge-table th {
    color: rgba(232, 246, 255, 0.82);
    font-size: 0.8rem;
    letter-spacing: 0.05em;
    text-transform: uppercase;
}

.scraper-bridge-row.is-hidden {
    display: none;
}

.scraper-status-pill {
    display: inline-flex;
    align-items: center;
    min-height: 26px;
    padding: 4px 9px;
    border-radius: 999px;
    border: 1px solid rgba(255, 255, 255, 0.12);
    background: rgba(255, 255, 255, 0.06);
    color: rgba(232, 246, 255, 0.84);
    font-size: 0.78rem;
    letter-spacing: 0.04em;
    text-transform: uppercase;
}

.scraper-status-pill--aktiv,
.scraper-status-pill--bereit {
    border-color: rgba(0, 255, 159, 0.38);
    color: rgba(181, 255, 224, 0.94);
    background: rgba(0, 255, 159, 0.1);
}

.scraper-status-pill--eingeschrankt {
    border-color: rgba(255, 209, 102, 0.42);
    color: rgba(255, 224, 148, 0.96);
    background: rgba(255, 209, 102, 0.11);
}

.scraper-status-pill--offline {
    border-color: rgba(255, 90, 120, 0.38);
    color: rgba(255, 180, 195, 0.94);
    background: rgba(255, 90, 120, 0.1);
}

.scraper-bridge-filter-empty td {
    white-space: normal;
}

@media (max-width: 960px) {
    .community-shell {
        width: min(100%, calc(100vw - 22px));
    }

    .members-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .member-filter-form {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .messages-layout {
        grid-template-columns: 1fr;
    }

    .messages-layout .message-sidebar {
        position: static;
        max-height: none;
    }

    .stats-segment-grid {
        grid-template-columns: 1fr;
    }

    .stats-lists-two {
        grid-template-columns: 1fr;
    }

    .stats-segment-focus__grid {
        grid-template-columns: 1fr;
    }

    .scraper-bridge-config {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 560px) {
    .community-shell {
        width: 100%;
        gap: 10px;
    }

    .community-hero,
    .community-panel,
    .member-card,
    .message-sidebar,
    .message-thread,
    .stats-list {
        padding: 12px;
        border-radius: 14px;
    }

    .members-grid,
    .stats-grid {
        grid-template-columns: 1fr;
        gap: 8px;
    }

    .member-filter-form {
        grid-template-columns: 1fr;
    }

    .mailbox-filters__toggle,
    .message-file-drop {
        min-height: 64px;
    }

    .message-attachment-preview {
        grid-template-columns: 72px minmax(0, 1fr);
    }

    .message-attachment-preview__frame {
        width: 72px;
        border-radius: 14px;
    }

    .message-attachment-preview__remove {
        grid-column: 1 / -1;
        width: 100%;
    }

    .filter-actions,
    .member-actions,
    .message-compose__actions,
    .message-safety-actions {
        display: grid;
        grid-template-columns: 1fr;
    }

    .filter-actions .neon-button,
    .filter-actions .ghost-button,
    .member-actions .neon-button,
    .member-actions .ghost-button,
    .message-compose__actions .neon-button,
    .message-compose__actions .ghost-button,
    .message-safety-actions .ghost-button {
        width: 100%;
    }

    .message-toolbar {
        align-items: stretch;
    }

    .message-safety-status {
        width: 100%;
    }

    .member-card img,
    .contact-card img,
    .message-row img,
    .stats-user img {
        width: 40px;
        height: 40px;
        border-radius: 11px;
    }

    .stats-range-form {
        display: grid;
        grid-template-columns: 1fr;
    }

    .stats-range-form label,
    .stats-custom-range label {
        min-width: 0;
    }

    .stats-custom-range {
        display: grid;
        grid-template-columns: 1fr;
    }

    .stats-range-badge {
        width: 100%;
        justify-content: center;
    }

    .stats-segment-switch {
        display: grid;
        grid-template-columns: 1fr;
    }

    .stats-segment-link {
        width: 100%;
    }

    .scraper-bridge-config {
        grid-template-columns: 1fr;
    }

    .scraper-bridge-header {
        align-items: stretch;
    }

    .scraper-bridge-chips {
        flex-wrap: nowrap;
        width: 100%;
        overflow-x: auto;
        padding: 2px 2px 6px;
        scroll-snap-type: x proximity;
        -webkit-overflow-scrolling: touch;
    }

    .scraper-chip {
        flex: 0 0 auto;
        min-height: 44px;
        padding-inline: 12px;
        scroll-snap-align: start;
    }
}

/* ShadowSeek app-shell polish */
.community-shell {
    background:
        radial-gradient(circle at 14% 0%, rgba(160, 32, 255, 0.13), transparent 35%),
        radial-gradient(circle at 86% 100%, rgba(0, 255, 156, 0.08), transparent 36%);
}

.community-hero h1,
.message-thread h2,
.stats-list h2 {
    letter-spacing: 0.03em;
}

.members-grid .member-card {
    position: relative;
    overflow: hidden;
}

.members-grid .member-card::before {
    content: "MITGLIEDER-VERZEICHNIS";
    position: absolute;
    top: 10px;
    right: 10px;
    font-family: var(--ss-mono-font);
    font-size: 0.6rem;
    letter-spacing: 0.1em;
    color: rgba(183, 195, 216, 0.64);
    z-index: 2;
}

.members-grid .member-card > * {
    position: relative;
    z-index: 1;
}

.community-ad-slot .ad-slot__fallback {
    min-height: 0;
    align-content: stretch;
}

.community-ad-slot .ad-slot__catalog-grid {
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
}

.community-ad-slot .ad-slot__catalog-card img {
    aspect-ratio: 16 / 7;
}

.member-actions .neon-button,
.member-actions .ghost-button,
.message-compose__actions .neon-button,
.message-compose__actions .ghost-button {
    min-height: 44px;
}

.messages-layout .message-sidebar,
.messages-layout .message-thread {
    background:
        radial-gradient(circle at 12% 0%, rgba(0, 229, 255, 0.11), transparent 34%),
        linear-gradient(160deg, rgba(115, 58, 190, 0.09), rgba(0, 229, 255, 0.04) 44%, rgba(5, 8, 16, 0.96)),
        rgba(8, 12, 22, 0.94);
    border-color: rgba(97, 232, 255, 0.18);
    box-shadow: 0 18px 42px rgba(0, 0, 0, 0.34), 0 0 0 1px rgba(255, 255, 255, 0.02);
}

.message-thread::before {
    display: none;
}

.message-row--mine .message-bubble {
    border-color: rgba(160, 32, 255, 0.52);
    background: rgba(160, 32, 255, 0.12);
}

.message-row--theirs .message-bubble {
    border-color: rgba(0, 255, 156, 0.34);
    background: rgba(0, 255, 156, 0.08);
}

.messages-shell {
    --message-card-bg: rgba(4, 8, 18, 0.76);
    --message-soft-border: rgba(97, 232, 255, 0.2);
    --message-hot-border: rgba(255, 80, 228, 0.28);
    --message-surface: rgba(3, 7, 18, 0.78);
    --message-surface-strong: rgba(5, 9, 22, 0.92);
}

.messages-hero {
    overflow: hidden;
    background:
        radial-gradient(circle at 8% 0%, rgba(255, 0, 255, 0.22), transparent 34%),
        radial-gradient(circle at 96% 0%, rgba(0, 229, 255, 0.18), transparent 32%),
        linear-gradient(145deg, rgba(7, 10, 22, 0.96), rgba(2, 14, 14, 0.94));
}

.messages-eyebrow {
    display: inline-flex;
    margin-bottom: 8px;
    padding: 5px 10px;
    border-radius: 999px;
    border: 1px solid rgba(0, 255, 159, 0.34);
    color: rgba(170, 255, 224, 0.96);
    font-family: var(--ss-mono-font);
    font-size: 0.72rem;
    text-transform: uppercase;
    letter-spacing: 0.1em;
}

.messages-hero__actions,
.messages-feature-strip,
.contact-card__topline,
.contact-card__badges,
.message-room-panel__head {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
}

.messages-status-chip {
    min-height: 34px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 7px 12px;
    border-radius: 999px;
    border: 1px solid rgba(0, 229, 255, 0.32);
    color: rgba(224, 244, 255, 0.96);
    background: rgba(0, 229, 255, 0.08);
    font-weight: 800;
}

.messages-status-chip--secure {
    border-color: rgba(0, 255, 159, 0.34);
    background: rgba(0, 255, 159, 0.1);
}

.messages-feature-strip {
    margin-top: 16px;
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
}

.messages-feature-strip article {
    min-height: 92px;
    padding: 14px;
    border-radius: 16px;
    border: 1px solid rgba(0, 229, 255, 0.18);
    background: rgba(1, 7, 16, 0.58);
}

.messages-feature-strip strong,
.messages-feature-strip span {
    display: block;
}

.messages-feature-strip strong {
    color: var(--community-text);
    margin-bottom: 5px;
}

.messages-feature-strip span {
    color: var(--community-muted);
    line-height: 1.35;
}

.message-sidebar__header {
    display: flex;
    justify-content: space-between;
    gap: 10px;
}

.messages-layout .message-sidebar {
    position: sticky;
    top: 82px;
    max-height: calc(100vh - 104px);
    overflow: auto;
    scrollbar-color: rgba(97, 232, 255, 0.42) rgba(255, 255, 255, 0.06);
}

.message-sidebar__header h2,
.message-room-panel h2,
.message-compose h2 {
    margin: 0;
    letter-spacing: 0;
}

.message-sidebar__header h2,
.message-room-panel h2 {
    font-size: 1.18rem;
}

.message-search {
    display: grid;
    gap: 6px;
    color: #d6d8de;
    font-size: 0.92rem;
}

.message-search input,
.message-room-create input,
.message-room-create select,
.message-e2ee-panel input {
    width: 100%;
    min-height: 44px;
    padding: 10px 12px;
    border-radius: 14px;
    border: 1px solid rgba(0, 229, 255, 0.22);
    background: rgba(0, 0, 0, 0.45);
    color: var(--community-text);
}

.contact-card {
    transition: border-color 160ms ease, transform 160ms ease, background 160ms ease;
}

.mailbox-tab,
.contact-card,
.message-room-card {
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.04);
}

.mailbox-tab.is-active,
.contact-card[data-active="true"] {
    background:
        linear-gradient(135deg, rgba(255, 80, 228, 0.14), rgba(0, 229, 255, 0.06)),
        rgba(7, 11, 24, 0.86);
}

.contact-card:hover,
.message-room-card:hover {
    transform: translateY(-1px);
    border-color: rgba(0, 255, 159, 0.34);
}

.contact-card__content {
    display: grid;
    gap: 4px;
    flex: 1;
    min-width: 0;
}

.contact-card__topline {
    justify-content: space-between;
}

.contact-card__topline strong,
.message-room-card__title {
    overflow-wrap: anywhere;
}

.contact-card__badges span {
    display: inline-flex;
    min-height: 22px;
    align-items: center;
    padding: 3px 7px;
    border-radius: 999px;
    border: 1px solid rgba(0, 255, 159, 0.22);
    color: rgba(187, 255, 228, 0.92);
    background: rgba(0, 255, 159, 0.08);
    font-size: 0.72rem;
    font-weight: 800;
}

.message-room-panel {
    display: grid;
    gap: 12px;
    padding-top: 14px;
    border-top: 1px solid rgba(255, 255, 255, 0.08);
}

.message-room-panel__head {
    justify-content: space-between;
}

.message-room-panel__head > div {
    display: grid;
    gap: 5px;
}

.message-room-panel__eyebrow {
    width: fit-content;
    padding: 4px 8px;
    border-radius: 999px;
    border: 1px solid rgba(97, 232, 255, 0.24);
    color: rgba(183, 239, 255, 0.9);
    background: rgba(97, 232, 255, 0.07);
    font-family: var(--ss-mono-font);
    font-size: 0.65rem;
    text-transform: uppercase;
}

.message-room-list {
    display: grid;
    gap: 8px;
}

.message-room-card {
    width: 100%;
    display: grid;
    gap: 4px;
    padding: 13px;
    border-radius: 14px;
    border: 1px solid var(--message-soft-border);
    background:
        linear-gradient(145deg, rgba(0, 229, 255, 0.05), rgba(255, 80, 228, 0.035)),
        rgba(4, 10, 22, 0.78);
    color: var(--community-text);
    text-align: left;
    cursor: pointer;
    transition: border-color 160ms ease, transform 160ms ease, background 160ms ease;
}

.message-room-card[data-active="true"] {
    border-color: rgba(255, 80, 228, 0.46);
    background:
        linear-gradient(135deg, rgba(255, 80, 228, 0.18), rgba(0, 229, 255, 0.07)),
        rgba(12, 10, 28, 0.9);
    box-shadow: 0 0 0 1px rgba(255, 80, 228, 0.08), 0 14px 24px rgba(0, 0, 0, 0.2);
}

.message-room-card__meta,
.message-room-card__preview {
    color: var(--community-muted);
    font-size: 0.82rem;
    overflow-wrap: anywhere;
}

.message-room-create {
    display: grid;
    gap: 10px;
    padding: 12px;
    border-radius: 16px;
    border: 1px solid rgba(97, 232, 255, 0.16);
    background: rgba(0, 0, 0, 0.22);
}

.message-room-create__header,
.message-room-member-picker__topline {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
}

.message-room-create__header strong,
.message-room-member-picker__topline span,
.message-room-field span {
    color: var(--community-text);
    font-size: 0.9rem;
    font-weight: 800;
}

.message-room-create__header span {
    flex: 0 0 auto;
    padding: 4px 8px;
    border-radius: 999px;
    border: 1px solid rgba(255, 255, 255, 0.12);
    color: var(--community-muted);
    background: rgba(255, 255, 255, 0.04);
    font-size: 0.74rem;
}

.message-room-create__header span[data-active="true"] {
    border-color: rgba(0, 255, 159, 0.34);
    color: rgba(190, 255, 229, 0.96);
    background: rgba(0, 255, 159, 0.08);
}

.message-room-field,
.message-room-member-picker {
    display: grid;
    gap: 7px;
}

.message-room-member-picker__topline small {
    color: var(--community-muted);
    font-size: 0.72rem;
}

.message-room-member-picker select {
    min-height: 118px;
    padding: 7px;
    border-radius: 14px;
    border-color: rgba(97, 232, 255, 0.24);
    background:
        linear-gradient(180deg, rgba(9, 16, 34, 0.92), rgba(3, 5, 14, 0.96));
}

.message-room-member-picker option {
    margin: 2px 0;
    padding: 8px 9px;
    border-radius: 10px;
}

.message-room-member-picker option:checked {
    color: #ffffff;
    background: linear-gradient(135deg, rgba(255, 80, 228, 0.6), rgba(0, 229, 255, 0.34));
}

.message-room-create__button {
    width: 100%;
    border-color: rgba(255, 80, 228, 0.34);
    background:
        linear-gradient(135deg, rgba(255, 80, 228, 0.12), rgba(0, 229, 255, 0.08)),
        rgba(255, 255, 255, 0.03);
    font-weight: 800;
}

.message-thread {
    grid-template-rows: auto minmax(360px, 1fr) auto;
    min-height: 680px;
}

.message-toolbar {
    position: sticky;
    top: 0;
    z-index: 3;
    padding: 12px;
    border-radius: 16px;
    border: 1px solid rgba(97, 232, 255, 0.18);
    background:
        linear-gradient(135deg, rgba(0, 229, 255, 0.08), rgba(255, 80, 228, 0.06)),
        rgba(3, 7, 16, 0.9);
    backdrop-filter: blur(14px);
}

.message-toolbar .pill {
    border-color: rgba(97, 232, 255, 0.2);
    background: rgba(8, 14, 30, 0.72);
    color: rgba(232, 246, 255, 0.94);
    font-weight: 800;
}

.message-typing-indicator {
    min-width: 110px;
    color: rgba(170, 255, 224, 0.92);
    font-size: 0.86rem;
}

.thread-list {
    max-height: none;
    min-height: 320px;
    padding: 12px;
    border-radius: 18px;
    border: 1px solid rgba(97, 232, 255, 0.11);
    background:
        radial-gradient(circle at 18% 12%, rgba(0, 229, 255, 0.06), transparent 32%),
        linear-gradient(180deg, rgba(0, 0, 0, 0.18), rgba(0, 0, 0, 0.42)),
        rgba(0, 0, 0, 0.25);
}

.message-thread-empty {
    min-height: 100%;
    display: grid;
    place-items: center;
    align-content: center;
    gap: 9px;
    padding: 34px 22px;
    border: 1px dashed rgba(97, 232, 255, 0.2);
    border-radius: 16px;
    color: var(--community-muted);
    text-align: center;
    background:
        linear-gradient(135deg, rgba(97, 232, 255, 0.045), rgba(255, 80, 228, 0.045)),
        rgba(0, 0, 0, 0.12);
}

.message-thread-empty__mark {
    width: 44px;
    height: 44px;
    display: inline-grid;
    place-items: center;
    border-radius: 14px;
    border: 1px solid rgba(97, 232, 255, 0.28);
    color: rgba(198, 244, 255, 0.96);
    background: rgba(97, 232, 255, 0.08);
    font-family: var(--ss-mono-font);
    font-size: 0.78rem;
    font-weight: 900;
}

.message-thread-empty strong {
    color: var(--community-text);
    font-size: 1.05rem;
}

.message-thread-empty span:last-child {
    max-width: 460px;
    line-height: 1.45;
}

.message-row {
    background: transparent;
    padding: 4px;
}

.message-row--mine {
    justify-content: flex-end;
}

.message-row--mine > img {
    order: 2;
}

.message-bubble {
    width: min(680px, 78%);
    padding: 12px 14px;
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 18px;
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.05);
}

.message-row--mine .message-bubble {
    border-bottom-right-radius: 6px;
}

.message-row--theirs .message-bubble {
    border-bottom-left-radius: 6px;
}

.message-attachment video,
.message-attachment audio {
    width: min(420px, 70vw);
    max-width: 100%;
    display: block;
}

.message-attachment--audio {
    padding: 10px;
    background: rgba(0, 0, 0, 0.38);
}

.message-encrypted {
    display: grid;
    gap: 8px;
    padding: 10px;
    border-radius: 14px;
    border: 1px solid rgba(0, 229, 255, 0.26);
    background: rgba(0, 229, 255, 0.08);
}

.message-encrypted span,
.message-encrypted__output {
    color: var(--community-muted);
}

.message-encrypted__controls {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 8px;
}

.message-encrypted__controls input {
    min-height: 42px;
    padding: 9px 11px;
    border-radius: 12px;
    border: 1px solid rgba(0, 229, 255, 0.22);
    background: rgba(0, 0, 0, 0.42);
    color: var(--community-text);
}

.message-encrypted__output.is-open {
    color: var(--community-text);
    white-space: pre-wrap;
}

.message-e2ee-panel {
    display: grid;
    gap: 8px;
}

.message-compose {
    display: grid;
    gap: 12px;
    padding: 16px;
    border-radius: 18px;
    border: 1px solid rgba(97, 232, 255, 0.14);
    background:
        radial-gradient(circle at 8% 0%, rgba(255, 80, 228, 0.08), transparent 34%),
        linear-gradient(160deg, rgba(3, 8, 18, 0.9), rgba(12, 8, 28, 0.76));
}

.message-compose h2 {
    font-size: 1.24rem;
}

.message-compose select,
.message-compose textarea,
.message-e2ee-panel input {
    border-color: rgba(97, 232, 255, 0.22);
    background: rgba(2, 6, 16, 0.76);
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.04);
}

.message-compose textarea {
    min-height: 104px;
}

.message-compose select:focus-visible,
.message-compose textarea:focus-visible,
.message-e2ee-panel input:focus-visible,
.message-room-create input:focus-visible,
.message-room-member-picker select:focus-visible {
    outline: 2px solid rgba(97, 232, 255, 0.62);
    outline-offset: 2px;
}

.message-compose__actions {
    gap: 10px;
}

.message-compose__actions .neon-button,
.message-compose__actions .ghost-button {
    min-width: 112px;
}

.message-e2ee-toggle {
    margin: 0;
}

.message-attachment-preview__audio {
    width: 100%;
    height: 100%;
    display: grid;
    place-items: center;
    color: rgba(170, 255, 224, 0.96);
    font-family: var(--ss-mono-font);
    text-transform: uppercase;
}

.messages-shell.is-room-mode .message-recipient-field,
.messages-shell.is-room-mode .message-safety-actions,
.messages-shell.is-room-mode #message-archive-toggle {
    display: none;
}

.messages-quickchat {
    position: fixed;
    right: max(88px, calc(env(safe-area-inset-right) + 72px));
    bottom: calc(20px + env(safe-area-inset-bottom));
    z-index: 1195;
    display: grid;
    justify-items: end;
    gap: 10px;
}

.messages-quickchat__toggle {
    min-height: 50px;
    padding: 0 15px;
    border-radius: 14px;
    border: 1px solid rgba(255, 80, 228, 0.4);
    background:
        linear-gradient(135deg, rgba(255, 80, 228, 0.84), rgba(0, 229, 255, 0.56)),
        rgba(7, 10, 22, 0.92);
    color: #f6fbff;
    font-size: 0.82rem;
    font-weight: 900;
    letter-spacing: 0.02em;
    cursor: pointer;
    box-shadow:
        0 0 24px rgba(255, 80, 228, 0.22),
        0 10px 24px rgba(0, 0, 0, 0.32);
}

.messages-quickchat__panel {
    width: min(340px, calc(100vw - 36px));
    display: grid;
    gap: 10px;
    padding: 12px;
    border-radius: 14px;
    border: 1px solid rgba(97, 232, 255, 0.3);
    background:
        radial-gradient(circle at 8% 0%, rgba(255, 80, 228, 0.14), transparent 38%),
        linear-gradient(160deg, rgba(4, 8, 18, 0.96), rgba(8, 12, 27, 0.94));
    box-shadow:
        0 20px 54px rgba(0, 0, 0, 0.46),
        0 0 26px rgba(0, 229, 255, 0.14);
    backdrop-filter: blur(12px);
}

.messages-quickchat__head {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 8px;
}

.messages-quickchat__head strong {
    display: block;
    color: #f7fbff;
    font-size: 0.95rem;
}

.messages-quickchat__head span {
    color: rgba(207, 229, 255, 0.74);
    font-size: 0.74rem;
}

.messages-quickchat__close {
    width: 30px;
    height: 30px;
    border-radius: 10px;
    border: 1px solid rgba(255, 255, 255, 0.16);
    background: rgba(0, 0, 0, 0.32);
    color: #f8fbff;
    font-size: 1.1rem;
    line-height: 1;
    cursor: pointer;
}

.messages-quickchat__list {
    max-height: 206px;
    min-height: 112px;
    overflow: auto;
    display: grid;
    gap: 7px;
    padding: 6px;
    border-radius: 11px;
    border: 1px solid rgba(97, 232, 255, 0.14);
    background: rgba(0, 0, 0, 0.28);
}

.messages-quickchat__empty {
    margin: auto 0;
    color: rgba(210, 230, 255, 0.74);
    font-size: 0.76rem;
    line-height: 1.35;
}

.messages-quickchat__item {
    max-width: 92%;
    padding: 8px 9px;
    border-radius: 10px;
    border: 1px solid rgba(255, 255, 255, 0.12);
    background: rgba(8, 15, 30, 0.82);
    color: rgba(242, 248, 255, 0.94);
    font-size: 0.76rem;
    line-height: 1.34;
}

.messages-quickchat__item--mine {
    justify-self: end;
    border-color: rgba(255, 80, 228, 0.34);
    background: rgba(255, 80, 228, 0.16);
}

.messages-quickchat__item--theirs {
    justify-self: start;
    border-color: rgba(0, 255, 159, 0.3);
    background: rgba(0, 255, 159, 0.12);
}

.messages-quickchat__form {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 8px;
}

.messages-quickchat__form input {
    min-height: 40px;
    padding: 9px 10px;
    border-radius: 11px;
    border: 1px solid rgba(97, 232, 255, 0.24);
    background: rgba(2, 6, 16, 0.88);
    color: #f4f8ff;
}

.messages-quickchat__form button {
    min-height: 40px;
    padding: 0 12px;
    border-radius: 11px;
    border: 1px solid rgba(255, 80, 228, 0.42);
    background: rgba(255, 80, 228, 0.18);
    color: #fff3ff;
    font-weight: 900;
    cursor: pointer;
}

@media (max-width: 760px) {
    .messages-feature-strip {
        grid-template-columns: 1fr;
    }

    .message-thread {
        min-height: 0;
        grid-template-rows: auto minmax(420px, 58vh) auto;
    }

    .thread-list {
        min-height: 420px;
    }

    .message-bubble {
        width: min(100%, calc(100vw - 96px));
    }

    .message-encrypted__controls {
        grid-template-columns: 1fr;
    }

    .message-room-create select {
        min-height: 120px;
    }

    .message-room-create__header,
    .message-room-member-picker__topline {
        align-items: flex-start;
        flex-direction: column;
    }

    .message-compose__actions .neon-button,
    .message-compose__actions .ghost-button {
        width: 100%;
    }

    .messages-page-body .shadow-feedback-fab {
        display: none;
    }

    .messages-quickchat {
        right: max(12px, env(safe-area-inset-right));
        bottom: calc(16px + env(safe-area-inset-bottom));
    }

    .messages-quickchat__toggle {
        min-height: 44px;
        padding: 0 12px;
    }

    .messages-quickchat__panel {
        width: min(320px, calc(100vw - 20px));
    }
}

.stats-shell .stats-range-badge {
    text-transform: uppercase;
    letter-spacing: 0.08em;
}

.notifications-page {
    width: min(1180px, 100%);
}

.notifications-hero {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    align-items: end;
    gap: 16px;
    padding: 18px;
    border-radius: 16px;
    border: 1px solid rgba(0, 255, 159, 0.32);
    background:
        radial-gradient(circle at 0% 0%, rgba(255, 0, 255, 0.18), transparent 38%),
        linear-gradient(145deg, rgba(7, 11, 20, 0.96), rgba(1, 8, 13, 0.94));
    box-shadow: 0 0 28px rgba(0, 255, 159, 0.08);
}

.notifications-eyebrow {
    display: inline-flex;
    width: fit-content;
    min-height: 26px;
    align-items: center;
    padding: 0 10px;
    border-radius: 999px;
    border: 1px solid rgba(255, 0, 255, 0.38);
    color: #ffd6ff;
    font-size: 0.72rem;
    font-weight: 900;
    text-transform: uppercase;
}

.notifications-hero h1 {
    margin: 10px 0 6px;
    color: #fff;
    font-size: 2.45rem;
    line-height: 1.02;
}

.notifications-hero p {
    max-width: 760px;
    margin: 0;
    color: rgba(222, 239, 255, 0.78);
}

.notifications-hero__metric {
    min-width: 142px;
    padding: 14px;
    border-radius: 14px;
    border: 1px solid rgba(0, 245, 255, 0.28);
    background: rgba(0, 0, 0, 0.28);
    text-align: right;
}

.notifications-hero__metric strong {
    display: block;
    color: #c77dff;
    font-size: 2rem;
    line-height: 1;
}

.notifications-hero__metric span {
    color: rgba(221, 236, 255, 0.72);
    font-size: 0.78rem;
    font-weight: 800;
}

.notifications-summary-grid {
    display: grid;
    grid-template-columns: repeat(5, minmax(0, 1fr));
    gap: 10px;
    margin-top: 12px;
}

.notifications-summary-grid article {
    min-width: 0;
    padding: 12px;
    border-radius: 12px;
    border: 1px solid rgba(255, 255, 255, 0.1);
    background: rgba(6, 11, 20, 0.82);
}

.notifications-summary-grid span {
    display: block;
    color: rgba(218, 235, 255, 0.68);
    font-size: 0.72rem;
    font-weight: 800;
}

.notifications-summary-grid strong {
    display: block;
    margin-top: 6px;
    color: #00ff9f;
    font-size: 1.35rem;
}

.notifications-layout {
    display: grid;
    grid-template-columns: minmax(180px, 250px) minmax(0, 1fr);
    gap: 12px;
    margin-top: 12px;
}

.notifications-filter-panel,
.notifications-timeline {
    min-width: 0;
    border-radius: 16px;
    border: 1px solid rgba(0, 245, 255, 0.18);
    background: rgba(4, 8, 16, 0.86);
}

.notifications-filter-panel {
    align-self: start;
    padding: 12px;
}

.notifications-filter-panel h2 {
    margin: 0 0 10px;
    color: #fff;
    font-size: 0.92rem;
}

.notifications-filter-list {
    display: grid;
    gap: 7px;
}

.notifications-filter-list a {
    min-width: 0;
    min-height: 38px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
    padding: 7px 9px;
    border-radius: 10px;
    border: 1px solid rgba(255, 255, 255, 0.1);
    color: rgba(234, 244, 255, 0.86);
    text-decoration: none;
    font-weight: 850;
}

.notifications-filter-list a:hover,
.notifications-filter-list a:focus-visible,
.notifications-filter-list a.is-active {
    border-color: rgba(255, 0, 255, 0.48);
    background: rgba(255, 0, 255, 0.12);
    color: #fff;
}

.notifications-filter-list strong {
    flex: 0 0 auto;
    min-width: 28px;
    min-height: 24px;
    display: inline-grid;
    place-items: center;
    border-radius: 999px;
    background: rgba(0, 255, 159, 0.12);
    color: #b8ffe5;
    font-size: 0.72rem;
}

.notifications-timeline {
    display: grid;
    gap: 9px;
    padding: 12px;
}

.notifications-system-note {
    padding: 10px 12px;
    border-radius: 12px;
    border: 1px solid rgba(255, 214, 102, 0.34);
    background: rgba(255, 214, 102, 0.1);
    color: #fff0b8;
    font-size: 0.84rem;
}

.notification-row {
    min-width: 0;
    display: grid;
    grid-template-columns: 46px minmax(0, 1fr);
    gap: 11px;
    align-items: center;
    padding: 12px;
    border-radius: 14px;
    border: 1px solid rgba(255, 255, 255, 0.1);
    background:
        linear-gradient(110deg, rgba(255, 0, 255, 0.08), rgba(0, 245, 255, 0.06)),
        rgba(3, 8, 15, 0.88);
    color: inherit;
    text-decoration: none;
}

.notification-row:hover,
.notification-row:focus-visible {
    outline: none;
    border-color: rgba(0, 255, 159, 0.44);
    transform: translateY(-1px);
}

.notification-row--maintenance {
    border-color: rgba(255, 214, 102, 0.4);
    background:
        linear-gradient(110deg, rgba(255, 214, 102, 0.12), rgba(0, 245, 255, 0.06)),
        rgba(5, 8, 14, 0.92);
}

.notification-row__avatar {
    width: 46px;
    height: 46px;
    border-radius: 999px;
    border: 1px solid rgba(255, 0, 255, 0.48);
    object-fit: cover;
    background: #03070d;
}

.notification-row__body {
    min-width: 0;
    display: grid;
    gap: 3px;
}

.notification-row__meta {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 8px;
    color: rgba(0, 255, 159, 0.78);
    font-size: 0.68rem;
    font-weight: 900;
    text-transform: uppercase;
}

.notification-row h2 {
    min-width: 0;
    margin: 0;
    overflow-wrap: anywhere;
    color: #fff;
    font-size: 1rem;
    line-height: 1.2;
}

.notification-row p {
    min-width: 0;
    margin: 0;
    overflow-wrap: anywhere;
    color: rgba(223, 237, 255, 0.75);
    font-size: 0.84rem;
}

.notifications-empty {
    padding: 28px 18px;
    text-align: center;
    color: rgba(222, 238, 255, 0.78);
}

.notifications-empty h2 {
    margin: 0 0 6px;
    color: #fff;
}

.notifications-empty p {
    margin: 0;
}

@media (max-width: 900px) {
    .notifications-hero,
    .notifications-layout {
        grid-template-columns: minmax(0, 1fr);
    }

    .notifications-hero__metric {
        width: 100%;
        text-align: left;
    }

    .notifications-summary-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .notifications-filter-list {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 560px) {
    .notifications-hero h1 {
        font-size: 2rem;
    }

    .notifications-hero,
    .notifications-filter-panel,
    .notifications-timeline {
        border-radius: 12px;
    }

    .notifications-summary-grid,
    .notifications-filter-list {
        grid-template-columns: minmax(0, 1fr);
    }

    .notification-row {
        grid-template-columns: 40px minmax(0, 1fr);
        padding: 10px;
    }

    .notification-row__avatar {
        width: 40px;
        height: 40px;
    }
}
