/* Yappy X mode v59 — dark mobile X-inspired social scene builder. */
html[data-social-app="x"]{
  --x-bg:#000;
  --x-surface:#16181c;
  --x-surface-2:#202327;
  --x-border:#2f3336;
  --x-text:#e7e9ea;
  --x-muted:#71767b;
  --x-blue:#1d9bf0;
}
html[data-social-app="x"] #phone-screen,
html[data-social-app="x"] #app-root{background:#000!important;color:var(--x-text)!important}
html[data-social-app="x"] .statusbar{color:#fff!important;background:#000!important}
html[data-social-app="x"] #tabbar{
  background:#000!important;border-top:1px solid var(--x-border)!important;
  height:72px!important;padding:6px 18px calc(8px + env(safe-area-inset-bottom,0px))!important;
  display:flex!important;align-items:flex-start!important;justify-content:space-between!important;
}
html[data-social-app="x"] #tabbar .tab-btn{color:#e7e9ea!important;min-width:48px!important;gap:0!important}
html[data-social-app="x"] #tabbar .tab-btn span{display:none!important}
html[data-social-app="x"] #tabbar .tab-btn svg{width:28px!important;height:28px!important}
html[data-social-app="x"] #tabbar .tab-btn.active{color:#fff!important}
html[data-social-app="x"] .home-indicator{background:#fff!important}

.x56-shell{flex:1;min-height:0;display:flex;flex-direction:column;background:#000;color:var(--x-text)}
.x56-head{height:58px;flex:0 0 58px;display:grid;grid-template-columns:48px 1fr 48px;align-items:center;padding:0 14px;border-bottom:1px solid var(--x-border);background:#000}
.x56-head h1{font-size:20px;line-height:1;font-weight:800;text-align:center;margin:0;color:#fff}
.x56-head button{border:0;background:none;color:#e7e9ea;padding:7px;display:grid;place-items:center}
.x56-head button svg{width:26px;height:26px}
.x56-avatar-btn .avatar{width:34px;height:34px}
.x56-scroll{flex:1;min-height:0;overflow:auto;-webkit-overflow-scrolling:touch;background:#000;padding-bottom:18px}
.x56-search-wrap{padding:10px 16px;border-bottom:1px solid var(--x-border)}
.x56-search{height:44px;border-radius:999px;background:var(--x-surface-2);display:flex;align-items:center;gap:9px;padding:0 16px;color:var(--x-muted)}
.x56-search input{flex:1;border:0;outline:0;background:transparent;color:#fff;font:inherit;font-size:16px}
.x56-search svg{width:20px;height:20px}

.x56-fab{position:absolute;right:18px;bottom:92px;width:58px;height:58px;border-radius:50%;border:0;background:var(--x-blue);color:white;display:grid;place-items:center;z-index:15;box-shadow:0 4px 18px rgba(0,0,0,.35)}
.x56-fab svg{width:27px;height:27px}
.x56-post{display:grid;grid-template-columns:46px 1fr;gap:10px;padding:13px 16px;border-bottom:1px solid var(--x-border);background:#000;color:var(--x-text)}
.x56-post .avatar{width:44px;height:44px}
.x56-post-main{min-width:0}
.x56-post-top{display:flex;gap:5px;align-items:baseline;min-width:0;font-size:15px}
.x56-post-name{font-weight:750;color:#fff;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.x56-post-handle,.x56-post-time{color:var(--x-muted);white-space:nowrap}
.x56-post-text{font-size:16px;line-height:1.34;color:#e7e9ea;margin-top:3px;white-space:pre-wrap;word-break:break-word}
.x56-post-media{margin-top:10px;border-radius:16px;border:1px solid var(--x-border);overflow:hidden;max-height:340px}
.x56-post-media img{width:100%;display:block;object-fit:cover;max-height:340px}
.x56-post-actions{display:flex;justify-content:space-between;align-items:center;margin-top:11px;color:var(--x-muted);font-size:13px}
.x56-post-actions span{display:flex;align-items:center;gap:5px}
.x56-post-actions svg{width:19px;height:19px}

.x56-empty{padding:72px 30px;text-align:center;color:var(--x-muted)}
.x56-empty strong{display:block;color:#fff;font-size:22px;margin-bottom:8px}
.x56-list-row{display:grid;grid-template-columns:52px 1fr auto;gap:12px;align-items:center;padding:13px 16px;border-bottom:1px solid var(--x-border);background:#000}
.x56-list-row .avatar{width:52px;height:52px}
.x56-row-copy{min-width:0}
.x56-row-copy strong{display:block;color:#fff;font-size:16px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.x56-row-copy small{display:block;color:var(--x-muted);font-size:15px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;margin-top:4px}
.x56-row-time{color:var(--x-muted);font-size:14px;align-self:start;margin-top:4px}
.x56-unread{width:9px;height:9px;border-radius:50%;background:var(--x-blue);display:inline-block;margin-left:8px}

.x56-dm-room{flex:1;min-height:0;display:flex;flex-direction:column;background:#000}
.x56-dm-list{flex:1;min-height:0;overflow:auto;padding:14px 16px 18px;display:flex;flex-direction:column;gap:8px}
.x56-dm-bubble{max-width:76%;padding:10px 14px;border-radius:22px;font-size:16px;line-height:1.3;white-space:pre-wrap;word-break:break-word}
.x56-dm-bubble.out{align-self:flex-end;background:var(--x-blue);color:#fff;border-bottom-right-radius:6px}
.x56-dm-bubble.in{align-self:flex-start;background:#2f3336;color:#fff;border-bottom-left-radius:6px}
.x56-dm-time{font-size:11px;opacity:.72;margin-top:4px;text-align:right}
.x56-compose{display:flex;gap:8px;align-items:flex-end;padding:10px 12px calc(10px + env(safe-area-inset-bottom,0px));border-top:1px solid var(--x-border);background:#000}
.x56-compose textarea{flex:1;min-height:42px;max-height:110px;resize:none;border:1px solid var(--x-border);border-radius:22px;background:var(--x-surface-2);color:#fff;padding:10px 14px;font:inherit;outline:0}
.x56-compose button{width:42px;height:42px;border-radius:50%;border:0;background:var(--x-blue);color:#fff;font-weight:700}

.x56-notice{display:grid;grid-template-columns:34px 1fr;gap:12px;padding:14px 16px;border-bottom:1px solid var(--x-border)}
.x56-notice-icon{font-size:24px;line-height:1}
.x56-notice-copy{color:#e7e9ea;font-size:15px;line-height:1.35}
.x56-notice-copy b{color:#fff}
.x56-notice-copy small{display:block;color:var(--x-muted);margin-top:4px}

.x56-profile{padding:20px 18px}
.x56-profile-top{display:flex;align-items:flex-end;justify-content:space-between}
.x56-profile .avatar{width:88px;height:88px}
.x56-profile h2{margin:14px 0 2px;font-size:24px;color:#fff}
.x56-profile .handle{color:var(--x-muted);font-size:15px}
.x56-profile .bio{margin:16px 0;color:#e7e9ea;line-height:1.45}
.x56-profile .stats{display:flex;gap:20px;color:var(--x-muted);font-size:14px}
.x56-profile .stats b{color:#fff}
.x56-outline-btn{border:1px solid #536471;border-radius:999px;background:transparent;color:#fff;padding:8px 15px;font-weight:700}
.x56-section-title{font-size:20px;font-weight:800;color:#fff;padding:14px 16px;border-bottom:1px solid var(--x-border)}

.x56-detail-head{height:58px;display:grid;grid-template-columns:48px 1fr 48px;align-items:center;border-bottom:1px solid var(--x-border);padding:0 8px;background:#000}
.x56-detail-head h2{margin:0;text-align:center;font-size:20px}
.x56-detail-head button{border:0;background:none;color:#fff;font-size:28px}
.x56-reply-box{padding:12px 16px;border-top:1px solid var(--x-border);display:flex;gap:8px;background:#000}
.x56-reply-box input{flex:1;border:0;border-radius:22px;background:var(--x-surface-2);color:#fff;padding:11px 14px;font:inherit;outline:none}
.x56-reply-box button{border:0;border-radius:999px;padding:0 18px;background:var(--x-blue);color:#fff;font-weight:750}
.x56-social-sheet-x{background:#000;color:#fff}
.app-switch-dot.app-x{background:#000;color:#fff;border:1px solid #536471}

/* v57: consistent Yappy-style back control for X detail screens. */
.x56-detail-head .x56-back-btn{
  width:44px;
  height:44px;
  padding:0;
  display:grid;
  place-items:center;
  border:0;
  background:transparent;
  color:#fff;
  border-radius:50%;
}
.x56-detail-head .x56-back-btn svg{
  width:28px;
  height:28px;
  display:block;
  flex:0 0 28px;
}
.x56-detail-head .x56-back-btn:active{
  background:rgba(239,243,244,.1);
}

/* v58: keep X detail navigation below Yappy's fake iOS status bar. */
.x56-detail-head{
  height:calc(var(--status-h) + 58px)!important;
  min-height:calc(var(--status-h) + 58px)!important;
  padding:var(--status-h) 8px 0!important;
  flex:0 0 calc(var(--status-h) + 58px)!important;
  box-sizing:border-box;
  position:relative;
  z-index:20;
  background:#000;
}
.x56-detail-head .x56-back-btn{
  align-self:center;
}

/* v59: X post detail, replies and threaded conversations. */
.x56-post-screen{background:#000}
.x56-thread-scroll{padding-bottom:0!important}
.x56-post-detail{padding:14px 16px 0;border-bottom:1px solid var(--x-border);background:#000}
.x56-detail-author{display:grid;grid-template-columns:46px 1fr 34px;gap:10px;align-items:center}
.x56-detail-author .avatar{width:44px;height:44px}
.x56-detail-author>div{display:flex;flex-direction:column;min-width:0}
.x56-detail-author strong{font-size:16px;color:#fff;line-height:20px}
.x56-detail-author span{font-size:15px;color:var(--x-muted);line-height:19px}
.x56-more-inline,.x56-detail-more{border:0!important;background:transparent!important;color:var(--x-muted)!important;padding:6px!important}
.x56-more-inline svg,.x56-detail-more svg{width:22px!important;height:22px!important}
.x56-detail-text{font-size:23px;line-height:1.32;color:#e7e9ea;margin-top:15px;white-space:pre-wrap;word-break:break-word}
.x56-detail-media{margin-top:14px;border:1px solid var(--x-border);border-radius:16px;overflow:hidden}
.x56-detail-media img{display:block;width:100%;max-height:420px;object-fit:cover}
.x56-detail-meta{display:flex;gap:5px;align-items:center;color:var(--x-muted);font-size:14px;padding:17px 0 12px;border-bottom:1px solid var(--x-border)}
.x56-detail-meta strong{color:#e7e9ea;font-weight:700}
.x56-detail-meta b{font-weight:400;color:var(--x-muted)}
.x56-detail-counts{display:flex;gap:20px;flex-wrap:wrap;padding:12px 0;border-bottom:1px solid var(--x-border);color:var(--x-muted);font-size:14px}
.x56-detail-counts strong{color:#e7e9ea}
.x56-detail-actions{height:50px;display:flex;align-items:center;justify-content:space-around}
.x56-detail-actions button{border:0;background:transparent;color:var(--x-muted);width:48px;height:42px;display:grid;place-items:center}
.x56-detail-actions svg{width:23px;height:23px}
.x56-relevance{height:47px;display:flex;align-items:center;gap:6px;padding:0 16px;color:#71767b;font-size:14px;font-weight:700;border-bottom:1px solid var(--x-border)}
.x56-thread-list{background:#000}
.x56-no-replies{padding:36px 18px;text-align:center;color:var(--x-muted);border-bottom:1px solid var(--x-border)}
.x56-reply-row{display:grid;grid-template-columns:46px 1fr;gap:10px;padding:11px 16px 4px;background:#000}
.x56-thread-node{border-bottom:1px solid var(--x-border)}
.x56-thread-node.is-child{border-bottom:0;margin-left:0}
.x56-thread-rail{position:relative;display:flex;justify-content:center;align-items:flex-start}
.x56-thread-rail .avatar{width:44px;height:44px;position:relative;z-index:2}
.x56-thread-rail i{position:absolute;top:48px;bottom:-16px;left:50%;width:2px;transform:translateX(-50%);background:#333639;border-radius:2px}
.x56-reply-main{min-width:0;padding-bottom:8px}
.x56-reply-top{display:grid;grid-template-columns:auto minmax(0,1fr) 28px;gap:5px;align-items:center}
.x56-reply-top strong{font-size:15px;color:#fff;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.x56-reply-top span{font-size:14px;color:var(--x-muted);white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.x56-reply-top button{border:0;background:transparent;color:var(--x-muted);padding:3px}
.x56-reply-top svg{width:18px;height:18px}
.x56-replying{font-size:13px;color:var(--x-muted);margin:3px 0 2px}
.x56-replying span{color:var(--x-blue)}
.x56-reply-text{font-size:16px;line-height:1.34;color:#e7e9ea;white-space:pre-wrap;word-break:break-word}
.x56-reply-actions{margin-top:8px!important}
.x56-reply-actions button{border:0;background:transparent;color:var(--x-muted);display:flex;align-items:center;gap:4px;padding:3px 5px 3px 0;font-size:12px}
.x56-reply-actions svg{width:18px;height:18px}
.x56-thread-children{margin-left:-56px;padding-left:0}
.x56-thread-children>.x56-thread-node>.x56-reply-row{padding-left:16px}
.x56-show-replies{border:0;background:transparent;color:var(--x-blue);font-size:15px;padding:9px 0 11px;display:flex;align-items:center;gap:9px}
.x56-show-replies span{color:var(--x-muted);font-size:24px;line-height:10px}
.x56-thread-composer{flex:0 0 auto;background:#000;border-top:1px solid var(--x-border)}
.x56-reply-context{height:30px;padding:7px 16px 0;color:var(--x-muted);font-size:13px;display:flex;align-items:center;gap:4px}
.x56-reply-context[hidden]{display:none!important}
.x56-reply-context span{color:var(--x-blue)}
.x56-reply-context button{margin-left:auto;border:0;background:transparent;color:var(--x-muted);font-size:20px;line-height:1}
.x56-thread-composer .x56-reply-box{border-top:0;padding:10px 14px calc(10px + env(safe-area-inset-bottom,0px))}
.x56-thread-composer .x56-reply-box input{height:42px}
.x56-thread-composer .x56-reply-box button{min-width:70px;height:42px}

/* v60: repair threaded-reply layout and interaction. */
.x56-thread-list{
  width:100%;
  background:#000;
}
.x56-thread-node{
  width:100%;
  border-bottom:1px solid var(--x-border);
  background:#000;
}
.x56-thread-node.is-child{
  border-bottom:0;
}
.x56-reply-row{
  width:100%;
  display:grid!important;
  grid-template-columns:48px minmax(0,1fr)!important;
  gap:10px!important;
  align-items:start!important;
  padding:12px 16px 6px!important;
  margin:0!important;
  box-sizing:border-box!important;
  background:#000!important;
}
.x56-thread-rail{
  width:48px!important;
  min-width:48px!important;
  position:relative!important;
  display:flex!important;
  align-items:flex-start!important;
  justify-content:flex-start!important;
}
.x56-thread-rail .avatar{
  width:42px!important;
  height:42px!important;
  min-width:42px!important;
  flex:0 0 42px!important;
  margin:0!important;
}
.x56-thread-rail i{
  position:absolute!important;
  top:46px!important;
  bottom:-18px!important;
  left:20px!important;
  width:2px!important;
  transform:none!important;
  background:#333639!important;
  border-radius:2px!important;
}
.x56-reply-main{
  width:100%!important;
  min-width:0!important;
  padding:0 0 8px!important;
}
.x56-reply-top{
  width:100%;
  display:flex!important;
  align-items:center!important;
  gap:5px!important;
}
.x56-reply-top strong{
  flex:0 0 auto;
  max-width:42%;
}
.x56-reply-top span{
  flex:1 1 auto;
  min-width:0;
}
.x56-reply-top button{
  flex:0 0 26px;
  margin-left:auto;
}
.x56-reply-text{
  margin-top:2px;
}
.x56-reply-actions{
  width:100%;
  display:grid!important;
  grid-template-columns:repeat(4,minmax(0,1fr))!important;
  gap:0!important;
  justify-content:stretch!important;
  align-items:center!important;
}
.x56-reply-actions button{
  min-height:34px;
  display:flex!important;
  align-items:center!important;
  justify-content:flex-start!important;
  gap:4px!important;
  color:var(--x-muted)!important;
  cursor:pointer!important;
  pointer-events:auto!important;
}
.x56-reply-actions button:first-child{
  color:var(--x-muted)!important;
}
.x56-reply-actions button:first-child:active,
.x56-reply-actions button:first-child:hover{
  color:var(--x-blue)!important;
}
.x56-thread-children{
  width:100%!important;
  margin:0!important;
  padding:0!important;
}
.x56-thread-children .x56-reply-row{
  padding-left:16px!important;
}
.x56-thread-children .x56-thread-rail{
  margin-left:0!important;
}
.x56-show-replies{
  margin:0!important;
  padding:8px 0 12px!important;
  cursor:pointer!important;
  pointer-events:auto!important;
}
.x56-thread-composer .x56-reply-box{
  display:grid!important;
  grid-template-columns:38px minmax(0,1fr) auto!important;
  align-items:center!important;
  gap:8px!important;
}
.x56-reply-author{
  width:36px!important;
  height:36px!important;
  padding:0!important;
  border:0!important;
  border-radius:50%!important;
  overflow:hidden!important;
  background:transparent!important;
}
.x56-reply-author .avatar{
  width:36px!important;
  height:36px!important;
  min-width:36px!important;
  margin:0!important;
}
.x56-thread-composer .x56-reply-box input{
  min-width:0!important;
}

/* v61: configurable X post engagement metrics in composer. */
.x56-metrics-grid{
  display:grid;
  grid-template-columns:repeat(2,minmax(0,1fr));
  gap:10px;
}
.x56-metric-field{
  display:flex;
  flex-direction:column;
  gap:6px;
  min-width:0;
}
.x56-metric-field>span{
  font-size:12px;
  font-weight:650;
  color:var(--text-sub);
  letter-spacing:.02em;
}
.x56-metric-field .text-field{
  width:100%;
  min-width:0;
  box-sizing:border-box;
  font-variant-numeric:tabular-nums;
}
.x56-metric-field:last-child{
  grid-column:1/-1;
}
html[data-social-app="x"] .x56-post-submit{
  background:var(--x-blue)!important;
  color:#fff!important;
}

/* v62: tappable post/reply action targets. */
.x56-post[data-x-post],
.x56-post-detail,
.x56-thread-node[data-x-reply-node]{
  cursor:pointer;
}
.x56-post[data-x-post]:active,
.x56-post-detail:active,
.x56-thread-node[data-x-reply-node]:active{
  background:rgba(239,243,244,.035);
}
.x56-visited-profile .x56-profile-top{
  justify-content:flex-start;
}

/* v63: X threads stay on one left grid; nested replies do not indent. */
.x56-thread-children{
  margin-left:-58px!important;
  width:calc(100% + 58px)!important;
  max-width:none!important;
  padding:0!important;
}
.x56-thread-children>.x56-thread-node{
  width:100%!important;
  margin:0!important;
  padding:0!important;
}
.x56-thread-children .x56-reply-row{
  grid-template-columns:48px minmax(0,1fr)!important;
  padding:12px 16px 6px!important;
}
.x56-thread-children .x56-thread-rail{
  width:48px!important;
  min-width:48px!important;
  margin:0!important;
}
.x56-thread-children .x56-reply-main{
  width:100%!important;
  min-width:0!important;
}
.x56-thread-rail i{
  bottom:-20px!important;
}

/* Match X's compact reply/repost action proportions. */
.x56-post-actions svg,
.x56-reply-actions svg,
.x56-detail-actions svg{
  width:20px!important;
  height:20px!important;
  flex:0 0 20px!important;
  overflow:visible!important;
}
.x56-reply-actions button{
  gap:5px!important;
}


/* v64: keep every expanded reply on the same X timeline grid. */
.x56-thread-scroll,
.x56-thread-list{
  overflow-x:hidden!important;
}
.x56-thread-children{
  width:100%!important;
  max-width:100%!important;
  margin:0!important;
  padding:0!important;
  box-sizing:border-box!important;
}
.x56-thread-children>.x56-thread-node,
.x56-thread-children .x56-thread-node{
  width:100%!important;
  max-width:100%!important;
  margin:0!important;
  padding:0!important;
  box-sizing:border-box!important;
}
.x56-thread-children .x56-reply-row{
  width:100%!important;
  grid-template-columns:48px minmax(0,1fr)!important;
  gap:10px!important;
  padding:12px 16px 6px!important;
  margin:0!important;
  box-sizing:border-box!important;
}
.x56-thread-children .x56-thread-rail{
  width:48px!important;
  min-width:48px!important;
  margin:0!important;
}
.x56-thread-children .x56-reply-main{
  width:100%!important;
  min-width:0!important;
  margin:0!important;
}
.x56-show-replies{
  width:100%!important;
  display:grid!important;
  grid-template-columns:48px minmax(0,1fr)!important;
  gap:10px!important;
  align-items:center!important;
  box-sizing:border-box!important;
  margin:0!important;
  padding:2px 16px 11px!important;
  border:0!important;
  background:#000!important;
  color:var(--x-blue)!important;
  text-align:left!important;
}
.x56-show-replies .x56-show-rail{
  width:48px;
  display:grid;
  place-items:center;
  color:var(--x-muted);
  font-size:24px;
  line-height:14px;
}
.x56-show-replies .x56-show-label{
  font-size:15px;
  line-height:22px;
}
.x56-thread-node.has-children:not(.is-expanded)>.x56-reply-row .x56-thread-rail i{
  bottom:-41px!important;
}
.x56-thread-node.is-expanded>.x56-reply-row .x56-thread-rail i{
  bottom:-15px!important;
}
.x56-reply-actions svg{
  display:block!important;
  shape-rendering:geometricPrecision;
}


/* v65: X top chrome uses the same profile glyph as the bottom-right tab. */
.x56-switch-btn{
  width:44px!important;
  height:44px!important;
  padding:0!important;
  display:grid!important;
  place-items:center!important;
  border:0!important;
  background:transparent!important;
  color:#e7e9ea!important;
  border-radius:50%!important;
}
.x56-switch-btn svg{
  width:28px!important;
  height:28px!important;
  display:block!important;
}
.x56-switch-btn:active{
  background:rgba(239,243,244,.1)!important;
}
.x56-brand-mark{
  display:inline-grid;
  place-items:center;
  width:32px;
  height:32px;
  color:#fff;
  vertical-align:middle;
}
.x56-brand-mark svg{
  width:28px!important;
  height:28px!important;
  display:block!important;
}


/* v66: connected X reply rails, perfect composer avatar, persistent detail switcher. */
.x56-detail-head{
  grid-template-columns:92px minmax(0,1fr) 48px!important;
}
.x56-detail-left{
  width:92px;
  display:flex;
  align-items:center;
  justify-content:flex-start;
  gap:0;
}
.x56-detail-left .x56-switch-btn,
.x56-detail-left .x56-back-btn{
  width:44px!important;
  height:44px!important;
  flex:0 0 44px!important;
}
.x56-detail-head h2{
  min-width:0;
  overflow:hidden;
  text-overflow:ellipsis;
  white-space:nowrap;
}

.x56-thread-node{
  position:relative;
}
.x56-thread-rail{
  align-self:stretch!important;
}
.x56-thread-node.has-children>.x56-reply-row .x56-thread-rail i{
  top:46px!important;
  bottom:-12px!important;
  left:20px!important;
  width:2px!important;
  transform:none!important;
  background:#333639!important;
  z-index:1!important;
}
.x56-thread-children{
  position:relative!important;
}
.x56-thread-children::before{
  content:"";
  position:absolute;
  left:36px;
  top:0;
  width:2px;
  height:12px;
  background:#333639;
  z-index:0;
}
.x56-thread-children>.x56-thread-node:first-child>.x56-reply-row .x56-thread-rail::before{
  content:"";
  position:absolute;
  left:20px;
  top:-12px;
  width:2px;
  height:16px;
  background:#333639;
  z-index:0;
}
.x56-thread-rail .avatar{
  z-index:2!important;
  border-radius:50%!important;
  overflow:hidden!important;
}
.x56-thread-rail .avatar img{
  width:100%!important;
  height:100%!important;
  object-fit:cover!important;
  border-radius:50%!important;
}

.x56-show-replies{
  position:relative;
}
.x56-show-replies .x56-show-rail{
  position:relative;
}
.x56-thread-node.has-children:not(.is-expanded)>.x56-reply-row .x56-thread-rail i{
  bottom:-42px!important;
}
.x56-thread-node.has-children:not(.is-expanded)>.x56-show-replies::before{
  content:"";
  position:absolute;
  left:36px;
  top:0;
  bottom:16px;
  width:2px;
  background:#333639;
  z-index:0;
}

.x56-reply-author{
  width:36px!important;
  height:36px!important;
  min-width:36px!important;
  max-width:36px!important;
  aspect-ratio:1/1!important;
  border-radius:50%!important;
  overflow:hidden!important;
  display:grid!important;
  place-items:center!important;
  line-height:0!important;
}
.x56-reply-author .avatar,
.x56-reply-author .avatar.sm{
  width:36px!important;
  height:36px!important;
  min-width:36px!important;
  max-width:36px!important;
  aspect-ratio:1/1!important;
  border-radius:50%!important;
  overflow:hidden!important;
  margin:0!important;
  padding:0!important;
  display:block!important;
}
.x56-reply-author .avatar img,
.x56-reply-author img{
  width:36px!important;
  height:36px!important;
  min-width:36px!important;
  max-width:36px!important;
  object-fit:cover!important;
  border-radius:50%!important;
  display:block!important;
}


/* v67: per-engagement visibility controls. */
.x56-metric-label{
  display:flex!important;
  align-items:center!important;
  justify-content:space-between!important;
  gap:8px!important;
  min-height:24px;
}
.x56-metric-label>span{
  min-width:0;
}
.x56-metric-visibility{
  width:28px;
  height:28px;
  min-width:28px;
  padding:0;
  border:0;
  border-radius:50%;
  background:transparent;
  color:var(--x-blue);
  display:grid;
  place-items:center;
  cursor:pointer;
}
.x56-metric-visibility svg{
  width:18px;
  height:18px;
  display:block;
}
.x56-metric-visibility.is-hidden{
  color:var(--text-sub);
  opacity:.72;
}
.x56-metric-visibility:active{
  background:rgba(29,155,240,.12);
}
.x56-post-actions:empty,
.x56-detail-counts:empty,
.x56-detail-actions:empty{
  display:none!important;
}
.x56-reply-actions{
  gap:10px;
}
.x56-reply-actions button{
  min-width:0;
  white-space:nowrap;
}


/* v68: WA-style clock/settings control inside X reply composer. */
.x56-thread-composer .x56-reply-box{
  grid-template-columns:38px minmax(0,1fr) auto!important;
}
.x56-reply-input-wrap{
  min-width:0;
  height:44px;
  display:flex;
  align-items:center;
  gap:4px;
  padding:0 6px 0 8px;
  border-radius:22px;
  background:var(--x-surface-2);
  box-sizing:border-box;
}
.x56-thread-composer .x56-reply-box .x56-reply-input-wrap input{
  flex:1!important;
  min-width:0!important;
  height:100%!important;
  padding:0 6px!important;
  border:0!important;
  border-radius:0!important;
  background:transparent!important;
  color:#fff!important;
  outline:0!important;
}
.x56-reply-settings{
  width:30px!important;
  height:30px!important;
  min-width:30px!important;
  padding:0!important;
  border:0!important;
  border-radius:50%!important;
  background:transparent!important;
  color:var(--x-muted)!important;
  display:grid!important;
  place-items:center!important;
}
.x56-reply-settings svg{
  width:19px!important;
  height:19px!important;
  display:block!important;
}
.x56-reply-settings.is-configured{
  color:var(--x-blue)!important;
}
.x56-reply-settings:active{
  background:rgba(239,243,244,.08)!important;
}
.x56-thread-composer #x56-reply-send{
  height:38px!important;
  padding:0 15px!important;
  border-radius:999px!important;
  background:var(--x-blue)!important;
  color:#fff!important;
  font-weight:750!important;
}


/* v69: interactive X reactions, repost/quote menu, quote cards, clean reply avatar. */
.x56-post-actions .x56-action-btn,
.x56-detail-actions .x56-action-btn{
  border:0;
  background:transparent;
  color:var(--x-muted);
  padding:3px 5px 3px 0;
  margin:0;
  display:inline-flex;
  align-items:center;
  justify-content:center;
  gap:5px;
  font:inherit;
  line-height:1;
  min-width:0;
}
.x56-detail-actions .x56-action-btn{
  width:48px;
  height:42px;
  padding:0;
  border-radius:50%;
}
.x56-action-btn svg{
  color:inherit;
}
.x56-action-btn.is-reposted{
  color:#00ba7c!important;
}
.x56-action-btn.is-liked{
  color:#f91880!important;
}
.x56-action-btn.is-bookmarked{
  color:#1d9bf0!important;
}
.x56-action-btn.is-liked svg path{
  fill:currentColor;
}
.x56-action-btn:active{
  opacity:.72;
}
.x56-view-count{
  display:inline-flex;
  align-items:center;
  gap:3px;
  white-space:nowrap;
}

.x56-reply-author{
  line-height:normal!important;
  flex:0 0 36px!important;
  box-sizing:border-box!important;
}
.x56-reply-author .avatar,
.x56-reply-author .avatar.sm{
  display:flex!important;
  align-items:center!important;
  justify-content:center!important;
  line-height:1!important;
  font-size:14px!important;
  box-sizing:border-box!important;
  inset:auto!important;
  transform:none!important;
}
.x56-reply-author .avatar img,
.x56-reply-author img{
  position:static!important;
  inset:auto!important;
  transform:none!important;
}
.x56-thread-composer .x56-reply-box{
  overflow:visible!important;
}
.x56-thread-composer{
  overflow:visible!important;
}

.x56-quote-card{
  margin-top:10px;
  border:1px solid var(--x-border);
  border-radius:15px;
  padding:11px 12px;
  background:#000;
  overflow:hidden;
}
.x56-quote-head{
  display:flex;
  align-items:center;
  gap:8px;
  min-width:0;
}
.x56-quote-head .avatar{
  width:22px!important;
  height:22px!important;
  min-width:22px!important;
  font-size:9px!important;
}
.x56-quote-head>div{
  min-width:0;
  display:flex;
  align-items:baseline;
  gap:5px;
}
.x56-quote-head strong{
  color:#fff;
  font-size:14px;
  white-space:nowrap;
  overflow:hidden;
  text-overflow:ellipsis;
}
.x56-quote-head span{
  color:var(--x-muted);
  font-size:13px;
  white-space:nowrap;
  overflow:hidden;
  text-overflow:ellipsis;
}
.x56-quote-text{
  margin-top:6px;
  color:#e7e9ea;
  font-size:14px;
  line-height:1.35;
  white-space:pre-wrap;
  word-break:break-word;
}
.x56-quote-preview .x56-quote-card{
  margin:0 0 14px;
  background:#000;
  color:#fff;
}

.sheet.x56-repost-sheet{
  width:min(250px,calc(100% - 40px))!important;
  margin-left:auto!important;
  margin-right:auto!important;
  margin-bottom:calc(118px + env(safe-area-inset-bottom,0px))!important;
  padding:8px!important;
  border-radius:20px!important;
  background:#16181c!important;
  color:#fff!important;
  box-shadow:0 10px 35px rgba(0,0,0,.45)!important;
  overflow:hidden!important;
}
.sheet.x56-repost-sheet .sheet-grabber{
  display:none!important;
}
.x56-repost-menu{
  display:flex;
  flex-direction:column;
  gap:2px;
}
.x56-repost-choice{
  width:100%;
  min-height:58px;
  border:0;
  border-radius:14px;
  background:transparent;
  color:#fff;
  display:grid;
  grid-template-columns:34px 1fr;
  gap:10px;
  align-items:center;
  text-align:left;
  padding:8px 12px;
  font-size:20px;
  font-weight:750;
}
.x56-repost-choice svg{
  width:26px;
  height:26px;
}
.x56-repost-choice:active{
  background:#202327;
}


/* v70: compact native-X repost popover, centered quote avatars, home-only switch control. */
.x56-head-spacer{
  width:44px;
  height:44px;
  display:block;
}
.x56-detail-head{
  grid-template-columns:48px minmax(0,1fr) 48px!important;
}
.x56-detail-left{
  width:48px!important;
}
.x56-detail-left .x56-back-btn{
  width:44px!important;
  height:44px!important;
  flex:0 0 44px!important;
}

.x56-quote-avatar{
  width:24px!important;
  height:24px!important;
  min-width:24px!important;
  max-width:24px!important;
  flex:0 0 24px!important;
  display:grid!important;
  place-items:center!important;
  overflow:hidden!important;
  border-radius:50%!important;
  line-height:1!important;
}
.x56-quote-avatar .avatar,
.x56-quote-avatar .avatar.sm{
  width:24px!important;
  height:24px!important;
  min-width:24px!important;
  max-width:24px!important;
  margin:0!important;
  padding:0!important;
  border-radius:50%!important;
  overflow:hidden!important;
  display:flex!important;
  align-items:center!important;
  justify-content:center!important;
  line-height:1!important;
  font-size:9px!important;
  position:relative!important;
  inset:auto!important;
  transform:none!important;
  box-sizing:border-box!important;
}
.x56-quote-avatar .avatar img,
.x56-quote-avatar img{
  width:100%!important;
  height:100%!important;
  max-width:none!important;
  max-height:none!important;
  object-fit:cover!important;
  object-position:center center!important;
  border-radius:50%!important;
  position:static!important;
  inset:auto!important;
  transform:none!important;
  display:block!important;
}
.x56-quote-head>.x56-quote-copy{
  min-width:0;
  display:flex;
  align-items:baseline;
  gap:5px;
}
.x56-quote-head>.x56-quote-avatar{
  align-self:center!important;
}
.x56-quote-head>div:not(.x56-quote-avatar):not(.x56-quote-copy){
  min-width:0;
}

#overlay-root:has(.x56-repost-sheet),
#overlay-root:has(.x56-quote-sheet){
  backdrop-filter:none!important;
  -webkit-backdrop-filter:none!important;
  background:rgba(0,0,0,.18)!important;
}
.sheet.x56-quote-sheet{
  max-height:min(82vh,720px)!important;
  overflow-y:auto!important;
  overscroll-behavior:contain!important;
  -webkit-overflow-scrolling:touch!important;
}
.sheet.x56-repost-sheet{
  width:min(214px,calc(100% - 54px))!important;
  margin-left:auto!important;
  margin-right:auto!important;
  margin-bottom:calc(190px + env(safe-area-inset-bottom,0px))!important;
  padding:6px!important;
  border:1px solid var(--x-border)!important;
  border-radius:16px!important;
  background:#000!important;
  color:#fff!important;
  box-shadow:0 8px 24px rgba(0,0,0,.32)!important;
}
.x56-repost-menu{
  gap:0!important;
}
.x56-repost-choice{
  min-height:50px!important;
  grid-template-columns:28px minmax(0,1fr)!important;
  gap:8px!important;
  padding:6px 10px!important;
  border-radius:10px!important;
  font-size:17px!important;
  font-weight:700!important;
}
.x56-repost-choice svg{
  width:22px!important;
  height:22px!important;
}
.x56-repost-choice+ .x56-repost-choice{
  border-top:1px solid var(--x-border)!important;
  border-radius:0 0 10px 10px!important;
}


/* v71: top-level X masthead sits visibly below Yappy's fake iOS status bar. */
html[data-social-app="x"] .x56-head{
  height:calc(var(--status-h) + 58px)!important;
  min-height:calc(var(--status-h) + 58px)!important;
  flex:0 0 calc(var(--status-h) + 58px)!important;
  padding:var(--status-h) 14px 0!important;
  box-sizing:border-box!important;
  position:relative!important;
  z-index:20!important;
  background:#000!important;
}
html[data-social-app="x"] .x56-home-shell .x56-head{
  grid-template-columns:48px minmax(0,1fr) 48px!important;
}
html[data-social-app="x"] .x56-home-shell .x56-head>div:last-child{
  width:48px;
  height:44px;
}
html[data-social-app="x"] .x56-home-shell .x56-switch-btn{
  justify-self:start!important;
}
html[data-social-app="x"] .x56-home-shell .x56-brand-mark{
  justify-self:center!important;
}


/* v72: full X profile metadata + 3:1 header image. */
.x56-profile-banner{
  width:100%;
  aspect-ratio:3/1;
  background:#333639;
  overflow:hidden;
  border-bottom:1px solid var(--x-border);
}
.x56-profile-banner img{
  width:100%;
  height:100%;
  display:block;
  object-fit:cover;
  object-position:center;
}
.x56-profile.x56-profile-with-banner{
  padding-top:0!important;
}
.x56-profile-with-banner .x56-profile-top{
  min-height:54px;
  margin-top:-44px;
  align-items:flex-end;
}
.x56-profile-with-banner .x56-profile-top>.avatar{
  width:88px!important;
  height:88px!important;
  min-width:88px!important;
  border:4px solid #000;
  box-sizing:border-box;
  border-radius:50%;
  overflow:hidden;
  background:#0f1419;
}
.x56-profile-with-banner .x56-outline-btn{
  margin-bottom:8px;
}

/* v74: native X profile spacing — keep Edit profile clear of the banner edge.
   Only the owner's Edit profile button moves; visited-profile follow controls
   keep their existing geometry. */
.x56-profile-with-banner #x56-edit-profile{
  margin-bottom:0!important;
  transform:translateY(8px);
}
.x56-profile h2{
  display:flex;
  align-items:center;
  gap:5px;
}
.x56-verified{
  display:inline-flex;
  align-items:center;
  justify-content:center;
  color:#1d9bf0;
  flex:0 0 auto;
  vertical-align:-2px;
}
.x56-verified svg{
  width:18px!important;
  height:18px!important;
  display:block;
}
.x56-post-name .x56-verified,
.x56-reply-top strong .x56-verified,
.x56-detail-author strong .x56-verified,
.x56-quote-head strong .x56-verified{
  margin-left:3px;
}
.x56-post-name .x56-verified svg,
.x56-reply-top strong .x56-verified svg,
.x56-detail-author strong .x56-verified svg,
.x56-quote-head strong .x56-verified svg{
  width:16px!important;
  height:16px!important;
}
.x56-profile-meta{
  display:flex;
  flex-wrap:wrap;
  align-items:center;
  gap:8px 14px;
  margin:10px 0 12px;
  color:var(--x-muted);
  font-size:14px;
}
.x56-profile-meta span{
  display:inline-flex;
  align-items:center;
  gap:5px;
  min-width:0;
}
.x56-profile-meta svg{
  width:17px;
  height:17px;
  flex:0 0 17px;
}
.x56-profile-link{
  color:#1d9bf0!important;
  overflow:hidden;
  text-overflow:ellipsis;
  white-space:nowrap;
  max-width:100%;
}

.x56-profile-editor-header{
  width:100%;
  aspect-ratio:3/1;
  border:1px solid var(--divider);
  border-radius:12px;
  background:#333639;
  overflow:hidden;
  display:grid;
  place-items:center;
  color:var(--text-sub);
  font-size:13px;
  box-sizing:border-box;
}
.x56-profile-editor-header img{
  width:100%;
  height:100%;
  display:block;
  object-fit:cover;
  object-position:center;
}
.x56-profile-header-actions{
  display:flex;
  gap:8px;
  margin:8px 0 4px;
}
.x56-profile-header-actions .btn{
  flex:1;
  margin:0;
}
.x56-profile-toggle{
  min-height:58px;
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:14px;
  padding:10px 12px;
  border:1px solid var(--divider);
  border-radius:12px;
  background:var(--field-bg);
  box-sizing:border-box;
}
.x56-profile-toggle>span{
  min-width:0;
  display:flex;
  flex-direction:column;
  gap:2px;
}
.x56-profile-toggle strong{
  font-size:14px;
  color:var(--text-main);
}
.x56-profile-toggle small{
  font-size:11px;
  line-height:1.3;
  color:var(--text-sub);
}
.x56-profile-toggle input{
  width:20px;
  height:20px;
  flex:0 0 auto;
  accent-color:#1d9bf0;
}


.x56-profile-photo-edit{
  display:flex;
  align-items:center;
  gap:12px;
  margin-bottom:4px;
}
#x56-profile-photo-preview{
  width:64px;
  height:64px;
  min-width:64px;
  display:grid;
  place-items:center;
  border-radius:50%;
  overflow:hidden;
  background:#0f1419;
}
#x56-profile-photo-preview .avatar,
#x56-profile-photo-preview .avatar.sm{
  width:64px!important;
  height:64px!important;
  min-width:64px!important;
  border-radius:50%!important;
  overflow:hidden!important;
  margin:0!important;
}
#x56-profile-photo-preview .avatar img{
  width:100%!important;
  height:100%!important;
  object-fit:cover!important;
  object-position:center!important;
  display:block!important;
}
.x56-profile-photo-edit .btn{
  flex:1;
  margin:0;
}


/* v73: balanced verification badge + discreet visited-profile settings. */
.x56-verified{
  width:18px!important;
  height:18px!important;
  min-width:18px!important;
  flex:0 0 18px!important;
  margin-left:4px;
  display:inline-flex!important;
  align-items:center!important;
  justify-content:center!important;
  vertical-align:-3px!important;
  line-height:1!important;
  color:#1d9bf0!important;
  position:relative;
  top:0;
}
.x56-verified svg{
  width:18px!important;
  height:18px!important;
  min-width:18px!important;
  display:block!important;
  overflow:visible!important;
  transform:none!important;
}
.x56-post-name,
.x56-detail-author strong,
.x56-reply-top strong,
.x56-quote-head strong,
.x56-profile h2{
  align-items:center;
}
.x56-post-name .x56-verified,
.x56-reply-top strong .x56-verified,
.x56-detail-author strong .x56-verified,
.x56-quote-head strong .x56-verified{
  width:16px!important;
  height:16px!important;
  min-width:16px!important;
  flex-basis:16px!important;
  margin-left:3px!important;
  vertical-align:-2px!important;
}
.x56-post-name .x56-verified svg,
.x56-reply-top strong .x56-verified svg,
.x56-detail-author strong .x56-verified svg,
.x56-quote-head strong .x56-verified svg{
  width:16px!important;
  height:16px!important;
  min-width:16px!important;
}

.x56-profile-gear{
  width:44px!important;
  height:44px!important;
  justify-self:end;
  display:grid!important;
  place-items:center!important;
  padding:0!important;
  margin:0!important;
  border:0!important;
  border-radius:50%!important;
  background:transparent!important;
  color:#e7e9ea!important;
}
.x56-profile-gear svg{
  width:22px!important;
  height:22px!important;
  display:block!important;
}
.x56-profile-gear:active{
  background:rgba(239,243,244,.1)!important;
}
.x56-visited-profile .x56-profile-top{
  justify-content:flex-start!important;
}

#x56-visited-photo-preview{
  width:64px;
  height:64px;
  min-width:64px;
  display:grid;
  place-items:center;
  border-radius:50%;
  overflow:hidden;
  background:#0f1419;
}
#x56-visited-photo-preview .avatar,
#x56-visited-photo-preview .avatar.sm{
  width:64px!important;
  height:64px!important;
  min-width:64px!important;
  margin:0!important;
  padding:0!important;
  border-radius:50%!important;
  overflow:hidden!important;
}
#x56-visited-photo-preview .avatar img,
#x56-visited-photo-preview img{
  width:100%!important;
  height:100%!important;
  object-fit:cover!important;
  object-position:center!important;
  display:block!important;
}


/* v74: X DM reply composer, clock settings and read state. */
.x56-dm-room{
  display:flex;
  flex-direction:column;
  min-height:0;
  height:100%;
  background:#000;
}
.x56-dm-list{
  flex:1;
  min-height:0;
  overflow-y:auto;
  padding:14px 12px 12px;
  display:flex;
  flex-direction:column;
  gap:6px;
  background:#000;
}
.x56-dm-message{
  width:100%;
  display:flex;
  border:0;
  padding:0;
  margin:0;
  background:transparent;
  color:inherit;
  text-align:left;
}
.x56-dm-message.out{justify-content:flex-end}
.x56-dm-message.in{justify-content:flex-start}
.x56-dm-bubble{
  max-width:79%;
  border-radius:18px;
  padding:9px 11px 6px;
  font-size:15px;
  line-height:1.34;
  box-sizing:border-box;
  word-break:break-word;
}
.x56-dm-bubble.out{
  background:#1d9bf0;
  color:#fff;
  border-bottom-right-radius:6px;
}
.x56-dm-bubble.in{
  background:#2f3336;
  color:#fff;
  border-bottom-left-radius:6px;
}
.x56-dm-text{
  white-space:pre-wrap;
}
.x56-dm-time{
  margin-top:4px;
  min-height:14px;
  display:flex;
  align-items:center;
  justify-content:flex-end;
  gap:5px;
  font-size:10px;
  line-height:14px;
  opacity:.86;
  color:inherit;
}
.x56-dm-read-dot{
  width:8px;
  height:8px;
  flex:0 0 8px;
  border:1.4px solid rgba(255,255,255,.75);
  border-radius:50%;
  box-sizing:border-box;
  background:transparent;
}
.x56-dm-read-dot.is-read{
  background:#fff;
  border-color:#fff;
}
.x56-dm-reply-card{
  margin:-2px -3px 7px;
  padding:7px 8px;
  border-left:3px solid #1d9bf0;
  border-radius:8px;
  background:rgba(0,0,0,.24);
  overflow:hidden;
}
.x56-dm-bubble.out .x56-dm-reply-card{
  border-left-color:#fff;
  background:rgba(0,0,0,.16);
}
.x56-dm-reply-who{
  font-size:11px;
  line-height:1.2;
  font-weight:750;
  margin-bottom:2px;
}
.x56-dm-reply-text{
  font-size:12px;
  line-height:1.3;
  opacity:.82;
  white-space:nowrap;
  overflow:hidden;
  text-overflow:ellipsis;
}

.x56-dm-composer{
  flex:0 0 auto;
  border-top:1px solid var(--x-border);
  background:#000;
  padding:0 10px calc(8px + env(safe-area-inset-bottom,0px));
}
.x56-dm-reply-context{
  min-height:50px;
  display:grid;
  grid-template-columns:minmax(0,1fr) 32px;
  gap:8px;
  align-items:center;
  padding:7px 5px 5px 10px;
  color:#e7e9ea;
}
.x56-dm-reply-context>div{
  min-width:0;
  padding-left:9px;
  border-left:3px solid #1d9bf0;
}
.x56-dm-reply-context strong{
  display:block;
  color:#1d9bf0;
  font-size:12px;
  line-height:1.2;
}
.x56-dm-reply-context span{
  display:block;
  margin-top:2px;
  color:var(--x-muted);
  font-size:12px;
  line-height:1.25;
  white-space:nowrap;
  overflow:hidden;
  text-overflow:ellipsis;
}
.x56-dm-reply-context button{
  width:32px;
  height:32px;
  border:0;
  border-radius:50%;
  background:transparent;
  color:var(--x-muted);
  font-size:22px;
}
.x56-dm-compose-row{
  min-height:48px;
  display:flex;
  align-items:flex-end;
  gap:8px;
}
.x56-dm-input-pill{
  flex:1;
  min-width:0;
  min-height:42px;
  display:flex;
  align-items:center;
  gap:4px;
  padding:0 7px 0 6px;
  border:1px solid var(--x-border);
  border-radius:22px;
  background:#16181c;
  box-sizing:border-box;
}
.x56-dm-input-pill textarea{
  flex:1;
  min-width:0;
  min-height:40px;
  max-height:110px;
  padding:10px 4px;
  resize:none;
  border:0;
  outline:0;
  background:transparent;
  color:#fff;
  font:inherit;
  line-height:20px;
}
.x56-dm-clock{
  width:30px;
  height:30px;
  min-width:30px;
  padding:0;
  border:0;
  border-radius:50%;
  display:grid;
  place-items:center;
  background:transparent;
  color:var(--x-muted);
}
.x56-dm-clock svg{
  width:19px;
  height:19px;
}
.x56-dm-clock.is-configured{
  color:#1d9bf0;
}
.x56-dm-send{
  width:42px;
  height:42px;
  min-width:42px;
  border:0;
  border-radius:50%;
  background:#1d9bf0;
  color:#fff;
  font-size:22px;
  font-weight:800;
  display:grid;
  place-items:center;
}


/* v76: richer multi-actor X notifications. */
.x56-notifications-scroll{
  padding-bottom:96px;
}
.x56-notice{
  display:grid!important;
  grid-template-columns:34px minmax(0,1fr)!important;
  gap:12px!important;
  padding:14px 16px!important;
  border-bottom:1px solid var(--x-border)!important;
  background:#000!important;
}
.x56-notice-icon{
  width:34px;
  height:34px;
  display:grid;
  place-items:start center;
  padding-top:1px;
}
.x56-notice-icon>span{
  width:26px;
  height:26px;
  display:grid;
  place-items:center;
}
.x56-notice-icon svg{
  width:25px!important;
  height:25px!important;
  display:block!important;
}
.x56-notice-icon .is-like{color:#f91880}
.x56-notice-icon .is-repost{color:#00ba7c}
.x56-notice-icon .is-follow{color:#1d9bf0}
.x56-notice-icon .is-reply{color:#1d9bf0}
.x56-notice-icon .is-mention{color:#1d9bf0}

.x56-notice-main{
  min-width:0;
}
.x56-notice-avatars{
  min-height:30px;
  display:flex;
  align-items:center;
  margin-bottom:8px;
}
.x56-notice-avatars>span{
  width:30px;
  height:30px;
  margin-left:-5px;
  border:2px solid #000;
  border-radius:50%;
  overflow:hidden;
  display:grid;
  place-items:center;
  background:#0f1419;
}
.x56-notice-avatars>span:first-child{
  margin-left:0;
}
.x56-notice-avatars .avatar,
.x56-notice-avatars .avatar.sm{
  width:26px!important;
  height:26px!important;
  min-width:26px!important;
  margin:0!important;
  border-radius:50%!important;
  overflow:hidden!important;
}
.x56-notice-avatars img{
  width:100%!important;
  height:100%!important;
  object-fit:cover!important;
  object-position:center!important;
  display:block!important;
}
.x56-notice-copy{
  color:#e7e9ea!important;
  font-size:15px!important;
  line-height:1.35!important;
}
.x56-notice-copy b{
  color:#fff!important;
  font-weight:750!important;
}
.x56-notice-copy small{
  display:inline!important;
  margin:0!important;
  color:var(--x-muted)!important;
  font-size:inherit!important;
}
.x56-notice-preview{
  margin-top:3px;
  color:var(--x-muted);
  font-size:14px;
  line-height:1.35;
  display:-webkit-box;
  -webkit-line-clamp:2;
  -webkit-box-orient:vertical;
  overflow:hidden;
}

.x56-notice-actor-picker{
  max-height:210px;
  overflow:auto;
  border:1px solid var(--divider);
  border-radius:12px;
  background:var(--field-bg);
  padding:4px;
}
.x56-notice-actor-row{
  min-height:46px;
  display:grid;
  grid-template-columns:22px 34px minmax(0,1fr);
  gap:9px;
  align-items:center;
  padding:5px 8px;
  border-radius:9px;
  color:var(--text-main);
}
.x56-notice-actor-row:has(input:checked){
  background:rgba(29,155,240,.1);
}
.x56-notice-actor-row input{
  width:18px;
  height:18px;
  margin:0;
  accent-color:#1d9bf0;
}
.x56-notice-actor-row .avatar,
.x56-notice-actor-row .avatar.sm{
  width:32px!important;
  height:32px!important;
  min-width:32px!important;
  border-radius:50%!important;
  overflow:hidden!important;
  margin:0!important;
}
.x56-notice-actor-row span:last-child{
  min-width:0;
  overflow:hidden;
  text-overflow:ellipsis;
  white-space:nowrap;
}
.x56-notice-live{
  margin-top:12px;
  min-height:54px;
  display:grid;
  grid-template-columns:32px minmax(0,1fr);
  gap:10px;
  align-items:center;
  padding:10px 12px;
  border:1px solid var(--divider);
  border-radius:12px;
  background:#000;
  color:#e7e9ea;
  font-size:13px;
  line-height:1.3;
}
.x56-notice-live>span{
  width:28px;
  height:28px;
  display:grid;
  place-items:center;
}
.x56-notice-live svg{
  width:24px;
  height:24px;
}
.x56-notice-live .is-like{color:#f91880}
.x56-notice-live .is-repost{color:#00ba7c}
.x56-notice-live .is-follow,
.x56-notice-live .is-reply,
.x56-notice-live .is-mention{color:#1d9bf0}


/* v77: single-actor reply/quote rules and selectable quoted tweets. */
.x56-notice-rule{
  margin:7px 0 2px;
  padding:8px 10px;
  border-radius:10px;
  background:rgba(113,118,123,.12);
  color:var(--text-sub);
  font-size:12px;
  line-height:1.35;
}
.x56-notice-post-picker{
  max-height:230px;
  overflow:auto;
  display:flex;
  flex-direction:column;
  gap:4px;
  padding:4px;
  border:1px solid var(--divider);
  border-radius:12px;
  background:var(--field-bg);
}
.x56-notice-post-row{
  min-height:62px;
  display:grid;
  grid-template-columns:20px 36px minmax(0,1fr);
  gap:9px;
  align-items:start;
  padding:7px 8px;
  border-radius:9px;
}
.x56-notice-post-row:has(input:checked){
  background:rgba(29,155,240,.1);
}
.x56-notice-post-row input{
  width:17px;
  height:17px;
  margin:7px 0 0;
  accent-color:#1d9bf0;
}
.x56-notice-post-row .avatar,
.x56-notice-post-row .avatar.sm{
  width:34px!important;
  height:34px!important;
  min-width:34px!important;
  border-radius:50%!important;
  overflow:hidden!important;
  margin:0!important;
}
.x56-notice-post-copy{
  min-width:0;
  display:flex;
  flex-direction:column;
  gap:1px;
}
.x56-notice-post-copy strong{
  color:var(--text-main);
  font-size:13px;
  line-height:1.2;
}
.x56-notice-post-copy small{
  color:var(--text-sub);
  font-size:11px;
  line-height:1.2;
  overflow:hidden;
  text-overflow:ellipsis;
  white-space:nowrap;
}
.x56-notice-post-copy em{
  margin-top:3px;
  color:var(--text-main);
  font-style:normal;
  font-size:12px;
  line-height:1.3;
  display:-webkit-box;
  -webkit-line-clamp:2;
  -webkit-box-orient:vertical;
  overflow:hidden;
}
.x56-notice-no-posts{
  padding:14px;
  border:1px dashed var(--divider);
  border-radius:12px;
  color:var(--text-sub);
  text-align:center;
  font-size:12px;
}
.x56-notice-live.is-quote-preview{
  display:block!important;
  padding:10px!important;
}
.x56-notice-live-quote{
  min-width:0;
}
.x56-notice-live-author{
  display:flex;
  align-items:center;
  gap:8px;
}
.x56-notice-live-author .avatar,
.x56-notice-live-author .avatar.sm{
  width:30px!important;
  height:30px!important;
  min-width:30px!important;
  border-radius:50%!important;
  overflow:hidden!important;
}
.x56-notice-live-author>div{
  min-width:0;
  display:flex;
  align-items:baseline;
  gap:5px;
}
.x56-notice-live-author b{
  color:#fff;
  font-size:13px;
}
.x56-notice-live-author small{
  color:var(--x-muted);
  font-size:11px;
}
.x56-notice-live-comment{
  margin-top:7px;
  color:#e7e9ea;
  font-size:13px;
  line-height:1.35;
}

.x56-notice-quote-post{
  display:grid;
  grid-template-columns:46px minmax(0,1fr);
  gap:9px;
  padding:12px 14px 8px;
  border-bottom:1px solid var(--x-border);
  background:#000;
}
.x56-notice-quote-avatar .avatar,
.x56-notice-quote-avatar .avatar.sm{
  width:42px!important;
  height:42px!important;
  min-width:42px!important;
  border-radius:50%!important;
  overflow:hidden!important;
  margin:0!important;
}
.x56-notice-quote-body{
  min-width:0;
}
.x56-notice-quote-comment{
  margin-top:3px;
  color:#e7e9ea;
  font-size:15px;
  line-height:1.35;
  white-space:pre-wrap;
}
.x56-notice-quote-post .x56-quote-card{
  margin-top:9px;
}
.x56-notice-quote-actions{
  margin-top:7px;
}
.x56-notice-quote-actions span{
  display:inline-flex;
  align-items:center;
  gap:4px;
}
.x56-notice-quote-actions svg{
  width:18px!important;
  height:18px!important;
}


/* v78: flatter X bottom nav + up to two adaptive photos in posts/replies. */
html[data-social-app="x"] #tabbar{
  height:56px!important;
  min-height:56px!important;
  padding:6px 14px calc(6px + env(safe-area-inset-bottom,0px))!important;
  border-top:1px solid var(--x-border)!important;
  background:#000!important;
  border-radius:0!important;
  margin:0!important;
  box-shadow:none!important;
  backdrop-filter:none!important;
  -webkit-backdrop-filter:none!important;
  align-items:center!important;
}
html[data-social-app="x"] #tabbar .tab-btn{
  flex:1 1 20%!important;
  min-width:0!important;
  min-height:44px!important;
  height:44px!important;
  padding:0!important;
  border-radius:0!important;
  display:grid!important;
  place-items:center!important;
}
html[data-social-app="x"] #tabbar .tab-btn svg{
  width:25px!important;
  height:25px!important;
}
html[data-social-app="x"] .home-indicator{
  display:none!important;
}
html[data-social-app="x"] .x56-fab{
  bottom:72px!important;
}

/* Media presentation */
.x56-post-media,
.x56-detail-media{
  margin-top:10px!important;
  border:1px solid var(--x-border)!important;
  border-radius:16px!important;
  overflow:hidden!important;
  max-height:none!important;
  background:#000!important;
}
.x56-detail-media{
  margin-top:14px!important;
}
.x56-media-grid{
  display:grid!important;
  gap:2px!important;
}
.x56-media-grid.count-1{
  grid-template-columns:minmax(0,1fr)!important;
}
.x56-media-grid.count-2{
  grid-template-columns:repeat(2,minmax(0,1fr))!important;
}
.x56-media-cell{
  min-width:0;
  overflow:hidden;
  background:#000;
}
.x56-media-grid.count-1 .x56-media-cell img{
  width:100%!important;
  height:auto!important;
  max-height:430px!important;
  object-fit:contain!important;
  display:block!important;
  background:#000;
}
.x56-detail-media.count-1 .x56-media-cell img{
  max-height:560px!important;
}
.x56-media-grid.count-2 .x56-media-cell{
  aspect-ratio:1/1.18;
}
.x56-media-grid.count-2 .x56-media-cell img{
  width:100%!important;
  height:100%!important;
  max-height:none!important;
  object-fit:cover!important;
  object-position:center!important;
  display:block!important;
}
.x56-reply-main .x56-post-media{
  margin-top:8px!important;
  border-radius:14px!important;
}
.x56-reply-main .x56-media-grid.count-1 .x56-media-cell img{
  max-height:300px!important;
}
.x56-quote-card .x56-post-media{
  margin:9px -12px -11px!important;
  border-width:1px 0 0!important;
  border-radius:0!important;
}
.x56-quote-card .x56-media-grid.count-1 .x56-media-cell img{
  max-height:260px!important;
}
.x56-quote-card .x56-media-grid.count-2 .x56-media-cell{
  aspect-ratio:1/1!important;
}

/* Media picker in post/reply editor sheets */
.x56-media-editor{
  margin:0 0 6px;
}
.x56-media-editor-preview{
  display:grid;
  grid-template-columns:repeat(2,minmax(0,1fr));
  gap:8px;
  margin-bottom:8px;
}
.x56-media-thumb{
  position:relative;
  min-height:0;
  aspect-ratio:1/1;
  border:1px solid var(--divider);
  border-radius:12px;
  overflow:hidden;
  background:#000;
}
.x56-media-thumb img{
  width:100%;
  height:100%;
  object-fit:cover;
  display:block;
}
.x56-media-thumb button{
  position:absolute;
  top:6px;
  right:6px;
  width:26px;
  height:26px;
  border:0;
  border-radius:50%;
  background:rgba(0,0,0,.72);
  color:#fff;
  font-size:20px;
  line-height:1;
  display:grid;
  place-items:center;
}
.x56-add-photo{
  width:100%;
  min-height:42px;
  display:flex!important;
  align-items:center;
  justify-content:center;
  gap:8px;
}
.x56-add-photo svg{
  width:19px;
  height:19px;
}
.x56-media-editor>small{
  display:block;
  margin-top:5px;
  color:var(--text-sub);
  text-align:center;
  font-size:11px;
}

/* Inline reply photo picker */
.x56-reply-input-wrap{
  overflow:visible;
}
.x56-reply-photo{
  width:30px!important;
  height:30px!important;
  min-width:30px!important;
  padding:0!important;
  border:0!important;
  border-radius:50%!important;
  background:transparent!important;
  color:var(--x-muted)!important;
  display:grid!important;
  place-items:center!important;
}
.x56-reply-photo svg{
  width:19px!important;
  height:19px!important;
}
.x56-reply-photo:disabled{
  opacity:.35;
}
.x56-reply-media-preview{
  display:grid;
  grid-template-columns:repeat(2,minmax(0,1fr));
  gap:7px;
  padding:8px 14px 0 62px;
  background:#000;
}
.x56-reply-media-preview>div{
  position:relative;
  aspect-ratio:1/1;
  border:1px solid var(--x-border);
  border-radius:12px;
  overflow:hidden;
  background:#000;
}
.x56-reply-media-preview img{
  width:100%;
  height:100%;
  object-fit:cover;
  display:block;
}
.x56-reply-media-preview button{
  position:absolute;
  top:5px;
  right:5px;
  width:24px;
  height:24px;
  border:0;
  border-radius:50%;
  background:rgba(0,0,0,.72);
  color:#fff;
  display:grid;
  place-items:center;
  font-size:18px;
  line-height:1;
}

/* Disabled single-user-only notification actions should visibly grey out. */
#x56-n-type option:disabled{
  color:#8b8f94;
}


/* v79: profile All / Posts / Replies filters and traceable reply context. */
.x56-profile-tabs{
  height:48px;
  display:grid;
  grid-template-columns:repeat(3,minmax(0,1fr));
  border-bottom:1px solid var(--x-border);
  background:#000;
  position:sticky;
  top:0;
  z-index:6;
}
.x56-profile-tabs button{
  position:relative;
  min-width:0;
  border:0;
  background:transparent;
  color:var(--x-muted);
  font:inherit;
  font-size:14px;
  font-weight:650;
  padding:0 8px;
}
.x56-profile-tabs button.active{
  color:#fff;
  font-weight:750;
}
.x56-profile-tabs button.active::after{
  content:"";
  position:absolute;
  left:50%;
  bottom:0;
  width:54px;
  max-width:74%;
  height:3px;
  transform:translateX(-50%);
  border-radius:999px;
  background:var(--x-blue);
}
.x56-profile-timeline{
  background:#000;
}
.x56-profile-empty{
  border-bottom:1px solid var(--x-border);
}

/* Replies tab: source tweet/reply is shown first, connected to the user's reply. */
.x56-profile-reply-cluster{
  padding:12px 16px 8px;
  border-bottom:1px solid var(--x-border);
  background:#000;
}
.x56-profile-reply-target,
.x56-profile-reply-own{
  display:grid;
  grid-template-columns:46px minmax(0,1fr);
  gap:10px;
}
.x56-profile-reply-target{
  color:var(--x-muted);
}
.x56-profile-reply-rail{
  position:relative;
  min-height:48px;
}
.x56-profile-reply-rail .avatar,
.x56-profile-reply-own-avatar .avatar{
  width:42px!important;
  height:42px!important;
  min-width:42px!important;
  border-radius:50%!important;
  overflow:hidden!important;
  position:relative;
  z-index:2;
}
.x56-profile-reply-rail i{
  position:absolute;
  top:46px;
  bottom:-13px;
  left:20px;
  width:2px;
  background:#333639;
  border-radius:999px;
}
.x56-profile-reply-copy,
.x56-profile-reply-own-main{
  min-width:0;
}
.x56-profile-target-text{
  margin-top:2px;
  color:#d7d9da;
  font-size:15px;
  line-height:1.32;
  white-space:pre-wrap;
  word-break:break-word;
  display:-webkit-box;
  -webkit-line-clamp:4;
  -webkit-box-orient:vertical;
  overflow:hidden;
}
.x56-profile-reply-target .x56-post-media{
  margin-top:7px!important;
  opacity:.9;
}
.x56-profile-reply-own{
  margin-top:5px;
}
.x56-profile-reply-own-avatar{
  display:flex;
  align-items:flex-start;
}
.x56-profile-reply-own-main .x56-replying{
  margin-top:2px;
}
.x56-profile-reply-own-main .x56-reply-text{
  margin-top:1px;
}
.x56-profile-reply-actions{
  margin-top:8px!important;
}
.x56-profile-reply-actions span{
  min-width:0;
}
.x56-profile-reply-cluster:active{
  background:#080808;
}


/* v80: X group DMs, DM photos, and video-thumbnail media. */
.x56-media-cell{position:relative}
.x56-media-play{
  position:absolute;
  inset:50% auto auto 50%;
  transform:translate(-50%,-50%);
  width:48px;
  height:48px;
  border-radius:50%;
  background:rgba(0,0,0,.68);
  color:#fff;
  display:grid;
  place-items:center;
  pointer-events:none;
  box-shadow:0 2px 10px rgba(0,0,0,.3);
}
.x56-media-play svg{width:24px!important;height:24px!important}
.x56-media-thumb .x56-media-play{
  width:38px;height:38px;
}
.x56-media-thumb .x56-media-play svg{width:19px!important;height:19px!important}
.x56-media-add-row{
  display:grid;
  grid-template-columns:repeat(2,minmax(0,1fr));
  gap:8px;
}
.x56-add-video{
  width:100%;
  min-height:42px;
  display:flex!important;
  align-items:center;
  justify-content:center;
  gap:8px;
}
.x56-add-video svg{width:17px!important;height:17px!important}
.x56-reply-video{
  width:30px!important;
  height:30px!important;
  min-width:30px!important;
  padding:0!important;
  border:0!important;
  border-radius:50%!important;
  background:transparent!important;
  color:var(--x-muted)!important;
  display:grid!important;
  place-items:center!important;
}
.x56-reply-video svg{width:18px!important;height:18px!important}
.x56-reply-video:disabled{opacity:.35}

/* DM list/group avatars */
.x56-group-avatar{
  width:44px;
  height:44px;
  min-width:44px;
  position:relative;
  display:block;
}
.x56-group-avatar>span{
  position:absolute;
  width:30px;
  height:30px;
  border:2px solid #000;
  border-radius:50%;
  overflow:hidden;
  background:#16181c;
}
.x56-group-avatar>span:first-child{left:0;top:0}
.x56-group-avatar>span:nth-child(2){right:0;bottom:0}
.x56-group-avatar>span .avatar,
.x56-group-avatar>span .avatar.sm{
  width:100%!important;height:100%!important;min-width:100%!important;margin:0!important;
}
.x56-dm-list-row>.x56-group-avatar{align-self:center}

/* Create-group sheet */
.x56-create-group-row .x56-create-group-icon{
  width:34px;height:34px;border-radius:50%;
  display:grid;place-items:center;
  background:#1d9bf0;color:#fff;
}
.x56-create-group-row .x56-create-group-icon svg{width:19px;height:19px}
.x56-dm-group-photo-row{
  display:flex;align-items:center;gap:12px;margin-bottom:6px;
}
#x56-dm-group-photo{
  width:66px;height:66px;min-width:66px;border-radius:50%;
  overflow:hidden;background:#202327;display:grid;place-items:center;
}
#x56-dm-group-photo img{width:100%;height:100%;object-fit:cover;display:block}
.x56-dm-group-placeholder{width:28px;height:28px;color:#71767b}
.x56-dm-group-placeholder svg{width:28px;height:28px}
.x56-dm-group-photo-row .btn{flex:1;margin:0}
.x56-dm-group-picker{
  max-height:280px;overflow:auto;
  border:1px solid var(--divider);
  border-radius:12px;padding:4px;background:var(--field-bg);
}
.x56-dm-group-person{
  min-height:48px;
  display:grid;grid-template-columns:22px 36px minmax(0,1fr);
  gap:9px;align-items:center;padding:5px 8px;border-radius:9px;
}
.x56-dm-group-person:has(input:checked){background:rgba(29,155,240,.1)}
.x56-dm-group-person input{width:18px;height:18px;margin:0;accent-color:#1d9bf0}
.x56-dm-group-person .avatar,
.x56-dm-group-person .avatar.sm{
  width:34px!important;height:34px!important;min-width:34px!important;margin:0!important;border-radius:50%!important;overflow:hidden!important;
}
.x56-dm-group-person>span{display:flex;flex-direction:column;min-width:0}
.x56-dm-group-person strong{font-size:14px;color:var(--text-main)}
.x56-dm-group-person small{font-size:11px;color:var(--text-sub);white-space:nowrap;overflow:hidden;text-overflow:ellipsis}

/* DM room closer to X screenshot */
.x56-dm-head{
  min-height:calc(var(--status-h) + 62px);
  padding:var(--status-h) 12px 6px;
  box-sizing:border-box;
  display:grid;
  grid-template-columns:44px 46px minmax(0,1fr);
  gap:8px;align-items:center;
  border-bottom:1px solid var(--x-border);
  background:#000;
  flex:0 0 auto;
}
.x56-dm-head-back{
  width:42px;height:42px;border:0;border-radius:50%;
  background:#16181c;color:#fff;display:grid;place-items:center;padding:0;
}
.x56-dm-head-back svg{width:23px;height:23px}
.x56-dm-head-avatar .avatar,
.x56-dm-head-avatar .avatar.sm{
  width:42px!important;height:42px!important;min-width:42px!important;border-radius:50%!important;overflow:hidden!important;
}
.x56-dm-head-avatar .x56-group-avatar{width:42px;height:42px;min-width:42px}
.x56-dm-head-copy{min-width:0;display:flex;flex-direction:column}
.x56-dm-head-copy strong{font-size:16px;color:#fff;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.x56-dm-head-copy small{font-size:12px;color:var(--x-muted);margin-top:1px}

.x56-dm-profile-intro{
  padding:20px 12px 24px;
  display:flex;flex-direction:column;align-items:center;text-align:center;
  color:var(--x-muted);
}
.x56-dm-profile-intro .x56-dm-profile-avatar .avatar{
  width:58px!important;height:58px!important;min-width:58px!important;border-radius:50%!important;overflow:hidden!important;
}
.x56-dm-profile-intro>strong{
  margin-top:8px;color:#fff;font-size:18px;display:flex;align-items:center;gap:4px;
}
.x56-dm-profile-intro>span{font-size:13px}
.x56-dm-profile-intro>small{margin-top:10px;font-size:13px}
.x56-dm-profile-intro>button{
  margin-top:10px;border:0;border-radius:999px;background:#2f3336;color:#fff;
  padding:8px 15px;font-weight:700;
}
.x56-dm-profile-intro.is-group .x56-group-avatar{
  width:62px;height:62px;min-width:62px;margin-bottom:6px;
}
.x56-dm-profile-intro.is-group .x56-group-avatar>span{width:42px;height:42px}

.x56-dm-group-sender{
  margin-bottom:4px;font-size:11px;font-weight:700;color:#1d9bf0;
}
.x56-dm-message.has-media .x56-dm-bubble{
  padding:4px;
  max-width:82%;
}
.x56-dm-photo{
  width:min(250px,68vw);
  max-width:100%;
  border-radius:15px;
  overflow:hidden;
  background:#111;
}
.x56-dm-photo img{
  display:block;width:100%;height:auto;max-height:330px;object-fit:contain;background:#111;
}
.x56-dm-bubble.has-media .x56-dm-text{
  padding:7px 7px 2px;
}
.x56-dm-bubble.has-media .x56-dm-time{
  padding:0 5px 2px;
}
.x56-dm-draft-media{
  position:relative;
  width:92px;height:92px;
  margin:8px 0 6px 50px;
  border:1px solid var(--x-border);
  border-radius:14px;overflow:hidden;background:#111;
}
.x56-dm-draft-media img{width:100%;height:100%;object-fit:cover;display:block}
.x56-dm-draft-media button{
  position:absolute;top:5px;right:5px;width:24px;height:24px;border:0;border-radius:50%;
  background:rgba(0,0,0,.72);color:#fff;display:grid;place-items:center;font-size:18px;
}
.x56-dm-attach{
  width:42px;height:42px;min-width:42px;border:0;border-radius:50%;
  background:#16181c;color:#fff;display:grid;place-items:center;padding:0;
}
.x56-dm-attach svg{width:21px;height:21px}


/* v82: private profile, follow states, and optional liked/reposted context. */
.x56-post-context{
  display:flex;
  align-items:center;
  gap:7px;
  min-height:22px;
  margin:0 0 5px;
  color:var(--x-muted);
  font-size:12.5px;
  line-height:1.2;
  font-weight:500;
}
.x56-post-context svg{
  width:16px!important;
  height:16px!important;
  flex:0 0 16px;
}
.x56-post-context strong{
  color:inherit;
  font-weight:650;
}
.x56-post-context.is-liked svg{color:#f91880}
.x56-post-context.is-reposted svg{color:#00ba7c}

.x56-private-lock{
  display:inline-flex;
  align-items:center;
  justify-content:center;
  width:17px;
  height:17px;
  min-width:17px;
  color:#e7e9ea;
  margin-left:2px;
}
.x56-private-lock svg{
  width:16px!important;
  height:16px!important;
  display:block!important;
}

.x56-profile-handle-row{
  display:flex;
  align-items:center;
  flex-wrap:wrap;
  gap:6px;
}
.x56-profile-handle-row .handle{
  color:var(--x-muted);
  font-size:15px;
}
.x56-follows-you{
  display:inline-flex;
  align-items:center;
  min-height:18px;
  padding:0 5px;
  border-radius:4px;
  background:#202327;
  color:#71767b;
  font-size:11px;
  line-height:18px;
  white-space:nowrap;
}

.x56-visited-profile .x56-profile-top{
  justify-content:space-between!important;
}
.x56-follow-btn{
  min-width:84px;
  min-height:36px;
  margin:0 0 8px auto;
  padding:0 15px;
  border:1px solid #536471;
  border-radius:999px;
  background:#eff3f4;
  color:#0f1419;
  font:inherit;
  font-size:14px;
  font-weight:750;
}
.x56-follow-btn.is-following{
  background:#000;
  color:#eff3f4;
}
.x56-follow-btn:active{
  opacity:.82;
}

.x56-private-protected{
  min-height:220px;
  padding:36px 30px 48px;
  border-top:1px solid var(--x-border);
  border-bottom:1px solid var(--x-border);
  display:flex;
  flex-direction:column;
  align-items:center;
  text-align:center;
  background:#000;
}
.x56-private-protected-icon{
  width:46px;
  height:46px;
  display:grid;
  place-items:center;
  margin-bottom:15px;
  color:#e7e9ea;
}
.x56-private-protected-icon svg{
  width:42px!important;
  height:42px!important;
}
.x56-private-protected strong{
  color:#e7e9ea;
  font-size:21px;
  line-height:1.25;
}
.x56-private-protected span{
  max-width:290px;
  margin-top:7px;
  color:var(--x-muted);
  font-size:14px;
  line-height:1.4;
}


/* v82 detail polish for private locks and activity labels. */
.x56-post-name .x56-private-lock,
.x56-reply-top strong .x56-private-lock,
.x56-detail-author strong .x56-private-lock,
.x56-quote-head strong .x56-private-lock{
  width:14px;
  height:14px;
  min-width:14px;
  margin-left:3px;
}
.x56-post-name .x56-private-lock svg,
.x56-reply-top strong .x56-private-lock svg,
.x56-detail-author strong .x56-private-lock svg,
.x56-quote-head strong .x56-private-lock svg{
  width:14px!important;
  height:14px!important;
}
.x56-post-detail>.x56-post-context{
  margin-bottom:9px;
}


/* v83: cleaner profile spacing around follow controls and stats. */
.x56-visited-profile .x56-follow-btn{
  position:relative;
  top:13px;
  margin:0 0 0 auto!important;
}
.x56-profile .stats{
  margin-top:12px;
}
.x56-visited-profile .x56-profile-handle-row{
  margin-top:1px;
}
.x56-visited-profile{
  padding-bottom:24px!important;
}
.x56-private-lock{
  width:16px;
  height:16px;
  min-width:16px;
}
.x56-private-lock svg{
  width:16px!important;
  height:16px!important;
}


/* v83: visually center the solid private lock beside large profile display names. */
.x56-profile h2 .x56-private-lock{
  transform:translateY(1.5px);
}


/* v84: X beta DM + welcome-thread polish. */

/* DM list and room always consume the complete X viewport. */
html[data-social-app="x"] .x56-shell,
html[data-social-app="x"] .x56-dm-room,
html[data-social-app="x"] #x56-dm-list{
  width:100%!important;
  max-width:none!important;
  box-sizing:border-box!important;
}
html[data-social-app="x"] .screen[data-key="xdm"] .x56-dm-room{
  flex:1 1 auto!important;
  height:100%!important;
  min-height:0!important;
}
html[data-social-app="x"] .x56-dm-list-row{
  width:100%!important;
  min-width:100%!important;
  max-width:100%!important;
  box-sizing:border-box!important;
  justify-self:stretch!important;
  text-align:left!important;
  margin:0!important;
  border-left:0!important;
  border-right:0!important;
}
html[data-social-app="x"] .x56-dm-list-row:focus{
  outline:none!important;
}
html[data-social-app="x"] .x56-dm-list-row:focus-visible{
  outline:2px solid var(--x-blue)!important;
  outline-offset:-2px!important;
}

/* X DMs use fully rounded bubbles — no chat-tail corner treatment. */
html[data-social-app="x"] .x56-dm-bubble,
html[data-social-app="x"] .x56-dm-bubble.out,
html[data-social-app="x"] .x56-dm-bubble.in{
  border-radius:20px!important;
}
html[data-social-app="x"] .x56-dm-message.has-media .x56-dm-bubble,
html[data-social-app="x"] .x56-dm-bubble.has-media{
  border-radius:20px!important;
  overflow:hidden!important;
}

/* The built-in welcome thread reads as one continuous conversation even though
   the tutorial replies are sibling replies rather than nested children. */
html[data-social-app="x"] .x56-thread-list.is-welcome-thread>.x56-thread-node{
  position:relative!important;
}
html[data-social-app="x"] .x56-thread-list.is-welcome-thread>.x56-thread-node:not(:last-child)::after{
  content:"";
  position:absolute;
  left:36px;
  top:58px;
  bottom:-14px;
  width:2px;
  border-radius:999px;
  background:#333639;
  z-index:0;
  pointer-events:none;
}
html[data-social-app="x"] .x56-thread-list.is-welcome-thread>.x56-thread-node>.x56-reply-row .x56-thread-rail .avatar{
  position:relative!important;
  z-index:2!important;
}


/* v86 — theme-aware X + divider-free threaded conversations. */
html[data-theme="dark"][data-social-app="x"]{
  color-scheme:dark;
  --x-bg:#000;
  --x-surface:#16181c;
  --x-surface-2:#202327;
  --x-border:#2f3336;
  --x-text:#e7e9ea;
  --x-muted:#71767b;
  --x-incoming:#2f3336;
  --x-blue:#1d9bf0;
}
html[data-theme="light"][data-social-app="x"]{
  color-scheme:light;
  --x-bg:#fff;
  --x-surface:#f7f9f9;
  --x-surface-2:#eff3f4;
  --x-border:#cfd9de;
  --x-text:#0f1419;
  --x-muted:#536471;
  --x-incoming:#eff3f4;
  --x-blue:#1d9bf0;
}

/* Final X surface ownership: follow the user's Yappy light/dark preference just like WA/iMessage. */
html[data-social-app="x"] #phone-screen,
html[data-social-app="x"] #app-root,
html[data-social-app="x"] .screen,
html[data-social-app="x"] .x56-shell,
html[data-social-app="x"] .x56-head,
html[data-social-app="x"] .x56-scroll,
html[data-social-app="x"] .x56-post,
html[data-social-app="x"] .x56-list-row,
html[data-social-app="x"] .x56-dm-room,
html[data-social-app="x"] .x56-compose,
html[data-social-app="x"] .x56-detail-head,
html[data-social-app="x"] .x56-reply-box,
html[data-social-app="x"] .x56-post-screen,
html[data-social-app="x"] .x56-post-detail,
html[data-social-app="x"] .x56-thread-list,
html[data-social-app="x"] .x56-reply-row,
html[data-social-app="x"] .x56-thread-composer,
html[data-social-app="x"] .x56-show-replies,
html[data-social-app="x"] .x56-profile-timeline,
html[data-social-app="x"] .x56-dm-head,
html[data-social-app="x"] .x56-dm-composer{
  background:var(--x-bg)!important;
  color:var(--x-text)!important;
}
html[data-social-app="x"] .statusbar{
  background:var(--x-bg)!important;
  color:var(--x-text)!important;
}
html[data-social-app="x"] #tabbar{
  background:var(--x-bg)!important;
  border-top-color:var(--x-border)!important;
}
html[data-social-app="x"] #tabbar .tab-btn,
html[data-social-app="x"] #tabbar .tab-btn.active,
html[data-social-app="x"] .x56-head h1,
html[data-social-app="x"] .x56-head button,
html[data-social-app="x"] .x56-post-name,
html[data-social-app="x"] .x56-post-text,
html[data-social-app="x"] .x56-empty strong,
html[data-social-app="x"] .x56-row-copy strong,
html[data-social-app="x"] .x56-profile h2,
html[data-social-app="x"] .x56-profile .bio,
html[data-social-app="x"] .x56-profile .stats b,
html[data-social-app="x"] .x56-section-title,
html[data-social-app="x"] .x56-detail-head,
html[data-social-app="x"] .x56-detail-head button,
html[data-social-app="x"] .x56-detail-author strong,
html[data-social-app="x"] .x56-detail-text,
html[data-social-app="x"] .x56-detail-meta strong,
html[data-social-app="x"] .x56-detail-counts strong,
html[data-social-app="x"] .x56-reply-top strong,
html[data-social-app="x"] .x56-reply-text,
html[data-social-app="x"] .x56-notice-copy,
html[data-social-app="x"] .x56-notice-copy b,
html[data-social-app="x"] .x56-dm-head-copy strong,
html[data-social-app="x"] .x56-profile-tabs button.active{
  color:var(--x-text)!important;
}
html[data-social-app="x"] .x56-search input,
html[data-social-app="x"] .x56-compose textarea,
html[data-social-app="x"] .x56-reply-box input,
html[data-social-app="x"] .x56-dm-input-pill textarea{
  color:var(--x-text)!important;
}
html[data-social-app="x"] .x56-search,
html[data-social-app="x"] .x56-compose textarea,
html[data-social-app="x"] .x56-reply-box input,
html[data-social-app="x"] .x56-dm-input-pill,
html[data-social-app="x"] .x56-notice-preview{
  background:var(--x-surface-2)!important;
}
html[data-social-app="x"] .x56-dm-bubble.in{
  background:var(--x-incoming)!important;
  color:var(--x-text)!important;
}
html[data-social-app="x"] .x56-dm-bubble.out,
html[data-social-app="x"] .x56-fab,
html[data-social-app="x"] .x56-compose button,
html[data-social-app="x"] .x56-reply-box button,
html[data-social-app="x"] .x56-dm-send,
html[data-social-app="x"] .x56-post-submit{
  color:#fff!important;
}
html[data-social-app="x"] .x56-outline-btn{
  color:var(--x-text)!important;
  border-color:var(--x-muted)!important;
}
html[data-theme="light"][data-social-app="x"] .home-indicator{background:#000!important}
html[data-theme="dark"][data-social-app="x"] .home-indicator{background:#fff!important}
html[data-theme="light"][data-social-app="x"] .app-switch-dot.app-x{
  background:#0f1419!important;color:#fff!important;border-color:#0f1419!important;
}
html[data-theme="dark"][data-social-app="x"] .app-switch-dot.app-x{
  background:#fff!important;color:#0f1419!important;border-color:#fff!important;
}

/* X threads: no horizontal separators between connected replies.
   A continuous avatar rail is the only structural divider, matching X more closely. */
html[data-social-app="x"] .x56-thread-list .x56-thread-node,
html[data-social-app="x"] .x56-thread-list .x56-thread-node.is-child,
html[data-social-app="x"] .x56-thread-children>.x56-thread-node{
  border-top:0!important;
  border-bottom:0!important;
  box-shadow:none!important;
}
html[data-social-app="x"] .x56-thread-list .x56-reply-row{
  border-top:0!important;
  border-bottom:0!important;
}
html[data-social-app="x"] .x56-thread-list>.x56-thread-node{
  position:relative!important;
}
html[data-social-app="x"] .x56-thread-list>.x56-thread-node:not(:last-child)::after{
  content:"";
  position:absolute;
  left:36px;
  top:54px;
  bottom:-18px;
  width:2px;
  border-radius:999px;
  background:var(--x-border);
  z-index:0;
  pointer-events:none;
}
html[data-social-app="x"] .x56-thread-list>.x56-thread-node>.x56-reply-row .x56-thread-rail .avatar{
  position:relative!important;
  z-index:2!important;
}
html[data-social-app="x"] .x56-thread-list>.x56-thread-node>.x56-reply-row .x56-thread-rail>i{
  background:var(--x-border)!important;
}


/* v87 — final X theme isolation + profile/thread cleanup.
   This intentionally wins over older dark-only rules so X never mixes light/dark surfaces. */
html[data-social-app="x"] .x56-profile,
html[data-social-app="x"] .x56-visited-profile,
html[data-social-app="x"] .x56-profile-tabs,
html[data-social-app="x"] .x56-profile-timeline,
html[data-social-app="x"] .x56-profile-reply-cluster,
html[data-social-app="x"] .x56-private-protected,
html[data-social-app="x"] .x56-thread-node,
html[data-social-app="x"] .x56-thread-children,
html[data-social-app="x"] .x56-no-replies,
html[data-social-app="x"] .x56-dm-profile-intro{
  background:var(--x-bg)!important;
  color:var(--x-text)!important;
}
html[data-social-app="x"] .x56-profile-tabs{
  border-bottom-color:var(--x-border)!important;
}
html[data-social-app="x"] .x56-profile-tabs button{
  color:var(--x-muted)!important;
}
html[data-social-app="x"] .x56-profile-tabs button.active{
  color:var(--x-text)!important;
}
html[data-social-app="x"] .x56-profile-empty,
html[data-social-app="x"] .x56-profile-reply-cluster,
html[data-social-app="x"] .x56-private-protected{
  border-color:var(--x-border)!important;
}
html[data-social-app="x"] .x56-profile-reply-cluster:active{
  background:var(--x-surface)!important;
}
html[data-social-app="x"] .x56-profile-target-text{
  color:var(--x-text)!important;
  opacity:.88;
}
html[data-social-app="x"] .x56-profile-gear{
  color:var(--x-text)!important;
}
html[data-social-app="x"] .x56-private-lock,
html[data-social-app="x"] .x56-private-protected-icon,
html[data-social-app="x"] .x56-private-protected strong{
  color:var(--x-text)!important;
}
html[data-social-app="x"] .x56-follows-you{
  background:var(--x-surface-2)!important;
  color:var(--x-muted)!important;
}

/* Follow controls adapt to theme instead of forcing a light button on every profile. */
html[data-theme="light"][data-social-app="x"] .x56-follow-btn{
  background:#0f1419!important;
  color:#fff!important;
  border-color:#0f1419!important;
}
html[data-theme="light"][data-social-app="x"] .x56-follow-btn.is-following{
  background:#fff!important;
  color:#0f1419!important;
  border-color:#cfd9de!important;
}
html[data-theme="dark"][data-social-app="x"] .x56-follow-btn{
  background:#eff3f4!important;
  color:#0f1419!important;
  border-color:#eff3f4!important;
}
html[data-theme="dark"][data-social-app="x"] .x56-follow-btn.is-following{
  background:#000!important;
  color:#eff3f4!important;
  border-color:#536471!important;
}

/* Header/profile avatar borders follow the active background. */
html[data-social-app="x"] .x56-profile-with-banner .x56-profile-top>.avatar{
  border-color:var(--x-bg)!important;
}
html[data-social-app="x"] .x56-group-avatar>span{
  border-color:var(--x-bg)!important;
  background:var(--x-surface)!important;
}

/* DM controls also stay in the active theme. */
html[data-social-app="x"] .x56-dm-head{
  background:var(--x-bg)!important;
  border-bottom-color:var(--x-border)!important;
}
html[data-social-app="x"] .x56-dm-head-back,
html[data-social-app="x"] .x56-dm-attach{
  background:var(--x-surface)!important;
  color:var(--x-text)!important;
}
html[data-social-app="x"] .x56-dm-head-copy strong,
html[data-social-app="x"] .x56-dm-profile-intro>strong{
  color:var(--x-text)!important;
}
html[data-social-app="x"] .x56-dm-profile-intro>button{
  background:var(--x-surface-2)!important;
  color:var(--x-text)!important;
}

/* One thin neutral rail only. Remove the extra pseudo rail introduced during welcome-thread repair. */
html[data-social-app="x"] .x56-thread-list>.x56-thread-node:not(:last-child)::after{
  content:none!important;
  display:none!important;
}
html[data-social-app="x"] .x56-thread-rail>i,
html[data-social-app="x"] .x56-profile-reply-rail>i,
html[data-social-app="x"] .x56-thread-children::before,
html[data-social-app="x"] .x56-thread-rail::before{
  width:1px!important;
  background:var(--x-border)!important;
  opacity:.82!important;
}
html[data-social-app="x"] .x56-thread-list .x56-thread-node,
html[data-social-app="x"] .x56-thread-list .x56-reply-row{
  border-top:0!important;
  border-bottom:0!important;
}

/* Light-mode media/profile cards must not retain hard-coded black fill. */
html[data-theme="light"][data-social-app="x"] .x56-quote-card,
html[data-theme="light"][data-social-app="x"] .x56-notice-preview,
html[data-theme="light"][data-social-app="x"] .x56-profile-reply-target,
html[data-theme="light"][data-social-app="x"] .x56-profile-reply-own{
  color:var(--x-text)!important;
}


/* v88 — X light composer contrast + one typography rhythm for profile timelines. */
html[data-social-app="x"] .x56-reply-input-wrap{
  background:var(--x-surface-2)!important;
  color:var(--x-text)!important;
}
html[data-social-app="x"] .x56-reply-input-wrap input,
html[data-social-app="x"] .x56-reply-box input,
html[data-social-app="x"] .x56-dm-input-pill textarea,
html[data-social-app="x"] .x56-compose textarea{
  color:var(--x-text)!important;
  caret-color:var(--x-text)!important;
  -webkit-text-fill-color:var(--x-text)!important;
  opacity:1!important;
}
html[data-social-app="x"] .x56-reply-input-wrap input::placeholder,
html[data-social-app="x"] .x56-reply-box input::placeholder,
html[data-social-app="x"] .x56-dm-input-pill textarea::placeholder,
html[data-social-app="x"] .x56-compose textarea::placeholder,
html[data-social-app="x"] .x56-search input::placeholder{
  color:var(--x-muted)!important;
  -webkit-text-fill-color:var(--x-muted)!important;
  opacity:1!important;
}
html[data-theme="light"][data-social-app="x"] .x56-reply-input-wrap{
  box-shadow:inset 0 0 0 1px rgba(15,20,25,.04);
}

/* A post and a reply inside a profile timeline use the exact same body typography. */
html[data-social-app="x"] .x56-profile-timeline .x56-post-text,
html[data-social-app="x"] .x56-profile-timeline .x56-reply-text,
html[data-social-app="x"] .x56-profile-timeline .x56-profile-target-text{
  font-size:16px!important;
  line-height:1.34!important;
  font-weight:400!important;
  letter-spacing:normal!important;
  color:var(--x-text)!important;
}
html[data-social-app="x"] .x56-profile-timeline .x56-post-top,
html[data-social-app="x"] .x56-profile-timeline .x56-reply-top{
  font-size:15px!important;
  line-height:20px!important;
  align-items:baseline!important;
}
html[data-social-app="x"] .x56-profile-timeline .x56-post-name,
html[data-social-app="x"] .x56-profile-timeline .x56-reply-top strong{
  font-size:15px!important;
  line-height:20px!important;
  font-weight:750!important;
}
html[data-social-app="x"] .x56-profile-timeline .x56-post-handle,
html[data-social-app="x"] .x56-profile-timeline .x56-post-time,
html[data-social-app="x"] .x56-profile-timeline .x56-reply-top span{
  font-size:15px!important;
  line-height:20px!important;
  font-weight:400!important;
}
html[data-social-app="x"] .x56-profile-timeline .x56-replying{
  font-size:13px!important;
  line-height:18px!important;
}

/* Keep profile chrome on the same font stack as the rest of X without overriding
   the user's global Yappy typography choice. */
html[data-social-app="x"] .x56-profile,
html[data-social-app="x"] .x56-profile-tabs,
html[data-social-app="x"] .x56-profile-timeline{
  font-family:inherit!important;
}


/* v89 — profile reply spacing.
   Give the replied-to tweet a little breathing room before the replier identity. */
html[data-social-app="x"] .x56-profile-reply-own{
  margin-top:11px!important;
}
html[data-social-app="x"] .x56-profile-reply-own-main>.x56-post-top{
  margin-top:0!important;
}
html[data-social-app="x"] .x56-profile-reply-target + .x56-profile-reply-own{
  padding-top:1px!important;
}


/* v92 — X theme parity + stable scroll physics.
   Notifications previously retained hard-coded dark surfaces in Yappy light mode. */
html[data-social-app="x"] .x56-notifications-scroll,
html[data-social-app="x"] .x56-notice,
html[data-social-app="x"] .x56-notice-quote-post{
  background:var(--x-bg)!important;
  color:var(--x-text)!important;
  border-color:var(--x-border)!important;
}
html[data-social-app="x"] .x56-notice-copy,
html[data-social-app="x"] .x56-notice-copy b,
html[data-social-app="x"] .x56-notice-live-author b,
html[data-social-app="x"] .x56-notice-live-comment,
html[data-social-app="x"] .x56-notice-quote-comment{
  color:var(--x-text)!important;
  -webkit-text-fill-color:var(--x-text)!important;
}
html[data-social-app="x"] .x56-notice-copy small,
html[data-social-app="x"] .x56-notice-live-author small,
html[data-social-app="x"] .x56-notice-preview{
  color:var(--x-muted)!important;
  -webkit-text-fill-color:var(--x-muted)!important;
}
html[data-social-app="x"] .x56-notice-preview{
  background:var(--x-surface-2)!important;
}
html[data-social-app="x"] .x56-notice-avatars>span{
  border-color:var(--x-bg)!important;
  background:var(--x-surface)!important;
}
html[data-social-app="x"] .x56-notice-live{
  background:var(--x-surface)!important;
  color:var(--x-text)!important;
  border-color:var(--x-border)!important;
}
html[data-social-app="x"] .x56-notice-quote-post .x56-quote-card{
  background:var(--x-bg)!important;
  color:var(--x-text)!important;
  border-color:var(--x-border)!important;
}
html[data-social-app="x"] .x56-notice-quote-post .x56-post-name,
html[data-social-app="x"] .x56-notice-quote-post .x56-quote-text,
html[data-social-app="x"] .x56-notice-quote-post .x56-quote-copy strong{
  color:var(--x-text)!important;
  -webkit-text-fill-color:var(--x-text)!important;
}
html[data-social-app="x"] .x56-notice-quote-post .x56-post-handle,
html[data-social-app="x"] .x56-notice-quote-post .x56-post-time,
html[data-social-app="x"] .x56-notice-quote-post .x56-quote-copy span,
html[data-social-app="x"] .x56-notice-quote-actions{
  color:var(--x-muted)!important;
  -webkit-text-fill-color:var(--x-muted)!important;
}

/* Keep every X scrolling surface self-contained inside the fake phone.
   This prevents scroll chaining/rubber-band "pulling" between nested X views. */
html[data-social-app="x"] .x56-scroll,
html[data-social-app="x"] .x56-dm-list,
html[data-social-app="x"] .x56-notice-post-picker{
  min-height:0!important;
  overflow-y:auto!important;
  overflow-x:hidden!important;
  overscroll-behavior-y:none!important;
  overscroll-behavior-x:none!important;
  scroll-behavior:auto!important;
  touch-action:pan-y!important;
  -webkit-overflow-scrolling:touch;
}
html[data-social-app="x"] .x56-shell,
html[data-social-app="x"] .x56-dm-room,
html[data-social-app="x"] .x56-post-screen{
  min-height:0!important;
  overflow:hidden!important;
}


/* v93 — X editor-control contrast + always-open real threads. */
html[data-social-app="x"] .x56-reply-settings,
html[data-social-app="x"] .x56-reply-photo,
html[data-social-app="x"] .x56-reply-video{
  color:var(--x-text)!important;
  opacity:.72!important;
}
html[data-social-app="x"] .x56-reply-settings.is-configured{
  color:var(--x-blue)!important;
  opacity:1!important;
}
html[data-social-app="x"] .x56-reply-photo:disabled,
html[data-social-app="x"] .x56-reply-video:disabled{
  opacity:.28!important;
}
html[data-theme="light"][data-social-app="x"] .x56-reply-settings:active,
html[data-theme="light"][data-social-app="x"] .x56-reply-photo:active,
html[data-theme="light"][data-social-app="x"] .x56-reply-video:active{
  background:rgba(15,20,25,.08)!important;
}
html[data-theme="dark"][data-social-app="x"] .x56-reply-settings:active,
html[data-theme="dark"][data-social-app="x"] .x56-reply-photo:active,
html[data-theme="dark"][data-social-app="x"] .x56-reply-video:active{
  background:rgba(239,243,244,.08)!important;
}

.x56-post-top{
  min-width:0!important;
}
.x56-post-more{
  width:30px!important;
  height:30px!important;
  min-width:30px!important;
  margin-left:auto!important;
  padding:0!important;
  border:0!important;
  border-radius:50%!important;
  background:transparent!important;
  color:var(--x-muted)!important;
  display:grid!important;
  place-items:center!important;
}
.x56-post-more svg{
  width:18px!important;
  height:18px!important;
}
.x56-post-more:active{
  background:rgba(29,155,240,.10)!important;
  color:var(--x-blue)!important;
}

/* Real nested replies never collapse. Only synthetic dummy branches may show a prompt. */
html[data-social-app="x"] .x56-thread-node.is-expanded>.x56-thread-children{
  display:block!important;
}
html[data-social-app="x"] .x56-show-replies:not(.is-dummy){
  display:none!important;
}


/* v94 — one canonical X thread connector color.
   Connector segments overlap at reply boundaries; keep them fully opaque so
   overlapping pieces cannot render darker than the first/top rail. */
html[data-social-app="x"] .x56-thread-rail>i,
html[data-social-app="x"] .x56-profile-reply-rail>i,
html[data-social-app="x"] .x56-thread-children::before,
html[data-social-app="x"] .x56-thread-rail::before,
html[data-social-app="x"] .x56-show-replies::before{
  width:1px!important;
  background:var(--x-border)!important;
  opacity:1!important;
  box-shadow:none!important;
}


/* v95 — final high-specificity thread rail ownership.
   Older has-children rules use #333639!important with greater specificity.
   Match/exceed that specificity so every visible connector uses one theme token. */
html[data-social-app="x"] .x56-thread-node.has-children>.x56-reply-row .x56-thread-rail>i,
html[data-social-app="x"] .x56-thread-node.is-expanded>.x56-reply-row .x56-thread-rail>i,
html[data-social-app="x"] .x56-thread-node.has-children:not(.is-expanded)>.x56-reply-row .x56-thread-rail>i,
html[data-social-app="x"] .x56-thread-children>.x56-thread-node:first-child>.x56-reply-row .x56-thread-rail::before,
html[data-social-app="x"] .x56-thread-children::before,
html[data-social-app="x"] .x56-profile-reply-cluster .x56-profile-reply-rail>i,
html[data-social-app="x"] .x56-thread-list.is-welcome-thread>.x56-thread-node>.x56-reply-row .x56-thread-rail>i,
html[data-social-app="x"] .x56-thread-list.is-welcome-thread>.x56-thread-node:not(:last-child)::after{
  background:var(--x-border)!important;
  background-color:var(--x-border)!important;
  opacity:1!important;
  box-shadow:none!important;
}

/* Keep the welcome/sibling connector implementation single-source:
   the avatar rail draws it; legacy node ::after must never reappear. */
html[data-social-app="x"] .x56-thread-list.is-welcome-thread>.x56-thread-node:not(:last-child)::after{
  content:none!important;
  display:none!important;
}


/* v99 — Explore people results are real profile entry points. */
.x56-person-result{
  grid-template-columns:52px minmax(0,1fr) auto!important;
}
.x56-person-avatar,
.x56-person-copy{
  border:0!important;
  background:transparent!important;
  color:inherit!important;
  padding:0!important;
  margin:0!important;
  font:inherit!important;
  text-align:left!important;
}
.x56-person-avatar{
  width:52px!important;
  height:52px!important;
  border-radius:50%!important;
  display:grid!important;
  place-items:center!important;
}
.x56-person-avatar .avatar{
  width:52px!important;
  height:52px!important;
}
.x56-person-copy{
  min-width:0!important;
  display:block!important;
  cursor:pointer!important;
}


/* v101 — hard-lock X profile headers to the X viewport width.
   aspect-ratio alone can still shrink in some mobile/standalone layouts.
   Container units make the rendered header exactly 3:1 everywhere. */
html[data-social-app="x"] .x56-shell{
  container-type:inline-size!important;
}
html[data-social-app="x"] .x56-profile-banner{
  width:100%!important;
  height:calc(100cqw / 3)!important;
  min-height:calc(100cqw / 3)!important;
  max-height:calc(100cqw / 3)!important;
  aspect-ratio:auto!important;
  flex:0 0 calc(100cqw / 3)!important;
  box-sizing:border-box!important;
  overflow:hidden!important;
  background:#333639!important;
}
html[data-social-app="x"] .x56-profile-banner img{
  width:100%!important;
  height:100%!important;
  min-width:100%!important;
  min-height:100%!important;
  max-width:100%!important;
  max-height:100%!important;
  display:block!important;
  object-fit:contain!important;
  object-position:center!important;
  background:#333639!important;
}
html[data-social-app="x"] .x56-profile-editor-header{
  width:100%!important;
  height:calc(100cqw / 3)!important;
  min-height:calc(100cqw / 3)!important;
  max-height:calc(100cqw / 3)!important;
  aspect-ratio:auto!important;
  box-sizing:border-box!important;
  overflow:hidden!important;
}
html[data-social-app="x"] .x56-profile-editor-header img{
  width:100%!important;
  height:100%!important;
  object-fit:contain!important;
  object-position:center!important;
  background:#333639!important;
}

/* Fallback for browsers without container query units. */
@supports not (height:1cqw){
  html[data-social-app="x"] .x56-profile-banner,
  html[data-social-app="x"] .x56-profile-editor-header{
    height:auto!important;
    min-height:0!important;
    max-height:none!important;
    aspect-ratio:3 / 1!important;
    flex:0 0 auto!important;
  }
}


/* v102 — real X header fix: prevent the avatar overlap margin from collapsing
   through the profile section and covering the bottom 44px of the banner. */
html[data-social-app="x"] .x56-shell{
  container-type:normal!important;
}
html[data-social-app="x"] .x56-profile-banner{
  width:100%!important;
  height:auto!important;
  min-height:0!important;
  max-height:none!important;
  aspect-ratio:3 / 1!important;
  flex:none!important;
  box-sizing:border-box!important;
  overflow:hidden!important;
  background:#333639!important;
}
html[data-social-app="x"] .x56-profile-banner img{
  width:100%!important;
  height:100%!important;
  min-width:100%!important;
  min-height:100%!important;
  max-width:100%!important;
  max-height:100%!important;
  display:block!important;
  object-fit:cover!important;
  object-position:center!important;
  background:#333639!important;
}
html[data-social-app="x"] .x56-profile.x56-profile-with-banner{
  display:flow-root!important;
  position:relative!important;
  overflow:visible!important;
  padding-top:0!important;
  margin-top:0!important;
  background:var(--x-bg)!important;
}
html[data-social-app="x"] .x56-profile-with-banner .x56-profile-top{
  margin-top:-44px!important;
  position:relative!important;
  z-index:3!important;
}
html[data-social-app="x"] .x56-profile-editor-header{
  width:100%!important;
  height:auto!important;
  min-height:0!important;
  max-height:none!important;
  aspect-ratio:3 / 1!important;
}
html[data-social-app="x"] .x56-profile-editor-header img{
  width:100%!important;
  height:100%!important;
  object-fit:cover!important;
  object-position:center!important;
}

/* v109 — canonical Haru-reference X timeline.
   Single adaptive source of truth for typography, alignment and engagement rows. */
html[data-social-app="x"]{
  --x-inline:clamp(14px,3.9vw,16px);
  --x-avatar:clamp(39px,10.3vw,42px);
  --x-col-gap:clamp(9px,2.45vw,10px);
  --x-name-size:clamp(14.5px,3.8vw,15.5px);
  --x-body-size:clamp(15.5px,4.05vw,16.5px);
  --x-meta-size:clamp(13.5px,3.55vw,14.5px);
  --x-action-size:clamp(12.5px,3.3vw,13.5px);
  --x-icon-size:clamp(19px,5.05vw,21px);
}
html[data-social-app="x"] .x56-shell,
html[data-social-app="x"] .x56-shell button,
html[data-social-app="x"] .x56-shell input,
html[data-social-app="x"] .x56-shell textarea,
html[data-social-app="x"] .x56-shell select,
html[data-social-app="x"] #tabbar{
  font-family:-apple-system,BlinkMacSystemFont,"SF Pro Text","SF Pro Display","Helvetica Neue",Arial,sans-serif!important;
  font-synthesis:none!important;
  -webkit-font-smoothing:antialiased!important;
}

/* One identity hierarchy everywhere. */
html[data-social-app="x"] .x56-display-name,
html[data-social-app="x"] .x56-post-name,
html[data-social-app="x"] .x56-detail-author strong,
html[data-social-app="x"] .x56-reply-top strong,
html[data-social-app="x"] .x56-quote-head strong,
html[data-social-app="x"] .x56-profile h2{
  color:var(--x-text)!important;
  -webkit-text-fill-color:var(--x-text)!important;
  font-weight:700!important;
  opacity:1!important;
}

/* Profile tabs match the reference rhythm but stay fluid on narrow/wide devices. */
html[data-social-app="x"] .x56-profile-tabs{
  height:clamp(46px,12vw,50px)!important;
}
html[data-social-app="x"] .x56-profile-tabs button{
  font-size:clamp(14px,3.7vw,15px)!important;
  line-height:1!important;
  font-weight:500!important;
}
html[data-social-app="x"] .x56-profile-tabs button.active{
  font-weight:700!important;
}
html[data-social-app="x"] .x56-profile-tabs button.active::after{
  width:clamp(48px,13vw,54px)!important;
  height:3px!important;
}

/* Home/Profile tweet geometry — same grid as Haru. */
html[data-social-app="x"] .x56-post{
  grid-template-columns:var(--x-avatar) minmax(0,1fr)!important;
  gap:var(--x-col-gap)!important;
  align-items:start!important;
  padding:clamp(10px,2.7vw,12px) var(--x-inline) clamp(7px,2vw,9px)!important;
  border-bottom:1px solid var(--x-border)!important;
}
html[data-social-app="x"] .x56-post>.avatar{
  width:var(--x-avatar)!important;
  height:var(--x-avatar)!important;
  min-width:var(--x-avatar)!important;
  min-height:var(--x-avatar)!important;
  margin:0!important;
  align-self:start!important;
  justify-self:start!important;
}
html[data-social-app="x"] .x56-post.has-context>.avatar{
  margin-top:clamp(22px,5.8vw,26px)!important;
}
html[data-social-app="x"] .x56-post-main{
  min-width:0!important;
  padding:0!important;
}
html[data-social-app="x"] .x56-post-top{
  display:flex!important;
  align-items:baseline!important;
  gap:4px!important;
  min-width:0!important;
  min-height:20px!important;
  margin:0!important;
  font-size:var(--x-name-size)!important;
  line-height:20px!important;
}
html[data-social-app="x"] .x56-post-name{
  min-width:0!important;
  flex:0 1 auto!important;
  display:inline-flex!important;
  align-items:center!important;
  overflow:hidden!important;
  white-space:nowrap!important;
  font-size:var(--x-name-size)!important;
  line-height:20px!important;
  font-weight:700!important;
}
html[data-social-app="x"] .x56-display-name{
  overflow:hidden!important;
  text-overflow:ellipsis!important;
  white-space:nowrap!important;
}
html[data-social-app="x"] .x56-post-handle,
html[data-social-app="x"] .x56-post-time{
  flex:0 1 auto!important;
  min-width:0!important;
  overflow:hidden!important;
  text-overflow:ellipsis!important;
  white-space:nowrap!important;
  color:var(--x-muted)!important;
  font-size:var(--x-name-size)!important;
  line-height:20px!important;
  font-weight:400!important;
}
html[data-social-app="x"] .x56-post-time{
  flex:0 0 auto!important;
}
html[data-social-app="x"] .x56-post-more{
  width:28px!important;
  height:28px!important;
  min-width:28px!important;
  margin:-4px -4px 0 auto!important;
  padding:4px!important;
  border:0!important;
  border-radius:50%!important;
  background:transparent!important;
  color:var(--x-muted)!important;
  display:grid!important;
  place-items:center!important;
}
html[data-social-app="x"] .x56-post-more svg{
  width:18px!important;
  height:18px!important;
}
html[data-social-app="x"] .x56-post-text,
html[data-social-app="x"] .x56-profile-timeline .x56-post-text{
  margin-top:1px!important;
  color:var(--x-text)!important;
  font-size:var(--x-body-size)!important;
  line-height:1.34!important;
  font-weight:400!important;
  letter-spacing:0!important;
}

/* Canonical six-item engagement row: reply, repost, heart, views, bookmark, share. */
html[data-social-app="x"] .x56-post-actions,
html[data-social-app="x"] .x56-profile-reply-actions{
  width:100%!important;
  min-height:clamp(27px,7.2vw,30px)!important;
  margin-top:clamp(8px,2.25vw,10px)!important;
  display:flex!important;
  align-items:center!important;
  justify-content:space-between!important;
  gap:clamp(5px,1.5vw,8px)!important;
  color:var(--x-muted)!important;
  font-size:var(--x-action-size)!important;
  line-height:1!important;
}
html[data-social-app="x"] .x56-post-actions .x56-action-btn,
html[data-social-app="x"] .x56-post-actions .x56-view-count,
html[data-social-app="x"] .x56-post-actions .x56-share-btn,
html[data-social-app="x"] .x56-profile-reply-actions>span{
  min-width:0!important;
  padding:2px 0!important;
  margin:0!important;
  border:0!important;
  background:transparent!important;
  color:inherit!important;
  display:inline-flex!important;
  align-items:center!important;
  justify-content:center!important;
  gap:4px!important;
  font:inherit!important;
  white-space:nowrap!important;
}
html[data-social-app="x"] .x56-post-actions svg,
html[data-social-app="x"] .x56-profile-reply-actions svg{
  width:var(--x-icon-size)!important;
  height:var(--x-icon-size)!important;
  flex:0 0 var(--x-icon-size)!important;
}
html[data-social-app="x"] .x56-action-btn[data-x-action="like"] svg,
html[data-social-app="x"] .x56-profile-reply-actions>span:nth-child(3) svg{
  width:calc(var(--x-icon-size) + 1px)!important;
  height:calc(var(--x-icon-size) + 1px)!important;
}
html[data-social-app="x"] .x56-action-count{
  font-size:var(--x-action-size)!important;
  line-height:1!important;
  font-weight:400!important;
}
html[data-social-app="x"] .x56-action-count:empty{
  display:none!important;
}
html[data-social-app="x"] .x56-action-btn.is-liked svg path{
  fill:currentColor!important;
}

/* Connected profile replies use exactly the same font scale/alignment as tweets. */
html[data-social-app="x"] .x56-profile-reply-cluster{
  padding:clamp(10px,2.7vw,12px) var(--x-inline) clamp(7px,2vw,9px)!important;
  border-bottom:1px solid var(--x-border)!important;
}
html[data-social-app="x"] .x56-profile-reply-target,
html[data-social-app="x"] .x56-profile-reply-own{
  grid-template-columns:var(--x-avatar) minmax(0,1fr)!important;
  gap:var(--x-col-gap)!important;
}
html[data-social-app="x"] .x56-profile-reply-rail .avatar,
html[data-social-app="x"] .x56-profile-reply-own-avatar .avatar{
  width:var(--x-avatar)!important;
  height:var(--x-avatar)!important;
  min-width:var(--x-avatar)!important;
  min-height:var(--x-avatar)!important;
}
html[data-social-app="x"] .x56-profile-reply-rail{
  min-height:calc(var(--x-avatar) + 4px)!important;
}
html[data-social-app="x"] .x56-profile-reply-rail i{
  top:calc(var(--x-avatar) + 4px)!important;
  bottom:calc(-1 * clamp(11px,3vw,14px))!important;
  left:calc(var(--x-avatar) / 2)!important;
  width:1px!important;
  transform:translateX(-50%)!important;
  background:var(--x-border)!important;
}
html[data-social-app="x"] .x56-profile-target-text,
html[data-social-app="x"] .x56-profile-reply-own-main .x56-reply-text{
  margin-top:1px!important;
  color:var(--x-text)!important;
  font-size:var(--x-body-size)!important;
  line-height:1.34!important;
  font-weight:400!important;
  letter-spacing:0!important;
}
html[data-social-app="x"] .x56-profile-reply-own{
  margin-top:clamp(9px,2.5vw,11px)!important;
}
html[data-social-app="x"] .x56-profile-reply-own-main .x56-replying{
  margin:2px 0 1px!important;
  font-size:var(--x-meta-size)!important;
  line-height:1.25!important;
}

/* Thread-detail replies keep the same identity/body system. */
html[data-social-app="x"] .x56-reply-row{
  grid-template-columns:var(--x-avatar) minmax(0,1fr)!important;
  gap:var(--x-col-gap)!important;
  padding:clamp(10px,2.7vw,12px) var(--x-inline) 5px!important;
}
html[data-social-app="x"] .x56-thread-rail .avatar{
  width:var(--x-avatar)!important;
  height:var(--x-avatar)!important;
  min-width:var(--x-avatar)!important;
  min-height:var(--x-avatar)!important;
}
html[data-social-app="x"] .x56-reply-top{
  grid-template-columns:auto minmax(0,1fr) 28px!important;
  gap:4px!important;
  min-height:20px!important;
  align-items:baseline!important;
}
html[data-social-app="x"] .x56-reply-top strong{
  font-size:var(--x-name-size)!important;
  line-height:20px!important;
  font-weight:700!important;
}
html[data-social-app="x"] .x56-reply-top span{
  font-size:var(--x-name-size)!important;
  line-height:20px!important;
  font-weight:400!important;
}
html[data-social-app="x"] .x56-reply-text{
  margin-top:1px!important;
  font-size:var(--x-body-size)!important;
  line-height:1.34!important;
  font-weight:400!important;
}

/* Badges align to the display-name optical center, without shifting the row. */
html[data-social-app="x"] .x56-post-name .x56-private-lock,
html[data-social-app="x"] .x56-reply-top strong .x56-private-lock,
html[data-social-app="x"] .x56-detail-author strong .x56-private-lock,
html[data-social-app="x"] .x56-quote-head strong .x56-private-lock{
  width:14px!important;
  height:14px!important;
  min-width:14px!important;
  flex:0 0 14px!important;
  margin-left:3px!important;
  display:inline-flex!important;
  align-self:center!important;
  transform:none!important;
}
html[data-social-app="x"] .x56-post-name .x56-verified,
html[data-social-app="x"] .x56-reply-top strong .x56-verified,
html[data-social-app="x"] .x56-detail-author strong .x56-verified,
html[data-social-app="x"] .x56-quote-head strong .x56-verified{
  width:16px!important;
  height:16px!important;
  min-width:16px!important;
  flex:0 0 16px!important;
  margin-left:3px!important;
  display:inline-flex!important;
  align-self:center!important;
  transform:none!important;
}

/* Keep post-detail cleanup from the reference pass, without reintroducing timeline overrides. */
html[data-social-app="x"] .x56-detail-head{
  grid-template-columns:44px minmax(0,1fr)!important;
}
html[data-social-app="x"] .x56-detail-head h2{
  justify-self:start!important;
  text-align:left!important;
  font-size:17px!important;
  line-height:22px!important;
  font-weight:700!important;
}
html[data-social-app="x"] .x56-detail-head>.x56-detail-more{
  display:none!important;
}
html[data-social-app="x"] .x56-post-detail{
  padding:11px var(--x-inline) 0!important;
}
html[data-social-app="x"] .x56-detail-author{
  grid-template-columns:var(--x-avatar) minmax(0,1fr) 28px!important;
  gap:var(--x-col-gap)!important;
  align-items:start!important;
}
html[data-social-app="x"] .x56-detail-author>.avatar{
  width:var(--x-avatar)!important;
  height:var(--x-avatar)!important;
  min-width:var(--x-avatar)!important;
  min-height:var(--x-avatar)!important;
}
html[data-social-app="x"] .x56-detail-author strong{
  font-size:var(--x-name-size)!important;
  line-height:20px!important;
  font-weight:700!important;
}
html[data-social-app="x"] .x56-detail-author span{
  font-size:var(--x-name-size)!important;
  line-height:20px!important;
  font-weight:400!important;
}
html[data-social-app="x"] .x56-detail-text{
  margin-top:clamp(10px,2.7vw,12px)!important;
  font-size:clamp(16.5px,4.35vw,18px)!important;
  line-height:1.36!important;
}
html[data-social-app="x"] .x56-detail-meta{
  padding:clamp(14px,3.7vw,16px) 0 11px!important;
  font-size:var(--x-meta-size)!important;
}
html[data-social-app="x"] .x56-detail-counts,
html[data-social-app="x"] .x56-relevance,
html[data-social-app="x"] .x56-no-replies{
  display:none!important;
}
html[data-social-app="x"] .x56-detail-actions{
  height:clamp(48px,12.8vw,52px)!important;
  display:flex!important;
  align-items:center!important;
  justify-content:space-around!important;
}
html[data-social-app="x"] .x56-detail-actions .x56-action-btn{
  flex:1 1 0!important;
  width:auto!important;
  min-width:0!important;
  height:44px!important;
  padding:0!important;
  display:flex!important;
  align-items:center!important;
  justify-content:center!important;
  gap:5px!important;
}
html[data-social-app="x"] .x56-detail-actions .x56-action-btn svg{
  width:clamp(21px,5.5vw,23px)!important;
  height:clamp(21px,5.5vw,23px)!important;
}
html[data-social-app="x"] .x56-thread-list{
  border-top:1px solid var(--x-border)!important;
}
html[data-social-app="x"] .x56-thread-list:empty{
  border-top:0!important;
}


/* v110 — profile header ownership + deterministic bold names in detail/thread. */
html[data-social-app="x"] .x56-profile-detail-head{
  grid-template-columns:44px minmax(0,1fr) 44px!important;
  column-gap:6px!important;
}
html[data-social-app="x"] .x56-profile-detail-head h2{
  justify-self:start!important;
  text-align:left!important;
  min-width:0!important;
}
html[data-social-app="x"] .x56-profile-detail-head .x56-profile-gear{
  grid-column:3!important;
  grid-row:1!important;
  justify-self:end!important;
  align-self:center!important;
  width:40px!important;
  height:40px!important;
  margin:0!important;
  padding:0!important;
  display:grid!important;
  place-items:center!important;
}
html[data-social-app="x"] .x56-profile-detail-head .x56-profile-gear svg{
  width:21px!important;
  height:21px!important;
}

/* Bold the actual display-name node, not only its parent strong/span wrapper. */
html[data-social-app="x"] .x56-post-screen .x56-detail-author .x56-display-name,
html[data-social-app="x"] .x56-post-screen .x56-thread-list .x56-reply-top .x56-display-name,
html[data-social-app="x"] .x56-post-screen .x56-thread-list .x56-reply-top strong,
html[data-social-app="x"] .x56-post-detail .x56-detail-author strong{
  font-family:-apple-system,BlinkMacSystemFont,"SF Pro Text","SF Pro Display","Helvetica Neue",Arial,sans-serif!important;
  font-weight:700!important;
  color:var(--x-text)!important;
  -webkit-text-fill-color:var(--x-text)!important;
  opacity:1!important;
}


/* v111 — subtle single-line separators in X post detail. */
html[data-theme="light"][data-social-app="x"] .x56-post-screen{
  --x-thread-rule:rgba(83,100,113,.18);
}
html[data-theme="dark"][data-social-app="x"] .x56-post-screen{
  --x-thread-rule:rgba(113,118,123,.28);
}

/* The main post must not add its own closing rule after the action row. */
html[data-social-app="x"] .x56-post-detail{
  border-bottom:0!important;
}
html[data-social-app="x"] .x56-detail-actions{
  border-bottom:0!important;
  box-shadow:none!important;
}

/* Metadata rule and first-reply rule share the exact same subtle treatment. */
html[data-social-app="x"] .x56-detail-meta{
  border-bottom:1px solid var(--x-thread-rule)!important;
}
html[data-social-app="x"] .x56-thread-list{
  border-top:1px solid var(--x-thread-rule)!important;
}
html[data-social-app="x"] .x56-thread-list:empty{
  border-top:0!important;
}


/* v112 — deterministic private-lock alignment + anchored X reply composer. */

/* In detail/thread the name wrapper itself must be flex; otherwise the lock's
   align-self has no effect and the glyph rides too high on the text baseline. */
html[data-social-app="x"] .x56-post-screen .x56-detail-author strong,
html[data-social-app="x"] .x56-post-screen .x56-reply-top strong{
  display:inline-flex!important;
  align-items:center!important;
  justify-content:flex-start!important;
  gap:0!important;
  min-width:0!important;
  height:20px!important;
  line-height:20px!important;
  vertical-align:top!important;
}
html[data-social-app="x"] .x56-post-screen .x56-detail-author strong .x56-display-name,
html[data-social-app="x"] .x56-post-screen .x56-reply-top strong .x56-display-name{
  display:inline-block!important;
  line-height:20px!important;
}
html[data-social-app="x"] .x56-post-screen .x56-detail-author strong .x56-private-lock,
html[data-social-app="x"] .x56-post-screen .x56-reply-top strong .x56-private-lock{
  position:static!important;
  inset:auto!important;
  top:auto!important;
  bottom:auto!important;
  width:14px!important;
  height:14px!important;
  min-width:14px!important;
  flex:0 0 14px!important;
  margin:0 0 0 4px!important;
  padding:0!important;
  display:inline-flex!important;
  align-items:center!important;
  justify-content:center!important;
  align-self:center!important;
  vertical-align:middle!important;
  line-height:1!important;
  transform:none!important;
}
html[data-social-app="x"] .x56-post-screen .x56-detail-author strong .x56-private-lock svg,
html[data-social-app="x"] .x56-post-screen .x56-reply-top strong .x56-private-lock svg{
  width:14px!important;
  height:14px!important;
  display:block!important;
  position:static!important;
  transform:none!important;
}

/* Composer is a real bottom bar, not a floating cluster. */
html[data-social-app="x"] .x56-post-screen{
  min-height:0!important;
  overflow:hidden!important;
}
html[data-social-app="x"] .x56-post-screen>.x56-thread-composer{
  position:relative!important;
  inset:auto!important;
  transform:none!important;
  flex:0 0 auto!important;
  width:100%!important;
  min-width:0!important;
  margin:0!important;
  padding:0!important;
  box-sizing:border-box!important;
  overflow:hidden!important;
  z-index:20!important;
  background:var(--x-bg)!important;
  border-top:1px solid var(--x-thread-rule,var(--x-border))!important;
  box-shadow:none!important;
  backdrop-filter:none!important;
  -webkit-backdrop-filter:none!important;
}
html[data-social-app="x"] .x56-post-screen>.x56-thread-composer .x56-reply-box{
  position:relative!important;
  inset:auto!important;
  transform:none!important;
  width:100%!important;
  min-width:0!important;
  margin:0!important;
  padding:8px var(--x-inline) calc(8px + env(safe-area-inset-bottom,0px))!important;
  box-sizing:border-box!important;
  display:grid!important;
  grid-template-columns:36px minmax(0,1fr) auto!important;
  align-items:center!important;
  gap:8px!important;
  background:var(--x-bg)!important;
  border:0!important;
  box-shadow:none!important;
  overflow:hidden!important;
}
html[data-social-app="x"] .x56-post-screen .x56-reply-author{
  width:36px!important;
  height:36px!important;
  min-width:36px!important;
  max-width:36px!important;
  margin:0!important;
  padding:0!important;
  align-self:center!important;
}
html[data-social-app="x"] .x56-post-screen .x56-reply-author .avatar,
html[data-social-app="x"] .x56-post-screen .x56-reply-author .avatar.sm,
html[data-social-app="x"] .x56-post-screen .x56-reply-author img{
  width:36px!important;
  height:36px!important;
  min-width:36px!important;
  max-width:36px!important;
}
html[data-social-app="x"] .x56-post-screen .x56-reply-input-wrap{
  position:relative!important;
  inset:auto!important;
  transform:none!important;
  width:100%!important;
  min-width:0!important;
  height:40px!important;
  margin:0!important;
  padding:0 7px!important;
  box-sizing:border-box!important;
  display:flex!important;
  align-items:center!important;
  gap:3px!important;
  border:0!important;
  border-radius:20px!important;
  background:var(--x-surface-2)!important;
  box-shadow:none!important;
}
html[data-social-app="x"] .x56-post-screen .x56-reply-input-wrap input{
  flex:1 1 auto!important;
  min-width:0!important;
  width:auto!important;
  height:38px!important;
  margin:0!important;
  padding:0 6px!important;
  border:0!important;
  border-radius:0!important;
  background:transparent!important;
  color:var(--x-text)!important;
  -webkit-text-fill-color:var(--x-text)!important;
  font-size:15px!important;
  line-height:20px!important;
  font-weight:400!important;
  outline:0!important;
  box-shadow:none!important;
}
html[data-social-app="x"] .x56-post-screen .x56-reply-input-wrap input::placeholder{
  color:var(--x-muted)!important;
  -webkit-text-fill-color:var(--x-muted)!important;
  opacity:1!important;
}
html[data-social-app="x"] .x56-post-screen .x56-reply-settings,
html[data-social-app="x"] .x56-post-screen .x56-reply-photo,
html[data-social-app="x"] .x56-post-screen .x56-reply-video{
  width:28px!important;
  height:28px!important;
  min-width:28px!important;
  margin:0!important;
  padding:0!important;
  border:0!important;
  border-radius:50%!important;
  background:transparent!important;
  color:var(--x-muted)!important;
  opacity:.78!important;
  display:grid!important;
  place-items:center!important;
  align-self:center!important;
}
html[data-social-app="x"] .x56-post-screen #x56-reply-send{
  position:static!important;
  inset:auto!important;
  transform:none!important;
  min-width:68px!important;
  height:36px!important;
  margin:0!important;
  padding:0 14px!important;
  border:0!important;
  border-radius:999px!important;
  background:var(--x-blue)!important;
  color:#fff!important;
  font-size:14px!important;
  line-height:36px!important;
  font-weight:700!important;
  box-shadow:none!important;
  align-self:center!important;
}


/* v113 — canonical responsive X bottom navigation.
   Safe-area belongs to the nav's total height, never inside a fixed 56px box. */
html[data-social-app="x"]{
  --x-nav-row:56px;
  --x-nav-safe-bottom:var(--native-safe-bottom-resolved,env(safe-area-inset-bottom,0px));
  --x-nav-total:calc(var(--x-nav-row) + var(--x-nav-safe-bottom));
}
html[data-social-app="x"] #tabbar.x56-tabs{
  position:relative!important;
  inset:auto!important;
  width:100%!important;
  max-width:100%!important;
  height:var(--x-nav-total)!important;
  min-height:var(--x-nav-total)!important;
  max-height:none!important;
  flex:0 0 var(--x-nav-total)!important;
  margin:0!important;
  padding:0 8px var(--x-nav-safe-bottom)!important;
  box-sizing:border-box!important;
  display:grid!important;
  grid-template-columns:repeat(5,minmax(0,1fr))!important;
  grid-template-rows:var(--x-nav-row)!important;
  align-items:stretch!important;
  justify-items:stretch!important;
  gap:0!important;
  overflow:hidden!important;
  border-radius:0!important;
  border-left:0!important;
  border-right:0!important;
  border-bottom:0!important;
  background:var(--x-bg)!important;
  -webkit-backdrop-filter:none!important;
  backdrop-filter:none!important;
  box-shadow:none!important;
}
html[data-social-app="x"] #tabbar.x56-tabs .tab-btn{
  width:100%!important;
  min-width:0!important;
  max-width:none!important;
  height:var(--x-nav-row)!important;
  min-height:var(--x-nav-row)!important;
  margin:0!important;
  padding:0!important;
  display:grid!important;
  place-items:center!important;
  align-self:stretch!important;
  justify-self:stretch!important;
  border:0!important;
  border-radius:0!important;
  background:transparent!important;
  overflow:visible!important;
}
html[data-social-app="x"] #tabbar.x56-tabs .tab-btn>svg{
  width:25px!important;
  height:25px!important;
  min-width:25px!important;
  max-width:25px!important;
  display:block!important;
  margin:0!important;
  flex:none!important;
}
html[data-social-app="x"] #tabbar.x56-tabs .tab-btn>span{
  display:none!important;
}
html[data-social-app="x"] .x56-fab{
  bottom:calc(var(--x-nav-total) + 16px)!important;
}

/* Very narrow devices keep equal hit targets without squeezing the icons. */
@media(max-width:350px){
  html[data-social-app="x"] #tabbar.x56-tabs{
    padding-left:4px!important;
    padding-right:4px!important;
  }
  html[data-social-app="x"] #tabbar.x56-tabs .tab-btn>svg{
    width:24px!important;
    height:24px!important;
    min-width:24px!important;
    max-width:24px!important;
  }
}


/* v114 — optically center X reply-field text in live view and captures. */
html[data-social-app="x"] .x56-post-screen .x56-reply-input-wrap input{
  height:40px!important;
  line-height:40px!important;
  padding:0 6px!important;
  transform:translateY(1px)!important;
}
html[data-social-app="x"] .x56-post-screen .x56-reply-input-wrap input::placeholder{
  line-height:40px!important;
}


/* v136: group DM identity mirrors the shared Yappy rule.
   Sender name appears on the first bubble in a run; avatar is aligned with the
   last bubble, while invisible placeholders preserve the bubble gutter. */
.x56-dm-message.is-group.in{
  align-items:flex-end;
}
.x56-dm-group-avatar-row{
  width:30px;
  height:30px;
  flex:0 0 30px;
  margin-right:7px;
  align-self:flex-end;
  display:block;
}
.x56-dm-group-avatar-row.is-hidden{
  visibility:hidden;
}
.x56-dm-group-avatar-row>.avatar{
  width:30px!important;
  height:30px!important;
  min-width:30px!important;
  font-size:10px!important;
}
.x56-dm-message.is-group.in .x56-dm-bubble{
  max-width:calc(79% - 37px);
}


/* v94 — quoted posts follow the active X theme. */
html[data-social-app="x"] .x56-quote-card,
html[data-social-app="x"] .x56-quote-preview .x56-quote-card{
  background:var(--x-bg)!important;
  color:var(--x-text)!important;
  border-color:var(--x-border)!important;
}
html[data-social-app="x"] .x56-quote-head strong,
html[data-social-app="x"] .x56-quote-text{
  color:var(--x-text)!important;
  -webkit-text-fill-color:var(--x-text)!important;
}
html[data-social-app="x"] .x56-quote-head span{
  color:var(--x-muted)!important;
  -webkit-text-fill-color:var(--x-muted)!important;
}
html[data-social-app="x"] .x56-quote-card .x56-post-media{
  border-color:var(--x-border)!important;
}


/* v86 — native X social-token tint. Public post/reply/profile copy only; DMs remain plain text. */
html[data-social-app="x"] .x56-hashtag,
html[data-social-app="x"] .x56-mention{
  color:#1d9bf0!important;
  font:inherit;
}
/* staging X refine — notification header, colored event icons, divider-free DM list */
html[data-social-app="x"] .x56-notifications-head{
  height:calc(var(--status-h) + 58px)!important;
  min-height:calc(var(--status-h) + 58px)!important;
  flex:0 0 calc(var(--status-h) + 58px)!important;
  padding:var(--status-h) 14px 0!important;
  box-sizing:border-box!important;
  display:grid!important;
  grid-template-columns:38px minmax(0,1fr) 38px!important;
  gap:10px!important;
  align-items:center!important;
  border-bottom:1px solid var(--x-border)!important;
  background:var(--x-bg)!important;
}
html[data-social-app="x"] .x56-notifications-head h1{
  margin:0!important;
  color:var(--x-text)!important;
  font-size:20px!important;
  line-height:1!important;
  font-weight:800!important;
  text-align:left!important;
}
html[data-social-app="x"] .x56-notifications-avatar{
  width:34px!important;
  height:34px!important;
  display:grid!important;
  place-items:center!important;
  overflow:hidden!important;
  border-radius:50%!important;
}
html[data-social-app="x"] .x56-notifications-avatar .avatar,
html[data-social-app="x"] .x56-notifications-avatar .avatar.sm{
  width:34px!important;
  height:34px!important;
  min-width:34px!important;
  max-width:34px!important;
  margin:0!important;
  border-radius:50%!important;
  overflow:hidden!important;
}
html[data-social-app="x"] .x56-notifications-avatar img{
  width:100%!important;
  height:100%!important;
  object-fit:cover!important;
  display:block!important;
}
html[data-social-app="x"] .x56-notifications-settings{
  width:34px!important;
  height:34px!important;
  display:grid!important;
  place-items:center!important;
  justify-self:end!important;
  color:var(--x-text)!important;
}
html[data-social-app="x"] .x56-notifications-settings svg{
  width:22px!important;
  height:22px!important;
  display:block!important;
}
html[data-social-app="x"] .x56-notice-icon .is-like svg{
  fill:currentColor!important;
}
html[data-social-app="x"] .x56-dm-list-row{
  border-top:0!important;
  border-bottom:0!important;
  box-shadow:none!important;
}

