/* ═══════════════════════════════════════════════════════════
   ئەندازیارنامە · Engineerpedia — minimal design on the animated blueprint background.
   Logical properties everywhere so RTL (ku, ar) and LTR (en, de) both work.
   Layout: one centred column (max 1180px), sections separated by space, thin hairlines for structure.
   ═══════════════════════════════════════════════════════════ */

/* ─────────── Zain (self-hosted, Google Fonts, SIL OFL) ─────────── */
@font-face { font-family: 'Zain'; font-style: normal; font-weight: 400; font-display: swap; src: url('../fonts/zain-arabic-400.woff2') format('woff2'); unicode-range: U+0600-06FF, U+0750-077F, U+0870-088E, U+08A0-08FF, U+200C-200E, U+FB50-FDFF, U+FE70-FEFF; }
@font-face { font-family: 'Zain'; font-style: normal; font-weight: 400; font-display: swap; src: url('../fonts/zain-latin-400.woff2') format('woff2'); unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+2000-206F, U+2070-209F, U+20A0-20BF; }
@font-face { font-family: 'Zain'; font-style: normal; font-weight: 700; font-display: swap; src: url('../fonts/zain-arabic-700.woff2') format('woff2'); unicode-range: U+0600-06FF, U+0750-077F, U+0870-088E, U+08A0-08FF, U+200C-200E, U+FB50-FDFF, U+FE70-FEFF; }
@font-face { font-family: 'Zain'; font-style: normal; font-weight: 700; font-display: swap; src: url('../fonts/zain-latin-700.woff2') format('woff2'); unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+2000-206F, U+2070-209F, U+20A0-20BF; }
@font-face { font-family: 'Zain'; font-style: normal; font-weight: 900; font-display: swap; src: url('../fonts/zain-arabic-900.woff2') format('woff2'); unicode-range: U+0600-06FF, U+0750-077F, U+0870-088E, U+08A0-08FF, U+200C-200E, U+FB50-FDFF, U+FE70-FEFF; }
@font-face { font-family: 'Zain'; font-style: normal; font-weight: 900; font-display: swap; src: url('../fonts/zain-latin-900.woff2') format('woff2'); unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+2000-206F, U+2070-209F, U+20A0-20BF; }

:root {
  color-scheme: dark;
  --bg: #03060d;
  --surface: rgba(9, 16, 30, .64);
  --surface-2: rgba(13, 23, 42, .8);
  --line: rgba(140, 180, 255, .12);
  --line-2: rgba(140, 180, 255, .22);
  --ink: #eef3fb;
  --ink-2: #b6c3d6;
  --muted: #7e8ea6;
  --green: #4ade80;
  --accent: #FFB81C;
  --accent-rgb: 255, 184, 28;
  --accent-ink: #0a1220;
  --radius: 18px;
  --ease: cubic-bezier(.22, .7, .28, 1);
  --font: 'Zain', system-ui, -apple-system, 'Segoe UI', Tahoma, sans-serif;
  --wrap: 1180px;
  --top: calc(66px + env(safe-area-inset-top, 0px));
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-padding-top: 90px; background: var(--bg); }
body {
  margin: 0; background: var(--bg); color: var(--ink);
  font-family: var(--font); font-size: 20px; line-height: 1.8;
  overflow-x: hidden; overflow-wrap: break-word;
  -webkit-font-smoothing: antialiased;
}
@supports (overflow-x: clip) { body { overflow-x: clip; } }
html[dir="ltr"] body { font-size: 19px; line-height: 1.7; }
img, svg { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; background: none; border: 0; cursor: pointer; padding: 0; }
input { font: inherit; }
h1, h2, h3, h4, p, figure, dl, dd { margin: 0; }
ul { margin: 0; padding: 0; list-style: none; }
[hidden] { display: none !important; }
em { font-style: normal; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.svg-defs { position: absolute; width: 0; height: 0; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; border-radius: 8px; }
::selection { background: rgba(var(--accent-rgb), .35); color: #fff; }
.ic { width: 1.1em; height: 1.1em; flex: none; }
html[dir="rtl"] .flip { transform: scaleX(-1); }
html[lang="de"] :is(h1, h2, h3, b) { hyphens: auto; -webkit-hyphens: auto; }

/* ─────────── Background layers (unchanged look) ─────────── */
#bg { position: fixed; inset: 0; z-index: 0; pointer-events: none; }
.grid-layer {
  position: fixed; inset: 0; z-index: 0; pointer-events: none; overflow: hidden;
  -webkit-mask-image: radial-gradient(ellipse 90% 80% at 50% 45%, #000 30%, transparent 100%);
  mask-image: radial-gradient(ellipse 90% 80% at 50% 45%, #000 30%, transparent 100%);
}
.grid-layer::before {
  content: ''; position: absolute; inset: 0 0 -120px 0;
  background-image:
    linear-gradient(rgba(95, 150, 235, .07) 1px, transparent 1px),
    linear-gradient(90deg, rgba(95, 150, 235, .07) 1px, transparent 1px),
    linear-gradient(rgba(95, 150, 235, .03) 1px, transparent 1px),
    linear-gradient(90deg, rgba(95, 150, 235, .03) 1px, transparent 1px);
  background-size: 120px 120px, 120px 120px, 24px 24px, 24px 24px;
  transform: translate3d(0, var(--gy, 0px), 0);
}
.vignette { position: fixed; inset: 0; z-index: 0; pointer-events: none; background: radial-gradient(ellipse at 50% 40%, transparent 42%, rgba(0, 0, 0, .66)); }
.noise { position: fixed; inset: 0; z-index: 0; pointer-events: none; opacity: .05; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='160'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.9' numOctaves='2' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E"); }

/* ─────────── Helmet (SVG, still) ─────────── */
.helmet { width: 100%; height: auto; overflow: visible; }
.helmet .hc { fill: var(--hc); }
.helmet .h-shadow { fill: url(#hg-shadow); }
.helmet .o-hi { fill: url(#hg-hi); }
.helmet .o-sh { fill: url(#hg-sh); }
.helmet .o-side { fill: url(#hg-side); }
.helmet .o-brim { fill: url(#hg-brim); }
.helmet .o-edge { fill: url(#hg-edge); }
.helmet .o-rib { fill: url(#hg-rib); }
.helmet .o-band { fill: #000; opacity: .26; }
.helmet .s-rib { fill: none; stroke: #000; stroke-opacity: .16; stroke-width: 3.2; stroke-linecap: round; }
.helmet .s-ribhi { fill: none; stroke: #fff; stroke-opacity: .3; stroke-width: 1.4; stroke-linecap: round; }
.helmet .s-lip { fill: none; stroke: #fff; stroke-opacity: .4; stroke-width: 1.6; stroke-linecap: round; }
.helmet .s-rim { fill: none; stroke: #fff; stroke-opacity: .2; stroke-width: 1.2; }
.helmet .spec { fill: url(#hg-spec); }
.helmet .spec2 { fill: #fff; opacity: .6; }

/* ─────────── Text motion (from the text-motion kit; colours are the site's own) ─────────── */
@keyframes page-in { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: none; } }
.page-in { animation: page-in .7s cubic-bezier(.25, .6, .3, 1) both; }

.js-reveal .reveal { opacity: 0; transform: translateY(28px); transition: opacity .85s var(--ease), transform .85s var(--ease); }
.js-reveal .reveal.is-in { opacity: 1; transform: none; }

.js-reveal .reveal.words { opacity: 1; transform: none; }
.js-reveal .reveal.words .word { display: inline-block; opacity: 0; transform: translateY(11px); transition: opacity .62s cubic-bezier(.25, .6, .3, 1), transform .62s cubic-bezier(.25, .6, .3, 1); }
.js-reveal .reveal.words.is-in .word { opacity: 1; transform: none; }

.js-reveal .reveal.lines { opacity: 1; transform: none; }
.js-reveal .reveal.lines:not([data-lines]) { opacity: 0; }
.js-reveal .tline { display: block; overflow: hidden; padding: .16em .12em; margin: -.16em -.12em; }
.js-reveal .tline-in { display: block; transform: translateY(102%); opacity: 0; transition: transform .8s cubic-bezier(.25, .6, .3, 1), opacity .6s cubic-bezier(.25, .6, .3, 1); }
.js-reveal .reveal.lines.is-in .tline-in { transform: none; opacity: 1; }

@keyframes fade { from { opacity: 0; } to { opacity: 1; } }
@keyframes fadeUp { from { opacity: 0; transform: translateY(12px); } to { opacity: 1; transform: none; } }
@keyframes fadeOut { to { opacity: 0; } }
@keyframes pop { from { opacity: 0; transform: translateY(16px) scale(.98); } to { opacity: 1; transform: none; } }

/* ─────────── Top bar ─────────── */
.topbar { position: fixed; top: 0; inset-inline: 0; z-index: 60; padding-top: env(safe-area-inset-top, 0px); border-bottom: 1px solid transparent; transition: background .35s, border-color .35s; }
.topbar.scrolled { background: rgba(3, 6, 13, .9); border-color: var(--line); }
.topbar-in { max-width: var(--wrap); margin-inline: auto; height: 66px; padding-inline: 20px; display: flex; align-items: center; gap: 20px; }
.brand { display: flex; align-items: center; gap: 10px; font-size: 23px; font-weight: 900; line-height: 1; }
.brand b { white-space: nowrap; }
.brand-helmet { width: 38px; }
.nav { display: flex; align-items: center; gap: 2px; margin-inline-start: auto; }
.nav a { padding: 6px 12px; border-radius: 10px; font-size: 17px; color: var(--ink-2); transition: color .25s, background .25s; }
.nav a:hover { color: var(--ink); background: rgba(255, 255, 255, .05); }
.nav .nav-cta { color: var(--accent); }
.lang { position: relative; }
.lang-btn { display: inline-flex; align-items: center; gap: 8px; height: 40px; padding-inline: 12px; border-radius: 12px; border: 1px solid var(--line-2); font-size: 15px; color: var(--ink-2); transition: border-color .25s, color .25s; }
.lang-btn:hover { color: var(--ink); border-color: rgba(var(--accent-rgb), .55); }
.lang-btn b { font-weight: 700; letter-spacing: .06em; }
.lang-menu { position: absolute; top: calc(100% + 8px); inset-inline-end: 0; min-width: 190px; padding: 6px; border-radius: 14px; background: #0a1322; border: 1px solid var(--line-2); box-shadow: 0 20px 50px rgba(0, 0, 0, .5); opacity: 0; visibility: hidden; transform: translateY(-6px); transition: opacity .2s, transform .2s, visibility .2s; }
.lang.open .lang-menu { opacity: 1; visibility: visible; transform: none; }
.lang-menu button { width: 100%; display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 9px 12px; border-radius: 10px; font-size: 17px; text-align: start; }
.lang-menu button:hover { background: rgba(255, 255, 255, .05); }
.lang-menu button.on { color: var(--accent); }
.lang-menu small { font-size: 12px; color: var(--muted); letter-spacing: .08em; }
.menu-btn { display: none; width: 42px; height: 42px; border-radius: 12px; border: 1px solid var(--line-2); place-items: center; }
.menu-btn .ic { width: 22px; height: 22px; }
.menu-btn .ic + .ic, body.menu-open .menu-btn .ic:first-child { display: none; }
body.menu-open .menu-btn .ic + .ic { display: block; }

/* ─────────── Layout ─────────── */
main { position: relative; z-index: 1; }
body.switching main { opacity: .4; transition: opacity .2s; }
.sec { position: relative; z-index: 1; max-width: var(--wrap); margin-inline: auto; padding-block: 104px; padding-inline: 20px; }
.sec-head { max-width: 780px; margin-block-end: 44px; }
.label { display: flex; align-items: center; gap: 10px; margin-block-end: 12px; font-size: 15px; font-weight: 700; color: var(--accent); }
.label::before { content: ''; width: 22px; height: 1px; background: currentColor; }
.label bdi { color: var(--muted); font-weight: 400; }
.h2 { font-size: clamp(34px, 4.6vw, 54px); font-weight: 900; line-height: 1.18; text-wrap: balance; }
.h2 .t2 { color: var(--accent); }
.lead { margin-block-start: 16px; max-width: 62ch; font-size: clamp(18px, 1.5vw, 20.5px); line-height: 1.9; color: var(--ink-2); }
.sub { display: flex; align-items: center; gap: 10px; margin-block-end: 10px; font-size: 23px; font-weight: 800; line-height: 1.4; }
.sub .ic { width: 22px; height: 22px; color: var(--accent); }
.note { margin-block-end: 20px; max-width: 72ch; font-size: 16.5px; color: var(--muted); }
.block { margin-block-start: 56px; }
.sec-head + .block { margin-block-start: 0; }
.two { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 32px; }
.panel { padding: 24px; border-radius: var(--radius); border: 1px solid var(--line); background: var(--surface); }
.n { font-variant-numeric: tabular-nums; }

/* Buttons */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 10px; min-height: 52px; padding-inline: 24px; border-radius: 14px; font-size: 18px; font-weight: 700; transition: background .25s, border-color .25s, color .25s, transform .25s; }
.btn .ic { width: 20px; height: 20px; }
.btn.primary { background: var(--accent); color: var(--accent-ink); }
.btn.primary:hover { transform: translateY(-2px); }
.btn.ghost { border: 1px solid var(--line-2); background: rgba(255, 255, 255, .02); }
.btn.ghost:hover { border-color: rgba(var(--accent-rgb), .6); }

/* ─────────── Hero ─────────── */
.hero { position: relative; z-index: 1; max-width: 920px; margin-inline: auto; padding-block: calc(var(--top) + 96px) 88px; padding-inline: 20px; display: flex; flex-direction: column; align-items: center; text-align: center; }
.hero-helmet { width: 128px; margin-block-end: 26px; }
.kicker { margin-block-end: 16px; font-size: 14px; font-weight: 700; letter-spacing: .2em; color: var(--muted); }
.hero-title { font-size: clamp(46px, 8vw, 96px); font-weight: 900; line-height: 1.1; text-wrap: balance; }
.hero-title .ln { display: block; }
.hero-title .acc { color: var(--accent); }
.hero-lead { margin-block-start: 24px; max-width: 58ch; font-size: clamp(18px, 1.6vw, 21px); line-height: 1.9; color: var(--ink-2); }
.hero-cta { margin-block-start: 34px; display: flex; flex-wrap: wrap; justify-content: center; gap: 12px; }

/* ─────────── Ticker ─────────── */
.ticker { position: relative; z-index: 1; overflow: hidden; padding-block: 20px; border-block: 1px solid var(--line); background: rgba(3, 6, 13, .55);
  -webkit-mask-image: linear-gradient(90deg, transparent, #000 9%, #000 91%, transparent); mask-image: linear-gradient(90deg, transparent, #000 9%, #000 91%, transparent); }
.ticker-track { display: flex; width: max-content; animation: tk 80s linear infinite; will-change: transform; }
html[dir="rtl"] .ticker-track { animation-name: tk-rtl; }
.ticker:hover .ticker-track { animation-play-state: paused; }
@keyframes tk { to { transform: translate3d(-50%, 0, 0); } }
@keyframes tk-rtl { to { transform: translate3d(50%, 0, 0); } }
.tk { display: inline-flex; align-items: center; gap: 14px; padding-inline: 26px; font-size: 22px; font-weight: 700; color: var(--ink-2); white-space: nowrap; transition: color .3s; }
.tk i { width: 9px; height: 9px; border-radius: 50%; background: var(--c); }
.tk:hover { color: var(--c); }

/* ─────────── Numbers ─────────── */
.stats { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); border-top: 1px solid var(--line); }
.stat { display: flex; flex-direction: column; gap: 4px; padding: 26px 20px 4px; }
.stat + .stat { border-inline-start: 1px solid var(--line); }
.stat .ic { width: 26px; height: 26px; color: var(--accent); margin-block-end: 6px; }
.stat b { font-size: clamp(40px, 4.4vw, 56px); font-weight: 900; line-height: 1.05; font-variant-numeric: tabular-nums; direction: ltr; unicode-bidi: isolate; text-align: left; }
html[dir="rtl"] .stat b, html[dir="rtl"] .mini .volt, html[dir="rtl"] .std .key { text-align: right; }
.stat b em { color: var(--accent); }
.stat span { font-size: 17px; color: var(--muted); line-height: 1.5; }

/* ─────────── Departments ─────────── */
.search { display: flex; align-items: center; gap: 12px; max-width: 520px; height: 56px; padding-inline: 18px; margin-block-end: 28px; border-radius: 14px; border: 1px solid var(--line-2); background: var(--surface); transition: border-color .25s; }
.search:focus-within { border-color: rgba(var(--accent-rgb), .6); }
.search .ic { width: 20px; height: 20px; color: var(--muted); }
.search input { flex: 1; min-width: 0; background: none; border: 0; outline: 0; color: var(--ink); font-size: 18px; }
.search input::placeholder { color: var(--muted); }
.dept-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 20px; }
.empty { grid-column: 1 / -1; color: var(--muted); }
.dcard { position: relative; display: flex; flex-direction: column; overflow: hidden; border-radius: var(--radius); border: 1px solid var(--line); background: var(--surface); transition: border-color .3s, background .3s; }
.dcard:hover { border-color: rgba(var(--c-rgb), .55); background: var(--surface-2); }
.dcard-cover { position: relative; display: block; aspect-ratio: 16 / 9; overflow: hidden; background: linear-gradient(135deg, rgba(var(--c-rgb), .22), rgba(9, 16, 30, .9)); }
.dcard-cover img { width: 100%; height: 100%; object-fit: cover; opacity: 0; transition: opacity .6s; }
.dcard-cover img.ok { opacity: .78; }
.dcard-cover::after { content: ''; position: absolute; inset: 0; background: linear-gradient(180deg, transparent 35%, rgba(6, 12, 24, .92)); }
.dcard-helmet { position: relative; z-index: 1; display: block; width: 78px; margin-block: -44px 0; margin-inline: 18px; }
.dcard-body { display: flex; flex-direction: column; gap: 4px; flex: 1; padding: 8px 20px 18px; }
.dcard h3 { font-size: 24px; font-weight: 900; line-height: 1.3; }
.den { font-size: 12.5px; letter-spacing: .1em; text-transform: uppercase; color: var(--c); line-height: 1.6; }
.dtag { margin-block-start: 4px; font-size: 16.5px; line-height: 1.75; color: var(--ink-2); display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.dmeta { display: flex; flex-wrap: wrap; gap: 4px 16px; margin-block-start: auto; padding-block-start: 14px; font-size: 15px; color: var(--muted); }
.dmeta .hc { display: inline-flex; align-items: center; gap: 7px; color: var(--c); }
.dmeta i { width: 8px; height: 8px; border-radius: 50%; background: var(--c); }

/* ─────────── Safety ─────────── */
.codes { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); column-gap: 36px; }
.codes li { display: flex; align-items: baseline; gap: 14px; padding-block: 13px; border-bottom: 1px solid var(--line); }
.codes .dot { flex: none; width: 13px; height: 13px; border-radius: 50%; background: var(--c); box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .25); transform: translateY(1px); }
.codes b { flex: none; min-width: 5.5em; font-weight: 800; }
.codes span:last-child { font-size: 17px; color: var(--ink-2); }
.mini-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
.mini-grid.c3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.style-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; }
.mini { padding: 20px; border-radius: var(--radius); border: 1px solid var(--line); background: var(--surface); }
.mini .key { display: inline-block; font-size: 14px; font-weight: 700; color: var(--accent); direction: ltr; unicode-bidi: isolate; }
.mini b { display: block; margin-block: 2px 4px; font-size: 19px; font-weight: 800; line-height: 1.4; }
.mini em { display: block; font-size: 13px; color: var(--muted); unicode-bidi: plaintext; margin-block-end: 4px; }
.mini p { font-size: 16px; line-height: 1.75; color: var(--ink-2); }
.mini .volt { display: block; margin-block-end: 4px; font-size: 22px; font-weight: 900; font-variant-numeric: tabular-nums; unicode-bidi: isolate; text-align: start; }
.std li, .care li { display: flex; gap: 14px; padding-block: 11px; border-bottom: 1px solid var(--line); font-size: 17px; color: var(--ink-2); }
.std li:last-child, .care li:last-child { border-bottom: 0; }
.std .key { flex: none; min-width: 8.6em; font-weight: 700; color: var(--ink); direction: ltr; unicode-bidi: isolate; text-align: start; }
.care .ic { color: var(--green); margin-block-start: 6px; }
.ppe-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; }
.ppe { display: flex; align-items: flex-start; gap: 14px; padding: 18px; border-radius: var(--radius); border: 1px solid var(--line); background: var(--surface); }
.ppe > div { min-width: 0; }
.ppe-ic { flex: none; width: 44px; height: 44px; border-radius: 12px; display: grid; place-items: center; color: var(--accent); background: rgba(var(--accent-rgb), .1); }
.ppe-ic .ic { width: 24px; height: 24px; }
.ppe b { font-size: 18px; font-weight: 800; line-height: 1.4; }
.ppe p { font-size: 15.5px; line-height: 1.7; color: var(--ink-2); }
.ppe-dots { display: flex; flex-wrap: wrap; gap: 5px; margin-block-start: 10px; }
.ppe-dots i { width: 8px; height: 8px; border-radius: 50%; }

/* ─────────── Software ─────────── */
.chips { display: flex; gap: 8px; margin-block-end: 24px; padding-block-end: 6px; overflow-x: auto; scrollbar-width: none; }
.chips::-webkit-scrollbar { display: none; }
.chips button { flex: none; white-space: nowrap; display: inline-flex; align-items: center; gap: 8px; height: 38px; padding-inline: 14px; border-radius: 999px; border: 1px solid var(--line-2); font-size: 15.5px; color: var(--ink-2); transition: color .25s, border-color .25s, background .25s; }
.chips button i { width: 8px; height: 8px; border-radius: 50%; background: var(--c); }
.chips button:hover { color: var(--ink); border-color: rgba(var(--accent-rgb), .45); }
.chips button.on { background: var(--ink); border-color: var(--ink); color: #06101f; }
.sw-grid { display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); gap: 12px; }
.sw-grid.collapsed .swt.x { display: none; }
.swt { display: flex; flex-direction: column; align-items: center; gap: 6px; padding: 18px 10px 16px; text-align: center; border-radius: var(--radius); border: 1px solid var(--line); background: var(--surface); transition: border-color .25s, background .25s; }
.swt:hover { border-color: rgba(var(--c-rgb), .6); background: var(--surface-2); }
.swt b { font-size: 16.5px; font-weight: 800; line-height: 1.3; }
.swt small { font-size: 13.5px; line-height: 1.4; color: var(--muted); }
.logo { position: relative; flex: none; width: 52px; height: 52px; border-radius: 14px; display: grid; place-items: center; overflow: hidden; background: linear-gradient(140deg, rgba(var(--c-rgb), .95), rgba(var(--c-rgb), .5)); color: var(--c-ink, #fff); font-size: 18px; font-weight: 900; }
.logo.lg { width: 76px; height: 76px; border-radius: 20px; font-size: 26px; }
.logo img { position: absolute; inset: 20%; width: 60%; height: 60%; object-fit: contain; opacity: 0; transition: opacity .3s; }
.logo.has-img img { opacity: 1; }
.logo.has-img .mono { opacity: 0; }
.more-wrap { display: flex; justify-content: center; margin-block-start: 24px; }

/* ─────────── Engineers (home) ─────────── */
.legs { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); gap: 14px; }
.leg { display: flex; flex-direction: column; gap: 6px; min-width: 0; }
.leg-ph { position: relative; display: block; aspect-ratio: 4 / 5; overflow: hidden; border-radius: 14px; border: 1px solid var(--line); background: rgba(var(--c-rgb), .08); transition: border-color .25s; }
.leg:hover .leg-ph { border-color: rgba(var(--c-rgb), .65); }
.leg b { margin-block-start: 4px; font-size: 16.5px; font-weight: 800; line-height: 1.35; }
.leg small { display: flex; align-items: center; gap: 6px; font-size: 14px; line-height: 1.4; color: var(--muted); }
.leg small i { flex: none; width: 7px; height: 7px; border-radius: 50%; background: var(--c); }

/* Image placeholders */
.ph { position: relative; overflow: hidden; }
.ph img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; opacity: 0; transition: opacity .5s; }
.ph img.ok { opacity: 1; }
.ph-fb { position: absolute; inset: 0; display: grid; place-items: center; font-size: 26px; font-weight: 900; color: rgba(255, 255, 255, .35); }
.ph-fb .ic { width: 34px; height: 34px; }
.ph.loaded .ph-fb { display: none; }

/* ─────────── Quiz ─────────── */
.quiz { max-width: 880px; padding: 28px; border-radius: 22px; border: 1px solid var(--line); background: var(--surface); }
.quiz.qz-anim > * { animation: fadeUp .45s var(--ease) both; }
.qz-top { display: flex; align-items: center; gap: 14px; margin-block-end: 18px; font-size: 15px; color: var(--muted); }
.qz-top .ic { color: var(--green); width: 22px; height: 22px; }
.qz-bar { flex: 1; height: 3px; border-radius: 3px; overflow: hidden; background: var(--line); }
.qz-bar i { display: block; height: 100%; background: var(--accent); transition: width .5s var(--ease); }
.qz-q { margin-block-end: 18px; font-size: clamp(22px, 2.4vw, 28px); font-weight: 800; line-height: 1.4; }
.qz-opts { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
.qz-opt { display: flex; align-items: center; gap: 12px; padding: 14px 16px; text-align: start; border-radius: 14px; border: 1px solid var(--line-2); font-size: 17.5px; line-height: 1.5; transition: border-color .2s, background .2s; }
.qz-opt .k { flex: none; width: 28px; height: 28px; border-radius: 8px; display: grid; place-items: center; font-size: 14px; background: rgba(255, 255, 255, .06); }
.qz-opt:hover { border-color: rgba(var(--accent-rgb), .7); background: rgba(var(--accent-rgb), .06); }
.qz-reset { display: inline-flex; align-items: center; gap: 8px; margin-block-start: 18px; font-size: 16px; color: var(--muted); transition: color .2s; }
.qz-reset:hover { color: var(--ink); }
.qz-res { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; }
.qz-card { display: flex; flex-direction: column; gap: 6px; padding: 18px; border-radius: 16px; border: 1px solid rgba(var(--c-rgb), .4); background: rgba(var(--c-rgb), .06); transition: border-color .25s; }
.qz-card:hover { border-color: rgba(var(--c-rgb), .8); }
.qz-helmet { width: 84px; }
.qz-card b { font-size: 19px; font-weight: 800; line-height: 1.35; }
.qz-pct { height: 4px; border-radius: 4px; overflow: hidden; background: var(--line); }
.qz-pct i { display: block; height: 100%; background: var(--c); }
.qz-card small { font-size: 15px; color: var(--muted); }
.qz-note { margin-block-start: 16px; font-size: 15.5px; color: var(--muted); }

/* ─────────── Other fields ─────────── */
.others { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); column-gap: 40px; }
.other { padding-block: 16px; border-bottom: 1px solid var(--line); }
.other b { font-size: 19px; font-weight: 800; }
.other p { font-size: 16.5px; color: var(--ink-2); }

/* ─────────── Footer ─────────── */
.footer { position: relative; z-index: 1; border-top: 1px solid var(--line); background: rgba(3, 6, 13, .78); }
.foot-in { max-width: var(--wrap); margin-inline: auto; padding: 48px 20px 28px; display: grid; grid-template-columns: minmax(0, 1.1fr) minmax(0, 1fr); gap: 32px; }
.foot-brand b { font-size: 24px; font-weight: 900; }
.foot-brand p, .foot-note p { font-size: 15.5px; line-height: 1.8; color: var(--muted); }
.foot-note p + p { margin-block-start: 8px; }
.credit { max-width: var(--wrap); margin-inline: auto; padding: 16px 20px calc(24px + env(safe-area-inset-bottom, 0px)); display: flex; align-items: center; justify-content: space-between; gap: 16px; border-top: 1px solid var(--line); font-size: 14px; color: var(--muted); }
.credit .dev { color: var(--ink-2); }
.to-top { display: inline-flex; align-items: center; gap: 6px; color: var(--muted); transition: color .2s; }
.to-top:hover { color: var(--ink); }

/* ─────────── Department page ─────────── */
.d-hero { position: relative; z-index: 1; display: flex; align-items: flex-end; min-height: min(80svh, 760px); overflow: hidden; }
.d-cover { position: absolute; inset: 0; background-size: cover; background-position: center; opacity: 0; transition: opacity .9s; }
.d-cover.ok { opacity: .5; }
.d-hero::after { content: ''; position: absolute; inset: 0; pointer-events: none; background: linear-gradient(180deg, rgba(3, 6, 13, .6), rgba(3, 6, 13, .3) 38%, var(--bg)); }
.d-hero-in { position: relative; z-index: 2; width: 100%; max-width: var(--wrap); margin-inline: auto; padding-block: calc(var(--top) + 70px) 56px; padding-inline: 20px; display: grid; grid-template-columns: minmax(0, 1fr) 300px; gap: 40px; align-items: end; }
.d-hero-tx { min-width: 0; container-type: inline-size; }
.back { display: inline-flex; align-items: center; gap: 8px; margin-block-end: 22px; font-size: 16px; color: var(--ink-2); transition: color .2s; }
.back:hover { color: var(--ink); }
.d-hero h1 { font-size: clamp(44px, 6.4vw, 92px); font-weight: 900; line-height: 1.1; text-wrap: balance; }
@supports (width: 1cqi) { .d-hero h1 { font-size: min(clamp(44px, 6.4vw, 92px), calc(100cqi / (var(--lw, 8) * .63))); } }
.d-en { margin-block-start: 8px; font-size: 14px; letter-spacing: .16em; text-transform: uppercase; color: var(--c); }
.d-tag { margin-block-start: 16px; max-width: 54ch; font-size: clamp(18px, 1.6vw, 22px); line-height: 1.8; color: var(--ink-2); }
.d-chips { display: flex; flex-wrap: wrap; gap: 8px; margin-block-start: 22px; }
.d-chips span { display: inline-flex; align-items: center; gap: 8px; height: 38px; padding-inline: 14px; border-radius: 999px; border: 1px solid var(--line-2); background: rgba(3, 6, 13, .55); font-size: 15.5px; color: var(--ink-2); }
.d-chips .ic { color: var(--c); }
.d-hero-helmet { justify-self: center; width: 100%; max-width: 280px; text-align: center; }
.d-hlabel { display: inline-flex; align-items: center; gap: 10px; margin-block-start: 14px; font-size: 15px; color: var(--muted); }
.d-hlabel i { width: 10px; height: 10px; border-radius: 50%; background: var(--c); }
.d-hlabel b { color: var(--c); font-weight: 700; }

.d-tabs { position: sticky; top: var(--top); z-index: 40; background: rgba(3, 6, 13, .94); border-block: 1px solid var(--line); }
.d-tabs-in { max-width: var(--wrap); margin-inline: auto; padding-inline: 8px; display: flex; overflow-x: auto; scrollbar-width: none; }
.d-tabs-in::-webkit-scrollbar { display: none; }
.d-tabs button { flex: none; padding: 13px 14px; font-size: 16px; color: var(--muted); white-space: nowrap; border-bottom: 2px solid transparent; transition: color .25s, border-color .25s; }
.d-tabs button:hover { color: var(--ink-2); }
.d-tabs button.on { color: var(--ink); border-color: var(--c); }
.dept .label, .dept .sub .ic, .dept .h2 .t2 { color: var(--c); }
.d-sec { padding-block: 88px; }
.d-sec + .d-sec { border-top: 1px solid var(--line); }

.about-grid { display: grid; grid-template-columns: minmax(0, 1.55fr) minmax(0, 1fr); gap: 36px; align-items: start; margin-block-end: 48px; }
.about-tx { font-size: clamp(18px, 1.5vw, 20.5px); line-height: 1.95; color: var(--ink-2); }
.fact { display: flex; gap: 14px; padding: 22px; border-radius: var(--radius); border: 1px solid rgba(var(--c-rgb), .35); background: rgba(var(--c-rgb), .06); }
.fact .ic { width: 26px; height: 26px; margin-block-start: 4px; color: var(--c); }
.fact b { display: block; margin-block-end: 4px; font-weight: 800; }
.fact p { font-size: 16.5px; line-height: 1.8; color: var(--ink-2); }
.nature { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); column-gap: 36px; }
.nature li { display: flex; gap: 12px; padding-block: 14px; border-bottom: 1px solid var(--line); color: var(--ink-2); }
.nature li::before { content: ''; flex: none; width: 7px; height: 7px; margin-block-start: .72em; border-radius: 50%; background: var(--c); }

.stages { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; }
.stages.s5 { grid-template-columns: repeat(5, minmax(0, 1fr)); }
.stage { padding: 20px; border-radius: var(--radius); border: 1px solid var(--line); background: var(--surface); }
.stage-h { display: flex; align-items: center; gap: 10px; margin-block-end: 10px; padding-block-end: 12px; border-bottom: 1px solid var(--line); }
.stage-n { width: 30px; height: 30px; border-radius: 9px; display: grid; place-items: center; font-size: 16px; font-weight: 900; color: var(--c); background: rgba(var(--c-rgb), .14); }
.stage-h b { font-size: 18px; font-weight: 800; }
.stage li { padding-block: 6px; font-size: 16.5px; line-height: 1.5; }
.stage li em, .grad li em, .br em { display: block; font-size: 13px; color: var(--muted); unicode-bidi: plaintext; line-height: 1.5; }
html[dir="rtl"] :is(.stage li em, .grad li em, .br em, .mini em, .eng-info > em, .proj-b em) { text-align: right; }
.study-note { display: flex; gap: 10px; margin-block-start: 20px; max-width: 80ch; font-size: 15.5px; color: var(--muted); }
.study-note .ic { margin-block-start: 6px; }

.count { margin-block-start: 12px; font-size: 18px; color: var(--ink-2); }
.count b { font-size: 1.3em; font-weight: 900; color: var(--c); }
.br-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
.br { padding: 20px; border-radius: var(--radius); border: 1px solid var(--line); background: var(--surface); }
.br b { font-size: 19px; font-weight: 800; line-height: 1.4; }
.br em { color: var(--c); }
.br p { margin-block-start: 6px; font-size: 16.5px; line-height: 1.75; color: var(--ink-2); }

.grad { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
.grad-h { display: flex; align-items: center; gap: 10px; margin-block-end: 8px; }
.grad-h .ic { width: 24px; height: 24px; color: var(--c); }
.grad-h b { flex: 1; font-size: 20px; font-weight: 800; }
.grad-h .tag { font-size: 13px; color: var(--muted); padding: 2px 10px; border-radius: 999px; border: 1px solid var(--line-2); }
.grad li { padding-block: 9px; border-bottom: 1px solid var(--line); font-size: 17px; }
.grad li:last-child { border-bottom: 0; }

.swd-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
.swd { display: flex; align-items: flex-start; gap: 14px; padding: 16px; text-align: start; border-radius: var(--radius); border: 1px solid var(--line); background: var(--surface); transition: border-color .25s, background .25s; }
.swd:hover { border-color: rgba(var(--c-rgb), .55); background: var(--surface-2); }
.swd-tx { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.swd b { font-size: 18px; font-weight: 800; }
.swd .p { font-size: 15.5px; line-height: 1.7; color: var(--ink-2); }
.swd .more { display: inline-flex; align-items: center; gap: 6px; margin-block-start: 6px; font-size: 14.5px; color: var(--c); }

.jobs { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); column-gap: 36px; }
.job { display: flex; align-items: center; gap: 12px; padding-block: 14px; border-bottom: 1px solid var(--line); color: var(--ink-2); }
.job > span { min-width: 0; }
.job .ic { color: var(--c); }

.safe { display: grid; grid-template-columns: 320px minmax(0, 1fr); gap: 32px; align-items: start; }
.safe-card { position: sticky; top: calc(var(--top) + 64px); padding: 24px; border-radius: 22px; border: 1px solid rgba(var(--c-rgb), .35); background: var(--surface); }
.safe-vis { width: 72%; margin: 0 auto 14px; }
.safe-card dl { display: grid; grid-template-columns: auto minmax(0, 1fr); gap: 8px 16px; font-size: 16px; }
.safe-card dt { color: var(--muted); }
.safe-card dd { display: flex; align-items: center; gap: 8px; font-weight: 700; }
.safe-card dd[dir="ltr"] { justify-content: flex-end; }
html[dir="ltr"] .safe-card dd[dir="ltr"] { justify-content: flex-start; }
.safe-card dd i { width: 12px; height: 12px; border-radius: 50%; }
.why { margin-block-start: 14px; padding-block-start: 14px; border-top: 1px solid var(--line); font-size: 15.5px; line-height: 1.8; color: var(--ink-2); }
.safe-ppe { min-width: 0; }
.ppe-list { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
.dept .ppe-ic { color: var(--c); background: rgba(var(--c-rgb), .12); }
.tip { display: flex; gap: 12px; margin-block-start: 16px; padding: 18px; border-radius: var(--radius); border: 1px solid rgba(74, 222, 128, .35); background: rgba(74, 222, 128, .06); }
.tip .ic { width: 24px; height: 24px; margin-block-start: 4px; color: var(--green); }
.tip b { display: block; font-weight: 800; }
.tip p { font-size: 16px; line-height: 1.8; color: var(--ink-2); }

.engs { display: flex; flex-direction: column; gap: 18px; }
.eng { padding: 24px; border-radius: 22px; border: 1px solid var(--line); background: var(--surface); }
.eng-head { display: grid; grid-template-columns: 150px minmax(0, 1fr); gap: 22px; align-items: start; }
.eng-ph { aspect-ratio: 4 / 5; border-radius: 14px; background: rgba(var(--c-rgb), .1); }
.eng-info h3 { font-size: 26px; font-weight: 900; line-height: 1.25; }
.eng-info > em { display: block; font-size: 14px; color: var(--c); unicode-bidi: plaintext; }
.eng-meta { display: flex; flex-wrap: wrap; gap: 6px 16px; margin-block: 8px 10px; font-size: 15px; color: var(--muted); }
.eng-meta span { display: inline-flex; align-items: center; gap: 6px; }
.eng-info > p { font-size: 17px; line-height: 1.85; color: var(--ink-2); }
.links { display: flex; flex-wrap: wrap; gap: 8px; margin-block-start: 14px; }
.links a, .bio-btn { display: inline-flex; align-items: center; gap: 6px; height: 36px; padding-inline: 12px; border-radius: 10px; border: 1px solid var(--line-2); font-size: 15px; color: var(--ink-2); transition: color .2s, border-color .2s; }
.links a:hover, .bio-btn:hover { color: var(--ink); border-color: rgba(var(--c-rgb, var(--accent-rgb)), .6); }
.bio-btn .ic:last-child { transition: transform .3s; }
.eng.open .bio-btn .ic:last-child { transform: rotate(180deg); }
.story { display: grid; grid-template-rows: 0fr; transition: grid-template-rows .45s var(--ease); }
.story > div { overflow: hidden; }
.eng.open .story { grid-template-rows: 1fr; }
.story p { padding-block-start: 14px; font-size: 16.5px; line-height: 1.95; color: var(--ink-2); }
.projs { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; margin-block-start: 20px; }
.proj { display: flex; flex-direction: column; overflow: hidden; border-radius: 16px; border: 1px solid var(--line); background: rgba(3, 6, 13, .35); }
.proj-ph { aspect-ratio: 16 / 10; background: rgba(var(--c-rgb), .08); }
.proj-y { position: absolute; inset-block-end: 8px; inset-inline-end: 8px; z-index: 1; padding: 1px 8px; border-radius: 8px; font-size: 13px; background: rgba(3, 6, 13, .78); }
.proj-b { display: flex; flex-direction: column; gap: 4px; flex: 1; padding: 14px; }
.proj-b b { font-size: 17px; font-weight: 800; line-height: 1.4; }
.proj-b em { font-size: 12.5px; color: var(--muted); unicode-bidi: plaintext; }
.proj-b p { font-size: 15px; line-height: 1.7; color: var(--ink-2); }
.proj-f { display: flex; align-items: center; gap: 8px; margin-block-start: auto; padding-block-start: 10px; font-size: 14px; color: var(--muted); }
.proj-f span { display: flex; align-items: center; gap: 6px; flex: 1; min-width: 0; }
.proj-f a { flex: none; width: 32px; height: 32px; border-radius: 9px; display: grid; place-items: center; border: 1px solid var(--line-2); transition: border-color .2s, color .2s; }
.proj-f a:hover { color: var(--ink); border-color: rgba(var(--c-rgb), .6); }

.pn { position: relative; z-index: 1; max-width: var(--wrap); margin-inline: auto; padding: 24px 20px 88px; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; }
.pn-card { display: flex; align-items: center; gap: 16px; padding: 18px 20px; border-radius: var(--radius); border: 1px solid var(--line); background: var(--surface); transition: border-color .25s; }
.pn-card:hover { border-color: rgba(var(--c-rgb), .6); }
.pn-card.nx { flex-direction: row-reverse; text-align: end; }
.pn-h { flex: none; width: 64px; }
.pn-tx { display: flex; flex-direction: column; min-width: 0; }
.pn-dir { display: flex; align-items: center; gap: 6px; font-size: 14.5px; color: var(--muted); }
.pn-card.nx .pn-dir { justify-content: flex-end; }
.pn-card b { font-size: 20px; font-weight: 800; line-height: 1.35; color: var(--c); overflow-wrap: anywhere; hyphens: auto; }

/* ─────────── Software modal ─────────── */
.modal { position: fixed; inset: 0; z-index: 90; display: grid; place-items: center; padding: 16px; }
.modal-veil { position: absolute; inset: 0; background: rgba(2, 5, 10, .84); animation: fade .25s ease; }
.modal-box { position: relative; width: min(820px, 100%); max-height: calc(100svh - 32px); overflow: auto; border-radius: 24px; border: 1px solid var(--line-2); background: #0a1322; box-shadow: 0 40px 100px rgba(0, 0, 0, .55); animation: pop .35s var(--ease); scrollbar-width: thin; }
.modal-close { position: absolute; top: 14px; inset-inline-end: 14px; z-index: 2; width: 40px; height: 40px; border-radius: 12px; display: grid; place-items: center; border: 1px solid var(--line-2); background: rgba(3, 6, 13, .7); }
.modal-close .ic { width: 20px; height: 20px; }
.mh { display: flex; align-items: center; gap: 16px; padding: 24px; padding-inline-end: 70px; }
.mh h3 { font-size: 30px; font-weight: 900; line-height: 1.2; }
.meta { display: flex; flex-wrap: wrap; gap: 2px 16px; font-size: 15px; color: var(--muted); }
.meta span { display: inline-flex; align-items: center; gap: 6px; }
.mshot { aspect-ratio: 16 / 8; margin-inline: 24px; border-radius: 16px; background: rgba(var(--c-rgb), .08); }
.mb { display: grid; gap: 18px; padding: 20px 24px 24px; }
.mb h4 { display: flex; align-items: center; gap: 8px; margin-block-end: 6px; font-size: 18px; font-weight: 800; }
.mb h4 .ic { color: var(--c); }
.mb p { font-size: 16.5px; line-height: 1.85; color: var(--ink-2); }
.mworks li { display: flex; gap: 12px; padding-block: 8px; border-bottom: 1px solid var(--line); font-size: 16px; color: var(--ink-2); }
.mworks li::before { content: ''; flex: none; width: 6px; height: 6px; margin-block-start: .75em; border-radius: 50%; background: var(--c); }
.mworks li:last-child { border-bottom: 0; }
.mdepts { display: flex; flex-wrap: wrap; gap: 8px; }
.mdepts a { display: inline-flex; align-items: center; gap: 7px; height: 34px; padding-inline: 12px; border-radius: 999px; border: 1px solid var(--line-2); font-size: 15px; transition: border-color .2s; }
.mdepts a:hover { border-color: var(--dc); }
.mdepts i { width: 8px; height: 8px; border-radius: 50%; background: var(--dc); }
.modal .links { margin-block-start: 0; }

/* ─────────── Helmet put on when entering a department ─────────── */
.drop { position: fixed; inset: 0; z-index: 100; display: grid; place-items: center; cursor: pointer; }
.drop-veil { position: absolute; inset: 0; background: rgba(3, 6, 13, .92); }
.drop-center { position: relative; width: 200px; height: 210px; }
.drop-person { width: 100%; height: 100%; fill: none; stroke: rgba(var(--c-rgb), .85); stroke-width: 2.4; stroke-linecap: round; stroke-linejoin: round; }
.drop-helmet { position: absolute; left: 50%; top: 14px; width: 140px; transform: translate(-50%, 0); }
.drop-title, .drop-sub { position: absolute; left: 50%; translate: -50% 0; width: min(92vw, 640px); text-align: center; opacity: 0; text-wrap: balance; }
.drop-title { top: 104%; font-size: clamp(24px, 4vw, 34px); font-weight: 900; line-height: 1.3; color: var(--c); }
.drop-sub { top: calc(104% + 54px); font-size: 17px; color: var(--ink-2); }
.drop.run .drop-veil { animation: fade .3s ease both; }
.drop.run .drop-person { animation: fadeUp .45s var(--ease) .05s both; }
.drop.run .drop-helmet { animation: hdrop .75s cubic-bezier(.3, 1.12, .5, 1) .18s both; }
@keyframes hdrop { 0% { transform: translate(-50%, -50vh); opacity: 0; } 20% { opacity: 1; } 100% { transform: translate(-50%, 0); opacity: 1; } }
.drop.run .drop-title { animation: fadeUp .5s var(--ease) .55s both; }
.drop.run .drop-sub { animation: fadeUp .5s var(--ease) .68s both; }
.drop.out { animation: fadeOut .35s ease both; }

/* ─────────── Responsive ─────────── */
@media (max-width: 1080px) {
  .nav a { padding-inline: 9px; font-size: 16px; }
  .dept-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .sw-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); }
  .ppe-grid, .style-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .stages, .stages.s5 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .two, .about-grid, .safe { grid-template-columns: minmax(0, 1fr); }
  .safe-card { position: static; }
  .legs { grid-template-columns: repeat(7, minmax(110px, 1fr)); overflow-x: auto; padding-block-end: 8px; scroll-snap-type: x mandatory; scrollbar-width: thin; }
  .leg { scroll-snap-align: start; }
}
@media (max-width: 860px) {
  .menu-btn { display: grid; }
  .lang { margin-inline-start: auto; }
  .nav { position: fixed; top: var(--top); inset-inline: 0; margin: 0; padding: 10px 16px 16px; flex-direction: column; align-items: stretch; gap: 2px; background: rgba(3, 6, 13, .97); border-bottom: 1px solid var(--line); opacity: 0; visibility: hidden; transform: translateY(-8px); transition: opacity .2s, transform .2s, visibility .2s; }
  body.menu-open .nav { opacity: 1; visibility: visible; transform: none; }
  .nav a { padding: 12px; font-size: 18px; border-radius: 12px; }
  body.menu-open .topbar { background: rgba(3, 6, 13, .97); border-color: var(--line); }
  .d-hero-in { grid-template-columns: minmax(0, 1fr); gap: 20px; padding-block-start: calc(var(--top) + 40px); }
  .d-hero-helmet { order: -1; display: flex; align-items: center; gap: 14px; max-width: none; justify-self: start; text-align: start; }
  .d-hero-helmet .helmet { width: 150px; flex: none; }
  .d-hlabel { margin: 0; flex-wrap: wrap; }
}
@media (max-width: 760px) {
  body { font-size: 18.5px; }
  html[dir="ltr"] body { font-size: 18px; }
  .topbar-in { padding-inline: 16px; gap: 12px; }
  .brand { font-size: 21px; }
  .brand-helmet { width: 34px; }
  .sec { padding-block: 68px; padding-inline: 16px; }
  .d-sec { padding-block: 60px; }
  .sec-head { margin-block-end: 32px; }
  .block { margin-block-start: 44px; }
  .hero { padding-block: calc(var(--top) + 56px) 64px; padding-inline: 16px; }
  .hero-helmet { width: 104px; }
  .btn { width: 100%; }
  .hero-cta { flex-direction: column; align-self: stretch; }
  .ticker { padding-block: 16px; }
  .tk { font-size: 19px; padding-inline: 20px; }
  .stats { grid-template-columns: repeat(2, minmax(0, 1fr)); border-top: 0; }
  .stat { padding: 20px 4px 14px; border-top: 1px solid var(--line); }
  .stat + .stat { border-inline-start: 0; }
  .stat:last-child { grid-column: 1 / -1; }
  .dept-grid, .codes, .mini-grid, .mini-grid.c3, .ppe-grid, .style-grid, .nature, .stages, .stages.s5, .br-grid, .grad, .swd-grid, .jobs, .ppe-list, .qz-opts, .qz-res, .others, .projs, .foot-in, .pn { grid-template-columns: minmax(0, 1fr); }
  .sw-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; }
  .swt { padding: 14px 6px 12px; }
  .swt b { font-size: 15px; }
  .swt small { font-size: 12.5px; }
  .logo { width: 44px; height: 44px; border-radius: 12px; font-size: 16px; }
  .legs { grid-template-columns: repeat(14, 42%); }
  .quiz { padding: 20px; }
  .eng { padding: 18px; }
  .eng-head { grid-template-columns: 96px minmax(0, 1fr); gap: 16px; }
  .eng-info h3 { font-size: 22px; }
  .d-hero { min-height: 0; }
  .d-hero-in { padding-inline: 16px; padding-block-end: 40px; }
  .d-hero-helmet .helmet { width: 112px; }
  .pn { padding-inline: 16px; }
  .pn-card.nx { flex-direction: row; text-align: start; }
  .pn-card.nx .pn-dir { justify-content: flex-start; }
  .mh { padding: 20px; padding-inline-end: 64px; }
  .mh h3 { font-size: 24px; }
  .mshot { margin-inline: 20px; }
  .mb { padding: 18px 20px 20px; }
  .credit { flex-direction: column; align-items: flex-start; }
  .foot-in { padding-inline: 16px; }
  .credit { padding-inline: 16px; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; }
  .ticker { -webkit-mask-image: none; mask-image: none; overflow-x: auto; }
  .ticker-track { animation: none; }
}

/* Shown only when JavaScript cannot run (e.g. a file preview) */
.noscript { position: relative; z-index: 2; max-width: 640px; margin: 140px auto 0; padding: 24px; border-radius: var(--radius); border: 1px solid var(--line-2); background: var(--surface); font-size: 18px; line-height: 1.9; color: var(--ink-2); text-align: center; }
.boot-error { padding-block-start: calc(var(--top) + 80px); text-align: center; }
.boot-error .lead { margin-inline: auto; }
