/* =============================================================================
 * DSpace tenant branding stylesheet
 * -----------------------------------------------------------------------------
 * Generated per instance by scripts/onboard-tenant.sh from this template
 * (scripts/templates/branding.css.tpl). Served from
 * /assets/branding/branding.css and injected into <head> through the theme's
 * headTags in ui-config.yml.
 *
 * Selectors target the stock DSpace 9 "dspace" theme and were taken from the
 * dspace-angular source:
 *   header .navbar-brand img  -> src/app/header/header.component.html
 *   .home-news-content        -> src/app/home-page/home-news/home-news.component.html
 *   .btn-*                    -> Bootstrap 5 CSS custom properties
 *
 * Everything here is plain CSS — edit branding/<slug>/branding.css and re-run
 * onboard-tenant.sh (same --slug) to push changes out to the running pods.
 * ===========================================================================*/

:root {
  /* Instance colours */
  --dspace-brand-primary: #14532d;
  --dspace-brand-accent: #14532d;

  /* Bootstrap colour system (DSpace maps Bootstrap variables to CSS custom
     properties on :root — see src/styles/_bootstrap_variables_mapping.scss) */
  --bs-primary: #14532d;
  --bs-link-color: #14532d;
  --bs-link-hover-color: color-mix(in srgb, #14532d 75%, black);

  /* Body font (font_body spec key); Bootstrap reads --bs-body-font-family
     from :root and our late-loaded stylesheet wins the cascade. */

  --bs-body-font-family: 'Open Sans', sans-serif;
  --brand-font-heading: 'Merriweather', sans-serif;
  /* DSpace theme palette hooks (header/footer/navbar/news colours). Every
     --ds-* variable is defined on :root by dspace-theme.css, which loads
     before this file — so re-declaring them here wins. */

  --ds-header-bg: #14532d;
  --ds-navbar-dropdown-bg: #14532d;
  --ds-navbar-link-color: #ffffff;
  --ds-navbar-link-color-hover: color-mix(in srgb, #ffffff 75%, black);
  --ds-header-icon-color: #ffffff;
  --ds-header-icon-color-hover: color-mix(in srgb, #ffffff 75%, black);
  --ds-footer-bg: #14532d;
  --ds-top-footer-bg: #14532d;
}

/* ---------------------------------------------------------------- buttons --
   Bootstrap writes the real button colours as custom properties *on the
   button class*, so the same properties are re-declared here. `!important`
   guarantees our stylesheet wins regardless of load order. */
.btn-primary,
.btn-check:checked + .btn-primary {
  --bs-btn-bg: #14532d !important;
  --bs-btn-border-color: #14532d !important;
  --bs-btn-hover-bg: color-mix(in srgb, #14532d 82%, black) !important;
  --bs-btn-hover-border-color: color-mix(in srgb, #14532d 82%, black) !important;
  --bs-btn-active-bg: color-mix(in srgb, #14532d 70%, black) !important;
  --bs-btn-active-border-color: color-mix(in srgb, #14532d 70%, black) !important;
  --bs-btn-disabled-bg: color-mix(in srgb, #14532d 60%, white) !important;
  --bs-btn-disabled-border-color: color-mix(in srgb, #14532d 60%, white) !important;
}


.btn-primary,
.btn-check:checked + .btn-primary {
  --bs-btn-color: #ffffff !important;
  --bs-btn-hover-color: #ffffff !important;
  --bs-btn-active-color: #ffffff !important;
}
.btn-outline-primary {
  color: #14532d !important;
  border-color: #14532d !important;
}

.btn-outline-primary:hover,
.btn-outline-primary:focus-visible {
  background-color: #14532d !important;
  border-color: #14532d !important;
  color: #ffffff !important;
}

/* Links and focus rings inside content areas */
main a:not(.btn):not(.page-link):not(.dropdown-item) {
  color: #14532d;
}

main a:not(.btn):not(.page-link):not(.dropdown-item):hover {
  color: color-mix(in srgb, #14532d 75%, black);
}

:focus-visible {
  outline-color: #14532d;
}


header .navbar-brand { display: flex; flex-direction: column; align-items: flex-start; line-height: 1.15; }
header .navbar-brand::before {
  content: "Debre Markos University Institutional Repository";
  order: 2;
  font-size: 1.05rem;
  font-weight: 700;
  color: #ffffff;
}
header .navbar-brand::after {
  content: "Open Access to Research Output";
  order: 3;
  font-size: 0.72rem;
  font-weight: 500;
  color: color-mix(in srgb, #ffffff 80%, transparent);
}
/* Home page banner — replaces DSpace's stock marketing block */
.home-news-content {
  padding-top: 2.75rem;
  padding-bottom: 2.75rem;
  background-color: color-mix(in srgb, #14532d 12%, #ffffff);
  border-bottom: 3px solid #14532d;
}

.home-news-content h1.display-2 { font-size: 0; }
.home-news-content h1.display-2::after {
  content: "Debre Markos University Institutional Repository";
  font-size: clamp(1.7rem, 3.5vw, 2.75rem);
  font-weight: 700;
  line-height: 1.15;
}
.home-news-content p.lead { font-size: 0; }
.home-news-content p.lead::after {
  content: "Open Access to Research Output";
  font-size: 1.1rem;
  line-height: 1.5;
}
/* Hide the stock DSpace marketing bullets/links in the banner */
.home-news-content ul,
.home-news-content p:not(.lead) { display: none !important; }

body, button, input, select, textarea, .btn {
  font-family: 'Open Sans', sans-serif;
}
h1, h2, h3, h4, h5, h6,
.display-1, .display-2, .display-3, .display-4, .display-5, .display-6 {
  font-family: var(--brand-font-heading);
}

.bottom-footer, .bottom-footer .text-white,
.bottom-footer a, .bottom-footer button {
  color: #ffffff !important;
}
.bottom-footer .content-container { display: none !important; }
.bottom-footer::after {
  content: "© 2026 Debre Markos University";
  flex-basis: 100%;
  width: 100%;
  text-align: center;
  font-size: 0.8rem;
  padding-top: 0.15rem;
  opacity: 0.9;
}
