:root {
    /* SEKAI Pass Theme Variables */
    --bg-color: #0b0b0e;
    --card-bg: #17171c;
    --primary-color: #a48cd6;
    --primary-hover: #bda6e8;
    --text-main: #e2e2e6;
    --text-muted: #75757a;
    --border-color: #2a2a30;
    --error-color: #e57373;
    --success-color: #81c784;
    --code-font: 'Menlo', 'Monaco', 'Courier New', monospace;
    
    /* Legacy Mappings for Hub */
    --accent: var(--primary-color);
    --bg-primary: var(--bg-color);
    --text-primary: var(--text-main);
    --text-secondary: var(--text-muted);
    --border: var(--border-color);
}

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

body {
    font-family: 'Inter', system-ui, -apple-system, sans-serif;
    background-color: var(--bg-color);
    color: var(--text-main);
    line-height: 1.6;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

a {
    color: inherit;
    text-decoration: none;
}

.container {
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 1.5rem;
}

/* Header */
header {
    padding: 1.5rem 0;
    /* Glass effect slightly tweaked for darker theme */
    background: rgba(11, 11, 14, 0.8);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid var(--border-color);
    position: sticky;
    top: 0;
    z-index: 100;
}

.nav-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--text-main);
    letter-spacing: -0.5px;
    position: relative;
    /* Optional: Add the "SYSTEM" tag from Pass if desired, keeping it simple for Hub for now */
}

/* Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0.75rem 1.5rem;
    border-radius: 4px; /* More squared like Pass */
    font-weight: 600;
    transition: all 0.2s ease;
    cursor: pointer;
    border: none;
    font-size: 0.95rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.btn-primary {
    background: var(--primary-color);
    color: #1a1a1e; /* Dark text on bright accent */
    box-shadow: 0 4px 20px rgba(164, 140, 214, 0.2);
}

.btn-primary:hover {
    background: var(--primary-hover);
    transform: translateY(-1px);
    box-shadow: 0 4px 20px rgba(164, 140, 214, 0.4);
}

.btn-secondary {
    background: transparent;
    color: var(--text-muted);
    border: 1px solid var(--border-color);
}

.btn-secondary:hover {
    background: rgba(255, 255, 255, 0.05);
    color: var(--text-main);
}

/* Hero Section */
.hero {
    padding: 6rem 0;
    text-align: center;
    position: relative;
    overflow: hidden;
}

.hero::before {
    content: '';
    position: absolute;
    top: -50%;
    left: 50%;
    transform: translateX(-50%);
    width: 600px;
    height: 600px;
    background: radial-gradient(circle, rgba(164, 140, 214, 0.1), transparent 70%); /* Primary color glow */
    z-index: -1;
    pointer-events: none;
}

.hero h1 {
    font-size: 4rem;
    font-weight: 800;
    margin-bottom: 1.5rem;
    line-height: 1.1;
    background: linear-gradient(to bottom right, #fff, #94a3b8);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

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

/* Ecosystem Grid */
.section-title {
    font-size: 2rem;
    margin-bottom: 2rem;
    text-align: center;
}

.category-title {
    font-size: 1rem;
    color: var(--text-muted);
    margin-top: 2rem;
    margin-bottom: 1rem;
    padding-left: 0.5rem;
    border-left: 3px solid var(--primary-color);
    font-family: var(--code-font);
    text-transform: uppercase;
    letter-spacing: 1px;
}

.grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 1.5rem; /* Tighter gap */
    padding: 1rem 0 3rem;
}

.card {
    background: var(--card-bg);
    border: 1px solid var(--border-color);
    border-radius: 8px; /* Match Pass border radius */
    padding: 2rem;
    transition: transform 0.2s, border-color 0.2s, box-shadow 0.2s;
    display: flex;
    flex-direction: column;
    position: relative;
    overflow: hidden;
}

.card:hover {
    transform: translateY(-2px);
    border-color: var(--primary-color);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
}

.card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 2px;
    background: linear-gradient(90deg, transparent, var(--primary-color), transparent);
    opacity: 0;
    transition: opacity 0.2s;
}

.card:hover::before {
    opacity: 1;
}

.card-icon {
    font-size: 2rem;
    margin-bottom: 1rem;
    color: var(--primary-color);
}

.card h3 {
    margin-bottom: 0.5rem;
    font-size: 1.25rem;
    color: var(--text-main);
}

.card p {
    color: var(--text-muted);
    flex-grow: 1;
    font-size: 0.95rem;
}

.card-link {
    margin-top: 1.5rem;
    color: var(--primary-color);
    font-weight: 600;
    font-size: 0.9rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.card-link:hover {
    text-decoration: underline;
    text-underline-offset: 4px;
}

/* Private Dashboard */
.welcome-section {
    padding: 4rem 0 2rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 1px solid var(--border-color);
    margin-bottom: 3rem;
    flex-wrap: wrap;
    gap: 2rem;
}

.welcome-text h2 {
    font-size: 2.2rem;
    margin-bottom: 0.5rem;
}

/* Dashboard Components */
.dashboard-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 1.5rem;
    margin-bottom: 2rem;
}

.stat-card {
    background: var(--card-bg);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    padding: 1.5rem;
    position: relative;
}

.stat-header {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin-bottom: 1rem;
    color: var(--text-muted);
    font-size: 0.8rem;
    text-transform: uppercase;
    letter-spacing: 1px;
    font-family: var(--code-font);
}

.stat-value {
    font-size: 1.75rem;
    font-weight: 700;
    margin-bottom: 0.25rem;
    color: var(--text-main);
}

.stat-label {
    color: var(--text-muted);
    font-size: 0.9rem;
}

.achievement-list {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.achievement-item {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 1rem;
    background: rgba(255, 255, 255, 0.02);
    border-radius: 6px;
    border: 1px solid var(--border-color);
    transition: background 0.2s;
}

.achievement-item:hover {
    background: rgba(255, 255, 255, 0.04);
}

.achievement-icon {
    font-size: 1.25rem;
    background: rgba(164, 140, 214, 0.1);
    color: var(--primary-color);
    width: 2.5rem;
    height: 2.5rem;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
}

.chart-placeholder {
    height: 200px;
    background: rgba(255, 255, 255, 0.02);
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 1px dashed var(--border-color);
    color: var(--text-muted);
    font-family: var(--code-font);
    font-size: 0.9rem;
}

/* Utilities */
.loading-screen {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    height: 100vh;
    gap: 1.5rem;
}

.spinner {
    width: 40px;
    height: 40px;
    border: 3px solid rgba(164, 140, 214, 0.1);
    border-radius: 50%;
    border-top-color: var(--primary-color);
    animation: spin 1s ease-in-out infinite;
}

.loading-text {
    font-family: var(--code-font);
    font-size: 0.9rem;
    color: var(--text-muted);
    letter-spacing: 2px;
    animation: pulse 2s infinite;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

@keyframes pulse {
    0%, 100% { opacity: 0.5; }
    50% { opacity: 1; }
}

@media (max-width: 768px) {
    .hero h1 {
        font-size: 2.5rem;
    }
    
    .welcome-section {
        flex-direction: column;
        align-items: flex-start;
        text-align: left;
    }
}
