/* Folioの紙と手書き文字を引き継ぎ、右ページ内だけに収める。 */
#rightAppsPanel {display:block;position:relative;min-height:0;overflow:hidden}
#rightAppsPanel[hidden],#rightAppsPanel>[hidden] {display:none!important}
.folio-wheel {--fw-paper:var(--ref-sheet,#fff9ef);--fw-ink:var(--ref-ink,#24241e);--fw-muted:#756b5d;--fw-sage:var(--ref-sage,#d7d9b0);--fw-line:#b5a38166;--fw-peach:var(--ref-peach,#f3cabb);position:relative;container-type:size;height:100%;min-height:0;display:grid;grid-template-rows:30px minmax(120px,1fr) minmax(138px,31%) 52px;gap:6px;color:var(--fw-ink);font-family:var(--body);user-select:none;-webkit-user-select:none;overflow:hidden}
.folio-wheel [hidden] {display:none!important}
.folio-wheel button {border:0;background:none;color:inherit;cursor:pointer;font:inherit;touch-action:manipulation}
.folio-wheel button:disabled {opacity:.28;cursor:default}
.folio-wheel button:focus-visible,.fw-wheel:focus-visible {outline:2px solid #65816b;outline-offset:3px}
.fw-heading {display:flex;align-items:center;justify-content:space-between;padding:0 6px;font-size:clamp(11px,2.7cqw,15px);color:var(--fw-muted)}
.fw-count {font-size:11px}
.fw-stage {position:relative;min-height:0;overflow:hidden}
.fw-orbit {position:absolute;inset:0}
.folio-wheel .fw-card {position:absolute;display:flex;align-items:center;justify-content:center;width:clamp(50px,18cqw,94px);height:clamp(50px,18cqw,94px);padding:0;will-change:transform;isolation:isolate}
.folio-wheel .fw-card .app-tile {width:100%!important;height:100%!important;max-width:none!important;aspect-ratio:1;border:3px solid var(--fw-paper);background-color:var(--fw-paper);border-radius:20%!important;box-shadow:4px 7px 12px #715b3724;overflow:hidden;display:grid;place-items:center;font-size:32px}
.folio-wheel .fw-card .app-tile img,.folio-wheel .fw-card .app-tile svg {width:100%!important;height:100%!important;object-fit:contain}
.fw-card-name {position:absolute;right:calc(100% + 10px);width:clamp(74px,22cqw,140px);text-align:right;font-size:clamp(11px,3.1cqw,16px);line-height:1.3;overflow-wrap:anywhere}
.fw-card.is-selected .fw-card-name {visibility:hidden}
.fw-copy {position:absolute;left:2%;top:39%;width:61%;pointer-events:none;z-index:12}
.fw-copy h2 {margin:0;font:500 clamp(19px,6cqw,34px)/1.22 var(--body);letter-spacing:-.04em;overflow-wrap:anywhere;display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical;overflow:hidden}
.fw-copy p {margin:10px 0 0;font-size:clamp(11px,2.8cqw,14px);color:var(--fw-muted)}
.fw-bars {margin-top:15px;display:flex;align-items:end;gap:5px;height:36px;border-left:1px solid var(--fw-line);padding-left:10px;opacity:.62}
.fw-bars i {width:6px;height:70%;background:repeating-linear-gradient(to top,#929879 0 4px,transparent 4px 6px)}
.fw-bars i:nth-child(2n) {height:50%}.fw-bars i:nth-child(3n) {height:95%}
.fw-shortcuts {display:flex;justify-content:space-around;align-items:center;padding:0 7%}
.folio-wheel .fw-shortcuts button {width:42px;height:42px;border-radius:50%;border:1px solid #fffaf1;background:var(--fw-paper);box-shadow:3px 4px 8px #6e56341c,-2px -2px 5px #fffdf3;font:26px/1 var(--body);color:var(--fw-muted)}
.folio-wheel .fw-shortcuts button:last-child {background:var(--fw-peach);color:#564838}
.fw-wheel-row {display:grid;place-items:center;min-height:0}
.fw-wheel {width:min(57cqw,30cqh,230px);height:min(57cqw,30cqh,230px);min-width:136px;min-height:136px;border-radius:50%;border:1px solid #fffdfa;position:relative;touch-action:none;background:radial-gradient(circle at 32% 24%,#fffdf7,#f0e8d7);box-shadow:6px 9px 18px #6c54321a,inset 1px 2px 4px #fffdf8;color:var(--fw-muted)}
.folio-wheel .fw-wheel button {position:absolute;min-width:32px;min-height:32px;padding:0;display:grid;place-items:center;touch-action:none;font-size:clamp(11px,2.8cqw,16px)}
.fw-menu {top:2%;left:50%;transform:translateX(-50%);letter-spacing:.08em}
.fw-prev {left:4%;top:50%;transform:translateY(-50%);letter-spacing:-4px;padding-right:4px!important}
.fw-next {right:4%;top:50%;transform:translateY(-50%);letter-spacing:-4px;padding-right:4px!important}
.fw-play {bottom:3%;left:50%;transform:translateX(-50%);font-size:24px!important}
.folio-wheel .fw-center {top:50%;left:50%;transform:translate(-50%,-50%);width:37%;height:37%;border-radius:50%;background:var(--fw-paper);box-shadow:3px 7px 12px #76644029,inset 1px 2px 2px #fffdfa;border:1px solid #fffaf0}
.fw-footer {display:flex;align-items:center;justify-content:space-between;padding:0 5px}
.folio-wheel .fw-list-switch {display:flex;align-items:center;gap:7px;min-height:40px;padding:6px 10px;border-radius:24px;background:var(--fw-paper);border:1px solid #fffdfa;box-shadow:2px 3px 7px #78623d22;font-size:12px}
.folio-wheel .fw-list-switch svg {width:15px!important;height:15px!important;fill:none;stroke:currentColor;stroke-width:1.5}
.fw-list-switch i {width:29px;height:17px;border-radius:12px;background:var(--fw-sage);box-shadow:inset 1px 1px 3px #50493333;position:relative}
.fw-list-switch i::after {content:"";position:absolute;top:2px;left:2px;width:13px;height:13px;border-radius:50%;background:#fffdf7;transition:transform .15s}
.fw-list-switch[aria-expanded=true] i::after {transform:translateX(12px)}
.fw-position {color:var(--fw-muted);font-size:12px}
.fw-list {position:absolute;inset:0;display:flex;flex-direction:column;background:var(--fw-paper);background-image:var(--ref-texture);padding:8px 9px;border:1px solid var(--fw-line);border-radius:5px 10px 6px 5px}
.fw-list header {display:flex;align-items:center;justify-content:space-between;flex:none;border-bottom:1px dashed var(--fw-line);padding-bottom:6px}
.fw-list h2 {margin:0;font:500 17px var(--body)}
.fw-list header button {min-height:32px;padding:4px 9px;border-radius:15px;background:var(--fw-sage)}
.fw-list-grid {display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:12px 7px;padding:12px 0;align-content:start;overflow:auto;overscroll-behavior:contain;min-height:0}
.fw-list-grid>button {min-width:0;display:flex;flex-direction:column;align-items:center;gap:6px;padding:0}
.folio-wheel .fw-list-grid .app-tile {width:clamp(40px,12cqw,62px)!important;height:clamp(40px,12cqw,62px)!important;max-width:100%!important;display:grid;place-items:center;font-size:24px}
.fw-list-grid>button>span:last-child:not(.app-tile) {font-size:11px;line-height:1.35;overflow-wrap:anywhere;text-align:center}
.fw-empty {position:absolute;inset:10% 5%;display:grid;place-content:center;text-align:center;font-size:16px}
.fw-empty button {padding:10px 14px;background:var(--fw-sage);border-radius:5px;margin:auto;min-height:40px}
@container (max-height:550px) {.folio-wheel .fw-bars {display:none}.folio-wheel .fw-copy p {margin-top:5px}.folio-wheel .fw-card {width:clamp(44px,14cqw,70px);height:clamp(44px,14cqw,70px)}}
@media(prefers-reduced-motion:reduce) {.fw-list-switch i::after {transition:none}.fw-card {will-change:auto}}

/* アイコン画像がないアプリも、頭文字を紙の上ではっきり読めるようにする。 */
.folio-wheel .app-tile.app-initial {color:var(--fw-ink);background:var(--fw-sage);font-weight:600}

/* 移動は合成レイヤーの座標だけで行う。回転中だけGPUへの準備を指定する。 */
.folio-wheel .fw-card {left:0;top:0;will-change:auto}
.folio-wheel.is-moving .fw-card:not([hidden]) {will-change:transform}
.folio-wheel .fw-shortcuts button {width:44px;height:44px}
.folio-wheel .fw-wheel button {min-width:44px;min-height:44px}
.folio-wheel .fw-list-switch {min-height:44px}
.folio-wheel .fw-list header button {min-height:40px}
.folio-reference button,.folio-reference a,.folio-reference [role=button] {touch-action:manipulation;-webkit-tap-highlight-color:transparent}
.folio-reference .fw-wheel,.folio-reference .fw-wheel button {touch-action:none}

/* 一覧は右ページ全体に。撮影の隣を空け、切替を紙面の左下へ置く。 */
.folio-reference .ref-right:has(>#rightAppsPanel:not([hidden])) {padding-left:8px;padding-right:8px;padding-bottom:4px}
.fw-heading .fw-count {margin-left:auto;margin-right:12px}
.fw-heading>button {min-height:30px;padding:2px 8px!important;font-size:12px}
.fw-footer {padding:0 90px 4px 0;gap:8px}
.fw-position {white-space:nowrap}
.folio-wheel>.fw-list {inset:0 0 56px;z-index:30;padding:12px;border:0}
.folio-wheel.is-list-mode {grid-template-rows:minmax(0,1fr) 52px}
.folio-wheel.is-list-mode>.fw-heading,.folio-wheel.is-list-mode>.fw-stage,.folio-wheel.is-list-mode>.fw-wheel-row {display:none}
.folio-wheel.is-list-mode>.fw-footer {grid-row:2}
.fw-list header>div {display:flex;gap:8px}
.fw-list-grid {flex:1}
.folio-wheel .fw-center svg {width:22px!important;height:22px!important;fill:none;stroke:currentColor;stroke-width:1.5}
#captureHelpDialog {width:min(400px,calc(100vw - 32px));padding:24px;border:1px solid #b5a381;border-radius:10px;background:#fff8ec;color:#514b3c;font-family:var(--body)}
#captureHelpDialog h2 {margin-top:0;font-size:20px}
#captureHelpDialog p {line-height:1.8}
#captureHelpDialog a {display:block;padding:12px;background:#d8dcb9;color:#304736;border-radius:5px;text-align:center}
#captureHelpDialog a[hidden] {display:none}
#captureHelpDialog form {margin-top:16px;text-align:right}
#captureHelpDialog button {min-height:44px;padding:8px 18px}
