:root {
  --bg: #faf8f3;
  --paper: #fffefb;
  --ink: #1f2937;
  --muted: #6b7280;
  --accent: #4a82c4;
  --blue: #4a82c4;
  --line: rgba(31, 41, 55, 0.10);
  --soft-accent: #e3edf8;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: "Plus Jakarta Sans", system-ui, sans-serif;
  color: var(--ink);
  line-height: 1.8;
  background:
    radial-gradient(circle at 88% 8%, rgba(247, 205, 182, 0.72), transparent 28%),
    radial-gradient(circle at 4% 35%, rgba(212, 229, 249, 0.82), transparent 25%),
    radial-gradient(circle at 72% 88%, rgba(255, 238, 184, 0.48), transparent 24%),
    var(--bg);
}

a {
  color: var(--accent);
  text-underline-offset: 0.18em;
}

/* TOP NAV */

.top-nav {
  position: fixed;
  inset: 0 0 auto 0;
  z-index: 50;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 28px;
  padding: 18px clamp(22px, 5vw, 64px);
  background: rgba(250, 248, 243, 0.82);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border-bottom: 1px solid rgba(31, 41, 55, 0.08);
  box-shadow: 0 2px 16px rgba(31, 41, 55, 0.06);
}

.nav-name {
  color: var(--ink);
  font-size: 1.05rem;
  font-weight: 800;
  letter-spacing: -0.03em;
  text-decoration: none;
}

.nav-links {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 22px;
}

.nav-links a {
  color: rgba(31, 41, 55, 0.74);
  text-decoration: none;
  font-size: 0.92rem;
  font-weight: 700;
}

.nav-links a:hover {
  color: var(--accent);
}

/* HERO */

.hero {
  min-height: 100vh;
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 72px 38px 112px;
  overflow: hidden;
  background-color: #ede8df;
  background-image:
    radial-gradient(circle, rgba(28,25,23,0.065) 1.4px, transparent 1.4px),
    linear-gradient(135deg, rgba(255,255,255,0.25), transparent);
  background-size: 26px 26px, cover;
}

.hero::after {
  content: "";
  position: absolute;
  inset: auto 0 -1px 0;
  height: 130px;
  background: linear-gradient(to bottom, transparent, var(--bg));
  pointer-events: none;
}

.shape {
  position: absolute;
  pointer-events: none;
  opacity: 0.95;
}

.shape-1 {
  width: 390px;
  height: 390px;
  border-radius: 50%;
  background: rgba(220, 79, 53, 0.10);
  top: -90px;
  right: -70px;
}

.shape-2 {
  width: 280px;
  height: 280px;
  border-radius: 50%;
  background: rgba(74, 130, 196, 0.12);
  bottom: 110px;
  left: -65px;
}

.shape-3 {
  width: 120px;
  height: 120px;
  border-radius: 28px;
  background: rgba(255, 205, 94, 0.26);
  right: 9%;
  bottom: 130px;
  transform: rotate(17deg);
}

.hero-inner {
  position: relative;
  z-index: 1;
  width: 100%;
  max-width: 1180px;
}

.wb-frame {
  background:
    linear-gradient(#28282E, #28282E) 0 0 / 26px 26px no-repeat,
    linear-gradient(#28282E, #28282E) 100% 0 / 26px 26px no-repeat,
    linear-gradient(#28282E, #28282E) 0 100% / 26px 26px no-repeat,
    linear-gradient(#28282E, #28282E) 100% 100% / 26px 26px no-repeat,
    linear-gradient(160deg, #D8D8DC 0%, #E9E9ED 35%, #C5C5CB 68%, #D6D6DA 100%);
  padding: 16px;
  border-radius: 8px;
  box-shadow:
    0 28px 80px rgba(28,25,23,0.23),
    0 3px 8px rgba(28,25,23,0.14);
}

.whiteboard {
  min-height: calc(100vh - 232px);
  display: grid;
  grid-template-columns: minmax(260px, 0.72fr) 1fr;
  align-items: center;
  background:
    linear-gradient(#fbfbfb, #f7f7f5),
    radial-gradient(circle at 20% 20%, rgba(74,130,196,.08), transparent 30%);
  position: relative;
  overflow: hidden;
}

.whiteboard::before {
  content: "";
  position: absolute;
  inset: 28px;
  border: 2px dashed rgba(31, 41, 55, 0.055);
  pointer-events: none;
}

.wb-left {
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 58px 48px;
  border-right: 1.5px solid rgba(28,25,23,0.07);
}

.polaroid {
  width: clamp(235px, 26vw, 370px);
  background: #fff;
  padding: 14px 14px 50px;
  box-shadow: 0 18px 48px rgba(28,25,23,0.13);
  transform: rotate(-2.8deg);
  position: relative;
}

.polaroid::before {
  content: "";
  position: absolute;
  top: -12px;
  left: 50%;
  transform: translateX(-50%) rotate(-2deg);
  width: 88px;
  height: 22px;
  background:
    repeating-linear-gradient(
      90deg,
      transparent 0px, transparent 3px,
      rgba(185, 155, 50, 0.09) 3px, rgba(185, 155, 50, 0.09) 4px
    ),
    rgba(252, 238, 150, 0.72);
  box-shadow:
    0 2px 5px rgba(0, 0, 0, 0.16),
    0 0 0 0.5px rgba(170, 140, 45, 0.28);
  z-index: 4;
}

.polaroid img {
  display: block;
  width: 100%;
  aspect-ratio: 1 / 1;
  object-fit: cover;
  background:
    linear-gradient(135deg, #e4edf8, #fff0d1);
}

.polaroid-caption {
  margin-top: 10px;
  text-align: center;
  font-family: "Caveat", cursive;
  font-size: 1.9rem;
  color: var(--muted);
}

.wb-right {
  padding: 58px 64px;
}

.eyebrow,
.section-label {
  margin: 0 0 10px;
  color: var(--accent);
  font-size: 0.74rem;
  font-weight: 800;
  letter-spacing: 0.17em;
  text-transform: uppercase;
}

.whiteboard h1 {
  max-width: 780px;
  margin: 0;
  font-size: clamp(2rem, 3.6vw, 3.2rem);
  line-height: 1.1;
  letter-spacing: -0.03em;
}

.wb-marker-title {
  font-family: "Caveat", cursive;
  font-weight: 700;
  font-size: clamp(2.8rem, 5vw, 4.4rem);
  letter-spacing: 0.01em;
  color: #1a2a4a;
  /* layered text-shadow to mimic the slight bleed and sheen of a whiteboard marker */
  text-shadow:
    0 0 1px rgba(26, 42, 74, 0.55),
    1px 1px 0px rgba(26, 42, 74, 0.08),
    0 0 18px rgba(26, 42, 74, 0.10);
  -webkit-text-stroke: 0.5px rgba(26, 42, 74, 0.18);
  filter: url(#marker-roughen);
  position: relative;
}

.subtitle {
  max-width: 650px;
  margin: 20px 0 0;
  color: var(--muted);
  font-size: clamp(1rem, 1.6vw, 1.18rem);
}

.wb-bio {
  margin: 0;
  font-size: 0.95rem;
  line-height: 1.65;
  color: rgba(31, 41, 55, 0.80);
  max-width: none;
}

/* INDEX CARD + FRIDGE MAGNET */
.wb-card {
  position: relative;
  background-color: #fffef7;
  border-radius: 3px;
  border: 1px solid rgba(0, 0, 0, 0.09);
  box-shadow:
    3px 7px 24px rgba(0, 0, 0, 0.13),
    0 1px 3px rgba(0, 0, 0, 0.07);
  margin-top: 36px;
}

.wb-card-bio {
  padding: 20px 24px 22px 58px;
  transform: rotate(-1.1deg);
  max-width: 560px;
  background-image:
    repeating-linear-gradient(
      transparent 0px, transparent 30px,
      rgba(155, 200, 240, 0.32) 30px, rgba(155, 200, 240, 0.32) 31px
    ),
    linear-gradient(
      to right,
      transparent 46px,
      rgba(210, 50, 50, 0.45) 46px, rgba(210, 50, 50, 0.45) 47.5px,
      transparent 47.5px
    );
  background-size: 100% 31px, 100% 100%;
}

.wb-card-info {
  padding: 22px 26px 24px 26px;
  transform: rotate(0.6deg);
  background-image: repeating-linear-gradient(
    transparent 0px, transparent 30px,
    rgba(155, 200, 240, 0.32) 30px, rgba(155, 200, 240, 0.32) 31px
  );
  background-size: 100% 31px;
}

.card-magnet {
  position: absolute;
  top: -13px;
  width: 24px;
  height: 24px;
  border-radius: 50%;
  z-index: 3;
  box-shadow:
    0 3px 8px rgba(0, 0, 0, 0.30),
    inset 0 -1px 2px rgba(0, 0, 0, 0.18),
    inset 0 1px 3px rgba(255, 255, 255, 0.55);
}

.card-magnet--red {
  left: calc(50% - 12px);
  background: radial-gradient(circle at 36% 30%, #ff9e9e, #c0392b);
}

.card-magnet--blue {
  left: calc(50% - 12px);
  background: radial-gradient(circle at 36% 30%, #90caf9, #1a56a0);
}

.wb-quick {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px 34px;
  margin: 0;
}

.wb-quick dt {
  margin-bottom: 4px;
  color: var(--accent);
  font-size: 0.68rem;
  font-weight: 800;
  letter-spacing: 0.15em;
  text-transform: uppercase;
}

.wb-quick dd {
  margin: 0;
  font-weight: 600;
  line-height: 1.45;
}

/* FLOWING BODY */

main {
  max-width: 980px;
  margin: 0 auto;
  padding: 0 24px;
}

section {
  scroll-margin-top: 72px;
}

.open-section {
  padding: 72px 8px;
  border-bottom: 1.5px solid var(--line);
  position: relative;
  isolation: isolate;
}

.open-section:last-of-type {
  border-bottom: none;
  padding-bottom: 100px;
}

/* PER-SECTION BACKGROUND TEXTURES
   ::before spans full viewport width (breaks out of max-width: 980px main). */

#project.open-section::before,
#log.open-section::before,
#resources.open-section::before,
#fun.open-section::before {
  content: "";
  position: absolute;
  inset: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 100vw;
  z-index: -1;
  pointer-events: none;
}

/* ─── RESEARCH PROJECT
   Network graph SVG + blue atmospheric blobs (slightly pulled back) ─── */
#project.open-section::before {
  background-image:
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='640' height='440'%3E%3Cg stroke='rgb(74,130,196)' stroke-opacity='0.2' stroke-width='1.2' fill='none'%3E%3Cline x1='88' y1='62' x2='228' y2='112'/%3E%3Cline x1='228' y1='112' x2='386' y2='68'/%3E%3Cline x1='228' y1='112' x2='178' y2='252'/%3E%3Cline x1='178' y1='252' x2='352' y2='296'/%3E%3Cline x1='386' y1='68' x2='352' y2='296'/%3E%3Cline x1='468' y1='210' x2='352' y2='296'/%3E%3Cline x1='468' y1='210' x2='386' y2='68'/%3E%3C/g%3E%3Cg fill='rgb(74,130,196)'%3E%3Ccircle cx='88' cy='62' r='5' fill-opacity='0.38'/%3E%3Ccircle cx='228' cy='112' r='7.5' fill-opacity='0.44'/%3E%3Ccircle cx='386' cy='68' r='5' fill-opacity='0.34'/%3E%3Ccircle cx='178' cy='252' r='6' fill-opacity='0.38'/%3E%3Ccircle cx='352' cy='296' r='5.5' fill-opacity='0.34'/%3E%3Ccircle cx='468' cy='210' r='4' fill-opacity='0.28'/%3E%3C/g%3E%3C/svg%3E"),
    radial-gradient(ellipse 70% 60% at 94% 5%,  rgba(74, 130, 196, 0.13), transparent 72%),
    radial-gradient(ellipse 52% 72% at -6% 95%, rgba(120, 85, 215, 0.09), transparent 65%),
    radial-gradient(ellipse 45% 45% at 50% 50%, rgba(212, 229, 249, 0.09), transparent 62%);
}

/* ─── RESEARCH LOG
   Warm amber blobs sweeping in from both sides, soft diagonal line texture ─── */
#log.open-section::before {
  background-image:
    repeating-linear-gradient(
      170deg,
      transparent 0, transparent 40px,
      rgba(175, 118, 42, 0.08) 40px, rgba(175, 118, 42, 0.08) 41px
    ),
    radial-gradient(ellipse 78% 62% at -6% 18%,  rgba(252, 192, 115, 0.42), transparent 65%),
    radial-gradient(ellipse 65% 75% at 108% 84%, rgba(255, 215, 128, 0.36), transparent 60%),
    radial-gradient(ellipse 42% 44% at 72% 8%,   rgba(255, 232, 170, 0.28), transparent 58%);
}

/* ─── RESOURCES  (cool — blue-slate ripples + indigo/blue wash) ─── */
#resources.open-section::before {
  background-image:
    radial-gradient(circle at 90% 90%, transparent 80px,  rgba(74, 118, 210, 0.18) 81px,  transparent 86px),
    radial-gradient(circle at 90% 90%, transparent 145px, rgba(74, 118, 210, 0.15) 146px, transparent 151px),
    radial-gradient(circle at 90% 90%, transparent 220px, rgba(74, 118, 210, 0.12) 221px, transparent 226px),
    radial-gradient(circle at 90% 90%, transparent 305px, rgba(74, 118, 210, 0.09) 306px, transparent 311px),
    radial-gradient(circle at 90% 90%, transparent 400px, rgba(74, 118, 210, 0.07) 401px, transparent 406px),
    radial-gradient(circle at 90% 90%, transparent 505px, rgba(74, 118, 210, 0.05) 506px, transparent 511px),
    radial-gradient(ellipse 65% 72% at 108% 108%, rgba(80, 110, 220, 0.26), transparent 65%),
    radial-gradient(ellipse 55% 62% at -6%  16%,  rgba(110, 150, 230, 0.18), transparent 60%),
    radial-gradient(ellipse 40% 45% at 50%  0%,   rgba(160, 185, 240, 0.14), transparent 58%);
}

/* ─── FUN STUFF  (warm — coral, gold, peach, rose; no cool lavender/mint) ─── */
#fun.open-section::before {
  background-image:
    radial-gradient(ellipse 58% 52% at 98%  4%,  rgba(255, 128, 90,  0.36), transparent 65%),
    radial-gradient(ellipse 50% 65% at -6%  38%, rgba(255, 200, 70,  0.34), transparent 60%),
    radial-gradient(ellipse 54% 50% at 50%  108%,rgba(255, 155, 120, 0.30), transparent 62%),
    radial-gradient(ellipse 38% 44% at 14%  92%, rgba(255, 185, 100, 0.28), transparent 58%),
    radial-gradient(ellipse 32% 38% at 86%  72%, rgba(255, 160, 150, 0.28), transparent 55%),
    radial-gradient(ellipse 44% 36% at 42%  2%,  rgba(255, 218, 80,  0.26), transparent 58%);
}

h2 {
  max-width: 780px;
  margin: 0 0 20px;
  font-size: clamp(2rem, 5vw, 4rem);
  line-height: 1;
  letter-spacing: -0.06em;
}

h3 {
  margin: 0 0 8px;
  font-size: 1.08rem;
}

p {
  max-width: 780px;
  margin: 0 0 14px;
  color: var(--muted);
  font-size: 1.03rem;
}

.feature-section {
  margin: 38px 0;
  padding: clamp(34px, 6vw, 58px);
  border-radius: 34px;
  background:
    linear-gradient(135deg, rgba(255,255,255,.74), rgba(255,255,255,.38)),
    radial-gradient(circle at 100% 0%, rgba(220,99,66,.13), transparent 32%);
  border: 1.5px solid rgba(31,41,55,0.08);
  box-shadow: 0 24px 80px rgba(31,41,55,0.065);
}

.soft-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 26px;
  margin-top: 34px;
}

.soft-grid div {
  padding-top: 22px;
  border-top: 1.5px dashed rgba(31,41,55,0.16);
}

.q-num {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: var(--soft-accent);
  color: var(--accent);
  font-size: 0.72rem;
  font-weight: 800;
  vertical-align: middle;
  margin-right: 6px;
  flex-shrink: 0;
}

.entry {
  padding: 34px 0 36px;
  border-top: 1.5px dashed rgba(31, 41, 55, 0.16);
}

.entry:first-of-type {
  margin-top: 12px;
}

.week {
  display: inline-block;
  margin-bottom: 12px;
  padding: 5px 12px;
  border-radius: 999px;
  background: var(--soft-accent);
  color: var(--accent);
  font-size: 0.78rem;
  font-weight: 800;
}

.reading-list {
  display: grid;
  gap: 20px;
  margin-top: 24px;
}

.reading-item {
  display: grid;
  grid-template-columns: 56px 1fr;
  align-items: start;
  gap: 18px;
}

.reading-item span {
  font-family: "Caveat", cursive;
  font-size: 2rem;
  color: var(--accent);
  line-height: 1;
}

.scrapbook {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 22px;
  margin-top: 30px;
}

.scrap {
  min-height: 230px;
  padding: 30px;
  border-radius: 30px;
  background: rgba(255,255,255,0.52);
  border: 1.5px solid rgba(31,41,55,0.08);
  box-shadow: 0 18px 54px rgba(31,41,55,0.045);
}

.scrap:nth-child(2) {
  transform: translateY(18px);
}

.scrap:nth-child(3) {
  transform: translateY(-8px);
}

.emoji {
  font-size: 2.5rem;
  margin-bottom: 18px;
}

footer {
  max-width: 980px;
  margin: 0 auto;
  padding: 0 24px 48px;
  color: var(--muted);
  font-size: 0.86rem;
}

/* CONTACT LINE */
.contact-line {
  margin-top: 24px;
  font-size: 0.94rem;
}

/* ACKNOWLEDGEMENTS */
.acknowledgements {
  margin-top: 40px;
  padding-top: 28px;
  border-top: 1.5px dashed rgba(31, 41, 55, 0.16);
}

.ack-label {
  margin-bottom: 6px;
  color: var(--accent);
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0.17em;
  text-transform: uppercase;
  max-width: none;
}

/* RESOURCES */
.resource-group {
  margin-top: 40px;
}

.resource-group-label {
  margin-bottom: 14px;
  color: var(--muted);
  font-size: 0.76rem;
  font-weight: 800;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

/* FUN STUFF SUBSECTIONS */
.fun-sub {
  margin-top: 56px;
  padding-top: 44px;
  border-top: 1.5px solid var(--line);
}

.fun-sub-title {
  display: flex;
  align-items: center;
  gap: 10px;
  margin: 0 0 6px;
  font-size: 1.45rem;
  font-weight: 800;
  letter-spacing: -0.03em;
}

.fun-icon {
  font-size: 1.55rem;
}

.fun-intro {
  font-style: italic;
  color: var(--muted);
  margin-bottom: 0;
}

/* PHOTO GRID */
.photo-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 14px;
  margin-top: 20px;
  max-width: 780px;
}

.photo-item img {
  display: block;
  width: 100%;
  border-radius: 12px;
  object-fit: cover;
  aspect-ratio: 4 / 3;
  box-shadow: 0 6px 20px rgba(31, 41, 55, 0.10);
}

/* ACTIVITY LOG */
.activity-log {
  list-style: none;
  padding: 0;
  margin: 14px 0 0;
  display: grid;
  gap: 12px;
}

.activity-row {
  display: flex;
  align-items: baseline;
  gap: 14px;
  color: var(--muted);
  font-size: 1.0rem;
}

.activity-date {
  flex-shrink: 0;
  padding: 4px 11px;
  border-radius: 999px;
  background: var(--soft-accent);
  color: var(--accent);
  font-size: 0.74rem;
  font-weight: 800;
  letter-spacing: 0.04em;
}

.boardgame-imgs {
  display: flex;
  gap: 14px;
  margin: 20px 0;
  flex-wrap: wrap;
}

.boardgame-imgs img {
  height: 180px;
  width: auto;
  border-radius: 10px;
  object-fit: cover;
}

/* GAME GALLERY */
.game-gallery {
  display: flex;
  gap: 18px;
  margin-top: 20px;
  flex-wrap: wrap;
}

.game-card {
  width: 220px;
  border-radius: 16px;
  overflow: hidden;
  background: rgba(255, 255, 255, 0.60);
  border: 1.5px solid rgba(31, 41, 55, 0.08);
  box-shadow: 0 8px 24px rgba(31, 41, 55, 0.07);
}

.game-card img {
  display: block;
  width: 100%;
  height: 160px;
  object-fit: cover;
}

.game-card p {
  padding: 10px 14px 14px;
  margin: 0;
  font-size: 0.88rem;
  color: var(--muted);
  max-width: none;
}

@media (max-width: 860px) {
  .top-nav {
    padding: 12px 18px;
    flex-wrap: wrap;
    align-items: flex-start;
    flex-direction: column;
    gap: 8px;
  }

  .nav-links {
    display: grid;
    grid-template-columns: repeat(3, auto);
    justify-content: start;
    gap: 8px 18px;
  }

  .nav-links a {
    font-size: 0.82rem;
  }

  .hero {
    padding: 110px 18px 96px;
  }

  .whiteboard {
    grid-template-columns: 1fr;
    min-height: auto;
  }

  .wb-left {
    border-right: none;
    border-bottom: 1.5px solid rgba(28,25,23,0.07);
    padding: 40px 24px 30px;
  }

  .wb-right {
    padding: 34px 28px 42px;
  }

  .wb-quick,
  .soft-grid,
  .scrapbook {
    grid-template-columns: 1fr;
  }

  .scrap:nth-child(2),
  .scrap:nth-child(3) {
    transform: none;
  }

  main {
    padding-top: 40px;
  }

  .photo-grid {
    grid-template-columns: 1fr;
  }

  .game-gallery {
    flex-direction: column;
  }

  .game-card {
    width: 100%;
    max-width: 340px;
  }

  .activity-row {
    flex-wrap: wrap;
    gap: 8px;
  }
}
