/* ============================================================
   Home page styles — extracted from Home.razor
   ============================================================ */

.content-container {
    margin: 0 32px;
}

/* Environment indicator banner (Development / UAT only — hidden in Production) */
.env-banner {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 6px 32px;
    color: #fff;
    font-family: 'Roboto', sans-serif;
    font-size: 14px;
    font-weight: 600;
    letter-spacing: 0.04em;
    text-transform: uppercase;
}

.env-banner-label::before {
    content: '⚠\00A0';
}

.title-section {
    background: #ffffff;
    padding-bottom: 0;
    border-top: 3px solid #00857C;
    border-bottom: 1px solid #E0E5E9;
}

.title-content-area {
    padding-top: 16px;
    padding-bottom: 20px;
}

.title-logo-row {
    display: flex;
    align-items: center;
    gap: 24px;
    padding: 10px 0 8px;
}

.title-logo {
    width: 216px;
    height: auto;
    display: block;
    flex-shrink: 0;
}

.site-logo-link {
    display: block;
    flex-shrink: 0;
}

.grid-title {
    font-family: "Roboto", sans-serif;
    font-weight: 700;
    text-transform: none;
    font-size: 30px;
    line-height: 1.2;
    color: #24323A;
}

.title-text-group {
    display: flex;
    flex-direction: column;
    gap: 10px;
    border-left: 3px solid #00857C;
    padding-left: 20px;
}

.grid-body {
    font-family: "Roboto", sans-serif;
    font-size: 16px;
    font-weight: 400;
    color: #3A4A54;
}

.banner-contact-link {
    color: #95989A;
    text-decoration: underline;
}

.banner-contact-link:hover {
    color: #24323A;
}

.info-box {
    background-color: #f9fafb;
    border: 1px solid #DDDDDD;
    border-radius: 10px;
    padding: 10px 14px;
    margin: 0;
}

.info-box-title {
    font-family: "Roboto", sans-serif;
    font-weight: 500;
    font-size: 14px;
    color: #333333;
    margin: 0 0 8px 0;
}

.info-box-text {
    font-family: "Roboto", sans-serif;
    font-size: 16px;
    color: #6B7580;
    margin: 0;
}

.sections-container {
    background-color: #f9fafb;
    display: flex;
    flex-direction: column;
    gap: 16px;
    margin: 0 32px;
    padding: 24px 0 32px 0;
}

.section-box {
    width: 100%;
}

/* Shared chamfered-corner mixin via gradient overlay.
   Paints four 6 px transparent triangles at each corner over the
   page background (#f9fafb), giving the cut-corner effect without
   clip-path so box-shadows and focus rings are never clipped. */
.procedure-name-cell {
    display: flex;
    align-items: flex-start;
    gap: 8px;
    flex-wrap: wrap;
}

.procedure-name-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.selection-action-btn-wrap {
    display: inline-flex;
}

.selection-action-btn {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    text-decoration: none;
}

.box-location,
.box-search,
.box-results {
    --chamfer: 6px;
    --page-bg: #f9fafb;
    background-image:
        linear-gradient(135deg, var(--page-bg) var(--chamfer), transparent var(--chamfer)),
        linear-gradient(225deg, var(--page-bg) var(--chamfer), transparent var(--chamfer)),
        linear-gradient(315deg, var(--page-bg) var(--chamfer), transparent var(--chamfer)),
        linear-gradient(45deg,  var(--page-bg) var(--chamfer), transparent var(--chamfer));
    background-position: top left, top right, bottom right, bottom left;
    background-size: 50% 50%;
    background-repeat: no-repeat;
}

.box-location {
    background-color: #FFFFFF;
    padding: 28px 0 20px 0;
    border-radius: 8px;
    box-shadow: 0 1px 4px rgba(0, 0, 0, 0.07);
}

.box-search {
    --page-bg: #F9FAFB;
    background-color: #F9FAFB;
    padding: 5px 0;
    border-radius: 8px;
    box-shadow: 0 1px 4px rgba(0, 0, 0, 0.07);
}

.box-results {
    background-color: #FFFFFF;
    padding: 5px 0;
    border-radius: 8px;
    box-shadow: 0 1px 4px rgba(0, 0, 0, 0.07);
}

#home-results-grid .k-master-row {
    cursor: pointer;
}

#home-results-grid .k-detail-row .k-grid-table {
    background: linear-gradient(180deg, #f6fbf9 0%, #fdfdfd 100%);
    border: 1px solid #d7e5df;
    border-radius: 8px;
    overflow: hidden;
}

#home-results-grid .k-detail-row .k-grid-table thead th {
    background-color: #4d7f71;
    color: #ffffff;
    font-weight: 700;
}

#home-results-grid .k-detail-row .k-grid-table tbody tr {
    background-color: #ffffff;
}

#home-results-grid .k-detail-row .k-grid-table tbody tr:hover {
    background-color: #f2f8f5;
}

#home-results-grid .k-detail-row .k-grid-table tbody td {
    border-color: #e8efeb;
}

#home-results-grid .k-detail-row .k-grid-table tbody tr td:first-child {
    font-weight: 600;
    color: #2f5f4f;
}

#home-results-grid .k-detail-row .k-grid-content,
#home-results-grid .k-detail-row .k-grid-header,
#home-results-grid .k-detail-row .k-grid-container,
#home-results-grid .k-detail-row .k-grid-table-wrap {
    overflow: hidden !important;
    overflow-x: hidden !important;
    overflow-y: hidden !important;
}

#home-results-grid .k-detail-row .k-grid-content {
    max-height: none !important;
    height: auto !important;
}

/* White text inside the search section to contrast with the green background */
.box-search .page-section-heading,
.box-search .search-instructions,
.box-search .filter-label {
    color: #5C6670;
}

.page-section-heading {
    font-family: "Roboto", sans-serif;
    font-weight: 700;
    font-size: 16px;
    color: #6B7580;
    margin: 16px 0 8px 30px;
}

.box-search .page-section-heading,
.box-results .page-section-heading {
    margin-top: 5px;
    margin-bottom: 5px;
}

.results-heading-row {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 12px;
}

.selection-message-banner {
    background-color: #FFF4B9;
    border: 1px solid #E5C94A;
    border-radius: 6px;
    padding: 10px 16px;
    margin: 8px 0 12px 0;
}

.selection-message-text {
    font-family: "Roboto", sans-serif;
    font-size: 16px;
    color: #4A3B00;
    margin: 0;
    line-height: 1.5;
}

.selection-message-text + .selection-message-text {
    margin-top: 6px;
}

.search-title {
    font-family: "Roboto", sans-serif;
    font-weight: 700;
    font-size: 16px;
    color: #6B7580;
    margin: 0px 0 16px 30px;
}

.location-container {
    max-width: 400px;
    padding: 0 0 0 30px;
}

/* Grid row that holds the location dropdown and the AP/Cyto entry point.
   Uses the same column template, gap, and left/right padding as
   .search-fields-grid / .search-fields-wrapper below so the AP/Cyto block
   lines up with the "Lab ID" column in the search section. */
.location-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    align-items: end;
    gap: 12px 32px;
    padding: 0 30px;
}

.location-combo-wrapper {
    max-width: 400px;
    width: 100%;
}

/* Anatomic Pathology - Cytopathology entry point beside the location dropdown */
.apcyto-top-wrapper {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 8px;
}

.apcyto-top-instructions {
    font-family: "Roboto", sans-serif;
    font-size: 14px;
    font-weight: 600;
    line-height: 1.4;
    color: #5C6670;
    margin: 0;
}

.apcyto-top-instructions-sub {
    font-weight: 400;
    font-size: 13px;
    color: #6B7580;
}

.apcyto-top-trigger-btn {
    padding: 16px 28px;
    font-size: 18px;
    background-color: #4D7F71 !important;
    border-color: #4D7F71 !important;
    color: #FFFFFF !important;
    font-weight: 700 !important;
}

.apcyto-top-trigger-btn:hover {
    background-color: #3a5f57 !important;
    border-color: #3a5f57 !important;
    color: #FFFFFF !important;
}

.apcyto-top-trigger-btn:focus-visible {
    outline: 2px solid #4D7F71;
    outline-offset: 2px;
}

.ql-category {
    font-family: "Roboto", sans-serif;
    font-size: 16px;
    font-weight: 700;
    color: #5e6140;
    letter-spacing: 0.03em;
    padding: 10px 14px 10px 16px;
    margin: 16px 0 0 0;
    background-color: #f0efe7;
    border-left: 4px solid #898f65;
    border-top: 1px solid #e0ddd0;
    border-bottom: 1px solid #e0ddd0;
}

.selection-drawer-entry {
    display: flex;
    flex-direction: column;
}

.selection-drawer-entry-state {
    color: #5e6140;
}

/* Scenario card: bordered + shaded box matching the screenshot layout */
.selection-scenario-card {
    background: #fdf9e9;
    border: 1px solid #ccc9a8;
    border-radius: 4px;
    margin: 8px 16px;
    padding: 12px 14px;
}

.selection-scenario-heading {
    font-weight: 700;
    font-size: 16px;
    color: #24323A;
    margin-bottom: 4px;
}

.selection-scenario-body {
    font-size: 16px;
    color: #24323A;
    margin-bottom: 10px;
}

.selection-scenario-body ul {
    margin: 0;
    padding: 0;
    list-style: none;
}

.selection-scenario-body li {
    padding-left: 0;
}

.selection-scenario-body li::before {
    content: "\2022 ";
}

.selection-scenario-link-label {
    font-weight: 700;
    font-size: 16px;
    color: #24323A;
    margin-bottom: 2px;
}

.selection-scenario-link-row {
    display: flex;
    flex-wrap: wrap;
    align-items: baseline;
    gap: 4px;
    margin-top: 2px;
}

.selection-scenario-link-row .selection-drawer-link--embedded {
    width: auto;
    padding: 0;
    margin-top: 0;
    font-size: 16px;
}

.selection-scenario-link-row .selection-drawer-lab-id-inline {
    font-size: 16px;
}

.ql-link {
    display: block;
    width: 100%;
    padding: 9px 14px;
    background: none;
    border: none;
    border-bottom: 1px solid #F0F0F0;
    text-align: left;
    font-family: "Roboto", sans-serif;
    font-size: 16px;
    font-weight: 500;
    color: #4D7F71;
    cursor: pointer;
    line-height: 1.4;
    text-decoration: underline;
    text-decoration-thickness: 1px;
    text-underline-offset: 3px;
}

.ql-link:hover {
    background-color: transparent;
    color: #3D6A5D;
    text-decoration-thickness: 2px;
}

.ql-link-synonym {
    color: #24323A;
    font-size: 16px;
    font-style: italic;
    font-weight: 400;
    margin-left: 2px;
}

/* ── Detail window content ── */
.detail-content {
    font-family: "Roboto", sans-serif;
    font-size: 16px;
    color: #5C6670;
    line-height: 1.65;
}

.detail-content h2 {
    font-size: 20px;
    font-weight: 500;
    color: #24323A;
    margin: 0 0 4px 0;
}

.detail-content .detail-meta {
    font-size: 14px;
    color: #9AA3AC;
    margin: 0 0 18px 0;
}

.detail-content h3 {
    font-size: 14px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: #5C6670;
    margin: 18px 0 6px 0;
    padding-bottom: 4px;
    border-bottom: 1px solid #EEEEEE;
}

.detail-content p {
    margin: 0 0 8px 0;
}

.detail-content table {
    border-collapse: collapse;
    width: 100%;
    margin: 6px 0 10px 0;
}

.detail-content th {
    background-color: #F9FAFB;
    border-bottom: 1px solid #D7E5DF;
    color: #FFFFFF;
    text-align: left;
    padding: 7px 12px;
    font-size: 14px;
    font-weight: 600;
    color: #24323A;
}

.detail-content td {
    padding: 6px 12px;
    font-size: 16px;
    border-bottom: 1px solid #F0F0F0;
}

.detail-content tr:hover td {
    background-color: #F9FBFA;
}

.detail-content ul, .detail-content ol {
    padding-left: 20px;
    margin: 4px 0 10px 0;
}

.detail-content li {
    margin-bottom: 4px;
}

.detail-placeholder {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 12px 16px;
    background-color: #FFF8E1;
    border: 1px solid #FFD54F;
    border-radius: 4px;
    font-family: "Roboto", sans-serif;
    font-size: 16px;
    color: #795548;
    margin-top: 16px;
}

.location-label {
    font-family: "Roboto", sans-serif;
    font-weight: 600;
    font-size: 16px;
    color: #5C6670;
    margin-bottom: 8px;
    display: block;
}

.location-combobox {
    font-family: "Roboto", sans-serif;
    font-size: 16px;
    border: 2px solid #D7E5DF;
    border-radius: 4px;
    background-color: #FFFFFF;
    color: #5C6670;
}

.location-combobox .k-input-inner {
    border-radius: 4px;
}

.location-combobox .k-input-button {
    background-color: #4D7F71;
    border-color: #4D7F71;
    color: #FFFFFF;
    font-weight: 700;
}

.location-combobox .k-input-button:hover {
    background-color: #3a5f57;
    border-color: #3a5f57;
    color: #FFFFFF;
}

.search-button {
    width: 300px;
    padding: 12px 24px;
    background-color: #4D7F71 !important;
    color: #FFFFFF !important;
    border: none;
    border-radius: 4px;
    font-family: "Roboto", sans-serif;
    font-size: 18px;
    font-weight: 700;
    line-height: 18px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    white-space: nowrap;
}

/* TelerikButton renders inner elements; force them to inherit the same flex layout */
.search-button .k-button-text {
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.search-button svg {
    display: block;
}

.search-button:hover {
    background-color: #3a5f57 !important;
}

.search-button:disabled {
    background-color: #8AA79F;
    cursor: not-allowed;
    opacity: 0.6;
}

.search-button:disabled:hover {
    background-color: #8AA79F;
}

.filter-search-container {
    padding: 12px 0 16px 0;
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 16px;
    flex-wrap: wrap;
}

.box-search .filter-search-container {
    padding-top: 5px;
    padding-bottom: 5px;
}

.search-instructions,
.results-status {
    font-family: "Roboto", sans-serif;
    font-size: 16px;
    color: #5C6670;
    margin: 0 30px 12px 30px;
    line-height: 1.5;
}

.box-search .search-instructions,
.box-results .results-status {
    margin-bottom: 5px;
}

.results-status {
    padding: 12px 16px;
    background-color: #F5F9F7;
    border: 1px solid #D7E5DF;
    border-radius: 6px;
}

.results-grid-wrapper {
    overflow-x: auto;
}

.results-grid-shell {
    position: relative;
}

.results-grid-loading {
    position: absolute;
    inset: 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 14px;
    background-color: rgba(249, 250, 251, 0.80);
    z-index: 1;
    pointer-events: none;
}

.results-grid-loading-spinner {
    width: 48px;
    height: 48px;
    border: 5px solid #b3e8ed;
    border-top-color: #00adbb;
    border-radius: 50%;
    animation: grid-spin 0.75s linear infinite;
}

.results-grid-loading-text {
    font-family: "Roboto", sans-serif;
    font-size: 16px;
    font-weight: 500;
    color: #00adbb;
}

@keyframes grid-spin {
    to { transform: rotate(360deg); }
}

.quick-links-helper-text {
    font-family: "Roboto", sans-serif;
    font-size: 16px;
    color: #5C6670;
    margin: 0 0 12px 0;
    line-height: 1.5;
}

.quick-links-helper-text ul {
    margin: 0;
    padding: 0;
    list-style: none;
}

.quick-links-helper-text li {
    padding-left: 0;
}

.quick-links-helper-text li::before {
    content: "\2022 ";
}

/* ── AP Cyto slide-in panel ── */
.apcyto-backdrop {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.38);
    z-index: 1200;
}

.apcyto-panel {
    position: fixed;
    top: 0;
    left: 0;
    width: 648px;
    max-width: 96vw;
    height: 100%;
    background: #FFFFFF;
    box-shadow: 4px 0 24px rgba(0, 0, 0, 0.18);
    z-index: 1201;
    display: flex;
    flex-direction: column;
    font-family: "Roboto", sans-serif;
}

.apcyto-panel-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    background-color: #F9FAFB;
    padding: 16px 20px;
    flex-shrink: 0;
}

.apcyto-panel-title {
    font-family: "Roboto", sans-serif;
    font-size: 18px;
    font-weight: 600;
    color: #24323A;
    margin: 0;
}

.apcyto-panel-close:focus-visible {
    outline: 2px solid #4D7F71;
    outline-offset: 2px;
}

.apcyto-panel-close {
    background: none;
    border: none;
    cursor: pointer;
    color: #24323A;
    padding: 4px;
    min-width: 44px;
    min-height: 44px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 4px;
    opacity: 0.85;
    transition: opacity 0.15s;
}

.apcyto-panel-close:hover {
    opacity: 1;
}

.apcyto-panel-body {
    flex: 1 1 auto;
    overflow-y: auto;
    padding: 8px 0 24px 0;
}

.apcyto-panel-body .ql-category:first-of-type {
    margin-top: 0;
}

.apcyto-search-field {
    display: block;
    width: 100%;
}

.apcyto-search-field .k-textbox {
    width: 100%;
}

.filter-label {
    font-family: "Roboto", sans-serif;
    font-weight: 600;
    font-size: 16px;
    color: #5C6670;
    margin: 0 0 6px 0;
    display: block;
}

.filter-disabled {
    opacity: 0.45;
    pointer-events: none;
    user-select: none;
}

.search-fields-wrapper {
    padding: 12px 30px 8px 30px;
}

.box-search .search-fields-wrapper {
    padding-top: 5px;
    padding-bottom: 5px;
}

.search-fields-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px 32px;
}

.search-field {
    display: flex;
    flex-direction: column;
}

.search-field .k-input {
    border-color: #00adbb;
    border-radius: 4px;
    font-family: "Roboto", sans-serif;
    font-size: 16px;
}

.search-field .k-input:focus-within {
    border-color: #008fa0;
    box-shadow: 0 0 0 2px rgba(0, 173, 187, 0.2);
}

.navigation-arrows {
    display: flex;
    justify-content: center;
    gap: 8px;
}

.nav-arrow {
    width: 40px;
    height: 40px;
    background-color: #00adbb;
    color: #FFFFFF;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 18px;
}

.nav-arrow:hover {
    background-color: #008fa0;
}

.pink-section-top-slim {
    background-color: #f9fafb;
    height: 0;
}

/* Grid Styles */
.k-grid {
    border: none;
    font-family: "Roboto", sans-serif;
}

.k-grid-header {
    background-color: #FFFFFF;
    border-bottom: 1px solid #DDDDDD;
    padding-inline-end: 0px !important;
}

.k-grid-header .k-header {
    background-color: #FFFFFF;
    border: none;
    border-right: none !important;
    border-left: none !important;
    font-family: "Roboto", sans-serif;
    font-size: 18px;
    line-height: 30px;
    font-weight: 500;
    color: #5C6670;
    padding: 20px 30px;
    text-align: left;
}

.k-grid tbody td {
    border: none;
    border-right: none !important;
    border-left: none !important;
    border-bottom: 1px solid #EEEEEE;
    padding: 6px 30px;
    font-family: "Roboto", sans-serif;
    font-size: 16px;
    line-height: 24px;
    font-weight: 400;
    color: #5C6670;
    vertical-align: middle;
}

.k-grid tbody tr {
    border: none;
}

.k-grid tbody tr:hover {
    background-color: #FAFAFA;
}

.k-grid td {
    border-right: none !important;
    border-left: none !important;
}

.k-grid th {
    border-right: none !important;
    border-left: none !important;
}

.selection-notice-bar {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    flex-wrap: wrap;
    padding: 10px 20px 10px 16px;
    margin: 0;
    background-color: #edf7f8;
    border-left: 4px solid #4D7F71;
    border-bottom: 1px solid #c9e8e5;
}

.selection-notice-label {
    display: flex;
    align-items: center;
    gap: 6px;
    font-family: "Roboto", sans-serif;
    font-size: 16px;
    font-weight: 700;
    color: #4D7F71;
    white-space: nowrap;
    padding-top: 3px;
}

.selection-notice-actions {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
}

.selection-notice-btn {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    padding: 8px 18px;
    background: #4D7F71;
    border: 1px solid #4D7F71;
    border-radius: 4px;
    font-family: "Roboto", sans-serif;
    font-size: 16px;
    font-weight: 700;
    color: #ffffff;
    cursor: pointer;
    white-space: nowrap;
    transition: background-color 0.15s, color 0.15s;
}

.selection-notice-btn:hover {
    background-color: #3a5f57;
    border-color: #3a5f57;
    color: #ffffff;
}

.selection-notice-btn:hover .selection-notice-chevron {
    stroke: #ffffff;
}

.selection-notice-chevron {
    flex-shrink: 0;
    stroke: currentColor;
}

.results-grid-toolbar {
    display: flex;
    align-items: center;
    justify-content: flex-start;
    padding: 16px 30px 10px;
}

.box-results .results-grid-toolbar {
    padding-top: 5px;
    padding-bottom: 5px;
}

.results-grid-toolbar-actions {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
}

.selection-action-btn {
    white-space: nowrap;
}

.results-grid-empty {
    padding: 16px 30px 24px;
    font-family: "Roboto", sans-serif;
    font-size: 16px;
    color: #5C6670;
}

.box-results .results-grid-empty {
    padding-top: 5px;
    padding-bottom: 5px;
}

.k-grid .k-filter-row .k-filtercell-operator {
    display: none;
}

.k-grid .k-filter-row .k-textbox,
.k-grid .k-filter-row .k-input,
.k-grid .k-filter-row .k-input-inner {
    width: 100%;
}

.test-name-cell {
    font-weight: 400;
    color: #5C6670;
    padding: 4px 0 4px 20px;
}

.synonyms-cell {
    color: #5C6670;
    padding: 4px 0 4px 20px;
}

.lab-id-cell {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 12px;
}

.lab-id-cell .synonyms-cell {
    padding-right: 0;
}

.lab-id-cell .selection-action-btn-wrap {
    margin-left: 0;
}

.performing-location-cell {
    color: #5C6670;
    padding: 4px 0 4px 20px;
    white-space: nowrap;
    overflow-wrap: normal;
    word-break: keep-all;
}

.updated-cell {
    color: #5C6670;
    padding: 12px 0 12px 20px;
}

.show-more-container {
    text-align: center;
    margin-top: 24px;
    padding-bottom: 32px;
}

.show-more-button {
    padding: 8px 20px;
    background-color: #b0b3b5;
    color: #000000;
    border: 1px solid #b0b3b5;
    border-radius: 4px;
    font-family: "Roboto", sans-serif;
    font-size: 18px;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.2s;
    line-height: 18px;
}

.show-more-button:hover {
    background-color: #9a9d9f;
    color: #000000;
    border: 1px solid #9a9d9f;
}

.resources-section {
    background-color: #f9fafb;
    padding: 5px 0;
}

.resources-wrapper {
    margin: 0 32px;
}

.resources-title {
    font-family: "Roboto", sans-serif;
    font-weight: 500;
    font-size: 36px;
    color: #5C6670;
    margin: 0 0 5px 0;
    border-bottom: 1px solid #bcbdbd;
}

.resources-grid {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 32px;
}

.resource-item {
    flex: 0 0 160px;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    cursor: pointer;
    position: relative;
    text-decoration: none;
    color: inherit;
    background: none;
    border: none;
    padding: 0;
    font-family: inherit;
    gap: 14px;
}

.resource-icon {
    width: 80px;
    height: 80px;
    padding: 16px;
    transition: transform 0.3s ease, filter 0.3s ease;
    filter: invert(76%) sepia(5%) saturate(300%) hue-rotate(169deg) brightness(95%) contrast(88%);
}

.resource-item::before {
    content: '';
    position: absolute;
    top: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 80px;
    height: 80px;
    border-radius: 50%;
    background-color: transparent;
    transition: background-color 0.3s ease, transform 0.3s ease;
    z-index: 0;
}

.resource-item:hover::before,
.resource-item:focus-visible::before {
    background-color: #b0b3b5;
    transform: translateX(-50%) scale(1.04);
}

.resource-item .resource-icon {
    position: relative;
    z-index: 1;
}

.resource-item:hover .resource-icon,
.resource-item:focus-visible .resource-icon {
    transform: scale(1.03);
    filter: brightness(0) invert(1);
}

.resource-title {
    font-family: "Roboto", sans-serif;
    font-size: 20px;
    line-height: 18px;
    font-weight: 500;
    color: #5C6670;
    position: relative;
    z-index: 1;
    text-decoration: none;
    text-underline-offset: 4px;
    transition: color 0.3s ease, text-decoration-color 0.3s ease;
}

.resource-item:hover .resource-title,
.resource-item:focus-visible .resource-title {
    color: #000000;
    text-decoration: underline;
}

.resource-item:focus-visible {
    outline: none;
}

/* Make filter inputs/dropdowns match your border colour */
.filter-container .k-filter .k-input,
.filter-container .k-filter .k-dropdownlist,
.filter-container .k-filter .k-combobox {
    border-color: #00adbb;
    border-radius: 4px;
}

/* Style the AND/OR operator button */
.filter-container .k-filter .k-filter-operator .k-button {
    background-color: #00adbb;
    color: #FFFFFF;
    border: none;
    border-radius: 4px;
}

.filter-container .k-filter .k-filter-operator .k-button:hover {
    background-color: #008fa0;
}

/* Add filter / add group links */
.filter-container .k-filter-toolbar .k-button-flat {
    color: #00adbb;
}

/* Remove button */
.filter-container .k-filter-remove .k-button {
    color: #5C6670;
}

/* Connecting tree lines */
.filter-container .k-filter-lines {
    border-color: #DDDDDD;
}

/* Double the width of the field name dropdown */
.filter-container .k-filter .k-filter-field .k-dropdownlist {
    width: 250px;
}

/* Keep the field / operator / value on one line */
.filter-container .k-filter .k-filter-item {
    flex-wrap: nowrap;
}

/* Hide the Add Group button */
.filter-container .k-filter-toolbar .k-button:nth-child(3) {
    display: none;
}

/* Double the width of the Add Expression button */
.filter-container .k-filter-toolbar .k-button:nth-child(2) {
    padding-inline: 3em;
    background-color: #00adbb;
    color: #FFFFFF;
}

@media (max-width: 1100px) {
    .search-fields-grid {
        grid-template-columns: 1fr 1fr;
    }

    .location-row {
        align-items: stretch;
    }

    .location-combo-wrapper {
        max-width: none;
        width: 100%;
    }
}

@media (max-width: 768px) {
    .content-container,
    .resources-wrapper {
        margin: 0 16px;
    }

    .sections-container {
        margin: 0 16px;
        gap: 12px;
        padding: 16px 0 24px 0;
    }

    .title-logo-row {
        gap: 12px;
    }

    .title-logo {
        width: 174px;
    }

    .grid-title {
        font-size: 26px;
        line-height: 1.1;
    }

    .page-section-heading,
    .search-title,
    .search-instructions,
    .results-status {
        margin-left: 16px;
        margin-right: 16px;
    }

    .location-row {
        grid-template-columns: 1fr;
        gap: 12px;
        padding: 0 16px;
    }

    .search-fields-wrapper {
        padding: 12px 16px 8px 16px;
    }

    .search-fields-grid {
        grid-template-columns: 1fr;
    }

    .filter-search-container {
        padding: 8px 16px 16px 16px;
    }

    .search-button {
        width: 100%;
    }

    .resources-title {
        font-size: 28px;
        margin-bottom: 32px;
    }

    .k-grid-header .k-header,
    .k-grid tbody td {
        padding-left: 16px;
        padding-right: 16px;
    }
}

.view-test-button.k-button-solid {
    background-color: #4D7F71;
    border-color: #4D7F71;
    color: #FFFFFF;
    font-weight: 700;
}

.view-test-button.k-button-solid:hover {
    background-color: #3a5f57;
    border-color: #3a5f57;
}

/* ── Detail template hierarchy expand/collapse icon: green chevron ── */

/* Position the icon container for the pseudo-element overlay */
.k-grid .k-hierarchy-cell .k-icon {
    position: relative;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

/* Hide the default SVG (+ / -) regardless of its specific icon class */
.k-grid .k-hierarchy-cell .k-icon svg {
    opacity: 0;
}

/* Collapsed row → green chevron pointing right */
.k-grid .k-hierarchy-cell .k-icon::before {
    content: '';
    position: absolute;
    width: 9px;
    height: 9px;
    border-right: 2.5px solid #4D7F71;
    border-bottom: 2.5px solid #4D7F71;
    transform: rotate(-45deg);
    margin-top: -1px;
}

/* Expanded row → green chevron pointing down (.k-expanded is added by Telerik on the tr) */
.k-grid .k-table-row.k-expanded .k-hierarchy-cell .k-icon::before {
    transform: rotate(45deg);
    margin-top: 2px;
}

.k-toolbar .k-searchbox .k-input-inner {
    height: 42px;
    font-size: 16px;
}
