<?php
/**
 * Minimal footer — copyright + social only.
 *
 * @package Kutby
 * @since   2.7.0
 */

declare(strict_types=1);

namespace Kutby\Footer\Layouts;

use Kutby\Footer\Components\BackToTop;
use Kutby\Footer\Components\Copyright;
use Kutby\Footer\Components\SocialIcons;
use Kutby\Footer\Contracts\FooterLayoutInterface;
use Kutby\Footer\Support\FooterContext;

if ( ! defined( 'ABSPATH' ) ) {
	exit;
}

/**
 * Class MinimalFooter
 */
final class MinimalFooter implements FooterLayoutInterface {

	/**
	 * {@inheritdoc}
	 */
	public function id(): string {
		return 'minimal';
	}

	/**
	 * {@inheritdoc}
	 */
	public function label(): string {
		return 'مبسط';
	}

	/**
	 * {@inheritdoc}
	 */
	public function option_keys(): array {
		return array(
			'show_social',
			'copyright',
			'back_to_top',
		);
	}

	/**
	 * {@inheritdoc}
	 */
	public function render( FooterContext $ctx ): void {
		?>
		<footer class="kutby-footer kutby-footer--minimal">
			<div class="kutby-container">
				<div class="kutby-footer__bottom kutby-footer__bottom--minimal">
					<?php Copyright::render( $ctx ); ?>
					<?php SocialIcons::render( $ctx ); ?>
				</div>
			</div>
			<?php BackToTop::render( $ctx ); ?>
		</footer>
		<?php
	}
}
