@charset "UTF-8";

/* ===========================
  基本設定（デザイントークン）
=========================== */
:root{
  /* 色 */
  --c-text:#082b48;
  --c-text-sub:#365975;
  --c-link:#0a78d1;
  --c-border:#e5eaf0;
  --c-key:#111111;
  --c-bg:#ffffff;
  --c-bg-mute:#f5f7fa;
  --c-footer:#06477d;

  /* 余白スケール（8pxベース） */
  --sp-0:0;
  --sp-1:0.25rem;  /* 4px */
  --sp-2:0.5rem;   /* 8px */
  --sp-3:0.75rem;  /* 12px */
  --sp-4:1rem;     /* 16px */
  --sp-5:1.5rem;   /* 24px */
  --sp-6:2rem;     /* 32px */
  --sp-7:2.5rem;   /* 40px */
  --sp-8:3rem;     /* 48px */
  --sp-9:4rem;     /* 64px */

  /* レイアウト */
  --container:980px;
  --radius:16px;
  --shadow:0 6px 20px rgba(0,0,0,.06);

  /* タイポ */
  --fz-12:.75rem;
  --fz-14:.875rem;
  --fz-16:1rem;
  --fz-18:1.125rem;
  --fz-20:1.25rem;
  --fz-24:1.5rem;
  --fz-28:1.75rem;
  --fz-32:2rem;
  --fz-40:2.5rem;
  --fz-56:3.5rem;
}

/* ユーザー設定 */
html{scroll-behavior:smooth;}
@media (prefers-reduced-motion: reduce){
  html{scroll-behavior:auto;}
}

/* ベース */
*,
*::before,
*::after{box-sizing:border-box;}

body{
  color:var(--c-text);
  font-family:system-ui,-apple-system,Segoe UI,Roboto,Ubuntu,Cantarell,Noto Sans,Helvetica,Arial,"Apple Color Emoji","Segoe UI Emoji","Segoe UI Symbol", Verdana, Geneva, Tahoma, sans-serif;
  line-height:1.7;
  background:var(--c-bg);
  -webkit-text-size-adjust:100%;
  text-rendering:optimizeLegibility;
}

img{display:block; max-width:100%; height:auto;}

/* リンク */
a{
  color:var(--c-text);
  text-decoration:none;
  transition:opacity .2s ease;
}
a:hover{opacity:.75;}
a:focus-visible{outline:2px solid #222; outline-offset:2px;}

/* コンテナ */
.container{
  width:90%;
  max-width:var(--container);
  margin-inline:auto;
}

/* ユーティリティ */
.clear::after{content:""; display:block; clear:both;} /* 互換維持用 */
.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;}

/* ===========================
  ボタン
=========================== */
.btn{
  display:inline-block;
  padding:calc(var(--sp-3) + 2px) var(--sp-5);
  border-radius:9999px;
  border:1px solid var(--c-key);
  font-weight:600;
  line-height:1;
  transition:transform .08s ease, opacity .2s ease;
  will-change:transform;
}
.btn:hover{transform:translateY(-1px);}
.btn--primary{background:var(--c-key); color:#fff;}
.btn--ghost{background:#fff; color:var(--c-key); margin-top: 5px;}

/* ===========================
  見出し/セクション共通
=========================== */
.section{padding-block:var(--sp-8);}
.section-title{
  font-size:var(--fz-32);
  font-weight:800;
  text-align:center;
  letter-spacing:.02em;
  margin-bottom:var(--sp-2);
}
.about-subtitle,
.service-subtitle,
.work-subtitle,
.contact-subtitle{
  text-align:center;
  color:var(--c-text-sub);
  margin-bottom:var(--sp-6);
  font-size:var(--fz-14);
  letter-spacing:.06em;
  text-transform:uppercase;
}

/* ===========================
  Header
=========================== */
header{
  padding-block:var(--sp-4);
  position:sticky;
  top:0;
  background:rgba(255,255,255,.95);
  backdrop-filter:saturate(180%) blur(6px);
  z-index:50;
  border-bottom:1px solid #eef1f4;
}
.header-left,
.header-right{
  /* 旧float互換は残しつつ、Flexで上書き */
  float:none;
}
header .container{
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:var(--sp-4);
}
.header-title{
  font-size:var(--fz-28);
  font-weight:800;
  letter-spacing:.02em;
  display:inline-block;
}
.tagline{
  font-size:var(--fz-14);
  color:var(--c-text-sub);
  margin-top:2px;
}
.header-nav{
  display:flex;
  align-items:center;
  gap:var(--sp-5);
}
.header-nav-item{margin:0;}
.header-nav-item a{
  display:inline-block;
  padding:.25rem .25rem;
  font-weight:700;
  line-height:1.2;
}

/* ===========================
  Top（ヒーロー）
=========================== */
.top{
  background-image:url(../img/top.jpg);
  background-size:cover;
  background-position:center;
  width:100%;
  min-height:420px;
  display:flex;
  align-items:center;
}
.top-title{
  text-align:center;
  font-size:var(--fz-56);
  font-weight:800;
  letter-spacing:.02em;
  padding-top:var(--sp-1);
  text-shadow:0 2px 18px rgba(0,0,0,.15);
}
.top-subtitle{
  text-align:center;
  color: #fff;
  margin-top:var(--sp-3);
  font-size:var(--fz-18);
}
.top-container {
  text-align: center;
}

/* ===========================
  About
=========================== */
.about-left,
.about-right{
  float:none; /* 旧float無効化 */
}
#about .container{
  display:grid;
  grid-template-columns:1fr 1fr;
  gap:var(--sp-7);
  align-items:start;
}
.profile{
  font-size:var(--fz-12);
  font-weight:800;
  color:var(--c-text-sub);
  margin-bottom:var(--sp-2);
  letter-spacing:.08em;
  text-transform:uppercase;
}
.name{
  font-size:var(--fz-28);
  font-weight:800;
  margin-bottom:var(--sp-4);
}
.message{
  font-size:var(--fz-16);
  font-weight:600;
}
.message-sub{
  font-size:var(--fz-14);
  color:var(--c-text-sub);
  margin-top:var(--sp-3);
}

/* プロフィール画像の体裁 */
.about-left img{
  width:100%;
  max-width:480px;
  border-radius:var(--radius);
  box-shadow:var(--shadow);
}

/* ===========================
  Service
=========================== */
.service{background:var(--c-bg-mute);}
.service-wrapper{
  display:flex;
  justify-content:space-between;
  gap:var(--sp-5);
  flex-wrap:wrap;
}
.service-item{
  border:1px solid var(--c-border);
  border-radius:var(--radius);
  background:#fff;
  box-shadow:var(--shadow);
  width:calc(33.333% - var(--sp-5) * 2 / 3);
  overflow:hidden;
}
.service-item img{
  width:100%;
  height:200px;
  object-fit:cover;
}
.service-title{
  font-size:var(--fz-20);
  font-weight:800;
  text-align:center;
  margin:var(--sp-3) 0 var(--sp-2);
}
.service-comment{
  padding:0 var(--sp-4) var(--sp-4);
  font-size:var(--fz-14);
  color:var(--c-text);
}
.service-content {
  font-size:var(--fz-14);
  color:var(--c-text);
  margin-top: 15px;
}
.service-content p {
  margin-bottom: 10px;
}

/* ===========================
  Work
=========================== */
.work-wrapper{
  display:flex;
  justify-content:space-between;
  gap:var(--sp-5);
  flex-wrap:wrap;
}
.work-item{
  border:1px solid #edeff3;
  border-radius:var(--radius);
  background:#fff;
  box-shadow:var(--shadow);
  width:calc(50% - var(--sp-5) * 2 / 2);
  overflow:hidden;
}
.work-item img{
  width:100%;
  height:240px;
  object-fit:cover;
}
.work-title{
  font-size:var(--fz-20);
  text-align:center;
  padding:var(--sp-3) var(--sp-4) var(--sp-2);
  font-weight:800;
}
.work-meta{
  margin:0 var(--sp-4) var(--sp-3);
  padding-left:1.25rem;
  padding-right: 1.25rem;
  font-size:var(--fz-14);
}
.work-meta li{list-style:disc; margin-bottom: 10px;}
.work-comment{
  padding:0 var(--sp-4) var(--sp-4);
  text-align:center;
  color:var(--c-text-sub);
}
.work-link{
  text-align:center;
  padding:0 0 var(--sp-5);
}
.work-link a{
  color:var(--c-link);
}

.work-link__left {
  margin-top: 35px;
}

.work-link__right {
  margin-top: 59px;
}

/* ===========================
  Contact
=========================== */
.contact{background:var(--c-bg-mute);}
.contact-comment{
  text-align:center;
  margin-bottom:var(--sp-6);
  color:var(--c-text);
}
.contact-wrapper{
  display:flex;
  justify-content:center;
  align-items:center;
  gap:var(--sp-7);
  flex-wrap:wrap;
}
.contact-item{
  width:80px;
  height:80px;
}
.contact-item-x {
  margin-top: 29px;
}
.contact-x-img img{
  width:50px;
  height:50px;
}

.mail-btn,
.x-btn {
  text-align: center;
}

/* ===========================
  Footer
=========================== */
.footer{
  background-color:var(--c-footer);
  padding:var(--sp-3) 0;
  color:#fff;
  text-align: center;
}
.footer-title{
  text-align:center;
  color:#ffffff;
  font-size:var(--fz-14);
  opacity:.95;
}

/* ===========================
  レスポンシブ
=========================== */

/* ～1024pxで少し縮める */
@media (max-width:1024px){
  .top-title{font-size:var(--fz-40);}
}

/* ～767px：スマホ */
@media (max-width:767px){
  .clear::after{content:none;} /* 旧clearfixを無効化 */

  /* ヘッダー */
  header{padding-block:var(--sp-3);}
  header .container{flex-direction:column; align-items:flex-start; gap:var(--sp-2);}
  .header-title{font-size:var(--fz-24);}
  .header-nav{flex-wrap:wrap; gap:var(--sp-3);}

  /* ヒーロー */
  .top{min-height:380px;}
  .top-title{font-size:var(--fz-40); padding-top:var(--sp-6);}
  .top-subtitle{font-size:var(--fz-14); font-weight:700;}

  /* セクション共通 */
  .section{padding-block:var(--sp-9);}
  .section-title{font-size:var(--fz-32);}

  /* About */
  #about .container{grid-template-columns:1fr; gap:var(--sp-5);}
  .about-left{margin-bottom:var(--sp-3);}
  .name{font-size:var(--fz-24);}

  /* Service */
  .service-item{width:100%;}
  .service-item img{height:200px;}

  /* Work */
  .work-item{width:100%;}
  .work-item img{height:220px;}

  /* Footer */
  .footer-title{font-size:var(--fz-12);}
}

/* ～480px：極小幅 */
@media (max-width:480px){
  .top{min-height:340px;}
  .top-title{font-size:2rem;}
  .header-nav{gap:var(--sp-2);}
}

/* ===========================
  細かなアクセシビリティ
=========================== */
:focus:not(:focus-visible){outline:none;}
:focus-visible{outline:2px solid #222; outline-offset:2px;}

/* 画像の遅延読み込みのフォールバックっぽい演出（任意） */
img[loading="lazy"]{opacity:0; transition:opacity .2s ease;}
img[loading="lazy"].loaded{opacity:1;}


/* ===========================
  スクロール時のフェードイン
=========================== */
.js-fade{
  opacity:0;
  transform:translateY(20px);
  transition:opacity .5s ease, transform .5s ease;
}

.js-fade.is-visible{
  opacity:1;
  transform:translateY(0);
}


/* ===========================
  TOPへ戻る
=========================== */
#page-top {
  position: fixed;
  bottom: 70px;
  right: 40px;
  font-size: 30px;
  line-height: 1;
  z-index: 99;
  display: none;
}

#page-top a {
  background: #84dbee;
  text-decoration: none;
  padding: 15px;
  display: block;
  border-radius: 10px;
  transition: all 0.3s ease;
}

#page-top a:hover {
  text-decoration: none;
  opacity: 0.5;
}



@media (max-width:767px){
  #page-top {
    bottom: 20px;
    right: 20px;
  }
  #page-top a {
    width: 45px;
    height: 45px;
    font-size: 20px;
    padding: 13px 12px;
  }
}



/* ヘッダー行を基準にボタン位置決め */
.header-bar{ position:relative; }

/* PC：通常表示、トグルは非表示 */
@media (min-width:768px){
  #globalNav{ display:block; }
  .nav-toggle{ display:none; }
  .nav-overlay{ display:none !important; }
}

/* SP：右上に固定、ドロワー＋オーバーレイ */
@media (max-width:767px){
  .tagline{ display:none; }

  .nav-toggle{
    position:absolute;
    right:0;
    display:inline-flex;
    flex-direction:column;
    justify-content:center;
    align-items:center;
    gap:6px;
    width:44px; height:44px;
    border:1px solid #e5eaf0;
    border-radius:10px;
    background:#fff;
    z-index:101; /* オーバーレイより上 */
  }
  .nav-toggle:focus-visible{ outline:2px solid #222; outline-offset:2px; }

  .nav-toggle__bar{
    width:22px; height:2px;
    background:#111; display:block;
    transition:transform .2s ease, opacity .2s ease;
  }

  /* ❌に変形（開いているとき） */
  .nav-open .nav-toggle__bar:nth-child(1){ transform:translateY(8px) rotate(45deg); }
  .nav-open .nav-toggle__bar:nth-child(2){ opacity:0; }
  .nav-open .nav-toggle__bar:nth-child(3){ transform:translateY(-8px) rotate(-45deg); }

  /* ドロワーメニュー（ヘッダーの下にスライド表示） */
  #globalNav{
    position:fixed;
    inset:60px 0 auto 0;   /* ヘッダー直下から */
    background:#fff;
    border-bottom:1px solid #eef1f4;
    box-shadow:0 12px 24px rgba(0,0,0,.06);
    transform:translateY(-12px);
    opacity:0;
    pointer-events:none;
    transition:transform .18s ease, opacity .18s ease;
    z-index:100;
  }
  .nav-open #globalNav{
    transform:translateY(0);
    opacity:1;
    pointer-events:auto;
  }

  .header-nav{
    display:flex;
    flex-direction:column;
    gap:0;
    padding:8px 12px;
  }
  .header-nav-item{ margin:0; }
  .header-nav-item a{
    display:block;
    padding:14px 12px;
    border-radius:10px;
    font-weight:700;
  }
  .header-nav-item a:active{ background:#f5f7fa; }

  /* 省アニメ派対応 */
  @media (prefers-reduced-motion: reduce){
    .nav-toggle__bar{ transition:none; }
    #globalNav{ transition:none; }
    .js-fade{
      opacity:1 !important;
      transform:none !important;
      transition:none !important;
    }
  }
}
