:root {
  --bg: #0c0c0d;
  --fg: #f2ede2;
  --accent: #d6c197;
  --serif: "Cormorant Garamond", "EB Garamond", Garamond, "Times New Roman", serif;
  --ease: cubic-bezier(0.2, 0.7, 0.1, 1);
}

* { box-sizing: border-box; }

html, body {
  margin: 0;
  padding: 0;
  background: var(--bg);
  color: var(--fg);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overflow: hidden;
  cursor: none;
  height: 100%;
}

body {
  display: grid;
  place-items: center;
  position: relative;
}

/* Grain overlay */
.grain {
  pointer-events: none;
  position: fixed;
  inset: -50%;
  z-index: 100;
  opacity: 0.07;
  mix-blend-mode: overlay;
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='240' height='240'><filter id='n'><feTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='2' stitchTiles='stitch'/><feColorMatrix values='0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 0'/></filter><rect width='100%' height='100%' filter='url(%23n)'/></svg>");
  animation: drift 8s steps(6) infinite;
}
@keyframes drift {
  0%   { transform: translate(0, 0); }
  20%  { transform: translate(-2%, 1%); }
  40%  { transform: translate(1%, -2%); }
  60%  { transform: translate(-1%, 2%); }
  80%  { transform: translate(2%, 1%); }
  100% { transform: translate(0, 0); }
}

/* Custom cursor */
.cursor {
  pointer-events: none;
  position: fixed;
  top: 0; left: 0;
  width: 14px; height: 14px;
  border: 1px solid var(--fg);
  border-radius: 50%;
  transform: translate(-50%, -50%);
  transition: width 280ms var(--ease), height 280ms var(--ease),
              background 280ms var(--ease), opacity 200ms var(--ease);
  z-index: 200;
  mix-blend-mode: difference;
  opacity: 0;
}
.cursor.is-active { opacity: 1; }
.cursor.is-hover {
  width: 64px; height: 64px;
  background: var(--fg);
}

main {
  padding: 0 7vw;
  width: 100%;
  max-width: 1100px;
  text-align: center;
}

/* Quote — main stage */
.quote {
  margin: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2.4em;
}
.quote blockquote {
  margin: 0;
  font-family: var(--serif);
  font-style: italic;
  font-weight: 300;
  font-size: clamp(28px, 4.4vw, 64px);
  line-height: 1.18;
  letter-spacing: -0.012em;
  color: var(--fg);
  max-width: 22ch;
  opacity: 0;
  transform: translateY(14px);
  transition: opacity 1100ms var(--ease) 200ms, transform 1100ms var(--ease) 200ms;
}
.quote blockquote::before {
  content: "“";
  display: block;
  font-size: 1.6em;
  line-height: 0;
  margin-bottom: 0.45em;
  color: var(--accent);
  opacity: 0.55;
}
.quote figcaption {
  font-family: var(--serif);
  font-size: 11px;
  letter-spacing: 0.42em;
  text-transform: uppercase;
  color: var(--accent);
  opacity: 0;
  transform: translateY(8px);
  transition: opacity 900ms var(--ease) 900ms, transform 900ms var(--ease) 900ms;
  display: flex;
  align-items: center;
  gap: 14px;
}
.quote figcaption::before,
.quote figcaption::after {
  content: "";
  width: 36px;
  height: 1px;
  background: var(--accent);
  opacity: 0.5;
}
.quote.in blockquote,
.quote.in figcaption {
  opacity: 1;
  transform: translateY(0);
}
.quote.in figcaption { opacity: 0.85; }

/* Wordmark — secondary */
.mark {
  position: fixed;
  bottom: 32px;
  left: 50%;
  transform: translateX(-50%);
  font-family: var(--serif);
  font-style: italic;
  font-weight: 300;
  font-size: 22px;
  letter-spacing: -0.01em;
  color: var(--fg);
  text-decoration: none;
  opacity: 0;
  transition: opacity 1200ms var(--ease) 1600ms, color 250ms var(--ease);
  cursor: none;
  z-index: 50;
}
.mark.in { opacity: 0.55; }
.mark:hover { opacity: 1; color: var(--accent); }
.mark::before {
  content: "";
  position: absolute;
  top: 50%;
  right: calc(100% + 14px);
  width: 28px;
  height: 1px;
  background: currentColor;
  opacity: 0.6;
}
.mark::after {
  content: "";
  position: absolute;
  top: 50%;
  left: calc(100% + 14px);
  width: 28px;
  height: 1px;
  background: currentColor;
  opacity: 0.6;
}

@media (max-width: 720px) {
  html, body { cursor: auto; }
  .cursor { display: none; }
  .quote blockquote { max-width: 18ch; }
  .mark { font-size: 18px; bottom: 22px; }
  .mark::before, .mark::after { width: 18px; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}
