/* ============================================================ */
/* Steam Guides QR Tile Button                                  */
/* Inline-SVG QR glyph with a dark pill background that gives   */
/* the icon contrast against any cover art, light or dark.      */
/* ============================================================ */

.steam-guide-tile-btn {
  appearance: none;
  -webkit-appearance: none;
  margin: 0;
  padding: 0;
  font: inherit;
  font-size: 0;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 30px;
  height: 30px;
  border-radius: 6px;
  background: rgba(0, 0, 0, 0.65);
  border: 1px solid rgba(102, 192, 244, 0.4);
  backdrop-filter: blur(2px);
  -webkit-backdrop-filter: blur(2px);
  color: #ffffff;
  transition:
    background 0.18s ease,
    border-color 0.18s ease,
    color 0.18s ease,
    transform 0.18s ease,
    box-shadow 0.18s ease;
}

.steam-guide-tile-btn:hover {
  background: rgba(0, 0, 0, 0.85);
  border-color: #66c0f4;
  color: #66c0f4;
  transform: translateY(-1px);
  box-shadow: 0 2px 8px rgba(102, 192, 244, 0.35);
}

.steam-guide-tile-btn:focus-visible {
  outline: 2px solid #66c0f4;
  outline-offset: 2px;
}

.steam-guide-modal a:focus-visible,
.steam-guide-modal button:focus-visible {
  outline: 2px solid #66c0f4;
  outline-offset: 2px;
}

.steam-guide-tile-btn:active {
  transform: translateY(0);
  box-shadow: 0 1px 3px rgba(102, 192, 244, 0.25);
}

.steam-guide-tile-btn .steam-guide-icon {
  width: 16px;
  height: 16px;
  display: block;
}

.steam-guide-tile-btn--grid {
  position: absolute;
  top: 8px;
  left: 8px;
  z-index: 3;
}

.library-item .steam-guide-tile-btn--grid {
  opacity: 1;
  transform: translateY(0);
  transition:
    opacity 0.18s ease,
    transform 0.18s ease,
    background 0.18s ease,
    border-color 0.18s ease,
    color 0.18s ease,
    box-shadow 0.18s ease;
}

.library-item:hover .steam-guide-tile-btn--grid:hover {
  transform: translateY(-1px);
}

@media (max-width: 768px) {
  .steam-guide-tile-btn {
    width: 34px;
    height: 34px;
  }

  .steam-guide-tile-btn .steam-guide-icon {
    width: 18px;
    height: 18px;
  }
}

.steam-guide-tile-btn--inline {
  flex: 0 0 auto;
}

.steam-guide-modal.modal-overlay {
  position: fixed;
  inset: 0;
  z-index: 10000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1.5rem;
  background: rgba(0, 0, 0, 0.82);
  overflow-y: auto;
}

.steam-guide-modal .modal-content {
  width: 100%;
  max-width: 480px;
  margin: auto;
  padding: 0;
  overflow: hidden;
  background: var(--bg2);
  border: 1px solid rgba(102, 192, 244, 0.24);
  border-radius: 8px;
  box-shadow: 0 18px 55px rgba(0, 0, 0, 0.55);
}

.steam-guide-modal .modal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 1.25rem 1.5rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.steam-guide-modal .modal-header h2 {
  margin: 0;
  color: #66c0f4;
  font-size: 1.2rem;
}

.steam-guide-modal .modal-close {
  width: 32px;
  height: 32px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: transparent;
  border: none;
  border-radius: 4px;
  color: var(--muted);
  cursor: pointer;
  font-size: 1.5rem;
  line-height: 1;
  transition: background 0.2s, color 0.2s;
}

.steam-guide-modal .modal-close:hover {
  background: rgba(255, 255, 255, 0.1);
  color: #fff;
}

.steam-guide-modal .modal-body {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 1.5rem;
}

.steam-guide-game-name {
  margin-bottom: 1rem;
  color: #66c0f4;
  font-size: 1.1rem;
  font-weight: 700;
  text-align: center;
}

.steam-guide-qr-wrapper {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 16px;
  background: #fff;
  border-radius: 8px;
  box-shadow: 0 6px 18px rgba(0, 0, 0, 0.35);
}

.steam-guide-qr-svg,
.steam-guide-qr-svg svg {
  width: 240px;
  height: 240px;
  display: block;
}

.steam-guide-helper {
  margin: 1rem 0 1.25rem;
  color: var(--muted);
  font-size: 0.92rem;
  line-height: 1.45;
  text-align: center;
}

.steam-guide-actions {
  width: 100%;
  display: flex;
  gap: 0.75rem;
  justify-content: center;
}

.steam-guide-actions a,
.steam-guide-actions button {
  min-width: 130px;
  text-align: center;
  text-decoration: none;
  transition: filter 0.2s, transform 0.2s;
}

.steam-guide-actions a:hover,
.steam-guide-actions button:hover {
  filter: brightness(1.08);
  transform: translateY(-1px);
}

.steam-guide-event-card {
  margin-bottom: 1.5rem;
}

.steam-guide-event-card .steam-guide-event-content {
  padding: 1.5rem;
}

.steam-guide-event-card h3 {
  margin: 0 0 0.5rem;
  color: #66c0f4;
  font-size: 1.1rem;
}

.steam-guide-event-card p {
  margin: 0 0 1rem;
  color: var(--muted);
  font-size: 0.9rem;
}

.steam-guide-event-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
}

.steam-guide-poll-strip {
  min-height: 48px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 1rem;
  padding: 0.75rem 1rem;
  background: rgba(102, 192, 244, 0.05);
  border: 1px solid rgba(102, 192, 244, 0.16);
  border-radius: 8px;
}

.steam-guide-poll-label {
  color: #c7d5e0;
  font-size: 0.92rem;
  min-width: 0;
}

.steam-guide-poll-label strong {
  color: #66c0f4;
}

.steam-guide-poll-btn {
  flex: 0 0 auto;
  white-space: nowrap;
}

.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

@media (max-width: 768px) {
  .steam-guide-modal.modal-overlay {
    align-items: flex-start;
    padding: 1rem;
  }

  .steam-guide-modal .modal-content {
    margin-top: 1rem;
  }

  .steam-guide-modal.is-mobile .steam-guide-actions {
    order: 2;
    flex-direction: column;
    margin-bottom: 1rem;
  }

  .steam-guide-modal.is-mobile .steam-guide-qr-wrapper {
    order: 3;
    padding: 12px;
  }

  .steam-guide-modal.is-mobile .steam-guide-helper {
    order: 4;
    margin: 0.75rem 0 0;
    font-size: 0.85rem;
  }

  .steam-guide-modal.is-mobile .steam-guide-game-name {
    order: 1;
  }

  .steam-guide-modal.is-mobile .steam-guide-actions a,
  .steam-guide-modal.is-mobile .steam-guide-actions button {
    width: 100%;
  }

  .steam-guide-qr-svg,
  .steam-guide-qr-svg svg {
    width: 200px;
    height: 200px;
  }

  .steam-guide-poll-strip {
    align-items: stretch;
    flex-direction: column;
  }
}
