/* Only the right-hand toolbar. Studio columns, branding and forms are untouched. */
.topbar .studio-toolbar { display: flex; align-items: center; gap: 20px; width: auto; min-width: 0; }
.header-credit-pill { display: inline-flex; align-items: center; flex-shrink: 0; gap: 9px; padding: 5px; border-radius: 15px; background: #f6f0ff; }
.studio-toolbar .wallet-badge { display: inline-flex; align-items: center; justify-content: center; gap: 8px; padding: 6px 7px; border: 0; border-radius: 10px; background: transparent; color: #352747; font-size: 13px; font-weight: 600; cursor: pointer; white-space: nowrap; }
.studio-toolbar .wallet-badge:hover { background: #ede2fb; }
.header-coins { display: block; width: 24px; height: 24px; flex-shrink: 0; }
.header-credit-divider { width: 1px; height: 23px; background: #deceef; }
.header-topup { display: inline-flex; align-items: center; justify-content: center; padding: 8px 19px; min-height: 35px; border-radius: 10px; background: linear-gradient(130deg,#a02bef,#6925dd); color: #fff; box-shadow: inset 0 1px 1px #ffffff5c; font-size: 13px; font-weight: 550; white-space: nowrap; }
.header-topup:hover { background: linear-gradient(130deg,#9230da,#5a20c5); color: #fff; }
.header-language { display: flex; align-items: center; position: relative; gap: 7px; color: #514269; flex-shrink: 0; }
.header-language > svg:first-child { width: 22px; height: 22px; flex-shrink: 0; }
.topbar .header-language .language-select { appearance: none; -webkit-appearance: none; border: 0; border-radius: 6px; background: transparent; color: #352747; font-size: 13px; font-weight: 550; max-width: none; width: 74px; padding: 9px 18px 9px 0; cursor: pointer; }
.header-language > .header-chevron { position: absolute; right: 0; pointer-events: none; }
.header-chevron { width: 14px; height: 14px; flex-shrink: 0; }
.header-section-divider { display: block; flex-shrink: 0; width: 1px; height: 28px; background: #e1d6ed; }
.header-account { position: relative; flex-shrink: 0; }
.header-avatar-button { display: flex; align-items: center; gap: 10px; padding: 0; border: 0; border-radius: 25px; background: transparent; color: #352747; cursor: pointer; }
.header-avatar { display: flex; align-items: center; justify-content: center; width: 42px; height: 42px; border-radius: 50%; background: linear-gradient(140deg,#f4edff,#ece8ff); }
.header-avatar svg { width: 34px; height: 34px; }
.header-avatar-button[aria-expanded="true"] > .header-chevron { transform: rotate(180deg); }
.account-menu-panel { position: absolute; z-index: 80; top: calc(100% + 14px); right: 0; width: 236px; max-width: calc(100vw - 32px); padding: 9px; border: 1px solid #e7dcef; border-radius: 14px; background: #fff; box-shadow: 0 12px 40px #50346d1f; }
.account-menu-panel[hidden] { display: none; }
.header-account-summary { padding: 10px 11px 12px; margin-bottom: 5px; border-bottom: 1px solid #f0e8f7; overflow-wrap: anywhere; }
.header-account-summary strong { display: block; color: #4d365d; font-size: 13px; font-weight: 600; }
.header-account-summary small { display: block; margin-top: 5px; color: #9985a7; font-size: 11px; }
.account-menu-panel .header-menu-item { display: block; width: 100%; padding: 11px; border: 0; border-radius: 8px; text-align: left; background: transparent; color: #604673; font-size: 13px; cursor: pointer; }
.account-menu-panel .header-menu-item:hover, .account-menu-panel .header-menu-item:focus-visible { background: #f6f0ff; color: #7735b8; }
.account-menu-panel .header-menu-logout { color: #a26881; }
.account-menu-panel .provider-badge { display: flex; align-items: center; gap: 6px; margin: 8px 0 0; padding: 11px; border-top: 1px solid #f0e8f7; font-size: 10px; color: #9580a2; }
.studio-toolbar button:focus-visible, .studio-toolbar a:focus-visible, .studio-toolbar select:focus-visible { outline: 2px solid #a165e2; outline-offset: 3px; }
@media (max-width: 1000px) { .topbar .studio-toolbar { gap: 14px; } }
@media (max-width: 650px) {
  .topbar { min-height: 73px; }
  .topbar .studio-toolbar { width: 100%; justify-content: space-between; gap: 9px; flex-wrap: wrap; }
  .studio-toolbar .wallet-badge { font-size: 12px; padding: 6px; gap: 5px; }
  .header-credit-pill { gap: 6px; padding: 4px; border-radius: 12px; }
  .header-coins { width: 21px; height: 21px; }
  .header-topup { padding: 8px 12px; min-height: 34px; font-size: 12px; border-radius: 9px; }
  .header-avatar { width: 36px; height: 36px; }
  .header-avatar svg { width: 30px; height: 30px; }
  .header-avatar-button { gap: 5px; }
  .header-language { gap: 5px; }
  .header-language > svg:first-child { width: 19px; height: 19px; }
  .topbar .header-language .language-select { font-size: 12px; width: 68px; padding-right: 15px; }
  .header-section-divider { display: none; }
  .header-chevron { width: 12px; height: 12px; }
}
@media (max-width: 380px) {
  .topbar .studio-toolbar { gap: 7px; }
  .studio-toolbar .wallet-badge { font-size: 11px; gap: 4px; padding: 5px 4px; }
  .header-coins { width: 18px; height: 18px; }
  .header-credit-pill { gap: 4px; padding: 3px; }
  .header-topup { font-size: 11px; padding: 8px 9px; }
  .header-language > svg:first-child { display: none; }
  .topbar .header-language .language-select { width: 55px; font-size: 11px; }
  .header-avatar { width: 32px; height: 32px; }
  .header-avatar svg { width: 26px; height: 26px; }
  .header-chevron { width: 10px; height: 10px; }
}
