/* ============================================================
   PluriMed — brand stylesheet (OJS Default theme overrides)
   Forest palette · Fraunces / Montserrat / Newsreader
   ============================================================ */
@import url('https://fonts.googleapis.com/css2?family=Fraunces:opsz,wght@9..144,400;9..144,500;9..144,600;9..144,900&family=Montserrat:wght@500;600;700&family=Newsreader:ital,opsz,wght@0,6..72,400;0,6..72,500;0,6..72,600;1,6..72,400&display=swap');

:root{
  --pm-forest:#0F3A22;
  --pm-forest-2:#0B2A18;
  --pm-green:#2F7D3C;
  --pm-green-d:#256B31;
  --pm-leaf:#8CC888;
  --pm-cream:#EDE7D6;
  --pm-paper:#F5F2EA;
  --pm-soft:#E7EFE0;
  --pm-ink:#18231B;
  --pm-muted:#5C6350;
  --pm-line:#E3DDCE;
}

/* ---------- HEADER ---------- */
.pkp_structure_head{ background:var(--pm-forest) !important; }
.pkp_head_wrapper{ padding-top:6px; padding-bottom:6px; }

/* enlarged, prominent logo (kept from prior stylesheet) */
.pkp_site_name img,.pkp_site_name .is_img img,header img,#headerNavigationContainer img{
  max-height:126px !important; height:auto !important; width:auto !important;
}
.pkp_site_name_wrapper,.pkp_site_name{ padding:10px 0 !important; }

/* nav bar links legible on forest */
.pkp_site_nav_menu,
.pkp_structure_head .pkp_navigation_primary > li > a,
.pkp_structure_head .pkp_navigation_user > li > a,
.pkp_structure_head .pkp_navigation_user > li > span,
.pkp_structure_head .pkp_search a,
.pkp_structure_head .pkp_search .fa{
  color:var(--pm-cream) !important;
}
.pkp_structure_head .pkp_navigation_primary > li > a{
  font-family:"Montserrat",system-ui,sans-serif; font-weight:600;
  letter-spacing:.01em; font-size:.95rem;
}
.pkp_structure_head .pkp_navigation_user > li > a{
  font-family:"Montserrat",system-ui,sans-serif; font-weight:500; font-size:.85rem;
}
.pkp_structure_head .pkp_navigation_primary > li > a:hover,
.pkp_structure_head .pkp_navigation_primary > li > a:focus,
.pkp_structure_head .pkp_navigation_user > li > a:hover,
.pkp_structure_head .pkp_search a:hover{
  color:var(--pm-leaf) !important;
}
/* active/current nav item */
.pkp_structure_head .pkp_navigation_primary > li.current > a{
  color:#fff !important; border-bottom:2px solid var(--pm-leaf);
}

/* ---------- ABOUT DROPDOWN ---------- */
.pkp_navigation_primary .dropdown-menu,
.pkp_navigation_primary li ul{
  background:var(--pm-paper) !important;
  border:1px solid var(--pm-line) !important;
  border-radius:10px !important;
  box-shadow:0 12px 34px rgba(15,58,34,.22) !important;
  padding:6px 0 !important; min-width:230px; margin-top:6px;
}
.pkp_navigation_primary .dropdown-menu a,
.pkp_navigation_primary li ul a{
  color:var(--pm-ink) !important;
  font-family:"Montserrat",system-ui,sans-serif !important;
  font-weight:500 !important; font-size:.9rem !important;
  padding:9px 20px !important; display:block;
}
.pkp_navigation_primary .dropdown-menu a:hover,
.pkp_navigation_primary li ul a:hover,
.pkp_navigation_primary .dropdown-menu a:focus{
  background:var(--pm-soft) !important; color:var(--pm-green-d) !important;
}

/* ---------- TYPOGRAPHY ---------- */
body,.pkp_structure_page{ font-family:"Newsreader",Georgia,serif; color:var(--pm-ink); font-size:17px; }
h1,h2,h3,h4,h5,
.cmp_page_title,.pkp_page_title,.page_title,
.obj_issue_toc .title,.obj_article_summary .title a,.obj_article_summary .title,
.obj_issue_toc h2,.obj_galleys_links + .heading,.current_issue_title{
  font-family:"Fraunces",Georgia,serif !important; letter-spacing:-.01em; font-weight:600;
}
h1,h2,h3,.cmp_page_title,.pkp_page_title,.current_issue_title,.obj_issue_toc h2{ color:var(--pm-forest); }
/* utility / UI faces in Montserrat */
.pkp_navigation_primary,.pkp_navigation_user,
.cmp_button,.pkp_button,button,input[type="submit"],
.pkp_block .title,.pkp_block h2,.label,.pkp_screen_reader + *{
  font-family:"Montserrat",system-ui,sans-serif;
}

/* ---------- CONTENT ACCENTS ---------- */
.pkp_structure_content a{ color:var(--pm-green-d); text-underline-offset:2px; }
.pkp_structure_content a:hover{ color:var(--pm-forest); }
.obj_article_summary .title a{ color:var(--pm-forest) !important; }
.obj_article_summary .title a:hover{ color:var(--pm-green) !important; }

/* buttons */
.cmp_button,.pkp_button,button.pkp_button,input[type="submit"].pkp_button,
.obj_galleys_links a.obj_galley_link{
  background:var(--pm-green) !important; border-color:var(--pm-green) !important;
  color:#fff !important; border-radius:7px; font-weight:600;
}
.cmp_button:hover,.pkp_button:hover,.obj_galleys_links a.obj_galley_link:hover{
  background:var(--pm-forest) !important; border-color:var(--pm-forest) !important;
}

/* sidebar blocks */
.pkp_block .title,.pkp_block h2{ color:var(--pm-forest); font-family:"Fraunces",serif !important; font-weight:600; }

/* footer */
.pkp_structure_footer{ background:var(--pm-forest) !important; color:var(--pm-cream); }
.pkp_structure_footer a{ color:var(--pm-leaf) !important; }

/* ---------- PM-DROPDOWN-FIX: keep About menu open while hovering ---------- */
/* the 6px margin-top created a dead hover gap; bridge it with padding instead */
.pkp_navigation_primary .dropdown-menu,
.pkp_navigation_primary li ul{
  margin-top:0 !important;
}
.pkp_navigation_primary > li{ position:relative; }
/* invisible hover bridge spanning the old gap */
.pkp_navigation_primary .dropdown-menu::before,
.pkp_navigation_primary li ul::before{
  content:""; position:absolute; left:0; right:0; top:-14px; height:14px;
}
/* keep the submenu open while the pointer is anywhere on li or the menu */
.pkp_navigation_primary > li:hover > ul,
.pkp_navigation_primary > li:focus-within > ul,
.pkp_navigation_primary > li > ul:hover,
.pkp_navigation_primary > li:hover > .dropdown-menu,
.pkp_navigation_primary > li:focus-within > .dropdown-menu{
  display:block !important; visibility:visible !important; opacity:1 !important;
  pointer-events:auto !important;
}
/* small delay so the menu doesn't vanish instantly on brief mouse-outs */
.pkp_navigation_primary li ul,
.pkp_navigation_primary .dropdown-menu{
  transition:opacity .15s ease .1s, visibility 0s linear .25s;
}
.pkp_navigation_primary > li:hover > ul,
.pkp_navigation_primary > li:hover > .dropdown-menu{
  transition-delay:0s;
}


/* ---------- PM-LOGO-CACHEBUST: serve header logo via versioned URL ---------- */
/* the plain logo URL sits behind a server cache; the ?v= query bypasses it.
   bump the ?v= value whenever the logo file is replaced. */
.pkp_site_name a.is_img{
  display:block; max-width:302px; height:126px;
  background:url('/public/journals/2/pageHeaderLogoImage_en.png?v=pm18374x') no-repeat left center;
  background-size:contain;
}
.pkp_site_name a.is_img img{ opacity:0 !important; }


/* ---------- PM-MOBILE-FIX: phone header layout ---------- */
/* at small widths the theme absolutely-positions .pkp_site_name inside a
   fixed ~52px band, so the logo spills over the page content. restore
   normal flow and scale the logo to the viewport. */
@media (max-width: 767px){
  .pkp_head_wrapper{ height:auto !important; }
  .pkp_site_name_wrapper{
    position:static !important; display:flex !important; align-items:center;
    height:auto !important; min-height:0 !important;
    padding:8px 0 10px 0 !important;
  }
  .pkp_site_name{
    position:static !important; height:auto !important; width:auto !important;
    margin:0 0 0 48px !important; padding:0 !important; top:auto !important;
  }
  .pkp_site_name a.is_img{
    max-width:calc(100vw - 70px) !important; height:88px !important;
    background-position:left center !important;
  }
  .pkp_site_name a.is_img img{ max-height:88px !important; }
  /* hamburger stays left, vertically centred in the taller band */
  .pkp_site_nav_toggle{
    position:absolute !important; left:0 !important;
    top:50% !important; transform:translateY(-50%);
  }
}
