{% set seo_title = title|default(title_key|trans(title_parameters|default({}), 'meta')) %}
{% set seo_description = description|default(description_key|trans(description_parameters|default({}), 'meta')) %}
{% set localizedRoutes = localized_page_routes() %}
{% set canonicalUrl = localizedRoutes.current.absoluteUrl|default(app.request.uri) %}
{% set business_name = contact_business_name() %}

<link rel="canonical" href="{{ canonicalUrl }}">
{% for localizedRoute in localizedRoutes.routes %}
    <link rel="alternate" hreflang="{{ localizedRoute.hreflang }}" href="{{ localizedRoute.absoluteUrl }}">
{% endfor %}
{% if localizedRoutes.default %}
    <link rel="alternate" hreflang="x-default" href="{{ localizedRoutes.default.absoluteUrl }}">
{% endif %}
<meta name="robots" content="{{ robots|default('index,follow') }}">
<meta name="description" lang="{{ app.request.locale }}" content="{{ seo_description }}">
<meta property="og:site_name" content="{{ business_name ?: 'site.name'|trans }}">
<meta property="og:title" content="{{ seo_title }}">
<meta property="og:type" content="website">
<meta property="og:url" content="{{ canonicalUrl }}">
<meta property="og:image" content="{{ absolute_url(asset(viti_theme_asset('images/logo-bk.png'))) }}">
{% if localizedRoutes.current and localizedRoutes.current.openGraphLocale %}
    <meta property="og:locale" content="{{ localizedRoutes.current.openGraphLocale }}">
{% endif %}
{% for localizedRoute in localizedRoutes.routes %}
    {% if localizedRoute.locale != localizedRoutes.currentLocale and localizedRoute.openGraphLocale %}
        <meta property="og:locale:alternate" content="{{ localizedRoute.openGraphLocale }}">
    {% endif %}
{% endfor %}
<meta property="og:image:type" content="image/png">
<meta property="og:image:alt" content="{{ 'seo.og_image_alt'|trans }}">
<meta property="og:description" content="{{ seo_description }}">
<meta name="twitter:card" content="summary_large_image">
<meta name="twitter:title" content="{{ seo_title }}">
<meta name="twitter:description" content="{{ seo_description }}">
<meta name="twitter:image" content="{{ absolute_url(asset(viti_theme_asset('images/logo-bk.png'))) }}">
<meta name="twitter:image:alt" content="{{ 'seo.og_image_alt'|trans }}">
