/* Casual group conversations: feature-owned, token-based in both themes. */
html.ss-redesign .group-inbox-row { display:flex;align-items:center;gap:12px;width:100%;padding:12px 8px;border:0;border-bottom:1px solid var(--web-line);background:var(--web-paper);color:var(--web-ink);text-align:left;cursor:pointer;min-height:68px;font:inherit; }
html.ss-redesign .group-inbox-row>span:nth-child(2) { flex:1;min-width:0; }
html.ss-redesign .group-inbox-row strong,html.ss-redesign .group-inbox-row small { display:block;overflow:hidden;text-overflow:ellipsis;white-space:nowrap; }
html.ss-redesign .group-inbox-row strong { font-size:15px;font-weight:500; }
html.ss-redesign .group-inbox-row small { font-size:13px;color:var(--web-muted);margin-top:4px; }
html.ss-redesign .group-avatar { flex:none;width:44px;height:44px;border-radius:50%;display:grid;place-items:center;background:var(--web-soft);color:var(--web-accent, #b91c50);font-size:26px; }
html.ss-redesign #feed .group-screen { display:flex!important;flex-direction:column!important;min-height:0!important;height:calc(100dvh - 80px);max-width:100%;overflow:hidden;background:var(--web-paper);color:var(--web-ink); }
html.ss-redesign .group-header { display:flex;align-items:center;gap:8px;flex:none;min-height:52px;border-bottom:1px solid var(--web-line); }
html.ss-redesign .group-header>button:nth-child(2) { flex:1;text-align:center;min-width:0; }
html.ss-redesign .group-header strong { font-size:17px;font-weight:500;display:block;white-space:nowrap;overflow:hidden;text-overflow:ellipsis; }
html.ss-redesign .group-screen button,html.ss-redesign dialog.group-dialog button { min-height:44px;min-width:44px;padding:8px 12px;border:1px solid var(--web-line);border-radius:12px;background:var(--web-soft);color:var(--web-ink);font:inherit;cursor:pointer; }
html.ss-redesign .group-screen button:disabled,html.ss-redesign dialog.group-dialog button:disabled { opacity:.5;cursor:default; }
html.ss-redesign .group-header button { border:0;background:transparent; }
html.ss-redesign .group-message-list { flex:1;min-height:0;overflow:auto;padding:14px;overscroll-behavior:contain; }
html.ss-redesign .group-message { display:flex;flex-direction:column;align-items:flex-start;margin:10px 0; }
html.ss-redesign .group-message.mine { align-items:flex-end; }
html.ss-redesign .group-message .group-alias { min-height:24px;padding:0 8px;border:0;background:transparent;color:var(--web-muted);font-size:12px; }
html.ss-redesign .group-bubble { display:flex;flex-wrap:wrap;gap:6px;max-width:80%;padding:10px 12px;border-radius:20px;background:var(--web-soft);white-space:pre-wrap;overflow-wrap:anywhere;font-size:15px;line-height:1.4; }
html.ss-redesign .group-message.mine .group-bubble { background:var(--web-accent-soft, #fbe1ea); }
html.ss-redesign .group-bubble>span { flex-basis:100%; }
html.ss-redesign .group-bubble>small { align-self:flex-end;font-size:11px;color:var(--web-ink);margin-left:auto; }
html.ss-redesign .group-bubble>button[data-group-message-menu] { padding:0;min-width:44px;min-height:30px;background:transparent;border:0; }
html.ss-redesign .group-bubble>img { width:260px;max-width:100%;height:auto;max-height:320px;object-fit:contain;border-radius:12px; }
html.ss-redesign .group-event { color:var(--web-muted);font-size:12px;text-align:center;margin:14px 0; }
html.ss-redesign .group-case-card { display:flex;flex-direction:column;gap:8px;width:250px;max-width:100%;text-align:left;background:var(--web-paper)!important; }
html.ss-redesign .group-case-card strong { font-size:15px;font-weight:500; }
html.ss-redesign .group-case-card small { font-size:12px;color:var(--web-muted); }
html.ss-redesign .group-screen .group-composer { flex:none;padding:8px!important;margin:0!important;background:var(--web-paper)!important;border:0!important; }
html.ss-redesign .group-composer form { display:flex;align-items:flex-end;gap:3px;border:1px solid var(--web-line);border-radius:24px;padding:3px;background:var(--web-soft); }
html.ss-redesign .group-composer textarea { min-height:40px;max-height:120px;flex:1;min-width:0;padding:9px 12px;border:0!important;background:transparent!important;color:var(--web-ink)!important;font:inherit;resize:vertical; }
html.ss-redesign .group-composer button[type=submit] { border-radius:50%;background:var(--web-accent, #b91c50);color:#fff; }
html.ss-redesign .group-composer p { margin:4px 0;font-size:13px; }
html.ss-redesign .group-invitation { padding:20px; }
html.ss-redesign .group-gif-panel { flex:none;height:min(55dvh,440px);display:flex;flex-direction:column;background:var(--web-paper);border-radius:20px 20px 0 0;padding:10px; }
html.ss-redesign .group-gif-panel form { display:flex;gap:6px; }
html.ss-redesign .group-gif-panel form input { min-width:0;flex:1; }
html.ss-redesign .group-gif-panel>div { display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:6px;overflow:auto;min-height:0;margin-top:8px; }
html.ss-redesign .group-gif-panel img { width:100%;height:auto;max-height:260px;object-fit:contain; }
html.ss-redesign dialog.group-dialog { box-sizing:border-box;width:min(480px,calc(100vw - 24px));max-height:85dvh;margin:auto;padding:18px;overflow:auto;border:1px solid var(--web-line);border-radius:22px;background:var(--web-paper);color:var(--web-ink);font:inherit; }
html.ss-redesign dialog.group-dialog::backdrop { background:rgb(0 0 0 / 45%); }
html.ss-redesign dialog.group-dialog header { display:flex;justify-content:space-between;align-items:center;gap:10px; }
html.ss-redesign dialog.group-dialog h2 { margin:0;font-size:18px;font-weight:500; }
html.ss-redesign dialog.group-dialog p { margin:12px 0;line-height:1.4; }
html.ss-redesign dialog.group-dialog label { display:block;margin:12px 0; }
html.ss-redesign dialog.group-dialog input,html.ss-redesign dialog.group-dialog textarea,html.ss-redesign dialog.group-dialog select,html.ss-redesign .group-gif-panel input { box-sizing:border-box;width:100%;min-height:44px;padding:10px;border:1px solid var(--web-line);border-radius:12px;background:var(--web-soft)!important;color:var(--web-ink)!important;font:inherit; }
html.ss-redesign dialog.group-dialog textarea { min-height:120px; }
html.ss-redesign .group-people { max-height:40dvh;overflow:auto; }
html.ss-redesign .group-people button { display:flex;width:100%;justify-content:space-between;margin:4px 0; }
html.ss-redesign [role=alert] { overflow-wrap:anywhere; }
@media(max-width:767px) {
  html.ss-redesign body.group-chat-open .mobile-nav,html.ss-redesign body.group-chat-open #siteHeader { display:none!important; }
  html.ss-redesign body.group-chat-open #feed .group-screen { height:100dvh!important; }
}

html.ss-redesign .group-message-list { display:flex;flex-direction:column; }
html.ss-redesign .group-message-list::before { content:"";flex:1 0 0; }
html.ss-redesign .group-message-list>* { flex-shrink:0; }
html.ss-redesign .group-composer textarea:focus { outline:none!important;box-shadow:none!important; }
html.ss-redesign .group-composer form:focus-within { border-color:var(--web-accent,#b91c50); }

html.ss-redesign #feed .group-screen .group-composer form textarea,html.ss-redesign #feed .group-screen .group-composer form textarea:focus { border:0!important;outline:none!important;box-shadow:none!important;border-radius:0!important;resize:none!important; }

html.ss-redesign .group-inbox-row time { color:var(--web-muted);font-size:12px;white-space:nowrap; }

/* Group info keeps everyday controls visible and moves member management into People. */
html.ss-redesign .conversation-search-tools { display:flex!important;align-items:center;gap:10px;margin:8px 0!important; }
html.ss-redesign .conversation-search-tools .conversation-search { flex:1!important;min-width:0!important;margin:0!important; }
html.ss-redesign .conversation-search-tools .conversation-new-group { flex:none!important;width:44px!important;height:44px!important;border-radius:50%!important;background:var(--web-soft)!important; }
html.ss-redesign .group-header { display:grid!important;grid-template-columns:44px minmax(0,1fr) 44px!important;align-items:center!important; }
html.ss-redesign .group-header button { display:flex!important;align-items:center!important;justify-content:center!important;min-height:44px!important;min-width:0!important;margin:0!important; }
html.ss-redesign .group-header button strong { font-size:17px!important;line-height:22px!important;font-weight:500!important;overflow:hidden;text-overflow:ellipsis;white-space:nowrap; }
html.ss-redesign dialog.group-dialog .group-info-hero { text-align:center;padding-top:22px; }
html.ss-redesign dialog.group-dialog .group-info-hero h3 { font-size:20px!important;line-height:26px!important;font-weight:500!important;margin:12px 0 4px!important; }
html.ss-redesign dialog.group-dialog .group-info-hero p { color:var(--web-muted);font-size:13px;margin:4px 0; }
html.ss-redesign .group-info-portrait { position:relative;width:112px;height:100px;margin:auto; }
html.ss-redesign .group-info-portrait .group-person-avatar { position:absolute!important;width:78px!important;height:78px!important;border:3px solid var(--web-paper)!important;border-radius:50%!important;overflow:hidden;left:0;top:0; }
html.ss-redesign .group-info-portrait .group-person-avatar+ .group-person-avatar { left:auto;top:auto;right:0;bottom:0; }
html.ss-redesign .group-person-avatar img { width:100%!important;height:100%!important;object-fit:cover; }
html.ss-redesign dialog.group-dialog .group-change-name { color:var(--web-accent)!important;background:transparent!important;border:0!important;min-height:44px!important; }
html.ss-redesign .group-quick-actions { display:flex!important;justify-content:space-around;gap:8px;margin:18px 0; }
html.ss-redesign dialog.group-dialog .group-quick-actions button { display:flex!important;flex-direction:column;align-items:center;gap:8px;background:transparent!important;border:0!important;padding:0!important;min-width:44px; }
html.ss-redesign .group-quick-actions button>span { display:flex;align-items:center;justify-content:center;width:48px;height:48px;border-radius:50%;background:var(--web-soft);font-size:24px; }
html.ss-redesign .group-quick-actions small { font-size:13px!important;font-weight:400!important; }
html.ss-redesign dialog.group-dialog .group-info-row { display:flex!important;align-items:center;gap:14px;width:100%;padding:14px 0!important;min-height:64px!important;text-align:left;background:transparent!important;border:0!important;font-size:16px!important;font-weight:400!important; }
html.ss-redesign .group-info-row>span:nth-child(2) { flex:1;min-width:0; }
html.ss-redesign .group-info-row small,html.ss-redesign .group-person small { display:block;color:var(--web-muted);font-size:13px;line-height:18px;font-weight:400;overflow:hidden;text-overflow:ellipsis;white-space:nowrap; }
html.ss-redesign dialog.group-dialog .group-people-label { font-size:14px!important;font-weight:500!important;color:var(--web-muted);margin:22px 0 8px; }
html.ss-redesign .group-person { display:flex;align-items:center;gap:8px; }
html.ss-redesign dialog.group-dialog .group-person button { background:transparent!important;border:0!important;min-height:48px!important; }
html.ss-redesign dialog.group-dialog .group-person button:first-child { display:flex;align-items:center;flex:1;gap:14px;padding:12px 0!important;text-align:left;font-weight:500!important;min-width:0; }
html.ss-redesign .group-person .group-person-avatar { width:48px!important;height:48px!important;flex:none;overflow:hidden;border-radius:50%; }
html.ss-redesign .group-person button>span:last-child { min-width:0; }
html.ss-redesign dialog.group-dialog .group-info-back { background:transparent!important;border:0!important;color:var(--web-muted)!important;font-size:13px!important; }
html.ss-redesign dialog.group-dialog .group-danger { color:var(--web-danger,#bc244e)!important; }
html.ss-redesign .group-info-muted { color:var(--web-muted);font-size:13px; }

html.ss-redesign .group-quick-actions svg,html.ss-redesign .group-info-row svg { width:24px!important;height:24px!important; }

/* Inbox action hierarchy: filled main actions, soft secondary controls and quieter menus. */
html.ss-redesign .group-screen button,html.ss-redesign dialog.group-dialog button { font-weight:500;border-radius:14px;border:0;transition:opacity 100ms ease-out; }
html.ss-redesign .group-screen button:active,html.ss-redesign dialog.group-dialog button:active { opacity:.72; }
html.ss-redesign dialog.group-dialog :is([data-create],[data-name-save],[data-submit-report]),html.ss-redesign .group-invitation [data-group-join] { min-height:48px;padding:12px 20px;background:var(--web-accent)!important;color:var(--web-on-accent)!important; }
html.ss-redesign dialog.group-dialog :is([data-create],[data-name-save],[data-submit-report]) { width:100%;margin-top:12px; }
html.ss-redesign .group-screen :is([data-group-older],[data-group-report]),html.ss-redesign dialog.group-dialog :is([data-report],[data-discard]) { background:transparent!important;color:var(--web-muted)!important; }
html.ss-redesign dialog.group-dialog :is([data-leave],[data-clear],[data-member-remove]),html.ss-redesign [data-group-delete-selected] { color:var(--web-danger)!important; }
html.ss-redesign .group-list-portrait { position:relative;flex:none;width:48px;height:48px; }
html.ss-redesign .group-list-portrait .group-person-avatar { position:absolute!important;left:0;top:0;width:36px!important;height:36px!important;border:2px solid var(--web-paper);box-sizing:border-box;border-radius:50%;overflow:hidden; }
html.ss-redesign .group-list-portrait .group-person-avatar+.group-person-avatar { top:auto;left:auto;right:0;bottom:0; }
html.ss-redesign .group-unread-badge { display:grid;place-items:center;min-width:22px;height:22px;padding:0 6px;box-sizing:border-box;border-radius:11px;background:var(--web-accent);color:var(--web-on-accent);font-size:12px;font-weight:500; }
html.ss-redesign dialog.group-dialog .group-people [data-person] { display:flex;align-items:center;gap:14px;min-height:72px;background:transparent;border:0;padding:12px 0;text-align:left; }
html.ss-redesign .group-people .group-person-avatar { flex:none;width:48px!important;height:48px!important;border-radius:50%;overflow:hidden; }
html.ss-redesign .group-people [data-person]>span:nth-child(2) { flex:1;min-width:0;overflow-wrap:anywhere; }
html.ss-redesign .group-select-circle { display:grid;place-items:center;width:24px;height:24px;flex:none;border-radius:50%;border:1px solid var(--web-muted);box-sizing:border-box; }
html.ss-redesign [data-person][aria-checked=true] .group-select-circle { background:var(--web-accent);border-color:var(--web-accent);color:var(--web-on-accent); }
html.ss-redesign .group-select-circle svg { width:16px;height:16px; }
html.ss-redesign .group-composer [data-group-gif] { width:44px;height:44px;padding:0!important;background:transparent!important;border-radius:22px; }
html.ss-redesign .group-composer [data-group-gif][aria-expanded=true] { background:var(--web-accent-soft)!important;color:var(--web-accent)!important; }
html.ss-redesign .group-composer button[type=submit] { width:44px;height:44px;padding:0!important;color:var(--web-on-accent)!important; }
html.ss-redesign .group-composer :is([data-group-gif],button[type=submit]) svg { width:24px;height:24px; }
html.ss-redesign .conversation-search-tools .conversation-new-group { color:var(--web-accent)!important;background:var(--web-accent-soft)!important; }
@media (prefers-reduced-motion:reduce) { html.ss-redesign .group-screen button,html.ss-redesign dialog.group-dialog button { transition:none; } }

/* Timestamp, unread count and More each have their own space. */
html.ss-redesign body.web-mobile-parity.logged-in.inbox-view #home #feed .conversation-row-wrap { display:flex!important;align-items:center!important;gap:4px; }
html.ss-redesign body.web-mobile-parity.logged-in.inbox-view #home #feed .conversation-row-wrap>.conversation-row { display:grid!important;grid-template-columns:48px minmax(0,1fr) auto!important;flex:1!important;min-width:0!important;width:auto!important;min-height:72px!important;padding:10px 4px 10px 0!important;border:0!important;background:var(--web-paper)!important;box-shadow:none!important;text-align:left; }
html.ss-redesign body.web-mobile-parity.logged-in.inbox-view #home #feed .conversation-row-wrap>.inbox-row-options { position:static!important;inset:auto!important;transform:none!important;flex:none!important;width:44px!important;height:44px!important;min-height:44px!important;padding:0!important;margin:0!important;border:0!important;border-radius:22px!important;background:transparent!important;color:var(--web-ink)!important;box-shadow:none!important; }
html.ss-redesign body.web-mobile-parity.logged-in.inbox-view #home #feed .conversation-row-body { min-width:0!important; }
html.ss-redesign body.web-mobile-parity.logged-in.inbox-view #home #feed .conversation-row-top { display:flex!important;align-items:center!important;gap:8px!important; }
html.ss-redesign body.web-mobile-parity.logged-in.inbox-view #home #feed .conversation-row-top strong { flex:1;min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;font-size:15px!important;font-weight:500!important; }
html.ss-redesign body.web-mobile-parity.logged-in.inbox-view #home #feed .conversation-row.is-unread .conversation-row-top strong { font-weight:600!important; }
html.ss-redesign body.web-mobile-parity.logged-in.inbox-view #home #feed .conversation-row-time { flex:none!important;position:static!important;color:var(--web-muted)!important;font-size:13px!important;font-weight:400!important; }
html.ss-redesign body.web-mobile-parity.logged-in.inbox-view #home #feed .conversation-row-preview { font-size:13px!important;font-weight:400!important;color:var(--web-muted)!important; }
html.ss-redesign body.web-mobile-parity.logged-in.inbox-view #home #feed .conversation-row.is-unread .conversation-row-preview { font-weight:500!important;color:var(--web-ink)!important; }
html.ss-redesign body.web-mobile-parity.logged-in.inbox-view #home #feed .conversation-row-dot { position:static!important;display:grid!important;place-items:center;min-width:22px!important;height:22px!important;border-radius:11px!important;background:var(--web-accent)!important;color:var(--web-on-accent)!important;padding:0 6px!important;font-size:12px!important; }

/* One Inbox typography/spacing contract for groups and private conversations. */
html.ss-redesign body.web-mobile-parity.logged-in.inbox-view #home #feed .group-inbox-row { min-height:72px;padding:10px 0;gap:12px;border-bottom:1px solid var(--web-line); }
html.ss-redesign body.web-mobile-parity.logged-in.inbox-view #home #feed :is(.conversation-row-top strong,.group-inbox-row strong) { font-family:"SS Montserrat",Arial,sans-serif!important;font-size:15px!important;line-height:20px!important;font-weight:500!important; }
html.ss-redesign body.web-mobile-parity.logged-in.inbox-view #home #feed :is(.conversation-row.is-unread .conversation-row-top strong,.group-inbox-row.is-unread strong) { font-weight:600!important; }
html.ss-redesign body.web-mobile-parity.logged-in.inbox-view #home #feed :is(.conversation-row-preview,.group-inbox-row small) { font-family:"SS Montserrat",Arial,sans-serif!important;font-size:13px!important;line-height:18px!important;margin-top:2px!important;font-weight:400!important;color:var(--web-muted)!important; }
html.ss-redesign body.web-mobile-parity.logged-in.inbox-view #home #feed :is(.conversation-row.is-unread .conversation-row-preview,.group-inbox-row.is-unread small) { font-weight:500!important;color:var(--web-ink)!important; }
html.ss-redesign body.web-mobile-parity.logged-in.inbox-view #home #feed :is(.conversation-row-time,.group-inbox-row time) { font-family:"SS Montserrat",Arial,sans-serif!important;font-size:13px!important;line-height:18px!important;color:var(--web-muted)!important; }
html.ss-redesign body.web-mobile-parity.logged-in.inbox-view #home #feed .conversation-row-wrap { border-bottom:1px solid var(--web-line); }
html.ss-redesign .group-list-portrait .group-person-avatar { border:0; }
html.ss-redesign body.web-mobile-parity #home #feed .conversation-peer strong { font-weight:500!important; }

/* Reading text follows the browser's default font size and supports text resizing. */
html.ss-redesign body.web-mobile-parity #home #feed :is(.message-bubble-text,.group-bubble) { font-size:1.0625rem!important;line-height:1.3!important;overflow-wrap:anywhere!important; }
html.ss-redesign body.web-mobile-parity #home #feed :is(#conversationMessageInput,.group-composer textarea) { font-family:"SS Montserrat",Arial,sans-serif!important;font-size:1.0625rem!important;line-height:1.3!important;min-width:0!important;min-height:max(44px,calc(1.375rem + 20px))!important;max-height:max(calc(1.375rem + 20px),25dvh)!important; }
html.ss-redesign body.web-mobile-parity #home #feed :is(.conversation-row-dot,.group-unread-badge) { min-height:22px!important;height:auto!important;font-size:.75rem!important;line-height:1.3334!important;padding:3px 6px!important; }
