/* ============================================================
   Board widgets (docs/design board-widgets) — each card looks like
   a real object on the board: poll = index card on a pushpin,
   ask = kraft speech bubble, countdown = tear-off calendar,
   ideas = cardboard box with a slot, requests = clipboard,
   stars = sticky note with tape, hi = card with bunting.
   Colours, rotations and shapes match BoardWidget.dc.html.
   ============================================================ */

.bw {
    position: relative;
    font-family: var(--font-hand, "Comic Sans MS", system-ui, sans-serif);
    color: var(--gray-900);
    -webkit-font-smoothing: antialiased;
}
.bw button, .bw input { font-family: inherit; }
.bw .icon { display: block; flex-shrink: 0; }

.bw-card {
    position: relative;
    box-sizing: border-box;
    padding: 14px 14px 12px;
    display: flex;
    flex-direction: column;
    gap: 8px;
}
.bw-kind {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    align-self: flex-start;
    font-size: 12.5px;
    padding: 0 8px;
    border-radius: 8px;
    background: color-mix(in srgb, var(--gray-900) 8%, transparent);
    color: var(--gray-700);
}
.bw-q { font-family: var(--font-marker, "Comic Sans MS", cursive); font-weight: 700; font-size: 25px; line-height: 1.02; }
.bw-foot { font-size: 13px; color: var(--gray-600); display: flex; align-items: center; gap: 6px; flex-wrap: wrap; }

.bw-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 5px;
    min-height: 36px;
    padding: 2px 12px;
    box-sizing: border-box;
    font-size: 15px;
    color: var(--gray-900);
    background: var(--cream);
    border: 2px solid var(--gray-900);
    border-radius: 255px 15px 225px 15px / 15px 225px 15px 255px;
    box-shadow: 2px 2px 0 var(--gray-900);
    cursor: pointer;
}
.bw-btn:hover { transform: translate(-1px, -1px) rotate(-.6deg); box-shadow: 3px 3px 0 var(--gray-900); }
.bw-btn.dark { background: var(--navy); color: var(--amber-200); }
.bw-btn.on { background: var(--yellow-500); }
.bw-btn:disabled { opacity: .5; cursor: default; transform: none; }

.bw-in {
    flex: 1;
    min-width: 0;
    min-height: 36px;
    box-sizing: border-box;
    font-size: 15px;
    padding: 4px 10px;
    color: var(--gray-900);
    background: var(--white);
    border: 2px solid var(--gray-900);
    border-radius: 185px 25px 145px 20px / 20px 155px 25px 175px;
}
.bw-in:focus { outline: 3px solid var(--amber-500); outline-offset: 1px; }

.bw-stack { display: flex; }
.bw-stack .av { margin-left: -8px; }
.bw-stack .av:first-child { margin-left: 0; }

/* poll: index card on a pushpin */
.bw-poll {
    background: var(--cream);
    border: 2px solid var(--gray-900);
    border-radius: 3px 4px 3px 5px;
    background-image:
        linear-gradient(transparent 46px, color-mix(in srgb, var(--red-500) 45%, transparent) 46px 48px, transparent 48px),
        repeating-linear-gradient(transparent 0 23px, color-mix(in srgb, var(--blue-500) 16%, transparent) 23px 24px);
    background-position: 0 0, 0 48px;
    box-shadow: 3px 6px 0 color-mix(in srgb, var(--gray-900) 25%, transparent);
    padding-top: 18px;
}
.bw-pin {
    position: absolute;
    left: 50%;
    top: -10px;
    translate: -50% 0;
    width: 20px;
    height: 20px;
    border-radius: 50%;
    background: radial-gradient(circle at 35% 30%, var(--red-100), var(--red-500) 55%, var(--red-900));
    box-shadow: 0 3px 4px color-mix(in srgb, var(--black) 35%, transparent);
}
.bw-opt {
    position: relative;
    display: flex;
    align-items: center;
    gap: 8px;
    width: 100%;
    min-height: 38px;
    padding: 4px 10px;
    box-sizing: border-box;
    text-align: left;
    font-size: 16px;
    color: var(--gray-900);
    background: var(--white);
    border: 2px solid var(--gray-900);
    border-radius: 12px 9px 13px 8px;
    cursor: pointer;
    overflow: hidden;
}
.bw-opt:hover { background: var(--yellow-100); }
.bw-opt.mine { box-shadow: inset 0 0 0 2px var(--blue-500); border-color: var(--blue-500); }
.bw-opt .fill {
    position: absolute;
    left: 0;
    top: 0;
    bottom: 0;
    background: repeating-linear-gradient(-45deg, color-mix(in srgb, var(--amber-500) 55%, transparent) 0 4px, color-mix(in srgb, var(--amber-500) 18%, transparent) 4px 8px);
    border-right: 2px solid color-mix(in srgb, var(--yellow-700) 60%, transparent);
    transition: width .5s;
}
.bw-opt span { position: relative; }
.bw-opt .l { flex: 1; }
.bw-opt .p { font-size: 14px; color: var(--gray-700); }
.bw-names { font-size: 12.5px; color: var(--gray-600); padding-left: 4px; }

/* question of the day: kraft speech bubble */
.bw-ask {
    background: var(--amber-200);
    color: var(--amber-950);
    border: 2.5px solid var(--amber-950);
    border-radius: 22px 26px 24px 20px / 20px 24px 26px 22px;
    background-image: radial-gradient(color-mix(in srgb, var(--amber-950) 12%, transparent) 1px, transparent 1.4px);
    background-size: 7px 7px;
    box-shadow: 3px 5px 0 color-mix(in srgb, var(--amber-950) 30%, transparent);
}
.bw-ask::after {
    content: "";
    position: absolute;
    left: 34px;
    bottom: -16px;
    width: 22px;
    height: 18px;
    background: var(--amber-200);
    border-left: 2.5px solid var(--amber-950);
    border-bottom: 2.5px solid var(--amber-950);
    transform: skewX(-30deg);
    border-radius: 0 0 0 6px;
}
.bw-ask .bw-kind { background: color-mix(in srgb, var(--amber-950) 12%, transparent); color: var(--amber-950); }
.bw-ask .bw-anslink { color: var(--amber-950); text-underline-offset: 3px; }

/* countdown: tear-off calendar */
.bw-count {
    background: var(--cream);
    border: 2.5px solid var(--gray-900);
    border-radius: 6px 6px 14px 14px;
    box-shadow: 3px 6px 0 color-mix(in srgb, var(--gray-900) 25%, transparent);
    padding-top: 26px;
    align-items: center;
    text-align: center;
}
.bw-count::before {
    content: "";
    position: absolute;
    left: 0;
    right: 0;
    top: 0;
    height: 16px;
    background: var(--navy);
    border-radius: 3px 3px 0 0;
}
.bw-rings { position: absolute; top: -9px; left: 24px; right: 24px; display: flex; justify-content: space-between; }
.bw-rings span { width: 8px; height: 20px; border: 2px solid var(--gray-900); border-radius: 6px; background: linear-gradient(90deg, var(--gray-300), var(--white) 50%, var(--gray-500)); }
.bw-digits { display: flex; gap: 6px; justify-content: center; flex-wrap: wrap; max-width: 100%; }
.bw-digit { display: flex; flex-direction: column; align-items: center; min-width: 36px; }
.bw-digit b {
    font-family: var(--font-marker, cursive);
    font-size: 32px;
    line-height: 1;
    padding: 2px 4px;
    border: 2px solid var(--gray-900);
    border-radius: 6px;
    background: var(--amber-200);
    min-width: 28px;
    text-align: center;
    font-variant-numeric: tabular-nums;
}
.bw-digit small { font-size: 12px; color: var(--gray-600); }

/* ideas box */
.bw-ideas {
    background: var(--amber-200);
    border: 2.5px solid var(--amber-900);
    color: var(--amber-950);
    border-radius: 4px 6px 5px 4px;
    box-shadow: 3px 6px 0 color-mix(in srgb, var(--amber-900) 35%, transparent);
}
.bw-ideas .bw-kind { background: color-mix(in srgb, var(--amber-900) 14%, transparent); color: var(--amber-950); }
.bw-slot { height: 10px; margin: 0 30px; border-radius: 6px; background: var(--amber-950); box-shadow: inset 0 3px 0 color-mix(in srgb, var(--black) 40%, transparent); }
.bw-idea {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 4px 6px;
    background: var(--cream);
    border: 2px solid var(--amber-900);
    border-radius: 8px 10px 9px 7px;
    font-size: 15px;
}
.bw-idea .t { flex: 1; line-height: 1.1; }
.bw-idea .by { font-size: 12px; color: var(--amber-900); }
.bw-up {
    display: flex;
    flex-direction: column;
    align-items: center;
    min-width: 36px;
    min-height: 36px;
    justify-content: center;
    border: 2px solid var(--amber-900);
    border-radius: 8px;
    background: var(--white);
    color: var(--amber-950);
    cursor: pointer;
    font-size: 13px;
    line-height: 1;
    padding: 0;
}
.bw-up.on { background: var(--yellow-500); }

/* feature requests: a clipboard */
.bw-req {
    background: var(--orange-300);
    border: 2.5px solid var(--amber-900);
    border-radius: 10px 12px 9px 11px;
    box-shadow: 3px 6px 0 color-mix(in srgb, var(--amber-900) 35%, transparent);
    padding: 22px 10px 10px;
}
.bw-clip {
    position: absolute;
    left: 50%;
    top: -12px;
    translate: -50% 0;
    width: 74px;
    height: 26px;
    border: 2.5px solid var(--gray-900);
    border-radius: 8px 8px 4px 4px;
    background: linear-gradient(180deg, var(--gray-100), var(--gray-500));
    box-shadow: 0 3px 0 color-mix(in srgb, var(--black) 25%, transparent);
}
.bw-clip::after {
    content: "";
    position: absolute;
    left: 50%;
    top: 5px;
    translate: -50% 0;
    width: 22px;
    height: 8px;
    border-radius: 5px;
    background: var(--gray-600);
}
.bw-sheet {
    display: flex;
    flex-direction: column;
    gap: 6px;
    padding: 10px 10px 10px;
    background: var(--cream);
    border: 2px solid var(--amber-900);
    border-radius: 3px;
    box-shadow: 1px 2px 0 color-mix(in srgb, var(--amber-900) 25%, transparent);
}
.bw-req .bw-kind { background: color-mix(in srgb, var(--gray-900) 8%, transparent); }
.bw-rq { display: flex; align-items: center; gap: 8px; font-size: 15px; line-height: 1.1; }
.bw-rq .t { flex: 1; min-width: 0; }
.bw-st {
    display: inline-block;
    font-size: 11.5px;
    padding: 0 6px;
    border: 1.5px solid var(--gray-900);
    border-radius: 8px;
    line-height: 1.45;
    white-space: nowrap;
    margin-top: 2px;
}
.bw-st.planned { background: var(--blue-100); color: var(--blue-900); border-color: var(--blue-900); }
.bw-st.building { background: var(--yellow-500); }
.bw-st.open { background: var(--cream); }
.bw-st.done { background: var(--green-200); }
.bw-st.wont { background: var(--mist-100); }

/* shout-outs: sticky note with tape */
.bw-stars {
    background: var(--yellow-200);
    color: var(--yellow-950);
    border-radius: 2px 2px 24px 2px / 2px 2px 12px 2px;
    box-shadow: 0 1px 1px color-mix(in srgb, var(--black) 12%, transparent), 4px 10px 14px -6px color-mix(in srgb, var(--black) 35%, transparent);
    padding-top: 22px;
}
.bw-stars::before {
    content: "";
    position: absolute;
    top: -10px;
    left: 50%;
    width: 66px;
    height: 18px;
    translate: -50% 0;
    rotate: -3deg;
    background: color-mix(in srgb, var(--red-100) 90%, transparent);
}
.bw-stars .bw-kind { background: color-mix(in srgb, var(--yellow-950) 10%, transparent); color: var(--yellow-950); }
.bw-shout { display: flex; gap: 8px; align-items: flex-start; font-size: 15px; line-height: 1.15; }
.bw-pick { display: flex; flex-wrap: wrap; gap: 4px; }
.bw-chip {
    min-height: 32px;
    padding: 0 10px;
    font-size: 14px;
    border: 2px solid var(--gray-900);
    border-radius: 16px 12px 14px 10px;
    background: var(--white);
    color: var(--gray-900);
    cursor: pointer;
}
.bw-chip.on { background: var(--navy); color: var(--amber-200); }

/* new faces: card with bunting */
.bw-hi {
    background: var(--cream);
    border: 2.5px solid var(--gray-900);
    border-radius: 12px 18px 14px 16px / 16px 12px 18px 14px;
    box-shadow: 3px 6px 0 color-mix(in srgb, var(--gray-900) 25%, transparent);
    padding-top: 30px;
}
.bw-bunting { position: absolute; left: 8px; right: 8px; top: -4px; height: 30px; width: calc(100% - 16px); }
.bw-face { display: flex; flex-direction: column; align-items: center; gap: 2px; font-size: 13px; width: 44px; }

/* a widget pinned on the board + its selected toolbar (Widgets.dc.html) */
.wgt-pin { position: absolute; }
/* everything on the board lives inside .canvas-pins (pointer-events: none) —
   the interactive bits opt back in, like the .pin class does */
.wgt-pin, .wgt-peek, .kit-drawer { pointer-events: auto; }
.wgt-pin.sel > .wgt-body { outline: 3px dashed var(--amber-500); outline-offset: 8px; border-radius: 12px; }
.wgt-pin.fresh::after {
    content: "new!";
    position: absolute;
    top: -14px;
    right: -8px;
    rotate: 6deg;
    background: var(--yellow-500);
    border: 2px solid var(--w-ink);
    border-radius: 10px;
    padding: 0 8px;
    font-size: 13px;
    color: var(--w-ink);
    z-index: 3;
    font-family: var(--font-hand, sans-serif);
}
.wgt-grab {
    position: absolute;
    inset: -6px;
    z-index: 2;
    border: none;
    background: transparent;
    cursor: grab;
    border-radius: 12px;
}
.wgt-grab:hover { background: color-mix(in srgb, var(--amber-500) 12%, transparent); }
.wgt-grab:focus-visible { outline: 3px solid var(--amber-500); }
.wgt-bar {
    position: absolute;
    left: 50%;
    top: -58px;
    translate: -50% 0;
    z-index: 5;
    display: flex;
    align-items: center;
    gap: 2px;
    padding: 3px 6px;
    background: var(--p-ink);
    color: var(--p-canvas);
    border: 2.5px solid var(--p-ink);
    border-radius: 22px 18px 22px 16px;
    box-shadow: var(--shadow-hard);
    white-space: nowrap;
}
.wgt-bar button {
    display: flex;
    align-items: center;
    gap: 5px;
    min-height: 40px;
    padding: 0 10px;
    border: none;
    background: none;
    color: inherit;
    font-size: 15px;
    cursor: pointer;
    border-radius: 16px;
    font-family: inherit;
}
.wgt-bar button:hover { background: color-mix(in srgb, var(--p-canvas) 15%, transparent); }
.wgt-bar .sep { width: 2px; height: 20px; background: color-mix(in srgb, var(--p-canvas) 30%, transparent); }

/* a map-only widget opened from the board map */
.wgt-peek {
    position: absolute;
    left: 6px;
    top: 6px;
    z-index: 60;
    padding: 34px 14px 14px;
    background: color-mix(in srgb, var(--w-paper) 92%, transparent);
    border: 2.5px solid var(--w-ink);
    border-radius: 14px 18px 12px 16px;
    box-shadow: 5px 6px 0 var(--w-shadow);
    max-width: min(320px, 90%);
}
.wgt-peek .hd {
    position: absolute;
    left: 12px;
    right: 6px;
    top: 4px;
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 13px;
    color: var(--w-ink-soft);
}
.wgt-peek .hd .ibtn { color: var(--w-ink); } /* the peek card takes the theme's paper */

/* the toolkit drawer hanging under the whiteboard's bottom edge (KitDrawer.dc.html):
   a flex item after the frame, its square top tucked under the frame's outer edge */
.kit-drawer {
    margin-top: 8px; /* the frame's aluminium ring */
    z-index: 30;
    display: flex;
    justify-content: center;
    flex-shrink: 0;
}
.kit-drawer-btn {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    height: 44px;
    padding: 0 18px 2px;
    box-sizing: border-box;
    border: 2.5px solid var(--gray-900);
    border-top: none;
    border-radius: 0 0 16px 14px / 0 0 14px 16px;
    background: var(--amber-200);
    box-shadow: 3px 4px 0 var(--w-shadow);
    cursor: pointer;
    color: var(--amber-950);
    transition: height .15s;
    font-family: var(--font-hand, sans-serif);
}
/* no hover nudge: the handle hangs off the board, and moving it opens a gap at the seam */
.kit-drawer-btn:focus-visible { outline: 3px solid var(--amber-500); outline-offset: 3px; }
.kit-drawer-btn.on { height: 52px; background-color: var(--hi-yellow); color: var(--ink); } /* the app's highlight style, not a plain yellow */
.kit-drawer-handle {
    display: grid;
    place-items: center;
    width: 34px;
    height: 14px;
    border: 2.5px solid var(--amber-950);
    border-top: none;
    border-radius: 0 0 10px 10px;
    margin-top: -4px;
}
.kit-drawer-btn.on .kit-drawer-handle { border-color: var(--gray-900); }
.kit-drawer-lbl { font-family: var(--font-marker, cursive); font-weight: 700; font-size: 23px; line-height: 1; }

/* toolkit widgets tab (Widgets.dc.html catalogue) */
.kit-types { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; }
.kit-type {
    position: relative;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 3px;
    padding: 8px;
    min-height: 84px;
    box-sizing: border-box;
    border: 2px solid var(--w-ink);
    border-radius: 12px 9px 13px 8px;
    background: var(--w-white);
    cursor: pointer;
    text-align: left;
    color: var(--w-ink);
    font-size: 16px;
    line-height: 1.05;
    font-family: inherit;
}
.kit-type:hover { background: var(--w-tint); box-shadow: 2px 2px 0 var(--w-shadow); transform: rotate(-.8deg); }
.kit-type small { font-size: 12.5px; color: var(--w-ink-soft); line-height: 1.15; }
.kit-type .sw { width: 26px; height: 26px; display: grid; place-items: center; border: 2px solid var(--w-ink); border-radius: 8px 6px 9px 5px; color: var(--gray-900); /* pastel chip in every theme, so its icon stays dark ink */ }
.kit-type.lock { opacity: .66; cursor: help; border-style: dashed; background: var(--w-gray1); }
.kit-type.lock:hover { background: var(--w-gray1); box-shadow: none; transform: none; }
.kit-ctape {
    display: inline-flex;
    align-items: center;
    font-size: 12px;
    line-height: 1.3;
    padding: 0 7px;
    background: var(--purple-100);
    color: var(--blue-900);
    rotate: -3deg;
    border-left: 2px dashed color-mix(in srgb, var(--black) 20%, transparent);
    border-right: 2px dashed color-mix(in srgb, var(--black) 20%, transparent);
    white-space: nowrap;
    margin-top: auto;
}
.kit-ctape.v { background: var(--green-200); color: var(--green-900); }

/* set-up pop-up (WidgetSetup.dc.html): desktop card with live preview, phone sheet */

/* The chrome around the widgets — toolkit tiles, the set-up pop-up, the peek card and
   the requests box — follows the app theme: paper, ink and soft text hang off these
   role pins, so dark mode recolours them together. The little paper objects themselves
   (the calendar, stickies, the kraft tag) keep the palette — physical paper stays light. */
.wgt-pin, .wgt-peek, .kit-drawer, .kit-types,
.wgtsetup, .reqbox {
    --w-ink: var(--line);
    --w-ink-soft: var(--ink-soft);
    --w-ink-faint: var(--ink-faint);
    --w-paper: var(--paper);
    --w-white: var(--surface);
    --w-bone: color-mix(in srgb, var(--ink) 10%, var(--paper));
    --w-gray1: color-mix(in srgb, var(--ink) 8%, var(--surface));
    --w-tint: color-mix(in srgb, var(--hi-yellow) 45%, var(--surface));
    --w-shadow: color-mix(in srgb, var(--black) 85%, var(--line));
}

.wgtsetup {
    position: relative;
    box-sizing: border-box;
    display: flex;
    flex-direction: column;
    background: var(--w-paper);
    color: var(--w-ink);
    font-family: var(--font-hand, system-ui, sans-serif);
    -webkit-font-smoothing: antialiased;
    max-height: min(660px, calc(100vh - 48px));
}
.wgtsetup.card {
    width: min(780px, calc(100vw - 48px));
    border: 2.5px solid var(--w-ink);
    border-radius: 14px 20px 16px 18px / 18px 14px 20px 16px;
    box-shadow: 6px 7px 0 var(--w-shadow);
}
.wgtsetup.sheet {
    border: 2.5px solid var(--w-ink);
    border-bottom: none;
    border-radius: 18px 22px 0 0;
    box-shadow: 0 -18px 40px color-mix(in srgb, var(--night-900) 25%, transparent);
    max-height: min(720px, calc(100vh - 90px));
}
.wgtsetup button, .wgtsetup input, .wgtsetup select { font-family: inherit; }
.wgtsetup-hd { display: flex; align-items: center; gap: 10px; padding: 14px 14px 10px 18px; border-bottom: 2px dashed color-mix(in srgb, var(--w-ink) 20%, transparent); }
.wgtsetup-sw { width: 38px; height: 38px; display: grid; place-items: center; border: 2px solid var(--w-ink); border-radius: 10px 8px 11px 7px; flex-shrink: 0; }
.wgtsetup-grab { display: flex; justify-content: center; padding: 8px 0 0; }
.wgtsetup-grab span { width: 56px; height: 6px; border-radius: 4px; background: color-mix(in srgb, var(--w-ink) 35%, transparent); }
.wgtsetup-body { flex: 1; min-height: 0; display: flex; gap: 18px; }
.wgtsetup-form { flex: 1; min-width: 0; overflow: auto; padding: 4px 18px 14px; }
.wgtsetup-prev {
    width: 320px;
    overflow-y: auto;
    flex-shrink: 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    padding: 14px 16px;
    box-sizing: border-box;
    border-left: 2px dashed color-mix(in srgb, var(--w-ink) 20%, transparent);
    background: var(--w-gray1);
    background-image: radial-gradient(color-mix(in srgb, var(--w-ink) 14%, transparent) 1.1px, transparent 1.5px);
    background-size: 22px 22px;
}
.wgtsetup-prev .cap { font-family: var(--font-marker, cursive); font-weight: 700; font-size: 20px; color: var(--w-ink-soft); align-self: flex-start; margin-top: 4px; }
.wgtsetup .lbl { display: block; font-family: var(--font-marker, cursive); font-weight: 700; font-size: 21px; margin: 14px 0 6px; color: inherit; }
.wgtsetup .lbl small { font-family: var(--font-hand, sans-serif); font-weight: 400; font-size: 13px; color: var(--w-ink-soft); margin-left: 6px; }
.wgtsetup-in {
    width: 100%;
    min-height: 44px;
    font-size: 16px;
    padding: 4px 12px;
    box-sizing: border-box;
    color: var(--w-ink);
    background: var(--w-white);
    border: 2px solid var(--w-ink);
    border-radius: 185px 25px 145px 20px / 20px 155px 25px 175px;
}
.wgtsetup-in:focus { outline: 3px solid var(--amber-500); outline-offset: 1px; }
.wgtsetup-pick { position: relative; display: block; }
.wgtsetup-pick select { appearance: none; -webkit-appearance: none; padding-right: 40px; cursor: pointer; }
.wgtsetup-pick .chev { position: absolute; right: 14px; top: 50%; translate: 0 -50%; pointer-events: none; color: var(--w-ink); }
.wgtsetup-where { align-self: stretch; margin-top: 8px; padding: 8px 10px 10px; border: 2.5px solid var(--w-ink); border-radius: 14px 18px 12px 16px; background: var(--w-tint); }
.wgtsetup-where .lbl { margin-top: 0; }
.wgtsetup-opt {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    width: 100%;
    min-height: 48px;
    padding: 6px 10px;
    box-sizing: border-box;
    margin-top: 6px;
    border: 2px solid var(--w-ink);
    border-radius: 12px 9px 13px 8px;
    background: var(--w-white);
    font-size: 16px;
    color: var(--w-ink);
    text-align: left;
    cursor: pointer;
    line-height: 1.15;
}
.wgtsetup-opt small { display: block; font-size: 13px; color: var(--w-ink-soft); }
.wgtsetup-opt .dot { width: 20px; height: 20px; border-radius: 50%; border: 2.5px solid var(--w-ink); box-sizing: border-box; flex-shrink: 0; margin-top: 1px; background: var(--w-white); }
.wgtsetup-opt.on { background: var(--w-paper); box-shadow: 3px 3px 0 var(--w-shadow); }
.wgtsetup-opt.on .dot { background: radial-gradient(circle, var(--w-ink) 0 4px, var(--yellow-500) 4.5px); }
.wgtsetup-foot { display: flex; align-items: center; gap: 8px; padding: 12px 18px 14px; border-top: 2px dashed color-mix(in srgb, var(--w-ink) 20%, transparent); }
.wgtsetup-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    min-height: 44px;
    padding: 2px 16px;
    box-sizing: border-box;
    font-size: 16px;
    border: 2.5px solid var(--w-ink);
    border-radius: 255px 15px 225px 15px / 15px 225px 15px 255px;
    background: var(--w-paper);
    color: var(--w-ink);
    box-shadow: 2px 2px 0 var(--w-shadow);
    cursor: pointer;
}
.wgtsetup-btn.primary { background: var(--navy); color: var(--amber-200); }
.wgtsetup-btn.ghost { background: transparent; box-shadow: none; border-style: dashed; }
.wgtsetup-btn.danger { color: var(--red-800); border-color: var(--red-800); box-shadow: none; background: transparent; }
.wgtsetup-btn:disabled { opacity: .5; cursor: default; }
.wgtsetup-btn:hover:not(:disabled) { transform: translate(-1px, -1px) rotate(-.6deg); box-shadow: 3px 3px 0 var(--w-shadow); }
.wgtsetup-btn.ghost:hover:not(:disabled), .wgtsetup-btn.danger:hover:not(:disabled) { transform: translate(-1px, -1px) rotate(-.6deg); box-shadow: none; }
.wgtsetup-err { font-size: 13px; color: var(--w-ink-soft); }
.wgtsetup-maprow { display: flex; align-items: center; gap: 8px; width: 100%; min-height: 38px; padding: 2px 10px; box-sizing: border-box; border: 2px solid var(--w-ink); border-radius: 10px; background: var(--yellow-200); font-size: 16px; }
.wgtsetup-maprow .t { flex: 1; min-width: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.wgtsetup-maprow .m { font-size: 12px; padding: 0 7px; border-radius: 9px; background: var(--w-paper); border: 1.5px solid var(--w-ink); }
.wgtsetup-tip { margin-top: 10px; padding: 6px 10px; border: 2px dashed var(--w-ink-faint); border-radius: 12px; font-size: 13.5px; color: var(--w-ink-soft); line-height: 1.25; }

/* feature requests full list (RequestsBox — desktop card 800×640, phone sheet) */
.reqbox {
    position: relative;
    box-sizing: border-box;
    display: flex;
    flex-direction: column;
    background: var(--cream);
    color: var(--gray-900);
    font-family: var(--font-hand, system-ui, sans-serif);
    max-height: min(640px, calc(100vh - 60px));
}
.reqbox.card { border: 2.5px solid var(--gray-900); border-radius: 14px 20px 16px 18px / 18px 14px 20px 16px; box-shadow: 6px 7px 0 var(--gray-900); }
.reqbox.sheet { border: 2.5px solid var(--gray-900); border-bottom: none; border-radius: 18px 22px 0 0; box-shadow: 0 -18px 40px color-mix(in srgb, var(--night-900) 25%, transparent); max-height: calc(100vh - 90px); }
.reqbox button, .reqbox input, .reqbox textarea { font-family: inherit; }
.reqbox-hd { display: flex; align-items: center; gap: 10px; padding: 14px 14px 10px 18px; border-bottom: 2px dashed color-mix(in srgb, var(--gray-900) 20%, transparent); }
.reqbox-hd .mk { font-family: var(--font-marker, cursive); font-weight: 700; font-size: 30px; line-height: 1; }
.reqbox-tabs { display: flex; gap: 2px; padding: 6px 12px 0; border-bottom: 2.5px solid var(--gray-900); overflow-x: auto; }
.reqbox-tab {
    display: flex;
    align-items: center;
    gap: 5px;
    min-height: 40px;
    padding: 0 10px 2px;
    font-family: var(--font-marker, cursive);
    font-weight: 700;
    font-size: 19px;
    background: none;
    border: 2.5px solid transparent;
    border-bottom: none;
    color: var(--gray-700);
    cursor: pointer;
    border-radius: 12px 12px 0 0;
    position: relative;
    top: 2.5px;
    white-space: nowrap;
}
.reqbox-tab.on { color: var(--gray-900); background: var(--cream); border-color: var(--gray-900); }
.reqbox-tab .n { font-family: var(--font-hand, sans-serif); font-size: 12px; min-width: 18px; height: 18px; padding: 0 5px; box-sizing: border-box; border-radius: 9px; display: grid; place-items: center; background: color-mix(in srgb, var(--gray-900) 10%, transparent); }
.reqbox-body { flex: 1; min-height: 0; overflow: auto; padding: 6px 16px 14px; }
.req-row { display: flex; gap: 10px; align-items: flex-start; padding: 8px 4px; border-bottom: 1.5px dashed color-mix(in srgb, var(--gray-900) 15%, transparent); }
.req-row .t { flex: 1; min-width: 0; font-size: 16px; line-height: 1.15; }
.req-row .d { display: block; font-size: 13.5px; color: var(--gray-600); }
.req-row .meta { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; margin-top: 3px; }
.req-row .by { font-size: 12.5px; color: var(--gray-600); }
.req-row .note { font-size: 13.5px; color: var(--blue-900); background: var(--blue-100); border-radius: 8px; padding: 2px 8px; margin-top: 4px; display: inline-block; }
.req-row .merged { font-size: 12.5px; color: var(--gray-600); }
.req-acts { display: flex; gap: 4px; flex-wrap: wrap; }
.req-acts select { min-height: 34px; font-size: 14px; border: 2px solid var(--gray-900); border-radius: 10px; background: var(--white); color: var(--gray-900); padding: 0 6px; }
.req-mini {
    min-height: 34px;
    padding: 0 10px;
    font-size: 14px;
    border: 2px solid var(--gray-900);
    border-radius: 12px 9px 13px 8px;
    background: var(--cream);
    color: var(--gray-900);
    cursor: pointer;
}
.req-mini:hover { background: var(--yellow-100); }
.req-mini.danger { color: var(--red-800); border-color: var(--red-800); }
.reqbox-form { padding: 8px 0 2px; }
.reqbox-form .lbl { display: block; font-family: var(--font-marker, cursive); font-weight: 700; font-size: 21px; margin: 10px 0 4px; }
.reqbox-form textarea {
    width: 100%;
    min-height: 74px;
    font-size: 15px;
    padding: 8px 12px;
    box-sizing: border-box;
    color: var(--gray-900);
    background: var(--white);
    border: 2px solid var(--gray-900);
    border-radius: 20px 12px 22px 14px / 14px 22px 12px 20px;
    resize: vertical;
}
.reqbox-form textarea:focus { outline: 3px solid var(--amber-500); outline-offset: 1px; }
.req-already { margin-top: 8px; padding: 8px 10px; border: 2px dashed var(--gray-500); border-radius: 12px; }
.req-already .cap { font-size: 14px; color: var(--gray-700); display: block; margin-bottom: 4px; }
.req-foot { display: flex; align-items: center; gap: 8px; padding: 10px 18px 14px; border-top: 2px dashed color-mix(in srgb, var(--gray-900) 20%, transparent); }

@media (max-width: 759px) {
    .wgtsetup-body { flex-direction: column; }
    .wgtsetup-prev { display: none; }
}
@media (prefers-reduced-motion: reduce) {
    .bw-opt .fill { transition: none; }
    .bw-btn:hover, .kit-type:hover { transform: none; }
}
