@charset "UTF-8";

:root {
  --night: #11140f;
  --night-soft: #181d16;
  --panel: #1e241b;
  --panel-light: #252c21;
  --cream: #f3ead7;
  --cream-soft: #d8cfbc;
  --muted: #9f9f90;
  --orange: #f1a326;
  --gold: #ffc861;
  --leaf: #708269;
  --line: rgba(243, 234, 215, 0.14);
  --line-strong: rgba(243, 234, 215, 0.28);
  --max-width: 1240px;
  --radius: 2px;
  --font-sans: "Hiragino Kaku Gothic ProN", "Yu Gothic", "Meiryo", system-ui, sans-serif;
  --font-serif: "Yu Mincho", "Hiragino Mincho ProN", serif;
}

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

html {
  scroll-behavior: smooth;
  color-scheme: dark;
}

body {
  margin: 0;
  min-width: 320px;
  background:
    radial-gradient(circle at 82% 8%, rgba(241, 163, 38, 0.12), transparent 24rem),
    radial-gradient(circle at 4% 42%, rgba(112, 130, 105, 0.11), transparent 28rem),
    linear-gradient(rgba(255,255,255,0.018) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255,255,255,0.018) 1px, transparent 1px),
    var(--night);
  background-size: auto, auto, 44px 44px, 44px 44px, auto;
  color: var(--cream);
  font-family: var(--font-sans);
  line-height: 1.75;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

a { color: inherit; }
button, input, textarea, select { font: inherit; }
img { max-width: 100%; display: block; }

::selection {
  background: var(--orange);
  color: var(--night);
}

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

.skip-link {
  position: fixed;
  z-index: 1000;
  top: 1rem;
  left: 1rem;
  transform: translateY(-180%);
  background: var(--cream);
  color: var(--night);
  padding: 0.65rem 1rem;
  text-decoration: none;
  font-weight: 700;
}

.skip-link:focus { transform: translateY(0); }

:focus-visible {
  outline: 2px solid var(--gold);
  outline-offset: 4px;
}

.site-header,
main,
.site-footer {
  width: min(calc(100% - 48px), var(--max-width));
  margin-inline: auto;
}

.site-header {
  min-height: 96px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 2rem;
  border-bottom: 1px solid var(--line);
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 0.9rem;
  color: var(--cream);
  text-decoration: none;
}

.brand-copy {
  display: grid;
  line-height: 1;
  gap: 0.4rem;
}

.brand-copy strong {
  font-size: 0.93rem;
  letter-spacing: 0.18em;
}

.brand-copy small {
  color: var(--muted);
  font-size: 0.57rem;
  letter-spacing: 0.24em;
}

.brand-flower {
  position: relative;
  width: 29px;
  height: 29px;
  flex: 0 0 auto;
  transform: rotate(45deg);
}

.brand-flower span {
  position: absolute;
  width: 12px;
  height: 12px;
  border-radius: 70% 18% 70% 18%;
  background: var(--orange);
  box-shadow: 0 0 18px rgba(241, 163, 38, 0.25);
}

.brand-flower span:nth-child(1) { top: 1px; left: 1px; }
.brand-flower span:nth-child(2) { top: 1px; right: 1px; transform: rotate(90deg); }
.brand-flower span:nth-child(3) { bottom: 1px; right: 1px; transform: rotate(180deg); }
.brand-flower span:nth-child(4) { bottom: 1px; left: 1px; transform: rotate(270deg); }

.global-nav {
  display: flex;
  align-items: center;
  gap: clamp(1.4rem, 4vw, 3.5rem);
}

.global-nav a {
  position: relative;
  color: var(--cream-soft);
  font-size: 0.76rem;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-decoration: none;
  text-transform: uppercase;
}

.global-nav a:not(.nav-contact)::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: -0.5rem;
  width: 100%;
  height: 1px;
  background: var(--orange);
  transform: scaleX(0);
  transform-origin: right;
  transition: transform 180ms ease;
}

.global-nav a:hover::after { transform: scaleX(1); transform-origin: left; }

.nav-contact {
  border: 1px solid var(--line-strong);
  padding: 0.65rem 1rem;
}

.nav-contact:hover { border-color: var(--orange); color: var(--gold); }
.menu-button { display: none; }

.hero {
  min-height: calc(100vh - 96px);
  display: grid;
  grid-template-columns: minmax(0, 1.35fr) minmax(320px, 0.65fr);
  align-items: center;
  gap: clamp(3rem, 8vw, 8rem);
  padding: clamp(5rem, 10vw, 9rem) 0;
}

.eyebrow,
.section-index {
  margin: 0 0 1.6rem;
  color: var(--muted);
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.19em;
}

.eyebrow span,
.section-index { color: var(--orange); }

.hero h1 {
  margin: 0;
  max-width: 780px;
  font-family: var(--font-serif);
  font-size: clamp(3.2rem, 8.2vw, 7.3rem);
  font-weight: 500;
  letter-spacing: -0.055em;
  line-height: 1.08;
}

.hero h1 em {
  color: var(--gold);
  font-style: normal;
}

.hero-lead {
  max-width: 610px;
  margin: 2rem 0 0;
  color: var(--cream-soft);
  font-size: clamp(1rem, 1.5vw, 1.15rem);
}

.hero-actions {
  display: flex;
  align-items: center;
  gap: 2rem;
  margin-top: 2.7rem;
}

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 1.6rem;
  min-height: 54px;
  padding: 0.8rem 1.25rem;
  text-decoration: none;
  font-size: 0.82rem;
  font-weight: 700;
  letter-spacing: 0.08em;
}

.button-primary {
  background: var(--orange);
  color: var(--night);
  transition: background 180ms ease, transform 180ms ease;
}

.button-primary:hover { background: var(--gold); transform: translateY(-2px); }

.text-link,
.card-link {
  display: inline-flex;
  align-items: center;
  gap: 0.8rem;
  color: var(--cream);
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-decoration: none;
}

.text-link span,
.card-link span { color: var(--orange); transition: transform 180ms ease; }
.text-link:hover span,
.card-link:hover span { transform: translateX(4px); }

.port-board {
  position: relative;
  min-height: 470px;
  padding: 1.4rem;
  border: 1px solid var(--line-strong);
  background: linear-gradient(145deg, rgba(255,255,255,0.04), rgba(255,255,255,0.012));
  overflow: hidden;
}

.port-board::before,
.port-board::after {
  content: "";
  position: absolute;
  pointer-events: none;
}

.port-board::before {
  width: 240px;
  height: 240px;
  right: -105px;
  top: 65px;
  border: 1px solid rgba(241, 163, 38, 0.35);
  border-radius: 50%;
  box-shadow: 0 0 0 35px rgba(241,163,38,0.025), 0 0 0 70px rgba(241,163,38,0.018);
}

.port-board::after {
  inset: 3.3rem 1.4rem auto;
  height: 1px;
  background: var(--line);
}

.port-board-head {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  color: var(--muted);
  font-size: 0.62rem;
  letter-spacing: 0.16em;
}

.status { color: var(--cream); }
.status i {
  display: inline-block;
  width: 6px;
  height: 6px;
  margin-right: 0.4rem;
  border-radius: 50%;
  background: var(--orange);
  box-shadow: 0 0 12px var(--orange);
}

.port-number {
  margin-top: 3.6rem;
  font-family: var(--font-serif);
  font-size: clamp(7rem, 14vw, 11rem);
  line-height: 0.9;
  color: var(--cream);
  letter-spacing: -0.08em;
}

.port-board > p {
  margin: 1.1rem 0 2rem;
  color: var(--muted);
  font-size: 0.65rem;
  letter-spacing: 0.18em;
  line-height: 1.6;
}

.port-stats {
  position: relative;
  z-index: 1;
  margin: 0;
  border-top: 1px solid var(--line);
}

.port-stats div {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  padding: 0.7rem 0;
  border-bottom: 1px solid var(--line);
  font-size: 0.68rem;
  letter-spacing: 0.08em;
}

.port-stats dt { color: var(--muted); }
.port-stats dd { margin: 0; color: var(--cream); }

.osmanthus {
  position: absolute;
  right: 2.5rem;
  bottom: 2rem;
  width: 100px;
  height: 100px;
  opacity: 0.92;
}

.osmanthus span {
  position: absolute;
  width: 14px;
  height: 14px;
  background: var(--orange);
  border-radius: 70% 16% 70% 16%;
  box-shadow: 0 0 18px rgba(241, 163, 38, 0.28);
  animation: drift 5s ease-in-out infinite alternate;
}

.osmanthus span:nth-child(1) { top: 12px; left: 50px; }
.osmanthus span:nth-child(2) { top: 42px; left: 72px; animation-delay: -1s; transform: rotate(70deg); }
.osmanthus span:nth-child(3) { top: 62px; left: 35px; animation-delay: -2s; transform: rotate(120deg); }
.osmanthus span:nth-child(4) { top: 35px; left: 13px; animation-delay: -3s; transform: rotate(200deg); }
.osmanthus span:nth-child(5) { top: 2px; left: 8px; animation-delay: -4s; transform: rotate(260deg); }

@keyframes drift {
  to { translate: 0 -7px; rotate: 12deg; }
}

.section {
  padding: clamp(5rem, 9vw, 8.5rem) 0;
  border-top: 1px solid var(--line);
}

.section-heading {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 2rem;
  margin-bottom: 3rem;
}

.section-heading h2,
.about h2,
.contact h2 {
  margin: 0;
  font-family: var(--font-serif);
  font-size: clamp(2.2rem, 5vw, 4.8rem);
  font-weight: 500;
  letter-spacing: -0.04em;
  line-height: 1.15;
}

.section-heading .section-index { margin-bottom: 0.6rem; }

.work-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1px;
  background: var(--line);
  border: 1px solid var(--line);
}

.work-card {
  min-width: 0;
  background: var(--night-soft);
}

.work-card-featured {
  grid-column: 1 / -1;
  display: grid;
  grid-template-columns: 1.08fr 0.92fr;
}

.work-visual {
  min-height: 230px;
  display: grid;
  place-content: center;
  overflow: hidden;
  background: var(--panel);
  color: var(--cream);
}

.work-card-featured .work-visual { min-height: 360px; }

.visual-lines { gap: 0.35rem; }
.visual-lines span {
  display: block;
  min-width: min(60vw, 360px);
  border-bottom: 1px solid var(--line-strong);
  padding: 0.65rem 1rem;
  font-family: var(--font-serif);
  font-size: 1.2rem;
  letter-spacing: 0.55em;
}

.visual-lines span:nth-child(2) { color: var(--orange); transform: translateX(2rem); }

.visual-tags {
  grid-template-columns: repeat(2, 68px);
  gap: 0.6rem;
}

.visual-tags span {
  display: grid;
  place-items: center;
  aspect-ratio: 1;
  border: 1px solid var(--line-strong);
  color: var(--orange);
  font-family: var(--font-serif);
  font-size: 1.4rem;
}

.visual-tags span:nth-child(2), .visual-tags span:nth-child(3) { background: var(--orange); color: var(--night); }

.visual-wildcard {
  grid-template-columns: auto auto auto;
  gap: 0.45rem;
  font-size: clamp(0.8rem, 2vw, 1.1rem);
  letter-spacing: 0.16em;
}

.visual-wildcard strong { color: var(--orange); font-size: 1.8em; }

.work-content { padding: clamp(1.5rem, 3vw, 2.5rem); }

.work-meta {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  color: var(--muted);
  font-size: 0.62rem;
  letter-spacing: 0.14em;
}

.work-meta span { color: var(--orange); }

.work-content h3 {
  margin: 1.2rem 0 0.7rem;
  font-family: var(--font-serif);
  font-size: clamp(1.5rem, 3vw, 2.3rem);
  font-weight: 500;
}

.work-content p {
  margin: 0 0 1.7rem;
  color: var(--muted);
  font-size: 0.9rem;
}

.route-list {
  margin-top: 4rem;
  border-top: 1px solid var(--line-strong);
}

.route-list a {
  display: grid;
  grid-template-columns: 50px minmax(180px, 0.55fr) 1fr auto;
  align-items: center;
  gap: 1.5rem;
  min-height: 84px;
  border-bottom: 1px solid var(--line-strong);
  color: var(--cream);
  text-decoration: none;
  transition: color 160ms ease, padding 160ms ease;
}

.route-list a:hover { color: var(--gold); padding-inline: 0.8rem; }
.route-list span, .route-list small { color: var(--muted); }
.route-list span { font-size: 0.68rem; }
.route-list strong { font-family: var(--font-serif); font-size: 1.25rem; font-weight: 500; }
.route-list small { font-size: 0.78rem; }
.route-list i { color: var(--orange); font-style: normal; }

.journal-preview { display: grid; grid-template-columns: 0.55fr 1fr; gap: clamp(2rem, 8vw, 8rem); }
.journal-preview .section-heading { display: block; margin: 0; }

.journal-entry {
  display: grid;
  grid-template-columns: 90px 1fr auto;
  gap: 2rem;
  align-items: start;
  padding: 2rem 0;
  border-top: 1px solid var(--line-strong);
  border-bottom: 1px solid var(--line-strong);
}

.journal-entry time {
  color: var(--cream-soft);
  font-size: 0.8rem;
  letter-spacing: 0.09em;
}

.journal-entry time span { display: block; color: var(--muted); font-size: 0.62rem; }
.entry-tag { margin: 0 0 0.55rem; color: var(--orange); font-size: 0.62rem; letter-spacing: 0.15em; }
.journal-entry h3 { margin: 0 0 0.55rem; font-family: var(--font-serif); font-size: 1.45rem; font-weight: 500; }
.journal-entry p:not(.entry-tag) { margin: 0; color: var(--muted); font-size: 0.86rem; }
.entry-arrow { color: var(--orange); font-size: 1.2rem; }

.about {
  display: grid;
  grid-template-columns: 0.55fr 1fr;
  align-items: center;
  gap: clamp(3rem, 9vw, 9rem);
}

.about-mark {
  display: grid;
  place-items: center;
  aspect-ratio: 1;
  border: 1px solid var(--line-strong);
  background: radial-gradient(circle, rgba(241,163,38,0.13), transparent 58%);
  color: var(--orange);
  font-family: var(--font-serif);
  font-size: clamp(5rem, 13vw, 10rem);
}

.about-copy > p:not(.section-index) { max-width: 650px; margin: 1.8rem 0 2.4rem; color: var(--cream-soft); }
.about-copy dl { margin: 0; border-top: 1px solid var(--line); }
.about-copy dl div { display: grid; grid-template-columns: 130px 1fr; gap: 1rem; padding: 0.8rem 0; border-bottom: 1px solid var(--line); font-size: 0.78rem; }
.about-copy dt { color: var(--muted); }
.about-copy dd { margin: 0; }

.contact {
  position: relative;
  padding-right: min(35vw, 360px);
  overflow: hidden;
}

.contact::after {
  content: "✣";
  position: absolute;
  right: 3vw;
  top: 50%;
  transform: translateY(-50%);
  color: var(--orange);
  font-size: clamp(8rem, 18vw, 15rem);
  line-height: 1;
  opacity: 0.75;
}

.contact > p:not(.section-index) { color: var(--muted); }

.social-list {
  display: flex;
  flex-wrap: wrap;
  gap: 0.8rem;
  margin-top: 2rem;
}

.social-list > span {
  display: grid;
  gap: 0.15rem;
  min-width: 150px;
  padding: 0.8rem 1rem;
  border: 1px solid var(--line);
  color: var(--cream-soft);
  font-size: 0.82rem;
}

.social-list small { color: var(--muted); font-size: 0.52rem; letter-spacing: 0.14em; }

.site-footer {
  min-height: 170px;
  display: grid;
  grid-template-columns: 1fr auto auto;
  align-items: center;
  gap: 3rem;
  border-top: 1px solid var(--line);
  color: var(--muted);
  font-size: 0.62rem;
  letter-spacing: 0.12em;
}

.site-footer > a:last-child { color: var(--muted); text-decoration: none; }
.footer-brand .brand-copy small { max-width: 190px; }

[data-reveal] { transition: opacity 600ms ease, transform 600ms ease; }
.js [data-reveal]:not(.is-visible) { opacity: 0; transform: translateY(18px); }

@media (max-width: 900px) {
  .site-header { min-height: 78px; }
  .menu-button {
    display: grid;
    gap: 7px;
    width: 44px;
    height: 44px;
    place-content: center;
    border: 1px solid var(--line);
    background: transparent;
    color: var(--cream);
  }
  .menu-button span:not(.sr-only) { display: block; width: 20px; height: 1px; background: currentColor; }
  .global-nav {
    position: absolute;
    z-index: 50;
    top: 78px;
    left: 24px;
    right: 24px;
    display: none;
    align-items: stretch;
    flex-direction: column;
    gap: 0;
    padding: 0.75rem;
    border: 1px solid var(--line-strong);
    background: rgba(17, 20, 15, 0.98);
    box-shadow: 0 24px 60px rgba(0,0,0,0.45);
  }
  .global-nav.is-open { display: flex; }
  .global-nav a { padding: 0.9rem; }
  .nav-contact { margin-top: 0.3rem; }
  .hero { grid-template-columns: 1fr; min-height: auto; }
  .port-board { min-height: 420px; }
  .work-card-featured { grid-template-columns: 1fr; }
  .journal-preview, .about { grid-template-columns: 1fr; }
  .about-mark { max-width: 480px; }
}

@media (max-width: 650px) {
  .site-header, main, .site-footer { width: min(calc(100% - 32px), var(--max-width)); }
  .site-header { gap: 1rem; }
  .brand-copy strong { font-size: 0.8rem; }
  .hero { padding: 4.6rem 0 5rem; gap: 3.5rem; }
  .hero h1 { font-size: clamp(2.85rem, 14.2vw, 4.4rem); }
  .hero-actions { align-items: flex-start; flex-direction: column; gap: 1.4rem; }
  .button { width: 100%; }
  .port-board { min-height: 390px; }
  .section { padding: 4.5rem 0; }
  .section-heading { align-items: start; }
  .desktop-link { display: none; }
  .work-grid { grid-template-columns: 1fr; }
  .work-card-featured { grid-column: auto; }
  .work-card-featured .work-visual { min-height: 260px; }
  .route-list a { grid-template-columns: 32px 1fr auto; gap: 0.8rem; padding: 0.8rem 0; }
  .route-list small { grid-column: 2 / 3; }
  .route-list i { grid-column: 3; grid-row: 1 / 3; }
  .journal-entry { grid-template-columns: 70px 1fr; gap: 1rem; }
  .entry-arrow { display: none; }
  .contact { padding-right: 0; padding-bottom: 15rem; }
  .contact::after { top: auto; bottom: 1rem; right: 50%; transform: translateX(50%); }
  .site-footer { grid-template-columns: 1fr; gap: 1.2rem; padding: 3rem 0; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation-duration: 0.01ms !important; animation-iteration-count: 1 !important; transition-duration: 0.01ms !important; }
}

/* ===== 下層ページ ===== */
.global-nav a[aria-current="page"] { color: var(--gold); }

.page-shell {
  min-height: calc(100vh - 96px);
  padding-bottom: clamp(5rem, 10vw, 9rem);
}

.page-hero {
  max-width: 980px;
  padding: clamp(5.5rem, 11vw, 10rem) 0 clamp(3.5rem, 7vw, 6rem);
}

.page-hero h1,
.work-detail-copy h1,
.article-header h1 {
  margin: 0;
  font-family: var(--font-serif);
  font-size: clamp(3.3rem, 9vw, 7.6rem);
  font-weight: 500;
  letter-spacing: -0.055em;
  line-height: 1.02;
}

.page-hero > p:last-child,
.work-detail-copy > p,
.article-header > p:not(.section-index) {
  max-width: 680px;
  margin: 2rem 0 0;
  color: var(--cream-soft);
  font-size: clamp(1rem, 1.5vw, 1.15rem);
}

.filter-bar {
  display: flex;
  flex-wrap: wrap;
  gap: 0.65rem;
  padding: 1rem 0;
  border-top: 1px solid var(--line-strong);
  border-bottom: 1px solid var(--line-strong);
}

.filter-bar button,
.embed-actions button,
.embed-actions a {
  border: 1px solid var(--line);
  background: transparent;
  color: var(--muted);
  padding: 0.62rem 0.95rem;
  cursor: pointer;
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-decoration: none;
}

.filter-bar button:hover,
.filter-bar button[aria-pressed="true"],
.embed-actions button:hover,
.embed-actions a:hover {
  border-color: var(--orange);
  color: var(--gold);
}

.filter-result {
  margin: 1.2rem 0 2rem;
  color: var(--muted);
  font-size: 0.7rem;
  letter-spacing: 0.08em;
}

.catalog-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1px;
  background: var(--line);
  border: 1px solid var(--line);
}

.catalog-card {
  min-width: 0;
  background: var(--night-soft);
}

.catalog-card[hidden] { display: none; }

.catalog-visual-link {
  display: block;
  color: inherit;
  text-decoration: none;
  overflow: hidden;
}

.catalog-visual-link .work-visual {
  min-height: 240px;
  transition: transform 300ms ease, background 300ms ease;
}

.catalog-visual-link:hover .work-visual {
  transform: scale(1.018);
  background: var(--panel-light);
}

.catalog-content { padding: 1.5rem; }
.catalog-content h2 { margin: 1.15rem 0 0.7rem; font-family: var(--font-serif); font-size: 1.55rem; font-weight: 500; line-height: 1.3; }
.catalog-content h2 a { text-decoration: none; }
.catalog-content h2 a:hover { color: var(--gold); }
.catalog-content > p { min-height: 5em; margin: 0 0 1.3rem; color: var(--muted); font-size: 0.83rem; }

.tag-list {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem;
  padding: 0;
  margin: 0;
  list-style: none;
}

.tag-list li {
  border: 1px solid var(--line);
  padding: 0.25rem 0.55rem;
  color: var(--muted);
  font-size: 0.58rem;
  letter-spacing: 0.06em;
}

.empty-state {
  padding: 4rem 1rem;
  border-bottom: 1px solid var(--line);
  color: var(--muted);
  text-align: center;
}

.breadcrumbs {
  display: flex;
  flex-wrap: wrap;
  gap: 0.65rem;
  padding: 1.4rem 0;
  color: var(--muted);
  font-size: 0.65rem;
  letter-spacing: 0.05em;
}

.breadcrumbs a { color: var(--cream-soft); text-decoration: none; }
.breadcrumbs a:hover { color: var(--gold); }

.work-detail-hero {
  display: grid;
  grid-template-columns: minmax(0, 0.9fr) minmax(380px, 1.1fr);
  align-items: stretch;
  gap: 1px;
  margin-top: 2.5rem;
  background: var(--line);
  border: 1px solid var(--line);
}

.work-detail-copy {
  display: flex;
  flex-direction: column;
  justify-content: center;
  min-height: 560px;
  padding: clamp(2rem, 5vw, 4.5rem);
  background: var(--night-soft);
}

.work-detail-copy h1 {
  margin-top: 2rem;
  font-size: clamp(3rem, 6.5vw, 6rem);
}

.work-detail-copy .tag-list { margin-top: 2rem; }
.visual-large { min-height: 560px; }

.detail-overview {
  display: grid;
  grid-template-columns: 0.7fr 1fr;
  gap: clamp(2rem, 8vw, 8rem);
  padding: clamp(5rem, 9vw, 8rem) 0;
  border-bottom: 1px solid var(--line);
}

.detail-overview h2,
.embed-heading h2,
.related-section h2,
.profile-copy h2,
.profile-route h2 {
  margin: 0;
  font-family: var(--font-serif);
  font-size: clamp(2rem, 4vw, 3.6rem);
  font-weight: 500;
  letter-spacing: -0.035em;
  line-height: 1.2;
}

.detail-body > p:first-child { margin-top: 0; color: var(--cream-soft); font-size: 1.04rem; }
.detail-body ul { margin: 2rem 0; padding: 0; list-style: none; border-top: 1px solid var(--line); }
.detail-body li { padding: 0.75rem 0 0.75rem 1.4rem; border-bottom: 1px solid var(--line); color: var(--cream-soft); font-size: 0.86rem; position: relative; }
.detail-body li::before { content: "✣"; position: absolute; left: 0; color: var(--orange); }
.detail-date { color: var(--muted); font-size: 0.67rem; letter-spacing: 0.08em; }

.embed-section { padding: clamp(5rem, 9vw, 8rem) 0; border-bottom: 1px solid var(--line); }
.embed-heading { display: flex; align-items: end; justify-content: space-between; gap: 2rem; margin-bottom: 2rem; }
.embed-heading .section-index { margin-bottom: 0.5rem; }
.embed-actions { display: flex; flex-wrap: wrap; gap: 0.55rem; }

.embed-shell {
  min-height: min(76vh, 820px);
  padding: 10px;
  border: 1px solid var(--line-strong);
  background: var(--cream);
}

.embed-shell iframe { display: block; width: 100%; height: min(74vh, 800px); border: 0; background: #fff; }
.embed-shell:fullscreen { padding: 0; border: 0; }
.embed-shell:fullscreen iframe { height: 100vh; }

.related-section { padding-top: clamp(5rem, 9vw, 8rem); }
.related-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1px; background: var(--line); border: 1px solid var(--line); }

.journal-entry { color: inherit; text-decoration: none; }
.journal-entry:hover h3 { color: var(--gold); }

.diary-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.6rem;
  padding: 1rem 0 2rem;
  color: var(--muted);
  font-size: 0.66rem;
}

.diary-tags span { border: 1px solid var(--line); padding: 0.35rem 0.65rem; }

.diary-list { border-top: 1px solid var(--line-strong); }
.diary-card {
  display: grid;
  grid-template-columns: 130px 1fr auto;
  gap: clamp(1.3rem, 4vw, 4rem);
  align-items: start;
  padding: 2rem 0;
  border-bottom: 1px solid var(--line-strong);
}

.diary-card time { color: var(--muted); font-size: 0.72rem; letter-spacing: 0.08em; }
.diary-card h2 { margin: 0.8rem 0 0.5rem; font-family: var(--font-serif); font-size: clamp(1.5rem, 3vw, 2.35rem); font-weight: 500; }
.diary-card h2 a { text-decoration: none; }
.diary-card h2 a:hover { color: var(--gold); }
.diary-card p { margin: 0; color: var(--muted); font-size: 0.86rem; }
.diary-read { align-self: center; color: var(--orange); font-size: 1.25rem; text-decoration: none; }

.article-shell { max-width: 940px; }
.article-header { padding: clamp(5rem, 10vw, 9rem) 0 4rem; border-bottom: 1px solid var(--line-strong); }
.article-header h1 { max-width: 860px; font-size: clamp(3rem, 8vw, 6.5rem); }
.article-header .tag-list { margin-top: 2rem; }

.prose {
  max-width: 760px;
  margin: 0 auto;
  padding: clamp(4rem, 8vw, 7rem) 0;
  color: var(--cream-soft);
  font-size: 1rem;
}

.prose > *:first-child { margin-top: 0; }
.prose h2 { margin: 3.2rem 0 1rem; color: var(--cream); font-family: var(--font-serif); font-size: 2rem; font-weight: 500; }
.prose h3 { margin-top: 2.5rem; color: var(--cream); }
.prose p { margin: 1.3rem 0; }
.prose strong { color: var(--gold); }
.prose a { color: var(--gold); text-underline-offset: 0.2em; }
.prose ul, .prose ol { padding-left: 1.5rem; }
.prose li { margin: 0.55rem 0; }
.prose blockquote { margin: 2rem 0; padding: 0.5rem 0 0.5rem 1.4rem; border-left: 2px solid var(--orange); color: var(--muted); }
.prose pre { overflow-x: auto; padding: 1.2rem; border: 1px solid var(--line); background: var(--night-soft); }
.prose code { font-family: ui-monospace, "Cascadia Code", monospace; font-size: 0.9em; }

.back-link { display: inline-flex; color: var(--cream-soft); font-size: 0.78rem; text-decoration: none; }
.back-link:hover { color: var(--gold); }

.about-page-content .page-hero { max-width: 940px; }
.profile-panel {
  display: grid;
  grid-template-columns: minmax(300px, 0.65fr) 1fr;
  gap: 1px;
  background: var(--line);
  border: 1px solid var(--line);
}
.profile-panel .about-mark { max-width: none; background-color: var(--panel); }
.profile-copy { padding: clamp(2rem, 6vw, 5.5rem); background: var(--night-soft); }
.profile-copy > p:not(.section-index) { color: var(--cream-soft); }
.profile-copy dl { margin: 2.5rem 0 0; border-top: 1px solid var(--line); }
.profile-copy dl div { display: grid; grid-template-columns: 130px 1fr; gap: 1rem; padding: 0.85rem 0; border-bottom: 1px solid var(--line); font-size: 0.8rem; }
.profile-copy dt { color: var(--muted); }
.profile-copy dd { margin: 0; }
.profile-route { max-width: 760px; padding: clamp(5rem, 9vw, 8rem) 0 0; }
.profile-route > p:not(.section-index) { margin: 1.2rem 0 2rem; color: var(--muted); }

.not-found {
  min-height: calc(100vh - 96px);
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  justify-content: center;
  padding: 5rem 0;
}
.not-found > strong { color: var(--orange); font-family: var(--font-serif); font-size: clamp(8rem, 26vw, 22rem); font-weight: 500; line-height: 0.78; opacity: 0.18; }
.not-found h1 { margin: 2rem 0 0; font-family: var(--font-serif); font-size: clamp(2rem, 5vw, 4rem); font-weight: 500; }
.not-found > p:not(.section-index) { color: var(--muted); }
.not-found .button { margin-top: 1.5rem; width: auto; }
.about-link { margin-top: 2rem; }

@media (max-width: 980px) {
  .catalog-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .work-detail-hero { grid-template-columns: 1fr; }
  .work-detail-copy { min-height: auto; }
  .visual-large { min-height: 430px; }
}

@media (max-width: 760px) {
  .page-shell { min-height: calc(100vh - 78px); }
  .page-hero { padding-top: 4.5rem; }
  .catalog-grid, .related-grid { grid-template-columns: 1fr; }
  .catalog-content > p { min-height: auto; }
  .detail-overview { grid-template-columns: 1fr; }
  .embed-heading { align-items: start; flex-direction: column; }
  .embed-shell { min-height: 70vh; padding: 5px; }
  .embed-shell iframe { height: 69vh; }
  .diary-card { grid-template-columns: 1fr auto; gap: 1rem; }
  .diary-card time { grid-column: 1 / -1; }
  .profile-panel { grid-template-columns: 1fr; }
  .profile-panel .about-mark { max-width: none; }
}

@media (max-width: 520px) {
  .filter-bar { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .filter-bar button { text-align: center; }
  .page-hero h1, .article-header h1 { font-size: clamp(2.8rem, 15vw, 4.4rem); }
  .work-detail-copy h1 { font-size: clamp(2.55rem, 13vw, 4rem); }
  .visual-large { min-height: 300px; }
  .embed-actions { width: 100%; }
  .embed-actions > * { flex: 1; text-align: center; }
  .profile-copy dl div { grid-template-columns: 1fr; gap: 0.2rem; }
}

/* ===== ホーム：一画面ポータル ===== */
.home-page {
  line-height: 1.55;
  background:
    radial-gradient(circle at 92% 4%, rgba(241, 163, 38, 0.08), transparent 24rem),
    linear-gradient(rgba(255,255,255,0.014) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255,255,255,0.014) 1px, transparent 1px),
    var(--night);
  background-size: auto, 44px 44px, 44px 44px, auto;
}

.home-page .site-header {
  min-height: 64px;
}

.home-page .brand-flower {
  width: 23px;
  height: 23px;
}

.home-page .brand-flower span {
  width: 10px;
  height: 10px;
}

.home-page .global-nav {
  gap: clamp(1.4rem, 3vw, 2.6rem);
}

.portal-overview {
  min-height: calc(100vh - 116px);
  display: grid;
  grid-template-rows: auto minmax(0, 1fr);
  gap: 14px;
  padding: 18px 0;
}

.portal-summary {
  display: grid;
  grid-template-columns: auto minmax(240px, 1fr) auto;
  align-items: end;
  gap: clamp(1.5rem, 4vw, 4rem);
  padding: 0 2px 14px;
  border-bottom: 1px solid var(--line-strong);
}

.portal-identity p {
  margin: 0 0 0.25rem;
  color: var(--orange);
  font-size: 0.62rem;
  font-weight: 700;
  letter-spacing: 0.08em;
}

.portal-identity p span {
  margin-left: 0.55rem;
  color: var(--muted);
  font-size: 0.52rem;
  letter-spacing: 0.14em;
}

.portal-identity h1 {
  margin: 0;
  font-family: var(--font-sans);
  font-size: clamp(1.75rem, 3.2vw, 2.55rem);
  font-weight: 700;
  letter-spacing: 0.08em;
  line-height: 1;
}

.portal-description {
  margin: 0 0 0.15rem;
  color: var(--cream-soft);
  font-size: 0.86rem;
}

.portal-counts {
  display: flex;
  gap: 0;
  margin: 0;
  border: 1px solid var(--line);
}

.portal-counts div {
  display: flex;
  align-items: baseline;
  gap: 0.75rem;
  min-width: 88px;
  padding: 0.5rem 0.7rem;
}

.portal-counts div + div { border-left: 1px solid var(--line); }
.portal-counts dt { color: var(--muted); font-size: 0.65rem; }
.portal-counts dd { margin: 0; color: var(--gold); font-size: 1.1rem; font-weight: 700; }

.portal-grid {
  min-height: 0;
  display: grid;
  grid-template-columns: minmax(0, 1.65fr) minmax(310px, 0.75fr);
  gap: 12px;
}

.portal-panel {
  min-width: 0;
  border: 1px solid var(--line-strong);
  background: rgba(24, 29, 22, 0.88);
}

.portal-panel-heading {
  min-height: 47px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 0.65rem 0.9rem;
  border-bottom: 1px solid var(--line);
}

.portal-panel-heading h2 {
  margin: 0;
  font-size: 0.88rem;
  letter-spacing: 0.04em;
}

.portal-panel-heading a {
  color: var(--muted);
  font-size: 0.68rem;
  text-decoration: none;
}

.portal-panel-heading a:hover { color: var(--gold); }

.portal-works {
  display: grid;
  grid-template-rows: auto 1fr auto;
}

.portal-work-list {
  display: grid;
  grid-template-rows: repeat(3, minmax(74px, 1fr));
}

.portal-work {
  min-width: 0;
  display: grid;
  grid-template-columns: 36px minmax(150px, 0.75fr) minmax(180px, 1.15fr) 22px;
  align-items: center;
  gap: 0.8rem;
  padding: 0.8rem 0.9rem;
  border-bottom: 1px solid var(--line);
  color: var(--cream);
  text-decoration: none;
  transition: background 150ms ease, border-color 150ms ease;
}

.portal-work:hover {
  background: rgba(241, 163, 38, 0.07);
  border-bottom-color: rgba(241, 163, 38, 0.35);
}

.portal-work-no {
  color: var(--orange);
  font-size: 0.62rem;
  font-variant-numeric: tabular-nums;
}

.portal-work-title {
  min-width: 0;
  display: grid;
  gap: 0.25rem;
}

.portal-work-title strong {
  overflow: hidden;
  font-size: clamp(0.86rem, 1.25vw, 1.02rem);
  text-overflow: ellipsis;
  white-space: nowrap;
}

.portal-work-title small {
  color: var(--muted);
  font-size: 0.59rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.portal-work-summary {
  min-width: 0;
  overflow: hidden;
  color: var(--muted);
  font-size: 0.72rem;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.portal-arrow { color: var(--orange); text-align: right; }

.portal-categories {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.portal-categories a {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
  padding: 0.7rem 0.9rem;
  color: var(--cream-soft);
  font-size: 0.68rem;
  text-decoration: none;
}

.portal-categories a + a { border-left: 1px solid var(--line); }
.portal-categories a:hover { background: var(--panel); color: var(--gold); }
.portal-categories strong { color: var(--orange); font-size: 0.85rem; }

.portal-sidebar {
  min-height: 0;
  display: grid;
  grid-template-rows: minmax(190px, 0.9fr) minmax(220px, 1.1fr);
  gap: 12px;
}

.portal-diary-entry {
  height: calc(100% - 47px);
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  justify-content: center;
  gap: 0.55rem;
  padding: 1rem;
  color: var(--cream);
  text-decoration: none;
}

.portal-diary-entry:hover { background: rgba(241, 163, 38, 0.06); }
.portal-diary-entry time { color: var(--orange); font-size: 0.64rem; }
.portal-diary-entry strong { font-size: 1rem; line-height: 1.45; }
.portal-diary-entry span { color: var(--muted); font-size: 0.72rem; }

.portal-info {
  display: grid;
  grid-template-rows: auto auto 1fr;
}

.portal-profile {
  margin: 0;
  padding: 0.55rem 0.9rem;
  border-bottom: 1px solid var(--line);
}

.portal-profile div {
  display: grid;
  grid-template-columns: 48px 1fr;
  gap: 0.7rem;
  padding: 0.3rem 0;
  font-size: 0.68rem;
}

.portal-profile dt { color: var(--muted); }
.portal-profile dd { min-width: 0; margin: 0; overflow-wrap: anywhere; }

.portal-socials {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  align-self: end;
}

.portal-socials > span,
.portal-socials > a {
  min-width: 0;
  display: grid;
  gap: 0.15rem;
  padding: 0.7rem 0.8rem;
  color: var(--cream-soft);
  font-size: 0.7rem;
  text-decoration: none;
}

.portal-socials > * + * { border-left: 1px solid var(--line); }
.portal-socials > a:hover { background: var(--panel); color: var(--gold); }
.portal-socials small { overflow: hidden; color: var(--muted); font-size: 0.47rem; letter-spacing: 0.04em; text-overflow: ellipsis; white-space: nowrap; }

.home-page .site-footer {
  min-height: 52px;
  gap: 1.5rem;
}

.home-page .footer-brand .brand-flower { display: none; }
.home-page .footer-brand .brand-copy { display: flex; align-items: center; gap: 0.8rem; }

@media (max-width: 1100px) and (min-width: 901px) {
  .portal-summary { grid-template-columns: 1fr auto; gap: 0.65rem 2rem; }
  .portal-description { grid-column: 1 / -1; grid-row: 2; }
  .portal-counts { grid-column: 2; grid-row: 1; }
  .portal-work { grid-template-columns: 30px minmax(140px, 1fr) 20px; }
  .portal-work-summary { display: none; }
}

@media (max-height: 760px) and (min-width: 901px) {
  .portal-overview { gap: 10px; padding: 12px 0; }
  .portal-summary { padding-bottom: 10px; }
  .portal-identity h1 { font-size: 1.7rem; }
  .portal-panel-heading { min-height: 42px; padding-block: 0.5rem; }
  .portal-work-list { grid-template-rows: repeat(3, minmax(62px, 1fr)); }
  .portal-work { padding-block: 0.55rem; }
  .portal-diary-entry { height: calc(100% - 42px); gap: 0.35rem; padding-block: 0.65rem; }
  .portal-sidebar { grid-template-rows: minmax(155px, 0.85fr) minmax(185px, 1.15fr); gap: 10px; }
  .portal-profile { padding-block: 0.35rem; }
  .portal-socials > span, .portal-socials > a { padding-block: 0.5rem; }
}

@media (max-width: 900px) {
  .home-page .site-header { min-height: 64px; }
  .home-page .global-nav { top: 64px; }
  .portal-overview { min-height: auto; padding: 24px 0 48px; }
  .portal-summary { grid-template-columns: 1fr auto; align-items: center; }
  .portal-description { grid-column: 1 / -1; }
  .portal-counts { grid-column: 2; grid-row: 1; }
  .portal-grid { grid-template-columns: 1fr; }
  .portal-sidebar { grid-template-columns: repeat(2, minmax(0, 1fr)); grid-template-rows: none; }
}

@media (max-width: 650px) {
  .portal-summary { grid-template-columns: 1fr; align-items: start; }
  .portal-counts { grid-column: 1; grid-row: auto; }
  .portal-description { grid-column: 1; }
  .portal-work { grid-template-columns: 30px 1fr 20px; }
  .portal-work-summary { display: none; }
  .portal-categories { grid-template-columns: 1fr; }
  .portal-categories a + a { border-top: 1px solid var(--line); border-left: 0; }
  .portal-sidebar { grid-template-columns: 1fr; }
  .portal-socials { grid-template-columns: 1fr; }
  .portal-socials > * + * { border-top: 1px solid var(--line); border-left: 0; }
  .home-page .site-footer { grid-template-columns: 1fr auto; }
  .home-page .site-footer > a:last-child { display: none; }
}

/* ===== コンパクト表示 ===== */
.portal-overview {
  grid-template-rows: auto auto;
  align-content: start;
}

.portal-grid { align-items: start; }

.portal-works {
  grid-template-rows: auto auto auto;
  align-content: start;
}

.portal-work-list {
  grid-template-rows: none;
}

.portal-work {
  min-height: 58px;
  padding-block: 0.52rem;
}

.portal-categories a {
  padding-block: 0.55rem;
}

.portal-sidebar {
  grid-template-rows: auto auto;
}

.portal-diary-entry {
  height: auto;
  min-height: 128px;
  justify-content: flex-start;
}

.page-shell {
  min-height: calc(100vh - 96px);
  padding-bottom: 3.5rem;
}

.page-hero {
  max-width: none;
  padding: 2.3rem 0 1.5rem;
  border-bottom: 1px solid var(--line-strong);
}

.page-hero .section-index {
  margin-bottom: 0.45rem;
}

.page-hero h1 {
  font-family: var(--font-sans);
  font-size: clamp(2rem, 4.5vw, 3.2rem);
  font-weight: 700;
  letter-spacing: 0.01em;
  line-height: 1.2;
}

.page-hero > p:last-child {
  max-width: none;
  margin-top: 0.65rem;
  color: var(--muted);
  font-size: 0.82rem;
}

.filter-bar {
  padding: 0.7rem 0;
}

.filter-bar button {
  padding: 0.45rem 0.8rem;
}

.filter-result {
  margin: 0.8rem 0;
}

.catalog-grid {
  grid-template-columns: 1fr;
}

.catalog-card {
  display: grid;
  grid-template-columns: 220px minmax(0, 1fr);
}

.catalog-card-compact {
  display: block;
}

.catalog-card-compact .catalog-content {
  min-height: 68px;
  display: grid;
  grid-template-columns: 112px minmax(170px, 0.7fr) minmax(220px, 1.4fr) minmax(180px, 0.8fr) 24px;
  align-items: center;
  gap: 0.9rem;
  padding: 0.65rem 0.9rem;
}

.catalog-card-compact .work-meta {
  display: grid;
  gap: 0.18rem;
  justify-content: start;
}

.catalog-card-compact .catalog-content h2 {
  margin: 0;
  font-family: var(--font-sans);
  font-size: 0.95rem;
  font-weight: 700;
  line-height: 1.35;
}

.catalog-card-compact .catalog-content > p {
  min-height: 0;
  margin: 0;
  overflow: hidden;
  color: var(--muted);
  font-size: 0.72rem;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.catalog-card-compact .tag-list {
  flex-wrap: nowrap;
  overflow: hidden;
}

.catalog-card-compact .tag-list li {
  white-space: nowrap;
}

.catalog-open {
  color: var(--orange);
  text-align: right;
  text-decoration: none;
}

.catalog-open:hover { color: var(--gold); }

.catalog-card:not(.catalog-card-compact) .catalog-content {
  align-self: center;
}

.catalog-card:not(.catalog-card-compact) .catalog-visual-link .work-visual {
  min-height: 180px;
}

.work-detail-hero-compact {
  display: block;
  border-top: 1px solid var(--line-strong);
  border-bottom: 1px solid var(--line-strong);
}

.work-detail-hero-compact .work-detail-copy {
  min-height: auto;
  max-width: 920px;
  padding: 2rem 0;
}

.work-detail-hero-compact .work-detail-copy h1 {
  margin-top: 0.75rem;
  font-family: var(--font-sans);
  font-size: clamp(2rem, 5vw, 3.5rem);
  font-weight: 700;
  letter-spacing: 0;
}

.work-detail-hero-compact .work-detail-copy > p {
  margin-top: 0.8rem;
  font-size: 0.88rem;
}

.work-detail-hero-compact .work-detail-copy .tag-list {
  margin-top: 1rem;
}

.detail-overview {
  padding: 2.5rem 0;
}

.related-section {
  padding-top: 3rem;
}

.related-section .section-heading {
  margin-bottom: 1.2rem;
}

.related-grid .catalog-card-compact .catalog-content {
  grid-template-columns: 1fr 22px;
  align-content: start;
}

.related-grid .catalog-card-compact .work-meta,
.related-grid .catalog-card-compact .catalog-content h2,
.related-grid .catalog-card-compact .catalog-content > p,
.related-grid .catalog-card-compact .tag-list {
  grid-column: 1;
}

.related-grid .catalog-card-compact .catalog-open {
  grid-column: 2;
  grid-row: 1 / 5;
  align-self: center;
}

.diary-tags {
  margin: 1rem 0;
}

.diary-card {
  grid-template-columns: 110px minmax(0, 1fr) auto;
  gap: 1.2rem;
  padding: 1rem 0;
}

.diary-card h2 {
  margin: 0.35rem 0 0.2rem;
  font-family: var(--font-sans);
  font-size: 1.05rem;
  font-weight: 700;
}

.diary-card p {
  overflow: hidden;
  font-size: 0.72rem;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.article-header {
  padding: 2.8rem 0 2rem;
}

.article-header h1 {
  font-family: var(--font-sans);
  font-size: clamp(2rem, 5vw, 3.6rem);
  font-weight: 700;
  letter-spacing: 0;
}

.profile-panel {
  grid-template-columns: minmax(180px, 0.35fr) 1fr;
}

.profile-panel .about-mark {
  font-size: clamp(4rem, 9vw, 7rem);
}

.profile-copy {
  padding: clamp(1.5rem, 4vw, 3rem);
}

.profile-copy dl {
  margin-top: 1.5rem;
}

.profile-route {
  padding-top: 3rem;
}

@media (max-width: 900px) {
  .catalog-card-compact .catalog-content {
    grid-template-columns: 90px minmax(150px, 0.75fr) minmax(180px, 1.25fr) 24px;
  }

  .catalog-card-compact .tag-list { display: none; }
}

@media (max-width: 650px) {
  .page-shell { min-height: calc(100vh - 64px); }
  .page-hero { padding-top: 1.7rem; }
  .page-hero h1 { font-size: 2rem; }
  .catalog-card { grid-template-columns: 1fr; }
  .catalog-card-compact .catalog-content {
    min-height: 0;
    grid-template-columns: 1fr 22px;
    gap: 0.45rem 0.8rem;
    padding: 0.85rem;
  }
  .catalog-card-compact .work-meta,
  .catalog-card-compact .catalog-content h2,
  .catalog-card-compact .catalog-content > p {
    grid-column: 1;
  }
  .catalog-card-compact .catalog-open {
    grid-column: 2;
    grid-row: 1 / 4;
    align-self: center;
  }
  .catalog-card-compact .catalog-content > p { white-space: normal; }
  .diary-card { grid-template-columns: 1fr auto; gap: 0.6rem; }
  .diary-card time { grid-column: 1 / -1; }
  .diary-card p { white-space: normal; }
  .profile-panel { grid-template-columns: 1fr; }
  .profile-panel .about-mark { max-height: 180px; }
}

/* ===== ツール詳細：本体を最優先 ===== */
.tool-detail-page .site-header {
  min-height: 64px;
}

.tool-detail-page main,
.tool-detail-page .site-footer {
  width: min(calc(100% - 32px), 1400px);
}

.tool-detail-page .breadcrumbs {
  min-height: 36px;
  align-items: center;
  padding: 0.45rem 0;
}

.tool-detail-page .work-detail-hero-compact {
  margin-top: 0;
  border-right: 1px solid var(--line-strong);
  border-left: 1px solid var(--line-strong);
}

.tool-detail-page .work-detail-hero-compact .work-detail-copy {
  min-height: 68px;
  max-width: none;
  display: grid;
  grid-template-columns: minmax(190px, 0.6fr) minmax(280px, 1.4fr) auto;
  align-items: center;
  gap: 1rem;
  padding: 0.65rem 0.9rem;
}

.tool-detail-page .work-detail-hero-compact .work-meta {
  display: none;
}

.tool-detail-page .work-detail-hero-compact .work-detail-copy h1 {
  margin: 0;
  font-size: clamp(1.15rem, 2.4vw, 1.55rem);
  line-height: 1.3;
}

.tool-detail-page .work-detail-hero-compact .work-detail-copy > p {
  margin: 0;
  color: var(--muted);
  font-size: 0.7rem;
  line-height: 1.55;
}

.tool-detail-page .work-detail-hero-compact .work-detail-copy .tag-list {
  flex-wrap: nowrap;
  justify-content: flex-end;
  margin: 0;
}

.tool-detail-page .work-detail-hero-compact .tag-list li {
  white-space: nowrap;
}

.embed-section-direct {
  padding: 8px 0 1.2rem;
}

.embed-section-direct .embed-shell {
  height: calc(100vh - 196px);
  min-height: 440px;
  max-height: 820px;
  padding: 4px;
  background: #111722;
}

.embed-section-direct .embed-shell iframe {
  height: 100%;
}

.tool-detail-page .detail-overview {
  padding-top: 2.2rem;
}

@media (max-width: 900px) {
  .tool-detail-page .global-nav { top: 64px; }
  .tool-detail-page .work-detail-hero-compact .work-detail-copy {
    grid-template-columns: minmax(170px, 0.75fr) minmax(220px, 1.25fr);
  }
  .tool-detail-page .work-detail-hero-compact .tag-list { display: none; }
}

@media (max-width: 650px) {
  .tool-detail-page main,
  .tool-detail-page .site-footer {
    width: min(calc(100% - 20px), 1400px);
  }
  .tool-detail-page .breadcrumbs {
    overflow: hidden;
    flex-wrap: nowrap;
    white-space: nowrap;
  }
  .tool-detail-page .breadcrumbs span:last-child {
    overflow: hidden;
    text-overflow: ellipsis;
  }
  .tool-detail-page .work-detail-hero-compact .work-detail-copy {
    min-height: 0;
    grid-template-columns: 1fr;
    gap: 0.35rem;
    padding: 0.65rem;
  }
  .tool-detail-page .work-detail-hero-compact .work-detail-copy > p {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
  }
  .embed-section-direct .embed-shell {
    height: calc(100vh - 218px);
    min-height: 420px;
  }
}

/* ===== カジュアルな見た目 ===== */
body {
  background:
    radial-gradient(circle at 88% 0%, rgba(244, 163, 64, 0.09), transparent 25rem),
    radial-gradient(circle at 0% 75%, rgba(112, 130, 105, 0.08), transparent 28rem),
    var(--night);
}

.brand-copy strong {
  letter-spacing: 0.08em;
}

.brand-copy small {
  letter-spacing: 0.08em;
}

.global-nav a {
  letter-spacing: 0.04em;
  text-transform: none;
}

.section-index,
.eyebrow {
  margin-bottom: 0.55rem;
  color: var(--muted);
  letter-spacing: 0.04em;
}

.button,
.filter-bar button,
.embed-actions button,
.embed-actions a {
  border-radius: 8px;
  letter-spacing: 0.02em;
}

.tag-list li {
  border-radius: 999px;
  letter-spacing: 0.02em;
}

.portal-panel,
.portal-counts,
.catalog-grid,
.related-grid,
.profile-panel,
.work-detail-hero-compact,
.embed-shell {
  border-radius: 10px;
  overflow: hidden;
}

.portal-panel {
  background: rgba(27, 33, 25, 0.92);
}

.portal-identity p {
  color: var(--muted);
  letter-spacing: 0.02em;
}

.portal-identity h1 {
  letter-spacing: 0.035em;
}

.portal-counts div:first-child {
  min-width: 150px;
}

.portal-counts dt {
  white-space: nowrap;
}

.portal-panel-heading h2,
.portal-work-title strong,
.catalog-card-compact .catalog-content h2,
.diary-card h2 {
  letter-spacing: 0;
}

.portal-work,
.portal-categories a,
.portal-diary-entry,
.portal-socials > span,
.portal-socials > a {
  transition: background 120ms ease, color 120ms ease;
}

.page-hero h1,
.detail-overview h2,
.related-section h2,
.profile-copy h2,
.profile-route h2,
.article-header h1 {
  font-family: var(--font-sans);
  letter-spacing: 0;
}

.detail-overview h2,
.related-section h2,
.profile-copy h2,
.profile-route h2 {
  font-size: clamp(1.35rem, 2.5vw, 2rem);
  font-weight: 700;
}

.filter-bar button {
  background: rgba(255,255,255,0.025);
}

.catalog-card {
  background: rgba(27, 33, 25, 0.92);
}

.catalog-card-compact .work-meta span:first-child {
  color: var(--orange);
}

.about-mark,
.profile-panel .about-mark {
  border-radius: 10px 0 0 10px;
}

.home-page {
  background:
    radial-gradient(circle at 90% 0%, rgba(244, 163, 64, 0.09), transparent 25rem),
    var(--night);
}

@media (max-width: 650px) {
  .portal-counts div:first-child { min-width: 150px; }
  .about-mark,
  .profile-panel .about-mark { border-radius: 10px 10px 0 0; }
}

/* ===== 明色テーマ ===== */
:root {
  --night: #f7f2e7;
  --night-soft: #fffdf7;
  --panel: #eee6d6;
  --panel-light: #e7ddca;
  --cream: #292b25;
  --cream-soft: #4d5047;
  --muted: #74766c;
  --orange: #e99624;
  --gold: #b96c0d;
  --leaf: #71806b;
  --line: rgba(41, 43, 37, 0.12);
  --line-strong: rgba(41, 43, 37, 0.22);
}

html { color-scheme: light; }

body,
.home-page {
  background:
    radial-gradient(circle at 88% 0%, rgba(233, 150, 36, 0.13), transparent 26rem),
    radial-gradient(circle at 0% 82%, rgba(113, 128, 107, 0.11), transparent 30rem),
    var(--night);
}

.portal-panel,
.catalog-card {
  background: rgba(255, 253, 247, 0.94);
}

.portal-work:hover,
.portal-diary-entry:hover {
  background: rgba(233, 150, 36, 0.08);
}

.button-primary,
.tool-detail-page .button-primary {
  color: #2c2417;
}

.global-nav,
.work-card,
.work-detail-copy,
.profile-copy {
  background-color: var(--night-soft);
}

.global-nav { background-color: transparent; }

.about-mark {
  background-color: var(--panel);
}

.not-found > strong { opacity: 0.11; }

@media (max-width: 900px) {
  .global-nav {
    background: rgba(247, 242, 231, 0.98);
    box-shadow: 0 20px 45px rgba(65, 55, 36, 0.14);
  }
}

/* ===== 記事・日記の検索 ===== */
.portal-panel-links {
  display: flex;
  gap: 0.8rem;
}

.portal-reading-list {
  display: grid;
}

.portal-reading-entry {
  min-width: 0;
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 0.25rem 0.65rem;
  padding: 0.75rem 0.9rem;
  color: var(--cream);
  text-decoration: none;
  transition: background 120ms ease;
}

.portal-reading-entry + .portal-reading-entry {
  border-top: 1px solid var(--line);
}

.portal-reading-entry:hover {
  background: rgba(233, 150, 36, 0.08);
}

.portal-reading-kind,
.portal-reading-entry time {
  font-size: 0.6rem;
}

.portal-reading-kind {
  color: var(--gold);
  font-weight: 700;
}

.portal-reading-entry time {
  color: var(--muted);
}

.portal-reading-entry strong,
.portal-reading-entry > span:last-child {
  grid-column: 1 / -1;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.portal-reading-entry strong {
  font-size: 0.86rem;
}

.portal-reading-entry > span:last-child {
  color: var(--muted);
  font-size: 0.66rem;
}

.content-browser {
  padding-top: 1rem;
}

.content-controls {
  display: grid;
  grid-template-columns: minmax(250px, 0.8fr) minmax(0, 1.2fr);
  gap: 1px;
  border: 1px solid var(--line-strong);
  background: var(--line);
  overflow: hidden;
  border-radius: 10px;
}

.content-search,
.content-tag-filter {
  min-width: 0;
  padding: 0.9rem;
  background: rgba(255, 253, 247, 0.94);
}

.content-search label,
.content-tag-filter > span {
  display: block;
  margin-bottom: 0.55rem;
  color: var(--muted);
  font-size: 0.65rem;
  font-weight: 700;
}

.content-search-field {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: stretch;
}

.content-search input {
  min-width: 0;
  width: 100%;
  min-height: 42px;
  border: 1px solid var(--line-strong);
  border-radius: 8px 0 0 8px;
  background: var(--night-soft);
  color: var(--cream);
  padding: 0.65rem 0.8rem;
  font: inherit;
  font-size: 0.82rem;
}

.content-search button,
.content-tag-buttons button,
.empty-state button {
  border: 1px solid var(--line-strong);
  background: var(--night-soft);
  color: var(--muted);
  cursor: pointer;
  font: inherit;
  font-size: 0.68rem;
  font-weight: 700;
}

.content-search button {
  min-width: 68px;
  margin-left: -1px;
  border-radius: 0 8px 8px 0;
}

.content-search button:disabled {
  cursor: default;
  opacity: 0.48;
}

.content-tag-buttons {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem;
}

.content-tag-buttons button {
  border-radius: 999px;
  padding: 0.42rem 0.72rem;
}

.content-search button:not(:disabled):hover,
.content-tag-buttons button:hover,
.content-tag-buttons button[aria-pressed="true"],
.empty-state button:hover {
  border-color: var(--orange);
  color: var(--gold);
}

.content-search input:focus-visible,
.content-search button:focus-visible,
.content-tag-buttons button:focus-visible,
.empty-state button:focus-visible {
  outline: 3px solid rgba(233, 150, 36, 0.28);
  outline-offset: 2px;
}

.content-result {
  margin-bottom: 0.8rem;
}

.content-card[hidden] {
  display: none;
}

.empty-state button {
  margin-top: 0.8rem;
  border-radius: 8px;
  padding: 0.55rem 0.9rem;
}

@media (max-width: 900px) {
  .content-controls {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 650px) {
  .portal-counts {
    width: 100%;
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .portal-counts div,
  .portal-counts div:first-child {
    min-width: 0;
    display: grid;
    gap: 0.2rem;
  }

  .portal-counts dt {
    white-space: normal;
    line-height: 1.3;
  }

  .content-search-field {
    grid-template-columns: 1fr;
    gap: 0.45rem;
  }

  .content-search input,
  .content-search button {
    margin: 0;
    border-radius: 8px;
  }
}
