/*
Theme Name: PSC Quiz Hub
Theme URI: https://keralapscquiz.com/
Author: keralapscquiz.com
Description: A clean exam-paper theme for Kerala PSC quiz sites. Ink-blue on cool paper, a thin gold rule borrowed from the Kerala kasavu border, big readable Malayalam, quiz cards with question counts, light and dark modes, and styling that matches the Kerala PSC Quiz plugin.
Version: 1.1.0
Requires at least: 5.8
Tested up to: 6.8
Requires PHP: 7.4
License: GNU General Public License v2 or later
License URI: https://www.gnu.org/licenses/gpl-2.0.html
Text Domain: kpsc-theme
*/

/* ================================================================
   1. Tokens
   ================================================================ */
:root {
	--paper: #f2f5fb;
	--surface: #ffffff;
	--soft: #eaeff9;
	--ink: #0e1a3a;
	--muted: #52607f;
	--line: #d6dded;
	--brand: #1c3fb8;
	--brand-strong: #142f8f;
	--brand-soft: #e6ecfb;
	--on-brand: #ffffff;
	--gold: #b98a2c;
	--ok: #15803d;
	--bad: #b91c1c;
	--wa: #168a4a;
	--shadow: 0 1px 2px rgba(14, 26, 58, .06), 0 10px 28px -12px rgba(14, 26, 58, .18);

	--pill-bg-l: 93%;
	--pill-fg-l: 30%;
	--pill-s: 70%;
	--ph-1: 93%;
	--ph-2: 84%;

	--font: "Anek Malayalam", "Noto Sans Malayalam", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
	--wrap: 1180px;
	--r-card: 10px;
	--r-ctl: 8px;
}

@media (prefers-color-scheme: dark) {
	:root:not([data-theme="light"]) {
		--paper: #0a1226;
		--surface: #111c38;
		--soft: #17254a;
		--ink: #e9eefb;
		--muted: #9fb0d4;
		--line: #243459;
		--brand: #8aa6ff;
		--brand-strong: #aebfff;
		--brand-soft: #182650;
		--on-brand: #0a1226;
		--gold: #d9b35a;
		--ok: #4ade80;
		--bad: #f87171;
		--wa: #34d399;
		--shadow: 0 1px 2px rgba(0, 0, 0, .4), 0 12px 30px -14px rgba(0, 0, 0, .7);
		--pill-bg-l: 22%;
		--pill-fg-l: 82%;
		--pill-s: 55%;
		--ph-1: 24%;
		--ph-2: 17%;
	}
}
:root[data-theme="dark"] {
	--paper: #0a1226;
	--surface: #111c38;
	--soft: #17254a;
	--ink: #e9eefb;
	--muted: #9fb0d4;
	--line: #243459;
	--brand: #8aa6ff;
	--brand-strong: #aebfff;
	--brand-soft: #182650;
	--on-brand: #0a1226;
	--gold: #d9b35a;
	--ok: #4ade80;
	--bad: #f87171;
	--wa: #34d399;
	--shadow: 0 1px 2px rgba(0, 0, 0, .4), 0 12px 30px -14px rgba(0, 0, 0, .7);
	--pill-bg-l: 22%;
	--pill-fg-l: 82%;
	--pill-s: 55%;
	--ph-1: 24%;
	--ph-2: 17%;
}

/* ================================================================
   2. Base
   ================================================================ */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body {
	margin: 0;
	background: var(--paper);
	color: var(--ink);
	font: 400 17px/1.8 var(--font);
	-webkit-font-smoothing: antialiased;
	text-rendering: optimizeLegibility;
}
img, svg, video { max-width: 100%; height: auto; }
a { color: var(--brand); text-underline-offset: .18em; }
a:hover { color: var(--brand-strong); }
h1, h2, h3, h4 { line-height: 1.38; margin: 0 0 .5em; font-weight: 700; color: var(--ink); }
p { margin: 0 0 1.1em; }
:focus-visible { outline: 3px solid var(--brand); outline-offset: 2px; border-radius: 4px; }
.screen-reader-text { position: absolute !important; clip: rect(1px, 1px, 1px, 1px); width: 1px; height: 1px; overflow: hidden; }
.skip-link { position: absolute; left: 12px; top: -60px; background: var(--brand); color: var(--on-brand); padding: 10px 16px; border-radius: var(--r-ctl); z-index: 100; }
.skip-link:focus { top: 12px; }
.muted { color: var(--muted); }
.container { width: min(100% - 32px, var(--wrap)); margin-inline: auto; }
.container--narrow { width: min(100% - 32px, 820px); }
.when-dark { display: none; }
:root[data-theme="dark"] .when-light { display: none; }
:root[data-theme="dark"] .when-dark { display: inline-flex; }
@media (prefers-color-scheme: dark) {
	:root:not([data-theme="light"]) .when-light { display: none; }
	:root:not([data-theme="light"]) .when-dark { display: inline-flex; }
}

/* The kasavu rule: the one decorative device. Two fine gold lines, used under headings only. */
.gold-rule { height: 5px; border-block: 1px solid var(--gold); margin-top: 14px; opacity: .9; }

/* OMR bubbles */
.brand__mark { display: inline-grid; grid-template-columns: repeat(2, 1fr); gap: 3px; width: 34px; padding: 5px; border: 1.5px solid var(--brand); border-radius: 9px; background: var(--surface); flex: none; }
.brand__mark i, .card__ph i { display: block; aspect-ratio: 1; border: 1.5px solid var(--brand); border-radius: 50%; }
.brand__mark i.on, .card__ph i.on { background: var(--brand); }

/* ================================================================
   3. Buttons, pills, chips
   ================================================================ */
.btn {
	display: inline-flex; align-items: center; gap: 8px; cursor: pointer;
	font: 600 15px/1.2 var(--font); padding: 11px 18px; border-radius: var(--r-ctl);
	border: 1.5px solid transparent; text-decoration: none; transition: background-color .15s, border-color .15s;
}
.btn--primary { background: var(--brand); color: var(--on-brand); }
.btn--primary:hover { background: var(--brand-strong); color: var(--on-brand); }
.btn--ghost { background: transparent; color: var(--ink); border-color: var(--line); }
.btn--ghost:hover { border-color: var(--brand); color: var(--brand); }
.btn--wa { background: var(--wa); color: #fff; }
.btn--wa:hover { filter: brightness(1.08); color: #fff; }
.icon { flex: none; }

.pill {
	display: inline-flex; align-items: center; gap: 6px; text-decoration: none;
	font: 600 13px/1.4 var(--font); padding: 2px 11px; border-radius: 999px;
	background: hsl(var(--h, 222) var(--pill-s) var(--pill-bg-l));
	color: hsl(var(--h, 222) 65% var(--pill-fg-l));
}
a.pill:hover { filter: brightness(.96); color: hsl(var(--h, 222) 65% var(--pill-fg-l)); }
.pill b { font-weight: 700; opacity: .75; }
.chip {
	display: inline-flex; align-items: center; gap: 5px; font: 500 13px/1.4 var(--font);
	color: var(--muted); padding: 2px 9px; border-radius: 6px; background: var(--soft);
}
.chip .icon { width: 14px; height: 14px; }

/* ================================================================
   4. Header
   ================================================================ */
.topbar { background: #0a1330; color: #b6c3e4; font-size: 13px; line-height: 1; }
.topbar__in { display: flex; justify-content: space-between; align-items: center; gap: 12px; min-height: 36px; }
.topbar__wa { color: #fff; text-decoration: none; display: inline-flex; align-items: center; gap: 6px; font-weight: 600; }
.topbar__wa .icon { width: 16px; height: 16px; }
.topbar__wa:hover { color: #9be7bd; }

.site-header { position: sticky; top: 0; z-index: 40; background: var(--surface); border-bottom: 1px solid var(--line); }
.header-main { display: flex; align-items: center; gap: 20px; min-height: 68px; }
.brand { display: flex; align-items: center; gap: 12px; text-decoration: none; color: var(--ink); min-width: 0; }
.brand .custom-logo { max-height: 44px; width: auto; }
.brand__text { display: flex; flex-direction: column; line-height: 1.25; min-width: 0; }
.brand__text strong { font-size: 18px; font-weight: 800; letter-spacing: -.005em; }
.brand__text small { font-size: 12.5px; color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

.site-nav { margin-left: auto; }
.site-nav .menu { list-style: none; margin: 0; padding: 0; display: flex; gap: 2px; }
.site-nav a { display: block; padding: 8px 14px; border-radius: var(--r-ctl); color: var(--ink); text-decoration: none; font-weight: 600; font-size: 15.5px; line-height: 1.5; }
.site-nav a:hover { background: var(--brand-soft); color: var(--brand); }
.site-nav .current-menu-item > a, .site-nav .current-menu-ancestor > a, .site-nav .current_page_item > a { background: var(--brand-soft); color: var(--brand); }
.site-nav li { position: relative; }
.site-nav .sub-menu { list-style: none; margin: 0; padding: 6px; position: absolute; left: 0; top: 100%; min-width: 220px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-card); box-shadow: var(--shadow); display: none; z-index: 5; }
.site-nav li:hover > .sub-menu, .site-nav li:focus-within > .sub-menu { display: block; }

.header-actions { display: flex; gap: 6px; }
.icon-btn { display: inline-flex; align-items: center; justify-content: center; width: 42px; height: 42px; border-radius: var(--r-ctl); border: 1.5px solid var(--line); background: transparent; color: var(--ink); cursor: pointer; }
.icon-btn:hover { border-color: var(--brand); color: var(--brand); }
.when-light, .when-dark { align-items: center; }
.nav-toggle { display: none; }

.search-panel { border-top: 1px solid var(--line); background: var(--surface); padding: 14px 0; }

@media (max-width: 900px) {
	.nav-toggle { display: inline-flex; }
	.site-nav { display: none; position: absolute; left: 0; right: 0; top: 100%; background: var(--surface); border-bottom: 1px solid var(--line); padding: 8px 16px 16px; box-shadow: var(--shadow); }
	.site-nav.is-open { display: block; }
	.site-nav .menu { flex-direction: column; }
	.site-nav .sub-menu { position: static; display: block; border: 0; box-shadow: none; padding: 0 0 0 14px; }
	.header-main { gap: 10px; }
	.header-actions { margin-left: auto; }
	.site-nav { margin-left: 0; }
	.brand__text small { display: none; }
}
@media (max-width: 420px) { .topbar__in > span { display: none; } .topbar__in { justify-content: center; } }

/* ================================================================
   5. Search form
   ================================================================ */
.searchform { display: flex; gap: 8px; max-width: 640px; }
.searchform input[type="search"] {
	flex: 1; min-width: 0; font: 500 16px/1.4 var(--font); color: var(--ink);
	padding: 13px 16px; border: 1.5px solid var(--line); border-radius: var(--r-ctl); background: var(--surface);
}
.searchform input[type="search"]::placeholder { color: var(--muted); }
.searchform input[type="search"]:focus { outline: 0; border-color: var(--brand); box-shadow: 0 0 0 3px var(--brand-soft); }
.searchform button { font: 700 15px/1 var(--font); padding: 0 22px; border: 0; border-radius: var(--r-ctl); background: var(--brand); color: var(--on-brand); cursor: pointer; }
.searchform button:hover { background: var(--brand-strong); }

/* ================================================================
   6. Home hero
   ================================================================ */
.hero { padding: 48px 0 8px; background:
	linear-gradient(180deg, var(--brand-soft) 0, transparent 70%); }
.hero__grid { display: grid; grid-template-columns: minmax(0, 1.2fr) minmax(0, .8fr); gap: 48px; align-items: center; }
.hero__title { font-size: clamp(30px, 4.6vw, 50px); font-weight: 800; line-height: 1.22; letter-spacing: -.012em; margin-bottom: .45em; max-width: 17em; }
.hero__sub { font-size: 18px; color: var(--muted); max-width: 36em; margin-bottom: 1.5em; line-height: 1.85; }
.hero .searchform { margin-bottom: 18px; }
.hero__cats { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 8px; }
.facts { display: grid; grid-template-columns: repeat(3, 1fr); margin: 40px 0 0; padding: 0; border-top: 1px solid var(--line); }
.facts > div { padding: 16px 20px 16px 0; }
.facts > div + div { padding-left: 24px; border-left: 1px solid var(--line); }
.facts dt { font-size: 24px; font-weight: 800; line-height: 1.3; color: var(--ink); }
.facts dd { margin: 0; font-size: 14.5px; color: var(--muted); line-height: 1.5; }

/* "Try one now" answer sheet */
.omr { background: var(--surface); border: 1px solid var(--line); border-radius: 14px; padding: 22px; box-shadow: var(--shadow); position: relative; }
.omr::before { content: ""; position: absolute; inset: 0 0 auto 0; height: 4px; border-radius: 14px 14px 0 0; background: var(--brand); }
.omr__label { margin: 0 0 6px; font-size: 13.5px; font-weight: 600; color: var(--muted); }
.omr__q { font-size: 20px; font-weight: 700; line-height: 1.5; margin-bottom: 14px; }
.omr__opts { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; }
.omr__opts button {
	width: 100%; display: flex; align-items: center; gap: 12px; text-align: left;
	font: 500 17px/1.4 var(--font); color: var(--ink); background: var(--surface);
	padding: 10px 12px; border: 1.5px solid var(--line); border-radius: var(--r-ctl); cursor: pointer;
	transition: border-color .15s, background-color .15s;
}
.omr__opts button:hover:not(:disabled) { border-color: var(--brand); background: var(--brand-soft); }
.omr__opts button:disabled { cursor: default; color: var(--ink); }
.bub { flex: none; width: 28px; height: 28px; border-radius: 50%; border: 1.5px solid var(--muted); display: inline-flex; align-items: center; justify-content: center; font-size: 13px; font-weight: 700; color: var(--muted); transition: background-color .2s, color .2s, border-color .2s; }
.omr__opts .is-right { border-color: var(--ok); background: color-mix(in srgb, var(--ok) 12%, var(--surface)); }
.omr__opts .is-right .bub { background: var(--ok); border-color: var(--ok); color: #fff; }
.omr__opts .is-wrong { border-color: var(--bad); background: color-mix(in srgb, var(--bad) 10%, var(--surface)); }
.omr__opts .is-wrong .bub { background: var(--bad); border-color: var(--bad); color: #fff; }
.omr__top { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; }
.omr__score { margin: 0 0 6px; font-size: 13.5px; font-weight: 700; color: var(--brand); }
.omr__stage { transition: opacity .16s ease; }
.omr__stage.is-swap { opacity: 0; }
.omr__q { margin-bottom: 4px; }
.omr__src { margin: 0 0 14px; font-size: 14px; line-height: 1.6; color: var(--muted); }
.omr__src a { font-weight: 600; }
.omr__t { min-width: 0; overflow-wrap: anywhere; }
.omr__fb { margin: 14px 0 0; font-size: 15.5px; color: var(--muted); min-height: 3.4em; }
.omr__exp { display: block; margin-top: 4px; font-size: 14.5px; font-weight: 400; color: var(--muted); line-height: 1.7; }
.omr__next { display: flex; align-items: center; gap: 14px; margin-top: 12px; }
.omr__next .btn { padding: 8px 16px; font-size: 14.5px; }
.omr__timer { flex: 1; height: 4px; border-radius: 2px; background: var(--soft); overflow: hidden; }
.omr__timer i { display: block; height: 100%; width: 100%; background: var(--brand); transform-origin: left; }
@keyframes omrTimer { from { transform: scaleX(1); } to { transform: scaleX(0); } }
.omr.is-ok .omr__fb { color: var(--ok); font-weight: 600; }
.omr.is-bad .omr__fb { color: var(--bad); font-weight: 600; }

@media (max-width: 900px) {
	.hero { padding-top: 32px; }
	.hero__grid { grid-template-columns: 1fr; gap: 28px; }
	.facts { grid-template-columns: 1fr; margin-top: 28px; }
	.facts > div, .facts > div + div { padding: 12px 0; border-left: 0; }
	.facts > div + div { border-top: 1px solid var(--line); }
}

/* ================================================================
   7. Sections and grids
   ================================================================ */
.section { padding: 40px 0 8px; }
.section--tight { padding-top: 28px; }
.section__head { margin-bottom: 22px; }
.section__head h2 { font-size: clamp(22px, 2.6vw, 28px); font-weight: 800; margin: 0; }
.section__row { display: flex; align-items: baseline; justify-content: space-between; gap: 16px; flex-wrap: wrap; }
.more { font-weight: 600; font-size: 15px; text-decoration: none; }
.more:hover { text-decoration: underline; }
.empty { padding: 28px; border: 1.5px dashed var(--line); border-radius: var(--r-card); color: var(--muted); text-align: center; }
.banner-strip { margin-top: 28px; }
.banner-strip .widget { background: none; border: 0; padding: 0; margin: 0; }
.banner-strip img { border-radius: var(--r-card); display: block; margin-inline: auto; }

.page-head { padding: 40px 0 6px; background: linear-gradient(180deg, var(--brand-soft) 0, transparent 100%); }
.page-head h1 { font-size: clamp(28px, 4vw, 42px); font-weight: 800; margin: 0 0 .3em; line-height: 1.3; }
.page-head__desc { color: var(--muted); max-width: 44em; }
.page-head__count { color: var(--muted); font-weight: 600; margin: 0; font-size: 15px; }
.search-inline { margin-top: 14px; }

.grid { display: grid; gap: 22px; grid-template-columns: repeat(auto-fill, minmax(290px, 1fr)); }
@media (min-width: 900px) {
	.grid--lead { grid-template-columns: repeat(3, 1fr); }
	.grid--lead > .card--lead { grid-column: span 3; flex-direction: row; }
	.grid--lead > .card--lead .card__media { flex: 0 0 52%; aspect-ratio: auto; min-height: 300px; }
	.grid--lead > .card--lead .card__body { padding: 28px; justify-content: center; }
	.grid--lead > .card--lead .card__title { font-size: 28px; }
}

/* ================================================================
   8. Quiz card
   ================================================================ */
.card {
	display: flex; flex-direction: column; background: var(--surface);
	border: 1px solid var(--line); border-left: 4px solid hsl(var(--h, 222) 62% 46%);
	border-radius: var(--r-card); overflow: hidden; box-shadow: var(--shadow);
}
.card:hover .card__title a { color: var(--brand); }
.card__media { display: block; aspect-ratio: 16 / 9; overflow: hidden; background: var(--soft); position: relative; }
.card__media img { width: 100%; height: 100%; object-fit: cover; display: block; }
.card__ph {
	position: absolute; inset: 0; display: grid; grid-template-columns: repeat(4, 22px); gap: 10px; place-content: center;
	background: linear-gradient(135deg, hsl(var(--h, 222) 70% var(--ph-1)), hsl(var(--h, 222) 62% var(--ph-2)));
}
.card__ph i { width: 22px; border-color: hsl(var(--h, 222) 55% 38% / .55); }
.card__ph i.on { background: hsl(var(--h, 222) 55% 38% / .55); }
.card__body { display: flex; flex-direction: column; gap: 10px; padding: 16px 18px 14px; flex: 1; }
.card__meta { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; }
.card__title { font-size: 19px; font-weight: 700; line-height: 1.5; margin: 0; }
.card__title a { color: var(--ink); text-decoration: none; }
.card__title a::after { content: ""; position: absolute; inset: 0; }
.card { position: relative; }
.card__meta a, .card__foot a { position: relative; z-index: 1; }
.card__excerpt { color: var(--muted); font-size: 15px; line-height: 1.75; margin: 0; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.card--lead .card__excerpt { -webkit-line-clamp: 4; font-size: 16px; }
.card__foot { margin-top: auto; padding-top: 12px; border-top: 1px solid var(--line); display: flex; justify-content: space-between; align-items: center; gap: 12px; font-size: 14px; color: var(--muted); }
.card__cta { font-weight: 700; color: var(--brand); }

/* ================================================================
   9. Single quiz / page
   ================================================================ */
.layout { display: grid; gap: 28px; grid-template-columns: minmax(0, 1fr); padding-top: 28px; }
@media (min-width: 1040px) { .layout { grid-template-columns: minmax(0, 1fr) 320px; } }
.page-wrap { padding-top: 28px; }

.paper { background: var(--surface); border: 1px solid var(--line); border-radius: 14px; padding: clamp(20px, 4vw, 44px); box-shadow: var(--shadow); min-width: 0; }
.paper__head { margin-bottom: 24px; }
.crumbs { display: flex; gap: 8px; align-items: center; font-size: 14.5px; color: var(--muted); margin-bottom: 10px; flex-wrap: wrap; }
.crumbs a { color: var(--muted); text-decoration: none; }
.crumbs a:hover { color: var(--brand); text-decoration: underline; }
.paper__title { font-size: clamp(26px, 4vw, 38px); font-weight: 800; line-height: 1.32; letter-spacing: -.008em; margin-bottom: .5em; }
.paper__meta { display: flex; flex-wrap: wrap; gap: 8px 10px; align-items: center; color: var(--muted); font-size: 14.5px; }
.paper__img { margin: 0 0 24px; }
.paper__img img { width: 100%; border-radius: var(--r-card); display: block; }
.paper__foot { margin-top: 32px; padding-top: 22px; border-top: 1px solid var(--line); }
.share { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
.share__label { font-weight: 600; margin-right: 6px; }
.tags { margin: 16px 0 0; display: flex; flex-wrap: wrap; gap: 6px; }
.tags a { font-size: 13.5px; padding: 2px 10px; border-radius: 6px; background: var(--soft); color: var(--muted); text-decoration: none; }

/* Article typography */
.entry { font-size: 18px; line-height: 1.9; overflow-wrap: anywhere; }
.entry > *:first-child { margin-top: 0; }
.entry h2 { font-size: 26px; margin: 1.6em 0 .5em; }
.entry h3 { font-size: 21px; margin: 1.4em 0 .4em; }
.entry ul, .entry ol { padding-left: 1.4em; margin: 0 0 1.1em; }
.entry li { margin: .3em 0; }
.entry blockquote { margin: 1.4em 0; padding: .4em 0 .4em 1.1em; border-left: 3px solid var(--gold); color: var(--muted); }
.entry img, .entry figure { border-radius: 8px; }
.entry table { width: 100%; border-collapse: collapse; margin: 0 0 1.2em; font-size: 16px; display: block; overflow-x: auto; }
.entry th, .entry td { border: 1px solid var(--line); padding: 8px 12px; text-align: left; }
.entry th { background: var(--soft); }
.entry .alignwide, .entry .alignfull { max-width: 100%; }
.entry iframe { max-width: 100%; }

/* Sidebar widgets */
.sidebar { min-width: 0; }
.widget { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-card); padding: 18px; margin-bottom: 20px; }
.widget-title { font-size: 17px; font-weight: 800; margin: 0 0 12px; padding-bottom: 10px; border-bottom: 1px solid var(--gold); }
.widget img { display: block; margin-inline: auto; border-radius: 8px; }
.widget ul, .plain-list { list-style: none; margin: 0; padding: 0; }
.widget li, .plain-list li { padding: 7px 0; border-bottom: 1px solid var(--line); line-height: 1.6; }
.widget li:last-child, .plain-list li:last-child { border-bottom: 0; }
.widget a, .plain-list a { text-decoration: none; }
.widget a:hover, .plain-list a:hover { text-decoration: underline; }

/* ================================================================
   10. Quiz plugin, restyled to match
   ("body" prefix so these win over the plugin's own stylesheet, which loads later)
   ================================================================ */
body .kpq {
	--kpq-accent: var(--brand);
	--kpq-ok: var(--ok);
	--kpq-no: var(--bad);
	--kpq-bg: var(--surface);
	--kpq-soft: var(--soft);
	--kpq-line: var(--line);
	--kpq-text: var(--ink);
	font-family: var(--font);
	max-width: none;
	margin-block: 1.6em;
	color: var(--ink);
}
body .kpq .kpq-stage { border-radius: 12px; border: 1px solid var(--line); border-top: 4px solid var(--brand); padding: clamp(16px, 3vw, 26px); background: var(--surface); }
body .kpq .kpq-title { font-size: 22px; font-weight: 800; line-height: 1.4; }
body .kpq .kpq-chips li { background: var(--soft); color: var(--ink); }
body .kpq .kpq-btn { font-family: var(--font); font-weight: 600; border-radius: var(--r-ctl); color: var(--ink); background: var(--surface); border-color: var(--line); }
body .kpq .kpq-btn:hover:not(:disabled) { border-color: var(--brand); }
body .kpq .kpq-primary { background: var(--brand); border-color: var(--brand); color: var(--on-brand); }
body .kpq .kpq-wa { background: var(--wa); border-color: var(--wa); color: #fff; }
body .kpq .kpq-opt { border-radius: var(--r-ctl); font-family: var(--font); font-size: 17px; line-height: 1.55; color: var(--ink); background: var(--surface); border-color: var(--line); }
body .kpq .kpq-let { border: 1.5px solid var(--muted); background: transparent; color: var(--muted); }
body .kpq button.kpq-opt:hover:not(:disabled), body .kpq .kpq-sel { background: var(--brand-soft); border-color: var(--brand); }
body .kpq .kpq-sel .kpq-let { background: var(--brand); border-color: var(--brand); color: var(--on-brand); }
body .kpq .kpq-right { background: color-mix(in srgb, var(--ok) 12%, var(--surface)); border-color: var(--ok); }
body .kpq .kpq-right .kpq-let { background: var(--ok); border-color: var(--ok); color: #fff; }
body .kpq .kpq-bad { background: color-mix(in srgb, var(--bad) 10%, var(--surface)); border-color: var(--bad); }
body .kpq .kpq-bad .kpq-let { background: var(--bad); border-color: var(--bad); color: #fff; }
body .kpq .kpq-exp { background: color-mix(in srgb, var(--gold) 12%, var(--surface)); border-left-color: var(--gold); color: var(--ink); }
body .kpq .kpq-pn { color: var(--ink); font-family: var(--font); background: var(--surface); border-color: var(--line); }
body .kpq .kpq-pn.kpq-done { background: var(--brand-soft); border-color: var(--brand); }
body .kpq .kpq-timer, body .kpq .kpq-bar { background: var(--soft); color: var(--ink); }
body .kpq .kpq-bar i { background: var(--brand); }
body .kpq .kpq-c-ok { color: var(--ok); }
body .kpq .kpq-c-no { color: var(--bad); }
body .kpq .kpq-ring.kpq-pass { border-color: var(--ok); }
body .kpq .kpq-ring.kpq-fail { border-color: var(--bad); }
body .kpq .kpq-item { border-color: var(--line); }
body .kpq .kpq-qno { color: var(--brand); }

/* WordPress default widget blocks (search, recent posts, archives ...) */
.widget .wp-block-heading, .widget h2:not(.widget-title) { font-size: 17px; font-weight: 800; margin: 0 0 12px; padding-bottom: 10px; border-bottom: 1px solid var(--gold); }
.widget .wp-block-search__label { display: block; font-size: 17px; font-weight: 800; margin-bottom: 10px; }
.widget .wp-block-search__inside-wrapper { display: flex; gap: 6px; }
.widget input[type="search"], .widget .wp-block-search__input { flex: 1; min-width: 0; font: 500 15px/1.4 var(--font); color: var(--ink); background: var(--surface); padding: 9px 12px; border: 1.5px solid var(--line); border-radius: var(--r-ctl); }
.widget .wp-block-search__button, .widget button[type="submit"] { font: 700 14px/1 var(--font); padding: 0 14px; border: 0; border-radius: var(--r-ctl); background: var(--brand); color: var(--on-brand); cursor: pointer; }
.widget .wp-block-group, .widget .wp-block-latest-posts, .widget .wp-block-categories, .widget .wp-block-archives, .widget .wp-block-latest-comments { margin: 0; padding: 0; list-style: none; }
.widget .wp-block-latest-comments__comment { margin: 0; }
.widget .wp-block-latest-posts__post-date { display: block; font-size: 13px; color: var(--muted); }

/* ================================================================
   11. Pagination, comments, footer
   ================================================================ */
.pagination { margin: 36px 0 12px; }
.pagination .nav-links { display: flex; flex-wrap: wrap; gap: 8px; justify-content: center; }
.page-numbers { padding: 8px 15px; border: 1.5px solid var(--line); border-radius: var(--r-ctl); text-decoration: none; color: var(--ink); font-weight: 600; background: var(--surface); }
a.page-numbers:hover { border-color: var(--brand); color: var(--brand); }
.page-numbers.current { background: var(--brand); border-color: var(--brand); color: var(--on-brand); }
.page-numbers.dots { border-color: transparent; background: none; }

.comments { margin: 28px 0 0; padding: clamp(18px, 3vw, 32px); background: var(--surface); border: 1px solid var(--line); border-radius: 14px; }
.comments__title, .comment-reply-title { font-size: 21px; font-weight: 800; }
.comment-list { list-style: none; padding: 0; margin: 0 0 24px; }
.comment-list .children { list-style: none; padding-left: 20px; }
.comment-body { padding: 14px 0; border-bottom: 1px solid var(--line); }
.comment-author img { border-radius: 50%; vertical-align: middle; margin-right: 8px; }
.comment-metadata { font-size: 13.5px; }
.comment-metadata a { color: var(--muted); }
.comment-form label { display: block; font-weight: 600; margin-bottom: 4px; }
.comment-form input[type="text"], .comment-form input[type="email"], .comment-form input[type="url"], .comment-form textarea {
	width: 100%; font: 400 16px/1.6 var(--font); color: var(--ink); background: var(--paper);
	padding: 10px 14px; border: 1.5px solid var(--line); border-radius: var(--r-ctl);
}
.comment-form textarea:focus, .comment-form input:focus { outline: 0; border-color: var(--brand); }
.comment-form .form-submit .btn { border: 0; }

.site-footer { margin-top: 64px; padding: 8px 0 28px; background: #0a1330; color: #b6c3e4; }
.site-footer a { color: #dbe4ff; text-decoration: none; }
.site-footer a:hover { text-decoration: underline; color: #fff; }
.site-footer .gold-rule { margin: 0 0 34px; border-color: var(--gold); }
.site-footer .widget { background: none; border: 0; padding: 0; margin: 0 0 18px; }
.site-footer .widget-title { color: #fff; border-bottom-color: #3a4a78; }
.site-footer .widget li, .site-footer .plain-list li { border-bottom-color: #22305a; }
.footer-grid { display: grid; gap: 32px; grid-template-columns: 1.3fr 1fr 1fr; }
.footer-col p { line-height: 1.8; margin: 0; }
.footer-bottom { margin-top: 28px; padding-top: 18px; border-top: 1px solid #22305a; display: flex; justify-content: space-between; flex-wrap: wrap; gap: 10px; font-size: 14px; }
.footer-menu { list-style: none; margin: 0; padding: 0; display: flex; gap: 16px; flex-wrap: wrap; }
@media (max-width: 760px) { .footer-grid { grid-template-columns: 1fr; gap: 20px; } }

/* WhatsApp band */
.wa-band { display: flex; align-items: center; justify-content: space-between; gap: 24px; flex-wrap: wrap; padding: clamp(22px, 4vw, 36px); border-radius: 14px; background: #0f5132; color: #eafff3; border-bottom: 4px solid var(--gold); }
.wa-band h2 { color: #fff; font-size: 24px; margin: 0 0 4px; }
.wa-band p { margin: 0; color: #c9f0da; max-width: 36em; }
.wa-band .btn--wa { background: #fff; color: #0f5132; }

/* WordPress core classes */
.alignleft { float: left; margin: 0 1.2em 1em 0; }
.alignright { float: right; margin: 0 0 1em 1.2em; }
.aligncenter { display: block; margin-inline: auto; }
.wp-caption { max-width: 100%; }
.wp-caption-text, figcaption { font-size: 14px; color: var(--muted); }
.sticky .card__title::before { content: "★ "; color: var(--gold); }
.gallery { display: grid; gap: 8px; }

@media (prefers-reduced-motion: reduce) {
	html { scroll-behavior: auto; }
	* { transition: none !important; }
}
@media print {
	.site-header, .site-footer, .sidebar, .share, .comments, .banner-strip { display: none !important; }
	body { background: #fff; color: #000; }
	.paper { border: 0; box-shadow: none; padding: 0; }
}
