/* Widget styles. Each model sets these tokens on :root (or a wrapper):
   --w-ink, --w-muted, --w-bg, --w-surface, --w-line, --w-in, --w-out, --w-stat, --w-neg,
   --w-accent, --w-accent-ink, --w-radius, --w-radius-sm, --w-font, --w-num */
[data-w] { font-family: var(--w-font); color: var(--w-ink); }
[data-w] *, [data-w] *::before, [data-w] *::after { box-sizing: border-box; }
[data-w] button { font: inherit; color: inherit; cursor: pointer; touch-action: manipulation; }
[data-w] svg { fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
[data-w] :focus-visible { outline: 2px solid var(--w-accent); outline-offset: 2px; }
.w-note { font-size: 13px; color: var(--w-muted); margin: 10px 0 0; line-height: 1.45; }
.w-dim { color: var(--w-muted); font-size: 14px; }
.w-lbl { font-size: 13px; font-weight: 500; color: var(--w-muted); margin: 0 0 6px; }
.w-btn-icon { width: 36px; height: 36px; display: inline-grid; place-items: center; border: 0; border-radius: var(--w-radius-sm); background: var(--w-surface); transition: background-color .15s, transform .12s; }
.w-btn-icon svg { width: 18px; height: 18px; }
.w-btn-icon:hover { background: var(--w-line); }
.w-btn-icon:active { transform: scale(.94); }
.w-legend { display: inline-flex; gap: 14px; font-size: 13px; color: var(--w-muted); }
.w-legend span { display: inline-flex; align-items: center; gap: 6px; }
.w-legend i, .w-mc-day em i { width: 9px; height: 9px; border-radius: 3px; display: inline-block; }
.k-in { background: var(--w-in); } .k-out { background: var(--w-out); } .k-stat { background: var(--w-stat); }
.w-tag { font-size: 13px; padding: 4px 8px; border-radius: 6px; background: var(--w-surface); }
.k-in-t { background: color-mix(in srgb, var(--w-in) 16%, transparent); }
.k-out-t { background: color-mix(in srgb, var(--w-out) 22%, transparent); }
.k-stat-t { background: color-mix(in srgb, var(--w-stat) 24%, transparent); }
[data-tone="pos"] { color: var(--w-in); } [data-tone="mid"] { color: var(--w-stat-ink, var(--w-stat)); } [data-tone="neg"] { color: var(--w-neg); }

/* hero calendar */
.w-hc { background: var(--w-bg); border-radius: var(--w-radius); padding: 18px; }
.w-hc-top { display: flex; align-items: center; gap: 14px; margin-bottom: 14px; }
.w-hc-top > b { font-size: 15px; font-weight: 600; margin-right: auto; }
.w-hc-body { display: grid; grid-template-columns: 150px 22px 1fr; gap: 12px; }
.w-hc-h { font-size: 13px; color: var(--w-muted); margin: 0 0 10px; font-weight: 500; }
.w-hc-h span { opacity: .75; font-weight: 400; margin-left: 4px; }
.w-hc-past { background: var(--w-surface); border-radius: var(--w-radius-sm); padding: 12px; position: relative; overflow: hidden; }
.w-hc-past ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; opacity: .4; filter: blur(.3px); }
.w-hc-past li { display: grid; font-size: 12.5px; }
.w-hc-past li b { font-variant-numeric: tabular-nums; font-weight: 500; }
.w-hc-hind { font-size: 20px; font-weight: 600; letter-spacing: -.02em; color: var(--w-muted); margin: 10px 0 0; }
.w-hc-stamp { position: absolute; left: 50%; top: 46%; translate: -50% -50%; white-space: nowrap; background: var(--w-bg); margin: 0; font-size: 12px; font-weight: 700; color: var(--w-neg); border: 2px solid currentColor; border-radius: 4px; padding: 2px 6px; transform: rotate(-8deg); text-transform: uppercase; letter-spacing: .04em; opacity: 0; transition: opacity .3s .1s, transform .35s cubic-bezier(.2,1.4,.4,1) .1s; }
.played .w-hc-stamp, html:not(.js) .w-hc-stamp { opacity: 1; transform: rotate(-8deg) scale(1); }
.w-hc-today { position: relative; display: grid; place-items: center; }
.w-hc-today::before { content: ""; position: absolute; top: 0; bottom: 0; width: 3px; border-radius: 2px; background: var(--w-accent); }
.w-hc-today span { position: relative; writing-mode: vertical-rl; transform: rotate(180deg); font-size: 11px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; background: var(--w-accent); color: var(--w-accent-ink); padding: 8px 3px; border-radius: 4px; }
.w-hc-grid { display: grid; gap: 6px; }
.w-hc-row { display: grid; grid-template-columns: 54px repeat(6, 1fr); gap: 6px; align-items: center; }
.w-hc-dow, .w-hc-wk { font-size: 12px; color: var(--w-muted); }
.w-hc-cell { min-height: 40px; border-radius: 8px; background: var(--w-surface); font-size: 12px; font-weight: 600; display: flex; align-items: center; gap: 5px; padding: 0 7px; white-space: nowrap; overflow: hidden; }
.w-hc-cell i { width: 7px; height: 7px; border-radius: 2px; flex: none; }
.w-hc-cell.is-in { background: color-mix(in srgb, var(--w-in) 16%, var(--w-bg)); } .w-hc-cell.is-in i { background: var(--w-in); }
.w-hc-cell.is-out { background: color-mix(in srgb, var(--w-out) 20%, var(--w-bg)); } .w-hc-cell.is-out i { background: var(--w-out); }
.w-hc-cell.is-stat { background: color-mix(in srgb, var(--w-stat) 26%, var(--w-bg)); } .w-hc-cell.is-stat i { background: var(--w-stat); }
.js .w-hc-cell:not(:empty) { opacity: 0; transform: translateY(6px) scale(.96); transition: opacity .28s ease-out, transform .32s cubic-bezier(.2,.9,.3,1.2); }
.js .w-hc-cell.on { opacity: 1; transform: none; }
.w-hc-green { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 6px 16px; margin-top: 14px; padding: 12px 14px; border-radius: var(--w-radius-sm); background: color-mix(in srgb, var(--w-in) 12%, var(--w-bg)); font-size: 14px; }
.w-hc-green b { color: var(--w-in); font-variant-numeric: tabular-nums; }

/* score */
.w-score { display: grid; gap: 16px; }
.w-gauge { position: relative; max-width: 260px; margin: 0 auto; width: 100%; }
.w-gauge svg { display: block; width: 100%; }
.w-g-track { stroke: var(--w-surface); stroke-width: 16; }
.w-g-fill { stroke-width: 16; stroke: var(--w-in); transition: stroke-dasharray .45s cubic-bezier(.2,.8,.2,1), stroke .3s; }
.w-g-fill[data-tone="neg"] { stroke: var(--w-neg); } .w-g-fill[data-tone="mid"] { stroke: var(--w-stat); }
.w-g-needle { stroke: var(--w-ink); stroke-width: 3; transform-origin: 110px 112px; transition: transform .45s cubic-bezier(.2,.8,.2,1); }
.w-g-hub { fill: var(--w-ink); stroke: none; }
.w-g-num { margin: 4px 0 0; text-align: center; }
.w-g-num b { display: block; font-size: 40px; font-weight: 700; letter-spacing: -.02em; font-variant-numeric: tabular-nums; line-height: 1; }
.w-g-num span { font-size: 13px; color: var(--w-muted); }
.w-sliders { display: grid; gap: 12px; }
.w-slider { display: grid; gap: 6px; }
.w-s-top { display: flex; justify-content: space-between; font-size: 14px; }
.w-s-top b { font-variant-numeric: tabular-nums; font-weight: 600; }
[data-w] input[type=range] { width: 100%; accent-color: var(--w-accent); height: 28px; margin: 0; cursor: pointer; }
.w-shapes { display: flex; flex-wrap: wrap; gap: 6px; }
.w-chip { border: 0; background: var(--w-surface); border-radius: 999px; padding: 8px 12px; font-size: 13px; transition: background-color .15s, transform .12s; }
.w-chip:hover { background: var(--w-line); } .w-chip:active { transform: scale(.96); }
.w-chip[aria-pressed="true"] { background: var(--w-ink); color: var(--w-bg); }
.w-parts { list-style: none; margin: 0; padding: 0; display: grid; gap: 7px; }
.w-parts li { display: grid; grid-template-columns: 118px 1fr; align-items: center; gap: 10px; font-size: 13px; }
.w-parts i { height: 8px; border-radius: 4px; background: var(--w-surface); overflow: hidden; }
.w-parts s { display: block; height: 100%; border-radius: 4px; background: var(--w-in); transform-origin: left; transition: transform .45s cubic-bezier(.2,.8,.2,1); }
.w-parts s[data-tone="neg"] { background: var(--w-neg); } .w-parts s[data-tone="mid"] { background: var(--w-stat); }

/* segmented */
.w-seg { display: flex; flex-wrap: wrap; gap: 4px; padding: 4px; background: var(--w-surface); border-radius: calc(var(--w-radius-sm) + 4px); }
.w-seg-b { flex: 1 1 auto; border: 0; background: transparent; padding: 8px 12px; border-radius: var(--w-radius-sm); font-size: 13.5px; font-weight: 500; min-height: 38px; transition: background-color .15s, color .15s; }
.w-seg-b:hover { background: color-mix(in srgb, var(--w-ink) 7%, transparent); }
.w-seg-b[aria-checked="true"] { background: var(--w-bg); color: var(--w-ink); box-shadow: 0 1px 2px color-mix(in srgb, var(--w-ink) 18%, transparent); }
.w-seg-sm { margin-bottom: 14px; }

/* industry */
.w-ind { display: grid; gap: 16px; }
.w-bands { list-style: none; margin: 0; padding: 0; display: grid; gap: 14px; }
.w-b-top { display: flex; justify-content: space-between; gap: 10px; font-size: 14px; margin-bottom: 6px; }
.w-b-top b { font-weight: 600; font-variant-numeric: tabular-nums; }
.w-b-track { position: relative; height: 12px; border-radius: 6px; background: var(--w-surface); }
.w-b-band { position: absolute; top: 0; bottom: 0; border-radius: 6px; background: color-mix(in srgb, var(--w-in) 35%, transparent); transition: left .4s cubic-bezier(.2,.8,.2,1), width .4s cubic-bezier(.2,.8,.2,1); }
.w-b-you { position: absolute; top: -4px; width: 4px; height: 20px; border-radius: 2px; background: var(--w-ink); transform: translateX(-2px); transition: left .4s cubic-bezier(.2,.8,.2,1); }

/* month */
.w-mc-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 10px; }
.w-mc-title { font-size: 16px; font-weight: 600; }
.w-mc-dow, .w-mc-grid { display: grid; grid-template-columns: repeat(7, 1fr); gap: 4px; }
.w-mc-dow span { font-size: 12px; color: var(--w-muted); text-align: center; padding-bottom: 4px; }
.w-mc-day { border: 0; background: var(--w-surface); border-radius: 8px; min-height: 44px; padding: 5px 4px; display: grid; align-content: space-between; justify-items: center; font-size: 13px; font-variant-numeric: tabular-nums; transition: background-color .15s, transform .12s; }
.w-mc-day:hover { background: var(--w-line); } .w-mc-day:active { transform: scale(.95); }
.w-mc-day em { display: flex; gap: 2px; min-height: 9px; }
.w-mc-day em i { width: 7px; height: 7px; }
.w-mc-day.is-sel { background: var(--w-ink); color: var(--w-bg); }
.w-mc-detail { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; min-height: 34px; margin-top: 10px; font-size: 14px; }
.w-mc-detail b { margin-right: 4px; }
.w-mc-sum { display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; margin: 10px 0 0; }
.w-mc-sum div { background: var(--w-surface); border-radius: var(--w-radius-sm); padding: 10px; }
.w-mc-sum dt { font-size: 12px; color: var(--w-muted); line-height: 1.3; }
.w-mc-sum dd { margin: 4px 0 0; font-size: 20px; font-weight: 700; font-variant-numeric: tabular-nums; }

/* clock */
.w-clock { display: grid; grid-template-columns: 1.15fr .85fr; gap: 28px; }
.w-field { display: grid; gap: 2px; margin: 14px 0; }
.w-field input { font: inherit; font-size: 18px; font-weight: 600; font-variant-numeric: tabular-nums; padding: 10px 12px; border-radius: var(--w-radius-sm); border: 1.5px solid var(--w-line); background: var(--w-bg); color: var(--w-ink); min-height: 44px; }
.w-field input:focus { border-color: var(--w-accent); outline: none; }
.w-blocks { display: grid; grid-template-columns: repeat(11, 1fr); gap: 4px; margin-top: 14px; }
.w-blocks i { height: 22px; border-radius: 4px; background: var(--w-surface); transition: background-color .2s; }
.w-blocks i.on { background: var(--w-stat); } .w-blocks i.half { background: color-mix(in srgb, var(--w-stat) 50%, var(--w-surface)); }
.w-clock-out { background: var(--w-surface); border-radius: var(--w-radius); padding: 22px; display: flex; flex-direction: column; }
.w-big { font-size: clamp(34px, 4vw, 52px); font-weight: 700; letter-spacing: -.02em; margin: 0 0 14px; font-variant-numeric: tabular-nums; line-height: 1; }
.w-big-2 { font-size: clamp(26px, 2.6vw, 34px); color: var(--w-muted); }
.w-link { margin-top: auto; padding-top: 14px; font-weight: 600; color: var(--w-accent-text, var(--w-ink)); text-underline-offset: 4px; }

/* where */
.w-tabs { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 24px; }
.w-tabs button { border: 0; border-radius: 999px; padding: 12px 18px; background: var(--w-surface); font-size: 15px; font-weight: 500; min-height: 44px; transition: background-color .15s, color .15s, transform .12s; }
.w-tabs button:hover { background: var(--w-line); } .w-tabs button:active { transform: scale(.97); }
.w-tabs button[aria-selected="true"] { background: var(--w-ink); color: var(--w-bg); }
.w-where-p { display: grid; grid-template-columns: .9fr 1.1fr; gap: 40px; align-items: center; }
.w-tagline { font-size: 14px; color: var(--w-muted); margin: 0 0 10px; }
.w-where-copy h3 { font-size: clamp(24px, 2.4vw, 32px); line-height: 1.15; letter-spacing: -.02em; margin: 0 0 12px; font-weight: 650; }
.w-where-copy > p { color: var(--w-muted); line-height: 1.6; margin: 0 0 16px; }
.w-checks { list-style: none; padding: 0; margin: 0 0 22px; display: grid; gap: 10px; }
.w-checks li { display: grid; grid-template-columns: 22px 1fr; gap: 8px; line-height: 1.45; }
.w-checks svg { width: 20px; height: 20px; color: var(--w-in); margin-top: 1px; }
.w-where-cta { display: flex; flex-wrap: wrap; gap: 14px; align-items: center; }
.w-where-cta span { color: var(--w-muted); font-size: 14px; }
.w-btn { display: inline-flex; align-items: center; min-height: 46px; padding: 0 20px; border-radius: var(--w-radius-sm); background: var(--w-accent); color: var(--w-accent-ink); font-weight: 600; text-decoration: none; transition: transform .12s, filter .15s; }
.w-btn:hover { filter: brightness(1.06); } .w-btn:active { transform: scale(.97); }
.w-screen { background: var(--w-bg); border-radius: var(--w-radius); overflow: hidden; border: 1px solid var(--w-line); }
.w-screen-bar { display: flex; justify-content: space-between; gap: 10px; padding: 12px 16px; background: var(--w-surface); font-size: 13px; }
.w-screen-bar span { color: var(--w-muted); }
.w-kpis { display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; padding: 14px 16px 0; }
.w-kpis div { background: var(--w-surface); border-radius: var(--w-radius-sm); padding: 10px; display: grid; gap: 4px; }
.w-kpis span { font-size: 12px; color: var(--w-muted); } .w-kpis b { font-size: 15px; font-variant-numeric: tabular-nums; }
.w-v-bars { display: grid; grid-template-columns: repeat(6, 1fr); gap: 10px; align-items: end; height: 170px; padding: 16px; }
.w-v-bars div { display: flex; flex-direction: column; align-items: center; justify-content: flex-end; gap: 2px; height: 100%; }
.w-v-bars span { width: 60%; max-width: 34px; border-radius: 4px; }
.w-vb-in { background: var(--w-in); } .w-vb-out { background: var(--w-out); } .w-vb-stat { background: var(--w-stat); }
.w-v-bars em { font-style: normal; font-size: 12px; color: var(--w-muted); margin-top: 6px; }
.w-v-cons { display: grid; grid-template-columns: repeat(5, 1fr); gap: 6px; padding: 16px; }
.w-v-cons span { font-size: 12px; text-align: center; padding: 10px 4px; border-radius: var(--w-radius-sm); background: var(--w-surface); }
.w-v-cons b { grid-column: 1 / -1; text-align: center; padding: 12px; border-radius: var(--w-radius-sm); background: var(--w-ink); color: var(--w-bg); font-size: 14px; margin-top: 6px; }
.w-v-lines { padding: 16px; display: grid; gap: 10px; }
.w-v-lines div { display: grid; grid-template-columns: 60px 1fr; align-items: center; gap: 10px; font-size: 13px; }
.w-v-lines i { height: 14px; border-radius: 4px; background: var(--w-in); }
.w-v-lines p { margin: 6px 0 0; font-size: 13px; color: var(--w-muted); }

/* week */
.w-week { background: var(--w-bg); border-radius: var(--w-radius); padding: 18px; }
.w-week-head { display: flex; justify-content: space-between; gap: 10px; flex-wrap: wrap; font-size: 14px; margin-bottom: 14px; }
.w-week-head span { color: var(--w-muted); font-size: 13px; }
.w-week-kpi { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; margin-bottom: 14px; }
.w-week-kpi div { background: var(--w-surface); border-radius: var(--w-radius-sm); padding: 12px; display: grid; gap: 4px; }
.w-week-kpi span { font-size: 13px; color: var(--w-muted); } .w-week-kpi b { font-size: 20px; font-variant-numeric: tabular-nums; }
.w-week-kpi b.pos { color: var(--w-in); }
.w-week-days { display: grid; grid-template-columns: repeat(6, 1fr); gap: 6px; }
.w-week-days button { border: 0; background: var(--w-surface); border-radius: var(--w-radius-sm); padding: 8px 4px 10px; display: grid; justify-items: center; gap: 6px; transition: background-color .15s, transform .12s; }
.w-week-days button:hover { background: var(--w-line); } .w-week-days button:active { transform: scale(.96); }
.w-week-days button[aria-selected="true"] { background: var(--w-ink); color: var(--w-bg); }
.w-week-days span { font-size: 12px; font-weight: 600; }
.w-week-days em { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 2px; height: 64px; }
.w-week-days em i { width: 16px; border-radius: 3px; display: block; }
.w-wd-in { background: var(--w-in); } .w-wd-out { background: var(--w-out); } .w-wd-stat { background: var(--w-stat); }
.w-legend-row { margin: 12px 0; display: flex; flex-wrap: wrap; }
.w-ladder { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.w-lad-col p { margin: 0 0 6px; font-size: 13px; font-weight: 600; }
.w-lad-in p { color: var(--w-in); }
.w-lad-col div { display: flex; justify-content: space-between; gap: 8px; font-size: 13.5px; padding: 9px 10px; border-radius: 8px; background: var(--w-surface); margin-bottom: 4px; }
.w-lad-in div { background: color-mix(in srgb, var(--w-in) 12%, var(--w-bg)); }
.w-lad-col div.is-stat { background: color-mix(in srgb, var(--w-stat) 26%, var(--w-bg)); font-weight: 600; }
.w-lad-col div.is-none { color: var(--w-muted); background: transparent; border: 1.5px dashed var(--w-line); }
.w-lad-col b { font-weight: 500; color: var(--w-muted); white-space: nowrap; font-variant-numeric: tabular-nums; }

/* forecast */
.w-fc { margin: 0; }
.w-fc-plot { position: relative; height: clamp(180px, 26vw, 320px); }
.w-fc-plot svg { position: absolute; inset: 0; width: 100%; height: 100%; overflow: visible; }
.w-fc-past { stroke: var(--w-ink); stroke-width: 3; fill: none; }
.w-fc-ahead { stroke: var(--w-in); stroke-width: 3; stroke-dasharray: 8 7; fill: none; }
.w-fc-band { fill: color-mix(in srgb, var(--w-in) 18%, transparent); stroke: none; }
.w-fc-today { stroke: var(--w-accent); stroke-width: 2; }
.w-fc-floor { stroke: var(--w-stat); stroke-width: 2; stroke-dasharray: 3 6; }
.w-fc-need { position: absolute; right: 0; transform: translateY(-130%); font-size: 13px; color: var(--w-stat-ink, var(--w-stat)); font-weight: 600; }
.w-fc-top, .w-fc-axis { position: relative; height: 26px; font-size: 14px; }
.w-fc-top span { position: absolute; right: calc(100% - var(--t) + 10px); color: var(--w-muted); }
.w-fc-top b { position: absolute; left: calc(var(--t) + 10px); color: var(--w-in); }
.w-fc-axis { display: flex; justify-content: space-between; margin-top: 8px; color: var(--w-muted); font-size: 13px; }
.w-fc-axis .w-fc-tl { position: absolute; left: var(--t); transform: translateX(-50%); color: var(--w-ink); font-weight: 600; }

@media (max-width: 760px) {
  .w-hc-body { grid-template-columns: 1fr; }
  .w-hc-past { display: none; }
  .w-hc-today { display: none; }
  .w-hc-row { grid-template-columns: 44px repeat(6, 1fr); gap: 4px; }
  .w-hc-cell { font-size: 0; padding: 0; justify-content: center; min-height: 32px; }
  .w-hc-cell i { width: 10px; height: 10px; }
  .w-clock, .w-where-p { grid-template-columns: 1fr; }
  .w-mc-sum, .w-kpis { grid-template-columns: 1fr 1fr; }
  .w-v-cons { grid-template-columns: repeat(2, 1fr); }
  .w-ladder { grid-template-columns: 1fr; }
  .w-parts li { grid-template-columns: 104px 1fr; }
}
/* motion */
@keyframes w-swap-in { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: none; } }
.w-swap > * { animation: w-swap-in 320ms cubic-bezier(0.23, 1, 0.32, 1) both; }
.w-swap > *:nth-child(2) { animation-delay: 60ms; }
.w-blocks i { transition: background-color 220ms cubic-bezier(0.23, 1, 0.32, 1); }
.w-g-fill { transition: stroke-dasharray 900ms cubic-bezier(0.23, 1, 0.32, 1), stroke .3s; }
.w-g-needle { transition: transform 900ms cubic-bezier(0.23, 1, 0.32, 1); }
.w-parts s { transition: transform 700ms cubic-bezier(0.23, 1, 0.32, 1); }
[data-w] .w-btn-icon, [data-w] .w-chip, [data-w] .w-seg-b, [data-w] .w-mc-day, [data-w] .w-week-days button, [data-w] .w-tabs button { transition: background-color 160ms ease, color 160ms ease, transform 140ms cubic-bezier(0.23, 1, 0.32, 1); }
[data-w] button:active { transform: scale(.97); }
@media (prefers-reduced-motion: reduce) {
  [data-w] *, [data-w] *::before { transition: none !important; animation: none !important; }
}
