/* Reset & Base */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    --color-bg: #fcfcfc;
    --color-surface: #D9D9D9;
    --color-text: #1d1d1f;
    --color-text-secondary: #86868b;
    --color-border: rgba(0, 0, 0, 0.06);
    --color-border-strong: rgba(0, 0, 0, 0.1);

    /* Liquid Glass Variables */
    --glass-bg: rgba(255, 255, 255, 0.72);
    --glass-border: rgba(255, 255, 255, 0.5);
    --glass-shadow: 0 8px 32px rgba(0, 0, 0, 0.04);
    --glass-blur: 20px;

    /* Layout */
    --sidebar-width: 280px;

    /* Typography - SF Pro */
    --font-system: -apple-system, BlinkMacSystemFont, "SF Pro Display", "SF Pro Text", "Helvetica Neue", Helvetica, Arial, sans-serif;
}

html {
    scroll-behavior: smooth;
}

/* macOS-style scrollbar */
::-webkit-scrollbar {
    width: 8px;
    height: 8px;
}

::-webkit-scrollbar-track {
    background: transparent;
}

::-webkit-scrollbar-thumb {
    background: rgba(0, 0, 0, 0.2);
    border-radius: 100px;
    border: 2px solid transparent;
    background-clip: padding-box;
}

::-webkit-scrollbar-thumb:hover {
    background: rgba(0, 0, 0, 0.35);
    border: 2px solid transparent;
    background-clip: padding-box;
}

/* Firefox */
* {
    scrollbar-width: thin;
    scrollbar-color: rgba(0, 0, 0, 0.2) transparent;
}

body {
    background-color: var(--color-bg);
    color: var(--color-text);
    font-family: var(--font-system);
    font-size: 14px;
    line-height: 1.5;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

/* Sidebar */
.sidebar {
    position: fixed;
    left: 0;
    top: 0;
    width: var(--sidebar-width);
    height: 100vh;
    padding: 32px 24px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    border-right: 1px solid var(--color-border);
    background: var(--color-bg);
    z-index: 100;
}

.sidebar-top {
    display: flex;
    flex-direction: column;
    gap: 40px;
}

.logo-link {
    display: block;
    width: 40px;
    height: 40px;
}

.logo {
    width: 100%;
    height: 100%;
    border-radius: 10px;
}

/* Search Box */
.search-container {
    width: 100%;
}

.search-box {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 10px 12px;
    background: #ffffff;
    border-radius: 10px;
    cursor: pointer;
    transition: all 0.2s ease;

    /* Inset grey border effect */
    box-shadow:
        inset 0 0 0 1.5px rgba(0, 0, 0, 0.08),
        inset 0 2px 4px rgba(0, 0, 0, 0.02);
}

.search-box:hover {
    box-shadow:
        inset 0 0 0 1.5px rgba(0, 0, 0, 0.12),
        inset 0 2px 4px rgba(0, 0, 0, 0.03);
}

.search-icon {
    color: var(--color-text-secondary);
    flex-shrink: 0;
    display: flex;
    align-items: center;
}

.search-input {
    flex: 1;
    font-size: 13px;
    color: var(--color-text);
    font-weight: 400;
    line-height: 1;
    border: none;
    background: transparent;
    outline: none;
    font-family: var(--font-system);
    min-width: 0;
}

.search-input::placeholder {
    color: var(--color-text-secondary);
}


.search-shortcut {
    display: flex;
    align-items: center;
    gap: 3px;
}

.search-shortcut kbd {
    display: flex;
    align-items: center;
    justify-content: center;
    min-width: 20px;
    height: 20px;
    padding: 0 5px;
    font-family: var(--font-system);
    font-size: 11px;
    font-weight: 500;
    color: var(--color-text-secondary);
    background: linear-gradient(180deg, #fafafa 0%, #f0f0f0 100%);
    border: 1px solid rgba(0, 0, 0, 0.1);
    border-radius: 4px;
    box-shadow: 0 1px 0 rgba(0, 0, 0, 0.08);
}

/* Navigation */
.nav {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.nav-item {
    display: block;
    padding: 10px 12px;
    color: var(--color-text-secondary);
    text-decoration: none;
    font-size: 13px;
    font-weight: 500;
    letter-spacing: -0.01em;
    border-radius: 8px;
    transition: all 0.2s ease;
}

.nav-item:hover {
    color: var(--color-text);
    background: rgba(0, 0, 0, 0.04);
}

.nav-item.active {
    color: var(--color-text);
    background: rgba(0, 0, 0, 0.04);
}

/* Sidebar Bottom */
.sidebar-bottom {
    display: flex;
    align-items: center;
}

.social-link {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    color: var(--color-text-secondary);
    border-radius: 8px;
    transition: all 0.2s ease;
}

.social-link:hover {
    color: var(--color-text);
    background: rgba(0, 0, 0, 0.04);
}

/* Main Content */
.main-content {
    margin-left: var(--sidebar-width);
    min-height: 100vh;
    padding: 48px 64px;
}

/* Sections */
.section {
    max-width: 1200px;
    margin: 0 auto;
}

.section.hidden {
    display: none;
}

.section-header {
    margin-bottom: 48px;
}

.section-title {
    font-size: 32px;
    font-weight: 600;
    letter-spacing: -0.02em;
    color: var(--color-text);
    margin-bottom: 8px;
}

.section-subtitle {
    font-size: 15px;
    color: var(--color-text-secondary);
    font-weight: 400;
}

/* Members Grid */
.members-grid {
    display: flex;
    flex-direction: column;
    gap: 48px;
}

.member-category {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.category-title {
    font-size: 14px;
    font-weight: 600;
    color: var(--color-text-secondary);
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.category-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 24px;
}

/* Liquid Glass Card */
.member-card {
    text-decoration: none;
    display: block;
    border-radius: 24px;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.member-card:hover {
    transform: translateY(-2px) scale(1.01);
}

.card-inner {
    display: flex;
    align-items: center;
    gap: 16px;
    padding: 20px;
    border-radius: 24px;
    position: relative;

    /* White liquid glass */
    background: rgba(252, 252, 252, 0.85);
    backdrop-filter: blur(40px) saturate(180%);
    -webkit-backdrop-filter: blur(40px) saturate(180%);

    /* Subtle border */
    border: 1px solid rgba(255, 255, 255, 0.9);

    /* Liquid glass shadows */
    box-shadow:
        0 4px 24px rgba(0, 0, 0, 0.04),
        0 1px 3px rgba(0, 0, 0, 0.02),
        inset 1px 1px 0px rgba(255, 255, 255, 1),
        inset -1px -1px 0px rgba(0, 0, 0, 0.03),
        inset 0 0 20px rgba(255, 255, 255, 0.5);

    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.member-card:hover .card-inner {
    background: rgba(252, 252, 252, 0.95);
    box-shadow:
        0 8px 32px rgba(0, 0, 0, 0.08),
        0 2px 6px rgba(0, 0, 0, 0.04),
        inset 1px 1px 0px rgba(255, 255, 255, 1),
        inset -1px -1px 0px rgba(0, 0, 0, 0.03),
        inset 0 0 30px rgba(255, 255, 255, 0.6);
}

/* Faded banner background - right half */
.card-banner {
    position: absolute;
    top: 0;
    right: 0;
    width: 50%;
    height: 100%;
    background-size: cover;
    background-position: center;
    border-radius: 0 24px 24px 0;
    opacity: 0.15;
    /* Fade from transparent on left to visible on right */
    mask-image: linear-gradient(to right, transparent 0%, black 100%);
    -webkit-mask-image: linear-gradient(to right, transparent 0%, black 100%);
    pointer-events: none;
    transition: opacity 0.3s ease;
}

.member-card:hover .card-banner {
    opacity: 0.25;
}

.member-img {
    width: 56px;
    height: 56px;
    border-radius: 50%;
    object-fit: cover;
    flex-shrink: 0;
    /* Subtle ring around avatar */
    box-shadow: 0 0 0 1px rgba(0, 0, 0, 0.04);
    position: relative;
    z-index: 1;
}

.member-info {
    flex: 1;
    min-width: 0;
    position: relative;
    z-index: 1;
}

.member-info h3 {
    font-size: 15px;
    font-weight: 600;
    color: var(--color-text);
    letter-spacing: -0.01em;
    margin-bottom: 2px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.handle {
    font-size: 13px;
    color: var(--color-text-secondary);
    font-weight: 400;
}

/* Articles Grid */
.articles-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 24px;
}

.article-card {
    text-decoration: none;
    display: block;
    border-radius: 24px;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.article-card:hover {
    transform: translateY(-2px) scale(1.01);
}

.article-inner {
    position: relative;
    border-radius: 24px;
    overflow: hidden;

    /* White liquid glass */
    background: rgba(252, 252, 252, 0.85);
    backdrop-filter: blur(40px) saturate(180%);
    -webkit-backdrop-filter: blur(40px) saturate(180%);

    /* Subtle border */
    border: 1px solid rgba(255, 255, 255, 0.9);

    /* Liquid glass shadows */
    box-shadow:
        0 4px 24px rgba(0, 0, 0, 0.04),
        0 1px 3px rgba(0, 0, 0, 0.02),
        inset 1px 1px 0px rgba(255, 255, 255, 1),
        inset -1px -1px 0px rgba(0, 0, 0, 0.03),
        inset 0 0 20px rgba(255, 255, 255, 0.5);

    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.article-card:hover .article-inner {
    background: rgba(252, 252, 252, 0.95);
    box-shadow:
        0 8px 32px rgba(0, 0, 0, 0.08),
        0 2px 6px rgba(0, 0, 0, 0.04),
        inset 1px 1px 0px rgba(255, 255, 255, 1),
        inset -1px -1px 0px rgba(0, 0, 0, 0.03),
        inset 0 0 30px rgba(255, 255, 255, 0.6);
}

.article-banner {
    width: 100%;
    height: 180px;
    background-size: cover;
    background-position: center;
    position: relative;
}

.article-banner::after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 0;
    right: 0;
    height: 80%;
    background: linear-gradient(to top, rgba(252, 252, 252, 1) 0%, rgba(252, 252, 252, 0.9) 30%, rgba(252, 252, 252, 0.5) 60%, transparent 100%);
}

.article-content {
    padding: 20px 24px 24px;
    position: relative;
    margin-top: -30px;
    z-index: 1;
}

.article-tag {
    display: inline-block;
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--color-text-secondary);
    background: rgba(0, 0, 0, 0.05);
    padding: 4px 10px;
    border-radius: 100px;
    margin-bottom: 12px;
}

.article-title {
    font-size: 18px;
    font-weight: 600;
    color: var(--color-text);
    letter-spacing: -0.02em;
    line-height: 1.3;
    margin-bottom: 8px;
}

.article-excerpt {
    font-size: 14px;
    color: var(--color-text-secondary);
    line-height: 1.5;
    margin-bottom: 20px;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

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

.article-author {
    display: flex;
    align-items: center;
    gap: 8px;
}

.author-avatar {
    width: 24px;
    height: 24px;
    border-radius: 50%;
    object-fit: cover;
}

.author-name {
    font-size: 13px;
    font-weight: 500;
    color: var(--color-text);
}

.article-date {
    font-size: 12px;
    color: var(--color-text-secondary);
    font-weight: 500;
}

@media (max-width: 900px) {
    .articles-grid {
        grid-template-columns: 1fr;
    }
}

/* Portfolio Grid */
.portfolio-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 24px;
}

.portfolio-card {
    text-decoration: none;
    display: block;
    border-radius: 24px;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    aspect-ratio: 16 / 9;
}

.portfolio-card:hover {
    transform: translateY(-2px) scale(1.01);
}

.portfolio-inner {
    position: relative;
    height: 100%;
    border-radius: 24px;
    overflow: hidden;

    /* White liquid glass */
    background: rgba(252, 252, 252, 1);
    backdrop-filter: blur(40px) saturate(180%);
    -webkit-backdrop-filter: blur(40px) saturate(180%);

    /* Liquid glass shadows - no border */
    box-shadow:
        0 4px 24px rgba(0, 0, 0, 0.06),
        0 1px 3px rgba(0, 0, 0, 0.02);

    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.portfolio-card:hover .portfolio-inner {
    background: rgba(252, 252, 252, 1);
    box-shadow:
        0 8px 32px rgba(0, 0, 0, 0.1),
        0 2px 6px rgba(0, 0, 0, 0.04);
}

.portfolio-banner {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 60%;
    background-size: cover;
    background-position: center;
}

.portfolio-banner::after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 0;
    right: 0;
    height: 80%;
    background: linear-gradient(to top, rgba(252, 252, 252, 1) 0%, rgba(252, 252, 252, 0.9) 30%, rgba(252, 252, 252, 0.5) 60%, transparent 100%);
}

.portfolio-content {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    padding: 24px;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
}

.portfolio-logo {
    width: 64px;
    height: 64px;
    border-radius: 14px;
    object-fit: cover;
    flex-shrink: 0;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    margin-bottom: 16px;
}

.portfolio-content h3 {
    font-size: 20px;
    font-weight: 600;
    color: var(--color-text);
    letter-spacing: -0.02em;
    margin-bottom: 8px;
}

.portfolio-desc {
    font-size: 14px;
    color: var(--color-text-secondary);
    font-weight: 400;
    line-height: 1.5;
}

@media (max-width: 900px) {
    .portfolio-grid {
        grid-template-columns: 1fr;
    }
}

/* Contact Section */
.contact-info {
    display: flex;
    flex-direction: column;
    gap: 16px;
    max-width: 400px;
}

.glass-panel {
    padding: 24px;
    border-radius: 24px;
    background: rgba(252, 252, 252, 0.85);
    backdrop-filter: blur(40px) saturate(180%);
    -webkit-backdrop-filter: blur(40px) saturate(180%);
    border: 1px solid rgba(255, 255, 255, 0.9);
    box-shadow:
        0 4px 24px rgba(0, 0, 0, 0.04),
        0 1px 3px rgba(0, 0, 0, 0.02),
        inset 1px 1px 0px rgba(255, 255, 255, 1),
        inset -1px -1px 0px rgba(0, 0, 0, 0.03),
        inset 0 0 20px rgba(255, 255, 255, 0.5);
}

.contact-link {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 16px;
    color: var(--color-text);
    text-decoration: none;
    border-radius: 12px;
    transition: all 0.2s ease;
}

.contact-link:hover {
    background: rgba(0, 0, 0, 0.04);
}

.contact-link svg {
    color: var(--color-text-secondary);
    flex-shrink: 0;
}

.contact-link span {
    font-size: 14px;
    font-weight: 500;
}

/* Simple Text (for Investments) */
.simple-text {
    font-size: 15px;
    color: var(--color-text-secondary);
    font-weight: 400;
}

/* Simple Contact Links */
.contact-simple {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.contact-link-simple {
    display: flex;
    align-items: center;
    gap: 10px;
    color: var(--color-text);
    text-decoration: none;
    font-size: 14px;
    font-weight: 500;
    transition: opacity 0.2s ease;
}

.contact-link-simple:hover {
    opacity: 0.7;
}

.contact-link-simple svg {
    color: var(--color-text-secondary);
}

/* Coming Soon */
.coming-soon {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 200px;
    border-radius: 24px;
    background: rgba(252, 252, 252, 0.85);
    backdrop-filter: blur(40px) saturate(180%);
    -webkit-backdrop-filter: blur(40px) saturate(180%);
    border: 1px solid rgba(255, 255, 255, 0.9);
    box-shadow:
        0 4px 24px rgba(0, 0, 0, 0.04),
        0 1px 3px rgba(0, 0, 0, 0.02),
        inset 1px 1px 0px rgba(255, 255, 255, 1),
        inset -1px -1px 0px rgba(0, 0, 0, 0.03),
        inset 0 0 20px rgba(255, 255, 255, 0.5);
}

.coming-soon p {
    color: var(--color-text-secondary);
    font-size: 15px;
    font-weight: 500;
}

/* Responsive Design */
@media (max-width: 1024px) {
    .main-content {
        padding: 40px 40px;
    }

    .members-grid {
        grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
        gap: 20px;
    }
}

@media (max-width: 768px) {
    :root {
        --sidebar-width: 0px;
    }

    .sidebar {
        position: fixed;
        left: 0;
        right: 0;
        bottom: 0;
        top: auto;
        width: 100%;
        height: auto;
        padding: 8px 16px;
        padding-bottom: max(8px, env(safe-area-inset-bottom));
        flex-direction: row;
        justify-content: center;
        align-items: center;
        border-right: none;
        border-top: none;

        /* Mobile liquid glass effect */
        background: rgba(252, 252, 252, 0.85);
        backdrop-filter: blur(40px) saturate(180%);
        -webkit-backdrop-filter: blur(40px) saturate(180%);
        box-shadow:
            inset 0px 1px 0px rgba(255, 255, 255, 0.9),
            0 -4px 24px rgba(0, 0, 0, 0.04);
    }

    .sidebar-top {
        flex-direction: row;
        align-items: center;
        gap: 0;
        flex: 1;
        width: 100%;
    }

    .logo-link {
        display: none;
    }

    .search-container {
        display: none;
    }

    .nav {
        flex-direction: row;
        gap: 0;
        justify-content: space-around;
        flex: 1;
        width: 100%;
    }

    .nav-item {
        padding: 10px 16px;
        font-size: 13px;
        text-align: center;
    }

    .sidebar-bottom {
        display: none;
    }

    .main-content {
        margin-left: 0;
        padding: 24px 20px 100px;
    }

    .section-title {
        font-size: 28px;
    }

    .members-grid {
        grid-template-columns: 1fr;
        gap: 16px;
    }

    .card-inner {
        padding: 16px;
    }

    .member-img {
        width: 48px;
        height: 48px;
    }
}

/* Search highlight */
.search-highlight {
    position: relative;
}

.search-highlight::before {
    content: '';
    position: absolute;
    top: -4px;
    left: -4px;
    right: -4px;
    bottom: -4px;
    border-radius: inherit;
    border: 3px solid #007AFF;
    animation: pulse-highlight 2s ease-in-out infinite;
    pointer-events: none;
}

@keyframes pulse-highlight {
    0%, 100% {
        opacity: 0.2;
    }
    50% {
        opacity: 1;
    }
}

/* Background with soft gradients for liquid glass to blur */
body::before {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background:
        radial-gradient(ellipse at 0% 0%, rgba(180, 180, 220, 0.15) 0%, transparent 50%),
        radial-gradient(ellipse at 100% 0%, rgba(220, 180, 180, 0.12) 0%, transparent 50%),
        radial-gradient(ellipse at 50% 100%, rgba(180, 220, 200, 0.1) 0%, transparent 50%),
        radial-gradient(ellipse at 30% 60%, rgba(217, 217, 217, 0.2) 0%, transparent 40%),
        radial-gradient(ellipse at 70% 40%, rgba(200, 200, 220, 0.15) 0%, transparent 40%);
    pointer-events: none;
    z-index: -1;
}
