:root {
  --cream: #fff7ec;
  --paper: #ffffff;
  --ink: #1c1917;
  --muted: #6b635b;
  --cheese: #f4c430;
  --cheese-deep: #e0a61a;
  --dot: #f6d56a;
  --line: rgba(28, 25, 23, 0.08);
  --shadow: 0 18px 40px rgba(28, 25, 23, 0.08);
  --radius: 22px;
  --max: 1080px;
  --font: "DM Sans", system-ui, sans-serif;
  --display: "Fredoka", "DM Sans", system-ui, sans-serif;
}

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

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: var(--font);
  color: var(--ink);
  background-color: var(--cream);
  background-image:
    radial-gradient(var(--dot) 1.6px, transparent 1.7px),
    radial-gradient(rgba(244, 196, 48, 0.35) 1.2px, transparent 1.3px);
  background-size: 28px 28px, 28px 28px;
  background-position: 0 0, 14px 14px;
  min-height: 100vh;
  line-height: 1.55;
  overflow-x: hidden;
}

img,
video {
  max-width: 100%;
  display: block;
}

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

.wrap {
  width: min(var(--max), calc(100% - 2rem));
  margin-inline: auto;
}

/* Flying cheese layer */
.sky {
  position: fixed;
  inset: 0;
  pointer-events: none;
  overflow: hidden;
  z-index: 0;
}

.sky .wedge {
  position: absolute;
  width: clamp(36px, 6vw, 72px);
  height: auto;
  opacity: 0.85;
  animation: drift linear infinite;
  filter: drop-shadow(0 8px 10px rgba(224, 166, 26, 0.25));
  will-change: transform;
}

@keyframes drift {
  0% {
    transform: translate3d(0, 110vh, 0) rotate(-20deg);
  }
  100% {
    transform: translate3d(var(--drift-x, 40px), -20vh, 0) rotate(340deg);
  }
}

header,
main,
footer {
  position: relative;
  z-index: 1;
}

/* Header */
.top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1.1rem 0 0.4rem;
}

.brand {
  display: flex;
  align-items: center;
  gap: 0.65rem;
  font-family: var(--display);
  font-weight: 600;
  letter-spacing: -0.02em;
  font-size: 1.15rem;
}

.brand-mark {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: var(--cheese);
  display: grid;
  place-items: center;
  box-shadow: inset -4px -5px 0 rgba(0, 0, 0, 0.06);
  position: relative;
}

.brand-mark::before,
.brand-mark::after {
  content: "";
  position: absolute;
  background: var(--cream);
  border-radius: 50%;
}

.brand-mark::before {
  width: 8px;
  height: 8px;
  top: 8px;
  left: 9px;
}

.brand-mark::after {
  width: 6px;
  height: 6px;
  bottom: 9px;
  right: 8px;
}

nav {
  display: flex;
  gap: 0.35rem;
}

nav a {
  padding: 0.45rem 0.9rem;
  border-radius: 999px;
  font-size: 0.92rem;
  font-weight: 500;
  border: 1px solid transparent;
}

nav a:hover,
nav a[aria-current="page"] {
  background: var(--paper);
  border-color: var(--line);
}

/* Hero */
.hero {
  display: grid;
  grid-template-columns: 1.05fr 0.95fr;
  gap: 2.5rem;
  align-items: center;
  padding: 2.2rem 0 3.4rem;
}

.kicker {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  font-size: 0.78rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--muted);
  font-weight: 600;
}

h1,
h2 {
  font-family: var(--display);
  letter-spacing: -0.03em;
  line-height: 1.05;
  margin: 0.35rem 0 0.8rem;
}

h1 {
  font-size: clamp(2.4rem, 6vw, 4.4rem);
}

h2 {
  font-size: clamp(1.7rem, 3.4vw, 2.4rem);
}

.lede {
  font-size: 1.08rem;
  color: var(--muted);
  max-width: 38ch;
  margin: 0 0 1.5rem;
}

.actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.7rem;
}

.btn {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.72rem 1.15rem;
  border-radius: 999px;
  font-weight: 600;
  border: 1px solid var(--ink);
  background: var(--ink);
  color: #fff;
  transition: transform 0.15s ease, background 0.15s ease;
}

.btn:hover {
  transform: translateY(-1px);
}

.btn.ghost {
  background: transparent;
  color: var(--ink);
}

.portrait {
  background: var(--paper);
  border-radius: 40% 32% 36% 28% / 32% 38% 30% 40%;
  border: 1px solid var(--line);
  box-shadow: var(--shadow);
  padding: 1.2rem 1.2rem 0;
  position: relative;
}

.portrait img {
  margin-inline: auto;
  width: min(340px, 100%);
}

.badge {
  position: absolute;
  top: 1rem;
  right: 1rem;
  background: var(--cheese);
  color: var(--ink);
  font-family: var(--display);
  font-weight: 600;
  font-size: 0.85rem;
  padding: 0.35rem 0.7rem;
  border-radius: 999px;
  transform: rotate(8deg);
}

/* Facts */
.facts {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1rem;
  padding-bottom: 3.2rem;
}

.card {
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 1.15rem 1.2rem 1.25rem;
  box-shadow: var(--shadow);
}

.card h3 {
  margin: 0 0 0.35rem;
  font-family: var(--display);
  font-size: 1.15rem;
}

.card p {
  margin: 0;
  color: var(--muted);
  font-size: 0.95rem;
}

/* Gallery page */
.page-head {
  padding: 1.8rem 0 1.4rem;
}

.page-head p {
  color: var(--muted);
  max-width: 48ch;
}

.gallery {
  display: grid;
  grid-template-columns: 1.2fr 0.8fr;
  grid-template-rows: auto auto;
  gap: 1rem;
  padding-bottom: 1.4rem;
}

.tile {
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow);
}

.tile img,
.tile video {
  width: 100%;
  height: 100%;
  object-fit: contain;
  background: #fff;
  aspect-ratio: 4 / 3;
}

.tile.tall {
  grid-row: span 2;
}

.tile.tall img {
  aspect-ratio: auto;
  min-height: 100%;
  object-fit: cover;
}

.tile figcaption,
.caption {
  padding: 0.75rem 1rem 0.95rem;
  font-size: 0.9rem;
  color: var(--muted);
}

.video-block {
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  overflow: hidden;
  margin-bottom: 3rem;
}

.video-block video {
  width: 100%;
  aspect-ratio: 16 / 9;
  background: #fff;
  object-fit: contain;
}

.video-block .caption {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  flex-wrap: wrap;
}

footer {
  border-top: 1px solid var(--line);
  padding: 1.4rem 0 2rem;
  color: var(--muted);
  font-size: 0.88rem;
}

.foot {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  flex-wrap: wrap;
}

/* Mobile */
@media (max-width: 800px) {
  .hero,
  .facts,
  .gallery {
    grid-template-columns: 1fr;
  }

  .tile.tall {
    grid-row: auto;
  }

  .tile.tall img {
    aspect-ratio: 4 / 5;
    object-fit: contain;
  }

  .hero {
    padding-top: 1.2rem;
    gap: 1.4rem;
  }

  nav a {
    padding-inline: 0.7rem;
  }
}

@media (max-width: 480px) {
  .brand span {
    display: none;
  }
}
