:root{color-scheme:light;--paper:#f2eee5;--white:#fffdf8;--line:#dfd8ca;--ink:#232921;--muted:#535b50;--green:#263d32;--orange:#ad432b;--tint:#121a16;--safe:env(safe-area-inset-bottom,0px);font:15px/1.5 system-ui,"Noto Sans TC","PingFang TC","Microsoft JhengHei",sans-serif}
*{box-sizing:border-box}html{min-width:280px}body{margin:0;background:var(--paper);color:var(--ink)}button,input,select{font:inherit}button{cursor:pointer;touch-action:manipulation}button:disabled{cursor:not-allowed;opacity:.45}:focus-visible{outline:3px solid #ab492e;outline-offset:3px}button:focus:not(:focus-visible){outline:none}a{color:inherit}h1,h2,h3,p{margin:0}button[hidden],[hidden]{display:none!important}.svg-defs,.visually-hidden{position:absolute;inline-size:1px;block-size:1px;overflow:hidden;clip-path:inset(50%);white-space:nowrap}.icon{width:20px;height:20px;flex:none;fill:none;stroke:currentColor;stroke-width:1.75;stroke-linecap:round;stroke-linejoin:round}.icon use{pointer-events:none}
.mast{border-bottom:1px solid var(--line);background:var(--white)}.mast-inner{max-width:1160px;margin:auto;height:68px;padding:0 24px;display:flex;align-items:center;justify-content:space-between;gap:8px}.brand{display:flex;align-items:center;gap:11px;text-decoration:none;line-height:1.12}.brand strong,.brand small{display:block}.brand strong{font-size:17px;letter-spacing:.04em}.brand small{font-size:9px;font-weight:790;color:var(--muted);letter-spacing:.23em;margin-top:5px}.mark{display:grid;place-items:center;width:38px;height:38px;border-radius:9px;background:var(--green);color:#fffaf0}.mark .icon{width:25px;height:25px}.install{border:1px solid var(--line);background:transparent;border-radius:20px;display:flex;align-items:center;gap:6px;color:var(--green);padding:0 12px;min-height:42px;font-size:13px;font-weight:720;white-space:nowrap}.install .icon{width:16px;height:16px}
main{max-width:1160px;margin:auto;padding:0 24px calc(138px + var(--safe))}.project{display:flex;align-items:end;justify-content:space-between;gap:14px;padding:25px 0 19px}.kicker{display:flex;gap:7px;align-items:center;font-size:11px;color:var(--orange);letter-spacing:.14em;font-weight:820}.kicker i,.stage-bar i{width:6px;height:6px;background:#e58462;display:inline-block;border-radius:50%}.project h1{font-size:35px;letter-spacing:-.04em;line-height:1.14;margin-top:4px}.project p{font-size:12px;color:var(--muted);margin-top:5px}.mode{display:flex;padding:3px;border-radius:13px;background:#e8e3d8;border:1px solid #ded7ca;gap:2px;flex:none}.mode button,.navigation button{display:flex;gap:6px;align-items:center;justify-content:center;border:0;background:transparent;white-space:nowrap;color:var(--muted);font-weight:720}.mode button{border-radius:9px;padding:0 10px;min-height:38px;font-size:13px}.mode .icon{width:16px;height:16px}.mode button[aria-pressed=true]{color:#fffaf0;background:var(--green)}
.navigation{display:flex;gap:7px;margin-bottom:12px;border-bottom:1px solid var(--line)}.navigation button{position:relative;padding:0 13px;min-height:46px;color:var(--muted);font-size:14px}.navigation button[aria-selected=true]{color:var(--green);font-weight:850}.navigation button[aria-selected=true]::after{position:absolute;content:"";bottom:-1px;left:8px;right:8px;height:3px;border-radius:3px 3px 0 0;background:var(--orange)}.navigation .icon{width:17px;height:17px}#routeCount{font-size:10px;background:#e8ded0;border-radius:10px;padding:1px 5px}.work{display:grid;grid-template-columns:minmax(0,1.34fr) minmax(0,.86fr);gap:16px;align-items:start}.navigation .nav-preview{display:none}.inspector{min-width:0}.panel{border:1px solid var(--line);background:var(--white);border-radius:16px;padding:20px;min-width:0}.stage{overflow:hidden;border-radius:17px;background:var(--tint);color:#fffaf0;min-width:0;border:1px solid #222d26}.stage-bar,.stage-foot{display:flex;align-items:center;gap:9px;padding:8px 13px;color:#d1d8d1;font-size:11px;min-height:49px}.stage-bar>span:first-child{display:flex;align-items:center;gap:7px;font-weight:760;color:#fffaf0}.stage-bar .dimensions{margin-left:auto;color:#c1cec4;letter-spacing:.045em;white-space:nowrap}.stage-bar button,.stage-foot button{border:1px solid #46554b;color:#fffaf0;background:#28352c;border-radius:8px;min-width:38px;height:36px;display:inline-flex;align-items:center;justify-content:center;gap:5px}.stage-bar button .icon,.stage-foot button .icon{width:16px;height:16px}.stage-body{min-height:380px;display:grid;place-items:center;padding:16px;position:relative;background:#26352c;background-image:repeating-radial-gradient(ellipse at 15% 85%,transparent 0 13px,#88a58a27 14px 15px,transparent 16px 26px),radial-gradient(ellipse at 38% 27%,#43604a,transparent 75%)}.poster-shell{padding:5px;border:1px solid #87958a77;background:#161f19;border-radius:12px;box-shadow:0 12px 32px #0b100bc0}.poster-shell canvas{display:block;block-size:clamp(365px,59vh,690px);inline-size:auto;max-inline-size:100%;border-radius:7px;aspect-ratio:9/16}.placeholder{text-align:center;display:grid;justify-items:center;gap:8px;padding:22px 14px;max-width:100%;z-index:1}.placeholder h2{font-size:27px;letter-spacing:-.04em}.placeholder p{color:#ebf0e7;font-size:13px}.placeholder .pin{display:grid;place-items:center;background:#f4e1cc;border:1px solid #ffeee0;color:#463526;border-radius:16px;width:56px;height:56px;margin-bottom:6px}.placeholder .pin .icon{width:28px;height:28px}.placeholder button{background:#fff5e4;color:var(--green);border:0;border-radius:9px;min-height:42px;padding:0 12px;display:flex;align-items:center;gap:9px;font-weight:790}.placeholder #demo{background:transparent;color:#fffaf0;text-decoration:underline;text-underline-offset:4px;min-height:38px;font-size:13px}.placeholder #startImport{margin-top:8px}.stage:not([data-has=true]) .poster-shell{display:none}.stage[data-has=true] .placeholder{display:none}.stage-foot{justify-content:space-between;min-height:51px}.stage-foot p{overflow-wrap:anywhere}.stage-foot button{font-size:11px;flex:none;padding:0 8px}#mapStatus.error{color:#ffd1b7}.stage-foot .retry{min-height:28px;height:auto;margin-left:4px}.notice:empty{display:none}.notice{margin:10px 0;color:var(--green);font-size:12px;background:#eef3eb;border-radius:7px;padding:8px 10px;overflow-wrap:anywhere}.notice.error{background:#fcf0e4;color:#812d18}
.section-title{display:flex;align-items:center;justify-content:space-between;gap:10px;margin-bottom:10px}.section-title h2{font-size:27px;letter-spacing:-.035em;line-height:1}.section-title p{font-size:11px;color:var(--orange);letter-spacing:.12em;font-weight:750;margin-bottom:5px}.icon-square{display:grid;place-items:center;color:#fffaf0;background:var(--green);width:43px;height:43px;border:0;border-radius:11px}.hint,.empty-list{color:var(--muted);font-size:13px}.empty-list{padding:17px 9px;margin:13px 0;border:1px dashed var(--line);text-align:center;border-radius:9px}.panel ul{padding:0;margin:11px 0 0;list-style:none}.panel li{display:flex;gap:8px;align-items:center;border-bottom:1px solid var(--line);padding:8px 0}.panel li::before{content:"";width:8px;height:8px;border-radius:50%;background:#be5d40;flex:none;margin:0 4px}.panel li div{min-width:0;flex:1}.panel li strong,.panel li small{display:block;overflow-wrap:anywhere}.panel li small{color:var(--muted);font-size:12px}.panel li button{width:40px;height:40px;background:transparent;border:1px solid var(--line);border-radius:9px;color:var(--muted);font-size:20px}
.file-tools{border-top:1px solid var(--line);margin-top:15px;padding-top:13px}.file-tools h3{font-size:12px;color:var(--muted);letter-spacing:.08em}.file-tools button{display:flex;justify-content:space-between;align-items:center;width:100%;min-height:42px;border:0;border-bottom:1px solid var(--line);background:transparent;text-align:left;color:var(--green);padding-inline:0;font-size:13px;font-weight:720}.file-tools button .icon{width:15px;height:15px}.field{display:grid;gap:5px;font-size:13px;margin:12px 0;color:var(--ink);font-weight:680}.field input,.field select,.two input{width:100%;min-height:43px;height:auto;padding:8px 10px;border:1px solid var(--line);border-radius:9px;background:#f7f4ec;color:var(--ink);font-size:16px;font-weight:450}.looks,.two{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:8px}.looks button{border:1px solid var(--line);border-radius:9px;background:var(--white);padding:7px 8px;text-align:left;min-height:45px;color:var(--muted);display:flex;align-items:center;gap:7px;font-size:13px}.looks button[aria-pressed=true]{border-color:var(--green);background:#edf1e8;color:var(--green);font-weight:790}.looks i{width:14px;height:20px;border-radius:3px;background:#485c4a;border-bottom:6px solid #d99e78}.looks button:last-child i{background:#e8decb;border-bottom-color:#202b25}details{border-top:1px solid var(--line);margin-top:15px;padding-top:10px}summary{cursor:pointer;font-size:14px;font-weight:730}summary span{margin-left:4px;color:var(--muted);font-size:11px}details p{font-weight:450;font-size:12px;color:var(--muted);margin:8px 0}.two label{font-size:12px;display:grid;gap:4px;color:var(--muted)}.check{display:flex;align-items:center;gap:6px;min-height:40px;font-size:13px;color:var(--muted);margin-top:7px}.check input{accent-color:var(--green)}footer{color:var(--muted);display:flex;align-items:start;gap:7px;margin-top:15px;font-size:11px}footer .icon{width:15px;height:15px}
.action{position:fixed;z-index:3;bottom:0;left:0;right:0;padding-bottom:var(--safe);background:var(--white);border-top:1px solid var(--line);box-shadow:0 -4px 18px #1e262212}.action-inner{display:flex;align-items:center;justify-content:flex-end;gap:7px;padding:9px 24px;max-width:1160px;margin:auto}.action button,.primary{display:inline-flex;gap:7px;align-items:center;justify-content:center;min-height:48px;border-radius:9px;border:1px solid transparent;font-size:14px;font-weight:790;padding:0 14px;white-space:nowrap}.action-import,.action-share{border-color:var(--line)!important;background:#f4f0e7;color:var(--green)}.action-share{padding-inline:10px!important}.primary{background:var(--orange);color:#fffaf0}.dialog-close{width:42px;height:42px;display:grid;place-items:center;border:1px solid var(--line);border-radius:10px;background:transparent;color:var(--ink)}dialog{border:1px solid var(--line);border-radius:17px;width:min(calc(100% - 28px),390px);padding:19px;background:var(--white);color:var(--ink);box-shadow:0 18px 75px #162017a0}dialog::backdrop{background:#121a17aa}#installDialog .dialog-close{position:absolute;top:12px;right:12px}.dialog-mark{color:var(--green);margin-top:5px}.dialog-mark .icon{width:35px;height:35px}dialog h2{font-size:22px;margin:8px 0}dialog p{line-height:1.6;color:var(--muted);margin:0 0 13px}dialog .primary{width:100%}.fullscreen{background:#121a16;color:#fffaf0;width:min(calc(100% - 20px),520px);padding:10px;border-color:#46554b}.dialog-top{display:flex;align-items:center;justify-content:space-between;margin-bottom:7px}.dialog-top h2{font-size:15px;margin-left:4px}.fullscreen .dialog-close{color:#fffaf0;border-color:#46554b}.fullscreen img{display:block;max-width:100%;max-height:77vh;max-height:77dvh;aspect-ratio:9/16;object-fit:contain;margin:auto;border-radius:6px}
@media(max-width:730px){.mast-inner{height:56px;padding:0 14px}.mark{width:34px;height:34px}.brand{gap:8px}.brand strong{font-size:15px}.install{min-height:37px;font-size:12px}.project{align-items:center;padding:15px 0 11px;gap:5px}.project h1{font-size:26px}.project p{font-size:10px}.kicker{font-size:10px}.mode button{padding:0 7px;min-height:38px;font-size:12px}.mode .icon{width:15px;height:15px}main{padding:0 12px calc(98px + var(--safe))}.navigation{z-index:2;position:sticky;top:0;background:var(--paper);display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:0;margin-bottom:9px}.navigation .nav-preview{display:flex}.navigation button{min-height:44px;padding:0 5px;gap:5px;font-size:13px}.work{display:block}.stage-body{min-height:288px;padding:7px}.stage-bar,.stage-foot{min-height:43px;padding:5px 9px}.poster-shell canvas{block-size:clamp(275px,48svh,530px)}.panel{padding:15px}.stage{border-radius:13px}.action-inner{padding:8px 12px}.action-import{flex:1}.action .primary{flex:1.35}#workspace:not([data-tab=preview]) .stage{display:none}#workspace[data-tab=preview] .inspector{display:none}.placeholder h2{font-size:24px}}
@media(max-width:340px){.mode .icon{display:none}.mode button{padding:0 6px}.action button{padding:0 8px;gap:4px;font-size:13px}.action .icon{width:17px;height:17px}}
@media(max-width:730px) and (max-height:570px){.stage-body{min-height:220px}.poster-shell canvas{block-size:260px}}
@media(prefers-reduced-motion:no-preference){button{transition:background-color .16s,color .16s,opacity .16s}.panel:not([hidden]),.stage{animation:appear .22s ease-out both}@keyframes appear{from{opacity:.55;transform:translateY(4px)}to{opacity:1;transform:none}}}

/* 預覽回到紙張展台：拿掉仿手機外框，並把切換風格、心率放在圖卡旁。 */
.stage{background:#fffdf8;color:#26302a;border:1px solid #ddd6c8;box-shadow:0 12px 30px #42382a14}
.stage-bar,.stage-foot{color:#535d55}
.stage-bar>span:first-child{color:#262e28;font-size:14px}
.stage-bar .dimensions{color:#59645c;font-size:11px}
.stage-bar button,.stage-foot button{color:#263d32;background:#fffdf8;border-color:#dcd5c7}
.stage-body{background-color:#e7e4db;background-image:linear-gradient(45deg,#f6f3e880,transparent 65%),radial-gradient(#99948670 .7px,transparent .8px);background-size:auto,14px 14px;padding:14px 12px 17px}
.poster-shell{appearance:none;display:block;border:0;border-radius:12px;padding:0;background:#131c16;box-shadow:0 2px 7px #2b252746,0 14px 34px #2e271b38;max-width:100%;overflow:hidden}
.poster-shell:disabled{opacity:1;cursor:default}
.poster-shell canvas{block-size:clamp(420px,66svh,730px);max-inline-size:100%;border-radius:11px}
.stage .placeholder{color:#28302b}
.stage .placeholder p{color:#505b53}
.stage .placeholder #startImport{background:#263d32;color:#fffdf8}
.stage .placeholder #demo{color:#344f41}
.stage .placeholder .pin{background:#f5f0e3;border-color:#ddd3bf;color:#213c2c}
.preview-controls{display:flex;gap:7px;justify-content:space-between;align-items:center;padding:9px 11px 5px}
.preview-looks{display:flex;gap:5px;flex-wrap:wrap;min-width:0}
.preview-controls button{color:#263d32;background:#fbf9f2;border:1px solid #e2dbce;border-radius:8px;min-height:40px;font-size:12px;font-weight:720;display:flex;align-items:center;justify-content:center;gap:5px;padding:0 7px;white-space:nowrap}
.preview-controls button i{width:7px;height:14px;border-radius:2px;flex:none;background:#6f8167}
.preview-controls [data-preview-look="minimal"] i{background:#282f2b}
.preview-controls [data-preview-look="sport"] i{background:#b4d64b}
.preview-controls button[aria-pressed=true]{border-color:#284537;background:#edf1e8;color:#213a2b}
#quickHeart .icon{width:16px;height:16px}
#quickHeart[aria-pressed=true]{border-color:#a94967;background:#fff0f3;color:#87254b}
.stage-foot{border-top:1px solid #e9e3d7;margin-top:4px}
.stage-foot #mapStatus.error{color:#822a22}
.looks{grid-template-columns:repeat(3,minmax(0,1fr))}
.looks [data-look="minimal"] i{background:#e8decb;border-bottom-color:#202b25}
.looks [data-look="sport"] i{background:#263b4d;border-bottom-color:#c4e65a}
.fullscreen{padding:9px;background:#1f2923;width:min(calc(100% - 10px),540px)}
.fullscreen img{max-height:84vh;max-height:84dvh}
@media(max-width:730px){
 .poster-shell canvas{block-size:clamp(330px,54svh,620px);inline-size:auto}
 .stage-body{padding:9px 7px 12px}
 .stage-bar button{min-width:42px;height:38px}
 .preview-controls{padding:7px 6px 3px;gap:4px}
 .preview-controls button{font-size:11px;padding:0 5px}
 .preview-looks{gap:3px}
}
@media(max-width:340px){.preview-controls button i{display:none}.preview-controls button{padding:0 4px}.looks button{padding:6px 4px;font-size:12px}}
@media(max-width:730px) and (max-height:570px){.poster-shell canvas{block-size:280px}}

/* 改成薄工具列和整張 9:16 預覽，換底圖不用翻到設定。 */
.stage{border-radius:14px;box-shadow:0 5px 19px #241d1312}
.stage-bar{min-height:42px;padding:4px 11px}
.stage-bar>span:first-child{font-size:14px;letter-spacing:.025em}
.stage-bar .dimensions{font-variant-numeric:tabular-nums;font-size:10px}
.stage-bar button{min-width:36px;height:32px}
.preview-map{border-block:1px solid #eee7da;display:flex;gap:7px;align-items:center;padding:5px 10px;background:#f8f5ee;color:#415346;font-size:12px;font-weight:750}
.preview-map>span{margin-left:auto;font-size:11px;font-weight:500;color:#5c6b61;white-space:nowrap}
.preview-map select{min-height:36px;border:1px solid #d8d1c3;border-radius:8px;background:#fffdf8;color:#223a2b;padding-inline:7px;max-width:min(60%,210px);font-size:14px}
.stage-body{background-color:#eae6da;background-image:none;padding:14px 9px}
.poster-shell{box-shadow:0 9px 19px #1b22172c}
.stage-foot{padding:5px 10px;min-height:37px}
.stage-foot>button{height:30px;border:none;background:transparent;padding:0 3px}
#mapStatus{font-size:11px}
.preview-controls{border-top:1px solid #ede6d9;padding:7px 10px 2px}
@media(max-width:730px){.project{padding-block:12px 8px}.project .kicker{display:none}.navigation{margin-bottom:7px}.stage-bar{min-height:39px}.stage-body{padding-block:8px 9px}.poster-shell canvas{block-size:clamp(310px,53svh,620px)}}
@media(max-width:350px){.preview-map>span{display:none}.preview-map select{max-width:unset}.preview-controls{padding-inline:5px}}
