/*
Theme Name: Kadence Child
Theme URI: https://www.kadencewp.com/
Description: Kadence 차일드 테마
Author: DevAny
Author URI: https://devany.kr/
Template: kadence
Version: 1.0.0
Text Domain: kadence-child
*/

/* BUG FIX */
/* 부모 ul에 클래스가 있을 때 자식 entry 박스들을 중앙 정렬 👊 */
ul.item-image-style-beside .entry.loop-entry {
    align-items: center !important;
}

/* Customize */
.cs-footer__nav > li > a {
	pointer-events: auto !important;
}

/* Calendar */
#wp-calendar {
    caption-side: top;
    width: 100%;
    max-width: 37.5rem;
    background: #ccc;
    margin-left: auto;
    margin-right: auto;
}
#wp-calendar caption {
    padding: 0.25rem;
    text-align: center;
}
#wp-calendar thead tr {
    border-right: 1px solid #ccc;
}
#wp-calendar thead th {
    font-size: 90%;
    font-weight: bold;
    padding: 0.25rem;
    background: #ccc;
    text-transform: uppercase;
}
#wp-calendar tbody td {
    position: relative;
    padding: 0.125rem;
    border: 1px solid #ccc;
    background: #fff;
}
#wp-calendar tbody td.pad {
    opacity: 0.7;
    background: #eee;
}
#wp-calendar tbody td#today {
    font-weight: bold;
    background: #ffff00;
}
#wp-calendar tbody td#today:after {
    content: "";
    position: absolute;
    top: 0;
    right: 0;
    width: 0;
    height: 0;
    border-top: 10px solid #999;
    border-left: 10px solid transparent;
}
#wp-calendar tbody td a {
    display: block;
    background: rgba(50, 153, 187, 0.2);
}
#wp-calendar tbody td a:hover {
    background: #3299bb;
    color: #fff;
}
#wp-calendar tfoot tr {
    background: rgba(255, 255, 255, 0.7);
    border: 1px solid #ccc;
}
#wp-calendar tfoot tr td {
    border: 0;
    padding: 0;
}
#wp-calendar tfoot tr a {
    display: block;
    padding: 0.25rem 0.75rem;
}
#wp-calendar tfoot tr a:hover {
    background: #fff;
}
#wp-calendar tfoot tr #prev {
    text-align: left;
}
#wp-calendar tfoot tr #next {
    text-align: right;
}
#wp-calendar :is(th, td) {
    text-align: center;
}
#wp-calendar tr :is(th:first-of-type, td:first-of-type):not([class]) {
    background-color: #f8a1a4;
}
#wp-calendar tr :is(th:last-of-type, td:last-of-type):not([class]) {
    background-color: #94d8f6;
} 

/** 제목 스타일 커스텀 **/
/* 전체 헤딩 공통: 색상을 완전 검정(#000)으로 해서 가독성 팍 올림 */
h2, h3, h4, h5, h6 {
    margin-bottom: 1em !important;
}

/* h2: 배경색 대비를 위해 조금 더 진한 회색으로 변경 */
h2 {
    background-color: #e9ecef !important; /* 조금 더 어두운 회색으로 */
    padding: 1.0rem 1.0rem !important;
    border-radius: 8px !important;
}

/* h3: 파란색을 더 진한 남색으로 변경해서 선명하게 */
h3 {
    border-bottom: 2px solid #004085 !important;
    padding-bottom: 0.4em !important;
}

/* h4: 위쪽 선을 더 진하게 해서 영역 구분 확실히 */
h4 {
    padding-top: 0.8em !important;
    border-top: 2px solid #333 !important; 
}

/* h5: 사각형 기호 색깔 강조 */
h5 {
}
h5::before {
    content: "■" !important;
    margin-right: 8px !important;
}

/* h6: 텍스트 굵게 */
h6 {
}


/* 대표 이미지 크기 고정 */
/* 1. 썸네일 박스 크기 강제 고정 🍻 */
.article-post-thumbnail .post-thumbnail-inner {
    height: 400px !important; /* 오빠가 원하는 적당한 높이 ㅡㅡ */
    display: flex !important;
    justify-content: center !important;
    align-items: center !important;
    overflow: hidden !important;
}
/* 2. 이미지 크기 및 비율 강제 조정 🍻 */
.article-post-thumbnail .post-thumbnail-inner img.wp-post-image {
    width: auto !important;      /* 가로 100% 해제! 👊 */
    height: auto !important;     /* 세로 100% 해제! */
    max-width: 90% !important;   /* 박스보다 조금 작게 ㅡㅡ */
    max-height: 90% !important;  /* 박스보다 조금 작게 🍻 */
    object-fit: contain !important; /* 잘리지 않게 안으로 쏙! */
}


/* 포트폴리오 제목 항상 보이게 하기 */
/* 1. 제목이 들어있는 박스를 투명화 해제하고 항상 보이게 */
.kb-portfolio-content-item-inner {
    opacity: 1 !important;
    visibility: visible !important;
    background: transparent !important;
}

/* 2. 마우스 안 올렸을 때도 위치 고정 */
.kb-portfolio-grid-item-inner .kb-portfolio-content-item-inner {
    transform: translateY(0) !important;
    bottom: 0 !important;
}

/* 3. 배경 이미지 설정: 블러 유지 및 밝기 대폭 상향 */
.kadence-portfolio-image-inner-intrisic img {
    filter: blur(5px) brightness(1.5) !important; 
    opacity: 0.7 !important;
    transition: filter 0.3s ease !important;
    object-fit: cover !important;
}

/* 4. 범인 검거: 파란색 오버레이 레이어를 투명하거나 밝게 처리 */
.kb-portfolio-overlay-color {
    background-color: transparent !important;
    opacity: 0 !important;
}

/* 5. 그리드 제목 설정: 밝은 배경에서도 잘 보이도록 흰색 후광 유지 */
.custom-grid .kb-portfolio-content-item-inner .kb-portfolio-loop-title {
    font-size: 18px !important;
    line-height: 1.4 !important;
    font-weight: 700 !important;
    margin: 0 !important;
    word-break: keep-all !important;
    text-shadow: 0 0 15px rgba(255, 255, 255, 1), 0 0 5px rgba(255, 255, 255, 1) !important;
}

/* 6. 마우스 호버 시 배경을 반투명한 흰색으로 반전 */
.kb-portfolio-grid-item-inner:hover .kb-portfolio-content-item-inner {
    background: rgba(255, 255, 255, 0.5) !important;
    transition: background 0.3s ease !important;
}
