/*
 * RahkarTheme — WooCommerce My Account layout & cards.
 *
 * Loaded only on is_account_page() via the feature registry in inc/enqueue.php,
 * so visitors who never hit /my-account/* pay zero bytes.
 *
 * No JS. No external assets. Pure CSS that piggybacks on theme.json tokens
 * (with hard-coded fallbacks so this stylesheet also renders correctly inside
 * Gutenberg's editor iframe where CSS custom properties aren't always present).
 *
 * Two-view design (one DOM):
 *   - Desktop ≥901px: 2-column grid (sidebar + content). Mobile-only chrome
 *     (profile header, back bar, row chevrons) is hidden.
 *   - Mobile ≤900px: full-width list view. On the dashboard endpoint the
 *     profile header + menu list show and the dashboard cards hide; on every
 *     other endpoint the sidebar hides and the content + back-bar show.
 */

/* ---------- Page-level overrides ----------------------------------------
 * The /my-account/* page is rendered via the [woocommerce_my_account]
 * shortcode injected into page.html's post-content. post-content uses the
 * constrained layout (contentSize = 760px), which caps the WC wrapper
 * before our grid even has a chance.
 *
 * We override two things on the account page (using the body class WC
 * sets automatically):
 *   1. Expand the .woocommerce wrapper from contentSize to wideSize so
 *      the sidebar+content grid has room to breathe.
 *   2. Hide the redundant page title ("My account"). The dashboard's own
 *      h2 ("اطلاعات حساب کاربری") is the real heading.
 */
.woocommerce-account .wp-block-post-content > .woocommerce,
.woocommerce-account .entry-content > .woocommerce{
	max-width:var(--wp--style--global--wide-size,1200px);
	width:100%;
}
.woocommerce-account .wp-block-post-title{display:none;}

/* On mobile, the account page wants edge-to-edge layout — strip the
 * post-content's horizontal padding so the profile header and list rows
 * span the full viewport. */
@media (max-width:900px){
	.woocommerce-account .wp-block-post-content,
	.woocommerce-account .entry-content{padding-inline:0;}
}

/* ---------- Page shell ---------------------------------------------------- */
.rahkar-account{
	width:100%;
	margin-inline:auto;
	padding:1.5rem 0 4rem;
	display:grid;
	grid-template-columns:280px minmax(0,1fr);
	gap:1.75rem;
	align-items:start;
	direction:rtl;
}

/* Mobile-only elements are display:none on desktop. */
.rahkar-account__mobile-profile,
.rahkar-account__mobile-back{display:none;}

/* ---------- Sidebar (desktop) -------------------------------------------- */
.rahkar-account__sidebar{
	background:var(--wp--preset--color--base,#fff);
	border:1px solid var(--wp--preset--color--border,#e2e4e9);
	border-radius:var(--wp--custom--radius--xl,1rem);
	padding:1.25rem 0.875rem;
	position:sticky;
	top:90px;
}
.rahkar-account__sidebar-title{
	font-size:1rem;
	font-weight:var(--wp--custom--fw--strong);
	margin:0 0 0.875rem;
	padding-inline:0.625rem;
	color:var(--wp--preset--color--contrast,#0f1115);
}
.rahkar-account__nav ul{
	list-style:none;
	margin:0;
	padding:0;
	display:flex;
	flex-direction:column;
	gap:0.125rem;
}
.rahkar-account__nav li{margin:0;}
.rahkar-account__nav a{
	display:flex;
	align-items:center;
	gap:0.75rem;
	padding:0.7rem 0.75rem;
	border-radius:var(--wp--custom--radius--md);
	color:var(--wp--preset--color--text,#1a1d23);
	font-size:0.9375rem;
	text-decoration:none;
	transition:background-color .15s,color .15s;
}
.rahkar-account__nav a:hover{
	background:var(--wp--preset--color--surface,#f7f7f8);
	text-decoration:none;
	color:var(--wp--preset--color--text,#1a1d23);
}
.rahkar-account__nav .is-active a,
.rahkar-account__nav li.is-active a:hover{
	background:var(--wp--preset--color--primary,#0a66c2);
	color:var(--wp--custom--on-primary, #fff);
}
.rahkar-account__nav-icon-wrap{
	display:inline-flex;
	align-items:center;
	justify-content:center;
	width:32px;height:32px;
	border-radius:var(--wp--custom--radius--md);
	background:var(--wp--preset--color--surface,#f7f7f8);
	color:var(--wp--preset--color--text-muted,#5b6271);
	flex-shrink:0;
	transition:background-color .15s,color .15s;
}
.rahkar-account__nav .is-active a .rahkar-account__nav-icon-wrap{
	background:rgba(255,255,255,0.18);
	color:#fff;
}
.rahkar-account__nav-icon{width:18px;height:18px;stroke-width:1.3;}
.rahkar-account__nav-label{flex:1;min-width:0;}
.rahkar-account__nav-chevron{display:none;} /* desktop hides the trailing arrow */
.rahkar-account__nav li.is-logout a{color:var(--wp--preset--color--accent,#e63946);}
.rahkar-account__nav li.is-logout a:hover{background:#fef2f2;color:var(--wp--preset--color--accent,#e63946);}
.rahkar-account__nav li.is-logout a .rahkar-account__nav-icon-wrap{
	background:rgba(230,57,70,0.10);
	color:var(--wp--preset--color--accent,#e63946);
}

/* ---------- Content column ------------------------------------------------ */
.rahkar-account__content{
	display:flex;
	flex-direction:column;
	gap:1.25rem;
	min-width:0;
}

/* Shared card */
.rahkar-account-card{
	background:var(--wp--preset--color--base,#fff);
	border:1px solid var(--wp--preset--color--border,#e2e4e9);
	border-radius:var(--wp--custom--radius--xl,1rem);
	padding:1.75rem;
}

/* ---------- Info card ----------------------------------------------------- */
.rahkar-account-info__header{
	display:flex;
	align-items:center;
	justify-content:space-between;
	gap:1rem;
	margin-bottom:1.25rem;
}
.rahkar-account-info__title{
	font-size:1.125rem;
	font-weight:var(--wp--custom--fw--strong);
	margin:0;
}
.rahkar-account-info__edit{
	display:inline-flex;
	align-items:center;
	justify-content:center;
	gap:var(--wp--custom--button--gap,8px);
	min-height:var(--wp--custom--button--h--sm,36px);
	background:var(--wp--preset--color--primary,#0a66c2);
	color:var(--wp--custom--on-primary, #fff);
	padding:0 var(--wp--custom--button--px--sm,14px);
	border-radius:var(--wp--custom--button--radius,10px);
	font-size:var(--wp--custom--button--fs--sm,0.875rem);
	font-weight:var(--wp--custom--button--fw,600);
	text-decoration:none;
	transition:background-color .15s;
}
.rahkar-account-info__edit:hover{text-decoration:none;color:var(--wp--custom--on-primary, #fff);background:var(--wp--preset--color--primary-dark,#074a8d);}
.rahkar-account-info__edit svg{width:16px;height:16px;}

.rahkar-account-info__user{
	display:flex;
	align-items:center;
	gap:1rem;
	padding-bottom:1.25rem;
	border-bottom:1px solid var(--wp--preset--color--border,#e2e4e9);
	margin-bottom:1.5rem;
}
.rahkar-account-info__avatar{
	width:64px;height:64px;
	border-radius:50%;
	background:var(--wp--preset--color--muted,#eceef1);
	overflow:hidden;
	flex-shrink:0;
}
.rahkar-account-info__avatar img{width:100%;height:100%;display:block;border-radius:50%;}
.rahkar-account-info__identity{min-width:0;flex:1;}
.rahkar-account-info__name{
	font-weight:var(--wp--custom--fw--strong);
	font-size:1.0625rem;
	margin:0 0 0.25rem;
	color:var(--wp--preset--color--contrast,#0f1115);
}
.rahkar-account-info__email{
	font-size:0.8125rem;
	color:var(--wp--preset--color--text-muted,#5b6271);
	word-break:break-all;
}

.rahkar-account-info__grid{
	display:grid;
	grid-template-columns:1fr 1fr;
	gap:1.5rem 2rem;
}
.rahkar-account-info__label{
	display:flex;
	align-items:center;
	gap:0.375rem;
	font-size:0.8125rem;
	color:var(--wp--preset--color--text-muted,#5b6271);
	margin-bottom:0.375rem;
}
.rahkar-account-info__label svg{width:14px;height:14px;opacity:.7;}
.rahkar-account-info__value{
	font-weight:var(--wp--custom--fw--strong);
	font-size:0.9375rem;
	color:var(--wp--preset--color--text,#1a1d23);
}
.rahkar-account-info__value--empty{color:var(--wp--preset--color--text-muted,#5b6271);font-weight:var(--wp--custom--fw--base);}

/* ---------- Stats row ----------------------------------------------------- */
.rahkar-account-stats{
	display:grid;
	grid-template-columns:repeat(3,1fr);
	gap:1.25rem;
}
.rahkar-account-stat{
	background:var(--wp--preset--color--base,#fff);
	border:1px solid var(--wp--preset--color--border,#e2e4e9);
	border-radius:var(--wp--custom--radius--xl,1rem);
	padding:1.5rem 1rem;
	text-align:center;
}
.rahkar-account-stat__value{
	font-size:1.5rem;
	font-weight:var(--wp--custom--fw--strong);
	margin:0 0 0.5rem;
	color:var(--wp--preset--color--contrast,#0f1115);
	line-height:1.2;
}
.rahkar-account-stat__label{
	font-size:0.875rem;
	color:var(--wp--preset--color--text-muted,#5b6271);
}

/* ---------- Endpoint placeholder shell (.rh-acct-ph) ----------------------
 * Baseline structure: same as .rh-acct-ord (orders screen). Used by every
 * custom my-account endpoint that doesn't have real content yet — see
 * rahkar_render_account_placeholder() in inc/woocommerce.php.
 *
 * Pattern: padding-block:1rem container, header with lg title, then a
 * bordered empty card (radius xl, padding 3rem 1.5rem, 64px circle icon).
 */
.rh-acct-ph{padding-block:1rem;}
.rh-acct-ph__header{
	display:flex;
	align-items:center;
	justify-content:space-between;
	margin-block-end:1rem;
}
.rh-acct-ph__title{
	margin:0;
	font-size:var(--wp--preset--font-size--lg,1.25rem);
	font-weight:var(--wp--custom--fw--strong);
	color:var(--wp--preset--color--contrast,#0f1115);
}
.rh-acct-ph__empty{
	background:var(--wp--preset--color--base,#fff);
	border:1px solid var(--wp--preset--color--border,#e2e4e9);
	border-radius:var(--wp--custom--radius--xl,1rem);
	padding:3rem 1.5rem;
	text-align:center;
}
.rh-acct-ph__empty-icon{
	width:64px;height:64px;
	margin:0 auto 1rem;
	display:inline-flex;
	align-items:center;
	justify-content:center;
	border-radius:50%;
	background:var(--wp--preset--color--surface,#f7f7f8);
	color:var(--wp--preset--color--primary,#0a66c2);
}
.rh-acct-ph__empty-icon svg{width:32px;height:32px;}
.rh-acct-ph__empty-desc{
	margin:0;
	font-size:var(--wp--preset--font-size--md,1rem);
	color:var(--wp--preset--color--text,#1a1d23);
}

/* ---------- Legacy placeholder classes (kept for any third-party CSS that
 * still targets them; new code should use .rh-acct-ph instead). */
.rahkar-account-placeholder{
	text-align:center;
	padding:3rem 1.5rem;
}
.rahkar-account-placeholder__icon{
	width:64px;height:64px;
	margin:0 auto 1rem;
	display:inline-flex;
	align-items:center;
	justify-content:center;
	border-radius:50%;
	background:var(--wp--preset--color--surface,#f7f7f8);
	color:var(--wp--preset--color--primary,#0a66c2);
}
.rahkar-account-placeholder__icon svg{width:32px;height:32px;}
.rahkar-account-placeholder__title{
	font-size:1.125rem;
	font-weight:var(--wp--custom--fw--strong);
	margin:0 0 0.5rem;
	color:var(--wp--preset--color--contrast,#0f1115);
}
.rahkar-account-placeholder__desc{
	font-size:0.9375rem;
	color:var(--wp--preset--color--text-muted,#5b6271);
	margin:0;
}

/* =========================================================================
 *  MOBILE — full redesign at ≤900px to match the comp.
 * ========================================================================= */
@media (max-width:900px){

	.rahkar-account{
		grid-template-columns:1fr;
		gap:0;
		padding:0 0 5rem;
	}

	/* ----- Mobile profile header (primary-color hero) ---------------------
	 * Shown only on the dashboard endpoint. The visibility is gated by a
	 * parent class so we don't have to touch the markup per endpoint. */
	.rahkar-account__mobile-profile{display:none;}
	.rahkar-account--ep-dashboard .rahkar-account__mobile-profile{
		display:block;
		background:var(--wp--preset--color--primary,#0a66c2);
		color:var(--wp--custom--on-primary, #fff);
		padding:1.25rem 1rem 1.75rem;
		margin-bottom:0.75rem;
	}
	.rahkar-account__mobile-profile-inner{
		display:flex;
		align-items:center;
		gap:0.875rem;
	}
	.rahkar-account__mobile-avatar{
		width:44px;height:44px;
		border-radius:50%;
		background:rgba(255,255,255,0.18);
		display:flex;
		align-items:center;
		justify-content:center;
		flex-shrink:0;
		color:#fff;
	}
	.rahkar-account__mobile-avatar svg{width:24px;height:24px;}
	.rahkar-account__mobile-identity{min-width:0;flex:1;line-height:1.3;}
	.rahkar-account__mobile-phone{
		font-weight:var(--wp--custom--fw--strong);
		font-size:1.0625rem;
		margin:0;
		direction:ltr;
		text-align:right;
	}
	.rahkar-account__mobile-name{
		font-size:0.8125rem;
		opacity:0.85;
		margin:0.125rem 0 0;
	}

	/* ----- Mobile back-bar (non-dashboard endpoints) -----------------------
	 * Slim sticky bar at top with chevron + endpoint label. Tap returns to
	 * /my-account/ (the mobile menu view). */
	.rahkar-account--ep-dashboard .rahkar-account__mobile-back{display:none;}
	.rahkar-account__mobile-back{
		display:flex;
		align-items:center;
		gap:0.5rem;
		padding:0.875rem 1rem;
		background:var(--wp--preset--color--base,#fff);
		border-bottom:1px solid var(--wp--preset--color--border,#e2e4e9);
		color:var(--wp--preset--color--contrast,#0f1115);
		font-weight:var(--wp--custom--fw--strong);
		font-size:1rem;
		text-decoration:none;
		position:sticky;
		top:0;
		z-index:5;
	}
	.rahkar-account__mobile-back:hover{color:var(--wp--preset--color--contrast,#0f1115);text-decoration:none;}
	.rahkar-account__mobile-back svg{width:18px;height:18px;flex-shrink:0;}

	/* ----- Sidebar becomes a full-width list view on dashboard ------------ */
	.rahkar-account__sidebar{
		background:transparent;
		border:0;
		border-radius:0;
		padding:0;
		position:static;
	}
	.rahkar-account__sidebar-title{display:none;} /* mobile uses profile header as identity instead */

	.rahkar-account__nav ul{gap:0;}
	.rahkar-account__nav li{
		background:var(--wp--preset--color--base,#fff);
		border-bottom:1px solid var(--wp--preset--color--border,#e2e4e9);
	}
	.rahkar-account__nav li:first-child{border-top:1px solid var(--wp--preset--color--border,#e2e4e9);}
	.rahkar-account__nav a{
		padding:0.95rem 1rem;
		border-radius:0;
		font-size:0.9375rem;
		gap:0.875rem;
	}
	.rahkar-account__nav a:hover,
	.rahkar-account__nav .is-active a,
	.rahkar-account__nav li.is-active a:hover{
		background:var(--wp--preset--color--surface,#f7f7f8);
		color:var(--wp--preset--color--text,#1a1d23);
	}
	.rahkar-account__nav .is-active a .rahkar-account__nav-icon-wrap{
		background:color-mix(in srgb,var(--wp--preset--color--primary,#0a66c2) 10%,transparent);
		color:var(--wp--preset--color--primary,#0a66c2);
	}
	.rahkar-account__nav-icon-wrap{
		width:36px;height:36px;
		background:color-mix(in srgb,var(--wp--preset--color--primary,#0a66c2) 8%,transparent);
		color:var(--wp--preset--color--primary,#0a66c2);
	}
	.rahkar-account__nav-icon{width:20px;height:20px;}
	.rahkar-account__nav-chevron{
		display:block;
		width:16px;height:16px;
		flex-shrink:0;
		color:var(--wp--preset--color--text-muted,#5b6271);
		opacity:.6;
	}
	.rahkar-account__nav li.is-logout a .rahkar-account__nav-icon-wrap{
		background:rgba(230,57,70,0.10);
		color:var(--wp--preset--color--accent,#e63946);
	}

	/* ----- Hide menu on non-dashboard endpoints --------------------------- */
	.rahkar-account:not(.rahkar-account--ep-dashboard) .rahkar-account__sidebar{
		display:none;
	}

	/* ----- Hide dashboard content on the dashboard endpoint --------------
	 * On mobile, the menu IS the dashboard. The cards rendered by
	 * dashboard.php would just push the menu below the fold. */
	.rahkar-account--ep-dashboard .rahkar-account__content{display:none;}

	/* ----- Content column on non-dashboard endpoints --------------------- */
	.rahkar-account__content{
		padding:1rem;
		gap:1rem;
	}
	.rahkar-account-card{padding:1.25rem;}
	.rahkar-account-info__grid{grid-template-columns:1fr;gap:1.25rem;}
	.rahkar-account-info__header{flex-direction:column;align-items:flex-start;}
	.rahkar-account-stats{grid-template-columns:1fr;gap:0.75rem;}
	.rahkar-account-placeholder{padding:2.5rem 1rem;}

	/* Same mobile shrink for the new baseline placeholder shell. */
	.rh-acct-ph__title{font-size:var(--wp--preset--font-size--md,1.125rem);}
	.rh-acct-ph__empty{padding:2.5rem 1rem;}
}

/* =========================================================================
 *  My Account → "دیدگاه‌ها"  (inc/account-reviews.php)
 * =========================================================================
 *
 *  Top: encouragement banner.
 *  Below: 2-column grid of pending-review cards on desktop, 1-column on
 *  mobile. Each card mirrors the dashboard card's visual vocabulary
 *  (white surface, soft border, 0.75rem radius) so the page feels of-a-piece.
 *
 *  The whole page lives inside .rahkar-account-card so it inherits the
 *  same padding/border treatment as other endpoint screens. The banner
 *  and grid then style themselves WITHIN that shell.
 */

.rahkar-account-reviews-page,
.rh-acct-rev{
	padding-block:1rem;
}

.rh-acct-rev__header{
	display:flex;
	align-items:center;
	justify-content:space-between;
	margin-block-end:1rem;
}
.rh-acct-rev__title{
	margin:0;
	font-size:var(--wp--preset--font-size--lg,1.25rem);
	font-weight:var(--wp--custom--fw--strong);
	color:var(--wp--preset--color--contrast,#0f1115);
}

.rh-acct-rev__banner{
	display:flex;
	align-items:center;
	gap:1rem;
	padding:1rem 1.125rem;
	background:color-mix(in srgb,var(--wp--preset--color--primary,#0a66c2) 6%,transparent);
	border:1px solid color-mix(in srgb,var(--wp--preset--color--primary,#0a66c2) 18%,transparent);
	border-radius:var(--wp--custom--radius--lg);
	margin-block-end:1rem;
}

.rh-acct-rev__banner-icon{
	display:inline-flex;
	align-items:center;
	justify-content:center;
	width:2.75rem;
	height:2.75rem;
	border-radius:var(--wp--custom--radius--pill);
	background:var(--wp--preset--color--base,#fff);
	color:var(--wp--preset--color--primary,#0a66c2);
	flex-shrink:0;
}

.rh-acct-rev__banner-title{
	margin:0 0 0.25rem;
	font-size:var(--wp--preset--font-size--md,1.125rem);
	font-weight:var(--wp--custom--fw--strong);
	color:var(--wp--preset--color--contrast,#0f1115);
}

.rh-acct-rev__banner-sub{
	margin:0;
	font-size:var(--wp--preset--font-size--sm,0.875rem);
	color:var(--wp--preset--color--text-muted,#5b6271);
	line-height:1.6;
}

/* ---- grid ---- */

.rh-acct-rev__grid{
	display:grid;
	grid-template-columns:1fr;
	gap:0.875rem;
}

@media (min-width:700px){
	.rh-acct-rev__grid{
		grid-template-columns:repeat(2,minmax(0,1fr));
	}
}

/* ---- card ---- */

.rh-acct-rev__card{
	display:flex;
	flex-direction:column;
	gap:0.75rem;
	padding:1rem;
	background:var(--wp--preset--color--base,#fff);
	border:1px solid var(--wp--preset--color--border,#e2e4e9);
	border-radius:var(--wp--custom--radius--lg);
	transition:opacity 280ms ease, transform 280ms ease;
}

.rh-acct-rev__card.is-removing{
	opacity:0;
	transform:scale(0.96);
	pointer-events:none;
}

.rh-acct-rev__card-head{
	display:flex;
	align-items:flex-start;
	justify-content:space-between;
	gap:0.75rem;
}

.rh-acct-rev__card-name{
	flex:1 1 auto;
	min-width:0;
	font-weight:var(--wp--custom--fw--strong);
	font-size:var(--wp--preset--font-size--sm,0.875rem);
	line-height:1.5;
	color:var(--wp--preset--color--text,#1a1d23);
	text-decoration:none;
	display:-webkit-box;
	-webkit-line-clamp:2;
	-webkit-box-orient:vertical;
	overflow:hidden;
}

.rh-acct-rev__card-name:hover,
.rh-acct-rev__card-name:focus-visible{
	color:var(--wp--preset--color--primary,#0a66c2);
}

.rh-acct-rev__card-img-wrap{
	display:inline-flex;
	flex-shrink:0;
	width:3.5rem;
	height:3.5rem;
	border-radius:var(--wp--custom--radius--md);
	overflow:hidden;
	background:var(--wp--preset--color--surface,#f7f7f8);
	border:1px solid var(--wp--preset--color--border,#e2e4e9);
}

.rh-acct-rev__card-img{
	width:100%;
	height:100%;
	object-fit:contain;
}

.rh-acct-rev__card-meta{
	display:flex;
	align-items:center;
	flex-wrap:wrap;
	gap:0.375rem;
	font-size:var(--wp--preset--font-size--xs,0.75rem);
	color:var(--wp--preset--color--text-muted,#5b6271);
}

.rh-acct-rev__card-sep{
	color:var(--wp--preset--color--border,#e2e4e9);
}

/* ---- inline star row (per-card quick-pick) ---- */

.rh-acct-rev__card-stars{
	display:inline-flex;
	gap:0.25rem;
	direction:ltr; /* visual L→R for the star meter, like every product UI */
	margin-block-start:0.25rem;
}

.rh-acct-rev__star{
	display:inline-flex;
	flex-direction:column;
	align-items:center;
	justify-content:center;
	gap:0.125rem;
	background:transparent;
	border:0;
	padding:0.25rem;
	font:inherit; /* override UA button font so the digit uses Vazirmatn */
	cursor:pointer;
	color:var(--wp--preset--color--border,#e2e4e9);
	transition:color 80ms ease, transform 80ms ease;
}

/* Digit label under each star. Inherits the button's currentColor so it
   tracks the same gray-default / gold-on-hover state as the star icon
   itself — no extra selector needed. */
.rh-acct-rev__star-num{
	font-size:0.7rem;
	font-weight:var(--wp--custom--fw--strong);
	line-height:1;
}

/*
 * Hover painting: when the user hovers (or focuses) a star, fill it AND
 * every star BEFORE it in DOM order. DOM order is 1..5, visual order
 * (direction:ltr) is 1 → 5, so "before" = lower ratings.
 *
 * `:has(~ .rh-acct-rev__star:hover)` matches every star that has a hovered
 * star as a *later* sibling — i.e. every star at a lower rating than the
 * pointer. Combined with `:hover` itself, that's exactly "fill 1..N when
 * the pointer is on star N".
 *
 * Reset rule below clears the default gray on every star within a
 * hover/focus-within group; the gold rule then re-paints only 1..N.
 */
.rh-acct-rev__card-stars:hover .rh-acct-rev__star,
.rh-acct-rev__card-stars:focus-within .rh-acct-rev__star{
	color:var(--wp--preset--color--border,#e2e4e9);
}
.rh-acct-rev__card-stars .rh-acct-rev__star:hover,
.rh-acct-rev__card-stars .rh-acct-rev__star:has(~ .rh-acct-rev__star:hover),
.rh-acct-rev__card-stars .rh-acct-rev__star:focus-visible,
.rh-acct-rev__card-stars .rh-acct-rev__star:has(~ .rh-acct-rev__star:focus-visible){
	color:var(--wp--preset--color--warning,#d97706);
}

.rh-acct-rev__star:focus-visible{
	outline:2px solid var(--wp--preset--color--primary,#0a66c2);
	outline-offset:2px;
	border-radius:var(--wp--custom--radius--sm);
}

/* ---- CTA ---- */

.rh-acct-rev__card-cta{
	display:inline-flex;
	align-items:center;
	justify-content:center;
	gap:var(--wp--custom--button--gap,8px);
	box-sizing:border-box;
	width:100%;
	min-height:var(--wp--custom--button--h--md,44px);
	padding:0 var(--wp--custom--button--px--md,20px);
	border:1px solid var(--wp--preset--color--primary,#0a66c2);
	border-radius:var(--wp--custom--button--radius,10px);
	background:transparent;
	color:var(--wp--preset--color--primary,#0a66c2);
	font:inherit;
	font-weight:var(--wp--custom--button--fw,600);
	font-size:var(--wp--custom--button--fs--md,0.9375rem);
	cursor:pointer;
	transition:background-color 120ms ease, color 120ms ease;
	margin-block-start:auto;
}

.rh-acct-rev__card-cta:hover,
.rh-acct-rev__card-cta:focus-visible{
	background:var(--wp--preset--color--primary,#0a66c2);
	color:var(--wp--custom--on-primary, #fff);
}

@media (max-width:600px){
	.rh-acct-rev__title{font-size:var(--wp--preset--font-size--md,1.125rem);}
	.rh-acct-rev__banner{
		flex-direction:row;
		gap:0.75rem;
		padding:0.875rem;
	}
	.rh-acct-rev__banner-title{font-size:var(--wp--preset--font-size--sm,0.875rem);}
	.rh-acct-rev__banner-sub{font-size:var(--wp--preset--font-size--xs,0.75rem);}
}

/* =========================================================================
 *  My Account → "سفارش‌های من" — list (orders.php) + detail (view-order.php)
 * =========================================================================
 *
 *  Two screens sharing one stylesheet because both live inside the same
 *  asset gate (is_account_page) — bundling them avoids a second HTTP
 *  request and keeps gzip dictionary warm across the pair.
 *
 *  Colour vocabulary: status badges use four semantic tokens (success,
 *  warning, danger, primary) so the same rule set powers delivered /
 *  refunded / cancelled / current. Adding a new tab = add the colour
 *  token + one modifier class; no per-status duplication.
 */

/* ---------- Orders list shell -------------------------------------------- */
.rh-acct-ord{padding-block:1rem;}

.rh-acct-ord__header{
	display:flex;
	align-items:center;
	justify-content:space-between;
	margin-block-end:1rem;
}
.rh-acct-ord__title{
	margin:0;
	font-size:var(--wp--preset--font-size--lg,1.25rem);
	font-weight:var(--wp--custom--fw--strong);
	color:var(--wp--preset--color--contrast,#0f1115);
}

/* ---------- Tabs ---------------------------------------------------------- */
.rh-acct-ord__tabs{
	display:flex;
	align-items:center;
	gap:0.5rem;
	border-bottom:1px solid var(--wp--preset--color--border,#e2e4e9);
	margin-block-end:1rem;
	overflow-x:auto;          /* mobile: tabs scroll instead of wrap */
	scrollbar-width:none;
}
.rh-acct-ord__tabs::-webkit-scrollbar{display:none;}
.rh-acct-ord__tab{
	display:inline-flex;
	align-items:center;
	gap:0.375rem;
	padding:0.625rem 0.75rem;
	font-size:var(--wp--preset--font-size--sm,0.875rem);
	font-weight:var(--wp--custom--fw--strong);
	color:var(--wp--preset--color--text-muted,#5b6271);
	text-decoration:none;
	white-space:nowrap;
	border-bottom:2px solid transparent;
	margin-bottom:-1px;        /* overlap the row underline to "merge" */
	transition:color .15s,border-color .15s;
}
.rh-acct-ord__tab:hover{
	color:var(--wp--preset--color--contrast,#0f1115);
	text-decoration:none;
}
.rh-acct-ord__tab.is-active{
	color:var(--wp--preset--color--primary,#0a66c2);
	border-bottom-color:var(--wp--preset--color--primary,#0a66c2);
}
.rh-acct-ord__tab-count{
	display:inline-flex;
	align-items:center;
	justify-content:center;
	min-width:1.5rem;
	height:1.25rem;
	padding-inline:0.375rem;
	border-radius:var(--wp--custom--radius--md);
	background:var(--wp--preset--color--muted,#eceef1);
	color:var(--wp--preset--color--text,#1a1d23);
	font-size:var(--wp--preset--font-size--xs,0.75rem);
	font-weight:var(--wp--custom--fw--strong);
	line-height:1;
}
.rh-acct-ord__tab.is-active .rh-acct-ord__tab-count{
	background:var(--wp--preset--color--primary,#0a66c2);
	color:var(--wp--custom--on-primary, #fff);
}

/* ---------- List + card --------------------------------------------------- */
.rh-acct-ord__list{
	list-style:none;
	margin:0;
	padding:0;
	display:flex;
	flex-direction:column;
	gap:0.75rem;
}
.rh-acct-ord__card{
	background:var(--wp--preset--color--base,#fff);
	border:1px solid var(--wp--preset--color--border,#e2e4e9);
	border-radius:var(--wp--custom--radius--lg,0.75rem);
	overflow:hidden;
}
.rh-acct-ord__card-link{
	display:block;
	padding:1rem 1.125rem;
	color:inherit;
	text-decoration:none;
	transition:background-color .15s;
}
.rh-acct-ord__card-link:hover{
	background:var(--wp--preset--color--surface,#f7f7f8);
	text-decoration:none;
	color:inherit;
}

.rh-acct-ord__card-top{
	display:flex;
	align-items:center;
	justify-content:space-between;
	gap:0.5rem;
}
.rh-acct-ord__status{
	display:inline-flex;
	align-items:center;
	gap:0.4rem;
	font-weight:var(--wp--custom--fw--strong);
	font-size:var(--wp--preset--font-size--sm,0.875rem);
}
.rh-acct-ord__status-icon{
	display:inline-flex;
	align-items:center;
	justify-content:center;
	width:1.25rem;
	height:1.25rem;
}
.rh-acct-ord__status-icon svg{width:100%;height:100%;}

/* Semantic-color variants — shared by list cards AND view-order header. */
.rh-acct-ord__status--success,
.rh-ord-view__ship-status--success{color:var(--wp--preset--color--success,#198754);}
.rh-acct-ord__status--warning,
.rh-ord-view__ship-status--warning{color:var(--wp--preset--color--warning,#d97706);}
.rh-acct-ord__status--danger,
.rh-ord-view__ship-status--danger{color:var(--wp--preset--color--danger,#dc2626);}
.rh-acct-ord__status--primary,
.rh-ord-view__ship-status--primary{color:var(--wp--preset--color--primary,#0a66c2);}

.rh-acct-ord__card-chev{
	display:inline-flex;
	width:1.125rem;
	height:1.125rem;
	color:var(--wp--preset--color--text-muted,#5b6271);
	opacity:.6;
}
.rh-acct-ord__card-chev svg{width:100%;height:100%;}

/* Meta row: dot-separated key/value pairs. flex-wrap so long rows
   gracefully wrap on narrow viewports. */
.rh-acct-ord__meta{
	list-style:none;
	margin:0.625rem 0 0;
	padding:0;
	display:flex;
	flex-wrap:wrap;
	align-items:center;
	gap:0.375rem 0.625rem;
	font-size:var(--wp--preset--font-size--sm,0.875rem);
	color:var(--wp--preset--color--text-muted,#5b6271);
}
.rh-acct-ord__meta li{margin:0;}
.rh-acct-ord__meta-sep{color:var(--wp--preset--color--border,#e2e4e9);}
.rh-acct-ord__meta-savings{color:var(--wp--preset--color--success,#198754);font-weight:var(--wp--custom--fw--strong);}
.rh-acct-ord__meta .woocommerce-Price-amount{color:var(--wp--preset--color--text,#1a1d23);font-weight:var(--wp--custom--fw--strong);}

/* Product thumbnails strip */
.rh-acct-ord__thumbs{
	display:flex;
	align-items:center;
	gap:0.5rem;
	margin-block-start:0.875rem;
	padding-block-start:0.875rem;
	border-top:1px dashed var(--wp--preset--color--border,#e2e4e9);
	flex-wrap:wrap;
}
.rh-acct-ord__thumb{
	display:inline-flex;
	align-items:center;
	justify-content:center;
	width:48px;
	height:48px;
	border-radius:var(--wp--custom--radius--md);
	background:var(--wp--preset--color--surface,#f7f7f8);
	border:1px solid var(--wp--preset--color--border,#e2e4e9);
	overflow:hidden;
	flex-shrink:0;
}
.rh-acct-ord__thumb img{width:100%;height:100%;object-fit:contain;}
.rh-acct-ord__thumb--more{
	background:var(--wp--preset--color--muted,#eceef1);
	color:var(--wp--preset--color--text-muted,#5b6271);
	font-size:var(--wp--preset--font-size--sm,0.875rem);
	font-weight:var(--wp--custom--fw--strong);
}

/* Card footer with the invoice link */
.rh-acct-ord__card-foot{
	display:flex;
	align-items:center;
	justify-content:flex-end;
	padding:0.625rem 1.125rem;
	border-top:1px solid var(--wp--preset--color--border,#e2e4e9);
	background:var(--wp--preset--color--surface,#f7f7f8);
}
.rh-acct-ord__invoice-link{
	display:inline-flex;
	align-items:center;
	gap:0.375rem;
	color:var(--wp--preset--color--primary,#0a66c2);
	font-size:var(--wp--preset--font-size--sm,0.875rem);
	font-weight:var(--wp--custom--fw--strong);
	text-decoration:none;
}
.rh-acct-ord__invoice-link:hover{text-decoration:underline;}
.rh-acct-ord__invoice-link svg{width:16px;height:16px;}

/* Pagination — WC's paginate_links( type=list ) outputs <ul class="page-numbers"> */
.rh-acct-ord__pagination{margin-block-start:1.25rem;}
.rh-acct-ord__pagination .page-numbers{
	list-style:none;
	margin:0;
	padding:0;
	display:flex;
	align-items:center;
	justify-content:center;
	gap:0.25rem;
}
.rh-acct-ord__pagination .page-numbers li > *{
	display:inline-flex;
	align-items:center;
	justify-content:center;
	min-width:2.25rem;
	height:2.25rem;
	padding-inline:0.5rem;
	border:1px solid var(--wp--preset--color--border,#e2e4e9);
	border-radius:var(--wp--custom--radius--md);
	background:var(--wp--preset--color--base,#fff);
	color:var(--wp--preset--color--text,#1a1d23);
	font-size:var(--wp--preset--font-size--sm,0.875rem);
	text-decoration:none;
}
.rh-acct-ord__pagination .page-numbers .current{
	background:var(--wp--preset--color--primary,#0a66c2);
	border-color:var(--wp--preset--color--primary,#0a66c2);
	color:var(--wp--custom--on-primary, #fff);
}

/* Empty state */
.rh-acct-ord__empty{
	background:var(--wp--preset--color--base,#fff);
	border:1px solid var(--wp--preset--color--border,#e2e4e9);
	border-radius:var(--wp--custom--radius--xl,1rem);
	padding:3rem 1.5rem;
	text-align:center;
}
.rh-acct-ord__empty-icon{
	width:64px;height:64px;
	margin:0 auto 1rem;
	display:inline-flex;
	align-items:center;
	justify-content:center;
	border-radius:50%;
	background:var(--wp--preset--color--surface,#f7f7f8);
	color:var(--wp--preset--color--primary,#0a66c2);
}
.rh-acct-ord__empty-icon svg{width:32px;height:32px;}
.rh-acct-ord__empty-text{
	margin:0 0 1rem;
	font-size:var(--wp--preset--font-size--md,1rem);
	color:var(--wp--preset--color--text,#1a1d23);
}
.rh-acct-ord__empty-cta{
	display:inline-flex;
	align-items:center;
	padding:0.6rem 1.25rem;
	background:var(--wp--preset--color--primary,#0a66c2);
	color:var(--wp--custom--on-primary, #fff);
	border-radius:var(--wp--custom--radius--md);
	font-weight:var(--wp--custom--fw--strong);
	text-decoration:none;
}
.rh-acct-ord__empty-cta:hover{background:var(--wp--preset--color--primary-dark,#074a8d);color:var(--wp--custom--on-primary, #fff);text-decoration:none;}

/* ---------- View-Order page ---------------------------------------------- */
.rh-ord-view{padding-block:1rem;}

.rh-ord-view__top{
	display:flex;
	align-items:center;
	justify-content:space-between;
	gap:0.75rem;
	margin-block-end:1rem;
}
.rh-ord-view__back{
	display:inline-flex;
	align-items:center;
	gap:0.5rem;
	font-weight:var(--wp--custom--fw--strong);
	font-size:var(--wp--preset--font-size--md,1.125rem);
	color:var(--wp--preset--color--contrast,#0f1115);
	text-decoration:none;
}
.rh-ord-view__back:hover{text-decoration:none;color:var(--wp--preset--color--contrast,#0f1115);}
.rh-ord-view__back svg{width:20px;height:20px;}
.rh-ord-view__invoice{
	display:inline-flex;
	align-items:center;
	gap:0.375rem;
	color:var(--wp--preset--color--primary,#0a66c2);
	font-size:var(--wp--preset--font-size--sm,0.875rem);
	font-weight:var(--wp--custom--fw--strong);
	text-decoration:none;
}
.rh-ord-view__invoice:hover{text-decoration:underline;}
.rh-ord-view__invoice svg{width:16px;height:16px;}

/* Info card */
.rh-ord-view__info{display:flex;flex-direction:column;gap:1.125rem;}
.rh-ord-view__info-grid{
	display:grid;
	grid-template-columns:repeat(2,minmax(0,1fr));
	gap:0.75rem 2rem;
}
.rh-ord-view__info-field{
	display:flex;
	align-items:baseline;
	gap:0.5rem;
	min-width:0;
}
.rh-ord-view__info-row{
	display:flex;
	gap:0.5rem;
	padding-block:0.75rem;
	border-top:1px solid var(--wp--preset--color--border,#e2e4e9);
	border-bottom:1px solid var(--wp--preset--color--border,#e2e4e9);
}
.rh-ord-view__info-label{
	color:var(--wp--preset--color--text-muted,#5b6271);
	font-size:var(--wp--preset--font-size--sm,0.875rem);
	flex-shrink:0;
}
.rh-ord-view__info-value{
	color:var(--wp--preset--color--text,#1a1d23);
	font-weight:var(--wp--custom--fw--strong);
	font-size:var(--wp--preset--font-size--sm,0.875rem);
	min-width:0;
	word-break:break-word;
}
.rh-ord-view__info-value--ltr{direction:ltr;unicode-bidi:isolate;}

.rh-ord-view__totals{
	display:flex;
	flex-wrap:wrap;
	gap:0.75rem 2rem;
}
.rh-ord-view__total{display:flex;align-items:baseline;gap:0.5rem;}
.rh-ord-view__total--savings .rh-ord-view__info-value{color:var(--wp--preset--color--success,#198754);}

/* Transactions disclosure */
.rh-ord-view__history{
	border-top:1px solid var(--wp--preset--color--border,#e2e4e9);
	padding-block-start:0.5rem;
}
.rh-ord-view__history > summary{
	display:flex;
	align-items:center;
	justify-content:space-between;
	gap:0.5rem;
	padding:0.625rem 0;
	cursor:pointer;
	list-style:none;
	color:var(--wp--preset--color--primary,#0a66c2);
	font-weight:var(--wp--custom--fw--strong);
	font-size:var(--wp--preset--font-size--sm,0.875rem);
}
.rh-ord-view__history > summary::-webkit-details-marker{display:none;}
.rh-ord-view__history > summary svg{
	width:16px;height:16px;
	transition:transform .15s;
}
.rh-ord-view__history[open] > summary svg{transform:rotate(180deg);}
.rh-ord-view__history-list{
	list-style:none;
	margin:0;
	padding:0.5rem 0 0;
	display:flex;
	flex-direction:column;
	gap:0.75rem;
}
.rh-ord-view__history-list li{
	padding:0.625rem 0.75rem;
	background:var(--wp--preset--color--surface,#f7f7f8);
	border-radius:var(--wp--custom--radius--md);
}
.rh-ord-view__history-date{
	display:block;
	font-size:var(--wp--preset--font-size--xs,0.75rem);
	color:var(--wp--preset--color--text-muted,#5b6271);
	margin-block-end:0.25rem;
}
.rh-ord-view__history-text{margin:0;font-size:var(--wp--preset--font-size--sm,0.875rem);}

/* Shipment card */
.rh-ord-view__shipment{display:flex;flex-direction:column;gap:1rem;}
.rh-ord-view__ship-head{
	display:flex;
	align-items:center;
	justify-content:space-between;
	gap:0.5rem;
}
.rh-ord-view__ship-title{
	font-weight:var(--wp--custom--fw--strong);
	font-size:var(--wp--preset--font-size--md,1rem);
	color:var(--wp--preset--color--contrast,#0f1115);
}
.rh-ord-view__ship-status{
	display:inline-flex;
	align-items:center;
	gap:0.375rem;
	font-size:var(--wp--preset--font-size--sm,0.875rem);
	font-weight:var(--wp--custom--fw--strong);
}
.rh-ord-view__ship-dot{
	display:inline-block;
	width:0.5rem;height:0.5rem;
	border-radius:50%;
	background:currentColor;
}

/* Progress bar */
.rh-ord-view__progress{display:flex;flex-direction:column;gap:0.5rem;}
.rh-ord-view__progress-track{
	height:0.5rem;
	background:var(--wp--preset--color--muted,#eceef1);
	border-radius:var(--wp--custom--radius--pill);
	overflow:hidden;
}
.rh-ord-view__progress-fill{
	height:100%;
	border-radius:inherit;
	transition:width .25s ease;
}
.rh-ord-view__progress-fill--success{background:var(--wp--preset--color--success,#198754);}
.rh-ord-view__progress-fill--warning{background:var(--wp--preset--color--warning,#d97706);}
.rh-ord-view__progress-fill--danger{background:var(--wp--preset--color--danger,#dc2626);}
.rh-ord-view__progress-fill--primary{background:var(--wp--preset--color--primary,#0a66c2);}
.rh-ord-view__progress-label{
	margin:0;
	font-size:var(--wp--preset--font-size--sm,0.875rem);
	color:var(--wp--preset--color--text,#1a1d23);
	font-weight:var(--wp--custom--fw--strong);
	text-align:center;
}

/* Ship meta row (shipping fee, tracking, free badge) */
.rh-ord-view__ship-meta{
	display:flex;
	flex-wrap:wrap;
	gap:0.5rem 1.5rem;
	padding-block:0.625rem;
	border-top:1px solid var(--wp--preset--color--border,#e2e4e9);
	border-bottom:1px solid var(--wp--preset--color--border,#e2e4e9);
}
.rh-ord-view__ship-meta-item{
	display:inline-flex;
	align-items:center;
	gap:0.375rem;
	font-size:var(--wp--preset--font-size--sm,0.875rem);
}
.rh-ord-view__ship-free{
	color:var(--wp--preset--color--primary,#0a66c2);
	font-weight:var(--wp--custom--fw--strong);
}
.rh-ord-view__ship-free svg{width:16px;height:16px;}

/* Items list */
.rh-ord-view__items{
	list-style:none;
	margin:0;
	padding:0;
	display:flex;
	flex-direction:column;
	gap:0.875rem;
}
.rh-ord-view__item{
	display:grid;
	grid-template-columns:64px 1fr auto;
	gap:0.875rem;
	align-items:center;
	padding-block:0.625rem;
	border-bottom:1px dashed var(--wp--preset--color--border,#e2e4e9);
}
.rh-ord-view__item:last-child{border-bottom:0;padding-bottom:0;}
.rh-ord-view__item-img{
	width:64px;height:64px;
	border-radius:var(--wp--custom--radius--md);
	background:var(--wp--preset--color--surface,#f7f7f8);
	border:1px solid var(--wp--preset--color--border,#e2e4e9);
	overflow:hidden;
}
.rh-ord-view__item-img img{width:100%;height:100%;object-fit:contain;}
.rh-ord-view__item-body{min-width:0;}
.rh-ord-view__item-name{
	display:block;
	font-weight:var(--wp--custom--fw--strong);
	font-size:var(--wp--preset--font-size--sm,0.875rem);
	color:var(--wp--preset--color--text,#1a1d23);
	text-decoration:none;
	margin-block-end:0.25rem;
	line-height:1.5;
}
.rh-ord-view__item-name:hover{color:var(--wp--preset--color--primary,#0a66c2);text-decoration:none;}
.rh-ord-view__item-attrs{
	list-style:none;
	margin:0;
	padding:0;
	display:flex;
	flex-wrap:wrap;
	gap:0.25rem 0.625rem;
	font-size:var(--wp--preset--font-size--xs,0.75rem);
	color:var(--wp--preset--color--text-muted,#5b6271);
}
.rh-ord-view__item-side{
	display:flex;
	flex-direction:column;
	align-items:flex-end;
	gap:0.25rem;
	white-space:nowrap;
}
.rh-ord-view__item-qty{
	font-size:var(--wp--preset--font-size--xs,0.75rem);
	color:var(--wp--preset--color--text-muted,#5b6271);
}
.rh-ord-view__item-price{
	font-weight:var(--wp--custom--fw--strong);
	font-size:var(--wp--preset--font-size--sm,0.875rem);
	color:var(--wp--preset--color--text,#1a1d23);
}

/* Per-item "rate this" widget — only rendered for items in a completed
   order that the visitor hasn't reviewed yet (gate in view-order.php).
   Spans the item's full grid width on a new row underneath, sharing the
   stars+CTA markup with the my-account/reviews cards so the modal-opening
   contract stays identical across the site. */
.rh-ord-view__item-rate{
	grid-column:1 / -1;
	display:flex;
	align-items:center;
	flex-wrap:wrap;
	gap:0.625rem 0.875rem;
	padding-block-start:0.875rem;
	margin-block-start:0.25rem;
	border-block-start:1px dashed var(--wp--preset--color--border,#e2e4e9);
}
.rh-ord-view__item-rate-prompt{
	font-size:var(--wp--preset--font-size--sm,0.875rem);
	font-weight:var(--wp--custom--fw--strong);
	color:var(--wp--preset--color--contrast,#0f1115);
}
.rh-ord-view__item-rate .rh-acct-rev__card-stars{
	margin:0;
}
.rh-ord-view__item-rate .rh-acct-rev__card-cta{
	/* Cancel the my-account-card context (full-width + push-to-bottom)
	   so the CTA sits inline as a compact pill on the order line. */
	width:auto;
	min-width:9rem;
	min-height:var(--wp--custom--button--h--sm,36px);
	padding:0 var(--wp--custom--button--px--md,20px);
	font-size:var(--wp--custom--button--fs--sm,0.875rem);
	margin-block-start:0;
	/* Push to the far inline-end of the row (visual left in RTL) — keeps
	   the prompt+stars cluster tight on the inline-start side. */
	margin-inline-start:auto;
}

/* ---------- Mobile tweaks ------------------------------------------------- */
@media (max-width:600px){
	.rh-acct-ord__card-link{padding:0.875rem 1rem;}
	.rh-acct-ord__card-foot{padding:0.5rem 1rem;}
	.rh-acct-ord__thumbs{gap:0.375rem;}
	.rh-acct-ord__thumb{width:42px;height:42px;}
	.rh-acct-ord__title{font-size:var(--wp--preset--font-size--md,1.125rem);}

	.rh-ord-view__info-grid{grid-template-columns:1fr;gap:0.625rem;}
	.rh-ord-view__totals{flex-direction:column;gap:0.5rem;}
	.rh-ord-view__item{
		grid-template-columns:56px 1fr;
		grid-template-areas:
			"img body"
			"img side"
			"rate rate";
		row-gap:0.375rem;
	}
	.rh-ord-view__item-img{grid-area:img;width:56px;height:56px;}
	.rh-ord-view__item-body{grid-area:body;}
	.rh-ord-view__item-side{grid-area:side;align-items:flex-start;flex-direction:row;justify-content:space-between;width:100%;}
	.rh-ord-view__item-rate{
		grid-area:rate;
		margin-block-start:0.5rem;
	}
	.rh-ord-view__item-rate .rh-acct-rev__card-cta{
		width:100%;
		min-width:0;
		margin-inline-start:0;
	}
}

/* =========================================================================
 *  My Account → "آدرس‌های من" — index card (my-address.php) + form
 *  (form-edit-address.php).
 * =========================================================================
 *
 *  Single-address model — see inc/account-addresses.php for the data
 *  contract. The form mirrors checkout's address step visually but
 *  uses a bigger layout (full-width inputs, ample spacing) since the
 *  user isn't in a hurry here like at checkout.
 */

.rh-acct-addr{padding-block:1rem;}

.rh-acct-addr__header{margin-block-end:1rem;}
.rh-acct-addr__title{
	margin:0 0 0.25rem;
	font-size:var(--wp--preset--font-size--lg,1.25rem);
	font-weight:var(--wp--custom--fw--strong);
	color:var(--wp--preset--color--contrast,#0f1115);
}
.rh-acct-addr__hint{
	margin:0;
	font-size:var(--wp--preset--font-size--sm,0.875rem);
	color:var(--wp--preset--color--text-muted,#5b6271);
}

/* ---------- Saved address card -------------------------------------------- */
.rh-acct-addr__card{
	background:var(--wp--preset--color--base,#fff);
	border:1px solid var(--wp--preset--color--border,#e2e4e9);
	border-radius:var(--wp--custom--radius--xl,1rem);
	padding:1.25rem 1.25rem 1rem;
}
.rh-acct-addr__card-head{
	display:flex;
	align-items:center;
	gap:0.875rem;
	padding-bottom:1rem;
	border-bottom:1px solid var(--wp--preset--color--border,#e2e4e9);
	margin-bottom:1rem;
}
.rh-acct-addr__card-icon{
	display:inline-flex;
	align-items:center;
	justify-content:center;
	width:44px;height:44px;
	border-radius:50%;
	background:color-mix(in srgb,var(--wp--preset--color--primary,#0a66c2) 10%,transparent);
	color:var(--wp--preset--color--primary,#0a66c2);
	flex-shrink:0;
}
.rh-acct-addr__card-icon svg{width:22px;height:22px;}
.rh-acct-addr__card-head-text{flex:1;min-width:0;line-height:1.3;}
.rh-acct-addr__card-eyebrow{
	margin:0 0 0.125rem;
	font-size:var(--wp--preset--font-size--xs,0.75rem);
	color:var(--wp--preset--color--text-muted,#5b6271);
}
.rh-acct-addr__card-region{
	margin:0;
	font-size:var(--wp--preset--font-size--md,1rem);
	font-weight:var(--wp--custom--fw--strong);
	color:var(--wp--preset--color--contrast,#0f1115);
}
.rh-acct-addr__card-edit{
	display:inline-flex;
	align-items:center;
	justify-content:center;
	gap:var(--wp--custom--button--gap,8px);
	min-height:var(--wp--custom--button--h--sm,36px);
	padding:0 var(--wp--custom--button--px--sm,14px);
	border:1px solid var(--wp--preset--color--primary,#0a66c2);
	border-radius:var(--wp--custom--button--radius,10px);
	color:var(--wp--preset--color--primary,#0a66c2);
	font-size:var(--wp--custom--button--fs--sm,0.875rem);
	font-weight:var(--wp--custom--button--fw,600);
	text-decoration:none;
	transition:background-color .15s,color .15s;
	flex-shrink:0;
}
.rh-acct-addr__card-edit:hover{
	background:var(--wp--preset--color--primary,#0a66c2);
	color:var(--wp--custom--on-primary, #fff);
	text-decoration:none;
}
.rh-acct-addr__card-edit svg{width:14px;height:14px;}

.rh-acct-addr__card-grid{
	margin:0;
	display:grid;
	grid-template-columns:repeat(2,minmax(0,1fr));
	gap:1rem 1.5rem;
}
.rh-acct-addr__row{margin:0;min-width:0;}
.rh-acct-addr__row--full{grid-column:1/-1;}
.rh-acct-addr__row dt{
	display:flex;
	align-items:center;
	gap:0.375rem;
	font-size:var(--wp--preset--font-size--xs,0.75rem);
	color:var(--wp--preset--color--text-muted,#5b6271);
	margin-block-end:0.25rem;
}
.rh-acct-addr__row dt svg{width:14px;height:14px;opacity:.7;}
.rh-acct-addr__row dd{
	margin:0;
	font-size:var(--wp--preset--font-size--sm,0.875rem);
	color:var(--wp--preset--color--text,#1a1d23);
	font-weight:var(--wp--custom--fw--strong);
	line-height:1.6;
	word-break:break-word;
}
.rh-acct-addr__value--ltr{direction:ltr;unicode-bidi:isolate;text-align:right;}

/* ---------- Empty state --------------------------------------------------- */
.rh-acct-addr__empty{
	background:var(--wp--preset--color--base,#fff);
	border:1px dashed var(--wp--preset--color--border,#e2e4e9);
	border-radius:var(--wp--custom--radius--xl,1rem);
	padding:2.5rem 1.5rem;
	text-align:center;
}
.rh-acct-addr__empty-icon{
	width:64px;height:64px;
	margin:0 auto 1rem;
	display:inline-flex;
	align-items:center;
	justify-content:center;
	border-radius:50%;
	background:color-mix(in srgb,var(--wp--preset--color--primary,#0a66c2) 10%,transparent);
	color:var(--wp--preset--color--primary,#0a66c2);
}
.rh-acct-addr__empty-icon svg{width:30px;height:30px;}
.rh-acct-addr__empty-title{
	margin:0 0 0.375rem;
	font-size:var(--wp--preset--font-size--md,1.125rem);
	font-weight:var(--wp--custom--fw--strong);
	color:var(--wp--preset--color--contrast,#0f1115);
}
.rh-acct-addr__empty-desc{
	margin:0 0 1.25rem;
	font-size:var(--wp--preset--font-size--sm,0.875rem);
	color:var(--wp--preset--color--text-muted,#5b6271);
}
.rh-acct-addr__empty-cta{
	display:inline-flex;
	align-items:center;
	gap:0.5rem;
	padding:0.625rem 1.5rem;
	background:var(--wp--preset--color--primary,#0a66c2);
	color:var(--wp--custom--on-primary, #fff);
	border-radius:var(--wp--custom--radius--md);
	font-weight:var(--wp--custom--fw--strong);
	font-size:var(--wp--preset--font-size--sm,0.875rem);
	text-decoration:none;
	transition:background-color .15s;
}
.rh-acct-addr__empty-cta:hover{background:var(--wp--preset--color--primary-dark,#074a8d);color:var(--wp--custom--on-primary, #fff);text-decoration:none;}
.rh-acct-addr__empty-cta svg{width:16px;height:16px;}

/* ---------- Form ---------------------------------------------------------- */
.rh-acct-addr__form-head{margin-block-end:1rem;}
.rh-acct-addr__form-back{
	display:inline-flex;
	align-items:center;
	gap:0.5rem;
	font-weight:var(--wp--custom--fw--strong);
	font-size:var(--wp--preset--font-size--md,1.125rem);
	color:var(--wp--preset--color--contrast,#0f1115);
	text-decoration:none;
}
.rh-acct-addr__form-back:hover{color:var(--wp--preset--color--contrast,#0f1115);text-decoration:none;}
.rh-acct-addr__form-back svg{width:20px;height:20px;}

.rh-acct-addr__form{
	background:var(--wp--preset--color--base,#fff);
	border:1px solid var(--wp--preset--color--border,#e2e4e9);
	border-radius:var(--wp--custom--radius--xl,1rem);
	padding:1.5rem;
}
.rh-acct-addr__form-grid{
	display:grid;
	grid-template-columns:repeat(2,minmax(0,1fr));
	gap:1rem 1.25rem;
}
.rh-acct-addr__field{display:flex;flex-direction:column;gap:0.375rem;min-width:0;}
.rh-acct-addr__field--col{grid-column:span 1;}
.rh-acct-addr__field--full{grid-column:1/-1;}
.rh-acct-addr__field label{
	display:inline-flex;
	align-items:center;
	gap:0.25rem;
	font-size:var(--wp--preset--font-size--sm,0.875rem);
	font-weight:var(--wp--custom--fw--strong);
	color:var(--wp--preset--color--text,#1a1d23);
}
.rh-acct-addr__req{color:var(--wp--preset--color--danger,#dc2626);font-weight:var(--wp--custom--fw--strong);}

.rh-acct-addr__field input,
.rh-acct-addr__field select,
.rh-acct-addr__field textarea{
	display:block;
	width:100%;
	padding:0.625rem 0.875rem;
	border:1px solid var(--wp--preset--color--border,#e2e4e9);
	border-radius:var(--wp--custom--radius--md);
	background:var(--wp--preset--color--base,#fff);
	color:var(--wp--preset--color--text,#1a1d23);
	font:inherit;
	font-size:var(--wp--preset--font-size--sm,0.875rem);
	line-height:1.6;
	transition:border-color .12s, box-shadow .12s;
}
.rh-acct-addr__field input:focus,
.rh-acct-addr__field select:focus,
.rh-acct-addr__field textarea:focus{
	outline:0;
	border-color:var(--wp--preset--color--primary,#0a66c2);
	box-shadow:0 0 0 3px color-mix(in srgb,var(--wp--preset--color--primary,#0a66c2) 18%,transparent);
}
.rh-acct-addr__field select:disabled{
	background:var(--wp--preset--color--surface,#f7f7f8);
	color:var(--wp--preset--color--text-muted,#5b6271);
	cursor:not-allowed;
}
.rh-acct-addr__field textarea{resize:vertical;min-height:5.5rem;}
.rh-acct-addr__hint-text{
	margin:0;
	font-size:var(--wp--preset--font-size--xs,0.75rem);
	color:var(--wp--preset--color--text-muted,#5b6271);
}

.rh-acct-addr__form-actions{
	display:flex;
	align-items:center;
	justify-content:flex-start;
	gap:0.75rem;
	margin-block-start:1.5rem;
	padding-block-start:1.25rem;
	border-top:1px solid var(--wp--preset--color--border,#e2e4e9);
}
.rh-acct-addr__submit{
	display:inline-flex;
	align-items:center;
	gap:0.5rem;
	padding:0.7rem 1.5rem;
	background:var(--wp--preset--color--primary,#0a66c2);
	color:var(--wp--custom--on-primary, #fff);
	border:0;
	border-radius:var(--wp--custom--radius--md);
	font:inherit;
	font-weight:var(--wp--custom--fw--strong);
	font-size:var(--wp--preset--font-size--sm,0.875rem);
	cursor:pointer;
	transition:background-color .15s;
}
.rh-acct-addr__submit:hover{background:var(--wp--preset--color--primary-dark,#074a8d);}
.rh-acct-addr__submit svg{width:16px;height:16px;}
.rh-acct-addr__cancel{
	color:var(--wp--preset--color--text-muted,#5b6271);
	font-size:var(--wp--preset--font-size--sm,0.875rem);
	text-decoration:none;
}
.rh-acct-addr__cancel:hover{color:var(--wp--preset--color--text,#1a1d23);text-decoration:underline;}

@media (max-width:600px){
	.rh-acct-addr__title{font-size:var(--wp--preset--font-size--md,1.125rem);}
	.rh-acct-addr__card{padding:1rem;}
	.rh-acct-addr__card-grid{grid-template-columns:1fr;gap:0.875rem;}
	.rh-acct-addr__card-head{flex-wrap:wrap;}
	.rh-acct-addr__card-edit{order:3;width:100%;justify-content:center;}
	.rh-acct-addr__form{padding:1.125rem;}
	.rh-acct-addr__form-grid{grid-template-columns:1fr;gap:0.875rem;}
}

/* =========================================================================
 *  My Account → "پیام‌ها" (notification center) + sidebar unread badge
 * =========================================================================
 *  Markup lives in:
 *    - inc/notifications.php   (.rahkar-notif* — list, item, pagination)
 *    - woocommerce/myaccount/navigation.php  (.rahkar-account__nav-badge)
 *
 *  Design intent: a flat list (one row per notification), no avatars or
 *  attachments. Unread items get a coloured leading dot + a faint surface
 *  tint so they read at a glance. Once the user opens the page, the
 *  renderer marks all as read after the markup is emitted — so the very
 *  same page render still shows the dots, but the next visit doesn't.
 * ========================================================================= */

/* ---------- Sidebar badge (unread count on the menu row) ---------------- */
.rahkar-account__nav-badge{
	display:inline-flex;
	align-items:center;
	justify-content:center;
	min-width:1.25rem;
	height:1.25rem;
	padding:0 0.4rem;
	border-radius:var(--wp--custom--radius--pill);
	background:var(--wp--preset--color--accent,#e63946);
	color:#fff;
	font-size:0.6875rem;
	font-weight:var(--wp--custom--fw--strong);
	line-height:1;
	flex-shrink:0;
}
/* On the active row the accent background already has enough contrast
 * against the primary fill — no override needed. */

/* ---------- Notification list container ---------------------------------
 * Outer shell mirrors the .rh-acct-ord baseline (no outer card; just
 * padding-block:1rem + lg-size header title). The list cards inside keep
 * their own white surface — the section frame is identical to other
 * custom account screens. */
.rahkar-notif{padding-block:1rem;}
.rahkar-notif__header{
	display:flex;
	align-items:center;
	justify-content:space-between;
	gap:1rem;
	margin-block-end:1rem;
}
.rahkar-notif__title{
	font-size:var(--wp--preset--font-size--lg,1.25rem);
	font-weight:var(--wp--custom--fw--strong);
	margin:0;
	color:var(--wp--preset--color--contrast,#0f1115);
}
.rahkar-notif__total{
	font-size:var(--wp--preset--font-size--xs,0.75rem);
	color:var(--wp--preset--color--text-muted,#5b6271);
}

.rahkar-notif__list{
	list-style:none;
	margin:0;
	padding:0;
	display:flex;
	flex-direction:column;
	gap:0.5rem;
}

/* ---------- A single row ------------------------------------------------- */
.rahkar-notif__item{margin:0;}
.rahkar-notif__item-inner{
	display:flex;
	align-items:flex-start;
	gap:0.875rem;
	padding:0.875rem 1rem;
	background:var(--wp--preset--color--surface,#f7f7f8);
	border:1px solid var(--wp--preset--color--border,#e2e4e9);
	border-radius:var(--wp--custom--radius--lg);
	color:inherit;
	text-decoration:none;
	transition:background-color .15s,border-color .15s;
}
a.rahkar-notif__item-inner:hover{
	background:var(--wp--preset--color--muted,#eceef1);
	text-decoration:none;
	color:inherit;
}

/* Leading dot — coloured for unread, neutral for read */
.rahkar-notif__dot{
	width:0.5rem;
	height:0.5rem;
	border-radius:50%;
	background:transparent;
	border:1.5px solid var(--wp--preset--color--border,#e2e4e9);
	margin-top:0.375rem;
	flex-shrink:0;
}
.rahkar-notif__item.is-unread .rahkar-notif__item-inner{
	background:var(--wp--preset--color--base,#fff);
	border-color:var(--wp--preset--color--primary-soft,#d8e6f5);
}
.rahkar-notif__item.is-unread .rahkar-notif__dot{
	background:var(--wp--preset--color--accent,#e63946);
	border-color:var(--wp--preset--color--accent,#e63946);
}

.rahkar-notif__body{
	flex:1;
	min-width:0;
}
.rahkar-notif__row-top{
	display:flex;
	align-items:baseline;
	justify-content:space-between;
	gap:0.75rem;
	margin-bottom:0.25rem;
}
.rahkar-notif__item-title{
	font-size:var(--wp--preset--font-size--sm,0.9375rem);
	font-weight:var(--wp--custom--fw--strong);
	margin:0;
	color:var(--wp--preset--color--contrast,#0f1115);
}
.rahkar-notif__item.is-unread .rahkar-notif__item-title{
	color:var(--wp--preset--color--text,#1a1d23);
}
.rahkar-notif__time{
	font-size:var(--wp--preset--font-size--xs,0.75rem);
	color:var(--wp--preset--color--text-muted,#5b6271);
	white-space:nowrap;
	flex-shrink:0;
}
.rahkar-notif__message{
	font-size:var(--wp--preset--font-size--sm,0.875rem);
	color:var(--wp--preset--color--text,#1a1d23);
	margin:0;
	line-height:1.7;
}

/* ---------- Pagination footer ------------------------------------------- */
.rahkar-notif__pagination{
	display:flex;
	align-items:center;
	justify-content:space-between;
	gap:1rem;
	margin-top:1.25rem;
	padding-top:1rem;
	border-top:1px solid var(--wp--preset--color--border,#e2e4e9);
}
.rahkar-notif__page-info{
	font-size:var(--wp--preset--font-size--xs,0.75rem);
	color:var(--wp--preset--color--text-muted,#5b6271);
}
.rahkar-notif__page-link{
	display:inline-flex;
	align-items:center;
	padding:0.4rem 0.875rem;
	border-radius:var(--wp--custom--radius--md);
	background:var(--wp--preset--color--surface,#f7f7f8);
	border:1px solid var(--wp--preset--color--border,#e2e4e9);
	font-size:var(--wp--preset--font-size--sm,0.875rem);
	color:var(--wp--preset--color--text,#1a1d23);
	text-decoration:none;
	transition:background-color .15s;
}
.rahkar-notif__page-link:hover{
	background:var(--wp--preset--color--muted,#eceef1);
	text-decoration:none;
	color:var(--wp--preset--color--text,#1a1d23);
}

/* ---------- Mobile tweaks ----------------------------------------------- */
@media (max-width:600px){
	.rahkar-notif__title{font-size:var(--wp--preset--font-size--md,1.125rem);}
	.rahkar-notif__item-inner{padding:0.75rem 0.875rem;gap:0.625rem;}
	.rahkar-notif__row-top{flex-wrap:wrap;gap:0.25rem;}
	.rahkar-notif__time{font-size:0.6875rem;}
}

/* =========================================================================
 *  Transactions endpoint  (woocommerce/myaccount/transactions.php)
 *  -----------------------------------------------------------------------
 *  Borrows the .rh-acct-ord__status--* color variants (declared above) so
 *  the badge palette stays consistent across orders ↔ transactions. Layout
 *  is its own card style — transactions are key/value heavy (no thumbs).
 * ========================================================================= */
/* Container — matches the orders shell (padding-block:1rem). */
.rh-acct-tx{padding-block:1rem;}

.rh-acct-tx__header{
	display:flex;
	align-items:center;
	justify-content:space-between;
	gap:0.75rem;
	margin-block-end:1rem;
}
.rh-acct-tx__title{
	margin:0;
	font-size:var(--wp--preset--font-size--lg,1.25rem);
	font-weight:var(--wp--custom--fw--strong);
	color:var(--wp--preset--color--contrast,#0f1115);
}
.rh-acct-tx__count{
	font-size:var(--wp--preset--font-size--sm,0.875rem);
	color:var(--wp--preset--color--text-muted,#5b6271);
}

.rh-acct-tx__list{
	list-style:none;
	margin:0;
	padding:0;
	display:flex;
	flex-direction:column;
	gap:0.75rem;
}

.rh-acct-tx__card{
	background:var(--wp--preset--color--base,#fff);
	border:1px solid var(--wp--preset--color--border,#e2e4e9);
	border-radius:var(--wp--custom--radius--xl,1rem);
	padding:1rem 1.125rem;
	display:flex;
	flex-direction:column;
	gap:0.875rem;
	transition:border-color .15s, box-shadow .15s;
}
.rh-acct-tx__card:hover{
	border-color:var(--wp--preset--color--muted,#eceef1);
	box-shadow:var(--wp--preset--shadow--xs,0 1px 2px rgba(15,17,21,0.06));
}

.rh-acct-tx__card-head{
	display:flex;
	align-items:center;
	justify-content:space-between;
	gap:0.75rem;
	padding-block-end:0.75rem;
	border-block-end:1px dashed var(--wp--preset--color--border,#e2e4e9);
}

.rh-acct-tx__status{
	display:inline-flex;
	align-items:center;
	gap:0.4rem;
	font-weight:var(--wp--custom--fw--strong);
	font-size:var(--wp--preset--font-size--sm,0.875rem);
}
.rh-acct-tx__status-icon{
	display:inline-flex;
	align-items:center;
	justify-content:center;
	width:1.25rem;
	height:1.25rem;
}
.rh-acct-tx__status-icon svg{width:100%;height:100%;}
.rh-acct-tx__status--success{color:var(--wp--preset--color--success,#198754);}
.rh-acct-tx__status--warning{color:var(--wp--preset--color--warning,#d97706);}
.rh-acct-tx__status--primary{color:var(--wp--preset--color--primary,#0a66c2);}

.rh-acct-tx__amount{
	font-weight:var(--wp--custom--fw--strong);
	font-size:var(--wp--preset--font-size--lg,1.25rem);
	color:var(--wp--preset--color--contrast,#0f1115);
	line-height:1.2;
}
.rh-acct-tx__amount .woocommerce-Price-amount{font-weight:inherit;color:inherit;}

.rh-acct-tx__body{
	margin:0;
	display:flex;
	flex-direction:column;
	gap:0.5rem;
}
.rh-acct-tx__row{
	display:flex;
	align-items:center;
	justify-content:space-between;
	gap:0.75rem;
	margin:0;
	min-height:1.5rem;
}
.rh-acct-tx__row-label{
	margin:0;
	color:var(--wp--preset--color--text-muted,#5b6271);
	font-size:var(--wp--preset--font-size--sm,0.875rem);
}
.rh-acct-tx__row-value{
	margin:0;
	color:var(--wp--preset--color--text,#1a1d23);
	font-size:var(--wp--preset--font-size--sm,0.875rem);
	font-weight:var(--wp--custom--fw--strong);
	text-align:left;
	direction:ltr;
	unicode-bidi:plaintext;
}

/* Reference number row — number + copy button inline */
.rh-acct-tx__row--ref .rh-acct-tx__row-value{
	display:inline-flex;
	align-items:center;
	gap:0.4rem;
}
.rh-acct-tx__ref-num{
	font-family:var(--wp--preset--font-family--mono,ui-monospace,Menlo,monospace);
	font-size:var(--wp--preset--font-size--sm,0.875rem);
	letter-spacing:0.01em;
	background:var(--wp--preset--color--surface,#f7f7f8);
	padding:0.2rem 0.5rem;
	border-radius:var(--wp--custom--radius--sm,0.25rem);
}
.rh-acct-tx__copy{
	-webkit-appearance:none;appearance:none;
	background:transparent;
	border:1px solid var(--wp--preset--color--border,#e2e4e9);
	border-radius:var(--wp--custom--radius--sm,0.25rem);
	width:1.75rem;
	height:1.75rem;
	padding:0;
	display:inline-flex;
	align-items:center;
	justify-content:center;
	color:var(--wp--preset--color--text-muted,#5b6271);
	cursor:pointer;
	transition:background-color .15s, color .15s, border-color .15s;
}
.rh-acct-tx__copy:hover{
	background:var(--wp--preset--color--surface,#f7f7f8);
	color:var(--wp--preset--color--primary,#0a66c2);
	border-color:var(--wp--preset--color--primary,#0a66c2);
}
.rh-acct-tx__copy:focus-visible{
	outline:2px solid var(--wp--preset--color--primary,#0a66c2);
	outline-offset:2px;
}
.rh-acct-tx__copy svg{width:14px;height:14px;}
.rh-acct-tx__copy-icon{display:inline-flex;}
.rh-acct-tx__copy-icon--done{display:none;color:var(--wp--preset--color--success,#198754);}
.rh-acct-tx__copy.is-copied{
	background:var(--wp--preset--color--success,#198754);
	border-color:var(--wp--preset--color--success,#198754);
	color:var(--wp--preset--color--base,#fff);
}
.rh-acct-tx__copy.is-copied .rh-acct-tx__copy-icon--copy{display:none;}
.rh-acct-tx__copy.is-copied .rh-acct-tx__copy-icon--done{display:inline-flex;color:var(--wp--preset--color--base,#fff);}

/* Refund summary line — visually offset to draw attention */
.rh-acct-tx__row--refund{
	margin-block-start:0.25rem;
	padding-block-start:0.5rem;
	border-block-start:1px dashed var(--wp--preset--color--border,#e2e4e9);
}
.rh-acct-tx__row--refund .rh-acct-tx__row-label{color:var(--wp--preset--color--warning,#d97706);font-weight:var(--wp--custom--fw--strong);}
.rh-acct-tx__refund-amount{color:var(--wp--preset--color--warning,#d97706);}
.rh-acct-tx__refund-amount .woocommerce-Price-amount{color:inherit;}

/* Footer: view-order link */
.rh-acct-tx__card-foot{
	display:flex;
	justify-content:flex-end;
	padding-block-start:0.625rem;
	border-block-start:1px solid var(--wp--preset--color--border,#e2e4e9);
}
.rh-acct-tx__view-link{
	display:inline-flex;
	align-items:center;
	gap:0.25rem;
	color:var(--wp--preset--color--primary,#0a66c2);
	font-size:var(--wp--preset--font-size--sm,0.875rem);
	font-weight:var(--wp--custom--fw--strong);
	text-decoration:none;
}
.rh-acct-tx__view-link:hover{text-decoration:underline;}
.rh-acct-tx__view-chev{
	display:inline-flex;
	width:1rem;
	height:1rem;
}
.rh-acct-tx__view-chev svg{width:100%;height:100%;}

/* Empty state — mirrors the orders empty layout for visual consistency */
.rh-acct-tx__empty{
	background:var(--wp--preset--color--base,#fff);
	border:1px solid var(--wp--preset--color--border,#e2e4e9);
	border-radius:var(--wp--custom--radius--xl,1rem);
	padding:3rem 1.5rem;
	text-align:center;
}
.rh-acct-tx__empty-icon{
	width:64px;height:64px;
	margin:0 auto 1rem;
	display:inline-flex;
	align-items:center;
	justify-content:center;
	border-radius:50%;
	background:var(--wp--preset--color--surface,#f7f7f8);
	color:var(--wp--preset--color--primary,#0a66c2);
}
.rh-acct-tx__empty-icon svg{width:32px;height:32px;}
.rh-acct-tx__empty-text{
	margin:0 0 1rem;
	font-size:var(--wp--preset--font-size--md,1rem);
	color:var(--wp--preset--color--text,#1a1d23);
}
.rh-acct-tx__empty-cta{
	display:inline-flex;
	align-items:center;
	padding:0.6rem 1.25rem;
	background:var(--wp--preset--color--primary,#0a66c2);
	color:var(--wp--custom--on-primary, #fff);
	border-radius:var(--wp--custom--radius--md);
	font-weight:var(--wp--custom--fw--strong);
	text-decoration:none;
}
.rh-acct-tx__empty-cta:hover{
	background:var(--wp--preset--color--primary-dark,#074a8d);
	color:var(--wp--custom--on-primary, #fff);
	text-decoration:none;
}

/* Pagination — same shape as orders pagination */
.rh-acct-tx__pagination{margin-block-start:1.25rem;}
.rh-acct-tx__pagination .page-numbers{
	list-style:none;
	margin:0;
	padding:0;
	display:flex;
	align-items:center;
	justify-content:center;
	gap:0.25rem;
}
.rh-acct-tx__pagination .page-numbers li > *{
	display:inline-flex;
	align-items:center;
	justify-content:center;
	min-width:2.25rem;
	height:2.25rem;
	padding-inline:0.5rem;
	border:1px solid var(--wp--preset--color--border,#e2e4e9);
	border-radius:var(--wp--custom--radius--md);
	background:var(--wp--preset--color--base,#fff);
	color:var(--wp--preset--color--text,#1a1d23);
	font-size:var(--wp--preset--font-size--sm,0.875rem);
	text-decoration:none;
}
.rh-acct-tx__pagination .page-numbers .current{
	background:var(--wp--preset--color--primary,#0a66c2);
	border-color:var(--wp--preset--color--primary,#0a66c2);
	color:var(--wp--custom--on-primary, #fff);
}

/* Mobile tweaks */
@media (max-width:600px){
	.rh-acct-tx__title{font-size:var(--wp--preset--font-size--md,1.125rem);}
	.rh-acct-tx__card{padding:0.875rem 1rem;gap:0.75rem;}
	.rh-acct-tx__card-head{flex-wrap:wrap;}
	.rh-acct-tx__amount{font-size:var(--wp--preset--font-size--md,1.125rem);}
	.rh-acct-tx__ref-num{font-size:0.8125rem;padding:0.15rem 0.375rem;}
}
