/* Ingle Listen — mobile-first community listening experience. */

html,
body {
  width: 100%;
  height: 100%;
  margin: 0;
  overflow: hidden;
}

body {
  min-height: 100vh;
  min-height: 100dvh;
}

.listen-app .listen-workspace {
  width: 100%;
  min-height: 100%;
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

.listen-intro,
.listen-filters,
.listen-results,
.listen-community-note {
  border: 1px solid var(--line);
  background: #fff;
  border-radius: 20px;
}

.listen-intro {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  margin-bottom: 14px;
  padding: 20px;
}

.listen-intro-copy {
  min-width: 0;
}

.listen-kicker,
.listen-filter-kicker {
  color: var(--green, #257a53);
  font-size: 0.72rem;
  font-weight: 900;
  letter-spacing: 0.11em;
  text-transform: uppercase;
}

.listen-intro h1 {
  max-width: 17ch;
  margin: 4px 0 10px;
  font-size: clamp(1.9rem, 8vw, 3.3rem);
  line-height: 1;
  letter-spacing: -0.045em;
}

.listen-intro p {
  max-width: 760px;
  margin: 0;
  color: var(--muted);
  line-height: 1.55;
}

.listen-intro-icon {
  flex: 0 0 auto;
  display: none;
  width: 74px;
  height: 74px;
  place-items: center;
  border-radius: 22px;
  background: #eef7fb;
  font-size: 2rem;
}

.listen-layout {
  display: grid;
  gap: 14px;
}

.listen-filters {
  align-self: start;
  overflow: hidden;
}

.listen-topic-toggle {
  width: 100%;
  min-height: 72px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  border: 0;
  background: #fff;
  padding: 14px 16px;
  color: inherit;
  text-align: left;
  cursor: pointer;
}

.listen-topic-toggle > span:first-child {
  display: grid;
  gap: 3px;
}

.listen-topic-toggle strong {
  font-size: 1rem;
}

.listen-topic-toggle small {
  color: var(--muted);
  font-size: 0.8rem;
}

.listen-topic-toggle-icon {
  font-size: 1.35rem;
  transition: transform 160ms ease;
}

.listen-topic-toggle[aria-expanded="true"] .listen-topic-toggle-icon {
  transform: rotate(180deg);
}

.listen-topic-panel {
  display: none;
  border-top: 1px solid var(--line);
  padding: 16px;
}

.listen-topic-panel.is-open {
  display: block;
}

.listen-filter-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 14px;
}

.listen-filter-head strong {
  display: block;
  margin-top: 3px;
}

.listen-clear-filters {
  border: 0;
  background: transparent;
  padding: 5px;
  color: var(--green, #257a53);
  font: inherit;
  font-size: 0.82rem;
  font-weight: 800;
  cursor: pointer;
}

.listen-topic-list {
  display: grid;
  gap: 8px;
}

.listen-topic-option {
  min-height: 54px;
  display: grid;
  grid-template-columns: 22px minmax(0, 1fr);
  align-items: center;
  gap: 10px;
  padding: 10px 11px;
  border: 1px solid var(--line);
  border-radius: 13px;
  background: #fbfcfd;
  cursor: pointer;
}

.listen-topic-option:hover {
  border-color: #bfcfd9;
}

.listen-topic-option input {
  width: 18px;
  height: 18px;
  margin: 0;
  accent-color: var(--green, #257a53);
}

.listen-topic-option > span {
  min-width: 0;
  display: grid;
  gap: 2px;
}

.listen-topic-option strong {
  overflow: hidden;
  font-size: 0.9rem;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.listen-topic-option small {
  color: var(--muted);
  font-size: 0.75rem;
}

.listen-topic-option-all {
  background: #eef9f3;
  border-color: #d3eadf;
}

.listen-filter-empty {
  margin: 0;
  color: var(--muted);
  line-height: 1.45;
}

.listen-results {
  min-width: 0;
  padding: 16px;
}

.listen-results-head {
  display: grid;
  gap: 8px;
  margin-bottom: 14px;
}

.listen-results-head h2 {
  margin: 4px 0 0;
  font-size: clamp(1.35rem, 5vw, 2rem);
  letter-spacing: -0.03em;
}

.listen-topic-summary {
  margin: 0;
  color: var(--muted);
  font-size: 0.86rem;
  line-height: 1.4;
}

.listen-status {
  min-height: 44px;
  display: grid;
  place-items: center;
  margin-bottom: 12px;
  border-radius: 14px;
  background: #f5f7f9;
  color: var(--muted);
  font-size: 0.86rem;
  text-align: center;
}

.listen-error {
  width: 100%;
  box-sizing: border-box;
  padding: 12px;
  border: 1px solid #f0c7c2;
  border-radius: 12px;
  background: #fff5f4;
  color: #8b2b21;
}

.listen-feed {
  display: grid;
  gap: 12px;
}

.listen-answer-card {
  min-width: 0;
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: 17px;
  background: #fff;
  box-shadow: 0 6px 18px rgba(20, 35, 50, 0.045);
}

.listen-answer-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
}

.listen-award {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  min-height: 28px;
  margin-bottom: 7px;
  padding: 0 10px;
  border-radius: 999px;
  background: #fff7da;
  color: #72520a;
  font-size: 0.76rem;
  font-weight: 850;
}

.listen-topic-label {
  color: var(--green, #257a53);
  font-size: 0.76rem;
  font-weight: 850;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.listen-fluency {
  flex: 0 0 auto;
  display: grid;
  justify-items: end;
  gap: 2px;
}

.listen-fluency span {
  color: var(--muted);
  font-size: 0.7rem;
  font-weight: 800;
  text-transform: uppercase;
}

.listen-fluency strong {
  font-size: 1.35rem;
  line-height: 1;
}

.listen-question {
  margin: 13px 0 10px;
  font-size: clamp(1.08rem, 4vw, 1.35rem);
  line-height: 1.35;
  letter-spacing: -0.015em;
}

.listen-answer-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 7px 12px;
  margin-bottom: 13px;
  color: var(--muted);
  font-size: 0.78rem;
}

.listen-audio {
  display: block;
  width: 100%;
  min-height: 44px;
}

.listen-transcript-toggle {
  margin-top: 12px;
  border: 0;
  background: transparent;
  padding: 3px 0;
  color: var(--green, #257a53);
  font: inherit;
  font-size: 0.82rem;
  font-weight: 800;
  cursor: pointer;
}

.listen-transcript {
  margin-top: 10px;
  padding: 13px;
  border-radius: 13px;
  background: #f6f8fa;
  color: #344257;
  font-size: 0.9rem;
  line-height: 1.6;
  white-space: pre-wrap;
}

.listen-empty {
  padding: 32px 18px;
  text-align: center;
}

.listen-empty-icon {
  font-size: 2rem;
}

.listen-empty h2 {
  margin: 10px 0 6px;
  font-size: 1.25rem;
}

.listen-empty p {
  max-width: 500px;
  margin: 0 auto;
  color: var(--muted);
  line-height: 1.5;
}

.listen-load-more-wrap {
  display: grid;
  place-items: center;
  padding-top: 16px;
}

.listen-load-more {
  min-height: 44px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: #fff;
  padding: 0 20px;
  color: inherit;
  font: inherit;
  font-weight: 850;
  cursor: pointer;
}

.listen-load-more:hover {
  border-color: #b8c9d3;
  box-shadow: 0 6px 14px rgba(20, 35, 50, 0.07);
}

.listen-load-more:disabled {
  cursor: wait;
  opacity: 0.65;
}

.listen-community-note {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-top: 14px;
  padding: 15px 16px;
  background: linear-gradient(135deg, #eef9f3, #f7fbf8);
}

.listen-community-note > span {
  flex: 0 0 auto;
  font-size: 1.45rem;
}

.listen-community-note p {
  margin: 0;
  color: #405064;
  font-size: 0.86rem;
  line-height: 1.45;
}

.listen-community-note strong {
  color: #13613f;
}

@media (min-width: 560px) {
  .listen-intro {
    padding: 24px;
  }

  .listen-intro-icon {
    display: grid;
  }

  .listen-results {
    padding: 20px;
  }

  .listen-results-head {
    grid-template-columns: minmax(0, 1fr) auto;
    align-items: end;
  }

  .listen-topic-summary {
    max-width: 280px;
    text-align: right;
  }

  .listen-answer-card {
    padding: 19px;
  }
}



@media (min-width: 900px) {
  .listen-layout {
    grid-template-columns: minmax(230px, 280px) minmax(0, 1fr);
    align-items: start;
  }

  .listen-topic-toggle {
    display: none;
  }

  .listen-topic-panel {
    display: block;
    border-top: 0;
    padding: 18px;
  }

  .listen-filters {
    position: sticky;
    top: 0;
  }
}



@media (min-width: 1180px) {
  .listen-feed {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (prefers-reduced-motion: reduce) {
  .listen-topic-toggle-icon {
    transition: none;
  }
}
/* Ingle Listen — thumbs feedback controls */

.listen-rating-controls {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 8px;
  margin-top: 10px;
}

.listen-rating-button {
  width: 42px;
  height: 38px;
  display: inline-grid;
  place-items: center;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: #fff;
  padding: 0;
  color: inherit;
  font: inherit;
  font-size: 1.08rem;
  line-height: 1;
  cursor: pointer;
  opacity: 0.58;
  transition:
    opacity 140ms ease,
    transform 140ms ease,
    border-color 140ms ease,
    background 140ms ease,
    box-shadow 140ms ease;
}

.listen-rating-button:hover {
  opacity: 1;
  transform: translateY(-1px);
  border-color: #b8c9d3;
  box-shadow: 0 5px 12px rgba(20, 35, 50, 0.08);
}

.listen-rating-button.is-selected {
  opacity: 1;
  border-color: #badfca;
  background: #eef9f3;
  box-shadow: 0 0 0 3px rgba(37, 122, 83, 0.08);
}

.listen-rating-button[data-listen-rating="-1"].is-selected {
  border-color: #dfc7c4;
  background: #fff4f2;
  box-shadow: 0 0 0 3px rgba(139, 43, 33, 0.06);
}

.listen-rating-button:disabled {
  cursor: wait;
  opacity: 0.4;
}

.listen-rating-button:focus-visible {
  outline: 3px solid rgba(37, 122, 83, 0.24);
  outline-offset: 2px;
}

@media (prefers-reduced-motion: reduce) {
  .listen-rating-button {
    transition: none;
  }
}

