@font-face {
  font-family: "Outfit";
  src: url("../fonts/outfit-latin-400-normal.woff2") format("woff2");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}

:root {
  --bg: #000;
  --fg: #fff;
  --muted: #8f9aa1;
  --accent: #00b8ff;
  color-scheme: dark;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html,
body {
  height: 100%;
  margin: 0;
}

body {
  background: var(--bg);
  color: var(--fg);
  font-family: "Outfit", "Segoe UI", system-ui, -apple-system, "Helvetica Neue", Arial, sans-serif;
  font-weight: 400;
  overflow: hidden;
  overscroll-behavior: none;
  touch-action: manipulation;
  -webkit-tap-highlight-color: transparent;
  -webkit-user-select: none;
  user-select: none;
  -webkit-font-smoothing: antialiased;
}

/* The board: the eye sits in the middle of the viewport. */
.stage {
  position: fixed;
  inset: 0;
  display: grid;
  place-items: center;
  padding: env(safe-area-inset-top) env(safe-area-inset-right) env(safe-area-inset-bottom) env(safe-area-inset-left);
}

.eye {
  display: block;
  width: clamp(280px, 68vmin, 600px);
  height: auto;
  aspect-ratio: 1;
  overflow: visible;
}

/* 3D eye: a full-screen canvas behind the contact line. */
.scene {
  display: none;
  position: fixed;
  inset: 0;
  width: 100%;
  height: 100%;
  z-index: 0;
  pointer-events: none;
}

.js .scene { display: block; }
.js.fallback .scene { display: none; }

/* Flat SVG is only the fallback: hidden while the 3D eye loads and runs. */
.js .stage { visibility: hidden; }
.js.fallback .stage { visibility: visible; }

.pulse {
  position: fixed;
  left: 50%;
  top: 50%;
  z-index: 0;
  border: 1.5px solid #00b8ff;
  border-radius: 50%;
  opacity: 0;
  transform: translate(-50%, -50%);
  pointer-events: none;
}

/* Contact line, bottom of the screen. */
.contact {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 1;
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  align-items: baseline;
  column-gap: 0.6em;
  padding: 0 1rem max(1.1rem, env(safe-area-inset-bottom));
  font-size: clamp(0.75rem, 0.72rem + 0.15vw, 0.875rem);
  letter-spacing: 0.03em;
  text-transform: lowercase;
  text-align: center;
  animation: contact-in 0.9s ease 0.9s both;
}

.contact-label {
  color: var(--muted);
}

.contact-link {
  color: var(--fg);
  text-decoration: underline;
  text-decoration-color: rgb(255 255 255 / 0.3);
  text-underline-offset: 0.3em;
  -webkit-user-select: text;
  user-select: text;
  padding: 0.7rem 0.2rem; /* comfortable touch target */
  margin: -0.7rem 0;
  transition: color 0.2s ease, text-decoration-color 0.2s ease;
}

.contact-link:hover {
  color: var(--accent);
  text-decoration-color: var(--accent);
}

.contact-link:focus-visible {
  color: var(--accent);
  outline: 2px solid var(--accent);
  outline-offset: 4px;
  border-radius: 2px;
}

@keyframes contact-in {
  from { opacity: 0; }
  to   { opacity: 1; }
}

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