/* ==================================================
   NAVBAR — AETERNUM
   Incisa · Solenne · Vetro antico
   Signature UI
================================================== */

.navbar{
  position: sticky;
  top: 0;
  z-index: 999;

  background:
    linear-gradient(
      to bottom,
      rgba(252,250,246,.96),
      rgba(245,242,235,.92)
    );

  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);

  border-bottom: 1px solid rgba(0,0,0,.06);

  box-shadow:
    0 8px 24px rgba(0,0,0,.10),
    inset 0 1px 0 rgba(255,255,255,.85);

  font-family: inherit;
}

/* ===============================
   INNER CONTAINER
================================ */

.nav-inner{
  max-width: 1280px;
  margin: 0 auto;
  padding: 14px 24px;

  display: flex;
  align-items: center;
  justify-content: space-between;
}

/* ===============================
   BRAND / SIGILLO
================================ */

.brand{
  display: flex;
  align-items: center;
  gap: 10px;

  text-decoration: none;
  user-select: none;
}

.brand .logo{
  width: 32px;
  height: 32px;

  filter:
    drop-shadow(0 0 6px rgba(122,30,43,.45))
    drop-shadow(0 2px 6px rgba(0,0,0,.25));

  transition:
    transform .35s ease,
    filter .35s ease;
}

.brand span{
  font-weight: 700;
  letter-spacing: .12em;
  font-size: .8rem;
  text-transform: uppercase;

  color: var(--accent);

  text-shadow:
    0 1px 0 rgba(255,255,255,.85),
    0 -1px 0 rgba(0,0,0,.15);
}

.brand:hover .logo{
  transform: scale(1.06);
  filter:
    drop-shadow(0 0 14px rgba(122,30,43,.85))
    drop-shadow(0 4px 10px rgba(0,0,0,.35));
}

/* ===============================
   NAV LINKS — INCISIONE
================================ */

.nav-links{
  display: flex;
  align-items: center;
  gap: 26px;
}

.nav-links a{
  position: relative;

  text-decoration: none;
  text-transform: uppercase;

  font-size: .78rem;
  font-weight: 600;
  letter-spacing: .16em;

  color: var(--accent);

  padding: 6px 2px;

  text-shadow:
    0 1px 0 rgba(255,255,255,.9),
    0 -1px 0 rgba(0,0,0,.18);

  transition:
    color .25s ease,
    text-shadow .25s ease;
}

/* linea incisa */
.nav-links a::after{
  content: "";
  position: absolute;
  left: 0;
  bottom: -4px;

  width: 100%;
  height: 2px;

  background: linear-gradient(
    to right,
    transparent,
    var(--accent),
    transparent
  );

  opacity: 0;
  transform: scaleX(.4);

  transition:
    opacity .25s ease,
    transform .25s ease;
}

/* hover */
.nav-links a:hover{
  color: var(--accent-wine-d);

  text-shadow:
    0 1px 0 rgba(255,255,255,1),
    0 0 6px rgba(122,30,43,.35);
}

.nav-links a:hover::after{
  opacity: 1;
  transform: scaleX(1);
}

/* voce attiva */
.nav-links a.active{
  font-weight: 700;
}

.nav-links a.active::after{
  opacity: 1;
  transform: scaleX(1);
}

/* ===============================
   HAMBURGER — SIGILLO
================================ */

.nav-toggle{
  display: none;
  background: none;
  border: none;
  padding: 6px;
  cursor: pointer;
}

.nav-toggle span{
  display: block;
  width: 26px;
  height: 3px;
  margin: 5px 0;

  background: var(--accent);
  border-radius: 2px;

  box-shadow:
    inset 0 1px 0 rgba(255,255,255,.45),
    0 1px 2px rgba(0,0,0,.35);

  transition:
    transform .3s ease,
    opacity .3s ease;
}

/* ===============================
   MOBILE — RITO SOLENNE
================================ */

@media (max-width: 768px){

  .nav-toggle{
    display: block;
  }

  .nav-links{
    position: absolute;
    top: 68px;
    left: 0;
    width: 100%;

    background:
      linear-gradient(
        to bottom,
        rgba(252,250,246,.98),
        rgba(245,242,235,.96)
      );

    backdrop-filter: blur(14px);

    flex-direction: column;
    align-items: center;
    gap: 20px;

    padding: 26px 0;

    display: none;

    border-bottom: 1px solid rgba(0,0,0,.08);

    box-shadow:
      0 18px 40px rgba(0,0,0,.22),
      inset 0 1px 0 rgba(255,255,255,.85);
  }

  .nav-links.active{
    display: flex;
    animation: navReveal .28s ease;
  }
}

@keyframes navReveal{
  from{
    opacity: 0;
    transform: translateY(-8px);
  }
  to{
    opacity: 1;
    transform: translateY(0);
  }
}

/* ===============================
   ACCESSIBILITÀ
================================ */

.nav-links a:focus-visible,
.nav-toggle:focus-visible{
  outline: none;

  box-shadow:
    0 0 0 2px rgba(201,162,77,.45),
    0 0 12px rgba(122,30,43,.45);

  border-radius: 6px;
}

/* ===============================
   SELEZIONE TESTO — RITO
================================ */

::selection{
  background: rgba(201,162,77,.45);
  color: var(--ink-main);
}

::-moz-selection{
  background: rgba(201,162,77,.45);
  color: var(--ink-main);
}
