/* 唯一的全局重置 */
* {
	margin: 0;
	padding: 0;
	box-sizing: border-box;
	font-family: "微软雅黑", sans-serif;
}

html {
	overflow-x: hidden !important;
	width: 100%;
}

html,
body {
	width: 100%;
	overflow-x: hidden;
	/* 统一隐藏横向滚动 */
}

body {
	background-color: #f8f8f8;
	color: #333;
	line-height: 1.6;
	/* 移除重复的overflow-x: hidden */
}

hr {
	background-color: transparent;
	/* 背景透明 */
	width: 100%;
	color: #a0a0a0;
}

/* 头部导航栏 */
.header {
	background-color: transparent;
	/* 背景透明 */
	color: #fff;
	z-index: 100;
	position: absolute;
	/* 绝对定位，覆盖在banner图上 */
	top: 0;
	left: 0;
	width: 100%;
	/* 占满宽度 */
	padding: 20px 0;
	/* 导航栏内边距，控制覆盖高度 */
}

.header-top {
	font-size: 18px;
	margin-bottom: 10px;
	height: 50px;
	display: flex;
	justify-content: space-between;
	align-items: center;
	padding: 0 80px;
	flex-wrap: wrap;
	/* 新增：小屏幕下换行 */
	overflow: hidden;
	/* 新增：隐藏溢出内容 */
}

/* 导航栏容器 */
.nav {
	display: flex;
	gap: 40px;
	/* 导航项间距 */
	height: 50px;
	font-size: 16px;
	/* 字体大小 */
	justify-content: center;
	/* 内容居中 */
	align-items: center;
	/* 上下居中 */
	list-style: none;
	padding: 0;
	margin: 0;
	background-color: transparent;
	position: relative;
}

/* 导航项链接 */
.nav a {
	color: #fff;
	/* 字体白色 */
	text-decoration: none;
	/* 去掉下划线 */
	padding: 8px 0;
	display: block;
}

.nav a:hover {
	text-decoration: none;
	/* 去掉 hover 下划线 */
	border-bottom: 2px solid #ffd700;
	/* 底部边框效果 */

}

/* 导航项容器 */
.nav-item {
	position: relative;
}

/* 选中.nav-item下的第一个a标签 */
.nav-item>a:first-child {
	/* 自定义样式 */
	font-size: 20px;
	/*    font-weight: bold; /* 加粗 */
	padding: 10px 0;
	/* 调整内边距 */
}

#nav-admin-item>a {
	font-size: 20px;
	padding: 10px 0;
	color: #ffd700;
}

#nav-admin-item>a:hover {
	border-bottom-color: #fff8dc;
	color: #fffacd;
}

.nav-login {
	position: relative;
}

/* 选中.nav-item下的第一个a标签 */
.nav-login a {
	/* 自定义样式 */
	font-size: 20px;
	/*    font-weight: bold; /* 加粗 */
	padding: 10px 0;
	/* 调整内边距 */
}

/* 下拉框样式 */
.dropdown {
	/* 替换display: none，使用opacity和visibility实现过渡 */
	opacity: 0;
	visibility: hidden;
	transform: translateY(10px);
	/* 初始向下偏移 */
	position: absolute;
	top: 100%;
	left: 0;
	background-color: rgba(0, 0, 0, 0.8);
	min-width: 200px;
	border-radius: 4px;
	box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
	z-index: 999;
	padding: 0;
	margin: 0;
	/* 添加过渡效果 */
	transition:
		opacity 0.5s ease,
		visibility 0.5s ease,
		transform 0.5s ease;
}

.dropdown a {
	padding: 10px 15px;
	color: #fff;
	text-decoration: none;
	display: block;
	border-bottom: none;
	/* 去掉下拉项底部边框 */
}

.dropdown a:hover {
	background-color: #ffffff;
	border-bottom: none;
	/* hover时也无底部边框 */
	color: #000;
}

/* 鼠标悬浮显示下拉框（触发过渡） */
.nav-item:hover .dropdown {
	opacity: 1;
	visibility: visible;
	transform: translateY(0);
	/* 回到原位 */
}

/* 主轮播图区域（banner图） */
.main-carousel {
	width: 100%;
	/* 视口宽度的100%，覆盖整个屏幕宽度 */
	height: 100vh;
	/* 视口高度的100%，覆盖整个屏幕高度 */
	overflow: hidden;
	position: relative;
	/* 作为导航栏绝对定位的参考 */
	margin: 0;
	/* 清除默认外边距 */
	padding: 0;
	/* 清除默认内边距 */
}

.carousel-item {
	position: absolute;
	top: 0;
	left: 0;
	width: 100%;
	height: 100%;
	opacity: 0;
	transition: opacity 0.8s ease;
	display: flex;
	align-items: center;
	justify-content: center;
	text-align: center;
	color: #fff;
}

.carousel-item.active {
	opacity: 1;
}

.carousel-bg1 {
	background: url("../img/重庆非遗.webp") no-repeat center;
	background-size: cover;
	background-blend-mode: overlay;
}

.carousel-bg2 {
	background: url("../img/铜梁龙舞-8.webp") no-repeat center;
	background-size: cover;
	background-blend-mode: overlay;
}

.carousel-bg3 {
	background: url("../img/梁平木板年画-6.webp") no-repeat center;
	background-size: cover;
	background-blend-mode: overlay;
}

.carousel-bg4 {
	background: url("../img/川江号子.webp") no-repeat center;
	background-size: cover;
	background-blend-mode: overlay;
}

.carousel-bg5 {
	background: url("../img/酉阳苗绣-1.webp") no-repeat center;
	background-size: cover;
	background-blend-mode: overlay;
}

.carousel-content {
	max-width: 800px;
	padding: 20px;
	margin-top: 150px;
	/* 轮播内容向下偏移，避开导航栏覆盖区域 */
}

.carousel-title {
	font-size: 80px;
	font-weight: bold;
	color: #ffd700;
	margin-bottom: 20px;
	text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.5);
}

.carousel-subtitle {
	font-size: 24px;
	margin: 10px 0;
	text-shadow: 1px 1px 3px rgba(0, 0, 0, 0.5);
}

.carousel-desc {
	font-size: 18px;
	margin: 10px 0;
	text-shadow: 1px 1px 3px rgba(0, 0, 0, 0.5);
}

.carousel-tag {
	font-size: 28px;
	margin-top: 30px;
	font-weight: bold;
	text-shadow: 1px 1px 3px rgba(0, 0, 0, 0.5);
}

/* 轮播控制按钮 */
.carousel-control {
	position: absolute;
	top: 50%;
	transform: translateY(-50%);
	width: 50px;
	height: 50px;
	background-color: rgba(255, 255, 255, 0.2);
	color: #fff;
	border: none;
	border-radius: 50%;
	font-size: 24px;
	cursor: pointer;
	z-index: 10;
	display: flex;
	align-items: center;
	justify-content: center;
	transition: background-color 0.3s ease;
}

.carousel-control:hover {
	background-color: rgba(255, 255, 255, 0.4);
}

.carousel-prev {
	left: 20px;
}

.carousel-next {
	right: 20px;
}

/* 轮播指示器 */
.carousel-indicators {
	position: absolute;
	bottom: 30px;
	left: 50%;
	transform: translateX(-50%);
	display: flex;
	gap: 15px;
	z-index: 10;
}

.indicator-dot {
	width: 15px;
	height: 15px;
	border-radius: 50%;
	background-color: rgba(255, 255, 255, 0.5);
	cursor: pointer;
	transition: all 0.3s ease;
}

.indicator-dot.active {
	background-color: #ffd700;
	transform: scale(1.2);
}

/* 内容容器 */
.container {
	max-width: 1200px;
	margin: 0 auto;
	padding: 20px;
}

/* 春节介绍 */
.intro-section {
	background-color: #fff;
	padding: 30px;
	border-radius: 8px;
	box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
	margin-bottom: 30px;
}

.section-title {
	color: #c81623;
	font-size: 28px;
	margin-bottom: 20px;
	padding-bottom: 10px;
	border-bottom: 3px solid #c81623;
	display: inline-block;
}

.intro-content {
	display: flex;
	gap: 30px;
	margin-top: 20px;
}

.intro-text {
	flex: 2;
	font-size: 16px;
}

.intro-text p {
	margin-bottom: 15px;
	text-indent: 2em;
}

.intro-image {
	flex: 1;
}

.intro-image img {
	width: 100%;
	height: 300px;
	object-fit: cover;
	border-radius: 8px;
}

/* 春节习俗轮播图 */
.customs-carousel-section {
	margin-bottom: 30px;
	background-color: #fff;
	padding: 30px;
	border-radius: 8px;
	box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}

.customs-carousel-container {
	position: relative;
	width: 100%;
	height: 500px;
	overflow: hidden;
	border-radius: 8px;
	margin-top: 20px;
}

.customs-slide {
	position: absolute;
	top: 0;
	left: 0;
	width: 100%;
	height: 100%;
	opacity: 0;
	transition: opacity 0.5s ease;
	display: flex;
}

.customs-slide.active {
	opacity: 1;
}

.customs-image {
	flex: 1;
	height: 100%;
}

.customs-image img {
	width: 95%;
	height: 100%;
	object-fit: cover;
}

.customs-content {
	flex: 1;
	padding: 40px;
	display: flex;
	flex-direction: column;
	justify-content: center;
	background-color: #fff;
}

.customs-title {
	font-size: 32px;
	color: #c81623;
	margin-bottom: 20px;
	font-weight: bold;
}

.customs-desc {
	font-size: 18px;
	line-height: 1.8;
	color: #555;
	margin-bottom: 30px;
}

.customs-features {
	display: grid;
	grid-template-columns: repeat(2, 1fr);
	gap: 15px;
}

.customs-feature-item {
	display: flex;
	align-items: center;
	gap: 10px;
}

.customs-feature-icon {
	width: 30px;
	height: 30px;
	background-color: #c81623;
	border-radius: 50%;
	display: flex;
	align-items: center;
	justify-content: center;
	color: #fff;
}

/* 习俗轮播控制按钮 */
.customs-control {
	position: absolute;
	top: 50%;
	transform: translateY(-50%);
	width: 50px;
	height: 50px;
	background-color: rgba(200, 22, 35, 0.7);
	color: #fff;
	border: none;
	border-radius: 50%;
	font-size: 24px;
	cursor: pointer;
	z-index: 10;
	display: flex;
	align-items: center;
	justify-content: center;
	transition: background-color 0.3s ease;
}

.customs-control:hover {
	background-color: #c81623;
}

/* 习俗轮播指示器 */
.customs-indicators {
	position: absolute;
	bottom: 20px;
	left: 50%;
	transform: translateX(-50%);
	display: flex;
	gap: 10px;
	z-index: 10;
}

.customs-dot {
	width: 12px;
	height: 12px;
	border-radius: 50%;
	background-color: rgba(200, 22, 35, 0.3);
	cursor: pointer;
	transition: all 0.3s ease;
}

.customs-dot.active {
	background-color: #c81623;
	transform: scale(1.3);
}

/* 非遗项目展示 */
.heritage-section {
	background-color: #fff;
	padding: 30px;
	border-radius: 8px;
	box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
	margin-bottom: 30px;
}

.heritage-list {
	margin-top: 20px;
}

.heritage-item {
	display: flex;
	align-items: center;
	padding: 15px;
	border-bottom: 1px solid #eee;
}

.heritage-item:last-child {
	border-bottom: none;
}

.heritage-icon {
	width: 60px;
	height: 60px;
	background-color: #c81623;
	border-radius: 50%;
	display: flex;
	align-items: center;
	justify-content: center;
	color: #fff;
	font-size: 24px;
	font-weight: bold;
	margin-right: 20px;
}

.heritage-content {
	flex: 1;
}

.heritage-title {
	font-size: 18px;
	margin-bottom: 5px;
}

.heritage-desc {
	color: #666;
	font-size: 14px;
}

/* 文化传承 */
.inheritance-section {
	background-color: #c81623;
	color: #fff;
	padding: 40px 0;
	text-align: center;
	margin-bottom: 30px;
}

.inheritance-content {
	max-width: 800px;
	margin: 0 auto;
	padding: 0 20px;
}

.inheritance-title {
	font-size: 32px;
	margin-bottom: 20px;
}

.inheritance-text {
	font-size: 18px;
	margin-bottom: 30px;
}

.btn {
	display: inline-block;
	padding: 10px 30px;
	background-color: #ffd700;
	color: #c81623;
	text-decoration: none;
	border-radius: 30px;
	font-weight: bold;
	transition: background-color 0.3s ease;
}

.btn:hover {
	background-color: #fff;
}

/* 页脚 */
.footer {
	background-color: #333;
	color: #fff;
	padding: 40px 0;
}

.footer-content {
	max-width: 1200px;
	margin: 0 auto;
	padding: 0 20px;
	display: flex;
	flex-wrap: wrap;
	justify-content: space-between;
}

.footer-column {
	flex: 1;
	min-width: 250px;
	margin-bottom: 20px;
	padding-right: 20px;
}

.footer-title {
	font-size: 18px;
	margin-bottom: 15px;
	color: #ffd700;
}

.footer-links {
	list-style: none;
}

.footer-links li {
	margin-bottom: 8px;
}

.footer-links a {
	color: #ccc;
	text-decoration: none;
}

.footer-links a:hover {
	color: #ffd700;
}

.copyright {
	text-align: center;
	padding-top: 20px;
	border-top: 1px solid #555;
	margin-top: 20px;
	font-size: 14px;
	color: #aaa;
}

/* ============ 优化后的响应式适配 ============ */
@media (max-width: 1024px) {

	/* 平板设备适配 */
	.header-top {
		padding: 0 40px;
	}

	.nav {
		gap: 25px;
	}

	.carousel-title {
		font-size: 60px;
	}

	.customs-carousel-container {
		height: 450px;
	}
}

@media (max-width: 768px) {

	/* 移动端适配 */
	.header {
		padding: 10px 0;
	}

	.header-top {
		font-size: 16px;
		height: auto;
		padding: 0 20px;
		flex-direction: row;
		/* 保持横向布局，避免错乱 */
		align-items: center;
		gap: 15px;
	}

	/* 导航栏优化 */
	.nav {
		gap: 15px;
		font-size: 14px;
		flex-wrap: wrap;
		overflow: visible;
		padding: 10px;
		justify-content: center;
		scrollbar-width: none;
	}

	.nav::-webkit-scrollbar {
		display: none;
	}

	.nav-item>a:first-child,
	.nav-login a,
	#nav-admin-item>a {
		font-size: 16px;
		padding: 8px 0;
	}

	/* 轮播图适配 */
	.main-carousel {
		height: 70vh;
		max-width: 100%;
		/* 减小高度，避免内容溢出 */
		min-height: 400px;
	}

	.carousel-content {
		max-width: 90%;
		margin-top: 80px;
		padding: 15px;
	}

	.carousel-title {
		font-size: 40px;
		margin-bottom: 15px;
	}

	.carousel-subtitle {
		font-size: 20px;
	}

	.carousel-desc {
		font-size: 16px;
	}

	.carousel-tag {
		font-size: 22px;
	}

	/* 轮播控制按钮 */
	.carousel-control {
		width: 40px;
		height: 40px;
		font-size: 20px;
	}

	.carousel-prev {
		left: 10px;
	}

	.carousel-next {
		right: 10px;
	}

	/* 内容容器适配 */
	.container {
		max-width: 100%;
		padding: 15px;
	}

	/* 春节介绍适配 */
	.intro-section {
		padding: 20px;
		margin-bottom: 20px;
	}

	.section-title {
		font-size: 24px;
	}

	.intro-content {
		flex-direction: column;
		gap: 20px;
	}

	.intro-image img {
		height: 220px;
	}

	/* 习俗轮播适配 */
	.customs-carousel-section {
		padding: 20px;
	}

	.customs-carousel-container {
		height: auto;
		min-height: 400px;
	}

	.customs-slide {
		flex-direction: column;
	}

	.customs-image {
		height: 220px;
	}

	.customs-image img {
		width: 100%;
	}

	.customs-content {
		padding: 20px;
	}

	.customs-title {
		font-size: 26px;
	}

	.customs-desc {
		font-size: 16px;
		margin-bottom: 20px;
	}

	.customs-features {
		grid-template-columns: 1fr;
	}

	/* 非遗项目适配 */
	.heritage-section {
		padding: 20px;
	}

	.heritage-item {
		padding: 12px;
	}

	.heritage-icon {
		width: 50px;
		height: 50px;
		font-size: 20px;
	}

	/* 文化传承适配 */
	.inheritance-section {
		padding: 30px 0;
	}

	.inheritance-title {
		font-size: 26px;
	}

	.inheritance-text {
		font-size: 16px;
	}

	/* 页脚适配 */
	.footer-content {
		padding: 0 15px;
	}

	.footer-column {
		min-width: 45%;
		padding-right: 15px;
	}
}

/* 横屏手机适配 */
@media (max-height: 500px) and (orientation: landscape) {
	.main-carousel {
		height: 100vh;
	}

	.carousel-content {
		margin-top: 20px;
	}

	.carousel-title {
		font-size: 36px;
	}
}
/* ============ 移动端汉堡菜单 ============ */
.nav-toggle {
	display: none;
	background: transparent;
	border: 2px solid rgba(255, 255, 255, 0.8);
	border-radius: 6px;
	padding: 6px 9px;
	cursor: pointer;
	margin: 0 auto;
}
.nav-toggle span {
	display: block;
	width: 22px;
	height: 2px;
	background: #fff;
	margin: 5px 0;
	border-radius: 2px;
	transition: transform 0.3s, opacity 0.3s;
}
.header.nav-open .nav-toggle span:nth-child(1) {
	transform: translateY(7px) rotate(45deg);
}
.header.nav-open .nav-toggle span:nth-child(2) {
	opacity: 0;
}
.header.nav-open .nav-toggle span:nth-child(3) {
	transform: translateY(-7px) rotate(-45deg);
}

@media (max-width: 768px) {
	.nav-toggle {
		display: block;
	}
	.header .nav {
		display: none;
		flex-direction: column;
		height: auto;
		gap: 0;
		padding: 6px 12px;
		background: rgba(0, 0, 0, 0.88);
		border-radius: 8px;
	}
	.header.nav-open .nav {
		display: flex;
	}
	.header.nav-open {
		background: transparent;
	}
	.header .nav-item {
		width: 100%;
		text-align: center;
	}
	.header .nav-item > a:first-child {
		border-bottom: 1px solid rgba(255, 255, 255, 0.12);
	}
	.header .dropdown {
		position: static;
		display: none;
		opacity: 1;
		visibility: visible;
		transform: none;
		transition: none;
		background: rgba(255, 255, 255, 0.08);
		min-width: 100%;
		box-shadow: none;
	}
	.header .nav-item.open .dropdown {
		display: block;
	}
	.header .nav-login {
		width: 100%;
		text-align: center;
	}
}
