@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500&display=swap');

:root {
  --background: #f6f5f1;
  --foreground: #111111;
  --muted: #77746d;
  --line: rgba(17, 17, 17, 0.14);
  --content-width: 1440px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background: var(--background);
  color: var(--foreground);
  font-family: "Inter", Arial, sans-serif;
  font-weight: 300;
  letter-spacing: -0.02em;
}

a {
  color: inherit;
  text-decoration: none;
}

a:hover,
a:focus-visible {
  opacity: 0.55;
}

.intro {
  position: relative;
  min-height: 100svh;
  display: grid;
  place-items: center;
  padding: 48px 24px;
}

.intro__content {
  text-align: center;
}

h1 {
  margin: 0 0 20px;
  font-size: clamp(4rem, 14vw, 11rem);
  font-weight: 500;
  line-height: 0.82;
  letter-spacing: -0.085em;
}

.phonetic,
.pronunciation,
.part-of-speech,
.definition {
  margin: 0;
}

.phonetic {
  margin-top: 38px;
  font-size: clamp(1rem, 1.5vw, 1.3rem);
}

.pronunciation {
  margin-top: 8px;
  font-size: 0.82rem;
  color: var(--muted);
}

.part-of-speech {
  margin-top: 34px;
  font-size: 0.82rem;
  font-style: italic;
  color: var(--muted);
}

.definition {
  margin-top: 12px;
  font-size: clamp(1.05rem, 2vw, 1.55rem);
}

.scroll-cue {
  position: absolute;
  bottom: 28px;
  left: 50%;
  transform: translateX(-50%);
  font-size: 1.4rem;
}

.objects {
  width: min(calc(100% - 48px), var(--content-width));
  margin: 0 auto;
}

.object {
  padding: 12vh 0;
  border-top: 1px solid var(--line);
}

.object__media {
  margin: 0;
  width: 100%;
  aspect-ratio: 16 / 10;
  overflow: hidden;
}

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

.placeholder {
  display: grid;
  place-items: center;
  background: #e8e6df;
  color: rgba(17, 17, 17, 0.28);
  font-size: clamp(0.75rem, 1vw, 0.9rem);
  letter-spacing: 0.18em;
}

.placeholder--two {
  background: #deddd7;
}

.placeholder--three {
  background: #eceae4;
}

.object__details {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 24px;
  margin-top: 20px;
}

.object__details h2 {
  margin: 0;
  font-size: clamp(1rem, 1.5vw, 1.25rem);
  font-weight: 400;
}

.object__details a {
  padding-bottom: 3px;
  border-bottom: 1px solid currentColor;
  font-size: 0.92rem;
}

footer {
  width: min(calc(100% - 48px), var(--content-width));
  margin: 12vh auto 0;
  padding: 32px 0 48px;
  border-top: 1px solid var(--line);
  display: grid;
  grid-template-columns: 1fr auto auto;
  gap: 24px;
  font-size: 0.78rem;
  color: var(--muted);
}

footer p {
  margin: 0;
}

@media (max-width: 700px) {
  .intro {
    padding: 32px 20px;
  }

  h1 {
    font-size: clamp(4rem, 23vw, 7rem);
  }

  .objects,
  footer {
    width: calc(100% - 32px);
  }

  .object {
    padding: 8vh 0;
  }

  .object__media {
    aspect-ratio: 4 / 5;
  }

  footer {
    grid-template-columns: 1fr;
    gap: 10px;
  }
}

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