/* ===========================================
   PNP 2030 - Theme Manager Styles
   Stili per la pagina di gestione temi
   =========================================== */

/* Theme Cards */
.theme-card {
    cursor: pointer;
    border: 2px solid transparent;
}

.theme-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.1);
}

.theme-card.selected {
    border-color: var(--pnp-primary, #0d6efd);
}

.theme-card .badge-default {
    position: absolute;
    top: 10px;
    right: 10px;
}

/* Palette Preview */
.palette-preview {
    display: flex;
    gap: 5px;
    margin-top: 10px;
}

.palette-color {
    width: 30px;
    height: 30px;
    border-radius: 4px;
    border: 1px solid rgba(0, 0, 0, 0.1);
}

.palette-color:hover {
    transform: scale(1.2);
}

/* Large palette display */
.palette-preview-lg .palette-color {
    width: 50px;
    height: 50px;
}

/* Color Input Group */
.color-input-group {
    display: flex;
    align-items: center;
    gap: 10px;
}

.color-input-group input[type="color"] {
    width: 50px;
    height: 38px;
    padding: 2px;
    border: 1px solid #ced4da;
    border-radius: 4px;
    cursor: pointer;
}

.color-input-group input[type="color"]:hover {
    border-color: var(--pnp-primary, #0d6efd);
}

/* Preview Frame */
.preview-frame {
    border: 2px solid #dee2e6;
    border-radius: 8px;
    overflow: hidden;
    min-height: 400px;
    background: #f8f9fa;
}

.preview-navbar {
    padding: 15px 20px;
    color: white;
    font-weight: 500;
}

.preview-navbar-title {
    font-weight: 700;
}

.preview-navbar-user {
    float: right;
}

.preview-body {
    padding: 20px;
}

.preview-card {
    margin: 15px;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.preview-card-header {
    padding: 10px 15px;
    color: white;
    font-weight: 500;
}

.preview-card-body {
    padding: 15px;
    background: white;
}

/* Tab Content */
.tab-content {
    padding-top: 20px;
}

/* Theme Status Badge */
.theme-status {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    padding: 4px 8px;
    border-radius: 4px;
    font-size: 0.875rem;
}

.theme-status.active {
    background-color: rgba(25, 135, 84, 0.1);
    color: #198754;
}

.theme-status.inactive {
    background-color: rgba(108, 117, 125, 0.1);
    color: #6c757d;
}

/* Region Badge */
.region-badge {
    display: inline-block;
    padding: 2px 8px;
    background-color: rgba(13, 110, 253, 0.1);
    color: #0d6efd;
    border-radius: 4px;
    font-size: 0.75rem;
    font-weight: 500;
}

/* Color Code Display */
.color-code {
    font-family: 'Consolas', 'Monaco', monospace;
    font-size: 0.85rem;
    padding: 2px 6px;
    background-color: #f8f9fa;
    border-radius: 3px;
    border: 1px solid #e9ecef;
}

/* Theme Info Box */
.theme-info-box {
    background-color: #e7f3ff;
    border-left: 4px solid var(--pnp-primary, #0d6efd);
    padding: 15px;
    border-radius: 0 8px 8px 0;
    margin-bottom: 20px;
}

.theme-info-box h6 {
    color: var(--pnp-primary, #0d6efd);
    margin-bottom: 10px;
}

.theme-info-box ul {
    margin-bottom: 0;
    padding-left: 20px;
}

.theme-info-box li {
    margin-bottom: 5px;
}

/* Action Buttons */
.theme-actions {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
}

.theme-actions .btn {
    padding: 0.25rem 0.5rem;
    font-size: 0.875rem;
}

/* Responsive */
@media (max-width: 768px) {
    .palette-preview {
        flex-wrap: wrap;
    }
    
    .color-input-group {
        flex-direction: column;
        align-items: flex-start;
    }
    
    .color-input-group input[type="color"] {
        width: 100%;
    }
    
    .theme-card {
        margin-bottom: 15px;
    }
}

/* NOTA: Animazioni theme-switch-animation e themeFadeIn rimosse
   per eliminare l'effetto dissolvenza ad ogni caricamento */

/* Loading State */
.theme-loading {
    position: relative;
    pointer-events: none;
}

.theme-loading::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(255, 255, 255, 0.7);
    display: flex;
    align-items: center;
    justify-content: center;
}
