* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  scroll-behavior: smooth;
  text-decoration: none;
}

body {
  font-family: 'Arial', sans-serif;
  line-height: 1.6;
  background-color: #f5f5f5;
}

/* navbar styles */
.navbar {
  background-color: #7dc4ea;   /*navbar bg color*/
  color: white;
  padding: 1rem 2rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
  box-shadow: 0 2px 5px rgba(0,0,0,0.1);
}

.nav-brand h1 {
  font-size: 1.5rem;
  font-weight: 600;
  color: white;    /*  ShelfSync color */
}

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

.nav-links a {
  color: white;
  padding: 0.5rem 1rem;
  border-radius: 4px;
  transition: background-color 0.3s ease;
}

.nav-links a:hover {
  background-color: rgba(255, 255, 255, 0.1);
}

.nav-links a.active {
  background-color: rgba(255, 255, 255, 0.2);
}

.book-action-btn {
  width: 100%;
  padding: 0.75rem 1rem;
  border: none;
  border-radius: 4px;
  cursor: pointer;
  font-size: 0.9rem;
  transition: background-color 0.3s ease;
  margin-top: auto;  /* Push button to bottom */
}

.save-btn {
  background-color: #2ecc71;
  color: white;
}

.save-btn:hover {
  background-color: #27ae60;
}

.remove-btn {
  background-color: #e74c3c;
  color: white;
}

.remove-btn:hover {
  background-color: #c0392b;
}

.auth-btn {
  padding: 0.5rem 1rem;
  border: none;
  border-radius: 4px;
  background-color: #3498db;
  color: white;       
  cursor: pointer;
  font-size: 0.9rem;
  transition: background-color 0.3s ease;
}

.auth-btn:hover {
  background-color: #2980b9;
}

/* User profile styles */
.user-profile {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  color: white;
}

.avatar {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  object-fit: cover;
}

/* Search container styles */
.search-container {
  max-width: 800px;
  margin: 2rem auto;
  padding: 0 1rem;
  display: flex;
  gap: 1rem;
}

.search-bar {
  flex: 1;
  padding: 0.8rem 1rem;
  border: 2px solid #ddd;
  border-radius: 4px;
  font-size: 1rem;
  transition: border-color 0.3s ease;
}

.search-bar:focus {
  outline: none;
  border-color: #3498db;
}

.search-btn {
  padding: 0.8rem 1.5rem;
  background-color: #3498db;
  color: white;
  border: none;
  border-radius: 4px;
  cursor: pointer;
  font-size: 1rem;
  transition: background-color 0.3s ease;
}

.search-btn:hover {
  background-color: #2980b9;
}

/* Add these styles to styles.css */
.filters-container {
  max-width: 800px;
  margin: 0 auto 2rem;
  padding: 1rem;
  background-color: white;
  border-radius: 8px;
  box-shadow: 0 2px 5px rgba(0,0,0,0.1);
  display: flex;
  flex-wrap: wrap;
  gap: 1.5rem;
}

.filter-group {
  flex: 1;
  min-width: 200px;
}

.filter-group label {
  display: block;
  margin-bottom: 0.5rem;
  color: #2c3e50;
  font-weight: 500;
}

.filter-select {
  width: 100%;
  padding: 0.5rem;
  border: 1px solid #ddd;
  border-radius: 4px;
  font-size: 0.9rem;
  color: #2c3e50;
}

.year-range {
  display: flex;
  gap: 0.5rem;
  align-items: center;
}

.year-input {
  width: 100%;
  padding: 0.5rem;
  border: 1px solid #ddd;
  border-radius: 4px;
  font-size: 0.9rem;
  color: #2c3e50;
}

.year-input::-webkit-inner-spin-button,
.year-input::-webkit-outer-spin-button {
  opacity: 1;
}

.filter-select:focus,
.year-input:focus {
  outline: none;
  border-color: #3498db;
}

/* Main content area */
.main-content {
  max-width: 1200px;
  margin: 0 auto;
  padding: 2rem 1rem;
}

/* Book grid styles */
.books-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 2rem;
  padding: 1rem;
}

.book-card {
  background: white;
  border-radius: 8px;
  box-shadow: 0 2px 5px rgba(0,0,0,0.1);
  overflow: hidden;
  transition: transform 0.3s ease;
  display: flex;
  flex-direction: column;
  height: 100%;  /* Make all cards the same height */
}

.book-card:hover {
  transform: translateY(-5px);
}

.book-cover {
  width: 100%;
  height: 200px;
  object-fit: contain;
}

.book-info {
  padding: 1rem;
  display: flex;
  flex-direction: column;
  flex-grow: 1;  /* Allow info section to grow */
  min-height: 0;  /* Prevent overflow */
}

.book-title {
  font-size: 1.2rem;
  margin-bottom: 0.5rem;
  color: #2c3e50;
}

.book-author {
  font-size: 0.9rem;
  color: #7f8c8d;
  margin-bottom: 0.5rem;
}

.book-description {
  font-size: 0.9rem;
  color: #34495e;
  line-height: 1.4;
  flex-grow: 1;  /* Push button to bottom */
  margin-bottom: 1rem;  /* Add space above button */
}

.no-results {
  text-align: center;
  color: #7f8c8d;
  font-size: 1.2rem;
  padding: 2rem;
}

