/* Verktygshubben /verktyg/ i startsidans stil – förslag 8/10 2026 (bygg_verktyg_hubb_forslag.py).
   Bygger på sx-* ur bygg_startsida.py (tokens --sx-*, .sx-rad, .sx-band, .sx-ogon, .sx-h2, .sx-form). */

main section { scroll-margin-top: 64px; }
@media (prefers-reduced-motion: no-preference) { html { scroll-behavior: smooth; } }

/* hjälte med sökrutan */
.vh-hero { position: relative; color: #fff; background: var(--sx-ink); overflow: hidden; isolation: isolate; }
.vh-hero > img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; object-position: 70% 40%; z-index: -2; }
.vh-hero::before { content: ""; position: absolute; inset: 0; z-index: -1;
  background: linear-gradient(90deg, rgba(20,12,24,.94) 0%, rgba(20,12,24,.8) 45%, rgba(20,12,24,.25) 100%); }
.vh-hero .sx-rad { padding-top: clamp(60px, 8vw, 120px); padding-bottom: clamp(48px, 6vw, 88px); }
.vh-hero .sx-ogon { color: var(--sx-acc2); }
.vh-hero h1 { font-size: clamp(32px, 1.6rem + 2.6vw, 60px); font-weight: 800; line-height: 1.05; letter-spacing: -.025em; margin: 0 0 18px; max-width: 18ch; color: #fff; text-wrap: balance; }
.vh-hero h1 em { font-style: normal; color: var(--sx-acc2); }
.vh-hero__ingress { font-size: clamp(16px, 1rem + .3vw, 19px); line-height: 1.55; max-width: 50ch; margin: 0 0 28px; color: rgba(255,255,255,.88); }
.vh-sok { max-width: 620px; margin: 0; }
.vh-sok label { display: block; font-size: 13px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: rgba(255,255,255,.75); margin: 0 0 8px; }
.vh-sok__falt { position: relative; }
.vh-sok__falt::before { content: ""; position: absolute; left: 18px; top: 50%; width: 16px; height: 16px; margin-top: -10px; border: 2.5px solid var(--sx-mute); border-radius: 50%; box-sizing: border-box; }
.vh-sok__falt::after { content: ""; position: absolute; left: 31px; top: 50%; width: 8px; height: 2.5px; margin-top: 3px; background: var(--sx-mute); transform: rotate(45deg); }
.vh-sok input { width: 100%; font: inherit; font-size: 17px; padding: 16px 18px 16px 48px; border: 2px solid #fff; border-radius: 999px; background: #fff; color: var(--sx-ink); box-shadow: 0 18px 50px rgba(0,0,0,.35); }
.vh-sok input:focus { outline: none; border-color: var(--sx-acc); }
.vh-sok input::-webkit-search-cancel-button { cursor: pointer; }
.vh-sok__traff { margin: 10px 0 0 4px; min-height: 1.5em; font-size: 14.5px; color: rgba(255,255,255,.85); }

/* brödsmula och byline i hjälten */
.vh-brod { font-size: 14px; color: rgba(255,255,255,.7); margin: 0 0 22px; display: flex; gap: 10px; align-items: center; }
.vh-brod a { color: #fff; text-decoration: none; font-weight: 600; }
.vh-brod a:hover { text-decoration: underline; text-underline-offset: 4px; }
.vh-byline { display: flex; align-items: center; gap: 10px; margin: 26px 0 0; font-size: 14px; color: rgba(255,255,255,.75); }
.vh-byline strong, .vh-byline a { color: #fff; text-decoration: none; }
.vh-byline a:hover { text-decoration: underline; text-underline-offset: 4px; }
.vh-byline__m { flex: none; width: 30px; height: 30px; border-radius: 50%; display: grid; place-items: center; background: var(--sx-acc); color: var(--sx-ink); font-weight: 800; font-size: 15px; }
.vh-alla { color: var(--sx-lila); text-decoration: none; border-bottom: 2px solid var(--sx-acc); padding-bottom: 2px; }
.vh-alla:hover { border-color: var(--sx-lila); }

/* klibbig hopplist under hjälten (samma som yrkesnavet) */
.vh-nav { position: sticky; top: 0; z-index: 5; background: rgba(255,255,255,.94); backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px); border-bottom: 1px solid var(--sx-line); }
.vh-nav ul { list-style: none; margin: 0; padding: 0; display: flex; gap: clamp(20px, 2.8vw, 40px); overflow-x: auto; scrollbar-width: none; }
.vh-nav ul::-webkit-scrollbar { display: none; }
.vh-nav a { display: inline-flex; align-items: baseline; gap: 7px; padding: 17px 0 15px; border-bottom: 2px solid transparent; font-size: 14.5px; font-weight: 600; color: var(--sx-ink); text-decoration: none; white-space: nowrap; transition: color .15s, border-color .15s; }
.vh-nav a span { font-size: 12px; font-weight: 700; color: var(--sx-mute); }
.vh-nav a:hover, .vh-nav a.ar-har { color: var(--sx-lila); border-color: var(--sx-acc); }
.vh-nav a:focus-visible { outline-offset: -4px; }

/* sektionshuvud */
.vh-huvud { display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: end; gap: 16px 48px; margin-bottom: clamp(26px, 3.5vw, 44px); }
.vh-huvud .sx-h2 { margin-bottom: 10px; }
.vh-huvud .sx-lead { margin: 0; }
.vh-antal { margin: 0 0 6px; font-size: 14px; font-weight: 700; color: var(--sx-mute); white-space: nowrap; }

/* mest använda: åtta stora kort */
.vh-topp { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; }
.vh-topp li[hidden] { display: none; }
.vh-topp a { display: grid; align-content: start; gap: 8px; height: 100%; padding: 24px 22px 20px; border: 1px solid var(--sx-line); border-radius: 16px; background: #fff; text-decoration: none; color: inherit; position: relative; overflow: hidden; transition: border-color .15s, box-shadow .15s, transform .15s; }
.vh-topp a::before { content: ""; position: absolute; left: 22px; top: 0; width: 36px; height: 4px; background: var(--sx-acc); border-radius: 0 0 2px 2px; transition: width .25s; }
.vh-topp a:hover, .vh-topp a:focus-visible { border-color: var(--sx-lila); box-shadow: 0 14px 34px rgba(86,13,112,.12); transform: translateY(-2px); }
.vh-topp a:hover::before { width: 64px; }
.vh-topp__kat { font-size: 12px; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; color: var(--sx-lila); margin-top: 6px; }
.vh-topp strong { display: block; font-size: 20px; font-weight: 800; line-height: 1.2; letter-spacing: -.015em; color: var(--sx-ink); }
.vh-topp p { margin: 0; font-size: 14.5px; line-height: 1.5; color: var(--sx-mute); }
.vh-topp__pil { font-size: 14.5px; font-weight: 700; color: var(--sx-lila); margin-top: 8px; }
.vh-topp a:hover .vh-topp__pil { text-decoration: underline; text-underline-offset: 4px; text-decoration-color: var(--sx-acc); }

/* kategori: foto + register med hårlinjer och pil */
.vh-kat { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); gap: clamp(28px, 5vw, 64px); align-items: start; }
.vh-foto { margin: 0; border-radius: 14px; overflow: hidden; aspect-ratio: 4/3; background: var(--sx-ink); position: sticky; top: 76px; }
.vh-foto img { width: 100%; height: 100%; object-fit: cover; display: block; }
.vh-lista { list-style: none; margin: 0; padding: 0; border-top: 1px solid var(--sx-line); }
.vh-lista--2 { columns: 2; column-gap: clamp(24px, 4vw, 48px); }
.vh-lista li { break-inside: avoid; }
.vh-lista a { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 11px 0; border-bottom: 1px solid var(--sx-line); font-size: 15.5px; font-weight: 500; line-height: 1.3; color: var(--sx-ink); text-decoration: none; }
.vh-lista a::after { content: "→"; color: var(--sx-mute); font-weight: 400; transition: transform .15s, color .15s; }
.vh-lista a:hover { color: var(--sx-lila); }
.vh-lista a:hover::after { color: var(--sx-lila); transform: translateX(3px); }
.vh-lista li[hidden] { display: none; }

/* hopfällda register (Blanketter, Policyer på mobil) och "alla för jobbsökande" */
.vh-mer { margin-top: 22px; border-top: 1px solid var(--sx-line); }
.vh-mer > summary, .vh-fall > summary { list-style: none; cursor: pointer; display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 14px 0; font-size: 15px; font-weight: 700; color: var(--sx-lila); }
.vh-mer > summary::-webkit-details-marker, .vh-fall > summary::-webkit-details-marker { display: none; }
.vh-mer > summary::after, .vh-fall > summary::after { content: ""; flex: none; width: 9px; height: 9px; margin-right: 4px; border-right: 2px solid currentColor; border-bottom: 2px solid currentColor; transform: rotate(45deg) translate(-2px, -2px); transition: transform .2s; }
.vh-mer[open] > summary::after, .vh-fall[open] > summary::after { transform: rotate(-135deg) translate(-2px, -2px); }
.vh-mer > summary .k-dolj, .vh-fall > summary .k-dolj { display: none; }
.vh-mer[open] > summary .k-visa, .vh-fall[open] > summary .k-visa { display: none; }
.vh-mer[open] > summary .k-dolj, .vh-fall[open] > summary .k-dolj { display: inline; }
.vh-mer > summary:hover, .vh-fall > summary:hover { color: #3E0A52; }
.vh-mer .vh-lista { margin-top: 4px; }
.vh-sok__traff a, .vh-sok__traff button { color: var(--sx-acc2); font: inherit; font-weight: 700; background: none; border: 0; padding: 0; cursor: pointer; text-decoration: underline; text-underline-offset: 4px; }

/* behöver ni folk – mitt i registret */
.vh-folk { display: grid; grid-template-columns: minmax(0, 1.2fr) minmax(320px, 420px); gap: clamp(28px, 5vw, 72px); align-items: center; background: var(--sx-ink); color: #fff; border-radius: 20px; padding: clamp(32px, 4.5vw, 64px); position: relative; overflow: hidden; }
.vh-folk::before { content: ""; position: absolute; top: 0; left: 0; right: 0; height: 6px; background: var(--sx-acc); }
.vh-folk .sx-ogon { color: var(--sx-acc2); }
.vh-folk .sx-h2 { color: #fff; }
.vh-folk > div:first-child p { color: rgba(255,255,255,.85); max-width: 46ch; }
.vh-folk__ring { margin: 20px 0 0; font-size: 15px; }
.vh-folk__ring a { color: var(--sx-acc2); font-weight: 700; font-size: 22px; text-decoration: none; }
.vh-folk__ring a:hover { text-decoration: underline; text-underline-offset: 5px; text-decoration-color: var(--sx-acc); }

/* om verktygen + faq */
.vh-om { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: clamp(32px, 6vw, 80px); align-items: start; }
.vh-om .sx-lead { margin-bottom: 0; }
.vh-om .sx-faq { max-width: none; }
.vh-om .sx-faq__post:first-child { padding-top: 0; }

@media (prefers-reduced-motion: reduce) { .vh-nav a, .vh-lista a::after, .vh-topp a { transition: none; } }
@media (max-width: 1100px) { .vh-topp { grid-template-columns: repeat(2, minmax(0, 1fr)); } .vh-topp strong { font-size: 18px; } }
@media (max-width: 900px) {
  .vh-hero::before { background: linear-gradient(0deg, rgba(20,12,24,.96) 0%, rgba(20,12,24,.82) 55%, rgba(20,12,24,.45) 100%); }
  .vh-huvud, .vh-kat, .vh-folk, .vh-om { grid-template-columns: 1fr; }
  .vh-huvud { align-items: start; }
  .vh-antal { margin: 0; }
  .vh-foto { position: static; aspect-ratio: 16/10; }
  .vh-lista a { padding: 10px 0; }
  .vh-fall > summary { display: flex; border-top: 1px solid var(--sx-line); }
  .vh-fall .vh-lista { border-top: 0; }
  .vh-byline { align-items: flex-start; }
}
@media (max-width: 600px) {
  .vh-topp { grid-template-columns: 1fr; }
  .vh-lista--2 { columns: 1; }
  .vh-sok input { font-size: 16px; }
  .vh-nav ul { mask-image: linear-gradient(90deg, #000 calc(100% - 40px), transparent); -webkit-mask-image: linear-gradient(90deg, #000 calc(100% - 40px), transparent); padding-right: 40px; }
  .vh-folk { padding: 26px 20px; }
}

@media (min-width: 901px) { .vh-fall > summary { display: none; } }
