<?php
require __DIR__ . '/db.php';
require __DIR__ . '/includes/functions.php';

$city_name = isset($_GET['name']) ? trim($_GET['name']) : '';
if (empty($city_name)) {
    header("Location: /404.php");
    exit;
}

$city_slug = normalizeSlug($city_name);
$stmt = $pdo->prepare("SELECT id, name, seo_text FROM cities WHERE slug = ?");
$stmt->execute([$city_slug]);
$city = $stmt->fetch();

if (!$city) {
    header("Location: /404.php");
    exit;
}

$city_id = $city['id'];
$city_display_name = htmlspecialchars($city['name']);

$page = isset($_GET['page']) ? (int)$_GET['page'] : 1;
$profiles_per_page = 10;
$offset = ($page - 1) * $profiles_per_page;

$stmt = $pdo->prepare("SELECT p.*,
       c.name AS city_name
FROM profiles p
JOIN cities c ON p.city_id = c.id
WHERE c.id = ?
ORDER BY p.created_at DESC
LIMIT ? OFFSET ?
");
$stmt->bindParam(1, $city_id, PDO::PARAM_INT);
$stmt->bindParam(2, $profiles_per_page, PDO::PARAM_INT);
$stmt->bindParam(3, $offset, PDO::PARAM_INT);
$stmt->execute();
$profiles = $stmt->fetchAll();

$stmt = $pdo->prepare("SELECT COUNT(*) FROM profiles WHERE city_id = ?");
$stmt->execute([$city_id]);
$total_profiles = $stmt->fetchColumn();

$total_pages = ceil($total_profiles / $profiles_per_page);
?>
<?php

function removeSpecialChars($string)
{
    // 1) Forcer en minuscules
    $string = mb_strtolower($string, 'UTF-8');

    // 2) Tenter la translittération : on passe de UTF-8 à ASCII,
    //    en essayant de convertir les caractères accentués (é -> e, ö -> o, etc.)
    //    Attention : en fonction de la locale et de l’OS, iconv peut mieux ou moins bien marcher.
    $trans = @iconv('UTF-8', 'ASCII//TRANSLIT', $string);
    if ($trans !== false) {
        $string = $trans;
    }

    // 3) Remplacer tout ce qui n’est pas lettre ou chiffre par un tiret
    //    Ici on remplace la séquence de caractères spéciaux par un seul tiret
    //    (ex: "genève!!!" -> "geneve-").
    $string = preg_replace('/[^a-z0-9]+/', '-', $string);

    // 4) Enlever d’éventuels tirets en début ou fin
    $string = trim($string, '-');

    return $string;
}
?>
<!DOCTYPE html>
<html lang="fi">
<head>
    <meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
    <?php
$storage_dir = 'ads_counts/';
if (!is_dir($storage_dir)) {
    mkdir($storage_dir, 0777, true);
}
$file_path = $storage_dir . md5($city_display_name) . '.txt';
if (file_exists($file_path)) {
    // Lire le chiffre depuis le fichier
    $ad_count = (int)file_get_contents($file_path);
} else {
    $ad_count = rand(100, 2000);
    file_put_contents($file_path, $ad_count);
}$canonicalUrl = "https://" . $_SERVER['HTTP_HOST'] . strtok($_SERVER["REQUEST_URI"], '?');

?>
<title>Seksitreffit <?php echo $city_display_name; ?> | <?php echo $ad_count; ?> ilmoitusta löydettävissä nyt SEXSITREFFIT FI:ssä</title>
<link rel="canonical" href="<?php echo htmlspecialchars(mb_strtolower($canonicalUrl, 'UTF-8')); ?>">
    <script>
        var currentCity = "<?php echo $city_display_name; ?>";
        console.log("Current City:", currentCity);
    </script>
    <link rel="stylesheet" href="/styles.css">
    <link rel="stylesheet" href="/styl.css">
  <link href="/map/map-style.css"  rel="stylesheet" type="text/css"/></head>
<body>
    <?php include 'includes/header.php'; ?>
<div id="map-overlay" class="map-overlay"></div>
<section class="filters-section">
    <div class="filters">
        <div class="filter">
            <button class="filter-icon" id="filter-sex-btn" aria-haspopup="true" aria-expanded="false">
                <svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" fill="currentColor" viewBox="0 0 24 24">
                    <circle cx="12" cy="12" r="8" stroke="currentColor" stroke-width="2" fill="none"/>
                    <line x1="12" y1="6" x2="12" y2="18" stroke="currentColor" stroke-width="2"/>
                    <line x1="6" y1="12" x2="18" y2="12" stroke="currentColor" stroke-width="2"/>
                </svg>
            </button>
            <div class="dropdown-content" id="dropdown-sex" aria-label="Suodata sukupuolen mukaan">
                <button class="dropdown-item" data-value="">Kaikki</button>
                <button class="dropdown-item" data-value="homme">Mies</button>
                <button class="dropdown-item" data-value="femme">Nainen</button>
                <button class="dropdown-item" data-value="couple">Pari</button>
            </div>
        </div>
        <div class="filter">
            <button class="filter-icon" id="filter-photo-btn" aria-haspopup="true" aria-expanded="false">
                <!-- SVG Kuva Ikoni -->
                <svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" fill="currentColor" viewBox="0 0 24 24">
                    <path d="M21 5h-3.17l-1.84-2H7.01L5.17 5H2v14h19V5zm-9 14c-2.76 0-5-2.24-5-5s2.24-5 5-5 
                    5 2.24 5 5-2.24 5-5 5zm7-10l-2.5 3.01-1.5-2L8 15h8l3-4z"/>
                </svg>
            </button>
            <div class="dropdown-content" id="dropdown-photo" aria-label="Suodata kuvien mukaan">
                <button class="dropdown-item" data-value="">Kaikki</button>
                <button class="dropdown-item" data-value="with_photo">Kuvalla</button>
                <button class="dropdown-item" data-value="without_photo">Ilman kuvaa</button>
            </div>
        </div>
        <div class="filter">
            <button class="filter-icon" id="filter-tri-btn" aria-haspopup="true" aria-expanded="false">
                <!-- SVG Lajittelu Ikoni -->
                <svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" fill="currentColor" viewBox="0 0 24 24">
                    <path d="M3 18h6v-2H3v2zm0-5h12v-2H3v2zm0-7v2h18V6H3z"/>
                </svg>
            </button>
            <div class="dropdown-content" id="dropdown-tri" aria-label="Lajittele">
                <button class="dropdown-item" data-value="">Oletus</button>
                <button class="dropdown-item" data-value="jeune">Nuori</button>
                <button class="dropdown-item" data-value="vieux">Vanha</button>
                <button class="dropdown-item" data-value="ancien">Vanha profiili</button>
                <button class="dropdown-item" data-value="recent">Uusi</button>
                <button class="dropdown-item" data-value="inconnue">Tuntematon</button>
            </div>
        </div>
            <button id="reset-filters" style="display: none;"></button>
        </div>
  <button type="button" id="toggle-map-btn" class="toggle-map-btn" aria-label="Afficher la carte des régions de la Finlande">
    <p style="margin-right:10px">Kartta</p> <svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" width="24" height="24">
        <path fill="currentColor" d="M3.5 3.9L8 3l8 1.5 4.5-1.5V17.5L16 19 8 17.5 3.5 19.9V3.9zm1 1.9v11.2l3.5-1.2V5.8L4.5 5.8zm5.5.6V17.2l6-1.1V5.8L10 6.4zm8-1.4v11.2l2.5-.8V4.8L18 5z"/>
    </svg>
</button>
        <div id="finland-map-container" class="finland-map-container" aria-hidden="true">
    <button type="button" class="close-map-btn" aria-label="Fermer la carte">&times;</button>
<span id="fijstip"></span>
<div id="mapwrapper">
  <div id="mapbase">
    <svg version="1.1" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 440 760" xml:space="preserve">
      <g>
        <path id="fijs1" fill="black" stroke="#FFFFFF" vector-effect="non-scaling-stroke" d="M57.75,723.083c-1.917,1.167-3.25-0.417-4.083,0s-1.25,1.5-2.667,1.5s-2.583-1.999-0.5-2.583c1.874-0.525,1-3.334,3.5-2.167S59.667,721.916,57.75,723.083z M47.25,714.352c-1.917-0.648-2.75,1.814-2.083,3.157s-1.117,1.468-2.083,0.824c-2.249-1.498-1.417,0.333-3.917,0.875s-0.083,1.542,1.333,1.542s-0.5,1.583,2.083,3.083s2.917-2.417,2.667-3.333s1.083-1.667,1.667-1.89S49.167,715,47.25,714.352z M39.167,712.594c-1.333-1.011-1.083-2.511-0.25-3.011s1.646,2.538,4.198,2.228s3.136-1.145,2.969-3.645s-0.083-2.75-1.25-3.25s0.562-0.833-1.719-2.333s-3.866-3.001-5.032-1.917s-2.332-0.166-2.249-1.916s-1.417-4-3.583-0.75s-0.5,4.75,0.833,4.75s3.25,0.417,2.583,2s-2.333,1.999-2.5,3.416s-0.756,4.168-1.961,1.334s0.455-3.75,0-4.417s-3.706,4-4.789,2s-2.25-0.501-2.833,0.083s0.333,2.89-0.417,4.028s-2.333,2.296,0,3.051s1.917-1.474,3.083-1.651s-0.917-2.344,0.833-2.511s1.25,6.877,3.417,6.938s3.667,1.83,4.917,0.487s2.31,1.819,3.5-2.676C39.254,713.56,40.5,713.604,39.167,712.594z"/>
        <path id="fijs2" fill="black" stroke="#FFFFFF" vector-effect="non-scaling-stroke" d="M250.334,629.833c-4.5-2.833-1.5-3.167-3.178-4c-1.679-0.833,0.178-5.5,0.01-9.167c-0.167-3.667,1.668-1.666,1-5.999c-3,0-2.666-1-4.832-1.667c-2.167-0.667-5.334-9.167-8.668-9.833c-3.333-0.666-2.5,3-4.166,6.333s-1-3.833-6.5,0s-2,3.833-4,5.5s-0.5,5.333-1,8s-15.667,0.833-17.333,1s-2.833,2.667-1.333,4.167s-1.167,4.333,0,7.166s4.667,1.5,4.833,2.567s2.333,1.1,4.667,1.933s0.667,5,1.167,7.167s-0.167,3.666-1.833,4s-5.333,6.5-5.333,9.333s5.5,4.167,3.5,5s-3.167,4,0,4s4,1.167,5.207,3.667s2.793,0.666,4.959-0.834s1.167,2.167,3.5,6.232c2.334,4.065,6.666-1.065,8.5-0.502s3.334-2.896,4.166,0c0.833,2.896,4.668-2.063,7,0.502c2.333,2.565,4,0.768,3.834-2.232c-4.334-2,1.334-4.666-2.666-5.666s-2.334-3.834-1.5-5c0.833-1.166,2.332-3-0.741-3.334c-3.074-0.334-0.759-3.666,0.741-3.666s1.332-4.5-0.334-8s2.166-2.5,4.5-2s2.5-2.5,5.334-3.167c2.833-0.667-1.167-2.833,3.5-6C253.167,633.333,254.834,632.666,250.334,629.833z"/>
        <path id="fijs3" fill="black" stroke="#FFFFFF" vector-effect="non-scaling-stroke" d="M358.5,600.166c-1.833,1.5-1.833,5.668-5.333,5.334s-2.834,9.466-11.167,9.466c-13.833,0-5.833,4.034-11.333,4.034s-8,0-9-1.5s-2-1.5-2.5,1.5s-4.001,9.166-7.667,8.833s-8.5,2.025-12.333,0.013s-8.501,3.99-11.667,0.822s-3.834-2.002-8.5-2.835s-3,1.833-5.166,1.5c-2.167-0.333-5.834,1-2.167,3s6.166-0.667,8.833,2.833s-1.667,3.001,0,4.834s1.166,4-2.5,4.833c2.834,4.833,1.833,6,0,6s-4.531,1.533-2.333,3.667c4.122,4-0.957,5.539,1.646,7.333c4.354,3,6.02,0.333,7.187,3s4.833,4.667,7.5,4.667c6.334,0,3.667,4.5,6.334,3.5c2.666-1,2.832,6.667,7.666,5.5c0.938-1.563,1.834-3.5,2.667-3.5s9.167-9.834,10.333-10.831s2.5-0.169,4-0.003s2.667-5.833,2.834-7.5s3.333-3.333,5-5.166s2.333-1,2.666-1.834s7.834-6.333,8.5-6.333s2.834-2.667,3.167-4s3.833-4.5,4.5-8s1.5-3.333,2.5-3.166s8.166-6.5,9-11.201s9.333-7.966,8.5-10.299s7.333-7,9.333-9.765s3.333-9.402,6-12.069c-3.333,1.5-10.334,9.833-13.5,9.833S360.333,598.666,358.5,600.166z"/>
        <path id="fijs4" fill="black" stroke="#FFFFFF" vector-effect="non-scaling-stroke" d="M317.167,545.166c-2.5-0.167-1,6-2.833,6s-3.834,3.334-1.834,4.738s0,2.262,2,3.096s1.167,2,2.834,1.833s4,2,5.666,4.167s3,3.5,1.834,5.333s-4.334,0.333-8.667-1.667s-4.834-0.499-7.667,0.001s-2.167-3.834-9.666-3.667c-2.505,0.056-4.168-4.167-5-6.333c-0.834-2.166-6.834-6.001-8.667-8.001s-4.167,0-7.667,1.979s-1-4.145-8.666,0.688c-3.105,1.957-3.334-2.5-7,0c-3.667,2.5,2,5.5,0,6.167s-2,3.666-2.5,6.833s-3.667,0.833-6.167,1.167s-4.001,2.333-6.167,7.5s4.666,9.333,2.334,12.167c-2.334,2.834,1.832,8.833,1.166,11.921s5.5,5.579,3.334,9.579c-2.167,4-2.668,2-5.668,2c0.668,4.333-1.167,2.332-1,5.999c0.168,3.667-1.688,8.334-0.01,9.167c1.678,0.833-1.322,1.167,3.178,4s2.833,3.5,3,5.5c4.666-3.167,4.833,1,6,3.667c1.166,2.667,4-1.834,4.333-3.667s4.167-1,3.833,2.167s1.667,3.333,2.607,4.666c0.941,1.333,4.227,1.5,7.893,0.667s4.167-3,2.5-4.833s2.667-1.334,0-4.834s-5.166-0.833-8.833-2.833s0-3.333,2.167-3c2.166,0.333,0.5-2.333,5.166-1.5s5.334-0.333,8.5,2.835s7.834-2.835,11.667-0.822s8.667-0.346,12.333-0.013s7.167-5.833,7.667-8.833s1.5-3,2.5-1.5s3.5,1.5,9,1.5s-2.5-4.034,11.333-4.034c8.333,0,7.667-9.8,11.167-9.466s3.5-3.834,5.333-5.334c0.833-4,0-4.833,1.167-6.833c1.121-1.921-1.667-7.5-1-7.833s-0.667-4.333-4.167-5.167s-3.333-10.333-3.167-13s-5.5-3.833-4.666-10.666c0.283-2.321-3.167-3.167-4.5-1.834s-4.333-2-2.833-3.666s-3-4.5-3-6s-5.5-6.667-9.834-7.167S319.667,545.333,317.167,545.166z"/>
        <path id="fijs5" fill="black" stroke="#FFFFFF" vector-effect="non-scaling-stroke" d="M337.167,338.167c-2.666-1.667-3,2-4.167,3.833s-3.167,1.833-4.667,0.914s-5,0.919-8.666,2.752s-1.334,4.833-2.667,6.833s-2.333,2.667-13,3.167s-5.166,7.833-6.166,10.667s-8.5-3.333-9.5-0.833s-2.167,3-4.667,2s-5,0.167-6.833,2.833c-1.834,2.667,3.666,2.167,4.5,4.167c0.833,2,1.833,10.667,1,11.493c-0.834,0.826-4,2.007-6.834,0.34s-1.5,3.334-5.833,3.334s-5,8.833-7.667,9s-2.833,5.667-5.333,4.833s-2.5,2.667-4.833,4.334c-2.334,1.667-0.334,3.333,2.5,4.833c2.833,1.5,0,3.5,0,5.833s2.333,2.834,3.666,2.976s3-0.142,4.667,1.858s1,11.5,1,14.666s0.167,1.167,2.499,4.332c3.168,0.833,8.667,3.999,12,3.833c3.334-0.166,8.501-0.666,10.168,0.667c1.666,1.333,11.333,7.666,12.5,9c1.166,1.334,9,11.667,9.333,10.167s2.334-3.333,2.5-5s2.666-9.667,3.666-9.167s12.334,3.334,14.834,3.167s22.334-5.001,23-3.667s2.333,12.166,3.833,10.5s4-2.848,8-1.924c0,0,7-5.075,7.5-6.742s5.833-14.833,6.333-17.5s-0.833-8.333-0.833-10.5s-10-8.166-11.834-9.5s-3.833-9-4.333-11.333s1.667-3.667,2.167-4.833s0.333-5.834-0.667-7s0-3.167-0.833-4.5s-7.167-1-9.667-2.167s-4-14.333-3.5-16.5S359,367,356.167,361.5c-1.313-2.549,1.166-4.333,0-5.667s-5.5-0.667-6.834-0.833s0.834-5,1.5-6s1.834-11.167,1.834-12C347.667,337.833,339.833,339.834,337.167,338.167z"/>
        <path id="fijs6" fill="black" stroke="#FFFFFF" vector-effect="non-scaling-stroke" d="M298.334,671c-2.667,1,0-3.5-6.334-3.5c-2.667,0-6.333-2-7.5-4.667s-2.833,0-7.187-3c-2.604-1.794,2.476-3.333-1.646-7.333c-2.198-2.134,0.5-3.667,2.333-3.667s2.834-1.167,0-6c-3.666,0.833-6.951,0.666-7.893-0.667c-0.94-1.333-2.941-1.499-2.607-4.666s-3.5-4-3.833-2.167s-3.167,6.334-4.333,3.667c-1.167-2.667-1.334-6.834-6-3.667c-4.667,3.167-0.667,5.333-3.5,6C247,642,246.834,645,244.5,644.5s-6.166-1.5-4.5,2s1.834,8,0.334,8s-3.815,3.332-0.741,3.666c3.073,0.334,1.574,2.168,0.741,3.334c-0.834,1.166-2.5,4,1.5,5s-1.668,3.666,2.666,5.666s2.666,5.167,6.166,5.167s0.5,3.999,3.5,3.833s2-3.499,5.334-2.166s1.491,4.108-1.334,3.833c-6.832-0.667-3.168,5.902-6.416,11.251c0.166,1.083,1.25,0.084,1.75,1.417s-1.083,0.333-0.583,1.926s1.417,0.657,1.569-0.093c0.153-0.75,1.014,0.417,2.514,0s-0.666-1.583-1.583-1.833s-1.333-1-0.417-1.25s2-0.167,2.917,1.359s2.167,0.224,2.917,0s-1.167-2.693-0.5-3.214s1.583,0.188,1.416,1.604s0.667,0.666,2.417,1.481s-0.917-2.565,0.75-1.815s0.083,0.75,1.417,1.584s1.833-0.834,1.312-1.084s0.188-0.833,0.021-1.771s0.667-1.146,1.417-1.313s0.916-0.833,1.25-2.083s2.25-0.834,2.333,0.25s1.917,1.833,3.5,1.166s-2-2.75-0.5-3.083s2,1,3.25,2.583s1.167,0.334,2.97,0.834s0.197,0.416,0.03,1.646s0.333,0.188,1.917,0.845s1.25-0.24,0.75-1.574s0.5-0.666,1.75,0.084s3.25-1.834,3.583-1.084s-0.917,0.667-1.417,1.729s0.667,1.021,1.084,0.438s2.5-0.25,3.583-0.438s-1.667-0.396,0-2.063S292.5,687,293.834,686s1.333,2.666,2.666,2.333s8.667-11.833,9.5-11.833C299.875,677,301,670,298.334,671z"/>
        <path id="fijs7" fill="black" stroke="#FFFFFF" vector-effect="non-scaling-stroke" d="M185,511.5c0.167,3-0.5,5.167,2.5,7.833s-4.167,2,1.333,9.334c2.562,3.415-0.667,5.166,2.532,7.737s-0.198,2.929-0.032,7.096s-0.167,4.667-4.833,4.667s-1.333,3.166-6.333,2.5s-1,4.166-6.5,4.166c0.667,2.5-1.5,6.501,2.333,8.167s4.5-0.168,5.667,2.666s2.667,4.333,5.5,4s4.166-0.333,6.333,2.167s3.667,10.333,2,12s-6.5-0.5-4.333,4.5s6.091,7.334,5.045,9.667s-2.045,5.833,0.955,6.333s3.616,2.289,2.475,2.645s-3.358,4.022,0,6.022s1.524,5.334,2.025,7c1.667-0.167,16.833,1.667,17.333-1s-1-6.333,1-8s-1.5-1.667,4-5.5s4.834,3.333,6.5,0s0.833-6.999,4.166-6.333c3.334,0.666,6.501,9.166,8.668,9.833c2.166,0.667,1.832,1.667,4.832,1.667s3.501,2,5.668-2c2.166-4-4-6.491-3.334-9.579s-3.5-9.087-1.166-11.921c2.332-2.834-4.5-7-2.334-12.167s3.667-7.166,6.167-7.5s5.667,2,6.167-1.167s0.5-6.166,2.5-6.833s-3.667-3.667,0-6.167c-1.334-3.333-2.834,0.833-7-4.167c-2.579-3.094-0.334-3.333,1.166-4.333s2.5-4.667,1.167-8.429s-3-7.404-6-6.904s-7.833-7.167-10.167-9.667s4.834-1,7-3.5s-2.333-3,0.167-5.167s0.5-2.833-2.605-5.833s-0.895-7.666-0.728-10.666c0.166-3-1.334-8.667-2.667-10.667c-2.156-3.234-5.167,1.5-6.833-4c-0.704-2.322-3.167-3-7-2.5c-3.834,0.5-9.167-5.5-11.5-7s-4.5,1.167-4.293,4.667s0.459,6-5.041,5.741s-5.167,3.925-7.858,5.925s0.358,12,0,14.833s-8.308-0.833-12.642,3.167S184.833,508.5,185,511.5z"/>
        <path id="fijs8" fill="black" stroke="#FFFFFF" vector-effect="non-scaling-stroke" d="M145,455.834c2-0.5,6.52,5.522,9.333,4.075c5.333-2.742,4,1.408,6.5,0S163,457.253,166,460.21s4.334,4.123,3.667,4.957s-3.667,2.834-5.333,1.334s-1.333-2.334-3.667-0.834s-1,2-0.167,3.167s2.833,0.167,4.5,4.5s3.667,4.666,0.833,9.833c0.667,2.834,5.917,9.5,8.042,9.5s1.958,0.551,6.458,4.275s-0.5,4.893,1.333,6.059s3.666,0.998,5.333,1.832c4.333-4,12.283-0.334,12.642-3.167s-2.692-12.833,0-14.833s2.358-6.184,7.858-5.925c-2.167-3.093-11.167-14.407-13.833-17.835s-1.333-8.905-5.333-9.739s-2-6.666-4.333-7.333s-1.5-4.667-1.333-7.167s-9.167-10.5-12.5-12.167c-2.333,2.333-1.5-2.333-3.833,0s2,5,0,5.334s1.5,6.5-1.667,6.5s-1.167-4-4.333-2.667s2.167,12.667-7.833,11.962c-5.063-0.357-2,0.705-6.167,1.205s-0.167-1.5-4.833-1.167C143,450.001,143,456.334,145,455.834z"/>
        <path id="fijs9" fill="black" stroke="#FFFFFF" vector-effect="non-scaling-stroke" d="M133.833,711.084c-1-0.333-2-0.25-1.75,2s1.005,3.001-0.039,4.334s-3.128,0.832-2.878,2.416s1.25,2.417,0.917,3.167s-2.584,1.334-3.417,0.167s-0.833,0.249-2.083-0.834s-1.833,1.25-3.25,0.75s-1.5,0.5-2.417,0.167s-2.333,0.25-2.833-2.5s-0.083-3.5,0.917-3.5s1.917-0.001,2.083,1.083s1.416,0.416,1.083-0.5s-1.917-0.834-2-2s3.333-0.25,3.333-1.333s-3.667,0.667-3.75-1.25s1.833-1.916,1.75-2.583s-0.083-1.668,1.083-1.584s-0.833,0.918,1.167,1.084s3.583-0.916,4.667-0.75s4.75-0.417,5.25-0.417s1.167-0.583,1.417-1.25s1-2.25,1.5-2.75s0.75-1.834-0.083-1.667s-1.583,1.334-1.917,1.917s-1.917,2.083-3,2.333s-3.583,1.834-5.083,0.834s0.083-1.918-0.667-2.584s-1.334,1.834-2.667,1.584s-1.5-2.667-0.25-3.167s1.167-2.5,2.583-3s0.417-1.833-0.5-1.833s-2.25-0.083-2.083,0.75s-0.833,0.582-1,1.416s1.75,0.416,0.75,1.25s-3.083-0.249-2.833,1.334s1.417-0.5,1.25,1s-1.583,1.334-1.5,2s-1.84,0.333-1.712,1.833s1.128-0.667,1.128,1s-0.917,2.917-1.667,3.417s-2-0.333-2.167,0.75s-0.917-1.75,0-2s1.25-0.916,0.75-1.5s-2.083,1.75-2.75,0.583s-1.083-2.084,0-2.667s3-1.167,2.833-2s-2.417,1.001-2.5,0.084s-2.083,0.416-3.25-0.417s-1.667-1.25-0.417-2.75s2.667-0.916,4.167-0.583s2,1.584,2.583-0.25s1-2.001-0.083-2.084s-3.667,2-5.083,0.75s-1.75-1.583-0.167-2.333s0-1.667,1.25-2.25s1.417-0.084-1.25-1.417s-3.167-1-4.25-2.25s-2.25-2.834-2.917-4s-3-0.999-2.333,0.584s1.75,1.707,1.417,2.729s-1.083-0.145-2.083-0.479s-1.5-0.668-1.333-1.834s-0.083-2.416,0.833-3.583s-0.25-2.666,0.25-3.833s-1.5-1.916-2,0.5s-1,3.5-2.333,3s-1.833,0.75-1.167,1.333s0.083,2.834-0.75,3.417s-2.5,1.833-2.417,0.083s1.161-1.001-0.003-2.417s-1.913-1.5-1.08-2.5s-1.583-0.916-1.583-0.916s-2.833,0.333-1.583-1.417s-3.417-2.584-2.75-4.667s2.667,0.666,3.417-0.75s-0.667-1.166-0.333-2.166s-2.167-1.084-2.083-2.334s-0.5-1.917,0.167-3s-2.167-1.666-1.75-2.916s1.583-0.25,2-1.167s-2.417-0.417-2.917-1.417s-2.833,2.834-3.333,0.834s0.5-2.5,1.833-2.417s2.333,0.75,1.583-1s-3.083-1.751-1.667-3.167s1.833-0.667,2.333,0.75s1.667,3.667,2.583,2.417s-2.333-3.25-1.917-4.75s-2.5-3.168-2-4.084s3,2.418,3.917,1.334s0.167-1.667,1-3.167s-0.167-2.583,0.167-4.25s1.584-0.584,2.417-1.667s-0.917-1.416-0.75-2.416s2.75,1.333,3.083,0.333c1.75,3.417,5.917-0.658,6.777,9.314c0.295,3.426,3.474,0.602,6.807,1.769s5.833-2.834,7.167-2.5s8.167,1,6.667-1.5s2.833-3.834,7-1.5s4.333-1,3.333-4.167s0.167-2.333,3.667,0s5.667,1.833,7.5,3c-1.833,2.167,1.5,3.5,3.667,4.898s-1.167,3.102-4.167,4.935s1.167,4.667-0.5,5.834s0,2.833,4.167,5s3.833-0.667,5.333-1.001s4.333,2.5,7.167,4.834s4.333,1.666,8.667,3.621c-0.333,1.788-0.167,6.046-1,7.046S161.5,687,159.172,687s-4.505,1.667-3.005,2.5s5,3.5,1.5,4.584s0.667,5.249-3.5,5.685s0.667,5.731-1.167,7.852s-3.5-1.62-6.5,0.546s-2.667-2.666-5.333,0.667S136.333,708.333,133.833,711.084z M107.75,711.416c-1.333-0.667,0.333-3.25-1.333-3.25c-1.583,0-0.583,2.584-2.583,2.917s0.333,3.417-1,4.167s-0.583,1.583,1.333,1.764s1.75-2.931,2.917-2.931S109.083,712.083,107.75,711.416z M98.667,710.083c-2.5,0-4.5,3.583-3.833,5.75s3.5,0,5.083-1.25S100.667,710.083,98.667,710.083z M92.083,711.25c-2.333,0.917-6.167,4.5-3.333,5.771s4.25-0.188,4.583-1.605S93.402,710.731,92.083,711.25z M84.667,705.916c-1.75,0.166,0.75,3.25-0.833,3.76s-1.333-1.343-2.5-1.51s-1.815,2.129,0,3.028c3.25,1.611,5.5-0.278,5.25-1.778S86.417,705.75,84.667,705.916z M105.296,703.833c0.463-1.167-0.13-2.917-1.213-4.417s-2.333-1.5-1.25-2.75s1.667,0.75,3-0.166s0-1.334-2.333-2.667s-0.75,0.5-1.833,0.833s-1.957-2.433-3.25-0.583s0.417,0.917,0.417,2.75s-0.667,0.833-1.108,2.083s3.858,1.417,4.435,3.667s-2.076,1.013-2.076,1.833c0,0.833-0.75,0.5,0.662,1.491S104.833,705,105.296,703.833z M86.603,688.917c-0.731-0.166-2.265-3.066-3.2-2.084c-1.348,1.416,3.015,6.334,3.681,5.563S87.333,689.083,86.603,688.917z M82.333,691.75c1.167-0.25-1.003-4.2-2.131-3.75C77.905,688.917,81.167,692,82.333,691.75z"/>
        <path id="fijs10" fill="black" stroke="#FFFFFF" vector-effect="non-scaling-stroke" d="M226.334,322.168c4.832,0.5,8.332,1.889,10.332-0.056s9.29-6.611,8.896-4.111c-0.396,2.5-0.396,5,3.438,5s18.499,4.293,22.166,0.98c3.668-3.313,11-17.646,13-16.313s3.5-1.667,4.5,0.833s3.334,6.333,6.668,6.833c3.332,0.5,10,3.5,13.333,1.833s5.333-2.333,5.333-5.333s-5.334-4.5-3-6.5s7.834,0.167,9.167-2.833s-3.333-2.167-3.5-5.833s3.979-0.333,3.739-5.167s1.094-4.667-2.239-5.833s-3.834-4.833-4.667-6.833s-1.334-3,1-4.333s3-1.5,3-3.167s0.615-3,2.975-1.5s9.192,5.333,23.692,2c-0.5-1.167-2.167-7.167-2.833-7.833s-14.834-22.667-14.667-24.016s24-45.817,24-46.484s0.5-10.513,0.5-10.513s-9.334-6.321-10-6.821s-9.667-21-10-21.5S315,147.5,315,147.5s-6.333-22.167-6.166-22.833s3.833-6.667,5.666-9.333s2.334-8,2-13s-7-2.833-7.833-3s10-8.5,10.667-9s-1.667-6.667-2.167-7.333s0.333-6.333,0.5-7.833s11.666-16.333,11.666-16.333s-5-16-6-16.5S307,34.667,304.667,33.667S303.5,28.167,302,27.5s-8.5-6.5-9.167-8.5s-1.333-2.5-3-1.685s-3,0.519-5,0.019S275,26.5,273.167,27.667S265.334,27,263,25.167s-3.833,1-6.166,1.667s-4.5,7.167-5.334,9s-9.166,8.833-10.166,11s1.333,5,0,6.167c-1.334,1.167-0.334,4.167-2,11.919c-1.667,7.752-3.334,18.748-2.5,23.748c0.833,5-1.168,8.333-1.334,9.833s-3.5,1.5-5.5,1.167s-7.5,7.167-8.666,8.667c-1.167,1.5,0.333,6.833,0.166,9.167s-4.333,1.167-5,2.833s-5-6-10.667-8.833s-11.5-7-13-8.667s-7.167,3.5-7.833,6.5S178.833,112,175.667,113s-3.667,1.667-4.167,0.167s-3.833-1.5-6.5-1.667s-3.333,0.167-6.333-3.5s-4-0.5-5.333-0.5s-0.667-7-0.833-8.167s-13.833-29.833-14.667-31s-6-2.5-9.5-3.333s-8.333,5-10,6.333s1.833,5.5,2.5,6.667s-0.333,3.833-1,4.5s-7.667-5.333-7.667-5.333s-5.5,4.167-5,4.833s5.667,7.167,6.5,8.167s0,4.167,0.667,5.5S117.5,97,118.833,98s6.833,13.5,7.667,14.667s6.333,3,6.5,4.167s3.333,4,4.833,4.333s2.167,4.333,2.5,6s5.167,1.333,6.5,1.833s7.667,3.167,9.167,4s10.167,9,11.333,9.489s0.667,7.177,0.667,8.177s2.5,3.167,4.167,3.333s1.333,2.5,1.333,3.667s5.5,7,5.833,7.833s-3,5.333-3.833,6s0.167,14-0.333,18.167s-3.167,8.167-1.667,11.319s3.167,1.18,5.667,1.514s1.333,2.667,0.667,3.833s1.167,4.333,1.167,4.333s-4.167,1.333-5.833,3s0.167,7.384,0.167,7.384s9.167,22.116,10.167,23.45s0.667,1-3,4.167s0.833,11.5-2.667,13.833s-0.333,3.833-4.333,7.833s1.833,4.667-0.5,7.5s1,2.667,0.667,5.833s1.333,6,4.833,8.667s0.667,5.667,3.667,9.5s-0.833,5.833,2,9s0.167,5,1.833,7s3.333-3.333,6,0s3.833-0.5,5.5,2.833s-3.333,2-1,6.513s2.667-1.68,5.167,1.154s4-3.667,6.5,0s2.833-1.667,4.5,2.5c4.167-2.333,5.667-4.5,7.667-5.333C224.334,324.668,221.5,321.668,226.334,322.168z"/>
        <path id="fijs11" fill="black" stroke="#FFFFFF" vector-effect="non-scaling-stroke" d="M85.917,579.501c1.667-0.167,1.833-3.083-0.333-3.75s-0.75-2.166-1.75-2.833s0.5-5.751-0.917-7.001s-1.666,0.667-2.583-0.583s0.25-2.084-0.333-2.917s-1.178-0.166-1.797-1.333s0.381-1.667-0.369-2.917s-1.833-0.249-2.083-1.416s2.583-2.833,1.5-4.833s0.25-1.501,0.25-2.084s-1.75-3.916-2.667-2.333s-1.667,0.5-1.083-0.75s2.25-4.417,3-5.167s2.583-3.583,3.583-1.083s2.5-2.526,1-4.097S80,536.501,80,532.501s1.167-3.334-0.5-4.667s-2-5.167,0.833-4.667s2.5-0.166,1.5-2.833s-0.401-5.667,1.883-4.667s2.45-1.999,4.784-0.666s2.334-3.834,4.167-3.667s2-5.666,1.5-6.166s-3.5-4.833,0.5-3s6.167-0.168,3.667-1.834s-3.167-3.5-1.333-4.333s-0.667-5.166,2.333-6.333s-1-4.667,4-4.667s-0.5,4.001,4.667,4.167s3.5,2.834,5.5,1.5s-2.833-3.166-0.333-4.5s4.5-1.5,5.5,1.333s-0.333,3.001,2.5,1.167s6.167-2.167,4.333-4.667s-6.167-8.167-3.5-9s-0.667-3.667,3.333-3.667s0.167-4.5,4.5-5.333s1.5-4.668,4.5-4.834s0-5.166,3.5-7.666s-1-5.334,3.667-5.667c1.5,2.167,1.5,8.5,3.5,8s6.52,5.522,9.333,4.075c5.333-2.742,4,1.408,6.5,0S163,457.253,166,460.21s4.334,4.123,3.667,4.957s-3.667,2.834-5.333,1.334s-1.333-2.334-3.667-0.834s-1,2-0.167,3.167s2.833,0.167,4.5,4.5s3.667,4.666,0.833,9.833c-0.667-2.834-5.167-5.833-10.333-5.5s-2.5,6.334-5.167,7.986s-6.167,0.181-9,0.014s-11,1.167-10.833,5.834s1.833,2.833,2.667,6.166s1.333,3.667-1.833,4s-6,7.334-7.5,9.667s-2,4.667-1.167,6.137s-3.333,4.863-5.667,8.043s-5.667-2.013-7.833-2.347s-3.5-5.666-6.744-5.696s-0.589,4.03-1.423,6.696s0.167,2.5,1.167,4.167s-1,1.833-4.833,5.333s-1.5,6-4.833,10.334s-0.667,3.166,1.468,7.333s2.866,2.167,3.532,5.5s3.833,4.333,0,6.167s1.667,6-1.333,6.666s-2,6.667-2.167,8.833C90.167,577.333,88.5,580.667,85.917,579.501z M78.25,507.875c1.125,2.125,2.875,1.875,2.375,0.625s1.25-1.375,3.25-1.75s3.25-4.375,0-4.375s-0.495,2.447-3.25,2.625c-3.875,0.25-1.875-3.625-2.625-3.625s-2-1.75-2.75,1.875S77.125,505.75,78.25,507.875z M84.125,498c0.875-1.125,0.375-2.625-1.375-2.875s-4.215,0.765-2.875,2.875C80.51,499,83.25,499.125,84.125,498z"/>
        <path id="fijs12" fill="black" stroke="#FFFFFF" vector-effect="non-scaling-stroke" d="M141.5,559.667c2.5-2.334,5.167-0.358,6.833-3.763s1-6.403,4.5-3.737s3.833-2.168,7.167-0.334s1.833-6.833,8.5-4.333s-0.333,7.333,5.167,7.333s1.5-4.832,6.5-4.166s1.666-2.5,6.333-2.5s5-0.5,4.833-4.667s3.23-4.524,0.032-7.096s0.03-4.322-2.532-7.737c-5.5-7.334,1.667-6.668-1.333-9.334s-2.333-4.833-2.5-7.833s-2.333-2.667,2-6.667c-1.667-0.834-3.5-0.666-5.333-1.832s3.167-2.334-1.333-6.059s-4.333-4.275-6.458-4.275s-7.375-6.666-8.042-9.5s-5.167-5.833-10.333-5.5s-2.5,6.334-5.167,7.986s-6.167,0.181-9,0.014s-11,1.167-10.833,5.834s1.833,2.833,2.667,6.166s1.333,3.667-1.833,4s-6,7.334-7.5,9.667s-2,4.667-1.167,6.137s-3.333,4.863-5.667,8.043s-5.667-2.013-7.833-2.347s-3.5-5.666-6.744-5.696s-0.589,4.03-1.423,6.696s0.167,2.5,1.167,4.167s-1,1.833-4.833,5.333s-1.5,6-4.833,10.334s-0.667,3.166,1.468,7.333s2.866,2.167,3.532,5.5s3.833,4.333,0,6.167s1.667,6-1.333,6.666s-2,6.667-2.167,8.833c3.833,1.167,5-0.329,6.333,1.252s1.833,2.077,5.333-1.504s7-6.581,10.333-6.248s2.667-6.667,6-6.5s3.5-9.833,6-7s2.167,2.667,4.667,2.667S139,562.001,141.5,559.667z"/>
        <path id="fijs13" fill="black" stroke="#FFFFFF" vector-effect="non-scaling-stroke" d="M416.667,510.334c-0.666-3-1.667-3.666-5.334-5.666s-5.333-6-5.333-9.334s-2.667-5-7-7.333s-11-7.333-12.333-7.093s-4.334-1.574-6-4.907s-12-13.333-14.667-16.092c-4-0.924-6.5,0.258-8,1.924s-3.167-9.166-3.833-10.5s-20.5,3.5-23,3.667s-13.834-2.667-14.834-3.167s-3.5,7.5-3.666,9.167c2.5,2.833,4.667,4.333,6.167,4.333s0.334,8,3,8.167s-0.833,2.501,0,4.167s-1.001,8.167,2.166,9.5s-3,8.167-1,10s6.001,12.333,6.834,12.833s7.999,4.333,7.166,4.333s-4.167,2.608-4,3.138s3.834,5.696,2.334,6.696s-2.834,4.499-4.167,3.666s-5-3.334-5-1.5s-3.667,1.834-2.5,4.667s1.833,4.333,2.833,7c4.334,0.5,9.834,5.667,9.834,7.167s4.5,4.334,3,6s1.5,4.999,2.833,3.666s4.783-0.487,4.5,1.834c-0.834,6.833,4.832,7.999,4.666,10.666s-0.333,12.166,3.167,13s4.834,4.834,4.167,5.167s2.121,5.912,1,7.833c-1.167,2-0.334,2.833-1.167,6.833c1.833-1.5,9.834-7.5,13-7.5s10.167-8.333,13.5-9.833c2.667-2.667,3.167-5.166,3.333-7.5s1.333-4,3.456-6.833s4.377-7.834,7.877-9.5s5.5-10.5,7.667-12s6-18.334,6.667-20.334s1-3.665,2.667-9.195S417.333,513.334,416.667,510.334z"/>
        <path id="fijs14" fill="black" stroke="#FFFFFF" vector-effect="non-scaling-stroke" d="M170.167,426.667c2.333-2.333,3-7.548,4.333-5.19s2.667-0.476,2.667-2.643s5.333-8.999,9.167-10.333s-1.333-4.333,2.667-4.5s1.333-7.668,5-9.834s1.167-6.666,5-8.333s2.5-5.001,6-4.167s2.748-1.834,7.541-1.667s6.292,6.001,9.959,5.001s-6.911-8.25-5.667-9.834c3.667-4.667,6.5,3.334,8.667,1.667s-3.5-4.667-3.166-7.5c0.333-2.833-5.167-3.84-5.167-6.92s3.333,0.753,3.333-2.58s-1.833-6.5-2.167-8.833s2.167-0.667,1.667-4s3-2,2.667-5.333s-2.833-3.834-3.5-6.667s-2.833,0-4.5-4.167c4.167-2.333,5.667-4.5,7.667-5.333c2-0.833-0.834-3.833,4-3.333c4.832,0.5,8.332,1.889,10.332-0.056s9.29-6.611,8.896-4.111c-0.396,2.5-0.396,5,3.438,5s18.499,4.293,22.166,0.98c3.668-3.313,11-17.646,13-16.313s3.5-1.667,4.5,0.833s3.334,6.333,6.668,6.833c3.332,0.5,10,3.5,13.333,1.833s5.333-2.333,5.333-5.333s-5.334-4.5-3-6.5s7.834,0.167,9.167-2.833s-3.333-2.167-3.5-5.833s3.979-0.333,3.739-5.167s1.094-4.667-2.239-5.833s-3.834-4.833-4.667-6.833s-1.334-3,1-4.333s3-1.5,3-3.167s0.615-3,2.975-1.5s9.192,5.333,23.692,2c0.5,1.167,2,9.5,4,11.5s5.5,6,5.833,7.5s2.333,7.833,3.333,9.833s4.334,14.5,4.667,16s0.5,7.46-1,7.313s-4.833,0.687-5,1.187s-4.167,1.833-4,2.5s2.999,4.166,2.333,5.333s-1.666,3.167-1.666,4c-5,0.833-12.834,2.834-15.5,1.167s-3,2-4.167,3.833s-3.167,1.833-4.667,0.914s-5,0.919-8.666,2.752s-1.334,4.833-2.667,6.833s-2.333,2.667-13,3.167s-5.166,7.833-6.166,10.667s-8.5-3.333-9.5-0.833s-2.167,3-4.667,2s-5,0.167-6.833,2.833c-1.834,2.667,3.666,2.167,4.5,4.167c0.833,2,1.833,10.667,1,11.493c-0.834,0.826-4,2.007-6.834,0.34s-1.5,3.334-5.833,3.334s-5,8.833-7.667,9s-2.833,5.667-5.333,4.833s-2.5,2.667-4.833,4.334c-2.334,1.667-0.334,3.333,2.5,4.833c2.833,1.5,0,3.5,0,5.833s2.333,2.834,3.666,2.976s3-0.142,4.667,1.858s1,11.5,1,14.666s0.167,1.167,2.499,4.332c-3.167-0.833-3.666,1.333-7.332,2.167c-3.667,0.834-10.168,8.166-11.834,10.166s2.334,18.167,0,18.834s-3.5,6.166-4.833,10.5c-2.156-3.234-5.167,1.5-6.833-4c-0.704-2.322-3.167-3-7-2.5c-3.834,0.5-9.167-5.5-11.5-7s-4.5,1.167-4.293,4.667s0.459,6-5.041,5.741c-2.167-3.093-11.167-14.407-13.833-17.835s-1.333-8.905-5.333-9.739s-2-6.666-4.333-7.333s-1.5-4.667-1.333-7.167S173.5,428.334,170.167,426.667z M204.25,371.625c1.125-1.75-4.625-1.5-4.5-2.5s-0.875-2.375-2.5-1.75s-5.125-0.456-7.75,2.272s1.125,4.103,1.125,5.978s1.625,2.875,2.5,2s1.5-0.109,2.125,0.32s1.625,0.748,3.5-1.599s-2.89-5.303-2.125-5.597C198.212,370.141,203.125,373.375,204.25,371.625z"/>
        <path id="fijs15" fill="black" stroke="#FFFFFF" vector-effect="non-scaling-stroke" d="M300.834,455.833c-1.167-1.334-10.834-7.667-12.5-9c-1.667-1.333-6.834-0.833-10.168-0.667c-3.333,0.166-8.832-3-12-3.833c-3.167-0.833-3.666,1.333-7.332,2.167c-3.667,0.834-10.168,8.166-11.834,10.166s2.334,18.167,0,18.834s-3.5,6.166-4.833,10.5c1.333,2,2.833,7.667,2.667,10.667c-0.167,3-2.378,7.666,0.728,10.666s5.105,3.666,2.605,5.833s1.999,2.667-0.167,5.167s-9.334,1-7,3.5s7.167,10.167,10.167,9.667s4.667,3.143,6,6.904s0.333,7.429-1.167,8.429s-3.745,1.239-1.166,4.333c4.166,5,5.666,0.834,7,4.167c3.666-2.5,3.895,1.957,7,0c7.666-4.833,5.166,1.29,8.666-0.688s5.834-3.979,7.667-1.979s7.833,5.835,8.667,8.001c0.832,2.166,2.495,6.389,5,6.333c7.499-0.167,6.833,4.167,9.666,3.667s3.334-2.001,7.667-0.001s7.501,3.5,8.667,1.667S324.666,567.167,323,565s-3.999-4.334-5.666-4.167S316.5,559.834,314.5,559s0-1.691-2-3.096s0.001-4.738,1.834-4.738s0.333-6.167,2.833-6s4.999-7.666,9.333-7.166c-1-2.667-1.666-4.167-2.833-7s2.5-2.833,2.5-4.667s3.667,0.667,5,1.5s2.667-2.666,4.167-3.666S333.167,518,333,517.471s3.167-3.138,4-3.138s-6.333-3.833-7.166-4.333S325,499,323,497.167s4.167-8.667,1-10s-1.333-7.834-2.166-9.5s2.666-4,0-4.167s-1.5-8.167-3-8.167s-3.667-1.5-6.167-4.333c-0.166,1.667-2.167,3.5-2.5,5S302,457.167,300.834,455.833z"/>
        <path id="fijs16" fill="black" stroke="#FFFFFF" vector-effect="non-scaling-stroke" d="M207.333,661.333c2-0.833-3.5-2.167-3.5-5s3.667-8.999,5.333-9.333s2.333-1.833,1.833-4s1.167-6.334-1.167-7.167s-4.5-0.865-4.667-1.933s-3.667,0.266-4.833-2.567c-1.124-1.377-3.667,0.667-5.333-1s-4.333,2.833-6.167,0.333s-4.5-0.333-7.167,2.953s-2.167,1.714-5.833,0.281s0.5,2.933,0.5,5.933s-8.667,4.5-11,5s-2.833,2.5-2.5,6.5s-2.167,3.667-4.5,0.5s-3-1.666-7.333,0.667s-9.333-6.167-11.167-4s1.5,3.5,3.667,4.898s-1.167,3.102-4.167,4.935s1.167,4.667-0.5,5.834s0,2.833,4.167,5s3.833-0.667,5.333-1.001s4.333,2.5,7.167,4.834s4.333,1.666,8.667,3.621s10.167,1.045,11.5,3.379s3.667-0.334,4.833,1.5s1.5,0.166,3.5,0.666s3.333-2,3.5-4.5s4.167-1.666,6.833-1.045s6.833-2.455,8.667-1.455s2.5,0.5,4.333-2.166s-4.5-0.834,0-7.667C204.167,665.333,205.333,662.166,207.333,661.333z"/>
        <path id="fijs17" fill="black" stroke="#FFFFFF" vector-effect="non-scaling-stroke" d="M151,652.5c4.333-2.333,5-3.834,7.333-0.667s4.833,3.5,4.5-0.5s0.167-6,2.5-6.5s11-2,11-5s-4.167-7.365-0.5-5.933s3.166,3.005,5.833-0.281s5.334-5.453,7.167-2.953s4.5-2,6.167-0.333s4.21-0.377,5.333,1c-1.167-2.833,1.5-5.666,0-7.166s-0.334-4,1.333-4.167c-0.5-1.666,1.333-5-2.025-7s-1.142-5.667,0-6.022s0.525-2.145-2.475-2.645s-2-4-0.955-6.333s-2.879-4.667-5.045-9.667s2.667-2.833,4.333-4.5s0.167-9.5-2-12s-3.5-2.5-6.333-2.167s-4.333-1.166-5.5-4s-1.833-1-5.667-2.666s-1.667-5.667-2.333-8.167c-5.5,0,1.5-4.833-5.167-7.333s-5.167,6.167-8.5,4.333s-3.667,3-7.167,0.334s-2.833,0.333-4.5,3.737s-4.333,1.429-6.833,3.763s-6.333,1.5-8.833,1.5c1,2.833,0.935,5.809-1,7.5c-3.496,3.056-0.5,6.666-4,6.666s-3.833,2.334-0.85,3.834s-0.817,5.166,1.35,5.166s4.833,2.334,3.5,8.334s-2,2.666-4.85,4.833s4.016,6,0.683,7.667s-2.167,3.333-3.833,7.333s4.5,2.5,3.833,6s-7.5,3-8,4.5s2.833,9.333,5.333,8.917s3.333,0.916,5.667,0.083s3.333,4.833,1.833,7.167s4.833,6,0,6.333c3.5,2.333,5.667,1.833,7.5,3C141.667,646.333,146.667,654.833,151,652.5z"/>
        <path id="fijs18" fill="black" stroke="#FFFFFF" vector-effect="non-scaling-stroke" d="M251.75,694.084c-0.166-1.083-0.917-1.5-1-0.25s0.666,2.584,0,2.667s-0.916-0.833-0.916,0.5S248,697.762,249,698.298s1.917,0.703,2.334,1.453c0.416,0.75,2.666-0.083,1.833,1s-2.75,1.083-3.75,0s-1.75-3.417-2.25-2.167s-0.834,0.584-1.417-0.833s-0.583-3.167-1.666-2.5c-1.084,0.667,0.5,2.416,0,3.083s-1.418-1.833-1.834-0.833s1.167,1.5,0.917,2.25s-1.251,1.375-0.167,1.813s2.167,1.604,1.417,2.271s-2.75-0.834-2.833-2.25c-0.084-1.416,0.416-1.582-0.917-2.916s-2.5-1.333-3-2.5s-1-0.834-1.833-2.167c-0.834-1.333-2.084-0.25-1.167,0.5s1.833,2.667,1.75,3.25s1.833,1.75,1.917,3c0.083,1.25,1.833,1.249,1.75,2.083c-0.084,0.834,1.666,2.084,1.166,2.584s-2,0.167-2.166-0.5c-0.167-0.667-1.418-0.25-2.084-0.25s0-2.751-0.916-2.834c-0.917-0.083,0.582,3.483,0.166,3.825s-1.917,1.842-2.25,0.842s0.834-0.833,0.667-2.083s-1.037-1.167-0.728-2.167c0.311-1-0.522-2.333-1.272-2.333s0.167,3.083-0.333,3.083s-0.417,1.333,0,2.083c0.416,0.75,1.666,2.5,1.166,2.917s-1.416,1-1.916,0s0.583-2.25-0.5-2.25c-1.084,0-1.668-1.584-2.084-1.167s2.084,2.334,1.417,2.667s-1.178-0.667-1.464,0.083s-2.619,0.167-2.619-0.833s-2.667-2.083-2.167-3.25s1.666-0.833,1.333-1.75s-1.041-1.251-1.396-0.834s-0.271,1.251-0.938,1.334s-0.917,0.167-0.583,1c0.333,0.833,0.749,2.75,1.416,3.083s2.084,1.771,1.334,2.469s-2.628,0.864-2.897-0.636s-0.27-1.5-0.353-2.333c-0.084-0.833,0.25-3.333-0.417-3.333s-1.167,0-0.583,0.583c0.583,0.583,0.234,2.501-0.258,2.667c-0.493,0.166-1.826,0.499-1.409,1.416s-3.167,1.25-3.583,0.417s-1.5-0.917-1.75-0.167s-1.417,1.333-2.667,0.5s-2.417,1.053-1.917,1.401s-0.833-0.067-0.833,0.933s-1.667,1.917-2.333,1s-0.667-0.494-0.667,0.378s0.25,3.288-1.083,3.038s0.25-2.749-0.75-3.416s-1.667-1.666-2.25-0.25s-1.5,0.75-2.75,0s-3.417,0.584-2.333,1.25s0.333,2.167-0.75,2s-0.333,0.916-1.75,1.083s-0.833,0.667-1.917,0.5s-2.833-0.083-1.417,0.667s1.106,1.832-0.53,3.166s-2.22,2.251-2.303,2.834s-1.083,2.25-2,2.5s-1.75-0.25-1.75-0.5s2.25-1.5,1.75-2.917s-2.833,2.584-3.583,1.917s0.333-1.584,0-2.334s0.625-0.749-0.271-1.916s-1.979-1.584-2.063,0.166s-1.75,2.918-2.5,1.834s-1.75,0.084-1.417,0.5s-0.917,2.166-2.167,1.166s-1.167,0.751-2.333-0.166s-2.5-0.083-2.25,0.75s0.522,2.583-0.03,2.583s-0.97-1.334-1.886-0.667s1.417,1,0.5,1.667s-3.917,1.667-3.333,0s1.5-1.167,0.583-1.667s-0.75,1.667-2.583,0.917s-5.333-0.25-4.5,0.5s3.167,0.324,2.5,1.162s-2.833,0.088-3.167,0.338s-3.25-0.583-3.917,0.417s0.167,3-1.917,2.5s-0.5,2.334-1.917,1.417s1.5-1.75,0-3s-2.917,1.832-4.167,1.416s-1.167,2.167-0.917,2.417s-0.5,2.083-2.25,1.75s-4.333,0.75-6,0.75s-2.417-1.001-0.5-1.167s2.917-3.667,5.333-3s0.583-2,2-2s1.583-1.916,0.75-2.583s-2.417,1.75-3.083,0.5s0.5-3.001-0.333-3.167s-2.083,0.583-2.833-0.75s-0.833-2.083,0.167-2.083s2.917,0.584,1.75-0.583s-3.5-1.501-2.417-2.584s1.167-1.75-0.25-2.5s-2.75,0.084-3.333-1.333s1.333-3.084,0.333-3.417c2.5-2.751,4.667,1.082,7.333-2.251s2.333,1.499,5.333-0.667s4.667,1.574,6.5-0.546s-3-7.416,1.167-7.852s0-4.601,3.5-5.685s0-3.751-1.5-4.584s0.677-2.5,3.005-2.5s3.162-2.333,3.995-3.333s0.666-5.258,1-7.046c4.333,1.955,10.167,1.045,11.5,3.379s3.667-0.334,4.833,1.5s1.5,0.166,3.5,0.666s3.333-2,3.5-4.5s4.167-1.666,6.833-1.045s6.833-2.455,8.667-1.455s2.5,0.5,4.333-2.166s-4.5-0.834,0-7.667c3.167,0,4,1.167,5.207,3.667s2.793,0.666,4.959-0.834s1.167,2.167,3.5,6.232c2.334,4.065,6.666-1.065,8.5-0.502s3.334-2.896,4.166,0c0.833,2.896,4.668-2.063,7,0.502c2.333,2.565,4,0.768,3.834-2.232c4.334,2,2.666,5.167,6.166,5.167s0.5,3.999,3.5,3.833s2-3.499,5.334-2.166s1.491,4.108-1.334,3.833C251.334,682.166,254.998,688.735,251.75,694.084z M134.833,717.083c-1.167-0.5-2.252,1.847-1.333,2C136,719.499,136,717.583,134.833,717.083z M139.167,727.75c0.083-2.25-2.5-2-4.417-2.583s-2.889,0.35-1.594,2.583C134.895,730.75,139.083,730,139.167,727.75z"/>
        <path id="fijs19" fill="black" stroke="#FFFFFF" vector-effect="non-scaling-stroke" d="M97.693,653.398c0.295,3.426,3.474,0.602,6.807,1.769s5.833-2.834,7.167-2.5s8.167,1,6.667-1.5s2.833-3.834,7-1.5s4.333-1,3.333-4.167s0.167-2.333,3.667,0c4.833-0.333-1.5-3.999,0-6.333s0.5-8-1.833-7.167s-3.167-0.499-5.667-0.083S119,624.5,119.5,623s7.333-1,8-4.5s-5.5-2-3.833-6s0.5-5.666,3.833-7.333s-3.532-5.5-0.683-7.667s3.517,1.167,4.85-4.833s-1.333-8.334-3.5-8.334s1.634-3.666-1.35-5.166s-2.65-3.834,0.85-3.834s0.504-3.61,4-6.666c1.935-1.691,2-4.667,1-7.5c-2.5,0-2.167,0.166-4.667-2.667s-2.667,7.167-6,7s-2.667,6.833-6,6.5s-6.833,2.667-10.333,6.248s-4,3.085-5.333,1.504s-2.5-0.085-6.333-1.252s-5.5,2.167-8.083,1.001c-1.667,0.167-0.25-1.5-1.917-1.5s0.417,3.75-1.167,3.667s-1.5,2.916-0.917,5s-1.083,3.75,0.583,4.666s-0.667,1.917,0.917,3.568s2.5,0.015,2.333,1.432s1.833,1.5,0.667,4.333s3.083,0.167,3.333,3s-2.083-0.25-2.25,2.084s3.25,3.5,3.333,5.166s-1.167-1.416-1.583,1.667s2.917,4.083,3.167,5.75s3.417,2.25,2.25,3.833s-2.833-1.416-4-1.166s-1.833-2.667-2.833-1.667s0.167,1.417,1,2.833s3.167,1.417,2.417,2.667s-2.75-0.917-2.75,0.75s3.167,2.5,2.667,4s-3.75-0.75-3.833,0.667s3.417,1.166,2.5,2.416s0,3,0,3.834s0.75,0.916,0.5,2.083s-1.5,0.25-2.583,2.417s3.5,2.083,3.167,3.083C92.666,647.501,96.833,643.426,97.693,653.398z"/>
      </g>

      <g id="visnames" fill="#ff0000">
        <text id="fijsvn1" transform="matrix(1 0 0 1 3 745)" font-size="16">Ahvenanmaa</text>
        <text id="fijsvn2" transform="matrix(1 0 0 1 208 633)"><tspan x="0" y="0" font-size="16">Etelä-</tspan><tspan x="-4" y="19" font-size="16">Karjala</tspan></text>
        <text id="fijsvn3" transform="matrix(1 0 0 1 349 655)"><tspan x="0" y="0" font-size="16">Etelä-</tspan><tspan x="-19" y="19" font-size="16">Pohjanmaa</tspan></text>
        <text id="fijsvn4" transform="matrix(1 0 0 1 268 594)" font-size="15">Etelä-Savo</text>
        <text id="fijsvn5" transform="matrix(1 0 0 1 286 412)" font-size="19">Kainuu</text>
        <text id="fijsvn6" transform="matrix(1 0 0 1 273 707)"><tspan x="0" y="0" font-size="16">Kanta-</tspan><tspan x="2" y="19" font-size="16">Häme</tspan></text>
        <text id="fijsvn7" transform="matrix(1 0 0 1 199 545)"><tspan x="0" y="0" font-size="14">Keski-</tspan><tspan x="-15" y="16" font-size="14">Pohjanmaa</tspan></text>
        <text id="fijsvn8" transform="matrix(1 0 0 1 62 440)" font-size="16">Keski-Suomi</text>
        <text id="fijsvn9" transform="matrix(1 0 0 1 42 682)" font-size="16">Kymenlaakso</text>
        <text id="fijsvn10" transform="matrix(1 0 0 1 232 214)" font-size="20">Lappi</text>
        <text id="fijsvn11" transform="matrix(1 0 0 1 35 479)" font-size="16">Pirkanmaa</text>
        <text id="fijsvn12" transform="matrix(1 0 0 1 111 541)" font-size="14">Pohjanmaa</text>
        <text id="fijsvn13" transform="matrix(1 0 0 1 344 513)"><tspan x="0" y="0" font-size="16">Pohjois-</tspan><tspan x="4" y="19" font-size="16">Karjala</tspan></text>
        <text id="fijsvn14" transform="matrix(1 0 0 1 120 370)"><tspan x="0" y="0" font-size="16">Pohjois-</tspan><tspan x="-11" y="19" font-size="16">Pohjanmaa</tspan></text>
        <text id="fijsvn15" transform="matrix(1 0 0 1 257 500)"><tspan x="0" y="0" font-size="17">Pohjois-</tspan><tspan x="11" y="20" font-size="17">Savo</tspan></text>
        <text id="fijsvn16" transform="matrix(1 0 0 1 164 657)"><tspan x="0" y="0" font-size="13">Päijät-</tspan><tspan x="1" y="15" font-size="13">Häme</tspan></text>
        <text id="fijsvn17" transform="matrix(1 0 0 1 128 609)" font-size="15">Satakunta</text>
        <text id="fijsvn18" transform="matrix(1 0 0 1 166 699)" font-size="15">Uusimaa</text>
        <text id="fijsvn19" transform="matrix(1 0 0 1 17 614)"><tspan x="0" y="0" font-size="15">Varsinais-</tspan><tspan x="12" y="18" font-size="15">Suomi</tspan></text>
      </g>
      <g id="fijspins"></g>
    </svg>
  </div>
</div>
<div class="clear"></div>    </section>

<section id="profiles-section">
    <h1>Seksitreffit <?php echo $city_display_name; ?></h1>
    <?php if (!empty($city['seo_text'])): ?>
    <p class="addReadMore showlesscontent seo-intro"><?php echo htmlspecialchars($city['seo_text']); ?></p>
    <?php endif; ?>
    <div id="profiles-container">
    <?php if (count($profiles) > 0): ?>
    <?php foreach ($profiles as $profile): ?>
        <div class="profile-card">
            <a href="/profiili/<?php echo urlencode(strtolower($profile['pseudo'])); ?>">
                <img src="/<?php echo htmlspecialchars($profile['photo']); ?>" alt="<?php echo htmlspecialchars($profile['pseudo']); ?>">
            </a>
<div class="vote-container">
    <span class="vote-count" id="vote-count-<?php echo $profile['id']; ?>">
        <?php echo htmlspecialchars($profile['votes']); ?>
    </span>
    <button class="vote-button" data-profile-id="<?php echo $profile['id']; ?>" aria-label="Voter">
        <svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" fill="currentColor" viewBox="0 0 24 24">
            <path d="M12 21.35l-1.45-1.32C5.4 15.36 2 12.28 2 8.5 2 
            5.42 4.42 3 7.5 3c1.74 0 3.41 0.81 
            4.5 2.09C13.09 3.81 14.76 3 16.5 
            3 19.58 3 22 5.42 22 8.5c0 3.78-3.4 
            6.86-8.55 11.54L12 21.35z"/>
        </svg>
    </button>
</div>
            <div class="profile-info">
    <span><?php echo htmlspecialchars($profile['pseudo']); ?></span>
    <p>
        <svg class="icon" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24">
            <path d="M12 2C8.13 2 5 5.13 5 9c0 5.25 7 13 7 13s7-7.75 7-13c0-3.87-3.13-7-7-7zm0 9.5c-1.38 0-2.5-1.12-2.5-2.5S10.62 6.5 12 6.5s2.5 1.12 2.5 2.5S13.38 11.5 12 11.5z"/>
        </svg>
<a href="/kaupunki/<?php echo removeSpecialChars($profile['city_name']); ?>">
    <?php echo htmlspecialchars($profile['city_name']); ?>
</a>
    </p>
    <h2>        <svg class="icon" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24">
            <path d="M4 4h16v2H4V4zm0 4h16v12H4V8zm4 2v8h8v-8H8z"/>
        </svg>
        <?php echo htmlspecialchars(substr($profile['description'], 0, 50)); ?>...
    </h2>
    <p class="age">
        <svg class="icon" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24">
            <path d="M12 12c2.21 0 4-1.79 4-4s-1.79-4-4-4-4 1.79-4 4 1.79 4 4 4zm0 2c-2.67 0-8 1.34-8 4v2h16v-2c0-2.66-5.33-4-8-4z"/>
        </svg>
        Ikä: <?php echo htmlspecialchars($profile['age']); ?>
    </p>
</div>
                    </div>
                <?php endforeach; ?>
            <?php else: ?>
                <p>Yhtään profiilia ei löytynyt.</p>
            <?php endif; ?>
        </div>
        <div id="pagination">
    </div>
</section>
    <?php include 'includes/footer.php'; ?><script>
document.addEventListener('DOMContentLoaded', function() {
    const toggleBtn = document.getElementById('toggle-map-btn');
    const closeBtn = document.querySelector('#finland-map-container .close-map-btn');
    const mapContainer = document.getElementById('finland-map-container');
    function showMap() {
        mapContainer.classList.add('show');
        mapContainer.setAttribute('aria-hidden', 'false');
    }
    function hideMap() {
        mapContainer.classList.remove('show');
        mapContainer.setAttribute('aria-hidden', 'true');
    }
    toggleBtn.addEventListener('click', function() {
        if (mapContainer.classList.contains('show')) {
            hideMap();
        } else {
            showMap();
        }
    });
    closeBtn.addEventListener('click', function() {
        hideMap();
    });
    document.addEventListener('click', function(event) {
        if (!mapContainer.contains(event.target) && !toggleBtn.contains(event.target)) {
            hideMap();
        }
    });
});
</script>
<script src="/map/jquery.min.js"></script>
<script src="/map/map-config.js"></script>
<script src="/map/map-interact.js"></script>
<script src="/map.js"></script> 
<script src="/script.js"></script>
<script src="/js/filters.js"></script>
</body>
</html>
