/*
 * Oldooz Auth — فرانت‌اند (RTL)
 */

.oa-wrap {
	--oa-primary: #7c2d12;
	--oa-accent: #b45309;
	--oa-border: #eadfce;
	--oa-text: #3f2d20;
	--oa-muted: #78716c;
	direction: rtl;
	font-family: Vazirmatn, Tahoma, Arial, sans-serif;
	color: var(--oa-text);
}

.oa-wrap *,
.oa-wrap *::before,
.oa-wrap *::after {
	box-sizing: border-box;
}

.oa-card {
	max-width: 430px;
	margin: 24px auto;
	background: #fff;
	border: 1px solid var(--oa-border);
	border-radius: 16px;
	padding: 26px;
	box-shadow: 0 8px 30px rgba(124, 45, 18, 0.08);
}

.oa-card--wide {
	max-width: 680px;
}

.oa-card__logo {
	text-align: center;
	font-size: 22px;
	font-weight: 800;
	color: var(--oa-primary);
	margin-bottom: 6px;
}

.oa-card__title {
	text-align: center;
	font-size: 16px;
	color: #57534e;
	margin: 0 0 18px;
	font-weight: 600;
}

.oa-card__h2 {
	font-size: 16px;
	color: var(--oa-primary);
	margin: 0 0 12px;
}

.oa-card__h3 {
	font-size: 14px;
	color: #57534e;
	margin: 20px 0 10px;
}

.oa-field {
	margin-bottom: 14px;
}

.oa-field label {
	display: block;
	font-size: 13px;
	color: #57534e;
	margin-bottom: 6px;
}

.oa-field input {
	width: 100%;
	border: 1px solid #d6d3d1;
	border-radius: 10px;
	padding: 10px 12px;
	font-size: 14px;
	background: #fafaf9;
	font-family: inherit;
	color: #1c1917;
}

.oa-field input:focus {
	outline: 2px solid var(--oa-accent);
	outline-offset: 1px;
	background: #fff;
}

.oa-pass {
	position: relative;
}

.oa-pass input {
	padding-left: 40px;
}

.oa-pass__btn {
	position: absolute;
	left: 8px;
	top: 50%;
	transform: translateY(-50%);
	background: none;
	border: 0;
	cursor: pointer;
	font-size: 16px;
	opacity: 0.6;
	padding: 4px;
}

.oa-btn {
	width: 100%;
	background: linear-gradient(135deg, var(--oa-accent), var(--oa-primary));
	color: #fff;
	border: 0;
	border-radius: 10px;
	padding: 11px 18px;
	font-size: 15px;
	font-weight: 700;
	cursor: pointer;
	font-family: inherit;
}

.oa-btn:hover {
	filter: brightness(1.08);
}

.oa-btn--secondary {
	display: inline-block;
	text-align: center;
	background: #0f766e;
	width: auto;
}

.oa-btn--ghost {
	background: #fff;
	color: var(--oa-primary);
	border: 1px solid #d6d3d1;
	width: auto;
}

.oa-check {
	display: flex;
	gap: 6px;
	align-items: center;
	font-size: 13px;
	color: #57534e;
	margin-bottom: 14px;
}

.oa-check input {
	width: auto;
}

.oa-notice {
	border-radius: 10px;
	padding: 10px 12px;
	font-size: 13px;
	margin-bottom: 14px;
	line-height: 2;
}

.oa-notice--ok {
	background: #ecfdf5;
	color: #065f46;
	border: 1px solid #a7f3d0;
}

.oa-notice--err {
	background: #fef2f2;
	color: #991b1b;
	border: 1px solid #fecaca;
}

.oa-notice--warn {
	background: #fffbeb;
	color: #92400e;
	border: 1px solid #fde68a;
}

.oa-hp {
	position: absolute !important;
	right: -9999px !important;
	opacity: 0;
	height: 0;
	overflow: hidden;
}

.oa-card__links {
	display: flex;
	justify-content: space-between;
	gap: 8px;
	flex-wrap: wrap;
	font-size: 13px;
	margin-top: 16px;
}

.oa-card__links a {
	color: var(--oa-accent);
	text-decoration: none;
}

.oa-inline-form {
	display: flex;
	gap: 8px;
	margin-top: 10px;
	flex-wrap: wrap;
	align-items: center;
}

.oa-inline-form input[type="email"],
.oa-inline-form input[type="text"] {
	border: 1px solid #d6d3d1;
	border-radius: 8px;
	padding: 7px 10px;
	font-size: 13px;
	font-family: inherit;
}

.oa-badge {
	display: inline-block;
	border-radius: 999px;
	padding: 3px 10px;
	font-size: 12px;
	font-weight: 700;
	line-height: 1.7;
}

.oa-badge--active { background: #ecfdf5; color: #059669; }
.oa-badge--unused { background: #eff6ff; color: #1d4ed8; }
.oa-badge--suspended { background: #fffbeb; color: #b45309; }
.oa-badge--expired { background: #fef2f2; color: #dc2626; }
.oa-badge--revoked { background: #f3f4f6; color: #6b7280; }

.oa-license-row {
	border: 1px solid #f0e7db;
	border-radius: 12px;
	padding: 14px;
	margin-bottom: 12px;
	background: #fffdf9;
}

.oa-license-row__head {
	display: flex;
	justify-content: space-between;
	align-items: center;
	gap: 8px;
	flex-wrap: wrap;
	margin-bottom: 10px;
}

.oa-key {
	direction: ltr;
	display: inline-block;
	font-family: Consolas, Monaco, monospace;
	letter-spacing: 1px;
	font-size: 14px;
	background: #f5f5f4;
	border: 1px solid #e7e5e4;
	border-radius: 8px;
	padding: 4px 8px;
	color: #1c1917;
	word-break: break-all;
}

.oa-progress {
	height: 8px;
	background: #f5f5f4;
	border-radius: 999px;
	overflow: hidden;
	margin-top: 8px;
}

.oa-progress span {
	display: block;
	height: 100%;
	background: linear-gradient(90deg, #22c55e, #16a34a);
}

.oa-days {
	font-size: 12px;
	color: var(--oa-muted);
	margin-top: 6px;
}

.oa-grid {
	display: grid;
	grid-template-columns: 1fr 1fr;
	gap: 8px 14px;
	font-size: 13px;
	color: #57534e;
}

.oa-avatar {
	width: 46px;
	height: 46px;
	border-radius: 50%;
	background: linear-gradient(135deg, var(--oa-accent), var(--oa-primary));
	color: #fff;
	display: flex;
	align-items: center;
	justify-content: center;
	font-size: 20px;
	font-weight: 800;
	flex-shrink: 0;
}

.oa-head {
	display: flex;
	gap: 12px;
	align-items: center;
	margin-bottom: 12px;
}

.oa-name {
	font-weight: 800;
	font-size: 16px;
	color: #1c1917;
}

.oa-email {
	font-size: 13px;
	color: var(--oa-muted);
	direction: ltr;
	text-align: right;
}

.oa-details {
	max-width: 680px;
	margin: 12px auto;
	background: #fff;
	border: 1px solid var(--oa-border);
	border-radius: 16px;
	padding: 16px 20px;
}

.oa-details summary {
	cursor: pointer;
	font-weight: 700;
	color: var(--oa-primary);
}

.oa-empty {
	color: var(--oa-muted);
	font-size: 14px;
	line-height: 2;
}

.oa-actions {
	display: flex;
	gap: 10px;
	justify-content: space-between;
	align-items: center;
	flex-wrap: wrap;
}

.oa-form--inline {
	display: flex;
	gap: 8px;
	flex-wrap: wrap;
	align-items: flex-end;
}

.oa-form--inline .oa-field {
	flex: 1;
	min-width: 230px;
	margin-bottom: 0;
}

.oa-input-key {
	letter-spacing: 1px;
}

@media (max-width: 480px) {
	.oa-grid {
		grid-template-columns: 1fr;
	}

	.oa-card {
		padding: 18px;
	}
}

/* ==================== فاز ۶: کارت دورهٔ تست رایگان ==================== */

.oa-trial-card {
	background: linear-gradient(135deg, #f5f3ff 0%, #fdf4ff 60%, #fff7ed 100%);
	border: 1px solid #ddd6fe;
}

.oa-trial-card__head {
	display: flex;
	align-items: center;
	gap: 14px;
	flex-wrap: wrap;
}

.oa-trial-card__ico {
	width: 52px;
	height: 52px;
	border-radius: 14px;
	background: #7c3aed;
	color: #fff;
	font-size: 26px;
	display: flex;
	align-items: center;
	justify-content: center;
	flex: 0 0 auto;
	box-shadow: 0 6px 14px rgba(124, 58, 237, 0.35);
}

.oa-trial-card__txt {
	flex: 1;
	min-width: 200px;
	display: flex;
	flex-direction: column;
	gap: 2px;
}

.oa-trial-card__txt b {
	color: #4c1d95;
	font-size: 15.5px;
}

.oa-trial-card__txt span {
	color: #6d28d9;
	font-size: 13px;
}

.oa-trial-card__bar {
	height: 10px;
	background: #e9e5f8;
	border-radius: 99px;
	overflow: hidden;
	margin: 14px 0 10px;
}

.oa-trial-card__bar span {
	display: block;
	height: 100%;
	border-radius: 99px;
	background: linear-gradient(90deg, #8b5cf6, #d946ef);
}

.oa-trial-card__hint {
	margin: 0;
	color: #6b7280;
	font-size: 12.5px;
	line-height: 1.9;
}

@media (max-width: 600px) {
	.oa-trial-card__head .oa-btn {
		width: 100%;
		text-align: center;
	}
}

/* ─── v1.3: راهنمای زندهٔ نام کاربری ─── */
.oa-user-hint {
	display: block;
	min-height: 18px;
	margin-top: 4px;
	font-size: 11.5px;
	color: #6b7280;
}
.oa-user-hint.is-ok { color: #0f9d58; font-weight: 600; }
.oa-user-hint.is-err { color: #d92d20; font-weight: 600; }
.oa-field__help {
	margin: 4px 0 0;
	font-size: 11.5px;
	color: #6b7280;
	line-height: 1.8;
}
