/* Bodoni Moda (SIL OFL 1.1), ospitato nel sito: niente richieste a servizi esterni */
@font-face {
  font-family: "Bodoni Moda";
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url("/assets/fonts/bodoni-moda-latin-400-normal.woff2") format("woff2");
}

@font-face {
  font-family: "Bodoni Moda";
  font-style: normal;
  font-weight: 500;
  font-display: swap;
  src: url("/assets/fonts/bodoni-moda-latin-500-normal.woff2") format("woff2");
}

:root {
  --bg: #000;
  --fg: #fff;
  --serif: "Bodoni Moda", Didot, "Bodoni 72", "Bodoni MT", Georgia, serif;
}

html, body {
  margin: 0;
  height: 100%;
  background: var(--bg);
  color: var(--fg);
}

main {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 100vh;
  min-height: 100dvh;
}

/* Marchio ritagliato, bianco su trasparente: il nero lo dà la pagina */
.logo {
  display: block;
  width: min(60vw, 280px);
  height: auto;
}

/* Pagina 404 */
.notfound {
  flex-direction: column;
  padding: 0 16px;
  text-align: center;
  font-family: var(--serif);
}

.notfound .title {
  margin: 0 0 40px;
  font-size: clamp(0.8rem, 2.6vw, 0.95rem);
  font-weight: 500;
  letter-spacing: 0.32em;
  text-transform: uppercase;
  /* compensa lo spazio dopo l'ultima lettera, per centrare otticamente */
  padding-left: 0.32em;
}

.notfound .logo {
  width: min(50vw, 200px);
}

.notfound .back,
.notfound .back:visited,
.notfound .back:hover,
.notfound .back:active {
  color: var(--fg);
}

.notfound .back {
  display: inline-flex;
  align-items: baseline;
  gap: 0.5em;
  margin-top: 44px;
  font-size: clamp(1rem, 3.2vw, 1.15rem);
  letter-spacing: 0.04em;
  text-decoration: none;
}

/* sottolineatura sottile solo sotto il testo, piena al passaggio del mouse */
.notfound .label {
  text-decoration: underline;
  text-decoration-thickness: 1px;
  text-underline-offset: 0.35em;
  text-decoration-color: rgba(255, 255, 255, 0.35);
  transition: text-decoration-color 0.2s ease;
}

.notfound .back:hover .label,
.notfound .back:focus-visible .label {
  text-decoration-color: var(--fg);
}

.notfound .back:focus-visible {
  outline: 1px solid var(--fg);
  outline-offset: 6px;
}

.notfound .arrow {
  transition: transform 0.2s ease;
}

.notfound .back:hover .arrow {
  transform: translateX(-4px);
}

@media (prefers-reduced-motion: reduce) {
  .notfound .label,
  .notfound .arrow {
    transition: none;
  }
}
