@charset "UTF-8";
@import url("grid.css");

:root { /* 色変更される場合は、#以降のカラーコードを変更してください IE非対応 */
    --main-color: #5c5744;
    --base-color: #000000;
    --link-color: #5c5744;
    --linkhover-color: #000000;
    --back-color: #ffffff;
    --border-color: #5c5744;
    --white-color: #ffffff;
    --nav-color: rgba(0, 0, 0, 0.85);
}

/* Vegas.js 巨大化・はみ出し対策 */
.vegas-container {
    overflow: hidden !important;
    position: relative;
}
.vegas-slide, .vegas-slide-inner {
    background-size: cover !important;
    background-position: center center !important;
    width: 100% !important;
    height: 100% !important;
}

body {
    background: var(--white-color); 
    color: var(--base-color);
    font-family: 'Noto Serif JP', serif;
    margin: 0;
}

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

a {
    display:block;
    color: var(--link-color);
    text-decoration-line: none;
}

a:hover { 
    color: var(--linkhover-color);
}

h2, h1.catch, h2.menu {
    margin-bottom: 2rem;
    padding-bottom: 2rem;
    text-align: center;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--white-color);
}

h2.info {
    margin-bottom: 2rem;
    padding-bottom: 2rem;
    text-align: center;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--base-color);
}

h1::before, h1::after, h2::before, h2::after {
    content:"";
    width:80px;
    height:1px;
    margin:0 10px;
    background-color: var(--border-color);
}

h3.underline {
    border-bottom: 1px solid var(--border-color);
    padding-bottom: 0.5rem;
}

h4 {
    border-left: 4px solid var(--link-color);
    padding-left: 1rem;
}

section {
    padding: 3rem 0;
}

/* ヘッダー・ナビゲーション
-------------------------------------*/
.spnavi {
    display: none;
}

nav ul {
    display: flex;
    flex-direction: row;
    justify-content: space-around;
    list-style: none;
    margin: 0; 
    position: sticky;
}

nav li {
    flex: 1 0 auto;
    margin-bottom: 0;
}

nav li a {
    text-decoration: none;
    text-align: center;
    width: 100%;
    color: var(--white-color); 
    padding-top: 1.4em;
    padding-bottom: 1.0em;
    padding-left: 0.8em;
    padding-right: 0.8em;
    font-weight: 600;
    letter-spacing: 0.05em;
}

nav a:hover {
    color: var(--linkhover-color);   
}

@media screen and (min-width: 769px){
    #open,#close {
        display: none !important;
    }
    #navi {
        display: block !important;
    }
}

@media screen and (max-width: 768px){
    .header {
        flex-direction: column;
        margin-bottom: 10px;
        position: static; 
    }
    #open, #close {
        display: block;
        width: 50px;
        height: 50px;
        border: none;
        position: absolute;
        top: 12px;
        right: 12px;
        z-index: 10000;
        background-repeat: no-repeat;
        background-size: contain;
    }
    #open { background-image: url(../img/button.png); }
    #close { background-image: url(../img/button2.png); }

    nav ul {
        flex-direction: column;
        border-top: 1px solid #cccccc;
        border-bottom: 1px solid #cccccc;
    }

    #navi {
        display: none; 
        position: fixed;
        top: 0;
        left: 0;
        width: 100%;
        height: 100vh;
        z-index: 9999;
        background-color: rgba(92, 87, 68, 0.9);
        overflow-y: auto;
        padding-top: 80px;
    }

    #navi ul {
        opacity: 0;
        transform: translateY(-20px);
        transition: opacity 0.6s ease, transform 0.6s ease;
    }

    #navi[style*="display: block"] ul {
        opacity: 1;
        transform: translateY(0);
    }

#navi ul li a {
    color: #ffffff;
    padding: 1.5em;
    text-align: center;
    border-bottom: 1px solid #cccccc;
    background-color: transparent !important;
    font-weight: 600;
    letter-spacing: 0.05em;
}

    .navblock {
        background: none !important; 
    }
}

/* メインビジュアル (Vegas適用エリア)
-------------------------------------*/
.head {
    /* Vegas.jsが動くまでの背景 */
    background: #000 url("../img/mainimg00.jpg") center center / cover no-repeat;
    height: 100vh;
    position: relative;
}

.head h1 {
    width: 100%;
    height: auto; /* 固定値を解除して柔軟に */
    line-height: 2;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: flex-start;
    padding-top: 5vh; /* 上からの位置を画面比率で調整 */
    text-align: center;
    color: var(--base-color);
    text-shadow: 1px 2px 3px var(--white-color); 
    margin: 0;
    position: relative;
    z-index: 10; /* Vegasより前面に出す */
}

.navblock {
    background-color: rgba(92, 87, 68, 0.9);
}

.button {
    border-radius: 30px;
    height: 50px;
    line-height: 48px;
    color: var(--white-color);
    background-color: var(--link-color);
    border: 1px solid var(--link-color);
    margin: 1rem;
    text-align: center;
}

.button:hover {
    background-color: var(--linkhover-color);
    border: 1px solid var(--linkhover-color);
    color: var(--white-color);
}

/* キャッチコピー
-------------------------------------*/
.catchback {
  background: url('../img/catchback.jpg') no-repeat center / cover;
  margin-top: -5rem;
  padding-top: 5rem;
}

.catch {
    background-color: var(--white-color);
    margin: 5rem auto;
    padding: 3rem 2rem;
    max-width: 700px;
    border: none;
    text-align: center;
    line-height: 1.7;
}

p.catch {
    padding: 3rem 1rem;
}

.center {
    text-align: center;
    margin-bottom: 4rem;
}

/* ニュース
-------------------------------------*/
.back-color {
    background-color: var(--back-color);
}

.news {
    margin: 0 auto;
    max-width: 980px;
    padding: 2rem;
}

.news-list {
    list-style: none;
    padding: 0;
}

.news-list .item a {
    display: flex;
    flex-wrap: wrap;
    color: var(--base-color);
    border-bottom: 1px solid var(--border-color);
    padding: 1.5rem 0;
}

.news-list .item:first-child a {
    border-top: 1px solid var(--border-color);
}

.news-list .item .date {
    min-width: 120px;
}

/* コンテンツ背景
-------------------------------------*/
.menuback {
    background: url('../img/menuback.jpg') no-repeat center / cover;
    padding: 15rem 0;
    margin-bottom: 3rem;
}

.infoback {
    background: url('../img/infoback.jpg') no-repeat center / cover;
    padding: 15rem 0;
}

.photoback {
    background: url('../img/photoback.jpg') no-repeat center / cover;
    padding: 15rem 0;
}

.menuback h2, .contactback h2. .photoback h2. {
    text-shadow: 1px 2px 3px var(--base-color); 
}

/* 画像ホバー
-------------------------------------*/
.hoverbox {
    max-height: 800px;
    overflow: hidden;
}

.hoverbox-img {
    transition: transform 0.3s;
}

.hoverbox-img:hover {
    transform: scale(1.03);
}

/* その他パーツ
-------------------------------------*/
.gmap { margin: 3rem 0; }

a.tel { display: inline-block; }

@media screen and (min-width: 768px){
    a[href*="tel:"] { 
        pointer-events: none;
        cursor: default;
    }
}

h3.stripe {
    position: relative;
    padding: 0.3em;
}

h3.stripe:after {
    content: "";
    position: absolute;
    left: 0;
    bottom: 0;
    width: 100%;
    height: 3px;
    background: repeating-linear-gradient(-45deg, var(--link-color), var(--link-color) 2px, var(--back-color) 2px, var(--back-color) 5px);
}

.table { margin: 4rem 0; width: 100%; }
.table th { width: 150px; text-align: left; }

input, textarea, select {
    border-radius: 10px;
    border: 1px solid #ccc;
    padding: 0.5em;
}

/* SNS & フッター
-------------------------------------*/
.snsicon {
    display: flex;
    justify-content: center;
    list-style: none;
    padding: 0;
}

.snsicon li {
    width: 60px;
    margin: 2rem 1rem 0;
}

footer {
    background-color: #5c5744;
    color: var(--white-color);
}

.footermenu {
    display: flex;
    justify-content: center;
    list-style: none;
    padding: 3rem 0 0;
}

.footermenu li { padding: 1rem; }
.footermenu a { color: var(--white-color); }
.footermenu a:hover { color: var(--linkhover-color); }

.copyright {
    text-align: center;
    padding: 1rem 0;
}

#pagetop {
    position: fixed;
    bottom: 25px;
    right: 25px;
    width: 40px;
    height: 40px;
    background: var(--main-color);
    border: 1px solid var(--white-color);
    border-radius: 50%;
    z-index: 100;
}

#pagetop::after {
    content: "";
    display: block;
    border-top: 2px solid var(--white-color);
    border-right: 2px solid var(--white-color);
    width: 10px;
    height: 10px;
    /* --- ここから修正 --- */
    position: absolute;
    top: 55%;    /* 矢印の重心を考慮して少し下げ気味に設定 */
    left: 50%;   /* 一旦中央へ */
    transform: translate(-50%, -50%) rotate(-45deg); /* 中央補正しつつ回転 */
    /* --- ここまで修正 --- */
}

/* 下層ページ 完全固定版
-------------------------------------*/
.subhead {
  height: 500px;
  background: url('../img/subpageback.jpg') no-repeat center / cover;
  margin-bottom: 2rem;

  display: grid;
  place-items: center;   /* ← flexよりズレにくい */
}

/* h1 を完全リセット */
.subhead h1 {
  all: unset;            /* ← これが決定打 */
  display: block;

  width: 100%;
  text-align: center;

  color: var(--white-color);
  font-family: 'Noto Serif JP', serif;
  font-size: 2.8rem;
  text-shadow: 1px 2px 3px var(--base-color);

  margin: 0 auto;
}

/* spanも完全に素に戻す */
.subhead h1 span {
  display: inline-block;
  text-align: center;
}

/* 疑似要素完全封印 */
.subhead h1::before,
.subhead h1::after {
  content: none !important;
}

/* スマホ */
@media (max-width: 768px) {
  .subhead {
    height: 420px;
  }
}

.subhead h1 {
  transform: translateY(20px);
}

@media (max-width: 768px) {
  .subhead h1 {
    transform: translateY(-120px);
  }
}

/* スマホ表示調整
-------------------------------------*/
@media screen and (max-width: 768px){
    h1, h2, h3 { font-size: 2.5rem; }
    h2::before, h2::after { width: 30px; }
    .head h1 { height: 400px; padding-top: 20px; }
    .catch { margin: 3rem 1rem; }
    .table th, .table td { display: block; width: 100%; }
    .footermenu { flex-wrap: wrap; }
}

.head .vertical,
.head .tate,
.head .copy {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
}

/* PC版 ナビを上部固定（崩れない最小構成） */
@media screen and (min-width: 769px){
  .navblock {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 999;
  }
  }