root = Card([header, kpiCard, trendCard, productsCard, conversionCard, downloadActions])
header = CardHeader("Monthly Sales Check", "Founder's overview — everything that matters this month")
kpiCard = Card([revenueHeading, revenueValue], "sunk")
revenueHeading = Heading("Revenue this month", "h3")
revenueValue = TextContent("$86,240", "large-heavy")
trendCard = Card([trendHeading, trendChart], "sunk")
trendHeading = Heading("Revenue over the last six months", "h4")
trendChart = LineChart(["Aug", "Sep", "Oct", "Nov", "Dec", "Jan"], [revenueSeries], "natural", "Month", "Revenue")
revenueSeries = Series("Revenue", [41200, 45800, 52300, 61400, 72800, 86240])
productsCard = Card([productsHeading, productsTable], "sunk")
productsHeading = Heading("Best-selling products", "h4")
productsTable = Table([productCol, unitsCol])
productCol = Col("Product", ["Aurora Desk", "Nimbus Chair", "Halo Lamp"])
unitsCol = Col("Units sold", [1240, 980, 762])
conversionCard = Card([conversionHeading, conversionProgress, conversionNote], "sunk")
conversionHeading = Heading("Conversion rate", "h4")
conversionProgress = Progress(3.2, "Visitors who placed an order")
conversionNote = TextContent("3.2% of store visitors purchased this month.", "small")
downloadActions = Buttons([downloadBtn, exportBtn])
downloadBtn = Button("Download numbers", null, "primary")
exportBtn = Button("Export CSV", null, "secondary")