/*
 * Compte Optencis (includes/account.php) : icône de l'en-tête et page
 * « Mon compte ». Palette du site ; propriétés logiques pour l'arabe.
 */

/* ─── Icône de l'en-tête ─────────────────────────────────────────────── */
.opx-acc-chip {
	display: inline-flex;
	align-items: center;
	gap: 0.4rem;
	padding: 0.3rem 0.75rem 0.3rem 0.35rem;
	padding-inline: 0.35rem 0.75rem;
	border: 1px solid var(--wp--preset--color--platinum, #e4e4e6);
	border-radius: 999px;
	font-size: 0.875rem;
	font-weight: 600;
	line-height: 1;
	white-space: nowrap;
	color: var(--wp--preset--color--ink, #01182a);
	text-decoration: none;
}

.opx-acc-chip svg {
	flex: none;
	padding: 3px;
	box-sizing: content-box;
	border-radius: 50%;
	background: rgba(13, 54, 208, 0.08);
	color: var(--wp--preset--color--blue, #0d36d0);
}

.opx-acc-chip:hover,
.opx-acc-chip:focus-visible {
	border-color: var(--wp--preset--color--blue, #0d36d0);
	color: var(--wp--preset--color--blue, #0d36d0);
}

.opx-acc-chip:focus-visible {
	outline: 2px solid var(--wp--preset--color--blue, #0d36d0);
	outline-offset: 2px;
}

.opx-acc-chip.is-in {
	background: rgba(13, 54, 208, 0.05);
	font-variant-numeric: tabular-nums;
}

/* ─── Avatar (symbole Optencis, en attendant les rangs) ───────────────── */
.opx-acc-avatar {
	display: inline-grid;
	place-items: center;
	flex: none;
	width: 26px;
	height: 26px;
	border-radius: 50%;
	background: #fff;
	box-shadow: inset 0 0 0 1.5px var(--wp--preset--color--blue, #0d36d0);
}

.opx-acc-avatar img {
	width: 15px;
	height: auto;
	display: block;
}

.opx-acc-avatar.is-l {
	width: 64px;
	height: 64px;
	box-shadow: inset 0 0 0 2.5px var(--wp--preset--color--blue, #0d36d0), 0 6px 18px rgba(13, 54, 208, 0.15);
}

.opx-acc-avatar.is-l img {
	width: 34px;
}

@media (max-width: 600px) {
	.opx-acc-chip {
		gap: 0.3rem;
		padding-inline: 0.25rem 0.5rem;
		font-size: 0.75rem;
	}

	/* L'en-tête est étroit : le numéro reste, « ID » s'efface, les blocs se serrent. */
	.opx-acc-chip__pre {
		display: none;
	}

	.wp-block-group:has(> .opx-acc-chip) {
		gap: 0.5rem !important;
	}

	.opx-acc-avatar {
		width: 22px;
		height: 22px;
	}

	.opx-acc-avatar img {
		width: 13px;
	}
}

/* ─── Page « Mon compte » ─────────────────────────────────────────────── */
.opx-acc {
	box-sizing: border-box;
	max-width: 520px;
	margin: 0 auto;
	padding: 3rem 16px 4rem;
	color: var(--wp--preset--color--ink, #01182a);
}

.opx-acc *,
.opx-acc *::before,
.opx-acc *::after {
	box-sizing: inherit;
}

.opx-acc__card {
	padding: 2rem 1.75rem;
	border: 1px solid var(--wp--preset--color--platinum, #e4e4e6);
	border-radius: 18px;
	background: #fff;
	box-shadow: 0 10px 30px rgba(1, 24, 42, 0.06);
}

.opx-acc .opx-eyebrow {
	margin: 0;
	color: var(--wp--preset--color--blue, #0d36d0);
}

.opx-acc h1 {
	margin: 0.25rem 0 0.75rem;
	font-size: clamp(1.6rem, 4vw, 2rem);
	letter-spacing: -0.01em;
}

.opx-acc__lead {
	margin: 0 0 1.25rem;
	color: var(--wp--preset--color--ink-muted, #4f5b66);
}

.opx-acc__msg {
	margin: 0 0 1rem;
	padding: 0.75rem 1rem;
	border-radius: 10px;
	background: rgba(13, 54, 208, 0.06);
	font-size: 0.9375rem;
}

.opx-acc__msg.is-error {
	background: rgba(240, 68, 82, 0.08);
	color: #b3202d;
}

.opx-acc__form {
	display: grid;
	gap: 0.6rem;
}

.opx-acc__form label {
	font-weight: 600;
	font-size: 0.9375rem;
}

.opx-acc__form input {
	width: 100%;
	padding: 0.85rem 1rem;
	border: 1.5px solid var(--wp--preset--color--platinum, #e4e4e6);
	border-radius: 12px;
	font: inherit;
	font-size: 1.125rem;
	letter-spacing: 0.04em;
	font-variant-numeric: tabular-nums;
}

.opx-acc__form input:focus {
	outline: none;
	border-color: var(--wp--preset--color--blue, #0d36d0);
	box-shadow: 0 0 0 3px rgba(13, 54, 208, 0.15);
}

.opx-acc__go {
	display: inline-flex;
	justify-content: center;
	align-items: center;
	padding: 0.95rem 1.5rem;
	border: 0;
	border-radius: 12px;
	background: var(--wp--preset--color--blue, #0d36d0);
	color: #fff;
	font: inherit;
	font-weight: 700;
	font-size: 1.0625rem;
	text-decoration: none;
	cursor: pointer;
	box-shadow: 0 8px 20px rgba(13, 54, 208, 0.25);
}

.opx-acc__go:hover,
.opx-acc__go:focus-visible {
	background: #082a6e;
	color: #fff;
}

.opx-acc__go.is-alt {
	background: #16c784;
	box-shadow: 0 8px 20px rgba(22, 199, 132, 0.25);
}

.opx-acc__go.is-alt:hover,
.opx-acc__go.is-alt:focus-visible {
	background: #10a46c;
}

.opx-acc__signup {
	display: grid;
	gap: 0.6rem;
	margin-top: 1.5rem;
	padding-top: 1.25rem;
	border-top: 1px solid var(--wp--preset--color--platinum, #e4e4e6);
}

.opx-acc__signup p {
	margin: 0;
	font-weight: 600;
}

.opx-acc__note {
	margin: 1.25rem 0 0;
	font-size: 0.8125rem;
	color: var(--wp--preset--color--ink-muted, #4f5b66);
}

.opx-acc__who {
	display: flex;
	align-items: center;
	gap: 1rem;
}

.opx-acc__who h1 {
	margin: 0.1rem 0 0.2rem;
	font-variant-numeric: tabular-nums;
}

.opx-acc__lvl {
	margin: 0;
	font-size: 0.875rem;
	color: var(--wp--preset--color--ink-muted, #4f5b66);
}

.opx-acc__status {
	margin: 1.5rem 0 1rem;
	padding: 0.85rem 1rem;
	border-radius: 12px;
	background: rgba(13, 54, 208, 0.06);
	border-inline-start: 4px solid var(--wp--preset--color--blue, #0d36d0);
}

.opx-acc__status.is-funded {
	background: rgba(22, 199, 132, 0.08);
	border-inline-start-color: #16c784;
}

.opx-acc__status.is-low {
	background: rgba(255, 184, 0, 0.1);
	border-inline-start-color: #ffb800;
}

.opx-acc__links {
	display: grid;
	gap: 0.5rem;
}

.opx-acc__link {
	display: block;
	padding: 0.8rem 1rem;
	border: 1px solid var(--wp--preset--color--platinum, #e4e4e6);
	border-radius: 12px;
	background: #fff;
	color: var(--wp--preset--color--ink, #01182a);
	font: inherit;
	font-weight: 600;
	text-align: start;
	text-decoration: none;
	cursor: pointer;
	width: 100%;
}

.opx-acc__link:hover,
.opx-acc__link:focus-visible {
	border-color: var(--wp--preset--color--blue, #0d36d0);
	color: var(--wp--preset--color--blue, #0d36d0);
}

.opx-acc__out {
	margin-top: 1.25rem;
}

.opx-acc__link.is-out {
	color: var(--wp--preset--color--ink-muted, #4f5b66);
	text-align: center;
}

/* Barre « connecté » des pages membres (wire-pocket.php) : avatar puis texte, déconnexion au bout */
.opx-po__bar > .opx-acc-avatar + span {
	flex: 1 1 auto;
	margin-inline-start: -0.5rem;
}

/* Bot Telegram des signaux (optencis_account_telegram_box, wire-telegram.php). */
.opx-acc .opx-tg--account {
	display: flex;
	flex-wrap: wrap;
	justify-content: space-between;
	align-items: center;
	gap: 0.75rem;
	margin-top: 0.75rem;
	padding: 0.9rem 1rem;
	border: 1px solid rgba(13, 54, 208, 0.25);
	border-radius: 12px;
	background: rgba(13, 54, 208, 0.05);
}

.opx-acc .opx-tg--account > div {
	flex: 1 1 14rem;
	min-width: 0;
}

.opx-acc .opx-tg--account p {
	margin: 0.15rem 0 0;
	font-size: 0.85rem;
	color: var(--wp--preset--color--ink-muted, #4f5b66);
}

.opx-acc .opx-tg__btn {
	display: inline-block;
	padding: 0.6rem 1.1rem;
	border-radius: 999px;
	background: var(--wp--preset--color--blue, #0d36d0);
	color: #fff;
	font-weight: 700;
	text-decoration: none;
	white-space: nowrap;
}

.opx-acc .opx-tg__btn:hover,
.opx-acc .opx-tg__btn:focus-visible {
	background: var(--wp--preset--color--ink, #01182a);
}

/* ─── Encadré « Leave a review, get a gift » (refait le 29/10/2026) ────── */
.opx-acc .opx-rv {
	margin-top: 0.75rem;
	padding: 1.25rem 1.25rem 1.35rem;
	border: 1px solid rgba(13, 54, 208, 0.25);
	border-radius: 16px;
	background: linear-gradient(160deg, rgba(13, 54, 208, 0.07), rgba(22, 199, 132, 0.06));
}

.opx-acc .opx-rv__head {
	display: flex;
	align-items: flex-start;
	gap: 0.85rem;
}

.opx-acc .opx-rv__head > div {
	min-width: 0;
}

.opx-acc .opx-rv__head b {
	font-size: 1.125rem;
	letter-spacing: -0.01em;
}

.opx-acc .opx-rv__head p {
	margin: 0.2rem 0 0;
	font-size: 0.875rem;
	color: var(--wp--preset--color--ink-muted, #4f5b66);
}

.opx-acc .opx-rv__money {
	display: flex;
	flex-wrap: wrap;
	align-items: baseline;
	gap: 0.4rem 0.75rem;
	margin: 1rem 0 0;
	padding: 0.65rem 0.9rem;
	border-radius: 12px;
	background: #fff;
	font-weight: 700;
	font-variant-numeric: tabular-nums;
}

.opx-acc .opx-rv__money-k {
	font-size: 0.75rem;
	font-weight: 600;
	letter-spacing: 0.06em;
	text-transform: uppercase;
	color: var(--wp--preset--color--blue, #0d36d0);
}

.opx-acc .opx-rv__form {
	display: grid;
	gap: 0.75rem;
	margin-top: 1rem;
}

.opx-acc .opx-rv__stars {
	margin: 0;
	padding: 0;
	border: 0;
}

.opx-acc .opx-rv__stars legend,
.opx-acc .opx-rv__label {
	display: block;
	margin: 0 0 0.3rem;
	font-weight: 600;
	font-size: 0.9375rem;
}

/* Les étoiles de 5 à 1 dans le flux, affichées de 1 à 5 : le survol remplit depuis la gauche. */
.opx-acc .opx-rv__stars-row {
	display: inline-flex;
	flex-direction: row-reverse;
	justify-content: flex-end;
	gap: 0.15rem;
}

.opx-acc .opx-rv__stars-row input {
	position: absolute;
	width: 1px;
	height: 1px;
	opacity: 0;
	pointer-events: none;
}

.opx-acc .opx-rv__stars-row label {
	cursor: pointer;
	font-size: 2rem;
	line-height: 1;
	color: #c9ced6;
	transition: color 0.1s, transform 0.1s;
}

.opx-acc .opx-rv__stars-row label:hover,
.opx-acc .opx-rv__stars-row label:hover ~ label,
.opx-acc .opx-rv__stars-row input:checked ~ label {
	color: #ffb800;
}

.opx-acc .opx-rv__stars-row label:hover {
	transform: scale(1.12);
}

.opx-acc .opx-rv__stars-row input:focus-visible + label {
	outline: 2px solid var(--wp--preset--color--blue, #0d36d0);
	outline-offset: 2px;
	border-radius: 6px;
}

.opx-acc .opx-rv__form textarea {
	width: 100%;
	padding: 0.8rem 0.95rem;
	border: 1.5px solid var(--wp--preset--color--platinum, #e4e4e6);
	border-radius: 12px;
	background: #fff;
	font: inherit;
	font-size: 1rem;
	resize: vertical;
}

.opx-acc .opx-rv__form textarea:focus {
	outline: none;
	border-color: var(--wp--preset--color--blue, #0d36d0);
	box-shadow: 0 0 0 3px rgba(13, 54, 208, 0.15);
}

.opx-acc .opx-rv__img {
	padding: 0.85rem 0.95rem;
	border: 1.5px dashed rgba(13, 54, 208, 0.35);
	border-radius: 12px;
	background: #fff;
}

.opx-acc .opx-rv__hint {
	margin: 0 0 0.6rem;
	font-size: 0.8125rem;
	color: var(--wp--preset--color--ink-muted, #4f5b66);
}

.opx-acc .opx-rv__hint a {
	color: var(--wp--preset--color--blue, #0d36d0);
	font-weight: 600;
}

.opx-acc .opx-rv__hint.is-safe {
	margin: 0.6rem 0 0;
	font-size: 0.75rem;
}

.opx-acc .opx-rv__img input[type="file"] {
	width: 100%;
	font: inherit;
	font-size: 0.875rem;
}

.opx-acc .opx-rv__img input[type="file"]::file-selector-button {
	margin-inline-end: 0.75rem;
	padding: 0.5rem 0.9rem;
	border: 0;
	border-radius: 999px;
	background: var(--wp--preset--color--blue, #0d36d0);
	color: #fff;
	font: inherit;
	font-weight: 700;
	font-size: 0.8125rem;
	cursor: pointer;
}

.opx-acc .opx-rv__consent {
	display: flex;
	align-items: flex-start;
	gap: 0.55rem;
	font-size: 0.9375rem;
}

.opx-acc .opx-rv__consent input {
	flex: none;
	width: 1.15rem;
	height: 1.15rem;
	margin: 0.1rem 0 0;
	accent-color: var(--wp--preset--color--blue, #0d36d0);
}

.opx-acc .opx-rv__ok {
	margin: 0.9rem 0 0;
	padding: 0.75rem 0.95rem;
	border-radius: 12px;
	background: rgba(22, 199, 132, 0.12);
	font-weight: 600;
}

/* ─── Barre résumée en haut des pages (lead connecté, 29/10/2026) ─────── */
.opx-topbar {
	background: var(--wp--preset--color--ink, #01182a);
	color: #fff;
	font-size: 0.8125rem;
}

.opx-topbar__in {
	display: flex;
	align-items: center;
	gap: 1rem;
	max-width: 1200px;
	margin: 0 auto;
	padding: 0.35rem 16px;
}

.opx-topbar__me {
	display: inline-flex;
	align-items: center;
	gap: 0.45rem;
	flex: none;
	color: #fff;
	font-weight: 700;
	font-variant-numeric: tabular-nums;
	text-decoration: none;
}

.opx-topbar .opx-acc-avatar {
	width: 22px;
	height: 22px;
	box-shadow: inset 0 0 0 1.5px var(--wp--preset--color--blue, #0d36d0);
}

.opx-topbar .opx-acc-avatar img {
	width: 13px;
}

.opx-topbar__money {
	flex: 1 1 auto;
	min-width: 0;
	overflow: hidden;
	text-overflow: ellipsis;
	white-space: nowrap;
	color: #9fc1ff;
	font-weight: 600;
	font-variant-numeric: tabular-nums;
}

.opx-topbar__nav {
	display: flex;
	gap: 0.25rem;
	margin-inline-start: auto;
	overflow-x: auto;
	scrollbar-width: none;
}

.opx-topbar__nav a {
	padding: 0.3rem 0.65rem;
	border-radius: 999px;
	color: #fff;
	font-weight: 600;
	text-decoration: none;
	white-space: nowrap;
}

.opx-topbar__nav a:hover,
.opx-topbar__nav a:focus-visible {
	background: rgba(255, 255, 255, 0.12);
}

.opx-topbar__nav a.is-acc {
	background: var(--wp--preset--color--blue, #0d36d0);
}

@media (max-width: 700px) {
	.opx-topbar__in {
		flex-wrap: wrap;
		gap: 0.4rem 0.75rem;
		padding: 0.4rem 16px;
	}

	.opx-topbar__money {
		flex-basis: 100%;
		order: 3;
		white-space: normal;
	}

	.opx-topbar__nav {
		margin-inline-start: 0;
		order: 2;
	}
}

