/* KEMI Journal — brand accents for OJS default theme */

.pkp_site_name .is_img {
  background-color: #ffffff;
  padding: 8px 16px;
  border-radius: 4px;
  display: inline-block;
}

.pkp_site_name .is_text,
.pkp_site_name > a.is_text {
  color: #ffffff;
}

/* Footer brand links */
.kemi-footer-links {
  margin-bottom: 1.5rem;
}

.kemi-footer-links strong {
  display: block;
  margin-bottom: 0.5rem;
  color: #0068a7;
  font-size: 1rem;
}

.kemi-footer-links ul {
  list-style: none;
  padding: 0;
  margin: 0 0 0.75rem 0;
  display: flex;
  flex-wrap: wrap;
  gap: 1.25rem;
}

.kemi-footer-links ul a,
.kemi-footer-links p a {
  color: #0068a7;
  text-decoration: none;
}

.kemi-footer-links ul a:hover,
.kemi-footer-links p a:hover {
  text-decoration: underline;
}

.kemi-footer-links p {
  margin: 0;
  font-size: 0.875rem;
}

.kemi-footer-copyright {
  margin-top: 0.75rem;
  color: #555;
}

/* Hide the default OJS/PKP "powered by" branding */
.pkp_brand_footer {
  display: none;
}

/* "Call for Papers" nav link - pulsing red badge to draw attention.
   Pulse rate is well under the WCAG 3-flashes/second seizure-risk threshold,
   and prefers-reduced-motion turns it into a plain static badge.
   Floated to the right of the nav bar - the left end blends in with the
   other plain-text links, the right end is where the eye actually lands. */
#navigationPrimary li:has(> a[href*="announcement/view/2"]) {
  float: right;
  margin-left: 1rem;
}

#navigationPrimary a[href*="announcement/view/2"] {
  color: #ffffff !important;
  background-color: #dc2626;
  border-radius: 999px;
  padding: 6px 16px !important;
  font-weight: 700;
  animation: kjelmCfpPulse 1.6s ease-in-out infinite;
}

#navigationPrimary a[href*="announcement/view/2"]:hover {
  background-color: #b91c1c;
}

@keyframes kjelmCfpPulse {
  0%, 100% {
    background-color: #dc2626;
    box-shadow: 0 0 0 0 rgba(220, 38, 38, 0.6);
  }
  50% {
    background-color: #ef4444;
    box-shadow: 0 0 0 6px rgba(220, 38, 38, 0);
  }
}

@media (prefers-reduced-motion: reduce) {
  #navigationPrimary a[href*="announcement/view/2"] {
    animation: none;
  }
}

/* "Make a Submission" nav link - a permanent, always-visible call to action
   (unlike the CFP badge, this isn't time-limited) so it reads as a solid
   button rather than competing for attention with the red pulse.
   href$= (ends-with) so it matches only "/submission" and not "about/submissions".
   White-on-blue (matching .kemi_submission_cta_button below), NOT blue-on-blue -
   the original #0068a7 background sat directly on the #0068a7 header, so the
   "button" had zero contrast against its own background and just read as
   plain bold text. */
#navigationPrimary a[href$="/submission"] {
  color: #0068a7 !important;
  background-color: #ffffff;
  border-radius: 999px;
  padding: 6px 16px !important;
  font-weight: 700;
}

#navigationPrimary a[href$="/submission"]:hover {
  background-color: #dbeafe;
}

/* Homepage "Ready to publish?" submission banner - added to
   templates/frontend/pages/indexJournal.tpl, right at the top of the page. */
.kemi_submission_cta {
  background: linear-gradient(135deg, #0068a7, #004b78);
  border-radius: 10px;
  margin: 1rem 0 2rem;
  padding: 1.75rem 2rem;
}

.kemi_submission_cta_inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.5rem;
  flex-wrap: wrap;
}

.kemi_submission_cta_text h2 {
  color: #ffffff;
  margin: 0 0 0.35rem;
  font-size: 1.4rem;
}

.kemi_submission_cta_text p {
  color: #dbeafe;
  margin: 0;
  max-width: 46em;
}

.kemi_submission_cta_button {
  flex-shrink: 0;
  background-color: #ffffff;
  color: #0068a7 !important;
  font-weight: 700;
  padding: 0.75rem 1.5rem;
  border-radius: 999px;
  text-decoration: none;
  white-space: nowrap;
}

.kemi_submission_cta_button:hover {
  background-color: #dbeafe;
}

/* Tables inside announcement/article rich-text bodies - the sanitizer allows
   the tags but not a style attribute, so style plain tables here instead. */
.obj_announcement_full .description table,
.page_announcement table {
  width: 100%;
  border-collapse: collapse;
  margin: 0.5rem 0 1.25rem;
}

.obj_announcement_full .description table th,
.obj_announcement_full .description table td,
.page_announcement table th,
.page_announcement table td {
  padding: 8px 12px;
  border: 1px solid #dbe3ea;
  text-align: left;
}

.obj_announcement_full .description table th,
.page_announcement table th {
  background-color: #0068a7;
  color: #ffffff;
}

.obj_announcement_full .description table tr:nth-child(even) td,
.page_announcement table tr:nth-child(even) td {
  background-color: #f3f7fa;
}

/* Typography pass for long-form content pages (About, Submissions, Editorial
   Board, and every custom NMI_TYPE_CUSTOM page - all render inside a plain
   <div class="page">). Previously h2/h3 were barely distinguishable from body
   text and paragraphs ran edge-to-edge with tight line-height, so a page like
   About read as one dense, undifferentiated block. This just adds real visual
   hierarchy - it doesn't change layout/structure. */
.page h1 {
  border-bottom: 3px solid #0068a7;
  padding-bottom: 0.6rem;
  margin-bottom: 1.5rem;
}

.page h2 {
  color: #0068a7;
  font-size: 1.3rem;
  margin: 2rem 0 0.85rem;
  padding-top: 0.25rem;
  border-top: 1px solid #e2e8f0;
}

.page h2:first-of-type {
  border-top: none;
  margin-top: 1.25rem;
}

.page h3 {
  color: #14415e;
  font-size: 1.08rem;
  margin: 1.5rem 0 0.6rem;
}

.page p {
  line-height: 1.65;
  margin: 0 0 1.1rem;
  max-width: 62em;
}

.page ul li,
.page ol li {
  line-height: 1.6;
  margin-bottom: 0.4rem;
}

/* The homepage "Call for Papers" announcement teaser embeds the full A4
   promotional flyer at large size - every word on the poster itself (dates,
   fee, focus areas) is illegible at that width, and it dwarfs everything
   else in the first screen of the homepage. Cap it to a proper thumbnail;
   the readable version is the actual summary text next to it, and the full
   flyer is still one click away via "Read More". */
.obj_announcement_summary_has_image {
  grid-template-columns: 180px auto !important;
  align-items: start;
}

.obj_announcement_summary_image {
  max-width: 180px;
  width: 100%;
  height: auto;
  border: 1px solid #dbe3ea;
  border-radius: 4px;
  box-shadow: 0 1px 4px rgba(0, 0, 0, 0.08);
}
