.all-openings-view {
  padding: 28px 0 48px;
}

.page-header {
  text-align: left;
  margin-bottom: 28px;
  max-width: 640px;
}

.page-header p {
  margin: 0;
  color: var(--muted);
  line-height: 1.7;
}

.opening-family {
  margin-bottom: 36px;
}

.opening-family-title {
  margin: 0 0 14px;
  font-size: 1.05rem;
  font-weight: 650;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--muted);
}

.course-list {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.all-openings-view.grid-mode .course-list {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
  gap: 16px;
}

.all-openings-view.grid-mode .course-row {
  display: flex;
  flex-direction: column;
  height: auto;
  grid-template-columns: none;
}

/* Grid cards give the picture the full card width, and a square crop there costs
   far more than it does in the list — a 4:3 photo of a board loses its edges.

   The box stays SQUARE. It was briefly 4:3, on the reasoning that a wider box
   suits a landscape photo, but the built-in opening art is a square 8x8 board:
   letterboxing that into a 4:3 frame left 9px of empty board-coloured space down
   each side of every card, which read as the artwork failing to fill its frame.
   A member's own cover is a photo of a board, so it is square-ish too.

   `cover` rather than `contain` is what makes the artwork fill the frame edge to
   edge. Because the box matches the art's shape, the two agree here — and cover
   is chosen so a slightly-off-ratio upload fills the frame instead of floating
   in it.

   Two roots, because the two libraries switch view differently:
   /openings toggles `.grid-mode` and /repertoire toggles `.is-grid`. */
.all-openings-view.grid-mode .course-row-thumb,
.repertoire-view.is-grid .course-row-thumb {
  width: 100%;
  height: auto;
  aspect-ratio: 1 / 1;
  object-fit: cover;
  /* Only reached by a cover whose aspect genuinely differs; the board colour
     keeps any sliver that does appear looking like part of the board. */
  background: #769656;
}

.all-openings-view.grid-mode .course-row-body {
  padding: 12px;
}

.all-openings-view.grid-mode .course-row-heading {
  flex-direction: column;
  align-items: flex-start;
}

.all-openings-view.grid-mode .course-row-meta {
  margin-top: 8px;
  justify-content: center;
}

.all-openings-view.grid-mode .course-row-aside {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 6px;
  padding-top: 8px;
}

.all-openings-view.grid-mode .course-row-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: flex-start;
  gap: 8px 12px;
  margin-top: 8px;
}

.all-openings-view.grid-mode .course-row-actions .btn {
  min-height: 32px;
  padding: 0 10px;
  font-size: 0.78rem;
}

.page-header {
  display: flex;
  flex-direction: row;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 28px;
  max-width: 640px;
  gap: 20px;
}

.page-header-text {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.view-toggle-group {
  display: inline-flex;
  align-items: center;
  padding: 4px;
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 10px;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
}

.view-toggle-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 16px;
  border: none;
  background: transparent;
  color: var(--muted);
  font-size: 0.82rem;
  font-weight: 600;
  cursor: pointer;
  border-radius: 8px;
  transition: all 0.2s ease;
  white-space: nowrap;
}

.view-toggle-btn:hover {
  color: var(--gold-bright);
}

.view-toggle-btn .view-toggle-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 20px;
  height: 20px;
  flex-shrink: 0;
  color: var(--muted);
  transition: color 0.2s ease;
}

.view-toggle-btn:hover .view-toggle-icon {
  color: var(--gold-bright);
}

.view-toggle-btn.is-on {
  background: var(--gold);
  color: var(--on-solid);
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.15);
}

.view-toggle-btn.is-on .view-toggle-icon {
  color: var(--on-solid);
}

.course-row,
.course-row-main {
  display: grid;
  /* Matches the 72px thumbnail below. It was 56px, so the image overflowed its
     own track and overlapped the title by 4px — the grid reserved less space
     than the picture needed. The letterbox variant is sized by the same
     `.course-row-thumb` rule, so both follow one number. */
  grid-template-columns: 72px minmax(0, 1fr);
  gap: 12px;
  align-items: center;
  min-width: 0;
  color: inherit;
  text-decoration: none;
}

.course-row {
  padding: 8px 10px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: var(--panel);
  grid-template-columns: 72px minmax(0, 1fr) auto;
}

a.course-row,
.course-row-main {
  cursor: pointer;
}

a.course-row:hover,
.course-row.is-community:hover,
.course-row.is-own:hover {
  background: var(--fill-subtle, rgba(255, 255, 255, 0.03));
}

.course-row.is-soon {
  opacity: 0.62;
  cursor: default;
}

.course-row.is-complete {
  background: color-mix(in srgb, #22c55e 16%, var(--panel));
  border-color: color-mix(in srgb, #22c55e 40%, var(--line));
}

.course-row.is-complete:hover {
  background: color-mix(in srgb, #22c55e 22%, var(--panel));
}

.course-row.is-complete .course-row-aside {
  color: #4ade80;
  font-weight: 700;
}

html[data-theme="light"] .course-row.is-complete {
  background: color-mix(in srgb, #16a34a 12%, #fff);
  border-color: color-mix(in srgb, #16a34a 28%, var(--line));
}

html[data-theme="light"] .course-row.is-complete .course-row-aside {
  color: #15803d;
}

.course-row-thumb {
  width: 72px;
  height: 72px;
  object-fit: cover;
  border-radius: 8px;
  background: var(--bg-3);
  border: 1px solid var(--line);
}

.course-row-mark {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 72px;
  height: 72px;
  margin: 0 auto;
  border-radius: 10px;
  font-size: 0.9rem;
  font-weight: 800;
  background: var(--fill-subtle, rgba(255, 255, 255, 0.06));
  color: var(--gold-bright);
}

.course-row-mark.is-white {
  color: #1a1712;
  background: #f6f0e4;
}

.course-row-mark.is-black {
  color: #e8e4dc;
  background: #1a1712;
  box-shadow: inset 0 0 0 1px var(--line-strong);
}

.endgame-row-mark {
  background: color-mix(in srgb, var(--gold) 14%, var(--bg-3));
  color: var(--gold-bright);
  border: 1px solid color-mix(in srgb, var(--gold) 32%, var(--line));
}

.endgames-view .course-row {
  padding: 10px 12px;
  grid-template-columns: 112px minmax(0, 1fr) auto;
  gap: 14px;
}

.endgames-view .course-row-thumb {
  width: 112px;
  height: 112px;
  border-radius: 10px;
  object-fit: contain;
}

.course-row-body {
  min-width: 0;
  overflow: hidden;
}

.course-row-heading {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 10px;
}

.course-row-body strong {
  display: block;
  font-size: 0.94rem;
  font-weight: 700;
  letter-spacing: -0.02em;
  line-height: 1.25;
  overflow-wrap: break-word;
  word-wrap: break-word;
}

.course-row-body > span {
  display: block;
  margin-top: 2px;
  color: var(--muted);
  font-size: 0.8rem;
  line-height: 1.35;
}

.course-access {
  flex: 0 0 auto;
  display: inline-flex;
  align-items: center;
  min-height: 22px;
  padding: 0 8px;
  border-radius: 999px;
  border: 1px solid var(--line);
  font-size: 0.66rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--muted);
  white-space: nowrap;
}

.course-access.is-free {
  color: #4ade80;
  border-color: color-mix(in srgb, #22c55e 45%, var(--line));
  background: color-mix(in srgb, #22c55e 12%, transparent);
}

.course-access.is-signin {
  color: var(--gold-bright);
  border-color: color-mix(in srgb, var(--gold) 45%, var(--line));
  background: color-mix(in srgb, var(--gold) 12%, transparent);
}

.course-access.is-locked {
  color: #7dd3fc;
  border-color: color-mix(in srgb, #38bdf8 40%, var(--line));
  background: color-mix(in srgb, #38bdf8 10%, transparent);
}

.course-access.is-open {
  color: var(--cream-dim, var(--muted));
  border-color: var(--line);
}

.course-access.is-soon {
  opacity: 0.8;
}

.course-row-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 8px;
}

.course-chip {
  display: inline-flex;
  align-items: center;
  min-height: 24px;
  padding: 0 9px;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: color-mix(in srgb, var(--ink, #fff) 4%, transparent);
  color: var(--muted);
  font-size: 0.72rem;
  font-weight: 650;
  letter-spacing: 0.01em;
}

.course-chip.is-white {
  color: #f6f0e4;
  border-color: color-mix(in srgb, #fbbf24 35%, var(--line));
}

.course-chip.is-black {
  color: #bae6fd;
  border-color: color-mix(in srgb, #38bdf8 35%, var(--line));
}

html[data-theme="light"] .course-chip.is-white {
  color: #92400e;
}

html[data-theme="light"] .course-chip.is-black {
  color: #0369a1;
}

html[data-theme="light"] .course-access.is-free {
  color: #15803d;
}

.course-row.is-community {
  grid-template-columns: minmax(0, 1fr) auto;
}

.course-row.is-community .course-row-main {
  min-width: 0;
}

.course-row-aside {
  color: var(--muted);
  font-size: 0.8rem;
  padding-right: 4px;
  display: flex;
  align-items: center;
  gap: 10px;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  font-weight: 700;
  font-size: 0.72rem;
}

.course-row-aside a {
  color: var(--gold);
  text-decoration: none;
}

.course-row-aside a:hover {
  text-decoration: underline;
}

.course-row.is-own {
  grid-template-columns: 72px minmax(0, 1fr) auto;
  gap: 12px;
}

.course-row-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: flex-end;
  gap: 6px 10px;
}

.course-row-actions .btn {
  min-height: 36px;
  padding: 0 12px;
  letter-spacing: 0.04em;
}

.course-row-learn {
  color: var(--gold-bright);
}

.course-tag-list {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
  margin-top: 6px;
}

.course-tag {
  display: inline-flex;
  align-items: center;
  min-height: 22px;
  padding: 0 8px;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: color-mix(in srgb, var(--ink) 4%, transparent);
  color: var(--muted);
  font-size: 0.68rem;
  font-weight: 650;
  letter-spacing: 0.02em;
}

.course-row-progress {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 10px;
  margin-top: 8px;
}

.course-row-progress-track {
  height: 6px;
  border-radius: 999px;
  overflow: hidden;
  background: color-mix(in srgb, var(--ink) 10%, transparent);
}

.course-row-progress-track i {
  display: block;
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, var(--gold-deep), var(--gold-bright));
}

.course-row-progress > span {
  color: var(--muted);
  font-size: 0.72rem;
  font-weight: 650;
  white-space: nowrap;
  font-variant-numeric: tabular-nums;
}

.library-filter {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin: 0 0 14px;
}

.library-filter-chip {
  display: inline-flex;
  align-items: center;
  min-height: 30px;
  padding: 4px 11px;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: var(--bg-3);
  color: var(--cream-dim);
  font: inherit;
  font-size: 0.74rem;
  font-weight: 650;
  cursor: pointer;
}

.library-filter-chip:hover {
  border-color: color-mix(in srgb, var(--gold) 40%, var(--line));
  color: var(--gold-bright);
}

.library-filter-chip.is-on {
  border-color: color-mix(in srgb, var(--gold) 55%, var(--line));
  background: color-mix(in srgb, var(--gold) 14%, var(--bg-3));
  color: var(--gold-bright);
}

.library-filter-empty {
  margin: 8px 0 0;
  color: var(--muted);
  font-size: 0.9rem;
}

.course-row-actions a,
.course-row-actions .repertoire-action,
.course-row-actions .repertoire-action-disabled {
  color: var(--gold-bright);
  font-size: 0.72rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  text-decoration: none;
  font-weight: 700;
  padding: 0;
  border: 0;
  background: transparent;
  font-family: var(--font);
  cursor: pointer;
}

.course-row-actions a:hover,
.course-row-actions .repertoire-action:hover {
  text-decoration: underline;
}

.course-row-actions .repertoire-action.danger {
  color: #ff9aa8;
}

.course-row-actions .repertoire-action-disabled {
  color: var(--muted);
  cursor: default;
}

.all-openings-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(168px, 1fr));
  gap: 16px;
}

.community-section {
  margin-top: 48px;
  padding-top: 28px;
  border-top: 1px solid var(--line);
}

/* The section header. .page-header is a horizontal flex (text beside the view
   toggle), so the copy needs the same .page-header-text wrapper the page header
   uses — without it the eyebrow, heading and paragraph became flex siblings and
   the heading was crushed into a narrow column that wrapped one word per line.
   The heading is an h2 here, so it is sized to match the h1 it sits under
   rather than inheriting the page-level scale. */
.community-header {
  align-items: flex-end;
  gap: 24px;
  margin-bottom: 22px;
  /* Wider than the 640px the page header sets, because this row has room for
     copy and two buttons side by side. */
  max-width: 900px;
}

.community-header .page-header-text {
  min-width: 0;
  flex: 1 1 auto;
}

.community-header h2 {
  margin: 4px 0 0;
  font-size: clamp(1.5rem, 2.4vw, 2rem);
  line-height: 1.15;
  color: var(--cream);
}

.community-header .eyebrow {
  margin: 0;
}

.community-header .page-header-text > p:last-child {
  max-width: 56ch;
  margin: 10px 0 0;
  font-size: 0.95rem;
  line-height: 1.65;
  color: var(--muted);
}

/* Buttons in their own group, wrapping to a new line rather than being forced
   into the text column. */
.community-header-actions {
  display: flex;
  flex: 0 0 auto;
  flex-wrap: wrap;
  gap: 10px;
}

.community-section .btn,
.community-section .btn-gold {
  margin-top: 0;
}

.community-card {
  text-decoration: none;
}

.community-card-main {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
  width: 100%;
  color: inherit;
  text-decoration: none;
}

.community-card small a {
  color: var(--gold);
  text-decoration: none;
}

.community-card small a:hover {
  text-decoration: underline;
}

.community-card-mark {
  width: 100%;
  height: 120px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 8px;
  background: var(--thumb-bg);
  color: var(--gold-bright);
  font-size: 2.4rem;
  font-weight: 800;
}

.community-card small {
  color: var(--muted);
  font-size: 0.72rem;
  letter-spacing: 0.04em;
}

.opening-card.draft::after,
.opening-card.live::after {
  position: absolute;
  top: 10px;
  right: 10px;
  padding: 3px 7px;
  font-size: 0.58rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--on-gold);
  background: var(--gold);
  border-radius: 6px;
}

.opening-card.draft::after { content: "Draft"; }
.opening-card.live::after { content: "Published"; }

.mine-card {
  cursor: default;
}

.mine-card:hover {
  transform: none;
}

.mine-card-actions {
  display: flex;
  gap: 10px;
  margin-top: 4px;
}

.mine-card-actions a,
.mine-card-actions .repertoire-action,
.course-manage a,
.course-manage .repertoire-action {
  color: var(--gold-bright);
  font-size: 0.72rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  text-decoration: none;
  font-weight: 700;
  padding: 0;
  border: 0;
  background: transparent;
  font-family: var(--font);
  cursor: pointer;
}

.mine-card-actions a:hover,
.mine-card-actions .repertoire-action:hover,
.course-manage a:hover,
.course-manage .repertoire-action:hover {
  text-decoration: underline;
}

.mine-card-actions .repertoire-action.danger,
.course-manage .repertoire-action.danger {
  color: #ff9aa8;
}

.mine-card-actions .repertoire-action-disabled,
.course-manage .repertoire-action-disabled {
  color: var(--muted);
  font-size: 0.68rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.repertoire-view .page-header {
  max-width: none;
}

.repertoire-view .page-header h1 {
  margin: 6px 0 10px;
}

.repertoire-hero {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  justify-content: space-between;
  gap: 22px 28px;
  margin-bottom: 32px;
}

.repertoire-hero-copy {
  max-width: 640px;
}

.repertoire-hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-bottom: 6px;
}

.repertoire-unlimited-promo {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 16px 24px;
  margin: 0 0 28px;
  padding: 18px 20px;
  border-radius: 16px;
  border: 1px solid color-mix(in srgb, var(--gold) 42%, var(--line));
  background:
    radial-gradient(ellipse 70% 90% at 0% 50%, color-mix(in srgb, var(--gold) 16%, transparent), transparent 55%),
    linear-gradient(120deg, color-mix(in srgb, var(--gold) 8%, var(--panel)), var(--panel));
  box-shadow:
    inset 0 1px 0 color-mix(in srgb, var(--gold) 20%, transparent),
    0 12px 28px rgba(0, 0, 0, 0.16);
  animation: repertoire-unlimited-in 0.55s cubic-bezier(0.22, 1, 0.36, 1) both;
}

.repertoire-unlimited-promo-copy {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 8px;
  min-width: min(100%, 28rem);
  max-width: 40rem;
}

.repertoire-unlimited-promo .studio-unlimited-badge {
  display: inline-flex;
  align-items: center;
  padding: 4px 9px;
  border-radius: 999px;
  background: var(--gold);
  color: var(--on-gold);
  font-size: 0.68rem;
  font-weight: 800;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  animation: repertoire-unlimited-badge 1.8s ease-in-out infinite;
}

.repertoire-unlimited-promo h2 {
  margin: 0;
  font-size: 1.2rem;
  letter-spacing: -0.03em;
  color: var(--cream);
}

.repertoire-unlimited-promo p {
  margin: 0;
  color: var(--muted);
  font-size: 0.92rem;
  line-height: 1.5;
}

.repertoire-unlimited-promo strong {
  color: var(--gold-bright);
}

.studio-unlimited-was-inline {
  text-decoration: line-through;
  text-decoration-thickness: 1.5px;
  opacity: 0.78;
}

.repertoire-unlimited-promo .btn {
  flex: 0 0 auto;
}

@keyframes repertoire-unlimited-in {
  from {
    opacity: 0;
    transform: translateY(8px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes repertoire-unlimited-badge {
  0%, 100% { box-shadow: 0 0 0 0 color-mix(in srgb, var(--gold) 0%, transparent); }
  50% { box-shadow: 0 0 0 6px color-mix(in srgb, var(--gold) 18%, transparent); }
}

@media (prefers-reduced-motion: reduce) {
  .repertoire-unlimited-promo,
  .repertoire-unlimited-promo .studio-unlimited-badge {
    animation: none;
  }
}

.repertoire-courses {
  display: flex;
  flex-direction: column;
  gap: 2px;
  padding: 16px;
  border: 1px solid var(--line-strong);
  border-radius: 16px;
  background: var(--panel);
  box-shadow: none;
}

.course-card {
  display: flex;
  flex-direction: column;
  gap: 14px;
  min-width: 0;
  padding: 20px 20px 16px;
  border: 1px solid var(--line-strong);
  border-radius: 16px;
  background: var(--panel);
  box-shadow: none;
}

.course-card-top {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
}

.course-card h2 {
  margin: 6px 0 0;
  font-family: var(--serif);
  font-size: clamp(1.35rem, 2vw, 1.7rem);
  font-weight: 800;
  line-height: 1.15;
  letter-spacing: -0.02em;
  color: var(--cream);
}

.course-side {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin: 0;
  font-size: 0.68rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--gold);
  font-weight: 700;
}

.course-side-swatch {
  width: 12px;
  height: 12px;
  border-radius: 50%;
  border: 1px solid var(--line-strong);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.12);
}

.course-card--white .course-side-swatch {
  background: #f6f0e4;
}

.course-card--black .course-side-swatch {
  background: #1a1712;
}

.course-status {
  flex-shrink: 0;
  padding: 4px 9px;
  border-radius: 999px;
  font-size: 0.6rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  font-weight: 700;
}

.course-status--live {
  color: var(--on-gold);
  background: var(--gold);
}

.course-status--draft {
  color: var(--muted);
  border: 1px solid var(--line-strong);
  background: transparent;
}

.course-meta {
  margin: 0;
  color: var(--muted);
  font-size: 0.92rem;
  line-height: 1.5;
}

.course-practice {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
}

.course-practice .btn {
  width: 100%;
  padding-left: 10px;
  padding-right: 10px;
  letter-spacing: 0.1em;
}

.course-manage {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px 14px;
  padding-top: 12px;
  border-top: 1px solid var(--line);
}

.repertoire-empty {
  display: grid;
  grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.2fr);
  gap: 28px 36px;
  align-items: center;
  max-width: none;
  padding: 28px 26px;
  border: 1px solid var(--line-strong);
  border-radius: 16px;
  background: var(--panel);
  box-shadow: none;
}

.repertoire-empty h2 {
  margin: 0 0 10px;
  font-family: var(--serif);
  font-size: clamp(1.6rem, 2.4vw, 2.1rem);
  font-weight: 800;
  line-height: 1.15;
  color: var(--cream);
}

.repertoire-empty p:not(.eyebrow) {
  margin: 0 0 18px;
  color: var(--muted);
  line-height: 1.7;
}

.repertoire-intro {
  display: grid;
  grid-template-columns: minmax(0, 0.92fr) minmax(280px, 1.15fr);
  gap: 32px 40px;
  align-items: center;
  margin-bottom: 40px;
}

.repertoire-intro-copy {
  max-width: 36rem;
}

.repertoire-intro-copy h1 {
  margin: 6px 0 14px;
}

.repertoire-intro-copy > p {
  margin: 0;
  font-size: 1.05rem;
}

.repertoire-intro-shot {
  margin: 0;
  overflow: hidden;
  border: 1px solid var(--line-strong);
  border-radius: 16px;
  background: var(--panel);
  box-shadow: none;
}

.repertoire-intro-shot a {
  display: block;
  color: inherit;
  text-decoration: none;
}

.repertoire-guest-points {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
  margin-bottom: 48px;
}

.repertoire-guest-points a.repertoire-guest-card {
  padding: 22px 20px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: var(--panel);
  box-shadow: none;
  text-decoration: none;
  color: inherit;
  cursor: pointer;
}

.repertoire-guest-points h2 {
  margin: 0 0 8px;
  font-family: var(--serif);
  font-size: 1.25rem;
  font-weight: 800;
  line-height: 1.25;
  color: var(--cream);
}

.repertoire-guest-points p:not(.eyebrow) {
  margin: 0;
  color: var(--muted);
  line-height: 1.65;
}

.repertoire-grid .mine-card-actions {
  flex-wrap: wrap;
}

.repertoire-showcase-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 16px;
}

.repertoire-showcase-list {
  display: flex;
  flex-direction: column;
  gap: 0;
  max-width: 1080px;
  padding: 8px 0 40px;
}

.repertoire-showcase {
  width: min(68%, 720px);
  margin: 0;
  padding: 10px 10px 12px;
  border: 1px solid var(--line-strong);
  border-radius: 16px;
  background: var(--panel);
}

.repertoire-showcase:nth-child(odd) {
  align-self: flex-start;
  transform: rotate(-1.8deg) translateX(-12px);
}

.repertoire-showcase:nth-child(even) {
  align-self: flex-end;
  transform: rotate(1.8deg) translateX(12px);
  margin-top: -56px;
}

.repertoire-showcase:nth-child(3) {
  margin-top: -40px;
}

.repertoire-showcase:nth-child(4) {
  margin-top: -56px;
}

@media (max-width: 980px) {
  .repertoire-intro,
  .repertoire-empty,
  .repertoire-guest-points {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 760px) {
  .all-openings-view {
    padding: 16px 0 32px;
  }

  .course-row.is-own {
    grid-template-columns: 72px minmax(0, 1fr);
  }

  .course-row-actions {
    grid-column: 1 / -1;
    justify-content: flex-start;
    padding-top: 4px;
  }

  .course-row-actions .btn {
    min-height: 40px;
  }

  .community-section .btn,
  .repertoire-hero-actions .btn,
  .repertoire-showcase-actions .btn,
  .repertoire-empty .btn,
  .repertoire-unlimited-promo .btn {
    width: 100%;
    min-height: 44px;
  }

  /* Stack the section header on a phone: beside each other there is no room
     for the copy, which is what pushed the buttons into a narrow strip. */
  .community-header {
    flex-direction: column;
    align-items: stretch;
    gap: 16px;
  }

  .community-header-actions {
    width: 100%;
  }

  .repertoire-guest-card {
    padding: 18px 16px;
  }

  .repertoire-intro-copy > p {
    font-size: 1rem;
    line-height: 1.6;
  }

  .course-row-actions a,
  .course-row-actions .repertoire-action {
    min-height: 40px;
    display: inline-flex;
    align-items: center;
  }

  .repertoire-showcase {
    width: 100%;
  }

  .repertoire-showcase:nth-child(odd),
  .repertoire-showcase:nth-child(even) {
    align-self: stretch;
    transform: none;
    margin-top: 0;
  }

  .repertoire-showcase + .repertoire-showcase {
    margin-top: 14px;
  }

  .course-practice {
    grid-template-columns: 1fr;
  }
}
