/* Dashboard Preview Section */
.dashboard-preview {
    padding: 6rem 5%;
    background: #000;
    position: relative;
    overflow: hidden;
}

/* Background effects to match image - optimized */
.dashboard-preview::before, .dashboard-preview::after {
    content: '';
    position: absolute;
    width: 300px;
    height: 300px;
    background: radial-gradient(circle, var(--accent-color) 0%, transparent 70%);
    opacity: 0.15;
    filter: blur(30px);
    z-index: 0;
    will-change: transform;
}
.dashboard-preview::before { top: 0; left: 0; }
.dashboard-preview::after { bottom: 0; right: 0; }

.dashboard-container {
    max-width: 1200px;
    margin: 0 auto;
    border: 1px solid rgba(255, 69, 0, 0.3);
    background: rgba(10, 10, 10, 0.95);
    border-radius: 4px;
    padding: 2rem;
    position: relative;
    z-index: 1;
    box-shadow: 0 0 30px rgba(255, 69, 0, 0.1);
}

.dashboard-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 1px solid rgba(255, 69, 0, 0.5);
    padding-bottom: 1rem;
    margin-bottom: 2rem;
    position: relative;
}

.dashboard-header::after {
    content: '';
    position: absolute;
    bottom: -1px;
    left: 50%;
    transform: translateX(-50%);
    width: 20%;
    height: 2px;
    background: var(--accent-color);
}

.dashboard-title {
    font-size: 1.8rem;
    letter-spacing: 1px;
    text-transform: uppercase;
    background: linear-gradient(90deg, #fff, #ddd);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
    margin: 0;
}

/* Live Indicator */
.live-indicator {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.pulse-dot {
    width: 10px;
    height: 10px;
    background: #00ff00;
    border-radius: 50%;
    animation: pulse 1.5s ease-in-out infinite;
    box-shadow: 0 0 8px #00ff00;
    will-change: opacity, transform;
}

@keyframes pulse {
    0%, 100% { opacity: 1; transform: scale3d(1, 1, 1); }
    50% { opacity: 0.5; transform: scale3d(0.8, 0.8, 1); }
}

.live-text {
    color: #888;
    font-size: 0.85rem;
}

/* Status Dots */
.status-dot {
    display: inline-block;
    width: 8px;
    height: 8px;
    background: #444;
    border-radius: 50%;
    margin-right: 0.75rem;
    vertical-align: middle;
}

.status-dot.active {
    background: #00ff00;
    box-shadow: 0 0 6px #00ff00;
}

/* Platform Icons */
.platform-icon {
    display: inline-block;
    padding: 0.25rem 0.6rem;
    border-radius: 4px;
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
}

.platform-icon.tiktok {
    background: linear-gradient(135deg, #00f2ea, #ff0050);
    color: #fff;
}

.platform-icon.instagram {
    background: linear-gradient(135deg, #833ab4, #fd1d1d, #fcb045);
    color: #fff;
}

.platform-icon.youtube {
    background: #ff0000;
    color: #fff;
}

/* Table Styles */
.data-table-container {
    margin-bottom: 2rem;
    border: 1px solid rgba(255, 255, 255, 0.1);
    background: rgba(0, 0, 0, 0.5);
}

.campaign-table {
    width: 100%;
    border-collapse: collapse;
    color: #fff;
    font-size: 0.9rem;
}

.campaign-table th {
    text-align: left;
    padding: 1rem;
    color: var(--accent-color);
    font-weight: 600;
    text-transform: uppercase;
    border-bottom: 1px solid rgba(255, 69, 0, 0.3);
    font-size: 0.8rem;
}

.campaign-table td {
    padding: 0.8rem 1rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.campaign-table tr:last-child td {
    border-bottom: none;
}

.campaign-table tbody tr {
    transition: background 0.2s ease;
}

.campaign-table tr:hover td {
    background: rgba(255, 69, 0, 0.1);
}

.progress-bar {
    width: 100px;
    height: 6px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 3px;
    display: inline-block;
    margin-right: 10px;
    vertical-align: middle;
    overflow: hidden;
}

.progress-bar .fill {
    height: 100%;
    background: linear-gradient(90deg, var(--accent-color), #ff8c00);
}

.progress-bar.glow .fill {
    box-shadow: 0 0 8px var(--accent-color);
}

/* Animated Numbers */
.count-up {
    font-variant-numeric: tabular-nums;
}

/* Chart Styles */
.chart-container {
    border: 1px solid rgba(255, 255, 255, 0.1);
    background: rgba(0, 0, 0, 0.5);
    padding: 1.5rem;
}

.chart-container h3 {
    color: var(--accent-color);
    font-size: 1rem;
    margin-bottom: 1.5rem;
    text-transform: uppercase;
}

.chart-wrapper {
    display: grid;
    grid-template-columns: auto 1fr;
    grid-template-rows: 1fr 25px;
    gap: 0;
    height: 300px;
}

.y-axis {
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    padding-right: 1rem;
    color: #888;
    font-size: 0.75rem;
    grid-row: 1;
    grid-column: 1;
}

.chart-area {
    border-left: 1px solid rgba(255, 255, 255, 0.1);
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    position: relative;
    grid-row: 1;
    grid-column: 2;
    min-height: 0;
    overflow: hidden;
}

.grid-line {
    position: absolute;
    left: 0;
    width: 100%;
    height: 1px;
    background: rgba(255, 255, 255, 0.05);
    border-top: 1px dashed rgba(255, 255, 255, 0.1);
}

.graph-line {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
}

.x-axis {
    padding-left: 0;
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    padding-top: 0.5rem;
    color: #888;
    font-size: 0.75rem;
    grid-row: 2;
    grid-column: 2;
    min-height: 20px;
}

/* Responsive adjustments */
@media (max-width: 768px) {
    .dashboard-preview {
        padding: 3rem 3%;
    }

    .dashboard-container {
        padding: 1rem;
        border-radius: 8px;
    }

    .dashboard-header {
        flex-direction: column;
        gap: 1rem;
        text-align: center;
        padding-bottom: 0.75rem;
        margin-bottom: 1.5rem;
    }

    .dashboard-header::after {
        width: 40%;
    }

    .dashboard-title {
        font-size: 1.2rem;
    }

    .live-indicator {
        justify-content: center;
    }

    .data-table-container {
        margin-bottom: 1.5rem;
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
    }

    .campaign-table {
        display: block;
        overflow-x: auto;
        min-width: 500px;
        font-size: 0.8rem;
    }

    .campaign-table th {
        padding: 0.75rem 0.5rem;
        font-size: 0.7rem;
        white-space: nowrap;
    }

    .campaign-table td {
        padding: 0.6rem 0.5rem;
        white-space: nowrap;
    }

    .progress-bar {
        width: 60px;
    }

    .platform-icon {
        padding: 0.2rem 0.4rem;
        font-size: 0.65rem;
    }

    .chart-container {
        padding: 1rem;
    }

    .chart-container h3 {
        font-size: 0.85rem;
        margin-bottom: 1rem;
    }

    .chart-wrapper {
        height: 220px;
        grid-template-columns: 50px 1fr;
        grid-template-rows: 1fr 20px;
    }

    .y-axis {
        font-size: 0.6rem;
        padding-right: 0.4rem;
    }

    .y-axis span {
        white-space: nowrap;
    }

    .x-axis {
        font-size: 0.55rem;
        padding-top: 0.3rem;
        min-height: 18px;
    }

    .x-axis span:nth-child(even) {
        display: none; /* Hide every other label on mobile */
    }
}

/* Extra small screens */
@media (max-width: 480px) {
    .dashboard-preview {
        padding: 2rem 2%;
    }

    .dashboard-container {
        padding: 0.75rem;
    }

    .dashboard-title {
        font-size: 1rem;
    }

    .live-text {
        font-size: 0.75rem;
    }

    .pulse-dot {
        width: 8px;
        height: 8px;
    }

    .campaign-table {
        font-size: 0.75rem;
    }

    .campaign-table th {
        font-size: 0.65rem;
    }

    .progress-bar {
        width: 50px;
        height: 4px;
    }

    .chart-wrapper {
        height: 180px;
        grid-template-columns: 45px 1fr;
        grid-template-rows: 1fr 18px;
    }

    .y-axis {
        font-size: 0.5rem;
        padding-right: 0.25rem;
    }

    .x-axis {
        font-size: 0.5rem;
        padding-top: 0.2rem;
    }

    /* Hide more labels on very small screens */
    .x-axis span:nth-child(3n+2),
    .x-axis span:nth-child(3n+3) {
        display: none;
    }
}
