/**
 * Ohanashi Shell - ヘッダー / タブ / 下部ナビ / レイアウト
 *
 * v1.1.0:
 *   - SVG アイコン対応（emoji 廃止）
 *   - グラスモーフィズム風ヘッダー
 *   - タブのアクティブ表現を強化（影 + サイズ感）
 */

.oh-header {
	position: sticky;
	top: 0;
	z-index: var(--oh-z-header);
	background: var(--oh-bg-glass);
	backdrop-filter: saturate(180%) blur(14px);
	-webkit-backdrop-filter: saturate(180%) blur(14px);
	border-bottom: 1px solid var(--oh-border-soft);
	padding: 10px var(--oh-space-4);
	display: flex;
	align-items: center;
	gap: var(--oh-space-3);
	box-shadow: var(--oh-shadow-sm);
}

.oh-header__logo {
	display: flex;
	align-items: center;
	gap: var(--oh-space-2);
	color: var(--oh-text-primary);
	padding: 4px 8px;
	border-radius: var(--oh-r-md);
	transition: background 0.15s;
}
.oh-header__logo:hover { background: var(--oh-border-soft); }

.oh-header__brand {
	font-weight: 800;
	font-size: 18px;
	background: var(--oh-gradient-violet-blue);
	-webkit-background-clip: text;
	background-clip: text;
	-webkit-text-fill-color: transparent;
	letter-spacing: -0.01em;
}

.oh-header__search {
	flex: 1;
	max-width: 520px;
	position: relative;
	display: flex;
	align-items: center;
}

.oh-header__search-icon {
	position: absolute;
	left: 12px;
	top: 50%;
	transform: translateY(-50%);
	color: var(--oh-text-tertiary);
	pointer-events: none;
	display: inline-flex;
}

.oh-header__search input {
	width: 100%;
	border: 1px solid var(--oh-border-soft);
	background: var(--oh-bg-app);
	border-radius: var(--oh-r-full);
	padding: 9px 14px 9px 36px;
	font-size: 14px;
	outline: none;
	transition: border-color 0.15s, background 0.15s, box-shadow 0.15s;
}

.oh-header__search input:focus {
	border-color: var(--oh-primary);
	background: var(--oh-bg-card);
	box-shadow: 0 0 0 4px rgba(91, 169, 240, 0.15);
}

.oh-header__actions {
	display: flex;
	align-items: center;
	gap: var(--oh-space-2);
}

.oh-header__action {
	min-width: 38px;
	height: 38px;
	padding: 0 10px;
	border-radius: var(--oh-r-full);
	background: var(--oh-bg-app);
	display: inline-flex;
	align-items: center;
	justify-content: center;
	gap: 6px;
	cursor: pointer;
	color: var(--oh-text-secondary);
	border: 1px solid var(--oh-border-soft);
	position: relative;
	transition: all 0.15s;
	font-weight: 600;
	font-size: 13px;
}

.oh-header__action:hover {
	background: var(--oh-bg-card);
	border-color: var(--oh-border-strong);
	color: var(--oh-text-primary);
	transform: translateY(-1px);
}

.oh-header__action--primary {
	background: var(--oh-gradient-violet-blue);
	color: #fff;
	border-color: transparent;
	box-shadow: var(--oh-shadow-pop);
}
.oh-header__action--primary:hover {
	color: #fff;
	background: var(--oh-gradient-violet-blue);
	filter: brightness(1.06);
	border-color: transparent;
}

.oh-header__icon { display: inline-flex; align-items: center; }

.oh-header__action-label { display: none; }
@media (min-width: 768px) { .oh-header__action-label { display: inline; } }

.oh-header__action[data-badge]::after {
	content: attr(data-badge);
	position: absolute;
	top: -2px;
	right: -2px;
	min-width: 18px;
	height: 18px;
	padding: 0 5px;
	border-radius: var(--oh-r-full);
	background: var(--oh-danger);
	color: #fff;
	font-size: 10px;
	font-weight: 800;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	border: 2px solid var(--oh-bg-card);
}

.oh-tabs {
	position: sticky;
	top: 58px;
	z-index: var(--oh-z-tabs);
	background: var(--oh-bg-glass);
	backdrop-filter: saturate(180%) blur(12px);
	-webkit-backdrop-filter: saturate(180%) blur(12px);
	border-bottom: 1px solid var(--oh-border-soft);
	padding: 10px var(--oh-space-3);
	display: flex;
	gap: var(--oh-space-2);
	overflow-x: auto;
	scroll-snap-type: x mandatory;
	-webkit-overflow-scrolling: touch;
	scrollbar-width: none;
}

.oh-tabs::-webkit-scrollbar { display: none; }

.oh-tab {
	flex: none;
	padding: 8px 16px;
	border-radius: var(--oh-r-full);
	background: var(--oh-bg-card);
	color: var(--oh-text-secondary);
	font-size: 14px;
	font-weight: 700;
	cursor: pointer;
	border: 1px solid var(--oh-border-soft);
	display: inline-flex;
	align-items: center;
	gap: 7px;
	transition: all 0.18s ease-out;
	scroll-snap-align: start;
	white-space: nowrap;
}

.oh-tab:hover {
	border-color: var(--oh-border-strong);
	color: var(--oh-text-primary);
	transform: translateY(-1px);
}

.oh-tab.is-active {
	background: var(--oh-gradient-violet-blue);
	color: #fff;
	border-color: transparent;
	box-shadow: var(--oh-shadow-pop);
	transform: translateY(-1px);
}

.oh-tab__emoji {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 22px;
	height: 22px;
	border-radius: var(--oh-r-full);
	font-size: 12px;
	font-weight: 800;
	background: var(--oh-bg-app);
	color: var(--oh-text-secondary);
}
.oh-tab__emoji[data-c="violet"] { background: rgba(123, 95, 233, 0.14); color: var(--oh-violet); }
.oh-tab__emoji[data-c="blue"]   { background: rgba(91, 169, 240, 0.14); color: var(--oh-primary); }
.oh-tab__emoji[data-c="red"]    { background: rgba(220, 53, 69, 0.14);  color: #BC002D; font-size: 10px; }
.oh-tab__emoji[data-c="red2"]   { background: rgba(255, 0, 0, 0.10);    color: #B33A3A; font-size: 10px; }
.oh-tab__emoji[data-c="orange"] { background: rgba(255, 123, 110, 0.14);color: var(--oh-accent); }
.oh-tab__emoji[data-c="green"]  { background: rgba(16, 200, 150, 0.14); color: var(--oh-success); }

.oh-tab.is-active .oh-tab__emoji {
	background: rgba(255, 255, 255, 0.22);
	color: #fff;
}

.oh-tab__label { white-space: nowrap; }

.oh-bottom-nav {
	position: fixed;
	bottom: 0;
	left: 0;
	right: 0;
	z-index: var(--oh-z-bottom-nav);
	background: var(--oh-bg-glass);
	backdrop-filter: saturate(180%) blur(18px);
	-webkit-backdrop-filter: saturate(180%) blur(18px);
	border-top: 1px solid var(--oh-border-soft);
	display: flex;
	justify-content: space-around;
	padding: 6px 0 max(6px, env(safe-area-inset-bottom));
	box-shadow: 0 -6px 22px rgba(30, 32, 60, 0.07);
}

@media (min-width: 768px) {
	.oh-bottom-nav { display: none; }
}

.oh-bottom-nav__item {
	flex: 1;
	display: flex;
	flex-direction: column;
	align-items: center;
	gap: 2px;
	padding: 6px 4px;
	color: var(--oh-text-tertiary);
	font-size: 11px;
	font-weight: 600;
	border: 0;
	background: transparent;
	transition: color 0.15s;
}

.oh-bottom-nav__item.is-active {
	color: var(--oh-violet);
}
.oh-bottom-nav__item.is-active .oh-bottom-nav__icon {
	transform: scale(1.1);
}

.oh-bottom-nav__icon {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 26px;
	height: 26px;
	transition: transform 0.18s;
}

@media (max-width: 767px) {
	body.ohanashi-app { padding-bottom: 76px; }
}

.oh-container {
	max-width: 720px;
	margin: 0 auto;
	padding: var(--oh-space-4);
}

.oh-badge {
	display: inline-flex;
	align-items: center;
	padding: 2px 8px;
	border-radius: var(--oh-r-full);
	font-size: 10px;
	font-weight: 800;
	color: #fff;
	letter-spacing: 0.02em;
}
.oh-badge--jlc   { background: var(--oh-badge-jlc); }
.oh-badge--jpn   { background: var(--oh-badge-jpn); }
.oh-badge--staff { background: var(--oh-badge-staff); }
.oh-badge--direction-jp-id { background: var(--oh-direction-jp-id); }
.oh-badge--direction-id-jp { background: var(--oh-direction-id-jp); }
