:root {
  --sfondo: #071018;
  --inchiostro: #e8eef4;
  --debole: #9aafc0;
  --accento: #d4a24c;
  --accento-soft: rgba(212, 162, 76, 0.35);
  --safe-top: env(safe-area-inset-top, 0px);
  --safe-bottom: env(safe-area-inset-bottom, 0px);
}

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

html,
body {
  margin: 0;
  min-height: 100%;
  min-height: 100dvh;
}

body {
  position: relative;
  display: flex;
  flex-direction: column;
  color: var(--inchiostro);
  font-family: Manrope, system-ui, sans-serif;
  background: var(--sfondo);
  overflow: hidden;
}

.atmosfera {
  position: fixed;
  inset: 0;
  pointer-events: none;
  background:
    radial-gradient(1200px 700px at 50% -10%, rgba(45, 90, 120, 0.35), transparent 55%),
    radial-gradient(900px 600px at 100% 100%, rgba(212, 162, 76, 0.12), transparent 50%),
    linear-gradient(160deg, #050b12 0%, #0a1620 45%, #08131c 100%);
}

.alone {
  position: absolute;
  border-radius: 50%;
  filter: blur(40px);
  opacity: 0.55;
  animation: respira 9s ease-in-out infinite;
}

.alone-a {
  width: min(55vw, 420px);
  height: min(55vw, 420px);
  top: 18%;
  left: 12%;
  background: rgba(70, 130, 160, 0.28);
}

.alone-b {
  width: min(45vw, 340px);
  height: min(45vw, 340px);
  right: 8%;
  bottom: 16%;
  background: rgba(212, 162, 76, 0.18);
  animation-delay: -3.5s;
}

.griglia {
  position: absolute;
  inset: 0;
  opacity: 0.18;
  background-image:
    linear-gradient(rgba(232, 238, 244, 0.05) 1px, transparent 1px),
    linear-gradient(90deg, rgba(232, 238, 244, 0.05) 1px, transparent 1px);
  background-size: 72px 72px;
  mask-image: radial-gradient(ellipse at center, #000 30%, transparent 78%);
  animation: deriva 28s linear infinite;
}

.schermo {
  position: relative;
  z-index: 1;
  flex: 1;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: flex-start;
  gap: 22px;
  width: min(920px, 92vw);
  margin: 0 auto;
  padding: calc(48px + var(--safe-top)) 0 calc(40px + var(--safe-bottom));
}

.marchio {
  margin: 0;
  font-size: clamp(0.95rem, 1.6vw, 1.1rem);
  font-weight: 700;
  letter-spacing: 0.28em;
  text-transform: uppercase;
  color: var(--accento);
  opacity: 0;
  transform: translateY(18px);
  animation: entra 0.9s ease forwards 0.1s;
}

.titolo {
  margin: 0;
  max-width: 12ch;
  font-family: "Instrument Serif", Georgia, serif;
  font-weight: 400;
  font-size: clamp(3.4rem, 12vw, 7.2rem);
  line-height: 0.92;
  letter-spacing: -0.02em;
}

.titolo .riga {
  display: block;
  opacity: 0;
  transform: translateY(28px);
  animation: entra 1s ease forwards;
}

.titolo .riga:first-child {
  animation-delay: 0.25s;
}

.titolo .corsivo {
  font-style: italic;
  color: #f3d7a0;
  animation-delay: 0.45s;
}

.sottotitolo {
  margin: 8px 0 0;
  max-width: 28em;
  color: var(--debole);
  font-size: clamp(1rem, 2.2vw, 1.2rem);
  line-height: 1.55;
  font-weight: 500;
  opacity: 0;
  transform: translateY(18px);
  animation: entra 0.95s ease forwards 0.7s;
}

.piede {
  position: relative;
  z-index: 1;
  padding: 0 4vw calc(20px + var(--safe-bottom));
  color: rgba(154, 175, 192, 0.75);
  font-size: 0.82rem;
  letter-spacing: 0.04em;
  opacity: 0;
  animation: entra 0.8s ease forwards 1s;
}

@keyframes entra {
  to {
    opacity: 1;
    transform: none;
  }
}

@keyframes respira {
  0%,
  100% {
    transform: scale(1) translate(0, 0);
  }
  50% {
    transform: scale(1.08) translate(12px, -10px);
  }
}

@keyframes deriva {
  from {
    transform: translate3d(0, 0, 0);
  }
  to {
    transform: translate3d(-72px, -72px, 0);
  }
}

@media (prefers-reduced-motion: reduce) {
  .alone,
  .griglia,
  .marchio,
  .titolo .riga,
  .sottotitolo,
  .piede {
    animation: none !important;
    opacity: 1 !important;
    transform: none !important;
  }
}

@media (max-width: 640px) {
  .schermo {
    align-items: stretch;
    gap: 18px;
  }

  .titolo {
    max-width: none;
  }
}
