/* Page-specific styles for React components */

/* Common page container */
.page-container,
.events-container,
.system-health-container,
.ml-dashboard-container,
.features-container,
.api-docs-container {
    padding-top: 90px;
    min-height: 100vh;
    background: linear-gradient(135deg, #0a0a0a 0%, #1a1a2e 50%, #0a0a0a 100%);
    color: #e0e0e0;
}

/* Page header */
.events-header,
.page-header {
    padding: 2rem;
    text-align: center;
    margin-bottom: 2rem;
}

.events-header h1,
.page-header h1 {
    font-size: 2.5rem;
    font-weight: 700;
    background: linear-gradient(135deg, #00d4ff 0%, #7b2cbf 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    margin-bottom: 0.5rem;
}

.events-header p,
.page-header p {
    color: #888;
    font-size: 1.1rem;
}

/* Loading and error states */
.loading-spinner {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    min-height: 400px;
    color: #00d4ff;
    font-size: 1.2rem;
}

.loading-spinner::before {
    content: "";
    width: 50px;
    height: 50px;
    border: 3px solid rgba(0, 212, 255, 0.3);
    border-top-color: #00d4ff;
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin-bottom: 1rem;
}

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

.error-message {
    text-align: center;
    padding: 3rem;
    color: #ff6b6b;
}

.retry-button {
    margin-top: 1rem;
    padding: 0.75rem 1.5rem;
    background: linear-gradient(135deg, #00d4ff 0%, #7b2cbf 100%);
    border: none;
    border-radius: 8px;
    color: white;
    cursor: pointer;
    font-weight: 600;
    transition: transform 0.2s, box-shadow 0.2s;
}

.retry-button:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 20px rgba(0, 212, 255, 0.3);
}

/* Controls section */
.events-controls,
.filter-controls {
    display: flex;
    flex-wrap: wrap;
    gap: 1rem;
    padding: 0 2rem;
    margin-bottom: 2rem;
    justify-content: center;
}

.filter-group {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.filter-group label {
    font-size: 0.85rem;
    color: #888;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.filter-select,
.search-input {
    padding: 0.75rem 1rem;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 8px;
    color: #e0e0e0;
    font-size: 1rem;
    min-width: 200px;
    transition: border-color 0.2s, box-shadow 0.2s;
}

.filter-select:focus,
.search-input:focus {
    outline: none;
    border-color: #00d4ff;
    box-shadow: 0 0 10px rgba(0, 212, 255, 0.2);
}

.filter-select option {
    background: #1a1a2e;
    color: #e0e0e0;
}

/* Stats grid */
.events-stats,
.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1.5rem;
    padding: 0 2rem;
    margin-bottom: 2rem;
    max-width: 1200px;
    margin-left: auto;
    margin-right: auto;
}

.stat-card {
    background: rgba(255, 255, 255, 0.05);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 12px;
    padding: 1.5rem;
    text-align: center;
    transition: transform 0.2s, box-shadow 0.2s;
}

.stat-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 10px 30px rgba(0, 212, 255, 0.1);
}

.stat-label {
    font-size: 0.85rem;
    color: #888;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 0.5rem;
}

.stat-value {
    font-size: 2rem;
    font-weight: 700;
    background: linear-gradient(135deg, #00d4ff 0%, #7b2cbf 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

/* Events table */
.events-table-container {
    padding: 0 2rem;
    overflow-x: auto;
    max-width: 1400px;
    margin: 0 auto;
}

.events-table {
    width: 100%;
    border-collapse: collapse;
    background: rgba(255, 255, 255, 0.02);
    border-radius: 12px;
    overflow: hidden;
}

.events-table th {
    background: rgba(0, 212, 255, 0.1);
    padding: 1rem;
    text-align: left;
    font-weight: 600;
    color: #00d4ff;
    text-transform: uppercase;
    font-size: 0.85rem;
    letter-spacing: 0.5px;
}

.events-table td {
    padding: 1rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.event-row:hover {
    background: rgba(255, 255, 255, 0.03);
}

.timestamp-cell {
    white-space: nowrap;
    font-family: monospace;
    color: #888;
}

.event-type-badge {
    display: inline-block;
    padding: 0.25rem 0.75rem;
    border-radius: 20px;
    font-size: 0.85rem;
    font-weight: 500;
    text-transform: capitalize;
}

.event-type-badge.page_view {
    background: rgba(0, 212, 255, 0.2);
    color: #00d4ff;
}

.event-type-badge.click {
    background: rgba(123, 44, 191, 0.2);
    color: #a855f7;
}

.event-type-badge.purchase {
    background: rgba(34, 197, 94, 0.2);
    color: #22c55e;
}

.event-type-badge.user_interaction {
    background: rgba(251, 191, 36, 0.2);
    color: #fbbf24;
}

.event-type-badge.system {
    background: rgba(239, 68, 68, 0.2);
    color: #ef4444;
}

.user-id {
    font-family: monospace;
    color: #a855f7;
}

.metadata-container {
    max-width: 300px;
}

.metadata-json {
    font-family: monospace;
    font-size: 0.85rem;
    color: #888;
    white-space: pre-wrap;
    word-break: break-all;
}

.no-metadata {
    color: #555;
    font-style: italic;
}

.status-indicator {
    display: inline-block;
    width: 8px;
    height: 8px;
    border-radius: 50%;
    margin-right: 0.5rem;
}

.status-indicator.online {
    background: #22c55e;
    box-shadow: 0 0 10px rgba(34, 197, 94, 0.5);
}

.status-text {
    color: #22c55e;
}

.no-events-message {
    text-align: center;
    padding: 3rem;
    color: #888;
}

/* Refresh controls */
.refresh-controls {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 1rem;
    padding: 2rem;
}

.refresh-button {
    padding: 0.75rem 1.5rem;
    background: linear-gradient(135deg, #00d4ff 0%, #7b2cbf 100%);
    border: none;
    border-radius: 8px;
    color: white;
    cursor: pointer;
    font-weight: 600;
    transition: transform 0.2s, box-shadow 0.2s;
}

.refresh-button:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 20px rgba(0, 212, 255, 0.3);
}

.last-updated {
    color: #888;
    font-size: 0.9rem;
}

/* Back link */
.back-link {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    color: #00d4ff;
    padding: 0.5rem 1rem;
    margin: 1rem 2rem;
    transition: transform 0.2s;
}

.back-link:hover {
    transform: translateX(-5px);
}

/* Responsive */
@media (max-width: 768px) {
    .events-header h1,
    .page-header h1 {
        font-size: 1.8rem;
    }
    
    .events-controls,
    .filter-controls {
        flex-direction: column;
        align-items: stretch;
    }
    
    .filter-select,
    .search-input {
        width: 100%;
    }
    
    .events-table {
        font-size: 0.9rem;
    }
    
    .events-table th,
    .events-table td {
        padding: 0.75rem 0.5rem;
    }
}

/* Chart containers */
.chart-container {
    background: rgba(26, 26, 46, 0.5);
    border-radius: 12px;
    padding: 1.5rem;
    margin-bottom: 2rem;
    border: 1px solid rgba(0, 212, 255, 0.1);
    backdrop-filter: blur(10px);
}

.chart-container h3 {
    color: #00d4ff;
    margin-bottom: 1rem;
    font-size: 1.2rem;
}

/* Progress bars */
.progress-bar {
    width: 100%;
    height: 8px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 4px;
    overflow: hidden;
    margin: 0.5rem 0;
}

.progress-bar-fill {
    height: 100%;
    background: linear-gradient(90deg, #00d4ff 0%, #7b2cbf 100%);
    border-radius: 4px;
    transition: width 1s ease;
    animation: progressAnimation 2s ease-out;
}

@keyframes progressAnimation {
    from { width: 0; }
}

/* Skills section */
.skills-section {
    padding: 2rem;
    background: rgba(26, 26, 46, 0.3);
    border-radius: 12px;
    margin: 2rem auto;
    max-width: 1200px;
}

.skills-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
    margin-top: 2rem;
}

.skill-item {
    padding: 1rem;
    background: rgba(0, 0, 0, 0.3);
    border-radius: 8px;
    border: 1px solid rgba(0, 212, 255, 0.1);
}

.skill-header {
    display: flex;
    justify-content: space-between;
    margin-bottom: 0.5rem;
}

.skill-name {
    color: #e0e0e0;
    font-weight: 500;
}

.skill-percentage {
    color: #00d4ff;
    font-weight: 600;
}

/* Profile photo */
.profile-photo {
    width: 200px;
    height: 200px;
    border-radius: 50%;
    object-fit: cover;
    border: 4px solid #00d4ff;
    box-shadow: 0 0 30px rgba(0, 212, 255, 0.5);
    margin: 0 auto;
    display: block;
}

/* Dashboard metrics */
.metrics-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 1.5rem;
    margin-bottom: 2rem;
}

.metric-card {
    background: rgba(26, 26, 46, 0.5);
    border-radius: 12px;
    padding: 1.5rem;
    border: 1px solid rgba(0, 212, 255, 0.1);
    backdrop-filter: blur(10px);
    transition: transform 0.3s, box-shadow 0.3s;
}

.metric-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 30px rgba(0, 212, 255, 0.2);
}

.metric-value {
    font-size: 2rem;
    font-weight: 700;
    color: #00d4ff;
    margin-bottom: 0.5rem;
}

.metric-label {
    color: #888;
    font-size: 0.9rem;
    text-transform: uppercase;
}

.metric-change {
    margin-top: 0.5rem;
    font-size: 0.85rem;
}

.metric-change.positive {
    color: #4ade80;
}

.metric-change.negative {
    color: #f87171;
}

/* Recharts customization */
.recharts-wrapper {
    width: 100% !important;
    height: auto !important;
}

.recharts-surface {
    overflow: visible;
}

.recharts-cartesian-axis-tick-value {
    fill: #888;
    font-size: 0.85rem;
}

.recharts-legend-wrapper {
    padding-top: 10px;
}

.recharts-legend-item-text {
    color: #888 !important;
}

.recharts-tooltip-wrapper {
    background: rgba(0, 0, 0, 0.9) !important;
    border: 1px solid rgba(0, 212, 255, 0.3) !important;
    border-radius: 8px !important;
    padding: 10px !important;
}

.recharts-default-tooltip {
    background: rgba(0, 0, 0, 0.9) !important;
    border: 1px solid rgba(0, 212, 255, 0.3) !important;
    border-radius: 8px !important;
}

.recharts-tooltip-label {
    color: #00d4ff !important;
    font-weight: 600 !important;
    margin-bottom: 5px !important;
}

.recharts-tooltip-item {
    color: #e0e0e0 !important;
}
EOF'

/* API Docs Specific Styles */
.api-docs-container {
    padding-top: 90px !important;
    min-height: 100vh !important;
    background: linear-gradient(135deg, #0a0a0a 0%, #1a1a2e 50%, #0a0a0a 100%) !important;
    color: #e0e0e0 !important;
}

.docs-content {
    max-width: 1200px;
    margin: 0 auto;
    padding: 2rem;
}

.api-section {
    margin-bottom: 3rem;
}

.api-section h2 {
    color: #00d4ff;
    font-size: 1.8rem;
    margin-bottom: 1.5rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.endpoint-card {
    background: rgba(26, 26, 46, 0.5);
    border: 1px solid rgba(0, 212, 255, 0.1);
    border-radius: 12px;
    margin-bottom: 1.5rem;
    overflow: hidden;
    backdrop-filter: blur(10px);
    transition: transform 0.3s, box-shadow 0.3s;
}

.endpoint-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 30px rgba(0, 212, 255, 0.15);
}

.endpoint-header {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 1.5rem;
    background: rgba(0, 0, 0, 0.3);
    border-bottom: 1px solid rgba(0, 212, 255, 0.1);
}

.method {
    padding: 0.25rem 0.75rem;
    border-radius: 6px;
    font-weight: 700;
    font-size: 0.85rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.method.get {
    background: linear-gradient(135deg, #10b981 0%, #059669 100%);
    color: white;
}

.method.post {
    background: linear-gradient(135deg, #3b82f6 0%, #2563eb 100%);
    color: white;
}

.method.put {
    background: linear-gradient(135deg, #f59e0b 0%, #d97706 100%);
    color: white;
}

.method.delete {
    background: linear-gradient(135deg, #ef4444 0%, #dc2626 100%);
    color: white;
}

.endpoint-url {
    font-family: 'Monaco', 'Courier New', monospace;
    font-size: 1rem;
    color: #00d4ff;
    background: rgba(0, 212, 255, 0.05);
    padding: 0.25rem 0.5rem;
    border-radius: 4px;
}

.endpoint-body {
    padding: 1.5rem;
}

.endpoint-description {
    color: #888;
    margin-bottom: 1.5rem;
}

.parameters-table,
.response-table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 1rem;
}

.parameters-table th,
.response-table th {
    text-align: left;
    padding: 0.75rem;
    background: rgba(0, 212, 255, 0.05);
    border-bottom: 2px solid rgba(0, 212, 255, 0.2);
    color: #00d4ff;
    font-weight: 600;
}

.parameters-table td,
.response-table td {
    padding: 0.75rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.param-name,
.field-name {
    font-family: 'Monaco', 'Courier New', monospace;
    color: #7b2cbf;
    background: rgba(123, 44, 191, 0.1);
    padding: 0.125rem 0.25rem;
    border-radius: 3px;
}

.param-type,
.field-type {
    color: #10b981;
    font-size: 0.85rem;
}

.param-required {
    background: linear-gradient(135deg, #ef4444 0%, #dc2626 100%);
    color: white;
    padding: 0.125rem 0.5rem;
    border-radius: 12px;
    font-size: 0.75rem;
    font-weight: 600;
}

.code-example {
    background: #0a0a0a;
    border: 1px solid rgba(0, 212, 255, 0.1);
    border-radius: 8px;
    padding: 1rem;
    margin-top: 1rem;
    overflow-x: auto;
}

.code-example pre {
    margin: 0;
    color: #e0e0e0;
    font-family: 'Monaco', 'Courier New', monospace;
    font-size: 0.9rem;
    line-height: 1.5;
}

/* Features Viewer Specific Styles */
.features-container {
    padding-top: 90px !important;
    min-height: 100vh !important;
    background: linear-gradient(135deg, #0a0a0a 0%, #1a1a2e 50%, #0a0a0a 100%) !important;
    color: #e0e0e0 !important;
}

.features-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: 2rem;
    max-width: 1200px;
    margin: 0 auto;
    padding: 2rem;
}

.feature-card {
    background: rgba(26, 26, 46, 0.5);
    border: 1px solid rgba(0, 212, 255, 0.1);
    border-radius: 12px;
    padding: 2rem;
    backdrop-filter: blur(10px);
    transition: transform 0.3s, box-shadow 0.3s, border-color 0.3s;
    position: relative;
    overflow: hidden;
}

.feature-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: linear-gradient(90deg, #00d4ff 0%, #7b2cbf 100%);
    transform: scaleX(0);
    transition: transform 0.3s;
}

.feature-card:hover::before {
    transform: scaleX(1);
}

.feature-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 40px rgba(0, 212, 255, 0.2);
    border-color: rgba(0, 212, 255, 0.3);
}

.feature-icon {
    width: 60px;
    height: 60px;
    background: linear-gradient(135deg, #00d4ff 0%, #7b2cbf 100%);
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 1.5rem;
    font-size: 1.5rem;
    color: white;
}

.feature-title {
    font-size: 1.4rem;
    font-weight: 700;
    color: #00d4ff;
    margin-bottom: 1rem;
}

.feature-description {
    color: #888;
    line-height: 1.6;
    margin-bottom: 1.5rem;
}

.feature-stats {
    display: flex;
    gap: 1.5rem;
    padding-top: 1rem;
    border-top: 1px solid rgba(255, 255, 255, 0.05);
}

.stat {
    flex: 1;
}

.stat-value {
    font-size: 1.5rem;
    font-weight: 700;
    color: #00d4ff;
    margin-bottom: 0.25rem;
}

.stat-label {
    color: #666;
    font-size: 0.85rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.feature-actions {
    display: flex;
    gap: 1rem;
    margin-top: 1.5rem;
}

.feature-btn {
    flex: 1;
    padding: 0.75rem;
    background: linear-gradient(135deg, #00d4ff 0%, #7b2cbf 100%);
    color: white;
    border: none;
    border-radius: 8px;
    font-weight: 600;
    cursor: pointer;
    transition: transform 0.2s, box-shadow 0.2s;
}

.feature-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 20px rgba(0, 212, 255, 0.3);
}

.feature-btn.secondary {
    background: transparent;
    border: 1px solid rgba(0, 212, 255, 0.3);
    color: #00d4ff;
}

.feature-btn.secondary:hover {
    background: rgba(0, 212, 255, 0.1);
}

/* Filter controls for features */
.filter-controls {
    display: flex !important;
    gap: 1rem !important;
    justify-content: center !important;
    margin-bottom: 2rem !important;
    flex-wrap: wrap !important;
    padding: 0 2rem !important;
}

.filter-btn {
    padding: 0.5rem 1.5rem !important;
    background: rgba(26, 26, 46, 0.5) !important;
    border: 1px solid rgba(0, 212, 255, 0.2) !important;
    border-radius: 25px !important;
    color: #888 !important;
    cursor: pointer !important;
    transition: all 0.3s !important;
}

.filter-btn.active,
.filter-btn:hover {
    background: linear-gradient(135deg, #00d4ff 0%, #7b2cbf 100%) !important;
    color: white !important;
    border-color: transparent !important;
    transform: translateY(-2px) !important;
    box-shadow: 0 5px 20px rgba(0, 212, 255, 0.3) !important;
}
EOF'

/* ML Dashboard Page Specific Styles */
.ml-dashboard-container {
  padding-top: 90px !important;
  min-height: 100vh !important;
  background: linear-gradient(135deg, #0a0a0a 0%, #1a1a2e 50%, #0a0a0a 100%) !important;
}

.ml-dashboard-container h1 {
  font-size: 3rem !important;
  font-weight: 700 !important;
  background: linear-gradient(135deg, #00d4ff 0%, #0099ff 100%) !important;
  -webkit-background-clip: text !important;
  background-clip: text !important;
  -webkit-text-fill-color: transparent !important;
  margin-bottom: 3rem !important;
  text-align: center !important;
}

.metrics-grid {
  display: grid !important;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr)) !important;
  gap: 1.5rem !important;
  margin-bottom: 3rem !important;
}

.metric-card {
  background: rgba(26, 26, 46, 0.5) !important;
  border: 1px solid rgba(0, 212, 255, 0.1) !important;
  border-radius: 12px !important;
  padding: 1.5rem !important;
  backdrop-filter: blur(10px) !important;
  transition: all 0.3s ease !important;
}

.metric-card:hover {
  transform: translateY(-5px) !important;
  border-color: rgba(0, 212, 255, 0.3) !important;
  box-shadow: 0 10px 30px rgba(0, 212, 255, 0.2) !important;
}

.metric-card h3 {
  color: #8a8aa0 !important;
  font-size: 0.875rem !important;
  font-weight: 500 !important;
  margin-bottom: 0.5rem !important;
  text-transform: uppercase !important;
  letter-spacing: 0.05em !important;
}

.metric-card .metric-value {
  font-size: 2.5rem !important;
  font-weight: 700 !important;
  background: linear-gradient(135deg, #00d4ff 0%, #0099ff 100%) !important;
  -webkit-background-clip: text !important;
  background-clip: text !important;
  -webkit-text-fill-color: transparent !important;
}

.metric-card .metric-change {
  font-size: 0.875rem !important;
  margin-top: 0.5rem !important;
  display: flex !important;
  align-items: center !important;
  gap: 0.25rem !important;
}

.metric-card .metric-change.positive {
  color: #10b981 !important;
}

.metric-card .metric-change.negative {
  color: #ef4444 !important;
}

.charts-section {
  margin-top: 3rem !important;
}

.chart-container {
  background: rgba(26, 26, 46, 0.5) !important;
  border: 1px solid rgba(0, 212, 255, 0.1) !important;
  border-radius: 12px !important;
  padding: 2rem !important;
  margin-bottom: 2rem !important;
  backdrop-filter: blur(10px) !important;
}

.chart-container h2 {
  color: #ffffff !important;
  font-size: 1.5rem !important;
  font-weight: 600 !important;
  margin-bottom: 1.5rem !important;
}

.chart-wrapper {
  width: 100% !important;
  height: 400px !important;
  display: flex !important;
  justify-content: center !important;
  align-items: center !important;
}

/* Recharts Customization */
.recharts-wrapper {
  width: 100% !important;
  height: 100% !important;
}

.recharts-surface {
  width: 100% !important;
}

.recharts-cartesian-grid-horizontal line,
.recharts-cartesian-grid-vertical line {
  stroke: rgba(255, 255, 255, 0.05) !important;
}

.recharts-cartesian-axis-tick-value {
  fill: #8a8aa0 !important;
  font-size: 0.875rem !important;
}

.recharts-legend-wrapper {
  padding-top: 1rem !important;
}

.recharts-legend-item-text {
  color: #8a8aa0 !important;
  font-size: 0.875rem !important;
}

.recharts-tooltip-wrapper {
  outline: none !important;
}

.recharts-default-tooltip {
  background: rgba(10, 10, 10, 0.95) !important;
  border: 1px solid rgba(0, 212, 255, 0.2) !important;
  border-radius: 8px !important;
  padding: 0.75rem !important;
}

.recharts-tooltip-label {
  color: #ffffff !important;
  font-weight: 600 !important;
  margin-bottom: 0.5rem !important;
}

.recharts-tooltip-item {
  color: #8a8aa0 !important;
  font-size: 0.875rem !important;
}

.recharts-bar-rectangle {
  transition: all 0.3s ease !important;
}

.recharts-bar-rectangle:hover {
  filter: brightness(1.2) !important;
}

.recharts-line-curve {
  stroke-width: 2 !important;
}

.recharts-dot {
  r: 4 !important;
  transition: all 0.3s ease !important;
}

.recharts-dot:hover {
  r: 6 !important;
}

/* Performance Metrics Table */
.performance-table {
  width: 100% !important;
  margin-top: 2rem !important;
}

.performance-table table {
  width: 100% !important;
  border-collapse: separate !important;
  border-spacing: 0 0.5rem !important;
}

.performance-table th {
  background: rgba(0, 212, 255, 0.1) !important;
  color: #00d4ff !important;
  padding: 1rem !important;
  text-align: left !important;
  font-weight: 600 !important;
  text-transform: uppercase !important;
  font-size: 0.875rem !important;
  letter-spacing: 0.05em !important;
  border: 1px solid rgba(0, 212, 255, 0.2) !important;
}

.performance-table td {
  background: rgba(26, 26, 46, 0.3) !important;
  color: #ffffff !important;
  padding: 1rem !important;
  border: 1px solid rgba(0, 212, 255, 0.1) !important;
  transition: all 0.3s ease !important;
}

.performance-table tr:hover td {
  background: rgba(0, 212, 255, 0.05) !important;
  border-color: rgba(0, 212, 255, 0.2) !important;
}

/* Loading State */
.ml-dashboard-container .loading-container {
  display: flex !important;
  justify-content: center !important;
  align-items: center !important;
  min-height: 400px !important;
}

.ml-dashboard-container .loading-spinner {
  width: 50px !important;
  height: 50px !important;
  border: 3px solid rgba(0, 212, 255, 0.1) !important;
  border-top-color: #00d4ff !important;
  border-radius: 50% !important;
  animation: spin 1s linear infinite !important;
}

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

/* Responsive Design */
@media (max-width: 768px) {
  .ml-dashboard-container h1 {
    font-size: 2rem !important;
  }
  
  .metrics-grid {
    grid-template-columns: 1fr !important;
  }
  
  .chart-wrapper {
    height: 300px !important;
  }
  
  .performance-table {
    overflow-x: auto !important;
  }
}

/* System Health Page Specific Styles */
.system-health-container {
  padding-top: 90px !important;
  min-height: 100vh !important;
  background: linear-gradient(135deg, #0a0a0a 0%, #1a1a2e 50%, #0a0a0a 100%) !important;
}

.system-health-container h1 {
  font-size: 3rem !important;
  font-weight: 700 !important;
  background: linear-gradient(135deg, #00d4ff 0%, #0099ff 100%) !important;
  -webkit-background-clip: text !important;
  background-clip: text !important;
  -webkit-text-fill-color: transparent !important;
  margin-bottom: 3rem !important;
  text-align: center !important;
}

.system-health-container .metrics-grid {
  display: grid !important;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)) !important;
  gap: 1.5rem !important;
  margin-bottom: 3rem !important;
}

.system-health-container .metric-card {
  background: rgba(26, 26, 46, 0.5) !important;
  border: 1px solid rgba(0, 212, 255, 0.1) !important;
  border-radius: 12px !important;
  padding: 1.5rem !important;
  backdrop-filter: blur(10px) !important;
  transition: all 0.3s ease !important;
}

.system-health-container .metric-card:hover {
  transform: translateY(-5px) !important;
  border-color: rgba(0, 212, 255, 0.3) !important;
  box-shadow: 0 10px 30px rgba(0, 212, 255, 0.2) !important;
}

.system-health-container .chart-container {
  background: rgba(26, 26, 46, 0.5) !important;
  border: 1px solid rgba(0, 212, 255, 0.1) !important;
  border-radius: 12px !important;
  padding: 2rem !important;
  margin-bottom: 2rem !important;
  backdrop-filter: blur(10px) !important;
}

.system-health-container .chart-wrapper {
  width: 100% !important;
  height: 100% !important;
  min-height: 300px !important;
}

.system-health-container .performance-table table {
  width: 100% !important;
  background: rgba(26, 26, 46, 0.3) !important;
  border-radius: 12px !important;
  overflow: hidden !important;
}

.system-health-container .performance-table th {
  background: rgba(0, 212, 255, 0.1) !important;
  color: #00d4ff !important;
  font-weight: 600 !important;
  text-transform: uppercase !important;
  font-size: 0.875rem !important;
  letter-spacing: 0.05em !important;
}

.system-health-container .performance-table td {
  color: #ffffff !important;
  transition: all 0.3s ease !important;
}

.system-health-container .performance-table tr:hover td {
  background: rgba(0, 212, 255, 0.05) !important;
}

/* Events Viewer Page Specific Styles */
.events-viewer-container {
  padding-top: 90px !important;
  min-height: 100vh !important;
  background: linear-gradient(135deg, #0a0a0a 0%, #1a1a2e 50%, #0a0a0a 100%) !important;
}

.events-viewer-container h1 {
  font-size: 3rem !important;
  font-weight: 700 !important;
  background: linear-gradient(135deg, #00d4ff 0%, #0099ff 100%) !important;
  -webkit-background-clip: text !important;
  background-clip: text !important;
  -webkit-text-fill-color: transparent !important;
  margin-bottom: 3rem !important;
  text-align: center !important;
}

.events-viewer-container .metrics-grid {
  display: grid !important;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)) !important;
  gap: 1.5rem !important;
  margin-bottom: 3rem !important;
}

.events-viewer-container .metric-card {
  background: rgba(26, 26, 46, 0.5) !important;
  border: 1px solid rgba(0, 212, 255, 0.1) !important;
  border-radius: 12px !important;
  padding: 1.5rem !important;
  backdrop-filter: blur(10px) !important;
  transition: all 0.3s ease !important;
}

.events-viewer-container .metric-card:hover {
  transform: translateY(-5px) !important;
  border-color: rgba(0, 212, 255, 0.3) !important;
  box-shadow: 0 10px 30px rgba(0, 212, 255, 0.2) !important;
}

.events-viewer-container .metric-card h3 {
  color: #8a8aa0 !important;
  font-size: 0.875rem !important;
  font-weight: 500 !important;
  margin-bottom: 0.5rem !important;
  text-transform: uppercase !important;
  letter-spacing: 0.05em !important;
}

.events-viewer-container .metric-value {
  font-size: 2.5rem !important;
  font-weight: 700 !important;
  background: linear-gradient(135deg, #00d4ff 0%, #0099ff 100%) !important;
  -webkit-background-clip: text !important;
  background-clip: text !important;
  -webkit-text-fill-color: transparent !important;
}

.events-viewer-container .metric-change {
  font-size: 0.875rem !important;
  margin-top: 0.5rem !important;
  display: flex !important;
  align-items: center !important;
  gap: 0.25rem !important;
}

.events-viewer-container .metric-change.positive {
  color: #10b981 !important;
}

.events-viewer-container .chart-container {
  background: rgba(26, 26, 46, 0.5) !important;
  border: 1px solid rgba(0, 212, 255, 0.1) !important;
  border-radius: 12px !important;
  padding: 2rem !important;
  margin-bottom: 2rem !important;
  backdrop-filter: blur(10px) !important;
}

.events-viewer-container .chart-container h2 {
  color: #ffffff !important;
  font-size: 1.5rem !important;
  font-weight: 600 !important;
  margin-bottom: 1.5rem !important;
}

.events-viewer-container .chart-wrapper {
  width: 100% !important;
  height: 100% !important;
}

.events-viewer-container .events-table table {
  width: 100% !important;
  background: transparent !important;
}

.events-viewer-container .events-table th {
  background: rgba(0, 212, 255, 0.1) !important;
  color: #00d4ff !important;
  padding: 1rem !important;
  text-align: left !important;
  font-weight: 600 !important;
  text-transform: uppercase !important;
  font-size: 0.875rem !important;
  letter-spacing: 0.05em !important;
}

.events-viewer-container .events-table td {
  background: rgba(26, 26, 46, 0.3) !important;
  color: #ffffff !important;
  padding: 1rem !important;
  border-bottom: 1px solid rgba(0, 212, 255, 0.05) !important;
}

.events-viewer-container .events-table tr:hover td {
  background: rgba(0, 212, 255, 0.05) !important;
}

.events-viewer-container .events-controls {
  display: flex !important;
  gap: 1rem !important;
  margin-bottom: 1.5rem !important;
}

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

/* Enhanced Home Page Styles */
.home-container {
  min-height: 100vh !important;
  background: linear-gradient(135deg, #0a0a0a 0%, #1a1a2e 50%, #0a0a0a 100%) !important;
}

.hero-enhanced {
  padding: 120px 0 60px !important;
  min-height: 100vh !important;
  display: flex !important;
  align-items: center !important;
}

.hero-container {
  max-width: 1400px !important;
  margin: 0 auto !important;
  padding: 0 2rem !important;
  display: grid !important;
  grid-template-columns: 1fr 1fr !important;
  gap: 4rem !important;
  align-items: center !important;
}

.hero-title {
  font-size: 3.5rem !important;
  font-weight: 700 !important;
  line-height: 1.2 !important;
  margin-bottom: 1.5rem !important;
}

.gradient-text {
  background: linear-gradient(135deg, #00d4ff 0%, #0099ff 100%) !important;
  -webkit-background-clip: text !important;
  background-clip: text !important;
  -webkit-text-fill-color: transparent !important;
}

.hero-subtitle {
  font-size: 1.25rem !important;
  color: #8a8aa0 !important;
  margin-bottom: 2rem !important;
  line-height: 1.6 !important;
}

/* Live Metrics Grid */
.live-metrics-grid {
  display: grid !important;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)) !important;
  gap: 1.5rem !important;
  margin-bottom: 2rem !important;
}

.metric-card-live {
  background: rgba(26, 26, 46, 0.5) !important;
  border: 1px solid rgba(0, 212, 255, 0.1) !important;
  border-radius: 12px !important;
  padding: 1.5rem !important;
  display: flex !important;
  align-items: center !important;
  gap: 1rem !important;
  backdrop-filter: blur(10px) !important;
  transition: all 0.3s ease !important;
}

.metric-card-live:hover {
  transform: translateY(-5px) !important;
  border-color: rgba(0, 212, 255, 0.3) !important;
  box-shadow: 0 10px 30px rgba(0, 212, 255, 0.2) !important;
}

.metric-icon {
  font-size: 2rem !important;
  color: #00d4ff !important;
}

.metric-content {
  flex: 1 !important;
}

.metric-value {
  font-size: 1.75rem !important;
  font-weight: 700 !important;
  color: #ffffff !important;
  margin-bottom: 0.25rem !important;
}

.metric-label {
  font-size: 0.875rem !important;
  color: #8a8aa0 !important;
  text-transform: uppercase !important;
  letter-spacing: 0.05em !important;
}

.metric-progress {
  margin-top: 0.5rem !important;
  height: 4px !important;
  background: rgba(0, 212, 255, 0.1) !important;
  border-radius: 2px !important;
  overflow: hidden !important;
}

.metric-progress .progress-bar {
  background: linear-gradient(90deg, #00d4ff, #0099ff) !important;
  height: 100% !important;
  transition: width 0.3s ease !important;
}

/* Hero Visual Enhanced */
.hero-visual-enhanced {
  display: flex !important;
  flex-direction: column !important;
  gap: 2rem !important;
}

.profile-section {
  text-align: center !important;
  padding: 2rem !important;
  background: rgba(26, 26, 46, 0.5) !important;
  border-radius: 12px !important;
  border: 1px solid rgba(0, 212, 255, 0.1) !important;
  backdrop-filter: blur(10px) !important;
}

.profile-image {
  width: 150px !important;
  height: 150px !important;
  border-radius: 50% !important;
  border: 3px solid #00d4ff !important;
  box-shadow: 0 0 30px rgba(0, 212, 255, 0.3) !important;
}

.performance-chart-mini {
  background: rgba(26, 26, 46, 0.5) !important;
  border-radius: 12px !important;
  padding: 1.5rem !important;
  border: 1px solid rgba(0, 212, 255, 0.1) !important;
  backdrop-filter: blur(10px) !important;
}

/* Hero Buttons */
.hero-buttons {
  display: flex !important;
  gap: 1rem !important;
  margin-top: 2rem !important;
}

.btn {
  padding: 1rem 2rem !important;
  border-radius: 8px !important;
  font-weight: 600 !important;
  display: inline-flex !important;
  align-items: center !important;
  gap: 0.5rem !important;
  cursor: pointer !important;
  transition: all 0.3s ease !important;
  text-decoration: none !important;
}

.btn-primary {
  background: linear-gradient(135deg, #00d4ff, #0099ff) !important;
  color: #ffffff !important;
  border: none !important;
}

.btn-primary:hover {
  transform: translateY(-2px) !important;
  box-shadow: 0 10px 30px rgba(0, 212, 255, 0.3) !important;
}

.btn-secondary {
  background: transparent !important;
  color: #00d4ff !important;
  border: 2px solid #00d4ff !important;
}

.btn-secondary:hover {
  background: rgba(0, 212, 255, 0.1) !important;
  transform: translateY(-2px) !important;
}

/* Projects Section */
.projects-section {
  padding: 80px 0 !important;
}

.section-container {
  max-width: 1400px !important;
  margin: 0 auto !important;
  padding: 0 2rem !important;
}

.section-title {
  font-size: 2.5rem !important;
  font-weight: 700 !important;
  text-align: center !important;
  margin-bottom: 3rem !important;
  background: linear-gradient(135deg, #00d4ff 0%, #0099ff 100%) !important;
  -webkit-background-clip: text !important;
  background-clip: text !important;
  -webkit-text-fill-color: transparent !important;
}

.projects-grid {
  display: grid !important;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)) !important;
  gap: 2rem !important;
  margin-bottom: 4rem !important;
}

.project-card-enhanced {
  background: rgba(26, 26, 46, 0.5) !important;
  border: 1px solid rgba(0, 212, 255, 0.1) !important;
  border-radius: 12px !important;
  padding: 2rem !important;
  backdrop-filter: blur(10px) !important;
  transition: all 0.3s ease !important;
}

.project-card-enhanced:hover {
  transform: translateY(-5px) !important;
  border-color: rgba(0, 212, 255, 0.3) !important;
  box-shadow: 0 10px 30px rgba(0, 212, 255, 0.2) !important;
}

.project-card-enhanced h3 {
  color: #ffffff !important;
  margin-bottom: 1.5rem !important;
  font-size: 1.25rem !important;
}

.project-metrics {
  display: flex !important;
  flex-direction: column !important;
  gap: 1rem !important;
}

.metric-row {
  display: grid !important;
  grid-template-columns: 100px 1fr 50px !important;
  align-items: center !important;
  gap: 1rem !important;
  color: #8a8aa0 !important;
  font-size: 0.9rem !important;
}

.progress-bar {
  height: 6px !important;
  background: rgba(0, 212, 255, 0.1) !important;
  border-radius: 3px !important;
  overflow: hidden !important;
}

/* Tech Stack Section */
.tech-stack-section {
  margin-top: 3rem !important;
}

.tech-stack-section h3 {
  color: #ffffff !important;
  font-size: 1.75rem !important;
  text-align: center !important;
  margin-bottom: 2rem !important;
}

.chart-container-home {
  background: rgba(26, 26, 46, 0.5) !important;
  border: 1px solid rgba(0, 212, 255, 0.1) !important;
  border-radius: 12px !important;
  padding: 2rem !important;
  backdrop-filter: blur(10px) !important;
}

/* Skills Section */
.skills-section {
  padding: 80px 0 !important;
  background: rgba(16, 16, 30, 0.5) !important;
}

.capabilities-chart {
  background: rgba(26, 26, 46, 0.5) !important;
  border: 1px solid rgba(0, 212, 255, 0.1) !important;
  border-radius: 12px !important;
  padding: 2rem !important;
  margin-bottom: 3rem !important;
  backdrop-filter: blur(10px) !important;
}

.skills-grid {
  display: grid !important;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)) !important;
  gap: 2rem !important;
}

.skill-item {
  background: rgba(26, 26, 46, 0.5) !important;
  border: 1px solid rgba(0, 212, 255, 0.1) !important;
  border-radius: 8px !important;
  padding: 1.5rem !important;
  backdrop-filter: blur(10px) !important;
}

.skill-header {
  display: flex !important;
  justify-content: space-between !important;
  margin-bottom: 0.75rem !important;
  color: #ffffff !important;
}

.skill-name {
  font-weight: 600 !important;
}

.skill-level {
  color: #00d4ff !important;
  font-weight: 700 !important;
}

.skill-progress {
  height: 8px !important;
  background: rgba(0, 212, 255, 0.1) !important;
  border-radius: 4px !important;
  overflow: hidden !important;
}

/* Demos Section */
.demos-section {
  padding: 80px 0 !important;
}

.demos-grid {
  display: grid !important;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)) !important;
  gap: 2rem !important;
}

.demo-card {
  background: rgba(26, 26, 46, 0.5) !important;
  border: 1px solid rgba(0, 212, 255, 0.1) !important;
  border-radius: 12px !important;
  padding: 2rem !important;
  text-align: center !important;
  text-decoration: none !important;
  color: inherit !important;
  backdrop-filter: blur(10px) !important;
  transition: all 0.3s ease !important;
}

.demo-card:hover {
  transform: translateY(-5px) !important;
  border-color: rgba(0, 212, 255, 0.3) !important;
  box-shadow: 0 10px 30px rgba(0, 212, 255, 0.2) !important;
}

.demo-icon {
  font-size: 3rem !important;
  color: #00d4ff !important;
  margin-bottom: 1rem !important;
}

.demo-card h3 {
  color: #ffffff !important;
  margin-bottom: 0.75rem !important;
}

.demo-card p {
  color: #8a8aa0 !important;
  margin-bottom: 1.5rem !important;
}

.demo-status {
  display: inline-flex !important;
  align-items: center !important;
  gap: 0.5rem !important;
  color: #10b981 !important;
  font-weight: 600 !important;
}

.status-indicator {
  width: 8px !important;
  height: 8px !important;
  border-radius: 50% !important;
  background: #10b981 !important;
  animation: pulse 2s infinite !important;
}

@keyframes pulse {
  0% {
    box-shadow: 0 0 0 0 rgba(16, 185, 129, 0.4);
  }
  70% {
    box-shadow: 0 0 0 10px rgba(16, 185, 129, 0);
  }
  100% {
    box-shadow: 0 0 0 0 rgba(16, 185, 129, 0);
  }
}

/* Stats Section */
.stats-section {
  padding: 80px 0 !important;
  background: rgba(16, 16, 30, 0.5) !important;
}

.stats-grid {
  display: grid !important;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr)) !important;
  gap: 2rem !important;
}

.stat-card {
  text-align: center !important;
  padding: 2rem !important;
  background: rgba(26, 26, 46, 0.5) !important;
  border: 1px solid rgba(0, 212, 255, 0.1) !important;
  border-radius: 12px !important;
  backdrop-filter: blur(10px) !important;
  transition: all 0.3s ease !important;
}

.stat-card:hover {
  transform: translateY(-5px) !important;
  border-color: rgba(0, 212, 255, 0.3) !important;
  box-shadow: 0 10px 30px rgba(0, 212, 255, 0.2) !important;
}

.stat-icon {
  font-size: 2.5rem !important;
  color: #00d4ff !important;
  margin-bottom: 1rem !important;
}

.stat-value {
  font-size: 2.5rem !important;
  font-weight: 700 !important;
  background: linear-gradient(135deg, #00d4ff 0%, #0099ff 100%) !important;
  -webkit-background-clip: text !important;
  background-clip: text !important;
  -webkit-text-fill-color: transparent !important;
  margin-bottom: 0.5rem !important;
}

.stat-label {
  color: #8a8aa0 !important;
  font-size: 1rem !important;
  text-transform: uppercase !important;
  letter-spacing: 0.05em !important;
}

/* Responsive Design */
@media (max-width: 1024px) {
  .hero-container {
    grid-template-columns: 1fr !important;
  }
  
  .hero-visual-enhanced {
    margin-top: 3rem !important;
  }
}

@media (max-width: 768px) {
  .hero-title {
    font-size: 2.5rem !important;
  }
  
  .live-metrics-grid {
    grid-template-columns: 1fr !important;
  }
  
  .projects-grid,
  .demos-grid,
  .stats-grid {
    grid-template-columns: 1fr !important;
  }
}
