:root {
  --bg: #eeebe4;
  --card: #ffffff;
  --paper: #fbf9f5;
  --ink: #17171b;
  --soft: #74757f;
  --faint: #b4b4bb;
  --line: rgba(23, 23, 27, 0.08);
  --accent: #e0592a;
  --lift: #f6f3ee;
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html, body { height: 100%; }
body {
  background:
    radial-gradient(90% 70% at 50% 0%, #f6f4ef 0%, rgba(246, 244, 239, 0) 62%),
    radial-gradient(60% 50% at 85% 100%, rgba(224, 89, 42, 0.07), rgba(224, 89, 42, 0) 70%),
    var(--bg);
  color: var(--ink);
  font-family: "Mona Sans Variable", "Mona Sans", system-ui, -apple-system, sans-serif;
  -webkit-font-smoothing: antialiased;
  overflow: hidden;
}
body::after {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  opacity: 0.05;
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='160' height='160'><filter id='n'><feTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='2' stitchTiles='stitch'/></filter><rect width='160' height='160' filter='url(%23n)'/></svg>");
}

button { font: inherit; color: inherit; background: none; border: 0; cursor: pointer; }

.stage {
  position: relative;
  min-height: 100vh;
  min-height: 100svh;
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  place-items: center;
  padding: 12px;
}

/* the window: every measure inside is in em, and the em follows both the width and the height of the window */
.win {
  position: relative;
  font-size: clamp(8.5px, min(3.55vw, 2.72vh), 17.5px);
  width: min(26em, 100%);
  height: 33em;
  display: flex;
  flex-direction: column;
  border-radius: 1.35em;
  background: linear-gradient(180deg, #ffffff 0%, #fcfbf8 100%);
  box-shadow:
    0 0 0 1px rgba(23, 23, 27, 0.07),
    0 1px 0 0 rgba(255, 255, 255, 0.95) inset,
    0 1px 2px rgba(23, 23, 27, 0.05),
    0 8px 18px -8px rgba(23, 23, 27, 0.12),
    0 34px 70px -28px rgba(80, 40, 20, 0.28);
  overflow: hidden;
  isolation: isolate;
}
.win__sheen {
  position: absolute;
  inset: 0;
  border-radius: inherit;
  pointer-events: none;
  z-index: 4;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.5) 0%, rgba(255, 255, 255, 0) 8%);
  box-shadow: 0 0 0 1px rgba(255, 255, 255, 0.4) inset;
}

/* the browser chrome */
.chrome {
  position: relative;
  z-index: 3;
  flex: none;
  display: flex;
  align-items: center;
  gap: 0.6em;
  height: 2.9em;
  padding: 0 0.85em;
  background: linear-gradient(180deg, #f8f6f2, #f3f1ec);
  border-bottom: 1px solid var(--line);
}
.chrome svg { width: 1.05em; height: 1.05em; fill: none; stroke: var(--faint); stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; }
.chrome__nav { display: flex; gap: 0.25em; }
.chrome__nav svg:first-child { stroke: var(--soft); }
.chrome__read { margin-left: auto; display: flex; }
.url {
  flex: 1;
  min-width: 0;
  display: flex;
  align-items: center;
  gap: 0.3em;
  height: 1.85em;
  padding: 0 0.7em;
  border-radius: 0.7em;
  background: #ffffff;
  box-shadow: 0 0 0 1px rgba(23, 23, 27, 0.06), 0 1px 2px rgba(23, 23, 27, 0.04);
  font-size: 0.74em;
  color: var(--soft);
  white-space: nowrap;
  overflow: hidden;
}
.url__lock { width: 1.1em !important; height: 1.1em !important; stroke: var(--soft) !important; flex: none; }
.url__host { color: var(--faint); }
.url__path { position: relative; display: inline-grid; color: var(--ink); font-weight: 520; overflow: hidden; height: 1.4em; line-height: 1.4em; min-width: 0; }
.url__a, .url__b { grid-area: 1 / 1; overflow: hidden; text-overflow: ellipsis; }
.url__b { opacity: 0; }

.screen { position: relative; flex: 1; min-height: 0; overflow: hidden; }

/* the list of posts */
.list { position: absolute; inset: 0; padding: 1.35em 1.05em 1em; }
.blog { display: flex; align-items: center; gap: 0.7em; padding: 0 0.35em; }
.blog__mono {
  flex: none;
  display: grid;
  place-items: center;
  width: 2.5em;
  height: 2.5em;
  border-radius: 50%;
  background: radial-gradient(120% 100% at 30% 20%, #f08a5c, #c2421a);
  color: #fff;
  font-size: 0.86em;
  font-weight: 640;
  letter-spacing: 0.02em;
  box-shadow: 0 0 0 1px rgba(23, 23, 27, 0.06), 0 2px 6px -2px rgba(194, 66, 26, 0.5), 0 1px 0 rgba(255, 255, 255, 0.35) inset;
}
.blog__who { min-width: 0; flex: 1; }
.blog__name { font-family: "Fraunces Variable", Georgia, serif; font-size: 1.22em; font-weight: 600; letter-spacing: -0.01em; line-height: 1.15; font-variation-settings: "opsz" 48; }
.blog__line { font-size: 0.74em; color: var(--soft); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.sub {
  flex: none;
  height: 2.2em;
  padding: 0 0.95em;
  border-radius: 999px;
  background: var(--ink);
  color: #fff;
  font-size: 0.74em;
  font-weight: 560;
  box-shadow: 0 1px 0 rgba(255, 255, 255, 0.18) inset, 0 4px 10px -4px rgba(23, 23, 27, 0.5);
}

.sec { display: flex; justify-content: space-between; align-items: baseline; padding: 1.5em 0.35em 0.55em; font-size: 0.74em; font-weight: 560; color: var(--ink); letter-spacing: 0.02em; }
.sec__n { color: var(--faint); font-weight: 500; }

.rows { list-style: none; }
.row { position: relative; }
.row + .row .row__rule { opacity: 1; }
.row__rule { position: absolute; left: 0.85em; right: 0.85em; top: 0; height: 1px; background: var(--line); opacity: 0; transform-origin: 0 50%; }
.row__in {
  position: relative;
  display: flex;
  align-items: center;
  gap: 0.85em;
  padding: 0.85em 0.75em;
  border-radius: 0.95em;
  cursor: pointer;
  outline: none;
}
.row__bg {
  position: absolute;
  inset: 0;
  border-radius: inherit;
  background: var(--lift);
  box-shadow: 0 0 0 1px rgba(23, 23, 27, 0.04);
  opacity: 0;
  transition: opacity 0.28s ease;
}
.row.is-hover .row__bg { opacity: 1; }
.row__in:focus-visible .row__bg { opacity: 1; box-shadow: 0 0 0 2px var(--accent); }
.tile {
  position: relative;
  flex: none;
  width: 3.5em;
  height: 3.5em;
  border-radius: 0.7em;
  overflow: hidden;
  box-shadow: 0 0 0 1px rgba(23, 23, 27, 0.06), 0 3px 8px -4px rgba(23, 23, 27, 0.3);
}
.tile__art { position: absolute; inset: 0; transition: transform 0.5s cubic-bezier(0.2, 0.8, 0.2, 1); }
.row.is-hover .tile__art { transform: scale(1.07); }
.tile::after, .cover::after {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
  pointer-events: none;
  box-shadow: 0 0 0 1px rgba(255, 255, 255, 0.22) inset;
  background: linear-gradient(160deg, rgba(255, 255, 255, 0.22), rgba(255, 255, 255, 0) 40%);
}
.art { display: block; width: 100%; height: 100%; }
.row__txt { position: relative; flex: 1; min-width: 0; }
.row__title { font-family: "Fraunces Variable", Georgia, serif; font-size: 1em; font-weight: 560; line-height: 1.22; letter-spacing: -0.005em; font-variation-settings: "opsz" 24; transform-origin: 0 0; }
.row__date { display: inline-block; margin-top: 0.35em; font-size: 0.72em; color: var(--soft); font-weight: 500; }
.row__side { position: relative; flex: none; display: flex; flex-direction: column; align-items: flex-end; gap: 0.5em; }
.row__read { font-size: 0.68em; color: var(--faint); font-weight: 500; white-space: nowrap; }
.row__chev { width: 1em; height: 1em; fill: none; stroke: var(--faint); stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; transition: transform 0.35s cubic-bezier(0.3, 1.6, 0.5, 1), stroke 0.2s; }
.row.is-hover .row__chev { transform: translateX(2px); stroke: var(--ink); }

/* the surface that grows from the row into the page */
.sheet {
  position: absolute;
  left: 0;
  top: 0;
  width: 0;
  height: 0;
  border-radius: 0.95em;
  background: var(--lift);
  opacity: 0;
  visibility: hidden;
  z-index: 1;
  pointer-events: none;
}

/* the open post */
.post { position: absolute; inset: 0; z-index: 2; visibility: hidden; }
.bar {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 2.9em;
  padding: 0 0.8em;
}
.back {
  display: inline-flex;
  align-items: center;
  gap: 0.25em;
  height: 2em;
  padding: 0 0.75em 0 0.45em;
  border-radius: 999px;
  font-size: 0.8em;
  font-weight: 560;
  background: #ffffff;
  box-shadow: 0 0 0 1px rgba(23, 23, 27, 0.07), 0 1px 2px rgba(23, 23, 27, 0.05), 0 4px 10px -6px rgba(23, 23, 27, 0.25);
}
.back svg { width: 1.15em; height: 1.15em; fill: none; stroke: currentColor; stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; transition: transform 0.35s cubic-bezier(0.3, 1.6, 0.5, 1); }
.back:focus-visible, .save:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.bar__name { position: absolute; left: 50%; transform: translateX(-50%); font-family: "Fraunces Variable", Georgia, serif; font-size: 0.84em; font-weight: 600; font-variation-settings: "opsz" 24; color: var(--soft); }
.save { display: grid; place-items: center; width: 2em; height: 2em; border-radius: 50%; }
.save svg { width: 1.2em; height: 1.2em; fill: transparent; stroke: var(--ink); stroke-width: 1.5; stroke-linejoin: round; overflow: visible; }
.save__shape { transition: fill 0.25s ease, stroke 0.25s ease; }
.save.is-on .save__shape { fill: var(--accent); stroke: var(--accent); }
.prog { position: absolute; left: 0; right: 0; bottom: 0; height: 1px; background: var(--line); }
.prog i { position: absolute; inset: 0; background: var(--accent); transform-origin: 0 50%; transform: scaleX(0); }

.post__page {
  position: relative;
  padding: 0.95em 1.25em 0;
  height: calc(100% - 2.9em);
  display: flex;
  flex-direction: column;
}
.cover {
  position: relative;
  flex: none;
  height: 7.8em;
  border-radius: 1em;
  overflow: hidden;
  box-shadow: 0 0 0 1px rgba(23, 23, 27, 0.05), 0 10px 24px -14px rgba(23, 23, 27, 0.45);
  will-change: transform, clip-path;
}
.cover__art { position: absolute; inset: 0; transform-origin: 50% 50%; }
.cover__grain {
  position: absolute;
  inset: 0;
  opacity: 0.14;
  mix-blend-mode: overlay;
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='120' height='120'><filter id='n'><feTurbulence type='fractalNoise' baseFrequency='1.1' numOctaves='2' stitchTiles='stitch'/></filter><rect width='120' height='120' filter='url(%23n)'/></svg>");
}
.meta { flex: none; display: flex; align-items: center; gap: 0.6em; margin-top: 1em; font-size: 0.74em; color: var(--soft); font-weight: 500; white-space: nowrap; }
.tag { color: var(--accent); font-weight: 600; letter-spacing: 0.02em; }
.meta__date, .meta__read { display: inline-block; }
.meta__sep { width: 1px; height: 0.95em; background: var(--faint); opacity: 0.6; }
.title {
  flex: none;
  margin-top: 0.4em;
  font-family: "Fraunces Variable", Georgia, serif;
  font-size: 1.72em;
  font-weight: 560;
  line-height: 1.12;
  letter-spacing: -0.018em;
  font-variation-settings: "opsz" 72;
  transform-origin: 0 0;
  text-wrap: balance;
}
.body {
  flex: 1;
  min-height: 0;
  overflow: hidden;
  margin-top: 0.85em;
  font-size: 0.86em;
  line-height: 1.58;
  color: #3b3c44;
  -webkit-mask-image: linear-gradient(180deg, #000 55%, transparent 96%);
  mask-image: linear-gradient(180deg, #000 55%, transparent 96%);
}
.body p + p { margin-top: 0.7em; }
.body p:first-child::first-letter { font-family: "Fraunces Variable", Georgia, serif; font-weight: 600; color: var(--ink); }
.ln { display: block; overflow: hidden; padding-bottom: 0.06em; margin-bottom: -0.06em; }
.ln__in { display: block; white-space: nowrap; will-change: transform; }

@media (hover: hover) {
  .back:hover svg { transform: translateX(-2px); }
  .sub:hover { background: #2a2a30; }
  .save:hover { background: rgba(23, 23, 27, 0.05); }
}

.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

.ghost {
  position: fixed;
  left: 0;
  top: 0;
  width: 22px;
  height: 22px;
  pointer-events: none;
  fill: #ffffff;
  stroke: #17171b;
  stroke-width: 1.4;
  stroke-linejoin: round;
  filter: drop-shadow(0 2px 4px rgba(23, 23, 27, 0.35));
  opacity: 0;
  visibility: hidden;
  z-index: 5;
}
