<IfModule mod_rewrite.c>
RewriteEngine on
RewriteBase /offer/
RewriteRule ^(.*)/offer/([0-9]{4})/([0-9]{1,2})/([0-9]{1,2})/(.*)/$ /offer/detail.php?id=1 [QSA]
RewriteRule ^(.*)/offer/([0-9]{4})/([0-9]{1,2})/([0-9]{1,2})/$ /offer/list.php?year=$2&month=$3&day=$4 [QSA]
RewriteRule ^(.*)/offer/([0-9]{4})/([0-9]{1,2})/$ /offer/list.php?year=$2&month=$3 [QSA]
RewriteRule ^(.*)/offer/([0-9]{4})/$ /offer/list.php?year=$2 [QSA]
</IfModule>