/* =============================================================
   PROVES.IO — 04. COMPONENTS
   Badge, buttons, cards and the theme switch.
   ============================================================= */

.badge {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.4375rem 0.9375rem 0.4375rem 0.8125rem;
  background: linear-gradient(180deg, rgba(239, 90, 80, 0.18) 0%, rgba(239, 90, 80, 0.10) 100%);
  border: 1px solid rgba(239, 90, 80, 0.45);
  border-radius: 100px;
  font-family: var(--font-body);
  font-size: 0.6875rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--red);
  box-shadow: 0 1px 0 rgba(255, 255, 255, 0.6) inset, 0 0 0 1px rgba(239, 90, 80, 0.08), 0 6px 18px -6px rgba(239, 90, 80, 0.35);
  transition: transform 180ms ease, box-shadow 180ms ease, border-color 180ms ease;
}

.badge:hover {
  transform: translateY(-1px);
  border-color: rgba(239, 90, 80, 0.65);
  box-shadow: 0 1px 0 rgba(255, 255, 255, 0.7) inset, 0 0 0 1px rgba(239, 90, 80, 0.12), 0 10px 24px -8px rgba(239, 90, 80, 0.45);
}

.badge::before {
  content: '';
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--red);
  flex-shrink: 0;
  box-shadow: 0 0 0 2px rgba(239, 90, 80, 0.18), 0 0 10px rgba(239, 90, 80, 0.9);
}

.btn-primary {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.9375rem 2.125rem;
  background: var(--red-vivid);
  color: #fff;
  font-family: var(--font-body);
  font-size: 0.875rem;
  font-weight: 600;
  letter-spacing: 0.015em;
  border-radius: 100px;
  text-decoration: none;
  border: none;
  cursor: pointer;
  box-shadow: 0 4px 20px rgba(242, 61, 51, 0.3), 0 1px 4px rgba(0,0,0,0.5), inset 0 1px 1px rgba(255,255,255,0.2);
  transition: background 0.2s, transform 0.25s var(--ease-spring), box-shadow 0.25s;
}

.btn-primary:hover {
  background: #E5362C;
  transform: translateY(-3px) scale(1.02);
  box-shadow: 0 8px 28px rgba(242, 61, 51, 0.38), 0 4px 12px rgba(0,0,0,0.5), inset 0 1px 1px rgba(255,255,255,0.2);
}

.btn-primary:active {
  transform: translateY(0) scale(0.98);
}

.btn-primary:focus-visible {
  outline: 2px solid var(--red-vivid);
  outline-offset: 3px;
}

.btn-secondary {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.9375rem 2.125rem;
  background: transparent;
  color: var(--text-primary);
  font-family: var(--font-body);
  font-size: 0.875rem;
  font-weight: 600;
  letter-spacing: 0.015em;
  border-radius: 100px;
  text-decoration: none;
  border: 1px solid var(--border-mid);
  cursor: pointer;
  transition: background 0.2s, transform 0.25s var(--ease-spring), border-color 0.2s;
}

.btn-secondary:hover {
  background: var(--bg-surface);
  border-color: var(--red);
  transform: translateY(-3px) scale(1.02);
}

.btn-secondary:active {
  transform: translateY(0) scale(0.98);
}

.hover-card {
  transition: transform 0.4s var(--ease-out), box-shadow 0.4s var(--ease-out), border-color 0.4s;
}

.hover-card:hover {
  transform: translateY(-6px);
  border-color: rgba(239,90,80,0.4);
  box-shadow: 0 20px 40px rgba(0,0,0,0.5), 0 4px 16px rgba(239,90,80,0.12);
}

.theme-toggle {
  position: fixed;
  top: 7.5rem;
  left: 3rem;
  z-index: 450;
  display: inline-flex;
  align-items: center;
  padding: 4px;
  background: rgba(255, 255, 255, 0.7);
  backdrop-filter: blur(14px) saturate(1.4);
  -webkit-backdrop-filter: blur(14px) saturate(1.4);
  border: 1px solid var(--border);
  border-radius: 100px;
  cursor: pointer;
  transition: background 0.35s var(--ease-out), border-color 0.35s var(--ease-out), box-shadow 0.35s var(--ease-out), transform 0.25s var(--ease-spring);
  box-shadow: 0 1px 0 rgba(255, 255, 255, 0.65) inset, 0 4px 14px -6px rgba(10, 10, 10, 0.18);
}

[data-theme="dark"] .theme-toggle {
  background: rgba(20, 20, 20, 0.55);
  box-shadow: 0 1px 0 rgba(255, 255, 255, 0.04) inset, 0 4px 14px -6px rgba(0, 0, 0, 0.55);
}

.theme-toggle:hover {
  transform: translateY(-1px);
  border-color: rgba(239, 90, 80, 0.45);
}

.theme-toggle:focus-visible {
  outline: 2px solid var(--red-vivid);
  outline-offset: 3px;
}

.theme-toggle__track {
  position: relative;
  display: inline-flex;
  align-items: center;
  width: 58px;
  height: 26px;
}

.theme-toggle__indicator {
  position: absolute;
  top: 0;
  left: 0;
  width: 26px;
  height: 26px;
  border-radius: 50%;
  background: linear-gradient(145deg, var(--red-vivid), var(--red));
  box-shadow: 0 2px 6px rgba(242, 61, 51, 0.4), 0 0 10px rgba(242, 61, 51, 0.28), inset 0 1px 1px rgba(255, 255, 255, 0.3);
  transition: transform 0.35s var(--ease-spring);
  transform: translateX(0);
}

[data-theme="dark"] .theme-toggle__indicator {
  transform: translateX(32px);
}

.theme-toggle__icon {
  position: relative;
  z-index: 1;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 26px;
  height: 26px;
  color: var(--text-muted);
  transition: color 0.3s var(--ease-out);
}

.theme-toggle__icon svg {
  width: 13px;
  height: 13px;
}

.theme-toggle__icon--sun {
  color: #FFFFFF;
}

.theme-toggle__icon--moon {
  color: var(--text-muted);
}

[data-theme="dark"] .theme-toggle__icon--sun {
  color: var(--text-muted);
}

[data-theme="dark"] .theme-toggle__icon--moon {
  color: #FFFFFF;
}
