:root {
  --modern-bg: var(--bg);
  --modern-surface: var(--surface);
  --modern-surface-raised: var(--surface-raised, var(--surface-variant));
  --modern-text: var(--text);
  --modern-muted: var(--text-muted);
  --modern-border: var(--border);
  --modern-primary: var(--primary);
  --modern-secondary: var(--secondary);
  --modern-accent: var(--tertiary, var(--accent));
  --modern-focus: var(--focus);

  --modern-radius-sm: 0.75rem;
  --modern-radius-md: 1rem;
  --modern-radius-lg: 1.25rem;
  --modern-radius-xl: 1.5rem;
  --modern-radius-pill: 999px;

  --modern-shadow-1: 0 4px 14px rgba(0, 0, 0, 0.10);
  --modern-shadow-2: 0 12px 32px rgba(0, 0, 0, 0.16);
  --modern-shadow-3: 0 18px 46px rgba(0, 0, 0, 0.22);
}

body {
  background: radial-gradient(circle at top right, color-mix(in srgb, var(--modern-primary) 12%, transparent), transparent 45%), var(--modern-bg);
  color: var(--modern-text);
}

.topbar,
.app-bar {
  background: color-mix(in srgb, var(--modern-surface) 86%, black);
  border-bottom: 1px solid color-mix(in srgb, var(--modern-border) 75%, transparent);
  backdrop-filter: blur(10px);
}

.left-rail,
.right-rail,
.sidebar {
  background: color-mix(in srgb, var(--modern-surface) 93%, black);
  border-color: color-mix(in srgb, var(--modern-border) 80%, transparent);
}

.card,
.panel,
.widget,
.feed-card,
.post-card,
.settings-card,
.modal-content,
.dropdown-menu {
  background: var(--modern-surface-raised);
  border: 1px solid color-mix(in srgb, var(--modern-border) 85%, transparent);
  border-radius: var(--modern-radius-md);
  box-shadow: var(--modern-shadow-1);
}

.btn {
  border-radius: var(--modern-radius-pill);
  font-weight: 600;
  transition: transform .15s ease, box-shadow .2s ease, background-color .2s ease, border-color .2s ease;
}

.btn:hover {
  transform: translateY(-1px);
  box-shadow: var(--modern-shadow-1);
}

.btn:active {
  transform: translateY(0);
}

.btn-primary,
.btn-brand,
button[type="submit"] {
  box-shadow: 0 8px 20px color-mix(in srgb, var(--modern-primary) 28%, transparent);
}

.icon-btn,
.profile-chip,
.nav-link,
.dropdown-item {
  border-radius: var(--modern-radius-sm);
}

.form-control,
.form-select,
.form-check-input,
input,
select,
textarea {
  border-radius: var(--modern-radius-sm);
  border-color: color-mix(in srgb, var(--modern-border) 90%, transparent);
  background: color-mix(in srgb, var(--modern-surface) 92%, black);
  color: var(--modern-text);
}

.form-control:focus,
.form-select:focus,
.form-check-input:focus,
input:focus,
select:focus,
textarea:focus,
.btn:focus-visible,
.icon-btn:focus-visible,
.nav-link:focus-visible,
.dropdown-item:focus-visible {
  border-color: var(--modern-focus);
  box-shadow: 0 0 0 3px color-mix(in srgb, var(--modern-focus) 30%, transparent);
  outline: none;
}

.left-rail .nav-link:hover,
.right-rail .nav-link:hover,
.nav-link.active,
.dropdown-item:hover {
  background: color-mix(in srgb, var(--modern-primary) 18%, transparent);
  color: var(--modern-text);
}

.alert {
  border-radius: var(--modern-radius-sm);
  border-color: color-mix(in srgb, var(--modern-border) 80%, transparent);
}

hr,
.border,
.border-top,
.border-bottom,
.border-start,
.border-end {
  border-color: color-mix(in srgb, var(--modern-border) 75%, transparent) !important;
}


/* Pocket visual layer */
.pocket-shell{max-width:1180px;margin:0 auto;display:grid;gap:.6rem}
.wizard-social-shell.pocket-shell{max-width:960px}
.pocket-hero,.pocket-quick-card,.pocket-item-card,.pocket-file-card,.pocket-stat-card,.pocket-toolbar{background:linear-gradient(160deg,rgba(23,26,45,.95),rgba(16,19,34,.92));border:1px solid rgba(122,209,255,.15);border-radius:16px;box-shadow:0 10px 28px rgba(0,0,0,.32);backdrop-filter:blur(8px)}
.pocket-hero{padding:.7rem .9rem;border-color:rgba(170,127,255,.25)}
.pocket-hero-grid{display:grid;grid-template-columns:minmax(0,1fr) auto;gap:.6rem;align-items:center}
.pocket-hero-actions{display:flex;flex-wrap:wrap;justify-content:flex-end;gap:.5rem}
.pocket-eyebrow{font-size:.75rem;letter-spacing:.08em;text-transform:uppercase;color:rgba(183,200,255,.85)}
.pocket-chip-row,.pocket-item-meta{display:flex;flex-wrap:wrap;gap:.45rem .6rem}
.pocket-chip{display:inline-flex;align-items:center;padding:.25rem .65rem;border-radius:999px;font-size:.78rem;background:rgba(255,255,255,.06);border:1px solid rgba(255,255,255,.08);color:rgba(236,242,255,.9)}
.pocket-toolbar,.pocket-quick-card,.pocket-item-card,.pocket-file-card{padding:.8rem}
.pocket-stat-grid{display:grid;grid-template-columns:repeat(auto-fit,minmax(160px,1fr));gap:.55rem}
.pocket-stat-card{padding:.72rem .82rem;position:relative;overflow:hidden}
.pocket-stat-card:before{content:'';position:absolute;top:0;left:0;right:0;height:2px;background:linear-gradient(90deg,#47d1ff,#b882ff,#ff7ea8)}
.pocket-stat-card .value{font-size:1.25rem;font-weight:700}
.pocket-type-pill,.pocket-standard-badge,.pocket-locked-badge{display:inline-flex;align-items:center;padding:.2rem .55rem;border-radius:999px;font-size:.74rem}
.pocket-type-pill{background:rgba(71,209,255,.14);color:#93ebff}.pocket-standard-badge{background:rgba(126,255,180,.16);color:#96ffc3}.pocket-locked-badge{background:rgba(255,146,146,.2);color:#ffb0b0}
.pocket-action-row,.pocket-card-footer{display:flex;flex-wrap:wrap;gap:.5rem}
.pocket-item-meta{color:rgba(222,231,255,.72);font-size:.86rem}
.pocket-preview{font-size:.9rem;line-height:1.4;color:rgba(234,242,255,.92);border-top:1px solid rgba(122,209,255,.14);padding-top:.55rem;display:-webkit-box;-webkit-line-clamp:3;-webkit-box-orient:vertical;overflow:hidden}
.pocket-item-title{word-break:break-word}
.pocket-body-render{background:rgba(255,255,255,.03);border:1px solid rgba(255,255,255,.07);border-radius:12px;padding:1rem;line-height:1.6}
.pocket-warning{border:1px solid rgba(255,146,146,.5);background:rgba(66,15,20,.4);border-radius:14px;padding:.95rem}
.pocket-search-form{display:flex;gap:.5rem;flex:1;min-width:260px}
.pocket-search-form .form-control{min-width:220px}
.pocket-filter-strip{display:flex;gap:.5rem;overflow-x:auto;padding:.15rem 0 .25rem;scrollbar-width:none;-webkit-overflow-scrolling:touch}
.pocket-filter-strip::-webkit-scrollbar{display:none}
.pocket-filter-pill{display:inline-flex;align-items:center;justify-content:center;padding:.45rem .9rem;border-radius:999px;border:1px solid rgba(140,214,255,.25);background:rgba(14,19,39,.75);color:rgba(227,238,255,.9);text-decoration:none;font-weight:600;white-space:nowrap;min-height:40px}
.pocket-filter-pill:hover,.pocket-filter-pill:focus-visible{color:#fff;background:rgba(102,152,255,.24);border-color:rgba(169,132,255,.55);outline:none}
.pocket-filter-pill.is-active{background:linear-gradient(120deg,rgba(103,216,255,.24),rgba(194,126,255,.28));border-color:rgba(194,126,255,.55);box-shadow:0 0 20px rgba(120,200,255,.2)}
.pocket-item-card .btn,.pocket-file-card .btn,.pocket-quick-actions .btn{min-height:38px}
.pocket-card-footer .btn{min-width:84px}
.pocket-delete-muted{opacity:.85}
.pocket-file-icon{width:44px;height:44px;border-radius:10px;display:grid;place-items:center;background:rgba(71,209,255,.16);border:1px solid rgba(71,209,255,.32);font-size:.72rem;font-weight:700;color:#a8efff;flex-shrink:0}
.pocket-empty-state{padding:1.4rem}
.pocket-progress{height:8px;background:rgba(255,255,255,.08);border-radius:999px;overflow:hidden}.pocket-progress>span{display:block;height:100%;background:linear-gradient(90deg,#47d1ff,#b882ff,#ff7ea8)}
.pocket-section-title{margin-bottom:.9rem}
.pocket-title{font-size:1.4rem;font-weight:800;color:#f3f7ff;letter-spacing:-.01em}
.pocket-accordion>summary{list-style:none}
.pocket-accordion>summary::-webkit-details-marker{display:none}
.pocket-accordion__summary{display:flex;align-items:center;gap:.5rem;cursor:pointer;font-weight:700;font-size:.95rem;color:#eef3ff}
.pocket-accordion__label{display:inline-flex;align-items:center;gap:.4rem;margin-right:auto}
.pocket-accordion__label .material-symbols-outlined{font-size:1.15rem;color:#9adcff}
.pocket-accordion__summary::after{content:'expand_more';font-family:'Material Symbols Outlined';font-weight:400;font-size:1.25rem;line-height:1;color:rgba(200,215,255,.7);transition:transform .18s ease}
.pocket-accordion[open]>.pocket-accordion__summary::after{transform:rotate(180deg)}
.pocket-accordion[open]>.pocket-accordion__summary{margin-bottom:.7rem;padding-bottom:.6rem;border-bottom:1px solid rgba(122,209,255,.16)}
.pocket-trash-card{border-color:rgba(255,146,146,.38);background:linear-gradient(160deg,rgba(42,20,28,.68),rgba(21,14,24,.9))}
.pocket-action-row-sticky{position:sticky;bottom:.4rem;background:rgba(9,13,29,.86);border:1px solid rgba(130,204,255,.24);padding:.6rem;border-radius:14px;z-index:2}
.pocket-editor-layout{display:grid;grid-template-columns:1fr;gap:1rem}
.pocket-editor-main textarea{min-height:48vh}
.pocket-editor-side{height:max-content}
.pocket-sticky-save{position:sticky;bottom:.5rem;background:rgba(16,19,34,.7);padding-top:.35rem}
.pocket-file-card .table{color:rgba(236,242,255,.92);margin-bottom:0}
.pocket-file-card .table thead th{color:rgba(199,214,255,.9);border-bottom-color:rgba(122,209,255,.22)}
.pocket-file-card .table td,.pocket-file-card .table th{border-color:rgba(122,209,255,.16)}
.pocket-file-card .table .text-muted{color:rgba(199,214,255,.75)!important}
.pocket-editor-form .form-label{color:rgba(224,234,255,.9);font-weight:600;margin-bottom:.35rem}
.pocket-editor-form .form-control,.pocket-editor-form .form-select{background:rgba(8,5,26,.92);border:1px solid rgba(122,209,255,.28);color:rgba(245,248,255,.98)}
.pocket-editor-form .form-control::placeholder{color:rgba(197,206,236,.78)}
.pocket-editor-form .form-control:focus,.pocket-editor-form .form-select:focus{background:rgba(11,8,33,.96);color:#fff;border-color:rgba(130,223,255,.72);box-shadow:0 0 0 .2rem rgba(91,199,255,.18)}
.pocket-editor-form .form-check-input{background-color:rgba(255,255,255,.08);border-color:rgba(122,209,255,.5)}
.pocket-editor-form .form-check-label{color:rgba(235,242,255,.95)}
@media (min-width: 992px){.pocket-hero-grid{grid-template-columns:1fr auto}.pocket-editor-layout{grid-template-columns:minmax(0,1fr) 320px}}
@media (max-width: 767px){.pocket-search-form{min-width:100%;flex-wrap:wrap}.pocket-search-form .form-control{min-width:100%}.pocket-hero-actions .btn{flex:1 1 calc(50% - .5rem)}.pocket-item-card,.pocket-file-card{padding:1rem}.pocket-card-footer .btn,.pocket-card-footer form{flex:1 1 calc(50% - .5rem)}.pocket-card-footer form .btn{width:100%}}

/* Promos visual layer */
.promos-shell{max-width:1080px;margin:0 auto;display:grid;gap:1rem}
.promos-hero,.promos-toolbar,.promo-card{position:relative;background:linear-gradient(155deg,rgba(18,22,40,.94),rgba(13,16,30,.92));border:1px solid rgba(117,228,255,.2);border-radius:16px;box-shadow:0 12px 30px rgba(0,0,0,.35);backdrop-filter:blur(8px)}
.promos-hero{padding:1.1rem 1.2rem;display:flex;justify-content:space-between;align-items:center;gap:1rem;border-color:rgba(195,115,255,.3)}
.promos-kicker{font-size:.76rem;letter-spacing:.08em;text-transform:uppercase;color:rgba(199,211,255,.9)}
.promos-hero-badge{width:52px;height:52px;display:grid;place-items:center;border-radius:999px;background:radial-gradient(circle at 30% 30%,rgba(255,255,255,.3),rgba(113,240,255,.2) 42%,rgba(193,122,255,.3));box-shadow:0 0 24px rgba(141,246,255,.35)}
.promos-toolbar{padding:.9rem;display:grid;gap:.8rem}
.promos-search-form{display:flex;gap:.55rem;flex-wrap:wrap}.promos-search-form .form-control{flex:1;min-width:210px}
.promos-actions{display:flex;flex-wrap:wrap;gap:.5rem}
.promo-grid{display:grid;grid-template-columns:1fr;gap:.85rem}
.promo-card{padding:1rem;overflow:hidden}.promo-card-glow{position:absolute;inset:0;pointer-events:none;background:radial-gradient(circle at 100% 0,rgba(98,232,255,.16),transparent 48%),radial-gradient(circle at 0 100%,rgba(224,120,255,.13),transparent 52%)}
.promo-grid .promo-card{border-color:rgba(151,230,255,.32);box-shadow:0 14px 34px rgba(0,0,0,.4),0 0 26px rgba(120,209,255,.16)}
.promo-card-top,.promo-action-row,.promo-business-row{position:relative;z-index:1;display:flex;justify-content:space-between;align-items:center;gap:.6rem;flex-wrap:wrap}
.promo-discount-pill{display:inline-flex;padding:.28rem .66rem;border-radius:999px;font-size:.78rem;font-weight:700;color:#091223;background:linear-gradient(90deg,#79efff,#b59bff,#ff8fbc)}
.promo-title{position:relative;z-index:1;margin:.55rem 0 .4rem;font-size:1.15rem;font-weight:800;letter-spacing:.01em}
.promo-description{position:relative;z-index:1;color:rgba(232,239,255,.86);font-size:.92rem;line-height:1.4;display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical;overflow:hidden;min-height:2.55em}
.promo-perforation{position:relative;z-index:1;border-top:1px dashed rgba(143,214,255,.45);margin:.72rem 0}
.promo-preview{position:relative;z-index:1;background:rgba(255,255,255,.05);border:1px solid rgba(255,255,255,.1);border-radius:12px;padding:.65rem;font-size:.9rem}
.promo-expiry{position:relative;z-index:1;margin:.55rem 0;color:rgba(201,214,255,.8);font-size:.84rem}
.promo-empty-state{background:linear-gradient(160deg,rgba(24,24,42,.96),rgba(16,16,31,.95));border:1px solid rgba(136,214,255,.18)}
.promo-form-grid .form-label{font-weight:600}
.promo-form-card{border-color:rgba(184,132,255,.34)}
.promo-form-grid{display:grid;grid-template-columns:1fr;gap:.8rem}
.promo-form-textarea{min-height:120px}
.promo-form-span-2{grid-column:1/-1}
.promo-redeem-code{font-size:1.3rem;padding:.65rem .7rem;border-radius:12px;border:1px dashed rgba(156,234,255,.5);background:rgba(255,255,255,.04);letter-spacing:.05em;word-break:break-all}
@media (min-width:768px){.promo-grid{grid-template-columns:repeat(2,minmax(0,1fr))}.promo-form-grid{grid-template-columns:repeat(2,minmax(0,1fr))}}
@media (min-width:1100px){.promo-grid{grid-template-columns:repeat(3,minmax(0,1fr))}}

.qr-wallet-shell{max-width:640px}
.qr-wallet-card{display:grid;gap:.75rem;justify-items:center}
.qr-wallet-chip-row{display:flex;gap:.45rem;flex-wrap:wrap;justify-content:center}
.qr-wallet-image{max-width:280px;width:min(100%,280px);padding:.7rem;border-radius:16px;border:1px solid rgba(130,224,255,.45);background:rgba(255,255,255,.04);box-shadow:0 0 0 2px rgba(122,188,255,.12),0 0 24px rgba(131,226,255,.2)}

.points-shell{max-width:900px}
.points-balance{font-size:2rem;line-height:1;font-weight:800;color:#e7f3ff;text-shadow:0 0 16px rgba(130,218,255,.3)}
.points-account-card,.points-activity-card{border-color:rgba(130,214,255,.28)}
.points-activity-card p{word-break:break-word}

.scanner-shell{max-width:720px}
.scanner-action-card{display:grid;gap:1rem}
.scanner-form{display:grid;gap:.65rem}
.scanner-stage{min-height:240px;border:2px dashed rgba(129,222,255,.45);border-radius:16px;display:grid;place-items:center;background:radial-gradient(circle at 50% 50%,rgba(117,228,255,.11),rgba(16,20,38,.45));color:rgba(221,236,255,.9);font-weight:600}

/* Profile visual layer */
.profile-shell,.business-profile-shell{max-width:1080px;margin:0 auto;display:grid;gap:1rem}
.profile-hero,.business-profile-hero{border-radius:18px}
.profile-avatar-panel{width:112px;height:112px;flex-shrink:0}
.profile-avatar__image{width:100%;height:100%;object-fit:cover;border-radius:999px;border:2px solid color-mix(in srgb,var(--modern-border) 80%,transparent)}
.profile-identity .profile-title{line-height:1.2}
.profile-action-row{display:flex;flex-wrap:wrap;gap:.5rem}
.profile-stat-strip{display:grid;grid-template-columns:repeat(auto-fit,minmax(140px,1fr))}
.profile-stat-strip .profile-stats__item{padding:.55rem .7rem;gap:.2rem;min-height:0;border-right:1px solid color-mix(in srgb,var(--modern-border) 60%,transparent)}
.profile-stat-strip .profile-stats__item:last-child{border-right:none}
.profile-main-grid{display:grid;grid-template-columns:1fr;gap:1rem}
.profile-info-card,.profile-empty-card{border-radius:16px}

.business-profile-hero{background:linear-gradient(160deg,rgba(16,22,36,.96),rgba(13,18,30,.92));border:1px solid rgba(121,202,255,.3)}
.business-profile-card{background:linear-gradient(160deg,rgba(15,19,32,.95),rgba(12,16,27,.92));border:1px solid rgba(120,187,255,.2);border-radius:16px}
.business-profile-promos .list-group-item{background:rgba(255,255,255,.03);border-color:rgba(255,255,255,.08)}
.support-mode-banner{position:sticky;top:0;z-index:1200;background:#7b0000;color:#fff;padding:.65rem 1rem;display:flex;gap:1rem;align-items:center;justify-content:space-between;border:1px solid rgba(255,255,255,.2)}

.mobile-bottom-nav{position:fixed;left:0;right:0;bottom:0;z-index:1180;display:grid;grid-template-columns:repeat(5,minmax(0,1fr));gap:.35rem;padding:.5rem max(.45rem,env(safe-area-inset-left)) calc(.56rem + env(safe-area-inset-bottom)) max(.45rem,env(safe-area-inset-right));background:linear-gradient(180deg,rgba(7,10,24,.9),rgba(8,11,30,.98));border-top:1px solid rgba(150,208,255,.26);box-shadow:0 -16px 34px rgba(0,0,0,.42),0 0 0 1px rgba(98,176,255,.08) inset;backdrop-filter:blur(14px) saturate(138%)}
.mobile-bottom-nav__item{min-width:0;min-height:58px;display:flex;flex-direction:column;align-items:center;justify-content:center;gap:.2rem;padding:.32rem .1rem;border-radius:15px;color:rgba(226,238,255,.88);text-decoration:none;transition:background .18s ease,color .18s ease,box-shadow .18s ease,transform .18s ease}
.mobile-bottom-nav__item .material-symbols-outlined{font-size:1.3rem;line-height:1}
.mobile-bottom-nav__label{font-size:.7rem;font-weight:700;line-height:1.05;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;max-width:100%}
.mobile-bottom-nav__item:hover,.mobile-bottom-nav__item:focus-visible{color:#fff;background:rgba(255,255,255,.08);outline:none}
.mobile-bottom-nav__item:focus-visible{box-shadow:0 0 0 2px rgba(123,214,255,.68)}
.mobile-bottom-nav__item.is-active{background:linear-gradient(140deg,rgba(110,228,255,.26),rgba(188,130,255,.28));color:#fff;box-shadow:0 0 0 1px rgba(183,142,255,.52),0 8px 22px rgba(103,177,255,.24),0 0 26px rgba(114,208,255,.22)}
.mobile-bottom-nav__item.is-active .material-symbols-outlined{font-variation-settings:'FILL' 1}
@media (min-width: 992px){.mobile-bottom-nav{display:none}}
@media (max-width: 360px){.mobile-bottom-nav{gap:.25rem;padding-left:max(.32rem,env(safe-area-inset-left));padding-right:max(.32rem,env(safe-area-inset-right))}.mobile-bottom-nav__label{font-size:.64rem;letter-spacing:-.01em}}

body{overflow-x:hidden}
:root{--wizard-mobile-nav-height:82px;--wizard-bottom-ui-clearance:calc(var(--wizard-mobile-nav-height,82px) + env(safe-area-inset-bottom) + 1rem);--wizard-sticky-submit-offset:calc(var(--wizard-mobile-nav-height,82px) + env(safe-area-inset-bottom) + .75rem);--wizard-sticky-submit-clearance:calc(var(--wizard-mobile-nav-height,82px) + env(safe-area-inset-bottom) + 4.75rem)}
@media (max-width: 991.98px){
  body.has-mobile-bottom-nav .editor{padding-bottom:var(--wizard-bottom-ui-clearance)}
  body.has-mobile-bottom-nav .pocket-shell{padding-bottom:calc(var(--wizard-mobile-nav-height,82px) + env(safe-area-inset-bottom) + 1.5rem)}
  body.has-mobile-bottom-nav .wizard-social-shell{padding-bottom:calc(var(--wizard-mobile-nav-height,82px) + env(safe-area-inset-bottom) + 1.4rem)}
  .wizard-bottom-safe{padding-bottom:calc(var(--wizard-mobile-nav-height,82px) + env(safe-area-inset-bottom) + 1rem)}
  .wizard-bottom-safe-sm{padding-bottom:calc(var(--wizard-mobile-nav-height,82px) + env(safe-area-inset-bottom) + .5rem)}
  .wizard-bottom-safe-lg{padding-bottom:calc(var(--wizard-mobile-nav-height,82px) + env(safe-area-inset-bottom) + 1.25rem)}
}
@media (min-width: 992px){
  body.has-mobile-bottom-nav .editor,.wizard-bottom-safe,.wizard-bottom-safe-sm,.wizard-bottom-safe-lg{padding-bottom:0}
}


/* Defensive guard so the prior in-page bottom nav can never re-appear. */
.home-md-bottom-nav,[class*="home-md-bottom-nav"]{display:none!important;visibility:hidden!important;pointer-events:none!important;max-height:0!important;overflow:hidden!important}

/* Shared Wizard Skin Neon Social Command Center utilities */
.wizard-social-shell{max-width:760px;margin:0 auto;padding:0 .9rem 1rem;display:grid;gap:.95rem}
.wizard-social-hero,.wizard-social-card,.wizard-social-action-card,.wizard-social-toolbar,.wizard-social-empty,.wizard-social-pulse{background:linear-gradient(160deg,rgba(22,27,50,.94),rgba(12,16,35,.92));border:1px solid rgba(126,204,255,.2);border-radius:18px;box-shadow:0 14px 36px rgba(0,0,0,.36),0 0 0 1px rgba(90,164,255,.08) inset;backdrop-filter:blur(8px)}
.wizard-social-hero{padding:1rem 1rem 1.05rem;border-color:rgba(188,132,255,.32)}
.wizard-social-card{padding:1rem}
.wizard-social-grid{display:grid;grid-template-columns:1fr;gap:.8rem}
.wizard-social-pulse-strip{display:flex;gap:.6rem;overflow-x:auto;padding:.1rem .1rem .25rem;-webkit-overflow-scrolling:touch;scrollbar-width:none}
.wizard-social-pulse-strip::-webkit-scrollbar{display:none}
.wizard-social-pulse{flex:0 0 auto;width:132px;min-height:120px;padding:.72rem;display:flex;flex-direction:column;justify-content:space-between}
.wizard-social-action-card{padding:.8rem;min-height:64px;display:flex;align-items:center;gap:.65rem}
.wizard-social-toolbar{padding:.68rem;display:flex;flex-wrap:wrap;gap:.55rem}
.wizard-social-empty{padding:1.2rem;text-align:center;color:rgba(214,226,255,.86);border-style:dashed}
@media (min-width:768px){.wizard-social-shell{max-width:860px;padding-inline:1rem}.wizard-social-grid{grid-template-columns:repeat(2,minmax(0,1fr))}}
/* === Signed-in home: social-app redesign ============================== */
body.home-modern-auth{background:radial-gradient(circle at 20% -10%,rgba(112,86,255,.18),transparent 55%),radial-gradient(circle at 110% 12%,rgba(64,196,255,.16),transparent 60%),#06081a}
/* Single mobile bottom-safe-area rule for the authenticated homepage. */
.social-home-container{max-width:680px;margin:0 auto;padding:0 .85rem calc(var(--wizard-mobile-nav-height,82px) + env(safe-area-inset-bottom) + .9rem);position:relative;overflow-x:hidden}
.social-home{display:flex;flex-direction:column;gap:.85rem;padding-top:.6rem}
.social-home a{color:inherit;text-decoration:none}

.social-home__hero{display:flex;align-items:center;gap:.7rem;padding:.25rem .15rem .1rem}
.social-home__avatar{width:46px;height:46px;border-radius:50%;overflow:hidden;background:linear-gradient(140deg,#8be7ff,#be93ff);display:grid;place-items:center;font-weight:800;color:#0a0f1e;font-size:1.05rem;flex-shrink:0;box-shadow:0 6px 16px rgba(0,0,0,.32)}
.social-home__avatar img{width:100%;height:100%;object-fit:cover;display:block}
.social-home__avatar.is-fallback img{display:none}
.social-home__avatar.is-fallback::after{content:attr(data-initial);font-size:1.1rem;font-weight:800;color:#0a0f1e}
.social-home__hello{flex:1;min-width:0}
.social-home__kicker{margin:0;font-size:.62rem;letter-spacing:.18em;text-transform:uppercase;color:rgba(190,210,255,.65);font-weight:600}
.social-home__title{margin:0;font-size:1.35rem;font-weight:800;line-height:1.15;color:#f3f7ff;letter-spacing:-.01em;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.social-home__hero-actions{display:flex;gap:.4rem}
.social-home__icon-btn{position:relative;width:42px;height:42px;display:grid;place-items:center;border-radius:50%;background:rgba(255,255,255,.06);border:1px solid rgba(255,255,255,.08);color:#e7eeff;transition:background .15s ease,border-color .15s ease}
.social-home__icon-btn:hover,.social-home__icon-btn:focus-visible{background:rgba(255,255,255,.12);border-color:rgba(180,210,255,.32);outline:none}
.social-home__icon-btn .material-symbols-outlined{font-size:1.35rem}
.social-home__icon-btn.is-flagged{background:linear-gradient(140deg,rgba(110,228,255,.22),rgba(190,130,255,.22));border-color:rgba(190,130,255,.45)}
.social-home__icon-badge{position:absolute;top:-4px;right:-4px;min-width:18px;height:18px;padding:0 5px;border-radius:999px;background:linear-gradient(90deg,#ff7ab1,#ff9d52);color:#10131f;font-size:.66rem;font-weight:800;display:inline-flex;align-items:center;justify-content:center;box-shadow:0 0 0 2px #06081a}

.social-home__stories{margin:0 -.35rem;overflow:hidden}
.social-home__stories-track{display:flex;gap:.55rem;overflow-x:auto;overflow-y:hidden;padding:.2rem .35rem .35rem;-webkit-overflow-scrolling:touch;scroll-snap-type:x proximity;scrollbar-width:none;align-items:stretch}
.social-home__stories-track::-webkit-scrollbar{display:none}
.social-story{flex:0 0 128px;scroll-snap-align:start;width:128px;min-height:148px;padding:.65rem .65rem .7rem;border-radius:18px;display:flex;flex-direction:column;justify-content:flex-start;gap:.25rem;background:linear-gradient(160deg,rgba(28,32,58,.92),rgba(15,18,36,.92));border:1px solid rgba(132,212,255,.18);color:#eef3ff;position:relative;overflow:hidden;text-align:left;cursor:pointer;font-family:inherit}
.social-story-form{margin:0;flex:0 0 128px;display:block}
.social-story-form .social-story{width:100%;min-height:148px}
button.social-story{font:inherit}
.social-story--add{background:linear-gradient(150deg,rgba(110,228,255,.18),rgba(190,130,255,.22));border-color:rgba(190,130,255,.45);align-items:center;justify-content:center;text-align:center}
.social-story__ring{width:54px;height:54px;border-radius:50%;display:grid;place-items:center;background:rgba(255,255,255,.08);border:1.5px dashed rgba(255,255,255,.45);margin-bottom:.25rem}
.social-story__ring--plus .material-symbols-outlined{font-size:1.6rem;color:#fff}
.social-story__label{font-weight:700;font-size:.82rem}
.social-story__icon{font-size:2.5rem;color:rgba(232,242,255,.92)}
.social-story__big{font-size:1.6rem;font-weight:800;line-height:1.05}
.social-story__tag{font-size:.72rem;color:rgba(220,232,255,.78);font-weight:600;text-transform:uppercase;letter-spacing:.04em;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;max-width:100%}
.social-story__sub{font-size:.7rem;color:rgba(214,228,255,.72);line-height:1.25;display:-webkit-box;-webkit-box-orient:vertical;-webkit-line-clamp:2;overflow:hidden}
.social-story__headline{font-size:.86rem;font-weight:700;line-height:1.2;display:-webkit-box;-webkit-box-orient:vertical;-webkit-line-clamp:2;overflow:hidden}
.social-story__chip{align-self:flex-start;display:inline-flex;padding:.12rem .45rem;border-radius:999px;background:rgba(120,228,255,.18);color:#cfeaff;font-size:.6rem;font-weight:700;letter-spacing:.06em;text-transform:uppercase}
.social-story--weather{background:linear-gradient(155deg,rgba(45,90,170,.55),rgba(20,28,60,.85))}
.social-story--weather.social-story--sunny{background:linear-gradient(155deg,rgba(255,170,80,.45),rgba(60,30,15,.85))}
.social-story--weather.social-story--rainy{background:linear-gradient(155deg,rgba(70,140,210,.55),rgba(15,30,55,.9))}
.social-story--weather.social-story--snowy{background:linear-gradient(155deg,rgba(150,200,240,.5),rgba(20,30,55,.9))}
.social-story--weather.social-story--foggy{background:linear-gradient(155deg,rgba(140,150,170,.4),rgba(20,25,42,.85))}
.social-story--announce{background:linear-gradient(155deg,rgba(255,140,200,.28),rgba(60,20,55,.85));border-color:rgba(255,140,200,.4)}
.social-story--agenda{background:linear-gradient(155deg,rgba(120,228,255,.22),rgba(15,40,68,.9))}
.social-story--cta{background:linear-gradient(155deg,rgba(190,130,255,.28),rgba(36,15,68,.9));border-color:rgba(190,130,255,.45)}
.social-story--soft{background:linear-gradient(160deg,rgba(28,32,58,.88),rgba(15,18,36,.92))}
.social-story--vibe{padding:.65rem .65rem .7rem;background:linear-gradient(155deg,rgba(28,32,58,.92),rgba(15,18,36,.92))}
.social-story--vibe .home-modern-scope-switch{display:none}
.social-story--vibe .home-modern-section-head{padding:0;margin:0 0 .3rem}
.social-story--vibe .home-modern-section-title{font-size:.68rem;letter-spacing:.06em;text-transform:uppercase;color:rgba(220,232,255,.72);font-weight:700}
.social-story--vibe .home-modern-vibe-live{font-size:.6rem;padding:.05rem .35rem;border-radius:999px;background:rgba(102,230,150,.18);color:#aef3c5}
.social-story--vibe .home-modern-vibe-body{padding:0}
.social-story--vibe .home-modern-vibe-kicker{display:none}
.social-story--vibe .home-modern-vibe-marquee{height:78px;overflow:hidden;border:none;border-radius:0;background:transparent;mask-image:linear-gradient(180deg,#000 70%,transparent)}
.social-story--vibe .home-modern-vibe-marquee-track{flex-direction:column;display:flex;gap:.1rem;padding:0;animation:none;min-width:0;width:100%}
.social-story--vibe .home-modern-vibe-marquee-track > a:nth-child(n+4){display:none}
.social-story--vibe .home-modern-vibe-marquee-item{font-size:.7rem;line-height:1.2;padding:.1rem 0;color:rgba(228,240,255,.88);border:none;background:transparent;text-align:left;display:-webkit-box;-webkit-box-orient:vertical;-webkit-line-clamp:1;overflow:hidden;white-space:normal;text-overflow:ellipsis}
.social-story--vibe .home-modern-vibe-copy{padding:.15rem 0 0;font-size:.7rem;color:rgba(214,228,255,.72)}


.social-agenda-panel{margin:.2rem 0 .35rem;padding:.7rem .75rem;border-radius:16px;background:linear-gradient(155deg,rgba(22,26,50,.92),rgba(13,16,32,.95));border:1px solid rgba(126,194,255,.14)}
.social-agenda-panel__head{display:flex;align-items:center;justify-content:space-between;gap:.6rem;margin-bottom:.45rem}
.social-agenda-panel__head h3{margin:0;font-size:.9rem;font-weight:800;color:#eaf1ff}
.social-agenda-panel__close{border:1px solid rgba(160,200,255,.25);background:rgba(255,255,255,.04);color:#cfe5ff;border-radius:999px;padding:.2rem .6rem;font-size:.75rem}
.social-agenda-panel__list{list-style:none;padding:0;margin:0;display:grid;gap:.45rem}
.social-agenda-panel__item{display:grid;gap:.08rem;padding:.45rem .52rem;border-radius:12px;background:rgba(255,255,255,.04);border:1px solid rgba(160,200,255,.14)}
.social-agenda-panel__time{font-size:.68rem;font-weight:700;color:#9adcff;text-transform:uppercase;letter-spacing:.03em}
.social-agenda-panel__title{font-size:.82rem;color:#eef3ff}
button.social-story{border:0}
.social-composer{display:flex;align-items:center;gap:.55rem;padding:.55rem .7rem;border-radius:999px;background:linear-gradient(160deg,rgba(28,32,58,.85),rgba(15,18,36,.88));border:1px solid rgba(160,200,255,.15);box-shadow:0 8px 20px rgba(0,0,0,.22)}
.social-composer__avatar{width:36px;height:36px;border-radius:50%;overflow:hidden;display:grid;place-items:center;background:linear-gradient(140deg,#8be7ff,#be93ff);color:#0a0f1e;font-weight:800;font-size:.85rem;flex-shrink:0}
.social-composer__avatar img{width:100%;height:100%;object-fit:cover;display:block}
.social-composer__avatar.is-fallback img{display:none}
.social-composer__avatar.is-fallback::after{content:attr(data-initial)}
.social-composer__prompt{flex:1;min-width:0;font-size:.92rem;color:rgba(214,228,255,.72);padding:.45rem .65rem;border-radius:999px;background:rgba(255,255,255,.05);border:1px solid rgba(255,255,255,.06);white-space:nowrap;overflow:hidden;text-overflow:ellipsis;text-decoration:none}
.social-composer__prompt:hover,.social-composer__prompt:focus-visible{background:rgba(255,255,255,.08);color:#eaf1ff;outline:none}
.social-composer__btn{width:38px;height:38px;border-radius:50%;display:grid;place-items:center;background:linear-gradient(140deg,#6ee8ff,#bb8eff);color:#091022;flex-shrink:0;box-shadow:0 4px 12px rgba(150,120,255,.42)}
.social-composer__btn .material-symbols-outlined{font-size:1.2rem;color:#050505;-webkit-text-fill-color:#050505}

.social-feed{display:flex;flex-direction:column;gap:.75rem;margin-top:.15rem}
.social-feed__head{display:flex;align-items:baseline;justify-content:space-between;padding:0 .15rem}
.social-feed__title{margin:0;font-size:1rem;font-weight:800;color:#eaf1ff;letter-spacing:-.005em}
.social-feed__count{font-size:.72rem;color:#9adcff;font-weight:600}
.social-feed__list{list-style:none;margin:0;padding:0;display:flex;flex-direction:column;gap:.65rem}
.social-home-short-list{display:grid;gap:.8rem}
.social-home-short-card .short-card{min-height:0;height:auto;border-radius:20px;overflow:hidden;background:linear-gradient(155deg,rgba(22,26,50,.92),rgba(13,16,32,.95));border:1px solid rgba(126,194,255,.14);box-shadow:0 10px 24px rgba(0,0,0,.24)}
.social-home-short-card .short-card__media{min-height:0;height:auto}
.social-home-short-card .short-card__media-frame{position:relative;inset:auto;aspect-ratio:16/10;min-height:0;max-height:260px;border-radius:18px 18px 0 0;overflow:hidden}
.social-home-short-card .short-card__media-image,.social-home-short-card .short-card__video,.social-home-short-card .short-card__media-frame iframe{width:100%;height:100%;object-fit:contain;object-position:center;background:#05070d}
.social-home-short-card .short-card__overlay{position:static;inset:auto;background:transparent;padding:.7rem .8rem .8rem}
.social-home-short-card .short-card__header{position:static;padding:0;margin-bottom:.45rem}
.social-home-short-card .short-card__footer{position:static;padding:0}
.social-home-short-card .short-card__caption{display:-webkit-box;-webkit-box-orient:vertical;-webkit-line-clamp:2;overflow:hidden;font-size:.9rem;line-height:1.35;margin:0 0 .55rem;border:0;padding:0;border-radius:0;background:transparent}
.social-home-short-card .short-card__actions{position:static;flex-direction:row;align-items:center;gap:.9rem;margin-top:.15rem}
.social-home-short-card .short-card__rail-item{flex-direction:row;gap:.34rem}
.social-home-short-card .short-card__action-btn--side{width:34px;height:34px;min-width:34px;min-height:34px;box-shadow:none;-webkit-backdrop-filter:none;backdrop-filter:none}
.social-home-short-card .short-card__action-icon{font-size:1.12rem}
.social-home-short-card .short-card__rail-count{color:rgba(214,228,255,.82);text-shadow:none}
.social-post{display:flex;gap:.6rem;padding:.75rem .8rem;border-radius:20px;background:linear-gradient(155deg,rgba(22,26,50,.92),rgba(13,16,32,.95));border:1px solid rgba(126,194,255,.12);box-shadow:0 10px 24px rgba(0,0,0,.22)}
.social-post__avatar{position:relative;width:40px;height:40px;border-radius:50%;overflow:hidden;flex-shrink:0;background:linear-gradient(140deg,#8be7ff,#be93ff);display:grid;place-items:center;color:#0a0f1e;font-weight:800;font-size:.92rem}
.social-post__avatar img{width:100%;height:100%;object-fit:cover;display:block}
.social-post__avatar.is-fallback img{display:none}
.social-post__avatar.is-fallback::after{content:attr(data-initial)}
.social-post__body{flex:1;min-width:0;display:flex;flex-direction:column;gap:.4rem}
.social-post__head{display:flex;align-items:baseline;gap:.4rem}
.social-post__name{font-weight:700;font-size:.92rem;color:#eaf1ff}
.social-post__meta{font-size:.7rem;color:rgba(214,228,255,.55)}
.social-post__text{display:block;font-size:.94rem;line-height:1.4;color:rgba(232,240,255,.92);text-decoration:none;display:-webkit-box;-webkit-box-orient:vertical;-webkit-line-clamp:4;overflow:hidden}
.social-post__text:hover{color:#fff}
.social-post__media{display:flex;position:relative;border-radius:14px;overflow:hidden;background:radial-gradient(circle at 50% 40%,rgba(110,228,255,.08),rgba(0,0,0,.85));border:1px solid rgba(126,194,255,.08);max-height:320px;min-height:160px;align-items:center;justify-content:center}
.social-post__media img,.social-post__media video{max-width:100%;max-height:320px;width:auto;height:auto;object-fit:contain;object-position:center;display:block}
.social-post__media--video img,.social-post__media--video video{width:100%;max-height:320px;object-fit:cover;object-position:center}
.social-post__play{position:absolute;inset:0;margin:auto;font-size:3rem;color:rgba(255,255,255,.92);pointer-events:none;text-shadow:0 4px 16px rgba(0,0,0,.6);width:fit-content;height:fit-content}
.social-post__media-fallback{position:absolute;inset:0;display:none;flex-direction:column;align-items:center;justify-content:center;gap:.35rem;background:linear-gradient(155deg,rgba(34,40,72,.92),rgba(15,18,36,.95));color:rgba(214,228,255,.78);font-size:.82rem;font-weight:600;text-align:center;padding:.6rem}
.social-post__media-fallback .material-symbols-outlined{font-size:1.7rem;color:rgba(190,130,255,.7)}
.social-post__media.is-fallback img,.social-post__media.is-fallback video,.social-post__media.is-fallback .social-post__play{display:none}
.social-post__media.is-fallback .social-post__media-fallback{display:flex}
.social-post__media-state{display:flex;flex-direction:column;align-items:center;justify-content:center;gap:.3rem;color:rgba(214,228,255,.78);font-size:.82rem;font-weight:600;text-align:center;padding:1.6rem .8rem;width:100%}
.social-post__media-state .material-symbols-outlined{font-size:1.7rem;color:rgba(110,228,255,.78)}
.social-post__foot{display:flex;align-items:center;gap:1rem;padding-top:.1rem}
.social-post__stat{display:inline-flex;align-items:center;gap:.25rem;font-size:.78rem;color:rgba(214,228,255,.7)}
.social-post__stat .material-symbols-outlined{font-size:1rem}
.social-post__open{margin-left:auto;font-size:.78rem;font-weight:700;color:#9adcff}
.social-post__open:hover{color:#fff}
.social-feed__more{align-self:center;display:inline-flex;align-items:center;gap:.3rem;margin:1rem auto 0;padding:.5rem 1rem;border-radius:999px;background:rgba(255,255,255,.05);border:1px solid rgba(160,200,255,.18);font-size:.82rem;font-weight:600;color:#cfe5ff}
.social-feed__more:hover,.social-feed__more:focus-visible{background:rgba(255,255,255,.1);color:#fff;outline:none}

.social-feed__empty{padding:1.5rem 1rem;text-align:center;border-radius:20px;background:linear-gradient(155deg,rgba(22,26,50,.92),rgba(13,16,32,.95));border:1px solid rgba(126,194,255,.12)}
.social-feed__empty .material-symbols-outlined{font-size:2.25rem;color:rgba(190,130,255,.7)}
.social-feed__empty-title{margin:.55rem 0 .25rem;font-size:1rem;font-weight:800;color:#eaf1ff}
.social-feed__empty-sub{margin:0 0 .85rem;font-size:.82rem;color:rgba(214,228,255,.66)}
.social-feed__empty-cta{display:inline-flex;padding:.55rem 1.1rem;border-radius:999px;background:linear-gradient(140deg,#6ee8ff,#bb8eff);color:#091022;font-weight:700;font-size:.85rem}
.social-feed__empty-cta:hover{transform:translateY(-1px)}

@media (min-width:680px){
  .social-home{gap:1.1rem}
  .social-home__stories{margin:0}
  .social-story{width:148px;min-height:160px}
  .social-post__media,.social-post__media img,.social-post__media video,.social-post__media--video img,.social-post__media--video video{max-height:380px}
}
@media (min-width:768px){
  .social-home-short-card .short-card__media-frame{left:auto;right:auto;width:100%;transform:none}
}
@media (min-width:992px){
  .social-home-container{padding-bottom:1.25rem}
}
@media (max-width:430px){
  .social-home__title{font-size:1.25rem}
  .social-home-short-card .short-card__caption{font-size:.86rem}
}
@media (max-width:390px){
  .social-home-container{padding-left:.7rem;padding-right:.7rem}
  .social-home__avatar{width:42px;height:42px;font-size:1rem}
  .social-home__title{font-size:1.18rem}
  .social-home__icon-btn{width:40px;height:40px}
  .social-story{width:122px;min-height:140px;padding:.55rem}
  .social-composer__prompt{font-size:.86rem}
  .social-post{padding:.65rem;border-radius:18px}
}
@media (max-width:360px){
  .social-home-container{padding-left:.55rem;padding-right:.55rem}
  .social-home__title{font-size:1.1rem}
  .social-story{width:114px;min-height:134px}
  .social-story__big{font-size:1.4rem}
  .social-post{padding:.55rem .6rem;gap:.5rem}
  .social-post__avatar{width:36px;height:36px}
}
@media (max-width:320px){
  .social-home__hero-actions{gap:.25rem}
  .social-home__icon-btn{width:36px;height:36px}
  .social-home__icon-btn .material-symbols-outlined{font-size:1.2rem}
  .social-story{width:108px;min-height:128px}
  .social-post__text{font-size:.88rem}
}

.social-news-panel__content{display:grid;gap:.65rem;padding:.35rem 0 .15rem;overflow:hidden}
.social-news-panel__stories{--news-card-width:min(280px,calc(100% - 1.5rem));box-sizing:border-box;width:100%;display:flex;gap:.55rem;overflow-x:auto;overflow-y:hidden;padding:.1rem .75rem .35rem;-webkit-overflow-scrolling:touch;scroll-snap-type:x mandatory;scrollbar-width:none;justify-content:flex-start;scroll-padding-inline:.75rem;overscroll-behavior-x:contain;scroll-behavior:smooth}
.social-news-panel__stories::-webkit-scrollbar{display:none}
.social-news-panel__stories::after{content:"";flex:0 0 .75rem}
.social-news-panel__story-card{flex:0 0 var(--news-card-width);display:flex;flex-direction:column;gap:.4rem;scroll-snap-align:start;min-height:146px;padding:.75rem .72rem;border-radius:16px;background:linear-gradient(160deg,rgba(34,39,70,.95),rgba(15,18,36,.95));border:1px solid rgba(146,206,255,.25);color:#eef3ff;text-decoration:none;box-shadow:0 10px 24px rgba(0,0,0,.28);opacity:.72;transition:opacity .2s ease,transform .2s ease,border-color .2s ease;text-align:center;overflow:hidden}
.social-news-panel__story-card:hover,.social-news-panel__story-card:focus-visible{background:linear-gradient(160deg,rgba(53,65,110,.95),rgba(20,25,48,.95));border-color:rgba(172,222,255,.45);color:#fff;opacity:1;transform:translateY(-1px)}
.social-news-panel__story-card.is-active{opacity:1}
.social-news-panel__story-kicker{font-size:.64rem;text-transform:uppercase;letter-spacing:.08em;color:rgba(194,228,255,.72);font-weight:700}
.social-news-panel__story-title{font-size:.92rem;font-weight:700;line-height:1.32;display:-webkit-box;-webkit-box-orient:vertical;-webkit-line-clamp:4;overflow:hidden;overflow-wrap:anywhere}
.social-news-panel__story-meta{margin-top:auto;font-size:.7rem;color:rgba(208,224,255,.74);text-align:center}
.social-news-panel__dots{display:flex;justify-content:center;gap:.34rem;min-height:.45rem}
.social-news-panel__dot{width:.36rem;height:.36rem;border-radius:999px;background:rgba(182,198,235,.35);transition:transform .2s ease,background-color .2s ease}
.social-news-panel__dot.is-active{background:rgba(126,231,255,.9);transform:scale(1.2)}
@media (prefers-reduced-motion: reduce){.social-news-panel__stories{scroll-behavior:auto}.social-news-panel__dot{transition:none}.social-news-panel__story-card{transition:none}}


/* Spaces visual refresh */
.spaces-theme{position:relative;background:radial-gradient(circle at 10% -5%,rgba(120,86,255,.25),transparent 45%),radial-gradient(circle at 100% 0,rgba(72,206,255,.2),transparent 45%),#070a1b;overflow-x:hidden}
.spaces-shell{position:relative;z-index:1;max-width:1280px;padding-bottom:calc(88px + env(safe-area-inset-bottom))}
.spaces-command,.space-zone-card,.space-card,.space-thread-card,.space-reply-card{background:linear-gradient(160deg,rgba(22,26,50,.88),rgba(11,15,31,.92));border:1px solid rgba(130,195,255,.2);border-radius:20px;box-shadow:0 16px 40px rgba(0,0,0,.25)}
.spaces-command{padding:1rem}
.spaces-command__row{display:flex;flex-direction:column;gap:1rem}
.space-search__row{display:flex;flex-direction:column;gap:.55rem}
.space-search .form-control{border-radius:999px;background:rgba(10,15,30,.88);border:1px solid rgba(146,195,255,.3);color:#ebf2ff;padding:.7rem .95rem}
.space-search .form-control:focus{box-shadow:0 0 0 .2rem rgba(110,228,255,.2);border-color:rgba(135,216,255,.6)}
.spaces-filter-rail{display:flex;gap:.55rem;overflow-x:auto;padding:.2rem;scrollbar-width:none}
.spaces-filter-rail::-webkit-scrollbar{display:none}
.spaces-filter-chip{flex:0 0 auto;padding:.5rem .85rem;border-radius:999px;border:1px solid rgba(140,186,255,.28);color:#d4e6ff;text-decoration:none;background:rgba(255,255,255,.04)}
.spaces-filter-chip.active,.spaces-filter-chip:hover{background:linear-gradient(145deg,rgba(108,228,255,.3),rgba(188,130,255,.28));color:#fff}
.spaces-grid{display:grid;grid-template-columns:1fr;gap:.9rem}
.space-card{padding:1rem;transition:transform .18s ease,border-color .18s ease;min-height:100%}
.space-card:hover{transform:translateY(-2px);border-color:rgba(187,140,255,.6)}
.space-card-desc,.space-thread-preview{color:rgba(214,228,255,.8)}
.space-open-cta{display:inline-flex;padding:.35rem .75rem;border-radius:999px;background:rgba(154,210,255,.16);font-weight:700}
.space-empty-state{padding:1.1rem;border-radius:18px;border:1px dashed rgba(150,203,255,.35);background:rgba(255,255,255,.03);color:#d8e9ff}
.space-zone-card--about{position:sticky;top:1rem}
.space-composer-summary{list-style:none;cursor:pointer;font-weight:700}
.space-composer-summary::-webkit-details-marker{display:none}
.space-thread-card{padding:.8rem .95rem}
.space-thread-summary{display:flex;justify-content:space-between;gap:.9rem;cursor:pointer;list-style:none}
.space-thread-summary::-webkit-details-marker{display:none}
.space-thread-toggle{align-self:center;padding:.35rem .75rem;border-radius:999px;background:rgba(255,255,255,.08)}
.space-thread-expanded{margin-top:.8rem;padding-top:.7rem;border-top:1px solid rgba(255,255,255,.12)}
.space-media{background:#04070f;border-radius:14px;object-fit:contain;max-height:420px}
.space-media--reply{max-height:260px}
.space-back-pill{display:inline-flex;align-items:center;padding:.35rem .75rem;border-radius:999px;background:rgba(255,255,255,.06);border:1px solid rgba(144,193,255,.22);text-decoration:none;color:#d8e8ff}
.space-reply-card{margin-left:clamp(0rem,var(--space-reply-indent),3rem);padding-left:1rem;border-left:1px solid rgba(162,206,255,.22)}
@media (min-width:768px){.spaces-grid{grid-template-columns:repeat(2,minmax(0,1fr))}.space-search__row{flex-direction:row}.space-search__row .form-control{flex:1}}
@media (min-width:1200px){.spaces-grid{grid-template-columns:repeat(3,minmax(0,1fr))}.spaces-command{padding:1.2rem 1.3rem}.spaces-command__row{flex-direction:row;justify-content:space-between;align-items:flex-start}}

/* Spaces neon social shell alignment */
.spaces-theme .wizard-social-shell{max-width:1120px;gap:1rem}
.spaces-theme .spaces-hero{display:grid;grid-template-columns:minmax(0,1fr);gap:.6rem;padding:.7rem .85rem}
.spaces-theme .spaces-hero__intro{display:flex;flex-direction:column;gap:.1rem}
.spaces-theme .spaces-hero__count{font-size:.8rem;color:var(--space-text-soft)}
.spaces-theme .spaces-create-panel{padding:.85rem}
.spaces-theme .spaces-command__stats{display:flex;flex-wrap:wrap;gap:.45rem}
.spaces-theme .space-search__row{display:flex;flex-direction:column;gap:.55rem}
.spaces-theme .spaces-filter-rail{padding:.15rem .1rem .25rem;gap:.5rem}
.spaces-theme .spaces-filter-chip{background:rgba(255,255,255,.05)}
.spaces-theme .spaces-grid{grid-template-columns:1fr;gap:.7rem}
.spaces-theme .space-card{padding:.78rem .82rem}
.spaces-theme .space-card__head{display:grid;grid-template-columns:auto minmax(0,1fr) auto;gap:.6rem;align-items:center;margin-bottom:.5rem}
.spaces-theme .space-card__avatar{width:44px;height:44px;border-radius:13px;display:grid;place-items:center;font-weight:800;color:#f5f9ff;background:linear-gradient(145deg,rgba(97,233,255,.3),rgba(190,130,255,.34));border:1px solid rgba(176,225,255,.34);box-shadow:0 0 20px rgba(108,215,255,.2)}
.spaces-theme .space-card__title{font-size:1rem;font-weight:700;color:#f4f8ff;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.spaces-theme .space-card__slug{font-size:.8rem;color:rgba(200,215,255,.8);white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.spaces-theme .space-card-desc{font-size:.92rem;line-height:1.45;min-height:2.7em}
.spaces-theme .space-open-cta{font-weight:700}
.spaces-theme .space-empty-state{grid-column:1/-1}
@media (min-width:768px){.spaces-theme .spaces-grid{grid-template-columns:repeat(2,minmax(0,1fr))}.spaces-theme .space-search__row{flex-direction:row}.spaces-theme .space-search__row .form-control{flex:1}.spaces-theme .spaces-hero{grid-template-columns:minmax(0,1fr) 300px;align-items:start}}
@media (min-width:1200px){.spaces-theme .spaces-grid{grid-template-columns:repeat(3,minmax(0,1fr))}}

/* Forms Neon Social Command Center */
.wizard-social-shell--forms{max-width:980px}
.wizard-social-kicker{font-size:.72rem;letter-spacing:.09em;text-transform:uppercase;color:rgba(201,218,255,.88)}
.wizard-social-hero-actions{display:flex;flex-wrap:wrap;gap:.55rem;margin-top:.7rem}
.wizard-social-chip{display:inline-flex;align-items:center;min-height:36px;padding:.35rem .8rem;border-radius:999px;border:1px solid rgba(130,212,255,.24);background:rgba(18,22,44,.78);color:rgba(227,237,255,.94);white-space:nowrap}
.wizard-social-chip-link{text-decoration:none;font-weight:700}
.forms-card-grid,.forms-response-grid{display:grid;grid-template-columns:1fr;gap:.75rem}
.forms-item-card h3{color:#f5f8ff}
.wizard-social-meta{display:flex;flex-wrap:wrap;gap:.4rem .7rem;color:rgba(206,220,255,.78);font-size:.84rem}
.wizard-social-form-shell .form-control,.wizard-social-form-shell .form-select{min-height:50px}
.wizard-social-form-shell textarea.form-control{min-height:128px}
.wizard-social-sticky-save{position:sticky;bottom:.5rem;background:rgba(8,12,30,.9);border:1px solid rgba(129,206,255,.28);border-radius:14px;padding:.55rem;z-index:3}
.forms-response-card{padding:.85rem;border:1px solid rgba(126,204,255,.18)}
.forms-pre-wrap{white-space:pre-wrap;background:rgba(255,255,255,.03);border:1px solid rgba(140,214,255,.16);border-radius:12px;padding:.85rem}
@media (min-width:768px){.forms-card-grid,.forms-response-grid{grid-template-columns:repeat(2,minmax(0,1fr))}}
@media (max-width:767px){.wizard-social-hero-actions .btn{flex:1 1 calc(50% - .55rem)}.wizard-social-shell--forms .btn{min-height:46px}}

/* Social command center pass: feed/discover/create/billboard */
.wizard-social-shell--feed{max-width:940px;padding-bottom:.5rem;gap:.75rem}
.wizard-social-feed-hero{padding:.9rem 1rem}
.wizard-social-feed-strip{padding-bottom:.35rem}
.short-deck .wizard-social-empty{margin:.4rem auto 1rem;max-width:860px}

.wizard-social-shell--composer{max-width:860px;padding-top:.2rem;gap:.65rem}
.create-post-page__hero{padding:.95rem 1rem}
.create-post-page__form{padding:.9rem .9rem var(--wizard-sticky-submit-clearance)}
.create-post-page__form textarea.form-control{min-height:180px;font-size:1rem}
.create-post-page__form .form-control,.create-post-page__form .form-select{min-height:50px}
.create-post-page__ai-actions .btn{border-color:rgba(133,214,255,.35);font-size:.78rem;padding:.26rem .6rem}
.create-post-page__submit-row .btn{font-weight:700}
@media (max-width:991.98px){.create-post-page .wizard-social-sticky-save{bottom:var(--wizard-sticky-submit-offset)}}

.wizard-social-shell--discover{max-width:860px;gap:.8rem}
.discover-page__search{align-items:center}
.discover-page__search-field{flex:1 1 260px;min-width:0}
.discover-page__search .form-control{margin:0}
.discover-page__results{display:grid;gap:.75rem}
.discover-user-card{display:flex;align-items:center;justify-content:space-between;gap:.85rem;border-color:rgba(122,207,255,.25)!important}
.discover-user-card__identity{min-width:0;display:grid;gap:.2rem;align-content:center}
.discover-user-card__name{width:max-content;max-width:100%;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.discover-user-card__meta{display:flex;align-items:center;gap:.45rem;min-width:0;flex-wrap:wrap}
.discover-user-card__quote{min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.discover-user-card__action{flex:0 0 auto;margin:0}
.discover-user-card__action .btn{min-width:96px}
.discover-user-card a{color:rgba(228,240,255,.97);text-decoration:none}

.post-card{background:linear-gradient(160deg,rgba(23,27,47,.95),rgba(10,14,31,.94));border:1px solid rgba(128,206,255,.22);box-shadow:0 16px 36px rgba(0,0,0,.34),0 0 0 1px rgba(102,156,255,.09) inset;overflow:hidden}
.post-card .card-header,.post-card .card-footer{background:transparent;border-color:rgba(130,191,255,.2)}
.post-card .card-header{padding:.9rem .95rem .65rem}
.post-card .card-body{padding:.85rem .95rem}
.post-card .card-footer{padding:.7rem .95rem .9rem}
.post-card .post-avatar{width:44px;height:44px;object-fit:cover;border:2px solid rgba(170,221,255,.45)}
.post-card .card-text{color:rgba(228,238,255,.96);line-height:1.45}
.post-card .post-media img,.post-card .post-media video{border-radius:14px;background:rgba(7,10,24,.72)}
.post-card .post-comment-form .form-control{background:rgba(15,19,42,.8);border-color:rgba(126,201,255,.25);color:rgba(235,242,255,.96)}
.post-card .post-actions .btn{min-height:36px}

@media (max-width:767px){
  .wizard-social-shell--feed,.wizard-social-shell--discover,.wizard-social-shell--composer{padding-inline:.75rem}
  .short-deck-page{gap:.65rem}
}

/* Settings + safety neon alignment */
.settings-shell{max-width:860px}
.settings-kicker{font-size:.72rem;letter-spacing:.08em;text-transform:uppercase;color:rgba(194,212,255,.84)}
.settings-card h3,.settings-card h4{font-size:1rem}
.settings-card .list-group-item{background:rgba(255,255,255,.03);border-color:rgba(132,206,255,.2);color:rgba(234,242,255,.94)}
.settings-list{display:grid;gap:.6rem}
.settings-list-row{display:flex;align-items:center;justify-content:space-between;gap:.75rem;padding:.75rem .9rem;border:1px solid rgba(130,204,255,.2);border-radius:14px;background:rgba(255,255,255,.03)}
.settings-page{max-width:860px;margin:0 auto;display:grid;gap:.75rem;padding:0 .9rem 1.1rem}
.settings-page__header{padding:1rem;border-radius:18px;background:linear-gradient(160deg,rgba(22,27,50,.94),rgba(12,16,35,.92));border:1px solid rgba(188,132,255,.3)}
.settings-accordion-item{border:1px solid rgba(126,204,255,.22);border-radius:16px;background:linear-gradient(160deg,rgba(22,27,50,.94),rgba(12,16,35,.92));padding:.2rem .85rem}
.settings-accordion-item>summary{padding:.85rem .1rem;font-weight:700;color:#ecf3ff;cursor:pointer}
.settings-accordion-body{padding:.2rem 0 1rem}
.settings-accordion-body .card{background:rgba(255,255,255,.03);border:1px solid rgba(125,198,255,.2)}
@media (max-width:991.98px){body.has-mobile-bottom-nav .settings-page{padding-bottom:calc(var(--wizard-mobile-nav-height,82px) + env(safe-area-inset-bottom) + .95rem)}}


.pocket-toolbar + .pocket-composer{margin-top:-.15rem}

/* profile refinement */
.profile-shell{padding-bottom:calc(var(--wizard-mobile-nav-height,82px) + env(safe-area-inset-bottom) + .8rem)}
.profile-hero{padding:.7rem;overflow:hidden;background:var(--surface);border:1px solid color-mix(in srgb,var(--border) 82%,transparent)}
.profile-hero__core{display:grid;grid-template-columns:1fr;gap:.4rem;align-items:center}
.profile-avatar-panel{position:relative;width:64px;height:64px;display:grid;place-items:center}
.profile-avatar-ring{display:none}
.profile-avatar__image{position:relative;z-index:1;background:var(--surface-2);padding:2px;border:1px solid color-mix(in srgb,var(--border) 72%,transparent);box-shadow:none}
.profile-kicker{font-size:.73rem;letter-spacing:.06em;text-transform:uppercase;color:var(--text-muted)}
.profile-title{font-size:clamp(1.15rem,3.8vw,1.45rem);font-weight:700;color:var(--text)}
.profile-subtitle,.profile-headline{color:var(--text-muted)}
.profile-message-pill .material-symbols-outlined{font-size:18px}
.profile-stat-strip{margin-top:.1rem;border:1px solid color-mix(in srgb,var(--border) 82%,transparent);border-radius:12px;overflow:hidden;background:var(--surface-2)}
.profile-action-row{display:flex;flex-wrap:wrap;gap:.4rem}
.profile-action-row .btn{padding:.38rem .7rem;font-size:.9rem}
.profile-stats__value{font-weight:700;color:var(--text);text-shadow:none;text-decoration:none}
.profile-stats__label{font-size:.72rem;text-transform:uppercase;letter-spacing:.04em;color:var(--text-muted);text-decoration:none}
.profile-section-tabs{display:flex;gap:.5rem;overflow:auto}
.profile-section-tab{padding:.42rem .8rem;border-radius:999px;border:1px solid color-mix(in srgb,var(--border) 82%,transparent);text-decoration:none;color:var(--text-muted);background:var(--surface)}
.profile-section-tab.active{background:var(--surface-2);border-color:color-mix(in srgb,var(--border) 92%,transparent);color:var(--text)}
.profile-post-grid{display:grid;gap:.65rem}
.profile-post-grid .post-card{margin-bottom:0;background:var(--surface);border-color:color-mix(in srgb,var(--border) 82%,transparent)}
.profile-media-card{padding:.72rem}
.profile-empty-state--compact{padding:.7rem .8rem}
.profile-media-grid{display:grid;gap:.45rem;grid-template-columns:repeat(3,minmax(0,1fr))}
.profile-media-tile{display:block;border-radius:12px;overflow:hidden;border:1px solid color-mix(in srgb,var(--border) 82%,transparent);background:var(--surface-2);aspect-ratio:1/1}
.profile-media-tile img,.profile-media-tile video{width:100%;height:100%;object-fit:cover;display:block}
.profile-meta-list{display:grid;gap:.55rem}
.profile-meta-item{display:flex;align-items:center;gap:.45rem;color:var(--text)}
.profile-meta-item .material-symbols-outlined{font-size:18px;color:var(--text-muted)}
.profile-edit-shell .profile-action-row .btn{min-width:140px}

/* spaces controls refinement */
.spaces-theme .spaces-create-panel{padding:0;background:transparent;border:0;box-shadow:none}
.spaces-theme .space-create-toggle{list-style:none;display:inline-flex;align-items:center;gap:.35rem;padding:.42rem .8rem;border-radius:999px;border:1px solid rgba(126,205,255,.25);background:rgba(10,16,34,.72);color:rgba(214,231,255,.93);font-weight:700;cursor:pointer}
.spaces-theme .space-create-toggle::-webkit-details-marker{display:none}
.spaces-theme .space-composer{padding:.9rem;border:1px solid rgba(126,205,255,.25);border-radius:16px;background:linear-gradient(160deg,rgba(17,22,44,.94),rgba(9,12,26,.94))}
.spaces-theme .space-search{padding:.7rem .75rem}
.spaces-theme .space-search__row{display:grid;grid-template-columns:auto 1fr auto;align-items:center;gap:.5rem}
.spaces-theme .space-search__icon{font-size:20px;color:#86dcff}
.spaces-theme .space-search .form-control{min-height:48px}
.spaces-theme .spaces-filter-wrap{padding:.1rem .1rem .25rem}
.spaces-theme .spaces-filter-label{font-size:.73rem;letter-spacing:.09em;text-transform:uppercase;color:rgba(194,212,255,.84)}
.spaces-theme .spaces-filter-chip.active,.spaces-theme .spaces-filter-chip[aria-current='page']{background:linear-gradient(140deg,rgba(97,236,255,.92),rgba(152,115,255,.92));border-color:rgba(157,118,255,.95);color:#031127;box-shadow:0 10px 24px rgba(120,99,255,.34)}

@media (min-width:768px){
  .profile-hero__core{grid-template-columns:auto minmax(0,1fr) auto}
  .profile-action-row{justify-content:flex-end}
  .profile-post-grid{grid-template-columns:repeat(2,minmax(0,1fr))}
}
@media (max-width:767.98px){
  .profile-hero__core{grid-template-columns:auto minmax(0,1fr);grid-template-areas:"avatar identity" "actions actions"}
  .profile-avatar-panel{grid-area:avatar}
  .profile-identity{grid-area:identity}
  .profile-action-row{grid-area:actions}
  .profile-action-row .btn{width:auto;flex:1 1 auto}
  .profile-stat-strip{display:grid;grid-template-columns:repeat(2,minmax(0,1fr))}
  .profile-stat-strip .profile-stats__item{padding:.5rem .6rem;gap:.15rem}
  .profile-media-grid{grid-template-columns:repeat(2,minmax(0,1fr))}
}
@media (prefers-reduced-motion:no-preference){
  .reveal-up{animation:revealUp .28s ease-out both}
  @keyframes revealUp{from{opacity:0;transform:translateY(8px)}to{opacity:1;transform:translateY(0)}}
}

.pocket-filter-pill-icon{padding:.45rem .65rem;min-width:40px}.pocket-filter-pill-icon .material-symbols-outlined{font-size:1.1rem}.pocket-category-pill{display:inline-flex;align-items:center;padding:.2rem .55rem;border-radius:999px;font-size:.74rem;background:rgba(187,123,255,.2);color:#e6cdff;border:1px solid rgba(187,123,255,.45)}

/* Homepage requested alignment updates */
.social-agenda-panel__actions{display:flex;align-items:center;gap:.45rem}
.social-agenda-panel__manage{display:inline-flex;align-items:center;padding:.35rem .65rem;border-radius:999px;border:1px solid rgba(140,212,255,.4);background:transparent;color:#d8ecff;text-decoration:none;font-size:.76rem;font-weight:700;cursor:pointer}
.social-agenda-panel__manage:hover,.social-agenda-panel__manage:focus-visible{color:#fff;background:rgba(120,198,255,.16);outline:none}
.social-news-panel__stories{display:grid;grid-template-columns:1fr;gap:.55rem;overflow:visible;padding:.1rem 0 .2rem;scroll-snap-type:none}
.social-news-panel__stories::after{display:none}
.social-news-panel__story-card{width:100%;min-height:0;text-align:left;opacity:.92}
.social-news-panel__story-title{-webkit-line-clamp:3}
.social-news-panel__story-meta{text-align:left;margin-top:.25rem}
.social-news-panel__dots{display:none}
.mobile-bottom-nav__item{justify-content:flex-start;padding-top:.16rem}
.mobile-bottom-nav__label{margin-top:-.05rem}

/* Pocket + Spaces compact row pass */
.pocket-row-list .pocket-item-card,.pocket-file-card,.space-thread-card,.space-card{border-radius:14px}
.pocket-row-list .pocket-item-card{display:grid;gap:.45rem;padding:.62rem .75rem;min-height:58px}
.pocket-row-list .pocket-preview{margin-top:.1rem!important;font-size:.88rem;line-height:1.3;display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical;overflow:hidden}
.pocket-row-list .pocket-item-title{white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.pocket-row-list .pocket-card-footer,.pocket-file-card .pocket-action-row{justify-content:flex-end;align-items:center;gap:.38rem}
.pocket-icon-btn{width:34px;min-width:34px;height:34px;padding:0;display:inline-flex;align-items:center;justify-content:center}
.pocket-icon-btn .material-symbols-outlined{font-size:1.03rem}
.pocket-empty-state{padding:.9rem}

.spaces-theme .spaces-filter-rail{display:flex;overflow-x:auto;scrollbar-width:none;-webkit-overflow-scrolling:touch}
.spaces-theme .spaces-filter-rail::-webkit-scrollbar{display:none}
.spaces-theme .spaces-filter-chip{padding:.38rem .72rem;font-size:.82rem;min-height:34px}
.spaces-theme .space-card{padding:.62rem .72rem;border-radius:14px}
.spaces-theme .space-card__avatar{width:38px;height:38px;border-radius:10px}
.spaces-theme .space-card-desc{margin-bottom:.35rem!important;font-size:.88rem;display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical;overflow:hidden;min-height:auto}
.spaces-theme .space-thread-card{padding:.5rem .62rem;border-radius:14px}
.spaces-theme .space-thread-summary{padding:.5rem .58rem;gap:.55rem}
.spaces-theme .thread-stat-chip,.spaces-theme .space-stat-chip,.spaces-theme .space-meta-chip{padding:.22rem .48rem;font-size:.72rem}
.spaces-theme .space-thread-preview{font-size:.88rem;display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical;overflow:hidden}
.spaces-theme .space-composer{padding:.72rem .78rem;border-radius:14px}
.spaces-theme .space-zone-card{border-radius:14px}
.spaces-theme .space-reply-card{padding:.65rem .72rem!important;border-radius:12px!important}

[data-theme="wizard-skin"] .pocket-item-card,
[data-theme="wizard-skin"] .pocket-file-card,
[data-theme="wizard-skin"] .space-card,
[data-theme="wizard-skin"] .space-thread-card,
[data-theme="wizard-skin"] .space-zone-card,
[data-theme="wizard-skin"] .space-reply-card{background:linear-gradient(165deg,rgba(14,18,38,.92),rgba(8,10,24,.96));border:1px solid rgba(0,229,255,.18);box-shadow:0 8px 20px rgba(0,0,0,.28),inset 0 1px 0 rgba(255,255,255,.04)}
[data-theme="wizard-skin"] .pocket-item-card:hover,
[data-theme="wizard-skin"] .pocket-file-card:hover,
[data-theme="wizard-skin"] .space-card:hover,
[data-theme="wizard-skin"] .space-thread-summary:hover{border-color:rgba(230,195,95,.45);box-shadow:0 10px 24px rgba(0,0,0,.32),0 0 0 1px rgba(98,227,255,.2)}
[data-theme="wizard-skin"] .pocket-item-meta,
[data-theme="wizard-skin"] .space-card__slug,
[data-theme="wizard-skin"] .space-thread-preview{color:rgba(219,229,250,.76)}

@media (max-width: 767px){
  .pocket-row-list .pocket-card-footer,.pocket-file-card .pocket-action-row{justify-content:flex-start;flex-wrap:wrap}
  .spaces-theme .space-search__row{grid-template-columns:1fr auto}
  .spaces-theme .space-search__icon{display:none}
}

/* Spaces board compact redesign */
.spaces-theme .space-board-shell{max-width:1200px;width:100%}
.spaces-theme .space-board-grid{display:grid;grid-template-columns:minmax(0,1fr);gap:1rem}
.spaces-theme .space-board-header,.spaces-theme .thread-composer-card,.spaces-theme .space-about-card{border-radius:14px;border:1px solid rgba(130,195,255,.2);background:linear-gradient(160deg,rgba(22,26,50,.86),rgba(11,15,31,.9));box-shadow:0 8px 20px rgba(0,0,0,.22)}
.spaces-theme .space-board-actions .btn{min-height:34px}
.spaces-theme .thread-composer-collapsed{width:100%;display:flex;justify-content:space-between;align-items:center;gap:.75rem;border:0;background:transparent;padding:.8rem .95rem;color:rgba(220,230,255,.9)}
.spaces-theme .thread-filter-row{display:flex;gap:.5rem;overflow-x:auto;flex-wrap:nowrap;padding-bottom:.15rem}
.spaces-theme .thread-list{gap:.65rem;background:transparent;border:0}
.spaces-theme .thread-list-item{border:1px solid rgba(130,195,255,.18)!important;background:linear-gradient(180deg,rgba(15,25,45,.9),rgba(8,15,30,.9));border-radius:12px!important;padding:.78rem .85rem;min-width:0}
.spaces-theme .thread-meta,.spaces-theme .thread-meta h3{min-width:0}
.spaces-theme .thread-actions{flex-shrink:0}
.spaces-theme .space-about-card dt{font-weight:700;color:rgba(180,205,245,.85);margin-top:.45rem}
.spaces-theme .space-about-card dd{margin:0;color:rgba(226,236,255,.95)}
.spaces-theme .accordion-item.space-about-card,.spaces-theme .accordion-button{background:transparent;color:inherit;border:0;box-shadow:none}
@media (min-width: 992px){
  .spaces-theme .space-board-grid{grid-template-columns:minmax(0,1fr) 260px}
}

/* Pocket compact row/list refresh */
.pocket-list-group{border-radius:14px;overflow:hidden;border:1px solid rgba(122,209,255,.14)}
.pocket-list-group .list-group-item{background:linear-gradient(160deg,rgba(23,26,45,.95),rgba(16,19,34,.92));border-color:rgba(122,209,255,.14);color:inherit}
.pocket-list-row{display:flex;gap:.75rem;justify-content:space-between;align-items:flex-start;padding:.7rem .8rem}
.pocket-row-main{min-width:0;flex:1;display:grid;gap:.3rem}
.pocket-row-head{display:flex;flex-wrap:wrap;gap:.35rem;align-items:center}
.pocket-row-actions{display:flex;flex-wrap:wrap;gap:.4rem;align-items:center;justify-content:flex-end}
.pocket-row-actions form{margin:0}
.pocket-row-actions .btn{min-height:32px}
.pocket-preview{margin-top:.1rem;padding-top:.35rem;border-top:1px solid rgba(122,209,255,.14);font-size:.86rem;-webkit-line-clamp:2}
.pocket-toolbar{padding:.7rem}
.pocket-item-meta{font-size:.8rem;gap:.35rem .45rem}
.pocket-chip,.pocket-type-pill,.pocket-standard-badge,.pocket-locked-badge{font-size:.72rem;padding:.15rem .5rem}
@media (max-width:767px){.pocket-list-row{flex-direction:column}.pocket-row-actions{width:100%;justify-content:flex-start}.pocket-row-actions .btn,.pocket-row-actions form{flex:1 1 calc(50% - .4rem)}.pocket-row-actions form .btn{width:100%}}
/* Pocket compact row/list pass */
.pocket-shell{gap:.45rem}
.pocket-hero,.pocket-toolbar,.pocket-file-card,.pocket-stat-card{border-radius:12px;box-shadow:0 6px 18px rgba(0,0,0,.24)}
.pocket-hero{padding:.55rem .75rem}
.pocket-toolbar{padding:.6rem .7rem}
.pocket-toolbar-compact{padding:.55rem .65rem}
.pocket-title{font-size:1.2rem}
.pocket-filter-pill{min-height:32px;padding:.32rem .72rem;font-size:.82rem}
.pocket-list-group{border:1px solid rgba(122,209,255,.14);border-radius:12px;overflow:hidden}
.pocket-list-group .list-group-item{background:rgba(14,18,33,.82);border-color:rgba(122,209,255,.12)}
.pocket-list-row{display:flex;gap:.6rem;align-items:flex-start;justify-content:space-between;padding:.58rem .7rem}
.pocket-row-main{min-width:0;display:grid;gap:.2rem;flex:1}
.pocket-row-head{display:flex;flex-wrap:wrap;gap:.35rem}
.pocket-item-meta{font-size:.78rem;gap:.3rem .45rem}
.pocket-chip,.pocket-category-pill{padding:.12rem .5rem;font-size:.74rem}
.pocket-preview{border-top:0;padding-top:0;font-size:.84rem;line-height:1.32;-webkit-line-clamp:2;color:rgba(220,232,255,.84)}
.pocket-row-actions{display:flex;gap:.35rem;flex-wrap:nowrap;justify-content:flex-end;align-items:center;flex-shrink:0;white-space:nowrap}
.pocket-row-actions .btn{padding:.2rem .55rem}
.pocket-row-actions form{margin:0;display:inline-flex}
.pocket-empty-state{padding:.95rem}
.pocket-file-card{padding:.65rem .75rem}
.pocket-section-title{margin-bottom:.55rem;font-size:.95rem}
@media (max-width: 767px){
  .discover-page__search .btn{width:100%;justify-content:center}
  .discover-user-card{align-items:flex-start;flex-direction:column}
  .discover-user-card__action,.discover-user-card__action .btn{width:100%}
  .pocket-row-actions{width:100%;justify-content:flex-start}
  .pocket-row-actions .btn,.pocket-row-actions form{flex:1 1 auto}
  .pocket-row-actions form .btn{width:100%}
  .pocket-item-title{font-size:.95rem}
}

/* Pocket table row redesign */
.pocket-table-card{border:1px solid rgba(100,220,255,.22);border-radius:8px;overflow:visible;background:rgba(8,12,24,.78)}
.pocket-table-head,.pocket-row{display:grid;grid-template-columns:32px minmax(160px,1.6fr) minmax(90px,.65fr) 104px 132px;align-items:center;gap:.65rem;padding:.42rem .65rem}
.pocket-table-head{padding:.38rem .65rem;font-size:.72rem;text-transform:uppercase;letter-spacing:.04em;color:rgba(210,223,255,.72);border-bottom:1px solid rgba(180,150,255,.16);background:rgba(20,24,42,.68)}
.pocket-row{min-height:44px;border-bottom:1px solid rgba(180,150,255,.14);background:rgba(12,16,30,.56)}
.pocket-row:last-child{border-bottom:0}
.pocket-row:hover,.pocket-row:focus-within{background:rgba(60,210,255,.075)}
.pocket-row__icon{display:grid;place-items:center;color:rgba(147,235,255,.9)}
.pocket-row__main,.pocket-row__titleline,.pocket-row__meta,.pocket-row__date{min-width:0}
.pocket-row__titleline{display:flex;align-items:baseline;gap:.35rem;overflow:hidden;white-space:nowrap;color:inherit}
.pocket-row__title,.pocket-row__preview{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.pocket-row__title{flex:0 1 auto;max-width:45%;font-weight:600;color:rgba(236,243,255,.96)}
.pocket-row__preview{flex:1 1 auto;color:rgba(210,223,255,.72)}
.pocket-row__meta{display:inline-flex;gap:.28rem;white-space:nowrap}
.pocket-mini-pill{display:inline-flex;align-items:center;height:20px;padding:0 .45rem;border-radius:6px;font-size:11px;background:rgba(122,209,255,.12);border:1px solid rgba(122,209,255,.18);color:rgba(210,236,255,.88)}
.pocket-mini-pill--locked{background:rgba(255,146,146,.14);border-color:rgba(255,146,146,.26);color:#ffc0c0}
.pocket-row__date{font-size:.82rem;color:rgba(210,223,255,.72);white-space:nowrap}
.pocket-row__actions{display:inline-flex;align-items:center;justify-content:flex-end;gap:.25rem;white-space:nowrap;flex-wrap:nowrap}
.pocket-icon-btn{width:30px;height:30px;padding:0;display:inline-grid;place-items:center;border:1px solid rgba(90,220,255,.28);border-radius:7px;background:rgba(9,14,28,.72);color:#93ebff}
.pocket-icon-btn:hover,.pocket-icon-btn:focus-visible{border-color:rgba(255,205,120,.65);background:rgba(255,205,120,.1);color:#ffe3a3}
.pocket-icon-btn .material-symbols-outlined{font-size:18px;line-height:1}
.pocket-row__actions form{margin:0;display:inline-flex}
.pocket-table-card .pocket-empty-state{border:0;background:transparent}
.pocket-trash-row{display:grid;grid-template-columns:minmax(0,1fr) auto auto;align-items:center;gap:.65rem}

@media (max-width:640px){
  .pocket-table-head{display:none}
  .pocket-row{grid-template-columns:28px minmax(0,1fr) auto;grid-template-areas:"icon main actions" "icon meta actions";gap:.3rem .55rem;min-height:60px;padding:.55rem .6rem}
  .pocket-row__icon{grid-area:icon}
  .pocket-row__main{grid-area:main}
  .pocket-row__meta{grid-area:meta}
  .pocket-row__actions{grid-area:actions}
  .pocket-row__preview{display:none}
  .pocket-row__actions .pocket-icon-btn:not(.pocket-row-menu-trigger){display:none}
}


/* Pocket + Spaces readability pass */
.pocket-shell,.pocket-board{display:grid;gap:.9rem}
.pocket-row-list{display:grid;gap:.6rem}
.pocket-row-list .pocket-item-card,.pocket-file-card{padding:.78rem .9rem}
.pocket-row-list .pocket-item-title,.pocket-file-name{line-height:1.3}
.pocket-row-list .pocket-item-meta,.pocket-file-meta{font-size:.8rem;line-height:1.35}

.spaces-theme .space-board-shell,.spaces-theme .space-board-grid{gap:1.1rem}
.spaces-theme .thread-list{display:grid;gap:.8rem}
.spaces-theme .thread-list-item{padding:.9rem .95rem}
.spaces-theme .thread-list .thread-title,
.spaces-theme .thread-list .thread-meta h3{line-height:1.32}
.spaces-theme .thread-list .thread-preview,
.spaces-theme .space-thread-preview{line-height:1.4;color:rgba(225,236,255,.9)}
.ui-icon-btn,.ui-icon-chip{display:inline-flex;align-items:center;gap:.32rem}
.ui-icon-btn .material-symbols-outlined,.ui-icon-chip .material-symbols-outlined{font-size:1rem;line-height:1}
.ui-icon-btn{justify-content:center;min-width:34px}
.ui-icon-chip{font-weight:600}
.compact-action-group{display:flex;align-items:center;gap:.4rem;flex-wrap:wrap}
.spaces-theme .thread-stat-chip{display:inline-flex;align-items:center;gap:.2rem}
.spaces-theme .space-post__actions .ui-icon-btn,.spaces-theme .space-reply__actions .ui-icon-btn{color:rgba(145,225,255,.95)}
@media (max-width:640px){
  .ui-icon-chip span:last-child{font-size:.82rem}
  .spaces-theme .thread-list-item{padding:.75rem .78rem}
}


.discover-user-card{padding:.7rem .85rem;border:1px solid rgba(122,209,255,.18);background:linear-gradient(160deg,rgba(22,26,50,.82),rgba(11,15,31,.92))}.discover-user-card .btn{min-height:34px}.discover-page__search .form-control::placeholder{color:rgba(194,208,240,.85)}
.spaces-theme .thread-list-item,.spaces-theme .space-message-composer,.spaces-theme .space-post,.spaces-theme .space-reply{border-color:rgba(128,206,255,.22)}
.spaces-theme .space-post,.spaces-theme .space-reply__content{background:rgba(10,16,28,.88);border:1px solid rgba(128,206,255,.18);border-radius:12px;padding:.55rem .65rem}
.spaces-theme .space-reply{gap:.45rem}.spaces-theme .space-reply__avatar{width:26px;height:26px;font-size:.72rem}
.spaces-theme .space-reply__meta{display:flex;align-items:center;gap:.4rem;flex-wrap:wrap}.spaces-theme .space-reply__actions{gap:.45rem;margin-top:.2rem}
.spaces-theme .space-reply-children{margin:.35rem 0 0 .25rem;padding-left:.55rem;border-left:1px solid rgba(130,200,255,.26)}
.spaces-theme .space-message-composer{padding:.5rem .55rem}.spaces-theme .space-message-composer .form-control{min-height:72px}

/* Spaces thread polish aligned with Pocket compact surfaces */
.spaces-theme .space-list-item,
.spaces-theme .thread-list-item,
.spaces-theme .space-post,
.spaces-theme .space-reply__content,
.spaces-theme .space-message-composer,
.spaces-theme .space-board-header,
.spaces-theme .space-about-card {
  border: 1px solid color-mix(in srgb, var(--border) 82%, transparent) !important;
  background: color-mix(in srgb, var(--surface) 95%, transparent) !important;
  border-radius: 12px !important;
  box-shadow: 0 10px 28px color-mix(in srgb, #000 18%, transparent);
}
.spaces-theme .space-list-item,
.spaces-theme .thread-list-item { padding: .65rem .72rem; }
.spaces-theme .space-row-avatar,
.spaces-theme .space-reply__avatar,
.spaces-theme .space-post__avatar { width: 30px; height: 30px; }
.spaces-theme .space-message-list { display: grid; gap: .55rem; }
.spaces-theme .space-reply { display: grid; grid-template-columns: 30px minmax(0,1fr); gap: .45rem; align-items: start; }
.spaces-theme .space-reply__meta { font-size: .78rem; color: var(--bs-secondary-color); }
.spaces-theme .space-reply__body,
.spaces-theme .space-post__body,
.spaces-theme .space-row-description,
.spaces-theme .space-thread-preview { font-size: .9rem; line-height: 1.35; }
.spaces-theme .space-reply-children { margin: .35rem 0 0 .25rem; padding-left: .55rem; border-left: 1px solid color-mix(in srgb, var(--primary) 28%, var(--border)); }
.spaces-theme .space-reply-branch-toggle { cursor: pointer; font-size: .78rem; color: var(--bs-secondary-color); }
.spaces-theme .compact-action-group .ui-icon-btn {
  min-width: 30px;
  width: 30px;
  height: 30px;
  border-radius: 999px;
  border: 1px solid color-mix(in srgb, var(--border) 78%, transparent);
  color: var(--bs-secondary-color);
}
.spaces-theme .compact-action-group .ui-icon-btn:hover,
.spaces-theme .compact-action-group .ui-icon-btn:focus-visible {
  color: var(--bs-body-color);
  border-color: color-mix(in srgb, var(--primary) 45%, var(--border));
  background: color-mix(in srgb, var(--primary) 12%, transparent);
}
.spaces-theme .ui-icon-btn.is-copied { border-color: rgba(25, 208, 138, .7); color: #8bffd2; }
@media (max-width: 576px) {
  .spaces-theme .spaces-shell { padding-inline: .5rem; }
  .spaces-theme .space-reply { grid-template-columns: 26px minmax(0,1fr); }
  .spaces-theme .space-reply-children { margin-left: .15rem; padding-left: .45rem; }
  .spaces-theme .space-board-actions .btn span:last-child,
  .spaces-theme .ui-icon-chip span:last-child { display: none; }
}


/* Spaces reply polish - safe incremental refinements */
.spaces-theme .space-reply--nested .space-reply__content{background:color-mix(in srgb,var(--surface) 92%, transparent)!important}
.spaces-theme .space-reply__author{font-weight:600;color:rgba(232,241,255,.94)}
.spaces-theme .space-reply-branch-toggle{display:inline-flex;align-items:center;gap:.3rem;padding:.16rem .5rem;border-radius:999px;border:1px solid rgba(128,206,255,.24);background:rgba(255,255,255,.03)}
.spaces-theme .space-reply-branch-toggle:hover,.spaces-theme .space-reply-branch-toggle:focus-visible{background:rgba(108,228,255,.12);border-color:rgba(152,115,255,.5);outline:none}
.spaces-theme .thread-list-item:focus-visible,.spaces-theme .spaces-filter-chip:focus-visible{outline:2px solid rgba(136,220,255,.7);outline-offset:2px}
@media (max-width:640px){
  .spaces-theme .space-reply{grid-template-columns:26px minmax(0,1fr)}
  .spaces-theme .space-reply__avatar{width:26px;height:26px}
  .spaces-theme .space-reply-children{margin-left:.1rem;padding-left:.45rem}
}

/* Spaces thread detail polish (Pocket surface + Chat flow hybrid) */
.spaces-theme .space-thread-shell {
  padding-bottom: calc(7.5rem + env(safe-area-inset-bottom));
}
.spaces-theme .space-thread-header {
  padding: .7rem .8rem;
  border: 1px solid color-mix(in srgb, var(--border) 84%, transparent);
  background: color-mix(in srgb, var(--surface) 96%, transparent);
  border-radius: 14px;
  align-items: center;
}
.spaces-theme .space-thread-header__main { min-width: 0; }
.spaces-theme .space-thread-header__eyebrow { letter-spacing: .04em; }
.spaces-theme .space-thread-header__meta { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.spaces-theme .space-post {
  background: linear-gradient(170deg, color-mix(in srgb, var(--surface) 98%, transparent), color-mix(in srgb, var(--surface-raised) 94%, transparent)) !important;
}
.spaces-theme .space-message-list { gap: .62rem; }
.spaces-theme .space-reply-row {
  display: grid;
  grid-template-columns: 30px minmax(0, 1fr);
  align-items: start;
  gap: .5rem;
  margin-left: calc(min(var(--space-reply-depth, 0), 4) * .36rem);
}
.spaces-theme .space-reply-avatar {
  margin-top: .15rem;
  box-shadow: inset 0 0 0 1px rgba(255,255,255,.07);
}
.spaces-theme .space-reply-bubble {
  background: color-mix(in srgb, var(--surface) 93%, #081126) !important;
  border-color: color-mix(in srgb, var(--primary) 20%, var(--border)) !important;
  border-radius: 14px !important;
  padding: .58rem .68rem !important;
}
.spaces-theme .space-reply-children {
  position: relative;
  margin: .42rem 0 0 .2rem;
  padding-left: .72rem;
  border-left: 0;
}
.spaces-theme .space-reply-rail {
  position: absolute;
  left: .08rem;
  top: .08rem;
  bottom: .28rem;
  width: 1px;
  border-radius: 999px;
  background: linear-gradient(180deg, color-mix(in srgb, var(--primary) 46%, transparent), color-mix(in srgb, var(--secondary) 30%, transparent));
}
.spaces-theme .space-reply-actions .ui-icon-btn,
.spaces-theme .space-post__actions .ui-icon-btn {
  width: 28px;
  height: 28px;
  min-width: 28px;
  border-radius: 999px;
}
@media (max-width: 640px) {
  .spaces-theme .space-thread-header { padding: .62rem .66rem; }
  .spaces-theme .space-reply-row { margin-left: calc(min(var(--space-reply-depth, 0), 3) * .2rem); }
  .spaces-theme .space-reply-children { padding-left: .56rem; }
  .spaces-theme .space-message-composer { padding-bottom: .62rem; }
}

/* Wizard Skin Spaces + Pocket-share polish pass */
.spaces-theme {
  --casino-cyan: #65e8ff;
  --casino-violet: #9f7cff;
  --casino-magenta: #ff4fd8;
  --casino-gold: #ffd76a;
  --casino-mint: #7dffca;
  background:
    radial-gradient(circle at 14% 0%, rgba(101, 232, 255, .12), transparent 28rem),
    radial-gradient(circle at 90% 8%, rgba(255, 79, 216, .11), transparent 24rem),
    linear-gradient(rgba(101,232,255,.035) 1px, transparent 1px),
    linear-gradient(90deg, rgba(159,124,255,.035) 1px, transparent 1px),
    #070b15;
  background-size: auto, auto, 32px 32px, 32px 32px, auto;
}
.spaces-theme .spaces-shell { width: min(100%, 1180px); }
.spaces-theme .spaces-shell--detail { width: min(100%, 1120px); }
.spaces-theme .space-board-layout { display: grid; grid-template-columns: minmax(0, 1fr); gap: .9rem; }
.spaces-theme .space-board-side { display: none; }
@media (min-width: 992px) {
  .spaces-theme .space-board-layout { grid-template-columns: minmax(0, 1fr) 260px; align-items: start; }
  .spaces-theme .space-board-side { display: block; position: sticky; top: 1rem; }
}
.spaces-theme .space-board-header,
.spaces-theme .space-about-card,
.spaces-theme .space-list-item,
.spaces-theme .thread-list-item,
.spaces-theme .space-post,
.spaces-theme .space-reply-bubble,
.spaces-theme .space-message-composer {
  background:
    linear-gradient(145deg, rgba(23, 29, 54, .9), rgba(7, 12, 26, .92)) !important;
  border-color: rgba(101, 232, 255, .22) !important;
  box-shadow: 0 0 0 1px rgba(159, 124, 255, .08), 0 16px 34px rgba(0, 0, 0, .24) !important;
  backdrop-filter: blur(16px);
}
.spaces-theme .space-board-header { overflow: hidden; position: relative; }
.spaces-theme .space-board-header::after {
  content: '';
  position: absolute;
  inset: 0 0 auto;
  height: 2px;
  background: linear-gradient(90deg, var(--casino-cyan), var(--casino-violet), var(--casino-magenta), var(--casino-gold));
  opacity: .8;
}
.spaces-theme .spaces-kicker,
.spaces-theme .space-thread-header__eyebrow {
  color: var(--casino-gold) !important;
  font-size: .72rem;
  font-weight: 800;
  letter-spacing: .12em;
  text-transform: uppercase;
}
.spaces-theme .spaces-subtitle,
.spaces-theme .space-thread-preview,
.spaces-theme .space-row-description { color: rgba(223, 234, 255, .78) !important; }
.spaces-theme .input-group-text,
.spaces-theme .form-control,
.spaces-theme .form-select {
  background: rgba(5, 10, 22, .86) !important;
  border-color: rgba(101, 232, 255, .2) !important;
  color: rgba(239, 246, 255, .96) !important;
}
.spaces-theme .form-control:focus,
.spaces-theme .form-select:focus {
  border-color: rgba(255, 215, 106, .65) !important;
  box-shadow: 0 0 0 .18rem rgba(101, 232, 255, .14), 0 0 22px rgba(159, 124, 255, .14) !important;
}
.spaces-theme .space-stat-chip,
.spaces-theme .thread-stat-chip,
.spaces-theme .spaces-chip,
.spaces-theme .spaces-filter-pills .nav-link,
.spaces-theme .thread-view-chip {
  display: inline-flex;
  align-items: center;
  gap: .25rem;
  border: 1px solid rgba(101, 232, 255, .22);
  border-radius: 999px;
  background: rgba(101, 232, 255, .075);
  color: rgba(224, 242, 255, .9) !important;
  font-size: .76rem;
  font-weight: 700;
  line-height: 1;
  min-height: 1.55rem;
  padding: .24rem .52rem;
  text-decoration: none;
}
.spaces-theme .space-stat-chip--hot,
.spaces-theme .thread-stat-chip--hot,
.spaces-theme .spaces-chip.active,
.spaces-theme .spaces-filter-pills .nav-link.active {
  background: linear-gradient(135deg, rgba(255, 215, 106, .95), rgba(125, 255, 202, .88));
  border-color: rgba(255, 215, 106, .72);
  color: #111827 !important;
  box-shadow: 0 0 18px rgba(255, 215, 106, .18);
}
.spaces-theme .thread-list-item { text-decoration: none; transition: transform .15s ease, border-color .15s ease, box-shadow .15s ease; }
.spaces-theme .thread-list-item:hover,
.spaces-theme .thread-list-item:focus-visible {
  transform: translateY(-1px);
  border-color: rgba(101, 232, 255, .48) !important;
  box-shadow: 0 0 0 1px rgba(101, 232, 255, .16), 0 16px 36px rgba(0, 0, 0, .32), 0 0 28px rgba(159, 124, 255, .12) !important;
}
.spaces-theme .thread-list-item__inner { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: .75rem; align-items: center; }
.spaces-theme .thread-view-chip {
  background: linear-gradient(135deg, rgba(101,232,255,.14), rgba(159,124,255,.16));
  border-color: rgba(255, 215, 106, .34);
  color: rgba(255, 246, 210, .95) !important;
  white-space: nowrap;
}
.spaces-theme .thread-view-chip .material-symbols-outlined { font-size: 1rem; }
.spaces-theme .space-thread-back { margin-bottom: .65rem; }
.spaces-theme .space-thread-header {
  display: flex;
  justify-content: space-between;
  gap: .75rem;
  margin-bottom: .75rem;
  background: linear-gradient(145deg, rgba(20, 26, 48, .94), rgba(8, 12, 28, .94));
  box-shadow: inset 0 1px 0 rgba(255,255,255,.05), 0 14px 34px rgba(0,0,0,.24);
}
.spaces-theme .space-conversation { display: grid; gap: .7rem; }
.spaces-theme .space-post { padding: .85rem; border-radius: 16px !important; }
.spaces-theme .space-post__header { display: flex; align-items: center; gap: .55rem; margin-bottom: .55rem; }
.spaces-theme .space-post__author,
.spaces-theme .space-reply__author { color: rgba(245, 249, 255, .96) !important; font-weight: 800; }
.spaces-theme .space-post__title { font-size: 1rem; margin-bottom: .35rem; }
.spaces-theme .space-post__body,
.spaces-theme .space-reply__body { color: rgba(236, 243, 255, .94); overflow-wrap: anywhere; }
.spaces-theme .space-post__actions,
.spaces-theme .space-reply-actions { display: flex; gap: .32rem; margin-top: .45rem; }
.spaces-theme .space-reply-row {
  grid-template-columns: 30px minmax(0, 1fr) !important;
  margin-left: calc(min(var(--space-reply-depth, 0), 4) * .34rem) !important;
}
.spaces-theme .space-reply-avatar,
.spaces-theme .space-post__avatar,
.spaces-theme .space-row-avatar {
  display: grid;
  place-items: center;
  flex: 0 0 auto;
  border-radius: 50%;
  background: linear-gradient(135deg, rgba(101, 232, 255, .92), rgba(159, 124, 255, .86));
  color: #06111f;
  font-weight: 900;
  box-shadow: 0 0 0 2px rgba(255, 215, 106, .16), 0 0 18px rgba(101, 232, 255, .18);
}
.spaces-theme .space-reply-bubble {
  padding: .58rem .68rem !important;
  border-radius: 15px !important;
  border-color: rgba(101, 232, 255, .24) !important;
}
.spaces-theme .space-reply--nested .space-reply-bubble { background: linear-gradient(145deg, rgba(17, 24, 45, .92), rgba(7, 12, 26, .9)) !important; }
.spaces-theme .space-reply__meta { display: flex; align-items: center; gap: .32rem; font-size: .76rem; line-height: 1.2; color: rgba(203, 218, 245, .76) !important; }
.spaces-theme .space-reply-children { margin-top: .48rem !important; padding-left: .65rem !important; }
.spaces-theme .space-reply-rail { background: linear-gradient(180deg, rgba(101,232,255,.65), rgba(255,79,216,.36), rgba(255,215,106,.24)) !important; }
.spaces-theme .space-reply-branch-toggle {
  color: rgba(224, 242, 255, .92) !important;
  border-color: rgba(125, 255, 202, .32) !important;
  background: rgba(125, 255, 202, .08) !important;
}
.spaces-theme .space-reply-branch-toggle .material-symbols-outlined { font-size: 1rem; }
.spaces-theme .space-reply-context {
  display: inline-flex;
  width: fit-content;
  max-width: 100%;
  margin-bottom: .4rem;
  padding: .2rem .55rem;
  border-radius: 999px;
  border: 1px solid rgba(255, 215, 106, .35);
  background: rgba(255, 215, 106, .1);
  color: rgba(255, 246, 210, .94);
  font-size: .78rem;
  font-weight: 700;
}
.spaces-theme .space-message-composer {
  position: sticky;
  bottom: calc(.5rem + env(safe-area-inset-bottom));
  z-index: 5;
  margin-top: .85rem;
  padding: .58rem !important;
  border-radius: 16px !important;
}
.spaces-theme .space-message-composer .form-control { min-height: 68px !important; resize: vertical; }
@media (max-width: 640px) {
  .spaces-theme .spaces-shell { padding-inline: .45rem !important; }
  .spaces-theme .thread-list-item__inner { grid-template-columns: minmax(0, 1fr); }
  .spaces-theme .thread-view-chip { width: fit-content; }
  .spaces-theme .space-thread-header { align-items: stretch; flex-direction: column; }
  .spaces-theme .space-thread-actions .btn { width: 100%; }
  .spaces-theme .space-reply-row { grid-template-columns: 26px minmax(0, 1fr) !important; margin-left: calc(min(var(--space-reply-depth, 0), 3) * .16rem) !important; }
  .spaces-theme .space-reply-bubble { padding: .52rem .58rem !important; }
  .spaces-theme .space-reply-children { padding-left: .48rem !important; }
  .spaces-theme .space-message-composer { bottom: calc(.35rem + env(safe-area-inset-bottom)); }
}

.chat-pocket-preview {
  border-color: rgba(101, 232, 255, .34) !important;
  background: linear-gradient(145deg, rgba(18, 26, 49, .95), rgba(7, 12, 26, .96)) !important;
  box-shadow: 0 0 0 1px rgba(159, 124, 255, .12), 0 12px 28px rgba(0,0,0,.22);
}
.chat-pocket-preview .chat-link-preview__host { color: #ffd76a; text-transform: uppercase; font-weight: 800; letter-spacing: .08em; }
.chat-pocket-preview .chat-link-preview__title { color: rgba(245, 249, 255, .98); font-weight: 800; }
.chat-pocket-preview .btn { border-radius: 999px; }
.chat-pocket-picker__lead { color: rgba(216, 229, 255, .78); font-size: .84rem; margin: .15rem 0 0; }
.chat-pocket-picker__filters { display: grid; grid-template-columns: minmax(0, 1fr); gap: .45rem; margin-bottom: .55rem; }
.chat-pocket-picker__quick-row { display: flex; gap: .45rem; flex-wrap: wrap; margin-bottom: .55rem; }
.chat-pocket-picker__advanced-toggle { color: rgba(101, 232, 255, .92); cursor: pointer; font-size: .8rem; font-weight: 700; list-style: none; }
.chat-pocket-picker__advanced-toggle::-webkit-details-marker { display: none; }
.chat-pocket-picker__advanced { margin: .4rem 0 .55rem; padding: .55rem; border: 1px solid rgba(101, 232, 255, .16); border-radius: 12px; background: rgba(5, 10, 22, .42); }
.chat-pocket-picker__controls { display: grid; gap: .45rem; }
.chat-pocket-picker__item {
  text-align: left;
  border-color: rgba(101, 232, 255, .22) !important;
  background: linear-gradient(145deg, rgba(18, 26, 49, .86), rgba(7, 12, 26, .9)) !important;
  border-radius: 12px !important;
}
.chat-pocket-picker__item.is-active,
.chat-pocket-picker__item:hover,
.chat-pocket-picker__item:focus-visible {
  border-color: rgba(255, 215, 106, .62) !important;
  box-shadow: 0 0 0 1px rgba(255, 215, 106, .16), 0 0 22px rgba(101, 232, 255, .12);
}
.chat-pocket-picker__attach-note { color: rgba(125, 255, 202, .9); font-size: .8rem; }
@media (min-width: 720px) {
  .chat-pocket-picker__filters { grid-template-columns: minmax(0, 1fr) auto; }
}
.chat-pocket-picker__title { display: flex; align-items: center; gap: .42rem; min-width: 0; font-weight: 800; color: rgba(245, 249, 255, .96); }
.chat-pocket-picker__title .material-symbols-rounded { color: #65e8ff; font-size: 1.05rem; flex: 0 0 auto; }
.chat-composer__pocket { border-color: rgba(101, 232, 255, .28) !important; color: #65e8ff !important; }
.chat-composer__pocket:hover,
.chat-composer__pocket:focus-visible { border-color: rgba(255, 215, 106, .58) !important; color: #ffd76a !important; box-shadow: 0 0 18px rgba(101, 232, 255, .18); }
.chat-native__composer .chat-composer__tools { display: inline-flex; align-items: center; gap: .35rem; }

/* Spaces replies rebuild: Chat-style rows under Pocket-style thread cards. */
.spaces-theme .space-thread-shell {
  padding-bottom: calc(7.5rem + env(safe-area-inset-bottom));
}
.spaces-theme .space-conversation {
  display: grid;
  gap: .85rem;
}
.spaces-theme .space-post {
  position: relative;
  overflow: hidden;
  padding: .9rem .95rem;
  border: 1px solid rgba(101, 232, 255, .22) !important;
  border-radius: 18px !important;
  background:
    radial-gradient(circle at 14% 0%, rgba(101, 232, 255, .14), transparent 18rem),
    radial-gradient(circle at 92% 5%, rgba(255, 79, 216, .12), transparent 16rem),
    linear-gradient(145deg, rgba(23, 29, 54, .94), rgba(7, 12, 26, .94)) !important;
  box-shadow: 0 0 0 1px rgba(159, 124, 255, .08), 0 18px 42px rgba(0, 0, 0, .28) !important;
  backdrop-filter: blur(16px);
}
.spaces-theme .space-post::before {
  content: '';
  position: absolute;
  inset: 0 0 auto;
  height: 2px;
  background: linear-gradient(90deg, var(--casino-cyan, #65e8ff), var(--casino-violet, #9f7cff), var(--casino-magenta, #ff4fd8), var(--casino-gold, #ffd76a));
  opacity: .82;
}
.spaces-theme .space-replies-list,
.spaces-theme .space-message-list {
  display: grid;
  gap: .72rem;
}
.spaces-theme .space-reply-row {
  display: grid;
  grid-template-columns: 32px minmax(0, 1fr);
  align-items: start;
  gap: .55rem;
  margin-left: calc(min(var(--space-reply-depth, 0), 2) * .75rem) !important;
  min-width: 0;
}
.spaces-theme .space-reply-main {
  min-width: 0;
  display: grid;
  gap: .28rem;
}
.spaces-theme .space-reply-avatar,
.spaces-theme .space-post__avatar,
.spaces-theme .space-row-avatar {
  width: 32px;
  height: 32px;
  display: grid;
  place-items: center;
  flex: 0 0 auto;
  margin-top: .08rem;
  border-radius: 50%;
  background: linear-gradient(135deg, rgba(101, 232, 255, .95), rgba(159, 124, 255, .88));
  color: #06111f;
  font-size: .78rem;
  font-weight: 900;
  box-shadow: 0 0 0 2px rgba(255, 215, 106, .16), 0 0 18px rgba(101, 232, 255, .18);
}
.spaces-theme .space-reply-bubble {
  width: fit-content;
  max-width: min(100%, 78ch);
  padding: .58rem .7rem .48rem !important;
  border: 1px solid rgba(101, 232, 255, .18) !important;
  border-radius: 17px !important;
  background:
    linear-gradient(145deg, rgba(23, 33, 58, .92), rgba(10, 18, 36, .9)) !important;
  box-shadow: 0 8px 20px rgba(0, 0, 0, .18), inset 0 1px 0 rgba(255, 255, 255, .045) !important;
  backdrop-filter: blur(12px);
}
.spaces-theme .space-reply-row--nested .space-reply-bubble {
  background:
    linear-gradient(145deg, rgba(26, 36, 64, .9), rgba(11, 20, 40, .88)) !important;
  border-color: rgba(159, 124, 255, .18) !important;
}
.spaces-theme .space-reply-meta {
  display: flex;
  align-items: baseline;
  gap: .32rem;
  margin-bottom: .2rem;
  color: rgba(203, 218, 245, .76) !important;
  font-size: .74rem;
  line-height: 1.2;
  letter-spacing: .01em;
}
.spaces-theme .space-reply-author,
.spaces-theme .space-post__author {
  color: rgba(245, 249, 255, .97) !important;
  font-weight: 800;
}
.spaces-theme .space-reply-body,
.spaces-theme .space-post__body {
  color: rgba(236, 243, 255, .95);
  font-size: .92rem;
  line-height: 1.42;
  overflow-wrap: anywhere;
  white-space: pre-wrap;
}
.spaces-theme .space-reply-actions,
.spaces-theme .space-post__actions {
  display: inline-flex;
  align-items: center;
  gap: .22rem;
  margin-top: .38rem;
}
.spaces-theme .space-reply-action {
  width: 25px;
  height: 25px;
  min-width: 25px;
  padding: 0;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 1px solid rgba(101, 232, 255, .18);
  border-radius: 999px;
  background: rgba(101, 232, 255, .065);
  color: rgba(191, 234, 255, .92);
  line-height: 1;
  text-decoration: none;
  transition: transform .15s ease, border-color .15s ease, background-color .15s ease, color .15s ease;
}
.spaces-theme .space-reply-action:hover,
.spaces-theme .space-reply-action:focus-visible {
  transform: translateY(-1px);
  border-color: rgba(255, 215, 106, .48);
  background: rgba(255, 215, 106, .12);
  color: rgba(255, 246, 210, .98);
  outline: none;
}
.spaces-theme .space-reply-action .material-symbols-outlined {
  font-size: .98rem;
  line-height: 1;
}
.spaces-theme .space-reply-action.is-copied {
  border-color: rgba(125, 255, 202, .72);
  color: #8bffd2;
  background: rgba(125, 255, 202, .12);
}
.spaces-theme .space-reply-action.is-copy-failed {
  border-color: rgba(248, 113, 113, .62);
  color: #fecaca;
  background: rgba(248, 113, 113, .1);
}
.spaces-theme .space-reply-children {
  position: relative;
  display: grid;
  gap: .58rem;
  margin: .55rem 0 0 !important;
  padding-left: .68rem !important;
  border-left: 0 !important;
}
.spaces-theme .space-reply-rail {
  position: absolute;
  left: .12rem;
  top: .05rem;
  bottom: .1rem;
  width: 1px;
  border-radius: 999px;
  background: linear-gradient(180deg, rgba(101, 232, 255, .55), rgba(159, 124, 255, .36), rgba(255, 215, 106, .24)) !important;
}
.spaces-theme .space-replying-to-chip {
  display: inline-flex;
  align-items: center;
  width: fit-content;
  max-width: 100%;
  padding: .16rem .48rem;
  border: 1px solid rgba(255, 215, 106, .26);
  border-radius: 999px;
  background: rgba(255, 215, 106, .08);
  color: rgba(255, 246, 210, .88);
  font-size: .72rem;
  font-weight: 800;
  line-height: 1.2;
}
.spaces-theme .space-reply-branch {
  margin-top: .1rem;
}
.spaces-theme .space-reply-branch-toggle {
  width: fit-content;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: .28rem;
  padding: .2rem .55rem;
  border: 1px solid rgba(125, 255, 202, .24) !important;
  border-radius: 999px;
  background: rgba(125, 255, 202, .075) !important;
  color: rgba(224, 242, 255, .9) !important;
  font-size: .76rem;
  font-weight: 800;
  list-style: none;
}
.spaces-theme .space-reply-branch-toggle::-webkit-details-marker {
  display: none;
}
.spaces-theme .space-reply-branch-toggle .material-symbols-outlined {
  font-size: 1rem;
  transition: transform .15s ease;
}
.spaces-theme .space-reply-branch[open] .space-reply-branch-toggle .material-symbols-outlined {
  transform: rotate(180deg);
}
.spaces-theme .space-reply-branch__inner {
  display: grid;
  gap: .58rem;
  margin-top: .55rem;
}
.spaces-theme .space-reply-branch--reset > .space-reply-branch__inner {
  width: 100%;
  margin-left: 0;
  padding-left: .68rem;
}
.spaces-theme .space-reply-composer,
.spaces-theme .space-message-composer {
  position: sticky;
  bottom: calc(.5rem + env(safe-area-inset-bottom));
  z-index: 5;
  margin-top: .85rem;
  padding: .6rem !important;
  border: 1px solid rgba(101, 232, 255, .22) !important;
  border-radius: 18px !important;
  background: linear-gradient(145deg, rgba(23, 29, 54, .94), rgba(7, 12, 26, .94)) !important;
  box-shadow: 0 0 0 1px rgba(159, 124, 255, .08), 0 16px 34px rgba(0, 0, 0, .24) !important;
  backdrop-filter: blur(16px);
}
.spaces-theme .space-message-composer .form-control {
  min-height: 68px !important;
  resize: vertical;
}
@media (max-width: 640px) {
  .spaces-theme .space-thread-shell {
    padding-inline: .45rem !important;
  }
  .spaces-theme .space-reply-row {
    grid-template-columns: 28px minmax(0, 1fr) !important;
    gap: .46rem;
    margin-left: calc(min(var(--space-reply-depth, 0), 2) * .42rem) !important;
  }
  .spaces-theme .space-reply-avatar {
    width: 28px;
    height: 28px;
    font-size: .7rem;
  }
  .spaces-theme .space-reply-bubble {
    max-width: 100%;
    padding: .52rem .6rem .44rem !important;
  }
  .spaces-theme .space-reply-children {
    padding-left: .5rem !important;
  }
  .spaces-theme .space-reply-branch--reset > .space-reply-branch__inner {
    width: 100%;
    margin-left: 0;
    padding-left: .5rem;
  }
  .spaces-theme .space-replying-to-chip {
    font-size: .68rem;
  }
  .spaces-theme .space-message-composer {
    bottom: calc(.35rem + env(safe-area-inset-bottom));
  }
}

/* Spaces board: Bootstrap-style compact rows */
.spaces-theme .space-board-layout { gap: .5rem !important; }
.spaces-theme .space-board-header { margin-bottom: .5rem !important; }
.spaces-theme .space-board-header .card-body { padding: .65rem .8rem !important; }
.spaces-theme .space-board-header h1 { font-size: 1.15rem; line-height: 1.2; }
.spaces-theme .spaces-subtitle { margin-bottom: .4rem !important; line-height: 1.25; }
.spaces-theme .space-board-actions .btn { min-width: 2.25rem; min-height: 2rem; padding: .25rem .55rem; justify-content: center; }
.spaces-theme .thread-filter-row { gap: .35rem; margin-bottom: .5rem !important; }
.spaces-theme .thread-filter-row + details { margin-bottom: .5rem !important; }
.spaces-theme .spaces-chip,
.spaces-theme .space-stat-chip,
.spaces-theme .thread-stat-chip,
.spaces-theme .thread-view-chip { min-height: 1.35rem; padding: .18rem .45rem; font-size: .72rem; }
.spaces-theme .thread-list { gap: .45rem; }
.spaces-theme .thread-list-item { padding: .55rem .65rem !important; }
.spaces-theme .thread-list-item__inner { gap: .5rem; align-items: center; }
.spaces-theme .thread-meta h3 { line-height: 1.2; }
.spaces-theme .space-thread-preview { margin-bottom: .35rem !important; line-height: 1.25; -webkit-line-clamp: 1 !important; }
@media (max-width: 640px) {
  .spaces-theme .space-board-header .card-body { padding: .55rem .65rem !important; }
  .spaces-theme .space-board-header h1 { font-size: 1rem; }
  .spaces-theme .space-board-actions .btn { width: auto !important; }
  .spaces-theme .thread-list-item__inner { grid-template-columns: minmax(0, 1fr); }
}

/* Spaces replies: keep long branches readable instead of squeezing each nested reply narrower. */
.spaces-theme .space-reply-row {
  margin-left: calc(min(var(--space-reply-depth, 0), 1) * .7rem) !important;
}
.spaces-theme .space-reply-children {
  width: 100%;
  margin-left: 0 !important;
  padding-left: .68rem !important;
}
.spaces-theme .space-reply-branch__inner {
  width: 100%;
}
.spaces-theme .space-reply-bubble {
  max-width: min(100%, 46rem);
}
@media (max-width: 640px) {
  .spaces-theme .space-reply-row {
    margin-left: calc(min(var(--space-reply-depth, 0), 1) * .3rem) !important;
  }
  .spaces-theme .space-reply-children {
    width: 100%;
    margin-left: 0 !important;
    padding-left: .5rem !important;
  }
}

/* Spaces replies: cap visual nesting at two levels; deeper context moves to branch view. */
.spaces-theme .reply-node,
.spaces-theme .space-reply-row {
  box-sizing: border-box;
  max-width: 100%;
  min-width: 0;
}
.spaces-theme .reply-card,
.spaces-theme .space-reply-bubble {
  box-sizing: border-box;
  min-width: 0;
  max-width: min(100%, 46rem) !important;
}
.spaces-theme .space-reply-main,
.spaces-theme .space-replies-list,
.spaces-theme .space-message-list,
.spaces-theme .space-reply-children,
.spaces-theme .space-reply-branch__inner {
  min-width: 0;
  max-width: 100%;
}
.spaces-theme .reply-depth-0 { margin-left: 0 !important; }
.spaces-theme .reply-depth-1 { margin-left: clamp(.75rem, 3vw, 1.5rem) !important; }
.spaces-theme .reply-depth-2,
.spaces-theme .reply-depth-deep { margin-left: clamp(1rem, 5vw, 2.25rem) !important; }
.spaces-theme .space-reply-children {
  padding-left: .68rem !important;
}
.spaces-theme .space-reply-children--deep {
  padding-left: 0 !important;
}
.spaces-theme .space-reply-children--deep .space-reply-rail {
  display: none;
}
.spaces-theme .space-reply-branch-link {
  display: inline-flex;
  align-items: center;
  gap: .34rem;
  width: fit-content;
  max-width: 100%;
  padding: .24rem .62rem;
  border: 1px solid rgba(125, 255, 202, .28);
  border-radius: 999px;
  background: rgba(125, 255, 202, .08);
  color: rgba(224, 242, 255, .94);
  font-size: .76rem;
  font-weight: 800;
  text-decoration: none;
}
.spaces-theme .space-reply-branch-link:hover,
.spaces-theme .space-reply-branch-link:focus-visible {
  border-color: rgba(255, 215, 106, .55);
  background: rgba(255, 215, 106, .12);
  color: rgba(255, 246, 210, .98);
  outline: none;
}
.spaces-theme .space-reply-branch-link .material-symbols-outlined {
  font-size: 1rem;
}
.spaces-theme .space-thread-branch-shell .space-reply-row {
  margin-left: 0 !important;
}
.spaces-theme .space-thread-branch-shell .reply-depth-1,
.spaces-theme .space-thread-branch-shell .reply-depth-2,
.spaces-theme .space-thread-branch-shell .reply-depth-deep {
  margin-left: 0 !important;
}
@media (max-width: 640px) {
  .spaces-theme .reply-depth-1,
  .spaces-theme .reply-depth-2,
  .spaces-theme .reply-depth-deep {
    margin-left: .75rem !important;
  }
  .spaces-theme .reply-card,
  .spaces-theme .space-reply-bubble {
    width: 100%;
    max-width: 100% !important;
  }
  .spaces-theme .space-reply-row {
    max-width: calc(100vw - .9rem);
    overflow-wrap: anywhere;
  }
  .spaces-theme .space-reply-children {
    padding-left: .5rem !important;
  }
  .spaces-theme .space-reply-children--deep {
    padding-left: 0 !important;
  }
  .spaces-theme .space-thread-branch-shell .reply-depth-1,
  .spaces-theme .space-thread-branch-shell .reply-depth-2,
  .spaces-theme .space-thread-branch-shell .reply-depth-deep {
    margin-left: 0 !important;
  }
}

/* Spaces reply nesting hard cap: layout may use only visual depth (0-2), never actual depth. */
.spaces-theme .thread-container,
.spaces-theme .replies-container,
.spaces-theme .reply-list,
.spaces-theme .space-conversation,
.spaces-theme .space-replies-list,
.spaces-theme .space-message-list {
  overflow-x: hidden;
  max-width: 100%;
}
.spaces-theme .reply-node,
.spaces-theme .space-reply-row,
.spaces-theme .reply-thread,
.spaces-theme .reply-children,
.spaces-theme .space-reply-children,
.spaces-theme .nested-replies,
.spaces-theme .reply-list {
  min-width: 0;
  max-width: 100%;
  box-sizing: border-box;
}
.spaces-theme .reply-node * {
  max-width: 100%;
}
.spaces-theme .reply-node {
  position: relative;
  padding-left: 0 !important;
  transform: none !important;
  width: auto !important;
}
.spaces-theme .reply-depth-0 {
  margin-left: 0 !important;
  padding-left: 0 !important;
}
.spaces-theme .reply-depth-1 {
  margin-left: clamp(.5rem, 3vw, 1.25rem) !important;
  padding-left: 0 !important;
}
.spaces-theme .reply-depth-2,
.spaces-theme .reply-depth-deep {
  margin-left: clamp(.75rem, 5vw, 2rem) !important;
  padding-left: 0 !important;
}
.spaces-theme .reply-node .space-reply-children,
.spaces-theme .reply-node .reply-children,
.spaces-theme .reply-node .nested-replies,
.spaces-theme .reply-node .reply-thread {
  margin-left: 0 !important;
  padding-left: 0 !important;
  transform: none !important;
  width: 100% !important;
  border-left: 0 !important;
}
.spaces-theme .space-reply-rail {
  display: none !important;
}
.spaces-theme .reply-node::before {
  content: none;
  display: none;
}
.spaces-theme .reply-depth-1::before,
.spaces-theme .reply-depth-2::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0;
  bottom: 0;
  display: block;
  border-left: 1px solid var(--thread-line-color, rgba(0, 229, 255, .35));
}
.spaces-theme .reply-depth-0::before,
.spaces-theme .reply-depth-deep::before {
  display: none !important;
  content: none !important;
}
.spaces-theme .reply-card,
.spaces-theme .space-reply-bubble,
.spaces-theme .comment-card {
  box-sizing: border-box;
  min-width: 0;
  max-width: 100% !important;
}
.spaces-theme .space-thread-branch-modal {
  position: fixed;
  inset: 0;
  z-index: 1080;
  display: none;
}
.spaces-theme .space-thread-branch-modal.is-open {
  display: block;
}
.space-thread-branch-lock {
  overflow: hidden;
}
.spaces-theme .space-thread-branch-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(2, 6, 18, .72);
  backdrop-filter: blur(6px);
}
.spaces-theme .space-thread-branch-drawer {
  position: absolute;
  top: 0;
  right: 0;
  bottom: 0;
  display: flex;
  flex-direction: column;
  gap: .75rem;
  width: min(42rem, 100vw);
  max-width: 100%;
  padding: 1rem;
  overflow-y: auto;
  overflow-x: hidden;
  border-left: 1px solid rgba(101, 232, 255, .22);
  background: linear-gradient(145deg, rgba(18, 24, 46, .98), rgba(7, 12, 26, .98));
  box-shadow: -22px 0 50px rgba(0, 0, 0, .35);
}
.spaces-theme .space-thread-branch-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: .75rem;
}
.spaces-theme .space-thread-branch-content {
  display: grid;
  gap: .75rem;
  min-width: 0;
}
.spaces-theme .space-thread-branch-composer {
  position: static;
  margin-top: auto;
}
.spaces-theme .space-thread-branch-shell .reply-depth-1,
.spaces-theme .space-thread-branch-shell .reply-depth-2,
.spaces-theme .space-thread-branch-shell .reply-depth-deep,
.spaces-theme .space-thread-branch-modal .reply-depth-1,
.spaces-theme .space-thread-branch-modal .reply-depth-2,
.spaces-theme .space-thread-branch-modal .reply-depth-deep {
  margin-left: 0 !important;
}
@media (max-width: 640px) {
  .spaces-theme .reply-depth-1,
  .spaces-theme .reply-depth-2,
  .spaces-theme .reply-depth-deep {
    margin-left: .65rem !important;
  }
  .spaces-theme .reply-card,
  .spaces-theme .space-reply-bubble,
  .spaces-theme .comment-card {
    width: 100%;
    max-width: 100% !important;
    min-width: 0;
    box-sizing: border-box;
  }
  .spaces-theme .space-reply-row {
    grid-template-columns: 28px minmax(0, 1fr) !important;
    max-width: 100% !important;
  }
  .spaces-theme .space-thread-branch-drawer {
    width: 100vw;
    padding: .75rem;
    border-left: 0;
  }
}

/* Spaces media attachments: make the thread starter feel like a feed post, not a reply bubble. */
.spaces-theme .space-post-media {
  margin-top: .75rem;
  overflow: hidden;
  border: 1px solid rgba(101, 232, 255, .2);
  border-radius: 16px;
  background: rgba(4, 10, 22, .55);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, .04);
}
.spaces-theme .space-post-media__item {
  display: block;
  width: 100%;
  max-height: min(62vh, 560px);
  object-fit: contain;
  background: rgba(3, 8, 18, .82);
}
.spaces-theme .space-post-media--hero {
  margin-inline: -.15rem;
  border-radius: 18px;
}
.spaces-theme .space-post-media--reply {
  max-width: min(100%, 34rem);
  margin-top: .5rem;
  border-radius: 14px;
}
.spaces-theme .space-post-media--reply .space-post-media__item {
  max-height: 320px;
}
.spaces-theme .thread-list-media {
  position: relative;
  overflow: hidden;
  width: min(100%, 26rem);
  margin: .55rem 0 .65rem;
  border: 1px solid rgba(101, 232, 255, .18);
  border-radius: 14px;
  background: rgba(4, 10, 22, .55);
}
.spaces-theme .thread-list-media__item {
  display: block;
  width: 100%;
  aspect-ratio: 16 / 9;
  object-fit: cover;
  background: rgba(3, 8, 18, .82);
}
.spaces-theme .thread-list-media__badge {
  position: absolute;
  right: .55rem;
  bottom: .55rem;
  display: inline-grid;
  place-items: center;
  width: 2rem;
  height: 2rem;
  border-radius: 999px;
  background: rgba(7, 12, 26, .82);
  color: #fff6d2;
  box-shadow: 0 0 0 1px rgba(255, 215, 106, .3);
}
.spaces-theme .thread-list-media__badge .material-symbols-outlined {
  font-size: 1.2rem;
}
@media (max-width: 640px) {
  .spaces-theme .space-post-media__item {
    max-height: 430px;
  }
  .spaces-theme .thread-list-media {
    width: 100%;
  }
}
.pocket-file-preview-modal .modal-body{padding:.75rem;background:rgba(5,8,18,.96)}
.pocket-file-preview-frame{min-height:60vh;display:grid;place-items:center;border:1px solid rgba(122,209,255,.18);border-radius:12px;background:rgba(3,6,14,.84);overflow:hidden}
.pocket-file-preview-frame--shared{min-height:64vh}
.pocket-file-preview-media{display:block;width:100%;height:70vh;max-height:70vh;border:0;object-fit:contain;background:transparent;color:rgba(236,242,255,.94)}
audio.pocket-file-preview-media{height:auto;max-height:none;padding:2rem}
img.pocket-file-preview-media{height:auto;max-height:70vh}
@media (max-width: 767px){.pocket-file-preview-frame{min-height:52vh}.pocket-file-preview-media{height:58vh;max-height:58vh}}
.social-home__pwa-guide{display:grid;gap:.85rem;margin:.75rem 0 1rem;padding:1rem;border-radius:20px;background:linear-gradient(135deg,rgba(47,83,255,.16),rgba(25,182,255,.1));border:1px solid rgba(126,204,255,.28);box-shadow:0 18px 45px rgba(0,0,0,.22)}
.social-home__pwa-guide[hidden]{display:none!important}
.social-home__pwa-kicker{margin:0 0 .15rem;color:#9fd5ff;font-size:.78rem;font-weight:800;text-transform:uppercase;letter-spacing:.08em}
.social-home__pwa-copy h2{margin:0 0 .3rem;font-size:1.1rem;color:#f4f8ff}
.social-home__pwa-copy p{margin-bottom:.55rem;color:#d7e6ff}
.social-home__pwa-copy ol{margin:.35rem 0 .6rem;padding-left:1.25rem;color:#edf5ff}
.social-home__pwa-promise,.settings-pwa-guide__promise{display:inline-block;margin:.25rem 0 0;padding:.45rem .6rem;border-radius:999px;background:rgba(255,215,106,.16);border:1px solid rgba(255,215,106,.42);color:#fff3bf;font-weight:800}
.social-home__pwa-actions,.settings-pwa-guide__actions{display:flex;flex-wrap:wrap;gap:.5rem;align-items:center}
.social-home__pwa-statuses{display:flex;flex-wrap:wrap;gap:.45rem;font-size:.85rem;color:#b9cee9}
.social-home__pwa-statuses span{padding:.3rem .5rem;border-radius:999px;background:rgba(255,255,255,.06)}
.social-home__pwa-steps,.settings-pwa-guide__steps{display:grid;gap:.45rem;margin-top:.2rem;color:#dbe9ff}
.social-home__pwa-steps p,.settings-pwa-guide__steps p{margin:0;padding:.55rem .65rem;border-radius:12px;background:rgba(255,255,255,.05);border:1px solid rgba(255,255,255,.08)}
.settings-pwa-guide{border-color:rgba(126,204,255,.28)!important}
.settings-pwa-guide__status-grid{display:grid;gap:.45rem;margin-bottom:.85rem}
.settings-pwa-guide__status-grid>div{display:flex;justify-content:space-between;gap:.75rem;padding:.55rem .7rem;border-radius:12px;background:rgba(255,255,255,.05);border:1px solid rgba(255,255,255,.08)}
.settings-pwa-guide__status-grid span{color:#b9c7dc}
.settings-pwa-guide__status-grid strong{color:#fff}
.settings-pwa-guide__actions{margin-bottom:.85rem}
@media (max-width:640px){.social-home__pwa-actions .btn,.settings-pwa-guide__actions .btn{width:100%}.settings-pwa-guide__status-grid>div{display:grid}}

/* Keep home quick-setting modals above the mobile nav without using Bootstrap's page-blocking backdrop. */
.home-settings-modal {
  z-index: 1305;
}

.home-settings-modal + .modal-backdrop {
  display: none;
}

@media (max-width: 767.98px) {
  .home-settings-modal .modal-dialog {
    align-items: flex-start;
    margin: calc(.75rem + env(safe-area-inset-top)) .75rem calc(var(--wizard-mobile-nav-height, 82px) + env(safe-area-inset-bottom) + 1rem);
    min-height: 0;
  }
}
