/* ============================================
   SOCIAL SHARE BUTTONS
   ============================================ */

/* Share Container */
.share-container {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    flex-wrap: wrap;
    margin: 2rem 0;
    padding: 1.5rem;
    background: linear-gradient(135deg, #f8fafc 0%, #f1f5f9 100%);
    border-radius: 12px;
    border: 2px solid #e2e8f0;
}

.share-label {
    font-weight: 700;
    color: #64748b;
    font-size: 0.95rem;
    margin-right: 0.5rem;
}

/* Share Buttons */
.share-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 0.75rem 1.25rem;
    border-radius: 10px;
    border: none;
    font-weight: 600;
    font-size: 0.95rem;
    cursor: pointer;
    transition: all 0.3s ease;
    text-decoration: none;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
    position: relative;
    overflow: hidden;
}

.share-btn::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 0;
    height: 0;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.3);
    transform: translate(-50%, -50%);
    transition: width 0.6s, height 0.6s;
}

.share-btn:hover::before {
    width: 300px;
    height: 300px;
}

.share-btn span {
    position: relative;
    z-index: 1;
}

.share-btn-icon {
    font-size: 1.25rem;
    position: relative;
    z-index: 1;
}

.share-btn:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.15);
}

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

/* Individual Platform Styles */

/* Twitter */
.share-btn-twitter {
    background: linear-gradient(135deg, #1DA1F2 0%, #0d8bd9 100%);
    color: white;
}

.share-btn-twitter:hover {
    box-shadow: 0 8px 20px rgba(29, 161, 242, 0.4);
}

/* LinkedIn */
.share-btn-linkedin {
    background: linear-gradient(135deg, #0077B5 0%, #005885 100%);
    color: white;
}

.share-btn-linkedin:hover {
    box-shadow: 0 8px 20px rgba(0, 119, 181, 0.4);
}

/* Facebook */
.share-btn-facebook {
    background: linear-gradient(135deg, #1877F2 0%, #0d5dbf 100%);
    color: white;
}

.share-btn-facebook:hover {
    box-shadow: 0 8px 20px rgba(24, 119, 242, 0.4);
}

/* WhatsApp */
.share-btn-whatsapp {
    background: linear-gradient(135deg, #25D366 0%, #1da851 100%);
    color: white;
}

.share-btn-whatsapp:hover {
    box-shadow: 0 8px 20px rgba(37, 211, 102, 0.4);
}

/* Reddit */
.share-btn-reddit {
    background: linear-gradient(135deg, #FF4500 0%, #cc3700 100%);
    color: white;
}

.share-btn-reddit:hover {
    box-shadow: 0 8px 20px rgba(255, 69, 0, 0.4);
}

/* Copy Link */
.share-btn-copy {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
}

.share-btn-copy:hover {
    box-shadow: 0 8px 20px rgba(102, 126, 234, 0.4);
}

.share-btn-copy.copied {
    background: linear-gradient(135deg, #10b981 0%, #059669 100%);
}

.share-btn-copy.copied .share-btn-icon::after {
    content: '✓';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    font-size: 1.5rem;
    animation: checkmark 0.5s ease;
}

@keyframes checkmark {
    0% {
        opacity: 0;
        transform: translate(-50%, -50%) scale(0);
    }
    50% {
        opacity: 1;
        transform: translate(-50%, -50%) scale(1.3);
    }
    100% {
        opacity: 1;
        transform: translate(-50%, -50%) scale(1);
    }
}

/* Email */
.share-btn-email {
    background: linear-gradient(135deg, #34495e 0%, #2c3e50 100%);
    color: white;
}

.share-btn-email:hover {
    box-shadow: 0 8px 20px rgba(52, 73, 94, 0.4);
}

/* Compact Share Buttons (for mobile or sidebar) */
.share-btn-compact {
    padding: 0.65rem;
    width: 44px;
    height: 44px;
    border-radius: 50%;
}

.share-btn-compact span:not(.share-btn-icon) {
    display: none;
}

/* Floating Share Bar (Sticky) */
.share-floating {
    position: sticky;
    top: 120px;
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
    padding: 1rem;
    background: white;
    border-radius: 12px;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.1);
}

.share-floating .share-label {
    margin: 0 0 0.5rem 0;
    text-align: center;
    font-size: 0.85rem;
}

.share-floating .share-btn {
    width: 48px;
    height: 48px;
    padding: 0;
    border-radius: 50%;
    justify-content: center;
}

.share-floating .share-btn span:not(.share-btn-icon) {
    display: none;
}

/* Share Count */
.share-count {
    position: absolute;
    top: -8px;
    right: -8px;
    background: #ef4444;
    color: white;
    font-size: 0.75rem;
    font-weight: 700;
    padding: 0.25rem 0.5rem;
    border-radius: 12px;
    box-shadow: 0 2px 8px rgba(239, 68, 68, 0.3);
    animation: countPop 0.5s cubic-bezier(0.68, -0.55, 0.265, 1.55);
}

@keyframes countPop {
    0% {
        transform: scale(0);
    }
    50% {
        transform: scale(1.2);
    }
    100% {
        transform: scale(1);
    }
}

/* Mobile Styles */
@media (max-width: 768px) {
    .share-container {
        padding: 1rem;
        gap: 0.5rem;
    }

    .share-btn {
        padding: 0.65rem 1rem;
        font-size: 0.9rem;
        flex: 1;
        min-width: 120px;
    }

    .share-btn span:not(.share-btn-icon) {
        display: none;
    }

    .share-btn-compact {
        min-width: unset;
        flex: 0;
    }

    .share-floating {
        position: fixed;
        bottom: 20px;
        right: 20px;
        flex-direction: row;
        padding: 0.75rem;
        z-index: 1000;
    }

    .share-floating .share-label {
        display: none;
    }

    .share-floating .share-btn {
        width: 44px;
        height: 44px;
    }
}

/* Dark Mode */
@media (prefers-color-scheme: dark) {
    .share-container {
        background: linear-gradient(135deg, #1e293b 0%, #334155 100%);
        border-color: #475569;
    }

    .share-label {
        color: #cbd5e1;
    }

    .share-floating {
        background: #1e293b;
        box-shadow: 0 8px 24px rgba(0, 0, 0, 0.3);
    }
}

/* Accessibility */
.share-btn:focus {
    outline: 3px solid #667eea;
    outline-offset: 2px;
}

/* Print */
@media print {
    .share-container,
    .share-floating {
        display: none;
    }
}
