export interface TimeReference {
  emoji: string;
  text: string;
}

export function getTimeReference(hours: number): TimeReference {
  if (hours < 1) {
    return { emoji: "⏱️", text: "A quick meditation" };
  }
  if (hours < 4) {
    return { emoji: "🎬", text: "A movie marathon" };
  }
  if (hours < 8) {
    return { emoji: "✈️", text: "A cross-country flight" };
  }
  if (hours < 12) {
    return { emoji: "🌙", text: "A full night's sleep" };
  }
  if (hours < 16) {
    return { emoji: "🏔️", text: "A day hike" };
  }
  if (hours < 24) {
    return { emoji: "🌍", text: "A day trip abroad" };
  }
  if (hours < 36) {
    return { emoji: "🚂", text: "A train across the country" };
  }
  if (hours < 48) {
    return { emoji: "⛵", text: "A weekend sailing trip" };
  }
  return { emoji: "🏕️", text: "A multi-day adventure" };
}

export function getEncouragingMessage(hours: number): string {
  if (hours < 4) {
    return "Great start! Your body is beginning to adjust.";
  }
  if (hours < 8) {
    return "You're doing well. Insulin is dropping.";
  }
  if (hours < 12) {
    return "Halfway through a standard fast. Fat burning is ramping up!";
  }
  if (hours < 16) {
    return "You've passed 12 hours. Autophagy is beginning.";
  }
  if (hours < 24) {
    return "Deep into your fast. Your body is thriving.";
  }
  if (hours < 36) {
    return "Incredible discipline! Growth hormone is surging.";
  }
  return "Extraordinary commitment. Your body is deeply healing.";
}
