/**
 * Mafar Points & Loyalty Public Styles
 * Using Figma color scheme: Navy Blue, Bright Blue, Soft Teal
 */

.mafar-points-dashboard {
	background: #fff;
	border: 1px solid #ddd;
	border-radius: 8px;
	padding: 20px;
	margin: 20px 0;
}

.mafar-points-dashboard h3 {
	margin-top: 0;
	color: #333;
	border-bottom: 2px solid #009FF0;
	padding-bottom: 10px;
}

.points-summary {
	display: flex;
	justify-content: space-between;
	align-items: center;
	margin: 20px 0;
	padding: 20px;
	background: linear-gradient(135deg, #009FF0, #0088D4);
	color: white;
	border-radius: 8px;
}

.points-card {
	display: flex;
	align-items: center;
	gap: 15px;
}

.points-display {
	text-align: center;
}

.points-number {
	display: block;
	font-size: 32px;
	font-weight: bold;
	line-height: 1;
}

.points-label {
	font-size: 14px;
	opacity: 0.9;
}

.tier-badge {
	padding: 5px 12px;
	border-radius: 20px;
	font-size: 12px;
	font-weight: bold;
	text-transform: uppercase;
}

.tier-bronze { background: #cd7f32; color: white; }
.tier-silver { background: #c0c0c0; color: #333; }
.tier-gold { background: #ffd700; color: #333; }
.tier-platinum { background: #e5e4e2; color: #333; }

.points-breakdown {
	display: flex;
	gap: 30px;
}

.breakdown-item {
	text-align: center;
}

.breakdown-item .amount {
	display: block;
	font-size: 20px;
	font-weight: bold;
}

.breakdown-item .label {
	font-size: 12px;
	opacity: 0.9;
}

.tier-progress {
	margin: 20px 0;
	padding: 15px;
	background: #f8f9fa;
	border-radius: 8px;
	border-left: 4px solid #009FF0;
}

.progress-header {
	display: flex;
	justify-content: space-between;
	margin-bottom: 10px;
	font-size: 14px;
}

.progress-bar {
	width: 100%;
	height: 10px;
	background: #e9ecef;
	border-radius: 5px;
	overflow: hidden;
	margin-bottom: 5px;
}

.progress-fill {
	height: 100%;
	background: linear-gradient(90deg, #009FF0, #10D6C3);
	border-radius: 5px;
	transition: width 0.3s ease;
}

.points-actions {
	display: flex;
	gap: 10px;
	margin-top: 20px;
}

.points-actions .button {
	background: #009FF0;
	color: white;
	border: none;
	padding: 10px 20px;
	border-radius: 4px;
	text-decoration: none;
	display: inline-block;
	transition: background 0.2s;
}

.points-actions .button:hover {
	background: #0088D4;
}

/* Points Balance Widget */
.points-balance-widget {
	display: inline-flex;
	align-items: center;
	gap: 10px;
	background: #f8f9fa;
	padding: 10px 15px;
	border-radius: 25px;
	border: 1px solid #e9ecef;
}

.points-info {
	text-align: center;
}

.points-count {
	display: block;
	font-size: 18px;
	font-weight: bold;
	color: #009FF0;
	line-height: 1;
}

.tier-name {
	font-size: 11px;
	color: #666;
	text-transform: uppercase;
}

/* Recent Activity */
.recent-points-activity {
	margin: 20px 0;
}

.recent-points-activity h4 {
	margin: 0 0 15px 0;
	color: #333;
	font-size: 16px;
}

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

.activity-item {
	display: flex;
	justify-content: space-between;
	align-items: center;
	padding: 10px 0;
	border-bottom: 1px solid #eee;
}

.activity-item:last-child {
	border-bottom: none;
}

.activity-date {
	font-size: 12px;
	color: #666;
}

.activity-description {
	flex: 1;
	margin: 0 15px;
	font-size: 14px;
}

.activity-points {
	font-weight: bold;
	font-size: 14px;
}

/* Redemption Catalog */
.mafar-redemption-catalog {
	background: #fff;
	border: 1px solid #ddd;
	border-radius: 8px;
	padding: 20px;
	margin: 20px 0;
}

.mafar-redemption-catalog h3 {
	margin-top: 0;
	color: #333;
}

.available-points {
	background: #e8f4fd;
	border: 1px solid #bee5eb;
	border-radius: 4px;
	padding: 10px 15px;
	margin: 15px 0;
	font-size: 16px;
}

.redemption-items {
	display: grid;
	grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
	gap: 20px;
	margin-top: 20px;
}

.redemption-item {
	border: 1px solid #ddd;
	border-radius: 8px;
	padding: 15px;
	background: #fff;
}

.redemption-item.available {
	border-color: #10D6C3;
	background: #E7FAF8;
}

.redemption-item.unavailable {
	border-color: #ccc;
	background: #f9f9f9;
}

.redemption-item h4 {
	margin: 0 0 10px 0;
	color: #333;
}

.redemption-item .description {
	color: #666;
	font-size: 14px;
	margin-bottom: 15px;
}

.redemption-details {
	display: flex;
	justify-content: space-between;
	margin-bottom: 15px;
	font-size: 14px;
}

.points-cost {
	font-weight: bold;
	color: #009FF0;
}

.discount {
	color: #10D6C3;
	font-weight: bold;
}

.expiry {
	color: #666;
	font-size: 12px;
}

.redeem-button {
	background: #009FF0;
	color: white;
	border: none;
	padding: 10px 20px;
	border-radius: 4px;
	cursor: pointer;
	width: 100%;
	transition: background 0.2s;
}

.redeem-button:hover {
	background: #0088D4;
}

.status.expired {
	color: #dc3545;
	font-weight: bold;
}

.status.insufficient {
	color: #ffc107;
	font-weight: bold;
}

/* Redemption Modal */
.redemption-modal {
	position: fixed;
	top: 0;
	left: 0;
	width: 100%;
	height: 100%;
	background: rgba(0, 0, 0, 0.5);
	display: flex;
	justify-content: center;
	align-items: center;
	z-index: 1000;
}

.modal-content {
	background: white;
	padding: 20px;
	border-radius: 8px;
	max-width: 500px;
	width: 90%;
	max-height: 80vh;
	overflow-y: auto;
}

.close-modal {
	float: right;
	font-size: 28px;
	font-weight: bold;
	cursor: pointer;
	color: #666;
}

.close-modal:hover {
	color: #333;
}

/* Responsive Design */
@media (max-width: 768px) {
	.points-summary {
		flex-direction: column;
		gap: 15px;
		text-align: center;
	}

	.points-breakdown {
		justify-content: center;
	}

	.points-actions {
		flex-direction: column;
	}

	.redemption-items {
		grid-template-columns: 1fr;
	}

	.redemption-details {
		flex-direction: column;
		gap: 5px;
	}
}
