/* ============================================
   SONG REQUEST PAGE STYLES
   ============================================ */

/* Page-specific body styling */
.request-page {
  background: var(--color-bg-primary, #0a0a0f);
  min-height: 100vh;
  padding: 0;
  margin: 0;
}

/* Loading Indicator */
.page-loader {
  position: fixed;
  inset: 0;
  background: #0a0a0f;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 9999;
  opacity: 1;
  transition: opacity 0.6s ease-out;
}

.page-loader.hidden {
  opacity: 0;
  pointer-events: none;
}

.loader-content {
  position: relative;
  width: 120px;
  height: 120px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.spinner {
  position: absolute;
  inset: 0;
  border: 4px solid rgba(245, 9, 0, 0.1);
  border-top-color: rgb(245, 9, 0);
  border-radius: 50%;
  animation: spin 1s linear infinite;
  box-shadow: 0 0 20px rgba(245, 9, 0, 0.2);
}

.loader-logo {
  width: 90px;
  height: 90px;
  border-radius: 50%;
  object-fit: cover;
  position: relative;
  z-index: 2;
  box-shadow: 0 0 15px rgba(0, 0, 0, 0.5);
  animation: pulse 1.5s ease-in-out infinite;
}

@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}

@keyframes pulse {

  0%,
  100% {
    transform: scale(1);
  }

  50% {
    transform: scale(1.15);
  }
}

/* Main Container */
.request-container {
  max-width: 600px;
  margin: 0 auto;
  padding: 20px;
  padding-bottom: 60px;
}

/* Header */
.request-header {
  text-align: center;
  padding: 30px 20px;
  margin-bottom: 30px;
  background: linear-gradient(135deg, rgba(245, 9, 0, 0.1) 0%, rgba(1, 1, 3, 0.8) 100%);
  border-radius: 20px;
  border: 1px solid rgba(245, 9, 0, 0.2);
  backdrop-filter: blur(10px);
}

.header-content {
  margin-bottom: 20px;
}

.header-logo {
  width: 80px;
  height: 80px;
  border-radius: 50%;
  object-fit: cover;
  margin-bottom: 15px;
  border: 3px solid rgb(245, 9, 0);
  box-shadow: 0 0 20px rgba(245, 9, 0, 0.3);
}

.header-title {
  font-family: 'Bebas Neue', sans-serif;
  font-size: 2.5rem;
  color: rgb(221, 221, 223);
  margin: 0 0 5px 0;
  letter-spacing: 2px;
}

.header-subtitle {
  font-size: 1rem;
  color: rgba(221, 221, 223, 0.7);
  margin: 0;
  font-weight: 500;
}

/* Session Status */
.session-status {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 20px;
  background: rgba(0, 0, 0, 0.3);
  border-radius: 50px;
  font-size: 0.9rem;
  font-weight: 600;
}

.session-status.active {
  background: rgba(0, 255, 0, 0.1);
  border: 1px solid rgba(0, 255, 0, 0.3);
}

.session-status.inactive {
  background: rgba(255, 0, 0, 0.1);
  border: 1px solid rgba(255, 0, 0, 0.3);
}

.status-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: rgba(221, 221, 223, 0.5);
  animation: pulse-dot 2s ease-in-out infinite;
}

.session-status.active .status-dot {
  background: #00ff00;
}

.session-status.inactive .status-dot {
  background: #ff0000;
}

@keyframes pulse-dot {

  0%,
  100% {
    opacity: 1;
  }

  50% {
    opacity: 0.5;
  }
}

.status-text {
  color: rgb(221, 221, 223);
}

/* Instagram Card */
.instagram-card {
  background: linear-gradient(135deg, rgba(131, 58, 180, 0.1) 0%, rgba(253, 29, 29, 0.1) 50%, rgba(252, 176, 69, 0.1) 100%);
  border: 1px solid rgba(253, 29, 29, 0.3);
  border-radius: 20px;
  padding: 25px;
  margin-bottom: 30px;
  backdrop-filter: blur(10px);
}

.instagram-header {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 20px;
}

.instagram-icon {
  font-size: 1.8rem;
  background: linear-gradient(45deg, #f09433 0%, #e6683c 25%, #dc2743 50%, #cc2366 75%, #bc1888 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.instagram-header h2 {
  font-family: 'Bebas Neue', sans-serif;
  font-size: 1.5rem;
  color: rgb(221, 221, 223);
  margin: 0;
  letter-spacing: 1px;
}

.instagram-profile {
  display: flex;
  align-items: center;
  gap: 15px;
  padding: 15px;
  background: rgba(0, 0, 0, 0.3);
  border-radius: 15px;
  text-decoration: none;
  transition: all 0.3s ease;
  border: 1px solid rgba(255, 255, 255, 0.1);
}

.instagram-profile:hover {
  background: rgba(0, 0, 0, 0.5);
  border-color: rgba(253, 29, 29, 0.5);
  transform: translateY(-2px);
  box-shadow: 0 5px 20px rgba(253, 29, 29, 0.2);
}

.profile-image {
  flex-shrink: 0;
}

.profile-image img {
  width: 60px;
  height: 60px;
  border-radius: 50%;
  object-fit: cover;
  border: 2px solid rgba(253, 29, 29, 0.5);
}

.profile-info {
  flex: 1;
}

.profile-name {
  font-size: 1.1rem;
  font-weight: 700;
  color: rgb(221, 221, 223);
  margin-bottom: 5px;
}

.profile-tagline {
  font-size: 0.85rem;
  color: rgba(221, 221, 223, 0.7);
  line-height: 1.4;
}

.follow-btn {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 10px 20px;
  background: linear-gradient(45deg, #f09433 0%, #e6683c 25%, #dc2743 50%, #cc2366 75%, #bc1888 100%);
  border-radius: 50px;
  color: white;
  font-weight: 700;
  font-size: 0.9rem;
  white-space: nowrap;
}

.instagram-incentive {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  margin-top: 15px;
  padding: 12px;
  background: rgba(255, 215, 0, 0.1);
  border-left: 3px solid rgba(255, 215, 0, 0.5);
  border-radius: 8px;
  font-size: 0.85rem;
  color: rgba(221, 221, 223, 0.9);
  line-height: 1.5;
}

.instagram-incentive i {
  color: rgba(255, 215, 0, 0.8);
  margin-top: 2px;
  flex-shrink: 0;
}

/* Request Form Section */
.request-form-section {
  background: rgba(1, 1, 3, 0.6);
  border: 1px solid rgba(245, 9, 0, 0.2);
  border-radius: 20px;
  padding: 30px 25px;
  backdrop-filter: blur(10px);
}

.form-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 25px;
  flex-wrap: wrap;
  gap: 10px;
}

.form-header h2 {
  font-family: 'Bebas Neue', sans-serif;
  font-size: 1.8rem;
  color: rgb(221, 221, 223);
  margin: 0;
  letter-spacing: 1px;
}

.request-counter {
  display: flex;
  align-items: center;
  gap: 5px;
  padding: 8px 16px;
  background: rgba(245, 9, 0, 0.2);
  border: 1px solid rgba(245, 9, 0, 0.4);
  border-radius: 50px;
  font-size: 0.9rem;
  font-weight: 700;
  color: rgb(221, 221, 223);
}

#request-count {
  color: rgb(245, 9, 0);
  font-size: 1.1rem;
}

/* Song Request Groups */
.song-request-group,
.requester-info-group {
  background: rgba(0, 0, 0, 0.3);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 15px;
  padding: 20px;
  margin-bottom: 20px;
}

.group-header {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 20px;
  padding-bottom: 12px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.group-header i {
  color: rgb(245, 9, 0);
  font-size: 1.2rem;
}

.group-header span {
  font-weight: 700;
  color: rgb(221, 221, 223);
  font-size: 1rem;
}

.optional-badge {
  margin-left: auto;
  padding: 4px 12px;
  background: rgba(221, 221, 223, 0.1);
  border-radius: 50px;
  font-size: 0.75rem;
  font-weight: 600;
  color: rgba(221, 221, 223, 0.6);
}

/* Form Groups */
.form-group {
  margin-bottom: 18px;
}

.form-group:last-child {
  margin-bottom: 0;
}

.form-label {
  display: block;
  margin-bottom: 8px;
  font-weight: 600;
  color: rgb(221, 221, 223);
  font-size: 0.9rem;
}

.required {
  color: rgb(245, 9, 0);
}

.label-hint {
  font-weight: 400;
  color: rgba(221, 221, 223, 0.6);
  font-size: 0.85rem;
}

.form-input {
  width: 100%;
  padding: 14px 16px;
  background: rgba(0, 0, 0, 0.4);
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 10px;
  color: rgb(221, 221, 223);
  font-size: 1rem;
  font-family: 'Inter', sans-serif;
  transition: all 0.3s ease;
  box-sizing: border-box;
}

.form-input:focus {
  outline: none;
  border-color: rgb(245, 9, 0);
  background: rgba(0, 0, 0, 0.6);
  box-shadow: 0 0 0 3px rgba(245, 9, 0, 0.1);
}

.form-input::placeholder {
  color: rgba(221, 221, 223, 0.4);
}

/* Instagram Input */
.instagram-input-wrapper {
  position: relative;
  display: flex;
  align-items: center;
}

.instagram-prefix {
  position: absolute;
  left: 16px;
  color: rgba(221, 221, 223, 0.6);
  font-weight: 600;
  pointer-events: none;
  z-index: 1;
}

.instagram-input {
  padding-left: 35px;
}

/* Song Autocomplete Dropdown */
.autocomplete-wrapper {
  position: relative;
}

.autocomplete-dropdown {
  position: absolute;
  top: 100%;
  left: 0;
  right: 0;
  max-height: 300px;
  overflow-y: auto;
  background: rgba(1, 1, 3, 0.98);
  border: 1px solid rgba(245, 9, 0, 0.3);
  border-radius: 10px;
  margin-top: 5px;
  z-index: 1000;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5);
  backdrop-filter: blur(10px);
}

.autocomplete-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px;
  cursor: pointer;
  transition: all 0.2s ease;
  border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.autocomplete-item:last-child {
  border-bottom: none;
}

.autocomplete-item:hover,
.autocomplete-item.selected {
  background: rgba(245, 9, 0, 0.15);
}

.autocomplete-artwork {
  width: 50px;
  height: 50px;
  border-radius: 8px;
  object-fit: cover;
  flex-shrink: 0;
  border: 1px solid rgba(255, 255, 255, 0.1);
}

.autocomplete-info {
  flex: 1;
  min-width: 0;
}

.autocomplete-song {
  font-weight: 600;
  color: rgb(221, 221, 223);
  font-size: 0.95rem;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.autocomplete-artist {
  font-size: 0.85rem;
  color: rgba(221, 221, 223, 0.7);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  margin-top: 2px;
}

.autocomplete-loading {
  padding: 20px;
  text-align: center;
  color: rgba(221, 221, 223, 0.6);
  font-size: 0.9rem;
}

.autocomplete-loading i {
  margin-right: 8px;
  animation: spin 1s linear infinite;
}

.autocomplete-empty {
  padding: 20px;
  text-align: center;
  color: rgba(221, 221, 223, 0.5);
  font-size: 0.9rem;
}

/* Browse & Upvote Requests Section */
.browse-requests-section {
  background: rgba(1, 1, 3, 0.6);
  border: 1px solid rgba(245, 9, 0, 0.2);
  border-radius: 20px;
  padding: 30px 25px;
  margin-bottom: 30px;
  backdrop-filter: blur(10px);
}

.browse-header {
  text-align: center;
  margin-bottom: 25px;
}

.browse-header h2 {
  font-family: 'Bebas Neue', sans-serif;
  font-size: 1.8rem;
  color: rgb(221, 221, 223);
  margin: 0 0 10px 0;
  letter-spacing: 1px;
}

.browse-subtitle {
  color: rgba(221, 221, 223, 0.7);
  font-size: 0.9rem;
  margin: 0;
}

.browse-requests-feed {
  display: flex;
  flex-direction: column;
  gap: 12px;
  max-height: 220px;
  /* Approximately 2 cards */
  overflow-y: auto;
  padding: 8px 12px 8px 5px;
  scrollbar-width: thin;
  scrollbar-color: rgba(245, 9, 0, 0.5) transparent;
}

/* Custom Scrollbar for Chrome/Safari/Edge */
.browse-requests-feed::-webkit-scrollbar {
  width: 6px;
}

.browse-requests-feed::-webkit-scrollbar-track {
  background: transparent;
}

.browse-requests-feed::-webkit-scrollbar-thumb {
  background: rgba(245, 9, 0, 0.3);
  border-radius: 10px;
}

.browse-requests-feed::-webkit-scrollbar-thumb:hover {
  background: rgba(245, 9, 0, 0.6);
}

.browse-request-card {
  background: rgba(0, 0, 0, 0.4);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 12px;
  padding: 15px;
  display: flex;
  align-items: center;
  gap: 15px;
  transition: all 0.3s ease;
}

.browse-request-card:hover {
  border-color: rgba(245, 9, 0, 0.3);
  background: rgba(0, 0, 0, 0.6);
}

.browse-request-info {
  flex: 1;
  min-width: 0;
}

.browse-song-name {
  font-weight: 700;
  color: rgb(221, 221, 223);
  font-size: 1rem;
  margin-bottom: 4px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.browse-artist-name {
  font-size: 0.85rem;
  color: rgba(221, 221, 223, 0.7);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.browse-requester {
  font-size: 0.75rem;
  color: rgba(221, 221, 223, 0.5);
  margin-top: 4px;
}

.upvote-btn {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  padding: 10px 14px;
  background: rgba(245, 9, 0, 0.1);
  /* Dark red background */
  border: 1px solid rgba(245, 9, 0, 0.3);
  /* Muted red border */
  border-radius: 12px;
  cursor: pointer;
  transition: all 0.3s ease;
  flex-shrink: 0;
  min-width: 48px;
}

.upvote-btn:hover:not(.upvoted) {
  background: rgba(245, 9, 0, 0.2);
  border-color: rgba(245, 9, 0, 0.6);
  transform: translateY(-2px);
}

.upvote-btn.upvoted {
  background: rgba(245, 9, 0, 0.35);
  border-color: rgb(245, 9, 0);
  cursor: default;
}

.upvote-icon {
  font-size: 1.3rem;
  color: #f50900;
  /* Signature red */
  transition: all 0.3s ease;
}

.upvote-btn.upvoted .upvote-icon {
  color: #f50900;
  transform: scale(1.1);
}

.upvote-count {
  font-weight: 800;
  color: #ffffff;
  font-size: 0.95rem;
}

.upvote-btn.upvoted .upvote-count {
  color: #ffffff;
}

.browse-empty {
  text-align: center;
  padding: 40px 20px;
  color: rgba(221, 221, 223, 0.5);
}

.browse-empty i {
  font-size: 3rem;
  margin-bottom: 15px;
  opacity: 0.5;
}

.browse-empty p {
  margin: 0;
  font-size: 0.95rem;
}

/* Submit Button */
.submit-btn {
  width: 100%;
  margin-top: 25px;
  padding: 16px;
  font-size: 1.1rem;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  background: linear-gradient(135deg, rgb(245, 9, 0) 0%, rgba(245, 9, 0, 0.8) 100%);
  border: none;
  border-radius: 12px;
  color: white;
  cursor: pointer;
  transition: all 0.3s ease;
  box-shadow: 0 4px 15px rgba(245, 9, 0, 0.3);
}

.submit-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 25px rgba(245, 9, 0, 0.5);
}

.submit-btn:active {
  transform: translateY(0);
}

.submit-btn:disabled {
  opacity: 0.5;
  cursor: not-allowed;
  transform: none;
}

/* Error Message */
.error-message {
  margin-top: 15px;
  padding: 15px 20px;
  background: rgba(245, 9, 0, 0.25);
  border: 1px solid rgba(245, 9, 0, 0.5);
  border-radius: 12px;
  color: #ffffff;
  font-size: 0.95rem;
  font-weight: 600;
  text-align: center;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.4);
  animation: fadeIn 0.3s ease-out;
  position: relative;
  line-height: 1.4;
  transition: opacity 0.4s ease, transform 0.4s ease;
}

.error-message.hiding {
  opacity: 0 !important;
  transform: translateY(10px);
}

@keyframes fadeIn {
  from {
    opacity: 0;
    transform: translateY(-10px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* Session Inactive */
.session-inactive {
  text-align: center;
  padding: 40px 20px;
}

.session-inactive i {
  font-size: 4rem;
  color: rgba(245, 9, 0, 0.6);
  margin-bottom: 20px;
}

.session-inactive h3 {
  font-family: 'Bebas Neue', sans-serif;
  font-size: 1.8rem;
  color: rgb(221, 221, 223);
  margin: 0 0 10px 0;
  letter-spacing: 1px;
}

.session-inactive p {
  color: rgba(221, 221, 223, 0.7);
  margin-bottom: 25px;
  line-height: 1.6;
}

/* Footer */
.request-footer {
  text-align: center;
  padding: 30px 20px;
  margin-top: 40px;
  color: rgba(221, 221, 223, 0.6);
  font-size: 0.9rem;
}

.request-footer a {
  color: rgb(245, 9, 0);
  text-decoration: none;
  font-weight: 600;
}

.request-footer a:hover {
  text-decoration: underline;
}

.footer-socials {
  display: flex;
  justify-content: center;
  gap: 15px;
  margin-top: 15px;
}

.footer-socials a {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  background: rgba(245, 9, 0, 0.1);
  border: 1px solid rgba(245, 9, 0, 0.3);
  border-radius: 50%;
  color: rgb(221, 221, 223);
  font-size: 1.2rem;
  transition: all 0.3s ease;
}

.footer-socials a:hover {
  background: rgba(245, 9, 0, 0.3);
  transform: translateY(-3px);
}

/* Success Modal */
.modal {
  position: fixed;
  inset: 0;
  z-index: 10000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
}

.modal-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.8);
  backdrop-filter: blur(5px);
}

.modal-content {
  position: relative;
  z-index: 1;
  max-width: 450px;
  width: 100%;
}

.success-modal-content {
  background: linear-gradient(135deg, rgba(1, 1, 3, 0.95) 0%, rgba(20, 20, 30, 0.95) 100%);
  border: 1px solid rgba(245, 9, 0, 0.3);
  border-radius: 20px;
  padding: 40px 30px;
  text-align: center;
  box-shadow: 0 10px 50px rgba(0, 0, 0, 0.5);
}

.success-icon {
  font-size: 4rem;
  color: #00ff00;
  margin-bottom: 20px;
  animation: scale-in 0.5s ease-out;
}

@keyframes scale-in {
  from {
    transform: scale(0);
    opacity: 0;
  }

  to {
    transform: scale(1);
    opacity: 1;
  }
}

.success-modal-content h2 {
  font-family: 'Bebas Neue', sans-serif;
  font-size: 2rem;
  color: rgb(221, 221, 223);
  margin: 0 0 15px 0;
  letter-spacing: 1px;
}

.success-modal-content>p {
  color: rgba(221, 221, 223, 0.8);
  margin-bottom: 25px;
  line-height: 1.6;
}

.success-instagram-reminder {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 15px;
  background: linear-gradient(135deg, rgba(131, 58, 180, 0.2) 0%, rgba(253, 29, 29, 0.2) 100%);
  border: 1px solid rgba(253, 29, 29, 0.3);
  border-radius: 12px;
  margin-bottom: 25px;
}

.success-instagram-reminder i {
  font-size: 1.5rem;
  background: linear-gradient(45deg, #f09433 0%, #e6683c 25%, #dc2743 50%, #cc2366 75%, #bc1888 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.success-instagram-reminder p {
  margin: 0;
  color: rgb(221, 221, 223);
  font-size: 0.9rem;
}

.success-instagram-reminder a {
  color: rgb(245, 9, 0);
  font-weight: 700;
  text-decoration: none;
}

.success-instagram-reminder a:hover {
  text-decoration: underline;
}

/* Mobile Responsiveness */
@media (max-width: 768px) {
  .request-container {
    padding: 15px;
  }

  .header-title {
    font-size: 2rem;
  }

  .header-logo {
    width: 70px;
    height: 70px;
  }

  .instagram-card {
    padding: 20px;
  }

  .instagram-profile {
    flex-direction: column;
    text-align: center;
  }

  .profile-info {
    text-align: center;
  }

  .follow-btn {
    width: 100%;
    justify-content: center;
  }

  .request-form-section {
    padding: 25px 20px;
  }

  .form-header {
    flex-direction: column;
    align-items: flex-start;
  }

  .song-request-group,
  .requester-info-group {
    padding: 18px;
  }
}

@media (max-width: 480px) {
  .header-title {
    font-size: 1.8rem;
  }

  .form-header h2 {
    font-size: 1.5rem;
  }

  .instagram-header h2 {
    font-size: 1.3rem;
  }

  .profile-image img {
    width: 50px;
    height: 50px;
  }
}