/* ==========================================================================
   TensuraLabs — design tokens & base
   Sizes are expressed in "design units" (--u): 1u = 1px at a 1440px viewport.
   ========================================================================== */
:root {
  --u: clamp(0.72px, 0.06944vw, 1.6px);
  --font-serif: 'Noto Serif', Georgia, 'Times New Roman', serif;
  --font-sans: 'Noto Sans', system-ui, -apple-system, 'Segoe UI', Roboto, Arial, sans-serif;
  --font-mono: ui-monospace, 'SFMono-Regular', Menlo, Consolas, monospace;

  --ink: #0b0c12;
  --ink-2: #16171f;
  --paper: #d5d7de;
  --cream-1: #fbf6ea;
  --cream-2: #e8d7ab;
  --gold: #c9a65a;
  --gold-soft: rgba(232, 215, 171, 0.35);
  --navy-1: #2738b9;
  --navy-2: #141f86;
  --slime: #5ea8ff;
  --slime-deep: #1d3fbf;
  --text-dim: #b7b8c6;

  --ease-out: cubic-bezier(0.22, 1, 0.36, 1);
  --ease-in-out: cubic-bezier(0.65, 0, 0.35, 1);
  --vh: 1vh;
  --header-top: calc(14 * var(--u));
  --header-h: calc(61 * var(--u));
  --content-w: calc(1091 * var(--u));
  color-scheme: dark;
}

@media (max-width: 1100px) and (min-width: 769px) {
  :root { --u: clamp(0.66px, 0.085vw, 1px); --content-w: 94vw; }
}

@media (max-width: 768px) {
  :root {
    --u: clamp(0.82px, 0.2564vw, 1.3px); /* 1u = 1px at 390px */
    --header-top: 0px;
    --header-h: calc(64 * var(--u));
    --content-w: 100vw;
  }
}

*, *::before, *::after { box-sizing: border-box; }
html, body { height: 100%; }
html {
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
  background: var(--ink);
}
body {
  margin: 0;
  overflow: hidden;
  font-family: var(--font-sans);
  font-weight: 500;
  color: #f2f2f5;
  background: var(--ink);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  -webkit-tap-highlight-color: transparent;
  overscroll-behavior: none;
}
img, svg, video, canvas { display: block; max-width: 100%; }
button, input, select, textarea { font: inherit; color: inherit; }
button { cursor: pointer; background: none; border: 0; padding: 0; }
button:disabled { cursor: not-allowed; }
a { color: inherit; text-decoration: none; }
h1, h2, h3, h4, p, ul, ol, figure { margin: 0; }
ul, ol { padding: 0; list-style: none; }
svg { fill: currentColor; }

:focus-visible { outline: 2px solid var(--slime); outline-offset: 3px; border-radius: 4px; }

.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;
}

.gold-text {
  background: linear-gradient(180deg, var(--cream-1) 0, var(--cream-2));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.noscript { position: fixed; inset: auto 0 0; padding: 16px; text-align: center; background: #111; z-index: 9999; }

/* App outlet & views ---------------------------------------------------- */
.app {
  position: fixed;
  inset: 0;
  overflow: hidden;
  isolation: isolate;
}
.view {
  position: absolute;
  inset: 0;
  outline: none;
  overflow: hidden;
  z-index: 1;
}
.view.is-entering { z-index: 2; }
.view.is-liquid-top { z-index: 3; will-change: clip-path; }
.view.is-leaving { pointer-events: none; }
.view-shade { position: absolute; inset: 0; z-index: 50; background: #000; opacity: 0; pointer-events: none; }

.liquid-canvas {
  position: fixed;
  inset: 0;
  z-index: 40;
  pointer-events: none;
  opacity: 0;
}
.liquid-canvas.is-active { opacity: 1; }

/* Generic states --------------------------------------------------------- */
.state { display: grid; gap: 12px; justify-items: center; text-align: center; padding: 48px 16px; font-size: max(14px, calc(15 * var(--u))); }
.state small { opacity: 0.6; }
.state--empty { grid-column: 1 / -1; color: #555; }

/* Pills & round arrows -------------------------------------------------- */
.pill {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-width: calc(109 * var(--u));
  height: max(30px, calc(31 * var(--u)));
  padding: 0 calc(18 * var(--u));
  border-radius: calc(8 * var(--u));
  font-size: max(12px, calc(13 * var(--u)));
  font-weight: 700;
  color: #ececf0;
  background: linear-gradient(180deg, #17181f, #050508);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.08), 0 2px 6px rgba(0, 0, 0, 0.25);
  transition: transform 0.25s var(--ease-out), background 0.25s, box-shadow 0.25s;
}
.pill svg { width: 12px; height: 12px; }
.pill:hover { transform: translateY(-1px); }
.pill.is-active { background: linear-gradient(180deg, var(--navy-1), var(--navy-2)); box-shadow: inset 0 0 0 1px rgba(160, 175, 255, 0.45), 0 4px 14px rgba(25, 40, 160, 0.35); }
.pill--light { color: #1b1b1f; background: linear-gradient(180deg, var(--cream-1), var(--cream-2)); }
.pill--dark { color: #fff; }

.round-arrow {
  display: grid;
  place-items: center;
  flex: none;
  width: max(26px, calc(24 * var(--u)));
  height: max(26px, calc(24 * var(--u)));
  border-radius: 50%;
  color: #2b2620;
  background: radial-gradient(circle at 40% 35%, #fffaf0, #e3d2a6);
  box-shadow: 0 0 0 1px rgba(0, 0, 0, 0.35), 0 0 0 3px rgba(232, 215, 171, 0.25);
  transition: transform 0.2s var(--ease-out), filter 0.2s;
}
.round-arrow svg { width: 60%; height: 60%; }
.round-arrow:hover { transform: scale(1.08); filter: brightness(1.08); }
.round-arrow:active { transform: scale(0.94); }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: 0.01ms !important; animation-iteration-count: 1 !important; transition-duration: 0.01ms !important; }
}
