*{box-sizing:border-box}html,body{margin:0;padding:0;background:#fafafa;color:#17151f;font-family:Inter,system-ui,-apple-system,BlinkMacSystemFont,"Segoe UI",sans-serif}body{min-height:100vh}button,input,textarea{font:inherit}button{cursor:pointer;border:0;background:none}.app{display:flex;min-height:100vh}.sidebar{position:fixed;left:0;top:0;bottom:0;width:245px;border-right:1px solid #e8e6ea;background:#fff;padding:27px 14px;display:flex;flex-direction:column;z-index:30}.brand{font-size:28px;letter-spacing:-2px;font-weight:850;color:#17151f;text-decoration:none;margin:0 13px 35px;font-style:italic}.brand span{color:#ef2c77}.nav{display:grid;gap:3px}.nav a{height:48px;display:flex;align-items:center;gap:15px;padding:0 15px;border-radius:12px;color:#302d38;text-decoration:none;font-weight:600;font-size:14px}.nav a:hover,.nav a.active{background:#f8f0fc;color:#8c31e8}.nav .ico{width:24px;text-align:center;font-size:20px}.create-btn,.primary{background:linear-gradient(100deg,#ff2d6d,#7a43ed);color:#fff;border-radius:10px;font-weight:750}.create-btn{margin:23px 0 0;height:48px}.sidebar-footer{margin-top:auto;color:#a09ba8;font-size:10px;text-align:center;line-height:1.7}.main{margin-left:245px;flex:1;min-width:0}.topbar{height:68px;background:#fff;border-bottom:1px solid #e8e6ea;display:flex;align-items:center;justify-content:space-between;padding:0 28px;position:sticky;top:0;z-index:20}.search{width:410px;height:43px;background:#f6f5f8;border:1px solid #eeeaf1;border-radius:12px;display:flex;align-items:center;padding:0 13px;gap:9px;color:#777}.search input{border:0;outline:0;background:transparent;width:100%;font-size:13px}.top-actions{display:flex;align-items:center;gap:20px}.top-actions a,.top-actions button{font-size:21px;color:#292632;text-decoration:none}.mini-avatar{width:31px;height:31px;border-radius:50%;overflow:hidden;display:block}.mini-avatar img{width:100%;height:100%;object-fit:cover}.primary,.secondary{height:38px;padding:0 16px;display:inline-flex;align-items:center;justify-content:center;text-decoration:none;border-radius:9px}.secondary{border:1px solid #ded9e4;background:#fff;color:#28242f;font-weight:700}.wide{width:100%;height:46px}.error,.success{padding:12px;border-radius:10px;margin:15px 0;font-size:12px}.error{background:#fff0f2;color:#b31d40}.success{background:#ecfff4;color:#187344}.feed-page{width:min(1080px,100%);margin:0 auto;display:grid;grid-template-columns:minmax(0,650px) 280px;gap:35px;padding:28px 22px 70px}.stories{display:flex;gap:18px;overflow:auto;padding:3px 0 22px;scrollbar-width:none}.stories::-webkit-scrollbar{display:none}.story{min-width:72px;text-align:center;text-decoration:none;color:#222}.story-avatar{width:68px;height:68px;padding:3px;border-radius:50%;background:linear-gradient(135deg,#ff2d55,#ff9a3c,#9b42e8)}.story-avatar img{width:100%;height:100%;border-radius:50%;object-fit:cover;border:3px solid #fff}.story small{display:block;margin-top:7px;font-size:10px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.feed-card{background:#fff;border:1px solid #e8e6ea;border-radius:15px;margin:0 0 22px;overflow:hidden}.feed-head{padding:13px 15px;display:flex;justify-content:space-between;align-items:center}.feed-user{display:flex;align-items:center;gap:10px;text-decoration:none;color:#222}.feed-user img{width:40px;height:40px;border-radius:50%;object-fit:cover}.feed-user small{display:block;color:#999;font-size:10px;margin-top:3px}.feed-image-link{display:block;background:#eee}.feed-image{width:100%;aspect-ratio:1/1;display:block;object-fit:cover}.feed-actions{display:flex;gap:17px;padding:13px 15px 4px;font-size:13px;font-weight:700}.feed-actions a{margin-left:auto;color:#7542dc;text-decoration:none}.feed-card p{padding:0 15px 15px;margin:9px 0 0;font-size:13px;line-height:1.55}.side-card{padding:12px 4px}.side-me{display:flex;align-items:center;gap:10px;margin:7px 0 22px}.side-me img,.suggestion img{width:44px;height:44px;border-radius:50%;object-fit:cover}.side-me div{flex:1}.side-me b,.side-me small{display:block}.side-me small{color:#999;font-size:11px}.side-card h4{font-size:12px;color:#888;margin:0 0 14px}.suggestion{display:flex;align-items:center;gap:9px;margin:12px 0}.suggestion div{flex:1;min-width:0}.suggestion strong,.suggestion small{display:block;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.suggestion strong{font-size:12px}.suggestion small{font-size:10px;color:#999}.suggestion a{color:#7040d6;font-size:11px;font-weight:800;text-decoration:none}.profile{width:min(980px,100%);margin:0 auto;padding:38px 22px 70px}.profile-head{display:flex;gap:70px;align-items:center;padding:0 15px 30px}.avatar-ring{width:150px;height:150px;border-radius:50%;padding:6px;background:linear-gradient(135deg,#ff3b61,#ff9d36,#8d43db);flex:none}.avatar-ring img{width:100%;height:100%;border-radius:50%;object-fit:cover;border:5px solid #fff;background:#eee}.profile-info{flex:1}.profile-row{display:flex;align-items:center;gap:10px;flex-wrap:wrap}.profile-row h1{font-size:22px;margin:0 14px 0 0}.verified{display:inline-grid;place-items:center;width:17px;height:17px;border-radius:50%;background:#6d43e8;color:#fff;font-size:11px}.stats{display:flex;gap:30px;margin:25px 0 18px}.stats span{font-size:13px}.stats b{font-size:14px}.bio{display:grid;gap:3px;font-size:13px}.bio strong{font-size:14px}.highlights{display:flex;gap:27px;padding:0 15px 30px}.highlight{display:grid;gap:8px;justify-items:center}.highlight span{width:70px;height:70px;border-radius:50%;padding:3px;border:2px solid #ddd}.highlight img{width:100%;height:100%;object-fit:cover;border-radius:50%}.highlight small{font-size:10px;font-weight:700}.tabs{display:grid;grid-template-columns:repeat(3,1fr);border-top:1px solid #e8e6ea;margin:0 15px}.tabs a,.tabs button{height:55px;display:flex;align-items:center;justify-content:center;gap:7px;color:#8d8893;text-decoration:none;font-size:12px;font-weight:750;border-bottom:1px solid transparent}.tabs a.active,.tabs button.active{color:#ef2c77;border-bottom:2px solid #ef2c77}.grid{display:grid;grid-template-columns:repeat(3,1fr);gap:4px;margin:0 15px}.post-card{position:relative;aspect-ratio:1;overflow:hidden;padding:0;background:#eee;display:block;text-decoration:none}.post-card img{width:100%;height:100%;object-fit:cover;display:block;transition:.3s}.post-card:hover img{transform:scale(1.035)}.overlay{position:absolute;inset:0;background:rgba(15,12,22,.42);display:flex;align-items:center;justify-content:center;gap:18px;color:#fff;opacity:0;transition:.2s}.post-card:hover .overlay{opacity:1}.messages-page{height:calc(100vh - 68px);max-width:1100px;margin:0 auto;display:grid;grid-template-columns:350px 1fr;background:#fff;border-left:1px solid #e8e6ea;border-right:1px solid #e8e6ea}.message-list{border-right:1px solid #e8e6ea;display:flex;flex-direction:column;min-width:0}.message-list-head{padding:22px 20px 12px}.message-list-head h2{margin:0 0 16px;font-size:21px}.message-search{height:40px;background:#f5f4f7;border:1px solid #eee;border-radius:10px;display:flex;align-items:center;padding:0 11px}.message-search input{border:0;outline:0;background:transparent;width:100%;font-size:12px}.conversation{display:flex;gap:11px;align-items:center;padding:12px 18px;text-decoration:none;color:#222}.conversation:hover,.conversation.active{background:#faf7fc}.conversation img{width:52px;height:52px;border-radius:50%;object-fit:cover}.conversation div{min-width:0}.conversation b,.conversation small{display:block}.conversation b{font-size:13px}.conversation small{font-size:11px;color:#999;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;margin-top:3px}.chat{display:grid;grid-template-rows:65px 1fr 65px;min-width:0}.chat>header{border-bottom:1px solid #eee;display:flex;align-items:center;gap:10px;padding:10px 20px}.chat>header img{width:42px;height:42px;border-radius:50%;object-fit:cover}.chat-body{padding:22px;overflow:auto;background:#fff;display:flex;flex-direction:column;gap:8px}.bubble{max-width:68%;padding:10px 13px;background:#f0eef2;border-radius:18px 18px 18px 5px;font-size:13px;align-self:flex-start}.bubble.mine{background:linear-gradient(100deg,#ff2d6d,#7a43ed);color:#fff;border-radius:18px 18px 5px 18px;align-self:flex-end}.chat-send{display:flex;gap:8px;padding:11px 15px;border-top:1px solid #eee}.chat-send input{flex:1;border:1px solid #ddd;border-radius:22px;padding:0 15px;outline:0}.chat-send .primary{height:42px;border-radius:22px}.chat-empty{display:grid;place-items:center;text-align:center;color:#999}.notify-page{width:min(760px,100%);margin:0 auto;padding:30px 20px 80px}.notify-title{display:flex;justify-content:space-between;align-items:center;margin-bottom:20px}.notify-title h1{font-size:22px;margin:0}.notify-title a{font-size:12px;color:#7542dc;text-decoration:none}.notify-group{margin:0 0 25px}.notify-group h3{font-size:12px;color:#888;margin:0 0 8px}.notify-item{display:flex;align-items:center;gap:11px;padding:13px 5px;border-bottom:1px solid #eee}.notify-item.unread{background:#faf5ff;border-radius:10px}.notify-item img{width:45px;height:45px;border-radius:50%;object-fit:cover}.notify-text{flex:1;font-size:12px;line-height:1.4}.notify-text a{color:#222;text-decoration:none}.notify-text small{display:block;color:#999;margin-top:3px;font-size:10px}.notify-post{width:42px;height:42px;object-fit:cover;border-radius:6px}.discover{max-width:1050px;margin:auto;padding:35px 25px}.discover h1{font-size:28px}.people{display:grid;grid-template-columns:repeat(4,1fr);gap:10px;margin-bottom:30px}.person{background:#fff;border:1px solid #eee;border-radius:13px;padding:13px;display:flex;align-items:center;gap:10px;text-decoration:none;color:#222}.person img{width:45px;height:45px;border-radius:50%;object-fit:cover}.person small{display:block;color:#999;font-size:10px;margin-top:3px}.post-view{width:min(1050px,100%);display:grid;grid-template-columns:1.1fr .9fr;background:#fff;border-radius:18px;overflow:hidden;box-shadow:0 20px 60px rgba(30,20,50,.12)}.post-large{width:100%;height:680px;object-fit:cover}.post-side{padding:25px;display:flex;flex-direction:column;gap:15px}.comments{overflow:auto;max-height:470px}.comments p{font-size:12px;border-bottom:1px solid #eee;padding:8px 0}.comment-form{display:flex;gap:6px;margin-top:auto}.comment-form input{flex:1;border:1px solid #ddd;border-radius:20px;padding:0 12px}.comment-form .primary{height:38px}.auth-page{min-height:100vh;background:linear-gradient(135deg,#fff6fa,#f7f3ff);display:grid;place-items:center;padding:20px}.auth-card{width:min(460px,100%);background:#fff;border:1px solid #eee;box-shadow:0 20px 70px rgba(60,30,90,.12);border-radius:20px;padding:34px}.auth-card h1{margin:20px 0 8px}.auth-card form{display:grid;gap:14px}.auth-card label{font-size:12px;font-weight:750}.auth-card input,.auth-card textarea{width:100%;border:1px solid #e4e1e8;border-radius:10px;padding:10px 13px;outline:0;margin-top:6px}.auth-card input{height:44px}.auth-links{text-align:center;font-size:12px;margin-top:15px}.auth-links a{color:#7040d6}.mobile-nav{display:none}.create-preview{display:none;width:100%;max-height:360px;object-fit:contain;background:#f5f4f7;border-radius:12px;margin:4px 0 12px}.file-drop{border:1.5px dashed #d8d2df;border-radius:13px;padding:22px;text-align:center;color:#777}.file-drop input{margin-top:10px}.success-box{padding:15px;border-radius:12px;background:#f4edff;color:#6e36bb}.empty{padding:70px 20px;text-align:center;color:#888}.landing{min-height:100vh;background:radial-gradient(circle at 75% 25%,#fff0f7,transparent 35%),radial-gradient(circle at 20% 80%,#f0ecff,transparent 35%),#fff}.landing-nav{height:82px;display:flex;align-items:center;justify-content:space-between;padding:0 7%;border-bottom:1px solid #eee}.landing-nav .brand{margin:0}.landing-nav>div{display:flex;gap:10px}.hero{max-width:1200px;margin:auto;min-height:calc(100vh - 82px);display:grid;grid-template-columns:1.1fr .9fr;align-items:center;gap:70px;padding:55px 30px}.eyebrow{font-size:11px;letter-spacing:2px;color:#8a48dc;font-weight:900;margin-bottom:18px}.hero h1{font-size:clamp(42px,6vw,74px);line-height:1.02;letter-spacing:-4px;margin:0}.hero h1 span{background:linear-gradient(90deg,#ff2c70,#7a43ed);-webkit-background-clip:text;color:transparent}.hero p{font-size:17px;line-height:1.7;color:#777;max-width:580px}.hero-actions{display:flex;gap:12px;margin-top:28px}.big{height:48px;padding:0 22px}.hero-card{position:relative;max-width:470px;justify-self:center}.hero-card>img{width:100%;aspect-ratio:4/5;object-fit:cover;border-radius:35px;box-shadow:0 30px 80px rgba(72,35,120,.2)}.floating-card{position:absolute;left:-25px;bottom:30px;background:#fff;padding:15px 20px;border-radius:16px;box-shadow:0 15px 40px rgba(40,20,60,.14)}@media(max-width:1050px){.sidebar{width:78px;padding:27px 8px}.brand{font-size:18px;letter-spacing:-1px;text-align:center;margin:0 0 35px}.nav a{justify-content:center;padding:0}.nav a:not(.active){}.nav a{font-size:0}.nav .ico{font-size:21px}.create-btn{font-size:0}.create-btn:before{content:'＋';font-size:22px}.sidebar-footer{display:none}.main{margin-left:78px}.feed-page{grid-template-columns:minmax(0,650px);justify-content:center}.side-card{display:none}}@media(max-width:700px){.sidebar{display:none}.main{margin:0}.topbar{height:60px;padding:0 13px}.search{width:220px;height:39px}.top-actions{gap:14px}.feed-page{display:block;padding:15px 0 70px}.stories{padding:3px 14px 18px}.feed-card{border-left:0;border-right:0;border-radius:0}.feed-image{aspect-ratio:1/1}.profile{padding:25px 0 70px}.profile-head{gap:18px;padding:0 15px 25px;align-items:flex-start}.avatar-ring{width:92px;height:92px;padding:4px}.profile-info{min-width:0}.profile-row h1{font-size:18px}.stats{margin:16px 0;gap:20px}.stats span{font-size:11px}.highlights{padding-left:15px;overflow:auto}.highlight span{width:60px;height:60px}.tabs{margin:0}.grid{margin:0;gap:2px}.messages-page{height:calc(100vh - 60px);grid-template-columns:1fr}.message-list{display:flex}.chat{display:none}.messages-page.has-chat .message-list{display:none}.messages-page.has-chat .chat{display:grid}.notify-page{padding:22px 14px 80px}.people{grid-template-columns:1fr 1fr}.post-view{grid-template-columns:1fr;border-radius:0}.post-large{height:430px}.post-side{padding:18px}.mobile-nav{position:fixed;display:flex;left:0;right:0;bottom:0;height:58px;background:#fff;border-top:1px solid #eee;z-index:40;justify-content:space-around;align-items:center}.mobile-nav a,.mobile-nav button{font-size:21px;color:#24202b;text-decoration:none}.hero{grid-template-columns:1fr;padding:35px 22px}.hero-card{display:none}.hero h1{letter-spacing:-2px}.landing-nav{padding:0 18px}.landing-nav .brand{font-size:23px}.landing-nav .secondary{display:none}}

/* V5 UI fixes: settings, DM, search, realtime */
.auth-card label{display:block}
.settings-page{width:min(900px,100%);margin:0 auto;padding:38px 24px 80px}.settings-card{background:#fff;border:1px solid #e9e5ed;border-radius:18px;box-shadow:0 12px 45px rgba(50,25,70,.06);overflow:hidden}.settings-title{display:flex;justify-content:space-between;align-items:center;padding:28px 30px;border-bottom:1px solid #eee}.settings-title h1{margin:0 0 5px;font-size:24px}.settings-title p{margin:0;color:#8a8590;font-size:12px}.settings-avatar{width:74px;height:74px;border-radius:50%;object-fit:cover;border:3px solid #fff;box-shadow:0 0 0 3px #eee}.settings-section{padding:28px 30px;border-bottom:1px solid #eee}.settings-section:last-child{border-bottom:0}.settings-section h2{font-size:15px;margin:0 0 20px}.settings-section form{display:grid;gap:9px}.form-label{display:block;font-size:12px;font-weight:750;margin-top:8px}.form-control{display:block;width:100%;height:44px!important;border:1px solid #ded9e4;border-radius:10px;padding:0 13px;outline:0;background:#fff}.form-control:focus{border-color:#a76be8;box-shadow:0 0 0 3px rgba(122,67,237,.08)}.form-control.textarea{height:auto!important;min-height:125px;padding:12px 13px;resize:vertical;line-height:1.5}.readonly-field{height:44px;border:1px solid #eee8f0;border-radius:10px;background:#f8f7f9;color:#888;padding:12px 13px;font-size:13px}.avatar-upload-row{display:flex;align-items:center;gap:12px;margin-bottom:8px}.file-button{position:relative;display:inline-flex!important;align-items:center;justify-content:center;height:40px;padding:0 15px;background:#f4eff9;border-radius:9px;color:#6d35bd;font-size:12px;font-weight:800;cursor:pointer}.file-button input{position:absolute;inset:0;opacity:0;width:100%;height:100%;cursor:pointer;margin:0}.avatar-upload-row>span{font-size:11px;color:#999;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.save-btn{margin-top:12px;height:44px;justify-self:start;min-width:180px}.dm-heading{display:flex;align-items:center;justify-content:space-between}.dm-status{color:#32bf71;font-size:10px}.message-list{position:relative}.user-results{position:absolute;left:20px;right:20px;top:101px;background:#fff;border:1px solid #e8e3ec;border-radius:12px;box-shadow:0 18px 40px rgba(30,20,45,.13);display:none;z-index:50;overflow:hidden}.user-results.show{display:block}.user-results a{display:flex;align-items:center;gap:10px;padding:11px;text-decoration:none;color:#222}.user-results a:hover{background:#faf6ff}.user-results img{width:38px;height:38px;border-radius:50%;object-fit:cover}.user-results span{display:block}.user-results b,.user-results small{display:block}.user-results b{font-size:12px}.user-results small{font-size:10px;color:#999;margin-top:2px}.conversation{position:relative}.conversation time{margin-left:auto;color:#aaa;font-size:9px}.chat-head{box-shadow:0 1px 0 rgba(0,0,0,.02)}.chat-back{display:none;color:#222;text-decoration:none;font-size:27px;margin-right:4px}.chat-user{font-size:13px;font-weight:800;color:#222;text-decoration:none}.chat-head small{display:block;color:#999;font-size:10px;margin-top:2px}.bubble-wrap{max-width:72%;align-self:flex-start;display:flex;flex-direction:column;align-items:flex-start}.bubble-wrap.mine{align-self:flex-end;align-items:flex-end}.bubble-wrap small{font-size:8px;color:#aaa;margin:3px 8px 0}.bubble-wrap .bubble{max-width:100%;margin:0}.send-btn{width:44px;height:42px;border-radius:50%;background:linear-gradient(100deg,#ff2d6d,#7a43ed);color:#fff;font-size:18px}.dm-icon{width:68px;height:68px;border:2px solid #222;border-radius:50%;display:grid;place-items:center;margin:0 auto 15px;font-size:28px}.notification-link{position:relative}.badge{display:none;position:absolute;top:-5px;right:-8px;min-width:16px;height:16px;border-radius:9px;background:#ef2c77;color:#fff;font-size:9px;align-items:center;justify-content:center;font-weight:800}.badge.show{display:flex}.notify-item .secondary{height:30px;padding:0 10px;font-size:10px}.notify-item{transition:background .2s}.notify-item.new-item{animation:notifyIn .35s ease}@keyframes notifyIn{from{transform:translateY(-5px);opacity:0}to{transform:none;opacity:1}}
@media(max-width:800px){.settings-page{padding:20px 12px 90px}.settings-title,.settings-section{padding:20px}.messages-page{grid-template-columns:1fr}.messages-page.has-chat .message-list{display:none}.messages-page.has-chat .chat{display:grid}.chat-back{display:block}.message-list{border-right:0}.chat{min-height:calc(100vh - 68px)}.chat-head{padding-left:12px}.message-search{margin-bottom:5px}}
@media(max-width:560px){.settings-title{align-items:flex-start}.settings-avatar{width:58px;height:58px}.avatar-upload-row{align-items:flex-start;flex-direction:column}.save-btn{width:100%}.settings-section{padding:18px 15px}}

/* V6 messaging / mobile / post UX */
.chat-screen{overflow:hidden}.messages-page{height:calc(100dvh - 68px);min-height:0}.chat{min-height:0}.chat-body{min-height:0;overscroll-behavior:contain;-webkit-overflow-scrolling:touch}.chat-send{position:relative;z-index:10;background:#fff;min-height:65px;align-items:center;padding-bottom:max(11px,env(safe-area-inset-bottom));}.tool-btn{width:38px;height:38px;flex:0 0 38px;border-radius:50%;display:grid;place-items:center;color:#6e35bd;font-size:20px;background:#f7f2fb}.tool-btn.recording{background:#ef2c77;color:#fff;animation:pulse 1s infinite}.msg-media{display:block;width:min(260px,100%);max-height:330px;object-fit:cover;border-radius:14px}.msg-audio{display:block;width:240px;max-width:100%;height:40px}.msg-text{white-space:pre-wrap;overflow-wrap:anywhere}.emoji-panel{position:absolute;bottom:66px;left:10px;width:min(330px,calc(100vw - 20px));padding:10px;background:#fff;border:1px solid #e5e0e9;border-radius:16px;box-shadow:0 16px 45px rgba(30,20,45,.18);display:none;grid-template-columns:repeat(8,1fr);gap:4px;max-height:230px;overflow:auto}.emoji-panel.show{display:grid}.emoji-panel button{font-size:22px;padding:6px;border-radius:8px}.emoji-panel button:hover{background:#f7f1fb}@keyframes pulse{50%{transform:scale(1.08)}}
.post-page{min-height:100dvh;background:#f7f6f8}.post-shell{min-height:100dvh}.post-top{height:64px;background:#fff;border-bottom:1px solid #e9e6ec;display:grid;grid-template-columns:1fr auto 1fr;align-items:center;padding:0 24px;position:sticky;top:0;z-index:20}.post-top .brand{margin:0;font-size:23px}.post-back,.post-user-top{text-decoration:none;color:#292532;font-weight:700;font-size:13px}.post-user-top{text-align:right}.post-view-modern{width:min(1080px,100%);min-height:calc(100dvh - 64px);margin:0 auto;display:grid;grid-template-columns:minmax(0,1.05fr) minmax(350px,.75fr);background:#fff}.post-media-wrap{background:#111;display:grid;place-items:center;min-height:0}.post-large{width:100%;height:calc(100dvh - 64px);max-height:none;object-fit:contain}.post-side-modern{display:flex;flex-direction:column;min-height:0;border-left:1px solid #eee}.post-owner{height:72px;padding:12px 16px;border-bottom:1px solid #eee;display:flex;align-items:center;gap:10px}.post-owner img{width:44px;height:44px;border-radius:50%;object-fit:cover}.post-owner a{text-decoration:none;color:#222}.post-owner small{display:block;color:#999;font-size:10px;margin-top:2px}.post-caption{padding:16px;font-size:13px;line-height:1.55;border-bottom:1px solid #eee}.post-comments{flex:1;min-height:0;overflow:auto;padding:10px 16px}.post-comment{display:flex;gap:9px;padding:8px 0;font-size:12px}.post-comment img,.post-comment-fallback{width:34px;height:34px;border-radius:50%;object-fit:cover;flex:0 0 34px}.post-comment-fallback{display:grid;place-items:center;background:#eee6f6;color:#7034bc;font-weight:800}.post-comment b,.post-comment span{display:block}.post-comment span{margin-top:2px;line-height:1.4}.post-bottom{border-top:1px solid #eee;padding:10px 14px calc(10px + env(safe-area-inset-bottom));background:#fff}.post-actions{display:flex;gap:12px;margin-bottom:8px}.like-btn,.comment-focus{font-size:22px;color:#292532;padding:4px 8px;border-radius:8px}.like-btn.liked{color:#ef2c77}.comment-form-modern{display:flex;gap:8px}.comment-form-modern input{flex:1;min-width:0;height:42px;border:1px solid #ddd8e1;border-radius:22px;padding:0 15px;outline:0}.comment-form-modern button{height:42px;padding:0 14px;border-radius:21px;background:linear-gradient(100deg,#ff2d6d,#7a43ed);color:#fff;font-weight:800}
@media(max-width:700px){.chat-screen .main{height:100dvh}.messages-page{height:100dvh!important}.messages-page.has-chat .chat{display:grid;position:fixed;inset:0;z-index:50;background:#fff;grid-template-rows:62px minmax(0,1fr) auto}.messages-page.has-chat .chat-body{padding:14px 12px 18px}.messages-page.has-chat .chat-send{min-height:62px;padding:8px 8px max(8px,env(safe-area-inset-bottom));}.messages-page.has-chat .chat-head{padding:8px 12px}.messages-page.has-chat~*{}.chat-send input{height:42px;min-width:0}.send-btn{width:42px;height:42px;flex:0 0 42px}.emoji-panel{bottom:67px}.chat-screen .mobile-nav{display:none}.bubble-wrap{max-width:84%}.msg-media{width:min(230px,75vw);max-height:280px}.post-top{height:58px;padding:0 12px;grid-template-columns:1fr auto 1fr}.post-top .brand{font-size:20px}.post-view-modern{display:flex;flex-direction:column;min-height:calc(100dvh - 58px);margin:0}.post-media-wrap{height:auto;min-height:0;aspect-ratio:1/1;background:#111}.post-large{height:100%;width:100%;object-fit:contain}.post-side-modern{border-left:0;min-height:calc(100dvh - 58px - 100vw);}.post-owner{height:62px}.post-caption{padding:12px 14px}.post-comments{max-height:35dvh;flex:none}.post-bottom{position:sticky;bottom:0}.post-user-top{font-size:11px}.post-back span{display:none}.post-back{font-size:28px}.like-btn,.comment-focus{font-size:24px}}
@media(max-width:420px){.tool-btn{width:34px;height:34px;flex-basis:34px;font-size:18px}.send-btn{width:38px;height:38px;flex-basis:38px}.chat-send input{height:38px;padding:0 12px}.emoji-panel{grid-template-columns:repeat(7,1fr)}}

/* V8: voice preview + chat photo lightbox */
.voice-preview{display:none;position:absolute;left:10px;right:10px;bottom:72px;background:#fff;border:1px solid #e8e1ee;border-radius:16px;padding:12px;box-shadow:0 18px 50px rgba(30,20,45,.18);z-index:30}.voice-preview.show{display:block}.voice-preview-top{display:flex;justify-content:space-between;align-items:center;margin-bottom:8px;font-size:12px}.voice-preview-top span{font-variant-numeric:tabular-nums;color:#7a43ed;font-weight:800}.voice-preview audio{width:100%;height:40px}.voice-preview-actions{display:flex;justify-content:flex-end;gap:8px;margin-top:9px}.voice-preview-actions button{border:0;border-radius:20px;height:36px;padding:0 15px;font-weight:800;cursor:pointer}.voice-cancel{background:#f3f1f4;color:#555}.voice-send{background:linear-gradient(100deg,#ff2d6d,#7a43ed);color:#fff}.mic-btn.recording{background:#ef2c77!important;color:#fff!important;animation:pulse 1s infinite}.chat-clickable{cursor:zoom-in}.chat-lightbox{position:fixed;inset:0;background:rgba(0,0,0,.82);display:none;align-items:center;justify-content:center;padding:25px;z-index:9999}.chat-lightbox.show{display:flex}.chat-lightbox img{max-width:94vw;max-height:92vh;object-fit:contain;border-radius:8px}.chat-lightbox-close{position:absolute;top:15px;right:18px;width:44px;height:44px;border:0;border-radius:50%;background:rgba(255,255,255,.14);color:#fff;font-size:30px;cursor:pointer}.lightbox-open{overflow:hidden}.chat-send{position:relative}
@media(max-width:560px){.voice-preview{bottom:76px;left:6px;right:6px}.chat-lightbox{padding:8px}.chat-lightbox img{max-width:100vw;max-height:90vh;border-radius:0}}

/* V9 social expansion */
:root{--accent:#7a43ed;--accent2:#ff2d6d;--soft:#f8f0fc;--text:#17151f;--panel:#fff;--line:#e8e6ea}
body[data-theme="bjk"]{--accent:#111;--accent2:#777;--soft:#f1f1f1}body[data-theme="gs"]{--accent:#e0ad00;--accent2:#9e0b0f;--soft:#fff3c7}body[data-theme="fb"]{--accent:#0b2a68;--accent2:#f5c400;--soft:#edf3ff}body[data-theme="ts"]{--accent:#7b1f2c;--accent2:#3f82a5;--soft:#f8e9ed}body[data-theme="night"]{--accent:#b66cff;--accent2:#ff3f87;--soft:#211b2a;--text:#f5f2fa;--panel:#16131b;--line:#302b36;background:#0e0c11;color:var(--text)}
body[data-theme="night"] .sidebar,body[data-theme="night"] .topbar,body[data-theme="night"] .feed-card,body[data-theme="night"] .post-side-modern,body[data-theme="night"] .post-bottom,body[data-theme="night"] .auth-card,body[data-theme="night"] .settings-section{background:var(--panel);color:var(--text);border-color:var(--line)}
body[data-theme="night"] .nav a,body[data-theme="night"] .top-actions a,body[data-theme="night"] .feed-user,body[data-theme="night"] .post-owner a{color:var(--text)}
.primary,.create-btn,.send-btn,.voice-send,.comment-form-modern button{background:linear-gradient(100deg,var(--accent2),var(--accent))!important}.nav a:hover,.nav a.active{background:var(--soft);color:var(--accent)}
.create-tabs{display:flex;gap:7px;margin:0 0 18px;padding:5px;background:#f5f2f7;border-radius:12px}.create-tabs a{flex:1;text-align:center;padding:10px 6px;border-radius:9px;text-decoration:none;color:#6c6672;font-size:12px;font-weight:800}.create-tabs a.active{background:#fff;color:var(--accent);box-shadow:0 3px 12px rgba(30,20,45,.08)}.create-card{max-width:560px}.create-video-preview{width:100%;max-height:420px;border-radius:15px;background:#111;margin:12px 0}.text-post-box textarea{width:100%;min-height:220px;border:1px solid #ddd8e1;border-radius:15px;padding:16px;resize:vertical;font-size:16px;outline:0}.feed-video-link{position:relative;display:block;background:#111}.feed-video{display:block;width:100%;aspect-ratio:1/1;object-fit:cover}.video-tag{position:absolute;top:12px;right:12px;background:rgba(0,0,0,.65);color:#fff;padding:6px 9px;border-radius:9px;font-size:10px;font-weight:800}.feed-actions .ajax-like{font:inherit;border:0;background:none;cursor:pointer;color:#292532}.feed-actions .ajax-like.liked{color:#ef2c77}.story-add-btn{margin-top:9px;height:38px;border:1px solid var(--line);border-radius:10px;color:var(--accent);text-decoration:none;display:flex;align-items:center;justify-content:center;font-size:12px;font-weight:800}.story-avatar.story-add{position:relative}.story-avatar.story-add b{position:absolute;right:-1px;bottom:-1px;width:20px;height:20px;border-radius:50%;background:var(--accent);color:#fff;display:grid;place-items:center;font-size:14px;border:2px solid #fff}.theme-grid{display:grid;grid-template-columns:repeat(3,1fr);gap:10px;margin:14px 0}.theme-option{position:relative}.theme-option input{position:absolute;opacity:0}.theme-option span{height:72px;border-radius:14px;border:2px solid #e2dce8;display:flex;align-items:flex-end;padding:10px;font-weight:800;font-size:12px;cursor:pointer;background:linear-gradient(135deg,#fff,#f7f3fa)}.theme-option input:checked+span{border-color:var(--accent);box-shadow:0 0 0 3px color-mix(in srgb,var(--accent) 16%,transparent)}.theme-bjk span{background:linear-gradient(135deg,#111 0 50%,#fff 50%)}.theme-gs span{background:linear-gradient(135deg,#9e0b0f 0 50%,#f1c40f 50%)}.theme-fb span{background:linear-gradient(135deg,#0b2a68 0 50%,#f5c400 50%)}.theme-ts span{background:linear-gradient(135deg,#7b1f2c 0 50%,#3f82a5 50%)}.theme-night span{background:linear-gradient(135deg,#0d0a11,#4b2a65);color:#fff}.reels-grid{display:grid;grid-template-columns:repeat(3,1fr);gap:3px}.reel-card{position:relative;aspect-ratio:9/14;background:#111;overflow:hidden}.reel-card video{width:100%;height:100%;object-fit:cover}.reel-card span{position:absolute;left:8px;bottom:8px;color:#fff;background:rgba(0,0,0,.55);border-radius:8px;padding:5px 7px;font-size:10px;font-weight:800}.profile-add-reel{margin-left:auto!important;padding:7px 11px!important;border:1px solid #ddd!important;border-radius:9px!important;text-decoration:none!important}.text-post-card{background:linear-gradient(135deg,var(--soft),#fff);display:flex!important;align-items:center;justify-content:center;padding:18px;text-align:center;color:var(--text);font-size:14px;line-height:1.5}.text-post-card .overlay{color:#555}.post-text-large{padding:40px;font-size:24px;line-height:1.55;color:#222;max-width:700px;overflow:auto}.story-view{background:#09070b;color:#fff;min-height:100dvh;display:grid;place-items:center}.story-viewer{width:min(460px,100vw);height:min(820px,100dvh);position:relative;background:#111;overflow:hidden}.story-viewer>img,.story-viewer>video{width:100%;height:100%;object-fit:contain;background:#111}.story-close{position:fixed;top:18px;right:24px;color:#fff;font-size:36px;text-decoration:none;z-index:4}.story-progress{position:absolute;left:12px;right:12px;top:10px;height:3px;background:rgba(255,255,255,.3);z-index:3}.story-progress i{display:block;height:100%;width:100%;background:#fff;transform-origin:left;animation:storyTimer 24s linear forwards}.story-owner{position:absolute;top:20px;left:15px;right:15px;display:flex;align-items:center;gap:8px;z-index:3;text-shadow:0 1px 4px #000}.story-owner img{width:34px;height:34px;border-radius:50%;object-fit:cover;border:2px solid #fff}.story-owner small{font-size:9px;opacity:.8}.story-caption{position:absolute;left:16px;right:16px;bottom:20px;padding:10px 13px;background:rgba(0,0,0,.45);border-radius:10px;z-index:3}@keyframes storyTimer{to{transform:scaleX(0)}}
@media(max-width:800px){.theme-grid{grid-template-columns:repeat(2,1fr)}.right-rail{display:none}.feed-page{display:block;padding:14px 8px 85px}.feed-card{border-radius:10px}.story-viewer{height:100dvh}.story-close{top:8px;right:12px}.profile-add-reel{margin-left:0!important}.reels-grid{grid-template-columns:repeat(2,1fr)}}

/* V9.1 stability fixes */
html,body{max-width:100%;overflow-x:hidden}.main{min-width:0;max-width:100vw}.feed-page{box-sizing:border-box;max-width:1080px}.feed-card,.feed-image,.feed-video{max-width:100%}.feed-image,.feed-video{display:block}.story-viewer{max-width:100vw}
@media(max-width:800px){.main{width:100%;margin-left:0}.feed-page{width:100%;max-width:100%;overflow-x:hidden}.topbar{max-width:100%;box-sizing:border-box}.stories{max-width:100%;overflow-x:auto}.feed-card{width:100%;box-sizing:border-box}.feed-image,.feed-video{width:100%;height:auto}}

/* V9.2 stability: right rail avatars, story media and discover cards */
.suggestion{display:flex;align-items:center;gap:9px;margin:12px 0;min-width:0}
.suggestion img{width:44px!important;height:44px!important;min-width:44px;min-height:44px;border-radius:50%;object-fit:cover;display:block}
.suggestion div{flex:1;min-width:0}
.suggestion b,.suggestion small{display:block;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.suggestion b{font-size:12px}.suggestion small{font-size:10px;color:#999}.suggestion a{color:#7040d6;font-size:11px;font-weight:800;text-decoration:none;white-space:nowrap}
.story-error{display:none;position:absolute;left:20px;right:20px;bottom:20px;padding:12px 14px;border-radius:10px;background:rgba(0,0,0,.72);color:#fff;font-size:12px;z-index:5}.story-error.show{display:block}
.explore-video-badge{position:absolute;right:8px;top:8px;background:rgba(0,0,0,.65);color:#fff;border-radius:8px;padding:5px 7px;font-size:11px}
.explore-text-card{width:100%;height:100%;display:grid;place-items:center;padding:18px;text-align:center;background:linear-gradient(135deg,#f8f0fc,#fff);font-size:13px;color:#333}
.post-card video{width:100%;height:100%;object-fit:cover;display:block}
@media(max-width:800px){.suggestion img{width:42px!important;height:42px!important;min-width:42px;min-height:42px}}

/* V10 FINAL THEMES */
body[data-theme="bjk"]{background:#f4f4f4;color:#111}body[data-theme="bjk"] .sidebar,body[data-theme="bjk"] .topbar{background:linear-gradient(90deg,#050505 0 12px,#fff 12px);color:#111}body[data-theme="bjk"] .brand{color:#111}body[data-theme="bjk"] .brand span{color:#111}body[data-theme="bjk"] .feed-card,body[data-theme="bjk"] .side-card,body[data-theme="bjk"] .messages-page,body[data-theme="bjk"] .settings-section{border-color:#222}
body[data-theme="gs"]{background:#fff8d9;color:#4d0b0b}body[data-theme="gs"] .sidebar,body[data-theme="gs"] .topbar{background:linear-gradient(90deg,#9e0b0f 0 10px,#f5c400 10px 20px,#fff 20px);color:#5b0909}body[data-theme="gs"] .brand span{color:#e0ad00}body[data-theme="gs"] .feed-card{border-color:#e0ad00}
body[data-theme="fb"]{background:#eef4ff;color:#10275c}body[data-theme="fb"] .sidebar,body[data-theme="fb"] .topbar{background:linear-gradient(90deg,#0b2a68 0 10px,#f5c400 10px 20px,#fff 20px);color:#0b2a68}body[data-theme="fb"] .brand span{color:#f5c400}body[data-theme="fb"] .feed-card{border-color:#0b2a68}
body[data-theme="ts"]{background:#f7eef0;color:#5b1c28}body[data-theme="ts"] .sidebar,body[data-theme="ts"] .topbar{background:linear-gradient(90deg,#7b1f2c 0 10px,#3f82a5 10px 20px,#fff 20px);color:#5b1c28}body[data-theme="ts"] .brand span{color:#3f82a5}body[data-theme="ts"] .feed-card{border-color:#7b1f2c}
body[data-theme="night"]{background:#0e0c11;color:#f5f2fa}body[data-theme="night"] .brand{color:#fff}body[data-theme="night"] .brand span{color:#ff3f87}body[data-theme="night"] .sidebar,body[data-theme="night"] .topbar{background:#16131b;color:#f5f2fa}body[data-theme="night"] .search{background:#211c27;border-color:#38313f;color:#ddd}body[data-theme="night"] .search input{color:#fff}body[data-theme="night"] .feed-page,body[data-theme="night"] .discover,body[data-theme="night"] .profile,body[data-theme="night"] .notify-page{color:#f5f2fa}body[data-theme="night"] .feed-card,body[data-theme="night"] .person,body[data-theme="night"] .post-card,body[data-theme="night"] .messages-page{background:#16131b;border-color:#302b36}body[data-theme="night"] .conversation:hover,body[data-theme="night"] .conversation.active{background:#211c27}body[data-theme="night"] .chat-body{background:#0e0c11}body[data-theme="night"] .chat-send{background:#16131b;border-color:#302b36}body[data-theme="night"] .chat-send input{background:#211c27;color:#fff;border-color:#38313f}
body[data-theme="night"] .nav a,body[data-theme="night"] .top-actions a,body[data-theme="night"] .feed-user,body[data-theme="night"] .person,body[data-theme="night"] .conversation,body[data-theme="night"] .profile a{color:#f5f2fa}
/* URL-safe navigation on rewritten pages */
.post-shell,.story-view,.auth-card{position:relative}

/* V10.1 avatar sizing fix - never allow user-card avatars to use post/media sizing */
.me-card{display:flex;align-items:center;gap:10px;min-width:0;margin:7px 0 22px}
.me-card>img{width:48px!important;height:48px!important;min-width:48px;min-height:48px;max-width:48px;max-height:48px;border-radius:50%;object-fit:cover;display:block;flex:0 0 48px}
.me-card>div{flex:1;min-width:0}
.me-card b,.me-card small{display:block;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.me-card small{color:#999;font-size:10px;margin-top:3px}
.me-card>a{color:#7040d6;font-size:11px;font-weight:800;text-decoration:none;white-space:nowrap}
.right-rail .suggestion{height:52px;min-height:52px}
.right-rail .suggestion>img{width:44px!important;height:44px!important;min-width:44px!important;min-height:44px!important;max-width:44px!important;max-height:44px!important;flex:0 0 44px;object-fit:cover;border-radius:50%;display:block}
.right-rail .suggestion>div{min-width:0;overflow:hidden}
.right-rail .suggestion>a{flex:0 0 auto}

/* V10.2 - Instagram tarzı gönderi etkileşimleri: ana akışta doğrudan görünür */
.feed-actions{align-items:center;border-top:0;padding:12px 15px 5px}
.feed-actions .ajax-like,.feed-actions .comment-focus{font:inherit;color:#292532;display:inline-flex;align-items:center;gap:5px;padding:3px 0;cursor:pointer}
.feed-actions .ajax-like.liked{color:#ef2c77}
.feed-actions .comment-focus{border:0;background:none}
.feed-actions .post-open-link{margin-left:auto;color:#8a39df;font-size:11px;font-weight:700;text-decoration:none}
.inline-comments{padding:0 15px;display:grid;gap:3px}
.inline-comment{font-size:12px;line-height:1.45;color:#34303a}
.inline-comment b{font-weight:800;margin-right:4px}
.inline-comment-form{display:flex;align-items:center;gap:8px;border-top:1px solid #f0edf2;margin-top:9px;padding:10px 15px 13px}
.inline-comment-form input{min-width:0;flex:1;border:0;outline:0;background:transparent;font-size:12px;color:inherit}
.inline-comment-form button{color:var(--accent);font-size:12px;font-weight:800;padding:4px 0}
@media(max-width:800px){.inline-comment-form{padding-bottom:12px}.feed-actions .post-open-link{font-size:10px}}
/* Inline comment composer v10.3 */
.inline-comment-form{position:relative;background:#fff}
.inline-comment-form .comment-emoji{width:30px;height:30px;flex:0 0 30px;border-radius:50%;font-size:18px;display:grid;place-items:center}
.inline-comment-form .comment-emoji:hover{background:#f5f1f8}
.inline-comment-form .comment-send{white-space:nowrap}
.comment-emoji-panel{position:absolute;left:8px;bottom:52px;width:230px;padding:9px;display:grid;grid-template-columns:repeat(7,1fr);gap:3px;background:#fff;border:1px solid #e5e0e8;border-radius:14px;box-shadow:0 12px 35px rgba(30,20,45,.16);z-index:40}
.comment-emoji-panel[hidden]{display:none}
.comment-emoji-panel button{width:28px;height:28px;border-radius:8px;font-size:18px;display:grid;place-items:center}
.comment-emoji-panel button:hover{background:#f6f2f8}
.comment-error{position:absolute;left:15px;right:15px;bottom:-18px;color:#c6284a;font-size:10px}
@media(max-width:700px){.comment-emoji-panel{left:5px;bottom:55px;width:min(270px,calc(100vw - 30px));grid-template-columns:repeat(8,1fr)}.inline-comment-form{padding-bottom:12px}.inline-comment-form input{font-size:13px}.inline-comment-form .comment-send{font-size:12px}}
