/* ==========================================================================
   Account Tabs — Account Home + mobile panel switching (page-id-8,
   uwp_account_page)

   See includes/hp-account-mobile-tabs.php for how the hp-account-view-*
   body classes are set (render-time, from $_GET['type'] — no client JS
   needed for any state to be correct on load, refresh, or back/forward)
   and why UsersWP's own 'active' nav class can't be trusted for the
   overview state or for the new synthetic "Account Home" tab.

   ── All widths ────────────────────────────────────────────────────────
   body.hp-account-view-overview — no ?type= in the URL (bare /account/,
     or Account Home clicked): My Listings (#brxe-dbsid) is the view. The
     tab-content pane UsersWP still renders (Edit Account, by its own
     internal default) is hidden on every screen size — showing it
     alongside My Listings was itself the desktop bug this fixes, not a
     desktop feature to preserve.
   body.hp-account-view-tab — a real tab is selected (Edit Account,
     Invoices, Change Password, ...).

   ── Desktop (>768px) ──────────────────────────────────────────────────
   Only the overview state's layout changes: the account nav column
   (#brxe-dbcol) narrows to a plain sidebar width instead of leaving a
   large empty gap where its now-hidden tab-content pane used to sit, and
   My Listings (#brxe-dbsid) takes the freed space. Tab views are
   completely untouched — both columns keep showing side by side exactly
   as before.

   ── Mobile (<=768px) ──────────────────────────────────────────────────
   Unchanged from v0.1.155: the grid (#brxe-dbgrd) is already a single
   column at this width (page 8's own _cssCustom), so tab views hide My
   Listings entirely to show only the selected tab's panel.
   ========================================================================== */

body.uwp_account_page.hp-account-view-overview #brxe-dbcol .uwp_widget_account .col-lg-9 {
	display: none;
}

/* UsersWP always marks "Edit Account" active when no ?type= is set
   (uwp_add_account_menu_links() defaults internally to 'account'), which
   would otherwise show it in the active brand-blue color (--bs-link-color,
   themed to --hp-blue sitewide) while My Listings — not the Edit Account
   panel — is what's actually visible. Reset to the same token normal
   nav-links use, and give that same active look to Account Home instead,
   since UsersWP has no concept of our synthetic 'account-home' tab_id and
   can never mark it active itself.

   v0.1.157: ayecode-ui also styles ANY .nav-link.active with
   `pointer-events:none;cursor:default` (its own "you're already on this
   tab" affordance) — harmless on a real tab's own page, but on the
   overview page it silently disabled real mouse/touch clicks on "Edit
   Account" (UsersWP still marks it active here even though its panel is
   hidden), while .click()-style checks and keyboard activation kept
   working, masking the break in earlier verification. Restoring
   pointer-events/cursor here, alongside the color reset above, is the
   fix — not a JS click handler or forced redirect. */
/* SO9 (v0.1.181): the colour token only — was --bs-nav-link-color (#454056),
   a Bootstrap value that left this one item a different dark to every other
   nav link (#2B3038). Now the HomePezzo ink token, so all ten inactive
   destinations read as one set. The pointer-events/cursor restoration below
   is the v0.1.157 correction and is UNCHANGED. */
body.uwp_account_page.hp-account-view-overview .uwp-account-account.active {
	color: var(--hp-ink, #2B3038);
	pointer-events: auto;
	cursor: pointer;
}

body.uwp_account_page.hp-account-view-overview .uwp-account-account-home {
	color: var(--hp-blue, #315E9E);
}

@media (min-width: 769px) {

	body.uwp_account_page.hp-account-view-overview #brxe-dbgrd {
		grid-template-columns: 280px 1fr !important;
	}

	/* col-lg-3 is normally 25% of #brxe-dbcol, sized to sit beside the
	   now-hidden col-lg-9. With that sibling gone and #brxe-dbcol itself
	   narrowed above, let the nav column use the full (now sidebar-width)
	   track instead of clipping to a quarter of it. */
	body.uwp_account_page.hp-account-view-overview #brxe-dbcol .uwp_widget_account .col-lg-3 {
		flex: 0 0 100%;
		max-width: 100%;
	}

}

@media (max-width: 768px) {

	body.uwp_account_page.hp-account-view-tab #brxe-dbsid {
		display: none;
	}

}
