@import url('https://fonts.googleapis.com/css2?family=Noto+Sans+TC:wght@400;500;600;700;800;900&family=Plus+Jakarta+Sans:wght@600;700;800&family=Zen+Maru+Gothic:wght@500;700;900&display=swap');

:root {
    --atlas-bg: rgba(247, 249, 253, 0.58);
    --atlas-card: rgba(255, 255, 255, 0.42);
    --atlas-segment: rgba(224, 231, 242, 0.52);
    --atlas-glass-border: rgba(255, 255, 255, 0.72);
    --atlas-glass-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.88), 0 4px 16px rgba(32, 47, 71, 0.06);
    --atlas-ink: #111b30;
    --atlas-muted: #69778f;
    --atlas-soft: #9aa9bf;
    --atlas-line: #e7ebf2;
    --atlas-rose: #e11d48;
    --atlas-rose-soft: #fbe8ed;
    --atlas-blue: #2f6eea;
    --atlas-font: "Noto Sans TC", -apple-system, BlinkMacSystemFont, sans-serif;
    --atlas-display: "Zen Maru Gothic", "Noto Sans TC", sans-serif;
    --atlas-number: "Plus Jakarta Sans", "Noto Sans TC", sans-serif;
}

.refined-ui #achievement-book-modal {
    align-items: stretch !important;
    justify-content: center !important;
    padding: 0 !important;
    background: rgba(15, 23, 42, 0.18) !important;
    backdrop-filter: blur(4px);
    -webkit-backdrop-filter: blur(4px);
}

.refined-ui #achievement-book-content {
    position: relative;
    width: 100% !important;
    max-width: 34rem !important;
    height: 100dvh !important;
    max-height: none !important;
    overflow: hidden;
    border: 1px solid var(--atlas-glass-border) !important;
    border-radius: 0 !important;
    color: var(--atlas-ink);
    background: var(--atlas-bg) !important;
    backdrop-filter: blur(28px) saturate(1.3) !important;
    -webkit-backdrop-filter: blur(28px) saturate(1.3) !important;
    box-shadow: 0 22px 60px rgba(15, 23, 42, 0.22) !important;
    font-family: var(--atlas-font);
}

.refined-ui #achievement-book-content:focus,
.refined-ui #achievement-detail-content:focus { outline: none; }

.refined-ui .achievement-atlas-hero {
    position: relative;
    z-index: 3;
    flex: 0 0 auto;
    padding: calc(env(safe-area-inset-top) + 0.7rem) 1.25rem 0.75rem;
    border: 0;
    background: rgba(250, 252, 255, 0.22);
    box-shadow: none;
    backdrop-filter: blur(18px);
    -webkit-backdrop-filter: blur(18px);
}

.refined-ui .achievement-atlas-topline {
    min-height: 2.75rem;
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 0.75rem;
}

.refined-ui .achievement-atlas-title {
    display: flex;
    align-items: center;
    gap: 0.45rem;
    color: var(--atlas-ink);
    font: 900 1.625rem/1.15 var(--atlas-display);
    letter-spacing: -0.035em;
}

.refined-ui .achievement-atlas-title::after {
    content: '';
    display: none;
    width: 0.5rem;
    height: 0.5rem;
    flex: 0 0 auto;
    border-radius: 50%;
    background: #fb7185;
}
.refined-ui .achievement-atlas-title.has-unread-achievement::after {
    display: block;
    animation: atlasUnreadPulse 2.6s ease-in-out infinite;
}

.refined-ui .achievement-atlas-close,
.refined-ui .achievement-detail-close {
    width: 2.75rem;
    height: 2.75rem;
    flex: 0 0 auto;
    display: grid;
    place-items: center;
    padding: 0;
    border: 1px solid var(--atlas-glass-border);
    border-radius: 50%;
    color: #526178;
    background: var(--atlas-card);
    backdrop-filter: blur(12px) saturate(1.2);
    -webkit-backdrop-filter: blur(12px) saturate(1.2);
    font-size: 1rem;
    transition: transform 160ms ease, background-color 160ms ease;
}

.refined-ui .achievement-atlas-close:active,
.refined-ui .achievement-detail-close:active { transform: scale(0.92); }
.refined-ui .achievement-atlas-close:hover,
.refined-ui .achievement-detail-close:hover { background: rgba(255, 255, 255, 0.68); }

.refined-ui .achievement-atlas-summary {
    min-height: 1.25rem;
    display: flex;
    align-items: baseline;
    gap: 0.42rem;
    margin-top: -0.08rem;
    color: #5f6d83;
    font-family: var(--atlas-display);
    font-size: 0.78rem;
    font-weight: 700;
    white-space: nowrap;
}

.refined-ui .achievement-atlas-summary strong {
    color: var(--atlas-ink);
    font-family: var(--atlas-number);
    font-size: 0.82rem;
    font-weight: 800;
}

.refined-ui .achievement-atlas-summary i {
    color: #c7d0dd;
    font-style: normal;
}

.refined-ui .achievement-atlas-tabs {
    position: relative;
    isolation: isolate;
    width: 100%;
    min-height: 2.625rem;
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 0.25rem;
    margin-top: 0.85rem;
    padding: 0.0625rem 0.25rem;
    border: 1px solid rgba(255, 255, 255, 0.5);
    border-radius: 1.15rem;
    background: var(--atlas-segment);
    box-shadow: inset 0 1px 4px rgba(15, 23, 42, 0.05), 0 1px 0 rgba(255, 255, 255, 0.72);
    backdrop-filter: blur(14px) saturate(1.2);
    -webkit-backdrop-filter: blur(14px) saturate(1.2);
}

.refined-ui .atlas-gooey-indicator {
    position: absolute;
    inset: 0;
    z-index: 0;
    width: 100%;
    height: 100%;
    overflow: visible;
    pointer-events: none;
    opacity: 0;
    filter: drop-shadow(0 2px 5px rgba(25, 39, 62, 0.09));
}
.refined-ui .has-gooey-indicator .atlas-gooey-indicator { opacity: 0.9; }

.refined-ui .achievement-atlas-tab {
    position: relative;
    z-index: 1;
    min-width: 0;
    min-height: 2.125rem;
    margin-block: 0.1875rem;
    padding: 0 0.4rem;
    border: 0;
    border-radius: 0.9rem;
    color: #68778e;
    background: transparent;
    box-shadow: none;
    font-family: var(--atlas-display);
    font-size: 0.83rem;
    font-weight: 700;
    line-height: 1;
    transition: color 180ms ease, background-color 180ms ease, box-shadow 180ms ease, transform 180ms ease;
}

.refined-ui .achievement-atlas-tab:active { transform: none; }
.refined-ui .achievement-atlas-tab[aria-selected="true"] {
    color: #8d1536;
    background: #fff;
    box-shadow: 0 2px 8px rgba(15, 23, 42, 0.07);
}
.refined-ui .has-gooey-indicator .achievement-atlas-tab[aria-selected="true"] {
    background: transparent;
    box-shadow: none;
}

.refined-ui .achievement-atlas-filters {
    display: flex;
    align-items: center;
    gap: 0.42rem;
    margin-top: 0.65rem;
    overflow-x: auto;
    scrollbar-width: none;
}
.refined-ui .achievement-atlas-filters::-webkit-scrollbar { display: none; }

.refined-ui .achievement-atlas-filter {
    min-height: 2rem;
    flex: 0 0 auto;
    padding: 0 0.75rem;
    border: 1px solid var(--atlas-glass-border);
    border-radius: 999px;
    color: #647287;
    background: var(--atlas-card);
    box-shadow: var(--atlas-glass-shadow);
    backdrop-filter: blur(12px) saturate(1.2);
    -webkit-backdrop-filter: blur(12px) saturate(1.2);
    font-family: var(--atlas-display);
    font-size: 0.7rem;
    font-weight: 700;
    transform: translateY(0);
    box-shadow: var(--atlas-glass-shadow), inset 0 1px 1px rgba(255, 255, 255, 0.65), inset 0 -1px 2px rgba(32, 42, 61, 0.08);
    transition: color 160ms ease, background-color 160ms ease,
        transform 650ms cubic-bezier(0.16, 1, 0.3, 1), box-shadow 650ms cubic-bezier(0.16, 1, 0.3, 1);
}
.refined-ui .achievement-atlas-filter:active {
    transform: translateY(2px);
    box-shadow: 0 1px 2px rgba(32, 42, 61, 0.06), inset 0 1px 3px rgba(32, 42, 61, 0.14), inset 0 -1px 1px rgba(255, 255, 255, 0.4);
    transition-duration: 80ms;
    transition-timing-function: ease-out;
}
.refined-ui .achievement-atlas-filter[aria-pressed="true"] { color: #fff; background: rgba(32, 42, 61, 0.8); border-color: rgba(255, 255, 255, 0.3); }

.refined-ui #achievement-book-list {
    position: relative;
    z-index: 1;
    display: block !important;
    flex: 1 1 auto;
    min-height: 0;
    padding: 0.65rem 1.25rem calc(env(safe-area-inset-bottom) + 2rem) !important;
    overflow-x: hidden;
    overflow-y: auto;
    overscroll-behavior-y: contain;
    background: transparent !important;
    scroll-padding-top: 0.75rem;
    scrollbar-width: none;
}
.refined-ui #achievement-book-list::-webkit-scrollbar { display: none; }
.refined-ui #achievement-book-list > * { content-visibility: visible; contain-intrinsic-size: none; }

.refined-ui .atlas-loading,
.refined-ui .atlas-filter-empty {
    min-height: 42vh;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    color: var(--atlas-muted);
    text-align: center;
}

.refined-ui .atlas-loading > span {
    width: 3.5rem;
    aspect-ratio: 1;
    border: 0.35rem solid #e7ebf2;
    border-top-color: #fb7185;
    border-radius: 50%;
    animation: atlasSpin 900ms linear infinite;
}
.refined-ui .atlas-loading strong,
.refined-ui .atlas-filter-empty strong { margin-top: 0.8rem; color: var(--atlas-ink); font: 800 0.9rem/1.3 var(--atlas-display); }
.refined-ui .atlas-loading small,
.refined-ui .atlas-filter-empty span { margin-top: 0.22rem; font-size: 0.7rem; }

.refined-ui .atlas-region + .atlas-region,
.refined-ui .atlas-finale { margin-top: 1.75rem; }

.refined-ui .atlas-region-heading {
    min-height: 1.75rem;
    display: flex;
    align-items: baseline;
    gap: 0.55rem;
    margin: 0 0 0.7rem;
    border: 0;
    background: transparent;
}

.refined-ui .atlas-region-heading h3,
.refined-ui .atlas-section-heading h3 {
    margin: 0;
    padding: 0;
    color: var(--atlas-ink);
    background: transparent;
    font: 900 1.12rem/1.25 var(--atlas-display);
    letter-spacing: -0.025em;
}
.refined-ui .atlas-region-heading span {
    color: #93a2b8;
    font-family: var(--atlas-number);
    font-size: 0.72rem;
    font-weight: 800;
}

.refined-ui .atlas-panel { margin-top: 0.1rem; }
.refined-ui .atlas-section-heading { margin: 0 0 1rem; text-align: left; }
.refined-ui .atlas-section-heading p {
    margin-top: 0.18rem;
    color: var(--atlas-muted);
    font-size: 0.7rem;
    font-weight: 500;
    line-height: 1.45;
}

.refined-ui .atlas-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    column-gap: 0.75rem;
    row-gap: 1.35rem;
}

.refined-ui .atlas-badge {
    position: relative;
    min-width: 0;
    min-height: 2.75rem;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: flex-start;
    padding: 0;
    border: 0;
    border-radius: 1rem;
    color: var(--atlas-ink);
    background: transparent;
    box-shadow: none;
    outline: none;
    text-align: center;
    transition: transform 180ms cubic-bezier(0.34, 1.56, 0.64, 1);
}
.refined-ui .atlas-badge:active { transform: scale(0.94); }

.refined-ui .atlas-badge:focus,
.refined-ui .atlas-finale-button:focus,
.refined-ui .achievement-atlas-tab:focus,
.refined-ui .achievement-atlas-filter:focus,
.refined-ui .achievement-atlas-close:focus,
.refined-ui .achievement-detail-close:focus,
.refined-ui .atlas-trip-list button:focus { outline: none; }

.refined-ui.atlas-keyboard-nav .atlas-badge:focus,
.refined-ui.atlas-keyboard-nav .atlas-finale-button:focus,
.refined-ui.atlas-keyboard-nav .achievement-atlas-tab:focus,
.refined-ui.atlas-keyboard-nav .achievement-atlas-filter:focus,
.refined-ui.atlas-keyboard-nav .achievement-atlas-close:focus,
.refined-ui.atlas-keyboard-nav .achievement-detail-close:focus,
.refined-ui.atlas-keyboard-nav .atlas-trip-list button:focus {
    outline: 2px solid var(--atlas-blue);
    outline-offset: 3px;
}

.refined-ui .atlas-artwork {
    position: relative;
    aspect-ratio: 1;
    display: grid;
    place-items: center;
    isolation: isolate;
}
.refined-ui .atlas-artwork-clip {
    position: absolute;
    inset: 0;
    display: grid;
    place-items: center;
    overflow: hidden;
    border-radius: 50%;
    isolation: isolate;
    contain: paint;
    transform: translateZ(0);
    -webkit-mask-image: -webkit-radial-gradient(white, black);
}
.refined-ui .atlas-artwork-standard { width: clamp(5.75rem, 26vw, 6.4rem); }
.refined-ui .atlas-artwork-detail { width: min(35vw, 12rem); }
.refined-ui .atlas-artwork-ultimate { width: 8.5rem; }
.refined-ui .atlas-artwork-notice { width: 3.4rem; }

.refined-ui .atlas-artwork img {
    position: relative;
    z-index: 1;
    width: 100%;
    height: 100%;
    display: block;
    padding: 0.16rem;
    border: 3px solid #e2e7ef;
    border-radius: 50%;
    object-fit: contain;
    background: #eef1f5;
    box-shadow: inset 0 0 0 2px rgba(15, 23, 42, 0.035), 0 3px 10px rgba(15, 23, 42, 0.05);
    opacity: 1;
    transition: filter 180ms ease, opacity 180ms ease, transform 180ms ease, box-shadow 180ms ease;
}

.refined-ui .atlas-artwork.is-earned img {
    padding: 0;
    border: 0;
    filter: none;
    opacity: 1;
    background: transparent;
    box-shadow: none;
}
.refined-ui .atlas-artwork-standard.is-earned .atlas-artwork-clip {
    padding: 0.1rem;
    border: 2px solid rgba(251, 113, 133, 0.56);
    background: #fff;
    box-shadow: 0 10px 25px rgba(225, 29, 72, 0.18);
}
.refined-ui .atlas-detail-hero .atlas-artwork-detail.is-earned img {
    padding: 0;
    border: 0;
    background: transparent;
    box-shadow: none;
}
.refined-ui .atlas-artwork.is-locked img {
    filter: grayscale(100%) contrast(0.92) brightness(0.98);
    opacity: 0.7;
}

@media (hover: hover) and (pointer: fine) {
    .refined-ui .atlas-badge.is-earned {
        --atlas-tilt-x: 0deg;
        --atlas-tilt-y: 0deg;
        --atlas-glow-x: 50%;
        --atlas-glow-y: 50%;
        perspective: 700px;
        transform-style: preserve-3d;
    }
    .refined-ui .atlas-badge.is-earned:hover {
        z-index: 4;
        transform: translateY(-0.42rem) scale(1.045);
    }
    .refined-ui .atlas-badge.is-earned .atlas-artwork {
        overflow: visible;
        border-radius: 50%;
        transform-style: preserve-3d;
        transition: transform 280ms cubic-bezier(0.22, 1, 0.36, 1), filter 280ms ease;
    }
    .refined-ui .atlas-badge.is-earned:hover .atlas-artwork {
        transform: rotateX(var(--atlas-tilt-x)) rotateY(var(--atlas-tilt-y)) translateZ(0.6rem);
        filter: drop-shadow(0 14px 18px rgba(180, 83, 9, 0.24));
    }
    .refined-ui .atlas-badge.is-earned:hover .atlas-artwork-clip {
        border-width: 1px;
        border-color: #f59e0b;
    }
    .refined-ui .atlas-badge.is-earned:hover .atlas-artwork img {
        transform: scale(1.045);
    }
    .refined-ui .atlas-badge.is-earned .atlas-artwork-clip::after {
        content: '';
        position: absolute;
        z-index: 2;
        inset: 0;
        border-radius: 50%;
        background: linear-gradient(135deg, transparent 38%, rgba(255, 255, 255, 0.7) 49%, transparent 61%);
        background-position: -120% -120%;
        background-size: 300% 300%;
        opacity: 0;
        pointer-events: none;
    }
    .refined-ui .atlas-badge.is-earned:hover .atlas-artwork-clip::after {
        opacity: 1;
        animation: atlasBadgeShimmer 3.2s cubic-bezier(0.2, 0.8, 0.2, 1) infinite;
    }
    .refined-ui .atlas-badge.is-earned:hover .atlas-badge-name {
        color: #a16207;
        transform: translateY(0.08rem);
    }
}

.refined-ui .atlas-badge.is-earned.has-integrated-title .atlas-artwork-standard::before {
    content: '✓';
    position: absolute;
    z-index: 3;
    width: 1.45rem;
    height: 1.45rem;
    top: -0.1rem;
    right: -0.1rem;
    display: grid;
    place-items: center;
    border: 2px solid #fff;
    border-radius: 50%;
    color: #fff;
    background: #f43f5e;
    box-shadow: 0 3px 8px rgba(225, 29, 72, 0.25);
    font-size: 0.76rem;
    font-weight: 900;
}

.refined-ui .atlas-artwork.is-artwork-missing {
    border: 3px solid #e2e7ef;
    border-radius: 50%;
    background: #eef1f5;
}
.refined-ui .atlas-artwork.is-artwork-missing::before {
    content: '';
    width: 42%;
    aspect-ratio: 1;
    border: 2px solid #c7d0de;
    border-radius: 50%;
}
.refined-ui .atlas-artwork-placeholder-text {
    position: absolute;
    z-index: 2;
    inset: 0;
    display: grid;
    place-items: center;
    color: #8290a4;
    font-size: 0.6rem;
    font-weight: 700;
}

.refined-ui .atlas-badge-name {
    max-width: 100%;
    margin-top: 0.55rem;
    overflow-wrap: anywhere;
    color: var(--atlas-ink);
    font: 900 0.88rem/1.2 var(--atlas-display);
    letter-spacing: -0.025em;
}
.refined-ui .atlas-badge-state,
.refined-ui .atlas-badge-progress {
    margin-top: 0.18rem;
    color: #91a0b5;
    font: 600 0.68rem/1.2 var(--atlas-display);
}
.refined-ui .atlas-badge.is-earned .atlas-badge-state { color: #68778e; }
.refined-ui .atlas-panel .atlas-badge-progress { color: #647287; }

.refined-ui .atlas-finale {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 1.5rem 0 0.5rem;
    border-top: 1px solid var(--atlas-line);
    text-align: center;
}
.refined-ui .atlas-finale-button {
    min-height: 2.75rem;
    display: block;
    padding: 0;
    border: 1px solid var(--atlas-glass-border);
    border-radius: 50%;
    color: var(--atlas-ink);
    background: var(--atlas-card);
    box-shadow: var(--atlas-glass-shadow);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
}
.refined-ui .atlas-finale-copy { margin-top: 0.55rem; }
.refined-ui .atlas-finale-copy > span { color: var(--atlas-rose); font: 700 0.62rem/1 var(--atlas-display); letter-spacing: 0.1em; }
.refined-ui .atlas-finale-copy h3 { margin-top: 0.2rem; color: var(--atlas-ink); font: 900 1.05rem/1.25 var(--atlas-display); }
.refined-ui .atlas-finale-copy p { margin-top: 0.12rem; color: var(--atlas-muted); font-size: 0.68rem; }
.refined-ui .atlas-finale-copy strong { display: block; margin-top: 0.28rem; color: #647287; font: 800 0.78rem/1 var(--atlas-number); }

.refined-ui #achievement-detail-modal {
    align-items: flex-end;
    justify-content: center;
    padding: 0;
    background: rgba(15, 23, 42, 0.28);
    backdrop-filter: blur(5px);
    -webkit-backdrop-filter: blur(5px);
}

.refined-ui #achievement-detail-content {
    position: relative;
    width: 100%;
    height: auto;
    max-height: calc(100svh - env(safe-area-inset-top) - 0.75rem);
    max-width: 34rem;
    display: flex;
    flex-direction: column;
    overflow: hidden;
    border: 1px solid var(--atlas-glass-border);
    border-radius: 2.25rem 2.25rem 0 0;
    color: var(--atlas-ink);
    background: rgba(248, 251, 255, 0.68);
    backdrop-filter: blur(28px) saturate(1.3);
    -webkit-backdrop-filter: blur(28px) saturate(1.3);
    box-shadow: 0 -14px 45px rgba(15, 23, 42, 0.2);
    font-family: var(--atlas-font);
}

.refined-ui .achievement-detail-toolbar {
    position: relative;
    min-height: 3rem;
    display: flex;
    justify-content: flex-end;
    flex: 0 0 auto;
    padding: 0.45rem 0.6rem 0;
}
.refined-ui .achievement-detail-toolbar::before {
    content: '';
    position: absolute;
    top: 0.75rem;
    left: 50%;
    width: 3rem;
    height: 0.35rem;
    border-radius: 999px;
    background: #dfe5ee;
    transform: translateX(-50%);
}
.refined-ui .achievement-detail-close {
    position: relative;
    width: 2rem;
    height: 2rem;
    background: var(--atlas-card);
    font-size: 0.78rem;
}
.refined-ui .achievement-detail-close::after {
    content: '';
    position: absolute;
    inset: -0.375rem;
}
.refined-ui .achievement-detail-close i { font-size: 0.78rem !important; }

.refined-ui .achievement-detail-scroll {
    flex: 1 1 auto;
    min-height: 0;
    padding: 0 1.5rem calc(env(safe-area-inset-bottom) + 1.5rem);
    overflow-x: hidden;
    overflow-y: auto;
    overscroll-behavior-y: contain;
    scrollbar-width: none;
}
.refined-ui .achievement-detail-scroll::-webkit-scrollbar { display: none; }

.refined-ui .atlas-detail-hero { text-align: center; }
.refined-ui .atlas-detail-hero .atlas-artwork { margin: 0 auto; }
.refined-ui .atlas-detail-pills {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    margin-top: 0.85rem;
}
.refined-ui .atlas-detail-category,
.refined-ui .atlas-detail-status {
    display: inline-flex;
    align-items: center;
    min-height: 1.75rem;
    padding: 0 0.7rem;
    border-radius: 999px;
    color: #66758a;
    border: 1px solid var(--atlas-glass-border);
    background: var(--atlas-card);
    box-shadow: var(--atlas-glass-shadow);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    font: 700 0.7rem/1 var(--atlas-display);
}
.refined-ui .atlas-detail-status.is-earned {
    border: 1px solid #fecdd6;
    color: #be123c;
    background: rgba(255, 232, 239, 0.6);
}
.refined-ui .atlas-detail-status.is-earned::before { content: '✓ '; }
.refined-ui .atlas-detail-hero h2 {
    margin-top: 0.65rem;
    color: var(--atlas-ink);
    font: 900 1.55rem/1.2 var(--atlas-display);
    letter-spacing: -0.035em;
}
.refined-ui .atlas-detail-hero > p {
    max-width: 22rem;
    margin: 0.3rem auto 0;
    color: var(--atlas-muted);
    font-size: 0.78rem;
    font-weight: 500;
    line-height: 1.5;
}
.refined-ui .atlas-detail-body { margin-top: 1.25rem; }

.refined-ui .atlas-detail-passport {
    overflow: hidden;
    padding: 0 0.95rem;
    border: 1px solid var(--atlas-glass-border);
    border-radius: 1.35rem;
    background: var(--atlas-card);
    box-shadow: var(--atlas-glass-shadow);
    backdrop-filter: blur(16px) saturate(1.2);
    -webkit-backdrop-filter: blur(16px) saturate(1.2);
}
.refined-ui .atlas-detail-passport > div {
    min-height: 3rem;
    display: grid;
    grid-template-columns: minmax(7.25rem, auto) minmax(0, 1fr);
    align-items: center;
    gap: 0.75rem;
    border-top: 1px solid #e7ebf1;
}
.refined-ui .atlas-detail-passport > div:first-child { border-top: 0; }
.refined-ui .atlas-detail-passport span {
    color: #99a7ba;
    font-size: calc(0.75rem - 2px);
    font-weight: 600;
    text-align: left;
}
.refined-ui .atlas-detail-passport strong {
    color: #273248;
    font-size: calc(0.76rem - 2px);
    font-weight: 800;
    text-align: right;
    overflow-wrap: anywhere;
}
.refined-ui .atlas-detail-passport strong.is-accent { color: var(--atlas-rose); }

.refined-ui .atlas-photo-reel,
.refined-ui .atlas-detail-section { margin-top: 1.15rem; }
.refined-ui .atlas-photo-reel header {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 0.75rem;
    margin-bottom: 0.55rem;
}
.refined-ui .atlas-photo-reel h3,
.refined-ui .atlas-detail-section h3 {
    color: #8797ad;
    font: 800 0.75rem/1.2 var(--atlas-display);
    letter-spacing: 0.04em;
}
.refined-ui .atlas-photo-reel header span { color: #9caabd; font-size: 0.66rem; }
.refined-ui .atlas-photo-track {
    display: flex;
    gap: 0.55rem;
    overflow-x: auto;
    overscroll-behavior-inline: contain;
    scroll-snap-type: x mandatory;
    scrollbar-width: none;
    -webkit-overflow-scrolling: touch;
    touch-action: pan-x;
}
.refined-ui .atlas-photo-track::-webkit-scrollbar { display: none; }
.refined-ui .atlas-photo-reel img {
    width: clamp(8.25rem, 42vw, 10.5rem);
    flex: 0 0 clamp(8.25rem, 42vw, 10.5rem);
    aspect-ratio: 1.35;
    display: block;
    border-radius: 0.85rem;
    object-fit: cover;
    background: #edf1f5;
    scroll-snap-align: start;
}

.refined-ui .atlas-trip-list { display: grid; gap: 0.45rem; }
.refined-ui .atlas-trip-list button {
    min-height: 2.75rem;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.75rem;
    padding: 0.55rem 0.75rem;
    border: 1px solid var(--atlas-glass-border);
    border-radius: 0.9rem;
    color: var(--atlas-ink);
    background: var(--atlas-card);
    box-shadow: var(--atlas-glass-shadow);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    text-align: left;
    font-size: 0.75rem;
    font-weight: 700;
}
.refined-ui .atlas-trip-list button span { flex: 0 0 auto; color: var(--atlas-rose); font-size: 0.65rem; }
.refined-ui .atlas-detail-empty { margin-top: 0.35rem; color: #9aa7b9; font-size: 0.72rem; }

.refined-ui #achievement-container {
    position: fixed !important;
    inset: 0 !important;
    width: 100vw !important;
    transform: none !important;
    pointer-events: none;
}

.achievement-notice {
    position: fixed;
    inset: 0;
    z-index: 1;
    width: 100%;
    min-height: 100dvh;
    display: grid;
    place-items: center;
    padding: calc(env(safe-area-inset-top) + 1rem) 1.25rem calc(env(safe-area-inset-bottom) + 1rem);
    overflow: hidden;
    color: #fff;
    background:
        radial-gradient(circle at 50% 38%, rgba(245, 158, 11, 0.17), transparent 18rem),
        rgba(8, 12, 22, 0.78);
    pointer-events: auto;
    backdrop-filter: blur(16px) saturate(0.84);
    -webkit-backdrop-filter: blur(16px) saturate(0.84);
    animation: achievementNoticeIn 360ms ease both;
}
.achievement-notice.is-leaving { animation: achievementNoticeOut 180ms ease both; }
.achievement-unlock-card {
    position: relative;
    width: min(100%, 20rem);
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 2.25rem 1.5rem 1.4rem;
    overflow: hidden;
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 1.75rem;
    text-align: center;
    background: linear-gradient(145deg, rgba(40, 45, 62, 0.92), rgba(16, 22, 38, 0.94));
    box-shadow: 0 30px 70px rgba(0, 0, 0, 0.55), inset 0 1px 0 rgba(255, 255, 255, 0.22);
    transform-origin: 50% 62%;
    animation: achievementUnlockCardIn 620ms cubic-bezier(0.34, 1.56, 0.64, 1) both;
}
.achievement-unlock-card::before {
    content: '';
    position: absolute;
    inset: 0;
    background: radial-gradient(circle at 50% 18%, rgba(254, 240, 138, 0.12), transparent 42%);
    pointer-events: none;
}
.achievement-unlock-stamp {
    position: relative;
    width: 8.4rem;
    height: 8.4rem;
    display: grid;
    place-items: center;
    margin-bottom: 1.15rem;
    isolation: isolate;
}
.achievement-notice-art {
    position: relative;
    z-index: 3;
    width: 100%;
    height: 100%;
    display: grid;
    place-items: center;
    opacity: 0;
    transform: scale(3.5) rotate(-25deg);
    animation: achievementStampImpact 680ms 180ms cubic-bezier(0.18, 0.89, 0.32, 1.28) forwards;
}
.achievement-notice-art .atlas-artwork-notice { width: 7.65rem; }
.achievement-notice-art .atlas-artwork-notice img {
    border-color: #fff;
    background: rgba(255, 255, 255, 0.94);
    box-shadow: 0 0 0 3px #f59e0b, 0 0 34px rgba(245, 158, 11, 0.5);
}
.achievement-unlock-shockwave {
    position: absolute;
    z-index: 1;
    inset: 0.15rem;
    border: 3px solid rgba(254, 240, 138, 0.9);
    border-radius: 50%;
    opacity: 0;
    pointer-events: none;
    animation: achievementShockwave 900ms 520ms ease-out forwards;
}
.achievement-unlock-shockwave.is-delayed { animation-delay: 660ms; }
.achievement-unlock-shimmer {
    position: absolute;
    z-index: 4;
    inset: -55%;
    background: linear-gradient(135deg, transparent 40%, rgba(255, 255, 255, 0.72) 50%, transparent 60%);
    opacity: 0;
    pointer-events: none;
    transform: translate3d(-55%, -55%, 0) rotate(45deg);
    animation: achievementUnlockShimmer 900ms 720ms ease-out forwards;
}
.achievement-notice-copy { position: relative; z-index: 2; min-width: 0; }
.achievement-notice-copy > span { color: #fbbf24; font: 800 0.65rem/1 var(--atlas-body); letter-spacing: 0.16em; }
.achievement-notice-copy strong,
.achievement-notice-copy small { display: block; }
.achievement-notice-copy strong { margin-top: 0.45rem; color: #fff; font: 900 1.45rem/1.15 var(--atlas-display); }
.achievement-notice-copy small { max-width: 15rem; margin: 0.5rem auto 0; color: #cbd5e1; font-size: 0.78rem; font-weight: 500; line-height: 1.5; }
.achievement-notice-actions { position: relative; z-index: 2; width: 100%; display: grid; gap: 0.45rem; margin-top: 1.35rem; }
.achievement-notice-actions button { min-height: 2.85rem; padding: 0 1rem; border-radius: 0.9rem; color: #fff; background: linear-gradient(135deg, #f59e0b, #d97706); box-shadow: 0 8px 20px rgba(217, 119, 6, 0.3); font-size: 0.82rem; font-weight: 800; }
.achievement-notice-actions button:active { transform: scale(0.97); }
.achievement-notice-actions button:last-child { min-height: 2.2rem; color: #aeb9ca; background: transparent; box-shadow: none; }

@keyframes achievementNoticeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}
@keyframes achievementNoticeOut { to { opacity: 0; } }
@keyframes achievementUnlockCardIn {
    from { opacity: 0; transform: scale(0.62) rotateX(28deg); }
    to { opacity: 1; transform: scale(1) rotateX(0deg); }
}
@keyframes achievementStampImpact {
    0% { opacity: 0; transform: scale(3.5) rotate(-25deg); }
    68% { opacity: 1; transform: scale(0.92) rotate(3deg); }
    84% { opacity: 1; transform: scale(1.07) rotate(-1deg); }
    100% { opacity: 1; transform: scale(1) rotate(0deg); }
}
@keyframes achievementShockwave {
    0% { opacity: 0.9; transform: scale(0.72); }
    100% { opacity: 0; transform: scale(1.7); }
}
@keyframes achievementUnlockShimmer {
    0% { opacity: 0; transform: translate3d(-55%, -55%, 0) rotate(45deg); }
    25% { opacity: 1; }
    100% { opacity: 0; transform: translate3d(55%, 55%, 0) rotate(45deg); }
}
@keyframes atlasBadgeShimmer {
    0% { background-position: -120% -120%; }
    100% { background-position: 120% 120%; }
}
@keyframes atlasUnreadPulse {
    0%, 100% { opacity: 0.42; transform: scale(0.82); }
    50% { opacity: 1; transform: scale(1.08); }
}
@keyframes atlasSpin { to { transform: rotate(360deg); } }

@media (min-width: 600px) {
    .refined-ui #achievement-book-modal { align-items: center !important; padding: 1rem !important; }
    .refined-ui #achievement-book-content {
        height: min(56rem, calc(100dvh - 2rem)) !important;
        border-radius: 2.25rem !important;
    }
    .refined-ui #achievement-detail-modal { align-items: center; padding: 1rem; }
    .refined-ui #achievement-detail-content { border-radius: 2.25rem; }
}

@media (max-width: 359px) {
    .refined-ui .achievement-atlas-hero { padding-right: 1rem; padding-left: 1rem; }
    .refined-ui #achievement-book-list { padding-right: 1rem !important; padding-left: 1rem !important; }
    .refined-ui .atlas-grid { column-gap: 0.35rem; }
    .refined-ui .atlas-artwork-standard { width: 5.4rem; }
    .refined-ui .atlas-badge-name { font-size: 0.8rem; }
}

@media (prefers-reduced-motion: reduce) {
    .achievement-notice,
    .achievement-notice.is-leaving,
    .achievement-unlock-card,
    .achievement-notice-art,
    .achievement-unlock-shockwave,
    .achievement-unlock-shimmer,
    .refined-ui .atlas-loading > span,
    .refined-ui .atlas-artwork-clip::after,
    .refined-ui .atlas-artwork img,
    .refined-ui .atlas-badge,
    .refined-ui .achievement-atlas-title.has-unread-achievement::after,
    .refined-ui .achievement-atlas-tab,
    .refined-ui .achievement-atlas-filter { animation: none !important; transition: none !important; }
}
