﻿:root {
    --eurl-ink: #0D2642;
    --eurl-navy: #003776;
}

body {
    font-family: 'Roboto', Helvetica, Arial, sans-serif;
    color: #000;
    min-height: 100vh;
}

/* App shell chrome, brought in line with the landing page (wwwroot/css/landing.css). */
.eurl-navbar {
    background-color: var(--eurl-ink);
}

.eurl-navbar .navbar-brand__mark {
    display: inline-flex;
    align-items: center;
    padding: 0.28rem 0.65rem;
    border: 1px solid rgba(255, 255, 255, 0.55);
    border-radius: 6px;
    font-size: 0.82rem;
    font-weight: 500;
    letter-spacing: 0.1em;
    color: #fff;
}

.navbar-dark .navbar-nav .nav-link {
    color: rgba(255, 255, 255, 0.82);
}

.navbar-dark .navbar-nav .nav-link:hover {
    color: #fff;
}

.layout-shell {
	min-height: 100vh;
	display: flex;
	flex-direction: column;
}

.layout-shell main {
	flex: 1 0 auto;
}

/* MemberArea: lock the shell to the viewport so the page itself never scrolls.
   The navbar and footer keep their natural height; the main area fills the rest
   and its content (e.g. a grid) scrolls internally. */
.member-area-shell {
	height: 100vh;
	overflow: hidden;
}

.member-area-shell > nav,
.member-area-shell > footer {
	flex: 0 0 auto;
}

main.member-area {
	flex: 1 1 auto;
	min-height: 0;
	display: flex;
	flex-direction: column;
}

main.member-area > .content,
main.member-area > .content > .content {
	flex: 1 1 auto;
	min-height: 0;
	display: flex;
	flex-direction: column;
}

/* Reusable grid wrapper: fills the available height so the grid scrolls
   internally instead of growing the page. Using a flex column lets the grid
   fill the space below any leading elements (e.g. breadcrumbs). */
.grid-container {
	flex: 1 1 auto;
	min-height: 0;
	display: flex;
	flex-direction: column;
}

.grid-container > .k-grid {
	flex: 1 1 auto;
	min-height: 0;
}

/* Content container wrapper: ensures tab strips and other components within
   only use the remaining space without overflowing the footer. */
.content-container {
	flex: 1 1 auto;
	min-height: 0;
	display: flex;
	flex-direction: column;
	margin-top: 10px;
}

/* Reusable info panel: a rounded, tinted content block used to group related
   text (e.g. profile sections, informational pages). */
.info-panel {
	margin-bottom: 24px;
	padding: 12px;
	background-color: #eef4ff;
	border-radius: 4px;
}

.info-panel-title {
	font-size: 16px;
	font-weight: 700;
	margin: 0 0 12px 0;
	color: #333;
	text-transform: none;
}

.tab-strip {
	background-color: #f8f8f8;
}

/* "Network of Official Labs" (/network-of-official-labs).
   This page scrolls normally instead of being locked to the viewport like the member area, so its
   grids get a bounded height of their own rather than filling the shell. 480px roughly matches the
   450px scroll height the legacy Reference Labs grids used. */
.network-labs__grid {
	height: 480px;
	margin-bottom: 24px;
}

.network-labs__grid > .grid-container {
	height: 100%;
}

.network-labs__tab-title {
	margin-bottom: 12px;
}

.landing .lab-map {
	margin-bottom: 16px;
}

/* A shorter hero for interior pages: the landing page's own hero fills most of the viewport, which
   would push a page's actual content far below the fold. */
.landing .hero--compact {
	min-height: 0;
	padding-block: clamp(7rem, 12vw, 9rem) clamp(2.5rem, 5vw, 4rem);
}

/* Telerik components inherit from .landing otherwise: its line-height (1.65) loosens grid rows and
   its slate text colour overrides the Kendo theme's. Hand those back to the theme. */
.landing .k-grid,
.landing .k-map,
.landing .k-tabstrip {
	line-height: normal;
	color: initial;
}

.landing .k-map {
	/* landing.css gives .landing a Roboto stack; the map's own labels should follow the theme. */
	font-family: inherit;
}

/* NRL "connection" markers (InstitutionSubsidiaryMap's ConnectionMarkers layer, Shape="Pin" - the
   only layer in the app using that shape, rendered as .k-svg-i-map-marker) render black once an
   EURL is selected, so they read as distinct from the still-red primary EURL markers
   (Shape="PinTarget", rendered as .k-svg-i-map-marker-target). */
.landing .lab-map .k-svg-i-map-marker:not(.k-svg-i-map-marker-target) {
	color: #000;
}

/* The map tooltip renders a small stack of labelled rows; keep it left-aligned (the legacy views
   overrode .k-tooltip the same way) and stop a long institution name stretching it across. */
.lab-map__tooltip {
	text-align: left;
	max-width: 320px;
}

.lab-map__tooltip-roles {
	margin-top: 8px;
}

.lab-map__hints {
	margin-top: 8px;
	padding-left: 20px;
	font-size: 13px;
}

.content-container > .k-tabstrip {
	flex: 1 1 auto;
	min-height: 0;
}

.content-container > .k-tabstrip > .k-tabstrip-content {
	flex: 1 1 auto;
	min-height: 0;
}

.details-splitter.k-splitter {
	flex: 1 1 auto;
	min-height: 0;
	height: auto;
}

.details-splitter .participant-details,
.details-splitter .compound-details {
	height: 100%;
	display: flex;
	flex-direction: column;
}

.details-splitter .participant-details > .tab-strip,
.details-splitter .compound-details > .tab-strip {
	flex: 1 1 auto;
	min-height: 0;
	display: flex;
	flex-direction: column;
}

.details-splitter .participant-details > .tab-strip > .k-tabstrip-content,
.details-splitter .compound-details > .tab-strip > .k-tabstrip-content {
	flex: 1 1 auto;
	min-height: 0;
	overflow-y: auto;
}

/* Resizable Telerik Windows: make the (otherwise invisible) resize
   handles visible so users know the window can be resized. */
.resizable-window-cue .k-resize-se {
	background-image: repeating-linear-gradient(
		135deg, currentColor 0 2px, transparent 2px 5px
	);
	color: var(--kendo-color-border, rgba(0, 0, 0, .35));
	opacity: .6;
}

.resizable-window-cue .k-resize-se:hover {
	opacity: 1;
}

.resizable-window-cue .k-resize-handle:hover {
	background-color: var(--kendo-color-primary, #ff6358);
	opacity: .35;
}

h1 {
	font-size: 1.25rem;
	font-weight: 400;
}

h2 {
    font-size: 1.5rem;
    font-weight: 200;
}

h3 {
    font-size: 1.25rem;
    font-weight: 400;
}

h4 {
    font-size: 1.25rem;
}

h5 {
    font-size: 1.25rem;
}

p {
    font-size: 1rem;
}

a {
    font-size: 1rem;
}

@media (min-width: 480px) {
    h1 {
        font-size: 1.5rem;
        font-weight: 400;
    }

    h2 {
        font-size: 1.25rem;
        font-weight: 200;
    }
}

@media (min-width: 768px) {
    h1 {
        font-size: 1.75rem;
        font-weight: 200;
    }

    h2 {
        font-size: 1.5rem;
        font-weight: 200;
    }
}

/* --- Bootstrap5 Menu Kit :::: https://bootstrap-menu.com  */
.dropdown:hover {
    z-index: 45;
}

.navbar:hover {
    z-index: 40;
}

.offcanvas-start, .offcanvas-end {
    max-width: 80%;
}

.fixed-onscroll.fixed-top {
    top: -60px;
    transform: translateY(60px);
    transition: transform .3s;
}

.autohide {
    position: fixed;
    top: 0;
    right: 0;
    left: 0;
    width: 100%;
    z-index: 1030;
}

.autohide.scrolled-down {
    transform: translateY(-100%);
    transition: all 0.3s ease-in-out;
}

.autohide.scrolled-up {
    transform: translateY(0);
    transition: all 0.3s ease-in-out;
}

.navbar .dropdown-menu, .dropdown .dropdown-menu {
    margin-top: 0;
    box-shadow: 0 2px 4px rgba(34, 34, 34, 0.15);
}

.navbar .dropdown-menu-end, .dropdown .dropdown-menu-end {
    right: 0;
    left: auto;
}

.navbar .megasubmenu, .dropdown .megasubmenu {
    padding: 1rem;
}

.navbar .dropdown-large, .dropdown .dropdown-large {
    padding: 1rem;
}

.navbar .megamenu, .dropdown .megamenu {
    padding: 1rem;
}

.navbar .has-megamenu, .dropdown .has-megamenu {
    position: static !important;
}

.icon-arrow:after {
    content: "\276F";
    font-style: normal;
    line-height: 1;
    display: inline-block;
    vertical-align: middle;
    margin-left: 7px;
    margin-top: -2px;
    opacity: .3;
    font-size: 80%;
}

.screen-darken {
    display: block;
    height: 100%;
    width: 0%;
    z-index: 20;
    position: fixed;
    top: 0;
    right: 0;
    opacity: 0;
    visibility: hidden;
    background-color: rgba(34, 34, 34, 0.6);
    transition: opacity .2s linear, visibility 0.2s, width 2s ease-in;
}

.screen-darken.active {
    z-index: 25;
    transition: opacity .3s ease, width 0s;
    opacity: 1;
    width: 100%;
    visibility: visible;
}

/* ============ desktop view ============ */
@media all and (min-width: 992px) {
    .navbar {
        padding: 0;
    }

    .navbar .nav-link {
        padding-top: 0.75rem;
        padding-bottom: 0.75rem;
        padding-left: 0.7rem !important;
        padding-right: 0.7rem !important;
    }

    .navbar-dark .nav-link.show {
        background: rgba(255, 255, 255, 0.12);
    }

    .navbar-light .nav-link.show {
        background: rgba(0, 0, 0, 0.12);
    }

    .navbar-nav {
        align-items: center;
    }

    .dropdown-menu li {
        position: relative;
    }

    .dropdown-menu .submenu {
        display: none;
        position: absolute;
        left: 100%;
        top: -7px;
    }

    .dropdown-menu .submenu-left {
        right: 100%;
        left: auto;
    }

    .dropdown-menu > li:hover {
        background-color: #f1f1f1;
    }

    .dropdown-menu > li:hover > .submenu {
        display: block;
    }

    .megasubmenu {
        left: 100%;
        top: 0;
        min-height: 100%;
        min-width: 500px;
    }

    .dropdown-menu-end .megasubmenu {
        left: auto;
        right: 100%;
        top: 0;
    }

    .dropdown-menu > li:hover .megasubmenu {
        display: block;
    }

    .dropdown-large {
        min-width: 520px;
    }

    .megamenu {
        left: 0;
        right: 0;
        width: 100%;
    }

    .nav-item.hover .dropdown-menu.animate {
        display: block;
        opacity: 0;
        visibility: hidden;
        margin-top: 0;
    }

    .nav-item.hover .animate.fade-down {
        top: 90%;
        transform: rotateX(-80deg);
        transform-origin: 0% 0%;
    }

    .nav-item.hover .animate.fade-up {
        top: 90px;
    }

    .nav-item.hover .dropdown-menu .animate.fade-down {
        top: 0;
    }

    .nav-item.hover .animate.dropdown-menu.show {
        display: block;
        transition: .4s;
        opacity: 1;
        visibility: visible;
        top: 100%;
        transform: rotateX(0deg);
    }

    .nav-item.hover .animate.dropdown-menu > li:hover > .submenu,
    .nav-item.hover .animate.dropdown-menu > li:hover > .megasubmenu {
        display: block;
        transition: .4s;
        opacity: 1;
        visibility: visible;
        top: 0;
        transform: rotateX(0deg);
    }

    .dropdown-menu li {
        position: relative;
    }

    .dropdown-menu li.has-megasubmenu {
        position: static !important;
    }

    .dropdown-menu li:hover > .submenu, .dropdown-menu li:hover > .dropdown-menu {
        display: block;
        transition: .4s;
        opacity: 1;
        visibility: visible;
        top: 0%;
        transform: rotateX(0deg);
    }

    .dropdown-menu li:hover > .megasubmenu {
        display: block;
        transition: .4s;
        opacity: 1;
        visibility: visible;
        top: 0%;
        transform: rotateX(0deg);
    }
}

/* ============ desktop view .end// ============ */
/* ============ small devices ============ */
@media (max-width: 991px) {
    .dropdown-menu .dropdown-menu {
        margin-left: 0.7rem;
        margin-right: 0.7rem;
        margin-bottom: .5rem;
    }
}

/* ============ small devices .end// ============ */
/* ============  THEME CUSTOM  ============ */
.navbar-styled {
    background-color: #ffca2a;
    box-shadow: 0 2px 3px rgba(100, 100, 100, 0.1);
    font-size: 14px;
}

.navbar-styled .navbar-toggler {
    color: rgba(0, 0, 0, 0.5);
    border-color: rgba(0, 0, 0, 0.1);
}

.navbar-styled .navbar-toggler-icon {
    background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' width='30' height='30' viewBox='0 0 30 30'%3e%3cpath stroke='rgba(0, 0, 0, 0.5)' stroke-linecap='round' stroke-miterlimit='10' stroke-width='2' d='M4 7h22M4 15h22M4 23h22'/%3e%3c/svg%3e");
}

.navbar-styled .navbar-brand {
    font-weight: 600;
    font-size: 18px;
}

.navbar-styled .navbar-nav .nav-link {
    font-weight: 600;
    text-transform: uppercase;
    color: #333;
    border: 2px solid transparent;
}

.navbar-styled .navbar-nav .nav-item:hover .nav-link, .navbar-styled .navbar-nav .nav-item.show .nav-link {
    border-bottom: 2px solid orange;
    color: #111;
}

.navbar-styled .dropdown-menu {
    border: 0;
    background-clip: initial;
    border-radius: 0;
    box-shadow: 0 1px 5px rgba(70, 70, 70, 0.2);
}

.navbar-styled .dropdown-menu .dropdown-item {
    padding: .6rem 1.5rem;
    border-bottom: 1px solid #f1f1f1;
}

.footer {
	padding: 10px;
	background-color: var(--eurl-ink);
	margin-top: 12px;
	font-size: 11px;
	color: #fff;
}

.footer a {
    color: #fff;
    font-size: 11px;
}

.footer .eurl-logo {
    width: 100px;
    height: 20px;
    vertical-align: middle;
    background-image: url("/images/eurl-logo.svg");
    background-position: center;
    background-repeat: no-repeat;
}

.content {
	min-height: 480px;
}

.content h2 {
    margin-top: 0.5rem;
}

.padding-bottom {
    padding-bottom: 1em;
}

#blazor-error-ui {
    background: lightyellow;
    bottom: 0;
    box-shadow: 0 -1px 2px rgba(0, 0, 0, 0.2);
    display: none;
    left: 0;
    padding: 0.6rem 1.25rem 0.7rem 1.25rem;
    position: fixed;
    width: 100%;
    z-index: 1000;
}

#blazor-error-ui .dismiss {
    cursor: pointer;
    position: absolute;
    right: 0.75rem;
    top: 0.5rem;
}

.initial-data-loader .k-loader-container-overlay {
    background-color: white;
}

.k-loader-container {
    z-index: 100;
}

.cloud {
    color: #d9d9d9;
    font-size: 90px;
}

.k-grid-norecords .k-badge-container {
    position: relative;
    display: inline-block;
}

.k-grid-norecords .k-badge-container > .k-badge {
    position: absolute;
    top: -6px;
    right: -6px;
}

.k-grid-norecords {
    position: absolute;
    top: 100px;
    left: 50%;
    transform: translateX(-50%);
}

.k-grid-norecords:hover {
    background-color: #ffffff !important;
}

.filter-values-container {
    max-height: 200px;
    overflow: auto;
    padding: 0 8px;
}

.window-content {
    height: 100%;
    min-height: 0;
    display: flex;
    flex-direction: column;
}

.edit-form {
    width: 100%;
    flex: 1;
    min-height: 0;
    height: 100%;
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

.edit-form .k-form-layout {
    flex: 1 1 auto;
    min-height: 0;
    overflow: hidden;
}

.edit-form.k-form-horizontal .k-form-field > .k-label,
.edit-form.k-form-horizontal .k-form-field > .k-form-label {
    align-items: flex-start;
    text-align: start;
    white-space: nowrap;
    width: 40%;
    max-width: calc(60% - 10px);
}

.edit-form .edit-form-fields {
    height: 100%;
    min-height: 0;
    overflow: auto;
    padding-right: 8px;
}

.edit-form .k-form-buttons {
    flex: 0 0 auto;
    margin-top: 10px;
    padding-top: 12px;
    border-top: 1px solid #ddd;
    background: #fff;
}

.edit-form,
.edit-form .k-form-legend,
.edit-form .k-textbox,
.edit-form .k-dropdownlist,
.edit-form .k-multiselect,
.edit-form .k-input,
.edit-form .k-button,
.edit-form .k-form-label,
.edit-form .k-label,
.edit-form label,
.edit-form .k-form-hint,
.edit-form a,
.edit-form .k-form-field-wrap,
.edit-form .k-picker,
.edit-form .k-input-inner,
.edit-form .k-input-value-text,
.edit-form .k-checkbox-label,
.edit-form .k-tabstrip-items .k-link,
.edit-form .k-tabstrip-items .k-item,
.edit-form .k-radio-label,
.edit-form .k-textarea,
.edit-form .k-editor,
.edit-form .k-editor-content,
.edit-form .k-grid,
.edit-form .k-grid td,
.edit-form .k-grid th,
.edit-form .k-numerictextbox,
.edit-form .k-chip,
.edit-form .k-chip-content,
.edit-form .k-switch-label,
.edit-form .k-validation-message,
.edit-form .validation-message,
.edit-form .k-tooltip-validation {
    font-size: 12px;
}

.window-content > .k-tabstrip {
    flex: 0 0 auto;
    margin-bottom: 8px;
}

.window-content > .k-tabstrip .k-tabstrip-items .k-link,
.window-content > .k-tabstrip .k-tabstrip-items .k-item {
    font-size: 12px;
}

.edit-form .k-form-hint {
    display: block;
    max-width: 95%;
    padding-left: 5px;
}

.edit-form .k-popup.smaller-font,
.edit-form .k-popup.smaller-font .k-calendar {
    font-size: 12px;
}

.edit-form .k-form-legend {
    font-weight: bold;
}

.edit-form .k-validation-summary ul {
    list-style-type: none;
    padding: 0;
    margin: 0;
}

.edit-form .validation-message,
.edit-form .k-form-error .k-validation-message,
.edit-form .k-validation-message,
.edit-form .k-tooltip-validation {
    color: #c00;
}

.edit-form .validation-message.smaller-font,
.edit-form .k-form-error .k-validation-message.smaller-font,
.edit-form .k-tooltip-validation.smaller-font {
    font-size: 11px;
    line-height: 1.2;
}

.hide {
    display: none;
    visibility: hidden;
}

.menu-title {
    font-weight:600;
}