:root {
  color-scheme: light;
  font-family: "Trebuchet MS", "Avenir Next", Avenir, system-ui, sans-serif;
  --ink: #263d3b;
  --muted: #667872;
  --cream: #fff9e8;
  --teal: #2c7068;
  --coral: #df6849;
  --yellow: #f6c84b;
}

* { box-sizing: border-box; }

html,
body {
  min-width: 280px;
  min-height: 100%;
  margin: 0;
}

body {
  min-height: 100vh;
  min-height: 100dvh;
  display: grid;
  place-items: center;
  padding: max(30px, env(safe-area-inset-top)) max(20px, env(safe-area-inset-right)) max(30px, env(safe-area-inset-bottom)) max(20px, env(safe-area-inset-left));
  color: var(--ink);
  background:
    radial-gradient(circle at 10% 20%, rgba(255,255,255,.8) 0 3px, transparent 4px),
    radial-gradient(circle at 90% 75%, rgba(255,255,255,.7) 0 2px, transparent 3px),
    #e9f5ef;
  background-size: 58px 58px, 43px 43px, auto;
}

main { width: min(980px, 100%); }

header {
  position: relative;
  width: fit-content;
  margin: 0 auto clamp(28px, 5vw, 52px);
  text-align: center;
}

header p {
  margin: 0 0 4px;
  color: var(--muted);
  font-size: clamp(14px, 2vw, 19px);
  font-weight: 800;
}

h1 {
  margin: 0;
  font-size: clamp(3.2rem, 10vw, 7.5rem);
  letter-spacing: -.08em;
  line-height: .9;
}

h1 span {
  display: inline-block;
  color: var(--coral);
  transform: rotate(8deg);
}

.scribble {
  width: 78%;
  height: 11px;
  margin: 11px auto 0;
  border-top: 5px solid var(--yellow);
  border-radius: 50%;
  transform: rotate(-1.5deg);
}

.project-list {
  display: grid;
  grid-template-columns: 1fr;
  gap: 12px;
  width: min(640px, 100%);
  margin: 0 auto;
  padding: 0;
  list-style: none;
}

.project-list > li {
  min-width: 0;
}

.project {
  position: relative;
  min-height: 88px;
  display: flex;
  align-items: center;
  padding: 20px 76px 20px 24px;
  color: inherit;
  background: var(--cream);
  border: 3px solid var(--ink);
  border-radius: 18px;
  box-shadow: 6px 7px 0 rgba(38, 61, 59, .18);
  text-decoration: none;
  transition: transform 160ms ease, box-shadow 160ms ease;
}

.project-list > li:nth-child(2) .project {
  border-radius: 18px;
}

.project:hover {
  transform: translateY(-5px) rotate(-.5deg);
  box-shadow: 10px 14px 0 rgba(38, 61, 59, .15);
}

.project:focus-visible {
  outline: 5px solid var(--yellow);
  outline-offset: 5px;
}

.project-copy {
  min-width: 0;
}

.project-copy small,
.project-copy strong,
.project-copy em { display: block; }

.project-copy small {
  margin-bottom: 5px;
  color: var(--coral);
  font-size: 10px;
  font-weight: 900;
  letter-spacing: .08em;
  text-transform: uppercase;
}

.space .project-copy small { color: var(--teal); }

.rocket .arrow {
  background: var(--coral);
}

.project-copy strong {
  font-size: clamp(25px, 3.4vw, 37px);
  letter-spacing: .05em;
  line-height: 1;
}

.project-copy em {
  margin-top: 6px;
  color: var(--muted);
  font-size: 13px;
  font-style: normal;
  font-weight: 700;
}

.arrow {
  position: absolute;
  right: 20px;
  top: 50%;
  width: 40px;
  height: 40px;
  display: grid;
  place-items: center;
  color: #fff;
  background: var(--teal);
  border-radius: 50%;
  font-size: 23px;
  font-weight: 900;
  transition: transform 160ms ease;
  transform: translateY(-50%);
}

.project:hover .arrow { transform: translate(4px, -50%); }

@media (max-width: 640px) {
  .project { min-height: 78px; }
}

@media (prefers-reduced-motion: reduce) {
  .project,
  .arrow { transition: none; }
}
