/**
 * subscriptions.css
 * Styles for the follow/subscribe button in Stories.
 * Supports light/dark themes via CSS custom properties.
 */

:root {
  --follow-border:      #D1D5DB;
  --follow-text:        #374151;
  --follow-hover-bg:    rgba(212, 175, 55, 0.08);
  --follow-active-bg:   #D4AF37;
  --follow-active-text: #1F2937;
  --follow-count:       #6B7280;
}

[data-theme="dark"] {
  --follow-border:      #4B5563;
  --follow-text:        #E5E7EB;
  --follow-hover-bg:    rgba(212, 175, 55, 0.15);
  --follow-active-bg:   #D4AF37;
  --follow-active-text: #1F2937;
  --follow-count:       #9CA3AF;
}

/* Follow button */
.follow-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 16px;
  border: 1.5px solid var(--follow-border);
  border-radius: 20px;
  background: transparent;
  font-family: inherit;
  font-size: 14px;
  font-weight: 500;
  color: var(--follow-text);
  cursor: pointer;
  user-select: none;
  -webkit-tap-highlight-color: transparent;
  transition: all 0.2s ease;
}

.follow-btn:hover {
  background: var(--follow-hover-bg);
  border-color: #D4AF37;
}

.follow-btn:active {
  transform: scale(0.95);
}

.follow-btn:focus-visible {
  outline: 2px solid var(--cyan, #0891B2);
  outline-offset: 2px;
}

/* Following state */
.follow-btn.following {
  background: var(--follow-active-bg);
  border-color: var(--follow-active-bg);
  color: var(--follow-active-text);
}

.follow-btn.following:hover {
  opacity: 0.85;
}

.follow-icon {
  font-size: 14px;
  line-height: 1;
}

/* Subscribers count */
.subscribers-count {
  font-size: 14px;
  color: var(--follow-count);
  margin-left: 8px;
}

/* Animation */
@keyframes followPop {
  0%   { transform: scale(1.0); }
  30%  { transform: scale(1.15); }
  60%  { transform: scale(0.95); }
  100% { transform: scale(1.0); }
}

.follow-btn.animating {
  animation: followPop 0.35s ease-in-out;
}

/* Author page: inline follow */
.author-follow {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  margin-top: 12px;
}

/* Tag page: inline follow */
.tag-follow {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-top: 8px;
  justify-content: center;
}

@media (max-width: 640px) {
  .follow-btn {
    padding: 5px 12px;
    font-size: 13px;
  }

  .subscribers-count {
    font-size: 13px;
  }
}
