:root{--site-header-height:64px;--site-header-primary-row:63px;--site-header-tabs-row:42px}
/* Compact tool switcher; keep each page's existing layout. */
.site-tabs{display:flex;align-items:center;gap:6px;flex-shrink:0;margin:0;padding:0;border:0;border-radius:0;background:none;box-shadow:none}
.site-tabs a{display:flex;align-items:center;justify-content:center;gap:8px;padding:9px 12px;border:1px solid transparent;border-radius:8px;color:#99adbf;font:550 12px/1.5 Inter,"Microsoft YaHei",system-ui,sans-serif;white-space:nowrap;text-decoration:none;transition:background .16s,color .16s,border-color .16s}
.site-tabs a:hover{background:#21313f;color:#e3edf4}
.site-tabs a[aria-current="page"]{color:#d8f5a1;border-color:#b4d77430;background:#bfd87612}
.site-tabs svg{width:16px;height:16px;flex:none}
.site-tabs a:focus-visible{outline:2px solid #d4ff68;outline-offset:3px}
.chat-topbar .site-tabs{margin-right:auto}
.chat-topbar>div:has(#sidebar-toggle){gap:0}
@media(max-width:1150px){.site-tabs a{font-size:11px;padding:8px 9px;gap:6px}.site-tabs{gap:4px}}
@media(max-width:1050px){.chat-topbar{flex-wrap:wrap;height:auto;min-height:98px;padding-top:10px;padding-bottom:10px;gap:8px}.chat-topbar .site-tabs{order:3;flex-basis:100%;justify-content:center}.chat-topbar .balance-chip{margin-left:auto}}
@media(max-width:760px){.topbar:has(.site-tabs){height:auto;flex-wrap:wrap;gap:12px;padding-top:12px;padding-bottom:12px}.topbar>.site-tabs{order:2;flex-basis:100%;justify-content:center}.topbar>.topbar-actions{margin-left:auto}.site-tabs a{padding:8px 7px;gap:5px}.site-tabs svg{width:14px;height:14px}}
@media(max-width:380px){.site-tabs svg{display:none}.site-tabs a{font-size:10px}.site-tabs{gap:3px}}
@media(prefers-reduced-motion:reduce){.site-tabs a{transition:none}}

/* Align the design header with the existing review header. */
.topbar:has(.site-tabs){align-content:flex-start}
:is(.design-page,.qa-page) .topbar{display:flex;justify-content:flex-start;flex-wrap:wrap;align-items:center;gap:16px;height:auto;min-height:78px;padding:12px clamp(22px,5vw,76px);border-bottom:1px solid #314057;background:#090d15cc}
:is(.design-page,.qa-page) .topbar>.brand{display:flex;align-items:center;gap:12px;flex-shrink:0;padding:0;font:750 19px/1.15 Inter,"Microsoft YaHei","PingFang SC",sans-serif;color:#f2f6ff;letter-spacing:.2px}
:is(.design-page,.qa-page) .topbar>.brand img{width:38px;height:38px;border-radius:12px}
:is(.design-page,.qa-page) .topbar>.brand>span{font:inherit;color:inherit;margin:0;letter-spacing:inherit}
:is(.design-page,.qa-page) .topbar>.brand .brand-sub{display:block;margin:5px 0 0;font:750 9px/1.15 Inter,"Microsoft YaHei","PingFang SC",sans-serif;letter-spacing:2px;color:#718198}
:is(.design-page,.qa-page) .topbar-actions{margin-left:auto}
@media(max-width:760px){:is(.design-page,.qa-page) .topbar{padding-inline:4%;gap:12px}:is(.design-page,.qa-page) .topbar>.brand{font-size:16px}:is(.design-page,.qa-page) .topbar>.brand img{width:27px;height:27px}}

/* Chat content stays below the shared product header. */
.qa-page{flex-direction:column}
.qa-page>.topbar{flex:none;position:relative;z-index:6}
.qa-layout{position:relative;display:flex;flex:1;min-height:0;overflow:hidden}
.qa-page .chat-topbar{display:none}
.qa-page .new-chat{margin-top:0}
.qa-page .balance-chip{border:1px solid #2e3d52;border-radius:12px;padding:9px 15px;background:#151d2a;color:#f2f6ff;font-size:12px}
.qa-page .balance-chip:hover{border-color:#80965c;background:#1c2935}
@media(max-width:700px){.qa-page .chat-topbar{display:flex;flex:none;min-height:48px;height:48px;padding:0 14px}.qa-page .chat-topbar strong{font-size:12px;color:#93a2b6}.qa-page .sidebar,.qa-page .sidebar-backdrop:not([hidden]){position:absolute}.qa-page .balance-chip{padding:7px 10px;font-size:11px}}

/* Stable product navigation shared by review, workshop and Q&A. */
.topbar.site-header{box-sizing:border-box;display:grid;grid-template-columns:max-content minmax(0,1fr) auto;grid-template-rows:var(--site-header-primary-row);align-items:center;align-content:center;gap:0 12px;width:100%;height:var(--site-header-height);min-height:var(--site-header-height);flex:none;flex-wrap:nowrap;margin:0;padding:0 16px;border:0;border-bottom:1px solid #314057;background:#090d15;position:relative;z-index:40}
.topbar.site-header>.brand{grid-column:1;grid-row:1;display:flex;align-items:center;gap:10px;min-width:0;flex:none;margin:0;padding:0;font:750 19px/1.15 Inter,"Microsoft YaHei","PingFang SC",sans-serif;letter-spacing:0;color:#f2f6ff;text-decoration:none;white-space:nowrap}
.topbar.site-header>.brand img{display:block;flex:none;width:38px;height:38px;border-radius:12px;box-shadow:0 0 0 1px #d4ff6830,0 0 24px #d4ff6830}
.topbar.site-header>.brand>span{font:inherit;letter-spacing:inherit;color:inherit;margin:0}
.topbar.site-header>.brand .brand-sub{display:block;margin:5px 0 0;font:750 9px/1.15 Inter,"Microsoft YaHei","PingFang SC",sans-serif;letter-spacing:2px;color:#718198}
.topbar.site-header>.site-tabs{grid-column:2;grid-row:1;display:flex;justify-content:flex-start;align-items:center;gap:3px;min-width:0;width:100%;margin:0;padding:0;overflow-x:auto;scrollbar-width:none;overscroll-behavior-x:contain}
.topbar.site-header>.site-tabs::-webkit-scrollbar{display:none}
.topbar.site-header>.site-tabs a{flex:none;gap:6px;padding:7px 9px;font:550 12px/1.5 Inter,"Microsoft YaHei",system-ui,sans-serif}
.topbar.site-header>.site-tabs svg{width:16px;height:16px;display:block;fill:none;stroke:currentColor;stroke-width:1.5;stroke-linecap:round;stroke-linejoin:round}
.topbar.site-header>:is(.account-bar,.topbar-actions){grid-column:3;grid-row:1;justify-self:end;min-width:0;margin:0}
.topbar.site-header .result-actions{display:flex;flex-wrap:nowrap;gap:8px;width:auto}
.topbar.site-header .button{min-height:36px;padding:7px 12px;font-size:12px}
.topbar.site-header:has(>.promotion-bar:not([hidden])){grid-template-columns:max-content minmax(0,1fr) auto auto}
.topbar.site-header:has(>.promotion-bar:not([hidden]))>.account-bar{grid-column:4}
.topbar.site-header>.promotion-bar{grid-area:1/3/2/4;justify-self:end;align-self:center;flex:none;width:max-content;max-width:100%;margin:0;padding:6px 10px;border:1px solid #705622;border-radius:7px;line-height:1.35}
.topbar.site-header>.promotion-bar p{display:none}
.site-status{display:flex;align-items:center;justify-content:flex-end;gap:16px;padding:0 20px;color:#a5afbc;font-size:11px}
.site-status>.promotion-bar{flex:none;width:auto;max-width:100%;margin:10px auto 0;padding:6px 10px}
.site-status>.promotion-bar p{display:none}.site-status>.qq-group{margin:10px 0 0;font-size:11px}
@media(max-width:1100px){
 :root{--site-header-height:92px;--site-header-primary-row:49px}
 .topbar.site-header{grid-template-columns:minmax(0,1fr) auto;grid-template-rows:var(--site-header-primary-row) var(--site-header-tabs-row);height:var(--site-header-height);min-height:var(--site-header-height);gap:0 10px;padding:0 16px}
 .topbar.site-header>.brand{font-size:18px}.topbar.site-header>.brand img{width:32px;height:32px}
 .topbar.site-header>.site-tabs{grid-column:1/-1;grid-row:2;align-self:center;justify-content:flex-start}
 .topbar.site-header>:is(.account-bar,.topbar-actions){grid-column:2;grid-row:1}
 .topbar.site-header:has(>.promotion-bar:not([hidden])){grid-template-columns:minmax(0,1fr) auto}
 .topbar.site-header:has(>.promotion-bar:not([hidden]))>.account-bar{grid-column:2}
 .topbar.site-header:has(>.promotion-bar:not([hidden]))>.site-tabs{grid-column:1}
 .topbar.site-header>.promotion-bar{grid-area:2/2/3/3}
 .site-status{flex-wrap:wrap}.site-status>.qq-group{display:none}
}
@media(max-width:600px){
 .topbar.site-header{padding-inline:14px}.topbar.site-header>.brand{font-size:16px;gap:9px}.topbar.site-header>.brand img{width:27px;height:27px}.topbar.site-header>.brand .brand-sub{font-size:8px;letter-spacing:1.5px}
 .topbar.site-header>.site-tabs a{font-size:11px;padding:7px 8px;gap:5px}.topbar.site-header>.site-tabs{gap:3px}
 .topbar.site-header>.account-bar .button{padding:6px 9px;min-height:32px;font-size:11px}.topbar.site-header .account-bar-logout{display:none}.qa-page .topbar.site-header .balance-chip{padding:7px 9px;font-size:10px}
}

/* One account area for all three public tools. */
.topbar.site-header .account-bar{display:flex;align-items:center;gap:8px;flex-wrap:nowrap}
.topbar.site-header .account-bar [hidden]{display:none!important}
.topbar.site-header .account-bar .result-actions{display:flex;align-items:center;gap:12px;flex-wrap:nowrap}
.topbar.site-header .account-bar .button{display:inline-flex;align-items:center;justify-content:center;min-height:38px;margin:0;padding:8px 16px;border:1px solid #3b4e64;border-radius:11px;background:#192637;color:#edf2fa;font:650 13px/1.5 Inter,"Microsoft YaHei",system-ui,sans-serif;white-space:nowrap;cursor:pointer;text-decoration:none}
.topbar.site-header .account-bar .primary{border-color:#d1f980;background:linear-gradient(120deg,#d7ff73,#b8ef4e);color:#17250a}
.topbar.site-header #account-open.account-open-signed-in{min-width:120px;min-height:42px;padding:9px 24px;border-color:#91b64c;background:linear-gradient(135deg,#455c2c,#334622);box-shadow:inset 0 1px 0 #ffffff14,0 0 16px #baff4a12;color:#f0ffd4;font-size:14px;font-weight:700}
.topbar.site-header #account-open.account-open-signed-in:hover:not(:disabled){border-color:#c2ee69;background:linear-gradient(135deg,#536e34,#405729)}
.topbar.site-header .account-bar .account-bar-logout{display:inline-flex;align-items:center;justify-content:center;min-height:36px;margin:0;padding:7px 4px;border:0;background:none;color:#8cdae6;font:550 13px/1.5 Inter,"Microsoft YaHei",system-ui,sans-serif;white-space:nowrap;cursor:pointer}
.topbar.site-header .account-bar .account-bar-logout:hover:not(:disabled){color:#ffb5a6}
.topbar.site-header .account-bar button:disabled{opacity:.5;cursor:wait}
.topbar.site-header .account-bar button:focus-visible{outline:2px solid #d4ff68;outline-offset:3px}
.qa-page .sidebar-footer .balance-chip{width:100%;margin-top:10px}
@media(max-width:600px){
 .topbar.site-header>.brand{max-width:calc(100vw - 188px);gap:8px;font-size:14px}
 .topbar.site-header>.brand>span{overflow:hidden;text-overflow:ellipsis}
 .topbar.site-header .account-bar .result-actions{gap:9px}
 .topbar.site-header .account-bar .button{min-height:34px;padding:6px 11px;font-size:12px}
 .topbar.site-header #account-open.account-open-signed-in{min-width:88px;min-height:36px;padding:7px 12px;font-size:12px}
 .topbar.site-header .account-bar .account-bar-logout{display:inline-flex;min-height:34px;padding:6px 0;font-size:11px}
}

.site-tabs .tool-beta{display:inline-block;margin-left:3px;padding:0 4px;border:1px solid #b4d77440;border-radius:4px;font:500 10px/1.5 Inter,system-ui,sans-serif;color:#c6df91;text-transform:none;vertical-align:1px}

/* A restrained silhouette glow adds weight without a tinted rectangular base. */
.brand img[src*="favicon.svg"],.topbar.site-header>.brand img[src*="favicon.svg"]{width:44px;height:38px;flex:0 0 44px;box-sizing:border-box;padding:2px;border:0;border-radius:15px 15px 21px 21px;background:transparent;box-shadow:none;filter:drop-shadow(0 0 2px #cfff7866) drop-shadow(0 0 8px #b8ef6852);animation:none;object-fit:contain}
@media(max-width:1100px){.brand img[src*="favicon.svg"],.topbar.site-header>.brand img[src*="favicon.svg"]{width:40px;height:36px;flex-basis:40px;border-radius:13px 13px 18px 18px}}
@media(max-width:560px){.brand img[src*="favicon.svg"],.topbar.site-header>.brand img[src*="favicon.svg"]{width:34px;height:30px;flex-basis:34px;border-radius:11px 11px 15px 15px}}
