/* Pyramid — stylesheet for OJS public pages
   Palette: deep purple, sandstone gold, lavender and warm ivory.
   Upload as a complete replacement for the previous custom stylesheet. */
:root {
 --pyramid-purple-dark: #29134e;
 --pyramid-purple: #5420a3;
 --pyramid-purple-hover: #432078;
 --pyramid-gold: #d3a238;
 --pyramid-gold-light: #ffdf86;
 --pyramid-text: #282137;
 --pyramid-muted: #615771;
 --pyramid-border: #dfd5ed;
 --pyramid-lavender: #f5effc;
 --pyramid-ivory: #fffaf0;
}
/* 1 - Base: no page-wide gradient, webfonts or animations */
body {color:var(--pyramid-text);}
.pkp_structure_main {min-width:0;}
.pkp_structure_main img {max-width:100%;height:auto;}
.pkp_structure_main a {overflow-wrap:break-word;}

/* 2 - Preserve the user's full-width banner without affecting menu sizing */
.pkp_structure_head {width:100%;box-sizing:border-box;overflow:visible;}
.pkp_structure_head .pkp_head_wrapper,
.pkp_structure_head .pkp_site_name_wrapper,
.pkp_structure_head .pkp_site_name {box-sizing:border-box;}
.pkp_structure_head .pkp_site_name .is_img img,
.pkp_structure_head .pkp_site_name a.is_img img {
 display:block!important;width:100%!important;height:auto!important;
 max-width:100%!important;max-height:none!important;object-fit:contain;border:0;
}
@media(min-width:992px){
 .pkp_structure_head .pkp_head_wrapper {width:100%;max-width:100%;}
 .pkp_structure_head .pkp_site_name_wrapper {width:100%!important;max-width:100%!important;padding-left:0!important;padding-right:0!important;}
 .pkp_structure_head .pkp_site_name {width:100%!important;max-width:none!important;padding:0!important;margin:0!important;white-space:normal!important;}
 .pkp_structure_head .pkp_site_name .is_img,
 .pkp_structure_head .pkp_site_name a.is_img {display:block!important;width:100%!important;max-width:100%!important;margin:0!important;padding:0!important;line-height:0;}
}
/* 3 - Navigation: neutral white typography on deep purple, consistent sizes.
   Restrict styles to desktop menu; mobile uses original theme controls. */
@media(min-width:992px){
 .pkp_navigation_primary_wrapper {background:var(--pyramid-purple-dark);border-bottom:2px solid var(--pyramid-gold);}
 .pkp_navigation_primary > li > a,
 .pkp_navigation_primary > li > a:link,
 .pkp_navigation_primary > li > a:visited {
  color:#fff!important;background:transparent!important;
  font-family:Arial,Helvetica,sans-serif;font-size:13px;font-weight:600;
  line-height:1.4;letter-spacing:0;text-transform:none;text-shadow:none;
 }
 .pkp_navigation_primary > li > a:hover,
 .pkp_navigation_primary > li > a:focus {color:#fff!important;background:var(--pyramid-purple-hover)!important;}
 .pkp_navigation_primary .dropdown-menu,
 .pkp_navigation_primary ul.dropdown-menu,
 .pkp_navigation_primary > li > ul {background:#fff!important;border:1px solid var(--pyramid-border);}
 .pkp_navigation_primary .dropdown-menu a,
 .pkp_navigation_primary > li > ul a,
 .pkp_navigation_primary .dropdown-menu a:visited {
  color:var(--pyramid-purple-dark)!important;background:#fff!important;
  font-size:13px;font-weight:500;text-transform:none;line-height:1.45;
 }
 .pkp_navigation_primary .dropdown-menu a:hover,
 .pkp_navigation_primary > li > ul a:hover {color:var(--pyramid-purple)!important;background:var(--pyramid-lavender)!important;}
}
/* For themes with a colored bar on mobile, retain default navigation layout */
@media(max-width:991px){
 .pkp_structure_head .pkp_site_name .is_img img,
 .pkp_structure_head .pkp_site_name a.is_img img {width:100%!important;max-height:none!important;}
}

/* 4 - Page titles, Pyramid branding */
.pkp_structure_main .page_title,
.pkp_structure_main h1.page_title {color:var(--pyramid-purple-dark);line-height:1.35;border-bottom:2px solid var(--pyramid-border);padding-bottom:12px;}
.pkp_structure_main .cmp_breadcrumbs {font-size:12px;color:var(--pyramid-muted);}

/* 5 - Issue header and section headings */
.obj_issue_toc > .heading {padding-bottom:16px;margin-bottom:18px;border-bottom:1px solid var(--pyramid-border);}
.obj_issue_toc > .heading .title {color:var(--pyramid-purple-dark);font-weight:700;line-height:1.4;}
.obj_issue_toc > .heading .published,
.obj_issue_toc > .heading .description {color:var(--pyramid-muted);line-height:1.65;}
.obj_issue_toc .cover img {border:1px solid var(--pyramid-border);border-radius:5px;}
.obj_issue_toc .section > .title,
.obj_issue_toc .section > h2,
.obj_issue_toc .section .section_title {
 color:var(--pyramid-purple-dark);background:var(--pyramid-lavender);
 border-left:4px solid var(--pyramid-gold);padding:10px 13px;
 font-size:18px;font-weight:700;line-height:1.4;margin:22px 0 16px;
}

/* 6 - Issue articles: a single flat card per row.
   Most OJS themes use .obj_issue_toc .articles > li.
   Do not turn article lists into CSS grid or touch other list elements. */
.obj_issue_toc .articles {margin:0;padding:0;list-style:none;}
.obj_issue_toc .articles > li {
 position:relative;box-sizing:border-box;
 padding:17px 18px;margin:0 0 12px;
 border:1px solid var(--pyramid-border);border-left:3px solid var(--pyramid-gold);
 border-radius:6px;background:#fff;
}
.obj_issue_toc .articles > li:hover {border-left-color:var(--pyramid-purple);background:var(--pyramid-ivory);}
/* Avoid nested cards if the theme has an article-summary wrapper */
.obj_issue_toc .articles > li .obj_article_summary {background:transparent;border:0;box-shadow:none;padding:0;margin:0;}
.obj_issue_toc .obj_article_summary .title,
.obj_issue_toc .obj_article_summary .title a {
 color:var(--pyramid-purple-dark);font-weight:700;font-size:17px;
 line-height:1.48;text-decoration:none;overflow-wrap:anywhere;
}
.obj_issue_toc .obj_article_summary .title a:hover {color:var(--pyramid-purple);text-decoration:underline;}
.obj_issue_toc .obj_article_summary .authors,
.obj_issue_toc .obj_article_summary .author {font-size:13px;color:var(--pyramid-muted);line-height:1.6;margin-top:6px;}
.obj_issue_toc .obj_article_summary .pages,
.obj_issue_toc .obj_article_summary .published,
.obj_issue_toc .obj_article_summary .doi,
.obj_issue_toc .obj_article_summary .meta {font-size:12px;color:var(--pyramid-muted);line-height:1.6;}
.obj_issue_toc .obj_article_summary .doi a {color:var(--pyramid-purple);}
/* Keep galley links compact; no expensive transitions */
.obj_issue_toc .obj_article_summary .galleys_links,
.obj_issue_toc .obj_article_summary .galleys {margin-top:12px;padding:0;display:flex;gap:7px;flex-wrap:wrap;align-items:center;}
.obj_issue_toc .obj_article_summary .galleys_links li,
.obj_issue_toc .obj_article_summary .galleys li {margin:0;padding:0;list-style:none;}
.obj_issue_toc .obj_article_summary a.obj_galley_link,
.obj_issue_toc .obj_article_summary .obj_galley_link {
 display:inline-block;min-width:48px;box-sizing:border-box;
 padding:6px 11px;border:1px solid var(--pyramid-border);border-radius:4px;
 color:var(--pyramid-purple-dark);background:var(--pyramid-lavender);
 font-size:12px;font-weight:700;line-height:1.4;text-align:center;text-decoration:none;
}
.obj_issue_toc .obj_article_summary a.obj_galley_link:hover {background:var(--pyramid-purple);border-color:var(--pyramid-purple);color:#fff;}
.obj_issue_toc .obj_article_summary .views,
.obj_issue_toc .obj_article_summary .downloads,
.obj_issue_toc .obj_article_summary .stats {font-size:12px;color:var(--pyramid-muted);}

/* 7 - Article detail: title, authors, DOI, abstract, references */
.pkp_page_article .obj_article_details > .page_title,
.pkp_page_article .obj_article_details > .title,
.pkp_page_article .obj_article_details .page_title {
 color:var(--pyramid-purple-dark);font-size:clamp(22px,2.4vw,29px);
 line-height:1.42;font-weight:700;overflow-wrap:anywhere;
}
.pkp_page_article .obj_article_details .authors,
.pkp_page_article .obj_article_details .author {color:var(--pyramid-muted);line-height:1.6;}
.pkp_page_article .obj_article_details .doi,
.pkp_page_article .obj_article_details .item.doi {font-size:13px;overflow-wrap:anywhere;}
.pkp_page_article .obj_article_details .doi a {color:var(--pyramid-purple);}
.pkp_page_article .obj_article_details .item.abstract,
.pkp_page_article .obj_article_details .abstract {
 background:var(--pyramid-ivory);border:1px solid var(--pyramid-border);
 border-left:3px solid var(--pyramid-gold);border-radius:5px;
 padding:17px 19px;line-height:1.78;overflow-wrap:anywhere;
}
.pkp_page_article .obj_article_details .item > .label,
.pkp_page_article .obj_article_details .item > h2 {color:var(--pyramid-purple-dark);font-size:16px;font-weight:700;}
.pkp_page_article .obj_article_details .item.references,
.pkp_page_article .obj_article_details .references {line-height:1.7;overflow-wrap:anywhere;}
.pkp_page_article .obj_article_details a.obj_galley_link,
.pkp_page_article .obj_article_details .obj_galley_link {
 display:inline-block;border-radius:4px;border:1px solid var(--pyramid-purple);
 background:#fff;color:var(--pyramid-purple);padding:7px 12px;
 font-size:12px;font-weight:700;text-decoration:none;
}
.pkp_page_article .obj_article_details a.obj_galley_link:hover {background:var(--pyramid-purple);color:#fff;}
/* 8 - Summary cards on journal home/archive: small enhancement only */
.current_issue .obj_issue_summary .title,
.issues_archive .obj_issue_summary .title {color:var(--pyramid-purple-dark);font-weight:700;}
/* 9 - Mobile density without any movement or animation */
@media(max-width:767px){
 .obj_issue_toc .articles > li {padding:13px 12px;margin-bottom:10px;}
 .obj_issue_toc .obj_article_summary .title,
 .obj_issue_toc .obj_article_summary .title a {font-size:15px;line-height:1.5;}
 .obj_issue_toc .obj_article_summary .authors {font-size:12px;}
 .obj_issue_toc .section > .title,
 .obj_issue_toc .section > h2 {font-size:16px;padding:9px 11px;}
 .pkp_page_article .obj_article_details .item.abstract,
 .pkp_page_article .obj_article_details .abstract {padding:13px;}
}

/* ================================================================
 10 — Contained desktop navigation aligned with the banner.
 ================================================================ */
.pkp_structure_head {background:#fff !important;}
@media (min-width:992px) {
  .pkp_structure_head .pkp_navigation_primary_row::before,
  .pkp_structure_head .pkp_navigation_primary_row::after,
  .pkp_structure_head .pkp_navigation_primary_wrapper::before,
  .pkp_structure_head .pkp_navigation_primary_wrapper::after {
    content:none !important;
    display:none !important;
  }
  /* Match the content/banner max width, not the browser viewport. */
  .pkp_structure_head .pkp_navigation_primary_row {
    box-sizing:border-box;
    width:100% !important;
    max-width:1160px !important;
    margin-left:auto !important;
    margin-right:auto !important;
    padding:0 !important;
    background:var(--pyramid-purple-dark) !important;
    border:0 !important;
    border-bottom:3px solid var(--pyramid-gold) !important;
    box-shadow:none !important;
    min-height:0 !important;
  }
  .pkp_structure_head .pkp_navigation_primary_wrapper {
    width:100% !important;
    max-width:100% !important;
    margin:0 !important;
    padding:0 !important;
    background:transparent !important;
    border:0 !important;
    box-shadow:none !important;
  }
  .pkp_structure_head .pkp_navigation_primary {
    box-sizing:border-box;
    margin:0 !important;
    padding:0 16px !important;
    min-height:0 !important;
    background:transparent !important;
    border:0 !important;
  }
  .pkp_structure_head .pkp_navigation_primary > li > a {
    display:block;
    padding:12px 15px !important;
    line-height:20px !important;
    color:#fff !important;
    background:transparent !important;
    font-size:13px !important;
    font-family:Arial,Helvetica,sans-serif !important;
    font-weight:600 !important;
    text-transform:none !important;
  }
  .pkp_structure_head .pkp_navigation_primary > li > a:hover,
  .pkp_structure_head .pkp_navigation_primary > li > a:focus {
    color:#fff !important;
    background:var(--pyramid-purple-hover) !important;
  }
  /* OJS default places the search widget separately on the right. */
  .pkp_structure_head .pkp_navigation_search_wrapper a,
  .pkp_structure_head .pkp_navigation_search_wrapper a:visited {
    color:#fff !important;
  }
  .pkp_structure_head .pkp_navigation_search_wrapper a:hover {
    color:var(--pyramid-gold-light) !important;
  }
  .pkp_structure_head .pkp_navigation_primary > li > ul {
    background:#fff !important;
  }
}
/* Mobile: no full-width generated bars, preserve OJS hamburger menu. */
@media (max-width:991px) {
  .pkp_structure_head .pkp_navigation_primary_row::before,
  .pkp_structure_head .pkp_navigation_primary_row::after {
    content:none !important;display:none !important;
  }
  .pkp_structure_head .pkp_navigation_primary_row,
  .pkp_structure_head .pkp_navigation_primary_wrapper {
    background:transparent !important;
  }
}

/* 11 — Sidebar titles and keyboard focus on public pages */
.pkp_structure_sidebar .pkp_block > .title {
 color:var(--pyramid-purple-dark);
 background:var(--pyramid-lavender);
 border-inline-start:3px solid var(--pyramid-gold);
 padding:8px 10px;
}
.pkp_structure_main a:focus-visible,
.pkp_structure_sidebar a:focus-visible {
 outline:2px solid var(--pyramid-purple);
 outline-offset:3px;
}
.pkp_structure_head a:focus-visible {
 outline:2px solid var(--pyramid-gold);
 outline-offset:-2px;
}

/* 12 — Grouped menu for the Information custom block */
.pyramid-sidebar-menu {
 font-size:13px;
 line-height:1.45;
}

.pyramid-sidebar-menu .pyramid-menu-group {
 margin:0 0 12px;
 border:1px solid var(--pyramid-border);
 border-radius:6px;
 background:#fff;
}

.pyramid-sidebar-menu .pyramid-menu-group:last-child {
 margin-bottom:0;
}

.pyramid-sidebar-menu .pyramid-menu-title {
 margin:0;
 padding:10px 12px;
 border-bottom:2px solid var(--pyramid-gold);
 border-radius:5px 5px 0 0;
 background:var(--pyramid-purple-dark);
 color:#fff;
 font-size:13px;
 font-weight:700;
 line-height:1.4;
}

.pyramid-sidebar-menu ul {
 margin:0;
 padding:0;
 list-style:none;
}

.pyramid-sidebar-menu li {
 margin:0;
 padding:0;
 list-style:none;
}

.pyramid-sidebar-menu li + li {
 border-top:1px solid var(--pyramid-border);
}

.pyramid-sidebar-menu li > a,
.pyramid-sidebar-menu .pyramid-menu-pending,
#customblock-information > .content > ul > li > a {
 display:block;
 padding:9px 12px;
 border-inline-start:3px solid transparent;
 overflow-wrap:anywhere;
}

.pyramid-sidebar-menu li > a,
.pyramid-sidebar-menu li > a:visited,
#customblock-information > .content > ul > li > a,
#customblock-information > .content > ul > li > a:visited {
 background:#fff;
 color:var(--pyramid-purple-dark);
 text-decoration:none;
}

.pyramid-sidebar-menu li:last-child > a,
.pyramid-sidebar-menu li:last-child > .pyramid-menu-pending {
 border-radius:0 0 5px 5px;
}

.pyramid-sidebar-menu li > a::before {
 content:"›";
 content:"›" / "";
 margin-inline-end:7px;
 color:var(--pyramid-purple);
 font-weight:700;
}

.pyramid-sidebar-menu li > a:hover,
.pyramid-sidebar-menu li > a:focus-visible,
#customblock-information > .content > ul > li > a:hover,
#customblock-information > .content > ul > li > a:focus-visible {
 border-inline-start-color:var(--pyramid-gold);
 background:var(--pyramid-lavender);
 color:var(--pyramid-purple);
 text-decoration:underline;
 text-underline-offset:3px;
}

.pyramid-sidebar-menu li > a:focus-visible,
#customblock-information > .content > ul > li > a:focus-visible {
 outline:2px solid var(--pyramid-purple);
 outline-offset:-2px;
}

.pyramid-sidebar-menu .pyramid-menu-pending {
 background:var(--pyramid-ivory);
 color:var(--pyramid-muted);
}

.pyramid-sidebar-menu .pyramid-menu-pending small {
 display:block;
 font-size:11px;
}

/* 13 — Egyptian theme for Author Guidelines and Copyright Notice */
:is(.pyramid-author-guidelines, .pyramid-copyright-policy) {
 box-sizing:border-box;
 padding:clamp(16px, 3vw, 30px);
 border:1px solid var(--pyramid-border);
 border-top:4px solid var(--pyramid-gold);
 border-radius:8px;
 background:var(--pyramid-ivory);
 color:var(--pyramid-text);
 font-size:1rem;
 line-height:1.7;
 overflow-wrap:anywhere;
}

:is(.pyramid-author-guidelines, .pyramid-copyright-policy) > p {
 margin:0 0 14px;
}

:is(.pyramid-author-guidelines, .pyramid-copyright-policy) > h2 {
 margin:26px 0 12px;
 padding:10px 14px;
 border-inline-start:4px solid var(--pyramid-gold);
 background:var(--pyramid-lavender);
 color:var(--pyramid-purple-dark);
 font-size:clamp(1.04rem, 2vw, 1.3rem);
 font-weight:700;
 line-height:1.35;
}

.pyramid-author-guidelines > p:first-child,
.pyramid-copyright-policy > h2:first-child {
 position:relative;
 margin:0 0 24px;
 padding:20px 96px 20px 20px;
 border:0;
 border-bottom:3px solid var(--pyramid-gold);
 border-radius:5px;
 background:var(--pyramid-purple-dark);
 color:#fff;
}

.pyramid-author-guidelines > p:first-child::after,
.pyramid-copyright-policy > h2:first-child::after {
 content:"";
 position:absolute;
 inset-inline-end:18px;
 top:50%;
 width:60px;
 height:46px;
 transform:translateY(-50%);
 background:repeating-linear-gradient(
  to bottom, var(--pyramid-gold-light) 0 8px, var(--pyramid-gold) 8px 10px
 );
 clip-path:polygon(
  50% 0, 62% 23%, 68% 23%, 68% 40%, 77% 40%, 77% 58%,
  86% 58%, 86% 76%, 95% 76%, 95% 90%, 100% 90%, 100% 100%,
  0 100%, 0 90%, 5% 90%, 5% 76%, 14% 76%, 14% 58%,
  23% 58%, 23% 40%, 32% 40%, 32% 23%, 38% 23%
 );
 pointer-events:none;
}

.pyramid-author-guidelines > :is(ul, ol) {
 margin:0 0 16px;
 padding:12px 16px;
 padding-inline-start:2.25rem;
 border:1px solid var(--pyramid-border);
 border-radius:5px;
 background:#fff;
}

.pyramid-author-guidelines li + li {
 margin-top:9px;
}

.pyramid-author-guidelines li::marker,
.pyramid-author-guidelines li > strong {
 color:var(--pyramid-purple-dark);
}

:is(.pyramid-author-guidelines, .pyramid-copyright-policy) a {
 color:var(--pyramid-purple);
 text-decoration:underline;
 text-underline-offset:3px;
}

:is(.pyramid-author-guidelines, .pyramid-copyright-policy) a:hover {
 background:var(--pyramid-lavender);
 color:var(--pyramid-purple-dark);
 text-decoration-thickness:2px;
}

:is(.pyramid-author-guidelines, .pyramid-copyright-policy) a:focus-visible {
 outline:2px solid currentColor;
 outline-offset:3px;
}

.pyramid-author-guidelines > p:first-child a {
 color:var(--pyramid-gold-light);
}

.pyramid-author-guidelines > p:first-child a:hover {
 background:var(--pyramid-gold-light);
 color:var(--pyramid-purple-dark);
}

.pyramid-copyright-policy a[rel="license"] {
 padding:2px 6px;
 border-radius:4px;
 background:var(--pyramid-gold-light);
 color:var(--pyramid-purple-dark);
 font-weight:700;
 -webkit-box-decoration-break:clone;
 box-decoration-break:clone;
}

.pyramid-copyright-policy a[rel="license"]:hover {
 background:var(--pyramid-purple-dark);
 color:#fff;
}

@media (max-width:480px) {
 .pyramid-author-guidelines > p:first-child,
 .pyramid-copyright-policy > h2:first-child {
  padding:14px;
  padding-inline-end:54px;
 }

 .pyramid-author-guidelines > p:first-child::after,
 .pyramid-copyright-policy > h2:first-child::after {
  inset-inline-end:10px;
  width:34px;
  height:28px;
 }
}
