/*
 * EROPORTA 0.4.16（Core 0.5.22・2026-10-03）: トップの画像を目立たせる配置。0.4.17（Core 0.5.23）: 本番公開の前の直し。
 * 0.4.18（Core 0.5.26）: 一覧の 8 列・カード・ボタン・保存の知らせの指定は、全部の一覧で使う共通の部品（eroporta-grid8.css）へ移した。
 * このファイルはトップのページ（固定ページ「EROPORTA トップ」）だけで読み込み、トップだけの指定（横幅・段の間・注目動画）を持つ。
 *
 * - 上段の注目動画（0.4.18: 4 作品）: PC・iPad（縦・横）は 4 列、スマホ（縦・横）は 2 列×2 段。
 *   カードの中の幅が 260px 未満（ボタンが横に収まらない幅）は、ボタンだけ縦に並べる。
 *   段の装飾はボルドーを軸に、淡い金色の線・柔らかな背景・細い枠・控えめな影。装飾は段の枠と見出しだけで、画像・文字・ボタンに重ねない。
 *   0.4.19: 段の外枠はボルドー＋淡い金色のまま、中のカードは掲載元の色（枠・帯・掲載元名・作品情報・淡い地。eroporta-grid8.css の .ep-vc）。
 *   見出しの注記「人気の順位ではありません」は必ず出す（template-parts/ep/top-featured.php）
 */

/* ---------------------------------------------------------------- 1. 横幅と段の間 */
/* 親の非表示ヘッダーに付く固定用body余白だけ解除。管理バーの操作領域は残す。 */
body.ep-site.ep-top-page.header_fix,
body.ep-site.ep-top-page.header_fix_mobile { padding-top: 0; }
body.ep-site.ep-top-page.admin-bar.header_fix,
body.ep-site.ep-top-page.admin-bar.header_fix_mobile { padding-top: 32px !important; }
@media (max-width: 782px) {
	body.ep-site.ep-top-page.admin-bar.header_fix,
	body.ep-site.ep-top-page.admin-bar.header_fix_mobile { padding-top: 46px !important; }
}
.ep-main.ep-top .ep-container { max-width: 1920px; padding-left: 12px; padding-right: 12px; }
.ep-main.ep-top .ep-section.ep-top-works .ep-h2 { margin: 18px 0 8px; }
.ep-main.ep-top .ep-more { margin: 6px 0 0; }
.ep-main.ep-top .ep-feature { padding: 10px 8px; }   /* 0.4.31: 段の間（margin）は下の 4. でまとめて決める */
@media (max-width: 699px) {
	.ep-main.ep-top .ep-container { padding-left: 10px; padding-right: 10px; }
}

/* ---------------------------------------------------------------- 2. 上段の注目動画（4 作品。PC・iPad 4 列、スマホ 2 列×2 段） */
.ep-main.ep-top .ep-top-featured {
	position: relative;
	padding: 12px 10px 12px;   /* 0.4.31: 段の間（margin）は下の 4. でまとめて決める */
	border: 1px solid #e7d7b8;
	border-radius: 12px;
	background: linear-gradient(180deg, #fffaf2 0%, #fdf6f8 100%);
	box-shadow: 0 2px 12px rgba(122, 31, 64, .07);
}
@media (min-width: 700px) {
	.ep-main.ep-top .ep-top-featured { padding: 14px 14px 16px; }
}
/* 見出し: ボルドーの文字と左の帯（共通の .ep-h2）に、淡い金色の下線。注記は金茶色 */
.ep-main.ep-top .ep-top-featured .ep-h2 {
	margin: 0 0 10px;
	padding-bottom: 7px;
	border-bottom: 1px solid #e3cc9a;
	color: #6d1c39;
	font-size: 22px;
	letter-spacing: .04em;
}
.ep-main.ep-top .ep-top-featured .ep-h2 .ep-note { color: #866636; font-size: 12px; letter-spacing: 0; }
@media (max-width: 699px) {
	.ep-main.ep-top .ep-top-featured .ep-h2 { font-size: 19px; }
}
.ep-main.ep-top .ep-featured-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px 8px; }
@media (min-width: 700px) and (min-height: 501px), (min-width: 700px) and (pointer: fine) {
	.ep-main.ep-top .ep-featured-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; }
}
/* 注目動画のカード: 0.4.19 から掲載元の色の細い枠と控えめな影（カードの外側だけ。画像・文字・ボタンに重ねない）。段の外枠（上）はボルドー＋淡い金色のまま */
.ep-main.ep-top .ep-featured-grid .ep-card.ep-card-large { border-color: var(--ep-vline, #eadbc0); box-shadow: 0 2px 8px var(--ep-vshadow, rgba(80, 40, 50, .06)); }
.ep-main.ep-top .ep-featured-grid .ep-card.ep-card-large:hover { border-color: var(--ep-vc, #c9a96e); }
.ep-main.ep-top .ep-card-large .ep-thumb { border-radius: 9px 9px 0 0; background: #f4f2f5; }
.ep-main.ep-top .ep-card-large .ep-go-cap.ep-go-cap-fix { padding: 4px 8px 0; font-size: 11px; }
.ep-main.ep-top .ep-card-large .ep-card-body { padding: 2px 8px 8px; }
.ep-main.ep-top .ep-card-large .ep-card-title { font-size: 14px; line-height: 1.5; }
.ep-main.ep-top .ep-card-large .ep-card-line { font-size: 12px; line-height: 1.55; }
.ep-main.ep-top .ep-card-large .ep-card-meta { font-size: 11px; }
.ep-main.ep-top .ep-card-large .ep-card-foot { gap: 6px; padding-top: 6px; }
.ep-main.ep-top .ep-card-large a.ep-card-info,
.ep-main.ep-top .ep-card-large .ep-card-foot .ep-save-work { min-height: 40px; font-size: 13px; }
/* ボタン: 2 つが欠けずに入る幅（カードの中の幅 260px）までは縦に並べる（スマホ・iPad 縦の 4 列など）。それより広いときは横並び */
@container (max-width: 259.98px) {
	.ep-main.ep-top .ep-card-large .ep-card-foot { flex-direction: column; align-items: stretch; gap: 6px; }
	.ep-main.ep-top .ep-card-large a.ep-card-info,
	.ep-main.ep-top .ep-card-large .ep-card-foot .ep-save-work { flex: 0 0 auto; width: 100%; gap: 3px; padding: 2px 4px; font-size: 13px; }
}
@container (min-width: 260px) {
	.ep-main.ep-top .ep-card-large a.ep-card-info,
	.ep-main.ep-top .ep-card-large .ep-card-foot .ep-save-work { flex: 1 1 0; max-width: 200px; }
}
/* 広い注目動画（PC の 4 列など）: 文字を大きく */
@container (min-width: 300px) {
	.ep-main.ep-top .ep-card-large .ep-go-cap.ep-go-cap-fix { padding: 5px 10px 0; font-size: 12px; }
	.ep-main.ep-top .ep-card-large .ep-card-body { padding: 2px 10px 10px; }
	.ep-main.ep-top .ep-card-large .ep-card-title { font-size: 16px; }
	.ep-main.ep-top .ep-card-large .ep-card-line { font-size: 13px; line-height: 1.6; }
	.ep-main.ep-top .ep-card-large .ep-card-meta { font-size: 12px; }
	.ep-main.ep-top .ep-card-large .ep-card-foot { gap: 8px; padding-top: 8px; }
	.ep-main.ep-top .ep-card-large a.ep-card-info,
	.ep-main.ep-top .ep-card-large .ep-card-foot .ep-save-work { min-height: 42px; font-size: 14px; }
}

/* ---------------------------------------------------------------- 3. 0.4.26（Core 0.5.36）: 各サイト 1 行（最大 4 件）
 * PC・iPad（700px 以上）は 4 列で 1 行。スマホは 2 枚が見える横 1 行で、残りはその行だけ横に送る（2 段に折り返さない）。
 * 画像が主役: 作品名は 1 行（0.4.31。0.4.26〜0.4.30 は 2 行まで）・日付と「発売前」だけ・保存は画像の外の小さな「しおり＋保存」（押せる高さ 44px）。
 * トップのページ（.ep-main.ep-top）の .ep-row4 と .ep-card-row4 だけ。検索・一覧・分類・保存・作品のページは変えない。 */
.ep-main.ep-top .ep-row-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 8px; margin: 0 0 8px; }   /* 0.4.31: 上の余白は段（4.）で持つ・見出しのまとまりの下端→カードは 8px */
.ep-main.ep-top .ep-row-head .ep-h2,
.ep-main.ep-top .ep-section.ep-top-works .ep-row-head .ep-h2 { margin: 0; min-width: 0; }   /* 0.4.31: 1. の .ep-top-works .ep-h2（18px・8px）が見出しのまとまりの中に残り、上に 18px の空きを作っていた */
.ep-main.ep-top .ep-row-head .ep-h2 .ep-note { display: block; margin-top: 2px; font-size: 11px; font-weight: 400; }
.ep-main.ep-top a.ep-row-more { flex: 0 0 auto; display: inline-flex; align-items: center; min-height: 44px; padding: 0 4px; font-size: 13px; font-weight: 700; white-space: nowrap; text-underline-offset: 3px; }
.ep-main.ep-top .ep-row4 {
	display: grid;
	grid-auto-flow: column;
	grid-auto-columns: calc((100% - 8px) / 2);
	gap: 8px;
	overflow-x: auto;
	overscroll-behavior-x: contain;
	scroll-snap-type: x mandatory;
	-webkit-overflow-scrolling: touch;
	padding-bottom: 4px;
}
.ep-main.ep-top .ep-row4 > .ep-card { scroll-snap-align: start; min-width: 0; }
@media (min-width: 700px) {
	.ep-main.ep-top .ep-row4 { grid-auto-flow: row; grid-template-columns: repeat(4, minmax(0, 1fr)); grid-auto-columns: auto; gap: 12px; overflow-x: visible; scroll-snap-type: none; padding-bottom: 0; }
}
/* 注目動画も同じ 1 行（前の 2 列×2 段の指定より優先） */
.ep-main.ep-top .ep-featured-grid.ep-row4 { grid-template-columns: none; gap: 8px; }   /* 前の 2 列×2 段の指定を消す（スマホは 2 枚が見えて横に送る） */
.ep-main.ep-top .ep-top-featured .ep-row-head { margin: 0 0 8px; padding-bottom: 7px; border-bottom: 1px solid #e3cc9a; }
.ep-main.ep-top .ep-top-featured .ep-row-head .ep-h2 { margin: 0; padding-bottom: 0; border-bottom: 0; }
@media (min-width: 700px) {
	.ep-main.ep-top .ep-featured-grid.ep-row4 { grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; }
}
/* もうすぐ発売の見出しの「もっと見る」 */
.ep-main.ep-top .ep-feature-head a.ep-row-more { margin-left: auto; }
.ep-main.ep-top .ep-feature-head { margin-bottom: 8px; }   /* 0.4.31: 見出しのまとまりの下端→カードは 8px（前は 10px） */
/* カード（トップの行）。0.4.31（2026-10-05・boone さんの追加指定）: 作品名は 1 行（24px）で、長い作品名は末尾を「…」。全文は DOM と title に残す（作品のページへのリンクも同じ）。
 * 本文の縦の間（掲載元の印→作品名・作品名→日付と保存・保存→カードの下端）は 3px にそろえた（前は 4〜6px と 2px）。文字の大きさは前のまま */
.ep-main.ep-top .ep-card-row4 .ep-card-body { padding: 3px 6px 3px; }
.ep-main.ep-top .ep-card-row4 .ep-card-title { height: 24px; min-height: 0; margin: 0; overflow: hidden; -webkit-line-clamp: unset; font-size: 13px; line-height: 24px; }
.ep-main.ep-top .ep-card-row4 .ep-card-title a {
	display: block;
	overflow: hidden;
	white-space: nowrap;
	text-overflow: ellipsis;
	height: 24px;
	line-height: 24px;
}
.ep-main.ep-top .ep-card-row4 .ep-card-row.ep-card-foot { display: flex; flex-direction: row; align-items: center; justify-content: space-between; gap: 4px; margin: 0; padding-top: 3px; }
.ep-main.ep-top .ep-card-row4 .ep-card-meta { margin: 0; min-width: 0; font-size: 11px; line-height: 1.4; }
.ep-main.ep-top .ep-card-row4 .ep-card-meta .ep-tag { margin-left: 2px; }
.ep-main.ep-top .ep-card-row4 .ep-card-foot .ep-save-work {
	flex: 0 0 auto;
	width: auto;
	min-width: 44px;
	min-height: 44px;
	margin: 0;
	padding: 0 8px;
	font-size: 12px;
	gap: 3px;
}
@media (min-width: 700px) {
	.ep-main.ep-top .ep-card-row4 .ep-card-body { padding: 3px 8px 3px; }
	.ep-main.ep-top .ep-card-row4 .ep-card-title { font-size: 14px; line-height: 24px; }
	.ep-main.ep-top .ep-card-row4 .ep-card-meta { font-size: 12px; }
}

/* ---------------------------------------------------------------- 4. 0.4.31（2026-10-05・boone さんの追加指定）: 各サイトの段の間を約半分に
 * 前: 前の段のカードの下端→次の段の見出しの上端が PC・iPad 46px・スマホ 50px（.ep-section の下 28px＋見出しのまとまりの中に残った 18px＋スマホの横送りの下 4px）。
 * 後: PC・iPad 22px・スマホ 18px（横送りの下 4px を含む）。注目動画・もうすぐ発売の枠のある段は、枠の上端・下端を境界に同じ距離。
 * 段どうしの margin は重なる（大きい方）。上は 14px（PC・iPad 22px）で、検索の欄→最初の段・前の段→次の段のどちらも同じ規則。
 * トップのページ（.ep-main.ep-top）の作品の段だけ。ライブの案内・運営の案内などの段と、検索・一覧・作品のページは変えない */
.ep-main.ep-top .ep-section.ep-top-row { margin: 14px 0; }
.ep-main.ep-top .ep-top-featured,
.ep-main.ep-top .ep-feature { margin: 14px 0 18px; }
@media (min-width: 700px) {
	.ep-main.ep-top .ep-section.ep-top-row,
	.ep-main.ep-top .ep-top-featured,
	.ep-main.ep-top .ep-feature { margin: 22px 0; }
}

/* ---------------------------------------------------------------- 5. 0.4.33（2026-10-05・boone さんの採用「白とボルドー＋背景 4%」）: トップだけの上部
 * template-parts/ep/top-head.php。白を基調に、ボルドーを上端の細い線・保存の入口・検索の枠・検索のボタンに使う。上部は低くまとめる（決まった最低の高さを付けない）。
 * 背景の画像は上部の後ろの層（.ep-th-bgwrap・z-index:-1・absolute）に濃さ 4%（描く層の opacity .04。0.4.34 からキャンバス）で敷く。文字・入力欄・ボタンの親に opacity を付けない。
 * 上部の中に重なりの文脈（z-index・isolation）を作らない（検索の候補・スマホの絞り込みのシート・年齢確認の重なりの順をそのままにする）。
 * 色の目安（見本）: 本文 #29242b・ボルドー #9b2854・ボタン #99274f・淡い帯 #fbf0f4・境界 #eadde3。ページの地は #f7f6f7（下端はこの色へなじませる） */
.ep-main.ep-top .ep-th {
	--ep-th-ink: #29242b;
	--ep-th-muted: #756873;
	--ep-th-line: #eadde3;
	--ep-th-rose: #9b2854;
	--ep-th-tint: #fbf0f4;
	--ep-th-button: #99274f;
	position: relative;
	margin: -20px -12px 0;   /* 上は .ep-container の上の余白・左右はトップの左右の余白まで広げて、線と白地を端までつなぐ */
	padding: 0 12px;
	border-top: 4px solid var(--ep-th-button);
	color: var(--ep-th-ink);
}
@media (max-width: 699px) {
	.ep-main.ep-top .ep-th { margin: -16px -10px 0; padding: 0 10px; }
}
.ep-main.ep-top .ep-th-bgwrap { position: absolute; inset: 0; z-index: -1; overflow: hidden; background: #fff; pointer-events: none; }
.ep-main.ep-top .ep-th-bgwrap::after { content: ""; position: absolute; inset: 0; background: linear-gradient(to bottom, rgba(247, 246, 247, 0) 65%, #f7f6f7 100%); }
.ep-main.ep-top .ep-th-bg { position: absolute; inset: 0; display: block; width: 100%; height: 100%; max-width: none; opacity: .04; }   /* 0.4.34: キャンバス（画像は覆うように・縦は 40% の位置で描く） */
.ep-main.ep-top .ep-th-bg:not([data-ep-th-ready]) { visibility: hidden; }   /* 描く前は何も出さない（白地のまま） */

/* ロゴ（h1）と「保存した作品」 */
.ep-main.ep-top .ep-th-top { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 16px 0 14px; }
.ep-main.ep-top .ep-th-h1 { min-width: 0; margin: 0; font-size: 1rem; font-weight: 400; line-height: 1; }
.ep-main.ep-top .ep-th-h1 a.ep-logo { display: inline-block; text-decoration: none; }
.ep-main.ep-top a.ep-th-saved {
	--ep-bm-hole: var(--ep-th-tint);
	flex: none;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	gap: 7px;
	min-width: 44px;
	min-height: 44px;
	padding: 8px 12px;
	border: 1px solid var(--ep-th-line);
	border-radius: 8px;
	background: var(--ep-th-tint);
	color: var(--ep-th-rose);
	font-size: 13px;
	font-weight: 700;
	line-height: 1.2;
	text-decoration: none;
	white-space: nowrap;
}
.ep-main.ep-top a.ep-th-saved:hover,
.ep-main.ep-top a.ep-th-saved:focus-visible { border-color: var(--ep-th-rose); }
.ep-main.ep-top .ep-th-saved .ep-saved-count { background: var(--ep-th-button); }

/* 色帯 */
.ep-main.ep-top .ep-th-band { display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 2px 10px; margin: 0 -12px; padding: 9px 12px; border-top: 1px solid var(--ep-th-line); border-bottom: 1px solid var(--ep-th-line); background: rgba(251, 240, 244, .85); color: var(--ep-th-rose); }
.ep-main.ep-top .ep-th-tagline { margin: 0; font-size: 17px; font-weight: 700; line-height: 1.35; letter-spacing: .03em; }
.ep-main.ep-top .ep-th-band-r { margin: 0; font-size: 11px; line-height: 1.4; }
@media (max-width: 699px) {
	.ep-main.ep-top .ep-th-band { margin: 0 -10px; padding: 9px 10px; }
}

/* 分野の入口（PC・iPad は 7 つを横 1 列。狭い幅は 4 列＋次の段、「サイトから探す」は 2 列分） */
.ep-main.ep-top .ep-th-cats { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); gap: 7px; padding: 13px 0 11px; }
.ep-main.ep-top a.ep-th-cat {
	--cat: var(--ep-th-rose);
	display: flex;
	flex-direction: column;
	align-items: center;
	justify-content: center;
	gap: 5px;
	min-width: 0;
	min-height: 57px;
	padding: 7px 3px;
	border: 1px solid var(--ep-th-line);
	border-radius: 9px;
	background: rgba(255, 255, 255, .93);
	color: var(--ep-th-ink);
	text-decoration: none;
}
.ep-main.ep-top a.ep-th-cat:hover,
.ep-main.ep-top a.ep-th-cat:focus-visible { border-color: var(--cat); background: var(--ep-th-tint); }
.ep-main.ep-top .ep-th-cat b { overflow: hidden; max-width: 100%; font-size: 12px; font-weight: 700; line-height: 1.2; white-space: nowrap; text-overflow: ellipsis; }
.ep-main.ep-top a.ep-th-cat-anime { --cat: #376fc0; }
.ep-main.ep-top a.ep-th-cat-manga { --cat: #2b7a57; }
.ep-main.ep-top a.ep-th-cat-game { --cat: #9c6d16; }
.ep-main.ep-top a.ep-th-cat-voice { --cat: #7954a6; }
.ep-main.ep-top a.ep-th-cat-live { --cat: #bf543b; }
.ep-main.ep-top a.ep-th-cat-sites { --cat: var(--ep-th-muted); }
.ep-main.ep-top .ep-th-ico { flex: none; width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.ep-main.ep-top .ep-th-cat .ep-th-ico { color: var(--cat); }
@media (max-width: 699px) {
	.ep-main.ep-top .ep-th-cats { grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 6px; padding: 12px 0 10px; }
	.ep-main.ep-top a.ep-th-cat { min-height: 61px; padding: 7px 2px; gap: 4px; }
	.ep-main.ep-top a.ep-th-cat:last-child:nth-child(4n+3) { grid-column: span 2; flex-direction: row; gap: 8px; }   /* 7 つのときの「サイトから探す」 */
}

/* 統一の検索の欄（search-panel.php・context top）: ボルドーの枠の入力欄 → 分野のタブ → 「詳しく絞り込む」「保存した検索条件」 */
.ep-main.ep-top .ep-th .ep-sx { margin: 0; }
.ep-main.ep-top .ep-th .ep-sx-row,
.ep-main.ep-top .ep-th-search { display: flex; gap: 6px; padding: 5px; border: 2px solid var(--ep-th-rose); border-radius: 10px; background: #fff; box-shadow: 0 5px 15px rgba(145, 60, 92, .05); }
.ep-main.ep-top .ep-th .ep-sx-q,
.ep-main.ep-top .ep-th-search input[type="search"] { flex: 1 1 auto; min-width: 0; min-height: 43px; padding: 0 8px; border: 0; border-radius: 5px; background: #fff; color: var(--ep-th-ink); font-size: 16px; }
.ep-main.ep-top .ep-th .ep-sx-q::placeholder,
.ep-main.ep-top .ep-th-search input[type="search"]::placeholder { color: var(--ep-th-muted); opacity: 1; font-size: 13px; }
.ep-main.ep-top .ep-th .ep-sx-q:focus { border: 0; outline: 3px solid rgba(155, 40, 84, .28); outline-offset: 1px; }
.ep-main.ep-top .ep-th .ep-sx-go { display: inline-flex; align-items: center; justify-content: center; gap: 6px; min-height: 43px; min-width: 84px; padding: 0 14px; border: 0; border-radius: 7px; background: var(--ep-th-button); color: #fff; font-size: 15px; font-weight: 700; cursor: pointer; }
.ep-main.ep-top .ep-th .ep-sx-go .ep-th-ico { width: 17px; height: 17px; }
@media (hover: hover) {
	.ep-main.ep-top .ep-th .ep-sx-go:hover { background: #7c1f40; }
}
.ep-main.ep-top .ep-th .ep-sx-kinds { gap: 3px; margin: 8px 0 0; padding: 0 0 4px; border-bottom: 1px solid var(--ep-th-line); }
.ep-main.ep-top .ep-th .ep-sx-kind { min-height: 40px; padding: 0 12px; border: 0; border-radius: 6px; background: transparent; color: var(--ep-th-muted); font-size: 13px; font-weight: 600; }
.ep-main.ep-top .ep-th .ep-sx-kind .ep-sx-kn { display: none; }   /* 見本どおりタブに件数を出さない（件数は「詳しく絞り込む」の中にある） */
.ep-main.ep-top .ep-th .ep-sx-kind.is-current { background: var(--ep-th-tint); color: var(--ep-th-rose); box-shadow: inset 0 -2px 0 var(--ep-th-rose); }   /* 色だけでなく下線でも示す */
.ep-main.ep-top .ep-th .ep-sx-kind.is-current .ep-sx-kl::before { content: none; }
@media (hover: hover) {
	.ep-main.ep-top .ep-th .ep-sx-kind:not(.is-current):hover { background: rgba(251, 240, 244, .7); color: var(--ep-th-rose); }
}
.ep-main.ep-top .ep-th .ep-sx-tools { display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 2px 8px; min-height: 44px; margin-top: 2px; }
.ep-main.ep-top .ep-th .ep-sx-more { gap: 4px 6px; min-height: 40px; padding: 4px 2px; border: 0; border-radius: 6px; background: transparent; color: var(--ep-th-rose); font-size: 13px; font-weight: 700; }
.ep-main.ep-top .ep-th .ep-sx-panel[open] > .ep-sx-more { padding: 4px 8px; background: var(--ep-th-tint); color: var(--ep-th-rose); }
.ep-main.ep-top .ep-th .ep-sx-oc { display: none; }
.ep-main.ep-top .ep-th .ep-sx-more::before,
.ep-main.ep-top .ep-th .ep-sx-savedbtn::before { content: ""; flex: none; width: 15px; height: 15px; background: currentColor; -webkit-mask: var(--ep-th-mask) center / contain no-repeat; mask: var(--ep-th-mask) center / contain no-repeat; }
.ep-main.ep-top .ep-th .ep-sx-more { --ep-th-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23000' stroke-width='2' stroke-linecap='round'%3E%3Cpath d='M4 6h9M17 6h3M4 12h3M11 12h9M4 18h11M19 18h1'/%3E%3Ccircle cx='15' cy='6' r='2'/%3E%3Ccircle cx='9' cy='12' r='2'/%3E%3Ccircle cx='17' cy='18' r='2'/%3E%3C/svg%3E"); }
.ep-main.ep-top .ep-th .ep-sx-savedbtn { --ep-th-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23000' stroke-width='2' stroke-linejoin='round'%3E%3Cpath d='M6 3.5h12v17l-6-4.2-6 4.2z'/%3E%3C/svg%3E"); display: inline-flex; align-items: center; gap: 6px; min-height: 40px; padding: 4px 2px; border: 0; border-radius: 6px; background: transparent; color: var(--ep-th-muted); font-size: 13px; font-weight: 400; }
.ep-main.ep-top .ep-th .ep-sx-savedbtn[aria-expanded="true"] { padding: 4px 8px; background: var(--ep-th-tint); color: var(--ep-th-rose); font-weight: 700; }
@media (max-width: 699px) {
	.ep-main.ep-top .ep-th .ep-sx-savedbtn { position: static; margin: 0 0 0 auto; }
}

/* 年齢の表記・解説記事への入口 */
.ep-main.ep-top .ep-th-note { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 2px 12px; margin: 0; padding: 0 0 10px; color: var(--ep-th-muted); font-size: 11px; line-height: 1.6; }
.ep-main.ep-top .ep-th-note a.ep-th-guides { color: var(--ep-th-rose); font-weight: 700; text-decoration: underline; text-underline-offset: 2px; }

@media (max-width: 560px) {
	.ep-main.ep-top .ep-th-top { gap: 8px; padding: 14px 0 12px; }
	.ep-main.ep-top a.ep-th-saved { gap: 5px; padding: 8px 9px; }
	.ep-main.ep-top .ep-th-saved-t { position: absolute; width: 1px; height: 1px; margin: -1px; padding: 0; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }   /* 文字は読み上げに残す */
	.ep-main.ep-top .ep-th-band { display: block; }
	.ep-main.ep-top .ep-th-band-r { margin-top: 1px; }
	.ep-main.ep-top .ep-th .ep-sx-go { min-width: 65px; padding: 0 10px; }
	.ep-main.ep-top .ep-th .ep-sx-go .ep-th-ico { display: none; }
	.ep-main.ep-top .ep-th .ep-sx-q::placeholder { font-size: 12px; }
	.ep-main.ep-top .ep-th .ep-sx-kind { min-height: 44px; padding: 0 8px; }
	.ep-main.ep-top .ep-th .ep-sx-more,
	.ep-main.ep-top .ep-th .ep-sx-savedbtn { min-height: 44px; }
}
@media (max-width: 370px) {
	.ep-main.ep-top .ep-th-tagline { font-size: 16px; }
	.ep-main.ep-top .ep-th .ep-sx-q::placeholder { font-size: 11px; }
	.ep-main.ep-top .ep-th .ep-sx-kinds { gap: 0; }
	.ep-main.ep-top .ep-th .ep-sx-kind { padding: 0 7px; }
}

/* ---------------------------------------------------------------- 0.4.46（Core 0.5.57・R37）: トップの 1 行のカード（もうすぐ発売・各サイトの段）の「サンプル」
 * boone さんの赤枠（日付・発売前と保存の間の空き）: 日付・発売前は左、サンプルと保存は右の操作のまとまり。入らない幅では、まとまりごと次の行へ（カードの高さは入る幅では変えない） */
.ep-main.ep-top .ep-card-row4 .ep-card-row.ep-card-foot { flex-wrap: wrap; row-gap: 3px; }
.ep-main.ep-top .ep-card-row4 .ep-card-acts { display: flex; flex: 0 0 auto; align-items: center; gap: 4px; margin-left: auto; }
.ep-main.ep-top .ep-card-row4 .ep-card-acts .ep-card-smp-btn { min-width: 44px; min-height: 44px; padding: 0 8px; }
/* wave17: homepage-only entrances and image shelves; existing links and data stay in place. */
.ep-main.ep-top.ep-top-refresh .ep-th-top { padding: 10px 0; }
.ep-main.ep-top.ep-top-refresh .ep-th-band { display: none; }
.ep-main.ep-top.ep-top-refresh .ep-th-cats { grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 6px; padding: 10px 0; }
.ep-main.ep-top.ep-top-refresh a.ep-th-cat { min-height: 48px; padding: 6px 3px; gap: 3px; }
.ep-main.ep-top.ep-top-refresh .ep-th-cat b { white-space: normal; overflow-wrap: anywhere; font-size: 12px; }
.ep-main.ep-top.ep-top-refresh .ep-th-cat-sale,
.ep-main.ep-top.ep-top-refresh .ep-th-cat-ranking { border-color: #982b51; background: #fbf0f4; }
.ep-main.ep-top.ep-top-refresh .ep-top-fold { margin: 10px 0; border: 1px solid #e7dce2; border-radius: 8px; background: #fff; }
.ep-main.ep-top.ep-top-refresh .ep-top-fold > summary { min-height: 44px; padding: 10px 12px; font-weight: 700; cursor: pointer; }
.ep-main.ep-top.ep-top-refresh .ep-top-fold[open] > :not(summary) { margin: 0 10px 10px; }
.ep-main.ep-top.ep-top-refresh .ep-th-help { margin: 8px 0 12px; }
.ep-main.ep-top.ep-top-refresh .ep-row4,
.ep-main.ep-top.ep-top-refresh .ep-featured-grid.ep-row4,
.ep-main.ep-top.ep-top-refresh .ep-growth-grid,
.ep-main.ep-top.ep-top-refresh .ep-live-briefs,
.ep-main.ep-top.ep-top-refresh .ep-tk-grid {
	display: grid;
	grid-auto-flow: row;
	grid-auto-columns: auto;
	gap: 12px 8px;
	overflow: visible;
	scroll-snap-type: none;
}
/* 作品・紹介棚は2列。案内棚は実カード数で末尾の空列を畳む。 */
.ep-main.ep-top.ep-top-refresh .ep-row4,
.ep-main.ep-top.ep-top-refresh .ep-featured-grid.ep-row4,
.ep-main.ep-top.ep-top-refresh .ep-growth-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.ep-main.ep-top.ep-top-refresh .ep-live-briefs,
.ep-main.ep-top.ep-top-refresh .ep-tk-grid { grid-template-columns: repeat(auto-fit, minmax(calc((100% - 10px) / 2), 1fr)); }
.ep-main.ep-top.ep-top-refresh .ep-top-live .ep-live-briefs + .ep-live-briefs { margin-top: 10px; }
.ep-main.ep-top.ep-top-refresh .ep-row4 > .ep-card { min-width: 0; }
.ep-main.ep-top.ep-top-refresh .ep-card-row4 .ep-card-title { height: auto; min-height: 3em; margin: 0; line-height: 1.5; }
.ep-main.ep-top.ep-top-refresh .ep-card-row4 .ep-card-title a,
.ep-main.ep-top.ep-top-refresh .ep-growth-card .ep-gd-card-t {
	display: -webkit-box;
	-webkit-box-orient: vertical;
	-webkit-line-clamp: 2;
	height: auto;
	max-height: 3em;
	line-height: 1.5;
	white-space: normal;
	overflow: hidden;
	overflow-wrap: anywhere;
}
.ep-main.ep-top.ep-top-refresh .ep-card-top .ep-card-line { display: none; }
.ep-main.ep-top.ep-top-refresh .ep-top-card-price { margin: 5px 0; padding: 4px 6px; border-radius: 5px; background: #fbf0f4; font-size: 12px; line-height: 1.5; white-space: normal; overflow: visible; overflow-wrap: anywhere; }
.ep-main.ep-top.ep-top-refresh .ep-top-card-options { margin: 4px 0 0; border-top: 1px solid #eee5e9; }
.ep-main.ep-top.ep-top-refresh .ep-top-card-options > summary { min-height: 36px; padding: 7px 0; font-size: 11px; cursor: pointer; }
.ep-main.ep-top.ep-top-refresh .ep-top-kind-label { display: inline-block; margin: 0 7px 3px 0; padding: 3px 7px; border-radius: 5px; background: #982b51; color: #fff; font-size: 12px; line-height: 1.4; vertical-align: middle; }
.ep-main.ep-top.ep-top-refresh .ep-top-kind-group { margin: 24px 0; padding: 12px 0; border-top: 3px solid #982b51; }
.ep-main.ep-top.ep-top-refresh .ep-top-kind-title { margin: 0 0 12px; font-size: 24px; color: #6d1c39; }
.ep-main.ep-top.ep-top-refresh .ep-top-kind-group .ep-top-kind-label { display: none; }
.ep-main.ep-top.ep-top-refresh .ep-live-briefs[data-count] > .ep-live-brief { grid-column: auto; min-width: 0; }
.ep-main.ep-top.ep-top-refresh .ep-tk-grid > .ep-tk-item { min-width: 0; }
.ep-main.ep-top.ep-top-refresh .ep-tk-main { grid-template-columns: minmax(0, 1fr); }
.ep-main.ep-top.ep-top-refresh .ep-tk-imgs { grid-row: auto; }
.ep-main.ep-top.ep-top-refresh .ep-tk-head { flex-direction: column; align-items: flex-start; gap: 2px; }
.ep-main.ep-top.ep-top-refresh .ep-tk-name { font-size: 18px; }
.ep-main.ep-top.ep-top-refresh .ep-tk-details { background: rgba(255, 255, 255, .04); color: #f4ebef; }
.ep-main.ep-top.ep-top-refresh .ep-tk-details > summary { font-size: 12px; }
.ep-main.ep-top.ep-top-refresh .ep-saletop-list[data-count]:not([hidden]) {
	display: grid;
	grid-template-columns: repeat(auto-fit, minmax(calc((100% - 10px) / 2), 1fr));
	grid-auto-flow: row;
	gap: 12px 8px;
	overflow: visible;
	scroll-snap-type: none;
}
.ep-main.ep-top.ep-top-refresh .ep-saletop-list::after { content: none; }
.ep-main.ep-top.ep-top-refresh .ep-saletop-list[data-count] > .ep-sale-card:not([hidden]) { display: block; grid-column: auto; min-width: 0; width: auto; }
.ep-main.ep-top.ep-top-refresh .ep-saletop-list[data-count] > .ep-sale-card .ep-sale-banner { height: auto; min-height: 44px; }
.ep-main.ep-top.ep-top-refresh .ep-sale-banner img { height: auto; object-fit: contain; }
.ep-main.ep-top.ep-top-refresh .ep-sale-name,
.ep-main.ep-top.ep-top-refresh .ep-sale-condition,
.ep-main.ep-top.ep-top-refresh .ep-sale-period { overflow-wrap: anywhere; }
.ep-main.ep-top.ep-top-refresh .ep-sale-num { font-size: clamp(26px, 5vw, 38px); }
.ep-main.ep-top.ep-top-refresh .ep-sale-text { font-size: 18px; }
.ep-main.ep-top.ep-top-refresh .ep-saletop-nav { display: none; }
@media (min-width: 1000px) {
	.ep-main.ep-top.ep-top-refresh .ep-th-cats { grid-template-columns: repeat(8, minmax(0, 1fr)); }
	.ep-main.ep-top.ep-top-refresh .ep-row4,
	.ep-main.ep-top.ep-top-refresh .ep-featured-grid.ep-row4 { grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 14px 12px; }
	.ep-main.ep-top.ep-top-refresh .ep-live-briefs,
	.ep-main.ep-top.ep-top-refresh .ep-tk-grid,
	.ep-main.ep-top.ep-top-refresh .ep-saletop-list[data-count]:not([hidden]) { grid-template-columns: repeat(auto-fit, minmax(calc((100% - 36px) / 4), 1fr)); gap: 14px 12px; }
}

/* wave18: top-only compact spacing; preserve prices, disclosures and every existing link. */
.ep-main.ep-top.ep-top-refresh .ep-container { padding-bottom: 12px; }
.ep-main.ep-top.ep-top-refresh .ep-row4,
.ep-main.ep-top.ep-top-refresh .ep-featured-grid.ep-row4,
.ep-main.ep-top.ep-top-refresh .ep-growth-grid,
.ep-main.ep-top.ep-top-refresh .ep-live-briefs,
.ep-main.ep-top.ep-top-refresh .ep-tk-grid,
.ep-main.ep-top.ep-top-refresh .ep-saletop-list[data-count]:not([hidden]) { height: auto; min-height: 0; align-items: start; align-content: start; grid-auto-rows: auto; gap: 10px; }
.ep-main.ep-top.ep-top-refresh .ep-row4 > .ep-card,
.ep-main.ep-top.ep-top-refresh .ep-growth .ep-growth-card,
.ep-main.ep-top.ep-top-refresh .ep-live-brief,
.ep-main.ep-top.ep-top-refresh .ep-tk-item,
.ep-main.ep-top.ep-top-refresh .ep-sale-card { height: auto; min-height: 0; align-self: start; }
/* 内容を持つ外枠だけを自然高にする。画像・二行見出し・操作ボタンの寸法は維持。 */
.ep-main.ep-top.ep-top-refresh :is(.ep-section, .ep-feature, .ep-top-kind-group, .ep-top-kinds, .ep-dv-entry-card, .ep-saletop, .ep-growth-block) { height: auto; min-height: 0; }
.ep-main.ep-top.ep-top-refresh .ep-dv-entry-no-image { display: block; }
.ep-main.ep-top.ep-top-refresh .ep-card-row4 .ep-thumb { aspect-ratio: 4 / 3; }
.ep-main.ep-top.ep-top-refresh .ep-card-row4 .ep-thumb img { object-fit: contain; }
.ep-main.ep-top.ep-top-refresh .ep-card-row4 .ep-card-title { height: 3em; min-height: 3em; max-height: 3em; }
.ep-main.ep-top.ep-top-refresh .ep-card-row4 .ep-card-title:has(> a:empty) { height: 0; min-height: 0; max-height: 0; }
.ep-main.ep-top.ep-top-refresh .ep-card-row4 .ep-card-body { flex: 0 0 auto; padding: 4px 6px; }
.ep-main.ep-top.ep-top-refresh .ep-section.ep-top-row,
.ep-main.ep-top.ep-top-refresh .ep-top-featured,
.ep-main.ep-top.ep-top-refresh .ep-feature,
.ep-main.ep-top.ep-top-refresh .ep-growth,
.ep-main.ep-top.ep-top-refresh .ep-top-live { margin: 12px 0; }
.ep-main.ep-top.ep-top-refresh .ep-top-kind-group { margin: 12px 0; padding: 8px 0 0; }
.ep-main.ep-top.ep-top-refresh .ep-top-kind-group > .ep-top-row:last-child { margin-bottom: 0; }
.ep-main.ep-top.ep-top-refresh .ep-top-kind-title { margin-bottom: 8px; font-size: 22px; }
/* 共通見出しの30px/22px上marginを、段の間隔や分類枠のpaddingと重ねない。 */
.ep-main.ep-top.ep-top-refresh .ep-growth-title,
.ep-main.ep-top.ep-top-refresh .ep-top-live > .ep-h2,
.ep-main.ep-top.ep-top-refresh .ep-browse > .ep-h2,
.ep-main.ep-top.ep-top-refresh .ep-top-more > .ep-h2,
.ep-main.ep-top.ep-top-refresh .ep-browse-box > .ep-h3 { margin-top: 0; }
.ep-main.ep-top.ep-top-refresh .ep-growth-block + .ep-growth-block { margin-top: 12px; }
.ep-main.ep-top.ep-top-refresh .ep-growth-note { margin-bottom: 8px; }
.ep-main.ep-top.ep-top-refresh .ep-top-kinds { margin: 12px 0; padding: 10px; }
.ep-main.ep-top.ep-top-refresh .ep-saletop { margin: 12px 0; padding: 12px; }
.ep-main.ep-top.ep-top-refresh .ep-saletop-head { margin-bottom: 12px; }
.ep-main.ep-top.ep-top-refresh .ep-top-fold { margin: 6px 0; }
.ep-main.ep-top.ep-top-refresh .ep-site-foot { margin-top: 12px; padding-top: 12px; padding-bottom: 12px; }
.ep-main.ep-top.ep-top-refresh .ep-row4:empty,
.ep-main.ep-top.ep-top-refresh .ep-growth-grid:empty,
.ep-main.ep-top.ep-top-refresh .ep-top-card-price:empty { display: none !important; min-height: 0; margin: 0; padding: 0; border: 0; }
.ep-main.ep-top.ep-top-refresh a.ep-top-direct { display: flex; align-items: center; justify-content: center; gap: 5px; min-height: 44px; box-sizing: border-box; margin: 5px 0 0; padding: 6px; border: 1px solid #7a1d40; border-radius: 6px; background: #982b51; color: #fff; font-size: 13px; font-weight: 700; line-height: 1.4; text-align: center; text-decoration: none; overflow-wrap: anywhere; }
.ep-main.ep-top.ep-top-refresh .ep-top-direct .ep-pr { flex: 0 0 auto; margin: 0; padding: 1px 3px; border: 1px solid currentColor; color: #fff; background: transparent; font-size: 10px; }
.ep-main.ep-top.ep-top-refresh a.ep-top-direct:hover { background: #7a1d40; color: #fff; }
.ep-main.ep-top.ep-top-refresh a.ep-top-direct:focus-visible { outline: 3px solid #b27b12; outline-offset: 2px; }
@supports not (aspect-ratio: 1 / 1) {
	.ep-main.ep-top.ep-top-refresh .ep-card-row4 .ep-thumb { height: 0; padding-top: 75%; }
}
@media (min-width: 1000px) {
	.ep-main.ep-top.ep-top-refresh .ep-row4,
	.ep-main.ep-top.ep-top-refresh .ep-featured-grid.ep-row4,
	.ep-main.ep-top.ep-top-refresh .ep-growth-grid,
	.ep-main.ep-top.ep-top-refresh .ep-live-briefs,
	.ep-main.ep-top.ep-top-refresh .ep-tk-grid,
	.ep-main.ep-top.ep-top-refresh .ep-saletop-list[data-count]:not([hidden]) { gap: 12px; }
}

/* wave20 compact shelves; wave23 uses the full container width with fixed column counts. */
.ep-main.ep-top.ep-top-refresh .ep-row4,
.ep-main.ep-top.ep-top-refresh .ep-featured-grid.ep-row4,
.ep-main.ep-top.ep-top-refresh .ep-growth-grid,
.ep-main.ep-top.ep-top-refresh .ep-top-ranking .ep-top-ranking-grid {
	display: grid;
	box-sizing: border-box;
	width: 100%;
	max-width: none !important;
	min-width: 0;
	grid-template-columns: repeat(2, minmax(0, 1fr));
	grid-auto-flow: row;
	grid-auto-rows: auto;
	justify-content: stretch;
	justify-items: stretch;
	align-items: start;
	align-content: start;
	gap: 10px;
}
.ep-main.ep-top.ep-top-refresh .ep-row4 > .ep-card,
.ep-main.ep-top.ep-top-refresh .ep-growth .ep-growth-card,
.ep-main.ep-top.ep-top-refresh .ep-top-ranking .ep-top-ranking-card {
	box-sizing: border-box;
	width: 100%;
	max-width: none !important;
	min-width: 0;
	height: auto;
	min-height: 0;
	grid-column: auto;
}
.ep-main.ep-top.ep-top-refresh .ep-card-row4 .ep-thumb { max-height: 150px; }
.ep-main.ep-top.ep-top-refresh .ep-card-row4 .ep-card-title { font-size: 13px; }
.ep-main.ep-top.ep-top-refresh .ep-top-ranking .ep-top-ranking-card { padding: 6px; gap: 4px; }
.ep-main.ep-top.ep-top-refresh .ep-top-ranking-card .ep-gd-card-imgs {
	width: 100%;
	min-width: 0;
	min-height: 0;
	max-height: 150px;
	aspect-ratio: 4 / 3;
	grid-template-rows: minmax(0, 1fr);
	gap: 4px;
	overflow: hidden;
}
.ep-main.ep-top.ep-top-refresh .ep-top-ranking-card .ep-tile-img {
	min-height: 0;
	height: 100%;
	max-height: 150px;
	aspect-ratio: auto;
}
.ep-main.ep-top.ep-top-refresh .ep-top-ranking-card .ep-tile-img img { width: 100%; height: 100%; max-height: 150px; object-fit: contain; }
.ep-main.ep-top.ep-top-refresh .ep-top-ranking-card .ep-gd-card-t {
	display: -webkit-box;
	-webkit-box-orient: vertical;
	-webkit-line-clamp: 2;
	font-size: 13px;
	line-height: 1.5;
	height: 3em;
	min-height: 3em;
	max-height: 3em;
	margin: 0;
	overflow: hidden;
	overflow-wrap: anywhere;
}
.ep-main.ep-top.ep-top-refresh .ep-top-ranking-card .ep-growth-rank,
.ep-main.ep-top.ep-top-refresh .ep-top-ranking-card .ep-tile-m {
	display: block;
	font-size: 12px;
	line-height: 1.4;
	min-width: 0;
	max-width: 100%;
	white-space: nowrap;
	overflow: hidden;
	text-overflow: ellipsis;
}
.ep-main.ep-top.ep-top-refresh .ep-top-ranking .ep-growth-note { font-size: 12px; line-height: 1.4; margin-bottom: 6px; }
.ep-main.ep-top.ep-top-refresh a.ep-top-ranking-entry {
	box-sizing: border-box;
	min-height: 44px;
	max-height: 56px;
	font-size: 13px;
	line-height: 1.35;
}
.ep-main.ep-top.ep-top-refresh a.ep-top-ranking-entry:not(.ep-th-cat) {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	flex: 0 1 auto;
	height: 44px;
	max-width: 100%;
	padding: 5px 10px;
	border: 1px solid #e7dce2;
	border-radius: 999px;
	white-space: normal;
	overflow-wrap: anywhere;
}
.ep-main.ep-top.ep-top-refresh a.ep-th-cat.ep-top-ranking-entry { height: 52px; padding: 4px 3px; gap: 2px; }
.ep-main.ep-top.ep-top-refresh a.ep-th-cat.ep-top-ranking-entry b { font-size: 12px; line-height: 1.35; }
.ep-main.ep-top.ep-top-refresh a.ep-th-cat.ep-top-ranking-entry .ep-th-ico { width: 18px; height: 18px; }
@media (min-width: 768px) {
	.ep-main.ep-top.ep-top-refresh .ep-row4,
	.ep-main.ep-top.ep-top-refresh .ep-featured-grid.ep-row4,
	.ep-main.ep-top.ep-top-refresh .ep-growth-grid,
	.ep-main.ep-top.ep-top-refresh .ep-top-ranking .ep-top-ranking-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; }
}
/* wave22 SOKMIL shelf; wave23 fluid columns retain the compact vertical dimensions. */
.ep-main.ep-top.ep-top-refresh .ep-sokmil-focus-top {
  margin: 10px 0; padding: 8px; height: auto; min-height: 0;
  border: 1px solid #c46b27; border-radius: 7px; background: #fff9f2;
}
.ep-main.ep-top.ep-top-refresh .ep-sokmil-focus-top > h2 {
  margin: 0 0 6px; padding: 0; font-size: 16px; line-height: 1.4;
}
.ep-main.ep-top.ep-top-refresh .ep-sokmil-focus-grid {
  display: grid; grid-template-columns: repeat(2,minmax(0,1fr));
  align-items: start; align-content: start; justify-content: stretch; justify-items: stretch; gap: 10px;
  box-sizing: border-box; width: 100%; max-width: none !important; min-width: 0;
  height: auto; min-height: 0; margin: 0; padding: 0;
}
.ep-main.ep-top.ep-top-refresh .ep-sokmil-focus-card {
  display: grid; gap: 4px; width: 100%; max-width: none !important; min-width: 0;
  box-sizing: border-box; height: auto; min-height: 0; margin: 0; padding: 4px;
  border: 1px solid #e2cebb; border-radius: 5px; background: #fff;
}
.ep-main.ep-top.ep-top-refresh .ep-sokmil-focus-info {
  display: grid; gap: 4px; min-width: 0; margin: 0; padding: 0; color: inherit; text-decoration: none;
}
.ep-main.ep-top.ep-top-refresh .ep-sokmil-focus-thumb {
  display: block; width: 100%; aspect-ratio: 4 / 3; max-height: 130px; min-height: 0;
  margin: 0; padding: 0; overflow: hidden; background: #f4f2f3;
}
.ep-main.ep-top.ep-top-refresh .ep-sokmil-focus-thumb img {
  display: block; width: 100%; height: 100%; max-height: 130px; margin: 0; padding: 0; object-fit: contain;
}
.ep-main.ep-top.ep-top-refresh .ep-sokmil-focus-title {
  display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 2;
  height: 39px; min-height: 0; margin: 0; padding: 0; overflow: hidden;
  font-size: 13px; line-height: 19.5px; font-weight: 600; overflow-wrap: anywhere;
}
.ep-main.ep-top.ep-top-refresh .ep-sokmil-focus-cta {
  display: flex; align-items: center; justify-content: center; gap: 3px; min-width: 0;
  min-height: 36px; margin: 0; padding: 3px; box-sizing: border-box;
  border: 1px solid #a64b16; border-radius: 5px; background: linear-gradient(110deg,#b32c29,#ad4b00);
  color: #fff; text-decoration: none; font-size: 12px; line-height: 16px; font-weight: 700; white-space: normal;
}
.ep-main.ep-top.ep-top-refresh .ep-sokmil-focus-cta .ep-pr { margin: 0; padding: 0 2px; font-size: 10px; color: #fff; border-color: currentColor; flex-shrink: 0; }
.ep-main.ep-top.ep-top-refresh .ep-sokmil-focus-card a:focus-visible { outline: 2px solid #8a1f3d; outline-offset: 1px; }
@media (min-width: 768px) {
  .ep-main.ep-top.ep-top-refresh .ep-sokmil-focus-grid { grid-template-columns: repeat(4,minmax(0,1fr)); gap: 12px; }
}

/* wave23: one full-width top sale bar; additional campaigns scroll within the same row. */
.ep-main.ep-top .ep-sale-direct-sokmil-top {
  box-sizing: border-box; width: 100%; max-width: none; min-width: 0; height: 56px;
  margin: 0; padding: 3px; border: 1px solid #b36b21; border-radius: 8px; background: #fff2d9;
}
.ep-main.ep-top .ep-sale-direct-sokmil-top .ep-sale-direct-items {
  box-sizing: border-box; width: 100%; min-width: 0; height: 48px; gap: 6px;
  flex-wrap: nowrap; align-items: center; overflow-x: auto; overflow-y: hidden;
  overscroll-behavior-x: contain; scrollbar-width: none;
}
.ep-main.ep-top .ep-sale-direct-sokmil-top .ep-sale-direct-items::-webkit-scrollbar { display: none; }
.ep-main.ep-top .ep-sale-direct-sokmil-top .ep-sale-direct-card {
  flex: 1 0 auto; width: auto; max-width: none; min-width: 0; height: 48px; margin: 0;
}
.ep-main.ep-top .ep-sale-direct-sokmil-top .ep-sale-direct-link {
  height: 48px; min-height: 48px; max-height: 48px; white-space: nowrap; overflow-wrap: normal;
}
.ep-main.ep-top .ep-sale-direct-sokmil-top .ep-sale-direct-link:focus-visible { outline-offset: -3px; }
