/*
 * Learnify Academy – inner page design system (template "page-learnify", September 2026).
 * Same tokens, fonts and buttons as the homepage (home.css). Loaded only on redesigned pages; no Bootstrap or Odoo styles.
 *
 * Components: page hero with breadcrumbs · sections · cards and grids · prose (long text) · facts list · chips ·
 * steps · FAQ · reviews · results lists · form frame (Tally) · contact + map · notice · call-to-action band.
 */

@font-face {
	font-family: "Bricolage Grotesque";
	font-style: normal;
	font-weight: 700 800;
	font-display: swap;
	src: url("../fonts/bricolage-grotesque-latin.woff2") format("woff2");
	unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
	font-family: "Assistant";
	font-style: normal;
	font-weight: 400 700;
	font-display: swap;
	src: url("../fonts/assistant-latin.woff2") format("woff2");
	unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

.lf-pg {
	--ink: #0b1f2a;
	--ink-soft: #3f5561;
	--blue: #2395cb;
	--blue-text: #0f6d9c;
	--blue-button: #1573a6;
	--blue-button-hover: #0f5f8a;
	--night: #072f45;
	--night-text: #c9deea;
	--night-accent: #7cc7ea;
	--ice: #edf7fb;
	--paper: #ffffff;
	--line: #d3e3ea;
	--red: #d23a2e;
	--red-text: #b3261c; /* red for small text on light grounds (6:1 on ice) */
	--star: #e29a12;
	--green: #1e7b3a;
	--radius: 14px;
	--display: "Bricolage Grotesque", "Assistant", system-ui, -apple-system, "Segoe UI", sans-serif;
	--body: "Assistant", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
	font-family: var(--body);
	font-size: 1.0625rem;
	line-height: 1.65;
	color: var(--ink);
	background: var(--paper);
}

/* ---------- Reset block spacing ---------- */
body .lf-pg :where(.wp-block-post-content, .is-layout-flow, .is-layout-constrained, .wp-block-group, .wp-block-details, .wp-block-quote, .wp-block-column) > * {
	margin-block-start: 0;
	margin-block-end: 0;
}
body .lf-pg :where(p, h1, h2, h3, h4, ul, ol, figure, blockquote, details, table) { margin: 0; }
.lf-pg a { color: var(--blue-text); text-underline-offset: 3px; }
.lf-pg a:hover { color: var(--blue-button-hover); }
.lf-pg :focus-visible { outline: 3px solid var(--blue); outline-offset: 3px; }
.lf-pg img { max-width: 100%; height: auto; }

/* ---------- Type ---------- */
.lf-pg h2 {
	font-family: var(--display);
	font-weight: 800;
	font-size: clamp(1.7rem, 3.2vw, 2.4rem);
	line-height: 1.12;
	letter-spacing: -.02em;
	text-wrap: balance;
	color: inherit;
}
.lf-pg h3 {
	font-family: var(--display);
	font-weight: 700;
	font-size: 1.2rem;
	line-height: 1.25;
	letter-spacing: -.01em;
	color: inherit;
}
.lf-pg h4 { font-size: 1.05rem; font-weight: 700; line-height: 1.3; color: inherit; }

/* ---------- Frames ---------- */
.lf-pg-sec { padding: clamp(52px, 7vw, 92px) 20px; }
.lf-pg-sec.is-ice { background: var(--ice); }
.lf-pg-sec.is-dark { background: var(--night); color: #fff; }
.lf-pg-sec.is-tight { padding-block: clamp(36px, 5vw, 56px); }
.lf-pg-in { max-width: 1140px; margin-inline: auto; display: grid; gap: clamp(26px, 3.6vw, 40px); }
.lf-pg-in.is-narrow { max-width: 820px; }
.lf-pg-head { display: grid; gap: 12px; max-width: 760px; }
.lf-pg-head.is-center { margin-inline: auto; text-align: center; justify-items: center; }
.lf-pg-kicker {
	font-size: .8125rem;
	font-weight: 700;
	letter-spacing: .12em;
	text-transform: uppercase;
	color: var(--blue-text);
}
.is-dark .lf-pg-kicker { color: var(--night-accent); }
.lf-pg-head > p:not(.lf-pg-kicker) { font-size: 1.125rem; color: var(--ink-soft); max-width: 64ch; }
.is-dark .lf-pg-head > p:not(.lf-pg-kicker) { color: var(--night-text); }

/* ---------- Buttons ---------- */
.lf-pg .lf-h-actions,
.lf-pg .lf-pg-actions { display: flex; flex-wrap: wrap; gap: 12px; }
.lf-pg .wp-block-button__link {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	padding: 13px 22px;
	border-radius: 10px;
	border: 1.5px solid transparent;
	font-family: var(--body);
	font-size: 1.0625rem;
	font-weight: 700;
	line-height: 1.2;
	text-decoration: none;
	transition: background-color .2s ease, border-color .2s ease, color .2s ease, transform .2s ease;
}
.lf-pg .wp-block-button__link:hover { transform: translateY(-1px); }
.lf-pg .lf-btn-primary .wp-block-button__link { background: var(--blue-button); color: #fff; box-shadow: 0 10px 22px -12px rgba(21, 115, 166, .8); }
.lf-pg .lf-btn-primary .wp-block-button__link:hover { background: var(--blue-button-hover); color: #fff; }
.lf-pg .lf-btn-ghost .wp-block-button__link { background: var(--paper); color: var(--ink); border-color: var(--line); }
.lf-pg .lf-btn-ghost .wp-block-button__link:hover { border-color: var(--blue); color: var(--blue-text); }
.lf-pg .lf-btn-light .wp-block-button__link { background: #fff; color: var(--night); }
.lf-pg .lf-btn-light .wp-block-button__link:hover { background: var(--ice); color: var(--night); }
.lf-pg .lf-btn-outline-light .wp-block-button__link { background: transparent; color: #fff; border-color: rgba(255, 255, 255, .55); }
.lf-pg .lf-btn-outline-light .wp-block-button__link:hover { border-color: #fff; color: #fff; }

/* ---------- Page hero ---------- */
.lf-pg-hero {
	padding: clamp(22px, 3vw, 34px) 20px clamp(44px, 6vw, 76px);
	background: linear-gradient(180deg, var(--ice) 0%, #f6fbfd 70%, var(--paper) 100%);
	border-bottom: 1px solid #e4eef3;
}
.lf-pg-hero .lf-pg-in { gap: 20px; }
.lf-pg-hero-grid { display: grid; grid-template-columns: minmax(0, 1.25fr) minmax(0, .75fr); gap: clamp(28px, 4vw, 56px); align-items: center; }
.lf-pg-hero-copy { display: grid; gap: 18px; align-content: start; }
.lf-pg .lf-pg-title {
	font-family: var(--display);
	font-weight: 800;
	font-size: clamp(2.1rem, 4.4vw, 3.35rem);
	line-height: 1.05;
	letter-spacing: -.03em;
	text-wrap: balance;
	color: var(--ink);
}
.lf-pg-title em { font-style: normal; color: var(--red); }
.lf-pg-lead { font-size: clamp(1.0625rem, 1.5vw, 1.2rem); color: var(--ink-soft); max-width: 60ch; }
.lf-pg-eyebrow {
	justify-self: start;
	display: inline-flex;
	align-items: center;
	gap: 10px;
	padding: 5px 13px;
	border: 1px solid var(--line);
	border-radius: 999px;
	background: var(--paper);
	font-size: .8125rem;
	font-weight: 700;
	color: var(--ink-soft);
}
.lf-pg-eyebrow::before { content: ""; width: 8px; height: 8px; border-radius: 50%; background: var(--blue); box-shadow: 0 0 0 4px rgba(35, 149, 203, .18); }

/* Breadcrumbs (Rank Math) */
.lf-pg .rank-math-breadcrumb { font-size: .875rem; color: var(--ink-soft); }
.lf-pg .rank-math-breadcrumb p { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 0; }
.lf-pg .rank-math-breadcrumb a { color: var(--ink-soft); text-decoration: none; }
.lf-pg .rank-math-breadcrumb a:hover { color: var(--blue-text); text-decoration: underline; }
.lf-pg .rank-math-breadcrumb .separator { margin: 0 8px; color: #9fb3bd; }
.lf-pg .rank-math-breadcrumb .last { color: var(--ink); font-weight: 600; }

/* Hero side card */
.lf-pg-aside {
	display: grid;
	gap: 14px;
	padding: 24px;
	border: 1px solid var(--line);
	border-radius: 16px;
	background: var(--paper);
	box-shadow: 0 30px 60px -36px rgba(7, 47, 69, .45);
}
.lf-pg-aside-title { font-family: var(--display); font-size: 1.15rem; font-weight: 800; }

/* ---------- Facts list (label / value) ---------- */
.lf-pg-facts { list-style: none; padding: 0; display: grid; border-top: 1px dashed var(--line); }
.lf-pg-facts li { display: grid; grid-template-columns: 7rem minmax(0, 1fr); gap: 12px; padding: 11px 0; border-bottom: 1px dashed var(--line); }
.lf-pg-facts strong { padding-top: 3px; font-size: .75rem; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; color: var(--ink-soft); }

/* ---------- Grids and cards ---------- */
.lf-pg-grid { display: grid; gap: 16px; grid-template-columns: repeat(3, minmax(0, 1fr)); }
.lf-pg-grid.is-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.lf-pg-grid.is-4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.lf-pg-card {
	position: relative;
	display: grid;
	align-content: start;
	gap: 8px;
	padding: 24px;
	border: 1px solid var(--line);
	border-radius: var(--radius);
	background: var(--paper);
	transition: border-color .2s ease, box-shadow .2s ease, transform .2s ease;
}
.lf-pg-card p:not([class]) { color: var(--ink-soft); font-size: 1rem; }
.lf-pg-card.is-link:hover { border-color: var(--blue); box-shadow: 0 18px 34px -24px rgba(7, 47, 69, .45); transform: translateY(-2px); }
.lf-pg-card.is-link:focus-within { outline: 3px solid var(--blue); outline-offset: 3px; }
.lf-pg-card.is-dark { background: var(--night); border-color: var(--night); color: #fff; }
.lf-pg-card.is-dark p:not([class]) { color: var(--night-text); }
.lf-pg-card.is-dark a { color: #fff; }
.is-ice .lf-pg-card { border-color: #d7e7ef; }
.is-dark .lf-pg-card { background: rgba(255, 255, 255, .06); border-color: rgba(255, 255, 255, .16); color: #fff; }
.is-dark .lf-pg-card p:not([class]) { color: var(--night-text); }
.lf-pg-num { font-family: var(--display); font-size: 2.4rem; font-weight: 800; line-height: 1; letter-spacing: -.04em; color: var(--blue); }
.lf-pg-num.is-text { font-size: 1.8rem; padding-top: .3rem; }
.is-dark .lf-pg-num,
.lf-pg-card.is-dark .lf-pg-num { color: var(--night-accent); }
.lf-pg-link { padding-top: 6px; font-weight: 700; }
.lf-pg-link a { text-decoration: none; }
.lf-pg-link a::after { content: ""; position: absolute; inset: 0; border-radius: inherit; }
.lf-pg-link::after { content: " →"; color: var(--blue-text); }
.lf-pg-card.is-dark .lf-pg-link::after { color: #fff; }
.lf-pg-tag {
	justify-self: start;
	padding: 3px 10px;
	border-radius: 999px;
	background: var(--ice);
	color: var(--blue-text);
	font-size: .75rem;
	font-weight: 700;
	letter-spacing: .06em;
	text-transform: uppercase;
}
.lf-pg-tag.is-red { background: var(--red); color: #fff; }

/* Tick list */
.lf-pg-ticks { list-style: none; padding: 0; display: grid; gap: 9px; }
.lf-pg-ticks li { position: relative; padding-left: 28px; }
.lf-pg-ticks li::before {
	content: "";
	position: absolute;
	left: 0;
	top: .28em;
	width: 18px;
	height: 18px;
	background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'%3E%3Ccircle cx='10' cy='10' r='10' fill='%232395cb'/%3E%3Cpath d='M5.5 10.4l2.9 2.9 6-6.3' fill='none' stroke='%23fff' stroke-width='2.2' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") no-repeat center / contain;
}

/* Chips */
.lf-pg-chips { list-style: none; padding: 0; display: flex; flex-wrap: wrap; gap: 8px; }
.lf-pg-chips li { padding: 6px 14px; border-radius: 999px; background: var(--ice); font-size: .9375rem; font-weight: 600; color: var(--ink); }
.is-ice .lf-pg-chips li { background: var(--paper); }

/* Stats */
.lf-pg-stats { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 16px; }
.lf-pg-stat { display: grid; gap: 6px; padding: 20px 0; border-top: 2px solid var(--night); }
.lf-pg-stat-num { font-family: var(--display); font-size: clamp(2rem, 3.6vw, 2.8rem); font-weight: 800; line-height: 1; letter-spacing: -.03em; font-variant-numeric: tabular-nums; color: var(--night); }
.lf-pg-stat-label { font-weight: 600; color: var(--ink-soft); }

/* Steps */
.lf-pg-steps { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; }
.lf-pg-step { display: grid; gap: 8px; align-content: start; padding-top: 20px; border-top: 3px solid var(--night); }
.lf-pg-step-num { font-size: .8125rem; font-weight: 700; letter-spacing: .12em; text-transform: uppercase; color: var(--blue-text); }
.lf-pg-step p:not(.lf-pg-step-num) { color: var(--ink-soft); }

/* Split: content + aside */
.lf-pg-split { display: grid; grid-template-columns: minmax(0, 1.4fr) minmax(0, .9fr); gap: clamp(28px, 4vw, 60px); align-items: start; }
.lf-pg-sticky { position: sticky; top: 96px; }

/* ---------- Prose (long text) ---------- */
.lf-pg-prose { display: grid; gap: 16px; max-width: 760px; }
.lf-pg-prose h2 { font-size: clamp(1.45rem, 2.6vw, 1.9rem); margin-top: 18px; }
.lf-pg-prose h3 { font-size: 1.2rem; margin-top: 10px; }
.lf-pg-prose p,
.lf-pg-prose li { color: #22343d; }
.lf-pg-prose ul,
.lf-pg-prose ol { padding-left: 1.3em; display: grid; gap: 7px; }
.lf-pg-prose table { width: 100%; border-collapse: collapse; font-size: .95rem; }
.lf-pg-prose th,
.lf-pg-prose td { padding: 10px 12px; border-bottom: 1px solid var(--line); text-align: left; vertical-align: top; }
.lf-pg-prose th { background: var(--ice); font-weight: 700; }
.lf-pg-table-wrap { overflow-x: auto; }

/* Table of contents */
.lf-pg-toc { display: grid; gap: 10px; padding: 20px 22px; border: 1px solid var(--line); border-radius: var(--radius); background: var(--paper); }
.lf-pg-toc-title { font-size: .8125rem; font-weight: 700; letter-spacing: .12em; text-transform: uppercase; color: var(--ink-soft); }
.lf-pg-toc ol,
.lf-pg-toc ul { padding-left: 1.2em; display: grid; gap: 6px; font-size: .95rem; }
.lf-pg-toc a { text-decoration: none; color: var(--ink); }
.lf-pg-toc a:hover { color: var(--blue-text); text-decoration: underline; }

/* ---------- FAQ ---------- */
.lf-pg-faq-list { display: grid; border-top: 1px solid var(--line); }
body .lf-pg .lf-faq { padding: 0; border-bottom: 1px solid var(--line); }
.lf-pg .lf-faq summary {
	display: flex;
	justify-content: space-between;
	align-items: flex-start;
	gap: 18px;
	padding: 18px 0;
	list-style: none;
	cursor: pointer;
	font-family: var(--display);
	font-size: 1.1rem;
	font-weight: 700;
	line-height: 1.3;
}
.lf-pg .lf-faq summary::-webkit-details-marker { display: none; }
.lf-pg .lf-faq summary::after { content: "+"; flex: none; font-family: var(--body); font-size: 1.8rem; font-weight: 400; line-height: .8; color: var(--blue); transition: transform .2s ease; }
.lf-pg .lf-faq[open] summary::after { transform: rotate(45deg); }
body .lf-pg .lf-faq > p { max-width: 70ch; padding-bottom: 20px; color: var(--ink-soft); }

/* ---------- Reviews ---------- */
body .lf-pg .lf-pg-quote {
	display: grid;
	align-content: space-between;
	gap: 14px;
	padding: 24px;
	border: 0;
	border-radius: var(--radius);
	background: var(--ice);
	font-style: normal;
}
.is-ice .lf-pg-quote { background: var(--paper) !important; }
.lf-pg-quote p::before { content: "★★★★★"; display: block; margin-bottom: 8px; font-size: .9rem; letter-spacing: 3px; color: var(--star); }
.lf-pg-quote cite { font-size: .9375rem; font-style: normal; font-weight: 700; color: var(--ink-soft); }

/* ---------- Results lists ---------- */
.lf-pg-scores { list-style: none; padding: 0; display: grid; border-top: 2px solid var(--ink); counter-reset: rank; }
.lf-pg-scores li {
	counter-increment: rank;
	display: grid;
	grid-template-columns: 2.2rem minmax(0, 1fr) auto;
	align-items: baseline;
	gap: 10px;
	padding: 11px 4px;
	border-bottom: 1px dashed var(--line);
}
.lf-pg-scores li::before { content: counter(rank); font-size: .8125rem; font-weight: 700; color: var(--ink-soft); font-variant-numeric: tabular-nums; }
.lf-pg-scores li strong { font-family: var(--display); font-size: 1.15rem; font-weight: 800; font-variant-numeric: tabular-nums; }
.lf-pg-scores li.is-top strong { color: var(--red-text); }
.lf-pg-scores li.is-top span { font-weight: 700; }
.lf-pg-posters { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; }
.lf-pg-poster { overflow: hidden; border-radius: var(--radius); background: var(--night); box-shadow: 0 24px 44px -26px rgba(7, 47, 69, .6); }
.lf-pg-poster img { display: block; width: 100%; height: auto; aspect-ratio: 3 / 4; object-fit: cover; }
.lf-pg-poster figcaption { padding: 9px 12px; font-size: .8125rem; font-weight: 600; color: var(--night-text); }

/* ---------- Form frame (Tally admission forms, contact form) ---------- */
.lf-pg-form {
	display: grid;
	gap: 16px;
	padding: clamp(20px, 3vw, 36px);
	border: 1px solid var(--line);
	border-radius: 18px;
	background: var(--paper);
	box-shadow: 0 30px 60px -40px rgba(7, 47, 69, .5);
}
.lf-pg-form iframe { display: block; width: 100%; min-height: 520px; border: 0; }
.lf-pg-form-note { font-size: .9375rem; color: var(--ink-soft); }
.lf-pg .lf-form label { font-weight: 700; }
.lf-pg .lf-form input,
.lf-pg .lf-form select,
.lf-pg .lf-form textarea { border-radius: 10px; }
.lf-pg .lf-submit { border-radius: 10px; background: var(--blue-button); }

/* ---------- Map ---------- */
.lf-pg-map { overflow: hidden; aspect-ratio: 16 / 9; max-width: 100%; border: 1px solid var(--line); border-radius: 16px; background: var(--paper); }
.lf-pg-map iframe { display: block; width: 100%; height: 100%; border: 0; }

/* ---------- Notice ---------- */
.lf-pg-notice { padding: 16px 20px; border-left: 4px solid var(--blue); border-radius: 0 12px 12px 0; background: var(--ice); color: var(--ink); }

/* ---------- Call-to-action band ---------- */
.lf-pg-cta {
	padding: clamp(52px, 7vw, 88px) 20px;
	background: radial-gradient(60% 90% at 50% 0%, rgba(35, 149, 203, .35) 0%, rgba(35, 149, 203, 0) 70%), var(--night);
	color: #fff;
	text-align: center;
}
.lf-pg-cta .lf-pg-in { justify-items: center; gap: 16px; }
.lf-pg .lf-pg-cta h2 { font-size: clamp(1.9rem, 4.2vw, 3rem); }
.lf-pg-cta-text { max-width: 54ch; font-size: 1.125rem; color: var(--night-text); }
.lf-pg-cta .lf-pg-actions,
.lf-pg-cta .lf-h-actions { justify-content: center; padding-top: 4px; }

/* ---------- Responsive ---------- */
@media (max-width: 960px) {
	.lf-pg-hero-grid,
	.lf-pg-split { grid-template-columns: minmax(0, 1fr); }
	.lf-pg-grid,
	.lf-pg-grid.is-4 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
	.lf-pg-stats { grid-template-columns: repeat(2, minmax(0, 1fr)); }
	.lf-pg-sticky { position: static; }
}
@media (max-width: 640px) {
	.lf-pg-sec { padding-block: 46px; }
	.lf-pg-grid,
	.lf-pg-grid.is-2,
	.lf-pg-grid.is-4,
	.lf-pg-steps,
	.lf-pg-posters { grid-template-columns: minmax(0, 1fr); }
	.lf-pg .lf-h-actions .wp-block-button,
	.lf-pg .lf-pg-actions .wp-block-button { flex: 1 1 100%; }
	.lf-pg .lf-h-actions .wp-block-button__link,
	.lf-pg .lf-pg-actions .wp-block-button__link { width: 100%; }
	.lf-pg-facts li { grid-template-columns: minmax(0, 1fr); gap: 2px; }
	.lf-pg-form iframe { min-height: 640px; }
}
@media (prefers-reduced-motion: reduce) {
	.lf-pg *,
	.lf-pg *::before,
	.lf-pg *::after { transition: none !important; animation: none !important; }
}

/* Taller map on phones */
@media (max-width: 640px) {
	.lf-pg-map { aspect-ratio: 4 / 3; }
}

/* ---------------------------------------------------------------- Long pages (Privacy Policy, Exam Paper Builder) */
.lf-pg [id] { scroll-margin-top: 104px; }
.lf-pg-meta { font-size: .9375rem; color: var(--ink-soft); }
.lf-pg-doc { display: grid; grid-template-columns: minmax(0, 270px) minmax(0, 1fr); gap: clamp(28px, 5vw, 72px); align-items: start; }
.lf-pg-doc .lf-pg-prose { max-width: 780px; }
.lf-pg-doc .lf-pg-toc { max-height: calc(100vh - 120px); overflow-y: auto; }
.lf-pg-toc-app a { font-weight: 700; color: var(--blue-text); }
.lf-pg-toc-list { font-variant-numeric: tabular-nums; }
.lf-pg-secnum { display: inline-block; min-width: 2.1em; color: var(--blue-text); font-variant-numeric: tabular-nums; }
.lf-pg-prose h2[id] { padding-top: 24px; border-top: 1px solid var(--line); }
.lf-pg-prose .lf-pg-notice { display: grid; gap: 4px; }
.lf-pg-rights .lf-pg-card { gap: 6px; }

/* Tables (core table block) */
.lf-pg .wp-block-table { margin: 0; overflow-x: auto; border: 1px solid var(--line); border-radius: 12px; background: var(--paper); }
.lf-pg .wp-block-table table { width: 100%; min-width: 560px; border-collapse: collapse; font-size: .95rem; }
.lf-pg .wp-block-table thead { border-bottom: 0; }
.lf-pg .wp-block-table th,
.lf-pg .wp-block-table td { padding: 11px 14px; border: 0; border-bottom: 1px solid var(--line); text-align: left; vertical-align: top; }
.lf-pg .wp-block-table th { background: var(--ice); font-weight: 700; color: var(--ink); }
.lf-pg .wp-block-table tbody tr:last-child td { border-bottom: 0; }
.lf-pg .wp-block-table td:first-child { font-weight: 600; color: var(--ink); }

/* App illustration and download strip (Exam Paper Builder) */
.lf-pg-mock { margin: 0; display: grid; gap: 14px; }
.lf-pg-mock-screen { display: grid; gap: 12px; padding: 18px; border-radius: 22px; background: #072f45; color: #fff; box-shadow: inset 0 0 0 6px rgba(255, 255, 255, .06); }
.lf-pg-mock-bar { font-size: .8125rem; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; color: #9fd3ec; }
.lf-pg-mock-rules { list-style: none; padding: 0; margin: 0; display: grid; gap: 10px; }
.lf-pg-mock-rules li { display: grid; grid-template-columns: auto minmax(0, 1fr); column-gap: 14px; align-items: center; padding: 12px 14px; border-radius: 14px; background: rgba(255, 255, 255, .08); }
.lf-pg-mock-rules strong { grid-row: span 2; font-family: var(--display); font-size: 1.9rem; line-height: 1; font-variant-numeric: tabular-nums; }
.lf-pg-mock-rules span { font-weight: 700; line-height: 1.3; }
.lf-pg-mock-rules em { font-style: normal; font-size: .875rem; color: #b9d6e3; }
.lf-pg-mock-hint { font-size: .875rem; color: #b9d6e3; }
.lf-pg-mock-btn { justify-self: start; padding: 9px 18px; border-radius: 999px; background: #1573a6; color: #fff; font-weight: 700; font-size: .9375rem; }
.lf-pg-mock figcaption { font-size: .9375rem; color: var(--ink-soft); }
.lf-pg-download { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 12px 20px; margin-top: 24px; }
.lf-pg-cta-note { font-size: .9375rem; opacity: .78; }

@media (max-width: 960px) {
	.lf-pg-doc { grid-template-columns: minmax(0, 1fr); }
	.lf-pg-doc .lf-pg-toc { max-height: none; }
}

/* ---------------------------------------------------------------- Study materials */
.lf-pg-stack { display: grid; gap: 18px; }
.lf-pg-stack > .wp-block-heading { margin-top: 10px; }
.lf-pg-toc-chips a { text-decoration: none; color: var(--ink); }
.lf-pg-toc-chips a:hover { color: var(--blue-text); text-decoration: underline; }

/* Chapter downloads: name on the left, link on the right */
.lf-pg-files { list-style: none; padding: 0 !important; margin: 0; display: grid !important; gap: 0 !important; border: 1px solid var(--line); border-radius: 12px; background: var(--paper); overflow: hidden; }
.lf-pg-files li { display: flex; flex-wrap: wrap; align-items: baseline; justify-content: space-between; gap: 4px 16px; padding: 12px 16px; border-bottom: 1px solid var(--line); }
.lf-pg-files li:last-child { border-bottom: 0; }
.lf-pg-files li strong { font-weight: 600; color: var(--ink); }
.lf-pg-files a { flex: none; font-weight: 700; color: var(--blue-text); white-space: nowrap; }

/* NCERT book cards with chapter links */
.lf-pg-book { align-content: start; }
.lf-pg-book-sub { font-size: .9375rem; font-weight: 600; color: var(--ink-soft); }
.lf-pg-chaplinks { display: flex; flex-wrap: wrap; gap: 6px; }
.lf-pg-chaplinks a { display: inline-block; padding: 5px 11px; border: 1px solid var(--line); border-radius: 999px; background: var(--paper); font-size: .875rem; font-weight: 600; color: var(--blue-text); text-decoration: none; font-variant-numeric: tabular-nums; }
.lf-pg-chaplinks a:hover { border-color: var(--blue); background: var(--ice); }
.lf-pg-card.is-soon { background: var(--ice); border-style: dashed; }
.lf-pg-tag.is-muted { background: #e3edf2; color: var(--ink-soft); }
.lf-pg-card h3 a { color: inherit; text-decoration: none; }
.lf-pg-card h3 a:hover { color: var(--blue-text); text-decoration: underline; }

/* Practice questions with a show/hide answer */
.lf-pg-qa-list { display: grid; gap: 12px; }
.lf-pg-qa { border: 1px solid var(--line); border-radius: 12px; background: var(--paper); }
.lf-pg-qa summary { cursor: pointer; padding: 14px 18px; line-height: 1.55; }
.lf-pg-qa summary::marker { color: var(--blue-text); }
.lf-pg-qa summary strong { color: var(--blue-text); font-variant-numeric: tabular-nums; }
.lf-pg-qa[open] summary { border-bottom: 1px solid var(--line); }
.lf-pg-qa > p { margin: 0; padding: 14px 18px 16px; }

/* Formulas typeset by MathJax */
.lf-pg mjx-container[display="true"] { overflow-x: auto; overflow-y: hidden; max-width: 100%; }
.lf-pg mjx-container { font-size: 104% !important; }
.lf-pg-ol { padding-left: 1.3em; display: grid; gap: 7px; }

/* Coming-soon cards on a blue band */
.is-ice .lf-pg-card.is-soon { background: var(--paper); }

/* ---------------------------------------------------------------- Blog index, categories, search and "Page not found" */
.lf-pg-posts .wp-block-post-template { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 18px; list-style: none; padding: 0; margin: 0; }
.lf-pg-posts .wp-block-post { position: relative; display: grid; align-content: start; gap: 10px; padding-bottom: 20px; border: 1px solid var(--line); border-radius: var(--radius); background: var(--paper); overflow: hidden; transition: border-color .2s ease, box-shadow .2s ease; }
.lf-pg-posts .wp-block-post:hover { border-color: var(--blue); box-shadow: 0 18px 34px -24px rgba(7, 47, 69, .45); }
.lf-pg-posts .wp-block-post > :not(.wp-block-post-featured-image) { margin: 0 20px; }
.lf-pg-posts .wp-block-post > :first-child:not(.wp-block-post-featured-image) { margin-top: 20px; }
.lf-pg-posts .wp-block-post-featured-image { margin: 0; background: var(--ice); }
.lf-pg-posts .wp-block-post-featured-image img { width: 100%; height: 100%; object-fit: cover; }
.lf-pg-posts .wp-block-post-terms { font-size: .8125rem; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; }
.lf-pg-posts .wp-block-post-terms a { color: var(--blue-text); text-decoration: none; }
.lf-pg-posts .wp-block-post-title { font-size: 1.25rem; line-height: 1.25; }
.lf-pg-posts .wp-block-post-title a { color: var(--ink); text-decoration: none; }
.lf-pg-posts .wp-block-post-title a::after { content: ""; position: absolute; inset: 0; }
.lf-pg-posts .wp-block-post:hover .wp-block-post-title a { color: var(--blue-text); }
.lf-pg-posts .wp-block-post-title a:focus-visible { outline: 3px solid var(--blue); outline-offset: 3px; }
.lf-pg-posts .wp-block-post-excerpt { color: var(--ink-soft); font-size: .975rem; }
.lf-pg-posts .wp-block-post-excerpt__excerpt { margin: 0; }
.lf-pg-posts .wp-block-post-date { font-size: .875rem; color: var(--ink-soft); }
.lf-pg-posts .wp-block-query-pagination { margin-top: 28px; gap: 12px; font-weight: 700; }
.lf-pg-search { max-width: 520px; }
.lf-pg-search .wp-block-search__inside-wrapper { padding: 4px; border: 1px solid var(--line); border-radius: 999px; background: var(--paper); }
.lf-pg-search .wp-block-search__input { min-width: 0; padding: 10px 16px; border: 0; background: transparent; font: inherit; color: var(--ink); }
.lf-pg-search .wp-block-search__button { margin: 0; padding: 10px 22px; border: 0; border-radius: 999px; background: var(--blue-button); color: #fff; font-weight: 700; }
.lf-pg-search .wp-block-search__button:hover { background: var(--blue-button-hover); }

@media (max-width: 960px) {
	.lf-pg-posts .wp-block-post-template { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 640px) {
	.lf-pg-posts .wp-block-post-template { grid-template-columns: minmax(0, 1fr); }
}
