/* Google Fonts */
@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700&family=Outfit:wght@400;500;600;700;800;900&display=swap');

/* Color Variables */
:root {
  --bg-primary: #030712;
  --bg-secondary: #0b1528;
  --bg-card: rgba(13, 24, 48, 0.45);
  --border-color: rgba(99, 143, 255, 0.15);
  --border-hover: rgba(0, 242, 254, 0.45);
  
  --text-main: #f8fafc;
  --text-muted: #94a3b8;
  
  --neon-cyan: #00f2fe;
  --neon-blue: #3b82f6;
  --neon-purple: #9b51e0;
  --neon-emerald: #10b981;
  --neon-amber: #f59e0b;
  --neon-rose: #f43f5e;
}

/* Base Reset & Typography */
* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  background-color: var(--bg-primary);
  background-image: 
    radial-gradient(at 10% 20%, rgba(59, 130, 246, 0.08) 0px, transparent 50%),
    radial-gradient(at 90% 10%, rgba(155, 81, 224, 0.08) 0px, transparent 50%),
    radial-gradient(at 50% 80%, rgba(0, 242, 254, 0.05) 0px, transparent 50%);
  color: var(--text-main);
  min-height: 100vh;
  overflow-x: hidden;
}

h1, h2, h3, h4, h5, h6, .font-heading {
  font-family: 'Outfit', sans-serif;
  letter-spacing: -0.02em;
}

/* Scrollbar Customization */
::-webkit-scrollbar {
  width: 8px;
}
::-webkit-scrollbar-track {
  background: var(--bg-primary);
}
::-webkit-scrollbar-thumb {
  background: rgba(255, 255, 255, 0.1);
  border-radius: 4px;
}
::-webkit-scrollbar-thumb:hover {
  background: rgba(255, 255, 255, 0.2);
}

/* Glassmorphism Classes */
.glass-panel {
  background: var(--bg-card) !important;
  backdrop-filter: blur(12px) saturate(140%) !important;
  -webkit-backdrop-filter: blur(12px) saturate(140%) !important;
  border: 1px solid var(--border-color) !important;
  border-radius: 20px !important;
  box-shadow: 0 8px 32px 0 rgba(0, 0, 0, 0.3) !important;
}

/* Main Layout Structure */
.main-content {
  min-height: 100vh;
  padding-bottom: 2rem;
  transition: margin-left 0.3s ease;
}

@media (min-width: 992px) {
  .main-content {
    margin-left: 280px; /* Width of the sidebar */
  }
}

/* Sleek Off-Canvas Sidebar */
.offcanvas-lg {
  width: 280px;
  background: rgba(4, 9, 20, 0.85) !important;
  backdrop-filter: blur(15px);
  -webkit-backdrop-filter: blur(15px);
  border-right: 1px solid var(--border-color) !important;
  z-index: 1045;
}

.offcanvas-lg .nav-link {
  font-family: 'Outfit', sans-serif;
  font-weight: 500;
  color: var(--text-muted) !important;
  border-radius: 12px;
  padding: 10px 16px;
  margin-bottom: 8px;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  display: flex;
  align-items: center;
  gap: 12px;
  border: 1px solid transparent;
}

.offcanvas-lg .nav-link i {
  font-size: 1.25rem;
  transition: transform 0.3s ease;
}

.offcanvas-lg .nav-link:hover {
  color: var(--neon-cyan) !important;
  background: rgba(0, 242, 254, 0.06) !important;
  border-color: rgba(0, 242, 254, 0.15);
  transform: translateX(4px);
}

.offcanvas-lg .nav-link:hover i {
  transform: scale(1.15);
}

/* Top mobile navbar */
.navbar {
  background: rgba(4, 9, 20, 0.8) !important;
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--border-color) !important;
  padding: 12px 20px;
}

/* Premium Greeting & Header */
.dashboard-header {
  margin-bottom: 2.5rem;
}

.greeting-text {
  font-weight: 800;
  background: linear-gradient(135deg, #fff 40%, var(--text-muted));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.live-badge {
  font-family: 'Outfit', sans-serif;
  font-size: 0.75rem;
  font-weight: 600;
  background: rgba(16, 185, 129, 0.08);
  border: 1px solid rgba(16, 185, 129, 0.2);
  color: var(--neon-emerald);
  padding: 4px 10px;
  border-radius: 50px;
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.live-dot-pulse {
  width: 6px;
  height: 6px;
  background-color: var(--neon-emerald);
  border-radius: 50%;
  box-shadow: 0 0 0 0 rgba(16, 185, 129, 0.7);
  animation: pulse-green 2s infinite;
}

@keyframes pulse-green {
  0% {
    transform: scale(0.95);
    box-shadow: 0 0 0 0 rgba(16, 185, 129, 0.7);
  }
  70% {
    transform: scale(1);
    box-shadow: 0 0 0 6px rgba(16, 185, 129, 0);
  }
  100% {
    transform: scale(0.95);
    box-shadow: 0 0 0 0 rgba(16, 185, 129, 0);
  }
}

/* Clock and Widgets Panel */
.widgets-row {
  margin-bottom: 2.5rem;
}

.clock-card {
  padding: 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.clock-time {
  font-size: 2.25rem;
  font-weight: 800;
  font-family: 'Outfit', sans-serif;
  background: linear-gradient(90deg, var(--neon-cyan), var(--neon-blue));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  line-height: 1;
}

.clock-date {
  font-size: 0.85rem;
  color: var(--text-muted);
  margin-top: 4px;
}

.stat-widget {
  padding: 20px 24px;
  display: flex;
  align-items: center;
  gap: 16px;
}

.stat-icon {
  width: 48px;
  height: 48px;
  border-radius: 12px;
  background: rgba(59, 130, 246, 0.08);
  border: 1px solid rgba(59, 130, 246, 0.15);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.5rem;
}

.stat-icon.cyan {
  background: rgba(0, 242, 254, 0.08);
  border-color: rgba(0, 242, 254, 0.15);
  color: var(--neon-cyan);
}

.stat-icon.purple {
  background: rgba(155, 81, 224, 0.08);
  border-color: rgba(155, 81, 224, 0.15);
  color: var(--neon-purple);
}

/* Interactive Service Cards Grid */
.services-section-title {
  font-weight: 800;
  margin-bottom: 1.5rem;
  font-size: 1.5rem;
  position: relative;
  display: inline-block;
}

.services-section-title::after {
  content: '';
  position: absolute;
  left: 0;
  bottom: -4px;
  width: 40px;
  height: 3px;
  background: linear-gradient(90deg, var(--neon-cyan), var(--neon-blue));
  border-radius: 2px;
}

.service-card {
  transition: all 0.4s cubic-bezier(0.16, 1, 0.3, 1);
  text-decoration: none !important;
  color: var(--text-main) !important;
  display: flex;
  flex-direction: column;
  height: 100%;
  position: relative;
  overflow: hidden;
  cursor: pointer;
}

.service-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.02) 0%, transparent 100%);
  z-index: 1;
}

.service-card-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  margin-bottom: 1.5rem;
  z-index: 2;
}

.service-icon-wrapper {
  width: 56px;
  height: 56px;
  border-radius: 16px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.75rem;
  transition: all 0.4s ease;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.08);
}

/* Custom coloring for icons */
.service-card[data-service="immich"] .service-icon-wrapper {
  color: var(--neon-amber);
  background: rgba(245, 158, 11, 0.08);
  border-color: rgba(245, 158, 11, 0.2);
  box-shadow: 0 0 15px rgba(245, 158, 11, 0.05);
}

.service-card[data-service="timesheet"] .service-icon-wrapper {
  color: var(--neon-cyan);
  background: rgba(0, 242, 254, 0.08);
  border-color: rgba(0, 242, 254, 0.2);
  box-shadow: 0 0 15px rgba(0, 242, 254, 0.05);
}

.service-card[data-service="canon"] .service-icon-wrapper {
  color: var(--neon-rose);
  background: rgba(244, 63, 94, 0.08);
  border-color: rgba(244, 63, 94, 0.2);
  box-shadow: 0 0 15px rgba(244, 63, 94, 0.05);
}

.service-card-body {
  flex-grow: 1;
  z-index: 2;
}

.service-name {
  font-size: 1.25rem;
  font-weight: 700;
  margin-bottom: 0.5rem;
  letter-spacing: -0.01em;
}

.service-desc {
  color: var(--text-muted);
  font-size: 0.9rem;
  line-height: 1.5;
  margin-bottom: 1.5rem;
}

.service-card-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-top: 1px solid rgba(255, 255, 255, 0.05);
  padding-top: 1rem;
  z-index: 2;
  color: var(--text-muted);
  font-size: 0.8rem;
  font-weight: 500;
  transition: color 0.3s ease;
}

.service-card-footer i {
  font-size: 1rem;
  transition: transform 0.3s ease;
}

/* Hover States for Service Cards */
.service-card:hover {
  transform: translateY(-6px);
  border-color: var(--border-hover) !important;
  box-shadow: 0 15px 40px -10px rgba(0, 242, 254, 0.18) !important;
}

.service-card:hover .service-icon-wrapper {
  transform: scale(1.1) rotate(-5deg);
}

.service-card[data-service="immich"]:hover {
  border-color: rgba(245, 158, 11, 0.4) !important;
  box-shadow: 0 15px 40px -10px rgba(245, 158, 11, 0.18) !important;
}

.service-card[data-service="timesheet"]:hover {
  border-color: rgba(0, 242, 254, 0.4) !important;
  box-shadow: 0 15px 40px -10px rgba(0, 242, 254, 0.18) !important;
}

.service-card[data-service="canon"]:hover {
  border-color: rgba(244, 63, 94, 0.4) !important;
  box-shadow: 0 15px 40px -10px rgba(244, 63, 94, 0.18) !important;
}

.service-card:hover .service-card-footer {
  color: var(--text-main);
}

.service-card:hover .service-card-footer i {
  transform: translateX(4px);
}

/* Admin Console Central Card Styling */
.admin-panel-container {
  padding: 10px;
}

/* Form Styles */
.form-control, .form-select {
  background: rgba(255, 255, 255, 0.03) !important;
  color: var(--text-main) !important;
  border: 1px solid rgba(255, 255, 255, 0.08) !important;
  border-radius: 12px !important;
  padding: 10px 14px !important;
  transition: all 0.3s ease !important;
}

.form-control:focus, .form-select:focus {
  background: rgba(255, 255, 255, 0.05) !important;
  border-color: var(--neon-cyan) !important;
  box-shadow: 0 0 15px rgba(0, 242, 254, 0.15) !important;
}

/* Button overrides for Neon Theme */
.btn {
  border-radius: 12px !important;
  font-family: 'Outfit', sans-serif !important;
  font-weight: 600 !important;
  padding: 10px 20px !important;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1) !important;
}

.btn-sm {
  padding: 6px 14px !important;
  border-radius: 8px !important;
}

.btn-primary {
  background: linear-gradient(135deg, var(--neon-cyan), var(--neon-blue)) !important;
  border: none !important;
  color: #001019 !important;
  box-shadow: 0 6px 20px -5px rgba(0, 229, 255, 0.4) !important;
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 10px 25px -5px rgba(0, 229, 255, 0.55) !important;
}

.btn-outline-warning {
  border-color: rgba(245, 158, 11, 0.4) !important;
  color: var(--neon-amber) !important;
}

.btn-outline-warning:hover {
  background: var(--neon-amber) !important;
  color: #000 !important;
  border-color: transparent !important;
}

.btn-outline-secondary {
  border-color: rgba(255, 255, 255, 0.1) !important;
  color: var(--text-muted) !important;
}

.btn-outline-secondary:hover {
  background: rgba(255, 255, 255, 0.05) !important;
  color: var(--text-main) !important;
  border-color: rgba(255, 255, 255, 0.2) !important;
}

.btn-success {
  background: var(--neon-emerald) !important;
  border: none !important;
  color: #022c22 !important;
  box-shadow: 0 6px 20px -5px rgba(16, 185, 129, 0.4) !important;
}

.btn-success:hover {
  transform: translateY(-2px);
  box-shadow: 0 10px 25px -5px rgba(16, 185, 129, 0.55) !important;
}

/* Modals glassmorphic style */
.modal-content {
  background: rgba(10, 19, 39, 0.88) !important;
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border: 1px solid var(--border-color) !important;
  border-radius: 24px !important;
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.5) !important;
}

.modal-header {
  border-bottom: 1px solid rgba(255, 255, 255, 0.05) !important;
  padding: 20px 24px !important;
}

.modal-footer {
  border-top: 1px solid rgba(255, 255, 255, 0.05) !important;
  padding: 16px 24px !important;
}

/* Nav Pills inside Admin Panel styling */
.nav-pills .nav-link {
  color: var(--text-muted) !important;
  border: 1px solid transparent !important;
  font-family: 'Outfit', sans-serif;
  font-weight: 500;
  transition: all 0.3s ease !important;
}

.nav-pills .nav-link:hover {
  color: var(--neon-cyan) !important;
  background-color: rgba(0, 242, 254, 0.06) !important;
}

.nav-pills .nav-link.active {
  background: linear-gradient(135deg, var(--neon-cyan), var(--neon-blue)) !important;
  color: #001019 !important;
  box-shadow: 0 4px 15px -3px rgba(0, 229, 255, 0.4) !important;
}

/* Active sidebar link highlight */
.nav-pills .nav-link.active-sidebar {
  color: var(--neon-cyan) !important;
  background: rgba(0, 242, 254, 0.08) !important;
  border-color: rgba(0, 242, 254, 0.15);
}

/* Service Row List Styles */
.service-row {
  transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1) !important;
  border-radius: 16px !important;
}

.service-row:hover {
  border-color: var(--border-hover) !important;
  box-shadow: 0 8px 24px 0 rgba(0, 242, 254, 0.1) !important;
  transform: translateY(-2px);
}

.service-icon-wrapper-mini {
  width: 42px;
  height: 42px;
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.25rem;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.08);
  transition: all 0.3s ease;
}

.service-row:hover .service-icon-wrapper-mini {
  transform: scale(1.1);
  border-color: rgba(0, 242, 254, 0.25);
  box-shadow: 0 0 10px rgba(0, 242, 254, 0.1);
}

.service-title-link {
  font-family: 'Outfit', sans-serif;
  font-size: 1.1rem;
  font-weight: 600;
  transition: all 0.3s ease;
}

.service-title-link:hover {
  color: var(--neon-cyan) !important;
  text-shadow: 0 0 8px rgba(0, 242, 254, 0.4);
}
