/* Reset and Base Styles */
*,
*::before,
*::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

:root {
  --background: #0f172a;
  --foreground: #f1f5f9;
  --card: #1e293b;
  --card-foreground: #f1f5f9;
  --primary: #2dd4bf;
  --primary-foreground: #0f172a;
  --secondary: #334155;
  --secondary-foreground: #f1f5f9;
  --muted: #334155;
  --muted-foreground: #94a3b8;
  --border: #475569;
  --radius: 0.625rem;
  --chart-2: #38bdf8;
  --danger: #ef4444;
  --danger-foreground: #ffffff;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  background-color: var(--background);
  color: var(--foreground);
  line-height: 1.6;
}

.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 1.5rem;
}

/* Navigation */
.nav-header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 50;
  background-color: rgba(15, 23, 42, 0.9);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border);
}

.nav-container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 1.5rem;
  height: 4rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.nav-logo {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  text-decoration: none;
  color: var(--foreground);
}

.logo-text {
  font-size: 1.25rem;
  font-weight: 700;
}

.nav-links {
  display: none;
  align-items: center;
  gap: 2rem;
}

.nav-links a {
  color: var(--muted-foreground);
  text-decoration: none;
  font-size: 0.875rem;
  font-weight: 500;
  transition: color 0.2s;
}

.nav-links a:hover {
  color: var(--primary);
}

.mobile-menu-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  background: none;
  border: none;
  color: var(--foreground);
  cursor: pointer;
  padding: 0.5rem;
}

.mobile-nav {
  padding: 1rem 1.5rem;
  border-bottom: 1px solid var(--border);
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.mobile-nav a {
  color: var(--muted-foreground);
  text-decoration: none;
  font-size: 0.875rem;
  font-weight: 500;
  padding: 0.5rem 0;
}

.hidden {
  display: none !important;
}

@media (min-width: 768px) {
  .nav-links {
    display: flex;
  }

  .mobile-menu-btn {
    display: none;
  }
}

/* Hero Section */
.hero {
  position: relative;
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 6rem 1.5rem 4rem;
  overflow: hidden;
}

.hero-bg {
  position: absolute;
  inset: 0;
  background: radial-gradient(
    ellipse at center,
    rgba(45, 212, 191, 0.15) 0%,
    transparent 70%
  );
}

.hero-content {
  position: relative;
  text-align: center;
  max-width: 800px;
}

.hero-badge {
  display: inline-block;
  padding: 0.5rem 1rem;
  background-color: var(--secondary);
  border: 1px solid var(--border);
  border-radius: 9999px;
  font-size: 0.75rem;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--primary);
  margin-bottom: 1.5rem;
}

.hero-title {
  font-size: clamp(3rem, 10vw, 5rem);
  font-weight: 700;
  letter-spacing: -0.02em;
  background: linear-gradient(to right, var(--foreground), var(--primary));
  background-clip: text;
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.hero-subtitle {
  font-size: clamp(1.25rem, 3vw, 1.5rem);
  color: var(--muted-foreground);
  margin-bottom: 3rem;
}

.hero-meta {
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: 1.5rem;
}

@media (min-width: 640px) {
  .hero-meta {
    flex-direction: row;
    flex-wrap: wrap;
  }
}

.meta-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.25rem;
}

.meta-label {
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--muted-foreground);
}

.meta-value {
  font-weight: 600;
}

.meta-divider {
  width: 1px;
  height: 2.5rem;
  background-color: var(--border);
  display: none;
}

@media (min-width: 640px) {
  .meta-divider {
    display: block;
  }
}

/* Sections */
.section {
  padding: 5rem 0;
}

.section-alt {
  background-color: var(--card);
}

.section-header {
  text-align: center;
  margin-bottom: 3rem;
}

.section-title {
  font-size: 2.25rem;
  font-weight: 700;
}

.section-subtitle {
  color: var(--muted-foreground);
  font-size: 1.125rem;
}

/* Cards */
.card {
  background-color: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.5rem;
}

.card-header {
  display: flex;
  flex-direction: column;
  gap: 0.375rem;
  margin-bottom: 1rem;
  color: var(--primary);
}

.card-header h3 {
  font-size: 1.125rem;
  font-weight: 600;
  color: var(--foreground);
}

.card-subtitle {
  font-size: 0.8125rem;
  color: var(--muted-foreground);
  line-height: 1.4;
}

.sheet-link {
  color: var(--primary);
  text-decoration: none;
  font-weight: 500;
  transition: opacity 0.2s;
}

.sheet-link:hover {
  opacity: 0.8;
  text-decoration: underline;
}

.synopsis-text {
  color: var(--muted-foreground);
  margin-bottom: 1rem;
  line-height: 1.7;
}

/* Team Section */
.team-grid {
  display: grid;
  gap: 1.5rem;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
}

.team-card {
  background-color: var(--background);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.5rem;
  text-align: center;
  transition: border-color 0.2s, transform 0.2s;
  height: 100%;
}

.team-card:hover {
  border-color: var(--primary);
  transform: translateY(-2px);
}

.team-avatar {
  width: 4rem;
  height: 4rem;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--primary), var(--chart-2));
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 1rem;
  font-weight: 700;
  color: var(--background);
}

.team-name {
  font-size: 1.125rem;
  font-weight: 600;
  margin-bottom: 0.5rem;
}

.team-role {
  display: inline-block;
  padding: 0.25rem 0.75rem;
  background-color: var(--secondary);
  border-radius: 9999px;
  font-size: 0.75rem;
  font-weight: 500;
  color: var(--primary);
  margin-bottom: 1rem;
}

/* Time Tracking */
.time-tracking-grid {
  display: grid;
  gap: 1.5rem;
  grid-template-columns: 1fr;
}

@media (min-width: 900px) {
  .time-tracking-grid {
    grid-template-columns: 1fr 1fr;
  }
}

.time-tracking-card {
  display: flex;
  flex-direction: column;
}

/* Entries Section */
.entries-list {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  max-height: 500px;
  overflow-y: auto;
  flex: 1;
}

.entries-list::-webkit-scrollbar {
  width: 6px;
}

.entries-list::-webkit-scrollbar-track {
  background: var(--background);
  border-radius: 3px;
}

.entries-list::-webkit-scrollbar-thumb {
  background: var(--border);
  border-radius: 3px;
}

.no-entries {
  font-size: 0.875rem;
  color: var(--muted-foreground);
  text-align: center;
  padding: 1rem;
}

.entry-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  padding: 0.625rem 0.75rem;
  background: var(--background);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  font-size: 0.8125rem;
}

.entry-info {
  display: flex;
  flex-direction: column;
  gap: 0.125rem;
  min-width: 0;
  flex: 1;
}

.entry-member {
  font-weight: 500;
  color: var(--foreground);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.entry-date {
  font-size: 0.75rem;
  color: var(--muted-foreground);
}

.entry-hours {
  font-weight: 600;
  color: var(--primary);
  white-space: nowrap;
}

/* Week Controls */
.week-controls {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 1rem;
  margin-bottom: 1.5rem;
}

.btn-nav {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0.5rem;
  background: var(--secondary);
  border: 1px solid var(--border);
  color: var(--foreground);
  cursor: pointer;
  border-radius: var(--radius);
  transition: border-color 0.2s, background 0.2s;
}

.btn-nav:hover {
  border-color: var(--primary);
  background: var(--background);
}

.week-label {
  font-size: 0.875rem;
  font-weight: 500;
  color: var(--foreground);
  min-width: 180px;
  text-align: center;
}

/* Chart */
.chart-container {
  position: relative;
  width: 100%;
  height: 250px;
  margin-bottom: 1.5rem;
}

#timeChart {
  width: 100% !important;
  height: 100% !important;
}

.chart-stats {
  display: flex;
  justify-content: center;
  gap: 2rem;
  padding-top: 1rem;
  border-top: 1px solid var(--border);
}

.stat-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.25rem;
}

.stat-label {
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--muted-foreground);
}

.stat-value {
  font-size: 1.25rem;
  font-weight: 700;
  color: var(--primary);
}
