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

:root {
  --bg: #000000;
  --fg: #f5f5f5;
  --muted: #9a9a9a;
  --bar: #0a0a0a;
  --max: 32rem;
  --pad-x: 1.25rem;
  --bar-h: 3.5rem;
  --safe-b: env(safe-area-inset-bottom, 0px);
}

html {
  background: var(--bg);
  color: var(--fg);
  -webkit-text-size-adjust: 100%;
}

body {
  min-height: 100dvh;
  background: var(--bg);
  color: var(--fg);
  font-family: "Helvetica Neue", Helvetica, Arial, system-ui, sans-serif;
  font-weight: 400;
  line-height: 1.45;
  -webkit-font-smoothing: antialiased;
}

.page {
  max-width: var(--max);
  margin: 0 auto;
  padding-bottom: calc(var(--bar-h) + var(--safe-b) + 2.5rem);
}

/* Hero ~45–55vh, object-cover, focus ~40% vertical */
.hero {
  position: relative;
  height: clamp(45vh, 50vh, 55vh);
  min-height: 16rem;
  overflow: hidden;
  background: #111;
}

.hero-img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center 40%;
  display: block;
}

.hero-overlay {
  position: absolute;
  inset: 0;
  z-index: 1;
  pointer-events: none;
  background: linear-gradient(
    180deg,
    rgba(0, 0, 0, 0.55) 0%,
    rgba(0, 0, 0, 0.2) 35%,
    rgba(0, 0, 0, 0) 60%
  );
}

.logo {
  position: absolute;
  top: max(1rem, env(safe-area-inset-top, 0px));
  left: var(--pad-x);
  z-index: 2;
  display: block;
  line-height: 0;
}

.logo img {
  height: 2rem;
  width: auto;
  display: block;
}

.content {
  padding: 1.75rem var(--pad-x) 1rem;
}

h1 {
  font-size: clamp(1.65rem, 6.2vw, 2rem);
  font-weight: 600;
  letter-spacing: -0.02em;
  line-height: 1.15;
  text-transform: uppercase;
  color: var(--fg);
  margin-bottom: 1.25rem;
}

.body {
  display: flex;
  flex-direction: column;
  gap: 0.15rem;
  font-size: 1rem;
  color: var(--fg);
}

.body p + p {
  /* keep tight between first three lines */
}

.body .meta {
  margin-top: 0.85rem;
  color: var(--muted);
  font-size: 0.95rem;
}

.body .meta + .meta {
  margin-top: 0.15rem;
}

/* Pengzhe-style sticky bar */
.sticky-bar {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 50;
  pointer-events: none;
}

.sticky-fade {
  height: 64px;
  background: linear-gradient(
    180deg,
    rgba(0, 0, 0, 0) 0%,
    rgba(0, 0, 0, 0.85) 70%,
    var(--bar) 100%
  );
  pointer-events: none;
}

.sticky-inner {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.55rem;
  min-height: var(--bar-h);
  padding: 0.75rem var(--pad-x) calc(0.75rem + var(--safe-b));
  background: var(--bar);
  pointer-events: auto;
}

.sticky-inner a {
  color: var(--muted);
  text-decoration: none;
  font-size: 0.9rem;
  letter-spacing: 0.01em;
  pointer-events: auto;
}

.sticky-inner a:hover,
.sticky-inner a:focus-visible {
  color: var(--fg);
  outline: none;
}

.sep {
  color: var(--muted);
  opacity: 0.7;
  user-select: none;
}

@media (min-width: 640px) {
  .logo img {
    height: 2.25rem;
  }
  .content {
    padding-top: 2rem;
  }
}
