/* ── dashboard.css ── Home page, profile center, dashboard sheets, team center ── */

.home-notice-section {
    padding-bottom: 0;
}

.home-notice-card {
    padding: 0;
    overflow: hidden;
    position: relative;
    border: 1px solid rgba(191, 150, 95, 0.18);
    border-radius: 24px;
    background:
        linear-gradient(135deg, rgba(255, 251, 244, 0.98), rgba(247, 238, 226, 0.97)),
        radial-gradient(circle at top right, rgba(199, 154, 70, 0.08), transparent 34%);
    box-shadow:
        0 18px 36px rgba(87, 51, 20, 0.08),
        inset 0 1px 0 rgba(255, 255, 255, 0.82);
}

.home-notice-card::before,
.home-notice-card::after {
    content: "";
    position: absolute;
    left: 18px;
    right: 18px;
    height: 1px;
    background: linear-gradient(90deg, transparent, rgba(209, 166, 97, 0.3), transparent);
    pointer-events: none;
}

.home-notice-card::before {
    top: 10px;
}

.home-notice-card::after {
    bottom: 10px;
}

.home-notice-shell {
    display: grid;
    grid-template-columns: 184px minmax(0, 1fr);
    align-items: stretch;
    min-height: 86px;
}

.home-notice-marker {
    position: relative;
    display: grid;
    align-content: center;
    gap: 8px;
    padding: 16px 18px;
    background:
        linear-gradient(180deg, rgba(247, 237, 220, 0.98), rgba(240, 225, 204, 0.96)),
        radial-gradient(circle at top left, rgba(205, 159, 87, 0.13), transparent 40%);
    border-right: 1px solid rgba(191, 150, 95, 0.12);
}

.home-notice-marker::after {
    content: "";
    position: absolute;
    top: 14px;
    right: -1px;
    bottom: 14px;
    width: 16px;
    background: linear-gradient(180deg, rgba(198, 154, 83, 0.1), rgba(198, 154, 83, 0));
    clip-path: polygon(0 0, 100% 50%, 0 100%);
}

.home-notice-seal {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 44px;
    height: 44px;
    border-radius: 14px;
    background:
        linear-gradient(135deg, rgba(255, 244, 216, 0.98), rgba(228, 189, 112, 0.94));
    color: #734619;
    box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, 0.46),
        0 10px 18px rgba(110, 72, 28, 0.14);
    font-size: 1.05rem;
    font-weight: 800;
    letter-spacing: 0.08em;
}

.home-notice-marker-copy {
    display: grid;
    gap: 3px;
    color: #54321b;
}

.home-notice-marker-copy strong {
    font-size: 0.96rem;
    font-weight: 800;
    letter-spacing: 0.04em;
}

.home-notice-marker-copy small {
    color: rgba(107, 80, 52, 0.66);
    font-size: 0.72rem;
    letter-spacing: 0.03em;
}

.home-notice-feed {
    display: grid;
    gap: 8px;
    padding: 12px 14px 12px 16px;
    min-width: 0;
}

.home-notice-item {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    align-items: center;
    gap: 16px;
    min-width: 0;
    padding: 10px 13px;
    border-radius: 15px;
    background:
        linear-gradient(180deg, rgba(255, 255, 255, 0.72), rgba(249, 240, 227, 0.82));
    border: 1px solid rgba(191, 150, 95, 0.08);
    box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, 0.76),
        0 8px 18px rgba(87, 51, 20, 0.04);
}

.home-notice-main {
    display: flex;
    align-items: center;
    gap: 12px;
    min-width: 0;
}

.home-notice-title {
    flex-shrink: 0;
    display: inline-flex;
    align-items: center;
    min-height: 28px;
    max-width: 220px;
    padding: 0 11px;
    border-radius: 999px;
    background: rgba(212, 167, 94, 0.14);
    color: #8b5a24;
    font-size: 0.78rem;
    font-weight: 700;
    letter-spacing: 0.03em;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.home-notice-time {
    flex-shrink: 0;
    color: rgba(153, 118, 80, 0.76);
    font-size: 0.74rem;
    font-weight: 700;
}

.home-notice-body {
    min-width: 0;
    color: rgba(90, 64, 43, 0.84);
    font-size: 0.88rem;
    line-height: 1.6;
}

.home-bonus-ranking {
    padding: 12px 14px;
    border-top: 1px solid rgba(95, 70, 56, 0.08);
}

.home-bonus-tabs {
    display: flex;
    gap: 4px;
    margin-bottom: 10px;
}

.home-bonus-tab {
    flex: 1;
    padding: 5px 0;
    border: none;
    border-radius: 8px;
    background: transparent;
    color: var(--muted);
    font-size: 0.78rem;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.15s, color 0.15s;
}

.home-bonus-tab:hover {
    background: rgba(255, 255, 255, 0.04);
}

.home-bonus-tab.is-active {
    background: var(--accent-soft);
    color: var(--accent);
}

.home-bonus-panel[hidden] {
    display: none;
}

.home-bonus-empty {
    margin: 0;
    padding: 8px 0;
    text-align: center;
    color: var(--muted);
    font-size: 0.8rem;
}

.home-bonus-ranking-list {
    display: grid;
    gap: 6px;
}

.home-bonus-ranking-row {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 6px 10px;
    border-radius: 10px;
}

.home-bonus-ranking-row:nth-child(-n+3) {
    background: rgba(212, 168, 60, 0.06);
}

.home-bonus-rank {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 22px;
    height: 22px;
    border-radius: 50%;
    background: rgba(0, 0, 0, 0.06);
    font-size: 0.72rem;
    font-weight: 700;
    flex-shrink: 0;
}

.home-bonus-ranking-row:nth-child(1) .home-bonus-rank { background: rgba(212, 168, 60, 0.2); color: #8b6a20; }
.home-bonus-ranking-row:nth-child(2) .home-bonus-rank { background: rgba(160, 160, 170, 0.18); color: #6a6a70; }
.home-bonus-ranking-row:nth-child(3) .home-bonus-rank { background: rgba(180, 120, 70, 0.16); color: #7a5a30; }

.home-bonus-name {
    flex: 1;
    min-width: 0;
    font-size: 0.86rem;
    font-weight: 600;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.home-bonus-more {
    width: 100%;
    margin-top: 6px;
    padding: 6px;
    border: none;
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.04);
    color: var(--accent);
    font-size: 0.78rem;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.15s;
}

.home-bonus-more:hover {
    background: var(--accent-soft);
}

.home-bonus-more-btn {
    width: 100%;
    margin-top: 6px;
    padding: 6px;
    border: none;
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.04);
    color: var(--accent);
    font-size: 0.78rem;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.15s;
}

.home-bonus-more-btn:hover {
    background: var(--accent-soft);
}

.home-kpi-grid .ops-kpi {
    min-height: 136px;
    border-radius: 24px;
}

.home-video-stage,
.home-module-card {
    display: grid;
    gap: 16px;
}

.home-video-stage {
    padding: 18px;
    border-radius: 30px;
}

.home-video-slide[hidden] {
    display: none;
}

.home-video-frame {
    position: relative;
    overflow: hidden;
    border-radius: 24px;
    background: linear-gradient(180deg, rgba(27, 17, 13, 0.96), rgba(15, 9, 7, 0.98));
    min-height: 260px;
}

.home-video-frame video {
    width: 100%;
    border-radius: 0;
}

.home-video-fallback {
    min-height: 260px;
    place-items: center;
    text-align: center;
    padding: 32px;
    color: #f8efe3;
}

.home-video-fallback p {
    margin: 0;
    color: rgba(248, 239, 227, 0.8);
}

.home-video-meta {
    display: flex;
    justify-content: space-between;
    gap: 16px;
    align-items: flex-end;
    flex-wrap: wrap;
}

.home-video-meta-compact {
    justify-content: flex-end;
    min-height: 24px;
}

.home-video-copy {
    display: grid;
    gap: 8px;
}

.home-video-copy h3 {
    margin: 0;
    font-size: 1.5rem;
}

.home-video-copy p,
.home-video-note small {
    margin: 0;
    color: var(--muted);
    line-height: 1.8;
}

.home-video-note {
    display: grid;
    gap: 8px;
    justify-items: start;
}

.home-video-title-badge {
    position: absolute;
    left: 18px;
    right: 18px;
    bottom: 18px;
    display: flex;
    justify-content: flex-start;
    pointer-events: none;
}

.home-video-title-badge strong {
    max-width: min(100%, 520px);
    padding: 10px 14px;
    border-radius: 14px;
    background: rgba(17, 11, 8, 0.62);
    color: #fff7ea;
    font-size: 1rem;
    line-height: 1.4;
    box-shadow: 0 14px 28px rgba(10, 6, 4, 0.2);
    backdrop-filter: blur(8px);
}

.home-video-pagination {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 14px;
    flex-wrap: wrap;
}

.home-video-dots {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    flex: 1 1 auto;
    flex-wrap: wrap;
}

.home-video-dot {
    min-width: 34px;
    height: 34px;
    padding: 0 10px;
    border: 1px solid rgba(95, 70, 56, 0.14);
    border-radius: 10px;
    background: rgba(255, 252, 248, 0.92);
    color: var(--muted);
    font-weight: 700;
}

.home-video-dot.is-active {
    background: var(--accent);
    border-color: var(--accent);
    color: #fff;
}

.home-module-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 16px;
}

.home-module-card {
    min-height: 94px;
    padding: 18px 22px;
    border-radius: 22px;
}

.home-module-action {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    width: 100%;
    border: 1px solid rgba(116, 77, 43, 0.22);
    background:
        linear-gradient(180deg, rgba(88, 55, 37, 0.96), rgba(59, 34, 22, 0.98)),
        repeating-linear-gradient(
            90deg,
            rgba(255, 255, 255, 0.05) 0,
            rgba(255, 255, 255, 0.05) 1px,
            transparent 1px,
            transparent 28px
        );
    box-shadow: 0 18px 38px rgba(51, 27, 16, 0.18);
    color: #fff7ea;
    text-align: left;
    transition: transform 180ms ease, box-shadow 180ms ease, border-color 180ms ease;
}

.home-module-action:hover {
    transform: translateY(-2px);
    border-color: rgba(206, 169, 95, 0.32);
    box-shadow: 0 22px 42px rgba(45, 23, 14, 0.22);
}

.home-module-inner {
    display: flex;
    align-items: center;
    gap: 14px;
    min-width: 0;
}

.home-module-icon {
    display: grid;
    place-items: center;
    width: 36px;
    height: 36px;
    flex: 0 0 36px;
    border-radius: 50%;
    border: 1px solid rgba(217, 187, 115, 0.42);
    background: rgba(255, 245, 221, 0.06);
    color: #d9bb73;
    font-size: 0.95rem;
    font-weight: 700;
}

.home-module-text {
    display: grid;
    gap: 4px;
    min-width: 0;
}

.home-module-text strong {
    font-size: 1.2rem;
    letter-spacing: 0.02em;
}

.home-module-text small {
    color: rgba(249, 234, 208, 0.72);
    line-height: 1.4;
}

.home-module-arrow {
    color: #d3ae62;
    font-size: 1.2rem;
    line-height: 1;
}

.home-shelf-bar {
    display: flex;
    justify-content: space-between;
    gap: 18px;
    align-items: center;
    flex-wrap: wrap;
}

.home-shelf-title {
    display: flex;
    align-items: baseline;
    gap: 14px;
}

.home-shelf-title h2 {
    margin: 0;
    padding-left: 16px;
    border-left: 6px solid #9c2d2d;
    font-size: clamp(1.7rem, 3vw, 2.35rem);
}

.home-shelf-title span {
    color: #b6a28c;
    letter-spacing: 0.12em;
    font-size: 1rem;
}

.home-shelf-tools {
    display: flex;
    align-items: center;
    gap: 12px;
    flex-wrap: wrap;
}

.home-shelf-reroll {
    min-height: 52px;
    padding-inline: 18px;
    white-space: nowrap;
}

.home-shelf-search-inline {
    display: flex;
    align-items: center;
    gap: 0;
    min-width: min(100%, 360px);
    border: 1px solid rgba(95, 70, 56, 0.08);
    border-radius: 0;
    background: rgba(255, 255, 255, 0.9);
    overflow: hidden;
}

.home-shelf-search-inline input {
    border: 0;
    border-radius: 0;
    min-height: 52px;
    padding: 0 18px;
    background: transparent;
}

.home-shelf-search-inline button {
    width: 58px;
    min-height: 52px;
    border: 0;
    background: transparent;
    color: #b4892f;
    font-size: 1.5rem;
}

.book-corridor {
    overflow: hidden;
    padding: 30px 10px 10px;
    background:
        linear-gradient(180deg, rgba(250, 244, 235, 0.95), rgba(245, 236, 224, 0.98)),
        repeating-linear-gradient(
            90deg,
            rgba(203, 171, 120, 0.08) 0,
            rgba(203, 171, 120, 0.08) 2px,
            transparent 2px,
            transparent 66px
        );
    border-radius: 28px;
    border: 1px solid rgba(95, 70, 56, 0.08);
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.48);
    scrollbar-width: none;
    -ms-overflow-style: none;
    touch-action: pan-x;
}

.book-corridor::-webkit-scrollbar {
    display: none;
}

.book-corridor-track {
    display: flex;
    align-items: flex-end;
    gap: 18px;
    width: max-content;
    padding-right: 18px;
    will-change: transform;
}

.corridor-book {
    display: block;
    width: 166px;
    flex: 0 0 166px;
    padding: 0;
    border: 0;
    background: transparent;
    appearance: none;
    cursor: pointer;
}

.corridor-book:hover .corridor-book-shell {
    transform: translateY(-8px);
    box-shadow: 16px 18px 34px rgba(47, 31, 22, 0.24);
}

.corridor-book-shell {
    position: relative;
    display: block;
    width: 100%;
    height: 220px;
    border-radius: 4px 10px 10px 4px;
    box-shadow: 12px 12px 26px rgba(47, 31, 22, 0.18);
    overflow: hidden;
    transition: transform 220ms ease, box-shadow 220ms ease;
}

.corridor-book-shell.palette-umber {
    background: linear-gradient(90deg, #222 0 16%, #4f3027 16%, #5b382d 88%, #f2e2c9 88%);
}

.corridor-book-shell.palette-slate {
    background: linear-gradient(90deg, #222 0 16%, #334550 16%, #405661 88%, #f2e2c9 88%);
}

.corridor-book-shell.palette-graphite {
    background: linear-gradient(90deg, #222 0 16%, #3d3e41 16%, #4b4d50 88%, #f2e2c9 88%);
}

.corridor-book-spine {
    position: absolute;
    left: 8px;
    top: 16px;
    bottom: 16px;
    width: 3px;
    background: repeating-linear-gradient(
        180deg,
        rgba(255, 255, 255, 0.88) 0 4px,
        transparent 4px 44px
    );
}

.corridor-book-label {
    position: absolute;
    top: 48px;
    left: 50%;
    transform: translateX(-50%);
    display: inline-grid;
    place-items: center;
    width: 44px;
    min-height: 86px;
    padding: 8px 6px;
    background: #fcf6ef;
    border: 2px solid rgba(150, 126, 99, 0.24);
    box-shadow: inset 0 0 0 2px rgba(232, 220, 205, 0.8);
    writing-mode: vertical-rl;
    text-orientation: mixed;
    letter-spacing: 0.06em;
    color: #1f1714;
}

.corridor-book-stamp {
    position: absolute;
    right: 16px;
    bottom: 16px;
    width: 42px;
    height: 42px;
    border: 2px solid rgba(164, 43, 43, 0.85);
    color: rgba(164, 43, 43, 0.85);
    display: grid;
    place-items: center;
    transform: rotate(12deg);
    font-size: 0.78rem;
    writing-mode: vertical-rl;
}

.corridor-book-edge {
    position: absolute;
    right: 0;
    top: 0;
    bottom: 0;
    width: 14px;
    background: linear-gradient(180deg, rgba(255, 251, 245, 0.85), rgba(240, 224, 195, 0.95));
}

.home-books-masonry {
    column-count: 3;
    column-gap: 18px;
}

.home-book-card {
    display: inline-grid;
    width: 100%;
    gap: 14px;
    padding: 16px;
    margin: 0 0 18px;
    border: 1px solid rgba(95, 70, 56, 0.08);
    border-radius: 24px;
    background: linear-gradient(180deg, rgba(255, 251, 246, 0.96), rgba(248, 240, 230, 0.96));
    box-shadow: 0 14px 34px rgba(61, 38, 24, 0.08);
    break-inside: avoid;
    cursor: pointer;
    transition: transform 200ms ease, box-shadow 200ms ease, border-color 200ms ease;
}

.home-book-card:hover {
    transform: translateY(-4px);
    border-color: rgba(180, 111, 54, 0.24);
    box-shadow: 0 18px 38px rgba(61, 38, 24, 0.12);
}

.home-book-card-media {
    display: block;
    overflow: hidden;
    border-radius: 18px;
    border: 1px solid rgba(95, 70, 56, 0.08);
    background: rgba(255, 255, 255, 0.62);
}

.home-book-card-media img,
.home-book-card-placeholder {
    display: block;
    width: 100%;
    min-height: 188px;
}

.home-book-card-media img {
    object-fit: cover;
}

.home-book-card-placeholder {
    display: grid;
    place-items: center;
    color: var(--muted);
    background:
        radial-gradient(circle at top, rgba(196, 158, 100, 0.14), transparent 58%),
        linear-gradient(180deg, rgba(251, 246, 239, 0.94), rgba(242, 232, 219, 0.98));
}

.home-book-card-body {
    display: grid;
    gap: 10px;
    text-align: left;
}

.home-book-card-head {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    align-items: start;
    gap: 10px;
}

.home-book-card-title {
    font-size: 1.05rem;
    line-height: 1.3;
}

.home-book-card-pages {
    display: inline-flex;
    align-items: center;
    padding: 6px 10px;
    border-radius: 999px;
    background: rgba(95, 70, 56, 0.08);
    color: #6b4a35;
    font-size: 0.82rem;
}

.home-book-card-tags {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
}

.home-book-card-excerpt {
    color: var(--muted);
    line-height: 1.75;
}

.home-book-card--masonry .home-book-card-media img,
.home-book-card--masonry .home-book-card-placeholder {
    min-height: 220px;
}

@media (max-width: 980px) {
    .home-books-masonry {
        column-count: 2;
    }

    .profile-summary-card {
        grid-template-columns: minmax(0, 1fr) minmax(200px, 34%);
    }
}

@media (max-width: 720px) {
    .home-books-masonry {
        column-count: 1;
        column-gap: 0;
    }

    .home-book-card {
        padding: 14px;
        border-radius: 20px;
    }

    .home-book-card-media img,
    .home-book-card-placeholder {
        min-height: 168px;
    }
}


/* ── Profile Center & Dashboard Sheets ── */

.profile-center-shell {
    display: grid;
    gap: 18px;
}

.profile-summary-card {
    padding: 12px 14px;
    border-radius: 18px;
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(280px, 34%);
    align-items: center;
    column-gap: 14px;
    row-gap: 8px;
    background:
        linear-gradient(180deg, rgba(255, 251, 247, 0.92), rgba(247, 240, 232, 0.84));
}

.profile-summary-head,
.profile-summary-main,
.profile-summary-tags,
.profile-edit-head {
    display: flex;
    align-items: center;
    gap: 14px;
    flex-wrap: wrap;
}

.profile-summary-head {
    justify-content: space-between;
    gap: 8px;
    min-width: 0;
}

.profile-summary-main,
.profile-edit-head {
    align-items: center;
}

.profile-summary-copy {
    display: grid;
    gap: 4px;
    min-width: 0;
    flex: 1;
}

.profile-summary-title-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
}

.profile-summary-copy h1 {
    margin: 0;
    font-size: clamp(1.02rem, 1.7vw, 1.28rem);
    line-height: 1.1;
}

.profile-summary-edit {
    min-width: 0;
    min-height: 30px;
    padding: 0 10px;
    border-radius: 10px;
    flex-shrink: 0;
    font-size: 0.82rem;
}

.profile-summary-copy p {
    margin: 0;
    color: var(--muted);
    line-height: 1.4;
    font-size: 0.82rem;
}

.profile-summary-bio {
    display: -webkit-box;
    -webkit-line-clamp: 1;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.profile-summary-head > .icon-action-button {
    display: none;
}

.profile-summary-main .avatar-md,
.profile-summary-main .avatar-lg {
    width: 54px;
    height: 54px;
    flex-shrink: 0;
}

.profile-summary-stats {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 8px;
    align-self: stretch;
}

.profile-summary-stat {
    display: grid;
    gap: 1px;
    min-width: 0;
    padding: 8px 10px;
    border: 1px solid rgba(95, 70, 56, 0.08);
    border-radius: 12px;
    background: rgba(255, 255, 255, 0.64);
    align-content: center;
}

.profile-summary-stat small {
    color: var(--muted);
    font-size: 0.66rem;
    line-height: 1;
}

.profile-summary-stat strong {
    font-size: 0.84rem;
    line-height: 1.2;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.profile-summary-stat[data-modal-open] {
    cursor: pointer;
    transition: border-color 0.15s, background 0.15s;
}

.profile-summary-stat[data-modal-open]:hover {
    border-color: var(--accent-soft);
    background: rgba(255, 255, 255, 0.78);
}

.profile-stat-action {
    display: inline-flex;
    align-items: center;
    gap: 2px;
    margin-top: 2px;
    padding: 3px 10px;
    border-radius: 6px;
    background: var(--accent);
    color: #fff;
    font-size: 0.68rem;
    font-weight: 600;
    letter-spacing: 0.03em;
    line-height: 1.4;
    white-space: nowrap;
}

.icon-action-button {
    min-width: 54px;
    min-height: 42px;
    border: 1px solid rgba(95, 70, 56, 0.1);
    border-radius: 14px;
    background: rgba(255, 255, 255, 0.66);
    color: var(--muted);
}

.profile-card-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 14px;
}

.profile-action-card {
    display: grid;
    grid-template-columns: auto 1fr auto;
    align-items: center;
    gap: 14px;
    width: 100%;
    padding: 18px 20px;
    text-align: left;
}

.profile-action-card-wide {
    grid-column: 1 / -1;
}

.profile-action-icon {
    display: inline-grid;
    place-items: center;
    width: 44px;
    height: 44px;
    border-radius: 14px;
    font-size: 1rem;
    font-weight: 700;
}

.action-blue {
    color: #3974df;
    background: rgba(57, 116, 223, 0.12);
}

.action-gold {
    color: #d28a11;
    background: rgba(210, 138, 17, 0.14);
}

.action-violet {
    color: #9150ef;
    background: rgba(145, 80, 239, 0.12);
}

.action-indigo {
    color: #5967ea;
    background: rgba(89, 103, 234, 0.12);
}

.action-rose {
    color: #cf5d7b;
    background: rgba(207, 93, 123, 0.14);
}

.profile-action-copy {
    display: grid;
    gap: 4px;
}

.profile-action-copy strong {
    font-size: 1.02rem;
}

.profile-action-copy small {
    color: var(--muted);
    line-height: 1.6;
}

.profile-action-arrow {
    color: #b9ab9c;
    font-size: 1.35rem;
    line-height: 1;
}

.dashboard-sheet {
    display: grid;
    gap: 18px;
    width: min(960px, 100%);
    padding: 24px;
}

.dashboard-sheet-profile {
    width: min(420px, 100%);
    gap: 14px;
    padding: 14px;
}

.dashboard-sheet-profile .dashboard-sheet-header {
    padding: 0 44px 10px 0;
    border-radius: 18px 18px 14px 14px;
}

.dashboard-sheet-profile .dashboard-sheet-header p {
    display: none;
}

.dashboard-sheet-profile .profile-edit-head {
    gap: 12px;
    align-items: center;
}

.dashboard-sheet-profile .profile-edit-head .avatar-lg {
    width: 72px;
    height: 72px;
}

.dashboard-sheet-profile .form-grid {
    gap: 12px;
    grid-template-columns: repeat(2, minmax(0, 1fr));
}

.dashboard-sheet-profile textarea {
    min-height: 76px;
}

.dashboard-sheet-profile .dashboard-subform {
    padding-top: 12px;
}


.profile-select-field {
    padding: 12px 12px 10px;
    border: 1px solid rgba(95, 70, 56, 0.08);
    border-radius: 14px;
    background: rgba(255, 255, 255, 0.72);
}

.profile-select-field--primary {
    border-color: rgba(70, 131, 106, 0.18);
    background:
        linear-gradient(180deg, rgba(240, 250, 244, 0.96), rgba(232, 246, 238, 0.88));
    box-shadow: inset 0 0 0 1px rgba(70, 131, 106, 0.06);
}

.profile-select-field--name {
    border-color: rgba(92, 103, 233, 0.18);
    background:
        linear-gradient(180deg, rgba(242, 245, 255, 0.96), rgba(234, 239, 252, 0.9));
    box-shadow: inset 0 0 0 1px rgba(92, 103, 233, 0.06);
}

.profile-select-field--platform {
    border-color: rgba(111, 123, 160, 0.16);
    background:
        linear-gradient(180deg, rgba(247, 248, 251, 0.96), rgba(238, 241, 246, 0.9));
    box-shadow: inset 0 0 0 1px rgba(111, 123, 160, 0.05);
}

.profile-select-field--battle {
    border-color: rgba(174, 104, 54, 0.2);
    background:
        linear-gradient(180deg, rgba(255, 247, 239, 0.96), rgba(250, 238, 226, 0.88));
    box-shadow: inset 0 0 0 1px rgba(174, 104, 54, 0.08);
}

.profile-select-title {
    display: block;
    margin-bottom: 2px;
    color: var(--text);
    font-size: 0.88rem;
    font-weight: 700;
}

.profile-select-field > span:first-child {
    display: block;
    margin-bottom: 10px;
    color: var(--text);
    font-size: 0.88rem;
    font-weight: 700;
    letter-spacing: 0.01em;
}

.profile-select-note {
    display: none;
}

.profile-select-field select {
    background: rgba(255, 255, 255, 0.94);
}

.profile-select-field input,
.profile-select-field textarea {
    background: rgba(255, 255, 255, 0.94);
}

.dashboard-sheet-compact {
    width: min(720px, 100%);
    gap: 14px;
    padding: 20px;
}

.dashboard-team-sheet {
    width: min(1120px, calc(100vw - 28px));
    max-height: calc(100vh - 20px);
    padding: 0;
    overflow: hidden;
    border-radius: 24px;
    border: 2px solid rgba(88, 89, 238, 0.9);
    background: #f8f8fb;
}

.dashboard-team-shell {
    display: grid;
    grid-template-columns: minmax(0, 1.45fr) minmax(320px, 0.95fr);
    min-height: min(860px, calc(100vh - 20px));
}

.dashboard-team-main,
.dashboard-team-sidebar {
    display: grid;
    grid-template-rows: auto 1fr;
    min-height: 0;
}

.dashboard-team-head,
.dashboard-team-sidehead {
    padding: 22px 26px;
    background: rgba(255, 255, 255, 0.92);
    border-bottom: 1px solid rgba(97, 99, 144, 0.12);
}

.dashboard-team-main {
    background: linear-gradient(180deg, #ffffff, #fcfcff);
}

.dashboard-team-sidebar {
    border-left: 1px solid rgba(97, 99, 144, 0.12);
    background: linear-gradient(180deg, #faf7ef, #f8f6ef);
}

.dashboard-team-panel,
.dashboard-team-list {
    padding: 22px 24px 20px;
    overflow: auto;
    align-content: start;
}

.dashboard-team-panel {
    display: grid;
    gap: 20px;
}

.dashboard-team-list {
    display: grid;
    gap: 14px;
}

.dashboard-team-current-card,
.dashboard-team-editor,
.dashboard-team-list-card,
.dashboard-team-members {
    border-radius: 18px;
    border: 1px solid rgba(95, 70, 56, 0.1);
    background: rgba(255, 255, 255, 0.88);
    box-shadow: 0 14px 28px rgba(36, 31, 58, 0.05);
}

.dashboard-team-current-card,
.dashboard-team-editor,
.dashboard-team-members,
.dashboard-team-list-card {
    padding: 18px;
}

.dashboard-team-current-card {
    display: grid;
    gap: 14px;
}

.dashboard-team-current-top {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 14px;
    flex-wrap: wrap;
}

.dashboard-team-current-top strong,
.dashboard-team-list-copy strong,
.dashboard-team-member-copy strong {
    font-size: 1.02rem;
    color: #1f2552;
}

.dashboard-team-current-top p,
.dashboard-team-list-card p,
.dashboard-team-member-copy p,
.dashboard-team-empty p {
    margin: 0;
    color: #7b8098;
    line-height: 1.7;
}

.dashboard-team-current-section {
    display: grid;
    gap: 8px;
    padding: 14px;
    border-radius: 14px;
    background: rgba(244, 247, 255, 0.72);
}

.dashboard-team-current-section span {
    font-size: 0.88rem;
    font-weight: 700;
    color: #66708e;
}

.dashboard-team-members {
    display: grid;
    gap: 12px;
}

.dashboard-team-member-row {
    display: grid;
    grid-template-columns: auto auto 1fr auto;
    align-items: center;
    gap: 12px;
}

.dashboard-team-list-top {
    display: grid;
    grid-template-columns: auto 1fr;
    align-items: start;
    gap: 12px;
}

.dashboard-team-rank {
    display: inline-grid;
    place-items: center;
    width: 26px;
    height: 26px;
    border-radius: 8px;
    background: rgba(92, 103, 233, 0.09);
    color: #5c67e9;
    font-size: 0.82rem;
    font-weight: 700;
}

.dashboard-team-member-copy,
.dashboard-team-list-copy {
    display: grid;
    gap: 4px;
    min-width: 0;
}

.dashboard-team-list-tags {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
}

.dashboard-team-list-card {
    display: grid;
    gap: 12px;
    transition: transform 160ms ease, box-shadow 160ms ease, border-color 160ms ease;
}

.dashboard-team-list-card.is-active {
    border-color: rgba(92, 103, 233, 0.32);
    box-shadow: 0 16px 34px rgba(92, 103, 233, 0.1);
}

.dashboard-team-list-card:hover {
    transform: translateY(-2px);
}

.dashboard-team-empty {
    display: grid;
    justify-items: center;
    gap: 10px;
    padding: 42px 28px;
    border: 1px dashed rgba(121, 129, 154, 0.24);
    border-radius: 20px;
    background: linear-gradient(180deg, rgba(250, 251, 255, 0.92), rgba(244, 246, 252, 0.92));
    text-align: center;
}

.dashboard-team-empty-icon {
    display: inline-grid;
    place-items: center;
    width: 62px;
    height: 62px;
    border-radius: 50%;
    background: rgba(92, 103, 233, 0.08);
    color: #5c67e9;
    font-size: 1rem;
    font-weight: 700;
}

.dashboard-team-editor {
    display: grid;
    gap: 16px;
}

.dashboard-subform {
    border-top: 1px solid rgba(95, 70, 56, 0.08);
    padding-top: 16px;
}

.book-editor-shell,
.dashboard-double-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 16px;
}

.book-editor-modal {
    width: min(980px, 100%);
    max-height: calc(100vh - 28px);
    overflow: hidden;
}

.book-editor-heading {
    padding-right: 56px;
}

.book-editor-modal-summary {
    padding: 18px 20px;
    border-radius: 24px;
    background:
        linear-gradient(145deg, rgba(255, 248, 240, 0.94), rgba(245, 234, 221, 0.96));
}

.book-editor-summary-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 12px;
}

.book-editor-summary-item {
    display: grid;
    gap: 6px;
    padding: 14px 16px;
    border-radius: 18px;
    background: rgba(255, 255, 255, 0.7);
    border: 1px solid rgba(95, 70, 56, 0.08);
}

.book-editor-summary-item span {
    color: var(--muted);
    font-size: 0.84rem;
}

.book-editor-summary-item strong {
    font-size: 1rem;
    color: var(--text);
}

.book-editor-workspace {
    grid-template-columns: minmax(300px, 360px) minmax(0, 1fr);
    align-items: start;
    min-height: 0;
    overflow: hidden;
}

.book-editor-pager {
    min-height: 0;
}

.book-editor-preview {
    position: sticky;
    top: 18px;
    display: grid;
    align-content: start;
    gap: 16px;
    padding: 22px;
}

.book-editor-preview-head {
    align-items: flex-start;
}

.book-editor-preview-frame {
    display: grid;
    place-items: center;
    min-height: 220px;
    border-radius: 24px;
    overflow: hidden;
    border: 1px solid rgba(95, 70, 56, 0.12);
    background:
        radial-gradient(circle at top right, rgba(179, 78, 46, 0.16), transparent 32%),
        linear-gradient(180deg, rgba(247, 238, 227, 0.98), rgba(234, 221, 205, 0.98));
}

.book-editor-cover {
    width: 100%;
    height: 100%;
    max-height: 380px;
    object-fit: cover;
}

.book-editor-cover-fallback {
    display: grid;
    place-items: center;
    width: 100%;
    min-height: 220px;
}

.book-editor-preview-copy {
    margin: 0;
}

.book-editor-page-list {
    display: grid;
    gap: 10px;
}

.book-editor-page-list strong {
    font-size: 0.96rem;
}

.book-page-chip-row {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.book-editor-pane {
    display: grid;
    gap: 16px;
    min-height: 0;
}

.book-editor-pane-head {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 12px;
    padding: 14px 16px;
}

.book-editor-pane-head small {
    display: block;
    margin-top: 4px;
    color: var(--muted);
    line-height: 1.6;
}

.book-editor-tabbar {
    display: flex;
    flex-wrap: wrap;
    justify-content: flex-end;
    gap: 6px;
}

.book-editor-tab {
    min-width: 34px;
    height: 34px;
    padding: 0 10px;
    border: 1px solid rgba(95, 70, 56, 0.14);
    border-radius: 10px;
    background: rgba(255, 252, 248, 0.92);
    color: var(--muted);
    font-weight: 700;
}

.book-editor-tab.is-active {
    background: var(--accent);
    border-color: var(--accent);
    color: #fff;
}

.book-editor-tab-add {
    font-size: 1.25rem;
    line-height: 1;
}

.book-editor-pane-badges {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    justify-content: flex-end;
}

.book-editor-form-stack {
    display: grid;
    gap: 12px;
    align-content: start;
    max-height: calc(100vh - 190px);
    overflow: auto;
    padding-right: 4px;
}

.book-page-editor-card {
    display: grid;
    gap: 12px;
    padding: 20px 0 0;
    border-radius: 20px;
    overflow: hidden;
}

.book-page-editor-card[hidden] {
    display: none;
}

.book-page-editor-card.is-new {
    border: 1px dashed rgba(179, 78, 46, 0.24);
}

.book-page-editor-head {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 12px;
    padding: 0 20px;
}

.book-page-editor-title {
    display: grid;
    gap: 6px;
}

.book-page-editor-head strong {
    font-size: 1rem;
}

.book-editor-spread {
    display: grid;
    grid-template-columns: 1fr 1fr;
    min-height: 520px;
    background:
        linear-gradient(180deg, rgba(252, 246, 237, 0.98), rgba(243, 232, 217, 0.98));
}

.book-editor-side {
    display: grid;
    gap: 16px;
    padding: 26px 24px 22px;
}

.book-editor-side + .book-editor-side {
    border-left: 1px solid rgba(95, 70, 56, 0.12);
}

.book-editor-image-frame {
    overflow: hidden;
    border: 1px solid rgba(95, 70, 56, 0.12);
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.74);
    padding: 10px;
}

.book-page-thumb {
    width: 100%;
    aspect-ratio: 4 / 5;
    object-fit: cover;
    border-radius: 4px;
}

.book-editor-image-empty {
    display: grid;
    place-items: center;
    min-height: 320px;
    background: rgba(247, 239, 229, 0.9);
    border-radius: 4px;
}

.book-editor-image-empty .avatar {
    width: 120px;
    height: 120px;
}

.book-editor-content-side {
    align-content: start;
}

.book-editor-meta-grid {
    grid-template-columns: minmax(0, 1fr) 120px;
}

.book-editor-content-field {
    display: grid;
    gap: 10px;
}

.book-editor-content-field textarea {
    min-height: 320px;
    line-height: 1.95;
    padding: 16px 18px;
    border-radius: 12px;
    background: rgba(255, 255, 255, 0.52);
}

.book-page-editor-actions {
    justify-content: flex-start;
    gap: 10px;
    padding-top: 4px;
}

.dashboard-stat-row {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 14px;
}

.dashboard-rule-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 16px;
}

.dashboard-redeem-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 16px;
}

.dashboard-redeem-card {
    min-height: 180px;
}

.dashboard-redeem-card h3 {
    margin: 0;
    font-size: 1.3rem;
}

.dashboard-redeem-price {
    display: block;
    font-size: 1.6rem;
    color: var(--accent-dark);
}

.dashboard-redeem-action {
    margin-top: auto;
}

.dashboard-redeem-custom {
    grid-column: 1 / -1;
}

.dashboard-admin-links {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 14px;
}

.winner-summary-strip {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 12px;
}

.winner-kpi-card {
    padding: 16px 18px;
    border-radius: 18px;
    border: 1px solid rgba(95, 70, 56, 0.1);
    background: rgba(255, 255, 255, 0.62);
}

.winner-kpi-card strong {
    display: block;
    font-size: 1.5rem;
}

.winner-kpi-card span {
    color: var(--muted);
}

.winner-rank-row,
.winner-recent-row {
    gap: 8px;
}

.winner-rank-row.is-self {
    border-color: rgba(47, 118, 89, 0.18);
    background: rgba(47, 118, 89, 0.08);
}

.winner-rank-row.is-self strong::after {
    content: " 我的排名";
    margin-left: 6px;
    font-size: 0.78rem;
    color: #1f8a63;
}

.winner-recent-row p {
    margin: 0;
    color: var(--text);
    line-height: 1.65;
}

[data-overlay-modal="dashboard-winners"] .dashboard-double-grid {
    align-items: start;
}

@media (max-width: 720px) {
    .winner-summary-strip {
        grid-template-columns: 1fr;
    }
}

/* ── Team Center & Dungeon Signup ── */

/* ── 队伍管理中心 Modal ──────────────────────────────── */
.team-center-modal {
    z-index: 240;
}

.team-center-panel {
    width: min(820px, calc(100vw - 32px));
    max-height: calc(100vh - 32px);
    display: flex;
    flex-direction: column;
    padding: 0;
    overflow: hidden;
}

.team-center-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 16px 20px;
    border-bottom: 1px solid var(--line);
    flex-wrap: wrap;
}

.team-center-my-info {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 0.92rem;
}

.team-center-my-badge {
    font-size: 1.1rem;
}

.team-center-my-leader {
    color: var(--muted, #888);
    font-size: 0.82rem;
}

.team-rename-inline {
    display: flex;
    align-items: center;
    gap: 0;
}

.team-rename-input {
    width: 120px !important;
    padding: 4px 8px !important;
    font-size: 0.84rem;
    border-radius: 8px 0 0 8px !important;
    border-right: none !important;
}

.team-rename-suffix {
    display: inline-flex;
    align-items: center;
    padding: 4px 10px;
    font-size: 0.88rem;
    font-weight: 800;
    color: var(--accent, #b08c5a);
    background: var(--surface-strong, rgba(255,255,255,0.9));
    border: 1px solid rgba(96, 67, 47, 0.14);
    border-left: none;
    border-radius: 0 8px 8px 0;
    white-space: nowrap;
}

.team-rename-inline .button {
    margin-left: 6px;
    padding: 4px 12px;
    font-size: 0.8rem;
}

.team-center-body {
    display: grid;
    grid-template-columns: 1fr 1fr;
    flex: 1;
    overflow: hidden;
}

.team-center-left,
.team-center-right {
    display: flex;
    flex-direction: column;
    gap: 10px;
    padding: 14px 16px;
    overflow-y: auto;
}

.team-center-left {
    border-right: 1px solid var(--line);
}

.team-center-collapse {
    display: contents;
}

.team-center-collapse > .team-center-teams-list {
    display: flex;
    flex-direction: column;
    gap: 0;
}

.team-center-summary {
    cursor: pointer;
    list-style: none;
}

.team-center-summary::-webkit-details-marker {
    display: none;
}

.team-center-expand-hint {
    display: none;
    font-size: 0.75rem;
    color: var(--muted, #888);
    margin-left: auto;
}

.team-center-section-head {
    display: flex;
    align-items: center;
    gap: 8px;
}

.team-center-section-head h2 {
    font-size: 1rem;
    font-weight: 700;
    flex: 1;
}

.team-center-icon {
    font-size: 1.1rem;
}

.team-center-count {
    font-size: 0.78rem;
    color: var(--muted);
}

.team-center-myteam {
    font-size: 0.88rem;
}

.team-center-empty {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 6px;
    padding: 24px;
    text-align: center;
    color: var(--muted);
    border: 1px dashed var(--line);
    border-radius: var(--radius);
}

.team-center-empty-icon {
    font-size: 2rem;
    opacity: 0.3;
}

.team-center-signup-block {
    display: flex;
    flex-direction: column;
    gap: 8px;
    padding: 14px;
    border-radius: var(--radius);
    background: rgba(179, 78, 46, 0.05);
    border: 1px solid rgba(179, 78, 46, 0.12);
}

.team-center-signup-head {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
}

.team-center-signup-title {
    font-weight: 600;
    font-size: 0.88rem;
    flex: 1;
}

.team-center-open-badge {
    background: rgba(34, 197, 94, 0.15);
    color: #16a34a;
    border-color: rgba(34, 197, 94, 0.25);
}

.team-center-notice {
    font-size: 0.82rem;
    color: var(--muted);
    line-height: 1.6;
}

.team-center-teams-list {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.team-center-team-card {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 10px 12px;
    border-radius: calc(var(--radius) - 4px);
    border: 1px solid var(--line);
    background: var(--surface);
    cursor: pointer;
    transition: background 0.15s;
}

.team-center-team-num {
    font-size: 0.78rem;
    font-weight: 700;
    color: var(--muted);
    min-width: 18px;
    padding-top: 2px;
}

.team-center-team-info {
    display: flex;
    flex-direction: column;
    gap: 4px;
    flex: 1;
    min-width: 0;
}

.team-center-team-head {
    display: flex;
    align-items: center;
    gap: 6px;
    flex-wrap: wrap;
}

.team-center-team-head strong {
    font-size: 0.9rem;
}

.team-center-leader-badge {
    font-size: 0.72rem;
}

.team-center-team-desc {
    font-size: 0.78rem;
    color: var(--muted);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.team-center-team-card:hover {
    background: rgba(179, 78, 46, 0.04);
}

.team-center-team-arrow {
    margin-left: auto;
    font-size: 0.9rem;
    color: var(--muted);
    transition: transform 0.2s;
    flex-shrink: 0;
}

.team-center-member-list {
    padding: 0 8px 10px 40px;
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.team-center-member-list[hidden] {
    display: none;
}

.team-center-member-row {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 6px 10px;
    border-radius: calc(var(--radius) - 4px);
    background: rgba(0, 0, 0, 0.02);
}

.team-center-member-info {
    display: flex;
    flex-direction: column;
    min-width: 0;
    flex: 1;
}

.team-center-member-info strong {
    font-size: 0.84rem;
}

.team-center-member-info small {
    font-size: 0.74rem;
    color: var(--muted);
}

.team-center-member-empty {
    font-size: 0.8rem;
    color: var(--muted);
    padding: 4px 0;
}

.team-center-footer {
    display: flex;
    gap: 10px;
    padding: 16px 24px;
    border-top: 1px solid var(--line);
    background: var(--surface);
    border-radius: 0 0 30px 30px;
}

.team-center-btn {
    flex: 1;
    justify-content: center;
}

.team-center-hint-card {
    padding: 12px 14px;
    border-radius: calc(var(--radius) - 4px);
    background: rgba(179, 78, 46, 0.06);
    border: 1px solid rgba(179, 78, 46, 0.14);
    font-size: 0.84rem;
    line-height: 1.6;
    color: var(--text);
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.team-center-hint-sub {
    font-size: 0.78rem;
    color: var(--muted);
}

.dungeon-signup-action {
    display: flex;
    align-items: center;
    gap: 10px;
}

.dungeon-btn {
    flex-shrink: 0;
}

.dungeon-signup-feedback {
    font-size: 0.82rem;
    color: var(--muted);
}

.team-center-signuplist {
    display: flex;
    flex-direction: column;
    gap: 6px;
    margin-top: 4px;
}

.team-center-signuplist-head {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 0.8rem;
    font-weight: 600;
    color: var(--muted);
    padding-bottom: 4px;
    border-bottom: 1px solid var(--line);
}

.dungeon-signup-row {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 5px 0;
    font-size: 0.84rem;
}

.dungeon-signup-num {
    font-size: 0.72rem;
    color: var(--muted);
    min-width: 16px;
}

.dungeon-signup-name {
    font-weight: 600;
    flex: 1;
    min-width: 0;
}

.dungeon-signup-meta {
    font-size: 0.78rem;
    color: var(--muted);
}

.dungeon-empty {
    font-size: 0.82rem;
    color: var(--muted);
    padding: 8px 0;
}

@media (max-width: 600px) {
    .team-center-header {
        flex-direction: column;
        align-items: flex-start;
        padding: 12px 14px;
    }

    .team-rename-input {
        width: 100px !important;
    }

    .team-center-body {
        grid-template-columns: 1fr;
    }

    .team-center-left {
        border-right: none;
        border-bottom: 1px solid var(--line);
    }

    .team-center-panel {
        max-height: 92vh;
    }

    .team-center-collapse {
        display: block;
    }

    .team-center-collapse:not([open]) > .team-center-teams-list {
        display: none;
    }

    .team-center-collapse[open] > .team-center-teams-list {
        display: flex;
        flex-direction: column;
        gap: 0;
        margin-top: 12px;
    }

    .team-center-expand-hint {
        display: inline;
    }

    .team-center-collapse[open] .team-center-expand-hint {
        display: none;
    }

    .team-center-right {
        padding: 16px 14px;
    }
}

/* User-facing polish: home, dashboard, book editor */

.home-module-section-head {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 16px;
    margin-bottom: 14px;
}

.home-module-section-head h2 {
    margin: 0;
    font-size: 1.3rem;
}

.home-module-section-head p {
    margin: 6px 0 0;
    color: var(--muted);
    line-height: 1.6;
}

.profile-action-sections {
    display: grid;
    gap: 16px;
}

.profile-action-section {
    display: grid;
    gap: 14px;
    padding: 18px;
    border-radius: 24px;
    background:
        linear-gradient(180deg, rgba(255, 251, 246, 0.98), rgba(248, 242, 234, 0.96));
}

.profile-action-section-secondary {
    background:
        linear-gradient(180deg, rgba(250, 248, 255, 0.98), rgba(245, 243, 252, 0.96));
}

.profile-action-section-head {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 12px;
}

.profile-action-section-head h2 {
    margin: 0;
    font-size: 1.08rem;
}

.profile-action-section-head p {
    margin: 6px 0 0;
    color: var(--muted);
    line-height: 1.55;
}

.profile-card-grid-primary,
.profile-card-grid-secondary {
    grid-template-columns: repeat(2, minmax(0, 1fr));
}

.profile-action-section .profile-action-card {
    border: 1px solid rgba(95, 70, 56, 0.08);
    background: rgba(255, 255, 255, 0.84);
    box-shadow: none;
}

.profile-card-grid-primary > a[href*="page=growth"] {
    display: none;
}

.profile-action-section-secondary .profile-action-section-head p,
.profile-action-section-secondary .profile-action-card-growth {
    display: none;
}

.dashboard-sheet-header {
    padding-right: 52px;
    padding: 2px 52px 14px 0;
    border-bottom: 1px solid rgba(95, 70, 56, 0.08);
    background:
        linear-gradient(180deg, rgba(255, 251, 247, 0.84), rgba(248, 241, 232, 0.38));
    border-radius: 22px 22px 18px 18px;
}

.dashboard-sheet-header h2 {
    margin: 0;
    font-size: 1.32rem;
}

.dashboard-sheet-header p {
    margin: 6px 0 0;
    max-width: 52ch;
    line-height: 1.65;
}

@media (max-width: 900px) {
    .home-module-grid {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 720px) {
    .home-video-stage {
        padding: 12px;
        border-radius: 22px;
    }

    .home-video-frame,
    .home-video-fallback {
        min-height: 220px;
    }

    .home-video-title-badge {
        left: 12px;
        right: 12px;
        bottom: 12px;
    }

    .home-video-title-badge strong {
        max-width: 100%;
        padding: 8px 12px;
        font-size: 0.92rem;
    }

    .home-video-pagination {
        justify-content: center;
        gap: 10px;
    }

    .home-video-dots {
        width: 100%;
        order: 3;
    }

    .home-module-section-head,
    .profile-action-section-head {
        flex-direction: column;
        align-items: flex-start;
    }

    .home-module-grid {
        grid-template-columns: 1fr;
        gap: 12px;
    }

    .home-module-card {
        min-height: 84px;
        padding: 14px 16px;
        border-radius: 18px;
    }

    .home-module-inner {
        gap: 12px;
    }

    .home-shelf-bar {
        align-items: stretch;
        gap: 12px;
    }

    .home-shelf-title {
        width: 100%;
        justify-content: space-between;
    }

    .home-shelf-title h2 {
        padding-left: 12px;
        border-left-width: 4px;
        font-size: 1.45rem;
    }

    .home-shelf-title span {
        font-size: 0.82rem;
        letter-spacing: 0.08em;
    }

    .home-shelf-search-inline {
        width: 100%;
        min-width: 100%;
    }

    .home-shelf-tools {
        width: 100%;
    }

    .home-shelf-reroll {
        width: 100%;
        justify-content: center;
    }

    .book-corridor {
        padding: 22px 8px 8px;
        border-radius: 22px;
    }

    .corridor-book {
        width: 132px;
        flex: 0 0 132px;
    }

    .profile-summary-card {
        padding: 16px;
        grid-template-columns: 1fr;
        gap: 12px;
    }

    .profile-summary-head {
        display: grid;
        gap: 12px;
    }

    .profile-summary-main {
        align-items: flex-start;
    }

    .profile-summary-title-row {
        flex-wrap: wrap;
    }

    .profile-summary-stats {
        display: grid;
        grid-template-columns: 1fr;
    }

    .profile-summary-copy h1 {
        font-size: 1.3rem;
    }

    .profile-summary-main .avatar-md,
    .profile-summary-main .avatar-lg {
        width: 60px;
        height: 60px;
    }

    .profile-summary-bio {
        -webkit-line-clamp: 2;
    }

    .profile-action-sections {
        gap: 14px;
    }

    .profile-action-section {
        padding: 16px;
        border-radius: 22px;
    }

    .profile-card-grid,
    .profile-card-grid-primary,
    .profile-card-grid-secondary {
        grid-template-columns: 1fr;
    }

    .profile-action-card {
        padding: 14px 16px;
        gap: 12px;
        border-radius: 18px;
    }

    .profile-action-icon {
        width: 40px;
        height: 40px;
        border-radius: 12px;
    }

    .dashboard-sheet,
    .dashboard-sheet-compact {
        width: min(calc(100vw - 14px), 100%);
        padding: 16px;
        gap: 14px;
        border-radius: 22px;
    }

    .dashboard-sheet-header {
        padding: 2px 40px 12px 0;
    }

    .dashboard-stat-row,
    .dashboard-redeem-grid,
    .dashboard-double-grid {
        grid-template-columns: 1fr;
    }

    .book-editor-pane-head {
        display: grid;
        gap: 10px;
        padding: 12px 14px;
    }

    .book-editor-tabbar {
        justify-content: flex-start;
        flex-wrap: nowrap;
        overflow: auto;
        padding-bottom: 4px;
    }

    .book-editor-tab {
        flex: 0 0 auto;
        min-width: 38px;
    }

    .book-editor-form-stack {
        max-height: none;
        padding-right: 0;
    }

    .book-page-editor-card {
        border-radius: 18px;
    }

    .book-page-editor-head {
        padding: 0 14px;
    }

    .book-editor-spread {
        grid-template-columns: 1fr;
        min-height: auto;
    }

    .book-editor-side {
        padding: 16px 14px;
    }

    .book-editor-side + .book-editor-side {
        border-left: 0;
        border-top: 1px solid rgba(95, 70, 56, 0.12);
    }

    .book-editor-image-empty {
        min-height: 220px;
    }

    .book-editor-meta-grid {
        grid-template-columns: 1fr;
    }

    .book-editor-content-field textarea {
        min-height: 220px;
        padding: 14px;
        line-height: 1.7;
    }

    .book-page-editor-actions {
        justify-content: stretch;
    }

    .book-page-editor-actions .button {
        width: 100%;
    }
}

@media (max-width: 480px) {
    .home-video-frame,
    .home-video-fallback {
        min-height: 188px;
    }

    .home-module-text strong {
        font-size: 1.08rem;
    }

    .book-corridor-track {
        gap: 12px;
    }

    .corridor-book {
        width: 124px;
        flex: 0 0 124px;
    }

    .profile-summary-tags {
        gap: 6px;
    }
}

/* User-facing modal polish */
.dashboard-redeem-card {
    display: grid;
    align-content: start;
    gap: 14px;
}

.dashboard-redeem-card .section-heading {
    gap: 6px;
}

.dashboard-redeem-card .section-heading p {
    margin: 0;
}

.dashboard-redeem-action .button,
.dashboard-redeem-custom .button {
    width: 100%;
    justify-content: center;
}

.dashboard-history-card,
.winner-rank-card,
.winner-recent-card {
    gap: 14px;
}

.dashboard-history-list,
.winner-rank-list,
.winner-recent-list {
    display: grid;
    gap: 10px;
}

.dashboard-history-item,
.winner-rank-row,
.winner-recent-row {
    gap: 10px;
}

.dashboard-history-item .meta-row,
.winner-rank-row .meta-row,
.winner-recent-row .meta-row {
    align-items: flex-start;
    justify-content: space-between;
    gap: 10px;
}

.dashboard-history-points {
    margin: 0;
    font-weight: 700;
    color: var(--text);
}

.dashboard-history-time {
    color: var(--muted);
}

.winner-rank-total {
    color: var(--accent-dark);
    font-weight: 700;
}

.winner-award-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: fit-content;
    min-height: 30px;
    padding: 4px 10px;
    border-radius: 999px;
    font-size: 0.82rem;
    font-weight: 700;
}

.winner-award-badge.is-active {
    background: rgba(47, 118, 89, 0.14);
    color: #1f8a63;
}

.winner-award-badge.is-league {
    background: rgba(69, 108, 207, 0.14);
    color: #456ccf;
}

.winner-award-badge.is-custom {
    background: rgba(130, 97, 168, 0.14);
    color: #7752a2;
}

.winner-rank-row.is-self strong::after {
    content: " 我的排名";
}

@media (max-width: 720px) {
    .dashboard-redeem-card {
        min-height: 0;
        padding: 16px;
        border-radius: 20px;
    }

    .dashboard-redeem-card h3 {
        font-size: 1.15rem;
    }

    .dashboard-redeem-price {
        font-size: 1.35rem;
    }

    .dashboard-history-item,
    .winner-rank-row,
    .winner-recent-row {
        padding: 13px 14px;
    }

    .dashboard-history-item .meta-row,
    .winner-rank-row .meta-row,
    .winner-recent-row .meta-row {
        flex-direction: column;
        align-items: flex-start;
    }

    .dashboard-history-item .badge,
    .winner-award-badge,
    .winner-rank-total {
        width: fit-content;
    }
}

@media (max-width: 520px) {
    .dashboard-redeem-grid,
    .dashboard-history-list,
    .winner-rank-list,
    .winner-recent-list {
        gap: 8px;
    }

    .winner-kpi-card {
        padding: 14px 16px;
    }

    .winner-kpi-card strong {
        font-size: 1.32rem;
    }
}

/* Shelf cards & book editor hierarchy */
.corridor-book {
    display: grid;
    gap: 10px;
    align-content: start;
    text-align: left;
}

.corridor-book-meta {
    display: grid;
    gap: 3px;
    padding: 0 4px;
}

.corridor-book-name {
    font-size: 0.98rem;
    font-weight: 700;
    color: var(--text);
}

.corridor-book-note {
    color: var(--muted);
    font-size: 0.82rem;
    line-height: 1.45;
}

.corridor-book:hover .corridor-book-name {
    color: var(--accent-dark);
}

.book-editor-status-bar {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
}

.book-editor-pane-head {
    border-radius: 22px;
    background:
        linear-gradient(180deg, rgba(255, 251, 247, 0.94), rgba(248, 241, 232, 0.94));
}

.book-editor-tabbar {
    padding: 6px;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.7);
}

.book-page-editor-card {
    background:
        linear-gradient(180deg, rgba(255, 252, 248, 0.98), rgba(248, 240, 230, 0.98));
    box-shadow: 0 12px 28px rgba(44, 26, 18, 0.06);
}

.book-page-editor-title small {
    display: block;
    margin: 0;
    color: var(--muted);
    line-height: 1.55;
}

@media (max-width: 720px) {
    .home-notice-card {
        border-radius: 20px;
    }

    .home-notice-shell {
        grid-template-columns: 1fr;
    }

    .home-notice-marker {
        grid-template-columns: auto 1fr;
        align-items: center;
        padding: 14px 16px;
        border-right: 0;
        border-bottom: 1px solid rgba(191, 150, 95, 0.12);
    }

    .home-notice-marker::after {
        display: none;
    }

    .home-notice-seal {
        width: 38px;
        height: 38px;
        border-radius: 12px;
        font-size: 0.96rem;
    }

    .home-notice-feed {
        padding: 10px;
    }

    .home-notice-item {
        grid-template-columns: 1fr;
        align-items: flex-start;
        gap: 8px;
        padding: 11px 12px;
        border-radius: 14px;
    }

    .home-notice-main {
        flex-wrap: wrap;
        gap: 8px;
    }

    .home-notice-title {
        max-width: 100%;
    }

    .home-notice-body {
        white-space: normal;
    }

    .corridor-book {
        gap: 8px;
    }

    .corridor-book-meta {
        padding: 0 2px;
    }

    .corridor-book-name {
        font-size: 0.92rem;
    }

    .corridor-book-note {
        font-size: 0.76rem;
    }

    .book-editor-pane-head {
        gap: 10px;
    }

    .book-editor-tabbar {
        width: 100%;
        overflow: auto;
        justify-content: flex-start;
    }
}

@media (max-width: 520px) {
    .book-editor-pane-head {
        padding: 14px;
    }
}



/* ── Lottery ── complete rewrite ── */

body.route-lottery .page-frame { width: min(calc(100% - 16px), 840px); }

.lt-page { position: relative; padding-bottom: 40px; }
.lt-particles { position: fixed; inset: 0; z-index: 0; pointer-events: none; opacity: 0.5; }
.lt-hero { position: relative; z-index: 1; text-align: center; padding: 20px 0 24px; }
.lt-hero small { display: block; font-size: 0.72rem; font-weight: 700; letter-spacing: 0.3em; color: var(--accent); margin-bottom: 6px; }
.lt-hero h1 { margin: 0; font-size: clamp(2rem, 6vw, 3rem); font-weight: 900; letter-spacing: 0.1em; background: linear-gradient(180deg, #fff, var(--accent)); -webkit-background-clip: text; -webkit-text-fill-color: transparent; background-clip: text; filter: drop-shadow(0 4px 16px var(--accent-soft)); }
.lt-hero p { margin: 8px 0 0; color: var(--muted); font-size: 0.86rem; letter-spacing: 0.12em; }

.lt-stage { position: relative; z-index: 1; display: grid; gap: 24px; padding: 32px; border-radius: 24px; border: 1.5px solid rgba(255,255,255,0.06); background: radial-gradient(ellipse at 50% 0%, var(--accent-soft), transparent 50%), linear-gradient(180deg, rgba(0,0,0,0.4), rgba(0,0,0,0.6)); overflow: hidden; }
.lt-stage::after { content: ""; position: absolute; left: 0; right: 0; height: 1px; background: linear-gradient(90deg, transparent, var(--accent), transparent); box-shadow: 0 0 16px var(--accent-soft), 0 0 48px var(--accent-soft); animation: lt-beam 5s linear infinite; pointer-events: none; z-index: 20; }
@keyframes lt-beam { 0% { top: -5%; } 100% { top: 105%; } }

.lt-timer { text-align: center; }
.lt-timer-name { font-size: 1.1rem; font-weight: 700; letter-spacing: 0.06em; margin-bottom: 6px; }
.lt-timer-digits { font-size: clamp(2.6rem, 8vw, 4.2rem); font-weight: 900; font-variant-numeric: tabular-nums; letter-spacing: 0.08em; color: var(--accent); text-shadow: 0 0 24px var(--accent-soft), 0 0 64px var(--accent-soft), 0 4px 8px rgba(0,0,0,0.5); line-height: 1.1; padding: 8px 0; }
.lt-timer-info { display: flex; justify-content: center; gap: 10px; flex-wrap: wrap; color: var(--muted); font-size: 0.84rem; }

.lt-prizes { display: flex; justify-content: center; gap: 14px; flex-wrap: wrap; }
.lt-prize { text-align: center; padding: 16px 22px; border-radius: 14px; border: 1px solid rgba(255,255,255,0.08); background: linear-gradient(145deg, rgba(255,255,255,0.07), rgba(255,255,255,0.02)); min-width: 100px; backdrop-filter: blur(6px); box-shadow: 0 6px 24px rgba(0,0,0,0.3); animation: lt-card-in 0.5s ease both; animation-delay: var(--delay, 0s); transition: transform 0.25s, box-shadow 0.25s; }
.lt-prize:hover { transform: translateY(-4px) scale(1.04); box-shadow: 0 12px 36px rgba(0,0,0,0.4), 0 0 16px var(--accent-soft); }
.lt-prize small { display: block; font-size: 0.78rem; font-weight: 700; color: var(--accent); letter-spacing: 0.06em; margin-bottom: 6px; }
.lt-prize strong { display: block; font-size: 1.5rem; line-height: 1; margin-bottom: 2px; }
.lt-prize span { font-size: 0.74rem; color: var(--muted); }
@keyframes lt-card-in { 0% { opacity: 0; transform: perspective(600px) rotateY(35deg) scale(0.8); } 100% { opacity: 1; transform: perspective(600px) rotateY(0) scale(1); } }

.lt-drum { display: flex; flex-wrap: wrap; gap: 10px; justify-content: center; padding: 22px; border-radius: 18px; border: 1px solid rgba(255,255,255,0.05); background: rgba(0,0,0,0.35); min-height: 80px; align-content: center; }
.lt-name { display: inline-flex; align-items: center; padding: 9px 18px; border-radius: 999px; border: 1px solid rgba(255,255,255,0.1); background: rgba(255,255,255,0.04); font-size: 0.9rem; font-weight: 600; transition: all 0.1s; }
.lt-name.is-hl { background: var(--accent); border-color: var(--accent); color: var(--bg); transform: scale(1.12); box-shadow: 0 0 16px var(--accent-soft), 0 0 32px var(--accent-soft); }
.lt-name.is-won { background: var(--accent); border-color: var(--accent); color: var(--bg); font-weight: 800; transform: scale(1.18); box-shadow: 0 0 20px var(--accent), 0 0 48px var(--accent-soft), 0 6px 16px rgba(0,0,0,0.5); }
.lt-empty { color: var(--muted); }

.lt-status { text-align: center; color: var(--muted); font-size: 0.86rem; letter-spacing: 0.1em; display: flex; align-items: center; justify-content: center; gap: 8px; }
.lt-pulse { width: 9px; height: 9px; border-radius: 50%; background: var(--accent); display: inline-block; animation: lt-dot 1.4s ease-in-out infinite; }
@keyframes lt-dot { 0%,100% { opacity: 0.3; transform: scale(1); box-shadow: 0 0 0 0 var(--accent-soft); } 50% { opacity: 1; transform: scale(1.2); box-shadow: 0 0 0 8px transparent; } }

.lt-tier-label { font-weight: 700; font-size: 0.92rem; color: var(--accent); letter-spacing: 0.08em; padding: 8px 0 2px; border-bottom: 1px solid var(--accent-soft); }

.lt-results { display: grid; gap: 12px; perspective: 900px; }

.lt-winner { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 16px 22px; border-radius: 14px; border: 1px solid var(--accent); background: linear-gradient(135deg, var(--accent-soft), rgba(0,0,0,0.15)); transform: perspective(900px) translateZ(500px) rotateX(-25deg) scale(1.5); opacity: 0; filter: blur(10px); box-shadow: 0 0 0 rgba(0,0,0,0); transition: none; }

.lt-winner.is-in { animation: lt-slam 1.4s cubic-bezier(0.16, 1, 0.3, 1) forwards; }

@keyframes lt-slam {
  0%   { opacity: 0; transform: perspective(900px) translateZ(500px) rotateX(-25deg) scale(1.5); filter: blur(10px); box-shadow: 0 0 0 rgba(0,0,0,0); }
  25%  { opacity: 1; filter: blur(3px); }
  50%  { transform: perspective(900px) translateZ(-15px) rotateX(4deg) scale(0.96); filter: blur(0); box-shadow: 0 0 80px var(--accent-soft), 0 0 160px var(--accent-soft); }
  70%  { transform: perspective(900px) translateZ(5px) rotateX(-1.5deg) scale(1.02); box-shadow: 0 0 40px var(--accent-soft); }
  100% { opacity: 1; transform: perspective(900px) translateZ(0) rotateX(0) scale(1); filter: blur(0); box-shadow: 0 0 24px var(--accent-soft), inset 0 1px 0 rgba(255,255,255,0.1); }
}

.lt-winner-name { font-size: 1.1rem; font-weight: 700; }
.lt-winner-pts { font-size: 0.88rem; white-space: nowrap; }

.lt-empty-page { position: relative; z-index: 1; text-align: center; padding: 60px 20px; color: var(--muted); }
.lt-rules { position: relative; z-index: 1; margin-bottom: 8px; }
.lt-rules summary { cursor: pointer; padding: 10px 14px; border-radius: 12px; border: 1px solid var(--line); background: rgba(255,255,255,0.03); color: var(--muted); font-size: 0.84rem; font-weight: 600; letter-spacing: 0.04em; list-style: none; text-align: center; }
.lt-rules summary::-webkit-details-marker { display: none; }
.lt-rules-body { padding: 14px 16px; margin-top: 8px; border-radius: 12px; border: 1px solid var(--line); background: rgba(255,255,255,0.03); font-size: 0.84rem; line-height: 1.7; }
.lt-rules-body p { margin: 0 0 6px; }
.lt-rules-body p:last-child { margin: 0; }
.lt-rules-body strong { color: var(--accent); }

.lt-history { position: relative; z-index: 1; margin-top: 28px; display: grid; gap: 10px; }
.lt-history-head { font-size: 1.1rem; font-weight: 700; letter-spacing: 0.04em; padding-bottom: 6px; border-bottom: 1px solid var(--accent-soft); color: var(--accent); }
.lt-history-item { padding: 14px 16px; border-radius: 14px; border: 1px solid var(--line); background: rgba(255,255,255,0.03); transition: border-color 0.2s, background 0.2s; }
.lt-history-item:hover { border-color: var(--accent-soft); background: rgba(255,255,255,0.05); }
.lt-history-tags { display: flex; flex-wrap: wrap; gap: 5px; margin-top: 8px; }
.lt-history-expand { width: 100%; padding: 12px; border-radius: 14px; border: 1px dashed var(--accent-soft); background: transparent; color: var(--accent); font-size: 0.88rem; font-weight: 600; letter-spacing: 0.06em; cursor: pointer; transition: background 0.2s, border-color 0.2s; }
.lt-history-expand:hover { background: var(--accent-soft); border-color: var(--accent); }

.lt-ranking { position: relative; z-index: 1; margin-top: 28px; display: grid; gap: 10px; }
.lt-ranking .winner-rank-card { padding: 14px 16px; border-radius: 14px; border: 1px solid var(--line); background: rgba(255,255,255,0.03); }
.lt-ranking .winner-rank-list { display: grid; gap: 6px; }
.lt-ranking .winner-rank-row { padding: 8px 12px; border-radius: 10px; background: rgba(255,255,255,0.02); transition: background 0.15s; }
.lt-ranking .winner-rank-row:hover { background: rgba(255,255,255,0.06); }
.lt-ranking .winner-rank-row.is-self { background: var(--accent-soft); border-left: 3px solid var(--accent); }
.lt-ranking .winner-rank-actions { margin-top: 8px; text-align: center; }

.lottery-tiers-list { display: grid; gap: 8px; }
.lottery-tier-row { display: grid; grid-template-columns: minmax(80px,1fr) 72px 80px 40px; gap: 8px; align-items: center; }
.lottery-tier-row input { min-height: 38px; }
.lottery-entry-grid { display: flex; flex-wrap: wrap; gap: 6px; }

@media (max-width: 640px) {
  .lt-stage { padding: 20px; gap: 18px; }
  .lt-timer-digits { font-size: 2.2rem; }
  .lt-prize { padding: 12px 16px; min-width: 85px; }
  .lt-name { padding: 7px 13px; font-size: 0.84rem; }
}
