"""
Public domain: landing page, marketing pages, legal pages.
"""
from pathlib import Path

from quart import Blueprint, render_template

from ..core import config

# Blueprint with its own template folder
bp = Blueprint(
    "public",
    __name__,
    template_folder=str(Path(__file__).parent / "templates"),
)


@bp.route("/")
async def landing():
    """Landing page."""
    return await render_template("landing.html")


@bp.route("/features")
async def features():
    """Features page."""
    return await render_template("features.html")


@bp.route("/terms")
async def terms():
    """Terms of service."""
    return await render_template("terms.html")


@bp.route("/privacy")
async def privacy():
    """Privacy policy."""
    return await render_template("privacy.html")


@bp.route("/about")
async def about():
    """About page."""
    return await render_template("about.html")
