/* ishaanharish.me */

/* EB Garamond, self-hosted. One variable file covers 400-800, so the bold
   headings and the body text come from the same download. OFL licensed. */
@font-face {
  font-family: 'EB Garamond';
  src: url('fonts/eb-garamond.woff2') format('woff2');
  font-weight: 400 800;
  font-style: normal;
  font-display: swap;
}

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

body {
  padding: 0;
  background: #fff;
  color: #141414;
  font: 1.15rem/1.65 'EB Garamond', Georgia, 'Times New Roman', Times, serif;
}

main { max-width: 44rem; margin: 3rem auto 6rem; padding: 0 1.5rem; }

a { color: inherit; text-decoration: underline; text-underline-offset: 0.15em; }
a:hover { color: #000; }

/* --- top nav ---------------------------------------------------------- */

.topnav {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: clamp(1.4rem, 5vw, 3.4rem);
  padding: 2.6rem 1.5rem 0;
  font-size: 1rem;
}

.topnav .here { color: #9e9e9e; }

/* --- home ------------------------------------------------------------- */

blockquote p { font-style: italic; color: #3a3a3a; }

blockquote cite {
  display: block;
  margin-top: 0.45rem;
  font-style: normal;
  font-size: 0.9rem;
  color: #8a8a8a;
}

.hi        { margin-top: 1.9rem; }
.roles     { margin-top: 1.15rem; }
.desk-line { margin-top: 0.9rem; }

/* --- the card --------------------------------------------------------- */

.card {
  margin-top: 3.2rem;
  padding: 1.7rem;
  border: 1px solid #e2e2e2;
}

.card h2 { font-size: 1.05rem; font-weight: 600; }

.card .sub {
  margin: 0.2rem 0 1.3rem;
  font-size: 0.92rem;
  color: #6a6a6a;
}

.field { margin-bottom: 0.85rem; }

.field label {
  display: block;
  margin-bottom: 0.3rem;
  font-size: 0.85rem;
  color: #6a6a6a;
}

input, textarea {
  width: 100%;
  padding: 0.5rem 0.6rem;
  font: inherit;
  font-size: 0.95rem;
  color: #141414;
  background: #fff;
  border: 1px solid #dcdcdc;
}

textarea { resize: vertical; min-height: 6rem; }
input:focus, textarea:focus { outline: none; border-color: #999; }
::placeholder { color: #b4b4b4; }

button {
  margin-top: 0.5rem;
  padding: 0.58rem 1.2rem;
  font: inherit;
  font-size: 0.92rem;
  color: #fff;
  background: #141414;
  border: none;
  cursor: pointer;
}

button:hover { background: #000; }

/* --- bottom ----------------------------------------------------------- */

.outro { font-size: 0.95rem; color: #5a5a5a; }
.outro + .outro { margin-top: 0.7rem; }
.outro.croc { margin-top: 2.6rem; }

/* shown only when the url ends in #sent, which is where the form returns to */
.sent { display: none; }

.sent:target {
  display: block;
  margin-bottom: 1.1rem;
  padding: 0.6rem 0.8rem;
  background: #f2f2f2;
  font-size: 0.92rem;
}

/* --- sub-pages -------------------------------------------------------- */

h1 { font-size: 1.35rem; font-weight: 600; margin-bottom: 1.8rem; }

.entry { margin-bottom: 2.3rem; }
.entry h2 { font-size: 1.02rem; font-weight: 600; }

.entry .meta {
  margin: 0.1rem 0 0.5rem;
  font-size: 0.88rem;
  color: #8a8a8a;
}

.entry p { font-size: 0.98rem; color: #3a3a3a; }
.entry p + p { margin-top: 0.7rem; }

/* --- timeline --------------------------------------------------------- */

.timeline { list-style: none; margin: 0 0 1.6rem; padding: 0; }

.timeline li {
  padding-left: 8.5rem;
  text-indent: -8.5rem;
  margin-bottom: 0.95rem;
}

.when {
  display: inline-block;
  width: 8.5rem;
  vertical-align: top;
  text-indent: 0;   /* the li's hanging indent is inherited here otherwise */
  color: #8a8a8a;
}

.note { color: #7a7a7a; font-size: 0.95rem; }

/* --- reading log ------------------------------------------------------ */

.book { margin-bottom: 1.9rem; }

.book .status { display: block; font-size: 0.82rem; color: #8a8a8a; }
.book .title  { font-weight: 600; }
.book .author { color: #3a3a3a; }

.book .why {
  display: block;
  margin-top: 0.35rem;
  font-size: 0.96rem;
  font-style: italic;
  color: #5c5c5c;
}

/* --- the easter egg -------------------------------------------------- */

.egg {
  display: inline-block;
  margin-top: 3.5rem;
  line-height: 0;
  color: #141414;
  opacity: 0.16;
  text-decoration: none;
  transition: opacity 0.25s;
}

.egg:hover,
.egg:focus-visible { opacity: 1; outline: none; }

/* --- now playing (a real Spotify embed) ------------------------------- */

.np {
  position: fixed;
  right: 1.6rem;
  bottom: 1.6rem;
  z-index: 10;
  width: 320px;
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 4px 18px rgba(0, 0, 0, 0.12);
}

.np iframe { display: block; border: 0; }

/* The 44rem column and a fixed widget only coexist above ~1408px. Below
   that the player joins the page flow instead of covering the text. */
@media (max-width: 88rem) {
  .np {
    position: static;
    width: auto;
    margin: 2.8rem 0 0;
    box-shadow: none;
  }
}

@media (max-width: 40rem) {
  main { margin: 2.2rem 1.2rem 4rem; }
  .topnav { padding: 2rem 1.2rem 0; }
  .card { padding: 1.3rem; }
  .when { display: block; width: auto; }
  .timeline li { padding-left: 0; text-indent: 0; }
}
