/* Critical CSS and Custom Styles for Dandeli.online */

/* Google Fonts - Inter & Pacifico */
@import url('https://fonts.googleapis.com/css2?family=Pacifico&family=Inter:wght@300;400;500;600;700;800&display=swap');

/* Glassmorphism Card */
.glass-panel {
  background: rgba(255, 255, 255, 0.1);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border: 1px solid rgba(255, 255, 255, 0.2);
  box-shadow: 0 8px 32px 0 rgba(0, 0, 0, 0.3);
}

/* Hide scrollbar utility */
.no-scrollbar::-webkit-scrollbar {
  display: none;
}

.no-scrollbar {
  -ms-overflow-style: none;
  scrollbar-width: none;
}

/* Text Gradient */
.text-gradient {
  background: linear-gradient(135deg, #ffffff 0%, #D1E1D2 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  text-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}

/* Scroll Indicator Animation */
@keyframes bounce-slow {

  0%,
  100% {
    transform: translateY(0);
  }

  50% {
    transform: translateY(10px);
  }
}

.animate-bounce-slow {
  animation: bounce-slow 2s infinite;
}

/* Hero Slide Fade Animation */
.hero-slide {
  transition: opacity 1.5s ease-in-out;
}

.hero-slide:first-child {
  animation: heroFade 8s infinite;
}

.hero-slide:nth-child(2) {
  animation: heroFade 8s infinite;
  animation-delay: 4s;
}

@keyframes heroFade {

  0%,
  45% {
    opacity: 1;
  }

  50%,
  95% {
    opacity: 0;
  }

  100% {
    opacity: 1;
  }
}

/* Base Styles */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  margin: 0;
  padding: 0;
  width: 100%;
  overflow-x: hidden;
}

body {
  font-family: 'Inter', system-ui, -apple-system, sans-serif;
  line-height: 1.6;
  color: #333;
  background-color: #ffffff;
  margin: 0;
  padding: 0;
  width: 100%;
  overflow-x: hidden;
}

/* Background Slider Animation */
.bg-slider {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  z-index: 0;
  overflow: hidden;
}

.bg-slide {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  background-size: cover;
  background-position: center;
  background-attachment: fixed;
  /* Parallax effect for "full screen" feel */
  opacity: 1;
  transition: opacity 1s ease-in-out;
}

/* 
   Simplifying to a pure opacity fade for "Full Screen" stability 
   OR a very slow zoom. 
   
   If user specifically requested "slide", we will use a giant container 
   sliding across.
*/

.bg-slider-track {
  display: flex;
  width: 400%;
  /* 4 slides (2 originals + 2 clones) */
  height: 100%;
  animation: slideContinuous 20s linear infinite;
}

.bg-slide-item {
  width: 25%;
  /* 100% / 4 */
  height: 100%;
  background-size: cover;
  background-position: center;
}

@keyframes slideContinuous {
  0% {
    transform: translateX(0);
  }

  100% {
    transform: translateX(-50%);
  }

  /* Move by 50% (width of 2 slides) to loop back to start */
}

/* Custom Scrollbar */
::-webkit-scrollbar {
  width: 10px;
}

::-webkit-scrollbar-track {
  background: #f1f1f1;
}

::-webkit-scrollbar-thumb {
  background: #4D774E;
  border-radius: 5px;
}

::-webkit-scrollbar-thumb:hover {
  background: #3E5F3F;
}

/* Smooth Transitions */
a,
button,
.card,
.btn {
  transition: all 0.3s ease;
}

/* Reading Progress Bar */
.reading-progress {
  position: fixed;
  top: 0;
  left: 0;
  height: 4px;
  background: linear-gradient(90deg, #4D774E 0%, #75A578 100%);
  z-index: 9999;
  transition: width 0.1s ease;
}

/* Hero Section Gradient Overlay */
.hero-overlay {
  background: linear-gradient(135deg, rgba(77, 119, 78, 0.9) 0%, rgba(62, 95, 63, 0.85) 100%);
}

/* Card Hover Effects */
.blog-card {
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.blog-card:hover {
  transform: translateY(-8px);
  box-shadow: 0 20px 40px rgba(77, 119, 78, 0.2);
}

/* Category Badge */
.category-badge {
  display: inline-block;
  padding: 0.25rem 0.75rem;
  background-color: #4D774E;
  color: white;
  border-radius: 9999px;
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

/* Button Styles */
.btn-primary {
  background-color: #4D774E;
  color: white;
  padding: 0.75rem 1.5rem;
  border-radius: 0.5rem;
  font-weight: 600;
  text-decoration: none;
  display: inline-block;
  border: 2px solid #4D774E;
}

.btn-primary:hover {
  background-color: #3E5F3F;
  border-color: #3E5F3F;
  transform: translateY(-2px);
  box-shadow: 0 10px 20px rgba(77, 119, 78, 0.3);
}

.btn-outline {
  background-color: transparent;
  color: #4D774E;
  padding: 0.75rem 1.5rem;
  border-radius: 0.5rem;
  font-weight: 600;
  text-decoration: none;
  display: inline-block;
  border: 2px solid #4D774E;
}

.btn-outline:hover {
  background-color: #4D774E;
  color: white;
  transform: translateY(-2px);
}

/* Search Bar */
.search-input {
  transition: all 0.3s ease;
}

.search-input:focus {
  outline: none;
  border-color: #4D774E;
  box-shadow: 0 0 0 3px rgba(77, 119, 78, 0.1);
}

/* Mobile Menu Animation */
.mobile-menu {
  transition: transform 0.3s ease, opacity 0.3s ease;
}

.mobile-menu.hidden {
  transform: translateY(-20px);
  opacity: 0;
  pointer-events: none;
}

/* Lazy Load Image Placeholder */
img[data-src] {
  filter: blur(10px);
  transition: filter 0.3s ease;
}

img.loaded {
  filter: blur(0);
}

/* Newsletter Form */
.newsletter-input:focus {
  outline: none;
  border-color: #4D774E;
  box-shadow: 0 0 0 3px rgba(77, 119, 78, 0.1);
}

/* Social Share Buttons */
.social-share-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background-color: #f3f4f6;
  color: #4D774E;
  transition: all 0.3s ease;
}

.social-share-btn:hover {
  background-color: #4D774E;
  color: white;
  transform: translateY(-3px);
}

/* Table of Contents */
.toc {
  position: sticky;
  top: 100px;
  max-height: calc(100vh - 120px);
  overflow-y: auto;
}

.toc a {
  color: #666;
  text-decoration: none;
  display: block;
  padding: 0.5rem 0;
  border-left: 2px solid transparent;
  padding-left: 1rem;
}

.toc a:hover,
.toc a.active {
  color: #4D774E;
  border-left-color: #4D774E;
}

/* Breadcrumb */
.breadcrumb {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.875rem;
  color: #666;
}

.breadcrumb a {
  color: #4D774E;
  text-decoration: none;
}

.breadcrumb a:hover {
  text-decoration: underline;
}

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

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

  100% {
    background-position: -200% 0;
  }
}

/* Print Styles */
@media print {
  .no-print {
    display: none !important;
  }

  body {
    font-size: 12pt;
    line-height: 1.5;
  }

  a {
    text-decoration: underline;
  }
}

/* Responsive Typography */
@media (max-width: 640px) {
  body {
    font-size: 14px;
  }
}

/* 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 for Keyboard Navigation */
*:focus-visible {
  outline: 2px solid #4D774E;
  outline-offset: 2px;
}