/* Account and media reuse the existing GRiD window manager and theme palette. */
#login-panel .discord-identity-card{gap:7px}
#login-panel .discord-identity-icon{width:21px;height:21px;font-size:17px}
#login-panel .discord-identity-card>div{flex:1;min-width:0;flex-direction:row;align-items:center;gap:7px}
#login-panel .discord-identity-card strong{flex:1;min-width:0;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
#login-panel .discord-identity-card small{flex:none;font-size:9px;white-space:nowrap}
#login-panel .discord-identity-card a{flex:none;font-size:10px;white-space:nowrap}
.account-workspace>.account-panel{grid-column:1/-1}
.account-panel .panel-body{padding:6px;min-width:0}
.account-frame{display:block;width:100%;height:clamp(380px,calc(100vh - 230px),740px);border:0;background:var(--panel)}
.account-access-message{padding:20px;color:var(--text);line-height:1.6}
#panel-manager-list .panel-tile:disabled{opacity:.5;cursor:not-allowed}
@media(max-width:360px){#login-panel .discord-identity-card{gap:5px}#login-panel .discord-identity-card>div{gap:5px}#login-panel .discord-identity-card .discord-signin{font-size:9px}}

/* Keep the original media-panel heights; swap only within the left/right slot. */
.account-workspace.workspace-slots-ready{display:grid;grid-template-columns:var(--workspace-left-width) minmax(0,1fr);align-items:start}
.workspace-slots-ready>[data-workspace-slot="left"]{grid-column:1;grid-row:var(--workspace-panel-row,2);--workspace-slot-height:var(--workspace-left-height)}
.workspace-slots-ready>[data-workspace-slot="right"]{grid-column:2;grid-row:var(--workspace-panel-row,2);--workspace-slot-height:var(--workspace-right-height)}
.workspace-slots-ready>.account-access-message[role="alert"]{grid-column:1/-1;grid-row:2}
.workspace-slots-ready>[data-workspace-slot]:not(.is-minimized):not(.is-maximized){height:var(--workspace-slot-height);display:flex;flex-direction:column}
.workspace-slots-ready>[data-workspace-slot]:not(.is-minimized)>.panel-body{display:flex;flex-direction:column;flex:1;min-height:0}
.workspace-slots-ready .account-frame{height:100%;min-height:0;flex:1}
.workspace-slots-ready>.account-panel:not(.is-minimized):not(.is-maximized){height:var(--workspace-slot-height);min-height:0}
.workspace-slots-ready>.account-panel:not(.is-minimized)>.panel-body{flex:1;min-height:0}
.workspace-slots-ready .account-frame{height:100%;min-height:0;flex:1}
.workspace-slots-ready .logo-stage,.workspace-slots-ready .media-stage{height:auto;min-height:0;flex:1;overflow:hidden}
.workspace-slots-ready .logo-stage{grid-template-rows:minmax(0,1fr) auto}
.workspace-slots-ready .logo-stage img{width:100%;height:100%;min-width:0;min-height:0;object-fit:contain}
.workspace-slots-ready .logo-stage figcaption{max-width:100%;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;text-align:center}
.workspace-slots-ready .media-stage img,.workspace-slots-ready .media-stage video{display:block;width:100%;height:100%;min-width:0;min-height:0;object-fit:cover;object-position:center}
.workspace-slots-ready .media-youtube-frame,.workspace-slots-ready .media-youtube-frame iframe{display:block;width:100%;height:100%;min-width:0;min-height:0;border:0}
.workspace-slots-ready .logo-dots,.workspace-slots-ready .media-dots{height:24px;flex:none;flex-wrap:nowrap;overflow-x:auto;justify-content:safe center;scrollbar-width:none}
.workspace-slots-ready .logo-dots button,.workspace-slots-ready .media-dots button{flex:none}
.account-workspace.workspace-slots-stacked{grid-template-columns:minmax(0,1fr)}
.workspace-slots-stacked>[data-workspace-slot="right"]{grid-column:1;grid-row:var(--workspace-right-row,3)}

/* Account view uses four equal-height columns; MEDIA keeps its paired slots. */
.account-workspace.is-account-grid{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:10px;align-items:stretch}
.account-workspace.is-account-grid:not(.has-staff){grid-template-columns:repeat(3,minmax(0,1fr))}
.account-workspace.is-account-grid>.account-panel{grid-column:auto;grid-row:auto;min-width:0}
.account-workspace.is-account-grid>.account-panel:not([hidden]):not(.is-maximized){display:flex;flex-direction:column;height:max(540px,calc(100dvh - var(--account-grid-top,198px) - 12px))}
.account-workspace.is-account-grid>.account-panel:not(.is-minimized)>.panel-body{display:flex;flex:1;min-height:0;overflow:hidden}
.account-workspace.is-account-grid .account-frame{flex:1;min-height:0;height:100%}
@media(max-width:1200px){.account-workspace.is-account-grid,.account-workspace.is-account-grid:not(.has-staff){grid-template-columns:repeat(2,minmax(0,1fr))}}
@media(max-width:700px){.account-workspace.is-account-grid,.account-workspace.is-account-grid:not(.has-staff){grid-template-columns:minmax(0,1fr)}.account-workspace.is-account-grid>.account-panel:not([hidden]):not(.is-maximized){height:auto;min-height:420px}.account-workspace.is-account-grid .account-frame{height:420px;flex:none}}

/* Compact identity and recent profile photos share Activity Stream's height limit. */
#login-panel{display:flex;flex-direction:column;max-height:var(--identity-height-cap,230px)}
#login-panel>.panel-header{flex-shrink:0}
#login-panel>.identity-body{min-height:0;overflow-y:auto;overflow-x:hidden;padding:5px 7px;scrollbar-width:thin;scrollbar-color:var(--cyan) #111}
#login-panel.is-minimized>.identity-body{display:none}
#login-panel .discord-identity-card{display:flex;align-items:center;gap:7px}
#login-panel .discord-identity-icon{flex:none;border-radius:50%;overflow:hidden}
#login-panel .discord-identity-icon img{display:block;width:100%;height:100%;object-fit:cover;border-radius:50%}
#login-panel .identity-recent{margin-top:5px;padding-top:5px;border-top:1px solid var(--line-soft)}
#login-panel .identity-recent-heading{display:flex;justify-content:space-between;gap:5px;margin-bottom:4px;color:#a4bdd0;font-size:8px;line-height:12px}
#login-panel .identity-recent-heading b{color:var(--cyan)}
#login-panel .identity-avatars{display:flex;flex-wrap:wrap;gap:5px;margin:0;padding:0;list-style:none}
#login-panel .identity-avatars li{flex:none}
#login-panel .identity-member-avatar{display:flex;align-items:center;justify-content:center;width:28px;height:28px;border:1px solid var(--line-soft);border-radius:50%;overflow:hidden;background:var(--panel-soft);color:var(--pink);font-size:18px}
#login-panel .identity-member-avatar img{display:block;width:100%;height:100%;border-radius:50%;object-fit:cover}
#login-panel .identity-member-avatar:hover,#login-panel .identity-member-avatar:focus-visible{border-color:var(--pink)}
#login-panel .identity-recent-empty{display:block;color:var(--muted);font-size:8px;line-height:12px}
