/* =========================================================================
 * Account — address form: one card, underline fields, select2
 * =========================================================================
 * Owns: the edit-address form (woocommerce/templates/myaccount/form-edit-address.php)
 * and the select2 widgets for country and state, including their own narrow
 * media queries.
 *
 * Scoped to .woocommerce-address-fields, which only that template prints, so
 * nothing here can leak into checkout, login or the password form.
 *
 * The !important count in this file is high by design and documented at the
 * head of the section: it has to outrank the (0,4,1) input rules that
 * account-layout.css sets, and it does so by specificity plus important
 * where specificity alone is not enough.
 *
 * Loaded: account pages only, after account-dashboard.css
 *
 * Part of the account design system. Split out of a single 2135-line
 * account.css in stage 6 of the architecture work; the rules below are
 * unchanged, in their original order. The order matters: these files are
 * enqueued in sequence (theme -> layout -> dashboard -> address) and the
 * cascade between them is the cascade that used to live inside one file.
 * ========================================================================= */

/* =========================================================================
 * Edit-address form — one card, underline fields
 * =========================================================================
 * Scope: `.woocommerce-address-fields` is printed only by
 * woocommerce/templates/myaccount/form-edit-address.php, so nothing here can
 * leak into checkout, login or the password form.
 *
 * The whole form stays ONE card: the h2 WooCommerce prints inside <form> is
 * kept as the single title, the field wrapper becomes a two-column grid, and
 * there are no sub-sections, sub-headings or separators.
 *
 * Specificity: account.css already styles these inputs at (0,4,1) with
 * !important (`.mg-acc__dash .woocommerce-MyAccount-content .form-row …`).
 * Every rule below therefore carries `.mg-account .woocommerce-address-fields`
 * in front — (0,3,x) plus a later position, and !important where it must
 * win outright. Verified by counting selectors, not by guessing.
 * ========================================================================= */

/* --- the card itself ----------------------------------------------------- */
.mg-account .woocommerce-MyAccount-content .woocommerce-address-fields {
	/* Was 760px, a leftover from the single-address era: it left the form
	 * occupying two-thirds of a 1017px content column, with the whole gap
	 * falling on the reading side in RTL. The grid inside already caps the
	 * fields at a comfortable measure, so the card takes the full column. */
	max-width: none;
	width: 100%;
}

/* WooCommerce prints <form><h2>…</h2><div class="woocommerce-address-fields">.
 * The h2 is the only title on the page, so give it the store's display face
 * and let it breathe — no second heading is added anywhere. */
.mg-account .woocommerce-MyAccount-content form:has(.woocommerce-address-fields) > h2,
.mg-account .woocommerce-MyAccount-content .woocommerce-address-fields h2 {
	font-family: var(--mg-acc-font-display);
	font-weight: 500;
	font-size: var(--mg-acc-fs-h2);
	line-height: 1.4;
	letter-spacing: 0;
	color: var(--mg-acc-ink);
	margin: 0 0 var(--mg-acc-s-6);
	padding: 0 0 var(--mg-acc-s-4);
	border-bottom: 1px solid var(--mg-acc-line);
}

/* --- the grid ------------------------------------------------------------ */
.mg-account .woocommerce-address-fields__field-wrapper {
	display: grid;
	grid-template-columns: repeat(2, minmax(0, 1fr));
	gap: var(--mg-acc-s-5) var(--mg-acc-s-5);
	margin: 0;
}

/* WooCommerce wraps every field in <p class="form-row">. Inside a grid the
 * floats and widths the plugin sets would fight the columns. */
.mg-account .woocommerce-address-fields__field-wrapper > .form-row {
	float: none !important;
	width: 100% !important;
	clear: none !important;
	margin: 0 !important;
	padding: 0 !important;

	/* Labels wrap: "کدپستی (بدون فاصله و با اعداد انگلیسی)" needs three lines
	 * at half width while "تلفن" needs one. Left to itself that taller row
	 * pushed its underline below the neighbouring one, so the two fields in a
	 * row did not share a baseline. A column with the content pushed to the
	 * bottom pins every underline to the row edge regardless of label length. */
	display: flex;
	flex-direction: column;
	justify-content: flex-end;
}

/* Long values get the full row; short ones share. Keyed on WooCommerce's own
 * per-field id, so it holds whatever order the fields are registered in.
 *
 * City and street are deliberately NOT in this list. They share one row the
 * same way postcode and phone do below them: two half-width fields read as a
 * single address line instead of two separate questions, and 490px still
 * holds a full Iranian street address without wrapping. Removing them from
 * this list is enough -- grid auto-placement pairs them in DOM order. */
.mg-account .woocommerce-MyAccount-content .woocommerce-address-fields #billing_address_2_field,
.mg-account .woocommerce-MyAccount-content .woocommerce-address-fields #billing_company_field,
.mg-account .woocommerce-MyAccount-content .woocommerce-address-fields #billing_email_field,
.mg-account .woocommerce-MyAccount-content .woocommerce-address-fields #shipping_address_2_field,
.mg-account .woocommerce-MyAccount-content .woocommerce-address-fields #shipping_company_field {
	grid-column: 1 / -1;
}

/* --- the label ----------------------------------------------------------- */
/* Display face at 12.5px. The old label was 11.5px medium grey --muted on
 * white, which is roughly 2.4:1: legible only if you already know what it
 * says. It now carries near-black --ink at a weight the display font holds
 * properly, so the label reads as a signpost rather than a whisper. */
.mg-account .woocommerce-MyAccount-content .woocommerce-address-fields .form-row label {
	display: block;
	float: none;
	font-family: var(--mg-acc-font-display);
	font-size: 12.5px;
	font-weight: 500;
	letter-spacing: 0;
	color: var(--mg-acc-label);
	margin: 0 0 8px;
	line-height: 1.6;
	transition: color 0.18s ease;
}

/* The asterisk WooCommerce adds to required fields. Left as text, only
 * recoloured, so screen readers keep reading "required". Gold at 11px on white
 * is unreadable, so it uses the darkened accent cut. */
.mg-account .woocommerce-MyAccount-content .woocommerce-address-fields .form-row label .required {
	color: var(--mg-acc-accent-deep);
	text-decoration: none;
	font-weight: 600;
	margin-inline-start: 3px;
}

/* Label darkens when the field is in use. */
.mg-account .woocommerce-MyAccount-content .woocommerce-address-fields .form-row:focus-within label {
	color: var(--mg-acc-ink);
}

/* -------------------------------------------------------------------------
 * The field surface
 * -------------------------------------------------------------------------
 * Replaces the old hairline-under-the-text treatment. A bare 1px line under
 * each value left the eye with no target: on a white card there was nothing
 * to say "type here". Each control now sits on its own quietly tinted
 * surface with a hairline box, 54px tall.
 *
 * Sizing note: 54px is above the 44px touch floor and below the point where
 * the row starts to feel like a form on a bank website. It matches
 * --mg-acc-h-control, so the button and the fields share one rhythm.
 *
 * Focus is three layers on purpose: the surface turns white (the field
 * "opens"), the border goes solid ink (you are here), and a gold rule sits
 * inside the bottom edge with a soft gold halo (brand, without shouting).
 * ---------------------------------------------------------------------- */

.mg-account .woocommerce-MyAccount-content .woocommerce-address-fields input.input-text,
.mg-account .woocommerce-MyAccount-content .woocommerce-address-fields input[type="text"],
.mg-account .woocommerce-MyAccount-content .woocommerce-address-fields input[type="email"],
.mg-account .woocommerce-MyAccount-content .woocommerce-address-fields input[type="tel"],
.mg-account .woocommerce-MyAccount-content .woocommerce-address-fields select,
.mg-account .woocommerce-MyAccount-content .woocommerce-address-fields textarea {
	height: 54px !important;
	line-height: 1 !important;
	padding: 0 16px !important;
	border: 1px solid var(--mg-acc-field-border) !important;
	border-radius: var(--mg-acc-r-sm) !important;
	background-color: var(--mg-acc-field-bg) !important;
	box-shadow: none !important;
	color: var(--mg-acc-ink) !important;
	font-family: var(--mg-acc-font) !important;
	font-size: 15px !important;
	font-weight: 400 !important;
	width: 100%;
	max-width: 100%;
	outline: none !important;
	appearance: none;
	-webkit-appearance: none;
	direction: rtl;
	text-align: right;
	box-sizing: border-box;
	transition: background-color 0.18s ease, border-color 0.18s ease, box-shadow 0.18s ease;
}

/* Textarea keeps its own height; only the chrome above applies to it. */
.mg-account .woocommerce-MyAccount-content .woocommerce-address-fields textarea {
	height: auto !important;
	min-height: 108px;
	padding: 14px 16px !important;
	line-height: 1.85 !important;
	resize: vertical;
}

.mg-account .woocommerce-MyAccount-content .woocommerce-address-fields input.input-text:hover,
.mg-account .woocommerce-MyAccount-content .woocommerce-address-fields input[type="text"]:hover,
.mg-account .woocommerce-MyAccount-content .woocommerce-address-fields input[type="email"]:hover,
.mg-account .woocommerce-MyAccount-content .woocommerce-address-fields input[type="tel"]:hover,
.mg-account .woocommerce-MyAccount-content .woocommerce-address-fields select:hover,
.mg-account .woocommerce-MyAccount-content .woocommerce-address-fields textarea:hover {
	border-color: var(--mg-acc-field-border-hover) !important;
	background-color: var(--mg-acc-field-bg-hover) !important;
}

/* Focus. Repeated at full specificity because the theme's own
 * `.woocommerce form .form-row input.input-text` rule (0,4,1) sets
 * box-shadow:none and would otherwise strip the halo for keyboard users. */
.mg-account .woocommerce-MyAccount-content .woocommerce-address-fields input.input-text:focus,
.mg-account .woocommerce-MyAccount-content .woocommerce-address-fields input[type="text"]:focus,
.mg-account .woocommerce-MyAccount-content .woocommerce-address-fields input[type="email"]:focus,
.mg-account .woocommerce-MyAccount-content .woocommerce-address-fields input[type="tel"]:focus,
.mg-account .woocommerce-MyAccount-content .woocommerce-address-fields select:focus,
.mg-account .woocommerce-MyAccount-content .woocommerce-address-fields textarea:focus {
	background-color: var(--mg-acc-surface) !important;
	border-color: var(--mg-acc-ink) !important;
	box-shadow: inset 0 -2px 0 0 var(--mg-acc-accent), 0 0 0 3px var(--mg-acc-ring) !important;
	outline: none !important;
}

/* Digits read in logical order but stay pinned to the reading edge. */
.mg-account .woocommerce-MyAccount-content .woocommerce-address-fields input[type="tel"],
.mg-account .woocommerce-MyAccount-content .woocommerce-address-fields #billing_postcode_field input,
.mg-account .woocommerce-MyAccount-content .woocommerce-address-fields #shipping_postcode_field input {
	direction: ltr;
	text-align: right;
	letter-spacing: 0.02em;
}

.mg-account .woocommerce-MyAccount-content .woocommerce-address-fields input::placeholder,
.mg-account .woocommerce-MyAccount-content .woocommerce-address-fields textarea::placeholder {
	color: var(--mg-acc-hint);
	opacity: 1;
	font-size: 14px;
}

/* --- the label, when its field is live ---------------------------------- */
.mg-account .woocommerce-MyAccount-content .woocommerce-address-fields .form-row:focus-within label {
	color: var(--mg-acc-ink);
}

/* Invalid rows keep a visible, non-colour-only cue plus the message below. */
.mg-account .woocommerce-MyAccount-content .woocommerce-address-fields .form-row.woocommerce-invalid input.input-text,
.mg-account .woocommerce-MyAccount-content .woocommerce-address-fields .form-row.woocommerce-invalid select {
	border-color: var(--mg-acc-ink-danger) !important;
	background-color: var(--mg-acc-surface) !important;
}

/* The select keeps its native behaviour and its own arrow; only the box is
 * redrawn. Replacing the arrow would mean replacing the control, which breaks
 * the state dropdown and select2. The chevron is drawn INSIDE the field
 * (left edge, which is the end edge in RTL) so it can never be mistaken for a
 * stray glyph floating in the gutter -- the bug visible in the old layout. */
.mg-account .woocommerce-MyAccount-content .woocommerce-address-fields select {
	padding-inline-end: 44px !important;
	padding-inline-start: 16px !important;
	cursor: pointer;
	/* The chevron is the same one the select2 wrapper draws. Keeping it on the
	 * native element too means the control still reads as a dropdown if
	 * selectWoo never runs (JS blocked, script failure): without it,
	 * appearance:none leaves a bare line that looks like a text field.
	 * When select2 does run, the native select is hidden, so the two arrows
	 * never appear together. */
	background-color: transparent !important;
	background-image: url("data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath d='M1 1.5 6 6.5 11 1.5' fill='none' stroke='%230a0a0a' stroke-width='1.7' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") !important;
	background-repeat: no-repeat !important;
	background-position: left 16px center !important;
	background-size: 14px 9px !important;
}

/* --- select2 own hidden select ------------------------------------------ */
/* selectWoo hides the real select with .select2-hidden-accessible
 * (position:absolute; width:1px; clip). Our chevron rule above paints a
 * background on EVERY select in this form, and a clipped select still
 * paints its background box, so a second stray chevron appeared at the far
 * edge of the row (visible next to استان in the screenshot). This rule is
 * last and carries !important: the earlier select rule is !important too,
 * so source order decides. */
.mg-account .woocommerce-MyAccount-content .woocommerce-address-fields select.select2-hidden-accessible,
.mg-account .woocommerce-MyAccount-content .woocommerce-address-fields .select2-hidden-accessible {
	background-image: none !important;
	padding-inline-end: 0 !important;
}

/* --- the submit button --------------------------------------------------- */
/* Sits on the same 54px rhythm as the fields. Hover carries the brand gold;
 * that is the only place gold appears at full strength on this page, which is
 * what keeps the accent worth noticing. */
.mg-account .woocommerce-MyAccount-content .woocommerce-address-fields > p .button {
	height: 54px !important;
	min-width: 168px;
	padding: 0 44px !important;
	font-family: var(--mg-acc-font-display) !important;
	font-size: 15px !important;
	font-weight: 500 !important;
	line-height: 1 !important;
	color: var(--mg-acc-surface) !important;
	background: var(--mg-acc-ink) !important;
	border: 1px solid var(--mg-acc-ink) !important;
	border-radius: var(--mg-acc-r-sm) !important;
	box-shadow: none !important;
	transition: background-color 0.2s ease, color 0.2s ease, border-color 0.2s ease;
}

.mg-account .woocommerce-MyAccount-content .woocommerce-address-fields > p .button:hover,
.mg-account .woocommerce-MyAccount-content .woocommerce-address-fields > p .button:focus-visible {
	background: var(--mg-acc-accent) !important;
	border-color: var(--mg-acc-ink) !important;
	color: var(--mg-acc-accent-ink) !important;
}

.mg-account .woocommerce-MyAccount-content .woocommerce-address-fields > p .button:focus-visible {
	outline: 2px solid var(--mg-acc-ink) !important;
	outline-offset: 3px;
}

/* --- descriptions and validation ---------------------------------------- */
.mg-account .woocommerce-MyAccount-content .woocommerce-address-fields .form-row .description,
.mg-account .woocommerce-MyAccount-content .woocommerce-address-fields .form-row small {
	display: block;
	margin: 5px 0 0;
	font-size: var(--mg-acc-fs-xs);
	line-height: 1.7;
	color: var(--mg-acc-ink-faint);
}

/* WooCommerce marks an invalid row with .woocommerce-invalid. */
.mg-account .woocommerce-MyAccount-content .woocommerce-address-fields .form-row.woocommerce-invalid::after {
	background: var(--mg-acc-ink-danger);
}

.mg-account .woocommerce-MyAccount-content .woocommerce-address-fields .form-row.woocommerce-invalid label {
	color: var(--mg-acc-ink-danger);
}

.mg-account .woocommerce-MyAccount-content .woocommerce-address-fields .form-row.woocommerce-invalid::before {
	background: var(--mg-acc-ink-danger);
}

/* --- the submit row ------------------------------------------------------ */
/* The button sits in a <p> after the field wrapper, separated by air rather
 * than a rule so the card still reads as one block.
 *
 * Solid ink at rest, brand gold on hover. That is the only place the accent
 * reaches full strength on this page, which is precisely why it still reads
 * as an accent. The previous version was an outline button with a fill that
 * rose from the bottom edge; against the new 54px fields an outline button
 * disappeared into the surface, so the fill animation had nothing to land on. */
.mg-account .woocommerce-MyAccount-content .woocommerce-address-fields > p {
	display: flex;
	align-items: center;
	justify-content: flex-start;
	margin: var(--mg-acc-s-6) 0 0 !important;
	padding: 0 !important;
}

.mg-account .woocommerce-MyAccount-content .woocommerce-address-fields > p .button {
	position: relative;
	z-index: 1;
	height: 54px !important;
	min-width: 168px;
	padding: 0 44px !important;
	border: 1px solid var(--mg-acc-ink) !important;
	border-radius: var(--mg-acc-r-sm) !important;
	background: var(--mg-acc-ink) !important;
	color: var(--mg-acc-surface) !important;
	font-family: var(--mg-acc-font-display) !important;
	font-size: 15px !important;
	font-weight: 500 !important;
	line-height: 1 !important;
	letter-spacing: 0;
	cursor: pointer;
	box-shadow: none !important;
	transition: background-color 0.2s ease, color 0.2s ease, border-color 0.2s ease;
}

.mg-account .woocommerce-MyAccount-content .woocommerce-address-fields > p .button:hover,
.mg-account .woocommerce-MyAccount-content .woocommerce-address-fields > p .button:focus-visible {
	background: var(--mg-acc-accent) !important;
	border-color: var(--mg-acc-ink) !important;
	color: var(--mg-acc-accent-ink) !important;
}

.mg-account .woocommerce-MyAccount-content .woocommerce-address-fields > p .button:focus-visible {
	outline: 2px solid var(--mg-acc-ink) !important;
	outline-offset: 3px;
}

/* =========================================================================
 * select2 (country and state)
 * ========================================================================= */
/* WooCommerce's country-select.js turns `select.country_select:visible` and
 * `select.state_select:visible` into select2 widgets, so on this page the two
 * native selects are hidden and replaced by `.select2-container`. Styling only
 * the <select> would leave those two fields looking like the old boxed inputs
 * in the middle of an underline form. The wrapper therefore gets the same
 * treatment: no box, no border, and the same chevron the other fields carry.
 *
 * This was found by rendering the real form through wc_get_template() and
 * counting markup, not by looking at the sample — the sample had plain
 * <select> elements and hid the problem. */
.mg-account .woocommerce-MyAccount-content .woocommerce-address-fields .select2-container {
	width: 100% !important;
	display: block;
}

.mg-account .woocommerce-MyAccount-content .woocommerce-address-fields .select2-container .select2-selection--single {
	/* Same surface as every other control on this form: 54px, quiet fill,
	 * hairline border, chevron drawn inside the box. Before this, select2 kept
	 * the old 40px borderless look and the state field visibly disagreed with
	 * the country field sitting next to it. */
	height: 54px !important;
	padding: 0 16px !important;
	border: 1px solid var(--mg-acc-field-border) !important;
	border-radius: var(--mg-acc-r-sm) !important;
	background-color: var(--mg-acc-field-bg) !important;
	background-image: url("data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' width='14' height='9' viewBox='0 0 14 9'%3E%3Cpath d='M1 1.5 7 7.5 13 1.5' fill='none' stroke='%230a0a0a' stroke-width='1.7' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") !important;
	background-repeat: no-repeat !important;
	background-position: left 16px center !important;
	background-size: 14px 9px !important;
	box-shadow: none !important;
	box-sizing: border-box;
	cursor: pointer;
	transition: background-color 0.18s ease, border-color 0.18s ease, box-shadow 0.18s ease;
}

.mg-account .woocommerce-MyAccount-content .woocommerce-address-fields .select2-container .select2-selection--single:hover {
	border-color: var(--mg-acc-field-border-hover) !important;
	background-color: var(--mg-acc-field-bg-hover) !important;
}

.mg-account .woocommerce-MyAccount-content .woocommerce-address-fields .select2-container.select2-container--focus .select2-selection--single,
.mg-account .woocommerce-MyAccount-content .woocommerce-address-fields .select2-container.select2-container--open .select2-selection--single {
	background-color: var(--mg-acc-surface) !important;
	border-color: var(--mg-acc-ink) !important;
	box-shadow: inset 0 -2px 0 0 var(--mg-acc-accent), 0 0 0 3px var(--mg-acc-ring) !important;
}

.mg-account .woocommerce-MyAccount-content .woocommerce-address-fields .select2-container .select2-selection--single .select2-selection__rendered {
	padding-inline: 0;
	line-height: 52px;
	color: var(--mg-acc-ink);
	font-size: var(--mg-acc-fs-md);
	font-family: inherit;
	direction: rtl;
	text-align: right;
}

/* The placeholder select2 shows before a choice is made. */
.mg-account .woocommerce-MyAccount-content .woocommerce-address-fields .select2-container .select2-selection--single .select2-selection__placeholder {
	color: var(--mg-acc-ink-faint);
	font-size: var(--mg-acc-fs-sm);
}

/* select2 draws its own arrow out of borders; the chevron above replaces it. */
/* select2 draws its own arrow out of borders; the chevron above replaces it. */
.mg-account .woocommerce-MyAccount-content .woocommerce-address-fields .select2-container .select2-selection--single .select2-selection__arrow {
	display: none !important;
}

/* The dropdown panel, so it does not arrive as an unstyled white slab.
 * It is appended to <body>, not to the form, so these rules are unscoped —
 * but they are narrow enough (select2 + results option) not to reach the
 * theme's other select2 uses such as the checkout page. */
.select2-container--default .select2-dropdown {
	border: 1px solid var(--mg-acc-line-strong);
	border-radius: var(--mg-acc-r-sm);
	background: var(--mg-acc-surface);
	box-shadow: var(--mg-acc-shadow-md);
}

.select2-container--default .select2-results__option {
	font-family: var(--mg-acc-font);
	font-size: var(--mg-acc-fs-base);
	color: var(--mg-acc-ink-soft);
	padding: 8px 12px;
}

.select2-container--default .select2-results__option--highlighted[aria-selected],
.select2-container--default .select2-results__option--highlighted[aria-selected]:hover {
	background: var(--mg-acc-ink);
	color: var(--mg-acc-surface);
}

.select2-container--default .select2-results__option[aria-selected="true"] {
	color: var(--mg-acc-ink);
	font-weight: 500;
	background: var(--mg-acc-surface-sunken);
}

/* Search box select2 adds above long lists. */
.select2-container--default .select2-search--dropdown .select2-search__field {
	border: 0;
	border-bottom: 1px solid var(--mg-acc-line-strong);
	border-radius: 0;
	padding: 6px 2px;
	font-family: inherit;
	font-size: var(--mg-acc-fs-base);
	outline: none;
}

/* Seasonal themes keep working: every colour above reads a token, so the
 * Yalda and Nowruz palettes apply with no rule of their own. */

/* --- tablet ------------------------------------------------------------- */
@media (max-width: 760px) {
	.mg-account .woocommerce-address-fields__field-wrapper {
		gap: var(--mg-acc-s-4) var(--mg-acc-s-4);
	}
}

/* --- phone -------------------------------------------------------------- */
@media (max-width: 560px) {
	/* One column: two fields side by side at 390px gives each about 150px,
	 * which is narrower than a postcode. */
	.mg-account .woocommerce-address-fields__field-wrapper {
		grid-template-columns: 1fr;
		gap: var(--mg-acc-s-4);
	}

	/* 16px keeps iOS from zooming the page when a field takes focus. */
	.mg-account .woocommerce-MyAccount-content .woocommerce-address-fields input.input-text,
	.mg-account .woocommerce-MyAccount-content .woocommerce-address-fields input[type="text"],
	.mg-account .woocommerce-MyAccount-content .woocommerce-address-fields input[type="email"],
	.mg-account .woocommerce-MyAccount-content .woocommerce-address-fields input[type="tel"],
	.mg-account .woocommerce-MyAccount-content .woocommerce-address-fields select,
	.mg-account .woocommerce-MyAccount-content .woocommerce-address-fields textarea {
		font-size: 16px !important;
		height: 50px !important;
	}

	.mg-account .woocommerce-MyAccount-content .woocommerce-address-fields > p .button {
		height: 50px !important;
	}

	.mg-account .woocommerce-MyAccount-content .woocommerce-address-fields > p .button {
		width: 100%;
		padding: 0 20px !important;
	}

	.mg-account .woocommerce-MyAccount-content form:has(.woocommerce-address-fields) > h2,
	.mg-account .woocommerce-MyAccount-content .woocommerce-address-fields h2 {
		margin-bottom: var(--mg-acc-s-5);
	}
}

/* --- reduced motion ----------------------------------------------------- */
/* account.css already shortens every transition globally. The focus line must
 * still be visible, so its finished state is written out explicitly rather
 * than left at scaleX(0). */
@media (prefers-reduced-motion: reduce) {
	.mg-account .woocommerce-MyAccount-content .woocommerce-address-fields input.input-text,
	.mg-account .woocommerce-MyAccount-content .woocommerce-address-fields select,
	.mg-account .woocommerce-MyAccount-content .woocommerce-address-fields textarea,
	.mg-account .woocommerce-MyAccount-content .woocommerce-address-fields > p .button {
		transition: none;
	}
}

