/* UI audit (15 Nov 2026, tools/apply-ui-audit-20261115.mjs). Phone, animation and worst-case-data fixes; a mouse at
   1280 sees the page as before. Linked after every other stylesheet, so equal specificity wins without !important. */

/* No grey or blue flash over a tapped link or button: each control has its own :active state (see gateHover). */
html{-webkit-tap-highlight-color:transparent}
/* Taps fire at once: these never double-tap-zoom. */
:is(a,button,summary,select,label,input,textarea,[role="button"]){touch-action:manipulation}
/* A long press on a control does not select its label. Content text stays selectable. */
:is(button,summary,[role="tab"]){-webkit-user-select:none;user-select:none}

/* Headings: a long word (a compound, a standard reference) breaks instead of pushing the page sideways. Phones only, so
   no desktop line box changes; "anywhere" also lets the single-column grids around the hero headings shrink. */
@media(max-width:671px){main :is(h1,h2,h3){overflow-wrap:anywhere}}

/* iOS zooms into a focused field whose text is under 16px and does not zoom back. The header currency select draws no
   text of its own (its code is a separate label), so only its focus zoom changes. */
@media(pointer:coarse){
 html[data-theme] .site-header .uk-nav-currency select{font-size:16px}
 .nz-card-course-language select,.purchase-course-language select,#checkout-course-language{font-size:16px}
}

/* Tap targets: the header logo and the footer links are at least 44px tall on touch (the theme toggle, menu button,
   currency field and Region rows already are). Block links stay block-level (flex), inline links stay inline (inline-flex,
   wrapping at the <wbr> in the mailbox addresses); the 44px rows replace the lists' 10px gap and the legal row's 8px. */
@media(pointer:coarse){
 :is(.site-header,.header) .regional-brand{min-height:44px}
 #site-footer.footer--au .site-footer__brand{min-height:44px}
 #site-footer.footer--au :is(.site-footer__contact a,.site-footer__legal a){display:flex;align-items:center;min-height:44px}
 #site-footer.footer--au .site-footer__col li a{display:inline-flex;flex-wrap:wrap;align-items:center;min-height:44px}
 #site-footer.footer--au .site-footer__col ul{gap:0}
 #site-footer.footer--au .site-footer__legal nav{row-gap:0}
}

/* Menu blur (owner decision 13 Nov 2026, kept): the filter fades in 100ms (was 160ms); none under reduced motion. The
   dropdowns already open after 120ms of hover intent (app.js), so sweeping across the nav does not blur the page. */
main,.site-footer,.course-enrol-bar,main>.about-page>*{transition:filter 100ms var(--ease)}
@media (prefers-reduced-motion:reduce){main,.site-footer,.course-enrol-bar,main>.about-page>*{transition:none}}

/* Scrolling panels: the visible viewport height with a 100vh fallback for browsers without dvh (without one the
   declaration was dropped and a long mobile menu could not scroll), and scrolling inside a panel does not scroll the
   page behind it. */
@media(max-width:1180px){.site-header .regional-inner #primary-nav{max-height:calc(100vh - var(--header));max-height:calc(100dvh - var(--header));overscroll-behavior:contain}}
@media(min-width:851px){.site-header .mega{max-height:calc(100vh - var(--header) - var(--space-4));max-height:calc(100dvh - var(--header) - var(--space-4))}}
.site-header .site-header-knowledge-panel > div:not([aria-hidden]){max-height:calc(100vh - 100px);max-height:calc(100dvh - 100px);overscroll-behavior:contain}
.uk-nz-dialog[open]{max-height:calc(100vh - 32px);max-height:calc(100dvh - 32px);overscroll-behavior:contain}
@media(min-width:1200px) and (min-height:700px){
 .about-rail{top:calc((100vh + var(--header))/2);top:calc((100dvh + var(--header))/2)}
 .about-rail details{max-height:calc(100vh - var(--header) - var(--space-7));max-height:calc(100dvh - var(--header) - var(--space-7));overscroll-behavior:contain}
}
