/*
 * Hercules 101 Layout System
 * Reference families:
 * Header 1-20 classic, 21-40 multi-tier, 41-60 floating/off-canvas,
 * 61-80 niche/industry, 81-101 hybrid/structural.
 * Footer 1-20 corporate, 21-40 minimal, 41-60 conversion,
 * 61-80 content/eCommerce, 81-101 experimental.
 * Page 1-20 landing, 21-40 editorial, 41-60 commerce,
 * 61-80 showcase, 81-101 dashboard/app.
 */

body.h101-system{
    --h101-radius:12px;
    --h101-gap:20px;
    --h101-pad:24px;
    --h101-line:1px;
    --h101-page-radius:14px;
    --h101-content-width:1200px;
}

/* Shared safety */
body.h101-system .h101-layout,
body.h101-system .h101-layout *{box-sizing:border-box}
body.h101-system .h101-layout img{max-width:100%;height:auto}
body.h101-system .h101-layout a:focus-visible{outline:2px solid currentColor;outline-offset:3px}
body.h101-system .h101-layout .sig-menu,
body.h101-system .h101-layout .hercules-layout-menu{gap:clamp(2px,calc(var(--h101-gap) * .22),8px)}
body.h101-system .h101-layout .sig-cta,
body.h101-system .h101-layout .hercules-layout-header__cta{border-radius:var(--h101-radius)}
body.h101-system .h101-layout .sig-mark{border-radius:calc(var(--h101-radius) * .55)}
body.h101-system .h101-layout .hsw{max-width:calc(var(--h101-content-width) + 40px)}

/* HEADER FAMILY 1-20: classic horizontal */
body.h101-header-family-classic .h101-layout:is(header,.hercules-layout-header){
    background:#fff;
    border-bottom:var(--h101-line) solid rgba(15,23,42,.12);
    box-shadow:0 5px 18px rgba(15,23,42,.045);
}
body.h101-header-family-classic .h101-layout .sig-menu>li>a,
body.h101-header-family-classic .h101-layout .hercules-layout-menu>li>a{
    letter-spacing:.015em;
}
body.h101-header-family-classic .h101-layout .sig-brand{min-width:max-content}

/* HEADER FAMILY 21-40: multi-tier utility */
body.h101-header-family-multitier .h101-layout:is(header,.hercules-layout-header){
    border-top:4px solid var(--sig-a,#2563eb);
    border-bottom:1px solid rgba(15,23,42,.12);
    box-shadow:0 8px 28px rgba(15,23,42,.07);
}
body.h101-header-family-multitier .h101-layout:is(header,.hercules-layout-header):before{
    content:"";
    display:block;
    height:5px;
    background:linear-gradient(90deg,var(--sig-a,#2563eb),var(--sig-a2,#f59e0b));
}
body.h101-header-family-multitier .h101-layout .sig-menu>li>a,
body.h101-header-family-multitier .h101-layout .hercules-layout-menu>li>a{
    text-transform:uppercase;
    font-size:12px;
    letter-spacing:.08em;
}

/* HEADER FAMILY 41-60: modern floating/off-canvas */
body.h101-header-family-floating .h101-layout:is(header,.hercules-layout-header){
    width:min(1280px,calc(100% - 28px));
    margin:14px auto 0;
    border:1px solid rgba(15,23,42,.11);
    border-radius:max(14px,var(--h101-radius));
    box-shadow:0 18px 45px rgba(15,23,42,.13);
    overflow:visible;
}
body.h101-header-family-floating.admin-bar .h101-layout:is(header,.hercules-layout-header){margin-top:14px}
body.h101-header-family-floating .h101-layout .sig-cta,
body.h101-header-family-floating .h101-layout .hercules-layout-header__cta{
    border-radius:999px;
}
body.h101-header-family-floating .h101-layout .sig-menu>li>a{
    border-radius:999px;
}

/* HEADER FAMILY 61-80: niche/industry */
body.h101-header-family-niche .h101-layout:is(header,.hercules-layout-header){
    border-left:6px solid var(--sig-a,#2563eb);
    border-bottom:1px solid rgba(15,23,42,.1);
}
body.h101-header-family-niche .h101-layout .sig-brand-text em{
    opacity:1;
    font-weight:800;
}
body.h101-header-family-niche .h101-layout .sig-menu>li>a{
    position:relative;
}
body.h101-header-family-niche .h101-layout .sig-menu>li>a:after{
    content:"";
    position:absolute;
    left:12px;
    right:12px;
    bottom:5px;
    height:2px;
    background:var(--sig-a,#2563eb);
    transform:scaleX(0);
    transition:transform .2s ease;
}
body.h101-header-family-niche .h101-layout .sig-menu>li>a:hover:after{transform:scaleX(1)}

/* HEADER FAMILY 81-101: hybrid/structural */
body.h101-header-family-hybrid .h101-layout:is(header,.hercules-layout-header){
    border:2px solid rgba(15,23,42,.16);
    border-radius:calc(var(--h101-radius) * .35);
    box-shadow:none;
}
body.h101-header-family-hybrid .h101-layout .sig-mark{
    border:2px solid currentColor;
    background:transparent;
    color:inherit;
}
body.h101-header-family-hybrid .h101-layout .sig-cta,
body.h101-header-family-hybrid .h101-layout .hercules-layout-header__cta{
    border:2px solid currentColor;
    box-shadow:4px 4px 0 rgba(15,23,42,.15);
}

/* Header micro-variants */
body.h101-system.h101-demo-1 .h101-layout header,
body.h101-system.h101-demo-1 header.h101-layout{--h101-local-shift:0}
body.h101-system [class*="h101-header-layout-"] .sig-brand-text strong{font-size:clamp(14px,1.35vw,18px)}
body.h101-system .h101-header-layout-2 .sig-brand,
body.h101-system .h101-header-layout-7 .sig-brand,
body.h101-system .h101-header-layout-12 .sig-brand,
body.h101-system .h101-header-layout-17 .sig-brand,
body.h101-system .h101-header-layout-22 .sig-brand,
body.h101-system .h101-header-layout-27 .sig-brand,
body.h101-system .h101-header-layout-32 .sig-brand,
body.h101-system .h101-header-layout-37 .sig-brand,
body.h101-system .h101-header-layout-42 .sig-brand,
body.h101-system .h101-header-layout-47 .sig-brand,
body.h101-system .h101-header-layout-52 .sig-brand,
body.h101-system .h101-header-layout-57 .sig-brand,
body.h101-system .h101-header-layout-62 .sig-brand,
body.h101-system .h101-header-layout-67 .sig-brand,
body.h101-system .h101-header-layout-72 .sig-brand,
body.h101-system .h101-header-layout-77 .sig-brand,
body.h101-system .h101-header-layout-82 .sig-brand,
body.h101-system .h101-header-layout-87 .sig-brand,
body.h101-system .h101-header-layout-92 .sig-brand,
body.h101-system .h101-header-layout-97 .sig-brand{flex-direction:column;text-align:center}
body.h101-system [class*="h101-header-layout-"] .sig-menu>li:nth-child(2n)>a{padding-inline:calc(10px + (var(--h101-gap) * .08))}
body.h101-system [class*="h101-header-layout-"] .sig-cta{min-height:calc(40px + (var(--h101-pad) * .12))}

/* FOOTER FAMILY 1-20: corporate multi-column */
body.h101-footer-family-corporate .h101-layout:is(footer,.hercules-layout-footer){
    border-top:5px solid var(--sig-a,#2563eb);
}
body.h101-footer-family-corporate .h101-layout .sig-fgrid,
body.h101-footer-family-corporate .h101-layout .hercules-layout-footer__inner{
    gap:clamp(24px,3vw,52px);
}

/* FOOTER FAMILY 21-40: minimal/single row */
body.h101-footer-family-minimal .h101-layout:is(footer,.hercules-layout-footer){
    padding-block:0;
}
body.h101-footer-family-minimal .h101-layout .sig-fgrid,
body.h101-footer-family-minimal .h101-layout .hercules-layout-footer__inner{
    padding-top:32px;
    padding-bottom:24px;
}
body.h101-footer-family-minimal .h101-layout .sig-bottom .hsw{
    padding-top:14px;
    padding-bottom:14px;
}
body.h101-footer-family-minimal .h101-layout .sig-ft-title{
    margin-bottom:9px!important;
}

/* FOOTER FAMILY 41-60: conversion and lead focused */
body.h101-footer-family-conversion .h101-layout:is(footer,.hercules-layout-footer){
    position:relative;
    border-top:0;
}
body.h101-footer-family-conversion .h101-layout:is(footer,.hercules-layout-footer):before{
    content:"";
    display:block;
    width:min(1240px,calc(100% - 40px));
    height:6px;
    margin:0 auto;
    background:linear-gradient(90deg,var(--sig-a,#2563eb),var(--sig-a2,#f59e0b));
}
body.h101-footer-family-conversion .h101-layout .sig-pre,
body.h101-footer-family-conversion .h101-layout .sig-f2-band,
body.h101-footer-family-conversion .h101-layout .sig-f4-news{
    border-radius:var(--h101-radius);
}

/* FOOTER FAMILY 61-80: content-rich/eCommerce */
body.h101-footer-family-content .h101-layout:is(footer,.hercules-layout-footer){
    border-top:1px solid rgba(255,255,255,.14);
}
body.h101-footer-family-content .h101-layout .sig-fgrid,
body.h101-footer-family-content .h101-layout .hercules-layout-footer__inner{
    grid-auto-flow:row;
}
body.h101-footer-family-content .h101-layout .sig-links a{
    display:inline-flex;
    align-items:center;
    min-height:28px;
}
body.h101-footer-family-content .h101-layout .sig-links a:before{
    content:"";
    width:5px;
    height:5px;
    border-radius:50%;
    background:currentColor;
    margin-right:8px;
    opacity:.5;
}

/* FOOTER FAMILY 81-101: modern/app/experimental */
body.h101-footer-family-experimental .h101-layout:is(footer,.hercules-layout-footer){
    width:min(1320px,calc(100% - 24px));
    margin:24px auto 12px;
    border:2px solid rgba(255,255,255,.16);
    border-radius:max(4px,var(--h101-radius));
    overflow:hidden;
}
body.h101-footer-family-experimental .h101-layout .sig-bottom{
    background:rgba(255,255,255,.035);
}
body.h101-footer-family-experimental .h101-layout .sig-socials a,
body.h101-footer-family-experimental .h101-layout .sig-badges span{
    border-radius:calc(var(--h101-radius) * .5);
}

/* PAGE LAYOUT SYSTEM */
body.h101-system .site-main,
body.h101-system main{
    --h101-local-width:var(--h101-content-width);
}
body.h101-system .hg14-shell,
body.h101-system .hercules-section__inner,
body.h101-system .entry-content>.wp-block-group>.wp-block-group__inner-container{
    max-width:var(--h101-local-width);
}

/* 1-20 Landing/Hero */
body.h101-page-family-landing .hg14-hero,
body.h101-page-family-landing .elementor-top-section:first-child,
body.h101-page-family-landing .entry-content>.wp-block-cover:first-child,
body.h101-page-family-landing .entry-content>.vc_row:first-child{
    border-radius:0 0 var(--h101-page-radius) var(--h101-page-radius);
    overflow:hidden;
}
body.h101-page-family-landing .hg14-section{
    padding-block:clamp(58px,7vw,92px);
}
body.h101-page-family-landing .hg14-cards article,
body.h101-page-family-landing .hg14-prices article{
    border-radius:var(--h101-page-radius);
}

/* 21-40 Blog/Content/Editorial */
body.h101-page-family-editorial .entry-content,
body.h101-page-family-editorial .hg14-shell{
    max-width:min(var(--h101-local-width),1180px);
}
body.h101-page-family-editorial .hg14-section{
    padding-block:clamp(48px,6vw,76px);
}
body.h101-page-family-editorial .hg14-media{
    grid-template-columns:minmax(0,1.15fr) minmax(280px,.85fr);
    gap:clamp(26px,5vw,64px);
}
body.h101-page-family-editorial .hg14-cards article{
    border-left:4px solid var(--g14-accent,#2563eb);
    border-radius:0 var(--h101-page-radius) var(--h101-page-radius) 0;
}

/* 41-60 E-commerce/Product */
body.h101-page-family-commerce .hg14-prices,
body.h101-page-family-commerce .woocommerce ul.products{
    gap:clamp(16px,2.4vw,30px);
}
body.h101-page-family-commerce .hg14-prices article,
body.h101-page-family-commerce .woocommerce ul.products li.product,
body.h101-page-family-commerce .hg14-cards article{
    border-radius:var(--h101-page-radius);
    box-shadow:0 16px 38px rgba(15,23,42,.08);
}
body.h101-page-family-commerce .hg14-btn,
body.h101-page-family-commerce .button{
    border-radius:999px;
}

/* 61-80 Portfolio/Showcase */
body.h101-page-family-showcase .hg14-gallery{
    gap:clamp(10px,1.8vw,22px);
}
body.h101-page-family-showcase .hg14-gallery figure,
body.h101-page-family-showcase .hg14-media .hg14-photo{
    border-radius:var(--h101-page-radius);
    overflow:hidden;
}
body.h101-page-family-showcase .hg14-gallery figure:nth-child(3n+1){
    transform:translateY(calc(var(--h101-page-radius) * -.35));
}

/* 81-101 Dashboard/Portal/App */
body.h101-page-family-dashboard .hg14-section{
    padding-block:clamp(44px,5vw,68px);
}
body.h101-page-family-dashboard .hg14-cards,
body.h101-page-family-dashboard .hg14-stats,
body.h101-page-family-dashboard .hg14-timeline{
    gap:clamp(12px,1.6vw,20px);
}
body.h101-page-family-dashboard .hg14-cards article,
body.h101-page-family-dashboard .hg14-stats>div,
body.h101-page-family-dashboard .hg14-timeline>div{
    border:1px solid rgba(15,23,42,.12);
    border-radius:calc(var(--h101-page-radius) * .65);
    box-shadow:none;
}
body.h101-page-family-dashboard .hg14-section:nth-of-type(even){
    background:rgba(148,163,184,.075);
}

/* Role-aware refinements */
body.h101-role-membership .hg14-prices article{transform:none!important}
body.h101-role-coaches .hg14-gallery figure,
body.h101-role-gallery .hg14-gallery figure{aspect-ratio:4/3}
body.h101-role-schedule .hg14-timeline,
body.h101-role-schedule .hercules-timetable{border:1px solid rgba(15,23,42,.12);border-radius:var(--h101-page-radius);overflow:hidden}
body.h101-role-contact .hg14-contact{gap:clamp(22px,4vw,52px)}
body.h101-role-faq .hg14-faq article{border-radius:calc(var(--h101-page-radius) * .75)}

/* Small per-layout variation without changing builder content */
body.h101-system[class*="h101-page-layout-"] .hg14-section:nth-of-type(3n+2) .hg14-shell{
    max-width:calc(var(--h101-local-width) - (var(--h101-gap) * 1.5));
}
body.h101-system[class*="h101-page-layout-"] .hg14-section:nth-of-type(4n) .hg14-eyebrow{
    letter-spacing:.18em;
}
body.h101-system[class*="h101-page-layout-"] .hg14-cards article,
body.h101-system[class*="h101-page-layout-"] .hg14-prices article,
body.h101-system[class*="h101-page-layout-"] .hg14-faq article{
    padding:calc(22px + (var(--h101-pad) * .18));
}

/* Responsive protection */
@media(max-width:980px){
    body.h101-header-family-floating .h101-layout:is(header,.hercules-layout-header){
        width:calc(100% - 20px);
        margin-top:10px;
    }
    body.h101-footer-family-experimental .h101-layout:is(footer,.hercules-layout-footer){
        width:calc(100% - 16px);
        margin-top:16px;
    }
    body.h101-page-family-editorial .hg14-media{grid-template-columns:1fr}
    body.h101-page-family-showcase .hg14-gallery figure:nth-child(3n+1){transform:none}
}
@media(max-width:600px){
    body.h101-system{--h101-gap:12px;--h101-pad:16px}
    body.h101-header-family-niche .h101-layout:is(header,.hercules-layout-header){border-left:0;border-top:4px solid var(--sig-a,#2563eb)}
    body.h101-header-family-hybrid .h101-layout:is(header,.hercules-layout-header){border-left:0;border-right:0;border-radius:0}
    body.h101-footer-family-experimental .h101-layout:is(footer,.hercules-layout-footer){width:100%;margin:12px 0 0;border-left:0;border-right:0;border-radius:0}
}
@media(prefers-reduced-motion:reduce){
    body.h101-system .h101-layout *,
    body.h101-system .hg14-gallery figure{transition:none!important;animation:none!important}
}
