/* ==========================================================================
   Hugo PaperMod Theme for JobSphere
   Faithfully crafted after adityatelange/hugo-PaperMod
   Minimal, clean, distraction-free, ultra-fast typography and dark/light modes.
   Fully optimized for desktop and mobile ergonomics.
   ========================================================================== */

:root {
    --gap: 24px;
    --content-gap: 20px;
    --nav-width: 1040px;
    --main-width: 820px;
    --header-height: 62px;
    --footer-height: 60px;
    --radius: 8px;

    /* PaperMod Dark Theme (Default) */
    --theme: rgb(29, 30, 32); /* #1d1e20 */
    --entry: rgb(46, 46, 51); /* #2e2e33 */
    --primary: rgb(218, 218, 219);
    --secondary: rgb(178, 180, 183);
    --tertiary: rgb(65, 66, 68);
    --content: rgb(196, 196, 197);
    --code-block-bg: rgb(46, 46, 51);
    --code-bg: rgb(55, 56, 62);
    --border: rgb(51, 51, 51);
    --accent: #10b981;
    --accent-hover: #059669;
    --accent-salary: #34d399;
    --badge-bg: rgba(255, 255, 255, 0.08);
    --badge-color: var(--primary);
    --shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    --focus-ring: rgba(218, 218, 219, 0.2);
}

body.light {
    /* PaperMod Light Theme */
    --theme: rgb(245, 245, 245);
    --entry: rgb(255, 255, 255);
    --primary: rgb(30, 30, 30);
    --secondary: rgb(85, 85, 85);

    --tertiary: rgb(214, 214, 214);
    --content: rgb(40, 40, 40);
    --code-block-bg: rgb(240, 240, 240);
    --code-bg: rgb(245, 245, 245);
    --border: rgb(230, 230, 230);
    --accent: #047857;
    --accent-hover: #065f46;
    --accent-salary: #065f46;
    --badge-bg: rgba(0, 0, 0, 0.05);
    --badge-color: var(--primary);
    --shadow: 0 2px 8px rgba(0, 0, 0, 0.06);
    --focus-ring: rgba(30, 30, 30, 0.1);
}

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

html {
    font-size: 16px;
    scroll-behavior: smooth;
    -webkit-text-size-adjust: 100%;
}

body {
    background: var(--theme);
    color: var(--content);
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen, Ubuntu, Cantarell, "Open Sans", "Helvetica Neue", sans-serif;
    font-size: 1rem;
    line-height: 1.6;
    word-break: break-word;
    letter-spacing: -0.01em;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    transition: background-color 0.2s ease, color 0.2s ease;
}

a {
    color: var(--primary);
    text-decoration: none;
    transition: color 0.15s ease, opacity 0.15s ease;
}

a:hover {
    color: var(--accent);
}

h1, h2, h3, h4, h5, h6 {
    color: var(--primary);
    line-height: 1.3;
    letter-spacing: -0.02em;
    font-weight: 700;
}

p {
    margin-bottom: 1.25rem;
}

p:last-child {
    margin-bottom: 0;
}

ul, ol {
    margin-bottom: 1.25rem;
    padding-left: 1.5rem;
}

li {
    margin-bottom: 0.35rem;
}

code, kbd, samp, pre {
    font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace;
    font-size: 0.875em;
}

code {
    background: var(--code-bg);
    padding: 2px 6px;
    border-radius: 4px;
    color: var(--primary);
}

/* Layout Containers */
.container {
    max-width: var(--main-width);
    margin: 0 auto;
    padding: 0 var(--gap);
    width: 100%;
}

.container-wide {
    max-width: var(--nav-width);
    margin: 0 auto;
    padding: 0 var(--gap);
    width: 100%;
}

.main {
    flex: 1;
    padding-top: var(--gap);
    padding-bottom: calc(var(--gap) * 2);
}

/* PaperMod Header & Nav */
.header {
    background: var(--theme);
    border-bottom: 1px solid var(--border);
    position: sticky;
    top: 0;
    z-index: 100;
    transition: background-color 0.2s ease, border-color 0.2s ease;
}

.nav {
    display: flex;
    justify-content: space-between;
    align-items: center;
    height: var(--header-height);
    max-width: var(--nav-width);
    margin: 0 auto;
    padding: 0 var(--gap);
}

.logo {
    display: flex;
    align-items: center;
    gap: 12px;
}

.logo a {
    font-size: 1.4rem;
    font-weight: 800;
    color: var(--primary);
    display: inline-flex;
    align-items: center;
    gap: 8px;
    letter-spacing: -0.03em;
}

.logo a .logo-dot {
    color: var(--accent);
}

.logo-switches {
    display: flex;
    align-items: center;
}

#theme-toggle {
    background: transparent;
    border: none;
    cursor: pointer;
    color: var(--secondary);
    padding: 8px;
    border-radius: var(--radius);
    display: flex;
    align-items: center;
    justify-content: center;
    transition: color 0.15s ease, background-color 0.15s ease;
}

#theme-toggle:hover {
    color: var(--primary);
    background: var(--entry);
}

#menu {
    display: flex;
    align-items: center;
    list-style: none;
    margin: 0;
    padding: 0;
    gap: 1.25rem;
}

#menu li a {
    font-size: 0.9375rem;
    color: var(--secondary);
    font-weight: 500;
    padding: 4px 0;
    transition: color 0.15s ease;
}

#menu li a:hover,
#menu li a.active {
    color: var(--primary);
}

#menu li a.active {
    border-bottom: 2px solid var(--primary);
}

/* PaperMod Profile Mode (Home Hero) */
.profile {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    padding: 3rem 1rem 2.5rem;
}

.profile .avatar {
    width: 90px;
    height: 90px;
    border-radius: 50%;
    margin-bottom: 1.25rem;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--entry);
    border: 2px solid var(--border);
    color: var(--accent);
    box-shadow: var(--shadow);
}

.profile h1 {
    font-size: 2.25rem;
    font-weight: 800;
    color: var(--primary);
    margin-bottom: 0.75rem;
    letter-spacing: -0.03em;
}

.profile .subtitle {
    font-size: 1.1rem;
    color: var(--secondary);
    max-width: 600px;
    margin: 0 auto 1.75rem;
    line-height: 1.5;
}

.profile-buttons {
    display: flex;
    gap: 0.75rem;
    flex-wrap: wrap;
    justify-content: center;
    margin-bottom: 2rem;
}

.button-link {
    background: var(--entry);
    border: 1px solid var(--border);
    color: var(--primary);
    padding: 8px 18px;
    border-radius: var(--radius);
    font-size: 0.875rem;
    font-weight: 600;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    transition: all 0.15s ease;
    text-decoration: none;
}

.button-link:hover {
    color: var(--primary);
    background: var(--code-bg);
    border-color: var(--secondary);
    transform: translateY(-1px);
}

.button-link.active {
    background: var(--code-bg);
    border-color: var(--accent);
    color: var(--accent);
}

/* Minimal PaperMod Search Bar */
.searchbox {
    width: 100%;
    max-width: 640px;
    margin: 0 auto 1rem;
}

.searchbox form {
    display: flex;
    align-items: center;
    background: var(--entry);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 6px 12px;
    gap: 10px;
    transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

.searchbox form:focus-within {
    border-color: var(--secondary);
    box-shadow: 0 0 0 3px var(--focus-ring);
}

.searchbox-input-wrap {
    display: flex;
    align-items: center;
    gap: 8px;
    flex: 1;
    min-width: 0;
}

.searchbox input[type="text"] {
    flex: 1;
    width: 100%;
    background: transparent;
    border: none;
    color: var(--primary);
    font-size: 0.95rem;
    padding: 6px 4px;
    outline: none;
    font-family: inherit;
}

.searchbox input[type="text"]::placeholder {
    color: var(--secondary);
}

.searchbox-controls {
    display: flex;
    align-items: center;
    gap: 8px;
}

.searchbox select {
    background: var(--code-bg);
    border: 1px solid var(--border);
    color: var(--primary);
    font-size: 0.85rem;
    padding: 6px 10px;
    border-radius: 6px;
    outline: none;
    cursor: pointer;
}

.searchbox button {
    background: var(--primary);
    color: var(--theme);
    border: none;
    padding: 7px 18px;
    border-radius: 6px;
    font-weight: 600;
    font-size: 0.875rem;
    cursor: pointer;
    transition: opacity 0.15s ease;
    white-space: nowrap;
}

.searchbox button:hover {
    opacity: 0.9;
}

/* PaperMod Post Entry Cards */
.post-entry {
    background: var(--entry);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: var(--gap);
    margin-bottom: var(--gap);
    transition: transform 0.15s ease, box-shadow 0.15s ease, border-color 0.15s ease;
    display: block;
    position: relative;
}

.post-entry:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow);
    border-color: var(--secondary);
}

.entry-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 1rem;
    margin-bottom: 0.65rem;
}

.entry-header h2 {
    font-size: 1.35rem;
    font-weight: 700;
    margin: 0;
    line-height: 1.3;
}

.entry-header h2 a {
    color: var(--primary);
}

.entry-header h2 a:hover {
    color: var(--accent);
}

.entry-salary {
    font-size: 0.95rem;
    font-weight: 700;
    color: var(--accent-salary);
    white-space: nowrap;
    background: rgba(16, 185, 129, 0.1);
    padding: 4px 10px;
    border-radius: 6px;
    border: 1px solid rgba(16, 185, 129, 0.2);
    display: inline-flex;
    align-items: center;
}

body.light .entry-salary {
    color: #065f46;
    background: #ecfdf5;
    border-color: #a7f3d0;
}

.entry-subhead {
    display: flex;
    align-items: center;
    gap: 8px;
    color: var(--secondary);
    font-size: 0.9rem;
    margin-bottom: 0.75rem;
    flex-wrap: wrap;
}

.entry-company {
    font-weight: 600;
    color: var(--primary);
}

.entry-company-avatar {
    width: 22px;
    height: 22px;
    border-radius: 4px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 0.75rem;
    font-weight: 700;
    color: #ffffff;
}

.entry-content {
    color: var(--content);
    font-size: 0.925rem;
    line-height: 1.55;
    margin-bottom: 1rem;
}

.entry-footer {
    display: flex;
    align-items: center;
    gap: 8px;
    color: var(--secondary);
    font-size: 0.8125rem;
    flex-wrap: wrap;
}

.entry-footer .dot-sep {
    color: var(--tertiary);
}

.badge-tag {
    background: var(--code-bg);
    color: var(--primary);
    padding: 2px 8px;
    border-radius: 4px;
    font-size: 0.75rem;
    font-weight: 500;
    border: 1px solid var(--border);
}

.badge-tag.badge-verified {
    color: #93c5fd;
    background: rgba(59, 130, 246, 0.2);
    border-color: rgba(96, 165, 250, 0.4);
}

body.light .badge-tag {
    background: #f1f5f9;
    color: #1e293b;
    border: 1px solid #cbd5e1;
}

body.light .badge-tag.badge-verified {
    color: #1d4ed8;
    background: #eff6ff;
    border-color: #93c5fd;
}

.badge-tag.badge-region {
    font-weight: 600;
}


/* PaperMod Breadcrumbs */
.breadcrumbs {
    display: flex;
    align-items: center;
    gap: 6px;
    color: var(--secondary);
    font-size: 0.875rem;
    margin-bottom: 1.5rem;
    flex-wrap: wrap;
}

.breadcrumbs a {
    color: var(--secondary);
}

.breadcrumbs a:hover {
    color: var(--primary);
}

.breadcrumbs .sep {
    color: var(--tertiary);
}

.breadcrumbs .current {
    color: var(--primary);
    font-weight: 500;
}

/* PaperMod Single Post Page */
.post-single {
    max-width: var(--main-width);
    margin: 0 auto;
}

.post-header {
    margin-bottom: 2rem;
}

.post-title {
    font-size: 2.2rem;
    font-weight: 800;
    color: var(--primary);
    line-height: 1.25;
    margin-bottom: 0.75rem;
    letter-spacing: -0.03em;
}

.post-meta {
    display: flex;
    align-items: center;
    gap: 8px;
    color: var(--secondary);
    font-size: 0.875rem;
    flex-wrap: wrap;
}

.post-meta a {
    color: var(--secondary);
    text-decoration: underline;
    text-underline-offset: 3px;
}

.post-meta a:hover {
    color: var(--primary);
}

/* PaperMod Callout / Highlight Box */
.papermod-callout {
    background: var(--code-bg);
    border-left: 3px solid var(--accent);
    border-radius: 4px;
    padding: 1.25rem 1.5rem;
    margin: 1.75rem 0;
}

.papermod-callout-title {
    font-size: 1rem;
    font-weight: 700;
    color: var(--primary);
    margin-bottom: 0.5rem;
    display: flex;
    align-items: center;
    gap: 8px;
}

.papermod-callout-desc {
    color: var(--content);
    font-size: 0.925rem;
    margin: 0;
}

/* PaperMod Post Content Typography */
.post-content {
    color: var(--content);
    font-size: 1rem;
    line-height: 1.7;
}

.post-content h2 {
    font-size: 1.5rem;
    font-weight: 700;
    margin-top: 2.25rem;
    margin-bottom: 1rem;
    padding-bottom: 0.4rem;
    border-bottom: 1px solid var(--border);
}

.post-content h3 {
    font-size: 1.25rem;
    font-weight: 600;
    margin-top: 1.75rem;
    margin-bottom: 0.75rem;
}

.post-content ul, .post-content ol {
    margin-bottom: 1.5rem;
    padding-left: 1.5rem;
}

.post-content li {
    margin-bottom: 0.5rem;
}

.post-content strong {
    color: var(--primary);
}

/* Job Specifications Grid Box (PaperMod style) */
.job-specs-card {
    background: var(--code-bg);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 1.25rem 1.5rem;
    margin: 1.5rem 0 2rem;
    transition: background 0.2s ease, border-color 0.2s ease;
}

body.light .job-specs-card {
    background: #f8fafc;
    border-color: #e2e8f0;
}

.job-specs-head {
    font-size: 0.95rem;
    font-weight: 700;
    color: var(--primary);
    margin-bottom: 1rem;
    padding-bottom: 0.6rem;
    border-bottom: 1px solid var(--border);
    display: flex;
    align-items: center;
    gap: 8px;
    letter-spacing: -0.01em;
}

body.light .job-specs-head {
    color: #0f172a;
    border-color: #e2e8f0;
}

.job-specs-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 0.85rem 1.5rem;
}

@media (max-width: 640px) {
    .job-specs-grid {
        grid-template-columns: 1fr;
        gap: 0.65rem;
    }
}

.job-spec-row {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    padding-bottom: 0.45rem;
    border-bottom: 1px dashed var(--border);
    font-size: 0.875rem;
    gap: 1rem;
}

body.light .job-spec-row {
    border-bottom-color: #e2e8f0;
}

.spec-k {
    color: var(--secondary);
    font-weight: 500;
    white-space: nowrap;
    flex-shrink: 0;
}

body.light .spec-k {
    color: #64748b;
}

.spec-v {
    color: var(--primary);
    font-weight: 600;
    text-align: right;
    word-break: break-word;
}

body.light .spec-v {
    color: #0f172a;
}

/* Post Action Area & Apply Button */
.post-actions {
    display: flex;
    gap: 1rem;
    align-items: center;
    margin: 2rem 0;
    flex-wrap: wrap;
}

.btn-papermod-primary {
    background: var(--primary);
    color: var(--theme);
    padding: 10px 24px;
    border-radius: var(--radius);
    font-weight: 600;
    font-size: 0.95rem;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    border: none;
    cursor: pointer;
    transition: opacity 0.15s ease, transform 0.15s ease;
    text-decoration: none;
}

.btn-papermod-primary:hover {
    opacity: 0.9;
    color: var(--theme);
    transform: translateY(-1px);
}

.btn-papermod-secondary {
    background: transparent;
    border: 1px solid var(--border);
    color: var(--secondary);
    padding: 10px 18px;
    border-radius: var(--radius);
    font-weight: 500;
    font-size: 0.875rem;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    transition: all 0.15s ease;
}

.btn-papermod-secondary:hover {
    color: var(--primary);
    border-color: var(--secondary);
    background: var(--entry);
}

/* Expired Alert */
.expired-banner {
    background: rgba(239, 68, 68, 0.1);
    border-left: 3px solid #ef4444;
    border-radius: 4px;
    padding: 1rem 1.25rem;
    margin-bottom: 1.5rem;
    color: var(--content);
}

.expired-banner h4 {
    color: #ef4444;
    font-size: 0.95rem;
    font-weight: 700;
    margin-bottom: 0.25rem;
}

.expired-banner p {
    font-size: 0.875rem;
    margin: 0;
}

/* Section Dividers */
.section-head {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    margin: 2rem 0 1.25rem;
    border-bottom: 1px solid var(--border);
    padding-bottom: 0.5rem;
}

.section-head h2 {
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--primary);
    margin: 0;
}

.section-head a {
    font-size: 0.85rem;
    color: var(--secondary);
}

.section-head a:hover {
    color: var(--primary);
}

/* Filters and Pagination */
.filter-bar {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
    margin-bottom: 1.5rem;
    align-items: center;
    justify-content: space-between;
}

.filter-pills {
    display: flex;
    gap: 0.5rem;
    flex-wrap: wrap;
}

.filter-pill {
    font-size: 0.8125rem;
    padding: 6px 14px;
    border-radius: var(--radius);
    background: var(--entry);
    border: 1px solid var(--border);
    color: var(--secondary);
    cursor: pointer;
    transition: all 0.15s ease;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
}

.filter-pill:hover,
.filter-pill.active {
    color: var(--primary);
    border-color: var(--secondary);
    background: var(--code-bg);
}

.pagination {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 2.5rem;
    padding-top: 1.5rem;
    border-top: 1px solid var(--border);
    font-size: 0.875rem;
}

.pagination a {
    color: var(--secondary);
    padding: 6px 14px;
    border-radius: var(--radius);
    border: 1px solid var(--border);
    background: var(--entry);
}

.pagination a:hover {
    color: var(--primary);
    border-color: var(--secondary);
}

/* PaperMod Minimal Footer */
.footer {
    padding: calc(var(--gap) * 1.5) var(--gap);
    border-top: 1px solid var(--border);
    color: var(--secondary);
    font-size: 0.8125rem;
    text-align: center;
    line-height: 1.8;
}

.footer a,
.footer-btn-link {
    color: var(--secondary);
    text-decoration: underline;
    text-underline-offset: 3px;
    background: none;
    border: none;
    padding: 0;
    font: inherit;
    cursor: pointer;
}

.footer a:hover,
.footer-btn-link:hover {
    color: var(--primary);
}


.footer-nav {
    display: flex;
    justify-content: center;
    gap: 1.25rem;
    margin-bottom: 0.75rem;
    list-style: none;
    padding: 0;
    flex-wrap: wrap;
}

/* Report Modal in PaperMod style */
.modal-backdrop {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.7);
    z-index: 999;
    align-items: center;
    justify-content: center;
    padding: 1rem;
}

.modal-card {
    background: var(--entry);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    max-width: 500px;
    width: 100%;
    padding: 1.75rem;
    box-shadow: 0 10px 25px rgba(0,0,0,0.5);
}

.modal-card h3 {
    margin-bottom: 0.5rem;
    font-size: 1.2rem;
}

.modal-card p {
    color: var(--secondary);
    font-size: 0.875rem;
    margin-bottom: 1.25rem;
}

.modal-card textarea {
    width: 100%;
    height: 100px;
    background: var(--code-bg);
    border: 1px solid var(--border);
    border-radius: 4px;
    color: var(--primary);
    padding: 10px;
    font-family: inherit;
    font-size: 0.875rem;
    margin-bottom: 1rem;
    outline: none;
}

.modal-card textarea:focus {
    border-color: var(--secondary);
}

.modal-actions {
    display: flex;
    justify-content: flex-end;
    gap: 0.75rem;
}

/* ==========================================================================
   MOBILE RESPONSIVENESS & ERGONOMICS (Max Width: 768px & 480px)
   Ultra-polished touch-friendly experience
   ========================================================================== */
@media (max-width: 768px) {
    :root {
        --gap: 16px;
        --header-height: auto;
    }

    /* Stack header neatly: Brand & Theme Toggle on top, Swipeable nav bar underneath */
    .nav {
        flex-direction: column;
        align-items: stretch;
        height: auto;
        padding: 10px var(--gap) 8px;
        gap: 8px;
    }

    .logo {
        width: 100%;
        justify-content: space-between;
    }

    #menu {
        width: 100%;
        display: flex;
        gap: 12px;
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
        scrollbar-width: none;
        padding-bottom: 4px;
    }

    #menu::-webkit-scrollbar {
        display: none;
    }

    #menu li a {
        font-size: 0.875rem;
        white-space: nowrap;
        padding: 4px 2px;
    }

    /* Profile hero responsive */
    .profile {
        padding: 2rem 0.5rem 1.5rem;
    }

    .profile .avatar {
        width: 72px;
        height: 72px;
        margin-bottom: 1rem;
    }

    .profile h1 {
        font-size: 1.85rem;
        margin-bottom: 0.5rem;
    }

    .profile .subtitle {
        font-size: 0.95rem;
        margin-bottom: 1.25rem;
        line-height: 1.45;
    }

    /* Swipeable pill bar for buttons on mobile */
    .profile-buttons {
        display: flex;
        gap: 8px;
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
        width: 100%;
        padding-bottom: 6px;
        justify-content: flex-start;
        scrollbar-width: none;
    }

    .profile-buttons::-webkit-scrollbar {
        display: none;
    }

    .profile-buttons .button-link {
        white-space: nowrap;
        flex-shrink: 0;
        font-size: 0.8125rem;
        padding: 7px 14px;
    }

    /* Searchbox mobile stacking: input on top, controls & button neatly organized */
    .searchbox {
        margin-bottom: 0.5rem;
    }

    .searchbox form {
        flex-direction: column;
        align-items: stretch;
        padding: 10px;
        gap: 8px;
    }

    .searchbox-input-wrap {
        width: 100%;
        padding: 2px 0 4px;
        border-bottom: 1px solid var(--border);
    }

    .searchbox input[type="text"] {
        font-size: 1rem; /* prevent iOS auto-zoom */
        padding: 6px 4px;
    }

    .searchbox-controls {
        display: flex;
        gap: 8px;
        width: 100%;
        flex-wrap: wrap;
    }

    .searchbox-controls select {
        flex: 1;
        min-width: 100px;
        padding: 8px 10px;
        font-size: 0.85rem;
    }

    .searchbox-controls button {
        flex-shrink: 0;
        padding: 8px 16px;
        font-size: 0.875rem;
    }

    /* Swipeable filter pills on jobs catalog */
    .filter-bar {
        margin-bottom: 1rem;
    }

    .filter-pills {
        display: flex;
        gap: 8px;
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
        width: 100%;
        padding-bottom: 6px;
        scrollbar-width: none;
    }

    .filter-pills::-webkit-scrollbar {
        display: none;
    }

    .filter-pill {
        white-space: nowrap;
        flex-shrink: 0;
        font-size: 0.8125rem;
        padding: 6px 12px;
    }

    /* Post entry cards mobile ergonomics */
    .post-entry {
        padding: 16px;
        margin-bottom: 14px;
        border-radius: var(--radius);
    }

    .entry-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 8px;
        margin-bottom: 0.5rem;
    }

    .entry-header h2 {
        font-size: 1.2rem;
        line-height: 1.35;
    }

    .entry-salary {
        font-size: 0.85rem;
        padding: 3px 8px;
    }

    .entry-subhead {
        font-size: 0.825rem;
        gap: 6px;
        margin-bottom: 0.6rem;
    }

    .entry-content {
        font-size: 0.875rem;
        margin-bottom: 0.8rem;
        line-height: 1.5;
    }

    .entry-footer {
        font-size: 0.75rem;
        gap: 6px;
    }

    /* Single job detail page mobile */
    .post-single {
        padding: 0;
    }

    .post-header {
        margin-bottom: 1.25rem;
    }

    .post-title {
        font-size: 1.55rem;
        line-height: 1.3;
        margin-bottom: 0.5rem;
    }

    .post-meta {
        font-size: 0.8125rem;
        gap: 6px;
    }

    .papermod-callout {
        padding: 1rem;
        margin: 1.25rem 0;
    }

    .papermod-callout-title {
        font-size: 0.95rem;
        line-height: 1.4;
    }

    .papermod-callout-desc {
        font-size: 0.85rem;
    }

    .post-actions {
        flex-direction: column;
        align-items: stretch;
        gap: 10px;
        margin: 1.5rem 0;
    }

    .post-actions .btn-papermod-primary,
    .post-actions .btn-papermod-secondary {
        width: 100%;
        justify-content: center;
        padding: 12px;
        font-size: 0.925rem;
        text-align: center;
    }

    .post-content h2 {
        font-size: 1.25rem;
        margin-top: 1.75rem;
        margin-bottom: 0.75rem;
    }

    .post-content h3 {
        font-size: 1.1rem;
    }

    .post-content {
        font-size: 0.95rem;
        line-height: 1.65;
    }

    /* Pagination mobile */
    .pagination {
        font-size: 0.8125rem;
        padding-top: 1rem;
        margin-top: 1.5rem;
    }

    .pagination a {
        padding: 8px 16px;
    }

    .footer {
        padding: calc(var(--gap) * 1.2) var(--gap);
        font-size: 0.78rem;
    }

    .footer-nav {
        gap: 0.75rem;
    }
}

/* ==========================================================================
   Fast Application Modal (Matches User Mockup Reference)
   ========================================================================== */
.apply-modal-backdrop {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(15, 23, 42, 0.65);
    backdrop-filter: blur(5px);
    -webkit-backdrop-filter: blur(5px);
    z-index: 1000;
    align-items: center;
    justify-content: center;
    padding: 1rem;
    animation: applyFadeIn 0.2s ease-out;
}

@keyframes applyFadeIn {
    from { opacity: 0; transform: scale(0.97); }
    to { opacity: 1; transform: scale(1); }
}

.apply-modal-card {
    background: var(--entry);
    border: 1px solid var(--border);
    border-radius: 20px;
    max-width: 480px;
    width: 100%;
    padding: 1.5rem 1.75rem;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.35);
    position: relative;
    max-height: 92vh;
    overflow-y: auto;
    transition: background 0.2s ease, border-color 0.2s ease;
    scrollbar-width: thin;
}

body.light .apply-modal-card {
    background: #ffffff;
    border: 1px solid #e2e8f0;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.15);
}

.apply-close-btn {
    position: absolute;
    top: 1.25rem;
    right: 1.25rem;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    border: none;
    background: var(--code-bg);
    color: var(--secondary);
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.15s ease;
}

.apply-close-btn:hover {
    background: var(--tertiary);
    color: var(--primary);
    transform: rotate(90deg);
}

body.light .apply-close-btn {
    background: #f1f5f9;
    color: #475569;
}

body.light .apply-close-btn:hover {
    background: #e2e8f0;
    color: #0f172a;
}

.apply-modal-header {
    margin-bottom: 1.15rem;
    padding-right: 2.5rem;
}

.apply-modal-badge {
    font-size: 0.85rem;
    color: var(--secondary);
    font-weight: 500;
    display: block;
    margin-bottom: 0.25rem;
}

body.light .apply-modal-badge {
    color: #64748b;
}

.apply-modal-title {
    font-size: 1.25rem;
    font-weight: 800;
    color: var(--primary);
    margin: 0 0 0.25rem;
    line-height: 1.3;
}

body.light .apply-modal-title {
    color: #0f172a;
}

.apply-modal-company {
    font-size: 0.9rem;
    font-weight: 600;
    color: #3b82f6;
}

body.light .apply-modal-company {
    color: #2563eb;
}

.apply-form-group {
    margin-bottom: 0.9rem;
}

.apply-label {
    display: block;
    font-size: 0.85rem;
    font-weight: 700;
    color: var(--primary);
    margin-bottom: 0.35rem;
}

body.light .apply-label {
    color: #1e293b;
}

.apply-input {
    width: 100%;
    border: 1.5px solid var(--border);
    border-radius: 12px;
    padding: 10px 14px;
    font-size: 0.925rem;
    color: var(--primary);
    background: var(--code-bg);
    outline: none;
    font-family: inherit;
    transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

.apply-input::placeholder {
    color: var(--secondary);
    opacity: 0.8;
}

.apply-input:focus {
    border-color: #3b82f6;
    box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.2);
}

body.light .apply-input {
    background: #ffffff;
    border-color: #e2e8f0;
    color: #0f172a;
}

body.light .apply-input::placeholder {
    color: #94a3b8;
}

body.light .apply-input:focus {
    border-color: #2563eb;
    box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.15);
}

/* Dropzone styling */
.apply-dropzone {
    border: 2px dashed var(--border);
    border-radius: 14px;
    padding: 1.15rem 1rem;
    text-align: center;
    cursor: pointer;
    background: var(--code-bg);
    transition: all 0.15s ease;
    user-select: none;
}

body.light .apply-dropzone {
    background: #f8fafc;
    border-color: #cbd5e1;
}

.apply-dropzone:hover,
.apply-dropzone.drag-over {
    border-color: #3b82f6;
    background: rgba(59, 130, 246, 0.08);
}

body.light .apply-dropzone:hover,
body.light .apply-dropzone.drag-over {
    border-color: #2563eb;
    background: #eff6ff;
}

.apply-dropzone.has-file {
    border-color: #10b981;
    background: rgba(16, 185, 129, 0.08);
}

body.light .apply-dropzone.has-file {
    border-color: #10b981;
    background: #ecfdf5;
}

.dropzone-paperclip {
    font-size: 1.6rem;
    margin-bottom: 0.35rem;
    display: inline-block;
}

.dropzone-text {
    font-size: 0.925rem;
    font-weight: 600;
    color: var(--primary);
}

body.light .dropzone-text {
    color: #1e293b;
}

.dropzone-hint {
    font-size: 0.775rem;
    color: var(--secondary);
    margin-top: 0.2rem;
}

body.light .dropzone-hint {
    color: #64748b;
}

/* Submit Button */
.apply-submit-btn {
    width: 100%;
    background: #0284c7;
    background: linear-gradient(180deg, #0284c7 0%, #0369a1 100%);
    color: #ffffff;
    border: none;
    border-radius: 14px;
    padding: 14px 20px;
    font-size: 1rem;
    font-weight: 700;
    cursor: pointer;
    box-shadow: 0 8px 16px -3px rgba(2, 132, 199, 0.35);
    margin-top: 0.5rem;
    transition: transform 0.15s ease, box-shadow 0.15s ease, opacity 0.15s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}

.apply-submit-btn:hover {
    transform: translateY(-1px);
    box-shadow: 0 12px 20px -3px rgba(2, 132, 199, 0.45);
    opacity: 0.95;
}

.apply-submit-btn:disabled {
    opacity: 0.6;
    cursor: not-allowed;
    transform: none;
}

.apply-error-text {
    color: #ef4444;
    font-size: 0.8125rem;
    margin-bottom: 0.85rem;
    padding: 8px 12px;
    background: rgba(239, 68, 68, 0.1);
    border-radius: 8px;
    border: 1px solid rgba(239, 68, 68, 0.2);
}

.apply-success-banner {
    text-align: center;
    padding: 2rem 1rem;
}

.apply-success-banner .success-icon {
    width: 56px;
    height: 56px;
    border-radius: 50%;
    background: rgba(16, 185, 129, 0.15);
    color: #10b981;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.75rem;
    font-weight: 800;
    margin: 0 auto 1rem;
}

.apply-success-banner h4 {
    font-size: 1.35rem;
    font-weight: 800;
    color: var(--primary);
    margin-bottom: 0.5rem;
}

body.light .apply-success-banner h4 {
    color: #0f172a;
}

.apply-success-banner p {
    color: var(--secondary);
    font-size: 0.925rem;
    line-height: 1.5;
    margin-bottom: 1rem;
}

body.light .apply-success-banner p {
    color: #475569;
}

