/* ==========================================================================
   WorkJob.com — стили
   Мобайл-фёрст, аккуратный современный лук. Все цвета — через переменные.
   ========================================================================== */

:root {
  --red:        #e11d2a;
  --red-dark:   #b3121d;
  --red-soft:   #fde7e9;
  --ink:        #14181f;
  --ink-2:      #3a4250;
  --muted:      #6b7382;
  --line:       #e8eaef;
  --bg:         #f4f6f9;
  --card:       #ffffff;
  --green:      #0f7a40;
  --green-soft: #e6f6ee;
  --blue:       #1d4ed8;
  --blue-soft:  #e7efff;
  --violet:     #6d28d9;
  --violet-soft:#f0e9ff;
  --amber:      #8a5a10;
  --amber-soft: #fdf3df;
  --shadow:     0 2px 8px rgba(20, 24, 31, .06), 0 1px 2px rgba(20, 24, 31, .04);
  --shadow-lg:  0 12px 40px rgba(20, 24, 31, .14);
  --radius:     16px;
  --radius-sm:  10px;
  --maxw:       1180px;
  --font: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 74px; -webkit-text-size-adjust: 100%;
       scrollbar-gutter: stable; /* место под полосу прокрутки: окно/меню открылись — страница не сдвигается вбок */ }
/* видимый фокус для клавиатурной навигации */
:focus-visible { outline: 2px solid var(--red); outline-offset: 2px; border-radius: 8px; }
body {
  margin: 0;
  font-family: var(--font);
  color: var(--ink);
  background: var(--bg);
  line-height: 1.5;
  font-size: 16px;
  -webkit-font-smoothing: antialiased;
}
a { color: inherit; text-decoration: none; }
img { max-width: 100%; display: block; }
button { font-family: inherit; cursor: pointer; }
[hidden] { display: none !important; }
.container { width: 100%; max-width: var(--maxw); margin: 0 auto; padding: 0 16px; }

/* ----------------------------- Header ----------------------------- */
.site-header {
  position: sticky; top: 0; z-index: 40;
  background: rgba(255,255,255,.92);
  backdrop-filter: saturate(180%) blur(10px);
  border-bottom: 1px solid var(--line);
}
.site-header .container {
  display: flex; align-items: center; gap: 12px;
  height: 62px;
}
.brand { display: flex; align-items: center; gap: 9px; font-weight: 800; font-size: 19px; letter-spacing: -.02em; }
.brand .dot { color: var(--red); }
.brand .logo {
  width: 30px; height: 30px; border-radius: 8px;
  background: linear-gradient(135deg, var(--red), #ff5a4d);
  display: grid; place-items: center; color: #fff; font-size: 16px; font-weight: 900;
  box-shadow: 0 4px 12px rgba(225,29,42,.35);
}
.header-spacer { flex: 1; }
.header-actions { display: flex; align-items: center; gap: 10px; }
.btn-employers {
  background: var(--red); color: #fff; border: 0;
  padding: 11px 18px; min-height: 42px; border-radius: 999px; font-weight: 600; font-size: 14px;
  transition: background .15s ease, transform .1s ease;
}
.btn-employers:hover { background: var(--red-dark); }
.btn-employers:active { transform: scale(.97); }
.burger {
  width: 42px; height: 42px; padding: 0; border-radius: 10px; border: 1px solid var(--line);
  background: #fff; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 4px;
  cursor: pointer; transition: border-color .15s ease, background .15s ease;
}
.burger:hover { border-color: #cfd4dd; background: var(--bg); }
.burger span { display: block; width: 18px; height: 2px; background: var(--ink); border-radius: 2px; }

/* узкий телефон: «Работодателям» — в меню (кнопка .panel-cta), в шапке — логотип и меню */
.mobile-nav .panel-cta { display: none; }
@media (max-width: 479px) {
  .has-burger .btn-employers { display: none; }
  .mobile-nav .panel-cta { display: flex; flex: none; width: 100%; margin: 4px 0 10px; }
}

/* mobile nav drawer */
.nav-links { display: none; }
.mobile-nav {
  position: fixed; inset: 0; z-index: 60; visibility: hidden; opacity: 0;
  transition: opacity .2s ease, visibility .2s ease;
}
.mobile-nav.open { visibility: visible; opacity: 1; }
.mobile-nav .scrim { position: absolute; inset: 0; background: rgba(10,12,16,.45); }
.mobile-nav .panel {
  position: absolute; top: 0; right: 0; height: 100%; width: min(82%, 320px);
  background: #fff; box-shadow: var(--shadow-lg); padding: 18px;
  transform: translateX(100%); transition: transform .25s cubic-bezier(.4,0,.2,1);
  display: flex; flex-direction: column; gap: 6px;
}
.mobile-nav.open .panel { transform: translateX(0); }
.mobile-nav .panel a {
  padding: 13px 12px; border-radius: 10px; font-weight: 500; color: var(--ink-2);
}
.mobile-nav .panel a:hover { background: var(--bg); color: var(--ink); }
.mobile-nav .panel .close {
  align-self: flex-end; border: 0; background: var(--bg); width: 44px; height: 44px;
  border-radius: 10px; font-size: 20px; color: var(--ink-2);
}

/* ----------------------------- Hero ----------------------------- */
.hero {
  background:
    radial-gradient(1200px 380px at 80% -10%, rgba(225,29,42,.10), transparent 60%),
    linear-gradient(180deg, #ffffff 0%, #f4f6f9 100%);
  border-bottom: 1px solid var(--line);
  padding: 34px 0 26px;
}
.hero h1 {
  margin: 0 0 10px; font-size: 28px; line-height: 1.18; letter-spacing: -.025em;
  font-weight: 800;
}
.hero h1 .accent { color: var(--red); }
.hero h1 .br-desk { display: none; }
.hero p { margin: 0 0 18px; color: var(--ink-2); font-size: 15.5px; max-width: 640px; }
.hero-badges { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 18px; }
.hero-badges .chip {
  display: inline-flex; align-items: center; gap: 6px;
  background: #fff; border: 1px solid var(--line); color: var(--ink-2);
  padding: 7px 12px; border-radius: 999px; font-size: 13px; font-weight: 500;
  box-shadow: var(--shadow);
}
.hero-badges .chip .ok { color: var(--green); font-weight: 800; }

/* search + filters */
.controls { display: flex; flex-direction: column; gap: 12px; }
.search-box {
  display: flex; align-items: center; gap: 10px;
  background: #fff; border: 1px solid var(--line); border-radius: 12px;
  padding: 12px 14px; box-shadow: var(--shadow);
}
.search-box svg { flex: none; color: var(--muted); }
.search-box input {
  border: 0; outline: 0; width: 100%; font-size: 15.5px; color: var(--ink); background: transparent;
}
.filters { display: flex; gap: 8px; overflow-x: auto; padding-bottom: 4px; -webkit-overflow-scrolling: touch; }
.filters::-webkit-scrollbar { height: 0; }
.filter-chip {
  flex: none; border: 1px solid var(--line); background: #fff; color: var(--ink-2);
  padding: 11px 16px; min-height: 42px; border-radius: 999px; font-size: 14px; font-weight: 600;
  transition: all .15s ease; white-space: nowrap;
}
.filter-chip .count { color: var(--muted); font-weight: 600; margin-left: 5px; font-size: 12.5px; }
.filter-chip:hover { border-color: #cfd4dd; }
.filter-chip.active { background: var(--ink); color: #fff; border-color: var(--ink); }
.filter-chip.active .count { color: rgba(255,255,255,.65); }

/* ----------------------------- Listing ----------------------------- */
.listing { padding: 24px 0 56px; }
.listing-head { display: flex; align-items: baseline; justify-content: space-between; margin-bottom: 16px; }
.listing-head h2 { margin: 0; font-size: 19px; font-weight: 700; letter-spacing: -.01em; }
.listing-head .total { color: var(--muted); font-size: 14px; }

.grid {
  display: grid; gap: 16px;
  align-items: start;   /* каждая карточка — своей высоты: без фото не растягивается под соседнюю с фото */
  grid-template-columns: 1fr;
}

/* ----------------------------- Card ----------------------------- */
.card {
  background: var(--card); border: 1px solid var(--line); border-radius: var(--radius);
  box-shadow: var(--shadow); overflow: hidden;
  display: flex; flex-direction: column;
  transition: transform .15s ease, box-shadow .2s ease, border-color .2s ease;
}
.card:hover { transform: translateY(-3px); box-shadow: var(--shadow-lg); border-color: #dfe3ea; }
.card .urgent-ribbon {
  background: linear-gradient(90deg, var(--red), #ff5a4d); color: #fff;
  font-size: 12px; font-weight: 700; letter-spacing: .02em;
  padding: 6px 16px; display: flex; align-items: center; gap: 6px;
}
.card-photo { display: block; aspect-ratio: 16 / 9; overflow: hidden; background: var(--bg); }
.card-photo img { width: 100%; height: 100%; object-fit: cover; transition: transform .3s ease; }
.card:hover .card-photo img { transform: scale(1.03); }
.card-body { padding: 16px 16px 14px; display: flex; flex-direction: column; gap: 12px; }
.card-loc { display: flex; align-items: center; gap: 6px; color: var(--muted); font-size: 13px; font-weight: 500; }
.card-loc svg { flex: none; color: var(--red); }
.card-loc .country { color: var(--ink-2); font-weight: 600; }
.card h3 {
  margin: 0; font-size: 17px; line-height: 1.3; font-weight: 700; letter-spacing: -.01em;
  overflow-wrap: anywhere;
}
.card h3 a:hover { color: var(--red); }

.price {
  display: flex; align-items: baseline; gap: 8px; flex-wrap: wrap;
  background: var(--red-soft); border: 1px solid #f7ccd0;
  border-radius: 12px; padding: 11px 14px;
}
.price .amount { font-size: 23px; font-weight: 800; color: var(--red-dark); letter-spacing: -.02em; }
.price .period { font-size: 13px; color: var(--ink-2); font-weight: 500; }
.price .note { width: 100%; font-size: 12.5px; color: var(--muted); margin-top: 2px; }

.tags { display: flex; flex-wrap: wrap; gap: 6px; }
.tag {
  font-size: 12px; font-weight: 600; padding: 5px 10px; border-radius: 8px;
  border: 1px solid transparent; display: inline-flex; align-items: center; gap: 4px;
}
.tag.ok    { background: var(--green-soft);  color: var(--green);  border-color: #c9ecd8; }
.tag.info  { background: var(--blue-soft);   color: var(--blue);   border-color: #d3e2ff; }
.tag.visa  { background: var(--violet-soft); color: var(--violet); border-color: #e3d6ff; }
.tag.free  { background: var(--amber-soft);  color: var(--amber);  border-color: #f3e3bd; }

.card-intro { color: var(--ink-2); font-size: 14px; line-height: 1.5;
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }

.card-foot { display: flex; align-items: center; gap: 10px; padding: 0 16px 16px; }
.btn-apply {
  flex: 1; background: var(--red); color: #fff; border: 0; border-radius: 11px;
  padding: 12px 16px; font-weight: 700; font-size: 15px;
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  transition: background .15s ease, transform .1s ease;
}
.btn-apply:hover { background: var(--red-dark); }
.btn-apply:active { transform: scale(.98); }
.btn-detail {
  flex: none; border: 1px solid var(--line); background: #fff; color: var(--ink-2);
  border-radius: 11px; padding: 12px 16px; font-weight: 600; font-size: 14px;
}
.btn-detail:hover { border-color: #cfd4dd; color: var(--ink); }

.empty {
  text-align: center; padding: 60px 20px; color: var(--muted);
  border: 2px dashed var(--line); border-radius: var(--radius); background: #fff;
}
.empty strong { display: block; color: var(--ink-2); font-size: 17px; margin-bottom: 6px; }

/* ----------------------------- Reviews ----------------------------- */
.reviews { padding: 8px 0 56px; }
.reviews-summary {
  display: inline-flex; align-items: center; gap: 10px; flex-wrap: wrap;
  background: var(--card); border: 1px solid var(--line); border-radius: 999px;
  padding: 7px 14px; margin-bottom: 16px; box-shadow: var(--shadow); font-size: 14px; color: var(--ink-2);
}
.reviews-summary .avg { font-size: 18px; font-weight: 800; color: var(--ink); letter-spacing: -.02em; }
.stars { display: inline-flex; gap: 1px; color: #f5a524; font-size: 16px; line-height: 1; letter-spacing: 0; }
.stars .off { color: #dfe3ea; }
/* отзывы — одна строка с прокруткой вбок: 1 / 2 / 3 карточки на экране */
.reviews-track {
  display: grid; gap: 16px; grid-auto-flow: column; grid-auto-columns: 86%;
  overflow-x: auto; scroll-snap-type: x mandatory; padding: 2px 16px 10px; margin: 0 -16px;
  scrollbar-width: none;
}
.reviews-track::-webkit-scrollbar { display: none; }
/* телефон: карточка по высоте своего текста; под лентой — точки-индикатор */
@media (max-width: 599px) {
  .reviews-track { align-items: start; }
  .reviews-nav button { width: 36px; height: 36px; font-size: 20px; }
}
.reviews-dots { display: flex; justify-content: center; flex-wrap: wrap; gap: 4px; margin-top: 6px; }
.reviews-dots button {
  width: 22px; height: 22px; padding: 0; border: 0; background: none; display: grid; place-items: center; cursor: pointer;
}
.reviews-dots button::before {
  content: ""; width: 8px; height: 8px; border-radius: 50%; background: #d5d9e1; transition: background .15s ease, width .15s ease;
}
.reviews-dots button.active::before { width: 20px; border-radius: 4px; background: var(--red); }
.reviews .listing-head { align-items: center; }
/* стрелки по бокам ленты: слой поверх ленты, клики проходят только в кнопки */
.reviews-carousel { position: relative; }
.reviews-nav {
  position: absolute; top: 0; bottom: 12px; left: -8px; right: -8px; z-index: 2;
  display: flex; justify-content: space-between; align-items: center; pointer-events: none;
}
.reviews-nav[hidden] { display: none; }
.reviews-nav button { pointer-events: auto; }
.reviews-nav button:disabled { visibility: hidden; }
.reviews-nav button {
  width: 40px; height: 40px; border-radius: 50%; border: 1px solid var(--line); background: var(--card);
  color: var(--ink); font-size: 22px; line-height: 1; display: grid; place-items: center;
  box-shadow: var(--shadow); transition: border-color .15s ease, color .15s ease, opacity .15s ease;
}
.reviews-nav button:hover:not(:disabled) { border-color: var(--red); color: var(--red); }

/* переключатель страниц (вакансии) */
.pager { display: flex; justify-content: center; align-items: center; gap: 6px; flex-wrap: wrap; margin-top: 24px; }
.pager button {
  min-width: 40px; height: 40px; padding: 0 12px; border-radius: 999px;
  border: 1px solid var(--line); background: var(--card); color: var(--ink-2);
  font-size: 14px; font-weight: 600; box-shadow: var(--shadow);
  transition: border-color .15s ease, color .15s ease, background .15s ease;
}
.pager button:hover:not(:disabled):not(.active) { border-color: #cfd4dd; color: var(--ink); }
.pager button.active { background: var(--ink); border-color: var(--ink); color: #fff; }
.pager button:disabled { opacity: .35; cursor: default; box-shadow: none; }
.pager .arrow { font-size: 20px; line-height: 1; }
.pager .gap { color: var(--muted); padding: 0 2px; font-weight: 600; }

.review {
  scroll-snap-align: center;
  background: var(--card); border: 1px solid var(--line); border-radius: var(--radius);
  box-shadow: var(--shadow); padding: 18px 18px 16px;
  display: flex; flex-direction: column; gap: 12px; position: relative;
}
.review::before {
  content: "“"; position: absolute; top: 4px; right: 16px;
  font-size: 64px; line-height: 1; font-weight: 800; color: var(--red-soft); pointer-events: none;
}
.review-text {
  margin: 0; color: var(--ink-2); font-size: 14.5px; line-height: 1.55; white-space: pre-line;
  display: -webkit-box; -webkit-line-clamp: 6; -webkit-box-orient: vertical; overflow: hidden;
}
.review.open .review-text { -webkit-line-clamp: unset; display: block; }
.review-more {
  align-self: flex-start; background: none; border: 0; padding: 0;
  color: var(--red); font-weight: 600; font-size: 13.5px;
}
.review-more:hover { color: var(--red-dark); }
.review-job { align-self: flex-start; }
.review-foot { display: flex; align-items: center; gap: 11px; margin-top: auto; padding-top: 12px; border-top: 1px solid var(--line); }
.review-avatar {
  width: 40px; height: 40px; border-radius: 50%; flex: none;
  display: grid; place-items: center; color: #fff; font-weight: 800; font-size: 15px;
  background: linear-gradient(135deg, var(--red), #ff5a4d);
}
.review-avatar.c1 { background: linear-gradient(135deg, #1d4ed8, #4f7cff); }
.review-avatar.c2 { background: linear-gradient(135deg, #0f7a40, #22b36a); }
.review-avatar.c3 { background: linear-gradient(135deg, #6d28d9, #9a63ff); }
.review-who { min-width: 0; }
.review-name { font-weight: 700; font-size: 14.5px; }
.review-meta { color: var(--muted); font-size: 12.5px; }

/* ----------------------------- Footer ----------------------------- */
.site-footer {
  background: var(--ink); color: #c9cfda; padding: 36px 0 28px; margin-top: auto;
}
.footer-grid { display: grid; gap: 24px; grid-template-columns: 1fr; }
.site-footer .brand { color: #fff; }
.site-footer .brand .logo { box-shadow: none; }
.footer-col h4 { color: #fff; font-size: 14px; margin: 0 0 12px; font-weight: 700; text-transform: uppercase; letter-spacing: .04em; }
.footer-col a, .footer-col p { display: block; color: #aab2c0; font-size: 14px; margin: 0 0 9px; transition: color .15s; }
.footer-col a:hover { color: #fff; }
.footer-about { color: #9aa3b2; font-size: 13.5px; line-height: 1.6; max-width: 320px; margin: 12px 0 0; }
.footer-bottom {
  border-top: 1px solid rgba(255,255,255,.1); margin-top: 26px; padding-top: 18px;
  font-size: 12.5px; color: #828b9b; display: flex; flex-wrap: wrap; gap: 6px 16px; justify-content: space-between;
}

/* ----------------------------- Modal (apply form) ----------------------------- */
.modal {
  position: fixed; inset: 0; z-index: 80; display: grid; place-items: center;
  padding: 16px; visibility: hidden; opacity: 0;
  transition: opacity .2s ease, visibility .2s ease;
}
.modal.open { visibility: visible; opacity: 1; }
.modal .scrim { position: absolute; inset: 0; background: rgba(10,12,16,.55); }
.modal .dialog {
  position: relative; width: 100%; max-width: 400px; background: #fff;
  max-height: calc(100dvh - 32px); overflow-y: auto; overscroll-behavior: contain; /* длинная форма — прокрутка внутри окна */
  border-radius: 18px; box-shadow: var(--shadow-lg); padding: 24px 22px 22px;
  transform: translateY(12px) scale(.98); transition: transform .22s cubic-bezier(.4,0,.2,1);
}
.modal.open .dialog { transform: translateY(0) scale(1); }
.modal .dialog .x {
  position: absolute; top: 12px; right: 12px; width: 44px; height: 44px;
  border: 0; background: var(--bg); border-radius: 10px; color: var(--ink-2); font-size: 18px;
}
.modal h3 { margin: 0 0 4px; font-size: 21px; font-weight: 800; letter-spacing: -.01em; }
.modal .for-vacancy { color: var(--muted); font-size: 13.5px; margin: 0 0 18px; }
.modal .for-vacancy strong { color: var(--ink-2); }

.field label { display: block; font-size: 13px; font-weight: 600; color: var(--ink-2); margin-bottom: 7px; }
.field input[type="tel"] {
  width: 100%; border: 1.5px solid var(--line); border-radius: 12px;
  padding: 14px 14px; font-size: 17px; letter-spacing: .02em; color: var(--ink); outline: 0;
  transition: border-color .15s ease, box-shadow .15s ease;
}
.field input[type="tel"]:focus { border-color: var(--red); box-shadow: 0 0 0 3px rgba(225,29,42,.12); }
.field input[type="tel"].invalid { border-color: #f0b4b9; }
.field .hint { font-size: 12px; color: var(--muted); margin-top: 6px; }
/* форма «Работодателям»: текстовые поля, списки, комментарий */
.emp-fields { display: flex; flex-direction: column; gap: 12px; margin-bottom: 12px; }
.emp-fields + .field-channels { margin-top: 3px; }
.field input[type="text"], .field select, .field textarea {
  width: 100%; border: 1.5px solid var(--line); border-radius: 12px; background: #fff;
  padding: 12px 13px; font: inherit; font-size: 15px; color: var(--ink); outline: 0;
  transition: border-color .15s ease, box-shadow .15s ease;
}
.field textarea { resize: vertical; min-height: 76px; line-height: 1.45; }
.field input[type="text"]:focus, .field select:focus, .field textarea:focus { border-color: var(--red); box-shadow: 0 0 0 3px rgba(225,29,42,.12); }
.field-row { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.field-row .field label { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.field + .emp-fields { margin-top: 14px; }
@media (max-width: 419px) { .field-row { grid-template-columns: 1fr; } }
.field .hint.error { color: var(--red); }

/* выбор мессенджера */
.field-channels { margin-top: 15px; }
.ch-label { display: block; font-size: 13px; font-weight: 600; color: var(--ink-2); margin-bottom: 8px; }
.ch-opts { display: flex; gap: 8px; flex-wrap: wrap; }
.ch {
  display: inline-flex; align-items: center; gap: 6px; cursor: pointer; user-select: none;
  border: 1.5px solid var(--line); background: #fff; border-radius: 10px;
  padding: 8px 12px; font-size: 13.5px; font-weight: 600; color: var(--ink-2);
  transition: border-color .15s ease, background .15s ease, color .15s ease;
}
.ch input { position: absolute; opacity: 0; width: 0; height: 0; }
.ch svg { flex: none; }
.ch:hover { border-color: #cfd4dd; }
.ch-tg svg { color: #229ED9; } .ch-wa svg { color: #25D366; }
.ch-tg:has(input:checked) { border-color: #229ED9; background: #e9f6fc; color: #1a7fb0; }
.ch-wa:has(input:checked) { border-color: #25D366; background: #e8f9ef; color: #1a9c4d; }
.ch:focus-within { box-shadow: 0 0 0 3px rgba(225,29,42,.12); }

/* ловушка для ботов — за пределами экрана (не display:none: такие поля боты пропускают) */
.hp-field { position: absolute; left: -10000px; top: auto; width: 1px; height: 1px; overflow: hidden; }
.agreements { margin: 16px 0 6px; display: flex; flex-direction: column; gap: 11px; }
.checkrow { display: flex; align-items: flex-start; gap: 10px; font-size: 12.5px; color: var(--ink-2); line-height: 1.45; }
.checkrow input { margin: 1px 0 0; width: 17px; height: 17px; accent-color: var(--red); flex: none; }
.checkrow a { color: var(--blue); font-weight: 600; }
.checkrow a:hover { text-decoration: underline; }

.modal-actions { display: flex; gap: 10px; margin-top: 16px; }
.modal-actions .cancel {
  flex: 1; border: 1px solid var(--line); background: #fff; color: var(--ink-2);
  padding: 13px; border-radius: 12px; font-weight: 600; font-size: 15px;
}
.modal-actions .cancel:hover { background: var(--bg); }
.modal-actions .submit {
  flex: 1.4; border: 0; background: var(--red); color: #fff;
  padding: 13px; border-radius: 12px; font-weight: 700; font-size: 15px;
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  transition: background .15s ease, opacity .15s ease;
}
.modal-actions .submit:disabled { background: #f1b5ba; cursor: not-allowed; }
.modal-actions .submit:not(:disabled):hover { background: var(--red-dark); }

.spinner {
  width: 16px; height: 16px; border: 2px solid rgba(255,255,255,.45); border-top-color: #fff;
  border-radius: 50%; animation: spin .7s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }

/* success state */
.modal-success { text-align: center; padding: 8px 4px 4px; }
.modal-success .check {
  width: 64px; height: 64px; margin: 4px auto 16px; border-radius: 50%;
  background: var(--green-soft); display: grid; place-items: center; color: var(--green);
  animation: pop .3s cubic-bezier(.4,0,.2,1);
}
@keyframes pop { 0% { transform: scale(.6); opacity: 0; } 100% { transform: scale(1); opacity: 1; } }
.modal-success h3 { margin-bottom: 8px; }
.modal-success p { color: var(--ink-2); font-size: 14.5px; margin: 0 0 20px; }
.modal-success .done {
  border: 0; background: var(--ink); color: #fff; padding: 13px 28px; border-radius: 12px; font-weight: 600;
}

/* ----------------------------- Vacancy detail page ----------------------------- */
.detail { padding: 22px 0 60px; }
.breadcrumbs { font-size: 13.5px; color: var(--muted); margin-bottom: 16px; display: flex; align-items: center; gap: 7px; flex-wrap: wrap; }
.breadcrumbs a:hover { color: var(--red); }
.breadcrumbs .sep { color: #cfd4dd; }
.detail-layout { display: grid; gap: 20px; grid-template-columns: 1fr; }
.detail-main { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow); padding: 22px 20px; }
.detail-main .urgent-ribbon { display: inline-flex; border-radius: 8px; margin-bottom: 14px; }
/* фото вакансии — на всю ширину карточки сверху */
.detail-photo {
  display: block; width: calc(100% + 40px); max-width: none; height: auto; aspect-ratio: 16 / 9; object-fit: cover;
  margin: -22px -20px 20px; border-radius: var(--radius) var(--radius) 0 0; background: var(--bg);
}
.detail-main h1 { margin: 0 0 12px; font-size: 25px; line-height: 1.22; letter-spacing: -.02em; font-weight: 800; }
.detail-loc { display: flex; align-items: center; gap: 7px; color: var(--ink-2); font-size: 15px; font-weight: 500; margin-bottom: 16px; }
.detail-loc svg { color: var(--red); flex: none; }
.detail-loc .note { color: var(--muted); font-weight: 400; }
.detail-intro { color: var(--ink-2); font-size: 15.5px; line-height: 1.6; margin: 0 0 20px; }
.detail .tags { margin-bottom: 20px; }

.section { margin-bottom: 22px; }
.section:last-child { margin-bottom: 0; }
.section h2 {
  font-size: 15px; font-weight: 800; text-transform: uppercase; letter-spacing: .04em;
  color: var(--ink); margin: 0 0 12px; display: flex; align-items: center; gap: 9px;
}
.section h2::before { content: ""; width: 4px; height: 16px; background: var(--red); border-radius: 3px; }
.section ul { margin: 0; padding: 0; list-style: none; display: flex; flex-direction: column; gap: 9px; }
.section li { position: relative; padding-left: 26px; color: var(--ink-2); font-size: 15px; line-height: 1.5; }
.section li::before {
  content: ""; position: absolute; left: 4px; top: 8px; width: 7px; height: 7px;
  background: var(--red); border-radius: 50%;
}

/* sticky apply aside */
.detail-aside { position: relative; }
.apply-card {
  background: #fff; border: 1px solid var(--line); border-radius: var(--radius);
  box-shadow: var(--shadow); padding: 20px; position: sticky; top: 78px;
}
.apply-card .price { margin-bottom: 16px; }
.apply-card .perk { display: flex; align-items: center; gap: 9px; font-size: 13.5px; color: var(--ink-2); margin-bottom: 10px; }
.apply-card .perk svg { color: var(--green); flex: none; }
.apply-card .btn-apply { width: 100%; margin-top: 6px; padding: 14px; font-size: 16px; }
.apply-card .reassure { text-align: center; font-size: 12px; color: var(--muted); margin: 12px 0 0; }

/* mobile sticky apply bar */
.apply-bar {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 50;
  background: #fff; border-top: 1px solid var(--line);
  padding: 10px 16px calc(10px + env(safe-area-inset-bottom));
  display: flex; align-items: center; gap: 12px; box-shadow: 0 -6px 24px rgba(20,24,31,.08);
}
.apply-bar .ab-price { display: flex; flex-direction: column; line-height: 1.1; }
.apply-bar .ab-price .amount { font-size: 18px; font-weight: 800; color: var(--red-dark); }
.apply-bar .ab-price .period { font-size: 11.5px; color: var(--muted); }
.apply-bar .btn-apply { flex: 1; padding: 13px; }

/* legal / static pages */
.legal { padding: 28px 0 60px; }
.legal-card { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow); padding: 26px 22px; max-width: 760px; margin: 0 auto; }
.legal-card h1 { font-size: 24px; margin: 0 0 6px; letter-spacing: -.02em; }
.legal-card .updated { color: var(--muted); font-size: 13px; margin: 0 0 22px; }
.legal-card h2 { font-size: 17px; margin: 24px 0 10px; }
.legal-card p, .legal-card li { color: var(--ink-2); font-size: 14.5px; line-height: 1.65; }
.legal-card ul { padding-left: 20px; }
.legal-card a { color: var(--blue); }

/* ----------------------------- Главная: hero-кнопки, страны, превью ----------------------------- */
.hero-actions { display: flex; flex-wrap: wrap; gap: 10px; }
.hero-actions .btn-apply { flex: none; padding: 14px 22px; font-size: 15.5px; }
.hero-actions .btn-detail { padding: 14px 20px; font-size: 15px; }
.hero-count { opacity: .85; font-weight: 600; }

/* глобус — фон hero главной: левая половина шара у правого края экрана, по высоте — во весь hero.
   На телефоне и планшете — полупрозрачный под текстом, на ПК — яркий справа */
.hero-home { position: relative; overflow: hidden; }
.hero-home .container { position: relative; z-index: 1; }
.hero-globe { position: absolute; z-index: 0; top: 8px; bottom: 8px; right: 0; pointer-events: none; line-height: 0; opacity: .4; }
.hero-globe-svg { display: block; height: 100%; width: auto; }
/* полное меню в шапке — только когда оно помещается вместе с «Работодателям»; уже — кнопка ☰ */
@media (min-width: 1100px) {
  .nav-links { display: flex; gap: 4px; }
  .nav-links a { padding: 8px 13px; border-radius: 9px; font-size: 14.5px; font-weight: 500; color: var(--ink-2); white-space: nowrap; }
  .nav-links a:hover { background: var(--bg); color: var(--ink); }
  .burger { display: none; }
}
@media (min-width: 1000px) { .hero-globe a { pointer-events: auto; cursor: pointer; } }
.g-grat { fill: none; stroke: var(--red); stroke-opacity: .10; stroke-width: 1; }
.g-land { fill: #f6d3d7; stroke: #fff; stroke-width: .7; stroke-linejoin: round; }
.map-country path { fill: var(--red); stroke: var(--red-dark); stroke-width: .8; stroke-linejoin: round; transition: fill .15s ease; }
.map-country:hover path { fill: var(--red-dark); }

.listing-preview { padding-top: 28px; }
.see-all { color: var(--red); font-weight: 600; font-size: 14.5px; }
.see-all:hover { color: var(--red-dark); }
.preview-more { display: flex; justify-content: center; margin-top: 20px; }

/* ----------------------------- Info sections (главная) ----------------------------- */
.info-sec { padding: 44px 0; }
.info-alt { background: #fff; border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.info-head { max-width: 680px; margin-bottom: 22px; }
.info-head h2 { margin: 0 0 8px; font-size: 24px; font-weight: 800; letter-spacing: -.02em; line-height: 1.2; }
.info-head p { margin: 0; color: var(--ink-2); font-size: 15px; line-height: 1.6; }
.info-sec h3 { margin: 0 0 6px; font-size: 16px; font-weight: 700; letter-spacing: -.01em; }
.info-sec .step p, .info-sec .feature p { margin: 0; color: var(--ink-2); font-size: 14px; line-height: 1.55; }

.steps { list-style: none; margin: 0; padding: 0; display: grid; gap: 12px; grid-template-columns: 1fr; }
.step {
  background: var(--card); border: 1px solid var(--line); border-radius: var(--radius);
  box-shadow: var(--shadow); padding: 18px;
}
.step-num {
  display: inline-flex; align-items: center; justify-content: center;
  width: 34px; height: 34px; border-radius: 10px; margin-bottom: 12px;
  background: var(--red-soft); color: var(--red); font-weight: 800; font-size: 16px;
}

.features { display: grid; gap: 12px; grid-template-columns: 1fr; }
.feature { background: var(--bg); border: 1px solid var(--line); border-radius: var(--radius); padding: 18px; }
.info-sec:not(.info-alt) .feature { background: var(--card); box-shadow: var(--shadow); }
.feature-ico { display: block; font-size: 24px; line-height: 1; margin-bottom: 12px; }

.faq { display: flex; flex-direction: column; gap: 10px; max-width: 820px; }
.faq details { background: var(--bg); border: 1px solid var(--line); border-radius: var(--radius-sm); }
.faq details[open] { background: #fff; box-shadow: var(--shadow); }
.faq summary {
  cursor: pointer; list-style: none; padding: 15px 44px 15px 16px; position: relative;
  font-weight: 600; font-size: 15px;
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after {
  content: "+"; position: absolute; right: 16px; top: 50%; transform: translateY(-50%);
  color: var(--red); font-size: 22px; font-weight: 500; line-height: 1;
}
.faq details[open] summary::after { content: "−"; }
.faq details p { margin: 0; padding: 0 16px 16px; color: var(--ink-2); font-size: 14.5px; line-height: 1.6; }

.cta { padding: 44px 0 56px; }
.cta-box {
  display: flex; flex-direction: column; gap: 18px;
  background: linear-gradient(135deg, var(--red) 0%, var(--red-dark) 100%); color: #fff;
  border-radius: var(--radius); padding: 26px 22px; box-shadow: var(--shadow-lg);
}
.cta-box h2 { margin: 0 0 6px; font-size: 22px; font-weight: 800; letter-spacing: -.02em; }
.cta-box p { margin: 0; opacity: .92; font-size: 15px; line-height: 1.55; }
.cta-box .cta-btn { flex: none; background: #fff; color: var(--red); }
.cta-box .cta-btn:hover { background: var(--red-soft); }

/* ----------------------------- Responsive ----------------------------- */
@media (min-width: 600px) {
  .hero { padding: 46px 0 30px; }
  .hero-home .container > * { max-width: 560px; }
  .hero h1 { font-size: 36px; }
  .controls { flex-direction: row; align-items: center; }
  .search-box { flex: 1; }
  .grid { grid-template-columns: repeat(2, 1fr); }
  .reviews-track { grid-auto-columns: calc((100% - 16px) / 2 - 24px); margin: 0; padding: 4px 0 14px; }
  .reviews-carousel { padding: 0 30px; }
  .reviews-nav { left: -12px; right: -12px; }
  .review { scroll-snap-align: start; }
  .steps, .features { grid-template-columns: repeat(2, 1fr); }
  .info-head h2 { font-size: 28px; }
}
@media (min-width: 760px) {
  .footer-grid { grid-template-columns: 1.5fr 1fr 1fr; }
  .detail-layout { grid-template-columns: 1fr 320px; align-items: start; }
  .apply-bar { display: none; }
  .detail { padding-bottom: 60px; }
  .cta-box { flex-direction: row; align-items: center; justify-content: space-between; padding: 32px 34px; }
}
@media (min-width: 1000px) {
  .hero h1 { font-size: 42px; }
  .hero-home { padding: 96px 0 72px; min-height: 420px; }
  /* текст — до глобуса с зазором ~64px: левый край шара = 6.7% ширины --gw от его блока */
  .hero-home { --gw: min(41vw, 700px); --tw: calc(100vw - var(--gw) * .933 - 64px - max(16px, (100vw - var(--maxw)) / 2 + 16px));
    min-height: 540px; display: flex; align-items: center; }
  .hero-home .container > * { max-width: var(--tw); }
  /* заголовок: «Начните зарабатывать в Европе» (~15.8em шириной) — одной строкой; у заголовка край шара
     правее самой левой точки, поэтому ему можно на 32px шире */
  .hero-home .container > h1 { max-width: calc(var(--tw) + 32px); font-size: clamp(38px, (var(--tw) + 32px) / 15.8, 50px); }
  .hero-home h1 .br-desk { display: inline; }
  /* ПК: чуть меньше половины экрана по ширине. Шар выше hero: Европа — по центру hero,
     сверху обрезан краем hero, вниз продолжается фоном под следующим блоком */
  .hero-home { overflow: visible; }
  .hero-globe { opacity: 1; top: 0; bottom: auto; width: var(--gw); clip-path: inset(0 0 -4000px 0); }
  .hero-globe .hero-globe-svg { width: 100%; height: auto; margin-top: calc(270px - var(--gw) * .93); }
  /* блоки после hero — поверх глобуса (только разделы страницы: окна заявки и меню не трогаем) */
  .hero-home ~ section, .hero-home ~ main, .hero-home ~ footer { position: relative; z-index: 1; }
  .grid { grid-template-columns: repeat(3, 1fr); }
  /* ровно 3 отзыва в ряд, остальные — прокруткой вбок */
  .reviews-track { grid-auto-columns: calc((100% - 32px) / 3); }
  .steps, .features { grid-template-columns: repeat(3, 1fr); }
  #docs .features { grid-template-columns: repeat(4, 1fr); }
}
@media (max-width: 759px) {
  /* extra bottom space on detail page so sticky bar doesn't cover content */
  .detail { padding-bottom: 88px; }
  .detail-aside { display: none; }
}

/* ----------------------------- 404 ----------------------------- */
.not-found { text-align: center; padding: 40px 22px; }
.legal-card .nf-code { margin: 0; font-size: 64px; font-weight: 900; line-height: 1; color: var(--red); letter-spacing: -.04em; }
.not-found h1 { margin: 10px 0 8px; }
.not-found p { color: var(--ink-2); }
.nf-actions { justify-content: center; margin-top: 20px; }
.legal-card .nf-actions .btn-apply { color: #fff; }
.legal-card .nf-actions .btn-detail { color: var(--ink-2); }
