[slot='poster'] {
  position: fixed;
  top: 50%;
  left: 50%;
  width: 100px;
  height: 100px;
  translate: -50% -50%;
  z-index: 5;
}

#product-viewer {
  width: 100vw;
  height: 100vh;
  display: block;
  position: relative;
}

#toggle-fullscreen {
  position: fixed;
  display: flex;
  align-items: center;
  justify-content: center;
  top: 10px;
  right: 10px;
  width: 48px;
  height: 48px;
  cursor: pointer;
  z-index: 100;
  font-size: 20px;
  border-radius: 6px;
  color: hsl(216, 16%, 32%);
  background-color: hsla(216, 16%, 88%, 0.48);
  border: none;
  transition: all 0.3s ease;
}

#toggle-fullscreen:hover {
  background-color: hsla(216, 16%, 82%, 0.6);
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.vote-button {
  position: fixed;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  top: 68px;
  right: 10px;
  padding: 0 12px;
  height: 36px;
  cursor: pointer;
  z-index: 100;
  font-size: 13px;
  border-radius: 6px;
  color: hsl(216, 16%, 32%);
  background-color: hsla(216, 16%, 88%, 0.48);
  border: none;
  transition: all 0.3s ease;
  font-weight: 500;
}

.vote-button:hover {
  background-color: hsla(216, 16%, 82%, 0.6);
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.vote-button svg {
  width: 16px;
  height: 16px;
  flex-shrink: 0;
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.vote-modal {
  display: none;
  position: fixed;
  z-index: 1000;
  left: 0;
  top: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(0, 0, 0, 0.7);
  backdrop-filter: blur(5px);
  align-items: center;
  justify-content: center;
}

.vote-modal-content {
  background-color: #ffffff;
  padding: 32px;
  border-radius: 12px;
  max-width: 400px;
  width: 90%;
  position: relative;
  text-align: center;
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.3);
  animation: modalFadeIn 0.3s ease;
}

.vote-modal-content h2 {
  margin: 0 0 24px 0;
  color: hsl(216, 16%, 32%);
  font-size: 18px;
  font-weight: 600;
  line-height: 1.4;
}

.vote-modal-close {
  position: absolute;
  right: 16px;
  top: 16px;
  font-size: 28px;
  font-weight: bold;
  color: hsl(216, 16%, 52%);
  background: none;
  border: none;
  cursor: pointer;
  width: 32px;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 6px;
  transition: all 0.2s ease;
}

.vote-modal-close:hover {
  color: hsl(216, 16%, 32%);
  background-color: hsl(216, 16%, 90%);
}

.vote-buttons {
  display: flex;
  gap: 12px;
  justify-content: center;
}

.vote-btn {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 20px 32px;
  border: 2px solid hsl(216, 16%, 88%);
  border-radius: 12px;
  background: #ffffff;
  cursor: pointer;
  transition: all 0.3s ease;
  font-size: 14px;
  font-weight: 500;
  color: hsl(216, 16%, 32%);
}

.vote-btn svg {
  width: 32px;
  height: 32px;
  flex-shrink: 0;
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
  transition: all 0.3s ease;
}

.vote-like:hover {
  border-color: #22c55e;
  background-color: #f0fdf4;
  color: #22c55e;
  transform: translateY(-4px);
  box-shadow: 0 8px 16px rgba(34, 197, 94, 0.2);
}

.vote-dislike:hover {
  border-color: #ef4444;
  background-color: #fef2f2;
  color: #ef4444;
  transform: translateY(-4px);
  box-shadow: 0 8px 16px rgba(239, 68, 68, 0.2);
}

@media (max-width: 480px) {
  .vote-modal-content {
    padding: 24px;
  }

  .vote-modal-content h2 {
    font-size: 16px;
    margin-bottom: 20px;
  }

  .vote-buttons {
    flex-direction: column;
    gap: 10px;
  }

  .vote-btn {
    width: 100%;
    padding: 16px;
  }
}

model-viewer > button[slot='ar-button'] {
  position: absolute;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 0 16px;
  height: 48px;
  cursor: pointer;
  z-index: 200;
  border-radius: 6px;
  border: none;
  font-size: 14px;
  font-weight: 500;
  color: hsl(216, 16%, 32%);
  background-color: hsla(216, 16%, 88%, 0.48);
  backdrop-filter: blur(10px);
  transition: all 0.3s ease;
  padding-bottom: env(safe-area-inset-bottom);
  margin-bottom: env(safe-area-inset-bottom);
}

@supports (padding: max(0px)) {
  model-viewer > button[slot='ar-button'] {
    padding-bottom: max(0px, env(safe-area-inset-bottom));
    margin-bottom: max(10px, env(safe-area-inset-bottom));
  }
}

model-viewer > button[slot='ar-button'] svg {
  width: 20px;
  height: 20px;
  flex-shrink: 0;
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

model-viewer > button[slot='ar-button']:active {
  transform: translateY(0);
}

.qr-button {
  position: fixed;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 0 16px;
  right: 10px;
  bottom: 10px;
  height: 48px;
  cursor: pointer;
  z-index: 100;
  border-radius: 6px;
  border: none;
  font-size: 14px;
  font-weight: 500;
  color: hsl(216, 16%, 32%);
  background-color: hsla(216, 16%, 88%, 0.48);
  backdrop-filter: blur(10px);
  transition: all 0.3s ease;
}

.qr-button:hover {
  background-color: hsla(216, 16%, 82%, 0.6);
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.qr-button svg {
  width: 20px;
  height: 20px;
  flex-shrink: 0;
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.qr-modal {
  display: none;
  position: fixed;
  z-index: 1000;
  left: 0;
  top: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(0, 0, 0, 0.7);
  backdrop-filter: blur(5px);
  align-items: center;
  justify-content: center;
}

.qr-modal-content {
  background-color: #ffffff;
  padding: 32px;
  border-radius: 12px;
  max-width: 400px;
  width: 90%;
  position: relative;
  text-align: center;
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.3);
  animation: modalFadeIn 0.3s ease;
}

@keyframes modalFadeIn {
  from {
    opacity: 0;
    transform: scale(0.9);
  }
  to {
    opacity: 1;
    transform: scale(1);
  }
}

.qr-modal-content h2 {
  margin: 0 0 20px 0;
  color: hsl(216, 16%, 32%);
  font-size: 20px;
  font-weight: 600;
}

.qr-modal-content p {
  margin: 20px 0 0 0;
  color: hsl(216, 16%, 52%);
  font-size: 14px;
  line-height: 1.5;
}

.qr-modal-close {
  position: absolute;
  right: 16px;
  top: 16px;
  font-size: 28px;
  font-weight: bold;
  color: hsl(216, 16%, 52%);
  background: none;
  border: none;
  cursor: pointer;
  width: 32px;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 6px;
  transition: all 0.2s ease;
}

.qr-modal-close:hover {
  color: hsl(216, 16%, 32%);
  background-color: hsl(216, 16%, 90%);
}

#qr-code {
  display: flex;
  justify-content: center;
  align-items: center;
  margin: 0 auto;
  padding: 16px;
  background-color: #ffffff;
  border-radius: 8px;
}

#qr-code img {
  display: block;
  max-width: 100%;
  height: auto;
}

@media (max-width: 480px) {
  .qr-modal-content {
    padding: 24px;
  }

  .qr-modal-content h2 {
    font-size: 18px;
  }

  #qr-code {
    padding: 12px;
  }
}