/* ============================================================
   Dot Experience — WooCommerce My Account
   ============================================================
   Restyles the classic My Account templates
   (woocommerce/myaccount/*.php, woocommerce/order/order-details.php)
   using this theme's design tokens (assets/css/tokens.css). Only
   loaded on the My Account endpoints — see dot_experience_styles()
   in functions.php — since nothing else on the site needs it.

   This file targets WooCommerce's own stable class names
   (.woocommerce-MyAccount-*, .woocommerce-orders-table, etc.) rather
   than duplicating markup, per this theme's "restyle via class-name
   targeting" convention for anything not using ACF blocks.

   Because this theme declares block-theme support, WooCommerce serves
   its block-theme CSS stack on these pages — woocommerce-blocktheme.css,
   woocommerce-layout.css, woocommerce-smallscreen.css, and the
   twenty-twenty-three.css companion (see functions.php). Several of
   those carry high-specificity rules (My Account nav, order-actions
   buttons); where this file has to win over one, the selector is
   deliberately built to out-specify it and a comment records which
   rule/where. That's the same specificity-fight pattern base.css and
   woocommerce-shop.css already document, not a new one.
   ============================================================ */

body.woocommerce-account .woocommerce-MyAccount-navigation,
body.woocommerce-account .woocommerce-MyAccount-content {
	font-size: var(--step-0);
	color: var(--ink);
}

body.woocommerce-account .woocommerce-MyAccount-content :is(p:not(.form-row), ul, ol) {
	font-size: var(--body-copy-size);
}

.woocommerce-account .form-row label {
	font-size: var(--wp--preset--font-size--medium);
}

/* ---- Layout: nav + content side by side on wider screens ----
   The container is a wrapping flexbox: below the md (768px) breakpoint
   each column takes a whole row (flex-basis 100%) so they stack, nav
   above content — the correct mobile order. At md+ the nav becomes a
   fixed rail and the content column fills the remaining width.

   ROOT CAUSE of the earlier stacked-at-desktop bug fixed here: the
   content column was `flex: 1 1 auto`. With `auto`, its flex-basis
   resolves to the column's own max-content width — and the order-
   history table is wide. Because the container also wraps (needed for
   the mobile stack), the flex line-breaking step measured the rail
   (260px) + the content column (wide `auto` basis) as too big for one
   row and pushed the content onto its own line *below* the rail before
   any shrinking could occur — leaving the dead space to the right of
   the rail. Giving the content column `flex: 1 1 0` takes its intrinsic
   width out of the line-break math, so it always shares the first row
   with the rail and then grows to fill what's left; `min-width: 0` lets
   the wide table shrink inside it.

   `:not(.dot-myaccount-login)` is required here — the `[woocommerce_my_
   account]` shortcode wraps its output in a plain `.woocommerce` div on
   EVERY endpoint, including the bare logged-out login screen (templates/
   page-my-account.html), which has no nav rail at all. Without this
   exclusion this rule turned that div's own children (the notices
   wrapper, the "Login" <h2>, and the login <form>) into flex-wrap
   siblings, which is the confirmed root cause of the "Login heading
   floats beside the username field" bug — verified live via DevTools
   (computed display: flex on that div) before this fix, not assumed from
   the CSS alone. */
body.woocommerce-account:not(.dot-myaccount-login) .woocommerce {
	display: flex;
	flex-wrap: wrap;
	gap: var(--r-lg);
	align-items: flex-start;
}

/* Two WooCommerce companion-stylesheet rules together pinned the account
   content narrower than the rest of the site, leaving dead space to the
   right of the whole two-column block on wide screens:

   1. twenty-twenty-three.css caps the page's <main> at
      `.woocommerce-page main { max-width: calc(1000px + root padding) }`
      (~1056px) — WooCommerce's readability cap for its pages.
   2. woocommerce-blocktheme.css then caps the container itself at
      `.woocommerce-account main .woocommerce { max-width: 1000px }`.

   The rest of the site sizes its main content to the theme's 1240px
   content width (theme.json contentSize/wideSize = 1240; the `.shell`
   convention in base.css, used by the Shop and front-page templates).
   Lift the <main> cap so the account content can reach that width, and
   pin the container to the same 1240px token so it matches — rather than
   overshooting to the full viewport. Both overrides out-specify the
   WooCommerce rules (body + main prefixes). */
body.woocommerce-account main {
	max-width: none;
}

body.woocommerce-account main .woocommerce {
	max-width: var(--wp--style--global--content-size, 1240px);
	margin-inline: auto;
}

/* Keep the "My account" page title lined up with the content column
   below it. WooCommerce's companion stylesheet caps the post title near
   1000px, so once the content was widened to the full 1240px column the
   title was left floating inset from it. Mirror entry-content's own
   sizing model exactly — a full-width box carrying the root padding, with
   the inner text centered at the content size — so the title's text
   column matches .woocommerce's left/right edges at every viewport
   (verified: content-left, not padding-inset).

   `:not(.dot-myaccount-login)` is required for the same reason as the
   `.woocommerce` flex rule above: this selector was written for the
   two-column dashboard, but `body.woocommerce-account` matches the bare
   login screen too. There, `.wp-block-post-title` is a direct flex item of
   `.dot-myaccount-login__content-col` (flex-direction: column) — the
   `margin-inline: auto` below isn't a no-op block centering there, it's a
   flex cross-axis auto-margin, which centers the title using its own
   (narrow, max-content) width inside the 560px column instead of leaving
   it flush with the form fields below it. Confirmed live: without this
   exclusion the heading sat ~70px further right than `.dot-wordmark` and
   the login form fields at 1440–1920px viewports. */
body.woocommerce-account:not(.dot-myaccount-login) main .wp-block-post-title {
	max-width: calc(
		var(--wp--style--global--content-size, 1240px) +
		var(--wp--style--root--padding-left, 28px) +
		var(--wp--style--root--padding-right, 28px)
	);
	margin-inline: auto;
	padding-inline: var(--wp--style--root--padding-left, 28px) var(--wp--style--root--padding-right, 28px);
	box-sizing: border-box;
}

/* Site notices span the full width of the container as their own row
   above the two columns, so an (empty) notices wrapper doesn't sit
   between the rail and content eating into the row's flex gaps; when
   empty it collapses out entirely so it adds no stray gap above. */
body.woocommerce-account .woocommerce > .woocommerce-notices-wrapper {
	flex: 0 0 100%;
}

body.woocommerce-account .woocommerce > .woocommerce-notices-wrapper:empty {
	display: none;
}

body.woocommerce-account .woocommerce-MyAccount-navigation {
	flex: 0 0 100%;
}

body.woocommerce-account .woocommerce-MyAccount-content {
	flex: 1 1 100%;
	min-width: 0;
}

@media (min-width: 768px) {
	body.woocommerce-account .woocommerce-MyAccount-navigation {
		flex: 0 0 260px;
		/* Keep the rail in view while a long orders/downloads list
		   scrolls. The offset clears the sticky site header (its nav
		   tier is ~72px once the utility bar tucks away — see base.css
		   "Main nav: sticky"). */
		position: sticky;
		top: 5.5rem;
	}

	body.woocommerce-account .woocommerce-MyAccount-content {
		flex: 1 1 0;
	}
}

/* ---- Account navigation ----
   A padded panel of individually-rounded rows with no inter-item
   dividers. The current page is a solid jet (--accent) row; the others
   get a quiet hover fill. This follows the theme's rounded / hairline /
   fill-for-emphasis language rather than WooCommerce's default bordered
   list. */
body.woocommerce-account .woocommerce-MyAccount-navigation ul {
	list-style: none;
	margin: 0;
	padding: 0.5rem;
	display: flex;
	flex-direction: column;
	gap: 0.375rem;
	border: 1px solid var(--line);
	border-radius: var(--r-md);
	background: var(--surface);
}

body.woocommerce-account .woocommerce-MyAccount-navigation li {
	/* Reset the stray bottom padding WooCommerce's twenty-twenty-three
	   companion stylesheet puts on these <li>s, which was making the
	   rows unevenly tall. */
	margin: 0;
	padding: 0;
}

body.woocommerce-account .woocommerce-MyAccount-navigation a {
	display: flex;
	align-items: center;
	min-height: 44px; /* comfortable click/touch target (WCAG 2.5.5) */
	padding: 0.6rem 0.9rem;
	border-radius: var(--r-sm);
	text-decoration: none;
	color: var(--ink);
	font-weight: 500;
	transition: background-color var(--motion-med) var(--ease), color var(--motion-med) var(--ease);
}

/* Hover only on rows that aren't the current page (the current row is
   already filled; swapping its background on hover would just flicker). */
body.woocommerce-account .woocommerce-MyAccount-navigation li:not(.is-active) a:hover {
	background: var(--placeholder-base);
}

/* Current page — matches both the `is-active` class WooCommerce puts on
   the <li> and the aria-current="page" attribute on the <a> itself, so
   the visual state can't drift from what's announced to assistive tech.
   The current page is ALSO conveyed by that aria-current (verified
   present live), so this jet fill is an enhancement of a non-color
   signal, not the only signal (WCAG 1.4.1). */
body.woocommerce-account .woocommerce-MyAccount-navigation li.is-active a,
body.woocommerce-account .woocommerce-MyAccount-navigation a[aria-current='page'] {
	background: var(--accent);
	color: var(--accent-ink);
	font-weight: 600;
}

/* Suppress the literal "> " that WooCommerce's twenty-twenty-three
   companion stylesheet injects before the active item — its rule is
   `.woocommerce-account .woocommerce .woocommerce-MyAccount-navigation
   li.is-active a::before { content: "> " }` at specificity (0,4,3).
   Prefixing `body` here reaches (0,4,4) to reliably win. The jet fill
   above is the current-page treatment now; the "> " read awkwardly and
   was redundant with aria-current for screen-reader users. */
body.woocommerce-account .woocommerce .woocommerce-MyAccount-navigation li.is-active a::before {
	content: none;
}

/* ---- Content card ---- */
body.woocommerce-account .woocommerce-MyAccount-content > *,
body.woocommerce-account .u-column1.col-1,
body.woocommerce-account .u-column2.col-2 {
	background: var(--surface);
}

body.woocommerce-account .woocommerce-MyAccount-content {
	background: var(--surface);
	border: 1px solid var(--line);
	border-radius: var(--r-md);
	padding: var(--r-lg);
}

body.woocommerce-account .woocommerce-MyAccount-content h2 {
	font-size: var(--step-1);
	letter-spacing: var(--letter-spacing-display);
	margin-top: 0;
}

/* ---- Notices ---- */
body.woocommerce-account .woocommerce-message,
body.woocommerce-account .woocommerce-info,
body.woocommerce-account .woocommerce-error {
	border-top-color: var(--accent);
	background: var(--placeholder-base);
	color: var(--ink);
	border-radius: var(--r-sm);
}

/* ---- Tables: order history + order line-items ----
   The content panel is already a bordered card, so the table drops its
   own box (no "border inside a border") and reads as clean, hairline-
   ruled data. Column headers use this theme's eyebrow-label language
   (small, uppercase, tracked, underlined) instead of a filled header
   bar. First/last cells sit flush with the card's padding edge. */
body.woocommerce-account table.shop_table {
	width: 100%;
	border-collapse: collapse;
	border: none;
}

body.woocommerce-account table.shop_table th,
body.woocommerce-account table.shop_table td {
	padding: 1em 1.1em;
	border-bottom: 1px solid var(--line);
	text-align: left;
	vertical-align: middle;
}

body.woocommerce-account table.shop_table th:first-child,
body.woocommerce-account table.shop_table td:first-child {
	padding-left: 0;
}

body.woocommerce-account table.shop_table th:last-child,
body.woocommerce-account table.shop_table td:last-child {
	padding-right: 0;
}

body.woocommerce-account table.shop_table thead th {
	background: none;
	color: var(--muted);
	font-size: var(--step--1);
	font-weight: 700;
	text-transform: uppercase;
	letter-spacing: 0.08em;
	border-bottom: 1.5px solid var(--ink);
	white-space: nowrap;
}

body.woocommerce-account table.shop_table tbody tr:last-child td,
body.woocommerce-account table.shop_table tbody tr:last-child th {
	border-bottom: none;
}

/* Subtle row highlight for scannability — pointer devices only, so it
   never sticks after a tap on touch screens. */
@media (hover: hover) {
	body.woocommerce-account table.shop_table tbody tr:hover td,
	body.woocommerce-account table.shop_table tbody tr:hover th {
		background: var(--placeholder-base);
	}
}

/* Order number is the row's identifier — give it weight. */
body.woocommerce-account .woocommerce-orders-table__cell-order-number a {
	font-weight: 700;
	color: var(--ink);
}

/* Responsive stacked rows (shop_table_responsive) use data-title as a
   generated per-row label — match it to the eyebrow-label treatment and
   the token palette instead of the WooCommerce companion stylesheet's
   default gray. Breakpoint matches WooCommerce's own table collapse
   (max-width: 768px) so the label styling and the stack begin together
   (the previous 600px value left 600–768px labeled in the default gray). */
@media (max-width: 768px) {
	body.woocommerce-account table.shop_table_responsive tr td,
	body.woocommerce-account table.shop_table_responsive tr th {
		padding-left: 0;
		padding-right: 0;
	}

	body.woocommerce-account table.shop_table_responsive tr td::before,
	body.woocommerce-account table.shop_table_responsive tr th::before {
		color: var(--muted);
		font-size: var(--step--1);
		font-weight: 700;
		text-transform: uppercase;
		letter-spacing: 0.06em;
	}

	/* WooCommerce's smallscreen stylesheet hides the order-number row
	   header (<th>) on narrow screens — which removes the one field that
	   tells the orders apart. Restore it as the lead line (heading) of
	   each stacked order block. `!important` is needed to beat Woo's own
	   `display: none` rule (the same documented Woo-specificity-fight
	   pattern used elsewhere in this theme). No data-title label is added:
	   "#447" reads as a self-evident heading, and Woo generates the
	   data-title ::before for <td> only, not <th>, so there's none to
	   suppress. */
	body.woocommerce-account .woocommerce-orders-table.shop_table_responsive tbody th.woocommerce-orders-table__cell-order-number {
		display: block !important;
		margin-bottom: 0.25rem;
	}

	body.woocommerce-account .woocommerce-orders-table__cell-order-number a {
		font-size: var(--step-0);
	}
}

/* ---- Addresses ---- */
body.woocommerce-account .woocommerce-Address {
	background: var(--surface);
	border: 1px solid var(--line);
	border-radius: var(--r-sm);
	padding: 1.25em;
}

body.woocommerce-account .woocommerce-Address-title {
	display: flex;
	align-items: baseline;
	justify-content: space-between;
	gap: 1em;
}

body.woocommerce-account .woocommerce-Address-title h2 {
	font-size: var(--step-0);
	margin: 0;
}

/* ---- Forms (edit account, addresses, login/register) ---- */
body.woocommerce-account fieldset {
	border: 1px solid var(--line);
	border-radius: var(--r-sm);
	padding: 1.25em;
	margin: 0 0 1.5em;
}

body.woocommerce-account fieldset legend {
	padding: 0 0.5em;
	font-weight: 600;
	color: var(--ink);
}

body.woocommerce-account .form-row label {
	display: block;
	margin-bottom: 8px;
	font-size: 1.25rem;
	font-weight: 300;
	color: var(--field-label);
}

body.woocommerce-account .woocommerce-Input,
body.woocommerce-account select,
body.woocommerce-account textarea,
body.woocommerce-account .woocommerce form .form-row .input-text,
body.woocommerce-account .woocommerce form .form-row select {
	background: transparent;
	color: var(--ink);
	border: 2pt solid var(--field-border);
	border-radius: 40px;
	min-height: 56px;
	padding: 7px 21px;
	font-size: 1.125rem;
	width: 100%;
	max-width: 100%;
}

body.woocommerce-account textarea {
	padding: 18px 21px;
	border-radius: 30px;
}

@media (min-width: 768px) {
	body.woocommerce-account textarea {
		border-radius: 40px;
	}
}

/* ---- Buttons: match the site's pill CTAs ----
   Everything WooCommerce renders with `.button` / submit in the account
   area becomes a pill (9999px), consistent with base.css's sitewide
   button language, instead of the rounded rectangle this file used
   before. This is the SOLID variant (jet fill), used by the form submit
   buttons (Save changes, Save address), pagination (Previous / Next),
   the "Browse products" empty-state button, and — as the default — any
   order action not given a lighter variant below. */
body.woocommerce-account .button,
body.woocommerce-account button[type='submit'] {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	gap: 0.4rem;
	background: var(--btn-primary-bg);
	color: var(--btn-primary-ink);
	border: 1.5px solid var(--btn-primary-bg);
	border-radius: 60px;
	padding: 0.6em 1.35em;
	font-weight: 500;
	line-height: 1.2;
	white-space: nowrap;
	cursor: pointer;
	transition: background-color var(--motion-med) var(--ease),
		color var(--motion-med) var(--ease),
		border-color var(--motion-med) var(--ease),
		transform var(--motion-med) var(--ease);
}

body.woocommerce-account .button:where(:not(.view, .cancel, .disabled, :disabled)):hover,
body.woocommerce-account button[type='submit']:where(:not(.view, .cancel, .disabled, :disabled)):hover {
	background: var(--btn-primary-hover-bg);
	color: var(--btn-primary-ink);
	border-color: var(--btn-primary-hover-bg);
	text-decoration: underline;
	text-decoration-thickness: 1px;
	text-underline-offset: 5px;
}

/* Hover lift is inherited from base.css's canonical .button:hover
   (translateY(-2px), reduced-motion-gated) — no local override here, so
   account buttons lift exactly like every other button sitewide. (Was a
   bespoke translateY(-1px) that also skipped the reduced-motion gate.)
   The order-action View/Cancel variants below add their own fill/tint on
   top of that shared lift. */

body.woocommerce-account .button:active,
body.woocommerce-account button[type='submit']:active {
	transform: scale(0.98);
}

/* ---- Order-history action buttons ----
   Up to three actions per row (Pay / View / Cancel). Give them a clear,
   restrained hierarchy instead of a column of identical black blocks:
   Pay stays the solid jet pill (the money action), View is an outline
   pill (the common, benign action), Cancel is a quiet ghost pill.

   `display: inline-flex !important` is needed to beat the block-theme /
   twenty-twenty-three stylesheets, which force these specific buttons to
   `display: block` at specificity up to (0,4,4) — e.g. `.woocommerce-page
   table.shop_table_responsive tbody td.woocommerce-orders-table__cell-
   order-actions a.button`. Left as block they stretched to fill the whole
   Actions cell. This is the same documented `!important`-to-win-a-Woo-
   specificity-fight pattern used in base.css and woocommerce-shop.css. */
body.woocommerce-account .woocommerce-orders-table__cell-order-actions .button {
	display: inline-flex !important;
	width: auto;
	padding: 0.5em 1.1em;
	font-size: var(--step--1);
}

/* Small horizontal gap between adjacent action pills. Margin (not flex
   gap) because the cell must stay a real table-cell for column
   alignment; the orders table only ever shows 1–3 short actions, so
   these sit on one row and never wrap into a vertical collision. */
body.woocommerce-account .woocommerce-orders-table__cell-order-actions .button + .button {
	margin-left: 0.5rem;
}

/* View — outline pill (surface fill, ink text + border). */
body.woocommerce-account .woocommerce-orders-table__cell-order-actions .button.view {
	background: var(--surface);
	color: var(--btn-secondary-ink);
	border: 2px solid var(--btn-primary-bg);
}

body.woocommerce-account .woocommerce-orders-table__cell-order-actions .button.view:hover {
	background: var(--ink);
	color: var(--bg);
}

/* Cancel — quiet ghost pill (hairline border, ink text). Kept high-
   contrast (ink on surface) and de-emphasized by the absence of a fill
   rather than by dimming the text, so it stays legible (WCAG 1.4.3). */
body.woocommerce-account .woocommerce-orders-table__cell-order-actions .button.cancel {
	background: var(--surface);
	color: var(--ink);
	border-color: var(--line);
}

body.woocommerce-account .woocommerce-orders-table__cell-order-actions .button.cancel:hover {
	background: var(--placeholder-base);
	border-color: var(--ink);
}

/* ---- Login / Register two-column layout ---- */
body.woocommerce-account #customer_login.col2-set {
	display: flex;
	flex-wrap: wrap;
	gap: var(--r-lg);
}

body.woocommerce-account #customer_login .u-column1,
body.woocommerce-account #customer_login .u-column2 {
	flex: 1 1 280px;
	min-width: 0;
}

/* ---- Accessibility: visible keyboard focus ----
   The WooCommerce companion stylesheet does not draw a strong focus
   ring of its own on these classic-template controls. This makes
   keyboard focus clearly visible using the same 3px --focus ring as the
   global :focus-visible rule in base.css (was 2px here — now matched, so
   every button variant focuses identically). The 2px offset places the
   ring on the surrounding surface, so it stays visible even on the
   jet-filled current nav row (the ring lands outside the fill, on the
   panel behind it) in all three theme variants. */
body.woocommerce-account input:where(:not([type="checkbox"], [type="radio"], [type="submit"], [type="button"])):focus-visible,
body.woocommerce-account select:focus-visible,
body.woocommerce-account textarea:focus-visible {
	outline: 3px dashed var(--focus-outline);
	outline-offset: 2px;
}

body.woocommerce-account a:focus-visible,
body.woocommerce-account button:focus-visible,
body.woocommerce-account input:where([type="checkbox"], [type="radio"], [type="submit"], [type="button"]):focus-visible {
	outline: 3px solid var(--focus);
	outline-offset: 2px;
}

/* ============================================================
   Modern login screen (templates/page-my-account.html, bare logged-out
   /my-account/ root only)
   ============================================================
   Scoped entirely to `body.dot-myaccount-login`, the class
   inc/myaccount-template.php adds only when the logged-out template is
   the one actually resolved for the bare My Account root (never present
   for the logged-in dashboard, which keeps the two-column nav-rail rules
   above completely untouched, and never present for sibling logged-out
   endpoints like lost-password/reset-password/registration, which now
   fall through to the generic page.html treatment instead).

   STRUCTURE: templates/page-my-account.html's <main> carries `align:full`
   plus this theme's plain custom-group convention (no core/columns —
   see hero-shop-spotlight/style.css for the same "plain wp:group +
   className" pattern used for one-off asymmetric layouts elsewhere in
   this theme) so it can bleed to the true viewport edge, matching the
   header's own alignfull bars (parts/header.html, dot-utility-bar /
   dot-main-nav). Two children: `.dot-myaccount-login__content-col` (just
   post-content — the page's own title block was removed per client
   request, 2026-07-13, so nothing but the login/register form renders,
   rendered by WooCommerce's [woocommerce_my_account]
   shortcode) and `.dot-myaccount-login__image-col` (the placeholder
   image), turned into a two-track CSS grid below so the image column can
   reach the real right edge of the viewport instead of stopping at the
   1240px content container like every other section on the site. */
body.dot-myaccount-login main {
	display: grid;
	grid-template-columns: minmax(0, 1fr) minmax(360px, 42%);
	column-gap: clamp(2rem, 5vw, 4rem);
	max-width: none;
	margin-top: var(--wp--preset--spacing--50);
	margin-bottom: 0;
}

/* "Closer to a full-viewport-height app screen than a compact contained
   card" (brief). 132px approximates the header's combined height
   (.dot-utility-bar's 44px min-height + .dot-main-nav's 72px min-height,
   plus hairline borders) so the screen reads as filling the rest of the
   viewport without actually measuring the live header via JS. Clamped
   between a 560px floor (so short viewports/zoomed text never crush the
   form) and a 900px ceiling (so ultra-tall monitors don't stretch the
   placeholder image into an absurd column). Grid's default
   `align-content: normal` computes to `stretch` for auto-sized tracks, so
   the single implicit row — and every item in it — fills this height
   automatically; no extra `height`/`align-items` rule needed. Desktop/
   tablet only (see breakpoint below) — a phone-width single column form
   doesn't want to be stretched to near-viewport height with mostly empty
   space beneath it. */
@media (min-width: 700px) {
	body.dot-myaccount-login main {
		min-height: clamp(560px, calc(100dvh - 132px), 900px);
	}
}

/* Content column: flex, capped to a comfortable measure so the
   login/register form doesn't stretch edge-to-edge on the wide track next
   to it.

   BUG FIX (2026-07-22): was `justify-content: center`, vertically centering
   the form within the (often much taller-than-its-content) grid row. Per
   client report, this put the "Login" heading and fields ~500px down the
   page — well below the fold — instead of near the top of the viewport
   as intended by the "closer to a full-viewport-height app screen" brief
   below. Changed to `flex-start` so the form anchors to the top of the
   column (below its own padding-block) regardless of how tall the row
   ends up being, matching how the client described wanting this to look.
   (This was compounded by a second bug — the image column's own intrinsic
   height was inflating the row far past main's intended clamp — fixed
   separately in the image-col/image rules below.)

   Left inset: match the header logo/nav's ACTUAL rendered left edge, not
   `.shell`'s own clamp(1.25rem, 4vw, 3rem) padding-inline. Verified live via
   getBoundingClientRect(): `.dot-wordmark` sits at exactly (100vw - 1240px)
   / 2 from the true viewport edge (340px at a 1920px viewport) — NOT that
   offset plus `.shell`'s clamp padding. That's because `.dot-main-nav__inner`
   / `.dot-utility-bar .shell` deliberately zero `.shell`'s own padding-inline
   (base.css, "Cancel `.shell`'s own padding-inline... in the header", 2026-
   07-12) — the header relies solely on the root has-global-padding (fixed
   28px) plus centering, and the two symmetric-padding terms happen to cancel
   out algebraically, leaving pure `(100vw - 1240px) / 2` once the viewport
   is wider than the content size. This grid's `main` carries no
   has-global-padding of its own (by design, so the image column can bleed
   to the true edge), so the content column has to supply both terms itself:
   the same centering offset, floored at the root gutter (28px) for
   viewports at/under 1240px + gutter, where centering hasn't kicked in.
   Confirmed live: heading/login form left edge now matches `.dot-wordmark`
   left edge exactly at 1920px and 1440px.

   BUG FIX (2026-07-13): this theme inherits WordPress core's global
   `html { box-sizing: border-box } *, *::before, *::after { box-sizing:
   inherit }` reset (wp-includes/css/dist/block-library/style.css) — confirmed
   live via getComputedStyle. That means the `max-width: 560px` above caps the
   ENTIRE border-box, padding included, not just the readable content. At a
   1920px viewport the left inset alone is 340px, so 560 - 340 - 48(end
   padding) left only ~172px for the heading/inputs — the reported "smushed"
   layout (heading wrapping mid-word, ~170px-wide inputs).

   Fix: keep the sitewide border-box convention (don't override box-sizing
   locally — this element's children, including the login form's inputs/
   buttons, would inherit that override too via the `inherit` chain above,
   which is a bigger blast radius than this one bug), and instead fold the
   two padding expressions into `max-width` itself so the border-box grows to
   accommodate them while the actual content measure stays a true 560px
   regardless of viewport. Both the padding rules and max-width read from the
   same two custom properties so the numbers can't drift apart. */
body.dot-myaccount-login .dot-myaccount-login__content-col {
	--dot-myaccount-login-pad-start: max(
		var(--wp--style--root--padding-left, 28px),
		calc((100vw - var(--wp--style--global--content-size, 1240px)) / 2)
	);
	--dot-myaccount-login-pad-end: clamp(1.25rem, 4vw, 3rem);
	display: flex;
	flex-direction: column;
	justify-content: flex-start;
	max-width: calc(
		560px + var(--dot-myaccount-login-pad-start) + var(--dot-myaccount-login-pad-end)
	);
	padding-inline-start: var(--dot-myaccount-login-pad-start);
	padding-inline-end: var(--dot-myaccount-login-pad-end);
	padding-block: clamp(2rem, 6vw, 3.5rem);
}

/* The login/register form renders inside core's post-content block
   (`.entry-content.wp-block-post-content`), which carries its own
   `has-global-padding` class and therefore its own 28px padding-left/right —
   stacking on top of the content column's own inset above and pushing the
   form 28px further right than the "My account" heading beside it
   (confirmed live via getBoundingClientRect: heading at the shell inset,
   form 28px further in). That class exists for post-content used as
   ordinary full-width page content; here it's nested inside an already-
   padded, deliberately narrow (max-width: 560px) column, so its own padding
   is pure double-counting. Zeroed the same way `.dot-utility-bar .shell` /
   `.dot-main-nav__inner` cancel `.shell`'s padding in the header (base.css)
   — one of these two padding sources should win, not both. */
body.dot-myaccount-login .dot-myaccount-login__content-col .entry-content.wp-block-post-content {
	padding-inline: 0;
}

/* Image column: a plain grid item, stretched to the row's full height by
   the default `align-content: stretch` behavior noted above.

   BUG FIX (2026-07-22): "stretched to the row's full height" was never
   actually true once a real (portrait, 2400x4267) photo replaced the
   placeholder — confirmed live via getBoundingClientRect at 1440x900: the
   grid row (main) rendered at ~1105px tall, blowing straight through the
   560-900px clamp() on main's min-height (woocommerce-myaccount.css
   ~line 591), and the login form — vertically centered in that oversized
   column, see the content-col fix below — ended up ~500px down the page,
   which is exactly the client-reported "login is below the fold" bug.

   Root cause: grid row tracks are sized *before* align-content stretch is
   applied, using each item's own normal-flow content. The `<img>` (below)
   had `height: 100%`, but percentages can't resolve against an
   indefinite/auto-sizing row, so browsers fall back to computing its
   height from its intrinsic aspect ratio instead — a 605px-wide portrait
   photo at that ratio is ~1076px tall, which is what actually drove the
   row (and therefore `main`, and the sibling content-col) to ~1105px,
   overriding the intended viewport-based clamp entirely.

   Fix: `position: relative` here so the `<img>` can be pulled out of
   normal flow below. Out-of-flow (absolutely positioned) descendants
   don't contribute to a grid item's intrinsic content size, so the row
   goes back to being sized only by `main`'s own min-height clamp, and the
   image just fills whatever height that clamp resolves to. */
body.dot-myaccount-login .dot-myaccount-login__image-col {
	position: relative;
	min-width: 0;
}

/* Real photo (swapped in 2026-07-13 — was a diagonal-stripe "no photo yet"
   placeholder, the same device used for the Shop landing heroes in
   blocks/hero-shop-spotlight/style.css, .dot-hero-shop-spotlight__image--
   placeholder; that placeholder rule and its --placeholder modifier class
   are removed now that a real <img> is in templates/page-my-account.html).

   BUG FIX (2026-07-22): switched from being a normal-flow grid item sized
   via `width/height: 100%` to `position: absolute; inset: 0` filling the
   now-`position: relative` column above. See that rule's comment for why:
   this photo's own tall intrinsic aspect ratio was inflating the whole
   grid row past the intended viewport-based clamp. Taking it out of flow
   removes it from the row's intrinsic-size computation entirely, so it
   just paints inside whatever box the column ends up being — still
   `object-fit: cover` + centered `object-position` to crop rather than
   distort, matching how the placeholder's background-color/-image
   previously filled the same box. The right edge is flattened (no
   border-radius, no border) because that edge is the true viewport edge,
   not a card boundary sitting on the page's own background. */
body.dot-myaccount-login .dot-myaccount-login__image {
	display: block;
	position: absolute;
	inset: 0;
	width: 100%;
	height: 100%;
	min-height: 320px;
	object-fit: cover;
	object-position: center;
	border-radius: var(--r-lg) 0 0 var(--r-lg);
	border: 1px solid var(--line);
	border-right: none;
}

/* Below 700px the image column isn't the point of a narrow-viewport login
   screen — drop it (and fall back to a single grid track) so the form is
   what visitors scroll to first, full width and unconstrained by the
   636px measure cap above. Matches the min-width gate on the tall
   min-height rule above, so the two behaviors (drop the image / stop
   forcing tall) change together at one breakpoint instead of two. */
@media (max-width: 699px) {
	body.dot-myaccount-login main {
		grid-template-columns: 1fr;
	}

	body.dot-myaccount-login .dot-myaccount-login__image-col {
		display: none;
	}

	body.dot-myaccount-login .dot-myaccount-login__content-col {
		max-width: none;
		padding-inline-end: var(--wp--style--root--padding-right, 28px);
	}
}

/* ---- Login form polish ----
   Beyond the sitewide baseline above (.woocommerce-Input, .button), this
   dedicated screen gets a bit more room to breathe and a stronger sense
   of a real "app" surface: taller inputs, a full-width primary action,
   and an extra focus glow layered on top of (never replacing) the
   sitewide `:focus-visible` outline rule so the accessibility-critical
   keyboard-focus indicator is unchanged.

   `#customer_login.col2-set` never actually renders on this store today
   — that markup only exists when My Account registration is enabled
   (woocommerce/templates/myaccount/form-login.php), and it's currently
   off, so the shortcode outputs a flat `.woocommerce > h2 + form`
   structure with no `#customer_login` wrapper at all (confirmed via the
   live DOM, not assumed). The rules below target that real, flat
   structure directly. The `#customer_login.col2-set` gap/margin rule
   further down this section is left in place, inert, for the day
   registration is turned back on — it costs nothing while unmatched. */
body.dot-myaccount-login .woocommerce {
	margin-top: clamp(1.5rem, 4vw, 2.5rem);
}

body.dot-myaccount-login .woocommerce > h2 {
	margin: 0 0 1.25rem;
	font-size: var(--step-1);
	font-weight: 800;
	letter-spacing: var(--letter-spacing-display);
}

body.dot-myaccount-login #customer_login.col2-set {
	gap: clamp(2rem, 5vw, 3rem);
	margin-top: clamp(1.5rem, 4vw, 2.5rem);
}

body.dot-myaccount-login .woocommerce-form-login .form-row,
body.dot-myaccount-login .woocommerce-form-register .form-row {
	margin-bottom: 1.1rem;
}

body.dot-myaccount-login .woocommerce-Input {
	padding: 0.85em 1em;
	font-size: var(--step-0);
	transition: border-color var(--motion-med) var(--ease),
		box-shadow var(--motion-med) var(--ease);
}

/* Supplemental focus glow — deliberately additive to, never a replacement
   for, the global 3px --focus outline (this file, "Accessibility: visible
   keyboard focus" above). That rule targets `:focus-visible` and must stay
   the accessibility-critical indicator; this rule only touches
   border-color/box-shadow, never `outline`, so it can't out-specify or
   suppress it on keyboard focus regardless of selector specificity. This
   is a softer, always-on (mouse or keyboard) tint so the field itself
   looks "lit up," matching the more app-like tone the rest of this screen
   is going for. `color-mix()` keeps the glow's hue matched to whichever of
   the three accessibility-preferences theme variants is active (--accent
   flips between jet black and off-white) without a separate override per
   variant; unsupported browsers simply skip the box-shadow. */
body.dot-myaccount-login .woocommerce-Input:focus {
	border-color: var(--accent);
	box-shadow: 0 0 0 4px color-mix(in srgb, var(--accent) 16%, transparent);
}

/* WooCommerce's core form-login.php template puts the "Remember me"
   checkbox+label, the login nonce field, AND the submit button all inside
   this ONE <p class="form-row"> — there's no separate row for the button.
   Flexing the row (needed to align the checkbox with its label) without
   accounting for the button squeezed the button and label into a shared
   row, which is the confirmed root cause of "Remember" / "me" wrapping
   onto two lines — the label was being flex-shrunk to make room for the
   button beside it (verified live: label rendered ~83px wide before this
   fix). `flex-wrap: wrap` plus giving the button `flex-basis: 100%` and a
   later `order` pushes it onto its own full-width line below the
   checkbox row instead, so the label keeps its natural (nowrap) width. */
body.dot-myaccount-login .woocommerce-form-login .form-row:has(input[type='checkbox']) {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 0.75rem 1rem;
}

body.dot-myaccount-login .woocommerce-form-login .form-row:has(input[type='checkbox']) label {
	display: flex;
	align-items: center;
	gap: 0.5rem;
	margin-bottom: 0;
	white-space: nowrap;
}

/* Submit + "Lost your password?" row: full-width primary button (a bigger,
   more deliberate tap target than the sitewide auto-width pill), with the
   secondary link given its own line below rather than crowding the
   button's trailing edge. `flex-basis: 100%` + `order` (only meaningful
   inside the flex row above, harmless no-ops for the register form's
   plain-block submit button) is what forces the button onto its own line
   under "Remember me" rather than beside it. */
body.dot-myaccount-login .woocommerce-form-login button[type='submit'],
body.dot-myaccount-login .woocommerce-form-register button[type='submit'] {
	width: 100%;
	padding: 0.85em 1.35em;
	font-size: var(--step-0);
	margin-bottom: 0.75rem;
}

body.dot-myaccount-login .woocommerce-form-login .form-row:has(input[type='checkbox']) button[type='submit'] {
	flex: 1 1 100%;
	order: 3;
}

body.dot-myaccount-login .woocommerce-LostPassword {
	margin: 0;
	font-size: var(--step--1);
}

/* Left-edge alignment bug (2026-07-13): WooCommerce auto-enqueues a
   block-theme compat stylesheet (assets/css/twenty-twenty-three.css) for
   any active block/FSE theme that doesn't opt out, and that file carries
   `.woocommerce-account .woocommerce-form-login { max-width: 516px;
   margin: 0 auto; }` — confirmed live via the page's actual matched CSS
   rules (document.styleSheets), not assumed. That centers the form at
   516px inside this screen's already-narrow 560px content column,
   producing a ~22px inset on both sides relative to the "Login" heading
   (a sibling `.woocommerce > h2`, unaffected by that compat rule), which
   is the reported leftover left-indent. This selector
   (`body.dot-myaccount-login .woocommerce-form-login`, specificity 0,2,1)
   already outweighs the compat rule's 0,2,0, so it wins regardless of
   stylesheet load order — no `!important` needed. Undoing both properties
   here rather than overriding just `margin-left` so the form also stops
   being artificially narrower than its column. */
body.dot-myaccount-login .woocommerce-form-login {
	max-width: none;
	margin: 0;
}
