/*
Theme Name: Danaci
Theme URI: https://danaci.vn
Author: Danaci
Description: Theme code tùy chỉnh cho danaci.vn. Đảm nhiệm khung sườn (header/footer, màu sắc, font, menu) và các trang nội dung chính. Elementor vẫn hoạt động song song — các trang mới có thể chọn template "Elementor Full Width" để dùng chung header/footer này, hoặc "Elementor Canvas" để dựng toàn màn hình riêng.
Version: 1.0.9
Requires at least: 6.4
Requires PHP: 8.0
Text Domain: danaci
*/

:root {
	--color-navy: #1B3A5C;
	--color-orange: #F2A93B;
	--color-green: #2E7D32; /* TODO: thay bằng mã hex xanh lá chính thức khi có */
	--color-white: #FFFFFF;
	--color-border: #E4E1DA;
	--font-primary: 'Be Vietnam Pro', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
	--container-max: 1200px;
}

*,
*::before,
*::after {
	box-sizing: border-box;
}

body {
	margin: 0;
	font-family: var(--font-primary);
	color: var(--color-navy);
	line-height: 1.5;
}

a {
	color: inherit;
}

img {
	max-width: 100%;
	height: auto;
}

.sr-only {
	position: absolute;
	width: 1px;
	height: 1px;
	padding: 0;
	margin: -1px;
	overflow: hidden;
	clip: rect(0, 0, 0, 0);
	white-space: nowrap;
	border: 0;
}

/* Header */
.site-header {
	background: var(--color-white);
	border-bottom: 0.5px solid var(--color-border);
	padding: 14px 0;
}

.site-header__inner {
	max-width: var(--container-max);
	margin: 0 auto;
	padding: 0 20px;
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 20px;
	flex-wrap: wrap;
}

.site-branding a,
.site-branding__text {
	font-size: 24px;
	font-weight: 600;
	color: var(--color-navy);
	text-decoration: none;
}

.site-nav__list {
	display: flex;
	gap: 24px;
	list-style: none;
	margin: 0;
	padding: 0;
}

.site-nav__list a {
	color: var(--color-navy);
	text-decoration: none;
	font-weight: 500;
}

.site-nav__list a:hover,
.site-nav__list a:focus {
	color: var(--color-orange);
}

/* Dropdown submenu */
.site-nav__list li {
	position: relative;
}

.site-nav__list .menu-item-has-children > a {
	display: inline-flex;
	align-items: center;
	gap: 6px;
}

.site-nav__list .menu-item-has-children > a::after {
	content: '';
	width: 6px;
	height: 6px;
	border-right: 1.5px solid currentColor;
	border-bottom: 1.5px solid currentColor;
	transform: rotate(45deg);
}

.site-nav__list .sub-menu {
	display: none;
	position: absolute;
	top: 100%;
	left: 0;
	min-width: 220px;
	background: var(--color-white);
	border: 1px solid var(--color-border);
	border-radius: 8px;
	box-shadow: 0 8px 24px rgba(27, 58, 92, 0.12);
	padding: 8px 0;
	margin: 8px 0 0;
	list-style: none;
	z-index: 100;
}

.site-nav__list .menu-item-has-children:hover > .sub-menu,
.site-nav__list .menu-item-has-children:focus-within > .sub-menu {
	display: block;
}

.site-nav__list .sub-menu li {
	width: 100%;
}

.site-nav__list .sub-menu a {
	display: block;
	padding: 8px 20px;
	font-weight: 400;
	white-space: nowrap;
}

.site-nav__list .sub-menu a:hover {
	background: #FAF8F3;
	color: var(--color-orange);
}

.site-header__lang {
	display: flex;
	gap: 8px;
	font-size: 14px;
}

.site-header__lang a {
	text-decoration: none;
	color: var(--color-navy);
}

.site-header__lang a.pll-selected {
	font-weight: 700;
	color: var(--color-orange);
}

.site-nav__toggle {
	display: none;
	flex-direction: column;
	gap: 4px;
	background: none;
	border: 0;
	cursor: pointer;
	padding: 8px;
}

.site-nav__toggle-bar {
	width: 22px;
	height: 2px;
	background: var(--color-navy);
	display: block;
}

@media (max-width: 782px) {
	.site-nav {
		display: none;
		width: 100%;
		order: 3;
	}

	.site-nav.is-open {
		display: block;
	}

	.site-nav__list {
		flex-direction: column;
		gap: 12px;
		padding: 16px 0 0;
	}

	.site-nav__toggle {
		display: inline-flex;
	}

	.site-nav__list .sub-menu {
		display: block;
		position: static;
		box-shadow: none;
		border: none;
		background: none;
		padding-left: 16px;
		margin: 8px 0 0;
	}

	.site-nav__list .menu-item-has-children > a::after {
		display: none;
	}
}

/* Main content */
.site-main {
	max-width: var(--container-max);
	margin: 0 auto;
	padding: 40px 20px;
}

.entry-title {
	color: var(--color-navy);
}

.entry-meta {
	color: #6b7280;
	font-size: 14px;
	margin-top: -8px;
}

.entry-thumbnail {
	margin: 20px 0;
}

.entry-thumbnail img {
	border-radius: 12px;
}

/* Archive header */
.archive-header {
	margin-bottom: 32px;
}

.archive-header__title {
	color: var(--color-navy);
	margin-bottom: 8px;
}

.archive-header__desc {
	color: #55606e;
}

.archive-empty {
	color: #55606e;
}

/* Card grid (archive.php, index.php, related sections) */
.card-grid {
	display: grid;
	grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
	gap: 24px;
}

.content-card {
	display: flex;
	flex-direction: column;
	background: var(--color-white);
	border: 1px solid var(--color-border);
	border-radius: 12px;
	overflow: hidden;
	transition: box-shadow 0.2s ease, transform 0.2s ease;
}

.content-card:hover {
	box-shadow: 0 12px 28px rgba(27, 58, 92, 0.12);
	transform: translateY(-2px);
}

.content-card__thumb {
	display: block;
	aspect-ratio: 4 / 3;
	background: #f2f0eb;
	overflow: hidden;
}

.content-card__thumb img {
	width: 100%;
	height: 100%;
	object-fit: cover;
	display: block;
}

.content-card__thumb-placeholder {
	display: block;
	width: 100%;
	height: 100%;
	background: linear-gradient(135deg, #eef1f5, #e4e1da);
}

.content-card__body {
	padding: 16px 20px 20px;
	display: flex;
	flex-direction: column;
	gap: 8px;
	flex: 1;
}

.content-card__title {
	font-size: 18px;
	margin: 0;
}

.content-card__title a {
	color: var(--color-navy);
	text-decoration: none;
}

.content-card__price {
	color: var(--color-orange);
	font-weight: 700;
	margin: 0;
}

.content-card__excerpt {
	color: #55606e;
	font-size: 14px;
	flex: 1;
}

.content-card__excerpt p {
	margin: 0;
}

.content-card__cta {
	color: var(--color-navy);
	font-weight: 600;
	text-decoration: none;
	font-size: 14px;
}

.content-card__cta:hover {
	color: var(--color-orange);
}

/* Badges (loai_thue, diem_den) */
.badge-list {
	display: flex;
	flex-wrap: wrap;
	gap: 8px;
	margin-bottom: 12px;
}

.badge {
	display: inline-block;
	background: #eef3f8;
	color: var(--color-navy);
	border-radius: 999px;
	padding: 4px 12px;
	font-size: 13px;
	font-weight: 600;
	text-decoration: none;
}

.badge:hover {
	background: var(--color-orange);
	color: var(--color-white);
}

/* Product / Tour detail (single-san_pham_thue.php, single-tour.php) */
.product-detail {
	display: grid;
	grid-template-columns: minmax(0, 1.1fr) minmax(0, 1fr);
	gap: 40px;
	margin-bottom: 56px;
}

@media (max-width: 782px) {
	.product-detail {
		grid-template-columns: 1fr;
		gap: 24px;
	}
}

.product-detail__media img {
	width: 100%;
	aspect-ratio: 4 / 3;
	max-height: 480px;
	object-fit: cover;
	border-radius: 12px;
	display: block;
}

.product-detail__thumb-placeholder {
	display: block;
	width: 100%;
	aspect-ratio: 4 / 3;
	border-radius: 12px;
	background: linear-gradient(135deg, #eef1f5, #e4e1da);
}

.product-detail__title {
	color: var(--color-navy);
	margin: 0 0 8px;
}

.product-detail__price {
	color: var(--color-orange);
	font-size: 24px;
	font-weight: 700;
	margin: 0 0 16px;
}

.product-detail__content {
	margin-bottom: 24px;
	line-height: 1.7;
}

.tour-meta {
	list-style: none;
	margin: 0 0 20px;
	padding: 0;
	display: flex;
	flex-direction: column;
	gap: 6px;
	color: #3d4a58;
}

.btn-cta {
	display: inline-block;
	background: var(--color-navy);
	color: var(--color-white);
	text-decoration: none;
	font-weight: 600;
	padding: 12px 28px;
	border-radius: 8px;
	transition: background 0.2s ease;
}

.btn-cta:hover {
	background: var(--color-orange);
}

.related-section {
	border-top: 1px solid var(--color-border);
	padding-top: 32px;
}

.related-section__title {
	color: var(--color-navy);
	margin-bottom: 20px;
}

/* Footer */
.site-footer {
	background: var(--color-navy);
	color: var(--color-white);
	padding: 32px 0;
	margin-top: 48px;
}

.site-footer__inner {
	max-width: var(--container-max);
	margin: 0 auto;
	padding: 0 20px;
}

.site-footer__list {
	display: flex;
	flex-wrap: wrap;
	gap: 20px;
	list-style: none;
	margin: 0 0 16px;
	padding: 0;
}

.site-footer__list a {
	color: var(--color-white);
	text-decoration: none;
}

.site-footer__list a:hover {
	color: var(--color-orange);
}

.site-footer__copy {
	margin: 0;
	font-size: 14px;
	opacity: 0.8;
}

/* Contact Form 7 */
.wpcf7 {
	max-width: 640px;
}

.wpcf7-form p {
	margin: 0 0 18px;
}

.wpcf7-form label {
	display: block;
	font-weight: 500;
	color: var(--color-navy);
}

.wpcf7-form input[type="text"],
.wpcf7-form input[type="email"],
.wpcf7-form input[type="tel"],
.wpcf7-form textarea {
	display: block;
	width: 100%;
	margin-top: 6px;
	padding: 12px 14px;
	font: inherit;
	color: var(--color-navy);
	background: var(--color-white);
	border: 1px solid var(--color-border);
	border-radius: 8px;
	transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.wpcf7-form input:focus,
.wpcf7-form textarea:focus {
	outline: none;
	border-color: var(--color-orange);
	box-shadow: 0 0 0 3px rgba(242, 169, 59, 0.25);
}

.wpcf7-form textarea {
	min-height: 140px;
	resize: vertical;
}

.wpcf7-form input[type="submit"] {
	background: var(--color-navy);
	color: var(--color-white);
	font: inherit;
	font-weight: 600;
	padding: 12px 32px;
	border: 0;
	border-radius: 8px;
	cursor: pointer;
	transition: background 0.2s ease;
}

.wpcf7-form input[type="submit"]:hover {
	background: var(--color-orange);
}

.wpcf7-not-valid-tip {
	color: #c0392b;
	font-size: 13px;
	margin-top: 4px;
}

.wpcf7 form .wpcf7-response-output {
	margin: 20px 0 0;
	padding: 12px 16px;
	border-radius: 8px;
}
