.copy-btn {
  position: relative;
  overflow: hidden;
}

.copy-btn::after {
  content: 'Copied!';
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--tiller-color-emerald, #10b981);
  color: white;
  font-weight: 600;
  transform: translateY(100%);
  transition: transform 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.copy-btn.copied::after {
  transform: translateY(0);
}

[data-tooltip] {
  position: relative;
}

[data-tooltip]::before,
[data-tooltip]::after {
  position: absolute;
  opacity: 0%;
  visibility: hidden;
  transition: all 0.2s ease;
  pointer-events: none;
  z-index: 1000;
}

[data-tooltip]::before {
  content: attr(data-tooltip);
  bottom: calc(100% + 8px);
  left: 50%;
  transform: translateX(-50%) translateY(5px);
  padding: 0.5rem 0.75rem;
  background: var(--tiller-bg-elevated, #323534);
  color: var(--tiller-text-primary, #ffffff);
  font-size: 0.8125rem;
  font-weight: 500;
  border-radius: 6px;
  white-space: nowrap;
  box-shadow: 0 4px 12px rgb(0 0 0 / 30%);
}

[data-tooltip]::after {
  content: '';
  bottom: calc(100% + 2px);
  left: 50%;
  transform: translateX(-50%);
  border: 6px solid transparent;
  border-top-color: var(--tiller-bg-elevated, #323534);
}

[data-tooltip]:hover::before,
[data-tooltip]:hover::after {
  opacity: 100%;
  visibility: visible;
}

[data-tooltip]:hover::before {
  transform: translateX(-50%) translateY(0);
}

[data-tooltip-pos='bottom']::before {
  bottom: auto;
  top: calc(100% + 8px);
  transform: translateX(-50%) translateY(-5px);
}

[data-tooltip-pos='bottom']:hover::before {
  transform: translateX(-50%) translateY(0);
}

[data-tooltip-pos='bottom']::after {
  bottom: auto;
  top: calc(100% + 2px);
  border-top-color: transparent;
  border-bottom-color: var(--tiller-bg-elevated, #323534);
}

:focus-visible {
  outline: 3px solid var(--tiller-color-emerald, #10b981);
  outline-offset: 3px;
}

.spinner-ring {
  display: inline-block;
  width: 40px;
  height: 40px;
}

.spinner-ring::after {
  content: '';
  display: block;
  width: 100%;
  height: 100%;
  border-radius: 50%;
  border: 3px solid transparent;
  border-top-color: var(--tiller-color-emerald, #10b981);
  animation: spin 0.8s linear infinite;
}

@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}

.badge {
  display: inline-flex;
  align-items: center;
  padding: 0.25rem 0.75rem;
  font-size: 0.75rem;
  font-weight: 600;
  border-radius: 9999px;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--tiller-text-secondary, #e5e7eb);
}

.badge--trust {
  background: rgb(0 225 132 / 8%);
  border: 1px solid rgb(0 225 132 / 20%);
  color: var(--tiller-color-emerald-light, #3bf0aa);
}

.badge--compliance {
  background: rgb(212 175 55 / 8%);
  border: 1px solid rgb(212 175 55 / 20%);
  color: var(--tiller-color-gold-light, #f2d75c);
}

.badge--reviews {
  background: rgb(212 175 55 / 8%);
  border: 1px solid rgb(212 175 55 / 20%);
  color: var(--tiller-color-gold, #d4af37);
}

.badge--new {
  background: var(--tiller-color-emerald, #10b981);
  color: white;
  animation: badge-pop 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
}

@keyframes badge-pop {
  0% {
    transform: scale(0);
  }

  100% {
    transform: scale(1);
  }
}

.badge--sale {
  background: #ef4444;
  color: white;
}

.badge--featured {
  background: var(--tiller-color-gold, #c9a227);
  color: var(--tiller-bg-darker, #121414);
}

.accordion-item {
  border-bottom: 1px solid rgb(255 255 255 / 10%);
}

.accordion-trigger {
  display: flex;
  justify-content: space-between;
  align-items: center;
  width: 100%;
  padding: 1.25rem 0;
  background: none;
  border: none;
  color: var(--tiller-text-primary, #ffffff);
  font-size: 1.0625rem;
  font-weight: 600;
  text-align: left;
  cursor: pointer;
  transition: color 0.2s ease;
}

.accordion-trigger:hover {
  color: var(--tiller-color-emerald, #10b981);
}

.accordion-icon {
  flex-shrink: 0;
  width: 24px;
  height: 24px;
  transition: transform 0.3s ease;
}

.accordion-item.is-open .accordion-icon {
  transform: rotate(180deg);
}

.accordion-content {
  overflow: hidden;
  max-height: 0;
  transition: max-height 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.accordion-item.is-open .accordion-content {
  max-height: 500px;
}

.accordion-content-inner {
  padding-bottom: 1.5rem;
  color: var(--tiller-text-secondary, #e5e7eb);
}

.tabs {
  display: flex;
  gap: 0.5rem;
  border-bottom: 2px solid rgb(255 255 255 / 10%);
  padding-bottom: 2px;
}

.tab {
  padding: 0.75rem 1.5rem;
  background: none;
  border: none;
  color: var(--tiller-text-muted, #6b7280);
  font-weight: 600;
  cursor: pointer;
  position: relative;
  transition: color 0.2s ease;
}

.tab::after {
  content: '';
  position: absolute;
  bottom: -2px;
  left: 0;
  right: 0;
  height: 2px;
  background: var(--tiller-color-emerald, #10b981);
  transform: scaleX(0);
  transition: transform 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.tab:hover {
  color: var(--tiller-text-primary, #ffffff);
}

.tab.is-active {
  color: var(--tiller-color-emerald, #10b981);
}

.tab.is-active::after {
  transform: scaleX(1);
}

.tab-panel {
  display: none;
  animation: tab-fade 0.4s ease;
}

.tab-panel.is-active {
  display: block;
}

@keyframes tab-fade {
  from {
    opacity: 0%;
    transform: translateY(10px);
  }

  to {
    opacity: 100%;
    transform: translateY(0);
  }
}

.modal-overlay {
  position: fixed;
  inset: 0;
  background: rgb(0 0 0 / 80%);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 2rem;
  z-index: 10000;
  opacity: 0%;
  visibility: hidden;
  transition: all 0.3s ease;
  backdrop-filter: blur(8px);
}

.modal-overlay.is-open {
  opacity: 100%;
  visibility: visible;
}

.modal {
  background: var(--tiller-bg-stone, #222524);
  border-radius: 16px;
  box-shadow: 0 25px 50px rgb(0 0 0 / 50%);
  max-width: 600px;
  max-height: 90vh;
  overflow-y: auto;
  transform: scale(0.9) translateY(20px);
  transition: transform 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.modal-overlay.is-open .modal {
  transform: scale(1) translateY(0);
}

.modal-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 1.5rem;
  border-bottom: 1px solid rgb(255 255 255 / 10%);
}

.modal-title {
  font-size: 1.25rem;
  font-weight: 700;
  color: var(--tiller-text-primary, #ffffff);
}

.modal-close {
  background: none;
  border: none;
  color: var(--tiller-text-muted, #6b7280);
  cursor: pointer;
  padding: 0.5rem;
  transition: color 0.2s ease;
}

.modal-close:hover {
  color: var(--tiller-text-primary, #ffffff);
}

.modal-body {
  padding: 1.5rem;
}

.modal-footer {
  display: flex;
  justify-content: flex-end;
  gap: 1rem;
  padding: 1.5rem;
  border-top: 1px solid rgb(255 255 255 / 10%);
}

.dropdown {
  position: relative;
}

.dropdown-menu {
  position: absolute;
  top: calc(100% + 8px);
  left: 0;
  min-width: 200px;
  background: var(--tiller-bg-elevated, #323534);
  border-radius: 12px;
  box-shadow: 0 10px 40px rgb(0 0 0 / 40%);
  border: 1px solid rgb(255 255 255 / 10%);
  opacity: 0%;
  visibility: hidden;
  transform: translateY(-10px);
  transition: all 0.2s cubic-bezier(0.34, 1.56, 0.64, 1);
  z-index: 100;
}

.dropdown.is-open .dropdown-menu {
  opacity: 100%;
  visibility: visible;
  transform: translateY(0);
}

.dropdown-item {
  display: block;
  padding: 0.75rem 1rem;
  color: var(--tiller-text-primary, #ffffff);
  text-decoration: none;
  transition: background 0.15s ease;
}

.dropdown-item:first-child {
  border-radius: 12px 12px 0 0;
}

.dropdown-item:last-child {
  border-radius: 0 0 12px 12px;
}

.dropdown-item:hover {
  background: rgb(255 255 255 / 5%);
}

[data-count-to] {
  display: inline-block;
  font-variant-numeric: tabular-nums;
}

.marquee {
  overflow: hidden;
  white-space: nowrap;
}

.marquee-content {
  display: inline-flex;
  animation: marquee 30s linear infinite;
}

@keyframes marquee {
  from {
    transform: translateX(0);
  }

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

.marquee:hover .marquee-content {
  animation-play-state: paused;
}

.has-notification {
  position: relative;
}

.has-notification::after {
  content: '';
  position: absolute;
  top: 0;
  right: 0;
  width: 10px;
  height: 10px;
  background: #ef4444;
  border-radius: 50%;
  border: 2px solid var(--tiller-bg-dark, #1a1c1a);
  animation: notification-pulse 2s infinite;
}

@keyframes notification-pulse {
  0%,
  100% {
    transform: scale(1);
  }

  50% {
    transform: scale(1.2);
  }
}

.skeleton {
  background: linear-gradient(
    90deg,
    var(--tiller-bg-slate, #2a2d2c) 0%,
    var(--tiller-bg-elevated, #323534) 50%,
    var(--tiller-bg-slate, #2a2d2c) 100%
  );
  background-size: 200% 100%;
  animation: skeleton-shimmer 1.5s infinite;
  border-radius: 4px;
}

.skeleton-text {
  height: 1em;
  margin-bottom: 0.5em;
}

.skeleton-text:last-child {
  width: 70%;
}

.skeleton-avatar {
  width: 48px;
  height: 48px;
  border-radius: 50%;
}

.skeleton-image {
  aspect-ratio: 16/9;
  border-radius: 8px;
}

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

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

@media (prefers-reduced-motion: reduce) {
  .marquee-content {
    animation: none;
  }

  .skeleton {
    animation: none;
    background: var(--tiller-bg-slate, #2a2d2c);
  }
}
