/*
Theme Name: Lampton Edu
Theme URI: https://lamptonedu.co.uk
Author: Lampton Education
Author URI: https://lamptonedu.co.uk
Description: Header, footer, base typography and blog templates for lamptonedu.co.uk. Designed to be used together with the "Lampton Education Manager" plugin, which creates and manages every page, course, form and the student application portal. Fast by design: no web fonts, no jQuery, one stylesheet and a tiny deferred script.
Version: 1.0.0
Requires at least: 6.0
Requires PHP: 7.4
License: GPL-2.0+
Text Domain: lampton-edu
*/

/* Design tokens (shared with the plugin's stylesheet). */
:root {
	--lec-ink: #0e1a33;
	--lec-navy: #15274d;
	--lec-royal: #2b4bdb;
	--lec-royal-dark: #1f38a8;
	--lec-saffron: #f3a939;
	--lec-saffron-dark: #d98e1f;
	--lec-paper: #f3f5fa;
	--lec-line: #dce2ee;
	--lec-muted: #56627a;
	--lec-serif: Charter, "Bitstream Charter", "Sitka Text", Cambria, "Iowan Old Style", Georgia, serif;
	--lec-sans: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
	--lec-header-h: 76px;
	--lt-adminbar: var(--wp-admin--admin-bar--height, 0px);
}

/* ── Base ── */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; scroll-padding-top: calc(var(--lec-header-h) + 16px); }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }
body { margin: 0; padding-top: var(--lec-header-h); font: 400 1rem/1.6 var(--lec-sans); color: var(--lec-ink); background: #fff; -webkit-font-smoothing: antialiased; text-rendering: optimizeLegibility; overflow-x: hidden; }
img, video, svg { max-width: 100%; }
img { height: auto; }
a { color: var(--lec-royal); }
a:focus-visible, button:focus-visible, input:focus-visible, select:focus-visible, textarea:focus-visible, summary:focus-visible { outline: 3px solid var(--lec-saffron); outline-offset: 2px; }
h1, h2, h3, h4 { line-height: 1.2; }
button { font-family: inherit; }
.screen-reader-text { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(1px, 1px, 1px, 1px); white-space: nowrap; }
.lt-main:focus { outline: none; }
.lt-skip { position: absolute; left: 12px; top: -60px; z-index: 10001; background: var(--lec-saffron); color: var(--lec-ink); padding: 10px 16px; border-radius: 6px; font-weight: 700; text-decoration: none; }
.lt-skip:focus { top: 12px; }
.lec-wrap { width: 100%; max-width: 1220px; margin: 0 auto; padding: 0 clamp(18px, 4vw, 40px); }

/* ═══ HEADER ═══ */
.lt-header { position: fixed; top: var(--lt-adminbar); left: 0; right: 0; z-index: 1000; height: var(--lec-header-h); background: #fff; color: var(--lec-ink); border-bottom: 1px solid var(--lec-line); transition: background-color .25s, border-color .25s, box-shadow .25s, color .25s; }
.lt-header.is-scrolled { box-shadow: 0 6px 24px rgba(14, 26, 51, .08); }
.lt-header__in { height: 100%; max-width: 1220px; margin: 0 auto; padding: 0 clamp(18px, 4vw, 40px); display: flex; align-items: center; gap: 28px; }
.lt-brand { display: flex; align-items: center; color: inherit; text-decoration: none; flex: none; }
.lt-brand img { display: block; height: 40px; width: auto; }
.lt-brand__light { display: none; }
.lt-wordmark { display: inline-flex; align-items: center; gap: 10px; font: 700 1.3rem/1 var(--lec-serif); letter-spacing: -.01em; color: inherit; }
.lt-wordmark__mark { width: 36px; height: 36px; border-radius: 9px; display: grid; place-items: center; background: var(--lec-royal); color: #fff; font-size: 1.25rem; }
.lt-wordmark em { font-style: normal; font-weight: 400; }

/* Transparent over the homepage video, solid once scrolled. */
.lt-header.is-transparent:not(.is-scrolled):not(.is-open) { background: transparent; border-color: transparent; color: #fff; }
.lt-header.is-transparent:not(.is-scrolled):not(.is-open) .lt-brand__dark { display: none; }
.lt-header.is-transparent:not(.is-scrolled):not(.is-open) .lt-brand__light { display: flex; }
.lt-header.is-transparent:not(.is-scrolled):not(.is-open) .lt-wordmark__mark { background: #fff; color: var(--lec-ink); }

/* ── Navigation ── */
.lt-nav { flex: 1; display: flex; justify-content: center; }
.lt-nav__list { list-style: none; margin: 0; padding: 0; display: flex; align-items: center; gap: 4px; }
.lt-nav__item, .lt-nav__list > li { position: relative; display: flex; align-items: center; }
.lt-nav__link, .lt-nav__list > li > a { display: block; padding: 10px 12px; color: inherit; text-decoration: none; font-weight: 600; font-size: .98rem; border-radius: 6px; }
.lt-nav__link:hover, .lt-nav__list > li > a:hover { color: var(--lec-royal); }
.lt-header.is-transparent:not(.is-scrolled):not(.is-open) .lt-nav__link:hover { color: var(--lec-saffron); }
.lt-nav__item.is-current > .lt-nav__link { box-shadow: inset 0 -2px 0 var(--lec-saffron); border-radius: 0; }
.lt-nav__caret { width: 22px; height: 32px; margin-left: -8px; border: 0; background: transparent; color: inherit; cursor: pointer; position: relative; }
.lt-nav__caret::before { content: ""; position: absolute; left: 6px; top: 11px; width: 6px; height: 6px; border-right: 2px solid currentColor; border-bottom: 2px solid currentColor; transform: rotate(45deg); transition: transform .2s; }
.lt-sub { list-style: none; margin: 0; padding: 10px; position: absolute; top: calc(100% + 6px); left: 0; min-width: 270px; background: #fff; color: var(--lec-ink); border: 1px solid var(--lec-line); border-radius: 12px; box-shadow: 0 18px 48px rgba(14, 26, 51, .16); opacity: 0; visibility: hidden; transform: translateY(6px); transition: opacity .18s, transform .18s, visibility .18s; }
.lt-sub::before { content: ""; position: absolute; left: 0; right: 0; top: -12px; height: 12px; }
.lt-sub a { display: block; padding: 9px 12px; border-radius: 7px; color: var(--lec-ink); text-decoration: none; font-weight: 500; font-size: .95rem; }
.lt-sub a:hover, .lt-sub a:focus-visible { background: var(--lec-paper); color: var(--lec-royal); }
.lt-sub li:first-child a { font-weight: 700; }
.has-sub:hover > .lt-sub, .has-sub:focus-within > .lt-sub, .has-sub.is-open > .lt-sub { opacity: 1; visibility: visible; transform: none; }
.has-sub.is-open > .lt-nav__caret::before { transform: rotate(-135deg); top: 14px; }
.lt-nav__mobile-extra { display: none; }

.lt-header__actions { display: flex; align-items: center; gap: 18px; flex: none; margin-left: auto; }
.lt-nav + .lt-header__actions { margin-left: 0; }
.lt-header__login { color: inherit; text-decoration: none; font-weight: 600; font-size: .95rem; }
.lt-header__login:hover { text-decoration: underline; text-underline-offset: 4px; }
.lt-header .lt-header__cta { min-height: 44px; padding: .6em 1.2em; }
.lt-burger { display: none; width: 44px; height: 44px; border: 0; background: transparent; color: inherit; cursor: pointer; position: relative; }
.lt-burger span:first-child, .lt-burger span:first-child::before, .lt-burger span:first-child::after { position: absolute; left: 11px; width: 22px; height: 2px; background: currentColor; border-radius: 2px; transition: transform .2s, top .2s, opacity .2s; }
.lt-burger span:first-child { top: 21px; }
.lt-burger span:first-child::before { content: ""; left: 0; top: -7px; }
.lt-burger span:first-child::after { content: ""; left: 0; top: 7px; }
.lt-header.is-open .lt-burger span:first-child { background: transparent; }
.lt-header.is-open .lt-burger span:first-child::before { top: 0; transform: rotate(45deg); }
.lt-header.is-open .lt-burger span:first-child::after { top: 0; transform: rotate(-45deg); }

@media (max-width: 1180px) {
	.lt-header__login { display: none; }
	.lt-nav__link { padding: 10px 9px; }
}
@media (max-width: 1040px) {
	:root { --lec-header-h: 68px; }
	.lt-burger { display: block; }
	.lt-header__in { justify-content: space-between; }
	.lt-nav { position: fixed; top: calc(var(--lec-header-h) + var(--lt-adminbar)); left: 0; right: 0; bottom: 0; background: #fff; color: var(--lec-ink); padding: 12px clamp(18px, 4vw, 40px) 32px; overflow-y: auto; display: block; transform: translateX(100%); visibility: hidden; transition: transform .25s ease, visibility .25s; }
	.lt-header.is-open .lt-nav { transform: none; visibility: visible; }
	.lt-nav__list { display: block; }
	.lt-nav__item, .lt-nav__list > li { flex-wrap: wrap; border-bottom: 1px solid var(--lec-line); }
	.lt-nav__link, .lt-nav__list > li > a { flex: 1; padding: 16px 0; font-size: 1.1rem; }
	.lt-nav__item.is-current > .lt-nav__link { box-shadow: none; color: var(--lec-royal); }
	.lt-nav__caret { width: 48px; height: 48px; margin: 0; }
	.lt-nav__caret::before { left: 20px; top: 18px; width: 8px; height: 8px; }
	.has-sub.is-open > .lt-nav__caret::before { top: 22px; }
	.lt-sub { position: static; width: 100%; min-width: 0; padding: 0 0 12px 8px; border: 0; box-shadow: none; opacity: 1; visibility: visible; transform: none; display: none; }
	.lt-sub::before { display: none; }
	.has-sub:hover > .lt-sub, .has-sub:focus-within > .lt-sub { display: none; }
	.has-sub.is-open > .lt-sub { display: block; }
	.lt-nav__mobile-extra { display: grid; gap: 16px; margin-top: 24px; }
	.lt-nav__phone { display: flex; align-items: center; gap: 8px; justify-content: center; color: var(--lec-ink); font-weight: 600; text-decoration: none; }
	body.lt-menu-open { overflow: hidden; }
}
@media (max-width: 520px) {
	.lt-header .lt-header__cta { display: none; }
	.lt-wordmark { font-size: 1.15rem; }
}

/* ═══ FOOTER ═══ */
.lt-footer { background: var(--lec-ink); color: #b8c2da; font-size: .97rem; }
.lt-footer a { color: #e6ebf7; text-decoration: none; }
.lt-footer a:hover { color: var(--lec-saffron); }
.lt-footer__top { display: grid; grid-template-columns: 1.6fr repeat(3, 1fr); gap: clamp(28px, 4vw, 56px); padding-top: clamp(56px, 7vw, 88px); padding-bottom: 56px; }
.lt-brand--footer { color: #fff; margin-bottom: 18px; }
.lt-brand--footer .lt-wordmark__mark { background: #fff; color: var(--lec-ink); }
.lt-footer__tag { margin: 0 0 22px; max-width: 34ch; line-height: 1.6; }
.lt-footer__contact { list-style: none; margin: 0 0 22px; padding: 0; display: grid; gap: 12px; }
.lt-footer__contact li { display: flex; gap: 10px; align-items: flex-start; line-height: 1.5; }
.lt-footer__contact .lec-ico { color: var(--lec-saffron); margin-top: 2px; }
.lt-social { list-style: none; margin: 0; padding: 0; display: flex; gap: 8px; }
.lt-social a { width: 40px; height: 40px; border-radius: 50%; display: grid; place-items: center; border: 1px solid rgba(255, 255, 255, .2); }
.lt-social a:hover { border-color: var(--lec-saffron); }
.lt-footer__col h2 { font: 700 1.05rem var(--lec-serif); color: #fff; margin: 4px 0 16px; }
.lt-footer__col ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; }
.lt-footer__bottom { border-top: 1px solid rgba(255, 255, 255, .1); padding: 22px 0; font-size: .87rem; }
.lt-footer__bottom-in { display: flex; justify-content: space-between; gap: 16px 28px; flex-wrap: wrap; align-items: center; }
.lt-footer__bottom p { margin: 0; max-width: 70ch; line-height: 1.55; }
.lt-footer__bottom ul { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 18px; }
@media (max-width: 900px) {
	.lt-footer__top { grid-template-columns: 1fr 1fr; }
	.lt-footer__brand { grid-column: 1 / -1; }
}
@media (max-width: 520px) { .lt-footer__top { grid-template-columns: 1fr; } }

/* ═══ BLOG & GENERIC CONTENT ═══ */
.lt-posts { display: grid; grid-template-columns: repeat(3, 1fr); gap: 26px; }
.lt-post { position: relative; border: 1px solid var(--lec-line); border-radius: 14px; overflow: hidden; background: #fff; display: flex; flex-direction: column; transition: box-shadow .15s, border-color .15s; }
.lt-post:hover { border-color: #b9c5e6; box-shadow: 0 10px 30px rgba(14, 26, 51, .08); }
.lt-post__img img { display: block; width: 100%; aspect-ratio: 16 / 9; object-fit: cover; }
.lt-post__body { padding: 22px 24px 26px; }
.lt-post time { font-size: .85rem; color: var(--lec-muted); }
.lt-post h2 { font: 700 1.25rem/1.3 var(--lec-serif); margin: 8px 0 10px; }
.lt-post h2 a { color: var(--lec-ink); text-decoration: none; }
.lt-post h2 a::after { content: ""; position: absolute; inset: 0; }
.lt-post p { margin: 0; color: var(--lec-muted); line-height: 1.6; }
.lt-pagination { margin-top: 40px; }
.lt-pagination .nav-links { display: flex; gap: 8px; flex-wrap: wrap; justify-content: center; }
.lt-pagination .page-numbers { min-width: 42px; height: 42px; padding: 0 12px; display: grid; place-items: center; border: 1px solid var(--lec-line); border-radius: 8px; text-decoration: none; color: var(--lec-ink); font-weight: 600; }
.lt-pagination .page-numbers.current { background: var(--lec-ink); color: #fff; border-color: var(--lec-ink); }
.lt-results { list-style: none; padding: 0; margin: 0; }
.lt-results li { padding: 20px 0; border-bottom: 1px solid var(--lec-line); }
.lt-results a { font: 700 1.2rem var(--lec-serif); color: var(--lec-ink); text-decoration: none; }
.lt-results p { margin: 6px 0 0; color: var(--lec-muted); }
.lt-feature-img { margin: 0 0 36px; }
.lt-feature-img img { border-radius: 18px; display: block; width: 100%; }
.lt-entry h2 { font-family: var(--lec-serif); }
.lt-entry h3 { font-size: 1.25rem; margin: 1.6em 0 .5em; }
.lt-entry img { border-radius: 12px; }
.lt-entry blockquote { margin: 1.6em 0; padding: 4px 0 4px 22px; border-left: 3px solid var(--lec-saffron); font: 1.2rem/1.55 var(--lec-serif); color: var(--lec-ink); }
.lt-entry table { width: 100%; border-collapse: collapse; margin: 1.4em 0; }
.lt-entry th, .lt-entry td { padding: 10px 12px; border-bottom: 1px solid var(--lec-line); text-align: left; }
.lt-entry figure { margin: 1.6em 0; }
.lt-entry figcaption { font-size: .88rem; color: var(--lec-muted); margin-top: 8px; }
.alignwide { margin-left: -6vw; margin-right: -6vw; }
.aligncenter { margin-left: auto; margin-right: auto; display: block; }
.lt-404__code { font: 700 clamp(5rem, 14vw, 9rem)/1 var(--lec-serif); color: var(--lec-saffron); margin: 0; letter-spacing: -.04em; }
@media (max-width: 960px) { .lt-posts { grid-template-columns: 1fr 1fr; } }
@media (max-width: 620px) { .lt-posts { grid-template-columns: 1fr; } }
