/* Make sure Lato font is loaded */
@font-face {
    font-family: 'Lato';
    src: url('/static/core/fonts/Lato/Lato-Regular.ttf') format('truetype');
    font-weight: 400;
    font-style: normal;
  }
  @font-face {
    font-family: 'Lato';
    src: url('/static/core/fonts/Lato/Lato-Italic.ttf') format('truetype');
    font-weight: 400;
    font-style: italic;
  }
  @font-face {
    font-family: 'Lato';
    src: url('/static/core/fonts/Lato/Lato-Bold.ttf') format('truetype');
    font-weight: 700;
    font-style: normal;
  }
  @font-face {
    font-family: 'Lato';
    src: url('/static/core/fonts/Lato/Lato-BoldItalic.ttf') format('truetype');
    font-weight: 700;
    font-style: italic;
  }
/* Colour Palette */
:root {
  --brand-blue:    #258DCC;
  --brand-green:   #8BBF52;
  --brand-grey:    #595959;
  --brand-orange:  #F08D37;     
  --brand-lightgrey: #fafafa;
  --brand-lightblue: #eef7fc;
}

/****************************/
/* General CSS */
.section-wrapper {
    width: 100%;
    margin-top: 40px;
    margin-bottom: 20px;
}

.section-grey-wrapper{
    padding: 40px 0;
    background-color:var(--brand-lightgrey)
}

.spacer-40{
    padding-top:20px;
    padding-bottom:20px;
}

.section-title{
    letter-spacing: 0.02em;
    margin-bottom: 2.5rem !important;
    color: var(--brand-grey);
    font-weight: 600;
}
.page-title-section {
    background-color: var(--brand-lightblue); 
    padding: 60px 0;
    margin: 20px 0;
}

.page-title {
    font-weight: 700;
    letter-spacing: 0.03em;
    color: var(--brand-blue);
}

.page-subtitle{
    color: var(--brand-grey)
}


/****************************/
/* Top Header */

/* Full-width background container */
.header-container {
  width: 100%;
  background-color: var(--brand-lightgrey);
  padding: 10px 0;
}

/* Inner content max 950px */
.header-content {
  max-width: 950px;
  margin: 0 auto;
  padding: 0 20px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 20px;
  flex-wrap: nowrap;
}

/* Logos section takes ~67% */
.header-logos {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex: 0 0 60%;
  gap: 15px;
}

/* Each logo gets 1/3 of the logos area */
.header-logo {
  flex: 1 1 33.33%;
}

.header-logo img {
  width: 100%;
  height: auto;
  display: block;
  object-fit: contain;
}

/* Text section ~33% */
.header-text {
  flex: 0 0 40%;
  font-size: 12px;
  line-height: 1.5;
  color: #000;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: left;
}

.header-text p {
  margin: 0;
  padding-top: 10px;
}

/* Mobile layout */
@media (max-width: 991px) {
  .header-content {
    flex-direction: column;
    align-items: center;
    text-align: center;
  }

  .header-logos {
    flex: 1 1 100%;
    flex-wrap: nowrap;
    overflow-x: auto;
    justify-content: center;
    gap: 15px;
    margin-bottom: 10px;
  }

  .header-logo {
    flex: 0 0 auto;
    max-width: 30%;
  }

  .header-text {
    flex: 1 1 100%;
    padding: 0 15px;
    margin-bottom:15px;
  }

  .header-text p {
    padding-top: 0;
    font-size: 14px;
    text-align:center;
  }
}


/****************************/
/* Navbar */

.navbar-brand img{
   height: 100px;  
   margin-top:-40px 
}

.custom-navbar .main-header-logo {
    height: 100px; /*Change here for main image nav bar size */
    width: auto;
    display: block;
    margin-top: 0px;
}

/* Main navbar container */
.custom-navbar {
    min-height: 100px;
    display: flex;
    align-items: center;
    padding: 0 20px;
    max-width: 1320px;
    margin-left: auto;
    margin-right: auto;
    background: white;
}

/* Navbar content wrapper */
.navbar-collapse {
    display: flex;
    align-items: center;
    width: 100%;
}

/* Collapsed on mobile */
.navbar-collapse:not(.show) {
    display: none;
}

/* Navigation list */
.navbar-nav {
    display: flex;
    gap: 40px;
    padding: 0;
    margin: 0;
    list-style: none;
    align-items: center;
}

/* List item wrapper */
.nav-item {
    position: relative;
    flex: 0 1 auto;
}

/* Top-level nav links */
.custom-nav-link {
    color: var(--brand-blue) !important;
    font-family: Lato, sans-serif;
    font-size: 22px;
    font-weight: 700;
    text-decoration: underline;
    text-underline-offset: 15px;
    text-decoration-thickness: 2px;
    line-height: 140%;
    white-space: nowrap;
    display: block;
    padding: 0.5rem 1rem;
    transition: color 0.3s;
}

/* Hover and active states */
.custom-nav-link:hover,
.custom-nav-link.active,
.nav-item.active > .custom-nav-link {
    color: var(--brand-green) !important;
}

/* ▼ indicator for dropdowns */
.nav-item.has-dropdown > .custom-nav-link::after {
    content: " ▼";
    font-size: 0.6em;
    margin-left: 6px;
    vertical-align: middle;
    border: none;
}

/* Dropdown menu container */
.dropdown-menu {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    background-color: #f8f9fa;
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.15);
    border: none;
    border-radius: 0.75rem;
    padding: 0.75rem 0;
    min-width: 220px;
    margin-top: 10px;
    z-index: 1000;
    flex-direction: column;
}

/* Dropdown items */
.dropdown-item {
    color: #175979;
    padding: 0.75rem 1.5rem;
    font-size: 1rem;
    white-space: nowrap;
    background: none;
    border: none;
    text-decoration: none;
    transition: background-color 0.2s, color 0.2s;
}

/* Dropdown hover/focus */
.dropdown-item:hover,
.dropdown-item:focus {
    background-color: #e9ecef !important;
    color: var(--brand-blue);
}

.dropdown-item.active{
    background: none;
    color: var(--brand-green);
}

/* Dropdown open on hover — only on desktop */
@media (min-width: 992px) {
  .nav-item.dropdown:hover > .dropdown-menu {
    display: flex !important;
    margin-top: 0;
  }

}

/* Navbar gap smaller in smaller screens */
@media (max-width: 1100px){
    .navbar-nav{ 
        gap:20px;
    }
}

/* Nabvar on mobile */
@media (max-width: 991px){
  .navbar-collapse{
    width: 100%;
    display:block;
  }
  .navbar-nav{
    gap: 20px;
    padding:0;
    margin: 20px 0;
    align-items:flex-start;
    background-color: var(--brand-lightgrey);
  } 

  .navbar-nav .nav-item + .nav-item {
    border-top: 1px solid #fff; /* Divider line */
  }  
  .custom-nav-link{
    text-decoration: none;
  }
  .dropdown-menu {
    background-color: var(--brand-lightgrey);
    box-shadow: none;
    border: none;
    border-radius: 0;
    padding: 0 0;
  }

  .dropdown-item {
    font-weight: 500;
  }
}

/* Mobile-specific toggler styles */
.navbar-toggler {
    border: none;
}


/****************************/
/* Hero Section */

.hero-banner {
    text-align: center;
    padding: 20px;
    margin: 10px auto;
    max-width: 1200px;
}

.hero-image-section {
    position: relative;
    overflow: hidden;
    box-sizing: border-box;
    max-width: 1200px;
    margin: 0 auto;
}


.hero-banner h4, .hero-banner h5{
    color:var(--brand-grey);
}

.hero-banner p, .hero-banner h3, .hero-banner h4, .hero-banner h5 {
    margin-left: auto;
    margin-right: auto;
    letter-spacing: 0.03em;
    padding-bottom: 10px;
}


.hero-image {
  width: 100%;
  height: auto;
  display: block;
}


.hero-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.4); /* Semi-transparent overlay */
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 2rem;
}

.hero-overlay p {
    color: white;
    font-size: 1.5rem;
    text-align: center;
    max-width: 800px;
    margin: 0;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.5);
}



/****************************/
/* News articles boxes */

.news-section-wrapper {
    background: #F2F2F2;
}

.news_article_cards {
    background: #F2F2F2;
    padding-top: 20px;
    padding-bottom: 20px;
}

.news-card {
  width: 100%; /* force full column width */
  border-radius: 1.2rem;
  transition: transform 0.2s ease-in-out;
  display: flex;
  flex-direction: column;
}

.news-card:hover {
    transform: translateY(-5px);
}

.news-card-img-wrapper {
  height: 220px;
  width: 100%;
  background-color: #dcdcdc;
  border-top-left-radius: 1.2rem;
  border-top-right-radius: 1.2rem;
  overflow: hidden;
  display: flex; /* change from block to flex */
  align-items: center;
  justify-content: center;
}

.news-card-img-wrapper img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.news-card-placeholder {
    width: 100%;
    height: 100%;
    background: #e6e6e6 center center no-repeat;
    background-size: 40px 40px;
}
.news-card-title {
    color: var(--brand-grey);
    font-weight: 700;
}

.news-card-tag {
    color: var(--brand-green);
    border:1px solid var(--brand-green);
}

.news-card-btn {
    border-radius: 2rem;
}

/* News Article Single */
.news-body{
    padding: 20px 0;
    text-align: justify;
}

.article-img-wrapper{
    max-width: 100%;
    width:100%;
}



/****************************
/* Project Partners in Home Page */

.partners-container {
  padding: 20px 0;
}

.partners-container .row {
  max-width: 1320px;
  margin: 0 auto;
  padding: 0 20px;
}

/* Column inner box to align logo to bottom */
.partner-img-wrapper {
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  height: 100%;               /* Fill height of col */
}

/* Logo image */
.partner-logo {
  max-width: 200px;
  width: 100%;
  height: auto;
  display: block;
}




/****************************/
/* Gallery Page Specific Styling */


.gallery-card {
    border-radius: 0.75rem;
    overflow: hidden;
    transition: transform 0.2s ease-in-out, box-shadow 0.2s ease-in-out;
   align-items: center;
}

.gallery-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 30px rgba(37, 141, 204, 0.18);
}

.gallery-img-wrapper {
    width: 400px;
    height: 250px;
    background-color: #f0f0f0;
    overflow: hidden;
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
}

.gallery-img-wrapper img {
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
    display: block;
    transition: transform 0.3s ease-in-out;
}

.gallery-card:hover .gallery-img-wrapper img {
    transform: scale(1.05);
}

.gallery-caption {
    font-size: 0.95rem;
    color: var(--brand-grey);
    margin-bottom: 0;
}

.gallery-card .card-body {
    padding: 1rem;
}

.video-play-icon {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 60px;
    height: 60px;
    background-color: rgba(0, 0, 0, 0.6);
    border-radius: 50%;
    color: white;
    font-size: 28px;
    line-height: 60px;
    text-align: center;
    z-index: 2;
    pointer-events: none;
}

@media (max-width: 991px) {
  .col{
    justify-content: center;
  }
}

/* Ensure images fit within their grid cells */
.row.row-cols-lg-3 .col {
    max-width: 100%; /* Ensure columns don't overflow */
}

.card:hover {
    transform: translateY(-8px) scale(1.03);
    box-shadow: 0 8px 32px rgba(37, 141, 204, 0.15);
}


/****************************/
/* Team section (Also used for Affiliates/Project partners */

.team-grid {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 2rem;
}

.team-card {
    background: #fff;
    border-radius: 12px;
    box-shadow: 0 2px 12px rgba(0,0,0,0.07);
    padding: 2rem 1.5rem;
    width: 370px;
    display: flex;
    flex-direction: column;
    align-items: center;
    transition: box-shadow 0.2s;
}
.team-card:hover {
    box-shadow: 0 4px 24px rgba(37,141,204,0.15);
}
.team-photo {
    border-radius: 20%;
    margin-bottom: 1rem;
    width: 120px;
    height: 120px;
    object-fit: cover;
}
.team-name {
    font-size: 1.4rem;
    font-weight: 700;
    color: var(--brand-blue);
    margin: 0.5rem 0 0.7rem 0;
}
.team-role {
    font-size: 1.1rem;
    color: #175979;
    margin-bottom: 0.5rem;
    font-weight: 600;
}
.team-affiliation {
    font-size: 1.1rem;
    color: var(--brand-grey);
    margin-bottom: 0.9rem;
    font-weight: 600;
}
.team-bio {
    font-size: 0.98rem;
    color: var(--brand-grey);
    margin: 0.5rem 1rem 0;
}

.team-contact-details{
    color: var(--brand-grey);
    font-weight: 600;
}
.team-contact-detail {
    color: var(--brand-grey);
    text-decoration: underline;
    font-weight: 600;
}
.team-contact-detail:hover, .team-contact-details:hover {
    color:var(--brand-green)
}

.partner-card-logo {
    margin-bottom: 1rem;
    max-width: 200px;
    height: auto;
    object-fit: cover;
}

/****************************/
/* Contact Page */
.contact-card:hover{
    transform: none;
}

/****************************/
/*Footer*/
.custom-footer {
    background-image: url('/static/core/images/footerimage.png');
    background-repeat: no-repeat;
    background-size: cover;   
    background-position: center bottom;
    min-height: 200px;       
    width: 100%;
    padding-top: 40px;
    padding-bottom: 40px;
    background-color: #175979;
    color: #fff; 
}

.footer.text {
    color: white;
}


/****************************/
/* General Styling */


body {
    background: white;
}

.content-bg  {
    background: white;
    padding: 1em;
    border-radius: 0.5em;
}

th.orderable {
    font-size: 0.9em;
    text-transform: uppercase;
}

th > a {
    color: rgba(179,158,106, 1);
    text-decoration: none;
}

.box-card {
    box-shadow: rgba(149, 157, 165, 0.2) 0px 8px 24px;
    padding: 1em;
    border-radius: 0.5em;
    background: rgba(179, 158, 106, 0.2);
}

.box-card-alt {
    box-shadow: rgba(149, 157, 165, 0.2) 0px 8px 24px;
    padding: 1em;
    border-radius: 0.5em;
    border: 1px solid rgba(179, 158, 106, 0.2);
}


/* Buttons */
.btn-blue{
    background: var(--brand-blue);
    color: white;
}
.btn-blue:hover {
    background: var(--brand-green);
    color:white;
}

.btn-blue-outline {
    background: white;
    color: var(--brand-blue);
    border:1px solid var(--brand-blue);
}

.btn-blue-outline:hover {
    background: white;
    color: var(--brand-green);
    border:1px solid var(--brand-green);
}

.btn-green {
    background: var(--brand-green);
    color: white;
}

.btn-green:hover {
    background: var(--brand-blue);
    color: white;
}

.btn-green-outline {
    background: white;
    color: var(--brand-green);
    border:1px solid var(--brand-green);
}

.btn-green-outline:hover {
    background:var(--brand-green);
    color:white;
}







td > a {
    text-decoration: none;
}



/* like the logo, but less saturation and more lightness hsl=78 40% 60%*/
.bg-lightgrey{
    background-color: var(--brand-lightgrey);
}

.bg-box-shadow {
    box-shadow: rgba(149, 157, 165, 0.2) 0px 8px 24px;
    padding: 3em 4em;
    width: 35vw;
}

.first-row {
    margin-top: -3em;
}

.info-padding {
    padding: 3em 8em 5em;
}


.search-padding {
    padding: 1em
}

#statistics-block .table-container {
    max-height: 300px;
    overflow: auto;
}

#echart-main {
    height: 600px;
}

#echart-main-fs {
    height: 600px;
    width: 1000px;
}

.doc-markdown img {
    max-width: 100%
}

/*LAYOUT*/
html, body {
    height: 100%;
    margin: 0;
}

.content {
    flex-grow: 1;
    overflow: auto;
    padding: 1em 0.5em 2em 210px;
}

h1.landing-h1 {
    font-size: 4em;
}


.preview_letter_container {
    color: #808080;
    width: 75%;
    margin: 0 auto;
}

#mail_body th {
    text-align: left;
    border: 1px solid black;
    padding: 3px;
    color: #000000;
}

#mail_body td {
    text-align: left;
    border: 1px solid black;
    padding: 3px;
}

#mail_body table {
    border: 1px solid #000000;
    width: 100%;
    margin: 2em 0;
    border-collapse: collapse;
}

#mail_body th:empty {
    border: 0px;
    padding: 3px;
    height: 1rem;
}

#mail_body td:empty {
    border: 0px;
    padding: 3px;
    height: 1rem;
}

.mail_body_footer {
    margin-top: 5em;
    color: #0d3f42;
}

.mail_body_footer .ga {
    font-weight: bold;
    border-top: 1px solid #0d3f42;
}


@media (max-width: 991px) {
    #sidebar {
        display: none;
    }
    .content {
        padding-left: 0;
    }
    .preview_letter_container {
        width: 100%;
    }
}

table.table {
    font-size: 0.9em;
}

.landing_icons {
    font-size: 2em;
    margin-top: 0.3em;
}

.landing-links {
    text-decoration: none;
    color: black;
}

.landing-links:hover {
    text-decoration: none;
    color: rgba(179,158,106, 1);
}


