/**
 * Button Components
 *
 * Reusable button styles for navigation, filters, and actions
 * across the entire site.
 */

/* Base Button */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.75rem 1.25rem;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: var(--radius-md);
  background: rgba(255, 255, 255, 0.03);
  color: inherit;
  font-family: inherit;
  font-size: 0.95rem;
  font-weight: 600;
  text-decoration: none;
  cursor: pointer;
  transition: all 0.2s ease;
}

.btn:hover {
  border-color: rgba(255, 255, 255, 0.15);
  background: rgba(255, 255, 255, 0.06);
}

.btn:active {
  transform: scale(0.98);
}

/* Focus States - Accessibility */
.btn:focus-visible {
  outline: 2px solid rgba(var(--accent-primary-rgb), 0.85);
  outline-offset: 3px;
  border-radius: var(--radius-md);
}

.btn--filter:focus-visible {
  outline: 2px solid rgba(var(--accent-primary-rgb), 0.85);
  outline-offset: 3px;
  border-radius: var(--radius-lg);
}

/* Primary Button */
.btn--primary {
  background: rgba(var(--accent-primary-rgb), 0.15);
  border-color: rgba(var(--accent-primary-rgb), 0.3);
  color: var(--accent-primary);
}

.btn--primary:hover {
  background: rgba(var(--accent-primary-rgb), 0.22);
  border-color: rgba(var(--accent-primary-rgb), 0.4);
}

/* Active State */
.btn.is-active {
  background: rgba(var(--accent-primary-rgb), 0.1);
  border-color: rgba(var(--accent-primary-rgb), 0.4);
  color: var(--accent-primary);
}

/* Small Button */
.btn--small {
  padding: 0.5rem 0.85rem;
  font-size: 0.85rem;
}

/* Large Button */
.btn--large {
  padding: 1rem 1.75rem;
  font-size: 1.05rem;
}

/* Full Width Button */
.btn--full {
  width: 100%;
}

/* Ghost Button */
.btn--ghost {
  background: transparent;
  border-color: transparent;
}

.btn--ghost:hover {
  background: rgba(255, 255, 255, 0.05);
  border-color: rgba(255, 255, 255, 0.08);
}

/* Reset/Secondary Button */
.btn--reset {
  background: transparent;
  border-color: rgba(255, 255, 255, 0.12);
  color: rgba(226, 227, 234, 0.7);
  font-size: 0.85rem;
  padding: 0.6rem 1rem;
}

.btn--reset:hover {
  background: rgba(255, 255, 255, 0.05);
  border-color: rgba(255, 255, 255, 0.2);
  color: rgba(226, 227, 234, 0.9);
}

/* Filter Button (Chip Style) */
.btn--filter {
  padding: 0.6rem 1rem;
  font-size: 0.875rem;
  border-radius: var(--radius-lg);
  font-weight: 600;
}

.btn--filter.is-active {
  background: rgba(var(--accent-primary-rgb), 0.12);
  border-color: rgba(var(--accent-primary-rgb), 0.35);
}

/* Icon Button */
.btn--icon {
  padding: 0.65rem;
  aspect-ratio: 1;
}

/* Button Group */
.btn-group {
  display: flex;
  gap: 0.5rem;
  flex-wrap: wrap;
}

/* Light Theme */
html[data-theme="light"] .btn {
  border-color: rgba(0, 0, 0, 0.08);
  background: rgba(0, 0, 0, 0.02);
}

html[data-theme="light"] .btn:hover {
  border-color: rgba(0, 0, 0, 0.15);
  background: rgba(0, 0, 0, 0.05);
}

html[data-theme="light"] .btn--primary {
  background: rgba(var(--accent-primary-rgb), 0.12);
  border-color: rgba(var(--accent-primary-rgb), 0.25);
  color: var(--accent-primary);
}

html[data-theme="light"] .btn--primary:hover {
  background: rgba(var(--accent-primary-rgb), 0.18);
  border-color: rgba(var(--accent-primary-rgb), 0.35);
}

html[data-theme="light"] .btn.is-active {
  background: rgba(var(--accent-primary-rgb), 0.08);
  border-color: rgba(var(--accent-primary-rgb), 0.35);
  color: var(--accent-primary);
}

html[data-theme="light"] .btn--ghost:hover {
  background: rgba(0, 0, 0, 0.04);
  border-color: rgba(0, 0, 0, 0.08);
}

html[data-theme="light"] .btn--reset {
  border-color: rgba(0, 0, 0, 0.12);
  color: rgba(32, 36, 52, 0.7);
}

html[data-theme="light"] .btn--reset:hover {
  background: rgba(0, 0, 0, 0.04);
  border-color: rgba(0, 0, 0, 0.2);
  color: rgba(32, 36, 52, 0.9);
}

html[data-theme="light"] .btn--filter.is-active {
  background: rgba(var(--accent-primary-rgb), 0.1);
  border-color: rgba(var(--accent-primary-rgb), 0.3);
}

/* Light Theme Focus States */
html[data-theme="light"] .btn:focus-visible {
  outline: 2px solid rgba(var(--accent-primary-rgb), 0.9);
  outline-offset: 3px;
}

html[data-theme="light"] .btn--filter:focus-visible {
  outline: 2px solid rgba(var(--accent-primary-rgb), 0.9);
  outline-offset: 3px;
}
