/* ============================================================================
   Walkthrough phone — Timer Face gallery, Analytics, and the Home Screen widgets.
   Positions = capture pixels × 4/9; see walkthrough-phone-focus-run-shield.css.
   ========================================================================== */

/* ---------- Timer Face gallery (8 tiles, 2 columns, scrolled like the capture) */
.fmd-tile { position: absolute; left: calc(16px + var(--col) * 149px); top: calc(-19px + var(--row) * 163px); width: 139px; transition: transform .15s ease; }
.fmd-tile__preview { position: relative; display: block; height: 110px; overflow: hidden; border-radius: 13px; background: #0B0908; box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .07); }
/* The app lays each face out on a 430 × 300 canvas and scales it into the tile (FaceTile). */
.fmd-tile__canvas { position: absolute; left: 0; top: 50%; width: 430px; height: 300px; margin-top: -150px; transform: scale(.3233); transform-origin: 0 50%; container-type: size; }
.fmd-tile__canvas .face-panel { position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; opacity: 1; visibility: visible; }
.fmd-tile__lock { position: absolute; inset: 0; display: grid; place-items: center; background: rgba(0, 0, 0, .4); color: rgba(255, 255, 255, .9); }
.fmd-tile__lock svg { width: 17px; height: 17px; }
.fmd-pro { position: absolute; top: 6px; right: 6px; padding: 2px 5.5px; border-radius: 99px; background: linear-gradient(90deg, #FF6A4D, #E0431E); font-size: 7.5px; font-weight: 900; letter-spacing: .05em; color: #fff; }
.fmd-tile__check { position: absolute; top: 6px; left: 6px; width: 16px; height: 16px; color: #FF6A4D; opacity: 0; transform: scale(.4); transition: opacity .2s ease, transform .3s cubic-bezier(.34, 1.56, .64, 1); }
.fmd-tile.is-selected .fmd-tile__preview { box-shadow: inset 0 0 0 2px #FF6A4D; }
.fmd-tile.is-selected .fmd-tile__check { opacity: 1; transform: none; }
.fmd-tile__name { display: block; margin-top: 8px; font-size: 10.5px; font-weight: 700; }
.fmd-tile__desc { display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; height: 2.6em; margin-top: 2px; font-size: 8.5px; line-height: 1.3; font-weight: 500; color: #9A8F88; }
.fmd-faces__head { position: absolute; z-index: 3; left: 0; right: 0; top: 0; height: 92px; background: linear-gradient(#191512 58%, rgba(25, 21, 18, .82)); }
.fmd-faces__back { position: absolute; left: 13px; top: 45px; width: 33px; height: 33px; padding: 9px; border-radius: 50%; background: rgba(255, 255, 255, .1); color: #fff; }
.fmd-faces__head b { position: absolute; left: 60px; right: 60px; top: 54px; text-align: center; font-size: 13.5px; font-weight: 700; }

/* ---------- Analytics */
.fmd-card { position: absolute; border-radius: 16px; background: #241E19; box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .05); }
.fmd-stats__hello { position: absolute; left: 16px; top: 60px; width: 200px; font-size: 9.5px; font-weight: 500; color: #9A8F88; }
.fmd-stats__title { position: absolute; left: 16px; top: 72px; width: 205px; font-size: 18px; font-weight: 800; }
.fmd-stats__streak {
  position: absolute; right: 16px; top: 61px; height: 28px; padding: 0 10px; display: inline-flex; align-items: center; gap: 4px;
  border-radius: 14px; background: #241E19; box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .06);
}
.fmd-stats__streak .fmd-emoji { font-size: 12px; }
.fmd-stats__streak b { font-size: 14px; font-weight: 800; }
.fmd-stats__streak small { font-size: 9px; color: #8E847D; font-weight: 600; }
.fmd-stats__streak b.is-roll, .fmd-stats__tile b.is-roll { animation: fmdRoll .5s cubic-bezier(.34, 1.56, .64, 1); }
@keyframes fmdRoll { 0% { transform: translateY(70%); opacity: 0; } 100% { transform: none; opacity: 1; } }
.fmd-stats__seg { position: absolute; left: 16px; top: 104px; width: 250px; height: 29px; padding: 3px; display: flex; border-radius: 14.5px; background: #241E19; }
.fmd-stats__seg i { flex: 1; display: grid; place-items: center; padding: 0 4px; border-radius: 12px; font-style: normal; font-size: 10.5px; font-weight: 600; color: #D8D0CA; text-align: center; line-height: 23px; }
.fmd-stats__seg i.is-on { background: #FF6A4D; color: #fff; }
.fmd-stats__cal { position: absolute; left: 273px; top: 104px; width: 29px; height: 29px; padding: 7px; border-radius: 50%; background: #241E19; color: #D8D0CA; }
.fmd-stats__chart { left: 16px; top: 144px; width: 288px; height: 208px; }
.fmd-stats__label { position: absolute; left: 13px; top: 14px; width: 170px; font-size: 9px; font-weight: 600; color: #BDB4AD; }
.fmd-stats__total { position: absolute; left: 13px; top: 27px; font-size: 19px; font-weight: 800; letter-spacing: -.01em; }
.fmd-stats__delta { position: absolute; right: 10px; top: 13px; height: 16px; padding: 0 7px; display: flex; align-items: center; border-radius: 8px; background: rgba(63, 182, 168, .18); color: #3FB6A8; font-size: 8.5px; font-weight: 800; }
.fmd-stats__vs { position: absolute; right: 10px; top: 35px; width: 90px; text-align: right; font-size: 8.5px; font-weight: 600; color: #9A8F88; }
.fmd-stats__svg { position: absolute; inset: 0; overflow: visible; }
.fmd-stats__line { fill: none; stroke: #FF6A4D; stroke-width: 2; stroke-linejoin: round; stroke-dasharray: 100; stroke-dashoffset: 0; }
.fmd-stats__prev { fill: none; stroke: #8E847D; stroke-width: 1.2; stroke-dasharray: 3 3; opacity: .8; }
.fmd-stats__pt { fill: #FF6A4D; }
.fmd-stats__area { transition: opacity .6s ease .5s; }
.fmd-stats[data-drawn="0"] .fmd-stats__line { stroke-dashoffset: 100; }
.fmd-stats[data-drawn="0"] .fmd-stats__area, .fmd-stats[data-drawn="0"] .fmd-stats__pt { opacity: 0; }
.fmd-stats[data-drawn="1"] .fmd-stats__line { transition: stroke-dashoffset 1.1s cubic-bezier(.45, 0, .2, 1); }
.fmd-stats__pt { transition: opacity .3s ease .9s; }
.fmd-stats__day { position: absolute; top: 164px; width: 40px; margin-left: -20px; text-align: center; font-size: 8px; font-weight: 600; color: #8E847D; }
.fmd-stats__legend { position: absolute; left: 13px; right: 13px; top: 186px; display: flex; align-items: center; gap: 5px; font-size: 8px; font-weight: 600; color: #9A8F88; }
.fmd-stats__legend span { max-width: 100px; margin-right: 8px; }
.fmd-stats__legend i { flex: none; width: 11px; height: 0; border-top: 2px solid #FF6A4D; }
.fmd-stats__legend i.is-prev { border-top: 1.5px dashed #8E847D; }
.fmd-stats__tile { left: calc(16px + var(--c) * 147px); top: calc(361px + var(--r) * 59px); width: 141px; height: 52px; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 3px; padding: 0 8px; }
.fmd-stats__tile b { font-size: 15px; font-weight: 800; }
.fmd-stats__tile b.is-accent { color: #FF6A4D; }
.fmd-stats__tile small { max-width: 100%; font-size: 8.5px; font-weight: 600; color: #9A8F88; }
.fmd-stats__golden { left: 16px; top: 481px; width: 288px; height: 143px; }
.fmd-stats__golden-head { position: absolute; left: 13px; right: 13px; top: 14px; font-size: 11.5px; }
.fmd-stats__golden-head b { font-weight: 800; }
.fmd-stats__golden-head small { font-size: 8px; font-weight: 600; color: #9A8F88; }
.fmd-stats__bar { position: absolute; bottom: 28px; left: calc(14px + var(--i) * 33.4px); width: 26px; height: var(--h); border-radius: 3px 3px 1px 1px; background: #8C4232; transform-origin: 50% 100%; transition: transform .7s cubic-bezier(.2, .8, .2, 1) calc(var(--i) * 60ms); }
.fmd-stats__bar.is-best { background: #FF6A4D; }
.fmd-stats__bar small { position: absolute; left: -6px; right: -6px; bottom: -13px; text-align: center; font-size: 7.5px; font-weight: 600; color: #8E847D; }
.fmd-stats[data-drawn="0"] .fmd-stats__bar { transform: scaleY(0); }

/* ---------- Home Screen with the widgets */
.fmd-home {
  background:
    radial-gradient(60% 34% at 88% 62%, rgba(96, 165, 250, .55), transparent 70%),
    radial-gradient(70% 40% at 8% 88%, rgba(15, 118, 110, .55), transparent 72%),
    radial-gradient(90% 60% at 60% 10%, #173A6E, transparent 70%),
    linear-gradient(165deg, #0B1A36 0%, #0E2D5E 45%, #0A1B3D 75%, #071228 100%);
}
.fmd-widget { position: absolute; left: 24px; width: 272px; border-radius: 22px; background: rgba(26, 21, 18, .9); box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .08), 0 12px 30px -16px rgba(0, 0, 0, .7); }
.fmd-home__label { position: absolute; left: 24px; width: 272px; text-align: center; font-size: 8.5px; font-weight: 600; color: #fff; text-shadow: 0 1px 3px rgba(0, 0, 0, .5); }
.fmd-home__stats { top: 70px; height: 126px; }
.fmd-home__stat { position: absolute; left: 20px; top: calc(22px + var(--y) * 47px); width: 130px; }
.fmd-home__stat small { display: flex; align-items: center; gap: 4px; font-size: 8px; font-weight: 600; color: #A99A8E; }
.fmd-home__stat small .fmd-ic { flex: none; width: 9px; height: 9px; }
.fmd-home__stat b { display: block; margin-top: 3px; font-size: 16px; font-weight: 800; }
.fmd-home__streak { position: absolute; right: 16px; top: 22px; max-width: 110px; height: 22px; padding: 0 8px; display: flex; align-items: center; gap: 4px; border-radius: 11px; background: rgba(255, 106, 77, .16); font-size: 8.5px; font-weight: 800; color: #F6EEE8; }
.fmd-home__mini { position: absolute; right: 22px; top: 60px; width: 102px; height: 32px; display: flex; align-items: flex-end; gap: 6px; }
.fmd-home__mini i { flex: 1; height: calc(var(--h, 2) * 1px); border-radius: 2px; background: #FF6A4D; opacity: .85; }
.fmd-home__qs { top: 228px; height: 126px; overflow: hidden; }
.fmd-qs__idle, .fmd-qs__active { position: absolute; inset: 0; transition: opacity .35s ease, transform .45s cubic-bezier(.2, .8, .2, 1); }
.fmd-qs__row { position: absolute; left: 7px; right: 7px; height: 53px; padding: 0 9px 0 7px; display: flex; align-items: center; gap: 8px; border-radius: 15px; }
.fmd-qs__row:first-child { top: 6px; background: rgba(63, 182, 168, .16); }
.fmd-qs__row:last-child { top: 66px; background: rgba(229, 161, 28, .16); }
.fmd-qs__ic { flex: none; width: 28px; height: 28px; display: grid; place-items: center; border-radius: 8px; background: #1C1916; font-size: 14px; }
.fmd-qs__text { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.fmd-qs__text b { font-size: 12.5px; font-weight: 800; }
.fmd-qs__text small { font-size: 8.5px; font-weight: 600; color: #A99A8E; }
.fmd-qs__play { flex: none; width: 28px; height: 28px; padding: 8px 7px 8px 9px; border-radius: 50%; color: #fff; transition: transform .15s ease; }
.fmd-qs__row.is-teal .fmd-qs__play { background: #3FB6A8; }
.fmd-qs__row.is-amber .fmd-qs__play { background: #E5A11C; }
.fmd-qs__active { padding: 10px 14px; display: flex; flex-direction: column; justify-content: space-between; opacity: 0; transform: translateY(14px); }
.fmd-home[data-qs="active"] .fmd-qs__idle { opacity: 0; transform: translateY(-14px); }
.fmd-home[data-qs="active"] .fmd-qs__active { opacity: 1; transform: none; }
.fmd-qs__head { display: flex; align-items: center; gap: 8px; }
.fmd-qs__ic--accent { width: 30px; height: 30px; background: rgba(255, 106, 77, .12); }
.fmd-qs__sq { flex: none; width: 30px; height: 30px; padding: 8px; border-radius: 9px; }
.fmd-qs__sq--pause { background: #FF6A4D; color: #fff; }
.fmd-qs__sq--stop { background: rgba(255, 106, 77, .13); color: #FF6A4D; }
.fmd-qs__hero { display: flex; align-items: baseline; gap: 8px; }
.fmd-qs__hero b { font-size: 34px; line-height: 1; font-weight: 900; letter-spacing: -.02em; font-variant-numeric: tabular-nums; }
.fmd-qs__hero small { max-width: 130px; font-size: 8.5px; font-weight: 900; letter-spacing: .07em; color: #FF6A4D; }
.fmd-qs__bar { display: block; height: 6.5px; border-radius: 4px; background: rgba(255, 106, 77, .15); overflow: hidden; }
.fmd-qs__bar i { display: block; height: 100%; width: 100%; border-radius: 4px; background: #FF6A4D; transform-origin: 0 50%; transition: transform 1s linear; }
.fmd-qs__ends { display: flex; justify-content: space-between; font-size: 9px; font-weight: 700; color: #A99A8E; }
.fmd-home__small { top: 385px; width: 126px; height: 127px; padding: 11px 10px; }
.fmd-home__recent { font-size: 7.5px; font-weight: 800; letter-spacing: .1em; color: #8C7C70; }
.fmd-home__small-task { display: flex; align-items: center; gap: 5px; margin-top: 11px; font-size: 10.5px; font-weight: 800; }
.fmd-home__small-task .fmd-emoji { font-size: 11px; }
.fmd-home__small-time { display: block; margin-top: 8px; font-size: 19px; font-weight: 900; letter-spacing: -.01em; }
.fmd-home__small-sub { margin-top: 2px; font-size: 7.5px; font-weight: 600; color: #A99A8E; }
.fmd-home__small-start { position: absolute; left: 9px; right: 9px; bottom: 10px; height: 24px; display: flex; align-items: center; justify-content: center; gap: 4px; border-radius: 12px; background: #FF6A4D; font-size: 9.5px; font-weight: 800; color: #fff; }
.fmd-home__small-start .fmd-ic { flex: none; width: 8px; height: 8px; }
.fmd-home__app { position: absolute; left: 245px; top: 463px; width: 50px; height: 50px; border-radius: 12px; }
.fmd-home__dock { position: absolute; left: 12px; top: 598px; width: 296px; height: 84px; display: flex; align-items: center; justify-content: center; gap: 20px; border-radius: 30px; background: rgba(255, 255, 255, .16); }
.fmd-app .fmd-home__dock-ic { width: 50px; height: 50px; }
@media (prefers-reduced-motion: reduce) {
  .fmd-tile__check, .fmd-stats__bar, .fmd-stats__line, .fmd-stats__area, .fmd-stats__pt, .fmd-qs__idle, .fmd-qs__active, .fmd-qs__bar i { transition: none; }
}
