/* ==========================================
   💕 Love Story - Final Edition
   艺术总监 + 审查员 优化版
   ========================================== */

@import url('https://fonts.googleapis.com/css2?family=ZCOOL+KuaiLe&family=Noto+Sans+SC:wght@300;400;500;700&display=swap');

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    -webkit-tap-highlight-color: transparent;
    -webkit-user-select: none;
    user-select: none;
}

:root {
    /* 奶油甜心配色 - 增强层次 */
    --peach-pink: #FFB5BA;
    --peach-light: #FFE4E6;
    --lavender: #C8B6FF;
    --lavender-soft: #E8E0FF;
    --cream-white: #FFFBF7;
    --accent-coral: #FF8FAB;
    
    /* 文字色 - 柔紫灰 */
    --text-primary: #5D4E6D;
    --text-secondary: #9D8BA7;
    --text-light: #C4B5C8;
    
    /* 渐变 */
    --gradient-bg: linear-gradient(135deg, var(--cream-white) 0%, var(--peach-light) 50%, var(--lavender-soft) 100%);
    --gradient-card: linear-gradient(180deg, rgba(255,255,255,0.95) 0%, rgba(255,245,248,0.9) 100%);
    --gradient-btn: linear-gradient(135deg, var(--peach-pink) 0%, var(--lavender) 100%);
    
    /* 阴影 */
    --shadow-soft: 0 4px 20px rgba(255, 181, 186, 0.15);
    --shadow-medium: 0 8px 32px rgba(200, 182, 255, 0.2);
    --shadow-glow: 0 0 30px rgba(255, 181, 186, 0.3);
    
    /* 字体 */
    --font-display: 'ZCOOL KuaiLe', cursive;
    --font-body: 'Noto Sans SC', -apple-system, sans-serif;
    
    /* 尺寸 */
    --radius-sm: 14px;
    --radius-md: 20px;
    --radius-lg: 28px;
    --radius-full: 50px;
    
    --safe-bottom: env(safe-area-inset-bottom, 0px);
}

/* ===== 节日主题 ===== */

/* 情人节 (2.14) - 热情红 */
.theme-valentine {
    --peach-pink: #FF6B81;
    --peach-light: #FFE0E6;
    --lavender: #FF8FA3;
    --lavender-soft: #FFF0F3;
    --accent-coral: #FF4D6D;
    --gradient-bg: linear-gradient(135deg, #FFF0F3 0%, #FFE0E6 50%, #FFDDE4 100%);
    --gradient-btn: linear-gradient(135deg, #FF6B81 0%, #FF8FA3 100%);
}

/* 七夕 (农历七月初七，约8月中) - 星空紫 */
.theme-qixi {
    --peach-pink: #A78BFA;
    --peach-light: #EDE9FE;
    --lavender: #8B5CF6;
    --lavender-soft: #F5F3FF;
    --accent-coral: #7C3AED;
    --gradient-bg: linear-gradient(135deg, #F5F3FF 0%, #EDE9FE 50%, #DDD6FE 100%);
    --gradient-btn: linear-gradient(135deg, #A78BFA 0%, #8B5CF6 100%);
}

/* 圣诞节 (12.24-12.25) - 圣诞红绿 */
.theme-christmas {
    --peach-pink: #EF4444;
    --peach-light: #FEE2E2;
    --lavender: #22C55E;
    --lavender-soft: #DCFCE7;
    --accent-coral: #DC2626;
    --gradient-bg: linear-gradient(135deg, #FEF2F2 0%, #FEE2E2 50%, #DCFCE7 100%);
    --gradient-btn: linear-gradient(135deg, #EF4444 0%, #22C55E 100%);
}

/* 元旦/新年 (1.1 & 春节) - 喜庆金红 */
.theme-newyear {
    --peach-pink: #F59E0B;
    --peach-light: #FEF3C7;
    --lavender: #EF4444;
    --lavender-soft: #FEE2E2;
    --accent-coral: #DC2626;
    --gradient-bg: linear-gradient(135deg, #FFFBEB 0%, #FEF3C7 50%, #FEE2E2 100%);
    --gradient-btn: linear-gradient(135deg, #F59E0B 0%, #EF4444 100%);
}

/* 520 (5.20) - 甜蜜粉 */
.theme-520 {
    --peach-pink: #EC4899;
    --peach-light: #FCE7F3;
    --lavender: #F472B6;
    --lavender-soft: #FDF2F8;
    --accent-coral: #DB2777;
    --gradient-bg: linear-gradient(135deg, #FDF2F8 0%, #FCE7F3 50%, #FBCFE8 100%);
    --gradient-btn: linear-gradient(135deg, #EC4899 0%, #F472B6 100%);
}

/* 周年纪念日 - 金色 */
.theme-anniversary {
    --peach-pink: #FBBF24;
    --peach-light: #FEF9C3;
    --lavender: #F59E0B;
    --lavender-soft: #FFFBEB;
    --accent-coral: #D97706;
    --gradient-bg: linear-gradient(135deg, #FFFBEB 0%, #FEF9C3 50%, #FDE68A 100%);
    --gradient-btn: linear-gradient(135deg, #FBBF24 0%, #F59E0B 100%);
}

/* 节日横幅 */
.holiday-banner {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 999;
    padding: 10px 16px;
    background: var(--gradient-btn);
    color: white;
    text-align: center;
    font-family: var(--font-display);
    font-size: 15px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
    animation: banner-slide 0.5s ease;
}

@keyframes banner-slide {
    from { transform: translateY(-100%); }
    to { transform: translateY(0); }
}

/* 有横幅时给页面顶部留空间 */
body:has(.holiday-banner) .section {
    padding-top: 50px;
}

body:has(.holiday-banner) .menu-btn {
    top: 56px;
}

html {
    font-size: 16px;
    -webkit-text-size-adjust: 100%;
}

body {
    font-family: var(--font-body);
    background: var(--gradient-bg);
    background-attachment: fixed;
    color: var(--text-primary);
    min-height: 100vh;
    min-height: 100dvh;
    overflow-x: hidden;
    line-height: 1.6;
}

/* 粒子背景 */
#particles {
    position: fixed;
    inset: 0;
    pointer-events: none;
    z-index: 0;
}

/* 星星闪烁装饰 */
.sparkle {
    position: fixed;
    width: 6px;
    height: 6px;
    background: white;
    clip-path: polygon(50% 0%, 61% 35%, 98% 35%, 68% 57%, 79% 91%, 50% 70%, 21% 91%, 32% 57%, 2% 35%, 39% 35%);
    animation: twinkle 2s ease-in-out infinite;
    pointer-events: none;
    z-index: 1;
}

@keyframes twinkle {
    0%, 100% { opacity: 0.3; transform: scale(0.8); }
    50% { opacity: 1; transform: scale(1.2); }
}

.container {
    max-width: 100%;
    padding: 16px;
    margin: 0 auto;
    position: relative;
    z-index: 2;
}

@media (min-width: 480px) {
    .container { max-width: 440px; padding: 20px; }
}

/* 页面切换 */
.section {
    display: none;
    animation: pop-in 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
}
.section.active { display: block; }

@keyframes pop-in {
    0% { transform: scale(0.9); opacity: 0; }
    100% { transform: scale(1); opacity: 1; }
}

/* ===== Hero Card ===== */
.hero-card {
    position: relative;
    border-radius: var(--radius-lg);
    overflow: hidden;
    margin-bottom: 16px;
}

.hero-bg {
    position: absolute;
    inset: 0;
    background: linear-gradient(135deg, #FFB5BA 0%, #C8B6FF 100%);
}

.hero-bg::before {
    content: '';
    position: absolute;
    inset: 0;
    background: radial-gradient(ellipse at top, rgba(255,255,255,0.4) 0%, transparent 60%);
}

.hero-bg::after {
    content: '';
    position: absolute;
    inset: 0;
    background: 
        radial-gradient(circle at 20% 80%, rgba(255,255,255,0.2) 0%, transparent 40%),
        radial-gradient(circle at 80% 20%, rgba(200,182,255,0.3) 0%, transparent 40%);
}

.hero-content {
    position: relative;
    padding: 24px 16px;
    text-align: center;
    color: white;
}

.avatar-ring {
    width: 56px;
    height: 56px;
    margin: 0 auto 10px;
    border-radius: 50%;
    background: rgba(255,255,255,0.25);
    padding: 3px;
    animation: float 4s ease-in-out infinite;
}

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

.avatar {
    width: 100%;
    height: 100%;
    border-radius: 50%;
    background: white;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 24px;
}

.hero-title {
    font-family: var(--font-display);
    font-size: 22px;
    margin-bottom: 10px;
    text-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

.counter-num {
    font-family: var(--font-display);
    font-size: 48px;
    font-weight: 700;
    line-height: 1;
    text-shadow: 
        0 4px 20px rgba(0,0,0,0.15),
        0 0 40px rgba(255,255,255,0.3);
    animation: counter-glow 3s ease-in-out infinite;
}

@keyframes counter-glow {
    0%, 100% { text-shadow: 0 4px 20px rgba(0,0,0,0.15), 0 0 40px rgba(255,255,255,0.2); }
    50% { text-shadow: 0 4px 20px rgba(0,0,0,0.15), 0 0 60px rgba(255,255,255,0.5); }
}

.counter-label {
    font-size: 13px;
    opacity: 0.95;
    margin-top: 4px;
}

.start-info {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    background: rgba(255,255,255,0.2);
    backdrop-filter: blur(10px);
    padding: 6px 12px;
    border-radius: 20px;
    font-size: 12px;
    margin-top: 10px;
}

.pulse-dot {
    width: 8px;
    height: 8px;
    background: #4ade80;
    border-radius: 50%;
    animation: pulse 2s infinite;
}

@keyframes pulse {
    0%, 100% { opacity: 1; transform: scale(1); }
    50% { opacity: 0.5; transform: scale(1.3); }
}

.ai-greeting {
    margin-top: 16px;
    padding: 10px 18px;
    background: rgba(255,255,255,0.25);
    backdrop-filter: blur(10px);
    border-radius: 20px;
    font-size: 14px;
    color: rgba(255,255,255,0.95);
    font-weight: 500;
    animation: fadeIn 0.5s ease;
}

.hero-love-quote {
    margin-top: 20px;
    padding: 12px 20px;
    background: rgba(255,255,255,0.2);
    backdrop-filter: blur(10px);
    border-radius: 16px;
    display: flex;
    align-items: center;
    gap: 8px;
    animation: fadeIn 0.5s ease;
}

.hero-love-quote .love-text {
    flex: 1;
    margin: 0;
    font-size: 13px;
    line-height: 1.5;
    background: none;
    -webkit-background-clip: unset;
    -webkit-text-fill-color: unset;
    background-clip: unset;
    color: rgba(255,255,255,0.95);
    text-align: center;
}

.hero-love-quote .refresh-btn {
    background: rgba(255,255,255,0.2);
    border: none;
    border-radius: 50%;
    width: 28px;
    height: 28px;
    font-size: 14px;
    cursor: pointer;
    flex-shrink: 0;
    transition: transform 0.3s;
}

.hero-love-quote .refresh-btn:active {
    transform: rotate(180deg);
}

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

/* ===== Glass Card ===== */
.card {
    background: var(--gradient-card);
    backdrop-filter: blur(20px) saturate(180%);
    -webkit-backdrop-filter: blur(20px) saturate(180%);
    border-radius: var(--radius-lg);
    border: 2px solid rgba(255, 181, 186, 0.25);
    box-shadow: var(--shadow-soft), inset 0 0 0 1px rgba(255,255,255,0.5);
    padding: 14px;
    margin-bottom: 10px;
    position: relative;
    overflow: hidden;
    transition: transform 0.3s, box-shadow 0.3s;
}

/* 首页双列布局 */
.home-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px;
}

.home-grid .card {
    margin-bottom: 0;
}

.card:active {
    transform: scale(0.97);
    box-shadow: var(--shadow-soft);
}

@media (hover: hover) {
    .card:hover {
        transform: translateY(-2px);
        box-shadow: var(--shadow-medium);
        border-color: rgba(255, 181, 186, 0.4);
    }
}

.card-header {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 8px;
}

.card-icon { font-size: 18px; }

.card-title {
    flex: 1;
    font-family: var(--font-display);
    font-size: 13px;
    color: var(--text-secondary);
}

.refresh-btn {
    width: 28px;
    height: 28px;
    border: none;
    background: var(--peach-light);
    border-radius: 50%;
    font-size: 14px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: transform 0.3s;
}

.refresh-btn:active {
    animation: jelly 0.3s ease;
}

@keyframes jelly {
    0% { transform: scale(1); }
    30% { transform: scale(0.9, 1.1); }
    60% { transform: scale(1.1, 0.9); }
    100% { transform: scale(1); }
}

.love-text {
    font-family: var(--font-display);
    font-size: 14px;
    line-height: 1.6;
    letter-spacing: 0.3px;
    background: linear-gradient(135deg, var(--text-primary) 0%, #7D6B8D 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

/* ===== Weather ===== */
.weather-card {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    gap: 6px;
}

.weather-icon { font-size: 32px; }
.weather-info { width: 100%; }

.weather-temp {
    font-family: var(--font-display);
    font-size: 24px;
    color: var(--text-primary);
}

.weather-desc {
    font-size: 11px;
    color: var(--text-secondary);
}

.weather-tip {
    font-size: 12px;
    color: var(--accent-coral);
    margin-top: 4px;
    font-weight: 500;
}

/* ===== Quick Grid ===== */
.quick-grid {
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    gap: 8px;
    margin-top: 10px;
}

.quick-item {
    background: var(--gradient-card);
    backdrop-filter: blur(10px);
    border: 2px solid rgba(255,255,255,0.5);
    border-radius: var(--radius-md);
    padding: 10px 6px 8px;
    min-height: 60px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    cursor: pointer;
    transition: transform 0.2s cubic-bezier(0.34, 1.56, 0.64, 1);
    box-shadow: var(--shadow-soft);
}

.quick-item:active {
    animation: jelly 0.3s ease;
}

.quick-icon {
    font-size: 22px;
    display: block;
    margin-bottom: 4px;
}

.quick-label {
    font-size: 11px;
    color: var(--text-secondary);
    font-weight: 500;
}

/* ===== Section Header ===== */
.section-header {
    text-align: center;
    margin-bottom: 20px;
}

.section-header h2 {
    font-family: var(--font-display);
    font-size: 22px;
    color: var(--text-primary);
}

.subtitle {
    font-size: 13px;
    color: var(--text-light);
    margin-top: 4px;
}

/* ===== Timeline ===== */
.timeline {
    position: relative;
    padding-left: 28px;
}

.timeline::before {
    content: '';
    position: absolute;
    left: 8px;
    top: 0;
    bottom: 0;
    width: 3px;
    background: linear-gradient(var(--peach-pink), var(--lavender));
    border-radius: 3px;
}

.timeline-item {
    position: relative;
    margin-bottom: 18px;
    opacity: 0;
    animation: slide-in 0.5s ease-out forwards;
}

.timeline-item:nth-child(1) { animation-delay: 0.1s; }
.timeline-item:nth-child(2) { animation-delay: 0.2s; }
.timeline-item:nth-child(3) { animation-delay: 0.3s; }
.timeline-item:nth-child(4) { animation-delay: 0.4s; }
.timeline-item:nth-child(5) { animation-delay: 0.5s; }

@keyframes slide-in {
    from { opacity: 0; transform: translateX(-20px); }
    to { opacity: 1; transform: translateX(0); }
}

.timeline-item::before {
    content: '';
    position: absolute;
    left: -24px;
    top: 18px;
    width: 14px;
    height: 14px;
    background: var(--peach-pink);
    border-radius: 50%;
    border: 3px solid white;
    box-shadow: 0 2px 8px rgba(255, 181, 186, 0.4);
}

.timeline-item::after {
    content: '';
    position: absolute;
    left: -28px;
    top: 14px;
    width: 22px;
    height: 22px;
    background: rgba(255, 181, 186, 0.3);
    border-radius: 50%;
    animation: timeline-pulse 2s ease-in-out infinite;
    z-index: -1;
}

@keyframes timeline-pulse {
    0%, 100% { transform: scale(1); opacity: 0.5; }
    50% { transform: scale(1.4); opacity: 0; }
}

.timeline-card {
    background: var(--gradient-card);
    backdrop-filter: blur(10px);
    border-radius: var(--radius-md);
    padding: 16px;
    border: 2px solid rgba(255, 181, 186, 0.2);
    box-shadow: var(--shadow-soft);
}

.timeline-date {
    display: inline-block;
    font-size: 11px;
    color: white;
    background: var(--gradient-btn);
    padding: 4px 12px;
    border-radius: 12px;
    margin-bottom: 10px;
    font-weight: 500;
}

.timeline-title {
    font-family: var(--font-display);
    font-size: 16px;
    margin-bottom: 6px;
}

.timeline-desc {
    font-size: 13px;
    color: var(--text-secondary);
    line-height: 1.6;
}

/* ===== Map ===== */
.map-card {
    background: var(--gradient-card);
    backdrop-filter: blur(10px);
    border-radius: var(--radius-lg);
    padding: 18px;
    margin-bottom: 18px;
    box-shadow: var(--shadow-soft);
    border: 2px solid rgba(255, 181, 186, 0.2);
}

.china-map {
    min-height: 120px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.province-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    justify-content: center;
    padding: 16px 0;
}

.province-tag {
    background: var(--gradient-btn);
    color: white;
    padding: 8px 16px;
    border-radius: var(--radius-full);
    font-size: 13px;
    font-weight: 500;
    box-shadow: 0 2px 10px rgba(255, 181, 186, 0.3);
}

.map-stats {
    display: flex;
    justify-content: center;
    gap: 40px;
    margin-top: 14px;
    padding-top: 14px;
    border-top: 1px solid rgba(255, 181, 186, 0.2);
}

.stat-num {
    font-family: var(--font-display);
    font-size: 32px;
    background: var(--gradient-btn);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.stat-label {
    font-size: 12px;
    color: var(--text-light);
}

/* ===== Places ===== */
.places-list {
    display: flex;
    flex-direction: column;
    gap: 14px;
}

.place-card {
    display: flex;
    gap: 14px;
    background: var(--gradient-card);
    backdrop-filter: blur(10px);
    border-radius: var(--radius-md);
    padding: 14px;
    border: 2px solid rgba(255, 181, 186, 0.2);
    box-shadow: var(--shadow-soft);
    cursor: pointer;
    transition: transform 0.2s;
}

.place-card:active {
    transform: scale(0.98) translateX(4px);
}

.place-thumb {
    width: 64px;
    height: 64px;
    border-radius: var(--radius-sm);
    object-fit: cover;
}

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

.place-name {
    font-family: var(--font-display);
    font-size: 15px;
    margin-bottom: 4px;
}

.place-location {
    font-size: 12px;
    color: var(--text-light);
}

.place-preview {
    font-size: 12px;
    color: var(--text-secondary);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    margin-top: 4px;
}

/* ===== Wishlist ===== */
.wishlist {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.wish-item {
    display: flex;
    align-items: center;
    gap: 12px;
    background: var(--gradient-card);
    backdrop-filter: blur(10px);
    border-radius: var(--radius-md);
    padding: 14px 16px;
    border: 2px solid rgba(255, 181, 186, 0.2);
    box-shadow: var(--shadow-soft);
    transition: all 0.2s;
}

.wish-item.wish-selected {
    background: rgba(255, 181, 186, 0.3);
    border-color: var(--peach-pink);
}

.wish-check {
    width: 26px;
    height: 26px;
    border: 2px solid var(--peach-light);
    border-radius: 8px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 14px;
    transition: all 0.2s;
    flex-shrink: 0;
}

.wish-check.done {
    background: var(--peach-pink);
    border-color: var(--peach-pink);
    color: white;
}

.wish-text {
    flex: 1;
    font-size: 14px;
    color: var(--text-primary);
}

.wish-text.done {
    text-decoration: line-through;
    color: var(--text-light);
}

.wish-toolbar {
    display: flex;
    gap: 10px;
    margin-bottom: 14px;
}

/* ===== Diary ===== */
.diary-input-area {
    margin-bottom: 16px;
}

.diary-textarea {
    width: 100%;
    min-height: 100px;
    padding: 14px;
    border: 2px solid rgba(255, 181, 186, 0.3);
    border-radius: var(--radius-md);
    font-family: var(--font-body);
    font-size: 14px;
    resize: none;
    outline: none;
    background: rgba(255,255,255,0.8);
    color: var(--text-primary);
}

.diary-textarea:focus {
    border-color: var(--peach-pink);
}

.diary-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.diary-entry {
    background: var(--gradient-card);
    backdrop-filter: blur(10px);
    border-radius: var(--radius-md);
    padding: 16px;
    border: 2px solid rgba(255, 181, 186, 0.2);
    box-shadow: var(--shadow-soft);
}

.diary-date {
    font-size: 12px;
    color: var(--accent-coral);
    margin-bottom: 8px;
    font-weight: 500;
}

.diary-content {
    font-size: 14px;
    line-height: 1.7;
    color: var(--text-secondary);
}

/* ===== Letter Page ===== */
.letter-container {
    position: relative;
    background: var(--gradient-card);
    border-radius: var(--radius-lg);
    padding: 24px 20px;
    margin-top: 20px;
    border: 2px solid rgba(255, 181, 186, 0.2);
    box-shadow: var(--shadow-medium);
}

.letter-container::before {
    content: '✉️';
    position: absolute;
    top: -12px;
    left: 50%;
    transform: translateX(-50%);
    font-size: 24px;
    background: var(--cream-white);
    padding: 0 12px;
}

.letter-title {
    font-family: var(--font-display);
    font-size: 20px;
    text-align: center;
    margin-bottom: 20px;
    color: var(--text-primary);
}

.letter-content {
    font-size: 15px;
    line-height: 2;
    color: var(--text-secondary);
    white-space: pre-wrap;
}

.letter-signature {
    text-align: right;
    margin-top: 24px;
    font-family: var(--font-display);
    color: var(--text-primary);
}

/* ===== Gallery ===== */
.gallery-masonry {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 8px;
}

.gallery-item {
    aspect-ratio: 1;
    border-radius: var(--radius-sm);
    overflow: hidden;
    cursor: pointer;
    transition: transform 0.2s;
}

.gallery-item:active {
    transform: scale(0.95);
}

.gallery-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* ===== Settings ===== */
.settings-section {
    margin-bottom: 20px;
}

.settings-title {
    font-family: var(--font-display);
    font-size: 16px;
    margin-bottom: 12px;
    color: var(--text-primary);
}

.settings-item {
    background: var(--gradient-card);
    border-radius: var(--radius-md);
    padding: 14px 16px;
    margin-bottom: 10px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    border: 2px solid rgba(255, 181, 186, 0.2);
}

.settings-label {
    font-size: 14px;
    color: var(--text-primary);
}

.settings-desc {
    font-size: 12px;
    color: var(--text-light);
    margin-top: 2px;
}

/* ===== Buttons ===== */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 14px 28px;
    border: none;
    border-radius: var(--radius-full);
    font-family: var(--font-body);
    font-size: 15px;
    font-weight: 500;
    cursor: pointer;
    position: relative;
    overflow: hidden;
    transition: transform 0.2s;
}

.btn-primary {
    background: var(--gradient-btn);
    color: white;
    box-shadow: 0 4px 15px rgba(255, 181, 186, 0.4), inset 0 1px 1px rgba(255,255,255,0.3);
}

.btn-primary:active {
    animation: jelly 0.3s ease;
}

.btn-secondary {
    background: rgba(255,255,255,0.8);
    color: var(--text-primary);
    border: 2px solid rgba(255, 181, 186, 0.3);
}

.btn-small {
    padding: 10px 20px;
    font-size: 13px;
}

/* ===== Tab Bar ===== */
.tab-bar {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    height: calc(68px + var(--safe-bottom));
    background: rgba(255, 251, 247, 0.95);
    backdrop-filter: blur(20px) saturate(180%);
    -webkit-backdrop-filter: blur(20px) saturate(180%);
    display: flex;
    justify-content: space-around;
    align-items: flex-start;
    padding-top: 8px;
    box-shadow: 0 -4px 20px rgba(0,0,0,0.06);
    border-top: 1px solid rgba(255, 181, 186, 0.2);
    z-index: 100;
}

.tab {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 2px;
    padding: 4px 10px;
    background: none;
    border: none;
    cursor: pointer;
    color: var(--text-light);
    transition: all 0.2s;
    position: relative;
}

.tab.active { 
    color: var(--accent-coral);
    transform: translateY(-2px);
}

.tab.active::after {
    content: '';
    position: absolute;
    bottom: -4px;
    width: 4px;
    height: 4px;
    background: var(--accent-coral);
    border-radius: 50%;
}

.tab-icon {
    font-size: 22px;
    transition: transform 0.2s;
}

.tab.active .tab-icon {
    transform: scale(1.1);
}

.tab span:last-child {
    font-size: 10px;
    font-weight: 500;
}

/* ===== Lightbox ===== */
.lightbox {
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,0.95);
    z-index: 1000;
    display: none;
    align-items: center;
    justify-content: center;
}
.lightbox.active { display: flex; }

.lightbox img {
    max-width: 95%;
    max-height: 85%;
    border-radius: var(--radius-md);
    box-shadow: 0 20px 60px rgba(0,0,0,0.5);
}

.lightbox-close {
    position: absolute;
    top: 20px;
    right: 20px;
    width: 44px;
    height: 44px;
    background: rgba(255,255,255,0.15);
    border: none;
    border-radius: 50%;
    color: white;
    font-size: 24px;
    cursor: pointer;
}

.lightbox-nav {
    position: absolute;
    bottom: 30px;
    display: flex;
    gap: 20px;
}

.lightbox-nav button {
    width: 50px;
    height: 50px;
    background: rgba(255,255,255,0.15);
    border: none;
    border-radius: 50%;
    color: white;
    font-size: 22px;
    cursor: pointer;
}

/* ===== Modal ===== */
.modal {
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,0.4);
    z-index: 999;
    display: none;
    align-items: flex-end;
}
.modal.active { display: flex; }

.modal-content {
    background: var(--cream-white);
    width: 100%;
    max-height: 80vh;
    border-radius: var(--radius-lg) var(--radius-lg) 0 0;
    overflow-y: auto;
    position: relative;
}

.modal-close {
    position: absolute;
    top: 14px;
    right: 14px;
    width: 36px;
    height: 36px;
    background: var(--peach-light);
    border: none;
    border-radius: 50%;
    font-size: 18px;
    cursor: pointer;
    z-index: 10;
    color: var(--text-primary);
}

/* ===== Empty State ===== */
.empty-state {
    text-align: center;
    padding: 40px 20px;
    color: var(--text-light);
    font-size: 14px;
}

/* ===== Responsive ===== */
@media (max-width: 360px) {
    .counter-num { font-size: 52px; }
    .hero-content { padding: 28px 16px; }
    .quick-grid { gap: 8px; }
    .quick-item { padding: 12px 6px; }
    .quick-icon { font-size: 24px; }
    .tab { padding: 4px 8px; }
    .tab-icon { font-size: 20px; }
}

@media (min-width: 480px) {
    .counter-num { font-size: 72px; }
    .hero-content { padding: 44px 28px; }
    .gallery-masonry { gap: 10px; }
}

/* 减少动画 */
@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after {
        animation-duration: 0.01ms !important;
        transition-duration: 0.01ms !important;
    }
}

/* ===== 抽屉菜单 ===== */
.menu-btn {
    position: fixed;
    top: 16px;
    right: 16px;
    z-index: 1000;
    width: 48px;
    height: 48px;
    border: none;
    border-radius: 50%;
    background: var(--gradient-btn);
    color: white;
    font-size: 22px;
    cursor: pointer;
    box-shadow: var(--shadow-medium);
    transition: transform 0.2s, box-shadow 0.2s;
}

.menu-btn:hover {
    transform: scale(1.08) rotate(5deg);
    box-shadow: 0 0 35px rgba(255, 181, 186, 0.5);
}

.menu-btn:active {
    transform: scale(0.95);
}

.drawer-overlay {
    position: fixed;
    inset: 0;
    z-index: 1001;
    background: rgba(93, 78, 109, 0.4);
    backdrop-filter: blur(4px);
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.35s ease-out, visibility 0.35s;
}

.drawer-overlay.active {
    opacity: 1;
    visibility: visible;
}

.drawer {
    position: fixed;
    top: 0;
    right: -280px;
    z-index: 1002;
    width: 280px;
    height: 100%;
    background: linear-gradient(180deg, 
        rgba(255,251,247,0.98) 0%, 
        rgba(255,228,230,0.95) 50%,
        rgba(232,224,255,0.95) 100%);
    backdrop-filter: blur(20px) saturate(180%);
    -webkit-backdrop-filter: blur(20px) saturate(180%);
    box-shadow: -8px 0 40px rgba(200,182,255,0.3);
    transition: right 0.35s cubic-bezier(0.32, 0.72, 0, 1);
    display: flex;
    flex-direction: column;
}

.drawer.active {
    right: 0;
}

.drawer-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 24px 20px;
    background: linear-gradient(135deg, 
        rgba(255,181,186,0.15) 0%, 
        rgba(200,182,255,0.15) 100%);
    border-bottom: 1px solid rgba(255,181,186,0.2);
    font-family: var(--font-display);
    font-size: 18px;
    color: var(--text-primary);
}

.drawer-close {
    width: 36px;
    height: 36px;
    border: none;
    border-radius: 50%;
    background: var(--peach-light);
    color: var(--text-secondary);
    font-size: 20px;
    cursor: pointer;
    transition: background 0.2s;
}

.drawer-close:hover {
    background: var(--peach-pink);
    color: white;
}

.drawer-items {
    flex: 1;
    padding: 12px;
    overflow-y: auto;
}

.drawer-item {
    display: flex;
    align-items: center;
    gap: 14px;
    width: 100%;
    padding: 16px 18px;
    margin-bottom: 8px;
    border: none;
    border-radius: var(--radius-md);
    background: transparent;
    color: var(--text-secondary);
    font-family: var(--font-body);
    font-size: 15px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.25s cubic-bezier(0.34, 1.56, 0.64, 1);
    text-align: left;
    position: relative;
    overflow: hidden;
}

.drawer-item::before {
    content: '';
    position: absolute;
    left: 0;
    top: 50%;
    transform: translateY(-50%);
    width: 3px;
    height: 0;
    background: var(--gradient-btn);
    border-radius: 2px;
    transition: height 0.25s ease;
}

.drawer-item:hover::before,
.drawer-item.active::before {
    height: 60%;
}

.drawer-item:hover {
    background: rgba(255, 181, 186, 0.12);
    color: var(--text-primary);
    transform: translateX(4px);
}

.drawer-item.active {
    background: var(--gradient-btn);
    color: white;
    transform: translateX(4px);
    box-shadow: 0 4px 15px rgba(255, 181, 186, 0.35);
}

.drawer-icon {
    font-size: 20px;
}
