@import url('https://fonts.googleapis.com/css2?family=Oswald:wght@300;400;500;600;700&family=Open+Sans:ital,wght@0,300;0,400;0,600;0,700;0,800;1,400&display=swap');

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

:root {
  /* Nav height is referenced by .hero too - change it here only. */
  --nav-h:         96px;

  --navbar-bg:     #3a5568;
  --teal:          #4cb6c8;
  --teal-hover:    #3aa3b5;
  --light-bg:      #e8f4f7;
  --about-bg:      #e0ebf2;
  --academy-bg:    #d1dce3;
  --footer-bg:     #3d4657;
  --footer-bottom: #1e2838;
  --text-dark:     #1a2535;
  --text-med:      #4a5568;
  --check-green:   #4aaa52;
  --x-red:         #d95555;
}

body {
  font-family: 'Open Sans', sans-serif;
  color: var(--text-dark);
}

/* ===================== NAVBAR ===================== */
.navbar {
  background: var(--navbar-bg);
  display: flex;
  align-items: center;
  padding: 0 40px;
  height: var(--nav-h);
  position: sticky;
  top: 0;
  z-index: 1000;
  gap: 40px;
}

.logo {
  color: white;
  text-decoration: none;
  font-family: 'Oswald', sans-serif;
  font-weight: 700;
  font-size: 26px;
  letter-spacing: 1.5px;
  white-space: nowrap;
  flex-shrink: 0;
}

.logo .cred {
  font-weight: 300;
  font-size: 20px;
  letter-spacing: 0;
  margin-left: 4px;
}

.nav-links {
  display: flex;
  align-items: center;
  flex: 1;
  gap: 4px;
}

.nav-links a {
  color: rgba(255, 255, 255, 0.88);
  text-decoration: none;
  font-size: 15px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  padding: 0 18px;
  white-space: nowrap;
  transition: color 0.2s;
}

.nav-links a:hover {
  color: white;
}

.nav-right {
  display: flex;
  align-items: center;
  gap: 20px;
  margin-left: auto;
  flex-shrink: 0;
}

.btn-insider {
  background: var(--teal);
  color: white;
  border: none;
  padding: 13px 30px;
  border-radius: 50px;
  font-size: 15px;
  font-weight: 700;
  letter-spacing: 0.8px;
  cursor: pointer;
  text-decoration: none;
  display: inline-block;
  transition: background 0.2s;
  white-space: nowrap;
}

.btn-insider:hover {
  background: var(--teal-hover);
  color: white;
}

.nav-user {
  color: rgba(255, 255, 255, 0.8);
  font-size: 30px;
  cursor: pointer;
  background: none;
  border: none;
  display: flex;
  align-items: center;
  line-height: 1;
  transition: color 0.2s;
}

.nav-user:hover {
  color: white;
}

/* Hamburger - hidden above the mobile breakpoint (see the media block at the
   end of this file, which is what actually reveals it). */
.nav-toggle {
  display: none;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  width: 44px;
  height: 44px;
  padding: 0;
  background: none;
  border: none;
  cursor: pointer;
  flex-shrink: 0;
}

.nav-toggle-bar {
  display: block;
  width: 24px;
  height: 2px;
  background: white;
  transition: transform 0.25s, opacity 0.2s;
}

/* Bars morph into an X while the panel is open. */
body.nav-open .nav-toggle-bar:nth-child(1) { transform: translateY(7px) rotate(45deg); }
body.nav-open .nav-toggle-bar:nth-child(2) { opacity: 0; }
body.nav-open .nav-toggle-bar:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* ===================== HERO ===================== */
.hero {
  position: relative;
  height: calc(100vh - var(--nav-h));
  min-height: 520px;
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
  background: #1e2c38;
}

.hero-video {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  z-index: 0;
}

.hero-overlay {
  position: absolute;
  inset: 0;
  background: rgba(20, 32, 44, 0.58);
  z-index: 1;
}

.hero-content {
  position: relative;
  z-index: 2;
  text-align: center;
  color: white;
  padding: 20px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
}

.hero-tag {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 22px;
  font-family: 'Open Sans', sans-serif;
  font-weight: 600;
  font-size: 18px;
  letter-spacing: 3.5px;
  text-transform: uppercase;
}

.tag-line {
  width: 90px;
  height: 2px;
  background: white;
  display: inline-block;
  flex-shrink: 0;
}

.hero-title {
  font-family: 'Oswald', sans-serif;
  font-weight: 700;
  font-size: clamp(60px, 8vw, 108px);
  line-height: 1;
  text-transform: uppercase;
  margin: 4px 0;
  letter-spacing: 2px;
}

.hero-title .phd {
  font-weight: 400;
  font-size: clamp(34px, 4.5vw, 58px);
  letter-spacing: 0;
}

.hero-btn {
  margin-top: 32px;
  padding: 18px 56px;
  font-size: 15px;
  letter-spacing: 1.5px;
}

/* ===================== LOGOS CAROUSEL ===================== */
.logos-section {
  background: var(--light-bg);
  padding: 30px 0 34px;
}

.logos-heading {
  text-align: center;
  font-style: italic;
  font-weight: 600;
  font-size: 19px;
  color: #6b7b88;
  margin-bottom: 22px;
  padding: 0 20px;
}

.logos-row {
  display: flex;
  align-items: center;
}

.carousel-btn {
  background: none;
  border: none;
  font-size: 22px;
  cursor: pointer;
  padding: 0 22px;
  color: #6b7b88;
  flex-shrink: 0;
  transition: color 0.2s, opacity 0.2s;
  line-height: 1;
}

.carousel-btn:hover {
  color: #223140;
}

.carousel-btn[disabled] {
  opacity: 0.25;
  cursor: default;
}

/* Native horizontal scrolling: handles variable-width logos and gives touch
   swipe for free. The old transform-based version assumed every item was the
   same width, which real logos are not. */
.logos-track-wrapper {
  flex: 1;
  overflow-x: auto;
  overflow-y: hidden;
  /* Deliberately NOT scroll-behavior: smooth - the loop advances by writing
     scrollLeft every frame, and smooth would animate each write and stutter.
     The arrow buttons opt into smoothness per-call instead. */
  scrollbar-width: none;          /* Firefox */
  -ms-overflow-style: none;       /* old Edge */
  overscroll-behavior-x: contain;
}

.logos-track-wrapper::-webkit-scrollbar {
  display: none;                  /* Chrome / Safari */
}

.logos-track {
  display: flex;
  align-items: center;
  gap: 44px;
  width: max-content;
}

/* Fixed box per logo so wildly different aspect ratios all read as one row. */
.logo-item {
  flex: 0 0 auto;
  width: 190px;
  height: 92px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.logo-item img {
  max-width: 100%;
  max-height: 100%;
  width: auto;
  height: auto;
  object-fit: contain;
  display: block;
}

@media (prefers-reduced-motion: reduce) {
  .logos-track-wrapper { scroll-behavior: auto; }
}

/* ===================== ABOUT SECTION ===================== */
.about-section {
  background: var(--about-bg);
  padding: 72px 0;
}

.container {
  max-width: 1100px;
  margin: 0 auto;
  padding: 0 36px;
}

.about-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 64px;
  align-items: start;
}

.about-video video {
  width: 100%;
  height: auto;
  display: block;
  background: #1a2535;
}

/* YouTube / video embed - responsive 16:9 */
.video-embed-wrap {
  position: relative;
  width: 100%;
  padding-bottom: 56.25%;
  height: 0;
  overflow: hidden;
  background: #1a2535;
}

.video-embed-wrap iframe {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  border: none;
}

/* Click-to-play facade - keeps YouTube's title/branding chrome off the page and
   defers loading the third-party iframe until someone actually wants the video. */
.video-facade {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  padding: 0;
  border: none;
  cursor: pointer;
  background: #1a2535 center/cover no-repeat;
  display: block;
}

.video-facade::after {
  content: '';
  position: absolute;
  inset: 0;
  background: rgba(20, 32, 44, 0.28);
  transition: background 0.25s;
}

.video-facade:hover::after {
  background: rgba(20, 32, 44, 0.12);
}

.video-facade .play-btn {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  z-index: 2;
  width: 84px;
  height: 84px;
  border-radius: 50%;
  background: var(--teal);
  color: white;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 30px;
  padding-left: 5px; /* optically centres the triangle glyph */
  box-shadow: 0 6px 24px rgba(0, 0, 0, 0.35);
  transition: transform 0.25s, background 0.25s;
}

.video-facade:hover .play-btn {
  transform: translate(-50%, -50%) scale(1.08);
  background: var(--teal-hover);
}

.video-facade:focus-visible {
  outline: 3px solid var(--teal);
  outline-offset: 3px;
}

.video-coming-soon {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 12px;
  color: rgba(255, 255, 255, 0.4);
}

.video-coming-soon i {
  font-size: 48px;
}

.video-coming-soon p {
  font-size: 14px;
  letter-spacing: 1px;
  text-align: center;
}

.about-text h2 {
  font-family: 'Open Sans', sans-serif;
  font-weight: 700;
  font-size: 27px;
  color: var(--text-dark);
  margin-bottom: 18px;
  text-align: center;
}

.about-text p {
  font-size: 14.5px;
  line-height: 1.75;
  color: #2a3545;
  text-align: justify;
}

/* ===================== INSIDER SECTION ===================== */
.insider-section {
  background: var(--light-bg);
  padding: 72px 36px 80px;
  text-align: center;
}

.insider-section h2 {
  font-family: 'Open Sans', sans-serif;
  font-size: 48px;
  font-weight: 800;
  color: var(--text-dark);
  margin-bottom: 10px;
}

.insider-subtitle {
  font-size: 15px;
  color: #666;
  margin-bottom: 52px;
}

.insider-table {
  width: 100%;
  max-width: 860px;
  margin: 0 auto;
  border-collapse: collapse;
}

.insider-table thead th {
  padding: 0 24px 28px;
  vertical-align: bottom;
}

.insider-table thead th:first-child {
  width: 54%;
}

.insider-table thead th:not(:first-child) {
  width: 23%;
}

.plan-label {
  display: block;
  font-size: 17px;
  font-weight: 700;
  letter-spacing: 2px;
  color: #444;
  margin-bottom: 2px;
}

.plan-sub {
  display: block;
  font-size: 11.5px;
  font-weight: 600;
  letter-spacing: 1.5px;
  color: #666;
  margin-bottom: 4px;
}

.plan-price {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2px;
  font-size: 26px;
  font-weight: 700;
  color: var(--text-dark);
  margin-bottom: 14px;
  line-height: 1.2;
}

.plan-price .per {
  font-size: 14px;
  font-weight: 400;
}

.plan-original {
  font-size: 16px;
  font-weight: 600;
  color: #e05252;
  text-decoration: line-through;
  text-decoration-color: #e05252;
  text-decoration-thickness: 2px;
}

.btn-subscribe {
  background: var(--teal);
  color: white;
  border: none;
  padding: 12px 30px;
  border-radius: 50px;
  font-size: 12.5px;
  font-weight: 700;
  letter-spacing: 1px;
  cursor: pointer;
  text-decoration: none;
  display: inline-block;
  transition: background 0.2s;
}

.btn-subscribe:hover {
  background: var(--teal-hover);
  color: white;
}

.insider-table tbody tr:nth-child(odd) td {
  background: rgba(200, 215, 225, 0.28);
}

.insider-table tbody tr:nth-child(even) td {
  background: rgba(232, 244, 247, 0.5);
}

.insider-table td {
  padding: 16px 24px;
  font-size: 13.5px;
  color: #3a4a58;
  border-top: 1px solid rgba(180, 200, 215, 0.5);
  vertical-align: middle;
}

.feature-col {
  text-align: left;
}

.check-col {
  text-align: center;
}

.check-icon {
  color: var(--check-green);
  font-size: 22px;
  font-weight: 700;
  line-height: 1;
}

.x-icon {
  color: var(--x-red);
  font-size: 18px;
  font-weight: 700;
  line-height: 1;
}

/* ===================== ACADEMY SECTION ===================== */
.academy-section {
  background: var(--academy-bg);
  padding: 72px 0;
}

.academy-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 64px;
  align-items: center;
}

.academy-text h2 {
  font-family: 'Open Sans', sans-serif;
  font-size: 24px;
  font-weight: 700;
  color: var(--text-dark);
  margin-bottom: 20px;
  text-align: center;
}

.academy-text p {
  font-size: 14.5px;
  line-height: 1.78;
  color: #2a3545;
  text-align: justify;
  margin-bottom: 32px;
}

.btn-learn {
  background: var(--teal);
  color: white;
  text-decoration: none;
  padding: 16px 48px;
  border-radius: 50px;
  font-size: 14px;
  font-weight: 700;
  letter-spacing: 1.5px;
  display: inline-block;
  transition: background 0.2s;
}

.btn-learn:hover {
  background: var(--teal-hover);
  color: white;
}

.academy-image img {
  width: 100%;
  height: auto;
  display: block;
  background: #1a2535;
  min-height: 280px;
}

.img-placeholder {
  width: 100%;
  min-height: 300px;
  background: #1a2535;
  display: flex;
  align-items: center;
  justify-content: center;
  color: rgba(255,255,255,0.3);
  font-size: 14px;
}

/* ===================== FOOTER ===================== */
footer {
  background: var(--footer-bg);
}

.footer-main {
  max-width: 1200px;
  margin: 0 auto;
  padding: 52px 44px;
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
}

.footer-left {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 0;
}

.footer-logo {
  color: white;
  font-family: 'Oswald', sans-serif;
  font-weight: 700;
  font-size: 19px;
  letter-spacing: 1.5px;
  text-decoration: none;
  display: inline-block;
  margin-bottom: 22px;
}

.footer-logo .cred {
  font-weight: 300;
  font-size: 15px;
  letter-spacing: 0;
}

.social-icons {
  display: flex;
  gap: 18px;
  margin-bottom: 22px;
}

.social-icons a {
  color: #8a9ab2;
  font-size: 22px;
  text-decoration: none;
  transition: color 0.2s;
  line-height: 1;
}

.social-icons a:hover {
  color: white;
}

.btn-youtube {
  background: var(--teal);
  color: white;
  text-decoration: none;
  padding: 14px 28px;
  border-radius: 50px;
  font-size: 12.5px;
  font-weight: 700;
  letter-spacing: 1px;
  display: inline-block;
  transition: background 0.2s;
  text-align: center;
  line-height: 1.4;
}

.btn-youtube:hover {
  background: var(--teal-hover);
  color: white;
}

/* Single vertical column. This was a two-column grid with one full-width
   centred item, which staggered the links into an arbitrary-looking shape. */
/* The block sits on the right (pushed there by .footer-main's space-between),
   but the link text is left-aligned inside it. Right-aligning the text gives a
   ragged left edge, which is what made the list look haphazard. */
.footer-nav {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 13px;
  padding-top: 4px;
}

.footer-nav a {
  color: rgba(255, 255, 255, 0.72);
  text-decoration: none;
  font-size: 14px;
  transition: color 0.2s;
}

.footer-nav a:hover {
  color: white;
}

/* .full-row is a leftover from the old two-column grid. Neutralised rather than
   stripped from the markup, since the class appears in the footer of every page. */
.footer-nav a.full-row {
  text-align: inherit;
}

.footer-bottom {
  background: var(--footer-bottom);
  text-align: center;
  padding: 18px;
  color: rgba(255, 255, 255, 0.55);
  font-size: 13px;
}

/* ===================== COLLEGE OF GLYCATION ===================== */
.episodes-section {
  background: white;
  padding: 80px 36px 100px;
}

.episodes-header {
  max-width: 900px;
  margin: 0 auto 56px;
  text-align: center;
}

.episodes-header h2 {
  font-family: 'Open Sans', sans-serif;
  font-weight: 800;
  font-size: 44px;
  color: var(--navbar-bg);
  margin-bottom: 18px;
}

.episodes-header p {
  font-size: 17px;
  line-height: 1.7;
  color: var(--text-med);
}

.episode-grid {
  max-width: 1240px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 32px;
}

.episode-card {
  display: flex;
  flex-direction: column;
  background: #f7f9fa;
  border: 1px solid #e2e8ec;
  overflow: hidden;
  transition: transform 0.2s, box-shadow 0.2s;
}

.episode-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 12px 28px rgba(30, 45, 60, 0.14);
}

.episode-thumb {
  position: relative;
  display: block;
  aspect-ratio: 16 / 9;
  background: var(--navbar-bg) center/cover no-repeat;
  overflow: hidden;
}

.episode-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.episode-number {
  position: absolute;
  top: 0;
  right: 0;
  background: var(--navbar-bg);
  color: white;
  font-family: 'Oswald', sans-serif;
  font-weight: 600;
  font-size: 13px;
  letter-spacing: 1.4px;
  padding: 8px 14px;
  z-index: 2;
}

.episode-thumb .play-overlay {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(20, 32, 44, 0.25);
  color: white;
  font-size: 44px;
  opacity: 0;
  transition: opacity 0.22s;
}

.episode-card:hover .play-overlay {
  opacity: 1;
}

.episode-body {
  padding: 24px 24px 28px;
  display: flex;
  flex-direction: column;
  flex: 1;
  gap: 10px;
}

.episode-body h3 {
  font-family: 'Open Sans', sans-serif;
  font-weight: 700;
  font-size: 21px;
  line-height: 1.3;
  color: var(--navbar-bg);
}

.episode-body h3 a {
  color: inherit;
  text-decoration: none;
}

.episode-body h3 a:hover {
  color: var(--teal-hover);
}

.episode-date {
  font-size: 13px;
  color: #8a97a3;
}

.episode-excerpt {
  font-size: 15px;
  line-height: 1.65;
  color: var(--text-med);
  flex: 1;
}

.episode-watch {
  align-self: flex-start;
  margin-top: 8px;
  padding: 11px 26px;
  border: 2px solid var(--teal);
  border-radius: 50px;
  color: var(--teal-hover);
  background: none;
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 1px;
  text-decoration: none;
  transition: background 0.2s, color 0.2s;
}

.episode-watch:hover {
  background: var(--teal);
  color: white;
}

.episodes-cta {
  text-align: center;
  margin-top: 64px;
}

.btn-channel {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  background: #c4302b;
  color: white;
  padding: 18px 46px;
  border-radius: 50px;
  font-size: 15px;
  font-weight: 700;
  letter-spacing: 1.2px;
  text-decoration: none;
  transition: background 0.2s;
}

.btn-channel:hover {
  background: #a82722;
  color: white;
}

.btn-channel i {
  font-size: 24px;
}

/* Loading / empty / error states for the grid */
.episode-skeleton {
  background: #eef2f4;
  border: 1px solid #e2e8ec;
  min-height: 380px;
  animation: episodePulse 1.4s ease-in-out infinite;
}

@keyframes episodePulse {
  0%, 100% { opacity: 1; }
  50%      { opacity: 0.55; }
}

.episodes-message {
  grid-column: 1 / -1;
  text-align: center;
  padding: 60px 20px;
  color: var(--text-med);
  font-size: 16px;
  line-height: 1.7;
}

.episodes-message i {
  display: block;
  font-size: 40px;
  color: #b6c2cb;
  margin-bottom: 16px;
}

/* ===================== SPEAKING PAGE ===================== */
/* Single centred column. Without a supporting image, a two-column hero leaves
   an obvious empty half - centring makes the shorter page read as deliberate. */
.speaking-hero-section {
  background: var(--light-bg);
  padding: 90px 36px 96px;
}

.speaking-hero-text {
  max-width: 780px;
  margin: 0 auto;
  text-align: center;
}

.speaking-hero-text h1 {
  font-family: 'Open Sans', sans-serif;
  font-weight: 800;
  font-size: clamp(30px, 3.6vw, 48px);
  line-height: 1.18;
  color: var(--navbar-bg);
  margin-bottom: 24px;
}

.speaking-hero-text p {
  font-size: 18px;
  line-height: 1.8;
  color: var(--text-med);
  margin: 0 auto 36px;
  max-width: 660px;
}

/* Outlined pill CTA - deliberately lighter than the solid teal Insider button
   so the two don't compete on the same page. */
.btn-outline {
  display: inline-block;
  padding: 16px 38px;
  border: 2px solid var(--teal);
  border-radius: 50px;
  color: var(--navbar-bg);
  background: none;
  font-size: 14px;
  font-weight: 700;
  letter-spacing: 1.2px;
  text-decoration: none;
  transition: background 0.2s, color 0.2s;
}

.btn-outline:hover {
  background: var(--teal);
  color: white;
}

.speaking-events {
  background: white;
  padding: 70px 36px 96px;
  text-align: center;
}

.speaking-events h2 {
  font-family: 'Open Sans', sans-serif;
  font-weight: 800;
  font-size: clamp(28px, 3vw, 40px);
  color: var(--navbar-bg);
  margin-bottom: 18px;
}

.events-empty {
  font-style: italic;
  font-weight: 700;
  font-size: 20px;
  color: #b3392f;
}

@media (max-width: 900px) {
  .speaking-hero-section { padding: 54px 22px 60px; }
  .speaking-hero-text p { font-size: 16px; }
  .speaking-events { padding: 50px 22px 70px; }
}

/* ===================== CONTACT PAGE ===================== */
.contact-section {
  background: var(--light-bg);
  padding: 80px 36px;
  min-height: 70vh;
}

.contact-grid {
  max-width: 980px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 70px;
  align-items: start;
}

.contact-left h1 {
  font-size: 30px;
  font-weight: 700;
  color: var(--text-dark);
  margin-bottom: 18px;
}

.contact-left p {
  font-size: 14px;
  color: #555;
  line-height: 1.65;
}

.contact-form {
  display: flex;
  flex-direction: column;
}

.form-group {
  margin-bottom: 18px;
}

.form-label {
  display: block;
  font-size: 14px;
  font-weight: 600;
  color: var(--text-dark);
  margin-bottom: 8px;
}

.form-label .req {
  color: #d95555;
  margin-left: 2px;
}

.name-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
}

.field-wrap {
  display: flex;
  flex-direction: column;
}

.form-input {
  width: 100%;
  padding: 11px 13px;
  border: 1px solid #c8d8e2;
  border-radius: 2px;
  font-size: 14px;
  font-family: 'Open Sans', sans-serif;
  background: white;
  color: var(--text-dark);
  transition: border-color 0.2s;
}

.form-input:focus {
  outline: none;
  border-color: var(--teal);
}

.sub-label {
  font-size: 11px;
  color: #888;
  margin-top: 4px;
  font-weight: 400;
}

textarea.form-input {
  min-height: 130px;
  resize: vertical;
  background: #fff6f6;
}

.btn-submit {
  align-self: flex-start;
  margin-top: 8px;
  background: var(--teal);
  color: white;
  border: none;
  padding: 13px 44px;
  border-radius: 50px;
  font-size: 15px;
  font-weight: 600;
  font-family: 'Open Sans', sans-serif;
  cursor: pointer;
  transition: background 0.2s;
}

.btn-submit:hover {
  background: var(--teal-hover);
}

/* ===================== AUTH CARD (login / signup) ===================== */
.auth-page {
  background: var(--light-bg);
  min-height: calc(100vh - var(--nav-h));
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 48px 20px;
}

.auth-card {
  background: white;
  border-radius: 6px;
  box-shadow: 0 4px 24px rgba(58, 85, 104, 0.12);
  padding: 44px 44px 36px;
  width: 100%;
  max-width: 460px;
}

.auth-card .card-logo {
  text-align: center;
  margin-bottom: 24px;
}

.auth-card .card-logo a {
  font-family: 'Oswald', sans-serif;
  font-weight: 700;
  font-size: 18px;
  letter-spacing: 1.5px;
  color: var(--navbar-bg);
  text-decoration: none;
}

.auth-card .card-logo a .cred {
  font-weight: 300;
  font-size: 14px;
}

.auth-card h2 {
  font-size: 22px;
  font-weight: 700;
  color: var(--text-dark);
  margin-bottom: 6px;
  text-align: center;
}

.auth-card .auth-sub {
  font-size: 13.5px;
  color: #666;
  text-align: center;
  margin-bottom: 28px;
}

.auth-form .form-group {
  margin-bottom: 16px;
}

.auth-form .form-label {
  display: block;
  font-size: 13px;
  font-weight: 600;
  color: var(--text-dark);
  margin-bottom: 6px;
}

.auth-form .form-input {
  width: 100%;
  padding: 11px 13px;
  border: 1px solid #c8d8e2;
  border-radius: 3px;
  font-size: 14px;
  font-family: 'Open Sans', sans-serif;
  color: var(--text-dark);
  background: white;
  transition: border-color 0.2s;
}

.auth-form .form-input:focus {
  outline: none;
  border-color: var(--teal);
}

.auth-form .name-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}

.auth-error {
  background: #fef2f2;
  border: 1px solid #fca5a5;
  border-radius: 3px;
  color: #b91c1c;
  font-size: 13px;
  padding: 10px 14px;
  margin-bottom: 16px;
  display: none;
}

.auth-error.visible {
  display: block;
}

.btn-auth {
  width: 100%;
  padding: 13px;
  background: var(--teal);
  color: white;
  border: none;
  border-radius: 50px;
  font-size: 14px;
  font-weight: 700;
  font-family: 'Open Sans', sans-serif;
  letter-spacing: 1px;
  cursor: pointer;
  transition: background 0.2s;
  margin-top: 8px;
}

.btn-auth:hover {
  background: var(--teal-hover);
}

.btn-auth:disabled {
  opacity: 0.6;
  cursor: not-allowed;
}

.auth-links {
  text-align: center;
  margin-top: 20px;
  font-size: 13px;
  color: #666;
}

.auth-links a {
  color: var(--teal);
  text-decoration: none;
  font-weight: 600;
}

.auth-links a:hover {
  color: var(--teal-hover);
}

.auth-divider {
  text-align: center;
  font-size: 12px;
  color: #aaa;
  margin: 16px 0;
  position: relative;
}

.auth-divider::before,
.auth-divider::after {
  content: '';
  position: absolute;
  top: 50%;
  width: 38%;
  height: 1px;
  background: #dde;
}

.auth-divider::before { left: 0; }
.auth-divider::after  { right: 0; }

/* ===================== ACCOUNT PAGE ===================== */
.account-section {
  background: var(--light-bg);
  min-height: calc(100vh - var(--nav-h));
  padding: 64px 36px;
}

.account-wrap {
  max-width: 680px;
  margin: 0 auto;
}

.account-wrap h1 {
  font-size: 28px;
  font-weight: 700;
  color: var(--text-dark);
  margin-bottom: 32px;
}

.account-card {
  background: white;
  border-radius: 6px;
  box-shadow: 0 2px 16px rgba(58, 85, 104, 0.1);
  padding: 28px 32px;
  margin-bottom: 20px;
}

.account-card h3 {
  font-size: 15px;
  font-weight: 700;
  color: var(--text-dark);
  margin-bottom: 16px;
  padding-bottom: 12px;
  border-bottom: 1px solid #e5eef3;
}

.account-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 8px 0;
  font-size: 14px;
  color: #444;
}

.account-row .label {
  font-weight: 600;
  color: var(--text-dark);
}

.status-badge {
  display: inline-block;
  padding: 4px 14px;
  border-radius: 50px;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.5px;
}

.status-badge.active   { background: #d1fae5; color: #065f46; }
.status-badge.inactive { background: #fee2e2; color: #991b1b; }
.status-badge.trialing { background: #dbeafe; color: #1e40af; }
.status-badge.past_due { background: #fef3c7; color: #92400e; }

.btn-account {
  display: inline-block;
  padding: 11px 28px;
  border-radius: 50px;
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.5px;
  cursor: pointer;
  text-decoration: none;
  border: none;
  font-family: 'Open Sans', sans-serif;
  transition: background 0.2s, color 0.2s;
  margin-top: 16px;
  margin-right: 10px;
}

.btn-account.primary {
  background: var(--teal);
  color: white;
}

.btn-account.primary:hover {
  background: var(--teal-hover);
  color: white;
}

.btn-account.outline {
  background: transparent;
  color: var(--text-dark);
  border: 1.5px solid #c8d8e2;
}

.btn-account.outline:hover {
  border-color: var(--teal);
  color: var(--teal);
}

/* ===================== INSIDER DASHBOARD ===================== */
.insider-hero {
  background: var(--navbar-bg);
  padding: 52px 36px;
  text-align: center;
  color: white;
}

.insider-hero h1 {
  font-family: 'Oswald', sans-serif;
  font-weight: 700;
  font-size: 42px;
  letter-spacing: 2px;
  margin-bottom: 8px;
}

.insider-hero p {
  font-size: 15px;
  opacity: 0.8;
}

.insider-badge {
  display: inline-block;
  background: var(--teal);
  color: white;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 1.5px;
  padding: 4px 14px;
  border-radius: 50px;
  margin-bottom: 16px;
}

.insider-dashboard {
  background: var(--light-bg);
  padding: 56px 36px;
  min-height: 60vh;
}

.insider-grid {
  max-width: 1060px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 24px;
}

.insider-card {
  background: white;
  border-radius: 6px;
  box-shadow: 0 2px 16px rgba(58, 85, 104, 0.09);
  padding: 28px;
  display: flex;
  flex-direction: column;
  gap: 12px;
  transition: box-shadow 0.2s;
}

.insider-card:hover {
  box-shadow: 0 6px 24px rgba(58, 85, 104, 0.15);
}

.insider-card .card-icon {
  width: 44px;
  height: 44px;
  background: var(--light-bg);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--teal);
  font-size: 20px;
}

.insider-card h3 {
  font-size: 16px;
  font-weight: 700;
  color: var(--text-dark);
}

.insider-card p {
  font-size: 13.5px;
  color: #555;
  line-height: 1.65;
  flex: 1;
}

.insider-card .card-tag {
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 1px;
  color: var(--teal);
  text-transform: uppercase;
}

.insider-card .card-tag.coming-soon {
  color: #aaa;
}

.btn-card {
  display: inline-block;
  padding: 9px 22px;
  background: var(--teal);
  color: white;
  border-radius: 50px;
  font-size: 12.5px;
  font-weight: 700;
  letter-spacing: 0.5px;
  text-decoration: none;
  cursor: pointer;
  border: none;
  font-family: 'Open Sans', sans-serif;
  transition: background 0.2s;
  align-self: flex-start;
}

.btn-card:hover {
  background: var(--teal-hover);
  color: white;
}

.btn-card.disabled {
  background: #c8d8e2;
  cursor: not-allowed;
}

/* ===================== SUCCESS / CANCEL PAGES ===================== */
.result-page {
  background: var(--light-bg);
  min-height: calc(100vh - var(--nav-h));
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 48px 20px;
}

.result-card {
  background: white;
  border-radius: 6px;
  box-shadow: 0 4px 24px rgba(58, 85, 104, 0.12);
  padding: 52px 44px;
  max-width: 500px;
  width: 100%;
  text-align: center;
}

.result-icon {
  font-size: 52px;
  margin-bottom: 20px;
  line-height: 1;
}

.result-icon.success { color: var(--check-green); }
.result-icon.cancel  { color: #aab; }

.result-card h2 {
  font-size: 26px;
  font-weight: 700;
  color: var(--text-dark);
  margin-bottom: 12px;
}

.result-card p {
  font-size: 15px;
  color: #555;
  line-height: 1.65;
  margin-bottom: 28px;
}

/* ===================== NEWSLETTER MODAL ===================== */
.modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(20, 32, 44, 0.55);
  z-index: 2000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.2s;
}

.modal-overlay.open {
  opacity: 1;
  pointer-events: all;
}

.modal-box {
  background: white;
  border-radius: 6px;
  padding: 40px;
  max-width: 420px;
  width: 100%;
  position: relative;
  transform: translateY(16px);
  transition: transform 0.2s;
}

/* Two-column variant: imagery on the left, form on the right. */
.modal-box.modal-split {
  display: grid;
  grid-template-columns: 1fr 1fr;
  max-width: 880px;
  padding: 0;
  overflow: hidden;
}

.modal-visual {
  background: var(--navbar-bg);
  overflow: hidden;
}

.modal-visual img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.modal-split .modal-content {
  padding: 48px 44px;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.modal-split h3 {
  font-size: 30px;
  line-height: 1.25;
  text-align: center;
  margin-bottom: 16px;
}

.modal-split .modal-content > p {
  text-align: center;
  font-size: 15px;
  line-height: 1.65;
  margin-bottom: 24px;
}

.modal-split .modal-form input {
  background: #f1f4f6;
  border: 1px solid transparent;
  padding: 15px 16px;
}

.modal-split .modal-form input:focus {
  background: white;
  border-color: var(--teal);
  outline: none;
}

/* Single column below the split breakpoint - side-by-side is unusable on a phone. */
@media (max-width: 820px) {
  .modal-box.modal-split { grid-template-columns: 1fr; max-width: 440px; }
  .modal-visual { max-height: 170px; }
  .modal-split .modal-content { padding: 32px 26px 34px; }
  .modal-split h3 { font-size: 24px; }
}

.modal-overlay.open .modal-box {
  transform: translateY(0);
}

.modal-close {
  position: absolute;
  top: 14px;
  right: 18px;
  background: none;
  border: none;
  font-size: 22px;
  cursor: pointer;
  color: #aaa;
  line-height: 1;
}

.modal-close:hover { color: #555; }

.modal-box h3 {
  font-size: 20px;
  font-weight: 700;
  color: var(--text-dark);
  margin-bottom: 6px;
}

.modal-box p {
  font-size: 13.5px;
  color: #666;
  margin-bottom: 20px;
  line-height: 1.6;
}

.modal-form {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.modal-form input {
  padding: 11px 14px;
  border: 1px solid #c8d8e2;
  border-radius: 3px;
  font-size: 14px;
  font-family: 'Open Sans', sans-serif;
  transition: border-color 0.2s;
}

.modal-form input:focus {
  outline: none;
  border-color: var(--teal);
}

.modal-success {
  text-align: center;
  padding: 16px 0;
  color: var(--check-green);
  font-weight: 600;
  font-size: 15px;
  display: none;
}

.modal-error {
  display: none;
  margin-top: 12px;
  padding: 11px 14px;
  background: #fdecec;
  border-left: 3px solid var(--x-red);
  color: #8c2f2f;
  font-size: 14px;
  line-height: 1.5;
}

.modal-consent {
  margin-top: 14px;
  font-size: 12px;
  line-height: 1.6;
  color: #8a97a3;
  text-align: center;
}


/* =========================================================================
   RESPONSIVE
   The site was built desktop-only - no media queries existed before this.
   Breakpoints: 1024 (tablet), 900 (nav collapse), 700 (phone), 420 (small).
   ========================================================================= */

/* Nothing should ever cause a sideways scroll.
 *
 * `overflow-x: hidden` here would ALSO silently disable position:sticky for
 * every descendant, because hidden makes this element a scroll container.
 * `clip` prevents the same overflow without that side effect. The hidden
 * fallback stays for browsers without clip support, which simply lose sticky. */
html, body { max-width: 100%; overflow-x: hidden; }

@supports (overflow: clip) {
  html, body { overflow-x: clip; }
}

img, video { max-width: 100%; }

/* ---------- Tablet ---------- */
@media (max-width: 1024px) {
  .navbar { padding: 0 24px; gap: 20px; }
  .nav-links a { padding: 0 12px; font-size: 14px; }
  .btn-insider { padding: 11px 22px; font-size: 13px; }
  .logo { font-size: 22px; }
  .logo .cred { font-size: 17px; }

  .episode-grid { grid-template-columns: repeat(2, 1fr); gap: 24px; }
  .about-grid,
  .academy-grid,
  .contact-grid { gap: 40px; }
}

/* ---------- Nav collapses to a slide-down panel ---------- */
@media (max-width: 900px) {
  :root { --nav-h: 68px; }

  .nav-toggle { display: flex; order: -1; }

  .navbar {
    padding: 0 16px;
    gap: 12px;
    flex-wrap: wrap;
  }

  .logo { font-size: 19px; }
  .logo .cred { font-size: 14px; }

  /* The panel lives below the bar; it is laid out but clipped until opened. */
  .nav-links {
    position: absolute;
    top: var(--nav-h);
    left: 0;
    right: 0;
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    background: var(--navbar-bg);
    border-top: 1px solid rgba(255, 255, 255, 0.12);
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.28s ease;
  }

  body.nav-open .nav-links {
    max-height: 80vh;
    overflow-y: auto;
  }

  .nav-links a {
    padding: 16px 20px;
    font-size: 15px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  }

  .nav-right { gap: 12px; }
  .btn-insider { padding: 9px 16px; font-size: 11px; letter-spacing: 0.5px; }
  .nav-user { font-size: 26px; }

  /* Two-column layouts stack. */
  .about-grid,
  .academy-grid,
  .contact-grid,
  .insider-dashboard { grid-template-columns: 1fr; gap: 36px; }

  /* Image-first on desktop reads better text-first once stacked. */
  .academy-image { order: -1; }

  .hero-tag { font-size: 14px; letter-spacing: 2px; gap: 14px; }
  .tag-line { width: 48px; }
  .hero-btn { margin-top: 24px; padding: 15px 40px; }


  .episodes-section { padding: 56px 20px 72px; }
  .episodes-header h2 { font-size: 32px; }
  .episodes-header { margin-bottom: 40px; }

  .container { padding: 0 20px; }
  .about-section { padding: 52px 0; }
}

/* ---------- Phone ---------- */
@media (max-width: 700px) {
  .episode-grid { grid-template-columns: 1fr; }
  .episode-skeleton { min-height: 300px; }

  .hero { min-height: 460px; }
  .hero-tag { font-size: 12px; letter-spacing: 1.5px; gap: 10px; }
  .tag-line { width: 28px; }

  .logo-item { width: 140px; height: 72px; }
  .logos-track { gap: 28px; }
  .carousel-btn { padding: 0 12px; font-size: 18px; }

  /* A 3-column comparison table cannot fit a phone. Let it scroll sideways
     inside its own container rather than blowing out the page width. */
  .insider-section { padding-left: 0; padding-right: 0; }
  .insider-table {
    display: block;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    white-space: normal;
    min-width: 100%;
  }
  .insider-table tbody,
  .insider-table thead { display: table; width: 100%; min-width: 520px; }
  .insider-section h2 { font-size: 30px; padding: 0 20px; }
  .insider-subtitle { padding: 0 20px; font-size: 15px; }

  /* Footer stacks and centres. It's flex, not grid. */
  .footer-main { flex-direction: column; align-items: center; gap: 32px; text-align: center; padding: 40px 20px; }
  .footer-left { align-items: center; }
  .social-icons { justify-content: center; }
  .footer-nav { align-items: center; text-align: center; }

  .auth-card { padding: 32px 24px; }
  .account-section { padding: 40px 20px; }
  .contact-section { padding: 44px 20px; }
  .speaking-content { padding: 60px 20px; }

  .modal-box { padding: 28px 22px; }
}

/* ---------- Small phones ---------- */
@media (max-width: 420px) {
  .logo { font-size: 16px; letter-spacing: 1px; }
  .logo .cred { font-size: 12px; }
  .btn-insider { padding: 8px 12px; font-size: 10px; }
  .nav-user { font-size: 23px; }
  .hero-title { letter-spacing: 1px; }
  .logo-item { width: 120px; height: 64px; }
}

/* ===================== INSIDER CONTENT PAGES ===================== */
.insider-page {
  background: var(--light-bg);
  min-height: calc(100vh - var(--nav-h));
  padding: 56px 36px 80px;
}

.insider-page-head {
  max-width: 1240px;
  margin: 0 auto 36px;
}

.insider-back {
  display: inline-block;
  margin-bottom: 18px;
  color: var(--text-med);
  font-size: 14px;
  text-decoration: none;
}

.insider-back:hover { color: var(--navbar-bg); }

.insider-page-head h1 {
  font-size: 40px;
  color: var(--navbar-bg);
  margin-bottom: 10px;
}

.insider-page-head p {
  font-size: 16px;
  line-height: 1.7;
  color: var(--text-med);
  max-width: 720px;
}

.archive-toolbar {
  max-width: 1240px;
  margin: 0 auto 28px;
  display: flex;
  gap: 14px;
  align-items: center;
  flex-wrap: wrap;
}

.archive-search {
  flex: 1;
  min-width: 240px;
  padding: 13px 16px;
  border: 1px solid #c7d4dc;
  background: white;
  font-size: 15px;
  font-family: inherit;
  color: var(--text-dark);
}

.archive-search:focus {
  outline: none;
  border-color: var(--teal);
}

.archive-count {
  font-size: 14px;
  color: var(--text-med);
  white-space: nowrap;
}

.archive-notice {
  max-width: 1240px;
  margin: 0 auto 24px;
  padding: 14px 18px;
  background: #fff8e6;
  border-left: 3px solid #e0a800;
  font-size: 14px;
  line-height: 1.6;
  color: #6b5417;
}

/* Reuses .episode-card / .episode-grid from the public lectures page. */
.archive-grid { max-width: 1240px; }

.gate-checking {
  max-width: 520px;
  margin: 80px auto;
  text-align: center;
  color: var(--text-med);
  font-size: 16px;
}

.gate-checking i {
  display: block;
  font-size: 34px;
  color: var(--teal);
  margin-bottom: 14px;
}

/* ---- Q&A ---- */
.qa-layout {
  max-width: 900px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  gap: 32px;
}

.qa-card {
  background: white;
  padding: 30px 30px 34px;
  border: 1px solid #dbe5ea;
}

.qa-card h2 {
  font-size: 21px;
  color: var(--navbar-bg);
  margin-bottom: 8px;
}

.qa-card > p {
  font-size: 15px;
  line-height: 1.7;
  color: var(--text-med);
  margin-bottom: 20px;
}

.qa-textarea {
  width: 100%;
  min-height: 150px;
  padding: 14px 16px;
  border: 1px solid #c7d4dc;
  font-family: inherit;
  font-size: 15px;
  line-height: 1.6;
  resize: vertical;
  color: var(--text-dark);
}

.qa-textarea:focus { outline: none; border-color: var(--teal); }

.qa-footer {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-top: 14px;
  gap: 16px;
  flex-wrap: wrap;
}

.qa-chars { font-size: 13px; color: #8a97a3; }
.qa-chars.over { color: var(--x-red); font-weight: 600; }

.qa-list { display: flex; flex-direction: column; gap: 14px; }

.qa-item {
  background: white;
  border: 1px solid #dbe5ea;
  border-left: 3px solid var(--teal);
  padding: 18px 20px;
}

.qa-item .qa-q { font-size: 15px; line-height: 1.65; color: var(--text-dark); }

.qa-item .qa-meta {
  margin-top: 10px;
  font-size: 12px;
  color: #8a97a3;
  display: flex;
  gap: 12px;
  align-items: center;
}

.qa-status {
  display: inline-block;
  padding: 3px 10px;
  border-radius: 50px;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.5px;
  text-transform: uppercase;
}

.qa-status.submitted { background: #e3eef5; color: #3a5568; }
.qa-status.answered  { background: #e0f2e2; color: #2f6b36; }

.qa-empty {
  padding: 26px;
  text-align: center;
  color: #8a97a3;
  font-size: 15px;
  background: white;
  border: 1px dashed #c7d4dc;
}

@media (max-width: 900px) {
  .insider-page { padding: 36px 20px 60px; }
  .insider-page-head h1 { font-size: 30px; }
  .qa-card { padding: 22px 20px 26px; }
}

/* ===================== SINGLE LECTURE PAGE ===================== */
.lecture-page {
  background: white;
  padding: 56px 36px 90px;
}

.lecture-layout {
  max-width: 1200px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: minmax(0, 1fr) 320px;
  gap: 60px;
  align-items: start;
}

.lecture-main { min-width: 0; }

.lecture-main h1 {
  font-family: 'Open Sans', sans-serif;
  font-weight: 800;
  font-size: clamp(28px, 3.2vw, 42px);
  line-height: 1.2;
  color: var(--navbar-bg);
  margin-bottom: 14px;
}

.lecture-byline {
  font-size: 15px;
  color: var(--teal-hover);
  margin-bottom: 28px;
}

.lecture-byline .sep { color: #b6c2cb; margin: 0 6px; }

/* Article body. Generous leading and short measure, because the source text
   arrives as very long unbroken blocks and reads as a wall without them. */
.lecture-intro {
  font-size: 18px;
  line-height: 1.85;
  color: var(--text-med);
  margin-bottom: 30px;
  max-width: 68ch;
}

.lecture-intro p { margin-bottom: 24px; }
.lecture-intro p:last-child { margin-bottom: 0; }
.lecture-intro a { color: var(--teal-hover); word-break: break-word; }

/* The opening hook. Regular weight: bolding a five-line paragraph makes the
   page open heavier than the article that follows. */
.lecture-lead {
  font-size: 19px;
  line-height: 1.8;
  color: var(--text-dark);
  margin-bottom: 30px !important;
}

.lecture-intro h2 {
  font-family: 'Open Sans', sans-serif;
  font-weight: 800;
  font-size: 27px;
  line-height: 1.3;
  color: var(--navbar-bg);
  margin: 40px 0 18px;
}

.lecture-intro h2:first-child { margin-top: 0; }

.lecture-disclaimer {
  margin-top: 40px !important;
  padding: 18px 20px;
  background: #f5f7f9;
  border-left: 3px solid #c7d4dc;
  font-size: 14px !important;
  line-height: 1.7;
  color: #74838f;
}

.lecture-video {
  position: relative;
  width: 100%;
  padding-bottom: 56.25%;
  height: 0;
  overflow: hidden;
  background: #1a2535;
  margin-bottom: 30px;
}

.lecture-video iframe {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  border: none;
}

/* One line of plain text, not a boxed callout. The box competed with the video
   directly above it for attention. */
.lecture-cta {
  font-size: 17px;
  line-height: 1.7;
  color: var(--text-med);
  margin-bottom: 34px;
}

.lecture-cta a { color: var(--teal-hover); font-weight: 700; text-decoration: none; }
.lecture-cta a:hover { text-decoration: underline; }

.lecture-back {
  display: inline-block;
  margin-bottom: 22px;
  color: var(--text-med);
  font-size: 14px;
  text-decoration: none;
}

.lecture-back:hover { color: var(--navbar-bg); }

/* End-of-article Insider block. */
.lecture-insider {
  margin-top: 48px;
  padding-top: 8px;
}

.lecture-insider h2 {
  font-family: 'Open Sans', sans-serif;
  font-weight: 800;
  font-size: 27px;
  color: var(--navbar-bg);
  margin-bottom: 12px;
}

.lecture-insider p {
  font-size: 17px;
  line-height: 1.7;
  color: var(--text-med);
  margin-bottom: 22px;
  max-width: 60ch;
}

/* ---- Sidebar ---- */
/* Sticky so it follows the reader down instead of leaving a tall empty column
   beside a short article. top offset clears the sticky navbar. */
.lecture-aside {
  position: sticky;
  top: calc(var(--nav-h) + 28px);
  align-self: start;
  max-height: calc(100vh - var(--nav-h) - 56px);
  overflow-y: auto;
  scrollbar-width: none;
}

.lecture-aside::-webkit-scrollbar { display: none; }

.lecture-aside h3 {
  font-family: 'Open Sans', sans-serif;
  font-weight: 800;
  font-size: 26px;
  color: var(--navbar-bg);
  margin-bottom: 18px;
}

.lecture-aside + .lecture-aside,
.aside-block + .aside-block { margin-top: 42px; }

.aside-list { list-style: none; display: flex; flex-direction: column; gap: 14px; }

.aside-list a {
  color: var(--teal-hover);
  text-decoration: none;
  font-size: 16px;
  line-height: 1.45;
  font-weight: 700;
}

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

@media (max-width: 950px) {
  /* Sticky is meaningless once the sidebar sits below the article. */
  .lecture-aside { position: static; max-height: none; }
}

.lecture-loading,
.lecture-missing {
  max-width: 700px;
  margin: 70px auto;
  text-align: center;
  color: var(--text-med);
  font-size: 16px;
  line-height: 1.7;
}

.lecture-loading i,
.lecture-missing i {
  display: block;
  font-size: 36px;
  color: #b6c2cb;
  margin-bottom: 14px;
}

@media (max-width: 950px) {
  .lecture-layout { grid-template-columns: 1fr; gap: 44px; }
  .lecture-page { padding: 36px 20px 64px; }
}

/* Shown on the account page while a subscription is past_due. */
.sub-warning {
  padding: 13px 16px;
  margin-bottom: 16px;
  background: #fff8e6;
  border-left: 3px solid #e0a800;
  font-size: 14px;
  line-height: 1.6;
  color: #6b5417;
}
