:root {
    --bg: #f8f9fb;
    --card-bg: #ffffff;
    --text-primary: #1f2937;
    --text-secondary: #6b7280;
    --text-muted: #9ca3af;
    --accent: #5b8def;
    --accent-light: #e8f0fe;
    --accent-glow: rgba(91, 141, 239, 0.15);
    --border: #e5e7eb;
    --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.05);
    --shadow-md: 0 4px 16px rgba(0, 0, 0, 0.08);
    --shadow-lg: 0 12px 40px rgba(0, 0, 0, 0.12);
    --radius-sm: 8px;
    --radius: 12px;
    --radius-lg: 16px;
    --radius-xl: 20px;
    --transition: 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    --font-mono: 'SF Mono', 'Cascadia Code', 'Consolas', 'Monaco', 'Menlo', 'Courier New', monospace;
    --grid-color: rgba(0, 0, 0, 0.04);
    --grid-size: 22px;
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    font-size: 16px;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'PingFang SC', 'Microsoft YaHei', 'Helvetica Neue', sans-serif;
    background-color: #f8f9fb;
    background-image:
        linear-gradient(var(--grid-color) 1px, transparent 1px),
        linear-gradient(90deg, var(--grid-color) 1px, transparent 1px);
    background-size: var(--grid-size) var(--grid-size);
    background-position: -1px -1px;
    color: var(--text-primary);
    line-height: 1.6;
    min-height: 100vh;
}

a {
    text-decoration: none;
}

.app-container {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

.main-header {
    text-align: center;
    padding: 48px 24px 32px;
    background: linear-gradient(180deg, rgba(91, 141, 239, 0.05) 0%, transparent 100%);
}

.logo-wrapper {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 4px;
    flex-wrap: wrap;
    margin-bottom: 12px;
}

.logo-char {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-family: var(--font-mono);
    font-size: 2rem;
    font-weight: 700;
    width: 44px;
    height: 44px;
    border-radius: 10px;
    transition: transform var(--transition);
}

.logo-l {
    background: #e8f0fe;
    color: #3b7de0;
}

.logo-i {
    background: #fde8ec;
    color: #d94862;
}

.logo-pipe {
    background: #e5e7eb;
    color: #6b7280;
    font-size: 1.6rem;
}

.logo-text {
    font-size: 1.3rem;
    font-weight: 700;
    color: var(--text-primary);
    margin-left: 8px;
    letter-spacing: 1px;
}

.logo-subtitle {
    font-size: 0.9rem;
    color: var(--text-secondary);
    margin-top: 4px;
}

.main-content {
    flex: 1;
    padding: 24px 36px 48px;
    max-width: 1100px;
    margin: 0 auto;
    width: 100%;
}

.cards-container {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
    gap: 24px;
}

.card {
    display: flex;
    flex-direction: column;
    background: var(--card-bg);
    border-radius: var(--radius-lg);
    padding: 28px 24px 24px;
    border: 1px solid var(--border);
    box-shadow: var(--shadow-sm);
    transition: all var(--transition);
    cursor: pointer;
    position: relative;
    overflow: hidden;
    color: var(--text-primary);
}

.card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: linear-gradient(90deg, var(--accent), #3b7de0);
    opacity: 0;
    transition: opacity var(--transition);
}

.card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-lg);
    border-color: var(--accent);
}

.card:hover::before {
    opacity: 1;
}

.card-icon {
    width: 56px;
    height: 56px;
    border-radius: var(--radius);
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 16px;
    background: var(--accent-light);
    color: var(--accent);
    font-family: var(--font-mono);
    font-size: 1.2rem;
    font-weight: 700;
    gap: 2px;
    transition: all var(--transition);
}

.card:hover .card-icon {
    background: var(--accent);
    color: #ffffff;
    transform: scale(1.05);
}

.icon-char {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 18px;
    height: 18px;
    border-radius: 4px;
    font-size: 0.8rem;
}

.icon-char.l {
    background: #e8f0fe;
    color: #3b7de0;
}

.icon-char.i {
    background: #fde8ec;
    color: #d94862;
}

.icon-char.pipe {
    background: #e5e7eb;
    color: #6b7280;
}

.hash-icon svg,
.aes-icon svg,
.base64-icon svg {
    width: 28px;
    height: 28px;
}

.card-title {
    font-size: 1.15rem;
    font-weight: 700;
    margin-bottom: 8px;
}

.card-desc {
    font-size: 0.85rem;
    color: var(--text-secondary);
    line-height: 1.6;
    margin-bottom: 16px;
    flex: 1;
}

.card-tags {
    display: flex;
    gap: 6px;
    flex-wrap: wrap;
}

.tag {
    font-size: 0.7rem;
    padding: 3px 10px;
    border-radius: 20px;
    background: #f3f4f6;
    color: var(--text-secondary);
    font-weight: 500;
    transition: all var(--transition);
}

.card:hover .tag {
    background: var(--accent-light);
    color: var(--accent);
}

.card-arrow {
    position: absolute;
    top: 24px;
    right: 24px;
    font-size: 1.2rem;
    color: var(--text-muted);
    transition: all var(--transition);
    opacity: 0;
}

.card:hover .card-arrow {
    opacity: 1;
    right: 20px;
    color: var(--accent);
}

.main-footer {
    padding: 24px;
    border-top: 1px solid var(--border);
    background: rgba(255, 255, 255, 0.5);
}

.footer-links {
    display: flex;
    justify-content: center;
    gap: 24px;
    flex-wrap: wrap;
    max-width: 800px;
    margin: 0 auto;
}

.footer-link {
    display: flex;
    align-items: center;
    gap: 6px;
    color: var(--text-muted);
    font-size: 0.75rem;
    transition: color var(--transition);
    padding: 6px 12px;
    border-radius: var(--radius-sm);
}

.footer-link:hover {
    color: var(--accent);
    background: var(--accent-light);
}

.footer-icon {
    width: 14px;
    height: 14px;
    flex-shrink: 0;
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(24px) scale(0.98);
    }
    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

.card {
    animation: fadeInUp 0.55s cubic-bezier(0.22, 1, 0.36, 1) backwards;
}

.card:nth-child(1) { animation-delay: 0.05s; }
.card:nth-child(2) { animation-delay: 0.1s; }
.card:nth-child(3) { animation-delay: 0.15s; }
.card:nth-child(4) { animation-delay: 0.2s; }
.card:nth-child(5) { animation-delay: 0.25s; }
.card:nth-child(6) { animation-delay: 0.3s; }
.card:nth-child(7) { animation-delay: 0.35s; }
.card:nth-child(8) { animation-delay: 0.4s; }
.card:nth-child(9) { animation-delay: 0.45s; }
.card:nth-child(10) { animation-delay: 0.5s; }
.card:nth-child(11) { animation-delay: 0.55s; }
.card:nth-child(12) { animation-delay: 0.6s; }
.card:nth-child(13) { animation-delay: 0.65s; }
.card:nth-child(14) { animation-delay: 0.7s; }
.card:nth-child(15) { animation-delay: 0.75s; }
.card:nth-child(16) { animation-delay: 0.8s; }
.card:nth-child(17) { animation-delay: 0.85s; }
.card:nth-child(18) { animation-delay: 0.9s; }
.card:nth-child(19) { animation-delay: 0.95s; }
.card:nth-child(20) { animation-delay: 1s; }
@media (max-width: 768px) {
    .main-header {
        padding: 32px 16px 24px;
    }

    .main-content {
        padding: 16px;
    }

    .cards-container {
        grid-template-columns: 1fr;
        gap: 16px;
    }

    .card {
        padding: 20px 16px;
    }

    .logo-char {
        width: 36px;
        height: 36px;
        font-size: 1.5rem;
    }

    .logo-text {
        font-size: 1.1rem;
    }
}

@media (max-width: 480px) {
    .footer-links {
        flex-direction: column;
        align-items: center;
        gap: 8px;
    }

    .card-arrow {
        display: none;
    }
}

@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after {
        animation-duration: 0.001ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.001ms !important;
        scroll-behavior: auto !important;
    }
}