/* ================================================================
   قالب «أُفق» — ناشر
   ألوان الهويّة متغيّرات يختارها الناشر؛ ما عداها ألوانٌ محايدة.
   ================================================================ */
:root {
	--store-primary: #FB6000;
	--store-primary-dark: #C24A00;
	--store-accent: #1A1A1A;
	--store-bg: #FFFFFF;
	--store-text: #1A1A1A;

	/* محايدة */
	--muted: #5F5F5F;
	--soft: #F6F6F6;
	--soft-2: #FAFAFA;
	--line: #EBEBEB;
	--white: #FFFFFF;
	--gold: #F2A516;
	--green: #2F7A3D;
	--peach: color-mix(in srgb, var(--store-primary) 16%, #FFFFFF);
	--peach-soft: color-mix(in srgb, var(--store-primary) 7%, #F7F3F0);

	/* أنواع الكتب (القاعدة 6) */
	--type-print: #DB7056;
	--type-ebook: #5675A3;
	--type-audio: #986AB0;
	--type-educational: #3f8f6b;

	--radius: 10px;
	--radius-lg: 16px;
	--pill: 999px;
	--container: 1360px;
	--gutter: 24px;
	--bpr: 4;
	--font: "Tajawal", system-ui, sans-serif;
	--shadow: 0 10px 30px rgba(20, 20, 20, .08);
}

body[data-corners="sharp"] { --radius: 0; --radius-lg: 0; --pill: 0; }
body[data-books-per-row="3"] { --bpr: 3; }
body[data-books-per-row="4"] { --bpr: 4; }
body[data-books-per-row="5"] { --bpr: 5; }
body[data-books-per-row="6"] { --bpr: 6; }

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body {
	margin: 0;
	font-family: var(--font);
	font-size: 16px;
	line-height: 1.7;
	color: var(--store-text);
	background: var(--store-bg);
	overflow-x: hidden;
}
img { max-width: 100%; height: auto; display: block; }
a { color: inherit; text-decoration: none; }
button, input, select, textarea { font: inherit; color: inherit; }
button { cursor: pointer; }
h1, h2, h3, p { margin: 0; }
ul, ol { margin: 0; padding: 0; list-style: none; }
:focus-visible { outline: 2px solid var(--store-accent); outline-offset: 2px; }

.container { width: 100%; max-width: var(--container); margin-inline: auto; padding-inline: var(--gutter); }
.visually-hidden { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.skip-link { position: absolute; inset-inline-start: 12px; top: -60px; z-index: 100; background: var(--store-accent); color: var(--white); padding: 8px 14px; border-radius: var(--radius); }
.skip-link:focus { top: 12px; }

.icon { width: 22px; height: 22px; fill: none; stroke: currentColor; stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; flex-shrink: 0; }
.icon-fill { fill: currentColor; stroke: none; }

/* ---------------------------------------------------------------- الأزرار */
.btn {
	display: inline-flex; align-items: center; justify-content: center; gap: 8px;
	min-height: 46px; padding: 10px 26px;
	border: 1px solid transparent; border-radius: var(--pill);
	font-weight: 500; font-size: 15px; line-height: 1.2; white-space: nowrap;
	transition: background-color .2s, color .2s, border-color .2s;
}
.btn .icon { width: 19px; height: 19px; }
.btn-primary { background: var(--store-primary); color: var(--store-accent); }
.btn-primary:hover { background: var(--store-accent); color: var(--white); }
.btn-dark { background: var(--store-accent); color: var(--white); border-radius: min(6px, var(--pill)); }
.btn-dark:hover { background: var(--store-primary); color: var(--store-accent); }
.btn-outline { background: var(--white); border-color: var(--store-accent); color: var(--store-accent); }
.btn-outline:hover { background: var(--store-accent); color: var(--white); }
.btn-lg { min-height: 52px; padding: 12px 32px; font-size: 16px; }
.btn-sm { min-height: 38px; padding: 6px 16px; font-size: 14px; }
.btn-block { width: 100%; }
.btn[disabled] { opacity: .5; cursor: not-allowed; }

.icon-btn {
	position: relative; display: inline-grid; place-items: center;
	width: 42px; height: 42px; padding: 0;
	background: transparent; border: 0; border-radius: 50%; color: var(--store-text);
}
.icon-btn:hover { background: var(--soft); }
.icon-btn-lg { width: 52px; height: 52px; border: 1px solid var(--line); }
.icon-btn[aria-pressed="true"] .icon, .wish-btn[aria-pressed="true"] .icon { fill: var(--store-primary); stroke: var(--store-primary); }

.link-arrow { display: inline-flex; align-items: center; gap: 6px; font-weight: 500; border-bottom: 1px solid currentColor; padding-bottom: 2px; }
.link-arrow .icon { width: 18px; height: 18px; transform: scaleX(-1); }
.link-arrow:hover { color: var(--store-primary-dark); }

.eyebrow {
	display: inline-flex; align-items: center; gap: 6px;
	padding: 3px 14px; border-radius: var(--pill);
	background: var(--peach); color: var(--store-text);
	font-size: 13px; font-weight: 500;
}

.badge { display: inline-block; padding: 2px 8px; border-radius: min(4px, var(--radius)); font-size: 12px; font-weight: 700; line-height: 1.6; }
.badge-sale { background: var(--store-primary-dark); color: var(--white); }
.badge-new { background: var(--green); color: var(--white); }

/* ---------------------------------------------------------------- نوع الكتاب */
.type-dot {
	display: inline-grid; place-items: center;
	width: 32px; height: 32px; border-radius: 50%;
	color: var(--white); box-shadow: 0 0 0 2px var(--white);
}
.type-dot .icon { width: 17px; height: 17px; stroke-width: 1.8; }
.type-dot[data-type="print"] { background: var(--type-print); }
.type-dot[data-type="ebook"] { background: var(--type-ebook); }
.type-dot[data-type="audio"] { background: var(--type-audio); }
.type-dot[data-type="educational"] { background: var(--type-educational); }

/* ---------------------------------------------------------------- التقييم والسعر */
.rating { display: inline-flex; align-items: center; gap: 6px; font-size: 13px; color: var(--muted); }
.stars { display: inline-flex; gap: 1px; color: var(--gold); }
.stars .icon { width: 15px; height: 15px; }
.stars .off { color: #D9D9D9; }
.price { display: inline-flex; align-items: baseline; flex-wrap: wrap; gap: 4px 10px; font-weight: 700; font-size: 16px; color: var(--store-text); }
.price.is-sale > span { color: var(--store-primary-dark); }
.price del { color: var(--muted); font-weight: 400; font-size: 14px; }
.price-lg { font-size: 26px; }
.price-lg del { font-size: 18px; }

/* ---------------------------------------------------------------- شريط الإعلان */
.announce { background: var(--store-primary); color: var(--store-accent); font-size: 14px; }
.announce .container { display: flex; align-items: center; justify-content: space-between; gap: 16px; min-height: 40px; }
.announce p { display: inline-flex; align-items: center; gap: 8px; font-weight: 500; }
.announce p:empty, .announce p:not(:has(span:not(:empty))) { display: none; }
.announce .icon { width: 16px; height: 16px; }
.announce-links { display: flex; gap: 22px; }
.announce-links a:hover { text-decoration: underline; }

/* ---------------------------------------------------------------- الرأس */
.site-header { position: sticky; top: 0; z-index: 40; background: var(--white); border-bottom: 1px solid var(--line); }
.header-row { display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; gap: 16px; min-height: 76px; }
.header-start { display: flex; align-items: center; gap: 8px; }
.menu-toggle { display: none; }
.nav-list { display: flex; align-items: center; gap: 4px; }
.nav-list > li > a, .nav-list > li > button {
	display: inline-flex; align-items: center; gap: 4px;
	padding: 8px 12px; background: none; border: 0; font-weight: 500; font-size: 15px;
}
.nav-list > li > a:hover, .nav-list > li > button:hover { color: var(--store-primary-dark); }
.nav-list .icon { width: 16px; height: 16px; transition: transform .2s; }
.has-mega.open > button .icon { transform: rotate(180deg); }
.mega {
	position: absolute; inset-inline: 0; top: 100%;
	background: var(--white); border-top: 1px solid var(--line); box-shadow: var(--shadow);
	opacity: 0; visibility: hidden; transform: translateY(8px); transition: .2s;
}
.has-mega:hover .mega, .has-mega:focus-within .mega, .has-mega.open .mega { opacity: 1; visibility: visible; transform: none; }
.mega-inner { display: grid; grid-template-columns: 1fr 1fr 280px; gap: 32px; padding-block: 28px; }
.mega h3 { font-size: 15px; font-weight: 700; margin-bottom: 10px; }
.mega-links a { display: block; padding: 5px 0; color: var(--muted); }
.mega-links a:hover { color: var(--store-text); }
.mega-card { position: relative; border-radius: var(--radius); overflow: hidden; aspect-ratio: 4 / 3; }
.mega-card img { width: 100%; height: 100%; object-fit: cover; }
.mega-card span {
	position: absolute; inset-inline-start: 14px; bottom: 14px;
	display: inline-flex; align-items: center; gap: 6px;
	background: var(--white); padding: 6px 14px; border-radius: var(--pill); font-weight: 500; font-size: 14px;
}
.mega-card .icon { width: 16px; height: 16px; transform: scaleX(-1); }

.brand { display: inline-flex; align-items: center; gap: 10px; justify-self: center; }
.brand img { width: 40px; height: 40px; border-radius: 10px; }
.brand-name { font-size: 24px; font-weight: 700; letter-spacing: -.01em; white-space: nowrap; }

.header-actions { display: flex; align-items: center; justify-content: flex-end; gap: 2px; }
.icon-btn .count, .mobile-bar .count {
	position: absolute; top: 2px; inset-inline-end: 0;
	min-width: 18px; height: 18px; padding: 0 4px; border-radius: 9px;
	background: var(--store-primary); color: var(--store-accent);
	font-size: 11px; font-weight: 700; line-height: 18px; text-align: center;
}

.search-panel { display: none; border-top: 1px solid var(--line); background: var(--white); }
body.search-open .search-panel { display: block; }
.search-panel .container { display: flex; gap: 10px; padding-block: 14px; }
.search-panel input, .field {
	flex: 1; min-width: 0; min-height: 46px; padding: 8px 18px;
	border: 1px solid var(--line); border-radius: var(--pill); background: var(--white);
}
.field { border-radius: min(8px, var(--radius)); }
textarea.field { width: 100%; resize: vertical; }

/* الدرج */
.drawer-backdrop { position: fixed; inset: 0; z-index: 60; background: rgba(0, 0, 0, .4); opacity: 0; visibility: hidden; transition: .25s; }
.drawer {
	position: fixed; top: 0; bottom: 0; inset-inline-start: 0; z-index: 70;
	width: min(330px, 86vw); padding: 18px; overflow-y: auto;
	background: var(--white); transform: translateX(100%); visibility: hidden; transition: transform .25s, visibility .25s;
}
body.drawer-open .drawer { transform: none; visibility: visible; }
body.drawer-open .drawer-backdrop, body.filters-open .drawer-backdrop { opacity: 1; visibility: visible; }
.drawer-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 14px; }
.drawer-head .brand-name { font-size: 20px; }
.drawer-nav a { display: block; padding: 11px 0; border-bottom: 1px solid var(--line); font-weight: 500; }
.drawer-title { font-size: 14px; color: var(--muted); font-weight: 500; margin: 20px 0 8px; }
.drawer-cats { display: flex; flex-wrap: wrap; gap: 8px; }
.drawer-cats a { padding: 6px 14px; border-radius: var(--pill); background: var(--soft); font-size: 14px; }
.drawer-phone { display: inline-flex; align-items: center; gap: 8px; margin-top: 22px; font-weight: 500; }

/* ---------------------------------------------------------------- الأقسام */
.section { padding-block: 72px; }
.section-tight { padding-block: 32px; }
.section-soft { background: var(--soft); }
.section-head { display: flex; flex-direction: column; gap: 10px; margin-bottom: 36px; }
.section-head.center { align-items: center; text-align: center; }
.section-head.start { align-items: flex-start; }
.section-title { font-weight: 300; font-size: clamp(28px, 2.9vw, 40px); line-height: 1.3; letter-spacing: -.01em; }
.section-title.small { font-size: 26px; }
.section-desc { max-width: 600px; color: var(--muted); font-size: 16px; }
.section-more { display: flex; justify-content: center; margin-top: 36px; }

/* ---------------------------------------------------------------- السلايدر */
.hero { position: relative; background: var(--soft); }
.slider { position: relative; }
.slides { display: flex; overflow-x: auto; scroll-snap-type: x mandatory; scrollbar-width: none; }
.slides::-webkit-scrollbar { display: none; }
.slide { position: relative; flex: 0 0 100%; scroll-snap-align: start; min-height: clamp(440px, 46vw, 640px); display: flex; align-items: center; overflow: hidden; }
.slide > img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; object-position: left center; }
.slide .container { position: relative; }
.slide-copy { max-width: 560px; display: flex; flex-direction: column; align-items: flex-start; gap: 18px; padding-block: 60px; }
.tag { display: inline-flex; align-items: center; gap: 6px; padding: 4px 14px; border-radius: var(--pill); background: var(--white); font-size: 13px; font-weight: 500; }
.tag .icon { width: 15px; height: 15px; color: var(--store-primary-dark); }
.slide-copy h1, .slide-copy h2 { font-weight: 300; font-size: clamp(36px, 4.6vw, 64px); line-height: 1.2; letter-spacing: -.015em; }
.slide-copy p { font-size: 17px; color: #3D3D3D; max-width: 460px; }
.slider-nav { position: absolute; bottom: 26px; inset-inline: 0; pointer-events: none; }
.slider-dots { display: flex; gap: 6px; pointer-events: auto; }
.slider-dots button { width: 26px; height: 4px; padding: 0; border: 0; border-radius: 2px; background: rgba(26, 26, 26, .25); transition: width .25s, background-color .25s; }
.slider-dots button[aria-current="true"] { width: 44px; background: var(--store-accent); }

/* ---------------------------------------------------------------- بطاقة الكتاب */
.book-grid { display: grid; grid-template-columns: repeat(var(--bpr), minmax(0, 1fr)); gap: 28px 20px; }
.book-grid.duo { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.book-card { position: relative; display: flex; flex-direction: column; gap: 14px; min-width: 0; }
/* الصندوق الرماديّ: الغلاف في الأعلى، وزرّ السلّة الأبيض ثابتٌ تحته داخل الصندوق، وشريط التخفيض في أسفله */
.book-media {
	position: relative; overflow: hidden;
	aspect-ratio: 4 / 5; border-radius: var(--radius);
	background: var(--soft);
	display: grid; grid-template-rows: minmax(0, 1fr) auto auto; justify-items: center;
}
.book-cover { display: flex; align-items: center; justify-content: center; min-height: 0; height: 100%; max-width: 74%; padding-block: 18px 12px; transition: transform .35s; }
.book-cover img { height: 100%; width: auto; max-width: 100%; aspect-ratio: 2 / 3; object-fit: cover; border-radius: 3px; box-shadow: 0 14px 26px rgba(0, 0, 0, .18), 0 2px 4px rgba(0, 0, 0, .12); }
.book-card:hover .book-cover { transform: translateY(-6px); }
.book-media > .type-dot { position: absolute; top: 12px; inset-inline-end: 12px; z-index: 2; }
.book-badges { position: absolute; top: 12px; inset-inline-start: 12px; z-index: 2; display: flex; flex-direction: column; align-items: flex-start; gap: 6px; }
.wish-btn {
	position: absolute; top: 52px; inset-inline-end: 12px; z-index: 2;
	display: grid; place-items: center; width: 32px; height: 32px; padding: 0;
	border: 0; border-radius: 50%; background: var(--white); color: var(--store-text); box-shadow: 0 2px 8px rgba(0, 0, 0, .1);
	opacity: 0; transform: translateX(-6px); transition: .2s;
}
.wish-btn .icon { width: 17px; height: 17px; }
.card-cart, .stock-band {
	position: relative; z-index: 3; justify-self: stretch;
	display: flex; align-items: center; justify-content: center; gap: 8px;
	min-height: 40px; margin: 0 12px 12px; padding: 4px 10px;
	border: 1px solid var(--line); border-radius: min(6px, var(--radius));
	background: var(--white); color: var(--store-text); font-weight: 500; font-size: 14px; line-height: 1.3;
	box-shadow: 0 4px 14px rgba(0, 0, 0, .06);
	transition: background-color .2s, color .2s, border-color .2s;
}
.card-cart .icon { width: 18px; height: 18px; }
.card-cart:hover { background: var(--store-accent); border-color: var(--store-accent); color: var(--white); }
.book-card:hover .wish-btn, .book-card:focus-within .wish-btn, .wish-btn[aria-pressed="true"] { opacity: 1; transform: none; }
@media (hover: none) {
	.wish-btn { opacity: 1; transform: none; }
}

/* شريط التخفيض المتحرّك أسفل الغلاف — علامة «أُفق» */
.sale-strip { position: relative; justify-self: stretch; z-index: 2; overflow: hidden; background: var(--store-accent); color: var(--white); height: 28px; }
.sale-run { display: flex; align-items: center; gap: 10px; width: max-content; height: 100%; font-size: 12px; font-weight: 700; white-space: nowrap; animation: strip 14s linear infinite; }
.sale-run .icon { width: 13px; height: 13px; color: var(--store-primary); fill: currentColor; stroke: none; }
@keyframes strip { from { transform: translateX(0); } to { transform: translateX(50%); } }

.stock-band { background: var(--store-accent); border-color: var(--store-accent); color: var(--white); box-shadow: none; cursor: not-allowed; }
.is-out .book-cover { opacity: .55; filter: grayscale(.6); }

.book-body { display: flex; flex-direction: column; gap: 4px; }
.book-title { font-size: 16px; font-weight: 500; line-height: 1.45; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.book-title a:hover { color: var(--store-primary-dark); }
.book-author { color: var(--muted); font-size: 14px; }
.book-body .price { margin-top: 2px; }

/* أشكال البطاقة */
body[data-card-style="framed"] .book-card { padding: 10px; border: 1px solid var(--line); border-radius: var(--radius-lg); background: var(--white); }
body[data-card-style="framed"] .book-media { background: var(--soft-2); }
body[data-card-style="framed"] .book-body { padding: 0 6px 6px; }
body[data-card-style="minimal"] .book-media { background: transparent; aspect-ratio: auto; }
body[data-card-style="minimal"] .book-cover { width: 100%; max-width: none; height: auto; padding: 0 0 10px; }
body[data-card-style="minimal"] .book-cover img { width: 100%; height: auto; border-radius: var(--radius); box-shadow: none; }
body[data-card-style="minimal"] .card-cart, body[data-card-style="minimal"] .stock-band { margin: 0 0 10px; box-shadow: none; }
body[data-card-style="minimal"] .sale-strip { border-radius: min(4px, var(--radius)); }
body[data-card-style="minimal"] .book-card:hover .book-cover { transform: none; }

/* البطاقة الصغيرة (شاهدتَه مؤخّرًا) */
.section-recent { padding-block: 48px; border-top: 1px solid var(--line); }
.recent-row { display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); gap: 16px; }
.mini-card { display: flex; gap: 12px; align-items: center; min-width: 0; }
.mini-cover { position: relative; flex: 0 0 64px; }
.mini-cover img { width: 64px; aspect-ratio: 2 / 3; object-fit: cover; border-radius: 4px; }
.mini-cover .type-dot { position: absolute; bottom: -6px; inset-inline-end: -6px; width: 24px; height: 24px; }
.mini-cover .type-dot .icon { width: 13px; height: 13px; }
.mini-card > div { min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.mini-card .book-title { font-size: 14px; }
.mini-card .book-author { font-size: 13px; }
.mini-card .price { font-size: 14px; }
.mini-card .price del { font-size: 12px; }

/* ---------------------------------------------------------------- البانرات الثلاثة */
.promo-trio { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; }
.promo { position: relative; display: flex; align-items: flex-end; aspect-ratio: 6 / 7; overflow: hidden; border-radius: var(--radius); color: var(--white); isolation: isolate; }
.promo img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; z-index: -2; transition: transform .6s; }
.promo::after { content: ""; position: absolute; inset: 0; z-index: -1; background: linear-gradient(to top, rgba(0, 0, 0, .72), rgba(0, 0, 0, .1) 55%, transparent); }
.promo:hover img { transform: scale(1.04); }
.promo-copy { display: flex; flex-direction: column; gap: 6px; padding: 26px; }
.promo-title { font-size: clamp(22px, 2.2vw, 30px); font-weight: 300; line-height: 1.25; }
.promo-text { font-size: 15px; opacity: .95; }
.promo-link { display: inline-flex; align-items: center; gap: 6px; margin-top: 8px; font-weight: 500; font-size: 14px; }
.promo-link .icon { width: 17px; height: 17px; transform: scaleX(-1); }

/* ---------------------------------------------------------------- شريط العبارات */
.marquee { overflow: hidden; padding-block: 30px; border-block: 1px solid var(--line); background: var(--soft-2); }
.marquee-track { display: flex; width: max-content; animation: marquee 40s linear infinite; }
.marquee:hover .marquee-track { animation-play-state: paused; }
.marquee-list { display: flex; flex-shrink: 0; }
.marquee-list:empty { display: none; }
.marquee:not(:has(.marquee-list li)) { display: none; }
.marquee-list li { display: flex; align-items: center; gap: 40px; padding-inline-end: 40px; font-size: clamp(30px, 3.6vw, 52px); font-weight: 300; line-height: 1.3; white-space: nowrap; }
.marquee-list li:nth-child(even) { color: var(--store-primary-dark); }
.marquee-list li::after { content: ""; width: 14px; height: 14px; border-radius: 50%; background: var(--store-primary); }
@keyframes marquee { from { transform: translateX(0); } to { transform: translateX(50%); } }

/* ---------------------------------------------------------------- المجموعة المختارة */
.season-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 56px; align-items: stretch; }
.season-grid > :only-child { grid-column: 1 / -1; }
.season:not(:has([data-region])) { display: none; }
.season-media { position: relative; display: block; min-height: 520px; overflow: hidden; border-radius: var(--radius-lg); }
.season-media img { position: absolute; inset: 0; }
.season-media img { width: 100%; height: 100%; object-fit: cover; }
.season-chip { position: absolute; bottom: 20px; inset-inline-start: 20px; padding: 6px 16px; border-radius: var(--pill); background: var(--white); font-weight: 500; }
.season-info { display: flex; flex-direction: column; align-items: flex-start; justify-content: center; gap: 28px; }
.season-info .section-head { margin-bottom: 0; }
.season-info .book-grid { width: 100%; max-width: 560px; }
.season-info .book-media { background: var(--white); }

/* ---------------------------------------------------------------- التصنيفات */
.cat-row { display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); gap: 24px; }
.cat { display: flex; flex-direction: column; align-items: center; gap: 10px; text-align: center; }
.cat-img { display: block; width: 100%; max-width: 160px; aspect-ratio: 1; overflow: hidden; border-radius: 50%; background: var(--soft); transition: transform .3s; }
.cat-img img { width: 100%; height: 100%; object-fit: cover; }
.cat:hover .cat-img { transform: translateY(-4px); }
.cat h3 { font-size: 17px; font-weight: 500; }
.cat small { color: var(--muted); font-size: 13px; margin-top: -8px; }

/* ---------------------------------------------------------------- البانر العريض */
.wide-banner { display: grid; grid-template-columns: 1fr 1.25fr; align-items: stretch; min-height: 420px; overflow: hidden; border-radius: var(--radius-lg); background: var(--peach-soft); }
.wide-copy { display: flex; flex-direction: column; align-items: flex-start; justify-content: center; gap: 18px; padding: 48px; }
.wide-title { font-size: clamp(28px, 3vw, 44px); font-weight: 300; line-height: 1.25; }
.wide-text { color: #3D3D3D; max-width: 420px; }
.wide-banner img { width: 100%; height: 100%; object-fit: cover; object-position: left center; }

/* ---------------------------------------------------------------- الآراء */
.reviews-total { display: inline-flex; align-items: center; gap: 10px; font-size: 15px; }
.reviews-total .stars .icon { width: 18px; height: 18px; }
.review-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 20px; }
.review-card { display: flex; flex-direction: column; gap: 14px; padding: 26px; border: 1px solid var(--line); border-radius: var(--radius-lg); background: var(--white); }
.review-card p { flex: 1; }
.review-who { display: flex; gap: 12px; align-items: center; }
.review-avatar { display: grid; place-items: center; flex: 0 0 44px; height: 44px; border-radius: 50%; background: var(--peach); font-weight: 700; }
.review-who b { font-weight: 700; margin-inline-end: 8px; }
.verified { display: inline-flex; align-items: center; gap: 4px; color: var(--green); font-size: 13px; }
.verified .icon { width: 15px; height: 15px; }
.review-who small { display: block; color: var(--muted); font-size: 13px; }
.review-who small a { color: var(--store-text); font-weight: 500; }
body[data-show-reviews="false"] .reviews-section { display: none; }

/* ---------------------------------------------------------------- شريط الثقة */
.trust-section { padding-block: 56px; border-top: 1px solid var(--line); }
.trust-bar { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 24px; text-align: center; }
.trust-item { display: flex; flex-direction: column; align-items: center; gap: 6px; }
.trust-icon { display: grid; place-items: center; width: 56px; height: 56px; margin-bottom: 4px; }
.trust-icon .icon { width: 34px; height: 34px; stroke-width: 1.3; }
.trust-item h3 { font-size: 17px; font-weight: 500; }
.trust-item p { color: var(--muted); font-size: 14px; }
body[data-show-trust-bar="false"] .trust-section { display: none; }

/* ---------------------------------------------------------------- المؤلّفون */
.author-row { display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); gap: 24px; }
.author-card { display: flex; flex-direction: column; align-items: center; gap: 6px; text-align: center; }
.author-card img { width: 100%; max-width: 160px; aspect-ratio: 1; border-radius: 50%; object-fit: cover; margin-bottom: 8px; transition: transform .3s; }
.author-card:hover img { transform: scale(1.04); }
.author-card h3 { font-size: 17px; font-weight: 500; }
.author-card small { color: var(--muted); font-size: 13px; }

/* ---------------------------------------------------------------- التذييل */
.site-footer { padding-top: 64px; border-top: 1px solid var(--line); background: var(--white); }
.footer-grid { display: grid; grid-template-columns: 1.4fr .8fr .8fr 1.4fr; gap: 40px; padding-bottom: 48px; }
.footer-about .brand { justify-self: start; margin-bottom: 18px; }
.footer-contact { display: flex; flex-direction: column; gap: 10px; color: var(--muted); font-size: 15px; }
.footer-contact li { display: flex; align-items: center; gap: 10px; }
.footer-contact .icon { width: 18px; height: 18px; color: var(--store-text); }
.social { display: flex; gap: 8px; margin-top: 20px; }
.social a { display: grid; place-items: center; width: 40px; height: 40px; border: 1px solid var(--line); border-radius: 50%; }
.social a:hover { background: var(--store-accent); color: var(--white); }
.social .icon { width: 18px; height: 18px; }
.footer-col h3 { font-size: 18px; font-weight: 700; margin-bottom: 14px; }
.footer-col li a { display: block; padding: 4px 0; color: var(--muted); font-size: 15px; }
.footer-col li a:hover { color: var(--store-text); }
.footer-news p { color: var(--muted); font-size: 15px; margin-bottom: 16px; }
.newsletter { display: flex; align-items: center; gap: 8px; padding: 4px; padding-inline-start: 18px; border: 1px solid var(--line); border-radius: var(--pill); }
.newsletter input { flex: 1; min-width: 0; border: 0; background: transparent; min-height: 40px; }
.newsletter input:focus { outline: none; }
.newsletter:focus-within { border-color: var(--store-accent); }
.newsletter button { display: grid; place-items: center; width: 56px; height: 40px; border: 0; border-radius: var(--pill); background: var(--store-accent); color: var(--white); }
.newsletter button:hover { background: var(--store-primary); color: var(--store-accent); }
.footer-bottom { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 10px; padding-block: 22px; border-top: 1px solid var(--line); color: var(--muted); font-size: 14px; }

.mobile-bar { display: none; }

/* ---------------------------------------------------------------- رأس الصفحات الداخليّة */
.page-head { padding-block: 40px 44px; background: var(--soft); }
.page-head .eyebrow { margin-top: 18px; background: var(--white); }
.page-head h1 { font-weight: 300; font-size: clamp(32px, 3.6vw, 50px); line-height: 1.25; margin-top: 10px; }
.page-head p { color: var(--muted); max-width: 640px; margin-top: 8px; }
.breadcrumb { display: flex; flex-wrap: wrap; gap: 6px; font-size: 14px; color: var(--muted); }
.breadcrumb li + li::before { content: "/"; margin-inline-end: 6px; color: #9A9A9A; }
.breadcrumb a:hover { color: var(--store-text); }
.breadcrumb [aria-current] { color: var(--store-text); }

/* التصنيف */
.sub-row { display: flex; gap: 22px; overflow-x: auto; padding-bottom: 6px; scrollbar-width: thin; }
.sub-cat { display: flex; flex-direction: column; align-items: center; gap: 8px; flex: 0 0 112px; text-align: center; font-weight: 500; font-size: 15px; }
.sub-cat .cat-img { width: 96px; }
.listing { display: grid; grid-template-columns: 270px minmax(0, 1fr); gap: 36px; align-items: start; }
.filters { position: sticky; top: 96px; display: flex; flex-direction: column; gap: 4px; }
.filters-head { display: flex; align-items: center; justify-content: space-between; padding-bottom: 10px; border-bottom: 1px solid var(--store-accent); }
.filters-head h2 { font-size: 19px; font-weight: 500; }
.filters-head .icon-btn { display: none; }
.filter-box { padding-block: 18px; border-bottom: 1px solid var(--line); }
.filter-box h3 { font-size: 16px; font-weight: 500; margin-bottom: 10px; }
.check { display: flex; align-items: center; gap: 10px; padding: 5px 0; font-size: 15px; cursor: pointer; }
.check input { width: 17px; height: 17px; accent-color: var(--store-accent); }
.check small { margin-inline-start: auto; color: var(--muted); }
.price-range { display: flex; align-items: center; gap: 8px; }
.price-range .field { width: 100%; padding-inline: 12px; }
.filters .btn { margin-top: 18px; }
.toolbar { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 26px; }
.toolbar p { color: var(--muted); }
.toolbar b { color: var(--store-text); }
.toolbar-actions { display: flex; gap: 10px; }
.toolbar select.field { flex: none; min-height: 40px; padding-inline: 14px; }
.filters-toggle { display: none; }
.listing-grid { grid-template-columns: repeat(min(var(--bpr), 4), minmax(0, 1fr)); }

.pagination { display: flex; justify-content: center; align-items: center; gap: 8px; margin-top: 48px; }
.pagination a, .pagination span { display: grid; place-items: center; width: 40px; height: 40px; border-radius: 50%; border: 1px solid var(--line); font-weight: 500; font-size: 15px; }
.pagination span { border: 0; color: var(--muted); }
.pagination a:hover { border-color: var(--store-accent); }
.pagination [aria-current="page"] { background: var(--store-accent); border-color: var(--store-accent); color: var(--white); }
.pagination .icon { width: 18px; height: 18px; }

/* صفحة الكتاب */
.section-first { padding-top: 36px; }
.section-first[data-carousel] { padding-top: 56px; padding-bottom: 40px; }
.pdp { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 56px; margin-top: 22px; align-items: start; }
.gallery { display: flex; flex-direction: column; gap: 12px; position: sticky; top: 100px; }
.gallery-main { position: relative; display: grid; place-items: center; aspect-ratio: 1 / 1; border-radius: var(--radius-lg); background: var(--soft); }
.gallery-main img { width: 52%; aspect-ratio: 2 / 3; object-fit: cover; border-radius: 4px; box-shadow: 0 24px 40px rgba(0, 0, 0, .2), 0 3px 6px rgba(0, 0, 0, .12); }
.gallery-main .type-dot { position: absolute; top: 18px; inset-inline-end: 18px; width: 40px; height: 40px; }
.gallery-main .type-dot .icon { width: 21px; height: 21px; }
.thumbs { display: flex; gap: 10px; }
.thumbs button { width: 86px; padding: 10px; border: 1px solid var(--line); border-radius: var(--radius); background: var(--soft); }
.thumbs button[aria-pressed="true"] { border-color: var(--store-accent); }
.thumbs img { width: 100%; aspect-ratio: 2 / 3; object-fit: cover; }
.pdp-info { display: flex; flex-direction: column; align-items: flex-start; gap: 14px; }
.pdp-tags { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.eyebrow-type .type-dot { width: 22px; height: 22px; box-shadow: none; margin-inline-start: -8px; }
.eyebrow-type .type-dot .icon { width: 13px; height: 13px; }
.pdp-info h1 { font-weight: 300; font-size: clamp(32px, 3.4vw, 48px); line-height: 1.2; letter-spacing: -.01em; }
.pdp-author { color: var(--muted); }
.pdp-author a { color: var(--store-text); font-weight: 500; border-bottom: 1px solid currentColor; }
.pdp-rating { display: flex; align-items: center; gap: 14px; font-size: 14px; }
.pdp-rating > a { text-decoration: underline; }
.pdp-lead { color: #3D3D3D; }
.pdp-meta { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); width: 100%; border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; }
.meta-item { display: flex; flex-direction: column; padding: 12px 16px; border-bottom: 1px solid var(--line); border-inline-start: 1px solid var(--line); }
.meta-item:nth-child(3n + 1) { border-inline-start: 0; }
.meta-item:nth-last-child(-n + 3) { border-bottom: 0; }
.meta-item small { color: var(--muted); font-size: 13px; }
.meta-item b { font-weight: 500; font-size: 15px; }
.stock { display: inline-flex; align-items: center; gap: 6px; color: var(--green); font-weight: 500; font-size: 15px; }
.stock .icon { width: 18px; height: 18px; }
.pdp-buttons { display: flex; flex-wrap: wrap; gap: 10px; width: 100%; }
.pdp-buttons .btn-primary { flex: 1 1 220px; }
.pdp-buttons .btn small { font-weight: 400; }
.pdp-perks { display: flex; flex-direction: column; gap: 10px; width: 100%; padding: 18px 20px; border-radius: var(--radius); background: var(--soft); font-size: 15px; }
.pdp-perks li { display: flex; align-items: center; gap: 10px; }
.pdp-perks .icon { width: 20px; height: 20px; }

.tabs { margin-top: 72px; }
.tab-list { display: flex; justify-content: center; gap: 8px; border-bottom: 1px solid var(--line); overflow-x: auto; }
.tab-list button { padding: 12px 20px; background: none; border: 0; border-bottom: 2px solid transparent; font-size: 17px; font-weight: 500; color: var(--muted); white-space: nowrap; }
.tab-list button[aria-selected="true"] { color: var(--store-text); border-bottom-color: var(--store-accent); }
.tab-panel { padding-top: 32px; }
.prose { max-width: 820px; margin-inline: auto; display: flex; flex-direction: column; gap: 14px; color: #3D3D3D; font-size: 17px; }
.spec-table { width: 100%; max-width: 820px; margin-inline: auto; border-collapse: collapse; }
.spec-table th, .spec-table td { padding: 12px 16px; text-align: start; border-bottom: 1px solid var(--line); }
.spec-table th { width: 34%; font-weight: 500; color: var(--muted); }
.reviews-layout { display: grid; grid-template-columns: 300px minmax(0, 1fr); gap: 48px; }
.reviews-side { display: flex; flex-direction: column; gap: 18px; }
.reviews-summary { display: flex; flex-direction: column; gap: 4px; }
.reviews-summary strong { font-size: 52px; font-weight: 300; line-height: 1; }
.reviews-summary small { color: var(--muted); }
.rating-bars { display: flex; flex-direction: column; gap: 8px; font-size: 14px; }
.rating-bars li { display: grid; grid-template-columns: 60px 1fr 40px; gap: 10px; align-items: center; }
.bar { height: 6px; border-radius: 3px; background: var(--line); overflow: hidden; }
.bar span { display: block; height: 100%; background: var(--gold); }
.review-list { display: grid; gap: 16px; }
.review-form { display: flex; flex-direction: column; align-items: flex-start; gap: 10px; margin-top: 24px; padding: 24px; border-radius: var(--radius-lg); background: var(--soft); }
.review-form h3 { font-size: 20px; font-weight: 500; }
.review-note { color: var(--muted); font-size: 14px; }
.star-input { display: flex; flex-direction: row-reverse; justify-content: flex-end; gap: 2px; margin: 0; padding: 0; border: 0; }
.star-input legend { float: right; margin-inline-end: 10px; font-size: 15px; font-weight: 500; }
.star-input label { position: relative; cursor: pointer; color: #CFCFCF; }
.star-input input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.star-input .icon { width: 24px; height: 24px; }
.star-input label:has(input:checked), .star-input label:has(input:checked) ~ label, .star-input label:hover, .star-input label:hover ~ label { color: var(--gold); }
.star-input label:has(input:focus-visible) { outline: 2px solid var(--store-accent); }
.field-label { font-weight: 500; font-size: 15px; }

/* المؤلّف */
.author-head { padding-block: 40px 56px; background: var(--soft); }
.author-hero { display: grid; grid-template-columns: 220px minmax(0, 1fr); gap: 44px; align-items: center; margin-top: 26px; }
.author-photo { width: 220px; aspect-ratio: 1; border-radius: 50%; object-fit: cover; }
.author-hero .eyebrow { background: var(--white); }
.author-hero h1 { font-weight: 300; font-size: clamp(34px, 3.8vw, 52px); line-height: 1.2; margin-block: 8px 10px; }
.bio { color: #3D3D3D; max-width: 720px; }
.author-stats { display: flex; gap: 36px; margin-top: 20px; }
.author-stats div { display: flex; flex-direction: column; }
.author-stats b { font-size: 30px; font-weight: 300; line-height: 1.1; }
.author-stats small { color: var(--muted); }

/* السلّة */
.cart-layout { display: grid; grid-template-columns: minmax(0, 1fr) 380px; gap: 40px; align-items: start; }
.cart-list { border-top: 1px solid var(--store-accent); }
.cart-row { display: grid; grid-template-columns: 88px minmax(0, 1fr) auto 110px 40px; gap: 20px; align-items: center; padding-block: 20px; border-bottom: 1px solid var(--line); }
.cart-cover { display: grid; place-items: center; padding: 8px; border-radius: var(--radius); background: var(--soft); }
.cart-cover img { width: 100%; aspect-ratio: 2 / 3; object-fit: cover; border-radius: 2px; }
.cart-info { display: flex; flex-direction: column; align-items: flex-start; gap: 2px; min-width: 0; }
.cart-type { display: inline-flex; align-items: center; gap: 6px; font-size: 13px; color: var(--muted); }
.cart-type .type-dot { width: 22px; height: 22px; box-shadow: none; }
.cart-type .type-dot .icon { width: 13px; height: 13px; }
.cart-info h3 { font-size: 17px; font-weight: 500; }
.cart-info p { color: var(--muted); font-size: 14px; }
.cart-info .price { font-size: 15px; }
.qty { display: inline-flex; align-items: center; border: 1px solid var(--line); border-radius: var(--pill); }
.qty button { width: 38px; height: 40px; border: 0; background: none; font-size: 18px; }
.qty input { width: 40px; border: 0; text-align: center; background: transparent; -moz-appearance: textfield; }
.qty input::-webkit-inner-spin-button { -webkit-appearance: none; }
.cart-total { text-align: end; font-size: 16px; }
.cart-remove { display: grid; place-items: center; width: 40px; height: 40px; border: 0; border-radius: 50%; background: none; color: var(--muted); }
.cart-remove:hover { background: var(--soft); color: var(--store-text); }
.cart-remove .icon { width: 19px; height: 19px; }
.cart-under { display: flex; justify-content: space-between; align-items: center; gap: 12px; margin-top: 22px; }
.cart-empty { display: flex; flex-direction: column; align-items: center; gap: 12px; padding: 60px 20px; text-align: center; }
.cart-empty[hidden] { display: none; }
.empty-icon { display: grid; place-items: center; width: 80px; height: 80px; border-radius: 50%; background: var(--soft); }
.empty-icon .icon { width: 36px; height: 36px; }
.cart-empty h2 { font-weight: 300; font-size: 30px; }
.cart-empty p { color: var(--muted); }
.summary { position: sticky; top: 100px; display: flex; flex-direction: column; gap: 16px; padding: 28px; border-radius: var(--radius-lg); background: var(--soft); }
.summary h2 { font-size: 22px; font-weight: 500; }
.coupon { display: flex; gap: 8px; }
.coupon .field { min-height: 46px; }
.coupon-applied { display: flex; align-items: center; gap: 6px; font-size: 14px; color: var(--muted); }
.coupon-applied b { color: var(--store-text); }
.coupon-applied button { margin-inline-start: auto; padding: 0; border: 0; background: none; text-decoration: underline; font-size: 14px; }
.summary-list { margin: 0; display: flex; flex-direction: column; }
.summary-list div { display: flex; justify-content: space-between; padding-block: 10px; border-bottom: 1px solid #E2E2E2; }
.summary-list dt { color: var(--muted); }
.summary-list dd { margin: 0; font-weight: 500; }
.summary-total { border-bottom: 0 !important; font-size: 19px; }
.summary-total dt { color: var(--store-text) !important; font-weight: 500; }
.summary-total dd { font-weight: 700 !important; }
.summary-perks { display: flex; flex-direction: column; gap: 8px; font-size: 14px; color: var(--muted); }
.summary-perks li { display: flex; gap: 8px; align-items: center; }
.summary-perks .icon { width: 18px; height: 18px; color: var(--store-text); }

/* 404 */
.notfound { text-align: center; }
.notfound .container { display: flex; flex-direction: column; align-items: center; gap: 14px; }
.nf-code { font-size: clamp(120px, 18vw, 220px); font-weight: 300; line-height: 1; letter-spacing: -.04em; color: var(--store-text); }
.notfound h1 { font-weight: 300; font-size: clamp(28px, 3vw, 40px); }
.notfound p { color: var(--muted); max-width: 520px; }
.nf-search { display: flex; gap: 10px; width: 100%; max-width: 520px; margin-block: 10px; }
.nf-search .field { border-radius: var(--pill); }

/* components.html */
.kit-title { font-size: 22px; font-weight: 500; margin: 48px 0 18px; padding-bottom: 8px; border-bottom: 1px solid var(--line); }
.kit-title:first-child { margin-top: 0; }
.kit-note { color: var(--muted); margin: -8px 0 18px; font-size: 14px; }
.kit-row { display: flex; flex-wrap: wrap; align-items: center; gap: 14px; }
.kit-options { display: flex; flex-direction: column; gap: 12px; }
.kit-options div { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; }
.kit-options b { min-width: 120px; font-weight: 500; }

/* ---------------------------------------------------------------- الحركة */
@media (prefers-reduced-motion: reduce) {
	*, *::before, *::after { animation: none !important; transition: none !important; scroll-behavior: auto !important; }
}

/* ---------------------------------------------------------------- العروض */
@media (max-width: 1180px) {
	.main-nav { display: none; }
	.menu-toggle { display: inline-grid; }
	/* القائمة والشعار يمينًا، والأيقونات يسارًا */
	.header-row { grid-template-columns: auto 1fr auto; }
	.brand { justify-self: start; }
	.book-grid { grid-template-columns: repeat(min(var(--bpr), 4), minmax(0, 1fr)); }
	.recent-row { grid-template-columns: repeat(3, minmax(0, 1fr)); row-gap: 22px; }
	.footer-grid { grid-template-columns: 1fr 1fr; }
	.listing { grid-template-columns: 240px minmax(0, 1fr); gap: 28px; }
	.listing-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}

@media (max-width: 1023px) {
	:root { --gutter: 20px; }
	.section { padding-block: 56px; }
	.announce-links { display: none; }
	.announce .container { justify-content: center; text-align: center; }
	.book-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
	.season-grid { grid-template-columns: 1fr; gap: 32px; }
	.season-media { min-height: 0; aspect-ratio: 16 / 10; }
	.season-info .book-grid { max-width: none; }
	.cat-row, .author-row { grid-template-columns: repeat(3, minmax(0, 1fr)); row-gap: 32px; }
	.review-grid { grid-template-columns: 1fr 1fr; }
	.review-grid > :nth-child(3) { display: none; }
	.trust-bar { grid-template-columns: repeat(2, minmax(0, 1fr)); row-gap: 32px; }
	.wide-banner { grid-template-columns: 1fr; }
	.wide-banner img { aspect-ratio: 16 / 7; height: auto; }
	.wide-copy { padding: 36px 28px; }
	.listing { grid-template-columns: 1fr; }
	.filters {
		position: fixed; top: 0; bottom: 0; inset-inline-start: 0; z-index: 70;
		width: min(340px, 88vw); padding: 20px; overflow-y: auto; background: var(--white);
		transform: translateX(100%); visibility: hidden; transition: transform .25s, visibility .25s;
	}
	body.filters-open .filters { transform: none; visibility: visible; }
	.filters-head .icon-btn, .filters-toggle { display: inline-flex; }
	.pdp { grid-template-columns: 1fr; gap: 32px; }
	.gallery { position: static; }
	.gallery-main { aspect-ratio: 4 / 3; }
	.gallery-main img { width: 36%; }
	.reviews-layout { grid-template-columns: 1fr; gap: 28px; }
	.cart-layout { grid-template-columns: 1fr; }
	.summary { position: static; }
	.tabs { margin-top: 48px; }
}

@media (max-width: 767px) {
	:root { --gutter: 16px; }
	body { padding-bottom: 64px; }
	.section { padding-block: 44px; }
	.section-tight { padding-block: 22px; }
	.section-head { margin-bottom: 26px; }
	.announce { font-size: 13px; }
	.announce .container { min-height: 36px; padding-block: 6px; }
	.header-row { min-height: 62px; gap: 8px; }
	.brand-name { font-size: 19px; }
	.brand img { width: 34px; height: 34px; }
	.hide-sm { display: none; }
	.mobile-bar {
		position: fixed; inset-inline: 0; bottom: 0; z-index: 50;
		display: grid; grid-template-columns: repeat(5, 1fr);
		background: var(--white); border-top: 1px solid var(--line);
		padding-bottom: env(safe-area-inset-bottom);
	}
	.mobile-bar a, .mobile-bar button { position: relative; display: flex; flex-direction: column; align-items: center; gap: 2px; padding: 8px 0 6px; border: 0; background: none; font-size: 12px; color: var(--store-text); }
	.mobile-bar .icon { width: 21px; height: 21px; }
	.mobile-bar .count { top: 3px; inset-inline-end: calc(50% - 22px); }

	.slide { flex-direction: column; align-items: stretch; min-height: 0; background: var(--peach-soft); }
	.slide > img { position: static; order: 2; height: 240px; }
	.slide-copy { padding-block: 36px 28px; gap: 14px; }
	.slide-copy p { font-size: 15px; }
	.slider-nav { bottom: 254px; }

	.book-grid, .listing-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 24px 12px; }
	.book-title { font-size: 15px; }
	.book-media { aspect-ratio: 3 / 4; }
	.card-cart, .stock-band { min-height: 40px; margin: 0 8px 8px; padding-inline: 6px; font-size: 13px; gap: 4px; }
	.card-cart .icon { width: 16px; height: 16px; }
	.book-media > .type-dot { top: 8px; inset-inline-end: 8px; width: 28px; height: 28px; }
	.book-badges { top: 8px; inset-inline-start: 8px; }
	.wish-btn { top: 42px; inset-inline-end: 8px; }
	.book-cover { max-width: 80%; padding-block: 14px 8px; }
	.recent-row { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 18px 12px; }
	.mini-card { flex-direction: column; align-items: flex-start; }

	.promo-trio { grid-template-columns: 1fr; }
	.promo { aspect-ratio: 4 / 3; }
	.marquee { padding-block: 20px; }
	.cat-row, .author-row { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 24px 12px; }
	.cat h3, .author-card h3 { font-size: 15px; }
	.review-grid { grid-template-columns: 1fr; }
	.review-grid > :nth-child(3) { display: flex; }
	.review-card { padding: 20px; }
	.reviews-total { flex-direction: column; gap: 4px; }
	.trust-bar { gap: 24px 12px; }
	.trust-item h3 { font-size: 15px; }
	.trust-item p { font-size: 13px; }
	.wide-copy { padding: 28px 20px; }
	.footer-grid { grid-template-columns: 1fr; gap: 32px; }
	.footer-bottom { flex-direction: column; text-align: center; align-items: center; }

	.page-head { padding-block: 26px 30px; }
	.toolbar { flex-direction: column; align-items: stretch; }
	.toolbar-actions { justify-content: space-between; }
	.toolbar-actions { gap: 8px; }
	.toolbar select.field { flex: 1 1 auto; min-width: 0; width: 100%; }
	.pdp-meta { grid-template-columns: repeat(2, minmax(0, 1fr)); }
	.meta-item:nth-child(3n + 1) { border-inline-start: 1px solid var(--line); }
	.meta-item:nth-child(2n + 1) { border-inline-start: 0; }
	.meta-item:nth-last-child(-n + 3) { border-bottom: 1px solid var(--line); }
	.meta-item:nth-last-child(-n + 2) { border-bottom: 0; }
	.gallery-main { aspect-ratio: 1 / 1; }
	.gallery-main img { width: 52%; }
	.pdp-buttons .btn { flex: 1 1 100%; }
	.pdp-buttons .icon-btn-lg { flex: 0 0 52px; }
	.pdp-buttons .btn-dark { flex: 1 1 calc(100% - 62px); }
	.tab-list { justify-content: flex-start; }
	.tab-list button { padding: 10px 14px; font-size: 15px; }
	.author-hero { grid-template-columns: 1fr; justify-items: center; text-align: center; gap: 20px; }
	.author-photo { width: 160px; }
	.author-stats { justify-content: center; }
	.cart-row { grid-template-columns: 72px minmax(0, 1fr) auto; grid-template-areas: "c i r" "c q t"; gap: 10px 14px; }
	.cart-cover { grid-area: c; align-self: start; }
	.cart-info { grid-area: i; }
	.cart-remove { grid-area: r; align-self: start; }
	.qty { grid-area: q; justify-self: start; }
	.cart-total { grid-area: t; white-space: nowrap; }
	.summary { padding: 22px; }
	.nf-search { flex-direction: column; }
}

/* صفّ «مختارات المتجر»: صفٌّ واحد يُمرَّر أفقيًّا كما في المرجع */
.book-grid.book-scroll {
	grid-template-columns: none; grid-auto-flow: column;
	grid-auto-columns: calc((100% - (var(--bpr) - 1) * 20px) / var(--bpr));
	overflow-x: auto; scroll-snap-type: x mandatory; padding-bottom: 18px;
	scrollbar-width: thin; scrollbar-color: var(--store-accent) var(--line);
}
.book-scroll > .book-card { scroll-snap-align: start; }
@media (max-width: 1023px) { .book-grid.book-scroll { grid-auto-columns: calc((100% - 40px) / 3); } }
@media (max-width: 767px) { .book-grid.book-scroll { grid-auto-columns: calc((100% - 12px) / 2.2); column-gap: 12px; } }
.section-soft .book-media { background: var(--white); }
body[data-card-style="minimal"] .section-soft .book-media { background: transparent; }

/* روابط داخل الصفحة: لا يختفي الهدف تحت الرأس المثبّت */
#t-rev, #p-rev { scroll-margin-top: 96px; }

/* ================================================================ ميزات المنصّة المعتمدة */
/* النظرة السريعة (quick-view) تحت زرّ المفضّلة */
.qv-btn {
	position: absolute; top: 92px; inset-inline-end: 12px; z-index: 2;
	display: grid; place-items: center; width: 32px; height: 32px; padding: 0;
	border: 0; border-radius: 50%; background: var(--white); color: var(--store-text); box-shadow: 0 2px 8px rgba(0, 0, 0, .1);
	opacity: 0; transform: translateX(-6px); transition: .2s .04s;
}
.qv-btn .icon { width: 17px; height: 17px; }
.qv-btn:hover { background: var(--store-accent); color: var(--white); }
.book-card:hover .qv-btn, .book-card:focus-within .qv-btn { opacity: 1; transform: none; }
@media (hover: none) { .qv-btn { opacity: 1; transform: none; } }

/* الباقات (home_bundles) بجانب المختارات */
.season-picks { display: flex; flex-direction: column; align-items: flex-start; gap: 28px; width: 100%; }
.season-picks .book-grid { width: 100%; max-width: 560px; }
.bundles { width: 100%; max-width: 560px; }
.bundles-head { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 12px; margin-bottom: 14px; }
.bundles-head .eyebrow { background: var(--white); }
.bundles-title { font-size: 18px; font-weight: 500; }
.bundle-list { display: grid; gap: 12px; }
.bundle { display: grid; grid-template-columns: auto minmax(0, 1fr) auto; align-items: center; gap: 16px; padding: 14px 16px; border-radius: var(--radius); background: var(--white); border: 1px solid var(--line); }
.bundle-covers { display: flex; padding-inline-end: 22px; }
.bundle-covers img { width: 46px; aspect-ratio: 2 / 3; object-fit: cover; border-radius: 3px; box-shadow: 0 6px 12px rgba(0, 0, 0, .16); border: 2px solid var(--white); }
.bundle-covers img + img { margin-inline-start: -22px; }
.bundle-title { margin: 0; font-size: 16px; font-weight: 700; line-height: 1.4; }
.bundle-books { color: var(--muted); font-size: 13px; line-height: 1.5; margin-top: 2px; display: -webkit-box; -webkit-line-clamp: 1; -webkit-box-orient: vertical; overflow: hidden; }
.bundle-price { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 10px; margin-top: 4px; }
.bundle-saving { padding: 1px 10px; border-radius: var(--pill); background: var(--peach); color: var(--store-text); font-size: 13px; font-weight: 700; }
.bundle-add { min-height: 42px; padding-inline: 16px; font-size: 14px; }
.bundle-add .icon { width: 17px; height: 17px; }

/* الخصم حسب الكمّيّة في صفحة الكتاب (book.qty_discount) */
.qty-deal { display: inline-flex; align-items: center; gap: 8px; margin-top: 10px; padding: 6px 14px; border-radius: var(--pill); background: var(--peach-soft); color: var(--store-text); font-size: 14px; font-weight: 700; }
.qty-deal .icon { width: 16px; height: 16px; }

/* قسيمة الترحيب تحت حقل النشرة (newsletter.offer) */
.nl-offer { display: flex; align-items: center; gap: 8px; margin-top: 12px; color: var(--store-primary-dark); font-size: 14px; font-weight: 700; }
.footer-news .nl-offer { margin-bottom: 0; color: var(--store-primary-dark); }
.nl-offer .icon { width: 16px; height: 16px; flex: none; }

/* المدوّنة (home_latest_posts وblog وpost) */
.post-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 32px 24px; }
.post-card { display: flex; flex-direction: column; gap: 16px; min-width: 0; }
.post-media { display: block; aspect-ratio: 16 / 9; overflow: hidden; border-radius: var(--radius); background: var(--soft); }
.post-media img { width: 100%; height: 100%; object-fit: cover; transition: transform .4s; }
.post-card:hover .post-media img { transform: scale(1.04); }
.post-body { display: flex; flex-direction: column; align-items: flex-start; gap: 8px; }
.post-meta { display: flex; align-items: center; gap: 10px; color: var(--muted); font-size: 14px; }
.post-tag { padding: 2px 12px; border-radius: var(--pill); background: var(--peach); color: var(--store-text); font-weight: 700; font-size: 13px; }
.post-title { font-size: 20px; font-weight: 500; line-height: 1.45; }
.post-title a:hover { color: var(--store-primary-dark); }
.post-excerpt { color: var(--muted); font-size: 15px; line-height: 1.8; }
.post-body .link-arrow { margin-top: 4px; font-size: 15px; }
.center-cta { display: flex; justify-content: center; margin-top: 36px; }
.post-wrap { max-width: 820px; display: flex; flex-direction: column; align-items: flex-start; gap: 32px; }
.post-hero { width: 100%; aspect-ratio: 16 / 9; object-fit: cover; border-radius: var(--radius-lg); }
.post-text { display: grid; gap: 18px; font-size: 18px; line-height: 2; }
.post-text p:first-child { font-size: 20px; }

@media (max-width: 1023px) {
	.post-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
	.bundles, .season-picks .book-grid { max-width: none; }
}
@media (max-width: 767px) {
	.post-grid { grid-template-columns: 1fr; gap: 28px; }
	.bundle { grid-template-columns: auto minmax(0, 1fr); gap: 12px 14px; }
	.bundle-add { grid-column: 1 / -1; width: 100%; }
	.post-text { font-size: 16.5px; }
	.post-text p:first-child { font-size: 18px; }
}

/* ================================================================ الإصدار الثاني */
/* شريط الثقة: صفٌّ رفيع تحت السلايدر */
.trust-section { padding-block: 20px; border-top: 0; border-bottom: 1px solid var(--line); background: var(--white); }
.trust-bar { gap: 16px; text-align: start; }
.trust-item { flex-direction: row; align-items: center; gap: 12px; }
.trust-item > div { display: flex; flex-direction: column; min-width: 0; }
.trust-icon { flex: none; width: 46px; height: 46px; margin: 0; border-radius: 50%; background: var(--peach); }
.trust-icon .icon { width: 24px; height: 24px; stroke-width: 1.5; }
.trust-item h3 { font-size: 15px; font-weight: 700; line-height: 1.4; }
.trust-item p { font-size: 13px; line-height: 1.5; }

/* أسهم الصفّ المتحرّك حول «عرض الكلّ» */
.car-nav { align-items: center; gap: 18px; margin-top: 22px; }
.car-btn { display: grid; place-items: center; width: 42px; height: 42px; padding: 0; border: 1px solid var(--store-accent); border-radius: 50%; background: var(--white); color: var(--store-accent); transition: background-color .2s, color .2s, opacity .2s; }
.car-btn:hover:not(:disabled) { background: var(--store-accent); color: var(--white); }
.car-btn:disabled { opacity: .3; cursor: default; }
.car-btn .icon { width: 18px; height: 18px; }

/* تبويبات صفّ الكتب (القاعدة 16): كبسولاتٌ تحت العنوان */
.row-tabs { display: flex; flex-wrap: wrap; justify-content: center; gap: 8px; margin-top: 8px; }
.row-tab { min-height: 40px; padding: 6px 20px; border: 1px solid var(--line); border-radius: var(--pill); background: var(--white); color: var(--store-text); font-weight: 500; font-size: 15px; transition: background-color .2s, border-color .2s, color .2s; }
.row-tab:hover { border-color: var(--store-accent); }
.row-tab[aria-selected="true"] { background: var(--store-accent); border-color: var(--store-accent); color: var(--white); }
[data-slot="section.tabs"]:not(:has([data-repeat="tab"] ~ [role="tab"])) { display: none; }

/* «الأكثر مبيعًا»: صفٌّ واحد كامل لكلّ عددٍ من الكتب في الصفّ */
.best-grid > :nth-child(n + 7) { display: none; }
body[data-books-per-row="3"] .best-grid > :nth-child(n + 4),
body[data-books-per-row="4"] .best-grid > :nth-child(n + 5),
body[data-books-per-row="5"] .best-grid > :nth-child(n + 6) { display: none; }

/* عرض الأسبوع: كتابٌ واحد كبير بعدّاد */
.deal { background: var(--peach-soft); }
.deal-panel { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.55fr); gap: 56px; align-items: center; }
.deal-head { display: flex; flex-direction: column; align-items: flex-start; gap: 14px; }
.deal-head .eyebrow { background: var(--white); }
.deal-head .eyebrow .icon { width: 15px; height: 15px; color: var(--store-primary-dark); }
.countdown { display: flex; gap: 10px; margin-top: 8px; }
.countdown[hidden] { display: none; }
.cd-unit { display: flex; flex-direction: column; align-items: center; justify-content: center; min-width: 72px; padding: 10px 6px; border-radius: var(--radius); background: var(--store-accent); color: var(--white); }
.cd-unit b { font-size: 30px; font-weight: 300; line-height: 1.1; font-variant-numeric: tabular-nums; }
.cd-unit small { font-size: 13px; }
.deal-items { min-width: 0; }
.deal-book { display: grid; grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.1fr); gap: 36px; align-items: center; padding: 22px; border-radius: var(--radius-lg); background: var(--white); box-shadow: var(--shadow); }
.deal-media { position: relative; display: grid; place-items: center; aspect-ratio: 4 / 5; border-radius: var(--radius); background: var(--soft); }
.deal-media img { width: 62%; aspect-ratio: 2 / 3; object-fit: cover; border-radius: 3px; box-shadow: 0 22px 36px rgba(0, 0, 0, .2), 0 3px 6px rgba(0, 0, 0, .12); transition: transform .35s; }
.deal-media:hover img { transform: translateY(-6px); }
.deal-media > .type-dot { position: absolute; top: 14px; inset-inline-end: 14px; }
.deal-media .book-badges { top: 14px; inset-inline-start: 14px; }
.deal-body { display: flex; flex-direction: column; align-items: flex-start; gap: 8px; min-width: 0; }
.deal-title { font-size: clamp(26px, 2.4vw, 34px); font-weight: 300; line-height: 1.25; }
.deal-title a:hover { color: var(--store-primary-dark); }
.deal-desc { color: #3D3D3D; margin-block: 4px 2px; }
.deal-actions { display: flex; gap: 10px; width: 100%; margin-top: 10px; }
.deal-actions .btn { flex: 1; }

@media (max-width: 1180px) {
	body[data-books-per-row="5"] .best-grid > :nth-child(5),
	body[data-books-per-row="6"] .best-grid > :nth-child(n + 5) { display: none; }
}
@media (max-width: 1023px) {
	.best-grid > :nth-child(n + 4) { display: none !important; }
	.trust-bar { grid-template-columns: repeat(2, minmax(0, 1fr)); row-gap: 16px; }
	.deal-panel { grid-template-columns: 1fr; gap: 28px; }
	.post-grid.home-posts > :nth-child(3) { display: none; }
}
@media (max-width: 767px) {
	.best-grid > :nth-child(4) { display: flex !important; }
	/* صفوفٌ تُمرَّر أفقيًّا في الهاتف بدل التكديس الطويل */
	.trust-section { padding-block: 12px; }
	.trust-bar, .promo-trio, .review-grid, .post-grid.home-posts {
		display: grid; grid-template-columns: none; grid-auto-flow: column;
		overflow-x: auto; scroll-snap-type: x mandatory; scrollbar-width: none;
		margin-inline: calc(var(--gutter) * -1); padding-inline: var(--gutter); scroll-padding-inline: var(--gutter);
	}
	.trust-bar::-webkit-scrollbar, .promo-trio::-webkit-scrollbar, .review-grid::-webkit-scrollbar, .post-grid.home-posts::-webkit-scrollbar { display: none; }
	.trust-bar { grid-auto-columns: 78%; gap: 12px; }
	.trust-item { padding: 10px 12px; border-radius: var(--radius); background: var(--soft-2); }
	.trust-icon { width: 40px; height: 40px; }
	.trust-item h3 { font-size: 14px; }
	.trust-item p { font-size: 12.5px; }
	.promo-trio { grid-auto-columns: 82%; gap: 12px; }
	.review-grid { grid-auto-columns: 86%; gap: 12px; }
	.post-grid.home-posts { grid-auto-columns: 84%; gap: 16px; }
	.post-grid.home-posts > :nth-child(3) { display: flex; }
	.trust-bar > *, .promo-trio > *, .review-grid > *, .post-grid.home-posts > * { scroll-snap-align: start; }
	.car-nav { gap: 14px; margin-top: 14px; }
	.row-tabs { flex-wrap: nowrap; justify-content: flex-start; overflow-x: auto; scrollbar-width: none; width: calc(100% + var(--gutter) * 2); margin-inline: calc(var(--gutter) * -1); padding-inline: var(--gutter); }
	.row-tabs::-webkit-scrollbar { display: none; }
	.row-tab { flex: none; padding-inline: 16px; font-size: 14px; }
	.deal-book { grid-template-columns: 1fr; gap: 18px; padding: 14px; }
	.deal-media { aspect-ratio: 4 / 3; }
	.deal-media img { width: 40%; }
	.cd-unit { min-width: 0; flex: 1; padding: 8px 4px; }
	.cd-unit b { font-size: 24px; }
	.countdown { width: 100%; }
}

/* صفحة الكتاب: اختيار النسخة (book.formats) والكمّيّة قبل الإضافة (cart.add_qty) */
.formats { display: flex; flex-direction: column; gap: 8px; width: 100%; }
.formats-label { font-size: 14px; font-weight: 500; color: var(--muted); }
.format-list { display: flex; flex-wrap: wrap; gap: 8px; }
.format-opt { display: flex; flex-direction: column; min-width: 120px; padding: 8px 18px; border: 1px solid var(--line); border-radius: var(--radius); background: var(--white); line-height: 1.4; transition: border-color .2s; }
.format-opt:hover { border-color: var(--store-accent); }
.format-opt[aria-current="page"] { border-color: var(--store-accent); box-shadow: inset 0 0 0 1px var(--store-accent); background: var(--soft-2); }
.format-name { font-weight: 700; font-size: 15px; }
.format-price { color: var(--muted); font-size: 14px; }
.qty-lg { flex: none; height: 52px; }
.qty-lg button { height: 50px; width: 42px; }
.qty-lg input { width: 44px; font-size: 16px; font-weight: 500; }
@media (max-width: 767px) {
	.format-list { display: grid; grid-template-columns: repeat(auto-fit, minmax(96px, 1fr)); }
	.format-opt { min-width: 0; padding-inline: 12px; }
	.pdp-buttons .qty-lg + .btn-primary { flex: 1 1 calc(100% - 150px); }
}

/* صفحة التصنيف: التصفية المختارة وطريقة العرض */
.view-switch { display: inline-flex; border: 1px solid var(--line); border-radius: var(--pill); overflow: hidden; }
.view-switch button { display: grid; place-items: center; width: 42px; height: 40px; padding: 0; border: 0; background: var(--white); color: var(--muted); }
.view-switch button[aria-pressed="true"] { background: var(--store-accent); color: var(--white); }
.view-switch .icon { width: 18px; height: 18px; }
.active-filters { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; margin: -10px 0 22px; }
.chip { display: inline-flex; align-items: center; gap: 6px; min-height: 34px; padding: 4px 8px 4px 14px; border-radius: var(--pill); background: var(--peach); font-size: 14px; font-weight: 500; }
.chip .icon { width: 15px; height: 15px; }
.chip:hover { background: var(--store-accent); color: var(--white); }
.chip-clear { font-size: 14px; text-decoration: underline; color: var(--muted); }
.listing-grid.is-list { grid-template-columns: 1fr; gap: 16px; }
.is-list .book-card { display: grid; grid-template-columns: 180px minmax(0, 1fr); align-items: center; gap: 24px; padding-bottom: 16px; border-bottom: 1px solid var(--line); }
.is-list .book-title { font-size: 18px; }
@media (max-width: 767px) {
	.is-list .book-card { grid-template-columns: 132px minmax(0, 1fr); gap: 14px; }
	.active-filters { margin-top: -6px; }
}

/* عناوين متوازنة الأسطر، ورقم ISBN في سطرٍ واحد */
.section-title, .wide-title, .promo-title, .slide-copy h1, .slide-copy h2, .deal-title, .pdp-info h1 { text-wrap: balance; }
.meta-item b[data-slot="book.isbn"] { white-space: nowrap; font-size: 14px; letter-spacing: -.01em; }
@media (max-width: 767px) { .meta-item { padding-inline: 12px; } }

/* صفوف الاقتراحات (أربعة كتب): صفٌّ كامل بكلّ عرض */
.book-grid.row-four { grid-template-columns: repeat(4, minmax(0, 1fr)); }
@media (max-width: 1023px) {
	.book-grid.row-four { grid-template-columns: repeat(3, minmax(0, 1fr)); }
	.book-grid.row-four > :nth-child(n + 4) { display: none; }
}
@media (max-width: 767px) {
	.book-grid.row-four { grid-template-columns: repeat(2, minmax(0, 1fr)); }
	.book-grid.row-four > :nth-child(4) { display: flex; }
}

/* الجهاز اللوحيّ: صورة السلايدر تحت النصّ لا خلفه، والمجموعة المختارة في عمودين */
@media (min-width: 768px) and (max-width: 900px) {
	.slide { flex-direction: column; align-items: stretch; min-height: 0; background: var(--peach-soft); }
	.slide > img { position: static; order: 2; height: 300px; }
	.slide-copy { max-width: none; padding-block: 40px 30px; }
	.slider-nav { bottom: 316px; }
}
@media (min-width: 768px) and (max-width: 1023px) {
	.season-info { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 28px; align-items: start; }
	.season-info .bundles { margin-top: 0; }
	.bundle { grid-template-columns: auto minmax(0, 1fr); gap: 10px 14px; }
	.bundle-add { grid-column: 1 / -1; width: 100%; }
	.promo { aspect-ratio: 3 / 4; }
	.promo-copy { padding: 18px; }
	.promo-title { font-size: 21px; }
	.promo-text { font-size: 13.5px; }
}

/* نصّ الرأي: أربعة أسطر على الأكثر، والنصّ الكامل في title (الملحق، البند 5) */
[data-slot="review.text"] { display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 4; line-clamp: 4; overflow: hidden; }
