/* One square hit area for every pencil, independent of inherited form sizing. */
body .identity-cover>.appearance-edit{display:grid;place-items:center;width:34px;height:34px;min-width:34px;max-width:34px;min-height:34px;max-height:34px;aspect-ratio:1;padding:0;flex:0 0 34px;border-radius:50%;line-height:1}
body .profile-page .editable-portrait>.appearance-edit{top:-2px;left:-2px;right:auto;bottom:auto;z-index:2;padding:0;min-width:30px;max-width:30px;max-height:30px;aspect-ratio:1}
body .profile-page .profile-person>.member-portrait>img.platform-badge,.profile-page .editable-portrait>.identity-portrait>.platform-badge{position:absolute;inset:auto -2px -2px auto;width:34px;height:34px;min-width:34px;max-width:34px;border-radius:50%;object-fit:contain;border:2px solid #fff;background:#fff;padding:2px}
.profile-avatar-link{display:inline-flex;flex:none;width:max-content;height:max-content;line-height:1;border-radius:50%}.profile-avatar-link:focus-visible{outline:2px solid #555;outline-offset:4px}.profile-avatar-link .member-portrait,.profile-avatar-link .identity-portrait{display:inline-flex;margin:0;flex:none}.chat-message>.profile-avatar-link{grid-column:1;grid-row:1}.chat-message.is-me>.profile-avatar-link{grid-column:2}.bot-platform-avatar>.portrait-image{object-fit:contain;background:white;padding:3px}.member-portrait[data-profile-id]{cursor:pointer}
.rich-tech-row .tech-logo-link{display:block;width:46px;height:46px;line-height:0}.rich-tech-row .tech-logo-link img{display:block;width:100%;height:100%;object-fit:contain}.rich-tech-row .tech-identity h2 a{display:inline}.rich-tech-row .tech-identity{flex:1}.rich-tech-row .tech-identity p,.rich-tech-row .tech-identity span{cursor:default}.tech-example-label{font-size:10px;color:#999;margin:18px 0 -6px}.project-strip.has-captions{align-items:flex-start;padding-bottom:2px}.has-captions .strip-project{height:auto;min-height:var(--thumb-height);border-radius:0;overflow:visible}.has-captions .strip-project .art{height:var(--thumb-height);border-radius:10px;overflow:hidden}.strip-project-title{display:block;font-size:11px;line-height:1.45;margin-top:7px;white-space:normal;overflow-wrap:anywhere;color:#666}.generated-project-thumb{display:block;width:100%;height:100%;object-fit:cover}
.listing-praise{display:flex;gap:14px;flex-wrap:wrap;margin:8px 0;font-size:11px;line-height:1.5}.listing-praise>a:first-child{color:#555}.listing-praise>a:last-child{color:#999}.listing-praise a:hover{text-decoration:underline;text-underline-offset:3px}.praise-heading{display:flex;align-items:baseline;justify-content:space-between;gap:12px;margin-bottom:14px}.praise-heading h2{margin:0}.praise-heading>a{font-size:11px;color:#999;white-space:nowrap}#projectPraise{scroll-margin-top:88px}
.publish-steps{list-style:none;display:flex;gap:16px;margin:0 0 20px;padding:0;font-size:10px;color:#999;counter-reset:step}.publish-steps li{counter-increment:step}.publish-steps li:before{content:counter(step) ' ';color:#555}.publish-version-note{font-size:12px;line-height:1.6;color:#666;margin:12px 0}.publish-actions #publishStatus{line-height:1.5}
@media(max-width:700px){.rich-tech-row .tech-logo-link{width:38px;height:38px}.listing-praise{font-size:10px;gap:9px}.publish-steps{gap:10px;font-size:9px}.profile-page .editable-portrait>.identity-portrait>.platform-badge,body .profile-page .profile-person>.member-portrait>img.platform-badge{width:30px;height:30px;min-width:30px;max-width:30px}}

.project-strip[data-expanded="true"]{flex-wrap:wrap;overflow:visible}
dialog[open]:has(#liveReviewForm){display:flex;flex-direction:column;height:min(850px,88dvh);max-height:88dvh;overflow:hidden}
dialog:has(#liveReviewForm)>h2{flex:none}
dialog:has(#liveReviewForm)>.publish-steps{flex:none;padding:0 24px;margin:0 0 18px}
#liveReviewForm{flex:1;max-height:none;min-height:0;margin:0}

/* Keep each studio project's preview and management controls distinct. */
.studio-projects>.projects-section-heading{margin:24px 0 8px;padding-top:4px}
.studio-projects>.projects-section-heading h2{margin:0;font-size:20px}
.studio-projects>.projects-section-heading button{font-size:13px;min-height:40px;flex-shrink:0}
.studio-projects>.directory-card{padding:24px 0 10px;min-width:0}
.studio-projects>.directory-card>.row{align-items:center;gap:12px;flex-wrap:wrap}
.studio-projects>.directory-card>.row h2{margin:0;min-width:0;overflow-wrap:anywhere}
.studio-projects>.directory-card>p{margin:12px 0 18px;line-height:1.65}
.studio-projects .chat-work-card{width:100%;max-width:100%;margin-bottom:0}
.studio-project-footer{display:flex;flex-wrap:wrap;align-items:flex-start;gap:0 24px;margin-top:6px;padding-top:0}
.studio-project-footer .live-project-actions{flex:1;display:flex;align-items:center;flex-wrap:wrap;gap:0 22px;margin:0;min-width:0}
.studio-project-footer .live-project-actions>button,.studio-project-footer .live-project-actions>a,.studio-projects .project-history>summary{font-size:13px;line-height:1.5;min-height:40px;padding:10px 0;text-align:left}
.studio-project-footer .live-project-actions>a{display:inline-flex;align-items:center}
.studio-project-footer .live-project-actions .edit-icon{width:14px;height:14px}
.studio-projects .project-history{min-width:0}
.studio-projects .project-history>summary{cursor:pointer;width:max-content;max-width:100%;color:#555}
.studio-projects .project-history>summary::marker{font-size:10px}
.studio-projects .version-count{color:#999;font-variant-numeric:tabular-nums}
.studio-project-footer .project-history[open]{flex-basis:100%;margin-bottom:12px}
.studio-projects .version-history-note{font-size:11px;color:#999;margin:4px 0 12px}
.studio-projects .project-history-list{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:16px;padding-bottom:12px}
@media(max-width:600px){
 .studio-projects>.projects-section-heading{margin-top:20px}
 .studio-project-footer{display:block;margin-top:6px;padding-top:0}
 .studio-project-footer .project-history{margin:0;padding:0}
 .studio-project-footer .live-project-actions{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:0 18px}
 .studio-project-footer .live-project-actions>a{grid-column:1/-1}
 .studio-projects .project-history-list{grid-template-columns:minmax(0,1fr)}
}

.studio-projects>.directory-card>.studio-project-title{align-items:baseline;justify-content:flex-start}
.studio-projects .studio-project-title>.badge{margin:0;white-space:nowrap;align-self:baseline}
/* The media has a screen ratio; captions and controls sit below that frame. */
.studio-projects .chat-work-preview{position:relative;aspect-ratio:16/9;height:auto;min-height:0;display:flex;flex-direction:column;justify-content:center}
.studio-projects .chat-work-preview>.work-preview-open{display:block;width:100%;height:100%;min-height:0;flex:1}
.studio-projects .chat-work-preview img,.studio-projects .chat-work-preview video{display:block;width:100%;height:100%;max-height:100%;object-fit:contain}
.studio-projects .chat-work-preview .work-placeholder{height:100%;min-height:0;display:grid;place-items:center}
.studio-projects .chat-work-preview .work-text-preview{height:100%;max-height:100%;overflow:hidden;box-sizing:border-box}
.studio-projects .chat-work-preview>.audio-art{flex:1;min-height:0;height:auto}
.studio-projects .chat-work-preview>audio{flex:none}

/* Badges scale with their portrait, including logos on large bot profile pictures. */
.identity-portrait>.platform-badge,.member-portrait>.platform-badge{box-sizing:border-box;width:46%;height:46%;min-width:0;min-height:0;max-width:none;max-height:none;aspect-ratio:1;object-fit:contain;position:absolute;right:-3%;bottom:-3%;border:1.5px solid #fff;border-radius:50%;padding:2%;background:#fff;flex:none}
body .profile-page .editable-portrait>.identity-portrait>.platform-badge,body .profile-page .profile-person>.member-portrait>.platform-badge{box-sizing:border-box;width:46%;height:46%;min-width:0;min-height:0;max-width:none;max-height:none;aspect-ratio:1;right:-3%;bottom:-3%;inset:auto -3% -3% auto;object-fit:contain;padding:3%;border:2px solid #fff;background:#fff}
.platform-unknown{color:#666}.live-member-actions{display:flex;gap:16px;align-items:center;flex-wrap:wrap;margin-left:auto}.live-member-actions button{font-size:12px;white-space:nowrap}.creator-transfer-actions{display:flex;align-items:center;justify-content:flex-end;gap:16px;margin-top:20px}
@media(max-width:600px){.live-member{flex-wrap:wrap}.live-member-actions{width:100%;margin-left:46px;gap:18px}}


.monthly-entry .project-strip,.monthly-entry .no-studio-projects{grid-column:2 / -1;min-width:0;margin-top:12px}.monthly-entry .studio-name{min-width:0}.monthly-entry .studio-name h2{overflow-wrap:anywhere}.monthly-entry .studio-portrait{width:48px;height:48px;flex:0 0 48px;border-radius:10px;overflow:hidden;display:grid;place-items:center}.monthly-entry .studio-portrait img{width:100%;height:100%;object-fit:cover}.monthly-entry .studio-kind{margin:3px 0 5px}
@media(max-width:700px){.monthly-entry .studio-portrait{width:40px;height:40px;flex-basis:40px}.monthly-entry .studio-name{gap:9px}.monthly-entry .project-strip{grid-column:2 / -1}}

/* Keep quoted text and its reply distinct within the same bubble. */
.shared-chat .chat-content>.live-quote{margin-bottom:6px}
/* Match the project's 16:9 contain frame in the publication review. */
#liveReviewPreview.publish-preview{display:flex;flex-direction:column;justify-content:center;aspect-ratio:16/9;width:100%;height:auto;min-height:0;max-height:none}
#liveReviewPreview.publish-preview>img,#liveReviewPreview.publish-preview>video{display:block;width:100%;height:100%;max-height:100%;min-height:0;object-fit:contain}
#liveReviewPreview.publish-preview>.work-placeholder{height:100%;min-height:0;display:grid;place-items:center}
#liveReviewPreview.publish-preview>.work-text-preview{height:100%;max-height:100%;overflow:hidden;box-sizing:border-box}
#liveReviewPreview.publish-preview>.audio-art{flex:1;min-height:0;height:auto}
#liveReviewPreview.publish-preview>audio{flex:none}
/* The tab labels already name these panels. Keep only the panel actions. */
.studio-projects>.studio-tab-actions,.studio-members>.studio-tab-actions{display:flex;justify-content:flex-end;align-items:center;margin:16px 0 4px;padding:0;min-height:40px}
/* Fixed role and action columns keep every Admin/Member label aligned. */
.studio-members .live-member{display:grid;grid-template-columns:36px minmax(0,1fr) 76px 44px;align-items:center;gap:12px;overflow:visible}
.studio-members .live-member>.profile-avatar-link{grid-column:1;min-width:0}
.studio-members .live-member>a:not(.profile-avatar-link){grid-column:2;min-width:0;overflow-wrap:anywhere}
.studio-members .live-member>.badge{grid-column:3;justify-self:start;margin:0;white-space:nowrap}
.studio-members .live-member-menu{grid-column:4;position:relative;justify-self:end;align-self:center}
.studio-members .live-member-menu[open]{z-index:4}
.studio-members .live-member-menu>summary{display:grid;place-items:center;list-style:none;cursor:pointer;width:44px;height:44px;padding:0;border:0;border-radius:8px;color:#777}
.studio-members .live-member-menu>summary::-webkit-details-marker{display:none}
.studio-members .live-member-menu>summary:hover,.studio-members .live-member-menu[open]>summary{background:#f6f6f5;color:#171717}
.studio-members .live-member-menu>summary:focus-visible{outline:2px solid #59788a;outline-offset:2px}
.studio-members .live-member-menu>.live-member-actions{position:absolute;inset:calc(100% + 4px) 0 auto auto;display:grid;gap:2px;min-width:168px;width:max-content;max-width:calc(100vw - 40px);padding:6px;margin:0;border:1px solid #e8e8e8;border-radius:10px;background:#fff;box-shadow:0 8px 24px #00000012;z-index:5}
.studio-members .live-member-menu:not([open])>.live-member-actions{display:none}
.studio-members .live-member-actions>button{display:block;width:100%;min-height:40px;padding:10px 12px;border-radius:5px;text-align:left;font-size:12px;line-height:20px;white-space:normal}
.studio-members .live-member-actions>button:hover{background:#f6f6f5}
@media(max-width:600px){.studio-members .live-member{grid-template-columns:32px minmax(0,1fr) 64px 44px;gap:10px}.studio-members .live-member>.badge{font-size:10px}}

/* Shared Studio identity sizing: directory, leaderboard and Studio header. */
:root{--studio-avatar-size:48px;--studio-avatar-radius:10px;--studio-title-size:20px;--studio-meta-size:12px;--studio-identity-gap:14px}
.studio-name,.monthly-entry .studio-name,.studio-heading-compact .studio-name{gap:var(--studio-identity-gap);align-items:center;min-width:0}
.studio-name .studio-portrait,.monthly-entry .studio-portrait,.studio-heading-compact .studio-portrait,.studio-heading-compact .editable-studio-portrait{width:var(--studio-avatar-size);height:var(--studio-avatar-size);flex:0 0 var(--studio-avatar-size);border-radius:var(--studio-avatar-radius)}
.studio-name .studio-portrait{font-size:23px}
.studio-name h2,.monthly-entry .studio-name h2,.studio-heading-compact h2{font-size:var(--studio-title-size);line-height:1.2;font-weight:500;letter-spacing:-.4px;margin:0;overflow-wrap:anywhere}
.studio-name .studio-kind,.monthly-entry .studio-kind,.studio-heading-compact .studio-kind{display:block;font-size:var(--studio-meta-size);line-height:1.4;font-weight:400;margin:3px 0 5px}
.studio-name .small,.studio-heading-compact .studio-result-link{font-size:var(--studio-meta-size);line-height:1.4;font-weight:400}
.studio-heading-compact .appearance-edit{box-sizing:border-box;padding:5px;width:26px;height:26px;min-height:26px;flex-basis:26px}
.studio-heading-compact .appearance-edit svg{display:block;width:14px;height:14px}
@media(max-width:700px){:root{--studio-title-size:18px;--studio-identity-gap:12px}}
