// portal-data.jsx — categories, default events, districts, nav

const CATEGORIES = [
  { id: "sports",  ja: "スポーツ", en: "SPORTS",   color: "#d24a36", glyph: "球" },
  { id: "market",  ja: "マルシェ", en: "MARKET",   color: "#c69a44", glyph: "市" },
  { id: "culture", ja: "文化・芸能", en: "CULTURE", color: "#5d6b4d", glyph: "芸" },
  { id: "kids",    ja: "子育て",   en: "FAMILY",   color: "#6b8a8a", glyph: "子" },
  { id: "festival",ja: "祭り",     en: "FESTIVAL", color: "#a8563a", glyph: "祭" },
  { id: "nature",  ja: "自然・体験", en: "NATURE",  color: "#4a7a5a", glyph: "森" },
  { id: "notice",  ja: "お知らせ", en: "NOTICE",   color: "#6b6f5e", glyph: "報" }
];

const catOf = (id) => CATEGORIES.find(c => c.id === id) || CATEGORIES[6];

// Default events — seeded into localStorage on first load
const DEFAULT_EVENTS = [
  {
    id: "evt-redsparks",
    cat: "sports",
    title: "広島レッドスパークス ホーム戦",
    date: "2026.06.21",
    time: "13:00 KICK OFF",
    place: "安佐町総合グラウンド",
    desc: "地元クラブ・レッドスパークスの公式戦を安佐町に誘致。応援団・キッチンカー出店あり。地区対抗の応援グッズづくりも開催します。",
    pinned: true,
    createdAt: 1717000000000
  },
  {
    id: "evt-marche",
    cat: "kids",
    title: "親子でミニマルシェ",
    date: "2026.06.28",
    time: "10:00 — 14:00",
    place: "飯室駅前ひろば",
    desc: "親子で出店者になれる一日かぎりの小さな市。手づくりの品やおやつ、野菜の販売を、子どもたちが店主になって体験します。雨天時は公民館ホール。",
    pinned: false,
    createdAt: 1716900000000
  },
  {
    id: "evt-kamishibai",
    cat: "culture",
    title: "紙芝居講演会「里山のむかしばなし」",
    date: "2026.07.05",
    time: "14:00 — 15:30",
    place: "鈴張公民館",
    desc: "安佐町に伝わる民話を、ベテラン紙芝居師が語ります。講演後には手づくり紙芝居のワークショップも。どなたでも無料でご参加いただけます。",
    pinned: false,
    createdAt: 1716800000000
  },
  {
    id: "evt-hotaru",
    cat: "nature",
    title: "小河内 蛍の夕べ",
    date: "2026.06.14 — 06.22",
    time: "19:30 — 21:00",
    place: "小河内渓谷",
    desc: "源氏蛍と平家蛍が舞う、初夏の夜の小宇宙。期間中の週末は地元ガイドによる観察ツアーを実施します。懐中電灯は赤色セロハンを忘れずに。",
    pinned: false,
    createdAt: 1716700000000
  },
  {
    id: "evt-soba",
    cat: "festival",
    title: "鈴張 新そば祭り 予告",
    date: "2026.10.11 — 10.13",
    time: "9:00 — 16:00",
    place: "鈴張そば処",
    desc: "標高三百米の冷涼地で育つ在来種そば。石臼挽き・手打ち・湯がきたての香りを。出店募集も同時受付中です。",
    pinned: false,
    createdAt: 1716600000000
  },
  {
    id: "evt-iju",
    cat: "notice",
    title: "安佐町 暮らし・移住相談会",
    date: "2026.07.12",
    time: "13:00 — 17:00",
    place: "安佐町連絡所",
    desc: "空き家バンク、就農支援、子育て環境について、地域おこし協力隊と先輩移住者がご相談に応じます。オンライン相談も併設。",
    pinned: false,
    createdAt: 1716500000000
  }
];

const DISTRICTS = [
  { idx: "01", name: "飯室",       ro: "IMURO",       pop: "2,512", feat: "COMS安佐パーク・丸木位里ゆかりの地・佐々木邦彦画伯・二つの本郷" },
  { idx: "02", name: "鈴張",       ro: "SUZUHARI",    pop: "2,591", feat: "鈴張川・棚田・三か寺・多数の御堂や祠" },
  { idx: "03", name: "久地",       ro: "KUCHI",       pop: "2,446", feat: "千年杉・宇賀峡・岳城跡・花みどり公園" },
  { idx: "04", name: "久地南",     ro: "KUCHIMINAMI", pop: "2,018", feat: "住宅団地・久地PA・どんどん（落差約2ｍの滝）" },
  { idx: "05", name: "小河内",     ro: "OGAUCHI",     pop: "318",   feat: "養山八幡神社の吹き囃子行事・小河内弥太郎・野外活動センター" },
  { idx: "06", name: "毛木",       ro: "KEGI",        pop: "199",   feat: "毛木川・阿土毛木村・JR西日本総合グラウンド" },
  { idx: "07", name: "後山",       ro: "USHIROYAMA",  pop: "354",   feat: "すり鉢状の地形・巨大エドヒガン・安佐動物公園" },
  { idx: "08", name: "宮野",       ro: "MIYANO",      pop: "39",    feat: "宮野八幡神社・大エノキ・市の天然記念物・宮野灌漑用水路・林四郎氏" },
  { idx: "09", name: "筒瀬",       ro: "TSUTSUSE",    pop: "179",   feat: "筒瀬八幡神社・市の天然記念物・筒瀬籠・玖谷埋立地" },
  { idx: "10", name: "あさひが丘", ro: "ASAHIGAOKA",  pop: "5,989", feat: "あさひが丘団地・農住都市構想・花木を生かした街" }
];

const NAV = [
  { label: "お知らせ", href: "#events" },
  { label: "10地区", href: "#districts" },
  { label: "動物公園", href: "#zoo" },
  { label: "魅力マップ", href: "https://map.asa-cho.com", external: true },
  { label: "暮らし", href: "#footer" }
];

const SNS_ACCOUNTS = [
  { id: "x", handle: "@asacho_machiko", name: "X (旧Twitter)", url: "https://x.com/asacho_machiko" },
  { id: "instagram", handle: "@asa_cho.hiroshima", name: "Instagram", url: "https://www.instagram.com/asa_cho.hiroshima/" },
  { id: "facebook", handle: "asachofm", name: "Facebook", url: "https://www.facebook.com/asachofm" },
  { id: "youtube", handle: "Asa-cho Channel", name: "YouTube" }
];

Object.assign(window, { CATEGORIES, catOf, DEFAULT_EVENTS, DISTRICTS, NAV, SNS_ACCOUNTS });
