/* ==========================================================================
   Imam Ali customisations (moved out of inline style="" / <style> blocks)
   RTL/LTR handled through the body.rtl class WordPress adds automatically.
   ========================================================================== */

/* ---------- Shared: responsive YouTube embed (was fixed 560px → overflow on phones) ---------- */
.imamali-video {
	position: relative;
	width: 100%;
	max-width: 560px;
	margin: 15px auto;
	aspect-ratio: 16 / 9;
}
.imamali-video iframe {
	position: absolute;
	inset: 0;
	width: 100%;
	height: 100%;
	border: 0;
}

.imamali-cta {
	float: none !important;
	white-space: normal;
}

/* ---------- Prayer times (#ribbon_right) ---------- */
.imamali-prayer {
	font-size: 24px;
	line-height: 40px;
	margin-top: 14px;
	text-align: center;
}
.imamali-prayer .cred,
.imamali-prayer .cblack {
	color: #fcda4a !important;
}
.imamali-prayer__date {
	margin-top: 10px;
}
.imamali-prayer__selects select {
	display: block;
	width: 100%;
	max-width: 100%;
	margin: 10px auto 0;
	text-align: center;
	text-align-last: center;
	background-color: #0e2c63;
	color: #fcda4a;
	border: 1px solid rgba(252, 218, 74, .4);
	border-radius: 4px;
	padding: 4px 8px;
	font-size: 16px;
	line-height: 1.5;
}
.imamali-prayer__grid {
	display: flex;
	gap: 0 30px;
	margin-top: 10px;
}
.imamali-prayer__table {
	flex: 1 1 0;
	width: 100%;
	border-collapse: collapse;
	background: transparent;
}
.imamali-prayer__table th,
.imamali-prayer__table td {
	border: 0;
	padding: 4px 6px;
	font-weight: normal;
	text-align: start;
}
.imamali-prayer__table td {
	text-align: end;
	direction: ltr;
	unicode-bidi: isolate;
	font-variant-numeric: tabular-nums;
}
@media (max-width: 480px) {
	.imamali-prayer { font-size: 18px; line-height: 30px; }
	.imamali-prayer__grid { gap: 0 12px; }
}

/* ---------- Bottom ribbon social icons (fixes the broken "img .ss" selector) ---------- */
.imamali-socials {
	display: flex;
	flex-wrap: wrap;
	justify-content: center;
	align-items: center;
	gap: 20px;
	margin: 10px 0;
}
.imamali-socials img {
	width: 50px;
	height: 50px;
	transition: transform .3s;
}
.imamali-socials a:hover img,
.imamali-socials a:focus img {
	transform: scale(1.1);
}
@media (max-width: 600px) {
	.imamali-socials { gap: 10px; }
	.imamali-socials img { width: 40px; height: 40px; }
}

/* ---------- Verse of the day ---------- */
.imamali-verse {
	display: flex;
	flex-direction: column;
	align-items: center;
	text-align: center;
	padding: 20px;
}
.imamali-verse [data-verse-text] {
	width: 100%;
}
.imamali-verse__head {
	position: relative;
	width: 100%;
	max-width: 574px;            /* was a fixed 574px box → horizontal scroll on phones */
	margin: 20px auto;
}
.imamali-verse__head img {
	display: block;
	width: 100%;
	height: auto;
}
.imamali-verse__title {
	position: absolute;
	top: 70%;
	left: 50%;
	transform: translate(-50%, -50%);
	color: #fff;
	font-size: 20px;
	white-space: nowrap;
}
.imamali-verse .cgray {
	color: #0e2b63 !important;
	font-size: 20px;
	line-height: 1.5;
	margin: 5px 0;
}
.imamali-verse__surah {
	display: inline-flex;
	align-items: center;
	padding: 10px 20px;
	border: 2px solid #0e2b63;
	border-radius: 30px;
	background: transparent;
	color: #0e2b63;
	font-size: 20px;
	cursor: pointer;
	margin-top: 10px;
	transition: background-color .2s;
}
.imamali-verse__surah:hover,
.imamali-verse__surah:focus {
	background-color: rgba(14, 43, 99, .08);
}
.imamali-verse__actions {
	display: flex;
	align-items: center;
	gap: 16px;
	margin-top: 15px;
}
.imamali-verse__icon {
	background: none;
	border: 0;
	padding: 4px;
	cursor: pointer;
	color: #0e2b63;
	font-size: 25px;
	line-height: 1;
}
@media (max-width: 480px) {
	.imamali-verse__title { font-size: 16px; }
	.imamali-verse .cgray,
	.imamali-verse__surah { font-size: 17px; }
}

/* ---------- Religious counseling ---------- */
.imamali-counseling__text h3 {
	text-align: center;
}
.imamali-counseling__text,
.imamali-counseling__text p,
.imamali-counseling__text a {
	color: #fff;
}
.imamali-counseling__text a {
	text-decoration: underline;
}

/* ---------- Library (packages slot) ---------- */
.imamali-book {
	margin: 20px 0;
}
.imamali-book__title {
	height: 60px;
	margin: 10px 0;
}
.imamali-book__title a {
	color: #0e2b63;
}

/* ---------- Latest news ---------- */
.imamali-news .latestnews-box,
.imamali-news__spacer {
	float: right;
}
.imamali-news__img--feature {
	border: 3px solid #122e65;
	border-radius: 10% / 50%;
}
.imamali-news__img--small {
	border: 3px solid #122e65;
	border-radius: 50% 20% / 10% 40%;
}
.imamali-news__feature-text {
	min-height: 320px;
}
.imamali-news__feature-text .latesnews-content1 {
	margin-top: 75px;
}
.imamali-news__feature-title a {
	font-size: 22px;
	color: #0e2b63;
}
.imamali-news__small .latesnews-content {
	margin-top: 10px;
}
.imamali-news__small .latestnews-title a,
.imamali-news__mobile-text .latestnews-title a {
	color: #0e2b63;
}
.imamali-news__mobile-text {
	margin-top: 20px;
}
.imamali-news__more a {
	font-size: 16px;
}

/* "More" links: right in LTR languages (en/ro), as before */
.imamali-more,
.imamali-news__more {
	float: right;
}
body.rtl .imamali-more {
	float: none;
}
body.rtl .imamali-news__more {
	float: left;
}
.entry-content .imamali-news__more { /* content.php */
	clear: both;
}
