/* Eqra Hifz Assistant — high contrast + tools switcher */
.eha-tools-nav {
	display: flex;
	flex-wrap: wrap;
	gap: 8px;
	margin: 0 0 16px;
	padding: 10px;
	background: #eef7f2;
	border: 1px solid #c5ddd2;
	border-radius: 12px;
	font-family: "IBM Plex Sans Arabic", Tahoma, sans-serif;
}

.eha-tools-link {
	flex: 1 1 140px;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	min-height: 44px;
	padding: 8px 14px;
	border-radius: 10px;
	border: 2px solid #0d4632;
	background: #ffffff;
	color: #0d4632 !important;
	font-weight: 800;
	font-size: 0.95rem;
	text-decoration: none !important;
	transition: background 0.15s ease, color 0.15s ease, transform 0.15s ease;
}

.eha-tools-link:hover {
	background: #e7f4ee;
	color: #0a3828 !important;
	transform: translateY(-1px);
}

.eha-tools-link.is-active {
	background: #0d4632;
	color: #ffffff !important;
	border-color: #0d4632;
}

.eha-host-wrap {
	max-width: 920px;
	margin: 0 auto;
	padding: 0 0 8px;
}

.eha.eha--forced,
.eha.eha--forced .eha-panel {
	color: #0c2f24 !important;
}

.eha {
	--eha-ink: #0c2f24;
	--eha-green: #0d4632;
	--eha-teal: #0a5c4b;
	--eha-mint: #d7efe5;
	--eha-sand: #f4eee6;
	--eha-cream: #fffdf9;
	--eha-line: #c5ddd2;
	--eha-warn: #7a3f0d;
	--eha-radius: 14px;
	--eha-font: "IBM Plex Sans Arabic", "Segoe UI", Tahoma, sans-serif;
	--eha-display: "Amiri", "Traditional Arabic", serif;
	max-width: 720px;
	margin: 0 auto 18px;
	padding: 16px 16px 28px;
	color: #0c2f24 !important;
	font-family: var(--eha-font);
	background: #fffdf9 !important;
	border: 1px solid #c5ddd2;
	border-radius: 16px;
	box-shadow: 0 10px 28px rgba(13, 70, 50, 0.08);
}

.eha.eha--nav {
	max-width: 920px;
	padding: 10px;
	margin: 8px auto 12px;
	box-shadow: none;
}
.eha.eha--nav .eha-tools-nav {
	margin: 0;
}

.eha-embed-toggle {
	width: 100%;
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	justify-content: space-between;
	gap: 8px;
	min-height: 48px;
	padding: 10px 14px;
	border: 2px solid #0d4632;
	border-radius: 12px;
	background: #0d4632;
	color: #ffffff !important;
	font: inherit;
	font-weight: 800;
	cursor: pointer;
	text-align: right;
}

.eha-embed-toggle-title {
	color: #ffffff !important;
	font-size: 1.05rem;
}

.eha-embed-toggle-hint {
	color: #e8fff6 !important;
	font-size: 0.88rem;
	font-weight: 600;
}

.eha-embed-body {
	margin-top: 12px;
}

.eha-hero {
	margin-bottom: 18px;
	padding: 16px 16px 18px;
	border-radius: 12px;
	background: #0d4632 !important;
	border: 1px solid #0d4632;
	color: #ffffff !important;
}

.eha-hero *,
.eha-kicker,
.eha-title,
.eha-lead {
	color: #ffffff !important;
	opacity: 1 !important;
}

.eha-kicker {
	margin: 0 0 6px;
	font-size: 0.95rem;
	font-weight: 800;
	letter-spacing: 0.04em;
}

.eha-title {
	margin: 0 0 10px;
	font-family: var(--eha-display);
	font-size: clamp(1.45rem, 3.4vw, 2.1rem);
	font-weight: 700;
	line-height: 1.3;
}

.eha-lead {
	margin: 0;
	font-size: 1.02rem;
	line-height: 1.8;
	font-weight: 600;
	max-width: 40em;
}

.eha-panel {
	background: #ffffff !important;
	border: 1px solid #c5ddd2;
	border-radius: var(--eha-radius);
	padding: 18px 16px;
}

.eha-h2,
.eha-h3 {
	margin: 0 0 12px;
	color: #0d4632 !important;
}

.eha-h2 { font-size: 1.2rem; }
.eha-h3 { margin-top: 22px; font-size: 1.05rem; }

.eha-form { display: grid; gap: 14px; }

.eha-fieldset {
	border: 1px solid #c5ddd2;
	border-radius: 10px;
	padding: 12px 14px;
	margin: 0;
	display: flex;
	flex-wrap: wrap;
	gap: 10px 18px;
	background: #fff;
}

.eha-fieldset legend {
	padding: 0 6px;
	font-size: 0.92rem;
	font-weight: 800;
	color: #0a5c4b !important;
}

.eha-choice {
	display: inline-flex;
	align-items: center;
	gap: 8px;
	cursor: pointer;
	font-weight: 700;
	color: #0c2f24 !important;
}

.eha-row { display: grid; gap: 6px; }
.eha-row label {
	font-weight: 800;
	font-size: 0.92rem;
	color: #0c2f24 !important;
}

.eha select,
.eha input[type="number"],
.eha input[type="text"] {
	font: inherit;
	padding: 10px 12px;
	border-radius: 10px;
	border: 1px solid #9fbfb2;
	background: #fff !important;
	color: #0c2f24 !important;
	min-height: 44px;
}

.eha-btn {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	gap: 8px;
	min-height: 46px;
	padding: 0 18px;
	border-radius: 10px;
	border: 2px solid transparent;
	font: inherit;
	font-weight: 800;
	text-decoration: none !important;
	cursor: pointer;
	transition: transform 0.15s ease, background 0.15s ease;
}

.eha-btn:hover { transform: translateY(-1px); }

.eha-btn-primary {
	background: #0d4632 !important;
	border-color: #0d4632 !important;
	color: #ffffff !important;
}

.eha-btn-primary:hover {
	background: #0a5c4b !important;
	color: #ffffff !important;
}

.eha-btn-secondary {
	background: #ffffff !important;
	border-color: #0d4632 !important;
	color: #0d4632 !important;
}

.eha-btn-secondary:hover {
	background: #e7f4ee !important;
	color: #06281c !important;
}

.eha-btn-share {
	background: #0d4632 !important;
	border-color: #0d4632 !important;
	color: #ffffff !important;
}

.eha-btn-ghost {
	background: #ffffff !important;
	color: #0a5c4b !important;
	border-color: #9fbfb2 !important;
	min-height: 38px;
	font-size: 0.9rem;
}

.eha-dash-head {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 12px;
	margin-bottom: 12px;
}
.eha-dash-head .eha-h2 { margin: 0; }

.eha-today {
	background: #eef7f2 !important;
	border: 1px solid #c5ddd2;
	border-radius: 12px;
	padding: 16px;
	margin-bottom: 16px;
}

.eha-today-title {
	margin: 0 0 6px;
	font-family: var(--eha-display);
	font-size: 1.3rem;
	color: #0d4632 !important;
}

.eha-today-meta {
	margin: 0;
	font-size: 0.95rem;
	font-weight: 600;
	color: #1b3f34 !important;
}

.eha-today-note {
	margin: 10px 0 0;
	font-size: 0.92rem;
	color: #7a3f0d !important;
	font-weight: 700;
}

.eha-actions {
	display: flex;
	flex-wrap: wrap;
	gap: 10px;
	margin-bottom: 8px;
}

.eha-week {
	list-style: none;
	margin: 0;
	padding: 0;
	display: grid;
	gap: 8px;
}

.eha-week li {
	display: grid;
	grid-template-columns: 72px 1fr auto;
	gap: 10px;
	align-items: center;
	padding: 12px 14px;
	border-radius: 10px;
	border: 1px solid #c5ddd2;
	background: #fff !important;
	color: #0c2f24 !important;
}

.eha-week li.is-today {
	border-color: #0a5c4b;
	box-shadow: 0 0 0 2px rgba(10, 92, 75, 0.15);
}

.eha-week li.is-done { opacity: 0.6; }

.eha-day-label {
	font-weight: 800;
	color: #0a5c4b !important;
	font-size: 0.88rem;
}

.eha-day-task {
	font-size: 0.95rem;
	line-height: 1.45;
	color: #0c2f24 !important;
}

.eha-day-check {
	appearance: none;
	width: 22px;
	height: 22px;
	border: 2px solid #0a5c4b;
	border-radius: 6px;
	cursor: pointer;
	background: #fff;
}
.eha-day-check:checked {
	background: #0a5c4b;
	box-shadow: inset 0 0 0 3px #fff;
}

.eha-hint {
	margin: 0 0 12px;
	font-size: 0.92rem;
	font-weight: 600;
	color: #1b3f34 !important;
}

.eha-weak-add {
	display: grid;
	grid-template-columns: 1fr 90px auto;
	gap: 8px;
	margin-bottom: 12px;
}

.eha-weak-list {
	list-style: none;
	margin: 0;
	padding: 0;
	display: grid;
	gap: 8px;
}

.eha-weak-list li {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 10px;
	padding: 10px 12px;
	border-radius: 10px;
	background: #fff6eb !important;
	border: 1px solid #e2c19a;
}

.eha-weak-list a {
	color: #0d4632 !important;
	font-weight: 800;
	text-decoration: none;
}

.eha-weak-list button {
	border: 0;
	background: transparent;
	color: #7a3f0d !important;
	font: inherit;
	font-weight: 800;
	cursor: pointer;
}

.eha-empty {
	margin: 0;
	padding: 12px;
	font-size: 0.92rem;
	font-weight: 600;
	color: #1b3f34 !important;
}

.eha-progress-wrap { margin: 0 0 14px; }
.eha-progress-bar {
	height: 10px;
	border-radius: 999px;
	background: #dceee6;
	overflow: hidden;
}
.eha-progress-bar span {
	display: block;
	height: 100%;
	width: 0;
	background: #0d4632;
	border-radius: inherit;
	transition: width 0.3s ease;
}
.eha-progress-label {
	margin: 8px 0 0;
	font-weight: 800;
	color: #0d4632 !important;
}

.eha-rate {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 8px;
	margin: 0 0 14px;
}
.eha-rate-label {
	font-weight: 800;
	color: #0c2f24 !important;
}
.eha-rate-btn {
	min-height: 38px;
	padding: 0 12px;
	border-radius: 999px;
	border: 2px solid #0d4632;
	background: #fff;
	color: #0d4632;
	font: inherit;
	font-weight: 800;
	cursor: pointer;
}
.eha-rate-btn.is-on,
.eha-rate-btn[data-rate="hard"].is-on { background: #0d4632; color: #fff; }

.eha-share-overlay {
	position: fixed;
	inset: 0;
	z-index: 99999;
	background: rgba(8, 28, 22, 0.55);
	display: flex;
	align-items: flex-end;
	justify-content: center;
	padding: 16px;
}
.eha-share-overlay[hidden] { display: none !important; }
.eha-share-sheet {
	width: min(560px, 100%);
	max-height: 90vh;
	overflow: auto;
	background: #fffdf9;
	border-radius: 18px 18px 12px 12px;
	padding: 18px 16px 22px;
	color: #0c2f24;
}
.eha-share-head {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 12px;
}
.eha-share-head h2 { margin: 0; color: #0d4632; font-size: 1.2rem; }
.eha-share-close {
	width: 40px; height: 40px; border: 0; border-radius: 10px;
	background: #eef7f2; color: #0d4632; font-size: 1.6rem; cursor: pointer;
}
.eha-share-lead { margin: 8px 0 14px; font-weight: 650; color: #0c2f24 !important; }
.eha-share-grid {
	display: grid;
	grid-template-columns: repeat(2, minmax(0, 1fr));
	gap: 8px;
}
.eha-share-item {
	display: flex;
	align-items: center;
	gap: 10px;
	min-height: 52px;
	padding: 8px 10px;
	border-radius: 12px;
	border: 1px solid #c5ddd2;
	background: #fff;
	color: #0c2f24;
	font: inherit;
	font-weight: 800;
	cursor: pointer;
	text-align: right;
}
.eha-share-ico {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 36px;
	height: 36px;
	border-radius: 10px;
	flex: 0 0 36px;
}
.eha-share-ico svg { width: 20px; height: 20px; display: block; }
.eha-wa { background: #25d366; }
.eha-tg { background: #229ed9; }
.eha-x { background: #0f1419; }
.eha-fb { background: #1877f2; }
.eha-em { background: #ea4335; }
.eha-cp { background: #0a5c4b; }
.eha-tx { background: #365314; }
.eha-nt { background: #4338ca; }
.eha-pr { background: #334155; }

@media (min-width: 640px) {
	.eha-share-overlay { align-items: center; }
	.eha-share-sheet { border-radius: 16px; }
	.eha-share-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}

@media print {
	.eha-tools-nav, .eha-share-overlay, .eha-rate, .eha-actions, .eha-embed-toggle, .no-print { display: none !important; }
}

@media (max-width: 560px) {
	.eha-week li { grid-template-columns: 56px 1fr auto; }
	.eha-weak-add { grid-template-columns: 1fr; }
	.eha-actions { flex-direction: column; }
	.eha-actions .eha-btn { width: 100%; }
}

@media (prefers-reduced-motion: no-preference) {
	.eha-panel { animation: eha-in 0.4s ease both; }
}

@keyframes eha-in {
	from { opacity: 0; transform: translateY(8px); }
	to { opacity: 1; transform: none; }
}
