/* 3.1: legibilidade consistente, restrita às telas do aplicativo. */
:is(.s2-app,.s2-login,.s2-public-shell,.s2p-shell,.sportiva-onboarding){font-size:16px;line-height:1.55;text-size-adjust:100%;-webkit-text-size-adjust:100%}
:is(.s2-app,.s2-login,.s2p-shell,.sportiva-onboarding) :is(p,li,td,th,label){line-height:1.55}
:is(.s2-app,.s2-login,.s2p-shell,.sportiva-onboarding) :is(input,select,textarea){font-size:16px!important;line-height:1.5;max-width:100%}
:is(.s2-app,.s2-login,.s2p-shell,.sportiva-onboarding) :is(button,.s2-btn,.svc-btn){font-size:16px;min-height:44px;line-height:1.35;white-space:normal}
:is(.s2-app,.s2-login,.s2p-shell,.sportiva-onboarding) :is(input,select):not([type=checkbox]):not([type=radio]):not([type=hidden]):not([type=color]):not([type=file]){min-height:46px}
:is(.s2-app,.s2-login,.s2p-shell,.sportiva-onboarding) :is(input[type=checkbox],input[type=radio]){min-width:20px;min-height:20px;flex-shrink:0}
:is(.s2-app,.s2-login,.s2p-shell,.sportiva-onboarding) :is(a,button,input,select,textarea,summary):focus-visible{outline:3px solid var(--sportiva-secondary,#2563eb);outline-offset:3px}
:is(.s2-app,.s2p-shell) :is(h1,h2,h3){line-height:1.22;overflow-wrap:break-word}
.s2-nav a{font-size:16px;min-height:48px}.s2-nav-title{font-size:14px;letter-spacing:.06em}.s2-sidebar-brand{min-height:90px;height:auto;padding-top:14px;padding-bottom:14px}
.s2p-shell :is(.s2p-service-card,.s2p-checkin-summary,.s2p-checkin-service,.s2p-section-heading){min-width:0}
.sportiva-kpis{grid-template-columns:repeat(auto-fit,minmax(155px,1fr))}.sportiva-kpis article{padding:18px}.sportiva-kpis strong{font-size:28px;line-height:1.25}.sportiva-kpis :is(small,p,em){white-space:normal;line-height:1.5}
.sportiva-form-grid.compact{grid-template-columns:repeat(auto-fit,minmax(170px,1fr))}.sportiva-settings-form label{font-size:16px}.sportiva-ob-progress :is(span,small){line-height:1.5}
.sportiva-risk-table,.sportiva-booking-table{overflow-x:auto}.sportiva-risk-table>.head,.sportiva-risk-table>article{min-width:660px}.sportiva-booking-table>.head,.sportiva-booking-table>article{min-width:590px}
.s2-content :is(.svc-table-wrap,.s2-table-wrap){overflow-x:auto;max-width:100%}
@media(max-width:700px){.s2-content{padding:20px 14px 110px}.s2-page-head{flex-wrap:wrap}.s2-page-head p{font-size:16px}.sportiva-kpis{grid-template-columns:repeat(2,minmax(0,1fr))}.sportiva-kpis strong{font-size:26px}.sportiva-dash-hero{padding:22px 18px}.sportiva-dash-hero p{font-size:16px}.sportiva-demo-banner{flex-wrap:wrap}.sportiva-demo-banner div{min-width:200px}.sportiva-ob-actions button{padding:12px 16px}}
@media(prefers-reduced-motion:reduce){:is(.s2-app,.s2p-shell,.sportiva-onboarding) *{scroll-behavior:auto!important;animation:none!important;transition:none!important}}

/* 3.1.1: real reflow inside WordPress/theme containers, without clipping the page. */
@media screen {
:is(.s2-app,.s2-login,.s2-public-shell,.s2p-shell,.sportiva-onboarding),
:is(.s2-app,.s2-login,.s2-public-shell,.s2p-shell,.sportiva-onboarding) *{box-sizing:border-box}
:is(.s2-main,.s2-content,.s2-legacy,.s2-section,.s2p-container,.sportiva-ob-shell,.sportiva-ob-form,.sportiva-card,.sportiva-settings,.sportiva-dashboard,.sportiva-intelligence,.sportiva-reservations){min-width:0;max-width:100%}
:is(.s2-app,.s2p-shell,.sportiva-onboarding) :where(form,fieldset,label,article,section,details){min-width:0}
:is(.s2-app,.s2p-shell,.sportiva-onboarding) :where(input,select,textarea){min-width:0}
:is(.s2-app,.s2p-shell,.sportiva-onboarding) :where(p,small,strong,h1,h2,h3,label,button,a){overflow-wrap:anywhere}
:is(.s2-app,.s2p-shell,.sportiva-onboarding) :where(img,video,canvas){max-width:100%}
:is(.s2-app,.s2-login,.s2p-shell,.sportiva-onboarding) :is(input[type=checkbox],input[type=radio]){width:20px;height:20px;min-width:20px;min-height:20px;max-width:20px;padding:0;flex:0 0 20px;vertical-align:middle}
:is(.s2-content,.s2p-container) :is(.svc-table-wrap,.s2-table-wrap,.svc-table-responsive,.dbz-table-wrap){min-width:0;max-width:100%;overflow-x:auto;overscroll-behavior-x:contain;-webkit-overflow-scrolling:touch}
:is(.sportiva-dash-grid,.sportiva-dash-grid.lower,.sportiva-form-grid,.sportiva-brand-editor,.sportiva-settings-cols,.sportiva-rule-grid,.sportiva-module-grid,.s2-grid-2,.s2-today-grid,.s2-dashboard-columns,.s2p-services-grid,.s2p-home-services-grid)>*{min-width:0;max-width:100%}
.s2-topbar{gap:10px}.s2-search{min-width:0;flex:1;max-width:520px}.s2-top-actions{flex-shrink:0;gap:8px}.s2-theme-trigger{white-space:nowrap;overflow-wrap:normal;flex-shrink:0}
.s2-sidebar-brand strong{white-space:normal;overflow-wrap:anywhere;line-height:1.2}
.s2p-brand{min-width:0;flex-shrink:1}.s2p-brand>span{min-width:0}.s2p-brand img{flex-shrink:0}
.s2p-brand strong,.s2p-brand small{line-height:1.25;white-space:normal;overflow-wrap:anywhere}
.s2p-header{height:auto;min-height:76px}.s2p-header-inner{min-height:76px;padding-block:8px}
.s2p-header-actions{gap:6px}
.sportiva-card>header,.s2-section-head{flex-wrap:wrap}
.sportiva-chart-legend{flex-wrap:wrap}
.sportiva-health{min-width:0;max-width:100%}
.sportiva-kpis strong{white-space:normal;overflow:visible;text-overflow:clip;font-size:clamp(21px,2vw,28px)}
.sportiva-funnel>div{min-width:0}.sportiva-funnel span{overflow-wrap:anywhere}
.sportiva-demo-banner div{min-width:0}
.sportiva-rule{grid-template-columns:20px minmax(0,1fr) 38px}
.sportiva-onboarding .sportiva-switch>span,.sportiva-onboarding .sportiva-module-grid label>span{min-width:0}
.sportiva-onboarding .sportiva-ob-actions{flex-wrap:wrap}
.sportiva-onboarding .sportiva-ob-brand>div{min-width:0}
.sportiva-onboarding .sportiva-ob-brand strong{overflow-wrap:anywhere;line-height:1.25}

/* Gateway switches stay beside their text, independent from text-field rules. */
.dbz-gateway>summary{gap:14px;flex-wrap:wrap}
.dbz-gateway :is(.dbz-gateway-toggle,.dbz-switch-line){display:flex;flex-direction:row;align-items:center;justify-content:flex-start;gap:10px;line-height:1.5;cursor:pointer;min-height:44px}
.dbz-gateway :is(.dbz-gateway-toggle,.dbz-switch-line)>input[type=checkbox]{width:20px;height:20px;min-height:20px;min-width:20px;margin:0;padding:0;flex:0 0 20px}
.dbz-gateway :is(.dbz-gateway-toggle,.dbz-switch-line)>span{display:block;min-width:0;overflow-wrap:break-word}
.dbz-gateway>div{grid-template-columns:repeat(2,minmax(0,1fr))}
.dbz-gateway-recurring{min-width:0;grid-template-columns:minmax(0,1fr) minmax(0,1fr)}
.dbz-webhook,.dbz-gateway-note{min-width:0;max-width:100%;overflow-wrap:anywhere}
.dbz-gateway-guidance{grid-template-columns:repeat(3,minmax(0,1fr))}

/* Theme names, descriptions and the default badge each get their own line. */
.s2-theme-popover .s2-theme-option{grid-template-columns:44px minmax(0,1fr);padding:12px 26px 12px 10px;align-items:start;min-height:82px}
.s2-theme-popover .s2-theme-swatches{width:44px;max-width:100%;margin-top:2px}
.s2-theme-popover .s2-theme-option :is(strong,small){white-space:normal;overflow:visible;text-overflow:clip;overflow-wrap:anywhere;line-height:1.4}
.s2-theme-popover .s2-theme-option .s2-theme-default-badge{position:static!important;display:inline-block;margin-top:7px;font-size:12px;line-height:1.4;padding:3px 6px;border:1px solid currentColor;border-radius:6px;white-space:normal}
.s2-theme-popover .s2-theme-option .s2-theme-default-badge[hidden]{display:none!important}
.s2-theme-popover .s2-theme-option.is-selected:after{top:11px;bottom:auto;right:7px}

@media screen and (max-width:1100px){
  .sportiva-dash-grid,.sportiva-dash-grid.lower{grid-template-columns:minmax(0,1fr)}
  .sportiva-quick>div{grid-template-columns:repeat(2,minmax(0,1fr))}
}
@media screen and (max-width:900px){
  .dbz-gateway>div,.dbz-gateway-recurring{grid-template-columns:minmax(0,1fr)}
  .sportiva-risk-table>article,.sportiva-booking-table>article{min-width:0}
  .sportiva-risk-table>.head,.sportiva-booking-table>.head{min-width:0}
}
@media screen and (max-width:800px){
  .s2-app .s2-topbar{height:auto;min-height:64px;flex-wrap:wrap;padding:10px 12px;gap:8px}
  .s2-app .s2-search{width:auto;flex:1 1 120px;margin:0;max-width:none}
  .s2-app .s2-search>input{width:100%}
  .s2-top-actions{gap:5px}
  .s2p-header,.s2p-header-inner{min-height:64px}
  .s2p-header-inner{gap:8px}
  .s2p-header .s2-theme-trigger{padding:0 8px}
  .s2p-header .s2-theme-trigger>span{display:none}
  .s2p-header .s2-theme-trigger svg{display:block}
  .s2-bottom-nav,.s2p-bottom-nav{height:auto;min-height:72px;padding-bottom:max(8px,env(safe-area-inset-bottom))}
  .s2-bottom-nav a,.s2p-bottom-nav a{min-width:0;min-height:54px;white-space:normal;text-align:center;line-height:1.25;font-size:12px}
  .s2-content{padding-bottom:110px}
}
@media screen and (max-width:600px){
  .dbz-gateway-guidance{grid-template-columns:minmax(0,1fr)}
  .sportiva-card{padding:16px}
  .sportiva-kpis,.sportiva-intel-summary{gap:8px;grid-template-columns:repeat(2,minmax(0,1fr))}
  .sportiva-kpis article{padding:13px 11px}
  .sportiva-quick>div{grid-template-columns:minmax(0,1fr)}
  .sportiva-risk-list article{grid-template-columns:36px minmax(0,1fr)}
  .sportiva-risk-list>article>span{grid-column:2}
  .sportiva-insights article{grid-template-columns:32px minmax(0,1fr)}
  .sportiva-insights article>a{grid-column:2;justify-self:start}
  .sportiva-reset-scopes{min-width:0}
  .sportiva-funnel{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:6px}
  .sportiva-funnel>div{padding:10px 6px}.sportiva-funnel>i{display:none}
  .s2-theme-popover .s2-theme-grid{grid-template-columns:minmax(0,1fr)}
  .s2p-brand small{letter-spacing:.025em;font-size:12px}
  .s2p-brand strong{font-size:16px}
  .s2p-brand img{width:36px;height:36px}
  .s2p-hero-actions,.s2p-service-toolbar,.dbz-action-row{flex-wrap:wrap}
  .s2p-shell .s2p-primary-checkin-button{min-width:0;white-space:normal;text-align:center}
  .sportiva-onboarding .sportiva-ob-actions>span{flex:1 1 100%;order:-1}
}
@media screen and (min-width:801px){
  .s2-theme-popover:not(.s2-theme-modal){max-height:calc(100dvh - 100px);overflow-y:auto;overscroll-behavior:contain}
  .s2-theme-popover:not(.s2-theme-modal) .s2-theme-grid{grid-template-columns:minmax(0,1fr)}
}

} /* screen: PDF and print layouts keep their own sizing. */
