@import url('https://cdn.jsdelivr.net/gh/orioncactus/pretendard/dist/web/static/pretendard.css');

.premium-font {
  font-family: 'Pretendard', -apple-system, BlinkMacSystemFont, system-ui, Roboto, sans-serif;
}

/* Smooth Grid Accordion Transition */
.accordion-grid {
  display: grid;
  grid-template-rows: 0fr;
  transition: grid-template-rows 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

.accordion-item.active .accordion-grid {
  grid-template-rows: 1fr;
}

.accordion-trigger {
  transition: all 0.3s ease;
}
.accordion-trigger:focus {
  outline: none !important;
  box-shadow: none !important;
}

.accordion-trigger svg {
  transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

.accordion-item.active .accordion-trigger svg {
  transform: rotate(180deg);
}

/* Accordion Focus / Unfocus Transitions */
.accordion-item {
  transition: opacity 0.4s cubic-bezier(0.16, 1, 0.3, 1), background-color 0.4s ease;
}

.accordion-item.inactive-fade {
  opacity: 0.3;
}

/* Custom Scrollbar */
.scrollbar-thin::-webkit-scrollbar {
  width: 4px;
}
.scrollbar-thin::-webkit-scrollbar-track {
  background: rgba(0, 0, 0, 0.03);
  border-radius: 9999px;
}
.scrollbar-thin::-webkit-scrollbar-thumb {
  background: rgba(0, 0, 0, 0.1);
  border-radius: 9999px;
}
.scrollbar-thin::-webkit-scrollbar-thumb:hover {
  background: rgba(0, 0, 0, 0.2);
}

/* Glow / Scale Hover Effect for Cards */
.premium-hover-card {
  transition: all 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}
.premium-hover-card:hover {
  transform: translateY(-6px);
  box-shadow: 0 30px 60px -15px rgba(15, 23, 42, 0.08);
  border-color: #64748b;
}

/* ==================== ANIMATIONS KEYFRAMES ==================== */

/* 1. Waveform Animation (Service 1) */
@keyframes soundwave {
  0%, 100% { height: 6px; }
  50% { height: 26px; }
}
.premium-hover-card:hover .wave-bar {
  animation: soundwave 1s infinite ease-in-out;
}
.wave-bar:nth-child(1) { animation-delay: 0.1s; }
.wave-bar:nth-child(2) { animation-delay: 0.3s; }
.wave-bar:nth-child(3) { animation-delay: 0.5s; }
.wave-bar:nth-child(4) { animation-delay: 0.2s; }
.wave-bar:nth-child(5) { animation-delay: 0.4s; }

/* 2. Watermark Fade Out Animation (Service 2) */
@keyframes watermarkRemove {
  0%, 100% { opacity: 1; transform: scale(1); }
  40% { opacity: 1; }
  50%, 90% { opacity: 0; transform: scale(0.9); }
}
.premium-hover-card:hover .anim-watermark {
  animation: watermarkRemove 4s infinite ease-in-out;
}

@keyframes brandHighlight {
  0%, 40%, 100% { border-color: #e2e8f0; background-color: transparent; }
  50%, 90% { border-color: #0f172a; background-color: #f8fafc; }
}
.premium-hover-card:hover .anim-brand-box {
  animation: brandHighlight 4s infinite ease-in-out;
}

/* 3. Message Typing & Button Pop Animation (Service 3) */
@keyframes textType {
  0%, 10% { width: 0; }
  40%, 90% { width: 100%; }
}
.anim-typing-text {
  display: inline-block;
  overflow: hidden;
  white-space: nowrap;
  border-right: 2px solid #0f172a;
  width: 100%;
  border-color: transparent;
}
.premium-hover-card:hover .anim-typing-text {
  animation: textType 4s infinite steps(20);
  border-color: #0f172a;
}

@keyframes buttonPop {
  0%, 45% { opacity: 0; transform: translateY(6px); }
  55%, 90% { opacity: 1; transform: translateY(0); }
  100% { opacity: 0; }
}
.anim-pop-btn {
  opacity: 1;
  transform: translateY(0);
}
.premium-hover-card:hover .anim-pop-btn {
  animation: buttonPop 4s infinite ease-in-out;
}

/* 4. Scanning Laser Animation (Service 4) */
@keyframes scanLaser {
  0%, 100% { top: 0%; opacity: 0.4; }
  50% { top: 100%; opacity: 1; }
}
.anim-laser {
  opacity: 0;
}
.premium-hover-card:hover .anim-laser {
  animation: scanLaser 2.5s infinite ease-in-out;
}

@keyframes progressFill {
  0% { width: 0%; }
  50%, 100% { width: 100%; }
}
.anim-progress-bar {
  width: 100%;
}
.premium-hover-card:hover .anim-progress-bar {
  animation: progressFill 2.5s infinite ease-in-out;
}

/* 5. Infinite Messaging Traffic (Service 5) */
@keyframes scrollTraffic {
  0% { transform: translateY(50px); opacity: 0; }
  15%, 85% { opacity: 1; }
  100% { transform: translateY(-50px); opacity: 0; }
}
.anim-traffic-bubble {
  opacity: 1;
  transform: translateY(0);
}
.premium-hover-card:hover .anim-traffic-bubble {
  animation: scrollTraffic 4s infinite linear;
}
.anim-traffic-bubble:nth-child(1) { animation-delay: 0s; }
.anim-traffic-bubble:nth-child(2) { animation-delay: 1.3s; }
.anim-traffic-bubble:nth-child(3) { animation-delay: 2.6s; }

/* 6. Excel Rows & Download (Service 6) */
@keyframes excelRows {
  0%, 100% { opacity: 0.1; }
  10%, 90% { opacity: 1; }
}
.anim-excel-row {
  opacity: 1;
}
.premium-hover-card:hover .anim-excel-row {
  animation: excelRows 3s infinite ease-in-out;
}
.anim-excel-row:nth-child(1) { animation-delay: 0.2s; }
.anim-excel-row:nth-child(2) { animation-delay: 0.4s; }
.anim-excel-row:nth-child(3) { animation-delay: 0.6s; }

@keyframes bounceBtn {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(3px); }
}
.premium-hover-card:hover .anim-bounce-btn {
  animation: bounceBtn 1.5s infinite ease-in-out;
}

/* 7. CRM Lead Loop (Service 7) */
@keyframes crmRow {
  0% { transform: translateY(10px); opacity: 0; }
  10%, 90% { transform: translateY(0); opacity: 1; }
  100% { opacity: 0; }
}
.anim-crm-row {
  opacity: 1;
  transform: translateY(0);
}
.premium-hover-card:hover .anim-crm-row {
  animation: crmRow 4s infinite ease-in-out;
}

/* 8. Character Swap Animation (SVG & Motion) */
@keyframes charSwap {
  0%, 100% { opacity: 0.4; transform: scale(0.95); border-color: #e2e8f0; }
  50% { opacity: 1; transform: scale(1.05); border-color: #0f172a; }
}
.premium-hover-card:hover .anim-char-motion {
  animation: charSwap 3s infinite ease-in-out;
}
.premium-hover-card:hover .anim-char-svg {
  animation: charSwap 3s infinite ease-in-out;
  animation-delay: 1.5s;
}

/* 9. Smart Action - Link Pop */
@keyframes linkPop {
  0%, 20% { opacity: 0; transform: translateY(10px) scale(0.95); }
  35%, 85% { opacity: 1; transform: translateY(0) scale(1); }
  100% { opacity: 0; }
}
.anim-link-btn {
  opacity: 1;
  transform: translateY(0);
}
.premium-hover-card:hover .anim-link-btn {
  animation: linkPop 3s infinite ease-in-out;
}

/* 10. Smart Action - Lead Form Pop */
@keyframes formSlideUp {
  0%, 20% { opacity: 0; transform: translateY(15px); }
  35%, 85% { opacity: 1; transform: translateY(0); }
  100% { opacity: 0; }
}
.anim-lead-form {
  opacity: 1;
  transform: translateY(0);
}
.premium-hover-card:hover .anim-lead-form {
  animation: formSlideUp 4s infinite ease-in-out;
}

/* 11. Smart Action - Kakao/Phone Exclusion Time Toggle */
@keyframes timeShift {
  0%, 40% { background-color: #f1f5f9; color: #64748b; content: "상담 제외 시간 (야간)"; }
  50%, 90% { background-color: #eff6ff; color: #1e40af; content: "상담 가능 시간 (주간)"; }
}
@keyframes lockShift {
  0%, 40% { opacity: 0.5; transform: translateY(2px) scale(0.96); }
  50%, 90% { opacity: 1; transform: translateY(0) scale(1); }
}
.anim-time-status {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  transition: all 0.3s ease;
}
.anim-time-status::after {
  content: "상담 가능 시간 (주간)";
  display: inline-block;
  padding: 2px 8px;
  border-radius: 9999px;
  background-color: #eff6ff;
  color: #1e40af;
  transition: all 0.3s ease;
}
.premium-hover-card:hover .anim-time-status::after {
  animation: timeShift 5s infinite steps(1);
}
.premium-hover-card:hover .anim-lock-btn {
  animation: lockShift 5s infinite ease-in-out;
}

/* 11-2. Smart Action - Kakao/Phone Instant Connection Animations */
@keyframes rippleOut {
  0% { transform: scale(1); opacity: 0.8; }
  100% { transform: scale(2.2); opacity: 0; }
}
@keyframes phoneShake {
  0%, 100% { transform: rotate(0); }
  15%, 45%, 75% { transform: rotate(-8deg); }
  30%, 60%, 90% { transform: rotate(8deg); }
}
.premium-hover-card:hover .anim-ripple {
  animation: rippleOut 1.5s infinite ease-out;
}
.anim-phone-shake {
  opacity: 0;
  transition: opacity 0.3s ease;
}
.premium-hover-card:hover .anim-phone-shake {
  opacity: 1;
  animation: phoneShake 0.6s infinite ease-in-out;
}

/* 11-3. Smart Action - Exclusion Time Setting Clock Animations */
@keyframes spinHour {
  0% { transform: rotate(0deg); }
  100% { transform: rotate(360deg); }
}
@keyframes spinMin {
  0% { transform: rotate(0deg); }
  100% { transform: rotate(720deg); }
}
.premium-hover-card:hover .anim-clock-hour {
  animation: spinHour 6s linear infinite;
}
.premium-hover-card:hover .anim-clock-min {
  animation: spinMin 1.5s linear infinite;
}

/* 12. Daily Chat Limit Warning */
@keyframes limitCounter {
  0%, 20% { content: "3 / 5 회"; color: #64748b; }
  40%, 60% { content: "5 / 5 회"; color: #ef4444; }
  80%, 100% { content: "3 / 5 회"; color: #64748b; }
}
@keyframes limitWarning {
  0%, 30% { opacity: 0; transform: scale(0.95); }
  40%, 75% { opacity: 1; transform: scale(1); }
  85%, 100% { opacity: 0; }
}
.anim-limit-cnt::after {
  content: "3 / 5 회";
}
.premium-hover-card:hover .anim-limit-cnt::after {
  animation: limitCounter 2s infinite steps(1);
}
.anim-limit-warning {
  opacity: 0;
}
.premium-hover-card:hover .anim-limit-warning {
  animation: limitWarning 2s infinite ease-in-out;
}
.premium-hover-card:hover .anim-crm-ping {
  animation: ping 1s cubic-bezier(0, 0, 0.2, 1) infinite;
}

/* ==================== AUTOMATION STEP ANIMATIONS ==================== */

/* Step 1: File Drop */
@keyframes dragDrop {
  0% { transform: translateY(-20px); opacity: 0; }
  20%, 80% { transform: translateY(0); opacity: 1; }
  100% { transform: translateY(20px); opacity: 0; }
}
.anim-drop-doc {
  opacity: 1;
  transform: translateY(0);
}
.premium-hover-card:hover .anim-drop-doc {
  animation: dragDrop 3s infinite ease-in-out;
}

/* Step 2: Sonar Radial Radar Scanning */
@keyframes radarPulse {
  0% { transform: scale(0.8); opacity: 0.8; }
  100% { transform: scale(1.6); opacity: 0; }
}
.anim-radar-wave {
  opacity: 0;
}
.premium-hover-card:hover .anim-radar-wave {
  animation: radarPulse 2s infinite ease-out;
}
.anim-radar-wave:nth-child(2) { animation-delay: 0.7s; }

/* Step 3: Phone Lead Typewriter & Success Dialog */
@keyframes phoneType {
  0%, 10% { content: ""; }
  15% { content: "0"; }
  20% { content: "01"; }
  25% { content: "010"; }
  30% { content: "010-3"; }
  35% { content: "010-32"; }
  40% { content: "010-329"; }
  45% { content: "010-3294"; }
  50%, 85% { content: "010-3294-****"; }
  90%, 100% { content: ""; }
}
.anim-phone-txt::after {
  content: "010-3294-****";
}
.premium-hover-card:hover .anim-phone-txt::after {
  animation: phoneType 5s infinite steps(1);
}

@keyframes successAlert {
  0%, 50% { opacity: 0; transform: scale(0.95); }
  55%, 85% { opacity: 1; transform: scale(1); }
  90%, 100% { opacity: 0; }
}
.anim-success-alert {
  opacity: 0;
}
.premium-hover-card:hover .anim-success-alert {
  animation: successAlert 5s infinite ease-in-out;
}
