/* 
 * Financial Analytics Styles
 * Using colors from theme.json
 */

/* General Layout */
.financial-page {
    padding: 0;
    max-width: 1200px;
    margin: 0 auto;
}

.financial-header {
    width: 100%;
    padding: 20px 0;
    margin-bottom: 30px;
}

.header-content {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    padding: 0 20px;
}

.title-container h1 {
    font-size: 28px;
    font-weight: 700;
    margin: 0 0 5px 0;
    color: var(--color-dark);
}

.subtitle {
    font-size: 14px;
    color: #666;
    margin: 0;
}

.header-controls {
    display: flex;
    align-items: center;
    gap: 15px;
}

.period-selector select {
    padding: 10px 15px;
    border: 1px solid var(--color-border);
    border-radius: 8px;
    font-family: 'Poppins', sans-serif;
    font-size: 14px;
    min-width: 120px;
    background-color: var(--color-white);
}

.export-button {
    background-color: var(--color-purple); /* Purple from theme */
    color: var(--color-white);
    border: none;
    border-radius: 8px;
    padding: 10px 15px;
    font-family: 'Poppins', sans-serif;
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 8px;
}

.download-icon {
    font-weight: bold;
}

/* Analytics Container */
.analytics-container {
    padding: 0 20px;
    width: 100%;
    box-sizing: border-box;
}

/* Metrics Section */
.metrics-section {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 20px;
    margin-bottom: 40px;
}

.metric-card {
    background-color: var(--color-white);
    border-radius: 10px;
    padding: 20px;
    box-shadow: var(--shadow-md);
}

.metric-card h3 {
    font-size: 14px;
    font-weight: 500;
    color: #666;
    margin: 0 0 10px 0;
}

.metric-value {
    font-size: 24px;
    font-weight: 700;
    color: #121212;
    margin-bottom: 10px;
}

.per-performance {
    font-size: 14px;
    font-weight: 400;
    color: #666;
    margin-left: 5px;
}

.metric-change {
    font-size: 14px;
    display: flex;
    align-items: center;
    gap: 5px;
}

.metric-change.positive {
    color: var(--color-success); /* Green */
}

.metric-change.negative {
    color: var(--color-danger); /* Red */
}

.metric-detail {
    font-size: 14px;
    color: #666;
}

/* Revenue Section */
.revenue-section {
    background-color: white;
    border-radius: 10px;
    padding: 20px;
    margin-bottom: 40px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
}

.section-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
}

.section-header h2 {
    font-size: 18px;
    font-weight: 600;
    color: #121212;
    margin: 0;
}

.view-options {
    display: flex;
    border: 1px solid #E5E7EB;
    border-radius: 6px;
    overflow: hidden;
}

.view-option {
    padding: 6px 12px;
    background: none;
    border: none;
    font-family: 'Poppins', sans-serif;
    font-size: 14px;
    cursor: pointer;
}

.view-option.active {
    background-color: var(--color-purple); /* Purple */
    color: white;
}

.chart-container {
    height: 300px;
    margin-bottom: 15px;
}

.chart-legend {
    display: flex;
    justify-content: center;
    gap: 20px;
}

.legend-item {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 14px;
}

.legend-color {
    width: 12px;
    height: 12px;
    border-radius: 2px;
}

.legend-color.base-revenue {
    background-color: var(--color-purple); /* Purple */
}

.legend-color.tips-revenue {
    background-color: var(--color-green); /* Green */
}

/* Performers Section */
.performers-section {
    background-color: white;
    border-radius: 10px;
    padding: 20px;
    margin-bottom: 40px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
}

.view-all {
    font-size: 14px;
    color: var(--color-purple); /* Purple */
    text-decoration: none;
}

.performers-table {
    width: 100%;
    overflow-x: auto;
}

table {
    width: 100%;
    border-collapse: collapse;
}

th {
    text-align: left;
    padding: 12px 15px;
    border-bottom: 1px solid #E5E7EB;
    font-size: 12px;
    font-weight: 600;
    color: #666;
}

td {
    padding: 15px;
    border-bottom: 1px solid #E5E7EB;
    font-size: 14px;
}

.performer-info {
    display: flex;
    align-items: center;
    gap: 10px;
}

.performer-avatar {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    object-fit: cover;
}

.performer-name {
    font-weight: 500;
}

/* Footer */
footer {
    margin-top: 40px;
    padding: 20px;
    text-align: center;
}

.navigation-links {
    display: flex;
    justify-content: center;
    gap: 20px;
    margin-bottom: 15px;
}

.nav-link {
    color: #6b46c1; /* Purple */
    text-decoration: none;
    font-weight: 500;
}

/* Responsive Design */
@media screen and (max-width: 768px) {
    .header-content {
        flex-direction: column;
        gap: 15px;
    }
    
    .header-controls {
        width: 100%;
        justify-content: space-between;
    }
    
    .metrics-section {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media screen and (max-width: 480px) {
    .metrics-section {
        grid-template-columns: 1fr;
    }
    
    .header-controls {
        flex-direction: column;
        align-items: flex-start;
    }
    
    .period-selector, .export-button {
        width: 100%;
    }
    
    .period-selector select {
        width: 100%;
    }
}