/* Dogabit 모바일 보정 — 767px 이하에만 적용. 데스크탑은 그대로. 테마 파일은 건드리지 않음 */
@media (max-width: 767px) {

	/* ── 1. 상단 바: 아래로 내리면 숨고, 위로 올리면 다시 나타남 ── */
	body.dgb-m.dgb-m-stuck { padding-top: var(--dgb-m-h, 60px); }
	body.dgb-m.dgb-m-stuck #site-header {
		position: fixed !important;
		top: 0; left: 0; right: 0;
		background: rgba(255, 255, 255, .94) !important;
		-webkit-backdrop-filter: saturate(180%) blur(12px);
		backdrop-filter: saturate(180%) blur(12px);
		box-shadow: 0 1px 0 rgba(0, 0, 0, .06);
		transform: translateY(-100%);
		transition: transform .22s ease;
	}
	body.dgb-m.dgb-m-stuck.dgb-m-show #site-header,
	body.dgb-m.dgb-m-open #site-header { transform: none; }
	/* WP 관리자 바(로그인 상태에서만 보임): 601~767px 에서는 화면에 고정이라 그 아래에 붙이고,
	   600px 이하에서는 관리자 바가 같이 스크롤되어 사라지므로 맨 위(0)에 붙인다 */
	body.dgb-m.dgb-m-stuck.admin-bar #site-header { top: 46px; }

	/* ── 2. 메뉴 버튼: 누르는 영역 48×48 ── */
	#site-header .hamburger {
		box-sizing: content-box;
		padding: 12px 10px !important;
		/* 테마가 원래 위로 12px 당겨 두므로(margin-top:-12px) 여백 12px를 더해 -24px. 오른쪽 10px도 상쇄 → 아이콘 위치는 그대로, 누르는 영역만 넓어짐 */
		margin: -24px -10px 0 0 !important;
		-webkit-tap-highlight-color: transparent;
		touch-action: manipulation;
	}

	/* ── 3. 메뉴: 상단 바 아래 전체 화면, 큰 글자, 바로 열림 ── */
	html body.dgb-m #slide-panel-holder #slide-panel {
		position: fixed !important;
		top: 0 !important; left: 0 !important; right: 0 !important; bottom: 0 !important;
		height: auto !important;
		z-index: 553 !important; /* 테마 상단 바(554) 바로 아래 → X 버튼은 계속 보임 */
		background: #fff !important;
		transform: none !important;
		overflow-y: auto;
	}
	html body.dgb-m #slide-panel-holder #slide-panel .hidden-scroll,
	html body.dgb-m #slide-panel-holder #slide-panel .inner { height: auto !important; background: transparent !important; }
	html body.dgb-m #slide-panel-holder #slide-panel .inner { padding: calc(var(--dgb-m-h, 60px) + 40px) 28px 48px !important; }
	html body.dgb-m.admin-bar #slide-panel-holder #slide-panel .inner { padding-top: calc(var(--dgb-m-h, 60px) + 86px) !important; }
	body.dgb-m #slide-mobile-menu ul { margin: 0 !important; padding: 0 !important; list-style: none; }
	body.dgb-m #slide-mobile-menu li { border: 0 !important; background: transparent !important; }
	body.dgb-m #slide-mobile-menu a {
		display: block;
		padding: 12px 0 !important;
		font-size: 40px !important;
		font-weight: 700 !important;
		line-height: 1.1 !important;
		letter-spacing: -0.03em !important;
		color: #111 !important;
		background: transparent !important;
		border: 0 !important;
		opacity: 0;
		transform: translateY(14px);
		transition: opacity .28s ease, transform .28s cubic-bezier(.2, .7, .2, 1);
		touch-action: manipulation;
		-webkit-tap-highlight-color: transparent;
	}
	body.dgb-m #slide-mobile-menu a:active { color: #888 !important; }
	body.dgb-m.dgb-m-open #slide-mobile-menu a { opacity: 1; transform: none; }
	body.dgb-m.dgb-m-open #slide-mobile-menu li:nth-child(2) a { transition-delay: .04s; }
	body.dgb-m.dgb-m-open #slide-mobile-menu li:nth-child(3) a { transition-delay: .08s; }
	body.dgb-m.dgb-m-open #slide-mobile-menu li:nth-child(4) a { transition-delay: .12s; }
	body.dgb-m.dgb-m-open #slide-mobile-menu li:nth-child(5) a { transition-delay: .16s; }
	body.dgb-m-open { overflow: hidden; }

	/* ── 4. 작업물 그리드: 제목을 항상 보이게 (터치에는 마우스 올리기가 없음) ── */
	.thumbs .project .details .text {
		transform: none !important;
		opacity: 1 !important;
		top: auto !important;
		bottom: 0 !important;
		padding: 0 18px 16px !important;
	}
	.thumbs .project .details {
		background: linear-gradient(to top, rgba(0,0,0,.72) 0%, rgba(0,0,0,.35) 38%, rgba(0,0,0,0) 62%) !important;
		border: 0 !important;
	}
	.thumbs .project .overlay { opacity: 0 !important; }
	.thumbs .project img { transform: none !important; }
	.thumbs .project .entry-title { font-size: 19px !important; line-height: 1.3 !important; font-weight: 700 !important; text-wrap: balance; }
	.thumbs .project .skills { font-size: 12px !important; opacity: .85; letter-spacing: .04em; }
	.thumbs .project a { -webkit-tap-highlight-color: transparent; touch-action: manipulation; }
	.thumbs .project .inside { transition: transform .12s ease; }
	.thumbs .project:active .inside { transform: scale(.985); }

	/* ── 5. 작업물 페이지 이전/다음: 글자·색·굵기는 원래 디자인 그대로 두고
	   누르는 영역만 48px로 (원래도 44px라 글자는 작아도 터치는 가능했음) ── */
	body.dgb-pl.dgb-pl-mobile .dgb-pl-nav a {
		min-height: 48px !important;
		min-width: 48px;
		touch-action: manipulation;
		-webkit-tap-highlight-color: transparent;
	}
}
@media (max-width: 600px) {
	body.dgb-m.dgb-m-stuck.admin-bar #site-header { top: 0; }
}
