.demo-chrome { display: grid; gap: 1rem; padding: 1rem clamp(1rem, 3vw, 2rem) 0; }
.demo-status-bar { display: flex; align-items: center; gap: 1rem; min-height: 3rem; padding: .5rem .85rem; border: 1px solid #cfe2f3; border-radius: .75rem; background: #f0f8ff; color: #204760; }
.demo-chrome.is-table-page { gap: .45rem; padding-top: .45rem; }
.demo-chrome.is-table-page .demo-status-bar { gap: .65rem; min-height: 2.45rem; padding: .35rem .7rem; }
.demo-chrome.is-table-page .demo-welcome, .demo-chrome.is-table-page .demo-signup-banner { display: none; }
.demo-chrome.is-table-page .demo-guide { display: none; }
.demo-tour-entry { margin-left: auto; white-space: nowrap; }
.demo-chrome.is-table-page .demo-upgrade-link { margin-left: 0; white-space: nowrap; }
.demo-status-label { display: inline-flex; align-items: center; gap: .45rem; font-size: .75rem; font-weight: 800; letter-spacing: .08em; }
.demo-time-remaining { font-size: .875rem; }
.demo-upgrade-link { margin-left: auto; font-size: .875rem; font-weight: 650; text-decoration: none; }
.demo-preview-banner { display: flex; align-items: center; justify-content: space-between; gap: 1rem; padding: 1rem 1.25rem; border: 1px solid #d6e5f1; border-radius: .8rem; background: linear-gradient(120deg, #f2f8fd, #fff); }
.demo-preview-banner h2 { margin: 0 0 .35rem; font-size: 1.1rem; }
.demo-preview-banner .eyebrow { margin-bottom: .3rem; }
.demo-upsell-dialog { width: min(100% - 2rem, 34rem); padding: clamp(1.5rem, 4vw, 2rem); border: 1px solid #d6e5f1; border-radius: 1rem; color: var(--text-primary, #172b3b); box-shadow: 0 1.5rem 5rem #102a4333; }
.demo-upsell-dialog::backdrop { background: #102a4380; backdrop-filter: blur(2px); }
.demo-upsell-dialog h2 { margin-bottom: .5rem; }
.demo-upsell-dialog > p:not(.eyebrow) { color: var(--text-secondary, #667085); }
.demo-upsell-close { position: absolute; top: .7rem; right: .7rem; }
.demo-upsell-actions { display: flex; align-items: center; flex-wrap: wrap; gap: .6rem; margin-top: 1.25rem; }
.demo-welcome, .demo-guide, .demo-tour { position: relative; padding: clamp(1rem, 2.5vw, 1.5rem); }
.demo-welcome { display: flex; align-items: flex-start; justify-content: space-between; gap: 1rem; border-color: #cfdeee; background: linear-gradient(120deg, #f8fbff, #fff); }
.demo-welcome h2 { margin: 0 0 .45rem; font-size: clamp(1.25rem, 2vw, 1.65rem); }
.demo-welcome p { max-width: 72ch; margin-bottom: .45rem; color: var(--text-secondary, #667085); }
.demo-welcome-actions, .demo-tour-actions { display: flex; align-items: center; flex-wrap: wrap; gap: .55rem; margin-top: 1rem; }
.demo-tour { border-color: #9fc5e4; background: linear-gradient(120deg, #f2f8fd, #fff); }
.demo-tour h2 { margin: 0 0 .4rem; }
.demo-tour [data-demo-tour-status]:empty { display: none; }
.demo-tour [data-demo-tour-status].is-error { color: #b02a37; }
.demo-tour [data-demo-tour-status].is-success { color: #1f7a45; }
.demo-tour-step-count { margin-left: .35rem; font-weight: 600; }
.demo-tour-highlight { outline: 3px solid #61a5df; outline-offset: 3px; box-shadow: 0 0 0 .5rem #61a5df22; }
.demo-activity-list { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 260px), 1fr)); gap: .6rem; padding: 0; margin: .5rem 0 0; list-style: none; }
.demo-activity-list a { display: flex; align-items: center; gap: .7rem; height: 100%; padding: .75rem; border: 1px solid var(--border-color, #e1e7ef); border-radius: .7rem; color: inherit; text-decoration: none; transition: border-color .15s, transform .15s; }
.demo-activity-list a:hover, .demo-activity-list a:focus-visible { border-color: #7aaee0; transform: translateY(-1px); }
.demo-activity-list a > span:nth-child(2) { display: grid; gap: .15rem; flex: 1; }
.demo-activity-list small { color: var(--text-secondary, #667085); }
.demo-activity-number { display: grid; place-items: center; width: 1.8rem; height: 1.8rem; flex: 0 0 1.8rem; border-radius: 50%; background: #e8f2fc; color: #175a90; font-weight: 750; }
.demo-activity-list > li > a > i { color: #6684a0; }
.demo-usage { display: inline-flex; flex-wrap: wrap; gap: .35rem 1rem; font-size: .8125rem; color: #2f5873; }
.demo-usage > span { display: inline-flex; align-items: center; gap: .3rem; white-space: nowrap; }
.demo-guide-actions { display: flex; align-items: center; flex-wrap: wrap; gap: .45rem; }
.demo-guide-actions .form-select { width: auto; min-width: 10rem; }
.demo-guide-progress { height: .35rem; margin: .75rem 0 .25rem; }
.demo-guide-groups { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 280px), 1fr)); gap: 1rem; margin-top: .75rem; }
.demo-guide-group h3 { margin: 0; font-size: .75rem; font-weight: 800; letter-spacing: .08em; text-transform: uppercase; color: #6684a0; }
.demo-guide-group .demo-activity-list { grid-template-columns: 1fr; }
.demo-activity-list button { display: flex; align-items: center; gap: .7rem; width: 100%; height: 100%; padding: .75rem; border: 1px solid var(--border-color, #e1e7ef); border-radius: .7rem; background: transparent; color: inherit; text-align: left; transition: border-color .15s, transform .15s; }
.demo-activity-list button:hover, .demo-activity-list button:focus-visible { border-color: #7aaee0; transform: translateY(-1px); }
.demo-activity-list button > span:nth-child(2) { display: grid; gap: .15rem; flex: 1; }
.demo-activity-list > li > button > i { color: #6684a0; }
.demo-activity-list li.is-done .demo-activity-number { background: #dff3e6; color: #1f7a45; font-size: 0; }
.demo-activity-list li.is-done .demo-activity-number::before { content: "\2713"; font-size: .95rem; }
.demo-activity-list li.is-done strong { color: #1f7a45; }
.demo-inline-link { color: var(--bs-link-color, #0d6efd); text-decoration: underline; cursor: pointer; }
.demo-hood { padding: clamp(1rem, 2.5vw, 1.5rem); }
.demo-hood-summary { display: flex; flex-wrap: wrap; gap: .5rem 1.5rem; margin: .75rem 0; }
.demo-hood-summary dt { font-size: .7rem; font-weight: 750; letter-spacing: .06em; text-transform: uppercase; color: #6684a0; }
.demo-hood-summary dd { margin: 0; font-size: 1.05rem; font-weight: 700; }
.demo-hood-table tr.is-current td { font-weight: 650; background: #f0f8ff; }
.demo-signup-banner, .demo-launch-card { display: flex; align-items: center; justify-content: space-between; gap: 1rem; padding: 1.2rem 1.4rem; border-radius: .8rem; background: #eaf3fb; }
.demo-signup-banner h2 { margin: 0 0 .25rem; font-size: 1.1rem; }
.demo-signup-banner p { margin: 0; color: var(--text-secondary, #667085); }
.demo-sql-examples { margin-top: 1rem; padding: 1rem; }
.demo-example-links { display: flex; flex-wrap: wrap; gap: .5rem; }
.demo-standalone-body { display: grid; place-items: center; min-height: 100vh; padding: 1rem; background: #f2f7fb; }
.demo-loading-card, .demo-message-card { width: min(100%, 40rem); padding: clamp(1.5rem, 5vw, 3rem); text-align: center; }
.demo-loading-brand { justify-content: center; margin-bottom: 2rem; text-decoration: none; }
.demo-loading-card > .spinner-border { width: 2.5rem; height: 2.5rem; margin-bottom: 1.25rem; }
.demo-loading-card h1, .demo-message-card h1 { font-size: clamp(1.7rem, 5vw, 2.5rem); }
.demo-loading-card p:not(.eyebrow), .demo-message-card p { color: var(--text-secondary, #667085); }
.demo-loading-progress { height: .45rem; margin: 1.5rem 0; }
.demo-message-icon { display: inline-grid; place-items: center; width: 3.25rem; height: 3.25rem; margin-bottom: 1rem; border-radius: 50%; background: #eaf3fb; color: #28668e; font-size: 1.35rem; }
.demo-message-actions { display: flex; justify-content: center; flex-wrap: wrap; gap: .6rem; margin-top: 1.5rem; }
.demo-message-actions form { margin: 0; }
.demo-navbar-actions { display: flex; align-items: center; flex-wrap: wrap; gap: .45rem; }
.demo-navbar-badge { display: inline-flex; align-items: center; gap: .4rem; padding: .35rem .65rem; border: 1px solid #cfe2f3; border-radius: 999px; background: #f0f8ff; color: #204760; font-size: .75rem; font-weight: 750; white-space: nowrap; }
.demo-navbar-actions .btn { white-space: nowrap; }
.sidebar-preview-badge { display: inline-flex; align-items: center; gap: .2rem; margin-left: auto; padding: .12rem .35rem; border: 1px solid #d6e5f1; border-radius: 999px; color: #6684a0; font-size: .625rem; font-weight: 700; }
.lp-demo-launch { padding-block: clamp(2rem, 5vw, 4rem); }
.demo-launch-card { border: 1px solid #d6e5f1; background: linear-gradient(120deg, #f2f8fd, #fff); }
.demo-launch-card h2 { margin-bottom: .5rem; }
.demo-launch-card p { max-width: 68ch; margin-bottom: .45rem; }
.demo-task { display: flex; align-items: center; gap: .8rem; margin-bottom: .75rem; padding: .75rem 1rem; border: 1px solid #7aaee0; border-radius: .75rem; background: #eaf4fd; color: #12344f; }
.demo-task[hidden] { display: none; }
.demo-task h2 { margin: 0 0 .15rem; font-size: 1.15rem; }
.demo-task p { margin: 0; font-size: .875rem; }
.demo-task-icon { font-size: 1.35rem; color: #175a90; }
.demo-task.is-done { border-color: #7cc79a; background: #e9f7ef; color: #14532d; }
.demo-task.is-done .demo-task-icon { color: #1f7a45; }
[data-theme="dark"] .demo-task { border-color: #2f6690; background: #10293d; color: #dbeefe; }
[data-theme="dark"] .demo-task.is-done { border-color: #2f7a4d; background: #10301f; color: #d3f5df; }
[data-theme="dark"] .demo-task-icon { color: inherit; }
/* The guided task keeps navigation, find/filter/sort and undo, and hides the controls it doesn't need. */
.demo-order-task .table-detail-heading, .demo-order-task .grid-viewbar, .demo-order-task .grid-bulk-toolbar,
.demo-order-task .grid-footnote, .demo-order-task .grid-action-primary, .demo-order-task [data-duplicate-selected],
.demo-order-task [data-delete-selected], .demo-order-task .dropdown:has(> [data-grid-more]),
.demo-chrome.is-order-task .demo-usage, .demo-chrome.is-order-task .demo-tour-entry { display: none !important; }
.demo-chrome.is-order-task .demo-upgrade-link { margin-left: auto; }
.demo-order-task .records-grid .tabulator .tabulator-row .tabulator-cell.demo-status-cell { background: color-mix(in srgb, #3b82c4 12%, transparent); box-shadow: inset 2px 0 #3b82c4, inset -2px 0 #3b82c4; cursor: pointer; }
.demo-order-task .records-grid .tabulator .tabulator-header .tabulator-col.demo-status-cell { box-shadow: inset 0 3px #3b82c4; background: color-mix(in srgb, #3b82c4 16%, var(--ft-surface)); }
.demo-status-control { display: flex; align-items: center; justify-content: space-between; gap: .4rem; width: 100%; }
.demo-status-control > i { font-size: .75rem; }
@media (max-width: 640px) {
    .demo-task { align-items: flex-start; padding: .65rem .75rem; }
    .demo-task h2 { font-size: 1rem; }
    .demo-chrome.is-order-task .demo-upgrade-link { width: auto; }
    .demo-chrome.is-order-task .demo-status-label { display: none; }
    /* Phones: keep menu, theme, Exit demo and Sign in; the demo bar already offers "Create an account". */
    body:has(.demo-order-task) .topbar .page-heading, body:has(.demo-order-task) .topbar .demo-navbar-badge,
    body:has(.demo-order-task) .topbar-actions > a[href$="/docs"], body:has(.demo-order-task) .demo-navbar-actions .btn-primary { display: none; }
    body:has(.demo-order-task) .topbar { min-height: 0; padding-block: .5rem; }
    .demo-task-icon, .demo-order-task .grid-record-count, .demo-order-task [data-grid-estimate] { display: none; }
    .demo-order-task .airtable-grid .grid-toolbar { flex-direction: row; flex-wrap: wrap; gap: .35rem; padding: .45rem .5rem; }
    .demo-order-task .grid-context { width: 100%; justify-content: space-between; }
    .demo-order-task .grid-actions { display: flex; flex-wrap: wrap; gap: .35rem; width: 100%; }
    .demo-order-task .grid-actions > .grid-action-group:first-child { display: flex; flex-wrap: wrap; gap: .35rem; flex: 1 1 100%; }
    .demo-order-task .airtable-grid .grid-search-wrap { flex: 1 1 7rem; min-width: 0; }
    .demo-order-task .airtable-grid .grid-refresh-button { flex: 0 0 2.5rem; width: 2.5rem; }
    /* Undo and redo appear once there is something to undo. */
    .demo-order-task .grid-actions > [aria-label="Editing"]:not(:has([data-grid-undo]:enabled, [data-grid-redo]:enabled, [data-retry-write]:not([hidden]))) { display: none; }
    .demo-order-task .records-grid .grid-row-number, .demo-order-task .records-grid .grid-row-menu-toggle,
    .demo-order-task .records-grid .tabulator-header .grid-field-type-icon, .demo-order-task .records-grid .tabulator-header .grid-field-menu-toggle,
    .demo-order-task .records-grid .tabulator-header .tabulator-col-sorter { display: none; }
    .demo-order-task .records-grid .tabulator-header .tabulator-col .tabulator-col-title { padding-right: 0; }
    .demo-status-bar { flex-wrap: wrap; gap: .35rem .75rem; }
    .demo-chrome.is-table-page .demo-status-bar { gap: .35rem .6rem; }
    .demo-chrome.is-table-page .demo-tour-entry { margin-left: 0; }
    .demo-upgrade-link { width: 100%; margin-left: 0; }
    .demo-signup-banner, .demo-launch-card, .demo-preview-banner { align-items: flex-start; flex-direction: column; }
    .demo-welcome { gap: .3rem; }
    .demo-welcome > button { flex: 0 0 auto; }
}
@media (max-width: 360px) {
    .demo-order-task .records-grid .tabulator .tabulator-row .tabulator-cell { padding-inline: .3rem; }
}
