/* ========================================
 * PAGE-THEME-ACTIONS-BAR.CSS
 * Barre d'actions style Instagram pour thèmes
 * Basé sur page-ingredient-actions-bar.css
 * ======================================== */

/* Container principal - Aucun background ni shadow */
.theme-actions-bar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 100%;
    padding: 10px 4px 6px 4px;
    margin-top: 0;
    background: none !important;
    background-color: transparent !important;
    box-shadow: none !important;
    border: none !important;
}

/* Groupes gauche et droite */
.theme-actions-left,
.theme-actions-right {
    display: flex;
    align-items: center;
    gap: 20px;
}

/* Alignement vertical spécifique pour les icônes */
.theme-actions-left .theme-action-btn,
.theme-actions-right .theme-action-btn {
    display: flex;
    align-items: center;
    justify-content: center;
}

.theme-actions-left .theme-action-btn i,
.theme-actions-right .theme-action-btn i {
    display: flex;
    align-items: center;
    justify-content: center;
    height: 1.5rem;
    line-height: 1;
}

/* Bouton d'action */
.theme-action-btn {
    position: relative;
    display: flex;
    align-items: center;
    gap: 10px;
    background: none;
    border: none;
    padding: 8px 6px;
    cursor: pointer;
    color: var(--text-color, #262626);
    font-size: 1rem;
    transition: all 0.2s ease;
    text-decoration: none;
    overflow: visible;
}

.theme-action-btn:hover > i {
    opacity: 0.7;
}

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

/* Icônes - taille uniforme */
.theme-action-btn i {
    font-size: 1.5rem;
    width: 1.5rem;
    text-align: center;
    transition: all 0.2s ease;
    cursor: pointer;
}

/* ======================================
 * ÉTATS SPÉCIFIQUES
 * ====================================== */

/* Like actif (cœur rouge) */
.theme-action-like.active i {
    color: #ed4956 !important;
}

/* Animation des boutons */
@keyframes themeActionAnimation {
    0% { transform: scale(1); }
    25% { transform: scale(1.3); }
    50% { transform: scale(0.95); }
    100% { transform: scale(1); }
}

.theme-action-btn.animating i {
    animation: themeActionAnimation 0.4s ease-in-out;
}

/* Masquer l'icône pendant le chargement */
.theme-action-btn.loading i {
    opacity: 0;
    transition: opacity 0.2s ease;
}

.theme-action-btn:not(.loading) i {
    opacity: 1;
}

/* État disabled pendant le chargement */
.theme-action-btn.loading {
    pointer-events: none;
}

/* Partage - icône couleur par défaut */
.theme-action-share i {
    color: inherit;
}

/* ======================================
 * CONTENU CACHÉ DES TOOLTIPS
 * ====================================== */
.tooltip-content-hidden {
    display: none;
}

/* ======================================
 * TOOLTIPSTER THEME SAVOOR (pour le partage)
 * ====================================== */
.tooltipster-sidetip.tooltipster-savoor .tooltipster-box {
    background: #2a3334;
    border: 2px solid var(--savoor-coral, #FF6B6B);
    border-radius: 8px;
}

.tooltipster-sidetip.tooltipster-savoor.tooltipster-top .tooltipster-arrow-border,
.tooltipster-sidetip.tooltipster-savoor.tooltipster-top .tooltipster-arrow-background {
    border-top-color: var(--savoor-coral, #FF6B6B);
}

.tooltipster-sidetip.tooltipster-savoor .tooltipster-content {
    color: #fff;
    padding: 8px 12px;
}

/* Container de partage dans le tooltip */
.tooltip-share-container {
    text-align: center;
}

.tooltip-share-container .tooltip-title {
    font-weight: 600;
    margin-bottom: 12px;
    font-size: 0.95rem;
    color: #fff;
}

.tooltip-share-options {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.tooltip-share-option {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 12px;
    background: transparent;
    border: none;
    color: #fff;
    font-size: 0.9rem;
    cursor: pointer;
    text-decoration: none;
    border-radius: 6px;
    transition: background-color 0.2s ease;
    width: 100%;
    text-align: left;
}

.tooltip-share-option:hover {
    background: rgba(255, 255, 255, 0.1);
}

.tooltip-share-option i {
    font-size: 1.1rem;
    width: 20px;
    text-align: center;
}

/* Couleurs spécifiques pour les réseaux sociaux */
.tooltip-share-option[data-action="facebook"] i { color: #1877F2; }
.tooltip-share-option[data-action="x"] i { color: #fff; }
.tooltip-share-option[data-action="pinterest"] i { color: #E60023; }
.tooltip-share-option[data-action="whatsapp"] i { color: #25D366; }
.tooltip-share-option[data-action="messenger"] i { color: #0084FF; }
.tooltip-share-option[data-action="email"] i { color: #EA4335; }
.tooltip-share-option[data-action="copy"] i { color: var(--savoor-coral, #FF6B6B); }

/* ======================================
 * TOOLTIPS SIMPLES POUR LES BOUTONS D'ACTION
 * Style identique aux tooltips des recettes et ingrédients
 * ====================================== */

.theme-action-btn .tooltip-text {
    position: absolute;
    bottom: calc(100% + 12px);
    left: calc(6px + 0.75rem);
    transform: translateX(-50%);
    background-color: #2a3334;
    color: #fff;
    padding: 10px 16px;
    border-radius: 8px;
    border: 2px solid var(--savoor-coral, #FF6B6B);
    font-size: 0.95rem;
    font-weight: 500;
    white-space: nowrap;
    visibility: hidden;
    z-index: 1000;
    pointer-events: none;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.3);
}

/* Flèche du tooltip */
.theme-action-btn .tooltip-text::after {
    content: '';
    position: absolute;
    top: 100%;
    left: 50%;
    transform: translateX(-50%);
    border: 8px solid transparent;
    border-top-color: var(--savoor-coral, #FF6B6B);
}

/* Affichage au hover - géré par JavaScript */
.theme-action-btn .tooltip-text.visible {
    visibility: visible;
}

/* Mode clair pour les tooltips simples */
body.light-mode .theme-action-btn .tooltip-text {
    background-color: #2c3e50;
}

/* ======================================
 * MODE SOMBRE
 * ====================================== */
.dark-mode .theme-actions-bar {
    background: transparent;
}

.dark-mode .theme-action-btn {
    color: var(--text-color, #f5f5f5);
}

.dark-mode .theme-action-like.active i {
    color: #ed4956;
}

/* ======================================
 * RESPONSIVE
 * ====================================== */

@media screen and (max-width: 768px) {
    .theme-actions-bar {
        padding: 10px 2px;
    }
    
    .theme-actions-left,
    .theme-actions-right {
        gap: 16px;
    }
    
    .theme-action-btn i {
        font-size: 1.4rem;
    }
    
    /* Masquer les tooltips simples sur tablette/mobile */
    .theme-action-btn .tooltip-text {
        display: none;
    }
}

@media screen and (max-width: 480px) {
    .theme-actions-bar {
        padding: 10px 0;
    }
    
    .theme-actions-left,
    .theme-actions-right {
        gap: 12px;
    }
    
    .theme-action-btn {
        gap: 5px;
        padding: 6px 2px;
    }
    
    .theme-action-btn i {
        font-size: 1.3rem;
    }
}

@media screen and (max-width: 320px) {
    .theme-actions-left,
    .theme-actions-right {
        gap: 8px;
    }
    
    .theme-action-btn i {
        font-size: 1.2rem;
    }
}
