/* f8f9fa 배경색*/
/* ===============================
   MOBILE HEADER (≤768px) 모바일
   =============================== */
@media (max-width: 768px) {

  .dropdown-pc {
    display: none !important; /*mobile에서 드롭다운 방지 꼭 있어야함!!*/
  }
  .dropdown-simsim {
    display: none !important; /*mobile에서 드롭다운 방지 꼭 있어야함!!*/
  }

  .header-container {
    width: 100vw !important;
    min-width: 0 !important;
    margin: 0;
    padding: 0;
    background: #f8f9fa;
    box-shadow: 0 2px 4px rgba(0,0,0,0.05);
    overflow-x: hidden;
  }
  html, body {
    width: 100vw;
    max-width: 100vw;
    margin: 0 !important;
    padding: 0 !important;
    overflow-x: hidden !important;
  }
  .header-top {
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 54px;
    padding: 0 12px;
    background: #fff;
    position: relative;
  }
  /*header 모바일에선 logout 안 보이게*/
  .mobile-hide-logout {
    display: none !important;
  }

  .header-left,
  .header-right {
    display: flex;
    align-items: center;
    gap: 10px;
    min-width: 0;
  }
  .header-left { flex: 1 0 auto; }
  .header-right { flex: 1 0 auto; justify-content: flex-end; }
  .home-image { height: 32px; width: auto; }
  .seller-btn { display: none !important; }

  
  .header-bottom {
    display: none;
    flex-direction: column;
    align-items: stretch;
    background: #fff;
    position: fixed;
    top: 54px; left: 0; right: 0;
    width: 100vw !important;
    height: calc(100vh - 54px);
    overflow-y: auto;
    z-index: 1000;
    box-shadow: 0 4px 8px rgba(0,0,0,0.1);
    transform: translateX(-100%);
    transition: transform 0.3s;
  }
  .header-bottom.show {
    display: flex !important;
    transform: translateX(0);
  }
  .nav-center {
    flex-direction: column !important;
    align-items: flex-start !important;
    width: 100vw !important;
    gap: 0;
    padding: 0;
  }
  .nav-item {
    width: 100vw !important;
    border-bottom: 1px solid #f2f2f2;
    padding: 0;
    position: relative;
    text-align: left;
  }
  .nav-link {
    font-size: 16px;
    font-weight: 600;
    color: #222;
    padding: 18px 18px 18px 16px;
    display: block;
    background: none;
    border-radius: 0;
    font-family: 'Roboto', sans-serif;
    width: 100%;
    text-align: left;
    border: none;
    cursor: pointer;
  }
  .nav-link:after {
    content: '▼';
    float: right;
    margin-right: 6px;
    font-size: 12px;
    color: #bbb;
    transition: transform 0.2s;
  }
  .nav-item.open-mobile .nav-link:after {
    transform: rotate(-180deg);
    color: #3a6beb;
  }
  /*모바일 햄버거*/
  .hamburger {
  display: block;
  width: 34px;
  height: 28px;
  position: relative;
  border: none;
  background: none;
  z-index: 1101;
  cursor: pointer;
  padding: 0;
}
.hamburger .bar {
  display: block;
  position: absolute;
  left: 0;
  width: 100%;
  height: 3px;
  background: #222;
  border-radius: 2px;
  transition: all 0.3s;
}
.hamburger .bar:nth-child(1) { top: 4px; }
.hamburger .bar:nth-child(2) { top: 12px; }
.hamburger .bar:nth-child(3) { top: 20px; }


  /* 모바일 아코디언(드롭다운 대체) */
  .accordion-mobile {
    display: none;
    flex-direction: column;
    background: #f9f9f9;
    padding: 7px 22px 11px 22px;
    box-sizing: border-box;
    border-bottom: 1px solid #f3f3f3;
    font-size: 15px;
    
  }
  .accordion-mobile h4 { /*아코디언내부 카테고리*/
    font-size: 16px;
    font-weight: bold;
    margin-top: 10px;
    margin-bottom: 6px;
    color: #2348b6;
  }
  .accordion-mobile a { /*아코디언내부 카테고리*/
    display: block;
    margin-left: 10px;
    font-size: 15px;
  }

  .nav-item.open-mobile .accordion-mobile {
    display: flex;
  }
  @keyframes accordionIn { from {opacity: 0; height: 0;} to {opacity: 1;} }
  .accordion-mobile a {
    color: #444;
    padding: 7px 0;
    text-decoration: none;
    font-size: 15px;
    border-radius: 4px;
    transition: background 0.13s;
  }
  .accordion-mobile a:hover {
    background: #e6ecfd;
    color: #2862d7;
  }
  .main-ad-banner {
    max-width: 96vw;
    margin: 13px auto 0 auto;
    padding: 12px;
    font-size: 14px;
    border-radius: 10px;
    min-height: 38px;
    text-align: center;
  }
}

/* ===============================
   PC HEADER (≥769px) pc
   =============================== */
@media (min-width: 769px) {
  .hamburger {
    display: none !important; /*pc에서 햄버거 안 뜨게 방지. 꼭 필요함.*/
  }
  .header-container {
    width: 100%;
    max-width: 1280px;
    min-width: 1000px;
    margin: 0 auto;
    background: #f8f9fa;
    
    padding: 0;
    position: relative;
    overflow-x: visible;
    /*border-bottom: 2px solid #e0e4ea;   나중에 심심하면 넣을 👈 가로줄 */
    .accordion-mobile {
    display: none !important;
  }
  }
  .header-top {
    display: flex;
    flex-direction: row;
    align-items: center;
    justify-content: space-between;
    min-height: 36px;
    padding: 8px 40px;
    background: #f8f9fa;
  }
  .header-left,
  .header-right {
    display: flex;
    align-items: center;
    gap: 20px;
  }
  .home-image { height: 45px; }

 
  .nav-center {
    display: flex;
    flex-direction: row;
    justify-content: center;
    align-items: center;
    gap: 38px;
    width: auto;
    max-width: 1000px;
    margin: 0 auto;
    padding: 0;
  }
  .nav-item {
    width: auto;
    min-width: 84px;
    padding: 0;
    border: none;
    text-align: center;
    position: relative;
  }
  .nav-link {
    font-size: 18px;
    font-weight: 500;
    color: #1a1a1a;
    padding: 18px 22px 13px 22px;
    border-radius: 10px 10px 0 0;
    margin: 0;
    background: none;
    display: block;
    font-family: 'Roboto', sans-serif;
    letter-spacing: -0.5px;
    text-align: center;
    border: none;
    cursor: pointer;
  }
  .nav-link:after { display: none; }
  .nav-link:hover, .nav-link.active {
    
    color: #2462dc;
    font-weight: 700;

  }

  /* PC용 드롭다운 */
  /* ✅ PC용 심심 드롭다운 */
.header-container .nav-item .dropdown-simsim {
  display: none;
  position: absolute;
  top: 100%;
  left: 50%;
  transform: translateX(-50%);
  background: #f8f9fa;
  border: 2px solid #e0e0e0;
  box-shadow: 0 8px 32px rgba(0,0,0,0.12), 0 1.5px 8px rgba(0,0,0,0.08);

  padding: 16px 44px 22px 44px;
  z-index: 1000;
  flex-direction: row;
  gap: 48px;
  min-width: 280px;
  max-width: 95vw;
  border-radius: 10px;
  font-family: 'Roboto', sans-serif;
  white-space: nowrap;
  text-align: center;
  justify-content: center;
}

.header-container .nav-item:hover .dropdown-simsim {
  display: flex !important;
}

.dropdown-simsim h4 {
  font-size: 19px;
  font-weight: 700;
  margin-bottom: 8px;
  color: #333;
}

.dropdown-simsim a {
  font-size: 16px;
  color: #444;
  text-decoration: none;
  margin: 4px 0;
  display: block;
  transition: color 0.3s;
}

.dropdown-simsim a:hover {
  text-decoration: underline;
}

.dropdown-simsim > div {
  display: flex;
  flex-direction: column;
}
  .header-container .nav-item .dropdown-pc {
    display: none;
    position: absolute;
    top: 100%;
    left: 50%;
    transform: translateX(-50%);
    background: #f8f9fa;
    border: 2px solid #e0e0e0;
    box-shadow: 0 8px 32px rgba(0,0,0,0.12), 0 1.5px 8px rgba(0,0,0,0.08);
    
    padding: 16px 44px 22px 44px;
    z-index: 1000;
    flex-direction: row;
    gap: 48px;
    min-width: 480px;
    max-width: 95vw;
    border-radius: 10px;
    font-family: 'Roboto', sans-serif;
    white-space: nowrap;
    /*글자들 중앙정렬*/
    text-align: center;
    
    justify-content: center;
  }
  .header-container .nav-item:hover .dropdown-pc {
    display: flex !important;
  }
  .dropdown-pc h4 {
    font-size: 19px;
    font-weight: 700;
    margin-bottom: 8px;
    color: #333;
    
    
  }
  .dropdown-pc a {
    font-size: 16px;
    color: #444;
    text-decoration: none;
    margin: 4px 0;
    display: block;
    transition: color 0.3s;
    
  }
  .dropdown-pc a:hover { /*알뜰요금제 게시판 hover*/
    
    text-decoration: underline;
  }
  .dropdown-pc > div {
    display: flex;
    flex-direction: column;
  }
  .main-ad-banner {
    max-width: 800px;
    margin: 22px auto 0 auto;
    padding: 18px;
    font-size: 20px;
    border-radius: 18px;
    min-height: 56px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.05);
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 600;
    text-align: center;
  }

  /*메인헤더 글 애니메이션 효과*/
  .fancy-link {
    display: inline-block;
    padding: 7px 12px;
    font-size: 18px;
    color: #000000;
    background: none;
    border: none;
    outline: none;
    text-decoration: none;
    position: relative;
    cursor: pointer;
    transition: color 0.16s;
    font-family: 'Roboto', 'Noto Sans KR', sans-serif;
    
  }

/* 밑줄 효과 (애니메이션) */
  .fancy-link::after {
    content: '';
    display: block;
    position: absolute;
    left: 20%;
    right: 20%;
    bottom: 2px;
    height: 2px;
    background: #2348b6;
    border-radius: 2px;
    transform: scaleX(0);
    transition: transform 0.22s cubic-bezier(.4,0,.2,1);
    opacity: 0.9;
  }

/* 마우스 올리면 밑줄 나타남 */
  .fancy-link:hover::after,
  .fancy-link:focus::after {
    transform: scaleX(1);
  }


}

/* ======== 공통: 푸터 ======== */
/* ======== 공통: 푸터 ======== */
footer {
  text-align: center;
  padding: 20px;
  background-color: #f8f9fa;
}
.footer-container {
  max-width: 1200px;
  margin: 0 auto;
}
.footer-links {
  list-style: none;
  padding: 0;
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 15px;
  margin-bottom: 10px;
}
.footer-links a {
  text-decoration: none;
  color: #757575;
  font-weight: 500;
}
.footer-links a:hover { color: #0077cc; }
.footer-info {
  font-size: 14px;
  color: #666;
  line-height: 1.6;
}
.footer-bottom {
  font-size: 12px;
  color: #999;
  margin-top: 10px;
}
