.dx-fab { position: fixed; right: 20px; bottom: 24px; z-index: 95; display: flex; flex-direction: column; gap: 12px; }
.dx-fab__btn {
    width: 64px; height: 64px; border: 0; border-radius: 50%; padding: 0;
    display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 2px;
    color: #fff; background: linear-gradient(135deg, var(--dx-primary-color), #ff7a3d);
    box-shadow: 0 10px 28px rgba(255, 47, 109, .25); cursor: pointer; white-space: nowrap;
    font-size: 11.5px; font-weight: 700; line-height: 1.2; letter-spacing: .02em;
    transition: transform .2s, box-shadow .2s, opacity .25s, visibility .25s;
}
.dx-fab__btn svg { width: 20px; height: 20px; flex: none; }
.dx-fab__btn:hover { transform: translateY(-2px); box-shadow: 0 14px 34px rgba(255, 47, 109, .25); }
.dx-fab__backtop { opacity: 0; visibility: hidden; transform: translateY(10px); }
.dx-fab__backtop.is-on { opacity: 1; visibility: visible; transform: none; }
.dx-fab__backtop.is-on:hover { transform: translateY(-2px); }
.dx-history {
    position: fixed; right: 100px; bottom: 24px; z-index: 96; width: 340px; max-height: min(70vh, 560px);
    display: flex; flex-direction: column; border-radius: 20px; box-sizing: border-box;
    color: #f4f4f6; background: #17171e; border: 1px solid rgba(255,255,255,.13);
    box-shadow: 0 24px 60px -20px rgba(0,0,0,.9); overflow: hidden;
}
.dx-history[hidden], .dx-history [hidden] { display: none; }
.dx-history button { background: none; border: 0; padding: 0; cursor: pointer; }
.dx-history__head { display: flex; align-items: center; gap: 10px; padding: 14px 16px; border-bottom: 1px solid rgba(255,255,255,.07); flex: none; }
.dx-history__title { margin: 0; font-size: 15px; font-weight: 750; line-height: 1.5; }
.dx-history__clear { margin-left: auto; font-size: 12.5px; color: #6f6f7e; }
.dx-history__clear:hover { color: #ff6b95; }
.dx-history__close { width: 28px; height: 28px; border-radius: 8px; display: grid; place-items: center; color: #a9a9b6; }
.dx-history__clear[hidden] + .dx-history__close { margin-left: auto; }
.dx-history .dx-history__close:hover { background: #20202a; color: #fff; }
.dx-history__list { list-style: none; margin: 0; padding: 6px; overflow-y: auto; overscroll-behavior: contain; min-height: 0; }
.dx-history__list a { display: flex; gap: 10px; align-items: center; padding: 8px; border-radius: 10px; text-decoration: none; }
.dx-history__list a:hover { background: #20202a; }
.dx-history__thumb { flex: 0 0 88px; width: 88px; height: 50px; aspect-ratio: 16 / 9; border-radius: 8px; object-fit: cover; background: #20202a; }
.dx-history__thumb--drama { height: 117px; aspect-ratio: 3 / 4; }
.dx-history__kind { color: #ff8bab; font-size: 11px; line-height: 1.4; }
.dx-history__episode { color: #b7b7c5; font-size: 12px; line-height: 1.45; overflow-wrap: anywhere; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.dx-history__info { min-width: 0; display: flex; flex-direction: column; gap: 4px; }
.dx-history__title { font-size: 13px; font-weight: 600; line-height: 1.45; color: #f4f4f6; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; overflow-wrap: anywhere; }
.dx-history__meta { font-size: 11.5px; color: #6f6f7e; }
.dx-history__empty { padding: 36px 16px; text-align: center; color: #6f6f7e; font-size: 13px; line-height: 1.6; }
.dx-history__note { flex: none; margin: 0; padding: 12px; border-top: 1px solid rgba(255,255,255,.07); font-size: 12px; color: #a9a9b6; text-align: center; }
.dx-fab__btn:focus-visible, .dx-history button:focus-visible, .dx-history a:focus-visible { outline: 2px solid #ff6b95; outline-offset: 3px; }
@media (max-width: 719px) {
    .dx-fab { right: 12px; bottom: calc(16px + env(safe-area-inset-bottom, 0px)); gap: 10px; }
    .dx-fab__btn { width: 56px; height: 56px; font-size: 10.5px; letter-spacing: 0; }
    .dx-fab__btn svg { width: 18px; height: 18px; }
    .dx-history { left: 0; right: 0; bottom: 0; width: auto; max-height: 72vh; border-radius: 20px 20px 0 0; padding-bottom: env(safe-area-inset-bottom, 0px); }
}
@media (prefers-reduced-motion: reduce) { .dx-fab__btn { transition: none; } }
