/* ==========================================================================
   Yesterday I Learned — recreated from the original Framer site.

   Type scale and geometry measured off the live original at a 1440px
   viewport:
     content column 1130px (centred, ~155px side margins)
     body / intro ....... Arial 15px / 28.5px  (1.9)
     section headings ... Arial 20px bold / 38px
     lesson links ....... Arial 14px / 26.6px, #09f underlined
     resume body ........ Arial 14px / 26.6px, column 738px
     accordion label .... Inter 16px bold, pill 333 x 45, radius 22px
     profile card ....... 354px wide, "By Eddy Lee" Arial 18px bold
     title .............. Linux Libertine 51px, "I Learned" in #a6a6a6
     lesson headings .... Cactus Classical Serif 60px, -0.05em
     lesson body ........ Geist 18px / 1.6, -0.02em
   ========================================================================== */

@font-face {
  font-family: "Linux Libertine";
  src: url("../assets/fonts/linux-libertine.woff2") format("woff2");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}

:root {
  --ink: #000;
  --ink-soft: #333;
  --border: #ccc;
  --border-accordion: #d4d4d4;
  --link: #09f;
  --paper: #fff;
  --serif-title: "Linux Libertine", "Linux Libertine O", Georgia, serif;
  --serif-lesson: "Cactus Classical Serif", Georgia, serif;
  --sans: "Geist", -apple-system, BlinkMacSystemFont, "Segoe UI", Helvetica, Arial, sans-serif;
  --narrow: "Arial Narrow", Arial, sans-serif;
  --lh: 1.9;
}

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

html { scroll-behavior: smooth; }

body {
  background: var(--paper);
  color: var(--ink);
  font-family: Arial, Helvetica, sans-serif;
  font-size: 15px;
  line-height: var(--lh);
  -webkit-font-smoothing: antialiased;
}

a { color: var(--link); text-decoration: underline; }
a:hover { text-decoration: none; }

img { max-width: 100%; display: block; }

.wrap {
  max-width: 1180px;
  margin: 0 auto;
  padding: 0 25px;
}

/* --------------------------------------------------------------------------
   Home header
   -------------------------------------------------------------------------- */
.site-header {
  display: flex;
  align-items: center;
  gap: 46px;
  padding: 22px 0 12px;
}

.site-header .globe {
  width: 190px;
  height: 190px;
  flex: none;
  border-radius: 50%;
  filter: drop-shadow(0 6px 12px rgba(0, 0, 0, 0.35));
}

.site-title {
  font-family: var(--serif-title);
  font-weight: 400;
  font-size: 51px;
  line-height: 1.2;
  letter-spacing: 0.01em;
}

.site-title .muted { color: #a6a6a6; }

.header-rule {
  border: none;
  border-top: 1px solid var(--border);
  margin: 6px 0 20px;
}

/* Tagline box */
.tagline-box {
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 8px 22px;
  font-family: var(--narrow);
  font-size: 14px;
  line-height: 1.2;
  margin-bottom: 28px;
}

.tagline-box mark {
  background: rgba(0, 0, 0, 0.2);
  color: inherit;
  padding: 0 2px;
}

/* --------------------------------------------------------------------------
   Home content
   -------------------------------------------------------------------------- */
.intro p { margin-bottom: 4px; }

.intro ol { margin: 6px 0 0 24px; }

.section-heading {
  font-size: 20px;
  font-weight: 700;
  line-height: 1.9;
  margin: 34px 0 4px;
}

/* Resume + profile card */
.columns {
  display: grid;
  grid-template-columns: minmax(0, 738px) 354px;
  justify-content: space-between;
  gap: 60px;
  align-items: start;
  margin-top: 34px;
}

.resume > p { font-size: 14px; margin-bottom: 22px; }

.accordions {
  display: flex;
  gap: 26px;
  flex-wrap: wrap;
}

.accordions details {
  flex: 0 1 333px;
  min-width: 250px;
  border: 1px solid var(--border-accordion);
  border-radius: 22px;
  padding: 0 24px;
  align-self: start;
}

.accordions summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  cursor: pointer;
  list-style: none;
  font-family: var(--sans);
  font-weight: 700;
  font-size: 16px;
  line-height: 1.2;
  min-height: 43px;
}

.accordions summary::-webkit-details-marker { display: none; }

.accordions summary::after {
  content: "";
  width: 15px;
  height: 15px;
  flex: none;
  background:
    linear-gradient(#000, #000) center / 15px 1.5px no-repeat,
    linear-gradient(#000, #000) center / 1.5px 15px no-repeat;
  transition: transform 0.25s ease;
}

.accordions details[open] summary::after { transform: rotate(45deg); }

.accordions .acc-body {
  font-family: var(--sans);
  font-size: 14px;
  line-height: 1.6;
  padding: 2px 0 16px;
}

.accordions .acc-body p { margin-bottom: 10px; }
.accordions .acc-body ul { margin-left: 18px; }
.accordions .acc-body li { margin-bottom: 8px; }

/* Profile card */
.profile-card {
  border: 1px solid #979797;
  font-family: Arial, Helvetica, sans-serif;
}

.profile-card .card-bar {
  background: #c2c2c2;
  font-weight: 700;
  font-size: 18px;
  line-height: 1.9;
  padding: 4px 14px;
}

.profile-card .avatar {
  width: 205px;
  height: 205px;
  border-radius: 50%;
  object-fit: cover;
  margin: 24px auto 8px;
  display: block;
}

.profile-card .credit {
  text-align: center;
  font-weight: 700;
  font-style: italic;
  font-size: 15px;
  margin-bottom: 20px;
}

.profile-card table {
  width: 100%;
  border-collapse: collapse;
  font-size: 14px;
  line-height: 1.9;
}

.profile-card td {
  padding: 10px 14px;
  vertical-align: top;
  border-top: 1px solid #ddd;
}

.profile-card td:first-child {
  font-weight: 700;
  white-space: nowrap;
  width: 100px;
}

/* Lesson index lists */
.lesson-section ul { list-style: none; }
.lesson-section ul li { font-size: 14px; }
.lesson-section .note { font-size: 14px; }

/* --------------------------------------------------------------------------
   Lesson pages
   -------------------------------------------------------------------------- */
.lesson-nav {
  position: sticky;
  top: 0;
  z-index: 10;
  background: var(--paper);
  border-bottom: 1px solid #eee;
}

.lesson-nav .nav-inner {
  max-width: 980px;
  margin: 0 auto;
  padding: 8px 24px;
  display: flex;
  align-items: center;
  gap: 22px;
  font-family: var(--sans);
  font-size: 15px;
  letter-spacing: -0.02em;
}

.lesson-nav img { width: 30px; height: 30px; border-radius: 50%; }

.lesson-nav .sep { color: #ccc; }

.lesson-nav a { color: var(--ink-soft); }
.lesson-nav a:hover { color: var(--link); }

.lesson-nav .mail {
  margin-left: auto;
  color: #888;
  text-decoration: none;
  font-size: 17px;
}

.lesson {
  max-width: 660px;
  margin: 0 auto;
  padding: 56px 24px 40px;
  font-family: var(--sans);
  font-size: 18px;
  letter-spacing: -0.02em;
  line-height: 1.6;
}

.lesson h1 {
  font-family: var(--serif-lesson);
  font-weight: 400;
  font-size: 60px;
  letter-spacing: -0.05em;
  line-height: 1.1;
  margin-bottom: 34px;
}

/* Word-by-word reveal (recreates the Framer per-letter entrance) */
.lesson h1 .w {
  display: inline-block;
  opacity: 0;
  filter: blur(5px);
  transform: translateY(10px);
  animation: rise 0.55s ease forwards;
}

@keyframes rise {
  to { opacity: 1; filter: blur(0); transform: translateY(0); }
}

.one-sentence {
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 18px 22px;
  margin-bottom: 30px;
}

.lesson p { margin-bottom: 16px; }
.lesson ul, .lesson ol { margin: 0 0 16px 24px; }
.lesson li { margin-bottom: 10px; }
.lesson h2 { font-size: 24px; font-weight: 600; margin: 30px 0 14px; }

.lesson table {
  width: 100%;
  border-collapse: collapse;
  margin: 0 0 22px;
  font-size: 16px;
}

.lesson th, .lesson td {
  border: 1px solid var(--border);
  padding: 10px 14px;
  text-align: left;
  vertical-align: top;
}

.lesson th { font-weight: 700; background: #fafafa; }

.lesson .checklist { list-style: none; margin-left: 4px; }
.lesson .checklist li::before { content: "\2610  "; }

/* --------------------------------------------------------------------------
   Footer / subscribe
   -------------------------------------------------------------------------- */
.site-footer {
  border-top: 1px solid var(--border);
  margin-top: 64px;
  padding: 48px 24px 56px;
  text-align: center;
  font-family: var(--sans);
}

.site-footer h2 {
  font-family: var(--serif-title);
  font-weight: 400;
  font-size: 28px;
  line-height: 1.5;
}

.site-footer .globe-small {
  width: 110px;
  height: 110px;
  border-radius: 50%;
  margin: 26px auto 30px;
}

.subscribe-form {
  display: flex;
  gap: 10px;
  justify-content: center;
  flex-wrap: wrap;
  max-width: 470px;
  margin: 0 auto 12px;
}

.subscribe-form input[type="email"] {
  flex: 1 1 230px;
  appearance: none;
  border: none;
  outline: none;
  padding: 10px;
  border-radius: 6px;
  font-size: 18px;
  font-family: var(--sans);
  letter-spacing: -0.02em;
  background: #fafafa;
  color: #000;
  box-shadow: inset 0 0 0 1px var(--border);
}

.subscribe-form input[type="submit"] {
  appearance: none;
  border: none;
  cursor: pointer;
  padding: 10px 16px;
  border-radius: 6px;
  font-size: 18px;
  font-family: var(--sans);
  background: #000;
  color: #fafafa;
}

.subscribe-form input[type="submit"]:hover { background: #222; }

/* Mailchimp's required bot-trap field, kept out of view */
.mc-bot-field {
  position: absolute;
  left: -5000px;
}

.site-footer .no-spam { font-size: 13px; color: var(--ink-soft); }

.site-footer .mc-note {
  font-size: 12px;
  color: #777;
  margin-top: 8px;
}

.site-footer .mc-note a { color: #777; }

/* --------------------------------------------------------------------------
   Responsive
   -------------------------------------------------------------------------- */
@media (max-width: 1120px) {
  .columns { grid-template-columns: 1fr; gap: 40px; }
  .profile-card { max-width: 380px; }
}

@media (max-width: 860px) {
  .site-header { gap: 24px; }
  .site-header .globe { width: 120px; height: 120px; }
  .site-title { font-size: 34px; }
  .lesson h1 { font-size: 38px; }
}

@media (max-width: 520px) {
  body { font-size: 14px; }
  .site-title { font-size: 25px; }
  .site-header .globe { width: 84px; height: 84px; }
  .section-heading { font-size: 18px; }
  .lesson { font-size: 16.5px; }
  .lesson h1 { font-size: 31px; }
  .lesson-nav .nav-inner { gap: 12px; font-size: 13.5px; }
  .accordions { gap: 16px; }
}
