/* the page colours are animated as colours themselves, so a ground and the gradient leading into it
   always show the same value (otherwise the gradient jumps ahead and the edge shows until the ground catches up) */
@property --deep{syntax:"<color>";inherits:true;initial-value:#071e80}
@property --page-bg{syntax:"<color>";inherits:true;initial-value:#ffffff}
@property --page-ink{syntax:"<color>";inherits:true;initial-value:#02176b}
:root{transition:--deep 2.5s linear,--page-bg 2.5s linear,--page-ink 2.5s linear}
:root.pw-instant{transition:none}
/* Reset, tokens, sky canvas, nav */
img{max-width:100%}
[hidden]:not([hidden=until-found i]){display:none!important}
html{scroll-padding-top:env(safe-area-inset-top,0px)}
body{font-size:14px}
:root{
  color-scheme:dark;
  --deep:#071e80;
  --glow:#b9dcff;
  --ink:#ffffff;
  --muted:rgba(255,255,255,.62);
  --line:rgba(255,255,255,.2);
  --shadow:0 0 22px rgba(0,20,70,.14);   /* only a soft halo for small type on the sky, no visible drop shadow */
  --gutter:clamp(16px,2.4vw,44px);
  --serif:"Self Modern","Iowan Old Style","Palatino Linotype",Georgia,serif;
  --lab-h:0px;
}
html{background:var(--deep)}
/* nothing may push the page sideways (the image effect draws a little beyond each frame): on phones
   the page could otherwise be dragged left and right. clip, unlike hidden, keeps sticky working */
html,body{overflow-x:clip;overscroll-behavior-x:none}
body{margin:0;background:var(--deep);color:var(--ink);font-family:var(--serif);font-weight:400;
  -webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale;text-rendering:optimizeLegibility;}
a{color:inherit}
::selection{background:var(--glow);color:var(--deep)}

/* SKY */
#sky{position:fixed;left:0;top:0;width:100vw;height:100vh;height:100lvh;display:block;z-index:0;
  background:linear-gradient(to bottom,#0a3cf0 0%,#5aa0ff 70%,#ffd2b0 100%)}

/* NAV */
.nav{position:fixed;top:0;left:0;right:0;z-index:10;display:flex;justify-content:space-between;align-items:baseline;gap:24px;
  padding:calc(env(safe-area-inset-top,0px) + 18px + var(--lab-h)) var(--gutter) 0;font-size:15px;letter-spacing:.01em;
  text-shadow:var(--shadow);pointer-events:none}
.nav::before{content:"";position:absolute;inset:0 0 -28px;background:linear-gradient(var(--deep) 55%,transparent);opacity:0;transition:opacity .4s;z-index:-1}
.nav.solid::before{opacity:1}
.nav a{pointer-events:auto;text-decoration:none}
.nav .links{display:flex;gap:clamp(14px,2vw,32px)}
.nav a:hover{font-style:italic}
.nav a:focus-visible,.bar button:focus-visible,.work a:focus-visible{outline:1px solid var(--glow);outline-offset:6px}
.sr{position:absolute;width:1px;height:1px;overflow:hidden;clip:rect(0 0 0 0);white-space:nowrap}
@keyframes pulse{0%,100%{opacity:1}50%{opacity:.35}}
@keyframes drip{0%{transform:scaleY(0)}50%{transform:scaleY(1)}100%{transform:scaleY(1);opacity:0}}
main:focus{outline:none}
.admin-bar .nav{top:var(--wp-admin--admin-bar--height,32px)}

/* Italic is narrower than roman: an invisible margin around small links keeps the pointer
   inside while they switch, otherwise the hover flickers at the right edge */
.nav a,.crumbs a,.contact .out a,.filter-btn{position:relative}
.nav a::after,.crumbs a::after,.contact .out a::after,.filter-btn::after{content:"";position:absolute;inset:-6px -.4em -6px -.2em}
