/* angaramoksh.com — white blackboard, black ink, yellow highlighter */

:root {
  --ink: #111;
  --paper: #f0e9da;
  --faint: #8b8375;
  --line: #e6e6e6;
  --highlight: #fff176;
  --hand: 'Shantell Sans', 'Comic Sans MS', cursive;
  --body: 'Inter', -apple-system, sans-serif;
}

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

html { scroll-behavior: smooth; }

body {
  background: var(--paper);
  color: var(--ink);
  font-family: var(--body);
  font-size: 17px;
  line-height: 1.75;
  overflow-x: hidden;
}

::selection { background: var(--highlight); }

a { color: var(--ink); text-decoration-thickness: 1.5px; text-underline-offset: 3px; }
a:hover { background: var(--highlight); text-decoration: none; }

.wrap { max-width: 720px; margin: 0 auto; padding: 0 24px; }
.wrap-wide { max-width: 1040px; margin: 0 auto; padding: 0 24px; }

h1, h2, h3, .hand { font-family: var(--hand); font-weight: 600; line-height: 1.25; }
h1 { font-size: clamp(2rem, 5.5vw, 3.4rem); }
h2 { font-size: clamp(1.5rem, 3.5vw, 2.1rem); margin: 0 0 1rem; }
h3 { font-size: 1.25rem; }

mark, .hl {
  background: linear-gradient(104deg, transparent 0.5%, var(--highlight) 3%, var(--highlight) 97%, transparent 99%);
  padding: 0 4px;
  border-radius: 2px;
}

/* ---------- nav ---------- */
nav.top {
  display: flex; justify-content: space-between; align-items: center;
  max-width: 1040px; margin: 0 auto; padding: 22px 24px;
  font-family: var(--hand); font-size: 1.05rem;
}
nav.top .logo { font-size: 1.3rem; font-weight: 700; text-decoration: none; }
nav.top .logo:hover { background: none; transform: rotate(-2deg); display: inline-block; }
nav.top .links a { margin-left: 22px; text-decoration: none; }
nav.top .links a:hover { background: var(--highlight); }

/* ---------- hero ---------- */
.hero { text-align: center; padding: 40px 24px 10px; position: relative; }
.hero h1 { max-width: 780px; margin: 0 auto 14px; }
.hero .sub { color: var(--faint); font-family: var(--hand); font-size: 1.15rem; }
.hero-stage { max-width: 860px; margin: 10px auto 0; }
.hero-stage svg { width: 100%; height: auto; display: block; }

.bio-strip {
  display: flex; flex-wrap: wrap; justify-content: center; gap: 10px 14px;
  padding: 18px 24px 8px; font-family: var(--hand); font-size: 1rem; color: var(--ink);
}
.bio-strip span {
  border: 1.8px solid var(--ink); border-radius: 30px 8px 26px 10px / 10px 24px 8px 28px;
  padding: 4px 16px; transform: rotate(-0.6deg);
}
.bio-strip span:nth-child(2n) { transform: rotate(0.8deg); }

/* ---------- numbers ---------- */
.numbers { display: flex; flex-wrap: wrap; justify-content: center; gap: 34px; padding: 44px 24px 20px; text-align: center; }
.numbers .n { font-family: var(--hand); }
.numbers .n b { display: block; font-size: 2rem; }
.numbers .n span { color: var(--faint); font-size: 0.95rem; }

/* ---------- sections / feed ---------- */
section.block { padding: 56px 0 8px; }
.sec-head { display: flex; align-items: baseline; gap: 14px; margin-bottom: 6px; }
.sec-head .doodle-ic { width: 40px; height: 40px; flex: none; }
.sec-head p.blurb { color: var(--faint); font-family: var(--hand); }

.cards { display: grid; grid-template-columns: repeat(auto-fill, minmax(290px, 1fr)); gap: 18px; margin-top: 22px; }
.card {
  border: 1.8px solid var(--ink);
  border-radius: 16px 5px 18px 6px / 6px 16px 5px 18px;
  padding: 20px 20px 16px; text-decoration: none; display: block;
  transition: transform 0.18s ease, box-shadow 0.18s ease;
  background: var(--paper);
}
.card:hover { background: var(--paper); transform: rotate(-0.8deg) translateY(-3px); box-shadow: 4px 5px 0 var(--ink); }
.card h3 { margin-bottom: 6px; }
.card p { color: var(--faint); font-size: 0.95rem; line-height: 1.5; }
.card .tag { font-family: var(--hand); font-size: 0.85rem; background: var(--highlight); padding: 1px 8px; border-radius: 4px; }

/* ---------- media placeholder boxes ---------- */
.media-box {
  border: 2px dashed var(--ink);
  border-radius: 14px 4px 16px 5px / 5px 14px 4px 16px;
  background: repeating-linear-gradient(-45deg, var(--paper), var(--paper) 14px, rgba(0,0,0,0.03) 14px, rgba(0,0,0,0.03) 28px);
  padding: 34px 20px; margin: 30px 0; text-align: center;
  font-family: var(--hand);
}
.media-box b { font-size: 1.2rem; display: block; }
.media-box span { color: var(--faint); font-size: 0.95rem; }
.media-row { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 16px; margin: 30px 0; }
.media-row .media-box { margin: 0; padding: 26px 14px; }

/* ---------- scribbles ---------- */
.scribbles { position: relative; padding: 60px 0 30px; }
.scribble {
  font-family: var(--hand); font-size: 1.15rem; max-width: 380px;
  border: 1.8px solid var(--ink);
  border-radius: 20px 6px 22px 8px / 8px 20px 6px 22px;
  padding: 16px 20px; margin: 22px auto; background: var(--paper);
  transform: rotate(-1.2deg);
}
.scribble:nth-child(2n) { transform: rotate(1.4deg); }
.scribble:nth-child(3n) { transform: rotate(-0.5deg); }

/* ---------- closer ---------- */
.closer { text-align: center; padding: 90px 24px 60px; }
.closer h2 { font-size: clamp(1.6rem, 4vw, 2.4rem); }
.closer .media-box { max-width: 420px; margin: 26px auto; }

/* ---------- footer ---------- */
footer { border-top: 1.8px solid var(--ink); padding: 36px 24px 60px; text-align: center; font-family: var(--hand); }
footer .flinks { display: flex; flex-wrap: wrap; justify-content: center; gap: 20px; margin: 14px 0; }
footer .small { color: var(--faint); font-size: 0.9rem; margin-top: 14px; font-family: var(--body); }

/* ---------- post page ---------- */
.post-head { padding: 30px 0 8px; }
.post-head .meta { color: var(--faint); font-family: var(--hand); margin-top: 6px; }
.post-body { padding: 14px 0 60px; }
.post-body p { margin: 0 0 1.3em; }
.post-body h2 { margin-top: 2em; }
.post-nav { display: flex; justify-content: space-between; gap: 20px; padding: 0 0 70px; font-family: var(--hand); }

/* ---------- floating doodles ---------- */
.floater {
  position: fixed; pointer-events: none; z-index: -1; opacity: 0.5;
  animation: floaty 9s ease-in-out infinite;
}
@keyframes floaty {
  0%, 100% { transform: translateY(0) rotate(-3deg); }
  50% { transform: translateY(-18px) rotate(4deg); }
}

/* scroll-reveal */
.reveal { opacity: 0; transform: translateY(22px); transition: opacity 0.6s ease, transform 0.6s ease; }
.reveal.in { opacity: 1; transform: none; }

@media (prefers-reduced-motion: reduce) {
  .floater { animation: none; }
  .reveal { opacity: 1; transform: none; transition: none; }
}

@media (max-width: 640px) {
  nav.top .links a { margin-left: 12px; font-size: 0.95rem; }
  .numbers { gap: 20px; }
}

/* ---------- hero sub, intro, coffee ---------- */
.sub-plain { color: var(--faint); font-size: 1.05rem; max-width: 560px; margin: 0 auto; }
.intro { line-height: 2; font-size: 1.05rem; }
.coffee { text-align: center; padding: 20px 24px 90px; }
.coffee h2 { font-size: clamp(1.8rem, 4.5vw, 2.6rem); }
.coffee-links { display: flex; flex-direction: column; align-items: center; gap: 12px; font-family: var(--hand); font-size: 1.05rem; }
.coffee-btn {
  border: 2px solid var(--ink); text-decoration: none; padding: 10px 30px; font-size: 1.25rem; font-weight: 700;
  border-radius: 30px 10px 28px 12px / 12px 26px 10px 30px; transform: rotate(-1deg);
  transition: transform 0.15s ease, box-shadow 0.15s ease;
}
.coffee-btn:hover { background: var(--highlight); transform: rotate(1deg) scale(1.04); box-shadow: 3px 4px 0 var(--ink); }

/* ---------- theme toggle + dark theme ---------- */
#theme-toggle { cursor: pointer; border: none; background: none; font-family: var(--hand); font-size: 1.05rem; padding: 2px 10px; border-radius: 8px; color: var(--ink); }
#theme-toggle:hover { background: var(--highlight); color: #111; }

.theme-chooser {
  position: fixed; inset: 0; background: rgba(0,0,0,0.45); z-index: 50;
  display: flex; align-items: center; justify-content: center;
}
.theme-chooser .box {
  background: var(--paper); color: var(--ink); border: 2px solid var(--ink); text-align: center;
  border-radius: 22px 8px 24px 10px / 10px 22px 8px 24px; padding: 34px 40px; font-family: var(--hand);
}
.theme-chooser h3 { font-size: 1.5rem; margin-bottom: 18px; }
.theme-chooser button {
  font-family: var(--hand); font-size: 1.1rem; font-weight: 700; cursor: pointer; margin: 0 8px;
  background: var(--paper); color: var(--ink); border: 2px solid var(--ink); padding: 10px 26px;
  border-radius: 26px 9px 24px 11px / 11px 24px 9px 26px;
}
.theme-chooser button:hover { background: var(--highlight); color: #111; }

html[data-theme="dark"] {
  --ink: #f0efe9;
  --paper: #161616;
  --faint: #9a9a93;
  --line: #333;
  --highlight: #ffd94a;
}
html[data-theme="dark"] mark, html[data-theme="dark"] .hl { color: #111; }
html[data-theme="dark"] .card:hover { box-shadow: 4px 5px 0 var(--highlight); }
html[data-theme="dark"] .media-box { background: repeating-linear-gradient(-45deg, #161616, #161616 14px, #1d1d1d 14px, #1d1d1d 28px); }
html[data-theme="dark"] .scribble { background: #161616; }
html[data-theme="dark"] .tag { color: #111; }
html[data-theme="dark"] .hero-stage svg, html[data-theme="dark"] .floater svg { filter: invert(1) hue-rotate(180deg); }
html[data-theme="dark"] .coffee-btn:hover { box-shadow: 3px 4px 0 var(--highlight); }

/* ---------- real media ---------- */
.ph { margin: 30px 0; text-align: center; }
.ph a { display: inline-block; background: none; }
.ph a:hover { background: none; }
.ph img {
  max-width: 100%; max-height: 68vh; width: auto; display: block; margin: 0 auto;
  border: 2px solid var(--ink);
  border-radius: 14px 5px 16px 6px / 6px 14px 5px 16px;
  transition: transform 0.18s ease, box-shadow 0.18s ease;
}
.ph a:hover img { transform: rotate(-0.6deg) scale(1.012); box-shadow: 4px 5px 0 var(--ink); }

/* adaptive masonry gallery — natural ratios, nobody gets cropped out */
.gallery { columns: 3 260px; column-gap: 16px; margin: 30px 0; }
.gallery .ph, .gallery .media-box { break-inside: avoid; margin: 0 0 16px; }
.gallery .ph img { width: 100%; max-height: none; }

/* feature card — the star image */
.feature-card { text-align: center; padding: 40px 24px 10px; }
.feature-card a { display: inline-block; width: min(560px, 92%); background: none; position: relative; }
.feature-card img {
  width: 100%; display: block; border: 2.4px solid var(--ink);
  border-radius: 18px 7px 20px 8px / 8px 18px 7px 20px;
  transform: rotate(-1.4deg);
  box-shadow: 6px 7px 0 var(--ink);
  transition: transform 0.2s ease;
}
.feature-card a:hover img { transform: rotate(0.4deg) scale(1.015); }
.feature-card .tape {
  position: absolute; top: -12px; left: 50%; width: 110px; height: 26px;
  background: var(--highlight); opacity: 0.85; transform: translateX(-50%) rotate(-3deg);
  border-radius: 2px;
}
.feature-card figcaption { font-family: var(--hand); font-size: 1.2rem; margin-top: 18px; }
.sheldon-sq { aspect-ratio: 1 / 1; object-fit: cover; width: min(340px, 90%); }
.hello-clip {
  width: min(340px, 88%); aspect-ratio: 1 / 1; object-fit: cover; display: block;
  margin: 30px auto 0; border: 2px solid var(--ink);
  border-radius: 16px 6px 18px 7px / 7px 16px 6px 18px;
}

/* ---------- mobile ---------- */
@media (max-width: 640px) {
  body { font-size: 16px; }
  nav.top { flex-wrap: wrap; gap: 6px 0; padding: 14px 16px; }
  nav.top .links { display: flex; flex-wrap: wrap; gap: 8px 14px; }
  nav.top .links a { margin-left: 0; }
  .hero { padding: 22px 16px 6px; }
  .hero h1 { font-size: 1.75rem; }
  .bio-strip span { font-size: 0.9rem; padding: 3px 12px; }
  .numbers { gap: 18px 26px; padding: 30px 16px 12px; }
  .numbers .n b { font-size: 1.5rem; }
  .numbers .n span { font-size: 0.85rem; }
  .intro { line-height: 1.9; font-size: 1rem; }
  .cards { grid-template-columns: 1fr; }
  .media-row { grid-template-columns: 1fr 1fr; }
  .scribble { font-size: 1.05rem; }
  .coffee-btn { font-size: 1.15rem; padding: 9px 24px; }
  .theme-chooser .box { padding: 26px 20px; margin: 0 14px; }
  .post-nav { flex-direction: column; gap: 10px; }
}

/* ---------- bento grid ---------- */
.bento {
  display: grid; grid-template-columns: repeat(4, 1fr);
  grid-auto-rows: 170px; grid-auto-flow: dense; gap: 14px; margin: 30px 0;
}
.bento .tile {
  display: block; overflow: hidden; background: none;
  border: 2px solid var(--ink);
  border-radius: 16px 6px 18px 7px / 7px 16px 6px 18px;
  transition: transform 0.18s ease, box-shadow 0.18s ease;
}
.bento .tile:hover { background: none; transform: rotate(-0.7deg) scale(1.015); box-shadow: 4px 5px 0 var(--ink); z-index: 2; }
.bento .tile img { width: 100%; height: 100%; object-fit: cover; display: block; }
.bento .t-2x2 { grid-column: span 2; grid-row: span 2; }
.bento .t-2x1 { grid-column: span 2; }
.bento .media-box { margin: 0; display: flex; flex-direction: column; justify-content: center; }
@media (max-width: 640px) {
  .bento { grid-template-columns: repeat(2, 1fr); grid-auto-rows: 140px; }
}

/* ---------- paper texture ---------- */
body::before {
  content: ""; position: fixed; inset: 0; z-index: -3; pointer-events: none;
  opacity: 0.8;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='200' height='200'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.8' numOctaves='3' stitchTiles='stitch'/%3E%3CfeColorMatrix type='saturate' values='0'/%3E%3CfeComponentTransfer%3E%3CfeFuncA type='linear' slope='0.13'/%3E%3C/feComponentTransfer%3E%3C/filter%3E%3Crect width='200' height='200' filter='url(%23n)'/%3E%3C/svg%3E");
}
html[data-theme="dark"] body::after {
  content: ""; position: fixed; inset: 0; z-index: -2; pointer-events: none;
  opacity: 0.5;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='700' height='700'%3E%3Cg stroke='%23ffffff' fill='none' stroke-linecap='round'%3E%3Cpath d='M60 120 C 180 90, 320 140, 470 105' stroke-width='1.2' opacity='0.05'/%3E%3Cpath d='M520 300 C 560 380, 600 420, 650 520' stroke-width='0.9' opacity='0.04'/%3E%3Cpath d='M100 520 C 220 500, 260 560, 380 545' stroke-width='1.4' opacity='0.045'/%3E%3Cpath d='M300 200 C 340 260, 330 320, 370 360' stroke-width='0.7' opacity='0.035'/%3E%3Cpath d='M600 80 C 630 120, 660 130, 690 180' stroke-width='1.1' opacity='0.04'/%3E%3Cpath d='M40 320 C 90 310, 140 340, 210 330' stroke-width='0.8' opacity='0.03'/%3E%3Cpath d='M420 620 C 480 600, 540 640, 620 615' stroke-width='1.3' opacity='0.05'/%3E%3C/g%3E%3C/svg%3E");
}

/* ---------- tile labels (review mode) ---------- */
.bento .tile { position: relative; }
.bento .tlabel {
  position: absolute; top: 6px; left: 6px; font-family: var(--hand); font-size: 0.95rem;
  background: var(--highlight); color: #111; padding: 0 8px; border-radius: 6px; border: 1.5px solid #111;
}

/* ---------- candidate strips ---------- */
.cands { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; margin: -14px 0 30px; }
.cands > span { width: 100%; color: var(--faint); font-size: 0.95rem; }
.cand { position: relative; display: block; width: 86px; height: 64px; border: 1.5px solid var(--ink); border-radius: 8px 3px 9px 4px / 4px 8px 3px 9px; overflow: hidden; background: none; }
.cand:hover { background: none; transform: scale(1.06); }
.cand img { width: 100%; height: 100%; object-fit: cover; display: block; }
.cand b { position: absolute; bottom: 2px; left: 4px; font-family: var(--hand); font-size: 0.85rem; background: var(--highlight); color: #111; padding: 0 5px; border-radius: 4px; }

/* ---------- lightbox ---------- */
.lightbox {
  position: fixed; inset: 0; z-index: 60; background: rgba(0,0,0,0.82);
  display: flex; flex-direction: column; align-items: center; justify-content: center; padding: 30px;
}
.lightbox img { max-width: min(92vw, 1100px); max-height: 76vh; border: 3px solid #fff; border-radius: 10px; }
.lightbox .lb-cap { color: #fff; font-family: var(--hand); font-size: 1.1rem; margin-top: 14px; text-align: center; max-width: 700px; }
.lightbox .lb-close { position: absolute; top: 18px; right: 26px; color: #fff; font-family: var(--hand); font-size: 1.6rem; cursor: pointer; background: none; border: none; }

/* ---------- feature caption ---------- */
.feature-card figcaption { max-width: 560px; margin: 18px auto 0; }
.cap-main { display: block; font-size: 1.2rem; }
.cap-tags { display: flex; flex-wrap: wrap; justify-content: center; gap: 8px 10px; margin: 12px 0 6px; }
.cap-tags a {
  font-size: 0.95rem; text-decoration: none; padding: 2px 14px;
  border: 1.6px solid var(--ink);
  border-radius: 22px 8px 20px 9px / 9px 20px 8px 22px;
  transform: rotate(-1deg);
}
.cap-tags a:nth-child(2) { transform: rotate(0.8deg); }
.cap-tags a:nth-child(3) { transform: rotate(-0.4deg); }
.cap-tags a:hover { background: var(--highlight); color: #111; }
.cap-sub { display: block; color: var(--faint); font-size: 0.9rem; }

.rt { color: var(--faint); font-size: 0.85rem; margin-left: 6px; }

/* ---------- capita row under feature card ---------- */
.capita-row { display: flex; flex-wrap: wrap; justify-content: center; gap: 14px; margin-top: 22px; }
.capita-row a { position: relative; display: block; width: min(300px, 44%); background: none; border: 2px solid var(--ink); border-radius: 14px 5px 16px 6px / 6px 14px 5px 16px; overflow: hidden; }
.capita-row a:hover { background: none; transform: rotate(-0.6deg) scale(1.02); box-shadow: 4px 5px 0 var(--ink); }
.capita-row img { width: 100%; height: 100%; aspect-ratio: 3 / 2; object-fit: cover; display: block; }
