/* 管理者ダッシュボード カスタムCSS */

body {
    display: flex;
    flex-direction: column;
    min-height: 100vh;
    background-color: #f8f9fa;
}

.main-content {
    margin-top: 56px; /* ナビバーの高さ分 */
    flex: 1 0 auto;
    padding-bottom: 2rem;
}

.footer {
    flex-shrink: 0;
}

/* ダッシュボード統計カード */
.dashboard-card {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border: none;
    border-radius: 15px;
    transition: transform 0.3s ease;
}

.dashboard-card:hover {
    transform: translateY(-5px);
}

.dashboard-card.bg-primary {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
}

.dashboard-card.bg-success {
    background: linear-gradient(135deg, #56ab2f 0%, #a8e6cf 100%);
}

.dashboard-card.bg-warning {
    background: linear-gradient(135deg, #f093fb 0%, #f5576c 100%);
}

.dashboard-card.bg-info {
    background: linear-gradient(135deg, #4facfe 0%, #00f2fe 100%);
}

.dashboard-card.bg-danger {
    background: linear-gradient(135deg, #fa709a 0%, #fee140 100%);
}

.card-icon {
    font-size: 3rem;
    opacity: 0.7;
}

/* チャートコンテナ */
.chart-container {
    position: relative;
    height: 400px;
    background: white;
    border-radius: 10px;
    padding: 20px;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
}

/* システム健康状態インジケーター */
.health-indicator {
    display: inline-flex;
    align-items: center;
    padding: 0.5rem 1rem;
    border-radius: 20px;
    font-weight: 600;
    text-transform: uppercase;
    font-size: 0.875rem;
}

.health-indicator.healthy {
    background-color: #d4edda;
    color: #155724;
}

.health-indicator.warning {
    background-color: #fff3cd;
    color: #856404;
}

.health-indicator.critical {
    background-color: #f8d7da;
    color: #721c24;
}

/* プログレスバー */
.progress-custom {
    height: 1.5rem;
    border-radius: 0.75rem;
    background-color: #e9ecef;
}

.progress-bar-custom {
    border-radius: 0.75rem;
    transition: width 0.3s ease;
}

/* データテーブル */
.table-custom {
    background: white;
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
}

.table-custom th {
    background-color: #495057;
    color: white;
    border: none;
    font-weight: 600;
}

.table-custom td {
    border: none;
    border-bottom: 1px solid #dee2e6;
}

/* ユーザーアバター */
.user-avatar {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
    color: white;
}

/* ステータスバッジ */
.status-badge {
    padding: 0.25rem 0.75rem;
    border-radius: 1rem;
    font-size: 0.875rem;
    font-weight: 600;
}

.status-active {
    background-color: #d4edda;
    color: #155724;
}

.status-inactive {
    background-color: #f8d7da;
    color: #721c24;
}

.status-pending {
    background-color: #fff3cd;
    color: #856404;
}

/* アクションボタン */
.btn-action {
    padding: 0.375rem 0.75rem;
    font-size: 0.875rem;
    border-radius: 0.375rem;
    border: none;
    transition: all 0.3s ease;
}

.btn-action:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
}

/* ローディングスピナー */
.loading-spinner {
    display: inline-block;
    width: 20px;
    height: 20px;
    border: 3px solid #f3f3f3;
    border-top: 3px solid #007bff;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* リアルタイム更新インジケーター */
.live-indicator {
    display: inline-flex;
    align-items: center;
    color: #28a745;
    font-size: 0.875rem;
}

.live-dot {
    width: 8px;
    height: 8px;
    background-color: #28a745;
    border-radius: 50%;
    margin-right: 0.5rem;
    animation: pulse 2s infinite;
}

@keyframes pulse {
    0% {
        transform: scale(0.95);
        box-shadow: 0 0 0 0 rgba(40, 167, 69, 0.7);
    }
    
    70% {
        transform: scale(1);
        box-shadow: 0 0 0 10px rgba(40, 167, 69, 0);
    }
    
    100% {
        transform: scale(0.95);
        box-shadow: 0 0 0 0 rgba(40, 167, 69, 0);
    }
}

/* レスポンシブ調整 */
@media (max-width: 768px) {
    .main-content {
        margin-top: 56px;
        padding: 1rem;
    }
    
    .chart-container {
        height: 300px;
        padding: 10px;
    }
    
    .card-icon {
        font-size: 2rem;
    }
}

/* カスタムスクロールバー */
::-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;
}

/* ダークモード対応 */
@media (prefers-color-scheme: dark) {
    body {
        background-color: #1a1a1a;
        color: #e9ecef;
    }
    
    .chart-container,
    .table-custom {
        background: #2d3748;
        color: #e9ecef;
    }
    
    .table-custom th {
        background-color: #4a5568;
    }
}
