/* Noto Sans JP — 400 / 500 / 700（japanese + latin サブセット同梱） */
@font-face {
  font-family: "Noto Sans JP";
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url("/fonts/noto-sans-jp-v56-japanese_latin-regular.woff2") format("woff2");
}
@font-face {
  font-family: "Noto Sans JP";
  font-style: normal;
  font-weight: 500;
  font-display: swap;
  src: url("/fonts/noto-sans-jp-v56-japanese_latin-500.woff2") format("woff2");
}
@font-face {
  font-family: "Noto Sans JP";
  font-style: normal;
  font-weight: 700;
  font-display: swap;
  src: url("/fonts/noto-sans-jp-v56-japanese_latin-700.woff2") format("woff2");
}

/* JetBrains Mono — 400 / 500 / 700 */
@font-face {
  font-family: "JetBrains Mono";
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url("/fonts/JetBrainsMono-Regular.woff2") format("woff2");
}
@font-face {
  font-family: "JetBrains Mono";
  font-style: normal;
  font-weight: 500;
  font-display: swap;
  src: url("/fonts/JetBrainsMono-Medium.woff2") format("woff2");
}
@font-face {
  font-family: "JetBrains Mono";
  font-style: normal;
  font-weight: 700;
  font-display: swap;
  src: url("/fonts/JetBrainsMono-Bold.woff2") format("woff2");
}
:root{
  --bg: #FFFFFF;
  --bg-sub: #F5F5F5;
  --bg-cta: #0F0F0F;
  --bg-footer: #F1F2F3;
  --bg-copy: #0B0D10;

  --text: #111111;
  --text-sub: #666666;
  --text-mute: #94A3B8;
  --text-copy: #64748B;

  --line: #E5E6E8;
  --line-strong: #D6D8DB;

  --accent: #E60023;
  --accent-hover: #C8001E;
  --accent-soft: #FDEEF1;

  --max: 1200px;
  --doc-max: 960px;
  --gutter: clamp(20px, 4vw, 40px);

  --fs-hero: clamp(32px, 5.2vw, 60px);
  --fs-h2: clamp(26px, 3.2vw, 36px);
  --fs-h3: 20px;
  --fs-body: 15px;
  --fs-small: 13px;

  --r: 6px;
  --r-lg: 10px;
}

*,*::before,*::after{ box-sizing: border-box; }
html,body{ margin:0; padding:0; }
body{
  font-family: "Noto Sans JP", "Hiragino Kaku Gothic ProN", "Yu Gothic", sans-serif;
  color: var(--text);
  background: var(--bg);
  font-size: var(--fs-body);
  line-height: 1.75;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}
a{ color: inherit; text-decoration: none; }
.mail-link{
  text-decoration: underline;
  text-decoration-thickness: 1px;
  text-underline-offset: 0.16em;
}
.mail-link[href^="mailto:"]:hover{
  color: var(--accent);
}
img{ display:block; max-width:100%; }
button{ font: inherit; cursor: pointer; }
.mono{ font-family: "JetBrains Mono", ui-monospace, monospace; letter-spacing: 0.02em; }

.container{
  max-width: var(--max);
  margin: 0 auto;
  padding-left: var(--gutter);
  padding-right: var(--gutter);
}

section{ padding: clamp(64px, 8vw, 96px) 0; }
.white{ background: var(--bg); }
.gray,
.section-sub{ background: var(--bg-sub); }
main.docs section{
  border-bottom: 1px solid var(--line);
}
main.docs section:last-of-type{ border-bottom: none; }

.sec-head{
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 20px;
  margin-bottom: 40px;
  flex-wrap: wrap;
}
.sec-lead{
  color: var(--text-sub);
  margin: 18px 0 0;
  font-size: 14.5px;
  line-height: 1.95;
}
.site-header{
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(255,255,255,0.92);
  backdrop-filter: saturate(180%) blur(8px);
  border-bottom: 1px solid var(--line);
}
.header-inner{
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 72px;
}
.brand{
  display: flex;
  align-items: center;
  gap: 10px;
  font-weight: 700;
  letter-spacing: 0.06em;
}
.brand-mark{
  display: block;
  width: 32px;
  height: 32px;
  flex-shrink: 0;
  object-fit: contain;
}
.brand-name{ font-size: 15px; }
.brand-name span{ color: var(--text-sub); font-weight: 500; margin-left: 6px; }

.nav{
  display: flex;
  align-items: center;
  gap: 32px;
}
.nav a{
  font-size: 14px;
  font-weight: 500;
  color: var(--text);
  padding: 8px 0;
  position: relative;
  transition: color .15s;
}
.nav a:hover{ color: var(--accent); }
.nav a.current{ color: var(--accent); }
.nav a.current::after{
  content:"";
  position: absolute;
  left: 0; right: 0; bottom: -1px;
  height: 2px;
  background: var(--accent);
}
.nav-cta{
  background: var(--accent);
  color: #fff !important;
  padding: 10px 20px !important;
  border-radius: var(--r);
  transition: background .15s;
}
.nav-cta:hover{ background: var(--accent-hover); color:#fff !important; }
.nav-cta.current::after{ display: none; }
.menu-btn{ display: none; border: 1px solid var(--line); background:#fff; width:40px; height:40px; border-radius: var(--r); }
.menu-btn-icon{ display:block; width:18px; height:18px; }

/* ===== レスポンシブ（≤ 767px） — nav ↔ ハンバーガーの切替 ===== */
@media (max-width: 767px){
  .nav{ display: none; }
  .menu-btn{ display: grid; place-items: center; width: 44px; height: 44px; }
  .header-inner{ height: 60px; }
}
.footer{
  background: var(--bg-footer);
  padding: 80px 0 0;
  border-top: 1px solid var(--line);
}
.footer-grid{
  display: grid;
  grid-template-columns: 1.6fr 1fr 1fr 1fr 1fr;
  gap: 40px;
  padding-bottom: 56px;
}
.footer-brand{
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 20px;
}
.footer-company{
  font-size: 17px;
  font-weight: 700;
  letter-spacing: 0.04em;
}
.footer-info{
  color: var(--text-sub);
  font-size: 13px;
  line-height: 1.9;
  margin: 0 0 20px;
}
.footer-info dt{
  font-family: "JetBrains Mono", monospace;
  font-size: 10.5px;
  letter-spacing: 0.12em;
  color: #9AA0A6;
  margin-top: 10px;
}
.footer-info dd{ margin: 0; color: var(--text); font-size: 13px; }
.footer h4{
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.06em;
  margin: 0 0 14px;
  padding-bottom: 10px;
  border-bottom: 1px solid var(--line-strong);
  color: var(--text);
}
.footer h4 a{
  color: inherit;
  transition: color .15s;
}
.footer h4 a:hover{ color: var(--accent); }
.footer-nav-col ul{ min-height: 1px; }
.footer-nav-col ul:empty{ display: none; }
.footer ul{
  list-style: none;
  padding: 0; margin: 0;
}
.footer ul li{
  margin-bottom: 10px;
}
.footer ul li a{
  font-size: 13px;
  color: var(--text);
  transition: color .15s;
}
.footer ul li a:hover{ color: var(--accent); }

.footer-copy{
  background: var(--bg-copy);
  color: var(--text-copy);
  padding: 20px 0;
  font-size: 12px;
}
.footer-copy .container{
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 12px;
}
.footer-copy .mono{ font-family: "JetBrains Mono", monospace; letter-spacing: 0.04em; }

/* ===== レスポンシブ（≤ 767px） — モック仕様：5列 → 1列の単一境界 ===== */
@media (max-width: 767px){
  .footer{ padding-top: 56px; }
  .footer-grid{ grid-template-columns: 1fr; gap: 32px; padding-bottom: 40px; }
  .footer-copy .container{ flex-direction: column; align-items: flex-start; gap: 6px; }
}
/* =========================================================
   ARTE SYSTEM — モバイルドロワー + 全画面共通SP最小ルール
   ※ コンポーネント固有の SP ルール(Header/Footer/CTA など)は
      それぞれの common/header.css, common/footer.css, common/cta.css に集約。
      ページ固有の SP ルールは pages/<page>/*.css に集約。
      理由：Vite/Astro の CSS 読込順序上、コンポーネント由来 CSS は BaseLayout
      の import より後に挿入され、common/responsive.css に置くと上書きされる。
   ========================================================= */

/* =========================================================
   モバイルドロワー本体（全幅共通・既定は非表示）
   ※ 開閉は素の <script>（バニラJS）。body.sp-menu-open をトグル。
   ========================================================= */
.sp-drawer-overlay{
  position: fixed; inset: 0; z-index: 90;
  background: rgba(11,13,16,0.46);
  opacity: 0; visibility: hidden;
  transition: opacity .3s ease, visibility .3s ease;
}
.sp-drawer-panel{
  position: fixed; top: 0; right: 0; bottom: 0; z-index: 91;
  width: min(80%, 320px); background: #fff;
  transform: translateX(100%);
  transition: transform .32s cubic-bezier(.4,0,.2,1);
  display: flex; flex-direction: column;
}
body.sp-menu-open .sp-drawer-overlay{ opacity: 1; visibility: visible; }
body.sp-menu-open .sp-drawer-panel{
  transform: translateX(0);
  box-shadow: -16px 0 40px -18px rgba(15,23,42,0.45);
}
body.sp-menu-open{ overflow: hidden; }   /* 背面スクロールロック */

.sp-drawer-head{
  display: flex; align-items: center; justify-content: space-between;
  height: 60px; padding: 0 16px 0 20px; border-bottom: 1px solid var(--line);
}
.sp-drawer-head .label{
  font-family: "JetBrains Mono", monospace;
  font-size: 11px; letter-spacing: 0.2em; color: var(--text-sub);
}
.sp-drawer-close{
  border: none; background: transparent; width: 44px; height: 44px;
  display: grid; place-items: center; color: var(--text);
}
.sp-drawer-close svg{ width: 18px; height: 18px; }
.sp-drawer-nav{ display: flex; flex-direction: column; padding: 8px 0; flex: 1 1 auto; }
.sp-drawer-nav a{
  display: flex; align-items: center; justify-content: space-between;
  min-height: 54px; padding: 0 20px; font-size: 15px; font-weight: 500;
  color: var(--text); border-bottom: 1px solid var(--line);
}
.sp-drawer-nav a .en{
  font-family: "JetBrains Mono", monospace;
  font-size: 10px; letter-spacing: 0.12em; color: var(--text-mute);
}
.sp-drawer-nav a:active{ background: var(--bg-sub); }
.sp-drawer-cta-wrap{ padding: 18px 20px 24px; margin-top: auto; }
.sp-drawer-cta{
  display: flex; align-items: center; justify-content: center;
  min-height: 52px; background: var(--accent); color: #fff;
  font-weight: 700; font-size: 15px; border-radius: var(--r); letter-spacing: 0.04em;
}
.sp-drawer-cta:active{ background: var(--accent-hover); }

/* デスクトップではドロワーを完全に無効化（万一 class が付いても出さない） */
@media (min-width: 768px){
  .sp-drawer-overlay, .sp-drawer-panel{ display: none !important; }
  body.sp-menu-open{ overflow: auto; }
}

/* =========================================================
   ≤767px：全画面共通の最小ルールのみ
   ========================================================= */
@media (max-width: 767px){
  /* フォーム入力：iOS自動ズーム抑止（16px以上） */
  main input, main textarea, main select{ font-size: 16px; }
}
