/*
 * Khalifa Al-Khazzi — Main stylesheet (RTL-first)
 * Identity: dark green, antique gold, white, soft beige, calm gray.
 */

:root {
	--kk-primary: #0e3b2c;
	--kk-primary-2: #0a2b20;
	--kk-gold: #c6a24b;
	--kk-gold-2: #a9863a;
	--kk-beige: #f7f3ea;
	--kk-ink: #22302a;
	--kk-gray: #5f6f68;
	--kk-line: #e7e0d2;
	--kk-white: #ffffff;
	--kk-radius: 16px;
	--kk-font: 'IBM Plex Sans Arabic', 'Segoe UI', Tahoma, sans-serif;
	--kk-pattern: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='64' height='64' viewBox='0 0 64 64'%3E%3Cpath d='M32 6l7 19 19 7-19 7-7 19-7-19-19-7 19-7z' fill='none' stroke='%23c6a24b' stroke-opacity='.10'/%3E%3C/svg%3E");
}

/* ---------- Base ---------- */
*, *::before, *::after { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
	margin: 0;
	font-family: var(--kk-font);
	font-size: 17px;
	line-height: 1.9;
	color: var(--kk-ink);
	background: var(--kk-white);
	-webkit-font-smoothing: antialiased;
	text-rendering: optimizeLegibility;
}

img { max-width: 100%; height: auto; display: block; }

a { color: var(--kk-primary); text-decoration: none; transition: color .2s ease; }
a:hover { color: var(--kk-gold-2); }

h1, h2, h3, h4, h5, h6 {
	color: var(--kk-primary);
	font-weight: 700;
	line-height: 1.55;
	margin: 0 0 .5em;
}

p { margin: 0 0 1em; }

::selection { background: rgba(198, 162, 75, .3); }

:focus-visible { outline: 2px solid var(--kk-gold); outline-offset: 2px; border-radius: 4px; }

.kk-container { width: min(100% - 2.5rem, 1280px); margin-inline: auto; }
.kk-container--narrow { width: min(100% - 2.5rem, 880px); }

.screen-reader-text {
	position: absolute !important;
	width: 1px; height: 1px;
	padding: 0; margin: -1px;
	overflow: hidden;
	clip: rect(0, 0, 0, 0);
	white-space: nowrap;
	border: 0;
}

.skip-link {
	position: fixed;
	top: .6rem;
	inset-inline-start: .6rem;
	z-index: 9999;
	background: var(--kk-primary);
	color: #fff;
	padding: .6rem 1.2rem;
	border-radius: 8px;
	transform: translateY(-200%);
	transition: transform .2s ease;
}
.skip-link:focus { transform: none; color: #fff; }

.kk-ic { flex: none; vertical-align: middle; }

/* ---------- Buttons & chips ---------- */
.kk-btn {
	display: inline-flex;
	align-items: center;
	gap: .5rem;
	padding: .72rem 1.7rem;
	border-radius: 999px;
	border: 2px solid transparent;
	font: inherit;
	font-weight: 600;
	font-size: .95rem;
	cursor: pointer;
	transition: transform .25s ease, box-shadow .25s ease, background .25s ease, color .25s ease;
}
.kk-btn--gold { background: var(--kk-gold); color: #fff; }
.kk-btn--gold:hover {
	background: var(--kk-gold-2);
	color: #fff;
	transform: translateY(-2px);
	box-shadow: 0 10px 24px rgba(169, 134, 58, .35);
}
.kk-btn--outline { border-color: var(--kk-primary); color: var(--kk-primary); background: transparent; }
.kk-btn--outline:hover { background: var(--kk-primary); color: #fff; }

.kk-chip {
	display: inline-block;
	background: var(--kk-gold);
	color: #fff;
	padding: .18rem .9rem;
	border-radius: 999px;
	font-size: .78rem;
	font-weight: 600;
}
.kk-chip--soft { background: rgba(198, 162, 75, .14); color: var(--kk-gold-2); }
.kk-chip--soft:hover { background: var(--kk-gold); color: #fff; }

/* ---------- Header ---------- */
.kk-header {
	position: sticky;
	top: 0;
	z-index: 200;
	background: rgba(255, 255, 255, .96);
	backdrop-filter: blur(10px);
	-webkit-backdrop-filter: blur(10px);
	border-bottom: 1px solid var(--kk-line);
	transition: box-shadow .3s ease;
}
body.admin-bar .kk-header { top: 32px; }
@media (max-width: 782px) { body.admin-bar .kk-header { top: 46px; } }

.kk-header.is-stuck { box-shadow: 0 4px 22px rgba(14, 59, 44, .09); }

.kk-header__inner { position: relative; display: flex; align-items: center; gap: 1.6rem; padding-block: .75rem; }

.kk-brand { display: flex; align-items: center; gap: .8rem; margin-inline-end: auto; min-width: 0; }
.kk-brand__logo img { max-height: 56px; width: auto; }
.kk-brand__name { font-size: 1.25rem; font-weight: 700; margin: 0; line-height: 1.4; }
.kk-brand__name a { color: var(--kk-primary); }
.kk-brand__tagline { display: block; font-size: .76rem; font-weight: 400; color: var(--kk-gray); }

.kk-header__actions { display: flex; align-items: center; gap: .5rem; }

.kk-icon-btn {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 42px; height: 42px;
	border-radius: 10px;
	border: 1px solid var(--kk-line);
	background: #fff;
	color: var(--kk-primary);
	cursor: pointer;
	transition: .2s ease;
}
.kk-icon-btn:hover { background: var(--kk-primary); color: #fff; border-color: var(--kk-primary); }

.kk-nav-toggle { display: none; }
.kk-nav-toggle__close { display: none; }
.kk-header.nav-open .kk-nav-toggle__open { display: none; }
.kk-header.nav-open .kk-nav-toggle__close { display: inline-flex; }

/* ---------- Main menu ---------- */
.kk-menu { display: flex; align-items: center; list-style: none; margin: 0; padding: 0; gap: .15rem; }
.kk-menu li { position: relative; }
.kk-menu a {
	display: block;
	padding: .85rem .95rem;
	color: var(--kk-ink);
	font-weight: 500;
	font-size: .96rem;
	border-radius: 8px;
	transition: background .2s ease, color .2s ease;
}
.kk-menu a:hover,
.kk-menu .current-menu-item > a,
.kk-menu .current-menu-ancestor > a { color: var(--kk-primary); background: rgba(198, 162, 75, .12); }

.kk-menu .menu-item-has-children > a::after {
	content: "";
	display: inline-block;
	width: 7px; height: 7px;
	border-inline-end: 2px solid currentColor;
	border-bottom: 2px solid currentColor;
	transform: rotate(45deg) translateY(-2px);
	margin-inline-start: .4rem;
	opacity: .55;
	transition: transform .2s ease;
}
.kk-menu li:hover > a::after { transform: rotate(225deg) translateY(-2px); }

.kk-menu .sub-menu {
	position: absolute;
	top: calc(100% - 4px);
	inset-inline-start: 0;
	min-width: 230px;
	background: #fff;
	border: 1px solid var(--kk-line);
	border-radius: 12px;
	box-shadow: 0 18px 44px rgba(14, 59, 44, .13);
	list-style: none;
	margin: 0;
	padding: .5rem;
	opacity: 0;
	visibility: hidden;
	transform: translateY(12px);
	transition: opacity .25s ease, transform .25s ease, visibility .25s;
	z-index: 60;
}
.kk-menu li:hover > .sub-menu,
.kk-menu li:focus-within > .sub-menu { opacity: 1; visibility: visible; transform: none; }
.kk-menu .sub-menu a { padding: .6rem .9rem; font-size: .92rem; border-radius: 8px; }
.kk-menu .sub-menu .sub-menu { top: 0; inset-inline-start: calc(100% - 8px); }

.kk-submenu-toggle { display: none; }

/* ---------- Header search ---------- */
.kk-header-search { border-top: 1px solid var(--kk-line); padding: .9rem 0; background: var(--kk-beige); background-image: var(--kk-pattern); }

/* ---------- Search form ---------- */
.kk-search-form { display: flex; gap: .6rem; }
.kk-search-form__input {
	flex: 1;
	min-width: 0;
	padding: .85rem 1.15rem;
	border: 1.5px solid var(--kk-line);
	border-radius: 12px;
	font: inherit;
	font-size: 1rem;
	color: var(--kk-ink);
	background: #fff;
	transition: border-color .2s ease, box-shadow .2s ease;
}
.kk-search-form__input:focus {
	outline: none;
	border-color: var(--kk-gold);
	box-shadow: 0 0 0 4px rgba(198, 162, 75, .18);
}
.kk-search-form__btn {
	display: inline-flex;
	align-items: center;
	gap: .5rem;
	background: var(--kk-primary);
	color: #fff;
	border: 0;
	border-radius: 12px;
	padding: .85rem 1.6rem;
	font: inherit;
	font-weight: 600;
	cursor: pointer;
	transition: background .25s ease;
}
.kk-search-form__btn:hover { background: var(--kk-gold-2); }

/* ---------- Hero slider ---------- */
.kk-hero {
	position: relative;
	height: clamp(430px, 62vh, 610px);
	overflow: hidden;
	background: var(--kk-primary);
}
.kk-hero__track { position: absolute; inset: 0; }
.kk-hero__slide {
	position: absolute;
	inset: 0;
	opacity: 0;
	visibility: hidden;
	transition: opacity 1s ease, visibility 1s;
}
.kk-hero__slide.is-active { opacity: 1; visibility: visible; z-index: 1; }

.kk-hero__bg {
	position: absolute;
	inset: 0;
	background-size: cover;
	background-position: center;
	transform: scale(1.02);
}
.kk-hero__slide.is-active .kk-hero__bg { animation: kkKenBurns 9s ease-out forwards; }
@keyframes kkKenBurns { from { transform: scale(1.13); } to { transform: scale(1.02); } }

.kk-hero__bg--plain {
	background-color: var(--kk-primary);
	background-image: var(--kk-pattern);
}

.kk-hero__overlay {
	position: absolute;
	inset: 0;
	background:
		linear-gradient(to top, rgba(7, 27, 21, .92) 0%, rgba(7, 27, 21, .38) 55%, rgba(7, 27, 21, .18) 100%),
		linear-gradient(to left, rgba(7, 27, 21, .5), transparent 65%);
}

.kk-hero__content {
	position: relative;
	z-index: 2;
	height: 100%;
	display: flex;
	flex-direction: column;
	justify-content: flex-end;
	align-items: flex-start;
	padding-bottom: 5rem;
	color: #fff;
}
.kk-hero__content > * { opacity: 0; transform: translateY(26px); transition: opacity .7s ease, transform .7s ease; }
.kk-hero__slide.is-active .kk-hero__content > * { opacity: 1; transform: none; }
.kk-hero__slide.is-active .kk-hero__content > *:nth-child(1) { transition-delay: .15s; }
.kk-hero__slide.is-active .kk-hero__content > *:nth-child(2) { transition-delay: .3s; }
.kk-hero__slide.is-active .kk-hero__content > *:nth-child(3) { transition-delay: .45s; }
.kk-hero__slide.is-active .kk-hero__content > *:nth-child(4) { transition-delay: .6s; }

.kk-hero__title { font-size: clamp(1.5rem, 3.4vw, 2.55rem); color: #fff; margin: .7rem 0 .7rem; max-width: 820px; }
.kk-hero__title a { color: #fff; }
.kk-hero__title a:hover { color: #e9dcba; }
.kk-hero__excerpt {
	max-width: 640px;
	margin: 0 0 1.5rem;
	color: rgba(255, 255, 255, .85);
	display: -webkit-box;
	-webkit-line-clamp: 2;
	-webkit-box-orient: vertical;
	overflow: hidden;
}

.kk-hero__nav {
	position: absolute;
	z-index: 3;
	bottom: 1.15rem;
	inset-inline: 0;
	display: flex;
	align-items: center;
	justify-content: center;
	gap: 1.1rem;
}
.kk-hero__dots { display: flex; gap: .5rem; }
.kk-hero__dot {
	width: 10px; height: 10px;
	border-radius: 6px;
	border: 0;
	padding: 0;
	background: rgba(255, 255, 255, .4);
	cursor: pointer;
	transition: .3s ease;
}
.kk-hero__dot.is-active { background: var(--kk-gold); width: 28px; }
.kk-hero__arrow {
	width: 44px; height: 44px;
	border-radius: 50%;
	border: 1px solid rgba(255, 255, 255, .4);
	background: rgba(255, 255, 255, .1);
	backdrop-filter: blur(4px);
	color: #fff;
	cursor: pointer;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	transition: .25s ease;
}
.kk-hero__arrow:hover { background: var(--kk-gold); border-color: var(--kk-gold); }

/* ---------- Search band ---------- */
.kk-searchband { background: var(--kk-beige); background-image: var(--kk-pattern); padding: 1.7rem 0; border-bottom: 1px solid var(--kk-line); }
.kk-searchband__card {
	background: #fff;
	border: 1px solid var(--kk-line);
	border-radius: var(--kk-radius);
	box-shadow: 0 10px 34px rgba(14, 59, 44, .1);
	padding: 1.1rem 1.2rem .9rem;
}
.kk-searchband__hint { margin: .55rem .2rem 0; font-size: .83rem; color: var(--kk-gray); }

/* ---------- Sections ---------- */
.kk-section { padding: 3.4rem 0; }
.kk-section--beige { background: var(--kk-beige); background-image: var(--kk-pattern); }

.kk-section-head { text-align: center; margin-bottom: 2.2rem; }
.kk-section-head__sub { color: var(--kk-gold-2); font-weight: 600; font-size: .85rem; }
.kk-section-head__title { font-size: clamp(1.4rem, 2.6vw, 2rem); margin: .25rem 0 .5rem; }
.kk-section-head__divider { display: flex; align-items: center; justify-content: center; gap: .8rem; color: var(--kk-gold); }
.kk-section-head__divider i { display: block; width: 56px; height: 1.5px; background: linear-gradient(to left, transparent, var(--kk-gold)); }
.kk-section-head__divider i:last-child { background: linear-gradient(to right, transparent, var(--kk-gold)); }

.kk-section-more { text-align: center; margin-top: 2.1rem; }

/* ---------- Grids ---------- */
.kk-grid { display: grid; gap: 1.6rem; }
.kk-grid--2 { grid-template-columns: repeat(2, 1fr); }
.kk-grid--3 { grid-template-columns: repeat(3, 1fr); }
.kk-grid--4 { grid-template-columns: repeat(4, 1fr); }

/* ---------- Post card ---------- */
.kk-card {
	background: #fff;
	border: 1px solid var(--kk-line);
	border-radius: var(--kk-radius);
	overflow: hidden;
	display: flex;
	flex-direction: column;
	transition: transform .3s ease, box-shadow .3s ease;
}
.kk-card:hover { transform: translateY(-6px); box-shadow: 0 16px 40px rgba(14, 59, 44, .12); }

.kk-card__media { display: block; aspect-ratio: 16 / 10; overflow: hidden; background: var(--kk-beige); }
.kk-card__media img { width: 100%; height: 100%; object-fit: cover; transition: transform .5s ease; }
.kk-card:hover .kk-card__media img { transform: scale(1.06); }
.kk-card__placeholder {
	display: flex;
	align-items: center;
	justify-content: center;
	width: 100%; height: 100%;
	color: var(--kk-gold);
	background-color: var(--kk-beige);
	background-image: var(--kk-pattern);
}

.kk-card__body { padding: 1.15rem 1.3rem 1.25rem; display: flex; flex-direction: column; gap: .5rem; flex: 1; }
.kk-card__title { font-size: 1.07rem; margin: 0; line-height: 1.65; }
.kk-card__title a { color: var(--kk-ink); }
.kk-card__title a:hover { color: var(--kk-primary); }
.kk-card__excerpt {
	color: var(--kk-gray);
	font-size: .92rem;
	margin: 0;
	display: -webkit-box;
	-webkit-line-clamp: 2;
	-webkit-box-orient: vertical;
	overflow: hidden;
}
.kk-card__foot {
	margin-top: auto;
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: .8rem;
	border-top: 1px dashed var(--kk-line);
	padding-top: .8rem;
}
.kk-card__date { display: inline-flex; align-items: center; gap: .35rem; color: var(--kk-gray); font-size: .8rem; }
.kk-card__more { display: inline-flex; align-items: center; gap: .4rem; color: var(--kk-gold-2); font-weight: 600; font-size: .86rem; }
.kk-card__more svg { transition: transform .25s ease; }
.kk-card__more:hover svg { transform: translateX(-4px); }

/* ---------- Books ---------- */
.kk-book {
	background: #fff;
	border: 1px solid var(--kk-line);
	border-radius: var(--kk-radius);
	overflow: hidden;
	display: flex;
	flex-direction: column;
	text-align: center;
	transition: transform .3s ease, box-shadow .3s ease;
}
.kk-book:hover { transform: translateY(-6px); box-shadow: 0 16px 40px rgba(14, 59, 44, .13); }

.kk-book__cover { display: block; aspect-ratio: 3 / 4; overflow: hidden; background: var(--kk-beige); }
.kk-book__cover img { width: 100%; height: 100%; object-fit: cover; transition: transform .5s ease; }
.kk-book:hover .kk-book__cover img { transform: scale(1.05); }

.kk-book__placeholder {
	height: 100%;
	display: flex;
	flex-direction: column;
	align-items: center;
	justify-content: center;
	gap: .9rem;
	padding: 1.2rem;
	color: #e7d9ae;
	background: linear-gradient(160deg, var(--kk-primary), var(--kk-primary-2));
}
.kk-book__placeholder-title { font-size: .92rem; font-weight: 600; line-height: 1.8; }

.kk-book__body { padding: 1rem 1rem 1.2rem; display: flex; flex-direction: column; gap: .5rem; flex: 1; }
.kk-book__title { font-size: .98rem; margin: 0; }
.kk-book__title a { color: var(--kk-ink); }
.kk-book__title a:hover { color: var(--kk-primary); }
.kk-book__excerpt { color: var(--kk-gray); font-size: .84rem; margin: 0; }
.kk-book__btn {
	margin-top: auto;
	align-self: center;
	display: inline-flex;
	align-items: center;
	gap: .4rem;
	color: var(--kk-gold-2);
	border: 1.5px solid rgba(198, 162, 75, .5);
	border-radius: 999px;
	padding: .38rem 1.1rem;
	font-size: .84rem;
	font-weight: 600;
	transition: .25s ease;
}
.kk-book__btn:hover { background: var(--kk-gold); border-color: var(--kk-gold); color: #fff; }

/* ---------- Category cards ---------- */
.kk-cat-card {
	background: #fff;
	border: 1px solid var(--kk-line);
	border-radius: var(--kk-radius);
	padding: 1.6rem 1.3rem;
	display: flex;
	flex-direction: column;
	align-items: center;
	text-align: center;
	gap: .55rem;
	color: var(--kk-ink);
	transition: transform .3s ease, box-shadow .3s ease, border-color .3s ease;
}
.kk-cat-card:hover { transform: translateY(-5px); box-shadow: 0 14px 36px rgba(14, 59, 44, .12); border-color: rgba(198, 162, 75, .55); color: var(--kk-ink); }
.kk-cat-card__icon {
	width: 60px; height: 60px;
	border-radius: 16px;
	display: flex;
	align-items: center;
	justify-content: center;
	background: rgba(198, 162, 75, .12);
	color: var(--kk-gold-2);
	transition: .3s ease;
}
.kk-cat-card:hover .kk-cat-card__icon { background: var(--kk-gold); color: #fff; }
.kk-cat-card__name { font-weight: 700; color: var(--kk-primary); font-size: 1.04rem; }
.kk-cat-card__desc { font-size: .84rem; color: var(--kk-gray); }
.kk-cat-card__count {
	font-size: .76rem;
	color: var(--kk-gold-2);
	background: rgba(198, 162, 75, .12);
	border-radius: 999px;
	padding: .12rem .8rem;
	font-weight: 600;
}

/* ---------- Video section & card ---------- */
.kk-video-sec__grid { display: grid; grid-template-columns: 1fr 1.15fr; gap: 2.6rem; align-items: center; }
.kk-video-sec__title { font-size: clamp(1.4rem, 2.4vw, 1.9rem); }
.kk-video-sec__desc { color: var(--kk-gray); margin: 0; }

.kk-video-card { margin: 0; }
.kk-video-card__media {
	position: relative;
	display: block;
	width: 100%;
	border: 0;
	padding: 0;
	cursor: pointer;
	border-radius: var(--kk-radius);
	overflow: hidden;
	aspect-ratio: 16 / 9;
	background: #000;
}
.kk-video-card__media img { width: 100%; height: 100%; object-fit: cover; opacity: .94; transition: transform .5s ease; }
.kk-video-card__media:hover img { transform: scale(1.04); }
.kk-video-card__play {
	position: absolute;
	left: 50%; top: 50%;
	transform: translate(-50%, -50%);
	width: 76px; height: 76px;
	border-radius: 50%;
	background: var(--kk-gold);
	color: #fff;
	display: flex;
	align-items: center;
	justify-content: center;
	box-shadow: 0 10px 34px rgba(0, 0, 0, .4);
	transition: transform .3s ease, background .3s ease;
}
.kk-video-card__play::after {
	content: "";
	position: absolute;
	inset: -9px;
	border-radius: 50%;
	border: 2px solid rgba(198, 162, 75, .55);
	animation: kkPulse 2s ease-out infinite;
}
@keyframes kkPulse {
	0% { transform: scale(.85); opacity: 1; }
	100% { transform: scale(1.3); opacity: 0; }
}
.kk-video-card__media:hover .kk-video-card__play { transform: translate(-50%, -50%) scale(1.1); background: var(--kk-gold-2); }
.kk-video-card__caption { padding: .8rem .4rem 0; font-size: .9rem; color: var(--kk-gray); text-align: center; }

/* ---------- Lightbox ---------- */
.kk-lightbox {
	position: fixed;
	inset: 0;
	z-index: 1000;
	background: rgba(6, 20, 15, .93);
	display: flex;
	align-items: center;
	justify-content: center;
	padding: 1.5rem;
	opacity: 0;
	transition: opacity .3s ease;
}
.kk-lightbox.is-open { opacity: 1; }
.kk-lightbox__frame {
	width: min(960px, 100%);
	aspect-ratio: 16 / 9;
	background: #000;
	border-radius: 12px;
	overflow: hidden;
	box-shadow: 0 30px 90px rgba(0, 0, 0, .55);
	transform: scale(.94);
	transition: transform .3s ease;
}
.kk-lightbox.is-open .kk-lightbox__frame { transform: scale(1); }
.kk-lightbox__frame iframe { width: 100%; height: 100%; border: 0; }
.kk-lightbox__close {
	position: absolute;
	top: 1.1rem;
	inset-inline-end: 1.1rem;
	width: 46px; height: 46px;
	border-radius: 50%;
	background: rgba(255, 255, 255, .12);
	border: 1px solid rgba(255, 255, 255, .3);
	color: #fff;
	cursor: pointer;
	display: flex;
	align-items: center;
	justify-content: center;
	transition: .25s ease;
}
.kk-lightbox__close:hover { background: var(--kk-gold); border-color: var(--kk-gold); }
body.kk-no-scroll { overflow: hidden; }

/* ---------- Page head & breadcrumbs ---------- */
.kk-pagehead {
	background: var(--kk-beige);
	background-image: var(--kk-pattern);
	border-bottom: 1px solid var(--kk-line);
	padding: 2.1rem 0 1.9rem;
	margin-bottom: 2.2rem;
}
.kk-pagehead__title { font-size: clamp(1.4rem, 2.8vw, 2rem); margin: .35rem 0 0; }
.kk-pagehead__query { color: var(--kk-gold-2); }
.kk-pagehead__desc { color: var(--kk-gray); margin: .5rem 0 0; max-width: 720px; font-size: .95rem; }
.kk-pagehead--single .kk-pagehead__title { max-width: 920px; }

.kk-breadcrumbs ol {
	list-style: none;
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: .45rem;
	margin: 0 0 .35rem;
	padding: 0;
	font-size: .83rem;
	color: var(--kk-gray);
}
.kk-breadcrumbs li { display: inline-flex; align-items: center; gap: .45rem; }
.kk-breadcrumbs a { color: var(--kk-gray); }
.kk-breadcrumbs a:hover { color: var(--kk-gold-2); }
.kk-breadcrumbs__sep { display: inline-flex; color: var(--kk-gold); opacity: .85; }
.kk-breadcrumbs [aria-current] { color: var(--kk-primary); font-weight: 600; }

/* ---------- Layout ---------- */
.kk-layout { display: grid; grid-template-columns: minmax(0, 1fr) 320px; gap: 2.5rem; padding-bottom: 3.5rem; }
.kk-content { min-width: 0; }
.kk-content--full { padding-bottom: 3.5rem; }

/* ---------- Meta ---------- */
.kk-meta { display: flex; flex-wrap: wrap; gap: 1.1rem; margin-top: .9rem; color: var(--kk-gray); font-size: .84rem; }
.kk-meta__item { display: inline-flex; align-items: center; gap: .4rem; }
.kk-meta a { color: var(--kk-gray); }
.kk-meta a:hover { color: var(--kk-gold-2); }

/* ---------- Article ---------- */
.kk-article {
	background: #fff;
	border: 1px solid var(--kk-line);
	border-radius: var(--kk-radius);
	padding: 1.8rem;
	box-shadow: 0 4px 22px rgba(14, 59, 44, .05);
}
.kk-article__media { margin: 0 0 1.5rem; border-radius: 12px; overflow: hidden; }

.kk-entry-content { font-size: 1.05rem; line-height: 2.05; color: #2c3833; }
.kk-entry-content > p:first-of-type { font-size: 1.12rem; }
.kk-entry-content h2 { font-size: 1.42rem; margin-top: 1.7em; position: relative; padding-inline-start: .9rem; }
.kk-entry-content h2::before {
	content: "";
	position: absolute;
	inset-inline-start: 0;
	top: .32em; bottom: .32em;
	width: 4px;
	border-radius: 4px;
	background: var(--kk-gold);
}
.kk-entry-content h3 { font-size: 1.18rem; margin-top: 1.5em; }
.kk-entry-content h4 { font-size: 1.05rem; margin-top: 1.4em; }
.kk-entry-content a { color: var(--kk-gold-2); text-decoration: underline; text-underline-offset: 4px; }
.kk-entry-content img { border-radius: 10px; }
.kk-entry-content ul, .kk-entry-content ol { padding-inline-start: 1.4rem; }
.kk-entry-content blockquote,
.kk-entry-content .wp-block-quote {
	margin: 1.6em 0;
	padding: 1.2rem 1.5rem;
	background: var(--kk-beige);
	border-inline-start: 4px solid var(--kk-gold);
	border-radius: 8px;
	font-weight: 500;
}
.kk-entry-content table { width: 100%; border-collapse: collapse; margin: 1.4em 0; font-size: .95rem; }
.kk-entry-content th, .kk-entry-content td { border: 1px solid var(--kk-line); padding: .6rem .8rem; }
.kk-entry-content th { background: var(--kk-beige); color: var(--kk-primary); }
.kk-entry-content .aligncenter { margin-inline: auto; text-align: center; }
.kk-entry-content figcaption { font-size: .82rem; color: var(--kk-gray); text-align: center; margin-top: .4rem; }

/* ---------- Tags / share / post-nav / related ---------- */
.kk-tags { display: flex; flex-wrap: wrap; align-items: center; gap: .5rem; margin-top: 1.8rem; padding-top: 1.2rem; border-top: 1px solid var(--kk-line); color: var(--kk-gold-2); }
.kk-tags__item {
	background: var(--kk-beige);
	border: 1px solid var(--kk-line);
	color: var(--kk-gray);
	padding: .22rem .9rem;
	border-radius: 999px;
	font-size: .8rem;
	transition: .2s ease;
}
.kk-tags__item:hover { border-color: var(--kk-gold); color: var(--kk-gold-2); }

.kk-share { display: flex; flex-wrap: wrap; align-items: center; gap: .55rem; margin-top: 1.2rem; padding: 1rem 0; border-top: 1px solid var(--kk-line); border-bottom: 1px solid var(--kk-line); }
.kk-share__label { display: inline-flex; align-items: center; gap: .4rem; font-weight: 600; color: var(--kk-primary); font-size: .9rem; }
.kk-share__btn {
	width: 40px; height: 40px;
	border-radius: 50%;
	border: 1px solid var(--kk-line);
	background: #fff;
	color: var(--kk-gray);
	display: inline-flex;
	align-items: center;
	justify-content: center;
	cursor: pointer;
	transition: .25s ease;
}
.kk-share__btn:hover,
.kk-share__btn.is-copied { background: var(--kk-primary); color: #fff; border-color: var(--kk-primary); }

.kk-postnav { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; margin-top: 1.8rem; }
.kk-postnav__link {
	display: flex;
	flex-direction: column;
	gap: .3rem;
	background: var(--kk-beige);
	border: 1px solid var(--kk-line);
	border-radius: 12px;
	padding: 1rem 1.2rem;
	transition: .25s ease;
}
.kk-postnav__link:hover { border-color: rgba(198, 162, 75, .6); transform: translateY(-3px); }
.kk-postnav__link--next { text-align: end; align-items: flex-end; }
.kk-postnav__label { display: inline-flex; align-items: center; gap: .3rem; color: var(--kk-gold-2); font-size: .78rem; font-weight: 600; }
.kk-postnav__title {
	color: var(--kk-primary);
	font-weight: 600;
	font-size: .94rem;
	line-height: 1.7;
	display: -webkit-box;
	-webkit-line-clamp: 2;
	-webkit-box-orient: vertical;
	overflow: hidden;
}

.kk-related { margin-top: 2.6rem; }
.kk-related__title { font-size: 1.3rem; margin-bottom: 1.2rem; display: flex; align-items: center; gap: .65rem; }
.kk-related__title::before { content: ""; width: 5px; height: 22px; border-radius: 5px; background: var(--kk-gold); }

/* ---------- Sidebar & widgets ---------- */
.kk-sidebar { display: flex; flex-direction: column; gap: 1.6rem; }
.kk-widget { background: #fff; border: 1px solid var(--kk-line); border-radius: var(--kk-radius); padding: 1.25rem 1.3rem 1.35rem; }
.kk-widget__title { font-size: 1.04rem; margin: 0 0 1rem; display: flex; align-items: center; gap: .6rem; }
.kk-widget__title::before { content: ""; width: 4px; height: 18px; border-radius: 4px; background: var(--kk-gold); }
.kk-widget ul { list-style: none; margin: 0; padding: 0; }
.kk-widget li { padding: .45rem 0; border-bottom: 1px dashed var(--kk-line); }
.kk-widget li:last-child { border-bottom: 0; }
.kk-widget a { color: var(--kk-ink); }
.kk-widget a:hover { color: var(--kk-primary); }
.kk-widget .kk-search-form { flex-direction: column; }
.kk-widget .kk-search-form__btn { justify-content: center; }

.kk-posts-list__item { display: flex; gap: .8rem; align-items: center; }
.kk-posts-list__thumb { flex: 0 0 64px; width: 64px; height: 64px; border-radius: 10px; overflow: hidden; background: var(--kk-beige); }
.kk-posts-list__thumb img { width: 100%; height: 100%; object-fit: cover; }
.kk-posts-list__body { min-width: 0; }
.kk-posts-list__title {
	font-weight: 600;
	font-size: .92rem;
	line-height: 1.7;
	display: -webkit-box;
	-webkit-line-clamp: 2;
	-webkit-box-orient: vertical;
	overflow: hidden;
}
.kk-posts-list__date { display: inline-flex; align-items: center; gap: .3rem; color: var(--kk-gray); font-size: .75rem; }

.kk-popular-list { margin: 0; padding: 0; list-style: none; }
.kk-popular-list__item { display: flex; gap: .8rem; align-items: flex-start; padding: .6rem 0; border-bottom: 1px dashed var(--kk-line); }
.kk-popular-list__item:last-child { border-bottom: 0; }
.kk-popular-list__rank {
	flex: 0 0 34px;
	height: 34px;
	border-radius: 10px;
	background: rgba(198, 162, 75, .12);
	color: var(--kk-gold-2);
	font-weight: 700;
	display: flex;
	align-items: center;
	justify-content: center;
}
.kk-popular-list__item:first-child .kk-popular-list__rank { background: var(--kk-gold); color: #fff; }
.kk-popular-list__title { font-weight: 600; font-size: .9rem; line-height: 1.7; display: block; }
.kk-popular-list__views { display: inline-flex; align-items: center; gap: .3rem; font-size: .75rem; color: var(--kk-gray); }

.kk-cats-list li { padding: 0; border: 0; }
.kk-cats-list a { display: flex; align-items: center; gap: .6rem; padding: .5rem .2rem; }
.kk-cats-list svg { color: var(--kk-gold-2); }
.kk-cats-list em {
	margin-inline-start: auto;
	font-style: normal;
	background: var(--kk-beige);
	border-radius: 999px;
	padding: .05rem .7rem;
	font-size: .76rem;
	color: var(--kk-gold-2);
	font-weight: 600;
}

.kk-widget .tagcloud, .kk-widget .wp-block-tag-cloud { display: flex; flex-wrap: wrap; gap: .4rem; }
.kk-widget .tag-cloud-link {
	display: inline-block;
	background: var(--kk-beige);
	border: 1px solid var(--kk-line);
	border-radius: 999px;
	padding: .18rem .8rem;
	font-size: .78rem !important;
	color: var(--kk-gray);
	transition: .2s ease;
}
.kk-widget .tag-cloud-link:hover { border-color: var(--kk-gold); color: var(--kk-gold-2); }

/* ---------- Single book ---------- */
.kk-single-book-wrap { padding-bottom: 3.5rem; }
.kk-book-single { background: #fff; border: 1px solid var(--kk-line); border-radius: var(--kk-radius); padding: 1.8rem; }
.kk-book-single__grid { display: grid; grid-template-columns: 280px 1fr; gap: 2rem; align-items: start; }
.kk-book-single__cover { margin: 0; border-radius: 12px; overflow: hidden; box-shadow: 0 14px 34px rgba(14, 59, 44, .16); aspect-ratio: 3 / 4; }
.kk-book-single__cover img { width: 100%; height: 100%; object-fit: cover; }
.kk-book__placeholder--single { height: 100%; }
.kk-book-single__terms { display: flex; flex-wrap: wrap; gap: .4rem; margin-bottom: 1rem; }

/* ---------- Pagination ---------- */
.pagination .nav-links { display: flex; flex-wrap: wrap; gap: .4rem; justify-content: center; margin: 2.4rem 0 .4rem; }
.page-numbers {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	min-width: 42px;
	height: 42px;
	padding: 0 .9rem;
	border-radius: 10px;
	border: 1px solid var(--kk-line);
	background: #fff;
	color: var(--kk-ink);
	font-weight: 600;
	font-size: .92rem;
	transition: .2s ease;
}
.page-numbers.current { background: var(--kk-primary); color: #fff; border-color: var(--kk-primary); }
.page-numbers:hover:not(.current):not(.dots) { border-color: var(--kk-gold); color: var(--kk-gold-2); }
.page-numbers.dots { border: 0; background: none; }

/* ---------- Comments ---------- */
.kk-comments { margin-top: 2.6rem; }
.kk-comments__title { font-size: 1.25rem; margin-bottom: 1.2rem; }
.kk-commentlist { list-style: none; margin: 0; padding: 0; display: grid; gap: 1rem; }
.kk-commentlist .children {
	list-style: none;
	margin: 1rem 0 0;
	padding-inline-start: 1.2rem;
	border-inline-start: 2px solid var(--kk-line);
	display: grid;
	gap: 1rem;
}
.kk-comment__body { background: #fff; border: 1px solid var(--kk-line); border-radius: 14px; padding: 1.1rem 1.2rem; }
.bypostauthor > .kk-comment__body { border-color: rgba(198, 162, 75, .55); background: #fffdf6; }
.kk-comment__meta { display: flex; align-items: center; gap: .8rem; margin-bottom: .7rem; }
.kk-comment__avatar { border-radius: 50%; }
.kk-comment__who { flex: 1; min-width: 0; }
.kk-comment__author { font-style: normal; font-weight: 700; color: var(--kk-primary); display: block; font-size: .95rem; }
.kk-comment__date { font-size: .76rem; color: var(--kk-gray); }
.kk-comment__reply .comment-reply-link {
	font-size: .78rem;
	color: var(--kk-gold-2);
	border: 1px solid rgba(198, 162, 75, .4);
	border-radius: 999px;
	padding: .18rem .9rem;
	transition: .2s ease;
}
.kk-comment__reply .comment-reply-link:hover { background: var(--kk-gold); color: #fff; border-color: var(--kk-gold); }
.kk-comment__content p { margin: 0 0 .5rem; font-size: .94rem; }
.kk-comment__pending { color: var(--kk-gold-2); font-size: .84rem; }
.kk-comments__closed { color: var(--kk-gray); }

.comment-respond { margin-top: 2rem; background: #fff; border: 1px solid var(--kk-line); border-radius: var(--kk-radius); padding: 1.5rem; }
.comment-reply-title { font-size: 1.15rem; color: var(--kk-primary); font-weight: 700; margin-bottom: 1rem; }
.comment-form label { display: block; font-size: .86rem; font-weight: 600; margin-bottom: .3rem; color: var(--kk-primary); }
.comment-form input[type="text"],
.comment-form input[type="email"],
.comment-form input[type="url"],
.comment-form textarea {
	width: 100%;
	padding: .7rem 1rem;
	border: 1.5px solid var(--kk-line);
	border-radius: 10px;
	font: inherit;
	background: #fff;
	color: var(--kk-ink);
	transition: border-color .2s ease, box-shadow .2s ease;
}
.comment-form input:focus,
.comment-form textarea:focus { outline: none; border-color: var(--kk-gold); box-shadow: 0 0 0 4px rgba(198, 162, 75, .15); }
.comment-form-cookies-consent label { display: inline; font-weight: 400; color: var(--kk-gray); }
.comment-form .form-submit { margin-bottom: 0; }
.comment-notes, .logged-in-as { font-size: .85rem; color: var(--kk-gray); }

/* ---------- Empty states ---------- */
.kk-404, .kk-none {
	text-align: center;
	padding: 4rem 1rem;
	display: flex;
	flex-direction: column;
	align-items: center;
	gap: 1rem;
}
.kk-404__code { font-size: 5rem; font-weight: 800; color: var(--kk-gold); line-height: 1; }
.kk-404__title, .kk-none__title { font-size: 1.5rem; margin: 0; }
.kk-404__text, .kk-none__text { color: var(--kk-gray); margin: 0; max-width: 460px; }
.kk-404 .kk-search-form, .kk-none .kk-search-form { max-width: 480px; width: 100%; }
.kk-none__icon { color: var(--kk-gold); }

/* ---------- Footer ---------- */
.kk-footer { background-color: var(--kk-primary); background-image: var(--kk-pattern); color: rgba(255, 255, 255, .8); }
.kk-footer__grid {
	display: grid;
	grid-template-columns: 1.3fr 1fr 1.15fr 1fr;
	gap: 2.4rem;
	padding: 3.1rem 0 2.2rem;
}
.kk-footer__brand { display: flex; align-items: center; gap: .7rem; margin-bottom: .9rem; }
.kk-footer__logo img { max-height: 48px; width: auto; }
.kk-footer__name { font-size: 1.12rem; font-weight: 700; color: #fff; }
.kk-footer__about { font-size: .9rem; line-height: 1.95; margin: 0; }

.kk-social { display: flex; gap: .5rem; list-style: none; margin: 1.1rem 0 0; padding: 0; }
.kk-social a {
	width: 38px; height: 38px;
	border-radius: 10px;
	background: rgba(255, 255, 255, .08);
	border: 1px solid rgba(255, 255, 255, .15);
	color: #e6d9b8;
	display: flex;
	align-items: center;
	justify-content: center;
	transition: .25s ease;
}
.kk-social a:hover { background: var(--kk-gold); color: #fff; border-color: var(--kk-gold); }

.kk-footer-widget__title { color: #fff; font-size: 1.04rem; margin: 0 0 1.1rem; display: flex; align-items: center; gap: .6rem; }
.kk-footer-widget__title::before { content: ""; width: 4px; height: 18px; border-radius: 4px; background: var(--kk-gold); }

.kk-footer-menu { list-style: none; margin: 0; padding: 0; }
.kk-footer-menu li { border-bottom: 1px dashed rgba(255, 255, 255, .13); }
.kk-footer-menu li:last-child { border-bottom: 0; }
.kk-footer-menu a { display: block; padding: .48rem 0; color: rgba(255, 255, 255, .8); font-size: .92rem; transition: .2s ease; }
.kk-footer-menu a:hover { color: var(--kk-gold); padding-inline-start: .4rem; }

.kk-footer-cats { list-style: none; margin: 0; padding: 0; }
.kk-footer-cats a { display: flex; align-items: center; gap: .5rem; color: rgba(255, 255, 255, .8); padding: .4rem 0; font-size: .92rem; }
.kk-footer-cats svg { color: var(--kk-gold); }
.kk-footer-cats a:hover { color: var(--kk-gold); }

.kk-footer .kk-posts-list__item { border-color: rgba(255, 255, 255, .13); }
.kk-footer .kk-posts-list__title { color: rgba(255, 255, 255, .92); }
.kk-footer .kk-posts-list__title:hover { color: var(--kk-gold); }
.kk-footer .kk-posts-list__date { color: rgba(255, 255, 255, .5); }

.kk-footer__bar { border-top: 1px solid rgba(255, 255, 255, .12); background: rgba(0, 0, 0, .16); padding: 1.05rem 0; }
.kk-footer__copy { margin: 0; text-align: center; font-size: .84rem; color: rgba(255, 255, 255, .62); }

/* ---------- Reading progress ---------- */
.kk-progress {
	position: fixed;
	top: 0;
	inset-inline-start: 0;
	height: 3px;
	width: 0;
	background: var(--kk-gold);
	z-index: 400;
	transition: width .1s linear;
}

/* ---------- Responsive ---------- */
@media (max-width: 1100px) {
	.kk-grid--4 { grid-template-columns: repeat(2, 1fr); }
	.kk-grid--3 { grid-template-columns: repeat(2, 1fr); }
	.kk-footer__grid { grid-template-columns: repeat(2, 1fr); }
	.kk-video-sec__grid { grid-template-columns: 1fr; gap: 1.6rem; }
}

@media (max-width: 1024px) {
	.kk-nav-toggle { display: inline-flex; }
	.kk-nav {
		display: none;
		position: absolute;
		top: 100%;
		inset-inline: 0;
		background: #fff;
		border-bottom: 1px solid var(--kk-line);
		box-shadow: 0 24px 40px rgba(14, 59, 44, .12);
		max-height: min(70vh, 540px);
		overflow: auto;
		padding: .6rem 1.25rem 1rem;
	}
	.kk-header.nav-open .kk-nav { display: block; }
	.kk-menu { flex-direction: column; align-items: stretch; gap: 0; }
	.kk-menu li { border-bottom: 1px dashed var(--kk-line); }
	.kk-menu li:last-child { border-bottom: 0; }
	.kk-menu a { padding: .8rem .4rem; border-radius: 0; }
	.kk-menu .menu-item-has-children > a::after { display: none; }
	.kk-menu .sub-menu {
		position: static;
		display: none;
		opacity: 1;
		visibility: visible;
		transform: none;
		box-shadow: none;
		border: 0;
		border-inline-start: 2px solid var(--kk-line);
		border-radius: 0;
		margin: 0 1rem .6rem 0;
		padding: 0 .6rem;
		min-width: 0;
	}
	.kk-menu li.kk-sub-open > .sub-menu { display: block; }
	.kk-submenu-toggle {
		display: inline-flex;
		align-items: center;
		justify-content: center;
		position: absolute;
		top: 5px;
		inset-inline-end: 0;
		width: 40px; height: 40px;
		background: none;
		border: 0;
		color: var(--kk-gray);
		cursor: pointer;
	}
	.kk-submenu-toggle svg { transition: transform .25s ease; }
	.kk-sub-open > .kk-submenu-toggle svg { transform: rotate(180deg); }

	.kk-layout { grid-template-columns: 1fr; }
	.kk-sidebar { margin-top: 1rem; }
}

@media (max-width: 680px) {
	body { font-size: 16px; }
	.kk-grid--2, .kk-grid--3 { grid-template-columns: 1fr; }
	.kk-grid--4 { grid-template-columns: repeat(2, 1fr); gap: 1rem; }
	.kk-hero { height: clamp(400px, 58vh, 520px); }
	.kk-hero__content { padding-bottom: 5.4rem; }
	.kk-hero__excerpt { -webkit-line-clamp: 3; }
	.kk-brand__tagline { display: none; }
	.kk-search-form { flex-direction: column; }
	.kk-search-form__btn { justify-content: center; }
	.kk-article { padding: 1.15rem; }
	.kk-postnav { grid-template-columns: 1fr; }
	.kk-postnav__link--next { text-align: start; align-items: flex-start; }
	.kk-book-single__grid { grid-template-columns: 1fr; }
	.kk-book-single__cover { max-width: 250px; margin-inline: auto; }
	.kk-footer__grid { grid-template-columns: 1fr; gap: 2rem; padding: 2.4rem 0 1.8rem; }
	.kk-share { justify-content: center; }
}

/* ---------- Reduced motion ---------- */
@media (prefers-reduced-motion: reduce) {
	*, *::before, *::after {
		animation-duration: .01ms !important;
		animation-iteration-count: 1 !important;
		transition-duration: .01ms !important;
		scroll-behavior: auto !important;
	}
}
