/* Two-phone section (#experience): a live replica of the app's home screen. Owned by js/x/duo.js.
   Page tokens come from x.css; the phone SCREENS use the app's own tokens (DESIGN.md light theme). */

.duo { --pw: clamp(240px, min(23vw, 34vh), 320px); padding: 11vh var(--g) 9vh; background: var(--paper-2); border-radius: calc(var(--r) * 2); margin: 0 calc(var(--g) * .5); display: flex; flex-direction: column; }
.duo-head { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 380px); gap: 16px 48px; align-items: end; order: 0; }
.duo-head .h2 { font-size: clamp(40px, 5.2vw, 84px); }
.duo-head .kick { grid-column: 1 / -1; margin-bottom: 0; }
.duo-head .h2 em { color: var(--sage-text); }
.duo-note { color: var(--ink-2); }
.duo-stage { order: 1; position: relative; display: flex; justify-content: center; align-items: flex-start; margin: 56px 0 30px; --s: .8; }
.duo-ctl { order: 2; display: flex; flex-wrap: wrap; justify-content: center; gap: 10px; max-width: 900px; margin: 0 auto; }
.duo-bar { order: 3; display: flex; flex-wrap: wrap; align-items: baseline; justify-content: center; gap: 8px 28px; margin: 22px auto 0; max-width: 900px; text-align: center; }
.duo-fine { color: var(--mute); font-size: 14px; line-height: 1.45; max-width: 560px; }
.duo-links { display: flex; gap: 22px; flex-wrap: wrap; justify-content: center; }
.duo-link { font-size: 14px; color: var(--sage-text); text-decoration: underline; text-underline-offset: 3px; text-decoration-thickness: 1px; padding: 8px 2px; min-height: 36px; }
.duo-link:hover { color: var(--ink); }
.duo-link[hidden] { display: none; }
.duo-switch { order: 1; display: none; }

/* ---------------------------------------------------------------- phones */
.dphone { position: relative; z-index: 1; width: var(--pw); flex: none; transition: transform .4s var(--ease); }
.dphone[data-side="a"] { transform: rotate(-3deg); transform-origin: 50% 80%; }
.dphone[data-side="b"] { transform: rotate(3deg); transform-origin: 50% 80%; }
.dscreen { position: relative; aspect-ratio: 360 / 780; border-radius: clamp(22px, 2.6vw, 38px); border: clamp(5px, .55vw, 8px) solid var(--night); background: var(--night); overflow: hidden; box-shadow: 0 50px 90px -46px rgba(27, 30, 26, .6); }
.dphone.shake .dscreen { animation: dvib .55s linear; }
@keyframes dvib { 0%, 100% { transform: none; } 10% { transform: translate(-5px, 1px) rotate(-.6deg); } 22% { transform: translate(5px, -1px) rotate(.6deg); } 34% { transform: translate(-4px, 1px); } 46% { transform: translate(4px, 0); } 60% { transform: translate(-2px, 0); } 75% { transform: translate(2px, 0); } }
.dview { position: absolute; inset: 0; overflow: hidden; background: #F9F9F6; }
.dview .dposter { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; object-position: 50% 0; }
.drec { position: absolute; inset: 0; display: none; background: #F9F9F6; }
.duo-stage[data-mode="rec"] .drec { display: block; }
.drec video, .drec .dposter { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; object-position: 50% 0; }
.drec video { opacity: 0; transition: opacity .3s; }
.drec.playing video { opacity: 1; }
.duo-stage[data-mode="rec"] .app { visibility: hidden; }
.dphone figcaption { margin-top: 16px; display: flex; flex-direction: column; gap: 4px; text-align: center; }
.dphone figcaption .mono { color: var(--mute); }
.dsay { display: none; font: 400 20px/1.2 var(--serif); min-height: 1.2em; transition: color .3s; }
.duo-stage[data-mode="rec"] .dsay { display: block; }
.dsay.hot { color: var(--sage-text); }

/* the dotted thread between the phones, at the height of the thread row on the screens */
.dthread { position: relative; z-index: 0; flex: none; width: clamp(70px, 11vw, 190px); height: 40px; margin-top: calc(var(--pw) * .39 - 13px); }
.dline { position: absolute; left: -6px; right: -6px; top: 19px; border-top: 2.5px dotted var(--sage); }
.dpop { position: absolute; left: 0; top: 12px; width: 14px; height: 14px; border-radius: 50%; background: var(--sand); box-shadow: 0 0 0 5px rgba(201, 180, 143, .28); opacity: 0; will-change: transform, opacity; }
.duo-stage[data-mode="rec"] .dpop { top: 12px; }

/* ---------------------------------------------------------------- chips */
.duo-ctl button { height: 46px; padding: 0 20px; border-radius: 46px; background: var(--card); border: 1px solid var(--rule); font-weight: 500; font-size: 15px; display: inline-flex; align-items: center; gap: 12px; transition: background .25s, color .25s, transform .25s var(--ease); }
.duo-ctl button .mono { color: var(--mute); transition: color .35s; }
.duo-ctl button:hover { background: var(--paper); }
.duo-ctl button:active { transform: scale(.97); }
.duo-ctl button[aria-pressed="true"] { background: var(--ink); color: var(--paper); }
.duo-ctl button[aria-pressed="true"] .mono { color: var(--glow); }

/* ================================================================ the app screen (360 x 780, scaled by --s) */
.app { --ap-paper: #F9F9F6; --ap-raised: #F1F2EC; --ap-ink: #292E27; --ap-2: #6B6F68; --ap-pres: #82977B; --ap-presT: #5E7357; --ap-warm: #B5A280; --ap-warmT: #7A6440; --ap-div: #E3E4DE;
  position: absolute; left: 0; top: 0; width: 360px; height: 780px; transform-origin: 0 0; transform: scale(var(--s, .8)); background: var(--ap-paper); color: var(--ap-ink);
  font: 400 14px/1.3 var(--sans); overflow: hidden; -webkit-tap-highlight-color: transparent; user-select: none; -webkit-user-select: none; }
.app button { font: inherit; color: inherit; cursor: pointer; }
.app p, .app ul, .app h3 { margin: 0; }
.app :focus-visible { outline: 2px solid var(--ap-presT); outline-offset: 2px; border-radius: 10px; }
.app .ic { width: 24px; height: 24px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; flex: none; }
.a-scroll { position: absolute; inset: 0 0 118px 0; overflow-y: auto; overflow-x: hidden; scrollbar-width: none; padding: 0 16px 20px; overscroll-behavior-y: contain; }
.a-scroll::-webkit-scrollbar { display: none; }
.a-head { height: 56px; padding-top: 8px; display: flex; align-items: center; gap: 12px; }
.a-logo { width: 118px; height: 22px; margin-right: auto; }
.a-hic { width: 38px; height: 38px; border-radius: 50%; display: grid; place-items: center; }
.a-prof { background: var(--ap-raised); width: 34px; height: 34px; }
.a-hic .ic { width: 22px; height: 22px; }
.a-date { margin-top: 2px; font-size: 11px; letter-spacing: .09em; text-transform: uppercase; color: var(--ap-2); font-weight: 500; }
.a-tag { margin-top: 3px; font-size: 18px; font-weight: 500; letter-spacing: -.005em; }

.a-thread { display: grid; grid-template-columns: 64px 1fr 64px; align-items: start; margin-top: 12px; }
.a-who { display: flex; flex-direction: column; align-items: center; gap: 3px; }
.a-av { width: 54px; height: 54px; border-radius: 50%; display: grid; place-items: center; font-size: 22px; font-weight: 500; background: var(--ap-raised); color: var(--ap-ink); position: relative; flex: none; }
.a-ev .a-av, .a-msg .a-av { width: 30px; height: 30px; font-size: 13px; }
.a-av.pt { background: #D5DDD2; color: #3C4A38; }
.a-pav { border: 0; padding: 0; transition: transform .2s var(--ease); }
.a-pav:active { transform: scale(.94); }
.a-pav::before { content: ""; position: absolute; inset: -4px; border-radius: 50%; border: 2px solid transparent; transition: border-color .25s; }
.a-pav .a-ini { position: relative; z-index: 1; }
.a-dot { position: absolute; right: 0; bottom: 1px; width: 13px; height: 13px; border-radius: 50%; background: var(--ap-pres); border: 2px solid var(--ap-paper); z-index: 2; }
.a-snd { position: absolute; right: -2px; bottom: -2px; width: 22px; height: 22px; border-radius: 50%; background: var(--ap-pres); color: var(--ap-paper); display: none; place-items: center; border: 2px solid var(--ap-paper); z-index: 2; }
.a-snd .ic { width: 13px; height: 13px; stroke-width: 2; }
.a-pav::after { content: ""; position: absolute; inset: 0; border-radius: 50%; border: 2px solid var(--ap-warm); opacity: 0; pointer-events: none; }
.a-pav.pulse::after { animation: dpulse 1.5s ease-out; }
@keyframes dpulse { 0% { opacity: .9; transform: scale(1); } 100% { opacity: 0; transform: scale(1.7); } }
.a-nm { font-size: 12px; color: var(--ap-2); }
.a-mid { display: flex; flex-direction: column; align-items: center; min-width: 0; }
.a-wireh { position: relative; width: 100%; height: 54px; display: grid; place-items: center; }
.a-wire { width: 100%; height: 30px; }
.a-wire path { fill: none; stroke: var(--ap-pres); stroke-width: 1.6; vector-effect: non-scaling-stroke; }
.a-wire circle { fill: var(--ap-pres); }
.a-state { margin-top: 3px; font-size: 14px; font-weight: 500; color: var(--ap-2); min-height: 18px; text-align: center; transition: color .25s; }
.a-state.hot { color: var(--ap-presT); }
.a-hint { margin-top: 4px; text-align: center; font-size: 12.5px; color: var(--ap-2); }
.a-status { margin-top: 14px; text-align: center; font-size: 22px; line-height: 1.2; font-weight: 500; letter-spacing: -.01em; min-height: 27px; padding: 2px 4px; border-radius: 10px; }
.a-upd { margin-top: 12px; text-align: center; font-size: 13px; color: var(--ap-2); }
.a-dist { margin-top: 8px; display: flex; gap: 5px; align-items: center; justify-content: center; font-size: 13px; color: var(--ap-2); }
.a-dist .ic { width: 15px; height: 15px; }
.a-acts { margin-top: 12px; display: grid; grid-template-columns: repeat(3, 1fr); border-top: 1px solid var(--ap-div); border-bottom: 1px solid var(--ap-div); }
.a-act { position: relative; height: 66px; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 5px; background: none; border: 0; font-size: 13px; font-weight: 500; transition: background .2s; }
.a-act:active { background: var(--ap-raised); }
.a-act .ic { width: 22px; height: 22px; }
.a-try { position: absolute; z-index: 5; top: calc(100% + 3px); left: 8px; white-space: nowrap; background: var(--ap-ink); color: var(--ap-paper); font-style: normal; font-size: 12.5px; font-weight: 500; padding: 6px 11px; border-radius: 10px; display: none; pointer-events: none; }
.a-try::before { content: ""; position: absolute; left: 30px; top: -5px; width: 10px; height: 10px; background: var(--ap-ink); transform: rotate(45deg); border-radius: 2px; }
.app.hint .a-try { display: block; animation: dbob 1.6s ease-in-out infinite; }
@keyframes dbob { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(3px); } }
.app.hint .a-act:first-child .ic { color: var(--ap-presT); }
.app.hint .a-act:first-child::before { content: ""; position: absolute; left: 50%; top: 11px; width: 36px; height: 36px; margin-left: -18px; border-radius: 50%; border: 2px solid var(--ap-pres); animation: dring 1.6s ease-out infinite; pointer-events: none; }
@keyframes dring { 0% { transform: scale(.7); opacity: .95; } 100% { transform: scale(1.7); opacity: 0; } }

.a-sec { display: flex; align-items: center; justify-content: space-between; margin-top: 12px; height: 52px; }
.a-sec h3 { font-size: 18px; font-weight: 500; }
.a-add { display: inline-flex; align-items: center; gap: 8px; height: 52px; padding: 0 8px 0 12px; background: none; border: 0; font-size: 15px; font-weight: 500; border-radius: 12px; }
.a-add .ic { width: 20px; height: 20px; }
.a-add:active { background: var(--ap-raised); }
.a-cap { margin-top: 8px; font-size: 11px; letter-spacing: .09em; text-transform: uppercase; color: var(--ap-2); font-weight: 500; }
.a-captoday { margin-top: 10px; }
.a-plan { list-style: none; display: grid; grid-template-columns: 66px 1fr auto; gap: 0 4px; align-items: center; min-height: 52px; padding: 5px 0; border-radius: 10px; }
.a-plan time { font-size: 12.5px; font-weight: 500; color: var(--ap-presT); }
.a-ptxt b { display: block; font-size: 15.5px; font-weight: 500; }
.a-ptxt span { display: block; font-size: 12.5px; color: var(--ap-2); }
.a-ptxt em { font-style: normal; color: var(--ap-presT); font-weight: 500; }
.a-chk { width: 52px; height: 52px; background: none; border: 0; display: grid; place-items: center; }
.a-chk::before { content: ""; width: 20px; height: 20px; border: 2px solid var(--ap-ink); border-radius: 3px; display: block; }
.a-chk { position: relative; }
.a-chk.on::before { background: var(--ap-ink); }
.a-chk.on::after { content: ""; position: absolute; left: 50%; top: 50%; width: 5px; height: 10px; margin: -6px 0 0 -2px; border: solid var(--ap-paper); border-width: 0 2.5px 2.5px 0; transform: rotate(45deg); }
.a-pact { display: flex; flex-wrap: wrap; gap: 0 2px; margin: 2px 0 0 -10px; }
.a-pact button { height: 52px; padding: 0 10px; background: none; border: 0; font-size: 14.5px; font-weight: 500; color: var(--ap-presT); border-radius: 10px; }
.a-pact button:active { background: var(--ap-raised); }
.a-later, .a-today { list-style: none; padding: 0; }
.a-today > li { list-style: none; }
.a-ev { display: grid; grid-template-columns: 38px 1fr auto; align-items: center; min-height: 46px; gap: 0; }
.a-evt { display: flex; align-items: center; gap: 8px; font-size: 15px; }
.a-evt .ic { width: 20px; height: 20px; }
.a-evt.touch .ic { color: var(--ap-warmT); }
.a-ev time { font-size: 12px; color: var(--ap-2); }
.a-msg { display: grid; grid-template-columns: 38px 1fr; padding: 8px 0 6px; align-items: start; }
.a-meta { font-size: 12.5px; color: var(--ap-2); }
.a-meta b { font-weight: 600; color: var(--ap-ink); }
.a-txt { margin-top: 2px; font-size: 15.5px; line-height: 1.3; }
.a-vpill { margin-top: 5px; display: flex; align-items: center; gap: 9px; height: 42px; padding: 0 8px; border-radius: 14px; background: var(--ap-raised); font-size: 12.5px; color: var(--ap-2); }
.a-vpill .ic:first-child { width: 26px; height: 26px; color: var(--ap-ink); }
.a-vpill .ic:last-child { width: 18px; height: 18px; }
.a-sub { margin-top: 4px; font-size: 12.5px; color: var(--ap-2); }
.a-today > .new, .a-later > .flash { animation: dnew .6s var(--ease); }
@keyframes dnew { 0% { opacity: 0; transform: translateY(-8px); background: rgba(130, 151, 123, .22); } 40% { opacity: 1; background: rgba(130, 151, 123, .22); } 100% { background: transparent; } }
.a-later > .flash, .a-status.flash { animation: dflash 1.1s ease-out; }
@keyframes dflash { 0% { background: rgba(130, 151, 123, .3); } 100% { background: transparent; } }
.a-later > li:focus { outline: none; }

/* waveform bars (the thread while talking, the dock, voice rows) */
.a-bars { display: flex; align-items: center; justify-content: center; gap: 3px; height: 30px; }
.a-bars i { width: 3px; height: 100%; border-radius: 2px; background: var(--ap-pres); transform: scaleY(var(--h, .5)); }
.a-bars.wave { position: absolute; inset: 0; display: none; gap: 4px; }
.a-bars.wave i { width: 3px; height: 28px; }
.a-bars.dl, .a-bars.dr { position: absolute; top: 20px; display: none; width: 112px; gap: 4px; }
.a-bars.dl { left: 20px; justify-content: flex-end; } .a-bars.dr { right: 20px; justify-content: flex-start; }
.a-bars.v { flex: 1; height: 24px; gap: 2px; overflow: hidden; }
.a-bars.v i { width: 2px; background: var(--ap-2); }
.app.talking .a-wire, .app.hearing .a-wire { display: none; }
.app.talking .a-bars.wave, .app.hearing .a-bars.wave, .app.talking .a-bars.dl, .app.talking .a-bars.dr, .app.hearing .a-bars.dl, .app.hearing .a-bars.dr { display: flex; }
.app.talking .a-bars:not(.v) i, .app.hearing .a-bars:not(.v) i { animation: dwave .8s ease-in-out infinite alternate; animation-delay: var(--d, 0s); }
@keyframes dwave { from { transform: scaleY(var(--h, .5)); } to { transform: scaleY(calc(var(--h, .5) * .3 + .08)); } }
.app.hearing .a-pav::before { border-color: var(--ap-pres); }
.app.hearing .a-dot { display: none; } .app.hearing .a-snd { display: grid; }

/* talk dock */
.a-dock { position: absolute; left: 0; right: 0; bottom: 0; height: 118px; background: var(--ap-paper); border-top: 1px solid var(--ap-div); display: flex; flex-direction: column; align-items: center; padding-top: 10px; }
.a-mic { width: 66px; height: 66px; border-radius: 50%; border: 2px solid var(--ap-div); background: none; padding: 4px; touch-action: none; -webkit-touch-callout: none; transition: border-color .2s, transform .15s var(--ease); }
.a-micin { width: 100%; height: 100%; border-radius: 50%; background: var(--ap-ink); color: var(--ap-paper); display: grid; place-items: center; transition: background .2s; }
.a-micin .ic { width: 28px; height: 28px; grid-area: 1 / 1; }
.a-micin .m2 { display: none; }
.a-mic:focus-visible { outline-offset: 4px; border-radius: 50%; }
.app.talking .a-mic { border-color: var(--ap-pres); transform: scale(.96); }
.app.hearing .a-mic { border-color: var(--ap-pres); }
.app.hearing .a-micin { background: var(--ap-pres); }
.app.hearing .a-micin .m1 { display: none; } .app.hearing .a-micin .m2 { display: block; }
.a-dt { margin-top: 6px; display: flex; align-items: center; gap: 8px; font-size: 15px; font-weight: 500; }
.a-dtdot { display: none; width: 9px; height: 9px; border-radius: 50%; background: var(--ap-pres); }
.app.hearing .a-dtdot { display: block; }
.a-dh { margin-top: 1px; font-size: 12.5px; color: var(--ap-2); text-align: center; padding: 0 14px; }
.app.shortpress .a-dh { animation: dshort .9s ease-out; }
@keyframes dshort { 0%, 100% { color: var(--ap-2); } 20% { color: var(--ap-ink); transform: scale(1.06); } }

/* snackbar, heads-up banner, tap ripple */
.a-toast { position: absolute; left: 12px; right: 12px; bottom: 126px; z-index: 30; background: var(--ap-ink); color: var(--ap-paper); border-radius: 10px; padding: 0 6px 0 16px; min-height: 48px; display: flex; align-items: center; justify-content: space-between; gap: 10px; font-size: 14px; opacity: 0; transform: translateY(12px); pointer-events: none; transition: opacity .25s, transform .3s var(--ease); }
.a-toast.on { opacity: 1; transform: none; pointer-events: auto; }
.a-toast button { height: 52px; padding: 0 12px; background: none; border: 0; color: #C9B48F; font-weight: 500; font-size: 14px; border-radius: 8px; }
.a-toast button[hidden] { display: none; }
.a-banner { position: absolute; z-index: 40; left: 8px; right: 8px; top: 10px; background: #fff; color: #1d1f1c; border-radius: 18px; padding: 10px 14px 12px; box-shadow: 0 6px 24px rgba(0, 0, 0, .22); transform: translateY(-140%); transition: transform .45s var(--ease); pointer-events: none; }
.a-banner.on { transform: none; }
.a-bh { display: flex; align-items: center; gap: 6px; font-size: 11.5px; color: #55584f; }
.a-bh .ic { width: 12px; height: 12px; stroke-width: 2.4; }
.a-bt { margin-top: 3px; font-size: 14px; font-weight: 600; }
.a-bb { font-size: 13.5px; color: #55584f; }
.a-rip { position: absolute; z-index: 60; width: 52px; height: 52px; margin: -26px 0 0 -26px; border-radius: 50%; background: rgba(130, 151, 123, .38); border: 2px solid var(--ap-pres); pointer-events: none; animation: drip .75s ease-out forwards; }
@keyframes drip { 0% { transform: scale(.4); opacity: 1; } 70% { opacity: 1; } 100% { transform: scale(1.5); opacity: 0; } }

/* update sheet */
.a-sheet { position: absolute; inset: 0; z-index: 20; visibility: hidden; transition: visibility 0s .35s; }
.a-sheet.on { visibility: visible; transition: none; }
.a-scrim { position: absolute; inset: 0; width: 100%; background: rgba(41, 46, 39, .38); border: 0; opacity: 0; transition: opacity .3s; }
.a-sheet.on .a-scrim { opacity: 1; }
.a-panel { position: absolute; left: 0; right: 0; bottom: 0; background: var(--ap-paper); border-radius: 26px 26px 0 0; padding: 10px 14px 18px; transform: translateY(102%); transition: transform .38s var(--ease); }
.a-sheet.on .a-panel { transform: none; }
.a-grab { display: block; width: 36px; height: 4px; border-radius: 2px; background: #C9CBC4; margin: 0 auto 14px; }
.a-panel h3 { font-size: 20px; font-weight: 500; padding: 0 4px; }
.a-panel p { margin-top: 3px; font-size: 14.5px; color: var(--ap-2); padding: 0 4px 6px; }
.a-presets { display: grid; grid-template-columns: repeat(3, 1fr); margin-top: 4px; }
.a-presets button { height: 70px; background: none; border: 0; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 6px; font-size: 14px; font-weight: 500; border-radius: 12px; }
.a-presets button:active, .a-presets button:hover { background: var(--ap-raised); }
.a-presets .ic { width: 24px; height: 24px; }

/* compass (Locate) */
.a-comp { position: absolute; inset: 0; z-index: 25; background: var(--ap-paper); transform: translateX(104%); visibility: hidden; transition: transform .36s var(--ease), visibility 0s .36s; }
.a-comp.on { transform: none; visibility: visible; transition: transform .36s var(--ease); }
.a-ch { height: 60px; margin-top: 8px; display: flex; align-items: center; justify-content: center; position: relative; font-size: 18px; }
.a-ch b { font-weight: 500; }
.a-back { position: absolute; left: 4px; top: 4px; width: 52px; height: 52px; background: none; border: 0; display: grid; place-items: center; border-radius: 50%; }
.a-rose { position: relative; width: 180px; height: 180px; margin: 54px auto 0; border-radius: 50%; border: 2px solid var(--ap-div); display: grid; place-items: center; }
.a-rose i { position: absolute; font-style: normal; font-size: 13px; font-weight: 600; color: var(--ap-2); }
.a-rose .n { top: 10px; left: 50%; margin-left: -4px; } .a-rose .s { bottom: 10px; left: 50%; margin-left: -4px; } .a-rose .e { right: 12px; top: 50%; margin-top: -8px; } .a-rose .w { left: 12px; top: 50%; margin-top: -8px; }
.a-rose .arrow { width: 62px; height: 62px; fill: var(--ap-ink); stroke: var(--ap-ink); stroke-width: 1.4; }
.a-rose .arrow.sw { transform: rotate(180deg); }
.a-km { margin-top: 38px; text-align: center; font-size: 38px; font-weight: 500; letter-spacing: -.01em; }
.a-dir { text-align: center; font-size: 18px; margin-top: 2px; }
.a-live { margin-top: 24px; text-align: center; font-size: 13.5px; color: var(--ap-2); }
.a-samp { margin-top: 6px; text-align: center; font-size: 12.5px; color: var(--ap-warmT); }

/* ---------------------------------------------------------------- phones on a phone: one big phone, the other arrives as a card */
.dpeek { display: none; }
@media (max-width: 1200px) {
  .duo-head { grid-template-columns: 1fr; }
  .duo-note { max-width: 52ch; }
}
@media (max-width: 900px) {
  .duo-head { grid-template-columns: 1fr; }
}
@media (max-width: 760px) {
  .duo { --pw: min(80vw, 316px); margin: 0; border-radius: calc(var(--r) * 1.5); padding: 12vh var(--g) 9vh; }
  .duo-stage { display: block; margin: 16px 0 18px; }
  .dthread { display: none; }
  .dphone, .dphone[data-side="a"], .dphone[data-side="b"] { transform: none; margin: 0 auto; }
  .duo-stage[data-mode="live"][data-view="a"] .dphone[data-side="b"], .duo-stage[data-mode="live"][data-view="b"] .dphone[data-side="a"] { display: none; }
  .duo-stage[data-mode="rec"] { display: flex; justify-content: center; gap: 14px; }
  .duo-stage[data-mode="rec"] .dphone { --pw: 40vw; margin: 0; }
  .duo-stage[data-mode="rec"] .dscreen { border-radius: 22px; border-width: 5px; }
  .duo-stage[data-mode="rec"] .dsay { font-size: 17px; }
  .duo-switch { display: flex; order: 1; margin: 22px auto 0; padding: 4px; gap: 4px; background: var(--card); border: 1px solid var(--rule); border-radius: 48px; }
  .duo-stage[data-mode="rec"] ~ .duo-switch { display: none; }
  .duo-switch button { position: relative; height: 44px; padding: 0 22px; border-radius: 44px; font-weight: 500; font-size: 15px; transition: background .25s, color .25s; }
  .duo-switch button[aria-pressed="true"] { background: var(--ink); color: var(--paper); }
  .duo-switch .dn { position: absolute; top: 8px; right: 10px; width: 9px; height: 9px; border-radius: 50%; background: var(--sand); display: none; }
  .duo-switch.new-a button[data-v="a"] .dn, .duo-switch.new-b button[data-v="b"] .dn { display: block; }
  .duo-ctl { gap: 8px; }
  .duo-ctl button { height: 44px; padding: 0 16px; font-size: 14px; }
  .duo-ctl button .mono { display: none; }
  .duo-bar { flex-direction: column; align-items: center; }
  .dpeek { position: absolute; z-index: 5; left: 50%; top: 10px; width: min(calc(var(--pw) - 20px), 300px); transform: translate(-50%, -150%); opacity: 0; display: grid; grid-template-columns: 1fr auto; gap: 0 12px; align-items: center; text-align: left; background: var(--ink); color: var(--paper); border-radius: 16px; padding: 10px 14px; box-shadow: 0 14px 40px -12px rgba(27, 30, 26, .55); min-height: 54px; }
  .dpeek[hidden] { display: none; }
  .dpeek.on { transform: translate(-50%, 0); opacity: 1; transition: transform .5s var(--ease), opacity .3s; }
  .dpeek .pk-n { grid-column: 1; font-size: 11.5px; letter-spacing: .02em; color: var(--glow); }
  .dpeek b { grid-column: 1; font-weight: 500; font-size: 16px; line-height: 1.25; }
  .dpeek .pk-go { grid-column: 2; grid-row: 1 / 3; font-size: 14px; font-weight: 500; padding: 10px 14px; border-radius: 30px; background: var(--paper); color: var(--ink); }
}

@media (prefers-reduced-motion: reduce) {
  .dphone, .dpeek, .a-panel, .a-comp, .a-toast, .a-banner { transition: none !important; }
  .app *, .app *::before, .app *::after { animation: none !important; }
  .app.hint .a-act:first-child::before { border-color: var(--ap-pres); opacity: .9; }
}
.rm .dphone, .rm .dpeek, .rm .a-panel, .rm .a-comp, .rm .a-toast, .rm .a-banner { transition: none !important; }
.rm .app *, .rm .app *::before, .rm .app *::after { animation: none !important; }
.rm .dphone.shake .dscreen { animation: none; }
