.body{
  background-color: bisque;
}
/* hide-only class for accessibility labels */
.sr-only {
  position: absolute;
  left: -10000px;
  top: auto;
  width: 1px;
  height: 1px;
  overflow: hidden;
}


/* Shows listing grid */
#shows-container {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 18px;
  padding: 16px;
}

.show-card {
  border: 1px solid #ddd;
  border-radius: 10px;
  padding: 12px;
  background: white;
}

.show-card img {
  width: 100%;
  border-radius: 8px;
  margin: 10px 0;
}

#nav {
  margin: 16px;
}

#back-to-shows {
  text-decoration: none;
  font-weight: 600;
}

/* Show search row */
#show-search-row {
  display: flex;
  gap: 12px;
  align-items: center;
  margin: 16px;
}

#show-search {
  flex: 1;
  height: 42px;
  padding: 8px 12px;
  font-size: 16px;
  border: 1px solid #ccc;
  border-radius: 6px;
}


/* Root grid */
#root {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 20px;
  padding: 20px;
}

/* Episode cards */
#root section {
  border: 1px solid #ddd;
  border-radius: 8px;
  padding: 10px;
  background-color: #f9f9f9;
  text-align: center;
  display: flex;
  flex-direction: column;
  justify-content: flex-start;
  min-height: 380px; /* ensures rectangle shape */
  box-shadow: 0 2px 6px rgba(0,0,0,0.1);
}

/* Image */
#root section img {
  width: 100%;
  height: 180px; /* fixed height */
  object-fit: cover; /* keep image ratio, crop if needed */
  border-radius: 4px;
  margin-bottom: 10px;
}

/* Title */
#root section h2 {
  font-size: 1rem;
  margin-bottom: 8px;
  height: 40px; /* fixed height to align cards */
  overflow: hidden;
}

/* Summary */
#root section div {
  color: black;
  font-size: 0.9rem;
  line-height: 1.4;
  flex-grow: 1;
  overflow: hidden;
}

/* Top bar */
#top-bar {
  width: 100%;
  padding: 20px 30px;
  box-sizing: border-box;
  background-color: #f5f5f5;
}

/* Controls row: show select | episode select | search + count */
#controls {
  display: flex;
  align-items: center;
  gap: 20px;
  flex-wrap: wrap; /* wrap on smaller screens */
}

/* Show summary clamped to a few lines */
.show-summary {
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 5;
  overflow: hidden;
}

/* When expanded, show full text */
.show-summary.expanded {
  -webkit-line-clamp: unset;
  display: block;
}

.read-more-btn {
  margin-top: 10px;
  padding: 6px 10px;
  border: 1px solid #ccc;
  background: white;
  border-radius: 6px;
  cursor: pointer;
}

.read-more-btn:hover {
  background: #f5f5f5;
}



/* Fixed widths for the select and search inputs */

#episode-select {
  padding: 10px 12px;
  font-size: 1.2rem;
  width: 220px; /* fixed width */
  flex: 0 0 auto; /* prevent flex-grow */
}

#search-input {
  padding: 10px 12px;
  font-size: 1.2rem;
  width: 260px; /* fixed width */
  flex: 0 0 auto; /* prevent flex-grow */
}

/* Search + count container */
#search-container {
  display: flex;
  align-items: center;
  gap: 15px;
  flex: 0 0 auto; /* prevent stretching */
}

/* Episode count */
#episode-count {
  font-size: 1.2rem;
  font-weight: bold;
  white-space: nowrap;
}

/* Footer */
footer {
  text-align: center;
  padding: 30px 20px;
  font-size: 1.1rem;
  font-weight: bold;
  color: #000;
}

footer hr {
  width: 100%;
  margin: 0 0 20px 0;
  border: none;
  border-top: 1px solid #000;
}

footer a {
  color: blue;
  font-weight: bold;
  text-decoration: none;
}

footer a:hover {
  text-decoration: underline;
}



/* Search container already styled */



/* In style.css made style changes to display episodes in a grid. 
/* In style.css styles for search bar added.
/* Level 200, style.css modified to include select drop-down
/* Level 400, style.css modified to include show selection