/**
 * Star Ratings - Display Only
 *
 * Pure CSS. No floats or bidi. Simple em-based sizing.
 *
 * http://codepen.io/cdillon/pen/vXNbBw
 *
 * Based on Pure CSS Star Rating Widget by James Barnett
 * http://codepen.io/jamesbarnett/pen/vlpkh
 */

.aggregate-rating {
	vertical-align: middle;
	white-space: nowrap;
}

.aggregate-rating.centered {
	text-align: center;
}

/* inline-block */
/* [title][stars][summary] */
.aggregate-rating .aggregate-title,
.aggregate-rating .aggregate-stars,
.aggregate-rating .aggregate-summary {
	display: inline-block;
	line-height: 30px;
	vertical-align: middle;
}

.aggregate-title {
	font-weight: 700;
	margin-right: 0.5em;
}

.aggregate-stars {
}

.aggregate-summary {
	margin-left: 0.5em;
}

/* if block */
.aggregate-rating.block .aggregate-title,
.aggregate-rating.block .aggregate-stars,
.aggregate-rating.block .aggregate-summary {
	display: block;
	margin: 0;
}

/* the stars */

.aggregate-stars span.star2 {
	display: inline-block;
}

.aggregate-stars span.star2:before {
	font-family: FontAwesome;
	content: "\f005";
	display: inline-block;
	font-size: 1.25em;
	/* use padding not margin */
	padding: 0 5px;
	transition: color 0.3s ease;
}

/* the magic */

/* this is how we highlight stars before the checked one (siblings before): */

/* hide the first label because our rating may be zero */
.aggregate-stars span.star0 { display: none; }

/* and turn all on */
.aggregate-stars span.star2:before { color: #FFB900; }

/* then turn off stars after the current rating */
.aggregate-stars span.current ~ span.star2:before { content: "\f006"; }

/* then turn on the current rating */
.aggregate-stars span.current:before { color: #FFB900; }

/* which may be a half star */
.aggregate-stars span.current.half:before { content: "\f123"; }


/* Responsive
--------------------------------------------------*/
@media only screen and (max-width: 480px) {
	.aggregate-rating .aggregate-title,
	.aggregate-rating .aggregate-stars,
	.aggregate-rating .aggregate-summary {
		display: block;
		line-height: 30px;
		vertical-align: middle;
		margin: 0;
		text-align: center;
	}
}
