/* 恋爱一周年纪念页面样式 */

/* 全局样式重置 */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

/* CSS变量定义 - 恋爱主题配色 */
:root {
    --primary-love: #ff6b9d;
    --secondary-love: #ff8fab;
    --accent-love: #ffa8c5;
    --soft-pink: #ffe0ec;
    --warm-gold: #ffd700;
    --deep-rose: #e91e63;
    --text-primary: #2c3e50;
    --text-secondary: #7f8c8d;
    --background-light: #fff5f7;
    --background-white: #ffffff;
    --shadow-soft: 0 8px 32px rgba(255, 107, 157, 0.15);
    --shadow-hover: 0 12px 48px rgba(255, 107, 157, 0.25);
    --gradient-love: linear-gradient(135deg, #ff6b9d 0%, #ffa8c5 50%, #ffd700 100%);
    --gradient-soft: linear-gradient(135deg, #ffe0ec 0%, #fff5f7 100%);
}

/* 基础样式 */
body {
    font-family: 'Arial', 'Microsoft YaHei', sans-serif;
    background: var(--background-light);
    color: var(--text-primary);
    line-height: 1.6;
    overflow-x: hidden;
}

/* 背景动画效果 */
#particles {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
    background: var(--gradient-soft);
}

/* 爱心飘落动画 */
.falling-hearts {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
    overflow: hidden;
    pointer-events: none;
}

.falling-hearts::before,
.falling-hearts::after {
    content: '💖';
    position: absolute;
    font-size: 20px;
    animation: float 15s infinite linear;
    opacity: 0.7;
}

.falling-hearts::before {
    left: 10%;
    animation-delay: 0s;
}

.falling-hearts::after {
    left: 80%;
    animation-delay: 7s;
}

@keyframes float {
    0% {
        transform: translateY(-100px) rotate(0deg);
        opacity: 0;
    }
    10% {
        opacity: 0.7;
    }
    90% {
        opacity: 0.7;
    }
    100% {
        transform: translateY(100vh) rotate(360deg);
        opacity: 0;
    }
}

/* 容器样式 */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* 头部样式 */
.header {
    text-align: center;
    padding: 60px 0 40px;
    background: var(--gradient-love);
    color: white;
    border-radius: 0 0 50px 50px;
    margin-bottom: 40px;
    box-shadow: var(--shadow-soft);
    position: relative;
    overflow: hidden;
}

.header::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: repeating-linear-gradient(
        45deg,
        transparent,
        transparent 10px,
        rgba(255, 255, 255, 0.05) 10px,
        rgba(255, 255, 255, 0.05) 20px
    );
    animation: shimmer 20s linear infinite;
}

@keyframes shimmer {
    0% { transform: translateX(-100%) translateY(-100%); }
    100% { transform: translateX(100%) translateY(100%); }
}

.header-top {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 30px;
    padding: 0 20px;
    position: relative;
    z-index: 2;
}

.welcome-message {
    font-size: 18px;
    font-weight: 500;
}

.logout-btn {
    background: rgba(255, 255, 255, 0.2);
    border: 1px solid rgba(255, 255, 255, 0.3);
    color: white;
    padding: 8px 16px;
    border-radius: 25px;
    cursor: pointer;
    transition: all 0.3s ease;
    backdrop-filter: blur(10px);
}

.logout-btn:hover {
    background: rgba(255, 255, 255, 0.3);
    transform: translateY(-2px);
}

.title {
    font-size: 3.5em;
    margin: 20px 0;
    position: relative;
    z-index: 2;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.1);
}

.heart-icon {
    color: var(--warm-gold);
    animation: heartbeat 2s ease-in-out infinite;
}

@keyframes heartbeat {
    0% { transform: scale(1); }
    14% { transform: scale(1.1); }
    28% { transform: scale(1); }
    42% { transform: scale(1.1); }
    70% { transform: scale(1); }
}

.subtitle {
    font-size: 1.3em;
    opacity: 0.9;
    margin-bottom: 20px;
}

/* 时间计算区域样式 */
.love-time {
    background: var(--background-white);
    border-radius: 30px;
    padding: 50px;
    margin: 40px 0;
    box-shadow: var(--shadow-soft);
    text-align: center;
    position: relative;
    overflow: hidden;
}

.love-time::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 5px;
    background: var(--gradient-love);
}

.love-time h2 {
    font-size: 2.2em;
    margin-bottom: 30px;
    background: var(--gradient-love);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.time-display {
    display: flex;
    justify-content: center;
    gap: 30px;
    margin: 40px 0;
    flex-wrap: wrap;
}

.time-item {
    background: var(--gradient-soft);
    border-radius: 20px;
    padding: 30px 20px;
    min-width: 120px;
    box-shadow: var(--shadow-soft);
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.time-item:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-hover);
}

.time-item::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: var(--gradient-love);
    opacity: 0;
    transition: opacity 0.3s ease;
    border-radius: 20px;
}

.time-item:hover::before {
    opacity: 0.1;
}

.time-number {
    display: block;
    font-size: 3em;
    font-weight: bold;
    background: var(--gradient-love);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    margin-bottom: 10px;
    animation: pulse 2s ease-in-out infinite;
}

@keyframes pulse {
    0% { transform: scale(1); }
    50% { transform: scale(1.05); }
    100% { transform: scale(1); }
}

.time-label {
    font-size: 1.1em;
    color: var(--text-secondary);
    font-weight: 500;
}

.love-date {
    font-size: 1.2em;
    color: var(--text-secondary);
    margin-top: 20px;
}

/* 相册展示区域样式 */
.photo-gallery {
    background: var(--background-white);
    border-radius: 30px;
    padding: 50px;
    margin: 40px 0;
    box-shadow: var(--shadow-soft);
    text-align: center;
}

.photo-gallery h2 {
    font-size: 2.2em;
    margin-bottom: 30px;
    background: var(--gradient-love);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.gallery-container {
    position: relative;
    max-width: 600px;
    margin: 0 auto;
}

.photo-slider {
    position: relative;
    overflow: hidden;
    border-radius: 20px;
    box-shadow: var(--shadow-soft);
}

.photo-item {
    display: none;
    position: relative;
}

.photo-item.active {
    display: block;
    animation: fadeIn 0.5s ease-in-out;
}

@keyframes fadeIn {
    from { opacity: 0; transform: scale(0.9); }
    to { opacity: 1; transform: scale(1); }
}

.photo-item img {
    width: 100%;
    height: 400px;
    object-fit: contain;
    border-radius: 20px;
    background: #f8f9fa;
}

.photo-caption {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    background: linear-gradient(transparent, rgba(0, 0, 0, 0.7));
    color: white;
    padding: 20px;
    font-size: 1.2em;
    border-radius: 0 0 20px 20px;
}

.gallery-controls {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 20px;
    margin-top: 30px;
}

.prev-btn,
.next-btn {
    background: var(--gradient-love);
    color: white;
    border: none;
    width: 50px;
    height: 50px;
    border-radius: 50%;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.2em;
}

.prev-btn:hover,
.next-btn:hover {
    transform: scale(1.1);
    box-shadow: var(--shadow-hover);
}

.photo-dots {
    display: flex;
    gap: 10px;
}

.dot {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background: var(--text-secondary);
    cursor: pointer;
    transition: all 0.3s ease;
}

.dot.active {
    background: var(--primary-love);
    transform: scale(1.3);
}

/* 音乐播放器样式 */
.music-player {
    background: var(--background-white);
    border-radius: 30px;
    padding: 40px;
    margin: 40px 0;
    box-shadow: var(--shadow-soft);
    text-align: center;
}

.music-player h2 {
    font-size: 2.2em;
    margin-bottom: 30px;
    background: var(--gradient-love);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.player-container {
    max-width: 400px;
    margin: 0 auto;
}

.player-info {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 15px;
    margin-bottom: 20px;
}

.music-icon {
    font-size: 2em;
    color: var(--primary-love);
    animation: rotate 3s linear infinite;
}

@keyframes rotate {
    from { transform: rotate(0deg); }
    to { transform: rotate(360deg); }
}

.song-info {
    text-align: left;
}

.song-title {
    font-size: 1.3em;
    font-weight: bold;
    color: var(--text-primary);
}

.song-artist {
    color: var(--text-secondary);
    font-size: 1.1em;
}

.player-controls {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 20px;
}

.play-btn {
    background: var(--gradient-love);
    color: white;
    border: none;
    width: 60px;
    height: 60px;
    border-radius: 50%;
    cursor: pointer;
    font-size: 1.5em;
    transition: all 0.3s ease;
}

.play-btn:hover {
    transform: scale(1.1);
    box-shadow: var(--shadow-hover);
}

.volume-control {
    display: flex;
    align-items: center;
    gap: 10px;
}

.volume-control i {
    color: var(--primary-love);
    font-size: 1.2em;
}

#volumeSlider {
    width: 100px;
    accent-color: var(--primary-love);
}

/* 爱情宣言样式 */
.love-message {
    background: var(--background-white);
    border-radius: 30px;
    padding: 50px;
    margin: 40px 0;
    box-shadow: var(--shadow-soft);
    text-align: center;
    position: relative;
    overflow: hidden;
}

.love-message::before {
    content: '💕';
    position: absolute;
    top: -20px;
    right: -20px;
    font-size: 100px;
    opacity: 0.1;
    transform: rotate(15deg);
}

.love-message h2 {
    font-size: 2.2em;
    margin-bottom: 30px;
    background: var(--gradient-love);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.love-text {
    font-size: 1.4em;
    line-height: 2;
    color: var(--text-primary);
    max-width: 600px;
    margin: 0 auto;
    animation: typewriter 3s ease-in-out;
}

@keyframes typewriter {
    from { width: 0; opacity: 0; }
    to { width: 100%; opacity: 1; }
}

/* 底部样式 */
.footer {
    text-align: center;
    padding: 40px 0;
    background: var(--gradient-love);
    color: white;
    border-radius: 50px 50px 0 0;
    margin-top: 60px;
}

.footer-content p {
    margin: 10px 0;
    font-size: 1.1em;
}

.footer-date {
    opacity: 0.8;
    font-size: 1em;
}

/* 移动端响应式设计 */
@media screen and (max-width: 768px) {
    /* 容器适配 */
    .container {
        padding: 0 15px;
    }
    
    /* 头部适配 */
    .header {
        padding: 40px 0 30px;
        border-radius: 0 0 30px 30px;
    }
    
    .header-top {
        flex-direction: column;
        gap: 15px;
        padding: 0 15px;
    }
    
    .welcome-message {
        font-size: 16px;
    }
    
    .title {
        font-size: 2.5em;
        margin: 15px 0;
    }
    
    .subtitle {
        font-size: 1.1em;
    }
    
    /* 时间计算区域适配 */
    .love-time {
        padding: 30px 20px;
        margin: 30px 0;
    }
    
    .love-time h2 {
        font-size: 1.8em;
        margin-bottom: 20px;
    }
    
    .time-display {
        gap: 15px;
        margin: 30px 0;
    }
    
    .time-item {
        padding: 20px 15px;
        min-width: 100px;
    }
    
    .time-number {
        font-size: 2.2em;
    }
    
    .time-label {
        font-size: 1em;
    }
    
    /* 相册展示区域适配 */
    .photo-gallery {
        padding: 30px 20px;
        margin: 30px 0;
    }
    
    .photo-gallery h2 {
        font-size: 1.8em;
        margin-bottom: 20px;
    }
    
    .photo-item img {
        height: 250px;
    }
    
    .photo-caption {
        padding: 15px;
        font-size: 1em;
    }
    
    .gallery-controls {
        gap: 15px;
        margin-top: 20px;
    }
    
    .prev-btn,
    .next-btn {
        width: 45px;
        height: 45px;
        font-size: 1.1em;
    }
    
    /* 音乐播放器适配 */
    .music-player {
        padding: 30px 20px;
        margin: 30px 0;
    }
    
    .music-player h2 {
        font-size: 1.8em;
        margin-bottom: 20px;
    }
    
    .player-controls {
        gap: 15px;
        margin: 20px 0;
    }
    
    .play-btn {
        width: 50px;
        height: 50px;
        font-size: 1.2em;
    }
    
    .volume-control {
        width: 120px;
    }
    
    /* 爱情宣言适配 */
    .love-message {
        padding: 30px 20px;
        margin: 30px 0;
    }
    
    .love-message h2 {
        font-size: 1.8em;
        margin-bottom: 20px;
    }
    
    .love-text {
        font-size: 1.2em;
        line-height: 1.8;
    }
    
    /* 特别提示区域适配 */
    .special-notice {
        padding: 20px;
        margin: 20px 0;
    }
    
    .princess-link {
        font-size: 1.4rem;
        padding: 15px 30px;
        gap: 10px;
    }
    
    .princess-link .fa-crown {
        font-size: 1.5rem;
    }
    
    /* 底部样式适配 */
    .footer {
        padding: 30px 0;
        border-radius: 30px 30px 0 0;
        margin-top: 30px;
    }
    
    .footer-content p {
        font-size: 1em;
    }
}

@media screen and (max-width: 480px) {
    /* 超小屏幕适配 */
    .container {
        padding: 0 10px;
    }
    
    .title {
        font-size: 2em;
    }
    
    .subtitle {
        font-size: 1em;
    }
    
    .love-time,
    .photo-gallery,
    .music-player,
    .love-message {
        padding: 20px 15px;
    }
    
    .love-time h2,
    .photo-gallery h2,
    .music-player h2,
    .love-message h2 {
        font-size: 1.5em;
    }
    
    .time-display {
        gap: 10px;
    }
    
    .time-item {
        padding: 15px 10px;
        min-width: 80px;
    }
    
    .time-number {
        font-size: 1.8em;
    }
    
    .photo-item img {
        height: 200px;
    }
    
    .love-text {
        font-size: 1.1em;
    }
    
    .princess-link {
        font-size: 1.2rem;
        padding: 12px 25px;
    }
    
    .princess-link .fa-crown {
        font-size: 1.3rem;
    }
}

/* 新增浪漫动画效果 */

/* 爱心爆炸动画 */
.heart-explosion {
    position: relative;
    display: inline-block;
    cursor: pointer;
}

.heart-explosion::before {
    content: '💖';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    font-size: 2em;
    opacity: 0;
    animation: explode 1s ease-out forwards;
}

@keyframes explode {
    0% {
        opacity: 1;
        transform: translate(-50%, -50%) scale(1);
    }
    100% {
        opacity: 0;
        transform: translate(-50%, -50%) scale(3) rotate(45deg);
    }
}

/* 渐变过渡效果 */
.gradient-transition {
    transition: background 1s ease-in-out;
}

.gradient-transition:hover {
    background: var(--gradient-love);
}

/* 粒子效果 (使用伪元素模拟) */
.particle-effect {
    position: relative;
    overflow: hidden;
}

.particle-effect::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: radial-gradient(circle, rgba(255, 107, 157, 0.2) 0%, transparent 70%);
    opacity: 0;
    animation: particle-burst 2s infinite;
}

@keyframes particle-burst {
    0% { opacity: 0; transform: scale(0); }
    50% { opacity: 1; transform: scale(1); }
    100% { opacity: 0; transform: scale(1.5); }
}

/* 旋转心形动画 */
.rotating-heart {
    display: inline-block;
    animation: rotate-heart 4s linear infinite;
}

@keyframes rotate-heart {
    0% { transform: rotate(0deg) scale(1); }
    50% { transform: rotate(180deg) scale(1.2); }
    100% { transform: rotate(360deg) scale(1); }
}

/* 淡入文字动画 */
.fade-in-text {
    opacity: 0;
    animation: fade-in 2s ease-in forwards;
}

@keyframes fade-in {
    0% { opacity: 0; transform: translateY(20px); }
    100% { opacity: 1; transform: translateY(0); }
}

/* 页面整体过渡动画 */
.section-transition {
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 0.5s ease, transform 0.5s ease;
}

.section-transition.visible {
    opacity: 1;
    transform: translateY(0);
}

/* 鼠标交互效果 */
.interactive-element {
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.interactive-element:hover {
    transform: scale(1.05);
    box-shadow: var(--shadow-hover);
    background: var(--gradient-love);
}

.interactive-element.heart-explosion::before {
    animation: explode 1s ease-out;
}

/* 特别提示区域样式 */
.special-notice {
    background: linear-gradient(135deg, rgba(255, 182, 193, 0.9), rgba(255, 192, 203, 0.9));
    border-radius: 20px;
    padding: 30px;
    margin: 30px 0;
    box-shadow: 0 15px 35px rgba(255, 105, 180, 0.3);
    backdrop-filter: blur(10px);
    text-align: center;
    position: relative;
    overflow: hidden;
}

.special-notice::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: linear-gradient(45deg, transparent, rgba(255, 255, 255, 0.1), transparent);
    animation: shimmer 3s infinite;
    pointer-events: none;
}

@keyframes shimmer {
    0% { transform: translateX(-100%) translateY(-100%) rotate(45deg); }
    100% { transform: translateX(100%) translateY(100%) rotate(45deg); }
}

.notice-container {
    position: relative;
    z-index: 2;
}

.princess-link {
    display: inline-flex;
    align-items: center;
    gap: 15px;
    color: #8B0000;
    text-decoration: none;
    font-size: 1.8rem;
    font-weight: 700;
    padding: 20px 40px;
    border-radius: 50px;
    background: linear-gradient(45deg, #FFD700, #FFA500, #FFD700);
    box-shadow: 0 8px 25px rgba(255, 215, 0, 0.4);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    overflow: hidden;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.3);
}

.princess-text {
    text-align: center;
    line-height: 1.4;
}

.sub-text {
    font-size: 0.7em;
    font-weight: 500;
    color: #B22222;
    text-shadow: 1px 1px 2px rgba(0, 0, 0, 0.2);
    opacity: 0.9;
    display: block;
    margin-top: 5px;
}

.princess-link::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.4), transparent);
    transition: left 0.5s;
}

.princess-link:hover::before {
    left: 100%;
}

.princess-link:hover {
    transform: translateY(-5px) scale(1.05);
    box-shadow: 0 15px 40px rgba(255, 215, 0, 0.6);
    color: #8B0000;
    text-decoration: none;
}

.princess-link .fa-crown {
    color: #FFD700;
    font-size: 2rem;
    animation: crownGlow 2s ease-in-out infinite alternate;
}

.princess-link .fa-arrow-down {
    color: #FF1493;
    animation: bounce 1.5s ease-in-out infinite;
}

@keyframes crownGlow {
    0% { 
        text-shadow: 0 0 10px #FFD700, 0 0 20px #FFD700;
        transform: rotate(-5deg);
    }
    100% { 
        text-shadow: 0 0 20px #FFD700, 0 0 30px #FFA500;
        transform: rotate(5deg);
    }
}

@keyframes bounce {
    0%, 20%, 50%, 80%, 100% {
        transform: translateY(0);
    }
    40% {
        transform: translateY(-10px);
    }
    60% {
        transform: translateY(-5px);
    }
}

/* 应用到现有元素 */
.love-time, .photo-gallery, .music-player, .love-message, .love-timeline {
    @extend .section-transition;
}

.time-item, .photo-item, .play-btn, .timeline-item {
    @extend .interactive-element;
}