/* Page Load Animation */
@keyframes fadeIn {
  from {
    opacity: 0;
  }
  to {
    opacity: 1;
  }
}

@keyframes slideInFromTop {
  from {
    transform: translateY(-30px);
    opacity: 0;
  }
  to {
    transform: translateY(0);
    opacity: 1;
  }
}

@keyframes slideInFromBottom {
  from {
    transform: translateY(30px);
    opacity: 0;
  }
  to {
    transform: translateY(0);
    opacity: 1;
  }
}

@keyframes slideInFromLeft {
  from {
    transform: translateX(-50px);
    opacity: 0;
  }
  to {
    transform: translateX(0);
    opacity: 1;
  }
}

@keyframes slideInFromRight {
  from {
    transform: translateX(50px);
    opacity: 0;
  }
  to {
    transform: translateX(0);
    opacity: 1;
  }
}

@keyframes scaleIn {
  from {
    transform: scale(0.9);
    opacity: 0;
  }
  to {
    transform: scale(1);
    opacity: 1;
  }
}

@keyframes pulse {
  0%, 100% {
    transform: scale(1);
  }
  50% {
    transform: scale(1.05);
  }
}

/* Apply animations to elements */
.header {
  animation: slideInFromTop 0.6s ease-out;
}

.header.transparent {
  background: transparent !important;
  box-shadow: none !important;
}

.hero-slider {
  animation: fadeIn 1s ease-out;
}

.product-card {
  animation: scaleIn 0.5s ease-out;
  animation-fill-mode: both;
}

.product-card:nth-child(1) {
  animation-delay: 0.1s;
}

.product-card:nth-child(2) {
  animation-delay: 0.2s;
}

.product-card:nth-child(3) {
  animation-delay: 0.3s;
}

.product-card:nth-child(4) {
  animation-delay: 0.4s;
}

.section-title {
  animation: slideInFromBottom 0.8s ease-out;
}

.stat-item {
  animation: slideInFromBottom 0.6s ease-out;
  animation-fill-mode: both;
}

.stat-item:nth-child(1) {
  animation-delay: 0.2s;
}

.stat-item:nth-child(2) {
  animation-delay: 0.3s;
}

.stat-item:nth-child(3) {
  animation-delay: 0.4s;
}

.stat-item:nth-child(4) {
  animation-delay: 0.5s;
}

.featured-card {
  animation: scaleIn 0.6s ease-out;
  animation-fill-mode: both;
}

.featured-card:nth-child(1) {
  animation-delay: 0.1s;
}

.featured-card:nth-child(2) {
  animation-delay: 0.2s;
}

.featured-card:nth-child(3) {
  animation-delay: 0.3s;
}

.featured-card:nth-child(4) {
  animation-delay: 0.4s;
}

.featured-card:nth-child(5) {
  animation-delay: 0.5s;
}

.exhibition-card {
  animation: scaleIn 0.5s ease-out;
  animation-fill-mode: both;
}

.exhibition-card:nth-child(1) {
  animation-delay: 0.1s;
}

.exhibition-card:nth-child(2) {
  animation-delay: 0.2s;
}

.exhibition-card:nth-child(3) {
  animation-delay: 0.3s;
}

.exhibition-card:nth-child(4) {
  animation-delay: 0.4s;
}

.exhibition-card:nth-child(5) {
  animation-delay: 0.5s;
}

.exhibition-card:nth-child(6) {
  animation-delay: 0.6s;
}

.news-card {
  animation: slideInFromBottom 0.6s ease-out;
  animation-fill-mode: both;
}

.news-card:nth-child(1) {
  animation-delay: 0.1s;
}

.news-card:nth-child(2) {
  animation-delay: 0.2s;
}

.news-card:nth-child(3) {
  animation-delay: 0.3s;
}

.news-card:nth-child(4) {
  animation-delay: 0.4s;
}

.news-card:nth-child(5) {
  animation-delay: 0.5s;
}

.news-card:nth-child(6) {
  animation-delay: 0.6s;
}

/* Scroll reveal animation */
.scroll-reveal {
  opacity: 0;
  transform: translateY(30px);
  transition: opacity 0.6s ease-out, transform 0.6s ease-out;
}

.scroll-reveal.revealed {
  opacity: 1;
  transform: translateY(0);
}

/* Hover animations */
.product-card {
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.product-card:hover {
  transform: translateY(-8px);
  box-shadow: 0 15px 40px rgba(165, 145, 130, 0.18);
}

.featured-card {
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.featured-card:hover {
  box-shadow: 0 10px 30px rgba(20, 77, 54, 0.2);
}

.btn-primary {
  position: relative;
  overflow: hidden;
  transition: all 0.3s ease;
}

.btn-primary::before {
  content: '';
  position: absolute;
  top: 50%;
  left: 50%;
  width: 0;
  height: 0;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.2);
  transform: translate(-50%, -50%);
  transition: width 0.6s, height 0.6s;
}

.btn-primary:hover::before {
  width: 300px;
  height: 300px;
}

.btn-primary-large {
  transition: all 0.3s ease;
}

.btn-primary-large:hover {
  transform: scale(1.05);
  box-shadow: 0 8px 20px rgba(165, 145, 130, 0.18);
}



.btn-primary2 {
  position: relative;
  overflow: hidden;
  transition: all 0.3s ease;
}

.btn-primary2::before {
  content: '';
  position: absolute;
  top: 50%;
  left: 50%;
  width: 0;
  height: 0;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.2);
  transform: translate(-50%, -50%);
  transition: width 0.6s, height 0.6s;
}

.btn-primary2:hover::before {
  width: 300px;
  height: 300px;
}

.btn-primary2-large {
  transition: all 0.3s ease;
}

.btn-primary2-large:hover {
  transform: scale(1.05);
  box-shadow: 0 8px 20px rgba(165, 145, 130, 0.18);
}

/* Footer fade in */
.footer {
  animation: fadeIn 0.8s ease-out;
}

/* Page banner animation */
.page-banner {
  animation: slideInFromTop 0.8s ease-out;
}

.page-banner h1 {
  animation: slideInFromBottom 0.8s ease-out 0.2s;
  animation-fill-mode: both;
}

/* Form animations */
.login-box,
.contact-form-container {
  animation: scaleIn 0.6s ease-out;
}

.form-group {
  animation: slideInFromLeft 0.5s ease-out;
  animation-fill-mode: both;
}

.form-group:nth-child(1) {
  animation-delay: 0.1s;
}

.form-group:nth-child(2) {
  animation-delay: 0.2s;
}

.form-group:nth-child(3) {
  animation-delay: 0.3s;
}

.form-group:nth-child(4) {
  animation-delay: 0.4s;
}

.form-group:nth-child(5) {
  animation-delay: 0.5s;
}

/* Input focus animation */
input:focus,
textarea:focus {
  animation: pulse 0.3s ease-out;
}

/* Logo animation on hover */
.logo img {
  transition: transform 0.3s ease;
}

.logo:hover img {
  transform: scale(1.05);
}

/* Nav link animation */
.nav-link {
  position: relative;
}

.nav-link::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 0;
  height: 2px;
  background: var(--primary-green);
  transition: width 0.3s ease;
}

.nav-link:hover::after {
  width: 100%;
}

/* Social links hover */
.social-links a {
  transition: transform 0.3s ease, background 0.3s ease;
}

.social-links a:hover {
  transform: translateY(-3px);
}

/* Play button animation */
.play-btn,
.play-btn-small {
  transition: all 0.3s ease;
}

.play-btn:hover,
.play-btn-small:hover {
  transform: translate(-50%, -50%) scale(1.1);
}

/* Smooth scroll behavior */
html {
  scroll-behavior: smooth;
}

/* Loading spinner for page transitions */
.page-loading {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: var(--white);
  z-index: 9999;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 1;
  transition: opacity 0.5s ease-out;
}

.page-loading.hidden {
  opacity: 0;
  pointer-events: none;
}

.spinner {
  width: 50px;
  height: 50px;
  border: 4px solid rgba(20, 77, 54, 0.1);
  border-top-color: var(--primary-green);
  border-radius: 50%;
  animation: spin 1s linear infinite;
}

@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}
