/* Reset and base styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
    background-color: #f8f9fa;
    color: #333;
    line-height: 1.6;
}

/* Dashboard container */
.dashboard-container {
    max-width: 1400px;
    margin: 30px auto;
    padding: 15px;
}

/* Header styles */
.header-section{
    border-bottom: 1px solid #e9ecef;
    position: sticky;
    top: 0;
    z-index: 20;
    background: #fff;
}
.dashboard-header {
/*    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 30px;
    padding: 0px 10px 10px;
    border-bottom: 1px solid #e9ecef;*/
    display: flex;
    display: -webkit-box;
    display: -moz-box;
    display: -ms-flexbox;
    display: -webkit-flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 30px;
    padding: 10px 15px;
    
    max-width: 1400px;
    margin: 0 auto;
}

.header-left {
    display: flex;
    align-items: center;
    gap: 15px;
}

.logo img {
    max-width: 100%;
    width: 300px;
}

.dashboard-header h1 {
    font-size: 28px;
    font-weight: 600;
    color: #2c3e50;
}

.header-right {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
}

.date-selector {
    display: flex;
    flex-direction: column;
    gap: 5px;
}

.date-selector label {
    font-size: 14px;
    color: #6c757d;
    font-weight: 700;
}

.date-selector select {
    padding: 8px 12px;
    border: 1px solid #dee2e6;
    border-radius: 6px;
    background-color: white;
    font-size: 14px;
    color: #495057;
    cursor: pointer;
}

.date-selector select:focus {
    outline: none;
    border-color: #00bcd4;
    box-shadow: 0 0 0 3px rgba(0, 188, 212, 0.1);
}
.date-selector #date-range-input{
     border: 1px solid #e2e8f0;
    background: #fff;
    color: #0f172a;
    padding: 10px 12px;
    border-radius: 10px;
    cursor: pointer;
    font-weight: 600;
    font-size: 15px;
    width: 245px;
}

/* Dashboard grid */
.dashboard-grid {
    /* display: grid;
    grid-template-columns: repeat(auto-fit, minmax(400px, 1fr)); */
    display: flex;
    flex-wrap: wrap;
    gap: 25px 20px;
    justify-content: space-between;
}

/* Platform cards */
.platform-card {
    width: 32%;
    background: white;
    border-radius: 12px;
    padding: 24px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
    border: 1px solid #e9ecef;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
    height: fit-content;
}

.platform-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.12);
}

/* Platform header */
.platform-header {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 20px;
    padding-bottom: 15px;
    border-bottom: 1px solid #f1f3f4;
}

.platform-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    border-radius: 8px;
    background-color: #f8f9fa;
}

.platform-name {
    font-size: 18px;
    font-weight: 600;
    color: #2c3e50;
}

/* Metrics grid */
.metrics-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 20px;
    margin-bottom: 25px;
}

.metric {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.metric-label {
    font-size: 12px;
    color: #6c757d;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.metric-value {
    font-size: 20px;
    font-weight: 700;
    color: #2c3e50;
}

/* Chart container */
.chart-container {
    margin-top: 20px;
}

.chart-container h4 {
    font-size: 14px;
    color: #495057;
    margin-bottom: 15px;
    font-weight: 600;
}

.chart-container canvas {
    width: 100% !important;
    height: 200px !important;
}

/* Platform-specific styling */
.facebook-card .platform-icon {
    background-color: rgba(24, 119, 242, 0.1);
}

.twitter-card .platform-icon {
    background-color: rgba(29, 161, 242, 0.1);
}

.youtube-card .platform-icon {
    background-color: rgba(255, 0, 0, 0.1);
}

.instagram-card .platform-icon {
    background: linear-gradient(45deg, rgba(131, 58, 180, 0.1), rgba(253, 29, 29, 0.1), rgba(252, 176, 69, 0.1));
}

.linkedin-card .platform-icon {
    background-color: rgba(0, 119, 181, 0.1);
}

/* Responsive design */
@media (max-width: 1200px) {
    .dashboard-grid {
        grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    }
}

@media (max-width: 950px){
   .dashboard-header {
        flex-direction: column;
        gap: 20px;
        align-items: flex-start;
    }
    .platform-card{
        width: 48%;
    }
}

@media (max-width: 768px) {
    .dashboard-container {
        padding: 15px;
    }
    
    .dashboard-header h1 {
        font-size: 24px;
    }
    
    .dashboard-grid {
        grid-template-columns: 1fr;
        gap: 20px;
    }
    
    .platform-card {
        padding: 20px;
    }
    
    .metrics-grid {
        grid-template-columns: 1fr;
        gap: 15px;
    }
    
    .metric-value {
        font-size: 20px;
    }
}

@media (max-width: 530px) {
      .platform-card {
        width: 100%;
    }
}

@media (max-width: 480px) {
    .dashboard-container {
        padding: 10px;
    }
    
    .platform-card {
        padding: 16px;
    }
    
    .dashboard-header h1 {
        font-size: 20px;
    }
    
    .metric-value {
        font-size: 18px;
    }
}

/* Loading animation */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.platform-card {
    animation: fadeIn 0.6s ease-out;
}

.platform-card:nth-child(1) { animation-delay: 0.1s; }
.platform-card:nth-child(2) { animation-delay: 0.2s; }
.platform-card:nth-child(3) { animation-delay: 0.3s; }
.platform-card:nth-child(4) { animation-delay: 0.4s; }
.platform-card:nth-child(5) { animation-delay: 0.5s; }

/* Scrollbar styling */
::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: #f1f1f1;
    border-radius: 4px;
}

::-webkit-scrollbar-thumb {
    background: #c1c1c1;
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: #a8a8a8;
}

