/* Programa, Calendari i Modalitats: una única vista i una única fitxa editorial */
body:has(.shared-program) #main{max-width:none!important;width:100%!important;margin:0!important;padding:0!important;background:#f6f7f7!important}
body:has(.shared-program) .interior-hero{min-height:315px!important;background-image:linear-gradient(90deg,#102c27dc,#143c3050),url('/home-assets/portada.webp')}

body:has(.shared-program) .interior-hero .page-head{padding-top:46px!important;padding-bottom:77px!important}
body:has(.shared-program) .interior-surface{width:min(1260px,calc(100% - 38px))!important;background:#fff!important;border:1px solid #edf0ee!important;border-radius:23px!important;padding:26px clamp(14px,3vw,38px) 40px!important;box-shadow:0 17px 50px #18281c14!important;margin-top:-41px!important}
.shared-program{max-width:none!important;width:100%!important;margin:0!important;padding:0!important;border:0!important;background:#fff!important}
.shared-program-controls{display:flex;flex-wrap:wrap;align-items:center;justify-content:space-between;gap:13px;padding:0 0 20px;border-bottom:1px solid #e8ebed;margin:0 0 20px}
.shared-program-controls input,.shared-program-controls select{height:43px!important;min-width:125px!important;padding:10px 14px!important;border:1px solid #dde3e4!important;background:#fff!important;border-radius:11px!important;color:#26343a!important;font:inherit!important;box-shadow:none!important}
.shared-program-controls input{flex:1 1 220px!important;max-width:330px!important}
.shared-program-modes{display:inline-flex;align-items:center;gap:3px;background:#f1f3f4;padding:4px;border-radius:12px;flex-shrink:0}
.shared-program-modes button{font:inherit;font-weight:700;font-size:13px;border:0;border-radius:9px;background:transparent;color:#647179;padding:10px 15px;cursor:pointer}
.shared-program-modes button[aria-pressed=true]{background:#fff;color:#243a32;box-shadow:0 1px 5px #172f241c}
.shared-program #result-count{font-size:13px;color:#778188;margin:0 0 17px}
.shared-program-flat,.shared-day-items{display:grid!important;grid-template-columns:repeat(2,minmax(0,1fr))!important;gap:15px!important;align-items:stretch!important}
.shared-program [hidden]{display:none!important}
.shared-day{margin:0 0 27px!important;padding:0!important;border:0!important;background:transparent!important;box-shadow:none!important}
.shared-day>header{display:flex;align-items:center;justify-content:space-between;gap:14px;margin:0 0 15px;padding:0 0 12px;border-bottom:1px solid #e8ecee}
.shared-day>header h2{font-size:clamp(20px,2.1vw,27px)!important;letter-spacing:-.03em!important;font-weight:790!important;color:#253b33!important;text-transform:none!important;margin:0!important}
.shared-day>header span{font-size:12px!important;color:#63726b!important;background:#f1f4f2!important;border-radius:20px!important;padding:7px 10px!important;white-space:nowrap}
.shared-program .shared-program-card{position:relative!important;display:grid!important;grid-template-columns:42% minmax(0,1fr)!important;width:100%!important;min-width:0!important;min-height:210px!important;border:1px solid #e8ebed!important;border-radius:19px!important;background:#fff!important;box-shadow:0 6px 24px #1f343615!important;overflow:hidden!important;transition:box-shadow .16s ease!important}
.shared-program .shared-program-card:hover{box-shadow:0 13px 34px #1f343625!important}
.shared-program .shared-card-photo{position:relative!important;display:block!important;min-height:210px!important;height:100%!important;width:100%!important;overflow:hidden!important;background:#e6e9e9!important}
.shared-program .shared-card-photo img{width:100%!important;height:100%!important;object-fit:cover!important;position:absolute!important;inset:0!important}
.shared-program .shared-card-kind{position:absolute!important;top:13px!important;left:13px!important;display:inline-flex!important;max-width:calc(100% - 24px)!important;padding:8px 13px!important;background:#ffcc7f!important;color:#3d3321!important;font-size:11px!important;font-weight:800!important;border-radius:13px!important;line-height:1.2!important;text-transform:uppercase!important}
.shared-program .shared-card-info{display:flex!important;flex-direction:column!important;align-items:flex-start!important;min-width:0!important;padding:24px 20px 15px!important}
.shared-program .shared-card-info>small{color:#69777e!important;font-size:12px!important;letter-spacing:.03em!important;font-weight:700!important;margin:0 33px 8px 0!important}
.shared-program .shared-card-info h3{color:#14242a!important;line-height:1.18!important;letter-spacing:-.025em!important;font-size:clamp(18px,1.65vw,23px)!important;margin:0 0 8px!important}
.shared-program .shared-card-info h3 a{color:inherit!important;text-decoration:none!important}
.shared-program .shared-card-info>strong{font-size:15px!important;font-weight:550!important;color:#243039!important;margin:0 0 8px!important}
.shared-program .shared-card-info p{font-size:13px!important;line-height:1.45!important;color:#657079!important;margin:0 0 14px!important;display:-webkit-box!important;-webkit-line-clamp:3!important;-webkit-box-orient:vertical!important;overflow:hidden!important}
.shared-program .shared-card-place{display:inline-flex!important;align-items:center!important;gap:7px!important;font-size:12px!important;margin-top:auto!important;background:#eef3f0!important;padding:8px 11px!important;border-radius:9px!important;color:#34483f!important}
.shared-program .shared-card-place svg{width:17px!important;height:17px!important}
.shared-program .shared-card-save{position:absolute!important;top:12px!important;right:12px!important;display:grid!important;place-items:center!important;width:33px!important;height:33px!important;border:0!important;border-radius:10px!important;background:#ffffffd9!important;color:#20312d!important;cursor:pointer}
.shared-program .shared-card-save svg{width:21px!important;height:21px!important}
@media(min-width:1450px){.shared-program-flat,.shared-day-items{grid-template-columns:repeat(2,minmax(0,1fr))!important}}
@media(max-width:960px){.shared-program-flat,.shared-day-items{grid-template-columns:minmax(0,1fr)!important}.shared-program .shared-program-card{min-height:185px!important}.shared-program .shared-card-photo{min-height:185px!important}}
@media(max-width:650px){
 body:has(.shared-program) .interior-hero{min-height:270px!important}
 body:has(.shared-program) .interior-surface{width:calc(100% - 18px)!important;padding:17px 13px 25px!important;margin-top:-27px!important;border-radius:18px!important}
 .shared-program-controls{gap:9px}
 .shared-program-controls input{max-width:none!important;flex:1 1 100%!important}
 .shared-program-controls select{flex:1 1 130px!important}
 .shared-program-modes{width:100%!important;justify-content:stretch!important}
 .shared-program-modes button{flex:1!important}
 .shared-program .shared-program-card{grid-template-columns:41% minmax(0,1fr)!important;min-height:205px!important;border-radius:14px!important}
 .shared-program .shared-card-photo{min-height:205px!important}
 .shared-program .shared-card-kind{top:8px!important;left:7px!important;padding:7px 8px!important;font-size:9px!important}
 .shared-program .shared-card-info{padding:18px 11px 12px!important}
 .shared-program .shared-card-info h3{font-size:17px!important}
 .shared-program .shared-card-info>small{font-size:10px!important}
 .shared-program .shared-card-info>strong{font-size:13px!important}
 .shared-program .shared-card-info p{font-size:12px!important;-webkit-line-clamp:3!important}
 .shared-program .shared-card-place{font-size:11px!important;padding:7px!important}
 .shared-program .shared-card-save{top:6px!important;right:6px!important;width:30px!important;height:30px!important}
}

/* Llistes amples i capçalera editorial clara, sense foto fosca heretada. */
body:has(.shared-program) .interior-hero{
 min-height:210px!important;background:#f2f5f7!important;background-image:none!important;
 align-items:center!important;border-bottom:1px solid #e5eaee!important;
}
body:has(.shared-program) .interior-hero:before{display:none!important}
body:has(.shared-program) .interior-hero .page-head{
 width:calc(100% - clamp(32px,7vw,112px))!important;max-width:none!important;
 padding:32px 0 48px!important;margin-inline:auto!important;color:#182b3d!important;
}
body:has(.shared-program) .interior-hero .page-head h1{
 color:#182b3d!important;font-size:clamp(30px,3.3vw,46px)!important;font-weight:750!important;
 line-height:1.12!important;letter-spacing:-.035em!important;margin:0 0 12px!important;text-shadow:none!important;
}
body:has(.shared-program) .interior-hero .page-head p:not(.eyebrow){
 color:#62717f!important;font-size:clamp(15px,1.2vw,18px)!important;line-height:1.5!important;max-width:70ch!important;
}
body:has(.shared-program) .interior-surface{
 width:calc(100% - clamp(32px,7vw,112px))!important;max-width:none!important;
 margin:-22px auto 0!important;padding:26px clamp(16px,2vw,30px) 40px!important;
 border-radius:18px!important;box-shadow:0 8px 30px #182b3d08!important;
}
@media(max-width:650px){
 body:has(.shared-program) .interior-hero{min-height:175px!important}
 body:has(.shared-program) .interior-hero .page-head{padding:25px 0 40px!important}
 body:has(.shared-program) .interior-surface{padding:18px 12px 28px!important}
}

/* Capçalera fotogràfica: el programa no ha de suprimir la imatge editorial. */
body:has(.shared-program) .interior-hero{min-height:clamp(260px,27vw,390px)!important;align-items:end!important;background:#19382e url('/home-assets/portada-safor-2026.webp') center 42%/cover no-repeat!important}
body:has(.shared-program) .interior-hero:before{display:block!important;background:linear-gradient(90deg,rgba(8,24,23,.86),rgba(8,24,23,.45) 67%,rgba(8,24,23,.12))!important}
body:has(.shared-program) .interior-hero .page-head{position:relative!important;z-index:1!important;color:#fff!important;padding:38px 0 72px!important}
body:has(.shared-program) .interior-hero .page-head h1{color:#fff!important;text-shadow:0 1px 10px #0003!important}
body:has(.shared-program) .interior-hero .page-head p:not(.eyebrow){color:#f0f5f4!important}
body:has(.shared-program) .interior-hero .page-head .eyebrow{color:#f7dfb9!important}
@media(max-width:650px){body:has(.shared-program) .interior-hero{min-height:230px!important;background-position:center 38%!important}body:has(.shared-program) .interior-hero .page-head{padding:30px 0 52px!important}}


/* Mòbil: llistes editorials compactes. Mantindre la imatge, prioritzar les activitats. */
@media(max-width:650px){
 body:has(.shared-program) .interior-hero{
  height:148px!important;min-height:148px!important;max-height:148px!important;
 }
 body:has(.shared-program) .interior-hero .page-head{
  padding:18px 0 34px!important;
 }
 body:has(.shared-program) .interior-hero .page-head h1{font-size:27px!important;margin-bottom:4px!important}
 body:has(.shared-program) .interior-hero .page-head p:not(.eyebrow){font-size:12px!important;line-height:1.3!important}
 body:has(.shared-program) .interior-surface{margin-top:-17px!important;padding:13px 11px 25px!important}
 body:has(.shared-program) .category-banner,
 body:has(.shared-program) .category-banner.cat-sport{
  box-sizing:border-box!important;height:155px!important;min-height:155px!important;max-height:155px!important;
  aspect-ratio:auto!important;border-radius:12px!important;margin:0 0 11px!important;overflow:hidden!important;
 }
 body:has(.shared-program) .category-banner .category-banner-text,
 body:has(.shared-program) .category-banner.cat-sport .category-banner-text{
  padding:13px 15px!important;max-width:100%!important;
 }
 body:has(.shared-program) .category-banner .category-banner-text h1,
 body:has(.shared-program) .category-banner.cat-sport .category-banner-text h1{
  font-size:27px!important;line-height:1.08!important;margin:0 0 4px!important;
 }
 body:has(.shared-program) .category-banner .category-banner-text>strong{font-size:12px!important;line-height:1.3!important}
 .shared-program-controls{
  display:grid!important;grid-template-columns:minmax(0,1fr) minmax(0,1fr)!important;
  align-items:center!important;gap:7px!important;padding:0 0 10px!important;margin:0 0 10px!important;
 }
 .shared-program-controls input#filter-text{
  grid-column:1 / -1!important;box-sizing:border-box!important;width:100%!important;max-width:none!important;
  height:36px!important;min-height:36px!important;padding:6px 11px!important;border-radius:9px!important;
  font-size:14px!important;flex:none!important;
 }
 .shared-program-controls select{
  box-sizing:border-box!important;min-width:0!important;width:100%!important;height:35px!important;
  min-height:35px!important;padding:5px 26px 5px 9px!important;border-radius:9px!important;font-size:12px!important;
 }
 .shared-program-controls select[hidden]{display:none!important}
 .shared-program-controls .shared-program-modes{
  grid-column:1 / -1!important;display:flex!important;gap:2px!important;width:100%!important;padding:2px!important;border-radius:9px!important;
 }
 .shared-program-controls .shared-program-modes button{min-height:30px!important;padding:6px 9px!important;font-size:12px!important}
 .shared-program-controls .fira-clear-filters{grid-column:1/-1!important;font-size:12px!important;padding:6px!important}
 .shared-program #result-count{font-size:12px!important;margin:5px 0 9px!important}
 .shared-program-flat,.shared-day-items{gap:9px!important}
 .shared-program .shared-program-card{
  grid-template-columns:35% minmax(0,1fr)!important;min-height:128px!important;border-radius:11px!important;
  box-shadow:none!important;
 }
 .shared-program .shared-card-photo{min-height:128px!important}
 .shared-program .shared-card-kind{font-size:9px!important;padding:4px 6px!important;top:6px!important;left:5px!important;border-radius:7px!important}
 .shared-program .shared-card-info{padding:10px 10px 9px!important}
 .shared-program .shared-card-info>small{font-size:10px!important;margin:0 24px 4px 0!important;letter-spacing:0!important}
 .shared-program .shared-card-info h3{font-size:15px!important;line-height:1.18!important;margin:0 0 5px!important}
 .shared-program .shared-card-info>strong{font-size:11px!important;line-height:1.3!important;margin:0 0 4px!important}
 .shared-program .shared-card-info p{font-size:11px!important;line-height:1.3!important;-webkit-line-clamp:2!important;margin:0 0 5px!important}
 .shared-program .shared-card-place{font-size:10px!important;padding:4px 6px!important;border-radius:7px!important}
 .shared-program .shared-card-place svg{width:12px!important;height:12px!important}
 .shared-program .shared-card-save{width:27px!important;height:27px!important;top:5px!important;right:5px!important;border-radius:8px!important}
 .shared-program .shared-card-save svg{width:17px!important;height:17px!important}
}

/* Respecta l'atribut hidden: les regles display:grid!important no poden revelar les dues vistes ni fitxes filtrades. */
.shared-program [hidden],.shared-program-flat[hidden],.shared-program-days[hidden],.shared-day[hidden],.shared-program-card[hidden]{display:none!important}

/* El cor ha de reflectir el mateix favorit persistent en totes les llistes. */
.shared-program .shared-card-save[aria-pressed="true"]{color:#b5254a!important;background:#fff0f4!important}
.shared-program .shared-card-save[aria-pressed="true"] svg{fill:currentColor!important;stroke:currentColor!important}
.shared-program .shared-card-save[aria-pressed="false"] svg{fill:none!important}

/* Una mateixa paleta en Agenda i Programa (incloent Guardats i Reserves). */
.shared-program .shared-card-kind{
 background:color-mix(in srgb,var(--agenda-color) 13%,white)!important;
 color:color-mix(in srgb,var(--agenda-color) 82%,black)!important;
 border:1px solid color-mix(in srgb,var(--agenda-color) 17%,white)!important;
 border-radius:999px!important;
}
.shared-program .shared-card-place{
 background:color-mix(in srgb,var(--venue-accent,#52628b) 11%,white)!important;
 color:color-mix(in srgb,var(--venue-accent,#52628b) 86%,black)!important;
 border:1px solid color-mix(in srgb,var(--venue-accent,#52628b) 19%,white)!important;
 border-radius:999px!important;
}
