:root,
[data-theme="dark"]{
  --ccg-nav-bg:#000;
  --ccg-nav-border:#202020;
  --ccg-nav-text:#f5f5f5;
  --ccg-nav-muted:#b8b8b8;
  --ccg-nav-hover:#1f1f1f;
  --ccg-nav-active:#242424;
}
[data-theme="light"]{
  --ccg-nav-bg:#fff;
  --ccg-nav-border:#e5e7eb;
  --ccg-nav-text:#111827;
  --ccg-nav-muted:#4b5563;
  --ccg-nav-hover:#f3f4f6;
  --ccg-nav-active:#eef0f4;
}
html body .nav.ccg-global-nav{
  height:56px!important;
  min-height:56px!important;
  background:var(--ccg-nav-bg)!important;
  border-bottom:1px solid var(--ccg-nav-border)!important;
  color:var(--ccg-nav-text)!important;
  display:flex!important;
  align-items:center!important;
  gap:14px!important;
  padding:0 20px!important;
  position:sticky!important;
  top:0!important;
  z-index:1000!important;
  box-shadow:none!important;
  backdrop-filter:none!important;
}
html body .ccg-global-nav .nav-logo{
  display:flex!important;
  align-items:center!important;
  justify-content:flex-start!important;
  gap:10px!important;
  width:132px!important;
  min-width:132px!important;
  max-width:132px!important;
  height:40px!important;
  padding:0 10px!important;
  border-radius:10px!important;
  background:transparent!important;
  border:0!important;
  color:var(--ccg-nav-text)!important;
  text-decoration:none!important;
  font-size:16px!important;
  line-height:1!important;
  font-weight:700!important;
  letter-spacing:0!important;
  margin:0 4px 0 0!important;
  opacity:1!important;
  filter:none!important;
  box-shadow:none!important;
  overflow:hidden!important;
  white-space:nowrap!important;
}
html body .ccg-global-nav .nav-logo:hover{
  background:transparent!important;
  color:var(--ccg-nav-text)!important;
}
html body .ccg-global-nav .nav-logo img{
  width:28px!important;
  height:28px!important;
  min-width:28px!important;
  min-height:28px!important;
  max-width:28px!important;
  max-height:28px!important;
  border-radius:7px!important;
  display:block!important;
  object-fit:cover!important;
  opacity:1!important;
  filter:brightness(1) saturate(1)!important;
  box-shadow:none!important;
  background:transparent!important;
  flex:0 0 28px!important;
  transition:transform .18s cubic-bezier(.2,.8,.2,1),filter .18s ease!important;
}
html body .ccg-global-nav .nav-logo:hover img{
  transform:scale(1.08) rotate(-2deg)!important;
  filter:brightness(1.14) saturate(1.1)!important;
}
html body .ccg-global-nav .nav-logo span{
  display:inline-block!important;
  color:inherit!important;
  font:inherit!important;
  line-height:1!important;
}
html body .ccg-global-nav .nav-right{
  margin-left:auto!important;
  display:flex!important;
  align-items:center!important;
  justify-content:flex-end!important;
  gap:8px!important;
  height:34px!important;
}
html body .ccg-global-nav .nav-btn,
html body .ccg-global-nav .ccg-account-link{
  height:34px!important;
  min-height:34px!important;
  padding:0 12px!important;
  border-radius:999px!important;
  border:1px solid transparent!important;
  background:transparent!important;
  color:var(--ccg-nav-muted)!important;
  box-shadow:none!important;
  font-family:-apple-system,BlinkMacSystemFont,"Segoe UI","PingFang SC","Noto Sans SC","Microsoft YaHei",sans-serif!important;
  font-size:13px!important;
  line-height:1!important;
  font-weight:600!important;
  text-decoration:none!important;
  display:inline-flex!important;
  align-items:center!important;
  justify-content:center!important;
  gap:6px!important;
  cursor:pointer!important;
  white-space:nowrap!important;
}
html body .ccg-global-nav .nav-btn:hover,
html body .ccg-global-nav .nav-btn.nav-btn-active,
html body .ccg-global-nav .ccg-account-link:hover,
html body .ccg-global-nav .ccg-account-link.is-current{
  background:var(--ccg-nav-active)!important;
  border-color:transparent!important;
  color:var(--ccg-nav-text)!important;
  box-shadow:none!important;
}
html body .ccg-global-nav .theme-toggle,
html body .ccg-global-nav .nav-mini{
  width:34px!important;
  min-width:34px!important;
  height:34px!important;
  min-height:34px!important;
  padding:0!important;
  border-radius:999px!important;
  border:1px solid transparent!important;
  background:transparent!important;
  color:var(--ccg-nav-muted)!important;
  box-shadow:none!important;
  display:inline-grid!important;
  place-items:center!important;
  cursor:pointer!important;
}
html body .ccg-global-nav .theme-toggle:hover,
html body .ccg-global-nav .nav-mini:hover{
  background:var(--ccg-nav-hover)!important;
  color:var(--ccg-nav-text)!important;
}
html body .ccg-global-nav .theme-toggle svg{
  width:16px!important;
  height:16px!important;
  stroke:currentColor!important;
  stroke-width:2!important;
  fill:none!important;
  stroke-linecap:round!important;
  stroke-linejoin:round!important;
  pointer-events:none!important;
}
html body .ccg-global-nav .ccg-avatar{
  width:26px!important;
  height:26px!important;
  min-width:26px!important;
  border-radius:999px!important;
  display:grid!important;
  place-items:center!important;
  background:linear-gradient(135deg,#7c3aed,#8b5cf6)!important;
  color:#fff!important;
  font-size:12px!important;
  font-weight:900!important;
  box-shadow:none!important;
}
html body .ccg-global-nav .nav-sub,
html body .ccg-global-nav .lang-toggle{
  display:none!important;
}

/* Unified CCG form selects.
   Native select popups remain browser-controlled, but the closed field must match the paint UI. */
:root,
[data-theme="dark"]{
  --ccg-select-bg:var(--panel2, var(--surface2, #202020));
  --ccg-select-border:var(--line, var(--border, #2c2c2c));
  --ccg-select-text:var(--text, #f5f5f5);
  --ccg-select-muted:var(--muted, var(--text-muted, #b8b8b8));
  --ccg-select-focus:rgba(124,58,237,.68);
  --ccg-select-ring:rgba(124,58,237,.16);
  --ccg-select-option-bg:var(--panel, var(--surface, #161616));
}
[data-theme="light"]{
  --ccg-select-bg:#ffffff;
  --ccg-select-border:#e5e7eb;
  --ccg-select-text:#111827;
  --ccg-select-muted:#4b5563;
  --ccg-select-focus:rgba(124,58,237,.58);
  --ccg-select-ring:rgba(124,58,237,.12);
  --ccg-select-option-bg:#ffffff;
}
html body select,
html body .select,
html body .ps-select,
html body .model-sel,
html body .toolbar-select,
html body .custom-select{
  height:40px!important;
  min-height:40px!important;
  max-height:40px!important;
  box-sizing:border-box!important;
  border:1px solid var(--ccg-select-border)!important;
  border-radius:12px!important;
  background-color:var(--ccg-select-bg)!important;
  color:var(--ccg-select-text)!important;
  box-shadow:none!important;
  font-family:-apple-system,BlinkMacSystemFont,"Segoe UI","PingFang SC","Noto Sans SC","Microsoft YaHei",sans-serif!important;
  font-size:13px!important;
  font-weight:700!important;
  line-height:1.2!important;
  letter-spacing:0!important;
  outline:none!important;
}
html body select{
  appearance:none!important;
  -webkit-appearance:none!important;
  padding:0 36px 0 12px!important;
  cursor:pointer!important;
  background-image:
    linear-gradient(45deg,transparent 50%,currentColor 50%),
    linear-gradient(135deg,currentColor 50%,transparent 50%)!important;
  background-position:
    calc(100% - 18px) 50%,
    calc(100% - 13px) 50%!important;
  background-size:5px 5px,5px 5px!important;
  background-repeat:no-repeat!important;
}
html body select::-ms-expand{
  display:none!important;
}
html body select:hover,
html body .select:hover,
html body .ps-select:hover,
html body .model-sel:hover,
html body .toolbar-select:hover,
html body .custom-select:hover{
  border-color:var(--ccg-select-focus)!important;
}
html body select:focus,
html body .select:focus,
html body .ps-select:focus,
html body .model-sel:focus,
html body .toolbar-select:focus,
html body .custom-select:focus{
  border-color:var(--ccg-select-focus)!important;
  box-shadow:0 0 0 3px var(--ccg-select-ring)!important;
}
html body select option{
  background:var(--ccg-select-option-bg)!important;
  color:var(--ccg-select-text)!important;
  font-family:-apple-system,BlinkMacSystemFont,"Segoe UI","PingFang SC","Noto Sans SC","Microsoft YaHei",sans-serif!important;
  font-size:13px!important;
}
@media(max-width:900px){
  html body .nav.ccg-global-nav{padding:0 12px!important;gap:8px!important}
  html body .ccg-global-nav .nav-logo{width:auto!important;min-width:0!important;max-width:none!important;padding:0!important}
  html body .ccg-global-nav .nav-btn:not(.nav-btn-active){display:none!important}
  html body .ccg-global-nav .nav-right{gap:6px!important}
  html body .ccg-global-nav .ccg-account-link span:last-child{max-width:92px;overflow:hidden;text-overflow:ellipsis}
}
