/**
 * 商品レビュー（★5段階）スタイル
 * FontAwesome 4 を利用（font-awesome.min.css が先に読み込まれている前提）
 */

#wc-reviews {
	margin: 40px 0;
	padding-top: 24px;
	border-top: 1px solid #e0e0e0;
}

.wc-reviews-title {
	font-size: 1.4em;
	margin: 0 0 20px;
}

/* ---- 星の共通表示（読み取り専用） ---- */
.wc-stars {
	display: inline-flex;
	gap: 1px;
	vertical-align: middle;
	line-height: 1;
}
.wc-stars .wc-star::before {
	font-family: 'FontAwesome';
	font-size: 1.05em;
	color: #f5a623;
	-webkit-font-smoothing: antialiased;
}
.wc-stars .wc-star.is-full::before {
	content: "\f005"; /* fa-star */
}
.wc-stars .wc-star.is-half::before {
	content: "\f123"; /* fa-star-half-o */
}
.wc-stars .wc-star.is-empty::before {
	content: "\f006"; /* fa-star-o */
	color: #cfcfcf;
}

/* ---- 平均サマリー ---- */
.wc-reviews-summary {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 24px 40px;
	margin-bottom: 28px;
}
.wc-reviews-average {
	display: flex;
	align-items: center;
	gap: 10px;
}
.wc-average-num {
	font-size: 2.2em;
	font-weight: bold;
	line-height: 1;
	color: #333;
}
.wc-reviews-average .wc-stars .wc-star::before {
	font-size: 1.3em;
}
.wc-average-count {
	color: #777;
	font-size: 0.9em;
}

.wc-reviews-breakdown {
	list-style: none;
	margin: 0;
	padding: 0;
	min-width: 220px;
}
.wc-reviews-breakdown li {
	display: flex;
	align-items: center;
	gap: 8px;
	margin: 2px 0;
	font-size: 0.85em;
}
.wc-bd-label {
	width: 32px;
	color: #f5a623;
	white-space: nowrap;
}
.wc-bd-bar {
	flex: 1;
	height: 8px;
	background: #eee;
	border-radius: 4px;
	overflow: hidden;
}
.wc-bd-fill {
	display: block;
	height: 100%;
	background: #f5a623;
}
.wc-bd-num {
	width: 28px;
	text-align: right;
	color: #777;
}

.wc-reviews-none {
	color: #777;
}
.wc-review-pending {
	background: #eef7ee;
	border: 1px solid #b7d9b7;
	color: #2e7d32;
	padding: 12px 16px;
	border-radius: 4px;
	margin-bottom: 24px;
}

/* ---- レビュー一覧 ---- */
.wc-review-list {
	list-style: none;
	margin: 0 0 36px;
	padding: 0;
}
.wc-review-list .wc-review-item {
	padding: 16px 0;
	border-bottom: 1px solid #eee;
}
.wc-review-head {
	display: flex;
	align-items: center;
	flex-wrap: wrap;
	gap: 10px;
	margin-bottom: 8px;
}
.wc-review-author {
	font-weight: bold;
}
.wc-review-date {
	color: #999;
	font-size: 0.85em;
}
.wc-review-text {
	line-height: 1.7;
	color: #333;
}

/* ---- 投稿フォーム ---- */
.wc-review-form-wrap {
	background: #fafafa;
	border: 1px solid #e5e5e5;
	border-radius: 6px;
	padding: 20px 24px;
}
.wc-review-form-title {
	font-size: 1.15em;
	margin: 0 0 16px;
}
.wc-form-row {
	margin-bottom: 16px;
}
.wc-form-label {
	display: inline-block;
	font-weight: bold;
	margin-bottom: 6px;
}
.wc-review-form textarea {
	width: 100%;
	padding: 10px;
	border: 1px solid #ccc;
	border-radius: 4px;
	box-sizing: border-box;
	font-size: 1em;
}

/* 星選択UI：DOM上は 5→1 の順、flex row-reverse で見た目 1→5 */
.wc-rating-row {
	display: flex;
	align-items: center;
	gap: 12px;
}
.wc-rating-input {
	display: inline-flex;
	flex-direction: row-reverse;
	justify-content: flex-end;
}
.wc-rating-input input {
	position: absolute;
	width: 1px;
	height: 1px;
	opacity: 0;
	pointer-events: none;
}
.wc-rating-input label {
	cursor: pointer;
	padding: 0 2px;
	margin: 0;
	line-height: 1;
}
.wc-rating-input label::before {
	content: "\f006"; /* fa-star-o（空） */
	font-family: 'FontAwesome';
	font-size: 1.8em;
	color: #cfcfcf;
	transition: color 0.1s ease;
}
/* チェック済み or ホバー中の星以下を点灯 */
.wc-rating-input input:checked ~ label::before,
.wc-rating-input label:hover::before,
.wc-rating-input label:hover ~ label::before {
	content: "\f005"; /* fa-star（塗り） */
	color: #f5a623;
}

.wc-review-submit {
	background: #c0392b;
	color: #fff;
	border: none;
	border-radius: 4px;
	padding: 10px 28px;
	font-size: 1em;
	cursor: pointer;
}
.wc-review-submit:hover {
	background: #a93226;
}
.wc-form-note {
	color: #888;
	font-size: 0.85em;
	margin: 8px 0 0;
}
.wc-review-login-required {
	color: #555;
}
.wc-review-login-link {
	display: inline-block;
	margin-left: 8px;
	color: #c0392b;
	text-decoration: underline;
}

/* ---- 一覧・トップ用のコンパクト星 ---- */
.wc-list-stars {
	display: inline-flex;
	align-items: center;
	gap: 5px;
	margin: 4px 0 2px;
	line-height: 1;
}
.wc-list-stars .wc-stars .wc-star::before {
	font-size: 0.85em;
}
.wc-list-count {
	color: #999;
	font-size: 0.8em;
}

@media screen and (max-width: 600px) {
	.wc-reviews-summary {
		gap: 16px;
	}
	.wc-average-num {
		font-size: 1.8em;
	}
}
