/* Material Symbols Configuration */
.material-symbols-outlined {
  font-variation-settings: "FILL" 0, "wght" 400, "GRAD" 0, "opsz" 24;
}

/* Carousel Styles */
.carousel-item {
  display: none;
  transition: opacity 1s ease-in-out;
}

.carousel-item.active {
  display: block;
}

/* Mobile Menu Styles */
.mobile-menu {
  opacity: 0;
  max-height: 0;
  overflow: hidden;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  transform: translateY(-10px);
}

.mobile-menu.active {
  opacity: 1;
  max-height: 90vh !important; /* Dùng viewport height */
  overflow-y: auto !important; /* Cho phép scroll */
  overflow-x: hidden;
  transform: translateY(0);
  -webkit-overflow-scrolling: touch; /* Smooth scroll trên iOS */
}

.mobile-backdrop {
  position: fixed;
  inset: 0;
  background-color: rgba(0, 0, 0, 0.5);
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s ease-in-out;
  z-index: 40;
}

.mobile-backdrop.active {
  opacity: 1;
  pointer-events: auto;
}

.mobile-menu-link {
  position: relative;
  overflow: hidden;
}

.mobile-menu-link::before {
  content: "";
  position: absolute;
  left: 0;
  top: 50%;
  transform: translateY(-50%);
  width: 3px;
  height: 0;
  background-color: #d93b3b;
  transition: height 0.2s ease;
}

.mobile-menu-link:hover::before,
.mobile-menu-link.active::before {
  height: 100%;
}

/* Desktop Navigation Styles - Japanese Inspired */
.nav-link {
  position: relative;
  padding: 0.5rem 0;
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.nav-link::after {
  content: "";
  position: absolute;
  bottom: 0;
  left: 50%;
  transform: translateX(-50%) scaleX(0);
  width: 100%;
  height: 2px;
  background: linear-gradient(90deg, transparent, #d93b3b, transparent);
  transition: transform 0.4s cubic-bezier(0.4, 0, 0.2, 1);
  transform-origin: center;
}

.nav-link:hover::after,
.nav-link.active::after {
  transform: translateX(-50%) scaleX(1);
}

.nav-link .material-symbols-outlined {
  font-size: 1.25rem;
  opacity: 0;
  transform: translateY(-5px);
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.nav-link:hover .material-symbols-outlined,
.nav-link.active .material-symbols-outlined {
  opacity: 1;
  transform: translateY(0);
}

.nav-link:hover {
  color: #d93b3b;
  transform: translateY(-2px);
}

.nav-link.active {
  color: #d93b3b;
  font-weight: 700;
}

/* CTA Button Animation */
.cta-button {
  position: relative;
  overflow: hidden;
  transition: all 0.3s ease;
}

.cta-button::before {
  content: "";
  position: absolute;
  top: 50%;
  left: 50%;
  width: 0;
  height: 0;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.3);
  transform: translate(-50%, -50%);
  transition: width 0.6s, height 0.6s;
}

.cta-button:hover::before {
  width: 300px;
  height: 300px;
}

.cta-button:hover {
  transform: translateY(-2px);
  box-shadow: 0 10px 25px rgba(217, 59, 59, 0.4);
}

/* Logo hover effect */
.logo-container {
  transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.logo-container:hover {
  transform: scale(1.05);
}

/* Navbar scroll effect */
.navbar-scrolled {
  box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1),
    0 2px 4px -1px rgba(0, 0, 0, 0.06);
}

/* Hero Section 3D Effects - Japanese Inspired */
.hero-title-3d {
  position: relative;
  text-shadow: 2px 2px 0px rgba(217, 59, 59, 0.3),
    4px 4px 0px rgba(217, 59, 59, 0.2), 6px 6px 0px rgba(217, 59, 59, 0.1),
    8px 8px 12px rgba(0, 0, 0, 0.5);
  animation: float 6s ease-in-out infinite;
  transform-style: preserve-3d;
  perspective: 1000px;
}

.hero-subtitle-3d {
  text-shadow: 1px 1px 0px rgba(255, 255, 255, 0.3),
    2px 2px 0px rgba(255, 255, 255, 0.2), 3px 3px 8px rgba(0, 0, 0, 0.4);
  animation: fadeInUp 1.5s ease-out 0.5s both;
}

@keyframes float {
  0%,
  100% {
    transform: translateY(0px) rotateX(0deg);
  }
  50% {
    transform: translateY(-10px) rotateX(2deg);
  }
}

@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(30px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* Sakura (Cherry Blossom) Particles */
.sakura {
  position: absolute;
  width: 12px;
  height: 12px;
  background: linear-gradient(135deg, #ffc0cb, #ffb6c1);
  border-radius: 50% 0 50% 0;
  opacity: 0.7;
  animation: fall linear infinite;
  box-shadow: 0 0 8px rgba(255, 192, 203, 0.5);
}

@keyframes fall {
  0% {
    transform: translateY(-100px) rotate(0deg);
    opacity: 0.7;
  }
  100% {
    transform: translateY(100vh) rotate(360deg);
    opacity: 0;
  }
}

/* Japanese Wave Pattern Overlay */
.wave-pattern {
  position: absolute;
  bottom: 0;
  left: 0;
  width: 100%;
  height: 150px;
  background: radial-gradient(
      circle at 20% 50%,
      rgba(217, 59, 59, 0.1) 0%,
      transparent 50%
    ),
    radial-gradient(
      circle at 80% 80%,
      rgba(217, 59, 59, 0.15) 0%,
      transparent 50%
    );
  opacity: 0.6;
}

/* Geometric Japanese Pattern */
.geometric-overlay {
  position: absolute;
  inset: 0;
  background-image: linear-gradient(
      30deg,
      rgba(217, 59, 59, 0.03) 12%,
      transparent 12.5%,
      transparent 87%,
      rgba(217, 59, 59, 0.03) 87.5%,
      rgba(217, 59, 59, 0.03)
    ),
    linear-gradient(
      150deg,
      rgba(217, 59, 59, 0.03) 12%,
      transparent 12.5%,
      transparent 87%,
      rgba(217, 59, 59, 0.03) 87.5%,
      rgba(217, 59, 59, 0.03)
    ),
    linear-gradient(
      30deg,
      rgba(217, 59, 59, 0.03) 12%,
      transparent 12.5%,
      transparent 87%,
      rgba(217, 59, 59, 0.03) 87.5%,
      rgba(217, 59, 59, 0.03)
    ),
    linear-gradient(
      150deg,
      rgba(217, 59, 59, 0.03) 12%,
      transparent 12.5%,
      transparent 87%,
      rgba(217, 59, 59, 0.03) 87.5%,
      rgba(217, 59, 59, 0.03)
    );
  background-size: 80px 140px;
  background-position: 0 0, 0 0, 40px 70px, 40px 70px;
  pointer-events: none;
}

/* Hero Gradient Overlay */
.hero-gradient {
  background: linear-gradient(
    135deg,
    rgba(217, 59, 59, 0.4) 0%,
    rgba(0, 0, 0, 0.6) 50%,
    rgba(217, 59, 59, 0.3) 100%
  );
}

/* 3D Button Effects */
.btn-3d {
  position: relative;
  transform-style: preserve-3d;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.btn-3d::before {
  content: "";
  position: absolute;
  inset: 0;
  background: inherit;
  border-radius: inherit;
  transform: translateZ(-4px);
  filter: brightness(0.7);
}

.btn-3d:hover {
  transform: translateY(-4px) translateZ(10px);
  box-shadow: 0 8px 16px rgba(217, 59, 59, 0.4), 0 0 30px rgba(217, 59, 59, 0.2);
}

.btn-3d:active {
  transform: translateY(-1px) translateZ(5px);
}

/* Parallax Effect */
.parallax-bg {
  transition: transform 0.3s ease-out;
}

/* Light Rays Effect */
.light-rays {
  position: absolute;
  inset: 0;
  background: linear-gradient(
    45deg,
    transparent 30%,
    rgba(255, 255, 255, 0.05) 50%,
    transparent 70%
  );
  background-size: 200% 200%;
  animation: rays 15s linear infinite;
  pointer-events: none;
}

@keyframes rays {
  0% {
    background-position: 0% 0%;
  }
  100% {
    background-position: 100% 100%;
  }
}
