/************************************/
/* 페이지 제목 스타일 설정 */
#contentName {
    text-align: center;
    margin: 1em 0; /* 위 여백 1em, 아래여백 1em */
    line-height: 1em;
    padding: 0em; 
    display: flex;
    flex-direction: column;
    align-items: center;
}

/** 컨텐츠: 이미지 갤러리 **/
.galleryName{
    font-family: 'SCoreDream-800';
    font-size: 2em;
}
.gallerySubName{
    font-family: 'SCoreDream-300';
    font-size: 1.5em;
}

/* gallery 및 grid-item 스타일 설정 */
.gallery {
    max-width: calc((100% - 4 * 10px) / 5 * 5 + 4 * 10px); /* 5개의 열과 4개의 간격 */
    width: 1206px;
    margin: 0 auto; /* 가운데 정렬을 위해 margin을 auto로 설정 */
    padding: 0px;
    gap: 0px;
    border: 0px solid rgb(0,0,0); /* 흰색 테두리선, 두께 2px */
    box-sizing: border-box; /* border와 padding을 요소 크기에 포함 */
    
}

.grid-item {
    width: calc((100% - 4 * 10px) / 5); /* 5개의 열과 4개의 간격 */
    margin-bottom: 10px; /* 2px로 간격 줄이기 */
    display: inline-block;
    border: 0px solid rgb(255, 0, 0); /* 레드 두께 3px */
    border-radius: 15px;
    box-sizing: border-box; /* border와 padding을 요소 크기에 포함 */  
    overflow: hidden; /* 부모 요소가 자식 요소를 넘지 않도록 설정 */
    position: relative;
}


.grid-item img {
    max-width: 100%; /* 이미지의 최대 너비 설정 */
    height: auto; /* 이미지의 높이 자동 조절 */
    display: block; /* 블록 레벨 요소로 설정 */
    margin-top: 0; /* 상단 여백 제거 */
    
    transform: scale(1); /* 이미지를 축소합니다. */
    width: 100%;
    margin: 0px;
    display: block;
    border: 1px solid rgb(255,255,255); /* 레드 두께 3px */
    border-radius: 15px;    
    transition: all 0.3s ease; /* 부드러운 전환을 위해 추가 */
    position: relative; /* 기본 위치 설정 */
    z-index: 1; /* 기본 z-index 설정 */
    filter: brightness(0.95); /* 기본 상태에서 이미지를 어둡게 설정 */
}

.grid-item img:hover,
.touch-hover {
    transform: scale(1.2); /* 이미지를 축소합니다. */
    opacity: 1;
    /* box-shadow: 1px 1px 0px rgba(0, 0, 0, 0.5); */
    border: 0px solid rgb(255, 255, 255);
    border-radius: 15px;  
    filter: brightness(1); /* 호버 시 이미지를 더 어둡게 설정 */
    background-color: rgb(255, 255, 255);
    z-index: 2; /* 호버 시 z-index 증가 */
    box-sizing: border-box; /* border와 padding을 요소 크기에 포함 */
}
.grid-item {
    overflow: hidden; /* 부모 요소가 자식 요소를 넘지 않도록 설정 */
    position: relative;
}
        
/* 더 보기 버튼 스타일 */
.more-button-container {
    display: flex;
    justify-content: center;
    margin: 2em 0;
}

.more-button {            
    font-size: 0.8em;
    font-family: 'SCoreDream-300', sans-serif;
    font-weight: 100;
    color: black;
    border: 1pt solid black;
    background-color: lightgray;
    text-align: center;
    line-height: 35px;
    cursor: pointer;
    transition: background-color 0.3s, color 0.3s;
    padding: 0.5em 2em;
    border-radius: 0.4em;
    line-height: 1.3em;
    transition: background-color 0.3s, color 0.3s;
}
.more-button:hover {
    background-color: gray;
    color: white;
}
.more-button:active {
    background-color: blue;
}

/* 반응형 미디어 쿼리 설정  ***/        
@media (max-width: 768px) {
    .menu ul li {
        float: none !important;
        width: 100% !important;
        text-align: center;
        }

    .productConents {
        height: auto;
        flex-direction: column;
        align-items: stretch;
        }

    .productImage {
        flex: none;
        margin-right: 0;
        margin-bottom: 10px;
        }
    }

     /* 반응형 미디어 쿼리 설정  ***/        
     @media (max-width: 768px) {
        .menu ul li {
            float: none !important;
            width: 100% !important;
            text-align: center;
        }

        .productConents {
            height: auto;
            flex-direction: column;
            align-items: stretch;
        }

        .productImage {
            flex: none;
            margin-right: 0;
            margin-bottom: 10px;
        }
    }

    @media (min-width: 1200px) {
.gallery {
    max-width: calc((100% - 4 * 10px) / 5 * 5 + 4 * 10px); /* 5개의 열과 4개의 간격 */
}
.grid-item {
    width: calc((100% - 4 * 10px) / 5); /* 5개의 열과 4개의 간격 */
}
}

@media (max-width: 1199px) {
.gallery {
    max-width: calc((100% - 3 * 10px) / 4 * 4 + 3 * 10px); /* 4개의 열과 3개의 간격 */
}
.grid-item {
    width: calc((100% - 3 * 10px) / 4); /* 4개의 열과 3개의 간격 */
}
}

@media (max-width: 750px) {
.gallery {
    max-width: calc((100% - 2 * 10px) / 3 * 3 + 2 * 10px); /* 3개의 열과 2개의 간격 */
}
.grid-item {
    width: calc((100% - 2 * 10px) / 3); /* 3개의 열과 2개의 간격 */
}
}

@media (max-width: 500px) {
.gallery {
    max-width: calc((100% - 1 * 10px) / 2 * 2 + 1 * 10px); /* 2개의 열과 1개의 간격 */
}
.grid-item {
    width: calc((100% - 1 * 10px) / 2); /* 2개의 열과 1개의 간격 */
}
}
