/**
 * ===================================================================
 * FILE: public/css/blocks.css - CSS FRONTEND PER BLOCCHI
 * ===================================================================
 * 
 * Stili che si applicano ai blocchi nel frontend del sito
 * Questi stili sono visibili ai visitatori del sito
 */

/* ===================================================================
   BLOCCO PRINCIPALE FRONTEND
   ================================================================= */

.base-plugin-faber-block {
    position: relative;
    transition: all 0.3s ease;
    border-radius: 6px;
    overflow: hidden;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
}

.base-plugin-faber-block:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 25px rgba(0,0,0,0.15);
}

.base-plugin-faber-block .block-icon {
    display: inline-block;
    vertical-align: middle;
    animation: gentle-bounce 3s ease-in-out infinite;
}

@keyframes gentle-bounce {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-5px); }
}

.base-plugin-faber-block .block-content {
    position: relative;
    z-index: 2;
}

.base-plugin-faber-block .block-content p {
    margin: 0;
    line-height: 1.6;
    font-weight: 400;
}

/* Effetto sottile di background */
.base-plugin-faber-block:before {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(135deg, rgba(255,255,255,0.1) 0%, rgba(255,255,255,0.05) 100%);
    z-index: 1;
    pointer-events: none;
}

/* ===================================================================
   VARIANTI DI STILE
   ================================================================= */

/* Default style */
.base-plugin-faber-block.style-default {
    background: linear-gradient(135deg, #e7f3ff 0%, #f0f8ff 100%);
    border-left: 4px solid #2196F3;
    color: #1565C0;
}

/* Success style */
.base-plugin-faber-block.style-success {
    background: linear-gradient(135deg, #d4edda 0%, #e8f5e8 100%);
    border-left: 4px solid #28a745;
    color: #155724;
}

.base-plugin-faber-block.style-success .block-icon {
    color: #28a745;
}

/* Warning style */
.base-plugin-faber-block.style-warning {
    background: linear-gradient(135deg, #fff3cd 0%, #fffaf0 100%);
    border-left: 4px solid #ffc107;
    color: #856404;
}

.base-plugin-faber-block.style-warning .block-icon {
    color: #ffc107;
    animation: warning-pulse 2s ease-in-out infinite;
}

@keyframes warning-pulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.7; }
}

/* Error style */
.base-plugin-faber-block.style-error {
    background: linear-gradient(135deg, #f8d7da 0%, #fdeaea 100%);
    border-left: 4px solid #dc3545;
    color: #721c24;
}

.base-plugin-faber-block.style-error .block-icon {
    color: #dc3545;
    animation: error-shake 0.5s ease-in-out;
}

@keyframes error-shake {
    0%, 100% { transform: translateX(0); }
    25% { transform: translateX(-5px); }
    75% { transform: translateX(5px); }
}

/* ===================================================================
   INFO BLOCK FRONTEND
   ================================================================= */

.base-plugin-faber-info-block {
    background: linear-gradient(135deg, #f8f9fa 0%, #ffffff 100%);
    border: 1px solid #dee2e6;
    border-radius: 8px;
    padding: 20px;
    margin: 15px 0;
    position: relative;
    transition: all 0.3s ease;
}

.base-plugin-faber-info-block:hover {
    border-color: #17a2b8;
    box-shadow: 0 4px 15px rgba(23, 162, 184, 0.1);
}

.base-plugin-faber-info-block h4 {
    color: #17a2b8;
    margin: 0 0 15px 0;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 8px;
}

.base-plugin-faber-info-block p {
    margin: 8px 0;
    color: #495057;
}

.base-plugin-faber-info-block strong {
    color: #212529;
}

/* Status indicators */
.base-plugin-faber-info-block .status-active {
    color: #28a745;
    font-weight: 600;
}

.base-plugin-faber-info-block .status-inactive {
    color: #dc3545;
    font-weight: 600;
}

/* ===================================================================
   INTERACTIVE BLOCK FRONTEND
   ================================================================= */

.base-plugin-faber-interactive-block {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 30px;
    border-radius: 12px;
    text-align: center;
    position: relative;
    overflow: hidden;
    margin: 20px 0;
    transition: all 0.4s ease;
}

.base-plugin-faber-interactive-block:hover {
    transform: translateY(-5px) scale(1.02);
    box-shadow: 0 15px 35px rgba(102, 126, 234, 0.3);
}

.base-plugin-faber-interactive-block h3 {
    margin: 0 0 20px 0;
    font-weight: 700;
    text-shadow: 0 2px 4px rgba(0,0,0,0.3);
}

.base-plugin-faber-interactive-block .counter {
    font-size: 28px;
    font-weight: 800;
    margin: 15px 0;
    text-shadow: 0 2px 4px rgba(0,0,0,0.3);
    display: block;
}

.base-plugin-faber-interactive-block button {
    background: rgba(255,255,255,0.15);
    border: 2px solid rgba(255,255,255,0.3);
    color: white;
    padding: 15px 30px;
    border-radius: 50px;
    cursor: pointer;
    font-size: 16px;
    font-weight: 600;
    transition: all 0.3s ease;
    backdrop-filter: blur(10px);
    text-transform: uppercase;
    letter-spacing: 1px;
}

.base-plugin-faber-interactive-block button:hover {
    background: rgba(255,255,255,0.25);
    border-color: rgba(255,255,255,0.5);
    transform: scale(1.05);
    box-shadow: 0 5px 15px rgba(0,0,0,0.2);
}

.base-plugin-faber-interactive-block button:active {
    transform: scale(0.98);
}

/* Effetto particelle di background */
.base-plugin-faber-interactive-block:before {
    content: "";
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle, rgba(255,255,255,0.1) 1px, transparent 1px);
    background-size: 50px 50px;
    animation: float-particles 20s linear infinite;
    pointer-events: none;
}

@keyframes float-particles {
    0% { transform: translateX(0) translateY(0); }
    100% { transform: translateX(-50px) translateY(-50px); }
}

/* ===================================================================
   ALLINEAMENTI
   ================================================================= */

.base-plugin-faber-block.align-left {
    text-align: left;
}

.base-plugin-faber-block.align-center {
    text-align: center;
}

.base-plugin-faber-block.align-right {
    text-align: right;
}

/* ===================================================================
   RESPONSIVE DESIGN
   ================================================================= */

@media (max-width: 768px) {
    .base-plugin-faber-block {
        padding: 15px;
        margin: 10px 0;
    }
    
    .base-plugin-faber-block .block-icon {
        font-size: 20px;
        margin-right: 8px;
    }
    
    .base-plugin-faber-info-block {
        padding: 15px;
    }
    
    .base-plugin-faber-interactive-block {
        padding: 20px;
        margin: 15px 0;
    }
    
    .base-plugin-faber-interactive-block h3 {
        font-size: 20px;
    }
    
    .base-plugin-faber-interactive-block .counter {
        font-size: 24px;
    }
    
    .base-plugin-faber-interactive-block button {
        padding: 12px 24px;
        font-size: 14px;
    }
}