/* 跨畫面共用的元件。機台頁（index.html）與手機保存頁（Worker 輸出的 /s/:id）都載這支。
   顏色取樣自設計稿 cut5 原圖（720×1280）：膠囊左 #EAA17E → 右 #E38178、文字 #2C231C。 */

/* 玻璃膠囊：白色半透明外框包著橘紅漸層，內層邊緣羽化、白字外發光。
   設計稿 cut2（ASSIGNING）、cut4（資料處理中）、cut5（配對成功）是同一種；目前 cut5、cut6 套用。
   可以是 <p>（純顯示）也可以是 <a>／<button>（cut6 的按鈕），內層一律包一個 <span>。 */
.glass-pill {
  display: flex;
  margin: 0;
  padding: 6px;
  border: 0;
  border-radius: 999px;
  background: linear-gradient(180deg, #fbf8f4, #ebe4db);
  box-shadow:
    0 10px 18px -8px rgba(90, 70, 55, .45),
    inset 0 1px 1px #fff,
    inset 0 -2px 3px rgba(0, 0, 0, .05);
  font: inherit;
  text-decoration: none;
}
.glass-pill > span {
  flex: 1;
  display: grid;
  place-items: center;
  border-radius: 999px;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0) 45%, rgba(214, 170, 170, .38) 100%),
    linear-gradient(90deg, #eeb08e 0%, #e6957a 35%, #e38178 75%, #dc9a9a 100%);
  box-shadow: inset 0 0 8px 2px rgba(255, 246, 242, .5);
  color: #fff;
  font-weight: 900;
  letter-spacing: .08em;
  text-shadow: 0 0 3px rgba(255, 255, 255, .7), 0 0 8px rgba(214, 90, 70, .55);
}
a.glass-pill, button.glass-pill { cursor: pointer; -webkit-tap-highlight-color: transparent; }
a.glass-pill:active > span, button.glass-pill:active > span { filter: brightness(.94); }

/* 玻璃卡：白色玻璃框裡放影片。位置與大小由各頁決定（absolute） */
.glass-card {
  position: absolute;
  padding: 16px 17px;
  border-radius: 12px;
  background: linear-gradient(160deg, rgba(255, 255, 255, .92), rgba(248, 245, 240, .78));
  border: 1.5px solid rgba(255, 255, 255, .95);
  box-shadow: 0 12px 28px -10px rgba(100, 85, 70, .4), inset 0 0 0 1px rgba(255, 255, 255, .6);
}
/* 設計稿卡片右下角有一點柔光 */
.glass-card::after {
  content: '';
  position: absolute;
  right: -10px;
  bottom: -10px;
  width: 42px;
  height: 42px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(255, 255, 255, .95), rgba(255, 255, 255, 0) 65%);
  pointer-events: none;
}
.glass-card__frame {
  position: relative;
  width: 100%;
  height: 100%;
  overflow: hidden;
  background: #e4ded4;
  display: grid;
  place-items: center;
}
.glass-card__frame video { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
