/* ========================================
   TESTIMONIALS SECTION - 고객 후기 섹션 (네이버 톡톡 스타일)
   ======================================== */

.testimonials {
  padding: var(--space-24) 0;
  background: linear-gradient(135deg, var(--brand-primary) 0%, var(--brand-dark) 100%);
  color: white;
  position: relative;
}

.testimonials::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 100 100"><defs><pattern id="chat-pattern" width="100" height="100" patternUnits="userSpaceOnUse"><circle cx="50" cy="50" r="1" fill="%23ffffff" opacity="0.05"/></pattern></defs><rect width="100" height="100" fill="url(%23chat-pattern)"/></svg>');
  opacity: 0.3;
  pointer-events: none;
}

.testimonials__container {
  max-width: var(--container-max-width);
  margin: 0 auto;
  padding: 0 var(--container-padding);
  position: relative;
  z-index: 2;
}

.testimonials__header {
  text-align: center;
  margin-bottom: var(--space-16);
}

.testimonials__title {
  font-size: var(--font-size-4xl);
  font-weight: var(--font-weight-bold);
  margin-bottom: var(--space-4);
  line-height: 1.2;
  color: white;
  text-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
  letter-spacing: -0.02em;
  filter: drop-shadow(0 1px 2px rgba(255, 255, 255, 0.2));
}

.testimonials__subtitle {
  font-size: var(--font-size-xl);
  opacity: 0.95;
  max-width: 600px;
  margin: 0 auto;
  line-height: 1.6;
  color: white;
  font-weight: var(--font-weight-medium);
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.2);
}

/* ========================================
   TESTIMONIALS SCROLL CONTAINER - 스크롤 컨테이너
   ======================================== */

.testimonials__scroll-container {
  margin-top: var(--space-12);
  padding-bottom: var(--space-4);
  overflow-x: auto;
  scrollbar-width: none;
  -ms-overflow-style: none;
  position: relative;
}

.testimonials__scroll-container::-webkit-scrollbar {
  display: none;
}

.testimonials__scroll-container:active {
  cursor: grabbing;
}

.testimonials__scroll-container * {
  user-select: none;
}

.testimonials__scroll-container .testimonial-card {
  cursor: grab;
}

.testimonials__scroll-container.can-scroll::after {
  content: '';
  position: absolute;
  top: 0;
  right: 0;
  bottom: 0;
  width: 60px;
  background: linear-gradient(90deg, transparent 0%, var(--brand-primary) 100%);
  pointer-events: none;
  z-index: 1;
}

/* ========================================
   TESTIMONIALS GRID - 후기 그리드
   ======================================== */

.testimonials__grid {
  display: flex;
  gap: var(--space-6);
  padding: var(--space-2) 0;
  min-width: max-content;
  scroll-snap-type: x mandatory;
  scroll-behavior: smooth;
}

/* ========================================
   TESTIMONIAL CARD - 네이버 톡톡 채팅 카드
   ======================================== */

.testimonial-card {
  background: rgba(255, 255, 255, 0.95);
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: var(--border-radius-2xl);
  padding: var(--space-6);
  box-shadow: var(--shadow-lg);
  transition: all var(--transition-duration-300) var(--transition-timing-function-ease);
  position: relative;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  height: 100%;
  min-height: 280px;
  min-width: 300px;
  max-width: 350px;
  flex-shrink: 0;
  scroll-snap-align: start;
  -webkit-scroll-snap-align: start;
  color: var(--color-neutral-800);
}

.testimonial-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 3px;
  background: linear-gradient(135deg, var(--brand-primary) 0%, var(--brand-accent) 100%);
  transform: scaleX(0);
  transition: transform 0.3s ease;
}

.testimonial-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.15), 0 4px 16px rgba(29, 136, 177, 0.2);
  border-color: rgba(29, 136, 177, 0.3);
}

.testimonial-card:hover::before {
  transform: scaleX(1);
}

/* ========================================
   TESTIMONIAL CARD HEADER - 채팅 헤더
   ======================================== */

.testimonial-card__header {
  display: flex;
  align-items: center;
  gap: var(--space-3);
  margin-bottom: var(--space-4);
  flex-shrink: 0;
}

.testimonial-card__avatar {
  width: 2.5rem;
  height: 2.5rem;
  border-radius: 50%;
  overflow: hidden;
  flex-shrink: 0;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.testimonial-card__avatar-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.testimonial-card__info {
  flex: 1;
  min-width: 0;
}

.testimonial-card__name {
  font-weight: var(--font-weight-bold);
  font-size: 0.875rem; /* 14px - SEO 최적 크기 */
  color: var(--color-neutral-900);
  margin-bottom: var(--space-1);
  line-height: 1.2;
}

.testimonial-card__time {
  font-size: 0.75rem; /* 12px */
  color: var(--color-neutral-500);
  font-weight: var(--font-weight-medium);
}

.testimonial-card__status {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 1.5rem;
  height: 1.5rem;
  flex-shrink: 0;
}

.testimonial-card__status-dot {
  width: 0.5rem;
  height: 0.5rem;
  background: var(--color-success-500);
  border-radius: 50%;
  animation: chat-pulse 2s ease-in-out infinite;
}

/* ========================================
   TESTIMONIAL CARD MESSAGE - 채팅 메시지
   ======================================== */

.testimonial-card__message {
  flex: 1;
  display: flex;
  flex-direction: column;
  margin-bottom: var(--space-3);
}

.testimonial-card__bubble {
  background: linear-gradient(135deg, var(--brand-primary) 0%, var(--brand-dark) 100%);
  color: white;
  padding: var(--space-4);
  border-radius: var(--border-radius-xl);
  position: relative;
  box-shadow: 0 2px 8px rgba(29, 136, 177, 0.2);
  flex: 1;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.testimonial-card__bubble::before {
  content: '';
  position: absolute;
  top: -8px;
  left: 20px;
  width: 0;
  height: 0;
  border-left: 8px solid transparent;
  border-right: 8px solid transparent;
  border-bottom: 8px solid var(--brand-primary);
}

.testimonial-card__bubble p {
  font-size: 0.875rem; /* 14px - SEO 최적 크기 */
  line-height: 1.5;
  margin: 0 0 var(--space-3) 0;
  font-weight: var(--font-weight-normal);
  color: white;
}

/* ========================================
   TESTIMONIAL CARD RATING - 별점
   ======================================== */

.testimonial-card__rating {
  display: flex;
  gap: var(--space-1);
  align-items: center;
  justify-content: flex-end;
  flex-shrink: 0;
}

.testimonial-card__star {
  font-size: 0.875rem; /* 14px */
  color: #FFD700;
  animation: star-twinkle 2s ease-in-out infinite;
}

.testimonial-card__star:nth-child(2) { animation-delay: 0.1s; }
.testimonial-card__star:nth-child(3) { animation-delay: 0.2s; }
.testimonial-card__star:nth-child(4) { animation-delay: 0.3s; }
.testimonial-card__star:nth-child(5) { animation-delay: 0.4s; }

/* ========================================
   TESTIMONIAL CARD LOCATION - 위치
   ======================================== */

.testimonial-card__location {
  font-size: 0.75rem; /* 12px */
  color: var(--color-neutral-600);
  font-weight: var(--font-weight-medium);
  text-align: center;
  padding: var(--space-2) 0;
  border-top: 1px solid var(--color-neutral-200);
  flex-shrink: 0;
}

/* ========================================
   RESPONSIVE STYLES - 반응형 스타일
   ======================================== */

@media (min-width: 769px) {
  .testimonials__scroll-container {
    margin-top: var(--space-16);
  }
  
  .testimonials__grid {
    gap: var(--space-8);
  }
  
  .testimonial-card {
    padding: var(--space-8);
    min-height: 320px;
    min-width: 350px;
    max-width: 400px;
  }
  
  .testimonial-card__avatar {
    width: 3rem;
    height: 3rem;
  }
  
  .testimonial-card__name {
    font-size: var(--font-size-base);
  }
  
  .testimonial-card__time {
    font-size: 0.875rem;
  }
  
  .testimonial-card__bubble p {
    font-size: var(--font-size-base);
  }
  
  .testimonial-card__star {
    font-size: var(--font-size-base);
  }
  
  .testimonial-card__location {
    font-size: 0.875rem;
  }
}

/* 모바일 최적화 (767px 이하) */
@media (max-width: 767px) {
  .testimonials__scroll-container {
    margin-top: var(--space-8);
  }
  
  .testimonials__grid {
    gap: var(--space-4);
  }
  
  .testimonial-card {
    min-width: 280px;
    max-width: 320px;
    min-height: 260px;
    padding: var(--space-4);
  }
  
  .testimonial-card__avatar {
    width: 2rem;
    height: 2rem;
  }
  
  .testimonial-card__name {
    font-size: 0.75rem;
  }
  
  .testimonial-card__time {
    font-size: 0.625rem;
  }
  
  .testimonial-card__bubble {
    padding: var(--space-3);
  }
  
  .testimonial-card__bubble p {
    font-size: 0.75rem;
  }
  
  .testimonial-card__star {
    font-size: 0.75rem;
  }
  
  .testimonial-card__location {
    font-size: 0.625rem;
  }
}

/* 작은 모바일 (480px 이하) */
@media (max-width: 480px) {
  .testimonials__scroll-container {
    margin-top: var(--space-6);
  }
  
  .testimonials__grid {
    gap: var(--space-3);
  }
  
  .testimonial-card {
    min-width: 260px;
    max-width: 300px;
    min-height: 240px;
    padding: var(--space-3);
  }
  
  .testimonial-card__avatar {
    width: 1.75rem;
    height: 1.75rem;
  }
  
  .testimonial-card__name {
    font-size: 0.6875rem; /* 11px */
  }
  
  .testimonial-card__time {
    font-size: 0.5625rem; /* 9px */
  }
  
  .testimonial-card__bubble {
    padding: var(--space-2);
  }
  
  .testimonial-card__bubble p {
    font-size: 0.6875rem; /* 11px */
  }
  
  .testimonial-card__star {
    font-size: 0.6875rem; /* 11px */
  }
  
  .testimonial-card__location {
    font-size: 0.5625rem; /* 9px */
  }
}

/* ========================================
   ANIMATIONS - 애니메이션
   ======================================== */

@keyframes chat-pulse {
  0%, 100% {
    opacity: 1;
    transform: scale(1);
  }
  50% {
    opacity: 0.7;
    transform: scale(1.2);
  }
}

@keyframes star-twinkle {
  0%, 100% {
    opacity: 1;
    transform: scale(1);
  }
  50% {
    opacity: 0.6;
    transform: scale(1.1);
  }
}

