Dinesh4311's picture
Add application code
aa752f5 verified
Raw
History Blame Contribute Delete
11 kB
:root {
--bg: #f5f7f4;
--panel: #ffffff;
--ink: #1c2421;
--muted: #6b7770;
--line: #e1e7e0;
--accent: #2e7d4f;
--accent-d: #1f5c39;
--accent-soft: #e8f3ec;
--warn: #b23c3c;
--radius: 10px;
--shadow: 0 1px 3px rgba(0,0,0,.06), 0 6px 24px rgba(0,0,0,.04);
}
* { box-sizing: border-box; }
body {
margin: 0; background: var(--bg); color: var(--ink);
font: 15px/1.5 system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
}
.topbar {
display: flex; align-items: baseline; gap: 16px;
padding: 14px 24px; background: var(--panel); border-bottom: 1px solid var(--line);
}
.brand { font-size: 19px; font-weight: 700; }
.brand .leaf { font-size: 22px; }
.brand .ver {
font-size: 11px; font-weight: 700; color: var(--accent);
background: var(--accent-soft); padding: 2px 7px; border-radius: 20px; vertical-align: middle;
}
.tagline { color: var(--muted); font-size: 13px; }
.layout {
display: grid; grid-template-columns: 360px 1fr; gap: 20px;
padding: 20px; max-width: 1400px; margin: 0 auto;
}
@media (max-width: 900px) { .layout { grid-template-columns: 1fr; } }
.panel {
background: var(--panel); border: 1px solid var(--line);
border-radius: var(--radius); padding: 20px; box-shadow: var(--shadow);
}
.panel h2 { margin: 0 0 16px; font-size: 16px; }
.panel h3 { margin: 24px 0 10px; font-size: 14px; color: var(--accent-d);
border-bottom: 1px solid var(--line); padding-bottom: 6px; }
.controls label { display: block; margin: 14px 0 4px; font-size: 13px; font-weight: 600; }
.controls label.check { font-weight: 400; display: flex; gap: 8px; align-items: center; margin: 6px 0; }
select, textarea, input[type=range] { width: 100%; }
select, textarea {
padding: 8px; border: 1px solid var(--line); border-radius: 7px;
font: inherit; background: #fff; margin-top: 4px;
}
textarea { resize: vertical; font-family: ui-monospace, "SF Mono", Menlo, monospace; font-size: 13px; }
input[type=range] { accent-color: var(--accent); margin-top: 6px; }
output { float: right; font-weight: 700; color: var(--accent-d); }
fieldset { border: 1px solid var(--line); border-radius: 8px; margin: 16px 0; padding: 10px 12px; }
legend { font-size: 12px; font-weight: 700; color: var(--muted); text-transform: uppercase; letter-spacing: .04em; padding: 0 6px; }
button.primary {
width: 100%; margin-top: 18px; padding: 12px; border: 0; border-radius: 8px;
background: var(--accent); color: #fff; font-size: 15px; font-weight: 700; cursor: pointer;
transition: background .15s;
}
button.primary:hover { background: var(--accent-d); }
button.primary:disabled { background: var(--muted); cursor: progress; }
.empty { color: var(--muted); text-align: center; padding: 60px 20px; }
.muted { color: var(--muted); font-size: 13px; }
.hidden { display: none !important; }
#progress-wrap { margin-bottom: 16px; }
.progress-label { font-size: 13px; color: var(--muted); margin-bottom: 6px; }
.progress-track { height: 8px; background: var(--line); border-radius: 20px; overflow: hidden; }
.progress-bar { height: 100%; width: 0%; background: linear-gradient(90deg, var(--accent), #57b87e);
transition: width .12s ease; }
.metric-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(120px, 1fr)); gap: 12px; }
.metric {
background: var(--accent-soft); border: 1px solid var(--line); border-radius: 8px;
padding: 12px 14px;
}
.metric .label { font-size: 11px; color: var(--muted); text-transform: uppercase; letter-spacing: .03em; }
.metric .value { font-size: 22px; font-weight: 700; color: var(--accent-d); }
.seq-viewer { height: 360px; border: 1px solid var(--line); border-radius: 8px; overflow: hidden; }
.chart { height: 260px; }
table.data { width: 100%; border-collapse: collapse; font-size: 13px; }
table.data th, table.data td { text-align: left; padding: 7px 10px; border-bottom: 1px solid var(--line); }
table.data th { color: var(--muted); font-size: 11px; text-transform: uppercase; letter-spacing: .03em; }
table.data code { font-family: ui-monospace, Menlo, monospace; font-size: 12px; }
.badge { display: inline-block; padding: 1px 7px; border-radius: 20px; font-size: 11px; font-weight: 700; }
.badge.good { background: #e3f3e8; color: var(--accent-d); }
.badge.warn { background: #fbe8e8; color: var(--warn); }
.error { background: #fbe8e8; color: var(--warn); border: 1px solid #f1c9c9;
border-radius: 8px; padding: 12px 14px; margin-bottom: 14px; font-size: 14px; }
.export-row { display: flex; gap: 10px; flex-wrap: wrap; }
.export-row a {
text-decoration: none; padding: 9px 14px; border: 1px solid var(--accent);
color: var(--accent-d); border-radius: 7px; font-size: 13px; font-weight: 600; background: #fff;
}
.export-row a:hover { background: var(--accent-soft); }
.kv { display: flex; flex-wrap: wrap; gap: 8px 18px; font-size: 13px; }
.kv code { background: #f0f3ef; padding: 2px 6px; border-radius: 5px; }
/* ── Generated DNA sequence output ─────────────────────────────────────── */
.seq-mono {
font-family: ui-monospace, "SF Mono", "Cascadia Code", Menlo, Consolas, monospace;
font-size: 12.5px; line-height: 1.55; letter-spacing: .03em;
white-space: pre-wrap; word-break: break-all; margin: 0;
}
.seq-output-wrap {
border: 1px solid var(--line); border-radius: var(--radius);
background: #0f1c14; padding: 14px 16px; margin-bottom: 18px;
box-shadow: var(--shadow);
}
.seq-output-head {
display: flex; align-items: center; gap: 12px; flex-wrap: wrap; margin-bottom: 10px;
}
.seq-output-head h3 { margin: 0; color: #d6f0df; font-size: 14px; }
.seq-meta { display: flex; gap: 14px; flex-wrap: wrap; font-size: 12px; color: #9fc7ad; }
.seq-meta strong { color: #eafff0; }
.seq-meta code { background: rgba(255,255,255,.08); padding: 1px 6px; border-radius: 5px; color: #cfe9d8; }
.copy-btn {
margin-left: auto; background: var(--accent); color: #fff; border: none;
padding: 6px 16px; border-radius: 7px; font-size: 13px; font-weight: 600; cursor: pointer;
}
.copy-btn:hover { background: #3a9a62; }
.seq-output { color: #8ee6a8; max-height: 220px; overflow-y: auto; }
/* ── Flagship feature badge ─────────────────────────────────────────────── */
.badge.flagship {
background: linear-gradient(90deg, #2e7d4f, #57b87e);
color: #fff; box-shadow: 0 1px 4px rgba(46,125,79,.4);
}
/* ── Biological target: trait β†’ mechanism β†’ protein flow ────────────────── */
.biotarget-flow { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; margin: 4px 0 6px; }
.bt-step {
padding: 6px 12px; border-radius: 7px; font-weight: 600; font-size: 13px;
border: 1px solid var(--line);
}
.bt-trait { background: var(--accent-soft); color: var(--accent-d); }
.bt-mech { background: #eef3fb; color: #2c5aa0; }
.bt-gene { background: #fbf0e8; color: #b5651d; }
.bt-dna { background: #0f1c14; color: #8ee6a8; border-color: #0f1c14; }
.bt-arrow { color: var(--muted); font-weight: 700; }
/* ── GA objective-contribution bars ─────────────────────────────────────── */
.ga-bars { margin-top: 6px; }
.ga-bar-row { display: flex; align-items: center; gap: 10px; margin: 3px 0; font-size: 12px; }
.ga-bar-label { flex: 0 0 130px; color: var(--ink); text-transform: capitalize; }
.ga-bar-track { flex: 1; height: 12px; background: #eef1ee; border-radius: 6px; overflow: hidden; }
.ga-bar-fill { display: block; height: 100%; border-radius: 6px; }
.ga-bar-fill.pos { background: linear-gradient(90deg, var(--accent), #57b87e); }
.ga-bar-fill.neg { background: linear-gradient(90deg, #d98a8a, var(--warn)); }
.ga-bar-val { flex: 0 0 56px; text-align: right; font-weight: 600; color: var(--accent-d); }
/* ── Trait selector helpers ─────────────────────────────────────────────── */
.trait-count { font-size: 11px; font-weight: 700; color: var(--accent); background: var(--accent-soft); padding: 1px 7px; border-radius: 20px; }
.trait-help { font-size: 11px; color: var(--muted); margin: 4px 0 8px; }
/* ── View toggle (Simple / Expert) ──────────────────────────────────────── */
.view-toggle { display: flex; align-items: center; gap: 8px; margin-bottom: 16px; flex-wrap: wrap; }
.vt-label { font-size: 12px; font-weight: 700; color: var(--muted); text-transform: uppercase; letter-spacing: .04em; }
.vt { border: 1px solid var(--line); background: #fff; color: var(--ink); padding: 6px 16px; border-radius: 8px; font-size: 13px; font-weight: 600; cursor: pointer; }
.vt.active { background: var(--accent); color: #fff; border-color: var(--accent); }
.view-hint { font-size: 11px; }
#result:not(.expert) .rsec[data-tier="advanced"] { display: none; }
.rsec { scroll-margin-top: 12px; }
/* ── Report card ────────────────────────────────────────────────────────── */
.report-card { border: 1px solid var(--line); border-radius: var(--radius); background: #fff; box-shadow: var(--shadow); padding: 16px 18px; margin-bottom: 18px; }
.rc-head { display: flex; align-items: center; gap: 16px; margin-bottom: 12px; }
.rc-grade { display: flex; flex-direction: column; align-items: center; justify-content: center; min-width: 110px; padding: 10px 14px; border-radius: 10px; }
.rc-grade.good { background: var(--accent-soft); color: var(--accent-d); }
.rc-grade.warn { background: #fbe8e8; color: var(--warn); }
.rc-grade-word { font-size: 20px; font-weight: 800; line-height: 1.1; }
.rc-grade-score { font-size: 12px; font-weight: 600; opacity: .8; }
.rc-title { display: flex; flex-direction: column; gap: 2px; }
.rc-title strong { font-size: 15px; }
.rc-items { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 8px; }
.rc-item { display: flex; align-items: baseline; gap: 8px; padding: 8px 10px; border-radius: 8px; background: #f7faf8; font-size: 12px; }
.rc-dot { font-weight: 800; }
.rc-dot.good { color: var(--accent); }
.rc-dot.warn { color: var(--warn); }
.rc-label { font-weight: 700; flex: 0 0 auto; }
.rc-note { color: var(--muted); }
/* ── Per-panel verdict bar ──────────────────────────────────────────────── */
.verdict { display: flex; align-items: center; gap: 8px; margin: 0 0 10px; font-size: 12.5px; }
.verdict-text { color: var(--ink); }