Sabatino81 commited on
Commit
f60e4fa
Β·
verified Β·
1 Parent(s): 6838a74

Upload app.py with huggingface_hub

Browse files
Files changed (1) hide show
  1. app.py +25 -25
app.py CHANGED
@@ -1876,8 +1876,8 @@ def render_card_html(card_id: str, card_info: dict, primary: str, secondary: str
1876
  """
1877
  card_name = card_info['name']
1878
 
1879
- # Common container style
1880
- base_style = "width: 180px; min-height: 240px; border-radius: 12px; position: relative; overflow: hidden; box-shadow: 0 2px 8px rgba(0,0,0,0.1); background: white; display: flex; flex-direction: column;"
1881
 
1882
  # PRODUCT & SHOPPING (6)
1883
  if card_id == "product_vertical":
@@ -1890,9 +1890,9 @@ def render_card_html(card_id: str, card_info: dict, primary: str, secondary: str
1890
  </div>
1891
  """
1892
  elif card_id == "product_horizontal":
1893
- base_style = "width: 280px; height: 100px; border-radius: 12px; position: relative; overflow: hidden; box-shadow: 0 2px 8px rgba(0,0,0,0.1); background: white; display: flex;"
1894
  content = f"""
1895
- <div style="width: 100px; background: #f5f5f5; display: flex; align-items: center; justify-content: center; font-size: 36px;">πŸ“±</div>
1896
  <div style="padding: 12px; flex: 1; display: flex; flex-direction: column; justify-content: space-between;">
1897
  <div>
1898
  <div style="font-weight: 700; font-size: 13px; color: #333;">Product Name</div>
@@ -1928,7 +1928,7 @@ def render_card_html(card_id: str, card_info: dict, primary: str, secondary: str
1928
  </div>
1929
  """
1930
  elif card_id == "product_grid_compact":
1931
- base_style = "width: 140px; min-height: 180px; border-radius: 12px; position: relative; overflow: hidden; box-shadow: 0 2px 8px rgba(0,0,0,0.1); background: white; display: flex; flex-direction: column;"
1932
  content = f"""
1933
  <div style="background: #f5f5f5; height: 120px; display: flex; align-items: center; justify-content: center; font-size: 40px;">πŸ“±</div>
1934
  <div style="padding: 8px;">
@@ -1937,7 +1937,7 @@ def render_card_html(card_id: str, card_info: dict, primary: str, secondary: str
1937
  </div>
1938
  """
1939
  elif card_id == "product_featured":
1940
- base_style = "width: 280px; height: 200px; border-radius: 12px; position: relative; overflow: hidden; box-shadow: 0 2px 8px rgba(0,0,0,0.1); background: linear-gradient(135deg, {primary}, {secondary});"
1941
  content = f"""
1942
  <div style="position: absolute; inset: 0; display: flex; flex-direction: column; justify-content: flex-end; padding: 16px; background: linear-gradient(to top, rgba(0,0,0,0.6), transparent);">
1943
  <div style="color: white; font-size: 11px; opacity: 0.9; margin-bottom: 4px;">FEATURED</div>
@@ -1984,7 +1984,7 @@ def render_card_html(card_id: str, card_info: dict, primary: str, secondary: str
1984
  </div>
1985
  """
1986
  elif card_id == "social_post_card":
1987
- base_style = "width: 280px; min-height: 280px; border-radius: 12px; overflow: hidden; box-shadow: 0 2px 8px rgba(0,0,0,0.1); background: white;"
1988
  content = f"""
1989
  <div style="padding: 12px; display: flex; align-items: center; gap: 10px;">
1990
  <div style="width: 40px; height: 40px; border-radius: 50%; background: {primary}; display: flex; align-items: center; justify-content: center; color: white; font-size: 20px;">πŸ‘€</div>
@@ -2002,7 +2002,7 @@ def render_card_html(card_id: str, card_info: dict, primary: str, secondary: str
2002
  </div>
2003
  """
2004
  elif card_id == "social_story_card":
2005
- base_style = "width: 100px; height: 140px; border-radius: 12px; overflow: hidden; box-shadow: 0 2px 8px rgba(0,0,0,0.1); position: relative;"
2006
  content = f"""
2007
  <div style="position: absolute; inset: 2px; border-radius: 10px; background: linear-gradient(135deg, {primary}, {secondary}); display: flex; align-items: center; justify-content: center; color: white; font-size: 40px;">πŸ‘€</div>
2008
  <div style="position: absolute; bottom: 8px; left: 0; right: 0; text-align: center; color: white; font-size: 10px; font-weight: 600; text-shadow: 0 1px 2px rgba(0,0,0,0.5);">Sarah</div>
@@ -2036,7 +2036,7 @@ def render_card_html(card_id: str, card_info: dict, primary: str, secondary: str
2036
 
2037
  # CONTENT & MEDIA (5)
2038
  elif card_id == "article_card":
2039
- base_style = "width: 280px; min-height: 260px; border-radius: 12px; overflow: hidden; box-shadow: 0 2px 8px rgba(0,0,0,0.1); background: white;"
2040
  content = f"""
2041
  <div style="background: #f0f0f0; height: 140px; display: flex; align-items: center; justify-content: center; font-size: 48px;">πŸ“°</div>
2042
  <div style="padding: 14px;">
@@ -2047,7 +2047,7 @@ def render_card_html(card_id: str, card_info: dict, primary: str, secondary: str
2047
  </div>
2048
  """
2049
  elif card_id == "video_card":
2050
- base_style = "width: 280px; height: 200px; border-radius: 12px; overflow: hidden; box-shadow: 0 2px 8px rgba(0,0,0,0.1); position: relative;"
2051
  content = f"""
2052
  <div style="position: absolute; inset: 0; background: linear-gradient(135deg, #667eea, #764ba2); display: flex; align-items: center; justify-content: center; color: white; font-size: 64px;">▢️</div>
2053
  <div style="position: absolute; top: 8px; right: 8px; background: rgba(0,0,0,0.7); color: white; padding: 4px 8px; border-radius: 6px; font-size: 10px; font-weight: 600;">12:45</div>
@@ -2057,7 +2057,7 @@ def render_card_html(card_id: str, card_info: dict, primary: str, secondary: str
2057
  </div>
2058
  """
2059
  elif card_id == "podcast_card":
2060
- base_style = "width: 280px; height: 120px; border-radius: 12px; overflow: hidden; box-shadow: 0 2px 8px rgba(0,0,0,0.1); background: white; display: flex;"
2061
  content = f"""
2062
  <div style="width: 120px; background: linear-gradient(135deg, {primary}, {secondary}); display: flex; align-items: center; justify-content: center; font-size: 48px; color: white;">πŸŽ™οΈ</div>
2063
  <div style="flex: 1; padding: 12px; display: flex; flex-direction: column; justify-content: space-between;">
@@ -2072,7 +2072,7 @@ def render_card_html(card_id: str, card_info: dict, primary: str, secondary: str
2072
  </div>
2073
  """
2074
  elif card_id == "news_headline":
2075
- base_style = "width: 280px; height: 80px; border-radius: 12px; overflow: hidden; box-shadow: 0 2px 8px rgba(0,0,0,0.1); background: white; display: flex; gap: 12px; padding: 10px;"
2076
  content = f"""
2077
  <div style="width: 60px; height: 60px; border-radius: 8px; background: #f0f0f0; flex-shrink: 0; display: flex; align-items: center; justify-content: center; font-size: 24px;">πŸ“°</div>
2078
  <div style="flex: 1; display: flex; flex-direction: column; justify-content: space-between;">
@@ -2081,7 +2081,7 @@ def render_card_html(card_id: str, card_info: dict, primary: str, secondary: str
2081
  </div>
2082
  """
2083
  elif card_id == "blog_featured":
2084
- base_style = "width: 280px; height: 240px; border-radius: 12px; overflow: hidden; box-shadow: 0 2px 8px rgba(0,0,0,0.1); position: relative;"
2085
  content = f"""
2086
  <div style="position: absolute; inset: 0; background: linear-gradient(135deg, {primary}, {secondary});"></div>
2087
  <div style="position: absolute; top: 12px; left: 12px; background: white; color: {primary}; padding: 4px 10px; border-radius: 16px; font-size: 9px; font-weight: 700;">FEATURED</div>
@@ -2094,7 +2094,7 @@ def render_card_html(card_id: str, card_info: dict, primary: str, secondary: str
2094
 
2095
  # STATS & ANALYTICS (4)
2096
  elif card_id == "stats_metric":
2097
- base_style = "width: 160px; height: 120px; border-radius: 12px; overflow: hidden; box-shadow: 0 2px 8px rgba(0,0,0,0.1); background: white; padding: 16px; display: flex; flex-direction: column; justify-content: space-between;"
2098
  content = f"""
2099
  <div style="width: 40px; height: 40px; border-radius: 10px; background: {primary}20; color: {primary}; display: flex; align-items: center; justify-content: center; font-size: 20px;">πŸ“Š</div>
2100
  <div>
@@ -2104,7 +2104,7 @@ def render_card_html(card_id: str, card_info: dict, primary: str, secondary: str
2104
  </div>
2105
  """
2106
  elif card_id == "stats_comparison":
2107
- base_style = "width: 240px; height: 100px; border-radius: 12px; overflow: hidden; box-shadow: 0 2px 8px rgba(0,0,0,0.1); background: white; padding: 16px; display: flex; gap: 16px;"
2108
  content = f"""
2109
  <div style="flex: 1; text-align: center;">
2110
  <div style="font-size: 20px; font-weight: 700; color: #333;">1,234</div>
@@ -2119,7 +2119,7 @@ def render_card_html(card_id: str, card_info: dict, primary: str, secondary: str
2119
  </div>
2120
  """
2121
  elif card_id == "stats_progress":
2122
- base_style = "width: 200px; height: 100px; border-radius: 12px; overflow: hidden; box-shadow: 0 2px 8px rgba(0,0,0,0.1); background: white; padding: 16px; display: flex; flex-direction: column; justify-content: space-between;"
2123
  content = f"""
2124
  <div style="display: flex; justify-content: space-between; align-items: center;">
2125
  <div style="font-weight: 600; font-size: 12px; color: #333;">Goal Progress</div>
@@ -2133,7 +2133,7 @@ def render_card_html(card_id: str, card_info: dict, primary: str, secondary: str
2133
  </div>
2134
  """
2135
  elif card_id == "stats_chart":
2136
- base_style = "width: 200px; height: 140px; border-radius: 12px; overflow: hidden; box-shadow: 0 2px 8px rgba(0,0,0,0.1); background: white; padding: 16px;"
2137
  content = f"""
2138
  <div style="font-weight: 700; font-size: 13px; color: #333; margin-bottom: 4px;">Weekly Stats</div>
2139
  <div style="font-size: 10px; color: #666; margin-bottom: 12px;">Last 7 days</div>
@@ -2150,7 +2150,7 @@ def render_card_html(card_id: str, card_info: dict, primary: str, secondary: str
2150
 
2151
  # MESSAGING & NOTIFICATIONS (4)
2152
  elif card_id == "message_preview":
2153
- base_style = "width: 280px; height: 80px; border-radius: 12px; overflow: hidden; box-shadow: 0 2px 8px rgba(0,0,0,0.1); background: white; display: flex; align-items: center; gap: 12px; padding: 12px;"
2154
  content = f"""
2155
  <div style="width: 48px; height: 48px; border-radius: 50%; background: {primary}; flex-shrink: 0; display: flex; align-items: center; justify-content: center; color: white; font-size: 24px;">πŸ‘€</div>
2156
  <div style="flex: 1; min-width: 0;">
@@ -2177,7 +2177,7 @@ def render_card_html(card_id: str, card_info: dict, primary: str, secondary: str
2177
  </div>
2178
  """
2179
  elif card_id == "alert_card":
2180
- base_style = "width: 280px; min-height: 80px; border-radius: 12px; overflow: hidden; box-shadow: 0 2px 8px rgba(0,0,0,0.1); background: #FFF3CD; border: 1px solid #FFE69C;"
2181
  content = f"""
2182
  <div style="padding: 14px; display: flex; gap: 12px; align-items: start;">
2183
  <div style="font-size: 20px;">⚠️</div>
@@ -2189,7 +2189,7 @@ def render_card_html(card_id: str, card_info: dict, primary: str, secondary: str
2189
  </div>
2190
  """
2191
  elif card_id == "chat_bubble":
2192
- base_style = "width: 220px; min-height: 60px; border-radius: 16px 16px 16px 4px; box-shadow: 0 2px 8px rgba(0,0,0,0.1); background: {primary}; padding: 12px; position: relative;"
2193
  content = f"""
2194
  <div style="color: white; font-size: 12px; line-height: 1.4; margin-bottom: 4px;">Hey! How are you doing? I wanted to check in about the project.</div>
2195
  <div style="text-align: right; font-size: 9px; color: rgba(255,255,255,0.8);">2:45 PM</div>
@@ -2197,7 +2197,7 @@ def render_card_html(card_id: str, card_info: dict, primary: str, secondary: str
2197
 
2198
  # SPECIAL CARDS (6)
2199
  elif card_id == "pricing_plan":
2200
- base_style = "width: 200px; min-height: 280px; border-radius: 12px; overflow: hidden; box-shadow: 0 2px 8px rgba(0,0,0,0.1); background: white; border: 2px solid #eee;"
2201
  content = f"""
2202
  <div style="padding: 20px; text-align: center; background: {primary}10;">
2203
  <div style="font-weight: 700; font-size: 14px; color: #333; margin-bottom: 8px;">Pro Plan</div>
@@ -2226,7 +2226,7 @@ def render_card_html(card_id: str, card_info: dict, primary: str, secondary: str
2226
  </div>
2227
  """
2228
  elif card_id == "event_card":
2229
- base_style = "width: 280px; height: 120px; border-radius: 12px; overflow: hidden; box-shadow: 0 2px 8px rgba(0,0,0,0.1); background: white; display: flex;"
2230
  content = f"""
2231
  <div style="width: 80px; background: {primary}; color: white; display: flex; flex-direction: column; align-items: center; justify-content: center;">
2232
  <div style="font-size: 28px; font-weight: 700;">24</div>
@@ -2241,7 +2241,7 @@ def render_card_html(card_id: str, card_info: dict, primary: str, secondary: str
2241
  </div>
2242
  """
2243
  elif card_id == "offer_coupon":
2244
- base_style = "width: 260px; height: 140px; border-radius: 12px; overflow: hidden; box-shadow: 0 2px 8px rgba(0,0,0,0.1); background: white; border: 2px dashed {primary}; position: relative;"
2245
  content = f"""
2246
  <div style="padding: 20px; text-align: center;">
2247
  <div style="font-size: 10px; color: {primary}; font-weight: 600; margin-bottom: 8px;">SPECIAL OFFER</div>
@@ -2255,7 +2255,7 @@ def render_card_html(card_id: str, card_info: dict, primary: str, secondary: str
2255
  </div>
2256
  """
2257
  elif card_id == "weather_card":
2258
- base_style = "width: 200px; height: 200px; border-radius: 12px; overflow: hidden; box-shadow: 0 2px 8px rgba(0,0,0,0.1); background: linear-gradient(135deg, {primary}, {secondary}); color: white; padding: 20px;"
2259
  content = f"""
2260
  <div style="text-align: center;">
2261
  <div style="font-size: 12px; opacity: 0.9; margin-bottom: 8px;">San Francisco</div>
@@ -2269,7 +2269,7 @@ def render_card_html(card_id: str, card_info: dict, primary: str, secondary: str
2269
  </div>
2270
  """
2271
  elif card_id == "ticket_card":
2272
- base_style = "width: 280px; height: 160px; border-radius: 12px; overflow: hidden; box-shadow: 0 2px 8px rgba(0,0,0,0.1); background: white; position: relative;"
2273
  content = f"""
2274
  <div style="padding: 20px; padding-bottom: 16px;">
2275
  <div style="font-weight: 700; font-size: 14px; color: #333; margin-bottom: 8px;">Concert Night 2024</div>
 
1876
  """
1877
  card_name = card_info['name']
1878
 
1879
+ # Common container style - responsive with max-width
1880
+ base_style = "width: 100%; max-width: 180px; min-height: 240px; border-radius: 12px; position: relative; overflow: hidden; box-shadow: 0 2px 8px rgba(0,0,0,0.1); background: white; display: flex; flex-direction: column;"
1881
 
1882
  # PRODUCT & SHOPPING (6)
1883
  if card_id == "product_vertical":
 
1890
  </div>
1891
  """
1892
  elif card_id == "product_horizontal":
1893
+ base_style = "width: 100%; max-width: 280px; height: 100px; border-radius: 12px; position: relative; overflow: hidden; box-shadow: 0 2px 8px rgba(0,0,0,0.1); background: white; display: flex;"
1894
  content = f"""
1895
+ <div style="width: 100px; min-width: 100px; background: #f5f5f5; display: flex; align-items: center; justify-content: center; font-size: 36px;">πŸ“±</div>
1896
  <div style="padding: 12px; flex: 1; display: flex; flex-direction: column; justify-content: space-between;">
1897
  <div>
1898
  <div style="font-weight: 700; font-size: 13px; color: #333;">Product Name</div>
 
1928
  </div>
1929
  """
1930
  elif card_id == "product_grid_compact":
1931
+ base_style = "width: 100%; max-width: 140px; min-height: 180px; border-radius: 12px; position: relative; overflow: hidden; box-shadow: 0 2px 8px rgba(0,0,0,0.1); background: white; display: flex; flex-direction: column;"
1932
  content = f"""
1933
  <div style="background: #f5f5f5; height: 120px; display: flex; align-items: center; justify-content: center; font-size: 40px;">πŸ“±</div>
1934
  <div style="padding: 8px;">
 
1937
  </div>
1938
  """
1939
  elif card_id == "product_featured":
1940
+ base_style = "width: 100%; max-width: 280px; height: 200px; border-radius: 12px; position: relative; overflow: hidden; box-shadow: 0 2px 8px rgba(0,0,0,0.1); background: linear-gradient(135deg, {primary}, {secondary});"
1941
  content = f"""
1942
  <div style="position: absolute; inset: 0; display: flex; flex-direction: column; justify-content: flex-end; padding: 16px; background: linear-gradient(to top, rgba(0,0,0,0.6), transparent);">
1943
  <div style="color: white; font-size: 11px; opacity: 0.9; margin-bottom: 4px;">FEATURED</div>
 
1984
  </div>
1985
  """
1986
  elif card_id == "social_post_card":
1987
+ base_style = "width: 100%; max-width: 280px; min-height: 280px; border-radius: 12px; overflow: hidden; box-shadow: 0 2px 8px rgba(0,0,0,0.1); background: white;"
1988
  content = f"""
1989
  <div style="padding: 12px; display: flex; align-items: center; gap: 10px;">
1990
  <div style="width: 40px; height: 40px; border-radius: 50%; background: {primary}; display: flex; align-items: center; justify-content: center; color: white; font-size: 20px;">πŸ‘€</div>
 
2002
  </div>
2003
  """
2004
  elif card_id == "social_story_card":
2005
+ base_style = "width: 100%; max-width: 100px; height: 140px; border-radius: 12px; overflow: hidden; box-shadow: 0 2px 8px rgba(0,0,0,0.1); position: relative;"
2006
  content = f"""
2007
  <div style="position: absolute; inset: 2px; border-radius: 10px; background: linear-gradient(135deg, {primary}, {secondary}); display: flex; align-items: center; justify-content: center; color: white; font-size: 40px;">πŸ‘€</div>
2008
  <div style="position: absolute; bottom: 8px; left: 0; right: 0; text-align: center; color: white; font-size: 10px; font-weight: 600; text-shadow: 0 1px 2px rgba(0,0,0,0.5);">Sarah</div>
 
2036
 
2037
  # CONTENT & MEDIA (5)
2038
  elif card_id == "article_card":
2039
+ base_style = "width: 100%; max-width: 280px; min-height: 260px; border-radius: 12px; overflow: hidden; box-shadow: 0 2px 8px rgba(0,0,0,0.1); background: white;"
2040
  content = f"""
2041
  <div style="background: #f0f0f0; height: 140px; display: flex; align-items: center; justify-content: center; font-size: 48px;">πŸ“°</div>
2042
  <div style="padding: 14px;">
 
2047
  </div>
2048
  """
2049
  elif card_id == "video_card":
2050
+ base_style = "width: 100%; max-width: 280px; height: 200px; border-radius: 12px; overflow: hidden; box-shadow: 0 2px 8px rgba(0,0,0,0.1); position: relative;"
2051
  content = f"""
2052
  <div style="position: absolute; inset: 0; background: linear-gradient(135deg, #667eea, #764ba2); display: flex; align-items: center; justify-content: center; color: white; font-size: 64px;">▢️</div>
2053
  <div style="position: absolute; top: 8px; right: 8px; background: rgba(0,0,0,0.7); color: white; padding: 4px 8px; border-radius: 6px; font-size: 10px; font-weight: 600;">12:45</div>
 
2057
  </div>
2058
  """
2059
  elif card_id == "podcast_card":
2060
+ base_style = "width: 100%; max-width: 280px; height: 120px; border-radius: 12px; overflow: hidden; box-shadow: 0 2px 8px rgba(0,0,0,0.1); background: white; display: flex;"
2061
  content = f"""
2062
  <div style="width: 120px; background: linear-gradient(135deg, {primary}, {secondary}); display: flex; align-items: center; justify-content: center; font-size: 48px; color: white;">πŸŽ™οΈ</div>
2063
  <div style="flex: 1; padding: 12px; display: flex; flex-direction: column; justify-content: space-between;">
 
2072
  </div>
2073
  """
2074
  elif card_id == "news_headline":
2075
+ base_style = "width: 100%; max-width: 280px; height: 80px; border-radius: 12px; overflow: hidden; box-shadow: 0 2px 8px rgba(0,0,0,0.1); background: white; display: flex; gap: 12px; padding: 10px;"
2076
  content = f"""
2077
  <div style="width: 60px; height: 60px; border-radius: 8px; background: #f0f0f0; flex-shrink: 0; display: flex; align-items: center; justify-content: center; font-size: 24px;">πŸ“°</div>
2078
  <div style="flex: 1; display: flex; flex-direction: column; justify-content: space-between;">
 
2081
  </div>
2082
  """
2083
  elif card_id == "blog_featured":
2084
+ base_style = "width: 100%; max-width: 280px; height: 240px; border-radius: 12px; overflow: hidden; box-shadow: 0 2px 8px rgba(0,0,0,0.1); position: relative;"
2085
  content = f"""
2086
  <div style="position: absolute; inset: 0; background: linear-gradient(135deg, {primary}, {secondary});"></div>
2087
  <div style="position: absolute; top: 12px; left: 12px; background: white; color: {primary}; padding: 4px 10px; border-radius: 16px; font-size: 9px; font-weight: 700;">FEATURED</div>
 
2094
 
2095
  # STATS & ANALYTICS (4)
2096
  elif card_id == "stats_metric":
2097
+ base_style = "width: 100%; max-width: 160px; height: 120px; border-radius: 12px; overflow: hidden; box-shadow: 0 2px 8px rgba(0,0,0,0.1); background: white; padding: 16px; display: flex; flex-direction: column; justify-content: space-between;"
2098
  content = f"""
2099
  <div style="width: 40px; height: 40px; border-radius: 10px; background: {primary}20; color: {primary}; display: flex; align-items: center; justify-content: center; font-size: 20px;">πŸ“Š</div>
2100
  <div>
 
2104
  </div>
2105
  """
2106
  elif card_id == "stats_comparison":
2107
+ base_style = "width: 100%; max-width: 240px; height: 100px; border-radius: 12px; overflow: hidden; box-shadow: 0 2px 8px rgba(0,0,0,0.1); background: white; padding: 16px; display: flex; gap: 16px;"
2108
  content = f"""
2109
  <div style="flex: 1; text-align: center;">
2110
  <div style="font-size: 20px; font-weight: 700; color: #333;">1,234</div>
 
2119
  </div>
2120
  """
2121
  elif card_id == "stats_progress":
2122
+ base_style = "width: 100%; max-width: 200px; height: 100px; border-radius: 12px; overflow: hidden; box-shadow: 0 2px 8px rgba(0,0,0,0.1); background: white; padding: 16px; display: flex; flex-direction: column; justify-content: space-between;"
2123
  content = f"""
2124
  <div style="display: flex; justify-content: space-between; align-items: center;">
2125
  <div style="font-weight: 600; font-size: 12px; color: #333;">Goal Progress</div>
 
2133
  </div>
2134
  """
2135
  elif card_id == "stats_chart":
2136
+ base_style = "width: 100%; max-width: 200px; height: 140px; border-radius: 12px; overflow: hidden; box-shadow: 0 2px 8px rgba(0,0,0,0.1); background: white; padding: 16px;"
2137
  content = f"""
2138
  <div style="font-weight: 700; font-size: 13px; color: #333; margin-bottom: 4px;">Weekly Stats</div>
2139
  <div style="font-size: 10px; color: #666; margin-bottom: 12px;">Last 7 days</div>
 
2150
 
2151
  # MESSAGING & NOTIFICATIONS (4)
2152
  elif card_id == "message_preview":
2153
+ base_style = "width: 100%; max-width: 280px; height: 80px; border-radius: 12px; overflow: hidden; box-shadow: 0 2px 8px rgba(0,0,0,0.1); background: white; display: flex; align-items: center; gap: 12px; padding: 12px;"
2154
  content = f"""
2155
  <div style="width: 48px; height: 48px; border-radius: 50%; background: {primary}; flex-shrink: 0; display: flex; align-items: center; justify-content: center; color: white; font-size: 24px;">πŸ‘€</div>
2156
  <div style="flex: 1; min-width: 0;">
 
2177
  </div>
2178
  """
2179
  elif card_id == "alert_card":
2180
+ base_style = "width: 100%; max-width: 280px; min-height: 80px; border-radius: 12px; overflow: hidden; box-shadow: 0 2px 8px rgba(0,0,0,0.1); background: #FFF3CD; border: 1px solid #FFE69C;"
2181
  content = f"""
2182
  <div style="padding: 14px; display: flex; gap: 12px; align-items: start;">
2183
  <div style="font-size: 20px;">⚠️</div>
 
2189
  </div>
2190
  """
2191
  elif card_id == "chat_bubble":
2192
+ base_style = "width: 100%; max-width: 220px; min-height: 60px; border-radius: 16px 16px 16px 4px; box-shadow: 0 2px 8px rgba(0,0,0,0.1); background: {primary}; padding: 12px; position: relative;"
2193
  content = f"""
2194
  <div style="color: white; font-size: 12px; line-height: 1.4; margin-bottom: 4px;">Hey! How are you doing? I wanted to check in about the project.</div>
2195
  <div style="text-align: right; font-size: 9px; color: rgba(255,255,255,0.8);">2:45 PM</div>
 
2197
 
2198
  # SPECIAL CARDS (6)
2199
  elif card_id == "pricing_plan":
2200
+ base_style = "width: 100%; max-width: 200px; min-height: 280px; border-radius: 12px; overflow: hidden; box-shadow: 0 2px 8px rgba(0,0,0,0.1); background: white; border: 2px solid #eee;"
2201
  content = f"""
2202
  <div style="padding: 20px; text-align: center; background: {primary}10;">
2203
  <div style="font-weight: 700; font-size: 14px; color: #333; margin-bottom: 8px;">Pro Plan</div>
 
2226
  </div>
2227
  """
2228
  elif card_id == "event_card":
2229
+ base_style = "width: 100%; max-width: 280px; height: 120px; border-radius: 12px; overflow: hidden; box-shadow: 0 2px 8px rgba(0,0,0,0.1); background: white; display: flex;"
2230
  content = f"""
2231
  <div style="width: 80px; background: {primary}; color: white; display: flex; flex-direction: column; align-items: center; justify-content: center;">
2232
  <div style="font-size: 28px; font-weight: 700;">24</div>
 
2241
  </div>
2242
  """
2243
  elif card_id == "offer_coupon":
2244
+ base_style = "width: 100%; max-width: 260px; height: 140px; border-radius: 12px; overflow: hidden; box-shadow: 0 2px 8px rgba(0,0,0,0.1); background: white; border: 2px dashed {primary}; position: relative;"
2245
  content = f"""
2246
  <div style="padding: 20px; text-align: center;">
2247
  <div style="font-size: 10px; color: {primary}; font-weight: 600; margin-bottom: 8px;">SPECIAL OFFER</div>
 
2255
  </div>
2256
  """
2257
  elif card_id == "weather_card":
2258
+ base_style = "width: 100%; max-width: 200px; height: 200px; border-radius: 12px; overflow: hidden; box-shadow: 0 2px 8px rgba(0,0,0,0.1); background: linear-gradient(135deg, {primary}, {secondary}); color: white; padding: 20px;"
2259
  content = f"""
2260
  <div style="text-align: center;">
2261
  <div style="font-size: 12px; opacity: 0.9; margin-bottom: 8px;">San Francisco</div>
 
2269
  </div>
2270
  """
2271
  elif card_id == "ticket_card":
2272
+ base_style = "width: 100%; max-width: 280px; height: 160px; border-radius: 12px; overflow: hidden; box-shadow: 0 2px 8px rgba(0,0,0,0.1); background: white; position: relative;"
2273
  content = f"""
2274
  <div style="padding: 20px; padding-bottom: 16px;">
2275
  <div style="font-weight: 700; font-size: 14px; color: #333; margin-bottom: 8px;">Concert Night 2024</div>