* {
  box-sizing: border-box;
}

body {
  margin: 0;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  line-height: 1.7;
  color: #222;
  background: #fff;
}

.wrap {
  width: min(550px, calc(100% - 32px));
  margin: 0 auto;
  padding: 24px 0 48px;
}

h1 {
  margin: 0 0 20px;
  font-size: 1.5rem;
}

.work-summary {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  margin: -8px 0 50px;
  color: #666;
  font-size: 0.95rem;
}

.work-summary span {
  display: inline-block;
}

a {
  color: inherit;
}

.home-link {
  margin: 0 0 20px;
  font-size: 0.95rem;
}

.post-back-link {
  margin: 16px 0 72px;
}

.post-back-link a {
  display: inline-block;
  padding: 10px 0;
}

.post-actions {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.post-actions a:last-child {
  margin-left: auto;
  white-space: nowrap;
}

.work-list {
  list-style: none;
  padding: 0;
  margin: 0;
  display: grid;
  gap: 12px;
}

.work-list li {
  margin: 0;
}

.work-list a {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 14px 16px;
  border: 1px solid #ddd;
  border-radius: 12px;
  text-decoration: none;
  background: #fafafa;
}

.work-thumb {
  flex: 0 0 72px;
  width: 72px;
  height: 72px;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  border: 1px solid #e0e0e0;
  border-radius: 8px;
  background: #fff;
}

.work-thumb img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.work-main {
  display: block;
  min-width: 0;
}

.work-main strong {
  display: block;
  font-size: 1rem;
  font-weight: 600;
}

.work-meta {
  display: block;
  margin-top: 4px;
  color: #666;
  font-size: 0.9rem;
  line-height: 1.5;
}

.post {
  position: relative;
  padding: 0 0 24px 40px;
  margin: 0 0 24px;
  border-bottom: 1px solid #e5e5e5;
}

.post:first-of-type {
  margin-top: 24px;
}

.post:first-of-type::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  top: -24px;
  border-top: 1px solid #e5e5e5;
}

.post::before {
  content: "•";
  position: absolute;
  left: 0;
  top: 0.05em;
  color: #8a8a8a;
  font-size: 28px;
  line-height: 1;
}

.post p {
  margin: 0 0 12px;
  font-size: 1.1rem;
  line-height: 1.8;
}

.post time {
  display: block;
  margin-top: 8px;
  color: #666;
  font-size: 0.9rem;
}

.post-single {
  min-height: 240px;
}

.spoiler-content {
  transition: filter 0.18s ease, opacity 0.18s ease;
}

.spoiler-gated:not(.is-open) .spoiler-content {
  filter: blur(14px);
  opacity: 0.36;
  pointer-events: none;
  user-select: none;
}

.spoiler-cover {
  position: absolute;
  inset: 0 0 24px 40px;
  z-index: 2;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 14px;
  padding: 24px;
  border: 1px solid #cfcfcf;
  border-radius: 8px;
  background: rgba(238, 238, 238, 0.9);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.55);
  text-align: center;
}

.spoiler-gated.is-open .spoiler-cover {
  display: none;
}

.spoiler-cover p {
  margin: 0;
  color: #333;
  font-size: 1rem;
  line-height: 1.6;
}

.spoiler-open-button {
  border: 1px solid #222;
  border-radius: 999px;
  background: #222;
  color: #fff;
  cursor: pointer;
  font: inherit;
  font-size: 0.95rem;
  line-height: 1;
  padding: 12px 18px;
}

.spoiler-open-button:hover,
.spoiler-open-button:focus-visible {
  background: #000;
}

.pager {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: 12px;
  margin-top: 32px;
}

.pager-top {
  margin-bottom: 40px;
}

.pager a,
.pager span {
  padding: 10px 14px;
  border: 1px solid #ddd;
  border-radius: 999px;
  text-decoration: none;
  background: #fafafa;
}

.pager a:first-child,
.pager span.hidden:first-child {
  justify-self: start;
}

.pager a:last-child,
.pager span.hidden:last-child {
  justify-self: end;
}

.pager-current {
  color: #666;
  font-size: 0.95rem;
  white-space: nowrap;
}

.pager .hidden {
  visibility: hidden;
}

.post img {
  display: block;
  width: 100%;
  max-width: 100%;
  height: auto;
  border-radius: 8px;
  margin: 0 0 12px;
  cursor: zoom-in;
}

.lightbox[hidden] {
  display: none;
}

.lightbox {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.85);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 8px;
  z-index: 1000;
}

.lightbox-image {
  max-width: calc(100vw - 16px);
  max-height: calc(100vh - 16px);
  width: auto;
  height: auto;
  border-radius: 4px;
}

.lightbox-close {
  position: absolute;
  top: 16px;
  right: 16px;
  border: 0;
  background: rgba(255, 255, 255, 0.15);
  color: white;
  font-size: 32px;
  line-height: 1;
  width: 48px;
  height: 48px;
  border-radius: 999px;
  cursor: pointer;
}

.video-wrap {
  position: relative;
  width: 100%;
  max-width: 550px;
  aspect-ratio: 16 / 9;
  margin: 0 0 12px;
}

.video-wrap iframe {
  width: 100%;
  height: 100%;
  border: 0;
  border-radius: 8px;
  display: block;
}

.spoiler-note {
  margin: 6px 0 30px;
  color: #8a3b12;
  font-size: 0.95rem;
  font-weight: 600;
  text-align: center;
  letter-spacing: 0.02em;
}

.page-kicker {
  margin: 0 0 6px;
  color: #666;
  font-size: 0.85rem;
  line-height: 1.4;
}
