.header {
  position:absolute;
  top: 0;
  left: 0;
  width: 100%;
  /*height: 40px;*/
  background-color: transparent;
  z-index: 10;
 /* margin-top: 8px;*/
}
.header.active{background:rgba(255,255,255,1);margin:0;position:fixed;max-width: 440px;   /*padding-bottom: 10px;
    padding-top: 8px;*/
    transform: translate(-50%, 0);
    left: 50%;
    top: 0;}
.header2.active{background:rgba(255,255,255,0.9);margin:0;position:fixed;max-width: 440px; /*  padding-bottom: 10px;
    padding-top: 8px;*/
    transform: translate(-50%, 0);
    left: 50%;
    top: 0;z-index:1;width:100%;}    
.header.active.modal-active{background:none;}    
/* 왼쪽 영역 */
.header-left {
  position: absolute;
  left: 0;
  top: 0;
  height: 100%;
  display: flex;
  align-items: center;
  padding-left: 0.8rem;
}

/* 가운데 타이틀(절대 중앙 정렬) */
.header-title {
  position: absolute;
  left: 50%;
  top: 50%;
  transform: translate(-50%, -50%);
  font-size: var(--fs16);
  /*color: var(--white);*/
  color:#000;
  display: flex;
  flex-direction: row;
  align-items: center;
}

/* 오른쪽 영역 */
.header-right {
  position: absolute;
  right: 0;
  top: 0;
  height: 100%;
  display: flex;
  align-items: center;
  padding-right: 0.8rem; /* 우측 여백 */
}

/* 버튼들 공통 스타일 (배경 제거 등) */
.header button {
  background: none;
  border: none;
  cursor: pointer;
  padding: 0;
  margin: 0 5px; /* 아이콘들 간 간격 */
}

.header button.btn-basket{margin-right:8px;} 

.status-bar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  height: 38px;
  padding: 13px 20px;
  background-color: var(--white); /* 배경색 */
  font-size: var(--fs14);
}
.status-left {
  font-size: var(--fs14);
}
.status-right img {
  gap: 5px;
}

/* 햄버거 메뉴 스타일 */
.menu-icon {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  width: 20px;
  height: 16px;
  cursor: pointer;
  position: relative;
  z-index: 3;
}

.line {
  width: 100%;
  height: 2px;
  transition: all 0.3s ease-in-out;
}

/* 햄버거 클릭 시 X로 변환 */
.menu-icon.active .line:nth-child(1) {
  transform: translateY(7px) rotate(45deg);
  background-color: var(--black);
}

.menu-icon.active .line:nth-child(2) {
  opacity: 0;
}

.menu-icon.active .line:nth-child(3) {
  transform: translateY(-7px) rotate(-45deg);
  background-color: var(--black);
}

/* 햄버거 메뉴 클릭 시 오버레이 */
.menu-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100vh;
  z-index: 9;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.3s ease-in-out, visibility 0.3s ease-in-out;
  display: flex;
  flex-direction: column;
  background-color: white;
}

/* 활성화된 상태 */
.menu-overlay.active {
  opacity: 1;
  visibility: visible;
}

.menu-overlay-inner {
  padding: 2rem 2rem 24rem 2rem;
  overflow-y: auto;
  background-color: white;
  flex: 1;
  overflow-y: auto;
  margin-top: 4rem;
}

.ham-top-con {
  display: flex;
  flex-direction: row;
  align-items: center;
  margin-bottom: 2rem;
}

.ham-top-con img {
  margin-right: 0.5rem;
}

.ham-divider {
  width: 100%;
  height: 1px;
  background-color: #efefef;
  margin-bottom: 2rem;
}

.ham-mid-tit {
  color: #999;
  font-size: 1.2rem;
  height: 3.8rem;
}

.ham-mid {
  font-size: 1.4rem;
  margin-bottom: 2rem;
}

.ham-log-tit {
  font-size: 1.8rem;
  font-weight: bold;
  margin-bottom: 0.5rem;
}

.ham-log-sub {
  font-size: 1.2rem;
}

.ham-footer {
  background-color: #333;
  flex-shrink: 0;
  position: fixed;
  bottom: 0;
  width: 100%;
  max-width: 440px;
}

.ham-footer-inner {
  padding: 1.5rem 2rem;
}
.ham-footer-tx {
  color: #fff;
  font-size: 1.4rem;
  margin-bottom: 1.5rem;
}
.ham-footer-tx2 {
  color: #fff;
  font-size: 1rem;
  margin-bottom: 1.5rem;
  margin-top: 1rem;
}

.header.modal-active .main-banner {
  display: none;
}
.header.modal-active .btn-search {
  display: none;
}
.header.modal-active .btn-basket {
  display: none;
}
.header.modal-active .header-title {
  display: none;
}

/* main-header-login.html ---------------------------------- */

.ham-top-con2 {
  display: flex;
  flex-direction: column;
  align-items: center;
  margin-bottom: 2rem;
}

.ham-top-con2 img {
  margin-right: 0.5rem;
}

.btn-basket {
  position: relative; /* 부모를 기준으로 배지 위치 설정 */
}

/* 연두색 동그라미 + 숫자 */
.basket-badge {
  position: absolute;
  bottom: -2px; /* 아이콘 아래쪽 모서리에 맞춰 조정 (필요시 조절) */
  right: -2px; /* 아이콘 오른쪽 모서리에 맞춰 조정 (필요시 조절) */
  display: inline-block;
  width: 14px;
  height: 14px;
  background-color: var(--green);
  font-size: 1rem;
  font-weight: 600;
  line-height: 14px;
  text-align: center;
  border-radius: 50%;
}

/* 메뉴 검색------------------------------------------------------------ */
.search-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100vh;
  z-index: 9;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.3s ease-in-out, visibility 0.3s ease-in-out;
  display: flex;
  flex-direction: column;
  background-color: white;
  z-index: 21;
}

.search-overlay.active {
  opacity: 1;
  visibility: visible;
}

.search-overlay-inner {
  padding: 2rem 2rem 0rem 2rem;
  overflow-y: auto;
  flex: 1;
}
.input-container {
  position: relative;
  width: 100%;;
}
.search-container .input-icon {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  left: 5px;
  width: 24px;
  height: 24px;
}
.input-icon {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  right: 2rem;
  width: 24px;
  height: 24px;
}
.store-search {
  background-color: var(--red2);
  color: var(--white);
  padding: 0.7rem;
  border-radius: 0.4rem;
  max-width: 10.6rem;
  min-height: 3.6rem;
}

.store-search img {
  max-width: 12px;
  max-height: 12px;
}

.m-search-con {
  position: relative;
}

.m-search-con img {
  position: absolute;
  top: -5px;
  right: -2px;
  width: 30px;
  height: 26px;
}
.search-li-con {
  border: 1px solid var(--gray2);
}

/* 리스트 기본 설정 */
.search-list {
  list-style: none;
  padding: 1rem 2rem;
}

.search-list li {
  display: flex;
  align-items: center;
  border-bottom: 1px solid #efefef;
  padding: 1.3rem 0;
}

.search-list li:last-child {
  border-bottom: none;
}

.num {
  display: inline-block;
  text-align: right;
  color: var(--gray);
  font-weight: 600;
  margin-right: 1rem;
}
.search-di {
  border: 1px solid var(--gray6);
}
.exchange-container{position:relative;}
@media (hover: hover) and (pointer: fine) {
 body{max-width:440px;margin:auto;}
 .search-overlay {
  top: 0;
  left: 50%;
  max-width: 440px;
  transform: translate(-50%, 0%);
}
}