Spaces:
Running
Running
feat: Add a demo video link to the UI and enhance styling for the workflow overview, main cards, and overall page container.
ac730ad
| /* Global background + text color */ | |
| :root { | |
| --color-background-primary: #f5f5fb; | |
| --color-background-secondary: #ffffff; | |
| --background-fill-primary: #f5f5fb; | |
| --background-fill-secondary: #ffffff; | |
| --block-background-fill: #ffffff; | |
| } | |
| html, | |
| body { | |
| background: #f5f5fb; | |
| color: #111827; | |
| margin: 0; | |
| } | |
| .gradio-container { | |
| max-width: 1200px ; | |
| /* change to 100% for full-width */ | |
| margin: 0 auto ; | |
| padding-inline: 24px; | |
| background: transparent ; | |
| font-family: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif; | |
| } | |
| /* Kill default grey on generic panels/boxes */ | |
| .gr-block, | |
| .gr-box, | |
| .gr-panel { | |
| background: transparent ; | |
| } | |
| /* Main section cards (API Config + Results) */ | |
| .section-card, | |
| #config-card, | |
| #results-card { | |
| background: #ffffff ; | |
| /* force white, remove grey header */ | |
| border-radius: 12px; | |
| padding: 16px 18px; | |
| box-shadow: 0 10px 25px rgba(15, 23, 42, 0.08); | |
| border: 1px solid #e5e7eb; | |
| } | |
| .section-card h3, | |
| .section-card h4 { | |
| margin-top: 0; | |
| color: #111827; | |
| } | |
| #app-header { | |
| margin-bottom: 1.25rem; | |
| } | |
| #app-header h1 { | |
| font-size: 2.2rem; | |
| margin-bottom: 0.25rem; | |
| color: #0f172a; | |
| } | |
| #app-header p { | |
| color: #4b5563; | |
| /* darker, more readable */ | |
| font-size: 0.95rem; | |
| margin-top: 0.25rem; | |
| } | |
| .badge-pill { | |
| display: inline-flex; | |
| align-items: center; | |
| gap: 0.4rem; | |
| padding: 0.25rem 0.85rem; | |
| border-radius: 999px; | |
| font-size: 0.9rem; | |
| /* bigger badge text */ | |
| font-weight: 600; | |
| background: #ecfdf3; | |
| color: #15803d; | |
| border: 1px solid #bbf7d0; | |
| } | |
| .badge-pill .dot { | |
| width: 9px; | |
| height: 9px; | |
| border-radius: 999px; | |
| background: #22c55e; | |
| box-shadow: 0 0 0 4px rgba(34, 197, 94, 0.25); | |
| } | |
| #disclaimer-box { | |
| background: #fefce8; | |
| border-left: 4px solid #f59e0b; | |
| padding: 10px 12px; | |
| border-radius: 10px; | |
| font-size: 0.86rem; | |
| margin-top: 0.5rem; | |
| color: #92400e; | |
| } | |
| #disclaimer-box strong { | |
| color: #b45309; | |
| } | |
| #config-card>div>label span, | |
| #results-card>div>label span { | |
| font-weight: 500; | |
| color: #111827; | |
| } | |
| /* Reduce font size inside the Security Tutor chatbot */ | |
| #tutor-chat * { | |
| font-size: 0.80rem ; | |
| } | |
| #tutor-chat .message { | |
| padding-top: 4px; | |
| padding-bottom: 4px; | |
| } | |
| /* Reset button styling – elem_id is on the button itself */ | |
| #reset-btn { | |
| background-color: #e0f2fe ; | |
| /* light blue */ | |
| color: #0369a1 ; | |
| border-color: #bae6fd ; | |
| } | |
| #reset-btn:hover { | |
| background-color: #bfdbfe ; | |
| } | |
| /* --- Professional full-width tabs for Security Assessment Results --- */ | |
| /* Tab bar container */ | |
| #results-card [role="tablist"] { | |
| background: #ffffff ; | |
| /* ensure no grey behind tabs */ | |
| border-radius: 8px; | |
| border: 1px solid #e5e7eb; | |
| display: flex; | |
| padding: 0; | |
| margin-top: 4px; | |
| overflow: hidden; | |
| } | |
| /* Each tab button */ | |
| #results-card [role="tablist"] button { | |
| flex: 1 1 0; | |
| justify-content: center; | |
| background: #ffffff ; | |
| color: #374151; | |
| border-radius: 0; | |
| border: none; | |
| box-shadow: none; | |
| font-size: 0.9rem; | |
| padding-block: 0.4rem; | |
| padding-inline: 0.75rem; | |
| } | |
| /* Hover state for inactive tabs */ | |
| #results-card [role="tablist"] button:hover:not([aria-selected="true"]) { | |
| background: #f3f4f6; | |
| } | |
| /* Active tab (selected) */ | |
| #results-card [role="tablist"] button[aria-selected="true"] { | |
| background: #ffffff ; | |
| color: #ea580c ; | |
| /* orange accent */ | |
| font-weight: 600; | |
| box-shadow: inset 0 -3px 0 #ea580c; | |
| /* bottom border highlight */ | |
| } | |
| /* Ensure tab content area is white */ | |
| #results-card .tabitem { | |
| background: #ffffff ; | |
| } | |
| /* --- Security Tutor panel styling --- */ | |
| #tutor-section { | |
| margin-top: 6px; | |
| gap: 10px; | |
| } | |
| /* Input row card */ | |
| #tutor-input-row { | |
| background: #f9fafb; | |
| border-radius: 12px; | |
| padding: 10px 12px; | |
| border: 1px solid #e5e7eb; | |
| align-items: stretch; | |
| } | |
| /* Text area inside tutor row */ | |
| #tutor-input-row textarea { | |
| min-height: 64px; | |
| border-radius: 8px 0 0 8px ; | |
| } | |
| /* Ask button styled as attached to textbox */ | |
| #tutor-input-row button { | |
| height: 100%; | |
| border-radius: 0 8px 8px 0 ; | |
| padding-inline: 1.6rem; | |
| font-weight: 600; | |
| } | |
| /* Example box */ | |
| #tutor-examples { | |
| margin-top: 10px; | |
| background: #f9fafb; | |
| border-radius: 10px; | |
| padding: 10px 12px; | |
| border: 1px solid #e5e7eb; | |
| font-size: 0.86rem; | |
| } | |
| #tutor-examples strong { | |
| display: block; | |
| margin-bottom: 4px; | |
| color: #111827; | |
| } | |
| #tutor-examples ul { | |
| margin: 0; | |
| padding-left: 1.1rem; | |
| } | |
| /* Security Report markdown container */ | |
| #security-report-md { | |
| background: #ffffff ; | |
| border-radius: 8px; | |
| padding: 16px 20px; | |
| border: 1px solid #e5e7eb; | |
| max-height: 520px; | |
| /* adjust as you like */ | |
| overflow-y: auto; | |
| /* vertical scroll when content exceeds height */ | |
| overflow-x: hidden; | |
| /* avoid horizontal bar unless you need it */ | |
| } | |
| /* Inner markdown/prose should be transparent, no extra padding/border */ | |
| #security-report-md .gr-markdown, | |
| #security-report-md .prose { | |
| background: transparent ; | |
| border: none ; | |
| box-shadow: none ; | |
| padding: 0 ; | |
| } | |
| /* Center the two dashboard charts horizontally */ | |
| #dashboard-row { | |
| justify-content: center; | |
| gap: 24px; | |
| } | |
| #risk-col, | |
| #severity-col { | |
| display: flex; | |
| justify-content: center; | |
| } | |
| #risk-col .gr-plot, | |
| #severity-col .gr-plot { | |
| max-width: 480px; | |
| width: 100%; | |
| } | |
| /* Demo video row with divider */ | |
| #demo-video-row { | |
| margin-top: 0 ; | |
| margin-bottom: 0.75rem ; | |
| padding: 0.75rem 0 0.85rem 0 ; | |
| background: linear-gradient(to right, #e0f2fe, #dbeafe, #e0f2fe) ; | |
| border-radius: 8px; | |
| border-bottom: 2px solid #e5e7eb; | |
| } | |
| #demo-video-row>div { | |
| padding: 0 ; | |
| } | |
| /* Workflow Overview card styling */ | |
| #workflow-overview-card { | |
| background: #f9fafb ; | |
| border: 1px solid #e5e7eb; | |
| border-radius: 12px; | |
| padding: 16px 18px; | |
| box-shadow: 0 10px 25px rgba(15, 23, 42, 0.08); | |
| } | |
| /* Add left accent border to main cards */ | |
| #config-card { | |
| border-left: 4px solid #3b82f6 ; | |
| } | |
| #results-card { | |
| border-left: 4px solid #ea580c ; | |
| } | |
| /* Page frame - subtle border and elevated shadow */ | |
| .gradio-container { | |
| border: 1px solid #d1d5db; | |
| box-shadow: 0 20px 60px rgba(15, 23, 42, 0.12), 0 0 0 1px rgba(15, 23, 42, 0.05); | |
| border-radius: 16px; | |
| background: #ffffff ; | |
| } |