/* SocialPress V4.10.65 — premium mobile UI layer */
:root{--sp-mobile-edge:12px;--sp-mobile-radius:18px;--sp-mobile-shadow:0 10px 30px rgba(15,23,42,.08)}
@media (max-width:860px){
  html{overflow-x:hidden;scroll-padding-top:68px}
  body{overflow-x:hidden;-webkit-tap-highlight-color:transparent;overscroll-behavior-x:none}
  body,button,input,textarea,select{font-family:inherit}
  img,video,canvas{max-width:100%}
  :where(button,a,[role="button"],input,textarea,select){touch-action:manipulation}
  :where(input,textarea,select){font-size:16px!important}
  :where(button,a,[role="button"]){-webkit-user-select:none;user-select:none}
  .sp-left,.sp-right{display:none!important}
  .sp-shell{display:block!important;width:100%!important;max-width:760px!important;margin:0 auto!important;padding:10px var(--sp-mobile-edge) calc(88px + env(safe-area-inset-bottom))!important}
  .sp-feed,.sp-app-page,.sp-settings-page,.sp-friends-page,.sp-notifications-page,.sp-live-page{width:100%!important;min-width:0!important;max-width:none!important}

  /* Compact glass header */
  .sp-topbar{height:58px!important;min-height:58px!important;position:sticky!important;top:0!important;background:color-mix(in srgb,var(--sp-card,#fff) 92%,transparent)!important;border-bottom:1px solid color-mix(in srgb,var(--sp-line,#e7eaf0) 82%,transparent)!important;box-shadow:0 7px 28px rgba(15,23,42,.055)!important;backdrop-filter:blur(18px) saturate(160%)!important;-webkit-backdrop-filter:blur(18px) saturate(160%)!important}
  .sp-topbar-inner{height:58px!important;min-height:58px!important;display:grid!important;grid-template-columns:auto minmax(0,1fr) auto!important;grid-template-areas:"brand search menu"!important;gap:8px!important;padding:7px max(10px,env(safe-area-inset-left)) 7px max(10px,env(safe-area-inset-right))!important}
  .sp-brand{grid-area:brand;min-width:0!important;gap:8px!important}
  .sp-brand-mark{width:38px!important;height:38px!important;border-radius:13px!important;box-shadow:0 6px 16px rgba(8,102,255,.22)!important}
  .sp-brand-mark .sp-icon{width:27px!important;height:27px!important}
  .sp-brand-text{font-size:17px!important;font-weight:850!important;max-width:126px!important;letter-spacing:-.03em!important}
  .sp-search{grid-area:search!important;height:40px!important;min-width:0!important;border-radius:14px!important;padding:0 11px!important;background:var(--sp-hover,#f2f5f9)!important;border:1px solid transparent!important;box-shadow:none!important}
  .sp-search input{min-width:0!important;width:100%!important;font-size:15px!important}
  .sp-mobile-menu-toggle{grid-area:menu!important;display:grid!important;place-items:center!important;width:40px!important;height:40px!important;min-width:40px!important;border:0!important;border-radius:14px!important;background:var(--sp-hover,#f2f5f9)!important;color:var(--sp-text,#111827)!important;box-shadow:none!important}
  body.logged-in .sp-topbar .sp-nav-icons{display:none!important}

  /* Drawer: clean, thumb-friendly */
  .sp-mobile-drawer{width:min(90vw,360px)!important;border-radius:0 24px 24px 0!important;border:0!important;box-shadow:24px 0 70px rgba(2,8,23,.24)!important;background:var(--sp-card,#fff)!important}
  .sp-mobile-drawer-head{padding:14px 14px 10px!important;border-bottom:0!important}
  .sp-mobile-drawer-brand small{display:none!important}
  .sp-mobile-drawer-close,.sp-mobile-theme-toggle{width:42px!important;height:42px!important;border:0!important;border-radius:14px!important;background:var(--sp-hover,#f2f5f9)!important}
  .sp-mobile-drawer-profile{padding:8px 12px 10px!important;border:0!important}
  .sp-mobile-drawer-profile a{min-height:68px!important;border:0!important;border-radius:18px!important;background:var(--sp-hover,#f2f5f9)!important;box-shadow:none!important}
  .sp-mobile-drawer-nav{padding:4px 10px 16px!important}
  .sp-mobile-menu-section{border:0!important;background:transparent!important;margin:0!important;padding:0!important}
  .sp-mobile-menu-section-toggle{min-height:34px!important;padding:0 8px!important;font-size:11px!important;text-transform:uppercase!important;letter-spacing:.06em!important;color:var(--sp-muted,#667085)!important}
  .sp-mobile-menu-grid{display:grid!important;grid-template-columns:1fr 1fr!important;gap:8px!important}
  .sp-mobile-menu-grid a{min-height:52px!important;padding:0 12px!important;border:0!important;border-radius:15px!important;background:var(--sp-hover,#f2f5f9)!important;box-shadow:none!important;font-size:13px!important}
  .sp-mobile-menu-grid a.is-active{background:var(--sp-blue-soft,#eaf3ff)!important;color:var(--sp-blue-strong,#0866ff)!important;box-shadow:inset 0 0 0 1px color-mix(in srgb,var(--sp-blue,#1677ff) 22%,transparent)!important}
  .sp-mobile-drawer-actions{padding:10px 12px calc(12px + env(safe-area-inset-bottom))!important;border-top:1px solid var(--sp-line,#e7eaf0)!important;gap:8px!important}

  /* Feed + cards */
  .sp-composer,.sp-post-card,.sp-comments-card,.sp-empty,.sp-view-head,.sp-person-card,.sp-settings-card,.sp-profile-card,.sp-profile-wide-card,.sp-friend-result,.sp-notifications-page-card{border-radius:var(--sp-mobile-radius)!important;border:1px solid var(--sp-line,#e7eaf0)!important;box-shadow:0 1px 2px rgba(15,23,42,.025)!important}
  .sp-composer{padding:11px 12px!important;margin:0 0 10px!important}
  .sp-composer-trigger{height:42px!important;font-size:14px!important}
  .sp-composer-actions{margin-top:9px!important;padding-top:7px!important}
  .sp-composer-actions button{min-height:38px!important;padding:0 6px!important;font-size:12px!important}
  .sp-post-card{margin-bottom:10px!important;overflow:hidden!important}
  .sp-post-head{padding:12px 12px 8px!important}
  .sp-post-public-title{padding-left:12px!important;padding-right:12px!important;font-size:16px!important}
  .sp-post-text{padding:4px 12px 12px!important;font-size:15px!important;line-height:1.48!important}
  .sp-social-stats{padding:9px 12px!important}
  .sp-actions{padding:4px 6px 6px!important}
  .sp-actions button,.sp-actions a{min-height:42px!important;font-size:12.5px!important;border-radius:11px!important}
  .sp-stories{margin-bottom:10px!important;padding:10px!important;border-radius:18px!important;box-shadow:none!important}

  /* All app modals become stable mobile sheets */
  :where(.sp-modal,.sp-share-modal,.sp-comments-modal){padding:0!important;align-items:flex-end!important}
  :where(.sp-modal-card,.sp-share-dialog){width:100%!important;max-width:none!important;max-height:min(92dvh,900px)!important;border-radius:24px 24px 0 0!important;margin:0!important;border:0!important;box-shadow:0 -24px 70px rgba(2,8,23,.28)!important;padding-bottom:env(safe-area-inset-bottom)!important}
  .sp-modal-head,.sp-share-head{min-height:58px!important;padding:9px 12px!important;position:sticky!important;top:0!important;z-index:3!important;background:var(--sp-card,#fff)!important;border-bottom:1px solid var(--sp-line,#e7eaf0)!important}
  .sp-modal-close,.sp-share-head button{width:40px!important;height:40px!important;border-radius:14px!important;background:var(--sp-hover,#f2f5f9)!important}

  /* Messages: native-app feeling */
  body.sp-messages-route{overflow:hidden!important}
  body.sp-messages-route .sp-shell{padding:0!important;max-width:none!important;height:calc(var(--sp-vh,1vh)*100 - 58px)!important;min-height:0!important}
  body.sp-messages-route .sp-messages-page{height:100%!important;min-height:0!important;border:0!important;border-radius:0!important;box-shadow:none!important;background:var(--sp-card,#fff)!important}
  body.sp-messages-route .sp-messenger-sidebar,body.sp-messages-route .sp-messenger-thread{height:100%!important;min-height:0!important;background:var(--sp-card,#fff)!important}
  body.sp-messages-route .sp-messenger-sidebar-head{min-height:58px!important;padding:10px 12px 8px!important}
  body.sp-messages-route .sp-messenger-sidebar-head span{display:none!important}
  body.sp-messages-route .sp-messenger-sidebar-head h1{font-size:22px!important;letter-spacing:-.025em!important}
  body.sp-messages-route .sp-chat-head{height:58px!important;min-height:58px!important;padding:7px 8px!important;border-bottom:1px solid var(--sp-line,#e7eaf0)!important;box-shadow:none!important;background:color-mix(in srgb,var(--sp-card,#fff) 94%,transparent)!important;backdrop-filter:blur(12px)!important}
  body.sp-messages-route .sp-chat-back{display:grid!important;place-items:center!important;width:42px!important;height:42px!important;min-width:42px!important;border-radius:14px!important;background:var(--sp-hover,#f2f5f9)!important}
  body.sp-messages-route .sp-chat-head-avatar,body.sp-messages-route .sp-chat-head-avatar img{width:38px!important;height:38px!important}
  body.sp-messages-route .sp-chat-person strong{font-size:14px!important}
  body.sp-messages-route .sp-chat-person small{font-size:10px!important}
  body.sp-messages-route .sp-chat-head-actions{gap:1px!important}
  body.sp-messages-route .sp-chat-head-actions button{width:38px!important;height:38px!important;border-radius:13px!important}
  body.sp-messages-route .sp-chat-head-actions button[data-chat-refresh]{display:none!important}
  body.sp-messages-route .sp-chat-scroll{padding:10px 9px 12px!important;overscroll-behavior-y:contain!important;scrollbar-width:none!important}
  body.sp-messages-route .sp-chat-scroll::-webkit-scrollbar{display:none!important}
  body.sp-messages-route .sp-chat-message{max-width:86%!important}
  body.sp-messages-route .sp-chat-bubble{font-size:14px!important;line-height:1.38!important;border-radius:18px!important;padding:9px 12px!important}
  body.sp-messages-route .sp-chat-composer{min-height:58px!important;padding:7px 8px calc(7px + env(safe-area-inset-bottom))!important;gap:4px!important;border-top:1px solid var(--sp-line,#e7eaf0)!important;background:var(--sp-card,#fff)!important}
  body.sp-messages-route .sp-chat-photo,body.sp-messages-route .sp-chat-attach,body.sp-messages-route .sp-chat-voice,body.sp-messages-route .sp-chat-send{width:40px!important;height:40px!important;min-width:40px!important;border-radius:13px!important}
  body.sp-messages-route .sp-chat-input-wrap{min-height:42px!important;padding:9px 12px!important;border-radius:18px!important;background:var(--sp-hover,#f2f5f9)!important}
  body.sp-messages-route .sp-chat-input-wrap textarea{font-size:16px!important;line-height:1.35!important;max-height:110px!important}
  body.sp-messages-route .sp-chat-voice-draft{border-radius:16px!important;min-height:48px!important}

  /* Settings / dashboard mobile density */
  .sp-settings-page{padding:0!important}
  .sp-settings-page-head{padding:8px 2px 12px!important}
  .sp-settings-page-head p,.sp-settings-section-head p{font-size:12px!important;line-height:1.4!important}
  .sp-settings-card{padding:14px!important;margin-bottom:10px!important}
  .sp-dv-shell{display:block!important;min-height:0!important}
  .sp-dv-sidebar{position:relative!important;top:auto!important;width:100%!important;height:auto!important;max-height:none!important;padding:8px!important}
  .sp-dv-workspace{padding:12px 10px 90px!important}
  .sp-dv-meta-metrics-grid.four,.sp-dv-meta-mini-metrics.three{grid-template-columns:1fr 1fr!important}

  /* LIVE: premium, minimal, video-first */
  .sp-live-page{grid-column:auto!important;padding:8px 0 calc(92px + env(safe-area-inset-bottom))!important}
  .sp-live-head{margin:0 0 10px!important;padding:0 2px!important;align-items:center!important;gap:8px!important}
  .sp-live-head>div{gap:8px!important;min-width:0!important}
  .sp-live-head-icon{display:none!important}
  .sp-live-head h1{font-size:22px!important;letter-spacing:-.035em!important;margin:0!important}
  .sp-live-head p{display:none!important}
  .sp-live-tabs{margin-left:auto!important;display:flex!important;gap:3px!important;padding:3px!important;border-radius:13px!important;background:var(--sp-hover,#f2f5f9)!important;border:0!important}
  .sp-live-tabs a{height:34px!important;min-height:34px!important;padding:0 10px!important;border:0!important;border-radius:10px!important;font-size:11px!important;font-weight:800!important;gap:5px!important;background:transparent!important}
  .sp-live-tabs a.active{background:var(--sp-card,#fff)!important;color:var(--sp-blue-strong,#0866ff)!important;box-shadow:0 2px 8px rgba(15,23,42,.08)!important}
  .sp-live-tabs a .sp-icon{width:15px!important;height:15px!important}
  .sp-live-go-card{border-radius:22px!important;border:1px solid var(--sp-line,#e7eaf0)!important;box-shadow:none!important;margin-bottom:12px!important}
  .sp-live-launch-card{min-height:82px!important;padding:13px!important;gap:10px!important;background:linear-gradient(135deg,#0e1628 0%,#17243f 58%,#142e67 100%)!important;color:#fff!important;border:0!important;overflow:hidden!important;position:relative!important}
  .sp-live-launch-card:after{content:"";position:absolute;width:130px;height:130px;right:-40px;top:-60px;border-radius:50%;background:rgba(72,145,255,.22);filter:blur(4px);pointer-events:none}
  .sp-live-go-copy{gap:10px!important;z-index:1!important}
  .sp-live-camera{width:44px!important;height:44px!important;border-radius:15px!important;background:rgba(255,255,255,.12)!important;color:#fff!important}
  .sp-live-go-copy h2{font-size:18px!important;color:#fff!important;letter-spacing:-.025em!important;margin:0!important}
  .sp-live-go-copy p{display:none!important}
  .sp-live-open-studio{width:auto!important;min-width:92px!important;height:44px!important;padding:0 14px!important;border-radius:14px!important;background:#fff!important;color:#0f1b33!important;box-shadow:none!important;z-index:1!important}
  .sp-live-broadcasts-section{margin-top:8px!important}
  .sp-live-section-title{margin-bottom:8px!important;padding:0 2px!important}
  .sp-live-section-title h2{font-size:18px!important;letter-spacing:-.025em!important}
  .sp-live-section-title p{display:none!important}
  .sp-live-section-title button{width:40px!important;height:40px!important;padding:0!important;border-radius:13px!important;background:var(--sp-hover,#f2f5f9)!important}
  .sp-live-section-title button span{display:none!important}
  .sp-live-broadcast-grid{grid-template-columns:1fr!important;gap:10px!important;padding:0!important}
  .sp-live-broadcast-card{border:1px solid var(--sp-line,#e7eaf0)!important;border-radius:20px!important;overflow:hidden!important;box-shadow:none!important;background:var(--sp-card,#fff)!important}
  .sp-live-broadcast-cover{aspect-ratio:16/9!important;border-radius:0!important;background:#06080d!important}
  .sp-live-broadcast-cover>img{width:100%!important;height:100%!important;object-fit:cover!important;filter:saturate(.88) brightness(.72)!important;transform:scale(1.02)}
  .sp-live-badge{font-size:9px!important;letter-spacing:.08em!important;border-radius:8px!important;padding:5px 7px!important;background:#ff304f!important;box-shadow:none!important}
  .sp-live-source-pill{display:none!important}
  .sp-live-viewer-pill{border:0!important;background:rgba(5,8,14,.62)!important;backdrop-filter:blur(10px)!important}
  .sp-live-broadcast-info{padding:10px!important;gap:9px!important}
  .sp-live-broadcast-info>div strong{font-size:14px!important;line-height:1.25!important}
  .sp-live-broadcast-info>div small{font-size:11px!important}
  .sp-live-broadcast-info>button{height:38px!important;min-width:74px!important;border:0!important;border-radius:12px!important;background:var(--sp-blue-strong,#0866ff)!important;color:#fff!important;font-size:12px!important;font-weight:850!important}
  .sp-live-empty-card{min-height:150px!important;border-radius:20px!important;padding:18px!important}
  .sp-live-empty-card p{font-size:12px!important;max-width:260px!important}

  /* Live studio is a true full-screen mobile creator */
  html.sp-live-studio-open,html.sp-live-viewer-open{overflow:hidden!important}
  .sp-live-studio-modal{padding:0!important;align-items:stretch!important}
  .sp-live-studio-dialog{width:100vw!important;height:100dvh!important;max-width:none!important;max-height:none!important;border-radius:0!important;display:grid!important;grid-template-rows:58px minmax(0,1fr) auto!important;background:var(--sp-card,#fff)!important}
  .sp-live-studio-head{height:58px!important;min-height:58px!important;padding:7px 10px!important;border-bottom:1px solid var(--sp-line,#e7eaf0)!important;background:var(--sp-card,#fff)!important}
  .sp-live-studio-head>div>span{width:36px!important;height:36px!important;border-radius:12px!important}
  .sp-live-studio-head h2{font-size:18px!important;letter-spacing:-.025em!important}
  .sp-live-studio-head p{display:none!important}
  .sp-live-studio-head>button{width:40px!important;height:40px!important;border-radius:13px!important;background:var(--sp-hover,#f2f5f9)!important}
  .sp-live-studio-body{display:flex!important;flex-direction:column!important;gap:12px!important;min-height:0!important;overflow-y:auto!important;padding:10px 10px 16px!important;overscroll-behavior:contain!important}
  .sp-live-studio-preview-wrap{order:-1!important;width:100%!important}
  .sp-live-studio-preview{aspect-ratio:16/9!important;min-height:0!important;border-radius:20px!important;overflow:hidden!important;background:#05070b!important;box-shadow:0 10px 28px rgba(0,0,0,.14)!important}
  .sp-live-preview-empty{gap:5px!important}
  .sp-live-preview-empty strong{font-size:13px!important}
  .sp-live-preview-empty small,.sp-live-preview-tip{display:none!important}
  .sp-live-studio-form{display:grid!important;gap:12px!important}
  .sp-live-field{gap:7px!important}
  .sp-live-field>span{font-size:11px!important;font-weight:850!important;color:var(--sp-muted,#667085)!important;text-transform:uppercase!important;letter-spacing:.05em!important}
  .sp-live-field input[type="text"],.sp-live-field input[type="url"]{height:46px!important;border-radius:14px!important;padding:0 13px!important;background:var(--sp-hover,#f2f5f9)!important;border:1px solid transparent!important}
  .sp-live-source-grid{grid-template-columns:repeat(4,minmax(0,1fr))!important;gap:6px!important}
  .sp-live-source-option{min-height:70px!important;padding:8px 4px!important;border-radius:15px!important;gap:5px!important;border:1px solid var(--sp-line,#e7eaf0)!important;background:var(--sp-card,#fff)!important}
  .sp-live-source-option .sp-icon{width:21px!important;height:21px!important}
  .sp-live-source-option strong{font-size:11px!important;white-space:nowrap!important}
  .sp-live-source-option small{display:none!important}
  .sp-live-source-option.is-active{background:var(--sp-blue-soft,#eaf3ff)!important;color:var(--sp-blue-strong,#0866ff)!important;border-color:color-mix(in srgb,var(--sp-blue,#1677ff) 38%,transparent)!important;box-shadow:none!important}
  .sp-live-audio-options{display:flex!important;gap:6px!important;flex-wrap:wrap!important}
  .sp-live-audio-options label,.sp-live-camera-switch-control{min-height:42px!important;padding:0 11px!important;border:1px solid var(--sp-line,#e7eaf0)!important;border-radius:13px!important;background:var(--sp-hover,#f2f5f9)!important;font-size:12px!important;font-weight:750!important}
  .sp-live-layout-controls{border:1px solid var(--sp-line,#e7eaf0)!important;border-radius:16px!important;padding:10px!important;background:var(--sp-hover,#f2f5f9)!important}
  .sp-live-layout-controls>p{display:none!important}
  .sp-live-studio-actions{position:relative!important;min-height:64px!important;padding:9px 10px calc(9px + env(safe-area-inset-bottom))!important;border-top:1px solid var(--sp-line,#e7eaf0)!important;background:var(--sp-card,#fff)!important;display:grid!important;grid-template-columns:1fr 1.2fr!important;gap:8px!important}
  .sp-live-studio-actions button{height:46px!important;border-radius:14px!important;font-size:13px!important;font-weight:850!important}

  /* Broadcaster live stage + host chat sheet */
  .sp-live-active-card{padding:0!important;overflow:hidden!important;border-radius:22px!important}
  .sp-live-active-head{padding:10px!important;gap:8px!important;background:var(--sp-card,#fff)!important}
  .sp-live-active-head>div:first-child{min-width:0!important}
  .sp-live-active-head small{font-size:10px!important}
  .sp-live-active-actions{display:flex!important;gap:6px!important;overflow-x:auto!important;scrollbar-width:none!important}
  .sp-live-active-actions::-webkit-scrollbar{display:none!important}
  .sp-live-active-actions button{flex:0 0 auto!important;min-height:38px!important;padding:0 10px!important;border-radius:12px!important;font-size:11px!important}
  .sp-live-active-actions .sp-live-end{margin-left:auto!important;background:#ffedf0!important;color:#d8173d!important}
  .sp-live-active-grid{display:block!important;position:relative!important}
  .sp-live-broadcaster-stage{position:relative!important;aspect-ratio:9/16!important;max-height:72dvh!important;background:#000!important;border-radius:0!important;overflow:hidden!important}
  .sp-live-broadcaster-stage video,.sp-live-broadcaster-stage canvas{width:100%!important;height:100%!important;object-fit:contain!important}
  .sp-live-host-chat-toggle{display:flex!important;position:absolute!important;right:12px!important;bottom:calc(12px + env(safe-area-inset-bottom))!important;z-index:7!important;height:44px!important;padding:0 12px!important;border:1px solid rgba(255,255,255,.14)!important;border-radius:999px!important;background:rgba(8,12,19,.72)!important;color:#fff!important;align-items:center!important;gap:6px!important;backdrop-filter:blur(14px)!important;box-shadow:0 10px 30px rgba(0,0,0,.25)!important;font-size:12px!important;font-weight:850!important}
  .sp-live-host-chat-toggle .sp-icon{width:17px!important;height:17px!important}.sp-live-host-chat-toggle b{min-width:20px;height:20px;padding:0 5px;border-radius:999px;background:#1677ff;display:grid;place-items:center;font-size:9px}
  .sp-live-active-grid>.sp-live-chat{position:absolute!important;left:0!important;right:0!important;bottom:0!important;z-index:12!important;height:min(62dvh,560px)!important;max-height:min(62dvh,560px)!important;border:0!important;border-radius:22px 22px 0 0!important;background:var(--sp-card,#fff)!important;box-shadow:0 -24px 60px rgba(0,0,0,.28)!important;transform:translateY(calc(100% + 20px))!important;transition:transform .22s ease!important;padding-bottom:env(safe-area-inset-bottom)!important;overflow:hidden!important}
  .sp-live-active-card.sp-live-host-chat-open .sp-live-active-grid>.sp-live-chat{transform:translateY(0)!important}
  .sp-live-active-card.sp-live-host-chat-open .sp-live-host-chat-toggle{opacity:0!important;pointer-events:none!important}
  .sp-live-host-chat-close{display:grid!important}

  /* Viewer: full video, floating controls, clean chat drawer */
  .sp-live-viewer-modal{padding:0!important;background:#000!important}
  .sp-live-viewer-dialog{width:100vw!important;height:100dvh!important;max-height:none!important;border-radius:0!important;background:#000!important;display:block!important;overflow:hidden!important}
  .sp-live-viewer-media{position:absolute!important;inset:0!important;background:#000!important}
  .sp-live-viewer-media>video{width:100%!important;height:100%!important;object-fit:contain!important;background:#000!important}
  .sp-live-viewer-top{top:max(8px,env(safe-area-inset-top))!important;left:8px!important;right:8px!important;min-height:48px!important;padding:6px 7px!important;border-radius:16px!important;background:linear-gradient(180deg,rgba(5,8,13,.76),rgba(5,8,13,.46))!important;backdrop-filter:blur(12px)!important;border:1px solid rgba(255,255,255,.09)!important;box-shadow:none!important}
  .sp-live-viewer-top>div{min-width:0!important}
  .sp-live-viewer-top strong{font-size:13px!important;color:#fff!important;max-width:58vw!important;white-space:nowrap!important;overflow:hidden!important;text-overflow:ellipsis!important}
  .sp-live-viewer-top small{font-size:10px!important;color:rgba(255,255,255,.74)!important}
  .sp-live-viewer-top>button{width:36px!important;height:36px!important;border-radius:12px!important;background:rgba(255,255,255,.12)!important;color:#fff!important}
  .sp-live-sound-toggle,.sp-live-mobile-chat-toggle{height:44px!important;border:1px solid rgba(255,255,255,.12)!important;background:rgba(8,12,19,.72)!important;backdrop-filter:blur(14px)!important;color:#fff!important;box-shadow:0 8px 26px rgba(0,0,0,.25)!important}
  .sp-live-sound-toggle{left:12px!important;bottom:calc(12px + env(safe-area-inset-bottom))!important;border-radius:999px!important;padding:0 12px!important}
  .sp-live-mobile-chat-toggle{right:12px!important;bottom:calc(12px + env(safe-area-inset-bottom))!important;border-radius:999px!important;padding:0 12px!important}
  .sp-live-connecting{max-width:260px!important;padding:14px 16px!important;border-radius:18px!important;background:rgba(8,12,19,.78)!important;color:#fff!important;backdrop-filter:blur(16px)!important;border:1px solid rgba(255,255,255,.10)!important;box-shadow:0 16px 44px rgba(0,0,0,.28)!important;font-size:12px!important;gap:8px!important}
  .sp-live-connecting>i{width:22px!important;height:22px!important;border-width:2px!important}
  .sp-live-connect-actions{display:flex!important;justify-content:center!important;gap:7px!important;width:100%!important}
  .sp-live-start-playback,.sp-live-retry{min-height:40px!important;padding:0 14px!important;border:0!important;border-radius:12px!important;background:#fff!important;color:#101828!important;font-size:12px!important;font-weight:850!important}
  .sp-live-viewer-chat{height:min(66dvh,620px)!important;max-height:min(66dvh,620px)!important;border-radius:24px 24px 0 0!important;background:var(--sp-card,#fff)!important}
  .sp-live-chat-head{min-height:56px!important;padding:14px 48px 8px 12px!important;border-bottom:1px solid var(--sp-line,#e7eaf0)!important;background:var(--sp-card,#fff)!important}
  .sp-live-chat-head strong{font-size:15px!important;letter-spacing:-.02em!important}
  .sp-live-chat-head small{display:none!important}
  .sp-live-chat-head>span{height:25px!important;min-width:25px!important;font-size:9px!important}
  .sp-live-chat-close{display:grid!important;place-items:center!important;width:36px!important;height:36px!important;border-radius:12px!important;background:var(--sp-hover,#f2f5f9)!important}
  .sp-live-chat-messages{padding:10px 11px 12px!important;gap:9px!important;scrollbar-width:none!important}
  .sp-live-chat-messages::-webkit-scrollbar{display:none!important}
  .sp-live-chat-empty{font-size:12px!important;color:var(--sp-muted,#667085)!important}
  .sp-live-chat-message{grid-template-columns:32px minmax(0,1fr)!important;gap:8px!important}
  .sp-live-chat-message>img{width:32px!important;height:32px!important}
  .sp-live-chat-meta strong{font-size:11.5px!important}.sp-live-chat-meta small{font-size:9px!important}
  .sp-live-chat-message p{font-size:13.5px!important;line-height:1.38!important;margin-top:2px!important}
  .sp-live-chat-form{grid-template-columns:minmax(0,1fr) 44px!important;gap:6px!important;padding:8px 9px calc(8px + env(safe-area-inset-bottom))!important;background:var(--sp-card,#fff)!important}
  .sp-live-chat-form input{height:44px!important;border:0!important;border-radius:16px!important;background:var(--sp-hover,#f2f5f9)!important;padding:0 13px!important;font-size:16px!important;box-shadow:none!important}
  .sp-live-chat-form button{width:44px!important;height:44px!important;border-radius:14px!important}

  /* Live TV */
  .sp-live-tv-layout{grid-template-columns:1fr!important;gap:10px!important}
  .sp-live-player-card,.sp-live-channel-panel{border-radius:20px!important;overflow:hidden!important;box-shadow:none!important;border:1px solid var(--sp-line,#e7eaf0)!important}
  .sp-live-player-wrap{aspect-ratio:16/9!important}
  .sp-live-now{padding:9px 10px!important}.sp-live-now small{font-size:10px!important}
  .sp-live-channel-head{padding:10px!important;gap:8px!important}.sp-live-channel-head h2{font-size:16px!important}.sp-live-channel-head>div>span{display:none!important}
  .sp-live-channel-head label{height:40px!important;border-radius:13px!important}
  .sp-live-channel-list{max-height:none!important;padding:0 6px 8px!important}
  .sp-live-channel{min-height:54px!important;border-radius:14px!important;padding:6px!important}
}

@media (max-width:520px){
  :root{--sp-mobile-edge:8px}
  .sp-brand-text{display:none!important}
  .sp-topbar-inner{grid-template-columns:40px minmax(0,1fr) 40px!important}
  .sp-search{height:40px!important}
  .sp-source-grid{grid-template-columns:repeat(2,minmax(0,1fr))!important}
  .sp-live-tabs a{padding:0 8px!important}.sp-live-tabs a .sp-icon{display:none!important}
  .sp-live-launch-card{padding:11px!important}.sp-live-go-copy h2{font-size:17px!important}.sp-live-open-studio{min-width:86px!important;padding:0 12px!important}
  .sp-live-source-grid{grid-template-columns:repeat(4,minmax(0,1fr))!important}
  .sp-live-source-option{min-height:66px!important}.sp-live-source-option strong{font-size:10px!important}
  .sp-live-active-actions .sp-live-copy-link span,.sp-live-active-actions .sp-live-switch-camera span{display:inline!important}
  body.sp-messages-route .sp-chat-head-actions button[data-chat-sound-toggle]{display:none!important}
}

@media (prefers-reduced-motion:reduce){
  .sp-live-viewer-chat,.sp-live-active-grid>.sp-live-chat,.sp-mobile-drawer{transition:none!important}
}


/* ==========================================================
   V4.10.66 — mobile Comment button reliability + touch UI
   ========================================================== */
@media (max-width:860px){
  /* Keep action rows above any media/gradient hit layers and preserve three
     equal tap targets on every feed/profile/group/page post card. */
  .sp-post-card .sp-actions{
    position:relative!important;
    z-index:6!important;
    isolation:isolate!important;
    display:grid!important;
    grid-template-columns:repeat(3,minmax(0,1fr))!important;
    align-items:stretch!important;
    overflow:visible!important;
  }
  .sp-post-card .sp-actions .sp-comment-btn{
    position:relative!important;
    z-index:8!important;
    display:flex!important;
    align-items:center!important;
    justify-content:center!important;
    min-width:0!important;
    min-height:46px!important;
    padding:0 8px!important;
    border:0!important;
    border-radius:13px!important;
    background:transparent!important;
    color:var(--sp-muted,#667085)!important;
    font-size:13px!important;
    font-weight:760!important;
    line-height:1!important;
    gap:7px!important;
    cursor:pointer!important;
    pointer-events:auto!important;
    touch-action:manipulation!important;
    -webkit-tap-highlight-color:transparent!important;
  }
  .sp-post-card .sp-actions .sp-comment-btn>.sp-icon,
  .sp-post-card .sp-actions .sp-comment-btn>span{
    pointer-events:none!important;
  }
  .sp-post-card .sp-actions .sp-comment-btn>.sp-icon{
    width:20px!important;
    height:20px!important;
    flex:0 0 20px!important;
  }
  .sp-post-card .sp-actions .sp-comment-btn:active,
  .sp-post-card .sp-actions .sp-comment-btn.is-mobile-comment-opening{
    background:var(--sp-hover,#eef2f7)!important;
    color:var(--sp-blue-strong,#0866ff)!important;
    transform:scale(.985)!important;
  }

  /* Comment count is also a proper mobile tap target instead of tiny text. */
  .sp-post-card .sp-social-stats .sp-comment-stat{
    min-height:34px!important;
    display:inline-flex!important;
    align-items:center!important;
    justify-content:center!important;
    padding:0 4px!important;
    position:relative!important;
    z-index:7!important;
    pointer-events:auto!important;
    touch-action:manipulation!important;
  }

  /* The comment sheet must sit above fixed mobile navigation and remain
     interactive across browser chrome / safe-area changes. */
  .sp-comments-modal.is-open{
    z-index:2147483000!important;
    width:100vw!important;
    height:100dvh!important;
    min-height:100dvh!important;
    pointer-events:auto!important;
  }
  .sp-comments-modal.is-open .sp-comments-dialog{
    width:100vw!important;
    max-width:100vw!important;
    height:100dvh!important;
    max-height:100dvh!important;
    margin:0!important;
    border-radius:0!important;
    overflow:hidden!important;
  }
  .sp-comments-modal.is-open .sp-comments-dialog-head{
    padding-top:env(safe-area-inset-top)!important;
    height:calc(48px + env(safe-area-inset-top))!important;
    min-height:calc(48px + env(safe-area-inset-top))!important;
    flex-basis:calc(48px + env(safe-area-inset-top))!important;
  }
  body.sp-mobile-comments-open .sp-mobile-nav{
    opacity:0!important;
    visibility:hidden!important;
    pointer-events:none!important;
    transform:translateY(115%)!important;
  }
}

/* V4.10.68 — comment sheet hard visibility fallback */
@media (max-width:860px){
  #sp-comments-modal.is-open{display:flex!important;visibility:visible!important;opacity:1!important;align-items:flex-end!important;justify-content:center!important}
  #sp-comments-modal.is-open .sp-comments-dialog{pointer-events:auto!important}
  #sp-comments-modal .sp-comments-load-error{gap:12px!important;text-align:center!important}
  #sp-comments-modal .sp-comments-load-error .sp-submit{min-height:42px!important;padding:0 18px!important;border:0!important;border-radius:12px!important}
}
