@font-face {
  font-family: "Rocher";
  src:
    url("./RocherColor.woff2") format("woff2"),
    url("./RocherColor.ttf") format("truetype");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}

@font-palette-values --pal-0  { font-family: "Rocher"; base-palette: 0; }
@font-palette-values --pal-1  { font-family: "Rocher"; base-palette: 1; }
@font-palette-values --pal-2  { font-family: "Rocher"; base-palette: 2; }
@font-palette-values --pal-3  { font-family: "Rocher"; base-palette: 3; }
@font-palette-values --pal-4  { font-family: "Rocher"; base-palette: 4; }
@font-palette-values --pal-5  { font-family: "Rocher"; base-palette: 5; }
@font-palette-values --pal-6  { font-family: "Rocher"; base-palette: 6; }
@font-palette-values --pal-7  { font-family: "Rocher"; base-palette: 7; }
@font-palette-values --pal-8  { font-family: "Rocher"; base-palette: 8; }
@font-palette-values --pal-9  { font-family: "Rocher"; base-palette: 9; }
@font-palette-values --pal-10 { font-family: "Rocher"; base-palette: 10; }

:root {
  color-scheme: light;
  --bg-color: #fdf9f1;
  --text-color: #2a2825;
  --note-color: rgba(42, 40, 37, 0.78);
  --selection-bg: #f0c24b;
  --selection-text: #2a2825;
  --focus-ring: rgba(0, 0, 0, 0.2);
  --sunbeam-size: 800px;
}

html,
body {
  margin: 0;
}

body {
  box-sizing: border-box;
  min-height: 100svh;
  min-height: 100dvh;
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1.5rem;
  background-color: var(--bg-color);
  color: var(--text-color);
  overflow: hidden;
  overscroll-behavior: none;
  touch-action: none;
}

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

::selection {
  background: var(--selection-bg);
  color: var(--selection-text);
}

.noise-overlay {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 50;
  opacity: 0.04;
  background: url('data:image/svg+xml;utf8,%3Csvg viewBox="0 0 200 200" xmlns="http://www.w3.org/2000/svg"%3E%3Cfilter id="noiseFilter"%3E%3CfeTurbulence type="fractalNoise" baseFrequency="0.8" numOctaves="3" stitchTiles="stitch"/%3E%3C/filter%3E%3Crect width="100%25" height="100%25" filter="url(%23noiseFilter)"/%3E%3C/svg%3E');
}

.sunbeam {
  position: fixed;
  top: 0;
  left: 0;
  width: var(--sunbeam-size);
  height: var(--sunbeam-size);
  border-radius: 50%;
  background: radial-gradient(circle, rgba(255, 212, 64, 0.08) 0%, rgba(255, 212, 64, 0) 60%);
  pointer-events: none;
  z-index: 5;
  will-change: transform, opacity;
  opacity: 0;
}

.rocher-text {
  font-family: "Rocher", sans-serif;
  font-variation-settings: "BVEL" 30, "SHDW" 13.5;
  display: inline-block;
  will-change: transform;
  transform-origin: bottom center;
  backface-visibility: hidden;
}

#name-container {
  transition: font-palette 0.22s ease;
  cursor: pointer;
  -webkit-touch-callout: none;
  -webkit-tap-highlight-color: transparent;
  touch-action: manipulation;
}

.corner-note {
  position: relative;
  z-index: 20;
  max-width: min(100%, 32rem);
  font-family: "Iowan Old Style", "Palatino Linotype", "Book Antiqua", Georgia, serif;
  font-size: 0.95rem;
  line-height: 1.35;
  color: var(--note-color);
  letter-spacing: 0.01em;
  text-align: left;
}

.corner-note-line {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  column-gap: 0.45rem;
  row-gap: 0.1rem;
}

.copy-email-link {
  appearance: none;
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  margin: 0;
  padding: 0;
  border: 0;
  background: transparent;
  color: #000;
  font: inherit;
  line-height: 1.2;
  letter-spacing: 0.01em;
  cursor: pointer;
  opacity: 0;
  transform: translateY(0.24rem);
  pointer-events: none;
  transition:
    opacity 0.46s ease,
    transform 0.46s cubic-bezier(0.2, 0.7, 0.2, 1),
    color 0.2s ease;
}

.copy-email-link.is-visible {
  opacity: 1;
  transform: translateY(0);
  pointer-events: auto;
}

.copy-email-link__separator {
  opacity: 0.7;
}

.copy-email-link__label {
  text-decoration: underline;
  text-decoration-thickness: 0.06em;
  text-underline-offset: 0.14em;
}

.copy-email-link:hover .copy-email-link__label,
.copy-email-link:focus-visible .copy-email-link__label {
  color: rgba(0, 0, 0, 0.72);
}

.copy-email-link:focus-visible {
  outline: 2px solid var(--focus-ring);
  outline-offset: 0.24rem;
}

.copy-email-link__check {
  display: inline-block;
  min-width: 0.75em;
  opacity: 0;
  transform: translateY(0.12rem);
}

.copy-email-link.is-confirmed .copy-email-link__check {
  animation: copy-check 1.25s ease;
}

.corner-note p {
  margin: 0;
}

.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
  border: 0;
}

@keyframes copy-check {
  0% {
    opacity: 0;
    transform: translateY(0.18rem);
  }

  18%,
  55% {
    opacity: 1;
    transform: translateY(0);
  }

  100% {
    opacity: 0;
    transform: translateY(-0.18rem);
  }
}

.hero {
  position: relative;
  z-index: 10;
  width: 100%;
  max-width: max-content;
  margin-inline: auto;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 1.35rem;
}

.hero-title {
  display: flex;
  width: 100%;
  max-width: calc(100vw - 3rem);
  flex-wrap: nowrap;
  justify-content: flex-start;
  margin: 0;
  font-size: 9vw;
  line-height: 1;
  text-align: left;
  letter-spacing: -0.03em;
}

.hero-title .rocher-text { padding-inline: 2px; }
.hero-title .rocher-text.tight { padding-inline: 1px; }
.hero-title .line-break { display: none; flex-basis: 100%; height: 0; }
.hero-title.is-stacked {
  flex-wrap: wrap;
  align-items: flex-start;
  row-gap: 0.18em;
  line-height: 1.1;
}
.hero-title.is-stacked .line-break { display: block; }
.hero-title.is-stacked .email-local { font-size: 1.1em; }

@media (min-width: 768px) {
  .corner-note { font-size: 1rem; }
  .hero-title { font-size: 7vw; }
}

@media (min-width: 1024px) {
  .hero-title { font-size: 6.5vw; }
}

@media (prefers-reduced-motion: reduce) {
  .sunbeam {
    display: none;
  }

  .copy-email-link,
  .copy-email-link__check,
  #name-container {
    transition-duration: 0.01ms !important;
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
  }
}

@media (prefers-contrast: more) {
  .noise-overlay {
    opacity: 0.02;
  }

  .corner-note {
    color: var(--text-color);
  }

  .copy-email-link:focus-visible {
    outline-width: 3px;
  }
}

@media (forced-colors: active) {
  .noise-overlay,
  .sunbeam {
    display: none;
  }

  .copy-email-link__separator {
    opacity: 1;
  }

  .copy-email-link {
    color: LinkText;
  }

  .copy-email-link:focus-visible {
    outline: 2px solid Highlight;
  }
}
