/* ORIS — KCST. Black, white, and the brand red of the KCST branding sheet. Hierarchy still
   comes from weight, rule and pattern; the red marks the institution and never carries a
   status. */
@font-face{font-family:"Plex";src:url(fonts/ibm-plex-sans-arabic-arabic-400-normal.woff2) format("woff2");font-weight:400;font-display:swap;unicode-range:U+0600-06FF,U+0750-077F,U+0870-08FF,U+200C-200E,U+2010-2011,U+FB50-FDFF,U+FE70-FEFC}
@font-face{font-family:"Plex";src:url(fonts/ibm-plex-sans-arabic-arabic-600-normal.woff2) format("woff2");font-weight:600;font-display:swap;unicode-range:U+0600-06FF,U+0750-077F,U+0870-08FF,U+200C-200E,U+2010-2011,U+FB50-FDFF,U+FE70-FEFC}
@font-face{font-family:"Plex";src:url(fonts/ibm-plex-sans-arabic-arabic-700-normal.woff2) format("woff2");font-weight:700;font-display:swap;unicode-range:U+0600-06FF,U+0750-077F,U+0870-08FF,U+200C-200E,U+2010-2011,U+FB50-FDFF,U+FE70-FEFC}
@font-face{font-family:"Plex";src:url(fonts/ibm-plex-sans-arabic-latin-400-normal.woff2) format("woff2");font-weight:400;font-display:swap;unicode-range:U+0000-00FF,U+0131,U+0152-0153,U+2000-206F,U+20AC,U+2122,U+2212}
@font-face{font-family:"Plex";src:url(fonts/ibm-plex-sans-arabic-latin-600-normal.woff2) format("woff2");font-weight:600;font-display:swap;unicode-range:U+0000-00FF,U+0131,U+0152-0153,U+2000-206F,U+20AC,U+2122,U+2212}
@font-face{font-family:"Plex";src:url(fonts/ibm-plex-sans-arabic-latin-700-normal.woff2) format("woff2");font-weight:700;font-display:swap;unicode-range:U+0000-00FF,U+0131,U+0152-0153,U+2000-206F,U+20AC,U+2122,U+2212}
@font-face{font-family:"Amiri";src:url(fonts/amiri-arabic-400-normal.woff2) format("woff2");font-weight:400;font-display:swap;unicode-range:U+0600-06FF,U+0750-077F,U+0870-08FF,U+200C-200E,U+2010-2011,U+FB50-FDFF,U+FE70-FEFC}
@font-face{font-family:"Amiri";src:url(fonts/amiri-arabic-700-normal.woff2) format("woff2");font-weight:700;font-display:swap;unicode-range:U+0600-06FF,U+0750-077F,U+0870-08FF,U+200C-200E,U+2010-2011,U+FB50-FDFF,U+FE70-FEFC}
@font-face{font-family:"Amiri";src:url(fonts/amiri-latin-400-normal.woff2) format("woff2");font-weight:400;font-display:swap;unicode-range:U+0000-00FF,U+0131,U+0152-0153,U+2000-206F,U+20AC,U+2122,U+2212}
@font-face{font-family:"Amiri";src:url(fonts/amiri-latin-700-normal.woff2) format("woff2");font-weight:700;font-display:swap;unicode-range:U+0000-00FF,U+0131,U+0152-0153,U+2000-206F,U+20AC,U+2122,U+2212}

/* ORIS — KCST. Black, white, and the brand red. Hierarchy from weight, shape and pattern. */
:root{
  /* ── KCST, and only KCST ────────────────────────────────────────────────────────────────────
     The branding sheet gives two colours and the black and white its logo is drawn in. This
     file used to hold fifty-one. Everything below is one of the two, a shade of one of the two,
     or ink and paper.

         #a93c2f   icon and line        6.22:1 on white — carries body text
         #5d5e5e   text                 6.51:1 on white — carries body text

     Both are stronger than the gold they replace, where white-on-gold measured 4.03:1 and the
     accent had to be kept away from running text. This one has no such restriction. */

  /* Ink and paper. A document is black on white here and stays that way: the minute, the
     certificate and the report are printed things, and a printed official document set in grey
     reads as a draft or a bad photocopy. */
  --ink:#000; --paper:#fff;
  --hair:1px solid #000; --rule:2px solid #000; --heavy:4px solid #000;

  /* The brand mark. It draws icons and lines, as the sheet says — the rule under a page title,
     the block beside a heading, the edge of a control. It never carries a status: a status is
     still a word plus the form of its stamp, so the page reads the same to somebody who cannot
     separate red from grey, and the same again on a monochrome printer. */
  --brand:#a93c2f;
  /* The edge and the pressed state, the same hue darkened rather than a second colour, so a
     button reads as one thing and not as an outline filled in. 8.46:1 on white, dark enough to
     hold its shape when the page is printed in grey. */
  --brand-line:#873026;
  /* White on the brand measures 6.22:1, so unlike the old gold it may carry a label of any
     size. */
  --brand-ink:#fff;
  /* A wash of the brand, for the one row or cell that is being pointed at. Black on it is far
     clear of 4.5:1. */
  --brand-wash:#f7ecea;

  /* The text colour from the sheet, and the greys that fall out of it. --g1 is a wash behind
     table headers and panel tops, --g2 a hairline, --g3 the colour of secondary text — which is
     the sheet's #5d5e5e itself, at 6.51:1. */
  --text:#5d5e5e;
  --g1:#f2f2f2; --g2:#dfdfdf; --g3:#5d5e5e; --g4:#8a8a8a;

  /* The dark lockup from the guideline sheet. The mark on it is WHITE — the brand red measures
     2.80:1 against this and must never be text or an icon here. */
  --panel:#1a1a1a; --panel-ink:#fff;

  --hatch:repeating-linear-gradient(135deg,#000 0 1.5px,#fff 1.5px 5px);
  --ui:"Plex","Segoe UI",Tahoma,sans-serif;--doc:"Amiri","Traditional Arabic","Times New Roman",serif;
  --r:14px;--r-s:10px;--s1:.25rem;--s2:.5rem;--s3:.75rem;--s4:1rem;--s5:1.5rem;--s6:2.25rem;--s7:3.5rem;--side:17rem;--top:4.25rem}
*,*::before,*::after{box-sizing:border-box}
html{font-size:100%;-webkit-text-size-adjust:100%;scroll-padding-top:5rem}
body{margin:0;background:#fff;color:#000;font-family:var(--ui);font-size:1rem;line-height:1.75;-webkit-font-smoothing:antialiased}
h1,h2,h3{font-family:var(--doc);font-weight:700;line-height:1.35;margin:0 0 var(--s3)}
h1{font-size:clamp(1.7rem,1.3rem + 1.6vw,2.4rem)}h2{font-size:1.45rem}h3{font-size:1.2rem}
p{margin:0 0 var(--s3)}
a{color:#000;text-decoration:underline;text-underline-offset:.22em;text-decoration-thickness:1px}
a:hover{text-decoration-thickness:2.5px}
:focus-visible{outline:3px solid #000;outline-offset:3px;border-radius:4px}
.sr-only{position:absolute;inline-size:1px;block-size:1px;margin:-1px;padding:0;overflow:hidden;clip-path:inset(50%);white-space:nowrap;border:0}
.skip{position:absolute;inset-inline-start:var(--s2);inset-block-start:-6rem;background:#000;color:#fff;padding:var(--s2) var(--s4);z-index:99;border-radius:var(--r-s)}
.skip:focus{inset-block-start:var(--s2)}
[hidden]{display:none!important}
.ic{inline-size:1.35rem;block-size:1.35rem;flex:none;vertical-align:-.3em}

/* ================= top bar ================= */
.top{position:sticky;inset-block-start:0;z-index:30;display:flex;align-items:center;gap:var(--s3);min-block-size:var(--top);padding:var(--s2) var(--s4);background:#fff;border-block-end:var(--hair)}
.brand{display:flex;align-items:center;gap:var(--s3);text-decoration:none;min-inline-size:0;flex:0 1 auto}
.brand img{block-size:auto;inline-size:min(46vw,15rem);display:block}
@media(max-width:30rem){.brand .mark{display:none}}
.brand .mark{font-family:var(--doc);font-weight:700;font-size:1.45rem;line-height:1;padding:.42rem .6rem .2rem;background:var(--brand);color:#fff;border-radius:8px;letter-spacing:.04em}
.search{display:none;flex:1 1 16rem;max-inline-size:34rem;margin-inline:auto;position:relative}
/* text-overflow matters here: the button sits over the inline-end of the box, and without it
   a long value scrolls under the button instead of stopping short of it. */
.search input{padding-inline-end:3.2rem;border-radius:999px!important;background:#fff;text-overflow:ellipsis}
.search button{position:absolute;inset-inline-end:.3rem;inset-block-start:50%;transform:translateY(-50%);inline-size:2.5rem;block-size:2.5rem;border:0;border-radius:50%;background:#000;color:#fff;display:grid;place-items:center;cursor:pointer}
.tools{display:flex;align-items:center;gap:var(--s2);margin-inline-start:auto}
.tool{position:relative;display:inline-flex;align-items:center;justify-content:center;gap:var(--s2);min-inline-size:44px;min-block-size:44px;padding:0 .5rem;border:0;border-radius:999px;background:transparent;color:#000;text-decoration:none;cursor:pointer;font-weight:600}
.tool:hover{background:#000;color:#fff}
.tool .count{position:absolute;inset-block-start:-2px;inset-inline-end:-6px;min-inline-size:1.25rem;block-size:1.25rem;padding:0 .3rem;border-radius:999px;background:#000;color:#fff;font-size:.72rem;font-weight:700;line-height:1.25rem;text-align:center;box-shadow:0 0 0 2px #fff}
/* The signed-in person: face then name, on one line. It is a link to their own profile, so it
   is underlined only on hover — a permanent rule through the top bar reads as a mistake. */
.me{display:inline-flex;align-items:center;gap:var(--s2);font-size:.82rem;line-height:1.35;padding-inline:var(--s2);max-inline-size:16rem;text-decoration:none;color:#000}
.me:hover b{text-decoration:underline;text-underline-offset:.22em}
.me b{font-size:.92rem;font-weight:700;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.avatar.sm{inline-size:2.3rem;block-size:2.3rem;border-width:1.5px}
.avatar.sm.initials{font-size:1.1rem;padding-block-start:.1rem}
.wide-only{display:none!important}

/* ================= shell, side navigation ================= */
.shell{display:block}
.side{display:none;position:fixed;inset:0;z-index:50;background:#fff;overflow-y:auto;padding:var(--s3) var(--s4) 6rem}
.navt:checked~.shell .side{display:block}
.navt:focus-visible~.tabbar label{outline:3px solid #fff;outline-offset:-6px}
.side-head{display:flex;align-items:center;justify-content:space-between;gap:var(--s3);padding-block-end:var(--s3);border-block-end:var(--hair);margin-block-end:var(--s3)}
.side-head .me{max-inline-size:none;padding:0}
/* Each group is a collapse, and only one stands open: the one holding the page you are on.
   Shape says which — outlined when shut, solid when open — so the state never rests on colour. */
.side .group{margin-block:var(--s2)}
.side .group>summary{display:flex;align-items:center;gap:var(--s2);margin:0;min-block-size:42px;padding:.4rem var(--s3);border-radius:var(--r-s);box-shadow:inset 0 0 0 1.5px #000;font-size:.8rem;font-weight:700;cursor:pointer}
.side .group>summary>span{flex:1 1 auto}
.side .group>summary .ic{inline-size:1.1rem;block-size:1.1rem;transform:rotate(-90deg)}
[dir=rtl] .side .group>summary .ic{transform:rotate(90deg)}
.side .group>summary:hover{background:#000;color:#fff}
.side .group[open]>summary{background:#000;color:#fff;box-shadow:none}
.side .group[open]>summary .ic,[dir=rtl] .side .group[open]>summary .ic{transform:rotate(0)}
.side .group>ul{margin:var(--s1) 0 var(--s2);padding-inline-start:var(--s2);margin-inline-start:var(--s3);border-inline-start:var(--rule)}
.side ul{list-style:none;margin:0;padding:0}
.side li a{display:flex;align-items:center;gap:var(--s3);min-block-size:46px;padding:.35rem var(--s3);border-radius:var(--r-s);text-decoration:none;font-weight:600;font-size:.96rem}
.side li a:hover{box-shadow:inset 0 0 0 1.5px #000}
.side li a[aria-current=page]{background:#000;color:#fff}
.side-foot{display:flex;flex-wrap:wrap;gap:var(--s2);margin-block-start:var(--s5);padding-block-start:var(--s4);border-block-start:var(--hair)}
main{padding:var(--s4) var(--s4) 7rem;min-inline-size:0}
.foot{margin-block-start:var(--s7);padding-block-start:var(--s3);border-block-start:var(--hair);font-size:.82rem}

/* mobile tab bar */
.tabbar{position:fixed;inset-inline:0;inset-block-end:0;z-index:60;display:grid;grid-template-columns:repeat(5,1fr);background:#000;color:#fff;padding-block-end:env(safe-area-inset-bottom,0)}
.tabbar a,.tabbar label{display:flex;flex-direction:column;align-items:center;justify-content:center;gap:.1rem;min-block-size:58px;padding:.3rem .2rem;color:#fff;text-decoration:none;font-size:.68rem;font-weight:600;line-height:1.3;text-align:center;cursor:pointer}
.tabbar span{max-inline-size:100%;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.tabbar a[aria-current=page]{background:#fff;color:#000;border-radius:12px;margin:.3rem .2rem;min-block-size:50px}
.search.in-main{display:flex}

@media(min-width:48rem){.top .search{display:flex}.brand img{inline-size:auto;block-size:2.2rem}}
.side .search{display:flex;max-inline-size:none;margin:0 0 var(--s3)}
@media(min-width:68rem){
  /* inline-flex suits all of them now: the signed-in person is a face beside a name, not a
     stacked block, so the span.me override that used to force `block` here has gone. */
  .wide-only{display:inline-flex!important}
  .tabbar,.side-head,.side-foot{display:none}
  .shell{display:grid;grid-template-columns:var(--side) minmax(0,1fr);align-items:start}
  .side{display:block;position:sticky;inset:auto;inset-block-start:var(--top);z-index:1;block-size:calc(100vh - var(--top));padding:var(--s3) var(--s3) var(--s5);border-inline-end:var(--hair)}
  .side li a{min-block-size:42px;font-size:.93rem}
  main{padding:var(--s6) clamp(1.5rem,3vw,3rem) var(--s6);max-inline-size:86rem}
  /* Search belongs at the head of the menu. While the menu is there, the top bar does not repeat it. */
  body:not(.nav-off) .top .search{display:none}
  /* Menu hidden: the page takes the whole width and the toggle in the top bar brings it back. */
  body.nav-off .side{display:none!important}
  body.nav-off .shell{grid-template-columns:minmax(0,1fr)}
}

/* ================= page head ================= */
.pagehead{display:flex;flex-wrap:wrap;align-items:end;justify-content:space-between;gap:var(--s3) var(--s5);margin-block-end:var(--s5);padding-block-end:var(--s4);border-block-end:var(--hair);position:relative}
.pagehead::after{content:"";position:absolute;inset-inline-start:0;inset-block-end:-3px;inline-size:4.5rem;border-block-end:5px solid var(--brand);border-radius:3px}
.pagehead h1{margin:0}
.pagehead p{margin:.15rem 0 0;font-size:.95rem;max-inline-size:60ch}
.actions{display:flex;flex-wrap:wrap;gap:var(--s2);align-items:center}
section{margin-block-end:var(--s6)}
section>h2{display:flex;align-items:center;gap:var(--s3);margin-block-end:var(--s4)}
section>h2::before{content:"";inline-size:.6rem;block-size:1.5rem;background:var(--brand);border-radius:3px;flex:none}
.lede{max-inline-size:70ch}
.cols{display:grid;gap:var(--s4)}
@media(min-width:52rem){.cols{grid-template-columns:repeat(2,minmax(0,1fr));gap:var(--s5)}.cols.three{grid-template-columns:repeat(3,minmax(0,1fr))}}
.panel{border:var(--hair);border-radius:var(--r);padding:var(--s4) var(--s4) var(--s3);background:#fff;margin-block-end:var(--s4)}
.cols>.panel,.cols>section{margin-block-end:0}
.panel>h2,.panel>h3{display:block;font-size:1.22rem;margin:0 0 var(--s3);padding-block-end:var(--s2);border-block-end:var(--hair)}
.panel>h2::before{content:none}
.panel.heavy{border:var(--rule);box-shadow:6px 6px 0 #000}
[dir=rtl] .panel.heavy{box-shadow:-6px 6px 0 #000}
.note{border-inline-start:5px solid #000;border-radius:3px;padding:var(--s2) var(--s4);margin-block-end:var(--s4)}
.empty{font-style:italic;padding:var(--s2) 0}
details>summary{list-style:none;cursor:pointer;margin-block:var(--s2)}
details>summary::-webkit-details-marker{display:none}
details[open]>summary{background:#000;color:#fff}

/* ================= dashboard hero ================= */
.hero{position:relative;overflow:hidden;display:grid;gap:var(--s5);background:#000;color:#fff;border-radius:calc(var(--r) + 6px);padding:var(--s5);margin-block-end:var(--s5)}
/* The circuit behind the hero, mirrored.
   It used to be pinned to the side the card now sits on, so the lines ran behind the badge and
   out from under it — the one place on this panel where something is meant to be read. Moving
   it to the other side is not enough on its own: a drawing anchored to the opposite edge has to
   be flipped as well, or it runs off the panel instead of into it. So both, which together are
   a true mirror — what was on the left is on the right and what was on the right is on the left.
   The sign-in panel keeps its own orientation; only the hero turns over. */
.hero .motif{position:absolute;inset-block:0;inset-inline-start:0;inset-inline-end:auto;
  inline-size:min(100%,36rem);block-size:100%;pointer-events:none;transform:scaleX(-1);
  /* A background at full strength is not a background. These are white lines on black and the
     greeting is white letters on black, so at full strength the two were the same drawing and
     the name had to be picked out of it. At a quarter they mark the panel and leave the words
     alone — which is the whole job of the thing. */
  opacity:.22}
[dir=rtl] .hero .motif{transform:none}
[dir=rtl] .gate-brand .motif{transform:scaleX(-1)}
@media(max-width:60rem){.hero .motif{display:none}}
.hero-id,.hero-figs{position:relative;z-index:2}
.hero h1{color:#fff;font-size:clamp(2rem,1.4rem + 2.6vw,3.1rem);margin:0 0 var(--s1)}
.hero .greet{margin:0;font-size:.95rem}
.hero p{margin:0 0 var(--s4)}
/* The name and the rank lead to the card and the CV. They keep the heading's weight and colour --
   the underline arrives on hover or focus, so the hero still reads as a greeting and not as a row
   of links. The focus ring is the brand red: on black it measures 3.37:1, which clears the 3:1
   a focus indicator needs — but only just, so it stays 3px and never lands on anything
   lighter than black. */
.hero-link{color:inherit;text-decoration:none;text-underline-offset:.22em}
.hero-link:hover,.hero-link:focus-visible{text-decoration:underline;text-decoration-thickness:2px}
.hero-link:focus-visible{outline:3px solid var(--brand);outline-offset:3px;border-radius:4px}
.hero-figs{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:var(--s2);margin:0}
.hero-figs div{border:1.5px solid #fff;border-radius:var(--r);background:#000}
/* The whole box is the link, not the number inside it: a target the size of a word is a target
   people miss, and these are read at a glance and pressed without looking. The red arrow says
   it opens; on hover the box fills with the red and inverts, which is the one state change on
   this panel and so needs no second signal. */
.hero-figs a{display:block;position:relative;padding:var(--s3);color:inherit;text-decoration:none;border-radius:calc(var(--r) - 2px)}
.hero-figs a:hover,.hero-figs a:focus-visible{background:var(--brand);color:var(--brand-ink)}
.hero-figs a:focus-visible{outline:3px solid #fff;outline-offset:2px}
.hero-figs .go{position:absolute;inset-block-start:var(--s3);inset-inline-end:var(--s3);color:var(--brand);line-height:0}
.hero-figs .go svg{inline-size:16px;block-size:16px;transform:rotate(-90deg)}
[dir=rtl] .hero-figs .go svg{transform:rotate(90deg)}
.hero-figs a:hover .go,.hero-figs a:focus-visible .go{color:var(--brand-ink)}
.hero-figs dt{font-size:.82rem;line-height:1.4;padding-inline-end:1.4rem}
.hero-figs dd{margin:0;font-family:var(--doc);font-weight:700;font-size:2.4rem;line-height:1.15}
/* The badge sits in the hero at its true size — 85.6mm is the ID-1 card format, and a card
   shown smaller than a card stops reading as one. It keeps its own white background against the
   black, which is what makes it look like something you could pick up. */
.hero-card{position:relative;z-index:1;display:flex;flex-direction:column;align-items:center;gap:var(--s2)}
/* The card is a white object with black text. Saying so here as well as on .idcard means the
   hero's white text can never leak into it again, whatever is added to the hero later. */
.hero-card .idcard{margin:0;color:#000;background:#fff;box-shadow:0 2px 14px rgba(0,0,0,.45)}
.hero-card .idcard b,.hero-card .idcard span,.hero-card .idcard small{color:#000}
.hero-card .idcard em{color:var(--brand-ink)}
/* The whole badge opens البطاقة والهوية, by way of a link lying over it rather than wrapped
   around it — the QR inside is already a link, and a link inside a link is invalid and is
   unpicked differently by different browsers. The code is raised above the cover, so scanning
   or pressing it still does what it has always done. The badge lifts on hover to read as
   something you can press, and the focus ring is the brand red: on this black panel it is the
   only colour that shows, at 3.37:1 — past the 3:1 a focus indicator needs, and no further. */
/* Why pointer-events and not a z-index.
   The cover lies over the card, and the QR inside the card was raised above the cover with a
   z-index so it could still be pressed. That worked until the card learned to lift on hover:
   a `transform` makes an element a stacking context, so the moment the cover was hovered the
   card became one, and the QR's z-index was trapped inside it. The card as a whole paints below
   the cover, so the QR went under it — and the code stopped taking the mouse at exactly the
   moment somebody moved towards it.
   Stacking cannot fix this, because the lift is what breaks it. Hit-testing can: the card
   ignores the mouse and lets it through to the cover beneath, and the QR alone takes it back.
   The card is a picture; the code and the cover are the two things you can press. */
/* The cover goes BEHIND the card, not in front of it.
   Two attempts failed before this one, and both failed the same way: anything painted over the
   card is also painted over the QR, and the QR is a link of its own. Raising the code with a
   z-index worked until the card learned to lift — a transform makes a stacking context and the
   code was trapped inside it. Making the card ignore the mouse was not enough either, because
   the cover was still the topmost thing at that point and took the event regardless.
   So the cover is underneath, and the card is transparent to the mouse: a press anywhere on the
   badge falls through the card and lands on the cover below, opening البطاقة والهوية. The code
   alone takes its own events back, and being inside the card it is above the cover, so it is hit
   first. Nothing has to escape a stacking context, so the lift cannot break it again. */
.card-cover{position:absolute;inset:0;z-index:0;border-radius:3.2mm}
.hero-card .idcard{position:relative;z-index:1;pointer-events:none;
  transition:transform .15s ease,box-shadow .15s ease}
.hero-card .qr-link{pointer-events:auto}
.hero-card:has(.card-cover:hover) .idcard,.hero-card:has(.card-cover:focus-visible) .idcard{
  transform:translateY(-2px);box-shadow:0 6px 20px rgba(0,0,0,.6)}
.card-cover:focus-visible{outline:3px solid var(--brand);outline-offset:4px}
@media(prefers-reduced-motion:reduce){
  .hero-card .idcard{transition:none}
  .hero-card:has(.card-cover:hover) .idcard{transform:none}}
/* Two columns: the greeting and the card side by side, with the four counts across the foot.
   `order` puts the card beside the greeting and the figures underneath — and it is bounded at
   the top, because a rule written only with min-width goes on applying in every wider layout.
   It did: the three-column rule below was placing the card in the middle column however the
   columns were named, because this `order` was still deciding what went where. */
@media(min-width:60rem) and (max-width:85.999rem){
  .hero{grid-template-columns:minmax(0,1.1fr) auto;align-items:end;padding:var(--s6)}
  .hero-card{order:2}
  .hero-figs{grid-template-columns:repeat(4,minmax(0,1fr));grid-column:1/-1;order:3}
}
/* Three columns, in the order the markup already reads: the greeting, the four counts, then the
   card at the outer edge — the left, as the page reads in Arabic. No `order` here at all, so
   what is on the page is what is in the source. */
@media(min-width:86rem){
  .hero{grid-template-columns:minmax(0,1fr) minmax(0,1fr) auto;align-items:end;padding:var(--s6)}
  .hero-id,.hero-figs,.hero-card{order:0}
  .hero-figs{grid-column:auto;grid-template-columns:repeat(2,minmax(0,1fr))}
}
@media print{.hero-card{display:none}}


/* ================= التقويم الأكاديمي =================
   Ported from the registry's own sheet, restated in this application's terms. The one thing that
   changed in the move is colour: there, the kind of an entry was a coloured edge — red for an
   exam, green for a holiday. Here a status is a word plus the form of its stamp, so the kind is
   carried by the *shape* of the leading edge instead: solid for an examination, dashed for a
   holiday, dotted for registration, double for a term boundary and for a deadline. Scannable
   down the column for somebody reading in colour; printed in grey it is the word in the row
   that says which category it is, not the edge. */
.cal-mast{border-block-start:3px solid var(--brand-line);padding:var(--s3) var(--s4)}
.cal-mast-row{display:grid;gap:var(--s2) var(--s5);grid-template-columns:repeat(auto-fit,minmax(11rem,1fr));margin:0}
.cal-mast-row>div{display:flex;flex-direction:column;min-inline-size:0}
.cal-mast-row dt{font-size:.78rem;color:var(--g3)}
.cal-mast-row dd{margin:0;font-weight:700;font-size:.95rem;overflow-wrap:anywhere}
.cal-mast-intro{margin:var(--s3) 0 0;font-size:.88rem;color:var(--g3);line-height:1.7}

/* The ticks. A chip is a label wrapping its own checkbox, so it works with no script at all —
   the box is only visually hidden, never disabled, and the label is the whole target. */
.cal-pick{display:flex;gap:var(--s2);flex-wrap:wrap;align-items:center;padding:var(--s3) var(--s4)}
.cal-pick-k,.cal-pick-y{font-size:.85rem;color:var(--g3);font-weight:600}
.cal-pick-y select{margin-inline-start:var(--s2)}
.chip{display:inline-flex;align-items:center;gap:var(--s1);min-height:38px;padding:var(--s1) var(--s3);
  border:1.5px solid var(--g2);border-radius:999px;background:#fff;font-size:.86rem;cursor:pointer;white-space:nowrap}
.chip input{position:absolute;inline-size:1px;block-size:1px;opacity:0;pointer-events:none}
.chip:hover{border-color:var(--brand-line)}
.chip.is-on{background:var(--brand);border-color:var(--brand-line);color:var(--brand-ink)}
.chip:has(input:focus-visible){outline:3px solid var(--brand-line);outline-offset:2px}
.chip-n{flex:none;font-size:.76rem;font-weight:700;line-height:1;padding:.15rem .35rem;border-radius:999px;background:var(--g1);color:var(--g3)}
.chip.is-on .chip-n{background:rgba(255,255,255,.28);color:var(--brand-ink)}
.cal-mine{font-style:normal;font-size:.5rem;color:var(--brand);vertical-align:super}
.chip.is-on .cal-mine{color:var(--brand-ink)}
.cal-everything{margin-inline-start:auto;font-size:.85rem}
@media(max-width:48rem){.cal-everything{margin-inline-start:0}}
.cal-showing{margin:var(--s2) 0 var(--s4);font-size:.85rem;color:var(--g3)}

/* «أين نحن» — the first question, answered before anything else. */
.cal-today{display:flex;align-items:center;gap:var(--s4);flex-wrap:wrap;
  border:1.5px solid var(--g2);border-inline-start:4px solid var(--brand);border-radius:var(--r-s);
  padding:var(--s3) var(--s4);margin-block-end:var(--s4)}
.cal-today-d{display:flex;flex-direction:column;flex:none}
.cal-today-d span,.cal-today-n span{font-size:.75rem;color:var(--g3);letter-spacing:.04em}
.cal-today-d b{font-size:1.05rem;font-variant-numeric:tabular-nums}
.cal-today-t{display:flex;align-items:center;gap:var(--s2);flex-wrap:wrap;flex:1 1 14rem;min-inline-size:0}
.cal-today-t span{color:var(--g3);font-size:.85rem}
/* How far through the term, as a bar: "41%" is not a thing anyone pictures. */
.cal-bar{flex:1 1 6rem;min-inline-size:5rem;block-size:8px;border-radius:999px;background:var(--g1);border:1px solid var(--g2);overflow:hidden}
.cal-bar i{display:block;block-size:100%;background:var(--brand)}
.cal-today-n{display:flex;align-items:center;gap:var(--s1);flex-wrap:wrap;
  padding-inline-start:var(--s4);border-inline-start:1px solid var(--g2)}
.cal-today-n i{font-style:normal;color:var(--g3);font-variant-numeric:tabular-nums}
@media(max-width:48rem){.cal-today-n{padding-inline-start:0;border-inline-start:0}}

.cal-next{list-style:none;margin:0;padding:0}
.cal-next li{display:flex;align-items:center;gap:var(--s3);flex-wrap:wrap;padding:var(--s2) var(--s1);border-block-start:1px solid var(--g2)}
.cal-next li:first-child{border-block-start:0}
.cal-next li.is-now{background:var(--g1);border-radius:var(--r-s)}
.cal-when{flex:none;min-inline-size:8rem;display:flex;flex-direction:column;line-height:1.3}
.cal-when b{font-variant-numeric:tabular-nums}
.cal-when i{font-style:normal;font-size:.76rem;color:var(--g3);font-variant-numeric:tabular-nums}
.cal-what{flex:1 1 12rem;display:flex;flex-direction:column;min-inline-size:0}
.cal-what small{font-size:.76rem;color:var(--g3)}

.cal-term{margin-block-start:var(--s4)}
.cal-term.is-current{border-inline-start:4px solid var(--brand)}
.cal-term-h{display:flex;justify-content:space-between;align-items:baseline;gap:var(--s4);flex-wrap:wrap}
.cal-term-h h2{margin:0;display:flex;align-items:center;gap:var(--s2);flex-wrap:wrap}
.cal-figs{display:flex;gap:var(--s4);flex-wrap:wrap;font-size:.8rem;color:var(--g3)}
.cal-figs b{color:#000;font-variant-numeric:tabular-nums}

/* What has already happened: folded, and counted on the fold itself — a disclosure that does
   not say how much is behind it is a question rather than an answer. */
.cal-done{margin-block-end:var(--s3);border:1.5px dashed var(--g2);border-radius:var(--r-s)}
.cal-done>summary{padding:var(--s2) var(--s3);cursor:pointer;font-size:.85rem;color:var(--g3)}
.cal-done[open]>summary{border-block-end:1.5px dashed var(--g2)}
.cal-table.is-done{opacity:.72}
.cal-table td:first-child{min-inline-size:16rem}
.cal-table tr.is-past>td:first-child{color:var(--g3)}
.cal-dot{display:inline-block;inline-size:8px;block-size:8px;border-radius:50%;background:var(--brand);margin-inline-end:var(--s1)}

/* Printed, the whole year is the record: the folds open and the filters go. */
@media print{
  .cal-mast,.cal-term,.cal-today{break-inside:avoid}
  .cal-done{border:0}
  .cal-done>summary{display:none}
  .cal-done[open]>summary{border:0}
  .cal-done:not([open])>div{display:block}
  .cal-table.is-done{opacity:1}
}

/* ---- the categories ----
   Seven things an entry can be. Under one brand colour the edge can no longer carry seven
   categories on its own: a 4px edge has four border styles to offer — solid, dashed, dotted,
   double — so three must be shared, and once the hue is gone the red and the mid greys land
   almost on top of each other (#a93c2f and #5d5e5e are a tenth of a stop apart in grey). The
   arrangement below gives every category its own form and shares a style only between a dark
   ink and a light one, which is the most a seven-way edge can honestly do.
   The kind is therefore named IN THE ROW, as a word — which is what this platform does with
   every other state. The edge is a scanning aid for somebody reading in colour; it is not the
   only thing that says what a row is. The tints stay pale enough that black body text sits on
   them at better than 4.5:1. */
:root{
  --k-exam:var(--brand);      --k-exam-bg:var(--brand-wash);
  --k-holiday:#4f4f4f;   --k-holiday-bg:#eeeeee;
  --k-registration:#6f6f6f; --k-registration-bg:#f0f0f0;
  /* The same red as an examination and the same tint. These two used to be told apart by hue;
     they are now told apart by the form of the edge and by the word in the row. */
  --k-deadline:var(--brand);  --k-deadline-bg:var(--brand-wash);
  --k-term:#8a8a8a;      --k-term-bg:#f4f4f4;
  --k-teaching:#5d5e5e;  --k-teaching-bg:#f2f2f2;
  /* «مناسبة» is the one category on this calendar that is good news — a graduation, an
     opening, a ceremony. It used to be the one hue nothing else claimed; under one brand colour
     there is no spare hue, so it takes the darker red at 8.46:1 on white and a dashed edge.
     Black text on the tint is far clear of 4.5:1. */
  --k-event:var(--brand-line);     --k-event-bg:var(--brand-wash);
}
.cal-legend{display:flex;gap:var(--s2) var(--s3);flex-wrap:wrap;align-items:center;
  margin:var(--s4) 0 var(--s3);font-size:.82rem}
.cal-legend b{font-weight:700;font-size:.85rem}
.cal-legend span{padding:.1rem var(--s2);border-radius:999px;border:1.5px solid}
.cal-legend .k-exam{background:var(--k-exam-bg);border-color:var(--k-exam)}
.cal-legend .k-holiday{background:var(--k-holiday-bg);border-color:var(--k-holiday)}
.cal-legend .k-registration{background:var(--k-registration-bg);border-color:var(--k-registration)}
.cal-legend .k-deadline{background:var(--k-deadline-bg);border-color:var(--k-deadline)}
.cal-legend .k-term{background:var(--k-term-bg);border-color:var(--k-term)}
.cal-legend .k-teaching{background:var(--k-teaching-bg);border-color:var(--k-teaching)}
.cal-legend .k-event{background:var(--k-event-bg);border-color:var(--k-event)}

/* The row, coloured by what it is. `is-now` still wins — what is happening today is the one
   thing that outranks the category. */
.cal-table tr.k-exam>td{background:var(--k-exam-bg)}
.cal-table tr.k-holiday>td{background:var(--k-holiday-bg)}
.cal-table tr.k-registration>td{background:var(--k-registration-bg)}
.cal-table tr.k-deadline>td{background:var(--k-deadline-bg)}
.cal-table tr.k-term>td{background:var(--k-term-bg)}
.cal-table tr.k-teaching>td{background:var(--k-teaching-bg)}
.cal-table tr.k-event>td{background:var(--k-event-bg)}
/* Four of these used to be `solid`, which was free when four hues told them apart. exam and
   deadline carry the identical red, so they may not also carry the identical form. Every
   category now has its own, and where a style repeats it pairs a dark ink with a light one. */
.cal-table tr.k-exam>td:first-child{border-inline-start:4px solid var(--k-exam)}
.cal-table tr.k-deadline>td:first-child{border-inline-start:4px double var(--k-deadline)}
.cal-table tr.k-event>td:first-child{border-inline-start:4px dashed var(--k-event)}
.cal-table tr.k-holiday>td:first-child{border-inline-start:4px dotted var(--k-holiday)}
.cal-table tr.k-registration>td:first-child{border-inline-start:4px dashed var(--k-registration)}
.cal-table tr.k-term>td:first-child{border-inline-start:4px double var(--k-term)}
.cal-table tr.k-teaching>td:first-child{border-inline-start:4px solid var(--k-teaching)}
.cal-table tr.is-now>td{box-shadow:inset 0 0 0 2px #000}
.cal-table tr.is-past>td{filter:saturate(.35)}

/* ---- one button ---- */
.cal-cut{display:flex;align-items:center;gap:var(--s3);flex-wrap:wrap;margin:0 0 var(--s4)}
.cal-cut .hint{margin:0}

/* ---- التقويم الشهري ---- */
.cal-nav{display:flex;align-items:center;justify-content:center;gap:var(--s4);margin-block-end:var(--s3)}
.cal-nav h2{margin:0;min-inline-size:12rem;text-align:center}
.cal-grid{display:grid;grid-template-columns:repeat(7,minmax(0,1fr));gap:2px;background:var(--g2);border:1.5px solid var(--g2)}
.cal-dow{background:var(--g1);padding:var(--s1) var(--s2);font-size:.78rem;font-weight:700;text-align:center}
.cal-cell{background:#fff;min-block-size:5.5rem;padding:var(--s1);display:flex;flex-direction:column;gap:2px;overflow:hidden}
.cal-cell.is-empty{background:var(--g1)}
.cal-cell.is-today{box-shadow:inset 0 0 0 2px #000}
.cal-dnum{font-size:.8rem;font-weight:700;font-variant-numeric:tabular-nums;color:var(--g3)}
.cal-cell.is-today .cal-dnum{color:#000}
.cal-item{font-size:.72rem;line-height:1.3;padding:1px var(--s1);border-radius:3px;
  border-inline-start:3px solid;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.cal-item.k-exam{background:var(--k-exam-bg);border-color:var(--k-exam)}
.cal-item.k-holiday{background:var(--k-holiday-bg);border-color:var(--k-holiday)}
.cal-item.k-registration{background:var(--k-registration-bg);border-color:var(--k-registration)}
.cal-item.k-deadline{background:var(--k-deadline-bg);border-color:var(--k-deadline)}
.cal-item.k-term{background:var(--k-term-bg);border-color:var(--k-term)}
.cal-item.k-teaching{background:var(--k-teaching-bg);border-color:var(--k-teaching)}
.cal-item.k-event{background:var(--k-event-bg);border-color:var(--k-event)}
.cal-more{font-size:.7rem;color:var(--g3)}
@media(max-width:48rem){.cal-cell{min-block-size:4rem}.cal-item{font-size:.66rem}}

/* ---- التقويم السنوي: twelve months, each day stamped with what it carries ---- */
.cal-year{display:grid;grid-template-columns:repeat(auto-fill,minmax(13rem,1fr));gap:var(--s4)}
.cal-mini h3{margin:0 0 var(--s2);font-size:1rem}
.cal-mini-g{display:grid;grid-template-columns:repeat(7,1fr);gap:2px}
.cal-mini-dow{font-size:.62rem;color:var(--g3);text-align:center;font-weight:700}
.cal-mini-d{font-size:.7rem;text-align:center;padding:.2rem 0;border-radius:3px;
  font-variant-numeric:tabular-nums;border:1px solid transparent}
.cal-mini-d.is-empty{visibility:hidden}
.cal-mini-d.is-today{box-shadow:inset 0 0 0 2px #000;font-weight:700}
.cal-mini-d.k-exam{background:var(--k-exam-bg);border-color:var(--k-exam)}
.cal-mini-d.k-holiday{background:var(--k-holiday-bg);border-color:var(--k-holiday)}
.cal-mini-d.k-registration{background:var(--k-registration-bg);border-color:var(--k-registration)}
.cal-mini-d.k-deadline{background:var(--k-deadline-bg);border-color:var(--k-deadline)}
.cal-mini-d.k-term{background:var(--k-term-bg);border-color:var(--k-term)}
.cal-mini-d.k-teaching{background:var(--k-teaching-bg);border-color:var(--k-teaching)}
.cal-mini-d.k-event{background:var(--k-event-bg);border-color:var(--k-event)}

@media print{
  .cal-grid,.cal-year,.cal-mini,.cal-cell{break-inside:avoid}
  /* Colour is set to print: these pages are carried about on paper. */
  .cal-table tr>td,.cal-item,.cal-mini-d,.cal-legend span{-webkit-print-color-adjust:exact;print-color-adjust:exact}
}

/* ================= sortable headings, and the month picker =================
   A sorted or filtered table is an address: every heading is a link and every month is a tick
   inside a GET form, so the view somebody arrived at can be kept, bookmarked or sent on. The
   mark in a heading says what it will do before it is pressed — ⇅ for «sort by this», ▲ or ▼ for
   «sorted, press to turn it round» — because a column that only reveals its state after you
   click it has made you do the experiment. */
.sortcol{display:inline-flex;align-items:center;gap:var(--s1);color:inherit;text-decoration:none}
.sortcol:hover,.sortcol:focus-visible{text-decoration:underline;text-underline-offset:.2em}
.sortcol .sortmark{font-size:.7rem;color:var(--g3);line-height:1}
.sortcol.is-on{color:var(--brand-line)}
.sortcol.is-on .sortmark{color:var(--brand-line)}
th[aria-sort] .sortcol{font-weight:800}
@media print{.sortcol .sortmark{display:none}}

.cf-mon{border:1.5px solid var(--g2);border-radius:var(--r-s);padding:var(--s3);margin:0;
  display:flex;gap:var(--s2);flex-wrap:wrap;align-items:center}
.cf-mon legend{font-size:.85rem;font-weight:600;color:var(--g3);padding-inline:var(--s2)}
.cf-mon .chip{min-height:34px;font-size:.82rem}
.cf-mon-w{display:inline-flex;align-items:center;gap:var(--s2);font-size:.85rem;color:var(--g3)}
.cf-mon .hint{flex:1 1 100%;margin:0}

/* The reassignment fold on a board card. Shut by default: on most cards on most days nobody is
   moving anything, and a select open on every card turns a board of work into a board of forms. */
.kmove{margin-block-start:var(--s2);border-block-start:1px dashed var(--g2);padding-block-start:var(--s2)}
.kmove>summary{cursor:pointer;font-size:.78rem;color:var(--g3)}
.kmove .form{margin-block-start:var(--s2)}
.kmove .fld{margin-block-end:var(--s2)}
.kmoves{list-style:none;margin:var(--s2) 0 0;padding:0;font-size:.76rem}
.kmoves li{display:flex;flex-direction:column;gap:1px;padding:var(--s1) 0;border-block-start:1px solid var(--g2)}
.kmoves .why{color:var(--g3);font-style:italic}

/* The release, beside the copyright. Quiet enough not to compete with it, and gone from the
   printed page: paper carries its own date, and a version number is for somebody reporting a
   fault from a screen. */
.foot .ver{margin-inline-start:var(--s2);font-family:var(--ui);font-size:.78rem;color:var(--g3);
  font-variant-numeric:tabular-nums;white-space:nowrap}
@media print{.foot .ver{display:none}}

/* A field that filled itself says so for a moment. A value appearing silently in a box the
   reader is not looking at is how people end up submitting last year's country. */
.was-filled{background:var(--k-deadline-bg);transition:background .4s ease}
@media(prefers-reduced-motion:reduce){.was-filled{transition:none}}

/* The way from a card to the task's own page, and the mark on a card that is not being counted
   in the reports — which somebody reading the board should not have to open a task to learn. */
.kmanage{margin:var(--s2) 0 0;display:flex;align-items:center;gap:var(--s2);flex-wrap:wrap;font-size:.78rem}

/* ================= charts =================
   Drawn on the server as SVG, so what is styled here is only the frame around them: the figures
   themselves carry their own colours as attributes and cannot be lost to a stylesheet that
   failed to load or a printer that drops backgrounds. */
.charts{display:grid;gap:var(--s4);grid-template-columns:repeat(auto-fit,minmax(16rem,1fr));margin-block-end:var(--s5)}
.chart{margin:0;border:1.5px solid var(--g2);border-radius:var(--r-s);padding:var(--s3);background:#fff;break-inside:avoid}
.chart svg{display:block;inline-size:100%;block-size:auto;max-block-size:16rem}
.chart figcaption{margin-block-start:var(--s2);font-size:.82rem;font-weight:600;color:var(--g3);text-align:center}
.chart-key{list-style:none;display:flex;flex-wrap:wrap;gap:var(--s1) var(--s3);margin:var(--s2) 0 0;padding:0;font-size:.78rem}
.chart-key li{display:inline-flex;align-items:center;gap:var(--s1)}
.chart-key svg{inline-size:12px;block-size:12px;flex:none}
.chart-donut svg{max-block-size:11rem}
.chart.is-blank{display:flex;flex-direction:column;justify-content:center;min-block-size:7rem}
.chart.is-blank .empty{margin:0;text-align:center}

.chart-heat svg{max-block-size:none}
@media print{
  /* These are the figures. They print in colour or the page says less than it did on screen. */
  .charts{grid-template-columns:repeat(2,1fr);gap:var(--s3)}
  .chart{break-inside:avoid;-webkit-print-color-adjust:exact;print-color-adjust:exact}
  .chart svg{max-block-size:13rem}
}

/* ================= براءات الاختراع =================
   The filing sheet. Every measurement here is the regulation's, not a design decision:
     margins  2.5 cm top and right, 2 cm bottom and left, «وتكون الهوامش خالية تماماً»
     leading  about 1 cm between lines
     type     capitals about 3.2 mm, dark and clear
     parts    each begins a new page, its name centred at the top and underlined
     folio    the sheet number centred below the top margin, never in the margin itself
     lines    every fifth numbered, to the left of the right margin
   The numbers are computed in PHP, because a browser decides where a line wraps only after it
   has laid the page out and no stylesheet can count those. */
@page patent{size:A4 portrait;margin:2.5cm 2.5cm 2cm 2cm}
.pat-doc{page:patent;font-family:var(--doc);font-size:12pt;line-height:1cm;max-inline-size:none}
@media print{body:has(.pat-doc){page:patent}}

.pat-page{break-after:page;padding-block-end:var(--s5)}
.pat-page:last-child{break-after:avoid-page;padding-block-end:0}
/* The sheet number sits below the top margin, centred — not inside the margin, which the
   regulation says stays clear. */
.pat-folio{text-align:center;font-size:10pt;color:#000;margin:0 0 var(--s5);font-variant-numeric:tabular-nums}
.pat-h{text-align:center;text-decoration:underline;text-underline-offset:.22em;font-size:14pt;margin:0 0 var(--s5)}
.pat-title{text-align:center;font-size:13pt;margin:0 0 var(--s4)}
.pat-sub{font-size:12pt;margin:var(--s4) 0 var(--s2);font-weight:700}

/* A line and its number. The number column is fixed so the text starts at the same place on
   every line, numbered or not — a ragged left edge is how a typed page betrays its tooling. */
.pat-body{margin-block-end:var(--s3)}
.pat-line{display:flex;gap:var(--s3);margin:0;line-height:1cm;break-inside:avoid}
.pat-n{flex:none;inline-size:2.2em;text-align:end;font-family:var(--ui);font-size:9pt;color:#000;
  font-variant-numeric:tabular-nums;line-height:1cm}
.pat-t{flex:1;white-space:pre-wrap;overflow-wrap:anywhere}

.pat-meta{margin:0 0 var(--s5)}
.pat-meta>div{display:flex;gap:var(--s3);padding-block:.2rem;border-block-end:1px solid var(--g2)}
.pat-meta dt{flex:none;inline-size:11rem;font-weight:700}
.pat-meta dd{margin:0;flex:1}
.pat-check{margin:0 0 var(--s4);padding-inline-start:1.2rem}
.pat-check li{margin-block-end:var(--s2)}
.pat-foot{font-size:10pt;color:var(--g3);margin-block-start:var(--s5)}
.pat-claims{padding-inline-start:1.4rem}
.pat-claims li{margin-block-end:var(--s3)}

/* The two languages are written side by side on the form, so a translation is never produced
   from a document that has since moved on. */
.pat-pair{border-block-start:1.5px solid var(--g2);padding-block-start:var(--s3);margin-block-start:var(--s3)}
.pat-pair h3{margin:0 0 var(--s1)}
.pat-pair .hint{margin:0 0 var(--s2)}

@media print{
  .pat-doc .pat-page{break-after:page}
  .pat-doc .pat-page:last-child{break-after:auto}
  .pat-n{color:#000}
  .pat-meta>div{border-block-end:1px solid #000}
}

/* A flag on the language button. Drawn at 2:1, which is the Union Flag's ratio and close enough
   to Kuwait's that neither looks stretched beside the other at this size. */
.flag{inline-size:22px;block-size:11px;flex:none;border-radius:2px;display:inline-block;vertical-align:-1px}
.btn .flag{margin-inline-end:var(--s1)}

/* ================= قاعات الاجتماعات =================
   Colour here says what KIND of space a booking is in, which is the question somebody scanning
   a week actually has. Status is a word on the block and never a colour: a tentative booking
   holds the room exactly as a confirmed one does, and a reader who cannot separate two hues
   must still be able to tell them apart. */
:root{
  --r-meeting:#6f6f6f; --r-board:var(--brand); --r-lecture:#8a8a8a; --r-exhibition:var(--brand-line);
  --r-study:#4f4f4f;   --r-studio:var(--brand-line); --r-dining:var(--brand); --r-other:#5d5e5e;
}
/* The box the floor plan scrolls inside. `max-inline-size` matters as much as the overflow:
   a scroll container that is itself allowed to grow is not a scroll container, it is a wide
   page — which is what the phone was showing. */
.rmmap{overflow-x:auto;max-inline-size:100%;border:1.5px solid var(--g2);border-radius:var(--r-s);background:#fff}
/* `.rmmap svg` used to set a 40rem floor here and, being the more specific selector, it beat
   `.planmap` and forced every floor to 640px whatever the screen. It is gone: the drawing's own
   rule decides, and it is relaxed on a phone below. */
/* ---- the floor plan ----------------------------------------------------------------------
   The viewBox is in MILLIMETRES, straight off the drawings, so every stroke width below is a
   real thickness: 220 is a 22cm external wall, 60 is a 6cm line between two rooms. Nothing is
   scaled by hand anywhere — the plan is laid out at building size and the browser fits it to
   the page, which is why a floor 37m long and one 55m long both come out in proportion.

   Colour says WHAT KIND of space a room is, never whether a booking is confirmed; status stays
   a word on the booking. Rooms that cannot be booked here are drawn in greys so that the ones
   that can be booked are the only coloured things on the page — which is the whole of what
   somebody is looking for. */
/* The plan fills its panel and keeps its proportions. The floor-size minimum is what makes a
   long building scroll sideways rather than shrink to a strip, and 34rem is the narrowest at
   which a room code is still readable. */
.planmap{display:block;inline-size:100%;min-inline-size:34rem;block-size:auto}
.pl-shell{fill:#fff;stroke:#000;stroke-width:220}
.pl-room rect{fill:#fbfbfb;stroke:#8a8a8a;stroke-width:60}
.pl-code{text-anchor:middle;font-weight:700;fill:#3a3a3a}
.pl-name{text-anchor:middle;fill:#4f4f4f}
.pl-room.k-corridor rect{fill:#f2f2f2;stroke:none}
.pl-room.k-open rect{fill:#fafafa;stroke:#c6c7c7;stroke-dasharray:300 200}
.pl-room.k-office rect,.pl-room.k-service rect{fill:#f4f4f4}
.pl-room.k-class rect,.pl-room.k-lab rect{fill:#f0f0f0}
.pl-room.k-wc rect{fill:#f0f0f0}
.pl-room.k-core rect{fill:#e4e4e4;stroke:#6f6f6f}
/* A bookable room: the kind's colour on the wall, a wash of it inside, and its text in black. */
.pl-room.is-book rect{stroke-width:150}
.pl-room.is-book .pl-code{fill:#000}
.pl-room.is-book .pl-name{fill:#3a3a3a}
.pl-room.k-meeting.is-book rect{stroke:var(--r-meeting);fill:#f0f0f0}
.pl-room.k-board.is-book rect{stroke:var(--r-board);fill:var(--brand-wash)}
.pl-room.k-lecture.is-book rect{stroke:var(--r-lecture);fill:#f4f4f4}
.pl-room.k-exhibition.is-book rect{stroke:var(--r-exhibition);fill:var(--brand-wash)}
.pl-room.k-study.is-book rect{stroke:var(--r-study);fill:#eeeeee}
.pl-room.k-studio.is-book rect{stroke:var(--r-studio);fill:var(--brand-wash)}
.pl-room.k-dining.is-book rect{stroke:var(--r-dining);fill:var(--brand-wash)}
.pl-room.k-other.is-book rect{stroke:var(--r-other);fill:#f1f1f1}
a.pl-room:hover rect,a.pl-room:focus-visible rect{stroke-width:320}
a.pl-room:focus-visible{outline:3px solid var(--brand);outline-offset:2px}
.pl-room.is-here rect{stroke:#000;stroke-width:320}
/* How many bookings the room has in the days being shown. A number, not a shade. */
.pl-dot{fill:#000}
.pl-dotn{fill:#fff;text-anchor:middle;font-weight:700}
.pl-scale line{stroke:#000;stroke-width:70}
.pl-scale text{text-anchor:middle;fill:#3a3a3a}

/* ---- choosing the building: the campus itself ----
   The site plan is the zoom-out. One spine corridor runs the length of the College and every
   block hangs off it, in its place and at its relative size, with the main entrance and the
   reception marked — which is how anybody actually describes where a room is: «J, off the spine
   past the reception, second floor». Pressing a block zooms into that block's floor beside it.
   Block B is drawn twice because the site plan draws it twice: two office wings, one above the
   reception and one below, both the same block. */
.plsite{display:block;inline-size:100%;block-size:auto;max-block-size:46rem;margin-inline:auto}
.pl-spine{fill:#eeeeee;stroke:#a6a6a6;stroke-width:4}
.pl-block rect{fill:#fbfbfb;stroke:#4f4f4f;stroke-width:5}
.pl-block .pl-bl{text-anchor:middle;font-weight:700;fill:#000}
.pl-block .pl-bn{text-anchor:middle;fill:var(--g3)}
a.pl-block:hover rect,a.pl-block:focus-visible rect{stroke:var(--brand);stroke-width:9}
a.pl-block:focus-visible{outline:3px solid var(--brand);outline-offset:2px}
.pl-block.is-here rect{fill:var(--brand);stroke:#000;stroke-width:9}
.pl-block.is-here .pl-bl{fill:var(--brand-ink)}
.pl-block.is-here .pl-bn{fill:var(--brand-ink)}
/* A block placed by elimination rather than read off the key: broken outline, and the page
   says why. The same device as a provisional room capacity — an inference must not look
   like a reading. */
.pl-block.is-guess rect{stroke-dasharray:18 12}
.pl-recep rect{fill:#fff;stroke:#4f4f4f;stroke-width:4;stroke-dasharray:14 10}
.pl-recep text{text-anchor:middle;fill:#3a3a3a}
.pl-entry line{stroke:var(--k-exam);stroke-width:9}
.pl-entry path{fill:var(--k-exam)}
.pl-entry text{fill:var(--k-exam);font-weight:700}

/* The same nine blocks as words, for a narrow screen and for anybody who would rather read. */
.plblocks{display:flex;gap:var(--s2) var(--s3);flex-wrap:wrap;align-items:baseline;font-size:.86rem}
.plblocks a{text-decoration:none;border-block-end:1.5px solid var(--g2);padding-block-end:1px}
.plblocks a:hover{border-color:var(--brand)}
.plblocks a[aria-current]{font-weight:700;border-color:#000}

/* ---- choosing the floor: a section of the building you are in ---- */
.plstack{display:block;inline-size:100%;block-size:auto}
.pl-slab rect{fill:#fff;stroke:#8a8a8a;stroke-width:1.5}
.pl-slab .pl-slabn{fill:#000;font-weight:700}
.pl-slab .pl-slabm{fill:var(--g3)}
.pl-slabst line{stroke:#8a8a8a;stroke-width:1.5}
.pl-slab:hover rect,.pl-slab:focus-visible rect{stroke:var(--brand);stroke-width:2.5}
.pl-slab:focus-visible{outline:3px solid var(--brand);outline-offset:2px}
.pl-slab.is-here rect{fill:var(--g1);stroke:#000;stroke-width:2.5}
.pl-ground{stroke:#000;stroke-width:2.5}

/* The two dates, one under the other, and the floor section beside them.
   `.form` goes to two columns at 44rem, which is right for a form and wrong for these two: it
   put من يوم and إلى يوم side by side in a column narrow enough to clip both to «2026». They
   are forced back to one column here, and the column is 16rem — a date field needs about ten
   to show a date in full, and the label sits above it.
   The floor section is capped rather than stretched: slabs the width of the page were a very
   emphatic way of saying «three floors». */
.rmtop{display:grid;grid-template-columns:1fr;gap:var(--s3) var(--s4);margin-block-end:var(--s3)}
/* `.form` goes to two columns at 44rem — right for a form, wrong for these two, which were
   halved until neither could show more than «2026». That rule lives further down the sheet, so
   a selector of equal weight loses to it on order: this one names the parent as well, which
   wins on specificity wherever it sits. */
.rmtop form.rmtop-days{margin:0;align-content:start;grid-template-columns:minmax(0,1fr)}
.rmtop-days .fld{margin:0}
.rmtop .plfloors,.rmtop .rmdays{margin:0}
.rmdays .form{margin-block-end:0}
@media (min-width:52rem){
  /* `stretch`, not `start`: the two are a pair and should begin and end on the same lines. Left
     to themselves each takes the height of its own contents — three slabs against two dates and
     a button — and the row comes out with one box hanging lower than the other. */
  .rmtop{grid-template-columns:16rem minmax(0,1fr);align-items:stretch}
  .rmtop form.rmtop-days{grid-template-columns:minmax(0,1fr)}
  /* The dates sit at the top of whatever height the pair settles on, and the button stays with
     them: a submit floating at the foot of a box it is not near belongs to nothing. */
  .rmtop .rmdays{display:flex;flex-direction:column}
}
/* The column the floor belongs to: its top row and its drawing are the same width, because
   they are the same column.
   Every box between the page and the drawing is pinned to `min-inline-size:0`. A grid or flex
   child defaults to `min-width:auto`, which is the width of its contents — so one wide drawing
   deep inside pushes its panel, its column and the page out with it, and on a phone the result
   is a page that slides sideways under the finger. */
.plmain{display:grid;gap:0;align-content:start;min-inline-size:0}
.plmain,.plplan,.plsite-p,.rmdays,.plfloors{min-inline-size:0;max-inline-size:100%}

/* ---- the phone ----
   The floor plan is the one thing here that cannot simply be made narrower: a building 37m long
   drawn at 320px puts a room code in two pixels. So it keeps a width to be read at — 26rem
   rather than the 34 it takes on a desk — and scrolls sideways inside its own box, while
   everything around it fits the screen exactly. */
@media (max-width:51.999rem){
  .plrow,.rmtop{grid-template-columns:minmax(0,1fr)}
  .planmap{min-inline-size:26rem}
  .plsite{max-block-size:30rem}
  .rm-key{font-size:.78rem}
  .rmrest>summary{padding-inline:var(--s2)}
}
.plstack{max-inline-size:20rem}

.plrow{display:grid;grid-template-columns:1fr;gap:var(--s3)}
.plside{display:grid;gap:var(--s3);align-content:start}
.plsite-wrap{display:flex;justify-content:center}
@media (min-width:62rem){
  /* The campus column and the floor plan end together.
     This was tried once before and made the campus unreadable, because it then shared the
     column with the floor section and was left about a hundred pixels wide. The floor section
     has gone up beside the dates, so the campus now has the column to itself and the whole
     height of the drawing to fill — and `min-block-size` is the guard against the other way it
     can go wrong: a short floor, such as C's ground, would otherwise shrink it again. */
  .plrow{grid-template-columns:22rem 1fr;align-items:stretch}
  .plsite-p{display:flex;flex-direction:column;min-block-size:0}
  .plsite-wrap{flex:1 1 0;min-block-size:26rem}
  .plsite-wrap .plsite{block-size:100%;inline-size:auto;max-inline-size:100%;max-block-size:none}
}

/* What cannot be booked, folded. The count is on the fold itself: a disclosure that does not
   say how much is behind it is a question rather than an answer. */
.rmrest{margin-block-start:var(--s3);border:1.5px dashed var(--g2);border-radius:var(--r-s)}
.rmrest>summary{padding:var(--s2) var(--s3);cursor:pointer;font-size:.86rem;color:var(--g3)}
.rmrest[open]>summary{border-block-end:1.5px dashed var(--g2)}
@media print{.rmrest>summary{display:none}.rmrest{border:0}}
@media print{.plside{display:none}}
.rm-key{gap:var(--s1) var(--s2)}
.rm-key .sw{padding:.15rem var(--s3);border-radius:999px;border:1.5px solid;background:#fff;
  color:inherit;text-decoration:none;white-space:nowrap}
a.sw:hover,a.sw:focus-visible{background:var(--g1)}
a.sw:focus-visible{outline:3px solid var(--brand);outline-offset:2px}
/* The kind being shown on its own: thicker rule and bold, never colour alone — the chips are
   already told apart by colour and this has to say something a second time. */
.rm-key .sw.is-on{border-width:3px;font-weight:700;background:var(--g1)}
.rm-key .sw.is-all{border-color:#000;font-weight:700}
/* A room of another kind while one kind is being shown. Dimmed, not hidden: a room is found by
   what is next to it, and hiding the neighbours would defeat the plan. */
.pl-room.is-dim{opacity:.22}
.pl-room.is-dim text{display:none}
.rm-key .k-meeting{border-color:var(--r-meeting)}
.rm-key .k-board{border-color:var(--r-board)}
.rm-key .k-lecture{border-color:var(--r-lecture)}
.rm-key .k-exhibition{border-color:var(--r-exhibition)}
.rm-key .k-study{border-color:var(--r-study)}
.rm-key .k-studio{border-color:var(--r-studio)}
.rm-key .k-dining{border-color:var(--r-dining)}
.rm-key .k-other{border-color:var(--r-other)}
.rm-key .k-class,.rm-key .k-office,.rm-key .k-core{border-color:var(--g2);color:var(--g3)}

/* The day, as a column of quarter-hours. */
.rmday{border:1.5px solid var(--g2);border-radius:var(--r-s);overflow:hidden}
.rmslot{display:flex;align-items:stretch;gap:var(--s2);min-block-size:1.9rem;border-block-start:1px solid var(--g2);padding:2px var(--s2)}
.rmslot:first-child{border-block-start:0}
.rmslot.is-taken{background:var(--g1)}
.rmtime{flex:none;inline-size:3.6rem;font-size:.76rem;color:var(--g3);font-variant-numeric:tabular-nums;padding-block-start:2px}
.rmfree{flex:1;font-size:.78rem;color:var(--g3);text-decoration:none;border:1px dashed var(--g2);border-radius:4px;
  display:flex;align-items:center;padding-inline:var(--s2)}
.rmfree:hover,.rmfree:focus-visible{border-style:solid;border-color:var(--brand);color:#000}
.rmblock{flex:1;display:block;padding:var(--s1) var(--s2);border-radius:5px;text-decoration:none;color:#000;
  border-inline-start:4px solid var(--r-other);background:var(--g1)}
.rmblock b{display:block;font-size:.86rem}
.rmblock .meta{display:block}
.rmblock.k-meeting,.cal-item.k-meeting{border-inline-start-color:var(--r-meeting)}
.rmblock.k-board,.cal-item.k-board{border-inline-start-color:var(--r-board)}
.rmblock.k-lecture,.cal-item.k-lecture{border-inline-start-color:var(--r-lecture)}
.rmblock.k-exhibition,.cal-item.k-exhibition{border-inline-start-color:var(--r-exhibition)}
.rmblock.k-study,.cal-item.k-study{border-inline-start-color:var(--r-study)}
.rmblock.k-studio,.cal-item.k-studio{border-inline-start-color:var(--r-studio)}
.rmblock.k-dining,.cal-item.k-dining{border-inline-start-color:var(--r-dining)}
.rmblock.k-other,.cal-item.k-other{border-inline-start-color:var(--r-other)}
.rmweek td{vertical-align:top;min-inline-size:9rem}
.rmweek td.is-today{box-shadow:inset 0 0 0 2px #000}
.rmweek .rmblock{margin-block-end:var(--s1)}
.rmadd{display:block;text-align:center;border:1px dashed var(--g2);border-radius:4px;color:var(--g3);text-decoration:none}
.rmadd:hover{border-color:var(--brand);color:#000}
.rm-invite{max-inline-size:40rem;margin-inline:auto;padding:var(--s5)}
@media print{.rmfree,.rmadd{display:none}}

/* ---- the people picker ----
   A scrolling box of checkboxes with a search field over it. It is deliberately not a combo
   box: somebody inviting six people needs to see the six they have ticked, and a control that
   shows one line at a time cannot do that. */
.pickbox{border:1.5px solid var(--g2);border-radius:var(--r-s);padding:var(--s2);background:#fff}
.pickbox .fld{margin-block-end:var(--s1)}
.pickq{inline-size:100%;padding:var(--s2);border:1.5px solid var(--g2);border-radius:var(--r-s);
  font:inherit;background:#fff;color:#000}
.pickq:focus-visible{outline:3px solid var(--brand);outline-offset:1px}
.picklist{list-style:none;margin:0;padding:0;max-block-size:15rem;overflow-y:auto;
  border-block-start:1px solid var(--g2)}
.picklist li{border-block-end:1px solid var(--g1)}
.picklist label{display:flex;align-items:baseline;gap:var(--s2);padding:.35rem var(--s1);cursor:pointer}
.picklist label:hover{background:var(--g1)}
.picklist input{flex:none}
.picklist b{font-weight:600}
.picklist .meta{font-size:.76rem;color:var(--g3)}
.picklist li:has(input:checked){background:var(--brand-wash);box-shadow:inset 3px 0 0 var(--brand)}
@media print{.pickbox{display:none}}


/* ---- الترجمة ----
   The pair of buttons between an Arabic field and its English twin, and the box the translation
   page shows its answer in. */
.tr-pair{display:flex;align-items:center;gap:var(--s2);flex-wrap:wrap;margin-block-end:var(--s3)}
.tr-pair .hint{flex:1 1 14rem;margin:0}
.tr-btn::before{content:"";display:inline-block;inline-size:0}
.tr-err{font-size:.82rem;color:var(--k-exam);font-weight:600}
.ai-out{border:1.5px solid var(--g2);border-inline-start:4px solid var(--brand);border-radius:var(--r-s);
  padding:var(--s3) var(--s4);background:#fff;font-family:var(--doc);font-size:1.05rem;line-height:1.85;
  white-space:pre-wrap}
/* The box being written into. A minimum height so the panel does not jump as the first line
   lands, and a caret while it is working — the one honest sign that words are still coming, since
   a model that has paused mid-sentence looks exactly like one that has finished. */
.ai-live{margin-block-start:var(--s4)}
.ai-live .ai-out{min-block-size:4.5rem}
.ai-out[aria-busy="true"]::after{content:"▌";animation:ai-blink 1.1s step-end infinite;
  margin-inline-start:.1em;color:var(--brand)}
@keyframes ai-blink{50%{opacity:0}}
@media (prefers-reduced-motion:reduce){.ai-out[aria-busy="true"]::after{animation:none}}
@media print{.tr-pair{display:none}.ai-live .actions{display:none}}



/* ---- the day: an hour to a row, a quarter to a cell ----
   Fifteen rows instead of sixty. The hour names itself once on the left; the four cells after
   it are the quarters, labelled 00 15 30 45, and each is its own press. Pressing a cell sets
   the start, pressing a later one sets the end, and everything between is washed red — so the
   length of the meeting is something you can see rather than something you work out from two
   dropdowns. */
.rmgrid{display:grid;grid-template-columns:repeat(4,1fr);gap:4px;
  border:1.5px solid var(--g2);border-radius:var(--r-s);padding:var(--s2);background:#fff}
@media(min-width:40rem){.rmgrid{grid-template-columns:repeat(6,1fr)}}
@media(min-width:60rem){.rmgrid{grid-template-columns:repeat(8,1fr)}}
.rmqc{display:flex;align-items:center;justify-content:center;min-block-size:2.3rem;
  border:1.5px solid var(--g2);border-radius:5px;background:#fff;color:var(--g3);
  font:inherit;font-size:.82rem;font-variant-numeric:tabular-nums;text-decoration:none;
  cursor:pointer;touch-action:none;user-select:none}
button.rmqc:hover{border-color:var(--brand);color:#000;background:var(--k-deadline-bg)}
button.rmqc:focus-visible{outline:3px solid var(--brand);outline-offset:2px}
/* Ticked. The brand red and not green, because the red is what every other chosen thing in
   this platform is, and a second «selected» colour would mean nothing extra. The tick is also carried by
   aria-pressed and by the figure in the line above, so colour is never the only channel. */
.rmqc.is-on{background:var(--brand);border-color:var(--brand-line);color:var(--brand-ink);font-weight:700}
.rmqc.is-taken{background:var(--g2);border-color:var(--g2);color:var(--g3);cursor:not-allowed}
.rmpick{font-size:.86rem;font-weight:700;font-variant-numeric:tabular-nums}
@media print{.rmgrid,.rmpick{display:none}}


/* ---- the clock picker ----
   Deliberately NOT in this platform's dress. There is no brand red here, no house lettering and no
   black-and-white rule: a clock face is something people have read since they were five, and a
   restyled one has to be learned again. White face, black rim, sixty ticks, twelve serif
   numerals, one hand. The only thing it adds to a real clock is which quarters are taken.
   Three states, told apart by fill AND by a title every pointer and screen reader can read:
   white free, grey taken, black chosen. */
.clocks{display:flex;gap:var(--s4);flex-wrap:wrap;align-items:flex-start;margin-block-end:var(--s3)}
.clockbox{margin:0;flex:1 1 13rem;max-inline-size:17rem;text-align:center}
.clockbox figcaption{font-size:.84rem;color:var(--g3);margin-block-start:var(--s1);
  font-variant-numeric:tabular-nums}
.clock{display:block;inline-size:100%;block-size:auto}
.clk-face{fill:#fff;stroke:#111;stroke-width:2}
.clk-tick{stroke:#111;stroke-width:.8}
.clk-tick.is-hour{stroke-width:2}
.clk-num{fill:#111;text-anchor:middle;font-family:Georgia,"Times New Roman",serif;font-size:14px}
.clk-w{fill:#fff;stroke:#a6a6a6;stroke-width:.5;cursor:pointer}
.clk-w:hover{fill:#e8e8e8}
.clk-w:focus-visible{outline:2px solid #111;outline-offset:1px}
.clk-w.is-taken{fill:#a6a6a6;cursor:not-allowed}
.clk-w.is-on{fill:#111}
.clk-hand{stroke:#111;stroke-width:2.4;stroke-linecap:round;transform-origin:110px 110px;
  transition:transform .18s ease}
.clk-pin{fill:#111}
.clk-key{flex:1 1 100%;display:flex;gap:var(--s2) var(--s3);flex-wrap:wrap;align-items:center;
  font-size:.8rem;color:var(--g3);margin:0}
.clk-sw{inline-size:14px;block-size:14px;border:1px solid #a6a6a6;background:#fff;display:inline-block}
.clk-sw.is-taken{background:#a6a6a6}
.clk-sw.is-on{background:#111;border-color:#111}
@media(prefers-reduced-motion:reduce){.clk-hand{transition:none}}
@media print{.clocks{display:none}}
/* ================= figures ================= */
.figs{display:grid;grid-template-columns:repeat(auto-fit,minmax(9.5rem,1fr));gap:var(--s3);margin-block-end:var(--s5)}
.figs div,.figs a{display:block;padding:var(--s3) var(--s4);border:var(--hair);border-radius:var(--r)}
.figs div:first-child,.figs a:first-child{background:#000;color:#fff}
/* A figure that opens its own list: it is a link, so it says so on hover and under the keyboard,
   and the red edge marks it as the way in without the number itself changing colour. */
.figs a{text-decoration:none;color:inherit;transition:box-shadow .12s ease}
.figs a:hover,.figs a:focus-visible{box-shadow:inset 0 0 0 2px var(--brand)}
.figs a:hover span,.figs a:focus-visible span{text-decoration:underline;text-underline-offset:.2em}
.figs b{display:block;font-family:var(--doc);font-size:2.1rem;line-height:1.2}
.figs span{font-size:.86rem}

/* ================= tables ================= */
.tw{overflow-x:auto;margin-block-end:var(--s4);-webkit-overflow-scrolling:touch}
table{border-collapse:collapse;inline-size:100%;font-size:.94rem}
table.data{border-block:var(--rule)}
caption{text-align:start;font-weight:700;padding-block-end:var(--s2)}
th,td{text-align:start;padding:.6rem var(--s3);vertical-align:top}
th:first-child,td:first-child{padding-inline-start:var(--s1)}
/* A wash behind the head, so a long report table keeps its columns legible without a rule
   under every row. It survives a greyscale printer, which a colour never would. */
thead th{border-block-end:var(--hair);font-weight:700;white-space:nowrap;font-size:.86rem;background:var(--g1)}
tbody tr+tr>*{border-block-start:1px dotted var(--g2)}
tbody tr:nth-child(even)>*{background:#fbfbfb}
tfoot td,tfoot th{border-block-start:var(--hair);font-weight:700}
.num{text-align:end;font-variant-numeric:tabular-nums;white-space:nowrap}
table.chart{margin-block-end:var(--s4)}
table.chart th{font-weight:400;inline-size:36%}
table.chart .barcell{inline-size:48%}
table.chart tbody tr+tr>*{border:0}
table.kv th{inline-size:32%;font-weight:600}
dl.kv{display:grid;grid-template-columns:minmax(8rem,14rem) 1fr;gap:var(--s1) var(--s4);margin:0 0 var(--s4)}
dl.kv dt{font-weight:600}dl.kv dd{margin:0}
@media(max-width:36rem){dl.kv{grid-template-columns:1fr}dl.kv dd{margin-block-end:var(--s2)}table.kv th,table.kv td{display:block;inline-size:100%;padding-inline:0}table.kv th{padding-block-end:0;font-size:.85rem}table.kv td{padding-block-start:.1rem;border:0!important}}

/* ================= stamps, meters ================= */
.badge{display:inline-block;padding:.1rem .7rem;font-size:.8rem;font-weight:700;line-height:1.55;white-space:nowrap;border:1.5px solid #000;border-radius:999px;background:#fff;color:#000;vertical-align:middle}
.badge.solid{background:#000;color:#fff}
.badge.dashed{border-style:dashed}
.badge.hatch{border:4px solid transparent;background:linear-gradient(#fff 0 0) padding-box,var(--hatch) border-box;padding:0 .55rem}
progress{appearance:none;-webkit-appearance:none;inline-size:100%;block-size:.7rem;border:var(--hair);border-radius:999px;background:#fff;vertical-align:middle;overflow:hidden}
progress::-webkit-progress-bar{background:#fff;border-radius:999px}
progress::-webkit-progress-value{background:#000;border-radius:999px}
progress::-moz-progress-bar{background:#000;border-radius:999px}
.gantt{inline-size:100%;block-size:1.1rem;display:block;min-inline-size:10rem}
[dir=rtl] .gantt{transform:scaleX(-1)}

/* ================= the six stages: a stepper ================= */
.stages{list-style:none;padding:0;margin:var(--s3) 0 var(--s5);display:grid;gap:0}
.stages li{position:relative;display:grid;grid-template-columns:2.6rem 1fr;column-gap:var(--s3);padding-block-end:var(--s4)}
.stages li::before{content:"";position:absolute;inset-inline-start:1.25rem;inset-block:2.6rem 0;border-inline-start:2px dashed #000}
.stages li.done::before{border-inline-start-style:solid}
.stages li:last-child::before{content:none}
.stages .n{grid-row:span 2;inline-size:2.6rem;block-size:2.6rem;display:grid;place-items:center;border:var(--rule);border-radius:50%;background:#fff;font-family:var(--doc);font-weight:700;font-size:1.3rem;line-height:1;padding-block-start:.2rem}
.stages .done .n{background:#000;color:#fff;padding:0}
.stages b{align-self:end;line-height:1.4}
.stages small{font-size:.84rem;line-height:1.4}
@media(min-width:60rem){
  .stages{grid-template-columns:repeat(6,minmax(0,1fr))}
  .stages li{display:block;text-align:center;padding:0 var(--s2)}
  .stages li::before{inset-block:1.3rem auto;inset-inline:calc(50% + 1.3rem) calc(-50% + 1.3rem);border-inline-start:0;border-block-start:2px dashed #000}
  .stages li.done::before{border-block-start-style:solid}
  .stages .n{margin:0 auto var(--s2);position:relative}
  .stages b,.stages small{display:block}
}

/* ================= forms ================= */
form.inline{display:inline}
.form{display:grid;gap:var(--s3) var(--s5);margin-block-end:var(--s4)}
@media(min-width:44rem){.form{grid-template-columns:repeat(2,minmax(0,1fr))}.form .wide,.form>h3,.form>.actions,.form>fieldset,.form>p{grid-column:1/-1}.form.three{grid-template-columns:repeat(3,minmax(0,1fr))}}
.form>h3{margin:var(--s3) 0 0;padding-block-end:var(--s1);border-block-end:var(--hair)}
.fld label{display:block;font-weight:600;font-size:.9rem;margin-block-end:.2rem}
.fld.chk label{font-weight:400;display:flex;gap:var(--s2);align-items:center;min-block-size:44px;flex-wrap:wrap}
.req{font-weight:700}
.hint{display:block;font-size:.84rem;line-height:1.5}
input,select,textarea,button{font:inherit;color:#000}
input:not([type=checkbox]):not([type=radio]),select,textarea{inline-size:100%;min-block-size:46px;padding:.45rem .8rem;border:1.5px solid #000;border-radius:var(--r-s);background:#fff}
input:focus,select:focus,textarea:focus{outline:3px solid #000;outline-offset:2px}
input[type=checkbox],input[type=radio]{inline-size:1.35rem;block-size:1.35rem;accent-color:#000;flex:none}
input[type=file]{padding:.55rem;border-style:dashed}
textarea{line-height:1.65;resize:vertical}
fieldset{border:var(--hair);border-radius:var(--r);padding:var(--s3) var(--s4);margin:0}
legend{font-weight:700;padding-inline:var(--s2)}
.btn{display:inline-flex;align-items:center;justify-content:center;gap:var(--s2);min-block-size:46px;padding:.35rem 1.3rem;border:var(--rule);border-radius:999px;background:#fff;color:#000;font-weight:700;text-decoration:none;cursor:pointer;line-height:1.3;transition:transform .12s ease}
/* The primary button: the brand red, white label, and the edge a darker red rather than black — one
   colour with its own outline, which is what distinguishes it from the plain button beside it. */
.btn.primary{background:var(--brand);color:var(--brand-ink);border-color:var(--brand-line)}
.btn:hover{background:#000;color:#fff}
.btn.primary:hover{background:var(--brand-line);color:#fff;border-color:var(--brand-line)}
.btn:active{transform:scale(.97)}
.btn.small{min-block-size:42px;padding:.15rem .95rem;font-size:.86rem;border-width:1.5px}
.btn.danger{border:4px solid transparent;background:linear-gradient(#fff 0 0) padding-box,var(--hatch) border-box;color:#000}
.btn.danger:hover{background:#000;color:#fff;border-color:#000}
.btn.invert{background:#fff;color:#000;border-color:#fff}
.btn.invert:hover{background:#000;color:#fff}
.btn.ghost{background:#000;color:#fff;border-color:#fff}
.btn.ghost:hover{background:#fff;color:#000}
.flash{display:flex;gap:var(--s3);border:var(--rule);border-radius:var(--r);padding:var(--s3) var(--s4);margin-block-end:var(--s4);font-weight:600}
.flash.ok{background:#000;color:#fff}
.flash.err{border:5px solid transparent;background:linear-gradient(#fff 0 0) padding-box,var(--hatch) border-box}
.flash.warn{border-style:dashed}
.tabs{display:flex;gap:var(--s1);overflow-x:auto;margin:0 0 var(--s5);padding:var(--s1);list-style:none;border:var(--hair);border-radius:999px;inline-size:fit-content;max-inline-size:100%;scrollbar-width:none}
.tabs::-webkit-scrollbar{display:none}
.tabs a{display:flex;align-items:center;gap:var(--s2);padding:.3rem 1rem;border-radius:999px;text-decoration:none;font-weight:600;font-size:.92rem;min-block-size:42px;white-space:nowrap}
.tabs a:hover{box-shadow:inset 0 0 0 1.5px #000}
.tabs a[aria-current=page]{background:#000;color:#fff}
.tabs .count{background:#fff;color:#000;border-radius:999px;padding:0 .45rem;font-size:.78rem}
.tabs a:not([aria-current]) .count{background:#000;color:#fff}
.feed{list-style:none;margin:0;padding:0}
.feed li{padding:.6rem 0;border-block-end:1px dotted #000}
.feed li:last-child{border-block-end:0}
/* Secondary text in grey rather than black: 4.6:1 on white, so it still carries small print. */
.feed time,.meta{font-size:.82rem;display:block;color:var(--g3)}
.hint{color:var(--g3)}
.unread{font-weight:700}
.unread::before{content:"";display:inline-block;inline-size:.55rem;block-size:.55rem;border-radius:50%;background:#000;margin-inline-end:var(--s2)}
.msg{border-inline-start:3px solid #000;padding-inline-start:var(--s4);margin-block-end:var(--s4)}
.qr{inline-size:11rem;block-size:11rem;display:block}
/* A QR that is also a link. No underline — the code is the target, not the text — and the red
   ring only on hover, so the printed sheet keeps a plain black-and-white code. */
.qr-link{display:inline-block;line-height:0;text-decoration:none;border-radius:6px}
.qr-link:hover,.qr-link:focus-visible{box-shadow:0 0 0 3px var(--brand)}
/* On the badge the ring is drawn inside the link instead: the card clips what overflows it, and
   a ring that is cut on one side reads as a mistake rather than as a state. The code keeps its
   quiet zone because the ring sits on the padding, not on the modules. */
.idcard .qr-link{padding:1.2mm;background:#fff;border-radius:1.5mm}
.idcard .qr-link:hover,.idcard .qr-link:focus-visible{box-shadow:inset 0 0 0 2px var(--brand)}
code,.mono{font-family:ui-monospace,"SF Mono",Consolas,monospace;font-size:.86em;word-break:break-word;direction:ltr;unicode-bidi:isolate}

/* ================= room day view ================= */
.day{display:grid;grid-auto-flow:column;grid-auto-columns:minmax(14rem,1fr);gap:var(--s3);overflow-x:auto;padding-block-end:var(--s3);margin-block-end:var(--s5);scroll-snap-type:inline proximity}
.day>div{border:var(--hair);border-radius:var(--r);padding:var(--s3);min-block-size:11rem;scroll-snap-align:start}
.day h3{font-size:1.08rem;border-block-end:var(--hair);padding-block-end:var(--s2);margin-block-end:var(--s2)}
.slot{border:1.5px solid #000;border-radius:var(--r-s);padding:var(--s2) var(--s3);margin-block-end:var(--s2);font-size:.88rem;line-height:1.6}
.slot.booked{background:#000;color:#fff}
.slot.booked .badge{border-color:#fff}
.slot.tentative{border-style:dashed}
.slot b{display:block;font-variant-numeric:tabular-nums;font-size:1rem}

/* ================= sign-in ================= */
.gatepage{min-block-size:100vh;display:grid}
.gate{display:grid;min-block-size:100vh}
/* Anchored to the end, not spread. This column used to hold the KCST lockup at the top and the
   ORIS block at the bottom, and `space-between` did that for free; with the lockup gone it would
   have pushed the single remaining block to the TOP of the panel. */
.gate-brand{position:relative;overflow:hidden;background:#000;color:#fff;padding:var(--s5);display:flex;flex-direction:column;justify-content:flex-end;gap:var(--s4);min-block-size:15rem}
.gate-brand .motif{position:absolute;inset-inline:0;inset-block-start:22%;inline-size:100%;block-size:46%}
.gate-brand div{position:relative}
.gate-brand .mark{font-family:var(--doc);font-weight:700;font-size:clamp(3.4rem,2.4rem + 6vw,7rem);line-height:1;margin:0;letter-spacing:.03em}
.gate-brand .unit{margin:var(--s2) 0 0;font-size:1.05rem;max-inline-size:28ch}
/* The signature, at the foot of the panel. Quiet — it names the system and its version, which is
   reference rather than greeting — but white at 21:1 on this black, because a version somebody
   is asked to quote has to be legible rather than decorative. */
.gate-sig{position:relative;margin:var(--s5) 0 0;font-size:.9rem;letter-spacing:.01em;
  padding-block-start:var(--s3);border-block-start:1px solid rgba(255,255,255,.25)}
.gate-sig span{font-variant-numeric:tabular-nums;unicode-bidi:isolate}
.gate-form{padding:var(--s6) var(--s5);display:flex;flex-direction:column;justify-content:center;inline-size:100%;max-inline-size:30rem;margin-inline:auto}
.gate-form h1{margin-block-end:var(--s5)}
.gate-form .form{grid-template-columns:1fr}
.gate-form .btn.primary{inline-size:100%}
.gate-lang{margin-block-start:var(--s5)}
@media(min-width:56rem){.gate{grid-template-columns:minmax(0,1.1fr) minmax(0,1fr)}.gate-brand{padding:var(--s7)}}

/* ================= printed documents ================= */
.dochead{display:none}
.doc{font-family:var(--doc);font-size:1.1rem;line-height:1.85;max-inline-size:52rem}
.doc h2{font-size:1.3rem;border-block-end:var(--hair);margin-block-start:var(--s5);display:block}
.doc .panel{border-radius:0;border-width:0 0 1px;padding:var(--s2) 0;margin:0}
.doc .badge{border-radius:0}
.doc .dochead{display:flex;gap:var(--s4);align-items:center;border-block-end:var(--heavy);padding-block-end:var(--s3);margin-block-end:var(--s4);position:relative}
.doc .dochead::after{content:"";position:absolute;inset-inline:0;inset-block-end:-9px;border-block-end:var(--hair)}
.doc .dochead img{inline-size:15rem;block-size:auto}
.doc .dochead h1{font-size:1.6rem;margin:0}
.doc .dochead p{margin:0}
.sigs{display:grid;grid-template-columns:repeat(2,1fr);gap:var(--s5) var(--s6);margin-block-start:var(--s4)}
.sig{break-inside:avoid}
.sig .line{border-block-end:var(--hair);block-size:2.6rem;margin-block-end:var(--s1)}
.seal{display:flex;gap:var(--s4);align-items:center;border:var(--rule);padding:var(--s3);margin-block-start:var(--s5);break-inside:avoid}
.seal .qr{inline-size:6.5rem;block-size:6.5rem;flex:none}

@page{size:A4 portrait;margin:16mm 15mm}
@page minute{size:A4 portrait;margin:16mm 15mm}
@page report{size:A4 portrait;margin:14mm 14mm}
@page wide{size:A4 landscape;margin:12mm}
/* Named page boxes, and why they are declared on the body as well.
   `.doc-report{page:report}` names the page box for the <article> that carries the report. But
   the article is not the last thing in the document — <main> and <body> continue past it, and
   they belong to the unnamed @page. A change of page name forces a page break, so the moment
   the article ended the engine opened a fresh sheet under the default box to hold whatever came
   next. Nothing came next: everything after the article is display:none in print. The result was
   one empty sheet at the end of every report, immediately after the seal, which is exactly where
   Dr Basil's preview showed it.
   Naming the box on the body too means there is no change of name to break on. */
.doc-minute{page:minute}.doc-report{page:report}.doc-wide{page:wide}
@media print{
  body:has(.doc-minute){page:minute}
  body:has(.doc-report){page:report}
  body:has(.doc-wide){page:wide}
}
@media print{
  .no-print,.top,.side,.tabbar,.foot,.skip,.flash,form,.btn,.tabs,.actions,details>summary{display:none!important}
  /* .shell and main lose their boxes entirely further down; this only keeps anything that
     reads them before that from re-introducing a width or a padding. */
  main{padding:0;max-inline-size:none}
  body{font-size:11pt}
  .doc{max-inline-size:none;font-size:12pt}
  a{text-decoration:none}
  .panel,.day>div,.figs div{border-radius:0;box-shadow:none!important}
  tr,.panel,.sig{break-inside:avoid}
  h2,h3{break-after:avoid}
  .day{grid-auto-flow:row;grid-template-columns:repeat(4,1fr);overflow:visible}
  *{-webkit-print-color-adjust:exact;print-color-adjust:exact}
  /* ---- no blank sheet at the end ----
     The real cause was not a stray margin. Every data table in this application sits inside
     `.tw`, which carries `overflow-x:auto` so a wide table can be scrolled on a phone. An
     element whose overflow is anything but `visible` is a scroll container, and a scroll
     container is *monolithic* to a print engine: it cannot be divided across two sheets. So on
     paper the engine had to place each table whole. A table taller than what was left on the
     page was pushed to the next one, and a table taller than a whole page was pushed to a sheet
     it still did not fit on — which is where both the trailing blank sheet and the quietly
     clipped rows came from. One is annoying and the other loses data, and they had one cause.
     On paper there is nothing to scroll, so every scroll container becomes an ordinary box and
     the tables break across sheets the way they should. */
  .tw,.board,.day,.awmap,.scroll-x{overflow:visible!important}
  /* A table divided across sheets repeats its headings, so the second sheet is readable on its
     own — which is the whole point of letting it divide. */
  thead{display:table-header-group}
  tfoot{display:table-footer-group}
  tr{break-inside:avoid}
  /* And the margins, which were the original suspect and are worth keeping flattened anyway:
     a few millimetres past the last page box is still answered with a whole extra sheet. */
  html,body{block-size:auto;margin-block-end:0;padding-block-end:0}
  .doc{margin-block-end:0;padding-block-end:0}
  .doc>*:last-child,.seal:last-child,section:last-of-type{margin-block-end:0}
  .seal{break-inside:avoid;break-after:avoid-page;margin-block-end:0}
  .doc>*:last-child,article>*:last-child{margin-block-end:0;padding-block-end:0}
  .doc::after,main::after,body::after{content:none}
  /* ---- nothing after the last line ----
     This is the fourth attempt at the blank final sheet, and the first that stops arguing with
     the boxes and removes them.

     Earlier passes closed three real causes — a named @page box ending before the document did,
     a scroll container that cannot be split, and trailing margins — and each time a sheet came
     back. The reason is that `main` is not the document: `<main>` wraps the article AND the
     site footer, carries 7rem of bottom padding for the mobile tab bar, and sits inside
     `.shell`. Every rule aiming at «the last thing printed» was therefore aiming at a hidden
     footer, and `main>*:last-child` never once selected the article. Zeroing the padding of a
     box is also not the same as the box not being there: it still ends where it ends, still
     takes part in fragmentation, and still answers a few tenths of a millimetre of overflow
     with a whole sheet of paper.

     `display:contents` makes `.shell` and `main` generate no box at all. Their padding, their
     margins and their fragmentation behaviour go with them, and the article becomes a direct
     child of <body> — so the last box in the document is the seal, and there is nothing after
     it to put on another sheet. Everything else inside main is already `display:none` above,
     so nothing is lost by their boxes going.

     The blanket `break-after:avoid-page` that used to be here is gone with them: «avoid a break
     after me» on body, main and .shell was asking three boxes that no longer exist to promise
     something about a break that no longer has anywhere to happen. It stays only on the seal,
     which is a statement about the seal. */
  .shell,main{display:contents}
  .doc>*:last-child,article>*:last-child,
  .doc>*:last-child>*:last-child{margin-block-end:0!important;padding-block-end:0!important}
  /* An element left empty by the rules above still occupies a line, and a line is enough to
     start a sheet. */
  .doc>*:last-child:empty,article>*:last-child:empty{display:none}
}
@media(prefers-reduced-motion:reduce){*{transition:none!important;animation:none!important}}

/* ================= signatures and endorsements ================= */
.sigpad{display:block;inline-size:100%;max-inline-size:600px;aspect-ratio:3/1;block-size:auto;border:2px dashed #000;border-radius:var(--r);background:#fff;touch-action:none;cursor:crosshair;margin-block-end:var(--s3)}
.sig-box{border:var(--hair);border-radius:var(--r);padding:var(--s2);max-inline-size:22rem;background:#fff}
.sig-img{display:block;inline-size:100%;max-inline-size:14rem;block-size:auto}
table.endorse .sig-img{max-inline-size:9rem}
.sig .line{display:flex;align-items:end;block-size:3.2rem}
.sig .line .sig-img{max-inline-size:9rem;max-block-size:3.1rem}
.seal-img{inline-size:6.5rem;block-size:6.5rem;flex:none}
.flash .ic{margin-block-start:.15rem}

/* ================= academic profile ================= */
.prof-head{display:flex;flex-wrap:wrap;gap:var(--s4) var(--s5);align-items:center;margin-block-end:var(--s5);padding:var(--s4);border:var(--rule);border-radius:calc(var(--r) + 4px)}
.prof-head h1{margin:0}
.prof-head p{margin:0}
.prof-head .role{font-weight:700}
/* Choosing a photo: the one in use, centred and round above the picker, at the size it is
   actually shown. The field inside stays a normal field — only the column is centred. */
.photo-field{display:flex;flex-direction:column;align-items:center;gap:var(--s3);text-align:center}
.photo-field .avatar{margin:0}
.photo-field .fld{inline-size:100%;max-inline-size:28rem;text-align:start}
/* ================= the committee board =================
   Five columns, scrolled sideways on a narrow screen. They are told apart by the weight of the
   rule above each — a hairline for what has not started, heavy for what is in hand, a dashed
   rule for what is parked — rather than by five hues, because this interface decided long ago
   that a state is a word and a shape, and because the red is the only colour it has. */
.board{display:grid;grid-auto-flow:column;grid-auto-columns:minmax(15rem,1fr);gap:var(--s3);overflow-x:auto;padding-block-end:var(--s2);margin-block-end:var(--s5)}
/* Each column carries its own colour, as the design asks. Two tones per column: --ink for the
   heading, the dot, the count and the card's edge; --tint for the column behind them. Every ink
   clears 4.5:1 on both its own tint and on the white card, so the colour is decoration over a
   layout that already works — the heading still says which column it is, and the rule weight
   under it still distinguishes them on a greyscale printer. */
.col{background:var(--tint);border-radius:var(--r);padding:var(--s3);min-block-size:12rem;--ink:var(--g3);--tint:var(--g1)}
.col[data-col=open]{--ink:#6f6f6f;--tint:#f0f0f0}
.col[data-col=doing]{--ink:var(--brand-line);--tint:var(--brand-wash)}
.col[data-col=review]{--ink:#8a8a8a;--tint:#f4f4f4}
.col[data-col=done]{--ink:#3a3a3a;--tint:#eeeeee}
.col[data-col=deferred]{--ink:#5d5e5e;--tint:#f1f1f1}
.col>h3{display:flex;align-items:center;gap:var(--s2);font-family:var(--ui);font-size:.86rem;font-weight:700;margin:0 0 var(--s3);padding-block-end:var(--s2);color:var(--ink);border-block-end:2px solid var(--ink)}
/* The dot the reference puts beside each column name. */
.col>h3::after{content:"";inline-size:.55rem;block-size:.55rem;border-radius:50%;background:var(--ink);flex:none;order:3}
.col>h3 .n{order:2;margin-inline-start:auto;font-variant-numeric:tabular-nums;min-inline-size:1.7rem;text-align:center;border-radius:999px;background:var(--ink);color:#fff;font-size:.78rem;line-height:1.5}
.col[data-col=deferred]>h3{border-block-end-style:dashed}
.cards{list-style:none;margin:0;padding:0;display:grid;gap:var(--s2);min-block-size:4rem}
/* A white card on the tint, with its column's colour down the inline-end edge — the bar the
   reference draws beside each card. */
.card{background:#fff;border:1px solid var(--g2);border-inline-end:4px solid var(--ink);border-radius:var(--r-s);padding:var(--s3);cursor:grab}
.card:active{cursor:grabbing}
.card b{display:block;line-height:1.4}
.card .meta{margin-block-start:.2rem}
.card .late{font-weight:700;text-decoration:underline;text-decoration-style:wavy}
.card .move{display:flex;gap:var(--s2);align-items:center;margin-block-start:var(--s2)}
.card .move select{flex:1 1 auto;min-inline-size:0;padding:.2rem .4rem;font-size:.82rem}
.card .move .btn{min-block-size:32px;padding:.1rem .7rem}
.card details{margin-block-start:var(--s2)}
.cards .empty{color:var(--g3);font-style:italic;padding:var(--s2)}
/* Where a card would land: the column's own colour, drawn inside its edge. */
.col.over{box-shadow:inset 0 0 0 2px var(--ink)}
.card.dragging{opacity:.5}
@media print{.board{grid-auto-flow:row;overflow:visible}.card{break-inside:avoid}.card .move{display:none}}

/* ================= the awards map =================
   Drawn here, not fetched: the content policy forbids this page reaching another host, and a
   map of twenty countries does not need a tile server. A graticule rather than coastlines,
   because the question it answers is which country, not what shape it is. Each marker is a
   link that filters the list, so the map navigates rather than decorates. */
.awmap{border:var(--hair);border-radius:var(--r);background:var(--g1);padding:var(--s3);margin-block-end:var(--s4);overflow-x:auto}
.awmap svg{inline-size:100%;block-size:auto;min-inline-size:34rem;display:block}
.awmap .grid{stroke:var(--g2);stroke-width:.4}
.awmap .equator{stroke:var(--g3);stroke-width:.5;stroke-dasharray:2 2}
.awmap .mark{fill:var(--brand);fill-opacity:.75;stroke:#000;stroke-width:.6;transition:fill-opacity .12s ease}
.awmap a:hover .mark,.awmap a:focus-visible .mark{fill-opacity:1;stroke-width:1.2}
.awmap .mark.on{fill:#000;fill-opacity:1}
.awmap .cnt{font-size:4px;font-weight:700;fill:#fff;text-anchor:middle;pointer-events:none;font-family:var(--ui)}
.awmap a{cursor:pointer}

/* A value worth taking whole — the one-time password. It reads as a field rather than a button,
   because that is what it is; the press is a convenience over selecting it. */
button.copy{display:inline-flex;align-items:center;gap:var(--s2);margin-inline-start:var(--s2);padding:.15rem .6rem;border:var(--hair);border-radius:var(--r-s);background:#fff;cursor:pointer;font:inherit;vertical-align:middle}
button.copy code{font-family:ui-monospace,Consolas,monospace;font-size:.95rem;font-weight:700;letter-spacing:.02em;direction:ltr;unicode-bidi:isolate}
button.copy:hover,button.copy:focus-visible{background:var(--brand);color:var(--brand-ink)}
button.copy.is-copied{background:#000;color:#fff;border-color:#000}
.copied{display:inline-block;margin-inline-start:var(--s2);font-size:.82rem;font-weight:700}
/* Research interests, one tag each. Outlined, not filled: they name a subject, not a state. */
.tags{display:flex;flex-wrap:wrap;gap:var(--s2);margin-block-start:var(--s2)!important}
.tags span{font-size:.82rem;font-weight:600;padding:.1rem .6rem;border:1px solid #000;border-radius:999px}
/* The ring round a face is the brand red: it frames the person rather than ruling them off, and it is
   the one place the colour touches somebody's photograph. */
.avatar{inline-size:7rem;block-size:7rem;border-radius:50%;object-fit:cover;border:2px solid var(--brand);flex:none;background:#fff}
.avatar.initials{display:grid;place-items:center;background:#000;color:#fff;font-family:var(--doc);font-weight:700;font-size:3rem;line-height:1;padding-block-start:.3rem}
/* ---- the CV, in the institutional red ----
   A CV is read by scanning for the headings, so the headings are what carries the colour: the
   name, each section title, each year, and the hairline under them. Everything that is
   evidence — the prose, the figures, the publications — stays black, because that is what has
   to survive a photocopier and a grey printer. One accent, used only to mark structure. */
/* The person, at the top: the photograph, the name in red, the rank, the department. Tight —
   a CV's first screen should be the person and then the evidence, not air. */
.cv .prof-head{border-width:0 0 1px;border-color:var(--brand);border-radius:0;padding:0 0 var(--s3);margin-block-end:var(--s4);gap:var(--s4);align-items:center}
.cv .prof-head h1{color:var(--brand);font-size:1.9rem;margin:0 0 .1rem}
.cv .prof-head .role{font-family:var(--ui);font-size:1rem;margin:0}
.cv .prof-head .dept{font-size:1rem;margin:.1rem 0 0}
.cv .avatar{inline-size:5.6rem;block-size:5.6rem}
/* ---- one theme for every document this system issues ----
   The CV set it; the committee report, the minute, the proposal and the faculty reports now
   read the same way, because they go out under the same letterhead and a reader should not have
   to learn a second set of conventions to read the second one. Headings in red with a red
   hairline, evidence in black, a light letterhead. Scoped to .doc, so it reaches every printed
   view at once and nothing on screen changes. */
.doc .dochead{border-block-end:2px solid var(--brand);padding-block-end:var(--s2);margin-block-end:var(--s4)}
.doc .dochead::after{content:none}
.doc .dochead img{inline-size:12rem}
.doc .dochead h1{font-size:1.25rem;color:#000}
.doc section{margin-block-end:var(--s4)}
.doc h2{color:var(--brand);border-block-end:1px solid var(--brand);padding-block-end:.15rem;font-size:1.1rem;margin-block:var(--s4) var(--s2)}
.doc h2::before{content:none}            /* the black tab beside a heading belongs on screen */
.doc h3{color:var(--brand);font-size:1rem;margin-block:var(--s3) var(--s1)}
/* One rule under the heading row, in the red. The black bars a table carries on screen are
   dropped here: two heavy lines and a red one between them is three rules doing one job. */
.doc table.data{border-block:0}
.doc tfoot td,.doc tfoot th{border-block-start:1px solid var(--brand)}
.doc thead th{background:transparent;color:var(--brand);border-block-end:1px solid var(--brand);font-family:var(--ui);font-size:.82rem}
.doc tbody tr:nth-child(even)>*{background:transparent}
.doc tbody tr+tr>*{border-block-start:1px dotted var(--g2)}
/* A figure sits under its own heading. Same reason as the identity list: an isolated Latin run
   is placed by the bidi algorithm, so it is made an atomic box and then the column's alignment
   applies to it — the date lands under «بتاريخ» rather than beside it. */
.doc .data .mono{display:inline-block}
.doc .count-b{background:var(--brand);color:var(--brand-ink)}
.doc .seal{border-color:var(--brand)}
/* The prose of a document fills its measure. `.lede` is capped at 70ch for reading on screen,
   which on paper leaves a column of text narrower than the table beneath it. */
.doc .lede{max-inline-size:none;margin-block-end:0;text-align:justify}
/* ---- the CV's own part: the person at the top, and the publication list ---- */
.cv .yr{color:var(--brand);border-block-end:1px solid var(--brand);font-size:1.05rem;margin:var(--s4) 0 var(--s2)}
.cv ol.pubs li{margin-block-end:var(--s3)}
.cv ol.pubs li b{font-family:var(--ui);font-size:.95rem}
.cv ol.pubs .auth{color:var(--brand);font-style:italic;font-size:.88rem}
.cv ol.pubs .meta{font-size:.85rem}
.cv .idlist dt{color:var(--g3)}
.cv .tags span{border-color:var(--brand)}
/* The letterhead: College above, Office beneath it, as the printed paper has it. */
.doc .dochead .mast{display:flex;flex-direction:column;gap:.25rem;flex:none}
.doc .dochead .mast .unit{font-weight:600;font-size:.9rem}
/* The identifiers: label and value on one line, a hairline between, no box. A CV is a document,
   not a form, and four facts do not need ruling off from the page. */
.idlist{display:grid;grid-template-columns:auto 1fr;gap:0 var(--s5);margin:0 0 var(--s4);font-family:var(--ui);font-size:.92rem}
.idlist dt{grid-column:1;font-weight:600;color:var(--g3);white-space:nowrap;padding:.42rem 0;border-block-end:1px solid var(--g2)}
/* The value begins where the label left off, not at the far edge of the page.
   An address or an employee number is Latin, so `.mono` carries direction:ltr and an isolate —
   and an isolated inline run is placed by the bidi algorithm, not by text-align, which is why
   asking for an alignment did not move it. A flex row settles the question at box level
   instead: flex-start follows the writing direction, so the value sits at the right in Arabic
   and at the left in English, while the text inside it still reads left-to-right either way. */
.idlist dd{grid-column:2;margin:0;padding:.42rem 0;border-block-end:1px solid var(--g2);min-inline-size:0;display:flex;justify-content:flex-start}
/* A flex item will not shrink below its content unless told to, and a Scholar address is long
   enough to push the page sideways if it is not allowed to break. */
.idlist dd>*{min-inline-size:0;overflow-wrap:anywhere}
.idlist dt:last-of-type,.idlist dd:last-of-type{border-block-end:0}
.brk{word-break:break-all}
/* The publication count, beside the heading rather than buried in the text. */
.count-b{font-family:var(--ui);font-size:.95rem;font-weight:700;padding:.05rem .55rem;border-radius:999px;background:var(--brand);color:#fff;vertical-align:.2em}
.yr{font-family:var(--ui);font-size:1rem;font-weight:700;margin:var(--s4) 0 var(--s2);padding-block-end:.15rem;border-block-end:var(--rule)}
ol.pubs{margin:0;padding-inline-start:1.4rem}
ol.pubs li{margin-block-end:var(--s3);line-height:1.6}
ol.pubs li b{font-weight:700}
ol.pubs .meta{display:block}
ol.pubs .auth{font-style:italic}
.cv section{margin-block-end:var(--s4)}
.cv section>h2::before{content:none}
.cv .figs div{border-radius:0}

/* ================= public business card ================= */
.plainpage{background:#fff}
.plain{inline-size:min(100%,34rem);margin-inline:auto;padding:var(--s4) var(--s4) var(--s6)}
.plain-foot{display:flex;flex-wrap:wrap;align-items:center;justify-content:space-between;gap:var(--s3);margin-block-start:var(--s5);padding-block-start:var(--s3);border-block-start:var(--hair)}
.plain-foot img{inline-size:min(60%,13rem);block-size:auto}
.vcard{border:var(--rule);border-radius:calc(var(--r) + 8px);overflow:hidden;text-align:center}
.vcard-top{position:relative;background:#000;color:#fff;block-size:8.5rem;overflow:visible}
.vcard-top .motif{position:absolute;inset:0;inline-size:100%;block-size:100%}
.vcard-top .mark{position:absolute;inset-block-start:var(--s3);inset-inline-start:var(--s4);font-family:var(--doc);font-weight:700;font-size:1.5rem;letter-spacing:.05em}
.vcard-top .avatar{position:absolute;inset-inline-start:50%;inset-block-end:-3.5rem;transform:translateX(-50%);box-shadow:0 0 0 5px #fff}
[dir=rtl] .vcard-top .avatar{transform:translateX(50%)}
.vcard-body{padding:4.4rem var(--s4) var(--s4)}
.vcard-body h1{margin:0}
.vcard-body .role{font-weight:700;margin:0}
.vcard-body .bio{text-align:start;border-block-start:var(--hair);padding-block-start:var(--s3)}
.vcard-body dl.kv{text-align:start;margin-block-start:var(--s4)}
.btn.big{inline-size:100%;min-block-size:56px;font-size:1.1rem;margin-block:var(--s3)}
.actions.center{justify-content:center}
.vcard-qr{display:grid;justify-items:center;margin-block-start:var(--s4);padding-block-start:var(--s4);border-block-start:var(--hair)}
.vcard-qr .qr{inline-size:9rem;block-size:9rem}

/* ================= printed cards: ID (85.6 × 54 mm) and business card (90 × 55 mm) ================= */
.idcard{inline-size:85.6mm;block-size:54mm;max-inline-size:100%;color:#000;border:1.5px solid var(--brand-line);border-radius:3.2mm;overflow:hidden;background:#fff;display:grid;grid-template-rows:13mm 1fr;font-family:var(--ui);line-height:1.25;margin-block-end:var(--s3)}
/* White, so the lockup on it is the approved one rather than a variant made to survive a
   dark ground. The rule beneath is the brand red the printed letterhead already draws
   under itself: the bar and the body are both white now, so something has to separate
   them, and repeating the letterhead's rule makes the card read as the same stationery. */
.idcard-top{background:#fff;color:#000;border-block-end:.4mm solid var(--brand);display:flex;align-items:center;justify-content:space-between;padding:0 4mm}
.idcard-top img{block-size:6.5mm;inline-size:auto}
.idcard-top span{font-family:var(--doc);font-weight:700;font-size:13pt;letter-spacing:.06em;color:var(--brand)}
.idcard-body{display:grid;grid-template-columns:20mm 1fr 20mm;gap:3mm;align-items:center;padding:3mm 4mm}
.idcard .avatar{inline-size:20mm;block-size:20mm;border-radius:2mm;border-width:1px}
.idcard .avatar.initials{font-size:22pt}
.idcard b{display:block;font-size:9.5pt}.idcard span[dir]{display:block;font-size:9pt}
.idcard small{display:block;font-size:6.5pt;color:#000}
/* The staff number carries the institution's red: white on it, edged in the darker red —
   the same rule the buttons follow, so the badge reads as part of the same system.
   White on this red is 6.22:1, where the gold it replaces was 4.03:1 and could carry a short
   bold label but not running text. This one has no such limit. */
.idcard em{display:inline-block;margin-block-start:1.2mm;padding:.4mm 1.8mm;background:var(--brand);color:var(--brand-ink);border:1px solid var(--brand-line);font-style:normal;font-weight:700;font-size:7pt;border-radius:1mm}
.idcard .qr{inline-size:20mm;block-size:20mm}
/* The code's column is 20mm wide, and the padded link that carries the ring must fit in it
   rather than push the name out of the way, so the code gives back exactly what the padding
   takes. */
.idcard .qr-link .qr{inline-size:17.6mm;block-size:17.6mm}
.bcards{display:flex;flex-wrap:wrap;gap:var(--s4);margin-block-end:var(--s3)}
.bcard{position:relative;overflow:hidden;inline-size:90mm;block-size:55mm;max-inline-size:100%;border:1px solid #000;border-radius:2mm;padding:6mm;display:flex;flex-direction:column;justify-content:space-between;font-family:var(--ui);line-height:1.3}
/* Likewise white. The motif follows currentColor, so on a white face it is set to the
   hairline grey and reads as a watermark instead of taking the card over. */
.bcard.front{background:#fff;color:#000}
.bcard.front .motif{position:absolute;inset:0;inline-size:100%;block-size:100%;color:var(--g2)}
.bcard.front img{position:relative;inline-size:46mm;block-size:auto}
.bcard.front div{position:relative}
.bcard b{display:block;font-family:var(--doc);font-size:14pt;line-height:1.2}
.bcard small{display:block;font-size:7.5pt}
.bcard.back{flex-direction:row;align-items:center;gap:5mm}
.bcard.back .qr{inline-size:26mm;block-size:26mm;flex:none}
.bcard.back em{display:inline-block;margin-block-start:2mm;font-family:var(--doc);font-style:normal;font-weight:700;font-size:12pt;letter-spacing:.06em}
@page idcard{size:85.6mm 54mm;margin:0}
@page bcard{size:90mm 55mm;margin:0}
.doc-id{page:idcard}.doc-bcard{page:bcard}
@media print{
  .doc-id .idcard,.doc-bcard .bcard{border:0;border-radius:0;margin:0;break-after:page}
  .doc-bcard .bcards{display:block;margin:0}
  .doc-id,.doc-bcard{margin:0}
}
/* The name sits on an opaque panel so the motif does not run through the lettering. It was
   #000 because the card was: invisible against the face, doing its job silently. With a white
   face it has to be white, or it is a black blot across the card. */
.bcard.front div{align-self:flex-start;background:#fff;padding:1.5mm 3mm 1mm 0}
.idcard-body>div{min-inline-size:0}

/* ── شهادة — the certificate sheet ───────────────────────────────────────────────────────────────
   Landscape, and it has to be said in a named page box rather than on the unnamed one: the
   unnamed box is a statement about every page in the platform, and the minute, the report and the
   identity card each want something different. A named box also forces a page break when it ends,
   which is why `.doc-cert` is named on the body too — the same empty trailing sheet that was
   fixed for the report would otherwise appear here.

   The whole sheet is one column, centred, because a certificate is read from the middle outwards:
   whose it is, then what it says, then who stands behind it. */
.doc-cert{page:cert;max-inline-size:68rem;text-align:center;margin-inline:auto}
.doc-cert .doc-head{display:flex;justify-content:space-between;align-items:flex-start;gap:var(--s4);text-align:start;border-block-end:var(--heavy);padding-block-end:var(--s2);margin-block-end:var(--s4)}
.doc-cert .doc-org b{display:block;font-size:1.15rem}
.doc-cert .doc-org span{display:block;font-size:.9rem}

/* The verdict bar, for whoever followed a link rather than being handed the paper. Never printed:
   a sheet carrying the words «this is valid» in its own margin proves nothing, because a
   withdrawn one carried them too on the day it was printed. */
.cert-verdict{display:flex;flex-direction:column;gap:.2rem;text-align:start;border:var(--heavy);padding:var(--s2) var(--s3);margin-block-end:var(--s4)}
.cert-verdict.is-bad{border-style:dashed}
.cert-verdict span{font-size:.95rem}

.cert-kicker{font-size:1rem;letter-spacing:.08em;text-transform:uppercase;margin:0 0 .2rem}
.cert-title{font-size:2.1rem;line-height:1.25;margin:0 0 var(--s3);border:0}
.cert-lede{font-size:1rem;margin:0 0 var(--s3)}

/* The name, and the one thing on the sheet that is allowed to resize itself. --nf is set in the
   markup from the length of the name: a name longer than the line shrinks rather than wrapping,
   because a wrapped name costs more height than the sheet has spare and would push one attendee
   onto a second page. Floored in PHP at 0.70 — still the largest thing here. */
.cert-who{font-size:calc(2.6rem * var(--nf, 1));line-height:1.2;margin:0}
.cert-who b{font-weight:700}
.cert-underline{inline-size:min(34rem, 80%);margin:.4rem auto var(--s3);border-block-end:var(--heavy)}

.cert-body{font-size:1.1rem;margin:0 auto var(--s2);max-inline-size:46rem}
.cert-extra,.cert-detail{font-size:1rem;margin:0 auto var(--s2);max-inline-size:46rem}
.cert-detail{font-style:italic}

/* The strip of facts: everything a reader checks at a glance, on one line. The label sits UNDER
   the value, which is the wrong way round for a form and the right way round here — the eye is
   looking for the date, not for the word «date». */
.cert-meta{display:flex;flex-wrap:wrap;justify-content:center;gap:var(--s3) var(--s5);margin-block:var(--s4);border-block:var(--hair);padding-block:var(--s2)}
.cert-meta div{display:flex;flex-direction:column;gap:.1rem}
.cert-meta b{font-size:1rem}
.cert-meta span{font-size:.8rem;letter-spacing:.04em;text-transform:uppercase}

/* Withdrawn, stamped on the face of the sheet. Hatched rather than coloured, like every other
   state in this platform — a certificate photocopied in black and white must still say it. */
.cert-lapsed{display:inline-block;border:3px dashed currentColor;padding:.3rem 1.2rem;font-size:1.2rem;font-weight:700;letter-spacing:.1em;text-transform:uppercase;transform:rotate(-4deg);margin-block:var(--s3)}

.cert-foot{display:flex;justify-content:space-between;align-items:flex-end;gap:var(--s5);margin-block-start:var(--s5);text-align:start}
.cert-sign{flex:1 1 auto;min-inline-size:0}
.cert-sign .sig-img{inline-size:14rem;max-inline-size:100%;block-size:auto}
.cert-seal{flex:none;text-align:center}
.cert-seal .qr{inline-size:7rem;block-size:7rem}
.cert-seal .meta{font-size:.75rem;max-inline-size:8rem}

/* The ledger bar: the number of the document, and the code a holder is asked to read out. Both,
   because they answer two different questions, and printing only one would leave a reader
   guessing which twelve characters were wanted. */
.cert-ledger{display:flex;flex-wrap:wrap;justify-content:space-between;gap:var(--s2) var(--s4);border-block-start:var(--hair);margin-block-start:var(--s4);padding-block-start:var(--s2);font-size:.85rem;text-align:start}
.cert-ledger .code{letter-spacing:.12em}
.cert-codenote{font-size:.75rem;margin:.3rem 0 0;text-align:start}
.cert-codenote.is-bad{border:1px dashed currentColor;padding:.3rem .6rem;font-weight:700}
.cert-verifyline{font-size:.75rem;margin:var(--s2) 0 0}

@page cert{size:A4 landscape;margin:10mm}
.doc-cert{page:cert}
@media print{
  body:has(.doc-cert){page:cert}
  /* The sheet is the page. Nothing else on it, and no border drawn by the screen view — a
     printed border that does not line up with the paper's own edge looks like a mistake. */
  .doc-cert{max-inline-size:none;margin:0}
  .cert-who{font-size:calc(30pt * var(--nf, 1))}
  .cert-title{font-size:22pt}
  .cert-kicker{font-size:10pt}
}

/* ── باب الفعالية — the screen at the front of the room ──────────────────────────────────────────
   Meant to be put on a projector, made full screen, and left alone. Everything is sized from the
   viewport rather than in rem: the only question that matters is whether somebody at the back of
   a hall can get a phone to focus on it. */
.door{text-align:center;margin-block-start:var(--s4)}
.door-qr{display:flex;align-items:center;justify-content:center;min-block-size:40vh}
.door-qr svg,.door-qr .qr{inline-size:min(62vh, 90vw);block-size:auto;max-inline-size:100%}
.door-msg{font-size:1.4rem;padding:var(--s5)}
/* How long the code on screen has left. The one thing that moves, and what tells somebody at the
   back whether the square they are pointing at is about to change under them. */
.door-bar{block-size:.6rem;border:var(--hair);margin:var(--s3) auto;inline-size:min(62vh, 90vw);max-inline-size:100%}
.door-bar span{display:block;block-size:100%;background:currentColor;inline-size:0;transition:inline-size .25s linear}
.door-ask{font-size:1.6rem;font-weight:700;margin:var(--s3) 0 .2rem}
.door-n{font-size:1rem;margin:0}
/* In full screen the element is the whole display, so it has to carry its own background: an
   element promoted out of the page keeps none of the page's. */
.door:fullscreen{background:var(--paper);color:var(--ink);display:flex;flex-direction:column;align-items:center;justify-content:center;padding:var(--s4)}
.door:fullscreen .door-qr{min-block-size:0}
.door:fullscreen .door-qr svg{inline-size:min(72vh, 90vw)}

/* ── what the scan opens ─────────────────────────────────────────────────────────────────────────
   A phone, held by somebody standing in a hall who wants this over with. One column, large
   target, nothing to read that is not an instruction. */
.scanpage{max-inline-size:34rem;margin-inline:auto}
.scanpage h1{font-size:1.6rem;margin-block-end:var(--s2)}
.scanpage .lede{font-size:1.05rem}
.scanpage .actions{margin-block-start:var(--s4)}
.scanpage .btn{font-size:1.1rem;padding:.7rem 1.4rem}

/* The queued message, as it was queued. Pre-wrapped rather than a paragraph: it is both
   languages with the separator between them, and the line breaks are part of what was sent. */
.mailbody{white-space:pre-wrap;font-family:ui-monospace,"SF Mono",Consolas,monospace;font-size:.82rem;max-block-size:22rem;overflow:auto;border:var(--hair);padding:var(--s2);margin-block-start:var(--s2)}

/* A form folded into a table cell. Six certificates each with a correction form would fill the
   page, so each is behind its own summary and only the one being used is open. */
.inline-edit{display:inline-block;vertical-align:top}
.inline-edit>summary{cursor:pointer;list-style:none}
.inline-edit>summary::-webkit-details-marker{display:none}
.inline-edit[open]>summary{margin-block-end:var(--s2)}
.inline-edit .form{border:var(--hair);padding:var(--s2);min-inline-size:14rem;text-align:start}

/* ── the rail, and the steps it walks ────────────────────────────────────────────────────────────
   Numbered, because «step three of six» is the one thing somebody filling a long form wants to
   know and the one thing a scroll bar cannot tell them.

   State is shown by weight and by a mark, never by colour: this platform says everything that
   way, and a rail whose only signal was a blue dot would be the one place it did not. */
.rail{display:flex;flex-wrap:wrap;gap:var(--s2);list-style:none;margin:0 0 var(--s5);padding:0;counter-reset:none}
.rail li{display:flex;align-items:center;border:var(--hair);min-inline-size:0;padding:0}
/* The padding moved onto the button so the whole item is the target, not a label with dead
   margin around it. A button also brings its own chrome, which is cleared here rather than
   fought with: this platform draws its own borders. */
.rail li>button,.rail li>b{display:flex;align-items:center;gap:var(--s2);padding:var(--s2) var(--s3);
  background:none;border:0;font:inherit;color:inherit;cursor:pointer;inline-size:100%;min-inline-size:0;text-align:start}
.rail li>b{cursor:default;padding-inline-end:0}
.rail li>span{padding-inline-end:var(--s3)}
.rail li>button:focus-visible{outline:2px solid #000;outline-offset:-4px}
.rail li b,.rail li button b{display:grid;place-items:center;inline-size:1.6rem;block-size:1.6rem;border:var(--hair);border-radius:50%;font-size:.8rem;flex:none;padding:0}
.rail li span{font-size:.85rem;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
/* Where you are: the heavy border, which is how this platform says «this one». */
.rail li.is-on{border:var(--heavy);font-weight:700}
.rail li.is-on b{background:#000;color:#fff;border-color:#000}
/* Behind you, and therefore done — a tick in place of the number, so the mark is the state and
   not merely a shade of it. */
.rail li.is-past b{background:#000;color:#fff;border-color:#000}
.rail li.is-past b::after{content:"✓";font-size:.9rem}
.rail li.is-past b{font-size:0}
/* The end of the rail is not a step. Dashed, because it has not happened: it is what the steps
   are for, and it is reached by pressing a button rather than by walking. */
.rail li.is-end{border-style:dashed}
.rail li.is-end b{border-style:dashed}
.rail li.is-end svg{inline-size:.9rem;block-size:.9rem}
/* Any phase can be opened, so every one of them looks pressable — a rail where only some items
   respond is a rail somebody stops trying. */
.rail.is-walking li:hover{border:var(--rule)}
.rail.is-walking li.is-on:hover{border:var(--heavy)}

/* A step is a fieldset, so it keeps the legend a screen reader needs. The browser's default
   fieldset border is dropped in favour of this platform's hairline, and the legend is a heading
   rather than a caption notched into a box. */
fieldset.step{border:0;border-block-start:var(--hair);padding:var(--s4) 0 0;margin:0 0 var(--s5);min-inline-size:0}
fieldset.step>legend{font-size:1.15rem;font-weight:700;padding:0;margin-block-end:var(--s3)}
fieldset.step>legend:focus-visible{outline:2px solid #000;outline-offset:3px}
fieldset.step.is-last{border-block-start:var(--heavy)}

/* The walking controls. Sticky at the foot, because the whole point of a step is that it fits on
   a screen and the way onward should not have to be hunted for under a textarea. */
.stepnav{display:flex;align-items:center;gap:var(--s3);position:sticky;inset-block-end:0;background:var(--paper);border-block-start:var(--hair);padding-block:var(--s3);margin-block-start:var(--s4);z-index:5}
.stepnav .meta{margin-inline-start:auto}
@media print{ .rail,.stepnav{display:none} fieldset.step{display:block !important} }

/* The map link and the room select it fills sit on one line, with the explanation under both:
   they are one question — «which room» — and separating the link from the field would make it
   look like a way of leaving the form rather than a way of answering it. */
.maplink{display:flex;flex-wrap:wrap;align-items:center;gap:var(--s3)}
.maplink .hint{flex:1 1 16rem;min-inline-size:0}

/* On a map opened to choose with, a bookable room is a choice rather than a way to its own
   diary. The banner above says so in words; this is only the pointer agreeing with it. */
.rmmap.is-picking a.pl-room.is-book{cursor:pointer}
