// English-only UI copy for the public portfolio site.

const I18N = {
  en: {
    nav: { portfolio: "Portfolio", about: "About", contact: "Contact" },
    hero: {
      catL: "Cat. No. SY-2026",
      vol: "Vol. I",
      center: "selected works, two thousand twenty-four to six",
      right: "Score / Sound",
      altLine: "Game Music Composer",
      statement: [
        "Orchestral-leaning ",
        "scores",
        ", ambient beds, and battle cues written for worlds that need a pulse, and silence that earns its keep.",
      ],
      cta: "Listen to the portfolio",
      ctaMetaSuffix: "tracks / ~17 min",
    },
    portfolio: {
      label: "B / Portfolio",
      title: "Portfolio",
      blurb: "A selection of original work, unreleased cues, and published game tracks. Click any track to play; drag the waveform to scrub.",
      tracks: "tracks",
      stems: "Stems on request",
    },
    track: {
      game: "Game",
      year: "Year",
      tags: "Tags",
    },
    games: {
      originalWork: "Original Work",
      unreleasedTitle: "Unreleased Title",
      publishedTitle: "Published Title",
    },
    about: {
      label: "A - About the composer",
      labelR: "",
      portraitTag: "",
      portraitAlt: "Portrait of Siyun Yoon",
      portraitName: "",
      portraitSub: "",
      lede: "I write orchestral-leaning music for games. Raised as a gamer and trained as a composer, I build audio worlds that support story, play, and emotion. From intimate indie projects to larger commercial releases, my work is shaped around the player's experience.",
      p1: "Great game audio takes more than good music. It takes clear communication, thoughtful iteration, and respect for the production timeline. Whatever the project, I work closely with you to make sure every cue lands exactly right.",
      p2a: "",
      p2b: "",
      p2c: "",
      facts: {
        based: "Based",
        basedV: "Seoul, KR / available remotely",
      },
    },
    footer: {
      copyright: "© 2026 Siyun Yoon. All rights reserved.",
    },
    tweaks: {
      title: "Tweaks",
      palette: "Palette",
      paper: "Paper",
      ink: "Ink",
      accent: "Accent",
      type: "Type",
      displayFont: "Display font",
      layout: "Layout",
      showHero: "Show hero",
      compact: "Compact cards",
      angle: "Cover stripe angle",
      quick: "Quick palettes",
      pDefault: "Cream & rust (default)",
      pBone: "Bone & olive",
      pSand: "Sand & ink",
      pNight: "Late-night warm",
    },
  },
};

const I18nContext = React.createContext({
  t: I18N.en,
  lang: "en",
  setLang: () => {},
});

function I18nProvider({ children }) {
  React.useEffect(() => {
    document.documentElement.lang = "en";
    try {
      localStorage.setItem("siyun.lang", "en");
    } catch (e) {}
  }, []);

  const value = { t: I18N.en, lang: "en", setLang: () => {} };
  return <I18nContext.Provider value={value}>{children}</I18nContext.Provider>;
}

function useI18n() {
  return React.useContext(I18nContext);
}

window.I18N = I18N;
window.I18nContext = I18nContext;
window.I18nProvider = I18nProvider;
window.useI18n = useI18n;
