/* --- Reset & Basic Styles --- */
@import url('https://fonts.googleapis.com/css2?family=Montserrat:wght@400;700&family=Noto+Sans+JP:wght@400;700&display=swap');
:root { --font-family-base: 'Noto Sans JP', sans-serif; --font-family-en: 'Montserrat', sans-serif; }
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body { font-family: var(--font-family-base); font-size: 16px; line-height: 1.8; color: #fff; background-color: #1a1a1a; overflow-x: hidden; transition: background-color 0.5s ease; }
img { max-width: 100%; height: auto; vertical-align: middle; }
a { text-decoration: none; color: inherit; transition: opacity 0.3s ease; }
a:hover { opacity: 0.7; }
ul { list-style: none; }
.inner, .inner-w { width: 100%; max-width: 1400px; margin: 0 auto; padding: 0 40px; }
.f-ty01 { font-family: var(--font-family-en); }
.viewSP { display: none; }
.wrap { padding: 120px 0; }
.grid-col-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 30px; }
.ov-action-item__thumb { overflow: hidden; }
.ov-action-item__thumb img { transition: transform 0.6s cubic-bezier(0.25, 1, 0.5, 1); }
.ov-action-item:hover .ov-action-item__thumb img { transform: scale(1.05); }
.ov-action-item_ttl span { background: linear-gradient(currentColor 0 0) 0 100% / 0 1px no-repeat; transition: background-size .4s; }
.ov-action-item:hover .ov-action-item_ttl span { background-size: 100% 1px; }
.animated { opacity: 0; transform: translateY(30px); transition: opacity 0.8s ease, transform 0.8s ease; }
.animated.is-active { opacity: 1; transform: translateY(0); }
.delay-01s { transition-delay: 0.1s; }
.delay-02s { transition-delay: 0.2s; }

/* --- Header --- */
#header { position: fixed; top: 0; left: 0; width: 100%; z-index: 1000; display: flex; justify-content: space-between; align-items: center; padding: 20px 40px; transition: all 0.4s ease; }
.logo { width: 200px; height: 28px; }
.logo a, .logo img { display: block; height: 100%; width: auto; }
/* 初期状態：スクロール前 */
#header .logo-light { display: block; } /* 明るいロゴを表示 */
#header .logo-dark { display: none; }  /* 暗いロゴを非表示 */

/* スクロール後の状態 */
#header.is-scrolled { background-color: #fff; box-shadow: 0 2px 10px rgba(0,0,0,0.1); padding-top: 10px; padding-bottom: 10px; }
#header.is-scrolled .logo-light { display: none; }  /* 明るいロゴを非表示 */
#header.is-scrolled .logo-dark { display: block; } /* 暗いロゴを表示 */

#header.is-scrolled { background-color: #fff; box-shadow: 0 2px 10px rgba(0,0,0,0.1); padding-top: 10px; padding-bottom: 10px; }
#header.is-scrolled .logo-light { display: none; }
#header.is-scrolled .logo-dark { display: block; }
#g-nav { display: flex; align-items: center; }
.g-nav-list { display: flex; align-items: center; }
.g-nav-list__item { position: relative; margin: 0 12px; }
.g-nav-link { font-family: var(--font-family-en); font-weight: bold; font-size: 13px; color: #fff; padding: 10px 0; display: block; position: relative; overflow: hidden; }
#header.is-scrolled .g-nav-link { color: #000; }
.g-nav-link span { display: block; transition: transform .4s cubic-bezier(.165,.84,.44,1); }
#gnav-contact a { display: block; background: #fff; color: #000; padding: 10px 25px; border: 1px solid #fff; transition: all 0.3s ease; }
#header.is-scrolled #gnav-contact a { background: #000; color: #fff; border-color: #000; }
.g-nav-openbtn { display: none; }


/* --- Main Visual & Intro --- */
#mv_cont { position: relative; width: 100%; height: 100vh; overflow: hidden; }
.mv-slider { width: 100%; height: 100%; }
.mv-slider .swiper-slide { overflow: hidden; }
.mv-slider .swiper-slide img { width: 100%; height: 100%; object-fit: cover; transform: scale(1); transition: transform 8s linear; }
.mv-slider .swiper-slide-active img, .mv-slider .swiper-slide-duplicate-active img { transform: scale(1.1); }
.scroll-down { position: absolute; bottom: 30px; left: 50%; transform: translateX(-50%); z-index: 10; color: #fff; font-size: 12px; letter-spacing: 0.1em; writing-mode: vertical-lr; }
.scroll-down span { display: block; width: 1px; height: 50px; background: #fff; margin: 10px auto 0; position: relative; overflow: hidden; }
.scroll-down span::after { content: ''; position: absolute; top: -100%; left: 0; width: 100%; height: 100%; background: #fff; animation: scroll-line 2s infinite ease-out; }
@keyframes scroll-line { 0% { transform: translateY(0); } 100% { transform: translateY(200%); } }

#intro_cont { text-align: center; padding: 120px 20px; background: #000; color: #fff; overflow: hidden; position: relative; }
#intro_cont h2 { font-size: 24px; line-height: 1.6; margin-bottom: 30px; font-weight: bold; }
#intro_cont h3 { font-size: 20px; margin-top: 40px; }
#intro_cont p { max-width: 800px; margin: 0 auto 48px; line-height: 2; }
#intro_cont .slide { position: absolute; top: 50%; left: 0; transform: translateY(-50%); width: 200%; display: flex; white-space: nowrap; z-index: 0; }
#intro_cont .slide .slide-text { font-size: 15vw; font-family: var(--font-family-en); font-weight: bold; color: rgba(255,255,255,0.05); padding: 0 20px; animation: slide-text 20s linear infinite; }
@keyframes slide-text { 0% { transform: translateX(0); } 100% { transform: translateX(-50%); } }

/* --- Common Section Styles --- */
.p-top-head { display: flex; justify-content: space-between; align-items: flex-end; margin-bottom: 50px; }
.section-heading .en { display: block; font-size: 50px; font-weight: 700; letter-spacing: 0.05em; line-height: 1; }
.section-heading .jp { display: block; font-size: 14px; margin-top: 10px; }
.link-btn { display: inline-flex; align-items: center; border: 1px solid #000; padding: 10px 20px 10px 30px; overflow: hidden; position: relative; }
.link-btn .txt { display: block; transition: transform 0.4s cubic-bezier(0.165, 0.84, 0.44, 1); }
.link-btn:hover .txt { transform: translateY(-100%); }
.link-btn .btn-arw { margin-left: 20px; width: 10px; height: 10px; }
.link-btn .btn-arw svg { width: 100%; height: 100%; }

/* --- Service --- */
/* #service_cont { background: #f7f7f7; } */
.top-service-list .ov-action-item, .top-service-list .ov-action-item a { display: flex; flex-direction: column; height: 100%; }
.top-service-list .item-pic { position: relative; overflow: hidden; }
.top-service-list .item-pic::after { content: ''; position: absolute; top: 0; left: 0; width: 100%; height: 100%; background-color: rgba(0, 0, 0, 0.2); transition: background-color 0.3s ease; z-index: 1; }
.top-service-list .ov-action-item:hover .item-pic::after { background-color: rgba(0, 0, 0, 0); }
.top-service-list .item-txt { position: relative; padding: 25px; background: #333; flex-grow: 1; }
.top-service-list .heading { font-size: 20px; font-weight: bold; margin-bottom: 10px; }
.top-service-list .txt { font-size: 14px; }
.top-service-list .item-pic:after {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, .6);
    z-index: 1;
}

/* --- Stock / Company / Gallery --- */
#stock_cont { padding: 120px 0; } /* ← padding-bottomを0に変更 */
#stock_cont .stock-link{
    display: block;
    background: #fff;
    border: 1px solid #de0d19;
    padding: 16px 24px;
    margin: 24px auto 0;
}
.stock-text { text-align: center; }
.stock-link { display: inline-block; margin-top: 30px; max-width: 250px; }
#about_cont { background: #000; color: #fff; overflow: hidden; padding-top: 120px; } /* ← padding-topを追加 */
#company_cont { padding: 0 0 120px; } /* ← padding-topを0に、padding-bottomを120pxに修正 */
.company-wrap dl { border-top: 1px solid #555; }
.company-wrap dt, .company-wrap dd { padding: 20px; border-bottom: 1px solid #555; }
.company-wrap dt { float: left; width: 20%; clear: left; }
.company-wrap dd { margin-left: 20%; }
#gallery_cont { padding: 120px 0; }
.swiper__area { padding-left: calc((100vw - 1400px) / 2 + 40px); overflow: hidden; }
.js-slider-gallery { overflow: visible; }
.gallery-item .heading { font-size: 16px; margin-top: 15px; }
.gallery-archive__body { padding-right: 15px; }
.gallery-archive__item { display: flex; justify-content: space-between; font-size: 13px; margin-top: 10px; color: #aaa; }
.gallery-archive__item-cate span { border: 1px solid #aaa; padding: 1px 8px; }

/* --- Footer --- */
#footer { background: #000; color: #fff; }
.footer-contact { position: relative; background: #1a1a1a; overflow: hidden; }
.footer-in { padding: 80px 16px; text-align: center; position: relative; z-index: 1; }
.footer-in .txt { font-size: 22px; font-weight: bold; }
.footer-in .time-txt { margin-top: 20px; }
.footer-contact__loop { position: absolute; top: 50%; left: 0; transform: translateY(-50%); width: 200%; display: flex; white-space: nowrap; }
.footer-contact__loop-text { font-size: 15vw; font-family: var(--font-family-en); font-weight: bold; color: rgba(255,255,255,0.05); padding: 0 20px; animation: loop-text 20s linear infinite; }
@keyframes loop-text { 0% { transform: translateX(0); } 100% { transform: translateX(-50%); } }
.footer-outer { display: flex; justify-content: flex-end; font-size: 12px; color: #aaa; padding: 20px 0; }
.copyright { font-family: var(--font-family-en); }
.fix-right { position: fixed; right: -115px; top: 50%; transform: translateY(-50%); z-index: 999; background: rgba(0,0,0,0.8); padding: 20px; transition: right 0.4s ease; }
.fix-right.is-show { right: 0; }
.fix-right li a { display: block; color: #fff; font-size: 14px; writing-mode: vertical-rl; padding: 20px 0; letter-spacing: 0.1em; }
#fix-bottom-contact { display: none; }

/* --- Body Color Change Logic --- */
body.bg-dark { background-color: #000; transition: background-color 0.5s ease, color 0.5s ease;}
body.bg-dark #about_cont { background-color: #fff; transition: background-color 0.5s ease, color 0.5s ease; }
#about_cont .section-heading, #about_cont .section-heading .jp { color: #fff; }
#about_cont .link-btn { border-color: #fff; color: #fff; }
#about_cont .link-btn svg path { fill: #fff; }
/* #stock_cont .section-heading, #stock_cont .section-heading .jp { color: #000; } */
#stock_cont .link-btn { color: #000; border-color: #000; }
#stock_cont .link-btn svg path { fill: #000; }

body.bg-dark #about_cont,body.bg-dark #about_cont h2,body.bg-dark #about_cont h2 .jp { color: #333; }

/* --- Responsive (SP) --- */
@media screen and (max-width: 768px) {
  #header.is-scrolled .g-nav-link { color: #fff; }
  .inner, .inner-w { padding: 0 20px; }
  .viewSP { display: block; }
  .wrap, #stock_cont, #company_cont, #gallery_cont { padding: 80px 0; }
  #stock_cont { padding: 80px 0; } /* ← padding-bottomを0に変更 */
  #about_cont { padding-top: 80px; } /* ← padding-topを追加 */
  #company_cont { padding: 0 0 80px; } /* ← paddingを修正 */
  #header { padding: 10px 20px; background: #fff; }
  #header.kv { background: rgba(0,0,0,0.2); }
  .logo { width: 150px; height: 24px; }
  #header.kv .logo-dark { display: none; }
  #header.kv .logo-light { display: block; }
  .g-nav-openbtn { display: block; width: 40px; height: 40px; position: relative; z-index: 1002; cursor: pointer; }
  .openbtn-area { width: 100%; height: 100%; display: flex; flex-direction: column; justify-content: center; align-items: center; }
  .openbtn-area span { display: block; width: 24px; height: 2px; background-color: #000; margin: 4px 0; transition: all .4s; }
  #header.kv .openbtn-area span { background-color: #fff; }
  body.nav-open .openbtn-area span { background-color: #000; }
  body.nav-open .openbtn-area span:nth-of-type(1) {
    transform: translateY(10px) rotate(45deg); /* 回転方向を修正 */
  }
  body.nav-open .openbtn-area span:nth-of-type(2) {
    opacity: 0;
  }
  body.nav-open .openbtn-area span:nth-of-type(3) {
    transform: translateY(-10px) rotate(-45deg); /* 回転方向を修正 */
  }
  #g-nav { position: fixed; top: 0; left: 0; width: 100%; height: 100%; background: rgba(0, 0, 0, 0.8); transform: translateX(100%); transition: transform 0.5s ease; padding-top: 60px; overflow-y: auto; }
  body.nav-open #g-nav { transform: translateX(0); }
  #nav-wrap { width: 100%; padding: 20px; }
  .g-nav-list { flex-direction: column; align-items: flex-start; }
  .g-nav-list__item { width: 100%; border-bottom: 1px solid #eee; margin: 0; }
  .g-nav-link { color: #eee; font-size: 16px; padding: 15px 10px; }
  #gnav-contact { display: none; }
  #mv_cont { height: 60vh; }
  #intro_cont { padding: 80px 8px; }
  #intro_cont h2 { font-size: 20px; }
  #intro_cont h3 { font-size: 18px; }
  .p-top-head { flex-direction: column; align-items: flex-start; margin-bottom: 30px; }
  .section-heading .en { font-size: 40px; }
  .link-btn { margin-top: 20px; }
  .grid-col-3 { grid-template-columns: 1fr; }
  .swiper__area { padding-left: 20px; }
  .company-wrap dt { width: 100%; float: none; border-bottom: none; padding-bottom: 5px; font-weight: bold; }
  .company-wrap dd { margin-left: 0; padding-top: 0; }
  .fix-right { display: none; }
  #fix-bottom-contact { display: block; position: fixed; bottom: 0; left: 0; width: 100%; background: #fff; z-index: 998; box-shadow: 0 -2px 10px rgba(0,0,0,0.1); }
  #fix-bottom-contact ul { display: flex; }
  #fix-bottom-contact li { flex: 1; text-align: center; }
  #fix-bottom-contact a { display: flex; flex-direction: column; align-items: center; justify-content: center; padding: 8px 0; font-size: 10px; }
  #fix-bottom-contact a i { width: 24px; height: 24px; margin-bottom: 4px; }
  #fix-bottom-contact .fix-bottom-contact__mail { background: #000; color: #fff; }
  #fix-bottom-contact .fix-bottom-contact__tel { color: #333; }
  #fix-bottom-contact .fix-bottom-contact__mail img { filter: brightness(0) invert(1); }
}
.link--none {pointer-events: none;}