/* stak.tech サイト共通 CSS（ブログ系ページ用ベース） */

:root {
  --bg: #08080C;
  --surface: #191923;
  --surface-soft: rgba(255, 255, 255, .025);
  --line: rgba(255, 255, 255, .08);
  --line-soft: rgba(255, 255, 255, .04);
  --line-strong: rgba(255, 255, 255, .18);
  --ink: #FFFFFF;
  --ink-soft: #A8A8B8;
  --ink-mute: #6A6A7A;
  --ink-warm: #F5EFE6;
  --c-blue: #0066FF;
  --c-cyan: #00D4FF;
  --c-purple: #8B5CF6;
  --c-pink: #EC4899;
  --c-amber: #F59E0B;
  --accent: #00D4FF;
  --glow: rgba(0, 212, 255, .35);
  --f-en: 'Inter', system-ui, sans-serif;
  --f-jp: 'Noto Sans JP', sans-serif;
  --f-mono: 'JetBrains Mono', monospace;
  --f-serif: 'Instrument Serif', serif;
  --ease: cubic-bezier(.22, .7, .18, 1);
  --container: 1320px;
}

*, *::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(--f-jp);
  font-size: 16px;
  line-height: 1.7;
  font-feature-settings: "palt";
  text-rendering: optimizeLegibility;
}
img { max-width: 100%; height: auto; display: block; }
a { color: var(--c-cyan); text-decoration: none; transition: opacity .2s; }
a:hover { opacity: .8; }

/* ───── Header（TOP と統一・白背景） ───── */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 1rem 2rem;
  background: rgba(255, 255, 255, .96);
  backdrop-filter: blur(24px) saturate(140%);
  -webkit-backdrop-filter: blur(24px) saturate(140%);
  border-bottom: 1px solid rgba(0, 0, 0, .06);
}
/* ブランドロゴ（TOP と完全統一） */
.site-header .brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  line-height: 0;
}
.site-header .brand img {
  height: 22px;
  width: auto;
  display: block;
}
/* 旧テキストロゴ（互換のため残置・新規ページからは使わない） */
.site-header .logo {
  font-family: var(--f-en);
  font-weight: 900;
  font-size: 1.6rem;
  letter-spacing: -.04em;
  color: var(--ink);
  position: relative;
  padding-right: 8px;
}
.site-header .logo::after {
  content: ".";
  color: var(--c-cyan);
  font-size: 2rem;
  line-height: 1;
  margin-left: 2px;
}
.site-header nav {
  display: flex;
  gap: 1.5rem;
}
.site-header nav a {
  /* 白背景に合わせて黒系ベース */
  color: #1a1a1a;
  font-size: .9rem;
  font-weight: 500;
  font-family: var(--f-jp);
  letter-spacing: .05em;
}
.site-header nav a:hover { color: #0066FF; opacity: 1; }

/* ───── Footer ───── */
.site-footer {
  border-top: 1px solid var(--line);
  padding: 3rem 2rem;
  text-align: center;
  color: var(--ink-mute);
  font-size: .85rem;
}

/* ───── Responsive ───── */
/* 5/25 朝シン指摘: モバイルでヘッダーが詰まってタップしにくい問題
 *   → ロゴ上段 + メニュー下段の2段構成にし、各項目に44px+のタップエリアを確保
 */
@media (max-width: 768px) {
  .site-header {
    padding: 0.75rem 1rem 0;
    flex-wrap: wrap;
    gap: 0.5rem;
  }
  .site-header .brand {
    flex: 0 0 auto;
    margin: 0 auto 0 0;
  }
  .site-header nav {
    width: 100%;
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    gap: 0;
    border-top: 1px solid rgba(0, 0, 0, .06);
    margin-top: 0.5rem;
  }
  .site-header nav a {
    padding: 0.85rem 0.25rem;
    font-size: 0.82rem;
    font-weight: 600;
    letter-spacing: 0;
    text-align: center;
    min-height: 44px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-right: 1px solid rgba(0, 0, 0, .04);
    transition: background .2s, color .2s;
  }
  .site-header nav a:last-child { border-right: none; }
  .site-header nav a:active {
    background: rgba(0, 102, 255, 0.08);
    color: #0066FF;
    opacity: 1;
  }
}
@media (max-width: 380px) {
  .site-header nav a {
    font-size: 0.75rem;
    padding: 0.85rem 0.1rem;
  }
}
