/* ============================================
   POWER PAGES CUSTOM THEME - DASHBOARD ONLY
   Primary: White | Accent: Yellow | Secondary: Grey
   ============================================ */

/* === COLOR VARIABLES === */
:root {
  /* Primary Colors */
  --color-primary: #FFFFFF;
  --color-primary-soft: #F8F9FA;
  
  /* Accent Colors (Yellow) */
  --color-accent: #F9EC00;
  --color-accent-hover: #E0D400;
  --color-accent-light: #FFF9CC;
  --color-accent-dark: #C9BD00;
  
  /* Secondary Colors (Grey Palette) */
  --color-secondary: #6C757D;
  --color-secondary-light: #ADB5BD;
  --color-secondary-dark: #495057;
  
  /* Neutral Greys */
  --color-grey-100: #F8F9FA;
  --color-grey-200: #E9ECEF;
  --color-grey-300: #DEE2E6;
  --color-grey-400: #CED4DA;
  --color-grey-500: #ADB5BD;
  --color-grey-600: #6C757D;
  --color-grey-700: #495057;
  --color-grey-800: #343A40;
  --color-grey-900: #212529;
  
  /* Text Colors */
  --color-text-primary: #212529;
  --color-text-secondary: #6C757D;
  --color-text-muted: #ADB5BD;
  --color-text-inverse: #FFFFFF;
  
  /* Shadows */
  --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.05);
  --shadow-md: 0 4px 6px rgba(0, 0, 0, 0.07);
  --shadow-lg: 0 10px 25px rgba(0, 0, 0, 0.1);
  --shadow-accent: 0 4px 14px rgba(249, 236, 0, 0.35);
  
  /* Spacing */
  --spacing-xs: 0.25rem;
  --spacing-sm: 0.5rem;
  --spacing-md: 1rem;
  --spacing-lg: 1.5rem;
  --spacing-xl: 2rem;
  --spacing-xxl: 3rem;
  
  /* Border Radius */
  --radius-sm: 4px;
  --radius-md: 8px;
  --radius-lg: 12px;
  --radius-full: 9999px;
  
  /* Transitions */
  --transition-fast: 150ms ease;
  --transition-normal: 250ms ease;
  --transition-slow: 350ms ease;
}

/* ============================================
   PAGE-SPECIFIC STYLES: DASHBOARD
   ============================================ */

/* === CONTAINER STYLES === */
.dynamic-container {
  width: calc(100% - 40px);
  max-width: 1400px;
  margin: 0 auto;
  padding: 0 20px;
}

/* === METRICS CONTAINER & CARDS === */
.metrics-container {
  margin: var(--spacing-xxl) auto;
  max-width: 1200px;
}

.metric-card {
  background: var(--color-primary);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-sm);
  padding: 25px;
  text-align: center;
  height: 100%;
  cursor: pointer;
  transition: all var(--transition-normal);
  position: relative;
  overflow: hidden;
  border: 1px solid var(--color-grey-200);
}

.metric-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: linear-gradient(135deg, var(--color-accent-light), rgba(249, 236, 0, 0.05));
  opacity: 0;
  transition: opacity var(--transition-normal);
}

.metric-card:hover {
  transform: translateY(-5px);
  box-shadow: var(--shadow-lg);
}

.metric-card:hover::before {
  opacity: 1;
}

.metric-card.clickable {
  cursor: pointer;
}

.metric-card.clickable:active {
  transform: translateY(-3px);
}

.metric-card.active {
  border: 2px solid var(--color-accent);
  box-shadow: var(--shadow-accent);
}

.metric-card.active::before {
  opacity: 1;
}

.metric-value {
  font-size: 2.5rem;
  font-weight: bold;
  color: var(--color-grey-900);
  margin: 10px 0;
  position: relative;
}

.metric-label {
  font-size: 1rem;
  color: var(--color-text-secondary);
  text-transform: uppercase;
  letter-spacing: 0.5px;
  position: relative;
}

.metric-icon {
  font-size: 2rem;
  color: #000000;
  margin-bottom: 10px;
  position: relative;
}

/* === ACTIONS CONTAINER & BAR === */
.actions-container {
  margin: var(--spacing-xxl) auto;
  max-width: 1200px;
}

.actions-bar {
  background: linear-gradient(135deg, var(--color-grey-800) 0%, var(--color-grey-900) 100%);
  border-radius: var(--radius-md);
  padding: 25px;
  box-shadow: var(--shadow-md);
}

.actions-bar h3 {
  color: var(--color-primary);
  margin: 0 0 20px 0;
  font-size: 1.3rem;
  font-weight: 600;
}

.action-buttons {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 10px;
}

.action-btn {
  background: var(--color-accent);
  color: var(--color-grey-900);
  border: none;
  border-radius: var(--radius-md);
  padding: 12px 24px;
  font-size: 1rem;
  font-weight: 600;
  cursor: pointer;
  transition: all var(--transition-fast);
  display: inline-flex;
  align-items: center;
  gap: 8px;
  text-decoration: none;
  box-shadow: var(--shadow-sm);
}

.action-btn:hover {
  background: var(--color-accent-hover);
  transform: translateY(-2px);
  box-shadow: var(--shadow-accent);
  color: var(--color-grey-900);
  text-decoration: none;
}

.action-btn:active {
  transform: translateY(0);
}

.action-btn i {
  font-size: 1.1rem;
}

/* === TAB NAVIGATION === */
.tab-navigation {
  background: var(--color-primary);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-sm);
  margin-bottom: var(--spacing-xxl);
  overflow: hidden;
  border: 1px solid var(--color-grey-200);
}

.tab-bar {
  display: flex;
  border-bottom: 2px solid var(--color-grey-200);
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
}

.tab-item {
  flex: 1;
  min-width: 120px;
  padding: 15px 20px;
  text-align: center;
  cursor: pointer;
  transition: all var(--transition-fast);
  border-bottom: 3px solid transparent;
  font-weight: 500;
  color: var(--color-text-secondary);
  background: var(--color-grey-100);
  position: relative;
}

.tab-item:hover {
  background: var(--color-grey-200);
  color: var(--color-grey-800);
}

.tab-item.active {
  background: var(--color-primary);
  color: var(--color-grey-900);
  border-bottom-color: var(--color-accent);
}

.tab-item i {
  margin-right: 8px;
  font-size: 18px;
}

.tab-badge {
  display: inline-block;
  background: var(--color-accent);
  color: var(--color-grey-900);
  border-radius: var(--radius-full);
  padding: 2px 8px;
  font-size: 12px;
  margin-left: 5px;
  font-weight: 600;
}

.tab-item.active .tab-badge {
  background: var(--color-accent-dark);
}

.tab-content {
  display: none;
  padding: 20px;
  animation: fadeIn var(--transition-normal);
}

.tab-content.active {
  display: block;
}

@keyframes fadeIn {
  from {
    opacity: 0;
    transform: translateY(10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* === ACTIVITIES CONTAINER & VIEWS === */
.activities-container {
  margin: var(--spacing-xxl) auto;
  max-width: 1200px;
}

.view-toggle {
  margin-bottom: 20px;
}

.view-toggle .btn {
  min-width: 120px;
}

#calendarView {
  background: var(--color-primary);
  padding: 20px;
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-sm);
}

#listView {
  background: var(--color-primary);
  padding: 20px;
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-sm);
}

.filter-badge {
  display: inline-block;
  background: var(--color-accent);
  color: var(--color-grey-900);
  padding: 8px 16px;
  border-radius: var(--radius-full);
  margin-bottom: 15px;
  font-weight: 500;
}

.filter-badge .clear-filter {
  margin-left: 10px;
  cursor: pointer;
  font-weight: bold;
}

/* === ENTITY LIST FILTER STYLES === */
.entitylist-filter-option-text {
  margin-bottom: 20px;
  box-shadow: var(--shadow-sm);
  border-radius: var(--radius-md);
  overflow: hidden;
}

.entitylist-filter-option-text .input-group-text {
  display: none;
}

.entitylist-filter-option-text .form-select {
  border-left: none;
  border-radius: var(--radius-md);
}

.entitylist-filter-option-text .input-group-text .fa-filter {
  font-size: 1.1rem;
}

.entitylist-filter-option-text .form-select:focus {
  outline: none;
  border-left-color: var(--color-accent);
}

.entitylist-filter-option-text .form-select:hover {
  cursor: pointer;
}

.entitylist-filter-option-text .form-select:not([value=""]) {
  font-weight: 600;
  color: var(--color-grey-900);
}

.entitylist-filter-option-group-label {
  font-size: 1rem;
  font-weight: 600;
  color: var(--color-grey-800);
  margin-bottom: 8px;
  text-transform: none;
}

/* === RESPONSIVE STYLES === */
@media (max-width: 768px) {
  .dynamic-container {
    padding: 0 10px;
  }

  .metrics-container,
  .actions-container,
  .tab-navigation {
    margin-bottom: var(--spacing-lg);
  }

  .metrics-container {
    margin-top: var(--spacing-lg);
  }

  .action-buttons {
    flex-direction: column;
  }

  .action-btn {
    width: 100%;
    justify-content: center;
  }

  .tab-item {
    font-size: 14px;
    padding: 12px 15px;
  }

  .tab-item i {
    display: block;
    margin: 0 0 5px 0;
    font-size: 20px;
  }

  .card-details-header {
    flex-direction: column;
    gap: 10px;
  }

  .entitylist-search {
    max-width: 100% !important;
  }

  /* .entitylist-search .query.form-control {
    width: calc(100% - 60px) !important;
    min-width: auto !important;
  }*/
} 

@media (min-width: 992px) {
  .metrics-container .col-lg-3 {
    flex: 0 0 20%;
    max-width: 20%;
  }
}

/* ============================================
   FOOTER STYLES
   ============================================ */

/* === MAIN FOOTER CONTAINER === */
.footer,
footer {
  background: linear-gradient(135deg, var(--color-grey-800) 0%, var(--color-grey-900) 100%);
  color: var(--color-text-inverse);
  padding: var(--spacing-xxl) 0 var(--spacing-lg) 0;
  margin-top: var(--spacing-xxl);
}

.footer-container {
  width: calc(100% - 40px);
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 20px;
}

/* === FOOTER TOP SECTION === */
.footer-top {
  display: flex;
  flex-wrap: wrap;
  gap: var(--spacing-xl);
  padding-bottom: var(--spacing-xl);
  border-bottom: 1px solid var(--color-grey-700);
}

.footer-column {
  flex: 1;
  min-width: 200px;
}

.footer-logo {
  max-width: 180px;
  margin-bottom: var(--spacing-md);
}

.footer-description {
  color: var(--color-grey-400);
  font-size: 0.95rem;
  line-height: 1.6;
  margin-bottom: var(--spacing-md);
}

/* === FOOTER HEADINGS === */
.footer-heading,
.footer h4,
.footer h5 {
  color: var(--color-primary);
  font-size: 1.1rem;
  font-weight: 600;
  margin-bottom: var(--spacing-md);
  position: relative;
  padding-bottom: var(--spacing-sm);
}

.footer-heading::after,
.footer h4::after,
.footer h5::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 40px;
  height: 3px;
  background: var(--color-accent);
  border-radius: var(--radius-full);
}

/* === FOOTER LINKS === */
.footer-links {
  list-style: none;
  padding: 0;
  margin: 0;
}

.footer-links li {
  margin-bottom: var(--spacing-sm);
}

.footer-links a,
.footer a {
  color: var(--color-grey-400);
  text-decoration: none;
  transition: all var(--transition-fast);
  display: inline-flex;
  align-items: center;
  gap: var(--spacing-xs);
}

.footer-links a:hover,
.footer a:hover {
  color: var(--color-accent);
  padding-left: var(--spacing-xs);
}

.footer-links a::before {
  content: '';
  width: 0;
  height: 2px;
  background: var(--color-accent);
  transition: width var(--transition-fast);
}

.footer-links a:hover::before {
  width: 10px;
}

/* === FOOTER CONTACT INFO === */
.footer-contact {
  list-style: none;
  padding: 0;
  margin: 0;
}

.footer-contact li {
  display: flex;
  align-items: flex-start;
  gap: var(--spacing-sm);
  margin-bottom: var(--spacing-md);
  color: var(--color-grey-400);
}

.footer-contact i {
  color: var(--color-accent);
  font-size: 1rem;
  margin-top: 3px;
  min-width: 20px;
}

.footer-contact a {
  color: var(--color-grey-400);
}

.footer-contact a:hover {
  color: var(--color-accent);
  padding-left: 0;
}

/* === SOCIAL MEDIA ICONS === */
.footer-social {
  display: flex;
  gap: var(--spacing-sm);
  margin-top: var(--spacing-md);
}

.footer-social a {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  background: var(--color-grey-700);
  border-radius: var(--radius-full);
  color: var(--color-grey-400);
  transition: all var(--transition-fast);
}

.footer-social a:hover {
  background: var(--color-accent);
  color: var(--color-grey-900);
  transform: translateY(-3px);
  box-shadow: var(--shadow-accent);
  padding-left: 0;
}

.footer-social a i {
  font-size: 1.1rem;
}

/* === FOOTER NEWSLETTER === */
.footer-newsletter {
  margin-top: var(--spacing-md);
}

.footer-newsletter .input-group {
  display: flex;
  gap: 0;
}

.footer-newsletter input[type="email"] {
  flex: 1;
  padding: 12px 16px;
  border: 1px solid var(--color-grey-700);
  border-right: none;
  border-radius: var(--radius-md) 0 0 var(--radius-md);
  background: var(--color-grey-800);
  color: var(--color-primary);
  font-size: 0.95rem;
}

.footer-newsletter input[type="email"]::placeholder {
  color: var(--color-grey-500);
}

.footer-newsletter input[type="email"]:focus {
  outline: none;
  border-color: var(--color-accent);
}

.footer-newsletter button {
  padding: 12px 20px;
  background: var(--color-accent);
  color: var(--color-grey-900);
  border: none;
  border-radius: 0 var(--radius-md) var(--radius-md) 0;
  font-weight: 600;
  cursor: pointer;
  transition: all var(--transition-fast);
}

.footer-newsletter button:hover {
  background: var(--color-accent-hover);
}

/* === FOOTER BOTTOM / COPYRIGHT === */
.footer-bottom {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: center;
  padding-top: var(--spacing-lg);
  gap: var(--spacing-md);
}

.footer-copyright {
  color: var(--color-grey-500);
  font-size: 0.9rem;
}

.footer-copyright a {
  color: var(--color-accent);
  font-weight: 500;
}

.footer-copyright a:hover {
  text-decoration: underline;
  padding-left: 0;
}

.footer-bottom-links {
  display: flex;
  gap: var(--spacing-lg);
  list-style: none;
  padding: 0;
  margin: 0;
}

.footer-bottom-links a {
  color: var(--color-grey-500);
  font-size: 0.9rem;
}

.footer-bottom-links a:hover {
  color: var(--color-accent);
  padding-left: 0;
}

/* === BACK TO TOP BUTTON === */
.back-to-top {
  position: fixed;
  bottom: 30px;
  right: 30px;
  width: 45px;
  height: 45px;
  background: var(--color-accent);
  color: var(--color-grey-900);
  border: none;
  border-radius: var(--radius-full);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: var(--shadow-md);
  transition: all var(--transition-fast);
  opacity: 0;
  visibility: hidden;
  z-index: 1000;
}

.back-to-top.visible {
  opacity: 1;
  visibility: visible;
}

.back-to-top:hover {
  background: var(--color-accent-hover);
  transform: translateY(-3px);
  box-shadow: var(--shadow-accent);
}

/* === FOOTER RESPONSIVE STYLES === */
@media (max-width: 992px) {
  .footer-top {
    gap: var(--spacing-xl);
  }

  .footer-column {
    min-width: 45%;
  }
}

@media (max-width: 768px) {
  .footer {
    padding: var(--spacing-xl) 0 var(--spacing-md) 0;
  }

  .footer-container {
    padding: 0 15px;
  }

  .footer-top {
    flex-direction: column;
    gap: var(--spacing-lg);
  }

  .footer-column {
    min-width: 100%;
  }

  .footer-bottom {
    flex-direction: column;
    text-align: center;
  }

  .footer-bottom-links {
    justify-content: center;
    flex-wrap: wrap;
    gap: var(--spacing-md);
  }

  .footer-social {
    justify-content: center;
  }

  .back-to-top {
    bottom: 20px;
    right: 20px;
    width: 40px;
    height: 40px;
  }
}

@media (max-width: 480px) {
  .footer-newsletter .input-group {
    flex-direction: column;
    gap: var(--spacing-sm);
  }

  .footer-newsletter input[type="email"] {
    border-right: 1px solid var(--color-grey-700);
    border-radius: var(--radius-md);
  }

  .footer-newsletter button {
    border-radius: var(--radius-md);
    width: 100%;
  }
}


/* ============================================
   CALENDAR VIEW TOGGLE BUTTON FIX
   Injects missing label text via CSS
   ============================================ */

/* Inject button labels */
#NavigateToToday::after {
  content: "Today";
}

#YearViewToggleButton::after {
  content: "Year";
}

#MonthViewToggleButton::after {
  content: "Month";
}

#WeekViewToggleButton::after {
  content: "Week";
}

/* Style the calendar view buttons to match theme */
.calendar-views .btn-group .btn {
  background: var(--color-grey-200);
  color: var(--color-grey-900);
  border: 1px solid var(--color-grey-300);
  font-weight: 600;
  font-size: 0.9rem;
  padding: 6px 14px;
  transition: all var(--transition-fast);
}

.calendar-views .btn-group .btn:hover {
  background: var(--color-accent);
  color: var(--color-grey-900);
  border-color: var(--color-accent-hover);
}

.calendar-views .btn-group .btn.active {
  background: var(--color-accent);
  color: var(--color-grey-900);
  border-color: var(--color-accent-dark);
  box-shadow: var(--shadow-accent);
}