html {
  scroll-behavior: smooth;
}

body.home-page {
  background: #f5f5f5;
  padding: 2rem;
  font-family: sans-serif;
}

.search-box {
  max-width: 600px;
  margin: 0 auto 3rem auto;
}

.show-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 1.5rem;
}

.show-tile {
  background: white;
  border-radius: 12px;
  box-shadow: 0 4px 12px rgba(0,0,0,0.1);
  padding: 1.5rem;
  text-align: center;
  cursor: pointer;
  transition: transform 0.15s ease;
  user-select: none;
  text-decoration: none;
  color: inherit;
  display: flex;
  flex-direction: column;
  justify-content: center;
  height: 180px;
}

.show-tile:hover {
  transform: translateY(-5px);
  box-shadow: 0 8px 20px rgba(0,0,0,0.15);
  text-decoration: none;
  color: #007bff;
}

.show-name {
  font-size: 1.25rem;
  font-weight: 600;
  margin-bottom: 0.5rem;
  flex-grow: 1;
  word-wrap: break-word;
  text-align: center;
}

.episode-count {
  font-size: 2.5rem;
  font-weight: 700;
  color: #4a90e2;
}

.popover.search-popover {
  max-width: 500px;
  white-space: normal;
  overflow-y: auto;
  max-height: 400px;
}

@media (max-width: 576px) {
  .popover.search-popover {
    max-width: 90vw;
  }
}

mark {
  background-color: #ffe066;
  padding: 0 2px;
}

.timecode {
  font-weight: bold;
  color: #555;
  margin-right: 6px;
}

.snippet {
  font-family: monospace;
}

.highlight {
  background-color: #fff3b0;
  font-weight: bold;
  padding: 0 2px;
  border-radius: 2px;
}

/* Segment rows */
.segment {
  padding: 8px;
  border-bottom: 1px solid #eee;
  cursor: pointer;
  transition: background-color 0.3s ease;
}

.segment:hover { background: #f9f9f9; }

/* Scroll to top button */
#scrollTopBtn {
  display: none;
  position: fixed;
  bottom: 30px;
  right: 30px;
  z-index: 1000;
}

/* Jump highlight animation */
.highlighted-segment {
  background-color: #fff3b0 !important;
  animation: pulse 1s ease;
}

@keyframes pulse {
  0%   { box-shadow: 0 0 0 rgba(0,0,0,0); }
  50%  { box-shadow: 0 0 10px rgba(255, 195, 0, 0.5); }
  100% { box-shadow: 0 0 0 rgba(0,0,0,0); }
}

/* Score badges */
.badge-misogyny {
  background-color: rgba(180, 120, 255, 0.8);
  font-size: 0.7em;
}

.badge-hate {
  background-color: rgba(255, 150, 170, 0.8);
  font-size: 0.7em;
}

.badge-toxicity {
  background-color: rgba(120, 210, 170, 0.8);
  font-size: 0.7em;
}

/* Stat cards */
.card-misogyny {
  border: 2px solid #d8b0ff;
  background-color: rgba(216, 176, 255, 0.1);
}

.card-hate {
  border: 2px solid #ffc0cb;
  background-color: rgba(255, 192, 203, 0.1);
}

.card-toxicity {
  border: 2px solid #a0dfc0;
  background-color: rgba(160, 223, 192, 0.1);
}

.card-info {
  background-color: rgba(13, 202, 240, 0.1);
}

.card-equal {
  display: flex; flex-direction: column; height: 100%;
}

.date-box {
  min-width: 100px;
  min-height: 60px;
  background-color: #f8f9fa;
  border: 1px solid #ddd;
  border-radius: .5rem;
  padding: .5rem;
}

#chart {
  cursor: crosshair;
}

.show-info-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 1px;
  background-color: #dee2e6;
  border-radius: 12px;
  overflow: hidden;
  margin-bottom: 1.5rem;
  border: 2px solid #dee2e6;
}

.si-cell {
  background-color: #f8f9fa;
  padding: 1rem 1.25rem;
  text-align: center;
}

.si-cell-alt {
  background-color: #f8f9fa;
}

.si-label {
  font-size: 20px;
  color: #6c757d;
  margin: 0 0 4px;
}

.si-value {
  font-size: 1.75rem;
  font-weight: 500;
  margin: 0;
}

.si-harm-label {
  font-size: 13px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: #6c757d;
  margin: 0 0 10px;
  text-align: center;
}

.si-harm-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
  margin-bottom: 1.5rem;
}

.si-harm-card {
  border-radius: 12px;
  padding: 3.0rem;
  text-align: center;
}

.si-harm-type {
  font-size: 20px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.07em;
  margin: 0 0 8px;
}

.si-harm-value {
  font-size: 3.0rem;
  font-weight: 500;
  line-height: 1;
  margin: 0 0 4px;
}

.si-harm-sub {
  font-size: 14px;
  margin: 0;
}

.si-harm-grid:has(> :nth-child(1):last-child) {
  grid-template-columns: minmax(0, 1fr);
}

.si-harm-grid:has(> :nth-child(2):last-child) {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.card-misogyny .si-harm-type,
.card-misogyny .si-harm-sub { color: #7a4faa; }
.card-toxicity .si-harm-type,
.card-toxicity .si-harm-sub { color: #2e7a57; }
.card-hate .si-harm-type,
.card-hate .si-harm-sub { color: #aa4f6a; }


