/* 헤더 스타일 */
/* :root {
  --primary-color: #53B2AC;
  --primary-dark: #129c8b;
  --primary-light: #edf8f6;
  --secondary-color: #1e1e1e;
  --text-color: #333;
  --text-light: #666;
  --background-color: #fff;
  --background-light: #f9f9f9;
  --border-color: #e0e0e0;
  --shadow-color: rgb(0 0 0 / 10%);
  --transition: all 0.3s ease;
} */

.header {
  /* background-color: var(--background-color); */
  background-color: var(--card);
  /* box-shadow: 0 2px 10px rgb(0 0 0 / 5%); */
  box-shadow: var(--shadow);
  position: sticky;
  top: 0;
  z-index: 1200;
  padding: 16px 0;
  /* transition: var(--transition); */
  transition: all 0.3s ease;
}

.header-container {
  margin: 0 auto;
  padding: 0 25px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.logo {
  display: flex;
  align-items: center;
}

.logo img {
  height: 40px;
  border-radius: 12px;
  /* transition: var(--transition); */
  transition: all 0.3s ease;
}

.nav {
  display: flex;
  align-items: center;
  gap: 24px;
}

.nav-link {
  font-size: 16px;
  font-weight: 500;
  /* color: var(--text-color); */
  color: var(--text);
  text-decoration: none;
  padding: 8px 12px;
  border-radius: 6px;
  /* transition: var(--transition); */
  transition: all 0.3s ease;
  position: relative;
}

.nav-link:hover {
  /* color: var(--primary-color); */
  color: var(--brand);
}

.nav-link::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 50%;
  width: 0;
  height: 2px;
  /* background-color: var(--primary-color); */
  background-color: var(--brand);
  /* transition: var(--transition); */
  transition: all 0.3s ease;
  transform: translateX(-50%);
}

.nav-link:hover::after {
  width: 80%;
}

.auth-links {
  display: flex;
  gap: 12px;
  margin-left: 16px;
}

.login-btn, .profile-btn {
  /* color: var(--primary-color); */
  color: var(--brand);
  /* border: 1px solid var(--primary-color); */
  border: 1px solid var(--brand);
  background-color: transparent;
}

.login-btn:hover, .profile-btn:hover {
  /* background-color: var(--primary-light); */
  background-color: var(--bg);
}

.signup-btn, .logout-btn {
  /* color: white; */
  color: #fff;
  /* background-color: var(--primary-color); */
  background-color: var(--brand);
}

.signup-btn:hover, .logout-btn:hover {
  /* background-color: var(--primary-dark); */
  background-color: var(--brand-hover); 
}

/* 모바일 메뉴 토글 버튼 */
.menu-toggle {
  display: none;
  flex-direction: column;
  justify-content: space-between;
  width: 30px;
  height: 21px;
  cursor: pointer;
  z-index: 1001;
}

.menu-toggle span {
  display: block;
  height: 3px;
  width: 100%;
  /* background-color: var(--text-color); */
  background-color: var(--text);
  border-radius: 3px;
  /* transition: var(--transition); */
  transition: all 0.3s ease;
}

/* 스크롤 시 헤더 스타일 변경 */
.header.scrolled {
  padding: 12px 0;
  background-color: rgb(255 255 255 / 95%);
  backdrop-filter: blur(10px);
}

.header.scrolled .logo img {
  height: 36px;
}

/* 반응형 디자인 */
@media (max-width: 992px) {
  .menu-toggle {
    display: flex;
  }

  .nav {
    position: fixed;
    top: 0;
    right: -100%;
    width: 280px;
    height: 100vh;
    /* background-color: white; */
    background-color: var(--card);
    flex-direction: column;
    align-items: flex-start;
    padding: 80px 30px 30px;
    /* box-shadow: -5px 0 15px rgb(0 0 0 / 10%); */
    box-shadow: -5px 0 15px rgba(0, 0, 0, .1);
    /* transition: var(--transition); */
    transition: all 0.3s ease;
    z-index: 1000;
    gap: 16px;
  }

  .nav.active {
    right: 0;
  }

  .nav-link {
    width: 100%;
  }

  .nav-link::after {
    display: none;
  }

  .auth-links {
    flex-direction: column;
    margin-left: 0;
    width: 100%;
    margin-top: 16px;
  }

  .auth-link-user, .auth-link-guest {
    width: 100%;
    text-align: center;
  }

  /* 메뉴 토글 활성화 시 햄버거 아이콘을 X로 변경 */
  .menu-toggle.active span:nth-child(1) {
    transform: translateY(9px) rotate(45deg);
  }

  .menu-toggle.active span:nth-child(2) {
    opacity: 0;
  }

  .menu-toggle.active span:nth-child(3) {
    transform: translateY(-9px) rotate(-45deg);
  }

  /* 메뉴 활성화 시 배경 오버레이 */
  .menu-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgb(0 0 0 / 50%);
    z-index: 999;
    opacity: 0;
    visibility: hidden;
    /* transition: var(--transition); */
    transition: all 0.3s ease;
  }

  .menu-overlay.active {
    opacity: 1;
    visibility: visible;
  }
}

@media (max-width: 480px) {
  .header-container {
    padding: 0 16px;
  }

  .logo img {
    height: 32px;
  }
}



/* ============================== 푸터 및 바텀바 ============================== */
/* 🌐 웹 기본 푸터 */
html, body {
  height: 100%;
  margin: 0;
  padding: 0;
}

body {
  display: flex;
  flex-direction: column;
  min-height: 100vh;
}

/* 본문 콘텐츠를 채우도록 */
main {
  flex: 1;
}

.web-footer {
  text-align: center;
  padding: 1rem 0;
  color: var(--muted);
  font-size: 0.85rem;
  background: var(--card);
  border-top: 1px solid rgba(0, 0, 0, 0.08);
}

/* 📱 바텀바 기본 숨김 */
.bottom-bar {
  display: none;
}

/* 📱 모바일용 바텀바 */
@media (max-width: 992px) {
  .web-footer {
    display: none;
    color: var(--text);
  }

  .bottom-bar {
    display: flex;
    position: fixed;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 64px;
    background: var(--card);
    box-shadow: 0 -2px 10px rgba(0, 0, 0, 0.05);
    justify-content: space-around;
    align-items: center;
    border-top: 1px solid rgba(0, 0, 0, 0.08);
    z-index: 1000;
  }

  .bottom-btn {
    flex: 1;
    background: none;
    border: none;
    color: var(--text);
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 4px;
    font-size: 0.85rem;
    cursor: pointer;
    transition: color 0.25s ease, transform 0.2s ease;
  }

  .bottom-btn.active {
    color: var(--brand);
  }

  .bottom-btn.active img {
    opacity: 1;
    transform: scale(1.1);
    filter: drop-shadow(0 0 4px var(--brand));
  }

  .bottom-btn:active {
    transform: scale(0.96);
  }
}

.bottom-btn .icon-wrapper svg {
  width: 28px;
  height: 28px;
  opacity: 0.7;
  stroke: currentColor;
  transition: color 0.25s ease, opacity 0.25s ease, transform 0.25s ease;
}

.bottom-btn.active {
  color: var(--brand);
}

.bottom-btn.active .icon-wrapper svg {
  opacity: 1;
  transform: scale(1.1);
  filter: drop-shadow(0 0 4px var(--brand));
}
