/* OC LOGISTIQUE — largeur adaptative. Scoped to theme structures, not admin screens. */
:root { --oc-site-max: 1540px; --oc-site-gutter: clamp(18px, 3vw, 56px); }
html, body { max-width:100%; }
body { overflow-x: clip; }
/* The custom OC theme uses .wrap (1180px) everywhere, including header/footer. */
body .wrap {
    width: 100%; max-width: var(--oc-site-max);
    margin-left: auto; margin-right: auto;
    padding-left: var(--oc-site-gutter); padding-right: var(--oc-site-gutter);
    box-sizing: border-box;
}
/* Keep long prose comfortably readable, while allowing page modules/cards to be wider. */
body .prose { max-width: 1000px; width:100%; }
body .page-top h1 { max-width:1100px; }
body .page-top p, body .intro-text { max-width:900px; }
body .hero-grid, body .about-grid, body .contact-grid, body .two { min-width:0; }
body .hero-grid > *, body .about-grid > *, body .contact-grid > *, body .two > * { min-width:0; }
body .services, body .press-grid { min-width:0; }
/* RH front-end is inside theme section.wrap > div.prose: remove both nested limitations. */
body .section.wrap:has(.oc-rh-front),
body .section.wrap:has(.oc-rh-dashboard) {
    max-width: var(--oc-site-max) !important;
    width: 100% !important;
}
body .prose:has(.oc-rh-front),
body .prose:has(.oc-rh-dashboard) {
    max-width: none !important;
    width: 100% !important;
    min-width: 0;
}
/* RH dashboard uses a second .wrap nested within the content column. */
body .oc-rh-front, body .oc-rh-front > .oc-rh-dashboard,
body .oc-rh-dashboard {
    width:100% !important; max-width: none !important;
    min-width:0 !important; box-sizing:border-box;
}
body .oc-rh-front > .oc-rh-dashboard { padding-left:0 !important; padding-right:0 !important; }
body .oc-rh-dashboard .oc-rh-panel { max-width: none !important; min-width:0; width:100%; }
body .oc-rh-dashboard .oc-rh-stats { grid-template-columns: repeat(4,minmax(0,1fr)); }
body .oc-rh-dashboard .oc-rh-tabs { display:grid; grid-template-columns:repeat(4,minmax(0,1fr)); gap:14px; }
body .oc-rh-dashboard .oc-rh-tab { width:100%; min-width:0; white-space:normal; min-height:76px; text-align:center; }
body .oc-rh-dashboard .ocpanel { max-width:none; }
body .oc-rh-dashboard .ocscroll { max-width:100%; overflow-x:auto; }
/* HTML tables in general never force the entire page out of viewport. */
body .prose table { max-width:100%; }
body .oc-rh-dashboard input:not([type=checkbox]):not([type=radio]):not([type=hidden]),
body .oc-rh-dashboard select, body .oc-rh-dashboard textarea { max-width:100%; }
body .oc-rh-dashboard input[type=checkbox], body .oc-rh-dashboard input[type=radio] {
    width:auto !important; min-height:0 !important; height:auto !important; display:inline-block !important;
    flex:0 0 auto; accent-color:#17496b;
}
@media (min-width:1700px) { :root { --oc-site-max: 1640px; } }
@media (max-width:1100px) {
    body .oc-rh-dashboard .oc-rh-tabs { grid-template-columns:repeat(2,minmax(0,1fr)); }
    body .oc-rh-dashboard .oc-rh-stats { grid-template-columns:repeat(2,minmax(0,1fr)); }
}
@media (max-width:700px) {
    :root { --oc-site-gutter:18px; }
    body .oc-rh-dashboard .oc-rh-tabs { gap:9px; }
    body .oc-rh-dashboard .oc-rh-tab { min-height:64px; padding:12px 8px; font-size:13px; }
    body .oc-rh-dashboard .oc-rh-hero { flex-wrap:wrap; }
    body .oc-rh-dashboard .oc-rh-hero-aside { text-align:left; white-space:normal; }
}
@media (max-width:390px) { body .oc-rh-dashboard .oc-rh-tabs { grid-template-columns:1fr; } }
