/* Case studies: restore the actual page identities and keep their shared UI quiet. */
body.sober-case.at97-detail{
  --header-tint:rgba(237,244,251,.78);
  --glass-border:rgba(164,188,214,.58);
  --glass-ink:#18304d;
  --case-accent:#003781;
  --case-accent-soft:#dfeaf7;
}
body.sober-case.case-apphalt{
  --header-tint:rgba(238,245,253,.78);
  --glass-border:rgba(163,190,222,.58);
  --glass-ink:#182b45;
  --case-accent:#1764c8;
  --case-accent-soft:#e7f1fc;
}

/* In-page links focus headings for reading; only controls need a focus ring. */
body.sober-case :is(main,section,h1,h2,h3)[tabindex="-1"]:focus-visible{
  outline:none;
  box-shadow:none;
}

/* AppHalt's three facts are a complete band, not isolated cards with empty badges. */
body.sober-case.case-apphalt .case-facts{
  display:grid;
  grid-template-columns:repeat(3,minmax(0,1fr));
  gap:0;
  width:100%;
  padding:0;
  margin-top:30px;
  overflow:hidden;
  border:1px solid #c9d9e9;
  border-radius:20px;
  background:#f3f8fd;
}
body.sober-case.case-apphalt .case-facts>div{
  min-width:0;
  min-height:104px;
  padding:22px 26px;
  gap:8px;
  background:transparent;
}
body.sober-case.case-apphalt .case-facts>div+div{border-left:1px solid #c9d9e9}
body.sober-case.case-apphalt .case-facts>div::before{display:none}
body.sober-case.case-apphalt .case-facts dt{
  margin:0;
  color:#426181;
  font-size:11px;
  letter-spacing:.09em;
}
body.sober-case.case-apphalt .case-facts dd{
  margin:0;
  color:#173658;
  font-size:16px;
  font-weight:600;
  line-height:1.35;
}

/* The research and product context share the same outside edge. */
body.sober-case.at97-detail .at124-research{
  width:100%;
  max-width:none;
}

/* The delivered result uses a dark panel, so its heading must remain light. */
body.sober-case.at97-detail .at2-result h2#at122-result-title{color:#f7fbff}

/* Source boards should be readable as previews and available at full size. */
body.sober-case.v105-cetelem .c115-source-card a{
  display:block;
  position:relative;
  overflow:hidden;
  border:1px solid rgba(60,96,68,.15);
  border-radius:16px;
  background:#eef4ee;
}
body.sober-case.v105-cetelem .c115-gallery-head h2[id]{scroll-margin-top:150px}
body.sober-case.v105-cetelem .c115-source-card a img{
  width:100%;
  height:clamp(250px,31vw,380px);
  object-fit:cover;
  object-position:center top;
  border:0;
  border-radius:0;
  transition:transform .3s ease;
}
body.sober-case.v105-cetelem .c115-source-card a:hover img{transform:scale(1.025)}
body.sober-case.v105-cetelem .c115-source-card a span{
  position:absolute;
  right:12px;
  bottom:12px;
  padding:8px 11px;
  border:1px solid #c7dac9;
  border-radius:999px;
  background:rgba(255,255,255,.94);
  color:#20572b;
  font:700 12px/1.2 var(--sans);
  box-shadow:0 3px 12px rgba(15,51,23,.1);
}
@media(prefers-reduced-motion:reduce){
  body.sober-case.v105-cetelem .c115-source-card a img{transition:none}
  body.sober-case.v105-cetelem .c115-source-card a:hover img{transform:none}
}

/* A compact, project-colored end point instead of a generic blue floating box. */
body.sober-case .v105-case-exits{
  display:grid;
  grid-template-columns:auto minmax(0,1fr) auto;
  align-items:center;
  gap:16px 24px;
  padding:16px 22px;
  border:1px solid color-mix(in srgb,var(--case-accent,#3154ef) 22%,white);
  border-radius:18px;
  background:color-mix(in srgb,var(--case-accent,#3154ef) 4%,white);
  box-shadow:none;
  color:var(--case-accent,#3154ef);
}
body.sober-case .v105-case-exits>div{
  display:flex;
  flex-wrap:wrap;
  justify-content:center;
  align-items:center;
  gap:4px 18px;
}
body.sober-case .v105-case-exits a{
  display:inline-flex;
  align-items:center;
  min-height:44px;
  color:inherit;
  text-underline-offset:4px;
}
body.sober-case .v105-case-exits>a:last-child{justify-self:end}

@media(max-width:850px){
  body.sober-case .v105-case-exits{grid-template-columns:1fr;gap:2px;padding:15px 20px}
  body.sober-case .v105-case-exits>div{justify-content:flex-start}
  body.sober-case .v105-case-exits>a:last-child{justify-self:start}
}

@media(max-width:600px){
  body.sober-case.case-apphalt .case-facts{grid-template-columns:1fr;margin-top:25px}
  body.sober-case.case-apphalt .case-facts>div{min-height:0;padding:15px 18px;gap:4px}
  body.sober-case.case-apphalt .case-facts>div+div{border-left:0;border-top:1px solid #c9d9e9}
  body.sober-case.case-apphalt .case-facts dd{font-size:15px}
  body.sober-case.v105-cetelem .c115-source-card a img{height:260px}
}
