/* 记忆相册 样式 — 从 extras.css 拆分 */
/* --- 【全新】回忆相册 (Summary App V2) --- */

/* 1. 角色选择页样式 (拍立得相册) */
#summary-character-select-page .page-content {
    background-color: #f4f1ea; /* 复古相册的米色背景 */
    padding: 20px;
    overflow-y: auto;
}

.polaroid-grid {
    display: grid;
    /* 响应式网格，每列最小140px，最多占满 */
    grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
    gap: 25px;
}

.polaroid-card {
    background-color: #fff;
    padding: 12px 12px 20px 12px; /* 底部留出更多空间写字 */
    border-radius: 4px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.15);
    cursor: pointer;
    transition: transform 0.2s ease-in-out;
    text-decoration: none; /* 去掉可能的链接下划线 */
}

.polaroid-card:hover {
    transform: scale(1.05) rotate(0deg) !important; /* 鼠标悬浮时摆正并放大 */
    z-index: 10;
}

/* 随机旋转效果，让相册看起来更自然 */
.polaroid-card:nth-child(5n+1) { transform: rotate(5deg); }
.polaroid-card:nth-child(5n+2) { transform: rotate(-3deg); }
.polaroid-card:nth-child(5n+3) { transform: rotate(4deg); }
.polaroid-card:nth-child(5n+4) { transform: rotate(-6deg); }
.polaroid-card:nth-child(5n+5) { transform: rotate(2deg); }

.polaroid-image {
    width: 100%;
    padding-bottom: 100%; /* 关键：保持1:1的正方形比例 */
    background-color: #e9ecef;
    background-size: cover;
    background-position: center;
    border: 1px solid #eee;
}

.polaroid-caption {
    font-family: 'Ma Shan Zheng', cursive; /* 使用手写字体 */
    font-size: 18px;
    color: #555;
    text-align: center;
    margin-top: 15px; /* 图片和文字的间距 */
}

/* 2. 角色专属总结页样式 (这部分和原来基本一样，但更精简) */
#summary-app-page > .page-content {
    background-color: #0f1c24; /* 改成深蓝色夜空背景 */
    background-image: 
        radial-gradient(circle at 50% 30%, rgba(175, 200, 220, 0.1) 0%, transparent 40%),
        radial-gradient(circle at 50% 80%, rgba(175, 200, 220, 0.15) 0%, transparent 50%); /* 增加一点光晕效果 */
    overflow: hidden;
    padding: 0;
    position: relative;
    font-family: sans-serif; /* 恢复默认字体，让手写体等特殊字体能正确生效 */
}


.summary-tabs-container {
    flex-shrink: 0;
    padding: 10px 15px;
    border-bottom: 1px solid #dcd1c4;
    background-color: rgba(244, 241, 234, 0.8);
    backdrop-filter: blur(5px);
}

.summary-tabs {
    display: flex;
    background-color: #e9e2d5;
    border-radius: 8px;
    padding: 4px;
}

.summary-tab-btn {
    flex: 1;
    text-align: center;
    padding: 8px 10px;
    border: none;
    background: none;
    font-size: 14px;
    font-weight: 500;
    color: #a08c75;
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.summary-tab-btn.active {
    background-color: #fff;
    color: #654321;
    box-shadow: 0 1px 3px rgba(0,0,0,0.1);
}

.summary-panes-container {
    flex-grow: 1;
    overflow-y: auto;
    padding: 20px; /* 内容区域统一加内边距 */
}

/* 摘要卡片 */
.summary-card {
    background-color: #ffffff; /* 改为纯白，更干净 */
    border-left: 4px solid var(--accent-color); /* 左侧加一条主题色装饰线 */
    border-radius: 8px; /* 圆角更大一些 */
    padding: 20px; /* 加大内边距 */
    box-shadow: 0 4px 12px rgba(0,0,0,0.06); /* 更柔和的阴影 */
    margin-bottom: 20px; /* 加大卡片间距 */
    cursor: pointer;
    transition: transform 0.2s, box-shadow 0.2s;
    border: none; /* 移除旧边框 */
}
.summary-card:hover {
    transform: translateY(-3px); /* 悬浮时轻微上移 */
    box-shadow: 0 6px 16px rgba(0,0,0,0.1); /* 阴影更明显 */
}
.summary-card-title {
    font-weight: 600;
    font-size: 17px; /* 字体稍大 */
    color: var(--primary-text);
    margin-bottom: 10px;
}
/* 你可以顺便加上这个，让卡片内容行距更舒服 */
.summary-card p {
    font-size: 15px;
    line-height: 1.7;
    color: var(--secondary-text);
}
/* 其他原有的卡片、时间轴样式可以保持不变，这里不再重复 */
.summary-timeline {
    padding-left: 20px;
    border-left: 2px solid #dcd1c4;
    position: relative;
}

.timeline-item {
    margin-bottom: 30px;
    position: relative;
}

.timeline-item::before {
    content: '★'; /* 使用一个更闪亮的星星符号 */
    position: absolute;
    left: -32px; /* 重新微调位置 */
    top: -2px; /* 向上微调，使其中心对齐文字顶部 */
    
    /* 移除旧的圆形样式 */
    width: auto;
    height: auto;
    background: none;
    border: none;
    border-radius: 0;

    /* 星星的核心样式 */
    font-size: 24px; /* 星星大小 */
    line-height: 1;
    color: #ffcc00; /* 星星的主色调：闪耀的金色 */
    
    /* 多巴胺风格的动画效果 */
    animation: dopamine-star-sparkle 2.5s infinite ease-in-out;
    text-shadow: 0 0 5px #fff, 0 0 10px #ffcc00, 0 0 15px #ffa500; /* 添加辉光效果 */
}
@keyframes dopamine-star-sparkle {
    0%, 100% {
        transform: scale(1);
        opacity: 0.8;
    }
    50% {
        transform: scale(1.3);
        opacity: 1;
    }
}


.timeline-date {
    font-weight: bold;
    color: #654321;
    margin-bottom: 8px;
}

.timeline-content {
    background-color: #fffef8;
    padding: 10px 15px;
    border-radius: 6px;
    border: 1px solid #e9e2d5;
}
/* --- 【全新】回忆相册内页拼贴画样式 (最终版) --- */
#summary-app-page .page-content {
    background-color: #0f1c24;
    background-image: 
        radial-gradient(circle at 50% 30%, rgba(175, 200, 220, 0.1) 0%, transparent 40%),
        radial-gradient(circle at 50% 80%, rgba(175, 200, 220, 0.15) 0%, transparent 50%);
    overflow: hidden;
    padding: 0;
    position: relative;
    font-family: sans-serif; /* 恢复默认字体，让特定字体生效 */
}

/* 基础照片/内容卡片样式 */
.collage-item {
    position: absolute;
    background-color: white;
    cursor: pointer;
    transition: transform 0.2s ease-out, box-shadow 0.2s ease-out;
}
.collage-item:hover {
    transform: scale(1.03) rotate(0deg) !important;
    z-index: 10;
    box-shadow: 0 8px 25px rgba(0,0,0,0.5);
}
.collage-item .content-wrapper {
    width: 100%; height: 100%;
    overflow-y: auto; box-sizing: border-box;
    font-family: 'Times New Roman', 'Ma Shan Zheng', serif;
    font-size: 14px; color: #4a4a4a; line-height: 1.7;
}
.content-wrapper h4 {
    margin-top: 0; margin-bottom: 8px; font-size: 16px;
    color: #8c785d; border-bottom: 1px solid #e9e2d5;
    padding-bottom: 5px; font-family: sans-serif;
}
.content-wrapper p, .content-wrapper li { margin: 0 0 10px; }
.content-wrapper ul { padding-left: 20px; }
.content-wrapper hr { border: none; border-top: 1px dashed #ddd; margin: 10px 0; }

/* 样式1: 总结内容 (胶带固定效果) */
#summary-collage-summaries {
    top: 60px; left: 40px; width: 200px; height: 240px; /* 调整了尺寸 */
    transform: rotate(-8deg); padding: 0;
    overflow: hidden; box-shadow: 0 4px 12px rgba(0,0,0,0.4);
}

#summary-collage-summaries::before, #summary-collage-summaries::after {
    content: ''; position: absolute; width: 60px; height: 20px;
    background-color: rgba(255, 255, 255, 0.2);
    box-shadow: 0 1px 3px rgba(0,0,0,0.2);
    border-left: 1px solid rgba(255, 255, 255, 0.1);
    border-right: 1px solid rgba(255, 255, 255, 0.1);
}
#summary-collage-summaries::before { top: -10px; left: -15px; transform: rotate(-30deg); }
#summary-collage-summaries::after { bottom: -12px; right: -10px; transform: rotate(-20deg); }


/* 样式2: 时间轴 (带星星贴纸的拍立得) */
#summary-collage-timeline {
    top: 250px;
    right: 30px;
    width: 250px;
    height: 270px;
    transform: rotate(4deg);
    padding: 12px 12px 50px 12px;
    background: #fff;
}
/* 手写体标题 */
#summary-collage-timeline .caption {
    position: absolute;
    bottom: 15px; left: 0; right: 0;
    text-align: center; margin: 0;
    font-family: 'Caveat', cursive; /* 改用更自然的手写体 */
    font-size: 22px; color: #444;
    transform: rotate(-2deg); /* 让手写字也歪一点 */
}
/* 星星贴纸的样式 */
.star-sticker {
    position: absolute;
    font-size: 40px; /* 控制星星大小 */
    color: #f0f0f0; /* 星星的底色 */
    text-shadow: -1px -1px 0 #fff, 1px -1px 0 #fff, -1px 1px 0 #fff, 1px 1px 0 #fff, 0 0 5px rgba(0,0,0,0.2); /* 制造立体感和阴影 */
}
#star-sticker-1 { top: -15px; left: -18px; transform: rotate(-20deg); }
#star-sticker-2 { top: 20px; left: -25px; transform: rotate(10deg); font-size: 35px;}
#star-sticker-3 { bottom: -20px; right: 25px; transform: rotate(25deg); }
#star-sticker-4 { bottom: 15px; right: -15px; transform: rotate(-10deg); font-size: 35px; }


/* 样式3: 记忆碎片 (带回形针的拍立得) */
#summary-collage-memories {
    bottom: 55px;
    left: 50%; /* 改为居中定位 */
    transform: translateX(-50%) rotate(2deg); /* 水平居中并旋转 */
    width: 280px;
    height: 250px;
    padding: 12px 12px 20px 12px;
    background: #fff;
}
/* 用伪元素制作回形针 */
#summary-collage-memories::before {
    content: '';
    position: absolute;
    top: -8px;
    left: 20px;
    width: 25px;
    height: 70px;
    border: 4px solid #b0b0b0;
    border-radius: 12px;
    transform: rotate(15deg);
    border-bottom-color: transparent; /* 关键：让回形针有个缺口 */
}
#summary-collage-memories:hover {
    transform: translateX(-50%) scale(1.03) rotate(0deg) !important;
}



/* 固定文字样式 */
.text-def {
    position: absolute; top: 65px; left: 245px; right: 20px;
    color: rgba(255, 255, 255, 0.9); font-family: 'Caveat', cursive;
    font-size: 13px; line-height: 1.5; transform: rotate(1deg);
    cursor: pointer; /* <--- 修改这里，把 pointer-events 改成 cursor */
    user-select: none;
    transition: color 0.2s; /* (可选) 增加一个悬浮效果 */
}
.text-def:hover {
    color: #fff;
}
.text-def p { margin: 0 0 4px 0; }

/* 所有装饰元素样式 */
.summary-deco {
    position: absolute; pointer-events: none; user-select: none;
}
#deco-flower { top: 38px; left: 40px; font-size: 24px; color: white; transform: rotate(-15deg); }
#deco-raindrops { top: 90px; left: 18px; font-family: 'Caveat', cursive; font-size: 18px; line-height: 1.4; color: #bbf2d5; text-shadow: 0 0 3px #bbf2d5; }
#deco-apples { top: 740px; left: 100px; font-size: 40px; transform: rotate(-15deg); opacity: 0.8; filter: drop-shadow(0 0 8px #a8e6c1); }
.summary-deco.star { font-weight: normal; }
#deco-star-crystal { top: 35px; right: 65px; font-size: 50px; color: #eaf6ff; text-shadow: 0 0 5px #fff, 0 0 12px #fff; }
#deco-star-blue { bottom: 120px; right: 50px; font-size: 26px; color: #61d2f2; }
#deco-star-pink { bottom: 60px; right: 110px; font-size: 34px; transform: rotate(15deg); color: #ffc0cb; }
#deco-star-yellow { bottom: 80px; right: 80px; font-size: 20px; color: #f7e36e; }
#deco-star-purple { bottom: 65px; right: 75px; font-size: 16px; transform: rotate(-15deg); color: #b39ddb; }
#deco-star-white-glow { bottom: 20px; right: 30px; font-size: 70px; color: white; text-shadow: 0 0 10px #fff; }
#deco-paws { bottom: 25px; right: 75px; color: #69c575; font-size: 20px; transform: rotate(-20deg); opacity: 0.9; }
