/* Homepage Academy 1.2.0. Only the static homepage, and only marked native course queries. */
body.smffd-academy-home{--smffd-home-width:1240px;--smffd-home-cols:var(--smffd-cols-desktop,2)}
@media(max-width:1024px){body.smffd-academy-home{--smffd-home-cols:var(--smffd-cols-tablet,2)}}
@media(max-width:680px){body.smffd-academy-home{--smffd-home-cols:var(--smffd-cols-mobile,1)}}
/* Exact decorative files identified on this installation; fallback for custom HTML images.
   Never hide a linked, captioned or meaningful image, or any other asset. */
body.smffd-hide-legacy-banners figure:has(> img[alt=""]:is([src$="/header.webp"],[src$="/corsoattestato.webp"],[src*="/header.webp?"],[src*="/corsoattestato.webp?"])):not(:has(a,button,figcaption,form)){display:none!important}
body.smffd-academy-home.smffd-header .wp-site-blocks>header.wp-block-template-part{position:static!important;top:auto!important;z-index:auto!important;background:var(--smffd-header-bg);padding-block:clamp(8px,1vw,var(--smffd-header-padding));border-bottom:1px solid var(--smffd-line)}
body.smffd-academy-home.smffd-header .wp-site-blocks>header .wp-block-navigation a{font-family:var(--smffd-font)!important;font-size:clamp(.83rem,1.3vw,.98rem);font-style:normal;font-weight:650;letter-spacing:0;text-transform:none}
body.smffd-academy-home.smffd-header .wp-site-blocks>header .wp-block-site-logo img{max-height:var(--smffd-logo-height);width:auto;object-fit:contain}
/* Correct only the ancestors of the identified homepage content. No global WordPress grid reset. */
body.smffd-academy-home main:has(.smffd-home-content),body.smffd-academy-home main .wp-block-group:has(.smffd-home-content){box-sizing:border-box;min-width:0;width:100%;max-width:100%!important}
body.smffd-academy-home .smffd-home-content{box-sizing:border-box;width:min(100%,var(--smffd-home-width));max-width:min(100%,var(--smffd-home-width))!important;min-width:0;margin-inline:auto!important;padding-inline:clamp(12px,2.4vw,30px);display:block}
body.smffd-academy-home .smffd-home-content .smffd-hero{margin:clamp(12px,2vw,24px) auto 28px!important;max-width:min(100%,var(--smffd-hero-width))!important;padding:clamp(22px,4vw,48px);font-family:var(--smffd-font);border-radius:calc(var(--smffd-radius) + 10px);box-shadow:0 12px 30px #142e541c}
body.smffd-academy-home .smffd-hero .smffd-hero-title{font-family:var(--smffd-font)!important;font-weight:770;font-style:normal;text-transform:none;letter-spacing:-.04em}
body.smffd-academy-home .smffd-hero .smffd-hero-intro,body.smffd-academy-home .smffd-hero .smffd-hero-cta{font-family:var(--smffd-font)!important;font-style:normal}
body.smffd-academy-home .smffd-home-course-anchor{height:0!important;margin:0!important;scroll-margin-top:28px}
/* Native Query Loop: keep original nodes and forms. Adapt only direct card geometry. */
body.smffd-academy-home.smffd-cards .smffd-home-query{width:100%;max-width:100%!important;min-width:0;box-sizing:border-box;margin:clamp(18px,3vw,34px) auto!important;display:block}
body.smffd-academy-home.smffd-cards.smffd-home-adaptive .smffd-home-query .wp-block-post-template{display:grid!important;grid-template-columns:repeat(auto-fit,minmax(min(100%,max(300px,calc((100% - (var(--smffd-home-cols) - 1)*var(--smffd-card-gap))/var(--smffd-home-cols)))),1fr))!important;gap:var(--smffd-card-gap)!important;width:100%!important;max-width:100%!important;min-width:0!important;padding:0!important;margin:0!important;list-style:none;align-items:stretch;box-sizing:border-box}
body.smffd-academy-home.smffd-cards .smffd-home-query .wp-block-post-template>li.wp-block-post{box-sizing:border-box;min-width:0;min-height:0;height:auto!important;max-height:none!important;background:var(--smffd-card-bg);border:1px solid var(--smffd-line);border-top:4px solid var(--smffd-accent);border-radius:calc(var(--smffd-radius) + 5px);padding:clamp(12px,2vw,var(--smffd-card-padding));color:var(--smffd-card-ink);font-family:var(--smffd-font)!important;line-height:1.55;overflow-wrap:break-word;box-shadow:none}
body.smffd-academy-home.smffd-cards.smffd-shadow .smffd-home-query .wp-block-post-template>li.wp-block-post{box-shadow:var(--smffd-shadow)}
body.smffd-academy-home.smffd-cards.smffd-home-adaptive .smffd-home-query .wp-block-post-template>li.wp-block-post{width:100%!important;max-width:100%!important;margin:0!important;float:none;align-self:stretch}
body.smffd-academy-home.smffd-cards.smffd-home-adaptive .smffd-home-query .wp-block-post-template>li.wp-block-post>.wp-block-group{width:100%;max-width:100%!important;min-width:0;padding:0!important;margin:0!important;box-sizing:border-box}
/* The native list pattern may contain horizontal columns. Stack those inside cards, not the page. */
body.smffd-academy-home.smffd-cards.smffd-home-adaptive .smffd-home-query .wp-block-post-template>li.wp-block-post .wp-block-columns{display:flex;flex-direction:column;flex-wrap:wrap!important;gap:12px!important;align-items:stretch!important;min-width:0;width:100%;max-width:100%}
body.smffd-academy-home.smffd-cards.smffd-home-adaptive .smffd-home-query .wp-block-post-template>li.wp-block-post .wp-block-columns>.wp-block-column{flex:0 0 auto!important;flex-basis:auto!important;width:100%!important;max-width:100%!important;min-width:0!important;margin-inline:0!important}
body.smffd-academy-home.smffd-cards .smffd-home-query .wp-block-post-template>li.wp-block-post :where(.wp-block-group,.wp-block-column,.wp-block-post-excerpt,.wp-block-post-excerpt__excerpt,.wp-block-sensei-lms-course-actions,.wp-block-buttons,.wp-block-button,form){min-width:0;max-width:100%;box-sizing:border-box}
body.smffd-academy-home.smffd-cards .smffd-home-query .wp-block-post-template>li.wp-block-post :where(.wp-block-post-title,.course-title){font:750 clamp(1.05rem,1.5vw,1.35rem)/1.32 var(--smffd-font)!important;color:var(--smffd-card-heading)!important;text-transform:none;letter-spacing:-.015em;margin-block:12px 8px!important;overflow-wrap:break-word;word-break:normal;text-align:start}
body.smffd-academy-home.smffd-cards .smffd-home-query .wp-block-post-template>li.wp-block-post :where(.wp-block-post-title,.course-title) a{font:inherit!important;color:inherit!important;text-decoration:none}
body.smffd-academy-home.smffd-cards .smffd-home-query .wp-block-post-template>li.wp-block-post :where(.wp-block-post-title,.course-title) a:hover{text-decoration:underline}
body.smffd-academy-home.smffd-cards .smffd-home-query .wp-block-post-template>li.wp-block-post :where(.wp-block-post-excerpt,.wp-block-post-excerpt__excerpt){font:400 .95rem/1.65 var(--smffd-font)!important;color:var(--smffd-card-ink);text-align:start;margin-block:6px 12px;overflow-wrap:break-word;word-break:normal}
body.smffd-academy-home.smffd-cards .smffd-home-query .wp-block-post-template>li.wp-block-post .wp-block-post-terms a{display:inline-block;border-radius:20px;padding:4px 11px;background:var(--smffd-soft);color:#142e54!important;font:650 .76rem/1.4 var(--smffd-font);text-decoration:none}
body.smffd-academy-home.smffd-cards .smffd-home-query .wp-block-post-template>li.wp-block-post :where(.wp-block-post-featured-image,.course-image){width:100%;max-width:100%!important;margin:0 0 12px!important;min-width:0;border-radius:var(--smffd-radius);overflow:hidden}
body.smffd-academy-home.smffd-cards .smffd-home-query .wp-block-post-template>li.wp-block-post :where(.wp-block-post-featured-image,.course-image) img{display:block;width:100%!important;max-width:100%!important;height:auto!important;aspect-ratio:var(--smffd-image-ratio);object-fit:var(--smffd-image-fit);border-radius:var(--smffd-radius)}
body.smffd-academy-home.smffd-cards.smffd-fixed-image-height .smffd-home-query .wp-block-post-template>li.wp-block-post :where(.wp-block-post-featured-image,.course-image) img{height:var(--smffd-image-height)!important;aspect-ratio:auto}
body.smffd-academy-home.smffd-cards.smffd-forms .smffd-home-query .wp-block-post-template>li.wp-block-post :where(button[type=submit],.button,.wp-block-button__link,input[type=submit]):not(:disabled):not([aria-disabled=true]):not(.disabled):not(.has-background){box-sizing:border-box;max-width:100%;white-space:normal;overflow-wrap:break-word;font-family:var(--smffd-font)!important;font-style:normal;font-weight:650;font-size:.95rem;line-height:1.4;min-height:44px;padding:10px 16px;border-radius:var(--smffd-radius);text-transform:none}
@media(prefers-reduced-motion:no-preference){body.smffd-academy-home.smffd-cards.smffd-motion .smffd-home-query .wp-block-post-template>li.wp-block-post{transition:border-color .18s ease,box-shadow .18s ease}body.smffd-academy-home.smffd-cards.smffd-motion .smffd-home-query .wp-block-post-template>li.wp-block-post:hover{border-color:var(--smffd-accent)}body.smffd-academy-home.smffd-cards.smffd-motion.smffd-image_zoom .smffd-home-query .wp-block-post-featured-image img{transition:transform .2s ease}body.smffd-academy-home.smffd-cards.smffd-motion.smffd-image_zoom .smffd-home-query .wp-block-post-featured-image:hover img{transform:scale(1.025)}}
@media(max-width:680px){body.smffd-academy-home .smffd-home-content{padding-inline:12px}body.smffd-academy-home .smffd-home-content .smffd-hero{padding:22px;margin-top:12px!important}body.smffd-academy-home .smffd-hero .smffd-hero-title{font-size:clamp(1.55rem,7vw,var(--smffd-hero-title-size))}body.smffd-academy-home.smffd-cards .smffd-home-query .wp-block-post-template>li.wp-block-post{padding:14px}}

/* 1.2.2: compact course cards. Scope to real course posts or marked native lists.
   Do not alter the grid, enrolment forms, progress markup or course records. */
body.smffd-academy-home .smffd-home-title-hidden{
 position:absolute!important;width:1px!important;height:1px!important;padding:0!important;margin:-1px!important;
 overflow:hidden!important;clip:rect(0,0,0,0)!important;clip-path:inset(50%)!important;white-space:nowrap!important;border:0!important;
}
body.smffd-academy-home.smffd-cards :is(.smffd-home-query,.wp-block-sensei-lms-course-list) .wp-block-post-template>li.wp-block-post,
body.smffd-academy-home.smffd-cards .wp-block-post-template>li.type-course{
 --smffd-card-inset:clamp(16px,var(--smffd-card-padding),40px);
 --wp--style--block-gap:12px;
 box-sizing:border-box!important;padding:var(--smffd-card-inset)!important;
 background:var(--smffd-card-bg)!important;border:1px solid var(--smffd-line)!important;
 border-top:3px solid var(--smffd-accent)!important;border-radius:calc(var(--smffd-radius) + 5px)!important;
 min-width:0;overflow-wrap:break-word;
}
/* The Course pattern can put its own border on a nested group. Use one outer frame. */
body.smffd-academy-home.smffd-cards :is(.smffd-home-query,.wp-block-sensei-lms-course-list) .wp-block-post-template>li.wp-block-post>.wp-block-group,
body.smffd-academy-home.smffd-cards .wp-block-post-template>li.type-course>.wp-block-group{
 box-sizing:border-box!important;width:100%;max-width:100%!important;padding:0!important;margin:0!important;
 border:0!important;box-shadow:none!important;min-width:0;
}
/* Gutenberg flow layout may generate high-specificity blockGap rules. Override only within course cards. */
body.smffd-academy-home.smffd-cards :is(.smffd-home-query .wp-block-post-template>li.wp-block-post,.wp-block-sensei-lms-course-list .wp-block-post-template>li.wp-block-post,.wp-block-post-template>li.type-course) :is(.wp-block-group,.wp-block-columns,.wp-block-column){--wp--style--block-gap:12px;row-gap:12px!important;min-width:0;}
body.smffd-academy-home.smffd-cards :is(.smffd-home-query .wp-block-post-template>li.wp-block-post,.wp-block-sensei-lms-course-list .wp-block-post-template>li.wp-block-post,.wp-block-post-template>li.type-course) :is(.wp-block-group,.wp-block-column)>:is(.wp-block-post-title,.course-title,.wp-block-post-terms,.wp-block-post-excerpt,.wp-block-post-excerpt__excerpt,.wp-block-sensei-lms-course-actions,.wp-block-buttons,.wp-block-button,.wp-block-sensei-lms-course-progress,form,p):not(:first-child){margin-block-start:12px!important;margin-block-end:0!important;}
body.smffd-academy-home.smffd-cards :is(.smffd-home-query .wp-block-post-template>li.wp-block-post,.wp-block-sensei-lms-course-list .wp-block-post-template>li.wp-block-post,.wp-block-post-template>li.type-course) :is(.wp-block-post-title,.course-title){margin-block:12px 0!important;font:750 clamp(1.05rem,1.5vw,1.35rem)/1.32 var(--smffd-font)!important;color:var(--smffd-card-heading)!important;}
body.smffd-academy-home.smffd-cards :is(.smffd-home-query .wp-block-post-template>li.wp-block-post,.wp-block-sensei-lms-course-list .wp-block-post-template>li.wp-block-post,.wp-block-post-template>li.type-course) :is(.wp-block-post-excerpt,.wp-block-post-excerpt__excerpt){margin-block:12px 0!important;font:400 .95rem/1.6 var(--smffd-font)!important;}
body.smffd-academy-home.smffd-cards :is(.smffd-home-query .wp-block-post-template>li.wp-block-post,.wp-block-sensei-lms-course-list .wp-block-post-template>li.wp-block-post,.wp-block-post-template>li.type-course) .wp-block-post-excerpt>.wp-block-post-excerpt__excerpt:first-child{margin-block-start:0!important;}
@media(max-width:680px){body.smffd-academy-home.smffd-cards :is(.smffd-home-query,.wp-block-sensei-lms-course-list) .wp-block-post-template>li.wp-block-post,body.smffd-academy-home.smffd-cards .wp-block-post-template>li.type-course{padding:clamp(16px,var(--smffd-card-padding),24px)!important;}}

/* Direct children also occur in alternate native Course query patterns. */
body.smffd-academy-home.smffd-cards :is(.smffd-home-query .wp-block-post-template>li.wp-block-post,.wp-block-sensei-lms-course-list .wp-block-post-template>li.wp-block-post,.wp-block-post-template>li.type-course)>:is(.wp-block-post-title,.course-title,.wp-block-post-terms,.wp-block-post-excerpt,.wp-block-post-excerpt__excerpt,.wp-block-sensei-lms-course-actions,.wp-block-buttons,.wp-block-button,.wp-block-sensei-lms-course-progress,form,p):not(:first-child){margin-block-start:12px!important;margin-block-end:0!important;}
