/*---------------------------------------
  HOMEPAGE: "TITLE SCREEN"
  (builds on the arcade styles in work.css)
-----------------------------------------*/

/* TITLE SCREEN */
.home-hero {
  padding-bottom: 0;
  border-bottom: 5px solid var(--gold);
  box-shadow: 0 5px 0 var(--ink), 0 10px 0 var(--red);
}

.home-hero h1 {
  font-size: clamp(52px, 8.5vw, 116px);
}

.title-menu {
  display: inline-flex;
  flex-direction: column;
  gap: 6px;
  list-style: none;
  padding: 0;
  margin: 0;
  text-align: left;
}

.title-menu a {
  position: relative;
  display: block;
  padding: 4px 0 0 40px;
  font-family: var(--display);
  font-size: 36px;
  line-height: 1.1;
  letter-spacing: .06em;
  color: var(--white-color);
  transition: color .15s, transform .15s;
}

.title-menu small {
  margin-left: 10px;
  font-family: var(--title-font-family);
  font-size: 14px;
  letter-spacing: .1em;
  text-transform: uppercase;
  color: rgba(255,255,255,.55);
}

.title-menu a::before {
  content: "\25B6";
  position: absolute;
  top: 10px;
  left: 4px;
  font-size: 24px;
  color: var(--gold);
  opacity: 0;
}

.title-menu li:first-child a::before,
.title-menu a:hover::before,
.title-menu a:focus::before {
  opacity: 1;
  animation: work-blink 1s steps(2, jump-none) infinite;
}

/* only the hovered item shows the cursor */
.title-menu:hover li:first-child a:not(:hover)::before,
.title-menu:focus-within li:first-child a:not(:focus)::before {
  opacity: 0;
}

.title-menu a:hover,
.title-menu a:focus {
  color: var(--gold);
  text-decoration: none;
  transform: translateX(6px);
}

.title-menu a:focus-visible {
  outline: 3px solid var(--white-color);
  outline-offset: 4px;
}

/* the squad, lined up along the bottom of the title screen */
.home-lineup {
  display: flex;
  justify-content: center;
  align-items: flex-end;
  max-width: 900px;
  margin: 56px auto 0;
  padding: 0 16px;
}

.home-lineup img {
  width: 20%;
  max-width: 190px;
  height: auto;
  margin: 0 -1.5%;
  filter: drop-shadow(0 0 22px color-mix(in srgb, var(--c) 70%, transparent));
  animation: work-rise .6s ease-out both;
}

.home-lineup img:nth-child(2),
.home-lineup img:nth-child(4) {
  width: 22%;
  max-width: 210px;
  animation-delay: .1s;
}

.home-lineup img:nth-child(3) {
  position: relative;
  z-index: 1;
  width: 26%;
  max-width: 250px;
  animation-delay: .2s;
}

/* STORY MODE */
.home-story {
  padding: 100px 0 110px;
  background: radial-gradient(circle at 20% 0%, #0e5566 0%, var(--ink) 60%);
}

.home-title {
  font-family: var(--display);
  font-size: clamp(40px, 6vw, 64px);
  letter-spacing: .04em;
  text-align: center;
  margin: 0 0 50px;
}

.home-title strong {
  color: var(--gold);
}

.dialogue {
  display: grid;
  grid-template-columns: 220px minmax(0, 1fr);
  gap: 28px;
  align-items: end;
  max-width: 980px;
  margin: 0 auto;
}

.dialogue__face {
  aspect-ratio: 400 / 440;
  overflow: hidden;
  background:
    repeating-conic-gradient(from 0deg at 50% 60%, rgba(255,255,255,.14) 0deg 6deg, transparent 6deg 18deg),
    var(--teal);
  border: 4px solid var(--white-color);
  border-radius: 24px;
  box-shadow: 8px 8px 0 var(--gold);
}

.dialogue__face img {
  display: block;
  width: 100%;
  height: auto;
}

.dialogue__box {
  position: relative;
  padding: 40px 34px 30px;
  color: var(--ink);
  background: var(--white-color);
  border: 4px solid var(--ink);
  border-radius: 22px;
  box-shadow: 0 0 0 4px var(--white-color), 10px 10px 0 4px var(--teal);
}

.dialogue__box::before {
  content: "";
  position: absolute;
  bottom: 40px;
  left: -22px;
  border: 12px solid transparent;
  border-right: 18px solid var(--ink);
  border-left: 0;
}

.dialogue__name {
  position: absolute;
  top: -22px;
  left: 26px;
  margin: 0;
  padding: 6px 16px 2px;
  font-family: var(--display);
  font-size: 24px;
  letter-spacing: .06em;
  color: var(--ink);
  background: var(--gold);
  border: 3px solid var(--ink);
  border-radius: 10px;
}

.dialogue__name span {
  margin-left: 6px;
  font-size: 16px;
  color: var(--red);
}

.dialogue__box h3 {
  font-family: var(--display);
  font-size: clamp(30px, 3.4vw, 40px);
  font-weight: normal;
  line-height: 1.05;
  letter-spacing: .03em;
  color: var(--ink);
  margin: 0 0 16px;
}

.dialogue__box h3 strong {
  color: var(--teal);
}

.dialogue__box p {
  color: #343b48;
}

.dialogue__box p:last-of-type {
  margin-bottom: 0;
}

.dialogue__next {
  position: absolute;
  right: 22px;
  bottom: 10px;
  font-size: 18px;
  color: var(--teal);
  animation: work-blink 1s steps(2, jump-none) infinite;
}

/* power-ups */
.powerups__title {
  margin: 90px 0 30px;
  font-family: var(--display);
  font-size: 40px;
  font-weight: normal;
  letter-spacing: .06em;
  text-align: center;
  color: var(--gold);
}

.powerups {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 24px;
  list-style: none;
  padding: 0;
  margin: 0;
}

.powerups li {
  padding: 26px 22px 22px;
  text-align: center;
  background: linear-gradient(160deg, rgba(255,255,255,.08), rgba(255,255,255,.02));
  border: 2px solid rgba(255,255,255,.16);
  border-radius: 20px;
  transition: transform .25s cubic-bezier(.2, 1.6, .4, 1), border-color .2s;
}

.powerups li:hover {
  border-color: var(--c);
  transform: translateY(-6px);
}

.powerups .fa {
  display: block;
  width: 72px;
  height: 72px;
  margin: 0 auto 16px;
  font-size: 32px;
  line-height: 66px;
  color: var(--white-color);
  background: var(--c);
  border: 3px solid var(--white-color);
  border-radius: 50%;
  box-shadow: 0 0 24px var(--c);
}

.powerups strong {
  display: block;
  font-family: var(--display);
  font-size: 26px;
  font-weight: normal;
  letter-spacing: .04em;
  line-height: 1.1;
  color: var(--white-color);
}

.powerups p {
  margin: 8px 0 0;
  font-size: 15px;
  color: rgba(255,255,255,.75);
}

/* FEATURED STAGES */
.home-featured__grid {
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 28px;
}

.home-featured .stage-card__name {
  font-size: 30px;
}

.home-featured__all {
  margin: 56px 0 0;
  text-align: center;
}

/* MEET THE SQUAD */
.home-squad {
  padding: 100px 0 110px;
  color: var(--ink);
  background:
    radial-gradient(rgba(11,18,32,.14) 1.4px, transparent 1.9px) 0 0 / 16px 16px,
    var(--gold);
  clip-path: polygon(0 40px, 100% 0, 100% calc(100% - 40px), 0 100%);
}

.home-squad h2 {
  font-family: var(--display);
  font-size: clamp(48px, 7vw, 84px);
  letter-spacing: .03em;
  text-align: center;
  color: var(--ink);
  margin: 0;
}

.home-squad h2 strong {
  color: var(--red);
  text-shadow: 3px 3px 0 var(--ink);
}

.home-squad__lead {
  margin: 6px 0 50px;
  font-size: 18px;
  text-align: center;
  color: var(--ink);
}

.squad-row {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 24px;
  list-style: none;
  padding: 0;
  margin: 0;
}

.squad-row a {
  display: block;
  height: 100%;
  padding: 18px 12px 16px;
  text-align: center;
  color: var(--ink);
  background: var(--white-color);
  border: 4px solid var(--ink);
  border-radius: 20px;
  box-shadow: 7px 7px 0 var(--ink);
  transform: rotate(-2deg);
  transition: transform .25s cubic-bezier(.2, 1.6, .4, 1);
}

.squad-row li:nth-child(even) a {
  transform: rotate(2deg) translateY(12px);
}

.squad-row a:hover,
.squad-row a:focus {
  color: var(--ink);
  text-decoration: none;
  transform: rotate(0) scale(1.06);
}

.squad-row a:focus-visible {
  outline: 3px solid var(--ink);
  outline-offset: 4px;
}

.squad-row img {
  display: block;
  width: 110px;
  height: 110px;
  margin: 0 auto 12px;
  object-fit: cover;
  object-position: 50% 20%;
  background: var(--c);
  border: 3px solid var(--ink);
  border-radius: 50%;
}

.squad-row strong {
  display: block;
  font-family: var(--display);
  font-size: 26px;
  font-weight: normal;
  letter-spacing: .04em;
  line-height: 1;
  color: var(--ink);
}

.squad-row small {
  display: block;
  margin-top: 6px;
  font-size: 13px;
  color: #4a5363;
}

/* RESPONSIVE */
@media (max-width: 1199px) {
  .home-featured__grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 991px) {
  .powerups {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .squad-row {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    row-gap: 36px;
  }
}

@media (max-width: 767px) {
  .dialogue {
    grid-template-columns: 1fr;
    gap: 34px;
  }

  .dialogue__face {
    width: 150px;
  }

  .dialogue__box::before {
    top: -22px;
    bottom: auto;
    left: 56px;
    border: 12px solid transparent;
    border-bottom: 18px solid var(--ink);
    border-top: 0;
  }

  .dialogue__name {
    left: auto;
    right: 20px;
  }
}

@media (max-width: 575px) {
  .title-menu a {
    padding-left: 32px;
    font-size: 30px;
  }

  .title-menu small {
    display: block;
    margin: 0 0 4px;
    font-size: 12px;
  }

  .title-menu a::before {
    font-size: 20px;
  }

  .home-lineup {
    margin-top: 40px;
  }

  .dialogue__box {
    padding: 36px 22px 28px;
  }

  .powerups,
  .home-featured__grid {
    grid-template-columns: minmax(0, 1fr);
  }

  .squad-row {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 28px 16px;
  }

  .squad-row img {
    width: 84px;
    height: 84px;
  }

  .squad-row strong {
    font-size: 22px;
  }
}
