:root {
    --primary: #ea4c89;
    --primary-dark: #df3e7b;
    --secondary: #0d0c22;
    --bg: #f8f8f8;
    --white: #ffffff;
    --gray-100: #f3f3f4;
    --gray-200: #e7e7e9;
    --gray-300: #9e9ea7;
    --gray-400: #6e6d7a;
    --text: #0d0c22;
    --shadow-sm: 0 1px 2px rgba(0,0,0,0.04);
    --shadow: 0 4px 12px rgba(0,0,0,0.08);
    --shadow-lg: 0 12px 24px rgba(0,0,0,0.12);
    --radius-sm: 8px;
    --radius: 12px;
    --radius-lg: 24px;
}

body {
    font-family: "SF Pro Display", -apple-system, BlinkMacSystemFont, sans-serif;
    background: var(--bg);
    color: var(--text);
    line-height: 1.5;
}

/* Header Styles */
.header {
    background: var(--white);
    position: sticky;
    top: 0;
    z-index: 100;
    border-bottom: 1px solid var(--gray-200);
}

.header-inner {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 24px;
}

.header-content {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 24px 0;
}

.header-left {
    flex-shrink: 0;
}

.header-right {
    flex-shrink: 0;
    display: flex;
    justify-content: flex-end;
    margin-right: 24px;
}

.site-title {
    font-size: 24px;
    font-weight: 700;
    color: var(--text);
    text-decoration: none;
}

.site-title span {
    color: var(--primary);
}

.search-wrapper {
    width: 280px;
}

.search-form {
    position: relative;
    width: 100%;
}

.search-form input {
    width: 100%;
    padding: 12px 16px;
    border: 1px solid #eee;
    border-radius: 6px;
    font-size: 14px;
    transition: all 0.3s ease;
}

.search-icon-btn {
    display: none;
    background: none;
    border: none;
    padding: 8px;
    cursor: pointer;
    color: #666;
}

/* 移动端搜索框样式 */
@media (max-width: 768px) {
    .header-content {
        padding: 16px 0;
    }

    .header-right {
        margin-right: 16px;
    }

    .search-wrapper {
        width: auto;
    }

    .search-form input {
        display: none;
    }

    .search-icon-btn {
        display: flex;
        align-items: center;
        justify-content: center;
    }

    /* 搜索框展开状态 */
    .search-wrapper.expanded {
        position: fixed;
        top: 0;
        left: 0;
        width: 100%;
        height: 100%;
        background: rgba(255, 255, 255, 0.98);
        z-index: 1000;
        display: flex;
        align-items: flex-start;
        padding: 16px;
    }

    .search-wrapper.expanded .search-form {
        width: 100%;
    }

    .search-wrapper.expanded input {
        display: block;
        width: 100%;
        padding: 12px 40px 12px 16px;
    }

    .search-wrapper.expanded .search-icon-btn {
        position: absolute;
        right: 16px;
        top: 50%;
        transform: translateY(-50%);
    }
}

/* Categories */
.categories {
    display: flex;
    gap: 16px;
    overflow-x: auto;
    scrollbar-width: none;
    padding: 0 0 16px 0;
    margin: 0;
}

.categories::-webkit-scrollbar {
    display: none;
}

.category-link {
    padding: 8px 16px;
    font-size: 14px;
    font-weight: 500;
    color: var(--gray-400);
    background: transparent;
    border-radius: var(--radius-sm);
    transition: all 0.2s ease;
    white-space: nowrap;
    cursor: pointer;
    text-decoration: none;
    user-select: none;
}

.category-link:hover {
    color: var(--text);
    background: var(--gray-100);
}

.category-link.active {
    color: var(--white);
    background: var(--text);
}

/* Content */
.content {
    max-width: 1400px;
    margin: 0 auto;
    padding: 40px 24px;
}

/* Grid */
.masonry-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 24px;
    padding: 12px 0;
}

/* Card */
.logo-card {
    background: var(--white);
    border-radius: var(--radius);
    overflow: hidden;
    transition: all 0.3s ease;
    display: flex;
    flex-direction: column;
}

.logo-card:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-lg);
}

.logo-image {
    position: relative;
    padding-top: 50%;
    background: var(--white);
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
}

.logo-image img {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 65%;
    height: 65%;
    object-fit: contain;
    transition: all 0.3s ease;
}

.logo-card:hover .logo-image img {
    width: 70%;
    height: 70%;
}

.hover-overlay {
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, 0.75);
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: all 0.3s ease;
}

.logo-card:hover .hover-overlay {
    opacity: 1;
}

.download-button {
    display: flex;
    align-items: center;
    gap: 8px;
    background: var(--primary);
    color: white;
    padding: 10px 20px;
    border-radius: 6px;
    font-size: 14px;
    font-weight: 500;
    text-decoration: none;
    transform: translateY(10px);
    transition: all 0.2s ease;
}

.logo-card:hover .download-button {
    transform: translateY(0);
}

.download-button:hover {
    background: var(--secondary);
}

.download-button svg {
    color: white;
    transition: transform 0.2s ease;
}

.download-button:hover svg {
    transform: translateY(1px);
}

.logo-details {
    padding: 16px 20px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    border-top: 1px solid var(--gray-100);
    background: var(--white);
    min-height: 64px;
}

.logo-details h3 {
    font-size: 14px;
    font-weight: 500;
    color: var(--text);
    margin: 0;
    line-height: 1.5;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    max-width: 65%;
}

.category-badge {
    font-size: 12px;
    color: var(--gray-300);
    background: var(--gray-100);
    padding: 6px 12px;
    border-radius: 6px;
    line-height: 1.2;
    transition: all 0.2s ease;
    white-space: nowrap;
}

.logo-card:hover .category-badge {
    color: var(--primary);
    background: rgba(234, 76, 137, 0.1);
}

/* Empty State */
.empty-state {
    text-align: center;
    padding: 80px 20px;
    color: var(--gray-400);
}

.empty-state img {
    width: 120px;
    height: 120px;
    margin-bottom: 24px;
    opacity: 0.5;
}

.empty-state p {
    font-size: 15px;
    font-weight: 500;
}

/* Animations */
@keyframes fadeUp {
    from {
        opacity: 0;
        transform: translateY(10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.logo-card {
    animation: fadeUp 0.5s ease backwards;
}

/* Responsive */
@media (max-width: 768px) {
    .header-inner {
        padding: 0 16px;
    }

    .header-content {
        display: flex;
        flex-direction: row;
        align-items: center;
        justify-content: space-between;
        padding: 16px 0;
        gap: 16px;
        width: 100%;
    }

    .header-left {
        flex-shrink: 0;
    }

    .header-right {
        flex: 1;
        max-width: none;
        margin-right: 16px;
    }

    .site-title {
        font-size: 18px;
        white-space: nowrap;
    }

    .search-form input {
        padding: 8px 12px;
        font-size: 14px;
    }
}

/* 更小屏幕的额外调整 */
@media (max-width: 480px) {
    .header-inner {
        padding: 0 12px;
    }

    .header-content {
        padding: 12px 0;
        gap: 12px;
    }

    .header-right {
        margin-right: 12px;
    }

    .site-title {
        font-size: 16px;
    }
}

/* Loading State */
.logo-card.loading {
    position: relative;
    overflow: hidden;
}

.logo-card.loading::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(
        90deg,
        transparent,
        rgba(255, 255, 255, 0.4),
        transparent
    );
    animation: shimmer 1.5s infinite;
}

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

/* 添加动画效果 */
@keyframes downloadPulse {
    0% { transform: scale(1); }
    50% { transform: scale(1.05); }
    100% { transform: scale(1); }
}

.download-button:hover .download-icon {
    animation: downloadPulse 1s infinite;
} 