:root {
  --canvas: #f4f2ed;
  --surface: #fbfaf7;
  --surface-strong: #ffffff;
  --ink: #17161b;
  --muted: #6f6c76;
  --line: #ddd9d1;
  --accent: #7057e8;
  --accent-dark: #5139bf;
  --accent-soft: #e9e4ff;
  --success: #27a36a;
  --shadow: 0 18px 50px rgba(31, 27, 44, 0.08);
  --radius-lg: 28px;
  --radius-md: 18px;
  --max-width: 1200px;
  --page-gutter: 80px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-width: 320px;
  color: var(--ink);
  background:
    radial-gradient(circle at 82% 10%, rgba(112, 87, 232, 0.1), transparent 28rem),
    var(--canvas);
  font-family: "DM Sans", sans-serif;
  -webkit-font-smoothing: antialiased;
}

button,
input,
select {
  font: inherit;
}

a {
  color: inherit;
}

.page-shell {
  width: auto;
  margin: 0 var(--page-gutter);
}

.site-header {
  min-height: 88px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-bottom: 1px solid rgba(23, 22, 27, 0.1);
}

.brand {
  display: inline-flex;
  align-items: center;
  align-self: center;
  gap: 10px;
  color: var(--ink);
  font: 700 1.08rem/1 "Manrope", sans-serif;
  letter-spacing: -0.03em;
  text-decoration: none;
  line-height: 1;
  flex: 0 0 auto;
}

.brand-logo {
  display: block;
  width: 80px !important;
  height: auto !important;
  max-width: 80px;
  max-height: none;
  object-fit: contain;
  object-position: left center;
  flex: 0 0 auto;
  align-self: center;
}

.brand-wordmark {
  display: inline-block;
  font-family: "Manrope", sans-serif;
  font-size: 32px;
  font-weight: 800;
  line-height: 1;
  letter-spacing: -0.055em;
  background: linear-gradient(135deg, #3a0b75 0%, #7b2ff7 48%, #c56cff 100%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent !important;
  -webkit-text-fill-color: transparent !important;
  white-space: nowrap;
}

.live-label {
  display: flex;
  align-items: center;
  gap: 8px;
  color: var(--muted);
  font-size: 0.85rem;
  font-weight: 600;
}

.live-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--success);
  box-shadow: 0 0 0 5px rgba(39, 163, 106, 0.12);
}

.hero {
  display: grid;
  grid-template-columns: minmax(0, 1.08fr) minmax(320px, 0.92fr);
  align-items: center;
  gap: clamp(48px, 7vw, 100px);
  padding: 48px 0 72px;
}

.hero-content {
  min-width: 0;
}

.eyebrow,
.section-kicker {
  margin: 0 0 22px;
  color: var(--accent-dark);
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.hero h1 {
  max-width: 720px;
  margin: 0;
  font: 600 clamp(3.4rem, 6.3vw, 6.2rem) / 0.96 "Manrope", sans-serif;
  letter-spacing: -0.07em;
}

.hero-copy {
  max-width: 550px;
  margin: 30px 0 50px;
  color: var(--muted);
  font-size: clamp(1.05rem, 2vw, 1.2rem);
  line-height: 1.65;
}

.hero-meta {
  display: flex;
  gap: clamp(40px, 9vw, 110px);
}

.hero-meta > div {
  display: grid;
  gap: 5px;
}

.hero-visual {
  width: 100%;
  min-height: 430px;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: clamp(18px, 3vw, 38px);
  overflow: hidden;
  border: 1px solid rgba(112, 87, 232, 0.14);
  border-radius: var(--radius-lg);
  background:
    radial-gradient(circle at 72% 22%, rgba(112, 87, 232, 0.18), transparent 42%),
    rgba(251, 250, 247, 0.65);
}

.hero-visual img {
  display: block;
  width: 100%;
  max-width: 100%;
  height: auto;
  max-height: 520px;
  object-fit: contain;
}

.meta-value {
  font: 600 1.4rem/1.2 "Manrope", sans-serif;
  letter-spacing: -0.04em;
}

.meta-label {
  color: var(--muted);
  font-size: 0.84rem;
}

.job-browser {
  padding-bottom: 90px;
}

.filter-panel {
  position: sticky;
  z-index: 10;
  top: 16px;
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  align-items: stretch;
  gap: 12px;
  padding: 14px;
  border: 1px solid rgba(221, 217, 209, 0.85);
  border-radius: 26px;
  background: rgba(251, 250, 247, 0.84);
  box-shadow: 0 12px 38px rgba(33, 29, 44, 0.08);
  backdrop-filter: blur(18px);
}

.select-field {
  position: relative;
  display: flex;
  align-items: center;
  min-width: 0;
}

.select-field select {
  width: 100%;
  min-height: 52px;
  border: 1px solid transparent;
  border-radius: 14px;
  outline: none;
  color: var(--ink);
  background: transparent;
  transition: border-color 160ms ease, background 160ms ease, box-shadow 160ms ease;
}

.select-field select {
  min-width: 0;
  padding: 0 45px 0 16px;
  appearance: none;
  cursor: pointer;
  white-space: nowrap;
  text-overflow: ellipsis;
}

.sort-field select {
  min-width: 0;
}

.search-button {
  grid-column: 1 / -1;
  min-height: 52px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 9px;
  padding: 0 20px;
  border: 0;
  border-radius: 14px;
  color: #fff;
  background: var(--accent);
  box-shadow: 0 8px 20px rgba(112, 87, 232, 0.2);
  font-weight: 600;
  white-space: nowrap;
  cursor: pointer;
  transition: background 160ms ease, box-shadow 160ms ease, transform 160ms ease;
}

.search-button:hover:not(:disabled) {
  background: var(--accent-dark);
  box-shadow: 0 11px 25px rgba(81, 57, 191, 0.27);
  transform: translateY(-1px);
}

.search-button:focus-visible {
  outline: 3px solid rgba(112, 87, 232, 0.24);
  outline-offset: 3px;
}

.search-button svg {
  width: 17px;
  fill: none;
  stroke: currentColor;
  stroke-linecap: round;
  stroke-width: 1.9;
}

.search-button:disabled {
  cursor: wait;
  opacity: 0.88;
  transform: none;
}

.search-button.is-searching {
  min-width: 132px;
  background: var(--accent-dark);
  box-shadow: 0 8px 20px rgba(81, 57, 191, 0.2);
}

.button-spinner {
  width: 16px;
  height: 16px;
  flex: 0 0 auto;
  border: 2px solid rgba(255, 255, 255, 0.38);
  border-top-color: #fff;
  border-radius: 50%;
  animation: spin 0.72s linear infinite;
}

.select-field > svg {
  position: absolute;
  right: 15px;
  width: 18px;
  fill: none;
  stroke: var(--muted);
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 1.7;
  pointer-events: none;
}

.select-field select:focus {
  border-color: rgba(112, 87, 232, 0.5);
  background: var(--surface-strong);
  box-shadow: 0 0 0 4px rgba(112, 87, 232, 0.1);
}

.results-header {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 24px;
  padding: 72px 0 28px;
}

.section-kicker {
  margin-bottom: 9px;
}

.results-header h2 {
  margin: 0;
  font: 600 clamp(1.8rem, 4vw, 2.6rem) / 1.1 "Manrope", sans-serif;
  letter-spacing: -0.05em;
}

.results-actions {
  display: flex;
  align-items: center;
  gap: 18px;
}

#result-count {
  margin: 0;
  color: var(--muted);
  font-size: 0.9rem;
}

#refresh-button {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 9px 12px;
  border: 0;
  border-radius: 10px;
  color: var(--muted);
  background: transparent;
  cursor: pointer;
}

#refresh-button:hover {
  color: var(--ink);
  background: rgba(23, 22, 27, 0.05);
}

#refresh-button svg {
  width: 16px;
  fill: none;
  stroke: currentColor;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 1.7;
}

#refresh-button.is-loading svg {
  animation: spin 0.8s linear infinite;
}

.jobs-grid {
  display: block;
}

.jobs-grid[aria-busy="true"] {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
}

.job-result-group + .job-result-group {
  margin-top: 52px;
}

.job-result-group-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  margin-bottom: 17px;
  padding-bottom: 13px;
  border-bottom: 1px solid var(--line);
}

.job-result-group-header h3 {
  margin: 0;
  font: 600 0.82rem/1.2 "Manrope", sans-serif;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.job-result-group-header span {
  color: var(--muted);
  font-size: 0.78rem;
}

.job-group-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
}

.pagination {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 14px;
  padding-top: 42px;
}

.pagination[hidden] {
  display: none;
}

.page-numbers {
  display: flex;
  align-items: center;
  gap: 7px;
}

.pagination button {
  min-width: 40px;
  height: 40px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 1px solid transparent;
  border-radius: 11px;
  color: var(--muted);
  background: transparent;
  font-size: 0.84rem;
  font-weight: 600;
  cursor: pointer;
  transition: color 160ms ease, border-color 160ms ease,
    background 160ms ease, transform 160ms ease;
}

.pagination button:hover:not(:disabled) {
  color: var(--ink);
  border-color: var(--line);
  background: var(--surface);
  transform: translateY(-1px);
}

.pagination button:focus-visible {
  outline: 3px solid rgba(112, 87, 232, 0.2);
  outline-offset: 2px;
}

.pagination .pagination-direction {
  width: auto;
  gap: 8px;
  padding: 0 12px;
}

.pagination .page-number.is-current {
  color: #fff;
  background: var(--ink);
  box-shadow: 0 7px 18px rgba(23, 22, 27, 0.16);
}

.pagination button:disabled {
  color: #b8b4bd;
  cursor: not-allowed;
}

.pagination-ellipsis {
  width: 24px;
  color: var(--muted);
  text-align: center;
}

.job-link {
  display: block;
  border-radius: var(--radius-md);
  text-decoration: none;
  outline: none;
}

.job-card {
  position: relative;
  min-height: 292px;
  display: flex;
  flex-direction: column;
  padding: 27px;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
  background: var(--surface);
  transition: transform 220ms ease, border-color 220ms ease, box-shadow 220ms ease;
}

.job-card::after {
  content: "";
  position: absolute;
  right: -45px;
  bottom: -60px;
  width: 150px;
  height: 150px;
  border-radius: 50%;
  background: var(--accent-soft);
  opacity: 0;
  transform: scale(0.7);
  transition: opacity 220ms ease, transform 280ms ease;
}

.job-link:hover .job-card,
.job-link:focus-visible .job-card {
  z-index: 1;
  border-color: rgba(112, 87, 232, 0.45);
  box-shadow: var(--shadow);
  transform: translateY(-4px);
}

.job-link:hover .job-card::after,
.job-link:focus-visible .job-card::after {
  opacity: 1;
  transform: scale(1);
}

.card-top,
.card-bottom {
  position: relative;
  z-index: 2;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.platform-name,
.posted-date {
  color: var(--muted);
  font-size: 0.78rem;
  font-weight: 500;
}

.platform-name {
  display: inline-flex;
  align-items: center;
  gap: 9px;
}

.platform-logo {
  width: 34px;
  height: 34px;
  display: block;
  flex: 0 0 auto;
  border: 1px solid rgba(23, 22, 27, 0.08);
  border-radius: 10px;
  object-fit: contain;
  box-shadow: 0 5px 14px rgba(31, 27, 44, 0.08);
}

.job-title {
  position: relative;
  z-index: 2;
  max-width: 92%;
  margin: 27px 0 18px;
  font: 600 clamp(1.25rem, 2.5vw, 1.6rem) / 1.25 "Manrope", sans-serif;
  letter-spacing: -0.04em;
}

.card-bottom {
  margin-top: auto;
}

.job-tags {
  position: relative;
  z-index: 2;
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
  margin-bottom: 25px;
}

.job-tag {
  padding: 7px 10px;
  border: 1px solid var(--line);
  border-radius: 100px;
  color: var(--muted);
  background: rgba(255, 255, 255, 0.52);
  font-size: 0.72rem;
  font-weight: 500;
}

.job-location {
  min-width: 0;
  display: inline-flex;
  align-items: center;
  gap: 7px;
  color: var(--muted);
  font-size: 0.76rem;
  line-height: 1.4;
}

.job-location svg {
  width: 16px;
  height: 16px;
  flex: 0 0 auto;
  fill: none;
  stroke: var(--accent);
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 1.55;
}

.job-location span {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.arrow {
  width: 36px;
  height: 36px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  color: var(--surface);
  background: var(--ink);
  transition: background 180ms ease, transform 180ms ease;
}

.job-link:hover .arrow,
.job-link:focus-visible .arrow {
  background: var(--accent);
  transform: rotate(-10deg);
}

.arrow svg {
  width: 16px;
  fill: none;
  stroke: currentColor;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 1.8;
}

.status-message {
  max-width: 720px;
  margin: 0 auto;
  padding: 56px 32px;
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
  color: var(--muted);
  background: var(--surface);
  box-shadow: 0 12px 35px rgba(31, 27, 44, 0.05);
  text-align: center;
  line-height: 1.6;
}

.status-message strong {
  display: block;
  margin-bottom: 7px;
  color: var(--ink);
  font: 600 1.1rem "Manrope", sans-serif;
}

.status-message button {
  margin-top: 16px;
  padding: 10px 15px;
  border: 0;
  border-radius: 10px;
  color: #fff;
  background: var(--accent);
  cursor: pointer;
}

.skeleton {
  min-height: 292px;
  padding: 27px;
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
  background: var(--surface);
  box-shadow: 0 8px 28px rgba(31, 27, 44, 0.035);
  animation: skeleton-pulse 1.8s ease-in-out infinite;
}

.skeleton-line {
  height: 12px;
  margin-bottom: 22px;
  border-radius: 10px;
  background: linear-gradient(90deg, #e6e3dd 25%, #f2efea 50%, #e6e3dd 75%);
  background-size: 200% 100%;
  animation: shimmer 1.4s infinite;
}

.skeleton-line.short {
  width: 34%;
}

.skeleton-line.title {
  width: 74%;
  height: 25px;
  margin-top: 50px;
}

footer {
  min-height: 150px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  border-top: 1px solid rgba(23, 22, 27, 0.1);
  color: var(--muted);
  font-size: 0.85rem;
}

footer a {
  color: var(--ink);
  font-weight: 600;
  text-decoration: none;
}

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

@keyframes shimmer {
  to {
    background-position-x: -200%;
  }
}

@keyframes skeleton-pulse {
  0%,
  100% {
    opacity: 0.72;
  }

  50% {
    opacity: 1;
  }
}

@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}

@media (max-width: 1180px) {
  .filter-panel {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .search-button {
    grid-column: 1 / -1;
  }
}

@media (max-width: 940px) {
  :root {
    --page-gutter: 40px;
  }

  .hero {
    grid-template-columns: 1fr;
    gap: 56px;
  }

  .hero-content {
    max-width: 760px;
  }

  .hero-visual {
    min-height: 360px;
  }

  .hero-visual img {
    max-width: 620px;
  }
}

@media (max-width: 760px) {
  :root {
    --page-gutter: 24px;
  }

  .site-header {
    min-height: 72px;
  }

  .brand-logo {
    width: 80px !important;
    height: auto !important;
    max-width: 80px;
    max-height: none;
  }

  .hero {
    padding: 38px 0 58px;
  }

  .hero h1 {
    font-size: clamp(3rem, 16vw, 5.2rem);
  }

  .hero-visual {
    min-height: 280px;
    padding: 18px;
  }

  .hero-meta {
    gap: 25px;
    justify-content: space-between;
  }

  .filter-panel {
    position: relative;
    top: 0;
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .search-button {
    grid-column: 1 / -1;
  }

  .results-header {
    align-items: flex-start;
    padding-top: 52px;
  }

  .results-actions {
    align-items: flex-end;
    flex-direction: column;
    gap: 6px;
  }

  .jobs-grid[aria-busy="true"],
  .job-group-grid {
    grid-template-columns: 1fr;
  }

  footer {
    min-height: 130px;
    align-items: flex-start;
    flex-direction: column;
    justify-content: center;
  }
}

@media (max-width: 430px) {
  .hero-meta {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
  }

  .hero-meta > div:last-child {
    grid-column: 1 / -1;
  }

  .filter-panel {
    grid-template-columns: 1fr;
  }

  .select-field,
  .sort-field,
  .search-button {
    width: 100%;
    grid-column: 1 / -1;
    min-width: 0;
  }

  .results-header {
    display: block;
  }

  .results-actions {
    margin-top: 18px;
    align-items: center;
    flex-direction: row;
    justify-content: space-between;
  }

  .pagination {
    gap: 6px;
  }

  .pagination .pagination-direction {
    padding: 0 8px;
    font-size: 0;
  }

  .pagination .pagination-direction span {
    font-size: 1rem;
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}
