
.topbar{margin-left:51px;height:64px;padding:0 24px;display:flex;align-items:center;gap:16px;background:#121212}
.hamburger-btn{display:none}
.topbar .search{display:flex;align-items:center;flex:1;max-width:356px;min-width:0;height:40px;padding:0 12px;gap:8px;background:#ffffff05;border:1px solid #ffffff14;border-radius:6px}
.search-symbol{width:18px;height:18px;flex:none;color:#aaa}
.topbar .search input{width:100%;min-width:0;background:none;border:0;color:var(--text);font-size:14px;outline:none}
.topbar .search kbd{color:#777;background:#ffffff06;border-radius:4px;padding:2px 5px}
.topbar .top-actions{display:flex;align-items:center;margin-left:auto;gap:20px}
.connect-btn{margin-left:auto;padding:8px 16px;border-radius:8px;background:#fff;color:#111;font-size:14px;font-weight:600}
.topbar:has(.account-profile) .connect-btn{display:none}
.guest-topbar .top-actions:empty{display:none}
@media(max-width:640px){.topbar{margin-left:44px;padding:0 12px;gap:8px}.topbar .top-actions{gap:8px}.topbar .account-action,.topbar .account-balance{display:none}.connect-btn{padding:8px}}

.top-actions .account-action{display:inline-flex;align-items:center;justify-content:center;width:24px;height:32px;padding:0;background:transparent;color:#ccc;border:0}
.top-actions .portfolio-trigger{display:inline-flex;align-items:center;gap:4px;height:32px;white-space:nowrap;padding:0;background:transparent;border:0;color:inherit}
.portfolio-trigger>svg{width:20px;height:20px;flex:none;color:#ccc}
.portfolio-trigger .account-balance{line-height:20px;font-variant-numeric:tabular-nums}
.account-action svg{width:20px;height:20px}.account-action svg:not([fill]){fill:none;stroke:currentColor;stroke-width:1.7}
.account-profile{display:flex;align-items:center;gap:8px;border-left:1px solid #303030;padding-left:16px}.account-profile>svg{width:16px;height:16px;fill:none;stroke:currentColor;stroke-width:1.5}
.account-avatar-wrap{display:flex}.account-avatar-wrap img{width:28px;height:28px;border-radius:50%}.account-balance{font:12px 'America Mono',monospace}
.sidebar-drawer .settings-toggle{background:transparent;border:0}
/* Mobile chrome follows the compact discovery reference. Keep the desktop rail intact. */
.mobile-header-brand{display:none}
@media(max-width:640px){
 body[data-home-transfer="true"]{--bg:#101010;background:var(--bg)}
 body[data-home-transfer="true"] #app{margin-left:0;padding:16px 14px 40px;min-width:0;width:100%;box-sizing:border-box}
 body[data-home-transfer="true"] .topbar{position:relative;margin-left:0;width:100%;box-sizing:border-box;height:63px;padding:0 14px;gap:8px;background:var(--bg,#101010);border-bottom:1px solid #ffffff10}
 .topbar .hamburger-btn{display:inline-flex;align-items:center;justify-content:center;flex:0 0 24px;width:24px;height:36px;padding:0;background:transparent;border:0;color:var(--text,#fff)}
 .topbar .mobile-header-brand{display:flex;align-items:center;gap:8px;flex:none;color:var(--text,#fff);text-decoration:none}
 .mobile-header-brand .brand-icon{display:block;width:30px;height:30px}
 .mobile-header-brand .brand-wordmark{display:block;width:80px;height:24px}
 .topbar .search{flex:0 0 28px;position:relative;margin-left:auto;width:28px;height:36px;max-width:none;padding:0;justify-content:center;background:none;border:0;border-radius:6px}
 .topbar .search-symbol{width:22px;height:22px;color:var(--text,#fff)}
 .topbar .search input{position:absolute;inset:0;width:100%;height:100%;opacity:0;cursor:pointer}
 .topbar .search:focus-within{position:absolute;z-index:5;left:46px;right:14px;width:auto;height:40px;padding:0 12px;justify-content:flex-start;background:var(--panel,#1a1a1a);border:1px solid #ffffff40}
 .topbar .search:focus-within input{position:static;opacity:1;cursor:text;flex:1;width:0;font-size:14px}
 .topbar .search kbd{display:none}
 .topbar .top-actions{margin-left:0;gap:12px;flex:none}
 .topbar .top-actions .account-action{display:inline-flex;width:24px;height:36px}
 .topbar .account-balance,.topbar .account-divider,.topbar .account-profile>svg{display:none}
 .topbar .portfolio-trigger{width:24px;height:36px;justify-content:center}
 .topbar .account-profile{padding-left:0;border:0}
 .topbar .account-avatar-wrap img{width:24px;height:24px}
 .topbar .connect-btn{margin-left:0;padding:7px 10px;white-space:nowrap;font-size:12px}
 body[data-home-transfer="true"] .sidebar-drawer:not(.open){display:none}
 body[data-home-transfer="true"] .sidebar-drawer.open{display:flex;width:min(280px,calc(100vw - 48px));padding:14px;align-items:stretch;bottom:0;overflow-y:auto;z-index:130}
 body[data-home-transfer="true"] .sidebar-drawer.open .brand{width:100%;justify-content:flex-start;gap:8px}
 body[data-home-transfer="true"] .sidebar-drawer.open .brand-wordmark{display:block;width:98px;height:24px}
 body[data-home-transfer="true"] .sidebar-drawer.open nav{width:100%;gap:8px}
 body[data-home-transfer="true"] .sidebar-drawer.open .nav-item{width:100%;justify-content:flex-start;gap:12px;padding:8px;height:40px}
 body[data-home-transfer="true"] .sidebar-drawer.open .tooltip{position:static;display:block;transform:none;visibility:visible;opacity:1;background:none;border:0;padding:0;font-size:14px}
 body[data-home-transfer="true"] .drawer-overlay.open{display:block!important;position:fixed;inset:0;z-index:120;background:#0009}
 body[data-home-transfer="true"] .statusbar{display:none}
 .topbar :is(button,a,input):focus-visible{outline:2px solid #58afff;outline-offset:2px}
}
@media(max-width:374px){.topbar .top-actions{gap:8px}.topbar .mobile-header-brand{gap:6px}.mobile-header-brand .brand-wordmark{width:72px}.topbar .top-actions .account-action,.topbar .portfolio-trigger{width:22px}}
@media(max-width:640px){
 body[data-home-transfer="true"]:has(.reference-layout) .topbar{height:63px!important;min-height:63px;margin-left:0;padding:0 14px;gap:8px}
 body[data-home-transfer="true"] .topbar .hamburger-btn{display:inline-flex}
 body[data-home-transfer="true"]:has(.reference-layout) .topbar .search{max-width:none;height:36px}
 body[data-home-transfer="true"]:has(.reference-layout) .topbar .search:focus-within{height:40px}
 body[data-home-transfer="true"]:has(.reference-layout) .topbar :is(.portfolio-trigger,.account-action){display:inline-flex}
}
/* Home supplies its own logo, search and account controls to the shared navigation. */
@media(max-width:640px){
 body[data-home-transfer="true"] .topbar.market-mobile-header{height:63px!important;min-height:63px;padding:0 14px!important;overflow:visible;z-index:110!important}
 body[data-home-transfer="true"] .topbar.market-mobile-header>.market-mobile-brand,
 body[data-home-transfer="true"] .topbar.market-mobile-header>#hamburger,
 body[data-home-transfer="true"] .topbar.market-mobile-header>[data-market-navigation-search],
 body[data-home-transfer="true"] .topbar.market-mobile-header>button.market-mobile-account:not(#connect-wallet){display:none!important}
 body[data-home-transfer="true"] .topbar.market-mobile-header>[data-market-navigation-trigger]{display:inline-flex!important;align-items:center;justify-content:center;flex:0 0 24px;width:24px;height:36px;background:transparent;border:0;padding:0;color:inherit}
 body[data-home-transfer="true"] .topbar.market-mobile-header>.mobile-header-brand{display:flex!important}
 body[data-home-transfer="true"] .topbar.market-mobile-header>.search{display:flex!important}
 body[data-home-transfer="true"] .topbar.market-mobile-header>.top-actions:not(:empty){display:flex!important}
 body[data-home-transfer="true"] .topbar.market-mobile-header>#connect-wallet:not([hidden]){display:block!important;width:auto!important;max-width:110px;min-height:32px;padding:7px 12px!important;border-radius:6px!important;background:#fff!important;color:#111!important;font-size:13px!important;line-height:18px;overflow:visible}
 body[data-home-transfer="true"] .topbar.market-mobile-header [data-market-navigation-account-path]>*{display:initial!important}
 body[data-home-transfer="true"] .topbar.market-mobile-header .top-actions :is(.account-action,.portfolio-trigger){display:inline-flex!important}
 body[data-home-transfer="true"] .topbar.market-mobile-header .top-actions :is(.account-balance,.account-divider,.account-profile>svg){display:none!important}
}
