TOTEM Studio commited on
Commit
e47eb3f
·
1 Parent(s): 4c77e4f

stage 4/5: wire brand assets + global #04081a dark background

Browse files

- Replace cream #fffaf0 with #04081a across all gradio container CSS
- Dark theme tab bar + tab buttons (gold/violet on dark)
- Sidebar: wire Ui Totem.png logo image, flex column layout, quote card to bottom
- Hero: wire Hero.png as full-cover background image, z-index layering for text/gauge
- Add hero-star, quote-star accent elements
- Quote card: italic serif, auto margin push to bottom

Files changed (1) hide show
  1. app.py +73 -26
app.py CHANGED
@@ -65,19 +65,28 @@ CSS = """
65
  .gradio-container {
66
  max-width: none !important;
67
  padding: 0 !important;
68
- background: #fffaf0 !important;
69
- color: var(--studio-ink) !important;
70
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif !important;
71
  }
72
 
 
 
 
 
 
 
 
 
 
73
  footer { display: none !important; }
74
 
75
  .gradio-container [role="tablist"] {
76
  position: sticky !important;
77
  top: 0 !important;
78
  z-index: 60 !important;
79
- background: #fffaf0 !important;
80
- border-bottom: 1px solid var(--studio-line);
81
  padding: 8px 10px;
82
  gap: 8px;
83
  overflow: visible !important;
@@ -86,18 +95,18 @@ footer { display: none !important; }
86
  .gradio-container [role="tab"] {
87
  opacity: 1 !important;
88
  visibility: visible !important;
89
- color: var(--studio-ink) !important;
90
- background: #f4ecd6 !important;
91
- border: 1px solid var(--studio-line) !important;
92
  border-radius: 8px !important;
93
  padding: 8px 14px !important;
94
  font-weight: 700 !important;
95
  }
96
 
97
  .gradio-container [role="tab"][aria-selected="true"] {
98
- background: linear-gradient(90deg, #f5c93c, #e5a721) !important;
99
- color: white !important;
100
- border-color: #d99e1b !important;
101
  }
102
 
103
  .nav-item[role="button"] {
@@ -305,6 +314,8 @@ TOTEM_CSS = """
305
  border-right: 1px solid rgba(242, 193, 78, 0.22);
306
  background: linear-gradient(180deg, #050d24 0%, #07122d 65%, #091733 100%);
307
  padding: 20px 18px;
 
 
308
  }
309
 
310
  .totem-main {
@@ -679,24 +690,53 @@ TOTEM_CSS = """
679
  }
680
 
681
  .totem-shell .totem-brand {
682
- font-family: var(--font-display);
683
- font-size: 34px;
684
- color: var(--totem-gold);
685
- line-height: 1.1;
686
  margin-bottom: var(--space-6);
 
687
  }
688
 
689
- .totem-shell .totem-brand small {
 
 
 
690
  display: block;
691
- margin-top: var(--space-2);
692
- font-family: var(--font-ui);
693
- font-size: 12px;
694
- letter-spacing: 1.5px;
695
- color: rgba(174, 183, 204, 0.9);
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
696
  }
697
 
698
  .totem-shell .totem-quote-card {
699
- margin-top: calc(var(--space-8) + var(--space-8));
700
  padding: var(--space-5);
701
  border-radius: var(--radius-card);
702
  border: 1px solid rgba(242, 193, 78, 0.28);
@@ -704,8 +744,9 @@ TOTEM_CSS = """
704
  linear-gradient(180deg, rgba(16, 26, 58, 0.95), rgba(11, 23, 51, 0.96));
705
  color: rgba(246, 241, 232, 0.95);
706
  font-family: var(--font-display);
707
- font-size: 24px;
708
- line-height: 1.25;
 
709
  }
710
 
711
  .totem-shell .totem-nav-item {
@@ -1199,9 +1240,14 @@ def render_sidebar(active: str = "Home") -> str:
1199
 
1200
  return f"""
1201
  <aside class="totem-sidebar">
1202
- <div class="totem-brand">TOTEM Studio<small>Story intelligence OS</small></div>
 
 
1203
  {''.join(items)}
1204
- <div class="totem-quote-card">Story intelligence turns inspiration into impact.</div>
 
 
 
1205
  </aside>
1206
  """
1207
 
@@ -1255,7 +1301,8 @@ def render_hero(state: dict) -> str:
1255
  signal = int(state.get("totem_signal", 0) or 0)
1256
  return f"""
1257
  <section class="totem-hero">
1258
- <h2 class="totem-hero-title">TOTEM Studio</h2>
 
1259
  <p class="totem-hero-subtitle">Data-driven insight for stronger stories.</p>
1260
  {render_signal_gauge(signal)}
1261
  </section>
 
65
  .gradio-container {
66
  max-width: none !important;
67
  padding: 0 !important;
68
+ background: #04081a !important;
69
+ color: #f6f1e8 !important;
70
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif !important;
71
  }
72
 
73
+ html, body {
74
+ background: #04081a !important;
75
+ }
76
+
77
+ .gradio-container > .tabs,
78
+ .gradio-container > div {
79
+ background: #04081a !important;
80
+ }
81
+
82
  footer { display: none !important; }
83
 
84
  .gradio-container [role="tablist"] {
85
  position: sticky !important;
86
  top: 0 !important;
87
  z-index: 60 !important;
88
+ background: #04081a !important;
89
+ border-bottom: 1px solid rgba(242, 193, 78, 0.22) !important;
90
  padding: 8px 10px;
91
  gap: 8px;
92
  overflow: visible !important;
 
95
  .gradio-container [role="tab"] {
96
  opacity: 1 !important;
97
  visibility: visible !important;
98
+ color: #aeb7cc !important;
99
+ background: rgba(7, 18, 45, 0.6) !important;
100
+ border: 1px solid rgba(242, 193, 78, 0.22) !important;
101
  border-radius: 8px !important;
102
  padding: 8px 14px !important;
103
  font-weight: 700 !important;
104
  }
105
 
106
  .gradio-container [role="tab"][aria-selected="true"] {
107
+ background: linear-gradient(90deg, rgba(242, 193, 78, 0.25), rgba(138, 77, 255, 0.25)) !important;
108
+ color: #f2c14e !important;
109
+ border-color: rgba(242, 193, 78, 0.55) !important;
110
  }
111
 
112
  .nav-item[role="button"] {
 
314
  border-right: 1px solid rgba(242, 193, 78, 0.22);
315
  background: linear-gradient(180deg, #050d24 0%, #07122d 65%, #091733 100%);
316
  padding: 20px 18px;
317
+ display: flex;
318
+ flex-direction: column;
319
  }
320
 
321
  .totem-main {
 
690
  }
691
 
692
  .totem-shell .totem-brand {
 
 
 
 
693
  margin-bottom: var(--space-6);
694
+ line-height: 1.1;
695
  }
696
 
697
+ .totem-shell .totem-brand-img {
698
+ width: 100%;
699
+ max-width: 220px;
700
+ height: auto;
701
  display: block;
702
+ border-radius: 10px;
703
+ }
704
+
705
+ .totem-hero-bg {
706
+ position: absolute;
707
+ inset: 0;
708
+ width: 100%;
709
+ height: 100%;
710
+ object-fit: cover;
711
+ object-position: center;
712
+ border-radius: inherit;
713
+ z-index: 0;
714
+ }
715
+
716
+ .totem-hero-title,
717
+ .totem-hero-subtitle,
718
+ .totem-signal-wrap {
719
+ position: relative;
720
+ z-index: 1;
721
+ }
722
+
723
+ .totem-hero-star {
724
+ font-size: 22px;
725
+ vertical-align: super;
726
+ margin-left: 4px;
727
+ color: var(--totem-gold);
728
+ }
729
+
730
+ .totem-quote-star {
731
+ display: block;
732
+ font-size: 16px;
733
+ color: var(--totem-gold);
734
+ margin-bottom: var(--space-2);
735
+ opacity: 0.8;
736
  }
737
 
738
  .totem-shell .totem-quote-card {
739
+ margin-top: auto;
740
  padding: var(--space-5);
741
  border-radius: var(--radius-card);
742
  border: 1px solid rgba(242, 193, 78, 0.28);
 
744
  linear-gradient(180deg, rgba(16, 26, 58, 0.95), rgba(11, 23, 51, 0.96));
745
  color: rgba(246, 241, 232, 0.95);
746
  font-family: var(--font-display);
747
+ font-size: 20px;
748
+ line-height: 1.35;
749
+ font-style: italic;
750
  }
751
 
752
  .totem-shell .totem-nav-item {
 
1240
 
1241
  return f"""
1242
  <aside class="totem-sidebar">
1243
+ <div class="totem-brand">
1244
+ <img src="/file=assets/Brand/Ui Totem.png" alt="TOTEM Studio" class="totem-brand-img" />
1245
+ </div>
1246
  {''.join(items)}
1247
+ <div class="totem-quote-card">
1248
+ <span class="totem-quote-star">✦</span>
1249
+ Story intelligence turns inspiration into impact.
1250
+ </div>
1251
  </aside>
1252
  """
1253
 
 
1301
  signal = int(state.get("totem_signal", 0) or 0)
1302
  return f"""
1303
  <section class="totem-hero">
1304
+ <img src="/file=assets/Brand/Hero.png" alt="" class="totem-hero-bg" aria-hidden="true" />
1305
+ <h2 class="totem-hero-title">TOTEM Studio<span class="totem-hero-star">✦</span></h2>
1306
  <p class="totem-hero-subtitle">Data-driven insight for stronger stories.</p>
1307
  {render_signal_gauge(signal)}
1308
  </section>