/*
Theme Name: Jobs Maxmag
Theme URI: https://jobs.maxmag.org
Author: Maxmag
Description: Minimal shell theme for jobs.maxmag.org. Keeps only the global shell, typography, and base containers so archive and homepage experiences can be handled by an MU plugin.
Version: 1.2
Text Domain: jobs-maxmag
*/

:root {
  --jm-text: #18212b;
  --jm-muted: #5e6a77;
  --jm-bg: #f5f6f8;
  --jm-surface: #ffffff;
  --jm-border: #e4e8ee;
  --jm-accent: #e85734;
  --jm-accent-hover: #d84a28;
  --jm-heading: #111827;
  --jm-container: 1240px;
  --jm-radius: 18px;
  --jm-shadow: 0 10px 35px rgba(17, 24, 39, 0.06);
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: Arial, Helvetica, sans-serif;
  color: var(--jm-text);
  background: var(--jm-bg);
  line-height: 1.65;
}
img { max-width: 100%; height: auto; display: block; }
a { color: inherit; text-decoration: none; }
a:hover { color: var(--jm-accent); }

.container {
  width: min(calc(100% - 32px), var(--jm-container));
  margin-inline: auto;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 1000;
  background: rgba(255, 255, 255, 0.9);
  backdrop-filter: blur(14px);
  border-bottom: 1px solid rgba(17, 24, 39, 0.06);
  box-shadow: 0 8px 24px rgba(15, 23, 42, 0.04);
}
.site-header-inner {
  min-height: 74px;
  display: grid;
  grid-template-columns: minmax(220px, auto) 1fr auto;
  align-items: center;
  gap: 18px;
}
.site-brand-wrap {
  min-width: 0;
}
.site-logo {
  display: inline-flex;
  align-items: center;
  gap: 14px;
  color: var(--jm-heading);
}
.site-logo:hover,
.site-logo:focus-visible {
  color: var(--jm-heading);
}
.site-logo-image {
  display: block;
  height: 54px;
  width: auto;
  max-width: 270px;
  object-fit: contain;
}

.site-logo-mark {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  border-radius: 14px;
  background: linear-gradient(135deg, #111827, #273449);
  color: #fff;
  font-size: 1rem;
  font-weight: 800;
  letter-spacing: -0.04em;
  box-shadow: 0 12px 22px rgba(15, 23, 42, 0.14);
}
.site-logo-copy {
  display: flex;
  flex-direction: column;
  min-width: 0;
}
.site-logo-name {
  font-size: 1.28rem;
  line-height: 1;
  font-weight: 800;
  letter-spacing: -0.035em;
}
.site-logo-tagline {
  margin-top: 5px;
  color: var(--jm-muted);
  font-size: 0.84rem;
  font-weight: 600;
  letter-spacing: -0.01em;
}
.site-menu-toggle {
  display: none;
  align-items: center;
  justify-content: center;
  gap: 10px;
  min-height: 42px;
  min-width: 42px;
  padding: 0 14px;
  border: 1px solid rgba(15, 23, 42, 0.08);
  border-radius: 999px;
  background: #fff;
  color: var(--jm-heading);
  font: inherit;
  font-weight: 700;
  box-shadow: 0 8px 18px rgba(15, 23, 42, 0.05);
  cursor: pointer;
}
.site-menu-toggle-box {
  display: inline-flex;
  flex-direction: column;
  justify-content: center;
  gap: 4px;
  width: 18px;
}
.site-menu-toggle-box span {
  display: block;
  width: 18px;
  height: 2px;
  border-radius: 999px;
  background: currentColor;
  transition: transform .2s ease, opacity .2s ease;
}
.site-header.is-menu-open .site-menu-toggle-box span:nth-child(1) { transform: translateY(6px) rotate(45deg); }
.site-header.is-menu-open .site-menu-toggle-box span:nth-child(2) { opacity: 0; }
.site-header.is-menu-open .site-menu-toggle-box span:nth-child(3) { transform: translateY(-6px) rotate(-45deg); }
.site-nav {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 18px;
  min-width: 0;
}
.site-nav ul,
.site-footer-nav ul,
.site-nav-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  align-items: center;
  gap: 8px;
}
.site-nav li {
  margin: 0;
}
.site-nav a,
.site-footer-nav a {
  color: var(--jm-heading);
}
.site-nav-list {
  justify-content: center;
}
.site-nav-list a {
  display: inline-flex;
  align-items: center;
  min-height: 40px;
  padding: 0 12px;
  border-radius: 999px;
  font-size: 0.97rem;
  font-weight: 700;
  color: #243244;
  transition: background .18s ease, color .18s ease, box-shadow .18s ease;
}
.site-nav-list a:hover,
.site-nav-list a:focus-visible {
  background: rgba(15, 23, 42, 0.05);
  color: var(--jm-heading);
}
.site-nav-list a.is-active {
  background: rgba(15, 23, 42, 0.06);
  box-shadow: inset 0 0 0 1px rgba(15, 23, 42, 0.04);
}
.site-nav-actions {
  display: flex;
  align-items: center;
  gap: 10px;
}
.site-nav-cta,
.site-nav-cta:link,
.site-nav-cta:visited {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  padding: 0 18px;
  border-radius: 999px;
  font-size: 0.94rem;
  font-weight: 800;
  letter-spacing: -0.01em;
  white-space: nowrap;
  background: #111827;
  color: #fff !important;
  box-shadow: 0 12px 24px rgba(15, 23, 42, 0.16);
  transition: transform .18s ease, box-shadow .18s ease, background .18s ease, color .18s ease;
}
.site-nav-cta:hover,
.site-nav-cta:focus-visible,
.site-nav-cta:active {
  transform: translateY(-1px);
  background: #0b1220;
  color: #fff !important;
}
.site-header--single-job .site-nav-cta {
  background: var(--jm-accent);
  box-shadow: 0 12px 24px rgba(232, 87, 52, 0.22);
}
.site-header--single-job .site-nav-cta:hover,
.site-header--single-job .site-nav-cta:focus-visible,
.site-header--single-job .site-nav-cta:active {
  background: var(--jm-accent-hover);
  color: #fff !important;
}
@media (max-width: 980px) {
  .site-header-inner {
    min-height: 68px;
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 14px;
  }
  .site-logo-image {
    height: 44px;
    max-width: 220px;
  }
  .site-logo-name {
    font-size: 1.08rem;
  }
  .site-logo-tagline {
    font-size: 0.78rem;
  }
  .site-menu-toggle {
    display: inline-flex;
  }
  .site-menu-toggle-label {
    display: none;
  }
  .site-nav {
    position: absolute;
    top: calc(100% + 10px);
    left: 16px;
    right: 16px;
    display: none;
    flex-direction: column;
    align-items: stretch;
    gap: 14px;
    padding: 16px;
    border-radius: 22px;
    background: rgba(255, 255, 255, 0.98);
    border: 1px solid rgba(15, 23, 42, 0.07);
    box-shadow: 0 24px 50px rgba(15, 23, 42, 0.14);
  }
  .site-header {
    position: sticky;
  }
  .site-header.is-menu-open .site-nav {
    display: flex;
  }
  .site-nav-list,
  .site-nav-actions {
    width: 100%;
    flex-direction: column;
    align-items: stretch;
  }
  .site-nav-list a,
  .site-nav-cta {
    width: 100%;
    justify-content: center;
    min-height: 46px;
  }
}
@media (max-width: 640px) {
  .container {
    width: min(calc(100% - 24px), var(--jm-container));
  }
  .site-header-inner {
    min-height: 64px;
  }
  .site-logo {
    gap: 10px;
  }
  .site-logo-image {
    height: 38px;
    max-width: 190px;
  }
  .site-logo-mark {
    width: 36px;
    height: 36px;
    border-radius: 12px;
  }
  .site-logo-name {
    font-size: 1rem;
  }
  .site-logo-tagline {
    display: none;
  }
}
.site-main {
  min-height: 70vh;
  padding: 40px 0 64px;
}

.content-shell {
  background: var(--jm-surface);
  border: 1px solid var(--jm-border);
  border-radius: var(--jm-radius);
  box-shadow: var(--jm-shadow);
  padding: clamp(24px, 3vw, 40px);
}

.entry-title,
.page-title,
h1, h2, h3, h4, h5, h6 {
  color: var(--jm-heading);
  line-height: 1.15;
  margin-top: 0;
}
.entry-title,
.page-title,
h1 { font-size: clamp(2rem, 4vw, 3.2rem); margin-bottom: 18px; }
h2 { font-size: clamp(1.5rem, 3vw, 2.2rem); margin-bottom: 14px; }
h3 { font-size: 1.3rem; margin-bottom: 12px; }
p { margin: 0 0 1rem; }

.entry-content,
.archive-description {
  color: var(--jm-text);
}

.button,
button,
input[type="submit"],
input[type="button"] {
  appearance: none;
  border: 0;
  border-radius: 999px;
  background: var(--jm-accent);
  color: #fff;
  font: inherit;
  font-weight: 700;
  padding: 0.9rem 1.35rem;
  cursor: pointer;
}
.button:hover,
button:hover,
input[type="submit"]:hover,
input[type="button"]:hover {
  background: var(--jm-accent-hover);
  color: #fff;
}

input[type="text"],
input[type="search"],
input[type="email"],
input[type="url"],
input[type="password"],
textarea,
select {
  width: 100%;
  padding: 0.9rem 1rem;
  border: 1px solid var(--jm-border);
  border-radius: 14px;
  background: #fff;
  color: var(--jm-text);
  font: inherit;
}

.posts-grid {
  display: grid;
  gap: 18px;
}
.post-card {
  background: #fff;
  border: 1px solid var(--jm-border);
  border-radius: 16px;
  padding: 22px;
}
.post-card h2 {
  font-size: 1.35rem;
  margin-bottom: 10px;
}

.pagination,
.nav-links {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 28px;
}
.nav-links .page-numbers {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 42px;
  min-height: 42px;
  padding: 0 12px;
  border-radius: 999px;
  background: #fff;
  border: 1px solid var(--jm-border);
}
.nav-links .current {
  background: var(--jm-accent);
  border-color: var(--jm-accent);
  color: #fff;
}

.site-footer {
  background: #fff;
  border-top: 1px solid rgba(17, 24, 39, 0.06);
}
.site-footer-inner {
  min-height: 84px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  padding: 24px 0;
}
.site-footer p {
  margin: 0;
  color: var(--jm-muted);
}

.screen-reader-text {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0,0,0,0);
  white-space: nowrap;
  border: 0;
}

@media (max-width: 1180px) {
  .site-header-inner {
    grid-template-columns: auto minmax(0, 1fr) auto auto;
    gap: 12px;
  }
  .site-header-search-link {
    width: min(100%, 320px);
  }
  .site-nav-list a {
    padding-inline: 10px;
    font-size: 0.9rem;
  }
  .site-nav-secondary,
  .site-nav-cta {
    padding-inline: 14px;
  }
}

@media (max-width: 980px) {
  .site-header-utility {
    display: none;
  }
  .site-header-inner,
  .site-header--home .site-header-inner {
    grid-template-columns: minmax(0, 1fr) auto;
    min-height: 74px;
  }
  .site-header-tools {
    display: none;
  }
  .site-menu-toggle {
    display: inline-flex;
  }
  .site-nav {
    position: absolute;
    left: 16px;
    right: 16px;
    top: calc(100% + 10px);
    display: none;
    flex-direction: column;
    align-items: stretch;
    gap: 16px;
    padding: 16px;
    border-radius: 24px;
    border: 1px solid rgba(15, 23, 42, 0.08);
    background: rgba(255, 255, 255, 0.98);
    box-shadow: 0 24px 60px rgba(15, 23, 42, 0.14);
    backdrop-filter: blur(18px);
  }
  .site-header.is-menu-open .site-nav {
    display: flex;
  }
  .site-nav ul,
  .site-nav-list {
    width: 100%;
    flex-direction: column;
    align-items: stretch;
    gap: 4px;
  }
  .site-nav-list a {
    min-height: 46px;
    padding: 0 14px;
    border-radius: 14px;
    background: #f8fafc;
  }
  .site-nav-actions {
    width: 100%;
    flex-direction: column;
  }
  .site-nav-secondary,
  .site-nav-cta {
    width: 100%;
    min-height: 48px;
  }
}

@media (max-width: 760px) {
  .site-header-inner,
  .site-footer-inner {
    grid-template-columns: 1fr;
    display: grid;
    align-items: center;
  }
  .site-header-inner {
    padding: 14px 0;
  }
  .site-menu-toggle-label {
    display: none;
  }
  .site-main {
    padding: 28px 0 48px;
  }
  .content-shell {
    padding: 22px;
  }
}

@media (max-width: 560px) {
  .container {
    width: min(calc(100% - 24px), var(--jm-container));
  }
  .site-header-utility {
    display: none;
  }
  .site-logo-mark {
    width: 38px;
    height: 38px;
    border-radius: 12px;
  }
  .site-logo-name {
    font-size: 1rem;
  }
  .site-logo-tagline {
    font-size: 0.74rem;
  }
  .site-header-search-link {
    min-height: 44px;
    padding: 0 14px;
  }
  .site-menu-toggle {
    min-height: 44px;
    padding: 0 14px;
  }
  .site-nav {
    left: 12px;
    right: 12px;
  }
  .site-footer-inner {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    justify-content: center;
  }
}


body.site-menu-open { overflow: hidden; }

@media (max-width: 980px) {
  .site-header-inner {
    min-height: 62px;
    gap: 10px;
  }
  .site-logo-mark {
    width: 38px;
    height: 38px;
    border-radius: 13px;
  }
  .site-logo-name {
    font-size: 0.98rem;
  }
  .site-menu-toggle {
    min-height: 40px;
    min-width: 40px;
    width: 40px;
    padding: 0;
    border-radius: 999px;
    box-shadow: 0 6px 14px rgba(15, 23, 42, 0.05);
  }
  .site-nav {
    top: calc(100% + 8px);
    left: 12px;
    right: 12px;
    gap: 10px;
    padding: 12px;
    border-radius: 18px;
    box-shadow: 0 18px 36px rgba(15, 23, 42, 0.12);
  }
  .site-nav-list {
    gap: 0;
  }
  .site-nav-list a {
    min-height: 44px;
    padding: 0 8px;
    border-radius: 12px;
    background: transparent;
    font-size: 1rem;
    justify-content: flex-start;
  }
  .site-nav-list a:hover,
  .site-nav-list a:focus-visible {
    background: #f6f8fb;
  }
  .site-nav-actions {
    padding-top: 4px;
  }
  .site-nav-cta,
  .site-nav-cta:link,
  .site-nav-cta:visited {
    min-height: 48px;
    font-size: 1rem;
    box-shadow: none;
  }
}

@media (max-width: 640px) {
  .site-header-inner {
    min-height: 58px;
  }
  .site-logo {
    gap: 10px;
  }
  .site-logo-image {
    height: 38px;
    max-width: 190px;
  }
  .site-logo-mark {
    width: 34px;
    height: 34px;
    border-radius: 11px;
    font-size: 0.95rem;
  }
  .site-logo-name {
    font-size: 0.92rem;
  }
  .site-menu-toggle {
    min-height: 38px;
    min-width: 38px;
    width: 38px;
  }
  .site-nav {
    left: 10px;
    right: 10px;
    top: calc(100% + 6px);
    padding: 10px;
    border-radius: 16px;
  }
  .site-nav-list a {
    min-height: 42px;
    font-size: 0.98rem;
  }
  .site-nav-cta,
  .site-nav-cta:link,
  .site-nav-cta:visited {
    min-height: 46px;
  }
  .site-main {
    padding-top: 24px;
  }
}
