/* index.css */

/* ========================================
   Base
   ======================================== */
* { box-sizing: border-box; }
html, body { height: 100%; }

body{
  margin: 0;
  font-family: "acumin-pro", sans-serif;
  font-weight: 400;
  font-style: normal;
  background: #f7f7f5;
  color: #111;
}


/* ========================================
   Layout
   ======================================== */
.layout{
  min-height: 100svh;
  display: grid;
  grid-template-columns: 1fr;
}

.main{
  padding: 0 8px 8px;
}

/* PCだけ：ギャラリー上に余白 */
@media (min-width: 861px){
  .hero-portfolio{
    margin-top: 8px;
  }
}

/* PCだけ：サイドnav分だけ main を右に逃がす */
@media (min-width: 861px){
  .main{
    padding-left: calc(180px + 24px);
    transition: padding-left 0.25s ease;
  }
}












/* ========================================
   NAV (side / top responsive)
   ======================================== */
.nav{
  transition: opacity 0.3s ease;
  will-change: opacity;
}

.nav.is-faded{
  opacity: 0;
  pointer-events: none;
}

.nav-inner{ padding: 24px 18px; }

.nav-top{
  display: flex;
  align-items: flex-start;
}

.brand{
  display: inline-block;
  text-decoration: none;
  color: #111;
  font-size: 0.7rem;
  line-height: 0.5;
  letter-spacing: 0.02em;
}

.brand-sub{
  font-size: 0.7rem;
  line-height: 3;
  letter-spacing: 0.02em;
  color: #111;
  text-decoration: none;
}

.nav-menu{
  margin-top: 15px;
  display: flex;
  flex-direction: column;
}

.nav-link{
  display: inline-block;
  text-decoration: none;
  color: #111;
  font-size: 0.7rem;
  padding: 2.5px 0;
  opacity: 0.85;
}



.nav-link:hover{ opacity: 1; }

.nav-link.is-active,
.nav-link[aria-current="page"]{
  text-decoration: underline;
  opacity: 1;
}


@media (max-width: 376px){
.brand,
.brand-sub,
.nav-menu,
.nav-link
{
  font-size: 0.6rem;
}
}


@media (min-width: 861px){
  .nav{
    position: fixed;
    left: 0;
    top: 0;
    width: 180px;
    height: 100svh;
    z-index: 1000;
  }

  .nav-inner{
    height: 100svh;
    overflow: auto;
  }

  .nav-top{
    flex-direction: column;
    align-items: flex-start;
  }

  .nav-menu .nav-link:last-child{
   margin-top: 15px; 
  }
}

@media (max-width: 860px){
  .nav{
    position: sticky;
    top: 0;
    z-index: 1000;
  }

  .nav-inner{
    display: flex;
    flex-wrap: wrap;           /* ← これで「崩れる幅」を吸収 */
    align-items: flex-start;   /* ← line-height問題の見た目も安定 */
    justify-content: space-between;
    gap: 10px 14px;
    padding: 14px 16px;
  }
   
  .nav-top{
    display: flex;
    flex-direction: column;    /* ← brand を2行で安定表示 */
    align-items: flex-start;
    gap: 2px;
    min-width: 140px;          /* ← 左カラムの最低幅（好みで調整） */
  }

    .brand{
    line-height: 1.15;         /* ← 0.5 をモバイルだけ正常化 */
  }

  .brand-sub{
    line-height: 1.15;         /* ← 3 をモバイルだけ正常化 */
  }

  .nav-menu{
    margin: 0;
    padding: 0;
    border: 0;
    display: flex;
    flex-direction: row;
    flex-wrap: wrap;           /* ← 右側は必要なら2段になる */
    justify-content: flex-end; /* ← 右寄せ */
    align-items: center;
    gap: 6px 10px;
    margin-left: auto;
    max-width: 60vw;           /* ← 右側が長い時の安全弁 */
  }

    .nav-link{
    white-space: nowrap;       /* ← “selected works” を途中で折らない */
  }
 
}


@media (max-width: 420px){
  .nav-link{ font-size: 0.62rem; }
  .brand, .brand-sub{ font-size: 0.62rem; }
  .nav-menu{ gap: 6px 8px; max-width: 64vw; }
}


@media (min-width: 390px) and (max-width: 430px){
  .nav-inner{
    flex-wrap: nowrap;
  }

  .nav-menu{
    flex-wrap: nowrap;
    max-width: none;
    gap: 0 8px;
  }

  .nav-link{
    font-size: 0.62rem;
  }
}











/* ========================================
   Info page
   ======================================== */
.info-page{
  position: fixed;
  inset: 0;
  background: #f7f7f5;
  display: none;
  z-index: 1200;
}
body.info-open .info-page{ display: block; }
body.info-open{ overflow: hidden; }

.info-page__inner{
  padding: 16px;
  line-height: 1.5;
  font-size: 0.6rem;
  font-weight: 500;
  letter-spacing: 0.06em;
}
.hp-label,
.hp-list,
.hp-note{ margin: 0 0 26px; }
.hp-copyright{
  margin-top: 60px;
  font-size: 0.6rem;
  font-weight: 100;
  letter-spacing: 0.06em;
}
.info-page a{ color: inherit; text-decoration: none; }
.info-page a:hover{ opacity: 0.75; }

.info-back{
  display: inline-block;
  margin-bottom: 32px;
  font-size: 0.6rem;
  letter-spacing: 0.06em;
  cursor: pointer;
}
.info-back:hover{ opacity: 0.7; }
















/* ========================================
   Real Masonry (Masonry lib)
   ======================================== */
.hero-portfolio{
  width: 100%;
  padding: 0 0 40px;
}

/* Real Masonry (Masonry lib) */
.masonry{
  width: 100%;
  max-width: 1200px; /* 必要なら消してOK。見た目安定用 */
  margin: 0 auto;
}

.grid-sizer,
.jl-item{
width: calc((100% - 10px) / 2); /* 2列 + gutter10px */
}

.jl-item video{
  width:100%;
  height:auto;
  display:block;
  object-fit:cover;
}

@media (max-width: 360px){
.grid-sizer,
.jl-item{
width: 100%;
}
}

@media (min-width: 1092px){
  .grid-sizer,
  .jl-item{
    width: calc((100% - 20px) / 3); /* 3列 + gutter10px x2 */
  }
}

.jl-item{ margin: 0 0 10px; }
.jl-item img{ width: 100%; height: auto; display: block; }




/* Masonry_js caption */
.jl-item{
  position: relative;
}

/* キャプション（中央テキスト） */
.jl-item .jl-caption{
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;

  text-align: center;
  padding: 0 14px;

  opacity: 0;
  transform: translateY(2px);
  transition: opacity 180ms ease, transform 180ms ease;
  pointer-events: none;

  z-index: 2;
}

.jl-cap-title{
  font-size: .7rem;
  letter-spacing: 0.14em;
  font-weight: 600;
  color: #111;

}

/* ========================================
   Masonry caption — mobile tuning
   ======================================== */
@media (max-width: 768px){
  .jl-cap-title{
    font-size: .6rem;
    letter-spacing: 0.12em;
  }

  .jl-caption{
    padding: 0 10px;
  }
}

@media (max-width: 480px){
  .jl-cap-title{
    font-size: .5rem;
  }
}



.jl-cap-line{
  margin-top: 6px;

  font-size: .7rem;
  letter-spacing: 0.14em;
  font-weight: 600;
  color: #111;

  opacity: .85;

  display:none;
}

/* フェード（画像を白っぽくする） */
.jl-item::after{
  content: "";
  position: absolute;
  inset: 0;

  background: rgba(255,255,255,0.55);

  opacity: 0;
  transition: opacity 180ms ease;
  pointer-events: none;

  z-index: 1;
}

/* PC: hover で表示 */
@media (hover:hover) and (pointer:fine){
  .jl-item:hover::after{ opacity: 1; }
  .jl-item:hover .jl-caption{
    opacity: 1;
    transform: translateY(0);
  }
}

/* Touch: 1回目タップで付くクラスで表示 */
.jl-item.is-caption-visible::after{ opacity: 1; }
.jl-item.is-caption-visible .jl-caption{
  opacity: 1;
  transform: translateY(0);
}

















/* =========================================
   LIGHTBOX (gm) — FULL BLOCK FROM styles.css
   ========================================= */

/* hidden state */
.gm[aria-hidden="true"] {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
}

/* modal root */
.gm {
  position: fixed;
  inset: 0;
  z-index: 9999;
  display: grid;
  place-items: center;
  --gm-footer-h: 120px;
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
}

@media (max-width: 767px){
  .gm{ --gm-footer-h: 140px; }
}

@media (orientation: portrait) and (hover: none) and (pointer: coarse) and (min-width:768px){
  .gm{ --gm-footer-h:180px; }
}

/* backdrop */
.gm-backdrop{
  position:absolute;
  inset:0;
  border:0;
  padding:0;
  margin:0;
  background:#f7F7F5;
}

/* hidden switching */
.gm-frame img[hidden],
.gm-video-wrap[hidden]{
  display:none !important;
}

/* frame */
.gm-frame{
  position:relative;
  width:98vw;
  height:calc(100svh - var(--gm-footer-h));
  display:flex;
  align-items:center;
  justify-content:center;
}

/* image */
.gm-frame img{
  max-width:100%;
  max-height:100%;
  object-fit:contain;
  user-select:none;
  -webkit-user-drag:none;
}

/* caption container */
.gm-caption{
  position:absolute;
  left:10px;
  bottom:10px;
  z-index:20;
  pointer-events:none;
  text-align:left;
  color:#000;
}



/* signature top-left */
.gm-name{
  position:fixed;
  top:8px;
  left:5px;
  z-index:10000;
  margin:0;
  pointer-events:none;
  line-height:0.5;
}

/* links */
.gm-main{ text-decoration:none; color:inherit; cursor:pointer; }
.gm-main:visited{ color:inherit; }

.gm-name .gm-main{
  font-size:.7rem;
  letter-spacing:0.05em;
  pointer-events:auto;
}

.gm-name .gm-subtitle{
  font-size:.7rem;
  letter-spacing:0.04em;
}

.gm-name .gm-main,
.gm-name .gm-subtitle{
  display:block;
}

/* caption text */
.gm-ttl{
  margin-bottom:1px;
  font-size:.7rem;
  letter-spacing:.06em;
}

.gm-sub{
  margin:0;
  font-size:.7rem;
  letter-spacing:.04em;
}

/* counter */
.gm-counter{
  position:absolute;
  right:15px;
  bottom:30px;
  color:#000;
  font-size:.7rem;
  letter-spacing:.04em;
}

/* close button */
.gm-close{
  position:absolute;
  right:10px;
  bottom:10px;
  border:0;
  background:transparent;
  color:#000;
  font-size:.7rem;
  z-index:10;
}

.gm-project-nav{
  position: absolute;
  left: 50%;
  bottom: 10px;
  transform: translateX(-50%);
  z-index: 10;

  display: flex;
  align-items: center;
  gap: 8px;

  font-size: .6rem;
  letter-spacing: .04em;
}

.gm-project-nav button {
  border: 0;
  background: transparent;
  color: #000;
  cursor: pointer;
  font: inherit;
  padding: 8px 6px;
}

.gm-project-nav span{
  color: #000;
}


@media (max-width: 360px){
.gm-name .gm-main,
.gm-name .gm-subtitle,
.gm-ttl,
.gm-sub,
.gm-counter,
.gm-close

{
  font-size:.6rem;
  letter-spacing:0.05em;
}
}


/* click zones */
.gm-hit{
  position:absolute;
  top:0;
  bottom:0;
  width:50vw;
  height:100vh;
  border:0;
  background:transparent;
  cursor:pointer;
  z-index:5;
}
.gm-prev{ left:0; }
.gm-next{ right:0; }

/* tap highlight off */
.gm-hit,
.gm-close,
.gm-backdrop{
  -webkit-tap-highlight-color:transparent;
  outline:none;
  user-select:none;
}

/* open behaviour */
.gm[aria-hidden="false"]{
  overflow:hidden !important;
  overscroll-behavior:contain !important;
  touch-action:none !important;
}

/* safe area mobile */
@media (max-width:768px){
  .gm-caption{
    left: 12px;
    right: auto;
    bottom: calc(38px + env(safe-area-inset-bottom));
    text-align: left;
    max-width: 68%;
    pointer-events: none;
  }

  .gm-project-nav{
    left: 6px;
    right: auto;
    transform: none;
    bottom: calc(12px + env(safe-area-inset-bottom));
    justify-content: flex-start;
    font-size: .6rem;
    gap: 8px;
  }

  .gm-counter{
    right: 18px;
    bottom: calc(38px + env(safe-area-inset-bottom));
  }

  .gm-close{
    right: 12px;
    bottom: calc(12px + env(safe-area-inset-bottom));
  }
}






/* =========================================
   LIGHTBOX (gm) — OVERVIEW TOGGLE
   ========================================= */
.gm-view-toggle{
  position: fixed;
  top: 7px;
  right: 24px;
  z-index: 10001;
  display: flex;
  gap: 10px;
}

.gm-view-btn{
  width: 30px;
  height: 30px;
  color: #111;
  font-size: 16px;
  line-height: 1;
  text-decoration: none;
  cursor: pointer;
  display: grid;
  place-items: center;
  padding: 0;
  border-radius: 6px;
}

.gm-view-btn.is-active{
  background: rgba(0,0,0,0.08);
}

@media (max-width: 768px){
  .gm-view-toggle{
    top: 7px;
    right: 16px;
    gap: 8px;
  }
}
















/* ================= VIDEO (gm) ================= */

/* wrapper: 基本形 + readyまで隠す */
.gm-video-wrap{
  position: relative;
  flex: 0 0 auto;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  z-index: 20;

  opacity: 0;
  transition: opacity .35s ease;

  pointer-events: auto;

  /* sizing: default */
  max-width: 100%;
  max-height: 100%;
}

.gm-video-wrap.is-ready{
  opacity: 1;
}

/* video: default sizing */
.gm-video-wrap video{
  display: block;
  width: auto;
  height: auto;
  max-width: 90vw;
  max-height: 90vh;
  object-fit: contain;
}

/* controls */
.sv-controls{
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  padding: 12px 14px;

  display: flex;
  flex-direction: column;
  gap: 6px;

  opacity: 0;
  pointer-events: none;
  transition: opacity .25s ease;

  z-index: 10;
  background: linear-gradient(to top, rgba(0,0,0,.35), rgba(0,0,0,0));
}

.gm-video-wrap:hover .sv-controls{
  opacity: 1;
  pointer-events: auto;
}

.sv-controls.is-visible{
  opacity: 1;
  pointer-events: auto;
}

.sv-progress{
  height: 6px;
  background: rgba(0,0,0,.3);
  cursor: pointer;
}

.sv-progress__bar{
  width: 0;
  height: 100%;
  background: #fff;
}

.sv-nav{
  display: flex;
  justify-content: space-between;
}

.sv-btn{
  border: none;
  background: transparent;
  color: #fff;
  font-size: 11px;
  letter-spacing: .06em;
  cursor: pointer;
}

@media (max-width:480px){
  .sv-controls{ padding: 8px 12px; }
}

/* ==========================================================================
   FIX — mobile PORTRAIT only
   ========================================================================== */

@media (max-width: 768px) and (orientation: portrait) and (pointer: coarse){

  .gm-frame{
    height: calc(100svh - var(--gm-footer-h));
  }

  .gm-video-wrap{
    max-height: 100%;
    max-width: none;
  }

  .gm-video-wrap video{
    height: 100%;
    width: auto;
    max-height: 100%;
    max-width: 100%;
    object-fit: contain;
  }

  .gm.is-portrait-video .gm-video-wrap{
    max-width: 72vw;
    margin: 0 auto;
  }

  .gm.is-portrait-video{
    --gm-footer-h: 190px;
  }
}










/* ============================
  16) Info Layout
   ============================ */


   
.info{
  padding: 26px 22px 80px;
}

.infoGrid{
  display: block; /* mobile default */
}

.info h2{
  margin: 22px 0 10px;
  font-size: .7rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

.info p{
  margin: 0 0 14px;
  font-size: .7rem;
  line-height: 1.9;
  letter-spacing: 0.06em;
  max-width: 72ch; /* mobile: 読みやすい行長 */
}


.info a{
  color: inherit;
  text-decoration: none;
}

.info .copyright{
 color: #11111182;
  margin-top: 50px;
}

@media (min-width: 980px){

  .info{
    padding: 34px 42px 80px;
  }

  .infoGrid{
    display: grid;
    grid-template-columns: 1fr 1fr;
    column-gap: 140px;
    align-items: start;
  }

  .infoLeft p{
    max-width: 64ch; /* 左側本文は少し細め */
  }

  .infoRight p{
    max-width: 56ch; /* 右側は羅列なのでさらに細めでもOK */
  }

  .infoRight .copyright{
    margin-top: 22px;
  }
}

/* Info page header */
.page-info .topbar{
  background: #f7f7f5;

  display: flex;
  align-items: flex-start;
  padding: 20px 20px 0;
}

.page-info .brand{
  display: flex;
  flex-direction: column;
  line-height: 1.2;
}

.page-info .brand-link{
  display: flex;
  flex-direction: column;
  color: inherit;
  text-decoration: none;
}

.page-info .brand .artist,
.page-info .brand .role{
  font-size: .8rem;
  letter-spacing: 0.02em;
  color: #111;
}

@media (min-width: 980px){
  .page-info .topbar{
    padding: 34px 42px 0;
  }
}

.info .social-links{
  line-height: 1.8;
}