/* Round 4, area pages: breadcrumb, person pictures in the k10 cards, and the Råd/Kunskapscenter row.
   Own classes p3-in-r4*, p3-crumbs (same look as the template pages). Only transform and opacity animate. */
.p3-crumbs{padding:16px 32px;font-size:13px;color:#514d47;position:relative;z-index:2}
.p3-crumbs a{color:inherit;text-decoration:none;border-radius:4px}
.p3-crumbs a:hover{text-decoration:underline;text-underline-offset:4px}
.p3-crumbs a:focus-visible{outline:2px solid currentColor;outline-offset:2px}
.p3-crumbs a:active{opacity:.7}
.p3-crumbs__sep{margin:0 8px}
@media (max-width:650px){.p3-crumbs{padding:14px 24px;font-size:12px}}

/* k10 card picture for a person cut-out: the area's own scene tint behind, head kept in view */
.p3-in-k10__pic--person{background:var(--surface-assessment,#efe9df)}
.p3-in-k10__pic--person img{object-fit:contain;object-position:50% 100%;padding-top:6px;box-sizing:border-box}
/* five cards: three over two, the two wider, so no row ends with a gap */
@media (min-width:1001px){
  .p3-in-k10__row:has(> li:nth-child(5):last-child){grid-template-columns:repeat(6,minmax(0,1fr))}
  .p3-in-k10__row:has(> li:nth-child(5):last-child) > li{grid-column:span 2}
  .p3-in-k10__row:has(> li:nth-child(5):last-child) > li:nth-child(n+4){grid-column:span 3}
  .p3-in-k10__row:has(> li:nth-child(5):last-child) > li:nth-child(n+4) .p3-in-k10__pic{aspect-ratio:21/10}
}

/* one row to Råd and Kunskapscenter */
.p3-in-r4more{--sp:cubic-bezier(.34,1.56,.64,1);display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:12px;margin:0;padding:0 32px 64px}
.p3-in-r4more__card{position:relative;display:flex;flex-direction:column;gap:6px;box-sizing:border-box;padding:24px 76px 24px 24px;border-radius:24px;
  background:var(--surface-assessment,#f1ede5);box-shadow:0 18px 28px -22px rgba(48,48,46,.5),inset 0 0 0 1px rgba(48,48,46,.07);
  color:#30302e;text-decoration:none;transition:transform .3s var(--sp)}
.p3-in-r4more__t{font-size:22px;line-height:1.15;letter-spacing:-.03em;font-weight:500}
.p3-in-r4more__s{font-size:15px;line-height:1.6;color:#514d47}
.p3-in-r4more__go{position:absolute;right:20px;top:50%;margin-top:-18px;display:grid;place-items:center;width:36px;height:36px;border-radius:50%;background:#30302e;color:#fff;transition:transform .3s var(--sp)}
.p3-in-r4more__go svg{width:14px;height:14px}
.p3-in-r4more__card:hover{transform:translateY(-2px)}
.p3-in-r4more__card:hover .p3-in-r4more__go{transform:translateX(2px)}
.p3-in-r4more__card:active{transform:scale(.985)}
.p3-in-r4more__card:focus-visible{outline:3px solid #30302e;outline-offset:3px}
@media (max-width:640px){
  .p3-in-r4more{grid-template-columns:1fr;padding:0 24px 40px}
  .p3-in-r4more__card{padding:20px 72px 20px 20px;border-radius:20px}
}

@media (prefers-reduced-motion:reduce){
  .p3-in-r4more__card,.p3-in-r4more__go{transition:none}
  .p3-in-r4more__card:hover,.p3-in-r4more__card:hover .p3-in-r4more__go{transform:none}
}

/* Contrast (reviewer round 4, hubs). The hero and closing copy sit on a gradient that gets lighter further down,
   so the lede and the secondary button are full white on a darker glass. The espresso hub (/vikt-och-halsa/) inherits
   cream text colours made for a dark page; its light sections take the dark brown pair the template pages use
   (service.css .p3-service.scene-espresso). Every pair measures >= 4.5:1 with tests/contrast-webkit.mjs. */
.layer--scene .hero .lede{color:#fff}
.layer--scene .hero .button--secondary{color:#fff;background:rgba(20,18,16,.4)}
.layer.closing .closing__copy p{color:#fff}
.scene-espresso .layer.assessment,.scene-espresso .layer.faq{--lede-color:#5a4433;--muted:#665040}
.scene-espresso .layer.assessment .step h3{color:var(--ink)}
.scene-espresso .layer.assessment .button--secondary{color:var(--ink);background:transparent;box-shadow:inset 0 0 0 1px currentColor}
.scene-espresso .layer--scene .p3-in-k10 .section-head h2{color:#fff9f1}
/* With a photo hero the scene layer is the photo's light sky from 901 px (css/in-topp.css): the cream heading takes the photo's
   dark ink there. Phones and tablets keep the espresso layer and the cream (Kajal's photo 2026-11-05; 1.3:1 before). */
@media (min-width:901px){.scene-espresso .layer--scene[data-p3-scene="photo"] .p3-in-k10 .section-head h2{color:var(--p3-photo-ink)}}
/* The espresso family has no closing/footer surfaces in system.css (service.css adds them for the template pages): same four for its hub. */
.scene-espresso{
  --surface-closing:radial-gradient(ellipse at 14% 0%, var(--f-glow) 0, transparent 42%), linear-gradient(176deg, var(--f-deep) 0%, var(--f-mid) 46%, var(--f-end) 100%);
  --surface-materials:radial-gradient(ellipse at 15% 0%, var(--f-glow) 0, transparent 50%), linear-gradient(172deg, var(--f-deep) 0%, var(--f-mid) 48%, var(--f-end) 100%);
  --surface-footer:var(--f-deep);
  --surface-footer-card:rgba(255,255,255,.18);
}
/* The brand pill is peach in the hero and in the closing; its text is dark in both. */
.brand-pill .brand-pill__name{color:#30302e}
.scene-grafit .layer--scene .section-head p{color:#3f3b37}
/* A soft dark shade behind the hero and closing copy, so white text keeps >= 4.5:1 where the scene gradient turns pale (desktop, tall hero). */
.layer--scene .hero__copy{position:relative;isolation:isolate}
.layer--scene .hero__copy::before{content:"";position:absolute;inset:-28px -40px -28px -56px;z-index:-1;pointer-events:none;
  background:radial-gradient(closest-side ellipse at 50% 50%,rgba(20,18,16,.34) 0,rgba(20,18,16,.16) 60%,transparent 100%)}
/* B133: on phones the hub's lede ends over the pale glow of the scene; a stronger shade behind it */
@media (max-width:900px){.pvt-site:not(.p3-sheets) .layer--scene .hero__copy::before{background:radial-gradient(closest-side ellipse at 50% 50%,rgba(20,18,16,.52) 0,rgba(20,18,16,.3) 60%,transparent 100%)}}
/* the closing layer's gradient turns pale towards the picture: a long soft shade from the copy side */
.layer.closing{position:relative;isolation:isolate}
.layer.closing::before{content:"";position:absolute;inset:0;z-index:-1;pointer-events:none;border-radius:inherit;
  background:linear-gradient(90deg,rgba(20,18,16,.5) 0,rgba(20,18,16,.3) 38%,transparent 68%)}
@media (max-width:900px){.layer.closing::before{background:linear-gradient(180deg,rgba(20,18,16,.5) 0,rgba(20,18,16,.3) 45%,transparent 75%)}}
.scene-grafit .layer--scene .section-head p{color:#1f1d1b}
.scene-grafit .area__group{color:#4b4640}

/* Area pages on computers (Kajal 2026-10-26): everything between the hero and the closing sits on the same centred column as the
   treatment pages (1100 px, never closer than 40 px to the screen edge). The backgrounds stay full width; only the side padding of
   the sections grows. --p3-col lives on .p3-sheets only, so 1100px is written out. Phones and tablets up to 900 px are not touched. */
@media (min-width:901px){
  main:has(.p3-in-r4more) :is(.areas, .p3-in-k10, .p3-in-r4more, .layer.assessment, .layer.faq){padding-inline:max(40px, calc((100% - 1100px) / 2))}
}

/* ---------- rows that follow how many treatments are open (Kajal 2026-11-18, launch with eight treatments) ----------
   tools/in_r4_hubbar.py writes the number of open cards on the row (data-p3-count); three or more keep the rows above. */
@media (min-width:641px){
  .p3-in-k10__row[data-p3-count="2"]{grid-template-columns:repeat(2,minmax(0,1fr))}
  .p3-in-k10__row[data-p3-count="2"] .p3-in-k10__pic{aspect-ratio:21/10}
  .p3-in-k10__row[data-p3-count="1"]{grid-template-columns:minmax(0,1fr)}
  .p3-in-k10__row[data-p3-count="1"] .p3-in-k10__pic{aspect-ratio:21/10}
  .p3-in-r4more>a:last-child:nth-child(odd){grid-column:1 / -1}
}
@media (min-width:1001px){ /* one card: text on the left, the photo on the right */
  .p3-in-k10__row[data-p3-count="1"] .p3-in-k10__card{display:grid;grid-template-columns:minmax(0,1fr) minmax(0,1fr);grid-template-rows:auto 1fr;column-gap:24px;row-gap:8px;padding:12px 12px 12px 20px}
  .p3-in-k10__row[data-p3-count="1"] .p3-in-k10__pic{grid-column:2;grid-row:1 / span 2;aspect-ratio:16/10}
  .p3-in-k10__row[data-p3-count="1"] .p3-in-k10__name{grid-column:1;grid-row:1;padding:16px 8px 0;font-size:32px}
  .p3-in-k10__row[data-p3-count="1"] .p3-in-k10__text{grid-column:1;grid-row:2;padding:0 8px 56px;font-size:16px;max-width:420px}
  .p3-in-k10__row[data-p3-count="1"] .p3-in-k10__go{right:auto;left:28px;bottom:12px}
}
@media (max-width:640px){
  .p3-in-k10__row[data-p3-count="1"]>li{flex:0 0 100%}
}
