/* Add your custom CSS styles here */

/* 블로그 프리뷰 스타일 */
.recent-blog {
  background: #f8fafc;
  padding: 50px 0;
  margin-top: 40px;
}

.blog-preview {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 25px;
  margin-top: 30px;
}

.blog-preview-card {
  background: white;
  border-radius: 12px;
  padding: 25px;
  box-shadow: 0 4px 6px rgba(0,0,0,0.1);
  transition: all 0.3s ease;
  border-left: 4px solid #667eea;
}

.blog-preview-card:hover {
  transform: translateY(-3px);
  box-shadow: 0 8px 20px rgba(0,0,0,0.15);
}

.blog-preview-title {
  font-size: 1.2em;
  font-weight: bold;
  color: #333;
  margin-bottom: 10px;
  line-height: 1.4;
}

.blog-preview-title a {
  text-decoration: none;
  color: inherit;
}

.blog-preview-title a:hover {
  color: #667eea;
}

.blog-preview-meta {
  display: flex;
  align-items: center;
  gap: 15px;
  margin-bottom: 12px;
  font-size: 0.85em;
  color: #666;
}

.blog-preview-description {
  color: #555;
  line-height: 1.5;
  margin-bottom: 15px;
  font-size: 0.95em;
}

.blog-preview-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-bottom: 15px;
}

.blog-preview-tag {
  background: #f0f8ff;
  color: #667eea;
  padding: 3px 8px;
  border-radius: 10px;
  font-size: 0.75em;
  font-weight: 500;
}

.blog-read-more {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  color: #667eea;
  text-decoration: none;
  font-weight: 500;
  font-size: 0.9em;
  transition: color 0.3s ease;
}

.blog-read-more:hover {
  color: #5a67d8;
}

.text-center {
  text-align: center;
}

@media (max-width: 768px) {
  .blog-preview {
    grid-template-columns: 1fr;
    gap: 20px;
  }
  
  .blog-preview-card {
    padding: 20px;
  }
}
body {
  font-family: 'Apple SD Gothic Neo', 'Pretendard', sans-serif;
  background-color: #fffaf5;
  margin: 0;
  padding: 0;
  color: #4b2e2e;
}

/* 카테고리 필터 애니메이션 */
@keyframes fadeIn {
  from {
    opacity: 0;
    transform: translateY(10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* 카테고리 버튼 스타일 개선 */
.category-btn {
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  user-select: none;
  outline: none;
}

.category-btn:focus {
  box-shadow: 0 0 0 3px rgba(76, 175, 80, 0.2);
}

.category-btn:active {
  transform: scale(0.95);
}

.category-btn .count {
  font-weight: 600;
  margin-left: 4px;
}

/* 반응형 카테고리 섹션 */
@media (max-width: 768px) {
  #category-section {
    margin: 10px;
    padding: 15px;
  }
  
  #category-filter-container {
    gap: 6px;
  }
  
  .category-btn {
    font-size: 13px !important;
    padding: 6px 12px !important;
  }
}

main {
  max-width: 960px;
  margin: 0 auto;
  padding: 0 16px;
}

header {
  position: sticky;
  top: 0;
  z-index: 999;
  background: #ffffff;
  border-bottom: 1px solid #f0dede;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
}

nav.top-nav {
  display: flex;
  align-items: center;
  gap: 16px;
  max-width: 960px;
  margin: 0 auto;
  padding: 8px 16px;
}
nav.top-nav img.logo {
  height: 36px;
  border-radius: 50%;
  background: #ffffff;
  padding: 4px;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
  margin-right: auto;
}
nav.top-nav a {
  color: #b1505e;
  text-decoration: none;
  font-weight: 600;
  font-size: 14px;
}
nav.top-nav a:hover {
  text-decoration: underline;
}

.marquee {
  width: 100%;
  overflow: hidden;
  white-space: nowrap;
  box-sizing: border-box;
  padding: 8px 0;
  background: #ffe7ec;
  color: #a14657;
  font-size: 13px;
}
.marquee span {
  display: inline-block;
  padding-left: 100%;
  animation: marquee 20s linear infinite;
}
@keyframes marquee {
  0% { transform: translate(0, 0); }
  100% { transform: translate(-100%, 0); }
}

h1 {
  text-align: center;
  font-size: 28px;
  font-weight: 700;
  margin: 24px auto;
}

#daily-message {
  text-align: center;
  font-size: 16px;
  margin-top: -10px;
  margin-bottom: 30px;
  color: #5f3d47;
}

#category-wrapper {
  max-width: 640px;
  margin: 0 auto 20px;
  text-align: center;
  position: relative;
}
#category-toggle {
  background: #ffe5ec;
  color: #b44d65;
  border: 1px solid #f5c3d2;
  padding: 6px 12px;
  border-radius: 20px;
  cursor: pointer;
  font-size: 14px;
}
#category-toggle::after {
  content: "\25BC"; /* ▼ */
  margin-left: 4px;
  font-size: 12px;
}
#category-wrapper.open #category-toggle::after {
  content: "\25B2"; /* ▲ */
}
#category-nav {
  position: absolute;
  left: 0;
  right: 0;
  top: calc(100% + 6px);
  background: #fff8f8;
  border: 1px solid #f5c3d2;
  border-radius: 12px;
  padding: 10px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(90px, 1fr));
  gap: 10px;
  max-height: 0;
  opacity: 0;
  overflow: hidden;
  pointer-events: none;
  transition: max-height 0.3s ease, opacity 0.3s ease;
  z-index: 1000;
}
#category-wrapper.open #category-nav {
  max-height: 400px;
  opacity: 1;
  pointer-events: auto;
}
#category-nav button {
  background: #ffe5ec;
  color: #b44d65;
  border: 1px solid #f5c3d2;
  padding: 6px 12px;
  border-radius: 20px;
  cursor: pointer;
  font-size: 14px;
  white-space: nowrap;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 4px;
  transition: background 0.2s ease;
}
#category-nav button:hover {
  background: #ffd8e3;
}
#category-nav button.active {
  background: #ffb6c1;
  color: #fff;
}

.controls {
  text-align: center;
  margin-bottom: 20px;
}
.controls input {
  padding: 8px;
  border-radius: 8px;
  border: 1px solid #ccc;
  font-size: 14px;
  width: 240px;
}
#autocomplete-list {
  list-style: none;
  margin: 4px auto 12px;
  padding: 0;
  max-height: 180px;
  overflow-y: auto;
  background: #fff8f8;
  border: 1px solid #e6caca;
  border-radius: 10px;
  font-size: 14px;
  position: absolute;
  width: 240px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 999;
  display: none;
  text-align: left;
}
#autocomplete-list li {
  padding: 6px 12px;
  cursor: pointer;
}
#autocomplete-list li:hover {
  background: #ffe0e6;
}

.table-wrapper {
  max-width: 960px;
  margin: 0 auto;
  padding: 0 16px;
}

.grid-wrapper {
  max-width: 960px;
  margin: 0 auto;
  padding: 0 16px;
}

.item-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
  gap: 16px;
}

.item-card {
  background: #fff;
  border-radius: 16px;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.06);
  text-align: center;
  padding: 12px;
  display: flex;
  flex-direction: column;
  align-items: center;
  cursor: pointer;
  transition: transform 0.2s ease;
}

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

.item-card img {
  width: 80px;
  height: 80px;
  object-fit: cover;
  border-radius: 12px;
  margin-top: 8px;
}

.item-card .item-title {
  font-size: 14px;
  font-weight: 500;
  margin: 10px 0;
  color: #4b2e2e;
}

.item-card .buttons {
  display: none; /* 카드 클릭 시 모달에서 BUY/BLOG 버튼 노출 */
}
table {
  width: 100%;
  border-collapse: separate;
  border-spacing: 0;
  border-radius: 16px;
  overflow: hidden;
  background: #fff;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.06);
}
table thead {
  background: #fff0f3;
}
table tbody tr:nth-child(even) {
  background: #fff7f9;
}
table tbody tr:hover {
  background: #ffeef3;
}
tbody tr {
  border-bottom: 1px solid #f6e6e1;
}
tbody tr:last-child {
  border-bottom: none;
}
th, td {
  padding: 12px 10px;
  border: none;
  text-align: center;
  font-size: 14px;
}
td:nth-child(3) { text-align: left; }
.item-title {
  font-weight: 500;
  font-size: 15px;
  /* 모바일에서 긴 상품명이 썸네일 영역을 침범하지 않도록 */
  word-break: break-word;
  overflow-wrap: anywhere;
  white-space: normal;
}

th:nth-child(3),
td:nth-child(3) {
  width: 45%;
}

/* 테이블에서 이미지가 있는 두 번째 열만 가운데 정렬 */
#itemTable td:nth-child(2) {
  text-align: center;
}

/* 이미지 자체도 block + 가운데로 정렬되게 */
#itemTable td:nth-child(2) img {
  display: block;
  margin: 0 auto;
}

#itemTable td {
  vertical-align: middle;
  height: 80px; /* 필요시 고정 */
}


img {
  width: 66px;
  border-radius: 12px;
  transition: transform 0.2s ease;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.05);
}
img:hover {
  transform: scale(1.08);
}
.more-btn {
  background-color: #ffe0e6;
  color: #5f3d47;
  padding: 6px 10px;
  border-radius: 10px;
  font-size: 12px;
  min-width: 90px;
  text-decoration: none;
  display: inline-block;
  transition: background 0.2s ease;
}
.more-btn:hover {
  background-color: #ffc9d5;
}

.blog-btn {
  background-color: #e0e7ff;
  color: #354fa6;
  padding: 6px 10px;
  border-radius: 10px;
  font-size: 12px;
  min-width: 90px;
  text-decoration: none;
  display: inline-block;
  transition: background 0.2s ease;
}
.blog-btn:hover {
  background-color: #cdd8ff;
}
footer {
  text-align: center;
  margin: 40px auto;
  font-size: 13px;
  color: #888;
}

#blog-cta {
  text-align: center;
  margin: 40px 0;
}
#blog-cta h2 {
  font-size: 20px;
  color: #b44d65;
  margin-bottom: 12px;
}
.cta-btn {
  background: linear-gradient(135deg, #ffb6c1, #ff7f9e);
  color: white;
  padding: 10px 24px;
  border-radius: 24px;
  text-decoration: none;
}

.post-cards {
  list-style: none;
  padding: 0;
  margin: 0;
}

.post-card {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 16px;
  padding: 10px;
  background: #fff0f3;
  border-radius: 12px;
  box-shadow: 0 2px 6px rgba(0,0,0,0.05);
}

.post-card img {
  width: 80px;
  height: 80px;
  object-fit: cover;
  border-radius: 8px;
}

.post-card a {
  font-weight: 600;
  color: #444;
  text-decoration: none;
}

.post-article {
  max-width: 720px;
  margin: 0 auto;
  padding: 20px;
  line-height: 1.7;
  text-align: center;
}
.post-article img {
  max-width: 320px;
  border-radius: 12px;
  margin: 12px 0;
}
.post-article p {
  font-size: 16px;
  margin: 16px 0;
  text-align: left;
}
.post-article p.detail {
  font-weight: 600;
  color: #b1505e;
  text-align: center;
}


/* 카테고리 드롭다운 스타일 */
.category-dropdown-wrapper {
  position: relative;
  display: inline-block;
  min-width: 200px;
}

.category-dropdown-btn {
  width: 100%;
  padding: 12px 16px;
  border: 2px solid #e0e0e0;
  border-radius: 8px;
  background: white;
  color: #333;
  font-size: 14px;
  font-weight: 500;
  cursor: pointer;
  display: flex;
  justify-content: space-between;
  align-items: center;
  transition: all 0.3s ease;
}

.category-dropdown-btn:hover {
  border-color: #4CAF50;
  background: #f8f9fa;
}

.dropdown-arrow {
  transition: transform 0.3s ease;
  font-size: 12px;
}

.dropdown-arrow.rotated {
  transform: rotate(180deg);
}

.category-dropdown-menu {
  position: absolute;
  top: 100%;
  left: 0;
  right: 0;
  background: white;
  border: 2px solid #e0e0e0;
  border-top: none;
  border-radius: 0 0 8px 8px;
  box-shadow: 0 4px 12px rgba(0,0,0,0.1);
  z-index: 100;
  max-height: 300px;
  overflow-y: auto;
}

.category-option {
  display: flex;
  align-items: center;
  padding: 12px 16px;
  cursor: pointer;
  transition: background-color 0.2s ease;
  border-bottom: 1px solid #f0f0f0;
}

.category-option:last-child {
  border-bottom: none;
}

.category-option:hover {
  background: #f8f9fa;
}

.category-option.active {
  background: #4CAF50;
  color: white;
}

.category-emoji {
  margin-right: 8px;
  font-size: 16px;
}

.category-name {
  flex: 1;
  font-weight: 500;
}

.category-count {
  font-size: 12px;
  color: #666;
  background: #f0f0f0;
  padding: 2px 6px;
  border-radius: 10px;
  margin-left: 8px;
}

.category-option.active .category-count {
  background: rgba(255,255,255,0.2);
  color: white;
}

.modal {
  display: none;
  position: fixed;
  z-index: 2000 !important; /* ✅ 최상단으로 */
  top: 0; left: 0; right: 0; bottom: 0;
  background-color: rgba(0, 0, 0, 0.3);
  align-items: center;
  justify-content: center;
}
.modal.show {
  display: flex !important;
}
.modal.hidden {
  display: none !important;
}
.modal-overlay {
  position: absolute;
  top: 0; left: 0; right: 0; bottom: 0;
  z-index: 9999;
}
.modal-content {
  background: #fffaf5;
  padding: 24px;
  border-radius: 20px;
  max-width: 500px;
  width: 90%;
  max-height: 90vh;
  overflow-y: auto;
  position: relative;
  z-index: 10000 !important;  /* ✅ 실제 콘텐츠도 더 위에 */
  box-shadow: 0 8px 24px rgba(0,0,0,0.15);
}
.close-btn {
  position: absolute;
  top: 12px; right: 16px;
  font-size: 22px;
  cursor: pointer;
  color: #bbb;
  z-index: 2200;
}
.modal-top {
  display: flex;
  gap: 16px;
  align-items: center;
}
.modal-top img {
  width: 120px;
  height: auto;
  border-radius: 12px;
}
.modal-text h2 {
  font-size: 18px;
  margin-bottom: 4px;
}
.modal-text p {
  font-size: 14px;
  margin: 4px 0;
}
.modal-category {
  font-weight: bold;
  color: #aa5d69;
}
.modal-buttons {
  margin-top: 20px;
  text-align: center;
}
.modal-chart {
  margin: 24px 0 12px;
  padding: 8px 12px;
  background: #fff8f8;
  border-radius: 12px;
  box-shadow: inset 0 0 4px rgba(0,0,0,0.05);
}

.btn-buy {
  background-color: #32c572;
  color: white;
}
.btn-sell {
  background-color: #ef5c5c;
  color: white;
}
.btn-blog {
  background-color: #6b87ff;
  color: white;
}
.btn-buy, .btn-sell, .btn-blog {
  padding: 8px 18px;
  margin: 0 6px;
  border: none;
  border-radius: 12px;
  font-size: 14px;
  cursor: pointer;
  font-weight: bold;
  font-family: 'Apple SD Gothic Neo', 'Pretendard', sans-serif;
}
.modal-chart {
  margin: 16px 0;
  max-width: 360px;
  margin-left: auto;
  margin-right: auto;
}
.sparkline {
  width: 100% !important;
  height: 48px !important;
}

#summary-dashboard {
  margin-top: 40px;
  padding: 20px;
  border-top: 1px dashed #ddd;
  font-size: 14px;
  line-height: 1.8;
  color: #333;
  max-width: 600px;
  margin-left: auto;
  margin-right: auto;
  background: #fffdfd;
  border-radius: 12px;
}

#summary-dashboard h2 {
  font-size: 20px;
  color: #B46C7A;
  margin-bottom: 16px;
  text-align: center;
}

#summary-dashboard h3 {
  font-size: 16px;
  margin: 20px 0 12px;
  color: #B46C7A;
}

#summary-dashboard ul {
  list-style: none;
  padding: 0;
  margin: 0;
}

#summary-dashboard ul li {
  padding: 4px 0;
  font-weight: 500;
}

#summary-dashboard ul li span {
  font-weight: bold;
  color: #222;
}

.top-items-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin-top: 12px;
}

.top-item-card {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 14px;
  background: #fff0f3;
  border-radius: 12px;
  box-shadow: 0 2px 6px rgba(0,0,0,0.05);
}

.top-item-card img {
  width: 60px;
  height: 60px;
  object-fit: cover;
  border-radius: 8px;
  box-shadow: 0 1px 4px rgba(0,0,0,0.06);
}

.top-item-info {
  flex-grow: 1;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.top-item-info .title {
  font-size: 14px;
  font-weight: 600;
  color: #444;
  margin-bottom: 4px;
}

.top-item-info .count {
  font-size: 13px;
  color: #a16b6b;
}

/* 기본 숨김 처리 (관리자가 아닌 경우) */
body:not(.admin) #summary-dashboard .summary-list {
  display: none;
}

body:not(.admin) #summary-dashboard .top-item-info .count {
  display: none;
}

#banner-items {
  padding: 20px 16px 40px;
  margin: 0 auto;
  max-width: 1024px;
  text-align: center;
}

/* ✨ 섹션 타이틀 */
#banner-items h3 {
  font-size: 20px;
  color: #b44d65;
  margin-bottom: 20px;
  font-weight: 600;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
}
#banner-items h3::before {
  content: "✨";
  font-size: 18px;
}
#banner-items h3::after {
  content: "✨";
  font-size: 18px;
}

.banner-wrapper {
  display: flex;
  justify-content: center;
  gap: 12px;
  margin-top: 12px;
}

.banner-card {
  width: 100px;
  height: 140px; /* 더 여유로운 높이 */
  background: #fff0f3;
  border-radius: 12px;
  box-shadow: 0 2px 6px rgba(0,0,0,0.06);
  overflow: hidden;
  text-align: center;
  cursor: pointer;
  transition: transform 0.2s ease;
  position: relative;
  flex-direction: column;
}

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

.banner-card img {
  width: 66px;
  height: 66px;
  object-fit: cover;
  border-radius: 12px;
  margin: 12px auto 0;
  margin-top: 12px;
  display: block;
  aspect-ratio: 1 / 1;
  opacity: 0;
  transition: opacity 0.3s ease;
}

.banner-card img.loaded {
  opacity: 1;
}

.banner-card .title {
  font-size: 12px;
  padding: 8px 4px 4px;
  font-weight: 500;
  color: #843547;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.banner-card .count {
  font-size: 11px;
  color: #a16b6b;
  padding-bottom: 8px;
}

/* ✅ 스켈레톤 스타일 */
.skeleton-img {
  width: 66px;
  height: 66px;
  margin: 12px auto 0;
  border-radius: 12px;
  background: #f0dede;
  animation: pulse 1.2s infinite ease-in-out;
}

.skeleton-text {
  height: 12px;
  width: 70%;
  margin: 8px auto;
  border-radius: 6px;
  background: #f3dcdc;
  animation: pulse 1.2s infinite ease-in-out;
}

@keyframes pulse {
  0% { opacity: 0.9; }
  50% { opacity: 0.5; }
  100% { opacity: 0.9; }
}


/* ✨ 모바일 대응 */
@media (max-width: 600px) {
  .banner-card {
    width: 45%;
    height: 140px;
  }

  /* 모바일 환경에서 테이블이 화면을 넘어가지 않도록 */
  .table-wrapper {
    overflow-x: hidden;
  }
  #itemTable {
    table-layout: fixed;
  }
  #itemTable th,
  #itemTable td {
    font-size: 13px;
    padding: 6px 4px;
    box-sizing: border-box;
  }
  #itemTable th:nth-child(1),
  #itemTable td:nth-child(1) {
    width: 28px;
  }
  #itemTable th:nth-child(2),
  #itemTable td:nth-child(2) {
    width: 50px;
  }
  #itemTable th:nth-child(3),
  #itemTable td:nth-child(3) {
    width: auto;
  }
  #itemTable th:nth-child(4),
  #itemTable td:nth-child(4),
  #itemTable th:nth-child(5),
  #itemTable td:nth-child(5) {
    width: 72px;
  }

  .more-btn,
  .blog-btn {
    font-size: 13px;
    padding: 4px 6px;
    display: block;
    width: 100%;
    box-sizing: border-box;
  }
}

td img {
  display: block;
  width: 66px;
  height: 66px;
  object-fit: cover;
  border-radius: 12px;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.05);
  aspect-ratio: 1 / 1;
  transition: opacity 0.3s ease;
  opacity: 0;
  background: #f0e6e6;
  animation: pulse 1.2s infinite ease-in-out;
}

@keyframes pulse {
  0% { opacity: 0.8; }
  50% { opacity: 0.4; }
  100% { opacity: 0.8; }
}

td img.loaded {
  animation: none;
  background: none;
  opacity: 1;
}

td:nth-child(2) {
  height: 80px; /* 이미지 포함해서 셀 높이 고정 */
  text-align: center;
}

/* ===== Admin Dashboard ===== */
#admin-table {
  max-width: 600px;
  margin: 40px auto;
  display: none;
}

#admin-table table {
  width: 100%;
  border-collapse: collapse;
}

#admin-table th,
#admin-table td {
  padding: 8px 10px;
  border-bottom: 1px solid #f0dede;
  font-size: 14px;
  text-align: left;
}

body.admin #admin-table {
  display: block;
}

/* ===== Component Styles ===== */

/* CategoryFilter 컴포넌트 스타일 */
.category-filter-wrapper {
  position: relative;
  margin: 20px 0;
}

.category-toggle-btn {
  background: linear-gradient(135deg, #ffb6c1, #ff7f9e);
  color: white;
  border: none;
  border-radius: 20px;
  padding: 8px 16px;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s ease;
}

.category-toggle-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(255, 127, 158, 0.4);
}

.category-nav {
  position: absolute;
  top: 100%;
  left: 0;
  right: 0;
  background: white;
  border-radius: 12px;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.15);
  padding: 12px;
  margin-top: 8px;
  display: none;
  z-index: 10;
  max-height: 300px;
  overflow-y: auto;
}

.category-filter-wrapper.open .category-nav {
  display: block;
}

.category-btn {
  display: block;
  width: 100%;
  background: transparent;
  border: none;
  padding: 8px 12px;
  margin: 2px 0;
  text-align: left;
  border-radius: 8px;
  cursor: pointer;
  font-size: 14px;
  transition: background-color 0.2s ease;
}

.category-btn:hover {
  background-color: #f8f9fa;
}

.category-btn.active {
  background: linear-gradient(135deg, #ffb6c1, #ff7f9e);
  color: white;
}

/* SearchBox 컴포넌트 스타일 */
.autocomplete-list {
  position: absolute;
  top: 100%;
  left: 0;
  right: 0;
  background: white;
  border: 1px solid #e1e5e9;
  border-radius: 8px;
  max-height: 200px;
  overflow-y: auto;
  z-index: 15;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
  margin: 0;
  padding: 0;
  list-style: none;
}

.autocomplete-item {
  padding: 12px 16px;
  cursor: pointer;
  border-bottom: 1px solid #f0f0f0;
  display: flex;
  align-items: center;
  gap: 8px;
  transition: background-color 0.2s ease;
}

.autocomplete-item:hover,
.autocomplete-item.highlighted {
  background-color: #f8f9fa;
}

.autocomplete-item:last-child {
  border-bottom: none;
}

.item-id {
  font-weight: 600;
  color: #666;
  min-width: 30px;
}

.item-title {
  flex: 1;
  color: #333;
}

.item-category {
  font-size: 12px;
  color: #888;
  background: #f0f0f0;
  padding: 2px 6px;
  border-radius: 10px;
}

/* ItemCard 컴포넌트 스타일 개선 */
.item-card {
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  cursor: pointer;
}

.item-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 8px 25px rgba(255, 182, 193, 0.3);
}

.item-card img.loaded {
  animation: fadeInScale 0.6s ease-out;
}

@keyframes fadeInScale {
  0% {
    opacity: 0;
    transform: scale(0.9);
  }
  100% {
    opacity: 1;
    transform: scale(1);
  }
}

/* 반응형 개선 */
@media (max-width: 768px) {
  .category-filter-wrapper {
    margin: 16px 0;
  }
  
  .category-nav {
    position: fixed;
    top: auto;
    bottom: 0;
    left: 0;
    right: 0;
    margin: 0;
    border-radius: 16px 16px 0 0;
    max-height: 50vh;
  }
  
  .autocomplete-list {
    max-height: 150px;
  }
  
  .autocomplete-item {
    padding: 10px 12px;
  }
}

