:root {
  --bg: #110f0d;
  --ink: #f4efe8;
  --muted: #b7aea3;
  --faint: #9c958c;
  --line: rgba(244, 239, 232, 0.14);
  --accent: #fc5134;
  --accent-soft: rgba(252, 81, 52, 0.16);
  --serif: "Instrument Serif", Georgia, "Times New Roman", serif;
  --sans: Outfit, "Segoe UI", system-ui, sans-serif;
  --mx: 80%;
  --my: 0%;
  color-scheme: dark;
}

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

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100dvh;
  color: var(--ink);
  font-family: var(--sans);
  background:
    radial-gradient(860px 520px at 100% -8%, rgba(252, 81, 52, 0.22), transparent 56%),
    radial-gradient(680px 460px at -12% 108%, rgba(252, 81, 52, 0.1), transparent 52%),
    var(--bg);
}

::selection {
  background: var(--accent);
  color: #1c0906;
}

.spot {
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  background: radial-gradient(
    200px circle at var(--mx) var(--my),
    rgba(252, 81, 52, 0.18),
    transparent 68%
  );
  animation: drift 18s ease-in-out infinite;
}

@keyframes drift {
  0%,
  100% { transform: translate3d(0, 0, 0); }
  50% { transform: translate3d(-4%, 6%, 0); }
}

a {
  color: inherit;
}

a:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 4px;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.page {
  position: relative;
  z-index: 1;
  width: min(1120px, 100%);
  min-height: 100dvh;
  margin-inline: auto;
  display: grid;
  align-content: start;
  padding:
    max(1.75rem, env(safe-area-inset-top))
    clamp(1.25rem, 4vw, 3.5rem)
    max(2rem, env(safe-area-inset-bottom));
}

.mark {
  display: flex;
  align-items: center;
  gap: 0.7rem;
  margin: 0;
  color: var(--muted);
  font-size: 0.74rem;
  font-weight: 500;
  letter-spacing: 0.22em;
  text-transform: uppercase;
}

.dot {
  width: 0.48rem;
  height: 0.48rem;
  border-radius: 50%;
  background: var(--accent);
  box-shadow: 0 0 14px var(--accent);
  animation: pulse 3.4s ease-in-out infinite;
}

@keyframes pulse {
  0%,
  100% { opacity: 1; transform: scale(1); }
  50% { opacity: 0.4; transform: scale(0.82); }
}

.identity h1 {
  margin: 1.15rem 0 0;
  font-family: var(--serif);
  font-weight: 400;
  font-size: clamp(3.3rem, 6vw, 5.7rem);
  line-height: 0.86;
  letter-spacing: -0.045em;
  text-rendering: optimizeLegibility;
  transition: text-shadow 0.8s ease;
}

.identity h1 em {
  font-style: italic;
  font-weight: 400;
}

.identity h1:hover {
  text-shadow: 0 0 36px rgba(252, 81, 52, 0.55);
}

.lede {
  margin: 1.15rem 0 0;
  max-width: 12rem;
  color: var(--muted);
  font-size: 1.28rem;
  font-weight: 300;
  line-height: 1.35;
}

nav {
  margin-top: 2.4rem;
}

.portal {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  grid-template-rows: auto auto;
  column-gap: 1rem;
  align-items: center;
  margin-inline: -0.85rem;
  padding: 0.95rem 0.85rem 1rem;
  border-top: 1px solid var(--line);
  text-decoration: none;
  border-radius: 14px;
  -webkit-tap-highlight-color: transparent;
  transition: background 0.35s ease;
}

.portal:last-child {
  border-bottom: 1px solid var(--line);
}

.portal:hover,
.portal:focus-visible {
  background: linear-gradient(90deg, var(--accent-soft), transparent 78%);
}

.portal-name {
  grid-column: 1;
  grid-row: 1;
  font-family: var(--serif);
  font-size: clamp(2.55rem, 11vw, 3.35rem);
  font-weight: 400;
  line-height: 0.95;
  letter-spacing: -0.03em;
  text-rendering: optimizeLegibility;
  transition: color 0.35s ease, text-shadow 0.35s ease;
}

.portal-meta {
  grid-column: 1;
  grid-row: 2;
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  margin-top: 0.28rem;
  color: var(--muted);
  font-size: 0.95rem;
  font-weight: 400;
  letter-spacing: 0.01em;
  overflow-wrap: anywhere;
  transition: color 0.35s ease;
}

.portal-meta svg {
  flex: none;
  opacity: 0.85;
}

.arrow {
  grid-column: 2;
  grid-row: 1 / span 2;
  width: 1.45rem;
  height: 1.45rem;
  color: var(--muted);
  transition: transform 0.35s ease, color 0.35s ease;
}

.portal:hover .arrow,
.portal:focus-visible .arrow,
.portal:active .arrow {
  transform: translateX(6px);
  color: var(--accent);
}

.portal:active .portal-name {
  color: #fffaf4;
}

footer {
  margin-top: 1.8rem;
  color: var(--faint);
  font-size: 0.82rem;
  letter-spacing: 0.04em;
}

footer p {
  margin: 0;
}

footer a {
  color: inherit;
  text-underline-offset: 0.18em;
}

@media (hover: hover) and (pointer: fine) {
  nav:hover .portal-name,
  nav:focus-within .portal-name {
    color: var(--faint);
  }

  nav:hover .portal:hover .portal-name,
  nav:focus-within .portal:focus-visible .portal-name {
    color: #fffaf4;
    text-shadow: 0 0 28px rgba(252, 81, 52, 0.48);
  }

  nav:hover .portal:hover .portal-meta,
  nav:focus-within .portal:focus-visible .portal-meta {
    color: var(--ink);
  }
}

@media (min-width: 900px) {
  .page {
    align-content: center;
    grid-template-columns: minmax(0, 1.08fr) minmax(0, 0.92fr);
    grid-template-areas:
      "head nav"
      "foot nav";
    column-gap: clamp(2rem, 5vw, 4.5rem);
    row-gap: 1.6rem;
    padding-top: clamp(2rem, 6vh, 4rem);
    padding-bottom: clamp(2.5rem, 8vh, 5.5rem);
  }

  .identity {
    grid-area: head;
  }

  nav {
    grid-area: nav;
    align-self: end;
    margin-top: 0;
  }

  footer {
    grid-area: foot;
    margin-top: 0;
  }

  .portal-name {
    font-size: clamp(2.35rem, 2.8vw, 3.15rem);
  }
}

@media (min-width: 900px) and (max-height: 760px) {
  .identity h1 {
    font-size: 4rem;
  }

  .portal {
    padding-block: 0.7rem;
  }

  .portal-name {
    font-size: 2.15rem;
  }
}

.legal {
  position: relative;
  z-index: 1;
  width: min(42rem, 100%);
  margin-inline: auto;
  padding:
    max(1.75rem, env(safe-area-inset-top))
    clamp(1.25rem, 4vw, 2rem)
    4.5rem;
}

.back {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  color: var(--muted);
  font-size: 0.74rem;
  font-weight: 500;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  text-decoration: none;
}

.back svg {
  width: 1rem;
  height: 1rem;
  transition: transform 0.3s ease;
}

.back:hover {
  color: var(--ink);
}

.back:hover svg {
  transform: translateX(-4px);
}

.legal h1 {
  margin: 1.4rem 0 1rem;
  font-family: var(--serif);
  font-weight: 400;
  font-size: clamp(2.8rem, 7vw, 4.2rem);
  line-height: 0.95;
  letter-spacing: -0.03em;
}

.legal h2 {
  margin: 2.1rem 0 0.55rem;
  font-family: var(--serif);
  font-weight: 400;
  font-size: 1.7rem;
  letter-spacing: -0.02em;
}

.legal p {
  color: #e6dfd6;
  font-size: 1.02rem;
  line-height: 1.7;
}

.legal a {
  color: var(--accent);
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}
