.favorite-weapon-layer {
  position: fixed;
  inset: 0;
  z-index: 80;
  display: grid;
  place-items: center;
  padding: 1rem;
}

.favorite-weapon-backdrop {
  position: absolute;
  inset: 0;
  border: 0;
  background: rgba(3, 5, 8, 0.72);
}

.favorite-weapon-dialog {
  position: relative;
  z-index: 1;
  width: min(46rem, 100%);
  max-height: min(88vh, 48rem);
  overflow: auto;
  padding: 1rem;
  border: 1px solid rgba(224, 196, 122, 0.32);
  border-radius: 8px;
  background: #10141c;
  color: rgba(255, 249, 229, 0.9);
  box-shadow: 0 24px 70px rgba(0, 0, 0, 0.45);
}

.favorite-weapon-dialog > header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 0.75rem;
}

.favorite-weapon-dialog > p,
.favorite-weapon-choice-summary p {
  color: rgba(246, 232, 190, 0.74);
}

.favorite-weapon-options {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(12rem, 1fr));
  gap: 0.55rem;
  margin: 0.8rem 0;
}

.favorite-weapon-option {
  display: grid;
  gap: 0.25rem;
  min-height: 3.2rem;
  padding: 0.65rem 0.75rem;
  border: 1px solid rgba(224, 196, 122, 0.25);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.055);
  color: rgba(255, 249, 229, 0.88);
  cursor: pointer;
  font: inherit;
  text-align: left;
}

.favorite-weapon-option span {
  color: rgba(246, 232, 190, 0.58);
  font-size: 0.78rem;
}

.favorite-weapon-option:hover,
.favorite-weapon-option:focus-visible {
  border-color: rgba(235, 203, 126, 0.7);
  background: rgba(224, 196, 122, 0.14);
  outline: none;
}

.favorite-weapon-option.is-selected {
  border-color: rgba(248, 215, 130, 0.9);
  background: rgba(224, 196, 122, 0.22);
  color: #fff4cc;
}

.favorite-weapon-name-field {
  display: grid;
  gap: 0.35rem;
  margin-top: 0.75rem;
}

.favorite-weapon-name-field span {
  color: rgba(246, 232, 190, 0.78);
  font-size: 0.78rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.favorite-weapon-name-field input {
  min-height: 2.65rem;
  padding: 0.55rem 0.7rem;
  border: 1px solid rgba(224, 196, 122, 0.28);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.08);
  color: #fff4cc;
  font: inherit;
}

.favorite-weapon-name-field small {
  color: rgba(246, 232, 190, 0.6);
}

.favorite-weapon-dialog footer {
  display: flex;
  justify-content: flex-end;
  gap: 0.6rem;
  margin-top: 1rem;
}

.favorite-weapon-inline {
  display: grid;
  gap: 0.6rem;
}

@media (max-width: 720px) {
  .favorite-weapon-layer {
    align-items: end;
    padding: 0.5rem;
  }

  .favorite-weapon-dialog {
    max-height: 92vh;
  }

  .favorite-weapon-options {
    grid-template-columns: 1fr;
  }

  .favorite-weapon-dialog footer {
    flex-direction: column-reverse;
  }
}
