/* GIGW 3.0 / WCAG 2.1 AA shared overrides for iLearn inner pages (16 Oct 2026) */

/* 2.4.7 visible keyboard focus */
a:focus-visible, button:focus-visible, input:focus-visible, select:focus-visible,
textarea:focus-visible, [tabindex]:focus-visible, summary:focus-visible {
  outline: 3px solid #0B3D91 !important; outline-offset: 2px !important; box-shadow: 0 0 0 5px #ffffff !important;
}

/* 1.4.3 / 1.4.11 contrast: brand blue #2680EB (3.91:1) -> #1565C0 (5.75:1 on white) */
.btn-primary, .btn-primary:hover, .btn-primary:focus, .btn-primary:active, .btn-primary:disabled {
  background-color: #1565C0 !important; border-color: #1565C0 !important; color: #ffffff !important;
}
.btn-outline-primary { color: #1565C0 !important; border-color: #1565C0 !important; }
.btn-outline-primary:hover, .btn-outline-primary:focus { background-color: #1565C0 !important; color: #ffffff !important; }
.text-primary, [style*="color:#2680EB" i], [style*="color: #2680EB" i] { color: #1565C0 !important; }
.float-fb { background-color: #0A66C2 !important; }
.float-tw { background-color: #00629B !important; }
.float-ig { background-color: #C2185B !important; }
.float-pn { background-color: #C62828 !important; }
.float-rs { background-color: #8E24AA !important; }
#headerSearch, .header-search input { color: #1F2933 !important; }
#headerSearch::placeholder, .header-search input::placeholder { color: #4B5563 !important; opacity: 1; }

.breadcrumb-item.active, .text-muted { color: #565E66 !important; }
#searchToggle, #searchToggle:hover, #searchToggle:focus { background-color: #1565C0 !important; border-color: #1565C0 !important; color: #ffffff !important; }

/* Google Translate gadget in the dark footer: its own greys fail 4.5:1 */
.goog-te-gadget, .goog-te-gadget a, .goog-te-gadget .goog-logo-link { color: #ffffff !important; }
.goog-te-gadget select, .goog-te-gadget .goog-te-combo { color: #212529 !important; }

/* heading added by script when a page has no <h1> */
.gigw-h1 { position: absolute !important; width: 1px; height: 1px; margin: -1px; padding: 0; overflow: hidden;
  clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0; }

/* the main-content target should not draw a ring when focused by the skip link */
#main-content:focus { outline: none; }

/* 1.4.10 reflow at 320 px */
@media (max-width: 575.98px) {
  .header-wrapper { flex-wrap: wrap; }
  .header-login { margin-left: auto; }
  html, body { overflow-x: hidden; }
  img, iframe, table { max-width: 100%; }
}

/* 2.4.1 skip link for pages that did not have one (visible only while focused) */
.gigw-skip { position: absolute; left: 8px; top: -60px; z-index: 100000; background: #0B3D91; color: #ffffff !important;
  padding: 8px 14px; border-radius: 0 0 4px 4px; font-size: 16px; text-decoration: underline; }
.gigw-skip:focus { top: 0; }

/* keeps the old look after duplicate ids were turned into classes / list gaps */
#benefits .gigw-content { margin-top: 100px !important; }
.gigw-gap { list-style: none; height: 1em; }

/* course explorer tab links: Bootstrap blue #0d6efd is 4.3:1 on the light background */
a[data-toggle="pill"]:not(.active), a[data-bs-toggle="pill"]:not(.active) { color: #0A58CA !important; }

.gigw-filemeta { font-size: .9em; white-space: nowrap; }

/* ---- Compact header tools (search + language) ----
   Labels/hint stay in the DOM for screen readers (aria-labelledby / aria-describedby)
   but are visually hidden so the header is one tidy row. */
.header-tools{justify-content:space-between;flex-wrap:wrap;gap:.5rem 1rem;padding:.25rem 10px}
.header-search-label,.header-search-hint,.header-language-label{position:absolute!important;width:1px;height:1px;margin:-1px;padding:0;border:0;overflow:hidden;clip:rect(0 0 0 0);clip-path:inset(50%);white-space:nowrap}
.header-search{flex:1 1 20rem;max-width:34rem;margin:0}
.header-search-row{width:100%}
.header-search input{flex:1 1 auto;width:auto;min-width:0}
.header-language-control{flex:0 0 auto;margin:0}

/* ---- Policy / document pages ---- */
.gigw-doc{max-width:62rem;line-height:1.7;color:#212529}
.gigw-doc h1{font-size:1.9rem;margin-bottom:1rem}
.gigw-doc h2{font-size:1.4rem;margin-top:1.8rem;margin-bottom:.6rem;color:#0B3D91}
.gigw-doc h3{font-size:1.15rem;margin-top:1.2rem;margin-bottom:.4rem}
.gigw-doc p,.gigw-doc li{font-size:1rem}
.gigw-doc ul,.gigw-doc ol{padding-left:1.5rem}
.gigw-doc ul.gigw-items{list-style:none;padding-left:0}
.gigw-doc table{width:100%;margin:1rem 0}
.gigw-doc caption{caption-side:top;font-weight:600;color:#212529;padding:.4rem 0}
.gigw-doc th{background:#E8EEF7;color:#212529;text-align:left}
.gigw-doc .gigw-docnote{background:#F1F6FB;border-left:4px solid #0B3D91;padding:.6rem .9rem}
.gigw-doc .gigw-langswitch{text-align:right;margin-bottom:.5rem}
.gigw-doc .gigw-langswitch a{font-weight:600;color:#0A58CA;text-decoration:underline}
.gigw-doc a{color:#0A58CA;text-decoration:underline}
.gigw-doc .gigw-docctl{max-width:40rem;margin-top:2rem}
.gigw-hindi{font-weight:600}

/* Primary navigation for pages that use the shared header (views/header.html) */
.gigw-hdr .main-menu1{list-style:none;padding:0;margin:0}
.gigw-hdr .main-menu1>li{position:relative;display:inline-block;padding:10px 15px}
.gigw-hdr .sub-menu1{display:none;position:absolute;top:100%;left:0;width:200px;background:#fff;box-shadow:0 4px 8px rgba(0,0,0,.1);padding:10px 0;border-radius:5px;border-top:2px solid #2608EB;z-index:999}
.gigw-hdr .main-menu1 li:hover>.sub-menu1,.gigw-hdr .main-menu1 li:focus-within>.sub-menu1{display:block}
.gigw-hdr .sub-menu1 li{position:relative;list-style:none}
.gigw-hdr .sub-menu1 li a{display:block;padding:8px 15px;text-decoration:none;color:#000;font-size:14px}
.gigw-hdr .sub-menu1 li a:hover{background:#f0f0f0}
.gigw-hdr .sub-menu1 .sub-menu1{left:100%;top:0;display:none}
.gigw-hdr .sub-menu1 li:hover>.sub-menu1,.gigw-hdr .sub-menu1 li:focus-within>.sub-menu1{display:block}

/* High-contrast view: the page body turns black and its text white, but the header stays white, so the main-menu links (which inherit the body colour) would be invisible. Applies only while high contrast is switched on. */
body[style*="background-color: black"] #header .main-menu1>li>a,body[style*="background-color: black"] #header .main-menu>li>a{color:#333}
body[style*="background-color: black"] #header .main-menu1>li:hover>a,body[style*="background-color: black"] #header .main-menu1>li:focus-within>a,body[style*="background-color: black"] #header .main-menu>li:hover>a,body[style*="background-color: black"] #header .main-menu>li:focus-within>a{color:#1565C0}

/* Escape key closes an open hover/focus sub-menu (WCAG 1.4.13). Class is set by gigw-a11y.js. */
.gigw-menu-dismissed .main-menu1 .sub-menu1{display:none !important}
