/* Desktop post reading: the photograph keeps its whole frame; conversation scrolls independently. */
dialog.post-detail{padding:0;border:1px solid var(--line);border-radius:18px;background:var(--card);color:var(--ink);width:min(1460px,calc(100vw - 64px));max-width:calc(100vw - 24px);height:min(880px,calc(100svh - 64px));max-height:calc(100svh - 24px);overflow:hidden;box-shadow:0 24px 100px #0006}
dialog.post-detail[open]{display:grid;grid-template-columns:minmax(0,1fr) minmax(340px,410px)}
dialog.post-detail::backdrop{background:#050505c9;backdrop-filter:blur(10px)}
.post-detail button,.post-detail textarea{font:inherit}
.post-detail button{cursor:pointer;-webkit-tap-highlight-color:transparent}
.post-detail button:disabled{opacity:.4;cursor:default}
.post-detail button:focus-visible,.post-detail a:focus-visible{outline:2px solid var(--accent);outline-offset:3px}
.detail-media{min-width:0;min-height:0;display:flex;flex-direction:column;background:#080808;color:#f5f5f5}
.detail-picture{flex:1;min-width:0;min-height:0;position:relative;overflow:hidden;display:grid;grid-template-columns:minmax(0,1fr);grid-template-rows:minmax(0,1fr)}
.detail-picture>img{display:block;width:100%;height:100%;min-height:0;min-width:0;object-fit:contain;transition:transform .2s}
.detail-picture.is-zoomed>img{transform:scale(1.6);cursor:zoom-out}
.detail-photo-state{position:absolute;inset:0;display:grid;place-content:center;text-align:center;padding:40px;background:#080808e8;color:#bcbcbc;font-size:13px}
.detail-step{position:absolute;top:50%;transform:translateY(-50%);display:grid;place-items:center;width:36px;height:36px;border:1px solid #ffffff40;border-radius:50%;background:#171717bd;color:#fff;z-index:1;backdrop-filter:blur(8px)}
.detail-step:hover{background:#303030}
.detail-step svg{width:20px;height:20px}.detail-prev{left:16px}.detail-next{right:16px}
.detail-photo-footer{flex:none;min-height:48px;display:grid;grid-template-columns:1fr auto 1fr;align-items:center;gap:12px;padding:10px 20px;font-size:11px;color:#c1c1c1;border-top:1px solid #ffffff12}
.detail-zoom{justify-self:end;border:0;background:transparent;color:inherit;padding:6px 0}
.detail-dots{display:flex;gap:5px;align-items:center}.detail-dots button{width:17px;height:24px;border:0;padding:0;background:transparent;position:relative}.detail-dots button::after{content:'';display:block;width:5px;height:5px;margin:auto;border-radius:50%;background:#666}.detail-dots button[aria-pressed=true]::after{background:#fff;width:6px;height:6px}
.detail-conversation{min-width:0;min-height:0;display:flex;flex-direction:column;border-left:1px solid var(--line)}
.detail-header{min-height:78px;display:flex;align-items:center;justify-content:space-between;gap:12px;padding:16px 22px;border-bottom:1px solid var(--line);flex-shrink:0}
.detail-author{display:flex;align-items:center;gap:12px;min-width:0;text-decoration:none;color:var(--ink);font-weight:650;font-size:14px;line-height:1.4}.detail-author>.avatar{flex:none;width:38px;height:38px}.detail-author>span:last-child{min-width:0;overflow-wrap:anywhere}.detail-author small{display:block;color:var(--muted);font-size:11px;font-weight:400;margin-top:3px}.detail-author .verified-badge,.detail-comment-name .verified-badge{display:inline-block;vertical-align:middle;width:15px;height:15px;margin-left:4px}
.detail-close{display:grid;place-items:center;flex:none;width:34px;height:34px;border:0;border-radius:50%;background:var(--soft);color:var(--ink)}.detail-close svg{width:18px;height:18px}
.detail-discussion{flex:1;min-height:0;overflow-y:auto;overscroll-behavior:contain;padding:24px 22px;scrollbar-width:thin;scrollbar-color:var(--line) transparent}
.detail-post-caption{padding:0 0 22px;margin-bottom:4px;border-bottom:1px solid var(--line);font-size:14px;line-height:1.65;overflow-wrap:anywhere}.detail-post-caption>strong{font-size:16px}.detail-post-caption p{margin:8px 0 0;white-space:pre-wrap;color:var(--muted)}
.detail-comment{display:flex;align-items:flex-start;gap:11px;padding:18px 0 0;min-width:0}.detail-comment-avatar{flex:none}.detail-comment .avatar{width:32px;height:32px}.detail-comment-body{flex:1;min-width:0}.detail-comment-body>p{font-size:13px;line-height:1.65;white-space:pre-wrap;overflow-wrap:anywhere;margin:0}.detail-comment-name{color:var(--ink);font-weight:650;text-decoration:none;margin-right:4px}.detail-comment.is-reply{margin-left:42px;padding-top:13px}.detail-comment.is-reply .avatar{width:26px;height:26px}
.detail-comment-meta{display:flex;flex-wrap:wrap;align-items:center;gap:6px 12px;font-size:10px;line-height:1.6;margin-top:6px;color:var(--muted)}.detail-comment-meta button{padding:2px 0;border:0;background:transparent;color:var(--muted);font-weight:600;font-size:10px}.detail-comment-meta button:hover{color:var(--ink)}
.detail-comment-like{flex:none;margin-top:1px;display:grid;place-items:center;width:26px;height:30px;background:transparent;border:0;color:var(--muted)}.detail-comment-like svg{width:15px;height:15px}.post-detail .is-liked{color:#e94863}.post-detail .is-liked svg{fill:currentColor;stroke:currentColor}
.detail-older{display:block;margin:24px auto 0;padding:10px 16px;border:1px solid var(--line);border-radius:24px;background:transparent;color:var(--muted);font-size:11px}
.detail-empty{min-height:200px;display:flex;flex-direction:column;align-items:center;justify-content:center;text-align:center;padding:36px 10px;color:var(--muted)}.detail-empty svg{width:30px;height:30px;stroke-width:1.2;opacity:.6}.detail-empty h3{font-size:19px;line-height:1.3;letter-spacing:-.4px;font-weight:600;color:var(--ink);margin:18px 0 8px}.detail-empty p{font-size:12px;line-height:1.6;max-width:230px;margin:0}.detail-loading{color:var(--muted);font-size:12px;text-align:center;padding:24px}
.detail-summary{padding:15px 22px 17px;border-top:1px solid var(--line);flex:none}.detail-actions{display:flex;align-items:center;gap:16px}.detail-actions button{display:grid;place-items:center;width:28px;height:32px;padding:0;border:0;background:transparent;color:var(--ink)}.detail-actions button:hover{opacity:.65}.detail-actions svg{width:25px;height:25px}.detail-actions #detailSave{margin-left:auto}.detail-actions .is-saved svg{fill:currentColor}.detail-summary p{font-size:12px;font-weight:600;margin:10px 0 6px;white-space:pre-wrap}.detail-summary time{font-size:10px;color:var(--muted);display:block;margin-top:8px}
.detail-composer{padding:16px 22px;border-top:1px solid var(--line);margin:0;flex:none;background:var(--card)}.detail-input-row{display:flex;align-items:center;gap:12px}.detail-input-row textarea{min-width:0;flex:1;min-height:30px;max-height:110px;resize:none;background:transparent!important;border:0!important;box-shadow:none!important;color:var(--ink);padding:4px 0;margin:0;border-radius:0;font-size:13px;line-height:1.6}.detail-input-row textarea:focus{outline:none!important}.detail-input-row button{border:0;background:transparent;color:var(--accent);font-size:12px;font-weight:700;padding:7px 0;min-width:42px}
#detailReply{display:flex;justify-content:space-between;align-items:center;gap:10px;font-size:11px;color:var(--muted);padding:0 0 12px;overflow-wrap:anywhere}#detailReply button{background:transparent;border:0;color:var(--muted);font-size:20px}.detail-composer p{font-size:11px;line-height:1.6;margin:9px 0 0}.detail-composer p.error{color:var(--danger);background:transparent;border:0}.detail-composer a{color:var(--accent)}
.post-detail [hidden]{display:none!important}.post-detail .sr-only{position:absolute;width:1px;height:1px;overflow:hidden;clip-path:inset(50%);white-space:nowrap}
@media(min-width:1600px){dialog.post-detail{grid-template-columns:minmax(0,1fr) 430px}}
@media(max-width:1100px){dialog.post-detail{width:calc(100vw - 32px);height:calc(100svh - 32px);grid-template-columns:minmax(0,1fr) 340px}.detail-header,.detail-summary,.detail-composer{padding-left:18px;padding-right:18px}.detail-discussion{padding:20px 18px}}
@media(max-width:700px){dialog.post-detail[open]{display:flex;flex-direction:column;width:calc(100vw - 16px);height:calc(100svh - 24px)}.detail-media{height:40%;flex:none}.detail-conversation{flex:1;border-left:0}.detail-header{min-height:58px;padding:10px 16px}.detail-photo-footer{min-height:36px;padding:5px 14px}.detail-summary{padding:8px 16px}.detail-summary time{display:none}.detail-discussion{padding:12px 16px}.detail-composer{padding:10px 16px}.detail-empty{min-height:110px;padding:14px}}
@media(prefers-reduced-motion:reduce){.detail-picture>img{transition:none}}
dialog.post-detail.conversation-only[open]{display:flex;flex-direction:column;position:fixed;left:0;right:0;bottom:auto;top:calc(var(--detail-offset,0px) + env(safe-area-inset-top) + 12px);margin:0 auto;width:min(576px,calc(100% - 16px));height:min(88svh,calc(var(--detail-viewport,100dvh) - 24px - env(safe-area-inset-top) - env(safe-area-inset-bottom)));max-height:calc(var(--detail-viewport,100dvh) - 24px - env(safe-area-inset-top) - env(safe-area-inset-bottom))}
.conversation-only .detail-media{display:none}
.conversation-only .detail-conversation{flex:1;border-left:0}
.conversation-only .detail-header{min-height:66px;padding:10px 16px}
.conversation-only .detail-close,.conversation-only .detail-actions button{width:44px;height:44px;min-width:44px}
.conversation-only .detail-actions{gap:8px}
.conversation-only .detail-summary{padding:5px 12px 12px}
.conversation-only .detail-discussion{padding:16px}
.conversation-only .detail-composer{padding:12px 16px}
.conversation-only .detail-input-row textarea{font-size:16px;min-height:44px;line-height:1.5;padding:10px 0}
.conversation-only .detail-input-row button{min-height:44px;font-size:14px}
.conversation-only .detail-comment-body>p{font-size:14px}
.conversation-only .detail-comment-meta{font-size:11px;gap:2px 10px}
.conversation-only .detail-comment-meta button{min-height:32px;font-size:11px}
.conversation-only .detail-comment-like{width:36px;height:44px}
.conversation-only .detail-comment-like svg{width:18px;height:18px}
.conversation-only .detail-comment.is-reply{margin-left:26px}

.post-age,.post-menu-button,.post-action-icon{display:none}
.post-caption-author,.post-published,.post-caption-toggle{display:none}
.post-heading .app-post-follow{order:1;flex:none}
.post-heading .post-menu-button{order:2}
.carousel-peek{position:absolute;inset:0;pointer-events:none;background:var(--paper);overflow:hidden}
.carousel-peek img{display:block;width:100%;height:100%;object-fit:contain}
.carousel-frame.is-dragging .carousel-photo{transition:none;will-change:transform}
.carousel-frame.is-dragging .carousel-counter{opacity:0}
/* A single mobile feed, shared by Safari and the native app canvas. */
:root.phone-post-feed #postFeed{gap:24px;width:100%;padding:0;grid-template-columns:minmax(0,1fr)}
:root.phone-post-feed #postFeed .post-card{border:0;border-radius:0;background:var(--paper);box-shadow:none;overflow:hidden;padding:0 0 12px}
:root.phone-post-feed #postFeed .post-heading{display:flex;align-items:center;gap:10px;padding:10px 12px;min-height:62px}
:root.phone-post-feed #postFeed .post-heading>.header-avatar-wrap{flex:none;display:block}
:root.phone-post-feed #postFeed .post-heading .avatar{width:34px;height:34px;border:1px solid var(--line);background:var(--soft)}
:root.phone-post-feed #postFeed .post-author-copy{min-width:0;flex:1}
:root.phone-post-feed #postFeed .post-author-line{display:flex;align-items:center;gap:5px;line-height:1.4}
:root.phone-post-feed #postFeed .post-author{min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;color:var(--ink);font-size:14px;font-weight:650;text-decoration:none}
:root.phone-post-feed #postFeed .post-author-badge{display:flex;align-items:center;flex:none}
:root.phone-post-feed #postFeed .post-author-badge img{width:16px;height:16px;margin:0}
:root.phone-post-feed #postFeed :is(.post-date,.post-age,.post-heading>.badge.new){display:none}
:root.phone-post-feed #postFeed .post-menu-button{display:grid;place-items:center;flex:none;order:2;width:44px;height:44px;padding:8px;margin:0 -5px 0 0;border:0;background:transparent;color:var(--ink)}
:root.phone-post-feed #postFeed .app-post-follow{order:1;flex:none}
:root.phone-post-feed #postFeed .app-post-follow .follow-button{font-size:12px;padding:6px;min-height:44px;border:0}
:root.phone-post-feed #postFeed .post-action-icon{display:block;width:26px;height:26px;flex:none}
:root.phone-post-feed #postFeed .post-menu-button svg{width:23px;height:23px}
:root.phone-post-feed #postFeed .carousel-frame{aspect-ratio:var(--photo-ratio,1)!important;width:100%;min-height:0;max-height:none;border:0;border-radius:0;background:var(--paper)}
:root.phone-post-feed #postFeed .carousel-photo{border:0;border-radius:0;background:transparent}
:root.phone-post-feed #postFeed .carousel-photo img{object-fit:contain}
:root.phone-post-feed #postFeed .carousel-arrow{display:none}
:root.phone-post-feed #postFeed .carousel-counter{top:12px;right:12px;min-width:36px;padding:6px 9px;background:#111b;border-radius:20px;font-size:11px;font-weight:500;letter-spacing:0;line-height:1.3}
:root.phone-post-feed #postFeed .carousel-dots{height:26px;min-height:26px;padding:0 12px;gap:0}
:root.phone-post-feed #postFeed .carousel-dot{flex:none;width:16px;height:26px}
:root.phone-post-feed #postFeed .carousel-dot span{width:5px;height:5px;opacity:.4;background:var(--muted)}
:root.phone-post-feed #postFeed .carousel-dot[aria-pressed=true] span{background:#5b78f6;opacity:1;transform:none;width:6px;height:6px}
:root.phone-post-feed #postFeed .post-bottom{display:flex;align-items:center;gap:14px;min-height:44px;padding:0 12px 4px;border:0}
:root.phone-post-feed #postFeed .post-bottom .social-button{display:inline-flex;align-items:center;justify-content:flex-start;gap:6px;min-width:44px;min-height:44px;padding:5px 0;margin:0;border:0;background:transparent;color:var(--ink);font-size:13px}
:root.phone-post-feed #postFeed .social-button>img,:root.phone-post-feed #postFeed .post-bottom>.image-count{display:none}
:root.phone-post-feed #postFeed .post-bottom .social-button.liked{color:#ed4956}
:root.phone-post-feed #postFeed .social-button.liked svg{fill:currentColor;stroke:currentColor}
:root.phone-post-feed #postFeed .post-bottom .bookmark-button{display:grid;place-items:center;margin-left:auto;width:44px;min-width:44px;height:44px;padding:5px 0 5px 12px;background:transparent;color:var(--ink)}
:root.phone-post-feed #postFeed .bookmark-button svg{width:25px;height:25px}
:root.phone-post-feed #postFeed .post-copy{padding:0 12px 0;line-height:1.5}
:root.phone-post-feed #postFeed .post-caption-content{display:block;overflow-wrap:anywhere;font-size:14px;line-height:1.5}
:root.phone-post-feed #postFeed .post-caption-content.can-collapse:not(.is-expanded){display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical;overflow:hidden}
:root.phone-post-feed #postFeed .post-caption-author{display:inline;color:var(--ink);font-size:14px;font-weight:650;text-decoration:none;margin-right:3px}
:root.phone-post-feed #postFeed .post-copy h2,:root.phone-post-feed #postFeed .post-copy p{display:inline;font:400 14px/1.5 var(--font-ui);color:var(--ink);letter-spacing:0;margin:0;white-space:pre-wrap}
:root.phone-post-feed #postFeed .post-caption-toggle{display:block;min-height:32px;padding:2px 0;border:0;background:transparent;color:var(--muted);font-size:13px;text-align:left}
:root.phone-post-feed #postFeed .post-published{display:block;margin:7px 0 0;font-size:11px;line-height:1.5;color:var(--muted)}
:root.phone-post-feed #postFeed :is(.album-entry,.admin-shortcuts){padding:8px 12px 0}
:root.phone-post-feed #postFeed .admin-shortcuts .btn{border:0;background:transparent;padding-left:0;color:var(--muted)}
:root.phone-post-feed #postFeed button:focus-visible{outline:2px solid var(--accent);outline-offset:-2px}
@media(max-width:900px){
 :root.phone-post-feed:not(.edwfoto-app) .social-layout{padding-left:0;padding-right:0}
 :root.phone-post-feed:not(.edwfoto-app) main.studio-main{padding-left:12px;padding-right:12px}
 :root.phone-post-feed:not(.edwfoto-app) #postFeed{width:calc(100% + 24px);max-width:none;margin-left:-12px;margin-right:-12px}
}
/* Feed posts use the page surface, a compact author line and the actual photo ratio. */
@media(min-width:901px){
 :root:not(.edwfoto-app) #postFeed{max-width:680px;gap:30px}
 :root:not(.edwfoto-app) #postFeed .post-card{border:0;border-radius:0;background:transparent;box-shadow:none;overflow:visible;padding:0 0 20px}
 :root:not(.edwfoto-app) #postFeed .post-heading{padding:0 4px 11px;gap:11px;min-height:54px;background:transparent}
 :root:not(.edwfoto-app) #postFeed .post-heading>.header-avatar-wrap{flex:none;display:grid;place-items:center;width:43px;height:43px;border:1px solid var(--line);border-radius:50%;padding:3px}
 :root:not(.edwfoto-app) #postFeed .post-heading .avatar{width:35px;height:35px}
 :root:not(.edwfoto-app) #postFeed .post-author-copy{min-width:0;flex:1}
 :root:not(.edwfoto-app) #postFeed .post-author-line{display:flex;align-items:center;flex-wrap:wrap;gap:5px;line-height:1.5}
 :root:not(.edwfoto-app) #postFeed .post-author{font-size:14px;font-weight:650;max-width:100%;overflow-wrap:anywhere;text-decoration:none;color:var(--ink)}
 :root:not(.edwfoto-app) #postFeed .post-author-badge{display:flex;align-items:center}
 :root:not(.edwfoto-app) #postFeed .post-author-badge img{width:16px;height:16px;margin:0}
 :root:not(.edwfoto-app) #postFeed .post-age{display:inline-flex;align-items:center;gap:6px;font-size:13px;color:var(--muted);font-weight:400;white-space:nowrap}
 :root:not(.edwfoto-app) #postFeed .post-heading>.badge.new,:root:not(.edwfoto-app) #postFeed .post-date{display:none}
 :root:not(.edwfoto-app) #postFeed .post-menu-button{display:grid;place-items:center;flex:none;margin-left:auto;width:34px;height:34px;border:0;border-radius:50%;color:var(--ink);background:transparent;cursor:pointer}
 :root:not(.edwfoto-app) #postFeed .post-menu-button:hover{background:var(--soft)}
 :root:not(.edwfoto-app) #postFeed .post-action-icon{display:block;width:24px;height:24px;flex:none}
 :root:not(.edwfoto-app) #postFeed .carousel-frame{aspect-ratio:var(--photo-ratio,1)!important;min-height:0;max-height:none;width:100%;border:1px solid var(--line);border-radius:5px;background:transparent}
 :root:not(.edwfoto-app) #postFeed .carousel-photo{background:transparent}
 :root:not(.edwfoto-app) #postFeed .carousel-counter{top:12px;right:12px;font-size:11px;padding:5px 9px;font-weight:500;letter-spacing:0}
 :root:not(.edwfoto-app) #postFeed .carousel-arrow{width:30px;height:30px;background:#17171799;color:#fff;border:1px solid #ffffff38;font-size:22px;box-shadow:none}
 :root:not(.edwfoto-app) #postFeed .carousel-prev{left:12px}
 :root:not(.edwfoto-app) #postFeed .carousel-next{right:12px}
 :root:not(.edwfoto-app) #postFeed .carousel-dots{min-height:23px}
 :root:not(.edwfoto-app) #postFeed .post-bottom{padding:7px 1px 10px;gap:18px;border:0}
 :root:not(.edwfoto-app) #postFeed .social-button{min-height:32px;gap:7px;padding:0;color:var(--ink);font-size:13px}
 :root:not(.edwfoto-app) #postFeed .social-button>img,:root:not(.edwfoto-app) #postFeed .post-bottom>.image-count{display:none}
 :root:not(.edwfoto-app) #postFeed .social-button.liked{color:#e94863}
 :root:not(.edwfoto-app) #postFeed .social-button.liked svg{fill:currentColor;stroke:currentColor}
 :root:not(.edwfoto-app) #postFeed .bookmark-button{margin-left:auto;min-height:32px;padding:0 1px;color:var(--ink)}
 :root:not(.edwfoto-app) #postFeed .bookmark-button svg{width:24px;height:24px}
 :root:not(.edwfoto-app) #postFeed .post-copy{padding:0 1px 14px;line-height:1.65}
 :root:not(.edwfoto-app) #postFeed .post-copy h2{font-size:14px;line-height:1.65;font-weight:650;letter-spacing:0}
 :root:not(.edwfoto-app) #postFeed .post-copy p{font-size:14px;line-height:1.65;color:var(--ink)}
 :root:not(.edwfoto-app) #postFeed :is(.album-entry,.admin-shortcuts){padding-left:1px;padding-right:1px}
 :root:not(.edwfoto-app) #postFeed .album-entry .btn{width:auto;min-height:32px;padding:5px 0;border:0;background:transparent;color:var(--muted);font-size:12px}
 :root:not(.edwfoto-app) #postFeed .admin-shortcuts .btn{font-size:11px;background:transparent;color:var(--muted)}
 :root:not(.edwfoto-app) #postFeed button:focus-visible{outline:2px solid var(--accent);outline-offset:3px}
 :root:not(.edwfoto-app)[data-gallery=grid] #postFeed{max-width:1100px;gap:28px}
 :root:not(.edwfoto-app)[data-gallery=grid] #postFeed .post-author{font-size:13px}
 :root:not(.edwfoto-app)[data-gallery=grid] #postFeed .post-age{font-size:11px}
}
.post-options{max-width:380px;border-radius:16px;padding:0;background:var(--card);color:var(--ink)}
.post-options .modal-head{padding:18px 20px}
.post-options .modal-head h2{font-size:16px;line-height:1.5;overflow-wrap:anywhere}
.post-options-list{display:grid;padding:0 12px 12px}
.post-options-list>*{display:block;border:0;border-radius:8px;background:transparent;color:var(--ink);padding:14px 12px;text-align:left;font:500 13px/1.5 var(--font-ui);text-decoration:none;cursor:pointer}
.post-options-list>*:hover{background:var(--soft)}
