PneumoDetect / static /css /style.css
Azhar Ahmed
Upload 3 files
6e09754 verified
Raw
History Blame Contribute Delete
7 kB
:root {
--bg: #f8fafc;
--card-bg: rgba(255, 255, 255, 0.9);
--primary: #4f46e5;
--primary-glow: rgba(79, 70, 229, 0.15);
--success: #059669;
--danger: #dc2626;
--text-main: #0f172a;
--text-dim: #64748b;
--border: rgba(0, 0, 0, 0.08);
}
* {
margin: 0;
padding: 0;
box-sizing: border-box;
}
body {
background-color: var(--bg);
color: var(--text-main);
font-family: 'Inter', sans-serif;
min-height: 100vh;
display: flex;
justify-content: center;
align-items: center;
overflow-x: hidden;
background-image:
radial-gradient(at 0% 0%, hsla(244, 83%, 58%, 0.05) 0px, transparent 50%),
radial-gradient(at 100% 0%, hsla(160, 83%, 58%, 0.05) 0px, transparent 50%),
radial-gradient(at 100% 100%, hsla(244, 83%, 58%, 0.05) 0px, transparent 50%),
radial-gradient(at 0% 100%, hsla(190, 83%, 58%, 0.05) 0px, transparent 50%);
}
.app-container {
width: 100%;
max-width: 600px;
padding: 2rem;
display: flex;
flex-direction: column;
gap: 2rem;
}
/* Header */
.header {
text-align: center;
}
.logo {
display: flex;
align-items: center;
justify-content: center;
gap: 0.75rem;
font-size: 1.5rem;
font-weight: 700;
letter-spacing: -0.5px;
}
.logo i {
color: var(--primary);
font-size: 1.75rem;
}
/* Main Card */
.glass-card {
background: var(--card-bg);
backdrop-filter: blur(24px) saturate(180%);
border: 1px solid rgba(0, 0, 0, 0.05);
border-radius: 32px;
padding: 3rem;
box-shadow:
0 25px 50px -12px rgba(0, 0, 0, 0.1),
0 0 0 1px rgba(255, 255, 255, 0.8) inset;
min-height: 450px;
display: flex;
flex-direction: column;
position: relative;
overflow: hidden;
transition: transform 0.3s ease, box-shadow 0.3s ease;
}
.glass-card:hover {
box-shadow:
0 30px 60px -12px rgba(0, 0, 0, 0.15),
0 0 20px rgba(79, 70, 229, 0.05);
}
.state-content {
animation: fadeIn 0.5s ease-out;
}
@keyframes fadeIn {
from {
opacity: 0;
transform: translateY(10px);
}
to {
opacity: 1;
transform: translateY(0);
}
}
/* Hero Section */
.hero-text {
text-align: center;
margin-bottom: 2rem;
}
.hero-text h1 {
font-size: 1.75rem;
font-weight: 700;
margin-bottom: 0.5rem;
}
.hero-text p {
color: var(--text-dim);
font-size: 0.95rem;
}
/* Upload Box */
.upload-box {
border: 2px dashed rgba(0, 0, 0, 0.1);
border-radius: 20px;
padding: 3rem 2rem;
text-align: center;
transition: 0.3s;
cursor: pointer;
}
.upload-box:hover {
border-color: var(--primary);
background: rgba(79, 70, 229, 0.02);
}
.upload-icon {
width: 64px;
height: 64px;
background: rgba(79, 70, 229, 0.08);
border-radius: 50%;
display: flex;
align-items: center;
justify-content: center;
margin: 0 auto 1.5rem;
color: var(--primary);
font-size: 1.5rem;
}
.upload-box h3 {
margin-bottom: 0.5rem;
}
.upload-box p {
color: var(--text-dim);
font-size: 0.85rem;
margin-bottom: 1.5rem;
}
/* Analysis State */
.preview-area {
position: relative;
border-radius: 16px;
overflow: hidden;
margin-bottom: 2rem;
aspect-ratio: 1;
background: #000;
}
.preview-area img {
width: 100%;
height: 100%;
object-fit: contain;
opacity: 0.6;
}
.scan-bar {
position: absolute;
top: 0;
left: 0;
width: 100%;
height: 4px;
background: linear-gradient(90deg, transparent, var(--primary), transparent);
box-shadow: 0 0 20px var(--primary), 0 0 40px var(--primary);
animation: scan 2.5s infinite cubic-bezier(0.4, 0, 0.2, 1);
z-index: 10;
}
@keyframes scan {
0% {
top: 0%;
opacity: 0;
}
10% {
opacity: 1;
}
90% {
opacity: 1;
}
100% {
top: 100%;
opacity: 0;
}
}
.loader-container {
text-align: center;
padding: 1rem;
}
.spinner {
width: 40px;
height: 40px;
border: 3px solid rgba(255, 255, 255, 0.1);
border-top-color: var(--primary);
border-radius: 50%;
animation: spin 1s infinite linear;
margin: 0 auto 1rem;
}
@keyframes spin {
to {
transform: rotate(360deg);
}
}
.pulse-text {
animation: pulse 2s infinite ease-in-out;
}
@keyframes pulse {
0%,
100% {
opacity: 1;
transform: scale(1);
}
50% {
opacity: 0.7;
transform: scale(0.98);
}
}
/* Results State */
.result-header {
text-align: center;
margin-bottom: 2.5rem;
}
.result-icon {
font-size: 4rem;
margin-bottom: 1rem;
color: var(--success);
}
.result-header h2 {
font-size: 2.25rem;
font-weight: 800;
margin-bottom: 0.25rem;
}
.result-header p {
color: var(--text-dim);
font-weight: 500;
}
.result-details {
margin-bottom: 2.5rem;
}
.prob-row {
margin-bottom: 1.5rem;
}
.prob-row span {
display: block;
font-size: 0.85rem;
color: var(--text-dim);
margin-bottom: 0.5rem;
}
.progress-bg {
height: 8px;
background: rgba(0, 0, 0, 0.05);
border-radius: 4px;
overflow: hidden;
margin-bottom: 0.25rem;
}
.progress-fill {
height: 100%;
background: var(--primary);
width: 0%;
transition: 1.5s cubic-bezier(0.4, 0, 0.2, 1);
}
.val {
font-family: monospace;
font-size: 0.9rem;
color: var(--text-main);
}
/* Buttons */
.btn-primary {
background: linear-gradient(135deg, var(--primary), #6366f1);
color: white;
border: none;
padding: 1rem 2.5rem;
border-radius: 16px;
font-weight: 700;
font-size: 1rem;
letter-spacing: 0.5px;
cursor: pointer;
transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
box-shadow: 0 4px 15px var(--primary-glow);
position: relative;
overflow: hidden;
}
.btn-primary::after {
content: '';
position: absolute;
top: -50%;
left: -50%;
width: 200%;
height: 200%;
background: linear-gradient(45deg, transparent, rgba(255, 255, 255, 0.1), transparent);
transform: rotate(45deg);
transition: 0.5s;
}
.btn-primary:hover {
transform: translateY(-3px) scale(1.02);
box-shadow: 0 12px 25px var(--primary-glow);
}
.btn-primary:hover::after {
left: 100%;
}
.btn-secondary {
background: rgba(255, 255, 255, 0.05);
color: var(--text-main);
border: 1px solid var(--border);
padding: 0.8rem 1.5rem;
border-radius: 12px;
font-weight: 600;
cursor: pointer;
width: 100%;
display: flex;
align-items: center;
justify-content: center;
gap: 0.5rem;
transition: 0.3s;
}
.btn-secondary:hover {
background: rgba(255, 255, 255, 0.1);
}
/* Footer */
.footer {
text-align: center;
color: var(--text-dim);
font-size: 0.8rem;
}
@media (max-width: 480px) {
.glass-card {
padding: 1.5rem;
}
.app-container {
padding: 1rem;
}
}