/* Partwise demo site: the pages around the components. Not needed in your project. */
:root { --site-canvas: #f3f4f6; --site-mark: #c9f26c; --site-mark-ink: #1b2a00; }
[data-pw-theme="dark"] { --site-canvas: #0e1014; --site-mark: #c9f26c; }
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-padding-top: 76px; }
body { margin: 0; background: var(--site-canvas); color: var(--pw-text); font: 400 16px/1.55 'Instrument Sans', system-ui, -apple-system, 'Segoe UI', Roboto, sans-serif; -webkit-font-smoothing: antialiased; }
a { color: var(--pw-accent-text); }
h1, h2, h3 { letter-spacing: -.02em; line-height: 1.15; }
code { font-family: 'JetBrains Mono', ui-monospace, Menlo, Consolas, monospace; font-size: .86em; }
:not(pre) > code { padding: 2px 6px; border-radius: 6px; background: var(--pw-bg-3); color: var(--pw-text); overflow-wrap: anywhere; }
.skip { position: absolute; left: 12px; top: -60px; z-index: 2000; padding: 10px 14px; border-radius: 8px; background: var(--pw-text); color: var(--pw-bg); }
.skip:focus { top: 12px; }

.site-top { position: sticky; top: 0; z-index: 900; display: flex; align-items: center; gap: 10px; height: 60px; padding: 0 20px; border-bottom: 1px solid var(--pw-line); background: color-mix(in srgb, var(--site-canvas) 88%, transparent); backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px); }
.site-brand { display: inline-flex; align-items: center; gap: 10px; margin-inline-end: auto; color: var(--pw-text); font-size: 1.15rem; font-weight: 700; letter-spacing: -.02em; text-decoration: none; }
.site-logo { display: grid; grid-template-columns: 1fr 1fr; gap: 3px; width: 28px; height: 28px; padding: 5px; border-radius: 8px; background: var(--pw-text); }
.site-logo i { border-radius: 2.5px; background: var(--pw-bg); }
.site-logo i:nth-child(2) { background: var(--site-mark); border-radius: 50%; }
.site-find { display: inline-flex; align-items: center; gap: 10px; min-height: 38px; padding: 0 8px 0 12px; border: 1px solid var(--pw-line-2); border-radius: 9px; background: var(--pw-bg); color: var(--pw-text-3); font: inherit; font-size: .92rem; cursor: pointer; }
.site-find:hover { border-color: var(--pw-text-3); color: var(--pw-text); }
.site-find:focus-visible { outline: none; box-shadow: var(--pw-ring); }
.site-menu-btn { display: none; }

.site-body { display: grid; grid-template-columns: 250px minmax(0, 1fr); max-width: 1320px; margin: 0 auto; }
.site-nav { position: sticky; top: 60px; align-self: start; height: calc(100vh - 60px); padding: 22px 12px 40px 20px; overflow-y: auto; scrollbar-width: thin; }
.site-nav h2 { margin: 18px 10px 5px; font-size: .78rem; font-weight: 600; letter-spacing: 0; color: var(--pw-text-3); }
.site-nav h2:first-child { margin-top: 0; }
.site-nav a { display: block; padding: 6px 10px; border-radius: 7px; color: var(--pw-text-2); font-size: .94rem; font-weight: 500; text-decoration: none; }
.site-nav a:hover { background: var(--pw-bg-3); color: var(--pw-text); }
.site-nav a[aria-current="page"] { background: var(--pw-text); color: var(--pw-bg); font-weight: 600; }
.site-nav a:focus-visible { outline: none; box-shadow: var(--pw-ring); }
.site-main { min-width: 0; padding: 34px 32px 90px; }
.site-main > * { max-width: 860px; }

.page-head { margin-bottom: 30px; }
.page-tag { display: inline-block; margin-bottom: 12px; padding: 3px 10px; border-radius: 99px; background: var(--site-mark); color: var(--site-mark-ink); font-size: .8rem; font-weight: 600; }
.page-head h1 { margin: 0; font-size: clamp(2rem, 4.2vw, 2.8rem); font-weight: 700; }
.page-head p { margin: 12px 0 0; max-width: 62ch; font-size: 1.12rem; color: var(--pw-text-2); }
.section { margin-top: 44px; }
.section > h2 { margin: 0 0 6px; font-size: 1.4rem; font-weight: 700; }
.section > p { margin: 0 0 14px; max-width: 70ch; color: var(--pw-text-2); }
.demo { margin-top: 26px; }
.demo > h3 { margin: 0 0 4px; font-size: 1.05rem; font-weight: 650; letter-spacing: -.01em; }
.demo > p { margin: 0 0 12px; max-width: 70ch; color: var(--pw-text-2); }
.stage { padding: 26px; border: 1px solid var(--pw-line); border-radius: 14px 14px 0 0; background: var(--pw-bg); }
.stage--center { display: flex; flex-wrap: wrap; align-items: center; justify-content: center; gap: 12px; }
.stage--row { display: flex; flex-wrap: wrap; align-items: center; gap: 12px; }
.stage--narrow > * { max-width: 420px; }
.stage--flush { padding: 0; overflow: hidden; }
.stage--tall { min-height: 260px; }
.source { border: 1px solid var(--pw-line); border-top: 0; border-radius: 0 0 14px 14px; background: var(--pw-bg-2); overflow: hidden; }
.source > summary { display: flex; align-items: center; gap: 8px; padding: 9px 16px; font-size: .86rem; font-weight: 600; color: var(--pw-text-2); cursor: pointer; list-style: none; user-select: none; }
.source > summary::-webkit-details-marker { display: none; }
.source > summary::before { content: ''; width: 14px; height: 14px; background: currentColor; -webkit-mask: var(--pw-i-chevron) center / contain no-repeat; mask: var(--pw-i-chevron) center / contain no-repeat; rotate: -90deg; transition: rotate .15s; }
.source[open] > summary::before { rotate: 0deg; }
.source > summary:hover { color: var(--pw-text); }
.source > summary:focus-visible { outline: 2px solid var(--pw-accent); outline-offset: -2px; }
.source .pw-codeblock { border: 0; border-radius: 0; }
.site-main .pw-codeblock { margin: 0; }
.section > .pw-codeblock, .section > pre { margin: 12px 0; }

.spec { width: 100%; border-collapse: collapse; font-size: .94rem; }
.spec th, .spec td { padding: 10px 14px 10px 0; text-align: start; vertical-align: top; border-bottom: 1px solid var(--pw-line); }
.spec th { font-size: .8rem; font-weight: 600; color: var(--pw-text-3); white-space: nowrap; }
.spec td:first-child { white-space: nowrap; }
.spec td { color: var(--pw-text-2); }
.spec-wrap { overflow-x: auto; }
.notes { margin: 0; padding-inline-start: 20px; color: var(--pw-text-2); }
.notes li { margin: 6px 0; max-width: 72ch; }
.pager { display: flex; justify-content: space-between; gap: 12px; margin-top: 60px; padding-top: 22px; border-top: 1px solid var(--pw-line); }
.pager a { display: grid; gap: 2px; padding: 10px 14px; border: 1px solid var(--pw-line); border-radius: 10px; background: var(--pw-bg); color: var(--pw-text); font-weight: 650; text-decoration: none; }
.pager a small { font-weight: 500; color: var(--pw-text-3); }
.pager a:hover { border-color: var(--pw-text-3); }
.pager a:last-child { text-align: end; margin-inline-start: auto; }

/* start page */
.hero { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.05fr); gap: 40px; align-items: center; max-width: none !important; margin-bottom: 56px; }
.hero h1 { margin: 14px 0 0; font-size: clamp(2.4rem, 5vw, 3.7rem); font-weight: 700; letter-spacing: -.035em; line-height: 1.02; }
.hero p { margin: 18px 0 0; max-width: 46ch; font-size: 1.15rem; color: var(--pw-text-2); }
.hero-actions { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 24px; }
.hero-facts { display: flex; flex-wrap: wrap; gap: 8px 22px; margin: 26px 0 0; padding: 0; list-style: none; font-size: .92rem; color: var(--pw-text-2); }
.hero-facts b { color: var(--pw-text); }
.bench { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
.bench > div { min-width: 0; padding: 16px; border: 1px solid var(--pw-line); border-radius: 14px; background: var(--pw-bg); }
.bench > .wide { grid-column: 1 / -1; }
.bench-label { display: block; margin-bottom: 9px; font-size: .78rem; font-weight: 600; color: var(--pw-text-3); }
.catalog { max-width: none !important; }
.catalog h2 { margin: 40px 0 12px; font-size: 1.25rem; font-weight: 700; }
.catalog-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: 12px; }
.catalog-grid a { display: grid; gap: 4px; align-content: start; padding: 16px 16px 15px; border: 1px solid var(--pw-line); border-radius: 14px; background: var(--pw-bg); color: var(--pw-text); text-decoration: none; transition: border-color .15s, translate .15s, box-shadow .15s; }
.catalog-grid a:hover { border-color: var(--pw-text); translate: 0 -2px; box-shadow: 0 6px 0 -3px var(--site-mark); }
.catalog-grid a:focus-visible { outline: none; box-shadow: var(--pw-ring); border-color: var(--pw-accent); }
.catalog-grid b { font-size: 1.02rem; font-weight: 650; }
.catalog-grid span { font-size: .9rem; color: var(--pw-text-2); line-height: 1.4; }

/* small things used inside demos */
.demo-card { display: grid; gap: 6px; padding: 18px; border: 1px solid var(--pw-line); border-radius: 12px; background: var(--pw-bg-2); min-height: 150px; align-content: end; }
.demo-card b { font-size: 1.05rem; }
.demo-card span { font-size: .9rem; color: var(--pw-text-2); }
.demo-tile { display: grid; gap: 4px; padding: 0 0 12px; border: 1px solid var(--pw-line); border-radius: 12px; background: var(--pw-bg); overflow: hidden; }
.demo-tile img { display: block; width: 100%; aspect-ratio: 4 / 3; object-fit: cover; }
.demo-tile b { padding: 8px 12px 0; }
.demo-tile span { padding: 0 12px; font-size: .86rem; color: var(--pw-text-3); }
.demo-thumbs { display: grid; grid-template-columns: repeat(auto-fill, minmax(130px, 1fr)); gap: 10px; }
.demo-thumbs a { display: block; border-radius: 10px; overflow: hidden; }
.demo-thumbs a:focus-visible { outline: 3px solid var(--pw-accent); outline-offset: 2px; }
.demo-thumbs img { display: block; width: 100%; aspect-ratio: 4 / 3; object-fit: cover; transition: scale .25s; }
.demo-thumbs a:hover img { scale: 1.05; }
.demo-area { display: grid; place-items: center; min-height: 150px; padding: 20px; border: 1.5px dashed var(--pw-line-2); border-radius: 12px; color: var(--pw-text-3); text-align: center; }
.demo-out { margin: 12px 0 0; font-size: .88rem; color: var(--pw-text-3); min-height: 1.4em; }
.demo-out code { background: var(--pw-bg-3); }
.demo-form { display: grid; gap: 16px; max-width: 440px; }
.demo-grid-2 { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; }
.demo-scroll { height: 60px; }
.swatches { display: flex; flex-wrap: wrap; gap: 8px; }
.swatches button { width: 30px; height: 30px; border-radius: 50%; border: 2px solid var(--pw-bg); box-shadow: 0 0 0 1px var(--pw-line-2); cursor: pointer; padding: 0; }
.swatches button[aria-pressed="true"] { box-shadow: 0 0 0 2px var(--pw-text); }
.swatches button:focus-visible { outline: none; box-shadow: 0 0 0 2px var(--pw-bg), 0 0 0 4px var(--pw-accent); }

@media (max-width: 980px) {
  .site-body { grid-template-columns: minmax(0, 1fr); }
  .site-nav { display: none; }
  .site-menu-btn { display: inline-flex; }
  .site-main { padding: 26px 18px 70px; }
  .hero { grid-template-columns: minmax(0, 1fr); gap: 28px; }
}
@media (max-width: 560px) {
  .site-top { padding: 0 12px; gap: 6px; }
  .site-find span, .site-find kbd { display: none; }
  .site-find { padding: 0 10px; }
  .site-buy { min-height: 36px; padding-inline: 12px; }
  .stage { padding: 16px; }
  .bench { grid-template-columns: minmax(0, 1fr); }
  .demo-grid-2 { grid-template-columns: minmax(0, 1fr); }
}
.site-drawer-nav { padding: 0 !important; }
.site-drawer-nav .site-nav { display: block; position: static; height: auto; padding: 6px 14px 30px; }
.site-buy-short { display: none; }
@media (max-width: 400px) {
  .site-brand-name, .site-buy-name { display: none; }
  .site-buy-short { display: inline; }
}
