/* ===========================================
   아트라이앵글 - Art Triangle
   Custom Styles
   =========================================== */

/* Base */
* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  font-family: 'Noto Sans KR', 'Apple SD Gothic Neo', sans-serif;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

/* Animations */
@keyframes fadeIn {
  from { opacity: 0; transform: translateY(20px); }
  to { opacity: 1; transform: translateY(0); }
}

@keyframes slideIn {
  from { opacity: 0; transform: translateX(-20px); }
  to { opacity: 1; transform: translateX(0); }
}

@keyframes float {
  0%, 100% { transform: translateY(0px); }
  50% { transform: translateY(-10px); }
}

.animate-fade-in {
  animation: fadeIn 0.8s ease-out forwards;
}

.animate-fade-in:nth-child(1) { animation-delay: 0.1s; }
.animate-fade-in:nth-child(2) { animation-delay: 0.2s; }
.animate-fade-in:nth-child(3) { animation-delay: 0.3s; }
.animate-fade-in:nth-child(4) { animation-delay: 0.4s; }

/* Typography */
.font-serif {
  font-family: 'Noto Serif KR', 'Playfair Display', Georgia, serif;
}

/* Teal color utilities (Brand color: #3DBEC8) */
.text-teal { color: #3DBEC8; }
.bg-teal { background-color: #3DBEC8; }
.border-teal { border-color: #3DBEC8; }
.hover\:bg-teal-dark:hover { background-color: #21AFB4; }
.text-teal-light { color: #66CBD2; }
.text-teal-dark { color: #21AFB4; }
/* 하위 호환 - gold 클래스도 teal로 매핑 */
.text-gold { color: #3DBEC8; }
.bg-gold { background-color: #3DBEC8; }
.border-gold { border-color: #3DBEC8; }
.hover\:bg-gold-dark:hover { background-color: #21AFB4; }
.text-gold-light { color: #66CBD2; }

/* Charcoal color utilities */
.text-charcoal { color: #1a1a1a; }
.bg-charcoal { background-color: #1a1a1a; }
.border-charcoal { border-color: #1a1a1a; }

/* Navigation */
#navbar {
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
}

#navbar.scrolled {
  box-shadow: 0 2px 20px rgba(0,0,0,0.1);
}

/* Hero Section */
.hero-text {
  text-shadow: 0 2px 4px rgba(0,0,0,0.3);
}

/* Card hover effects */
.card-hover {
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}
.card-hover:hover {
  transform: translateY(-4px);
  box-shadow: 0 20px 40px rgba(0,0,0,0.1);
}

/* Line clamp */
.line-clamp-2 {
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.line-clamp-3 {
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

/* Prose styles for blog content */
.prose h1, .prose h2, .prose h3, .prose h4 {
  font-family: 'Noto Serif KR', Georgia, serif;
  color: #1a1a1a;
  line-height: 1.4;
}

.prose h1 { font-size: 1.875rem; margin-top: 2.5rem; margin-bottom: 1.5rem; }
.prose h2 { font-size: 1.5rem; margin-top: 2rem; margin-bottom: 1rem; }
.prose h3 { font-size: 1.25rem; margin-top: 1.5rem; margin-bottom: 0.75rem; }

.prose p {
  color: #4b5563;
  line-height: 1.8;
  margin-bottom: 1rem;
}

.prose ul {
  list-style-type: disc;
  padding-left: 1.5rem;
  margin-bottom: 1rem;
}

.prose li {
  color: #4b5563;
  line-height: 1.8;
  margin-bottom: 0.25rem;
}

.prose blockquote {
  border-left: 4px solid #3DBEC8;
  padding-left: 1rem;
  margin: 1.5rem 0;
  color: #6b7280;
  font-style: italic;
  background: #fafafa;
  padding: 0.75rem 1rem;
}

.prose strong { color: #1a1a1a; font-weight: 600; }
.prose em { font-style: italic; }

.prose a {
  color: #3DBEC8;
  text-decoration: underline;
}
.prose a:hover { color: #21AFB4; }

/* Scroll animations */
.scroll-animate {
  opacity: 0;
  transform: translateY(30px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}

.scroll-animate.visible {
  opacity: 1;
  transform: translateY(0);
}

/* Button styles */
.btn-primary {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.75rem 2rem;
  background: #1a1a1a;
  color: white;
  font-weight: 500;
  font-size: 0.875rem;
  transition: background-color 0.3s ease;
  cursor: pointer;
  text-decoration: none;
  border: none;
}
.btn-primary:hover { background: #3DBEC8; }

.btn-outline {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.75rem 2rem;
  border: 2px solid #1a1a1a;
  color: #1a1a1a;
  font-weight: 500;
  font-size: 0.875rem;
  transition: all 0.3s ease;
  cursor: pointer;
  text-decoration: none;
}
.btn-outline:hover {
  background: #1a1a1a;
  color: white;
}

/* Form styles */
input[type="text"],
input[type="email"],
input[type="tel"],
input[type="url"],
input[type="password"],
input[type="number"],
input[type="date"],
textarea,
select {
  -webkit-appearance: none;
  appearance: none;
  border-radius: 0;
}

input:focus,
textarea:focus,
select:focus {
  outline: none;
  border-color: #3DBEC8;
  box-shadow: 0 0 0 1px #3DBEC8;
}

/* Loading indicator */
.loading {
  display: inline-block;
  width: 1rem;
  height: 1rem;
  border: 2px solid rgba(255,255,255,0.3);
  border-top-color: white;
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
}

@keyframes spin {
  to { transform: rotate(360deg); }
}

/* Toast notifications */
.toast {
  position: fixed;
  bottom: 1.5rem;
  right: 1.5rem;
  z-index: 9999;
  padding: 0.75rem 1.5rem;
  color: white;
  font-size: 0.875rem;
  border-radius: 2px;
  box-shadow: 0 4px 12px rgba(0,0,0,0.2);
  animation: slideIn 0.3s ease;
}

.toast.success { background: #16a34a; }
.toast.error { background: #dc2626; }
.toast.info { background: #2563eb; }

/* Image lazy loading */
img[loading="lazy"] {
  opacity: 0;
  transition: opacity 0.3s ease;
}
img.loaded { opacity: 1; }

/* Mobile responsive */
@media (max-width: 768px) {
  .prose h1 { font-size: 1.5rem; }
  .prose h2 { font-size: 1.25rem; }
  .prose h3 { font-size: 1.1rem; }
}

/* Print styles */
@media print {
  nav, footer, .cta-section { display: none; }
  body { color: black; background: white; }
}

/* Accessibility */
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0,0,0,0);
  white-space: nowrap;
  border-width: 0;
}

/* Focus visible */
*:focus-visible {
  outline: 2px solid #3DBEC8;
  outline-offset: 2px;
}

/* Skeleton loading */
.skeleton {
  background: linear-gradient(90deg, #f0f0f0 25%, #e0e0e0 50%, #f0f0f0 75%);
  background-size: 200% 100%;
  animation: skeleton-loading 1.5s infinite;
}

@keyframes skeleton-loading {
  0% { background-position: 200% 0; }
  100% { background-position: -200% 0; }
}
