/* ============================================================
   Jämställd Utveckling Skåne — design system
   Palette: blålila #5933EF on lilac paper, ink indigo, cerise signal
   Type: Bricolage Grotesque (display) / Instrument Sans (body)
   Signature: the equals sign — jämställdhet är ett likhetstecken
   ============================================================ */

:root {
  --brand: #5933ef;
  --brand-deep: #3c1fb8;
  --ink: #191536;
  --ink-soft: #46425f;
  --lila: #c9bdf7;
  --lila-soft: #e6e0fb;
  --paper: #f7f5fe;
  --card: #ffffff;
  --cerise: #e23d7b;
  --line: #d9d2f4;
  --radius: 14px;
  --font-display: "Bricolage Grotesque", "Arial Black", sans-serif;
  --font-body: "Instrument Sans", system-ui, sans-serif;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation: none !important; transition: none !important; }
}

body {
  margin: 0;
  font-family: var(--font-body);
  font-size: 1.05rem;
  line-height: 1.65;
  color: var(--ink);
  background: var(--paper);
  -webkit-font-smoothing: antialiased;
}

img { max-width: 100%; height: auto; display: block; }
a { color: var(--brand-deep); text-decoration-thickness: 1px; text-underline-offset: 2px; }
a:hover { color: var(--brand); }

h1, h2, h3, h4 {
  font-family: var(--font-display);
  line-height: 1.12;
  letter-spacing: -0.015em;
  margin: 0 0 0.5em;
  text-wrap: balance;
}
h1 { font-size: clamp(2.3rem, 5.5vw, 4rem); font-weight: 800; }
h2 { font-size: clamp(1.7rem, 3.4vw, 2.5rem); font-weight: 800; }
h3 { font-size: clamp(1.25rem, 2.2vw, 1.55rem); font-weight: 600; }
h4 { font-size: 1.1rem; font-weight: 600; }

.wrap { max-width: 1160px; margin: 0 auto; padding: 0 clamp(1.1rem, 4vw, 2rem); }
.wrap-narrow { max-width: 820px; }

.skip {
  position: absolute; left: -999px; top: 0; z-index: 200;
  background: var(--ink); color: #fff; padding: .6rem 1rem; border-radius: 0 0 8px 0;
}
.skip:focus { left: 0; }

:focus-visible { outline: 3px solid var(--cerise); outline-offset: 2px; border-radius: 2px; }

/* ---------- eyebrow: the equals mark ---------- */
.eyebrow {
  display: inline-block;
  font-weight: 600;
  font-size: .82rem;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--cerise);
  margin-bottom: .9rem;
}
.eyebrow.light { color: var(--lila); }

/* ---------- header ---------- */
.site-head {
  position: sticky; top: 0; z-index: 100;
  background: color-mix(in srgb, var(--paper) 88%, transparent);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--line);
}
.head-row { display: flex; align-items: center; gap: 1.5rem; min-height: 74px; }
.brand { display: flex; align-items: center; gap: .7rem; text-decoration: none; color: var(--ink); margin-right: auto; }
.brand img { width: 44px; height: 44px; }
.brand-name {
  font-family: var(--font-display); font-weight: 800; font-size: .95rem;
  line-height: 1.1; letter-spacing: 0;
}
.site-nav { display: flex; align-items: center; gap: .35rem; }
.nav-item { position: relative; }
.nav-link {
  font: inherit; font-weight: 500; color: var(--ink);
  background: none; border: 0; cursor: pointer;
  padding: .55rem .8rem; border-radius: 999px; text-decoration: none;
  display: inline-flex; align-items: center; gap: .35rem;
}
.nav-link:hover { background: var(--lila-soft); color: var(--ink); }
.nav-item.is-active > .nav-link, a.nav-link.is-active { box-shadow: inset 0 -3px 0 var(--brand); border-radius: 6px 6px 0 0; }
.sub {
  position: absolute; top: calc(100% + .4rem); left: 0; min-width: 260px;
  background: var(--card); border: 1px solid var(--line); border-radius: var(--radius);
  box-shadow: 0 14px 40px rgba(25, 21, 54, .14);
  padding: .5rem; display: none; flex-direction: column;
}
.sub a { padding: .55rem .8rem; border-radius: 8px; text-decoration: none; color: var(--ink); font-weight: 500; }
.sub a:hover { background: var(--lila-soft); }
.nav-item:hover .sub, .nav-item:focus-within .sub, .nav-item.open .sub { display: flex; }
.nav-cta {
  background: var(--brand); color: #fff; font-weight: 600; text-decoration: none;
  padding: .55rem 1.15rem; border-radius: 999px; margin-left: .4rem;
  transition: background .15s ease;
}
.nav-cta:hover { background: var(--brand-deep); color: #fff; }
.nav-toggle { display: none; }

@media (max-width: 900px) {
  .nav-toggle {
    display: grid; gap: 5px; background: none; border: 0; cursor: pointer; padding: .6rem;
  }
  .nav-toggle span { width: 24px; height: 2.5px; background: var(--ink); border-radius: 2px; transition: transform .2s ease, opacity .2s ease; }
  .nav-toggle[aria-expanded="true"] span:nth-child(1) { transform: translateY(7.5px) rotate(45deg); }
  .nav-toggle[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
  .nav-toggle[aria-expanded="true"] span:nth-child(3) { transform: translateY(-7.5px) rotate(-45deg); }
  .site-nav {
    display: none; position: absolute; top: 100%; left: 0; right: 0;
    background: var(--paper); border-bottom: 1px solid var(--line);
    flex-direction: column; align-items: stretch; padding: .8rem 1.2rem 1.4rem; gap: .15rem;
    max-height: calc(100vh - 74px); overflow: auto;
  }
  .site-nav.open { display: flex; }
  .sub { position: static; display: none; box-shadow: none; border: 0; background: none; padding: 0 0 .4rem .9rem; }
  .nav-item.open .sub { display: flex; }
  .nav-item:hover .sub { display: none; }        /* no hover-open on mobile */
  .nav-item.open:hover .sub { display: flex; }
  .nav-item:focus-within .sub { display: none; }
  .nav-item.open:focus-within .sub { display: flex; }
  .nav-cta { margin: .6rem 0 0; text-align: center; }
}

/* ---------- buttons ---------- */
.btn {
  display: inline-block; font-weight: 600; text-decoration: none;
  padding: .75rem 1.5rem; border-radius: 999px; border: 2px solid transparent;
  transition: transform .12s ease, background .15s ease, color .15s ease;
}
.btn:active { transform: scale(.97); }
.btn-primary { background: var(--brand); color: #fff; }
.btn-primary:hover { background: var(--brand-deep); color: #fff; }
.btn-cerise { background: var(--cerise); color: #fff; }
.btn-cerise:hover { background: #c22a64; color: #fff; }
.btn-ghost { border-color: var(--ink); color: var(--ink); background: transparent; }
.btn-ghost:hover { background: var(--ink); color: #fff; }
.btn-light { background: #fff; color: var(--ink); }
.btn-light:hover { background: var(--lila); color: var(--ink); }
.btn-row { display: flex; flex-wrap: wrap; gap: .8rem; align-items: center; }

/* ---------- hero (home) ---------- */
.hero { position: relative; overflow: hidden; padding: clamp(3rem, 7vw, 5.5rem) 0 clamp(2.5rem, 6vw, 4.5rem); }
.hero-grid { display: grid; grid-template-columns: minmax(0, 1.25fr) minmax(0, .85fr); gap: clamp(2rem, 5vw, 4rem); align-items: center; }
.hero h1 { margin-bottom: .6em; }
.hero h1 .accent { color: var(--brand); }
.hero .lede { font-size: clamp(1.1rem, 1.8vw, 1.25rem); color: var(--ink-soft); max-width: 34em; }
.hero .btn-row { margin-top: 1.8rem; }

/* the equals mark */
.equals-panel { position: relative; display: grid; justify-items: center; gap: 1.4rem; }
.equals {
  display: grid; gap: clamp(1rem, 2.2vw, 1.6rem); width: min(100%, 340px);
}
.equals span {
  height: clamp(2.6rem, 5.5vw, 3.8rem); border-radius: 999px; background: var(--brand);
  transform-origin: left center;
  animation: barIn .7s cubic-bezier(.2, .9, .3, 1.2) both;
}
.equals span:nth-child(2) { animation-delay: .18s; }
@keyframes barIn { from { transform: scaleX(0); } to { transform: scaleX(1); } }
.focus-chips { display: flex; flex-wrap: wrap; gap: .5rem; justify-content: center; }
.chip {
  background: var(--card); border: 1px solid var(--line); color: var(--ink);
  font-weight: 500; font-size: .88rem; padding: .35rem .85rem; border-radius: 999px;
}
@media (max-width: 800px) {
  .hero-grid { grid-template-columns: 1fr; }
  .equals-panel { justify-items: start; }
  .focus-chips { justify-content: flex-start; }
}

/* ---------- sections ---------- */
.section { padding: clamp(2.8rem, 6vw, 4.8rem) 0; }
.section-tint { background: var(--lila-soft); }
.section-ink { background: var(--ink); color: #fff; }
.section-ink h2, .section-ink h3 { color: #fff; }
.section-ink a { color: var(--lila); }
.section-head { max-width: 720px; margin-bottom: 2.2rem; }

/* ---------- aktuellt band ---------- */
.aktuellt { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 420px); gap: clamp(2rem, 4vw, 3.5rem); align-items: center; }
.aktuellt-img { border-radius: var(--radius); overflow: hidden; box-shadow: 0 18px 50px rgba(25, 21, 54, .18); }
.tag {
  display: inline-block; background: var(--cerise); color: #fff; font-weight: 600;
  font-size: .8rem; letter-spacing: .1em; text-transform: uppercase;
  padding: .3rem .8rem; border-radius: 999px; margin-bottom: 1rem;
}
.meta-line { font-weight: 600; color: var(--brand-deep); margin: .2rem 0 1rem; }
@media (max-width: 800px) { .aktuellt { grid-template-columns: 1fr; } }

/* ---------- cards ---------- */
.cards { display: grid; grid-template-columns: repeat(auto-fit, minmax(230px, 1fr)); gap: 1.3rem; }
.card {
  background: var(--card); border: 1px solid var(--line); border-radius: var(--radius);
  overflow: hidden; text-decoration: none; color: var(--ink); display: flex; flex-direction: column;
  transition: transform .18s ease, box-shadow .18s ease;
}
.card:hover { transform: translateY(-4px); box-shadow: 0 16px 40px rgba(89, 51, 239, .16); color: var(--ink); }
.card img { width: 100%; }
.card .card-label {
  padding: 1rem 1.2rem; font-family: var(--font-display); font-weight: 600; font-size: 1.15rem;
  display: flex; justify-content: space-between; align-items: center; gap: .5rem;
}
.card .card-label::after { content: "→"; color: var(--cerise); transition: transform .18s ease; }
.card:hover .card-label::after { transform: translateX(4px); }

/* ---------- quotes ---------- */
.quotes { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 1.5rem; }
.quote {
  background: var(--card); border-radius: var(--radius); padding: 1.8rem 1.8rem 1.5rem;
  border-top: 5px solid var(--brand); font-size: 1.02rem;
  color: var(--ink); margin: 0;
}
.quote p { margin: 0 0 1rem; }
.quote footer { font-weight: 600; color: var(--brand-deep); font-size: .92rem; }

/* ---------- partner logos ---------- */
.logo-grid {
  display: grid; grid-template-columns: repeat(auto-fill, minmax(130px, 1fr)); gap: 1rem;
  align-items: center;
}
.logo-grid figure {
  margin: 0; background: #fff; border: 1px solid var(--line); border-radius: 10px;
  display: grid; place-items: center; aspect-ratio: 3 / 2; padding: 1rem;
}
.logo-grid img {
  max-height: 64px; width: auto; max-width: 100%; object-fit: contain;
  filter: grayscale(1); opacity: .75; transition: filter .2s ease, opacity .2s ease;
}
.logo-grid figure:hover img { filter: none; opacity: 1; }
.logo-grid figure.on-brand { background: var(--brand); }
.logo-grid figure.on-brand img { filter: none; opacity: 1; }

/* ---------- page hero (subpages) ---------- */
.page-hero { padding: clamp(2.6rem, 6vw, 4.2rem) 0 clamp(1.6rem, 3vw, 2.4rem); }
.page-hero .lede { font-size: clamp(1.05rem, 1.7vw, 1.2rem); color: var(--ink-soft); max-width: 42em; }

/* ---------- prose ---------- */
.prose { max-width: 46em; }
.prose ul { padding-left: 1.2em; }
.prose li { margin: .4em 0; }
.prose .src { font-size: .85rem; color: var(--ink-soft); }

/* ---------- split (text+image) ---------- */
.split { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: clamp(1.8rem, 4vw, 3.2rem); align-items: center; }
.split img { border-radius: var(--radius); }
.split .framed { box-shadow: 0 18px 50px rgba(25, 21, 54, .15); }

/* ---------- feature blocks (jus-metoden) ---------- */
.steps { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 1.3rem; counter-reset: step; }
.step {
  background: var(--card); border: 1px solid var(--line); border-radius: var(--radius);
  padding: 1.6rem 1.6rem 1.4rem; position: relative;
}
.step::before {
  counter-increment: step; content: counter(step);
  position: absolute; top: -1rem; left: 1.3rem;
  background: var(--brand); color: #fff; font-family: var(--font-display); font-weight: 800;
  width: 2rem; height: 2rem; border-radius: 50%; display: grid; place-items: center; font-size: 1rem;
}
.step h3, .step h4 { margin-top: .4rem; }
.steps.no-num .step::before { display: none; }
.steps.no-num .step h3 { margin-top: 0; }

/* ---------- person cards ---------- */
.people { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 1.5rem; }
.person { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; }
.person img { aspect-ratio: 1; object-fit: cover; width: 100%; }
.person .p-body { padding: 1.2rem 1.4rem 1.4rem; }
.person h3 { margin-bottom: .1rem; }
.person .role { color: var(--cerise); font-weight: 600; margin: 0 0 .7rem; }
.person p { margin: .15rem 0; font-size: .95rem; }

/* ---------- accordions (projects) ---------- */
.project { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: clamp(1.4rem, 3vw, 2.2rem); margin-bottom: 1.5rem; }
.project-head { display: grid; grid-template-columns: 150px minmax(0, 1fr); gap: 1.5rem; align-items: center; margin-bottom: .6rem; }
.project-head img { border-radius: 10px; background: #fff; }
.project-head .year { color: var(--cerise); font-weight: 600; font-size: .88rem; letter-spacing: .08em; text-transform: uppercase; }
.project-head h2, .project-head h3 { margin: 0; }
@media (max-width: 560px) { .project-head { grid-template-columns: 1fr; } .project-head img { max-width: 180px; } }
details.fold { border-top: 1px solid var(--line); }
details.fold summary {
  cursor: pointer; font-weight: 600; padding: .8rem 0; list-style: none;
  display: flex; justify-content: space-between; align-items: center; gap: 1rem;
}
details.fold summary::-webkit-details-marker { display: none; }
details.fold summary::after { content: "+"; font-family: var(--font-display); font-size: 1.3rem; color: var(--brand); }
details.fold[open] summary::after { content: "–"; }
details.fold .fold-body { padding: 0 0 1.1rem; }
details.fold .fold-body p:first-child { margin-top: 0; }

/* ---------- report cards ---------- */
.reports { display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: 1.5rem; }
.report {
  background: var(--card); border: 1px solid var(--line); border-radius: var(--radius);
  overflow: hidden; display: flex; flex-direction: column;
}
.report .cover { aspect-ratio: 16 / 10; overflow: hidden; background: var(--lila-soft); }
.report .cover img { width: 100%; height: 100%; object-fit: cover; object-position: top; }
.report .r-body { padding: 1.3rem 1.4rem 1.5rem; display: flex; flex-direction: column; gap: .4rem; flex: 1; }
.report h3 { margin: 0; font-size: 1.18rem; }
.report p { margin: .3rem 0; font-size: .95rem; color: var(--ink-soft); }
.report .r-links { margin-top: auto; padding-top: .7rem; display: flex; flex-wrap: wrap; gap: .9rem; }
.report .r-links a { font-weight: 600; }

/* ---------- stat band (varför) ---------- */
.stats { display: grid; grid-template-columns: repeat(auto-fit, minmax(190px, 1fr)); gap: 1.2rem; }
.stat { border-left: 4px solid var(--cerise); padding: .2rem 0 .2rem 1.1rem; }
.stat .n { font-family: var(--font-display); font-weight: 800; font-size: 2.4rem; line-height: 1; color: var(--brand); display: block; }
.stat .t { font-size: .92rem; color: var(--ink-soft); }
.section-ink .stat .n { color: var(--lila); }
.section-ink .stat .t { color: #cfc9ec; }

/* ---------- focus areas grid ---------- */
.focus-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(160px, 1fr)); gap: 1.2rem; }
.focus { text-align: center; }
.focus img { width: 110px; height: 110px; object-fit: contain; margin: 0 auto .6rem; }
.focus h3 { font-size: 1.05rem; }

/* ---------- doc list ---------- */
.doc-list { list-style: none; padding: 0; display: grid; gap: .7rem; max-width: 560px; }
.doc-list a {
  display: flex; align-items: center; gap: .8rem; background: var(--card);
  border: 1px solid var(--line); border-radius: 10px; padding: .85rem 1.1rem;
  text-decoration: none; font-weight: 600; color: var(--ink);
}
.doc-list a:hover { border-color: var(--brand); color: var(--brand-deep); }
.doc-list a::before { content: "⤓"; color: var(--cerise); font-size: 1.15rem; }

/* ---------- contact ---------- */
.contact-cards { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 1.5rem; }
.contact-card { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 1.7rem; }
.contact-card h3 { margin-bottom: .3rem; }
.contact-card a { font-weight: 600; overflow-wrap: anywhere; }

/* ---------- reveal on scroll ---------- */
.reveal { opacity: 0; transform: translateY(18px); transition: opacity .55s ease, transform .55s ease; }
.reveal.in { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) { .reveal { opacity: 1; transform: none; } }

/* ---------- footer ---------- */
.site-foot { background: var(--ink); color: #cfc9ec; margin-top: clamp(3rem, 7vw, 5rem); }
.foot-grid {
  display: grid; grid-template-columns: 1.1fr 1fr 1.2fr; gap: clamp(2rem, 4vw, 3.5rem);
  padding-top: clamp(2.5rem, 5vw, 4rem); padding-bottom: 2.5rem;
}
.site-foot a { color: #fff; }
.site-foot a:hover { color: var(--lila); }
.foot-logo { max-width: 210px; filter: brightness(0) invert(1); opacity: .95; margin-bottom: 1rem; }
.foot-brand p { margin: .4rem 0; font-size: .95rem; }
.socials { display: flex; gap: 1rem; margin-top: 1rem; }
.socials a { color: #fff; }
.foot-links { display: grid; gap: .45rem; align-content: start; font-size: .97rem; }
.foot-links strong { color: var(--lila); font-size: .8rem; letter-spacing: .12em; text-transform: uppercase; }
.foot-links strong.mt { margin-top: 1rem; }
.foot-links a { text-decoration: none; }
.foot-news h3 { color: #fff; margin: .2rem 0 .5rem; }
.foot-news p { font-size: .95rem; }
.foot-news .btn { margin: .5rem 0 1.2rem; }
.site-foot a.btn-light { color: var(--ink); }
.site-foot a.btn-light:hover { color: var(--ink); }
.foot-region { font-weight: 600; color: #fff; }
.foot-gdpr { font-size: .85rem; }
.foot-base {
  display: flex; justify-content: space-between; gap: 1rem; flex-wrap: wrap;
  border-top: 1px solid #322c58; padding-top: 1.2rem; padding-bottom: 1.4rem; font-size: .9rem;
}
.foot-base a { text-decoration: none; }
@media (max-width: 860px) { .foot-grid { grid-template-columns: 1fr; } }
