/* naonotes.com の見た目（手で書いた 1 枚）。
   元は WordPress のテーマ「naonotes-modern」（Twenty Twelve の子テーマ）と、その上に重ねていた
   「naonotes-automation-design」「naonotes-article-header-design」の CSS（2026-12-04 に公開中の CSS を写して読んだ）。
   色・枠・カード・サイドバーの形はそのまま。文字組みは「本文の文字組み」の 1 つにそろえた（README）。 */

:root {
  --nn-bg: #eef2ef;
  --nn-surface: #fffdfa;
  --nn-card: #fff;
  --nn-ink: #172126;
  --nn-muted: #5d6a70;
  --nn-line: #d8e0dc;
  --nn-soft: #e8f1ed;
  --nn-note: #f3efe4;
  --nn-accent: #126f66;
  --nn-accent-2: #b45d32;
  --nn-focus: rgba(18, 111, 102, .28);
  --nn-code-bg: #101719;
  --nn-code-ink: #eef7f5;

  /* 本文の文字組み（全ページで 1 つ） */
  --nn-font: -apple-system, BlinkMacSystemFont, "Hiragino Sans", "Hiragino Kaku Gothic ProN", "Noto Sans JP",
    "Yu Gothic", YuGothic, Meiryo, sans-serif;
  --nn-mono: ui-monospace, SFMono-Regular, Menlo, Consolas, "Liberation Mono", "Noto Sans Mono CJK JP", monospace;
  --nn-size: 16px;
  --nn-leading: 1.85;
  --nn-tracking: .03em;
  --nn-heading-leading: 1.4;
  --nn-heading-tracking: .02em;
  --nn-space: 1.25em;         /* 段落・表・図・引用・コードの上下の間 */
  --nn-heading-space: 2em;    /* 見出しの上の間 */
}

/* ---- 土台 ---- */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; text-size-adjust: 100%; background: var(--nn-bg); }
body {
  margin: 0;
  color: var(--nn-ink);
  background: var(--nn-bg);
  font-family: var(--nn-font);
  font-size: var(--nn-size);
  line-height: var(--nn-leading);
  letter-spacing: var(--nn-tracking);
  font-kerning: normal;
  line-break: strict;
  word-break: normal;
  overflow-wrap: anywhere;
  text-autospace: normal;
  text-spacing-trim: trim-start;
}
a { color: var(--nn-accent); }
a:hover, a:focus { color: var(--nn-accent-2); }
a:focus-visible, button:focus-visible, input:focus-visible, select:focus-visible {
  outline: 3px solid var(--nn-focus);
  outline-offset: 2px;
}
img, video, iframe, embed, object { max-width: 100%; }
img { height: auto; }
.screen-reader-text {
  position: absolute !important;
  width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}
.skip-link:focus {
  position: fixed !important; top: 8px; left: 8px; z-index: 1000;
  width: auto; height: auto; margin: 0; padding: 8px 14px; clip: auto;
  background: #fff; color: var(--nn-ink); border-radius: 6px;
}

/* ---- 見出し・題名の文字組み（詰め palt と行の釣り合いは見出しだけ） ---- */
h1, h2, h3, h4, h5, h6,
.site-title, .entry-title, .archive-title, .widget-title, .comments-title {
  line-height: var(--nn-heading-leading);
  letter-spacing: var(--nn-heading-tracking);
  font-feature-settings: "palt";
  text-wrap: pretty;
  word-break: auto-phrase; /* 題名は日本語の文節で折る（balance だと「ブ／ログ」のように言葉の途中で折れた。2026-12-04）。対応しないブラウザは今までどおり */
}

/* ---- 枠 ---- */
#page {
  max-width: 1180px;
  margin: 22px auto;
  border: 1px solid var(--nn-line);
  background: var(--nn-surface);
  box-shadow: 0 18px 42px rgba(23, 33, 38, .08);
}

/* ---- ヘッダー（トップ・記事・固定ページは写真の帯。カテゴリーなどの一覧は白い帯） ---- */
.site-header {
  padding: 30px 36px 0;
  border-bottom: 1px solid var(--nn-line);
  background: linear-gradient(180deg, #fff 0%, #fbfcfb 100%);
  overflow: hidden;
}
.site-branding { max-width: 760px; }
.site-title {
  margin: 0 0 8px;
  font-size: 31px;
  font-weight: 800;
  line-height: 1.22;
}
.site-title a { color: var(--nn-ink); text-decoration: none; }
.site-description { margin: 0; color: var(--nn-muted); font-size: 14px; line-height: 1.7; }

.home .site-header, .blog .site-header, .single .site-header, .page .site-header, .error404 .site-header {
  min-height: 280px;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  color: #fff;
  background-color: #172126;
  background-image:
    linear-gradient(90deg, rgba(23, 33, 38, .9), rgba(23, 33, 38, .68) 42%, rgba(23, 33, 38, .08) 76%),
    url(/wordpress/wp-content/uploads/2026/05/naonotes-low-maintenance-hero-gpt-image2.png);
  background-size: cover;
  background-position: center;
}
.home .site-title, .blog .site-title, .single .site-title, .page .site-title, .error404 .site-title {
  font-size: 46px;
  line-height: 1.12;
}
.home .site-title a, .blog .site-title a, .single .site-title a, .page .site-title a, .error404 .site-title a,
.home .main-navigation a, .blog .main-navigation a, .single .main-navigation a, .page .main-navigation a,
.error404 .main-navigation a { color: #fff; }
.home .site-description, .blog .site-description, .single .site-description, .page .site-description,
.error404 .site-description { color: rgba(255, 255, 255, .9); font-size: 17px; }

/* ---- メニュー ---- */
.main-navigation { margin-top: 18px; padding: 0 0 20px; }
.main-navigation ul { list-style: none; margin: 0; padding: 0; }
.main-navigation a {
  display: block;
  color: var(--nn-ink);
  font-weight: 800;
  text-decoration: none;
  white-space: nowrap;
}
.main-navigation a:hover, .main-navigation a:focus { color: var(--nn-accent-2); }
.menu-toggle {
  display: none;
  min-height: 42px;
  padding: 0 15px;
  border: 1px solid var(--nn-line);
  border-radius: 6px;
  background: #fff;
  color: var(--nn-ink);
  font: inherit;
  font-weight: 700;
  cursor: pointer;
}
@media (min-width: 600px) {
  .nav-menu { display: flex; flex-wrap: wrap; gap: 4px; }
  .nav-menu > li { position: relative; }
  .nav-menu > li > a { padding: 10px 12px; border-radius: 6px; }
  .sub-menu {
    position: absolute; top: 100%; left: 0; z-index: 50;
    min-width: 190px;
    border: 1px solid var(--nn-line);
    background: #fff;
    box-shadow: 0 12px 28px rgba(23, 33, 38, .12);
    visibility: hidden; opacity: 0;
  }
  .nav-menu > li:hover > .sub-menu, .nav-menu > li:focus-within > .sub-menu { visibility: visible; opacity: 1; }
  .sub-menu a, .home .sub-menu a, .blog .sub-menu a, .single .sub-menu a, .page .sub-menu a, .error404 .sub-menu a {
    padding: 9px 14px; color: var(--nn-ink); font-weight: 700; border-bottom: 1px solid var(--nn-soft);
  }
}
@media (max-width: 599px) {
  .menu-toggle { display: inline-block; }
  .js .nav-menu { display: none; }
  .js .toggled-on .nav-menu { display: block; }
  .nav-menu { margin-top: 10px; border-radius: 8px; background: rgba(255, 255, 255, .96); }
  .nav-menu a, .home .nav-menu a, .blog .nav-menu a, .single .nav-menu a, .page .nav-menu a, .error404 .nav-menu a {
    padding: 11px 14px; color: var(--nn-ink); white-space: normal; border-bottom: 1px solid var(--nn-soft);
  }
  .main-navigation .nav-menu .sub-menu a { padding-left: 28px; font-weight: 700; }
}

/* ---- 本体とサイドバー ---- */
#main.wrapper {
  display: flex;
  flex-wrap: wrap;
  gap: 34px;
  padding: 34px 36px 46px;
}
#primary.site-content { flex: 1 1 620px; min-width: 0; }
#secondary.widget-area { flex: 0 1 306px; min-width: 0; }

/* ---- 一覧のカード ---- */
.card {
  margin-bottom: 24px;
  padding: 0 0 22px;
  overflow: hidden;
  border: 1px solid var(--nn-line);
  border-radius: 8px;
  background: var(--nn-card);
}
.entry-header .wp-post-image { display: block; width: 100%; max-width: 100%; height: auto; margin: 0; }
.card .entry-title {
  margin: 0;
  padding: 21px 24px 0;
  font-size: 24px;
  font-weight: 800;
  line-height: 1.38;
}
.entry-title a { color: var(--nn-ink); text-decoration: none; }
.entry-title a:hover, .entry-title a:focus { color: var(--nn-accent); }
.entry-summary { padding: 10px 24px 0; }
.entry-summary p { margin: 0 0 .9em; text-wrap: pretty; }
.read-more-row { margin: 0; }
.read-more {
  display: inline-flex;
  align-items: center;
  min-height: 40px;
  padding: 0 14px;
  border: 1px solid var(--nn-accent);
  border-radius: 6px;
  color: var(--nn-accent);
  font-weight: 800;
  text-decoration: none;
}
.read-more:hover, .read-more:focus { color: #fff; background: var(--nn-accent); }
.entry-meta { color: var(--nn-muted); font-size: 13px; line-height: 1.65; }
.card .entry-meta { padding: 12px 24px 0; }
.entry-meta a { color: var(--nn-muted); }
.archive-header { margin: 0 0 24px; padding: 0 0 14px; border-bottom: 1px solid var(--nn-line); }
.archive-title { margin: 0; font-size: 20px; font-weight: 800; }
.archive-meta { margin-top: 6px; color: var(--nn-muted); font-size: 14px; }
.no-posts { color: var(--nn-muted); }

/* ---- ページ送り ---- */
.paging-navigation, .nav-single {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 10px 18px;
  margin: 8px 0 24px;
  font-size: 15px;
}
.paging-navigation .nav-next { margin-left: auto; }
.page-count { flex-basis: 100%; margin: 0; color: var(--nn-muted); font-size: 13px; text-align: center; }
.nav-single { padding: 16px 0; border-top: 1px solid var(--nn-line); border-bottom: 1px solid var(--nn-line); }
.nav-single .nav-previous, .nav-single .nav-next { flex: 1 1 240px; }
.nav-single .nav-next { text-align: right; }
.nav-single a, .paging-navigation a { text-decoration: none; font-weight: 700; }

/* ---- 記事・固定ページ ---- */
.entry { margin-bottom: 28px; }
.entry .entry-header { margin-bottom: 18px; }
.entry .post-thumbnail img { display: block; width: 100%; border-radius: 8px; }
.entry .entry-title { margin: 16px 0 0; font-size: 30px; font-weight: 800; }
.entry > .entry-meta { margin-top: 22px; padding-top: 12px; border-top: 1px solid var(--nn-soft); }

/* ==== 本文の文字組み（古い記事も新しい記事も同じ。本文の中の書式は build.py の「本文の整え」で外してある） ==== */
.entry-content, .comment-content {
  font-family: var(--nn-font);
  font-size: var(--nn-size);
  line-height: var(--nn-leading);
  letter-spacing: var(--nn-tracking);
  font-kerning: normal;
  line-break: strict;
  word-break: normal;
  overflow-wrap: anywhere;
  text-autospace: normal;
  text-spacing-trim: trim-start;
}
@media (min-width: 960px) {
  .entry-content, .comment-content { font-size: 17px; }
}
/* 行末に並んだ全角の空白（古い記事のコマンドの画面の写し）は行の外へぶら下がり、スマホで横に揺れる。字は変えずに外へ出た分だけ切る */
.entry-content, .comment-content { overflow-x: clip; }
.entry-content p, .comment-content p { margin-block: 0 var(--nn-space); text-wrap: pretty; }
.entry-content > :first-child { margin-top: 0; }
.entry-content h1, .entry-content h2, .entry-content h3, .entry-content h4, .entry-content h5, .entry-content h6 {
  margin-block: var(--nn-heading-space) .75em;
  color: var(--nn-ink);
  font-weight: 800;
}
.entry-content h1 { font-size: 1.6em; }
.entry-content h2 { font-size: 1.45em; padding-bottom: .3em; border-bottom: 2px solid var(--nn-soft); }
.entry-content h3 { font-size: 1.25em; }
.entry-content h4 { font-size: 1.1em; }
.entry-content h5, .entry-content h6 { font-size: 1em; }
.entry-content ul, .entry-content ol, .comment-content ul, .comment-content ol {
  margin-block: 0 var(--nn-space);
  padding-left: 1.6em;
}
.entry-content li, .comment-content li { margin-block: .25em; }
.entry-content li > ul, .entry-content li > ol { margin-block: .25em; }
.entry-content blockquote, .comment-content blockquote, .entry-content .quotation {
  margin: 0 0 var(--nn-space);
  padding: .9em 1.1em;
  border-left: 4px solid var(--nn-accent);
  background: var(--nn-soft);
}
.entry-content blockquote > :last-child { margin-bottom: 0; }
.entry-content figure { margin: 0 0 var(--nn-space); }
.entry-content figcaption, .wp-caption-text {
  margin-top: .5em;
  color: var(--nn-muted);
  font-size: .85em;
  text-align: center;
}
.entry-content table {
  margin: 0 0 var(--nn-space);
  border-collapse: collapse;
  font-size: .95em;
}
.entry-content th, .entry-content td { padding: .4em .7em; border: 1px solid var(--nn-line); vertical-align: top; }
.entry-content th { background: var(--nn-soft); font-weight: 700; }
.entry-content table[border="0"] td, .entry-content table[border="0"] th { border: 0; }
.entry-content hr { margin: var(--nn-heading-space) 0; border: 0; border-top: 1px solid var(--nn-line); }
.entry-content img { border-radius: 6px; }
.entry-content iframe { display: block; max-width: 100%; margin-inline: auto; }
.entry-content iframe[src*="youtube.com"], .entry-content iframe[src*="youtube-nocookie.com"] {
  width: 100%; height: auto; aspect-ratio: 16 / 9;
}
.entry-content :where(div, table, figure, pre, embed, object, video) { max-width: 100%; }
.entry-content small, .entry-content .affiliate-disclosure { font-size: .85em; color: var(--nn-muted); }

/* コード（等幅は 1 つ。字間は付けない） */
.entry-content pre, .comment-content pre, .entry-content .command {
  margin: 0 0 var(--nn-space);
  padding: 1em 1.1em;
  overflow-x: auto;
  border: 1px solid var(--nn-line);
  border-radius: 7px;
  background: var(--nn-code-bg);
  color: var(--nn-code-ink);
  font-family: var(--nn-mono);
  font-size: .88em;
  line-height: 1.65;
  letter-spacing: 0;
  overflow-wrap: normal;
  word-break: normal;
  white-space: pre;
  text-autospace: no-autospace;
}
.entry-content .command { white-space: pre-wrap; overflow-wrap: anywhere; }
.entry-content code, .entry-content kbd, .entry-content samp, .comment-content code {
  font-family: var(--nn-mono);
  font-size: .9em;
  letter-spacing: 0;
  text-autospace: no-autospace;
}
.entry-content :not(pre) > code { padding: .1em .35em; border-radius: 4px; background: var(--nn-soft); }
.entry-content pre code { padding: 0; background: none; color: inherit; font-size: 1em; }
.entry-content .command a, .entry-content pre a { color: #8fe3d6; }

/* 古い記事のテーマが持っていた印（色の強調・節の見出し） */
.entry-content .fontcolor1 { color: var(--nn-accent-2); font-weight: 700; }
.entry-content .fontcolor2 { color: var(--nn-accent); font-weight: 700; }
.entry-content .command .fontcolor1 { color: #ffb88a; }
.entry-content .command .fontcolor2 { color: #8fe3d6; }
.entry-content .borderA {
  margin-block: var(--nn-heading-space) .75em;
  padding: .2em 0 .2em .7em;
  border-left: 4px solid var(--nn-accent);
  font-size: 1.15em;
  font-weight: 800;
  line-height: var(--nn-heading-leading);
  letter-spacing: var(--nn-heading-tracking);
}

/* 画像の寄せ（WordPress の印） */
.alignleft { float: left; margin: .3em 1.2em .8em 0; }
.alignright { float: right; margin: .3em 0 .8em 1.2em; }
.aligncenter { display: block; margin-inline: auto; }
.wp-caption { max-width: 100%; }
.entry-content::after { content: ""; display: table; clear: both; }
.img-alt { display: inline-block; padding: .2em .5em; border: 1px dashed var(--nn-line); color: var(--nn-muted); font-size: .85em; }
img[data-dead="1"] { display: none; }   /* 写しを作れなかった外部画像。JS があれば alt の字に置き換わる */

/* 目次（Easy Table of Contents の書き出しをそのまま。開け閉めは無し） */
#ez-toc-container {
  display: table;
  max-width: 100%;
  margin: 0 0 var(--nn-space);
  padding: .8em 1.2em;
  border: 1px solid var(--nn-line);
  border-radius: 7px;
  background: #f7faf8;
  font-size: .92em;
}
#ez-toc-container .ez-toc-title { margin: 0 0 .3em; font-weight: 800; }
#ez-toc-container ul { margin: 0; padding-left: 1.2em; }
#ez-toc-container nav > ul { padding-left: 1.1em; }
#ez-toc-container li { margin: .15em 0; }
#ez-toc-container a { text-decoration: none; }
.eztoc-hide { display: none; }

/* リンクの札（Pz-LinkCard の書き出し） */
.linkcard { margin: 0 0 var(--nn-space); }
.lkc-link { display: block; color: inherit; text-decoration: none; }
.lkc-card { padding: .8em 1em; border: 1px solid var(--nn-line); border-radius: 8px; background: #fff; }
.lkc-info { display: flex; align-items: center; gap: .4em; color: var(--nn-muted); font-size: .8em; }
.lkc-content::after { content: ""; display: table; clear: both; }
.lkc-thumbnail { float: right; margin: 0 0 .4em .8em; }
.lkc-thumbnail img { width: 100px; height: auto; }
.lkc-title { font-weight: 800; line-height: var(--nn-heading-leading); }
.lkc-excerpt, .lkc-date, .lkc-cat-list { color: var(--nn-muted); font-size: .85em; }
.lkc-cat-list object { display: inline; }
.lkc-cat { margin-right: .5em; }

/* ---- コメント（書いた人の名前・日時・本文だけ。受け付けは終了） ---- */
.comments-area { margin-top: 28px; }
.comments-title { margin: 0 0 16px; font-size: 20px; font-weight: 800; }
.commentlist, .commentlist .children { list-style: none; margin: 0; padding: 0; }
.commentlist .children { margin-left: 1.25em; padding-left: 1em; border-left: 2px solid var(--nn-soft); }
.comment-body { margin: 0 0 14px; padding: 12px 16px; border: 1px solid var(--nn-line); border-radius: 8px; background: #fff; }
.bypostauthor > .comment-body { background: #f6fbf9; }
.comment-meta { display: flex; flex-wrap: wrap; gap: 2px 12px; align-items: baseline; margin-bottom: 6px; }
.comment-meta .fn { font-style: normal; font-weight: 800; }
.comment-date { color: var(--nn-muted); font-size: 13px; text-decoration: none; }
.comment-content > :last-child { margin-bottom: 0; }
.comment-content img { max-width: 100%; }
.comments-closed { margin: 18px 0 0; padding: 10px 14px; border-radius: 6px; background: var(--nn-note); color: var(--nn-muted); font-size: 14px; }

/* ---- サイドバー（本文と同じ書体・行間・字間） ---- */
.widget {
  margin-bottom: 18px;
  padding: 17px 18px;
  border: 1px solid var(--nn-line);
  border-radius: 8px;
  background: #fff;
  font-size: 15px;
}
.widget-title { margin: 0 0 12px; font-size: 15px; font-weight: 800; }
.widget ul { list-style: none; margin: 0; padding: 0; }
.widget li { padding: 8px 0; border-bottom: 1px solid var(--nn-soft); line-height: 1.55; }
.widget li:last-child { border-bottom: 0; }
.widget a { color: var(--nn-ink); text-decoration: none; }
.widget a:hover, .widget a:focus { color: var(--nn-accent); }
.widget .children { margin-left: 12px; }
.widget .children li:last-child { padding-bottom: 0; }
.category-tree .children { margin-top: 8px; border-top: 1px solid var(--nn-soft); }
.textwidget::after { content: ""; display: table; clear: both; }
.textwidget a { color: var(--nn-accent); }
.archive-select, .search-field {
  width: 100%;
  min-height: 40px;
  padding: 6px 10px;
  border: 1px solid var(--nn-line);
  border-radius: 6px;
  background: #fff;
  color: var(--nn-ink);
  font: inherit;
}
.search-widget { display: none; }
.js .search-widget { display: block; }
.search-results:empty { display: none; }
.search-results { margin-top: 8px; }
.search-date { display: block; color: var(--nn-muted); font-size: 12px; }
.search-none { color: var(--nn-muted); }
.archive-noscript li { padding: 4px 0; }

/* ---- フッター ---- */
#colophon { padding: 24px 36px; border-top: 1px solid var(--nn-line); background: var(--nn-note); color: var(--nn-muted); font-size: 14px; }
#colophon p { margin: 0 0 4px; }
#colophon a { color: var(--nn-muted); }

/* ---- 広告（自動広告が見出しの帯や空の枠に入ったときに隠す。今のサイトの設定のまま） ---- */
.adsbygoogle, ins.adsbygoogle { max-width: 100%; }
.site-header .google-auto-placed, .site-header .adsbygoogle, .google-auto-placed:empty,
.google-auto-placed ins.adsbygoogle[data-ad-status=unfilled], .adsbygoogle[data-ad-status=unfilled] {
  display: none !important; min-height: 0 !important; height: 0 !important; margin: 0 !important; padding: 0 !important;
}

/* ---- 狭い画面 ---- */
@media (max-width: 959px) {
  #page { margin: 0; border-left: 0; border-right: 0; box-shadow: none; }
  .site-header { padding: 24px 22px 0; }
  #main.wrapper { padding: 26px 22px 34px; }
  #secondary.widget-area { flex-basis: 100%; }
}
@media (max-width: 640px) {
  .home .site-header, .blog .site-header, .single .site-header, .page .site-header, .error404 .site-header { min-height: 220px; }
  .site-title { font-size: 24px; }
  .home .site-title, .blog .site-title, .single .site-title, .page .site-title, .error404 .site-title { font-size: 30px; }
  .site-description, .home .site-description, .blog .site-description, .single .site-description,
  .page .site-description, .error404 .site-description { font-size: 13px; }
  #main.wrapper { gap: 24px; padding: 20px 14px 30px; }
  .card .entry-title { padding: 18px 18px 0; font-size: 21px; }
  .entry-summary, .card .entry-meta { padding-left: 18px; padding-right: 18px; }
  .entry .entry-title { font-size: 24px; }
  .entry-content table { display: block; max-width: 100%; overflow-x: auto; }
  .alignleft, .alignright { float: none; display: block; margin: .5em auto; }
  #colophon { padding: 20px 16px; }
}

@media print {
  .main-navigation, #secondary, .nav-single, .paging-navigation, .adsbygoogle { display: none !important; }
  #page { margin: 0; border: 0; box-shadow: none; }
  .site-header { min-height: 0 !important; background: none !important; color: #000; }
  .site-title a, .site-description { color: #000 !important; }
}
