/* FONT */
@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500&display=swap');

/* RESET */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

/* HTML + BODY */
html,
body {
  height: 100%;
}

/* BODY */
body {
  font-family: 'Georgia', serif;
  background-color: #E0E2E7;
  color: #1C2240;
  display: flex;
  overflow-x: hidden;
}

/* SIDEBAR */
.sidebar {
  width: 260px;
  height: 100vh;

  position: fixed;
  top: 0;
  left: 0;

  background-color: #1F2540;
  color: white;

  padding: 30px 25px;

  display: flex;
  flex-direction: column;
  align-items: flex-start;

  z-index: 1000;
  overflow-y: auto;
}

/* LOGO */
.logo {
  max-width: 200px;
  margin-bottom: 60px;
}

/* MENU DESKTOP */
.nav {
  margin-top: auto;
  margin-bottom: auto;
}

.nav a {
  display: block;
  color: #cfd3e0;
  text-decoration: none;
  font-family: 'Inter', sans-serif;
  font-size: 14px;
  letter-spacing: 3px;
  text-transform: uppercase;
  margin-bottom: 22px;
  transition: all 0.3s ease;
}

.nav a:hover {
  color: #d3541a;
  transform: translateX(4px);
}

.nav.active ~ .main .hero-text {
  opacity: 0;
}

.nav {
  z-index: 999;
}

/* BURGER */
.burger {
  display: none;
  flex-direction: column;
  gap: 6px;
  margin-top: 15px;
  cursor: pointer;

  z-index: 1000;
  position: relative;
}

.burger span {
  width: 30px;
  height: 3px;
  background-color: #d3541a;
  border-radius: 2px;
  transition: all 0.3s ease;
}

/* BURGER → X */
.burger.active span:nth-child(1) {
  transform: rotate(45deg) translate(5px, 5px);
}

.burger.active span:nth-child(2) {
  opacity: 0;
}

.burger.active span:nth-child(3) {
  transform: rotate(-45deg) translate(6px, -6px);
}

/* CONTENUTO */
.main {
  flex: 1;

  display: flex;
  align-items: center;
  justify-content: center;

  padding: 40px;
  position: relative;

  margin-left: 260px;
  width: calc(100% - 260px);

  overflow-x: hidden;

  z-index: 1;
}

/* CANVAS */
#bg {
  position: fixed;
  inset: 0;
  z-index: 0;
  width: 100%;
  height: 100%;
}
/* HERO */
.hero-text {
  font-size: 64px;
  font-style: italic;
  color: #2f2a5a;
  position: relative;
  z-index: 2;
}

/* CURSORE */
.cursor {
  color: #d3541a;
  margin-left: 5px;
  animation: blink 1s infinite;
}

@keyframes blink {
  50% {
    opacity: 0;
  }
}

/* ===== PAGINE ===== */

.page {
  max-width: 900px;
  width: 100%;

  margin: 0 auto;
  padding: 80px 40px;

  display: flex;
  flex-direction: column;
  gap: 60px;

  position: relative;
  z-index: 2;

  align-self: flex-start;
}

.block {
  opacity: 0;
  transform: translateY(40px);
  transition: all 0.8s ease;
}

/* animazione attiva */
.block.visible {
  opacity: 1;
  transform: translateY(0);
}

/* gerarchie testo */
.big {
  font-size: 42px;
  line-height: 1.2;
  color: #2f2a5a;
}

.medium {
  font-size: 26px;
  line-height: 1.4;
  color: #2f2a5a;
}

.small {
  font-size: 18px;
  line-height: 1.6;
  color: #444;
}

/* accento */
.accent {
  color: #d3541a;
}

/* EASTER OVERLAY */
#easter-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;

  background: rgba(224, 226, 231, 0.95);

  display: flex;
  align-items: center;
  justify-content: center;

  opacity: 0;
  pointer-events: none;

  z-index: 9999;

  transition: opacity 0.4s ease;
}

#easter-overlay.active {
  opacity: 1;
}

.easter-text {
  font-size: 32px;
  color: #2f2a5a;
  text-align: center;
  max-width: 600px;
}

/* glitch leggero */
.glitch {
  animation: glitch 0.4s linear;
}

@keyframes glitch {
  0% {
    transform: translate(0);
  }

  25% {
    transform: translate(2px, -2px);
  }

  50% {
    transform: translate(-2px, 2px);
  }

  75% {
    transform: translate(1px, -1px);
  }

  100% {
    transform: translate(0);
  }
}

/* ========================= */
/* MOBILE */
/* ========================= */

@media (max-width: 768px) {

  body {
    flex-direction: column;
  }

  .sidebar {
    width: 100%;
    height: auto;

    position: relative;

    padding: 20px 0;

    align-items: center;

    overflow: visible;
  }

  .logo {
    max-width: 140px;
    margin-bottom: 10px;
  }

  .burger {
    display: flex;
  }

  /* MENU OVERLAY */
  .nav {
    position: fixed;
    top: 0;
    left: 0;

    width: 100%;
    height: 100vh;

    background-color: #1F2540;

    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;

    gap: 30px;

    transform: translateY(-100%);
    transition: transform 0.4s ease;

    z-index: 998;
  }

  .nav.active {
    transform: translateY(0);
  }

  .nav a {
    font-size: 18px;
    letter-spacing: 4px;
  }

  .main {
    width: 100%;
    margin-left: 0;
    padding: 20px;
  }

  .hero-text {
    font-size: 36px;
    text-align: center;
  }

  .page {
    padding: 40px 20px;
    gap: 40px;
  }

  .big {
    font-size: 28px;
  }

  .medium {
    font-size: 20px;
  }

  .small {
    font-size: 16px;
  }

}
.page a {
  color: #d3541a;
  font-weight: bold;
  text-decoration: none;
  transition: all 0.3s ease;
}

.page a:hover {
  opacity: 0.8;
}