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

:root {
    --bg: #0a0a0f;
    --bg-rgb: 10, 10, 15;
    --card-bg: rgba(255, 255, 255, 0.02);
    --card-border: rgba(255, 255, 255, 0.06);
    --card-hover-bg: rgba(255, 255, 255, 0.04);
    --card-hover-border: rgba(255, 255, 255, 0.12);
    --text: #e8e8ec;
    --text-secondary: #9a9aab;
    --text-muted: #5a5a6e;
    --accent: #6366f1;
    --accent-glow: rgba(99, 102, 241, 0.15);
    --logo-shadow: 0 2px 8px rgba(0,0,0,0.6);
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;
    background: var(--bg);
    color: var(--text);
    line-height: 1.5;
    min-height: 100vh;
}

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

/* HEADER */

.site-header {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 48px 24px 0;
    gap: 20px;
}

#logo a {
    display: inline-flex;
    align-items: center;
}

.logo-text {
    font-family: 'Space Grotesk', sans-serif;
    font-size: 32px;
    font-weight: 700;
    letter-spacing: -0.03em;
    color: #fff;
}

.logo-orbit {
    position: relative;
    display: inline-block;
}

.logo-orbit::after {
    content: '';
    position: absolute;
    top: -2px;
    left: -3px;
    right: -3px;
    bottom: -2px;
    border: 1.5px solid rgba(99, 102, 241, 0.7);
    border-radius: 50%;
    transform: rotateX(62deg) rotateZ(-20deg);
    pointer-events: none;
}

.tagline {
    font-size: 14px;
    font-weight: 400;
    color: var(--text-muted);
    letter-spacing: -0.01em;
}

.site-header #search-container {
    width: 100%;
    max-width: 420px;
}

/* CHIP BAR */

.chip-bar {
    max-width: 920px;
    margin: 0 auto;
    padding: 24px 24px 0;
}

/* SEARCH */

#search-container {
    width: 100%;
}

.search-box {
    display: flex;
    align-items: center;
    padding: 12px 18px;
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 12px;
    transition: border-color 0.2s, background 0.2s, box-shadow 0.2s;
}

.search-box:focus-within {
    border-color: rgba(255, 255, 255, 0.25);
    background: rgba(255, 255, 255, 0.06);
    box-shadow: 0 0 0 3px rgba(255, 255, 255, 0.06);
}

.search-icon {
    display: flex;
    align-items: center;
    margin-right: 12px;
    color: var(--text-muted);
    flex-shrink: 0;
}

.search-input {
    flex: 1;
    min-width: 0;
    border: none;
    outline: none;
    font-size: 14px;
    color: var(--text);
    padding: 5px 0;
    font-family: inherit;
    background: transparent;
}

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

.search-clear {
    appearance: none;
    background: rgba(255,255,255,0.08);
    border: none;
    padding: 5px;
    color: var(--text-secondary);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    transition: background 0.15s;
    flex-shrink: 0;
}

.search-clear:hover {
    background: rgba(255,255,255,0.15);
    color: #fff;
}

#active-filters {
    display: flex;
    flex-shrink: 0;
    gap: 5px;
    align-items: center;
    margin-right: 4px;
}
#active-filters:empty { display: none; }
.filter-pill {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 4px 8px 4px 10px;
    background: rgba(99, 102, 241, 0.12);
    border: 1px solid rgba(99, 102, 241, 0.25);
    border-radius: 8px;
    font-size: 12px;
    color: #c4b5fd;
    white-space: nowrap;
}
.filter-pill button {
    display: inline-flex;
    align-items: center;
    background: none;
    border: none;
    padding: 0;
    cursor: pointer;
    color: rgba(255,255,255,0.4);
    transition: color 0.15s;
}
.filter-pill button:hover { color: #fff; }

/* QUICK SEARCH CHIPS */

.quick-searches {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    justify-content: center;
}

.qs-chip {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 7px 14px 7px 11px;
    background: rgba(255,255,255,0.03);
    border: 1px solid rgba(255,255,255,0.07);
    border-radius: 10px;
    color: var(--text-secondary);
    font-size: 12px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s ease;
}

.qs-chip:hover {
    background: rgba(255,255,255,0.07);
    border-color: rgba(255,255,255,0.14);
    color: #fff;
    transform: translateY(-1px);
}

/* COMPANY STRIP */

.company-strip {
    display: none;
    align-items: center;
    justify-content: center;
    gap: 6px;
    padding: 0 0 20px;
    flex-wrap: wrap;
}

@media (max-width: 800px) {
    .company-strip {
        display: flex;
    }
}

.company-pill {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    padding: 5px 12px 5px 6px;
    background: rgba(255,255,255,0.02);
    border: 1px solid rgba(255,255,255,0.06);
    border-radius: 10px;
    cursor: pointer;
    transition: all 0.2s ease;
}

.company-pill:hover {
    background: rgba(255,255,255,0.06);
    border-color: rgba(255,255,255,0.12);
}

.company-pill.active {
    background: var(--accent-glow);
    border-color: rgba(99, 102, 241, 0.35);
}

.company-pill img {
    width: 22px;
    height: 22px;
    border-radius: 6px;
    object-fit: contain;
}

.company-pill span {
    font-size: 11px;
    font-weight: 600;
    color: var(--text-secondary);
    letter-spacing: 0.02em;
}

.company-pill:hover span { color: #fff; }
.company-pill.active span { color: #c4b5fd; }

/* MAIN LAYOUT */

#main-container {
    max-width: 920px;
    margin: 0 auto;
    padding: 32px 24px 60px;
    margin-top: 28px;
}

.content-layout {
    display: flex;
    gap: 24px;
    justify-content: center;
}

/* SIDEBAR */

.sidebar {
    width: 140px;
    flex-shrink: 0;
    padding-top: 6px;
    padding-right: 0;
    border-right: 1px solid rgba(255,255,255,0.06);
    padding-right: 24px;
    position: sticky;
    top: 80px;
    align-self: flex-start;
}

.sidebar-label {
    font-size: 9px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.12em;
    color: var(--text-muted);
    margin-bottom: 10px;
    padding-left: 8px;
}

.sidebar-companies {
    display: flex;
    flex-direction: column;
    gap: 1px;
}

.sidebar-co {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 6px 8px;
    border-radius: 8px;
    cursor: pointer;
    transition: background 0.15s;
}

.sidebar-co:hover {
    background: rgba(255,255,255,0.04);
}

.sidebar-co.active {
    background: var(--accent-glow);
}

.sidebar-co img {
    width: 18px;
    height: 18px;
    border-radius: 5px;
    object-fit: contain;
    flex-shrink: 0;
}

.sidebar-co span {
    font-size: 11px;
    font-weight: 500;
    color: var(--text-secondary);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.sidebar-co:hover span { color: var(--text); }
.sidebar-co.active span { color: #c4b5fd; font-weight: 600; }

.jobs-column {
    flex: 1;
    min-width: 0;
    max-width: 500px;
}

.stats-bar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    color: var(--text-muted);
    font-size: 13px;
    margin-bottom: 16px;
    padding-left: 4px;
}

#stats-text {
    display: inline;
}

.stat-count {
    font-weight: 600;
    color: var(--text-secondary);
}

.stat-query {
    font-weight: 600;
    color: var(--text);
}

.clear-filter {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 18px;
    height: 18px;
    margin-left: 4px;
    background: rgba(255, 255, 255, 0.1);
    border: none;
    border-radius: 50%;
    color: var(--text-secondary);
    font-size: 14px;
    line-height: 1;
    cursor: pointer;
    vertical-align: middle;
    transition: background 0.15s, color 0.15s;
}

.clear-filter:hover {
    background: rgba(255, 255, 255, 0.2);
    color: #fff;
}

/* JOB GRID */

.job-grid {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.job-card {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 14px 16px;
    border-radius: 14px;
    border: 1px solid transparent;
    cursor: pointer;
    transition: all 0.2s ease;
}

.job-card:hover {
    background: var(--card-hover-bg);
    border-color: var(--card-hover-border);
}

.job-logo-wrapper {
    width: 38px;
    height: 38px;
    border-radius: 10px;
    background: rgba(255,255,255,0.04);
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    overflow: hidden;
    transition: transform 0.15s;
}

.job-logo-wrapper:hover {
    transform: scale(1.08);
}

.job-logo {
    width: 75%;
    height: 75%;
    object-fit: contain;
    border-radius: 6px;
}

.job-info {
    flex: 1;
    min-width: 0;
}

.job-card-header {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 3px;
}

.job-company {
    font-size: 11px;
    font-weight: 700;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.1em;
    white-space: nowrap;
    flex-shrink: 0;
}

.job-location {
    font-size: 11px;
    font-weight: 500;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.06em;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.job-location::before {
    content: "\00b7 ";
    margin-right: 2px;
}

.job-title {
    font-size: 15px;
    font-weight: 500;
    color: rgba(255,255,255,0.75);
    letter-spacing: -0.01em;
    line-height: 1.4;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.job-card:hover .job-title {
    color: #fff;
}

.job-new {
    font-size: 11px;
    font-weight: 500;
    color: #34d399;
    white-space: nowrap;
}

.job-new::before {
    content: "\00b7 ";
    margin-right: 2px;
    color: var(--text-muted);
}

.job-star {
    margin-left: auto;
    cursor: pointer;
    opacity: 0;
    transition: opacity 0.2s, transform 0.2s;
    flex-shrink: 0;
    display: flex;
    align-items: center;
}

.job-card:hover .job-star {
    opacity: 0.4;
}

.job-star:hover {
    opacity: 0.7 !important;
    transform: scale(1.15);
}

.job-star.starred {
    opacity: 1 !important;
}

.job-star.starred .star-icon {
    fill: #f59e0b;
    stroke: #f59e0b;
}

.sparkle-icon { display: none; }

.job-star.pop {
    animation: starPop 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
}

@keyframes starPop {
    0%   { transform: scale(1); }
    50%  { transform: scale(1.4); }
    100% { transform: scale(1); }
}

/* PAGINATION */

.pagination {
    margin-top: 40px;
    display: flex;
    justify-content: center;
    gap: 6px;
}

.pagination a {
    padding: 8px 16px;
    border-radius: 8px;
    border: 1px solid rgba(255,255,255,0.08);
    color: var(--text-muted);
    font-weight: 500;
    font-size: 13px;
    transition: all 0.15s;
}

.pagination a:hover {
    color: var(--text);
    border-color: rgba(255,255,255,0.15);
    background: rgba(255,255,255,0.03);
}

.pagination a.active {
    background: var(--accent);
    color: #fff;
    border-color: var(--accent);
}

/* FOOTER */

.site-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    max-width: 720px;
    margin: 0 auto;
    padding: 20px 24px;
    border-top: 1px solid rgba(255,255,255,0.05);
}

.footer-brand {
    font-size: 13px;
    font-weight: 700;
    color: var(--text-secondary);
}

.footer-meta {
    font-size: 12px;
    color: var(--text-muted);
}

.footer-meta span {
    margin: 0 6px;
    opacity: 0.4;
}

.footer-credit {
    font-size: 12px;
    color: var(--text-muted);
}

.footer-credit a {
    color: var(--text-secondary);
    font-weight: 600;
    transition: color 0.15s;
}

.footer-credit a:hover {
    color: #fff;
}

/* MOBILE */

@media (max-width: 800px) {
    .sidebar {
        display: none;
    }
    .content-layout {
        flex-direction: column;
    }
    #main-container {
        max-width: 720px;
    }
}

@media (max-width: 640px) {
    .site-header {
        padding: 20px 16px 0;
        gap: 10px;
    }
    .logo-text {
        font-size: 26px;
    }
    .chip-bar {
        padding: 10px 16px 0;
    }
    .job-title {
        font-size: 14px;
    }
    .job-card {
        padding: 12px;
        gap: 12px;
    }
    .job-logo-wrapper {
        width: 32px;
        height: 32px;
    }
    .company-strip {
        gap: 4px;
    }
    .company-pill span {
        display: none;
    }
    .company-pill {
        padding: 5px;
    }
    .job-star {
        display: none;
    }
    .quick-searches {
        gap: 6px;
    }
}
