/* Hart — hartstudio.nl
   One dark screen: 3D cube logo top left (follows the cursor), giant off-black
   "Coming soon" top right, Dutch intro + contact along the bottom. */

/* ---------- Fonts (self-hosted: no third-party requests, no cookies) ---------- */
@font-face {
  font-family: "Switzer";
  src: url("../fonts/switzer-500.woff2") format("woff2");
  font-weight: 500;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "Big Shoulders Display";
  src: url("../fonts/big-shoulders-display-800.woff2") format("woff2");
  font-weight: 800;
  font-style: normal;
  font-display: swap;
}

/* ---------- Tokens ---------- */
:root {
  --ink: #151515;
  --cube-face: #1a1a1a;
  --cube-line: #2e2d2d;
  --ghost: #222121;
  --paper: #ece8e7;
  --paper-dim: rgba(236, 232, 231, 0.7);
  --flame: #ef521f;

  --f-display: "Big Shoulders Display", "Arial Narrow", "Helvetica Neue", sans-serif;
  --f-body: "Switzer", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;

  --gutter: 24px;
  --cube: 52px;
  --track: -0.045em;           /* headline letter-spacing */

  color-scheme: dark;
}
@media (max-width: 480px) { :root { --gutter: 16px; } }

/* ---------- Base ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { height: 100%; -webkit-text-size-adjust: 100%; text-size-adjust: 100%; }
body {
  margin: 0;
  min-height: 100%;
  background: var(--ink);
  color: var(--paper);
  font-family: var(--f-body);
  font-weight: 500;
  font-size: 16px;
  line-height: 1.5;
  letter-spacing: -0.02em;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}
img, svg { max-width: 100%; }
a:focus-visible { outline: 2px solid var(--flame); outline-offset: 4px; border-radius: 2px; }
.sprite { position: absolute; width: 0; height: 0; overflow: hidden; }
.visually-hidden {
  position: absolute !important; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}

/* ---------- Page frame ---------- */
.page {
  min-height: 100vh;
  min-height: 100svh;
  display: grid;
  grid-template-rows: auto 1fr auto;
  position: relative;
  overflow: hidden;
  isolation: isolate;
  padding-top: env(safe-area-inset-top, 0px);
  padding-bottom: env(safe-area-inset-bottom, 0px);
}
.wrap {
  width: 100%;
  padding-left: max(var(--gutter), env(safe-area-inset-left, 0px));
  padding-right: max(var(--gutter), env(safe-area-inset-right, 0px));
  position: relative;
  z-index: 1;
}

/* ---------- Header + cube logo ---------- */
.bar { display: flex; align-items: center; padding-block: 24px; }
.logo {
  display: grid; place-items: center;
  width: calc(var(--cube) * 1.7); height: calc(var(--cube) * 1.7);
  margin: calc(var(--cube) * -0.35);
  perspective: 420px;
  color: inherit; text-decoration: none;
}
.world { width: var(--cube); height: var(--cube); transform-style: preserve-3d; transform: rotateX(-18deg) rotateY(-28deg); will-change: transform; }
.cube { position: relative; width: 100%; height: 100%; transform-style: preserve-3d; }
.face {
  position: absolute; inset: 0;
  background: var(--cube-face);
  color: var(--cube-line);
  backface-visibility: hidden;
  -webkit-backface-visibility: hidden;
  border-radius: calc(var(--cube) * 0.09);
  overflow: hidden;
}
.face svg { display: block; width: 100%; height: 100%; }
.face .shade { position: absolute; inset: 0; background: #000; opacity: 0.3; }
.f-front  { transform: translateZ(calc(var(--cube) / 2)); }
.f-right  { transform: rotateY(90deg)  translateZ(calc(var(--cube) / 2)); }
.f-back   { transform: rotateY(180deg) translateZ(calc(var(--cube) / 2)); }
.f-left   { transform: rotateY(-90deg) translateZ(calc(var(--cube) / 2)); }
.f-top    { transform: rotateX(90deg)  translateZ(calc(var(--cube) / 2)); }
.f-bottom { transform: rotateX(-90deg) translateZ(calc(var(--cube) / 2)); }

/* ---------- Giant ghost headline ---------- */
.ghost {
  position: absolute; top: 0; right: 0; z-index: 0;
  margin: 0;
  padding-top: calc(env(safe-area-inset-top, 0px) + max(12px, 2vw));
  /* + letter-spacing, so the last letter lines up with the gutter */
  padding-right: calc(max(var(--gutter), env(safe-area-inset-right, 0px)) - var(--track));
  font-family: var(--f-display);
  font-weight: 800;
  text-transform: uppercase;
  font-size: clamp(110px, 27vw, 460px);
  line-height: 0.84;
  letter-spacing: var(--track);
  color: var(--ghost);
  text-align: right;
  pointer-events: none;
  user-select: none;
}
.ghost span { display: block; }
/* Phones: start the headline under the logo so they don't overlap */
@media (max-width: 600px) {
  .ghost { padding-top: calc(env(safe-area-inset-top, 0px) + 104px); }
}
.ghost .soon { animation: rise 0.9s cubic-bezier(.2, .8, .2, 1) 0.2s both; }
@keyframes rise {
  from { opacity: 0; transform: translateY(0.08em); }
  to   { opacity: 1; transform: none; }
}

/* ---------- Intro + contact ---------- */
.intro {
  display: grid;
  grid-template-columns: minmax(0, 34rem) auto;
  justify-content: space-between;
  align-items: end;
  gap: 24px;
  padding-block: 24px 32px;
}
.intro p { margin: 0; color: var(--paper-dim); font-size: 15px; text-wrap: pretty; }
.intro p strong { color: var(--paper); font-weight: 500; }
.contact { display: grid; gap: 4px; justify-items: end; text-align: right; font-size: 14px; color: var(--paper-dim); font-style: normal; }
.contact a { color: var(--paper); text-decoration: none; border-bottom: 1px solid var(--flame); }
.contact a:hover, .contact a:focus-visible { color: var(--flame); }
@media (max-width: 720px) {
  .intro { grid-template-columns: 1fr; }
  .contact { justify-items: start; text-align: left; }
}

/* ---------- 404 ---------- */
.notfound { display: grid; align-content: end; gap: 16px; padding-block: 24px 32px; }
.notfound p { margin: 0; color: var(--paper-dim); max-width: 34rem; font-size: 15px; }
.notfound p strong { color: var(--paper); font-weight: 500; }
.notfound a { color: var(--paper); text-decoration: none; border-bottom: 1px solid var(--flame); justify-self: start; }
.notfound a:hover, .notfound a:focus-visible { color: var(--flame); }

/* ---------- Motion preferences ---------- */
@media (prefers-reduced-motion: reduce) {
  .ghost .soon { animation: none; }
}
