
/* Single-page architecture: shared chrome + interchangeable page roots */
.demo-page-root{
  display:contents;
}
.demo-page-root[hidden],
.section-metrics-bar[hidden],
.kpi-grid[hidden]{
  display:none!important;
}

/* Balance: only in card "Отчет по активам" */
.balance-report-view [data-section="asset-report"] .exchange-card .sbadge{
  font-size:7px;
  padding:2px 6px;
  letter-spacing:.03em;
}

.balance-exchange-name{
  display:inline-flex;
  align-items:center;
  gap:8px;
}

.balance-exchange-logo{
  width:16px;
  height:16px;
  border-radius:4px;
  object-fit:contain;
  background:transparent;
  flex-shrink:0;
}

/* Subscription scanner-style redesign */
.subx-grid{
  gap:16px;
}

.subx-info-card{
  position:relative;
  overflow:hidden;
  background:linear-gradient(145deg,color-mix(in srgb,var(--panel-high) 82%,#0b1120 18%) 0%,color-mix(in srgb,var(--panel-sunken) 86%,#070b14 14%) 100%);
  border:1px solid color-mix(in srgb,var(--brand) 22%,var(--line));
  box-shadow:0 18px 42px -24px rgba(0,0,0,.6),0 0 0 1px rgba(124,140,255,.09) inset;
}

.subx-hero-glow{
  position:absolute;
  top:-74px;
  right:-86px;
  width:240px;
  height:240px;
  border-radius:50%;
  background:radial-gradient(circle,rgba(124,140,255,.24) 0%,rgba(124,140,255,0) 72%);
  pointer-events:none;
}

.subx-info-top{
  position:relative;
  z-index:1;
  display:flex;
  align-items:flex-start;
  justify-content:space-between;
  gap:16px;
  margin-bottom:14px;
  flex-wrap:wrap;
}

.subx-kicker{
  display:inline-flex;
  align-items:center;
  gap:6px;
  font-size:9px;
  font-weight:900;
  letter-spacing:.12em;
  color:var(--fg-mute);
  margin-bottom:6px;
}

.subx-title-row{
  display:flex;
  align-items:center;
  gap:10px;
  flex-wrap:wrap;
}

.subx-title{
  margin:0;
  font-size:28px;
  line-height:1;
  letter-spacing:-.03em;
  font-weight:900;
  color:var(--fg);
}

.subx-desc{
  margin:8px 0 0;
  max-width:640px;
  font-size:12px;
  color:var(--fg-dim);
  line-height:1.5;
}

.subx-info-right{
  display:flex;
  flex-direction:column;
  align-items:flex-end;
  gap:10px;
}

.subx-price{
  font-size:26px;
  font-weight:800;
  letter-spacing:-.03em;
  color:var(--fg);
}

.subx-price span{
  font-size:11px;
  color:var(--fg-mute);
  font-weight:700;
  letter-spacing:.06em;
}

.subx-stats{
  position:relative;
  z-index:1;
  display:grid;
  grid-template-columns:repeat(4,minmax(0,1fr));
  gap:10px;
}

.subx-progress-wrap{
  position:relative;
  z-index:1;
  margin:14px 0 14px;
}

.subx-progress-head{
  display:flex;
  align-items:center;
  justify-content:space-between;
  margin-bottom:0;
  font-size:10px;
  font-weight:900;
  letter-spacing:.08em;
  color:var(--fg-mute);
  text-transform:uppercase;
}

.subx-info-grid{
  position:relative;
  z-index:1;
  display:grid;
  grid-template-columns:repeat(4,minmax(0,1fr));
  gap:10px;
}

.subx-info-item{
  border:1px solid var(--line);
  border-radius:10px;
  background:color-mix(in srgb,var(--panel-sunken) 100%,#000 3%);
  padding:10px 11px;
}

.subx-info-item span{
  display:block;
  font-size:9px;
  font-weight:900;
  letter-spacing:.1em;
  color:var(--fg-mute);
  margin-bottom:5px;
  text-transform:uppercase;
}

.subx-info-item b{
  font-size:12px;
  font-weight:700;
}


.subx-stat{
  border:1px solid var(--line);
  border-radius:10px;
  background:color-mix(in srgb,var(--panel-sunken) 100%,#000 3%);
  padding:10px 11px;
}

.subx-stat span{
  display:block;
  font-size:9px;
  font-weight:900;
  letter-spacing:.1em;
  color:var(--fg-mute);
  margin-bottom:5px;
}

.subx-stat b{
  font-size:12px;
  font-weight:700;
}

.subx-bars .bar-row b,
.subx-bars .bar-row span{
  font-size:11px;
}

.subx-timeline .timeline-item{
  border:1px solid var(--line);
  border-radius:10px;
  padding:11px 12px;
  background:color-mix(in srgb,var(--panel-sunken) 100%,#000 4%);
}

.sub-history-layout{
  display:grid;
  grid-template-columns:minmax(0,1.1fr) minmax(0,.9fr);
  gap:12px;
}

.sub-history-list{
  display:flex;
  flex-direction:column;
  gap:6px;
}

.sub-history-row{
  position:relative;
  width:100%;
  text-align:left;
  border:1px solid var(--line);
  border-left:3px solid var(--brand);
  background:var(--panel-sunken);
  border-radius:10px;
  padding:10px 12px;
  display:grid;
  grid-template-columns:minmax(0,1fr) auto auto;
  gap:10px;
  align-items:center;
  cursor:pointer;
  transition:background .15s,border-color .15s,transform .15s;
}

.sub-history-row:hover,.sub-history-row.is-active{
  border-color:var(--line-strong);
  border-left-color:var(--up);
  background:color-mix(in srgb,var(--panel-high) 100%,#fff 4%);
}

.sub-history-row:hover{transform:translateX(2px)}

.sub-history-row::after{
  content:'›';
  position:absolute;
  right:8px;
  top:50%;
  transform:translateY(-50%);
  color:var(--fg-mute);
  font-size:18px;
  line-height:1;
  opacity:.7;
}

.sub-history-row-title{font-size:12px;font-weight:700;color:var(--fg)}
.sub-history-row-sub{font-size:10px;color:var(--fg-mute);margin-top:2px}
.sub-history-row-date{font-size:10px;color:var(--fg-mute);text-align:right}
.sub-history-row-amount{font-size:11px;color:var(--fg);font-weight:700;margin-top:2px;text-align:right}

.sub-history-detail{
  border:1px solid var(--line);
  border-radius:10px;
  background:var(--panel-sunken);
  padding:12px;
}

.sub-history-detail-body{
  display:grid;
  grid-template-columns:128px minmax(0,1fr);
  gap:12px;
}

.sub-history-detail-qrcol{
  display:flex;
  flex-direction:column;
  align-items:center;
  gap:8px;
}

.sub-history-detail-main{
  min-width:0;
  display:flex;
  flex-direction:column;
  gap:10px;
}

.sub-history-detail-kicker{font-size:9px;font-weight:900;letter-spacing:.1em;text-transform:uppercase;color:var(--fg-mute);margin-bottom:4px}
.sub-history-detail-title{font-size:14px;font-weight:800;color:var(--fg)}
.sub-history-detail-sub{font-size:10px;color:var(--fg-mute);margin-top:2px}
.sub-history-detail-head{display:flex;justify-content:space-between;gap:10px;align-items:flex-start;margin-bottom:10px}
.sub-history-detail-grid{display:grid;grid-template-columns:1fr 1fr;gap:8px;margin-bottom:10px}
.sub-history-detail-item{border:1px solid var(--line);border-radius:8px;padding:8px;background:var(--panel)}
.sub-history-detail-item span{display:block;font-size:9px;color:var(--fg-mute);text-transform:uppercase;letter-spacing:.08em;margin-bottom:4px}
.sub-history-detail-item b{font-size:11px;color:var(--fg)}
.sub-history-detail-box{display:grid;gap:8px}
.sub-history-detail-note{margin-top:8px;font-size:10.5px;color:var(--fg-dim)}

.sub-history-detail-warning{
  margin-top:10px;
  padding:10px 12px;
}

@media(max-width:900px){
  .subx-title{font-size:24px}
  .subx-price{font-size:22px}
  .subx-info-grid{grid-template-columns:repeat(2,minmax(0,1fr))}
}

@media(max-width:580px){
  .subx-info-top{flex-direction:column;align-items:flex-start}
  .subx-info-right{align-items:flex-start}
  .subx-info-grid{grid-template-columns:1fr}
  .sub-history-layout{grid-template-columns:1fr}
  .sub-history-detail-body{grid-template-columns:1fr}
}

/* Balance page: scanner trade-history style */
body.balance-page-active .content-shell>.section-toolbar{
  display:none!important;
}

body.subscription-page-active .content-shell>.section-toolbar{
  display:none!important;
}

body.api-page-active .content-shell>.section-toolbar{
  display:none!important;
}

.subscription-history-view .balhp-token-symbol{
  white-space:nowrap;
  overflow:hidden;
  text-overflow:ellipsis;
}

.subscription-history-view .subhp-payment-details{
  grid-template-columns:repeat(2,minmax(260px,1fr));
  border-top:1px solid var(--line);
}

.subscription-history-view .subhp-payment-details .balhp-kv-val{
  max-width:100%;
}

@media(max-width:700px){
  .subscription-history-view .subhp-payment-details{grid-template-columns:1fr}
}

.subhp-list-head{
  padding:10px 16px;
  border-bottom:1px solid var(--line-strong);
  background:var(--panel);
  color:var(--fg-mute);
  font-size:9.5px;
  font-weight:800;
  letter-spacing:.1em;
  text-transform:uppercase;
}

.subhp-pending-details{padding:12px 16px;background:var(--panel-sunken);border-top:1px solid var(--line)}
.subhp-pending-title{font-size:9px;letter-spacing:.12em;text-transform:uppercase;font-weight:800;color:var(--fg-faint);margin-bottom:8px}
.subhp-requisites-blocks{border-top:1px solid var(--line)}
.subhp-qr-block{display:flex;flex-direction:column;align-items:center;gap:8px}
.subhp-qr-wrap{width:112px;height:112px;background:#fff;padding:7px;border-radius:10px;border:1px solid var(--line);overflow:hidden}
.subhp-qr-wrap canvas{width:100%;height:100%}
.subhp-qr-caption{font-size:9px;font-weight:800;text-transform:uppercase;letter-spacing:.08em;color:var(--fg-mute);text-align:center}
.subhp-app-btn{width:100%;max-width:140px;padding:7px 0;border-radius:8px;font-size:10.5px;font-weight:800;border:1px solid var(--line-strong);background:var(--panel-high);color:var(--fg);cursor:pointer;transition:filter .15s;text-align:center;white-space:nowrap}
.subhp-app-btn:hover{filter:brightness(1.08)}
.subhp-warning{margin:0 16px 12px;padding:12px 14px;background:rgba(245,158,11,.06);border:1px solid rgba(245,158,11,.22);border-radius:10px;font-size:11px;color:color-mix(in srgb,#f59e0b 75%,var(--fg));line-height:1.55}
.subhp-warning strong{display:block;font-size:10px;text-transform:uppercase;letter-spacing:.06em;margin-bottom:2px;opacity:.75}
.subhp-pay-actions{display:flex;justify-content:flex-end;padding:0 16px 14px}
.subhp-paid-btn{height:34px;padding:0 16px;border-radius:9px;background:var(--brand);color:#fff;font-size:11px;font-weight:900;border:1px solid var(--brand-border);cursor:pointer}
.subhp-paid-btn:disabled{opacity:.75;cursor:wait}
.subhp-pending-shell{background:var(--panel-sunken);border-top:1px solid var(--line)}
.subhp-pending-head{display:flex;align-items:center;justify-content:space-between;gap:12px;padding:12px 16px;border-bottom:1px solid var(--line);background:linear-gradient(90deg,color-mix(in srgb,var(--warn) 8%,var(--panel)),var(--panel))}
.subhp-pending-kicker{font-size:8.5px;letter-spacing:.12em;text-transform:uppercase;font-weight:900;color:var(--fg-mute);margin-bottom:3px}
.subhp-pending-title-main{font-size:13px;font-weight:900;color:var(--fg);letter-spacing:-.01em}
.subhp-pending-grid{display:grid;grid-template-columns:160px minmax(0,1fr) minmax(240px,.75fr);gap:1px;background:var(--panel-edge);border-bottom:1px solid var(--line)}
.subhp-pending-qr-panel{background:var(--panel-sunken);padding:12px;display:flex;flex-direction:column;align-items:center;gap:8px}
.subhp-pending-main-card,.subhp-pending-status-card{border-radius:0;border:0}
.subhp-pending-bottom{display:grid;grid-template-columns:minmax(0,1fr) auto;gap:12px;align-items:center;padding:12px 16px;background:var(--panel)}
.subhp-pending-bottom .subhp-warning{margin:0;width:fit-content;max-width:min(680px,100%);justify-self:start}
.subhp-pending-bottom .subhp-paid-btn{height:38px;min-width:136px;box-shadow:0 8px 20px -10px var(--brand)}
.apihp-warning{margin:12px 16px;padding:12px 14px;width:fit-content;max-width:min(720px,calc(100% - 32px));background:rgba(245,158,11,.06);border:1px solid rgba(245,158,11,.22);border-radius:10px;font-size:11px;color:color-mix(in srgb,#f59e0b 75%,var(--fg));line-height:1.55}
.apihp-warning strong{font-weight:900;text-transform:uppercase;letter-spacing:.04em}
.api-modal-overlay{position:fixed;inset:0;z-index:600;display:grid;place-items:center;padding:16px;background:rgba(0,0,0,.68);backdrop-filter:blur(5px);opacity:0;pointer-events:none;transition:opacity .2s}
.api-modal-overlay.open{opacity:1;pointer-events:all}
.api-key-modal{width:min(540px,100%);max-height:92dvh;overflow:hidden;display:flex;flex-direction:column;background:var(--panel);border:1px solid var(--line);border-radius:18px;box-shadow:0 34px 80px rgba(0,0,0,.55);transform:translateY(8px) scale(.98);transition:transform .24s cubic-bezier(.22,1,.36,1)}
.api-modal-overlay.open .api-key-modal{transform:translateY(0) scale(1)}
.api-key-modal-head{display:flex;align-items:flex-start;justify-content:space-between;gap:12px;padding:16px 18px;border-bottom:1px solid var(--line);background:linear-gradient(90deg,color-mix(in srgb,var(--brand) 8%,var(--panel)),var(--panel))}
.api-key-modal-title{font-size:15px;font-weight:900;letter-spacing:-.02em;color:var(--fg)}
.api-key-modal-sub{font-size:11px;color:var(--fg-mute);margin-top:3px;line-height:1.4}
.api-key-close{width:30px;height:30px;border-radius:8px;border:1px solid var(--line);background:var(--panel-high);color:var(--fg-mute);font-size:18px;line-height:1;cursor:pointer}
.api-key-close:hover{color:var(--fg);border-color:var(--line-strong)}
.api-key-tabs{display:flex;gap:6px;padding:10px 18px;border-bottom:1px solid var(--line);background:var(--panel)}
.api-key-tab{height:30px;padding:0 12px;border-radius:8px;border:1px solid transparent;background:transparent;color:var(--fg-mute);font-size:11px;font-weight:900;cursor:pointer}
.api-key-tab.active{background:var(--panel-high);border-color:var(--line);color:var(--fg)}
.api-key-modal-body{padding:16px 18px;display:grid;gap:12px;overflow-y:auto}
.api-tab-panel{display:none;gap:12px}
.api-tab-panel.active{display:grid}
.api-create-shell{display:grid;gap:12px}
.api-key-create-box,.api-create-shell{padding:12px;border:1px solid var(--line);border-radius:12px;background:linear-gradient(135deg,color-mix(in srgb,var(--brand) 8%,var(--panel-sunken)),var(--panel-sunken))}
.api-key-create-head{display:flex;align-items:flex-start;justify-content:space-between;gap:12px;margin-bottom:10px}
.api-key-create-head b{display:block;font-size:12px;font-weight:900;color:var(--fg)}
.api-key-create-head span{display:block;font-size:10.5px;color:var(--fg-mute);margin-top:2px;line-height:1.35}
#api-key-return-hint{font-family:'JetBrains Mono',monospace;font-size:9.5px!important;font-weight:800;color:var(--brand)!important;text-align:right;max-width:180px;margin-top:0!important}
.api-key-exchange-grid{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:6px}
.api-key-exchange-grid button{height:30px;border-radius:8px;border:1px solid var(--line);background:var(--panel-high);color:var(--fg-dim);font-size:11px;font-weight:900;cursor:pointer}
.api-key-exchange-grid button:hover,.api-key-exchange-grid button.active{color:var(--fg);border-color:var(--brand-border);background:var(--brand-soft)}
.api-instruction-card{display:grid;gap:12px;padding:12px;border-radius:10px;border:1px solid var(--line);background:var(--panel)}
.api-instruction-title{font-size:12px;font-weight:900;color:var(--fg);letter-spacing:-.01em}
.api-instruction-steps{display:grid;gap:7px}
.api-instruction-steps div{display:grid;grid-template-columns:22px minmax(0,1fr);gap:8px;align-items:start}
.api-instruction-steps span{width:22px;height:22px;border-radius:7px;display:grid;place-items:center;background:var(--brand-soft);border:1px solid var(--brand-border);color:var(--brand);font-size:9px;font-weight:900}
.api-instruction-steps p{margin:0;padding-top:3px;font-size:11px;color:var(--fg-dim);line-height:1.35}
.api-instruction-reqs{display:grid;gap:1px;background:var(--panel-edge);border:1px solid var(--line);border-radius:9px;overflow:hidden}
.api-instruction-reqs div{display:flex;justify-content:space-between;gap:12px;padding:8px 10px;background:var(--panel-sunken);font-size:11px}
.api-instruction-reqs b{color:var(--fg-mute);font-size:9px;text-transform:uppercase;letter-spacing:.08em}
.api-instruction-reqs span{text-align:right;color:var(--fg);font-weight:800}
.api-open-exchange-btn{height:34px;border-radius:9px;border:1px solid var(--brand-border);background:var(--brand-soft);color:var(--brand);font-size:11px;font-weight:900;cursor:pointer}
.api-open-exchange-btn:hover{filter:brightness(1.1)}
.api-key-field{display:grid;gap:6px}
.api-key-field span{font-size:9px;font-weight:900;text-transform:uppercase;letter-spacing:.09em;color:var(--fg-mute)}
.api-key-field input,.api-key-field select{width:100%;height:38px;border-radius:9px;border:1px solid var(--line);background:var(--panel-sunken);color:var(--fg);padding:0 11px;font-size:12px;font-weight:700;outline:none}
.api-key-field input:focus,.api-key-field select:focus{border-color:var(--brand-border);box-shadow:0 0 0 3px color-mix(in srgb,var(--brand) 12%,transparent)}

/* Account profile: compact edit surface */
.profile-page-grid{
  gap:12px;
}

.profile-card{
  padding:16px;
}

.profile-main-layout{
  display:grid;
  grid-template-columns:minmax(220px,300px) minmax(320px,680px);
  justify-content:space-between;
  gap:clamp(18px,4vw,54px);
  align-items:start;
}

.profile-avatar-pane,
.profile-form-pane{
  min-width:0;
}

.profile-avatar-pane{
  max-width:300px;
  display:grid;
  gap:14px;
}

.profile-avatar-head,
.profile-form-head{
  margin:0;
}

.profile-avatar-zone{
  width:fit-content;
  display:grid;
  grid-template-columns:112px auto;
  gap:12px;
  align-items:center;
}

.profile-avatar-preview{
  width:112px;
  aspect-ratio:1;
  border-radius:50%;
  overflow:hidden;
  border:1px solid var(--line-strong);
  background:linear-gradient(145deg,var(--panel-sunken),var(--panel));
  display:grid;
  place-items:center;
  box-shadow:0 14px 30px -22px rgba(0,0,0,.6);
}

.profile-avatar-preview img{
  width:100%;
  height:100%;
  object-fit:cover;
  display:block;
}

.profile-avatar-preview span{
  font-size:30px;
  font-weight:900;
  color:var(--brand);
  letter-spacing:-.03em;
}

.profile-avatar-actions{
  display:flex;
  flex-direction:column;
  gap:8px;
}

.profile-icon-btn{
  width:36px;
  height:36px;
  border-radius:10px;
  display:grid;
  place-items:center;
  border:1px solid var(--line);
  background:var(--panel-high);
  color:var(--fg-dim);
  transition:filter .15s,color .15s,border-color .15s,background .15s;
}

.profile-icon-btn:hover{
  color:var(--brand);
  border-color:var(--brand-border);
  background:var(--brand-soft);
}

.profile-icon-btn.danger:hover{
  color:var(--down);
  border-color:var(--down-border);
  background:var(--down-bg);
}

.profile-icon-btn:disabled{
  cursor:wait;
  opacity:.76;
}

.profile-icon-btn[data-loading="true"] svg{
  animation:profileIconSpin .8s linear infinite;
}

@keyframes profileIconSpin{
  to{transform:rotate(360deg)}
}

.profile-avatar-note,
.profile-save-hint{
  font-size:10.5px;
  line-height:1.45;
  color:var(--fg-mute);
}

.profile-form-pane{
  width:min(100%,680px);
  justify-self:end;
  display:grid;
  gap:14px;
}

.profile-form-grid{
  display:grid;
  gap:10px;
}

.profile-field input{
  height:42px;
}

.profile-meta-grid{
  display:grid;
  grid-template-columns:repeat(3,minmax(0,1fr));
  gap:10px;
}

.profile-meta-grid .balhp-kv{
  min-height:38px;
  padding:9px 10px;
  border:1px solid var(--line);
  border-radius:10px;
  background:var(--panel-sunken);
}

@media(max-width:900px){
  .profile-main-layout{
    grid-template-columns:1fr;
    gap:18px;
  }
  .profile-avatar-pane{
    max-width:none;
  }
  .profile-form-pane{
    width:100%;
    justify-self:stretch;
  }
  .profile-meta-grid{
    grid-template-columns:1fr;
  }
}

@media(max-width:520px){
  .profile-card{
    padding:12px;
  }
  .profile-avatar-zone{
    width:100%;
    grid-template-columns:96px 1fr;
  }
  .profile-avatar-preview{
    width:96px;
  }
  .profile-avatar-actions{
    flex-direction:row;
  }
  .profile-icon-btn{
    width:38px;
    height:38px;
  }
  .profile-form-head{
    align-items:flex-start;
    flex-direction:column;
  }
}
.api-key-rights{display:grid;gap:8px;padding:12px;border:1px solid var(--line);border-radius:10px;background:var(--panel-sunken)}
.api-key-rights label{display:flex;align-items:center;gap:8px;font-size:12px;font-weight:800;color:var(--fg-dim)}
.api-key-rights input{accent-color:var(--brand)}
.api-key-rights span{margin-left:auto;color:var(--down);font-size:10px;font-weight:900}
.api-key-rights-static div{display:flex;align-items:center;justify-content:space-between;gap:12px;padding:6px 0;border-bottom:1px dashed color-mix(in srgb,var(--line) 60%,transparent);font-size:11.5px}
.api-key-rights-static div:last-child{border-bottom:0}
.api-key-rights-static b{font-size:11px;color:var(--fg);font-weight:900}
.api-key-rights-static span{margin-left:0;color:var(--fg-mute);font-size:10.5px;font-weight:700;text-align:right}
.api-key-note{padding:11px 12px;border-radius:10px;border:1px solid var(--warn-border);background:var(--warn-bg);color:var(--warn);font-size:11px;line-height:1.45}
.api-key-note strong{font-weight:900;text-transform:uppercase;letter-spacing:.04em}
.api-key-modal-foot{display:flex;justify-content:flex-end;gap:8px;padding:14px 18px;border-top:1px solid var(--line);background:var(--panel-sunken)}
.api-key-secondary,.api-key-primary{height:34px;padding:0 14px;border-radius:9px;font-size:11px;font-weight:900;cursor:pointer;border:1px solid var(--line)}
.api-key-secondary{background:var(--panel-high);color:var(--fg-mute)}
.api-key-primary{background:var(--brand);border-color:var(--brand-border);color:#fff}

/* Account API keys: light management-table treatment inspired by reference mockup */
@media(max-width:640px){
  .subhp-warning{margin-left:12px;margin-right:12px}
  .subhp-pay-actions{padding-left:12px;padding-right:12px}
  .subhp-pending-head{padding:10px 12px;align-items:flex-start;flex-direction:column}
  .subhp-pending-grid{grid-template-columns:1fr}
  .subhp-pending-qr-panel{align-items:flex-start}
  .subhp-pending-bottom{grid-template-columns:1fr;padding:12px}
  .subhp-pending-bottom .subhp-warning{width:100%;max-width:none}
  .subhp-pending-bottom .subhp-paid-btn{width:100%}
  .apihp-warning{width:auto;max-width:none;margin-left:12px;margin-right:12px}
  .api-modal-overlay{align-items:end;padding:0}
  .api-key-modal{border-radius:18px 18px 0 0;border-left:0;border-right:0;border-bottom:0}
  .api-key-modal-foot{flex-direction:column-reverse}
  .api-key-secondary,.api-key-primary{width:100%}
  .api-key-tabs{padding:8px 10px}
  .api-key-tab{flex:1}
  .api-key-create-head{flex-direction:column}
  #api-key-return-hint{text-align:left;max-width:none}
  .api-key-exchange-grid{grid-template-columns:repeat(2,minmax(0,1fr))}
  .api-instruction-reqs div{flex-direction:column;gap:4px}
  .api-instruction-reqs span{text-align:left}
}

.balance-history-view{
  background:var(--panel);
  border-top:1px solid var(--line);
  min-height:0;
}

.balhp-stats-grid{
  display:grid;
  grid-template-columns:repeat(5,minmax(0,1fr));
  background:var(--panel);
  border-bottom:1px solid var(--line);
}

.balhp-stat-cell{
  display:flex;
  flex-direction:column;
  gap:3px;
  padding:10px 14px;
  border-right:1px solid var(--line);
}

.balhp-stat-cell:last-child{border-right:0}
.balhp-stat-cell>div:first-child{font-size:8.5px;letter-spacing:.1em;text-transform:uppercase;font-weight:800;color:var(--fg-mute)}
.balhp-stat-cell>div:last-child{font-size:18px;font-weight:900;color:var(--fg);line-height:1.15}
.balhp-stat-cell .up{color:var(--up)}
.balhp-stat-cell .warn{color:var(--warn)}
.balhp-stat-cell .brd{color:var(--brand)}

.balhp-filters{
  display:flex;
  align-items:center;
  gap:6px;
  padding:8px 16px;
  border-bottom:1px solid var(--line);
  background:var(--panel);
  flex-wrap:wrap;
}

.balhp-filter-tab{
  padding:5px 10px;
  font-size:11.5px;
  font-weight:700;
  color:var(--fg-mute);
  background:none;
  border:1px solid transparent;
  border-radius:7px;
  cursor:pointer;
  transition:all .12s;
}

.balhp-filter-tab[aria-selected="true"]{color:var(--fg);background:var(--panel-high);border-color:var(--line)}
.balhp-filter-tab:hover{color:var(--fg-dim)}
.balhp-filter-sep{width:1px;height:18px;background:var(--line);margin:0 4px}
.balhp-filter-spacer{flex:1}
.balhp-export-btn,
.balhp-side-btn{
  display:inline-flex;
  align-items:center;
  justify-content:center;
  gap:5px;
  font-size:11px;
  font-weight:800;
  color:var(--fg-mute);
  background:var(--panel-high);
  border:1px solid var(--line);
  border-radius:7px;
  padding:6px 10px;
  cursor:pointer;
}
.balhp-export-btn:hover,
.balhp-side-btn:hover{color:var(--fg);border-color:var(--line-strong)}

.balhp-table-head,
.balhp-row{
  display:grid;
  grid-template-columns:14px 130px 170px minmax(120px,1fr) 110px 90px 90px 130px 30px;
  gap:10px;
  align-items:center;
}

.balhp-table-head{
  padding:8px 16px;
  border-bottom:1px solid var(--line-strong);
  background:var(--panel);
  font-size:9.5px;
  letter-spacing:.1em;
  text-transform:uppercase;
  font-weight:800;
  color:var(--fg-mute);
}

.balhp-table-head>div:nth-child(5),
.balhp-table-head>div:nth-child(6),
.balhp-table-head>div:nth-child(7),
.balhp-table-head>div:nth-child(8){text-align:right}

.balhp-scroll{min-height:0;background:var(--bg)}
.balhp-row{
  padding:10px 16px;
  border-bottom:1px solid var(--line);
  background:var(--bg);
  cursor:pointer;
  transition:background .12s;
}
.balhp-row:hover{background:color-mix(in srgb,var(--fg) 3%,transparent)}
.balhp-row[data-open="true"]{background:color-mix(in srgb,var(--brand) 5%,transparent)}
.balhp-row[data-open="true"] .balhp-chev{transform:rotate(180deg)}
.balhp-accent{width:3px;height:22px;border-radius:2px}
.balhp-time{font-size:11.5px;font-weight:700}
.balhp-muted{font-size:10px;color:var(--fg-mute);line-height:1.3}
.balhp-asset-main{min-width:0}
.balhp-logo-wrap .balance-exchange-name{font-size:12px;font-weight:800}
.balhp-logo-wrap .balance-exchange-logo{width:20px;height:20px;border-radius:6px}
.balhp-token-symbol{font-size:12px;font-weight:900;letter-spacing:.02em}
.balhp-route{display:flex;align-items:center;gap:6px;font-size:11.5px;font-weight:800;color:var(--fg-faint)}
.balhp-num{text-align:right;font-size:11.5px;font-weight:800}
.balhp-num.up{color:var(--up)}
.balhp-num.warn{color:var(--warn)}
.balhp-num.brd{color:var(--brand)}
.balhp-status{text-align:right}
.balhp-chev-wrap{display:grid;place-items:center}
.balhp-chev{transition:transform .25s;color:var(--fg-mute)}

.balhp-detail{
  background:var(--panel-sunken);
  border-bottom:1px solid var(--line);
  overflow:hidden;
  max-height:0;
  transition:max-height .35s cubic-bezier(.22,1,.36,1);
}
.balhp-detail[data-open="true"]{max-height:1800px}
.balhp-detail-grid{display:grid;grid-template-columns:minmax(0,1fr) 280px;border-bottom:1px solid var(--line)}
.balhp-trace-step{
  display:grid;
  grid-template-columns:24px minmax(0,1fr) 90px 120px;
  gap:10px;
  align-items:center;
  padding:8px 14px;
  border-bottom:1px solid var(--line);
  font-size:11.5px;
}
.balhp-trace-step:last-child{border-bottom:0}
.balhp-trace-step>div:nth-child(2)>div:first-child{font-weight:800}
.balhp-trace-step>div:nth-child(2)>div:last-child{font-size:10.5px;color:var(--fg-mute);margin-top:1px}
.balhp-trace-step>div:nth-child(3){text-align:right;font-size:11px;font-weight:800}
.balhp-trace-step>div:nth-child(4){text-align:right}
.balhp-trace-icon{width:22px;height:22px;border-radius:6px;display:grid;place-items:center;font-size:9px;font-weight:900}
.balhp-trace-icon.up{background:var(--up-bg);border:1px solid var(--up-border);color:var(--up)}
.balhp-trace-icon.warn{background:var(--warn-bg);border:1px solid var(--warn-border);color:var(--warn)}
.balhp-trace-icon.brd{background:var(--brand-soft);border:1px solid var(--brand-border);color:var(--brand)}
.balhp-side{border-left:1px solid var(--line);padding:12px 14px;display:flex;flex-direction:column;gap:8px}
.balhp-side-btn{width:100%;margin-top:6px;padding:7px 0}
.balhp-blocks{display:grid;grid-template-columns:repeat(auto-fit,minmax(220px,1fr));gap:1px;background:var(--panel-edge);border-bottom:1px solid var(--line)}
.balhp-block{background:var(--panel-sunken);padding:10px 14px 12px}
.balhp-block-title{font-size:9px;letter-spacing:.12em;text-transform:uppercase;font-weight:800;color:var(--fg-faint);margin-bottom:8px}
.balhp-kv{display:flex;justify-content:space-between;align-items:center;gap:10px;padding:4px 0;font-size:11px;border-bottom:1px dashed color-mix(in srgb,var(--line) 50%,transparent)}
.balhp-kv:last-child{border-bottom:0}
.balhp-kv-key{color:var(--fg-mute);font-weight:600;flex-shrink:0}
.balhp-kv-val{color:var(--fg);font-weight:800;text-align:right;min-width:0;display:flex;justify-content:flex-end;gap:8px;align-items:center;word-break:break-word}
.balhp-kv-val.up{color:var(--up)}
.balhp-kv-val.warn{color:var(--warn)}
.balhp-kv-val.brd{color:var(--brand)}

@media(max-width:900px){
  .balhp-stats-grid{grid-template-columns:repeat(3,minmax(0,1fr))}
  .balhp-table-head{display:none}
  .balhp-filters{flex-wrap:nowrap;overflow-x:auto;overflow-y:hidden;padding:6px 12px;scrollbar-width:none}
  .balhp-filters::-webkit-scrollbar{display:none}
  .balhp-filter-tab{flex-shrink:0;padding:4px 9px;font-size:11px}
  .balhp-filter-spacer,.balhp-export-btn{display:none}
  .balhp-row{
    grid-template-columns:4px minmax(0,1fr) auto 28px;
    grid-template-rows:auto auto;
    column-gap:10px;
    row-gap:3px;
    padding:10px 12px;
    align-items:start;
  }
  .balhp-row>div:nth-child(1){grid-column:1;grid-row:1/3;align-self:stretch;height:auto;min-height:38px}
  .balhp-row>div:nth-child(2){grid-column:2;grid-row:2}
  .balhp-row>div:nth-child(3){grid-column:2;grid-row:1}
  .balhp-row>div:nth-child(4){grid-column:3;grid-row:2;text-align:right;justify-content:flex-end;font-size:11px}
  .balhp-row>div:nth-child(5){display:none}
  .balhp-row>div:nth-child(6){grid-column:3;grid-row:1;text-align:right;font-size:12px}
  .balhp-row>div:nth-child(7),.balhp-row>div:nth-child(8){display:none}
  .balhp-row>div:nth-child(9){grid-column:4;grid-row:1/3;align-self:center}
  .balhp-detail-grid{grid-template-columns:1fr}
  .balhp-side{border-left:0;border-top:1px solid var(--line)}
  .balhp-trace-step{grid-template-columns:24px minmax(0,1fr) 90px}
  .balhp-trace-step>div:nth-child(4){display:none}
}

@media(max-width:520px){
  .balhp-stats-grid{grid-template-columns:repeat(2,minmax(0,1fr))}
  .balhp-stat-cell{padding:8px 10px}
  .balhp-stat-cell>div:last-child{font-size:15px}
  .balhp-blocks{grid-template-columns:1fr}
  .balhp-block{padding:8px 10px 10px}
  .balhp-kv{font-size:10.5px}
}

/* Unified dense typography: apply scanner/history text rhythm across app pages */
.terminal-topbar .brand-title,
.sidebar-title,
.metric-strip-heading,
.section-toolbar h2,
.card-title,
.balhp-token-symbol,
.sub-history-row-title,
.settings-block-title,
.api-key-modal-title{
  font-size:12px!important;
  line-height:1.18!important;
  font-weight:900!important;
  letter-spacing:.02em!important;
}

.metric-strip-heading,
.section-toolbar h2,
.card-title,
.sidebar-title,
.api-key-modal-title{
  font-size:13px!important;
  letter-spacing:-.01em!important;
}

.terminal-topbar .topnav-link,
.side-link,
.side-link b,
.mob-acc-head,
.mob-acc-sub,
.action-btn,
.balhp-filter-tab,
.balhp-side-btn,
.balhp-export-btn,
.setting-main b,
.token-row b,
.exchange-card b,
.api-key-tab,
.api-key-field input,
.api-key-field select{
  font-size:11.5px!important;
  line-height:1.2!important;
  font-weight:800!important;
  letter-spacing:0!important;
}

.section-toolbar p,
.card-sub,
.sidebar-sub,
.side-link small,
.hero-email,
.setting-main span,
.muted,
.balhp-muted,
.sub-history-row-sub,
.api-key-modal-sub,
.api-instruction-steps p,
.notification-detail-text p{
  font-size:10.5px!important;
  line-height:1.38!important;
  font-weight:650!important;
  letter-spacing:0!important;
}

.sb-label,
.metric-strip-label,
.kpi-label,
.field-group label,
.api-key-field span,
.balhp-table-head,
.balhp-block-title,
.balhp-stat-cell>div:first-child,
.subhp-list-head,
.subhp-pending-kicker,
.settings-block-title,
.logic-hint p strong{
  font-size:9px!important;
  line-height:1.1!important;
  font-weight:900!important;
  letter-spacing:.1em!important;
  text-transform:uppercase!important;
}

.metric-strip-value,
.terminal-topbar .quick-metric .value,
.balhp-time,
.balhp-num,
.balhp-kv,
.balhp-trace-step,
.sub-history-row-date,
.sub-history-row-amount,
.sbadge,
.notification-count-chip,
.mob-acc-badge,
.side-link em,
.sub-dur-pill,
.subhp-app-btn,
.subhp-paid-btn{
  font-size:10.5px!important;
  line-height:1.2!important;
  font-weight:800!important;
}

.balhp-stat-cell>div:last-child,
.kpi-value,
.subx-price{
  font-size:16px!important;
  line-height:1.1!important;
  font-weight:900!important;
  letter-spacing:-.02em!important;
}

.field,
.select,
.textarea,
.api-key-field input,
.api-key-field select{
  font-size:11.5px!important;
  line-height:1.25!important;
  font-weight:700!important;
}

.balhp-table-head,
.balhp-row{
  font-size:11px!important;
}

@media(max-width:700px){
  .metric-strip-heading,
  .section-toolbar h2,
  .card-title,
  .sidebar-title{font-size:12px!important}
  .balhp-stat-cell>div:last-child,
  .kpi-value{font-size:15px!important}
}

/* Late mobile override: notifications have checkbox/delete columns, unlike generic balhp rows. */
@media(max-width:900px){
  .notification-history-view .balhp-row.notification-history-row{
    grid-template-columns:4px 26px minmax(0,1fr) 28px!important;
    grid-template-rows:auto auto auto!important;
    column-gap:10px!important;
    row-gap:3px!important;
    min-height:auto!important;
    height:auto!important;
    padding:11px 12px!important;
    align-items:start!important;
    overflow:visible!important;
  }
  .notification-history-view .balhp-row.notification-history-row>.balhp-accent{
    grid-column:1!important;
    grid-row:1/4!important;
    align-self:stretch!important;
    height:auto!important;
    min-height:52px!important;
  }
  .notification-history-view .balhp-row.notification-history-row>.notification-select{
    grid-column:2!important;
    grid-row:1/4!important;
    align-self:center!important;
    display:grid!important;
  }
  .notification-history-view .balhp-row.notification-history-row>div:nth-child(3){
    grid-column:3!important;
    grid-row:2!important;
    display:block!important;
    min-width:0!important;
    line-height:1.25!important;
  }
  .notification-history-view .balhp-row.notification-history-row>div:nth-child(4){
    grid-column:3!important;
    grid-row:1!important;
    display:block!important;
    min-width:0!important;
    line-height:1.25!important;
  }
  .notification-history-view .balhp-row.notification-history-row>div:nth-child(4) .balhp-muted{
    grid-column:3!important;
    display:block!important;
    margin-top:3px!important;
    line-height:1.25!important;
  }
  .notification-history-view .balhp-row.notification-history-row>div:nth-child(5){
    grid-column:3!important;
    grid-row:3!important;
    display:block!important;
    min-width:0!important;
    max-width:100%!important;
    overflow:hidden!important;
    text-overflow:ellipsis!important;
    white-space:nowrap!important;
    text-align:left!important;
    color:var(--fg-faint)!important;
    font-size:10px!important;
    line-height:1.2!important;
  }
  .notification-history-view .balhp-row.notification-history-row>div:nth-child(5) span{display:inline!important}
  .notification-history-view .balhp-row.notification-history-row>div:nth-child(6),
  .notification-history-view .balhp-row.notification-history-row>div:nth-child(7),
  .notification-history-view .balhp-row.notification-history-row>div:nth-child(8),
  .notification-history-view .balhp-row.notification-history-row>div:nth-child(9),
  .notification-history-view .balhp-row.notification-history-row>.notification-delete-row{
    display:none!important;
  }
  .notification-history-view .balhp-row.notification-history-row>div:nth-child(11){
    grid-column:4!important;
    grid-row:1/4!important;
    display:grid!important;
    align-self:center!important;
  }
  .notification-history-view .balhp-token-symbol,
  .notification-history-view .balhp-muted{
    min-width:0!important;
    max-width:100%!important;
    overflow:hidden!important;
    text-overflow:ellipsis!important;
    white-space:nowrap!important;
  }
}

@media(max-width:700px){
  .notification-history-view{
    padding-bottom:calc(96px + env(safe-area-inset-bottom,0px))!important;
  }
  .notification-history-view .balhp-scroll{
    padding-bottom:calc(96px + env(safe-area-inset-bottom,0px))!important;
  }
  .notification-history-detail[data-open="true"]{
    max-height:none!important;
    overflow:visible!important;
  }
}

/* Demo header restyle based on assets/src/header_app.jsx */
#unifiedTopbar.header-app-shell.terminal-topbar{
  grid-template-columns:minmax(240px,330px) minmax(0,1fr) auto!important;
  align-items:center!important;
  gap:16px!important;
  min-height:58px!important;
  padding:6px 18px!important;
  background:
    radial-gradient(circle at top right,color-mix(in srgb,var(--brand) 18%,transparent),transparent 34%),
    linear-gradient(180deg,color-mix(in srgb,var(--panel) 92%,transparent),color-mix(in srgb,var(--panel-high) 98%,transparent))!important;
  border-bottom:1px solid color-mix(in srgb,var(--line-strong) 90%,transparent)!important;
  box-shadow:0 18px 44px -30px rgba(0,0,0,.55)!important;
  backdrop-filter:blur(18px)!important;
}

:root[data-theme="light"] #unifiedTopbar.header-app-shell.terminal-topbar{
  background:
    radial-gradient(circle at top right,rgba(79,70,229,.10),transparent 34%),
    linear-gradient(180deg,rgba(255,255,255,.94),rgba(247,248,251,.96))!important;
}

#unifiedTopbar.header-app-shell .topbar-left,
#unifiedTopbar.header-app-shell .brand,
#unifiedTopbar.header-app-shell .topbar-right{
  display:flex!important;
  align-items:center!important;
  align-self:center!important;
  gap:10px!important;
  min-width:0!important;
}

#unifiedTopbar.header-app-shell .brand{gap:12px!important}

#unifiedTopbar.header-app-shell .brand-logo{
  width:38px!important;
  height:38px!important;
  border-radius:13px!important;
  background:linear-gradient(135deg,var(--brand),color-mix(in srgb,var(--brand) 52%,#7c3aed))!important;
  box-shadow:0 16px 34px -18px color-mix(in srgb,var(--brand) 62%,transparent)!important;
  color:#fff!important;
  font-size:0!important;
}

#unifiedTopbar.header-app-shell .brand-logo svg{display:block;width:15px;height:15px}
#unifiedTopbar.header-app-shell .brand-copy{min-width:0}

#unifiedTopbar.header-app-shell .brand-kicker{
  margin-bottom:2px;
  color:var(--fg-mute);
  font-size:8px;
  font-weight:900;
  letter-spacing:.15em;
  text-transform:uppercase;
}

#unifiedTopbar.header-app-shell .brand-title{
  font-size:13px!important;
  line-height:1!important;
  letter-spacing:-.03em!important;
}

#unifiedTopbar.header-app-shell .brand-sub{
  margin-top:4px;
  color:var(--fg-dim)!important;
  font-size:10px!important;
  letter-spacing:.01em!important;
  text-transform:none!important;
}

#unifiedTopbar.header-app-shell .topnav-main{
  justify-content:center!important;
  gap:8px!important;
  border-radius:999px!important;
  overflow:hidden;
}

#unifiedTopbar.header-app-shell .topnav-link{
  height:34px!important;
  padding:0 22px!important;
  border-radius:999px!important;
  border:1px solid transparent!important;
  background:transparent!important;
  color:var(--fg-dim)!important;
  font-size:11px!important;
  font-weight:800!important;
  box-shadow:none!important;
}

#unifiedTopbar.header-app-shell .topnav-link:hover{
  color:var(--fg)!important;
  background:color-mix(in srgb,var(--panel-high) 84%,transparent)!important;
  border-color:color-mix(in srgb,var(--line) 95%,transparent)!important;
}

#unifiedTopbar.header-app-shell .topnav-link.active{
  color:var(--brand)!important;
  background:color-mix(in srgb,var(--brand) 12%,var(--panel-high))!important;
  border-color:color-mix(in srgb,var(--brand) 26%,var(--line))!important;
  box-shadow:0 8px 22px -18px color-mix(in srgb,var(--brand) 72%,transparent)!important;
}

#unifiedTopbar.header-app-shell .topbar-right{gap:8px!important}

#unifiedTopbar.header-app-shell .unified-theme-btn.icon-only{
  width:34px!important;
  min-width:34px!important;
  height:34px!important;
  border-radius:12px!important;
  background:color-mix(in srgb,var(--panel-high) 94%,transparent)!important;
  border:1px solid color-mix(in srgb,var(--line) 95%,transparent)!important;
  color:var(--fg-dim)!important;
  box-shadow:none!important;
}

#unifiedTopbar.header-app-shell .unified-theme-btn.icon-only:hover{
  color:var(--fg)!important;
  background:color-mix(in srgb,var(--panel-high) 100%,#fff 3%)!important;
}

#unifiedTopbar.header-app-shell .quick-metric.user-balance{
  min-width:140px!important;
  height:34px!important;
  padding:4px 8px!important;
  border-radius:999px!important;
  display:flex!important;
  flex-direction:column!important;
  justify-content:center!important;
  background:linear-gradient(135deg,color-mix(in srgb,var(--up) 9%,var(--panel-high)) 0%,color-mix(in srgb,var(--panel-high) 94%,transparent) 100%)!important;
  border:1px solid color-mix(in srgb,var(--up) 28%,var(--line))!important;
  box-shadow:none!important;
}

#unifiedTopbar.header-app-shell .quick-metric.user-balance .label{
  color:color-mix(in srgb,var(--up) 36%,var(--fg-mute))!important;
  font-size:7px!important;
  line-height:1!important;
  letter-spacing:.14em!important;
}

#unifiedTopbar.header-app-shell .quick-metric.user-balance .value{
  margin-top:1px;
  color:var(--fg)!important;
  font-size:10px!important;
  line-height:1!important;
  letter-spacing:-.02em!important;
  font-family:'JetBrains Mono',monospace!important;
  font-weight:800!important;
}

#unifiedTopbar.header-app-shell .topnav-profile-btn{
  width:54px!important;
  min-width:54px!important;
  height:54px!important;
  padding:0!important;
  border-radius:16px!important;
  display:inline-flex!important;
  align-items:center!important;
  justify-content:center!important;
  line-height:0;
  gap:0;
  background:transparent!important;
  border-color:transparent!important;
  box-shadow:none!important;
  color:var(--fg)!important;
  transition:background .15s,border-color .15s,box-shadow .15s;
  align-self:center!important;
  margin-top:0!important;
  transform:none!important;
}

#unifiedTopbar.header-app-shell .topnav-profile-menu-wrap{
  position:relative;
  display:flex!important;
  align-items:center!important;
  align-self:center!important;
  line-height:0;
}

#unifiedTopbar.header-app-shell .topnav-profile-menu{
  position:absolute;
  top:calc(100% + 10px);
  right:0;
  min-width:180px;
  padding:8px;
  border-radius:12px;
  border:1px solid color-mix(in srgb,var(--line-strong) 88%,transparent);
  background:
    linear-gradient(180deg,color-mix(in srgb,var(--panel-high) 97%,#fff 3%),color-mix(in srgb,var(--panel) 96%,#000 4%));
  box-shadow:
    0 18px 36px -24px rgba(0,0,0,.75),
    0 10px 22px -20px rgba(0,0,0,.6),
    0 0 0 1px rgba(255,255,255,.03) inset;
  backdrop-filter:blur(12px);
  -webkit-backdrop-filter:blur(12px);
  z-index:40;
}

#unifiedTopbar.header-app-shell .topnav-profile-menu::before{
  content:'';
  position:absolute;
  top:-6px;
  right:14px;
  width:10px;
  height:10px;
  border-top:1px solid color-mix(in srgb,var(--line-strong) 88%,transparent);
  border-left:1px solid color-mix(in srgb,var(--line-strong) 88%,transparent);
  background:color-mix(in srgb,var(--panel-high) 96%,#fff 4%);
  transform:rotate(45deg);
}

#unifiedTopbar.header-app-shell .topnav-profile-menu[hidden]{
  display:none!important;
}

#unifiedTopbar.header-app-shell .topnav-profile-menu-item{
  width:100%;
  height:38px;
  border:1px solid color-mix(in srgb,var(--line) 82%,transparent);
  border-radius:10px;
  background:color-mix(in srgb,var(--panel-sunken) 72%,var(--panel));
  color:var(--down);
  font-size:12px;
  font-weight:900;
  letter-spacing:.01em;
  text-align:left;
  padding:0 12px;
  display:flex;
  align-items:center;
  justify-content:space-between;
  cursor:pointer;
  transition:background .14s,border-color .14s,color .14s,transform .14s,box-shadow .14s;
}

#unifiedTopbar.header-app-shell .topnav-profile-menu-item-ico{
  width:14px;
  height:14px;
  opacity:.78;
  flex-shrink:0;
  transition:transform .14s,opacity .14s;
}

#unifiedTopbar.header-app-shell .topnav-profile-menu-item:hover{
  background:linear-gradient(180deg,color-mix(in srgb,var(--down) 16%,var(--panel)),color-mix(in srgb,var(--down) 10%,var(--panel-sunken)));
  border-color:color-mix(in srgb,var(--down) 42%,var(--line-strong));
  color:color-mix(in srgb,var(--down) 88%,#fff 12%);
  transform:translateY(-1px);
  box-shadow:0 10px 18px -16px rgba(239,68,68,.75),0 0 0 1px rgba(239,68,68,.1) inset;
}

#unifiedTopbar.header-app-shell .topnav-profile-menu-item:hover .topnav-profile-menu-item-ico{
  opacity:1;
  transform:translateX(1px);
}

#unifiedTopbar.header-app-shell .topnav-profile-menu-item:focus-visible{
  outline:none;
  border-color:color-mix(in srgb,var(--down) 54%,var(--line-strong));
  box-shadow:0 0 0 3px color-mix(in srgb,var(--down) 20%,transparent);
}

:root[data-theme="light"] #unifiedTopbar.header-app-shell .topnav-profile-menu{
  background:linear-gradient(180deg,#ffffff,#f7f9fd);
  border-color:#d7deee;
  box-shadow:0 16px 34px -22px rgba(15,23,42,.28),0 0 0 1px rgba(255,255,255,.8) inset;
}

:root[data-theme="light"] #unifiedTopbar.header-app-shell .topnav-profile-menu::before{
  background:#ffffff;
  border-top-color:#d7deee;
  border-left-color:#d7deee;
}

:root[data-theme="light"] #unifiedTopbar.header-app-shell .topnav-profile-menu-item{
  background:#ffffff;
  border-color:#d7deee;
  color:#d92828;
}

:root[data-theme="light"] #unifiedTopbar.header-app-shell .topnav-profile-menu-item:hover{
  background:linear-gradient(180deg,#fff3f3,#ffe8e8);
  border-color:#f0a7a7;
  color:#c61f1f;
}

#unifiedTopbar.header-app-shell .topnav-profile-btn:hover{
  background:transparent!important;
  border-color:transparent!important;
  transform:none!important;
}

#unifiedTopbar.header-app-shell .topnav-profile-btn::before{
  content:none!important;
}

#unifiedTopbar.header-app-shell .topnav-profile-avatar{
  width:46px;
  height:46px;
  border-radius:999px;
  display:grid;
  place-items:center;
  background:linear-gradient(135deg,var(--brand),#7c3aed);
  color:#fff;
  flex-shrink:0;
  overflow:hidden;
  box-shadow:0 0 0 1px color-mix(in srgb,var(--line-strong) 88%,transparent);
  transition:box-shadow .16s ease,filter .16s ease;
}

#unifiedTopbar.header-app-shell .topnav-profile-avatar img{
  width:100%;
  height:100%;
  object-fit:cover;
  display:block;
}

#unifiedTopbar.header-app-shell .topnav-profile-btn:hover .topnav-profile-avatar{
  box-shadow:
    0 0 0 2px color-mix(in srgb,var(--brand) 45%,transparent),
    0 0 0 5px color-mix(in srgb,var(--brand) 16%,transparent);
  filter:saturate(1.03);
}

#unifiedTopbar.header-app-shell .topnav-profile-btn:focus-visible{
  outline:none;
}

#unifiedTopbar.header-app-shell .topnav-profile-btn:focus-visible .topnav-profile-avatar{
  box-shadow:
    0 0 0 2px color-mix(in srgb,var(--brand) 52%,transparent),
    0 0 0 6px color-mix(in srgb,var(--brand) 20%,transparent);
}

#unifiedTopbar.header-app-shell .topnav-profile-copy{
  display:none!important;
}

#unifiedTopbar.header-app-shell .mobile-menu-btn{
  width:34px!important;
  height:34px!important;
  border-radius:12px!important;
  background:color-mix(in srgb,var(--panel-high) 94%,transparent)!important;
  border:1px solid color-mix(in srgb,var(--line) 95%,transparent)!important;
  color:var(--fg)!important;
}

#unifiedTopbar.header-app-shell .mobile-menu-btn svg{display:block}

@media(max-width:1100px){
  #unifiedTopbar.header-app-shell.terminal-topbar{
    grid-template-columns:minmax(0,1fr) auto!important;
  }

  #unifiedTopbar.header-app-shell .topnav-main,
  #unifiedTopbar.header-app-shell .quick-metric.user-balance{
    display:none!important;
  }
}

@media(max-width:700px){
  #unifiedTopbar.header-app-shell.terminal-topbar{
    min-height:58px!important;
    padding:8px 12px!important;
    gap:8px!important;
  }

  #unifiedTopbar.header-app-shell .brand{gap:8px!important}

  #unifiedTopbar.header-app-shell .brand-logo{
    width:34px!important;
    height:34px!important;
    border-radius:12px!important;
  }

  #unifiedTopbar.header-app-shell .brand-kicker,
  #unifiedTopbar.header-app-shell .brand-sub,
  #unifiedTopbar.header-app-shell .topnav-profile-copy{
    display:none!important;
  }

  #unifiedTopbar.header-app-shell .topnav-profile-btn{
    width:52px!important;
    min-width:52px!important;
    height:52px!important;
    padding:0!important;
    justify-content:center!important;
    border-radius:16px!important;
    margin-top:0!important;
  }

  #unifiedTopbar.header-app-shell .topnav-profile-avatar{
    width:44px;
    height:44px;
  }
}

#sidebarContent{
  display:flex;
  flex-direction:column;
  min-height:100%;
}

.sidebar-v2-nav{
  flex:1;
  padding:8px;
  position:relative;
}

.sidebar-v2-link{
  min-height:52px!important;
  border-radius:12px!important;
  padding:0 12px!important;
  transition:background-color .22s ease,color .22s ease,border-color .22s ease,box-shadow .22s ease;
  border:1px solid transparent!important;
  background:transparent!important;
  color:#475569!important;
}

.sidebar-v2-link-main{
  display:flex;
  align-items:center;
  gap:10px;
}

.sidebar-v2-active-arrow{
  position:absolute;
  right:22px;
  top:0;
  transform:translateY(-50%);
  color:#fff;
  font-size:18px;
  line-height:1;
  opacity:0;
  pointer-events:none;
  z-index:3;
  transition:top .28s cubic-bezier(.22,1,.36,1),opacity .18s ease;
}

.sidebar-v2-active-arrow.is-visible{
  opacity:1;
}

.sidebar-v2-link .link-chevron{
  display:none!important;
}

.sidebar-v2-link-icon{
  width:28px;
  height:28px;
  border-radius:8px;
  display:grid;
  place-items:center;
  color:#6b86ad;
  transition:color .2s ease;
}

.sidebar-v2-link.is-current .sidebar-v2-link-icon{
  color:#fff;
}

.sidebar-v2-link:not(.is-current):hover{
  background:#f8fafc!important;
}

.sidebar-v2-link.is-current{
  background:#2563eb!important;
  color:#fff!important;
  border-color:#1d4ed8!important;
  box-shadow:0 8px 18px -12px rgba(37,99,235,.9)!important;
}

.sidebar-v2-link.is-current b,
.sidebar-v2-link.is-current em{
  color:#fff!important;
}

.sidebar-v2-link em{
  opacity:0;
  color:#6b86ad!important;
  transition:opacity .18s ease,color .18s ease,transform .18s ease;
  transform:translateX(-2px);
}

#sidebarContent .sidebar-v2-link em{
  background:none!important;
  border:0!important;
  box-shadow:none!important;
  width:auto!important;
  height:auto!important;
  min-width:0!important;
  border-radius:0!important;
  padding:0!important;
  display:inline!important;
  line-height:1!important;
}

#sidebarContent .sidebar-v2-link em.link-chevron{
  display:none!important;
}

.sidebar-v2-link.is-current em{
  opacity:1;
  transform:translateX(0);
}

/* Hard-match sidebar visuals with arbitrizor-profile-settings */
#sidebarContent .sidebar-v2-link{
  opacity:1!important;
  filter:none!important;
  border-left:0!important;
}

#sidebarContent .sidebar-v2-link::before,
#sidebarContent .sidebar-v2-link::after{
  content:none!important;
}

#sidebarContent .sidebar-v2-link.is-current{
  background:#2563eb!important;
  border:1px solid #1d4ed8!important;
  box-shadow:0 8px 18px -12px rgba(37,99,235,.9)!important;
  color:#fff!important;
  opacity:1!important;
}

#sidebarContent .sidebar-v2-link.is-current .sidebar-v2-link-icon,
#sidebarContent .sidebar-v2-link.is-current b,
#sidebarContent .sidebar-v2-link.is-current em{
  color:#fff!important;
  opacity:1!important;
}

.sidebar-v2-footer{
  margin-top:auto;
  padding:14px 8px 10px;
  border-top:1px solid var(--line);
}

.sidebar-v2-process-card{
  border:1px solid #e2e8f0;
  border-radius:16px;
  padding:12px;
  background:#fff;
}

.sidebar-v2-process-head{
  display:flex;
  align-items:center;
  justify-content:space-between;
  font-size:10px;
  font-weight:900;
  letter-spacing:.12em;
  text-transform:uppercase;
  color:#94a3b8;
  margin-bottom:8px;
}

.sidebar-v2-process-head i{
  width:20px;
  height:8px;
  border-radius:999px;
  background:linear-gradient(90deg,#e2e8f0,#cbd5e1,#e2e8f0);
}

.sidebar-v2-process-card p{
  margin:0;
  font-size:12px;
  font-weight:700;
  color:#64748b;
}

.sidebar-v2-logout-btn{
  width:100%;
  height:38px;
  margin-top:10px;
  border:0;
  background:transparent;
  color:#94a3b8;
  display:flex;
  align-items:center;
  justify-content:center;
  gap:8px;
  font-size:11px;
  font-weight:800;
}

.sidebar-v2-logout-btn:hover{
  color:#f43f5e;
}

body.profile-v2-active #sectionMetricsBar,
body.profile-v2-active .section-metrics-bar,
body.profile-v2-active .page-hero,
body.profile-v2-active .content-shell>.section-toolbar,
body.profile-v2-active .content-shell .section-toolbar{
  display:none!important;
}

body.profile-v2-active #sectionMetricsBar,
body.profile-v2-active .section-metrics-bar{
  height:0!important;
  min-height:0!important;
  padding:0!important;
  margin:0!important;
  border:0!important;
  overflow:hidden!important;
}

body.profile-v2-active{
  grid-template-rows:56px minmax(0,1fr)!important;
  grid-template-areas:"topnav" "main"!important;
}

body.profile-v2-active .content-shell{
  background:transparent!important;
  border:0!important;
  box-shadow:none!important;
  padding:0!important;
  overflow:visible!important;
}

body.profile-v2-active #pageContent{
  padding:20px 26px 44px;
}

.account-v2-page{
  max-width:1380px;
  margin:0 auto;
  display:grid;
  gap:24px;
}

.account-v2-header{
  display:grid;
  gap:18px;
  padding-bottom:8px;
  border-bottom:1px solid rgba(148,163,184,.25);
}

.account-v2-title-wrap{
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:16px;
  flex-wrap:wrap;
}

.account-v2-title-wrap h1{
  margin:0;
  font-size:34px;
  font-weight:900;
  letter-spacing:-.03em;
  color:#0f172a;
}

.account-v2-title-wrap p{
  margin:4px 0 0;
  color:#94a3b8;
  font-size:14px;
  font-weight:700;
}

.account-v2-title-icon{
  width:56px;
  height:56px;
  border-radius:18px;
  display:grid;
  place-items:center;
  color:#fff;
  background:#2563eb;
  box-shadow:0 14px 32px -20px rgba(37,99,235,.9);
}

.account-v2-stats{
  display:grid;
  grid-template-columns:repeat(3,minmax(0,1fr));
  gap:12px;
}

.account-v2-stat{
  background:#fff;
  border:1px solid #e2e8f0;
  border-radius:20px;
  padding:12px 14px;
}

.account-v2-stat span{
  display:block;
  font-size:9px;
  font-weight:900;
  letter-spacing:.16em;
  text-transform:uppercase;
  color:#94a3b8;
  margin-bottom:7px;
}

.account-v2-stat b{
  font-size:18px;
  font-weight:900;
  letter-spacing:-.02em;
  color:#0f172a;
}

.account-v2-action-row{
  display:flex;
  align-items:flex-end;
  justify-content:space-between;
  gap:14px;
  flex-wrap:wrap;
}

.account-v2-action-row h2{
  margin:0;
  font-size:30px;
  font-weight:900;
  letter-spacing:-.03em;
  color:#0f172a;
}

.account-v2-action-row p{
  margin:5px 0 0;
  font-size:14px;
  color:#64748b;
  font-weight:600;
}

.account-v2-save-btn{
  height:48px;
  padding:0 24px;
  border:0;
  border-radius:16px;
  background:#2563eb;
  color:#fff;
  font-size:12px;
  font-weight:900;
  letter-spacing:.04em;
  box-shadow:0 16px 36px -22px rgba(37,99,235,.95);
}

.account-v2-save-btn:disabled{
  opacity:.7;
}

.account-v2-grid{
  display:grid;
  grid-template-columns:minmax(280px,.95fr) minmax(420px,1.4fr);
  gap:18px;
  align-items:start;
}

.account-v2-left-col{
  display:grid;
  gap:18px;
}

.account-v2-card{
  border:1px solid #e2e8f0;
  border-radius:34px;
  background:#fff;
  box-shadow:0 2px 4px rgba(15,23,42,.03);
  overflow:hidden;
}

.account-v2-card-head{
  padding:18px 24px;
  border-bottom:1px solid #eef2f7;
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:12px;
}

.account-v2-card-head h3{
  margin:0;
  font-size:11px;
  font-weight:900;
  text-transform:uppercase;
  letter-spacing:.2em;
  color:#334155;
}

.account-v2-avatar-wrap{
  padding:24px;
  display:grid;
  justify-items:center;
  gap:12px;
}

.account-v2-avatar-preview{
  width:min(280px,100%);
  aspect-ratio:1/1;
  border-radius:48px;
  overflow:hidden;
  border:10px solid #fff;
  box-shadow:0 26px 50px -28px rgba(37,99,235,.3);
  background:#f8fafc;
}

.account-v2-avatar-preview img{
  width:100%;
  height:100%;
  object-fit:cover;
  display:block;
}

.account-v2-avatar-actions{
  display:flex;
  gap:10px;
}

.account-v2-avatar-note{
  margin:4px 0 0;
  font-size:10px;
  font-weight:900;
  letter-spacing:.16em;
  text-transform:uppercase;
  color:#94a3b8;
}

.account-v2-readonly-list{
  padding:18px 20px 20px;
  display:grid;
  gap:10px;
}

.account-v2-readonly{
  border:1px solid #eef2f7;
  background:#f8fafc;
  border-radius:20px;
  padding:14px 16px;
  display:grid;
  gap:7px;
}

.account-v2-readonly span{
  font-size:10px;
  font-weight:900;
  letter-spacing:.16em;
  text-transform:uppercase;
  color:#94a3b8;
}

.account-v2-readonly b{
  font-size:18px;
  font-weight:900;
  color:#0f172a;
}

.account-v2-main-card .account-v2-form-grid{
  padding:26px 28px 30px;
  display:grid;
  gap:20px;
}

.account-v2-field{
  display:grid;
  gap:8px;
}

.account-v2-field span{
  font-size:11px;
  font-weight:900;
  letter-spacing:.2em;
  text-transform:uppercase;
  color:#94a3b8;
}

.account-v2-field input{
  height:54px;
  border:1px solid #e2e8f0;
  border-radius:18px;
  background:#f8fafc;
  padding:0 18px;
  font-size:16px;
  font-weight:700;
  color:#0f172a;
}

.account-v2-field input:focus{
  outline:none;
  border-color:#3b82f6;
  box-shadow:0 0 0 8px rgba(59,130,246,.1);
  background:#fff;
}

.account-v2-sync-btn{
  height:26px;
  padding:0 10px;
  border:0;
  border-radius:8px;
  background:#eff6ff;
  color:#2563eb;
  font-size:9px;
  font-weight:900;
  letter-spacing:.08em;
}

.account-v2-notice{
  margin-top:8px;
  border:1px solid #dbeafe;
  border-radius:26px;
  background:rgba(239,246,255,.7);
  padding:16px 18px;
  display:grid;
  grid-template-columns:42px 1fr;
  gap:12px;
}

.account-v2-notice-icon{
  width:38px;
  height:38px;
  border-radius:12px;
  background:#2563eb;
  color:#fff;
  display:grid;
  place-items:center;
}

.account-v2-notice strong{
  display:block;
  color:#1e3a8a;
  font-size:14px;
  margin-bottom:3px;
}

.account-v2-notice p{
  margin:0;
  color:#1e3a8a;
  opacity:.82;
  font-size:13px;
  line-height:1.45;
}

@media(max-width:1100px){
  body.profile-v2-active #pageContent{
    padding:14px 12px 34px;
  }
  .account-v2-grid{
    grid-template-columns:1fr;
  }
}

@media(max-width:700px){
  .account-v2-title-wrap h1{
    font-size:28px;
  }
  .account-v2-stats{
    grid-template-columns:1fr;
  }
  .account-v2-action-row h2{
    font-size:24px;
  }
  .account-v2-action-row .account-v2-save-btn{
    width:100%;
  }
}

/* Account profile exact-fit pass (React reference parity) */
.account-v3-page{
  gap:15px;
}

.account-v3-title-icon{
  border-radius:22px;
  box-shadow:0 18px 34px -24px rgba(37,99,235,.95);
}

.account-v3-stat{
  border-radius:14px;
  padding:8px 9px;
}

.account-v3-hrow{
  display:flex;
  align-items:center;
  gap:7px;
}

.account-v3-hrow i{
  display:inline-flex;
  align-items:center;
  justify-content:center;
  height:13px;
  padding:0 5px;
  border-radius:4px;
  background:#dcfce7;
  color:#16a34a;
  font-size:6px;
  font-style:normal;
  font-weight:900;
  text-transform:uppercase;
  letter-spacing:.08em;
}

.account-v2-card{
  border-color:#e2e8f0a6;
  border-radius:24px;
  box-shadow:0 2px 4px rgba(0,0,0,.02);
}

.account-v2-card-head{
  background:#f8fafc99;
}

.account-v2-card-head h3{
  display:flex;
  align-items:center;
  gap:10px;
}

.account-v3-head-ico{
  width:20px;
  height:20px;
  border-radius:8px;
  border:1px solid #e2e8f0;
  background:#fff;
  color:#3b82f6;
  display:grid;
  place-items:center;
}

.account-v2-avatar-preview{
  width:min(154px,100%);
  border-width:6px;
}

.account-v2-avatar-actions{
  margin-top:-2px;
}

.account-v2-main-card .account-v2-form-grid{
  padding:17px 17px 20px;
  gap:11px;
}

.account-v2-field input{
  height:36px;
  border-radius:13px;
  padding:0 11px;
  font-size:13px;
  font-weight:700;
}

.account-v2-notice{
  border-radius:18px;
  padding:10px 11px;
}

/* Header final match: remove nav capsule and heavy profile chip */
#unifiedTopbar.header-app-shell.terminal-topbar{
  min-height:58px!important;
  height:58px!important;
  padding:0 18px!important;
  gap:16px!important;
  background:var(--panel)!important;
  background-image:none!important;
  border-bottom:1px solid var(--line)!important;
  box-shadow:none!important;
  backdrop-filter:none!important;
}

#unifiedTopbar.header-app-shell .brand{
  gap:10px!important;
}

#unifiedTopbar.header-app-shell .brand-logo{
  width:28px!important;
  height:28px!important;
  border-radius:8px!important;
}

#unifiedTopbar.header-app-shell .brand-logo svg{
  width:13px!important;
  height:13px!important;
}

#unifiedTopbar.header-app-shell .brand-title{
  font-size:15px!important;
  font-weight:800!important;
  line-height:1!important;
  letter-spacing:-.015em!important;
  color:var(--fg)!important;
}

#unifiedTopbar.header-app-shell .brand-kicker,
#unifiedTopbar.header-app-shell .brand-sub{
  display:none!important;
}

#unifiedTopbar.header-app-shell .topnav-main{
  height:auto!important;
  padding:0!important;
  border:0!important;
  border-radius:0!important;
  background:transparent!important;
  box-shadow:none!important;
  gap:8px!important;
  overflow:visible!important;
}

#unifiedTopbar.header-app-shell .topnav-link{
  height:34px!important;
  padding:0 12px!important;
  border-radius:9px!important;
  font-size:12px!important;
  font-weight:800!important;
  color:var(--fg-dim)!important;
  background:transparent!important;
  border:1px solid transparent!important;
}

#unifiedTopbar.header-app-shell .topnav-link:hover{
  background:var(--panel-high)!important;
  border-color:var(--line)!important;
  color:var(--fg)!important;
}

#unifiedTopbar.header-app-shell .topnav-link.active{
  background:#2563eb!important;
  border-color:#2563eb!important;
  color:#fff!important;
  box-shadow:0 8px 18px -12px rgba(37,99,235,.9)!important;
}

#unifiedTopbar.header-app-shell .header-nav-icon{
  width:14px;
  height:14px;
}

#unifiedTopbar.header-app-shell .topbar-right{
  gap:10px!important;
}

#unifiedTopbar.header-app-shell .header-icon-group{
  padding-right:8px!important;
  border-right:0!important;
  gap:2px!important;
}

#unifiedTopbar.header-app-shell .header-icon-btn{
  width:28px!important;
  height:28px!important;
  border-radius:8px!important;
  color:var(--fg-mute)!important;
  background:transparent!important;
  border:1px solid transparent!important;
}

#unifiedTopbar.header-app-shell .header-icon-btn:hover{
  color:var(--fg)!important;
  background:var(--panel-high)!important;
}

#unifiedTopbar.header-app-shell .header-bell-dot{
  top:6px;
  right:6px;
  width:6px;
  height:6px;
}

#unifiedTopbar.header-app-shell .header-profile-btn{
  min-width:170px!important;
  height:40px!important;
  padding:0 10px 0 14px!important;
  border-radius:8px!important;
  background:transparent!important;
  border:1px solid transparent!important;
  gap:8px!important;
}

#unifiedTopbar.header-app-shell .header-profile-btn:hover{
  background:var(--panel-high)!important;
  border-color:var(--line)!important;
}

#unifiedTopbar.header-app-shell .header-profile-copy strong{
  font-size:9px!important;
  color:var(--fg-mute)!important;
  letter-spacing:.12em!important;
  line-height:1!important;
}

#unifiedTopbar.header-app-shell .header-profile-copy small{
  font-size:11px!important;
  color:var(--fg)!important;
  font-weight:800!important;
  line-height:1.05!important;
  max-width:108px!important;
  white-space:nowrap!important;
  overflow:hidden!important;
  text-overflow:ellipsis!important;
}

#unifiedTopbar.header-app-shell .topnav-profile-avatar{
  width:30px!important;
  height:30px!important;
  border-radius:8px!important;
  box-shadow:none!important;
}

@media(max-width:1100px){
  #unifiedTopbar.header-app-shell .header-profile-copy{
    display:none!important;
  }
}

/* Header hard override (final): no gradients, no vertical artifact */
#unifiedTopbar,
#unifiedTopbar.terminal-topbar,
#unifiedTopbar.header-app-shell.terminal-topbar,
#unifiedTopbar.header-app-shell.terminal-topbar{
  background:var(--panel)!important;
  background-image:none!important;
  box-shadow:none!important;
}

#unifiedTopbar.header-app-shell .header-icon-group{
  border-right:0!important;
  box-shadow:none!important;
}

#unifiedTopbar.header-app-shell .header-icon-group::before,
#unifiedTopbar.header-app-shell .header-icon-group::after,
#unifiedTopbar.header-app-shell .topbar-right::before,
#unifiedTopbar.header-app-shell .topbar-right::after{
  content:none!important;
  display:none!important;
}

#unifiedTopbar.header-app-shell .header-profile-copy{
  display:flex!important;
  flex-direction:column!important;
  align-items:flex-end!important;
  justify-content:center!important;
  min-width:0!important;
}

#unifiedTopbar.header-app-shell .header-profile-copy strong{
  line-height:1!important;
}

#unifiedTopbar.header-app-shell .header-profile-copy small{
  line-height:1.05!important;
}

/* Ultra-final header flattening */
#unifiedTopbar,
#unifiedTopbar.terminal-topbar,
#unifiedTopbar.header-app-shell,
#unifiedTopbar.header-app-shell.terminal-topbar{
  background:var(--panel)!important;
  background-color:var(--panel)!important;
  background-image:none!important;
  opacity:1!important;
  filter:none!important;
  box-shadow:none!important;
  backdrop-filter:none!important;
  -webkit-backdrop-filter:none!important;
}

/* Icons: no square highlight, only color change */
#unifiedTopbar .header-icon-group{
  border-right:0!important;
  padding-right:6px!important;
  gap:6px!important;
}

#unifiedTopbar .header-icon-btn,
#unifiedTopbar .unified-theme-btn.icon-only,
#unifiedTopbar #themeToggle{
  width:auto!important;
  min-width:auto!important;
  height:auto!important;
  padding:0!important;
  border:0!important;
  border-radius:0!important;
  background:transparent!important;
  box-shadow:none!important;
  color:var(--fg-mute)!important;
}

#unifiedTopbar .header-icon-btn:hover,
#unifiedTopbar .unified-theme-btn.icon-only:hover,
#unifiedTopbar #themeToggle:hover{
  background:transparent!important;
  border:0!important;
  box-shadow:none!important;
  color:var(--fg)!important;
}

#unifiedTopbar .header-icon-btn:focus-visible,
#unifiedTopbar .unified-theme-btn.icon-only:focus-visible,
#unifiedTopbar #themeToggle:focus-visible{
  outline:none!important;
  box-shadow:none!important;
}

/* Force-flat header and subbar (kill any remaining gradients from earlier layers) */
#unifiedTopbar,
#unifiedTopbar.terminal-topbar,
#unifiedTopbar.header-app-shell,
#unifiedTopbar.header-app-shell.terminal-topbar{
  background:var(--panel)!important;
  background-color:var(--panel)!important;
  background-image:none!important;
  box-shadow:none!important;
  backdrop-filter:none!important;
  -webkit-backdrop-filter:none!important;
}

#sectionMetricsBar,
.section-metrics-bar{
  background:var(--panel)!important;
  background-color:var(--panel)!important;
  background-image:none!important;
  box-shadow:none!important;
}

/* Fix bell-dot artifact (was rendering as vertical inline fragment) */
#unifiedTopbar .header-bell-btn{
  position:relative!important;
}

#unifiedTopbar .header-bell-dot{
  position:absolute!important;
  display:block!important;
  top:2px!important;
  right:0!important;
  width:6px!important;
  height:6px!important;
  border-radius:999px!important;
  background:#f43f5e!important;
  border:2px solid var(--panel)!important;
  line-height:0!important;
  font-size:0!important;
  pointer-events:none!important;
}

/* Header right-side alignment fix: keep icons before profile */
#unifiedTopbar .topbar-right{
  display:flex!important;
  align-items:center!important;
  justify-content:flex-end!important;
  gap:10px!important;
}

#unifiedTopbar .header-icon-group{
  order:1!important;
  display:inline-flex!important;
  align-items:center!important;
  justify-content:center!important;
  gap:8px!important;
  padding-right:6px!important;
  flex-shrink:0!important;
}

#unifiedTopbar .header-profile-btn,
#unifiedTopbar .topnav-profile-btn{
  order:2!important;
  display:inline-flex!important;
  align-items:center!important;
  gap:8px!important;
  flex-shrink:0!important;
}

/* Header profile hover fix: remove legacy pseudo fragments */
#unifiedTopbar .header-profile-btn{
  position:relative!important;
  overflow:visible!important;
}

#unifiedTopbar .header-profile-btn::before,
#unifiedTopbar .header-profile-btn::after{
  content:none!important;
  display:none!important;
}

#unifiedTopbar .header-profile-copy{
  display:flex!important;
  flex-direction:column!important;
  align-items:flex-end!important;
  justify-content:center!important;
  min-width:0!important;
}

#unifiedTopbar .header-icon-btn,
#unifiedTopbar .unified-theme-btn.icon-only,
#unifiedTopbar #themeToggle{
  display:inline-flex!important;
  align-items:center!important;
  justify-content:center!important;
  width:18px!important;
  height:18px!important;
  padding:0!important;
  line-height:1!important;
  vertical-align:middle!important;
}

/* Topnav icon centering fix */
#unifiedTopbar .topnav-link{
  display:inline-flex!important;
  align-items:center!important;
  justify-content:center!important;
  gap:6px!important;
  line-height:1!important;
}

#unifiedTopbar .topnav-link .header-nav-icon{
  display:inline-flex!important;
  align-items:center!important;
  justify-content:center!important;
  width:14px!important;
  height:14px!important;
  flex-shrink:0!important;
  line-height:1!important;
}

#unifiedTopbar .topnav-link .header-nav-icon svg{
  display:block!important;
  width:14px!important;
  height:14px!important;
}

/* Account exact match with var/maket.htm (priority block) */
body.profile-v2-active #pageContent{
  padding:20px 26px 44px!important;
}

body.profile-v2-active .account-v2-page.account-v3-page{
  max-width:1120px!important;
  margin:0 auto!important;
  gap:20px!important;
}

body.profile-v2-active .profile-motion-item{
  opacity:0;
  transform:translateY(20px);
  animation:profileMotionIn .46s cubic-bezier(.2,.8,.2,1) forwards;
  animation-delay:var(--pm-delay,0ms);
}

@keyframes profileMotionIn{
  to{
    opacity:1;
    transform:translateY(0);
  }
}

body.profile-v2-active .account-v2-header{
  position:static!important;
  top:auto!important;
  z-index:auto!important;
  background:var(--bg)!important;
  gap:18px!important;
  padding-top:0!important;
  padding-bottom:8px!important;
  border-bottom:1px solid rgba(148,163,184,.25)!important;
}

body.profile-v2-active .account-v2-header::before{
  content:"";
  position:absolute;
  left:0;
  right:0;
  top:0;
  height:1px;
  background:transparent;
  pointer-events:none;
}

body.profile-v2-active .account-v2-title-icon.account-v3-title-icon{
  width:44px!important;
  height:44px!important;
  border-radius:16px!important;
}

body.profile-v2-active .account-v2-title-main{
  display:flex!important;
  align-items:center!important;
  gap:14px!important;
  min-width:0!important;
}

body.profile-v2-active .account-v2-title-wrap h1{
  margin:0!important;
  font-size:30px!important;
  font-weight:800!important;
  line-height:1.05!important;
  letter-spacing:-.02em!important;
  font-family:Inter,ui-sans-serif,system-ui,sans-serif!important;
  color:#0f172a!important;
}

body.profile-v2-active .account-v2-title-wrap p{
  margin:4px 0 0!important;
  font-size:14px!important;
  font-weight:700!important;
  line-height:1.25!important;
  letter-spacing:-.01em!important;
  font-family:Inter,ui-sans-serif,system-ui,sans-serif!important;
  color:#8091ad!important;
}

body.profile-v2-active .account-v2-stats-card{
  display:grid!important;
  grid-template-columns:repeat(3,minmax(0,1fr))!important;
  gap:0!important;
  background:#fff!important;
  border:1px solid #e2e8f0!important;
  border-radius:20px!important;
  padding:12px 14px!important;
  min-width:min(460px,100%)!important;
  box-shadow:0 2px 4px rgba(15,23,42,.03)!important;
}

body.profile-v2-active .account-v2-stat-cell{
  display:flex!important;
  flex-direction:column!important;
  gap:8px!important;
  padding:0 14px!important;
  border-right:1px solid #eef2f7!important;
}

body.profile-v2-active .account-v2-stat-cell:last-child{
  border-right:0!important;
}

body.profile-v2-active .account-v2-stat-cell span{
  font-size:9px!important;
  font-weight:900!important;
  letter-spacing:.16em!important;
  color:#94a3b8!important;
  text-transform:uppercase!important;
}

body.profile-v2-active .account-v2-stat-cell b{
  display:flex!important;
  align-items:center!important;
  gap:8px!important;
  font-size:16px!important;
  font-weight:900!important;
  letter-spacing:-.02em!important;
}

body.profile-v2-active .account-v2-stat-cell b svg{
  width:16px!important;
  height:16px!important;
  flex-shrink:0!important;
}

body.profile-v2-active .account-v2-action-row{
  gap:16px!important;
}

body.profile-v2-active .account-v2-action-row h2{
  margin:0!important;
  font-size:20px!important;
  line-height:1!important;
  letter-spacing:-.03em!important;
  font-weight:900!important;
  font-family:Inter,ui-sans-serif,system-ui,sans-serif!important;
  color:#0f172a!important;
}

body.profile-v2-active .account-v3-hrow i{
  height:16px!important;
  padding:0 6px!important;
  font-size:8px!important;
  border-radius:4px!important;
  letter-spacing:.08em!important;
}

body.profile-v2-active .account-v2-action-row p{
  margin:5px 0 0!important;
  font-size:14px!important;
  font-weight:600!important;
  line-height:1.3!important;
  letter-spacing:-.01em!important;
  font-family:Inter,ui-sans-serif,system-ui,sans-serif!important;
  color:#425b7f!important;
}

body.profile-v2-active .account-v2-save-btn{
  height:48px!important;
  padding:0 24px!important;
  border-radius:16px!important;
  font-size:12px!important;
  font-weight:900!important;
  letter-spacing:.04em!important;
  display:inline-flex!important;
  align-items:center!important;
  justify-content:center!important;
  gap:8px!important;
  background:#2563eb!important;
  border:1px solid #2563eb!important;
  box-shadow:0 16px 32px -18px rgba(37,99,235,.9)!important;
  transition:background-color .18s ease,border-color .18s ease,transform .12s ease,box-shadow .18s ease!important;
}

body.profile-v2-active .account-v2-save-btn:hover{
  background:#1d4ed8!important;
  border-color:#1d4ed8!important;
  box-shadow:0 18px 34px -20px rgba(37,99,235,.8)!important;
}

body.profile-v2-active .account-v2-save-btn:active{
  transform:scale(.95)!important;
}

body.profile-v2-active .account-v2-save-btn .save-ico{
  width:16px!important;
  height:16px!important;
  flex-shrink:0!important;
  transition:transform .2s ease!important;
}

body.profile-v2-active .account-v2-save-btn:hover .save-ico{
  transform:scale(1.1)!important;
}

body.profile-v2-active .account-v2-save-btn .save-ico-spin{
  width:16px!important;
  height:16px!important;
  border:2px solid rgba(255,255,255,.38)!important;
  border-top-color:#fff!important;
  border-radius:50%!important;
  display:inline-block!important;
  animation:profileSaveSpin .9s linear infinite!important;
}

@keyframes profileSaveSpin{
  to{transform:rotate(360deg)}
}

body.profile-v2-active .account-v2-grid{
  gap:18px!important;
  grid-template-columns:minmax(250px,.9fr) minmax(360px,1.3fr)!important;
}

body.profile-v2-active .account-v2-left-col{
  gap:18px!important;
}

body.profile-v2-active .account-v2-card{
  border-radius:34px!important;
  transition:box-shadow .35s ease,transform .35s ease!important;
}

body.profile-v2-active .account-v2-card:hover{
  box-shadow:0 24px 48px -20px rgba(15,23,42,.08)!important;
}

body.profile-v2-active .account-v2-card-head{
  padding:18px 24px!important;
  background:#f8fafc99!important;
}

body.profile-v2-active .account-v2-card-head h3{
  font-size:10px!important;
  font-weight:900!important;
  text-transform:uppercase!important;
  letter-spacing:.2em!important;
  display:flex!important;
  align-items:center!important;
  gap:10px!important;
}

body.profile-v2-active .account-v3-head-ico{
  width:28px!important;
  height:28px!important;
  border-radius:11px!important;
}

body.profile-v2-active .account-v2-avatar-wrap{
  padding:24px!important;
  gap:12px!important;
}

body.profile-v2-active .account-v2-avatar-stack{
  position:relative!important;
  width:min(280px,100%)!important;
}

body.profile-v2-active .account-v2-avatar-preview{
  width:min(280px,100%)!important;
  border-width:10px!important;
  border-radius:48px!important;
  transition:transform .5s ease,box-shadow .5s ease!important;
}

body.profile-v2-active .account-v2-avatar-stack:hover .account-v2-avatar-preview{
  transform:scale(1.02)!important;
  box-shadow:0 30px 50px -24px rgba(59,130,246,.35)!important;
}

body.profile-v2-active .account-v2-avatar-actions{
  position:absolute!important;
  right:-8px!important;
  bottom:-8px!important;
  margin-top:0!important;
  gap:10px!important;
  transform:translateZ(0)!important;
  transition:none!important;
}

body.profile-v2-active .account-v2-avatar-stack:hover .account-v2-avatar-actions{
  transform:translateZ(0)!important;
}

body.profile-v2-active .profile-icon-btn{
  width:44px!important;
  height:44px!important;
  border-radius:18px!important;
  background:#ffffff!important;
  border:1px solid #e2e8f0!important;
  color:#64748b!important;
  opacity:1!important;
  filter:none!important;
  box-shadow:0 10px 26px -18px rgba(15,23,42,.35)!important;
  transition:transform .2s cubic-bezier(.22,1,.36,1),background-color .2s ease,border-color .2s ease,color .2s ease,box-shadow .2s ease!important;
  will-change:transform!important;
}

body.profile-v2-active .profile-icon-btn:hover{
  transform:translateY(-1px)!important;
  box-shadow:0 14px 30px -18px rgba(15,23,42,.28)!important;
}

body.profile-v2-active .profile-icon-btn.danger:hover{
  background:#ffffff!important;
  border-color:#fecaca!important;
  color:#ef4444!important;
  transform:translateY(-1px)!important;
  box-shadow:0 14px 28px -18px rgba(239,68,68,.4)!important;
}

body.profile-v2-active .profile-icon-btn.danger:hover svg{
  transform:none!important;
}

body.profile-v2-active .profile-icon-btn.primary{
  background:#2563eb!important;
  border-color:#2563eb!important;
  color:#fff!important;
  box-shadow:0 14px 30px -18px rgba(37,99,235,.55)!important;
}

body.profile-v2-active .profile-icon-btn.primary:hover{
  background:#1d4ed8!important;
  border-color:#1d4ed8!important;
  color:#fff!important;
  transform:translateY(-1px)!important;
  box-shadow:0 16px 32px -18px rgba(37,99,235,.62)!important;
}

body.profile-v2-active .profile-icon-btn:active{
  transform:scale(.9)!important;
}

body.profile-v2-active .account-v2-avatar-note{
  font-size:10px!important;
  letter-spacing:.16em!important;
}

body.profile-v2-active .account-v2-readonly-list{
  padding:18px 20px 20px!important;
  gap:10px!important;
}

body.profile-v2-active .account-v2-readonly{
  border-radius:20px!important;
  padding:14px 16px!important;
  gap:7px!important;
  transition:border-color .25s ease,background .25s ease,box-shadow .25s ease!important;
}

body.profile-v2-active .account-v2-readonly:hover{
  border-color:#cbd5e1!important;
  background:#fff!important;
  box-shadow:0 10px 24px -18px rgba(15,23,42,.24)!important;
}

body.profile-v2-active .account-v2-readonly span{
  font-size:10px!important;
  font-weight:900!important;
  text-transform:uppercase!important;
  letter-spacing:.16em!important;
}

body.profile-v2-active .account-v2-readonly b{
  font-size:16px!important;
  font-weight:900!important;
  line-height:1!important;
  letter-spacing:-.02em!important;
}

body.profile-v2-active .account-v2-main-card .account-v2-form-grid{
  padding:26px 28px 30px!important;
  gap:20px!important;
}

body.profile-v2-active .account-v2-field{
  gap:8px!important;
}

body.profile-v2-active .account-v2-field span{
  font-size:10px!important;
  font-weight:900!important;
  text-transform:uppercase!important;
  letter-spacing:.2em!important;
}

body.profile-v2-active .account-v2-field input{
  height:54px!important;
  border-radius:18px!important;
  padding:0 18px!important;
  font-size:16px!important;
  font-weight:700!important;
  letter-spacing:-.01em!important;
  line-height:1.25!important;
}

body.profile-v2-active .account-v2-sync-btn{
  height:26px!important;
  padding:0 10px!important;
  border-radius:8px!important;
  font-size:9px!important;
  letter-spacing:.08em!important;
  font-weight:900!important;
}

body.profile-v2-active .account-v2-notice{
  margin-top:8px!important;
  border-radius:26px!important;
  padding:16px 18px!important;
  grid-template-columns:42px 1fr!important;
  gap:12px!important;
  position:relative!important;
  overflow:hidden!important;
}

body.profile-v2-active .account-v2-notice-watermark{
  position:absolute!important;
  top:-12px!important;
  right:-8px!important;
  opacity:.04!important;
  color:#1e3a8a!important;
  transition:opacity .25s ease!important;
}

body.profile-v2-active .account-v2-notice:hover .account-v2-notice-watermark{
  opacity:.06!important;
}

body.profile-v2-active .account-v2-notice-icon{
  width:40px!important;
  height:40px!important;
  border-radius:12px!important;
  z-index:1!important;
  transition:transform .25s ease!important;
}

body.profile-v2-active .account-v2-notice:hover .account-v2-notice-icon{
  transform:scale(1.08)!important;
}

body.profile-v2-active .account-v2-notice-copy{
  position:relative!important;
  z-index:1!important;
}

body.profile-v2-active .account-v2-notice strong{
  font-size:14px!important;
  font-weight:900!important;
  letter-spacing:-.01em!important;
}

body.profile-v2-active .account-v2-notice p{
  font-size:12px!important;
  line-height:1.45!important;
  font-weight:700!important;
}

@media(max-width:1100px){
  body.profile-v2-active #pageContent{padding:14px 12px 34px!important}
  body.profile-v2-active .account-v2-grid{grid-template-columns:1fr!important}
  body.profile-v2-active .account-v2-title-wrap h1{font-size:28px!important}
  body.profile-v2-active .account-v2-title-wrap p{font-size:13px!important}
  body.profile-v2-active .account-v2-stats-card{min-width:100%!important}
  body.profile-v2-active .account-v2-action-row h2{font-size:20px!important}
  body.profile-v2-active .account-v2-action-row p{font-size:13px!important}
  body.profile-v2-active .account-v2-save-btn{height:46px!important;font-size:11px!important}
}

@media(max-width:700px){
  body.profile-v2-active .account-v2-page.account-v3-page{gap:16px!important}
  body.profile-v2-active #pageContent{
    padding-top:calc(58px + 12px)!important;
  }
  body.profile-v2-active .account-v2-header{
    top:auto!important;
    padding-top:0!important;
  }
  body.profile-v2-active .account-v2-stats-card{
    grid-template-columns:1fr!important;
    gap:10px!important;
  }
  body.profile-v2-active .account-v2-stat-cell{
    border-right:0!important;
    border-bottom:1px solid #eef2f7!important;
    padding:0 0 10px!important;
  }
  body.profile-v2-active .account-v2-stat-cell:last-child{
    border-bottom:0!important;
    padding-bottom:0!important;
  }
  body.profile-v2-active .account-v2-action-row h2{font-size:24px!important}
  body.profile-v2-active .account-v2-action-row p{font-size:14px!important;line-height:1.25!important}
  body.profile-v2-active .account-v2-save-btn{width:100%!important}
  body.profile-v2-active .account-v2-field input{
    height:54px!important;
    font-size:14px!important;
    border-radius:18px!important;
    padding:0 18px!important;
  }
  body.profile-v2-active .account-v3-hrow i{
    height:15px!important;
    padding:0 6px!important;
    font-size:8px!important;
  }
  body.profile-v2-active .account-v2-readonly b{font-size:15px!important}
  body.profile-v2-active .account-v2-notice strong{font-size:13px!important}
  body.profile-v2-active .account-v2-notice p{font-size:12px!important}
}

/* Mobile header order + compact avatar-only profile */
@media(max-width:700px){
  #unifiedTopbar .topbar-right{
    display:flex!important;
    align-items:center!important;
    justify-content:flex-end!important;
    gap:8px!important;
  }

  /* Right -> left: hamburger, avatar, then icon group */
  #unifiedTopbar .topbar-right .mobile-menu-btn{
    order:3!important;
  }

  #unifiedTopbar .topbar-right .topnav-profile-menu-wrap,
  #unifiedTopbar .topbar-right .header-profile-wrap{
    order:2!important;
    display:flex!important;
    align-items:center!important;
  }

  #unifiedTopbar .topbar-right .header-profile-btn,
  #unifiedTopbar .topbar-right .topnav-profile-btn{
    min-width:auto!important;
    width:44px!important;
    height:44px!important;
    padding:0!important;
    gap:0!important;
    justify-content:center!important;
  }

  #unifiedTopbar .topbar-right .header-icon-group{
    order:1!important;
    padding-right:0!important;
    gap:8px!important;
  }

  /* Hide profile text near avatar on mobile */
  #unifiedTopbar .topbar-right .header-profile-copy,
  #unifiedTopbar .topbar-right .topnav-profile-copy{
    display:none!important;
  }
}


/* Profile v2: dark theme pass */
:root[data-theme="dark"] body.profile-v2-active .account-v2-title-wrap h1,
:root[data-theme="dark"] body.profile-v2-active .account-v2-action-row h2,
:root[data-theme="dark"] body.profile-v2-active .account-v2-readonly b,
:root[data-theme="dark"] body.profile-v2-active .account-v2-stat-cell b,
:root[data-theme="dark"] body.profile-v2-active .account-v2-notice strong{
  color:#e6edf8!important;
}

:root[data-theme="dark"] body.profile-v2-active .account-v2-title-wrap p,
:root[data-theme="dark"] body.profile-v2-active .account-v2-action-row p,
:root[data-theme="dark"] body.profile-v2-active .account-v2-avatar-note,
:root[data-theme="dark"] body.profile-v2-active .account-v2-readonly span,
:root[data-theme="dark"] body.profile-v2-active .account-v2-field span{
  color:#9fb0ca!important;
}

:root[data-theme="dark"] body.profile-v2-active .account-v2-stats-card,
:root[data-theme="dark"] body.profile-v2-active .account-v2-card,
:root[data-theme="dark"] body.profile-v2-active .account-v2-readonly,
:root[data-theme="dark"] body.profile-v2-active .account-v2-avatar-preview,
:root[data-theme="dark"] body.profile-v2-active .account-v2-notice,
:root[data-theme="dark"] body.profile-v2-active .profile-icon-btn{
  background:#0f172a!important;
  border-color:#23314a!important;
  box-shadow:none!important;
}

:root[data-theme="dark"] body.profile-v2-active .account-v2-card-head{
  background:#111c31!important;
  border-bottom-color:#23314a!important;
}

:root[data-theme="dark"] body.profile-v2-active .account-v2-card-head h3,
:root[data-theme="dark"] body.profile-v2-active .account-v2-stat-cell span{
  color:#93a6c4!important;
}

:root[data-theme="dark"] body.profile-v2-active .account-v2-field input{
  background:#0b1426!important;
  border-color:#253755!important;
  color:#e6edf8!important;
}

:root[data-theme="dark"] body.profile-v2-active .account-v2-field input:focus{
  border-color:#3b82f6!important;
  background:#0b1426!important;
  box-shadow:0 0 0 6px rgba(59,130,246,.16)!important;
}

:root[data-theme="dark"] body.profile-v2-active .account-v2-sync-btn{
  background:#12213a!important;
  color:#8fb2ff!important;
}

:root[data-theme="dark"] body.profile-v2-active .account-v2-notice{
  background:rgba(30,58,138,.16)!important;
  border-color:#27467f!important;
}

:root[data-theme="dark"] body.profile-v2-active .account-v2-notice p{
  color:#b7caf0!important;
  opacity:1!important;
}

:root[data-theme="dark"] body.profile-v2-active .account-v2-stat-cell,
:root[data-theme="dark"] body.profile-v2-active .account-v2-readonly,
:root[data-theme="dark"] body.profile-v2-active .account-v2-card,
:root[data-theme="dark"] body.profile-v2-active .account-v2-card-head,
:root[data-theme="dark"] body.profile-v2-active .account-v2-stats-card{
  border-color:#23314a!important;
}

:root[data-theme="dark"] body.profile-v2-active .profile-icon-btn{
  color:#9fb0ca!important;
}

:root[data-theme="dark"] body.profile-v2-active .profile-icon-btn:hover{
  background:#16233a!important;
  border-color:#2d456a!important;
  color:#d4e0f4!important;
}

/* Profile mobile scroll fix: prevent bottom clipping in webview */
@media(max-width:700px){
  body.profile-v2-active{
    height:auto!important;
    min-height:100vh!important;
    overflow-y:auto!important;
    overflow-x:hidden!important;
    -webkit-overflow-scrolling:touch!important;
    touch-action:pan-y!important;
  }

  body.profile-v2-active.scanner-page-active{
    height:auto!important;
    overflow-y:auto!important;
  }

  body.profile-v2-active .content-shell,
  body.profile-v2-active #main{
    overflow:visible!important;
  }

  body.profile-v2-active #main{
    max-height:none!important;
    min-height:calc(100dvh - 58px)!important;
    -webkit-overflow-scrolling:touch!important;
    touch-action:pan-y!important;
  }

  body.profile-v2-active #pageContent{
    padding-bottom:calc(96px + env(safe-area-inset-bottom,0px))!important;
  }

  body.profile-v2-active .account-v2-page.account-v3-page{
    padding-bottom:20px!important;
  }
}
