/* ===== 个人信息页特有样式（profile-only，共用样式见 style.css） ===== */

/* 头像横条区域 */
.profile-header-row {
    display: flex;
    align-items: center;
    gap: 1.5rem;
    padding: 2rem 2.5rem;
    border-bottom: 1px solid #f0f0f0;
}

.avatar-ring {
    width: 96px;
    height: 96px;
    border-radius: 50%;
    padding: 3px;
    background: var(--brand-gradient);
    box-shadow: 0 4px 16px rgba(var(--brand-primary-rgb), 0.25);
    position: relative;
    cursor: pointer;
    transition: transform 0.3s, box-shadow 0.3s;
    flex-shrink: 0;
}

.avatar-ring:hover {
    transform: scale(1.05);
    box-shadow: 0 6px 24px rgba(var(--brand-primary-rgb), 0.35);
}

.avatar-ring .avatar-preview.placeholder {
    font-size: 2.2rem;
}

.avatar-edit-badge {
    position: absolute;
    bottom: 0;
    right: 0;
    width: 28px;
    height: 28px;
    border-radius: 50%;
    background: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.12);
    border: 2px solid #fff;
    pointer-events: none;
}

.avatar-edit-badge svg {
    width: 13px;
    height: 13px;
    color: var(--brand-primary);
}

.avatar-info {
    flex: 1;
    min-width: 0;
}

.avatar-info-name {
    margin: 0;
    font-size: 1.35rem;
    font-weight: 600;
    color: #1d1d1f;
    line-height: 1.3;
}

.avatar-info-sub {
    color: #6b7280;
    font-size: 0.875rem;
    margin-top: 0.25rem;
}

.avatar-info-hint {
    color: #6b7280;
    font-size: 0.8rem;
    margin-top: 0.4rem;
}

/* 表单主体 */
.profile-form-body {
    padding: 0;
}

/* 横排字段行 */
.profile-field-row {
    display: flex;
    align-items: flex-start;
    padding: 1.5rem 2.5rem;
    border-bottom: 1px solid #f0f0f0;
    gap: 1.5rem;
}

.profile-field-row:last-child {
    border-bottom: none;
}

.profile-field-label {
    width: 120px;
    flex-shrink: 0;
    padding-top: 0.7rem;
    font-size: 0.9rem;
    font-weight: 500;
    color: #1d1d1f;
}

.profile-field-content {
    flex: 1;
    min-width: 0;
}

.profile-static-value {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.15rem 0;
    font-size: 1.05rem;
    font-weight: 700;
    color: #8a5a00;
    line-height: 1.2;
}

.profile-static-value .coin-icon {
    width: 1.6rem;
    height: 1.6rem;
    border-radius: 999px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, #fff8db 0%, #ffe08a 100%);
    border: 1px solid #f0cb62;
    box-shadow: 0 2px 8px rgba(240, 203, 98, 0.35);
    font-size: 0.95rem;
}

.profile-static-value .coin-amount {
    font-size: 1.2rem;
    font-weight: 800;
    color: #6f4300;
    letter-spacing: 0.01em;
    font-variant-numeric: tabular-nums;
}

.profile-static-value .coin-unit {
    font-size: 0.88rem;
    color: #9b7a45;
    font-weight: 600;
}

.coin-breakdown {
    position: relative;
    font-size: 0.82rem;
    font-weight: 600;
    color: #6f4300;
}

.coin-breakdown-trigger {
    width: 1.35rem;
    height: 1.35rem;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border: 1px solid #dfbf75;
    border-radius: 999px;
    background: #fffaf0;
    cursor: help;
    padding: 0;
    font: inherit;
}

.coin-breakdown-trigger:focus-visible {
    outline: 2px solid #c58a1d;
    outline-offset: 2px;
}

.coin-breakdown-popover {
    position: absolute;
    z-index: 20;
    top: calc(100% + 0.55rem);
    left: 50%;
    min-width: 13rem;
    padding: 0.75rem;
    border: 1px solid #ead8ad;
    border-radius: 10px;
    background: #fffdf8;
    box-shadow: 0 12px 30px rgba(84, 58, 15, 0.16);
    color: #493719;
    opacity: 0;
    visibility: hidden;
    transform: translate(-50%, -0.25rem);
    transition: opacity 0.16s ease, transform 0.16s ease, visibility 0.16s;
}

.coin-breakdown:hover .coin-breakdown-popover,
.coin-breakdown:focus-within .coin-breakdown-popover,
.coin-breakdown-trigger:focus + .coin-breakdown-popover {
    opacity: 1;
    visibility: visible;
    transform: translate(-50%, 0);
}

.coin-breakdown-popover > strong {
    display: block;
    margin-bottom: 0.45rem;
    font-size: 0.8rem;
}

.coin-breakdown-popover > span {
    display: flex;
    justify-content: space-between;
    gap: 1.5rem;
    padding: 0.28rem 0;
    white-space: nowrap;
    font-weight: 500;
}

.coin-breakdown-popover b {
    color: #6f4300;
    font-variant-numeric: tabular-nums;
}

.coin-breakdown-popover .coin-breakdown-empty {
    color: #8b8170;
}

.profile-field-content input[type="text"],
.profile-field-content textarea {
    background: #f7f8fa;
    border: 1px solid #e8e8ed;
    color: #1d1d1f;
    border-radius: 10px;
    padding: 0.7rem 1rem;
    font-size: 0.95rem;
    transition: all 0.2s;
    width: 100%;
    font-family: inherit;
}

.profile-field-content input[type="text"]:hover,
.profile-field-content textarea:hover {
    border-color: #d0d0d5;
}

.profile-field-content input[type="text"]:focus,
.profile-field-content textarea:focus {
    outline: none;
    border-color: rgba(var(--brand-primary-rgb), 0.5);
    background: #fff;
    box-shadow: 0 0 0 3px rgba(var(--brand-primary-rgb), 0.08);
}

.profile-field-content input:disabled {
    background: #f2f3f5;
    color: #86868b;
    cursor: not-allowed;
    border-color: #eee;
}

.profile-field-content textarea {
    resize: vertical;
    min-height: 100px;
    line-height: 1.6;
}

.profile-field-content small {
    color: #6b7280;
    font-size: 0.8rem;
    display: block;
    margin-top: 0.4rem;
}

/* 隐藏全局 form-group 中的 label（由横排 label 替代） */
.profile-field-content .form-group {
    margin-bottom: 0;
}

.profile-field-content .form-group > label {
    display: none;
}

/* AI 推荐卡片 */
.bio-recommendation {
    margin-top: 0.75rem;
    padding: 1rem 1.25rem;
    background: linear-gradient(135deg, rgba(var(--brand-primary-rgb), 0.06) 0%, rgba(var(--brand-secondary-rgb), 0.06) 100%);
    border: 1px solid rgba(var(--brand-primary-rgb), 0.12);
    border-radius: 10px;
    color: #1d1d1f;
    box-shadow: none;
}

.bio-recommendation .recommendation-header {
    color: var(--brand-primary);
    font-weight: 600;
    font-size: 0.85rem;
}

.bio-recommendation .recommendation-content {
    background: rgba(255, 255, 255, 0.7);
    color: #1d1d1f;
    border: 1px solid rgba(var(--brand-primary-rgb), 0.08);
    border-radius: 8px;
    font-size: 0.9rem;
    padding: 0.75rem;
}

.bio-recommendation .recommendation-actions .btn {
    border-radius: 8px;
    font-weight: 500;
}

#generateRecommendationBtn {
    background: rgba(var(--brand-primary-rgb), 0.05);
    border: 1px solid rgba(var(--brand-primary-rgb), 0.18);
    color: var(--brand-primary);
    border-radius: 8px;
    font-weight: 500;
    transition: all 0.2s;
}

#generateRecommendationBtn:hover {
    background: rgba(var(--brand-primary-rgb), 0.1);
    border-color: rgba(var(--brand-primary-rgb), 0.3);
}

/* 底部操作栏 */
.profile-actions-bar {
    display: flex;
    justify-content: flex-end;
    gap: 0.75rem;
    padding: 1.5rem 2.5rem;
    border-top: 1px solid #f0f0f0;
    background: #fafbfc;
    border-radius: 0 0 16px 16px;
}

.profile-actions-bar .btn-primary {
    background: var(--brand-gradient);
    border: none;
    color: #fff;
    padding: 0.7rem 2.5rem;
    font-size: 0.95rem;
    font-weight: 600;
    border-radius: 10px;
    transition: all 0.25s;
    box-shadow: 0 4px 14px rgba(var(--brand-primary-rgb), 0.25);
    cursor: pointer;
}

.profile-actions-bar .btn-primary:hover {
    transform: translateY(-1px);
    box-shadow: 0 6px 20px rgba(var(--brand-primary-rgb), 0.35);
    background: var(--brand-gradient-hover);
}

.profile-actions-bar .btn-primary:active {
    transform: scale(0.98);
}

.profile-actions-bar .btn-outline {
    background: #fff;
    color: var(--brand-primary);
    border: 1px solid #e0e0e5;
    padding: 0.7rem 2rem;
    font-size: 0.95rem;
    font-weight: 500;
    border-radius: 10px;
    transition: all 0.2s;
    text-decoration: none;
    text-align: center;
    cursor: pointer;
}

.profile-actions-bar .btn-outline:hover {
    background: #f7f8fa;
    border-color: #ccc;
}

/* ===== 响应式（profile-only） ===== */
@media (max-width: 768px) {
    #profilePage .profile-card {
        margin-top: 1rem;
    }

    .profile-header-row {
        padding: 1.5rem;
    }

    .profile-field-row {
        flex-direction: column;
        padding: 1.25rem 1.5rem;
        gap: 0.5rem;
    }

    .profile-field-label {
        width: auto;
        padding-top: 0;
    }

    .profile-actions-bar {
        padding: 1.25rem 1.5rem;
        flex-direction: column;
    }

    .profile-actions-bar .btn-primary,
    .profile-actions-bar .btn-outline {
        width: 100%;
        display: flex;
        justify-content: center;
        align-items: center;
    }
}

@media (max-width: 480px) {
    .profile-header-row {
        flex-direction: column;
        align-items: center;
        text-align: center;
        padding: 1.25rem;
        gap: 0.75rem;
    }

    .avatar-ring {
        width: 72px;
        height: 72px;
    }

    .avatar-info-hint {
        font-size: 0.75rem;
    }

    .avatar-info-name {
        font-size: 1.15rem;
    }

    .profile-field-row {
        padding: 1rem 1.25rem;
    }

    .profile-actions-bar {
        padding: 1rem 1.25rem;
    }
}

/* ===== 公开玩家主页 ===== */
.public-profile-page {
    --pp-ink: #152725;
    --pp-muted: #687873;
    --pp-accent: #22725d;
    --pp-accent-strong: #185846;
    --pp-paper: #fffdf8;
    --pp-paper-soft: #f4f1e8;
    --pp-line: rgba(38, 68, 61, 0.14);
    position: relative;
    isolation: isolate;
    min-height: calc(100dvh - var(--navbar-height, 56px));
    overflow: hidden;
    background: #e7ece7;
    color: var(--pp-ink);
}

.public-profile-page::before {
    content: '';
    position: absolute;
    inset: 0;
    z-index: -2;
    background:
        radial-gradient(circle at 11% 6%, rgba(254, 236, 188, 0.72), transparent 27rem),
        radial-gradient(circle at 90% 24%, rgba(130, 171, 155, 0.3), transparent 31rem),
        #e7ece7;
}

.public-profile-page::after {
    content: '';
    position: absolute;
    inset: 0;
    z-index: -1;
    pointer-events: none;
    opacity: 0.42;
    background-image:
        linear-gradient(rgba(30, 66, 57, 0.045) 1px, transparent 1px),
        linear-gradient(90deg, rgba(30, 66, 57, 0.045) 1px, transparent 1px);
    background-size: 48px 48px;
    mask-image: linear-gradient(to bottom, #000 0, transparent 46rem);
}

.public-profile-ambient {
    position: absolute;
    inset: 0;
    z-index: -1;
    overflow: hidden;
    pointer-events: none;
}

.public-profile-ambient-orbit {
    position: absolute;
    display: block;
    border: 1px solid rgba(34, 114, 93, 0.15);
    border-radius: 50%;
}

.public-profile-ambient-orbit-one {
    top: 4rem;
    right: -12rem;
    width: 34rem;
    height: 34rem;
}

.public-profile-ambient-orbit-two {
    top: 10rem;
    right: -6rem;
    width: 18rem;
    height: 18rem;
}

.public-profile-shell {
    width: min(100% - 3rem, 1280px);
    margin: 0 auto;
    padding: 2rem 0 5.5rem;
}

.public-profile-breadcrumb {
    display: flex;
    align-items: center;
    gap: 0.55rem;
    margin: 0 0 1rem 0.3rem;
    color: #65746f;
    font-size: 0.78rem;
    font-weight: 600;
    letter-spacing: 0.03em;
}

.public-profile-breadcrumb a {
    display: inline-flex;
    align-items: center;
    min-height: 44px;
    color: var(--pp-accent-strong);
    text-decoration: none;
}

.public-profile-breadcrumb a:hover {
    color: var(--pp-accent);
}

.public-profile-breadcrumb svg {
    width: 18px;
    height: 18px;
    margin-right: 0.2rem;
    fill: none;
    stroke: currentColor;
    stroke-width: 2;
    stroke-linecap: round;
    stroke-linejoin: round;
}

.public-profile-sheet {
    overflow: hidden;
    border: 1px solid rgba(32, 72, 62, 0.13);
    border-radius: 28px 28px 18px 18px;
    background: var(--pp-paper);
    box-shadow: 0 26px 70px rgba(35, 65, 56, 0.13), 0 2px 10px rgba(35, 65, 56, 0.06);
    animation: publicProfileEnter 420ms cubic-bezier(0.2, 0.8, 0.2, 1) both;
}

.public-profile-hero {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    align-items: center;
    gap: 2.5rem;
    padding: 3.25rem 3.5rem 2.75rem;
}

.public-profile-identity {
    display: flex;
    align-items: center;
    min-width: 0;
    gap: 1.8rem;
}

.public-profile-avatar-wrap {
    position: relative;
    flex: 0 0 auto;
}

.public-profile-avatar-ring {
    width: 118px;
    height: 118px;
    padding: 4px;
    border: 1px solid rgba(34, 114, 93, 0.22);
    border-radius: 50%;
    background: #e8f0eb;
    box-shadow: 0 12px 28px rgba(37, 88, 73, 0.16);
}

.public-profile-avatar-ring > .lp-avatar-frame-profile-ring {
    width: 100%;
    height: 100%;
}

.public-profile-avatar-ring .avatar-preview {
    border: 3px solid var(--pp-paper);
}

.public-profile-avatar-ring .avatar-preview.placeholder {
    font-size: 2.5rem;
}

.public-profile-intro {
    min-width: 0;
}

.public-profile-kicker {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 0.48rem;
    margin-bottom: 0.65rem;
    color: var(--pp-accent-strong);
    font-size: 0.72rem;
    font-weight: 750;
    letter-spacing: 0.12em;
}

.public-profile-kicker-dot {
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background: #e7964d;
    box-shadow: 0 0 0 5px rgba(231, 150, 77, 0.14);
}

.public-profile-friend-label {
    margin-left: 0.35rem;
    padding: 0.25rem 0.48rem;
    border-radius: 5px;
    background: #e7f0eb;
    color: #3c685b;
    font-size: 0.68rem;
    letter-spacing: 0.04em;
}

.public-profile-name {
    margin: 0;
    color: var(--pp-ink);
    font-family: "Songti SC", "STSong", Georgia, serif;
    font-size: clamp(2.3rem, 4vw, 4rem);
    font-weight: 700;
    line-height: 1.02;
    letter-spacing: -0.045em;
    text-wrap: balance;
}

.public-profile-handle {
    margin: 0.5rem 0 0;
    color: #6b7975;
    font-size: 0.88rem;
    font-weight: 600;
    letter-spacing: 0.02em;
}

.public-profile-bio {
    max-width: 42rem;
    margin: 1rem 0 0;
    color: #4f5e5a;
    font-size: 0.96rem;
    line-height: 1.75;
    text-wrap: pretty;
}

.public-profile-actions {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    flex-wrap: wrap;
    max-width: 23rem;
    gap: 0.55rem;
}

.public-profile-action {
    display: inline-flex;
    min-height: 44px;
    align-items: center;
    justify-content: center;
    gap: 0.48rem;
    padding: 0.68rem 0.92rem;
    border: 1px solid transparent;
    border-radius: 10px;
    font: inherit;
    font-size: 0.82rem;
    font-weight: 700;
    line-height: 1;
    text-decoration: none;
    cursor: pointer;
    transition: transform 180ms ease, border-color 180ms ease, background 180ms ease, color 180ms ease;
}

.public-profile-action svg {
    width: 17px;
    height: 17px;
    fill: none;
    stroke: currentColor;
    stroke-width: 1.9;
    stroke-linecap: round;
    stroke-linejoin: round;
}

.public-profile-action-primary {
    background: var(--pp-accent-strong);
    color: #fff;
    box-shadow: 0 8px 18px rgba(24, 88, 70, 0.18);
}

.public-profile-action-secondary {
    border-color: rgba(40, 73, 65, 0.2);
    background: transparent;
    color: #36594f;
}

.public-profile-action:hover {
    transform: translateY(-2px);
}

.public-profile-action-primary:hover {
    background: var(--pp-accent);
    color: #fff;
}

.public-profile-action-secondary:hover {
    border-color: rgba(34, 114, 93, 0.45);
    background: #edf3ef;
    color: var(--pp-accent-strong);
}

.public-profile-action:active {
    transform: translateY(0) scale(0.98);
}

.public-profile-action:disabled {
    cursor: wait;
    opacity: 0.64;
    transform: none;
}

.public-profile-action.is-applied {
    border-color: rgba(34, 114, 93, 0.18);
    background: #e7f0eb;
    color: #47665d;
    box-shadow: none;
    cursor: default;
}

.public-profile-action:focus-visible,
.public-profile-breadcrumb a:focus-visible,
.public-profile-post-item:focus-visible,
.public-profile-section-heading a:focus-visible,
.public-profile-about-card button:focus-visible,
.public-profile-boardgame-heading a:focus-visible {
    outline: 3px solid rgba(231, 150, 77, 0.55);
    outline-offset: 3px;
}

.public-profile-rule {
    display: grid;
    grid-template-columns: auto minmax(2rem, 1fr) auto;
    align-items: center;
    gap: 1rem;
    padding: 0 3.5rem;
    color: #83908c;
    font-size: 0.62rem;
    font-weight: 700;
    letter-spacing: 0.17em;
}

.public-profile-rule i {
    height: 1px;
    background: var(--pp-line);
}

.public-profile-grid {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(18rem, 21rem);
    gap: 3.25rem;
    padding: 3rem 3.5rem 3.75rem;
}

.public-profile-primary-column,
.public-profile-secondary-column {
    min-width: 0;
}

.public-profile-primary-column {
    display: flex;
    flex-direction: column;
    gap: 3.5rem;
}

.public-profile-secondary-column {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.public-profile-section-heading {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 2rem;
    margin-bottom: 1.35rem;
}

.public-profile-section-index {
    margin: 0 0 0.42rem;
    color: var(--pp-accent);
    font-size: 0.68rem;
    font-weight: 750;
    letter-spacing: 0.12em;
}

.public-profile-section-heading h2,
.public-profile-boardgame-heading h2 {
    margin: 0;
    color: var(--pp-ink);
    font-size: clamp(1.35rem, 2vw, 1.75rem);
    font-weight: 720;
    line-height: 1.2;
    letter-spacing: -0.025em;
    text-wrap: balance;
}

.public-profile-history-summary {
    display: flex;
    align-items: flex-end;
    gap: 1.5rem;
    margin: 0;
}

.public-profile-history-summary div {
    display: flex;
    flex-direction: column-reverse;
    gap: 0.12rem;
}

.public-profile-history-summary dt {
    color: #7b8884;
    font-size: 0.68rem;
    font-weight: 600;
}

.public-profile-history-summary dd {
    margin: 0;
    color: var(--pp-ink);
    font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
    font-size: 1.45rem;
    font-weight: 700;
    font-variant-numeric: tabular-nums;
    line-height: 1;
}

.public-profile-game-list {
    display: flex;
    flex-direction: column;
    border-top: 1px solid var(--pp-line);
}

.public-profile-game-item {
    position: relative;
    display: grid;
    grid-template-columns: 2.4rem minmax(0, 1fr) auto;
    align-items: center;
    gap: 1rem;
    min-height: 86px;
    padding: 1rem 0.2rem 1.15rem;
    border-bottom: 1px solid var(--pp-line);
    overflow: hidden;
}

.public-profile-game-rank {
    color: #8a9792;
    font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
    font-size: 0.72rem;
    font-weight: 700;
    font-variant-numeric: tabular-nums;
}

.public-profile-game-copy {
    min-width: 0;
}

.public-profile-game-name {
    margin: 0;
    color: var(--pp-ink);
    font-size: 1rem;
    font-weight: 720;
    line-height: 1.35;
}

.public-profile-game-copy p {
    margin: 0.22rem 0 0;
    color: #7c8985;
    font-size: 0.72rem;
}

.public-profile-game-count {
    display: flex;
    align-items: baseline;
    gap: 0.28rem;
    color: #61706b;
}

.public-profile-game-count strong {
    color: var(--pp-accent-strong);
    font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
    font-size: 1.45rem;
    font-variant-numeric: tabular-nums;
}

.public-profile-game-count span {
    font-size: 0.72rem;
    font-weight: 650;
}

.public-profile-game-item progress {
    position: absolute;
    right: 0;
    bottom: -1px;
    left: 0;
    width: 100%;
    height: 3px;
    border: 0;
    appearance: none;
    background: transparent;
}

.public-profile-game-item progress::-webkit-progress-bar {
    background: transparent;
}

.public-profile-game-item progress::-webkit-progress-value {
    border-radius: 999px;
    background: var(--pp-accent);
}

.public-profile-game-item progress::-moz-progress-bar {
    border-radius: 999px;
    background: var(--pp-accent);
}

.public-profile-privacy-note {
    display: flex;
    align-items: center;
    gap: 0.45rem;
    margin: 0.9rem 0 0;
    color: #77847f;
    font-size: 0.72rem;
    line-height: 1.5;
}

.public-profile-privacy-note svg {
    flex: 0 0 auto;
    width: 15px;
    height: 15px;
    fill: none;
    stroke: currentColor;
    stroke-width: 1.8;
    stroke-linecap: round;
    stroke-linejoin: round;
}

.public-profile-empty-state {
    display: grid;
    grid-template-columns: auto minmax(0, 1fr) auto;
    align-items: center;
    gap: 1rem;
    min-height: 112px;
    padding: 1.25rem 1.4rem;
    border: 1px dashed rgba(34, 114, 93, 0.26);
    border-radius: 14px;
    background: #f3f5ef;
}

.public-profile-empty-symbol {
    color: var(--pp-accent);
    font-size: 2.3rem;
}

.public-profile-empty-state h3 {
    margin: 0;
    color: var(--pp-ink);
    font-size: 0.95rem;
}

.public-profile-empty-state p,
.public-profile-inline-empty p,
.public-profile-boardgame-empty p {
    margin: 0.25rem 0 0;
    color: var(--pp-muted);
    font-size: 0.78rem;
    line-height: 1.6;
}

.public-profile-empty-state a {
    color: var(--pp-accent-strong);
    font-size: 0.78rem;
    font-weight: 700;
    text-underline-offset: 3px;
}

.public-profile-section-heading-simple {
    align-items: center;
}

.public-profile-section-heading-simple > a {
    display: inline-flex;
    min-height: 44px;
    align-items: center;
    color: var(--pp-accent-strong);
    font-size: 0.76rem;
    font-weight: 700;
    text-decoration: none;
}

.public-profile-section-heading-simple > a:hover {
    text-decoration: underline;
    text-underline-offset: 4px;
}

.public-profile-post-list {
    display: flex;
    flex-direction: column;
    border-top: 1px solid var(--pp-line);
}

.public-profile-post-item {
    display: grid;
    grid-template-columns: 1.6rem minmax(0, 1fr) auto 1.2rem;
    align-items: center;
    gap: 0.85rem;
    min-height: 62px;
    padding: 0.75rem 0.2rem;
    border-bottom: 1px solid var(--pp-line);
    color: inherit;
    text-decoration: none;
    transition: color 180ms ease, padding 180ms ease, background 180ms ease;
}

.public-profile-post-item:hover {
    padding-right: 0.5rem;
    padding-left: 0.5rem;
    background: #f4f6f1;
    color: var(--pp-accent-strong);
}

.public-profile-post-index {
    color: #94a09c;
    font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
    font-size: 0.68rem;
    font-variant-numeric: tabular-nums;
}

.public-profile-post-title {
    min-width: 0;
    overflow: hidden;
    color: currentColor;
    font-size: 0.86rem;
    font-weight: 650;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.public-profile-post-time {
    color: #899591;
    font-size: 0.7rem;
    white-space: nowrap;
}

.public-profile-post-item > svg {
    width: 16px;
    height: 16px;
    fill: none;
    stroke: currentColor;
    stroke-width: 1.8;
    stroke-linecap: round;
    stroke-linejoin: round;
}

.public-profile-inline-empty {
    padding: 1.35rem 0;
    border-top: 1px solid var(--pp-line);
    border-bottom: 1px solid var(--pp-line);
}

.public-profile-inline-empty > span {
    color: var(--pp-ink);
    font-size: 0.88rem;
    font-weight: 700;
}

.public-profile-boardgame-summary {
    padding: 1.5rem;
    border: 1px solid var(--pp-line);
    border-radius: 18px 18px 12px 12px;
    background: var(--pp-paper-soft);
}

.public-profile-boardgame-heading {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 0.75rem;
}

.public-profile-boardgame-heading h2 {
    max-width: 14rem;
    font-size: 1.15rem;
}

.public-profile-boardgame-heading a {
    color: var(--pp-accent-strong);
    font-size: 0.72rem;
    font-weight: 700;
    text-decoration: none;
}

.public-profile-boardgame-heading a:hover {
    text-decoration: underline;
    text-underline-offset: 3px;
}

.public-profile-boardgame-counts {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0.65rem;
    margin-top: 1.25rem;
}

.public-profile-boardgame-counts > div {
    display: flex;
    flex-direction: column;
    gap: 0.18rem;
    padding: 0.8rem;
    border-left: 2px solid rgba(34, 114, 93, 0.35);
    background: rgba(255, 253, 248, 0.7);
}

.public-profile-boardgame-counts strong {
    color: var(--pp-ink);
    font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
    font-size: 1.35rem;
    font-variant-numeric: tabular-nums;
}

.public-profile-boardgame-counts span {
    color: var(--pp-muted);
    font-size: 0.7rem;
}

.public-profile-boardgame-covers {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 0.45rem;
    margin-top: 1rem;
}

.public-profile-boardgame-covers img {
    width: 100%;
    height: auto;
    aspect-ratio: 3 / 4;
    border: 2px solid var(--pp-paper);
    border-radius: 7px;
    object-fit: cover;
    box-shadow: 0 5px 12px rgba(43, 72, 64, 0.12);
}

.public-profile-boardgame-covers img:nth-child(n + 5) {
    display: none;
}

.public-profile-boardgame-empty {
    margin-top: 1.25rem;
    padding-top: 1rem;
    border-top: 1px solid var(--pp-line);
}

.public-profile-boardgame-empty > span {
    color: #8a9893;
    font-size: 1.05rem;
    letter-spacing: 0.35em;
}

.public-profile-about-card {
    position: relative;
    min-height: 180px;
    overflow: hidden;
    padding: 1.5rem;
    border-radius: 12px 12px 20px 20px;
    background: #f0c777;
    color: #22372f;
}

.public-profile-about-card::after {
    content: '';
    position: absolute;
    right: -3.5rem;
    bottom: -4.5rem;
    width: 10rem;
    height: 10rem;
    border: 1px solid rgba(57, 75, 67, 0.25);
    border-radius: 50%;
    box-shadow: 0 0 0 1.7rem rgba(255, 253, 248, 0.1), 0 0 0 3.4rem rgba(255, 253, 248, 0.08);
}

.public-profile-about-mark {
    display: block;
    color: #29443a;
    font-family: Georgia, serif;
    font-size: 1.9rem;
    font-weight: 700;
    line-height: 1;
}

.public-profile-about-card p {
    position: relative;
    z-index: 1;
    max-width: 14rem;
    margin: 1.1rem 0 1.3rem;
    font-family: "Songti SC", "STSong", Georgia, serif;
    font-size: 1.06rem;
    font-weight: 700;
    line-height: 1.55;
    text-wrap: balance;
}

.public-profile-about-card button {
    position: relative;
    z-index: 1;
    min-height: 44px;
    padding: 0;
    border: 0;
    border-bottom: 1px solid currentColor;
    background: transparent;
    color: #29443a;
    font: inherit;
    font-size: 0.76rem;
    font-weight: 750;
    cursor: pointer;
}

.public-profile-about-card button:hover {
    color: #0e5e49;
}

.public-profile-about-card button:disabled {
    cursor: wait;
    opacity: 0.55;
}

@keyframes publicProfileEnter {
    from {
        opacity: 0;
        transform: translateY(12px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@media (max-width: 1040px) {
    .public-profile-hero {
        grid-template-columns: minmax(0, 1fr);
        gap: 1.5rem;
    }

    .public-profile-actions {
        max-width: none;
        justify-content: flex-start;
    }

    .public-profile-grid {
        grid-template-columns: minmax(0, 1fr) minmax(16rem, 18rem);
        gap: 2rem;
    }
}

@media (max-width: 820px) {
    .public-profile-shell {
        width: min(100% - 2rem, 720px);
        padding-top: 1rem;
    }

    .public-profile-hero {
        padding: 2.25rem 2rem 2rem;
    }

    .public-profile-rule {
        padding: 0 2rem;
    }

    .public-profile-grid {
        grid-template-columns: minmax(0, 1fr);
        padding: 2.25rem 2rem 2.75rem;
    }

    .public-profile-secondary-column {
        display: grid;
        grid-template-columns: minmax(0, 1fr) minmax(0, 0.8fr);
        align-items: stretch;
    }

    .public-profile-boardgame-summary,
    .public-profile-about-card {
        min-height: 100%;
    }
}

@media (max-width: 600px) {
    .public-profile-page::after {
        background-size: 36px 36px;
    }

    .public-profile-shell {
        width: min(100% - 1rem, 540px);
        padding-bottom: 3rem;
    }

    .public-profile-breadcrumb {
        margin-left: 0.55rem;
    }

    .public-profile-sheet {
        border-radius: 20px 20px 14px 14px;
    }

    .public-profile-hero {
        padding: 1.5rem 1.25rem 1.35rem;
    }

    .public-profile-identity {
        align-items: flex-start;
        gap: 1rem;
    }

    .public-profile-avatar-ring {
        width: 82px;
        height: 82px;
        padding: 3px;
    }

    .public-profile-avatar-ring .avatar-preview.placeholder {
        font-size: 1.7rem;
    }

    .public-profile-kicker {
        margin-top: 0.1rem;
        margin-bottom: 0.45rem;
        font-size: 0.64rem;
    }

    .public-profile-name {
        font-size: clamp(1.8rem, 9vw, 2.45rem);
    }

    .public-profile-bio {
        margin-top: 0.9rem;
        font-size: 0.88rem;
    }

    .public-profile-actions {
        display: grid;
        grid-template-columns: repeat(2, minmax(0, 1fr));
        width: 100%;
        gap: 0.5rem;
    }

    .public-profile-action:only-child,
    .public-profile-action:last-child:nth-child(odd) {
        grid-column: 1 / -1;
    }

    .public-profile-rule {
        padding: 0 1.25rem;
        font-size: 0.53rem;
    }

    .public-profile-grid {
        gap: 2.5rem;
        padding: 2rem 1.25rem 2.25rem;
    }

    .public-profile-primary-column {
        gap: 2.75rem;
    }

    .public-profile-section-heading {
        align-items: flex-start;
        flex-direction: column;
        gap: 1rem;
    }

    .public-profile-section-heading-simple {
        flex-direction: row;
        align-items: center;
    }

    .public-profile-history-summary {
        width: 100%;
        justify-content: flex-start;
    }

    .public-profile-game-item {
        grid-template-columns: 1.7rem minmax(0, 1fr) auto;
        gap: 0.65rem;
    }

    .public-profile-game-copy p {
        display: none;
    }

    .public-profile-privacy-note {
        align-items: flex-start;
    }

    .public-profile-empty-state {
        grid-template-columns: auto minmax(0, 1fr);
    }

    .public-profile-empty-state a {
        grid-column: 2;
    }

    .public-profile-post-item {
        grid-template-columns: 1.4rem minmax(0, 1fr) 1rem;
    }

    .public-profile-post-time {
        display: none;
    }

    .public-profile-secondary-column {
        display: flex;
    }

    .public-profile-boardgame-summary {
        min-height: auto;
    }

    .public-profile-about-card {
        min-height: 180px;
    }
}

@media (max-width: 380px) {
    .public-profile-identity {
        display: grid;
        grid-template-columns: auto minmax(0, 1fr);
    }

    .public-profile-bio {
        grid-column: 1 / -1;
    }

    .public-profile-rule span:last-child {
        display: none;
    }

    .public-profile-rule {
        grid-template-columns: auto minmax(2rem, 1fr);
    }

    .public-profile-actions {
        grid-template-columns: minmax(0, 1fr);
    }

    .public-profile-action,
    .public-profile-action:last-child:nth-child(odd) {
        grid-column: auto;
        width: 100%;
    }

    .public-profile-history-summary {
        gap: 1rem;
    }
}

@media (prefers-reduced-motion: reduce) {
    .public-profile-sheet {
        animation: none;
    }

    .public-profile-action,
    .public-profile-post-item {
        transition: none;
    }
}

/* 我的信息页桌游标记摘要（/profile 只加载本文件，不可放在 community.css） */
.profile-boardgame-summary-card {
    background: #fff;
    border-radius: var(--radius-lg);
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.06), 0 4px 24px rgba(0, 0, 0, 0.04);
    padding: 1.25rem 1.5rem;
    margin-top: 1.25rem;
    min-width: 0;
}

.pbgs-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 1rem;
    gap: 0.75rem;
}

.pbgs-title-row {
    display: flex;
    align-items: center;
    gap: 0.45rem;
    font-size: 0.95rem;
    font-weight: 600;
    color: #1d1d1f;
    min-width: 0;
}

.pbgs-manage-link {
    font-size: 0.85rem;
    color: var(--brand-primary);
    text-decoration: none;
    font-weight: 500;
    flex-shrink: 0;
}

.pbgs-manage-link:hover {
    text-decoration: underline;
}

.pbgs-stats {
    display: flex;
    align-items: center;
    gap: 1.25rem;
    margin-bottom: 1rem;
    flex-wrap: wrap;
}

.pbgs-stat {
    display: flex;
    align-items: baseline;
    gap: 0.35rem;
}

.pbgs-stat-count {
    font-size: 1.5rem;
    font-weight: 700;
    color: #1d1d1f;
    font-variant-numeric: tabular-nums;
}

.pbgs-stat-label {
    font-size: 0.85rem;
    color: #617086;
    font-weight: 500;
}

.pbgs-stat-divider {
    width: 1px;
    height: 1.4rem;
    background: #e5e7eb;
}

.pbgs-covers {
    display: flex;
    gap: 0.5rem;
    flex-wrap: wrap;
    min-width: 0;
}

.pbgs-cover-img {
    width: 52px;
    height: 52px;
    max-width: 100%;
    object-fit: cover;
    border-radius: 8px;
    border: 1px solid rgba(0, 0, 0, 0.06);
    flex: 0 0 auto;
}

.pbgs-empty {
    color: #617086;
    font-size: 0.9rem;
    margin: 0;
}

.pbgs-empty a {
    color: var(--brand-primary);
    text-decoration: none;
}

.pbgs-empty a:hover {
    text-decoration: underline;
}

@media (max-width: 600px) {
    .profile-boardgame-summary-card {
        padding: 1rem 1.1rem;
    }

    .pbgs-cover-img {
        width: 48px;
        height: 48px;
    }
}
