/*
Theme Name: Aviation Theory
Description: A custom block theme for aviation theory training. Scaffolded by Studio Code.
Requires at least: 6.7
Tested up to: 6.9
Requires PHP: 7.2
Version: 0.1.2
License: GNU General Public License v2 or later
License URI: http://www.gnu.org/licenses/gpl-2.0.html
Text Domain: aviation-theory
Tags: full-site-editing, block-patterns, block-styles, wide-blocks, accessibility-ready, style-variations
*/

/* Zero the block gap between the template's top-level sections so full-bleed
   bands butt edge-to-edge and own their vertical rhythm. */
.wp-site-blocks > * + * {
	margin-block-start: 0;
}

.wp-site-blocks main {
	padding-block: var(--wp--preset--spacing--60) var(--wp--preset--spacing--70);
}
.wp-site-blocks main.is-flush {
	padding-block: 0;
}

/* === site header === */
.site-header {
	position: sticky;
	top: 0;
	z-index: 50;
	background-color: var(--wp--preset--color--background);
	border-bottom: 1px solid var(--wp--preset--color--border);
	/* sky + cloud wash across the bar */
	background-image:
		/* soft cloud blobs - keep the centre bright */
		radial-gradient(80% 90% at 8% 0%, rgba(255, 255, 255, 0.95) 0%, rgba(255, 255, 255, 0) 46%),
		radial-gradient(52% 80% at 24% 6%, rgba(255, 255, 255, 0.85) 0%, rgba(255, 255, 255, 0) 55%),
		/* Australian red bleeding in from the edges */
		radial-gradient(120% 130% at 0% -10%, rgba(240, 152, 127, 0.75) 0%, rgba(240, 152, 127, 0) 55%),
		radial-gradient(130% 140% at 100% -12%, rgba(240, 152, 127, 0.7) 0%, rgba(240, 152, 127, 0) 58%),
		radial-gradient(170% 80% at 50% -70%, rgba(240, 152, 127, 0.45) 0%, rgba(240, 152, 127, 0) 55%),
		linear-gradient(180deg, rgba(240, 152, 127, 0) 72%, rgba(240, 152, 127, 0.32) 100%),
		/* sky base, light in the centre so brand + nav stay readable */
		linear-gradient(180deg, #eef5fb 0%, #fbfdfe 55%, #ffffff 100%);
}
.site-header > * {
	position: relative;
	z-index: 1;
}
/* faint altimeter/compass gauge peeking from the lower-right corner */
.site-header::after {
	content: "";
	position: absolute;
	bottom: 0;
	right: 0;
	width: 210px;
	height: 110px;
	pointer-events: none;
	opacity: 0.3;
	background:
		repeating-radial-gradient(circle at 100% 100%, rgba(18, 49, 79, 0) 0 17px, rgba(42, 127, 184, 0.32) 17px 18px),
		repeating-radial-gradient(circle at 100% 100%, rgba(18, 49, 79, 0) 0 34px, rgba(42, 127, 184, 0.24) 34px 35px),
		repeating-radial-gradient(circle at 100% 100%, rgba(18, 49, 79, 0) 0 51px, rgba(42, 127, 184, 0.16) 51px 52px),
		radial-gradient(circle at 100% 100%, rgba(42, 127, 184, 0.5) 0 2px, rgba(42, 127, 184, 0) 3px);
}
.site-header .wp-site-title {
	font-size: 1.25rem;
	font-weight: 600;
	letter-spacing: -0.01em;
}
/* === brand: Aussie logo + site name (replaces the plain site title) === */
.site-brand {
	gap: 10px;
}
.brand-logo {
	width: 50px;
	height: 50px;
	margin: 0;
	flex: 0 0 auto;
}
.brand-logo img {
	width: 50px;
	height: 50px;
	border-radius: 999px;
	object-fit: cover;
	border: 1px solid var(--wp--preset--color--border);
	display: block;
}
.site-brand .site-brand-name {
	margin: 0;
	line-height: 1.15;
	font-size: 1.35rem;
	font-weight: 600;
	letter-spacing: -0.01em;
	color: var(--wp--preset--color--primary);
}
.site-header .wp-block-buttons {
	gap: 10px;
}
.site-header .wp-block-button__link {
	padding: 7px 11px;
	font-size: 0.6875rem;
	letter-spacing: 0.5px;
}

/* === header nav (navigation block, compact pill links + Courses subject dropdown) === */
.site-header .site-nav {
	font-size: 0.6875rem;
	font-weight: 600;
	letter-spacing: 0.5px;
	text-transform: uppercase;
	--wp--navigation--layout-flex--gap: 10px;
}
.site-nav .wp-block-navigation__container,
.site-nav .wp-block-navigation__responsive-container-content {
	flex-wrap: wrap;
	gap: 10px !important;
}
.site-header nav.site-nav {
	min-width: 0;
	max-width: 100%;
}
.site-nav {
	gap: 10px !important;
}
.site-nav li {
	list-style: none;
}
.site-nav .wp-block-navigation-item > a.wp-block-navigation-item__content,
.site-nav .wp-block-navigation-submenu > .wp-block-navigation-item__content {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	padding: 7px 11px;
	border-radius: 999px;
	border: 1px solid #bcd7ee;
	background: #dcebf6; /* light blue */
	color: var(--wp--preset--color--text);
	text-decoration: none;
}
.site-nav .wp-block-navigation-item:hover > a.wp-block-navigation-item__content,
.site-nav .wp-block-navigation-item:hover > .wp-block-navigation-item__content,
.site-nav .wp-block-navigation-item:focus-visible > a.wp-block-navigation-item__content {
	border-color: #8fbbe2;
	color: var(--wp--preset--color--text);
	background: #bfd7ef; /* a bit darker blue */
}
/* current / selected page: darker blue */
.site-nav .wp-block-navigation-item.nav-current > a.wp-block-navigation-item__content,
.site-nav .wp-block-navigation-item.nav-current > .wp-block-navigation-item__content {
	border-color: #7fadd7;
	background: #aecbe8; /* darker blue */
	color: var(--wp--preset--color--text);
	font-weight: 700;
}

/* paper-plane aviation mark on the brand + each top-level nav pill */
.site-header .wp-block-site-title,
.site-nav .wp-block-navigation-item__content {
	position: relative;
}
.site-header .wp-block-site-title::before,
.site-nav .wp-block-navigation-item__content::before {
	content: "";
	display: inline-block;
	width: 12px;
	height: 12px;
	margin-right: 7px;
	vertical-align: -1px;
	background-color: currentColor;
	-webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M2.01 21L23 12 2.01 3 2 10l15 2-15 2s-3.5 2-3.5 2z'/%3E%3C/svg%3E") no-repeat center / contain;
	mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M2.01 21L23 12 2.01 3 2 10l15 2-15 2s-3.5 2-3.5 2z'/%3E%3C/svg%3E") no-repeat center / contain;
}
.site-header .wp-block-site-title::before {
	width: 16px;
	height: 16px;
	margin-right: 9px;
	vertical-align: -2px;
}
.site-header .wp-block-site-title {
	color: var(--wp--preset--color--primary);
}
.site-nav .wp-block-navigation-item.nav-study > a.wp-block-navigation-item__content {
	background: var(--wp--preset--color--primary);
	border-color: var(--wp--preset--color--primary);
	color: #ffffff;
}
.site-nav .wp-block-navigation-item.nav-study:hover > a.wp-block-navigation-item__content {
	background: #226a9c;
	border-color: #226a9c;
	color: #ffffff;
}
.site-nav .wp-block-navigation-item.nav-team > a.wp-block-navigation-item__content {
	border-color: #bcd7ee;
	background: #dcebf6; /* light blue */
	color: var(--wp--preset--color--text);
}
.site-nav .wp-block-navigation-item.nav-team:hover > a.wp-block-navigation-item__content {
	border-color: #8fbbe2;
	background: #bfd7ef; /* a bit darker blue */
	color: var(--wp--preset--color--text);
}
/* Meet the Team: same darker-blue active state as the other pills */
.site-nav .wp-block-navigation-item.nav-team.nav-current > a.wp-block-navigation-item__content {
	border-color: #7fadd7;
	background: #aecbe8; /* darker blue */
	color: var(--wp--preset--color--text);
	font-weight: 700;
}
/* Courses submenu trigger (hide the default arrow, keep the pill) */
.site-nav .wp-block-navigation-submenu .wp-block-navigation__submenu-icon {
	margin-left: 2px;
}
/* subject submenu panel */
.site-nav .wp-block-navigation__submenu-container {
	background: #ffffff;
	border: 1px solid var(--wp--preset--color--border);
	border-radius: 10px;
	box-shadow: 0 16px 36px -20px rgba(18, 49, 79, 0.32);
	padding: 8px 0;
	z-index: 70;
}
.site-nav .wp-block-navigation__submenu-container li {
	margin: 0;
}
.site-nav .wp-block-navigation__submenu-container a.wp-block-navigation-item__content {
	padding: 9px 16px;
	font-size: 0.8125rem;
	font-weight: 600;
	letter-spacing: 0.02em;
	text-transform: none;
	border: none;
	border-radius: 0;
	color: var(--wp--preset--color--text);
	white-space: nowrap;
}
.site-nav .wp-block-navigation__submenu-container a.wp-block-navigation-item__content:hover {
	color: var(--wp--preset--color--primary);
	background: var(--wp--preset--color--surface);
}

/* === buttons === */
.wp-block-button.is-style-outline .wp-element-button {
	background: transparent;
	color: var(--wp--preset--color--text);
	border: 1px solid var(--wp--preset--color--border);
}
.wp-block-button.is-style-outline .wp-element-button:hover {
	border-color: var(--wp--preset--color--primary);
	color: var(--wp--preset--color--primary);
}

/* === eyebrow label === */
.eyebrow {
	color: var(--wp--preset--color--primary);
	text-transform: uppercase;
	font-size: 0.75rem;
	letter-spacing: 0.12em;
	font-weight: 600;
}

/* === banner hero === */
.banner-hero.has-powder-background-color {
	background:
		radial-gradient(120% 90% at 85% -25%, rgba(255, 255, 255, 0.9) 0%, rgba(255, 255, 255, 0) 55%),
		linear-gradient(180deg, #ffffff 0%, var(--wp--preset--color--powder) 100%);
}
.banner-eyebrow {
	background: var(--wp--preset--color--background);
	border: 1px solid var(--wp--preset--color--border);
	border-radius: var(--wp--custom--rounded--full);
	color: var(--wp--preset--color--primary);
	font-size: var(--wp--preset--font-size--label);
	font-weight: 600;
	letter-spacing: 0.1em;
	text-transform: uppercase;
	padding: 0.5rem 1rem;
}
.banner-sub {
	max-width: 34rem;
}
.banner-image {
	border-radius: var(--wp--custom--rounded--sm);
	box-shadow: 0 14px 34px -20px rgba(18, 49, 79, 0.3);
	overflow: hidden;
	line-height: 0;
}
.banner-stats {
	border-top: 1px solid var(--wp--preset--color--border);
	padding-top: 1.5rem;
	margin-top: 3.5rem;
}
.banner-stats > p {
	font-size: var(--wp--preset--font-size--label);
	font-weight: 600;
	letter-spacing: 0.08em;
	text-transform: uppercase;
	color: var(--wp--preset--color--text);
}
.banner-stats > p + p {
	position: relative;
	padding-left: 2rem;
}
.banner-stats > p + p::before {
	content: "";
	position: absolute;
	left: 0;
	top: 50%;
	transform: translateY(-50%);
	width: 6px;
	height: 6px;
	border-radius: 999px;
	background: var(--wp--preset--color--primary);
}

/* === cards === */
.is-style-card {
	padding: 1.75rem;
	background-color: var(--wp--preset--color--background);
	border: 1px solid var(--wp--preset--color--border);
	border-radius: var(--wp--custom--rounded--sm);
	box-shadow: 0 10px 30px -18px rgba(18, 49, 79, 0.22);
	height: 100%;
}
.is-style-card:hover {
	box-shadow: 0 8px 22px rgb(18 49 79 / 0.10);
	transform: translateY(-2px);
}

/* === light-blue pill buttons (same tones as the nav pills) === */
.wp-block-button.is-pill-light a.wp-block-button__link {
	background: #dcebf6 !important;
	border-color: #bcd7ee !important;
	color: var(--wp--preset--color--text) !important;
}
.wp-block-button.is-pill-light a.wp-block-button__link:hover {
	background: #bfd7ef !important;
	border-color: #8fbbe2 !important;
	color: var(--wp--preset--color--text) !important;
}

/* === contact "Get in touch" split blocks === */
.contact-touch-light {
	background: linear-gradient(180deg, #fdeee9 0%, #fae1da 100%);
	border: 1px solid #f3c8c0;
	border-radius: 16px;
	color: var(--wp--preset--color--text);
}
.contact-touch-light .wp-block-heading {
	color: var(--wp--preset--color--text);
}
.contact-touch-red {
	background: linear-gradient(180deg, var(--wp--preset--color--powder) 0%, var(--wp--preset--color--accent) 100%);
	border-radius: 16px;
	color: #ffffff;
}
.contact-touch-red .wp-block-heading,
.contact-touch-red .wp-block-list {
	color: #ffffff;
}

/* === subject image frames === */
.subject-image,
.banner-image,
.cockpit-wide {
	border-radius: var(--wp--custom--rounded--sm);
	overflow: hidden;
	line-height: 0;
	box-shadow: 0 14px 34px -20px rgba(18, 49, 79, 0.3);
}

/* === form (WPForms contact form) === */
.contact-form-main {
	max-width: 46rem;
	margin-left: auto;
	margin-right: auto;
	padding: 2.25rem;
	background-color: var(--wp--preset--color--background);
	border: 1px solid rgba(18, 49, 79, 0.14);
	border-radius: var(--wp--custom--rounded--sm);
	box-shadow:
		inset 0 0 0 1px rgba(242, 131, 106, 0.35),
		0 34px 84px -32px rgba(18, 49, 79, 0.5),
		0 12px 30px -18px rgba(18, 49, 79, 0.28);
}
.contact-form-main .wpforms-container {
	width: 100%;
}
/* Keep the form full-width even if a Columns block wraps it (as on the live Contact page) */
.contact-form-main .wp-block-columns {
	display: block !important;
	width: 100%;
}
.contact-form-main .wp-block-columns .wp-block-column {
	width: 100% !important;
	flex-basis: 100% !important;
	margin-left: 0;
	margin-right: 0;
}
/* Light blue study-path section */
.exam-path-blue {
	background-color: #d6e8f7;
	color: #12314f;
}
.exam-path-blue .wp-block-heading,
.exam-path-blue p,
.exam-path-blue li,
.exam-path-blue .wp-block-list {
	color: #12314f;
}
.contact-form-main .wpforms-field {
	display: block;
	margin: 0 0 1.25rem;
}
.contact-form-main .wpforms-field-label {
	display: block;
	margin: 0 0 0.45rem;
	font-size: 0.8125rem;
	font-weight: 600;
	letter-spacing: 0.02em;
	color: var(--wp--preset--color--text);
}
.contact-form-main .wpforms-required-label {
	color: var(--wp--preset--color--primary);
}
.contact-form-main .wpforms-field input:not([type="hidden"]):not([type="checkbox"]):not([type="radio"]),
.contact-form-main .wpforms-field textarea,
.contact-form-main .wpforms-field select {
	width: 100%;
	box-sizing: border-box;
	padding: 13px 16px;
	font-family: inherit;
	font-size: 1rem;
	color: var(--wp--preset--color--text);
	background-color: var(--wp--preset--color--background);
	border: 1px solid var(--wp--preset--color--border);
	border-radius: var(--wp--custom--rounded--sm);
	box-shadow: none;
}
.contact-form-main .wpforms-field select {
	height: auto;
	min-height: 0;
	line-height: 1.3;
	padding-top: 13px;
	padding-bottom: 13px;
	padding-right: 44px;
	-webkit-appearance: none;
	appearance: none;
}
.contact-form-main .wpforms-field input::placeholder,
.contact-form-main .wpforms-field textarea::placeholder {
	color: rgba(18, 49, 79, 0.45);
}
.contact-form-main .wpforms-field input:focus,
.contact-form-main .wpforms-field textarea:focus,
.contact-form-main .wpforms-field select:focus {
	outline: 2px solid var(--wp--preset--color--primary);
	outline-offset: 1px;
	border-color: var(--wp--preset--color--primary);
}
.contact-form-main .wpforms-form .wpforms-submit {
	padding: 15px 34px !important;
	margin-top: 0.75rem;
	font-family: inherit !important;
	font-size: 13px !important;
	font-weight: 700 !important;
	letter-spacing: 1.3px !important;
	text-transform: uppercase !important;
	line-height: 1.2 !important;
	color: #ffffff !important;
	background-color: var(--wp--preset--color--primary) !important;
	border: 0 !important;
	border-radius: 999px !important;
	cursor: pointer;
	box-shadow: 0 10px 22px -12px rgba(18, 49, 79, 0.55) !important;
}
.contact-form-main .wpforms-form .wpforms-submit:hover {
	background-color: #1f5f8c !important;
	transform: translateY(-1px);
	box-shadow: 0 14px 26px -12px rgba(18, 49, 79, 0.6) !important;
}

/* === primary CTA band === */
.cta-primary.has-primary-background-color {
	background-color: #2a7fb8;
}
.cta-primary,
.cta-primary .wp-block-heading,
.cta-primary h1,
.cta-primary h2,
.cta-primary p {
	color: var(--wp--preset--color--background) !important;
}
.cta-primary .is-style-outline .wp-element-button {
	color: var(--wp--preset--color--background);
	border-color: rgba(255, 255, 255, 0.6);
}
.cta-primary .is-style-outline .wp-element-button:hover {
	color: rgba(255, 255, 255, 0.9);
	border-color: var(--wp--preset--color--background);
}

/* === footer on navy === */
.wp-site-blocks footer .wp-block-site-title,
.wp-site-blocks footer .wp-block-heading,
.wp-site-blocks footer h1,
.wp-site-blocks footer h2,
.wp-site-blocks footer h3 {
	color: var(--wp--preset--color--background) !important;
}
.wp-site-blocks footer p,
.wp-site-blocks footer li,
.wp-site-blocks footer .wp-block-list {
	color: var(--wp--preset--color--powder) !important;
}
.wp-site-blocks footer a {
	color: var(--wp--preset--color--powder) !important;
}
.wp-site-blocks footer a:hover {
	color: var(--wp--preset--color--background) !important;
}

/* small Australia badge */
.australia-badge {
	width: 56px;
	height: 56px;
	margin: 0 0 0.25rem;
}
.australia-badge img {
	width: 56px;
	height: 56px;
	border-radius: 999px;
	object-fit: cover;
	border: 1px solid var(--wp--preset--color--border);
}

/* === contact form band: light airfield photo with a soft wash, instead of a solid red band === */
.contact-band {
	background-image:
		linear-gradient(180deg, rgba(255, 255, 255, 0.86) 0%, rgba(255, 255, 255, 0.62) 52%, rgba(240, 152, 127, 0.42) 100%),
		url("/wp-content/uploads/2026/10/airfield.png");
	background-size: cover;
	background-position: center 20%;
}
.contact-band .wp-block-heading,
.contact-band p { position: relative; }

/* === red edge-lean bleeding into the navy footer === */
footer.wp-block-template-part > .alignfull.has-text-background-color {
	background-image:
		radial-gradient(120% 120% at 0% 0%, rgba(240, 152, 127, 0.16) 0%, rgba(240, 152, 127, 0) 55%),
		radial-gradient(130% 130% at 100% 0%, rgba(240, 152, 127, 0.16) 0%, rgba(240, 152, 127, 0) 58%),
		radial-gradient(150% 90% at 50% -40%, rgba(240, 152, 127, 0.1) 0%, rgba(240, 152, 127, 0) 55%),
		linear-gradient(180deg, rgba(240, 152, 127, 0.14) 0%, rgba(240, 152, 127, 0) 34%);
}

/* === reduced motion === */
@media (prefers-reduced-motion: reduce) {
	*,
	*::before,
	*::after {
		animation: none !important;
		transition: none !important;
	}
}

/* === responsive === */
/* Phones and tablets use the hamburger; desktop windows retain standard links. */
@media (max-width: 1024px) {
	.site-header .header-row { flex-wrap: nowrap; }
	/* Keep the native accessible navigation overlay for phones and tablets. */
	.site-nav .wp-block-navigation__responsive-container { display: none !important; }
	.site-nav .wp-block-navigation__responsive-container.is-menu-open { display: flex !important; }
	.site-nav .wp-block-navigation__responsive-container-open {
		display: flex !important;
		align-items: center;
		justify-content: center;
		gap: 6px;
		padding: 7px 11px;
		border-radius: 999px;
		border: 1px solid var(--wp--preset--color--border);
		background: var(--wp--preset--color--surface);
	}
	.site-header .site-brand-name { font-size: 1.1rem; }
	.site-brand .brand-logo,
	.site-brand .brand-logo img { width: 42px; height: 42px; }
	/* Mobile: submenus collapsed by default; expand when the parent is tapped (.is-open) */
	.site-nav .wp-block-navigation__submenu-container,
	.wp-block-navigation__responsive-container.is-menu-open .site-nav .wp-block-navigation__submenu-container {
		display: none !important;
	}
	.site-nav li.wp-block-navigation-submenu.is-open > .wp-block-navigation__submenu-container,
	.wp-block-navigation__responsive-container.is-menu-open .site-nav li.wp-block-navigation-submenu.is-open > .wp-block-navigation__submenu-container {
		display: flex !important;
	}
	.site-nav .wp-block-navigation__submenu-icon {
		display: inline-flex;
	}
}

/* === contact "Get in touch": let the badge / heading / list wrap and stack cleanly on small phones === */
@media (max-width: 600px) {
	.contact-touch-red { flex-wrap: wrap !important; }
	.contact-touch-red .wp-block-heading { flex: 1 1 auto; }
}

/* subject cards: 2-across on tablets, kept 1-across (default mobile stack) and desktop 4-across */
@media (min-width: 782px) and (max-width: 900px) {
	.subject-grid {
		flex-wrap: wrap !important;
	}
	.subject-grid .wp-block-column {
		flex: 0 0 calc(50% - 12px) !important;
	}
}

