body.modal-open > *:not(.modal) {
  filter: blur(8px);
}

.sample-container {
  max-width: 1200px;
  margin: 10rem auto;
}

h2 {
  text-align: center;
  color: var(--text-color);
  margin-bottom: 3rem;
  font-weight: bold;
  position: relative;
  animation: fadeInDown 0.6s ease-out;
}

h2::after {
  position: absolute;
  left: 0;
  right: 0;
  margin: 5px auto 0;
  content: " ";
  display: block;
  border-bottom: 4px solid var(--primary-color);
  border-radius: 100px;
  width: 80px;
  animation: expandWidth 0.8s ease-out 0.3s backwards;
}

h2 span {
  background: var(--primary-color-gradient);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

/* Categories Nav */
.nav-container {
  margin-bottom: 20px;
  margin-left: 15rem;
  margin-right: 15rem;
  border: 1px solid #e5e5e5;
  border-radius: 12px;
  overflow: hidden;
  background: white;
}

.nav-header {
  text-align: center;
  margin: 0;
  padding: 16px 20px;
  font-size: 1.1rem;
  position: relative;
  cursor: pointer;
  background: #f9f9f9;
  transition: all 0.3s ease;
  user-select: none;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
}

.nav-header:hover {
  background: #f0f0f0;
  color: var(--primary-color);
}

.nav-header::after {
  display: none;
}

.nav-toggle-icon {
  font-size: 0.875rem;
  transition: transform 0.3s ease;
  color: var(--primary-color);
}

.nav-container.collapsed .nav-toggle-icon {
  transform: rotate(-90deg);
}

.categories-nav {
  display: flex;
  justify-content: center;
  gap: 8px;
  padding: 20px;
  flex-wrap: wrap;
  max-width: 900px;
  margin: 0 auto;
  max-height: 500px;
  opacity: 1;
  transition: all 0.3s ease;
  overflow: hidden;
}

.nav-container.collapsed .categories-nav {
  max-height: 0;
  padding: 0 20px;
  opacity: 0;
}

.category-pill {
  padding: 8px 18px;
  background: white;
  border: 2px solid var(--primary-color);
  border-radius: 50px;
  font-weight: 600;
  font-size: 0.875rem;
  color: var(--primary-color);
  cursor: pointer;
  transition: all 0.3s ease;
  text-decoration: none;
  white-space: nowrap;
}

.category-pill:hover {
  background: var(--primary-color-gradient);
  color: var(--text-color-alt);
  border-color: var(--primary-color);
  transform: translateY(-2px);
  box-shadow: 0 6px 16px rgba(209, 29, 35, 0.25);
}

/* Sample Category */
.sample-section-title {
  grid-column: 1 / -1;
  font-size: 1.5rem;
  font-weight: 600;
  margin-top: 20px;
  margin-bottom: 10px;
  padding-bottom: 10px;
  border-bottom: 3px solid;
  border-image: var(--primary-color-gradient) 1;
  background: var(--primary-color-gradient);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.sample-section-title:first-child {
  margin-top: 0;
}

.sample-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 20px;
  margin-bottom: 40px;
}

.sample-card {
  background: white;
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  cursor: pointer;
}

.sample-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 6px 20px rgba(209, 29, 35, 0.2);
}

.img-sample {
  width: 100%;
  height: 200px;
  object-fit: cover;
  border-bottom: 2px solid #f0f0f0;
  background: #f5f5f5;
}

.sample-info {
  padding: 15px;
  text-align: center;
}

.sample-name {
  font-weight: 600;
  margin-bottom: 5px;
  font-size: 0.95rem;
}

.sample-name-en {
  font-size: 0.85rem;
  color: #666;
}

/* Modern Glassmorphism Modal */
.modal {
  display: none;
  position: fixed;
  z-index: 1000;
  left: 0;
  top: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(255, 255, 255, 0.3);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  opacity: 0;
  transition: opacity 0.4s ease;
}

.modal.active {
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 1;
}

.modal-backdrop {
  position: absolute;
  width: 100%;
  height: 100%;
  top: 0;
  left: 0;
}

.modal-container {
  position: relative;
  max-width: 85%;
  max-height: 90vh;
  background: white;
  backdrop-filter: none;
  -webkit-backdrop-filter: none;
  border-radius: 24px;
  overflow: hidden;
  box-shadow: 0 25px 50px rgba(0, 0, 0, 0.15),
    0 0 0 1px rgba(255, 255, 255, 0.3), inset 0 1px 0 rgba(255, 255, 255, 0.6);
  transform: scale(0.95) translateY(20px);
  transition: transform 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
  z-index: 1001;
  border: 1px solid rgba(209, 29, 35, 0.1);
}

.modal.active .modal-container {
  transform: scale(1) translateY(0);
}

.modal-content {
  width: 100%;
  height: auto;
  max-height: 70vh;
  object-fit: contain;
  display: block;
  padding: 100px 20px 20px 20px;
}

.modal-header {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  padding: 20px;
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  z-index: 1002;
  background: linear-gradient(
    180deg,
    rgba(255, 255, 255, 0.98) 0%,
    rgba(255, 255, 255, 0.95) 70%,
    transparent 100%
  );
}

.modal-title {
  display: flex;
  flex-direction: column;
  gap: 5px;
  padding-left: 10px;
}

.modal-header-name {
  font-size: 1.3rem;
  font-weight: 600;
  background: var(--primary-color-gradient);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.modal-header-price {
  font-size: 1.1rem;
  color: var(--primary-color);
  font-weight: 600;
}

.modal-close {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.9);
  border: 1px solid var(--primary-color);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 24px;
  color: var(--primary-color);
  transition: all 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
  flex-shrink: 0;
}

.modal-close:hover {
  background: var(--primary-color);
  color: white;
  transform: rotate(90deg) scale(1.1);
  box-shadow: 0 6px 20px rgba(209, 29, 35, 0.3);
}

.modal-footer {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  padding: 25px;
  background: linear-gradient(
    0deg,
    rgba(255, 255, 255, 0.95) 0%,
    rgba(255, 255, 255, 0.7) 50%,
    transparent 100%
  );
  text-align: center;
  z-index: 1002;
}

.modal-info {
  display: inline-block;
  background: rgba(255, 255, 255, 0.9);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  padding: 12px 24px;
  border-radius: 50px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
  border: 1px solid rgba(209, 29, 35, 0.1);
}

.modal-name {
  font-size: 1.1rem;
  font-weight: 600;
  background: var(--primary-color-gradient);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

/* Animation */
@keyframes expandWidth {
  from {
    width: 0;
  }
  to {
    width: 80px;
  }
}

@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(30px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes fadeInDown {
  from {
    opacity: 0;
    transform: translateY(-30px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* Responsive */
@media (max-width: 768px) {
  .sample-container {
    margin: 6rem 0;
    padding: 15px;
  }

  h2 {
    font-size: 1.5rem;
    margin-bottom: 30px;
  }

  .nav-container {
    margin-left: 20px;
    margin-right: 20px;
  }

  .category-pill {
    padding: 6px 14px;
    font-size: 0.8125rem;
  }

  .categories-nav {
    gap: 6px;
    padding: 16px;
  }

  .sample-grid {
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    gap: 15px;
  }

  .img-sample {
    height: 150px;
  }

  .sample-info {
    padding: 10px;
  }

  .sample-name {
    font-size: 0.85rem;
  }

  .modal-container {
    max-width: 95%;
    border-radius: 20px;
  }

  .modal-content {
    padding: 90px 15px 15px 15px;
    max-height: 65vh;
  }

  .modal-header {
    padding: 15px;
  }

  .modal-title {
    padding-left: 5px;
  }

  .modal-header-name {
    font-size: 1.1rem;
  }

  .modal-header-price {
    font-size: 0.95rem;
  }

  .modal-close {
    width: 40px;
    height: 40px;
    font-size: 20px;
  }
}

@media (max-width: 480px) {
  .sample-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 10px;
  }

  .img-sample {
    height: 120px;
  }

  .modal-header {
    flex-direction: row;
    justify-content: space-between;
    align-items: flex-start;
    padding: 15px;
  }

  .modal-close {
    width: 36px;
    height: 36px;
  }

  .modal-title {
    flex: 1;
    padding-left: 0;
  }

  .modal-content {
    padding: 110px 15px 15px 15px;
  }
}
