/* IGE Solutions — bilingual A/L learning platform styles. */
@font-face { font-family: 'Noto Sans Sinhala'; font-weight: 400; font-display: swap; src: url(/fonts/noto-sans-sinhala-sinhala-400-normal.woff2) format('woff2'); unicode-range: U+0964-0965, U+0D81-0DF4, U+1CF2, U+200C-200D, U+25CC, U+111E1-111F4; }
@font-face { font-family: 'Noto Sans Sinhala'; font-weight: 500; font-display: swap; src: url(/fonts/noto-sans-sinhala-sinhala-500-normal.woff2) format('woff2'); unicode-range: U+0964-0965, U+0D81-0DF4, U+1CF2, U+200C-200D, U+25CC, U+111E1-111F4; }
@font-face { font-family: 'Noto Sans Sinhala'; font-weight: 600; font-display: swap; src: url(/fonts/noto-sans-sinhala-sinhala-600-normal.woff2) format('woff2'); unicode-range: U+0964-0965, U+0D81-0DF4, U+1CF2, U+200C-200D, U+25CC, U+111E1-111F4; }
@font-face { font-family: 'Noto Sans Sinhala'; font-weight: 700; font-display: swap; src: url(/fonts/noto-sans-sinhala-sinhala-700-normal.woff2) format('woff2'); unicode-range: U+0964-0965, U+0D81-0DF4, U+1CF2, U+200C-200D, U+25CC, U+111E1-111F4; }
@font-face { font-family: 'Noto Sans Sinhala'; font-weight: 800; font-display: swap; src: url(/fonts/noto-sans-sinhala-sinhala-800-normal.woff2) format('woff2'); unicode-range: U+0964-0965, U+0D81-0DF4, U+1CF2, U+200C-200D, U+25CC, U+111E1-111F4; }
@font-face { font-family: 'Noto Sans Sinhala'; font-weight: 400; font-display: swap; src: url(/fonts/noto-sans-sinhala-latin-400-normal.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: 'Noto Sans Sinhala'; font-weight: 500; font-display: swap; src: url(/fonts/noto-sans-sinhala-latin-500-normal.woff2) format('woff2'); unicode-range: U+0000-00FF, U+2000-206F, U+2212; }
@font-face { font-family: 'Noto Sans Sinhala'; font-weight: 600; font-display: swap; src: url(/fonts/noto-sans-sinhala-latin-600-normal.woff2) format('woff2'); unicode-range: U+0000-00FF, U+2000-206F, U+2212; }
@font-face { font-family: 'Noto Sans Sinhala'; font-weight: 700; font-display: swap; src: url(/fonts/noto-sans-sinhala-latin-700-normal.woff2) format('woff2'); unicode-range: U+0000-00FF, U+2000-206F, U+2212; }
@font-face { font-family: 'Noto Sans Sinhala'; font-weight: 800; font-display: swap; src: url(/fonts/noto-sans-sinhala-latin-800-normal.woff2) format('woff2'); unicode-range: U+0000-00FF, U+2000-206F, U+2212; }
@font-face { font-family: 'Abhaya Libre'; font-weight: 600; font-display: swap; src: url(/fonts/abhaya-libre-sinhala-600-normal.woff2) format('woff2'); unicode-range: U+0964-0965, U+0D81-0DF4, U+200C-200D, U+25CC; }
@font-face { font-family: 'Abhaya Libre'; font-weight: 800; font-display: swap; src: url(/fonts/abhaya-libre-sinhala-800-normal.woff2) format('woff2'); unicode-range: U+0964-0965, U+0D81-0DF4, U+200C-200D, U+25CC; }
@font-face { font-family: 'Abhaya Libre'; font-weight: 600; font-display: swap; src: url(/fonts/abhaya-libre-latin-600-normal.woff2) format('woff2'); unicode-range: U+0000-00FF, U+2000-206F; }
@font-face { font-family: 'Abhaya Libre'; font-weight: 800; font-display: swap; src: url(/fonts/abhaya-libre-latin-800-normal.woff2) format('woff2'); unicode-range: U+0000-00FF, U+2000-206F; }

:root {
  /* IGE brand palette (from the logo): navy → royal blue → sky → teal → green */
  --ige-navy: #0b2a66; --ige-navy-2: #0e3a8c; --ige-blue: #1565d8; --ige-sky: #1e9bf0; --ige-teal: #12b5a6; --ige-green: #3ee07f;
  --ige-grad: linear-gradient(90deg, #1565d8 0%, #1e9bf0 45%, #12b5a6 78%, #3ee07f 100%);
  --paper: #f6f9fc;
  --paper-2: #ffffff;
  --grid: #dce8f3;
  --grid-strong: #c3d6ea;
  --ink: #14213d;
  --ink-2: #3c4a66;
  --ink-3: #6a7790;
  --pen: #1565d8;          /* IGE royal blue */
  --pen-soft: #e3ebff;
  --brass: #b9862c;
  --brass-soft: #f6ead2;
  --red: #d0342c;          /* examiner's red pen */
  --red-soft: #fde8e6;
  --green: #12875a;
  --green-soft: #dff4ea;
  --line: #d6e0ec;
  --shadow: 0 1px 0 #c9d6e6, 0 6px 18px -10px rgba(20, 33, 61, .35);
  --radius-s: 6px; --radius: 12px; --radius-l: 20px;
  --font: 'Noto Sans Sinhala', system-ui, 'Segoe UI', Roboto, sans-serif;
  --display: 'Abhaya Libre', 'Noto Sans Sinhala', Georgia, serif;
  --topbar: 60px;
  color-scheme: light;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --paper: #0e1828; --paper-2: #142238; --grid: #1a2a42; --grid-strong: #223654; --ink: #e8eef8; --ink-2: #b8c4d8; --ink-3: #8394ad;
    --pen: #5aa9ff; --pen-soft: #13305e; --brass: #e0ac4e; --brass-soft: #3a2e17; --red: #ff6b5e; --red-soft: #3e1d1b; --green: #3ccf8e; --green-soft: #133426;
    --line: #253756; --shadow: 0 1px 0 #0a1220, 0 8px 22px -12px rgba(0,0,0,.7); color-scheme: dark;
  }
}
:root[data-theme="dark"] {
  --paper: #0e1828; --paper-2: #142238; --grid: #1a2a42; --grid-strong: #223654; --ink: #e8eef8; --ink-2: #b8c4d8; --ink-3: #8394ad;
  --pen: #5aa9ff; --pen-soft: #13305e; --brass: #e0ac4e; --brass-soft: #3a2e17; --red: #ff6b5e; --red-soft: #3e1d1b; --green: #3ccf8e; --green-soft: #133426;
  --line: #253756; --shadow: 0 1px 0 #0a1220, 0 8px 22px -12px rgba(0,0,0,.7); color-scheme: dark;
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0; font-family: var(--font); font-size: 16px; line-height: 1.6; color: var(--ink);
  background-color: var(--paper);
  background-image:
    linear-gradient(var(--grid) 1px, transparent 1px),
    linear-gradient(90deg, var(--grid) 1px, transparent 1px);
  background-size: 24px 24px;
  background-attachment: fixed;
  min-height: 100vh;
}
img { max-width: 100%; }
a { color: var(--pen); }
button, input, select, textarea { font: inherit; color: inherit; }
:focus-visible { outline: 3px solid var(--pen); outline-offset: 2px; border-radius: 4px; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
@media (prefers-reduced-motion: reduce) { *, *::before, *::after { animation: none !important; transition: none !important; } }

/* ── top bar (IGE navy with logo-gradient accent) ── */
.topbar {
  position: sticky; top: 0; z-index: 40; height: var(--topbar); display: flex; align-items: center; gap: 14px;
  padding: 0 clamp(12px, 3vw, 28px); color: #fff;
  background: linear-gradient(100deg, var(--ige-navy) 0%, var(--ige-navy-2) 62%, #0c4aa6 100%);
  box-shadow: 0 6px 18px -12px rgba(11, 42, 102, .8);
}
.topbar::after { content: ''; position: absolute; left: 0; right: 0; bottom: -3px; height: 3px; background: var(--ige-grad); }
.brand { display: flex; align-items: center; gap: 10px; line-height: 1.12; text-decoration: none; color: #fff; font-family: var(--display); font-weight: 800; font-size: 20px; letter-spacing: .2px; white-space: nowrap; }
.brand-logo { display: grid; place-items: center; height: 44px; padding: 3px 9px; border-radius: 12px; background: #fff; box-shadow: 0 2px 8px rgba(0, 0, 0, .25); }
.brand-logo img { height: 36px; width: auto; display: block; }
.brand small { font-family: var(--font); font-weight: 600; font-size: 12px; color: #a9c8f5; }
.topnav { display: flex; gap: 4px; margin-left: 12px; }
.topnav a { text-decoration: none; color: #d6e6ff; padding: 6px 13px; border-radius: 999px; font-weight: 600; font-size: 14px; transition: background .15s, color .15s; }
.topnav a:hover { background: rgba(255, 255, 255, .1); color: #fff; }
.topnav a[aria-current="page"] { background: linear-gradient(90deg, var(--ige-blue), var(--ige-teal)); color: #fff; box-shadow: 0 2px 10px -2px rgba(18, 181, 166, .6); }
.topbar .btn.ghost { color: #fff; border-color: rgba(255, 255, 255, .7); background: transparent; box-shadow: none; }
.topbar .btn.pen { background: linear-gradient(90deg, var(--ige-blue), var(--ige-teal)); border-color: transparent; box-shadow: none; }
.topbar .spacer { flex: 1; }
.chip { display: inline-flex; align-items: center; gap: 6px; padding: 4px 10px; border-radius: 999px; font-weight: 700; font-size: 13px; border: 1.5px solid var(--line); background: var(--paper-2); white-space: nowrap; }
.topbar .chip { background: rgba(255, 255, 255, .08); }
.topbar .chip.xp { border-color: #f2c35c; color: #ffd77a; }
.topbar .chip.streak { border-color: #ff8a7a; color: #ffb2a6; }
.topbar .iconbtn { background: rgba(255, 255, 255, .08); border-color: rgba(255, 255, 255, .35); color: #fff; }
.topbar .iconbtn .dot { border-color: var(--ige-navy); }
.topbar .avatar { background: linear-gradient(135deg, var(--ige-sky), var(--ige-teal)); box-shadow: 0 0 0 2px rgba(255, 255, 255, .85); }
.chip.xp { border-color: var(--brass); color: var(--brass); }
.chip.streak { border-color: var(--red); color: var(--red); }
.iconbtn { width: 38px; height: 38px; display: inline-grid; place-items: center; border-radius: 50%; border: 1.5px solid var(--line); background: var(--paper-2); cursor: pointer; position: relative; }
.iconbtn .dot { position: absolute; top: 4px; right: 4px; width: 9px; height: 9px; border-radius: 50%; background: var(--red); border: 2px solid var(--paper-2); }
.avatar { width: 38px; height: 38px; border-radius: 50%; display: grid; place-items: center; background: var(--ige-blue); color: #fff; font-weight: 800; text-decoration: none; }

.bottomnav { display: none; }
@media (max-width: 760px) {
  .topnav, .chip.streak, .hide-sm { display: none !important; }
  .bottomnav {
    display: grid; grid-template-columns: repeat(5, 1fr); position: fixed; bottom: 0; left: 0; right: 0; z-index: 40;
    background: var(--ige-navy); border-top: 3px solid transparent; border-image: var(--ige-grad) 1; padding: 4px 4px calc(4px + env(safe-area-inset-bottom));
  }
  .bottomnav a { display: grid; justify-items: center; gap: 0; text-decoration: none; color: #9fbbe6; font-size: 11px; font-weight: 600; padding: 4px 0; border-radius: 10px; }
  .bottomnav a span:first-child { font-size: 20px; line-height: 1.2; }
  .bottomnav a[aria-current="page"] { color: #fff; background: linear-gradient(180deg, rgba(30, 155, 240, .35), rgba(18, 181, 166, .25)); }
  main { padding-bottom: 86px !important; }
}

main:focus { outline: none; }
main { max-width: 1180px; margin: 0 auto; padding: clamp(16px, 3vw, 32px) clamp(16px, 3vw, 28px) 64px; }
.wide main, main.wide { max-width: 1440px; }

/* ── type ── */
h1, h2, h3 { font-family: var(--display); line-height: 1.2; margin: 0 0 .4em; color: var(--ink); }
h1 { font-size: clamp(30px, 5vw, 46px); font-weight: 800; }
h2 { font-size: clamp(24px, 3.4vw, 32px); font-weight: 800; }
h3 { font-size: 21px; font-weight: 800; }
p { margin: 0 0 .8em; }
.lead { font-size: 18px; color: var(--ink-2); max-width: 62ch; }
.muted { color: var(--ink-3); }
.small { font-size: 14px; }
.en { font-size: .86em; color: var(--ink-3); }

/* ── surfaces ── */
.sheet { background: var(--paper-2); border: 1.5px solid var(--ink); border-radius: var(--radius); box-shadow: 4px 4px 0 var(--ink); }
.panel { background: var(--paper-2); border: 1px solid var(--line); border-radius: var(--radius); }
.pad { padding: clamp(16px, 2.6vw, 26px); }
.stack > * + * { margin-top: 14px; }
.row { display: flex; gap: 12px; align-items: center; flex-wrap: wrap; }
.grid2 { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 320px), 1fr)); gap: 18px; }
.grid3 { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 240px), 1fr)); gap: 16px; }

/* ── buttons ── */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 44px; padding: 10px 18px; border-radius: 999px;
  border: 1.5px solid var(--ink); background: var(--ink); color: var(--paper-2); font-weight: 700; cursor: pointer; text-decoration: none;
  transition: transform .08s ease, box-shadow .08s ease; box-shadow: 2px 2px 0 var(--pen);
}
.btn:hover { transform: translate(-1px, -1px); box-shadow: 3px 3px 0 var(--pen); }
.btn:active { transform: translate(1px, 1px); box-shadow: 0 0 0 var(--pen); }
.btn.pen { background: linear-gradient(90deg, var(--ige-blue), #1d86ea); border-color: var(--ige-blue); color: #fff; box-shadow: 2px 2px 0 var(--ink); }
.btn.ghost { background: transparent; color: var(--ink); box-shadow: none; }
.btn.ghost:hover { background: var(--pen-soft); }
.btn.brass { background: var(--brass); border-color: var(--brass); color: #1b1404; box-shadow: 2px 2px 0 var(--ink); }
.btn.danger { background: var(--red); border-color: var(--red); color: #fff; box-shadow: 2px 2px 0 var(--ink); }
.btn.sm { min-height: 34px; padding: 5px 12px; font-size: 14px; }
.btn.block { width: 100%; }
.btn[disabled] { opacity: .5; cursor: not-allowed; transform: none; }

/* ── forms ── */
label.field { display: grid; gap: 4px; font-weight: 600; font-size: 14px; color: var(--ink-2); }
.input, select.input, textarea.input {
  width: 100%; padding: 11px 13px; border-radius: var(--radius-s); border: 1.5px solid var(--grid-strong); background: var(--paper-2);
  font-size: 16px; color: var(--ink);
}
.input:focus { border-color: var(--pen); outline: none; box-shadow: 0 0 0 3px var(--pen-soft); }
.form-error { color: var(--red); font-weight: 600; font-size: 14px; min-height: 1.2em; }

/* ── portal (subject chooser) ── */
.portal-hero { display: grid; grid-template-columns: 1.1fr .9fr; gap: 28px; align-items: center; margin: 8px 0 34px; }
.portal-hero h1 { font-size: clamp(34px, 6vw, 60px); letter-spacing: -.5px; }
.formula-card { position: relative; aspect-ratio: 5 / 4; }
.formula-card svg { width: 100%; height: 100%; }
@media (max-width: 860px) { .portal-hero { grid-template-columns: 1fr; } .formula-card { max-width: 420px; } }
.ige-banner { margin: 0 0 26px; border-radius: var(--radius-l); overflow: hidden; box-shadow: 0 14px 34px -18px rgba(11, 42, 102, .55); border: 1px solid var(--line); background: #eaf4ff; }
.ige-banner img { display: block; width: 100%; height: auto; }
@media (max-width: 760px) { .ige-banner { margin: -4px 0 18px; border-radius: var(--radius); } }
.grad-text { background: var(--ige-grad); -webkit-background-clip: text; background-clip: text; color: transparent; }
/* learning-mode switch */
.mode-card { background: var(--paper-2); border-radius: var(--radius-l); padding: clamp(16px, 2.4vw, 24px); position: relative;
  border: 2px solid transparent; background-image: linear-gradient(var(--paper-2), var(--paper-2)), var(--ige-grad); background-origin: border-box; background-clip: padding-box, border-box;
  box-shadow: 0 16px 36px -22px rgba(11, 42, 102, .6); }
.mode-head { display: flex; justify-content: space-between; align-items: baseline; gap: 10px; flex-wrap: wrap; margin-bottom: 12px; }
.mode-head h3 { margin: 0; }
.mode-now { font-size: 13px; font-weight: 700; color: var(--pen); }
.mode-opts { display: grid; gap: 10px; }
.mode-opt { display: flex; gap: 12px; align-items: flex-start; text-align: left; width: 100%; padding: 12px 14px; border-radius: 14px; cursor: pointer;
  border: 1.5px solid var(--line); background: var(--paper); transition: border-color .15s, box-shadow .15s, transform .15s; }
.mode-opt:hover { border-color: var(--ige-sky); transform: translateY(-1px); }
.mode-opt .mi { font-size: 26px; line-height: 1.2; }
.mode-opt .mt { display: block; line-height: 1.4; }
.mode-opt small { display: block; margin-top: 3px; color: var(--ink-3); font-size: 13px; }
.mode-opt.on { border-color: transparent; background: linear-gradient(120deg, rgba(21, 101, 216, .12), rgba(18, 181, 166, .14)); box-shadow: 0 0 0 2px var(--ige-blue) inset; }
.mode-opt.on b::after { content: ' ✓'; color: var(--ige-teal); }
.mode-pill { display: inline-flex; align-items: center; gap: 6px; font-size: 13px; font-weight: 700; padding: 3px 10px; border-radius: 999px; text-decoration: none;
  color: #fff; background: linear-gradient(90deg, var(--ige-blue), var(--ige-teal)); }
.mode-pill.quest { background: var(--pen-soft); color: var(--pen); }
.subjects { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 250px), 1fr)); gap: 16px; }
.subject {
  position: relative; display: grid; gap: 6px; padding: 20px; text-decoration: none; color: var(--ink); min-height: 168px;
  background: var(--paper-2); border: 1.5px solid var(--ink); border-radius: var(--radius); box-shadow: 4px 4px 0 var(--ink);
}
.subject .ico { font-size: 34px; }
.subject h3 { margin: 0; }
.subject.live:hover { box-shadow: 6px 6px 0 var(--pen); transform: translate(-2px, -2px); }
.subject.soon { border-style: dashed; box-shadow: none; color: var(--ink-3); background: transparent; }
.subject.soon h3 { color: var(--ink-3); }
.tag { display: inline-block; font-size: 12px; font-weight: 700; padding: 2px 9px; border-radius: 999px; background: var(--pen-soft); color: var(--pen); width: fit-content; }
.tag.soon { background: var(--line); color: var(--ink-2); }
.tag.green { background: var(--green-soft); color: var(--green); }
.tag.red { background: var(--red-soft); color: var(--red); }
.tag.brass { background: var(--brass-soft); color: var(--brass); }

/* ── level map ── */
.mapwrap { display: grid; grid-template-columns: minmax(0, 1fr) 320px; gap: 26px; align-items: start; }
@media (max-width: 980px) { .mapwrap { grid-template-columns: 1fr; } }
.unit-block { margin-bottom: 26px; }
.unit-head { display: flex; align-items: baseline; gap: 12px; margin: 0 0 10px; border-bottom: 1.5px solid var(--ink); padding-bottom: 6px; }
.unit-head h3 { margin: 0; }
.trail { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 280px), 1fr)); gap: 12px; }
.lvl {
  display: grid; grid-template-columns: 54px 1fr; gap: 12px; align-items: center; padding: 12px; text-decoration: none; color: var(--ink);
  background: var(--paper-2); border: 1.5px solid var(--line); border-radius: var(--radius); position: relative; min-height: 86px;
}
.lvl .num {
  width: 54px; height: 54px; border-radius: 50%; display: grid; place-items: center; font-weight: 800; font-size: 18px;
  border: 2px solid var(--ink); background: var(--paper); font-family: var(--display);
}
.lvl .t { font-weight: 700; font-size: 14.5px; line-height: 1.35; }
.lvl .meta { display: flex; gap: 8px; align-items: center; margin-top: 4px; font-size: 12px; color: var(--ink-3); }
.stars { color: var(--brass); letter-spacing: 1px; font-size: 14px; }
.stars .off { color: var(--line); }
.lvl.current { border-color: var(--pen); border-width: 2px; box-shadow: 3px 3px 0 var(--pen); }
.lvl.current .num { background: var(--ige-blue); color: #fff; border-color: var(--ige-blue); animation: pulse 2.2s ease-in-out infinite; }
.lvl.done .num { background: var(--ink); color: var(--paper-2); }
.lvl.locked { opacity: .55; }
.lvl.locked .num { border-style: dashed; }
@keyframes pulse { 0%, 100% { box-shadow: 0 0 0 0 rgba(31,79,209,.45); } 50% { box-shadow: 0 0 0 9px rgba(31,79,209,0); } }
.side-card { position: sticky; top: calc(var(--topbar) + 16px); }
.progress { height: 12px; border-radius: 999px; background: var(--line); overflow: hidden; border: 1px solid var(--grid-strong); }
.progress > i { display: block; height: 100%; background: repeating-linear-gradient(45deg, var(--pen), var(--pen) 6px, #3e6ae6 6px, #3e6ae6 12px); }
.progress.brass > i { background: var(--brass); }
.final-paper { border: 2px dashed var(--brass); border-radius: var(--radius); padding: 18px; background: var(--brass-soft); }

/* ── level page ── */
.level-head { display: grid; gap: 6px; margin-bottom: 14px; }
.tabs { display: flex; gap: 6px; border-bottom: 1.5px solid var(--ink); margin-bottom: 18px; overflow-x: auto; scrollbar-width: none; }
.tabs button {
  border: 1.5px solid transparent; border-bottom: none; background: transparent; padding: 10px 16px; font-weight: 700; cursor: pointer; color: var(--ink-3);
  border-radius: 10px 10px 0 0; white-space: nowrap; margin-bottom: -1.5px;
}
.tabs button[aria-selected="true"] { background: var(--paper-2); color: var(--ink); border-color: var(--ink); }
.tabs button .ok { color: var(--green); }
.lesson { max-width: 78ch; }
.lesson h3 { margin-top: 1.2em; }
.lesson ol, .lesson ul { padding-left: 1.3em; }
.lesson li { margin: .3em 0; }
.formula { display: block; padding: 12px 16px; margin: 10px 0; border-left: 4px solid var(--pen); background: var(--pen-soft); border-radius: 0 8px 8px 0; font-weight: 600; font-size: 17px; }
.trap { padding: 12px 16px; border-radius: 10px; background: var(--red-soft); border: 1px solid color-mix(in srgb, var(--red) 40%, transparent); }
.parts-fig { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 220px), 1fr)); gap: 10px; }
.part-name { display: flex; gap: 10px; align-items: baseline; padding: 8px 10px; border-bottom: 1px dashed var(--line); }
.part-name b { min-width: 1.6em; color: var(--pen); }

/* ── 3D lab ── */
.lab { display: grid; grid-template-columns: minmax(0, 1fr) 360px; gap: 16px; }
@media (max-width: 1000px) { .lab { grid-template-columns: 1fr; } }
.stage {
  position: relative; border: 1.5px solid var(--ink); border-radius: var(--radius); overflow: hidden; background: #1b2638;
  min-height: 420px; height: min(72vh, 640px); touch-action: none; user-select: none;
}
@media (max-width: 760px) { .stage { height: 62vh; min-height: 360px; } }
.stage canvas { display: block; width: 100%; height: 100%; }
.stage .hud { position: absolute; left: 10px; top: 10px; display: flex; gap: 6px; flex-wrap: wrap; pointer-events: none; }
.stage .hud .chip { pointer-events: auto; background: rgba(255,255,255,.92); color: #14213d; border-color: #14213d; }
.stage .tools { position: absolute; right: 10px; top: 10px; display: grid; gap: 6px; }
.stage .tools button { width: 40px; height: 40px; border-radius: 10px; border: 1.5px solid #14213d; background: rgba(255,255,255,.92); cursor: pointer; font-size: 18px; color: #14213d; }
.stage .tools button[aria-pressed="true"] { background: #1f4fd1; color: #fff; }
.stage .hint { position: absolute; left: 50%; top: 10px; transform: translateX(-50%); background: rgba(20,33,61,.86); color: #fff; padding: 8px 14px; border-radius: 999px; font-size: 13.5px; max-width: calc(100% - 130px); text-align: center; pointer-events: none; z-index: 3; transition: opacity .6s; }
@media (max-width: 640px) { .stage .hint { left: 10px; right: 58px; top: 48px; transform: none; max-width: none; border-radius: 12px; font-size: 12.5px; line-height: 1.45; padding: 7px 11px; } }
.loupe {
  position: absolute; width: 220px; height: 220px; border-radius: 50%; border: 4px solid #b9862c; box-shadow: 0 10px 30px rgba(0,0,0,.45), inset 0 0 0 2px rgba(255,255,255,.5);
  overflow: hidden; pointer-events: none; display: none; background: #fff;
}
.loupe canvas { width: 100%; height: 100%; }
.loupe.on { display: block; }
@media (max-width: 760px) { .loupe { width: 160px; height: 160px; } .zoomview, .zoomview.big { left: 8px; right: 8px; width: auto; aspect-ratio: 16 / 7; bottom: 8px; } .zoomview.big { aspect-ratio: 16 / 11; } }
.zoomview { position: absolute; right: 10px; bottom: 10px; width: min(44%, 420px); aspect-ratio: 16 / 10; border: 3px solid #b9862c; border-radius: 12px; overflow: hidden; background: #fff; box-shadow: 0 8px 24px rgba(0,0,0,.4); }
.zoomview canvas { width: 100%; height: 100%; display: block; }
.zoomview.big { width: min(72%, 760px); }
.zoomview .zbtn { position: absolute; right: 6px; top: 6px; width: 30px; height: 30px; border-radius: 8px; border: 1.5px solid #14213d; background: rgba(255,255,255,.9); cursor: pointer; font-size: 16px; color: #14213d; }
.zoomview .lbl { position: absolute; left: 6px; top: 4px; font-size: 11px; font-weight: 700; color: #14213d; background: rgba(255,255,255,.85); padding: 0 6px; border-radius: 6px; max-width: calc(100% - 46px); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.labside { display: grid; gap: 12px; align-content: start; }
.tasks { list-style: none; padding: 0; margin: 0; counter-reset: t; }
.tasks li { counter-increment: t; display: grid; grid-template-columns: 28px 1fr; align-items: start; gap: 8px; padding: 8px 4px; border-bottom: 1px dashed var(--line); font-size: 14.5px; }
.tasks li::before { content: counter(t); width: 24px; height: 24px; border-radius: 50%; display: grid; place-items: center; font-size: 12px; font-weight: 800; border: 1.5px solid var(--ink-3); color: var(--ink-3); }
.tasks li.done::before { content: '✓'; background: var(--green); border-color: var(--green); color: #fff; }
.tasks li.active { background: var(--pen-soft); border-radius: 8px; }
.tasks li.active::before { border-color: var(--pen); color: var(--pen); }
.controls { display: grid; gap: 10px; }
.controls .ctl { display: grid; gap: 4px; }
.controls .ctl-row { display: flex; gap: 6px; flex-wrap: wrap; }
input[type="range"] { width: 100%; accent-color: var(--pen); height: 28px; }
.obs { width: 100%; border-collapse: collapse; font-size: 14px; background: var(--paper-2); }
.obs th, .obs td { border: 1px solid var(--grid-strong); padding: 6px 8px; text-align: center; }
.obs th { background: var(--pen-soft); font-weight: 700; }
.obs td input { width: 100%; min-width: 64px; border: 1px solid var(--line); border-radius: 4px; padding: 4px; text-align: center; background: var(--paper); }
.obs td.ok { background: var(--green-soft); }
.obs td.bad { background: var(--red-soft); }
.reading-input { display: flex; gap: 6px; align-items: center; }
.reading-input input { flex: 1; }

/* ── exam (structured question) ── */
.exam-top {
  position: sticky; top: var(--topbar); z-index: 30; display: flex; align-items: center; gap: 12px; padding: 10px 14px; margin: -6px 0 16px;
  background: var(--paper-2); border: 1.5px solid var(--ink); border-radius: var(--radius);
}
.timer { font-variant-numeric: tabular-nums; font-weight: 800; font-size: 22px; font-family: var(--display); min-width: 82px; }
.timer.warn { color: var(--red); }
.exam-paper { background: var(--paper-2); border: 1.5px solid var(--ink); border-radius: 4px; padding: clamp(16px, 3vw, 36px); position: relative; box-shadow: 5px 5px 0 var(--ink); }
.exam-paper::before { content: ''; position: absolute; top: 0; bottom: 0; left: clamp(10px, 2.4vw, 28px); width: 1.5px; background: color-mix(in srgb, var(--red) 55%, transparent); }
.q-head { display: flex; gap: 10px; align-items: baseline; flex-wrap: wrap; margin-bottom: 12px; padding-left: clamp(8px, 2vw, 16px); }
.q-stem { padding-left: clamp(8px, 2vw, 16px); }
.q-stem p { max-width: 80ch; }
.figure { margin: 12px 0; text-align: center; }
.figure img { max-height: 340px; background: #fff; border: 1px solid var(--line); border-radius: 6px; padding: 6px; }
.figure figcaption { font-size: 13px; color: var(--ink-3); }
.part { padding: 10px 0 10px clamp(8px, 2vw, 16px); }
.part .plabel { font-weight: 800; color: var(--ink); margin-right: 6px; }
.part .ptext { display: inline; }
.part .sub { margin-left: clamp(10px, 3vw, 28px); }
.ans { margin-top: 8px; display: grid; gap: 6px; }
.ans textarea {
  width: 100%; min-height: 76px; resize: vertical; padding: 10px 12px; border-radius: 6px; border: 1.5px solid var(--grid-strong);
  background-color: var(--paper); line-height: 28px; font-size: 16px; color: var(--pen);
  background-image: linear-gradient(transparent 27px, var(--grid-strong) 27px); background-size: 100% 28px; background-attachment: local;
}
.ans textarea:focus, .ans input:focus { border-color: var(--pen); outline: none; box-shadow: 0 0 0 3px var(--pen-soft); }
.ans input.input { color: var(--pen); }
.ans .meta { display: flex; justify-content: space-between; gap: 8px; font-size: 12px; color: var(--ink-3); }
.marks-pill { font-size: 12px; font-weight: 700; color: var(--ink-3); border: 1px solid var(--line); padding: 0 8px; border-radius: 999px; white-space: nowrap; }
.kbd-bar { display: flex; gap: 4px; flex-wrap: wrap; }
.kbd-bar button { min-width: 34px; height: 32px; border: 1px solid var(--line); border-radius: 6px; background: var(--paper-2); cursor: pointer; font-size: 15px; }
.kbd-bar button.on { background: var(--ige-blue); color: #fff; border-color: var(--ige-blue); }
.blanks { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 200px), 1fr)); gap: 8px; }
.sketch { border: 1.5px solid var(--grid-strong); border-radius: 8px; background: #fff; touch-action: none; width: 100%; max-width: 560px; aspect-ratio: 4 / 3; display: block; }

/* red-pen results */
.score-ring {
  width: 120px; height: 120px; border-radius: 50%; border: 4px solid var(--red); color: var(--red); display: grid; place-items: center; text-align: center;
  font-family: var(--display); transform: rotate(-6deg);
}
.score-ring b { font-size: 36px; line-height: 1; display: block; }
.score-ring span { font-size: 14px; }
.redmark { color: var(--red); font-weight: 800; font-family: var(--display); font-size: 20px; border: 2px solid var(--red); border-radius: 50%; min-width: 38px; height: 38px; display: inline-grid; place-items: center; padding: 0 6px; transform: rotate(-4deg); flex: none; }
.feedback { border-left: 3px solid var(--red); padding: 6px 12px; margin-top: 6px; color: var(--ink-2); background: var(--red-soft); border-radius: 0 8px 8px 0; font-size: 14.5px; }
.feedback.good { border-color: var(--green); background: var(--green-soft); }
.scheme { margin-top: 6px; font-size: 14px; border: 1px dashed var(--green); border-radius: 8px; padding: 8px 12px; color: var(--ink-2); }
.scheme ol { margin: 4px 0; padding-left: 1.2em; }
.your-ans { white-space: pre-wrap; color: var(--pen); background: var(--paper); padding: 8px 12px; border-radius: 6px; border: 1px solid var(--line); }
.medal { font-size: 46px; }
.reward-pop { display: flex; gap: 10px; flex-wrap: wrap; }

/* ── misc ── */
.toast-wrap { position: fixed; z-index: 100; left: 50%; bottom: 24px; transform: translateX(-50%); display: grid; gap: 8px; width: min(92vw, 440px); }
@media (max-width: 760px) { .toast-wrap { bottom: 86px; } }
.toast { background: var(--ink); color: var(--paper-2); padding: 12px 16px; border-radius: 12px; box-shadow: var(--shadow); font-weight: 600; animation: rise .25s ease; }
.toast.err { background: var(--red); color: #fff; }
.toast.ok { background: var(--green); color: #fff; }
@keyframes rise { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: none; } }
.modal-bg { position: fixed; inset: 0; z-index: 90; background: rgba(10, 18, 32, .55); display: grid; place-items: center; padding: 16px; }
.modal { width: min(560px, 100%); max-height: 90vh; overflow: auto; }
.empty { text-align: center; padding: 36px 16px; color: var(--ink-3); }
.loading { display: grid; place-items: center; min-height: 40vh; color: var(--ink-3); }
.spinner { width: 34px; height: 34px; border: 3px solid var(--line); border-top-color: var(--pen); border-radius: 50%; animation: spin .8s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
table.list { width: 100%; border-collapse: collapse; font-size: 14px; }
table.list th, table.list td { padding: 8px 10px; border-bottom: 1px solid var(--line); text-align: left; vertical-align: top; }
table.list th { font-size: 13px; color: var(--ink-3); }
.scroll-x { overflow-x: auto; }
.plan { display: grid; gap: 10px; padding: 22px; border: 1.5px solid var(--ink); border-radius: var(--radius); background: var(--paper-2); position: relative; }
.plan.best { border-width: 2.5px; border-color: var(--brass); box-shadow: 5px 5px 0 var(--brass); }
.plan .price { font-family: var(--display); font-size: 42px; font-weight: 800; line-height: 1; }
.plan .price small { font-size: 16px; font-family: var(--font); color: var(--ink-3); font-weight: 600; }
.plan .ribbon { position: absolute; top: -13px; right: 16px; background: var(--brass); color: #1b1404; font-weight: 800; font-size: 13px; padding: 3px 12px; border-radius: 999px; }
.checklist { list-style: none; padding: 0; margin: 0; display: grid; gap: 6px; }
.checklist li::before { content: '✓  '; color: var(--green); font-weight: 800; }
.badge-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(118px, 1fr)); gap: 10px; }
.badge { text-align: center; padding: 12px 8px; border: 1.5px solid var(--line); border-radius: 12px; background: var(--paper-2); font-size: 13px; }
.badge .b-ico { font-size: 30px; display: block; }
.badge.off { opacity: .35; filter: grayscale(1); }
.lb-row { display: grid; grid-template-columns: 44px 1fr auto; gap: 10px; align-items: center; padding: 10px 12px; border-bottom: 1px solid var(--line); }
.lb-row .r { font-family: var(--display); font-weight: 800; font-size: 20px; text-align: center; }
.lb-row.me { background: var(--pen-soft); border-radius: 10px; }
.notice { padding: 12px 16px; border-radius: 10px; border: 1.5px solid var(--brass); background: var(--brass-soft); }
.notice.err { border-color: var(--red); background: var(--red-soft); }
.notice.info { border-color: var(--pen); background: var(--pen-soft); }
.kv { display: grid; grid-template-columns: auto 1fr; gap: 4px 14px; font-size: 14px; }
.kv dt { color: var(--ink-3); }
.kv dd { margin: 0; font-weight: 600; }
.foot { text-align: center; color: var(--ink-3); font-size: 13px; padding: 24px 0 10px; }
.hide { display: none !important; }

/* ── IGE Solutions · premium AI learning UI refresh (Oct 2026) ── */
:root {
  --display: 'Noto Sans Sinhala', 'Segoe UI', system-ui, sans-serif;
  --radius: 16px; --radius-l: 24px;
  --line: #dfe7f3;
}
body { background-size: 34px 34px; background-image: linear-gradient(rgba(63,110,183,.048) 1px, transparent 1px), linear-gradient(90deg, rgba(63,110,183,.048) 1px, transparent 1px); }
main { max-width: 1280px; }
.topbar { min-height: 70px; height: auto; padding-top: 9px; padding-bottom: 9px; gap: 16px; background: #081b3e; }
:root { --topbar: 70px; }
.topbar::after { height: 2px; bottom: -2px; }
.brand { font-family: 'Segoe UI', system-ui, sans-serif; font-weight: 800; font-size: 19px; letter-spacing: -.55px; gap: 11px; }
.brand-logo { background: rgba(255,255,255,.97); border-radius: 11px; box-shadow: none; height: 43px; }
.brand-logo img { height: 32px; }
.brand small { font-family: 'Segoe UI', system-ui, sans-serif; font-size: 10px; font-weight: 600; letter-spacing: .5px; color: #91b9ed; }
.topnav { margin-left: 9px; gap: 2px; }
.topnav a { font-family: 'Segoe UI', system-ui, sans-serif; font-weight: 600; font-size: 12.5px; color: #c4d9f7; padding: 8px 12px; white-space: nowrap; }
.topnav a[aria-current="page"] { background: rgba(92,155,245,.17); color: #fff; box-shadow: none; }
.topbar .btn { box-shadow: none; font-family: 'Segoe UI', system-ui, sans-serif; }
.topbar .btn.pen { background: linear-gradient(110deg, #2878e8, #11a9ae); }
.btn { border-radius: 11px; box-shadow: none; border-width: 1px; transition: transform .18s, box-shadow .18s, background .18s; }
.btn:hover { transform: translateY(-2px); box-shadow: 0 8px 24px -12px rgba(13,62,133,.38); }
.btn:active { transform: translateY(0); }
.btn.pen, .btn.brass, .btn.danger { box-shadow: none; }
.btn.pen { background: linear-gradient(105deg, #246feb, #0c9db7); border-color: transparent; }
.panel, .sheet { box-shadow: 0 4px 24px -20px rgba(21,45,91,.35); border-color: var(--line); }
.sheet { box-shadow: 0 6px 26px -17px rgba(27,65,119,.25); }
h1,h2,h3 { letter-spacing: -.45px; }
.page-eyebrow, .section-kicker { display: block; font: 800 11px/1.5 'Segoe UI', system-ui, sans-serif; letter-spacing: 2px; color: var(--ige-blue); text-transform: uppercase; margin-bottom: 11px; }

/* Homepage hero: a clean AI product landing area, no misleading simulated results */
.ige-home-hero {
  display: grid; grid-template-columns: 1.03fr .97fr; align-items: center; gap: clamp(25px, 4vw, 56px);
  position: relative; overflow: hidden; isolation: isolate; margin: 5px 0 26px;
  padding: clamp(28px, 5.2vw, 70px) clamp(24px, 5.3vw, 66px);
  min-height: 535px; border-radius: 29px;
  background: linear-gradient(120deg, #081b3b 0%, #0b2b54 58%, #0b4262 100%);
  color: #fff; box-shadow: 0 26px 65px -42px rgba(8,32,70,.75);
}
.ige-home-hero::before {
  content: ''; position: absolute; z-index: -1; pointer-events: none;
  width: 730px; height: 730px; top: -360px; right: -270px; border-radius: 50%;
  background: radial-gradient(circle, rgba(34,213,197,.2), transparent 68%);
}
.ige-home-hero::after {
  content: ''; position: absolute; z-index: -1; pointer-events: none; inset: 0;
  background-image: linear-gradient(rgba(185,217,255,.045) 1px, transparent 1px), linear-gradient(90deg,rgba(185,217,255,.045) 1px,transparent 1px);
  background-size: 37px 37px;
  mask-image: linear-gradient(90deg,transparent,black 75%);
}
.hero-copy { position: relative; z-index: 2; }
.hero-eyebrow { display: inline-flex; flex-wrap: wrap; align-items: center; gap: 10px; padding: 8px 13px; margin: 0 0 24px;
  border: 1px solid rgba(112,205,238,.35); background: rgba(53,133,196,.12); border-radius: 99px;
  font: 800 10px/1.4 'Segoe UI',system-ui,sans-serif; letter-spacing: 1.7px; color: #c2efff; }
.hero-dot-divider { color: #7e9bbd; }
.hero-live-dot,.visual-status-dot { display: inline-block; width: 7px; height: 7px; background: #3fe5ad; border-radius: 50%; box-shadow: 0 0 0 4px rgba(63,229,173,.1); }
.ige-home-hero h1 { color: #fff; max-width: 630px; font: 800 clamp(34px, 4.2vw, 56px)/1.16 'Segoe UI',system-ui,sans-serif; letter-spacing: -2px; margin: 0 0 24px; }
.hero-gradient-text { background: linear-gradient(100deg, #65baff, #70f6d0); color: transparent; background-clip: text; -webkit-background-clip: text; }
.hero-description { max-width: 510px; font-size: clamp(15px, 1.4vw, 17px); line-height: 1.75; color: #d0dff4; margin-bottom: 12px; }
.hero-local { max-width: 510px; font-size: 13px; line-height: 1.9; color: #a8c6e4; margin-bottom: 26px; }
.hero-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 12px; }
.ige-home-hero .btn { border-radius: 11px; min-height: 48px; padding: 10px 18px; gap: 16px; font: 750 13px 'Segoe UI',system-ui,sans-serif; }
.ige-home-hero .hero-primary { background: linear-gradient(110deg,#3c90fa,#16b8bd); color: #fff; border: 1px solid rgba(255,255,255,.14); }
.ige-home-hero .hero-secondary { background: rgba(255,255,255,.06); color: #f7fbff; border: 1px solid rgba(255,255,255,.25); }
.ige-home-hero .hero-secondary:hover { background: rgba(255,255,255,.15); }
.hero-trust { display: flex; flex-wrap: wrap; gap: 9px 16px; color: #b4d1ed; font: 600 11px/1.5 'Segoe UI',system-ui,sans-serif; margin-top: 26px; }
.hero-trust span::first-letter { color: #4de5ba; }
.hero-visual { overflow: hidden; border: 1px solid rgba(151,210,244,.27); border-radius: 20px; background: rgba(7,24,51,.68); box-shadow: 0 22px 58px -23px rgba(0,7,26,.77), 0 0 0 8px rgba(128,204,255,.028); }
.hero-visual-top,.hero-visual-bottom { display: flex; justify-content: space-between; align-items: center; gap: 9px; padding: 12px 17px; background: rgba(255,255,255,.055); font: 650 11px 'Segoe UI',system-ui,sans-serif; color: #bdd6f1; }
.hero-visual-top { border-bottom: 1px solid rgba(153,198,239,.16); }
.visual-window-dots { display: flex; gap: 4px; }
.visual-window-dots i { width: 7px; height: 7px; background: #7891b0; border-radius: 50%; }
.visual-window-dots i:first-child { background: #f5787a; } .visual-window-dots i:nth-child(2) { background: #ffd276; } .visual-window-dots i:last-child { background: #45dba5; }
.visual-live { color: #69e0bd; font: 800 9px 'Segoe UI',system-ui,sans-serif; letter-spacing: 1px; }
.hero-visual-body { padding: 16px; }
.hero-experiment { display: flex; align-items: center; flex-direction: column; position: relative; border: 1px solid rgba(124,185,242,.16); border-radius: 14px; background: radial-gradient(ellipse at center 25%, #193f6f 0%, #112b50 52%, #0e2647 100%); padding: 14px 10px 20px; text-align: center; }
.exp-overline { align-self: start; margin: 0 0 -4px 5px; color: #a1c8f6; letter-spacing: 1.7px; font: 700 9px 'Segoe UI',system-ui,sans-serif; }
.experiment-art { position: relative; display: grid; place-items: center; width: 100%; height: 138px; }
.atom-core { font-size: 78px; color: #89dafa; line-height: 1; text-shadow: 0 0 36px rgba(53,219,229,.55); }
.orbit { position: absolute; width: 176px; height: 82px; border: 1px solid rgba(118,226,228,.33); border-radius: 50%; transform: rotate(-30deg); }
.orbit-b { transform: rotate(48deg); }
.atom-spark { position: absolute; width: 8px; height: 8px; background: #70eac1; border-radius: 50%; box-shadow: 0 0 15px #54eac1; }
.spark-a { left: 28%; top: 39%; }.spark-b { right: 29%; bottom: 32%; width: 6px; height: 6px; background: #80c6ff; }
.hero-experiment b { font: 750 16px 'Segoe UI',system-ui,sans-serif; }
.hero-experiment > span:last-child { color: #b6cfea; margin-top: 4px; font: 500 11px 'Segoe UI',system-ui,sans-serif; }
.hero-feature-stack { display: grid; gap: 8px; margin-top: 11px; }
.visual-feature { display: flex; align-items: center; gap: 12px; padding: 12px; border: 1px solid rgba(117,175,225,.18); border-radius: 11px; background: rgba(255,255,255,.05); font-family: 'Segoe UI',system-ui,sans-serif; }
.vf-icon { display: grid; place-items: center; width: 39px; height: 39px; flex: none; border-radius: 11px; color: #8fdcf6; background: rgba(83,166,231,.15); font-size: 21px; }
.visual-feature b { display: block; font-size: 12px; color: #fff; }
.visual-feature small { display: block; color: #aec9e5; font-size: 10px; line-height: 1.6; }
.vf-end { margin-left: auto; color: #8cbbdf; }
.feature-ai { border-color: rgba(70,230,186,.3); background: rgba(32,179,159,.09); }.feature-ai .vf-icon, .feature-ai .vf-end { color: #67f1c4; }
.hero-visual-bottom { background: none; border-top: 1px solid rgba(153,198,239,.14); color: #8db6db; font-size: 10px; }
.hero-visual-bottom span:first-child { display: flex; align-items: center; gap: 10px; }
.ige-metrics { display: grid; grid-template-columns: repeat(4,1fr); background: var(--paper-2); border: 1px solid var(--line); border-radius: 20px; box-shadow: 0 12px 32px -27px rgba(17,49,104,.45); overflow: hidden; margin-bottom: 54px; }
.ige-metrics>div { display: grid; justify-content: center; align-content: center; text-align: center; gap: 2px; padding: 25px 9px; border-right: 1px solid var(--line); }
.ige-metrics>div:last-child { border: none; }
.ige-metrics strong { font: 800 clamp(20px,2.3vw,29px) 'Segoe UI',system-ui,sans-serif; color: var(--ink); letter-spacing: -1px; }
.ige-metrics span { font: 600 11px 'Segoe UI',system-ui,sans-serif; color: var(--ink-3); }
.ige-section { margin-bottom: 58px; }
.section-intro { display: flex; justify-content: space-between; align-items: end; gap: 20px; margin-bottom: 23px; }
.section-intro h2 { font: 800 clamp(25px,3vw,33px)/1.23 'Segoe UI',system-ui,sans-serif; letter-spacing: -1px; margin-bottom: 7px; }
.section-intro .muted { font-size: 13px; line-height: 1.8; margin: 0; }
.section-link { font: 700 13px 'Segoe UI',system-ui,sans-serif; text-decoration: none; white-space: nowrap; padding-bottom: 4px; }
.section-link:hover { text-decoration: underline; }
.mode-card { padding: clamp(18px,2.3vw,27px); border: 1px solid var(--line); border-radius: 20px; background: var(--paper-2); box-shadow: 0 10px 32px -25px rgba(18,60,114,.47); }
.mode-head h3 { font: 800 17px 'Segoe UI',system-ui,sans-serif; }
.mode-opts { grid-template-columns: repeat(2,minmax(0,1fr)); }
.mode-opt { min-height: 100px; background: var(--paper); border: 1px solid var(--line); border-radius: 13px; padding: 17px; }
.mode-opt .mt b { font: 800 15px 'Segoe UI',system-ui,sans-serif; }
.mode-opt .mt>.en { display: block; margin-top: 2px; }
.mode-opt small { font-size: 12px; line-height: 1.8; }
.mode-opt.on { border-color: #3b9de2; box-shadow: 0 0 0 1px rgba(56,164,237,.3) inset; }
.subject { border: 1px solid var(--line); box-shadow: none; min-height: 185px; border-radius: 16px; gap: 7px; transition: transform .18s,box-shadow .18s; }
.subject h3 { font: 800 20px 'Segoe UI',system-ui,sans-serif; }
.subject.live:hover { box-shadow: 0 12px 34px -24px rgba(10,60,150,.65); transform: translateY(-3px); }
.subject.soon { background: var(--paper-2); opacity: .7; border: 1px dashed var(--line); }
.home-features .panel { min-height: 234px; border-radius: 17px; padding: 27px; background: var(--paper-2); }
.home-features h3 { font: 800 18px 'Segoe UI',system-ui,sans-serif; margin: 16px 0 11px; }
.home-features p { font-size: 13px; line-height: 1.9; color: var(--ink-2); }
.home-feature-symbol { display: grid; place-items: center; width: 45px; height: 45px; background: linear-gradient(140deg,rgba(42,120,229,.13),rgba(37,190,175,.12)); border-radius: 13px; font: 700 28px 'Segoe UI',system-ui,sans-serif; color: var(--ige-blue); }
.feature-caption { font: 800 10px 'Segoe UI',system-ui,sans-serif; letter-spacing: 1.2px; color: var(--ige-blue); }
.home-footer { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 4px 20px; border-top: 1px solid var(--line); padding: 22px 5px 10px; color: var(--ink-3); font: 500 11px/1.7 'Segoe UI',system-ui,sans-serif; }
.home-footer strong { color: var(--ink-2); }
@media (max-width: 1100px) { .topnav a[href="#/leaderboard"] { display: none; } .topnav a { padding: 8px 8px; } .ige-home-hero { padding: 37px 34px; gap: 22px; } .ige-home-hero h1 { font-size: clamp(34px,4vw,47px); } }
@media (max-width: 900px) { .ige-home-hero { grid-template-columns: 1fr; } .hero-copy { max-width: 700px; }.hero-visual { max-width: 570px; width: 100%; margin: 0 auto; } }
@media (max-width: 760px) { .topbar { min-height: 59px; padding-top: 6px; padding-bottom: 6px; } .brand { font-size: 17px; } .brand small { font-size: 9px; } .brand-logo { height: 39px; }.brand-logo img { height: 29px; } .ige-home-hero { margin: 0 -2px 19px; padding: 34px 23px; border-radius: 21px; min-height: 0; } .ige-home-hero h1 { font-size: clamp(32px,8vw,46px); letter-spacing: -1.6px; } .hero-eyebrow { font-size: 9px; letter-spacing: 1.1px; } .hero-trust { gap: 7px 12px; } .ige-metrics { grid-template-columns: repeat(2,1fr); margin-bottom: 42px; } .ige-metrics>div { border-bottom: 1px solid var(--line); } .ige-metrics>div:nth-child(2) { border-right: 0; }.ige-metrics>div:nth-child(n+3) { border-bottom: 0; }.mode-opts { grid-template-columns: 1fr; }.ige-section { margin-bottom: 42px; } .section-intro { align-items: start; flex-direction: column; gap: 12px; }.section-intro h2 { font-size: 26px; }.home-footer { padding-bottom: 20px; } }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) .mode-opt, :root:not([data-theme="light"]) .subject.soon { background: var(--paper); } }
:root[data-theme="dark"] .mode-opt, :root[data-theme="dark"] .subject.soon { background: var(--paper); }

/* ── IGE Solutions / All-subject learning hub refresh ── */
.platform-hero { min-height: 505px; margin-bottom: 18px; }
.platform-hero .hero-copy { max-width: 600px; }
.platform-hero h1 { font-size: clamp(37px,4.4vw,60px); line-height: 1.12; max-width: 630px; }
.platform-hero .hero-primary { cursor: pointer; }
.platform-hero .hero-primary:focus-visible, .platform-hero .hero-secondary:focus-visible { outline-color: #78f7d6; }
.subject-console { transform: rotate(.35deg); }
.subject-console-body { padding: clamp(15px,2vw,23px); }
.console-intro { padding: 6px 3px 17px; display: grid; gap: 4px; }
.console-overline { font: 800 10px 'Segoe UI',system-ui,sans-serif; color: #5ce8ca; letter-spacing: 1.5px; }
.console-intro strong { font: 800 clamp(19px,2.1vw,24px)/1.25 'Segoe UI',system-ui,sans-serif; color: #fff; }
.console-intro small { font: 500 12px 'Segoe UI',system-ui,sans-serif; color: #a9cce5; }
.console-subjects { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 10px; }
.console-subject { display: flex; gap: 10px; align-items: center; padding: 15px 10px; min-width: 0; border-radius: 13px; border: 1px solid rgba(170,213,255,.16); background: rgba(255,255,255,.07); color: #fff; text-decoration: none; transition: background .2s, transform .2s, border-color .2s; }
.console-subject:hover, .console-subject:focus-visible { transform: translateY(-2px); background: rgba(78,155,242,.18); border-color: rgba(154,229,255,.52); }
.console-subject.console-active { border-color: rgba(65,234,193,.55); background: rgba(37,180,156,.13); }
.console-emoji { display: grid; place-items: center; flex: none; width: 44px; height: 44px; background: rgba(106,177,234,.17); border-radius: 12px; font-size: 23px; }
.console-subject b { font: 750 12px/1.3 'Segoe UI',system-ui,sans-serif; display: block; }
.console-subject small { font: 500 10px/1.7 'Segoe UI',system-ui,sans-serif; color: #bdd2e9; display: block; }
.console-chevron { align-self: start; margin-left: auto; font-size: 13px; color: #76e5db; }
.console-feature { display: flex; align-items: center; gap: 13px; border-radius: 13px; border: 1px solid rgba(76,229,196,.18); background: rgba(35,190,159,.08); margin-top: 12px; padding: 15px; }
.console-feature-icon { display: grid; place-items: center; color: #6aeacb; background: rgba(70,216,190,.14); width: 43px; height: 43px; flex: none; border-radius: 13px; font-size: 24px; }
.console-feature b { display: block; font: 800 12px 'Segoe UI',system-ui,sans-serif; color: #fff; }
.console-feature small { display: block; font: 500 10px/1.6 'Segoe UI',system-ui,sans-serif; color: #a8d8da; }
.ige-platform-strip { display: flex; align-items: center; justify-content: space-around; flex-wrap: wrap; gap: 14px 25px; background: #fff; padding: 20px; border: 1px solid var(--line); border-radius: 16px; margin: 0 0 65px; box-shadow: 0 12px 35px -31px rgba(9,49,114,.45); }
.ige-platform-strip span { display: inline-flex; gap: 10px; align-items: center; font: 700 12px 'Segoe UI',system-ui,sans-serif; color: #4b627e; white-space: nowrap; }
.ige-platform-strip i { display: grid; place-items: center; width: 27px; height: 27px; border-radius: 8px; font: 800 10px 'Segoe UI',system-ui,sans-serif; color: #1c69ca; background: #eaf3ff; }
.ige-catalog { scroll-margin-top: 98px; margin: 0 0 70px; }
.catalog-heading { display: flex; align-items: end; justify-content: space-between; gap: 12px 20px; flex-wrap: wrap; margin: 0 0 25px; }
.catalog-heading h2 { font: 800 clamp(26px,3vw,36px)/1.2 'Segoe UI',system-ui,sans-serif; letter-spacing: -1.3px; margin: 0 0 10px; }
.catalog-heading p { margin: 0; font-size: 14px; color: var(--ink-3); }
.catalog-count { font: 750 12px 'Segoe UI',system-ui,sans-serif; padding: 9px 13px; border-radius: 99px; color: #1a6b99; background: #e9f6ff; white-space: nowrap; }
.catalog-controls { display: flex; align-items: center; flex-wrap: wrap; gap: 13px; margin: 0 0 23px; }
.subject-search { display: flex; gap: 10px; align-items: center; padding: 0 14px; min-height: 45px; min-width: min(100%,270px); flex: 1; max-width: 350px; background: var(--paper-2); color: var(--ink-3); border: 1px solid var(--line); border-radius: 11px; }
.subject-search:focus-within { box-shadow: 0 0 0 3px rgba(33,128,222,.1); border-color: #3b9de2; }
.catalog-search { min-width: 0; width: 100%; padding: 10px 0; border: 0; outline: 0; background: transparent; font: 600 12px 'Segoe UI','Noto Sans Sinhala',system-ui,sans-serif; color: var(--ink); }
.catalog-search::placeholder { color: #8092aa; }
.catalog-filters { display: flex; align-items: center; gap: 7px; flex-wrap: wrap; }
.filter-chip { border: 1px solid var(--line); background: var(--paper-2); border-radius: 100px; padding: 10px 14px; cursor: pointer; color: var(--ink-2); font: 750 12px 'Segoe UI',system-ui,sans-serif; transition: all .18s; }
.filter-chip:hover { border-color: #70a7e8; background: #eaf4ff; }
.filter-chip.active { background: #0c3470; border-color: #0c3470; color: #fff; box-shadow: 0 5px 15px -10px #0c3470; }
.ige-subject-grid { display: grid; grid-template-columns: repeat(4,minmax(0,1fr)); gap: 15px; }
.ige-subject-tile { display: flex; flex-direction: column; min-height: 208px; min-width: 0; padding: 18px; text-decoration: none; color: var(--ink); background: var(--paper-2); border: 1px solid var(--line); border-radius: 17px; position: relative; overflow: hidden; transition: border-color .18s,transform .18s, box-shadow .18s; }
.ige-subject-tile::after { content: ''; position: absolute; inset: auto 0 0; height: 3px; background: linear-gradient(90deg,#2474ed,#25bfa5); opacity: 0; transition: opacity .18s; }
.ige-subject-tile:hover,.ige-subject-tile:focus-visible { transform: translateY(-4px); border-color: #a3c9f6; box-shadow: 0 18px 38px -30px #123f87; }
.ige-subject-tile:hover::after { opacity: 1; }
.ige-subject-tile.available { border-color: #84cfcc; box-shadow: 0 8px 25px -22px rgba(5,135,135,.75); }
.tile-top,.tile-foot { display: flex; justify-content: space-between; align-items: center; gap: 9px; }
.tile-top { margin-bottom: 18px; }
.tile-icon { display: grid; place-items: center; width: 52px; height: 52px; flex: none; font-size: 27px; border-radius: 15px; background: #eaf3ff; }
.tile-icon-science { background: #e8efff; }.tile-icon-technology { background: #e8f8f7; }.tile-icon-commerce { background: #fff4e2; }.tile-icon-arts { background: #f6edff; }.tile-icon-general { background: #eef0f5; }
.tile-status { display: inline-flex; align-items: center; gap: 5px; padding: 5px 7px; border-radius: 999px; color: #677b90; background: #eff3f7; font: 800 9px/1.2 'Segoe UI',system-ui,sans-serif; white-space: nowrap; }
.tile-status.is-live { color: #087b62; background: #dcf8eb; }
.status-dot { width: 6px; height: 6px; border-radius: 50%; background: #13a780; }
.tile-title { font: 800 17px/1.3 'Segoe UI',system-ui,sans-serif; letter-spacing: -.3px; margin-bottom: 5px; }
.tile-subtitle { font: 550 12px/1.6 'Noto Sans Sinhala','Segoe UI',system-ui,sans-serif; color: var(--ink-3); margin-bottom: 16px; }
.tile-foot { margin-top: auto; border-top: 1px solid var(--line); padding-top: 12px; color: var(--ink-3); font: 650 11px 'Segoe UI',system-ui,sans-serif; }
.tile-arrow { font: 800 17px 'Segoe UI',system-ui,sans-serif; color: #2778c5; }
.catalog-empty { padding: 34px; text-align: center; background: var(--paper-2); border: 1px dashed var(--line); border-radius: 16px; }
.catalog-empty p { color: var(--ink-3); }
.catalog-disclaimer { display: flex; gap: 8px; align-items: flex-start; color: var(--ink-3); font: 550 12px/1.6 'Segoe UI',system-ui,sans-serif; margin: 21px 0 0; }
.catalog-page-heading { padding: 15px 0 25px; }
.catalog-page-heading h1 { font: 800 clamp(32px,4vw,48px) 'Segoe UI',system-ui,sans-serif; letter-spacing: -1.5px; }
.catalog-page-heading p { color: var(--ink-3); font-size: 15px; }
.back-link { display: inline-flex; align-items: center; font: 750 12px 'Segoe UI',system-ui,sans-serif; text-decoration: none; color: #2d71b2; margin-bottom: 23px; }
.back-link:hover { text-decoration: underline; }
.subject-preview-page { max-width: 1050px; margin: 15px auto 50px; }
.subject-preview-hero { display: flex; align-items: center; gap: 27px; background: linear-gradient(120deg,#edf5ff,#e7f8fa); border: 1px solid #d9e7f5; border-radius: 24px; padding: clamp(24px,4vw,50px); }
.preview-icon { display: grid; place-items: center; flex: none; width: 100px; height: 100px; border-radius: 23px; font-size: 56px; }
.subject-preview-hero h1 { font: 800 clamp(31px,4vw,45px) 'Segoe UI',system-ui,sans-serif; letter-spacing: -1.5px; margin: 2px 0 3px; }
.preview-si { font-size: 15px; color: #526c86; }
.preview-status { display: inline-block; padding: 7px 12px; border-radius: 8px; background: #fff; color: #587391; font: 800 11px 'Segoe UI',system-ui,sans-serif; }
.preview-panel { margin-top: 24px; padding: clamp(24px,4vw,44px); background: var(--paper-2); border: 1px solid var(--line); border-radius: 24px; }
.preview-panel h2 { max-width: 700px; font: 800 clamp(24px,3vw,31px) 'Segoe UI',system-ui,sans-serif; }
.preview-panel > p { max-width: 680px; color: var(--ink-3); font-size: 14px; line-height: 1.8; }
.preview-modes { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 12px; margin: 24px 0; }
.preview-mode { display: flex; align-items: center; gap: 14px; background: var(--paper); border: 1px dashed #b5c9dd; border-radius: 14px; padding: 17px; }
.preview-mode-icon { font-size: 28px; opacity: .8; }
.preview-mode strong,.preview-mode small { display: block; }.preview-mode strong { font-size: 14px; }.preview-mode small { font-size: 11px; color: var(--ink-3); margin-top: 3px; }
.preview-lock { font-size: 10px; padding: 5px 8px; border-radius: 6px; background: #e7edf4; color: #657a91; margin-left: auto; }
.preview-actions { display: flex; flex-wrap: wrap; gap: 12px; }
/* Physics mode selection is inside the Physics workspace, before the learning path. */
.subject-page-top { display: flex; justify-content: space-between; align-items: start; margin: 12px 0 0; }
.subject-page-badge { color: #098569; background: #ddfaed; font: 800 10px 'Segoe UI',system-ui,sans-serif; padding: 8px 11px; border-radius: 50px; }
.subject-page-hero { display: flex; flex-wrap: wrap; align-items: end; justify-content: space-between; gap: 20px; padding: 27px 33px; border-radius: 21px; background: linear-gradient(110deg, #09274f, #17446c); margin: 0 0 22px; color: #fff; }
.subject-page-hero h1 { color: #fff; font: 800 clamp(31px,4vw,44px)/1.16 'Segoe UI',system-ui,sans-serif; letter-spacing: -1.5px; }
.subject-page-hero h1 span { color: #7ce6d3; }
.subject-page-hero .section-kicker { color: #9bd4ef; }
.subject-page-hero p { max-width: 730px; color: #c7e0ed; font-size: 13px; line-height: 1.8; }
.subject-meta { display: flex; gap: 8px 16px; flex-wrap: wrap; font: 650 11px 'Segoe UI',system-ui,sans-serif; color: #afe1e4; }
.subject-page-hero .btn { flex: none; background: #3a92df; }
.physics-mode-section { margin-bottom: 44px; }
.subject-mode-card { border: 1px solid #cddff4; background: #fff; border-radius: 21px; padding: clamp(20px,3vw,31px); }
.subject-mode-header { display: flex; justify-content: space-between; align-items: flex-start; flex-wrap: wrap; gap: 15px; margin-bottom: 23px; }
.subject-mode-header h2 { font: 800 clamp(23px,3vw,29px) 'Segoe UI',system-ui,sans-serif; letter-spacing: -.8px; margin: 0 0 7px; }
.subject-mode-header p { max-width: 670px; font: 500 13px/1.9 'Noto Sans Sinhala','Segoe UI',system-ui,sans-serif; color: var(--ink-3); margin: 0; }
.current-mode-indicator { font: 800 11px 'Segoe UI',system-ui,sans-serif; color: #167bae; background: #edf6ff; border: 1px solid #d6e6f6; border-radius: 99px; padding: 9px 11px; }
.mode-options-v2 { grid-template-columns: repeat(2,minmax(0,1fr)); gap: 15px; }
.mode-choice { display: flex; align-items: flex-start; min-height: 193px; padding: 20px; gap: 15px; border-radius: 17px; background: #f9fbff; border: 1.5px solid #dce7f4; text-align: left; transition: transform .18s,border-color .18s,box-shadow .18s; }
.mode-choice:hover { border-color: #6ca5e3; background: #f1f7ff; transform: translateY(-3px); box-shadow: 0 14px 32px -28px #0f427e; }
.mode-choice.on { background: linear-gradient(140deg,#eff6ff,#edfffb); border-color: #2089d0; box-shadow: 0 0 0 1px rgba(32,137,208,.26) inset; }
.mode-choice[disabled] { opacity: .6; cursor: progress; }
.mode-choice-icon { display: grid; place-items: center; width: 70px; height: 70px; border-radius: 17px; flex: none; color: #3178d8; background: #e7f0ff; transition: transform .2s; }
.mode-choice-icon-open { color: #058a7c; background: #e5f8f1; }
.mode-choice:hover .mode-choice-icon { transform: rotate(-4deg) scale(1.04); }
.mode-choice-body { display: block; flex: 1; min-width: 0; }
.mode-choice .mode-choice-kicker { display: block; color: #3979b6; font: 850 10px/1.2 'Segoe UI',system-ui,sans-serif; letter-spacing: .8px; margin: 3px 0 7px; }
.mode-choice .mode-choice-body b { display: block; font: 800 21px/1.2 'Segoe UI',system-ui,sans-serif; letter-spacing: -.6px; }
.mode-choice .mode-choice-body b::after { content: none; }
.mode-choice small { font: 500 12px/1.8 'Noto Sans Sinhala','Segoe UI',system-ui,sans-serif; margin: 9px 0 12px; color: var(--ink-2); }
.mode-choice-meta { display: block; color: #5780a4; font: 650 10px/1.6 'Segoe UI',system-ui,sans-serif; }
.mode-choice-selector { width: 25px; height: 25px; flex: none; display: grid; place-items: center; border: 1px solid #acc7e5; background: #fff; color: #3f89c3; border-radius: 50%; font-size: 15px; }
.mode-choice.on .mode-choice-selector { background: #147fb6; color: #fff; border-color: #147fb6; }
.mode-help { display: flex; align-items: flex-start; gap: 9px; margin: 16px 0 0; font: 500 12px/1.6 'Segoe UI',system-ui,sans-serif; color: #647c94; }
.mode-help svg { flex: none; margin-top: 1px; }
.learning-path-section { margin-top: 28px; }
.learning-path-section .section-intro { margin-bottom: 20px; }
[hidden] { display: none !important; }
@media (max-width: 1120px) { .ige-subject-grid { grid-template-columns: repeat(3,minmax(0,1fr)); } .catalog-controls { align-items: stretch; } }
@media (max-width: 840px) { .ige-subject-grid { grid-template-columns: repeat(2,minmax(0,1fr)); } .catalog-controls { flex-direction: column; align-items: stretch; }.subject-search { max-width: none; width: 100%; flex: none; }.mode-choice { gap: 10px; padding: 15px; }.mode-choice-icon { width: 50px; height: 50px; }.mode-choice-icon svg { width: 38px; height: 38px; }.mode-choice .mode-choice-body b { font-size: 18px; } }
@media (max-width: 760px) { .platform-hero { padding: 32px 22px; }.platform-hero h1 { font-size: clamp(32px,8vw,45px); }.ige-platform-strip { justify-content: start; padding: 16px; margin-bottom: 42px; gap: 12px 20px; }.ige-platform-strip span { font-size: 11px; }.catalog-heading h2 { font-size: 26px; }.ige-catalog { margin-bottom: 45px; }.catalog-filters { flex-wrap: nowrap; overflow-x: auto; padding: 3px 0 8px; }.filter-chip { white-space: nowrap; }.mode-options-v2 { grid-template-columns: 1fr; }.mode-choice { min-height: 152px; padding: 16px; }.subject-page-hero { padding: 25px 19px; }.subject-page-top { margin-top: 0; }.subject-preview-hero { flex-direction: column; align-items: flex-start; }.preview-modes { grid-template-columns: 1fr; } }
@media (max-width: 530px) { .ige-subject-grid { gap: 10px; }.ige-subject-tile { padding: 13px; min-height: 202px; border-radius: 14px; }.tile-top { align-items: flex-start; gap: 3px; flex-wrap: wrap; margin-bottom: 12px; }.tile-icon { width: 47px; height: 47px; font-size: 25px; }.tile-status { font-size: 9px; }.tile-title { font-size: 15px; }.tile-subtitle { font-size: 11px; }.tile-foot { font-size: 10px; }.console-subjects { gap: 7px; }.console-subject { padding: 11px 7px; gap: 6px; }.console-emoji { width: 35px; height: 38px; font-size: 20px; }.console-subject b { font-size: 11px; }.console-subject small { font-size: 9px; }.console-chevron { display: none; }.ige-home-hero .hero-actions .btn { width: 100%; } }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) .ige-platform-strip, :root:not([data-theme="light"]) .subject-mode-card { background: var(--paper-2); } :root:not([data-theme="light"]) .subject-search { background: var(--paper-2); } :root:not([data-theme="light"]) .mode-choice { background: var(--paper); } }
:root[data-theme="dark"] .ige-platform-strip, :root[data-theme="dark"] .subject-mode-card { background: var(--paper-2); }
:root[data-theme="dark"] .mode-choice { background: var(--paper); }
@media (max-width: 760px) {
  .catalog-controls, .catalog-filters { min-width: 0; max-width: 100%; width: 100%; }
  .catalog-filters { overflow-x: auto; overflow-y: hidden; -webkit-overflow-scrolling: touch; }
}

/* A/L-only redesign: subject-specific navigation stays within the Physics workspace. */
.physics-local-nav { display: grid; grid-template-columns: repeat(3,minmax(0,1fr)); gap: 12px; margin: -1px 0 23px; }
.physics-local-link { box-sizing: border-box; display: flex; gap: 12px; align-items: center; width: 100%; min-width: 0; background: var(--paper-2); border: 1px solid var(--line); border-radius: 16px; color: var(--ink); padding: 16px; text-decoration: none; text-align: left; font-family: 'Segoe UI',system-ui,sans-serif; cursor: pointer; transition: transform .17s,box-shadow .17s,border-color .17s; }
.physics-local-link:hover, .physics-local-link:focus-visible { transform: translateY(-2px); border-color: #68aad8; box-shadow: 0 10px 22px -17px #155e9c; outline-offset: 2px; }
.physics-local-icon { width: 42px; height: 42px; display: grid; flex: none; place-items: center; background: #dff1ff; border-radius: 12px; font-size: 23px; font-weight: 800; color: #1874b0; }
.physics-local-papers .physics-local-icon { background: #e0f6f0; color: #03847b; }
.physics-local-link > span:nth-child(2) { flex: 1; min-width: 0; }
.physics-local-link strong, .physics-local-link small { display: block; }
.physics-local-link strong { font-size: 14px; font-weight: 800; }
.physics-local-link small { font-size: 11px; margin-top: 4px; color: var(--ink-3); }
.physics-local-arrow { color: #1683ab; font-size: 17px; flex: none; }
.physics-mode-section, .learning-path-section { scroll-margin-top: 90px; }
.physics-paper-breadcrumb { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; margin: 8px 0 18px; gap: 9px; }
.physics-paper-breadcrumb > span { font: 750 10px 'Segoe UI',system-ui,sans-serif; letter-spacing: .7px; color: var(--ink-3); }
@media (max-width: 840px) { .physics-local-nav { grid-template-columns: 1fr; gap: 8px; } .physics-local-link { padding: 13px 14px; } }

/* Post-exam AI study card: conversational explanation without a teacher-review queue. */
.tutor-card { margin: 14px 0 4px; border-radius: 16px; padding: 15px; border: 1px solid #b8d8ee; background: linear-gradient(130deg,rgba(27,91,166,.09),rgba(13,153,151,.055)); }
.tutor-title { display:flex; gap: 11px; align-items: flex-start; margin-bottom: 13px; }
.tutor-sparkle { display:grid; place-items:center; flex:none; width:33px;height:33px; border-radius: 10px; background:#d5edfd;color:#1564b8;font-size: 21px; }
.tutor-title strong { display:block;font:800 13px/1.4 'Segoe UI',system-ui,sans-serif; }
.tutor-title small { display:block; font:500 11px/1.7 'Noto Sans Sinhala','Segoe UI',system-ui,sans-serif; color:var(--ink-3); margin-top:3px; }
.tutor-actions { display:flex;gap:8px; align-items:stretch; }
.tutor-actions .tutor-prompt { flex:1;min-width:0; border-radius:10px; }
.tutor-actions button { flex:none; border-radius:10px; }
.tutor-chat { margin:10px 0 15px; }
.tutor-message { padding:16px 18px;border-radius:14px;background:var(--paper);border:1px solid var(--line);box-shadow:0 4px 15px rgba(15,63,103,.05);font:500 13px/1.85 'Noto Sans Sinhala','Segoe UI',system-ui,sans-serif;white-space:normal; }
.tutor-bot { color:#1972a2;font:850 11px 'Segoe UI',system-ui,sans-serif;letter-spacing:.03em;margin-bottom:8px; }
.tutor-answer { font-weight:650;line-height:2; }
.tutor-message p { margin: 10px 0 0; }
.tutor-steps { margin:12px 0; }.tutor-steps ol { margin:4px 0 0;padding-left:19px; }.tutor-steps li { padding-bottom:4px; }
.tutor-tip { color:var(--ink-2); }.tutor-typing { font:600 12px 'Segoe UI',system-ui,sans-serif;color:var(--ink-3); }
@media(max-width:620px){.tutor-actions{flex-direction:column}.tutor-actions button{width:100%}.tutor-card{padding:12px}.tutor-message{padding:12px}}

/* IGE Solutions — clean navy / mint student interface */
:root {
  --ige-navy: #082857;
  --ige-navy-2: #082857;
  --ige-blue: #082857;
  --ige-sky: #1CE8A9;
  --ige-teal: #1CE8A9;
  --ige-green: #1CE8A9;
  --ige-grad: linear-gradient(90deg, #082857, #1CE8A9);
  --paper: #fff;
  --paper-2: #fff;
  --ink: #080b12;
  --ink-2: #223046;
  --ink-3: #4e5b6a;
  --pen: #082857;
  --pen-soft: rgba(28, 232, 169, .12);
  --line: rgba(8, 40, 87, .18);
  --grid: #e9eef4;
  --grid-strong: #bac7d5;
  --topbar: 105px;
  --radius-s: 0px;
  --radius: 0px;
  --radius-l: 0px;
}
body {
  background: #fff !important;
  color: var(--ink);
  font-family: 'Noto Sans Sinhala', 'Segoe UI', system-ui, sans-serif;
}
/* Non-interactive surfaces are square throughout the product. */
*:not(button):not(.btn) { border-radius: 0 !important; }
*:not(button):not(.btn)::before,
*:not(button):not(.btn)::after { border-radius: 0 !important; }
button, .btn { border-radius: 7px !important; }
button:focus-visible, a:focus-visible, input:focus-visible {
  outline: 2px solid #1CE8A9;
  outline-offset: 3px;
}
.btn.pen { background: #082857; color: #fff; border-color: #082857; }
.btn.ghost { border-color: rgba(8,40,87,.18); }
.btn:hover { box-shadow: none; }
.sheet, .panel { background: #fff; box-shadow: none; border-color: var(--line); }
.sheet { border-width: 1px; }
.sheet:hover, .panel:hover { box-shadow: none; }
#bottomnav { display: none !important; }
main { padding-bottom: 68px; }

/* Announcement and full-width navigation */
.topbar {
  position: sticky;
  top: 0;
  z-index: 80;
  display: block;
  width: 100%;
  height: auto;
  min-height: 0;
  padding: 0;
  background: #082857;
  color: #fff;
  box-shadow: none;
}
.topbar::after { display: none; }
.top-announcement {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 15px;
  min-height: 34px;
  padding: 6px 16px;
  background: #061f44;
  text-align: center;
  color: #fff;
  font: 500 11px/1.5 'Segoe UI', system-ui, sans-serif;
}
.top-announcement a { color: #1CE8A9; font-weight: 700; text-decoration: none; }
.top-announcement a:hover { text-decoration: underline; }
.header-inner {
  width: min(1440px, 100%);
  margin: 0 auto;
  min-height: 74px;
  padding: 9px clamp(18px, 4.5vw, 68px);
  display: flex;
  align-items: center;
  gap: 18px;
}
.topbar .spacer { flex: 1 1 auto; }
.brand {
  display: inline-flex;
  gap: 17px;
  align-items: center;
  color: #fff;
  font: 780 19px/1.15 'Segoe UI',system-ui,sans-serif;
  letter-spacing: -.5px;
}
.brand:hover { color: #fff; }
.brand-logo {
  display: grid;
  place-items: center;
  background: none;
  box-shadow: none;
  padding: 0 16px 0 0;
  border-right: 1px solid rgba(255,255,255,.33);
  height: 43px;
}
.brand-logo img {
  display: block;
  filter: brightness(0) invert(1);
  width: 75px;
  height: auto;
  max-height: 38px;
}
.brand-name { display: flex; flex-wrap: wrap; gap: 4px; align-items: baseline; }
.brand-name strong { font-weight: 760; }
.brand-name small {
  flex-basis: 100%;
  color: rgba(255,255,255,.72);
  font: 500 10px/1.35 'Segoe UI',system-ui,sans-serif;
  letter-spacing: .02em;
}
.header-actions { display: flex; align-items: center; gap: clamp(12px,2.2vw,29px); }
.header-login, .header-account {
  text-decoration: none;
  color: #fff;
  font: 650 14px/1.4 'Segoe UI',system-ui,sans-serif;
  white-space: nowrap;
}
.header-login:hover, .header-account:hover { color: #1CE8A9; }
.header-signup {
  display: inline-flex;
  justify-content: center;
  align-items: center;
  min-height: 38px;
  padding: 8px 17px;
  background: #1CE8A9;
  color: #082857;
  font: 750 13px 'Segoe UI',system-ui,sans-serif;
  text-decoration: none;
  border: 0;
  border-radius: 7px !important;
  white-space: nowrap;
}
.header-signup:hover { background: #fff; }
.hamburger-button {
  padding: 8px 0 8px 8px;
  width: 34px;
  min-height: 34px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  background: transparent;
  border: none;
  box-shadow: none;
  cursor: pointer;
  border-radius: 0 !important;
}
.hamburger-button span {
  display: block;
  height: 2px;
  width: 26px;
  background: #1CE8A9;
  transition: width .18s ease;
}
.hamburger-button:hover span:nth-child(2) { width: 19px; }
.header-notifications { background: transparent !important; border: 0 !important; color: #fff !important; box-shadow: none !important; }
.unread-count { color: #082857; background: #1CE8A9; font: 800 12px system-ui,sans-serif; padding: 2px 5px; }
.menu-backdrop {
  position: fixed;
  inset: 0;
  z-index: 0;
  display: block;
  width: 100%;
  height: 100vh;
  height: 100dvh;
  visibility: hidden;
  opacity: 0;
  background: rgba(0, 0, 0, .56);
  border: 0;
  padding: 0;
  cursor: pointer;
  pointer-events: none;
  border-radius: 0 !important;
  transition: opacity .22s ease, visibility .22s;
}
.menu-drawer {
  position: fixed;
  inset: 0 0 0 auto;
  width: min(385px, 90vw);
  height: 100vh;
  height: 100dvh;
  background: #061e40;
  color: #fff;
  display: flex;
  flex-direction: column;
  z-index: 1;
  visibility: hidden;
  transform: translateX(102%);
  box-shadow: none;
  transition: transform .24s ease, visibility .24s;
}
.menu-is-open .menu-backdrop { opacity: 1; visibility: visible; pointer-events: auto; }
.menu-is-open .menu-drawer { transform: translateX(0); visibility: visible; }
.menu-drawer-head {
  min-height: 88px;
  padding: 24px 26px 18px 32px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-bottom: 1px solid rgba(255,255,255,.16);
  font: 760 21px 'Segoe UI',system-ui,sans-serif;
}
.menu-close { background: none; color: #1CE8A9; border: 0; font: 400 31px/1 system-ui,sans-serif; cursor: pointer; padding: 5px; border-radius: 0 !important; }
.topbar .topnav {
  display: flex !important;
  flex-direction: column;
  gap: 0;
  align-items: stretch;
  margin: 12px 0;
  padding: 0 18px;
}
.topbar .topnav a {
  display: flex !important;
  align-items: center;
  justify-content: space-between;
  min-height: 59px;
  padding: 15px 14px;
  border-bottom: 1px solid rgba(255,255,255,.12);
  background: transparent;
  color: #fff;
  font: 600 15px 'Segoe UI', system-ui, sans-serif;
  border-radius: 0 !important;
  text-decoration: none;
  box-shadow: none;
}
.topbar .topnav a span { color: #1CE8A9; font-size: 17px; }
.topbar .topnav a:hover,
.topbar .topnav a[aria-current="page"] { color: #1CE8A9; background: rgba(28,232,169,.07); box-shadow: none; }
.menu-drawer-foot { display: grid; gap: 4px; margin-top: auto; padding: 23px 32px 33px; border-top: 1px solid rgba(255,255,255,.14); }
.menu-drawer-foot span { font-size: 15px; font-weight: 800; }
.menu-drawer-foot small { font-size: 12px; color: rgba(255,255,255,.66); }

/* First fold: centered text, transparent object-only hero image, bottom proof bar */
main:has(> .ige-home-hero) { width: 100%; max-width: none; padding: 0 0 64px; }
.ige-home-hero, .platform-hero {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: flex-start;
  gap: 0;
  min-height: clamp(680px, 87svh, 890px);
  margin: 0 0 62px;
  padding: clamp(48px,7vh,76px) 0 0;
  border: 0;
  background: radial-gradient(ellipse at 50% 70%, rgba(28,232,169,.17), transparent 62%), #082857;
  color: #fff;
  box-shadow: none;
  overflow: hidden;
  isolation: isolate;
}
.ige-home-hero::before, .ige-home-hero::after { content: none; display: none; }
.platform-hero .hero-copy {
  position: relative;
  z-index: 2;
  text-align: center;
  width: min(850px, calc(100% - 36px));
  max-width: 850px;
  margin: 0 auto;
}
.ige-home-hero h1, .platform-hero h1 {
  max-width: none;
  margin: 0 auto 14px;
  font: 800 clamp(45px, 6.5vw, 77px)/1.065 'Segoe UI',system-ui,sans-serif;
  letter-spacing: -.045em;
  color: #fff;
}
.hero-gradient-text { background: none; -webkit-text-fill-color: #1CE8A9; color: #1CE8A9; }
.ige-home-hero .hero-description {
  margin: 0 auto 13px;
  color: #fff;
  font: 680 clamp(17px, 2vw, 22px)/1.4 'Segoe UI',system-ui,sans-serif;
}
.ige-home-hero .hero-local {
  max-width: 730px;
  margin: 0 auto 24px;
  color: rgba(255,255,255,.88);
  font: 500 clamp(13px,1.3vw,15px)/1.95 'Noto Sans Sinhala',system-ui,sans-serif;
}
.ige-home-hero .hero-actions {
  justify-content: center;
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}
.ige-home-hero .hero-actions .btn {
  min-height: 49px;
  padding: 11px 22px;
  border: 0;
  border-radius: 7px !important;
  font: 750 13px/1.3 'Segoe UI',system-ui,sans-serif;
  text-decoration: none;
  gap: 20px;
  box-shadow: none;
  transition: background .18s ease, transform .18s ease;
}
.ige-home-hero .hero-actions .btn:hover { transform: translateY(-2px); box-shadow: none; }
.ige-home-hero .hero-actions .hero-primary { background: #1CE8A9; color: #082857; border: 0; }
.ige-home-hero .hero-actions .hero-primary:hover { background: #fff; }
.ige-home-hero .hero-actions .hero-secondary { background: rgba(255,255,255,.10); color: #fff; border: 0; }
.ige-home-hero .hero-actions .hero-secondary:hover { background: rgba(255,255,255,.19); }
.ige-home-hero .hero-art {
  align-self: center;
  display: flex;
  justify-content: center;
  align-items: flex-end;
  position: relative;
  z-index: 1;
  width: min(2040px,250%);
  height: clamp(240px,36vw,420px);
  margin: auto auto 0;
  pointer-events: none;
}
.hero-art img {
  display: block;
  width: 250%;
  height: 250%;
  object-fit: contain;
  object-position: center bottom;
  filter: drop-shadow(0 16px 28px rgba(0,0,0,.22));
}
.ige-home-hero .hero-trust {
  position: relative;
  z-index: 2;
  width: 100%;
  min-height: 74px;
  padding: 14px 18px;
  margin: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-wrap: wrap;
  gap: 12px clamp(24px,5vw,75px);
  color: #fff;
  background: rgba(0,0,0,.16);
  font: 600 12px/1.5 'Segoe UI',system-ui,sans-serif;
}
.hero-trust span { display: inline-flex; align-items: center; gap: 9px; white-space: nowrap; }
.hero-trust b { color: #1CE8A9; font-size: 18px; }

/* Subject finder and rest of the home page */
main:has(> .ige-home-hero) > :not(.ige-home-hero) { width: min(1170px,calc(100% - 38px)); margin-left: auto; margin-right: auto; }
.ige-catalog { margin-bottom: 58px; scroll-margin-top: 126px; }
.catalog-heading { align-items: center; margin-bottom: 24px; }
.catalog-heading h2 { font-size: clamp(23px,3vw,33px); letter-spacing: -.8px; color: #082857; }
.section-kicker { color: #082857; letter-spacing: .07em; font-size: 10px; }
.catalog-heading p { color: #344456; font-size: 13px; }
.catalog-count { background: transparent; color: #38485a; border: 0; padding: 0; font-size: 12px; }
.subject-search { min-height: 47px; border: 1px solid var(--line); box-shadow: none; }
.subject-search:focus-within { border-color: #082857; box-shadow: none; }
.catalog-filters { gap: 7px; }
.filter-chip { border: 1px solid rgba(8,40,87,.16); background: #fff; color: #082857; padding: 10px 12px; border-radius: 6px !important; font-weight: 700; }
.filter-chip:hover { background: rgba(28,232,169,.10); border-color: #1CE8A9; }
.filter-chip.active { background: #082857; color: #fff; border-color: #082857; box-shadow: none; }
.ige-subject-grid { gap: 12px; }
.ige-subject-tile {
  min-height: 190px;
  padding: 20px;
  border: 1px solid var(--line);
  background: #fff;
  box-shadow: none;
}
.ige-subject-tile::after { content: none; display: none; }
.ige-subject-tile:hover, .ige-subject-tile:focus-visible { transform: translateY(-3px); border-color: #082857; box-shadow: 0 12px 25px rgba(8,40,87,.08); }
.ige-subject-tile.available { border-color: rgba(8,40,87,.34); box-shadow: none; }
.tile-top { margin-bottom: 25px; align-items: flex-start; }
.tile-stream { color: #082857; font: 700 10px/1.4 'Segoe UI',system-ui,sans-serif; text-transform: uppercase; letter-spacing: .04em; }
.tile-status { padding: 0; background: transparent; color: #566578; font-size: 10px; }
.tile-status.is-live { color: #067655; background: transparent; }
.tile-title { font-size: 18px; color: #082857; }
.tile-subtitle { color: #495b70; }
.tile-foot { color: #41536a; border-top-color: var(--line); }
.tile-arrow { color: #082857; }
.catalog-disclaimer { font-size: 12px; color: #59677a; }
.ige-section h2 { color: #082857; }
.home-features.grid3 { gap: 12px; }
.home-features .panel { min-height: 142px; padding: 23px; background: #fff; border: 1px solid var(--line); }
.home-features .panel h3 { font: 750 17px/1.4 'Segoe UI',system-ui,sans-serif; letter-spacing: -.25px; color: #082857; }
.home-features .panel p { color: #455467; font-size: 13px; line-height: 1.6; }
.home-footer { border-top: 1px solid var(--line); color: #465568; }

/* Shared UI, including subject previews, forms, labs and dashboard */
.subject-page-hero { background: #082857; }
.subject-page-hero h1 span { color: #1CE8A9; }
.subject-page-hero .btn { background: #1CE8A9; color: #082857; border: 0; }
.subject-preview-hero { background: rgba(8,40,87,.04); border-color: var(--line); }
.subject-mode-card, .mode-choice, .physics-local-link, .preview-panel { border-color: var(--line); box-shadow: none; }
.physics-local-icon, .mode-choice-icon { color: #082857; background: rgba(28,232,169,.13); }
.mode-choice.on { border-color: #082857; background: rgba(28,232,169,.1); }
.catalog-page-heading h1 { color: #082857; }
.back-link { color: #082857; }

@media (max-width: 900px) {
  .ige-home-hero, .platform-hero { grid-template-columns: none; }
  .platform-hero .hero-copy { width: min(720px,calc(100% - 36px)); }
  .ige-home-hero .hero-art { max-width: 100%; }
}
@media (max-width: 760px) {
  :root { --topbar: 96px; }
  .topbar { padding: 0; min-height: 0; }
  .header-inner { min-height: 65px; padding: 8px 20px; }
  .top-announcement { min-height: 31px; font-size: 10px; gap: 9px; }
  .brand { font-size: 15px; gap: 10px; }
  .brand-logo { height: 34px; padding-right: 10px; }
  .brand-logo img { width: 60px; max-height: 31px; }
  .brand-name small { font-size: 8px; }
  .header-actions { gap: 12px; }
  .header-login, .header-account { font-size: 12px; }
  .header-signup { padding: 7px 10px; font-size: 12px; min-height: 35px; }
  .hamburger-button { width: 28px; padding-left: 3px; }
  .hamburger-button span { width: 23px; }
  .ige-home-hero, .platform-hero { margin: 0 0 46px; padding: 43px 0 0; min-height: 635px; }
  .ige-home-hero h1, .platform-hero h1 { font-size: clamp(41px,9vw,62px); letter-spacing: -.04em; }
  .ige-home-hero .hero-description { font-size: 17px; }
  .ige-home-hero .hero-local { font-size: 12px; line-height: 1.8; max-width: 530px; }
  .ige-home-hero .hero-actions .btn { min-height: 46px; width: auto; font-size: 12px; padding: 10px 16px; }
  .ige-home-hero .hero-art { height: clamp(210px,49vw,380px); }
  .ige-home-hero .hero-trust { min-height: 76px; gap: 7px 21px; font-size: 10px; padding: 13px 16px; }
  .hero-trust b { font-size: 15px; }
  main { padding-bottom: 60px !important; }
  main:has(> .ige-home-hero) { padding: 0 0 60px !important; }
  .catalog-heading h2 { font-size: 26px; }
  .catalog-filters { flex-wrap: nowrap; overflow-x: auto; }
  .ige-subject-grid { grid-template-columns: repeat(2,minmax(0,1fr)); }
}
@media (max-width: 530px) {
  .brand-name small { display: none; }
  .brand { font-size: 14px; }
  .header-actions { gap: 9px; }
  .top-announcement { gap: 6px; font-size: 9px; }
  .top-announcement a span { display: none; }
  .ige-home-hero, .platform-hero { padding-top: 42px; min-height: 610px; }
  .ige-home-hero h1, .platform-hero h1 { font-size: clamp(38px,10.2vw,49px); }
  .ige-home-hero .hero-local { margin-bottom: 20px; }
  .ige-home-hero .hero-actions { gap: 9px; }
  .ige-home-hero .hero-actions .btn { font-size: 11px; gap: 8px; padding: 10px 11px; }
  .ige-home-hero .hero-art { height: clamp(215px,61vw,275px); width: 118%; max-width: none; margin-left: -9%; margin-right: -9%; }
  .ige-home-hero .hero-trust { font-size: 9px; min-height: 86px; gap: 4px 13px; }
  .hero-trust span { gap: 5px; }
  .ige-subject-tile { min-height: 175px; padding: 14px; }
  .tile-top { gap: 5px; margin-bottom: 19px; }
  .tile-stream { font-size: 9px; }
  .tile-status { font-size: 9px; }
  .tile-title { font-size: 16px; }
  .tile-subtitle { font-size: 11px; }
  .catalog-count { font-size: 11px; }
}
@media (max-width: 370px) {
  .brand-name { display: none; }
  .header-inner { padding-inline: 14px; }
  .ige-home-hero .hero-actions { flex-direction: column; align-items: center; }
  .ige-home-hero .hero-actions .btn { min-width: 200px; }
}
@media (prefers-reduced-motion: reduce) {
  .menu-backdrop, .menu-drawer, .hamburger-button span, .ige-home-hero .hero-actions .btn { transition: none; }
}

/* Maintain the same four-color design when a device prefers dark mode. */
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --paper: #fff; --paper-2: #fff; --ink: #080b12; --ink-2: #223046;
    --ink-3: #4e5b6a; --pen: #082857; --pen-soft: rgba(28,232,169,.12);
    --grid: #e9eef4; --grid-strong: #bac7d5; --line: rgba(8,40,87,.18);
    color-scheme: light;
  }
}
:root[data-theme="dark"] {
  --paper: #fff; --paper-2: #fff; --ink: #080b12; --ink-2: #223046;
  --ink-3: #4e5b6a; --pen: #082857; --pen-soft: rgba(28,232,169,.12);
  --grid: #e9eef4; --grid-strong: #bac7d5; --line: rgba(8,40,87,.18);
  color-scheme: light;
}


/* Home hero refinements: authentic IGE logo, first-fold height and restrained motion. */
.topbar .brand-logo {
  width: 106px;
  height: 62px;
  padding: 5px 8px;
  background: transparent;
  border: 0;
  border-radius: 0;
  box-shadow: none;
  flex: 0 0 auto;
}
.topbar .brand-logo img {
  display: block;
  width: 100%;
  height: 100%;
  max-height: none;
  object-fit: contain;
  filter: drop-shadow(0 0 2px rgba(255, 255, 255, .36));
}
.topbar .header-inner { min-height: 78px; padding-top: 7px; padding-bottom: 7px; }

/* Header = 34px announcement + 78px navigation. The hero fills the rest of the viewport. */
main:has(> .ige-home-hero) > .ige-home-hero.platform-hero {
  height: calc(100vh - 112px);
  height: calc(100svh - 112px);
  min-height: 0;
  margin-bottom: 46px;
  padding: clamp(24px, 4.5vh, 51px) 0 0;
  justify-content: flex-start;
}
.ige-home-hero.platform-hero .hero-copy {
  z-index: 2;
  width: min(810px, calc(100% - 32px));
  pointer-events: none;
}
.ige-home-hero.platform-hero .hero-copy a { pointer-events: auto; }
.ige-home-hero.platform-hero h1 {
  font-size: clamp(38px, 5.4vw, 69px);
  line-height: 1.055;
  margin-bottom: 9px;
}
.ige-home-hero.platform-hero .hero-description {
  font-size: clamp(16px, 1.6vw, 20px);
  margin-bottom: 8px;
}
.ige-home-hero.platform-hero .hero-local {
  max-width: 780px;
  margin-bottom: 14px;
  font-size: clamp(12px, 1.1vw, 14px);
  line-height: 1.7;
}
.ige-home-hero.platform-hero .hero-actions .btn { min-height: 44px; padding: 10px 19px; }

/* Float the transparent image behind the CTAs, below the Sinhala paragraph. */
.ige-home-hero.platform-hero .hero-art {
  position: absolute;
  left: 50%;
  bottom: 59px;
  z-index: 1;
  width: min(940px, 90vw);
  height: min(47%, 370px);
  margin: 0;
  opacity: .83;
  pointer-events: none;
  transform: translateX(-50%);
}
.ige-home-hero.platform-hero .hero-art img {
  object-position: center bottom;
  filter: drop-shadow(0 12px 22px rgba(0, 0, 0, .12));
}
.ige-home-hero.platform-hero .hero-trust {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 3;
  min-height: 59px;
  padding: 10px 16px;
}

/* Slow, sequential fade-ins; floating remains small enough to avoid distraction. */
@keyframes ige-gentle-reveal {
  from { opacity: 0; transform: translateY(15px); }
  to { opacity: 1; transform: translateY(0); }
}
@keyframes ige-art-reveal {
  from { opacity: 0; transform: translateY(22px) scale(.985); }
  to { opacity: 1; transform: translateY(0) scale(1); }
}
@keyframes ige-art-float {
  0%, 100% { translate: 0 0; }
  50% { translate: 0 -9px; }
}
.ige-home-hero .hero-copy h1,
.ige-home-hero .hero-description,
.ige-home-hero .hero-local,
.ige-home-hero .hero-actions,
.ige-home-hero .hero-trust {
  animation: ige-gentle-reveal 1.05s cubic-bezier(.2,.7,.2,1) both;
}
.ige-home-hero .hero-description { animation-delay: .15s; }
.ige-home-hero .hero-local { animation-delay: .29s; }
.ige-home-hero .hero-actions { animation-delay: .43s; }
.ige-home-hero .hero-trust { animation-delay: .55s; }
.ige-home-hero .hero-art img {
  animation: ige-art-reveal 1.35s ease .25s both,
             ige-art-float 7s ease-in-out 1.6s infinite;
  will-change: transform, translate;
}

@media (max-width: 760px) {
  .topbar .header-inner { min-height: 66px; }
  .topbar .brand-logo { width: 78px; height: 50px; padding: 4px 5px; }
  .ige-home-hero.platform-hero { height: calc(100svh - 97px) !important; min-height: 0; padding-top: clamp(17px, 3.5vh, 36px) !important; }
  .ige-home-hero.platform-hero h1 { font-size: clamp(34px, 7vw, 54px); }
  .ige-home-hero.platform-hero .hero-local { font-size: 12px; line-height: 1.6; }
  .ige-home-hero.platform-hero .hero-art { height: min(37%, 280px); width: min(690px, 120vw); bottom: 66px; }
  .ige-home-hero.platform-hero .hero-trust { min-height: 66px; }
}
@media (max-width: 530px) {
  .topbar .header-inner { padding-left: 12px; padding-right: 12px; }
  .topbar .brand-logo { width: 68px; height: 43px; padding: 4px; }
  .topbar .brand { gap: 8px; font-size: 13px; }
  .topbar .brand-name { letter-spacing: -.03em; }
  .ige-home-hero.platform-hero { padding-top: 28px !important; }
  .ige-home-hero.platform-hero h1 { font-size: clamp(32px, 8.6vw, 43px); }
  .ige-home-hero.platform-hero .hero-description { font-size: 15px; margin-bottom: 7px; }
  .ige-home-hero.platform-hero .hero-local { max-width: 350px; font-size: 11px; line-height: 1.65; margin-bottom: 12px; }
  .ige-home-hero.platform-hero .hero-actions { gap: 8px; }
  .ige-home-hero.platform-hero .hero-actions .btn { padding: 9px 10px; font-size: 10px; min-height: 40px; }
  .ige-home-hero.platform-hero .hero-art { width: 122vw; height: 36%; bottom: 75px; }
  .ige-home-hero.platform-hero .hero-trust { min-height: 75px; gap: 3px 12px; padding: 10px; }
}
@media (max-width: 530px) and (min-height: 750px) {
  .ige-home-hero.platform-hero { padding-top: 58px !important; }
  .ige-home-hero.platform-hero .hero-art {
    width: 180vw;
    height: 45%;
  }
}
@media (max-width: 370px) {
  .ige-home-hero.platform-hero { padding-top: 17px !important; }
  .ige-home-hero.platform-hero h1 { font-size: 31px; }
  .ige-home-hero.platform-hero .hero-actions { flex-direction: row; gap: 6px; }
  .ige-home-hero.platform-hero .hero-actions .btn { min-width: 0; font-size: 9px; padding: 7px; }
  .ige-home-hero.platform-hero .hero-art { height: 30%; bottom: 84px; }
  .ige-home-hero.platform-hero .hero-trust { min-height: 84px; }
}
@media (prefers-reduced-motion: reduce) {
  .ige-home-hero .hero-copy h1,
  .ige-home-hero .hero-description,
  .ige-home-hero .hero-local,
  .ige-home-hero .hero-actions,
  .ige-home-hero .hero-trust,
  .ige-home-hero .hero-art img { animation: none !important; will-change: auto; }
}

/* Site-wide footer: the same navy / mint palette and square-edge layout as the hero. */
.site-footer {
  width: 100%;
  background: #082857;
  color: #fff;
  border: 0;
  border-radius: 0;
  font: 400 14px/1.65 'Segoe UI', system-ui, sans-serif;
}
.site-footer-inner {
  width: min(1160px, calc(100% - 48px));
  margin: 0 auto;
  padding: 62px 0 53px;
  display: grid;
  grid-template-columns: minmax(280px, 1.8fr) minmax(130px, 1fr) minmax(130px, 1fr);
  column-gap: clamp(30px, 5vw, 90px);
  row-gap: 35px;
}
.site-footer-brand { display: flex; flex-direction: column; align-items: flex-start; }
.site-footer-brand > a { display: inline-flex; align-items: center; line-height: 1; }
.site-footer-brand img { display: block; width: 144px; height: auto; max-height: 95px; object-fit: contain; }
.site-footer-brand-title { display: block; font-size: 21px; font-weight: 750; margin: 6px 0 2px; }
.site-footer-brand p { margin: 0; max-width: 290px; color: #bcd0e7; font-size: 12px; }
.site-footer-links { display: flex; flex-direction: column; align-items: flex-start; gap: 11px; }
.site-footer-links h2 { color: #1CE8A9; font: 750 13px/1.3 'Segoe UI',system-ui,sans-serif; letter-spacing: .045em; margin: 3px 0 9px; }
.site-footer-links a { color: #e7f0fb; font-size: 14px; font-weight: 500; text-decoration: none; transition: color .28s ease, transform .28s ease; }
.site-footer-links a:hover, .site-footer-links a[aria-current="page"] { color: #1CE8A9; transform: translateX(3px); }
.site-footer a:focus-visible { outline: 2px solid #1CE8A9; outline-offset: 5px; border-radius: 0; }
.site-footer-bottom {
  width: min(1160px, calc(100% - 48px));
  min-height: 62px;
  margin: 0 auto;
  padding: 18px 0 22px;
  border-top: 1px solid rgba(255,255,255,.17);
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 8px 20px;
  color: #b5c8e0;
  font: 400 12px/1.7 'Segoe UI',system-ui,sans-serif;
}
@media (max-width: 760px) {
  .site-footer-inner { grid-template-columns: minmax(180px, 1.3fr) minmax(115px, 1fr); padding: 44px 0 38px; }
  .site-footer-brand { grid-column: 1 / -1; }
  .site-footer-bottom { padding-bottom: 30px; }
}
@media (max-width: 400px) {
  .site-footer-inner, .site-footer-bottom { width: calc(100% - 36px); }
  .site-footer-inner { column-gap: 18px; }
}

/* The original hover styles remain interactive once a section finishes revealing. */
.home-scroll-reveal { transition: opacity 1.05s cubic-bezier(.22,1,.36,1), transform 1.05s cubic-bezier(.22,1,.36,1), border-color .2s, box-shadow .2s; }
.home-scroll-reveal.reveal-pending { opacity: 0; transform: translate3d(0, 26px, 0); }
.ige-subject-tile.home-scroll-reveal:not(.reveal-pending):hover,
.ige-subject-tile.home-scroll-reveal:not(.reveal-pending):focus-visible { transform: translateY(-3px); }

/* About and Contact pages: compact content with the same minimalist palette. */
.ige-info-page { width: min(900px, 100%); padding: clamp(26px,5vw,67px) 0 65px; color: #082857; font-family: 'Segoe UI',system-ui,sans-serif; }
.ige-info-eyebrow { display: block; margin-bottom: 23px; font-weight: 750; font-size: 11px; letter-spacing: .1em; color: #076d55; }
.ige-info-page h1 { font: 800 clamp(34px,5vw,60px)/1.14 'Segoe UI',system-ui,sans-serif; color: #082857; letter-spacing: -.035em; }
.ige-info-page > p { max-width: 630px; font-size: 15px; line-height: 1.9; color: #3d4d61; }
.ige-info-page .ige-info-lead { font-size: clamp(18px,2.2vw,23px); font-weight: 700; color: #082857; margin: 17px 0 9px; }
.ige-info-grid { display: grid; grid-template-columns: repeat(3,minmax(0,1fr)); margin: 32px 0; border: 1px solid rgba(8,40,87,.2); }
.ige-info-grid > div { padding: 26px 22px; border-right: 1px solid rgba(8,40,87,.16); }
.ige-info-grid > div:last-child { border-right: 0; }
.ige-info-grid h2, .ige-info-contact h2 { font: 750 17px/1.5 'Segoe UI',system-ui,sans-serif; color: #082857; margin-bottom: 7px; }
.ige-info-grid p, .ige-info-contact p { font-size: 13px; color: #4b5b6d; margin: 0; }
.ige-info-button { background: #1CE8A9; color: #082857; border: 0; box-shadow: none; border-radius: 5px !important; }
.ige-info-button:hover { background: #082857; color: #fff; box-shadow: none; }
.ige-info-contact { display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 15px; margin: 30px 0 30px; padding: 22px 26px; border: 1px solid rgba(8,40,87,.2); }
.ige-info-contact a { font-weight: 750; color: #082857; text-decoration: underline; text-underline-offset: 5px; }
.ige-info-contact a:hover { color: #087b5c; }
.ige-info-back { display: inline-block; font-weight: 700; font-size: 13px; color: #082857; text-decoration: none; }
.ige-info-back:hover { text-decoration: underline; }
@media (max-width: 620px) { .ige-info-grid { grid-template-columns: 1fr; } .ige-info-grid > div { border-right: 0; border-bottom: 1px solid rgba(8,40,87,.16); } .ige-info-grid > div:last-child { border-bottom: 0; } }
@media (prefers-reduced-motion: reduce) {
  .home-scroll-reveal, .site-footer-links a { transition: none !important; }
  .home-scroll-reveal.reveal-pending { opacity: 1; transform: none; }
}

/* Physics workspace: quiet, task-first layout for A/L learners. */
body:has(.physics-workspace) { background: #fff; background-image: none; }
main:has(> .physics-workspace) { max-width: none; padding: 0 0 80px; }
.physics-workspace {
  --physics-navy: #082857;
  --physics-mint: #1CE8A9;
  --physics-stroke: #e0e7ef;
  color: #0d1b2c;
  background: #fff;
  font-family: 'Noto Sans Sinhala', 'Segoe UI', system-ui, sans-serif;
}
.physics-container { width: min(1260px, calc(100% - 64px)); margin-inline: auto; }
.physics-topline {
  position: relative; display: flex; align-items: center; justify-content: space-between;
  min-height: 61px; gap: 15px; color: #fff;
}
.physics-topline::before {
  content: ''; position: absolute; inset: 0; left: 50%; right: 50%;
  margin-left: -50vw; margin-right: -50vw; background: var(--physics-navy); z-index: -1;
}
.physics-back { color: #fff; font: 700 13px/1.4 'Segoe UI',system-ui,sans-serif; text-decoration: none; }
.physics-back:hover { color: var(--physics-mint); text-decoration: underline; }
.physics-status { color: #cddced; font: 600 12px/1.4 'Segoe UI',system-ui,sans-serif; }
.physics-hero { width: 100%; color: #fff; background: var(--physics-navy); }
.physics-hero-inner { padding-block: clamp(26px, 3.5vw, 50px) 0; }
.physics-hero-main { display: flex; align-items: flex-end; justify-content: space-between; gap: 28px; }
.physics-eyebrow { display: block; margin-bottom: 13px; color: #9fc4db; font: 700 10px/1.3 'Segoe UI',system-ui,sans-serif; letter-spacing: .12em; }
.physics-hero h1 { margin: 0; color: #fff; font: 800 clamp(30px, 4vw, 49px)/1.12 'Segoe UI',system-ui,sans-serif; letter-spacing: -.035em; }
.physics-hero h1 span { color: var(--physics-mint); }
.physics-hero p { margin: 10px 0 0; color: #cddced; font: 400 clamp(12px, 1.1vw, 15px)/1.6 'Segoe UI',system-ui,sans-serif; }
.physics-continue {
  display: inline-flex; align-items: center; justify-content: center; gap: 18px;
  min-height: 44px; padding: 10px 18px; white-space: nowrap; flex: none;
  color: var(--physics-navy); background: var(--physics-mint); text-decoration: none;
  border: 0; border-radius: 5px; font: 750 13px/1.4 'Segoe UI',system-ui,sans-serif;
  transition: background .25s, transform .25s;
}
.physics-continue:hover { background: #69ffcd; transform: translateY(-2px); }
.physics-hero-nav {
  display: grid; grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px; margin-top: clamp(22px, 2.7vw, 37px); padding-bottom: 13px;
}
.physics-workspace .physics-hero-nav :is(.physics-hero-link,.physics-local-link) {
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
  width: 100%; min-height: 47px; padding: 9px 15px; margin: 0;
  border: none; border-radius: 0; background: transparent; box-shadow: none;
  color: #fff; text-decoration: none; text-align: left;
  font: 750 clamp(12px, 1.07vw, 15px)/1.35 'Segoe UI',system-ui,sans-serif;
  cursor: pointer; transition: background .3s, color .3s;
}
.physics-hero-nav :is(.physics-hero-link,.physics-local-link) span { font-weight: 400; font-size: 16px; color: var(--physics-mint); transition: transform .3s; }
.physics-workspace .physics-hero-nav :is(.physics-hero-link,.physics-local-link):hover, .physics-workspace .physics-hero-nav :is(.physics-hero-link,.physics-local-link):focus-visible { background: rgba(255,255,255,.1); color: var(--physics-mint); }
.physics-hero-nav :is(.physics-hero-link,.physics-local-link):hover span { transform: translateX(4px); }
.physics-hero-nav :is(.physics-hero-link,.physics-local-link):focus-visible, .physics-continue:focus-visible { outline: 2px solid var(--physics-mint); outline-offset: 2px; }
.physics-page-content { padding-top: clamp(27px, 3vw, 43px); }
.physics-workspace .physics-mode-section, .physics-workspace .learning-path-section { scroll-margin-top: 138px; }
.physics-workspace .subject-mode-card { padding: 0; border: 0; border-radius: 0; background: transparent; box-shadow: none; }
.physics-workspace .subject-mode-header { margin-bottom: 18px; gap: 8px; }
.physics-workspace .subject-mode-header h2,
.physics-workspace .physics-section-heading h2 { margin: 0 0 6px; color: var(--physics-navy); font: 800 clamp(22px, 2.25vw, 29px)/1.25 'Segoe UI',system-ui,sans-serif; letter-spacing: -.025em; }
.physics-workspace .subject-mode-header p { margin: 0; font: 500 13px/1.65 'Noto Sans Sinhala',sans-serif; color: #556577; }
.physics-workspace .mode-options-v2 { gap: 13px; grid-template-columns: repeat(2, minmax(0, 1fr)); }
.physics-workspace .mode-choice {
  min-height: 127px; display: flex; align-items: center; justify-content: space-between; gap: 20px;
  padding: 20px 22px; border: 1px solid var(--physics-stroke); border-radius: 5px;
  box-shadow: none; background: #fff; color: var(--physics-navy); text-align: left;
  transition: background .28s, border-color .28s, transform .28s;
}
.physics-workspace .mode-choice:hover { background: #f3faf8; border-color: #8ccdbd; box-shadow: none; transform: translateY(-2px); }
.physics-workspace .mode-choice.on { background: #eafcf5; border: 1px solid #51d6ae; box-shadow: none; }
.physics-workspace .mode-choice:focus-visible { outline: 2px solid #082857; outline-offset: 3px; }
.physics-workspace .mode-choice-body { display: flex; flex-direction: column; flex: 1; min-width: 0; }
.physics-workspace .mode-choice-kicker { order: 2; margin: 3px 0 0; color: #647485; font: 600 11px/1.3 'Segoe UI',system-ui,sans-serif; letter-spacing: 0; text-transform: none; }
.physics-workspace .mode-choice-body b { order: 1; color: #082857; font: 780 clamp(16px, 1.7vw, 20px)/1.3 'Segoe UI',system-ui,sans-serif; letter-spacing: -.015em; }
.physics-workspace .mode-choice-body b::after { content: none; }
.physics-workspace .mode-choice small { order: 3; margin: 12px 0 0; color: #47566b; font: 500 12px/1.65 'Noto Sans Sinhala',system-ui,sans-serif; }
.physics-workspace .mode-choice-state { flex: none; color: #146d62; font: 750 12px/1.3 'Segoe UI',system-ui,sans-serif; white-space: nowrap; }
.physics-workspace .mode-help { display: block; margin: 12px 0 0; color: #627082; font: 500 11px/1.6 'Segoe UI',system-ui,sans-serif; }
.physics-workspace .learning-path-section { margin-top: clamp(37px, 4.5vw, 58px); }
.physics-workspace .physics-section-heading { align-items: flex-end; margin-bottom: 22px; }
.physics-workspace .physics-section-heading p { margin: 0; color: #647185; font: 500 12px/1.6 'Segoe UI',system-ui,sans-serif; }
.physics-text-link { display: inline-block; color: var(--physics-navy); font: 750 13px/1.5 'Segoe UI',system-ui,sans-serif; text-decoration: none; }
.physics-text-link:hover { text-decoration: underline; }
.physics-workspace .physics-learning-layout { grid-template-columns: minmax(0, 1fr) 270px; gap: 32px; }
.physics-workspace .unit-block { margin: 0 0 34px; }
.physics-workspace .unit-head { display: flex; justify-content: space-between; align-items: baseline; flex-wrap: wrap; gap: 4px 14px; margin: 0 0 11px; padding-bottom: 9px; border-bottom: 1px solid var(--physics-stroke); }
.physics-workspace .unit-head h3 { font: 750 17px/1.5 'Noto Sans Sinhala',system-ui,sans-serif; color: #082857; }
.physics-workspace .unit-head .en { color: #7a8797; font: 500 11px/1.5 'Segoe UI',system-ui,sans-serif; }
.physics-workspace .trail { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 9px; }
.physics-workspace .lvl { grid-template-columns: 42px minmax(0,1fr); gap: 12px; padding: 12px 14px; min-height: 72px; border: 1px solid var(--physics-stroke); border-radius: 0; box-shadow: none; background: #fff; color: #0d1b2c; transition: background .2s, border-color .2s; }
.physics-workspace a.lvl:hover { background: #f3faf8; border-color: #6ecdb3; }
.physics-workspace .lvl.current { border: 1px solid #0a8b6e; background: #f3fdf9; box-shadow: none; }
.physics-workspace .lvl.done { border-color: #d9e5e0; }
.physics-workspace .lvl.locked { opacity: .59; }
.physics-workspace .lvl .num { display: flex; align-items: center; justify-content: center; width: 42px; height: 42px; border: 0; border-radius: 0; background: #eef3f8; color: #082857; font: 750 13px/1.2 'Segoe UI',system-ui,sans-serif; animation: none; }
.physics-workspace .lvl.current .num { background: #082857; color: #fff; animation: none; }
.physics-workspace .lvl.done .num { background: #d9f9eb; color: #086a52; }
.physics-workspace .lvl.locked .num { border-style: none; }
.physics-workspace .lvl .t { display: block; font: 650 13px/1.5 'Noto Sans Sinhala',system-ui,sans-serif; }
.physics-workspace .lvl .meta { display: block; margin-top: 4px; color: #637184; font: 500 11px/1.35 'Segoe UI',system-ui,sans-serif; }
.physics-workspace .side-card { top: 136px; display: flex; flex-direction: column; gap: 12px; }
.physics-workspace .physics-progress-panel, .physics-workspace .physics-plan-panel, .physics-workspace .physics-paper-panel { padding: 20px; border: 1px solid var(--physics-stroke); border-radius: 0; background: #fff; }
.physics-workspace .physics-sidebar h3 { margin: 0 0 6px; color: var(--physics-navy); font: 750 16px/1.4 'Segoe UI',system-ui,sans-serif; }
.physics-workspace .physics-sidebar p { margin: 0 0 13px; color: #607082; font: 500 12px/1.6 'Segoe UI',system-ui,sans-serif; }
.physics-workspace .physics-sidebar p strong { color: var(--physics-navy); font-size: 15px; }
.physics-workspace .physics-sidebar .progress { height: 6px; margin-top: 12px; background: #e8eef4; border: 0; border-radius: 0; }
.physics-workspace .physics-sidebar .progress > i { background: #10b889; }
.physics-workspace .physics-sidebar .btn { margin-top: 17px; min-height: 40px; border-radius: 4px; background: #1CE8A9; color: #082857; }
.physics-workspace .physics-inline-links { display: flex; flex-direction: column; gap: 9px; }
.physics-workspace .physics-inline-links a { color: var(--physics-navy); font: 750 12px/1.4 'Segoe UI',system-ui,sans-serif; text-decoration: none; }
.physics-workspace .physics-inline-links a:hover { text-decoration: underline; }
.physics-workspace .physics-plan-status { margin: 0; padding: 10px 14px; background: #eafcf5; }
.physics-workspace .physics-locked-label { color: #5e7086; font: 650 12px/1.5 'Segoe UI',system-ui,sans-serif; }
@media (max-width: 900px) {
  .physics-workspace .physics-learning-layout { grid-template-columns: minmax(0,1fr); gap: 16px; }
  .physics-workspace .side-card { position: static; display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); }
  .physics-workspace .physics-plan-status { grid-column: 1 / -1; }
}
@media (max-width: 700px) {
  .physics-container { width: min(100% - 36px, 1260px); }
  .physics-topline { min-height: 48px; }
  .physics-hero-inner { padding-top: 26px; }
  .physics-hero-main { align-items: flex-start; flex-direction: column; gap: 18px; }
  .physics-eyebrow { margin-bottom: 9px; }
  .physics-hero h1 { font-size: clamp(29px, 7vw, 39px); }
  .physics-hero p { margin-top: 7px; }
  .physics-continue { min-height: 39px; font-size: 12px; padding: 8px 13px; }
  .physics-hero-nav { gap: 0; margin-top: 23px; padding-bottom: 7px; grid-template-columns: 1fr; }
  .physics-workspace .physics-hero-nav :is(.physics-hero-link,.physics-local-link) { min-height: 39px; padding: 7px 8px; border-bottom: 1px solid rgba(255,255,255,.12); }
  .physics-workspace .physics-hero-nav :is(.physics-hero-link,.physics-local-link):last-child { border-bottom: 0; }
  .physics-workspace .mode-options-v2 { grid-template-columns: 1fr; gap: 10px; }
  .physics-workspace .mode-choice { min-height: 115px; padding: 16px; }
  .physics-workspace .physics-section-heading { align-items: flex-start; }
  .physics-workspace .trail { grid-template-columns: minmax(0,1fr); }
  .physics-workspace .side-card { grid-template-columns: minmax(0,1fr); }
}
@media (max-width: 400px) {
  .physics-container { width: calc(100% - 28px); }
  .physics-hero h1 { font-size: 28px; }
  .physics-workspace .mode-choice { padding: 13px; gap: 8px; }
  .physics-workspace .mode-choice-body b { font-size: 16px; }
  .physics-workspace .mode-choice small { font-size: 11px; }
  .physics-workspace .mode-choice-state { font-size: 11px; }
}
@media (prefers-reduced-motion: reduce) {
  .physics-workspace .mode-choice,
  .physics-workspace .physics-hero-nav :is(.physics-hero-link,.physics-local-link),
  .physics-workspace .physics-hero-link span,
  .physics-workspace .lvl,
  .physics-workspace .physics-continue { transition: none; }
}

/* Quiet data-loading and on-scroll interactions for student pages. */
.page-loading-shell {
  width: min(100% - 12px, 1180px);
  margin: 20px auto 48px;
  min-height: 280px;
  display: flex;
  flex-direction: column;
  gap: 19px;
}
.page-loading-shell .load-line, .page-loading-shell .load-card, .page-loading-shell .load-panel,
.page-loading-shell .load-hero { background: #e6edf3; border-radius: 0; }
.page-loading-shell .load-line { height: 15px; width: 95%; }
.page-loading-shell .load-line.medium { width: 54%; }
.page-loading-shell .load-line.short { height: 31px; width: 32%; }
.page-loading-shell .load-card-grid { display: grid; grid-template-columns: repeat(3,minmax(0,1fr)); gap: 16px; }
.page-loading-shell .load-two-col { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 16px; }
.page-loading-shell .load-card { min-height: 170px; }
.page-loading-shell .load-panel { min-height: 182px; padding: 22px; display: flex; flex-direction: column; gap: 17px; }
.page-loading-shell .load-panel.tall { min-height: 255px; }
.page-loading-shell .load-hero { min-height: 188px; background: #082857; padding: 35px; display: flex; flex-direction: column; gap: 22px; }
.page-loading-shell .load-hero .load-line { background: #254571; }
@keyframes ige-loading-sheen { 0% { opacity: .68; } 50% { opacity: 1; } 100% { opacity: .68; } }
.page-loading-shell :is(.load-line, .load-card, .load-panel) { animation: ige-loading-sheen 1.8s ease-in-out infinite; }
.page-reveal.page-reveal-pending {
  opacity: 0;
  transform: translate3d(0, 16px, 0);
}
.page-reveal {
  transition: opacity .85s cubic-bezier(.2,.7,.2,1), transform .85s cubic-bezier(.2,.7,.2,1);
  transition-delay: var(--page-reveal-delay, 0ms);
}
.page-reveal:not(.page-reveal-pending) { opacity: 1; transform: translate3d(0,0,0); }
.page-reveal[hidden] { display: none !important; }
@media (max-width: 700px) {
  .page-loading-shell { margin-top: 12px; }
  .page-loading-shell .load-card-grid { grid-template-columns: repeat(2,minmax(0,1fr)); gap: 10px; }
  .page-loading-shell .load-two-col { grid-template-columns: 1fr; gap: 12px; }
  .page-loading-shell .load-card { min-height: 125px; }
  .page-loading-shell .load-line.short { width: 55%; }
}
@media (prefers-reduced-motion: reduce) {
  .page-loading-shell :is(.load-line, .load-card, .load-panel) { animation: none !important; }
  .page-reveal { opacity: 1 !important; transform: none !important; transition: none !important; }
}
