/* Social Sharing Buttons Styles */

.social-share {
  margin: 0;
  padding: 0.5rem 0.25rem 0 0;
  background: transparent;
  border: none;
  border-radius: 0;
  box-shadow: none;
  transition: all 0.2s ease-in-out;
}

.social-share:hover {
  box-shadow: none;
}

/* Content Container */
.social-share__content {
  display: flex;
  justify-content: flex-end;
  align-items: center;
  margin-bottom: 0.5rem;
  gap: 1rem;
}

.social-share__text {
  flex: 0 0 auto;
}

.social-share__title {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  margin: 0;
  font-size: 1rem;
  font-weight: 600;
  color: var(--md-default-fg-color);
}

.social-share__title .twemoji svg {
  width: 1rem;
  height: 1rem;
  fill: var(--md-primary-fg-color);
}

.social-share__subtitle {
  margin: 0;
  font-size: 0.8rem;
  color: var(--md-default-fg-color--light);
  font-style: italic;
  text-align: center;
  width: 100%;
}

/* Buttons Container */
.social-share__buttons {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.5rem;
}

/* Individual Button */
.social-share__button {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 2rem;
  height: 2rem;
  border-radius: 50%;
  text-decoration: none;
  transition: all 0.2s ease-in-out;
  border: 2px solid transparent;
  position: relative;
  overflow: visible;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
}

.social-share__button:hover {
  transform: translateY(-2px) scale(1.1);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
  text-decoration: none;
}

.social-share__icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 1rem;
  height: 1rem;
  flex-shrink: 0;
}

.social-share__icon svg {
  width: 100%;
  height: 100%;
  fill: currentColor;
}

.social-share__label {
  display: none;
}

/* Tooltip styles */
.social-share__button::after {
  content: attr(title);
  position: absolute;
  bottom: 120%;
  left: 50%;
  transform: translateX(-50%);
  background: rgba(0, 0, 0, 0.9);
  color: white;
  padding: 0.375rem 0.5rem;
  border-radius: 0.25rem;
  font-size: 0.75rem;
  font-weight: 500;
  white-space: nowrap;
  opacity: 0;
  visibility: hidden;
  transition: all 0.2s ease-in-out;
  pointer-events: none;
  z-index: 10;
}

.social-share__button::before {
  content: "";
  position: absolute;
  bottom: 105%;
  left: 50%;
  transform: translateX(-50%);
  width: 0;
  height: 0;
  border-left: 4px solid transparent;
  border-right: 4px solid transparent;
  border-top: 4px solid rgba(0, 0, 0, 0.9);
  opacity: 0;
  visibility: hidden;
  transition: all 0.2s ease-in-out;
  z-index: 10;
}

.social-share__button:hover::after,
.social-share__button:hover::before {
  opacity: 1;
  visibility: visible;
}

/* Platform-specific colors */

/* Twitter */
.social-share__button--twitter {
  background-color: #1da1f2;
  color: #ffffff;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.3);
}

.social-share__button--twitter:hover {
  background-color: #0d8bd9;
  color: #ffffff;
}

/* Threads */
.social-share__button--threads {
  background-color: #000000;
  color: #ffffff;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.5);
}

.social-share__button--threads:hover {
  background-color: #1a1a1a;
  color: #ffffff;
}

/* Bluesky */
.social-share__button--bluesky {
  background-color: #0085ff;
  color: #ffffff;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.3);
}

.social-share__button--bluesky:hover {
  background-color: #0066cc;
  color: #ffffff;
}

/* LinkedIn */
.social-share__button--linkedin {
  background-color: #0a66c2;
  color: #ffffff;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.3);
}

.social-share__button--linkedin:hover {
  background-color: #084d94;
  color: #ffffff;
}

/* Reddit */
.social-share__button--reddit {
  background-color: #ff4500;
  color: #ffffff;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.3);
}

.social-share__button--reddit:hover {
  background-color: #e03d00;
  color: #ffffff;
}

/* Hacker News */
.social-share__button--hackernews {
  background-color: #ff6600;
  color: #ffffff;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.3);
}

.social-share__button--hackernews:hover {
  background-color: #e55a00;
  color: #ffffff;
}

/* Note: Footer styles removed as requested */

/* Dark mode adjustments */
[data-md-color-scheme="slate"] .social-share {
  background: var(--md-code-bg-color);
  border-color: var(--md-default-fg-color--lightest);
}

[data-md-color-scheme="slate"] .social-share__button--threads {
  background-color: #ffffff;
  color: #000000;
  text-shadow: none;
}

[data-md-color-scheme="slate"] .social-share__button--threads:hover {
  background-color: #e6e6e6;
  color: #000000;
}

/* Responsive Design */
@media (max-width: 768px) {
  .social-share {
    margin: 0;
    padding: 0.75rem 1rem 0.75rem 0;
  }

  .social-share__content {
    flex-direction: column;
    align-items: flex-end;
    gap: 0.75rem;
  }

  .social-share__buttons {
    align-self: flex-end;
    gap: 0.375rem;
  }

  .social-share__button {
    width: 1.75rem;
    height: 1.75rem;
  }

  .social-share__icon {
    width: 0.875rem;
    height: 0.875rem;
  }

  .social-share__title {
    font-size: 0.9rem;
  }

  .social-share__title .twemoji svg {
    width: 0.9rem;
    height: 0.9rem;
  }

  .social-share__subtitle {
    font-size: 0.75rem;
    margin: 0.5rem 0 0 0;
  }
}

@media (max-width: 480px) {
  .social-share__buttons {
    gap: 0.25rem;
    flex-wrap: wrap;
  }

  .social-share__button {
    width: 1.5rem;
    height: 1.5rem;
  }

  .social-share__icon {
    width: 0.75rem;
    height: 0.75rem;
  }
}

/* Print styles */
@media print {
  .social-share {
    display: none;
  }
}

/* Accessibility improvements */
.social-share__button:focus {
  outline: 2px solid var(--md-accent-fg-color);
  outline-offset: 2px;
}

.social-share__button:focus:not(:focus-visible) {
  outline: none;
}

/* Animation for buttons */
@keyframes shareButtonPress {
  0% { transform: translateY(-1px) scale(1); }
  50% { transform: translateY(0) scale(0.98); }
  100% { transform: translateY(-1px) scale(1); }
}

.social-share__button:active {
  animation: shareButtonPress 0.1s ease-in-out;
}

/* Loading state for buttons */
.social-share__button--loading {
  pointer-events: none;
  opacity: 0.7;
}

.social-share__button--loading::after {
  content: "";
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 1rem;
  height: 1rem;
  border: 2px solid transparent;
  border-top: 2px solid currentColor;
  border-radius: 50%;
  animation: spin 1s linear infinite;
}

@keyframes spin {
  0% { transform: translate(-50%, -50%) rotate(0deg); }
  100% { transform: translate(-50%, -50%) rotate(360deg); }
}

/* Note: Hover effects now handled by tooltips */