var phrases_one = new Array(
  'tree-hugging lumberjack',
  'pachyderm',
  'lascivious wink',
  '-symmetrical',
  'creative studio',
  'beautiful woman',
  'gravitational fieldtrip',
  'three-legged dog',
  'flexed muscle',
  'puffy cloud',
  'secret handshake',
  'Ukrainian grandmaster',
  'sandwich',
  'bike with pegs',
  'post-it note',
  'delicious spread',
  'cup of orange juice',
  'shortstop',
  'monster truck',
  'quadruple axel',
  'PE teacher',
  'million times a million',
  'color only God can see',
  'lightsaber, for real',
  'fraid of nothing',
  'nightmare\'s nightmare',
  '-t least half of twice your needs',
  'planeteer'
);
var phrases_one_over = false;

var phrases_two = new Array(
  'fill in your blank',
  'make you look good',
  'drink your milkshake',
  'tie your tie',
  'make you sandwiches',
  'lick your stamps',
  'make decisions',
  'get a 10',
  'aspirate your gangleon',
  'tune your heartstrings',
  'sharpen your knives',
  'chew your food',
  'retrieve your lunch money',
  'check for monsters',
  'graduate your college',
  'find an esquilax',
  'filibuster bad bills',
  'randomate',
  'walk you to your car',
  'hold your hand',
  'sing you Puccini',
  'bake you lasagne',
  'water your plants',
  'wax your car',
  'be your neighbors',
  'draw you a bath'  
);
var phrases_two_over = false;

var phrases_three = new Array(
  'a pleonasm',
  'nepenthe',
  'a trilobyte',
  'condiments',
  'words in your mouths',
  'zero diseases',
  'new ideas',
  'the meaning of life',
  'more visibility',
  'what you want',
  'a deal on hot pants',
  'a group hug',
  'a goblet of macaroni',
  'a thingamabob',
  'a tickle attack',
  'sandwiches',
  'even more sandwiches',
  'the antidote',
  'an anecdote',
  'a digestive aid'  
);
var phrases_three_over = false;

var phrases_four = new Array(
  'without breaking a shvitz',
  'colloquially',
  'right now',
  'as fast as we can',
  'happily',
  'right',
  'w/o any typos',
  'in a cat carrier',
  'fashionably on time',
  'muscles flexed',
  'with both hands on the wheel',
  'with our bare hands',
  'without a gun',
  'without a kerfuffle',
  'yesterday',
  'ASAP, stat, EOD',
  'without a kerfuffle',
  'from the future',
  'mustachioed',
  'without a potty mouth',
  'above ground',
  'in 3D',
  'in at least 256 colors',
  'in 16.7 million colors',
  'carefully',
  'out of cardboard',
  'with sandwich in hand'
);
var phrases_four_over = false;

$(document).ready(function(){
  $('#phrase_one').hover(
    function(){
      phrases_one_over = true;
    },
    function(){
      phrases_one_over = false;
    }
  );
  $('#phrase_two').hover(
    function(){
      phrases_two_over = true;
    },
    function(){
      phrases_two_over = false;
    }
  );
  $('#phrase_three').hover(
    function(){
      phrases_three_over = true;
    },
    function(){
      phrases_three_over = false;
    }
  );
  $('#phrase_four').hover(
    function(){
      phrases_four_over = true;
    },
    function(){
      phrases_four_over = false;
    }
  );
  $('#phrase_randomize').hover(
    function(){
      phrases_one_over = true;
      phrases_two_over = true;
      phrases_three_over = true;
      phrases_four_over = true;
      $('span', this).text('Randomating.....');
    },
    function(){
      phrases_one_over = false;
      phrases_two_over = false;
      phrases_three_over = false;
      phrases_four_over = false;
      $('span', this).text('The following statement is necessarily true:');
    }
  );
  phrases_cycler();
});

function phrases_cycler(){
  if(phrases_one_over){
    phrases_one_num = Math.floor(Math.random()*phrases_one.length);
    $('#phrase_one').html(phrases_one[phrases_one_num]);
  }
  if(phrases_two_over){
    phrases_two_num = Math.floor(Math.random()*phrases_two.length);
    $('#phrase_two').html(phrases_two[phrases_two_num]);
  }
  if(phrases_three_over){
    phrases_three_num = Math.floor(Math.random()*phrases_three.length);
    $('#phrase_three').html(phrases_three[phrases_three_num]);
  }
  if(phrases_four_over){
    phrases_four_num = Math.floor(Math.random()*phrases_four.length);
    $('#phrase_four').html(phrases_four[phrases_four_num]);
  }
  setTimeout('phrases_cycler()', 64);
}