/* iain.work v7 - the shared frame. Every page loads this; each page adds its own room on top. */

@font-face { font-family: 'Geist Mono'; src: url('/v7/fonts/GeistMono-Regular.woff2') format('woff2'); font-weight: 400; font-display: swap; }
@font-face { font-family: 'Geist Mono'; src: url('/v7/fonts/GeistMono-Medium.woff2') format('woff2'); font-weight: 500; font-display: swap; }
@font-face { font-family: 'Geist'; src: url('/v7/fonts/Geist-Regular.woff2') format('woff2'); font-weight: 400; font-display: swap; }
@font-face { font-family: 'Geist'; src: url('/v7/fonts/Geist-Medium.woff2') format('woff2'); font-weight: 500; font-display: swap; }

:root {
  --orange: #F26522;
  --ink: #111111;
  --paper: #ffffff;
  --night: #0d0d0c;
  --light: #F1EEE6;
  --mute: #9a968d;
  --panel: rgba(240, 238, 233, 0.82);
  --mono: 'Geist Mono', ui-monospace, SFMono-Regular, Menlo, monospace;
  --sans: 'Geist', ui-sans-serif, system-ui, -apple-system, 'Helvetica Neue', Arial, sans-serif;
  --pad-y: 16px;
  --pad-x: 20px;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; font-family: var(--mono); font-size: 11px; letter-spacing: 0.06em; text-transform: uppercase; font-variant-numeric: tabular-nums; -webkit-font-smoothing: antialiased; }
img, video { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
a:hover { opacity: 0.6; }
a:focus-visible { outline: 1px solid var(--orange); outline-offset: 3px; }
p { margin: 0; }

/* The orange square: the dot in iain.work, the full stop, the mark */
.sq { display: inline-block; width: 0.32em; height: 0.32em; margin: 0 0.14em; background: var(--orange); }
.sq-end { margin-right: 0; }

/* Light panels behind menu items */
.panel { display: inline-block; padding: 7px 10px; line-height: 1.2; background: var(--panel); color: var(--ink); -webkit-backdrop-filter: blur(10px); backdrop-filter: blur(10px); }
.panel:hover { opacity: 1; background: rgba(240, 238, 233, 0.96); }

.g { color: var(--mute); }
.visually-hidden { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

/* The orange square cursor - only where there is a real pointer */
.cursor { position: fixed; left: 0; top: 0; width: 8px; height: 8px; margin: -4px 0 0 -4px; background: var(--orange); pointer-events: none; z-index: 1000; opacity: 0; transition: opacity 1.4s ease; }
.has-pointer, .has-pointer * { cursor: none !important; }
.has-pointer .cursor.on { opacity: 1; transition: none; }

/* The four-column footer */
.foot { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 20px; padding-top: 12px; border-top: 1px solid currentColor; }
.foot > div { display: flex; flex-direction: column; gap: 4px; }
.foot .lc { text-transform: none; letter-spacing: 0.02em; }
.foot .end { text-align: right; }

@keyframes blink { 0%, 49% { opacity: 1; } 50%, 100% { opacity: 0; } }
.blink { animation: blink 1.2s steps(1) infinite; }

@media (max-width: 720px) {
  :root { --pad-y: 12px; --pad-x: 16px; }
  .panel { padding: 7px 9px; }
  .foot { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; }
  .foot .end { text-align: left; }
}

@media (prefers-reduced-motion: reduce) {
  .blink { animation: none; }
}
