/* =============================================================
   ADACCHI Portfolio  -  main stylesheet
   Design system: 白基調 + オレンジアクセント / 左サイドバー固定ナビ
   このCSSは WordPressテーマ と 静的preview.html の両方で共有します。
   ============================================================= */

/* ---------- Design tokens ---------- */
:root{
  --bg:        #ffffff;
  --ink:       #1a1a1a;   /* 見出し・本文の濃い色 */
  --ink-2:     #4a4a4a;   /* 通常本文 */
  --ink-3:     #8a8a8a;   /* 補助テキスト */
  --line:      #e6e6e6;   /* 罫線 */
  --line-2:    #f0f0f0;
  --accent:    #ed6c00;   /* オレンジ */
  --accent-d:  #cf5f00;
  --paid:      #ef6b7d;   /* 有料タグ */
  --free:      #25c4c9;   /* 無料タグ */
  --placeholder:#1a1a1a;  /* 1:1 / 16:9 ダミー背景 */

  --sidebar-w: 288px;
  --pad-x:     clamp(20px, 4vw, 64px);
  --maxw:      1440px;   /* 本文を広めにして右側のタグラインまでの余白を詰める */

  --ff-en: "Inter", "Helvetica Neue", Arial, sans-serif;
  --ff-jp: "Noto Sans JP", "Hiragino Kaku Gothic ProN", "Yu Gothic", Meiryo, sans-serif;
}

/* ---------- Reset ---------- */
*,*::before,*::after{ box-sizing:border-box; }
html{ -webkit-text-size-adjust:100%; scroll-behavior:smooth; }
body{
  margin:0;
  background:var(--bg);
  color:var(--ink);
  font-family:var(--ff-jp);
  font-size:15px;
  line-height:1.8;
  -webkit-font-smoothing:antialiased;
  text-rendering:optimizeLegibility;
}
img{ max-width:100%; height:auto; display:block; }
a{ color:inherit; text-decoration:none; transition:color .2s ease; }
ul{ list-style:none; margin:0; padding:0; }
button{ font-family:inherit; cursor:pointer; }

/* ============================================================
   LAYOUT  -  sidebar + content
   ============================================================ */
.site{ min-height:100vh; }

.site-sidebar{
  position:fixed;
  top:0; left:0; bottom:0;
  width:var(--sidebar-w);
  padding:48px 26px 0;   /* 下端までコピーライトの線を伸ばすため下余白は0 */
  background:var(--bg);
  border-right:1px solid var(--line);
  display:flex;
  flex-direction:column;
  overflow-y:auto;   /* 背の低い端末では内部スクロール */
  z-index:100;       /* メニューを最前面に */
}

/* メニューを閉じる(×)ボタン : スマホでメニューを開いた時だけ右上に表示 */
.nav-close{ display:none; }

/* logo : ADACCHIとGRAPHIC DESIGNERの幅をそろえ、下線はオレンジで全幅 */
.brand{ display:inline-block; margin-bottom:26px; }   /* ロゴ下の余分な余白を詰める */
.brand__img{ max-width:215px; width:100%; height:auto; display:block; }  /* 管理画面でロゴ画像を設定した場合 */
.mobile-bar .brand__img{ max-width:140px; }
.brand__name{
  display:block;
  font-family:var(--ff-en);
  font-weight:800;
  letter-spacing:.04em;
  font-size:31px;
  line-height:1;
  color:var(--ink);
}
.brand__role{
  display:block;
  width:100%;                      /* ADACCHIの幅に合わせる */
  font-family:var(--ff-en);
  font-weight:700;
  font-size:13px;
  margin-top:8px;
  padding-bottom:10px;
  border-bottom:2px solid var(--accent);
  color:var(--ink);
  text-align:justify;              /* 文字を均等割り付けして…  */
  text-align-last:justify;         /* …1行でも左右いっぱいに広げる */
  text-justify:inter-character;
}

/* nav */
.gnav{ display:flex; flex-direction:column; gap:6px; }
.gnav__item{
  display:flex;
  align-items:center;
  gap:15px;
  padding:11px 12px;
  font-family:var(--ff-en);
  font-weight:600;
  font-size:16px;
  letter-spacing:.06em;
  color:var(--ink-2);
  border-left:2px solid transparent;
  border-radius:0 6px 6px 0;
}
.gnav__item svg{ width:21px; height:21px; flex:none; stroke:currentColor; }
/* ホバー : 左に黒い縦線(文字・アイコンも黒)。現在地のときは適用しない */
.gnav__item:not(.is-current):hover{
  color:var(--ink);
  border-left-color:var(--ink);
}
.gnav__item.is-current{
  color:var(--accent);
  border-left-color:var(--accent);
  font-weight:700;
}

/* social + copyright pinned to bottom */
.sidebar-foot{ margin-top:auto; }
.social{ display:flex; flex-direction:column; gap:4px; margin-bottom:10px; }
.social a{ color:var(--ink); }
.social a:hover{ color:var(--accent); }
.social svg{ width:18px; height:18px; }

.copyright{
  font-family:var(--ff-en);
  font-size:10.5px;
  letter-spacing:.04em;
  color:var(--ink-3);
  writing-mode:vertical-rl;
  line-height:1;
  padding-left:6px;
  padding-bottom:24px;     /* 文字の下にオレンジ線を余分に伸ばし下端まで届かせる */
  border-left:2px solid var(--accent);
  align-self:flex-start;
  margin:0;
}

/* プライバシーポリシー : ナビ直下 / 横書き / オレンジ線の右 */
.foot-privacy{
  position:absolute;
  right:26px;
  bottom:18px;
  margin:0;
  padding:0;
  font-size:10px;
  letter-spacing:.04em;
  line-height:1.5;
}
.foot-privacy a{ color:var(--ink-3); text-decoration:none; }
.foot-privacy a:hover{ color:var(--accent); }

/* right vertical tagline */
.tagline{
  position:fixed;
  top:30px; right:10px;
  writing-mode:vertical-rl;
  font-family:var(--ff-en);
  font-weight:600;
  font-size:11px;
  letter-spacing:.32em;
  color:var(--ink-3);
  z-index:40;
  pointer-events:none;
}

/* content */
.site-main{
  margin-left:var(--sidebar-w);
  padding:0 var(--pad-x) 120px;
}
.container{ max-width:var(--maxw); margin:0 auto; }

/* mobile header (hidden on desktop) */
.mobile-bar{ display:none; }

/* ============================================================
   SHARED ELEMENTS
   ============================================================ */
.placeholder{
  position:relative;
  background:var(--placeholder);
  color:#fff;
  display:flex;
  align-items:center;
  justify-content:center;
  overflow:hidden;
  font-family:var(--ff-en);
  font-weight:600;
}
.placeholder::before{ /* diagonal line */
  content:"";
  position:absolute;
  inset:0;
  background:linear-gradient(to top right,
    transparent calc(50% - 0.6px), rgba(255,255,255,.85) 50%,
    transparent calc(50% + 0.6px));
}
.placeholder span{
  position:relative;
  z-index:1;
  background:#000;
  padding:.18em .42em;
  border-radius:10px;
  font-size:clamp(28px,4vw,46px);
}
.ph-1-1{ aspect-ratio:1/1; }
.ph-16-9{ aspect-ratio:16/9; }
.ph-2-1{ aspect-ratio:2/1; }

/* section heading */
.sec-head{
  display:flex;
  align-items:baseline;
  justify-content:space-between;
  gap:20px;
  margin:0 0 26px;
}
.sec-title{
  font-family:var(--ff-en);
  font-weight:800;
  font-size:clamp(26px,3.4vw,38px);
  letter-spacing:.01em;
  color:var(--ink);
  margin:0;
}
.more-link{
  font-weight:700;
  font-size:13px;
  color:var(--accent);
  white-space:nowrap;
  display:inline-flex;
  align-items:center;
  gap:8px;
}
.more-link:hover{ color:var(--accent-d); }
.more-link .arw{ transition:transform .2s ease; }
.more-link:hover .arw{ transform:translateX(4px); }

/* button */
.btn{
  display:inline-flex;
  align-items:center;
  justify-content:center;
  gap:14px;
  width:100%;          /* 親要素(列)の幅いっぱいまで伸ばす */
  padding:16px 26px;
  border:1px solid var(--ink);
  background:var(--bg);
  font-weight:700;
  font-size:14px;
  color:var(--ink);
  transition:all .2s ease;
}
.btn:hover{ background:var(--ink); color:#fff; }
.btn .arw{ transition:transform .2s ease; }
.btn:hover .arw{ transform:translateX(5px); }

/* breadcrumb */
.crumb{
  font-family:var(--ff-en);
  font-size:12px;
  font-weight:700;
  letter-spacing:.08em;
  color:var(--ink-3);
  margin:34px 0 6px;
}
.crumb a:hover{ color:var(--accent); }
.crumb .here{ color:var(--ink); border-bottom:2px solid var(--ink); padding-bottom:2px; }

/* ============================================================
   TOP : HERO
   ============================================================ */
.hero{
  display:grid;
  /* minmax(0,1fr) で見出しの最小幅に引っ張られず、左右きっちり50%ずつにする */
  grid-template-columns:minmax(0,1fr) minmax(0,1fr);
  grid-template-areas:
    "title  visual"
    "body   visual";
  column-gap:48px;
  row-gap:22px;
  align-items:start;
  padding:74px 0 78px;
}
.hero__title{
  grid-area:title;
  font-family:var(--ff-en);
  font-weight:700;
  font-size:clamp(34px, 7.5vw, 120px);   /* JS適用前/無効時のフォールバック(50%列に近いサイズ) */
  line-height:1.04;
  letter-spacing:.005em;
  margin:0;
  color:var(--ink);
  overflow:hidden;                       /* JS計算前の一瞬のはみ出しを防ぐ */
}
.hero__line{ display:block; white-space:nowrap; }  /* 各行をJSで幅に合わせて拡縮 */
.hero__body{ grid-area:body; }
.hero__title .dot{ color:var(--accent); }
.hero__lead{
  font-size:clamp(17px,1.6vw,21px);
  font-weight:700;
  margin:0 0 16px;
  color:var(--ink);
}
.hero__text{
  font-size:14px;
  color:var(--ink-2);
  margin:0 0 32px;
  max-width:30em;
}
.hero__visual{ grid-area:visual; width:100%; align-self:start; }

/* ============================================================
   TOP : WORKS strip
   ============================================================ */
.block{ padding:46px 0; }

.works-strip{
  display:grid;
  grid-template-columns:repeat(5,minmax(0,1fr));  /* カード幅を広めに保ち、タイトルの改行を安定させる */
  gap:16px;
}
.work-mini__thumb{ border-radius:10px; }
.work-mini__title{
  font-weight:700;
  font-size:13px;
  margin:12px 0 2px;
  color:var(--ink);
  word-break:auto-phrase;   /* 文節単位で自然な位置で改行(対応ブラウザ) */
  text-wrap:balance;        /* 行ごとの長さを揃えて読みやすく */
}
.work-mini__cat{ font-size:11px; color:var(--ink-3); margin-top:auto; padding-top:6px; }
/* タイトルの行数が違ってもカテゴリ・日付行をカード下端に固定
   ※後続の「カード共通」の display:block に負けないようセレクタを強めに */
.works-strip .work-mini{ display:flex; flex-direction:column; height:100%; }
.works-strip .work-mini__title{ flex:none; }
.works-strip .work-mini__cat{ margin-bottom:0; }

/* ============================================================
   カード共通(BLOGリンクカード / WORKSカード)
   通常=枠なし / ホバー=オレンジ枠 + 少し浮く
   ※レイアウトがずれないよう、通常時から透明な枠を確保
   ============================================================ */
.work-mini,
.blog-card,
.work-card{
  display:block;
  border:2px solid var(--line);   /* PC・スマホ共通でグレー枠をデフォルト表示 */
  border-radius:12px;
  padding:10px;
  transition:border-color .2s ease, transform .2s ease, box-shadow .2s ease;
}
.work-mini:hover,
.blog-card:hover,
.work-card:hover{
  border-color:var(--accent);
  transform:translateY(-3px);
  box-shadow:0 10px 26px rgba(0,0,0,.10);
}
/* WORKSカードはホバーでタイトルもオレンジに */
.work-mini:hover .work-mini__title,
.work-card:hover .work-card__title{ color:var(--accent); }

/* カード内の画像は角丸に */
.work-mini .placeholder, .work-mini .thumb,
.blog-card .placeholder, .blog-card .thumb,
.work-card .placeholder, .work-card .thumb{ border-radius:8px; }

/* ============================================================
   TOP : LATEST BLOG
   ============================================================ */
.tagrow{ display:flex; flex-wrap:wrap; align-items:center; gap:9px; }
.tagrow .tag-ic{ color:var(--accent); display:flex; align-items:center; font-size:18px; }
/* タグ群は折り返さず1行を維持(入りきらない場合は横スクロール) */
.tags{
  display:flex;
  align-items:center;
  gap:9px;
  flex-wrap:nowrap;
  overflow-x:auto;
  min-width:0;
  scrollbar-width:none;        /* Firefox: スクロールバー非表示 */
}
.tags::-webkit-scrollbar{ display:none; }   /* Chrome/Safari */
.tags .tag{ flex:0 0 auto; }   /* チップを縮ませない */

/* LATEST BLOG見出し : 1行目=見出し+「すべての記事を見る」、2行目=タグ一覧 */
.sec-head--blog{ flex-wrap:wrap; row-gap:8px; }   /* 見出し行とタグの間を詰める */
.sec-head--blog .tags{ flex-basis:100%; margin-top:0; }
.tag{
  font-family:var(--ff-en);
  font-size:12px;
  font-weight:600;
  color:var(--ink-2);
  background:var(--bg);   /* 動的背景が透けないよう白塗り */
  border:1px solid var(--line);
  border-radius:999px;
  padding:4px 14px;
}
.tag:hover{ border-color:var(--accent); color:var(--accent); }

.blog-strip{
  display:grid;
  grid-template-columns:repeat(5,minmax(0,1fr));  /* 長い文節でも列幅を広げない */
  gap:18px;
  margin-top:8px;
}
.blog-card__thumb{ }
.blog-card__chapter{
  color:var(--accent);
  font-family:var(--ff-en);
  font-weight:700;
  font-size:11px;
  letter-spacing:.05em;
  margin-top:14px;
}
.blog-card__title{ font-weight:700; font-size:14px; margin:2px 0 10px; word-break:auto-phrase; text-wrap:balance; }
.blog-card__foot{
  display:flex; align-items:center; justify-content:space-between;
  font-family:var(--ff-en); font-size:11px; color:var(--ink-3);
  border-top:1px solid var(--line); padding-top:8px;
}

/* ============================================================
   TOP : ABOUT teaser
   ============================================================ */
/* ABOUT ME : 画像 / テキスト / 受賞 / スキル の横一列。各列の「詳しく見る」を下端に揃える */
.about-row{
  display:grid;
  grid-template-columns:210px 1.5fr 1fr 1.05fr;
  gap:34px;
  align-items:stretch;
}
.about-col{ display:flex; flex-direction:column; }
.about-col .more-link{ margin-top:auto; padding-top:16px; }
.about-col--img .placeholder{ width:100%; }
/* 画像列 : 列の高さいっぱいまで拡大(比率維持・はみ出しはトリミング)して下端を揃える */
.about-col--img .thumb,
.about-col--img .placeholder{ height:100%; aspect-ratio:auto; min-height:210px; }
/* スキル列 : アイコングリッドを残りの高さに広げ、行を均等配置して下端を揃える */
.about-col--skills .skill-grid{ flex:1; align-content:space-between; }
.about-h{ font-size:15px; line-height:1.7; margin:0 0 12px; font-weight:700; }
.about-p{ font-size:13px; color:var(--ink-2); margin:0; }
.about-label{
  font-family:var(--ff-en); font-weight:700; font-size:12px;
  letter-spacing:.06em; color:var(--ink); margin:0 0 16px;
}
.stat-nums{ display:flex; align-items:center; justify-content:space-evenly; gap:20px; }
/* 受賞・資格の数字を、親要素の高さいっぱいに広げ左右中央へ均等配置 */
.about-col--awards .stat-nums{ flex:1; gap:0; }
.stat-nums .n{ text-align:center; }
.stat-nums .n b{
  display:block; font-family:var(--ff-en); font-weight:800;
  font-size:clamp(48px, 7vw, 84px); line-height:1; color:var(--accent);
}
.stat-nums .n small{ font-size:13px; color:var(--ink-2); }
.skill-grid{ display:grid; grid-template-columns:repeat(5,1fr); gap:7px; }
.skill-grid .placeholder{ border-radius:7px; }
.skill-grid .thumb{ border-radius:7px; overflow:hidden; }
.skill-grid .placeholder span{ font-size:13px; border-radius:5px; padding:.1em .3em;}

/* ============================================================
   GENERIC LIST GRIDS (WORKS / PRODUCTS / BLOG pages)
   ============================================================ */
.lead-title{
  font-family:var(--ff-en);
  font-weight:800;
  font-size:clamp(44px,6vw,80px);
  line-height:1;
  margin:0 0 22px;
  color:var(--ink);
}
.lead-sub{ font-size:clamp(17px,1.8vw,22px); font-weight:700; margin:0 0 12px; }
.lead-text{ font-size:14px; color:var(--ink-2); margin:0 0 26px; max-width:46em; }

.filters{ display:flex; flex-wrap:wrap; gap:10px; margin-bottom:34px; }
.filter{
  font-family:var(--ff-en); font-weight:600; font-size:13px;
  padding:8px 20px; border:1px solid var(--line); border-radius:999px;
  background:#fff; color:var(--ink-2);
}
.filter.is-active{ background:var(--ink); color:#fff; border-color:var(--ink); }
.filter:hover:not(.is-active){ border-color:var(--accent); color:var(--accent); }

.card-grid{
  display:grid;
  grid-template-columns:repeat(3,minmax(0,1fr));  /* 長い文節でも列幅を均等に保つ */
  gap:30px 26px;
}
.work-card__thumb{ position:relative; }
.work-card__badge{
  position:absolute; top:12px; left:12px;
  background:var(--accent); color:#fff;
  font-size:11px; font-weight:700; padding:3px 10px; border-radius:4px;
}
.work-card__cat{
  color:var(--accent); font-weight:700; font-size:12px; margin-top:12px;
}
.work-card__title{
  font-weight:700; font-size:16px; margin:2px 0 6px;
  word-break:auto-phrase;   /* 文節単位で自然な位置で改行(対応ブラウザ) */
  text-wrap:balance;        /* 行ごとの長さを揃えて読みやすく */
}
.work-card__desc{ font-size:13px; color:var(--ink-2); margin:0 0 6px; }
.work-card__meta{ font-size:12px; color:var(--ink-3); }

/* products */
.prod-tags{ display:flex; gap:8px; align-items:center; margin-top:12px; }
.pill{
  font-size:11px; font-weight:700; border-radius:999px; padding:3px 11px;
}
.pill--type{ border:1px solid var(--ink); color:var(--ink); font-family:var(--ff-en);}
.pill--paid{ background:var(--paid); color:#fff; }
.pill--free{ background:var(--free); color:#fff; }

/* ============================================================
   FOOTER
   ============================================================ */
.site-foot-bottom{
  margin-left:var(--sidebar-w);
  margin-right:var(--sidebar-w);
  border-top:1px solid var(--line);
  padding:22px var(--pad-x);
  font-family:var(--ff-en);
  font-size:11px;
  color:var(--ink-3);
  display:flex; justify-content:space-between; flex-wrap:wrap; gap:10px;
}

/* ============================================================
   ABOUT ページ
   ============================================================ */
/* セクション見出し(VALUES／…) */
.abt-label{
  font-family:var(--ff-en); font-weight:700; font-size:14px;
  letter-spacing:.04em; color:var(--ink-3);
  margin:46px 0 22px; padding-bottom:10px;
  border-bottom:1px solid var(--line);
}
.abt-label span{ color:var(--ink-2); font-family:var(--ff-jp); font-size:13px; }
.abt-label--major{ border-bottom:2px solid var(--ink); color:var(--ink); }

/* プロフィール */
.abt-profile{
  display:grid; grid-template-columns:330px 1fr; gap:42px;
  align-items:start; margin:28px 0 42px;
}
.abt-profile__img .placeholder{ width:100%; }
.abt-role{ color:var(--accent); font-weight:700; font-size:14px; margin:0 0 6px; }
.abt-name{
  font-family:var(--ff-en); font-weight:800; letter-spacing:.01em;
  font-size:clamp(28px,3vw,40px); margin:0 0 8px; color:var(--ink);
}
.abt-nameline{ display:flex; align-items:baseline; gap:0px; flex-wrap:wrap; margin:0 0 18px; }
.abt-jp{ font-weight:700; font-size:16px; margin:0; }
.abt-meta{ font-size:13px; color:var(--ink-3); margin:0; }
.abt-catch{ font-weight:700; font-size:18px; margin:0 0 8px; }
.abt-desc{ font-size:14px; color:var(--ink-2); line-height:1.9; margin:0 0 22px; }
.abt-dl{ width:auto; border-color:var(--accent); color:var(--accent); }
.abt-dl:hover{ background:var(--accent); color:#fff; }
.abt-dl i{ transition:transform .2s ease; }
.abt-dl:hover i{ transform:translateY(3px); }   /* ホバーでDLアイコンが少し下がる */

/* 統計カード */
.abt-stats{ display:grid; grid-template-columns:repeat(3,1fr); gap:22px; margin:0 0 6px; }
.abt-stat{ border:1px solid var(--line); border-radius:10px; padding:26px; text-align:center; }
.abt-stat b{
  display:block; font-family:var(--ff-en); font-weight:800;
  font-size:42px; line-height:1; color:var(--accent); margin-bottom:8px;
}
.abt-stat span{ font-size:13px; color:var(--ink-2); }

/* VALUES */
.abt-values{ display:grid; grid-template-columns:repeat(3,minmax(0,1fr)); gap:24px; }
.abt-value{ border:1px solid var(--line); border-radius:10px; padding:26px; }
.abt-value i{ font-size:30px; color:var(--ink); display:block; margin-bottom:18px; }
.abt-value h4{ font-size:18px; margin:0 0 10px; }
.abt-value p{ font-size:13.5px; color:var(--ink-2); line-height:1.85; margin:0; }

/* VISION */
.abt-vision{ border-left:3px solid var(--accent); margin:0; padding:4px 0 4px 20px; }
.abt-vision p{ font-size:15px; color:var(--ink); margin:0 0 6px; }
.abt-vision p:last-child{ font-size:14px; color:var(--ink-2); margin:0; }

/* SKILLS */
.abt-skills{ display:grid; grid-template-columns:1fr 1fr; gap:22px 50px; }
.abt-skill__head{ display:flex; justify-content:space-between; align-items:baseline; margin-bottom:10px; }
.abt-skill__name{ font-weight:700; font-size:15px; }
.abt-skill__sub{ font-size:12px; color:var(--ink-3); }
.abt-bar{ height:8px; background:var(--line-2); border-radius:999px; overflow:hidden; }
.abt-bar__fill{ display:block; height:100%; background:var(--accent); border-radius:999px; }

/* TOOLS : ただのラベル(ホバー・クリックで変化なし) */
.abt-tools{ display:flex; flex-wrap:wrap; gap:10px; }
.abt-tools .tag{ cursor:default; }
.abt-tools .tag:hover{ border-color:var(--line); color:var(--ink-2); }

/* AWARDS & QUALIFICATIONS */
.abt-aq{ display:grid; grid-template-columns:1fr 1fr; gap:0 60px; }
.abt-award{ display:flex; gap:18px; padding:15px 0; border-bottom:1px solid var(--line); }
.abt-award:first-child{ padding-top:4px; }
.abt-award__year{ font-family:var(--ff-en); font-size:13px; color:var(--ink-3); flex:0 0 auto; padding-top:2px; }
.abt-award__title{ color:var(--accent); font-weight:700; font-size:15px; margin:0 0 4px; }
.abt-award__desc{ font-size:13px; color:var(--ink-2); margin:0; }
.abt-qual{ display:flex; justify-content:space-between; align-items:center; gap:14px; padding:15px 0; border-bottom:1px solid var(--line); }
.abt-qual:first-child{ padding-top:4px; }
.abt-qual__name{ font-weight:700; font-size:14px; }
.abt-qual__date{ font-family:var(--ff-en); font-size:13px; color:var(--ink-3); white-space:nowrap; }

/* TIMELINE */
.abt-timeline{ position:relative; padding-left:30px; }
.abt-timeline::before{ content:""; position:absolute; left:6px; top:6px; bottom:14px; width:2px; background:var(--line); }
.abt-tl{ position:relative; padding-bottom:26px; }
.abt-tl::before{ content:""; position:absolute; left:-29px; top:4px; width:12px; height:12px; border-radius:50%; background:var(--accent); }
.abt-tl--sub{ margin-top:-8px; }
.abt-tl--sub::before{ display:none; }
.abt-tl__year{ font-family:var(--ff-en); font-weight:700; font-size:15px; color:var(--accent); margin:0 0 2px; }
.abt-tl__title{ font-weight:700; font-size:16px; margin:0 0 4px; }
.abt-tl__desc{ font-size:13px; color:var(--ink-2); line-height:1.8; margin:0; }

/* ============================================================
   WORKS 詳細 (single-work.php)
   ============================================================ */
.sw-meta{ display:flex; flex-wrap:wrap; align-items:center; gap:9px; margin:6px 0 6px; }
.sw-cat{ color:var(--accent); font-weight:700; font-size:13px; }
.sw-badge{ background:var(--accent); color:#fff; font-size:11px; font-weight:700; padding:2px 9px; border-radius:4px; }
.sw-sep{ color:var(--line); }
.sw-dim{ font-family:var(--ff-en); font-size:12px; color:var(--ink-3); }
.sw-title{ font-weight:800; font-size:clamp(26px,3.4vw,40px); line-height:1.12; margin:4px 0 8px; }
.sw-sub{ font-weight:700; font-size:clamp(15px,1.6vw,18px); margin:0 0 22px; }
/* ヒーロー : 画像を切らずに全体を収めて表示(ロゴ等も全体が見える) */
.sw-hero{
  background:var(--line-2); border-radius:10px;
  display:flex; align-items:center; justify-content:center;
  padding:24px; margin:0 0 16px;
}
.sw-hero img{ max-width:100%; max-height:520px; width:auto; height:auto; border-radius:6px; display:block; }
.sw-hero .placeholder{ width:100%; border-radius:6px; }

.sw-info{
  display:grid; grid-template-columns:repeat(auto-fit,minmax(150px,1fr));
  gap:1px; background:var(--line); border:1px solid var(--line);
  border-radius:8px; overflow:hidden; margin:0 0 38px;
}
.sw-info div{ background:#fff; padding:13px 15px; }
.sw-info .k{ display:block; font-family:var(--ff-en); font-size:10px; font-weight:700; letter-spacing:.05em; color:var(--ink-3); margin-bottom:3px; }
.sw-info .v{ font-size:13px; font-weight:700; }

.sw-seclabel{
  font-family:var(--ff-en); font-weight:700; font-size:14px; letter-spacing:.04em;
  color:var(--ink); border-bottom:2px solid var(--ink); padding-bottom:10px; margin:0 0 24px;
}
.sw-seclabel span{ font-family:var(--ff-jp); color:var(--ink-2); font-size:13px; }

/* PROCESS = 本文。H3が自動で「01 / 02 …」の工程ラベルになる。
   各工程は縦に並べ、横中央に揃える(中央寄せの列) */
.work-process{ counter-reset:step; max-width:760px; margin-left:auto; margin-right:auto; }
.work-process h2,
.work-process h3{
  counter-increment:step;
  display:flex; align-items:baseline; gap:13px;
  font-size:18px; margin:30px 0 14px; padding-top:18px;
  border-top:1px solid var(--line);
}
.work-process h2:first-child,
.work-process h3:first-child{ border-top:none; padding-top:0; margin-top:0; }
.work-process h2::before,
.work-process h3::before{
  content:counter(step,decimal-leading-zero);
  font-family:var(--ff-en); font-weight:800; font-size:20px; color:var(--accent);
}
.work-process p{ font-size:14px; color:var(--ink-2); line-height:1.95; margin:0 0 14px; text-align:left; }
.work-process img{ border-radius:10px; margin:10px auto 18px; height:auto; max-width:100%; display:block; }
/* PROCESS内の表(定義データの抜粋など) */
.work-process .wp-block-table{ margin:6px 0 18px; overflow-x:auto; border:1px solid var(--line); border-radius:10px; }
.work-process .wp-block-table table{ width:100%; border-collapse:collapse; font-size:12.5px; line-height:1.6; margin:0; }
.work-process .wp-block-table th,
.work-process .wp-block-table td{ padding:9px 12px; border-bottom:1px solid var(--line); text-align:left; white-space:nowrap; vertical-align:middle; }
.work-process .wp-block-table th{ background:var(--accent); color:#fff; font-family:var(--ff-en); font-weight:700; font-size:11.5px; letter-spacing:.04em; }
.work-process .wp-block-table tbody tr:nth-child(even) td{ background:#fff8f2; }
.work-process .wp-block-table tbody tr:last-child td{ border-bottom:0; }
.work-process .wp-block-table td:nth-child(4){ font-family:var(--ff-en); color:var(--accent-d); font-weight:600; }
.work-process .wp-block-table figcaption{ font-size:12px; color:var(--ink-3); text-align:center; padding:8px 12px 10px; margin:0; }
/* グループブロック(横並びで入っていても)を縦積みに。文章は全幅左揃え・画像は中央
   ※例外 : 「追加CSSクラス」に cols-flex を付けたグループは横並びを維持 */
.work-process .wp-block-group{ display:flex !important; flex-direction:column !important; align-items:stretch !important; gap:0px; }
.work-process .wp-block-group > p{ text-align:left; }
.work-process .wp-block-group.cols-flex{ flex-direction:row !important; align-items:center !important; gap:16px; }
.work-process .wp-block-group.cols-flex > *{ min-width:0; flex:1 1 0; }
.work-process .wp-block-group.cols-flex figure,
.work-process .wp-block-group.cols-flex .wp-block-image{ margin:10px 0; }
@media (max-width:781px){
	.work-process .wp-block-group.cols-flex{ flex-direction:column !important; }
}
.work-process ul,.work-process ol{ font-size:14px; color:var(--ink-2); line-height:1.9; padding-left:1.4em; margin:0 0 14px; }
/* 工程内の画像は回り込みさせず、文章の下に整列(短い文章でも隙間ができない) */
.work-process figure,
.work-process .wp-block-image{ float:none !important; margin:16px auto 24px; max-width:100%; text-align:center; }
.work-process .wp-block-image.alignright,
.work-process .wp-block-image.alignleft,
.work-process .wp-block-image.aligncenter{ float:none !important; margin-left:auto; margin-right:auto; }
.work-process figure img,
.work-process .wp-block-image img{ border-radius:10px; max-width:100%; height:auto; }
.work-process figcaption{ font-size:11px; color:var(--ink-3); margin-top:7px; line-height:1.6; text-align:center; }
.work-process h2, .work-process h3{ clear:both; }
/* 「メディアとテキスト」ブロックも縦積み(文章→画像)にして隙間をなくす */
.work-process .wp-block-media-text{ display:block !important; grid-template-columns:none !important; }
.work-process .wp-block-media-text__content{ padding:0 !important; }
.work-process .wp-block-media-text__media{ margin:16px 0 0; max-width:860px; }
.work-process .wp-block-media-text__media img{ border-radius:10px; max-width:100%; height:auto; }
/* カラムブロックも工程内では縦積み(横並びの隙間を防ぐ)
   ※例外 : カラムブロックの「追加CSSクラス」に cols-flex を付けると横並びを維持 */
.work-process .wp-block-columns:not(.cols-flex){ display:block !important; }
.work-process .wp-block-columns:not(.cols-flex) .wp-block-column{ flex-basis:auto !important; width:100% !important; margin:0 !important; }
.work-process .wp-block-column{ align-items:center; }
.work-process .wp-block-column figure{ margin:14px auto 20px; }

/* 例外 : cols-flex は横並び(エディタで指定したカラム幅 flex-basis が効く) */
.work-process .wp-block-columns.cols-flex{
  display:flex !important; flex-wrap:nowrap !important;
  align-items:center; gap:24px;
}
.work-process .wp-block-columns.cols-flex > .wp-block-column{ min-width:0; }
.work-process .wp-block-columns.cols-flex > .wp-block-column figure{ margin:8px auto; }
@media (max-width:781px){
  .work-process .wp-block-columns.cols-flex{ display:block !important; }
  .work-process .wp-block-columns.cols-flex > .wp-block-column{ margin-bottom:14px !important; }
}

/* PCのみ : 工程の列幅を画面の半分に狭めて中央寄せ(スマホは現状のまま) */
@media (min-width:769px){
  .work-process{ max-width:40vw; }
}

/* RESULT */
.sw-result{ background:var(--ink); color:#fff; border-radius:12px; padding:26px; margin:34px 0 28px; }
.sw-result__label{ display:block; color:var(--accent); font-weight:700; font-size:13px; letter-spacing:.08em; margin-bottom:18px; }
.sw-result__grid{ display:grid; grid-template-columns:repeat(auto-fit,minmax(150px,1fr)); gap:20px; }
.sw-result__item b{ display:block; font-family:var(--ff-en); font-weight:800; font-size:26px; line-height:1.15; color:var(--accent); }
.sw-result__item small{ font-size:12px; color:#cfcfcf; }

.sw-back .arw{ transform:rotate(180deg); }

/* ============================================================
   RESPONSIVE
   ============================================================ */
/* 右の縦タグラインは、右側に余白ができる広い画面のみ表示(重なり防止) */
@media (max-width:1200px){
  .tagline{ display:none; }
}

@media (max-width:1024px){
  .works-strip{ grid-template-columns:repeat(3,minmax(0,1fr)); }
  .blog-strip{ grid-template-columns:repeat(3,minmax(0,1fr)); }
  .skill-grid{ grid-template-columns:repeat(5,1fr); }
}

/* ABOUT ME : この幅以下は「画像+テキスト」を1段目、「受賞+ツール」を2段目に */
@media (max-width:1100px){
  .about-row{ display:flex; flex-wrap:wrap; gap:30px; }
  .about-col--img{ flex:0 0 200px; }
  .about-col--text{ flex:1 1 calc(100% - 230px); }
  .about-col--awards,
  .about-col--skills{ flex:1 1 calc(50% - 15px); }
}

@media (max-width:860px){
  :root{ --sidebar-w:0px; --mobile-bar-h:56px; }
  .tagline{ display:none; }

  /* 固定トップバー : 左ロゴ(ホームへ) / 右ハンバーガー */
  .mobile-bar{
    display:flex;
    align-items:center;
    justify-content:space-between;
    position:fixed;
    top:0; left:0; right:0;
    height:var(--mobile-bar-h);
    padding:0 16px;
    background:var(--bg);
    z-index:120;               /* メニュー(100)より前面 */
  }
  /* バーの影 : メニュー(z:100)より下のレイヤーに描くことで、
     クリッピングマスクの展開に追従して隠れ、閉じる時は逆に現れる */
  body::after{
    content:"";
    position:fixed;
    top:0; left:0; right:0;
    height:var(--mobile-bar-h);
    box-shadow:0 2px 14px rgba(0,0,0,.10);
    z-index:90;
    pointer-events:none;
  }
  .mobile-bar .brand{ margin:0; display:flex; align-items:center; }
  .mobile-bar .brand__img{ max-width:140px; max-height:40px; width:auto; }
  .mobile-bar .brand__name{ font-size:18px; }
  .mobile-bar .brand__role{ font-size:8px; margin-top:3px; padding-bottom:3px; border-bottom-width:1.5px; }
  .burger{
    border:none; background:none; padding:4px 2px;
    font-size:25px; line-height:1; color:var(--ink);
  }
  /* 768px以下 : ロゴを左右中央に(ハンバーガーは右端に固定) */
  @media (max-width:768px){
    .mobile-bar{ justify-content:center; }
    .burger{ position:absolute; right:16px; top:50%; transform:translateY(-50%); }
  }
  .burger .bi-x-lg{ display:none; }
  body.nav-open .burger .bi-list{ display:none; }
  body.nav-open .burger .bi-x-lg{ display:inline; color:var(--accent); font-size:21px; }

  /* メニュー : バーの下から上→下へマスクが広がって展開(閉じる時は逆再生) */
  .site-sidebar{
    top:var(--mobile-bar-h);
    width:100%;
    padding:26px 22px 0;
    border-right:none;
    clip-path: inset(0 0 100% 0);
    transition: clip-path .5s cubic-bezier(.4,0,.2,1);
  }
  body.nav-open .site-sidebar{
    clip-path: inset(0 0 0 0);
  }
  .site-sidebar .brand{ display:none; }   /* ロゴはバー側に常時表示 */

  /* スマホのメニュー下部 : 左=コピーライト(縦書き) / 右=SNS(縦並び) の2列に */
  .sidebar-foot{
    display:flex;
    flex-direction:row;
    align-items:flex-start;
    gap:20px;
  }
  .sidebar-foot .copyright{ order:1; margin:0; padding-bottom:0; }
  .sidebar-foot .social{ order:2; flex-direction:column; margin:0; }

  .site-main{ margin-left:0; padding:calc(var(--mobile-bar-h) + 22px) 20px 80px; }  /* バーの下から本文開始 */
  .site-foot-bottom{ margin-left:0; }

  .about-col--img .placeholder{ max-width:220px; }

  /* スマホは固定ロゴボタン分の上余白があるので、パンくず上の余白は不要 */
  .crumb{ margin-top:10px; }

  /* ABOUTページ : 426px以上では画像+テキストの横2列を維持(画像列は可変幅) */
  .abt-profile{ grid-template-columns:minmax(0,40%) 1fr; gap:24px; }
  .abt-skills{ grid-template-columns:1fr; gap:18px; }
  .abt-aq{ grid-template-columns:1fr; }
  .abt-quals{ margin-top:28px; }
}


@media (max-width:600px){
  /* スマホ : ヒーローを縦積み + 順番を キャッチコピー → 画像 → 文章 → ボタン に */
  .hero{
    grid-template-columns:1fr;
    grid-template-areas:
      "title"
      "visual"
      "body";
    row-gap:26px;
    padding:8px 0 40px;   /* 見出し上の余白を削減 */
  }
  .hero__visual{ max-width:420px; }

  /* セクション見出しの「すべて見る」リンクが入りきらない時は次の行の右端へ */
  .sec-head{ flex-wrap:wrap; }
  .sec-head .more-link{ margin-left:auto; }

  .abt-stats{ grid-template-columns:1fr; }
  .abt-values{ grid-template-columns:1fr; }

  .works-strip{ grid-template-columns:1fr; }  /* カード幅を保つため1列に */
  .blog-strip{ grid-template-columns:1fr; }  /* カード幅を保つため1列に */
  .card-grid{ grid-template-columns:1fr; }
  .skill-grid{ grid-template-columns:repeat(5,1fr); }
  .stat-nums .n b{ font-size:32px; }
  /* さらに狭い画面では4ブロックを縦に積む */
  .about-col--img,
  .about-col--text,
  .about-col--awards,
  .about-col--skills{ flex:1 1 100%; }
  .about-col--img .placeholder{ max-width:200px; }
}

/* ABOUTプロフィール : 425px以下では画像を上・テキストを下に縦積み(画像は全幅) */
@media (max-width:425px){
  .abt-profile{ grid-template-columns:1fr; gap:22px; }
  .abt-profile__img .placeholder{ max-width:none; }
}

/* nav scrim for mobile */
.nav-scrim{ display:none; }
@media (max-width:860px){
  /* グレーアウトはなし。透明のまま画面外タップで閉じられるようにだけしておく */
  body.nav-open .nav-scrim{
    display:block; position:fixed; inset:0; z-index:90;
    background:transparent;
  }
  /* 閉じるボタンはバーのハンバーガー(×表示)に統合したため非表示のまま */
}

/* ============================================================
   Masonry ギャラリー(Pinterest風)
   ギャラリーブロックの「追加CSSクラス」に masonry を付けると有効。
   仕組み : CSS Gridの細かい行(8px)に、JS(main.js)が画像の高さに
   応じた行スパンを設定して敷き詰める。
   ============================================================ */
.wp-block-gallery.masonry{
  display:grid !important;
  grid-template-columns:repeat(auto-fill, minmax(min(220px, 100%), 1fr));
  grid-auto-rows:1px;   /* 1px刻みにして縦の隙間を均一にする(JSのROWと揃える) */
  gap:0 14px !important;
  align-items:start;
}
.wp-block-gallery.masonry > figure,
.wp-block-gallery.masonry > .wp-block-image{
  margin:0 !important;
  padding-bottom:0;         /* 縦方向の間隔はJS(main.js)のGAPで確保 */
  width:auto !important;
  /* WP標準のflex化を無効に(flexだと画像が枠の高さに縮み、高さを測れない) */
  display:block !important;
  align-items:flex-start;
}
.wp-block-gallery.masonry img{
  width:100% !important; height:auto !important;
  display:block; border-radius:10px; margin:0 !important;
}
.wp-block-gallery.masonry figcaption{ text-align:left; font-size:11px; color:var(--ink-3); margin-top:6px; }

/* 将来 : ネイティブmasonry(grid-lanes)対応ブラウザではCSSのみで実現(JSは自動で無効化) */
@supports (display: grid-lanes){
  .wp-block-gallery.masonry{ display:grid-lanes !important; grid-auto-rows:auto; gap:14px !important; }
  .wp-block-gallery.masonry > figure,
  .wp-block-gallery.masonry > .wp-block-image{ padding-bottom:0; }
}

/* ============================================================
   動的背景 (bg-canvas.js) : 全ページの背面に固定表示
   ============================================================ */
:root{
  --bgfx-grid: #ececec;   /* 背景グリッド線の色 */
  --bgfx-ring: #dcdcdc;   /* 軌道リングの色 */
}
.bgfx-canvas{
  position: fixed;
  inset: 0;
  width: 100vw;
  height: 100vh;
  z-index: -1;
  pointer-events: none;
  opacity: 0.32;          /* 背景全体の濃さはここで調整(1で原寸の濃さ) */
}
/* 本文の可読性確保 : カード類には白背景を敷いて背景を透けさせない */
.work-card, .blog-card, .pd-card, .work-mini,
.stat-card, .abt-stat, .abt-value, .pd-feat,
.pd-spec, .pd-price, .pd-faq .q, .sw-info div,
.btn, .filter{
  background: var(--bg);
}

/* ============================================================
   PRODUCTS 一覧 / 詳細 (archive-product.php / single-product.php)
   ============================================================ */
/* 一覧 : 2カラム(16:9カード) */
.pd-grid{ grid-template-columns:repeat(2,minmax(0,1fr)); }
.pd-card{ border:1px solid var(--line); border-radius:10px; overflow:hidden; padding:0 0 18px; transition:transform .2s ease, border-color .2s ease; display:block; }
.pd-card:hover{ transform:translateY(-4px); border-color:var(--accent); }
.pd-card .prod-tags,
.pd-card .work-card__title,
.pd-card .work-card__desc{ padding:0 18px; }
.pd-card .work-card__title{ font-size:17px; margin-top:8px; }
.pd-card--soon{ opacity:.65; }
.pd-card--soon:hover{ transform:none; border-color:var(--line); }

/* 詳細 : ヒーロー */
.pd-hero{ display:grid; grid-template-columns:1fr 1fr; gap:36px; align-items:center; margin:18px 0 10px; }
.pd-name{ font-family:var(--ff-en); font-weight:800; font-size:clamp(28px,3.4vw,44px); line-height:1.05; margin:12px 0 6px; }
.pd-namejp{ font-weight:700; font-size:14px; margin:0 0 12px; }
.pd-tag{ font-size:14px; color:var(--ink-2); line-height:1.8; margin:0 0 20px; }
.pd-ctas{ display:flex; gap:12px; flex-wrap:wrap; }
.pd-ctas .btn{ width:auto; padding:13px 22px; font-size:14px; gap:9px; }
.btn--fill{ background:var(--accent); border-color:var(--accent); color:#fff; }
.btn--fill:hover{ background:var(--ink); border-color:var(--ink); }
.pd-hero__shot .thumb,
.pd-hero__shot .placeholder{ border-radius:10px; overflow:hidden; }
.pd-intro{ font-size:14px; color:var(--ink-2); line-height:1.9; max-width:60em; margin:14px 0 0; }

/* セクション見出しの上余白(詳細ページ) */
.single-product .sw-seclabel{ margin-top:48px; }

/* FEATURES */
.pd-feats{ display:grid; grid-template-columns:repeat(3,1fr); gap:16px; }
.pd-feat{ border:1px solid var(--line); border-radius:10px; padding:20px; }
.pd-feat__ic{ width:40px; height:40px; border-radius:9px; background:#fff3ec; color:var(--accent); display:flex; align-items:center; justify-content:center; margin-bottom:12px; }
.pd-feat__ic i{ font-size:20px; }
.pd-feat h4{ font-size:15px; margin:0 0 6px; }
.pd-feat p{ font-size:12.5px; color:var(--ink-2); line-height:1.7; margin:0; }

/* DEMO */
.pd-video{ aspect-ratio:16/9; border-radius:10px; overflow:hidden; background:var(--ink); }
.pd-video iframe{ width:100%; height:100%; border:0; display:block; }

/* SPEC + 価格 */
.pd-two{ display:grid; grid-template-columns:1fr 1fr; gap:24px; align-items:start; }
.pd-spec{ border:1px solid var(--line); border-radius:10px; overflow:hidden; margin:0; }
.pd-spec .row{ display:flex; justify-content:space-between; gap:14px; padding:12px 16px; font-size:13px; border-bottom:1px solid var(--line); }
.pd-spec .row:last-child{ border-bottom:0; }
.pd-spec dt{ color:var(--ink-3); }
.pd-spec dd{ font-weight:700; margin:0; text-align:right; }
.pd-price{ border:1px solid var(--line); border-radius:10px; padding:20px; }
.pd-price .amt{ font-family:var(--ff-en); font-size:30px; font-weight:800; margin:0; }
.pd-price .amt small{ font-family:var(--ff-jp); font-size:13px; color:var(--ink-2); font-weight:400; }
.pd-price .links{ display:flex; flex-direction:column; gap:8px; margin-top:14px; }
.pd-price .links a{ display:flex; align-items:center; gap:9px; font-size:13px; color:var(--ink); text-decoration:none; border:1px solid var(--line); border-radius:8px; padding:10px 13px; transition:border-color .2s ease; }
.pd-price .links a:hover{ border-color:var(--accent); color:var(--accent); }
.pd-price .links a i{ font-size:16px; color:var(--accent); }

/* CHANGELOG */
.pd-log{ border-left:2px solid var(--line); padding-left:20px; }
.pd-log .v{ position:relative; margin-bottom:16px; }
.pd-log .v::before{ content:""; position:absolute; left:-25px; top:6px; width:9px; height:9px; border-radius:50%; background:var(--accent); }
.pd-log .vt{ font-family:var(--ff-en); font-weight:700; font-size:14px; margin:0; }
.pd-log .vt .d{ font-size:12px; color:var(--ink-3); font-weight:400; margin-left:8px; }
.pd-log .vd{ font-size:13px; color:var(--ink-2); margin:4px 0 0; }

/* FAQ */
.pd-faq .q{ border:1px solid var(--line); border-radius:8px; padding:14px 18px; margin-bottom:10px; }
.pd-faq .qt{ font-size:14px; font-weight:700; margin:0; }
.pd-faq .qa{ font-size:13px; color:var(--ink-2); margin:8px 0 0; }

@media (max-width: 900px){
  .pd-grid{ grid-template-columns:1fr; }
  .pd-hero{ grid-template-columns:1fr; gap:22px; }
  .pd-hero__shot{ order:-1; }
  .pd-feats{ grid-template-columns:1fr 1fr; }
  .pd-two{ grid-template-columns:1fr; }
}
@media (max-width: 560px){
  .pd-feats{ grid-template-columns:1fr; }
}

/* ============================================================
   NEWS  -  TOPページのお知らせ欄
   ============================================================ */
.news{
  padding:22px 0;
  display:grid;
  grid-template-columns:96px 1fr;
  gap:0 20px;
  align-items:center;   /* NEWSラベルを一覧に対して天地中央に */
  border-top:1px solid var(--line);
  border-bottom:1px solid var(--line);
  margin-top:8px;
}
.news__label{
  font-family:var(--ff-en);
  font-weight:800;
  font-size:13px;
  line-height:1.6;
  letter-spacing:.12em;
  color:var(--ink);
  margin:0;
  padding:0 0 0 14px;
  position:relative;
  display:flex;
  align-items:center;
}
.news__label::before{
  content:"";
  position:absolute;
  left:0; top:50%;
  transform:translateY(-50%);
  width:7px; height:7px;
  border-radius:50%;
  background:var(--accent);
}
.news__list{ margin:0; width:100%; }
.news__item{ border-bottom:1px dashed var(--line); }
.news__item:last-child{ border-bottom:0; }

.news__item > *,
.news__link{
  display:flex;
  align-items:center;
  gap:14px;
  padding:10px 2px;
  min-height:41px;
}
.news__link{ transition:color .2s ease; }
.news__link:hover{ color:var(--accent); }
.news__link .arw{ margin-left:auto; flex:none; transition:transform .2s ease; }
.news__link:hover .arw{ transform:translateX(4px); }

.news__date{
  font-family:var(--ff-en);
  font-weight:700;
  font-size:12px;
  line-height:1;
  color:var(--ink-3);
  white-space:nowrap;
  flex:none;
}
.news__tag{
  font-family:var(--ff-en);
  font-weight:800;
  font-size:10px;
  letter-spacing:.08em;
  line-height:1;
  padding:5px 8px;
  border:1px solid var(--line);
  color:var(--ink-3);
  white-space:nowrap;
  flex:none;
}
.news__tag--update,
.news__tag--works{ border-color:var(--accent); color:var(--accent); }
.news__tag--product{ border-color:var(--free); color:var(--free); }

.news__text{
  font-size:13px;
  font-weight:700;
  color:var(--ink-2);
  line-height:1.6;
}
.news__link:hover .news__text{ color:var(--accent); }

/* ---- rotator : 1件ずつスロット風に切り替える ---- */
.news__list.is-rotator{
  position:relative;
  perspective:900px;
  overflow:hidden;   /* 高さはJSが「いちばん高い項目」に固定する */
}
.news__list.is-rotator > .news__item{
  position:absolute;
  top:0; left:0;
  width:100%;
  height:100%;       /* 枠いっぱいに広げ、中身を天地中央に */
  border-bottom:0;
  opacity:0;
  pointer-events:none;
  transform-origin:50% 0%;
  transform:rotateX(-88deg) translateY(-30%);
  transition:opacity .38s ease, transform .6s cubic-bezier(.22,.61,.36,1);
  will-change:transform, opacity;
}
.news__list.is-rotator > .news__item.is-active{
  opacity:1;
  pointer-events:auto;
  transform:rotateX(0) translateY(0);
}
.news__list.is-rotator > .news__item.is-leaving{
  opacity:0;
  transform-origin:50% 100%;
  transform:rotateX(88deg) translateY(30%);
}
.news__list.is-rotator > .news__item > *,
.news__list.is-rotator > .news__item .news__link{
  height:100%;
  min-height:0;
}

@media (prefers-reduced-motion: reduce){
  .news__list.is-rotator{ transition:none; }
  .news__list.is-rotator > .news__item{
    transition:opacity .2s ease;
    transform:none;
  }
  .news__list.is-rotator > .news__item.is-leaving{ transform:none; }
}

@media (max-width:900px){
  .news{ grid-template-columns:1fr; gap:0; }
  .news__label{ margin-bottom:6px; }
  .news__item > *,
  .news__link{ flex-wrap:wrap; gap:8px 10px; padding:12px 2px; min-height:0; }
  .news__label{ padding:0 0 6px 14px; }
  .news__text{ flex-basis:100%; }
  .news__link .arw{ display:none; }
}

/* ============================================================
   404
   ============================================================ */
.err{
  min-height:clamp(520px, 78vh, 900px);
  display:flex;
  flex-direction:column;
  align-items:center;
  justify-content:center;
  text-align:center;
  padding:40px 0 64px;
}
.err__code{
  font-family:var(--ff-en);
  font-weight:500;
  font-size:clamp(140px, 27vw, 420px);
  line-height:.9;
  letter-spacing:.02em;
  color:var(--accent);
  margin:0 0 clamp(24px,4vw,56px);
  user-select:none;
}
.err__title{
  font-family:var(--ff-en);
  font-weight:800;
  font-size:clamp(28px,4vw,52px);
  line-height:1.2;
  letter-spacing:.01em;
  margin:0 0 18px;
  color:var(--ink);
}
.err__text{
  font-size:15px;
  font-weight:700;
  line-height:2;
  color:var(--ink-2);
  margin:0 0 clamp(28px,4vw,48px);
  max-width:34em;
}
.err__btn{
  width:auto;
  min-width:300px;
}

/* 右下のキャラクター(気まずい反応) */
.err{ position:relative; }
.err__mascot{
  position:fixed;       /* 画面の下端に付け、右は少し余白をとる */
  right:clamp(16px, 4vw, 72px);
  bottom:0;
  width:clamp(80px, 7.5vw, 116px);
  margin:0;
  pointer-events:none;
  user-select:none;
  z-index:1;            /* サイドバー(z-index:100)より下 */
}
.err__mascot img{ margin-bottom:-1px; }   /* 画面下端との隙間をなくす */
.err__mascot img{
  width:100%;
  height:auto;
  display:block;
}

@media (max-width:900px){
  .err__mascot{ width:clamp(76px, 13vw, 100px); }
}
@media (max-width:600px){
  .err{ min-height:70vh; padding:24px 0 40px; }
  .err__text{ font-size:14px; }
  .err__btn{ width:100%; min-width:0; }
  .err__mascot{ width:84px; right:12px; bottom:0; opacity:.9; }
}

/* ============================================================
   LIGHTBOX  -  画像クリックで拡大表示
   ============================================================ */
.is-zoomable{ cursor:zoom-in; }
.zoom-frame{ cursor:zoom-in; }   /* 枠全体がクリック対象 */

/* 画像だけを包む枠。中の画像を拡大し、はみ出しは枠で切る。
   キャプションは枠の外にあるので、拡大しても隠れない。 */
.zoom-frame{
  position:relative;
  display:inline-block;
  max-width:100%;
  vertical-align:top;
  line-height:0;            /* インライン要素の下にできる余白を消す */
  overflow:hidden;
  border-radius:10px;
  isolation:isolate;
  transition:box-shadow .35s ease;
}
.zoom-frame .is-zoomable{
  margin:0;                       /* 余白は figure 側が持つ(枠内で二重にしない) */
  display:block;
  transition:transform .55s cubic-bezier(.22,.61,.36,1);
  /* width / height / border-radius は元のままにする。
     指定すると縦横比の決まった画像(アイキャッチ等)が崩れる。 */
}
.zoom-frame:hover{ box-shadow:0 14px 32px rgba(26,26,26,.16); }
/* 拡大中だけ合成レイヤーに載せる(常時載せると画像の枚数だけメモリを使うため) */
.zoom-frame:hover .is-zoomable{ will-change:transform; }
.zoom-frame:hover .is-zoomable{ transform:scale(1.055); }

/* 右下に出る「＋」バッジ(クリックで拡大できることの合図) */
.zoom-frame::after{
  content:"";
  position:absolute;
  right:12px; bottom:12px;
  width:34px; height:34px;
  border-radius:50%;
  background:
    linear-gradient(#fff,#fff) center/13px 1.6px no-repeat,
    linear-gradient(#fff,#fff) center/1.6px 13px no-repeat,
    var(--accent);
  box-shadow:0 4px 12px rgba(26,26,26,.28);
  opacity:0;
  transform:translateY(8px) scale(.88);
  transition:opacity .3s ease, transform .3s cubic-bezier(.22,.61,.36,1);
  pointer-events:none;
  z-index:2;
}
.zoom-frame:hover::after{ opacity:1; transform:none; }

/* キーボード操作(Tabキー)で選んだときだけ枠を出す。
   マウスのクリックでは出さない ＝ :focus ではなく :focus-visible を使う。 */
.zoom-frame:focus{ outline:none; }
.zoom-frame:focus-visible{
  outline:3px solid var(--accent);
  outline-offset:-3px;   /* 枠の内側に描いて overflow:hidden で切られないように */
}

/* タッチ端末はホバーが無いので、バッジを常時うっすら出す */
@media (hover:none){
  .zoom-frame::after{ opacity:.85; transform:none; }
  .zoom-frame:hover .is-zoomable{ transform:none; }
  .zoom-frame:hover{ box-shadow:none; }
}

@media (prefers-reduced-motion: reduce){
  .zoom-frame .is-zoomable,
  .zoom-frame,
  .zoom-frame::after{ transition:none; }
  .zoom-frame:hover .is-zoomable{ transform:none; }
}

body.lb-open{ overflow:hidden; }

.lb{
  position:fixed;
  inset:0;
  z-index:9999;
  display:flex;
  align-items:center;
  justify-content:center;
  padding:clamp(16px,4vw,56px);
  background:rgba(22,22,24,.9);
  opacity:0;
  transition:opacity .2s ease;
}
.lb.is-open{ opacity:1; }
.lb[hidden]{ display:none !important; }

.lb__stage{
  margin:0;
  max-width:100%;
  max-height:100%;
  display:flex;
  flex-direction:column;
  align-items:center;
  justify-content:center;
  gap:14px;
}
.lb__img{
  max-width:min(1200px, 92vw);
  max-height:82vh;
  width:auto;
  height:auto;
  display:block;
  border-radius:6px;
  background:#fff;
  box-shadow:0 24px 60px rgba(0,0,0,.45);
  transform:scale(.97);
  transition:transform .22s cubic-bezier(.22,.61,.36,1);
}
.lb.is-open .lb__img{ transform:scale(1); }

.lb__cap{
  margin:0;
  max-width:60ch;
  text-align:center;
  font-size:12.5px;
  line-height:1.7;
  color:rgba(255,255,255,.78);
}

.lb__close,
.lb__nav{
  position:absolute;
  border:0;
  background:rgba(255,255,255,.1);
  color:#fff;
  cursor:pointer;
  display:flex;
  align-items:center;
  justify-content:center;
  border-radius:50%;
  transition:background .18s ease;
  font-family:var(--ff-en, sans-serif);
  line-height:1;
}
.lb__close:hover,
.lb__nav:hover{ background:var(--accent); }
.lb__close:focus-visible,
.lb__nav:focus-visible{ outline:2px solid var(--accent); outline-offset:3px; }

.lb__close{
  top:clamp(10px,2.5vw,26px);
  right:clamp(10px,2.5vw,26px);
  width:44px; height:44px;
  font-size:26px;
  padding-bottom:3px;
}
.lb__nav{
  top:50%;
  transform:translateY(-50%);
  width:46px; height:46px;
  font-size:30px;
  padding-bottom:4px;
}
.lb__nav--prev{ left:clamp(8px,2vw,26px); }
.lb__nav--next{ right:clamp(8px,2vw,26px); }
.lb__nav[hidden]{ display:none; }

@media (max-width:600px){
  .lb{ padding:12px; }
  .lb__img{ max-height:72vh; }
  .lb__nav{ width:40px; height:40px; font-size:26px; }
  .lb__nav--prev{ left:4px; }
  .lb__nav--next{ right:4px; }
}

@media (prefers-reduced-motion: reduce){
  .lb, .lb__img{ transition:none; }
  .lb__img{ transform:none; }
}

/* ===== WORKS 本文のギャラリー：均一グリッド（最終行が引き伸ばされないように） ===== */
.work-process .wp-block-gallery.has-nested-images{ display:grid !important; grid-template-columns:repeat(2,minmax(0,1fr)); gap:10px; margin:12px 0 24px; }
.work-process .wp-block-gallery.has-nested-images.columns-3{ grid-template-columns:repeat(3,minmax(0,1fr)); }
.work-process .wp-block-gallery.has-nested-images.columns-4{ grid-template-columns:repeat(4,minmax(0,1fr)); }
.work-process .wp-block-gallery.has-nested-images figure.wp-block-image{ width:auto !important; max-width:none; margin:0 !important; flex:none !important; display:flex; flex-direction:column; }
.work-process .wp-block-gallery.has-nested-images figure.wp-block-image img{ width:100% !important; height:auto !important; aspect-ratio:4/3; object-fit:contain; background:#f3f2ef; margin:0 !important; border-radius:8px; }
.work-process .wp-block-gallery.has-nested-images.is-square figure.wp-block-image img{ aspect-ratio:1/1; object-fit:cover; background:none; }
.work-process .wp-block-gallery.has-nested-images figure.wp-block-image figcaption{ position:static !important; background:none !important; color:var(--ink-3) !important; font-size:11px; line-height:1.5; padding:5px 0 0 !important; margin:0 !important; max-height:none !important; overflow:visible !important; text-align:center; text-shadow:none !important; }
@media (max-width:600px){
	.work-process .wp-block-gallery.has-nested-images.columns-3,
	.work-process .wp-block-gallery.has-nested-images.columns-4{ grid-template-columns:repeat(2,minmax(0,1fr)); }
}
/* WP標準の is-cropped 指定（:not(#individual-image) 付きで強い）を上書き */
.work-process .wp-block-gallery.has-nested-images figure.wp-block-image:not(#individual-image) img{ flex:none !important; height:auto !important; width:100% !important; aspect-ratio:4/3; object-fit:contain; }
.work-process .wp-block-gallery.has-nested-images.is-square figure.wp-block-image:not(#individual-image) img{ aspect-ratio:1/1; object-fit:cover; }
.work-process .wp-block-gallery.has-nested-images figure.wp-block-image:not(#individual-image){ width:auto !important; flex:none !important; }
/* ギャラリー内の拡大表示の枠（zoom-frame）も画像と同じ大きさに */
.work-process .wp-block-gallery.has-nested-images figure.wp-block-image:not(#individual-image) .zoom-frame{ display:block !important; width:100% !important; height:auto !important; flex:none !important; border-radius:8px; }
.work-process .wp-block-gallery.has-nested-images figure.wp-block-image:not(#individual-image){ height:auto !important; justify-content:flex-start; }
/* 縦長ポスターなど、元の縦横比のまま並べたいギャラリー */
.work-process .wp-block-gallery.has-nested-images.is-natural figure.wp-block-image:not(#individual-image) img{ aspect-ratio:5/7; object-fit:cover; background:none; }
