/* ===== 基础样式 ===== */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    --pink-light: #FFC0CB;
    --pink-medium: #FFB6C1;
    --blue-light: #B0E0E6;
    --blue-sky: #87CEEB;
    --gold: #FFD700;
    --white: #FFFFFF;
    --text-dark: #333333;
    --text-light: #666666;
    --shadow: rgba(0, 0, 0, 0.1);
    --shadow-hover: rgba(0, 0, 0, 0.15);
    --font-family: "Microsoft YaHei", "PingFang SC", sans-serif;
}

body {
    font-family: var(--font-family);
    color: var(--text-dark);
    line-height: 1.6;
    overflow-x: hidden;
    background: linear-gradient(135deg, #ffeef8 0%, #e3f2fd 100%);
    scroll-behavior: smooth;
}

.section {
    min-height: 100vh;
    padding: 60px 20px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    position: relative;
}

.section-title {
    font-size: 2.5rem;
    font-weight: bold;
    color: var(--pink-medium);
    margin-bottom: 15px;
    text-align: center;
    text-shadow: 2px 2px 4px var(--shadow);
}

.section-desc {
    font-size: 1.1rem;
    color: var(--text-light);
    text-align: center;
    margin-bottom: 40px;
    max-width: 600px;
}

/* ===== 音乐控制按钮 ===== */
.music-toggle {
    position: fixed;
    top: 20px;
    right: 20px;
    width: 55px;
    height: 55px;
    border-radius: 50%;
    border: none;
    background: rgba(255, 255, 255, 0.9);
    backdrop-filter: blur(10px);
    font-size: 1.5rem;
    cursor: pointer;
    z-index: 1000;
    box-shadow: 0 4px 15px var(--shadow);
    transition: all 0.3s ease;
}

.music-toggle:hover {
    background: var(--white);
    transform: scale(1.1);
    box-shadow: 0 6px 20px var(--shadow-hover);
}

/* ===== 1. 欢迎页 ===== */
.welcome-section {
    background: linear-gradient(135deg, var(--pink-light) 0%, var(--blue-sky) 100%);
    position: relative;
    overflow: hidden;
}

.balloons-container {
    position: absolute;
    width: 100%;
    height: 100%;
    top: 0;
    left: 0;
    pointer-events: none;
}

.welcome-content {
    text-align: center;
    z-index: 10;
    color: var(--white);
}

.cake-icon {
    font-size: 5rem;
    margin-bottom: 20px;
    animation: bounce 2s ease-in-out infinite;
}

@keyframes bounce {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-20px); }
}

.main-title {
    font-size: 3rem;
    font-weight: bold;
    margin-bottom: 10px;
    text-shadow: 3px 3px 6px rgba(0, 0, 0, 0.2);
}

.subtitle {
    font-size: 1.3rem;
    margin-bottom: 10px;
}

.birthday-date {
    font-size: 1.5rem;
    font-weight: bold;
    margin-top: 20px;
}

.scroll-hint {
    position: absolute;
    bottom: 30px;
    display: flex;
    flex-direction: column;
    align-items: center;
    color: var(--white);
    animation: float 2s ease-in-out infinite;
}

.arrow {
    font-size: 2rem;
    margin-top: 5px;
}

@keyframes float {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(10px); }
}

/* ===== 2. 成长相册（轮播） ===== */
.photos-section {
    background: linear-gradient(to bottom, #ffeef8, #e3f2fd);
}

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

.slideshow-track {
    position: relative;
    width: 100%;
    border-radius: 20px;
    overflow: hidden;
    box-shadow: 0 15px 40px rgba(0,0,0,0.15);
}

.slide {
    display: none;
    position: relative;
}

.slide.active {
    display: block;
    animation: slideFade 0.6s ease;
}

@keyframes slideFade {
    from { opacity: 0; transform: scale(1.03); }
    to { opacity: 1; transform: scale(1); }
}

.slide img {
    width: 100%;
    height: 500px;
    object-fit: contain;
    background: linear-gradient(135deg, #ffeef8, #e3f2fd);
    display: block;
}

.slide-badge {
    position: absolute;
    top: 15px;
    right: 15px;
    background: linear-gradient(135deg, var(--pink-medium), var(--gold));
    color: var(--white);
    padding: 8px 18px;
    border-radius: 20px;
    font-weight: bold;
    font-size: 1.1rem;
    box-shadow: 0 4px 10px rgba(0,0,0,0.2);
}

.slide-btn {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(255,255,255,0.85);
    border: none;
    width: 44px;
    height: 44px;
    border-radius: 50%;
    font-size: 1.5rem;
    cursor: pointer;
    z-index: 10;
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--pink-medium);
}

.slide-btn:hover {
    background: var(--white);
    transform: translateY(-50%) scale(1.1);
}

.slide-btn.prev { left: -22px; }
.slide-btn.next { right: -22px; }

.slide-dots {
    display: flex;
    justify-content: center;
    gap: 8px;
    margin-top: 20px;
}

.slide-dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: var(--blue-light);
    cursor: pointer;
    transition: all 0.3s ease;
    border: none;
}

.slide-dot.active {
    background: var(--pink-medium);
    transform: scale(1.3);
}

@media (max-width: 768px) {
    .slide img { height: 380px; }
    .slide-btn.prev { left: 5px; }
    .slide-btn.next { right: 5px; }
}

.timeline-container {
    position: relative;
    max-width: 1000px;
    width: 100%;
    padding: 40px 0;
}

.timeline-container::before {
    content: '';
    position: absolute;
    left: 50%;
    top: 0;
    bottom: 0;
    width: 4px;
    background: linear-gradient(to bottom, var(--pink-medium), var(--blue-sky));
    transform: translateX(-50%);
}

.timeline-item {
    position: relative;
    margin-bottom: 60px;
    width: 100%;
    display: flex;
    justify-content: center;
    opacity: 0;
    transform: translateY(30px);
    transition: all 0.6s ease;
}

.timeline-item.visible {
    opacity: 1;
    transform: translateY(0);
}

.timeline-item:nth-child(odd) .photo-card {
    margin-right: auto;
    margin-left: 0;
}

.timeline-item:nth-child(even) .photo-card {
    margin-left: auto;
    margin-right: 0;
}

.timeline-marker {
    position: absolute;
    left: 50%;
    top: 20px;
    width: 20px;
    height: 20px;
    background: var(--gold);
    border: 4px solid var(--white);
    border-radius: 50%;
    transform: translateX(-50%);
    z-index: 10;
    box-shadow: 0 0 0 4px rgba(255, 215, 0, 0.2);
}

.photo-card {
    position: relative;
    width: 45%;
    background: var(--white);
    border-radius: 15px;
    overflow: hidden;
    box-shadow: 0 8px 20px var(--shadow);
    transition: all 0.3s ease;
    cursor: pointer;
}

.photo-card:hover {
    transform: translateY(-10px) scale(1.02);
    box-shadow: 0 12px 30px var(--shadow-hover);
}

.photo-card img {
    width: 100%;
    height: 300px;
    object-fit: contain;
    display: block;
    background: #f5f5f5;
}

.age-badge {
    position: absolute;
    top: 15px;
    right: 15px;
    background: var(--gold);
    color: var(--white);
    padding: 8px 16px;
    border-radius: 20px;
    font-weight: bold;
    font-size: 1.1rem;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.2);
}

/* ===== 3. 家人祝福区 ===== */
.blessings-section {
    background: linear-gradient(to bottom, #e3f2fd, #ffeef8);
    overflow: hidden;
}

.blessings-marquee-wrapper {
    width: 100%;
    overflow: hidden;
    position: relative;
    padding: 20px 0;
    height: 320px;
    display: flex;
    align-items: center;
}

.blessings-marquee-wrapper::before,
.blessings-marquee-wrapper::after {
    content: '';
    position: absolute;
    top: 0;
    bottom: 0;
    width: 80px;
    z-index: 2;
    pointer-events: none;
}

.blessings-marquee-wrapper::before {
    left: 0;
    background: linear-gradient(to right, #f0f8ff, transparent);
}

.blessings-marquee-wrapper::after {
    right: 0;
    background: linear-gradient(to left, #fff5f8, transparent);
}

.blessings-marquee {
    display: flex;
    gap: 25px;
    width: max-content;
    will-change: transform;
}

.blessings-marquee:hover {
    animation-play-state: paused;
}

.blessing-card-auto {
    background: var(--white);
    border-radius: 20px;
    padding: 25px;
    width: 300px;
    flex-shrink: 0;
    box-shadow: 0 6px 20px var(--shadow);
    border-top: 4px solid var(--pink-medium);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.blessing-card-auto:hover {
    transform: translateY(-8px);
    box-shadow: 0 12px 30px var(--shadow-hover);
}

.blessing-avatar {
    font-size: 2.5rem;
    margin-bottom: 10px;
    text-align: center;
}

.blessing-role {
    font-weight: bold;
    color: var(--pink-medium);
    font-size: 1.2rem;
    margin-bottom: 12px;
    text-align: center;
}

.blessing-text {
    color: var(--text-dark);
    line-height: 1.8;
    font-size: 0.95rem;
}
    color: var(--text-dark);
    font-weight: 500;
}

.form-group select,
.form-group textarea {
    width: 100%;
    padding: 12px;
    border: 2px solid var(--blue-light);
    border-radius: 10px;
    font-family: var(--font-family);
    font-size: 1rem;
    transition: all 0.3s ease;
}

.form-group select:focus,
.form-group textarea:focus {
    outline: none;
    border-color: var(--pink-medium);
    box-shadow: 0 0 0 3px rgba(255, 182, 193, 0.2);
}

.submit-btn {
    width: 100%;
    padding: 15px;
    background: linear-gradient(135deg, var(--pink-medium), var(--blue-sky));
    color: var(--white);
    border: none;
    border-radius: 10px;
    font-size: 1.1rem;
    font-weight: bold;
    cursor: pointer;
    transition: all 0.3s ease;
}

.submit-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px var(--shadow-hover);
}

.blessings-display {
    max-width: 800px;
    width: 100%;
}

.display-title {
    font-size: 1.8rem;
    color: var(--blue-sky);
    margin-bottom: 25px;
    text-align: center;
}

.blessings-list {
    display: grid;
    gap: 20px;
}

.blessing-card {
    background: var(--white);
    padding: 20px;
    border-radius: 15px;
    box-shadow: 0 4px 15px var(--shadow);
    border-left: 5px solid var(--gold);
    transition: all 0.3s ease;
}

.blessing-card:hover {
    transform: translateX(5px);
    box-shadow: 0 6px 20px var(--shadow-hover);
}

.blessing-role {
    font-weight: bold;
    color: var(--pink-medium);
    font-size: 1.1rem;
    margin-bottom: 8px;
}

.blessing-text {
    color: var(--text-dark);
    line-height: 1.8;
}

.blessing-time {
    font-size: 0.85rem;
    color: var(--text-light);
    margin-top: 10px;
    text-align: right;
}

/* ===== 4. 生日愿望 ===== */
.wish-section {
    background: linear-gradient(135deg, #ffeef8 0%, #e3f2fd 100%);
    position: relative;
}

.wish-container {
    max-width: 700px;
    width: 100%;
    position: relative;
    z-index: 10;
}

.wish-input-box {
    background: var(--white);
    padding: 30px;
    border-radius: 20px;
    box-shadow: 0 8px 25px var(--shadow);
    margin-bottom: 30px;
}

.wish-input-box textarea {
    width: 100%;
    padding: 15px;
    border: 2px solid var(--blue-light);
    border-radius: 10px;
    font-family: var(--font-family);
    font-size: 1rem;
    resize: none;
    margin-bottom: 15px;
    transition: all 0.3s ease;
    min-height: 80px;
    max-height: 80px;
    overflow-y: auto;
}

.wish-input-box textarea:focus {
    outline: none;
    border-color: var(--gold);
    box-shadow: 0 0 0 3px rgba(255, 215, 0, 0.2);
}

.wish-btn {
    width: 100%;
    padding: 15px;
    background: linear-gradient(135deg, var(--gold), #ffa500);
    color: var(--white);
    border: none;
    border-radius: 10px;
    font-size: 1.2rem;
    font-weight: bold;
    cursor: pointer;
    transition: all 0.3s ease;
}

.wish-btn:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 25px rgba(255, 215, 0, 0.4);
}

.wish-display {
    background: linear-gradient(135deg, rgba(255, 215, 0, 0.15), rgba(255, 182, 193, 0.15));
    padding: 20px;
    border-radius: 20px;
    box-shadow: 0 8px 30px rgba(255, 215, 0, 0.3), 0 0 0 2px rgba(255, 215, 0, 0.2);
    display: none;
    margin-bottom: 15px;
    position: relative;
    overflow: hidden;
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
}

.wish-display::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle, rgba(255, 215, 0, 0.1) 0%, transparent 70%);
    animation: shimmer 3s ease-in-out infinite;
    -webkit-animation: shimmer 3s ease-in-out infinite;
}

.wish-display p {
    position: relative;
    z-index: 1;
    color: #d4a017 !important;
    font-size: 1.1rem !important;
    text-align: center !important;
    line-height: 1.6 !important;
    margin: 0 !important;
    font-weight: 600;
    text-shadow: 0 2px 4px rgba(255, 215, 0, 0.2);
    word-wrap: break-word;
    overflow-wrap: break-word;
    hyphens: auto;
    -webkit-hyphens: auto;
}

.wish-display p::before {
    content: '✨ ';
    font-size: 1.2rem;
}

.wish-display p::after {
    content: ' ✨';
    font-size: 1.2rem;
}

@-webkit-keyframes shimmer {
    0%, 100% {
        -webkit-transform: translate(0, 0) rotate(0deg);
        transform: translate(0, 0) rotate(0deg);
    }
    50% {
        -webkit-transform: translate(10%, 10%) rotate(180deg);
        transform: translate(10%, 10%) rotate(180deg);
    }
}

@keyframes shimmer {
    0%, 100% {
        -webkit-transform: translate(0, 0) rotate(0deg);
        transform: translate(0, 0) rotate(0deg);
    }
    50% {
        -webkit-transform: translate(10%, 10%) rotate(180deg);
        transform: translate(10%, 10%) rotate(180deg);
    }
}

.wish-canvas {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100vh;
    pointer-events: none;
    z-index: 5;
}

/* ===== 5. 结束页 ===== */
.ending-section {
    background: linear-gradient(135deg, #ffeef8 0%, #e3f2fd 100%);
    color: var(--text-dark);
    position: relative;
    overflow: visible;
    min-height: 0 !important;
    height: auto !important;
    padding: 40px 20px 20px 20px;
    display: block !important;
}

.ending-content {
    max-width: 700px;
    margin: 0 auto;
    text-align: center;
    position: relative;
    z-index: 1;
}

.ending-title {
    font-size: 2.5rem;
    font-weight: bold;
    margin-bottom: 15px;
    color: var(--pink-medium);
    text-shadow: 2px 2px 8px rgba(255, 182, 193, 0.4);
}

.wish-subtitle {
    font-size: 1.1rem;
    color: var(--blue-medium);
    margin-bottom: 30px;
    font-weight: 400;
    opacity: 0.9;
    font-style: italic;
}

.ending-wishes {
    font-size: 1.15rem;
    line-height: 2;
    margin: 40px 0 0 0;
    padding: 30px;
    color: var(--text-dark);
    background: linear-gradient(135deg, rgba(255, 182, 193, 0.1), rgba(135, 206, 235, 0.1));
    border-radius: 20px;
    box-shadow: 0 8px 30px rgba(0, 0, 0, 0.1);
    -webkit-backdrop-filter: blur(10px);
    backdrop-filter: blur(10px);
}

.ending-wishes .wish-line {
    margin: 15px 0;
    opacity: 0;
    -webkit-transform: translateY(20px);
    transform: translateY(20px);
    position: relative;
}

.ending-wishes.animated .wish-line {
    -webkit-animation: fadeInUpSlow 1s ease forwards;
    animation: fadeInUpSlow 1s ease forwards;
}

.ending-wishes .wish-line.highlight {
    font-size: 1.25rem;
    font-weight: bold;
    color: var(--gold);
    text-shadow: 0 0 10px rgba(255, 215, 0, 0.3);
    margin-top: 25px;
}

.ending-wishes.animated .wish-line:nth-child(1) { -webkit-animation-delay: 0.2s; animation-delay: 0.2s; }
.ending-wishes.animated .wish-line:nth-child(2) { -webkit-animation-delay: 0.5s; animation-delay: 0.5s; }
.ending-wishes.animated .wish-line:nth-child(3) { -webkit-animation-delay: 0.8s; animation-delay: 0.8s; }
.ending-wishes.animated .wish-line:nth-child(4) { -webkit-animation-delay: 1.1s; animation-delay: 1.1s; }
.ending-wishes.animated .wish-line:nth-child(5) { -webkit-animation-delay: 1.4s; animation-delay: 1.4s; }
.ending-wishes.animated .wish-line:nth-child(6) { -webkit-animation-delay: 1.7s; animation-delay: 1.7s; }
.ending-wishes.animated .wish-line:nth-child(7) { -webkit-animation-delay: 2s; animation-delay: 2s; }

.family-signature {
    margin: 30px 0 0 0 !important;
    padding: 0 !important;
    font-size: 1.3rem !important;
    color: var(--pink-medium) !important;
    font-weight: bold;
    font-style: italic;
    text-align: center;
    opacity: 0;
}

.ending-wishes.animated .family-signature {
    -webkit-animation: fadeInScale 1s ease forwards 2.5s;
    animation: fadeInScale 1s ease forwards 2.5s;
}

.ending-section .wish-input-box {
    margin-bottom: 15px;
}

.ending-section .wish-display {
    margin-bottom: 15px;
}

.ending-section .wish-btn:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

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

.fireworks-canvas {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100vh;
    pointer-events: none;
    z-index: 0;
}

.back-to-top {
    position: fixed;
    bottom: 30px;
    right: 30px;
    padding: 15px 25px;
    background: var(--gold);
    color: var(--white);
    border: none;
    border-radius: 50px;
    font-size: 1rem;
    font-weight: bold;
    cursor: pointer;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.3);
    transition: all 0.3s ease;
    z-index: 999;
    opacity: 0;
    visibility: hidden;
}

.back-to-top.visible {
    opacity: 1;
    visibility: visible;
}

.back-to-top:hover {
    transform: translateY(-5px);
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.4);
}

/* 分享按钮 */
.share-btn {
    position: fixed;
    bottom: 30px;
    right: 30px;
    padding: 15px 25px;
    background: linear-gradient(135deg, #FF6B9D, #C06C84);
    color: var(--white);
    border: none;
    border-radius: 50px;
    font-size: 1rem;
    font-weight: bold;
    cursor: pointer;
    box-shadow: 0 4px 15px rgba(255, 107, 157, 0.3);
    transition: all 0.3s ease;
    z-index: 999;
    opacity: 0;
    visibility: hidden;
    transform: translateY(10px);
}

.share-btn.visible {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.share-btn:hover {
    transform: translateY(-5px);
    box-shadow: 0 6px 20px rgba(255, 107, 157, 0.5);
}

/* 二维码模态框 */
.qrcode-modal {
    display: none;
    position: fixed;
    z-index: 1000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.7);
    backdrop-filter: blur(5px);
    -webkit-backdrop-filter: blur(5px);
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
}

.qrcode-modal-content {
    position: relative;
    background: linear-gradient(135deg, #ffffff 0%, #f8f9fa 100%);
    margin: 15vh auto;
    padding: 30px 20px;
    border-radius: 20px;
    max-width: 90%;
    width: 400px;
    text-align: center;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.3);
    animation: fadeInScale 0.3s ease;
}

.qrcode-modal-close {
    position: absolute;
    right: 15px;
    top: 10px;
    font-size: 30px;
    font-weight: bold;
    color: #999;
    cursor: pointer;
    transition: color 0.3s ease;
    line-height: 1;
    padding: 5px;
}

.qrcode-modal-close:hover {
    color: #333;
}

.qrcode-title {
    font-size: 1.5rem;
    color: var(--pink-medium);
    margin-bottom: 8px;
    font-weight: bold;
}

.qrcode-desc {
    font-size: 0.95rem;
    color: var(--text-light);
    margin-bottom: 20px;
}

.qrcode-container {
    display: flex;
    justify-content: center;
    align-items: center;
    margin: 20px auto;
    padding: 15px;
    background: white;
    border-radius: 15px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
    max-width: 280px;
}

.qrcode-img {
    width: 100%;
    height: auto;
    max-width: 256px;
    display: block;
    border-radius: 8px;
}

.qrcode-url {
    font-size: 0.85rem;
    color: var(--text-light);
    margin-top: 15px;
    word-break: break-all;
}

.qrcode-tip {
    font-size: 0.85rem;
    color: var(--blue-medium);
    margin-top: 15px;
    padding: 10px;
    background: rgba(135, 206, 235, 0.1);
    border-radius: 10px;
    line-height: 1.5;
}

.native-share-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    margin: 20px auto 10px;
    padding: 12px 30px;
    background: linear-gradient(135deg, #FF6B9D, #C06C84);
    color: white;
    border: none;
    border-radius: 25px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(255, 107, 157, 0.3);
}

.native-share-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(255, 107, 157, 0.4);
}

.native-share-btn:active {
    transform: translateY(0);
}

.share-icon {
    font-size: 1.2rem;
}

/* ===== 照片查看器模态框 ===== */
.photo-modal {
    display: none;
    position: fixed;
    z-index: 2000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.9);
    animation: fadeIn 0.3s ease;
}

.photo-modal.active {
    display: flex;
    justify-content: center;
    align-items: center;
}

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

.modal-content {
    max-width: 90%;
    max-height: 90%;
    object-fit: contain;
    animation: zoomIn 0.3s ease;
}

@keyframes zoomIn {
    from { transform: scale(0.8); }
    to { transform: scale(1); }
}

.modal-close {
    position: absolute;
    top: 20px;
    right: 40px;
    color: var(--white);
    font-size: 40px;
    font-weight: bold;
    cursor: pointer;
    transition: all 0.3s ease;
}

.modal-close:hover {
    color: var(--gold);
    transform: rotate(90deg);
}

.modal-caption {
    position: absolute;
    bottom: 30px;
    left: 50%;
    transform: translateX(-50%);
    color: var(--white);
    font-size: 1.2rem;
    text-align: center;
    background: rgba(0, 0, 0, 0.7);
    padding: 10px 20px;
    border-radius: 10px;
}

/* ===== 响应式设计 ===== */
@media (max-width: 768px) {
    .section-title {
        font-size: 2rem;
    }

    .main-title {
        font-size: 2rem;
    }

    .subtitle {
        font-size: 1rem;
    }

    .birthday-date {
        font-size: 1.2rem;
    }

    .cake-icon {
        font-size: 3.5rem;
    }

    .timeline-container::before {
        left: 20px;
    }

    .timeline-item {
        justify-content: flex-start;
        padding-left: 50px;
    }

    .timeline-item:nth-child(odd) .photo-card,
    .timeline-item:nth-child(even) .photo-card {
        width: 100%;
        margin: 0;
    }

    .timeline-marker {
        left: 20px;
    }

    .photo-card img {
        height: 250px;
    }

    .blessing-form-container {
        padding: 20px;
    }

    .form-title {
        font-size: 1.5rem;
    }

    .ending-title {
        font-size: 2rem;
    }

    .ending-wishes {
        font-size: 1.1rem;
    }

    .back-to-top {
        bottom: 20px;
        right: 20px;
        padding: 12px 20px;
        font-size: 0.9rem;
    }

    .music-toggle {
        width: 50px;
        height: 50px;
        font-size: 1.3rem;
    }

    .modal-close {
        right: 20px;
        font-size: 30px;
    }
}

/* ===== PC 端优化样式 ===== */
@media (min-width: 769px) {
    /* 限制内容最大宽度，避免在大屏幕上过于分散 */
    .welcome-content {
        max-width: 800px;
    }

    .slideshow-container {
        max-width: 900px;
    }

    .ending-content {
        max-width: 800px;
    }

    /* 优化字体大小 */
    .main-title {
        font-size: 3.5rem;
    }

    .section-title {
        font-size: 3rem;
    }

    .subtitle {
        font-size: 1.3rem;
    }

    .section-desc {
        font-size: 1.2rem;
    }

    /* 优化祝福卡片在 PC 端的显示 */
    .blessings-marquee-wrapper {
        max-width: 1200px;
        margin: 0 auto;
    }

    .blessing-card-auto {
        min-width: 350px;
        max-width: 400px;
    }

    /* 优化许愿框 */
    .wish-input-box {
        max-width: 600px;
        margin: 0 auto;
    }

    /* 优化结束语 */
    .ending-wishes {
        font-size: 1.25rem;
        padding: 40px 50px;
    }

    /* 优化照片轮播 */
    .slide img {
        max-height: 600px;
        object-fit: contain;
    }

    /* 优化按钮 */
    .slide-btn {
        width: 50px;
        height: 50px;
        font-size: 2rem;
    }

    .slide-btn:hover {
        transform: scale(1.1);
        background: rgba(255, 182, 193, 0.95);
    }

    /* 优化返回顶部按钮 */
    .back-to-top:hover {
        transform: translateY(-5px);
        box-shadow: 0 8px 20px rgba(255, 215, 0, 0.4);
    }

    /* 优化音乐按钮 */
    .music-toggle:hover {
        transform: scale(1.1);
    }
}

/* ===== 平板设备优化样式 ===== */
@media (min-width: 769px) and (max-width: 1024px) {
    /* 平板设备的中等尺寸优化 */
    .main-title {
        font-size: 3rem;
    }

    .section-title {
        font-size: 2.5rem;
    }

    .subtitle {
        font-size: 1.2rem;
    }

    .section-desc {
        font-size: 1.1rem;
    }

    .slideshow-container {
        max-width: 700px;
    }

    .slide img {
        max-height: 500px;
    }

    .blessing-card-auto {
        min-width: 300px;
        max-width: 350px;
    }

    .ending-wishes {
        font-size: 1.2rem;
        padding: 35px 40px;
    }

    .wish-input-box {
        max-width: 550px;
    }
}

/* ===== 移动端按钮优化 ===== */
@media (max-width: 768px) {
    .share-btn {
        bottom: 90px;
        right: 20px;
        padding: 12px 20px;
        font-size: 0.9rem;
    }

    .back-to-top {
        bottom: 20px;
        right: 20px;
        padding: 12px 20px;
        font-size: 0.9rem;
    }

    .qrcode-modal-content {
        margin: 20vh auto;
        padding: 25px 15px;
        max-width: 85%;
        width: auto;
    }

    .qrcode-title {
        font-size: 1.3rem;
    }

    .qrcode-desc {
        font-size: 0.85rem;
        margin-bottom: 15px;
    }

    .qrcode-container {
        padding: 10px;
        max-width: 240px;
    }

    .qrcode-modal-close {
        font-size: 28px;
        right: 10px;
        top: 8px;
    }

    .qrcode-tip {
        font-size: 0.8rem;
        padding: 8px;
        margin-top: 12px;
    }

    .native-share-btn {
        font-size: 0.9rem;
        padding: 10px 25px;
        margin: 15px auto 8px;
    }

    .share-icon {
        font-size: 1.1rem;
    }
}

/* ===== 大屏幕优化 ===== */
@media (min-width: 1025px) {
    /* 超大屏幕的额外优化 */
    .section {
        padding: 80px 40px;
    }

    .main-title {
        font-size: 4rem;
    }

    .section-title {
        font-size: 3.5rem;
    }

    .slideshow-container {
        max-width: 1000px;
    }

    .slide img {
        max-height: 700px;
    }

    .ending-wishes {
        font-size: 1.3rem;
        padding: 50px 60px;
        max-width: 900px;
        margin: 40px auto 0;
    }
}
