:root {
  --paper: #f4f0e7;
  --ivory: #fffaf1;
  --ink: #111714;
  --muted: #666b64;
  --line: rgba(17, 23, 20, 0.22);
  --orange: #e76313;
  --teal: #148b7a;
  --sky: #dceae6;
  --yellow: #efd98f;
  color-scheme: light;
}

* { box-sizing: border-box; }

html {
  min-width: 20rem;
  scroll-behavior: smooth;
  background: var(--paper);
}

body {
  min-height: 100%;
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  line-height: 1.45;
  -webkit-font-smoothing: antialiased;
}

a { color: inherit; }

.skip-link {
  position: fixed;
  top: 0.5rem;
  left: 0.5rem;
  z-index: 20;
  padding: 0.65rem 0.8rem;
  transform: translateY(-150%);
  border: 1px solid var(--ink);
  border-radius: 0.25rem;
  background: var(--ivory);
  font-weight: 800;
}

.skip-link:focus { transform: none; }

.exploration-header {
  position: relative;
  z-index: 5;
  display: flex;
  min-height: 4.25rem;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 0.6rem clamp(1rem, 3vw, 3rem);
  border-bottom: 1px solid var(--line);
  background: rgba(244, 240, 231, 0.94);
}

.exploration-header p {
  margin: 0;
  color: var(--muted);
  font-size: 0.7rem;
  font-weight: 800;
  letter-spacing: 0;
}

.wordmark {
  display: inline-flex;
  align-items: center;
  gap: 0.8rem;
  color: var(--ink);
  font-size: 0.82rem;
  font-weight: 800;
  letter-spacing: 0;
  text-decoration: none;
}

.wordmark-core {
  position: relative;
  width: 2.55rem;
  height: 2.55rem;
  flex: 0 0 auto;
  border: 1px solid rgba(17, 23, 20, 0.24);
  border-radius: 50%;
  background: var(--ivory);
}

.wordmark-core::before,
.wordmark-core::after {
  content: "";
  position: absolute;
  border-radius: 50%;
}

.wordmark-core::before {
  inset: 0.42rem;
  border: 1px solid rgba(20, 139, 122, 0.38);
}

.wordmark-core::after {
  width: 0.42rem;
  height: 0.42rem;
  top: 0.18rem;
  left: 1.05rem;
  background: var(--orange);
  box-shadow: 0.7rem 1.45rem 0 -0.08rem var(--teal);
}

main { overflow: hidden; }

.field {
  position: relative;
  display: grid;
  width: min(100%, 96rem);
  min-height: calc(88svh - 4.25rem);
  grid-template-columns: minmax(0, 1.36fr) minmax(22rem, 0.84fr);
  margin: 0 auto;
  border-bottom: 1px solid var(--line);
}

.field-visual {
  position: relative;
  min-width: 0;
  min-height: 32rem;
  margin: 0;
  overflow: hidden;
  border-right: 1px solid var(--line);
  background: var(--sky);
}

.field-visual > img {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: cover;
}

.field-visual figcaption {
  position: absolute;
  right: 0.8rem;
  bottom: 0.75rem;
  max-width: 21rem;
  padding: 0.45rem 0.6rem;
  background: rgba(17, 23, 20, 0.82);
  color: var(--ivory);
  font-size: 0.65rem;
}

.field-copy {
  display: flex;
  min-width: 0;
  flex-direction: column;
  justify-content: center;
  padding: clamp(2rem, 6vw, 5rem);
  background: var(--ivory);
}

.field-index {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  margin: 0 0 1.5rem;
  color: var(--orange);
  font-size: 0.7rem;
  font-weight: 900;
  letter-spacing: 0;
}

.field-index span {
  display: grid;
  width: 2.35rem;
  height: 2.35rem;
  place-items: center;
  border: 1px solid currentColor;
  border-radius: 50%;
  font-family: Georgia, "Times New Roman", serif;
  font-size: 1rem;
}

h1,
h2 {
  max-width: 10ch;
  margin: 0;
  font-family: Georgia, "Times New Roman", serif;
  font-size: 4.65rem;
  font-weight: 500;
  letter-spacing: 0;
  line-height: 0.96;
  text-wrap: balance;
}

.field-lead {
  max-width: 34rem;
  margin: 1.5rem 0 0;
  color: #424842;
  font-family: Georgia, "Times New Roman", serif;
  font-size: 1.35rem;
  line-height: 1.42;
}

.field-facts {
  display: grid;
  gap: 0;
  margin-top: 2.3rem;
  border-top: 1px solid var(--line);
}

.field-facts p {
  margin: 0;
  padding: 0.85rem 0;
  border-bottom: 1px solid var(--line);
  color: var(--muted);
  font-size: 0.86rem;
}

.field-facts strong {
  display: block;
  margin-bottom: 0.18rem;
  color: var(--ink);
}

.field-action {
  display: flex;
  width: 100%;
  min-height: 3.6rem;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  margin-top: 2.4rem;
  padding: 0.85rem 1rem;
  border: 1px solid var(--ink);
  border-radius: 0.3rem;
  background: var(--ink);
  color: var(--ivory);
  font-size: 0.76rem;
  font-weight: 900;
  letter-spacing: 0;
  text-decoration: none;
  transition: background 160ms ease, color 160ms ease, transform 160ms ease;
}

.field-action:hover,
.field-action:focus-visible {
  background: var(--orange);
  color: #fff;
  transform: translateY(-0.12rem);
}

.field-action:focus-visible,
.wordmark:focus-visible,
footer a:focus-visible {
  outline: 3px solid var(--teal);
  outline-offset: 3px;
}

.connection {
  position: relative;
  display: grid;
  min-height: 15rem;
  place-items: center;
  margin: 0;
  padding: 3rem 1rem;
  overflow: hidden;
  background: var(--yellow);
}

.connection p {
  position: relative;
  z-index: 1;
  max-width: 28ch;
  margin: 0;
  font-family: Georgia, "Times New Roman", serif;
  font-size: 2rem;
  line-height: 1.12;
  text-align: center;
  text-wrap: balance;
}

.connection-line {
  position: absolute;
  width: 120%;
  height: 1px;
  background: var(--orange);
  transform: rotate(-4deg);
}

.field-two {
  grid-template-columns: minmax(22rem, 0.84fr) minmax(0, 1.36fr);
}

.field-two .field-visual {
  grid-column: 2;
  border-right: 0;
  border-left: 1px solid var(--line);
}

.field-two .field-copy {
  grid-row: 1;
  grid-column: 1;
  background: #dfece8;
}

.field-two .field-index { color: var(--teal); }

.game-visual {
  display: grid;
  place-items: center;
  isolation: isolate;
  background: #f0d9c7;
}

.game-visual::before {
  content: "";
  position: absolute;
  z-index: -2;
  width: min(76%, 34rem);
  aspect-ratio: 1;
  background: url("../assets/home/cristallo-orbital-mark.png") center / contain no-repeat;
  opacity: 0.32;
}

.game-visual > img {
  z-index: 1;
  width: auto;
  height: min(78svh, 43rem);
  max-width: 76%;
  object-fit: contain;
  border: 1px solid rgba(17, 23, 20, 0.2);
  border-radius: 0.45rem;
  box-shadow: 0 1.5rem 3rem rgba(17, 23, 20, 0.15);
}

.game-thread {
  position: absolute;
  z-index: -1;
  width: 75%;
  height: 1px;
  background: var(--orange);
}

.game-thread-one { transform: rotate(14deg); }
.game-thread-two { background: var(--teal); transform: rotate(-18deg); }

.field-action-game { background: var(--teal); border-color: var(--teal); }

footer {
  display: flex;
  min-height: 7rem;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 1.5rem clamp(1rem, 3vw, 3rem);
  background: var(--ink);
  color: var(--ivory);
  font-size: 0.72rem;
}

footer a {
  font-weight: 900;
  text-decoration: none;
}

footer p { margin: 0; color: rgba(255, 250, 241, 0.68); }

@media (max-width: 900px) {
  .field,
  .field-two {
    min-height: 0;
    grid-template-columns: minmax(0, 1fr);
  }

  .field-visual,
  .field-two .field-visual {
    min-height: 0;
    aspect-ratio: 3 / 2;
    grid-row: 1;
    grid-column: 1;
    border: 0;
    border-bottom: 1px solid var(--line);
  }

  .field-copy,
  .field-two .field-copy {
    grid-row: 2;
    grid-column: 1;
    padding: 2.4rem 1.15rem 3rem;
  }

  h1,
  h2 { font-size: 3.2rem; }

  .field-lead { font-size: 1.15rem; }

  .connection { min-height: 12rem; }
  .connection p { font-size: 1.55rem; }

  .game-visual { aspect-ratio: auto; min-height: 38rem; }
  .game-visual > img { height: 34rem; max-width: 90%; }
}

@media (max-width: 480px) {
  .exploration-header { min-height: 3.65rem; padding: 0.45rem 0.75rem; }
  .exploration-header p { font-size: 0.58rem; }
  .wordmark { gap: 0.55rem; font-size: 0.68rem; }
  .wordmark-core { width: 2.2rem; height: 2.2rem; }
  .wordmark-core::after { left: 0.88rem; }
  .field-copy,
  .field-two .field-copy { padding-inline: 0.9rem; }
  h1,
  h2 { font-size: 2.75rem; }
  .field-index { align-items: flex-start; font-size: 0.61rem; }
  .field-visual figcaption { right: 0.45rem; bottom: 0.45rem; max-width: 15rem; font-size: 0.55rem; }
  .game-visual { min-height: 35rem; }
  .game-visual > img { height: 31rem; }
  footer { align-items: flex-start; flex-direction: column; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *,
  *::before,
  *::after { transition: none !important; }
}
