:root {
    --bg-main: #030712;
    --bg-card: rgba(17, 24, 39, 0.7);
    --border-light: rgba(255, 255, 255, 0.08);
    --text-primary: #f9fafb;
    --text-muted: #9ca3af;
    --primary: #6366f1;
    --secondary: #a855f7;
    --accent: #10b981;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Outfit', sans-serif;
}

body {
    background-color: var(--bg-main);
    color: var(--text-primary);
    line-height: 1.6;
    overflow-x: hidden;
    position: relative;
}

/* Background Effects */
.spotlight {
    position: fixed;
    top: -20%;
    left: 50%;
    transform: translateX(-50%);
    width: 600px;
    height: 600px;
    background: radial-gradient(circle, rgba(99, 102, 241, 0.15) 0%, transparent 60%);
    z-index: -2;
    pointer-events: none;
}

.grid-bg {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image:
        linear-gradient(to right, rgba(255, 255, 255, 0.03) 1px, transparent 1px),
        linear-gradient(to bottom, rgba(255, 255, 255, 0.03) 1px, transparent 1px);
    background-size: 40px 40px;
    z-index: -3;
    pointer-events: none;
}

/* Header */
.hub-header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    background: rgba(3, 7, 18, 0.8);
    backdrop-filter: blur(12px);
    border-bottom: 1px solid var(--border-light);
    z-index: 100;
}

.header-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 1rem 2rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    text-decoration: none;
    color: white;
}

.logo-icon {
    font-size: 1.5rem;
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.logo-text {
    font-weight: 800;
    font-size: 1.25rem;
    letter-spacing: 1px;
}

.main-nav {
    display: flex;
    gap: 2rem;
}

.main-nav a {
    color: var(--text-muted);
    text-decoration: none;
    font-weight: 500;
    transition: color 0.3s;
}

.main-nav a:hover {
    color: white;
}

.main-nav a:hover {
    color: white;
}

/* Hero Section */
.hub-main {
    max-width: 1200px;
    margin: 100px auto 0;
    padding: 2rem;
}

.hero-section {
    text-align: center;
    padding: 4rem 0 6rem;
}

.hero-chip {
    display: inline-block;
    padding: 0.5rem 1rem;
    background: rgba(99, 102, 241, 0.1);
    border: 1px solid rgba(99, 102, 241, 0.2);
    border-radius: 999px;
    color: #818cf8;
    font-weight: 600;
    font-size: 0.9rem;
    margin-bottom: 1.5rem;
}

.hero-title {
    font-size: 4rem;
    font-weight: 800;
    line-height: 1.1;
    margin-bottom: 1.5rem;
}

.gradient-text {
    background: linear-gradient(135deg, var(--primary), var(--secondary), var(--accent));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.hero-subtitle {
    font-size: 1.25rem;
    color: var(--text-muted);
    max-width: 600px;
    margin: 0 auto;
}

/* Category Sections */
.category-section {
    margin-bottom: 4rem;
}

.category-header {
    display: flex;
    align-items: center;
    gap: 1.5rem;
    margin-bottom: 2rem;
}

.category-header h2 {
    font-size: 1.8rem;
    font-weight: 700;
    white-space: nowrap;
}

.category-header h2 span {
    color: var(--text-muted);
    font-weight: 400;
}

.category-header .line {
    flex-grow: 1;
    height: 1px;
    background: linear-gradient(to right, var(--border-light), transparent);
}

/* Tools Grid */
.tools-grid {
    display: grid;
    /* Default for mobile: 1 column filling width */
    grid-template-columns: 1fr;
    gap: 1.5rem;
    align-items: stretch;
}

@media (min-width: 768px) {
    .tools-grid {
        /* On PC, strictly allocate 350px widths, and pack them instead of stretching to 1fr */
        grid-template-columns: repeat(auto-fill, 350px);
        justify-content: flex-start;
    }
}

.tool-card {
    background: var(--bg-card);
    border: 1px solid var(--border-light);
    border-radius: 20px;
    padding: 2rem;
    text-decoration: none;
    color: white;
    display: flex;
    flex-direction: column;
    position: relative;
    overflow: hidden;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.tool-card:hover:not(.coming-soon) {
    transform: translateY(-5px);
    border-color: rgba(99, 102, 241, 0.4);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.4), 0 0 20px rgba(99, 102, 241, 0.1);
}

.card-icon {
    width: 60px;
    height: 60px;
    border-radius: 16px;
    display: flex;
    justify-content: center;
    align-items: center;
    font-size: 1.8rem;
    margin-bottom: 1.5rem;
    color: white;
    box-shadow: 0 8px 16px rgba(0, 0, 0, 0.2);
}

.card-content h3 {
    font-size: 1.4rem;
    font-weight: 700;
    margin-bottom: 0.75rem;
}

.card-content p {
    color: var(--text-muted);
    font-size: 0.95rem;
    line-height: 1.5;
    margin-bottom: 1rem;
}

.card-arrow {
    position: absolute;
    bottom: 2rem;
    right: 2rem;
    background: rgba(255, 255, 255, 0.05);
    width: 40px;
    height: 40px;
    border-radius: 50%;
    display: flex;
    justify-content: center;
    align-items: center;
    transition: all 0.3s;
    color: var(--text-muted);
}

.tool-card:hover .card-arrow {
    background: var(--primary);
    color: white;
    transform: translateX(5px) scale(1.1);
}

.coming-soon {
    opacity: 0.6;
    cursor: default;
}

.badge {
    display: inline-block;
    padding: 0.25rem 0.75rem;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 999px;
    font-size: 0.8rem;
    font-weight: 600;
    color: var(--text-muted);
    margin-top: 1rem;
}

.badge {
    display: inline-block;
    padding: 0.25rem 0.75rem;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 999px;
    font-size: 0.8rem;
    font-weight: 600;
    color: var(--text-muted);
    margin-top: 1rem;
}

/* About Section */
.about-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
    margin-top: 1rem;
}

.about-card {
    background: transparent;
    border: 1px dashed rgba(255, 255, 255, 0.1);
    border-radius: 20px;
    padding: 2.5rem 2rem;
    text-align: center;
    transition: all 0.3s;
}

.about-card:hover {
    background: rgba(255, 255, 255, 0.02);
    border-color: rgba(99, 102, 241, 0.3);
}

.about-icon {
    font-size: 2.5rem;
    margin-bottom: 1.5rem;
    color: var(--primary);
}

.about-card h3 {
    font-size: 1.3rem;
    font-weight: 700;
    margin-bottom: 1rem;
    color: var(--text-primary);
}

.about-card p {
    color: var(--text-muted);
    font-size: 0.95rem;
    line-height: 1.6;
}

/* Footer */
.hub-footer {
    text-align: center;
    padding: 3rem 0;
    color: var(--text-muted);
    border-top: 1px solid var(--border-light);
    margin-top: 4rem;
}

/* Responsive */
@media (max-width: 768px) {
    .hero-title {
        font-size: 2.8rem;
    }

    .main-nav {
        display: none;
    }

    .category-header h2 {
        font-size: 1.5rem;
    }

    .tools-grid {
        grid-template-columns: 1fr;
    }
}