/* ==========================================================
   The Mailer Review — Journal Site Stylesheet
   Layered over the OJS 3.4 Default theme as the journal
   stylesheet (Settings → Website → Appearance → Advanced).
   Brings the site in line with the HTML galleys (mr.css):
   Alegreya + Alegreya SC, ink on paper, small-caps headings.
   Colors borrowed from the v.16 (2026) cover: sage, slate
   teal, and cover red.
   Archives page renders as a grid of covers.
   Live copy: www:~/web-server/ojs/public/journals/1/styleSheet.css
   ========================================================== */

/* ---------- Font Faces (shared with the galleys) ---------- */

@font-face { font-family: "Alegreya"; src: url("/public/fonts/Alegreya-Regular.woff2") format("woff2"); font-weight: 400; font-style: normal; font-display: swap; }
@font-face { font-family: "Alegreya"; src: url("/public/fonts/Alegreya-Italic.woff2") format("woff2"); font-weight: 400; font-style: italic; font-display: swap; }
@font-face { font-family: "Alegreya"; src: url("/public/fonts/Alegreya-Bold.woff2") format("woff2"); font-weight: 700; font-style: normal; font-display: swap; }
@font-face { font-family: "Alegreya"; src: url("/public/fonts/Alegreya-BoldItalic.woff2") format("woff2"); font-weight: 700; font-style: italic; font-display: swap; }
@font-face { font-family: "Alegreya SC"; src: url("/public/fonts/AlegreyaSC-Regular.woff2") format("woff2"); font-weight: 400; font-style: normal; font-display: swap; }
@font-face { font-family: "Alegreya SC"; src: url("/public/fonts/AlegreyaSC-Bold.woff2") format("woff2"); font-weight: 700; font-style: normal; font-display: swap; }
@font-face { font-family: "Alegreya SC"; src: url("/public/fonts/AlegreyaSC-Italic.woff2") format("woff2"); font-weight: 400; font-style: italic; font-display: swap; }
@font-face { font-family: "Alegreya SC"; src: url("/public/fonts/AlegreyaSC-BoldItalic.woff2") format("woff2"); font-weight: 700; font-style: italic; font-display: swap; }

/* v.16 cover palette */
:root {
  --mr-paper: #f4f7f2;    /* sage, lightened for reading */
  --mr-sage: #cfdbcb;     /* cover ground */
  --mr-teal: #7d9b96;     /* cover slate blocks */
  --mr-ink: #1a1a1a;
  --mr-muted: #4f5a57;
  --mr-rule: #c9d5c6;
  --mr-accent: #862422;   /* cover red — links, small marks */
  --mr-accent-deep: #4e1514;
  --mr-serif: "Alegreya", Georgia, "Times New Roman", serif;
  --mr-sc: "Alegreya SC", "Alegreya", Georgia, serif;
}

/* ---------- Base ---------- */

/* The theme pins the root at 14px; lift it so all rem sizes grow. */
html {
  font-size: 17px;
  font-synthesis: none;   /* never fake an italic or bold */
}

html,
body,
.pkp_structure_page {
  background: var(--mr-paper);
}

html,
body,
.pkp_structure_page,
.pkp_structure_page button,
.pkp_structure_page input,
.pkp_structure_page select,
.pkp_structure_page textarea {
  font-family: var(--mr-serif);
  color: var(--mr-ink);
}

.pkp_structure_page {
  font-size: 1.1765rem;   /* 20px body */
  line-height: 1.6;
}

.pkp_structure_content,
.pkp_structure_main,
.pkp_structure_footer_wrapper {
  background: transparent;
}

/* ---------- Single column (no sidebar) ----------
   With the sidebar gone, header, body, and footer share one
   centered measure on desktop, and text lines up under the logo.
   Phones keep the theme's own layout. */

@media (min-width: 992px) {
  :root {
    --mr-measure: 46rem;
  }
  .pkp_head_wrapper,
  .pkp_structure_content,
  .pkp_structure_footer {
    width: auto;
    max-width: var(--mr-measure);
    margin-left: auto;
    margin-right: auto;
  }
  /* user menu (login/account): right edge of the column, not the window */
  .pkp_navigation_user_wrapper {
    left: 0;
    right: 0;
    transform: none;
    width: auto;
    padding-left: 0;
    padding-right: 0;
  }
  .pkp_navigation_user {
    width: auto;
  }
  .pkp_structure_main {
    float: none;
    width: auto;
    margin: 0;
    padding: 0 0 6rem;
  }
  .pkp_footer_content,
  .pkp_brand_footer {
    padding-left: 0;
    padding-right: 0;
  }
  /* article page: theme sizes the two columns in px and bleeds the row
     into the main column's (now removed) padding */
  .obj_article_details > .row {
    margin-left: 0;
    margin-right: 0;
  }
  .obj_article_details .main_entry {
    width: calc(100% - 300px);
  }
  .obj_article_details .main_entry .item {
    padding-left: 0;
  }
}

/* drop the theme's vertical column rules */
.pkp_structure_main::before,
.pkp_structure_main::after {
  display: none;
}

a {
  color: var(--mr-accent);
  text-decoration-thickness: 1px;
  text-underline-offset: 0.15em;
}
a:hover,
a:focus {
  color: var(--mr-accent-deep);
}

h1, h2, h3, h4,
.pkp_structure_page h1,
.pkp_structure_page h2,
.pkp_structure_page h3,
.pkp_structure_page h4,
.pkp_structure_page h5,
.pkp_structure_page h6,
.pkp_structure_page .title,
.pkp_structure_page .page_title,
.pkp_structure_page .subtitle {
  font-family: var(--mr-serif);
  font-weight: 700;
  color: var(--mr-ink);
}

/* page titles: small caps like galley section heads */
.page > h1,
.page_issue_archive > h1,
.current_issue > h2,
.cmp_breadcrumbs + h1 {
  font-family: var(--mr-sc);
  font-weight: 400;
  font-size: 1.6rem;
  letter-spacing: 0.06em;
  text-transform: lowercase;
}

.cmp_breadcrumbs,
.cmp_breadcrumbs a {
  font-family: var(--mr-sc);
  letter-spacing: 0.04em;
  color: var(--mr-muted);
}

/* ---------- Header: logo on the cover's sage, no navy bar ---------- */

.pkp_structure_head {
  position: relative;
  background: var(--mr-sage);
  border-bottom: 0;
}

/* a strip of the cover's red and slate blocks along the bottom */
.pkp_structure_head::after {
  content: "";
  display: block;
  height: 6px;
  background: linear-gradient(to right,
    var(--mr-accent) 0 14%,
    var(--mr-teal) 14% 31%,
    var(--mr-accent-deep) 31% 37%,
    var(--mr-teal) 37% 100%);
}

.pkp_head_wrapper {
  padding-top: 1.5rem;
}

.pkp_site_name .is_img img {
  max-height: 120px;
  width: auto;
}

@media (max-width: 991px) {
  .pkp_head_wrapper {
    padding-top: 0;
  }
  .pkp_site_name .is_img img {
    max-height: 44px;
  }
}

.pkp_site_name > a,
.pkp_site_name_wrapper {
  background: transparent;
}

/* user nav (Register / Login) */
.pkp_navigation_user_wrapper {
  background: transparent;
}
.pkp_navigation_user > li > a,
.pkp_navigation_user_wrapper a {
  color: var(--mr-muted);
  font-family: var(--mr-sc);
  letter-spacing: 0.05em;
  text-transform: lowercase;
}

/* primary nav: small caps, ink */
.pkp_navigation_primary_row {
  background: transparent;
  border-top: 1px solid var(--mr-teal);
}
.pkp_navigation_primary > li > a,
.pkp_navigation_search_wrapper a {
  color: var(--mr-ink);
  font-family: var(--mr-sc);
  font-size: 1.05rem;
  letter-spacing: 0.08em;
  text-transform: lowercase;
}
.pkp_navigation_primary > li > a:hover,
.pkp_navigation_primary > li > a:focus,
.pkp_navigation_search_wrapper a:hover {
  color: var(--mr-accent);
  border-color: var(--mr-accent);
}

.pkp_navigation_primary .dropdown-menu {
  background: var(--mr-paper);
  border: 1px solid var(--mr-rule);
  box-shadow: none;
}
.pkp_navigation_primary .dropdown-menu a {
  color: var(--mr-ink);
  font-family: var(--mr-serif);
}
.pkp_navigation_primary .dropdown-menu a:hover {
  color: var(--mr-accent);
  border-color: var(--mr-accent);
}

/* the theme paints the nav block in baseColour */
.pkp_site_nav_menu {
  background: var(--mr-sage);
}

/* mobile menu toggle */
.pkp_site_nav_toggle {
  background: var(--mr-ink);
}

/* ---------- Homepage intro (journal summary as a lede) ---------- */

.page_index_journal .homepage_about {
  margin: 3rem 0 4rem;
  padding: 0;
}

/* minimal homepage: the lede only; the current issue is a menu click away
   (OJS has no setting for this) */
.page_index_journal .current_issue {
  display: none;
}
.page_index_journal .homepage_about h2 {
  margin: 0 0 0.75rem;
  font-family: var(--mr-sc);
  font-weight: 400;
  font-size: 1rem;
  letter-spacing: 0.1em;
  text-transform: lowercase;
  color: var(--mr-muted);
}
.page_index_journal .homepage_about p {
  margin: 0;
  font-size: 1.4rem;
  line-height: 1.5;
  color: var(--mr-ink);
}
.page_index_journal .homepage_about p strong {
  font-weight: 400; /* italic title is emphasis enough at this size */
}
.page_index_journal .homepage_about::after {
  content: "Published since 2007  ·  ISSN 1936-4679 (print)  ·  1936-4687 (online)";
  display: block;
  margin-top: 1rem;
  font-family: var(--mr-sc);
  font-size: 0.95rem;
  letter-spacing: 0.05em;
  color: var(--mr-muted);
  white-space: pre-wrap;
}
@media (max-width: 480px) {
  .page_index_journal .homepage_about p {
    font-size: 1.2rem;
  }
}

/* ---------- Sidebar: quiet, ruled ---------- */

.pkp_structure_sidebar .pkp_block .title {
  font-family: var(--mr-sc);
  font-weight: 400;
  font-size: 1.05rem;
  letter-spacing: 0.08em;
  text-transform: lowercase;
  color: var(--mr-ink);
  border-bottom: 1px solid var(--mr-rule);
  padding-bottom: 0.35rem;
}
.pkp_structure_sidebar .pkp_block {
  font-size: 1rem;
}

/* ---------- Issue + article pages ---------- */

.obj_issue_toc .heading .published,
.obj_issue_toc .heading .pub_id,
.obj_article_summary .meta,
.obj_article_summary .pages,
.obj_article_details .item .label,
.obj_issue_toc .sections .section > h2,
.obj_issue_toc .sections .section > h3 {
  font-family: var(--mr-sc);
  letter-spacing: 0.05em;
}

.obj_issue_toc .sections .section > h2,
.obj_issue_toc .sections .section > h3 {
  font-weight: 400;
  font-size: 1.15rem;
  text-transform: lowercase;
  color: var(--mr-ink);
  background: none;
  border-bottom: 1px solid var(--mr-teal);
  padding: 0 0 0.35rem;
  margin-left: 0;
}
.obj_issue_toc .sections .section > h2,
.obj_issue_toc .sections .section > h3 {
  display: block;   /* rule runs the full column */
  left: 0;          /* theme nudges the head 15px left */
}
.obj_issue_toc .sections .section > h2::after,
.obj_issue_toc .sections .section > h3::after,
.obj_issue_toc .galleys h2::after,
.obj_issue_toc .sections .section::before {
  display: none; /* theme's half-rule under section heads, and its
                    full-width rule that the head used to mask */
}

.obj_issue_toc .heading .cover img,
.obj_issue_summary .cover img {
  box-shadow: 0 1px 2px rgba(0,0,0,.12), 0 6px 18px rgba(0,0,0,.10);
}

.obj_article_summary > .title {
  font-size: 1.25rem;
}
.obj_article_summary > .title a {
  color: var(--mr-ink);
  font-weight: 700;
}
.obj_article_summary > .title a:hover {
  color: var(--mr-accent);
}
/* authors sit inside .meta (Alegreya SC); the SC italic faces above
   make this a true italic rather than a slanted roman */
.obj_article_summary .authors {
  font-size: 1rem;
  font-style: italic;
  color: var(--mr-muted);
}

/* article page labels (Keywords, Abstract, Published…): the theme sets
   these in Noto Sans with a four-class selector, so outrank it */
.pkp_structure_page .obj_article_details .main_entry .item .label,
.pkp_structure_page .obj_article_details .entry_details .item .label,
.pkp_structure_page .obj_article_details .sub_item .label {
  font-family: var(--mr-sc);
  font-weight: 400;
  font-size: 1rem;
  letter-spacing: 0.06em;
  text-transform: lowercase;
  color: var(--mr-muted);
}

.obj_article_details .page_title {
  font-size: 2rem;
  line-height: 1.2;
}

/* galley buttons (PDF / HTML): outlined ink, not theme blue */
.obj_galley_link,
.cmp_button,
.cmp_form .buttons button {
  font-family: var(--mr-sc);
  letter-spacing: 0.05em;
  color: var(--mr-ink);
  background: transparent;
  border: 1px solid var(--mr-ink);
  border-radius: 2px;
  box-shadow: none;
}
.obj_galley_link:hover,
.obj_galley_link:focus,
.cmp_button:hover,
.cmp_form .buttons button:hover {
  color: var(--mr-paper);
  background: var(--mr-ink);
  border-color: var(--mr-ink);
}
.obj_galley_link.restricted {
  border-color: var(--mr-muted);
}

/* ---------- Archives: cover grid ---------- */

.page_issue_archive .issues_archive {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
  gap: 2.25rem 1.75rem;
  margin: 1.5rem 0 2rem;
  padding: 0;
  list-style: none;
}

.page_issue_archive .issues_archive > li {
  margin: 0;
  padding: 0;
  border: 0;
}

.page_issue_archive .obj_issue_summary {
  display: flex;
  flex-direction: column;
  height: 100%;
}
.page_issue_archive .obj_issue_summary::after { display: none; }

.page_issue_archive .obj_issue_summary .cover {
  float: none;
  display: block;
  width: 100%;
  max-width: none;
  margin: 0 0 0.75rem;
  aspect-ratio: 2 / 3;
  background: var(--mr-sage);
  overflow: hidden;
  transition: transform .15s ease;
}
.page_issue_archive .obj_issue_summary .cover:hover,
.page_issue_archive .obj_issue_summary .cover:focus {
  transform: translateY(-3px);
}
.page_issue_archive .obj_issue_summary .cover img {
  display: block;
  width: 100%;
  height: 100%;
  max-width: none;
  max-height: none;
  object-fit: cover;
}

.page_issue_archive .obj_issue_summary h2 {
  margin: 0;
  font-size: 1rem;
  line-height: 1.3;
  font-weight: 700;
}
.page_issue_archive .obj_issue_summary h2 .title {
  color: var(--mr-ink);
  text-decoration: none;
}
.page_issue_archive .obj_issue_summary h2 .title:hover {
  color: var(--mr-accent);
}
.page_issue_archive .obj_issue_summary .series {
  margin-top: 0.2rem;
  font-family: var(--mr-sc);
  font-weight: 400;
  font-size: 0.95rem;
  letter-spacing: 0.04em;
  color: var(--mr-muted);
}
/* issue with no title: the series line becomes the title */
.page_issue_archive .obj_issue_summary h2 > .title + .series:only-child,
.page_issue_archive .obj_issue_summary h2 > .series:first-child {
  color: var(--mr-ink);
}

/* long issue descriptions belong on the issue page, not the grid */
.page_issue_archive .obj_issue_summary .description {
  display: none;
}

.page_issue_archive .cmp_pagination {
  font-family: var(--mr-sc);
  letter-spacing: 0.04em;
}

@media (max-width: 480px) {
  .page_issue_archive .issues_archive {
    grid-template-columns: repeat(2, 1fr);
    gap: 1.75rem 1rem;
  }
}

/* ---------- Homepage: support the Society ----------
   Content lives in OJS Settings → Website → Appearance → Setup →
   Additional Content (copy kept in site/home-support.html). */

.pkp_page_index .additional_content {
  margin: 0 0 4rem;     /* theme: negative margins, padding, gray top rule */
  padding: 0;
  border-top: 0;
}
.mr-support {
  padding: 1.75rem 2rem 2rem;
  background: var(--mr-sage);
  border-left: 6px solid var(--mr-accent);
}
.mr-support h2 {
  margin: 0 0 0.75rem;
  font-family: var(--mr-sc);
  font-weight: 400;
  font-size: 1.15rem;
  letter-spacing: 0.08em;
  text-transform: lowercase;
}
.mr-support p {
  margin: 0 0 1.25rem;
}
.mr-support p:last-child {
  margin-bottom: 0;
}
.pkp_structure_page .mr-support .mr-support-button {
  display: inline-block;
  padding: 0.45rem 1.1rem;
  font-family: var(--mr-sc);
  letter-spacing: 0.06em;
  text-transform: lowercase;
  text-decoration: none;
  color: var(--mr-paper);
  background: var(--mr-accent);
  border-radius: 2px;
}
.pkp_structure_page .mr-support .mr-support-button:hover,
.pkp_structure_page .mr-support .mr-support-button:focus {
  background: var(--mr-accent-deep);
  color: var(--mr-paper);
}
@media (max-width: 480px) {
  .mr-support {
    padding: 1.25rem 1.25rem 1.5rem;
  }
}

/* ---------- Galley viewer bar (HTML/PDF view pages) ---------- */

.header_view {
  background: var(--mr-sage);
  border-bottom: 1px solid var(--mr-teal);
}
.header_view .return {
  background: var(--mr-paper);
  color: var(--mr-accent);
  border-right: 1px solid var(--mr-teal);
}
.header_view .return:hover,
.header_view .return:focus {
  background: var(--mr-accent);
  color: var(--mr-paper);
}
.header_view .title {
  color: var(--mr-ink);
  font-family: var(--mr-sc);
  letter-spacing: 0.05em;
}
.header_view .title:hover,
.header_view .title:focus {
  color: var(--mr-accent);
  background: transparent;
}

/* ---------- Footer ---------- */

.pkp_structure_footer_wrapper {
  border-top: 1px solid var(--mr-teal);
  background: var(--mr-sage);
}
.pkp_structure_footer {
  font-size: 1rem;
  color: var(--mr-muted);
}
.pkp_brand_footer a {
  width: auto;          /* theme fixes the link at 150px */
}
.pkp_brand_footer img {
  width: 72px;
  height: auto;
  opacity: 0.45;
  filter: grayscale(1);
}

.mr-footer p {
  margin: 0 0 0.35rem;
}
.mr-footer a {
  color: var(--mr-ink);
}
.mr-footer a:hover {
  color: var(--mr-accent);
}
.mr-footer .mr-footer-pub {
  font-family: var(--mr-sc);
  font-size: 1.1rem;
  letter-spacing: 0.06em;
  color: var(--mr-ink);
  margin-bottom: 0.6rem;
}
.mr-footer .mr-footer-pub a {
  text-decoration: none;
}
.mr-footer .mr-footer-issn {
  font-family: var(--mr-sc);
  letter-spacing: 0.04em;
}
