* {
    -webkit-user-select: none;
    -ms-user-select: none;
    user-select: none;
    box-sizing: border-box;
}

body {
  margin: 0;
  font-family: "Funnel Display", serif;
  background: linear-gradient(135deg, #1a0000 0%, #4a0000 25%, #8b0000 50%, #4a0000 75%, #1a0000 100%);
  background-size: 400% 400%;
  animation: gradientShift 20s ease infinite;
  background-attachment: fixed;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: flex-start;
  color: #fff;
  padding: 0;
  overflow-x: hidden;
}

@keyframes gradientShift {
  0% { background-position: 0% 50%; }
  50% { background-position: 100% 50%; }
  100% { background-position: 0% 50%; }
}

html,
body {
  height: 100%;
  width: 100%;
}

#twitch-embed {
  width: 100%;
  max-width: 1050px;
  height: 620px;
  margin-top: 20px;
  min-height: 620px;
  border-radius: 15px;
  overflow: hidden;
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.6);
  border: 2px solid rgba(255, 0, 0, 0.3);
  transition: all 0.3s ease;
}

#twitch-embed:hover {
  box-shadow: 0 15px 50px rgba(255, 0, 0, 0.3);
  transform: translateY(-2px);
  border-color: rgba(255, 0, 0, 0.5);
}

#loading-screen {
  position: fixed;
  width: 100%;
  height: 100%;
  background: radial-gradient(circle at center, #1a0000 0%, #000000 100%);
  z-index: 9999;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  animation: fadeOut 0.6s ease forwards;
  animation-delay: 1.5s;
  overflow: hidden;
}

@keyframes fadeOut {
  to { opacity: 0; visibility: hidden; }
}

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

.spinner-border {
  position: absolute;
  border: 3px solid rgba(255, 0, 0, 0.1);
  border-top: 3px solid #ff0000;
  border-right: 3px solid #ff3333;
  border-radius: 50%;
  width: 100%;
  height: 100%;
  animation: spin 1s ease-in-out infinite;
  filter: drop-shadow(0 0 10px rgba(255, 0, 0, 0.5));
}

.loading-image {
  width: 80px;
  height: 80px;
  animation: gentlePulse 2s ease-in-out infinite;
  filter: drop-shadow(0 0 15px rgba(255, 0, 0, 0.6));
  object-fit: contain;
  z-index: 1;
}

@keyframes gentlePulse {
  0%, 100% { 
    transform: scale(1); 
    opacity: 1; 
  }
  50% { 
    transform: scale(1.03); 
    opacity: 0.95; 
  }
}

#loading-screen::after {
  content: 'Loading...';
  position: absolute;
  bottom: 30%;
  font-size: 24px;
  font-weight: 700;
  color: #ff0000;
  text-shadow: 0 0 20px rgba(255, 0, 0, 0.8);
  animation: fadeInOut 1.5s ease-in-out infinite;
  letter-spacing: 3px;
}

@keyframes fadeInOut {
  0%, 100% { opacity: 0.5; }
  50% { opacity: 1; }
}

/* Esconder scrollbar durante loading */
body.loading {
  overflow: hidden;
}

.image-container {
  text-align: center;
  margin: 30px 0 20px;
  transition: transform 0.3s ease;
  filter: drop-shadow(0 10px 25px rgba(0, 0, 0, 0.5));
}

.image-container:hover {
  transform: scale(1.03);
  filter: drop-shadow(0 15px 35px rgba(255, 0, 0, 0.4));
}

.custom-image {
  max-width: 45%;
  height: auto;
  animation: floatIn 0.8s ease-out;
}

@keyframes floatIn {
  from { 
    opacity: 0; 
    transform: translateY(-20px); 
  }
  to { 
    opacity: 1; 
    transform: translateY(0); 
  }
}

.social-icons {
  display: flex;
  justify-content: center;
  gap: 15px;
  margin: 30px 0 20px;
  flex-wrap: wrap;
}

.social-icons a {
  width: 55px;
  height: 55px;
  display: flex;
  align-items: center;
  justify-content: center;
  text-decoration: none;
  border-radius: 12px;
  overflow: visible;
  transition: all 0.3s ease;
  background: rgba(255, 255, 255, 0.15);
  backdrop-filter: blur(10px);
  border: 2px solid rgba(255, 255, 255, 0.25);
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.3);
}

.social-icons a:hover {
  transform: translateY(-3px) scale(1.05);
  box-shadow: 0 6px 20px rgba(255, 0, 0, 0.4);
  background: rgba(255, 255, 255, 0.25);
  border-color: rgba(255, 255, 255, 0.4);
}

.social-icons svg {
  width: 28px;
  height: 28px;
}

.social-icons img {
  width: 32px;
  height: 32px;
  object-fit: contain;
}

.links {
  display: flex;
  flex-wrap: wrap;
  gap: 20px;
  justify-content: center;
  margin-top: 20px;
}

.link-card {
  position: relative;
  display: flex;
  flex-direction: row;
  align-items: center;
  justify-content: space-between;
  width: 1100px;
  padding: 25px;
  border-radius: 15px;
  background: rgba(0, 0, 0, 0.6);
  backdrop-filter: blur(15px);
  border: 1px solid rgba(255, 255, 255, 0.1);
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.5);
  transition: all 0.3s ease;
  overflow: visible;
}

@keyframes cardSlideIn {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.link-card::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 5px;
  height: 100%;
  border-radius: 15px 0 0 15px;
}

.link-card::after {
  content: "";
  position: absolute;
  top: 0;
  right: 0;
  width: 5px;
  height: 100%;
  border-radius: 0 15px 15px 0;
}

.link-card.csgonet::before,
.link-card.csgonet::after {
  background: #2ab6f7;
}

.link-card.betano::before,
.link-card.betano::after {
  background: #ff7300;
}

.link-card.prozis::before,
.link-card.prozis::after {
  background: #ff0000;
}

.link-card.csgofast::before,
.link-card.csgofast::after {
  background: #ffc107;
}

.link-card.asus::before,
.link-card.asus::after {
  background: #2007ff;
}

.link-card.faceit::before,
.link-card.faceit::after {
  background: #ff6a07;
}

.link-card.forthewin::before,
.link-card.forthewin::after {
  background: #ff0707;
}

.link-card:hover {
  transform: translateY(-3px);
  box-shadow: 0 12px 35px rgba(0, 0, 0, 0.6);
  background: rgba(0, 0, 0, 0.7);
  border-color: rgba(255, 255, 255, 0.2);
}

.link-card span {
  font-weight: bold;
  font-size: 18px;
  margin-right: auto;
}

.btn-container {
  display: flex;
  flex-direction: column;
  gap: 10px;
  width: 10%;
  margin-right: 10px;
}

.btn {
  padding: 12px 20px;
  border: none;
  border-radius: 10px;
  font-weight: 700;
  cursor: pointer;
  width: 100%;
  transition: all 0.3s cubic-bezier(0.68, -0.55, 0.265, 1.55);
  text-transform: uppercase;
  letter-spacing: 1px;
  font-size: 13px;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
  position: relative;
  overflow: hidden;
}

.btn::before {
  content: '';
  position: absolute;
  top: 50%;
  left: 50%;
  width: 0;
  height: 0;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.3);
  transform: translate(-50%, -50%);
  transition: width 0.5s, height 0.5s;
}

.btn:hover::before {
  width: 300px;
  height: 300px;
}

.btn:hover {
  transform: translateY(-3px);
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.3);
}

.btn:active {
  transform: translateY(-1px);
}

.link-icon {
  max-width: 160px;
  height: auto;
  margin-right: auto;
  filter: drop-shadow(0 4px 8px rgba(0, 0, 0, 0.3));
  transition: all 0.3s ease;
  image-rendering: -webkit-optimize-contrast;
  image-rendering: crisp-edges;
  object-fit: contain;
}

.link-icon:hover {
  transform: scale(1.05);
  filter: drop-shadow(0 6px 12px rgba(0, 0, 0, 0.4));
}

.btn.informacoes {
  background: transparent;
  color: #fff;
  border: 2px solid rgba(255, 255, 255, 0.6);
  backdrop-filter: blur(10px);
}

.btn.informacoes:hover {
  background: rgba(255, 255, 255, 0.15);
  border-color: #fff;
}

.info-container {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  justify-content: center;
  margin-right: 30px;
}

.info-square {
  width: 155px;
  height: 145px;
  background: rgba(0, 0, 0, 0.5);
  backdrop-filter: blur(10px);
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 12px;
  text-align: center;
  border: 1px solid rgba(255, 255, 255, 0.15);
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.3);
  transition: all 0.3s ease;
}

.info-square:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.4);
  border-color: rgba(255, 255, 255, 0.25);
  background: rgba(0, 0, 0, 0.6);
}

.info-square p {
  position: relative;
  z-index: 1;
  margin: 0;
  font-weight: 600;
  text-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
}

.btn.link {
  background: #ffc107;
  color: #ffffff;
}

.link-card.csgonet .btn.link {
  background: #2ab6f7;
}

.link-card.betano .btn.link {
  background: #ff7300;
}

.link-card.prozis .btn.link {
  background: #ff0000;
}

.link-card.csgofast .btn.link {
  background: #ffc107;
}

.link-card.asus .btn.link {
  background: #2007ff;
}

.link-card.faceit .btn.link {
  background: #ff6a07;
}

.link-card.forthewin .btn.link {
  background: #ff0707;
}

/* .link-card.skins .btn.link {
    background: #b3ff00;
} */

.popup {
  display: none;
  position: fixed;
  left: 50%;
  top: 50%;
  transform: translate(-50%, -50%) scale(0.9);
  width: 90%;
  max-width: 550px;
  max-height: 85vh;
  background: linear-gradient(135deg, #2a2a2a 0%, #3d3d3d 50%, #2a2a2a 100%);
  backdrop-filter: blur(20px);
  color: #fff;
  padding: 35px;
  border-radius: 20px;
  z-index: 10001;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.8), 0 0 0 1px rgba(255, 0, 0, 0.2);
  transition: all 0.3s ease;
  opacity: 0;
  border: 2px solid rgba(255, 50, 50, 0.4);
  overflow-y: auto;
}

/* Overlay de fundo */
.popup::before {
  content: '';
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0, 0, 0, 0.8);
  backdrop-filter: blur(8px);
  z-index: -1;
  opacity: 0;
  transition: opacity 0.3s ease;
}

.popup.open::before {
  opacity: 1;
}

.popup.open {
  display: block;
  opacity: 1;
  transform: translate(-50%, -50%) scale(1);
}

.popup .close {
  position: absolute;
  top: 20px;
  right: 20px;
  cursor: pointer;
  color: #ff4444;
  font-weight: bold;
  font-size: 26px;
  width: 35px;
  height: 35px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  background: rgba(255, 0, 0, 0.15);
  transition: all 0.3s ease;
  line-height: 1;
  border: 2px solid rgba(255, 0, 0, 0.3);
  user-select: none;
}

.popup .close:hover {
  transform: scale(1.1);
  background: rgba(255, 0, 0, 0.3);
  box-shadow: 0 4px 15px rgba(255, 0, 0, 0.4);
  border-color: rgba(255, 0, 0, 0.6);
  color: #ff6666;
}

.popup .content {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: flex-start;
  text-align: center;
  padding-top: 10px;
}

.popup .content h2 {
  margin: 0 0 20px;
  color: #fff;
  font-size: 28px;
  font-weight: 800;
  text-shadow: 0 2px 8px rgba(255, 0, 0, 0.5);
  border-bottom: 2px solid rgba(255, 0, 0, 0.3);
  padding-bottom: 15px;
}

.popup .content p {
  margin: 12px 0;
  line-height: 1.8;
  color: #e8e8e8;
  font-size: 16px;
}

.popup .content strong {
  color: #ff5555;
  font-weight: 700;
}

.popup .popup-image {
  max-width: 200px;
  max-height: 200px;
  border-radius: 15px;
  margin: 20px 0;
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.15);
  transition: transform 0.3s ease;
}

.popup .popup-image:hover {
  transform: scale(1.05);
}

.popup .popup-buttons {
  display: flex;
  gap: 15px;
  justify-content: center;
  margin-top: 25px;
  flex-wrap: wrap;
}

.popup .popup-buttons button {
  padding: 14px 28px;
  border: none;
  border-radius: 12px;
  font-weight: 700;
  font-size: 14px;
  cursor: pointer;
  transition: all 0.3s cubic-bezier(0.68, -0.55, 0.265, 1.55);
  text-transform: uppercase;
  letter-spacing: 0.5px;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
}

.popup .popup-buttons button:nth-child(1) {
  background: linear-gradient(135deg, #ff6b6b 0%, #ee5a6f 100%);
  color: #fff;
}

.popup .popup-buttons button:nth-child(2) {
  background: linear-gradient(135deg, #51cf66 0%, #37b24d 100%);
  color: #fff;
}

.popup .popup-buttons button:hover {
  transform: translateY(-3px);
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.3);
}

.popup .popup-buttons button:active {
  transform: translateY(-1px);
}

/* Scrollbar customizada - Chrome, Edge, Safari */
::-webkit-scrollbar {
  width: 8px;
}

::-webkit-scrollbar-track {
  background: rgba(0, 0, 0, 0.3);
  border-radius: 10px;
}

::-webkit-scrollbar-thumb {
  background: linear-gradient(180deg, #8b0000 0%, #ff0000 50%, #8b0000 100%);
  border-radius: 10px;
  border: 1px solid rgba(0, 0, 0, 0.3);
}

::-webkit-scrollbar-thumb:hover {
  background: linear-gradient(180deg, #ff0000 0%, #ff3333 50%, #ff0000 100%);
  box-shadow: 0 0 6px rgba(255, 0, 0, 0.5);
}

/* Scrollbar do popup */
.popup::-webkit-scrollbar {
  width: 6px;
}

.popup::-webkit-scrollbar-track {
  background: rgba(0, 0, 0, 0.2);
  border-radius: 10px;
}

.popup::-webkit-scrollbar-thumb {
  background: linear-gradient(180deg, #8b0000 0%, #ff0000 100%);
  border-radius: 10px;
}

.popup::-webkit-scrollbar-thumb:hover {
  background: linear-gradient(180deg, #ff0000 0%, #ff4444 100%);
}

/* Scrollbar customizada - Firefox */
* {
  scrollbar-width: thin;
  scrollbar-color: #ff0000 rgba(0, 0, 0, 0.3);
}

.popup {
  scrollbar-width: thin;
  scrollbar-color: #ff0000 rgba(0, 0, 0, 0.2);
}

footer {
  width: 100%;
  color: #fff;
  text-align: center;
  padding: 25px 20px;
  margin-top: 50px;
  background: rgba(0, 0, 0, 0.2);
  backdrop-filter: blur(10px);
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  font-size: 14px;
}

footer p {
  margin: 8px 0;
  text-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
}

@media (max-width: 768px) {
  .custom-image {
    max-width: 70%;
  }

  .social-icons {
    gap: 10px;
    max-width: 90%;
    margin-left: auto;
    margin-right: auto;
  }

  .social-icons a {
    width: 50px;
    height: 50px;
  }

  #twitch-embed {
    height: 0;
    min-height: 0;
    padding-bottom: 56.25%; /* Aspect ratio 16:9 */
    position: relative;
  }
  
  #twitch-embed iframe {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
  }

  .link-card {
    flex-direction: column;
    align-items: center;
    text-align: center;
    width: 95%;
    padding: 20px;
  }

  .link-icon {
    max-width: 180px;
    margin: 0 auto 20px;
    image-rendering: auto;
    -webkit-backface-visibility: hidden;
    backface-visibility: hidden;
  }

  .info-container {
    gap: 10px;
    margin-right: 0;
    margin-bottom: 20px;
    justify-content: center;
    max-width: 100%;
  }

  .info-square {
    width: calc(50% - 10px);
    min-width: 140px;
    max-width: 160px;
    height: 130px;
  }

  .info-square p {
    font-size: 20px !important;
  }

  .btn-container {
    flex-direction: row;
    gap: 15px;
    justify-content: center;
    width: 100%;
    margin-top: 0;
  }

  .btn {
    padding: 12px 24px;
    font-size: 13px;
    flex: 1;
    max-width: 150px;
  }

  .popup {
    width: 95%;
    padding: 25px;
    max-height: 90vh;
  }

  .popup .close {
    top: 15px;
    right: 15px;
    font-size: 24px;
  }
}

@media (max-width: 1200px) {
  .link-card {
    width: 95%;
  }

  .info-container {
    gap: 10px;
  }

  .info-square {
    width: 140px;
    height: 135px;
  }
}

@media (max-width: 480px) {
  .custom-image {
    max-width: 85%;
  }

  .social-icons a {
    width: 45px;
    height: 45px;
  }

  .social-icons img {
    width: 28px;
    height: 28px;
  }

  #twitch-embed {
    height: 0;
    min-height: 0;
    padding-bottom: 56.25%; /* Aspect ratio 16:9 */
    position: relative;
  }
  
  #twitch-embed iframe {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
  }

  .link-card {
    width: 95%;
    padding: 15px;
  }

  .link-icon {
    max-width: 150px;
    image-rendering: auto;
  }

  .info-square {
    width: calc(50% - 10px);
    min-width: 100px;
    max-width: 140px;
    height: 110px;
  }

  .info-square p {
    font-size: 18px !important;
  }

  .btn-container {
    gap: 10px;
  }

  .btn {
    padding: 10px 18px;
    font-size: 12px;
    flex: 1;
    max-width: 130px;
  }

  .popup {
    padding: 20px;
  }

  .popup .content h2 {
    font-size: 22px;
  }

  .popup .popup-buttons {
    gap: 10px;
  }

  .popup .popup-buttons button {
    padding: 12px 20px;
    font-size: 13px;
  }
}

@keyframes spin {
  0% { transform: rotate(0deg); }
  100% { transform: rotate(360deg); }
}

/* Efeito de brilho nos cards - usando pseudo-elemento diferente */
@keyframes shimmer {
  0% { left: -100%; }
  100% { left: 200%; }
}

.link-card:hover::before,
.link-card:hover::after {
  animation: pulse 2s ease-in-out infinite;
}

@keyframes pulse {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.7; }
}
