/* 모든 요소의 기본 스타일링 */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  font-family: 'Orbitron', sans-serif;
}

/* 기본적인 바디 스타일 */
body {
  background: #fff;
  color: #333;
}

/* 컨테이너 영역 */
.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 1rem;
  position: relative;
}

/* 헤더 스타일 */
header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
}

/* 로고 스타일 */
.logo {
  font-size: 2rem;
  font-weight: 800;
  color: #ff642f;
  display: flex;
  align-items: center;
  position: relative;
}

.logo canvas {
  margin-right: 0.5rem;
}

.logo-text {
  font-size: 1rem;
  color: #ff642f;
  margin-left: 0.5rem;
}

/* 잔액 표시 영역 */
.balance-area {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  /* background: rgba(255, 255, 255, 0.95); */
  /* padding: 0.3rem 0.6rem; */
  /* border-radius: 20px; */
  /* box-shadow: 0 0 8px rgba(0, 0, 0, 0.15); */
}

/* 버튼 스타일 */
.balance-btn {
  background: #ff642f;
  color: #fff;
  padding: 0.3rem 0.7rem;
  border-radius: 20px;
  border: none;
  cursor: pointer;
  font-size: 0.9rem;
}

/* 배너 섹션 */
.banner-section {
  margin: 2rem 0;
  display: flex;
  overflow-x: auto;
  gap: 1rem;
  padding-bottom: 1rem;
  scroll-snap-type: x mandatory;
}

.banner {
  min-width: 80%;
  flex: 0 0 auto;
  background: url(https://heathmont.imgix.net/bitcasino/images/promotions/2024/weekendtour-bc-tournamet-big.png?auto=compress,format&h=182);
  padding: 3.5rem;
  border-radius: 16px;
  color: #ffffff;
  text-shadow: 0 0 20px #000, 1px 4px 4px #000;
  text-align: center;
  scroll-snap-align: center;
  animation: fadeIn 1.2s ease forwards;
  font-size: 19px;
  font-weight: bold;
}

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

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

.banner img {
  width: 100px;
  margin-bottom: 1rem;
}

/* 토너먼트 섹션 */
.tournament-section {
  margin-bottom: 2rem;
}

.tournament-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 1rem;
}

.tournament-header a {
  background: #ff642f;
  color: white;
  padding: 0.3rem 0.8rem;
  border-radius: 12px;
  text-decoration: none;
  font-size: 0.85rem;
  transition: background 0.3s ease;
}

.tournament-header a:hover {
  background: #d43f1d;
}

/* 카드 스타일 */
.cards {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
}

.card {
  background: linear-gradient(135deg, #ffe0ec, #e0f7ff);
  padding: 3.5rem;
  border-radius: 16px;
  flex: 1 1 250px;
  box-shadow: 0 6px 16px rgba(0, 0, 0, 0.1);
  position: relative;
  transition: transform 0.3s ease;
  animation: fadeIn 1s ease both;
}

.card:hover {
  transform: translateY(-6px);
}

/* 카운트다운 스타일 */
.countdown {
  font-size: 1.4rem;
  font-weight: bold;
  margin: 1rem 0;
  color: #ff642f;
}

/* 참여 버튼 스타일 */
.cta-btn {
  padding: 0.5rem 1rem;
  border: none;
  border-radius: 12px;
  cursor: pointer;
  font-size: 1rem;
}

.joined {
  background: #ddd;
  color: #666;
}

.join-btn {
  background: #ff642f;
  color: white;
}

/* 랭킹 섹션 */
.ranking-section {
  margin: 3rem 0;
  background: linear-gradient(to right, #fff4f0, #f0faff);
  padding: 1.5rem;
  border-radius: 16px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.05);
}

.ranking-section h3 {
  margin-bottom: 1rem;
  font-size: 1.4rem;
  color: #ff642f;
}

.ranking-list {
  list-style: none;
}

.ranking-list li {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0.5rem 0;
  border-bottom: 1px dashed #ddd;
}

.ranking-list li span:first-child {
  font-weight: bold;
}

.ranking-list li .badge {
  margin-right: 0.5rem;
}

/* 푸터 모바일에서만 보이도록 설정 */
footer {
  display: none;
}

@media (max-width: 768px) {
  header, .tournament-header {
    flex-direction: column;
    align-items: flex-start;
  }

  .cards {
    flex-direction: column;
  }

  .balance-area,
  .tournament-header a {
    /* display: none; */
    text-align: center;
    margin: auto;
    margin-top: 25px;
  }

  footer {
    display: flex;
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    background: white;
    border-top: 1px solid #ccc;
    justify-content: space-around;
    padding: 0.8rem 0 1rem;
    box-shadow: 0 -2px 10px rgba(0, 0, 0, 0.05);
    z-index: 10;
  }

  footer div {
    text-align: center;
    font-size: 0.85rem;
    line-height: 1.4;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.2rem;
  }
}

/* 모달 기본 스타일 */
.modal {
  position: fixed;
  z-index: 1;
  left: 0;
  top: 0;
  width: 100%;
  height: 100%;
  overflow: auto;
  background-color: rgba(0, 0, 0, 0.4); /* 반투명 배경 */
  display: none;
}

/* 모달 콘텐츠 스타일 */
.modal-content {
  background-color: #fefefe;
  margin: 15% auto;
  padding: 20px;
  border: 1px solid #888;
  width: 300px;
  border-radius: 5px;
}

/* 닫기 버튼 스타일 */
.close {
  color: #aaa;
  float: right;
  font-size: 28px;
  font-weight: bold;
  z-index: 1050;
}

.close:hover,
.close:focus {
  color: black;
  text-decoration: none;
  cursor: pointer;
}

/* 입력 필드 스타일 */
.input-container {

  margin-bottom: 15px;
}

.icon {
  position: absolute;
  padding: 10px;
  color: gray;
  min-width: 40px;
  text-align: center;
  margin-top: 6px;
}

input[type="text"],
input[type="password"] {
  width: 100%;
  padding: 10px 10px 10px 50px;
  margin: 5px 0;
  display: inline-block;
  border: 1px solid #ccc;
  box-sizing: border-box;
  border-radius: 5px;
}

/* 로그인 버튼 스타일 */
.login-button {
  background-color: #de4919;
  color: white;
  padding: 14px 20px;
  margin: 8px 0;
  font-size: 17px;
  font-weight: bold;
  cursor: pointer;
  width: 100%;
  border-radius: 5px;
  border: 0px;
}

.login-button:hover {
  opacity: 0.8;
}

/* 커스텀 팝업 */
.custom-popup {
  display: none;
  position: fixed;
  z-index: 9999;
  top: 0; left: 0;
  width: 100%; height: 100%;
  background: rgba(0, 0, 0, 0.6);
}

/* 팝업 콘텐츠 */
.popup-content {
  background: #fff;
  width: 90%;
  max-width: 400px;
  margin: 10% auto;
  padding: 20px;
  border-radius: 10px;
  position: relative;
}

/* 팝업 닫기 버튼 */
.close-popup {
  position: absolute;
  top: 10px;
  right: 10px;
  background: #ff4d4d;
  color: white;
  border: none;
  padding: 5px 10px;
  cursor: pointer;
  border-radius: 5px;
}

/* 금액 버튼 */
.amount-buttons {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin: 10px 0;
}

.amount-buttons button {
  flex: 1;
  padding: 8px;
  background: #dddddd;
  border: none;
  border-radius: 6px;
  cursor: pointer;
}
