/* Social Sharing Module CSS
 * Reusable social sharing styles for all BAC Calculator pages
 * Domain: baccalculator.xyz
 */

/* Social Sharing Section */
.social-sharing-section {
    background: var(--light-bg, #f8f9fa);
    padding: 2rem 0;
    border-top: 1px solid var(--border-color, #e0e0e0);
    border-bottom: 1px solid var(--border-color, #e0e0e0);
    margin: 2rem 0;
}

.social-sharing-container {
    text-align: center;
    max-width: 600px;
    margin: 0 auto;
    padding: 0 1rem;
}

.social-sharing-container h3 {
    color: var(--primary-color, #2c5aa0);
    font-size: 1.5rem;
    margin-bottom: 0.5rem;
    font-weight: 600;
}

.social-sharing-container p {
    color: var(--text-light, #666666);
    margin-bottom: 1.5rem;
    font-size: 1rem;
    line-height: 1.5;
}

.social-sharing {
    display: flex;
    justify-content: center;
    gap: 1rem;
    flex-wrap: wrap;
}

.share-btn {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.75rem 1.5rem;
    border: none;
    border-radius: var(--border-radius, 8px);
    cursor: pointer;
    transition: all 0.3s ease;
    color: var(--white, #ffffff);
    font-weight: 600;
    text-decoration: none;
    min-width: 120px;
    justify-content: center;
    font-size: 0.9rem;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.share-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
}

.share-btn:active {
    transform: translateY(0);
}

.share-btn svg {
    flex-shrink: 0;
    width: 20px;
    height: 20px;
}

.share-btn span {
    font-weight: 600;
    letter-spacing: 0.5px;
}

/* Platform-specific styles */
.share-btn.facebook {
    background: linear-gradient(135deg, #1877f2, #166fe5);
}

.share-btn.facebook:hover {
    background: linear-gradient(135deg, #166fe5, #1464d6);
}

.share-btn.twitter {
    background: linear-gradient(135deg, #1da1f2, #1a91da);
}

.share-btn.twitter:hover {
    background: linear-gradient(135deg, #1a91da, #1781c2);
}

.share-btn.linkedin {
    background: linear-gradient(135deg, #0077b5, #006ba1);
}

.share-btn.linkedin:hover {
    background: linear-gradient(135deg, #006ba1, #005f8d);
}

.share-btn.copy-link {
    background: linear-gradient(135deg, var(--text-dark, #333333), #555555);
    color: var(--white, #ffffff);
}

.share-btn.copy-link:hover {
    background: linear-gradient(135deg, var(--primary-color, #2c5aa0), var(--secondary-color, #4a90e2));
}

/* Success state for copy button */
.share-btn.copy-link.success {
    background: linear-gradient(135deg, #28a745, #20c997);
}

/* Responsive design */
@media (max-width: 768px) {
    .social-sharing-section {
        padding: 1.5rem 0;
        margin: 1.5rem 0;
    }
    
    .social-sharing-container {
        padding: 0 0.75rem;
    }
    
    .social-sharing-container h3 {
        font-size: 1.3rem;
    }
    
    .social-sharing {
        gap: 0.75rem;
    }
    
    .share-btn {
        min-width: 100px;
        padding: 0.625rem 1.25rem;
        font-size: 0.85rem;
    }
    
    .share-btn svg {
        width: 18px;
        height: 18px;
    }
}

@media (max-width: 480px) {
    .social-sharing {
        flex-direction: column;
        align-items: center;
        gap: 0.5rem;
    }
    
    .share-btn {
        width: 100%;
        max-width: 200px;
        justify-content: center;
    }
    
    .social-sharing-container h3 {
        font-size: 1.2rem;
    }
    
    .social-sharing-container p {
        font-size: 0.9rem;
    }
}

/* Animation for sharing success */
@keyframes shareSuccess {
    0% {
        transform: scale(1);
    }
    50% {
        transform: scale(1.05);
    }
    100% {
        transform: scale(1);
    }
}

.share-btn.animate-success {
    animation: shareSuccess 0.3s ease-in-out;
}

/* Focus states for accessibility */
.share-btn:focus {
    outline: 2px solid var(--primary-color, #2c5aa0);
    outline-offset: 2px;
}

.share-btn:focus:not(:focus-visible) {
    outline: none;
}

/* High contrast mode support */
@media (prefers-contrast: high) {
    .share-btn {
        border: 2px solid currentColor;
    }
    
    .social-sharing-section {
        border-top: 2px solid var(--border-color, #e0e0e0);
        border-bottom: 2px solid var(--border-color, #e0e0e0);
    }
}

/* Reduced motion support */
@media (prefers-reduced-motion: reduce) {
    .share-btn {
        transition: none;
    }
    
    .share-btn:hover {
        transform: none;
    }
    
    .animate-success {
        animation: none;
    }
}

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