.dy { --ink: #1f2430; --mut: #6b7280; --card: #fff; --bd: #e5e0d3; --ac: #845ef7; max-width: 560px; margin: 0 auto; padding-bottom: 90px; color: var(--ink); font-family: -apple-system, 'Segoe UI', 'Noto Sans TC', 'Noto Sans JP', 'PingFang TC', 'Microsoft JhengHei', sans-serif; }
.dy [hidden] { display: none !important; }
.dy button, .dy input, .dy select { font: inherit; }
.dy button { cursor: pointer; -webkit-tap-highlight-color: transparent; }
.dy-tabs { display: flex; gap: 4px; background: #ece8dd; border-radius: 999px; padding: 4px; margin-bottom: 14px; position: sticky; top: 0; z-index: 5; }
.dy-tabs button { flex: 1; border: 0; background: none; padding: 9px 0; border-radius: 999px; font-size: 15px; color: var(--mut); }
.dy-tabs button.on { background: #fff; color: var(--ink); font-weight: 700; box-shadow: 0 1px 4px rgba(0,0,0,.12); }
.dy-chips { display: flex; flex-wrap: wrap; gap: 6px; margin: 0 0 12px; }
.dy-chips button { border: 1px solid var(--bd); background: #fff; color: var(--ink); padding: 6px 13px; border-radius: 999px; font-size: 14px; }
.dy-chips button.on { background: var(--ink); color: #fff; border-color: var(--ink); }
.dy-empty { text-align: center; color: var(--mut); padding: 40px 10px; line-height: 1.7; }
.dy-sep { margin: 18px 4px 8px; color: var(--mut); font-size: 14px; font-weight: 600; }
.dy-card { display: flex; align-items: center; gap: 12px; padding: 16px 16px; border-radius: 22px; color: #fff; margin-bottom: 12px; box-shadow: 0 6px 18px rgba(0,0,0,.14); cursor: pointer; position: relative; overflow: hidden; }
.dy-card.past { opacity: .88; filter: saturate(.8); }
.dy-card.soon { animation: dyglow 2.2s ease-in-out infinite; }
@keyframes dyglow { 0%, 100% { box-shadow: 0 6px 18px rgba(0,0,0,.14); } 50% { box-shadow: 0 0 0 4px rgba(255,255,255,.5), 0 10px 26px rgba(0,0,0,.28); } }
.dy-ic { font-size: 34px; flex: none; width: 46px; text-align: center; }
.dy-mid { flex: 1; min-width: 0; }
.dy-mid h3 { margin: 0 0 3px; font-size: 18px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.dy-date { font-size: 13px; opacity: .9; }
.dy-tags { display: flex; flex-wrap: wrap; gap: 5px; margin-top: 7px; }
.dy-tags span { background: rgba(255,255,255,.24); border-radius: 999px; padding: 2px 9px; font-size: 12px; }
.dy-num { text-align: right; flex: none; }
.dy-num b { display: block; font-size: 42px; line-height: 1; font-weight: 700; font-variant-numeric: tabular-nums; }
.dy-num small { font-size: 13px; opacity: .92; }
.dy-num em { display: block; font-size: 12px; font-style: normal; opacity: .95; margin-top: 3px; }
.dy-fab { position: fixed; right: 18px; bottom: calc(22px + env(safe-area-inset-bottom)); width: 58px; height: 58px; border-radius: 50%; border: 0; background: linear-gradient(135deg, #845ef7, #e64980); color: #fff; font-size: 32px; line-height: 1; box-shadow: 0 8px 22px rgba(132,94,247,.5); z-index: 30; }
.dy-fab:active { transform: scale(.94); }
/* 編輯面板 */
.dy-sheetbg { position: fixed; inset: 0; background: rgba(15,15,25,.5); z-index: 60; display: flex; align-items: flex-end; justify-content: center; }
.dy-sheet { background: #fff; width: 100%; max-width: 560px; max-height: 92vh; max-height: 92dvh; overflow: auto; border-radius: 24px 24px 0 0; padding: 18px 18px calc(18px + env(safe-area-inset-bottom)); box-sizing: border-box; display: grid; gap: 12px; }
.dy-sheet h3 { margin: 0; font-size: 18px; }
.dy label, .dy-lab { display: grid; gap: 5px; font-size: 14px; color: var(--mut); }
.dy input[type=text], .dy input[type=date], .dy input[type=time], .dy input[type=number], .dy select { width: 100%; box-sizing: border-box; border: 1px solid var(--bd); border-radius: 12px; padding: 11px 12px; font-size: 16px; background: #fff; color: var(--ink); min-width: 0; }
.dy-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; }
#dy-lun.dy-grid, #dy-calc .dy-grid:first-of-type { grid-template-columns: repeat(2, 1fr); }
#dy-lun .dy-prev { grid-column: 1 / -1; font-size: 14px; color: var(--ink); background: #f3f0ff; border-radius: 10px; padding: 8px 10px; }
.dy label.dy-chk { display: flex; align-items: center; gap: 8px; color: var(--ink); }
.dy-chk input { width: 20px; height: 20px; }
.dy-colors { display: flex; gap: 10px; flex-wrap: wrap; }
.dy-colors button { width: 36px; height: 36px; border-radius: 50%; border: 3px solid #fff; box-shadow: 0 0 0 1.5px var(--bd); }
.dy-colors button.on { box-shadow: 0 0 0 3px var(--ink); }
.dy-note { margin: 0; font-size: 13px; color: var(--mut); line-height: 1.6; }
.dy-btns { display: flex; gap: 10px; flex-wrap: wrap; }
.dy-btns button, .dy-file, .dy-row button { border: 1px solid var(--bd); background: #fff; color: var(--ink); padding: 11px 18px; border-radius: 14px; font-size: 15px; }
.dy-btns .dy-primary { background: linear-gradient(135deg, #845ef7, #e64980); color: #fff; border: 0; flex: 1; font-weight: 700; }
.dy-btns .dy-del { color: #c92a2a; margin-left: auto; }
.dy-file { display: inline-block; text-align: center; cursor: pointer; }
.dy-box { background: #fff; border: 1px solid var(--bd); border-radius: 18px; padding: 14px 16px; margin-bottom: 12px; display: grid; gap: 10px; }
.dy-box h3 { margin: 0; font-size: 16px; }
.dy-out { background: #f6f3ff; border-radius: 14px; padding: 12px 14px; display: grid; gap: 4px; font-size: 15px; min-height: 8px; }
.dy-out:empty { display: none; }
.dy-out .big { font-size: 22px; font-weight: 700; }
.dy-out small { color: var(--mut); }
.dy-row { display: flex; justify-content: space-between; align-items: center; gap: 10px; }
.dy-toast { position: fixed; left: 50%; bottom: 100px; transform: translateX(-50%); background: rgba(20,20,30,.9); color: #fff; padding: 9px 18px; border-radius: 999px; font-size: 14px; z-index: 80; max-width: 90vw; text-align: center; }
html.dy-lock, html.dy-lock body { overflow: hidden; }
.is-app .tl-head, .is-app #tl-install-tip, .is-app #tl-root > .tl-note, .is-app .dy ~ .tl-note { display: none !important; }
.is-app #tl-root { padding-top: 10px !important; }
@media (max-width: 380px) { .dy-num b { font-size: 34px; } .dy-grid { gap: 6px; } }
.is-app .dy-tabs { top: 56px; }
.dy-df { display: flex; align-items: center; gap: 5px; }
.dy-df input { border: 1px solid var(--bd); border-radius: 12px; padding: 11px 4px; font-size: 18px; text-align: center; background: #fff; color: var(--ink); width: 3.2em; box-sizing: border-box; min-width: 0; font-variant-numeric: tabular-nums; }
.dy-df input.y { width: 4.6em; }
.dy-df span { color: var(--mut); font-size: 15px; }
.dy-df input:focus { outline: none; border-color: var(--ac); box-shadow: 0 0 0 2px rgba(132,94,247,.25); }
#dy-calc .dy-grid:first-of-type { grid-template-columns: 1fr; }
.dy-callist { display: grid; gap: 4px; max-height: 50vh; overflow: auto; }
.dy-callist label.dy-chk { align-items: flex-start; padding: 8px 4px; border-bottom: 1px solid var(--bd); color: var(--ink); }
.dy-callist small { color: var(--mut); }
