<section class="profile">
	<header>
		<h1><?= $c->name ?></h1>
		<h3>Level <?= $c->level ?> <?= $c->title()['name'] ?></h3>
		<h5>owned by <?= $c->user_id === user()->id ? 'you' : $c->user()->username ?></h5>
	</header>

	<div class="grid">
		<section class="left">
			<div class="avatar">
				<img src="/assets/img/rathalos.webp">
				<img class="border" src="/assets/img/ui/borders/water.webp">
			</div>

			<?= c_profile_stats($c) ?>

			<div class="badges">
				<h4>Badges</h4>
				@TODO
			</div>

			<div class="traits">
				<h4>Traits</h4>
				@TODO
			</div>
		</section>

		<section class="right">
			<div class="bio">
				<h4>Biography</h4>
				<?= !empty($c->bio) ? parse_bbcode($c->bio)['html'] : "<i>[No bio.]</i>" ?>
			</div>

			<div class="gear">
				<h4>Equipped Gear</h4>
				<?= c_equipped_gear($c) ?>
			</div>

			<div class="inv">
				<h4>Inventory</h4>
				<?php
					for ($i = 0; $i < $c->inv_slots; $i++) {
						echo '<img class="mr-1" src="/assets/img/ui/2x3.png">';
					}
				?>
			</div>
		</section>
	</div>
</section>
