/* ========================================
   ADMIN PANEL - REDESIGNED THEME
   Color Palette:
   --dark:    #2B2C30  (near black)
   --gray:    #A3A09E  (medium gray)
   --cream:   #F0EFEA  (off-white)
   --steel:   #6E90AD  (muted blue)
   --navy:    #0A335D  (dark navy)
   --accent:  #244AC0  (bright blue - accent only)
   ======================================== */

:root {
  --dark: #2B2C30;
  --gray: #A3A09E;
  --cream: #F0EFEA;
  --steel: #6E90AD;
  --navy: #0A335D;
  --accent: #244AC0;

  /* Derived shades */
  --dark-lighter: #3a3b40;
  --gray-light: #c4c2bf;
  --cream-dark: #e4e3dd;
  --steel-light: #9bb3c8;
  --steel-dark: #567a96;
  --navy-light: #134a7a;
  --navy-dark: #072647;
  --accent-light: #3d62d4;
  --accent-dark: #1a3a9a;

  /* Semantic colors */
  --success: #2e7d5b;
  --success-bg: #dff0e8;
  --danger: #b9384b;
  --danger-bg: #f5dde1;
  --warning: #c08a24;
  --warning-bg: #faf0d6;
  --info-bg: #dce7f0;

  /* Text */
  --text-primary: #2B2C30;
  --text-secondary: #5c5d61;
  --text-muted: #A3A09E;

  /* Borders */
  --border: #d6d5d1;
  --border-light: #e4e3dd;
}

/* ========================================
   BASE STYLES
   ======================================== */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
  background: var(--cream);
  color: var(--text-primary);
  line-height: 1.6;
}

/* ========================================
   FUTURISTIC LOGIN PAGE STYLES
   ======================================== */

body.login-page {
  background: var(--dark);
  overflow: hidden;
}

#particles {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 1;
}

.gradient-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background:
    radial-gradient(ellipse at 20% 20%, rgba(10, 51, 93, 0.4) 0%, transparent 50%),
    radial-gradient(ellipse at 80% 80%, rgba(36, 74, 192, 0.15) 0%, transparent 50%),
    radial-gradient(ellipse at 50% 50%, rgba(0, 0, 0, 0.5) 0%, transparent 70%);
  z-index: 2;
  pointer-events: none;
}

body.login-page .login-container {
  position: relative;
  z-index: 10;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: flex-start;
  padding: 8vh 20px 40px;
  background: transparent;
}

/* Logo Styles */
.logo-wrapper {
  margin-bottom: 30px;
  animation: fadeInDown 1s ease;
}

.login-logo {
  max-width: 300px;
  height: auto;
  filter: drop-shadow(0 0 20px rgba(110, 144, 173, 0.4))
          drop-shadow(0 0 40px rgba(110, 144, 173, 0.2))
          drop-shadow(0 0 60px rgba(110, 144, 173, 0.1));
  transition: filter 0.3s ease, transform 0.3s ease;
  animation: logoGlow 4s ease-in-out infinite;
}

.login-logo:hover {
  filter: drop-shadow(0 0 25px rgba(110, 144, 173, 0.6))
          drop-shadow(0 0 50px rgba(110, 144, 173, 0.4))
          drop-shadow(0 0 80px rgba(110, 144, 173, 0.2));
  transform: scale(1.02);
}

@keyframes logoGlow {
  0%, 100% {
    filter: drop-shadow(0 0 20px rgba(110, 144, 173, 0.4))
            drop-shadow(0 0 40px rgba(110, 144, 173, 0.2))
            drop-shadow(0 0 60px rgba(110, 144, 173, 0.1));
  }
  50% {
    filter: drop-shadow(0 0 25px rgba(110, 144, 173, 0.5))
            drop-shadow(0 0 50px rgba(110, 144, 173, 0.3))
            drop-shadow(0 0 70px rgba(110, 144, 173, 0.15));
  }
}

/* Login Card */
body.login-page .login-card {
  position: relative;
  background: rgba(43, 44, 48, 0.8);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-radius: 24px;
  padding: 2px;
  width: 100%;
  max-width: 420px;
  box-shadow:
    0 25px 50px rgba(0, 0, 0, 0.5),
    0 0 100px rgba(110, 144, 173, 0.1);
  animation: cardAppear 0.8s ease;
  overflow: hidden;
}

/* Animated border glow */
body.login-page .login-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  border-radius: 24px;
  padding: 2px;
  background: conic-gradient(
    from var(--border-angle, 0deg),
    transparent 0%,
    transparent 85%,
    rgba(110, 144, 173, 0.8) 90%,
    rgba(110, 144, 173, 0.8) 95%,
    transparent 100%
  );
  -webkit-mask:
    linear-gradient(#fff 0 0) content-box,
    linear-gradient(#fff 0 0);
  mask:
    linear-gradient(#fff 0 0) content-box,
    linear-gradient(#fff 0 0);
  -webkit-mask-composite: xor;
  mask-composite: exclude;
  animation: rotateBorder 12s linear infinite;
  z-index: 0;
}

/* Subtle static border */
body.login-page .login-card::after {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  border-radius: 24px;
  border: 1px solid rgba(110, 144, 173, 0.15);
  z-index: 0;
  pointer-events: none;
}

@keyframes rotateBorder {
  0% { --border-angle: 0deg; transform: rotate(0deg); }
  100% { --border-angle: 360deg; transform: rotate(360deg); }
}

@property --border-angle {
  syntax: '<angle>';
  initial-value: 0deg;
  inherits: false;
}

.card-content {
  position: relative;
  z-index: 1;
  padding: 50px 40px;
  background: rgba(43, 44, 48, 0.95);
  border-radius: 24px;
}

@keyframes cardAppear {
  from {
    opacity: 0;
    transform: translateY(30px) scale(0.95);
  }
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

/* Login Title */
body.login-page .login-title {
  text-align: center;
  margin-bottom: 40px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.title-text {
  font-size: 2rem;
  font-weight: 700;
  background: linear-gradient(135deg, #fff 0%, var(--steel-light) 50%, #fff 100%);
  background-size: 200% auto;
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  animation: shimmer 3s linear infinite;
}

.title-subtitle {
  font-size: 0.9rem;
  font-weight: 400;
  color: var(--steel);
  text-transform: uppercase;
  letter-spacing: 3px;
}

@keyframes shimmer {
  0% { background-position: -200% center; }
  100% { background-position: 200% center; }
}

/* Form Styles */
body.login-page .login-form .form-group {
  margin-bottom: 25px;
  position: relative;
}

body.login-page .login-form label {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 10px;
  font-weight: 500;
  color: rgba(255, 255, 255, 0.8);
  font-size: 0.9rem;
  text-transform: uppercase;
  letter-spacing: 1px;
}

body.login-page .login-form label svg {
  color: var(--steel);
  opacity: 0.8;
}

body.login-page .login-form .form-input {
  width: 100%;
  padding: 16px 20px;
  font-size: 1rem;
  background: rgba(255, 255, 255, 0.05);
  border: 2px solid rgba(110, 144, 173, 0.2);
  border-radius: 12px;
  color: #fff;
  transition: all 0.3s ease;
}

body.login-page .login-form .form-input::placeholder {
  color: rgba(255, 255, 255, 0.3);
}

body.login-page .login-form .form-input:focus {
  outline: none;
  border-color: var(--accent);
  background: rgba(36, 74, 192, 0.08);
  box-shadow:
    0 0 0 4px rgba(36, 74, 192, 0.1),
    0 0 30px rgba(36, 74, 192, 0.15);
}

.input-glow {
  position: absolute;
  bottom: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 0;
  height: 2px;
  background: linear-gradient(90deg, transparent, var(--accent), transparent);
  transition: width 0.3s ease;
  border-radius: 2px;
}

.form-group.focused .input-glow {
  width: 80%;
}

/* Futuristic Button */
.btn-futuristic {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 18px 30px;
  font-size: 1rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 2px;
  color: #fff;
  background: linear-gradient(135deg, var(--navy) 0%, var(--navy-dark) 100%);
  border: none;
  border-radius: 12px;
  cursor: pointer;
  overflow: hidden;
  transition: all 0.3s ease;
}

.btn-futuristic::before {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg, transparent, rgba(36, 74, 192, 0.3), transparent);
  transition: left 0.5s ease;
}

.btn-futuristic:hover::before {
  left: 100%;
}

.btn-futuristic:hover {
  transform: translateY(-3px);
  box-shadow:
    0 10px 30px rgba(10, 51, 93, 0.5),
    0 0 50px rgba(36, 74, 192, 0.2);
}

.btn-futuristic:active {
  transform: translateY(-1px);
}

/* Alert Styles for Login Page */
body.login-page .alert {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 15px 20px;
  border-radius: 12px;
  margin-bottom: 25px;
  animation: shake 0.5s ease;
}

body.login-page .alert-error {
  background: rgba(185, 56, 75, 0.15);
  border: 1px solid rgba(185, 56, 75, 0.3);
  color: #f08090;
}

body.login-page .alert-error svg {
  flex-shrink: 0;
}

@keyframes shake {
  0%, 100% { transform: translateX(0); }
  10%, 30%, 50%, 70%, 90% { transform: translateX(-5px); }
  20%, 40%, 60%, 80% { transform: translateX(5px); }
}

@keyframes fadeInDown {
  from {
    opacity: 0;
    transform: translateY(-30px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* Responsive Design for Login Page */
@media (max-width: 480px) {
  .login-logo {
    max-width: 220px;
  }

  .card-content {
    padding: 35px 25px;
  }

  .title-text {
    font-size: 1.6rem;
  }

  .title-subtitle {
    font-size: 0.8rem;
    letter-spacing: 2px;
  }

  .btn-futuristic {
    padding: 16px 24px;
    font-size: 0.9rem;
    letter-spacing: 1px;
  }
}

/* ========================================
   END FUTURISTIC LOGIN PAGE STYLES
   ======================================== */

/* Navigation */
.admin-nav {
  background: var(--navy);
  color: white;
  box-shadow: 0 2px 8px rgba(10, 51, 93, 0.3);
  position: sticky;
  top: 0;
  z-index: 1000;
}

.nav-container {
  max-width: 1400px;
  margin: 0 auto;
  padding: 0 20px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  height: 60px;
}

.nav-brand a {
  font-size: 1.5rem;
  font-weight: 700;
  color: white;
  text-decoration: none;
}

.nav-menu {
  display: flex;
  list-style: none;
  gap: 25px;
  align-items: center;
}

.nav-menu a {
  color: rgba(255, 255, 255, 0.85);
  text-decoration: none;
  transition: color 0.3s ease;
  font-weight: 500;
}

.nav-menu a:hover {
  color: #fff;
}

.nav-logout {
  color: #f08090 !important;
}

/* Login Page (non-futuristic fallback) */
.login-container {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--dark);
  padding: 20px;
}

.login-card {
  background: white;
  border-radius: 15px;
  padding: 40px;
  width: 100%;
  max-width: 400px;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
}

.login-title {
  text-align: center;
  margin-bottom: 30px;
  color: var(--dark);
  font-size: 2rem;
}

.login-form .form-group {
  margin-bottom: 20px;
}

.login-footer {
  text-align: center;
  margin-top: 20px;
}

.login-footer a {
  color: var(--navy);
  text-decoration: none;
}

/* Dashboard Container */
.dashboard-container,
.form-container,
.analytics-container {
  max-width: 1400px;
  margin: 0 auto;
  padding: 30px 20px;
}

.dashboard-header,
.analytics-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 30px;
  flex-wrap: wrap;
  gap: 15px;
}

.dashboard-header h1,
.analytics-header h1 {
  font-size: 2rem;
  color: var(--dark);
}

/* Stats Grid */
.stats-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 20px;
  margin-bottom: 40px;
}

.stat-card {
  background: white;
  border-radius: 12px;
  padding: 25px;
  display: flex;
  align-items: center;
  gap: 20px;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.06), 0 1px 2px rgba(0, 0, 0, 0.04);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  border: 1px solid var(--border-light);
}

.stat-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 8px 25px rgba(10, 51, 93, 0.1);
}

.stat-icon {
  font-size: 2.5rem;
  color: var(--steel);
  opacity: 0.8;
}

.stat-content h3 {
  font-size: 2rem;
  color: var(--navy);
  margin-bottom: 5px;
}

.stat-content p {
  color: var(--text-muted);
  font-size: 0.95rem;
}

/* Projects Section */
.projects-section,
.recent-activity {
  background: white;
  border-radius: 12px;
  padding: 30px;
  margin-bottom: 30px;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.06), 0 1px 2px rgba(0, 0, 0, 0.04);
  border: 1px solid var(--border-light);
}

.projects-section h2,
.recent-activity h2 {
  margin-bottom: 20px;
  color: var(--dark);
  font-size: 1.5rem;
}

/* Tables */
.projects-table-container,
.activity-table-container {
  overflow-x: auto;
}

.projects-table,
.activity-table,
.analytics-table {
  width: 100%;
  border-collapse: collapse;
}

.projects-table th,
.activity-table th,
.analytics-table th {
  background: var(--cream);
  padding: 15px;
  text-align: left;
  font-weight: 600;
  color: var(--dark);
  border-bottom: 2px solid var(--border);
}

.projects-table td,
.activity-table td,
.analytics-table td {
  padding: 15px;
  border-bottom: 1px solid var(--border-light);
}

.projects-table tr:hover,
.activity-table tr:hover,
.analytics-table tr:hover {
  background: var(--cream);
}

.project-name {
  display: flex;
  align-items: center;
  gap: 10px;
}

.project-thumb {
  width: 40px;
  height: 40px;
  border-radius: 8px;
  object-fit: cover;
}

.calendly-link {
  color: var(--accent);
  text-decoration: none;
}

.calendly-link:hover {
  text-decoration: underline;
}

/* Badges */
.badge {
  display: inline-block;
  padding: 5px 12px;
  border-radius: 20px;
  font-size: 0.85rem;
  font-weight: 600;
}

.badge-success {
  background: var(--success-bg);
  color: var(--success);
}

.badge-danger {
  background: var(--danger-bg);
  color: var(--danger);
}

/* Buttons */
.btn {
  display: inline-block;
  padding: 10px 20px;
  font-size: 1rem;
  font-weight: 600;
  text-align: center;
  text-decoration: none;
  border: none;
  border-radius: 8px;
  cursor: pointer;
  transition: all 0.3s ease;
}

.btn-primary {
  background: var(--accent);
  color: white;
}

.btn-primary:hover {
  background: var(--accent-dark);
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(36, 74, 192, 0.3);
}

.btn-secondary {
  background: var(--cream-dark);
  color: var(--text-primary);
  border: 1px solid var(--border);
}

.btn-secondary:hover {
  background: var(--border);
}

.btn-danger {
  background: var(--danger);
  color: white;
}

.btn-danger:hover {
  background: #9e2e3e;
}

.btn-sm {
  padding: 6px 12px;
  font-size: 0.875rem;
}

.btn-block {
  width: 100%;
  display: block;
}

.actions {
  display: flex;
  gap: 8px;
}

/* Forms */
.form-group {
  margin-bottom: 20px;
}

.form-group label {
  display: block;
  margin-bottom: 8px;
  font-weight: 600;
  color: var(--text-primary);
}

.form-input,
.form-select {
  width: 100%;
  padding: 12px;
  font-size: 1rem;
  border: 2px solid var(--border);
  border-radius: 8px;
  transition: border-color 0.3s ease;
  background: white;
}

.form-input:focus,
.form-select:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(36, 74, 192, 0.1);
}

.form-help {
  display: block;
  margin-top: 5px;
  font-size: 0.875rem;
  color: var(--text-muted);
}

.form-textarea {
  min-height: 100px;
  resize: vertical;
  font-family: inherit;
}

/* Range Input Styling */
.range-input-group {
  display: flex;
  align-items: center;
  gap: 15px;
}

.form-range {
  flex: 1;
  -webkit-appearance: none;
  appearance: none;
  height: 8px;
  background: var(--border);
  border-radius: 4px;
  outline: none;
  cursor: pointer;
}

.form-range::-webkit-slider-thumb {
  -webkit-appearance: none;
  appearance: none;
  width: 20px;
  height: 20px;
  background: var(--navy);
  border-radius: 50%;
  cursor: pointer;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.form-range::-webkit-slider-thumb:hover {
  transform: scale(1.1);
  box-shadow: 0 2px 8px rgba(10, 51, 93, 0.3);
}

.form-range::-moz-range-thumb {
  width: 20px;
  height: 20px;
  background: var(--navy);
  border: none;
  border-radius: 50%;
  cursor: pointer;
}

.range-value {
  min-width: 50px;
  text-align: center;
  font-weight: 600;
  color: var(--navy);
  background: var(--cream);
  padding: 5px 10px;
  border-radius: 6px;
}

/* Section Description */
.section-description {
  color: var(--text-muted);
  font-size: 0.9rem;
  margin-bottom: 20px;
  margin-top: -10px;
}

/* Full Width Form Section */
.form-section-full {
  grid-column: 1 / -1;
}

/* Form Row for Side-by-Side Fields */
.form-row {
  display: flex;
  gap: 20px;
  flex-wrap: wrap;
}

.form-group-half {
  flex: 1;
  min-width: 200px;
}

/* Knowledge Base Styling */
#knowledgeBaseContainer {
  display: flex;
  flex-direction: column;
  gap: 15px;
  margin-bottom: 20px;
}

.knowledge-item {
  background: var(--cream);
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 15px;
}

.knowledge-item-header {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 10px;
}

.knowledge-type-badge {
  padding: 4px 10px;
  border-radius: 12px;
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
}

.knowledge-type-badge.text {
  background: var(--info-bg);
  color: var(--navy);
}

.knowledge-type-badge.url {
  background: var(--success-bg);
  color: var(--success);
}

.knowledge-title {
  flex: 1;
}

.knowledge-content {
  width: 100%;
}

.knowledge-actions {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}

.remove-knowledge-btn {
  margin-left: auto;
}

/* Variable Reference */
.variable-reference {
  background: var(--cream);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 12px 15px;
  margin-top: 15px;
  font-size: 0.9rem;
}

.variable-reference strong {
  display: block;
  margin-bottom: 8px;
  color: var(--dark);
}

.variable-reference code {
  background: var(--cream-dark);
  padding: 2px 6px;
  border-radius: 4px;
  font-size: 0.85rem;
  color: var(--accent);
  margin-right: 5px;
  margin-bottom: 5px;
  display: inline-block;
}

/* Badge Info */
.badge-info {
  background: var(--info-bg);
  color: var(--navy);
}

/* Project Form */
.form-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 30px;
  flex-wrap: wrap;
  gap: 15px;
}

.form-grid {
  display: grid;
  gap: 30px;
  margin-bottom: 30px;
}

.form-section {
  background: white;
  border-radius: 12px;
  padding: 30px;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.06), 0 1px 2px rgba(0, 0, 0, 0.04);
  border: 1px solid var(--border-light);
}

.form-section h3 {
  margin-bottom: 20px;
  color: var(--dark);
  padding-bottom: 10px;
  border-bottom: 2px solid var(--border-light);
}

.color-input-group {
  display: flex;
  gap: 10px;
  align-items: center;
}

.form-input-color {
  width: 60px;
  height: 45px;
  border: 2px solid var(--border);
  border-radius: 8px;
  cursor: pointer;
}

.current-image {
  margin-top: 15px;
  text-align: center;
}

.current-image img {
  max-width: 200px;
  border-radius: 8px;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
  margin-bottom: 10px;
}

.current-image p {
  font-size: 0.875rem;
  color: var(--text-muted);
}

.form-actions {
  display: flex;
  gap: 15px;
  justify-content: flex-start;
}

/* Alerts */
.alert {
  padding: 15px 20px;
  border-radius: 8px;
  margin-bottom: 20px;
}

.alert-error {
  background: var(--danger-bg);
  color: var(--danger);
  border: 1px solid #e8c4c9;
}

.alert-success {
  background: var(--success-bg);
  color: var(--success);
  border: 1px solid #b8dcc8;
}

/* Empty State */
.empty-state {
  text-align: center;
  padding: 60px 20px;
}

.empty-state p {
  font-size: 1.1rem;
  color: var(--text-muted);
  margin-bottom: 20px;
}

/* Analytics Filters */
.filters-section {
  background: white;
  border-radius: 12px;
  padding: 25px;
  margin-bottom: 30px;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.06), 0 1px 2px rgba(0, 0, 0, 0.04);
  border: 1px solid var(--border-light);
}

.filters-form {
  display: flex;
  gap: 15px;
  flex-wrap: wrap;
  align-items: flex-end;
}

.filter-group {
  flex: 1;
  min-width: 200px;
}

.filter-group label {
  display: block;
  margin-bottom: 8px;
  font-weight: 600;
  color: var(--text-primary);
}

/* Charts */
.charts-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(400px, 1fr));
  gap: 20px;
  margin-bottom: 30px;
}

.chart-card {
  background: white;
  border-radius: 12px;
  padding: 25px;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.06), 0 1px 2px rgba(0, 0, 0, 0.04);
  border: 1px solid var(--border-light);
}

.chart-card.full-width {
  grid-column: 1 / -1;
}

.chart-card h3 {
  margin-bottom: 20px;
  color: var(--dark);
}

.chart-content {
  min-height: 200px;
}

.bar-chart,
.line-chart {
  display: flex;
  flex-direction: column;
  gap: 15px;
}

.bar-item {
  display: flex;
  flex-direction: column;
  gap: 5px;
}

.bar-label {
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--text-primary);
}

.bar-wrapper {
  position: relative;
  background: var(--cream);
  border-radius: 6px;
  height: 30px;
  display: flex;
  align-items: center;
}

.bar-fill {
  background: var(--navy);
  height: 100%;
  border-radius: 6px;
  min-width: 2%;
  transition: width 0.5s ease;
}

.bar-value {
  position: absolute;
  right: 10px;
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--text-primary);
}

.line-chart {
  flex-direction: row;
  align-items: flex-end;
  height: 200px;
  gap: 10px;
  padding: 20px 0;
}

.line-item {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 5px;
}

.line-wrapper {
  width: 100%;
  height: 150px;
  display: flex;
  align-items: flex-end;
}

.line-fill {
  width: 100%;
  background: var(--navy);
  border-radius: 4px 4px 0 0;
  min-height: 5px;
  transition: height 0.5s ease;
}

.line-label {
  font-size: 0.75rem;
  color: var(--text-muted);
  writing-mode: horizontal-tb;
  text-align: center;
}

.line-value {
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--text-primary);
}

.analytics-table-section {
  background: white;
  border-radius: 12px;
  padding: 30px;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.06), 0 1px 2px rgba(0, 0, 0, 0.04);
  border: 1px solid var(--border-light);
}

.analytics-table-section h2 {
  margin-bottom: 20px;
  color: var(--dark);
  font-size: 1.5rem;
}

.table-container {
  overflow-x: auto;
}

.text-muted {
  color: var(--text-muted);
  font-style: italic;
}

/* Responsive Design */
@media (max-width: 768px) {
  .nav-menu {
    gap: 15px;
    font-size: 0.9rem;
  }

  .nav-brand a {
    font-size: 1.2rem;
  }

  .dashboard-header h1,
  .analytics-header h1 {
    font-size: 1.5rem;
  }

  .stats-grid {
    grid-template-columns: 1fr;
  }

  .stat-card {
    padding: 20px;
  }

  .form-grid {
    grid-template-columns: 1fr;
  }

  .filters-form {
    flex-direction: column;
  }

  .filter-group {
    width: 100%;
  }

  .charts-grid {
    grid-template-columns: 1fr;
  }

  .form-actions {
    flex-direction: column;
  }

  .form-actions .btn {
    width: 100%;
  }

  .actions {
    flex-direction: column;
    width: 100%;
  }

  .actions .btn {
    width: 100%;
  }

  .projects-table,
  .activity-table,
  .analytics-table {
    font-size: 0.85rem;
  }

  .projects-table th,
  .projects-table td,
  .activity-table th,
  .activity-table td,
  .analytics-table th,
  .analytics-table td {
    padding: 10px;
  }
}

@media (max-width: 480px) {
  .nav-container {
    flex-direction: column;
    height: auto;
    padding: 15px;
  }

  .nav-menu {
    flex-wrap: wrap;
    justify-content: center;
    gap: 10px;
  }

  .login-card {
    padding: 30px 20px;
  }

  .dashboard-container,
  .form-container,
  .analytics-container {
    padding: 20px 10px;
  }

  .projects-section,
  .recent-activity,
  .form-section,
  .chart-card,
  .analytics-table-section {
    padding: 20px 15px;
  }
}
