@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700;800&display=swap');

:root {
  --bg-primary: #ffffff;
  --bg-secondary: #f9fafb;
  --text-primary: #000000;
  --text-secondary: #6b7280;
  --border-color: #e5e7eb;
  --accent-color: #000000;
  --hover-color: #f3f4f6;
}

body {
  font-family: 'Inter', sans-serif;
  background-color: var(--bg-primary);
  color: var(--text-primary);
  margin: 0;
  padding: 0;
}

.sidebar {
  background-color: var(--bg-secondary);
  border-right: 1px solid var(--border-color);
  width: 280px;
  height: 100vh;
  position: fixed;
  display: flex;
  flex-direction: column;
  padding: 2.5rem 2rem;
  box-sizing: border-box;
  z-index: 100;
}

.main-content {
  margin-left: 280px;
  padding: 2.5rem 3rem;
  min-height: 100vh;
}

.card {
  background: var(--bg-primary);
  border: 1px solid var(--border-color);
  border-radius: 0.5rem;
  padding: 1.5rem;
  transition: all 0.2s ease;
}

.card:hover {
  border-color: var(--text-primary);
}

.nav-link {
  display: block;
  padding: 0.75rem 1rem;
  border-radius: 0.375rem;
  color: var(--text-secondary);
  text-decoration: none;
  font-weight: 500;
  margin-bottom: 0.5rem;
  transition: all 0.2s;
}

.nav-link.active {
  background-color: var(--text-primary);
  color: var(--bg-primary);
}

.nav-link:not(.active):hover {
  background-color: var(--hover-color);
  color: var(--text-primary);
}

.stats-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 1.5rem;
  margin-bottom: 2.5rem;
}

.table-container {
  border: 1px solid var(--border-color);
  border-radius: 0.5rem;
  overflow: hidden;
}

.table-header {
  background-color: var(--bg-secondary);
  border-bottom: 1px solid var(--border-color);
  padding: 1rem 1.5rem;
  display: grid;
  grid-template-columns: repeat(12, 1fr);
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--text-secondary);
  font-weight: 600;
}

.table-row {
  padding: 1.25rem 1.5rem;
  display: grid;
  grid-template-columns: repeat(12, 1fr);
  border-bottom: 1px solid var(--border-color);
  align-items: center;
  transition: background-color 0.2s;
}

.table-row:last-child {
  border-bottom: none;
}

.table-row:hover {
  background-color: var(--bg-secondary);
}

.col-name { grid-column: span 5; }
.col-category { grid-column: span 2; }
.col-status { grid-column: span 2; }
.col-progress { grid-column: span 3; }

#projectGrid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 1.5rem;
}

.badge {
  padding: 0.25rem 0.75rem;
  border-radius: 9999px;
  font-size: 0.75rem;
  font-weight: 600;
  border: 1px solid var(--border-color);
}

.badge-completed {
  background-color: #f0fdf4;
  color: #166534;
  border-color: #bbf7d0;
}

.badge-canceled {
  background-color: #fef2f2;
  color: #991b1b;
  border-color: #fecaca;
}

.badge-progress {
  background-color: #fefce8;
  color: #854d0e;
  border-color: #fef08a;
}

.progress-bar {
  width: 100%;
  height: 0.5rem;
  background-color: var(--border-color);
  border-radius: 9999px;
  overflow: hidden;
}

.progress-fill {
  height: 100%;
  background-color: var(--text-primary);
}

.btn {
  padding: 0.5rem 1rem;
  border-radius: 0.375rem;
  font-weight: 500;
  cursor: pointer;
  border: 1px solid var(--border-color);
  background: var(--bg-primary);
  transition: all 0.2s;
}

.btn-primary {
  background: var(--text-primary);
  color: var(--bg-primary);
  border-color: var(--text-primary);
}

.btn-primary:hover {
  background: #333;
}

/* Responsive Styles */
@media (max-width: 1024px) {
  .sidebar {
    width: 240px;
    padding: 2rem 1.5rem;
  }
  .main-content {
    margin-left: 240px;
    padding: 2rem 2rem;
  }
}

@media (max-width: 768px) {
  .sidebar {
    position: relative;
    width: 100%;
    height: auto;
    border-right: none;
    border-bottom: 1px solid var(--border-color);
    padding: 1.5rem;
    position: sticky;
    top: 0;
    z-index: 100;
  }

  .sidebar > div {
    margin-bottom: 1.5rem !important;
  }

  .sidebar nav {
    display: flex;
    gap: 0.5rem;
    overflow-x: auto;
    padding-bottom: 0.5rem;
  }

  .nav-link {
    margin-bottom: 0;
    flex: 1;
    text-align: center;
    white-space: nowrap;
    min-width: 100px;
  }

  .main-content {
    margin-left: 0;
    padding: 1.5rem;
  }

  header {
    flex-direction: column;
    gap: 1rem;
    align-items: flex-start !important;
  }

  header h2 {
    font-size: 1.75rem !important;
  }

  .stats-grid {
    grid-template-columns: 1fr;
  }

  .table-header {
    display: none;
  }

  .table-row {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 1.25rem;
    padding: 1.5rem;
  }

  .table-row > div {
    width: 100%;
    grid-column: span 12 !important;
  }

  .table-row > div:nth-child(2),
  .table-row > div:nth-child(3) {
    width: auto;
    display: inline-block;
  }

  .table-row > div:nth-child(3) {
    margin-left: 0.5rem;
  }

  .table-row > div:last-child {
    margin-top: 0.5rem;
  }

  #projectGrid {
    grid-template-columns: 1fr;
  }

  .transition-logo {
    font-size: 2rem;
  }
}

/* Transition Overlay */
.transition-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: radial-gradient(circle at center, #1a1a1a 0%, #000000 100%);
  z-index: 9999;
  transform: translateY(100%);
  pointer-events: none;
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
  overflow: hidden;
}

.transition-logo {
  font-size: 3.5rem;
  font-weight: 800;
  letter-spacing: -0.05em;
  opacity: 0;
  transform: scale(0.9);
  background: linear-gradient(135deg, #ffffff 0%, #a1a1aa 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  filter: drop-shadow(0 0 30px rgba(255, 255, 255, 0.1));
  z-index: 2;
  text-align: center;
  padding: 0 2rem;
}
