/* style.css */
:root {
  --primary: #6366f1;    /* Indigo */
  --primary-light: #818cf8;
  --bg-dark: #0f172a;
  --bg-card: #1e293b;
  --text-main: #f1f5f9;
  --text-muted: #94a3b8;
  --danger: #ef4444;
  --success: #22c55e;
  --border: #334155;
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
  font-family: 'Segoe UI', Roboto, 'Helvetica Neue', sans-serif;
}

body {
  background-color: var(--bg-dark);
  color: var(--text-main);
  line-height: 1.5;
  min-height: 100vh;
}

a { color: var(--primary-light); text-decoration: none; }
a:hover { text-decoration: underline; }

/* Layout */
.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 1rem;
}

.header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 1rem 1.5rem;
  background: rgba(30, 41, 59, 0.8);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--border);
  position: sticky;
  top: 0;
  z-index: 100;
}

.logo {
  font-size: 1.5rem;
  font-weight: 700;
  background: linear-gradient(to right, var(--primary), #a855f7);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.nav-links {
  display: flex;
  gap: 1rem;
  align-items: center;
}

.btn {
  padding: 0.5rem 1rem;
  border-radius: 0.5rem;
  border: none;
  cursor: pointer;
  font-weight: 600;
  transition: all 0.2s;
}

.btn-primary {
  background: var(--primary);
  color: white;
}

.btn-primary:hover { background: #4f46e5; transform: translateY(-1px); }
.btn-outline {
  background: transparent;
  border: 1px solid var(--border);
  color: var(--text-main);
}

/* Cards */
.card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 1rem;
  padding: 1.5rem;
  margin-bottom: 1.5rem;
  transition: transform 0.2s, box-shadow 0.2s;
}

.card:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 20px rgba(0,0,0,0.2);
}

/* Dashboard Grid */
.dashboard-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1.5rem;
}

@media (min-width: 768px) {
  .dashboard-grid {
    grid-template-columns: 300px 1fr;
  }
}

/* Timer Section */
.timer-card {
  text-align: center;
  background: linear-gradient(135deg, #1e1b4b, #1e293b);
  border: 1px solid var(--primary);
}

.timer-display {
  font-size: 4rem;
  font-weight: 700;
  font-family: 'Courier New', monospace;
  margin: 1rem 0;
  color: white;
}

.timer-btn-group {
  display: flex;
  gap: 1rem;
  justify-content: center;
  margin-top: 1rem;
}

.streak-badge {
  display: inline-block;
  padding: 0.5rem 1rem;
  background: rgba(255,255,255,0.1);
  border-radius: 2rem;
  margin-bottom: 1rem;
  font-weight: bold;
  color: #fbbf24; /* Gold */
}

/* Feed */
.feed-grid {
  display: grid;
  gap: 1rem;
}

.feed-item {
  background: rgba(255,255,255,0.03);
  padding: 1rem;
  border-radius: 0.5rem;
  border-left: 4px solid var(--primary);
  cursor: pointer;
}

.feed-item h3 { font-size: 1.1rem; margin-bottom: 0.5rem; }
.feed-meta { font-size: 0.85rem; color: var(--text-muted); display: flex; justify-content: space-between; }

/* Login Page */
.login-container {
  height: 100vh;
  display: flex;
  justify-content: center;
  align-items: center;
  background: radial-gradient(circle at top right, #1e1b4b, var(--bg-dark));
}

.login-box {
  background: var(--bg-card);
  padding: 3rem;
  border-radius: 1.5rem;
  width: 100%;
  max-width: 400px;
  text-align: center;
  box-shadow: 0 10px 30px rgba(0,0,0,0.3);
  border: 1px solid var(--border);
}

.google-btn {
  width: 100%;
  padding: 0.75rem;
  background: white;
  color: #444;
  border-radius: 0.5rem;
  font-weight: 600;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  cursor: pointer;
  border: none;
  font-size: 1rem;
  transition: transform 0.2s;
}
.google-btn:hover { transform: scale(1.02); background: #f1f5f9; }

/* Leaderboard */
.leaderboard-item {
  display: flex;
  justify-content: space-between;
  padding: 0.75rem;
  border-bottom: 1px solid var(--border);
}
.leaderboard-item:last-child { border-bottom: none; }
.rank-1 { color: #fbbf24; font-weight: bold; }

/* Modals */
.modal {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.8);
  display: none; 
  justify-content: center;
  align-items: center;
  z-index: 200;
  padding: 1rem;
}
.modal.active { display: flex; }
.modal-content {
  background: var(--bg-card);
  padding: 2rem;
  border-radius: 1rem;
  width: 100%;
  max-width: 500px;
  position: relative;
  border: 1px solid var(--border);
}

.input-group {
  margin-bottom: 1rem;
}
.input-group input, .input-group textarea {
  width: 100%;
  padding: 0.75rem;
  background: var(--bg-dark);
  border: 1px solid var(--border);
  color: white;
  border-radius: 0.5rem;
}
