@charset "utf-8";

/* ==========================================================================
   共通設定
   ========================================================================== */
* {
    box-sizing: border-box;
}

.zirei-container {
    max-width: 1200px;
    margin: 0 auto;
   
    width: 100%;
}
h2.tittle{
	text-align: center;
	margin: 30px;
    
    font-size: 2.2rem;}

/* ==========================================================================
   一覧ページ（グリッド表示）
   ========================================================================== */
.works-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 20px;
    margin-top: 30px;
	margin-left: 10px;
	margin-right: 10px;
}

.work-item {
    background-color: #fff;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.1);
    border: 1px solid #eee;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    text-decoration: none;
    color: inherit;
    display: block;
}

.work-item:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.15);
}

.work-img-box {
    width: 100%;
    aspect-ratio: 4 / 3;
    overflow: hidden;
    background: #f0f0f0;
}

.work-img-box img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.work-info {
    padding: 15px;
}

.work-cat {
    color: #999;
   
   
    display: block;
    margin-bottom: 5px;
    font-size: 1.3rem;
}

.work-title {
    margin: 0;
    font-size: 1.45rem;
    line-height: 1.4;
}

/* ==========================================================================
   詳細ページ
   ========================================================================== */
.detail-title {
    font-size: 2rem;
    margin-bottom: 20px;
}

.description-box {
    background: #fafafa;
    padding: 20px;
    border-radius: 8px;
    margin: 30px 0;
    white-space: pre-wrap;
    line-height: 1.3;
}

.photo-grid {
    display: grid;
    grid-template-columns: repeat(6, 1fr);
    gap: 15px;
    margin: 30px 0;
}

.photo-item {
    overflow: hidden;
    background: #f0f0f0;
    /*border-radius: 5px;*/
}

.photo-item img {
    width: 100%;
    aspect-ratio: 1 / 1;
    object-fit: cover;
    display: block;
    cursor: pointer;
    transition: transform 0.5s ease;
}

.photo-item:hover img {
    transform: scale(1.1);
}

/* ==========================================================================
   ライトボックス（外部化）
   ========================================================================== */
#custom-lightbox {
    display: none;
    position: fixed;
    z-index: 9999;
    top: 0;
    left: 0;
    background: rgba(0,0,0,0.9);
    justify-content: center;
    align-items: center;
	
	top: 50%; 
	left: 50%; 
	transform: translate(-50%, -50%);
	width: 75%; 
	height: auto;
}

#custom-lightbox.active {
    display: flex;
}

#lightbox-img {
    max-width: 90%;
    max-height: 80%;
    object-fit: contain;
    box-shadow: 0 0 20px rgba(0,0,0,0.5);
}


.close-btn {
    position: absolute;
    top: 20px;
    right: 30px;
    color: #fff;
    font-size: 50px;
    cursor: pointer;
    opacity: 0.7;
}

.nav-btn {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    color: #fff;
    font-size: 60px;
    cursor: pointer;
    padding: 20px;
    user-select: none;
    opacity: 0.5;
    transition: 0.3s;
}

.nav-btn:hover, .close-btn:hover {
    opacity: 1;
}

.prev { left: 10px; }
.next { right: 10px; }

body.noscroll {
    overflow: hidden;
}

/* ==========================================================================
   ボタン・ナビゲーション
   ========================================================================== */
.view-more, .footer-nav {
    text-align: center;
    margin: 40px 0;
}

.btn-link {
    display: inline-block;
    padding: 12px 50px;
    border: 1px solid #333;
    color: #333;
    text-decoration: none;
    transition: 0.3s;
}

.btn-link:hover {
    background: #333;
    color: #fff;
}
/* ==========================================================================
   パンくずリスト
   ========================================================================== */
.breadcrumb {
    margin: 20px 10px;
    padding: 0;
    list-style: none;
   
    color: #666;
}
.breadcrumb li {
    display: inline;
}
.breadcrumb li:after {
    content: ">";
    margin: 0 10px;
    color: #ccc;
}
.breadcrumb li:last-child:after {
    content: "";
}
.breadcrumb a {
    text-decoration: none;
    color: #333;
}
.breadcrumb a:hover {
    text-decoration: underline;
}

/* ==========================================================================
   レスポンシブ対応
   ========================================================================== */
@media (max-width: 960px) {
    .zirei-container {
        padding-left: 30px;
        padding-right: 30px;
    }
    .works-grid {
        grid-template-columns: repeat(3, 1fr);
    }
	 .photo-grid {
        grid-template-columns: repeat(5, 1fr);
    }
}

@media (max-width: 628px) {
    .zirei-container {
        padding-left: 20px;
        padding-right: 20px;
    }
    .works-grid {
        grid-template-columns: 3fr;
        gap: 25px;
    }
    .photo-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    .detail-title {
       
    }
    .nav-btn {
        font-size: 40px; /* スマホでは矢印を少し小さく */
    }
	#custom-lightbox {
    display: none;
    position: fixed;
    z-index: 9999;
    top: 0;
    left: 0;
    background: rgba(0,0,0,0.9);
    justify-content: center;
    align-items: center;
	
	top: 50%; 
	left: 50%; 
	transform: translate(-50%, -50%);
	width: 100%; 
	height: auto;
}
}