/* site.css — every style of the site in one file, in the order site.css used to import them: tokens, fonts, base, layout, quicknav, floatad, video, topbar, components, home, pages, motion.
   The sections below are the old files, kept apart by name so a rule is easy to find. */

/* ===== tokens.css ===== */
/* tokens.css — the only file that defines colours, plus the scale variables.
   White carries the pages. The college green (the brand sheet's Pantone 375 C, C43 M0 Y79 K0, R146 G212 B0: --c-brand) is the first auxiliary colour and the
   college blue (C100 M83 Y5 K0: --c-blue) the second; orange marks the few action points. The green is for what stands out against the white - the top bar,
   the arches at the foot of the hero, the quick-link bar, buttons, the leaf behind a title, the enquiry block (there paler: --c-lime, the green 30% toward
   white, because the pure colour over a whole block was too much) - and the blue for headings, links, figures and the deep surfaces: the first university card,
   the full-screen menu, the posters and the footer. Words on the green are navy (white would be 1.8:1), words on the blue are white, and the green's own
   marks on the blue are the lime. contrast.test.js and palette.test.js hold every shade to what it must do: the owner's colours are pinned, the others are the
   design's own. */
:root {
  /* the college green: the first auxiliary colour */
  --c-brand: #92d400;                      /* Pantone 375 C, C43 M0 Y79 K0, R146 G212 B0 */
  --c-lime: #b3e14d;                       /* the brand 30% toward white (same hue, paler): the enquiry block, tags, hover marks on the blue */
  --c-leaf: #2b640b;                       /* the deep leaf green: the lettering of the news boxes, words on the pale green */
  --c-green-text: #3b7d0a;                 /* the greenest green that still reads as words on white (5.1:1): the hero's sub lines and labels are drawn in it, going over into the blue */
  --c-leaf-light: #4e9a12;                 /* the light leaf green: marks, lines and ticks on white (3.5:1: marks, not words), the end of the hero figures */
  --c-green-tint: #eef8d6;                 /* the pale green: hover fills, the tile-pattern of the news boxes' ground */

  /* the college blue: the second auxiliary colour */
  --c-blue: #0033a0;                       /* C100 M83 Y5 K0 on the brand sheet; the brand sheet gives no RGB, this is the deep, clear blue that CMYK describes (Pantone 286 C) */
  --c-blue-dark: #00205b;                  /* the navy: headings, the words of the header, words on the green, the footer's ground, the dark end of the deep panels */
  --c-blue-light: #2a68c8;                 /* the light blue: the start of the round buttons' gradient, rings, the hover lines of the pale card */
  --c-blue-tint: #f1f5fc;                  /* the palest blue: the topics and the news bands, hover fills */

  --c-accent: #dc732a;
  --c-accent-dark: #c25f17;
  --c-accent-tint: #fcefe4;
  --c-danger: #a8480c;                     /* error words on white: the orange darkened to 5.8:1 (the accent itself is 4.3:1) */

  /* the college's own colours (its brand sheet) */
  --c-gray: #adafaf;                       /* Pantone Cool Gray 6 C: only for large type that carries no information (1.4:1 on the lime, 2.2:1 on white); contrast.test.js records the rule */
  --c-gray-soft: rgba(173, 175, 175, .62); /* the same grey, thinner: the pale English word behind a section title */
  --c-mark: var(--c-leaf-light);           /* the "current / selected / hover" mark on white: the light leaf green (the footer sets it to the lime, the green grounds to the navy) */
  --c-lime-text-2: #3a3a3a;                /* the greys for white are a little light straight on the green (--c-text-2 reaches 5.3:1 on the lime, --c-text-3 only 3.5:1): ... */
  --c-lime-text-3: #454545;                /* ... so text that sits on the green itself (not on a white card) reads these two (7.5:1 and 6.3:1 on the lime) */
  --c-focus: var(--c-blue);                /* the keyboard focus ring: the blue, on white and on the green; the deep surfaces set it to the orange, the quick-link bar to the navy */
  --c-field: #eef3fb;                      /* filled form fields */
  --c-dots: rgba(146, 212, 0, .3);         /* halftone dots on light sections */
  --c-quick: rgba(146, 212, 0, .94);       /* the right-edge quick-link bar: the college green, nearly solid, navy words; under the pointer a tile turns navy with lime words */
  --c-quick-line: rgba(0, 32, 91, .28);    /* hairlines between its tiles */
  --c-mist-1: rgba(146, 212, 0, .10);      /* the pale green university panel: a mist of the college green over white, thin at the top left ... */
  --c-mist-2: rgba(146, 212, 0, .30);      /* ... and thicker at the bottom right (text on it is checked against this end) */
  --c-mist-line: rgba(146, 212, 0, .5);    /* its edge */
  --c-mist-ring: rgba(146, 212, 0, .38);   /* the rings drawn in its corner */
  --c-wash-1: rgba(0, 32, 91, .8);         /* the blue wash over the photograph behind the full-screen menu: navy at the top left ... */
  --c-wash-2: rgba(0, 24, 70, .78);        /* ... and a deeper blue at the bottom right (white text over either stays readable even where the photograph is pure white) */
  --c-hero-scrim-1: rgba(0, 24, 70, .84);  /* the dark blue wash over a carousel slide's own picture (the words over it turn white), heavier at the left where the words are ... */
  --c-hero-scrim-2: rgba(0, 24, 70, .7);   /* ... lighter at the right (white words over either stay readable even where the picture is pure white) */
  --c-numeral: rgba(0, 51, 160, .72);      /* the big pale day numbers of the events: the blue at 72% (large type, 3:1 or more on white) */
  --news-tile-opacity: .2;                 /* how faint the tile pattern is along the right edge of a college news box (media/news/azulejo.png, drawn in the colour of --c-leaf-light) ... */
  --news-mark-opacity: .09;                /* ... and the "Polo UA@DUFL" lettering behind its words (media/news/polo-ua-dufl.png, drawn in the colour of --c-leaf); the words are checked against both, and a test checks the pictures' colour against the tokens */

  /* gradients: round "more" buttons, panels, the leaf behind section titles, the hero's figures and arches */
  --grad-brand: linear-gradient(92deg, var(--c-blue-light) 0%, var(--c-blue) 100%);   /* the round "more" buttons: a white arrow on it */
  --grad-panel: linear-gradient(135deg, var(--c-blue) 0%, var(--c-blue-dark) 100%);   /* the deep blue university card and the full-screen menu: white words and the lime marks stay readable over all of it */
  --grad-mist: linear-gradient(150deg, var(--c-mist-1) 0%, var(--c-mist-2) 100%);   /* the pale green university panel (sits on white) */
  --grad-wash: linear-gradient(150deg, var(--c-wash-1) 0%, var(--c-wash-2) 100%);   /* over the menu's photograph */
  --grad-hero-scrim: linear-gradient(100deg, var(--c-hero-scrim-1) 0%, var(--c-hero-scrim-2) 100%);   /* over a carousel slide's own picture */
  --grad-leaf: linear-gradient(135deg, rgba(146, 212, 0, .6) 0%, rgba(146, 212, 0, .12) 100%);   /* the leaf behind a section title's first characters: the college green thinning out, on white and on the pale blue */
  --grad-shade: linear-gradient(180deg, rgba(0, 24, 70, .4) 0%, rgba(0, 24, 70, 0) 36%, rgba(0, 24, 70, 0) 60%, rgba(0, 24, 70, .5) 100%);   /* over a poster: darkens top and bottom for the white text */
  --grad-orb: linear-gradient(135deg, rgba(255, 255, 255, .34) 0%, rgba(255, 255, 255, .08) 100%);   /* the big translucent circle behind the enquiry block: light on the lime */
  --grad-hero-letter: linear-gradient(180deg, var(--c-blue) 0%, var(--c-blue) 38%, #0a5aa8 60%, #2a7a3d 82%, var(--c-green-text) 94%);   /* more natural than a straight blend of blue into green, which goes through a dull grey-teal in the middle: it goes by way of a clear azure and a leaf green, the way the water-to-grass gradients of uiGradients ("Green and Blue", "Emerald Water") and WebGradients ("Dusty Grass", "Tempting Azure") do - the stops are the college blue, 6.9:1 azure, 5.3:1 leaf green and the green of text; every colour 4.5:1 on white. All the lettering of the hero - the title, the sub lines, the figures and their labels - and every letter of it a gradient from its top to its foot (not across the line): the college blue for the upper part, going over into the green of text at the foot (css/site.css lays it in tiles one line high, so that each line, and so each letter, has the whole of it); every colour 4.5:1 on white, so that small type reads too (the pure college green is 1.8:1 on white and cannot be a word) */
  --grad-arch: linear-gradient(180deg, var(--c-lime) 0%, var(--c-brand) 100%);   /* the four arches at the foot of the hero: the lime above, the pure college green below */

  /* neutrals and derived lines */
  --c-text: #333;
  --c-text-2: #505050;
  --c-text-3: #6b6b6b;
  --c-text-4: #666d7a;
  --c-line: rgba(0, 32, 91, .14);
  --c-line-strong: rgba(0, 32, 91, .28);
  --c-overlay: rgba(0, 24, 70, .72);
  --c-scrim: rgba(0, 8, 30, .9);           /* behind the video pop-up: a very dark blue, white controls on it stay readable even over a white page */

  /* layout */
  --topbar-h: 60px;
  --header-h: 96px;
  --header-h-compact: 72px;
  --container: 92rem;
  --gutter: max(3%, calc((100% - var(--container)) / 2));   /* page edge to content: the top bar, header and hero controls line up with .container */
  --qnav-w: clamp(60px, 4.5vw, 84px);   /* the quick-link bar on the right edge; .container keeps the content clear of it */
  --radius: 4px;
  --radius-lg: 12px;
  --shadow-1: 0 2px 14px rgba(0, 32, 91, .08);
  --shadow-2: 0 14px 36px rgba(0, 32, 91, .18);
  --shadow-accent: 0 12px 28px rgba(220, 115, 42, .36);   /* under the orange play button */
  --shadow-video: 0 28px 70px rgba(0, 8, 30, .55);        /* under the video player on its dark scrim */

  /* motion */
  --ease: cubic-bezier(.22,.61,.36,1);
  --dur: .6s;

  /* type: Helvetica Neue LT Std 65 Medium (css/site.css) for every Latin letter and figure - the English names of the two universities included - and
     the system's Chinese font for the Chinese; Microsoft YaHei for the figures of the two-university block. The first font in a stack that has a
     character draws it, so the Latin face placed in front of the Chinese ones sets the letters and the figures and leaves the Chinese characters to
     the Chinese font. */
  --font-latin: "Helvetica Neue LT Std", "Helvetica Neue", Helvetica, Arial;   /* the file of the site first, then what a machine has if it did not load */
  --font-display: var(--font-latin), sans-serif;   /* the pale English word behind a section title (it was Georgia) */
  --font-sans: var(--font-latin), system-ui, "Segoe UI", sans-serif;
  --font-yahei: "Microsoft YaHei", "微软雅黑", "PingFang SC", "Hiragino Sans GB", "Noto Sans SC", "Noto Sans CJK SC", system-ui, sans-serif;   /* the figures of the two-university block: Microsoft YaHei where it is installed (it is not shipped with the site), the nearest Chinese sans elsewhere */
  --font-hero: "Helvetica Neue", Helvetica, Arial, "PingFang SC", "PingFang HK", "Hiragino Sans GB", "Microsoft YaHei", "Microsoft JhengHei", "Noto Sans SC", "Noto Sans CJK SC", sans-serif;   /* the hero is bold: the shipped face has only a Medium, so the hero lettering takes the system's bold-capable Latin face (Helvetica Neue Bold on Apple, Arial Bold on Windows, Liberation Sans Bold on Linux) and the system Chinese bold */
}

:root:lang(zh-CN) { --font-sans: var(--font-latin), "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", "Noto Sans SC", "Noto Sans CJK SC", sans-serif; }
:root:lang(zh-HK) { --font-sans: var(--font-latin), "PingFang HK", "Microsoft JhengHei", "Noto Sans HK", "Noto Sans CJK HK", sans-serif; }
:root:lang(en), :root:lang(pt) { --font-sans: var(--font-latin), system-ui, "Segoe UI", sans-serif; --qnav-w: clamp(76px, 5.6vw, 96px); }   /* longer words need a wider quick-link bar */

/* shadcn/ui-style semantic roles: the form below speaks in these names, never in raw colours */
:root {
  --background: #fff;
  --foreground: var(--c-text);
  --card: #fff;
  --card-foreground: var(--c-text);
  --muted: var(--c-field);
  --muted-foreground: var(--c-text-3);
  --border: var(--c-line);
  --input: var(--c-line-strong);
  --ring: var(--c-blue);
  --primary: var(--c-blue-dark);
  --primary-foreground: #fff;
  --secondary: var(--c-field);
  --secondary-foreground: var(--c-blue-dark);
  --destructive: var(--c-danger);
  --destructive-foreground: #fff;
  --destructive-border: rgba(194, 95, 23, .35);
  --ring-soft: rgba(0, 51, 160, .18);
  --ring-strong: rgba(0, 51, 160, .22);
  --radius-field: var(--radius);
  --radius-card: var(--radius-lg);
}

/* ===== fonts.css ===== */
/* fonts.css — the one font the site brings with it: Helvetica Neue LT Std 65 Medium, for the Latin letters and figures of every page, the English names of the two
   universities included (--font-latin in tokens.css). It is a file of the site, so nothing is asked of any other server and the pages open by a double click.
   It is the college's own copy of a commercial font (Linotype / Monotype): its licence has to cover use on a website, see media/README.md. */

/* One face - the Medium - declared for every weight (100 to 900): a bold or a light request is answered with this very face, so the browser never
   draws a false bold. Everything Latin on the pages, headings and figures included, is therefore set in the Medium. */
@font-face {
  font-family: "Helvetica Neue LT Std";
  font-style: normal;
  font-weight: 100 900;
  font-display: swap;
  src: url("../media/fonts/HelveticaNeueLTStd-Md.otf") format("opentype");
}

/* ===== base.css ===== */
/* base.css — reset, typography, page container, accessibility helpers. (Written PC only with min-width 1200px; the page now adapts to every width.) */
*, *::before, *::after { box-sizing: border-box; }

html {
  color-scheme: light;
  font-size: clamp(15px, 11px + 0.28vw, 19px);
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-width: 0;   /* (the original PC-only minimum of 1200px is gone: the page adapts down to a phone, and a minimum wider than the window less its scrollbar made the page scroll sideways in windows 1195-1215px wide) */
  font-family: var(--font-sans);
  font-size: 1rem;
  line-height: 1.7;
  color: var(--c-text);
  background: #fff;   /* the ground is white; a few bands paint their own colours, the cards their own white */
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

h1, h2, h3, h4, h5 { margin: 0; line-height: 1.3; font-weight: 700; color: var(--c-blue-dark); }
/* Headings wrap on punctuation and spaces, balanced; CJK words are not split mid-phrase (overflow-wrap is the emergency exit). */
h1, h2, h3 { text-wrap: balance; word-break: keep-all; overflow-wrap: anywhere; }
p, figure, blockquote, dl, dd { margin: 0; }
ul, ol { margin: 0; padding: 0; list-style: none; }
a { color: inherit; text-decoration: none; }
button, input, select, textarea { font: inherit; color: inherit; }
button { padding: 0; border: 0; background: none; cursor: pointer; }
svg { vertical-align: middle; }
img { max-width: 100%; }
table { border-collapse: collapse; }
::selection { background: var(--c-blue); color: #fff; }

:focus-visible { outline: 3px solid var(--c-focus); outline-offset: 2px; }
.bignav, .univ--blue { --c-focus: var(--c-accent); }   /* on the deep blues the orange ring is the one that shows */
.qnav { --c-focus: var(--c-blue-dark); }   /* on the green bar the navy one (a tile under the pointer is navy: quicknav.css gives it the orange) */
:focus:not(:focus-visible) { outline: none; }

/* The content column: centred, at most --container wide, with 3% on the left and, on the right, never less than the quick-link bar's width and a
   little more, so the bar floating over the right edge never covers any content. */
.container {
  --m-l: max(3%, calc((100% - var(--container)) / 2));
  --m-r: max(calc(var(--qnav-w) + 14px), calc((100% - var(--container)) / 2));
  width: calc(100% - var(--m-l) - var(--m-r));
  margin-left: var(--m-l);
  margin-right: var(--m-r);
}
.section { padding: 5rem 0; }

.skip-link {
  position: absolute;
  left: .5rem;
  top: .5rem;
  z-index: 2000;
  padding: .6rem 1rem;
  border-radius: var(--radius);
  background: var(--c-blue-dark);
  color: #fff;
  font-weight: 700;
  transform: translateY(-200%);
}
.skip-link:focus { transform: none; }

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  margin: -1px;
  padding: 0;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
  border: 0;
}

[hidden] { display: none !important; }

/* ===== layout.css ===== */
/* layout.css — header, navigation, full-screen menu, language menu and footer. (The right-edge quick-link bar is in quicknav.css.) */

.ic { display: inline-flex; align-items: center; justify-content: center; }

/* header: sits under the top bar; clear over the hero, a plain solid white bar with a line of the college green under it once scrolled. Its words are the navy
   (--on); the full-screen menu shares the logo rules below but sets no --on, so its words keep the white of their fallbacks, and draws the logos white. */
.header {
  --on: var(--c-blue-dark);
  --on-line: rgba(0, 32, 91, .3);
  --logo-filter: none;   /* the three logos are colour pictures (tools/make-header-logos.py): drawn as they are on the white header; the menu draws them white by a filter */
  position: fixed;
  top: var(--topbar-h);
  left: 0;
  right: 0;
  z-index: 900;
  height: var(--header-h);
  background-color: rgba(255, 255, 255, 0);   /* white at no opacity: the same colour on both ends of the fade */
  color: var(--on);
  transition: background-color .35s var(--ease), box-shadow .35s var(--ease);
}
.is-scrolled .header { top: 0; height: var(--header-h-compact); background-color: #fff; box-shadow: 0 2px 14px rgba(0, 32, 91, .14), inset 0 -3px 0 var(--c-brand); }

.header__inner {
  position: relative;
  display: flex;
  align-items: center;
  height: 100%;
  padding: 0 var(--gutter);
  gap: clamp(.7rem, 1vw, 2rem);
}

/* the brand: with no logos configured, the college's own mark and name ... */
.header__logo { display: flex; align-items: center; flex: none; gap: .7rem; color: var(--on, #fff); }
.header__markwrap { display: flex; }
.header__mark { width: 2.6rem; height: 2.6rem; }
.header__name { display: flex; flex-direction: column; line-height: 1.15; }
.header__name strong { color: var(--on, #fff); font-size: 1.35rem; letter-spacing: .02em; }
.header__name small { font-size: .72rem; letter-spacing: .1em; opacity: .82; }
/* ... otherwise the three logos (Dalian University of Foreign Languages, Universidade de Aveiro, the college's own), colour pictures of one height with a hairline
   between each two. The height grows with the window but stays well under the bar (the bar is 96px, 72px once scrolled); the nine links give way a little to
   make room: their words are 1rem and their gaps close up as the window narrows. */
.header__logo--pair { --logo-h: clamp(28px, calc(28px + (100vw - 1280px) * .075), 44px); gap: clamp(.5rem, .8vw, 1rem); }   /* 28px at 1280 wide, 40px at 1440, 44px from 1490 up */
.header__logo-img { display: block; flex: none; width: auto; max-width: none; height: var(--logo-h); filter: var(--logo-filter, none); transition: opacity .25s var(--ease); }
.header__logo-sep { flex: none; width: 1px; height: calc(var(--logo-h) * .74); background: var(--on-line, rgba(255, 255, 255, .45)); }
.header__logo-text { color: var(--on, #fff); font-size: 1.1rem; font-weight: 700; letter-spacing: .02em; white-space: nowrap; }   /* a logo that would not load: its name */
.header__logo--pair:hover .header__logo-img, .header__logo--pair:focus-visible .header__logo-img { opacity: .86; }

/* navigation */
.nav { display: flex; flex: 1; justify-content: center; }
.nav__list { display: flex; gap: clamp(.5rem, .75vw, 1.6rem); }
.nav__item { position: relative; }
.nav__link {
  position: relative;
  display: block;
  padding: .6rem 0;
  color: var(--on);
  font-size: 1rem;   /* the three logos take room: the nine words are 1rem at every width */
  font-weight: 700;
  white-space: nowrap;
}
/* The English and Portuguese menu words are much longer than the Chinese ones: a little smaller, closer together, and a name that does not fit goes
   on a second line, centred (balanced, so that the two lines are about equally long). */
html:lang(en) .nav__list, html:lang(pt) .nav__list { align-items: center; gap: clamp(.5rem, .7vw, 1.2rem); }
html:lang(en) .nav__link, html:lang(pt) .nav__link { max-width: 9rem; font-size: .9rem; line-height: 1.16; text-align: center; text-wrap: balance; white-space: normal; }
@media (max-width: 1400px) { html:lang(en) .nav__link, html:lang(pt) .nav__link { font-size: .86rem; } }
.nav__link::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: .1rem;
  height: 3px;
  border-radius: 2px;
  background: var(--c-mark);
  transform: scaleX(0);
  transform-origin: left center;
  transition: transform .3s var(--ease);
}
.nav__item.is-open > .nav__link::after,
.nav__link[aria-current="true"]::after { transform: scaleX(1); }

/* the drop-down: a square white card hanging from a small caret */
.nav__panel {
  position: absolute;
  top: 100%;
  left: 50%;
  min-width: 11.5rem;
  margin-top: .7rem;
  padding: .7rem 0;
  border-radius: 0;
  background: #fff;
  box-shadow: 0 10px 30px rgba(0, 32, 91, .2);
  opacity: 0;
  visibility: hidden;
  transform: translate(-50%, 8px);
  transition: opacity .25s var(--ease), transform .25s var(--ease), visibility 0s linear .25s;
}
.nav__panel::before {
  content: "";
  position: absolute;
  left: 50%;
  top: -.5rem;
  width: 0;
  height: 0;
  margin-left: -.5rem;
  border-right: .5rem solid transparent;
  border-bottom: .5rem solid #fff;
  border-left: .5rem solid transparent;
}
.nav__panel::after { content: ""; position: absolute; left: 0; right: 0; top: -1rem; height: 1rem; }   /* bridge: the pointer can travel from the link to the card */
.nav__item.is-open > .nav__panel {
  opacity: 1;
  visibility: visible;
  transform: translate(-50%, 0);
  transition-delay: 0s;
}
.nav__sub {
  display: block;
  padding: .6rem 1.4rem;
  border-radius: 0;
  color: var(--c-text-2);
  font-size: .95rem;
  text-align: center;
  white-space: nowrap;
}
.nav__sub:hover, .nav__sub:focus-visible { background: var(--c-blue-tint); color: var(--c-blue); }
.nav__sub[aria-current="page"] { color: var(--c-blue); font-weight: 700; box-shadow: inset 3px 0 0 var(--c-mark); }

/* tools: the language menu and the menu button */
.header__tools { display: flex; flex: none; align-items: center; gap: .4rem; }

.lang { position: relative; }
.lang__btn {
  display: flex;
  align-items: center;
  gap: .4rem;
  padding: .5rem .7rem;
  border-radius: var(--radius);
  color: var(--on);
  font-size: .95rem;
  font-weight: 700;
  transition: background-color .2s var(--ease);
}
.lang__btn:hover { background: rgba(0, 32, 91, .08); }
.lang__menu {
  position: absolute;
  right: 0;
  top: calc(100% + .4rem);
  min-width: 11rem;
  padding: .4rem 0;
  background: #fff;
  box-shadow: 0 10px 30px rgba(0, 32, 91, .2);
  opacity: 0;
  visibility: hidden;
  transform: translateY(6px);
  transition: opacity .25s var(--ease), transform .25s var(--ease), visibility 0s linear .25s;
}
.lang.is-open .lang__menu { opacity: 1; visibility: visible; transform: none; transition-delay: 0s; }
/* the four languages: plain links, each named in its own language; the page you are on is marked */
.lang__menu a {
  display: block;
  padding: .55rem 1rem;
  color: var(--c-text-2);
  font-size: .95rem;
  text-align: left;
  white-space: nowrap;
}
.lang__menu a:hover, .lang__menu a:focus-visible { background: var(--c-blue-tint); color: var(--c-blue); }
.lang__menu a[aria-current="true"] { color: var(--c-blue); font-weight: 700; box-shadow: inset 3px 0 0 var(--c-mark); }

.header__burger {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 2.6rem;
  height: 2.6rem;
  border-radius: 50%;
  color: var(--on);
  transition: background-color .2s var(--ease);
}
.header__burger:hover { background: rgba(0, 32, 91, .08); }

/* ---------- full-screen menu ---------- */
.bignav {
  --logo-filter: brightness(0) invert(1);   /* the three logos are colour pictures: drawn white on the deep blue by a filter */
  position: fixed;
  inset: 0;
  z-index: 1500;
  display: flex;
  flex-direction: column;
  padding: 0 var(--gutter) 3rem;
  overflow-x: hidden;   /* the decorative ring reaches past the edge */
  overflow-y: auto;
  background: var(--grad-panel);
  color: #fff;
  opacity: 0;
  visibility: hidden;
  transform: translate3d(0, -14px, 0);
  transition: opacity .35s var(--ease), transform .35s var(--ease), visibility 0s linear .35s;
}
.bignav.is-open { opacity: 1; visibility: visible; transform: none; transition: opacity .35s var(--ease), transform .35s var(--ease), visibility 0s; }
/* the campus photograph (js: .bignav__bg, the menu's first child): fixed to the window and behind everything, so it stays put while a tall menu scrolls.
   Colour grading: the picture is laid over a light-blue ground with the "luminosity" blend, which keeps its light and dark and replaces its
   colours by that blue; a translucent blue wash on top (tokens.css) keeps the white words readable. It settles in slowly when the menu opens. */
.bignav__bg { position: fixed; inset: 0; z-index: -1; overflow: hidden; isolation: isolate; background: var(--c-blue-light); pointer-events: none; }
.bignav__bg img { display: block; width: 100%; max-width: none; height: 100%; object-fit: cover; mix-blend-mode: luminosity; transform: scale(1.08); transition: transform 2.6s var(--ease); }
.bignav.is-open .bignav__bg img { transform: none; }
.bignav__bg::after { content: ""; position: absolute; inset: 0; background: var(--grad-wash); }
/* one thin ring in the upper right stays from the old decoration; the big pale disc is gone, it only lightened the photograph under the words */
.bignav::after { content: ""; position: absolute; right: -9rem; top: 18rem; width: 24rem; height: 24rem; border: 1.5px solid rgba(255, 255, 255, .1); border-radius: 50%; pointer-events: none; }
html.is-bignav { overflow: hidden; }
.bignav__top { position: relative; display: flex; flex: none; align-items: center; justify-content: space-between; height: var(--header-h); }
.bignav__close {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 2.8rem;
  height: 2.8rem;
  border-radius: 50%;
  color: #fff;
  transition: background-color .2s var(--ease), transform .3s var(--ease);
}
.bignav__close:hover { background: rgba(255, 255, 255, .18); transform: rotate(90deg); }
/* the columns sit in the middle of what is left under the top row (auto margins; a tall menu simply scrolls) */
.bignav__grid { position: relative; display: grid; grid-template-columns: repeat(var(--cols, 8), minmax(0, 1fr)); gap: 3rem 1rem; margin: auto 0; padding-bottom: 4rem; text-align: center; }
.bignav__head { display: block; margin-bottom: 1.3rem; color: #fff; font-size: 1.3rem; font-weight: 700; transition: color .2s var(--ease); }
.bignav__links a { display: block; padding: .45rem 0; color: rgba(255, 255, 255, .92); font-size: 1rem; transition: color .2s var(--ease), transform .25s var(--ease); }
.bignav__head:hover, .bignav__links a:hover { color: var(--c-lime); }
.bignav__links a:hover { transform: translateX(3px); }

/* footer: the navy with white words; column links, contact and QR, legal line. Its marks and hover colour are the lime. */
.footer {
  --c-mark: var(--c-lime);
  padding-top: 4rem;
  background: var(--c-blue-dark);
  color: #fff;
}
.footer a { color: rgba(255, 255, 255, .86); transition: color .2s var(--ease); }
.footer a:hover { color: var(--c-lime); text-decoration: underline; text-underline-offset: 3px; }

.footer__top { display: grid; grid-template-columns: 1fr 18rem; gap: 3rem; padding-bottom: 3rem; }   /* the brand block is gone: the nine columns take the left, contact and QR the right */

.footer__cols { display: grid; grid-template-columns: repeat(5, 1fr); gap: 2rem 1.5rem; align-content: start; }   /* nine columns: five, then four */
.footer__cols li { line-height: 2; font-size: .9rem; }
.footer__head a { color: #fff; font-weight: 700; }

.footer__contact h3 { margin-bottom: .6rem; color: #fff; font-size: 1rem; }
.footer__contact p { display: flex; align-items: flex-start; gap: .55rem; margin-top: .45rem; color: rgba(255, 255, 255, .86); font-size: .875rem; line-height: 1.55; }
.footer__ci { flex: none; margin-top: .2rem; color: var(--c-mark); }

.footer__qr { display: flex; gap: 1.2rem; margin-top: 1.4rem; }
.footer__qrbox { margin: 0; text-align: center; font-size: .8rem; color: rgba(255, 255, 255, .82); }
.footer__qrimg { display: block; width: 116px; height: 116px; border-radius: var(--radius); background: #fff; }   /* the owner's QR picture, white margin and all */
.footer__qrbox figcaption { margin-top: .4rem; }

.footer__legal {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1.2rem 0;
  border-top: 1px solid rgba(255, 255, 255, .22);
  color: rgba(255, 255, 255, .78);
  font-size: .8125rem;
}
.footer__legal a { margin-left: .5rem; text-decoration: underline; text-underline-offset: 3px; }
.footer__post { padding-left: calc(16px + .55rem); }   /* under the address, in line with its text */

/* ===== quicknav.css ===== */
/* quicknav.css — the slim quick-link bar on the right edge: the university's services as icon-over-label tiles, TOP and a fold button.
   Tiles are the college green (--c-quick) with navy words and turn navy, with lime words, under the pointer; folded, the panel slides off and a pull tab stays. */
.qnav {
  position: fixed;
  top: 28%;
  right: 0;
  z-index: 800;
  width: var(--qnav-w);
}

/* the panel slides out to the right; it is hidden once it has gone and shown again at the start of the way back */
.qnav__panel { transition: transform .4s var(--ease), visibility 0s linear .4s; }
.qnav:not(.is-folded) .qnav__panel { transition: transform .4s var(--ease), visibility 0s; }
.qnav.is-folded .qnav__panel { visibility: hidden; transform: translateX(100%); }

/* arched caps top and bottom, each with a fine arc inside */
.qnav__cap { position: relative; display: block; height: calc(var(--qnav-w) * .42); background: var(--c-quick); }
.qnav__cap--top { border-radius: 50% 50% 0 0 / 100% 100% 0 0; }
.qnav__cap--bottom { border-radius: 0 0 50% 50% / 0 0 100% 100%; }
.qnav__cap::before { content: ""; position: absolute; inset: 6px 6px 0; border: 1px solid var(--c-quick-line); border-bottom: 0; border-radius: 50% 50% 0 0 / 100% 100% 0 0; }
.qnav__cap--bottom::before { inset: 0 6px 6px; border: 1px solid var(--c-quick-line); border-top: 0; border-radius: 0 0 50% 50% / 0 0 100% 100%; }

/* a tile: an icon over a short label, a hairline under it; lime under the pointer, where the icon turns over once */
.qnav__item {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 3px;
  padding: 10px 3px 9px;
  background: var(--c-quick);
  color: var(--c-blue-dark);
  font-size: .85rem;
  line-height: 1.25;
  text-align: center;
  transition: background-color .3s;
}
.qnav__item::after { content: ""; position: absolute; left: 50%; bottom: 0; width: 66%; height: 1px; transform: translateX(-50%); background: var(--c-quick-line); }
.qnav__item:hover, .qnav__item:focus-visible { background: var(--c-blue-dark); color: var(--c-lime); }
.qnav__item:focus-visible, .qnav__top:focus-visible { --c-focus: var(--c-accent); }   /* the tile under the focus is navy: the orange ring shows on it */
.qnav__item:hover::after, .qnav__item:focus-visible::after { display: none; }
.qnav__ic { display: flex; }
.qnav__item:hover .qnav__ic, .qnav__item:focus-visible .qnav__ic { transform: rotateY(360deg); transition: transform .5s; }
.qnav__txt { max-width: 100%; overflow-wrap: anywhere; }

.qnav__top {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 2px;
  width: 100%;
  padding: 10px 0;
  background: var(--c-quick);
  color: var(--c-blue-dark);
  font-size: .8rem;
  font-weight: 700;
  letter-spacing: .02em;
  transition: background-color .3s;
}
.qnav__top:hover, .qnav__top:focus-visible { background: var(--c-blue-dark); color: var(--c-lime); }
.qnav__top-ic { display: flex; }

.qnav__fold { display: flex; justify-content: center; width: 100%; padding: 2px 0 10px; background: var(--c-quick); color: var(--c-blue-dark); }
.qnav__fold-ic { display: flex; align-items: center; justify-content: center; width: 20px; height: 20px; border: 1.5px solid currentColor; border-radius: 50%; transition: background-color .25s, color .25s; }
.qnav__fold:hover .qnav__fold-ic, .qnav__fold:focus-visible .qnav__fold-ic { background: var(--c-blue-dark); color: var(--c-lime); }

.qnav__item:focus-visible, .qnav__top:focus-visible, .qnav__fold:focus-visible, .qnav__tab:focus-visible { outline-offset: -3px; }

/* the pull tab: the bar's name in vertical text; it comes in once the panel has gone */
.qnav__tab {
  position: absolute;
  top: 14%;
  right: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  width: 34px;
  padding: 14px 0 12px;
  border-radius: 10px 0 0 10px;
  background: var(--c-quick);
  color: var(--c-blue-dark);
  font-size: .85rem;
  letter-spacing: .15em;
  visibility: hidden;
  transform: translateX(100%);
  transition: transform .3s var(--ease), visibility 0s linear .3s;
}
.qnav.is-folded .qnav__tab { visibility: visible; transform: none; transition: transform .35s var(--ease) .3s, visibility 0s; }
.qnav__tab-txt { writing-mode: vertical-rl; }
:lang(zh-CN) .qnav__tab-txt, :lang(zh-HK) .qnav__tab-txt { text-orientation: upright; }
.qnav__tab-ic { display: flex; letter-spacing: 0; }

/* a short window: tighter tiles, so the whole bar stays on screen */
@media (max-height: 760px) {
  .qnav { top: 24%; }
  .qnav__item { padding: 7px 3px 6px; }
}

/* ===== floatad.css ===== */
/* floatad.css — the drifting picture ad: a picture that is a link, and a round close button. It has no text.
   It is anchored in the lower left corner of the window, 24px in from both edges, where it sets off from; js/site.js moves it from there
   with transform, here it is only dressed. */
.floatad { position: fixed; left: 24px; bottom: 24px; z-index: 1100; width: var(--ad-w, 260px); will-change: transform; }
.floatad--still { will-change: auto; }   /* reduced motion: it stays in that corner */
.floatad__box { position: relative; animation: floatad-in .7s var(--ease) .4s backwards; }   /* swells and fades in after the page has loaded */
.floatad__link { display: block; overflow: hidden; border-radius: var(--radius); background: #fff; box-shadow: var(--shadow-2); }
.floatad__pic { display: block; line-height: 0; }
.floatad__pic img, .floatad__pic svg { display: block; width: 100%; height: auto; transition: transform .5s var(--ease); }
.floatad__link:hover .floatad__pic img, .floatad__link:hover .floatad__pic svg,
.floatad__link:focus-visible .floatad__pic img, .floatad__link:focus-visible .floatad__pic svg { transform: scale(1.04); }
.floatad__link:focus-visible { outline-offset: 3px; }
.floatad__close { position: absolute; right: 8px; top: 8px; display: flex; align-items: center; justify-content: center; width: 28px; height: 28px; border-radius: 50%; background: var(--c-overlay); color: #fff; transition: background-color .2s var(--ease); }
.floatad__close:hover, .floatad__close:focus-visible { background: var(--c-blue); }
.floatad__close .ic { display: inline-flex; }
@keyframes floatad-in { from { opacity: 0; transform: scale(.9); } }

/* ===== video.css ===== */
/* video.css — the video pop-up behind the play button between the two university cards: a very dark blue scrim over the whole window and a
   16 : 9 player in the middle, with a round close button above its upper right corner. js/site.js builds it and toggles .is-open. */
html.is-video { overflow: hidden; }
.vmodal { position: fixed; inset: 0; z-index: 1600; display: flex; align-items: center; justify-content: center; padding: 4.5rem 2rem 2rem; opacity: 0; transition: opacity .3s var(--ease); }
.vmodal.is-open { opacity: 1; }
.vmodal__scrim { position: absolute; inset: 0; background: var(--c-scrim); }
/* as wide as the window allows (up to 70rem), and never so wide that the height leaves the window */
.vmodal__box { position: relative; width: min(70rem, 100%, calc((100vh - 7.5rem) * 16 / 9)); aspect-ratio: 16 / 9; border-radius: var(--radius-lg); background: var(--c-blue-dark); box-shadow: var(--shadow-video); transform: translate3d(0, 14px, 0) scale(.97); transition: transform .4s var(--ease); }
.vmodal.is-open .vmodal__box { transform: none; }
.vmodal__stage { position: absolute; inset: 0; overflow: hidden; border-radius: inherit; }
.vmodal__video, .vmodal__frame { display: block; width: 100%; height: 100%; border: 0; background: var(--c-blue-dark); }
.vmodal__close { position: absolute; right: 0; top: -3.6rem; display: flex; align-items: center; justify-content: center; width: 2.8rem; height: 2.8rem; border-radius: 50%; background: rgba(255, 255, 255, .14); color: #fff; transition: background-color .2s var(--ease), transform .3s var(--ease); }
.vmodal__close:hover { background: rgba(255, 255, 255, .26); transform: rotate(90deg); }
.vmodal__close:focus-visible { outline-color: #fff; }
/* the placeholder and the error message: the site's own artwork behind, a sentence in front */
.vmodal__soon { position: absolute; inset: 0; display: block; }
.vmodal__soon svg { display: block; width: 100%; height: 100%; }
.vmodal__msg { position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; padding: 2rem; color: #fff; font-size: 1.5rem; font-weight: 700; letter-spacing: .04em; text-align: center; text-shadow: 0 2px 18px rgba(0, 8, 30, .55); }

/* ===== topbar.css ===== */
/* topbar.css — the fixed 60px utility bar: two links on the left (the home pages of the two universities), the admissions phone and email on the right.
   The college green, with navy words. */
.topbar {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1000;
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: var(--topbar-h);
  padding: 0 var(--gutter);
  --c-mark: var(--c-blue-dark);   /* the hover mark on the green is navy */
  background: var(--c-brand);
  box-shadow: inset 0 -1px 0 rgba(0, 32, 91, .16);   /* a fine line between the bar and the header under it */
  color: var(--c-blue-dark);
  font-size: .875rem;
  transition: transform .35s var(--ease);
}

.topbar__links { display: flex; align-items: center; line-height: 1; }
.topbar__links a { display: block; padding: 0 10px; border-right: 1px solid rgba(0, 32, 91, .55); color: var(--c-blue-dark); }
.topbar__links a:last-child { border-right: 0; }
.topbar__links a:hover { color: var(--c-mark); text-decoration: underline; text-underline-offset: 4px; }

.topbar__contact { display: flex; align-items: center; }
.topbar__item { display: flex; align-items: center; margin-left: 30px; white-space: nowrap; }
.topbar__ic {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 30px;
  height: 30px;
  margin-right: 15px;
  border-radius: 50%;
  background: rgba(0, 32, 91, .12);
}

/* scrolled: the bar slides away (Task 8 sets body.is-scrolled) */
.is-scrolled .topbar { transform: translateY(-100%); }

/* ===== components.css ===== */
/* components.css — buttons, tags, cards, form controls, notices. Colours come from tokens only. */

/* buttons: primary = the college green with navy words (hovering turns it blue), accent = orange (action points only), ghost = outline */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: .5rem;
  padding: .75rem 1.6rem;
  border: 2px solid transparent;
  border-radius: var(--radius);
  font-size: 1rem;
  font-weight: 700;
  line-height: 1.2;
  text-align: center;
  cursor: pointer;
  transition: transform .25s var(--ease), background-color .25s var(--ease), color .25s var(--ease),
    border-color .25s var(--ease), box-shadow .25s var(--ease);
}
.btn:hover { transform: translateY(-2px); }
.btn[disabled], .btn[aria-disabled="true"] { opacity: .55; cursor: not-allowed; transform: none; }
.btn--primary { background: var(--c-brand); color: var(--c-blue-dark); }
.btn--primary:hover { background: var(--c-blue); color: #fff; }
.btn--accent { background: var(--c-accent); color: #fff; box-shadow: 0 6px 16px rgba(220, 115, 42, .32); }
.btn--accent:hover { background: var(--c-accent-dark); }
.btn--white { background: #fff; color: var(--c-blue); border-color: var(--c-brand); box-shadow: 0 6px 18px rgba(0, 32, 91, .16); }   /* the carousel's one button: white, with a line of the college green round it (the hero is white) */
.btn--white:hover { background: var(--c-brand); color: var(--c-blue-dark); }
.btn--ghost { background: transparent; color: var(--c-blue); border-color: currentColor; }
.btn--ghost:hover { background: var(--c-blue-tint); }
.on-dark .btn--ghost { color: #fff; }
.on-dark .btn--ghost:hover { background: rgba(255, 255, 255, .14); }

/* tags and chips */
.tag {
  display: inline-block;
  padding: .15rem .7rem;
  border-radius: 999px;
  background: var(--c-blue-tint);
  color: var(--c-blue);
  font-size: .8125rem;
  font-weight: 600;
  line-height: 1.6;
  white-space: nowrap;
}
.tag--green { background: var(--c-lime); color: var(--c-blue-dark); }
.tag--accent { background: var(--c-accent); color: #fff; }

.chip {
  display: inline-flex;
  align-items: center;
  padding: .2rem .8rem;
  border: 1px solid var(--c-line-strong);
  border-radius: 999px;
  color: var(--c-text-2);
  font-size: .875rem;
  transition: border-color .2s var(--ease), color .2s var(--ease), background-color .2s var(--ease);
}
.chip:hover { border-color: var(--c-blue-light); background: var(--c-blue-tint); color: var(--c-blue); }

/* card */
.card {
  position: relative;
  padding: 1.5rem;
  border-radius: var(--radius);
  background: #fff;
  box-shadow: var(--shadow-1);
  transition: transform .35s var(--ease), box-shadow .35s var(--ease);
}
.card:hover { transform: translateY(-4px); box-shadow: var(--shadow-2); }

/* ---------- form (shadcn/ui in plain CSS, drawn after the preset b0: `npx shadcn@latest init --preset b0 --template next` gives style base-nova, neutral colours, radius .625rem, Inter, Lucide icons) ----------
   What the preset's components are (read from the files that command writes: components/ui/card.tsx, input.tsx, textarea.tsx, field.tsx, input-group.tsx, toggle-group.tsx, checkbox.tsx, button.tsx, alert.tsx):
   Card = rounded-xl (the radius x 1.4 = .875rem) on a one-pixel ring of the text colour at 10% (ring-1 ring-foreground/10), no border, no hairline shadow; its header, content and footer share one
   spacing (--card-spacing); the footer is a band of its own: a line above it and a pale ground (border-t bg-muted/50). Input, Textarea, ToggleGroup, InputGroup, Button = rounded-lg (.625rem) on a one-pixel neutral
   border (border-input) with no shadow at all, a focus is a 3px ring (focus-visible:ring-3). A Label is a medium-weight line, a Field has a gap of 2 (.5rem), a FieldGroup a gap of 5 (1.25rem); the description is
   muted and the error destructive; a Checkbox is a 4px-rounded square that fills with the primary colour when it is checked; an Alert is a rounded-lg line with a border.
   Here it is the roomy size - the card's spacing is 3rem where the preset's is 1rem, the controls are 3.5rem high, the title is 2rem - and the card is as tall as the explanation beside it (.lead stretches
   both); the college's colours stay on the neutral greys: the blue for the chosen and the ring, the orange for the one action. */
.lead__form {
  --radius-field: .625rem;
  --radius-card: .875rem;
  --input: #d4d4d4;                      /* neutral-300: the preset's border-input is neutral-200 (#e5e5e5), a step firmer here so that the fields show on a bright page */
  --border: #e5e5e5;
  --muted: #f5f5f5;
  --ring-soft: rgba(0, 51, 160, .16);
  --ring-strong: rgba(0, 51, 160, .24);
  --card-spacing: 2.75rem;
  display: flex;
  flex-direction: column;
  min-width: 0;
  padding: 0;
  overflow: hidden;
  border-radius: var(--radius-card);
  background: var(--card);
  color: var(--card-foreground);
  box-shadow: 0 0 0 1px rgba(10, 10, 10, .1), 0 2px 5px rgba(0, 0, 0, .04), 0 46px 96px -42px rgba(0, 32, 91, .62);
}
.lead-form { display: flex; flex: 1; flex-direction: column; text-align: left; }
.card__header { padding: 2.5rem var(--card-spacing) 1.6rem; background: linear-gradient(180deg, var(--c-green-tint) 0%, rgba(238, 248, 214, 0) 100%); }   /* a pale green wash at the top of the card, gone by the first field */
.card__header::before { content: ""; display: block; width: 3.5rem; height: 5px; margin-bottom: 1.15rem; border-radius: 999px; background: var(--c-brand); }
.card__title { margin: 0; color: var(--foreground); font-size: 2rem; font-weight: 700; letter-spacing: -.01em; line-height: 1.2; }
.card__desc { margin: .75rem 0 0; color: var(--muted-foreground); font-size: 1.0625rem; line-height: 1.6; text-wrap: pretty; }
.card__content { display: flex; flex: 1; flex-direction: column; padding: .5rem var(--card-spacing) 2.3rem; }
.card__footer { display: flex; flex-direction: column; gap: .9rem; padding: 1.6rem var(--card-spacing) 1.8rem; border-top: 1px solid var(--border); background: rgba(245, 245, 245, .6); }   /* CardFooter: border-t bg-muted/50 */

/* FieldGroup + Field: every control sits in a field with its own label, description and error */
.field-group { display: grid; flex: 1; grid-template-columns: 1fr 1fr; gap: 1.45rem 1.6rem; }
@media (min-width: 721px) { .lead__form .field-group { grid-template-rows: repeat(4, auto) minmax(7rem, 1fr) auto; } }   /* six rows: the two to a line, the hint, the two, the message (it takes what is left of the card's height), the consent */
.field { display: flex; min-width: 0; flex-direction: column; gap: .65rem; }
.field--wide { grid-column: 1 / -1; }
.field__label { color: var(--foreground); font-size: 1rem; font-weight: 600; line-height: 1.4; }
.field__req { margin-left: .15rem; color: var(--destructive); font-style: normal; }
.field__opt { margin-left: .3rem; color: var(--muted-foreground); font-size: .875rem; font-style: normal; font-weight: 400; }

/* Input / Textarea / Select */
.input, .textarea, .select {
  width: 100%;
  min-height: 3.4rem;
  padding: .75rem 1.1rem;
  border: 1px solid var(--input);
  border-radius: var(--radius-field);
  background: var(--background);
  color: var(--foreground);
  font: inherit;
  font-size: max(16px, 1.0625rem);   /* never under 16px: iOS Safari zooms the page into a field that is smaller */
  line-height: 1.4;
  box-shadow: none;
  transition: border-color .15s var(--ease), box-shadow .15s var(--ease), background-color .15s var(--ease);
}
.textarea { min-height: 7rem; resize: vertical; }
.field--grow .textarea { flex: 1; }
.input:hover, .textarea:hover, .select:hover { border-color: #a3a3a3; }
.input::placeholder, .textarea::placeholder { color: var(--muted-foreground); }
.input:focus-visible, .textarea:focus-visible, .select:focus-visible { outline: none; border-color: var(--ring); box-shadow: 0 0 0 3px var(--ring-soft); }
.input[aria-invalid="true"], .textarea[aria-invalid="true"], .select[aria-invalid="true"] { border-color: var(--destructive); box-shadow: 0 0 0 3px rgba(194, 95, 23, .2); }
.field[data-invalid="true"] .field__label { color: var(--destructive); }

/* InputGroup: phone and email carry a quiet leading icon */
.input-group { display: flex; align-items: stretch; border: 1px solid var(--input); border-radius: var(--radius-field); background: var(--background); transition: border-color .15s var(--ease), box-shadow .15s var(--ease); }
.input-group:hover { border-color: #a3a3a3; }
.input-group:focus-within { border-color: var(--ring); box-shadow: 0 0 0 3px var(--ring-soft); }
.input-group[data-invalid="true"] { border-color: var(--destructive); box-shadow: 0 0 0 3px rgba(194, 95, 23, .2); }
.input-group__addon { display: inline-flex; flex: none; align-items: center; padding-left: 1.1rem; color: var(--muted-foreground); }
.input-group__input { min-height: 3.3rem; padding-left: .75rem; border: 0; background: transparent; box-shadow: none; }
.input-group__input:hover { border-color: transparent; }
.input-group__input:focus-visible { box-shadow: none; }

/* ToggleGroup: 2-5 choices, one chosen (radiogroup semantics, roving tabindex): joined outline buttons, the chosen one filled */
.toggle-group { display: flex; width: 100%; border-radius: var(--radius-field); }
.toggle { display: inline-flex; flex: 1 1 0; min-width: 0; align-items: center; justify-content: center; min-height: 3.4rem; margin-left: -1px; padding: .5rem .6rem; border: 1px solid var(--input); border-radius: 0; background: var(--background); color: var(--foreground); font: inherit; font-size: 1rem; font-weight: 600; line-height: 1.2; cursor: pointer; transition: background-color .15s var(--ease), color .15s var(--ease), border-color .15s var(--ease); }
.toggle:first-child { margin-left: 0; border-radius: var(--radius-field) 0 0 var(--radius-field); }
.toggle:last-child { border-radius: 0 var(--radius-field) var(--radius-field) 0; }
.toggle:only-child { border-radius: var(--radius-field); }
.toggle:hover { background: var(--muted); }
.toggle[aria-checked="true"], .toggle[aria-pressed="true"] { position: relative; z-index: 1; border-color: var(--primary); background: var(--primary); color: var(--primary-foreground); }
.toggle:focus-visible { position: relative; z-index: 2; outline: none; box-shadow: 0 0 0 3px var(--ring-strong); }
.toggle:disabled { opacity: .55; cursor: not-allowed; }

/* Checkbox: a small rounded square that fills when it is checked */
.checkbox-row { display: flex; align-items: flex-start; gap: .8rem; color: var(--c-text-2); font-size: 1rem; line-height: 1.55; cursor: pointer; }
.checkbox { appearance: none; -webkit-appearance: none; flex: none; width: 1.6rem; height: 1.6rem; min-width: 24px; min-height: 24px; margin: 0; border: 1px solid var(--input); border-radius: .3125rem; background: var(--background) center / 1.05rem no-repeat; cursor: pointer; transition: background-color .15s var(--ease), border-color .15s var(--ease), box-shadow .15s var(--ease); }
.checkbox:hover { border-color: #a3a3a3; }
.checkbox:checked { border-color: var(--primary); background-color: var(--primary); background-image: url("data:image/svg+xml,%3Csvg xmlns='http%3A//www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='white' stroke-width='3.4' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M5 12.5l4.5 4.5L19 7.5'/%3E%3C/svg%3E"); }
.checkbox:focus-visible { outline: none; box-shadow: 0 0 0 3px var(--ring-strong); }
.checkbox[aria-invalid="true"] { border-color: var(--destructive); }
.checkbox-row a { color: var(--primary); text-decoration: underline; }
.checkbox-row a:hover { text-decoration-thickness: 2px; }
.lead-form .btn[type="submit"] { min-height: 3.6rem; border-radius: var(--radius-field); font-size: 1.125rem; letter-spacing: .08em; }

/* descriptions and errors */
.form__hint { margin: 0; color: var(--muted-foreground); font-size: .875rem; line-height: 1.45; }
.field__err { margin: 0; color: var(--destructive); font-size: .875rem; font-weight: 500; line-height: 1.45; }
.field__err:empty, .form__err:empty { display: none; }
.form__contact { margin-top: -.2rem; }

/* Alert: the form-level error (spam, network, server, configuration) */
.alert { padding: .8rem 1rem; border: 1px solid var(--destructive-border); border-radius: var(--radius-field); background: var(--c-accent-tint); color: var(--destructive); font-size: .9375rem; font-weight: 600; line-height: 1.45; }

/* Spinner: the submit button's loading state (shadcn: Spinner + disabled, no separate isLoading prop) */
.spinner { display: inline-block; flex: none; width: 1rem; height: 1rem; border: 2px solid currentColor; border-right-color: transparent; border-radius: 50%; animation: spin .7s linear infinite; }
.spinner[hidden] { display: none; }
.btn .spinner { margin-right: .5rem; }
.form__note { margin: 0; color: var(--muted-foreground); font-size: .8125rem; line-height: 1.45; text-align: center; }

/* POW: one quiet line, only while a check is being solved */
.pow-status { min-height: 1.15rem; margin: 0; color: var(--muted-foreground); font-size: .8125rem; line-height: 1.4; }
.pow-status[data-state="error"] { color: var(--destructive); font-weight: 600; }

.hp { position: absolute; left: -10000px; top: auto; width: 1px; height: 1px; overflow: hidden; }

/* success: the card keeps its height and swaps the form for the thank-you panel */
.lead-ok { display: flex; flex: 1; flex-direction: column; align-items: center; justify-content: center; padding: 2.6rem 1.5rem; text-align: center; }
.lead-ok[hidden] { display: none; }
.lead-ok__ic { display: inline-flex; align-items: center; justify-content: center; width: 4.2rem; height: 4.2rem; border-radius: 50%; background: var(--primary); color: var(--primary-foreground); }
.lead-ok h3 { margin: 1.2rem 0 .55rem; color: var(--foreground); font-size: 1.6rem; }
.lead-ok h3:focus { outline: none; }
.lead-ok p { max-width: 24em; margin-inline: auto; color: var(--muted-foreground); }
.form-done { display: flex; flex-direction: column; justify-content: center; }

@media (max-width: 720px) {
  .lead__form { --card-spacing: 1.4rem; }
  .field-group { grid-template-columns: 1fr; gap: 1.25rem; }
  .card__header { padding: 1.6rem var(--card-spacing) 0; }
  .card__title { font-size: 1.6rem; }
  .card__content { padding: 1.5rem var(--card-spacing) 1.7rem; }
  .card__footer { padding: 1.3rem var(--card-spacing) 1.5rem; }
}
@media (prefers-reduced-motion: reduce) {
  .spinner { animation: none; border-right-color: currentColor; opacity: .7; }
}

/* notices and empty states */
.notice {
  padding: 1rem 1.25rem;
  border-left: 4px solid var(--c-blue);
  border-radius: 0 var(--radius) var(--radius) 0;
  background: var(--c-blue-tint);
  color: var(--c-blue-dark);
}
.empty { padding: 3rem 1rem; text-align: center; color: var(--c-text-3); }

.btn--block { display: flex; width: 100%; }

/* ---------- section furniture (reference-site composition, our colours) ---------- */

/* title row: the title on the left, the "more" link on the right */
.sec-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 2rem; }
.sec-head .more { margin-top: 2.1rem; }

/* section title: big light type, a leaf of colour behind the first characters, a pale English word behind the rest (data-en) */
.sec-title { position: relative; min-height: 6.4rem; padding: 1.15rem 0 0 1.7rem; }
.sec-title::before {
  content: "";
  position: absolute;
  left: 0;
  top: .6rem;
  width: 4.4rem;
  height: 3.3rem;
  border-radius: 90% 12% 90% 12%;
  background: var(--grad-leaf);
  transform: rotate(-8deg);
}
.sec-title::after {
  content: attr(data-en);
  position: absolute;
  left: 3.2rem;
  top: 2.7rem;
  color: var(--c-gray-soft);   /* the Cool Gray, thinned: a large word that only decorates */
  font-family: var(--font-display);
  font-size: 3.7rem;
  line-height: 1;
  letter-spacing: .01em;
  text-transform: uppercase;
  white-space: nowrap;
  pointer-events: none;
}
.sec-title__text { position: relative; z-index: 1; color: var(--c-text); font-size: 2.5rem; font-weight: 400; line-height: 1.25; }
.on-dark .sec-title__text { color: #fff; }
.on-dark .sec-title::after { color: rgba(255, 255, 255, .08); }

/* "more": grey text and a round gradient button with an arrow */
.more { display: inline-flex; align-items: center; gap: .55rem; color: var(--c-text-2); font-size: .96rem; transition: color .2s var(--ease); }
.more__dot {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 1.8rem;
  height: 1.8rem;
  border-radius: 50%;
  background: var(--grad-brand);
  color: #fff;
  transition: transform .25s var(--ease);
}
.more:hover { color: var(--c-blue); }
.more:hover .more__dot { transform: translateX(3px); }

/* halftone dots in the top-right corner of a light section */
.has-dots { position: relative; }
.has-dots::before {
  content: "";
  position: absolute;
  inset: 0;
  background-image: radial-gradient(var(--c-dots) 1.2px, transparent 1.5px);
  background-size: 14px 14px;
  -webkit-mask-image: radial-gradient(ellipse 60% 70% at 100% 0%, #000 0%, transparent 70%);
  mask-image: radial-gradient(ellipse 60% 70% at 100% 0%, #000 0%, transparent 70%);
  pointer-events: none;
}
.has-dots > * { position: relative; }

/* ===== home.css ===== */
/* home.css — homepage modules. */

/* ---------- hero: a full-screen carousel on an original animated background (or the configured video) ---------- */
.hero {
  --hero-safe-top: calc(var(--topbar-h) + var(--header-h) + .85rem);   /* the safe area of the words: under the top bar and the header, with a little air ... */
  --hero-safe-bottom: 13.05rem;   /* ... and above the four arches (8.6rem) and the slide buttons (they stand 10.4rem to 12.8rem above the foot); the bold lettering needs the last quarter of a rem */
  --hero-weight: 700;   /* the hero is the one bold display block of the site: the shipped Latin face has only a Medium, so the hero uses --font-hero, whose bold faces are real ones on every system, and one weight (700) across the title, sub lines, figures and labels */
  font-family: var(--font-hero);   /* a bold-capable system stack, used only by the hero; the rest of the page keeps the site's own Medium */
  position: relative;
  height: 100vh;
  height: 100svh;
  min-height: 640px;
  overflow: hidden;
  color: var(--c-blue-dark);   /* the words on the white hero: the title is the blue, the sub lines the greys, the rest navy */
  background: #fff;   /* plain white: the colour of the first screen comes from the drifting lights, the lettering and the arches */
}

.hero__bg {
  position: absolute;
  inset: -24px;
  transform: translate3d(calc(var(--px, 0) * 12px), calc(var(--py, 0) * 12px), 0);
  transition: transform .8s var(--ease);
  pointer-events: none;
}
.hero__video { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; opacity: .55; }
.hero__blob { position: absolute; border-radius: 50%; filter: blur(60px); animation: drift 28s ease-in-out infinite alternate; will-change: transform; }
/* the drifting lights on the white: a green glow, a faint blue one and a faint orange one */
/* the lights are gradients too, not one flat colour: WebGradients "Dusty Grass" (a yellow-green going over into a soft green) for the green one and a sky blue going over into the college's lighter blue for the blue one,
   so that the glow fades from one shade into the next, like daylight on grass and sky, and not from a colour into white. (Both stay inside one hue family: a gradient from the blue to a green passes through cyan, which the
   palette of the site leaves out - tests/browser/20-palette.js counts it in the pixels.) */
.hero__blob--a { left: -10vw; top: -14vw; width: 46vw; height: 46vw; background: linear-gradient(135deg, #d4fc79 0%, #96e6a1 100%); opacity: .5; animation-duration: 26s; }
.hero__blob--b { right: -6vw; top: 18vh; width: 34vw; height: 34vw; background: linear-gradient(135deg, #64b3f4 0%, #2a68c8 100%); opacity: .15; animation-duration: 32s; animation-delay: -8s; }
.hero__blob--c { left: 38vw; bottom: -16vw; width: 30vw; height: 30vw; background: var(--c-accent); opacity: .09; animation-duration: 29s; animation-delay: -15s; }
.hero__grid {
  position: absolute;
  inset: 0;
  background-image: linear-gradient(rgba(0, 51, 160, .06) 1px, transparent 1px), linear-gradient(90deg, rgba(0, 51, 160, .06) 1px, transparent 1px);
  background-size: 64px 64px;
  -webkit-mask-image: radial-gradient(ellipse at 50% 40%, #000 20%, transparent 75%);
  mask-image: radial-gradient(ellipse at 50% 40%, #000 20%, transparent 75%);
}
/* fine diagonal lines on the right half, an outlined giant word, concentric rings and two glowing dots */
.hero__stripes {
  position: absolute;
  inset: 0 0 0 36%;
  background: repeating-linear-gradient(112deg, rgba(0, 51, 160, .05) 0 1px, transparent 1px 9px);
  -webkit-mask-image: linear-gradient(90deg, transparent 0%, #000 45%);
  mask-image: linear-gradient(90deg, transparent 0%, #000 45%);
}
.hero__word {
  position: absolute;
  right: -2%;
  top: 12%;
  color: transparent;
  font-family: var(--font-sans);
  font-size: clamp(14rem, 21vw, 30rem);
  font-weight: 800;
  letter-spacing: -.04em;
  line-height: 1;
  white-space: nowrap;
  -webkit-text-stroke: 1.5px rgba(146, 212, 0, .55);   /* the giant word is drawn as an outline in the college green: large, and it says nothing a reader needs */
  user-select: none;
}
.hero__ring { position: absolute; border: 1.5px solid rgba(0, 51, 160, .12); border-radius: 50%; }
.hero__ring--1 { right: -8rem; bottom: -20rem; width: 44rem; height: 44rem; }
.hero__ring--2 { right: -15rem; bottom: -27rem; width: 58rem; height: 58rem; border-color: rgba(0, 51, 160, .09); }
.hero__ring--3 { right: -22rem; bottom: -34rem; width: 72rem; height: 72rem; border-color: rgba(0, 51, 160, .06); }
.hero__spark { position: absolute; border-radius: 50%; animation: float 5.5s ease-in-out infinite; }
.hero__spark--a { right: 26%; top: 47%; width: 1.5rem; height: 1.5rem; background: var(--c-brand); box-shadow: 0 0 2.2rem rgba(146, 212, 0, .8); }
.hero__spark--b { right: 14%; top: 38%; width: 1rem; height: 1rem; background: var(--c-accent); box-shadow: 0 0 1.8rem rgba(220, 115, 42, .65); animation-delay: -2.4s; }
.hero.is-bg-paused .hero__blob, .hero.is-bg-paused .hero__spark { animation-play-state: paused; }

/* the campus drawn in lines (media/hero/skyline-left.webp, -hall.webp, -tower.webp, -bend.webp and -right.webp, cut from three drawings by tools/make-skyline-pieces.py): five buildings standing on one line across
   the blank band between the lettering and the four arches, from left to right the four-storey building, the hall (a five-storey front with a great roof and a round wing at each end), the clock tower, the bent
   building with the curved front and the curved and glass building. The row is as wide as the content column - the first building starts at its left edge, the last ends at its right edge, where the four arches
   below it begin and end - and the gap between every two neighbours (--g) is the same one, the tower's included. The two buildings on the left are as wide together as the two on the right (752 + 832 and 644 + 941
   pixels of the drawing), so the tower stands in the middle of the row, and of the column. The size comes from the style sheet alone: the tower is a seventh of the window's height (14rem at most), and never so high
   that the gaps would be under 60 pixels of the drawing. The line is one gradient - the colours of the drawings' own lines, brought into the palette - from one edge of the column to the other, so that it joins the five
   wherever they stand; each building starts its colours again at the blue, as its drawing does (the tower and the hall start in the green where the building before them ends). The line is as thin as the strokes of
   the drawings (a pixel at least) and the buildings stand a little way into it, so that the lines at their feet and the line under them are one line and not two. The drawing is background and nothing is done to keep it
   clear of the words: it is drawn before the slides, so the words stand over it wherever they come to overlap, and a slide that has a picture of its own covers it like the rest of the background. Every time the page
   is loaded it comes in: the line draws itself out from the middle, then the buildings fade in and rise a little, the tower first and the others after it, outwards; the global rule for reduced motion (motion.css)
   takes the animations away and leaves the drawing standing. Under 900px the words have the whole width and it is not drawn.
   The line's colours are the drawings' own, lightened where they were dark (to a lightness of 52% at the least: a line of one full dark pixel is heavier to the eye than the thin strokes it joins, and the dark
   stretches looked thicker than the light ones). The line is one device pixel thick, whatever the screen (--dp: js/site.js sets it to 1 / devicePixelRatio, 1px where there is no script) and js/site.js moves it (--snap) by the part of a pixel that its top edge
   is off the pixel grid: a line that falls between two rows of pixels is drawn as two pale ones, and over the dark blue stretches that looked thicker than over the green. The foot of every building fades into
   the line (a mask), so that the dense little lines at the foot - steps, ramps, the lowest windows - are not a second, thicker line over it.
   --u is one pixel of the drawing: the pieces are 752, 832, 138, 644 and 941 pixels wide and 273, 219, 435, 294 and 205 high. */
.hero__skyline {
  --sky-hh: clamp(5.5rem, 14.5vh, 14rem);
  --sky-rv: max(calc(var(--qnav-w) + 14px), calc((100vw - var(--container)) / 2));   /* the room that the quick links keep at the right edge, as a length of the window */
  --sky-hw: calc((100vw - 17px - max(3vw, (100vw - var(--container)) / 2) - var(--sky-rv)) * .1226);   /* 435 / (3307 pixels of buildings + 4 * 60 of gaps) of the width of the column (17px: a window is as wide as 100vw less a scrollbar) */
  --sky-h: min(var(--sky-hh), var(--sky-hw));
  --u: calc(var(--sky-h) / 435);
  --dp: 1px;   /* one device pixel (js/site.js: 1 / devicePixelRatio) */
  --snap: 0px;   /* how far the line is moved up to stand on a row of pixels (js/site.js) */
  --lh: var(--dp);
  --sky-r: max(calc(var(--qnav-w) + 14px), calc((100% - var(--container)) / 2));   /* the right edge of the content column, as .container keeps it */
  --g: max(calc(var(--u) * 60), calc((100% - var(--gutter) - var(--sky-r) - var(--u) * 3307) / 4));   /* the one gap: what the five buildings leave of the column, in four */
  --x-l: var(--gutter);
  --x-hall: calc(var(--x-l) + var(--u) * 752 + var(--g));
  --x-t: calc(var(--x-hall) + var(--u) * 832 + var(--g));
  --x-bend: calc(var(--x-t) + var(--u) * 138 + var(--g));
  --x-r: calc(var(--x-bend) + var(--u) * 644 + var(--g));
  position: absolute; left: 0; right: 0; bottom: calc(8.6rem + .35rem + var(--snap)); height: calc(var(--sky-h) + var(--lh)); pointer-events: none;   /* 8.6rem is the height of the arches */
}
@supports (height: 1svh) { .hero__skyline { --sky-hh: clamp(5.5rem, 14.5svh, 14rem); } }   /* the height of the window with the toolbars of a phone or a tablet showing; a browser that has no such unit keeps the one above */
.hero__skyline, .sky__line, .sky__bld { transition: none !important; }   /* the one rule for reduced motion gives everything a .01ms transition on all properties; nothing here is meant to move but by its animation */
.sky__line { position: absolute; left: 0; right: 0; bottom: 0; height: var(--lh); clip-path: inset(0 var(--sky-r) 0 var(--gutter)); animation: sky-draw 1.4s var(--ease) .1s backwards;
  background: linear-gradient(90deg,
    #5f7eaa calc(var(--x-l) + var(--u) * 5), #627fa7 calc(var(--x-l) + var(--u) * 76), #7a808f calc(var(--x-l) + var(--u) * 152), #f4bea0 calc(var(--x-l) + var(--u) * 347), #e5733f calc(var(--x-l) + var(--u) * 372),
    #e08743 calc(var(--x-l) + var(--u) * 460), #a8ad5c calc(var(--x-l) + var(--u) * 540), #8aaa5f calc(var(--x-l) + var(--u) * 652), #97ba63 calc(var(--x-l) + var(--u) * 741),
    #97ba63 calc(var(--x-hall) - var(--g) / 2 - var(--u) * 5), #5886b1 calc(var(--x-hall) - var(--g) / 2 + var(--u) * 5),
    #5886b1 calc(var(--x-hall) + var(--u) * 0), #5689b3 calc(var(--x-hall) + var(--u) * 82), #5a7aaf calc(var(--x-hall) + var(--u) * 119), #676ea2 calc(var(--x-hall) + var(--u) * 143), #666da3 calc(var(--x-hall) + var(--u) * 177),
    #827990 calc(var(--x-hall) + var(--u) * 188), #9f8a93 calc(var(--x-hall) + var(--u) * 315), #a79499 calc(var(--x-hall) + var(--u) * 338), #c9917c calc(var(--x-hall) + var(--u) * 342), #d88668 calc(var(--x-hall) + var(--u) * 346),
    #e78460 calc(var(--x-hall) + var(--u) * 410), #ef9650 calc(var(--x-hall) + var(--u) * 468), #e6ab51 calc(var(--x-hall) + var(--u) * 497), #c6a95b calc(var(--x-hall) + var(--u) * 531), #bfc15e calc(var(--x-hall) + var(--u) * 539),
    #a1b559 calc(var(--x-hall) + var(--u) * 587), #5cae5b calc(var(--x-hall) + var(--u) * 745), #5cad69 calc(var(--x-hall) + var(--u) * 830),
    #94b362 calc(var(--x-t) + var(--u) * 4), #93b95c calc(var(--x-t) + var(--u) * 71), #5eab7d calc(var(--x-t) + var(--u) * 134),
    #5eab7d calc(var(--x-bend) - var(--g) / 2 - var(--u) * 5), #708099 calc(var(--x-bend) - var(--g) / 2 + var(--u) * 5),
    #708099 calc(var(--x-bend) + var(--u) * 5), #6e819c calc(var(--x-bend) + var(--u) * 46), #687ea1 calc(var(--x-bend) + var(--u) * 78), #6f739a calc(var(--x-bend) + var(--u) * 117), #827891 calc(var(--x-bend) + var(--u) * 144),
    #9a8395 calc(var(--x-bend) + var(--u) * 199), #a8959a calc(var(--x-bend) + var(--u) * 236), #c7917d calc(var(--x-bend) + var(--u) * 240), #dc8869 calc(var(--x-bend) + var(--u) * 272), #ec8c5d calc(var(--x-bend) + var(--u) * 295),
    #ef914a calc(var(--x-bend) + var(--u) * 341), #f09c3e calc(var(--x-bend) + var(--u) * 373), #d3ad51 calc(var(--x-bend) + var(--u) * 389), #b7b950 calc(var(--x-bend) + var(--u) * 400), #9dae67 calc(var(--x-bend) + var(--u) * 455),
    #8aab5e calc(var(--x-bend) + var(--u) * 478), #86a267 calc(var(--x-bend) + var(--u) * 569), #899e6b calc(var(--x-bend) + var(--u) * 638),
    #5dac84 calc(var(--x-r) - var(--u) * 16), #788c9e calc(var(--x-r) + var(--u) * 159), #8296a6 calc(var(--x-r) + var(--u) * 303), #6fa886 calc(var(--x-r) + var(--u) * 369), #60a974 calc(var(--x-r) + var(--u) * 394),
    #5eab75 calc(var(--x-r) + var(--u) * 513), #87997c calc(var(--x-r) + var(--u) * 527), #c78854 calc(var(--x-r) + var(--u) * 542), #cb7344 calc(var(--x-r) + var(--u) * 624), #c76a43 calc(var(--x-r) + var(--u) * 796),
    #ca653f calc(var(--x-r) + var(--u) * 936)); }
.sky__bld { position: absolute; bottom: calc(var(--lh) - var(--u) * 2.5); display: block; height: auto; max-width: none; animation: sky-rise 1.6s var(--ease) .6s backwards;   /* a building stands 2.5 pixels of the drawing into the line... */
  -webkit-mask-image: linear-gradient(to bottom, #000 0, #000 calc(100% - var(--u) * 10), transparent calc(100% - var(--u) * 3));
  mask-image: linear-gradient(to bottom, #000 0, #000 calc(100% - var(--u) * 10), transparent calc(100% - var(--u) * 3)); }   /* ...and its foot fades out over the last 10 to 3 of them: the line under it is the ground */
.sky__bld--l { left: var(--x-l); width: calc(var(--u) * 752); animation-delay: .7s; }
.sky__bld--hall { left: var(--x-hall); width: calc(var(--u) * 832); animation-delay: .55s; }
.sky__bld--c { left: var(--x-t); width: calc(var(--u) * 138); animation-delay: .4s; }
.sky__bld--bend { left: var(--x-bend); width: calc(var(--u) * 644); animation-delay: .55s; }
.sky__bld--r { left: var(--x-r); width: calc(var(--u) * 941); animation-delay: .7s; }
@keyframes sky-draw { from { opacity: 0; transform: scaleX(.12); } }
@keyframes sky-rise { from { opacity: 0; transform: translate3d(0, 1.2rem, 0); } }

/* slides: they fade into each other, the text rises into place line by line */
.hero__slides { position: absolute; inset: 0; }
.hero__slide {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  padding: var(--hero-safe-top) 0 var(--hero-safe-bottom);
  opacity: 0;
  visibility: hidden;
  transition: opacity .9s var(--ease), visibility 0s linear .9s;
}
.hero__slide.is-active { opacity: 1; visibility: visible; transition: opacity .9s var(--ease), visibility 0s; }
.hero__inner { position: relative; display: flex; flex-direction: column; align-items: flex-start; }
.hero__inner > * { opacity: 0; transform: translate3d(0, 26px, 0); transition: opacity .8s var(--ease), transform .8s var(--ease); }
.hero__slide.is-active .hero__inner > * { opacity: 1; transform: none; }
.hero__slide.is-active .hero__inner > :nth-child(2) { transition-delay: .08s; }
.hero__slide.is-active .hero__inner > :nth-child(3) { transition-delay: .16s; }
.hero__slide.is-active .hero__inner > :nth-child(4) { transition-delay: .26s; }
.hero__slide.is-active .hero__inner > :nth-child(5) { transition-delay: .36s; }

/* The words of a slide are one gradient lettering, blue above and green at the foot of every letter (--grad-hero-letter: it runs from the top of a letter to its foot, not across the line;
   it is laid in tiles as high as a line - --lh, the line height of each piece of lettering - one under the other, so that every line has all of it and a title of two lines has it twice),
   in one typeface and one weight (--hero-weight). Their sizes are multiplied by --fit, which is 1 unless js/site.js
   finds that the words do not fit the safe area and brings it down, and no size goes below its floor; their line lengths are those of the full size, so that a smaller
   size gives longer lines and not just smaller ones. */
.hero__title { --lh: 1.18; max-width: min(100%, calc(16 * clamp(3.2rem, 4.4vw + 1.2rem, 6rem))); color: var(--c-blue); font-size: max(1.7rem, calc(clamp(3.2rem, 4.4vw + 1.2rem, 6rem) * var(--fit, 1))); font-weight: var(--hero-weight); line-height: var(--lh); letter-spacing: -.01em; background: var(--grad-hero-letter) 0 0 / 100% calc(var(--lh) * 1em) repeat-y; -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent; }
.hero__rule { width: min(100%, 40rem); height: 3px; margin: calc(1.5rem * var(--fit, 1)) 0 calc(1.4rem * var(--fit, 1)); background: linear-gradient(90deg, var(--c-brand) 0%, rgba(146, 212, 0, 0) 100%); }
.hero__sub { --lh: 1.75; max-width: calc(36 * 1.4rem); color: var(--c-blue); font-size: max(.9rem, calc(1.4rem * var(--fit, 1))); font-weight: var(--hero-weight); line-height: var(--lh); background: var(--grad-hero-letter) 0 0 / 100% calc(var(--lh) * 1em) repeat-y; -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent; }
.hero__stats { display: flex; flex-wrap: wrap; gap: calc(.8rem * var(--fit, 1)) calc(5rem * var(--fit, 1)); margin-top: calc(2.4rem * var(--fit, 1)); }
.hstat { display: flex; align-items: baseline; gap: .8rem; }
/* the figures are lettering like the rest of the hero: large, in its one weight, filled with its one gradient (--grad-hero-letter) clipped to the letters, with a
   soft shadow under them; a browser that cannot clip a gradient to letters keeps the blue */
.hstat__num {
  --lh: 1;
  color: var(--c-blue);
  font-size: max(2.4rem, calc(clamp(4.4rem, 5vw + 1.4rem, 7.6rem) * var(--fit, 1)));
  font-variant-numeric: tabular-nums;
  font-weight: var(--hero-weight);
  letter-spacing: -.02em;
  line-height: var(--lh);
  background: var(--grad-hero-letter) 0 0 / 100% calc(var(--lh) * 1em) repeat-y;
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  filter: drop-shadow(0 .4rem .7rem rgba(0, 51, 160, .18));
}
.hstat__label { --lh: 1.7; color: var(--c-blue); font-size: max(.95rem, calc(1.5rem * var(--fit, 1))); font-weight: var(--hero-weight); line-height: var(--lh); background: var(--grad-hero-letter) 0 0 / 100% calc(var(--lh) * 1em) repeat-y; -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent; }
.hero__cta { display: flex; gap: 1rem; margin-top: calc(2.2rem * var(--fit, 1)); }
.hero__cta .btn { font-size: max(.9rem, calc(1rem * var(--fit, 1))); }
/* a slide's own picture (config.hero.slides[].image): it covers the built-in background, under a dark blue wash that keeps the words readable, and settles in
   slowly while its slide shows; a big number written inside a line ([UN]…[/UN]) is the weight of its line, like the figures under it */
.hero__pic { position: absolute; inset: 0; z-index: 0; overflow: hidden; }
.hero__pic-img { display: block; width: 100%; height: 100%; object-fit: cover; transform: scale(1.08); transition: transform 9s linear; }
.hero__slide.is-active .hero__pic-img { transform: none; }
.hero__pic::after { content: ""; position: absolute; inset: 0; background: var(--grad-hero-scrim); }
.hero .un { font-variant-numeric: tabular-nums; }
.hero__sub .un { font-size: 1.45em; }
/* the words of a slide that has a picture are white over its dark wash (the words of the white hero are blue, grey and navy) */
.hero__slide:has(.hero__pic) { color: #fff; }
.hero__slide:has(.hero__pic) .hero__title, .hero__slide:has(.hero__pic) .hero__sub, .hero__slide:has(.hero__pic) .hstat__label { background: none; color: #fff; -webkit-text-fill-color: #fff; }
/* the last resort of the fitting: when even the smallest sizes leave no room, the lines are cut (the whole text stays in the page for reading aids) */
.hero__slide.is-clamped .hero__title { display: -webkit-box; overflow: hidden; -webkit-box-orient: vertical; -webkit-line-clamp: 3; }
.hero__slide.is-clamped .hero__sub { display: -webkit-box; overflow: hidden; -webkit-box-orient: vertical; -webkit-line-clamp: 2; }
.hero__slide.is-clamped .hstat__label { display: -webkit-box; overflow: hidden; -webkit-box-orient: vertical; -webkit-line-clamp: 2; }
.hero__slide:has(.hero__pic) .hstat__num { background: none; color: #fff; -webkit-text-fill-color: #fff; filter: none; }
.hero__slide:has(.hero__pic) .hero__rule { background: linear-gradient(90deg, var(--c-lime) 0%, rgba(179, 225, 77, 0) 100%); }
/* the same four rules for a browser that does not know :has() (Firefox before 121, Safari before 15.4, Chrome before 105): js/site.js puts .has-pic on a slide that has a picture */
.hero__slide.has-pic { color: #fff; }
.hero__slide.has-pic .hero__title, .hero__slide.has-pic .hero__sub, .hero__slide.has-pic .hstat__label { background: none; color: #fff; -webkit-text-fill-color: #fff; }
.hero__slide.has-pic .hstat__num { background: none; color: #fff; -webkit-text-fill-color: #fff; filter: none; }
.hero__slide.has-pic .hero__rule { background: linear-gradient(90deg, var(--c-lime) 0%, rgba(179, 225, 77, 0) 100%); }
/* over a slide that has a picture the header, clear over the white hero, would put its navy words on a dark photograph: while the page is at its top and such a slide
   shows (js/site.js marks the page: has-hero-pic) the header is a white bar */
.has-hero-pic:not(.is-scrolled) .header { background-color: rgba(255, 255, 255, .94); }

/* four arches standing on the bottom edge, overlapping a little */
.hero__links { position: absolute; left: 0; right: 0; bottom: 0; display: flex; z-index: 5; }
.hero__links li { flex: 1; margin-left: -2.6rem; }
.hero__links li:first-child { margin-left: 0; }
.hero__links li:nth-child(1) { z-index: 4; }
.hero__links li:nth-child(2) { z-index: 3; }
.hero__links li:nth-child(3) { z-index: 2; }
.hero__links li:nth-child(4) { z-index: 1; }
.hero__capsule {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: flex-end;
  height: 8.6rem;
  padding: 0 2.2rem 1.35rem;
  border-radius: 55% 55% 0 0 / 100% 100% 0 0;
  background: var(--grad-arch);
  box-shadow: 0 -6px 28px rgba(0, 32, 91, .16);
  color: var(--c-blue-dark);
  text-align: center;
  transition: transform .35s var(--ease), box-shadow .35s var(--ease);
}
.hero__capsule strong { font-size: 1.18rem; font-weight: 700; line-height: 1.3; }
.hero__capsule small { margin-top: .15rem; color: var(--c-lime-text-2); font-size: .92rem; }
.hero__capsule:hover { transform: translateY(-8px); box-shadow: 0 -12px 34px rgba(0, 32, 91, .26); }

/* slide buttons and the pause button, above the arches on the right */
.hero__ctrl { position: absolute; right: calc(var(--gutter) + 3.6rem); bottom: 10.4rem; z-index: 6; display: flex; align-items: center; gap: .9rem; }   /* 3.6rem keeps it clear of the quick-link bar */
.hero__dots { display: flex; gap: 1.1rem; }   /* (WCAG 2.5.8: a target under 24px needs 24px of air round it; on a touch screen the dots have a larger invisible area below) */
.hero__dot { width: .9rem; height: .9rem; border: 2px solid rgba(0, 51, 160, .7); border-radius: 50%; transition: background-color .25s var(--ease), transform .25s var(--ease); }
.hero__dot:hover { background: rgba(0, 51, 160, .2); }
.hero__dot[aria-current="true"] { background: var(--c-blue); transform: scale(1.25); }
.hero__toggle {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 2.4rem;
  height: 2.4rem;
  border-radius: 50%;
  background: rgba(0, 51, 160, .1);
  color: var(--c-blue);
  transition: background-color .2s var(--ease);
}
.hero__toggle:hover { background: rgba(0, 51, 160, .18); }
/* the page holds both icons: the pause mark while the slides turn, the play mark while they are held (aria-pressed, set by js/site.js) */
.hero__toggle .icon--play, .hero__toggle[aria-pressed="true"] .icon--pause { display: none; }
.hero__toggle[aria-pressed="true"] .icon--play { display: block; }
/* the slide buttons are blue rings on the white hero; over a slide that has a picture (js/site.js: has-hero-pic) they are white, or they would vanish on the photograph */
.has-hero-pic .hero__dot { border-color: rgba(255, 255, 255, .9); }
.has-hero-pic .hero__dot:hover { background: rgba(255, 255, 255, .3); }
.has-hero-pic .hero__dot[aria-current="true"] { background: #fff; }
.has-hero-pic .hero__toggle { background: rgba(255, 255, 255, .2); color: #fff; }
.has-hero-pic .hero__toggle:hover { background: rgba(255, 255, 255, .36); }

/* ---------- mission: the two universities behind the college, side by side, one deep blue and one pale green (the class names --blue and --green say so; the pages
   and index.jsp use them). Their facts lie in rows opposite one
   another, and between the cards sits a round play button that opens a video ---------- */
.mission { position: relative; padding: 3.4rem 0 4.6rem; overflow: hidden; background: #fff; }
.mission .container { position: relative; }
.mission__ring { position: absolute; border: 1.5px solid var(--c-line); border-radius: 50%; }
.mission__ring::after { content: ""; position: absolute; top: 12%; left: 8%; width: .9rem; height: .9rem; border-radius: 50%; background: var(--c-brand); }
.mission__ring--a { right: -9rem; top: 7rem; width: 30rem; height: 30rem; }
.mission__ring--a::after { top: 74%; left: 16%; }
.mission__ring--b { left: -20rem; bottom: -24rem; width: 32rem; height: 32rem; }
.mission__ring--b::after { left: auto; right: 10%; top: 20%; background: var(--c-accent); }

/* The columns and rows of the grid are written in the markup (they depend on how many universities and facts there are). Every card spans all
   the rows and, where subgrid is understood, shares them: the third fact of one card is exactly as high as the third of the other and lies level
   with it, whatever the length of the texts. Each card is deep blue (--blue) or pale green (--green); its logo sits at the top right, its emblem faint in the lower right corner. */
.univs { --join-w: clamp(6.2rem, 5.4vw, 8.6rem); --pad-t: 1.9rem; --pad-b: 1.1rem; position: relative; display: grid; align-items: stretch; }
.univs:not(.univs--pair) { column-gap: 1.4rem; }
.univ { position: relative; grid-row: 1 / -1; display: flex; flex-direction: column; min-width: 0; padding: var(--pad-t) 2rem var(--pad-b); overflow: hidden; border: 1px solid transparent; border-radius: var(--radius); background-origin: border-box; box-shadow: var(--shadow-1); }
.univ .nowrap { white-space: nowrap; }
.univ > * { position: relative; z-index: 1; }
.univ--blue { background-image: var(--grad-panel); color: #fff; }
.univ--green { border-color: var(--c-mist-line); background-image: var(--grad-mist); background-color: #fff; color: var(--c-text); }
.univ::before, .univ::after { content: ""; position: absolute; z-index: 0; border: 1.5px solid; border-radius: 50%; pointer-events: none; }
.univ::before { right: -8rem; bottom: -9rem; width: 24rem; height: 24rem; }
.univ::after { right: -4rem; bottom: -5rem; width: 16rem; height: 16rem; }
.univ--blue::before { border-color: rgba(255, 255, 255, .13); }
.univ--blue::after { border-color: rgba(255, 255, 255, .09); }
.univ--green::before { border-color: var(--c-mist-ring); }
.univ--green::after { border-color: var(--c-mist-line); }

/* the emblem: a big faint watermark, centred in the rings; it fades in after the card, and drifts a little as the page scrolls (data-parallax) */
.univ > .univ__mark { position: absolute; z-index: 0; right: -1.4rem; bottom: -2.4rem; width: auto; height: 12rem; opacity: 0; pointer-events: none; user-select: none; transition: opacity 1.2s var(--ease) .3s; }
.univ.is-in > .univ__mark { opacity: .16; }
.univ--green.is-in > .univ__mark { opacity: .26; }

/* the head: the name at the left and the logo at the right of one row (they are flex items: a long name wraps, and if the two cannot share a row the
   logo goes under the name, never over it); a short rule draws itself on the line under the head once the card has come in */
.univ__head { padding-bottom: 1.25rem; border-bottom: 1px solid var(--c-line-strong); }   /* every line in a card is a real 1px border, so all of them are drawn equally thick (a 1px pseudo-element at a fractional height is not) */
.univ--blue .univ__head { border-bottom-color: rgba(255, 255, 255, .24); }
.univ__head::after { content: ""; position: absolute; left: 0; bottom: -1px; width: 2.6rem; height: 3px; background: var(--c-lime); transform: scaleX(0); transform-origin: left; transition: transform .7s var(--ease) .35s; }
.univ--green .univ__head::after { background: var(--c-blue); }
.univ.is-in .univ__head::after { transform: scaleX(1); }
.univ__top { display: flex; flex-wrap: wrap; align-items: center; gap: .5rem 1.2rem; }
.univ__logo { --logo-in: 14px; flex: none; width: auto; height: 2.3rem; max-width: 100%; margin-left: auto; object-fit: contain; object-position: right center; opacity: 0; transform: translateX(var(--logo-in)); transition: opacity .7s var(--ease) .45s, transform .7s var(--ease) .45s; user-select: none; }
.univ.is-in .univ__logo { opacity: 1; transform: none; }
/* English and Portuguese names are long: the logo goes above the name, at the left, in both cards alike */
:root:lang(en) .univ__top, :root:lang(pt) .univ__top { flex-direction: column-reverse; align-items: flex-start; gap: .7rem; }
:root:lang(en) .univ__logo, :root:lang(pt) .univ__logo { --logo-in: -14px; margin-left: 0; object-position: left center; }

.univ__name { color: var(--c-blue-dark); font-size: clamp(1.45rem, .7vw + 1.1rem, 1.9rem); font-weight: 700; line-height: 1.25; letter-spacing: .02em; }
.univ--blue .univ__name { color: #fff; }
:root:lang(en) .univ__name, :root:lang(pt) .univ__name { letter-spacing: 0; }   /* on the English and Portuguese pages the name itself is Latin: the page's own face, Helvetica Neue LT Std */
.univ__en { margin-top: .35rem; color: var(--c-text-2); font-family: var(--font-latin); font-size: .88rem; font-style: normal; font-weight: 600; letter-spacing: .03em; }   /* the English name under the Chinese one: Helvetica Neue LT Std 65 Medium (css/site.css) */
.univ--blue .univ__en { color: rgba(255, 255, 255, .82); }

/* the facts: a hairline above each, a small serif index (01 – 07) in the margin, then the text, whose numbers are set in the serif too, a little
   larger and in the card's accent; pointing at a row draws a line over its hairline, and over the hairline of the row opposite it */
.univ__items { display: flex; flex-direction: column; flex: 1; }
.item { position: relative; display: grid; grid-template-columns: 2.2rem minmax(0, 1fr); column-gap: .9rem; align-items: baseline; flex: 1; padding: .72rem 0; border-bottom: 1px solid var(--c-line-strong); }
.univ--blue .item { border-bottom-color: rgba(255, 255, 255, .24); }
.item::after { content: ""; position: absolute; left: 0; right: 0; bottom: -1px; height: 3px; background: var(--c-lime); transform: scaleX(0); transform-origin: left; transition: transform .45s var(--ease); }   /* the line that lights up is at the foot of the row, over its border */
.univ--green .item::after { background: var(--c-blue-light); }
.item:hover::after, .item.is-pair::after { transform: scaleX(1); }
.item[data-reveal].is-in { transition-delay: calc(var(--i, 0) * 90ms + .2s); }   /* the rows come in one pair after another: row 1 of both cards, then row 2 ... */
.item__idx { color: var(--c-blue); font-family: var(--font-yahei); font-size: 1.08rem; font-style: normal; font-weight: 700; letter-spacing: .04em; }
.item__text { font-size: clamp(.96rem, .2vw + .9rem, 1.1rem); line-height: 1.55; text-wrap: pretty; }
.item__text .n { color: var(--c-blue); font-family: var(--font-yahei); font-size: 1.45em; font-weight: 700; line-height: 1; letter-spacing: 0; }   /* line-height 1: the larger figure must not make its line taller, the rows of the two cards stay level */
.univ--blue .item__idx { color: var(--c-lime); }
.univ--blue .item__text { color: rgba(255, 255, 255, .94); }
.univ--blue .item__text .n { color: var(--c-lime); }

/* between the two cards: a tick for each pair of rows (a dashed line across, a dot on the spine; the pair under the pointer turns green) and, halfway
   down, the round orange play button, the one action point of the block, in a white halo that hides the spine behind it */
.univs__join { position: relative; grid-row: 1 / -1; display: flex; align-items: center; justify-content: center; padding: var(--pad-t) 0 var(--pad-b); border: 1px solid transparent; }   /* the padding and border of a card, so that in a subgrid its rows are as high as the card's */
.univs__tick { --tick: var(--c-line-strong); position: relative; grid-column: 1; opacity: 0; transition: opacity .6s var(--ease); transition-delay: calc(var(--i, 0) * 90ms + .3s); }
.univs__join.is-in .univs__tick { opacity: 1; }
.univs__tick i { position: absolute; left: 0; right: 0; top: 50%; height: 0; font-style: normal; border-top: 1px dashed var(--tick); transition: border-color .3s var(--ease); }   /* the dashed line across, a border like the others */
.univs__tick::before { content: ""; position: absolute; left: 50%; top: 0; bottom: 0; width: 0; border-left: 1px solid var(--c-line-strong); }
.univs__tick::after { content: ""; position: absolute; left: 50%; top: 50%; width: .7rem; height: .7rem; margin: -.35rem 0 0 -.35rem; border: 1.5px solid var(--c-leaf-light); border-radius: 50%; background: #fff; transition: background-color .3s var(--ease), border-color .3s var(--ease); }
.univs__tick.is-pair { --tick: var(--c-leaf-light); }
.univs__tick.is-pair::after { border-color: var(--c-leaf-light); background: var(--c-leaf-light); }
@supports not (grid-template-rows: subgrid) { .univs__tick { display: none; } }
.univs__play { position: relative; z-index: 2; grid-column: 1; grid-row: 2 / -1; align-self: center; justify-self: center; display: flex; align-items: center; justify-content: center; width: clamp(3.8rem, 3vw + 1.6rem, 4.8rem); aspect-ratio: 1; border-radius: 50%; background: var(--c-accent); color: #fff; box-shadow: var(--shadow-accent), 0 0 0 .6rem #fff; transition: transform .3s var(--ease), background-color .25s var(--ease); }
.univs__play:hover, .univs__play:focus-visible { background: var(--c-accent-dark); transform: scale(1.07); }
.univs__play:focus-visible { outline: 3px solid var(--c-blue); outline-offset: .8rem; }
.univs__join.is-in .univs__play { animation: play-in .8s var(--ease) .5s backwards; }
.univs__play-ic { display: inline-flex; margin-left: .15em; }   /* the weight of a triangle sits left of its box: nudge it right to look centred */
.univs__ring { position: absolute; inset: -.5rem; border: 1.5px dashed var(--c-leaf-light); border-radius: 50%; animation: spin 26s linear infinite; pointer-events: none; }
.univs__pulse { position: absolute; inset: 0; border: 2px solid var(--c-accent); border-radius: 50%; animation: pulse 2.8s var(--ease) infinite; pointer-events: none; }

/* where subgrid is understood (every current browser), the card, its list of facts and the play column take over the rows of the main grid
   (this block comes last so that it wins over the plain flex layout above, which is what an older browser keeps) */
@supports (grid-template-rows: subgrid) {
  .univ { display: grid; grid-template-rows: subgrid; row-gap: 0; }
  .univ__items { display: grid; grid-row: 2 / -1; grid-template-rows: subgrid; row-gap: 0; }
  .univs__join { display: grid; grid-template-rows: subgrid; row-gap: 0; align-items: stretch; justify-content: normal; }
}

/* ---------- topics and sites: a vertical title and four poster cards, 300 px high; the one under the pointer widens ----------
   A port of a fixed-pixel design, so this block is in px (the rest of the page is in rem, which follows the window). */
.topics { position: relative; padding: 100px 0; overflow: hidden; background: var(--c-blue-tint); }
.topics::before { content: ""; position: absolute; left: -11rem; bottom: -19rem; width: 26rem; height: 26rem; border: 1.5px solid var(--c-line); border-radius: 50%; pointer-events: none; }
.topics__block { position: relative; display: flex; align-items: center; }
.topics__head { display: flex; flex: none; flex-direction: column; max-width: 50px; }
.topics__title { writing-mode: vertical-lr; color: var(--c-text); font-size: 32px; font-weight: 400; line-height: 1.3; }
.topics__more { display: flex; flex-direction: column; align-items: center; gap: 20px; width: 45px; margin-top: 30px; color: var(--c-blue); font-size: 14px; }
.topics__more-txt { writing-mode: vertical-lr; line-height: 1.5; }
.topics__ic { display: block; width: 45px; height: 45px; }
.topics__ic svg { display: block; width: 100%; height: 100%; }
.topics__ic-fill, .topics__ic-light { opacity: 0; transition: opacity .2s ease-out; }
.topics__ic-light { color: #fff; }
.topics__more:hover .topics__ic-fill, .topics__more:hover .topics__ic-light,
.topics__more:focus-visible .topics__ic-fill, .topics__more:focus-visible .topics__ic-light { opacity: 1; }

.topics__list { display: flex; flex: 1 1 0; margin-left: 170px; }
/* the four cells share the row alike; the one that has the pointer (or the keyboard focus) takes two and a half shares (a card and three quarters as wide as before) and the others give way, slowly */
.topics__list > li { flex: 1 1 0; min-width: 0; margin-left: 20px; transition: flex-grow .5s var(--ease); }
.topics__list > li:hover { flex-grow: 2.4; }
.topics__list > li:has(.tcard:focus-visible) { flex-grow: 2.4; }   /* (its own rule: a browser that does not know :has() would drop the hover rule with it) */
.topics__list > li:first-child { margin-left: 0; }
@media (max-width: 1300px) { .topics__list { margin-left: 120px; } }
@media (min-width: 1700px) { .topics__title { font-size: 40px; } }

/* a card: the poster covers it (cut where it must be, whatever the width); title top left, "view more" bottom right, both set vertically */
.tcard { position: relative; display: block; height: 300px; overflow: hidden; color: #fff; }
.tcard::after { content: ""; position: absolute; inset: 0; background: var(--grad-shade); pointer-events: none; }
.tcard:focus-visible { outline: 3px solid var(--c-lime); outline-offset: -3px; }   /* drawn inside the dark poster, where the lime shows */
.tcard__pic { display: block; height: 100%; }
.tcard__pic svg, .tcard__pic img { display: block; width: 100%; height: 100%; }
.tcard__pic img { object-fit: cover; }
.tcard__tit, .tcard__more { position: absolute; z-index: 1; }
.tcard__tit { left: 24px; top: 24px; max-height: calc(100% - 48px); writing-mode: vertical-lr; white-space: pre-line; font-size: 20px; font-weight: 400; line-height: 1.3; }
.tcard__more { right: 30px; bottom: 0; writing-mode: vertical-lr; text-align: center; font-size: 14px; line-height: 1.6; }
.tcard__more::after { content: ""; display: inline-block; height: 40px; margin-top: 8px; border-left: 1px solid #fff; }
.topics--h .tcard__tit { right: 60px; max-height: none; writing-mode: horizontal-tb; font-size: 18px; line-height: 1.35; overflow-wrap: break-word; hyphens: auto; }   /* across, and not as far as the "view more" at the right edge */

/* they come in over a second, the first and third from above, the second and fourth from below (effects.js adds .is-in once the card is seen) */
.tcard[data-reveal] { --from: -50px; transform: translate3d(0, var(--from), 0); transition: opacity 1s ease-out, transform 1s ease-out; }
.topics__list > li:nth-child(even) .tcard { --from: 50px; }
.tcard[data-reveal].is-in { transform: none; }
@media (prefers-reduced-motion: reduce) { .topics__list > li { transition: none; } }

/* ---------- partner map: made like the cooperation map of usco.edu.cn (the Shanghai Cooperation Organisation University): a band (theirs is blue, ours the college green) with a faint world behind it, a
   globe of dots standing on its foot, rows of capsules - the emblem of a university, alone - that run to the left over the globe at their own speeds (each
   held still under the pointer, the ends fading out), and a pulse that spreads from the one place of the map, here the seal of the Dalian University of Foreign
   Languages on Dalian. The sizes are the original's, written in --mu, which is what a rem is there (a nineteenth-twentieth of the window: 75 px on 1440, 100 px
   from 1920 up; the page is never narrower than 1200 px, base.css). The pictures are drawn by tools/make-partner-globe.py, the capsules written by
   tools/make-partner-map.py. The original's panel on the right (the tabs and the lists) is not made. ---------- */
.map-sec {
  --mu: clamp(64px, 5.2083vw, 100px);
  --cap-pitch: calc(var(--mu) * 2.4333);
  position: relative;
  padding: calc(var(--mu) * 1.22) 0 0;
  overflow: hidden;
  background: url("../media/map/map-bg.png") center / cover no-repeat, radial-gradient(ellipse 55% 75% at 12% 100%, rgba(238, 248, 214, .75) 0%, rgba(238, 248, 214, 0) 70%), radial-gradient(ellipse 45% 60% at 66% 62%, rgba(43, 100, 11, .22) 0%, rgba(43, 100, 11, 0) 75%), linear-gradient(172deg, var(--c-brand) 0%, var(--c-lime) 100%);   /* the college green at the top, lightening to the lime at the foot (the right-edge quick-link bar is the college green too and has to stand out on it), a pale glow at the lower left and a shade of the leaf green behind the globe */
}
.map-sec__c { position: relative; width: min(calc(100% - 2rem), calc(var(--mu) * 15.2)); margin: 0 auto; padding-top: calc(var(--mu) * 1.1); }
/* the title stands in the content column of the page, at the left, like the titles of the news, the programmes and the enquiry (the column is the page's .container) */
.map-sec__head { position: absolute; z-index: 10; top: calc(var(--mu) * 1.22); left: 0; right: 0; pointer-events: none; }
.map-sec__head > * { pointer-events: auto; }
/* on the green the title is the navy (white is 1.8 : 1 on the college green and does not read), the leaf behind its first characters and the pale English word are white */
.map-sec .sec-title__text { color: var(--c-blue-dark); }
.map-sec .sec-title::before { background: linear-gradient(135deg, rgba(255, 255, 255, .55) 0%, rgba(255, 255, 255, .1) 100%); }
.map-sec .sec-title::after { color: rgba(255, 255, 255, .5); }
.pmap { position: relative; min-height: calc(var(--mu) * 6.85); }
/* the globe stands on the foot of the band, as wide as the original's picture and centred (a narrow window crops it on both sides); Dalian is a place on it, in percent of its box */
.pmap__globe {
  position: absolute;
  left: 50%;
  bottom: 0;
  z-index: 0;
  width: calc(var(--mu) * 17.19);
  height: calc(var(--mu) * 5.92);
  transform: translateX(-50%);
  background: url("../media/map/globe.png") center / 100% 100% no-repeat;
  pointer-events: none;
}

/* Dalian: three layers of pulse, each growing to one and a half times its size while it fades in and out, and the seal of the university on them */
.pmap__origin { position: absolute; z-index: 3; left: var(--x); top: var(--y); width: 0; height: 0; }
.pmap__ring { position: absolute; left: 0; top: 0; border-radius: 50%; animation: pmap-pulse 3s linear infinite; }
.pmap__ring:nth-child(1) { z-index: 2; width: calc(var(--mu) * 1.71); height: calc(var(--mu) * 1.71); margin: calc(var(--mu) * -.855) 0 0 calc(var(--mu) * -.855); background: rgba(238, 248, 214, .8); }
.pmap__ring:nth-child(2) { z-index: 1; width: calc(var(--mu) * 1.71); height: calc(var(--mu) * 1.71); margin: calc(var(--mu) * -.855) 0 0 calc(var(--mu) * -.855); background: rgba(179, 225, 77, .75); animation-delay: -2s; }
.pmap__ring:nth-child(3) { z-index: 8; width: calc(var(--mu) * 1.14); height: calc(var(--mu) * 1.14); margin: calc(var(--mu) * -.57) 0 0 calc(var(--mu) * -.57); border: 1px solid #fff; background: #fff; animation-delay: -1s; }
@keyframes pmap-pulse { 0% { transform: scale(1); opacity: 0; } 50% { opacity: 1; } 100% { transform: scale(1.5); opacity: 0; } }
.pmap__seal { position: absolute; left: 0; top: 0; z-index: 9; max-width: none; width: calc(var(--mu) * .58); height: calc(var(--mu) * .58); margin: calc(var(--mu) * -.29) 0 0 calc(var(--mu) * -.29); border-radius: 50%; background: #fff; }

/* the rows: a window of 80% of the band's width, its ends fading out, with a row of capsules in it that moves to the left (js/site.js doubles the row and sets
   the time of its turn from its width and its speed: data-speed, in pixels a second; each row is indented by its --off tenths of a capsule, so they do not stand in step) */
.pmap__panel { position: relative; z-index: 9; }
.pmap__row { position: relative; width: 100%; overflow: hidden; }
.pmap__win {
  position: relative;
  overflow: hidden;
  width: 80%;
  margin: calc(var(--mu) * .25) auto 0;
  -webkit-mask-image: linear-gradient(to right, transparent 0%, #000 15%, #000 85%, transparent 100%);
  mask-image: linear-gradient(to right, transparent 0%, #000 15%, #000 85%, transparent 100%);
}
.pmap__list { display: flex; width: max-content; margin: 0 0 0 calc(15% + var(--off, 0) * var(--cap-pitch) / 10); padding: 0; list-style: none; }
.pmap__list.is-looping { animation: pmap-run var(--mq-time, 60s) linear infinite; }
@keyframes pmap-run { to { transform: translateX(-50%); } }
.pmap__row:hover .pmap__list { animation-play-state: paused; }
.pmap__cap { flex: none; width: calc(var(--mu) * var(--cw, 2.22)); margin: 0 calc(var(--mu) * .1067); }   /* as long as its emblem asks: the page says it for each one (--cw), the original's 2.22 where it says nothing */

/* a capsule: the emblem of a university, alone, in the middle of it (a wide one - a name written out - as wide as the capsule lets it be, a round one as high as
   the capsule lets it be); no letters are made up for a university without an emblem, and no name is written beside one: the name is its alt text and the capsule's title */
.pmap__pill {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: calc(var(--mu) * .08);
  box-sizing: border-box;
  height: calc(var(--mu) * .6);
  padding: calc(var(--mu) * .1);
  border: 1px solid #fed796;
  border-radius: calc(var(--mu) * .36);
  background: rgba(255, 255, 255, .8);
  box-shadow: calc(var(--mu) * .08) calc(var(--mu) * .18) calc(var(--mu) * .51) 0 rgba(43, 100, 11, .22);
  transition: background .5s;
}
.pmap__pill:hover { background: #fff; }
.pmap__mark { display: block; flex: 0 1 auto; min-width: 0; width: auto; max-width: 100%; height: auto; max-height: 100%; object-fit: contain; }
/* the section moves only while it is in the window (js/site.js sets .is-live); the page does not spend its time on what nobody sees */
.map-sec:not(.is-live) .pmap__list, .map-sec:not(.is-live) .pmap__ring { animation-play-state: paused; }
@media (prefers-reduced-motion: reduce) {
  .pmap__win { overflow-x: auto; scrollbar-width: thin; -webkit-mask-image: none; mask-image: none; }
  .pmap__list.is-looping { animation: none; }
  .pmap__list > [aria-hidden="true"] { display: none; }
  .pmap__ring { animation: none; opacity: .35; }
}

/* ---------- news: the college news on top - photographs at the left, the four newest items as cards at the right - and under them the public notices and the
   admission news side by side, laid out alike (a title and a date on each row, as many rows in one as in the other) ---------- */
.news-sec { padding: 4.5rem 0 6.5rem; background: var(--c-blue-tint); }
.news {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  grid-template-areas: "college college" "notice admission";
  gap: 2.8rem 3.4rem;
  margin-top: .4rem;
}
.news__col--notice { grid-area: notice; }
.news__col--college { grid-area: college; }
.news__col--admission { grid-area: admission; }
.news__bar { display: flex; align-items: center; justify-content: space-between; min-height: 2.6rem; margin-bottom: .4rem; padding-bottom: .8rem; border-bottom: 1px solid var(--c-line); }
.news__name { font-size: 1.35rem; }

/* dated rows, dashed rules */
.news__row { display: flex; align-items: baseline; gap: 1rem; padding: .9rem 0; border-bottom: 1px dashed var(--c-line-strong); }
.news__title { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 1.08rem; transition: color .2s var(--ease), transform .25s var(--ease); }
.news__row:hover .news__title { color: var(--c-blue); transform: translateX(4px); }
.news__date { flex: none; color: var(--c-text-3); font-size: .875rem; font-variant-numeric: tabular-nums; }
.news__list .news__row { animation: rise .4s var(--ease) backwards; }
.news__list .news__row:nth-child(2) { animation-delay: .05s; }
.news__list .news__row:nth-child(3) { animation-delay: .1s; }
.news__list .news__row:nth-child(4) { animation-delay: .15s; }
.news__list .news__row:nth-child(5) { animation-delay: .2s; }
.news__list .news__row:nth-child(6) { animation-delay: .25s; }
/* the four newest college news: date, title, a two-line summary */
.news__cards { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1.4rem; }
/* the college news: the photographs at the left (five parts of the width), the cards at the right (seven), the photographs as high as the cards */
.news__college { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); gap: 1.4rem; align-items: stretch; margin-top: 1.1rem; }
/* the photographs: each a link with its picture and a caption on a dark wash; they fade into one another (js/site.js: initPhotos), one dot for each */
.photos { --c-focus: var(--c-lime); position: relative; isolation: isolate; overflow: hidden; min-height: 17rem; border-radius: var(--radius); background: var(--c-blue-dark); box-shadow: var(--shadow-1); }
.photos__slide { position: absolute; inset: 0; opacity: 0; visibility: hidden; transition: opacity .8s var(--ease), visibility 0s linear .8s; }
.photos__slide.is-active { opacity: 1; visibility: visible; transition: opacity .8s var(--ease), visibility 0s; }
.photos__link { position: relative; display: block; width: 100%; height: 100%; overflow: hidden; color: #fff; }
.photos__link:focus-visible { outline-offset: -4px; }
.photos__link::after { content: ""; position: absolute; inset: 0; background: linear-gradient(180deg, rgba(0, 24, 70, 0) 42%, rgba(0, 24, 70, .8) 100%); }
.photos__img { display: block; width: 100%; height: 100%; object-fit: cover; transform: scale(1.06); transition: transform 6s linear; }
.photos__slide.is-active .photos__img { transform: none; }
.photos__cap { position: absolute; z-index: 1; left: 1.5rem; right: 1.5rem; bottom: 2.7rem; display: -webkit-box; overflow: hidden; -webkit-line-clamp: 2; -webkit-box-orient: vertical; color: #fff; font-size: 1.2rem; font-weight: 500; line-height: 1.5; }
.photos__link:hover .photos__cap { text-decoration: underline; text-underline-offset: .25em; }
.photos__dots { position: absolute; z-index: 2; left: 1.5rem; bottom: 1rem; display: flex; gap: .55rem; }
.photos__dot { width: .75rem; height: .75rem; border: 2px solid #fff; border-radius: 50%; background: transparent; transition: background-color .25s var(--ease), transform .25s var(--ease); }
.photos__dot:hover { background: rgba(255, 255, 255, .45); }
.photos__dot[aria-current="true"] { background: #fff; transform: scale(1.2); }
@media (prefers-reduced-motion: reduce) { .photos__slide, .photos__img { transition: none; } .photos__img { transform: none; } }
.ncard { position: relative; isolation: isolate; overflow: hidden; display: flex; flex-direction: column; gap: .45rem; padding: 1.3rem 1.6rem 1.25rem; border-radius: var(--radius); background: #fff; box-shadow: var(--shadow-1); transition: transform .3s var(--ease), box-shadow .3s var(--ease); }
.ncard:hover { transform: translateY(-4px); box-shadow: var(--shadow-2); }
/* The box carries the lettering and the tile pattern of the Polo UA@DUFL picture, drawn faintly behind the words (two PNGs in media/news/, already in the
   site's greens - --c-leaf-light for the tiles, --c-leaf for the lettering; how faint is --news-tile-opacity and --news-mark-opacity in tokens.css):
   the tiles along the right edge, the lettering tilted across the lower left. Behind the words, and the pointer goes through them. They are background
   pictures, not CSS masks: a mask picture is fetched with CORS, which a page opened from disk (a double click) cannot give, so it would never show there. */
.ncard::before { content: ""; position: absolute; z-index: -1; top: 0; right: 0; bottom: 0; width: 46%; background: url("../media/news/azulejo.png") no-repeat right center / auto 118%; opacity: var(--news-tile-opacity); pointer-events: none; transition: opacity .4s var(--ease); }
.ncard::after { content: ""; position: absolute; z-index: -1; left: .8rem; bottom: .3rem; width: 64%; aspect-ratio: 485 / 82; background: url("../media/news/polo-ua-dufl.png") no-repeat center / contain; opacity: var(--news-mark-opacity); pointer-events: none; transform: rotate(-5deg); transform-origin: left bottom; transition: opacity .4s var(--ease); }
.ncard:hover::before { opacity: calc(var(--news-tile-opacity) * 1.35); }
.ncard:hover::after { opacity: calc(var(--news-mark-opacity) * 1.35); }
.ncard__date { color: var(--c-text-3); font-size: .85rem; font-variant-numeric: tabular-nums; }
.ncard__title { display: -webkit-box; overflow: hidden; -webkit-line-clamp: 2; -webkit-box-orient: vertical; color: var(--c-text); font-size: 1.2rem; line-height: 1.5; transition: color .2s var(--ease); }
.ncard:hover .ncard__title { color: var(--c-blue); }
.ncard__sum { display: -webkit-box; overflow: hidden; -webkit-line-clamp: 2; -webkit-box-orient: vertical; color: var(--c-text-2); font-size: .9rem; line-height: 1.7; }
.ncard__go { position: absolute; right: 1.4rem; top: 1.15rem; display: inline-flex; color: var(--c-blue); transition: transform .25s var(--ease); }
.ncard:hover .ncard__go { transform: translateX(4px); }

/* ---------- programmes: only their names, set large - the undergraduate programme first, then the postgraduate ones. The names come in one after
   another when the section is scrolled to, and then each row drifts sideways with the scroll (js/site.js writes --p, from 0 to 1, on every
   [data-scroll] element; the two rows drift the opposite way) ---------- */
.prog-sec { padding: 4.5rem 0 6.5rem; background: #fff; }
.prog-list { margin-top: 1.2rem; overflow-x: clip; border-top: 1px solid var(--c-line-strong); }
.prog-row { --accent: var(--c-brand); --drift: 4.5rem; display: grid; grid-template-columns: minmax(9rem, 14rem) minmax(0, 1fr); align-items: center; column-gap: 2rem; padding: 2.3rem 0; border-bottom: 1px solid var(--c-line-strong); }
.prog-row + .prog-row { --accent: var(--c-blue); --drift: -4.5rem; }   /* the two levels are told apart by the college green and the blue */
.prog-row__level { display: flex; align-items: center; gap: .7rem; color: var(--c-blue); font-size: 1.05rem; font-weight: 700; letter-spacing: .14em; }
.prog-row__level::before { content: ""; flex: none; width: .7rem; height: .7rem; border-radius: 50%; background: var(--accent); }
.prog-row__names { display: flex; flex-wrap: wrap; gap: .3rem 3.6rem; min-width: 0; transform: translate3d(calc((var(--p, .5) - .5) * var(--drift)), 0, 0); }
.prog-name { color: var(--c-blue-dark); font-size: clamp(2rem, 1.8vw + 1.3rem, 3.4rem); line-height: 1.3; }
.prog-name[data-reveal].is-in { transition-delay: calc(var(--i, 0) * 120ms + .15s); }   /* the names of a row come in one after another */
.prog-name span { position: relative; display: inline-block; padding-bottom: .1em; }
.prog-name span::after { content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 3px; border-radius: 2px; background: var(--accent); transform: scaleX(0); transform-origin: left; transition: transform .9s var(--ease) calc(var(--i, 0) * 140ms + .5s); }   /* the line under a name draws itself once the name is in */
.prog-name.is-in span::after { transform: scaleX(1); }
:root:lang(en) .prog-name, :root:lang(pt) .prog-name { font-size: clamp(1.6rem, 1.3vw + 1.05rem, 2.5rem); }   /* English and Portuguese names are longer */
@media (prefers-reduced-motion: reduce) { .prog-name span::after { transition: none; } }

/* ---------- enquiry: a light block, one big translucent circle behind the left side, the form on a white card; the explanation on the left and the card are one height (the grid stretches both,
   the explanation's last block stands at its foot, the message field takes what is left of the card) ---------- */
.lead-sec { --c-mark: var(--c-blue-dark); position: relative; padding: 4.5rem 0 6.5rem; overflow: hidden; background: var(--c-lime); scroll-margin-top: 1.5rem; }   /* the enquiry buttons lead here: the block stops a little below the fixed header, not under it */
.lead-sec::before { content: ""; position: absolute; left: -16rem; top: -12rem; width: 54rem; height: 54rem; border-radius: 50%; background: var(--grad-orb); pointer-events: none; }
.lead { position: relative; display: grid; grid-template-columns: 4.4fr 6.6fr; gap: 4.5rem; align-items: stretch; }
.lead__intro { display: flex; min-width: 0; flex-direction: column; }
.lead__heading { margin-top: .4rem; color: var(--c-blue-dark); font-size: 1.75rem; font-weight: 700; line-height: 1.45; }
.lead__sub { margin-top: 1rem; color: var(--c-lime-text-2); font-size: 1.0625rem; line-height: 1.8; }
.lead__points { display: grid; gap: 1rem; margin-top: 1.9rem; color: var(--c-lime-text-2); font-size: 1.0625rem; line-height: 1.6; }
.lead__points li { display: flex; align-items: flex-start; gap: .7rem; }
.lead__points .ic { display: inline-flex; flex: none; margin-top: .25rem; color: var(--c-mark); }
.lead__entry-title { margin-top: 2.2rem; color: var(--c-lime-text-3); font-size: 1rem; font-weight: 700; letter-spacing: .08em; }
.lead__contact, .lead__entry { margin-top: auto; padding-top: 2.6rem; }   /* what the card's height leaves over is shared between the two gaps before them; the last block stands at the foot of the column, as low as the card does */
.lead__contact .lead__entry-title, .lead__entry .lead__entry-title { margin-top: 0; }
.lead__contact-list { display: grid; gap: 1.2rem; margin-top: 1.1rem; }
.lead__contact-list li { display: flex; align-items: flex-start; gap: 1rem; }
.lead__ci { display: inline-flex; flex: none; align-items: center; justify-content: center; width: 3.2rem; height: 3.2rem; border-radius: 50%; background: rgba(255, 255, 255, .7); color: var(--c-blue-dark); box-shadow: 0 0 0 1px rgba(0, 32, 91, .08); }
.lead__cv { display: flex; min-width: 0; flex-direction: column; gap: .12rem; padding-top: .1rem; }
.lead__cv strong { color: var(--c-blue-dark); font-size: 1.125rem; font-weight: 700; line-height: 1.45; overflow-wrap: anywhere; }
.lead__cv small { color: var(--c-lime-text-3); font-size: .9375rem; line-height: 1.45; }
.lead__intents { display: flex; flex-wrap: wrap; gap: .8rem; margin-top: .8rem; }
.lead__intent {
  display: inline-flex;
  align-items: center;
  gap: .6rem;
  padding: .85rem 1.5rem .85rem 1.25rem;
  border: 1.5px solid var(--c-blue-dark);
  border-radius: var(--radius);
  color: var(--c-blue-dark);
  font-size: 1.0625rem;
  font-weight: 700;
  transition: background-color .2s var(--ease), color .2s var(--ease);
}
.lead__intent::before { content: ""; border-top: .32rem solid transparent; border-bottom: .32rem solid transparent; border-left: .5rem solid currentColor; }
.lead__intent:hover { background: rgba(255, 255, 255, .7); }
.lead__intent[aria-pressed="true"] { background: var(--c-blue-dark); color: #fff; }
@media (max-width: 1180px) { .lead { grid-template-columns: 1fr; gap: 2.5rem; } }   /* side by side only where the card has room for two fields to a line and the explanation for its contact lines */

/* ---------- the grounds ---------- */
/* White and the palest blue take turns down the page (the mission, the events and the programmes are white, the topics and the news the palest blue), so no
   line is needed to say where a band stops. The enquiry block is the lime: there the leaf behind its title is white. */
.lead-sec .sec-title::before { background: linear-gradient(135deg, rgba(255, 255, 255, .75) 0%, rgba(255, 255, 255, .18) 100%); }

/* ===== pages.css ===== */
/* pages.css — inner page templates (filled in by Tasks 16–26) */

/* ===== motion.css ===== */
/* motion.css — reveal, page transition, pause, card spotlight, reduced-motion overrides.
   Scroll-driven and auto-playing animation uses transform and opacity only. */

/* page fade-in */
@keyframes page-in { from { opacity: 0; } to { opacity: 1; } }
body { animation: page-in .4s var(--ease) both; }

/* scroll reveal: [data-reveal] (up) | left | scale; effects.js adds .is-in once the element is seen */
[data-reveal] {
  opacity: 0;
  transform: translate3d(0, 24px, 0);
  transition: opacity var(--dur) var(--ease), transform var(--dur) var(--ease);
}
[data-reveal="left"] { transform: translate3d(-32px, 0, 0); }
[data-reveal="scale"] { transform: scale(.94); }
[data-reveal].is-in { opacity: 1; transform: none; }

/* leaving the page */
html.is-leaving body { opacity: 0; transition: opacity .2s ease; }

/* hidden tab: freeze looping animation */
html.is-paused *, html.is-paused *::before, html.is-paused *::after { animation-play-state: paused !important; }

/* pointer-following highlight on cards (effects.js writes --mx / --my) */
.card::after {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
  background: radial-gradient(420px circle at var(--mx, 50%) var(--my, 50%), rgba(0, 51, 160, .08), transparent 60%);
  opacity: 0;
  pointer-events: none;
  transition: opacity .3s var(--ease);
}
.card:hover::after { opacity: 1; }

@media (prefers-reduced-motion: reduce) {
  [data-reveal] { opacity: 1; transform: none; transition: none; }
  html.is-leaving body { opacity: 1; transition: none; }
  .card::after { display: none; }
  *, *::before, *::after {
    animation: none !important;
    transition-duration: .01ms !important;
    transition-delay: 0s !important;
    scroll-behavior: auto !important;
  }
}

/* looping keyframes (transform only) */
@keyframes drift {
  from { transform: translate3d(0, 0, 0) scale(1); }
  50% { transform: translate3d(4vw, -3vh, 0) scale(1.08); }
  to { transform: translate3d(-3vw, 3vh, 0) scale(.96); }
}
@keyframes float {
  0%, 100% { transform: translate3d(0, 0, 0); }
  50% { transform: translate3d(0, -8px, 0); }
}
@keyframes spin { to { transform: rotate(360deg); } }
/* the play button: it pops in, and a ring spreads out from it again and again */
@keyframes play-in { from { opacity: 0; transform: scale(.4); } }
@keyframes pulse { from { opacity: .55; transform: scale(1); } to { opacity: 0; transform: scale(1.6); } }
/* content swapped inside a module (the news lists): the new items rise into place, one after another */
@keyframes rise {
  from { opacity: 0; transform: translate3d(0, 12px, 0); }
  to { opacity: 1; transform: none; }
}

/* ===== faculty page (faculty/full-time.html) ===== */
/* 参考上海交大外院师资名录的列表区：按系所分组、纯姓名、可折叠；没有 banner、面包屑、标题区、左侧栏和任何人数统计。 */
.fac-page { padding-top: calc(var(--topbar-h) + var(--header-h)); background: #fff; }
.fac-body { padding: 2.6rem 0 5rem; }

.fac-title { margin: 0 0 1.1rem; color: var(--c-blue-dark); font-size: clamp(1.5rem, 1.1vw + 1.2rem, 2rem); font-weight: 700; line-height: 1.3; }

.fac-groups { border-top: 2px solid var(--c-brand); }
.fac-group { border-bottom: 1px solid var(--c-line); scroll-margin-top: calc(var(--header-h-compact, 72px) + 1rem); }
.fac-group > summary { display: flex; align-items: center; justify-content: space-between; gap: 1rem; padding: 1.25rem .1rem; cursor: pointer; list-style: none; }
.fac-group > summary::-webkit-details-marker { display: none; }
.fac-group > summary:focus-visible { outline: 2px solid var(--c-blue); outline-offset: 3px; }
.fac-group__name { color: var(--c-blue-dark); font-size: 1.12rem; font-weight: 700; }
.fac-group > summary::after { content: "＋"; flex: none; color: var(--c-text-4); font-size: 1.05rem; font-weight: 400; }
.fac-group[open] > summary::after { content: "－"; }

.fac-names { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: .3rem 1.5rem; margin: 0; padding: 0 0 1.6rem; list-style: none; }
.fac-names li { color: var(--c-text-2); font-size: .9875rem; line-height: 2; }

@media (max-width: 1199px) {
  .fac-names { grid-template-columns: repeat(4, minmax(0, 1fr)); }
}
@media (max-width: 899px) {
  .fac-body { padding-top: 2rem; }
  .fac-names { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}
@media (max-width: 599px) {
  .fac-names { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

/* ===== news list page (news/index.html) ===== */
/* news-list.css — 文章列表页（news/index.html）的样式片段。
   只新增 np-* 类，颜色、圆角、阴影与动效全部取自 css/site.css 的 token；
   不改写站内既有类，也不写全局元素覆盖。
   站点只有一个样式表，建议把本片段合并到 css/site.css 末尾（或在页面中于 site.css 之后引入）。 */

/* ---------- 页面本体 ---------- */
.np-list-page { min-width: 0; }   /* 共享样式表按 PC 端（min-width: 1200px）写成；本页需要窄屏适配 */

/* ---------- 页头：面包屑、标题、导语与三个栏目统计 ---------- */
.np-pagehead {
  position: relative;
  overflow: hidden;
  padding: calc(var(--topbar-h) + var(--header-h) + clamp(2.25rem, 5vw, 4rem)) 0 clamp(2.5rem, 5vw, 3.75rem);
  border-bottom: 1px solid var(--c-line);
  background: linear-gradient(180deg, var(--c-blue-tint) 0%, #fff 100%);
}
.np-pagehead::before {
  content: "";
  position: absolute;
  top: -12rem;
  right: -6rem;
  width: clamp(22rem, 38vw, 34rem);
  height: clamp(22rem, 38vw, 34rem);
  border: 1px solid rgba(146, 212, 0, .38);
  border-radius: 50%;
  pointer-events: none;
}
.np-pagehead::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: 0;
  width: clamp(6rem, 12vw, 11rem);
  height: 4px;
  background: var(--c-brand);
  pointer-events: none;
}
.np-pagehead__inner { position: relative; z-index: 1; }
.np-pagehead__word {
  position: absolute;
  right: 3%;
  bottom: -.7rem;
  z-index: 0;
  color: rgba(0, 51, 160, .05);
  font-family: var(--font-display);
  font-size: clamp(6rem, 16vw, 14rem);
  font-weight: 700;
  line-height: .8;
  letter-spacing: .02em;
  pointer-events: none;
  user-select: none;
}

.np-crumbs { margin-bottom: clamp(1.75rem, 3.5vw, 2.75rem); font-size: .875rem; }
.np-crumbs ol { display: flex; flex-wrap: wrap; align-items: center; gap: .45rem; }
.np-crumbs li { display: flex; align-items: center; gap: .45rem; }
.np-crumbs li + li::before { content: "/"; color: var(--c-gray); }
.np-crumbs a { display: inline-block; padding: .12rem 0; color: var(--c-text-2); transition: color .2s var(--ease); }   /* 24px high at least (WCAG 2.5.8) */
.np-crumbs a:hover { color: var(--c-blue); text-decoration: underline; text-underline-offset: 3px; }
.np-crumbs [aria-current="page"] { color: var(--c-blue-dark); font-weight: 600; }

.np-pagehead__main {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(19rem, 29rem);
  align-items: end;
  gap: clamp(2rem, 4vw, 4rem);
}
.np-pagehead__eyebrow {
  display: block;
  margin-bottom: .5rem;
  color: var(--c-green-text);
  font-size: .8rem;
  font-weight: 700;
  letter-spacing: .16em;
  text-transform: uppercase;
}
.np-pagehead__title {
  color: var(--c-blue-dark);
  font-size: clamp(2.4rem, 4.6vw, 3.5rem);
  font-weight: 400;
  line-height: 1.12;
  letter-spacing: .01em;
}
.np-pagehead__lead {
  max-width: 44rem;
  margin-top: 1rem;
  color: var(--c-text-2);
  font-size: 1rem;
  line-height: 1.85;
}

.np-stats { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: .65rem; }
.np-stat {
  display: flex;
  flex-direction: column;
  gap: .15rem;
  padding: .9rem 1.05rem .85rem;
  border: 1px solid var(--c-line);
  border-top: 3px solid var(--c-brand);
  border-radius: var(--radius-lg);
  background: #fff;
  transition: transform .25s var(--ease), box-shadow .25s var(--ease);
}
.np-stat--notice { border-top-color: var(--c-blue); }
.np-stat--admission { border-top-color: var(--c-accent); }
.np-stat:hover { transform: translateY(-3px); box-shadow: var(--shadow-2); }
.np-stat strong {
  color: var(--c-blue);
  font-size: 1.8rem;
  font-weight: 700;
  line-height: 1.1;
  font-variant-numeric: tabular-nums;
}
.np-stat span { color: var(--c-text-3); font-size: .8rem; line-height: 1.4; }

/* ---------- 主栏与侧栏 ---------- */
.np-body { padding: clamp(2.5rem, 5vw, 4rem) 0 clamp(4rem, 8vw, 6rem); background: var(--c-blue-tint); }
.np-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 20rem;
  align-items: start;
  gap: clamp(1.75rem, 3.2vw, 3rem);
}
.np-main { min-width: 0; }
.np-side { display: flex; flex-direction: column; gap: 1.25rem; min-width: 0; }

.np-sec-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 1rem;
}
.np-sec-title {
  display: flex;
  align-items: center;
  gap: .55rem;
  color: var(--c-blue-dark);
  font-size: 1.35rem;
  font-weight: 700;
  line-height: 1.3;
}
.np-sec-title::before {
  content: "";
  flex: none;
  width: 4px;
  height: 1.15em;
  border-radius: 2px;
  background: var(--c-brand);
}
.np-sec-note { color: var(--c-text-3); font-size: .82rem; }

/* ---------- 头条大卡片 ---------- */
.np-feature {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(0, 1fr);
  overflow: hidden;
  border: 1px solid var(--c-line);
  border-radius: var(--radius-lg);
  background: #fff;
  box-shadow: var(--shadow-1);
  transition: box-shadow .35s var(--ease);
}
.np-feature:hover { box-shadow: var(--shadow-2); }
.np-feature:focus-within { outline: 3px solid var(--c-focus); outline-offset: 3px; }
.np-feature__media {
  position: relative;
  min-height: clamp(18rem, 26vw, 24rem);
  overflow: hidden;
  background: var(--c-blue-tint);
}
.np-feature__media img {
  position: absolute;
  inset: 0;
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform .7s var(--ease);
}
.np-feature:hover .np-feature__media img { transform: scale(1.035); }

.np-feature__body {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: .8rem;
  padding: clamp(1.5rem, 2.6vw, 2.5rem);
}
.np-meta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: .75rem;
  color: var(--c-text-3);
  font-size: .82rem;
}
.np-meta time { font-variant-numeric: tabular-nums; }

.np-cat { letter-spacing: .02em; }
.np-cat--news { background: var(--c-lime); color: var(--c-blue-dark); }
.np-cat--notice { background: var(--c-blue-tint); color: var(--c-blue); box-shadow: inset 0 0 0 1px rgba(0, 51, 160, .16); }
.np-cat--admission { background: var(--c-accent-tint); color: var(--c-danger); }

.np-feature__title {
  margin-top: .1rem;
  font-size: clamp(1.4rem, 2.1vw, 1.85rem);
  line-height: 1.4;
}
.np-feature__title a { color: var(--c-blue-dark); transition: color .2s var(--ease); }
.np-feature__title a::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 1;
  border-radius: inherit;
}
.np-feature__title a:focus-visible { outline: none; }
.np-feature:hover .np-feature__title a,
.np-feature:focus-within .np-feature__title a { color: var(--c-blue); }
.np-feature__sum { color: var(--c-text-2); font-size: .95rem; line-height: 1.8; }
.np-feature__more {
  display: inline-flex;
  align-items: center;
  gap: .45rem;
  margin-top: auto;
  padding-top: .35rem;
  color: var(--c-blue);
  font-size: .88rem;
  font-weight: 700;
}
.np-feature__more svg { transition: transform .25s var(--ease); }
.np-feature:hover .np-feature__more svg { transform: translateX(4px); }

/* ---------- 筛选条与文章列表 ---------- */
.np-feed {
  margin-top: clamp(1.75rem, 3vw, 2.5rem);
  padding: clamp(1.25rem, 2.4vw, 2rem);
  border: 1px solid var(--c-line);
  border-radius: var(--radius-lg);
  background: #fff;
  box-shadow: var(--shadow-1);
}
.np-feed__head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 1rem 1.5rem;
  padding-bottom: 1.1rem;
  border-bottom: 1px solid var(--c-line);
}
.np-feed__count { margin-top: .35rem; color: var(--c-text-3); font-size: .82rem; }

.np-filters {
  display: flex;
  flex-wrap: wrap;
  gap: .25rem;
  padding: .28rem;
  border: 1px solid var(--c-line);
  border-radius: 999px;
  background: var(--c-blue-tint);
}
.np-filter {
  display: inline-flex;
  align-items: center;
  padding: .38rem .95rem;
  border-radius: 999px;
  color: var(--c-text-2);
  font-size: .85rem;
  font-weight: 600;
  line-height: 1.4;
  white-space: nowrap;
  transition: background-color .2s var(--ease), color .2s var(--ease), box-shadow .2s var(--ease);
}
.np-filter:hover { background: #fff; color: var(--c-blue); }
.np-filter[aria-current="page"] {
  background: var(--c-blue);
  color: #fff;
  box-shadow: 0 4px 12px rgba(0, 51, 160, .24);
}

.np-list { margin-top: .25rem; }
.np-item {
  position: relative;
  display: grid;
  grid-template-columns: 5.1rem minmax(0, 1fr) 2.5rem;
  align-items: start;
  gap: clamp(1rem, 2vw, 1.5rem);
  padding: 1.4rem .55rem;
  border-bottom: 1px solid var(--c-line);
  border-radius: var(--radius);
  transition: background-color .25s var(--ease);
}
.np-list > li:last-child .np-item { border-bottom: 0; padding-bottom: 1.1rem; }
.np-item:hover { background: var(--c-blue-tint); }
.np-item:focus-within { background: var(--c-blue-tint); outline: 3px solid var(--c-focus); outline-offset: -3px; }

.np-date {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: .55rem .25rem .5rem;
  border-radius: var(--radius);
  background: var(--c-blue-tint);
  text-align: center;
  transition: background-color .25s var(--ease);
}
.np-date__day {
  color: var(--c-blue);
  font-size: 1.85rem;
  font-weight: 700;
  line-height: 1;
  font-variant-numeric: tabular-nums;
  transition: color .25s var(--ease);
}
.np-date__mon {
  margin-top: .18rem;
  color: var(--c-text-2);
  font-size: .78rem;
  font-weight: 700;
  line-height: 1.2;
  transition: color .25s var(--ease);
}
.np-date__year {
  color: var(--c-text-3);
  font-size: .62rem;
  line-height: 1.2;
  letter-spacing: .03em;
  transition: color .25s var(--ease);
}
.np-item:hover .np-date,
.np-item:focus-within .np-date { background: var(--c-blue); }
.np-item:hover .np-date__day,
.np-item:focus-within .np-date__day { color: #fff; }
.np-item:hover .np-date__mon,
.np-item:hover .np-date__year,
.np-item:focus-within .np-date__mon,
.np-item:focus-within .np-date__year { color: rgba(255, 255, 255, .82); }

.np-item__body { min-width: 0; }
.np-item__meta { display: flex; flex-wrap: wrap; align-items: center; gap: .5rem; }
.np-item__title { margin-top: .45rem; font-size: 1.08rem; line-height: 1.55; }
.np-item__title a { color: var(--c-blue-dark); transition: color .2s var(--ease); }
.np-item__title a::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 1;
  border-radius: inherit;
}
.np-item__title a:focus-visible { outline: none; }
.np-item:hover .np-item__title a,
.np-item:focus-within .np-item__title a { color: var(--c-blue); }
.np-item__sum {
  display: -webkit-box;
  margin-top: .3rem;
  overflow: hidden;
  color: var(--c-text-2);
  font-size: .88rem;
  line-height: 1.7;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}

.np-item__go {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  align-self: center;
  width: 2.5rem;
  height: 2.5rem;
  border: 1px solid var(--c-line);
  border-radius: 50%;
  color: var(--c-blue);
  transition: background-color .25s var(--ease), color .25s var(--ease), border-color .25s var(--ease), transform .25s var(--ease);
}
.np-item:hover .np-item__go {
  border-color: var(--c-blue);
  background: var(--c-blue);
  color: #fff;
  transform: translateX(2px);
}

/* ---------- 分页 ---------- */
.np-pager {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 1rem;
  margin-top: 1.35rem;
  padding-top: 1.35rem;
  border-top: 1px solid var(--c-line);
}
.np-pager__count { color: var(--c-text-3); font-size: .82rem; }
.np-pager__list { display: flex; flex-wrap: wrap; align-items: center; gap: .4rem; }
.np-page {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 2.35rem;
  height: 2.35rem;
  padding: 0 .65rem;
  border: 1px solid var(--c-line);
  border-radius: var(--radius);
  color: var(--c-blue-dark);
  font-size: .88rem;
  font-weight: 600;
  line-height: 1;
  font-variant-numeric: tabular-nums;
  transition: background-color .2s var(--ease), color .2s var(--ease), border-color .2s var(--ease);
}
.np-page[href]:hover { border-color: var(--c-blue); background: var(--c-blue-tint); color: var(--c-blue); }
.np-page[aria-current="page"] { border-color: var(--c-blue); background: var(--c-blue); color: #fff; }
.np-page--next { gap: .35rem; padding: 0 .8rem; }

/* ---------- 侧栏小部件 ---------- */
.np-widget {
  padding: 1.4rem 1.35rem;
  border: 1px solid var(--c-line);
  border-radius: var(--radius-lg);
  background: #fff;
  box-shadow: var(--shadow-1);
}
.np-widget__title {
  display: flex;
  align-items: center;
  gap: .5rem;
  margin-bottom: 1rem;
  color: var(--c-blue-dark);
  font-size: 1.02rem;
  font-weight: 700;
  line-height: 1.35;
}
.np-widget__title::before {
  content: "";
  flex: none;
  width: 4px;
  height: 1.1em;
  border-radius: 2px;
  background: var(--c-brand);
}

.np-tags { display: flex; flex-wrap: wrap; gap: .45rem; }
.np-tag-link {
  display: inline-block;
  padding: .35rem .78rem;
  border: 1px solid var(--c-line);
  border-radius: 999px;
  color: var(--c-text-2);
  font-size: .82rem;
  line-height: 1.4;
  transition: border-color .2s var(--ease), background-color .2s var(--ease), color .2s var(--ease);
}
.np-tag-link:hover { border-color: var(--c-brand); background: var(--c-green-tint); color: var(--c-leaf); }

.np-recent li { border-bottom: 1px solid var(--c-line); }
.np-recent li:last-child { border-bottom: 0; }
.np-recent a {
  display: grid;
  grid-template-columns: 3.1rem minmax(0, 1fr);
  align-items: start;
  gap: .65rem;
  padding: .7rem 0;
  color: var(--c-text);
  font-size: .88rem;
  line-height: 1.55;
  transition: color .2s var(--ease);
}
.np-recent li:first-child a { padding-top: 0; }
.np-recent li:last-child a { padding-bottom: 0; }
.np-recent time { color: var(--c-blue); font-size: .75rem; font-weight: 700; line-height: 1.6; font-variant-numeric: tabular-nums; }
.np-recent a:hover { color: var(--c-blue); }

.np-contact {
  position: relative;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  border-color: transparent;
  background: var(--grad-panel);
  color: #fff;
  box-shadow: var(--shadow-2);
  --c-focus: var(--c-accent);   /* 深蓝底上的键盘焦点环：橙色才看得见 */
}
.np-contact::after {
  content: "";
  position: absolute;
  right: -4.5rem;
  bottom: -5.5rem;
  width: 13rem;
  height: 13rem;
  border: 1px solid rgba(179, 225, 77, .28);
  border-radius: 50%;
  pointer-events: none;
}
.np-contact__kicker {
  position: relative;
  z-index: 1;
  margin-bottom: .35rem;
  color: var(--c-lime);
  font-size: .72rem;
  font-weight: 700;
  letter-spacing: .14em;
  text-transform: uppercase;
}
.np-contact__title { position: relative; z-index: 1; color: #fff; font-size: 1.3rem; }
.np-contact__title::before { background: var(--c-lime); }
.np-contact__text {
  position: relative;
  z-index: 1;
  margin: .55rem 0 1rem;
  color: rgba(255, 255, 255, .86);
  font-size: .87rem;
  line-height: 1.7;
}
.np-contact__list {
  position: relative;
  z-index: 1;
  display: flex;
  flex-direction: column;
  gap: .55rem;
  margin-bottom: 1.15rem;
}
.np-contact__list li {
  display: flex;
  align-items: flex-start;
  gap: .55rem;
  color: rgba(255, 255, 255, .92);
  font-size: .85rem;
  line-height: 1.55;
  overflow-wrap: anywhere;
}
.np-contact__ic { flex: none; margin-top: .12rem; color: var(--c-lime); }
.np-contact__label { display: block; color: rgba(255, 255, 255, .76); font-size: .7rem; line-height: 1.4; }
.np-contact__btn { position: relative; z-index: 1; width: 100%; }
.np-contact__hours { position: relative; z-index: 1; margin-top: .65rem; color: rgba(255, 255, 255, .72); font-size: .72rem; text-align: center; }

/* ---------- 窄屏：主栏与侧栏、页头、列表 ---------- */
@media (max-width: 1200px) {
  .np-pagehead__main { grid-template-columns: minmax(0, 1fr); gap: 1.75rem; }
  .np-stats { max-width: 40rem; }
  .np-feature { grid-template-columns: 1fr; }
  .np-feature__media { min-height: 0; aspect-ratio: 16 / 9; }
}

@media (max-width: 1023px) {
  .np-layout { grid-template-columns: minmax(0, 1fr); }
  .np-side { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .np-contact { grid-column: 1 / -1; }
}

@media (max-width: 719px) {
  .np-pagehead { padding-top: calc(var(--topbar-h) + var(--header-h) + 1.75rem); padding-bottom: 2rem; }
  .np-pagehead__title { font-size: clamp(2rem, 9vw, 2.6rem); }
  .np-pagehead__lead { font-size: .92rem; line-height: 1.75; }
  .np-pagehead__eyebrow { font-size: .72rem; letter-spacing: .12em; }
  .np-stat { padding: .72rem .6rem .68rem; }
  .np-stat strong { font-size: 1.45rem; }
  .np-stat span { font-size: .72rem; }

  .np-body { padding-top: 2rem; padding-bottom: 4rem; }
  .np-side { grid-template-columns: minmax(0, 1fr); }
  .np-feature__body { padding: 1.25rem; gap: .7rem; }
  .np-feature__title { font-size: 1.3rem; }
  .np-feature__sum { font-size: .88rem; }
  .np-feed { padding: 1.1rem; }
  .np-filters { border-radius: var(--radius-lg); }
  .np-filter { padding: .35rem .8rem; font-size: .8rem; }

  .np-item { grid-template-columns: 3.3rem minmax(0, 1fr) 1.9rem; gap: .85rem .75rem; padding: 1.1rem .35rem; }
  .np-item__go { display: inline-flex; width: 1.9rem; height: 1.9rem; }
  .np-item__go svg { width: 14px; height: 14px; }
  .np-date { padding: .45rem .15rem .4rem; }
  .np-date__day { font-size: 1.45rem; }
  .np-date__mon { font-size: .72rem; }
  .np-date__year { font-size: .58rem; }
  .np-item__title { font-size: 1rem; }
  .np-item__sum { font-size: .84rem; -webkit-line-clamp: 3; }
  .np-pager { align-items: flex-start; }
}

/* ---------- 页头、页脚、全屏菜单在窄屏下的适配（只作用于本页） ---------- */
@media (max-width: 1279px) {
  .np-list-page .nav { display: none; }
  .np-list-page .header__inner { justify-content: space-between; }
  .np-list-page .header__tools { margin-left: auto; }
}

.np-list-page .footer { --c-focus: var(--c-accent); }   /* 页脚是深蓝底：蓝色的焦点环看不见 */

@media (max-width: 900px) {
  .np-list-page .bignav__grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 2rem 1.5rem; }
  .np-list-page .footer__top { grid-template-columns: minmax(0, 1fr); }
}

@media (max-width: 860px) {
  .np-list-page .topbar__contact { display: none; }
}

@media (max-width: 760px) {
  .np-list-page .header__logo--pair > .header__logo-img:not(:last-of-type),
  .np-list-page .header__logo--pair > .header__logo-sep { display: none; }
  .np-list-page .footer__cols { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .np-list-page .footer__contact p { min-width: 0; }
  .np-list-page .footer__contact p > span:last-child { overflow-wrap: anywhere; }
}

/* ===== article page (article.html) ===== */
/* article.css — 文章内容页（article.html）新增的样式片段。
   只新增 art-* 类；颜色、字号、圆角与阴影全部取自 css/site.css 的 token，不写全局元素覆盖。
   对复制来的页头、页脚的少量窄屏适配均限定在 .art-site / .art-footer 之下，只作用于本页。
   合并方式：替换 css/site.css 中已有的 article page 片段（若有），或整段追加到末尾；随后可删除 article.html 中的同文内联块。 */

/* ---------- 页面与面包屑 ---------- */
.art-site { min-width: 0; }   /* 本站原为 PC 版（body 最小 1200px）；文章页按本页要求做窄屏适配 */
.art-main { padding: calc(var(--topbar-h) + var(--header-h) + 2.25rem) 0 4.5rem; }
.art-crumbs { max-width: 74rem; margin: 0 auto 2.25rem; color: var(--c-text-3); font-size: .875rem; }
.art-crumbs__list { display: flex; flex-wrap: wrap; align-items: center; gap: .3rem .45rem; margin: 0; padding: 0; list-style: none; }
.art-crumbs__list > li { display: flex; align-items: center; gap: .45rem; min-width: 0; }
.art-crumbs__list > li + li::before { content: "/"; color: var(--c-text-3); }
.art-crumbs__list a { display: inline-block; padding: .12rem 0; color: var(--c-text-2); transition: color .2s var(--ease); }
.art-crumbs__list a:hover { color: var(--c-blue); text-decoration: underline; text-underline-offset: 3px; }
.art-crumbs__list [aria-current="page"] { color: var(--c-blue-dark); font-weight: 600; }

/* ---------- 正文与侧栏 ---------- */
.art-layout { display: grid; grid-template-columns: minmax(0, 1fr) 20rem; gap: clamp(2rem, 4vw, 4rem); align-items: start; max-width: 74rem; margin-inline: auto; }
.art-prose { min-width: 0; }

/* 文章头 */
.art-head { position: relative; padding-top: 1.15rem; }
.art-head::before { content: ""; position: absolute; top: 0; left: 0; width: 3.5rem; height: 4px; border-radius: 999px; background: var(--c-brand); }
.art-kicker { margin: 0 0 1rem; }
.art-kicker .tag { transition: background-color .2s var(--ease), color .2s var(--ease); }
.art-kicker .tag:hover { background: var(--c-blue); color: #fff; }
.art-title { margin: 0; color: var(--c-blue-dark); font-size: clamp(1.95rem, 3.4vw, 2.9rem); font-weight: 700; line-height: 1.3; letter-spacing: .01em; }
.art-title__keep { white-space: nowrap; }
.art-lede { max-width: 46rem; margin: 1rem 0 0; color: var(--c-text-2); font-size: clamp(1.05rem, 1.35vw, 1.2rem); line-height: 1.85; }
.art-meta { display: flex; flex-wrap: wrap; align-items: center; gap: .5rem .75rem; margin: 1.4rem 0 0; padding-top: 1rem; border-top: 1px solid var(--c-line); color: var(--c-text-3); font-size: .875rem; }
.art-meta time { color: var(--c-text-2); font-variant-numeric: tabular-nums; }
.art-meta__sep { flex: none; width: 3px; height: 3px; border-radius: 50%; background: var(--c-line-strong); }

/* 头图 */
.art-figure { margin: 2.25rem 0 1.9rem; }
.art-figure img { display: block; width: 100%; height: auto; border-radius: var(--radius-lg); background: var(--c-blue-tint); box-shadow: var(--shadow-1); }
.art-figure figcaption { max-width: 70ch; margin-top: .65rem; color: var(--c-text-3); font-size: .85rem; line-height: 1.65; }

/* 正文段落、小标题、列表、引语：行宽约 70 字符 */
.art-prose > p { max-width: 70ch; margin: 0 0 1.05rem; color: var(--c-text); font-size: 1.0625rem; line-height: 1.95; text-wrap: pretty; }
.art-prose > h2 { position: relative; max-width: 70ch; margin: 2.4rem 0 .9rem; padding-left: 1rem; color: var(--c-blue-dark); font-size: 1.45rem; font-weight: 700; line-height: 1.45; }
.art-prose > h2::before { content: ""; position: absolute; top: .18em; bottom: .18em; left: 0; width: 4px; border-radius: 999px; background: var(--c-brand); }
.art-prose > .art-list { max-width: 70ch; margin: 1rem 0 1.4rem; padding: 0; list-style: none; }
.art-prose > .art-list > li { position: relative; margin: .55rem 0; padding-left: 1.35rem; color: var(--c-text); font-size: 1.0625rem; line-height: 1.85; }
.art-prose > .art-list > li::before { content: ""; position: absolute; top: .74em; left: .12rem; width: .46rem; height: .46rem; border-radius: 2px; background: var(--c-brand); }
.art-prose > .art-list strong { color: var(--c-blue-dark); }
.art-quote { max-width: 70ch; margin: 1.8rem 0; padding: 1.3rem 1.5rem 1.2rem; border-left: 4px solid var(--c-brand); border-radius: 0 var(--radius-lg) var(--radius-lg) 0; background: var(--c-green-tint); }
.art-quote p { margin: 0; color: var(--c-blue-dark); font-size: 1.1rem; font-weight: 600; line-height: 1.8; }
.art-quote footer { margin-top: .8rem; color: var(--c-text-2); font-size: .875rem; line-height: 1.6; }

/* 文章的结尾（.art-end：最后一两段正文和文末）有一张雾景图作文字的底（media/news/mist.webp）：前面的大部分正文没有底，白纸黑字；图从上边渐渐浮出来（上边是纯白，没有硬边），
   上面再盖一层淡白（.22），图最暗处的灰是 159，盖了以后深色的字压在上面仍有 6:1 的对比；图贴着底边，宽度跟正文栏一样，高度至少够看到山和湖。 */
.art-end {
  position: relative;
  margin-top: 2.25rem;
  padding: clamp(3.5rem, 8vw, 6.5rem) clamp(0rem, 2vw, 1.5rem) 1.75rem;
  min-height: clamp(21rem, 38vw, 30rem);
  border-radius: 0 0 var(--radius-lg) var(--radius-lg);
  background:
    linear-gradient(180deg, #fff 0%, rgba(255, 255, 255, .74) 12%, rgba(255, 255, 255, .22) 40%, rgba(255, 255, 255, .22) 100%),
    url("../media/news/mist.webp") center bottom / cover no-repeat;
}
.art-end > p { max-width: 70ch; margin: 0 0 1.05rem; color: var(--c-text); font-size: 1.0625rem; line-height: 1.95; text-wrap: pretty; }
.art-end .art-foot { margin-top: 1.75rem; border-top-color: rgba(0, 32, 91, .2); }
.art-end .art-pager__link { background: rgba(255, 255, 255, .86); }

/* 文末：标签、上一篇/下一篇、返回 */
.art-foot { margin-top: 2.5rem; padding-top: 1.5rem; border-top: 1px solid var(--c-line); }
.art-tags { display: flex; flex-wrap: wrap; align-items: center; gap: .55rem .7rem; }
.art-tags__label { margin: 0; color: var(--c-text-2); font-size: .875rem; font-weight: 700; }
.art-tags__list { display: flex; flex-wrap: wrap; gap: .5rem; margin: 0; padding: 0; list-style: none; }
.art-tags__list .tag { font-size: .8125rem; }
.art-pager { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1rem; margin-top: 1.8rem; }
.art-pager__link { display: flex; flex-direction: column; gap: .3rem; min-width: 0; padding: 1rem 1.15rem; border: 1px solid var(--c-line); border-radius: var(--radius); background: #fff; transition: border-color .2s var(--ease), background-color .2s var(--ease); }
.art-pager__link:hover { border-color: var(--c-blue-light); background: var(--c-blue-tint); }
.art-pager__dir { color: var(--c-text-3); font-size: .8125rem; line-height: 1.5; }
.art-pager__title { color: var(--c-blue-dark); font-size: .98rem; font-weight: 700; line-height: 1.55; }
.art-pager__link:hover .art-pager__title { color: var(--c-blue); }
.art-pager__link--next { text-align: right; }
.art-backrow { margin: 1.4rem 0 0; }
.art-back { display: inline-flex; align-items: center; gap: .45rem; color: var(--c-blue); font-size: .95rem; font-weight: 700; transition: color .2s var(--ease); }
.art-back:hover { color: var(--c-blue-dark); text-decoration: underline; text-underline-offset: 3px; }
.art-back__arrow { font-size: 1.1em; line-height: 1; }

/* 侧栏 */
.art-side { position: sticky; top: calc(var(--header-h-compact) + 1.5rem); display: grid; gap: 1.25rem; min-width: 0; }
.art-side__block { padding: 1.35rem; border: 1px solid var(--c-line); border-radius: var(--radius-lg); background: #fff; box-shadow: var(--shadow-1); }
.art-side__title { margin: 0 0 .85rem; padding-bottom: .65rem; border-bottom: 1px solid var(--c-line); color: var(--c-blue-dark); font-size: 1.05rem; font-weight: 700; }
.art-related { margin: 0; padding: 0; list-style: none; }
.art-related > li + li { border-top: 1px solid var(--c-line); }
.art-related a { display: block; padding: .7rem 0; }
.art-related > li:first-child a { padding-top: 0; }
.art-related > li:last-child a { padding-bottom: 0; }
.art-related time { display: block; color: var(--c-text-3); font-size: .78rem; line-height: 1.5; font-variant-numeric: tabular-nums; }
.art-related__title { display: block; margin-top: .15rem; color: var(--c-text); font-size: .94rem; font-weight: 600; line-height: 1.6; transition: color .2s var(--ease); }
.art-related a:hover .art-related__title, .art-related a:focus-visible .art-related__title { color: var(--c-blue); }
.art-related__all { color: var(--c-blue); font-weight: 700; }
.art-side__block--cta { border-color: var(--c-mist-line); background: linear-gradient(150deg, var(--c-green-tint) 0%, #fff 100%); }
.art-side__text { margin: 0; color: var(--c-text-2); font-size: .9rem; line-height: 1.8; }
.art-side__btn { width: 100%; margin-top: 1rem; border-color: transparent; background: var(--c-blue); color: #fff; }
.art-side__btn:hover { background: var(--c-blue-dark); color: #fff; }
.art-side__note { margin: .8rem 0 0; color: var(--c-text-3); font-size: .8rem; line-height: 1.65; }

/* ---------- 复制来的页脚：品牌块已删，补两列布局 ---------- */
.art-footer .footer__top { grid-template-columns: minmax(0, 1fr) 18rem; }

/* ---------- 窄屏：正文与侧栏 ---------- */
@media (max-width: 1023px) {
  .art-layout { grid-template-columns: minmax(0, 1fr); gap: 2.5rem; }
  .art-side { position: static; grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .art-footer .footer__top { grid-template-columns: minmax(0, 1fr); gap: 2.5rem; }
  .art-footer .footer__side { display: flex; flex-wrap: wrap; align-items: flex-start; gap: 2rem 3rem; }
  .art-footer .footer__qr { margin-top: 0; }
}

@media (max-width: 720px) {
  .art-main { padding: calc(var(--topbar-h) + var(--header-h) + 1.5rem) 0 3rem; }
  .art-crumbs { margin-bottom: 1.5rem; font-size: .82rem; }
  .art-head { padding-top: 1rem; }
  .art-title { font-size: 1.95rem; }
  .art-lede { font-size: 1.05rem; }
  .art-meta { gap: .45rem .6rem; padding-top: .8rem; font-size: .8rem; }
  .art-figure { margin: 1.6rem 0 1.5rem; }
  .art-prose > p { margin-bottom: .95rem; font-size: 1rem; line-height: 1.85; }
  .art-prose > h2 { margin-top: 1.9rem; font-size: 1.25rem; }
  .art-prose > .art-list > li { font-size: 1rem; line-height: 1.8; }
  .art-quote { padding: 1.05rem 1.15rem 1rem; }
  .art-quote p { font-size: 1.02rem; }
  .art-pager { grid-template-columns: minmax(0, 1fr); }
  .art-pager__link--next { text-align: left; }
  .art-side { grid-template-columns: minmax(0, 1fr); }
  .art-side__block { padding: 1.15rem; }
  .art-footer .footer__cols { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1.5rem 1rem; }
  .art-footer .footer__side { display: block; }
  .art-footer .footer__qr { margin-top: 1.4rem; }
  .art-footer .footer__legal { flex-wrap: wrap; gap: .4rem .8rem; }
  .art-footer .footer__legal a { margin-left: 0; }
}

@media (max-width: 480px) {
  .art-title { font-size: 1.7rem; }
  .art-figure figcaption { font-size: .8rem; }
  .art-side__block { padding: 1rem; }
}

/* ---------- 窄屏：复制来的页头（只作用于本页） ---------- */
@media (max-width: 1279px) {
  .art-site .nav { display: none; }
  .art-site .header__tools { margin-left: auto; }
}
@media (max-width: 900px) {
  .art-site .topbar__contact { display: none; }
  .art-site .bignav { overflow-y: auto; }
  .art-site .bignav__grid { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 2rem 1rem; text-align: left; }
}
@media (max-width: 719px) {
  .art-site .bignav__grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .art-site .lang__cur { display: inline; }
}
@media (max-width: 600px) {
  .art-site .header__logo--pair { --logo-h: 22px; }
}
@media (max-width: 479px) {
  .art-site .header__logo--pair { --logo-h: 26px; }
}

/* ===== column pages (tools/make-column-pages.py): cards, a table, the steps of an application, questions and answers ===== */
.pg-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(16.5rem, 1fr)); gap: 1.25rem; margin: 0; padding: 0; list-style: none; }
.pg-grid > li { display: flex; min-width: 0; }
.pg-card { display: flex; flex: 1; flex-direction: column; gap: .6rem; min-width: 0; padding: 1.5rem 1.5rem 1.3rem; border: 1px solid var(--c-line); border-radius: var(--radius-lg); background: #fff; box-shadow: var(--shadow-1); }
a.pg-card { transition: transform .3s var(--ease), box-shadow .3s var(--ease), border-color .3s var(--ease); }
a.pg-card:hover, a.pg-card:focus-visible { transform: translateY(-3px); border-color: var(--c-blue-light); box-shadow: var(--shadow-2); }
.pg-card__tag { align-self: flex-start; }
.pg-card__title { margin: 0; color: var(--c-blue-dark); font-size: 1.2rem; font-weight: 700; line-height: 1.45; }
.pg-card__text { margin: 0; color: var(--c-text-2); font-size: .95rem; line-height: 1.8; }
.pg-card__meta { margin: auto 0 0; padding-top: .75rem; border-top: 1px solid var(--c-line); color: var(--c-text-3); font-size: .85rem; }
.pg-card__go { display: flex; align-items: center; gap: .4rem; margin: auto 0 0; padding-top: .75rem; border-top: 1px solid var(--c-line); color: var(--c-blue); font-size: .9rem; font-weight: 700; }
.np-subnav a { grid-template-columns: minmax(0, 1fr); }
.np-subnav a[aria-current="page"] { color: var(--c-blue); font-weight: 700; }
.art-end > h2 { position: relative; max-width: 70ch; margin: 1.6rem 0 .9rem; padding-left: 1rem; color: var(--c-blue-dark); font-size: 1.45rem; font-weight: 700; line-height: 1.45; }
.art-end > h2::before { content: ""; position: absolute; top: .18em; bottom: .18em; left: 0; width: 4px; border-radius: 999px; background: var(--c-brand); }
.doc-table { width: 100%; max-width: 70ch; margin: 1rem 0 1.6rem; border-collapse: collapse; font-size: .98rem; line-height: 1.75; }
.doc-table th, .doc-table td { padding: .75rem 1rem; border: 1px solid var(--c-line); text-align: left; vertical-align: top; }
.doc-table th { width: 8rem; background: var(--c-blue-tint); color: var(--c-blue-dark); font-weight: 700; }
.doc-steps { counter-reset: step; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: .75rem; max-width: 70ch; margin: 1rem 0 1.6rem; padding: 0; list-style: none; }
.doc-steps > li { counter-increment: step; position: relative; padding: 2.6rem .75rem 1rem; border: 1px solid var(--c-line); border-radius: var(--radius-lg); background: #fff; color: var(--c-blue-dark); font-weight: 700; text-align: center; }
.doc-steps > li::before { content: counter(step); position: absolute; top: .8rem; left: 50%; display: grid; place-items: center; width: 1.7rem; height: 1.7rem; border-radius: 50%; background: var(--c-brand); color: var(--c-blue-dark); font-size: .9rem; transform: translateX(-50%); }
.doc-q { max-width: 70ch; border-bottom: 1px solid var(--c-line); }
.doc-q > summary { padding: 1rem .1rem; color: var(--c-blue-dark); font-weight: 700; cursor: pointer; list-style: none; }
.doc-q > summary::-webkit-details-marker { display: none; }
.doc-q > summary::after { content: "＋"; float: right; color: var(--c-text-4); font-weight: 400; }
.doc-q[open] > summary::after { content: "－"; }
.doc-q > p { margin: 0 0 1.1rem; color: var(--c-text-2); line-height: 1.85; }
.art-head + :not(.art-figure) { margin-top: 2rem; }   /* a page with no picture under the head: the text starts a little below the date line */
.art-source { margin: 1.25rem 0 0; color: var(--c-text-3); font-size: .85rem; line-height: 1.75; }
.art-source a { color: var(--c-blue); font-weight: 700; text-decoration: underline; text-underline-offset: 3px; }
@media (max-width: 720px) { .doc-steps { grid-template-columns: repeat(2, minmax(0, 1fr)); } .doc-table th { width: 6rem; } }

/* ===== responsive: tablet and phone ===== */
/* responsive.css — 追加在 css/site.css 末尾的响应式补丁（纯 @media 覆盖，不改桌面规则）。
   目的：360 / 390 / 768 / 1024 / 1280 宽下无横向滚动，导航、表单、地图、页脚可用；
   断点沿用站点的 1199 / 1023 / 899 / 719 / 479，另加触屏与减弱动效两个条件块。
   所有颜色、字体、圆角均引用站点现有 token，不新增配色。 */

/* =========================================================================
   1) 1200 以下：解除“PC only”的最小宽度；隐藏放不下的九项主导航；
      全屏菜单改成 4 列，1024 平板上一屏能看全。
   ========================================================================= */
@media (max-width: 1199px) {
  /* 顶栏与头部的实际高度略收，给首屏留出空间 */
  :root { --header-h: 88px; --header-h-compact: 72px; }

  /* 九个导航词在窄窗口必然溢出：隐藏 .nav，保留 logo、语言菜单和汉堡按钮；
     汉堡打开的全屏菜单仍然包含全部栏目 */
  .nav { display: none; }
  .header__tools { margin-left: auto; flex: none; }
  .header__inner { gap: clamp(.5rem, 1.2vw, 1.2rem); }

  /* 全屏菜单：不再用内联的 --cols:9，改 4 列并靠上排，避免字被压成一条 */
  .bignav__grid {
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 2rem 1.25rem;
    margin: 1rem 0 0;
    padding-bottom: 2.5rem;
    align-content: start;
  }
  .bignav__head { font-size: 1.15rem; }
  .bignav__links a { font-size: .95rem; }

  /* 1024–1199 仍保留桌面的四张专题卡，但把竖直标题缩小到卡片高度以内 */
  .topics__list { margin-left: 3rem; }
  .topics__title { font-size: 28px; }
  .tcard__tit { left: 18px; top: 18px; font-size: 17px; max-height: calc(100% - 40px); }
  .tcard__more { right: 18px; font-size: 12px; }
  .tcard__more::after { height: 30px; }
}

/* 1200–1319：主导航仍显示，但九项词条与三枚校徽已到极限；
   把 logo、字号和间距各收一点，避免 1200–1280 的窄桌面（含经典滚动条占位）
   把语言菜单或汉堡挤出右边。 */
@media (min-width: 1200px) and (max-width: 1319px) {
  .header__logo--pair { --logo-h: 26px; }
  .nav__list { gap: .5rem; }
  .nav__link { font-size: .94rem; }
}

/* =========================================================================
   2) 1024 以下：右侧快捷导航退场，内容栏重新居中；
      两所大学改上下排列；专题 2×2；新闻三栏依次堆叠；页脚单列。
   ========================================================================= */
@media (max-width: 1023px) {
  /* 快捷导航不再占右侧 60–96px，同时 .container 不再为它留右边距 */
  .qnav { display: none; }
  .container { --m-r: var(--m-l); }
  .hero__ctrl { right: var(--gutter); }   /* 原本多留的 3.6rem 是给快捷导航的 */
  .hero__skyline { --sky-r: var(--gutter); --sky-rv: max(3vw, (100vw - var(--container)) / 2); }   /* 内容栏右边不再为快捷导航留位置，校园线描图跟着撑到栏的右边 */

  /* ---- 项目使命：单列，两张大学卡上下排，播放按钮成为两卡之间的一行 ---- */
  .univs {
    display: flex;
    flex-direction: column;
    gap: 1.25rem;
  }
  .univs .univ {
    display: flex;               /* 覆盖 @supports 的 subgrid 网格 */
    flex-direction: column;
    padding: 1.6rem 1.5rem 1rem;
  }
  .univs .univ__items {
    display: flex;               /* 覆盖 subgrid 的 grid-template-rows */
    flex-direction: column;
    flex: 1;
  }
  .univs__join {
    display: flex;               /* 播放按钮不再独占一列 */
    align-items: center;         /* 覆盖 @supports 里 subgrid 行的 stretch */
    justify-content: center;     /* 覆盖 @supports 里 subgrid 行的 normal */
    padding: .5rem 0;
  }
  .univs__tick { display: none; } /* 中间的虚线/圆点只属于左右并排的桌面版 */
  .univs__play { width: 3.75rem; }

  /* ---- 专题：竖排标题改为横排栏头，四张卡改 2×2 ---- */
  .topics { padding: 4.5rem 0; }
  .topics__block { display: block; }
  .topics__head {
    display: flex;
    flex-direction: row;
    align-items: center;
    gap: 1rem;
    max-width: none;
  }
  .topics__title {
    writing-mode: horizontal-tb;
    font-size: 1.75rem;
    line-height: 1.3;
  }
  .topics__more {
    flex-direction: row;
    align-items: center;
    gap: .5rem;
    width: auto;
    margin: 0 0 0 auto;
    font-size: .9rem;
  }
  .topics__more-txt { writing-mode: horizontal-tb; }
  .topics__ic { width: 2.6rem; height: 2.6rem; }
  .topics__list {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 1rem;
    margin: 1.5rem 0 0;
  }
  .topics__list > li {
    min-width: 0;
    margin-left: 0;
    transition: none;
  }
  .tcard { height: 22rem; }  /* 比桌面高一些，竖直标题不被截断 */
  .tcard__tit {
    left: 1rem;
    top: 1rem;
    font-size: 1.05rem;
    max-height: calc(100% - 2.5rem);
  }
  .tcard__more { right: 1rem; font-size: .8rem; }
  .tcard__more::after { height: 2rem; margin-top: .4rem; }

  /* ---- 新闻：学院新闻 → 公示公告 → 招生动态，三块依次堆叠；
        学院新闻内部也让图片与卡片各占整行，卡片保持 2×2 ---- */
  .news {
    grid-template-columns: minmax(0, 1fr);
    grid-template-areas: "college" "notice" "admission";
    gap: 2.5rem;
  }
  .news__college {
    grid-template-columns: minmax(0, 1fr);
    gap: 1.25rem;
  }
  .photos {
    min-height: 0;
    aspect-ratio: 2.4 / 1;
  }

  /* ---- 页脚：品牌位已删除，栏目与联系方式由两列改一列 ---- */
  .footer { padding-top: 3rem; }
  .footer__top {
    grid-template-columns: minmax(0, 1fr);
    gap: 2.5rem;
    padding-bottom: 2.5rem;
  }
  .footer__side {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 2rem;
    align-items: start;
  }
  .footer__qr { margin-top: 0; justify-content: flex-end; }

  /* 1181 以下报名咨询上下堆叠（说明在上、表单卡片在下，卡片整行宽，两个字段一行） */
  .lead > * { min-width: 0; }
}

/* =========================================================================
   3) 900 以下：头部/顶栏收窄；首屏改成内容自撑高 + 2×2 拱门；
      地图标题回到文档流，避免盖住胶囊行；专业行与表单改单列。
   ========================================================================= */
@media (max-width: 899px) {
  :root { --header-h: 76px; --header-h-compact: 64px; }

  /* 顶栏右侧电话/邮箱在平板宽度先收掉，避免把左侧链接挤出去 */
  .topbar { font-size: .8125rem; }
  .topbar__contact { display: none; }
  .topbar__links { flex-wrap: wrap; row-gap: .2rem; }
  .topbar__links a { padding: 0 8px; }

  .header__inner { gap: .5rem; }
  .header__logo--pair { --logo-h: 24px; gap: .4rem; }
  .header__logo-text {
    max-width: 7rem;
    font-size: .9rem;
    line-height: 1.2;
    white-space: normal;
  }

  /* 全屏菜单改 3 列；关闭按钮与顶部行保持原高度 */
  .bignav__grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 1.75rem 1rem;
    padding-bottom: 2rem;
  }
  .bignav__head, .bignav__links a { overflow-wrap: anywhere; }

  /* ---- 首屏：100svh 保底，但内容少时不再硬撑 640px 并允许自然高度 ---- */
  .hero {
    height: auto;
    min-height: 100vh;
    min-height: 100svh;
    padding: 0;   /* .section 的 5rem 上下内边距在首屏没有意义 */
    --hero-safe-top: calc(var(--topbar-h) + var(--header-h) + .75rem);
    --hero-safe-bottom: 10.4rem;   /* 两行拱门 + 余量 */
  }
  .hero__inner { min-width: 0; }
  .hero__word { display: none; }              /* 巨大的描边单词在小屏只是噪点 */
  .hero__skyline { display: none; }           /* 校园线描图要靠右下的空地，小屏上文字占满整行，不画它 */
  .hero__ring--2, .hero__ring--3 { display: none; }
  .hero__rule { margin: 1rem 0 .9rem; }
  .hero__sub { max-width: 100%; }
  .hero__stats { gap: .6rem 1.5rem; margin-top: 1.25rem; }
  .hstat { gap: .4rem; }
  .hero__cta { flex-wrap: wrap; gap: .75rem; margin-top: 1.25rem; }

  /* 四座拱门改 2×2：不再互相叠压，也不会横向溢出 */
  .hero__links {
    left: var(--gutter);
    right: var(--gutter);
    width: auto;
    margin: 0;
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: .5rem;
  }
  .hero__links li { flex: none; margin-left: 0; }
  .hero__capsule {
    height: 4.6rem;
    padding: 0 .75rem .8rem;
  }
  .hero__capsule strong { font-size: 1rem; }
  .hero__capsule small { font-size: .78rem; line-height: 1.3; }

  /* 轮播控制放在两行拱门之上，不再被右边缘或快捷导航裁切 */
  .hero__ctrl {
    right: var(--gutter);
    bottom: 10.6rem;
    gap: .65rem;
  }

  /* ---- 项目使命：段落留白收紧 ---- */
  .mission { padding: 2.5rem 0 3rem; }

  /* ---- 地图：标题进入文档流，胶囊和地球从标题下方开始 ---- */
  .map-sec {
    --mu: clamp(44px, 9vw, 64px);
    padding: 2.5rem 0 0;
  }
  .map-sec__head {
    position: relative;
    top: auto;
    left: auto;
    right: auto;
    margin-bottom: .25rem;
  }
  .map-sec__c { padding-top: .5rem; }

  /* ---- 专业设置：名称列与层级列改上下排列，并关掉小屏上的横向漂移 ---- */
  .prog-row,
  .prog-row + .prog-row {
    grid-template-columns: minmax(0, 1fr);
    row-gap: .6rem;
    padding: 1.5rem 0;
    --drift: 0px;
  }
  .prog-row__level { font-size: .95rem; letter-spacing: .1em; }
  .prog-row__names { gap: .2rem 1.5rem; }
  .prog-name {
    font-size: clamp(1.7rem, 5.5vw, 2.6rem);
    overflow-wrap: break-word;
  }

  /* ---- 报名咨询：单列后收紧段落间距与标题字号 ---- */
  .lead { gap: 2rem; }
  .lead__heading { font-size: 1.35rem; }
  .lead__sub { margin-top: .65rem; }
  .lead__points { margin-top: 1.2rem; gap: .65rem; }
  .lead__entry-title { margin-top: 1.6rem; }
  .lead__contact { margin-top: 1.8rem; }
  .lead__entry { padding-top: 1.8rem; }

  /* ---- 各分区标题：缩小叶形底、弱化英文大字，保证不超出容器 ---- */
  .sec-title {
    min-height: 4.9rem;
    padding: .9rem 0 0 1.25rem;
  }
  .sec-title::before {
    width: 3.3rem;
    height: 2.5rem;
    top: .35rem;
  }
  .sec-title::after {
    left: 2.35rem;
    top: 2.05rem;
    font-size: clamp(1.5rem, 5.5vw, 3rem);
  }
  .sec-title__text { font-size: clamp(1.65rem, 3.4vw, 2.1rem); }
  .sec-head { align-items: center; gap: .75rem; }
  .sec-head .more { margin-top: 0; }

  /* 锚点跳转时给固定头留位置（滚动后顶栏收起，按 compact 高度算即可） */
  main section[id] { scroll-margin-top: calc(var(--header-h-compact) + 1.25rem); }
}

/* =========================================================================
   4) 720 以下：手机头部/顶栏、全屏菜单 2 列、新闻卡单列、
      页脚 2 列、浮动广告与视频弹窗缩小。
   ========================================================================= */
@media (max-width: 719px) {
  :root {
    --topbar-h: 48px;
    --header-h: 64px;
    --header-h-compact: 58px;
  }

  /* 英文/葡文页面的长单词在窄屏只断词、不撑宽容器 */
  .topbar__links a,
  .univ__name,
  .univ__en,
  .item__text,
  .lead__intent,
  .toggle,
  .news__title,
  .ncard__title,
  .ncard__sum,
  .footer a { overflow-wrap: break-word; }

  /* ---- 顶栏：只留左侧两个首页链接，字号再小一档 ---- */
  .topbar { font-size: .8rem; }
  .topbar__links { justify-content: flex-start; }
  .topbar__links a { padding: 0 7px; }

  /* ---- 头部：logo 再矮一点，语言菜单只留图标+当前语言，汉堡保持可点 ---- */
  .header__inner { gap: .4rem; }
  .header__logo--pair { --logo-h: 22px; gap: .35rem; }
  .header__logo-sep { height: calc(var(--logo-h) * .8); }
  .lang__btn { padding: .45rem .5rem; gap: .3rem; font-size: .9rem; }
  .lang__caret { display: none; }
  .header__tools { gap: .15rem; }
  .header__burger { width: 2.75rem; height: 2.75rem; }

  /* ---- 全屏菜单：2 列，允许纵向滚动；顶部行与关闭按钮保持可用 ---- */
  .bignav { padding: 0 var(--gutter) calc(2rem + env(safe-area-inset-bottom)); }
  .bignav__top { height: var(--header-h); flex: none; gap: .75rem; }
  .bignav__grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 1.5rem 1rem;
    margin: .5rem 0 0;
    padding-bottom: 1rem;
  }
  .bignav__head { margin-bottom: .35rem; font-size: 1.05rem; line-height: 1.35; }
  .bignav__links a { padding: .35rem 0; font-size: .95rem; line-height: 1.4; }
  .bignav__close { width: 2.75rem; height: 2.75rem; flex: none; }

  /* ---- 首屏：标题/统计更紧凑；控制条仍停在拱门上方 ---- */
  .hero__capsule { height: 4.4rem; }
  .hero__stripes { inset: 0 0 0 20%; opacity: .7; }
  .hero__ring--1 { display: none; }
  .hero__spark--a { right: 18%; }
  .hero__spark--b { right: 8%; }

  /* ---- 专题：2×2 保留，卡片和文字略缩 ---- */
  .topics { padding: 3.5rem 0; }
  .topics__head { gap: .75rem; }
  .topics__title { font-size: 1.5rem; }
  .topics__more { font-size: .85rem; }
  .topics__ic { width: 2.35rem; height: 2.35rem; }
  .topics__list { gap: .75rem; margin-top: 1.15rem; }
  .tcard { height: 20rem; }
  .tcard__tit { left: .8rem; top: .8rem; font-size: 1rem; }
  .tcard__more { right: .8rem; font-size: .75rem; }

  /* ---- 新闻：图片轮播与四张卡都占满整行；卡片改单列 ---- */
  .news-sec { padding: 3rem 0 4rem; }
  .news { gap: 2rem; }
  .news__college {
    grid-template-columns: minmax(0, 1fr);
    gap: 1rem;
    margin-top: .8rem;
  }
  .photos {
    min-height: 0;
    aspect-ratio: 2 / 1;
  }
  .photos__cap {
    left: 1rem;
    right: 1rem;
    bottom: 2.35rem;
    font-size: 1rem;
  }
  .photos__dots { left: 1rem; bottom: .8rem; }
  .news__cards { grid-template-columns: minmax(0, 1fr); gap: 1rem; }
  .ncard { padding: 1rem 1.1rem; }
  .ncard__title { font-size: 1.05rem; line-height: 1.45; }
  .ncard__sum { font-size: .85rem; line-height: 1.55; }
  .ncard__go { right: 1rem; top: .9rem; }
  .news__name { font-size: 1.2rem; }

  /* 长标题允许两行，不再只靠省略号 */
  .news__title {
    display: -webkit-box;
    overflow: hidden;
    white-space: normal;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
    line-height: 1.5;
  }

  /* ---- 专业设置：留白收紧，名称字号再降 ---- */
  .prog-sec { padding: 3rem 0 4rem; }
  .prog-row__names { gap: .15rem 1rem; }
  .prog-name { font-size: clamp(1.55rem, 6vw, 2.1rem); }

  /* ---- 报名咨询：手机端的卡片、按钮和状态文字 ---- */
  .lead-sec { padding: 3rem 0 4rem; }
  .lead { gap: 1.75rem; }
  .lead__heading { font-size: 1.25rem; line-height: 1.5; }
  .lead__intents { gap: .5rem; }
  .lead__intent { padding: .6rem 1rem .6rem .85rem; font-size: .95rem; }
  .pow-status { font-size: .8rem; overflow-wrap: anywhere; }

  /* ---- 页脚：栏目 2 列，联系方式与二维码上下排列，法务行可换行 ---- */
  .footer { padding-top: 2.5rem; }
  .footer__top { gap: 2rem; padding-bottom: 2rem; }
  .footer__cols {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 1.5rem 1rem;
  }
  .footer__cols li { font-size: .85rem; line-height: 1.9; overflow-wrap: break-word; }
  .footer__side { grid-template-columns: minmax(0, 1fr); gap: 1.5rem; }
  .footer__qr { justify-content: flex-start; }
  .footer__contact p { overflow-wrap: break-word; }
  .footer__legal {
    flex-direction: column;
    align-items: flex-start;
    gap: .35rem;
    padding: 1rem 0;
    font-size: .78rem;
  }
  .footer__legal p { max-width: 100%; overflow-wrap: break-word; }
  .footer__legal a { margin-left: 0; margin-right: .4rem; white-space: nowrap; }

  /* ---- 浮动广告：变窄，关闭按钮加大并保留透明热区 ---- */
  .floatad { width: min(170px, 46vw); }
  .floatad__close { right: 6px; top: 6px; width: 34px; height: 34px; }
  .floatad__close::after { content: ""; position: absolute; inset: -6px; border-radius: 50%; }

  /* ---- 视频弹窗：宽度适配，关闭按钮移入画面右上角确保可点 ---- */
  .vmodal { padding: 3.5rem 1rem 1rem; }
  .vmodal__box {
    width: min(100%, calc((100vh - 5rem) * 16 / 9));
    width: min(100%, calc((100svh - 5rem) * 16 / 9));
  }
  .vmodal__close {
    right: .5rem;
    top: .5rem;
    z-index: 2;
    background: var(--c-overlay);
  }
  .vmodal__msg { padding: 1rem; font-size: 1.15rem; }
}

/* =========================================================================
   5) 480 以下：360/390 宽的小屏；头部只留学院 logo，卡片内边距再收。
   ========================================================================= */
@media (max-width: 479px) {
  :root { --header-h: 60px; --header-h-compact: 54px; }

  /* 三枚校徽在 360 宽放不下：只保留学院自己的 logo（最后一枚），
     两个分隔线一并隐藏；语言菜单保留图标与语言名，仍在按钮里 */
  .header__logo--pair { --logo-h: 26px; gap: 0; }
  .header__logo--pair > .header__logo-img:not(:last-of-type),
  .header__logo--pair > .header__logo-sep { display: none; }

  /* 首屏：两列拱门与字块再紧凑一点 */
  .hero__capsule { height: 4.2rem; padding: 0 .55rem .7rem; }
  .hero__capsule strong { font-size: .95rem; }
  .hero__capsule small { font-size: .72rem; }
  .hero__ctrl { gap: .5rem; bottom: 10.2rem; }
  .hero__stats { gap: .5rem 1rem; }
  .hero__title { letter-spacing: -.02em; }

  /* 使命卡：字号、序号列和留白一起缩，facts 不塌行 */
  .univs { gap: .85rem; }
  .univs .univ { padding: 1.1rem .9rem .8rem; }
  .univ__name { font-size: 1.25rem; }
  .univ__en { font-size: .8rem; }
  .univ__logo { height: 2rem; }
  .item {
    grid-template-columns: 1.6rem minmax(0, 1fr);
    column-gap: .5rem;
    padding: .6rem 0;
  }
  .item__idx { font-size: .95rem; }
  .item__text { font-size: .925rem; line-height: 1.55; }
  .univs__play { width: 3.5rem; }
  .univ .nowrap { white-space: normal; }

  /* 专题：一屏两列仍然放得下，只把标题再小一点 */
  .tcard { height: 19rem; }
  .tcard__tit { font-size: .95rem; }
  .tcard__more { font-size: .7rem; }

  /* 新闻卡：手机上的内边距与字号 */
  .ncard { padding: .9rem 1rem; }
  .ncard__title { font-size: 1rem; }
  .ncard__sum { font-size: .82rem; }
  .news__row { gap: .5rem; padding: .75rem 0; }
  .news__title { font-size: 1rem; }
  .news__date { font-size: .78rem; }
  .news__name { font-size: 1.1rem; }

  /* 专业名称 */
  .prog-name { font-size: 1.5rem; }
  .prog-row__level { font-size: .9rem; }

  /* 表单：卡片内边距从 1.25rem 再降一档，ToggleGroup 不挤 */
  .lead__form { --card-spacing: 1rem; }
  .card__header { padding-top: 1.3rem; }
  .card__title { font-size: 1.45rem; }
  .card__content { padding-top: 1.1rem; padding-bottom: 1.3rem; }
  .card__footer { padding-top: 1.15rem; padding-bottom: 1.3rem; }
  .field-group { gap: .95rem 1rem; }
  .toggle-group { gap: .4rem; }
  .toggle { padding: .45rem .7rem; }
  .lead__heading { font-size: 1.15rem; }
  .lead__intent { padding: .55rem .85rem .55rem .75rem; font-size: .9rem; }

  /* 页脚：列距、二维码和法务字号 */
  .footer__cols { gap: 1.25rem .75rem; }
  .footer__qrimg { width: 104px; height: 104px; }
  .footer__legal { font-size: .75rem; }

  /* 浮动广告再窄一点 */
  .floatad { width: min(150px, 42vw); }
}

/* =========================================================================
   6) 触屏：关闭依赖 :hover 的位移、变宽、暂停与缩放；
      键盘 :focus-visible 的样式全部保留（这里只覆盖 :hover 分支）。
      同时把关键控件补到约 44px 的触控目标。
   ========================================================================= */
@media (hover: none) {
  /* 触屏没有 hover 可以暂停漂移，移动中的关闭按钮很难点：
     让小广告离开固定层，作为页面末尾的一张普通卡片（关闭后移除）。
     这样它不会覆盖导航、表单或正文，宽度仍按上面的手机档位缩小。 */
  .floatad {
    position: static;
    margin: 1.5rem auto;
    transform: none !important;
  }

  .btn,
  .toggle,
  .input,
  .select,
  .lang__btn,
  .header__burger,
  .hero__toggle,
  .bignav__close,
  .vmodal__close,
  .lead__intent,
  .topics__more,
  .qnav__top,
  .qnav__fold,
  .floatad__close { min-height: 44px; }

  .header__burger,
  .hero__toggle,
  .bignav__close,
  .vmodal__close { min-width: 44px; min-height: 44px; }
  .floatad__close { width: 40px; height: 40px; }

  .lang__menu a { display: flex; align-items: center; min-height: 44px; }
  .more { min-height: 44px; }

  /* 专题卡不再因手指停留而变宽；站点原有的 :has(.tcard:focus-visible)
     选择器权重更高，键盘 focus 的变宽仍然生效 */
  .topics__list > li:hover { flex-grow: 1; }

  /* 位移/缩放类 hover 全部归零 */
  .btn:hover,
  .card:hover,
  .ncard:hover,
  .hero__capsule:hover,
  .bignav__close:hover,
  .univs__play:hover,
  .floatad__link:hover .floatad__pic img,
  .floatad__link:hover .floatad__pic svg,
  .more:hover .more__dot,
  .news__row:hover .news__title { transform: none; }

  .ncard:hover { box-shadow: var(--shadow-1); }
  .card:hover::after { opacity: 0; }

  /* 地图胶囊行不再被点按后的 :hover 停住 */
  .pmap__row:hover .pmap__list { animation-play-state: running; }

  /* 轮播圆点扩大透明热区；视觉尺寸基本不变，间距同步拉开避免热区重叠 */
  .hero__dot, .photos__dot { position: relative; }
  .hero__dots { gap: 2rem; }
  .hero__dot::after {
    content: "";
    position: absolute;
    inset: -1rem;
    border-radius: 50%;
  }
  .photos__dots { gap: 2rem; }
  .photos__dot::after {
    content: "";
    position: absolute;
    inset: -1rem;
    border-radius: 50%;
  }

  /* 触屏上让全屏菜单的链接行高更舒展，减少误点 */
  .bignav__links a { padding-block: .45rem; }
}

/* =========================================================================
   7) 减弱动效：站内已有全局 animation/transition 关闭规则；
      这里仅确认浮动广告与首屏背景不再被脚本/样式推动。
   ========================================================================= */
@media (prefers-reduced-motion: reduce) {
  .floatad { will-change: auto; }
  .hero__bg { transform: none; }
  .pmap__win { overflow-x: auto; -webkit-overflow-scrolling: touch; }
}

/* ===== audit fixes: forced colours, landscape phones, iOS zoom, overlay order, touch targets, legacy JSP cards ===== */
/* audit-fixes.css — 兼容性审计后的补丁，追加在 site.css 最末尾（最后覆盖）。
   解决：强制配色下渐变字不可见、横屏手机首屏文字压住头部/拱门、iOS 表单聚焦放大、
   浮动广告盖住头部控件、触屏目标过小、1200–1219 头部 4px 裁切、移动端服务入口（页脚补齐）。 */

@media (forced-colors: active) {
  .input:focus-visible, .textarea:focus-visible, .select:focus-visible, .toggle:focus-visible, .checkbox:focus-visible, .input-group:focus-within { outline: 2px solid Highlight; outline-offset: 2px; }
  .toggle[aria-checked="true"], .toggle[aria-pressed="true"], .lead__intent[aria-pressed="true"] { forced-color-adjust: none; background: Highlight; color: HighlightText; border-color: Highlight; }
  .checkbox:checked { forced-color-adjust: none; background-color: Highlight; border-color: Highlight; }
  .hero__title, .hero__sub, .hstat__num, .hstat__label {
    background: none !important;
    -webkit-text-fill-color: currentColor !important;
    color: CanvasText !important;
    filter: none !important;
  }
}

/* 横屏手机 / 200% 缩放：短高度下给首屏一个下限，文字不再压到头和拱门 */
@media (max-width: 899px) {
  .hero {
    min-height: 35rem;
    min-height: max(100svh, 35rem);
  }
}

@media (max-width: 719px) {
  /* iOS Safari 在输入框字号小于 16px 时会在聚焦瞬间放大页面 */
  .input, .textarea, .select { font-size: 16px; }
  /* 全屏菜单内容比屏幕高时，关闭按钮留在顶部 */
  .bignav__top { position: sticky; top: 0; z-index: 2; background: var(--grad-panel); }
}

@media (max-width: 959px) {
  /* 葡语联系方式在 900 附近会被裁；提前隐藏，页脚仍有完整联系方式 */
  .topbar__contact { display: none; }
}

/* 广告在头部、顶栏、快捷栏之下：它仍可漂移，但不会盖住 logo / 语言 / 汉堡 / 服务栏 */
.floatad { z-index: 700; }

@media (hover: none) {
  .np-stat:hover, .np-feature:hover, .np-item:hover { transform: none; }
  .np-filter, .np-page, .np-tag-link { min-height: 44px; }
  .topbar__links a, .footer__cols a, .footer__legal a, .footer__services a { display: inline-flex; align-items: center; min-height: 44px; }
}


/* 快捷栏在 <=1023 隐藏后，五个校内服务入口由页脚补齐；桌面端仍用右侧快捷栏，不重复 */
.footer__services { display: none; }
@media (max-width: 1023px) {
  .footer__services { display: block; margin-top: 1.4rem; }
  .footer__services h3 { margin-bottom: .6rem; color: #fff; font-size: 1rem; }
  .footer__services ul { display: flex; flex-wrap: wrap; gap: .35rem 1rem; }
  .footer__services a { color: rgba(255, 255, 255, .86); font-size: .875rem; line-height: 1.6; text-decoration: underline; text-underline-offset: 3px; }
  .footer__services a:hover { color: var(--c-lime); }
}

/* legacy index.jsp 的旧专业卡片（.prog/.pcard）：当前 site.css 没有对应规则，补上以免在 360/768 溢出 */
.prog { display: grid; grid-template-columns: repeat(auto-fit, minmax(16rem, 1fr)); gap: 1.5rem; }
.pcard { display: flex; flex-direction: column; min-width: 0; }
.pcard__art { display: block; }
.pcard__art svg, .pcard__art img { max-width: 100%; height: auto; }
@media (max-width: 719px) { .prog { grid-template-columns: 1fr; } }

/* ===== print =====
   On paper a page is its words and its pictures: the fixed bars (the utility bar, the header, the quick links, the moving ad, the full-screen menu, the video box), the lights and lines drawn behind the
   first screen and every button are left off, nothing is waiting for a scroll or an animation to appear, the first slide is the hero, and the address of a link in an article is written after it. */
@media print {
  @page { margin: 14mm 12mm; }
  html { font-size: 11.5pt; scroll-behavior: auto; }
  body { background: #fff; color: #000; animation: none; }
  .skip-link, .topbar, .header, .qnav, .floatad, .bignav, .vmodal, .lang, .hero__bg, .hero__skyline, .hero__ctrl, .hero__links, .univs__play, .lead__intents, .lead-sec, .topics__more, .pmap { display: none !important; }
  *, *::before, *::after { animation: none !important; transition: none !important; box-shadow: none !important; text-shadow: none !important; }
  [data-reveal] { opacity: 1 !important; transform: none !important; }
  .hero { height: auto !important; min-height: 0 !important; padding: 0 !important; overflow: visible !important; }
  .hero__slides { position: static !important; }
  .hero__slide { position: static !important; opacity: 1 !important; visibility: visible !important; transform: none !important; padding: 0 0 1rem !important; }
  .hero__slide:not(.is-active) { display: none !important; }
  .section { padding-top: 1.2rem !important; padding-bottom: 1.2rem !important; }
  a { color: inherit; text-decoration: underline; }
  .art-body a[href^="http"]::after { content: " (" attr(href) ")"; font-size: .85em; overflow-wrap: anywhere; }
  img, svg, figure, blockquote, tr, .card, .ncard, .pg-card { break-inside: avoid; }
  h1, h2, h3, h4 { break-after: avoid; }
}
