/* Intent: overlay spacing, paper body, in-page video posters. Does not replace live theme. */

.btn-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.85rem;
  align-items: stretch;
  margin: 0.75rem 0 0.25rem;
}

.btn-row .btn {
  margin: 0;
}

a.btn,
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  margin: 0.4rem 0.4rem 0.4rem 0;
  min-height: 48px;
  box-sizing: border-box;
}

@media (max-width: 720px) {
  .btn-row {
    flex-direction: column;
    gap: 0.75rem;
  }
  a.btn,
  .btn {
    display: flex;
    width: 100%;
    margin: 0 0 0.75rem 0;
  }
  .content-card p {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
  }
  .content-card p .btn {
    margin: 0;
  }
  .site-header nav {
    display: flex;
    flex-wrap: wrap;
    gap: 0.55rem 0.9rem;
  }
  .site-header nav a {
    display: inline-block;
    padding: 0.35rem 0;
  }
}

.paper-body {
  max-width: 46rem;
  margin: 0 auto;
  padding: 1.5rem 1.25rem 4rem;
  line-height: 1.65;
}
.paper-body h1 { font-size: 1.85rem; margin: 1.2rem 0 0.6rem; }
.paper-body h2 { font-size: 1.35rem; margin: 2rem 0 0.7rem; }
.paper-body figure.wp-fig { margin: 1.5rem 0; }
.paper-body figure.wp-fig img { width: 100%; height: auto; background: #111; }
.paper-body figcaption { font-size: 0.9rem; color: #888; margin-top: 0.4rem; }

.video-frame {
  position: relative;
  display: block;
  background: #111;
  aspect-ratio: 16 / 9;
}
.video-frame iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }
.video-play {
  position: absolute;
  inset: 0;
  display: block;
  color: #fff;
  text-decoration: none;
}
.video-play img { width: 100%; height: 100%; object-fit: cover; display: block; }
.video-play span {
  position: absolute;
  left: 50%;
  top: 50%;
  transform: translate(-50%, -50%);
  font-size: 2.4rem;
  background: rgba(0,0,0,0.45);
  border-radius: 50%;
  width: 3.2rem;
  height: 3.2rem;
  display: flex;
  align-items: center;
  justify-content: center;
}
.lecture-card { margin-bottom: 1.5rem; }

.notebook-pre {
  white-space: pre-wrap;
  overflow-x: auto;
  font-size: 0.92rem;
  line-height: 1.55;
  max-width: 100%;
}

.video-embed {
  position: relative;
  width: 100%;
  padding-bottom: 56.25%;
  margin: 0 0 12px;
  background: #111;
}
.video-embed iframe {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  border: 0;
  border-radius: 4px;
}
#lectures .section-text.visible { opacity: 1; transform: none; }
