* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

/* 启动界面样式 */
.start-screen {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 9999;
    transition: opacity 0.8s ease, visibility 0.8s ease;
}

.start-screen.hidden {
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
}

.start-content {
    text-align: center;
    animation: fadeInUp 0.8s ease-out;
}

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

.start-icon {
    font-size: 120px;
    margin-bottom: 30px;
    animation: heartBeat 1.5s ease-in-out infinite;
}

@keyframes heartBeat {
    0%, 100% {
        transform: scale(1);
    }
    25% {
        transform: scale(1.1);
    }
    50% {
        transform: scale(1);
    }
}

.start-title {
    font-size: 48px;
    color: white;
    font-weight: 600;
    margin-bottom: 15px;
    text-shadow: 0 2px 20px rgba(0, 0, 0, 0.3);
    letter-spacing: 2px;
}

.start-subtitle {
    font-size: 20px;
    color: rgba(255, 255, 255, 0.9);
    margin-bottom: 50px;
    font-weight: 300;
}

.start-button {
    display: inline-flex;
    align-items: center;
    gap: 12px;
    padding: 18px 45px;
    font-size: 20px;
    font-weight: 600;
    color: #667eea;
    background: white;
    border: none;
    border-radius: 50px;
    cursor: pointer;
    box-shadow: 0 8px 30px rgba(0, 0, 0, 0.3);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    overflow: hidden;
}

.start-button::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 0;
    height: 0;
    border-radius: 50%;
    background: rgba(102, 126, 234, 0.1);
    transform: translate(-50%, -50%);
    transition: width 0.6s, height 0.6s;
}

.start-button:hover::before {
    width: 300px;
    height: 300px;
}

.start-button:hover {
    transform: translateY(-3px) scale(1.05);
    box-shadow: 0 12px 40px rgba(0, 0, 0, 0.4);
}

.start-button:active {
    transform: translateY(-1px) scale(1.02);
}

.button-icon {
    font-size: 18px;
    transition: transform 0.3s;
}

.start-button:hover .button-icon {
    transform: translateX(3px);
}

.button-text {
    position: relative;
    z-index: 1;
}

/* 移动端适配 */
@media (max-width: 768px) {
    .start-icon {
        font-size: 80px;
        margin-bottom: 20px;
    }
    
    .start-title {
        font-size: 32px;
        margin-bottom: 10px;
    }
    
    .start-subtitle {
        font-size: 16px;
        margin-bottom: 40px;
    }
    
    .start-button {
        padding: 15px 35px;
        font-size: 18px;
    }
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'PingFang SC', 'Hiragino Sans GB', 'Microsoft YaHei', sans-serif;
    background: #f5f5f5 url('images/lover.jpg') center/60% no-repeat fixed;
    min-height: 100vh;
    overflow-x: hidden;
    position: relative;
    /* 移动端优化 */
    -webkit-tap-highlight-color: transparent;
    -webkit-touch-callout: none;
    -webkit-user-select: none;
    user-select: none;
}

body::before {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image: 
        repeating-linear-gradient(0deg, rgba(0,0,0,0.03) 0px, rgba(0,0,0,0.03) 1px, transparent 1px, transparent 40px),
        repeating-linear-gradient(90deg, rgba(0,0,0,0.03) 0px, rgba(0,0,0,0.03) 1px, transparent 1px, transparent 40px),
        url('images/lover.jpg');
    background-size: 60%;
    background-position: center;
    background-repeat: no-repeat;
    pointer-events: none;
    z-index: 0;
}

.container {
    position: relative;
    width: 100%;
    min-height: 100vh;
    padding: 40px 20px;
    z-index: 1;
}

.cards-wrapper {
    max-width: 1400px;
    margin: 0 auto;
    position: relative;
    min-height: 800px;
}

.cards-wrapper::before {
    content: '❤️';
    position: fixed;
    left: 50%;
    top: 50%;
    transform: translate(-50%, -50%);
    font-size: 800px;
    opacity: 0.02;
    pointer-events: none;
    z-index: 0;
    filter: grayscale(0.3);
}

.card {
    position: absolute;
    width: 280px;
    background: rgba(255, 255, 255, 0.98);
    backdrop-filter: blur(10px);
    border-radius: 16px;
    padding: 16px;
    box-shadow: 
        0 8px 24px rgba(0, 0, 0, 0.12),
        0 2px 8px rgba(0, 0, 0, 0.08),
        0 0 1px rgba(0, 0, 0, 0.1);
    will-change: transform, left, top, opacity, filter;
    z-index: 10;
    border: 1px solid rgba(0, 0, 0, 0.04);
}

.card:hover {
    transform: translateY(-8px) scale(1.05) !important;
    box-shadow: 
        0 16px 32px rgba(0, 0, 0, 0.16),
        0 4px 16px rgba(0, 0, 0, 0.12),
        0 0 2px rgba(0, 0, 0, 0.1);
    z-index: 100;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1) !important;
}

.card-header {
    display: flex;
    align-items: center;
    margin-bottom: 12px;
    padding-bottom: 12px;
    border-bottom: 1px solid rgba(0, 0, 0, 0.08);
}

.mac-buttons {
    display: flex;
    gap: 6px;
    margin-right: 12px;
}

.mac-btn {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    transition: all 0.2s;
}

.mac-btn.red {
    background: linear-gradient(135deg, #ff5f57 0%, #ff3b30 100%);
    box-shadow: 0 1px 3px rgba(255, 95, 87, 0.4);
}

.mac-btn.yellow {
    background: linear-gradient(135deg, #ffbd2e 0%, #ffa500 100%);
    box-shadow: 0 1px 3px rgba(255, 189, 46, 0.4);
}

.mac-btn.green {
    background: linear-gradient(135deg, #28ca42 0%, #00c853 100%);
    box-shadow: 0 1px 3px rgba(40, 202, 66, 0.4);
}

.card:hover .mac-btn {
    transform: scale(1.1);
}

.card-title {
    font-size: 13px;
    color: #666;
    font-weight: 500;
    flex: 1;
}

.card-body {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    padding: 0;
}

.user-avatar {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    object-fit: cover;
    border: 2px solid rgba(255, 255, 255, 0.8);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
    flex-shrink: 0;
}

.card-content {
    flex: 1;
}

.user-name {
    font-size: 12px;
    color: #888;
    margin-bottom: 6px;
    font-weight: 500;
}

.card-text {
    font-size: 16px;
    line-height: 1.5;
    color: #333;
    font-weight: 500;
}

/* 不同颜色的卡片背景 */
.card.color-1 { background: linear-gradient(135deg, #FFE5E5 0%, #FFF0F0 100%); }
.card.color-2 { background: linear-gradient(135deg, #FFF4E5 0%, #FFF8F0 100%); }
.card.color-3 { background: linear-gradient(135deg, #FFFFE5 0%, #FFFFF0 100%); }
.card.color-4 { background: linear-gradient(135deg, #E5FFE5 0%, #F0FFF0 100%); }
.card.color-5 { background: linear-gradient(135deg, #E5F4FF 0%, #F0F8FF 100%); }
.card.color-6 { background: linear-gradient(135deg, #F0E5FF 0%, #F8F0FF 100%); }
.card.color-7 { background: linear-gradient(135deg, #FFE5F0 0%, #FFF0F8 100%); }
.card.color-8 { background: linear-gradient(135deg, #E5FFFF 0%, #F0FFFF 100%); }

body::after {
    content: '';
    position: fixed;
    bottom: 20px;
    right: 20px;
    padding: 10px 20px;
    background: rgba(255, 255, 255, 0.9);
    border-radius: 20px;
    font-size: 14px;
    color: #666;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    z-index: 1000;
    opacity: 0;
    animation: fadeInTip 1s ease-in-out 2s forwards;
}

@keyframes fadeInTip {
    to {
        opacity: 1;
    }
}

/* 响应式设计 */
@media (max-width: 768px) {
    body {
        overflow-x: hidden;
        -webkit-overflow-scrolling: touch;
        background: #fafafa;
        /* 移动端背景图片优化 */
        background-size: cover;
        background-position: center;
    }
    
    body::before {
        background-size: cover;
        opacity: 0.3;
    }
    
    .container {
        padding: 20px 10px;
        min-height: 100vh;
    }
    
    .cards-wrapper {
        min-height: calc(100vh - 40px);
    }
    
    .cards-wrapper::before {
        font-size: 400px;
        opacity: 0.015;
    }
    
    .card {
        width: 160px;
        padding: 12px;
        border-radius: 12px;
        /* 移动端触摸优化 */
        touch-action: manipulation;
        -webkit-user-select: none;
        user-select: none;
    }
    
    .card-body {
        gap: 8px;
    }
    
    .user-avatar {
        width: 28px;
        height: 28px;
        border-width: 1.5px;
    }
    
    .user-name {
        font-size: 10px;
        margin-bottom: 4px;
    }
    
    .card-text {
        font-size: 13px;
        line-height: 1.4;
    }
    
    /* 移动端触摸反馈 */
    .card:active {
        transform: scale(0.95) !important;
        transition: transform 0.1s ease !important;
    }
    
    body::after {
        bottom: 10px;
        right: 10px;
        padding: 8px 16px;
        font-size: 12px;
        display: none; /* 移动端隐藏提示 */
    }
}

/* 小屏手机优化 */
@media (max-width: 480px) {
    body {
        background: #fafafa;
    }
    
    .container {
        padding: 15px 5px;
    }
    
    .card {
        width: 140px;
        padding: 10px;
        /* 更小屏幕上更好的阴影效果 */
        box-shadow: 
            0 4px 12px rgba(0, 0, 0, 0.08),
            0 1px 4px rgba(0, 0, 0, 0.06);
    }
    
    .card-body {
        gap: 6px;
    }
    
    .card-text {
        font-size: 12px;
        line-height: 1.5;
    }
    
    .user-avatar {
        width: 24px;
        height: 24px;
    }
    
    .user-name {
        font-size: 9px;
    }
    
    .cards-wrapper::before {
        font-size: 300px;
        opacity: 0.01;
    }
    
    .start-icon {
        font-size: 70px !important;
    }
    
    .start-title {
        font-size: 28px !important;
    }
    
    .start-subtitle {
        font-size: 14px !important;
    }
    
    .start-button {
        padding: 12px 30px !important;
        font-size: 16px !important;
    }
}

/* 横屏适配 */
@media (max-width: 768px) and (orientation: landscape) {
    .cards-wrapper::before {
        font-size: 350px;
    }
    
    .container {
        padding: 10px 5px;
    }
    
    .start-content {
        transform: scale(0.8);
    }
}

/* 触摸设备优化 */
@media (hover: none) and (pointer: coarse) {
    .card:active {
        transform: scale(0.95) !important;
        transition: transform 0.1s ease !important;
    }
    
    .mac-btn {
        pointer-events: none;
    }
    
    /* 移除hover效果，使用active代替 */
    .card:hover {
        transform: none !important;
        box-shadow: 
            0 8px 24px rgba(0, 0, 0, 0.12),
            0 2px 8px rgba(0, 0, 0, 0.08),
            0 0 1px rgba(0, 0, 0, 0.1);
    }
    
    .start-button:hover {
        transform: none;
    }
    
    .start-button:active {
        transform: scale(0.95);
    }
}

/* 超大屏手机优化 */
@media (min-width: 481px) and (max-width: 768px) {
    .card {
        width: 180px;
        padding: 14px;
    }
    
    .card-text {
        font-size: 14px;
    }
    
    .user-avatar {
        width: 32px;
        height: 32px;
    }
}

/* iOS Safari优化 */
@supports (-webkit-touch-callout: none) {
    body {
        /* iOS Safari 防止下拉刷新 */
        overscroll-behavior-y: contain;
    }
    
    .container {
        /* iOS Safari 地址栏隐藏时的高度适配 */
        min-height: -webkit-fill-available;
    }
}

/* 安卓Chrome优化 */
@media screen and (max-width: 768px) {
    /* 防止横屏时内容被压缩 */
    @media (orientation: landscape) {
        .card {
            width: 140px;
            padding: 8px;
        }
        
        .card-text {
            font-size: 11px;
        }
    }
}

