/* Glassmorphism Design System */
.glass-effect {
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(15px);
    border-radius: 20px;
    border: 1px solid rgba(255, 255, 255, 0.2);
    box-shadow: 0 8px 32px 0 rgba(31, 38, 135, 0.37);
}

.scale-dashboard-container {
    display: flex;
    gap: 30px;
    max-width: 1400px;
    margin: 0 auto;
    padding: 20px;
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
}

/* Sidebar Styles */
.scale-sidebar {
    width: 320px;
    padding: 25px;
    text-align: center;
    position: sticky;
    top: 20px;
    height: fit-content;
}

.user-avatar {
    margin-bottom: 15px;
}

.user-avatar img {
    border-radius: 50%;
    border: 3px solid rgba(255, 255, 255, 0.5);
}

.scale-sidebar h3 {
    color: #fff;
    margin: 10px 0;
}

.user-email {
    color: rgba(255, 255, 255, 0.7);
    font-size: 14px;
}

/* Service Status */
.service-status {
    margin: 25px 0;
    text-align: right;
}

.service-status h4 {
    color: #fff;
    margin-bottom: 15px;
}

.status-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 10px 0;
    color: #fff;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.status-dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    display: inline-block;
}

.status-dot.whatsapp { background: #4caf50; box-shadow: 0 0 8px #4caf50; }
.status-dot.openai { background: #2196f3; box-shadow: 0 0 8px #2196f3; }
.status-dot.webhook { background: #ff9800; box-shadow: 0 0 8px #ff9800; }

/* API Key Section */
.api-key-section {
    margin-top: 25px;
}

.api-key-display {
    background: rgba(0, 0, 0, 0.3);
    padding: 10px;
    border-radius: 10px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin: 10px 0;
}

.api-key-display code {
    color: #4caf50;
    font-size: 12px;
    background: transparent;
}

.copy-btn, .regenerate-key {
    background: rgba(255, 255, 255, 0.2);
    border: none;
    padding: 5px 10px;
    border-radius: 8px;
    color: white;
    cursor: pointer;
    transition: all 0.3s;
}

.copy-btn:hover, .regenerate-key:hover {
    background: rgba(255, 255, 255, 0.3);
}

/* Main Content */
.scale-main-content {
    flex: 1;
}

/* Stats Grid */
.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 25px;
    margin-bottom: 25px;
}

.stat-card {
    padding: 25px;
    text-align: center;
    transition: transform 0.3s;
}

.stat-card:hover {
    transform: translateY(-5px);
}

.stat-icon {
    font-size: 40px;
    margin-bottom: 10px;
}

.stat-card h3 {
    color: rgba(255, 255, 255, 0.9);
    font-size: 16px;
    margin: 10px 0;
}

.stat-value {
    font-size: 32px;
    font-weight: bold;
    color: #fff;
    margin: 15px 0;
}

.quick-recharge {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border: none;
    padding: 10px 20px;
    border-radius: 25px;
    color: white;
    cursor: pointer;
    font-weight: bold;
}

/* Progress Section */
.progress-section {
    padding: 25px;
    margin-bottom: 25px;
}

.progress-section h3 {
    color: #fff;
    margin-bottom: 20px;
}

.progress-bar-container {
    background: rgba(255, 255, 255, 0.2);
    border-radius: 10px;
    overflow: hidden;
    height: 30px;
}

.progress-bar {
    background: linear-gradient(90deg, #667eea 0%, #764ba2 100%);
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-weight: bold;
    transition: width 0.5s ease;
}

.progress-stats {
    display: flex;
    justify-content: space-between;
    margin-top: 10px;
    color: rgba(255, 255, 255, 0.8);
}

/* Activity Table */
.activity-section {
    padding: 25px;
    margin-bottom: 25px;
}

.activity-section h3 {
    color: #fff;
    margin-bottom: 20px;
}

.activity-table-wrapper {
    overflow-x: auto;
}

.activity-table {
    width: 100%;
    border-collapse: collapse;
    color: #fff;
}

.activity-table th,
.activity-table td {
    padding: 12px;
    text-align: right;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.activity-table th {
    background: rgba(255, 255, 255, 0.1);
    font-weight: bold;
}

.status-badge {
    padding: 4px 12px;
    border-radius: 12px;
    font-size: 12px;
}

.status-badge.success {
    background: rgba(76, 175, 80, 0.3);
    color: #4caf50;
}

/* Quick Actions */
.quick-actions {
    display: flex;
    gap: 15px;
    flex-wrap: wrap;
}

.action-btn {
    background: rgba(255, 255, 255, 0.2);
    border: 1px solid rgba(255, 255, 255, 0.3);
    padding: 12px 24px;
    border-radius: 10px;
    color: white;
    cursor: pointer;
    transition: all 0.3s;
    font-size: 14px;
}

.action-btn:hover {
    background: rgba(255, 255, 255, 0.3);
    transform: scale(1.02);
}

/* Login Required */
.scale-login-required {
    max-width: 500px;
    margin: 100px auto;
    padding: 40px;
    text-align: center;
}

.scale-login-required h3 {
    color: #fff;
    margin-bottom: 15px;
}

.scale-login-required p {
    color: rgba(255, 255, 255, 0.8);
    margin-bottom: 25px;
}

.scale-login-btn {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    padding: 12px 30px;
    border-radius: 25px;
    color: white;
    text-decoration: none;
    display: inline-block;
}

/* Responsive */
@media (max-width: 768px) {
    .scale-dashboard-container {
        flex-direction: column;
    }
    
    .scale-sidebar {
        width: auto;
        position: static;
    }
    
    .stats-grid {
        grid-template-columns: 1fr;
    }
}

/* Animations */
@keyframes fadeIn {
    from { opacity: 0; transform: translateY(20px); }
    to { opacity: 1; transform: translateY(0); }
}

.glass-effect {
    animation: fadeIn 0.5s ease;
}