/* Dashboard Widgets */
.dashboard-widgets-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1.5rem;
    margin-bottom: 2rem;
}

.dashboard-widget {
    background: #FFFFFF;
    border-radius: 20px;
    padding: 1.5rem;
    box-shadow: var(--shadow-sm);
    border: 1px solid var(--border-color);
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.dashboard-widget:hover {
    box-shadow: var(--shadow-md);
    transform: translateY(-2px);
}

.widget-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1.5rem;
}

.widget-title {
    font-size: 1rem;
    font-weight: 700;
    color: #000000;
    margin: 0;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.widget-controls {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.widget-dropdown {
    padding: 0.375rem 0.75rem;
    border: 1px solid var(--border-color);
    border-radius: 8px;
    background: var(--bg-card);
    color: var(--text-dark);
    font-size: 0.75rem;
    cursor: pointer;
}

.widget-expand {
    background: var(--bg-light);
    border: none;
    color: var(--text-muted);
    width: 24px;
    height: 24px;
    border-radius: 6px;
    cursor: pointer;
    font-size: 0.875rem;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s;
}

.widget-expand:hover {
    background: var(--primary-color);
    color: white;
}

.widget-content {
    color: #000000;
}

/* REVENUE Widget - White Theme */
.widget-revenue {
    background: #FFFFFF;
    color: #000000;
    border: 1px solid var(--border-color);
}

.widget-revenue .widget-title {
    color: #000000;
}

.revenue-chart {
    margin-bottom: 1.5rem;
}

.chart-bars {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    height: 120px;
    gap: 0.5rem;
}

.chart-bar-container {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.5rem;
}

.chart-bar {
    width: 100%;
    background: var(--accent-coral);
    border-radius: 8px 8px 0 0;
    position: relative;
    min-height: 20px;
    transition: all 0.3s ease;
    opacity: 0.8;
}

.chart-bar:hover {
    opacity: 1;
}

.bar-value {
    position: absolute;
    top: -24px;
    left: 50%;
    transform: translateX(-50%);
    font-size: 0.75rem;
    font-weight: 600;
    white-space: nowrap;
    background: var(--bg-card);
    color: var(--text-dark);
    padding: 0.25rem 0.5rem;
    border-radius: 8px;
    box-shadow: var(--shadow-sm);
}

.bar-label {
    font-size: 0.75rem;
    color: var(--text-muted);
    font-weight: 500;
}

.widget-metrics {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1rem;
}

.widget-metric {
    background: var(--bg-light);
    padding: 1rem;
    border-radius: 12px;
}

.metric-label {
    font-size: 0.75rem;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 0.5rem;
}

.metric-value {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--text-dark);
    margin-bottom: 0.5rem;
}

.metric-badge {
    display: inline-block;
    padding: 0.25rem 0.5rem;
    border-radius: 12px;
    font-size: 0.75rem;
    font-weight: 600;
    margin-top: 0.5rem;
}

.badge-positive {
    background: rgba(16, 185, 129, 0.2);
    color: #000000;
}

.metric-subtext {
    font-size: 0.7rem;
    color: #666666;
    margin-top: 0.25rem;
}

/* ALERT Widget - White Theme */
.widget-alert {
    background: #FFFFFF;
    color: #000000;
    border: 1px solid var(--border-color);
}

.widget-alert .widget-title {
    color: #000000;
}

.alert-content {
    display: flex;
    align-items: flex-start;
    gap: 1rem;
}

.alert-icon {
    font-size: 2rem;
    flex-shrink: 0;
}

.alert-text {
    flex: 1;
}

.alert-text p {
    margin: 0;
    color: var(--text-dark);
    font-size: 0.95rem;
    line-height: 1.5;
}

.alert-text strong {
    color: var(--warning-color);
    font-weight: 700;
}

/* CAPACITY Widget - White Theme */
.widget-capacity {
    background: #FFFFFF;
    color: #000000;
    border: 1px solid var(--border-color);
}

.widget-capacity .widget-title {
    color: #000000;
}

.capacity-indicators {
    display: flex;
    justify-content: space-between;
    margin-bottom: 1.5rem;
    gap: 0.5rem;
}

.capacity-circle {
    flex: 1;
    text-align: center;
    padding: 0.75rem;
    background: var(--bg-card);
    border-radius: 12px;
    transition: all 0.3s ease;
    box-shadow: var(--shadow-sm);
}

.capacity-circle.highlighted {
    background: #7B1FA2;
    color: white;
    transform: scale(1.1);
    box-shadow: var(--shadow-md);
}

.capacity-circle.highlighted .circle-value,
.capacity-circle.highlighted .circle-label {
    color: white;
}

.circle-value {
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--text-dark);
    margin-bottom: 0.25rem;
}

.circle-label {
    font-size: 0.75rem;
    color: var(--text-muted);
    font-weight: 500;
}

.capacity-chart {
    height: 60px;
    background: var(--bg-light);
    border-radius: 12px;
    position: relative;
    overflow: hidden;
}

.chart-line {
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, 
        var(--accent-blue) 0%,
        var(--accent-purple) 50%,
        var(--accent-blue) 100%);
    border-radius: 12px;
    opacity: 0.6;
}

/* POINTS Widget - Soft Teal Theme */
.widget-points {
    background: #FFFFFF;
    color: #000000;
    border: 1px solid var(--border-color);
}

.widget-points .widget-title {
    color: #000000;
}

.campaigns-summary {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1rem;
}

.campaign-stat {
    text-align: center;
    padding: 1rem;
    background: var(--bg-card);
    border-radius: 12px;
    box-shadow: var(--shadow-sm);
}

.stat-value {
    font-size: 1.75rem;
    font-weight: 700;
    color: var(--text-dark);
    margin-bottom: 0.5rem;
}

.stat-label {
    font-size: 0.75rem;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

/* TIMING Widget - Soft Grey Theme */
.widget-timing {
    background: #FFFFFF;
    color: #000000;
    border: 1px solid var(--border-color);
}

.widget-timing .widget-title {
    color: #000000;
}

.timing-visual {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1rem;
    margin-bottom: 1.5rem;
}

.timing-circle {
    width: 120px;
    height: 120px;
    border-radius: 50%;
    background: var(--bg-card);
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: var(--shadow-sm);
}

.timing-arc {
    position: absolute;
    width: 100%;
    height: 100%;
    border-radius: 50%;
    border: 4px solid transparent;
}

.timing-peak {
    border-top-color: var(--accent-coral);
    border-right-color: var(--accent-coral);
    transform: rotate(-45deg);
}

.timing-completion {
    border-bottom-color: var(--text-light);
    border-left-color: var(--text-light);
    transform: rotate(135deg);
}

.timing-center {
    text-align: center;
    z-index: 1;
}

.timing-time {
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--text-dark);
    margin-bottom: 0.25rem;
}

.timing-timezone {
    font-size: 0.75rem;
    color: var(--text-muted);
}

.timing-legend {
    display: flex;
    gap: 1rem;
}

.legend-item {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.75rem;
    color: var(--text-muted);
}

.legend-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
}

.dot-peak {
    background: var(--accent-coral);
}

.dot-completion {
    background: var(--text-light);
}

.timing-stats {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1rem;
}

.timing-stat {
    text-align: center;
    padding: 1rem;
    background: var(--bg-card);
    border-radius: 12px;
    box-shadow: var(--shadow-sm);
}

/* AI Widget - Soft Grey Theme */
.widget-ai {
    background: #FFFFFF;
    color: #000000;
    border: 1px solid var(--border-color);
}

.widget-ai .widget-title {
    color: #000000;
}

.ai-chat {
    display: flex;
    gap: 1rem;
    margin-bottom: 1.5rem;
}

.ai-avatar {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: var(--bg-card);
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    font-size: 1.5rem;
    box-shadow: var(--shadow-sm);
}

.ai-message {
    flex: 1;
    background: var(--bg-card);
    padding: 1rem;
    border-radius: 12px;
    box-shadow: var(--shadow-sm);
}

.ai-message p {
    margin: 0;
    color: var(--text-dark);
    font-size: 0.9rem;
    line-height: 1.5;
}

.ai-message strong {
    color: var(--primary-color);
}

.ai-actions {
    display: flex;
    gap: 0.75rem;
}

.ai-action-btn {
    flex: 1;
    padding: 0.75rem 1rem;
    background: var(--bg-card);
    border: none;
    border-radius: 12px;
    color: var(--text-dark);
    font-size: 0.875rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    box-shadow: var(--shadow-sm);
}

.ai-action-btn:hover {
    background: var(--primary-color);
    color: white;
    transform: translateY(-1px);
    box-shadow: var(--shadow-md);
}

/* Responsive */
@media (max-width: 1200px) {
    .dashboard-widgets-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 768px) {
    .dashboard-widgets-grid {
        grid-template-columns: 1fr;
    }

    .widget-metrics,
    .campaigns-summary,
    .timing-stats {
        grid-template-columns: 1fr;
    }

    .capacity-indicators {
        flex-wrap: wrap;
    }
}

