/* ===== Goedert Mobile Nav — only active <=980px ===== */
.ggmn-burger{ display:none; }

@media (max-width:980px){
  /* ---- header: 3 zones inside Divi's shared column flex ---- */
  .et-l--header .et_pb_column_0_tb_header{ position:relative; align-items:center; }
  /* vertical breathing room so the (bigger) logo + icons aren't glued to the bar edges
     (Divi locks the row padding, so we grow the header via the column min-height) */
  .et-l--header .et_pb_column_0_tb_header{ min-height:64px !important; }
  /* neutralize Divi's relatively-positioned menu wrappers so the COLUMN (full width)
     is the logo's offset parent -> the G mark centers on the header, not the menu module */
  .et-l--header .et_pb_menu_0_tb_header,
  .et-l--header .et_pb_menu_inner_container{ position:static !important; }

  /* our hamburger, relocated by JS to be the first flex child -> far left */
  .ggmn-burger{
    display:inline-flex; order:-10; align-items:center; justify-content:center;
    width:42px; height:42px; padding:0; margin:0; border:0; background:transparent; cursor:pointer; color:#16130d;
  }
  .ggmn-burger__bars, .ggmn-burger__bars::before, .ggmn-burger__bars::after{
    content:""; display:block; width:24px; height:2px; background:currentColor; border-radius:2px; position:relative;
  }
  .ggmn-burger__bars::before{ position:absolute; top:-7px; } .ggmn-burger__bars::after{ position:absolute; top:7px; }

  /* hide Divi's native mobile hamburger + its dropdown */
  .et-l--header .et_pb_menu .mobile_menu_bar,
  .et-l--header .et_pb_menu .et_mobile_nav_menu{ display:none !important; }

  /* logo -> centered compact G mark (keep the link clickable) */
  .et-l--header .et_pb_menu__logo-wrap{
    position:absolute; left:50%; top:50%; transform:translate(-50%,-50%); margin:0 !important; padding:0 !important;
    width:52px !important; max-width:52px !important; min-width:0 !important; height:52px;
    background-image:var(--ggmn-gmark); background-size:contain; background-repeat:no-repeat; background-position:center;
  }
  .et-l--header .et_pb_menu__logo-wrap img{ opacity:0 !important; width:52px !important; height:52px !important; }
  /* the logo link is inline (~22px wide = the hidden img), so the mobile tap-highlight
     only covered a strip in the middle of the G. Fill the box (whole G is the tap target)
     and drop the default grey tap flash. */
  .et-l--header .et_pb_menu__logo-wrap a{ position:absolute; inset:0; display:block; -webkit-tap-highlight-color:transparent; }

  /* icons -> far right */
  .et-l--header .gcd_cart_icon_module_0_tb_header{ margin-left:auto; }

  /* drop the WPML language-switcher (flag) menu item from the drawer nav —
     we provide our own FR/DE toggle in the drawer footer */
  .ggmn-drawer__panels li[class*="wpml-ls"]{ display:none !important; }

  /* ---- overlay + drawer shell ---- */
  .ggmn-overlay{
    position:fixed; inset:0; background:rgba(0,0,0,.5); z-index:100000;
    opacity:0; visibility:hidden; transition:opacity .28s ease, visibility .28s ease;
  }
  body.ggmn-open .ggmn-overlay{ opacity:1; visibility:visible; }
  .ggmn-overlay[hidden]{ display:block; } /* we control via opacity/visibility, keep in flow */

  .ggmn-drawer{
    position:fixed; top:0; left:0; height:100vh; height:100dvh; width:84vw; max-width:360px; background:#fbf9f3; z-index:100001;
    display:flex; flex-direction:column; transform:translateX(-100%); transition:transform .3s cubic-bezier(.4,0,.2,1);
    box-shadow:0 0 40px -8px rgba(0,0,0,.4);
  }
  body.ggmn-open .ggmn-drawer{ transform:translateX(0); }
  body.admin-bar .ggmn-drawer{ top:32px; height:calc(100vh - 32px); height:calc(100dvh - 32px); }

  .ggmn-drawer__head{ display:flex; align-items:center; justify-content:space-between; padding:16px 18px; border-bottom:1px solid rgba(20,17,13,.1); }
  .ggmn-drawer__title{ font-weight:800; letter-spacing:.04em; text-transform:uppercase; font-size:13px; color:#16130d; }
  .ggmn-close{ border:0; background:transparent; color:#16130d; cursor:pointer; padding:4px; display:inline-flex; }

  .ggmn-drawer__panels{ position:relative; flex:1; overflow:hidden; }
  .ggmn-drawer__foot{ border-top:1px solid rgba(20,17,13,.1); padding:14px 18px 18px; }
  .ggmn-lang{ display:flex; gap:8px; margin-bottom:14px; }
  .ggmn-lang__item{ display:inline-flex; align-items:center; justify-content:center; min-width:42px; padding:7px 12px;
    border:1px solid rgba(20,17,13,.18); border-radius:8px; font-weight:700; font-size:13px; line-height:1;
    color:#16130d !important; text-decoration:none !important; }
  .ggmn-lang__item.is-active{ background:#16130d; color:#fff !important; border-color:#16130d; }
  .ggmn-contact{ display:flex; flex-direction:column; gap:9px; }
  .ggmn-contact__row{ display:flex; align-items:center; gap:9px; font-size:14px;
    color:#16130d !important; text-decoration:none !important; }
  .ggmn-contact__ic{ flex:0 0 18px; width:18px; height:18px; display:inline-flex; align-items:center; justify-content:center; opacity:.6; }
  .ggmn-contact__ic svg{ width:18px; height:18px; display:block; }
  .ggmn-contact__cta{ display:block; text-align:center; margin-top:5px; padding:13px 16px; border-radius:10px;
    background:#f1de58; color:#16130d !important; font-weight:800; font-size:14px; text-decoration:none !important; }

  .ggmn-drawer__panels .ggmn-panel{
    position:absolute; inset:0; overflow-y:auto; -webkit-overflow-scrolling:touch;
    transform:translateX(100%); transition:transform .28s cubic-bezier(.4,0,.2,1); background:#fbf9f3;
  }
  .ggmn-drawer__panels .ggmn-panel--root{ transform:translateX(0); }
  .ggmn-drawer__panels .ggmn-panel.is-current{ transform:translateX(0); }
  .ggmn-drawer__panels .ggmn-panel.is-left{ transform:translateX(-30%); }
  .ggmn-panel ul{ list-style:none; margin:0; padding:0; }
  .ggmn-panel li{ margin:0; border-bottom:1px solid rgba(20,17,13,.07); }
  .ggmn-panel a, .ggmn-drill{
    display:flex; align-items:center; justify-content:space-between; gap:10px;
    width:100%; min-height:52px; padding:0 18px; font-size:15px; color:#16130d; text-decoration:none;
    background:transparent; border:0; cursor:pointer; text-align:left; font-family:inherit;
  }
  .ggmn-drill::after{ content:""; width:9px; height:9px; border-right:2px solid #16130d; border-bottom:2px solid #16130d; transform:rotate(-45deg); flex:0 0 auto; }
  .ggmn-panel__head{ display:flex; align-items:center; gap:8px; padding:0 12px; min-height:52px; border-bottom:1px solid rgba(20,17,13,.1); background:#f3efe6; }
  .ggmn-back{ display:inline-flex; align-items:center; gap:8px; border:0; background:transparent; cursor:pointer; font:inherit; color:#16130d; font-weight:700; padding:8px; }
  .ggmn-back::before{ content:""; width:9px; height:9px; border-left:2px solid #16130d; border-bottom:2px solid #16130d; transform:rotate(45deg); }
  .ggmn-voirtout{ font-weight:700; color:#16130d; background:#f1de58; }

  .et-l--header .et_pb_menu__wrap{ flex:0 0 auto; }
  .et-l--header .et_pb_menu .et_pb_menu__menu{ display:none !important; }
}

@media (max-width:782px){ body.admin-bar .ggmn-drawer{ top:46px; height:calc(100vh - 46px); height:calc(100dvh - 46px); } }

/* never show the mobile UI on desktop */
@media (min-width:981px){ .ggmn-burger, .ggmn-overlay, .ggmn-drawer{ display:none !important; } }

@media (prefers-reduced-motion: reduce){
  .ggmn-drawer, .ggmn-overlay{ transition:none !important; }
}
