/* =============================================================
   JUNGLESS — style.css
   Vanilla CSS — no frameworks
   ============================================================= */

/* Fonts */
@font-face {
    font-family: "Euclid";
    src: url("1.woff2") format("woff2");
    font-weight: 400;
    font-style: normal;
    font-display: swap;
}
@font-face {
    font-family: "Euclid";
    src: url("2.woff2") format("woff2");
    font-weight: 500;
    font-style: normal;
    font-display: swap;
}

/* =============================================================
   CSS Variables
   ============================================================= */
:root {
    --accent: #dbe771;
    --accent-dark: #c8d45a;
    --accent-text: #192007;
    --bg-hero: #e2e2e2;
    --bg-page: #f7f8fa;
    --bg-surface: #ffffff;
    --bg-nav: #e2e2e2;
    --text-primary: #111827;
    --text-muted: #6b7280;
    --text-subtle: #5e6166;
    --border: #e5e7eb;
    --shadow-card: 0 1px 3px rgba(0, 0, 0, 0.06), 0 1px 2px rgba(0, 0, 0, 0.04);
    --shadow-hover:
        0 2px 10px rgba(0, 0, 0, 0.06), 0 1px 3px rgba(0, 0, 0, 0.03);
    --radius: 12px;
    --radius-sm: 8px;
    --radius-pill: 9999px;
    --nav-h: 64px;
    --filter-h: 56px;
    --font: "Euclid", system-ui, -apple-system, sans-serif;
}

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

html {
    scroll-behavior: smooth;
    overflow-x: clip;
}

body {
    font-family: var(--font);
    font-size: 15px;
    line-height: 1.6;
    color: var(--text-primary);
    background: var(--bg-page);
    -webkit-font-smoothing: antialiased;
    max-width: 100vw;
    overflow-x: hidden;
}

a {
    color: inherit;
    text-decoration: none;
}
button {
    font-family: var(--font);
    cursor: pointer;
    border: none;
    background: none;
}
input,
select {
    font-family: var(--font);
}
img {
    max-width: 100%;
    height: auto;
    display: block;
}

/* =============================================================
   Navigation
   ============================================================= */
.nav {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 100;
    height: var(--nav-h);
    background: #fbf6e0e3;
    backdrop-filter: blur(20px) saturate(180%);
    -webkit-backdrop-filter: blur(20px) saturate(180%);
    border-bottom: 1px solid rgba(17, 24, 39, 0.08);
    width: 100vw;
}

.nav-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 100%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

.nav-logo {
    display: flex;
    align-items: center;
    gap: 9px;
    font-size: 17px;
    font-weight: 500;
    color: var(--text-primary);
    letter-spacing: -0.025em;
}

.nav-logo-dot {
    width: 9px;
    height: 9px;
    border-radius: 50%;
    background: var(--accent);
    flex-shrink: 0;
}

.nav-links {
    display: none;
    align-items: center;
    gap: 2px;
    list-style: none;
}

.nav-links a {
    color: rgba(17, 24, 39, 0.72);
    font-size: 14px;
    padding: 6px 12px;
    border-radius: var(--radius-sm);
    transition:
        color 0.15s,
        background 0.15s;
}
.nav-links a:hover {
    color: var(--text-primary);
    background: rgba(17, 24, 39, 0.08);
}

.nav-cta {
    display: none;
    align-items: center;
    gap: 6px;
    background: var(--accent);
    color: var(--accent-text);
    font-size: 14px;
    font-weight: 500;
    padding: 8px 18px;
    border-radius: var(--radius-sm);
    transition:
        background 0.15s,
        transform 0.1s;
    white-space: nowrap;
    letter-spacing: -0.01em;
}
.nav-cta:hover {
    background: var(--accent-dark);
}
.nav-cta:active {
    transform: translateY(1px);
}

.nav-hamburger {
    display: flex;
    flex-direction: column;
    gap: 5px;
    padding: 8px;
    cursor: pointer;
}
.nav-hamburger span {
    display: block;
    width: 20px;
    height: 1.5px;
    background: rgba(17, 24, 39, 0.78);
    border-radius: 2px;
    transition: all 0.2s;
}

/* Mobile nav drawer */
.nav-mobile-menu {
    display: none;
    position: fixed;
    top: var(--nav-h);
    left: 0;
    right: 0;
    background: var(--bg-nav);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-bottom: 1px solid rgba(17, 24, 39, 0.08);
    padding: 12px 20px 20px;
    z-index: 99;
}
.nav.is-open .nav-mobile-menu {
    display: block;
}
.nav-mobile-menu ul {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 2px;
}
.nav-mobile-menu a {
    display: block;
    color: rgba(17, 24, 39, 0.82);
    font-size: 15px;
    padding: 10px 12px;
    border-radius: var(--radius-sm);
    transition:
        background 0.15s,
        color 0.15s;
}
.nav-mobile-menu a:hover {
    background: rgba(17, 24, 39, 0.08);
    color: var(--text-primary);
}
.nav-mobile-menu .nav-cta-mobile {
    display: block;
    margin-top: 10px;
    background: var(--accent);
    color: var(--accent-text);
    font-weight: 500;
    text-align: center;
    padding: 11px 16px;
    border-radius: var(--radius-sm);
}

/* Hamburger animated to X */
.nav.is-open .nav-hamburger span:nth-child(1) {
    transform: translateY(7px) rotate(45deg);
}
.nav.is-open .nav-hamburger span:nth-child(2) {
    opacity: 0;
}
.nav.is-open .nav-hamburger span:nth-child(3) {
    transform: translateY(-7px) rotate(-45deg);
}

@media (max-width: 1023px) {
    .nav-hamburger {
        display: flex;
    }
}

@media (min-width: 1024px) {
    .nav-inner {
        padding: 0 32px;
    }
    .nav-links {
        display: flex;
    }
    .nav-cta {
        display: flex;
    }
    .nav-hamburger {
        display: none;
    }
    .nav-mobile-menu {
        display: none !important;
    }
}

/* =============================================================
   Hero
   ============================================================= */
.hero {
    padding: calc(var(--nav-h) + 48px) 20px 56px;
    text-align: center;
    position: relative;
    overflow: hidden;
}

.hero::before {
    content: "";
    position: absolute;
    inset: 0;
    background-color: #fbf6e08c;
    background-size: 44px 44px;
    pointer-events: none;
}

.hero::after {
    content: "";
    position: absolute;
    top: 35%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 1100px;
    height: 640px;
    background: radial-gradient(
        ellipse at center,
        rgba(255, 255, 255, 0.36) 0%,
        rgba(255, 255, 255, 0.21) 42%,
        transparent 68%
    );
    pointer-events: none;
}

.hero-inner {
    position: relative;
    z-index: 1;
    max-width: 800px;
    margin: 0 auto;
}

.hero-badge {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    background: rgba(219, 231, 113, 0.34);
    border: 1px solid rgba(154, 171, 49, 0.4);
    color: #4c5e16;
    font-size: 13px;
    font-weight: 500;
    padding: 5px 14px;
    border-radius: var(--radius-pill);
    margin-bottom: 30px;
    letter-spacing: 0.01em;
}

.hero h1 {
    font-size: clamp(30px, 5.5vw, 64px);
    font-weight: 500;
    color: #000;
    line-height: 1.08;
    letter-spacing: -0.035em;
    margin-bottom: 18px;
}

.hero h1 .accent {
    background-color: var(--accent);
    padding: 0 6px 2px;
}

.hero-sub {
    color: #000;
    font-size: clamp(15px, 2vw, 17.5px);
    max-width: 480px;
    margin: 0 auto 36px;
    line-height: 1.65;
}

/* Search Card */
.search-card {
    background: #fff;
    border-radius: 14px;
    padding: 6px;
    max-width: 740px;
    margin: 0 auto 20px;
    box-shadow:
        0 0 0 1px rgba(0, 0, 0, 0.07),
        0 8px 40px rgba(0, 0, 0, 0.22);
}

.search-bar {
    display: flex;
    flex-direction: column;
    gap: 0;
}

.search-input-wrap {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 11px 14px;
}

.search-input-icon {
    width: 18px;
    height: 18px;
    color: var(--text-subtle);
    flex-shrink: 0;
}

.search-input-wrap input {
    border: none;
    outline: none;
    font-size: 15px;
    color: var(--text-primary);
    width: 100%;
    background: transparent;
    min-width: 0;
}
.search-input-wrap input::placeholder {
    color: var(--text-subtle);
}

.search-divider-h {
    height: 1px;
    background: var(--border);
    margin: 0 14px;
}

.search-divider-v {
    display: none;
}

.search-bar-actions {
    padding: 6px 6px 6px;
}

.btn-search {
    width: 100%;
    background: var(--accent);
    color: var(--accent-text);
    font-size: 14.5px;
    font-weight: normal;
    padding: 12px 24px;
    border-radius: var(--radius-sm);
    transition:
        background 0.15s,
        transform 0.1s;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    letter-spacing: -0.01em;
}
.btn-search:hover {
    background: var(--accent-dark);
}
.btn-search:active {
    transform: translateY(1px);
}

@media (min-width: 680px) {
    .search-bar {
        flex-direction: row;
        align-items: center;
    }
    .search-input-wrap {
        flex: 1;
        padding: 8px 16px;
    }
    .search-divider-h {
        display: none;
    }
    .search-divider-v {
        display: block;
        width: 1px;
        height: 26px;
        background: var(--border);
        flex-shrink: 0;
    }
    .search-bar-actions {
        padding: 6px;
        flex-shrink: 0;
    }
    .btn-search {
        width: auto;
        white-space: nowrap;
    }
}

/* =============================================================
   Jobs Layout + Sidebar Value Props
   ============================================================= */
.jobs-layout {
    max-width: 1220px;
    margin: 0 auto;
    padding: 32px 20px 80px;
    display: grid;
    grid-template-columns: minmax(0, 1fr);
    gap: 24px;
    align-items: start;
}

.jobs-section {
    min-width: 0;
}

.jobs-sidebar.value-props {
    background: transparent;
    border: 0;
    padding: 0;
}

.value-props-inner {
    max-width: none;
    margin: 0;
    display: grid;
    grid-template-columns: 1fr;
    gap: 12px;
}

.value-card {
    background: var(--bg-surface);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 20px 22px;
    transition: box-shadow 0.2s;
}
.value-card:hover {
    box-shadow: var(--shadow-hover);
}

.value-icon {
    font-size: 18px;
    display: block;
    margin-bottom: 10px;
    line-height: 1;
    color: #4c5e16;
    font-weight: 500;
}

.value-card h3 {
    font-size: 15px;
    font-weight: 500;
    color: var(--text-primary);
    margin-bottom: 6px;
    letter-spacing: -0.01em;
}

.value-card p {
    font-size: 13px;
    color: var(--text-muted);
    line-height: 1.6;
}

@media (min-width: 1080px) {
    .jobs-layout {
        grid-template-columns: minmax(0, 1fr) 320px;
        gap: 28px;
    }

    .jobs-sidebar .value-props-inner {
        position: sticky;
        top: calc(var(--nav-h) + var(--filter-h) + 16px);
    }
}
/* =============================================================
   Filter Bar
   ============================================================= */
.filter-bar {
    background: var(--bg-surface);
    border-bottom: 1px solid var(--border);
    position: sticky;
    top: var(--nav-h);
    z-index: 90;
    transition: box-shadow 0.2s;
}

.filter-bar.is-sticky {
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.07);
}

.filter-bar-inner {
    max-width: 1140px;
    margin: 0 auto;
    padding: 0 20px;
    display: flex;
    align-items: center;
    gap: 6px;
    overflow-x: auto;
    scrollbar-width: none;
    -ms-overflow-style: none;
    min-height: var(--filter-h);
}
.filter-bar-inner::-webkit-scrollbar {
    display: none;
}

/* Filter Groups */
.filter-group {
    flex-shrink: 0;
    /* position: static — dropdowns are position: fixed via JS */
}

.filter-btn {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 7px 13px;
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    background: var(--bg-surface);
    color: var(--text-primary);
    font-size: 13.5px;
    font-weight: 400;
    cursor: pointer;
    white-space: nowrap;
    transition:
        border-color 0.15s,
        background 0.15s;
    user-select: none;
}
.filter-btn:hover {
    border-color: #d1d5db;
    background: #fafafa;
}
.filter-btn.is-active {
    border-color: rgba(208, 252, 0, 0.5);
    background: rgba(219, 231, 113, 0.34);
    color: #374614;
}

.filter-btn svg {
    width: 13px;
    height: 13px;
    color: var(--text-subtle);
    transition: transform 0.2s;
    flex-shrink: 0;
}
.filter-group.is-open .filter-btn svg {
    transform: rotate(180deg);
}

.filter-dropdown {
    position: fixed; /* fixed = not clipped by overflow containers */
    top: 0; /* overridden by JS */
    left: 0; /* overridden by JS */
    background: var(--bg-surface);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 6px;
    min-width: 196px;
    box-shadow:
        0 4px 24px rgba(0, 0, 0, 0.1),
        0 1px 4px rgba(0, 0, 0, 0.05);
    z-index: 500;
    display: none;
    animation: dropIn 0.15s ease;
}
.filter-group.is-open .filter-dropdown {
    display: block;
}

@keyframes dropIn {
    from {
        opacity: 0;
        transform: translateY(-6px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.filter-option {
    display: flex;
    align-items: center;
    gap: 9px;
    padding: 7px 10px;
    border-radius: var(--radius-sm);
    cursor: pointer;
    font-size: 13.5px;
    color: var(--text-primary);
    transition: background 0.1s;
    user-select: none;
}
.filter-option:hover {
    background: #f9fafb;
}

.filter-option input[type="checkbox"] {
    width: 15px;
    height: 15px;
    accent-color: var(--accent);
    flex-shrink: 0;
    cursor: pointer;
    border-radius: 3px;
}

.filter-bar-end {
    margin-left: auto;
    padding-left: 10px;
    display: flex;
    align-items: center;
    gap: 10px;
    flex-shrink: 0;
}

.btn-clear-all {
    font-size: 13px;
    color: var(--text-muted);
    cursor: pointer;
    padding: 6px 8px;
    border-radius: var(--radius-sm);
    transition: color 0.15s;
    background: none;
    border: none;
    white-space: nowrap;
}
.btn-clear-all:hover {
    color: var(--text-primary);
}

/* =============================================================
   Jobs Section
   ============================================================= */
.jobs-section {
    min-width: 0;
}

.jobs-header {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 20px;
}

.jobs-title {
    font-size: 19px;
    font-weight: 500;
    color: var(--text-primary);
    letter-spacing: -0.02em;
}

.jobs-count {
    font-size: 13px;
    color: var(--text-muted);
}

/* Skeleton */
.job-skeleton {
    background: var(--bg-surface);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 20px 24px;
    margin-bottom: 8px;
    display: flex;
    gap: 16px;
    align-items: flex-start;
}

.skeleton-logo {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    flex-shrink: 0;
    background: linear-gradient(90deg, #f0f0f0 25%, #e8e8e8 50%, #f0f0f0 75%);
    background-size: 200% 100%;
    animation: shimmer 1.4s infinite;
}

.skeleton-content {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 9px;
    padding-top: 4px;
}

.skeleton-line {
    height: 13px;
    border-radius: 6px;
    background: linear-gradient(90deg, #f0f0f0 25%, #e8e8e8 50%, #f0f0f0 75%);
    background-size: 200% 100%;
    animation: shimmer 1.4s infinite;
}
.skeleton-line.w60 {
    width: 60%;
}
.skeleton-line.w40 {
    width: 40%;
}
.skeleton-line.w25 {
    width: 25%;
}

@keyframes shimmer {
    0% {
        background-position: 200% 0;
    }
    100% {
        background-position: -200% 0;
    }
}

/* Job Card */
.job-listing {
    background: var(--bg-surface);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 18px 20px;
    margin-bottom: 8px;
    display: flex;
    align-items: flex-start;
    gap: 16px;
    cursor: pointer;
    transition:
        box-shadow 0.2s,
        transform 0.2s,
        border-color 0.2s;
    position: relative;
}
.job-listing:hover {
    box-shadow: var(--shadow-hover);
    transform: translateY(-1px);
    border-color: #d5d9e0;
}
.job-listing--sponsored {
    border-left: 3px solid var(--accent);
}

.badge-sponsored {
    font-size: 10.5px;
    font-weight: 500;
    padding: 2px 8px;
    border-radius: var(--radius-pill);
    letter-spacing: 0.025em;
    text-transform: uppercase;
    color: var(--text-muted);
    background: #f3f4f6;
    border: 1px solid var(--border);
}

/* Company Logo */
.company-logo {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    background: #f3f4f6;
    border: 1px solid #e9ebee;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    flex-shrink: 0;
}

.company-logo img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    border-radius: 50%;
}

.company-initials {
    font-size: 14px;
    font-weight: 500;
    color: var(--text-primary);
    background: linear-gradient(135deg, #5a6d18 0%, #728724 100%);
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    letter-spacing: 0.02em;
}

/* Job Details */
.job-details {
    flex: 1;
    min-width: 0;
}

.job-details h3 {
    font-size: 15.5px;
    font-weight: 500;
    color: var(--text-primary);
    letter-spacing: -0.01em;
    margin-bottom: 4px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.company-info {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 5px;
    margin-bottom: 10px;
    font-size: 13px;
    color: var(--text-muted);
}

.company-info .company-name {
    font-weight: 500;
    color: var(--text-primary);
}

.company-info .dot-sep {
    color: #d1d5db;
}

.job-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 5px;
}

.tag {
    display: inline-flex;
    align-items: center;
    font-size: 12px;
    padding: 3px 9px;
    border: 1px solid var(--border);
    border-radius: var(--radius-pill);
    color: var(--text-muted);
    white-space: nowrap;
    background: transparent;
    line-height: 1.4;
}

.tag.job-type {
    background: rgba(219, 231, 113, 0.28);
    border-color: rgba(154, 171, 49, 0.34);
    color: #3a4a0f;
}

/* Job Meta (right side) */
.job-meta {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 7px;
    flex-shrink: 0;
    padding-left: 8px;
}

.post-date {
    font-size: 12px;
    color: var(--text-subtle);
    white-space: nowrap;
}

.badge-new {
    background: var(--accent);
    color: var(--accent-text);
    font-size: 10.5px;
    font-weight: 500;
    padding: 2px 8px;
    border-radius: var(--radius-pill);
    letter-spacing: 0.025em;
    text-transform: uppercase;
}

.job-button {
    display: none;
    align-items: center;
    gap: 4px;
    font-size: 13px;
    font-weight: 500;
    color: var(--text-primary);
    background: #f3f4f6;
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    padding: 6px 13px;
    transition: background 0.15s;
    white-space: nowrap;
    cursor: pointer;
    text-decoration: none;
}
.job-listing:hover .job-button {
    display: none;
}
.job-button:hover {
    background: #e9ebee;
}

/* Load More */
.load-more-wrap {
    text-align: center;
    margin-top: 24px;
}

.btn-load-more {
    background: var(--bg-surface);
    border: 1px solid var(--border);
    color: var(--text-primary);
    font-size: 13.5px;
    font-weight: 500;
    padding: 11px 28px;
    border-radius: var(--radius);
    cursor: pointer;
    transition:
        background 0.15s,
        box-shadow 0.15s;
}
.btn-load-more:hover {
    background: #f5f6f8;
    box-shadow: var(--shadow-card);
}

/* Empty State */
.empty-state {
    text-align: center;
    padding: 64px 24px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 12px;
}
.empty-state-icon {
    width: 56px;
    height: 56px;
    border-radius: 50%;
    background: rgba(219, 231, 113, 0.22);
    border: 1px solid rgba(154, 171, 49, 0.28);
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 4px;
}
.empty-state-icon svg {
    width: 24px;
    height: 24px;
    color: #4c5e16;
}
.empty-state h3 {
    font-size: 17px;
    font-weight: 500;
    color: var(--text-primary);
    letter-spacing: -0.01em;
    margin: 0;
}
.empty-state p {
    font-size: 13.5px;
    color: var(--text-muted);
    margin: 0;
}
.btn-reset-search {
    margin-top: 4px;
    background: var(--bg-surface);
    border: 1px solid var(--border);
    color: var(--text-primary);
    font-size: 13.5px;
    font-weight: 500;
    padding: 9px 20px;
    border-radius: var(--radius);
    cursor: pointer;
    transition:
        background 0.15s,
        box-shadow 0.15s;
    font-family: var(--font);
}
.btn-reset-search:hover {
    background: #f5f6f8;
    box-shadow: var(--shadow-card);
}

/* =============================================================
   Job Panel (Slide-in Drawer)
   ============================================================= */
.panel-overlay {
    position: fixed;
    inset: 0;
    background: rgba(13, 17, 23, 0.45);
    z-index: 200;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.25s ease;
}
.panel-overlay.is-open {
    opacity: 1;
    pointer-events: auto;
}

.job-panel {
    position: fixed;
    top: 0;
    right: 0;
    bottom: 0;
    width: 100%;
    max-width: 560px;
    background: var(--bg-surface);
    z-index: 201;
    transform: translateX(100%);
    transition: transform 0.3s cubic-bezier(0.32, 0.72, 0, 1);
    display: flex;
    flex-direction: column;
    overflow: hidden;
    box-shadow: -4px 0 40px rgba(0, 0, 0, 0.12);
}
.job-panel.is-open {
    transform: translateX(0);
}

.panel-header {
    padding: 18px 20px;
    border-bottom: 1px solid var(--border);
    display: flex;
    align-items: flex-start;
    gap: 14px;
    flex-shrink: 0;
}

.panel-logo {
    width: 50px;
    height: 50px;
    border-radius: 50%;
    background: #f3f4f6;
    border: 1px solid #e9ebee;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    flex-shrink: 0;
}
.panel-logo img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    border-radius: 50%;
}

.panel-title-group {
    flex: 1;
    min-width: 0;
}

.panel-job-title {
    font-size: 17px;
    font-weight: 500;
    color: var(--text-primary);
    letter-spacing: -0.02em;
    line-height: 1.3;
    margin-bottom: 3px;
}

.panel-company-name {
    font-size: 13.5px;
    color: var(--text-muted);
}

.panel-close {
    width: 30px;
    height: 30px;
    border-radius: 50%;
    background: #f3f4f6;
    border: 1px solid var(--border);
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    color: var(--text-muted);
    flex-shrink: 0;
    font-size: 15px;
    line-height: 1;
    transition:
        background 0.15s,
        color 0.15s;
}
.panel-close:hover {
    background: #e9ebee;
    color: var(--text-primary);
}

.panel-body {
    flex: 1;
    overflow-y: auto;
    padding: 20px;
    scroll-behavior: smooth;
}

.panel-info-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px;
    margin-bottom: 18px;
}

.panel-info-item {
    background: #f7f8fa;
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    padding: 11px 13px;
}

.panel-info-label {
    font-size: 10.5px;
    font-weight: 500;
    color: var(--text-subtle);
    text-transform: uppercase;
    letter-spacing: 0.07em;
    margin-bottom: 4px;
}

.panel-info-value {
    font-size: 13.5px;
    font-weight: 500;
    color: var(--text-primary);
    line-height: 1.4;
}

.panel-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    margin-bottom: 20px;
}

.panel-section-title {
    font-size: 13.5px;
    font-weight: 500;
    color: var(--text-primary);
    margin-bottom: 12px;
    padding-bottom: 8px;
    border-bottom: 1px solid var(--border);
    letter-spacing: -0.01em;
}

.panel-description {
    font-size: 13.5px;
    color: var(--text-primary);
    line-height: 1.75;
}
.panel-description p {
    margin-bottom: 12px;
}
.panel-description ul,
.panel-description ol {
    padding-left: 18px;
    margin-bottom: 12px;
}
.panel-description li {
    margin-bottom: 5px;
}
.panel-description h2,
.panel-description h3,
.panel-description h4 {
    font-weight: 500;
    margin-bottom: 8px;
    margin-top: 16px;
    letter-spacing: -0.01em;
}

.panel-footer {
    padding: 14px 20px;
    border-top: 1px solid var(--border);
    flex-shrink: 0;
    background: var(--bg-surface);
}

.btn-apply {
    display: block;
    width: 100%;
    background: var(--accent);
    color: var(--accent-text);
    text-align: center;
    font-size: 15px;
    font-weight: 500;
    padding: 13px 24px;
    border-radius: var(--radius);
    transition:
        background 0.15s,
        transform 0.1s;
    letter-spacing: -0.01em;
}
.btn-apply:hover {
    background: var(--accent-dark);
}
.btn-apply:active {
    transform: translateY(1px);
}

@media (max-width: 1023px) {
    .job-panel {
        left: 0;
        right: 0;
        top: 0;
        bottom: auto;
        width: 100vw;
        max-width: none;
        height: 100dvh;
        height: 100vh; /* fallback for browsers without dvh */
        height: 100dvh;
        transform: translateY(100%);
        box-shadow: none; /* only show shadow when open */
        visibility: hidden; /* prevent any sticky/paint leakage when closed */
    }

    .job-panel.is-open {
        transform: translateY(0);
        box-shadow: 0 -8px 32px rgba(0, 0, 0, 0.18);
        visibility: visible;
        /* safe-area insets for iPhone notch */
        padding-bottom: env(safe-area-inset-bottom, 0);
    }

    /* Remove sticky — flexbox handles header/footer position;
       position:sticky inside overflow:hidden creates paint glitches */
    .panel-header {
        position: relative;
        flex-shrink: 0;
    }

    .panel-footer {
        position: relative;
        flex-shrink: 0;
    }

    .panel-body {
        min-height: 0;
        overflow-y: auto;
        -webkit-overflow-scrolling: touch;
    }
}
/* =============================================================
   Footer
   ============================================================= */
.footer {
    background: #0d1208;
    padding: 56px 20px 32px;
    border-top: none;
}

.footer-inner {
    max-width: 1140px;
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    gap: 36px;
}

.footer-top {
    display: flex;
    flex-direction: column;
    gap: 24px;
}

.footer-logo {
    display: flex;
    align-items: center;
    gap: 9px;
    font-size: 16px;
    font-weight: 500;
    color: #ffffff;
    letter-spacing: -0.025em;
    margin-bottom: 10px;
}

.footer-tagline {
    font-size: 13px;
    color: rgba(255, 255, 255, 0.42);
    max-width: 300px;
    line-height: 1.65;
}

.footer-links {
    display: flex;
    flex-wrap: wrap;
    gap: 18px;
    align-items: center;
}

.footer-links a {
    font-size: 13px;
    color: rgba(255, 255, 255, 0.42);
    transition: color 0.15s;
}
.footer-links a:hover {
    color: var(--accent);
}

.footer-bottom {
    border-top: 1px solid rgba(255, 255, 255, 0.08);
    padding-top: 24px;
    font-size: 12px;
    color: rgba(255, 255, 255, 0.22);
}

@media (min-width: 768px) {
    .footer-top {
        flex-direction: row;
        justify-content: space-between;
        align-items: flex-start;
    }
    .footer-links {
        align-items: flex-start;
        flex-direction: column;
        gap: 10px;
    }
}

/* =============================================================
   Legal Pages (CGU / Confidentialité)
   ============================================================= */
.legal-page {
    max-width: 720px;
    margin: 0 auto;
    padding: calc(var(--nav-h) + 56px) 20px 80px;
}

.legal-header {
    margin-bottom: 48px;
    padding-bottom: 28px;
    border-bottom: 1px solid var(--border);
}

.legal-header h1 {
    font-size: clamp(24px, 4vw, 36px);
    font-weight: 500;
    color: var(--text-primary);
    letter-spacing: -0.03em;
    line-height: 1.15;
    margin-bottom: 8px;
}

.legal-date {
    font-size: 13px;
    color: var(--text-subtle);
}

.legal-content h2 {
    font-size: 17px;
    font-weight: 500;
    color: var(--text-primary);
    letter-spacing: -0.02em;
    margin-top: 40px;
    margin-bottom: 12px;
}

.legal-content p {
    font-size: 14.5px;
    color: #374151;
    line-height: 1.75;
    margin-bottom: 14px;
}

.legal-content ul,
.legal-content ol {
    padding-left: 20px;
    margin-bottom: 14px;
}

.legal-content li {
    font-size: 14.5px;
    color: #374151;
    line-height: 1.75;
    margin-bottom: 6px;
}

.legal-content a {
    color: #4c5e16;
    text-decoration: underline;
    text-underline-offset: 2px;
}
.legal-content a:hover {
    color: var(--text-primary);
}

/* =============================================================
   Mobile UX
   ============================================================= */
@media (max-width: 767px) {
    /* Touch targets — 44px minimum height */
    .filter-btn {
        min-height: 40px;
        padding: 8px 13px;
    }
    .btn-search {
        min-height: 44px;
    }
    .nav-hamburger {
        min-width: 44px;
        min-height: 44px;
        justify-content: center;
    }

    /* Hero: tighter vertical spacing on small phones */
    .hero {
        padding-top: calc(var(--nav-h) + 32px);
        padding-bottom: 40px;
    }

    /* Job cards: hide post date on tiny screens to give job title room */
    @media (max-width: 400px) {
        .post-date {
            display: none;
        }
    }

    /* Load more button — full width on mobile for easier tapping */
    .btn-load-more {
        width: 100%;
        padding: 14px 24px;
    }
}

/* =============================================================
   Focus States
   ============================================================= */
:focus-visible {
    outline: 2px solid var(--accent);
    outline-offset: 2px;
}
input:focus {
    outline: none;
}

/* =============================================================
   Utilities
   ============================================================= */
.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    border: 0;
}
