/* Study notes (/learn). The article itself uses the blog's styles (blog.css, .bp-*);
   this adds the subject and topic lists, level chips, questions, cover and full-size view. */
.ln-wrap{ max-width:1080px; }
.ln-h2{ font-size:clamp(22px, 2.2vw, 28px); line-height:1.25; letter-spacing:-0.02em; margin:0 0 18px; }
.ln-hero .bp-byline{ row-gap:10px; }
.ln-subject-badge{
  display:inline-flex; align-items:center; justify-content:center; width:52px; height:52px; margin:0 0 16px;
  border-radius:16px; background:var(--bl-tint); border:1px solid var(--bl-tint-2); color:var(--bl-accent);
}
.ln-subject-badge svg, .ln-subject-badge i{ width:26px; height:26px; }
.ln-levels{ display:inline-flex; flex-wrap:wrap; gap:6px; margin-left:4px; }
.ln-level{
  display:inline-flex; align-items:center; height:24px; padding:0 10px; border-radius:99px;
  background:var(--bl-tint); border:1px solid var(--bl-tint-2); color:var(--bl-accent); font-size:12px; font-weight:650;
}

/* subjects (/learn) */
.ln-subjects{ display:grid; grid-template-columns:repeat(auto-fill, minmax(min(100%, 240px), 1fr)); gap:16px; margin:0 0 56px; }
.ln-subject{
  display:flex; flex-direction:column; gap:8px; padding:22px; border:1px solid var(--hair); border-radius:18px;
  color:inherit; text-decoration:none; background:var(--paper); transition:border-color .2s ease, transform .2s ease;
}
.ln-subject:hover{ border-color:var(--sky-line, rgba(45,159,254,.45)); transform:translateY(-2px); }
.ln-subject:focus-visible, .ln-topic:focus-visible{ outline:2px solid var(--signal); outline-offset:3px; }
.ln-subject-icon{ display:flex; align-items:center; justify-content:center; width:44px; height:44px; border-radius:12px; background:var(--bl-tint); color:var(--bl-accent); }
.ln-subject-icon svg, .ln-subject-icon i{ width:22px; height:22px; }
.ln-subject b{ font-size:18px; line-height:1.3; color:var(--ink); }
.ln-subject > span:not(.ln-subject-icon){ font-size:14.5px; line-height:1.55; color:var(--graphite); }
.ln-subject small{ margin-top:auto; padding-top:4px; font-size:12.5px; font-weight:650; color:var(--bl-accent); }

/* topic lists (subject page, recent, related) */
.ln-topics{ display:grid; grid-template-columns:repeat(auto-fill, minmax(min(100%, 300px), 1fr)); gap:14px; }
.ln-topic{
  display:flex; flex-direction:column; gap:6px; padding:18px 20px; border:1px solid var(--hair); border-radius:14px;
  color:inherit; text-decoration:none; background:var(--paper); transition:border-color .2s ease, transform .2s ease;
}
.ln-topic:hover{ border-color:var(--sky-line, rgba(45,159,254,.45)); transform:translateY(-2px); }
.ln-topic b{ font-size:16px; line-height:1.35; color:var(--ink); }
.ln-topic span{ font-size:14px; line-height:1.55; color:var(--graphite); }
.ln-topic small{ margin-top:auto; font-size:12.5px; color:var(--graphite); }
.ln-chapter-block{ margin:0 0 44px; }
.ln-chapter-block:last-child{ margin-bottom:0; }
.ln-chapter-desc{ margin:-8px 0 16px; max-width:70ch; font-size:15px; line-height:1.6; color:var(--graphite); }
.ln-empty{ max-width:520px; margin:0 auto; padding:24px 0; text-align:center; }
.ln-empty > svg, .ln-empty > i{ width:36px; height:36px; color:var(--bl-accent); }
.ln-empty h2{ margin:14px 0 8px; font-size:24px; }
.ln-empty p{ margin:0 0 20px; color:var(--graphite); }
.ln-related h2{ margin-bottom:20px; }

/* topic page */
.ln-cover{ margin:0 0 30px; }
.ln-cover img{ display:block; width:100%; height:auto; border-radius:16px; border:1px solid var(--hair); }
.ln-faqs{ display:grid; gap:10px; margin:0 0 26px; }
.ln-faq{ border:1px solid var(--hair); border-radius:14px; padding:0 18px; background:var(--paper); }
.ln-faq > summary{
  display:flex; align-items:center; justify-content:space-between; gap:14px; padding:16px 0; cursor:pointer;
  list-style:none; font-size:16px; font-weight:650; line-height:1.45; color:var(--ink);
}
.ln-faq > summary::-webkit-details-marker{ display:none; }
.ln-faq > summary::after{
  content:""; flex:none; width:7px; height:7px; border-right:2px solid var(--graphite); border-bottom:2px solid var(--graphite);
  transform:rotate(45deg) translate(-2px, -2px); transition:transform .2s ease;
}
.ln-faq[open] > summary::after{ transform:rotate(-135deg) translate(-2px, -2px); }
.ln-faq > summary:focus-visible{ outline:2px solid var(--bl-accent); outline-offset:4px; border-radius:6px; }
.ln-faq-a{ padding:0 0 16px; }
.ln-faq-a > :last-child{ margin-bottom:0; }
.ln-side-list{ list-style:none; margin:0; padding:0; border-left:1px solid var(--hair); }
.ln-side-list li{ margin:0; }
.ln-side-list a{
  display:block; margin-left:-1px; padding:5px 0 5px 14px; border-left:2px solid transparent;
  font-size:13.5px; line-height:1.45; color:var(--graphite); text-decoration:none;
}
.ln-side-list a:hover{ color:var(--ink); }
.ln-side-list a[aria-current="page"]{ color:var(--bl-accent); border-left-color:var(--signal); font-weight:600; }
#lnBody figure img, .ln-cover img, #lnBody .bp-diagram-svg{ cursor:zoom-in; }

/* full-size view */
.ln-zoom{
  margin:auto; padding:0; border:0; border-radius:16px; max-width:96vw; max-height:92vh;
  background:var(--paper); color:var(--ink); box-shadow:0 30px 80px rgba(0,0,0,.35); overflow:hidden;
}
.ln-zoom::backdrop{ background:rgba(8,15,30,.72); }
.ln-zoom-body{ max-width:96vw; max-height:92vh; overflow:auto; padding:18px; }
.ln-zoom-body img{ display:block; max-width:none; width:auto; height:auto; max-height:86vh; border-radius:10px; }
.ln-zoom-body .bp-diagram-svg{ cursor:default; border:0; padding:0; background:none; }
.ln-zoom-body svg{ max-width:none !important; height:auto; min-width:min(90vw, 900px); }
.ln-zoom-close{
  position:absolute; top:10px; right:10px; z-index:1; width:36px; height:36px; border-radius:50%;
  border:1px solid var(--hair); background:var(--paper); color:var(--ink); font-size:22px; line-height:1; cursor:pointer;
}
.ln-zoom-close:focus-visible{ outline:2px solid var(--signal); outline-offset:2px; }

@media (max-width:680px){
  .ln-subjects{ gap:12px; margin-bottom:40px; }
  .ln-subject{ padding:18px; }
  .ln-levels{ margin-left:0; }
}
@media (prefers-reduced-motion: reduce){
  .ln-subject, .ln-topic{ transition:none; }
}
