* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    min-height: 100vh;
    padding: 20px;
}

.stats-container {
    max-width: 1400px;
    margin: 0 auto;
}

/* Password Protection */
.password-protection {
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    border-radius: 20px;
    padding: 60px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.1);
}

.password-card {
    max-width: 400px;
    margin: 0 auto;
    text-align: center;
}

.password-icon {
    font-size: 4rem;
    margin-bottom: 20px;
}

.password-title {
    font-size: 1.75rem;
    color: #333;
    margin-bottom: 12px;
    font-weight: 700;
}

.password-description {
    color: #666;
    font-size: 1rem;
    margin-bottom: 32px;
    line-height: 1.6;
}

.password-form {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.password-input {
    padding: 16px 20px;
    border: 2px solid rgba(102, 126, 234, 0.3);
    border-radius: 12px;
    font-size: 1rem;
    outline: none;
    transition: all 0.3s ease;
    background: white;
}

.password-input:focus {
    border-color: #667eea;
    box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.1);
}

.password-submit {
    padding: 16px 32px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border: none;
    border-radius: 12px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
}

.password-submit:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(102, 126, 234, 0.4);
}

.password-submit:active {
    transform: translateY(0);
}

.password-error {
    color: #e53e3e;
    font-size: 0.875rem;
    margin-top: 12px;
    padding: 12px;
    background: rgba(229, 62, 62, 0.1);
    border-radius: 8px;
    animation: shake 0.5s;
}

@keyframes shake {
    0%, 100% { transform: translateX(0); }
    25% { transform: translateX(-10px); }
    75% { transform: translateX(10px); }
}

/* Header */
.stats-header {
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    border-radius: 20px;
    padding: 24px 32px;
    margin-bottom: 24px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.1);
}

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

.back-link {
    color: #667eea;
    text-decoration: none;
    font-weight: 600;
    font-size: 1rem;
    padding: 10px 20px;
    border-radius: 12px;
    background: rgba(102, 126, 234, 0.1);
    transition: all 0.3s ease;
}

.back-link:hover {
    background: rgba(102, 126, 234, 0.2);
    transform: translateX(-4px);
}

.stats-title {
    font-size: 2rem;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    flex: 1;
    text-align: center;
}

.refresh-btn {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border: none;
    padding: 12px 24px;
    border-radius: 12px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 4px 12px rgba(102, 126, 234, 0.3);
}

.refresh-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(102, 126, 234, 0.4);
}

.refresh-btn:active {
    transform: translateY(0);
}

/* Loading State */
.loading-state {
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    border-radius: 20px;
    padding: 60px;
    text-align: center;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.1);
}

.loading-spinner {
    width: 50px;
    height: 50px;
    border: 4px solid rgba(102, 126, 234, 0.2);
    border-top-color: #667eea;
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin: 0 auto 20px;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

.loading-state p {
    color: #666;
    font-size: 1.1rem;
}

/* Error State */
.error-state {
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    border-radius: 20px;
    padding: 60px;
    text-align: center;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.1);
}

.error-icon {
    font-size: 4rem;
    margin-bottom: 20px;
}

.error-state p {
    color: #e53e3e;
    font-size: 1.1rem;
    margin-bottom: 20px;
}

.retry-btn {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border: none;
    padding: 12px 32px;
    border-radius: 12px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
}

.retry-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(102, 126, 234, 0.4);
}

/* Summary Cards */
.summary-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 20px;
    margin-bottom: 32px;
}

.summary-card {
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    border-radius: 20px;
    padding: 24px;
    display: flex;
    align-items: center;
    gap: 20px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.1);
    transition: all 0.3s ease;
}

.summary-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 12px 40px rgba(0, 0, 0, 0.15);
}

.card-icon {
    font-size: 2.5rem;
    width: 70px;
    height: 70px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, rgba(102, 126, 234, 0.1) 0%, rgba(118, 75, 162, 0.1) 100%);
    border-radius: 16px;
}

.card-content {
    flex: 1;
}

.card-label {
    color: #666;
    font-size: 0.875rem;
    margin-bottom: 8px;
    font-weight: 500;
}

.card-value {
    font-size: 2rem;
    font-weight: 700;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

/* Chart Section */
.chart-section {
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    border-radius: 20px;
    padding: 32px;
    margin-bottom: 32px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.1);
}

.section-title {
    font-size: 1.5rem;
    color: #333;
    margin-bottom: 24px;
    font-weight: 700;
}

.rating-chart {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.rating-bar-item {
    display: flex;
    align-items: center;
    gap: 16px;
}

.rating-label {
    font-size: 1rem;
    font-weight: 600;
    color: #666;
    min-width: 80px;
}

.rating-bar-container {
    flex: 1;
    height: 40px;
    background: rgba(102, 126, 234, 0.1);
    border-radius: 12px;
    overflow: hidden;
    position: relative;
}

.rating-bar-fill {
    height: 100%;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border-radius: 12px;
    transition: width 0.6s cubic-bezier(0.4, 0, 0.2, 1);
    display: flex;
    align-items: center;
    justify-content: flex-end;
    padding-right: 12px;
    color: white;
    font-weight: 600;
    font-size: 0.875rem;
}

.rating-count {
    font-size: 1rem;
    font-weight: 600;
    color: #333;
    min-width: 60px;
    text-align: right;
}

/* Feedback Section */
.feedback-section {
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    border-radius: 20px;
    padding: 32px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.1);
}

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

.filter-buttons {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
}

.filter-btn {
    padding: 8px 16px;
    border: 2px solid rgba(102, 126, 234, 0.3);
    background: white;
    border-radius: 12px;
    font-size: 0.875rem;
    font-weight: 600;
    color: #666;
    cursor: pointer;
    transition: all 0.3s ease;
}

.filter-btn:hover {
    border-color: #667eea;
    background: rgba(102, 126, 234, 0.05);
}

.filter-btn.active {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border-color: transparent;
}

.feedback-list {
    display: flex;
    flex-direction: column;
    gap: 16px;
    max-height: 800px;
    overflow-y: auto;
    padding-right: 8px;
}

.feedback-list::-webkit-scrollbar {
    width: 8px;
}

.feedback-list::-webkit-scrollbar-track {
    background: rgba(102, 126, 234, 0.1);
    border-radius: 10px;
}

.feedback-list::-webkit-scrollbar-thumb {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border-radius: 10px;
}

.feedback-item {
    background: rgba(248, 250, 252, 0.8);
    border-radius: 16px;
    padding: 20px;
    border: 2px solid rgba(102, 126, 234, 0.1);
    transition: all 0.3s ease;
}

.feedback-item:hover {
    border-color: rgba(102, 126, 234, 0.3);
    transform: translateX(4px);
}

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

.feedback-rating {
    display: flex;
    gap: 4px;
    font-size: 1.25rem;
}

.feedback-date {
    color: #999;
    font-size: 0.875rem;
}

.feedback-comment {
    color: #333;
    line-height: 1.6;
    font-size: 1rem;
}

.feedback-no-comment {
    color: #999;
    font-style: italic;
}

.feedback-session {
    color: #999;
    font-size: 0.75rem;
    margin-top: 8px;
    font-family: monospace;
}

/* Empty State */
.empty-state {
    text-align: center;
    padding: 60px;
    color: #999;
}

.empty-state-icon {
    font-size: 4rem;
    margin-bottom: 20px;
}

.empty-state-text {
    font-size: 1.1rem;
}

/* Responsive */
@media (max-width: 768px) {
    body {
        padding: 12px;
    }

    .stats-header {
        padding: 20px;
    }

    .header-content {
        flex-direction: column;
    }

    .stats-title {
        font-size: 1.5rem;
    }

    .summary-grid {
        grid-template-columns: 1fr;
    }

    .chart-section,
    .feedback-section {
        padding: 20px;
    }

    .section-header {
        flex-direction: column;
        align-items: flex-start;
    }

    .filter-buttons {
        width: 100%;
        justify-content: flex-start;
    }

    .feedback-list {
        max-height: 600px;
    }
}
