/*
 * MFMD Plataforma de Ferramentas - Folha de Estilos Principal
 * Version: 2.1.0
 */

/* --- Variáveis de Design para Consistência --- */
:root {
    --mfmd-primary-color: #0073e6;
    --mfmd-primary-hover: #005bb5;
    --mfmd-text-dark: #111;
    --mfmd-text-light: #666;
    --mfmd-border-color: #e0e0e0;
    --mfmd-background-light: #f8f9fa;
    --mfmd-star-color: #ffb400;
}

:root {
    --mfmd-primary-color: #0073e6;
    --mfmd-primary-hover: #005bb5;
    --mfmd-text-dark: #111;
    --mfmd-text-light: #666;
    --mfmd-border-color: #e0e0e0;
    --mfmd-background-light: #f8f9fa;
    --mfmd-star-color: #ffb400;
}

.mfmd-referrals-wrapper { max-width: 1200px; margin: 40px auto; font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif; }
.referral-filters { text-align: center; margin-bottom: 40px; display: flex; flex-wrap: wrap; justify-content: center; gap: 10px; }
.filter-btn { background: #f1f1f1; border: none; padding: 10px 20px; cursor: pointer; border-radius: 20px; font-size: 14px; font-weight: 500; transition: all 0.2s ease; }
.filter-btn.active, .filter-btn:hover { background: #0073e6; color: #fff; }
.referral-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 30px; }
.referral-card { background: #fff; border-radius: 12px; box-shadow: 0 5px 25px rgba(0,0,0,0.07); overflow: hidden; transition: all 0.3s ease; display: flex; flex-direction: column; }
.referral-card:hover { transform: translateY(-5px); box-shadow: 0 10px 30px rgba(0,0,0,0.1); }
.card-link-wrapper { text-decoration: none; color: inherit; display: flex; flex-direction: column; height: 100%; }
.referral-logo { height: 150px; display: flex; align-items: center; justify-content: center; background: #f8f9fa; padding: 15px; }
.referral-logo img, .referral-logo svg { max-width: 100%; max-height: 80px; width: auto; height: 80px; object-fit: contain; }
.placeholder-logo { font-size: 50px; font-weight: bold; color: #ccc; background-color: #eee; width: 80px; height: 80px; border-radius: 50%; display: flex; align-items: center; justify-content: center; }
.referral-details { padding: 20px; flex-grow: 1; display: flex; flex-direction: column; }
.referral-details h3 { margin: 0 0 10px; font-size: 1.1rem; color: #111; }
.referral-excerpt { font-size: 0.9rem; color: #666; line-height: 1.5; flex-grow: 1; }
.referral-rating { margin-top: 15px; font-size: 0.8rem; color: #888; display: flex; align-items: center; }
.rating-stars { display: inline-block; position: relative; color: #ddd; font-size: 18px; }
.rating-stars::before { content: '★★★★★'; position: absolute; top: 0; left: 0; color: #ffb400; overflow: hidden; width: calc(var(--rating, 0) / 5 * 100%); }
.rating-value { margin-left: 8px; }

.referral-meta-content-wrapper { margin-top: 40px; padding-top: 30px; border-top: 2px dashed #eee; font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif; }
.referral-cta-button { display: block; background: #0073e6; color: #fff !important; text-align: center; padding: 15px; border-radius: 8px; font-size: 1.2rem; font-weight: bold; text-decoration: none; transition: background 0.2s; margin-bottom: 30px; }
.referral-cta-button:hover { background: #005bb5; }
.referral-user-interaction { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 30px; }
.rating-section, .sharing-section { flex: 1; min-width: 280px; }
.rating-section h4, .sharing-section h4 { margin: 0 0 15px; font-size: 1.1rem; }
.user-rating-stars .star { font-size: 28px; color: #ccc; cursor: pointer; transition: color 0.2s; }
.user-rating-stars .star:hover, .user-rating-stars .star.selected { color: #ffb400; }
.user-rating-stars-disabled .star-disabled { font-size: 28px; color: #ddd; margin-right: 2px; }
.rating-login-notice { font-size: 0.85rem; color: #c00; margin-top: 5px; }
.rating-summary-text { font-size: 0.95rem; margin-top: 10px; }
.social-share-buttons { display: flex; flex-wrap: wrap; gap: 10px; }

.social-icon { 
    display: inline-flex !important; 
    align-items: center !important; 
    justify-content: center !important; 
    width: 40px !important; 
    height: 40px !important; 
    border-radius: 50% !important; 
    background: #f1f1f1 !important; 
    color: #333 !important; 
    transition: all 0.2s !important; 
    box-shadow: none !important;
    text-shadow: none !important;
    border: none !important;
    padding: 0 !important;
    margin: 0 !important;
    cursor: pointer !important;
    line-height: 1 !important;
}
.social-icon svg { width: 20px !important; height: 20px !important; fill: currentColor !important; display: block !important; }
.social-icon:hover { transform: scale(1.08) !important; background: #e1e1e1 !important; }
.social-icon.facebook svg { color: #1877F2; }
.social-icon.linkedin svg { color: #0077B5; }
.social-icon.x svg { color: #000000; }
.social-icon.whatsapp svg { color: #25D366; }
.social-icon.instagram svg { color: #E4405F; }
.social-icon.email svg { color: #888888; }

button.social-icon.copy-link {
    background: #f1f1f1 !important;
    border: none !important;
    border-radius: 50% !important;
    position: relative !important;
    overflow: visible !important;
}
.copy-feedback { position: absolute; top: -35px; left: 50%; transform: translateX(-50%); background-color: #333; color: #fff; padding: 4px 8px; border-radius: 4px; font-size: 11px; white-space: nowrap; opacity: 0; visibility: hidden; transition: opacity 0.3s, visibility 0.3s; pointer-events: none; }
.copy-feedback.show { opacity: 1; visibility: visible; }