/* whiskey_tags.css
   위스키 카드 UI, 검색, 모달, 맛 프로파일, 추천 태그 스타일 모두 포함
*/

/* ─── 검색 폼 ─── */
.search-form {
  text-align: center;
  margin: 30px 0;
}

.search-form input[type="text"] {
  padding: 12px 16px;
  width: 280px;
  font-size: 18px;
  border-radius: 8px;
  border: 1px solid #bbb;
  box-sizing: border-box;
  transition: box-shadow .2s ease;
}

.search-form input[type="text"]:focus {
  outline: none;
  box-shadow: 0 0 0 3px rgba(125, 95, 255, 0.3);
}
.search-form button {
  padding: 8px 16px;
  font-size: 18px;
  border-radius: 6px;
  border: none;
  background-color: #7d5fff;
  color: white;
  cursor: pointer;
  margin-left: 8px;
  height: 50px; /* 입력창과 동일 높이 */
}

/* ─── 카드 그리드 / 카드 ─── */
.card-container {
  display: flex;
  flex-wrap: wrap;
  gap: 20px;
  justify-content: center;
  padding: 0 10px;
}
.whiskey-card {
  width: 280px;
  border: 1px solid #ddd;
  border-radius: 15px;
  box-shadow: 2px 2px 12px rgba(0,0,0,0.08);
  overflow: hidden;
  background: #fff;
  position: relative;
  font-family: inherit;
  display: flex;
  flex-direction: column;
  transition: transform .2s ease, box-shadow .2s ease;
}
.whiskey-card:hover {
  transform: translateY(-2px);
  box-shadow: 4px 6px 20px rgba(0,0,0,0.15);
}
.whiskey-card img {
  width: 100%;
  height: 200px;
  object-fit: cover;
  cursor: pointer;
  background: #f9f9f9;
}
.whiskey-card .content {
  padding: 15px;
  flex: 1;
  display: flex;
  flex-direction: column;
}
.whiskey-card .title {
  font-size: 18px;
  font-weight: bold;
  margin-bottom: 8px;
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  align-items: center;
}
.whiskey-card .desc {
  font-size: 14px;
  color: #444;
  flex: none;
  margin-top: 4px;
}

/* ─── 추천 태그 / 배지 ─── */
.badge {
  display: inline-block;
  padding: 4px 10px;
  border-radius: 999px;
  font-size: 0.6em;
  margin-right: 4px;
  margin-bottom: 4px;
  background: #7d5fff; /* 기본 색 */
  color: #fff;
}
.badge.secondary { background: #555; }

/* 위린이 추천: 녹색 */
.badge.beginner {
   background: #2d8f2e; /* 녹색: 위린이 추천 */
}
/* 강한 위스키: 주황색 */
.badge.strong {
  background: #ff8c00; /* 주황: 강한 위스키 */
}
/* 예시 확장 (필요하면 사용)
.badge.smoky { background: #6f42c1; }
.badge.fruity { background: #ffb347; }
*/

/* ─── 모달 ─── */
.modal {
  display: none;
  position: fixed;
  z-index: 9999;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0,0,0,0.55);
  overflow-y: auto;
  padding: 30px 10px;
  box-sizing: border-box;
}
.modal-inner {
  background: white;
  margin: 5% auto;
  padding: 20px;
  width: 90%;
  max-width: 500px;
  border-radius: 10px;
  position: relative;
  font-family: inherit;
  box-shadow: 0 12px 40px rgba(0,0,0,0.25);
}
.close-btn {
  position: absolute;
  top: 10px;
  right: 15px;
  cursor: pointer;
  font-size: 24px;
  line-height:1;
  color: #333;
}
#modalTags {
  margin-bottom: 8px;
}
#modalTitle {
  margin: 0 0 8px;
}
#modalTitle + p {
  margin-top: 4px;
}

/* ─── 맛 프로파일 ─── */
.taste-bars {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-bottom: 12px;
  font-size: 14px;
}
.taste-row {
  display: flex;
  align-items: center;
  gap: 10px;
}
.taste-label {
  width: 70px;
  font-weight: 600;
  flex-shrink: 0;
}
.taste-bar-wrapper {
  position: relative;
  flex: 1;
  height: 12px;
  background: #eee;
  border-radius: 6px;
  overflow: hidden;
}
.taste-bar-fill {
  height: 100%;
  background: linear-gradient(90deg,#7d5fff,#a18aff);
  border-radius: 6px 0 0 6px;
  transition: width .25s ease;
}
.taste-value {
  width: 40px;
  text-align: right;
  flex-shrink: 0;
  font-weight: 500;
}

/* 카드 그리드: 한 줄에 최대 2~3개 */
.card-container {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
  gap: 24px;
  padding: 20px;
}

/* 카드 크기 조정 */
.whiskey-card {
  max-width: 360px;
  margin: 0 auto;
}

/* ─── 반응형 간단 조정 ─── */
@media (max-width: 900px) {
  .whiskey-card { width: 100%; max-width: 380px; }
}

