.despedida-menu-backdrop[hidden] { display: none; }

body.despedida-menu-open { overflow: hidden; }

.despedida-menu-backdrop {
  position: fixed;
  inset: 0;
  z-index: 1000;
  overflow-y: auto;
  padding: max(4.5rem, calc(env(safe-area-inset-top) + 4rem)) .65rem max(1rem, env(safe-area-inset-bottom));
  background: rgba(0, 4, 8, .76);
  backdrop-filter: blur(8px);
}

.despedida-menu-panel {
  width: min(46rem, 100%);
  margin: 0 auto;
  overflow: hidden;
  border: 1px solid rgba(220, 164, 77, .72);
  border-radius: .85rem;
  color: #f5efe5;
  background:
    radial-gradient(circle at 88% 8%, rgba(33, 75, 86, .22), transparent 18rem),
    linear-gradient(145deg, #030b10, #061116 54%, #02070a);
  box-shadow: 0 1.5rem 5rem rgba(0, 0, 0, .72), inset 0 0 40px rgba(205, 149, 67, .035);
  font-family: "Cormorant Garamond", "Palatino Linotype", Palatino, Georgia, serif;
}

.despedida-menu-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 1.35rem 1.25rem 1rem;
}

.despedida-menu-title {
  margin: 0;
  color: #f7f0e7;
  font-family: "Cinzel", "Palatino Linotype", Georgia, serif;
  font-size: clamp(.95rem, 4vw, 1.35rem);
  font-weight: 500;
  letter-spacing: clamp(.25em, 1.5vw, .52em);
  text-transform: uppercase;
}

.despedida-menu-close {
  position: relative;
  flex: 0 0 2.8rem;
  width: 2.8rem;
  height: 2.8rem;
  padding: 0;
  border: 0;
  color: #fff;
  background: transparent;
  cursor: pointer;
}

.despedida-menu-close::before,
.despedida-menu-close::after {
  content: "";
  position: absolute;
  top: 50%;
  left: 50%;
  width: 2rem;
  height: 2px;
  background: currentColor;
}

.despedida-menu-close::before { transform: translate(-50%, -50%) rotate(45deg); }
.despedida-menu-close::after { transform: translate(-50%, -50%) rotate(-45deg); }

.despedida-menu-list {
  display: grid;
  padding: 0 1.25rem .75rem;
}

.despedida-menu-item {
  display: grid;
  grid-template-columns: 5.1rem minmax(0, 1fr) 1.25rem;
  align-items: center;
  gap: 1rem;
  min-height: 7.3rem;
  padding: .85rem 0;
  border: 0;
  border-top: 1px solid rgba(226, 210, 186, .2);
  color: inherit;
  background: transparent;
  text-decoration: none;
}

.despedida-menu-item:first-child { border-top: 0; }
.despedida-menu-item[href] { cursor: pointer; }
.despedida-menu-item[href]:hover .despedida-menu-name,
.despedida-menu-item[href]:focus-visible .despedida-menu-name { color: #fff0bc; }

.despedida-menu-item[href]:focus-visible,
.despedida-menu-close:focus-visible {
  outline: 2px solid #f1c46f;
  outline-offset: 3px;
}

.despedida-menu-thumb {
  width: 5rem;
  height: 5.7rem;
  overflow: hidden;
  border: 1px solid rgba(220, 153, 59, .82);
  border-radius: .85rem;
  background-image: url("/assets/despedida-menu-reference.webp");
  background-repeat: no-repeat;
  background-size: 480px auto;
  box-shadow: inset 0 0 18px rgba(0, 0, 0, .32);
}

.despedida-menu-thumb--1 { background-position: -48px -226px; }
.despedida-menu-thumb--2 { background-position: -48px -346px; }
.despedida-menu-thumb--3 { background-position: -48px -461px; }
.despedida-menu-thumb--4 { background-position: -48px -581px; }
.despedida-menu-thumb--5 { background-position: -48px -696px; }

.despedida-menu-copy { min-width: 0; }

.despedida-menu-name {
  display: flex;
  align-items: baseline;
  gap: .75rem;
  margin: 0;
  color: #e6b65f;
  font-size: clamp(1.3rem, 5vw, 1.75rem);
  font-weight: 500;
  line-height: 1.03;
  transition: color .2s ease;
}

.despedida-menu-number {
  flex: 0 0 auto;
  color: #efc978;
  font-variant-numeric: tabular-nums;
}

.despedida-menu-description {
  margin: .35rem 0 0 2.7rem;
  color: #eee8df;
  font-size: clamp(1rem, 4.3vw, 1.25rem);
  line-height: 1.15;
}

.despedida-menu-arrow {
  color: #f2c56c;
  font-size: 2.2rem;
  line-height: 1;
}

.despedida-menu-item[aria-current="page"] {
  margin-inline: -.65rem;
  padding-inline: .65rem;
  background: linear-gradient(90deg, rgba(216, 157, 71, .11), transparent);
}

@media (max-width: 430px) {
  .despedida-menu-backdrop { padding-inline: .4rem; }
  .despedida-menu-head { padding-inline: 1rem; }
  .despedida-menu-list { padding-inline: 1rem; }
  .despedida-menu-item {
    grid-template-columns: 4.65rem minmax(0, 1fr) 1rem;
    gap: .7rem;
    min-height: 6.65rem;
  }
  .despedida-menu-thumb {
    width: 4.55rem;
    height: 5.25rem;
  }
  .despedida-menu-name { gap: .5rem; }
  .despedida-menu-description { margin-left: 2.25rem; }
}

@media (prefers-reduced-motion: no-preference) {
  .despedida-menu-panel { animation: despedida-menu-in .24s ease-out both; }
  @keyframes despedida-menu-in {
    from { opacity: 0; transform: translateY(-10px) scale(.985); }
  }
}
