/* ===================================================
   Bhavya Kamdar — personal site
   Palette: black / white / off-white / olive-green accent
   (visual language inspired by jayshetty.me)
=================================================== */

:root {
  --color-ink: #111111;
  --color-paper: #ffffff;
  --color-offwhite: #f3f1ec;
  --color-line: #e4e1d8;
  --color-olive: #74804f;
  --color-olive-dark: #5c6640;
  --color-muted: #6b6b64;

  --font-head: 'Poppins', 'Segoe UI', sans-serif;
  --font-body: 'Inter', 'Segoe UI', sans-serif;

  --maxw: 1180px;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; overflow-x: clip; }

body {
  margin: 0;
  font-family: var(--font-body);
  color: var(--color-ink);
  background: var(--color-paper);
  line-height: 1.55;
  overflow-x: clip;
}

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

a { color: inherit; text-decoration: none; }

.wrap {
  max-width: var(--maxw);
  margin: 0 auto;
  padding: 0 32px;
}

/* ---------- Buttons ---------- */
.btn {
  display: inline-block;
  padding: 14px 30px;
  border: 1.5px solid var(--color-ink);
  font-family: var(--font-head);
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  background: transparent;
  color: var(--color-ink);
  cursor: pointer;
  transition: background 0.2s ease, color 0.2s ease;
}
.btn:hover { background: var(--color-ink); color: var(--color-paper); }

.btn-light {
  border-color: var(--color-paper);
  color: var(--color-paper);
}
.btn-light:hover { background: var(--color-paper); color: var(--color-ink); }

/* ---------- Nav ---------- */
.site-header {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 100;
  background: transparent;
  transition: background 0.25s ease, box-shadow 0.25s ease;
}
.site-header.solid,
.site-header.always-solid {
  background: var(--color-paper);
  box-shadow: 0 1px 0 var(--color-line);
}

.nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 20px 32px;
  max-width: var(--maxw);
  margin: 0 auto;
}

.logo {
  font-family: var(--font-head);
  font-weight: 700;
  font-size: 20px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: inherit;
}

.nav-links {
  display: flex;
  gap: 28px;
  list-style: none;
  margin: 0;
  padding: 0;
}

.nav-links a {
  font-family: var(--font-head);
  font-size: 12.5px;
  font-weight: 600;
  letter-spacing: 0.09em;
  text-transform: uppercase;
}

.site-header:not(.solid):not(.always-solid) .nav { color: var(--color-paper); }
.site-header.solid .nav,
.site-header.always-solid .nav { color: var(--color-ink); }

.nav-toggle {
  display: none;
  background: none;
  border: none;
  cursor: pointer;
  font-size: 24px;
  color: inherit;
}

@media (max-width: 860px) {
  .nav-links {
    position: fixed;
    top: 0; right: 0;
    transform: translateX(100%);
    visibility: hidden;
    height: 100vh;
    width: 260px;
    background: var(--color-ink);
    color: var(--color-paper);
    flex-direction: column;
    gap: 0;
    padding: 90px 32px;
    transition: transform 0.3s ease, visibility 0.3s;
  }
  .nav-links.open { transform: none; visibility: visible; }
  .nav-links a { color: var(--color-paper); display: block; padding: 14px 0; border-bottom: 1px solid rgba(255,255,255,0.12); }
  .nav-links { z-index: 1; }
  .nav-toggle { display: block; position: relative; z-index: 2; }
  .nav-toggle.open { color: var(--color-paper); }
}

/* ---------- Hero ---------- */
.hero {
  position: relative;
  background: linear-gradient(160deg, #1c1f18 0%, #2c3324 45%, #45502f 100%);
  overflow: hidden;
}

/* Mobile (<860px): photo is a static banner above the text, so it never
   overlaps the headline. Desktop: full-bleed behind the text instead. */
.hero-photo {
  display: block;
  position: relative;
  aspect-ratio: 4 / 5;
  overflow: hidden;
}
.hero-photo img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center 30%;
}
.hero-photo::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(8,10,6,0.6) 0%, rgba(8,10,6,0.08) 30%, rgba(8,10,6,0) 55%);
}

@media (min-width: 860px) {
  .hero {
    display: flex;
    align-items: flex-end;
    min-height: 100vh;
  }
  .hero-photo {
    position: absolute;
    inset: 0;
    z-index: 1;
    aspect-ratio: auto;
  }
  .hero-photo img { object-position: center 35%; }
  .hero-photo::after {
    background: linear-gradient(0deg, rgba(8,10,6,0.88) 0%, rgba(8,10,6,0.4) 48%, rgba(8,10,6,0.05) 72%);
  }
}

.hero-inner {
  position: relative;
  z-index: 2;
  width: 100%;
  padding: 40px 32px 56px;
  max-width: var(--maxw);
  margin: 0 auto;
  color: var(--color-paper);
}
@media (min-width: 860px) {
  .hero-inner { padding: 0 32px 90px; }
}

.hero-eyebrow {
  font-family: var(--font-head);
  font-size: 12.5px;
  letter-spacing: 0.25em;
  text-transform: uppercase;
  color: #d7dcc7;
  margin-bottom: 18px;
}

.hero h1 {
  font-family: var(--font-head);
  font-weight: 700;
  font-size: clamp(40px, 7vw, 84px);
  line-height: 1.02;
  margin: 0 0 20px;
  letter-spacing: -0.01em;
}

.hero p {
  max-width: 520px;
  font-size: 17px;
  color: #eceee4;
  margin: 0 0 32px;
}

.hero-actions { display: flex; gap: 16px; flex-wrap: wrap; margin-bottom: 46px; }

.social-row { display: flex; gap: 20px; }
.social-row a {
  width: 38px; height: 38px;
  border: 1px solid rgba(255,255,255,0.4);
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  transition: background 0.2s ease, border-color 0.2s ease;
}
.social-row a:hover { background: var(--color-paper); border-color: var(--color-paper); }
.social-row a:hover svg { fill: var(--color-ink); }
.social-row svg { width: 16px; height: 16px; fill: var(--color-paper); }

/* ---------- Olive banners ---------- */
.banner {
  background: var(--color-olive);
  color: var(--color-paper);
  padding: 54px 32px;
}
.banner-inner {
  max-width: var(--maxw);
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 32px;
  flex-wrap: wrap;
}
.banner h3 {
  font-family: var(--font-head);
  font-size: 22px;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  margin: 0 0 8px;
}
.banner p { margin: 0; color: #eef0e4; max-width: 480px; }

.newsletter-form {
  display: flex;
  gap: 0;
  border-bottom: 1.5px solid rgba(255,255,255,0.6);
  min-width: 300px;
  flex: 1 1 320px;
  max-width: 420px;
}
.newsletter-form input {
  flex: 1;
  background: transparent;
  border: none;
  padding: 10px 4px;
  color: var(--color-paper);
  font-family: var(--font-body);
  font-size: 15px;
}
.newsletter-form input::placeholder { color: #dfe3d2; }
.newsletter-form input:focus { outline: none; }
.newsletter-form button {
  background: none;
  border: none;
  color: var(--color-paper);
  font-family: var(--font-head);
  font-size: 12.5px;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  cursor: pointer;
  padding: 10px 6px;
}

/* ---------- Section shell ---------- */
.section {
  padding: 100px 32px;
}
.section-tight { padding: 70px 32px; }
.section-offwhite { background: var(--color-offwhite); }

.section-head {
  max-width: var(--maxw);
  margin: 0 auto 48px;
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 24px;
  flex-wrap: wrap;
}

.eyebrow {
  font-family: var(--font-head);
  font-size: 12.5px;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--color-olive-dark);
  margin: 0 0 10px;
}

.section-head h2 {
  font-family: var(--font-head);
  font-weight: 700;
  font-size: clamp(28px, 3.4vw, 40px);
  margin: 0;
  letter-spacing: -0.01em;
}

/* ---------- Shared "real photo" placeholder treatment ---------- */
/* Every .ph box is meant to be swapped for a real <img> (object-fit:cover,
   same box). Kept photographic/dark so real photos drop in without a
   jarring tone shift. */
.ph {
  position: relative;
  overflow: hidden;
  background: linear-gradient(150deg, #3c4631 0%, #1a1c13 100%);
  display: flex;
  align-items: flex-end;
  justify-content: center;
}
.ph svg { width: 52%; height: auto; opacity: 0.38; transform: translateY(10%); }

/* ---------- Two-column blocks (About / Speaking) ---------- */
.split-grid {
  max-width: var(--maxw);
  margin: 0 auto;
  display: grid;
  grid-template-columns: 0.85fr 1.15fr;
  gap: 56px;
  align-items: stretch;
}
.split-grid.reverse { grid-template-columns: 0.85fr 1.15fr; }
.split-grid.reverse .portrait-frame { order: 2; }
.split-grid.reverse .split-copy { order: 1; align-self: center; }

.portrait-frame {
  aspect-ratio: 4 / 5;
  min-height: 420px;
}
.portrait-frame.wide { aspect-ratio: 16 / 11; }
.portrait-frame.photo { position: relative; overflow: hidden; min-width: 0; min-height: 0; width: 100%; }
.portrait-frame.photo img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; object-position: 38% 45%; }
.placeholder-label {
  position: absolute;
  bottom: 14px; left: 14px;
  font-family: var(--font-head);
  font-size: 10.5px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: rgba(17,17,17,0.45);
  background: rgba(255,255,255,0.6);
  padding: 4px 8px;
}

.split-copy h2 {
  font-family: var(--font-head);
  font-weight: 700;
  font-size: clamp(28px, 3.4vw, 38px);
  margin: 0 0 22px;
  letter-spacing: -0.01em;
}
.split-copy p { color: #333; margin: 0 0 18px; max-width: 540px; }

@media (max-width: 860px) {
  .split-grid, .split-grid.reverse { grid-template-columns: 1fr; }
  .split-grid.reverse .portrait-frame { order: -1; }
}

/* ---------- Featured book ---------- */
.featured-book {
  max-width: var(--maxw);
  margin: 0 auto 72px;
  display: grid;
  grid-template-columns: 380px 1fr;
  gap: 56px;
  align-items: center;
}
.book-cover {
  aspect-ratio: 2 / 3;
  background: linear-gradient(150deg, #efece3, #d8d4c4);
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
}
.book-cover svg { width: 34%; opacity: 0.5; }
.featured-book h3 {
  font-family: var(--font-head);
  font-weight: 700;
  font-size: clamp(26px, 3vw, 38px);
  margin: 0 0 16px;
}
.featured-book p { color: #333; max-width: 52ch; margin: 0 0 22px; }
.link-row { display: flex; gap: 14px; flex-wrap: wrap; }

@media (max-width: 760px) {
  .featured-book { grid-template-columns: 1fr; }
  .featured-book .book-cover { max-width: 240px; }
}

/* ---------- Book row / content grid (shared card layout) ---------- */
.card-grid {
  max-width: var(--maxw);
  margin: 0 auto;
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 28px;
}
.card-grid.books { grid-template-columns: repeat(4, 1fr); }

.card { display: block; }
.card-thumb {
  aspect-ratio: 1 / 1;
  background: linear-gradient(155deg, #efece3, #d8d4c4);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 14px;
  position: relative;
}
.card-thumb.book { aspect-ratio: 2 / 3; }
.card-thumb svg { width: 32%; opacity: 0.5; }
.card-tag {
  font-family: var(--font-head);
  font-size: 11px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--color-olive-dark);
  margin-bottom: 6px;
  display: block;
}
.card h4 {
  font-family: var(--font-body);
  font-weight: 600;
  font-size: 15px;
  margin: 0;
  color: var(--color-ink);
}

@media (max-width: 980px) {
  .card-grid, .card-grid.books { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 560px) {
  .card-grid, .card-grid.books { grid-template-columns: repeat(2, 1fr); gap: 20px 14px; }
  .card h4 { font-size: 14px; }
}

.section-cta { text-align: center; margin-top: 46px; }

/* ---------- Press-style image rows (Thinking) ---------- */
.press-list {
  max-width: var(--maxw);
  margin: 0 auto;
  display: flex;
  flex-direction: column;
}
.press-row {
  display: grid;
  grid-template-columns: 1.2fr 1fr;
  gap: 48px;
  align-items: center;
  padding: 40px 0;
  border-bottom: 1px solid var(--color-line);
}
.press-row:first-child { padding-top: 0; }
.press-image {
  aspect-ratio: 3 / 2;
  min-height: 260px;
}
.press-copy h4 {
  font-family: var(--font-head);
  font-weight: 700;
  font-size: clamp(20px, 2.4vw, 30px);
  margin: 0;
  letter-spacing: -0.005em;
}
@media (max-width: 760px) {
  .press-row { grid-template-columns: 1fr; gap: 20px; padding: 28px 0; }
}

/* ---------- Speaking/Thinking full-bleed CTA band ---------- */
.cta-band {
  position: relative;
  min-height: 50vh;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  color: var(--color-paper);
  background: linear-gradient(160deg, #20241a 0%, #3b4529 60%, #56613a 100%);
}
.cta-band-inner { max-width: 640px; padding: 60px 32px; }
.cta-band .eyebrow { color: #d7dcc7; }
.cta-band h2 {
  font-family: var(--font-head);
  font-weight: 700;
  font-size: clamp(30px, 4vw, 46px);
  margin: 0 0 20px;
}
.cta-band p { color: #e9ebdf; margin-bottom: 30px; }

/* ---------- Footer ---------- */
.site-footer {
  background: var(--color-ink);
  color: #e6e6e0;
  padding: 70px 32px 32px;
}
.footer-top {
  max-width: var(--maxw);
  margin: 0 auto 48px;
  display: flex;
  justify-content: space-between;
  gap: 40px;
  flex-wrap: wrap;
}
.footer-top h3 {
  font-family: var(--font-head);
  font-size: 20px;
  max-width: 380px;
  margin: 0 0 20px;
}

.footer-columns {
  max-width: var(--maxw);
  margin: 0 auto 48px;
  display: grid;
  grid-template-columns: 1.3fr 1fr 1fr 1fr;
  gap: 32px;
}
.footer-columns .brand-col .logo { color: var(--color-paper); font-size: 22px; }
.footer-bio { max-width: 420px; color: #b9b9b0; font-size: 14px; margin-top: 16px; }
.footer-col h5 {
  font-family: var(--font-head);
  font-size: 11.5px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: #9a9a90;
  margin: 0 0 16px;
}
.footer-col a { display: block; padding: 5px 0; font-size: 14.5px; color: #d8d8d0; }
.footer-col a:hover { color: var(--color-paper); }

@media (max-width: 760px) {
  .footer-columns { grid-template-columns: 1fr 1fr; }
  .footer-columns .brand-col { grid-column: 1 / -1; }
}

.footer-bottom {
  max-width: var(--maxw);
  margin: 0 auto;
  padding-top: 28px;
  border-top: 1px solid rgba(255,255,255,0.12);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  flex-wrap: wrap;
}
.footer-social { display: flex; gap: 16px; }
.footer-social a {
  width: 34px; height: 34px;
  border: 1px solid rgba(255,255,255,0.3);
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
}
.footer-social svg { width: 14px; height: 14px; fill: #e6e6e0; }
.copyright { font-size: 12.5px; color: #8c8c84; }

/* ---------- Book detail pages ---------- */
.book-hero { padding-top: clamp(130px, 18vw, 170px); }

.back-link {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 20px;
}

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

.book-cover-art {
  position: sticky;
  top: 110px;
}
.book-cover-art img {
  width: 100%;
  aspect-ratio: 2 / 3;
  object-fit: cover;
  box-shadow: 0 24px 48px rgba(0,0,0,0.18);
}

.book-info h1 {
  font-family: var(--font-head);
  font-weight: 700;
  font-size: clamp(32px, 4.2vw, 50px);
  line-height: 1.04;
  margin: 10px 0 10px;
  letter-spacing: -0.01em;
}
.book-byline {
  font-size: 16px;
  color: var(--color-muted);
  margin: 0 0 14px;
}
.book-byline a { border-bottom: 1px solid var(--color-line); }
.book-byline a:hover { border-color: var(--color-ink); }

.book-desc {
  font-size: 17px;
  line-height: 1.7;
  color: #2b2b2b;
  max-width: 62ch;
  margin: 0 0 36px;
}
.book-desc + .book-desc { margin-top: -22px; }

.book-formats {
  display: flex;
  flex-direction: column;
  gap: 24px;
  padding: 28px;
  background: var(--color-offwhite);
  border: 1px solid var(--color-line);
  margin-bottom: 36px;
}
.format-block h4 {
  font-family: var(--font-head);
  font-size: 13px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  margin: 0 0 12px;
  color: var(--color-olive-dark);
}
.format-block .link-row .btn { font-size: 12px; padding: 12px 22px; }
.format-note {
  font-size: 13.5px;
  color: var(--color-muted);
  font-style: italic;
  margin: 0;
}

.book-specs {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 16px 32px;
  padding-top: 28px;
  border-top: 1px solid var(--color-line);
  margin: 0;
}
.book-specs div { display: flex; flex-direction: column; gap: 3px; }
.book-specs dt {
  font-family: var(--font-head);
  font-size: 11px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--color-muted);
}
.book-specs dd { margin: 0; font-size: 14.5px; }

.game-callout {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  flex-wrap: wrap;
  background: var(--color-ink);
  color: var(--color-paper);
  padding: 28px 32px;
  margin-bottom: 36px;
}
.game-callout p { margin: 0; color: #d8d8d0; max-width: 46ch; }
.game-callout h4 { font-family: var(--font-head); margin: 0 0 6px; font-size: 18px; }

@media (max-width: 860px) {
  .book-hero-grid { grid-template-columns: 1fr; gap: 32px; }
  .book-cover-art { position: static; max-width: 280px; margin: 0 auto; }
  .book-specs { grid-template-columns: 1fr 1fr; }
}

/* ---------- Speaking page ---------- */
.speaking-list { max-width: var(--maxw); margin: 0 auto; }
.speaking-row {
  display: grid;
  grid-template-columns: 180px 1fr;
  gap: 32px;
  padding: 32px 0;
  border-bottom: 1px solid var(--color-line);
}
.speaking-date {
  font-family: var(--font-head);
  font-weight: 600;
  font-size: 13px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--color-muted);
  padding-top: 3px;
}
.speaking-row h3 {
  font-family: var(--font-head);
  font-weight: 700;
  font-size: clamp(18px, 2.2vw, 24px);
  margin: 0 0 6px;
}
.speaking-row h3 a { border-bottom: 1px solid var(--color-line); }
.speaking-row h3 a:hover { border-color: var(--color-ink); }
.speaking-row p { margin: 0 0 8px; color: #333; }
.speaking-row .speaking-meta { color: var(--color-muted); font-size: 14.5px; }
.speaking-empty { color: var(--color-muted); }
.speaking-empty a { border-bottom: 1px solid var(--color-ink); }
@media (max-width: 640px) {
  .speaking-row { grid-template-columns: 1fr; gap: 8px; }
}

.speaking-posts { display: grid; grid-template-columns: repeat(3, 1fr); align-items: stretch; gap: 28px; margin-top: 24px; }
.speaking-post { display: flex; flex-direction: column; gap: 16px; }
.speaking-gallery { overflow: hidden; display: grid; grid-template-columns: 1fr 1fr; grid-template-rows: 2fr 1fr; gap: 10px; }
.speaking-gallery img { width: 100%; height: 100%; min-height: 0; object-fit: cover; object-position: center 25%; }
.speaking-gallery img:first-child { grid-column: 1 / -1; }
.speaking-gallery.two { grid-template-rows: 1fr 1fr; }
.speaking-gallery.two img:nth-child(2) { grid-column: 1 / -1; }
.speaking-img, .speaking-gallery { aspect-ratio: 4 / 5; width: 100%; box-shadow: 0 16px 36px rgba(0,0,0,0.14); }
.speaking-img { object-fit: cover; }
.speaking-body { flex: 1; display: flex; flex-direction: column; align-items: flex-start; }
.speaking-body .btn { margin-top: auto; }
.speaking-qs { list-style: none; margin: 0; padding: 0; width: 100%; }
.speaking-qs li { padding: 12px 0; border-top: 1px solid var(--color-line); }
.speaking-qs li:first-child { border-top: 0; padding-top: 0; }
.speaking-row .speaking-qs .speaking-q { margin: 0 0 6px; font-size: 15px; line-height: 1.45; }
.speaking-qlink { font-family: var(--font-head); font-size: 11px; font-weight: 600; letter-spacing: 0.1em; text-transform: uppercase; border-bottom: 1.5px solid var(--color-ink); padding-bottom: 1px; white-space: nowrap; }
.speaking-qlink:hover { color: var(--color-olive-dark); border-color: var(--color-olive-dark); }
.speaking-row .speaking-excerpt { margin: 0 0 16px; line-height: 1.55; font-size: 15px; }
@media (min-width: 900px) {
  /* three-question card: photo flexes to fill whatever height the questions leave, so the card matches its neighbours */
  .speaking-post.has-questions .speaking-img { aspect-ratio: auto; flex: 1 1 0; height: 0; min-height: 170px; }
  .speaking-post.has-questions .speaking-body { flex: 0 0 auto; }
  .speaking-post.has-questions .speaking-qs li { padding: 7px 0; }
  .speaking-post.has-questions .speaking-qs .speaking-q { font-size: 14px; margin-bottom: 3px; line-height: 1.4; }
  .speaking-row .speaking-excerpt { display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 5; line-clamp: 5; overflow: hidden; }
  .speaking-body .btn { white-space: nowrap; padding: 12px 16px; font-size: clamp(9.5px, 1.05vw, 12px); letter-spacing: 0.1em; }
}
@media (max-width: 899px) {
  /* keep the desktop arrangement (up to three posts in a row); everything just gets smaller */
  .speaking-posts { gap: 12px; margin-top: 16px; }
  .speaking-post { gap: 8px; }
  .speaking-gallery { gap: 4px; }
  .speaking-row .speaking-excerpt { font-size: 11.5px; line-height: 1.45; margin: 0 0 8px; display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 6; line-clamp: 6; overflow: hidden; }
  .speaking-row .speaking-qs .speaking-q { font-size: 11px; line-height: 1.4; }
  .speaking-qs li { padding: 6px 0; gap: 6px; }
  .speaking-body .li-btn { width: 28px; height: 28px; }
  .speaking-body .li-btn svg { width: 12px; height: 12px; }
}

/* ---------- Compact home sections (Writing) ---------- */
.section-compact { padding: 64px 32px 60px; }
.section-compact .section-head { margin-bottom: 28px; }
.section-compact .featured-book { grid-template-columns: 260px 1fr; gap: 40px; margin-bottom: 0; align-items: center; }
.section-compact .featured-book h3 { margin-bottom: 12px; }
.section-compact .featured-book p { margin-bottom: 18px; }
.section-compact .section-cta { margin-top: 32px; }
@media (max-width: 760px) {
  .section-compact { padding: 48px 24px 44px; }
  .section-compact .featured-book { grid-template-columns: 150px 1fr; gap: 20px; }
  .section-compact .featured-book .book-cover { max-width: none; }
  .section-compact .featured-book p { font-size: 14.5px; margin-bottom: 14px; }
  .section-compact .link-row .btn { padding: 11px 16px; font-size: 11.5px; }
  .section-compact .section-cta { margin-top: 24px; }
}
@media (max-width: 560px) {
  .section-compact .featured-book { grid-template-columns: 118px 1fr; gap: 16px; align-items: start; }
  .section-compact .featured-book h3 { font-size: 22px; margin-bottom: 8px; }
  .section-compact .featured-book p { font-size: 14px; line-height: 1.5; }
  .section-compact .link-row { gap: 8px; }
  .section-compact .link-row .btn { padding: 10px 11px; font-size: 10px; letter-spacing: 0.08em; }
}

/* ---------- LinkedIn logo button (Speaking) ---------- */
.li-btn { border-radius: 50%; display: inline-flex; align-items: center; justify-content: center; width: 42px; height: 42px; border: 1.5px solid var(--color-ink); color: var(--color-ink); transition: background 0.2s ease, color 0.2s ease, border-color 0.2s ease; flex: none; }
.li-btn svg { width: 18px; height: 18px; fill: currentColor; }
.li-btn:hover, .li-btn:focus-visible { background: #0a66c2; border-color: #0a66c2; color: #fff; }
.li-btn.sm { width: 32px; height: 32px; }
.li-btn.sm svg { width: 14px; height: 14px; }
.speaking-body .li-btn { margin-top: auto; }
.speaking-qs li { display: flex; align-items: center; justify-content: space-between; gap: 14px; }
.speaking-qs .speaking-q { flex: 1; }
.speaking-row .speaking-qs .speaking-q { margin: 0; }

/* whole post is a link: image, text and logo button all open the LinkedIn post */
.speaking-hit { display: contents; cursor: pointer; }
.speaking-hit:hover .speaking-excerpt, .speaking-hit:hover .speaking-q { color: var(--color-olive-dark); }
.speaking-hit:hover .speaking-img, .speaking-hit:hover .speaking-gallery { filter: brightness(0.96); }
.speaking-img, .speaking-gallery { transition: filter 0.2s ease; }

/* ---------- Scroll story: the book opens, the preface page turns to the game ---------- */
.story { background: var(--color-offwhite); }
.story-track { position: relative; }
.story-stage { position: relative; min-height: 100vh; }
.st-scene { position: relative; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 28px; padding: 90px 24px 48px; min-height: 100vh; }
.st-book { --bh: min(42vh, 68vw); --bw: calc(var(--bh) / 1.5); --open: 1; --flip: 1; }

/* Live (JS) mode: tall scroll track with a pinned stage */
.story.is-live .story-track { height: 400vh; }
.story.is-live .story-stage { position: sticky; top: 0; height: 100vh; height: 100svh; min-height: 0; overflow: hidden; }
.story.is-live .st-scene { position: absolute; inset: 0; min-height: 0; }
.story.is-live .st-book { --open: var(--open-live, 0); --flip: var(--flip-live, 0); }
.story.is-live .st-buy { opacity: var(--buy, 0); transform: translateY(calc((1 - var(--buy, 0)) * 24px)); pointer-events: none; }
.story.is-live.buy-on .st-buy { pointer-events: auto; }

/* The book */
.st-book-art { perspective: 1800px; flex: none; }
.book3d { position: relative; width: var(--bw); height: var(--bh); transform-style: preserve-3d; transform: translateX(calc(var(--open) * var(--bw) / 2)); }
.book-page, .book-leaf, .book-cover3d { position: absolute; inset: 0; }
.book-page {
  background: #fdfbf5; color: #2a2a26; padding: calc(var(--bh) * 0.05) calc(var(--bw) * 0.08);
  font-family: Georgia, 'Times New Roman', serif; font-size: calc(var(--bh) * 0.034); line-height: 1.42; overflow: hidden;
}
.book-page p { margin: 0 0 .55em; }
.game-page { padding: 0; background: #fff; box-shadow: 4px 4px 0 -1px #e9e4d6, 8px 8px 0 -2px #ddd7c6, 0 22px 40px -12px rgba(0,0,0,.35); }
.st-game-frame { position: absolute; top: 0; left: 0; width: 360px; height: 540px; border: 0; background: #fff; transform-origin: 0 0; transform: scale(var(--fscale, .5)); }
.game-page::after { content: ""; position: absolute; inset: 0; pointer-events: none; box-shadow: inset 8px 0 14px -8px rgba(0,0,0,.25); }
.book-leaf { transform-style: preserve-3d; transform-origin: left center; transform: rotateY(calc(var(--flip) * -180deg)) translateZ(1px); }
.book-cover3d { transform-style: preserve-3d; transform-origin: left center; transform: rotateY(calc(var(--open) * -180deg)) translateZ(2px); }
.leaf-face { position: absolute; inset: 0; width: 100%; height: 100%; backface-visibility: hidden; -webkit-backface-visibility: hidden; }
.leaf-front { box-shadow: inset 8px 0 14px -8px rgba(0,0,0,.25); font-size: calc(var(--bh) * 0.04); display: flex; flex-direction: column; justify-content: center; }
.leaf-front .pf-label { margin-bottom: 1.1em; }
.leaf-front .pf-end { margin-bottom: 0; }
.leaf-back {
  transform: rotateY(180deg); background: #fdfbf5; display: flex; align-items: center; justify-content: center; text-align: center;
  font-family: Georgia, 'Times New Roman', serif; font-style: italic; color: rgba(42,42,38,.35); font-size: calc(var(--bh) * 0.06); line-height: 1.3;
  box-shadow: inset -8px 0 14px -8px rgba(0,0,0,.2);
}
.pf-label { font-family: var(--font-head); font-size: .8em; font-weight: 700; letter-spacing: .22em; text-transform: uppercase; color: var(--color-olive-dark); }
.pf-q { font-style: italic; border-left: 2px solid var(--color-olive); padding-left: .8em; }
.pf-end { font-style: italic; margin-top: 1em; }
.book-cover3d > * { position: absolute; inset: 0; width: 100%; height: 100%; backface-visibility: hidden; -webkit-backface-visibility: hidden; }
.cover-front { object-fit: cover; box-shadow: 0 22px 40px -12px rgba(0,0,0,.4); }
.cover-inside {
  transform: rotateY(180deg); background: linear-gradient(135deg, #f2eee2, #e6e0cd); display: flex; align-items: center; justify-content: center;
  font-family: 'Anton', var(--font-head), sans-serif; text-transform: uppercase; text-align: center; color: rgba(17,17,17,.14);
  font-size: calc(var(--bh) * 0.2); line-height: .9; letter-spacing: 1px; box-shadow: inset -8px 0 14px -8px rgba(0,0,0,.2);
}

/* Side panel (Buy now / Play the game) */
.st-side { max-width: 440px; text-align: center; position: relative; z-index: 3; }
.st-side h2 { font-family: var(--font-head); font-weight: 700; font-size: clamp(26px, 3.4vw, 40px); margin: 6px 0 12px; }
.st-side p { color: #333; margin: 0 0 18px; }
.st-side .link-row { justify-content: center; }
.btn-solid { background: var(--color-ink); color: var(--color-paper); }
.btn-solid:hover { background: transparent; color: var(--color-ink); }
.btn-swap { display: inline-grid; }
.btn-swap .btn { grid-area: 1 / 1; text-align: center; transition: opacity .35s ease, transform .35s ease; }
.desc-swap { display: grid; }
.desc-swap > span { grid-area: 1 / 1; transition: opacity .35s ease, transform .35s ease; }
.swap-play { opacity: 0; visibility: hidden; transform: translateY(6px); }
.story.on-game .swap-buy { opacity: 0; visibility: hidden; transform: translateY(-6px); }
.story.on-game .swap-play { opacity: 1; visibility: visible; transform: none; }
.story-cta { margin: 0; padding: 28px 24px 56px; }

@media (min-width: 860px) {
  .st-book { --bh: min(58vh, 460px); }
  .st-scene { flex-direction: row; justify-content: center; gap: 4vw; padding: 90px 6vw 48px; }
  .st-book-art { width: calc(var(--bw) * 2 + 20px); display: flex; justify-content: center; }
  .st-side { text-align: left; }
  .st-side .link-row { justify-content: flex-start; }
}
.st-label { display: none; }
@media (max-width: 859px) {
  .story .st-label { display: block; position: absolute; top: 88px; left: 24px; margin: 0; z-index: 4; }
  .story .eb-writing { display: none; }
  .story.is-live .st-book { padding-top: 120px; justify-content: flex-start; }
  .st-book { gap: 20px; }
  .st-book .st-side p { font-size: 14px; margin-bottom: 14px; }
}

/* ---------- About: portrait rises in on scroll ---------- */
.about-figure { position: relative; margin: 0 auto; width: 100%; max-width: 440px; aspect-ratio: 3 / 4; overflow: hidden; align-self: center; }
.about-figure img { position: absolute; inset: 0; width: 100%; height: 100%; display: block; }
/* top-aligned crop (no clipping of the blob), nudged down so the yellow blob is centred behind the portrait */
.about-splash { object-fit: cover; object-position: 50% 0%; opacity: var(--rise, 1); transform: translateY(2.2%) scale(calc(.85 + var(--rise, 1) * .15)); }
.about-person {
  object-fit: cover; object-position: bottom;
  opacity: var(--rise, 1); transform: translateY(calc((1 - var(--rise, 1)) * 70px));
  clip-path: inset(calc((1 - var(--rise, 1)) * 100%) 0 0 0);
}
.about-line.is-pending { opacity: 0; transform: translateY(18px); }
.about-line { transition: opacity .6s ease, transform .6s ease; }
.about-line.is-in { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) { .about-line { transition: none; } }

/* ---------- Speaking: full-width photo with a caption card in the bottom-right corner ---------- */
.speaking-banner { position: relative; background: #111; line-height: 0; }
.speaking-banner > img { display: block; width: 100%; height: auto; max-height: 100vh; object-fit: cover; object-position: center 35%; aspect-ratio: 3 / 2; }
.speaking-card {
  position: absolute; right: clamp(14px, 4vw, 56px); bottom: clamp(14px, 4vw, 56px);
  width: min(420px, calc(100% - 28px)); padding: 26px 28px 28px; line-height: 1.5;
  background: rgba(10,10,10,.8); -webkit-backdrop-filter: blur(6px); backdrop-filter: blur(6px); color: #fff;
}
.speaking-card .eyebrow { color: rgba(255,255,255,.7); margin: 0 0 8px; }
.speaking-card h2 { font-family: var(--font-head); font-weight: 700; font-size: clamp(24px, 2.6vw, 32px); line-height: 1.15; margin: 0 0 12px; color: #fff; }
.speaking-card p { color: rgba(255,255,255,.88); margin: 0 0 18px; font-size: 15px; }
.speaking-card .btn { color: #fff; border-color: #fff; }
.speaking-card .btn:hover { background: #fff; color: #111; }
@media (max-width: 600px) {
  /* portrait crop focused on Bhavya (left of the frame), caption card in the bottom-right corner */
  .speaking-banner > img { aspect-ratio: 3 / 4; max-height: none; object-position: 27% center; }
  .speaking-card { right: 0; bottom: 0; width: 88%; padding: 18px 18px 20px; }
  .speaking-card h2 { font-size: 22px; margin-bottom: 8px; }
  .speaking-card .eyebrow { font-size: 10.5px; margin-bottom: 6px; }
  .speaking-card p { font-size: 14px; margin-bottom: 14px; }
  .speaking-card .btn { padding: 11px 16px; font-size: 11px; letter-spacing: .09em; }
}

/* ---------- Home Thinking: "Beyond Bhavya" is written in, slides left, and the featured posts appear on the right ---------- */
.visually-hidden { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.thinking-home { background: #fff; }
.thinking-stage { padding: 96px 24px 0; }
.thinking-title { position: relative; margin: 0 auto 32px; width: min(760px, 88vw, 80vh); aspect-ratio: 1058 / 644; }
.thinking-title img { position: absolute; inset: 0; width: 100%; height: 100%; display: block; }
.thinking-title-script {
  -webkit-mask-image: linear-gradient(100deg, #000 calc(var(--draw, 1) * 112% - 12%), transparent calc(var(--draw, 1) * 112%));
          mask-image: linear-gradient(100deg, #000 calc(var(--draw, 1) * 112% - 12%), transparent calc(var(--draw, 1) * 112%));
}
/* Posts: each card shows its full portrait image */
.thinking-cards { max-width: 1000px; margin: 0 auto; display: grid; grid-template-columns: repeat(3, 1fr); align-items: stretch; gap: 40px clamp(16px, 2.6vw, 32px); }
.thinking-card { display: flex; flex-direction: column; align-items: flex-start; }
.thinking-card .speaking-hit { display: contents; }
.thinking-card .press-image { width: 100%; height: auto; aspect-ratio: auto; min-height: 0; display: block; box-shadow: 0 16px 36px rgba(0,0,0,0.14); }
.thinking-excerpt { margin: 16px 0 14px; color: #333; line-height: 1.5; font-size: 15px; }
.thinking-card .li-btn { margin-top: auto; }
.thinking-empty { color: var(--color-muted); }
.thinking-section-cta { text-align: center; margin: 0; padding: 48px 24px 88px; background: #fff; }
@media (max-width: 900px) { .thinking-cards { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 560px) { .thinking-cards { grid-template-columns: 1fr; max-width: 420px; } }

/* Scroll-driven mode (added by thinking.js; without it the title and posts simply stack). Everything below is positioned by the script. */
.thinking-scroll.is-anim .thinking-stage { position: sticky; top: 0; height: 100vh; height: 100svh; box-sizing: border-box; padding: 0; overflow: hidden; }
.is-anim .thinking-title { position: absolute; left: 50%; top: 50%; margin: 0; transform: translate(-50%, -50%) translate(var(--tx, 0px), var(--ty, 0px)) scale(var(--ts, 1)); will-change: transform; }
.is-anim .thinking-title-base { opacity: var(--in, 1); }
.is-anim .thinking-cards { position: absolute; top: 0; right: 24px; left: var(--cl, 42%); max-width: none; margin: 0; height: 100%; grid-template-columns: repeat(3, 1fr); align-content: center; align-items: start; gap: 24px; will-change: transform; }
.is-anim .thinking-card { opacity: var(--show, 0); transform: translateY(calc((1 - var(--show, 0)) * 36px)); }
@media (max-width: 640px) {
  .is-anim .thinking-cards { right: 12px; grid-template-columns: 1fr; height: auto; align-content: start; top: 92px; gap: 36px; transform: translateY(var(--cy, 0px)); }
  .is-anim .thinking-excerpt { font-size: 13px; margin: 12px 0 10px; }
}
@media (prefers-reduced-motion: reduce) { .thinking-scroll.is-anim { height: auto !important; } }

/* Thinking page: every post is its own card, newest first */
.thinking-page { padding-top: clamp(130px, 18vw, 170px); background: #fff; }
.thinking-grid { max-width: var(--maxw); margin: 0 auto; display: grid; grid-template-columns: repeat(3, 1fr); gap: 44px 28px; }
.thinking-grid { align-items: stretch; }
@media (max-width: 900px) {
  .thinking-grid { gap: 26px 12px; }
  .thinking-grid .thinking-excerpt { font-size: 11.5px; line-height: 1.45; margin: 10px 0 8px; display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 4; line-clamp: 4; overflow: hidden; }
  .thinking-grid .li-btn { width: 28px; height: 28px; }
  .thinking-grid .li-btn svg { width: 12px; height: 12px; }
}

/* ---------- Invited by: institution logos in white, in the hero photo's bottom-right corner (all screen sizes) ---------- */
.hero-photo::before { content: ""; position: absolute; inset: 0; z-index: 1; pointer-events: none; background: radial-gradient(ellipse 85% 60% at 100% 100%, rgba(8,10,6,0.85) 0%, rgba(8,10,6,0.55) 45%, rgba(8,10,6,0) 100%), linear-gradient(0deg, rgba(8,10,6,0.7) 0%, rgba(8,10,6,0.35) 18%, rgba(8,10,6,0) 36%); }
.hero-invited { position: absolute; z-index: 2; right: 0; bottom: 0; width: 72%; box-sizing: border-box; padding: 40px 14px 14px; text-align: right; display: block; color: inherit; cursor: pointer; -webkit-tap-highlight-color: transparent; }
.hero-invited:hover .hero-invited-logos img, .hero-invited:focus-visible .hero-invited-logos img { opacity: 1; }
.hero-invited:focus-visible { outline: 2px solid #fff; outline-offset: -4px; }
.hero .hero-invited-label { max-width: none; font-family: var(--font-head); font-size: 10px; letter-spacing: 0.2em; text-transform: uppercase; color: #d7dcc7; margin: 0 0 4px; line-height: 1.2; text-shadow: 0 1px 6px rgba(0,0,0,.85); }
.hero-invited-logos { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; align-items: center; justify-content: flex-end; gap: 2px 11px; }
.hero-invited-logos li { display: flex; align-items: center; }
.hero-invited-logos .row-break { flex-basis: 100%; height: 0; }   /* always three logos on the first row, two on the second */
.hero-invited-logos img { width: auto; display: block; filter: brightness(0) invert(1) drop-shadow(0 1px 3px rgba(0,0,0,.55)); opacity: .94; }
.hero-invited .logo-icai, .hero-invited .logo-hlcc { height: clamp(27px, 6.6vw, 46px); }
.hero-invited .logo-gls, .hero-invited .logo-ryn { height: clamp(17px, 4vw, 27px); }
.hero-invited .logo-skips { height: clamp(20px, 4.6vw, 31px); }
@media (min-width: 860px) {
  .hero-invited { right: max(12px, calc((100% - var(--maxw)) / 2 + 12px)); bottom: 70px; width: min(400px, 38vw); padding: 36px 20px 20px; }
  .hero .hero-invited-label { font-size: 12px; letter-spacing: 0.25em; margin-bottom: 8px; }
  .hero-invited-logos { gap: 7px 26px; }
  .hero-invited .logo-icai, .hero-invited .logo-hlcc { height: 68px; }
  .hero-invited .logo-gls, .hero-invited .logo-ryn { height: 44px; }
  .hero-invited .logo-skips { height: 48px; }
}
@media (min-width: 860px) { .hero-photo::before { display: none; } }

/* ---------- Mobile hero: everything (photo, Invited by, name, buttons, social) fits on the first screen ---------- */
@media (max-width: 859px) {
  .hero { display: flex; flex-direction: column; min-height: 100vh; min-height: 100svh; }
  .hero-photo { aspect-ratio: auto; flex: 1 1 0; min-height: 250px; }
  .hero-photo > img { position: absolute; inset: 0; object-position: center 28%; }
  .hero-inner { flex: none; padding: 20px 24px 26px; }
  .hero-eyebrow { font-size: 11px; letter-spacing: 0.2em; line-height: 1.5; margin-bottom: 10px; }
  .hero h1 { font-size: clamp(38px, 11.5vw, 48px); margin-bottom: 16px; }
  .hero-actions { flex-wrap: nowrap; gap: 10px; margin-bottom: 18px; }
  .hero-actions .btn { flex: 1 1 0; text-align: center; padding: 13px 8px; font-size: 11px; letter-spacing: 0.1em; white-space: nowrap; }
  .social-row { gap: 14px; }
  .social-row a { width: 36px; height: 36px; }
}

/* The hero text layer spans the whole hero on desktop; let clicks pass through to the Invited by link beneath it. */
.hero-inner { pointer-events: none; }
.hero-inner a { pointer-events: auto; }

/* Thinking page subtitle */
.thinking-sub { max-width: 560px; margin: 14px 0 0; color: var(--color-muted); font-size: clamp(16px, 1.6vw, 19px); line-height: 1.5; }

/* short phones: a slightly smaller book so the Writing label, book and buttons all fit */
@media (max-width: 859px) and (max-height: 700px) {
  .story .st-label { top: 80px; }
  .story.is-live .st-book { padding-top: 106px; --bh: min(33vh, 62vw); }
  .st-book { gap: 12px; }
  .st-book .st-side p { font-size: 13px; margin-bottom: 10px; line-height: 1.45; }
  .st-side h2 { margin: 2px 0 8px; }
}

/* Phones: two posts side by side, then the third (the question card) full width underneath */
@media (max-width: 899px) {
  .speaking-posts.phone-2-1 { grid-template-columns: 1fr 1fr; gap: 20px 12px; }
  .speaking-posts.phone-2-1 .speaking-post:nth-child(3) { grid-column: 1 / -1; }
  .speaking-posts.phone-2-1 .speaking-post.has-questions .speaking-img { max-width: none; aspect-ratio: 16 / 10; }
  .speaking-posts.phone-2-1 .speaking-post.has-questions .speaking-img { height: auto; flex: none; }
  .speaking-posts.phone-2-1 .speaking-qs .speaking-q { font-size: 14px; line-height: 1.45; }
  .speaking-posts.phone-2-1 .speaking-qs li { padding: 10px 0; gap: 12px; }
  .speaking-posts.phone-2-1 .speaking-post:not(:nth-child(3)) .speaking-excerpt { font-size: 12.5px; -webkit-line-clamp: 5; line-clamp: 5; }
  .speaking-posts.phone-2-1 .speaking-body .li-btn { width: 34px; height: 34px; }
  .speaking-posts.phone-2-1 .speaking-body .li-btn svg { width: 14px; height: 14px; }
}
