canloc / static /style.css
Biocoder09's picture
Update static/style.css
1a7c034 verified
raw
history blame
8.17 kB
:root{
--navy:#04293a;
--navy-dark:#02151a;
--turq:#2dd4bf;
--turq-light:#5ffbf1;
--text:#e6f7f5;
--muted:#a6b8b8;
--card-bg:rgba(255,255,255,0.02);
--border:rgba(255,255,255,0.04);
--glass:rgba(255,255,255,0.03);
}
/* RESET */
*{
margin:0;
padding:0;
box-sizing:border-box;
font-family:Inter, system-ui, Roboto, "Helvetica Neue", Arial;
}
body{
background:linear-gradient(180deg, var(--navy-dark), #041a20);
color:var(--text);
-webkit-font-smoothing:antialiased;
}
/* NAVBAR */
.nav.fixed{
position:fixed;
top:0; left:0; right:0;
z-index:100;
background:rgba(4,41,58,0.93);
backdrop-filter:blur(8px);
border-bottom:1px solid var(--border);
}
.nav-inner{
max-width:1180px;
margin:auto;
padding:12px 16px;
display:flex;
justify-content:space-between;
align-items:center;
}
.nav-left{
display:flex;
align-items:center;
}
.logo-circle{
width:42px;
height:42px;
border-radius:50%;
background:linear-gradient(135deg, var(--turq), #0be8c4);
display:flex;
justify-content:center;
align-items:center;
font-size:20px;
}
.logo-text{
margin-left:10px;
}
.logo-title{
font-weight:700;
font-size:20px;
}
.logo-sub{
color:var(--muted);
font-size:12px;
margin-top:2px;
}
.nav-links{
display:flex;
gap:20px;
}
.nav-link{
text-decoration:none;
color:var(--muted);
font-size:14px;
padding:6px 10px;
border-radius:8px;
}
.nav-link:hover{
color:var(--turq);
background:rgba(255,255,255,0.03);
}
/* HERO (SVG background) */
.hero{
height:260px;
display:flex;
align-items:center;
justify-content:center;
position:relative;
overflow:hidden;
margin-top:70px;
background:linear-gradient(180deg, var(--navy-dark), #042029);
}
.hero-network{
position:absolute;
inset:0;
background-image:url("/static/protein_hero.svg");
background-size:cover;
background-position:center;
opacity:0.42;
filter:drop-shadow(0 0 35px var(--turq));
pointer-events:none;
}
.hero-inner{
position:relative;
z-index:2;
text-align:center;
}
.hero-title{
font-size:42px;
font-weight:700;
line-height:1.1;
text-shadow:0 0 8px rgba(20,184,166,0.55);
}
.hero-title span{
color:var(--turq);
}
.hero-sub{
color:var(--muted);
margin-top:10px;
font-size:15px;
max-width:850px;
margin:auto;
}
/* MAIN LAYOUT */
.main-wrap{
max-width:1100px;
margin:20px auto 60px auto;
padding:0 16px;
}
.card{
background:var(--card-bg);
border:1px solid var(--border);
border-radius:14px;
padding:20px;
box-shadow:0 10px 30px rgba(0,0,0,0.5);
margin-bottom:20px;
}
/* TABS */
.tabs{
display:flex;
gap:10px;
margin-bottom:16px;
}
.tab{
padding:8px 16px;
border-radius:999px;
border:1px solid var(--border);
background:transparent;
color:var(--muted);
cursor:pointer;
}
.tab.active{
background:linear-gradient(90deg, var(--turq), #24d6b3);
color:#05323a;
font-weight:700;
}
.panel{
margin-top:10px;
}
/* TEXTAREA + UPLOAD */
.label{
color:var(--muted);
font-size:13px;
margin-bottom:6px;
display:block;
}
textarea{
width:100%;
min-height:160px;
background:var(--glass);
border:1px solid var(--border);
border-radius:10px;
padding:12px;
color:var(--text);
resize:vertical;
}
input[type=file]{
color:var(--muted);
}
.row{
margin-top:12px;
display:flex;
align-items:center;
gap:12px;
}
.btn{
background:linear-gradient(90deg, var(--turq), #25cdb6);
color:#032b2a;
border:none;
font-weight:700;
padding:10px 18px;
border-radius:999px;
cursor:pointer;
}
.btn:hover{
filter:brightness(1.08);
}
.loading{
font-size:13px;
color:var(--muted);
}
/* RESULT CARD */
.result-card{
background:rgba(255,255,255,0.02);
margin-top:20px;
padding:18px;
border-radius:12px;
border:1px solid var(--border);
}
.result-header{
font-size:20px;
font-weight:700;
}
.warning-text{
color:var(--muted);
margin-top:6px;
}
/* PROBABILITIES */
.prob-box{
margin-top:14px;
}
.prob-list{
display:grid;
grid-template-columns:repeat(auto-fit, minmax(150px,1fr));
gap:10px;
}
.prob-item{
background:rgba(255,255,255,0.02);
padding:8px;
border-radius:8px;
border:1px solid var(--border);
display:flex;
justify-content:space-between;
font-size:14px;
}
/* CHARTS */
.chart-title {
text-align: center;
font-weight: 700;
margin-bottom: 8px;
}
.charts-row{
display:flex;
gap:16px;
flex-wrap:wrap;
margin-top:14px;
}
.chart-card{
flex:1 1 300px;
background:rgba(255,255,255,0.01);
border:1px solid var(--border);
padding:12px;
border-radius:10px;
}
canvas{
width:100%!important;
height:240px!important;
}
/* FASTA TABLE */
.fasta-wrapper{
margin-top:18px;
}
.small-text{
color:var(--muted);
font-size:13px;
margin-bottom:8px;
}
.table-container{
margin-top:8px;
border-radius:12px;
overflow:hidden;
border:1px solid var(--border);
}
.results-table{
width:100%;
border-collapse:collapse;
font-size:14px;
}
.results-table th,
.results-table td{
padding:10px;
border-bottom:1px solid rgba(255,255,255,0.04);
color:var(--muted);
}
.results-table tbody tr{
cursor:pointer;
}
.results-table tbody tr:hover{
background:rgba(255,255,255,0.04);
}
/* FASTA MODAL (no charts) */
.modal{
position:fixed;
inset:0;
display:flex;
justify-content:center;
align-items:center;
z-index:200;
}
.modal-backdrop{
position:absolute;
inset:0;
background:rgba(0,0,0,0.7);
}
.modal-content{
position:relative;
z-index:2;
background:linear-gradient(180deg,#041e21,#022326);
border:1px solid var(--border);
padding:16px;
border-radius:14px;
width:92%;
max-width:600px;
}
.modal-close{
position:absolute;
top:8px;
right:10px;
background:transparent;
border:none;
font-size:22px;
color:var(--muted);
cursor:pointer;
}
.modal-meta{
color:var(--muted);
font-size:13px;
margin-bottom:8px;
}
/* BIG CHART MODALS */
.chart-modal{
position:fixed;
inset:0;
background:rgba(0,0,0,0.75);
display:flex;
justify-content:center;
align-items:center;
z-index:3000;
}
.chart-modal-content{
position:relative;
background:#0f172a;
padding:20px;
border-radius:10px;
}
.close-big-chart{
position:absolute;
top:10px;
right:15px;
font-size:26px;
cursor:pointer;
color:white;
}
/* FOOTER */
.footer{
text-align:center;
padding:18px 0;
color:var(--muted);
border-top:1px solid var(--border);
margin-top:40px;
}
/* FASTA TABLE ALIGNMENT */
/* Targets the table you already render: .results-table */
.results-table {
width: 100%;
border-collapse: collapse;
table-layout: fixed; /* force column widths to be respected */
font-size: 14px;
}
.results-table th,
.results-table td {
text-align: center;
padding: 10px;
white-space: nowrap;
overflow: hidden;
text-overflow: ellipsis;
}
/* set sensible column widths (adjust numbers if needed) */
.results-table th:nth-child(1),
.results-table td:nth-child(1) { width: 48px; } /* # */
.results-table th:nth-child(2),
.results-table td:nth-child(2) { width: 360px; } /* Sequence ID */
.results-table th:nth-child(3),
.results-table td:nth-child(3) { width: 110px; } /* Length */
.results-table th:nth-child(4),
.results-table td:nth-child(4) { width: 180px; } /* Predicted Location */
.results-table th:nth-child(5),
.results-table td:nth-child(5) { width: 120px; } /* Max Confidence */
/* visual niceties */
.results-table thead th {
background: rgba(10, 61, 98, 0.95);
color: #fff;
font-weight: 600;
}
.results-table tbody tr:hover {
background: rgba(255,255,255,0.02);
}
/* UTILITIES */
.hidden{
display:none;
}
/* RESPONSIVE */
@media(max-width:860px){
.nav-inner{
flex-direction:column;
align-items:flex-start;
gap:6px;
}
.hero-title{
font-size:32px;
}
canvas{
height:220px!important;
}
}
.about-flex {
display: flex;
gap: 2.5rem;
align-items: center;
}
.about-text {
flex: 1.2;
}
.about-image {
flex: 1;
text-align: center;
}
.about-image img {
max-width: 100%;
height: auto;
border-radius: 14px;
box-shadow: 0 15px 35px rgba(0, 0, 0, 0.3);
}
@media (max-width: 900px) {
.about-flex {
flex-direction: column;
}
}