:root {
  --bg: #0a0a0a;
  --bg-card: #141414;
  --accent: #ff4d00;
  --accent-hover: #ff6633;
  --text: #f5f5f5;
  --text-muted: #999;
  --border: #222;
  --font: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  --font-mono: 'JetBrains Mono', 'Fira Code', monospace;
  --max-width: 800px;
}

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

html {
  font-size: 16px;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

body {
  font-family: var(--font);
  background: var(--bg);
  color: var(--text);
  line-height: 1.6;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

/* ---- Layout ---- */

.container {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 24px;
}

main {
  flex: 1;
  padding: 56px 0 80px;
}

/* ---- Header ---- */

.site-header {
  border-bottom: 1px solid var(--border);
  padding: 18px 0;
}

.site-header .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.logo {
  display: flex;
  align-items: center;
  text-decoration: none;
}

.logo img {
  height: 34px;
  display: block;
}

.site-header nav a {
  color: var(--text-muted);
  text-decoration: none;
  font-size: 14px;
  transition: color 0.15s;
}

.site-header nav a:hover {
  color: var(--text);
}

/* ---- Footer ---- */

.site-footer {
  border-top: 1px solid var(--border);
  padding: 36px 0;
  text-align: center;
  color: var(--text-muted);
  font-size: 14px;
}

.site-footer a {
  color: var(--text-muted);
  text-decoration: none;
  transition: color 0.15s;
}

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

.footer-copy {
  margin-top: 8px;
  font-size: 13px;
  color: #555;
}

/* ---- Hero ---- */

.hero {
  margin-bottom: 48px;
}

.hero h1 {
  font-size: 2.5rem;
  font-weight: 700;
  margin-bottom: 14px;
  line-height: 1.15;
  letter-spacing: -0.02em;
}

.hero-sub {
  color: var(--text-muted);
  font-size: 1.05rem;
  max-width: 560px;
  line-height: 1.75;
}

/* ---- Department Filters ---- */

.filters {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  margin-bottom: 32px;
}

.filter-btn {
  background: transparent;
  border: 1px solid var(--border);
  color: var(--text-muted);
  padding: 6px 18px;
  border-radius: 20px;
  cursor: pointer;
  font-size: 13px;
  font-family: var(--font);
  line-height: 1;
  transition: border-color 0.15s, color 0.15s, background 0.15s;
}

.filter-btn:hover {
  border-color: #444;
  color: var(--text);
}

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

/* ---- Job Cards ---- */

.jobs-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.job-card {
  display: flex;
  flex-direction: column;
  gap: 10px;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 22px 24px;
  text-decoration: none;
  color: inherit;
  transition: border-color 0.15s;
}

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

.job-card:hover .job-card-title {
  color: var(--accent);
}

.job-card-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.job-card-title {
  font-size: 1.05rem;
  font-weight: 600;
  color: var(--text);
  transition: color 0.15s;
}

.job-card-meta {
  display: flex;
  align-items: center;
  gap: 20px;
  color: var(--text-muted);
  font-size: 13px;
}

/* ---- Badge ---- */

.badge {
  display: inline-block;
  padding: 3px 10px;
  background: rgba(255, 77, 0, 0.1);
  color: var(--accent);
  border: 1px solid rgba(255, 77, 0, 0.2);
  border-radius: 4px;
  font-size: 12px;
  font-weight: 500;
  white-space: nowrap;
  flex-shrink: 0;
  letter-spacing: 0.01em;
}

/* ---- RSS Link ---- */

.rss-link {
  margin-top: 48px;
  padding-top: 24px;
  border-top: 1px solid var(--border);
}

.rss-link a {
  color: var(--text-muted);
  text-decoration: none;
  font-size: 13px;
  transition: color 0.15s;
}

.rss-link a::before {
  content: '⌁ ';
  color: var(--accent);
}

.rss-link a:hover {
  color: var(--text);
}

/* ---- Job Detail Page ---- */

.back-link {
  display: inline-block;
  color: var(--text-muted);
  text-decoration: none;
  font-size: 14px;
  margin-bottom: 36px;
  transition: color 0.15s;
}

.back-link:hover {
  color: var(--accent);
}

.job-header {
  margin-bottom: 40px;
}

.job-header h1 {
  font-size: 2rem;
  font-weight: 700;
  margin-bottom: 18px;
  line-height: 1.25;
  letter-spacing: -0.02em;
}

.job-meta {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 0;
}

.meta-item {
  color: var(--text-muted);
  font-size: 14px;
  padding: 0 12px;
  border-left: 1px solid var(--border);
}

.meta-item:first-child {
  padding-left: 0;
  border-left: none;
}

/* ---- Job Body (rendered markdown) ---- */

.job-body {
  border-top: 1px solid var(--border);
  padding-top: 40px;
  margin-bottom: 56px;
}

.job-body h2 {
  font-size: 1.1rem;
  font-weight: 600;
  margin: 36px 0 14px;
  color: var(--text);
  letter-spacing: 0.01em;
}

.job-body h2:first-child {
  margin-top: 0;
}

.job-body h3 {
  font-size: 1rem;
  font-weight: 600;
  margin: 24px 0 10px;
  color: var(--text);
}

.job-body p {
  color: var(--text-muted);
  margin-bottom: 16px;
  line-height: 1.75;
}

.job-body ul,
.job-body ol {
  color: var(--text-muted);
  padding-left: 20px;
  margin-bottom: 16px;
}

.job-body li {
  margin-bottom: 7px;
  line-height: 1.65;
}

.job-body code {
  font-family: var(--font-mono);
  background: rgba(255, 255, 255, 0.06);
  padding: 2px 6px;
  border-radius: 3px;
  font-size: 0.875em;
  color: var(--accent-hover);
}

.job-body pre {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 6px;
  padding: 18px;
  overflow-x: auto;
  margin-bottom: 18px;
}

.job-body pre code {
  background: transparent;
  padding: 0;
  color: var(--text);
  font-size: 0.875rem;
}

.job-body a {
  color: var(--accent);
  text-decoration: none;
}

.job-body a:hover {
  color: var(--accent-hover);
  text-decoration: underline;
}

.job-body strong {
  color: var(--text);
  font-weight: 600;
}

/* ---- Apply Section ---- */

.apply-section {
  border-top: 1px solid var(--border);
  padding-top: 40px;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 20px;
}

.btn-apply {
  display: inline-block;
  background: var(--accent);
  color: #fff;
  padding: 13px 32px;
  border-radius: 6px;
  text-decoration: none;
  font-weight: 600;
  font-size: 0.95rem;
  letter-spacing: 0.01em;
  transition: background 0.15s;
}

.btn-apply:hover {
  background: var(--accent-hover);
}

.back-link-bottom {
  color: var(--text-muted);
  text-decoration: none;
  font-size: 14px;
  transition: color 0.15s;
}

.back-link-bottom:hover {
  color: var(--text);
}

/* ---- Responsive ---- */

@media (max-width: 600px) {
  main {
    padding: 40px 0 64px;
  }

  .hero h1 {
    font-size: 1.8rem;
  }

  .hero-sub {
    font-size: 1rem;
  }

  .job-card-header {
    flex-direction: column;
    align-items: flex-start;
  }

  .job-card-meta {
    flex-wrap: wrap;
    gap: 8px;
  }

  .job-header h1 {
    font-size: 1.6rem;
  }

  .job-meta {
    flex-direction: column;
    align-items: flex-start;
    gap: 6px;
  }

  .meta-item {
    padding: 0;
    border-left: none;
  }

  .meta-item:not(:first-child)::before {
    content: none;
  }

  .btn-apply {
    align-self: stretch;
    text-align: center;
  }
}
