/* 全局样式变量 */
:root {
    --primary-color: rgba(255, 255, 255, 0.9);
    --secondary-color: rgba(255, 255, 255, 0.7);
    --accent-color: rgba(255, 255, 255, 0.5);
    --background-color: #000;
    --card-background: rgba(255, 255, 255, 0.1);
    --text-color: #fff;
    --text-secondary: rgba(255, 255, 255, 0.7);
    --border-color: rgba(255, 255, 255, 0.2);
    --hover-color: rgba(255, 255, 255, 0.3);
    --error-color: #ff4444;
    --success-color: #00C851;
    --shadow-sm: 0 2px 4px rgba(0, 0, 0, 0.2);
    --shadow-md: 0 4px 6px rgba(0, 0, 0, 0.3);
    --shadow-lg: 0 8px 15px rgba(0, 0, 0, 0.4);
    --gradient-primary: linear-gradient(135deg, rgba(255, 255, 255, 0.1), rgba(255, 255, 255, 0.05));
    --gradient-accent: linear-gradient(135deg, rgba(255, 255, 255, 0.2), rgba(255, 255, 255, 0.1));
}

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

body {
    font-family: 'SF Pro Display', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    line-height: 1.6;
    color: var(--text-color);
    background-color: var(--background-color);
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    position: relative;
    overflow-x: hidden;
}

/* 背景样式 */
.background-container {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
    background-color: #000;
}

.background-image {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-size: cover;
    background-position: center;
    opacity: 0;
    transition: opacity 1s ease-in-out;
    transform: scale(1.05);
}

.background-image.active {
    opacity: 1;
}

.background-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(
        rgba(0, 0, 0, 0.3),
        rgba(0, 0, 0, 0.5)
    );
    z-index: 1;
    pointer-events: none;
}

/* 顶部样式 */
.header {
    text-align: center;
    padding: 3rem 2rem;
    color: white;
    position: relative;
    overflow: hidden;
    background: rgba(0, 0, 0, 0.3);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border-bottom: 1px solid var(--border-color);
}

.logo {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 1rem;
    position: relative;
}

.logo h1 {
    font-size: 2.5rem;
    font-weight: 600;
    letter-spacing: 1px;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
}

.subtitle {
    margin-top: 1rem;
    opacity: 0.9;
    font-size: 1.2rem;
    font-weight: 300;
    letter-spacing: 0.5px;
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.3);
}

/* 主要内容区样式 */
.main-content {
    max-width: 1200px;
    margin: 2rem auto;
    padding: 2rem;
    flex: 1;
    position: relative;
    z-index: 1;
}

/* 上传区域样式 */
.upload-area {
    background: rgba(255, 255, 255, 0.1);
    border: 2px dashed rgba(255, 255, 255, 0.3);
    border-radius: 15px;
    padding: 40px;
    text-align: center;
    cursor: pointer;
    transition: all 0.3s ease;
    backdrop-filter: blur(10px);
    margin: 20px auto;
    max-width: 600px;
}

.upload-area:hover {
    background: rgba(255, 255, 255, 0.15);
    border-color: rgba(255, 255, 255, 0.5);
}

.upload-area.drag-over {
    background: rgba(255, 255, 255, 0.2);
    border-color: rgba(255, 255, 255, 0.8);
    transform: scale(1.02);
}

.upload-icon {
    font-size: 48px;
    color: rgba(255, 255, 255, 0.8);
    margin-bottom: 20px;
}

.upload-text h3 {
    color: rgba(255, 255, 255, 0.9);
    font-size: 24px;
    margin: 0 0 10px;
}

.upload-text p {
    color: rgba(255, 255, 255, 0.7);
    font-size: 16px;
    margin: 0;
}

/* 文件列表样式 */
.files-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 20px;
    padding: 20px;
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
}

.file-card {
    background: rgba(255, 255, 255, 0.1);
    border-radius: 10px;
    overflow: hidden;
    backdrop-filter: blur(10px);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    height: 100%;
    display: flex;
    flex-direction: column;
}

.file-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 12px rgba(0, 0, 0, 0.2);
}

.preview-container {
    position: relative;
    width: 100%;
    padding-top: 75%; /* 4:3 宽高比 */
    background-size: cover;
    background-position: center;
    overflow: hidden;
}

.preview-img {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
    cursor: pointer;
}

.preview-img:hover {
    transform: scale(1.05);
}

.preview-video {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.file-type-badge {
    position: absolute;
    top: 10px;
    left: 10px;
    background: rgba(0, 0, 0, 0.5);
    color: white;
    padding: 4px 8px;
    border-radius: 4px;
    font-size: 0.8rem;
    backdrop-filter: blur(5px);
    -webkit-backdrop-filter: blur(5px);
}

.file-info {
    padding: 1rem;
}

.file-name {
    color: var(--text-color);
    font-size: 1rem;
    margin-bottom: 0.5rem;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.file-size {
    color: var(--text-secondary);
    font-size: 0.9rem;
}

.file-actions {
    display: flex;
    gap: 0.5rem;
    padding: 1rem;
    border-top: 1px solid var(--border-color);
}

.action-btn {
    flex: 1;
    padding: 0.5rem;
    border: 1px solid var(--border-color);
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.1);
    color: var(--text-color);
    cursor: pointer;
    transition: all 0.3s ease;
    backdrop-filter: blur(5px);
    -webkit-backdrop-filter: blur(5px);
}

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

.fade-in {
    animation: fadeIn 0.5s ease forwards;
}

.fade-out {
    animation: fadeOut 0.3s ease forwards;
}

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

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

/* 存储空间信息 */
.storage-info {
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border-radius: 20px;
    padding: 2rem;
    margin-top: 2rem;
    box-shadow: var(--shadow-lg);
    border: 1px solid var(--border-color);
}

.storage-bar {
    height: 8px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 4px;
    overflow: hidden;
    margin: 1rem 0;
}

.storage-used {
    height: 100%;
    background: var(--gradient-primary);
    border-radius: 4px;
    transition: width 0.3s ease;
}

/* 页脚样式 */
.footer {
    background: rgba(0, 0, 0, 0.3);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    padding: 2rem;
    margin-top: 2rem;
    border-top: 1px solid var(--border-color);
}

.footer-content {
    max-width: 1200px;
    margin: 0 auto;
    text-align: center;
}

.format-tag {
    display: inline-block;
    padding: 0.5rem 1rem;
    margin: 0.25rem;
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    color: var(--text-color);
    font-size: 0.9rem;
    backdrop-filter: blur(5px);
    -webkit-backdrop-filter: blur(5px);
    transition: all 0.3s ease;
}

.format-tag:hover {
    background: rgba(255, 255, 255, 0.2);
    transform: translateY(-2px);
}

/* 动画效果 */
@keyframes float {
    0%, 100% {
        transform: translateY(0);
    }
    50% {
        transform: translateY(-10px);
    }
}

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

/* 存储头部样式 */
.storage-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1rem;
}

.storage-header h3 {
    font-size: 1.2rem;
    font-weight: 600;
    color: var(--text-color);
}

.storage-total {
    color: var(--text-secondary);
    font-size: 0.9rem;
}

/* 底部格式标签样式 */
.footer-title {
    font-weight: 600;
    color: var(--text-color);
    margin-bottom: 1rem;
}

.footer-formats {
    display: flex;
    gap: 0.5rem;
    justify-content: center;
    flex-wrap: wrap;
    margin: 1rem 0;
}

.footer-limit {
    color: var(--text-secondary);
    font-size: 0.9rem;
    margin-top: 1rem;
}

/* 美化滚动条 */
.files-area::-webkit-scrollbar {
    height: 8px;
}

.files-area::-webkit-scrollbar-track {
    background: var(--background-color);
    border-radius: 4px;
}

.files-area::-webkit-scrollbar-thumb {
    background: var(--border-color);
    border-radius: 4px;
    transition: all 0.3s ease;
}

.files-area::-webkit-scrollbar-thumb:hover {
    background: var(--text-secondary);
}

/* 添加滚动提示 */
.files-area::after {
    content: '';
    position: absolute;
    right: 0;
    top: 0;
    bottom: 0;
    width: 40px;
    background: linear-gradient(to right, transparent, var(--card-background));
    pointer-events: none;
    opacity: 0.8;
    z-index: 1;
}

/* 图片预览模态框 */
.image-preview-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.9);
    display: none;
    justify-content: center;
    align-items: center;
    z-index: 1000;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.image-preview-modal.active {
    display: flex;
    opacity: 1;
}

.modal-image-container {
    position: relative;
    max-width: 90%;
    max-height: 90vh;
    margin: auto;
}

.modal-image {
    max-width: 100%;
    max-height: 90vh;
    object-fit: contain;
    border-radius: 4px;
    box-shadow: 0 0 20px rgba(0, 0, 0, 0.3);
    transition: transform 0.3s ease;
}

.modal-close {
    position: absolute;
    top: 20px;
    right: 20px;
    width: 40px;
    height: 40px;
    background: rgba(0, 0, 0, 0.5);
    border: none;
    border-radius: 50%;
    color: white;
    font-size: 24px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
    z-index: 1001;
}

.modal-close:hover {
    background: rgba(0, 0, 0, 0.8);
    transform: scale(1.1);
}

.image-counter {
    position: absolute;
    bottom: 20px;
    left: 50%;
    transform: translateX(-50%);
    background: rgba(0, 0, 0, 0.5);
    color: white;
    padding: 8px 16px;
    border-radius: 20px;
    font-size: 14px;
    z-index: 1001;
}

.modal-nav {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    width: 50px;
    height: 50px;
    background: rgba(0, 0, 0, 0.5);
    border: none;
    border-radius: 50%;
    color: white;
    font-size: 24px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
    z-index: 1001;
}

.modal-nav:hover {
    background: rgba(0, 0, 0, 0.8);
    transform: translateY(-50%) scale(1.1);
}

.modal-prev {
    left: 20px;
}

.modal-next {
    right: 20px;
}

/* 缩放提示 */
.preview-img {
    cursor: zoom-in;
}

/* 添加图片加载动画 */
@keyframes imageLoading {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

.modal-image.loading {
    opacity: 0.5;
}

/* 修复文件列表区域的样式 */
.files-area {
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border-radius: 20px;
    padding: 2rem;
    margin-bottom: 2rem;
    box-shadow: var(--shadow-lg);
    border: 1px solid var(--border-color);
}

.files-area h2 {
    color: var(--text-color);
    font-size: 1.5rem;
    font-weight: 600;
    margin-bottom: 1.5rem;
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.3);
}

/* 加载提示样式 */
.loading-indicator {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background: rgba(0, 0, 0, 0.8);
    padding: 20px 40px;
    border-radius: 15px;
    display: none;
    flex-direction: column;
    align-items: center;
    gap: 15px;
    color: white;
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    z-index: 1000;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.3);
}

.loading-indicator .spinner {
    width: 40px;
    height: 40px;
    border: 4px solid rgba(255, 255, 255, 0.3);
    border-top: 4px solid white;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* 记忆创造者展示区样式 */
.featured-photos {
    margin: 2rem auto;
    padding: 2rem;
    background: rgba(0, 0, 0, 0.3);
    border-radius: 15px;
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    max-width: 1200px;
}

.featured-photos h2 {
    color: var(--text-color);
    font-size: 2rem;
    margin-bottom: 2rem;
    text-align: center;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
    position: relative;
    display: inline-block;
    left: 50%;
    transform: translateX(-50%);
    padding-bottom: 0.5rem;
}

.featured-photos h2::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 2px;
    background: linear-gradient(90deg, 
        transparent 0%, 
        rgba(255, 255, 255, 0.8) 50%, 
        transparent 100%
    );
}

.photo-grid {
    display: flex;
    justify-content: center;
    gap: 1.5rem;
    padding: 1rem;
    margin: 0 auto;
    flex-wrap: nowrap;
}

.photo-item {
    position: relative;
    border-radius: 12px;
    overflow: hidden;
    width: 160px;
    height: 160px;
    cursor: pointer;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
    flex-shrink: 0;
}

.photo-item:hover {
    transform: translateY(-5px) scale(1.02);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.3);
}

.photo-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.photo-item:hover img {
    transform: scale(1.1);
}

.photo-caption {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    padding: 1rem 0.5rem;
    background: linear-gradient(transparent, rgba(0, 0, 0, 0.8));
    color: white;
    font-size: 0.85rem;
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 0.3s ease, transform 0.3s ease;
    text-align: center;
    font-weight: 500;
    letter-spacing: 0.5px;
}

.photo-item:hover .photo-caption {
    opacity: 1;
    transform: translateY(0);
}

@media (max-width: 900px) {
    .photo-grid {
        flex-wrap: wrap;
        justify-content: center;
    }
    
    .photo-item {
        width: 140px;
        height: 140px;
    }
    
    .featured-photos {
        margin: 1rem;
        padding: 1rem;
    }
    
    .featured-photos h2 {
        font-size: 1.5rem;
        margin-bottom: 1.5rem;
    }
    
    .photo-caption {
        font-size: 0.8rem;
        padding: 0.75rem 0.5rem;
    }
}

@media (max-width: 600px) {
    .photo-item {
        width: 120px;
        height: 120px;
    }
}

/* 音乐播放器样式 */
.music-player {
    position: fixed;
    right: 30px;
    top: 30px;
    z-index: 1000;
    background: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(10px);
    padding: 15px;
    border-radius: 15px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
    transition: transform 0.3s ease, width 0.3s ease;
    width: 80px;
}

.music-player:hover {
    transform: scale(1.02);
    width: 300px;
}

.music-player:hover .music-controls,
.music-player:hover .music-info {
    opacity: 1;
    visibility: visible;
}

.vinyl-player {
    position: relative;
    width: 60px;
    height: 60px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: transform 0.3s ease;
}

.vinyl-player:hover {
    transform: scale(1.1);
}

.player-icon {
    width: 100%;
    height: 100%;
    border-radius: 50%;
    object-fit: cover;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.3);
}

.vinyl-disc {
    position: absolute;
    width: 40%;
    height: 40%;
    background: radial-gradient(
        circle at center,
        #000 0%,
        #000 20%,
        #333 21%,
        #333 30%,
        #000 31%,
        #000 100%
    );
    border-radius: 50%;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    animation: rotate 3s linear infinite;
}

.music-player.paused .vinyl-disc {
    animation-play-state: paused;
}

.music-controls {
    display: flex;
    gap: 10px;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s ease, visibility 0.3s ease;
}

.music-controls button {
    background: none;
    border: none;
    color: white;
    cursor: pointer;
    padding: 5px;
    border-radius: 50%;
    transition: background-color 0.3s ease;
}

.music-controls button:hover {
    background-color: rgba(255, 255, 255, 0.1);
}

.music-info {
    width: 100%;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s ease, visibility 0.3s ease;
    color: white;
    text-align: center;
}

.song-title {
    font-size: 14px;
    margin-bottom: 5px;
    display: block;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.progress-bar {
    width: 100%;
    height: 4px;
    background: rgba(255, 255, 255, 0.2);
    border-radius: 2px;
    overflow: hidden;
}

.progress {
    width: 0%;
    height: 100%;
    background: white;
    transition: width 0.1s linear;
}

@keyframes rotate {
    from {
        transform: translate(-50%, -50%) rotate(0deg);
    }
    to {
        transform: translate(-50%, -50%) rotate(360deg);
    }
} 

/* Token对话框样式 */
.token-dialog {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5);
    z-index: 1000;
    justify-content: center;
    align-items: center;
}

.token-dialog.show {
    display: flex;
}

.token-dialog-content {
    background-color: white;
    padding: 20px;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    max-width: 400px;
    width: 90%;
}

.token-dialog h2 {
    margin-top: 0;
    color: #333;
}

.token-dialog input {
    width: 100%;
    padding: 8px;
    margin: 10px 0;
    border: 1px solid #ddd;
    border-radius: 4px;
}

.token-dialog button {
    background-color: #4CAF50;
    color: white;
    border: none;
    padding: 10px 20px;
    border-radius: 4px;
    cursor: pointer;
    width: 100%;
}

.token-dialog button:hover {
    background-color: #45a049;
}

.token-help {
    margin-top: 10px;
    font-size: 14px;
    color: #666;
}

.token-help a {
    color: #4CAF50;
    text-decoration: none;
}

.token-help a:hover {
    text-decoration: underline;
} 