/*
Theme Name: GP Child Francomedia
Theme URI: https://franco-media.com
Description: Franco-media.com child theme of GeneratePress, built for the Site Rebuild 2026 (TASK-N05), design system Ocean Sunset.
Author: Nick (Cowork desk) for Siam Info Guide Part., Ltd
Template: generatepress
Version: 1.0.0
Text Domain: gp-child-francomedia
*/

body{font-family:var(--font-body)}

/* ==========================================================================
TASK-N05 closing addendum - Brain ruling 05-09-2026, items 2, 3 (partial), 5
Staging only. Reversible, display-only - no post_content touched.
========================================================================== */

/* Item 2 + item 3 (breadcrumb half): hide [wpseo_breadcrumb] shortcode output
sitewide. Stable selector confirmed on real post content (Le Celtique,
Crepes bretonnes) - covers all 213 flagged pieces of content in one rule.
Real content-level removal stays a separate Phase 3 batch job. */
.wpcode-sitewide-breadcrumbs {
display: none !important;
}

/* Item 3 (duplicate title/CTA half): NO STABLE SELECTOR EXISTS. Verified on
Le Celtique and Crepes bretonnes - the duplicate H1/H2 blocks and the
double CTA/fiche-card duplication share their exact classes with
legitimate body content, with no unique wrapper to target safely. Left
for the Phase 3 content-cleanup batch job rather than a fragile per-page
hack, per the ruling's own caveat. */

/* Item 5: hide the floating vertical share widget (SumoMe plugin) below
768px, matching the site's real mobile breakpoint (raised from 480px,
TASK-N09b, 19-09-2026: the 480px cutoff left a gap between 481 and 767px
where the mobile hero layout was already active but this widget was not
yet suppressed, overlapping the article H1). In-content share buttons
stay untouched, so sharing stays available on mobile. */
@media (max-width: 768px) {
.sumome-share-client-wrapper-left-page {
display: none !important;
}
}

/* Item 5 (addendum, real breakpoint): SumoMe swaps to a different DOM
element - .sumome-share-client-wrapper-mobile-bottom-bar - below its own
JS-detected mobile breakpoint, instead of keeping -left-page. This is the
element actually visible on real phones; -left-page never renders there.
Confirmed live on the Crepes bretonnes article at a true 390px viewport.
Raised to 768px alongside the rule above for consistency, TASK-N09b,
19-09-2026. */
@media (max-width: 768px) {
.sumome-share-client-wrapper-mobile-bottom-bar {
display: none !important;
}
}

/* ==========================================================================
TASK-N15 addendum - Brain ruling, section AP, 24-09-2026
Staging only. Sitewide image alignment utilities - the theme previously had
no .alignleft/.alignright/.aligncenter rules at all, so a classic-editor
aligned image (WordPress core class) rendered with float:none and no size
constraint, exactly as found under TASK-N14 Task 3 on AA Insurance RU
(post 193392, "Приветливый персонал" block). Closes punch list item 13.
========================================================================== */

.alignleft {
float: left;
margin: 0 20px 20px 0;
}
.alignright {
float: right;
margin: 0 0 20px 20px;
}
.aligncenter {
display: block;
margin: 20px auto;
}
.alignleft,
.alignright,
.aligncenter {
max-width: 100%;
height: auto;
}

@media (max-width: 599px) {
.alignleft,
.alignright {
float: none;
display: block;
margin: 20px auto;
}
}

/* ==========================================================================
TASK-N25 - Brain rulings CX and CZ, 05-10-2026, items 1, 2 and 3
Staging only. Display-only, no post_content touched. One block, one place:
this sitewide stylesheet loads last on every page, so it reaches the 73
ordinary pages (parent page.php, .entry-content) as well as article bodies
(.abody) and client profile bodies (.desc). Tokens only, no new hex.
========================================================================== */

/* --- Item 2: content typography sweep -------------------------------------
   The container carries the body stack once (PT Sans, body size, line height,
   ink colour); every plain content element below inherits it, so no browser
   serif can leak. Cause found on staging: the content containers never set a
   font-family, so ul, ol, li, figcaption, table cells and the plugin grid
   fell back to the browser default (Times New Roman). Article and profile
   bodies keep their ruled article size (--size-article-body); ordinary pages
   take --size-body. */
.entry-content{
  font-family:var(--font-body);
  font-size:var(--size-body);
  line-height:var(--lh-body);
  color:var(--os-text);
}
.abody,
.desc{
  font-family:var(--font-body);
  font-size:var(--size-article-body);
  line-height:var(--lh-article-body);
  color:var(--os-text);
}
/* Zero-specificity group: it beats the browser defaults but gives way to any
   class rule that already styles an element (article blockquote, profile
   headings, plugin icon fonts, buttons with their own face). */
:where(.entry-content, .abody, .desc) :where(ul, ol, li, dl, dt, dd, blockquote, table, caption, th, td, figure, figcaption, address, label, legend, fieldset, details, summary){
  font-family:inherit;
  font-size:inherit;
  line-height:inherit;
  color:inherit;
}
/* Form controls and buttons never inherit by default; make them. */
:where(.entry-content, .abody, .desc) :where(input, textarea, select, button, optgroup){
  font-family:inherit;
  font-size:max(1em, var(--m-size-input));
  line-height:inherit;
}
:where(.entry-content, .abody, .desc) :where(table){ max-width:100%; }
:where(.entry-content, .abody, .desc) figcaption,
:where(.entry-content, .abody, .desc) .wp-caption-text{
  margin-top:var(--space-3);
  font-size:var(--size-small);
  line-height:1.4;
  color:var(--os-muted);
}
/* Legacy content headings carry inline faces (Barlow Condensed, Alegreya Sans,
   browser serif). The ruled display face wins for h1 and h4 to h6 only; h2
   and h3 are already ruled in article.css and client-profile.css. An article
   label h4 that carries its own colour keeps its ruled PT Sans look. */
.entry-content :is(h1, h4, h5, h6):not([style*="color"]),
.abody :is(h1, h4, h5, h6):not([style*="color"]),
.desc :is(h1, h4, h5, h6):not([style*="color"]){
  font-family:var(--font-display) !important;
  font-weight:var(--weight-display);
  color:var(--os-heading);
}
/* N40 (H1): h4, h5 and h6 take the second heading token; h1 stays on --os-heading. */
.entry-content :is(h4, h5, h6):not([style*="color"]),
.abody :is(h4, h5, h6):not([style*="color"]),
.desc :is(h4, h5, h6):not([style*="color"]){
  color:var(--os-heading-2);
}
.entry-content :is(h1, h4, h5, h6)[style*="color"],
.abody :is(h1, h5, h6)[style*="color"],
.desc :is(h1, h4, h5, h6)[style*="color"]{
  font-family:var(--font-display) !important;
  font-weight:var(--weight-display);
}
.entry-content :is(h4, h5, h6),
.desc :is(h4, h5, h6),
.abody :is(h4, h5, h6):not([style*="color"]){
  font-size:var(--size-card-title);
  line-height:var(--lh-card-title);
}
/* A body h1 is a legacy duplicate of the page title; it sits one step below
   the section heading scale on desktop and one step smaller again on phones. */
.entry-content h1,
.abody h1,
.desc h1{
  margin:var(--space-12) 0 var(--space-3);
  font-size:var(--size-section-h2) !important;
  line-height:var(--lh-h2);
  letter-spacing:normal;
}

/* Ordinary page title (parent page.php, header.entry-header h1.entry-title):
   measured on /tarifs-publicitaires/ and /contact/ as Times New Roman 700,
   colour #222, the one serif left on those pages. Given the ruled page title
   face, colour and the existing page title tokens (phones: --m-size-page-h1). */
.inside-article > .entry-header .entry-title{
  font-family:var(--font-display);
  font-weight:var(--weight-display);
  font-size:var(--size-page-h1);
  line-height:var(--lh-page-h1);
  letter-spacing:var(--ls-page-h1);
  color:var(--os-heading);
}

/* --- Item 1: nothing in the content may exceed the column --------------- */
:where(.entry-content, .abody, .desc) :where(img, video, iframe, embed, object){ max-width:100%; }
:where(.entry-content, .abody, .desc) :where(img){ height:auto; }
.entry-content,
.abody,
.desc{ overflow-wrap:break-word; }

/* --- Item 3: vertical rhythm, once, on the existing spacing tokens ------
   Scale used: 8 (tight, under a heading or before a list), 16 (between
   blocks), 26 / 30 (above h3 / h2, as ruled in article.css). The ruled
   heading-to-text gaps of N18b and N18c are not touched. */
.entry-content p,
.desc p{ margin:var(--space-7) 0 0; }
.entry-content :is(h2, h3),
.desc :is(h2, h3){ margin-bottom:0; }
.entry-content h2{ margin-top:var(--space-12); font-family:var(--font-display); font-weight:var(--weight-display); font-size:var(--size-h2); line-height:var(--lh-h2); color:var(--os-heading); }
.entry-content h3{ margin-top:var(--space-11); font-family:var(--font-display); font-weight:var(--weight-display); font-size:var(--size-h3); line-height:var(--lh-h3); color:var(--os-heading-2); }
.entry-content :is(ul, ol),
.desc :is(ul, ol){ margin:var(--space-7) 0 0; padding-left:var(--space-10); }
.entry-content li,
.desc li{ margin-top:var(--space-2); }
/* heading to image */
:is(.entry-content, .abody, .desc) :is(h2, h3) + :is(img, figure, .wp-caption, .wpb_single_image, p:has(> img:only-child)){ margin-top:var(--space-5); }
/* image to text */
:is(.entry-content, .abody, .desc) :is(figure, .wp-caption){ margin:var(--space-7) 0 0; }
:is(.entry-content, .abody, .desc) .wpb_single_image{ margin-bottom:var(--space-7); }
:is(.entry-content, .abody, .desc) :is(img, figure, .wp-caption, .wpb_single_image) + :is(p, ul, ol){ margin-top:var(--space-7); }
/* paragraph to list */
:is(.entry-content, .abody, .desc) p + :is(ul, ol){ margin-top:var(--space-3); }
/* list to heading */
:is(.entry-content, .abody, .desc) :is(ul, ol) + h2{ margin-top:var(--space-12); }
:is(.entry-content, .abody, .desc) :is(ul, ol) + h3{ margin-top:var(--space-11); }

@media (max-width: 768px) {
  /* Item 3: h1 one step smaller on phones (25px, --m-size-h2). */
  .entry-content h1,
  .abody h1,
  .desc h1,
  :is(.entry-content, .abody, .desc) .wpb_wrapper h1.vc_custom_heading.vc_do_custom_heading{ font-size:var(--m-size-h2) !important; margin-top:var(--space-10); }
  .inside-article > .entry-header .entry-title{ font-size:var(--m-size-page-h1); letter-spacing:-.7px; }
  .entry-content,
  .abody,
  .desc{ font-size:var(--m-size-article-body); }
  /* Item 1: the plugin post grid keeps a 30px item gutter with a matching
     negative margin, which widens its box 30px past a phone column and pushes
     the page 13px sideways. One column on a phone needs no gutter. The plugin
     prints its own rules after this sheet, hence the !important pair. The
     plugin also prints a 46px !important size on a legacy heading, matched
     above with extra specificity. */
  :is(.entry-content, .abody, .desc) .vc_grid-gutter .vc_pageable-slide-wrapper{ margin-right:0 !important; }
  :is(.entry-content, .abody, .desc) .vc_grid-gutter .vc_grid-item{ padding-right:0 !important; }
  :is(.entry-content, .abody, .desc) .vc_grid-container{ max-width:100%; }
}

/* ==========================================================================
TASK-N37b - Brain rulings GF and GG, 09-10-2026. Housekeeping build 1, Part B (mobile
rules from N37a and N37b), Part A support rules and Part D (back to top).
Staging only. Display-only, no post_content touched. Tokens only, no hex.
Scope: the brief names .abody; the same rules are written for the three body
containers of the theme, :is(.abody, .desc, .entry-content), because pages
(.entry-content) and client profiles (.desc) carry the same legacy markup as
articles (.abody). Plugin sheets print after this one, so rules aimed at a
plugin class repeat that class to win on specificity instead of using
!important. The only !important in this block is B5, justified there.
========================================================================== */

/* --- B1: 14px floor (N37a rules 1 to 4, N37b f, g, h) ----------------------
   --size-floor is 14px (tokens.css). The Forminator label size is written with
   !important in forminator.css and reads --gpcf-label-size, set here. */
:is(.abody, .desc, .entry-content){ --gpcf-label-size:var(--size-floor); }
:is(.abody, .desc, .entry-content) :is(.tags .lab, .tags a, .vc_figure-caption, .vc_figure-caption a, cite, .fiche .chip, .forminator-label, .forminator-required, .mejs-time span, span.mejs-time-float-current){
  font-size:var(--size-floor);
}
:is(.abody, .desc, .entry-content) :is(.vc_btn3.vc_btn3-size-sm, .vc_btn3.vc_btn3-size-xs){
  font-size:var(--size-floor);
}
:is(.abody, .desc, .entry-content) :is(.ecf-licenseinf, .ecf-licenseinf *){
  font-size:var(--size-floor);
}

/* --- B2: Forminator form title ------------------------------------------- */
:is(.abody, .desc, .entry-content) h2.forminator-title{ font-size:clamp(22px, 7vw, 34px); }

/* --- B3: headings that broke mid word (N37b d, e) -------------------------
   Sizes apply on phones only; the desktop sizes are the ruled ones. The long
   word wraps at a hyphen (hyphens:auto needs the html lang attribute, which
   WPML sets per language: fr-FR, en-US, ru-RU) and, failing that, anywhere. */
:is(.abody, .desc, .entry-content) :is(h1, h2, h3, h4, h5, h6),
.entry-title,
.sigpage-title,
.pagehead h1,
.phero h1{
  overflow-wrap:break-word;
  -webkit-hyphens:auto;
  hyphens:auto;
}
@media (max-width: 768px){
  .inside-article > .entry-header h1.entry-title{ font-size:clamp(24px, 7vw, 32px); }
  :is(.abody, .desc, .entry-content) h2{ font-size:clamp(22px, 6.5vw, 28px); }
}
/* An h5 or h6 that kept a colour (a heading on its own background fill) takes
   the theme card-title size like every other h5 and h6, never the legacy one. */
.abody :is(h5, h6)[style*="color"]{ font-size:var(--size-card-title); line-height:var(--lh-card-title); }

/* --- B4: breadcrumbs and buttons wrap (N37b a, b) -------------------------
   .pagehead .crumbs sets nowrap at (0,2,0); the pagehead selectors repeat it.
   max-width keeps a long link inside the line so its text can wrap. */
nav.crumbs,
.pagehead nav.crumbs{ flex-wrap:wrap; }
nav.crumbs a,
nav.crumbs .here,
.pagehead nav.crumbs a,
.pagehead nav.crumbs .here{ white-space:normal; max-width:100%; }
:is(.abody, .desc, .entry-content) .vc_btn3{ white-space:normal; }

/* --- B5: caption shortcode writes an inline width (N37b c) ----------------
   The [caption] shortcode prints style="width:2090px" on the figure (post
   86657, 1,719 px of overflow at 390 px). A normal rule cannot beat an inline
   width, so max-width carries !important here and nowhere else in this block. */
:is(.abody, .desc, .entry-content) .wp-caption{ max-width:100% !important; }
:is(.abody, .desc, .entry-content) .wp-caption img{ height:auto; }

/* --- B6: tables scroll inside themselves, never stack ---------------------
   On phones a table becomes a block that scrolls sideways when it is wider than
   the column; its cells keep their columns. Desktop tables keep their own width
   (a block-level table would shrink a full-width price table to its content). */
@media (max-width: 768px){
  :is(.abody, .desc, .entry-content) table{ display:block; max-width:100%; overflow-x:auto; }
}

/* --- B7: circle photos (Fabrice, 09-10-2026; N37b i) ----------------------
   article.css gives every .abody image margin-top:16px; inside a WPBakery image
   frame (circle, rounded, outline) that pushes the photo down and turns the
   round frame into an ellipse. */
:is(.abody, .desc, .entry-content) .vc_single_image-wrapper img{ margin:0; }

/* --- A support: empty WPBakery wrappers (a removed heading, grid or button
   leaves a hollow content element; the filter collapses most of them) ------ */
:is(.abody, .desc, .entry-content) .wpb_content_element:has(> .wpb_wrapper:empty){ display:none; }
/* Cards that replace a removed profile grid are the closing band card: no date. */
.gpcf-df-rel .card time{ display:none; }

/* --- Part D (CP3): back to top ---------------------------------------------
   Fixed, bottom right, 44px target (--tap-min). The ring is --os-cta, the arrow
   is --os-cta-ink (19.1 to 1 on the white card, 16.8 to 1 on the --os-tint hover). Invisible until gpcf-header.js
   adds .is-visible (one screen scrolled, page at least two screens tall).
   The theme has no fixed call bar, so nothing needs to be cleared. */
.gpcf-top{
  position:fixed;
  right:var(--page-gutter-mobile);
  bottom:max(var(--space-9), env(safe-area-inset-bottom));
  z-index:90;
  display:inline-flex;
  align-items:center;
  justify-content:center;
  width:var(--tap-min);
  height:var(--tap-min);
  padding:0;
  border:2px solid var(--os-cta);
  border-radius:var(--radius-pill);
  background:var(--os-card);
  color:var(--os-cta-ink);
  box-shadow:var(--shadow-floating);
  cursor:pointer;
  opacity:0;
  visibility:hidden;
  transform:translateY(var(--space-3));
  transition:opacity var(--duration-base) var(--ease), transform var(--duration-base) var(--ease), visibility 0s linear var(--duration-base), background var(--duration-fast) var(--ease);
}
.gpcf-top.is-visible{
  opacity:1;
  visibility:visible;
  transform:none;
  transition-delay:0s;
}
.gpcf-top:hover,
.gpcf-top:focus-visible{ background:var(--os-tint); }
.gpcf-top svg{ display:block; stroke:currentColor; transform:rotate(-90deg); }
.gpcf-nav-open .gpcf-top{ display:none; }
@media (min-width: 769px){
  .gpcf-top{ right:var(--page-gutter); }
}
@media (prefers-reduced-motion: reduce){
  .gpcf-top{ transition:none; }
}

/* ==========================================================================
TASK-N37c - Brain ruling GK, 10-10-2026. Two small fixes found by the N37b
deploy check at 390 px. Staging only. Display-only. Tokens only, no hex.
(The chrome text floor of N37c is in the theme sheets and tokens.css:
--size-chrome and --size-label, no rule is added here for it.)
========================================================================== */

/* --- Breadcrumb links: the padding and border stay inside max-width -------
   B4 gives a crumb link max-width:100% so a long parent title wraps. With the
   default content-box sizing the 13px side padding and the 1px border sat on
   top of that, so a title longer than the line (about 57 characters or more)
   pushed the page 10px past a 390px screen (14 pages found on staging). */
nav.crumbs a,
nav.crumbs .here,
.pagehead nav.crumbs a,
.pagehead nav.crumbs .here{ box-sizing:border-box; }

/* --- WPBakery image carousel: the shortcode prints style="width:400px" ----
   on the carousel element (170448 FR, 168980 EN, 170454 RU), 46px wider than
   the 354px phone column. max-width is a separate property from the inline
   width, so the clamp applies by itself; !important is kept as ruled so that
   a plugin sheet printed after this one cannot lift the clamp. */
:is(.abody, .desc, .entry-content) .vc_images_carousel{ max-width:100% !important; }

/* --- Easy Contact Form licence notice (an administrator sees it on the
   contact form of a profile, 12px from the plugin). Same floor as B1, written
   for the contact section, which is outside the three body containers. ---- */
.contact .form :is(.ecf-licenseinf, .ecf-licenseinf *){ font-size:var(--size-floor); }
