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

:root {
  --bg: #070708;
  --gold-1: #8c6a1a;
  --gold-2: #c9a227;
  --gold-3: #f3d57a;
  --gold-t: #e4c66a;
  --silver: #c8c8d0;
  --text: #f4f1ea;
  --muted: #9a9aa3;
  --hair: rgba(201, 162, 39, 0.35);
  --ease: cubic-bezier(0.22, 1, 0.36, 1);
  --serif: "Playfair Display", Georgia, serif;
  --sans: Montserrat, system-ui, sans-serif;
}

html,
body {
  width: 100%;
  height: 100%;
  overflow: hidden;
  background: var(--bg);
  color: var(--text);
  font-family: var(--sans);
  -webkit-font-smoothing: antialiased;
}

#app {
  width: 100%;
  height: 100vh;
  height: 100dvh;
  position: relative;
  overflow: hidden;
  background-color: var(--bg);
  transition: background-color 650ms var(--ease);
}

#inner {
  position: relative;
  width: 100%;
  height: 100%;
  overflow: hidden;
}

.svg-defs {
  position: absolute;
  width: 0;
  height: 0;
  overflow: hidden;
}

#grain {
  position: absolute;
  inset: 0;
  pointer-events: none;
  z-index: 50;
  opacity: 0.28;
  background-repeat: repeat;
  background-size: 200px 200px;
}

#ghost-text {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  transform: translateY(-12%);
  pointer-events: none;
  user-select: none;
  z-index: 2;
  font-family: var(--serif);
  font-size: clamp(64px, 22vw, 280px);
  font-weight: 400;
  color: #f4f1ea;
  opacity: 0.07;
  line-height: 0.9;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  white-space: nowrap;
  transition: opacity 280ms var(--ease);
}

#brand {
  position: absolute;
  top: max(1.25rem, env(safe-area-inset-top, 0px));
  left: max(1rem, env(safe-area-inset-left, 0px));
  z-index: 60;
  display: flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  color: inherit;
}

#brand svg {
  width: 28px;
  height: 34px;
  display: block;
  flex-shrink: 0;
}

#brand strong {
  display: block;
  font-family: var(--serif);
  font-size: 13px;
  font-weight: 400;
  letter-spacing: 0.32em;
  text-transform: uppercase;
  color: var(--gold-t);
  line-height: 1.2;
}

#brand em {
  display: block;
  font-style: normal;
  font-size: 8px;
  letter-spacing: 0.28em;
  text-transform: uppercase;
  color: var(--silver);
}

#carousel {
  position: absolute;
  inset: 0;
  z-index: 3;
}

.carousel-item {
  position: absolute;
  aspect-ratio: 0.6 / 1;
  transition:
    transform 650ms var(--ease),
    filter 650ms var(--ease),
    opacity 650ms var(--ease),
    left 650ms var(--ease),
    height 650ms var(--ease),
    bottom 650ms var(--ease);
  will-change: transform, filter, opacity;
  cursor: pointer;
}

.carousel-item img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  object-position: bottom center;
  display: block;
  user-select: none;
  -webkit-user-drag: none;
  pointer-events: none;
}

#bottom-left {
  position: absolute;
  bottom: max(1.5rem, env(safe-area-inset-bottom, 0px));
  left: max(1rem, env(safe-area-inset-left, 0px));
  z-index: 60;
  max-width: 340px;
}

#product-kicker {
  font-size: 10px;
  letter-spacing: 0.32em;
  text-transform: uppercase;
  color: var(--gold-t);
  margin-bottom: 8px;
}

#product-title {
  font-family: var(--serif);
  font-weight: 400;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  font-size: clamp(1.05rem, 2.4vw, 1.6rem);
  color: var(--text);
  margin-bottom: 8px;
}

#product-desc {
  font-size: 12px;
  font-weight: 300;
  color: var(--muted);
  line-height: 1.7;
  margin-bottom: 18px;
  display: none;
}

#nav-buttons {
  display: flex;
  gap: 12px;
}

.nav-btn {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  background: transparent;
  border: 1px solid var(--hair);
  color: var(--gold-t);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: transform 150ms var(--ease), background-color 150ms, border-color 150ms;
}

.nav-btn:hover {
  transform: scale(1.06);
  background-color: rgba(201, 162, 39, 0.1);
  border-color: var(--gold-2);
}

.nav-btn svg {
  width: 22px;
  height: 22px;
  stroke: var(--gold-t);
  stroke-width: 1.6;
  fill: none;
  stroke-linecap: round;
  stroke-linejoin: round;
}

#discover {
  position: absolute;
  bottom: max(1.5rem, env(safe-area-inset-bottom, 0px));
  right: max(1rem, env(safe-area-inset-right, 0px));
  z-index: 60;
  display: flex;
  align-items: center;
  gap: 10px;
  font-family: var(--serif);
  font-size: clamp(18px, 3.4vw, 42px);
  font-weight: 400;
  color: var(--gold-t);
  letter-spacing: 0.04em;
  line-height: 1;
  text-transform: uppercase;
  text-decoration: none;
  transition: opacity 200ms, color 200ms;
}

#discover:hover {
  color: var(--gold-3);
}

#discover svg {
  width: 1.15rem;
  height: 1.15rem;
  stroke: currentColor;
  stroke-width: 1.6;
  fill: none;
  stroke-linecap: round;
  stroke-linejoin: round;
}

@media (min-width: 640px) {
  #brand {
    top: max(1.75rem, env(safe-area-inset-top, 0px));
    left: max(2rem, env(safe-area-inset-left, 0px));
  }

  #brand svg {
    width: 36px;
    height: 44px;
  }

  #bottom-left {
    bottom: max(4.5rem, env(safe-area-inset-bottom, 0px));
    left: max(4rem, env(safe-area-inset-left, 0px));
  }

  #product-title {
    margin-bottom: 10px;
  }

  #product-desc {
    display: block;
  }

  .nav-btn {
    width: 56px;
    height: 56px;
  }

  #discover {
    bottom: max(4.5rem, env(safe-area-inset-bottom, 0px));
    right: max(2.5rem, env(safe-area-inset-right, 0px));
  }

  #discover svg {
    width: 1.75rem;
    height: 1.75rem;
  }
}

@media (max-width: 639px) {
  #ghost-text {
    font-size: clamp(48px, 18vw, 96px);
    letter-spacing: 0.06em;
  }

  #brand em {
    display: none;
  }
}
