@charset "UTF-8";

/************************************
** 記事一覧
************************************/
#list {
	--count: 2;
	--gap: .25rem;
	display: flex;
	flex-wrap: wrap;
	gap: var(--gap);
}

@media (min-width: 600px) {
	#list {
		--count: 3;
	}
}

#list .entry-card-wrap {
	width: calc((100% - var(--gap) * (var(--count) - 1)) / var(--count));
	margin: 0;
}

/************************************
** エントリーカード
************************************/
#list .entry-card-title,
#list .related-entry-card-title {
	display: block;
	padding: 0;
	border-bottom: 0;
	font-size: .75rem;
}

#list .entry-card-meta{
	display: none;
}

/************************************
** タグクラウド
************************************/
:is(.widget-sidebar, .under-entry-content) .tagcloud {
	max-height: 10rem;
	overflow-y: auto;
}

/* 10remを超えた場合にモヤ（グラデーション）を生成 */
:is(.widget-sidebar, .under-entry-content) .tagcloud.is-overflowing::after {
	content: "";
	position: sticky;
	bottom: -1px; /* ブラウザのレンダリング誤差による隙間を防ぐ */
	display: block;
	width: 100%;
	height: 3rem;
	margin-top: -3rem; /* 要素自体の高さを相殺し、スクロール領域を拡張させない */
	background: linear-gradient(to bottom, transparent, rgba(255, 255, 255, 1));
	background: linear-gradient(to bottom, rgba(255,255,255,0) 0%, rgba(255,255,255,1) 100%);
	pointer-events: none; /* 下にあるタグのクリックを妨げない */
	transition: opacity 0.3s ease;
	opacity: 1;
}

/* 一番下までスクロールした際にモヤを消す */
:is(.widget-sidebar, .under-entry-content) .tagcloud.is-bottom::after {
	opacity: 0;
}

.widget-sidebar .tagcloud a,
.under-entry-content .tagcloud a {
	flex: inherit;
	white-space: nowrap;
}

/************************************
** 記事詳細：1枚目の画像（スライド風）
************************************/
.first-image a {
	--slider-nav-size: clamp(1.5rem, 0.786rem + 1.9vw, 2.5rem);
	--slider-nav-bg: rgba(0, 0, 0, 0.5);
	--slider-nav-bg-hover: rgba(0, 0, 0, 0.8);
	--slider-nav-shadow: 0 4px 8px rgba(0, 0, 0, 0.3);
	--slider-transition: all 0.3s ease-out;
	position: relative;
	display: block;
	width: 100%;
	border-radius: .5rem;
	overflow: hidden;
	cursor: pointer;
}

.first-image a::before,
.first-image a::after {
	content: "";
	position: absolute;
	top: 50%;
	transform: translateY(-50%);
	width: var(--slider-nav-size);
	height: var(--slider-nav-size);
	background-color: var(--slider-nav-bg);
	border-radius: 50%;
	box-shadow: var(--slider-nav-shadow);
	backdrop-filter: blur(4px);
	z-index: 10;
	transition: var(--slider-transition);
	opacity: 0.8;
	background-repeat: no-repeat;
	background-position: center;
	background-size: calc(var(--slider-nav-size) / 2);
}

.first-image a::before {
	left: 0;
	background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23ffffff' stroke-width='2.5' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='15 18 9 12 15 6'%3E%3C/polyline%3E%3C/svg%3E");
}

.first-image a::after {
	right: 0;
	background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23ffffff' stroke-width='2.5' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='9 18 15 12 9 6'%3E%3C/polyline%3E%3C/svg%3E");
}

.first-image a:hover::before,
.first-image a:hover::after {
	opacity: 1;
	background-color: var(--slider-nav-bg-hover);
}

.first-image a:active::before {
	transform: translateY(-50%) scale(0.95);
}

.first-image a:active::after {
	transform: translateY(-50%) scale(0.95);
}

/************************************
** 関連記事
************************************/
.custom-related-group:not(:last-child){
	margin-bottom: 2.5rem;
}