/* Ethereal, for /worlds/harry-potter/ and /marauders-map/ (style: ethereal).

   The films' magic is silver light: the patronus, the castle's ghosts, the
   candles under the enchanted ceiling. So the castle at night is lit from
   above by that silver. Every card is a pane of moonlight, solid under its
   words, with a translucent edge that catches the light; mist lives in the
   margins and never behind a sentence; the candles still float, warm, in
   the sky. The signature: a light from above follows the reader down the
   page, and each section brightens as it reaches the middle of the screen.

   The Marauder's Map is ink on parchment and keeps its ground. The same
   light falls on it the way a patronus or a Lumos would fall on a sheet of
   parchment at night: a silver pool over the paper that follows the reader,
   soft glowing edges against the castle's blue night, ink that gives off a
   little light, and the corridors brightening as you reach them. Never
   fog over the text: the light goes under the ink, between it and the paper.

   One file for the pair, in three parts: what both share (the palette, the
   panes, the light); the world page; the Map. The spec: docs/superpowers/
   specs/2026-10-11-page-styles-design.md, "Harry Potter: Ethereal" and
   section 9. Everything is scoped to :root[data-style="ethereal"]. Material
   rules use :where() for that scope, so they weigh what the rule they
   restyle weighs and each page's own hover and open states still win. */

/* ── 1. shared: the castle's silver light ───────────────────────────────── */
:root[data-style="ethereal"] {
  --et-silver: #e8effc;            /* patronus silver, the brightest light */
  --et-silver-2: #c4d4f2;          /* the world's colour on this page */
  --et-candle: #f3cf86;            /* the floating candles stay warm */
  /* a pane of moonlight: a night-blue glass dense enough to be the solid
     ground of every word on it, a rim that lets the light through and is
     brightest along the top, where the light falls, and a soft glow round
     it, so it gives off a little of the light it catches */
  --et-pane: rgba(12, 17, 31, .9);
  --et-pane-hi: rgba(18, 25, 44, .93);
  --et-fall: linear-gradient(180deg, rgba(206, 222, 255, .06), rgba(206, 222, 255, 0) 42%);
  --et-rim: rgba(198, 214, 246, .2);
  --et-rim-top: rgba(222, 233, 255, .42);
  --et-rim-hi: rgba(222, 233, 255, .55);
  --et-lit: inset 0 1px 0 rgba(236, 243, 255, .26);
  --et-drop: 0 24px 46px -30px rgba(0, 0, 0, .9);
  --et-halo: 0 0 38px -16px rgba(170, 196, 242, .34);

  /* The night is blue and the reading inks are moonlit: the same three
     levels, cooled, and each a little lighter than the site's, because a
     section's light can sit behind them (the lightest ground any of them
     meets keeps 4.5:1). Lighter only, never darker (base.css). */
  --bg: #060913;
  --ink: #e6ebf4;
  --ink-dim: #c3c6d1;
  --mute: #aeb3c2;

  --s-surface: var(--et-fall), var(--et-pane);
  --s-surface-hi: var(--et-fall), var(--et-pane-hi);
  --s-edge: var(--et-rim);
  --s-bw: 1px;
  --s-r: 18px;
  --s-r-sm: 999px;
  --s-shadow: var(--et-lit), var(--et-drop), var(--et-halo);
  --s-shadow-hi: var(--et-lit), var(--et-drop), 0 0 50px -12px rgba(184, 206, 248, .55);
  --s-lift: -3px;
  --s-display: "Spectral", var(--serif, Georgia), serif;
  --s-display-w: 300;
  --s-display-ls: -0.015em;
  --s-focus: #e6eeff;

  /* the bars: night glass with a silver edge and the same faint glow */
  --s-bar: rgba(9, 13, 25, .66);
  --s-bar-edge: rgba(200, 216, 246, .18);
  --s-bar-shadow: inset 0 1px 0 rgba(226, 236, 255, .14), 0 18px 40px -22px rgba(0, 0, 0, .85), 0 0 34px -14px rgba(170, 196, 242, .28);

  /* no film grain and no circuit field in a castle; the HUD lattice and its
     scan line go too, and the light under the pointer is a wand's, silver */
  --s-grain: 0;
  --s-field: 0;
  --hud-grid: transparent;
  --hud-scan: transparent;
  --hud-sweep: transparent;
  --hud-lit: transparent;
  --hud-halo: rgba(206, 222, 255, .08);
}
:root[data-style="ethereal"] ::selection { background: #c4d4f2; color: #060913; }
:root[data-style="ethereal"] { scrollbar-color: #33405e #060913; }
@supports not ((backdrop-filter: blur(1px)) or (-webkit-backdrop-filter: blur(1px))) {
  :root[data-style="ethereal"] { --s-bar: rgba(9, 13, 25, .95); }
}
@media (prefers-reduced-transparency: reduce) {
  :root[data-style="ethereal"] {
    --et-pane: rgb(12, 17, 31); --et-pane-hi: rgb(18, 25, 44);
    --s-bar: rgb(9, 13, 25); --s-bar-blur: none;
  }
  :root[data-style="ethereal"] .hp-sky::after { opacity: 0; }
}
/* Increase Contrast: solid panes, rims that read, inks above the site's own
   boost, and a ground no lighter than the site's, so they keep their lead */
@media (prefers-contrast: more) {
  :root[data-style="ethereal"] {
    --bg: #05070d; --ink-dim: #d4d7e0; --mute: #bfc3cf;
    --et-pane: rgb(10, 14, 26); --et-pane-hi: rgb(16, 22, 40);
    --et-rim: rgba(214, 228, 255, .5); --s-bar-edge: rgba(214, 228, 255, .45);
  }
}

/* A section's own light. It sits behind everything in the section (main
   is the stacking context), so it shows round the heading, in the gaps
   between the panes and through their rims, and never over a word.
   Scrolling raises it as the section comes up the screen and lowers it as
   the section leaves, so the light moves down the page with the reader;
   under Reduce Motion, or without scroll-driven animation, every section
   rests half lit. Opacity only. */
@keyframes et-lit {
  entry 0% { opacity: .08; }
  entry 70%, exit 30% { opacity: 1; }
  exit 100% { opacity: .08; }
}
@keyframes et-rise { from { transform: translateY(0); } to { transform: translateY(-14vh); } }

/* ── 2. the world page: the castle at night ─────────────────────────────── */

/* the world's colour turns from candle gold to patronus silver; every item
   that carries its own colour keeps it, and the tab bar takes the silver */
:root[data-style="ethereal"] body[data-fan="hp"] { --a: var(--et-silver-2); }
:root[data-style="ethereal"] .tabbar { --s-accent: var(--et-silver); }

/* The enchanted ceiling, redrawn in moonlight: a blue night, a silver moon
   with a wide halo, the castle in night stone with its windows still lit,
   the candles warm and a little brighter, and mist low over the grounds
   and up the two sides. The whole sky is capped at .36 (fanpages.css), so
   all of it is drawn at about three times what it should read as. */
:root[data-style="ethereal"] .hp-sky {
  background:
    radial-gradient(42% 34% at 82% 12%, rgba(206, 222, 255, .26), transparent 72%),
    radial-gradient(80% 36% at 50% 104%, rgba(214, 170, 96, .1), transparent 64%),
    radial-gradient(120% 92% at 50% -18%, #22325a 0%, #0e182e 44%, #05070f 100%);
}
:root[data-style="ethereal"] .hp-moon {
  background: radial-gradient(circle at 38% 34%, #fbfdff, #dfe8f8 56%, #a9bad8 100%);
  box-shadow: 0 0 70px 22px rgba(206, 222, 255, .3), 0 0 200px 80px rgba(170, 196, 242, .14);
  opacity: 1;
}
:root[data-style="ethereal"] .hp-castle :is(.hp-rock, .hp-pitch-ground) { fill: #050811; }
:root[data-style="ethereal"] .hp-castle :is(.hp-stone, .hp-stands) { fill: #0c1426; }
:root[data-style="ethereal"] .hp-sky span {
  opacity: 1;
  box-shadow: 0 -8px 22px 4px rgba(245, 198, 90, .3), 0 0 7px rgba(255, 232, 160, .8);
}
:root[data-style="ethereal"] .hp-sky::after {
  content: ""; position: absolute; inset: 0 0 -16vh;
  background:
    radial-gradient(16% 48% at 0% 36%, rgba(196, 212, 244, .5), transparent 70%),
    radial-gradient(14% 40% at 0% 80%, rgba(196, 212, 244, .36), transparent 70%),
    radial-gradient(16% 48% at 100% 60%, rgba(196, 212, 244, .44), transparent 70%),
    radial-gradient(90% 22% at 50% 100%, rgba(186, 204, 240, .5), transparent 72%);
}
@media (max-width: 640px) {
  :root[data-style="ethereal"] .hp-sky::after {
    background:
      radial-gradient(10% 40% at 0% 40%, rgba(196, 212, 244, .4), transparent 70%),
      radial-gradient(10% 40% at 100% 64%, rgba(196, 212, 244, .36), transparent 70%),
      radial-gradient(100% 16% at 50% 100%, rgba(186, 204, 240, .45), transparent 72%);
  }
}

/* The light from above: moonlight through the high windows, two soft
   shafts falling from the upper right across the hall and fading before
   they reach the floor, under a wide glow round the moon. Fixed, so every
   section passes through it on its way up; faint enough that the faintest
   ink on the page keeps 4.5:1 where it is brightest. Behind everything in
   <main> (its own stacking context), never over a word. */
:root[data-style="ethereal"] main::before {
  content: ""; position: fixed; inset: 0; z-index: -1; pointer-events: none;
  background:
    radial-gradient(22% 30% at 82% 12%, rgba(214, 228, 255, .1), transparent 72%),
    linear-gradient(118deg, transparent 38%, rgba(206, 222, 255, .05) 47%, transparent 55%),
    linear-gradient(118deg, transparent 56%, rgba(206, 222, 255, .04) 61%, transparent 67%);
  -webkit-mask-image: linear-gradient(to bottom, #000 10%, transparent 88%);
  mask-image: linear-gradient(to bottom, #000 10%, transparent 88%);
}

/* each section's own light, pooled round its heading and falling over the
   first rows under it */
:root[data-style="ethereal"] .fan-sec { position: relative; view-timeline: --et-sec block; }
:root[data-style="ethereal"] .fan-sec::before {
  content: ""; position: absolute; z-index: -1; pointer-events: none;
  inset: -10rem 0 -2rem;
  background:
    radial-gradient(30% 220px at 24% 10.6rem, rgba(214, 228, 255, .2), transparent 72%),
    radial-gradient(56% 70% at 46% 10.6rem, rgba(170, 196, 242, .1), transparent 76%);
  /* soft at the top and the foot, so no edge of the box ever shows */
  -webkit-mask-image: linear-gradient(to bottom, transparent, #000 9rem, #000 70%, transparent);
  mask-image: linear-gradient(to bottom, transparent, #000 9rem, #000 70%, transparent);
  opacity: .5;
}
@media (prefers-reduced-motion: no-preference) {
  @supports (animation-timeline: scroll()) {
    :root[data-style="ethereal"] .fan-sec::before { animation: et-lit linear both; animation-timeline: --et-sec; }
    :root[data-style="ethereal"] .hp-sky::after { animation: et-rise linear both; animation-timeline: scroll(root); }
  }
}

/* Panes of moonlight, on every surface that holds text */
:where(:root[data-style="ethereal"]) :is(.fan-card, .fan-tile, .fan-linkcard, .fan-rankrow, .fan-land, .fan-film, .fan-shot, .fan-cf-side, .fan-cf-tab, .fan-intro-when, .hat-panel) {
  border: 1px solid var(--et-rim); border-top-color: var(--et-rim-top); border-radius: var(--s-r);
  background: var(--s-surface);
  box-shadow: var(--s-shadow);
}
:where(:root[data-style="ethereal"]) .fan-tile { border-radius: 14px; }
:where(:root[data-style="ethereal"]) .fan-cf-tab { border-radius: 12px; }
:where(:root[data-style="ethereal"]) .fan-shot figcaption { border-top-color: var(--et-rim); }
:where(:root[data-style="ethereal"]) .fan-cf-side {
  border-top: 2px solid color-mix(in srgb, var(--s, #888) 72%, transparent);
  background: linear-gradient(180deg, color-mix(in srgb, var(--s, #888) 13%, transparent), transparent 60%), var(--et-pane);
}
:where(:root[data-style="ethereal"]) .fan-cf-tab.is-on {
  border-color: var(--et-rim-hi);
  background: linear-gradient(180deg, rgba(206, 222, 255, .12), rgba(206, 222, 255, .02)), var(--et-pane);
}
/* a film's own colour as the light on it, the numeral faint behind */
:where(:root[data-style="ethereal"]) .fan-film {
  background: radial-gradient(120% 70% at 50% 0%, color-mix(in srgb, var(--a) 14%, transparent), transparent 70%), var(--et-pane);
}
/* the "first read" note: a pane, its colour in the name, not a stripe, and
   inside the same column as the sections (it ran a gutter past them, which
   the old fade hid and a pane's edge does not; on a phone, to the glass) */
:where(:root[data-style="ethereal"]) .fan-intro-when {
  border-left-width: 1px;
  margin-inline: var(--gutter); max-width: calc(var(--maxw) - 2 * var(--gutter));
}
/* the Sorting Hat sits in a pane lit from above left, where a candle is */
:where(:root[data-style="ethereal"]) .hat-panel {
  background: radial-gradient(80% 110% at 12% 0%, rgba(243, 207, 134, .07), transparent 60%), var(--et-fall), var(--et-pane);
}
@media (hover: hover) {
  :where(:root[data-style="ethereal"]) :is(.fan-rankrow, .fan-land, .fan-film, .fan-shot, .fan-card, .fan-linkcard):hover {
    border-color: var(--et-rim-hi); box-shadow: var(--s-shadow-hi);
  }
  /* the rank's own hover took the pane away; it brightens it instead */
  :root[data-style="ethereal"] .fan-rankrow:hover { background: var(--s-surface-hi); }
}

/* Each line people said keeps the house it is graded by, as the light on
   its pane: a glow in that colour from the corner, a rim of it, and the
   name under it in it. No coloured stripe down the side. */
:where(:root[data-style="ethereal"]) .fan-quote {
  border: 1px solid color-mix(in srgb, var(--a) 38%, transparent); border-radius: var(--s-r);
  background: radial-gradient(90% 120% at 0% 0%, color-mix(in srgb, var(--a) 17%, transparent), transparent 62%), var(--et-pane);
  box-shadow: var(--et-lit), var(--et-drop), 0 0 40px -18px var(--a);
}
@media (hover: hover) {
  :root[data-style="ethereal"] .fan-quote:hover {
    background: radial-gradient(100% 130% at 0% 0%, color-mix(in srgb, var(--a) 24%, transparent), transparent 66%), var(--et-pane-hi);
    box-shadow: var(--et-lit), var(--et-drop), 0 0 50px -14px var(--a);
  }
}

/* The houses keep their colours (and only they do): each crest is a pane
   lit in its own house's light */
:where(:root[data-style="ethereal"]) .crest {
  border-radius: var(--s-r);
  background:
    radial-gradient(125% 78% at 50% 0%, color-mix(in srgb, var(--h1) 24%, transparent), transparent 64%),
    var(--et-fall), var(--et-pane);
  box-shadow: var(--et-lit), var(--et-drop), 0 0 46px -20px var(--hl, var(--h1));
}
@media (hover: hover) {
  :root[data-style="ethereal"] .crest:hover {
    background:
      radial-gradient(125% 78% at 50% 0%, color-mix(in srgb, var(--h1) 38%, transparent), transparent 68%),
      var(--et-fall), var(--et-pane-hi);
  }
}

/* controls: pills and doors with a silver edge that reads as one */
:where(:root[data-style="ethereal"]) .fan-link { border-color: rgba(200, 216, 246, .45); background: var(--et-pane); }
:where(:root[data-style="ethereal"]) :is(.fan-iface, .wsib-i a) {
  border-color: rgba(200, 216, 246, .5);
  background: linear-gradient(180deg, rgba(206, 222, 255, .1), rgba(206, 222, 255, .02)), var(--et-pane);
  box-shadow: var(--et-lit), var(--et-halo);
}
:where(:root[data-style="ethereal"]) .fan-iface-a { border-color: rgba(200, 216, 246, .45); }
:where(:root[data-style="ethereal"]) .hat-go {
  color: var(--et-silver); border-color: rgba(200, 216, 246, .55);
  background: rgba(196, 214, 246, .08);
}
@media (hover: hover) {
  :where(:root[data-style="ethereal"]) .hat-go:hover:not([disabled]) { background: rgba(196, 214, 246, .18); }
}
/* the Hat's button drew its own gold ring; it takes the silver one */
:root[data-style="ethereal"] .hat-go:focus-visible { outline-color: var(--s-focus); }

/* Headings in Spectral, a light serif whose hairlines catch the light; the
   title is patronus silver and glows. Reading stays Inter, labels mono. */
:root[data-style="ethereal"] .fan-title {
  font-family: var(--s-display); font-weight: 300; letter-spacing: var(--s-display-ls);
  color: var(--et-silver);
  text-shadow: 0 0 1px rgba(232, 240, 255, .5), 0 0 24px rgba(186, 208, 250, .5), 0 0 72px rgba(150, 182, 240, .3);
}
:root[data-style="ethereal"] .subsec--fan {
  font-family: var(--s-display); font-weight: 300; text-transform: none;
  font-size: clamp(1.45rem, 2.4vw, 1.85rem); letter-spacing: -0.005em; line-height: 1.15;
  color: var(--et-silver); text-shadow: 0 0 22px rgba(186, 208, 250, .4);
}
:root[data-style="ethereal"] .subsec--fan .subsec-yr {
  font-family: var(--mono); font-size: 0.66rem; letter-spacing: 0.14em; text-transform: uppercase;
  color: #b4c3df; text-shadow: none;
}
:root[data-style="ethereal"] .subsec--fan::after { background: linear-gradient(90deg, rgba(206, 222, 255, .4), rgba(206, 222, 255, 0)); }
:root[data-style="ethereal"] :is(.fan-card :is(h2, h3, h4, h5), .fan-rankhead b, .fan-tiletext b, .fan-land-head :is(h2, h3, h4, h5), .fan-film :is(h2, h3, h4, h5), .fan-shot figcaption b, .fan-linkhead b, .fan-cf-name-h, .crest :is(h2, h3), .wsib-h b) {
  font-family: var(--s-display); font-weight: 500; letter-spacing: 0;
}
:root[data-style="ethereal"] .fan-card :is(h2, h3, h4, h5) { font-size: 1.18rem; }
:root[data-style="ethereal"] .fan-tiletext b { font-size: 1rem; }
:root[data-style="ethereal"] .fan-rankhead b { font-size: 1.12rem; }
:root[data-style="ethereal"] :is(.fan-num, .fan-film-num) { font-family: var(--s-display); font-weight: 300; letter-spacing: 0; }
:root[data-style="ethereal"] .fan-num { font-size: 1.32rem; line-height: 1.2; opacity: 1; color: #b4c6ea; }
:root[data-style="ethereal"] :is(.fan-quote blockquote, .fan-art-body q, .hat-say) {
  font-family: var(--s-display); font-style: italic; font-weight: 300; letter-spacing: 0;
}
:root[data-style="ethereal"] .fan-quote blockquote { font-size: 1.14rem; }
/* the Hat shouts the house upright, as it always did */
:root[data-style="ethereal"] .hat-say.is-shout { font-style: normal; font-weight: 500; }

/* An item's own colour (a caption, a subtitle, a tag, a Listen link, a
   Play button) on a pane a shade bluer than the old ground: each is lifted
   a quarter toward white, so the house reds and greens keep their 4.5:1.
   :where keeps the shared rules' weight, so hovering and playing win. */
:root[data-style="ethereal"] :is(.fan-tiletext i, .fan-card .fan-sub) { color: color-mix(in srgb, var(--a) 75%, #fff); opacity: 1; }
:where(:root[data-style="ethereal"]) :is(.fan-tag, .fan-visit, .fan-hear, .fan-grouphead) { color: color-mix(in srgb, var(--a) 75%, #fff); }
/* a spell, cast, flashes its own colour over the pane, never instead of it */
:root[data-style="ethereal"] #spells .fan-tile.is-cast {
  background: linear-gradient(color-mix(in srgb, var(--a) 18%, transparent), color-mix(in srgb, var(--a) 18%, transparent)), var(--et-pane);
}

/* Hogwarts drawn in moonlight: the lines are the silver, they glow a
   little, and the windows keep the candles. The wand's Lumos is the same
   silver as the light on the page. */
:root[data-style="ethereal"] .fan-art--hp .art-line { filter: drop-shadow(0 0 5px rgba(196, 214, 250, .45)); }
:root[data-style="ethereal"] .fan-art--hp .art-lit { fill: var(--et-candle); }
:root[data-style="ethereal"] .wl-halo { fill: rgba(206, 222, 255, .2); }
:root[data-style="ethereal"] .wl-core {
  fill: #f6f9ff;
  filter: drop-shadow(0 0 8px rgba(226, 236, 255, .95)) drop-shadow(0 0 22px rgba(160, 190, 250, .7));
}
:root[data-style="ethereal"] .wl-spark circle { fill: #dfe9ff; }

/* The fragment of the Map under the title is parchment, so it is lit the
   way the Map is: a cool pool on the paper and a silver glow at its edges.
   Its words were mixed for a dark ground and read faintly on paper; here
   they are the Map's own inks, and its ring is ink too. */
:root[data-style="ethereal"] .fan-peek {
  --s-focus: #22336a;
  background: radial-gradient(90% 70% at 50% 0%, rgba(240, 246, 255, .4), transparent 70%), var(--pkbg);
  box-shadow: 0 0 0 1px rgba(255, 255, 255, .1), 0 0 48px -10px rgba(196, 214, 250, .45), var(--et-drop);
}
:root[data-style="ethereal"] :is(.fan-peek-bar, .fan-peek-rows dt, .fan-peek-n) { color: #4a3d3a; }
:root[data-style="ethereal"] .fan-peek-rows dd { color: #24202e; }
:root[data-style="ethereal"] .fan-peek-go { color: #33508f; }

/* ── 3. the Marauder's Map: the same light on parchment ─────────────────── */

/* the night round the sheet is the castle's: blue, with mist at the sides
   and a candle or two floating in the margins */
:root[data-style="ethereal"] .mm ::selection { background: #33508f; color: #f3f0e6; }
:root[data-style="ethereal"] .mm {
  --ink: #24202e;                  /* iron gall, fresh, as the light finds it */
  --ink-2: #433b52;
  --line: rgba(36, 32, 52, .3);
  --s-focus: #22336a;
  background: #060913;
}
:root[data-style="ethereal"] .mm::before {
  content: ""; position: fixed; inset: 0; z-index: 0; pointer-events: none;
  background:
    radial-gradient(3px 9px at 2.6% 24%, var(--et-candle), transparent),
    radial-gradient(3px 8px at 97% 38%, var(--et-candle), transparent),
    radial-gradient(3px 9px at 3.4% 71%, var(--et-candle), transparent),
    radial-gradient(18% 52% at 0% 40%, rgba(186, 204, 238, .16), transparent 70%),
    radial-gradient(18% 52% at 100% 66%, rgba(186, 204, 238, .14), transparent 70%),
    radial-gradient(70% 24% at 50% 100%, rgba(170, 192, 232, .1), transparent 72%);
}
/* the parchment glows at its edges in the light, and is lit from above */
:root[data-style="ethereal"] .mm-sheet {
  background:
    radial-gradient(64% 30% at 50% 0%, rgba(242, 247, 255, .55), rgba(242, 247, 255, 0) 72%),
    radial-gradient(120% 90% at 50% 0%, var(--parch) 0%, var(--parch-2) 55%, #c9ad7c 100%);
  box-shadow: 0 40px 90px -40px #000, 0 0 110px -14px rgba(186, 206, 246, .4);
}

/* The light that follows the reader: a pool of silver held over the
   sheet wherever you are on it, between the paper and the ink */
:root[data-style="ethereal"] .mm-inner::before {
  content: ""; position: fixed; inset: 0; z-index: -1; pointer-events: none;
  background: radial-gradient(48% 40% at 50% 36%, rgba(238, 244, 255, .34), rgba(238, 244, 255, .12) 46%, transparent 74%);
}

/* luminous ink: the title and the room names give off a little light */
:root[data-style="ethereal"] .mm-title {
  text-shadow: 0 1px 0 rgba(255, 255, 255, .5), 0 0 18px rgba(255, 255, 255, .8), 0 0 44px rgba(214, 228, 255, .75);
}
:root[data-style="ethereal"] :is(.mm-room b, .mm-spell b) { text-shadow: 0 0 10px rgba(255, 255, 255, .62); }
:root[data-style="ethereal"] .mm-makers { color: #33508f; }

/* the corridors and the two panels: panes of moonlight on the paper, and
   each brightens round its edge as you reach it, like the sections on the
   world page */
:root[data-style="ethereal"] .mm-map { view-timeline: --et-sec block; }
:root[data-style="ethereal"] .mm-panel { position: relative; view-timeline: --et-sec block; }
:root[data-style="ethereal"] :is(.mm-map, .mm-panel)::before {
  content: ""; position: absolute; inset: -8px; z-index: -1; pointer-events: none;
  border-radius: 10px;
  background: rgba(244, 248, 255, .18);
  box-shadow: 0 0 34px 4px rgba(240, 246, 255, .72);
  opacity: .5;
}
@media (prefers-reduced-motion: no-preference) {
  @supports (animation-timeline: scroll()) {
    :root[data-style="ethereal"] :is(.mm-map, .mm-panel)::before { animation: et-lit linear both; animation-timeline: --et-sec; }
  }
}
:root[data-style="ethereal"] :is(.mm-room, .mm-panel) {
  background: linear-gradient(180deg, rgba(250, 252, 255, .46), rgba(244, 247, 255, .16));
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, .6), 0 10px 20px -16px rgba(30, 30, 64, .5);
}
/* the two labels on the frame become lit tags on it */
:root[data-style="ethereal"] :is(.mm-map-h, .mm-you) {
  border-radius: 4px; background: #f3f0e6;
  box-shadow: 0 0 14px rgba(255, 255, 255, .8);
}
/* the footprints are ink with the light behind them */
:root[data-style="ethereal"] .mm-steps i { background: rgba(36, 32, 46, .6); box-shadow: 0 0 8px 1px rgba(255, 255, 255, .75); }
:root[data-style="ethereal"] .mm-you b { background: rgba(36, 32, 46, .8); }
:root[data-style="ethereal"] .mm-manage {
  background: rgba(250, 252, 255, .4);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, .6), 0 0 26px -6px rgba(255, 255, 255, .9);
}
@media (hover: hover) {
  :root[data-style="ethereal"] .mm-room:hover {
    background: rgba(252, 253, 255, .74);
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, .8), 0 0 0 1px rgba(255, 255, 255, .4), 0 0 30px -4px rgba(236, 243, 255, .95);
  }
  :root[data-style="ethereal"] .mm-manage:hover { background: var(--ink); box-shadow: 0 0 34px -2px rgba(236, 243, 255, .95); }
}

/* the world button: the pair's moonlit ink, a pill of light on the paper */
:root[data-style="ethereal"] .mm .iw {
  --iw-a: #33508f;
  border-color: color-mix(in srgb, var(--iw-a) 55%, transparent);
  background: linear-gradient(180deg, rgba(250, 252, 255, .72), rgba(236, 242, 255, .42));
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, .8), 0 0 22px -6px rgba(240, 246, 255, .95), 0 6px 16px -10px rgba(30, 40, 80, .5);
}
:root[data-style="ethereal"] .mm .iw-k { opacity: 1; }
/* at the foot it is a line of its own, centred over Mischief managed and
   clear of the panels, where it had sat flush under the charms */
:root[data-style="ethereal"] .mm .iw--foot { display: flex; width: fit-content; max-width: 100%; margin: 1.5rem auto 0; }
@media (hover: hover) and (pointer: fine) {
  :root[data-style="ethereal"] .mm .iw:hover {
    background: linear-gradient(180deg, rgba(252, 253, 255, .9), rgba(240, 245, 255, .6));
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, .9), 0 0 30px -4px rgba(240, 246, 255, 1), 0 8px 18px -10px rgba(30, 40, 80, .55);
  }
}

/* every ring on the paper is the moonlit ink */
:root[data-style="ethereal"] .mm :focus-visible { outline: 2px solid var(--s-focus); outline-offset: 3px; }

/* Mischief managed: the blank sheet is gone and only the night is left,
   with a last silver glow where the map was */
:root[data-style="ethereal"] .mm-done {
  --s-focus: #e6eeff;
  background: radial-gradient(50% 40% at 50% 46%, rgba(186, 206, 246, .12), transparent 72%), #060913;
}
:where(:root[data-style="ethereal"]) .mm-done a { color: var(--et-silver-2); border-bottom-color: currentColor; }
