/* Dark creative-dashboard base for home2 */
:root { 
  --accent-start: #7928CA; 
  --accent-end: #FF0080; 
  --panel-bg: #0d0e22; 
  --panel-border: #2b2f4a; 
  --text-soft: #a0aec0; 
}

#page {
  height: auto !important;
  min-height: 100% !important;
  background: #24243e !important;
  background-attachment: fixed !important;
}

/* Most used app widget styling */
#mostUsedApp {
  word-break: break-word;
  font-size: 1rem !important;
}

/* Main panel styling */
.main-panel {
  background: var(--panel-bg);
  border: 1px solid var(--panel-border);
  border-radius: 8px;
  overflow: hidden;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.main-panel:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(121,40,202,0.3);
}

.panel-header {
  background: rgba(30, 41, 59, 0.6);
  padding: 12px 16px;
  border-bottom: 1px solid var(--panel-border);
}

.panel-title {
  font-size: 16px;
  font-weight: 600;
  color: #ffffff;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

/* Stat cards */
.v-stat-card {
  background: var(--panel-bg);
  border: 1px solid var(--panel-border);
  border-radius: 8px;
  padding: 16px;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
  height: 100%;
}

.v-stat-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(121,40,202,0.2);
}

.v-stat-value {
  font-size: 1.5rem;
  font-weight: 700;
  color: #ffffff;
  margin-bottom: 8px;
}

.v-stat-label {
  font-size: 0.75rem;
  color: var(--text-soft);
  font-weight: 500;
  letter-spacing: 0.5px;
}

/* Widget styling */
.home2-widget { 
  padding: 12px; 
  display: flex; 
  flex-direction: column; 
  align-items: center; 
  justify-content: center; 
  text-align: center;
}

.home2-widget h2 { 
  font-weight: 600; 
  text-align: center; 
  font-size: 16px !important;
  margin-bottom: 8px;
}

/* Chart widget */
.chart-widget { 
  text-align: center;
  min-height: 300px;
}

.chart-widget h2 { 
  font-size: 24px !important; 
  margin-bottom: 10px; 
  font-weight: 600; 
}

.chart-widget canvas { 
  max-height: 380px; 
}

.home2-news-list {
  display: grid;
  gap: 14px;
}

.home2-news-item {
  border: 1px solid rgba(255, 255, 255, 0.08);
  background: linear-gradient(180deg, rgba(121, 40, 202, 0.12), rgba(13, 14, 34, 0.92));
  border-radius: 12px;
  padding: 16px;
}

.home2-news-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
  margin-bottom: 10px;
}

.home2-news-badge {
  display: inline-flex;
  align-items: center;
  padding: 4px 10px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.08);
  color: #f8fafc;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.home2-news-badge--accent {
  background: linear-gradient(90deg, var(--accent-start), var(--accent-end));
}

.home2-news-badge--important {
  background: linear-gradient(90deg, #ff7a18, #ff3b30);
  color: #fff5f5;
  box-shadow: 0 0 0 1px rgba(255, 122, 24, 0.35) inset;
}

.home2-news-badge--critical {
  background: linear-gradient(90deg, #ff1f1f, #c70000);
  color: #ffffff;
  border: 1px solid rgba(255, 120, 120, 0.7);
  box-shadow: 0 0 14px rgba(255, 31, 31, 0.7);
  transform-origin: center;
  animation: home2-news-critical-flash 0.7s steps(1, end) infinite;
}

@keyframes home2-news-critical-flash {
  0%,
  49%,
  100% {
    opacity: 1;
    transform: scale(1);
    filter: brightness(1) saturate(1);
    background: linear-gradient(90deg, #ff1f1f, #c70000);
    color: #ffffff;
    box-shadow: 0 0 10px rgba(255, 31, 31, 0.45);
  }
  50% {
    opacity: 1;
    transform: scale(1.08);
    filter: brightness(1.7) saturate(1.5);
    background: linear-gradient(90deg, #fff5f5, #ffb3b3);
    color: #8b0000;
    box-shadow: 0 0 28px rgba(255, 31, 31, 1), 0 0 40px rgba(255, 140, 140, 0.8);
  }
}

.home2-news-date {
  color: var(--text-soft);
  font-size: 0.78rem;
  margin-left: auto;
}

.home2-news-title {
  color: #ffffff;
  font-size: 2rem;
  font-weight: 700;
  margin: 0 0 8px;
}

.home2-news-body {
  color: #dbe4f0;
  font-size: 0.92rem;
  line-height: 1.6;
}

.home2-news-body p:last-child {
  margin-bottom: 0;
}

.home2-widget img {
  max-width: 120px !important; 
  max-height: 120px !important;
  margin: 0 auto;
  display: block;
}

/* Responsive adjustments */
@media (max-width: 991.98px) {
  .v-stat-value {
    font-size: 1.25rem;
  }
  
  .chart-widget {
    min-height: 250px;
  }
  
  .chart-widget canvas {
    max-height: 300px;
  }
}

@media (max-width: 767.98px) {
  .v-stat-value {
    font-size: 1.1rem;
  }
  
  .v-stat-label {
    font-size: 0.7rem;
  }
  
  .panel-title {
    font-size: 14px;
  }
  
  .chart-widget {
    min-height: 200px;
  }

  .home2-news-date {
    margin-left: 0;
    width: 100%;
  }
}

/* Scrollbar styling for dark theme */
::-webkit-scrollbar {
  width: 8px;
  height: 8px;
}

::-webkit-scrollbar-track {
  background: #0b1020;
}

::-webkit-scrollbar-thumb {
  background: var(--panel-border);
  border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
  background: var(--accent-start);
}

/* Ensure text is readable */
.text-light {
  color: #e2e8f0 !important;
}

/* Add subtle glow effect to panels */
.main-panel::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(121,40,202,0.5), transparent);
  opacity: 0;
  transition: opacity 0.3s ease;
}

.main-panel:hover::before {
  opacity: 1;
}


/* Membership overrides */
.arm_current_membership_heading_main {
  display: none !important;
}