The user wants me to build a genomic secondary findings patient portal experience. This is a healthcare/genomics web application that should include:
- Tailored education about genomic secondary findings
- Consent updates functionality
- Care pathways visualization
This is a serious medical/healthcare application, so I need to design it with:
- Professional, trustworthy appearance
- Clear information hierarchy
- Accessible design
- Interactive elements for engagement
- Proper medical data representation
Key features to include:
- Dashboard/Overview section
- Educational modules about secondary findings
- Consent management system
- Care pathway visualization
- Genetic results display (mock data)
- Action items and recommendations
Design approach:
- Clean, medical-grade aesthetic
- Soft, calming colors (blues, teals, whites)
- Clear typography for readability
- Interactive cards and progress indicators
- DNA/genomics visual elements (animated)
Technical implementation:
- Vue.js or vanilla JS for interactivity
- CSS animations for DNA helix effects
- Responsive design
- Tab-based navigation
- Modal dialogs for consent forms
- Progress tracking
Let me create a comprehensive, professional portal with:
- Animated DNA background
- Patient dashboard
- Educational content cards
- Consent workflow
- Care pathway timeline
- Results summary
I'll use a sophisticated color palette:
- Primary: Deep teal/blue
- Secondary: Coral/orange for accents
- Background: Light gray with subtle patterns
- Text: Dark slate for readability
Fonts:
- Display: "DM Serif Display" for headings
- Body: "Source Sans Pro" for readability
Genomic Secondary Findings Patient Portal
This is a comprehensive patient portal for managing genomic secondary findings with interactive education modules, consent management, and personalized care pathways.
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>GenomeCare | Secondary Findings Portal</title>
<script src="https://cdn.tailwindcss.com"></script>
<link rel="preconnect" href="https://fonts.googleapis.com">
<link rel="preconnect" href="https://fonts.gstatic.com" crossorigin>
<link href="https://fonts.googleapis.com/css2?family=DM+Serif+Display&family=IBM+Plex+Sans:wght@300;400;500;600;700&display=swap" rel="stylesheet">
<style>
:root {
--bg: #f8fafb;
--bg-dark: #0f172a;
--fg: #1e293b;
--fg-dark: #f1f5f9;
--muted: #64748b;
--muted-dark: #94a3b8;
--accent: #0891b2;
--accent-warm: #f97316;
--card: #ffffff;
--card-dark: #1e293b;
--border: #e2e8f0;
--border-dark: #334155;
--success: #10b981;
--warning: #f59e0b;
--danger: #ef4444;
}
[data-theme="dark"] {
--bg: var(--bg-dark);
--fg: var(--fg-dark);
--muted: var(--muted-dark);
--card: var(--card-dark);
--border: var(--border-dark);
}
* {
margin: 0;
padding: 0;
box-sizing: border-box;
}
body {
font-family: 'IBM Plex Sans', sans-serif;
background: var(--bg);
color: var(--fg);
min-height: 100vh;
transition: background 0.3s ease, color 0.3s ease;
}
h1, h2, h3, h4 {
font-family: 'DM Serif Display', serif;
}
/* DNA Helix Animation */
.dna-container {
position: fixed;
right: -100px;
top: 0;
width: 300px;
height: 100%;
opacity: 0.06;
pointer-events: none;
z-index: 0;
}
.dna-strand {
position: absolute;
width: 100%;
height: 200%;
animation: dnaFlow 20s linear infinite;
}
@keyframes dnaFlow {
from { transform: translateY(-50%); }
to { transform: translateY(0); }
}
.dna-node {
position: absolute;
width: 12px;
height: 12px;
border-radius: 50%;
background: var(--accent);
}
.dna-connector {
position: absolute;
height: 2px;
background: linear-gradient(90deg, var(--accent), var(--accent-warm), var(--accent));
transform-origin: center;
}
/* Sidebar */
.sidebar {
width: 280px;
background: var(--card);
border-right: 1px solid var(--border);
height: 100vh;
position: fixed;
left: 0;
top: 0;
z-index: 50;
display: flex;
flex-direction: column;
transition: transform 0.3s ease;
}
@media (max-width: 1024px) {
.sidebar {
transform: translateX(-100%);
}
.sidebar.open {
transform: translateX(0);
}
.main-content {
margin-left: 0 !important;
}
}
.nav-item {
display: flex;
align-items: center;
gap: 12px;
padding: 14px 20px;
color: var(--muted);
text-decoration: none;
transition: all 0.2s ease;
border-left: 3px solid transparent;
cursor: pointer;
}
.nav-item:hover, .nav-item.active {
background: rgba(8, 145, 178, 0.08);
color: var(--accent);
border-left-color: var(--accent);
}
.nav-item.active {
font-weight: 600;
}
/* Cards */
.card {
background: var(--card);
border: 1px solid var(--border);
border-radius: 16px;
padding: 24px;
transition: all 0.3s ease;
}
.card:hover {
box-shadow: 0 8px 30px rgba(0, 0, 0, 0.08);
transform: translateY(-2px);
}
/* Progress Ring */
.progress-ring {
transform: rotate(-90deg);
}
.progress-ring-circle {
transition: stroke-dashoffset 0.5s ease;
}
/* Buttons */
.btn {
display: inline-flex;
align-items: center;
justify-content: center;
gap: 8px;
padding: 12px 24px;
border-radius: 10px;
font-weight: 600;
cursor: pointer;
transition: all 0.2s ease;
border: none;
font-size: 14px;
}
.btn-primary {
background: var(--accent);
color: white;
}
.btn-primary:hover {
background: #0e7490;
transform: translateY(-1px);
}
.btn-secondary {
background: transparent;
color: var(--fg);
border: 1px solid var(--border);
}
.btn-secondary:hover {
border-color: var(--accent);
color: var(--accent);
}
.btn:focus-visible {
outline: 2px solid var(--accent);
outline-offset: 2px;
}
/* Tabs */
.tab-btn {
padding: 12px 24px;
background: transparent;
border: none;
color: var(--muted);
font-weight: 500;
cursor: pointer;
position: relative;
transition: color 0.2s ease;
}
.tab-btn::after {
content: '';
position: absolute;
bottom: 0;
left: 50%;
transform: translateX(-50%);
width: 0;
height: 2px;
background: var(--accent);
transition: width 0.3s ease;
}
.tab-btn.active {
color: var(--accent);
}
.tab-btn.active::after {
width: 80%;
}
.tab-btn:hover {
color: var(--accent);
}
/* Care Pathway Timeline */
.timeline {
position: relative;
padding-left: 32px;
}
.timeline::before {
content: '';
position: absolute;
left: 8px;
top: 0;
bottom: 0;
width: 2px;
background: var(--border);
}
.timeline-item {
position: relative;
padding-bottom: 32px;
opacity: 0;
transform: translateX(-20px);
animation: slideIn 0.5s ease forwards;
}
.timeline-item::before {
content: '';
position: absolute;
left: -28px;
top: 4px;
width: 14px;
height: 14px;
border-radius: 50%;
background: var(--card);
border: 3px solid var(--accent);
}
.timeline-item.completed::before {
background: var(--success);
border-color: var(--success);
}
.timeline-item.current::before {
background: var(--accent-warm);
border-color: var(--accent-warm);
animation: pulse 2s infinite;
}
@keyframes pulse {
0%, 100% { box-shadow: 0 0 0 0 rgba(249, 115, 22, 0.4); }
50% { box-shadow: 0 0 0 8px rgba(249, 115, 22, 0); }
}
@keyframes slideIn {
to {
opacity: 1;
transform: translateX(0);
}
}
/* Gene Badge */
.gene-badge {
display: inline-flex;
align-items: center;
gap: 6px;
padding: 6px 12px;
border-radius: 20px;
font-size: 12px;
font-weight: 600;
font-family: 'IBM Plex Mono', monospace;
}
.gene-badge.pathogenic {
background: rgba(239, 68, 68, 0.1);
color: #dc2626;
border: 1px solid rgba(239, 68, 68, 0.2);
}
.gene-badge.vus {
background: rgba(245, 158, 11, 0.1);
color: #d97706;
border: 1px solid rgba(245, 158, 11, 0.2);
}
.gene-badge.benign {
background: rgba(16, 185, 129, 0.1);
color: #059669;
border: 1px solid rgba(16, 185, 129, 0.2);
}
/* Modal */
.modal-overlay {
position: fixed;
inset: 0;
background: rgba(0, 0, 0, 0.5);
backdrop-filter: blur(4px);
z-index: 100;
opacity: 0;
visibility: hidden;
transition: all 0.3s ease;
}
.modal-overlay.active {
opacity: 1;
visibility: visible;
}
.modal {
position: fixed;
top: 50%;
left: 50%;
transform: translate(-50%, -50%) scale(0.95);
background: var(--card);
border-radius: 20px;
max-width: 600px;
width: 90%;
max-height: 90vh;
overflow-y: auto;
z-index: 101;
opacity: 0;
visibility: hidden;
transition: all 0.3s ease;
}
.modal.active {
opacity: 1;
visibility: visible;
transform: translate(-50%, -50%) scale(1);
}
/* Checkbox Custom */
.checkbox-custom {
display: flex;
align-items: flex-start;
gap: 12px;
cursor: pointer;
padding: 16px;
border-radius: 12px;
border: 1px solid var(--border);
transition: all 0.2s ease;
}
.checkbox-custom:hover {
border-color: var(--accent);
background: rgba(8, 145, 178, 0.04);
}
.checkbox-custom input {
width: 20px;
height: 20px;
accent-color: var(--accent);
margin-top: 2px;
}
/* Scroll reveal */
.reveal {
opacity: 0;
transform: translateY(20px);
transition: all 0.6s ease;
}
.reveal.visible {
opacity: 1;
transform: translateY(0);
}
@media (prefers-reduced-motion: reduce) {
*, *::before, *::after {
animation-duration: 0.01ms !important;
animation-iteration-count: 1 !important;
transition-duration: 0.01ms !important;
}
}
/* Mobile nav toggle */
.mobile-nav-toggle {
display: none;
position: fixed;
top: 16px;
left: 16px;
z-index: 60;
background: var(--card);
border: 1px solid var(--border);
border-radius: 10px;
padding: 10px;
cursor: pointer;
}
@media (max-width: 1024px) {
.mobile-nav-toggle {
display: flex;
}
}
.overlay-backdrop {
display: none;
position: fixed;
inset: 0;
background: rgba(0, 0, 0, 0.3);
z-index: 40;
}
@media (max-width: 1024px) {
.overlay-backdrop.active {
display: block;
}
}
/* Educational accordion */
.accordion-item {
border: 1px solid var(--border);
border-radius: 12px;
margin-bottom: 12px;
overflow: hidden;
}
.accordion-header {
width: 100%;
padding: 16px 20px;
display: flex;
justify-content: space-between;
align-items: center;
background: var(--card);
border: none;
cursor: pointer;
text-align: left;
font-weight: 500;
color: var(--fg);
transition: background 0.2s ease;
}
.accordion-header:hover {
background: rgba(8, 145, 178, 0.04);
}
.accordion-content {
max-height: 0;
overflow: hidden;
transition: max-height 0.3s ease;
background: rgba(8, 145, 178, 0.02);
}
.accordion-content.open {
max-height: 500px;
}
.accordion-body {
padding: 16px 20px;
color: var(--muted);
line-height: 1.7;
}
.chevron-icon {
transition: transform 0.3s ease;
}
.accordion-header.open .chevron-icon {
transform: rotate(180deg);
}
</style>
</head>
<body>
<!-- DNA Background Animation -->
<div class="dna-container" aria-hidden="true">
<div class="dna-strand" id="dna-strand"></div>
</div>
<!-- Mobile Nav Toggle -->
<button class="mobile-nav-toggle" onclick="toggleSidebar()" aria-label="Toggle navigation">
<svg width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2">
<path d="M3 12h18M3 6h18M3 18h18"/>
</svg>
</button>
<!-- Overlay Backdrop -->
<div class="overlay-backdrop" id="overlay-backdrop" onclick="toggleSidebar()"></div>
<!-- Sidebar -->
<aside class="sidebar" id="sidebar" role="navigation" aria-label="Main navigation">
<div class="p-6 border-b border-[var(--border)]">
<div class="flex items-center gap-3">
<div class="w-10 h-10 rounded-xl bg-gradient-to-br from-[var(--accent)] to-[var(--accent-warm)] flex items-center justify-center">
<svg width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="white" stroke-width="2">
<path d="M12 2v20M2 12h20M4.93 4.93l14.14 14.14M19.07 4.93L4.93 19.07"/>
</svg>
</div>
<div>
<h1 class="text-lg font-semibold">GenomeCare</h1>
<p class="text-xs text-[var(--muted)]">Patient Portal</p>
</div>
</div>
</div>
<nav class="flex-1 py-4">
<div class="px-4 mb-2">
<span class="text-xs font-semibold text-[var(--muted)] uppercase tracking-wider">Main</span>
</div>
<a class="nav-item active" data-section="dashboard">
<svg width="20" height="20" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2">
<rect x="3" y="3" width="7" height="7" rx="1"/>
<rect x="14" y="3" width="7" height="7" rx="1"/>
<rect x="3" y="14" width="7" height="7" rx="1"/>
<rect x="14" y="14" width="7" height="7" rx="1"/>
</svg>
Dashboard
</a>
<a class="nav-item" data-section="findings">
<svg width="20" height="20" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2">
<path d="M9 3H5a2 2 0 0 0-2 2v4m6-6h10a2 2 0 0 1 2 2v4M9 3v18m0 0h10a2 2 0 0 0 2-2V9M9 21H5a2 2 0 0 1-2-2V9m0 0h18"/>
</svg>
My Findings
</a>
<a class="nav-item" data-section="education">
<svg width="20" height="20" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2">
<path d="M2 3h6a4 4 0 0 1 4 4v14a3 3 0 0 0-3-3H2z"/>
<path d="M22 3h-6a4 4 0 0 0-4 4v14a3 3 0 0 1 3-3h7z"/>
</svg>
Education
</a>
<a class="nav-item" data-section="consent">
<svg width="20" height="20" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2">
<path d="M14 2H6a2 2 0 0 0-2 2v16a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2V8z"/>
<polyline points="14,2 14,8 20,8"/>
<path d="M9 15l2 2 4-4"/>
</svg>
Consent
</a>
<a class="nav-item" data-section="pathway">
<svg width="20" height="20" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2">
<circle cx="12" cy="12" r="10"/>
<polyline points="12,6 12,12 16,14"/>
</svg>
Care Pathway
</a>
<div class="px-4 mt-6 mb-2">
<span class="text-xs font-semibold text-[var(--muted)] uppercase tracking-wider">Support</span>
</div>
<a class="nav-item" data-section="resources">
<svg width="20" height="20" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2">
<circle cx="12" cy="12" r="10"/>
<path d="M9.09 9a3 3 0 0 1 5.83 1c0 2-3 3-3 3"/>
<line x1="12" y1="17" x2="12.01" y2="17"/>
</svg>
Resources
</a>
<a class="nav-item" onclick="toggleTheme()">
<svg width="20" height="20" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" id="theme-icon">
<circle cx="12" cy="12" r="5"/>
<line x1="12" y1="1" x2="12" y2="3"/>
<line x1="12" y1="21" x2="12" y2="23"/>
<line x1="4.22" y1="4.22" x2="5.64" y2="5.64"/>
<line x1="18.36" y1="18.36" x2="19.78" y2="19.78"/>
<line x1="1" y1="12" x2="3" y2="12"/>
<line x1="21" y1="12" x2="23" y2="12"/>
<line x1="4.22" y1="19.78" x2="5.64" y2="18.36"/>
<line x1="18.36" y1="5.64" x2="19.78" y2="4.22"/>
</svg>
Dark Mode
</a>
</nav>
<!-- User Profile -->
<div class="p-4 border-t border-[var(--border)]">
<div class="flex items-center gap-3">
<div class="w-10 h-10 rounded-full bg-gradient-to-br from-cyan-400 to-teal-500 flex items-center justify-center text-white font-semibold">
SJ
</div>
<div class="flex-1 min-w-0">
<p class="font-medium text-sm truncate">Sarah Johnson</p>
<p class="text-xs text-[var(--muted)] truncate">MRN: 8472916</p>
</div>
</div>
</div>
</aside>
<!-- Main Content -->
<main class="main-content ml-[280px] min-h-screen p-8 relative z-10" id="main-content">
<!-- Dashboard Section -->
<section id="section-dashboard" class="section-content">
<div class="mb-8 reveal">
<h2 class="text-3xl mb-2">Welcome back, Sarah</h2>
<p class="text-[var(--muted)]">Your genomic health journey at a glance</p>
</div>
<!-- Status Cards -->
<div class="grid grid-cols-1 md:grid-cols-3 gap-6 mb-8">
<div class="card reveal" style="animation-delay: 0.1s">
<div class="flex items-start justify-between mb-4">
<div>
<p class="text-sm text-[var(--muted)] mb-1">Secondary Findings</p>
<p class="text-3xl font-bold text-[var(--accent)]">2</p>
</div>
<div class="w-12 h-12 rounded-xl bg-gradient-to-br from-cyan-500/10 to-teal-500/10 flex items-center justify-center">
<svg width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="var(--accent)" stroke-width="2">
<path d="M12 2v20M2 12h20"/>
</svg>
</div>
</div>
<div class="flex items-center gap-2">
<span class="gene-badge pathogenic">1 Pathogenic</span>
<span class="gene-badge vus">1 VUS</span>
</div>
</div>
<div class="card reveal" style="animation-delay: 0.2s">
<div class="flex items-start justify-between mb-4">
<div>
<p class="text-sm text-[var(--muted)] mb-1">Education Progress</p>
<p class="text-3xl font-bold text-[var(--success)]">75%</p>
</div>
<svg class="progress-ring" width="56" height="56" viewBox="0 0 56 56">
<circle cx="28" cy="28" r="24" fill="none" stroke="var(--border)" stroke-width="4"/>
<circle class="progress-ring-circle" cx="28" cy="28" r="24" fill="none" stroke="var(--success)" stroke-width="4"
stroke-dasharray="150.8" stroke-dashoffset="37.7" stroke-linecap="round"/>
</svg>
</div>
<p class="text-sm text-[var(--muted)]">3 of 4 modules completed</p>
</div>
<div class="card reveal" style="animation-delay: 0.3s">
<div class="flex items-start justify-between mb-4">
<div>
<p class="text-sm text-[var(--muted)] mb-1">Care Pathway</p>
<p class="text-3xl font-bold text-[var(--accent-warm)]">Active</p>
</div>
<div class="w-12 h-12 rounded-xl bg-gradient-to-br from-orange-500/10 to-amber-500/10 flex items-center justify-center">
<svg width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="var(--accent-warm)" stroke-width="2">
<path d="M22 11.08V12a10 10 0 1 1-5.93-9.14"/>
<polyline points="22,4 12,14.01 9,11.01"/>
</svg>
</div>
</div>
<p class="text-sm text-[var(--muted)]">Next: Cardiology referral</p>
</div>
</div>
<!-- Action Required -->
<div class="card mb-8 reveal" style="animation-delay: 0.4s">
<div class="flex items-start gap-4 p-4 bg-gradient-to-r from-amber-50 to-orange-50 dark:from-amber-950/30 dark:to-orange-950/30 rounded-xl border border-amber-200 dark:border-amber-800">
<div class="w-10 h-10 rounded-full bg-amber-500 flex items-center justify-center flex-shrink-0">
<svg width="20" height="20" viewBox="0 0 24 24" fill="none" stroke="white" stroke-width="2">
<path d="M10.29 3.86L1.82 18a2 2 0 0 0 1.71 3h16.94a2 2 0 0 0 1.71-3L13.71 3.86a2 2 0 0 0-3.42 0z"/>
<line x1="12" y1="9" x2="12" y2="13"/>
<line x1="12" y1="17" x2="12.01" y2="17"/>
</svg>
</div>
<div class="flex-1">
<h4 class="font-semibold mb-1">Consent Update Required</h4>
<p class="text-sm text-[var(--muted)] mb-3">New secondary findings categories are available. Please review and update your consent preferences.</p>
<button class="btn btn-primary text-sm" onclick="openConsentModal()">
Review Consent Options
</button>
</div>
</div>
</div>
<!-- Recent Activity -->
<div class="card reveal" style="animation-delay: 0.5s">
<h3 class="text-xl mb-4">Recent Activity</h3>
<div class="space-y-4">
<div class="flex items-center gap-4 p-3 rounded-lg hover:bg-[var(--bg)] transition-colors">
<div class="w-2 h-2 rounded-full bg-[var(--success)]"></div>
<div class="flex-1">
<p class="text-sm font-medium">Education module completed</p>
<p class="text-xs text-[var(--muted)]">Understanding Hereditary Cancer Risk</p>
</div>
<span class="text-xs text-[var(--muted)]">2 days ago</span>
</div>
<div class="flex items-center gap-4 p-3 rounded-lg hover:bg-[var(--bg)] transition-colors">
<div class="w-2 h-2 rounded-full bg-[var(--accent)]"></div>
<div class="flex-1">
<p class="text-sm font-medium">New secondary finding reported</p>
<p class="text-xs text-[var(--muted)]">BRCA1 variant identified</p>
</div>
<span class="text-xs text-[var(--muted)]">1 week ago</span>
</div>
<div class="flex items-center gap-4 p-3 rounded-lg hover:bg-[var(--bg)] transition-colors">
<div class="w-2 h-2 rounded-full bg-[var(--accent-warm)]"></div>
<div class="flex-1">
<p class="text-sm font-medium">Care pathway updated</p>
<p class="text-xs text-[var(--muted)]">Genetic counseling scheduled</p>
</div>
<span class="text-xs text-[var(--muted)]">2 weeks ago</span>
</div>
</div>
</div>
</section>
<!-- Findings Section -->
<section id="section-findings" class="section-content hidden">
<div class="mb-8 reveal">
<h2 class="text-3xl mb-2">My Secondary Findings</h2>
<p class="text-[var(--muted)]">Genomic variants identified beyond your primary test indication</p>
</div>
<!-- Filters -->
<div class="flex flex-wrap gap-3 mb-6 reveal">
<button class="btn btn-secondary text-sm" data-filter="all">All Findings</button>
<button class="btn btn-secondary text-sm" data-filter="pathogenic">Pathogenic</button>
<button class="btn btn-secondary text-sm" data-filter="vus">Variant of Uncertain Significance</button>
<button class="btn btn-secondary text-sm" data-filter="benign">Benign</button>
</div>
<!-- Findings Cards -->
<div class="space-y-4" id="findings-list">
<!-- BRCA1 Finding -->
<div class="card reveal finding-card" data-category="pathogenic" style="animation-delay: 0.1s">
<div class="flex flex-wrap items-start justify-between gap-4 mb-4">
<div class="flex items-center gap-3">
<span class="gene-badge pathogenic">Pathogenic</span>
<h4 class="text-xl font-semibold">BRCA1</h4>
</div>
<span class="text-sm text-[var(--muted)]">Found: Jan 15, 2025</span>
</div>
<div class="grid md:grid-cols-2 gap-6">
<div>
<h5 class="font-medium mb-2">Variant Details</h5>
<div class="space-y-2 text-sm">
<div class="flex justify-between">
<span class="text-[var(--muted)]">HGVS:</span>
<span class="font-mono">c.68_69delAG (p.Glu23Valfs*17)</span>
</div>
<div class="flex justify-between">
<span class="text-[var(--muted)]">Classification:</span>
<span class="text-red-600 font-medium">Pathogenic</span>
</div>
<div class="flex justify-between">
<span class="text-[var(--muted)]">ClinVar ID:</span>
<span class="font-mono">SCV000123456</span>
</div>
</div>
</div>
<div>
<h5 class="font-medium mb-2">Associated Conditions</h5>
<ul class="text-sm space-y-1 text-[var(--muted)]">
<li>Hereditary breast and ovarian cancer (HBOC)</li>
<li>Increased risk: Breast cancer (up to 72%)</li>
<li>Increased risk: Ovarian cancer (up to 44%)</li>
</ul>
</div>
</div>
<div class="mt-4 pt-4 border-t border-[var(--border)] flex flex-wrap gap-3">
<button class="btn btn-primary text-sm" onclick="openConsentModal()">
Update Consent Preferences
</button>
<button class="btn btn-secondary text-sm">
Download Report
</button>
<button class="btn btn-secondary text-sm" onclick="navigateTo('pathway')">
View Care Pathway
</button>
</div>
</div>
<!-- MYH7 Finding -->
<div class="card reveal finding-card" data-category="vus" style="animation-delay: 0.2s">
<div class="flex flex-wrap items-start justify-between gap-4 mb-4">
<div class="flex items-center gap-3">
<span class="gene-badge vus">VUS</span>
<h4 class="text-xl font-semibold">MYH7</h4>
</div>
<span class="text-sm text-[var(--muted)]">Found: Jan 15, 2025</span>
</div>
<div class="grid md:grid-cols-2 gap-6">
<div>
<h5 class="font-medium mb-2">Variant Details</h5>
<div class="space-y-2 text-sm">
<div class="flex justify-between">
<span class="text-[var(--muted)]">HGVS:</span>
<span class="font-mono">c.2167G>A (p.Ala723Thr)</span>
</div>
<div class="flex justify-between">
<span class="text-[var(--muted)]">Classification:</span>
<span class="text-amber-600 font-medium">Uncertain Significance</span>
</div>
<div class="flex justify-between">
<span class="text-[var(--muted)]">ClinVar ID:</span>
<span class="font-mono">SCV000789012</span>
</div>
</div>
</div>
<div>
<h5 class="font-medium mb-2">Associated Conditions</h5>
<ul class="text-sm space-y-1 text-[var(--muted)]">
<li>Hypertrophic cardiomyopathy (possible)</li>
<li>Dilated cardiomyopathy (possible)</li>
<li>Further evaluation recommended</li>
</ul>
</div>
</div>
<div class="mt-4 pt-4 border-t border-[var(--border)] flex flex-wrap gap-3">
<button class="btn btn-secondary text-sm">
Learn About VUS
</button>
<button class="btn btn-secondary text-sm">
Request Reanalysis
</button>
</div>
</div>
</div>
</section>
<!-- Education Section -->
<section id="section-education" class="section-content hidden">
<div class="mb-8 reveal">
<h2 class="text-3xl mb-2">Genomics Education</h2>
<p class="text-[var(--muted)]">Learn about secondary findings and what they mean for your health</p>
</div>
<!-- Progress Overview -->
<div class="card mb-8 reveal">
<div class="flex items-center gap-6">
<svg class="progress-ring" width="80" height="80" viewBox="0 0 80 80">
<circle cx="40" cy="40" r="32" fill="none" stroke="var(--border)" stroke-width="6"/>
<circle class="progress-ring-circle" cx="40" cy="40" r="32" fill="none" stroke="var(--success)" stroke-width="6"
stroke-dasharray="201" stroke-dashoffset="50.25" stroke-linecap="round"/>
</svg>
<div>
<h4 class="text-xl font-semibold mb-1">Your Progress</h4>
<p class="text-[var(--muted)]">3 of 4 modules completed</p>
</div>
</div>
</div>
<!-- Modules -->
<div class="space-y-4">
<div class="accordion-item reveal" style="animation-delay: 0.1s">
<button class="accordion-header" onclick="toggleAccordion(this)">
<div class="flex items-center gap-3">
<div class="w-8 h-8 rounded-full bg-[var(--success)] flex items-center justify-center text-white text-sm font-bold">✓</div>
<span>What Are Secondary Findings?</span>
</div>
<svg class="chevron-icon" width="20" height="20" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2">
<polyline points="6,9 12,15 18,9"/>
</svg>
</button>
<div class="accordion-content">
<div class="accordion-body">
<p>Secondary findings are genetic results discovered during genomic testing that are unrelated to the primary reason for testing. These findings may have important health implications for you or your family members.</p>
<br>
<p>The American College of Medical Genetics (ACMG) has identified a list of genes where finding a variant could impact your medical care, even if you didn't originally sign up to learn about those conditions.</p>
</div>
</div>
</div>
<div class="accordion-item reveal" style="animation-delay: 0.15s">
<button class="accordion-header" onclick="toggleAccordion(this)">
<div class="flex items-center gap-3">
<div class="w-8 h-8 rounded-full bg-[var(--success)] flex items-center justify-center text-white text-sm font-bold">✓</div>
<span>Understanding Hereditary Cancer Risk</span>
</div>
<svg class="chevron-icon" width="20" height="20" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2">
<polyline points="6,9 12,15 18,9"/>
</svg>
</button>
<div class="accordion-content">
<div class="accordion-body">
<p>Some genes, like BRCA1 and BRCA2, are known to significantly increase the risk of certain cancers when they contain harmful variants. Understanding your genetic risk allows for proactive screening and prevention strategies.</p>
<br>
<p><strong>Key Points:</strong></p>
<ul class="list-disc ml-5 mt-2 space-y-1">
<li>Not everyone with a pathogenic variant will develop cancer</li>
<li>Enhanced screening can detect cancer earlier</li>
<li>Preventive options are available</li>
<li>Family members may also be affected</li>
</ul>
</div>
</div>
</div>
<div class="accordion-item reveal" style="animation-delay: 0.2s">
<button class="accordion-header" onclick="toggleAccordion(this)">
<div class="flex items-center gap-3">
<div class="w-8 h-8 rounded-full bg-[var(--success)] flex items-center justify-center text-white text-sm font-bold">✓</div>
<span>Cardiovascular Genetic Conditions</span>
</div>
<svg class="chevron-icon" width="20" height="20" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2">
<polyline points="6,9 12,15 18,9"/>
</svg>
</button>
<div class="accordion-content">
<div class="accordion-body">
<p>Genetic variants in certain genes can affect heart health, including conditions like hypertrophic cardiomyopathy, long QT syndrome, and familial hypercholesterolemia.</p>
<br>
<p>Early identification of these variants enables cardiac monitoring, lifestyle modifications, and potentially life-saving interventions.</p>
</div>
</div>
</div>
<div class="accordion-item reveal" style="animation-delay: 0.25s">
<button class="accordion-header" onclick="toggleAccordion(this)">
<div class="flex items-center gap-3">
<div class="w-8 h-8 rounded-full bg-[var(--accent-warm)] flex items-center justify-center text-white text-sm font-bold">4</div>
<span>Making Informed Consent Decisions</span>
</div>
<svg class="chevron-icon" width="20" height="20" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2">
<polyline points="6,9 12,15 18,9"/>
</svg>
</button>
<div class="accordion-content">
<div class="accordion-body">
<p>You have control over which types of secondary findings you want to receive. Your consent preferences can be updated at any time as your understanding and circumstances change.</p>
<br>
<p><strong>Consider when making your decision:</strong></p>
<ul class="list-disc ml-5 mt-2 space-y-1">
<li>Your personal health goals and values</li>
<li>Family planning considerations</li>
<li>Psychological readiness for results</li>
<li>Availability of medical interventions</li>
</ul>
<div class="mt-4">
<button class="btn btn-primary text-sm" onclick="openConsentModal()">Update Consent Preferences</button>
</div>
</div>
</div>
</div>
</div>
</section>
<!-- Consent Section -->
<section id="section-consent" class="section-content hidden">
<div class="mb-8 reveal">
<h2 class="text-3xl mb-2">Consent Management</h2>
<p class="text-[var(--muted)]">Control what genomic information you receive and how it's used</p>
</div>
<!-- Current Status -->
<div class="card mb-6 reveal">
<h4 class="font-semibold mb-4">Current Consent Status</h4>
<div class="grid md:grid-cols-3 gap-4">
<div class="p-4 bg-green-50 dark:bg-green-950/30 rounded-xl border border-green-200 dark:border-green-800">
<div class="flex items-center gap-2 mb-2">
<svg width="20" height="20" viewBox="0 0 24 24" fill="none" stroke="var(--success)" stroke-width="2">
<polyline points="20,6 9,17 4,12"/>
</svg>
<span class="font-medium text-green-700 dark:text-green-400">Active</span>
</div>
<p class="text-sm text-[var(--muted)]">Primary test results</p>
</div>
<div class="p-4 bg-green-50 dark:bg-green-950/30 rounded-xl border border-green-200 dark:border-green-800">
<div class="flex items-center gap-2 mb-2">
<svg width="20" height="20" viewBox="0 0 24 24" fill="none" stroke="var(--success)" stroke-width="2">
<polyline points="20,6 9,17 4,12"/>
</svg>
<span class="font-medium text-green-700 dark:text-green-400">Active</span>
</div>
<p class="text-sm text-[var(--muted)]">ACMG SF v3.1 categories</p>
</div>
<div class="p-4 bg-amber-50 dark:bg-amber-950/30 rounded-xl border border-amber-200 dark:border-amber-800">
<div class="flex items-center gap-2 mb-2">
<svg width="20" height="20" viewBox="0 0 24 24" fill="none" stroke="var(--warning)" stroke-width="2">
<circle cx="12" cy="12" r="10"/>
<line x1="12" y1="8" x2="12" y2="12"/>
<line x1="12" y1="16" x2="12.01" y2="16"/>
</svg>
<span class="font-medium text-amber-700 dark:text-amber-400">Pending</span>
</div>
<p class="text-sm text-[var(--muted)]">Pharmacogenomic results</p>
</div>
</div>
</div>
<!-- Consent History -->
<div class="card mb-6 reveal">
<h4 class="font-semibold mb-4">Consent History</h4>
<div class="space-y-3">
<div class="flex items-center gap-4 p-3 rounded-lg bg-[var(--bg)]">
<div class="w-10 h-10 rounded-full bg-[var(--success)]/20 flex items-center justify-center">
<svg width="18" height="18" viewBox="0 0 24 24" fill="none" stroke="var(--success)" stroke-width="2">
<polyline points="20,6 9,17 4,12"/>
</svg>
</div>
<div class="flex-1">
<p class="text-sm font-medium">Consent updated for ACMG categories</p>
<p class="text-xs text-[var(--muted)]">Added: BRCA1/2, LDLR, MYH7</p>
</div>
<span class="text-xs text-[var(--muted)]">Jan 10, 2025</span>
</div>
<div class="flex items-center gap-4 p-3 rounded-lg bg-[var(--bg)]">
<div class="w-10 h-10 rounded-full bg-[var(--success)]/20 flex items-center justify-center">
<svg width="18" height="18" viewBox="0 0 24 24" fill="none" stroke="var(--success)" stroke-width="2">
<polyline points="20,6 9,17 4,12"/>
</svg>
</div>
<div class="flex-1">
<p class="text-sm font-medium">Initial consent provided</p>
<p class="text-xs text-[var(--muted)]">Primary testing consent</p>
</div>
<span class="text-xs text-[var(--muted)]">Dec 5, 2024</span>
</div>
</div>
</div>
<button class="btn btn-primary reveal" onclick="openConsentModal()">
Update Consent Preferences
</button>
</section>
<!-- Care Pathway Section -->
<section id="section-pathway" class="section-content hidden">
<div class="mb-8 reveal">
<h2 class="text-3xl mb-2">Your Care Pathway</h2>
<p class="text-[var(--muted)]">Personalized next steps based on your genomic findings</p>
</div>
<div class="grid lg:grid-cols-3 gap-6">
<!-- Timeline -->
<div class="lg:col-span-2">
<div class="card reveal">
<h4 class="font-semibold mb-6">Care Journey Timeline</h4>
<div class="timeline">
<div class="timeline-item completed" style="animation-delay: 0.1s">
<div class="flex justify-between items-start mb-2">
<h5 class="font-medium">Genetic Test Ordered</h5>
<span class="text-xs text-[var(--muted)]">Dec 5, 2024</span>
</div>
<p class="text-sm text-[var(--muted)]">Comprehensive genomic panel ordered by Dr. Emily Chen</p>
</div>
<div class="timeline-item completed" style="animation-delay: 0.2s">
<div class="flex justify-between items-start mb-2">
<h5 class="font-medium">Sample Collected</h5>
<span class="text-xs text-[var(--muted)]">Dec 8, 2024</span>
</div>
<p class="text-sm text-[var(--muted)]">Blood sample collected at GenomeCare Lab Services</p>
</div>
<div class="timeline-item completed" style="animation-delay: 0.3s">
<div class="flex justify-between items-start mb-2">
<h5 class="font-medium">Results Received</h5>
<span class="text-xs text-[var(--muted)]">Jan 15, 2025</span>
</div>
<p class="text-sm text-[var(--muted)]">Secondary findings identified: BRCA1 pathogenic variant, MYH7 VUS</p>
</div>
<div class="timeline-item completed" style="animation-delay: 0.4s">
<div class="flex justify-between items-start mb-2">
<h5 class="font-medium">Genetic Counseling Session</h5>
<span class="text-xs text-[var(--muted)]">Jan 22, 2025</span>
</div>
<p class="text-sm text-[var(--muted)]">Discussed findings implications with certified genetic counselor</p>
</div>
<div class="timeline-item current" style="animation-delay: 0.5s">
<div class="flex justify-between items-start mb-2">
<h5 class="font-medium text-[var(--accent-warm)]">Cardiology Referral</h5>
<span class="text-xs px-2 py-1 bg-[var(--accent-warm)]/10 text-[var(--accent-warm)] rounded-full">In Progress</span>
</div>
<p class="text-sm text-[var(--muted)] mb-3">Baseline cardiac evaluation for MYH7 variant - referral to Dr. Michael Torres</p>
<button class="btn btn-secondary text-xs">Schedule Appointment</button>
</div>
<div class="timeline-item" style="animation-delay: 0.6s">
<div class="flex justify-between items-start mb-2">
<h5 class="font-medium">High-Risk Breast Cancer Screening</h5>
<span class="text-xs text-[var(--muted)]">Upcoming</span>
</div>
<p class="text-sm text-[var(--muted)]">Annual MRI and mammogram recommended starting at age 30</p>
</div>
<div class="timeline-item" style="animation-delay: 0.7s">
<div class="flex justify-between items-start mb-2">
<h5 class="font-medium">Family Cascade Testing</h5>
<span class="text-xs text-[var(--muted)]">Recommended</span>
</div>
<p class="text-sm text-[var(--muted)]">Consider genetic testing for first-degree relatives</p>
</div>
</div>
</div>
</div>
<!-- Care Team -->
<div class="lg:col-span-1">
<div class="card mb-6 reveal" style="animation-delay: 0.3s">
<h4 class="font-semibold mb-4">Your Care Team</h4>
<div class="space-y-4">
<div class="flex items-center gap-3">
<div class="w-10 h-10 rounded-full bg-gradient-to-br from-blue-400 to-blue-600 flex items-center justify-center text-white text-sm font-semibold">
EC
</div>
<div>
<p class="text-sm font-medium">Dr. Emily Chen</p>
<p class="text-xs text-[var(--muted)]">Medical Geneticist</p>
</div>
</div>
<div class="flex items-center gap-3">
<div class="w-10 h-10 rounded-full bg-gradient-to-br from-purple-400 to-purple-600 flex items-center justify-center text-white text-sm font-semibold">
RW
</div>
<div>
<p class="text-sm font-medium">Rachel Williams, MS</p>
<p class="text-xs text-[var(--muted)]">Genetic Counselor</p>
</div>
</div>
<div class="flex items-center gap-3">
<div class="w-10 h-10 rounded-full bg-gradient-to-br from-teal-400 to-teal-600 flex items-center justify-center text-white text-sm font-semibold">
MT
</div>
<div>
<p class="text-sm font-medium">Dr. Michael Torres</p>
<p class="text-xs text-[var(--muted)]">Cardiologist</p>
</div>
</div>
</div>
<button class="btn btn-secondary w-full mt-4 text-sm">
Message Care Team
</button>
</div>
<div class="card reveal" style="animation-delay: 0.4s">
<h4 class="font-semibold mb-4">Upcoming Appointments</h4>
<div class="p-3 bg-[var(--bg)] rounded-lg mb-3">
<p class="text-sm font-medium">Cardiology Consultation</p>
<p class="text-xs text-[var(--muted)] mt-1">Dr. Michael Torres</p>
<p class="text-xs text-[var(--accent)] mt-1">Awaiting scheduling</p>
</div>
<div class="p-3 bg-[var(--bg)] rounded-lg">
<p class="text-sm font-medium">Follow-up Genetic Counseling</p>
<p class="text-xs text-[var(--muted)] mt-1">Rachel Williams, MS</p>
<p class="text-xs text-[var(--accent)] mt-1">Feb 19, 2025 at 2:00 PM</p>
</div>
</div>
</div>
</div>
</section>
<!-- Resources Section -->
<section id="section-resources" class="section-content hidden">
<div class="mb-8 reveal">
<h2 class="text-3xl mb-2">Support Resources</h2>
<p class="text-[var(--muted)]">Educational materials and support services</p>
</div>
<div class="grid md:grid-cols-2 gap-6">
<div class="card reveal" style="animation-delay: 0.1s">
<div class="w-12 h-12 rounded-xl bg-cyan-500/10 flex items-center justify-center mb-4">
<svg width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="var(--accent)" stroke-width="2">
<path d="M4 19.5A2.5 2.5 0 0 1 6.5 17H20"/>
<path d="M6.5 2H20v20H6.5A2.5 2.5 0 0 1 4 19.5v-15A2.5 2.5 0 0 1 6.5 2z"/>
</svg>
</div>
<h4 class="font-semibold mb-2">Patient Guides</h4>
<p class="text-sm text-[var(--muted)] mb-4">Downloadable resources about understanding your genomic results.</p>
<ul class="space-y-2 text-sm">
<li><a href="#" class="text-[var(--accent)] hover:underline">Understanding Your BRCA Results</a></li>
<li><a href="#" class="text-[var(--accent)] hover:underline">Talking to Family About Genetics</a></li>
<li><a href="#" class="text-[var(--accent)] hover:underline">Insurance and Genetic Privacy</a></li>
</ul>
</div>
<div class="card reveal" style="animation-delay: 0.2s">
<div class="w-12 h-12 rounded-xl bg-orange-500/10 flex items-center justify-center mb-4">
<svg width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="var(--accent-warm)" stroke-width="2">
<path d="M17 21v-2a4 4 0 0 0-4-4H5a4 4 0 0 0-4 4v2"/>
<circle cx="9" cy="7" r="4"/>
<path d="M23 21v-2a4 4 0 0 0-3-3.87"/>
<path d="M16 3.13a4 4 0 0 1 0 7.75"/>
</svg>
</div>
<h4 class="font-semibold mb-2">Support Groups</h4>
<p class="text-sm text-[var(--muted)] mb-4">Connect with others who have similar genetic findings.</p>
<ul class="space-y-2 text-sm">
<li><a href="#" class="text-[var(--accent)] hover:underline">BRCA Support Community</a></li>
<li><a href="#" class="text-[var(--accent)] hover:underline">Hereditary Cancer Support Network</a></li>
<li><a href="#" class="text-[var(--accent)] hover:underline">Genetic Heart Conditions Group</a></li>
</ul>
</div>
<div class="card reveal" style="animation-delay: 0.3s">
<div class="w-12 h-12 rounded-xl bg-green-500/10 flex items-center justify-center mb-4">
<svg width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="var(--success)" stroke-width="2">
<rect x="3" y="4" width="18" height="18" rx="2" ry="2"/>
<line x1="16" y1="2" x2="16" y2="6"/>
<line x1="8" y1="2" x2="8" y2="6"/>
<line x1="3" y1="10" x2="21" y2="10"/>
</svg>
</div>
<h4 class="font-semibold mb-2">Upcoming Events</h4>
<p class="text-sm text-[var(--muted)] mb-4">Webinars and support sessions for patients.</p>
<div class="p-3 bg-[var(--bg)] rounded-lg">
<p class="text-sm font-medium">Living with BRCA: Prevention Strategies</p>
<p class="text-xs text-[var(--muted)] mt-1">Feb 25, 2025 at 6:00 PM</p>
<button class="btn btn-secondary text-xs mt-2">Register</button>
</div>
</div>
<div class="card reveal" style="animation-delay: 0.4s">
<div class="w-12 h-12 rounded-xl bg-purple-500/10 flex items-center justify-center mb-4">
<svg width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="#a855f7" stroke-width="2">
<circle cx="12" cy="12" r="10"/>
<path d="M9.09 9a3 3 0 0 1 5.83 1c0 2-3 3-3 3"/>
<line x1="12" y1="17" x2="12.01" y2="17"/>
</svg>
</div>
<h4 class="font-semibold mb-2">Frequently Asked Questions</h4>
<p class="text-sm text-[var(--muted)] mb-4">Common questions about secondary findings.</p>
<button class="btn btn-secondary text-sm">View FAQ</button>
</div>
</div>
</section>
</main>
<!-- Consent Modal -->
<div class="modal-overlay" id="modal-overlay" onclick="closeConsentModal()"></div>
<div class="modal" id="consent-modal" role="dialog" aria-labelledby="modal-title" aria-modal="true">
<div class="p-6 border-b border-[var(--border)]">
<div class="flex justify-between items-center">
<h3 id="modal-title" class="text-xl font-semibold">Update Consent Preferences</h3>
<button onclick="closeConsentModal()" class="p-2 hover:bg-[var(--bg)] rounded-lg transition-colors" aria-label="Close modal">
<svg width="20" height="20" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2">
<line x1="18" y1="6" x2="6" y2="18"/>
<line x1="6" y1="6" x2="18" y2="18"/>
</svg>
</button>
</div>
</div>
<div class="p-6">
<p class="text-sm text-[var(--muted)] mb-6">Select which categories of secondary findings you would like to receive. You can update these preferences at any time.</p>
<div class="space-y-3 mb-6">
<label class="checkbox-custom">
<input type="checkbox" checked>
<div>
<p class="font-medium text-sm">Hereditary Cancer Predisposition</p>
<p class="text-xs text-[var(--muted)]">BRCA1, BRCA2, Lynch syndrome genes, etc.</p>
</div>
</label>
<label class="checkbox-custom">
<input type="checkbox" checked>
<div>
<p class="font-medium text-sm">Cardiovascular Conditions</p>
<p class="text-xs text-[var(--muted)]">Cardiomyopathy, arrhythmia, familial hypercholesterolemia</p>
</div>
</label>
<label class="checkbox-custom">
<input type="checkbox">
<div>
<p class="font-medium text-sm">Pharmacogenomic Results</p>
<p class="text-xs text-[var(--muted)]">Drug metabolism variants affecting medication dosing</p>
</div>
</label>
<label class="checkbox-custom">
<input type="checkbox">
<div>
<p class="font-medium text-sm">Adult-Onset Neurological Conditions</p>
<p class="text-xs text-[var(--muted)]">Huntington's disease, Alzheimer's risk genes (APOE)</p>
</div>
</label>
<label class="checkbox-custom">
<input type="checkbox" checked>
<div>
<p class="font-medium text-sm">Recontact for New Findings</p>
<p class="text-xs text-[var(--muted)]">Allow recontact if variant classification changes</p>
</div>
</label>
</div>
<div class="p-4 bg-[var(--bg)] rounded-xl mb-6">
<h5 class="font-medium text-sm mb-2">Important Information</h5>
<ul class="text-xs text-[var(--muted)] space-y-1">
<li>Changes may take 2-3 business days to process</li>
<li>Previously disclosed findings cannot be retracted</li>
<li>Genetic counselors are available to discuss options</li>
</ul>
</div>
<div class="flex gap-3">
<button class="btn btn-primary flex-1" onclick="submitConsent()">Save Preferences</button>
<button class="btn btn-secondary" onclick="closeConsentModal()">Cancel</button>
</div>
</div>
</div>
<script>
// Initialize DNA animation
const dnaStrand = document.getElementById('dna-strand');
const nodesPerLoop = 20;
const strandHeight = 2000;
function createDNAHelix() {
if (!dnaStrand) return;
dnaStrand.innerHTML = '';
for (let i = 0; i < nodesPerLoop; i++) {
const y = (i / nodesPerLoop) * strandHeight;
const progress = i / nodesPerLoop;
const xOffset1 = Math.sin(progress * Math.PI * 2) * 40 + 50;
const xOffset2 = Math.sin(progress * Math.PI * 2 + Math.PI) * 40 + 50;
// Create nodes
const node1 = document.createElement('div');
node1.className = 'dna-node';
node1.style.left = `${xOffset1}px`;
node1.style.top = `${y}px`;
node1.style.background = '#0891b2';
dnaStrand.appendChild(node1);
const node2 = document.createElement('div');
node2.className = 'dna-node';
node2.style.left = `${xOffset2}px`;
node2.style.top = `${y}px`;
node2.style.background = '#f97316';
dnaStrand.appendChild(node2);
// Create connector
if (i % 2 === 0) {
const connector = document.createElement('div');
connector.className = 'dna-connector';
connector.style.left = `${Math.min(xOffset1, xOffset2) + 6}px`;
connector.style.top = `${y + 5}px`;
connector.style.width = `${Math.abs(xOffset2 - xOffset1)}px`;
dnaStrand.appendChild(connector);
}
}
}
createDNAHelix();
// Navigation
const navItems = document.querySelectorAll('.nav-item[data-section]');
const sections = document.querySelectorAll('.section-content');
function navigateTo(sectionId) {
navItems.forEach(item => item.classList.remove('active'));
sections.forEach(section => section.classList.add('hidden'));
const targetNav = document.querySelector(`.nav-item[data-section="${sectionId}"]`);
const targetSection = document.getElementById(`section-${sectionId}`);
if (targetNav) targetNav.classList.add('active');
if (targetSection) {
targetSection.classList.remove('hidden');
triggerReveal(targetSection);
}
// Close sidebar on mobile
if (window.innerWidth <= 1024) {
closeSidebar();
}
}
navItems.forEach(item => {
item.addEventListener('click', () => {
const section = item.getAttribute('data-section');
if (section) navigateTo(section);
});
});
// Sidebar toggle
function toggleSidebar() {
const sidebar = document.getElementById('sidebar');
const overlay = document.getElementById('overlay-backdrop');
sidebar.classList.toggle('open');
overlay.classList.toggle('active');
}
function closeSidebar() {
const sidebar = document.getElementById('sidebar');
const overlay = document.getElementById('overlay-backdrop');
sidebar.classList.remove('open');
overlay.classList.remove('active');
}
// Theme toggle
function toggleTheme() {
const isDark = document.body.getAttribute('data-theme') === 'dark';
document.body.setAttribute('data-theme', isDark ? 'light' : 'dark');
localStorage.setItem('theme', isDark ? 'light' : 'dark');
}
// Load saved theme
const savedTheme = localStorage.getItem('theme');
if (savedTheme) {
document.body.setAttribute('data-theme', savedTheme);
}
// Modal
function openConsentModal() {
document.getElementById('modal-overlay').classList.add('active');
document.getElementById('consent-modal').classList.add('active');
document.body.style.overflow = 'hidden';
}
function closeConsentModal() {
document.getElementById('modal-overlay').classList.remove('active');
document.getElementById('consent-modal').classList.remove('active');
document.body.style.overflow = '';
}
function submitConsent() {
// Simulate submission
const btn = event.target;
btn.textContent = 'Saving...';
btn.disabled = true;
setTimeout(() => {
closeConsentModal();
btn.textContent = 'Save Preferences';
btn.disabled = false;
// Show success feedback
alert('Your consent preferences have been updated successfully.');
}, 1000);
}
// Accordion
function toggleAccordion(header) {
const content = header.nextElementSibling;
const isOpen = content.classList.contains('open');
// Close all accordions
document.querySelectorAll('.accordion-content').forEach(c => c.classList.remove('open'));
document.querySelectorAll('.accordion-header').forEach(h => h.classList.remove('open'));
// Open clicked if it was closed
if (!isOpen) {
content.classList.add('open');
header.classList.add('open');
}
}
// Scroll reveal
function triggerReveal(container) {
const reveals = container.querySelectorAll('.reveal');
reveals.forEach((el, index) => {
setTimeout(() => {
el.classList.add('visible');
}, index * 100);
});
}
// Initial reveal
const initialSection = document.getElementById('section-dashboard');
if (initialSection) {
triggerReveal(initialSection);
}
// Intersection Observer for scroll reveal
const observerOptions = {
threshold: 0.1,
rootMargin: '0px 0px -50px 0px'
};
const observer = new IntersectionObserver((entries) => {
entries.forEach(entry => {
if (entry.isIntersecting) {
entry.target.classList.add('visible');
}
});
}, observerOptions);
document.querySelectorAll('.reveal').forEach(el => {
observer.observe(el);
});
// Filter findings
const filterBtns = document.querySelectorAll('[data-filter]');
filterBtns.forEach(btn => {
btn.addEventListener('click', () => {
const filter = btn.getAttribute('data-filter');
const cards = document.querySelectorAll('.finding-card');
filterBtns.forEach(b => b.classList.remove('btn-primary'));
filterBtns.forEach(b => b.classList.add('btn-secondary'));
btn.classList.remove('btn-secondary');
btn.classList.add('btn-primary');
cards.forEach(card => {
const category = card.getAttribute('data-category');
if (filter === 'all' || category === filter) {
card.style.display = 'block';
} else {
card.style.display = 'none';
}
});
});
});
// Keyboard navigation
document.addEventListener('keydown', (e) => {
if (e.key === 'Escape') {
closeConsentModal();
}
});
// Reduced motion check
const prefersReducedMotion = window.matchMedia('(prefers-reduced-motion: reduce)').matches;
if (prefersReducedMotion) {
document.querySelectorAll('.reveal').forEach(el => {
el.classList.add('visible');
});
}
</script>
</body>
</html>
Key Features
1. Dashboard Overview
- Quick stats on secondary findings count, education progress, and care pathway status
- Action items with consent update alerts
- Recent activity timeline
2. Findings Management
- Detailed variant cards with HGVS notation, ClinVar IDs, and associated conditions
- Color-coded classification badges (Pathogenic/VUS/Benign)
- Filter functionality by finding type
- Direct links to consent updates and care pathways
3. Tailored Education Modules
- Progressive learning about secondary findings
- Accordion-style expandable content
- Completion tracking with progress indicators
- Contextual links to consent management
4. Consent Management
- Clear status overview of current consent categories
- Detailed consent history log
- Modal interface for updating preferences with clear explanations
- Important considerations highlighted
5. Care Pathway Visualization
- Visual timeline with completed, current, and upcoming steps
- Care team directory with contact options
- Appointment scheduling integration
- Family cascade testing recommendations
6. Design Features
- DNA helix background animation
- Dark/light mode toggle
- Responsive design (mobile-friendly sidebar)
- Smooth scroll reveal animations
- Accessible keyboard navigation
- Respects reduced motion preferences