/* LPD Reviews — CSS giống DevVN WooCommerce Reviews */

:root {
	--lpdr-accent: #03a0e2;
	--lpdr-star-color: #f5a623;
}

/* ═══ SUMMARY BOX ═══ */
.star_box {
	border: 1px solid #ddd;
	border-radius: 7px;
	padding: 10px;
	margin: 10px 0 20px;
	overflow: hidden;
	display: flex;
	flex-flow: row nowrap;
	align-items: center;
	justify-content: space-between;
	width: 100%;
	box-sizing: border-box;
}

.star-average .woocommerce-product-rating {
	width: 100%;
	display: flex;
	flex-flow: row wrap;
	position: relative;
	align-items: baseline;
}

span.star_average {
	color: var(--lpdr-star-color);
	font-size: 35px;
	vertical-align: middle;
	font-weight: 700;
	text-align: center;
	margin: 0 10px 0 0;
	line-height: 1;
}

.star-average strong {
	display: block;
	width: 100%;
	font-size: 12px;
	color: #999;
	font-weight: 400;
	margin-top: 4px;
}

.lpdr-icon-star {
	font-style: normal;
	color: var(--lpdr-star-color);
	font-size: 28px;
}

.star_box_left {
	flex: 1;
	flex-shrink: 1;
}

.reviews_bar {
	line-height: 1;
}

.devvn_review_row {
	padding-bottom: 10px;
	position: relative;
	display: flex;
	flex-flow: row nowrap;
	align-items: center;
	justify-content: space-between;
	width: 100%;
}

span.devvn_stars_value {
	line-height: 1;
	min-width: 28px;
	font-weight: 600;
}

span.devvn_stars_value i {
	margin: 0 3px;
	font-style: normal;
}

span.devvn_rating_bar {
	flex: 1;
	padding: 0 10px;
}

span.devvn_scala_rating {
	border-radius: 3px;
	display: inline-block;
	height: 15px;
	background: #eee;
	vertical-align: middle;
	overflow: hidden;
	width: 100%;
}

span.devvn_perc_rating {
	height: 15px;
	border-radius: 3px;
	display: inline-block;
	width: 0;
	transition: width 0.5s ease;
}

span.devvn_num_reviews {
	min-width: 150px;
	color: var(--lpdr-accent);
	font-size: 13px;
}

.star_box_right {
	width: 190px;
	text-align: center;
}

a.btn-reviews-now {
	background-color: var(--lpdr-accent);
	color: #fff !important;
	display: inline-block;
	padding: 10px 20px;
	border-radius: 3px;
	text-transform: uppercase;
	font-weight: 700;
	text-decoration: none !important;
	font-size: 14px;
	transition: opacity 0.2s;
}
a.btn-reviews-now:hover { opacity: 0.85; }

/* ═══ REVIEW FORM ═══ */
#review_form_wrapper {
	border-radius: 5px;
	padding: 20px;
	width: 100%;
	max-width: 590px;
	background: #fff;
	margin: 0 auto 20px;
	position: relative;
	border: 1px solid #ddd;
}

#review_form_wrapper span#reply-title {
	font-size: 18px;
	font-weight: 700;
	display: block;
	margin: 0 0 20px;
}

.lpdr-close-form {
	position: absolute;
	top: 5px;
	right: 5px;
	background: #000;
	border-radius: 50%;
	border: 0;
	color: #fff;
	width: 25px;
	height: 25px;
	font-size: 18px;
	line-height: 25px;
	text-align: center;
	cursor: pointer;
	padding: 0;
	margin: 0;
}

.form_row_reviews {
	margin: 0 0 10px;
	display: flex;
	flex-flow: row nowrap;
	justify-content: space-between;
	width: 100%;
	gap: 10px;
}

.form_row_reviews > p {
	flex: 1;
	margin: 0;
}

#review_form_wrapper input[type="text"],
#review_form_wrapper input[type="email"] {
	border: 1px solid #ddd;
	width: 100%;
	border-radius: 3px;
	padding: 5px 10px;
	height: 35px;
	outline: none;
	box-sizing: border-box;
}

#review_form_wrapper textarea {
	height: 77px;
	border: 1px solid #ddd;
	border-radius: 4px 4px 0 0;
	padding: 8px;
	resize: none;
	outline: none;
	display: block;
	width: 100%;
	margin: 0;
	box-sizing: border-box;
}

.comment-form-rating {
	width: 100%;
	display: flex;
	flex-flow: row nowrap;
	justify-content: space-between;
	align-items: center;
	margin: 0 0 10px;
}

.comment-form-rating label {
	width: 150px;
	padding-right: 10px;
	font-weight: 700;
}

.comment-form-rating select {
	flex: 1;
	padding: 5px;
	border: 1px solid #ddd;
	border-radius: 3px;
}

.wrap-attaddsend {
	background: #f7f7f7;
	padding: 6px !important;
	overflow: hidden;
	margin: 0 0 10px;
}

span#countContent {
	float: right;
	color: #999;
	font-size: 12px;
	margin-top: 5px;
}

.review-attach { position: relative; float: left; }

span.btn-attach {
	color: var(--lpdr-accent);
	font-weight: 700;
	padding: 5px 0;
	display: block;
	cursor: pointer;
	font-size: 13px;
}

.review-attach input[type="file"] {
	display: none;
}

.list_attach {
	margin: 8px 0;
}

ul.lpdr_attach_view {
	list-style: none;
	margin: 0;
	padding: 0;
	display: flex;
	gap: 8px;
	flex-wrap: wrap;
}

ul.lpdr_attach_view li {
	width: 70px;
	height: 70px;
	position: relative;
	overflow: hidden;
	border-radius: 4px;
	border: 1px solid #ddd;
}

ul.lpdr_attach_view li img {
	width: 100%;
	height: 100%;
	object-fit: cover;
}

ul.lpdr_attach_view li .close {
	position: absolute;
	right: 2px;
	top: 2px;
	background: #000;
	color: #fff;
	border-radius: 50%;
	width: 16px;
	height: 16px;
	font-size: 12px;
	text-align: center;
	line-height: 16px;
	cursor: pointer;
	border: 0;
	padding: 0;
}

#review_form_wrapper p.form-submit {
	text-align: center;
}

#review_form_wrapper p.form-submit input#submit {
	background-color: var(--lpdr-accent);
	color: #fff;
	border: 0;
	padding: 10px 30px;
	text-transform: uppercase;
	font-weight: 700;
	height: auto;
	cursor: pointer;
	border-radius: 3px;
	font-size: 14px;
}

/* ═══ REVIEWS LIST ═══ */
div#reviews.woocommerce-Reviews {
	width: 100%;
	max-width: 750px;
	margin: 0 auto 30px;
}

.woocommerce #reviews #comments ol.commentlist {
	list-style: none;
	margin: 0;
	padding: 0;
}

.woocommerce #reviews #comments ol.commentlist li {
	margin: 0 0 8px;
	padding: 0;
}

.woocommerce #reviews #comments ol.commentlist li .comment-text {
	margin: 0;
	border: 0;
	border-radius: 0;
	padding: 0;
	border-bottom: 1px solid #f0f0f0;
	padding-bottom: 12px;
}

.lpdr_review_top .meta {
	font-size: 14px;
	margin: 0 0 2px;
}

strong.woocommerce-review__author {
	font-weight: 700;
	display: inline-block;
	text-transform: capitalize;
	color: #000;
	margin: 0 10px 0 0;
}

em.woocommerce-review__verified.verified {
	position: relative;
	padding: 0 0 0 2px;
	color: #52b858;
	font-style: normal;
	margin-right: 10px;
	font-size: 12px;
}

.lpdr_review_mid {
	margin: 0 0 2px;
}

.lpdr_review_mid .star-rating {
	float: none;
	display: inline-block;
	margin: 0 8px 0 0;
	font-size: 11px;
	color: var(--lpdr-star-color);
}

.lpdr_review_mid .description {
	display: inline;
	line-height: 20px;
}

.lpdr_review_mid .description p {
	display: inline;
	margin: 0;
}

.lpdr_review_bottom > span {
	color: #999;
}

time.woocommerce-review__published-date {
	color: #999;
	font-size: 12px;
}

ul.cmt_attachment_img {
	list-style: none;
	margin: 8px 0 0;
	padding: 0;
	overflow: hidden;
	display: flex;
	gap: 5px;
}

ul.cmt_attachment_img li {
	width: 50px;
	margin: 0;
	padding: 0;
	border: 0;
}

ul.cmt_attachment_img li img {
	width: 100%;
	height: 50px;
	object-fit: cover;
	border-radius: 3px;
	display: block;
}

ul.cmt_attachment_img li a img:hover {
	opacity: 0.8;
}

/* ═══ HỎI ĐÁP ═══ */
.lpdr_prod_cmt {
	width: 100%;
	max-width: 750px;
	margin: 0 auto 30px;
	position: relative;
	border-top: 1px solid #ddd;
	padding-top: 20px;
}

.lpdr_cmt_input textarea,
.lpdr_cmt_input input {
	border: 1px solid #c1bfbf;
	width: 100%;
	padding: 5px 10px;
	border-radius: 3px;
	outline: none;
	box-sizing: border-box;
}

.lpdr_cmt_input textarea {
	height: 100px;
	border-radius: 3px 3px 0 0;
	display: block;
	margin: 0;
	resize: none;
}

.lpdr_cmt_input input {
	height: 30px;
}

.lpdr_cmt_form_bottom {
	border: 1px solid #c1bfbf;
	border-top: 0;
	padding: 10px;
	display: flex;
	flex-flow: row nowrap;
	justify-content: space-between;
	width: 100%;
	box-sizing: border-box;
	gap: 8px;
	align-items: center;
}

.lpdr_cmt_form_bottom.no-infor {
	display: flex;
	justify-content: flex-end;
}

.lpdr_cmt_form_bottom .lpdr_cmt_input {
	flex: 1;
}

.lpdr_cmt_submit {
	width: 50px;
}

button#lpdr_cmt_submit {
	width: 100%;
	height: 30px;
	background: #fbd648;
	border: 0;
	text-transform: uppercase;
	font-weight: 700;
	outline: none;
	border-radius: 3px;
	margin: 0;
	padding: 0;
	font-size: 14px;
	cursor: pointer;
	line-height: 30px;
}

button#lpdr_cmt_submit:hover {
	background: #f0c830;
}

.lpdr_cmt_form {
	margin: 0 0 20px;
}

.lpdr_cmt_list_header {
	overflow: hidden;
	margin: 0 0 15px;
}

.lpdr_cmt_lheader_left span {
	font-size: 16px;
	font-weight: 700;
}

.lpdr_cmt_list_box ul {
	list-style: none;
	margin: 0;
	padding: 0;
}

.lpdr_cmt_list_box > ul > li {
	margin: 0 0 20px;
}

.lpdr_cmt_box > span {
	width: 25px;
	height: 25px;
	background-color: #ccc;
	margin-right: 5px;
	text-align: center;
	color: #fff;
	text-transform: uppercase;
	font-size: 12px;
	line-height: 25px;
	font-style: normal;
	display: inline-block;
	border-radius: 50%;
}

.lpdr_cmt_box > strong {
	text-transform: capitalize;
}

.lpdr_cmt_box .qtv {
	text-transform: uppercase;
	margin-left: 10px;
	color: #000;
	font-weight: 400;
	font-size: 10px;
	background: #eebc49;
	padding: 2px 6px;
	border-radius: 3px;
	line-height: 18px;
}

.lpdr_cmt_box_content {
	display: block;
	font-size: 14px;
	color: #4a4a4a;
	line-height: 22px;
	margin-left: 30px;
}

.lpdr_cmt_box_content p { margin: 0 0 4px; }

.lpdr_cmt_tool {
	color: #999;
	font-size: 12px;
	margin: 0 0 10px 30px;
	padding: 5px 0;
}

ul.lpdr_cmt_child {
	display: block;
	margin-top: 10px;
	position: relative;
	background: #f1f1f1;
	border: 1px solid #e7e7e7;
	padding: 15px 10px 0;
	font-size: 14px;
	color: #333;
	margin-left: 30px;
	list-style: none;
}

ul.lpdr_cmt_child:after,
ul.lpdr_cmt_child:before {
	bottom: 100%;
	left: 20px;
	border: solid transparent;
	content: " ";
	height: 0;
	width: 0;
	position: absolute;
	pointer-events: none;
}

ul.lpdr_cmt_child:after {
	border-color: rgba(241,241,241,0);
	border-bottom-color: #f1f1f1;
	border-width: 12px;
	margin-left: -12px;
}

ul.lpdr_cmt_child:before {
	border-color: rgba(231,231,231,0);
	border-bottom-color: #e7e7e7;
	border-width: 13px;
	margin-left: -13px;
}

/* ═══ FLATSOME COMPAT ═══ */
.theme-flatsome .lpdr-icon-star {
	font-style: normal;
}

.theme-flatsome .star-rating:before {
	color: #d3ced2;
}

body.woocommerce.theme-flatsome #reviews #comments ol.commentlist li {
	padding: 0;
}

.single-product.theme-flatsome .commentlist li .description {
	font-style: normal;
}

/* ═══ LIGHTBOX ═══ */
.lpdr-lightbox {
	position: fixed;
	top: 0; left: 0; right: 0; bottom: 0;
	background: rgba(0,0,0,0.85);
	display: flex;
	align-items: center;
	justify-content: center;
	z-index: 99999;
	cursor: pointer;
}

.lpdr-lightbox img {
	max-width: 90vw;
	max-height: 90vh;
	border-radius: 4px;
}

/* ═══ PAGINATION ═══ */
.woocommerce div#reviews nav.woocommerce-pagination ul {
	display: block;
	border: 0;
	margin: 10px 0;
	padding: 0;
	list-style: none;
}

.woocommerce div#reviews nav.woocommerce-pagination ul li {
	display: inline-block;
	border: 0;
}

.woocommerce div#reviews nav.woocommerce-pagination ul li a,
.woocommerce div#reviews nav.woocommerce-pagination ul li span {
	padding: 7px 10px;
	background: #eee;
	border-radius: 3px;
	color: #333;
	margin-right: 4px;
	font-size: 12px;
	display: inline-block;
	text-decoration: none;
}

.woocommerce div#reviews nav.woocommerce-pagination ul li span.current {
	background: #ccc;
}

/* ═══ RESPONSIVE ═══ */
@media (max-width: 767px) {
	.star_box {
		display: block;
	}
	.star_box_left {
		display: block;
		margin: 0 0 10px;
	}
	.star_box_right {
		width: 100%;
	}
	.form_row_reviews {
		flex-direction: column;
	}
	.lpdr_cmt_form_bottom {
		display: block;
	}
	.lpdr_cmt_radio {
		padding-top: 0;
		float: none;
		margin-bottom: 5px;
		text-align: left;
	}
	.lpdr_cmt_form_bottom .lpdr_cmt_input {
		width: 49%;
		float: left;
		padding: 0;
	}
	.lpdr_cmt_form_bottom .lpdr_cmt_input:nth-child(3) {
		float: right;
	}
	.lpdr_cmt_submit {
		clear: both;
		margin: 0 auto 10px;
		position: relative;
		top: 10px;
	}
	span.devvn_num_reviews {
		min-width: 100px;
		font-size: 12px;
	}
	.lpdr_cmt_search_box {
		width: 160px;
	}
}

/* ═══ Q&A RADIO ═══ */
.lpdr_cmt_radio {
	flex: 1;
	text-align: right;
	padding-top: 7px;
	white-space: nowrap;
}

.lpdr_cmt_radio label {
	display: inline-block;
	font-weight: 700;
	position: relative;
	cursor: pointer;
	margin: 0 10px 0 0;
}

.lpdr_cmt_radio label input {
	border: 0;
	clip: rect(0 0 0 0);
	height: 1px;
	margin: -1px;
	overflow: hidden;
	padding: 0;
	position: absolute;
	width: 1px;
}

.lpdr_cmt_radio label span {
	padding-left: 23px;
	display: block;
}

.lpdr_cmt_radio label span:before,
.lpdr_cmt_radio label span:after {
	width: 16px;
	height: 16px;
	content: "";
	position: absolute;
	border: 1px solid #a6a6a6;
	border-radius: 50%;
	top: 1px;
	left: 0;
}

.lpdr_cmt_radio label input:checked ~ span:before {
	border: 1px solid #3398d2;
}

.lpdr_cmt_radio label input:checked ~ span:after {
	background: #3398d2;
	border: 1px solid #3398d2;
	width: 8px;
	height: 8px;
	top: 5px;
	left: 4px;
}

/* ═══ Q&A SEARCH ═══ */
.lpdr_cmt_list_header {
	overflow: hidden;
	margin: 0 0 20px;
}

.lpdr_cmt_lheader_left {
	float: left;
}

.lpdr_cmt_lheader_right {
	float: right;
}

.lpdr_cmt_search_box {
	position: relative;
	width: 200px;
}

#lpdr_cmt_search {
	border: 1px solid #c1bfbf;
	height: 30px;
	border-radius: 3px;
	padding: 0 10px 0 30px;
	outline: none;
	width: 100%;
	margin: 0;
	box-sizing: border-box;
}

.lpdr_cmt_search_box button {
	position: absolute;
	top: 0;
	left: 0;
	background: transparent;
	border: 0;
	width: 30px;
	height: 30px;
	outline: none;
	cursor: pointer;
	padding: 0;
	margin: 0;
	min-height: inherit;
	line-height: 1;
	font-size: 14px;
}

form#lpdr_cmt_search_form { margin: 0; }

/* ═══ REPLY FORM ═══ */
form#lpdr_cmt_reply {
	margin: 0 0 10px;
	position: relative;
}

form#lpdr_cmt_reply a.lpdr_cancel_cmt {
	position: absolute;
	top: 0;
	right: 0;
	background: #e03232;
	color: #fff;
	width: 15px;
	height: 15px;
	text-align: center;
	line-height: 15px;
	text-decoration: none;
	font-size: 12px;
	border-radius: 2px;
}

/* ═══ QTV BADGE (in reviews) ═══ */
span.review_qtv {
	background-color: #eebc49;
	color: #000;
	padding: 3px;
	border-radius: 3px;
	display: inline-block;
	font-size: 11px;
	text-transform: uppercase;
}

/* ═══ LOADING SPINNER ═══ */
.lpdr_loading:before {
	position: absolute;
	content: "";
	left: 0;
	width: 100%;
	height: 100%;
	background: rgba(0,0,0,0.2);
	z-index: 9;
}

.lpdr_loading:after {
	animation: lpdr_spin 500ms infinite linear;
	border: 2px solid #c29a44;
	border-radius: 32px;
	border-right-color: transparent !important;
	border-top-color: transparent !important;
	content: "";
	display: block;
	height: 16px;
	top: 50%;
	margin-top: -8px;
	left: 50%;
	margin-left: -8px;
	position: absolute;
	width: 16px;
	z-index: 10;
}

@keyframes lpdr_spin {
	0% { transform: rotate(0deg); }
	100% { transform: rotate(360deg); }
}

/* ═══ IMAGE UPLOAD BOX ═══ */
.img-wrap { position: relative; }

.img-wrap .close {
	position: absolute;
	right: -10px;
	top: -10px;
	background: #000;
	color: #fff !important;
	border-radius: 50%;
	z-index: 2;
	display: block;
	width: 20px;
	height: 20px;
	font-size: 16px;
	text-align: center;
	line-height: 18px;
	cursor: pointer;
	opacity: 1 !important;
	text-shadow: none;
	border: 0;
	padding: 0;
}

.img-wrap-box {
	position: relative;
	overflow: hidden;
	padding-top: 100%;
	height: auto;
	background-position: 50% 50%;
	background-size: cover;
}

.img-wrap-box img {
	right: 0;
	width: 100% !important;
	height: 100% !important;
	bottom: 0;
	left: 0;
	top: 0;
	position: absolute;
	object-position: 50% 50%;
	object-fit: cover;
}

i.lpdr-plus {
	font-style: normal;
	font-weight: 900;
	font-size: 35px;
	line-height: 1;
}

.list_attach span.lpdr_add_more {
	width: 70px;
	height: 70px;
	text-align: center;
	display: none;
	float: left;
	border: 2px dashed #ccc;
	line-height: 66px;
	font-size: 25px;
	color: #ccc;
	cursor: pointer;
}

/* ═══ mfp-hide ═══ */
.mfp-hide { display: none !important; }

/* ═══ VERIFIED BADGE ═══ */
em.woocommerce-review__verified.verified {
	position: relative;
	padding: 0 0 0 2px;
	color: #52b858;
	font-style: normal;
	margin-right: 10px;
	font-size: 12px;
}

em.woocommerce-review__awaiting-approval {
	color: #F44336;
}

/* ═══ REVIEW BOTTOM ═══ */
.lpdr_review_bottom .reply {
	color: #288ad6;
	display: inline-block;
}

.lpdr_review_bottom .reply a {
	color: #288ad6;
}

/* ═══ REVIEW CHILDREN (admin reply inline) ═══ */
body.woocommerce #reviews #comments ol.commentlist ul.children {
	margin: 10px 0 15px 10px;
	list-style: none;
	padding: 0;
}

body.woocommerce #reviews #comments ol.commentlist ul.children li {
	border-left: 4px solid #efefef;
	padding-left: 10px;
}

