@import url('https://fonts.googleapis.com/css2?family=Hanken+Grotesk:ital,wght@0,100..900;1,100..900&display=swap');
@import url('https://fonts.googleapis.com/css2?family=Roboto:ital,wght@0,100;0,300;0,400;0,500;0,700;0,900;1,100;1,300;1,400;1,500;1,700;1,900&display=swap');

/*==================================================
 * 1. RHG THEME COLOR PALETTE & VARIABLES
 *================================================== */
:root {
    /* Blue */
    --rhg-blue-lightest: #ADD4E8;
    --rhg-blue-light: #70B3D6;
    --rhg-blue-medium: #3293C5;
    --rhg-blue-dark: #28769E;
    --rhg-blue-darkest: #1E5876;
    
    /* Yellow */
    --rhg-yellow-lightest: #F7E4C3;
    --rhg-yellow-light: #F1D097;
    --rhg-yellow-medium: #EBBC6A;
    --rhg-yellow-dark: #BC9655;
    --rhg-yellow-darkest: #8D7140;
    
    /* Orange */
    --rhg-orange-lightest: #F4CDBF;
    --rhg-orange-light: #ECA890;
    --rhg-orange-medium: #E48360;
    --rhg-orange-dark: #B6694D;
    --rhg-orange-darkest: #894F3A;
    
    /* Cyan */
    --rhg-cyan-lightest: #BAE9EC;
    --rhg-cyan-light: #86D8DD;
    --rhg-cyan-medium: #52C7CF;
    --rhg-cyan-dark: #429FA6;
    --rhg-cyan-darkest: #31777C;
    
    /* Green */
    --rhg-green-lightest: #B7D9D1;
    --rhg-green-light: #82BDAE;
    --rhg-green-medium: #4CA08B;
    --rhg-green-dark: #3D806F;
    --rhg-green-darkest: #2E6053;
    
    /* Purple */
    --rhg-purple-lightest: #C6C3D0;
    --rhg-purple-light: #9C97AD;
    --rhg-purple-medium: #716A8A;
    --rhg-purple-dark: #5A556E;
    --rhg-purple-darkest: #444053;
    
    /* Grey */
    --rhg-grey-lightest: #C9CBCB;
    --rhg-grey-light: #A1A3A4;
    --rhg-grey-medium: #797C7D;
    --rhg-grey-dark: #616364;
    --rhg-grey-darkest: #494A4B;
    
    /* Red - for danger/destructive actions */
    --rhg-red-lightest: #F4CFCF;
    --rhg-red-light: #ECA5A5;
    --rhg-red-medium: #D64545;
    --rhg-red-dark: #AC3737;
    --rhg-red-darkest: #812929;
    
    /* Additional colors */
    --rhg-deep-black: #0A0A19;
    --rhg-crisp-white: #FFFFFF;
    --rhg-neutral-grey: #F2F2F2;
    --rhg-pastel-blue: #CCE4EF;
    --rhg-soft-navy: #003C58;
    --rhg-china-orange: #E48360;
    --rhg-enc-yellow: #EBBC6A;
    --rhg-rhodium-blue: #0078AD;
    
    /* System tokens */
    --rhg-sys-color-border-default: var(--rhg-grey-light);

    /* Font family */
    --font-family-main: 'Hanken Grotesk', sans-serif;
    --font-family-secondary: 'Roboto', sans-serif;
    
    /* Font sizes */
    --font-size-page-header: 20px;
    --font-size-page-subhead: 16px;
    --font-size-section-header: 18px;
    --font-size-paragraph: 14px;
    --font-size-small: 12px;
    --font-size-tiny: 11px;
    
    /* Font weights */
    --font-weight-light: 300;
    --font-weight-normal: 400;
    --font-weight-medium: 500;
    --font-weight-semibold: 600;
    --font-weight-bold: 700;
    
    /* Spacing */
    --spacing-xs: 4px;
    --spacing-sm: 8px;
    --spacing-md: 16px;
    --spacing-lg: 24px;
    --spacing-xl: 32px;
    --spacing-xxl: 48px;
    
    /* Layout dimensions */
    --header-height: 54px;
    --min-header-height: 54px;
    --max-header-height: 54px;
    --navbar-height: 54px;
    --sidebar-width: 200px;
    --right-sidebar-width: 200px;
    
    /* Icon sizes - Reference tokens */
    --rhg-ref-size-icon-xs: 12px;
    --rhg-ref-size-icon-sm: 16px;
    --rhg-ref-size-icon-md: 20px;
    --rhg-ref-size-icon-lg: 24px;
    --rhg-ref-size-icon-xl: 32px;
    
    /* Icon sizes - System tokens */
    --rhg-sys-icon-size-default: var(--rhg-ref-size-icon-sm);
    --rhg-sys-icon-size-small: var(--rhg-ref-size-icon-xs);
    --rhg-sys-icon-size-large: var(--rhg-ref-size-icon-md);
}

/*==================================================
 * 2. RESET & BASE STYLES
 *================================================== */
html {
    font-family: var(--font-family-main);
    margin: 0;
    padding: 0;
}

body {
    margin: 0;
    padding: 0;
    font-family: var(--font-family-main);
    color: var(--rhg-deep-black);
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    text-rendering: optimizeLegibility;
    /* Prevent layout shifts during navigation */
    overflow-y: scroll;
    min-height: 100vh;
}

body * {
    line-height: 1.2;
    color: var(--rhg-deep-black);
}

/* Universal font declarations */
button, input, select, textarea, span, a, p, h1, h2, h3, h4, h5, h6, li, td, th, label {
    font-family: var(--font-family-main) !important;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

/* Horizontal rule styling */
hr {
    border: none;
    border-top: 0.5px solid #C9CBCB;
    margin: 16px 0;
}

/*==================================================
 * 3. HEADER STYLES
 *================================================== */
.header-container {
    width: 100%;
    height: var(--header-height);
    min-height: var(--min-header-height);
    max-height: var(--max-header-height);
    flex-shrink: 0;
    background-color: var(--rhg-crisp-white);
    display: flex;
    align-items: center;
    padding: 0 40px 0 0;
    border-bottom: none;
    overflow: hidden;
    gap: 1rem;
    box-sizing: border-box;
}

.logo-container {
    position: relative;
    display: flex;
    align-items: center;
    height: 54px;
    flex: 0 0 auto;
    max-width: 54px;
}

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

.title-container {
    position: relative;
    display: flex;
    align-items: center;
    background-color: var(--rhg-crisp-white);
    height: var(--header-height);
    min-height: var(--min-header-height);
    max-height: var(--max-header-height);
    flex: 0 0 auto;
    min-width: 0;
}

.home-button {
    color: var(--rhg-deep-black);
    text-align: left;
    font-size: 32px;
    font-style: normal;
    font-weight: 700;
    line-height: normal;
    text-decoration: none;
    cursor: pointer;
    display: flex;
    align-items: center;
    height: 100%;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    font-family: 'Hanken Grotesk', sans-serif;
}

.logout-container {
    flex: 0 0 auto;
    display: flex;
    align-items: center;
    white-space: nowrap;
}

/* Logout button - white background, text-only, no border */
.logout-button {
    background-color: white;
    color: var(--rhg-deep-black);
    text-decoration: none;
    font-size: 16px;
    font-weight: 500;
    font-family: var(--font-family-main);
    padding: 10px 20px;
    height: 36px;
    box-sizing: border-box;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border: none;
    transition: background-color 0.15s ease;
}

.logout-button:hover {
    background-color: var(--rhg-grey-lightest);
    color: var(--rhg-deep-black);
    text-decoration: none;
}

.header-spacer {
    flex: 1 1 auto;
}

/* Divider bar removed from layout */
.divider-bar {
    display: none;
}

.nav-link {
    background-color: var(--rhg-pastel-blue);
    color: var(--rhg-deep-black);
    text-decoration: none;
    font-size: 16px;
    font-weight: 500;
    font-family: var(--font-family-main);
    padding: 10px 20px;
    height: 36px;
    box-sizing: border-box;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 0;
    border: none;
}

.nav-link:hover {
    background-color: var(--rhg-blue-lightest);
    color: var(--rhg-deep-black);
    text-decoration: none;
}

/*==================================================
 * 4. NAVIGATION STYLES
 *================================================== */
.site-header-wrapper {
    width: 100%;
    position: relative;
}

.site-header-wrapper nav {
    background-color: transparent;
    height: var(--navbar-height);
    width: 100%;
    display: flex;
    align-items: center;
    padding: 0 16px;
    gap: 32px;
    box-sizing: border-box;
    position: relative; /* Required for mobile menu positioning */
    z-index: 1;
}

.site-header-wrapper nav::before {
    content: '';
    position: absolute;
    top: 0;
    left: calc(-50vw + 50%);
    width: 100vw;
    height: 100%;
    background-color: #cce4ef;
    z-index: -1;
}

/* Top navigation bar (NOT for .rhg-tabs__nav - see Tab Components section) */
nav:not(.rhg-tabs__nav) {
    background-color: #cce4ef;
    height: var(--navbar-height);
    width: 100%;
    display: flex;
    align-items: center;
    padding: 0 16px;
    gap: 32px;
    box-sizing: border-box;
    position: relative; /* Required for mobile menu positioning */
}

/* Hide top nav when in left-only mode */
.nav-display-left-only nav {
    display: none;
}

/* Add header border back for left-only mode (since there's no top nav) */
.nav-display-left-only .header-container {
    border-bottom: 0.5px solid var(--rhg-grey-lightest);
}

/* Adjust page container for left-only mode - no special margin needed since header is no longer fixed */

.hamburger-button {
    display: none;
    font-size: 24px;
    background: none;
    border: none;
    color: var(--rhg-deep-black);
    cursor: pointer;
    padding: 10px;
    margin: 0;
    min-width: 44px;
    min-height: 44px;
    flex-shrink: 0;
    -webkit-tap-highlight-color: transparent;
    touch-action: manipulation;
}

.hamburger-button:focus {
    outline: 2px solid var(--rhg-blue-medium);
    outline-offset: 2px;
    border-radius: 4px;
}

.nav-item {
    position: relative;
    margin-right: 0;
    font-size: 16px;
    font-weight: 500;
    font-family: var(--font-family-main);
    color: #0a0a19;
    text-decoration: none;
    cursor: pointer;
    height: 54px;
    display: flex;
    align-items: center;
    padding: 15px 0;
    box-sizing: border-box;
    white-space: nowrap;
}

.nav-item:hover {
    color: #0078ad;
}

a.nav-item {
    font-size: 16px;
    font-weight: 500;
    font-family: var(--font-family-main);
    color: #0a0a19;
    text-decoration: none;
    height: 54px;
    display: flex;
    align-items: center;
    padding: 15px 0;
    box-sizing: border-box;
    white-space: nowrap;
}

a.nav-item.active::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 6px;
    background-color: #0078ad;
}

.nav-item span {
    display: block;
    font-size: 16px;
    font-weight: 500;
    font-family: var(--font-family-main);
}

/* Dropdown indicator for nav items */
.nav-item.dropdown-item {
    display: flex;
    align-items: center;
    gap: 4px;
}

.nav-item.dropdown-item::after {
    content: '';
    width: 16px;
    height: 16px;
    background-image: url("data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iMTYiIGhlaWdodD0iMTYiIHZpZXdCb3g9IjAgMCAxNiAxNiIgZmlsbD0ibm9uZSIgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIj4KPHBhdGggZD0iTTQgNkw4IDEwTDEyIDYiIHN0cm9rZT0iIzBhMGExOSIgc3Ryb2tlLXdpZHRoPSIyIiBzdHJva2UtbGluZWNhcD0icm91bmQiIHN0cm9rZS1saW5lam9pbj0icm91bmQiLz4KPC9zdmc+");
    background-repeat: no-repeat;
    background-position: center;
    background-size: contain;
}

/* Dropdown styles */
.dropdown {
    position: absolute;
    top: 100%;
    left: 0;
    background-color: var(--rhg-crisp-white);
    border: 1px solid var(--rhg-grey-light);
    border-radius: 4px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    display: none;
    min-width: 200px;
    z-index: 1000;
}

.nav-item:hover .dropdown {
    display: block;
}

.dropdown a {
    display: block;
    padding: 10px 15px;
    color: var(--rhg-deep-black);
    text-decoration: none;
    border-bottom: 1px solid var(--rhg-grey-lightest);
    font-size: 18px;
    font-weight: 600;
    font-family: var(--font-family-main);
}

.dropdown a:last-child {
    border-bottom: none;
}

.dropdown a:hover {
    background-color: var(--rhg-blue-lightest);
    color: var(--rhg-blue-dark);
}

/* Mobile menu - unified top and left navigation */
.mobile-menu {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background-color: var(--rhg-crisp-white);
    border-top: 1px solid var(--rhg-grey-light);
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    flex-direction: column;
    z-index: 1000;
    max-height: 70vh;
    overflow-y: auto;
}

.mobile-menu.show {
    display: flex;
}

/* Mobile navigation items */
.mobile-nav-item {
    margin: 0;
    border-bottom: 1px solid var(--rhg-grey-lightest);
}

.mobile-nav-item:last-child {
    border-bottom: none;
}

.mobile-nav-link {
    font-size: 18px;
    font-weight: 600;
    font-family: var(--font-family-main);
    color: var(--rhg-deep-black);
    text-decoration: none;
    display: block;
    padding: 15px 20px;
    transition: background-color 0.2s ease;
    min-height: 44px;
    -webkit-tap-highlight-color: transparent;
}

.mobile-nav-link:hover {
    background-color: var(--rhg-blue-lightest);
}

.mobile-nav-item.active {
    border-left: 6px solid var(--rhg-deep-black);
    background-color: var(--rhg-blue-lightest);
}

/* Mobile top nav title for dropdowns */
.mobile-nav-title {
    font-size: 18px;
    font-weight: 600;
    font-family: var(--font-family-main);
    color: var(--rhg-deep-black);
    display: block;
    padding: 15px 20px;
    cursor: pointer;
    border-bottom: 1px solid var(--rhg-grey-lightest);
    min-height: 44px;
    -webkit-tap-highlight-color: transparent;
}

.mobile-nav-title:hover {
    background-color: var(--rhg-blue-lightest);
}

/* Mobile dropdown styles */
.mobile-dropdown {
    display: none;
    background-color: var(--rhg-neutral-grey);
}

.mobile-dropdown.show {
    display: block;
}

.mobile-dropdown-link {
    font-size: 16px;
    font-weight: 400;
    font-family: var(--font-family-main);
    color: var(--rhg-deep-black);
    text-decoration: none;
    display: block;
    padding: 12px 40px;
    border-bottom: 1px solid var(--rhg-grey-lightest);
    min-height: 44px;
    -webkit-tap-highlight-color: transparent;
}

.mobile-dropdown-link:hover {
    background-color: var(--rhg-blue-lightest);
}

/* Separator between top and left nav sections */
.mobile-nav-separator {
    height: 2px;
    background-color: var(--rhg-grey-medium);
    margin: 0;
}

/* Mobile left navigation sections - borders removed for cleaner appearance */

.mobile-section-title {
    font-size: 14px;
    font-weight: 700;
    font-family: var(--font-family-main);
    color: var(--rhg-grey-dark);
    text-transform: uppercase;
    padding: 12px 20px 8px 20px;
    background-color: var(--rhg-neutral-grey);
    letter-spacing: 0.5px;
}

.mobile-left-nav-link {
    font-size: 16px;
    font-weight: 400;
    padding-left: 30px;
}

/* Mobile subsections - 4th level navigation */
.mobile-subsection {
    border-left: 3px solid var(--rhg-blue-light);
    margin-left: 20px;
}

.mobile-subsection-link {
    font-size: 14px;
    font-weight: 400;
    padding-left: 40px;
    color: var(--rhg-grey-dark);
}

/*==================================================
 * 5. LEFT NAVIGATION
 *================================================== */
.left-nav-container {
    width: 240px;
    min-height: calc(100vh - var(--header-height) - var(--navbar-height));
    background-color: white; /* White background when combined with global nav */
    border-right: 0.5px solid var(--rhg-grey-lightest);
    overflow-y: auto;
    box-sizing: border-box;
    flex-shrink: 0;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    /* Sticky positioning - will stick to top of viewport when scrolling past header */
    position: sticky;
    top: 0;
    align-self: flex-start;
    z-index: 1;
    /* When sticky, fill full viewport height */
    height: 100vh;
}

/* Left-only mode: use light grey background */
.nav-display-left-only .left-nav-container {
    background-color: #f4f8f9;
}

/* Standalone variant: enhanced left nav for standalone use (left-only mode) */
.left-nav-container.standalone-variant {
    width: 300px;
    background-color: #f4f8f9;
    border-right: 0.5px solid var(--rhg-grey-lightest);
}

/* Adjust page container margin for standalone variant */
.page-container.with-left-nav .left-nav-container.standalone-variant ~ .content-container,
.page-container.with-left-nav.standalone-variant-active {
    margin-left: 300px;
}

/* Standalone variant: enhanced section title styling */
.left-nav-container.standalone-variant .left-nav-section-title {
    font-size: 12px;
    font-weight: 500;
    color: var(--rhg-grey-medium);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    padding: 16px 12px 0 12px;
    margin-bottom: 8px;
}

/* Standalone variant: collapsible main nav items (products/dashboards) */
.left-nav-container.standalone-variant .left-nav-item.main-collapsible {
    font-size: 18px;
    font-weight: 600;
    padding: 12px 12px;
    height: 48px;
    min-height: 48px;
    display: flex;
    align-items: center;
    gap: 16px;
}

.left-nav-container.standalone-variant .left-nav-item.main-collapsible .collapse-icon {
    font-size: 8px;
    transition: transform 0.2s ease;
}

.left-nav-container.standalone-variant .left-nav-item.main-collapsible.collapsed .collapse-icon {
    transform: rotate(-90deg);
}

/* Standalone variant: subsection items with left border */
.left-nav-container.standalone-variant .left-nav-subsections {
    padding-left: 12px;
}

.left-nav-container.standalone-variant .left-nav-subsections .left-nav-item {
    border-left: 0.5px solid var(--rhg-grey-lightest);
    padding-left: 24px;
    font-size: 16px;
    font-weight: 400;
    height: 32px;
    min-height: 32px;
}

/* Standalone variant: active state with blue left border and background */
.left-nav-container.standalone-variant .left-nav-subsections .left-nav-item.active {
    background-color: var(--rhg-pastel-blue);
    border-left: 4px solid var(--rhg-blue-medium);
    color: var(--rhg-blue-medium);
    font-weight: 700;
}

/* Standalone variant: footer styling */
.left-nav-container.standalone-variant .left-nav-footer {
    padding: 12px 12px 24px 12px;
}

.left-nav-container.standalone-variant .left-nav-footer-item {
    padding: 12px 4px;
    gap: 12px;
    font-size: 16px;
    font-weight: 600;
}

.left-nav-content {
    padding: 24px 12px 0 12px;
    flex: 1;
}

/* Left navigation footer */
.left-nav-footer {
    padding: 0 0 24px 0;
    display: flex;
    flex-direction: column;
    gap: 10px;
    align-items: center;
    justify-content: center;
    width: 100%;
}

.left-nav-footer-item {
    display: flex;
    align-items: center;
    gap: 4px;
    padding: 0 16px;
    width: 100%;
    box-sizing: border-box;
    font-family: var(--font-family-main);
    font-size: 15px;
    font-weight: 500;
    color: var(--rhg-deep-black);
    text-decoration: none;
}

.left-nav-footer-item:hover {
    color: var(--rhg-blue-medium);
}

.left-nav-footer-links {
    display: flex;
    align-items: center;
    padding: 0 16px;
    width: 100%;
    box-sizing: border-box;
    font-family: var(--font-family-main);
    font-size: 16px;
    font-weight: 400;
    color: var(--rhg-deep-black);
    height: 21px;
}

.left-nav-footer-copyright {
    display: flex;
    align-items: center;
    padding: 16px 16px 0 16px;
    width: 100%;
    box-sizing: border-box;
    font-family: var(--font-family-main);
    font-size: 16px;
    font-weight: 400;
    color: var(--rhg-deep-black);
    gap: 10px;
}

.left-nav-section {
    margin-bottom: 16px;
    position: relative;
}

/* Consistent 16px gap between sections */
.left-nav-section + .left-nav-section {
    margin-top: 16px;
}

/* Don't add extra spacing for sections without titles (like the first overview section) */
.left-nav-section:not(:first-child) .left-nav-section-title:empty + .left-nav-items {
    margin-top: 0;
    padding-top: 0;
}

.left-nav-section:not(:first-child) .left-nav-section-title:empty {
    display: none;
}


.left-nav-section-title {
    font-family: var(--font-family-main);
    font-size: 12px;
    font-weight: 500;
    color: var(--rhg-grey-medium);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 0;
    padding: 16px 16px 0 16px;
    min-height: 20px;
    box-sizing: border-box;
}

.left-nav-section-title.expandable {
    cursor: pointer;
    display: flex;
    align-items: center;
    padding: 8px 24px;
    transition: color 0.2s ease;
}

.left-nav-section-title.expandable:hover {
    color: var(--rhg-blue-medium);
}

.left-nav-expand-icon {
    margin-right: 8px;
    font-size: 12px;
    color: var(--rhg-grey-medium);
    /* Removed transform transition for better performance */
}

/* Use CSS content change instead of rotation for better performance */
.left-nav-section.collapsed .left-nav-expand-icon::before,
.left-nav-expand-icon::before {
    content: '▶';
}

.left-nav-section.expanded .left-nav-expand-icon::before {
    content: '▼';
}

.left-nav-section.collapsed .left-nav-items {
    display: none;
}

.left-nav-items {
    margin-left: 0;
}

.left-nav-item {
    display: flex;
    height: 40px;
    padding: 8px 16px;
    margin-bottom: 0;
    font-family: var(--font-family-main);
    font-size: 15px;
    font-weight: 400;
    color: #0a0a19;
    text-decoration: none;
    align-items: center;
    gap: 4px;
    transition: background-color 0.2s ease;
    box-sizing: border-box;
    width: 100%;
    min-height: 40px;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    text-rendering: optimizeLegibility;
    position: relative;
}

/* Expandable product items (with nested dashboards) */
.left-nav-item.expandable {
    cursor: pointer;
}

/* Product items should not show active highlighting - only their subsections should */
.left-nav-item.expandable.active {
    background-color: transparent;
    font-weight: 500;
}

.left-nav-item.expandable.active::before {
    display: none;
}

.left-nav-item.expandable.active:hover {
    background-color: var(--rhg-blue-lightest);
}

.left-nav-item-expand-icon {
    margin-left: auto;
    margin-right: 0;
    font-size: 12px;
    color: var(--rhg-grey-medium);
    cursor: pointer;
    flex-shrink: 0;
}

.left-nav-item-expand-icon::before {
    content: '';
    width: 16px;
    height: 16px;
    background-image: url("data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iMTYiIGhlaWdodD0iMTYiIHZpZXdCb3g9IjAgMCAxNiAxNiIgZmlsbD0ibm9uZSIgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIj4KPHBhdGggZD0iTTQgNkw4IDEwTDEyIDYiIHN0cm9rZT0iIzBhMGExOSIgc3Ryb2tlLXdpZHRoPSIyIiBzdHJva2UtbGluZWNhcD0icm91bmQiIHN0cm9rZS1saW5lam9pbj0icm91bmQiLz4KPC9zdmc+");
    background-repeat: no-repeat;
    background-position: center;
    background-size: contain;
    display: inline-block;
}

.left-nav-item.expanded .left-nav-item-expand-icon::before {
    transform: rotate(180deg);
}

.left-nav-item:hover {
    background-color: var(--rhg-blue-lightest);
    color: var(--rhg-deep-black);
    text-decoration: none;
}

.left-nav-item.active {
    background-color: #cce4ef;
    color: #0a0a19;
    font-weight: 700;
}

.left-nav-item.active::before {
    content: '';
    position: absolute;
    left: 0;
    top: 0;
    bottom: 0;
    width: 4px;
    background-color: #0078ad;
}

.left-nav-item.active:hover {
    background-color: #cce4ef;
}

/* Left navigation separator */
.left-nav-separator {
    height: 32px;
    width: 100%;
    position: relative;
    margin: 0;
    display: flex;
    align-items: center;
    justify-content: center;
}

.left-nav-separator::after {
    content: '';
    width: calc(100% - 32px);
    height: 0.5px;
    background-color: #c9cbcb;
}

/* 4th level navigation - subsections */
.left-nav-subsections {
    margin-left: 16px;
    margin-top: 0;
    border-left: none;
    padding-left: 0;
}

.left-nav-subsection {
    display: flex;
    height: 32px;
    padding: 8px 8px 8px 8px;
    margin-bottom: 0;
    font-family: var(--font-family-main);
    font-size: 16px;
    font-weight: 400;
    color: #0a0a19;
    text-decoration: none;
    align-items: center;
    transition: background-color 0.2s ease;
    box-sizing: border-box;
    min-height: 32px;
    width: 100%;
    position: relative;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    text-rendering: optimizeLegibility;
    border-left: 0.5px solid #c9cbcb;
}

.left-nav-subsection::before {
    content: '';
    position: absolute;
    left: 0;
    top: 0;
    bottom: 0;
    width: 0.5px;
    background-color: var(--rhg-grey-light);
}

.left-nav-subsection:hover {
    background-color: var(--rhg-blue-lightest);
    color: var(--rhg-deep-black);
    text-decoration: none;
}

.left-nav-subsection.active {
    background-color: #cce4ef;
    color: #0a0a19;
    font-weight: 700;
}

.left-nav-subsection.active::before {
    content: '';
    position: absolute;
    left: 0;
    top: 0;
    bottom: 0;
    width: 4px;
    background-color: #0078ad;
}

.left-nav-subsection.active:hover {
    background-color: #cce4ef;
    color: #0a0a19;
}

.left-nav-subhead {
    font-family: var(--font-family-main);
    font-size: 12px;
    font-weight: 500;
    color: var(--rhg-grey-dark);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 0;
    padding: 16px 16px 8px 16px;
    min-height: 20px;
    box-sizing: border-box;
}

/*==================================================
 * 5B. CONTENT ACTION BAR
 *================================================== */
.content-action-bar {
    position: absolute;
    top: var(--header-height, 54px);
    left: 0;
    right: 0;
    background-color: white;
    border-bottom: 1px solid var(--rhg-grey-lightest);
    padding: 24px;
    display: flex;
    align-items: center;
    gap: 24px;
    z-index: 4;
    box-sizing: border-box;
}

/* Adjust top position when top nav is present */
.content-action-bar.with-top-nav {
    top: calc(var(--header-height, 54px) + var(--navbar-height, 48px));
}

/* Sticky variant */
.content-action-bar.sticky {
    position: sticky;
    top: 0;
}

/* Action bar items */
.content-action-bar-item {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.content-action-bar-item label {
    font-family: var(--font-family-main);
    font-size: 16px;
    font-weight: 700;
    color: var(--rhg-deep-black);
}

/* Search field */
.content-action-bar-search {
    flex: 1;
    max-width: 400px;
}

.content-action-bar-search input {
    width: 100%;
    padding: 8px 12px;
    font-family: var(--font-family-main);
    font-size: 16px;
    border: 1px solid var(--rhg-grey-lightest);
    box-sizing: border-box;
}

/* Dropdown field */
.content-action-bar-dropdown select {
    min-width: 160px;
    padding: 4px 8px;
    font-family: var(--font-family-main);
    font-size: 16px;
    border: 1px solid var(--rhg-grey-lightest);
    box-sizing: border-box;
    background-color: white;
}

/* Mobile responsive */
@media (max-width: 768px) {
    .content-action-bar {
        flex-wrap: wrap;
        gap: 16px;
        padding: 16px;
    }
    
    .content-action-bar-search {
        flex: 1 1 100%;
        max-width: none;
    }
    
    .content-action-bar-item {
        flex: 1 1 calc(50% - 8px);
        min-width: 150px;
    }
}

/*==================================================
 * 6. MAIN CONTENT STYLES
 *================================================== */
.page-container {
    margin: 0;
    width: 100%;
    min-height: calc(100vh - var(--header-height) - var(--navbar-height));
    position: relative;
    display: flex;
    /* Ensure consistent rendering to prevent flicker */
    will-change: auto;
    /* Removed transform: translateZ(0) to avoid stacking context issues with tooltips */
}

/* Content wrapper for consistent formatting */
.page-content {
    max-width: calc(100vw - 400px); /* Reserve space for potential left nav + margins */
    padding: 2rem;
    margin: 0 auto;
    box-sizing: border-box;
    position: relative;
    z-index: 10; /* Higher than sidebar (z-index: 1) so tooltips can appear above it */
    isolation: isolate; /* Create new stacking context */
    /* Removed heavy transitions for better performance */
}

/* Pages without left navigation - centered content with consistent margins */
.page-container:not(.with-left-nav) .page-content {
    max-width: 1200px; /* Reasonable max width for readability */
    margin-left: 120px; /* Consistent left offset to match left-nav spacing */
    margin-right: auto;
}

/* Pages with left navigation - flexbox layout */
.page-container.with-left-nav {
    display: flex;
}

.page-container.with-left-nav .page-content {
    flex: 1;
    max-width: none;
    margin-left: 0;
    padding-left: 24px;
    padding-right: 2rem;
}

/* Navigation display mode overrides */
.nav-display-top-only .left-nav-container {
    display: none;
}

.nav-display-top-only .page-container.with-left-nav {
    display: block; /* Override flexbox when no left nav */
}

.nav-display-top-only .page-container.with-left-nav .page-content {
    max-width: 1200px;
    margin-left: 120px;
    margin-right: auto;
    padding-left: 2rem;
}

/* Left-only mode adjustments */
.nav-display-left-only .page-container .page-content {
    margin-left: 0;
    padding-left: 24px;
}

/*==================================================
 * 7. ALERT/NOTIFICATION STYLES
 *================================================== */
.flash-messages {
    margin-bottom: 2rem;
}

.alert {
    padding: 12px 16px;
    margin-bottom: 1rem;
    border-radius: 4px;
    position: relative;
}

/* Info boxes */
.info-box, .content-callout {
    margin-bottom: 30px;
    line-height: 1.2;
    font-size: 14px;
    background-color: var(--rhg-pastel-blue);
    padding: 15px;
    border-radius: 4px;
    border-left: 4px solid var(--rhg-blue-medium);
    font-family: var(--font-family-secondary);
}

/* Old metric callout styles removed - replaced by dashboard component styles below */

.metric-callouts-container {
    display: flex;
    flex-wrap: nowrap;
    gap: 20px;
    margin: 10px;
    justify-content: flex-start;
    overflow-x: auto;
}

/* Info icon styles */
.info-icon {
    display: inline-block;
    width: 14px;
    height: 14px;
    line-height: var(--rhg-sys-icon-size-default);
    font-size: 12px;
    font-weight: bold;
    margin-left: 8px;
    cursor: help;
    position: relative;
    vertical-align: middle;
}



/* Tooltip for info icons */
.info-tooltip {
    position: absolute;
    bottom: 25px;
    left: 50%;
    transform: translateX(-50%);
    background-color: white;
    color: black;
    border: 1px solid #ccc;
    padding: 8px 12px;
    border-radius: 0;
    font-family: 'Roboto', sans-serif;
    font-size: 13px;
    font-weight: normal;
    white-space: nowrap;
    z-index: 9999;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s ease;
    max-width: 300px;
    white-space: normal;
    width: max-content;
    text-align: left;
}

.info-tooltip::after {
    content: '';
    position: absolute;
    top: 100%;
    left: 50%;
    transform: translateX(-50%);
    border: 5px solid transparent;
    border-top-color: #ccc;
}

.info-tooltip::before {
    content: '';
    position: absolute;
    top: 100%;
    left: 50%;
    transform: translateX(-50%);
    border: 4px solid transparent;
    border-top-color: white;
    z-index: 1;
    margin-top: -1px;
}

.info-icon:hover .info-tooltip {
    opacity: 1;
}

/* Filter label with info icon styles */
.filter-label-with-info {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 0px;
    overflow: visible;  /* Allow tooltips to overflow */
}

.filter-label-text {
    font-family: var(--font-family-main);
    font-size: 14px;
    font-weight: 700;
    color: var(--rhg-sys-color-text-default);
}

.filter-label-with-info .info-icon {
    position: relative;
    cursor: pointer;
}

/* Elevate z-index on hover so tooltip appears above sibling filter elements */
.filter-label-with-info .info-icon:hover {
    z-index: 10000;
}

.filter-label-with-info .info-icon img {
    width: 14px;
    height: 14px;
}

.alert-success {
    background-color: var(--rhg-green-lightest);
    border: 1px solid var(--rhg-green-light);
    color: var(--rhg-green-darkest);
}

.alert-info {
    background-color: var(--rhg-blue-lightest);
    border: 1px solid var(--rhg-blue-light);
    color: var(--rhg-blue-darkest);
}

.alert-warning {
    background-color: var(--rhg-yellow-lightest);
    border: 1px solid var(--rhg-yellow-light);
    color: var(--rhg-yellow-darkest);
}

.alert-error {
    background-color: var(--rhg-orange-lightest);
    border: 1px solid var(--rhg-orange-light);
    color: var(--rhg-orange-darkest);
}

.alert-dismissible .close {
    position: absolute;
    top: 8px;
    right: 12px;
    background: none;
    border: none;
    font-size: 20px;
    cursor: pointer;
    color: inherit;
    opacity: 0.7;
}

.alert-dismissible .close:hover {
    opacity: 1;
}

/*==================================================
 * 8. UTILITY CLASSES
 *================================================== */
.welcome-section {
    text-align: center;
    margin: 4rem 0;
}

.welcome-section h1 {
    font-size: 2.5rem;
    margin-bottom: 1rem;
    color: var(--rhg-deep-black);
}

.welcome-section p {
    font-size: 1.1rem;
    color: var(--rhg-grey-dark);
    margin-bottom: 1rem;
}

.btn {
    display: inline-block;
    padding: 10px 20px;
    text-decoration: none;
    border-radius: 0px;
    font-weight: 500;
    cursor: pointer;
    border: none;
    font-family: var(--font-family-main);
}

.btn-primary {
    background-color: var(--rhg-blue-medium);
    color: var(--rhg-crisp-white);
}

.btn-primary:hover {
    background-color: var(--rhg-blue-dark);
}

.btn-secondary {
    background-color: var(--rhg-grey-light);
    color: var(--rhg-deep-black);
}

.btn-secondary:hover {
    background-color: var(--rhg-grey-medium);
}

/* Content utilities */
.content-list-item {
    margin-bottom: 10px;
    padding-left: 17px;
    font-family: var(--font-family-secondary);
}

.page-header {
    font-size: 2rem;
    font-weight: 700;
    color: var(--rhg-deep-black);
    margin-bottom: 1rem;
    font-family: var(--font-family-main);
}

.page-subhead {
    font-size: 1.1rem;
    color: var(--rhg-grey-dark);
    margin-bottom: 1.5rem;
    font-family: var(--font-family-secondary);
}

/* Default paragraph styling */
p {
    font-family: var(--font-family-secondary);
    font-weight: 400;
    font-size: 1rem;
    color: var(--rhg-deep-black);
    line-height: 1.3;
    margin-top: 0;
    margin-bottom: 1rem;
}

/* Default header styling with reduced margins */
h1, h2, h3, h4, h5, h6 {
    font-family: var(--font-family-main);
    color: var(--rhg-deep-black);
    margin: 0 0 0.5rem 0;
    padding: 0;
    line-height: 1.2;
}

h1 {
    font-size: 2rem;
    font-weight: 700;
}

h2 {
    font-size: 1.5rem;
    font-weight: 700;
}

h3 {
    font-size: 1.25rem;
    font-weight: 700;
}

h4 {
    font-size: 1.125rem;
    font-weight: 600;
}

h5 {
    font-size: 1rem;
    font-weight: 600;
}

h6 {
    font-size: 0.875rem;
    font-weight: 600;
}

/* About section paragraphs - remove bottom margin from last paragraph */
.about-section p:last-child {
    margin-bottom: 0;
}

/* Metadata section specific styling */
.metadata-container p {
    margin: 0;
    line-height: normal;
}


/*==================================================
 * 9. RESPONSIVE DESIGN
 *================================================== */
@media (max-width: 768px) {
    /* Home button size on mobile */
    .home-button {
        font-size: 28px !important;
    }
    
    /* Button sizing on mobile */
    .rhg-button {
        font-size: 14px !important;
        padding: 10px !important;
    }
    
    /* Nav item text size on mobile */
    .nav-item span {
        font-size: 14px !important;
    }
    
    /* Hide metadata items on mobile */
    .metadata-item-small {
        display: none !important;
    }
    
    .hamburger-button {
        display: block;
    }
    
    /* Hide nav items on mobile except in mobile menu */
    .nav-item:not(.mobile-menu .nav-item) {
        display: none;
    }
    
    /* Improve nav bar spacing and layout on mobile */
    nav:not(.rhg-tabs__nav) {
        padding: 0 12px;
        gap: 0;
        justify-content: flex-start;
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
        scrollbar-width: none; /* Firefox */
        -ms-overflow-style: none; /* IE and Edge */
    }
    
    /* Keep nav items visible in rhg-navbar (used on homepage) - must come after general nav rules */
    nav.rhg-navbar .nav-item,
    nav.rhg-navbar .rhg-dropdown .nav-item,
    nav.rhg-navbar .rhg-dropdown-toggle.nav-item {
        display: flex !important;
    }
    
    nav.rhg-navbar .rhg-dropdown {
        display: inline-block !important;
    }
    
    nav.rhg-navbar {
        height: var(--navbar-height, 54px) !important;
        min-height: var(--navbar-height, 54px) !important;
        flex-wrap: nowrap;
        gap: 16px !important;
        padding: 0 16px !important;
        align-items: center;
        overflow-x: auto !important;
        -webkit-overflow-scrolling: touch;
        scrollbar-width: none;
    }
    
    nav.rhg-navbar::-webkit-scrollbar {
        display: none;
    }
    
    nav.rhg-navbar .nav-item,
    nav.rhg-navbar .rhg-dropdown-toggle {
        white-space: nowrap;
        font-size: 14px;
        flex-shrink: 0;
    }
    
    /* Dropdown menu on mobile - use fixed positioning to escape overflow clipping */
    nav.rhg-navbar .rhg-dropdown-menu {
        position: fixed;
        z-index: 10000;
    }
    
    nav.rhg-navbar .rhg-dropdown.open .rhg-dropdown-menu {
        display: block !important;
        opacity: 1 !important;
        visibility: visible !important;
        transform: none !important;
    }
    
    nav:not(.rhg-tabs__nav)::-webkit-scrollbar {
        display: none; /* Chrome, Safari, Opera */
    }
    
    /* Ensure hamburger button stays visible and accessible */
    .hamburger-button {
        position: sticky;
        left: 0;
        background-color: #cce4ef;
        z-index: 10;
    }
    
    /* Hide left navigation on mobile - it's accessible via mobile menu */
    .left-nav-container {
        display: none !important;
    }
    
    /* Reset page layout for mobile */
    .page-container,
    .page-container.with-left-nav {
        display: block !important;
        margin-left: 0 !important;
    }
    
    .page-container .page-content,
    .page-container.with-left-nav .page-content {
        padding: 1rem;
        max-width: none;
        margin-left: 0;
        margin-right: 0;
        padding-left: 1rem;
        padding-right: 1rem;
        flex: none;
    }
    
    /* Ensure consistent mobile layout regardless of left nav */
    .page-container:not(.with-left-nav) .page-content {
        margin-left: 0;
    }
    
    .header-container {
        padding: 0 40px 0 0;
        gap: 0.5rem;
    }
    
    .title-container {
        flex: 0 0 auto;
        min-width: 0;
    }
    
    .home-button {
        font-size: 20px;
    }
    
    .logo-container {
        height: 54px;
        max-width: 54px;
    }
    
    /* Divider bar removed - no mobile styles needed */
    
    /* Hide left navigation on mobile */
    .left-nav-container {
        display: none;
    }
    
    .page-container.with-left-nav {
        margin-left: 0;
    }
    
    .page-container.with-left-nav .page-content {
        padding-left: 1rem;
        padding-right: 1rem;
    }
    
    /* Metric callouts mobile responsiveness */
    .metric-callouts-container {
        flex-wrap: nowrap;
        overflow-x: auto;
        justify-content: flex-start;
        gap: 8px;
    }
    
    .metric-callout {
        margin: 0;
        min-width: 120px;
        flex-shrink: 0;
    }
    
    /* Main content responsive padding for mobile */
    .main-content {
        padding: 0.5rem 1rem 2rem 1rem !important;
        width: 100% !important;
        box-sizing: border-box !important;
    }
}

/* Tablet responsive styles */
@media (max-width: 1024px) and (min-width: 769px) {
    .main-content {
        padding: 0.5rem 2rem 3rem 2rem !important;
        width: 100% !important;
        box-sizing: border-box !important;
    }
    
    /* Stack charts on tablet when they get too cramped */
    .charts-row {
        gap: 24px !important;
    }
    
    .charts-row > * {
        min-width: 300px; /* Minimum width before stacking */
    }
}

/* Stack charts on smaller tablets and large phones */
@media (max-width: 900px) {
    .charts-row {
        flex-direction: column !important;
        gap: 24px !important;
    }
    
    .charts-row > * {
        flex: none !important;
        width: 100% !important;
        min-width: 0 !important;
    }
    
    /* Adjust BAN callouts spacing on smaller screens */
    .ban-callouts-row {
        gap: 16px !important;
    }
}

@media (max-width: 480px) {
    .home-button {
        font-size: 16px;
    }
    
    .nav-link {
        font-size: 0.9rem;
    }
    
    .welcome-section h1 {
        font-size: 2rem;
    }
    
    /* Extra small screens - even more compact padding */
    .main-content {
        padding: 0.5rem 0.5rem 2rem 0.5rem !important;
    }
    
    /* Ensure tables are fully responsive on small screens */
    .table-scroll-container {
        margin-left: -0.5rem !important;
        margin-right: -0.5rem !important;
        width: calc(100% + 1rem) !important;
    }
    
    /* Stack charts vertically on small screens */
    .charts-row {
        flex-direction: column !important;
        gap: 24px !important;
    }
    
    .charts-row > * {
        flex: none !important;
        width: 100% !important;
    }
}

/*==================================================
 * 10. LOADING OVERLAY STYLES
 *================================================== */


/* CSS-Only Loading overlay - auto-hide after 2 seconds */
#global-loading-overlay {
    /* Animation will override inline styles */
    animation: auto-fade-out 0.5s ease-out forwards !important;
}

.loading-spinner {
    animation: pulse 1.5s ease-in-out infinite;
}

@keyframes pulse {
    0% { opacity: 1; }
    50% { opacity: 0.6; }
    100% { opacity: 1; }
}

@keyframes auto-fade-out {
    0%, 70% { 
        opacity: 1; 
        visibility: visible;
    }
    100% { 
        opacity: 0; 
        visibility: hidden;
        pointer-events: none;
    }
}
/*==================================================
 * 11. DASHBOARD COMPONENT STYLES
 *================================================== */

/* ========================================
 * 11.1 PAGE ELEMENTS
 * ======================================== */
.page-header {
    font-family: var(--font-family-main);
    font-weight: 700;
    font-size: 24px;
    color: var(--rhg-deep-black);
    line-height: normal;
    margin: 0;
}

/* Removed .page-header::after border - not needed in dashboard layout */

.page-subhead {
    margin-top: 2px;
    margin-bottom: 2px;
    line-height: 1.1;
    font-size: var(--font-size-page-subhead);
    color: var(--rhg-deep-black);
    font-weight: var(--font-weight-normal);
    font-family: var(--font-family-secondary);
}

.section-header {
    font-family: var(--font-family-main);
    font-weight: 700;
    font-size: 20px;
    color: var(--rhg-deep-black);
    margin-bottom: 16px;
    margin-top: 10px;
}

/* ========================================
 * 11.2 CHART COMPONENTS
 * ======================================== */
.chart-title-container {
    text-align: left;
    margin-top: 10px;
    margin-bottom: 0;

    font-family: var(--font-family-secondary);
}

.chart-title {
    font-family: var(--font-family-main);
    font-weight: 700;
    font-size: 16px;
    margin: 0 0 0 0;
    text-align: left;
    color: var(--rhg-deep-black);
    line-height: normal;
}

.chart-subtitle {
    font-family: var(--font-family-main);
    margin: 0 0 0 0;
    font-weight: 400;
    font-size: 14px;
    text-align: left;
    color: var(--rhg-deep-black);
    line-height: normal;
    padding-bottom: 5px;
}

/* ========================================
 * 11.3 METADATA & INFO COMPONENTS
 * ======================================== */
.metadata-container {
    display: flex;
    flex-wrap: nowrap;
    gap: 20px;
    margin-bottom: 32px;
    padding: 16px 0px 0px 0px;
    align-items: flex-start;
}

/* Responsive metadata container - wrap on narrow screens */
@media (max-width: 850px) {
    .metadata-container {
        flex-wrap: wrap;
        gap: 16px;
    }
    
    .metadata-item {
        min-width: calc(50% - 8px);
        max-width: none;
    }
}

@media (max-width: 480px) {
    .metadata-container {
        gap: 12px;
        padding: 12px;
    }
    
    .metadata-item {
        min-width: 100%;
        margin-right: 0;
    }
    
    .metadata-item:not(:last-child) {
        margin-right: 0;
        margin-bottom: 8px;
    }
}

.metadata-item {
    min-width: 100px;
    max-width: 275px;
    flex: 0 1 auto;
    position: relative;
}

.metadata-item:not(:last-child) {
    margin-right: 10px;
}

.metadata-label {
    font-size: 14px;
    color: #797C7D;
    display: block;
    margin-bottom: 4px;
    font-weight: normal;
}

.metadata-value {
    font-size: 16px;
    color: #0A0A19;
    font-weight: 600;
    line-height: 1.3;
}

/* Metadata interactive elements */
.metadata-item-wrapper {
    position: relative;
    display: flex;
    flex-direction: column;
}

.metadata-actions {
    display: flex;
    align-items: center;
    gap: 6px;
    margin-top: 4px;
}

.metadata-actions.positioned {
    position: absolute;
    top: 0;
    right: 0;
    margin-top: 0;
}

.metadata-icon {
    cursor: pointer;
    color: #666;
    font-size: 16px;
    padding: 2px;
    border-radius: 3px;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 20px;
    height: 20px;
}

.metadata-icon:hover {
    color: #2c3e50;
    background-color: #f0f0f0;
}

.copy-icon {
    cursor: pointer;
    color: #666;
    padding: 2px;
    border-radius: 3px;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 20px;
    height: 20px;
}

.copy-icon.material-icons {
    font-size: 18px !important;
}

.copy-icon:hover {
    color: #2c3e50;
    background-color: #f0f0f0;
}

/* Material Icons styling */
.material-icons {
    font-family: 'Material Icons', 'Material Icons Outlined', 'Material Symbols Outlined', monospace;
    font-weight: normal;
    font-style: normal;
    font-size: 18px;
    line-height: 1;
    letter-spacing: normal;
    text-transform: none;
    display: inline-block;
    white-space: nowrap;
    word-wrap: normal;
    direction: ltr;
    font-feature-settings: 'liga';
    -webkit-font-feature-settings: 'liga';
    -webkit-font-smoothing: antialiased;
}

.jump-link {
    color: #1976d2;
    text-decoration: none;
    font-size: 12px;
    display: flex;
    align-items: center;
    gap: 3px;
    transition: color 0.2s ease;
}

.jump-link:hover {
    color: #1565c0;
    text-decoration: underline;
}

.down-arrow {
    font-size: 10px;
    animation: bounce 2s infinite;
}

@keyframes bounce {
    0%, 20%, 50%, 80%, 100% {
        transform: translateY(0);
    }
    40% {
        transform: translateY(-3px);
    }
    60% {
        transform: translateY(-1px);
    }
}

.external-link {
    color: var(--rhg-deep-black);
    font-weight: bold;
    text-decoration: underline;
    transition: color 0.2s ease;
}

.external-link:hover {
    color: var(--rhg-deep-black);
    text-decoration: underline;
}

/* ========================================
 * 11.4 METRIC CALLOUTS & HIGHLIGHTS
 * ======================================== */
.metric-callout {
    background-color: var(--rhg-crisp-white);
    border: 0.5px solid var(--rhg-grey-lightest);
    padding: 16px;
    text-align: left;
    margin: 0;
    flex: 0 0 200px;
    min-height: 80px;
    font-family: var(--font-family-main);
    position: relative;
    display: flex;
    flex-direction: column;
    justify-content: flex-start;
}

/* Metric callout color variations - only grey and white */
.metric-callout--default {
    background-color: var(--rhg-crisp-white);
    border: 0.5px solid var(--rhg-grey-lightest);
}

.metric-callout--filled {
    background-color: var(--rhg-neutral-grey); /* #f2f2f2 */
    border: none;
}

.metric-callout-title {
    font-family: var(--font-family-main);
    font-weight: 700;
    font-size: 16px;
    color: var(--rhg-deep-black);
    line-height: normal;
    margin: 0;
}

.metric-callout-value {
    font-family: var(--font-family-main);
    font-weight: 700;
    font-size: 40px;
    color: var(--rhg-deep-black);
    line-height: normal;
    margin: 0;
}

.metric-callout-subtitle {
    font-family: var(--font-family-main);
    font-weight: 400;
    font-size: 14px;
    color: var(--rhg-deep-black);
    line-height: normal;
    margin: 0;
    white-space: pre-line;
}

.metric-callout-unit {
    font-family: var(--font-family-main);
    font-weight: 400;
    font-size: 14px;
    color: var(--rhg-deep-black);
    line-height: normal;
    margin: 0;
}

.metric-callout-context {
    font-family: var(--font-family-main);
    font-weight: 400;
    font-size: 16px;
    color: var(--rhg-deep-black);
    line-height: normal;
    margin: 0;
}

/* Detailed metric callout - two-part design matching Figma */
.detailed-metric-callout {
    display: flex;
    align-items: flex-start;
    background-color: var(--rhg-crisp-white);
    border: 0.5px solid var(--rhg-grey-lightest);
    padding: 16px;
    gap: 32px;
    width: 75%;
    flex-shrink: 0;
}

/* Detailed metric callout color variations - only grey and white */
.detailed-metric-callout--default {
    background-color: var(--rhg-crisp-white);
    border: 0.5px solid var(--rhg-grey-lightest);
}

.detailed-metric-callout--filled {
    background-color: var(--rhg-neutral-grey); /* #f2f2f2 */
    border: none;
}

.detailed-metric-left {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    flex-shrink: 0;
}

.detailed-metric-value {
    font-family: var(--font-family-main);
    font-weight: 700;
    font-size: 40px;
    color: var(--rhg-deep-black);
    line-height: normal;
    margin: 0;
}

.detailed-metric-label {
    font-family: var(--font-family-main);
    font-weight: 400;
    font-size: 14px;
    color: var(--rhg-deep-black);
    line-height: normal;
    margin: 0;
}

.detailed-metric-explanation {
    font-family: var(--font-family-main);
    font-weight: 400;
    font-size: 16px;
    color: var(--rhg-deep-black);
    line-height: normal;
    flex: 1;
    display: flex;
    align-items: center;
}

/* Highlights container */
.highlights-container {
    display: flex;
    flex-direction: column;
    gap: 8px;
    margin-bottom: 32px;
}

/* Chart container - default to block layout to keep title and chart together */
.chart-container {
    display: block;
    margin-bottom: 32px;
    margin-top: 0px;
    padding-top: 0px;
}

/* When chart-container is used for side-by-side charts, apply flex properties */
.chart-container.side-by-side {
    display: flex;
    gap: 30px;
    flex-wrap: wrap;
}

/* When chart-container is inside chart-row, make it flexible for row layouts */
.chart-row .chart-container {
    display: flex;
    flex-direction: column;
    flex: 1;
}

.chart-container > div {
    flex: 1;
    min-width: 300px;
}

/* Chart split layout for side-by-side visualizations */
.chart-row {
    display: flex;
    align-items: flex-start;
    gap: 20px;
    margin-bottom: 24px;
    width: 100%;
}

/* Available data cards */
.data-card {
    display: flex;
    align-items: flex-start;
    gap: 16px;
    padding: 0;
    margin-bottom: 0px;
    line-height: 1.2;
}

.data-card-content {
    flex: 1;
}

.data-card-title {
    font-size: 16px;
    font-weight: bold;
    color: var(--rhg-deep-black);
    margin: 0 0 4px 0;
    line-height: 1.2;
    font-family: var(--font-family-main);
}

.data-card-description {
    font-size: 16px;
    font-weight: normal;
    color: var(--rhg-deep-black);
    margin: 0;
    line-height: 1.2;
    font-family: var(--font-family-main);
}

/* Insights section */
.insights-container {
    padding-top: 10px;
    margin-top: 20px;
}

.insights-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 24px;
    margin-bottom: 32px;
}

.insight-card {
    padding: 16px 0;
    border-top: 2px solid #e0e0e0;
    border-radius: 0;
}

.insight-card a {
    display: block;
    transition: opacity 0.2s ease;
}

.insight-card a:hover {
    opacity: 0.8;
}

.insight-card a:hover .insight-title {
    color: #0078AD;
}

.insight-card a:hover .insight-arrow {
    color: var(--rhg-blue-medium);
}

.insight-content {
    position: relative;
    padding-right: 40px; /* Space for arrow */
    min-height: 80px; /* Minimum height for arrow positioning */
}

.insight-title {
    font-size: 16px;
    font-weight: bold;
    color: var(--rhg-deep-black);
    margin: 0 0 8px 0;
    line-height: 1.2;
    font-family: var(--font-family-main);
}

.insight-description {
    font-size: 14px;
    font-weight: normal;
    color: var(--rhg-deep-black);
    margin: 0;
    line-height: 1.2;
    font-family: var(--font-family-main);
}

.insight-arrow {
    position: absolute;
    bottom: 0;
    right: 0;
    color: var(--rhg-deep-black);
    font-size: 20px;
    cursor: pointer;
    transition: color 0.2s ease;
}

.material-icons.insight-arrow {
    font-family: 'Material Icons', 'Material Icons Outlined', 'Material Symbols Outlined', monospace !important;
}

.insight-content:not(a .insight-content) .insight-arrow:hover {
    color: var(--rhg-blue-medium);
}

/* Responsive layout for detailed callouts */
@media screen and (max-width: 768px) {
    .detailed-metric-callout {
        flex-direction: column;
        gap: 12px;
        padding: 16px;
    }
    
    .detailed-metric-left {
        min-width: auto;
        width: 100%;
    }
    
    .detailed-metric-value {
        font-size: 22px;
    }
    
    .chart-container {
        flex-direction: column;
        gap: 20px;
    }
    
    .chart-container > div {
        min-width: auto;
    }
    
    /* Make insights cards single column on mobile */
    .insights-grid {
        grid-template-columns: 1fr !important;
        gap: 12px !important;
    }
}

/* Tag components */
.tag {
    display: inline-block;
    border-radius: 8px;
    font-family: var(--font-family-main);
    font-weight: var(--font-weight-medium);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    white-space: nowrap;
}

.tag-small {
    font-size: 10px;
    padding: 2px 6px;
}

.tag-medium {
    font-size: 12px;
    padding: 4px 8px;
}

.tag-large {
    font-size: 14px;
    padding: 6px 12px;
}

.tag-neutral {
    background-color: var(--rhg-grey-lightest);
    color: var(--rhg-grey-darkest);
    border: 1px solid var(--rhg-grey-light);
}

.tag-success {
    background-color: var(--rhg-green-lightest);
    color: var(--rhg-green-darkest);
    border: 1px solid var(--rhg-green-medium);
}

.tag-warning {
    background-color: var(--rhg-yellow-lightest);
    color: var(--rhg-yellow-darkest);
    border: 1px solid var(--rhg-yellow-medium);
}

.tag-danger {
    background-color: var(--rhg-orange-lightest);
    color: var(--rhg-orange-darkest);
    border: 1px solid var(--rhg-orange-medium);
}

.tag-info {
    background-color: var(--rhg-blue-lightest);
    color: var(--rhg-blue-darkest);
    border: 1px solid var(--rhg-blue-medium);
}

/* Chart widget components */
.chart-widget {
    background-color: var(--rhg-crisp-white);
    border: 0.5px solid var(--rhg-grey-lightest);
    border-radius: 0;
}

.chart-widget-title {
    font-family: var(--font-family-main);
    font-weight: var(--font-weight-bold);
    font-size: 16px;
    color: var(--rhg-deep-black);
    line-height: 1.2;
}

.chart-widget-subtitle {
    font-family: var(--font-family-main);
    font-weight: var(--font-weight-normal);
    font-size: 14px;
    color: var(--rhg-deep-black);
    line-height: 1.3;
}

.chart-widget-note {
    font-family: var(--font-family-main);
    font-weight: var(--font-weight-normal);
    font-size: 12px;
    color: var(--rhg-deep-black);
    line-height: 1.2;
    margin: 8px 0 0 0;
}

/*==================================================
 * 12. FOOTER STYLES
 *================================================== */
.rhg-footer {
    width: 100%;
    background-color: transparent;
    margin-top: auto; /* Push footer to bottom if using flexbox */
    box-sizing: border-box;
    position: relative;
}

.rhg-footer::before {
    content: '';
    position: absolute;
    top: 0;
    left: calc(-50vw + 50%);
    width: 100vw;
    height: 100%;
    background-color: var(--rhg-pastel-blue);
    z-index: -1;
}

.footer-content {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 16px 24px !important;
    box-sizing: border-box;
    width: 100%;
    position: relative;
    z-index: 1;
}

.footer-left {
    display: flex;
    align-items: center;
    gap: 16px;
    flex-shrink: 0;
}

.footer-logo {
    width: 112px;
    height: 40px;
    flex-shrink: 0;
    object-fit: contain;
}

.footer-copyright {
    font-family: var(--font-family-main);
    font-size: 16px;
    font-weight: 400;
    color: var(--rhg-deep-black);
    white-space: nowrap;
}

.footer-right {
    display: flex;
    align-items: center;
    flex-shrink: 0;
}

.footer-links {
    display: flex;
    gap: 32px;
    align-items: center;
}

.footer-link {
    font-family: var(--font-family-main);
    font-size: 16px;
    font-weight: 400;
    color: var(--rhg-deep-black);
    text-decoration: underline;
    text-underline-position: from-font;
    white-space: nowrap;
    cursor: pointer;
}

.footer-link:hover {
    color: var(--rhg-deep-black);
}

/* Responsive footer styles */
@media (max-width: 768px) {
    .footer-content {
        flex-direction: column;
        align-items: center;
        gap: 1rem;
        padding: 16px 24px;
    }
    
    .footer-left {
        flex-direction: column;
        align-items: center;
        gap: 8px;
    }
    
    .footer-right {
        width: 100%;
        justify-content: center;
    }
    
    .footer-links {
        justify-content: center;
        flex-wrap: wrap;
        gap: 24px;
    }
}

@media (max-width: 480px) {
    .footer-logo {
        width: 90px;
        height: 32px;
    }
    
    .footer-copyright {
        font-size: 14px;
        text-align: center;
    }
    
    .footer-links {
        flex-direction: column;
        gap: 16px;
    }
    
    .footer-link {
        font-size: 14px;
    }
}

/*==================================================
 * 13. BUTTON SYSTEM
 *================================================== */

/* Base button styles */
.rhg-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 4px; /* Figma inline space */
    padding: 10px 20px; /* Figma padding */
    height: 36px; /* Figma button height */
    box-sizing: border-box;
    font-family: var(--font-family-main);
    font-size: 16px; /* Figma button text size */
    font-weight: 500; /* Figma button text weight */
    line-height: normal;
    text-decoration: none;
    border: none;
    border-radius: 0;
    cursor: pointer;
    transition: background-color 0.2s ease, color 0.2s ease, border-color 0.2s ease;
    white-space: nowrap;
    user-select: none;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

/* Button icon styling */
.rhg-button-icon {
    width: var(--rhg-sys-icon-size-default);
    height: var(--rhg-sys-icon-size-default);
    flex-shrink: 0;
    display: flex;
    align-items: center;
    justify-content: center;
}

.rhg-button-icon svg,
.rhg-button-icon img {
    width: 100%;
    height: 100%;
    object-fit: contain;
}

/* Filled Button Style */
.rhg-button--filled {
    background-color: var(--rhg-rhodium-blue); /* #0078ad */
    color: var(--rhg-crisp-white);
    border: none;
}

.rhg-button--filled:hover:not(:disabled) {
    background-color: var(--rhg-blue-dark); /* Darker shade on hover */
    color: var(--rhg-crisp-white);
}

.rhg-button--filled:disabled {
    background-color: var(--rhg-grey-lightest); /* #c9cbcb */
    color: var(--rhg-grey-light); /* #a1a3a4 */
    cursor: not-allowed;
}

/* Tonal Button Style */
.rhg-button--tonal {
    background-color: var(--rhg-pastel-blue); /* #cce4ef */
    color: var(--rhg-deep-black); /* #0a0a19 */
    border: none;
}

.rhg-button--tonal:hover:not(:disabled) {
    background-color: var(--rhg-blue-lightest); /* Slightly darker tonal background */
    color: var(--rhg-deep-black);
}

.rhg-button--tonal:disabled {
    background-color: var(--rhg-grey-lightest); /* #c9cbcb */
    color: var(--rhg-grey-light); /* #a1a3a4 */
    cursor: not-allowed;
}

/* Outlined Button Style */
.rhg-button--outlined {
    background-color: transparent;
    color: var(--rhg-deep-black); /* #0a0a19 */
    border: 0.5px solid var(--rhg-grey-lightest); /* #c9cbcb */
}

.rhg-button--outlined:hover:not(:disabled) {
    background-color: transparent;
    color: var(--rhg-rhodium-blue); /* #0078ad */
    border-color: var(--rhg-rhodium-blue);
}

.rhg-button--outlined:disabled {
    background-color: transparent;
    color: var(--rhg-grey-light); /* #a1a3a4 */
    border-color: var(--rhg-grey-lightest); /* #c9cbcb */
    cursor: not-allowed;
}

/* Text Button Style */
.rhg-button--text {
    background-color: transparent;
    color: var(--rhg-deep-black); /* #0a0a19 */
    border: none;
}

.rhg-button--text:hover:not(:disabled) {
    background-color: transparent;
    color: var(--rhg-rhodium-blue); /* #0078ad */
}

.rhg-button--text:disabled {
    background-color: transparent;
    color: var(--rhg-grey-light); /* #a1a3a4 */
    cursor: not-allowed;
}

/* Button sizes */
.rhg-button--small {
    padding: 6px 12px;
    height: 28px;
    font-size: 14px;
    gap: 3px;
}

.rhg-button--small .rhg-button-icon {
    width: var(--rhg-sys-icon-size-small);
    height: var(--rhg-sys-icon-size-small);
}

.rhg-button--large {
    padding: 14px 28px;
    height: 44px;
    font-size: 18px;
    gap: 6px;
}

.rhg-button--large .rhg-button-icon {
    width: var(--rhg-sys-icon-size-default);
    height: var(--rhg-sys-icon-size-default);
}

/* Button with icon alignment */
.rhg-button--icon-left {
    flex-direction: row;
}

.rhg-button--icon-right {
    flex-direction: row-reverse;
}

.rhg-button--icon-only {
    padding: 10px;
    width: 36px;
    gap: 0;
}

.rhg-button--icon-only.rhg-button--small {
    padding: 6px;
    width: 28px;
}

.rhg-button--icon-only.rhg-button--large {
    padding: 14px;
    width: 44px;
}

/* Focus states for accessibility */
.rhg-button:focus {
    outline: 2px solid var(--rhg-rhodium-blue);
    outline-offset: 2px;
}

.rhg-button:focus:not(:focus-visible) {
    outline: none;
}

/* Button group styles */
.rhg-button-group {
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.rhg-button-group--attached {
    gap: 0;
}

.rhg-button-group--attached .rhg-button:not(:first-child):not(:last-child) {
    border-radius: 0;
}

.rhg-button-group--attached .rhg-button:first-child {
    border-top-right-radius: 0;
    border-bottom-right-radius: 0;
}

.rhg-button-group--attached .rhg-button:last-child {
    border-top-left-radius: 0;
    border-bottom-left-radius: 0;
}

/* Legacy button class compatibility */
.btn {
    /* Keep existing .btn styles for backward compatibility */
    display: inline-block;
}

/* Primary button maps to filled style */
.btn-primary,
.rhg-button--primary {
    background-color: var(--rhg-rhodium-blue);
    color: var(--rhg-crisp-white);
    border: none;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 10px 20px;
    height: 36px;
    font-family: var(--font-family-main);
    font-size: 16px;
    font-weight: 500;
    text-decoration: none;
    border-radius: 0;
    cursor: pointer;
    transition: background-color 0.2s ease;
    box-sizing: border-box;
}

.btn-primary:hover,
.rhg-button--primary:hover {
    background-color: var(--rhg-blue-dark);
    color: var(--rhg-crisp-white);
    text-decoration: none;
}

/* Secondary button maps to tonal style */
.btn-secondary,
.rhg-button--secondary {
    background-color: var(--rhg-pastel-blue);
    color: var(--rhg-deep-black);
    border: none;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 10px 20px;
    height: 36px;
    font-family: var(--font-family-main);
    font-size: 16px;
    font-weight: 500;
    text-decoration: none;
    border-radius: 0;
    cursor: pointer;
    transition: background-color 0.2s ease;
    box-sizing: border-box;
}

.btn-secondary:hover,
.rhg-button--secondary:hover {
    background-color: var(--rhg-blue-lightest);
    color: var(--rhg-deep-black);
    text-decoration: none;
}

/*==================================================
 * 14. DASHBOARD MODALS & INTERACTIVE COMPONENTS
 *================================================== */

/* Dashboard Header */
.dashboard-header {
    background-color: white;
    padding: 0;
    margin-top: 0;
    width: 100%;
    box-sizing: border-box;
}

.breadcrumb {
    font-family: var(--font-family-main);
    font-size: 16px;
    font-weight: 400;
    color: var(--rhg-deep-black);
    margin: 0 0 4px 0;
}

.dashboard-header-bar {
    display: flex;
    align-items: end;
    justify-content: space-between;
    min-height: 54px;
    border-bottom: 0.5px solid var(--rhg-grey-lightest);
    margin-bottom: 16px;
    width: 100%;
    box-sizing: border-box;
}

.title-section {
    flex: 1;
}

.dashboard-title {
    font-family: var(--font-family-main);
    font-size: 24px;
    font-weight: 700;
    color: var(--rhg-deep-black);
    margin: 0;
    padding: 8px 0;
}

.utility-section {
    display: flex;
    align-items: center;
    gap: 16px;
}

.metadata-item-small {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    justify-content: center;
    padding: 10px 0;
    gap: 2px;
}

.metadata-label-small {
    font-family: var(--font-family-main);
    font-size: 14px;
    font-weight: 400;
    color: var(--rhg-grey-medium);
    line-height: 1.2;
    white-space: nowrap;
}

.metadata-value-small {
    font-family: var(--font-family-main);
    font-size: 14px;
    font-weight: 700;
    color: var(--rhg-deep-black);
    line-height: 1.2;
    white-space: nowrap;
}

.license-link {
    text-decoration: underline;
    cursor: pointer;
}

.license-btn {
    background: none;
    border: none;
    padding: 0;
    font-family: inherit;
    font-size: 14px;
    color: inherit;
    text-decoration: underline;
    cursor: pointer;
}

.license-btn:hover {
    color: var(--rhg-blue);
}

/* License Modal Styles - Matching Figma Design */
.license-modal {
    max-width: 500px;
    width: 90vw;
    border: none;
    background-color: #FFFFFF; /* White background */
}

.license-modal-body {
    padding: 16px; /* Figma container padding */
    background-color: #FFFFFF; /* White background */
    position: relative; /* For absolute positioned close button */
}

/* License modal close button */
.license-modal-close {
    position: absolute;
    top: 16px;
    right: 16px;
    z-index: 10;
}

/* CC-BY Title */
.cc-by-title {
    font-size: 20px; /* 20px as requested */
    font-weight: 700;
    color: #0a0a19; /* Using Figma color */
    margin: 0 0 16px 0; /* No top margin needed now */
    font-family: 'Hanken Grotesk', sans-serif;
}

/* Section Titles */
.section-title {
    font-size: 16px; /* 16px as requested */
    font-weight: 700; /* Bold as in Figma */
    color: #0a0a19; /* Using Figma color */
    margin: 0 0 16px 0; /* 16px spacing from Figma */
    font-family: 'Hanken Grotesk', sans-serif;
}

/* Permissions Section */
.permissions-section {
    margin-bottom: 16px; /* 16px spacing from Figma */
}

.permission-item {
    display: flex;
    align-items: flex-start;
    gap: 4px; /* 4px gap from Figma */
    margin-bottom: 16px; /* 16px spacing from Figma */
}

.permission-check-icon {
    flex-shrink: 0;
    margin-top: 0; /* Align with text baseline */
}

.permission-text {
    flex: 1;
    margin: 0; /* Remove default paragraph margins */
    line-height: normal; /* Match Figma */
}

.permission-label {
    font-weight: 700;
    color: #0a0a19; /* Using Figma color */
    font-family: 'Hanken Grotesk', sans-serif;
    font-size: 16px; /* 16px as requested */
}

/* Divider */
.license-divider {
    border: none;
    border-top: 0.5px solid #c9cbcb; /* Using Figma colors and thickness */
    margin: 16px 0; /* 16px spacing from Figma */
}

/* Attribution Section */
.attribution-section {
    margin-bottom: 16px; /* 16px spacing from Figma */
}

.attribution-label {
    font-weight: 700;
    color: #0a0a19; /* Using Figma color */
    font-family: 'Hanken Grotesk', sans-serif;
    font-size: 16px; /* 16px as requested */
}

.attribution-text {
    color: #0a0a19; /* Using Figma color */
    font-weight: 400;
    line-height: normal; /* Match Figma */
    margin: 0;
    font-family: 'Hanken Grotesk', sans-serif;
    font-size: 16px; /* 16px as requested */
}

.attribution-link {
    color: #0a0a19; /* Using Figma color */
    text-decoration: underline;
    font-weight: 400;
    font-size: 16px; /* 16px as requested */
}

.attribution-link:hover {
    color: #1F2937;
}

/* Read More Button - Exact Figma Tonal Button */
.read-more-section {
    margin-bottom: 0; /* No extra margin, matches Figma */
}

.read-more-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background-color: #cce4ef; /* Exact Figma tonal button color */
    color: #0a0a19; /* Figma text color */
    padding: 10px 20px; /* Exact Figma padding */
    height: 36px; /* Exact Figma height */
    text-decoration: none;
    border-radius: 0; /* No border radius in Figma */
    font-weight: 500; /* Figma button text weight */
    font-family: 'Hanken Grotesk', sans-serif;
    font-size: 16px; /* Figma button text size */
    gap: 4px; /* Figma inline space */
    transition: background-color 0.2s ease;
    box-sizing: border-box;
}

.read-more-button:hover {
    background-color: #b3d7e8; /* Slightly darker on hover */
    color: #0a0a19;
}

.utility-icon {
    cursor: pointer;
    font-size: 16px;
    color: var(--rhg-deep-black);
    display: flex;
    align-items: center;
    justify-content: center;
    width: 16px;
    height: 16px;
}

.download-icon {
    width: 12px;
    height: 16px;
    font-size: 16px;
}

.download-icon-btn {
    background: none;
    border: none;
    cursor: pointer;
    padding: 8px;
    border-radius: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background-color 0.2s ease;
    margin-bottom: 4px;
    min-height: 40px; /* Match metadata item height for proper alignment */
    min-width: 40px; /* Ensure consistent button sizing */
}

.download-icon-btn:hover {
    background-color: var(--rhg-grey-lightest);
}

.download-icon-btn:focus {
    outline: 2px solid var(--rhg-blue-medium);
    outline-offset: 2px;
}

/* Download Modal Styles */
.download-modal-container {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 1000;
    pointer-events: none;
}

.modal-backdrop {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5);
    z-index: 1001;
    pointer-events: auto;
}

.modal-content {
    position: fixed;
    top: 340px;
    left: 50%;
    transform: translate(-50%, -50%);
    background-color: white;
    border-radius: 0;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.2);
    max-width: 480px;
    width: 90%;
    max-height: 80vh;
    overflow-y: auto;
    z-index: 1002;
    pointer-events: auto;
}

.modal-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 24px 24px 0 24px;
}

.modal-title {
    font-family: var(--font-family-main);
    font-size: 20px;
    font-weight: 700;
    color: var(--rhg-deep-black);
    padding: 0px;
    margin: 0 !important; /* Force remove all margins including browser defaults */
    line-height: normal; /* Match Figma line height */
}

.modal-close-btn {
    background: none;
    border: none;
    cursor: pointer;
    padding: 4px;
    border-radius: 3px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background-color 0.2s ease;
}

.modal-close-btn:hover {
    background-color: var(--rhg-grey-lightest);
}

/* Download modal close button positioning */
.download-modal .modal-close-btn {
    position: absolute;
    top: 16px;
    right: 16px;
    z-index: 10;
}

.modal-body {
    padding: 16px 24px 24px 24px;
}

.modal-description {
    font-family: var(--font-family-main);
    font-size: 14px;
    color: var(--rhg-grey-dark);
    margin: 0 0 20px 0;
    line-height: 1.4;
}

.download-options-grid {
    display: grid;
    gap: 12px;
}

.download-option {
    width: 100%;
}

.download-option-btn {
    width: 100%;
    background: white;
    border: 1px solid var(--rhg-grey-light);
    border-radius: 6px;
    padding: 16px;
    cursor: pointer;
    text-align: left;
    transition: all 0.2s ease;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.download-option-btn:hover {
    border-color: var(--rhg-blue-medium);
    background-color: var(--rhg-blue-lightest, #f0f7ff);
}

.download-option-btn:focus {
    outline: 2px solid var(--rhg-blue-medium);
    outline-offset: 2px;
}

.download-option-header {
    display: flex;
    align-items: center;
    gap: 8px;
}

.download-option-title {
    font-family: var(--font-family-main);
    font-size: 16px;
    font-weight: 600;
    color: var(--rhg-deep-black);
}

.download-option-desc {
    font-family: var(--font-family-main);
    font-size: 14px;
    color: var(--rhg-grey-dark);
    margin: 0;
    line-height: 1.3;
}

/* Enhanced Modal Sections */
.modal-section {
    margin-bottom: 24px;
}

.modal-section:last-child {
    margin-bottom: 0;
}

.modal-section-title {
    font-family: var(--font-family-main);
    font-size: 16px;
    font-weight: 600;
    color: var(--rhg-deep-black);
    margin: 0 0 12px 0;
}

/* View Options */
.view-options-grid {
    display: grid;
    gap: 8px;
}

.view-option {
    width: 100%;
}

.view-option-btn {
    width: 100%;
    background: white;
    border: 1px solid var(--rhg-grey-light);
    border-radius: 6px;
    padding: 12px 16px;
    cursor: pointer;
    text-align: left;
    transition: all 0.2s ease;
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.view-option-btn:hover {
    border-color: var(--rhg-blue-medium);
    background-color: var(--rhg-blue-lightest, #f0f7ff);
}

.view-option-btn.selected {
    border-color: var(--rhg-blue-medium);
    background-color: var(--rhg-blue-lightest, #f0f7ff);
}

.view-option-btn:focus {
    outline: 2px solid var(--rhg-blue-medium);
    outline-offset: 2px;
}

.view-option-header {
    display: flex;
    align-items: center;
    gap: 8px;
}

.view-option-title {
    font-family: var(--font-family-main);
    font-size: 14px;
    font-weight: 600;
    color: var(--rhg-deep-black);
}

.view-option-desc {
    font-family: var(--font-family-main);
    font-size: 13px;
    color: var(--rhg-grey-dark);
    margin: 0;
    line-height: 1.3;
}

/* Radio Buttons */
.radio-button {
    width: 14px;
    height: 14px;
    border: 2px solid var(--rhg-grey-medium);
    border-radius: 50%;
    background: white;
    position: relative;
    transition: all 0.2s ease;
}

.radio-button.selected {
    border-color: var(--rhg-blue-medium);
    background: var(--rhg-blue-medium);
}

.radio-button.selected::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: white;
}

/* Download Modal Styles */
.download-modal {
    max-width: 520px;
    width: 95%;
}

.download-modal-body {
    padding: 24px;
    position: relative; /* For absolute positioned close button */
}

.modal-intro {
    font-family: var(--font-family-main);
    font-size: 16px;
    color: var(--rhg-deep-black);
    margin: 0 0 16px 0; /* Removed top margin, reduced bottom margin to match Figma */
    line-height: normal; /* Match Figma line height */
}

.download-section {
    margin-bottom: 24px;
}

.download-section:last-child {
    margin-bottom: 0;
}

.download-section-title {
    font-family: var(--font-family-main);
    font-size: 16px;
    font-weight: 700;
    color: var(--rhg-deep-black);
    margin: 0 0 6px 0;
}

.download-section-description {
    font-family: var(--font-family-main);
    font-size: 16px;
    color: var(--rhg-grey-dark);
    margin: 0 0 12px 0;
    line-height: 1.3;
}

.download-btn {
    width: 100%;
    background: #f2f2f2;
    border: none;
    border-radius: 0;
    padding: 14px 16px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: space-between;
    transition: all 0.2s ease;
}

.download-btn:hover {
    background: #e4e3e3;
}

.download-btn-inner {
    display: flex;
    align-items: center;
    gap: 12px;
}

.file-type-icon {
    width: 28px;
    height: 28px;
    border-radius: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    font-family: var(--font-family-main);
    font-size: 11px;
    font-weight: 700;
    color: white;
}

.xls-icon {
    background-color: #1d7044;
}

.zip-icon {
    background-color: #333333;
}

.download-btn-content {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
}

.download-btn-text {
    font-family: var(--font-family-main);
    font-size: 16px;
    font-weight: 500;
    color: var(--rhg-deep-black);
}

.file-size-text {
    font-family: var(--font-family-main);
    font-size: 16px;
    color: var(--rhg-grey-dark);
}

.download-arrow-icon {
    opacity: 0.7;
}

.citation-section {
    border-top: 1px solid var(--rhg-grey-lightest);
    padding-top: 20px;
    margin-top: 8px;
}

.citation-container {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 12px;
}

.citation-text {
    font-family: var(--font-family-main);
    font-size: 16px;
    color: var(--rhg-deep-black);
    flex: 1;
    line-height: 1.4;
}

.citation-copy-btn {
    background: none;
    border: none;
    border-radius: 0;
    padding: 6px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s ease;
    flex-shrink: 0;
}

.citation-copy-btn:hover {
    background-color: #f2f2f2;
}

.citation-copy-btn-dash {
    background: none;
    border: none;
    border-radius: 0;
    padding: 6px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s ease;
    flex-shrink: 0;
    width: 28px;
    height: 28px;
    background-size: 16px 16px;
    background-repeat: no-repeat;
    background-position: center;
}

.citation-copy-btn-dash:hover {
    background-color: #f2f2f2;
}

/* Filter Components */
.filter-container {
    display: flex;
    flex-direction: column;
    gap: 4px;
    align-items: stretch;  /* Changed from flex-start to stretch so children take full width */
    font-size: 14px;
    overflow: visible;  /* Allow tooltips to overflow */
}

.filter-label {
    font-family: var(--font-family-main);
    font-size: 14px;
    font-weight: 700;
    color: var(--rhg-deep-black);
    margin: 0;
    padding-bottom: 2px;
    line-height: 1;
}

/* Dash Dropdown Styling - minimal styling to avoid layout conflicts */
.filter-dropdown .Select-control {
    font-family: var(--font-family-main);
    font-size: 14px;
    border-radius: 0;
}

.filter-dropdown .Select-placeholder {
    font-family: var(--font-family-main);
    font-size: 14px;
}

.filter-dropdown .Select-value-label {
    font-family: var(--font-family-main);
    font-size: 14px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    padding-right: 8px;
}

.filter-dropdown .Select-value {
    max-width: calc(100% - 40px);
    overflow: hidden;
}

/* Dash Mantine Components Styling for Select and MultiSelect */
.filter-dropdown .mantine-Select-root,
.filter-dropdown .mantine-MultiSelect-root {
    width: 100%;
}

.filter-dropdown .mantine-Select-input,
.filter-dropdown .mantine-MultiSelect-input {
    font-family: var(--font-family-main);
    font-size: 14px;
    border-radius: 0;
    border: 1px solid #c9cbcb;
    padding: 8px 12px;
    padding-right: 28px;  /* Space for dropdown arrow */
    min-height: 36px;
    height: 36px;  /* Fixed height for consistency */
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.filter-dropdown .mantine-Select-input:focus,
.filter-dropdown .mantine-MultiSelect-input:focus {
    border-color: var(--rhg-rhodium-blue);
    outline: none;
}

/* Truncate long text in Select dropdown to prevent overlap with arrows */
.filter-dropdown .mantine-Select-wrapper,
.filter-dropdown .mantine-Input-wrapper {
    overflow: hidden;
}

.filter-dropdown .mantine-Select-input input,
.filter-dropdown .mantine-Input-input {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    padding-right: 28px !important;
}

/* Target the input section that displays selected value - Mantine v7+ */
.filter-dropdown .mantine-Select-section,
.filter-dropdown .mantine-Input-section {
    flex-shrink: 0;
}

.filter-dropdown [data-combobox-target] {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

/* Ensure the input text area doesn't overflow into the right section (arrows) */
.filter-dropdown .mantine-Select-input[data-with-right-section],
.filter-dropdown .mantine-Input-wrapper[data-with-right-section] input {
    padding-right: 28px !important;
}

.filter-dropdown .mantine-Select-item,
.filter-dropdown .mantine-MultiSelect-item {
    font-family: var(--font-family-main);
    font-size: 14px;
    padding: 8px 12px;
}

.filter-dropdown .mantine-Select-item[data-selected],
.filter-dropdown .mantine-MultiSelect-item[data-selected] {
    background-color: var(--rhg-rhodium-blue);
    color: white;
}

.filter-dropdown .mantine-Select-item:hover,
.filter-dropdown .mantine-MultiSelect-item:hover {
    background-color: #f0f0f0;
}

/* Remove border radius from dropdown menus */
.filter-dropdown .mantine-Select-dropdown,
.filter-dropdown .mantine-MultiSelect-dropdown,
.filter-dropdown .mantine-Popover-dropdown,
.filter-dropdown-compact .mantine-Select-dropdown,
.filter-dropdown-compact .mantine-MultiSelect-dropdown,
.filter-dropdown-compact .mantine-Popover-dropdown {
    border-radius: 0 !important;
}

/* Target the specific generated classes - Mantine dropdowns are portaled to body */
div[class*="mantine-Select-dropdown"],
div[class*="mantine-MultiSelect-dropdown"],
div[class*="mantine-Popover-dropdown"],
.mantine-Popover-dropdown,
.mantine-Select-dropdown,
.mantine-MultiSelect-dropdown {
    border-radius: 0 !important;
    z-index: 9999 !important;
}

/* Mantine Combobox dropdown (used in newer versions) */
div[class*="mantine-Combobox-dropdown"],
.mantine-Combobox-dropdown {
    z-index: 9999 !important;
    border-radius: 0 !important;
}

/* Mantine Portal container - ensure dropdowns appear above all page content */
.mantine-Portal,
div[class*="mantine-Portal"] {
    z-index: 9999 !important;
}

/* Mantine Combobox options list */
div[class*="mantine-Combobox-options"],
.mantine-Combobox-options {
    z-index: 9999 !important;
}

/* Ensure filter containers don't create problematic stacking contexts */
.filter-row .filter-container {
    z-index: auto;
}

.filter-dropdown .mantine-MultiSelect-value {
    font-family: var(--font-family-main);
    font-size: 14px;
    background-color: var(--rhg-rhodium-blue);
    color: white;
    border-radius: 2px;
    padding: 2px 8px;
}

.filter-dropdown .mantine-MultiSelect-defaultValueRemove {
    color: white;
}

.filter-dropdown .mantine-MultiSelect-defaultValueRemove:hover {
    background-color: rgba(255, 255, 255, 0.2);
}

/* Compact MultiSelect Display */
.filter-dropdown-compact .mantine-Pill-root {
    display: none !important;
}

.filter-dropdown-compact .custom-display-text {
    display: block;
    pointer-events: none;
}

.filter-dropdown-compact .mantine-MultiSelect-input {
    min-height: 36px;
    height: 36px;  /* Match single select height */
}

.filter-dropdown-compact .mantine-MultiSelect-pillsList[data-selected-text] .mantine-MultiSelect-inputField {
    opacity: 0;
    width: 0;
    padding: 0;
}

/* Clear button styling for filters */
.filter-dropdown .mantine-InputClearButton-root,
.filter-dropdown-compact .mantine-InputClearButton-root {
    color: var(--rhg-rhodium-blue) !important;
}

.filter-dropdown .mantine-InputClearButton-root:hover,
.filter-dropdown-compact .mantine-InputClearButton-root:hover {
    color: var(--rhg-blue-dark) !important;
    background-color: rgba(50, 147, 197, 0.1) !important;
}

/* Additional selectors for clear button */
.filter-dropdown button[class*="clearButton"],
.filter-dropdown-compact button[class*="clearButton"],
.filter-dropdown .mantine-CloseButton-root,
.filter-dropdown-compact .mantine-CloseButton-root {
    color: var(--rhg-rhodium-blue) !important;
}

.filter-dropdown button[class*="clearButton"]:hover,
.filter-dropdown-compact button[class*="clearButton"]:hover,
.filter-dropdown .mantine-CloseButton-root:hover,
.filter-dropdown-compact .mantine-CloseButton-root:hover {
    color: var(--rhg-blue-dark) !important;
    background-color: rgba(50, 147, 197, 0.1) !important;
}

/* MultiSelect action buttons styling */
.filter-with-actions .mantine-Button-root[id*="select-all"],
.filter-with-actions .mantine-Button-root[id*="clear-all"] {
    font-family: var(--font-family-main);
    font-size: 12px;
    padding: 4px 8px;
    height: auto;
}

.mantine-Accordion-item {
    border-radius: 0px !important;
}

/* Year Range Slider */
.slider-filter {
    background-color: white;
    overflow: visible;
}

.slider-container {
    position: relative;
    width: 276px;
}

.year-slider {
    margin-bottom: 16px;
}

.year-slider .rc-slider-rail {
    background-color: var(--rhg-grey-lightest);
    height: 4px;
}

.year-slider .rc-slider-track {
    background-color: var(--rhg-rhodium-blue);
    height: 4px;
}

.year-slider .rc-slider-handle {
    background-color: var(--rhg-rhodium-blue);
    border: 2px solid var(--rhg-rhodium-blue);
    width: 17px;
    height: 17px;
    margin-top: -6.5px;
}

.year-slider .rc-slider-handle:hover,
.year-slider .rc-slider-handle:focus {
    border-color: var(--rhg-rhodium-blue);
    box-shadow: 0 0 0 5px rgba(0, 120, 173, 0.12);
}


/* Reset Filters Button */
.reset-filters-button {
    display: flex;
    align-items: center;
    gap: 4px;
    cursor: pointer;
    color: var(--rhg-rhodium-blue) !important;
    font-family: var(--font-family-main);
    font-size: 16px;
    font-weight: 400;
    justify-content: flex-end;
    margin-bottom: 4px;
    background: none;
    border: none;
    padding: 0;
    text-decoration: none;
}

.reset-filters-button:hover {
    color: var(--rhg-blue-dark) !important;
    text-decoration: none;
}

.reset-icon {
    font-size: 16px;
    color: var(--rhg-rhodium-blue) !important;
}

.reset-text {
    white-space: nowrap;
    color: var(--rhg-rhodium-blue) !important;
}

/* Global Filters Section - styling handled by sticky-filters class */
.global-filters-container {
    background-color: white;
    /*position: sticky;*/
    top: 0; /* Stick to top of scrolling container */
    /*z-index: 100;  Higher than most content but lower than nav */
    padding: 4px 0;
    margin: 0 0 40px 0;
    width: 100%;
    overflow: visible;  /* Allow tooltips to overflow */
}

/* Sticky Filters - Simple approach: make it work within the scrolling container */
.sticky-filters {
    position: sticky !important;
    top: 0 !important;
    z-index: 1000 !important;
    background-color: white !important;
    padding: 6px 0 4px 0 !important;
    margin: 0 0 40px 0 !important;
    width: 100% !important;
    overflow: visible !important;  /* Allow tooltips to overflow */
}

/* Create full-width border that's always visible 
.sticky-filters::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: -4rem; 
    width: calc(100vw - 280px + 4rem); 
    height: 1px;
    background-color: var(--rhg-grey-lightest);
    z-index: 1;
}
/*

/* Override page-container overflow to allow sticky positioning */
.page-container {
    overflow-y: visible !important;
    height: auto !important;
}

/* Make sure body handles the scrolling instead */
body {
    overflow-y: auto !important;
    height: 100vh !important;
}

/* Ensure the main layout container can scroll */
.dash-app-container > div {
    height: 100vh !important;
    overflow-y: auto !important;
}

/* Clean up - these rules are handled by the main layout override above */

/* Ensure parent containers don't interfere with sticky positioning */
.dashboard-content,
.main-content,
.page-content {
    /* Don't add overflow hidden or other properties that break sticky */
    contain: none;
}

.global-filters {
    display: flex;
    flex-wrap: wrap;
    gap: 16px;
    align-items: flex-start;
    justify-content: flex-start;
    position: relative;
    overflow: visible;  /* Allow tooltips to overflow */
}

.global-filters-reset {
    position: absolute;
    top: 0;
    right: 0;
    z-index: 1;
}

.filter-row {
    display: flex;
    align-items: flex-end;
    margin-bottom: 20px;
    margin-top: 20px;
    flex-wrap: wrap;
    gap: 16px;
}

/* Filter dropdown z-index fix - ensures dropdown menus appear above sibling filters */
.filter-row > .filter-container,
.filter-row > div {
    position: relative;
}

/* Dash dropdown menus need high z-index to appear above siblings */
.filter-row .Select-menu-outer,
.filter-row .dash-dropdown .Select-menu-outer,
.filter-container .Select-menu-outer {
    z-index: 9999 !important;
}

/* Ensure the dropdown container itself gets proper stacking when open */
.filter-row .dash-dropdown.is-open,
.filter-row .Select.is-open,
.filter-container .dash-dropdown.is-open,
.filter-container .Select.is-open {
    z-index: 1000 !important;
}

/* ========================================
 * 11.5 DATA TABLES
 * ======================================== */
.dash-table-container {
    background-color: white;
    border: none;
    overflow: visible;
    padding-top: 8px;
}

.dash-table-container .dash-spreadsheet-container {
    border: none;
}

.dash-table-container .dash-spreadsheet-container .dash-spreadsheet-inner {
    border: none;
}

.dash-table-container table {
    border-collapse: collapse;
    width: 100%;
}

/* Header styling */
.dash-table-container .dash-header {
    background-color: white !important;
    border-bottom: 0.5px solid var(--rhg-deep-black) !important;
}

.dash-table-container .dash-header .dash-cell {
    padding: 8px !important;
    font-family: var(--font-family-secondary) !important;
    font-size: 14px !important;
    font-weight: bold !important;
    color: var(--rhg-deep-black) !important;
    text-align: left !important;
    background-color: white !important;
    border: none !important;
    position: relative !important;
}

/* Data cell styling */
.dash-table-container .dash-cell {
    padding: 8px !important;
    font-family: var(--font-family-secondary) !important;
    font-size: 14px !important;
    color: var(--rhg-deep-black) !important;
    text-align: left;
    overflow: hidden;
    text-overflow: ellipsis;
    border-left: none !important;
    border-right: none !important;
    border-top: none !important;
    background-color: white !important;
}

/* Disable all cell selection/focus/hover effects */
.dash-table-container .dash-cell.focused,
.dash-table-container .dash-cell:focus,
.dash-table-container .dash-cell:hover,
.dash-table-container .dash-cell.selected,
.dash-table-container .dash-cell:active,
.dash-table-container .dash-cell.cell--selected,
.dash-table-container .dash-cell.cell--active,
.dash-table-container tr:hover,
.dash-table-container tbody tr:hover,
.dash-table-container tbody tr:hover td {
    background-color: inherit !important;
    border: none !important;
    outline: none !important;
    box-shadow: none !important;
    cursor: default !important;
}

/* Disable row selection highlighting */
.dash-table-container .dash-selected-row,
.dash-table-container .dash-row.dash-selected,
.dash-table-container tr.dash-selected {
    background-color: inherit !important;
}

/* Ensure no pointer cursor on table cells */
.dash-table-container .dash-cell {
    cursor: default !important;
    user-select: none !important;
}

/* Remove general striped styling - only apply to .striped-table class */

/* Ensure borders are consistent - but allow bordered tables to override */
.dash-table-container:not(.bordered-table) .dash-cell {
    border-bottom: none !important;
}

/* Override any default Dash table striping */
.dash-table-container .dash-spreadsheet-container .dash-spreadsheet-inner .dash-cell {
    background-color: inherit !important;
}

/* Bordered table specific styling - More specific selectors */
.bordered-table .dash-spreadsheet-container .dash-spreadsheet-inner table tbody tr td {
    border-bottom: 0.5px solid #E5E5E5 !important;
    background-color: white !important;
}

.bordered-table .dash-spreadsheet-container .dash-spreadsheet-inner table thead tr th {
    border-bottom: 0.5px solid #0a0a19 !important;
}

/* Ensure bordered table cells have consistent borders and white background */
.bordered-table .dash-cell {
    border-bottom: 0.5px solid #E5E5E5 !important;
    background-color: white !important;
}

.bordered-table .dash-header .dash-cell {
    border-bottom: 0.5px solid #0a0a19 !important;
    background-color: white !important;
}

/* Override any alternating colors for bordered tables */
.bordered-table .dash-spreadsheet-container .dash-spreadsheet-inner table tbody tr:nth-child(odd) td,
.bordered-table .dash-spreadsheet-container .dash-spreadsheet-inner table tbody tr:nth-child(even) td {
    background-color: white !important;
}

/* Striped table specific styling */
.striped-table .dash-spreadsheet-container .dash-spreadsheet-inner table tbody tr:nth-child(odd) td {
    background-color: #f8f8f8 !important;
}

.striped-table .dash-spreadsheet-container .dash-spreadsheet-inner table tbody tr:nth-child(even) td {
    background-color: white !important;
}

/* Ensure striped rows maintain their background even on interaction */
.striped-table .dash-spreadsheet-container .dash-spreadsheet-inner table tbody tr:nth-child(odd):hover td,
.striped-table .dash-spreadsheet-container .dash-spreadsheet-inner table tbody tr:nth-child(odd):focus td,
.striped-table .dash-spreadsheet-container .dash-spreadsheet-inner table tbody tr:nth-child(odd).dash-selected td {
    background-color: #f8f8f8 !important;
}

.striped-table .dash-spreadsheet-container .dash-spreadsheet-inner table tbody tr:nth-child(even):hover td,
.striped-table .dash-spreadsheet-container .dash-spreadsheet-inner table tbody tr:nth-child(even):focus td,
.striped-table .dash-spreadsheet-container .dash-spreadsheet-inner table tbody tr:nth-child(even).dash-selected td {
    background-color: white !important;
}

/* Ensure striped table doesn't have borders unless specified */
.striped-table:not(.bordered-table) .dash-cell {
    border-bottom: none !important;
}

/* Priority override for striped table interactions */
.striped-table .dash-cell:hover,
.striped-table .dash-cell:focus,
.striped-table .dash-cell.selected,
.striped-table .dash-cell:active {
    background-color: inherit !important;
}

/* Sort icon spacing - try different selectors */
.dash-table-container th {
    position: relative !important;
    padding-right: 30px !important;
}

.dash-table-container th .sort,
.dash-table-container th [data-dash-column] .sort,
.dash-table-container .column-header--sort {
    position: absolute !important;
    right: 8px !important;
    top: 50% !important;
    transform: translateY(-50%) !important;
    margin-left: 0 !important;
}

/* Alternative sort icon selectors */
.dash-table-container .dash-header .dash-cell::after {
    content: '';
    position: absolute;
    right: 8px;
    top: 50%;
    transform: translateY(-50%);
}

/* Frozen/Fixed column styling - ensure background covers full cell height */
.dash-table-container .cell--fixed-left,
.dash-table-container .dash-fixed-column,
.dash-table-container th.frozen-left,
.dash-table-container td.frozen-left,
.dash-table-container [data-dash-column="0"].dash-cell {
    background-color: white !important;
}

/* Ensure frozen header cells have full background coverage */
.dash-table-container .dash-header .cell--fixed-left,
.dash-table-container .dash-header .dash-fixed-column,
.dash-table-container .dash-header th[style*="position: sticky"],
.dash-table-container .dash-header td[style*="position: sticky"] {
    background-color: white !important;
    z-index: 2 !important;
}

/* Fix for frozen column header - ensure the cell background extends fully */
.dash-table-container .dash-spreadsheet-inner th,
.dash-table-container .dash-spreadsheet-inner td {
    box-sizing: border-box !important;
}

/* Target cells with inline sticky positioning (Dash's frozen columns) */
.dash-table-container th[style*="sticky"],
.dash-table-container td[style*="sticky"] {
    background-color: white !important;
}

/* Ensure header row frozen cells cover underlying content */
.dash-table-container thead th[style*="sticky"],
.dash-table-container thead td[style*="sticky"],
.dash-table-container .dash-header [style*="sticky"] {
    background-color: white !important;
    z-index: 3 !important;
}

/* ========================================
 * 11.6 METHODS NOTE & INFO CALLOUTS
 * ======================================== */
.methods-note-callout {
    border: 0.5px solid var(--rhg-grey-lightest);
    padding: 16px;
    display: flex;
    gap: 16px;
    align-items: flex-start;
    max-width: 1000px;
    background-color: white;
    margin-top: 10px;
    margin-bottom: 10px;
}




/* Methods note callout color variations - outlined, grey filled, and blue filled */
.methods-note-callout--outlined {
    background-color: var(--rhg-crisp-white);
    border: 0.5px solid var(--rhg-grey-lightest);
}

.methods-note-callout--filled {
    background-color: var(--rhg-neutral-grey); /* #f2f2f2 */
    border: none;
}

.methods-note-callout--blue {
    background-color: var(--rhg-pastel-blue); /* #cce4ef */
    border: none;
}

/* Info box color variations - keep existing semantic colors for backward compatibility */
.info-box--default,
.content-callout--default {
    background-color: var(--rhg-pastel-blue);
    border-left: 4px solid var(--rhg-blue-medium);
}

.info-box--success,
.content-callout--success {
    background-color: var(--rhg-green-lightest);
    border-left: 4px solid var(--rhg-green-medium);
}

.info-box--warning,
.content-callout--warning {
    background-color: var(--rhg-yellow-lightest);
    border-left: 4px solid var(--rhg-yellow-medium);
}

.info-box--danger,
.content-callout--danger {
    background-color: var(--rhg-orange-lightest);
    border-left: 4px solid var(--rhg-orange-medium);
}

.methods-note-icon {
    width: var(--rhg-sys-icon-size-default);
    height: var(--rhg-sys-icon-size-default);
    flex-shrink: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    padding-top: 2px;
    padding-left: 2px;
    /* Removed background, border-radius, and color for clean black icon */
}

.methods-note-content {
    display: flex;
    flex-direction: column;
    gap: 4px;
    line-height: 1.1;
}

.methods-note-title {
    font-family: var(--font-family-main);
    font-size: 0.9rem;
    font-weight: 700;
    color: var(--rhg-deep-black);
    margin: 0;
}

.methods-note-text {
    font-family: var(--font-family-main);
    font-size: 0.9rem;
    font-weight: 400;
    color: var(--rhg-deep-black);
    margin: 0;
    line-height: 1.2;
}

.methods-note-button {
    font-family: var(--font-family-main);
    font-size: 14px;
    font-weight: 500;
    color: var(--rhg-deep-black);
    background-color: var(--rhg-surface-light, #cce4ef);
    padding: 8px 16px;
    border-radius: 0;
    text-decoration: none;
    white-space: nowrap;
    flex-shrink: 0;
    margin-left: auto;
    align-self: center;
    transition: background-color 0.2s ease;
}

.methods-note-button:hover {
    background-color: #b8d9e6;
    text-decoration: none;
    color: var(--rhg-deep-black);
}

/*==================================================
 * 15. HOMEPAGE CALLOUT COMPONENT
 *================================================== */

/* Homepage callout - two-column layout with blue background */
.homepage-callout {
    background-color: var(--rhg-rhodium-blue); /* #0078ad */
    padding: 32px 120px;
    display: flex;
    gap: 80px;
    align-items: flex-start;
    justify-content: flex-start;
    box-sizing: border-box;
    width: 100%;
}

.homepage-callout-left {
    flex: 0 0 320px;
    max-width: 320px;
    display: flex;
    align-items: flex-start;
    justify-content: flex-start;
}

.homepage-callout-title {
    font-family: var(--font-family-main);
    font-size: 24px;
    font-weight: 700;
    color: var(--rhg-crisp-white);
    line-height: normal;
    margin: 0;
    white-space: nowrap;
}

.homepage-callout-right {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 16px;
    align-items: flex-start;
    justify-content: flex-start;
    padding-top: 16px;
    position: relative;
}

/* Top border for right section */
.homepage-callout-right::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 0.5px;
    background-color: var(--rhg-crisp-white);
}

.homepage-callout-description {
    font-family: var(--font-family-main);
    font-size: 16px;
    font-weight: 400;
    color: var(--rhg-crisp-white);
    line-height: normal;
    margin: 0;
    width: 100%;
    min-width: 100%;
}

.homepage-callout-button {
    background-color: var(--rhg-deep-black); /* #0a0a19 */
    color: var(--rhg-crisp-white);
    border: none;
    padding: 10px 20px;
    height: 36px;
    font-family: var(--font-family-main);
    font-size: 16px;
    font-weight: 500;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 4px;
    cursor: pointer;
    transition: background-color 0.2s ease;
    box-sizing: border-box;
    text-decoration: none;
    border-radius: 0;
}

.homepage-callout-button:hover {
    background-color: var(--rhg-grey-darkest);
    color: var(--rhg-crisp-white);
    text-decoration: none;
}

.homepage-callout-button:focus {
    outline: 2px solid var(--rhg-crisp-white);
    outline-offset: 2px;
}

/* Responsive design for homepage callout */
@media (max-width: 768px) {
    .homepage-callout {
        flex-direction: column;
        gap: 24px;
        padding: 24px 20px;
    }
    
    .homepage-callout-left {
        flex: none;
        max-width: none;
        width: 100%;
    }
    
    .homepage-callout-title {
        white-space: normal;
        font-size: 20px;
    }
    
    .homepage-callout-right {
        padding-top: 24px;
        width: 100%;
    }
    
    .homepage-callout-right::before {
        top: 12px;
    }
}

/*==================================================
 * 16. INSIGHTS PAGE COMPONENTS
 *================================================== */

/* Insights Header */
.insights-header {
    width: 100%;
    margin-top: 16px;
}


.insights-header-bar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    min-height: 54px;
    border-bottom: 0.5px solid var(--rhg-sys-color-border-default);
    position: relative;
}

.insights-title-container {
    display: flex;
    align-items: flex-end;
    height: 100%;
    padding-bottom: 8px;
}

.insights-title {
    font-family: var(--font-family-main);
    font-size: 24px;
    font-weight: var(--font-weight-bold);
    color: var(--rhg-deep-black);
    margin: 0;
    line-height: normal;
}

.utility-links {
    display: flex;
    align-items: center;
    gap: 16px;
}

.utility-item {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    padding: 8px 0;
}

.utility-label {
    font-family: var(--font-family-main);
    font-size: 14px;
    font-weight: var(--font-weight-normal);
    color: var(--rhg-grey-medium);
    line-height: normal;
}

.utility-value {
    font-family: var(--font-family-main);
    font-size: 14px;
    font-weight: var(--font-weight-bold);
    color: var(--rhg-deep-black);
    line-height: normal;
}

.utility-link {
    color: var(--rhg-deep-black);
    text-decoration: underline;
    text-underline-position: from-font;
}

.utility-separator {
    width: 1px;
    height: 40px;
    background-color: var(--rhg-sys-color-border-default);
    transform: rotate(90deg);
}

.utility-icon-container {
    display: flex;
    align-items: center;
    justify-content: center;
    width: var(--rhg-sys-icon-size-large);
    height: var(--rhg-sys-icon-size-large);
}

.utility-icon {
    width: var(--rhg-sys-icon-size-default);
    height: var(--rhg-sys-icon-size-default);
}

/* Report Widget */
.report-widget {
    background: var(--rhg-crisp-white);
    border: 0.5px solid var(--rhg-sys-color-border-default);
    border-radius: 0;
    overflow: hidden;
    width: 320px;
}

.report-image-container {
    width: 100%;
    height: 181px;
    overflow: hidden;
}

.report-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.report-placeholder {
    width: 100%;
    height: 100%;
    background-color: var(--rhg-neutral-grey);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--rhg-grey-medium);
    font-size: 14px;
}

.report-info {
    padding: 16px;
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.report-type-label {
    font-family: var(--font-family-main);
    font-size: 14px;
    font-weight: var(--font-weight-normal);
    color: var(--rhg-grey-medium);
    line-height: normal;
}

.report-title {
    font-family: var(--font-family-main);
    font-size: 16px;
    font-weight: var(--font-weight-bold);
    color: var(--rhg-deep-black);
    margin: 0;
    line-height: normal;
}

/* Dashboard Callout */
.dashboard-callout {
    background: var(--rhg-pastel-blue);
    border: none;
    border-radius: 0;
    padding: 16px;
    display: flex;
    gap: 16px;
    align-items: flex-start;
    max-width: 800px;
    width: 480px;
}

.callout-icon-container {
    display: flex;
    align-items: center;
    justify-content: center;
    width: var(--rhg-ref-size-icon-lg);
    height: var(--rhg-ref-size-icon-lg);
    flex-shrink: 0;
}

.callout-icon {
    width: var(--rhg-ref-size-icon-lg);
    height: var(--rhg-ref-size-icon-lg);
}

.callout-content {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 0;
}

.callout-title {
    font-family: var(--font-family-main);
    font-size: 16px;
    font-weight: var(--font-weight-bold);
    color: var(--rhg-deep-black);
    margin: 0 0 0 0;
    line-height: normal;
}

.callout-description {
    font-family: var(--font-family-main);
    font-size: 16px;
    font-weight: var(--font-weight-normal);
    color: var(--rhg-deep-black);
    margin: 0 0 0 0;
    line-height: normal;
}

.callout-arrow-container {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    margin-top: 10px;
    width: 16px;
    height: 10px;
}

.callout-arrow {
    width: 16px;
    height: 10px;
    transform: rotate(0deg);
}

/* Insights Content Layout */

.about-section {
    display: flex;
    flex-direction: column;
    gap: 0;
}

/* Insights page specific layout with side-by-side content */
.about-section.insights-layout {
    flex-direction: row;
    gap: 32px;
    align-items: flex-start;
}

.about-main-content {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.about-research-widget {
    flex-shrink: 0;
}

.section-subheading {
    font-family: var(--font-family-main);
    font-size: 20px;
    font-weight: var(--font-weight-bold);
    color: var(--rhg-deep-black);
    margin: 0;
    line-height: normal;
}


/* Citation Section */
.citation-section {
    display: flex;
    flex-direction: column;
    gap: 0;
}

.citation-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 0;
}

.citation-label {
    font-family: var(--font-family-main);
    font-size: 14px;
    font-weight: var(--font-weight-normal);
    color: var(--rhg-grey-medium);
    line-height: normal;
}

.copy-icon-container {
    display: flex;
    align-items: center;
    justify-content: center;
    width: var(--rhg-sys-icon-size-default);
    height: var(--rhg-sys-icon-size-default);
}

.copy-icon {
    width: var(--rhg-sys-icon-size-default);
    height: var(--rhg-sys-icon-size-default);
}

.citation-text {
    font-family: var(--font-family-main);
    font-size: 16px;
    font-weight: var(--font-weight-bold);
    color: var(--rhg-deep-black);
    line-height: normal;
}

/* BAN Metrics Row */
.ban-metrics-row {
    display: flex;
    flex-wrap: wrap;
    gap: 32px;
}

/* Charts Row */
.charts-row {
    display: flex;
    gap: 32px;
    align-items: flex-start;
}

.chart-widget {
    background: var(--rhg-crisp-white);
    border: none;
    border-radius: 0;
    padding: 0;
    max-width: 480px;
    width: 480px;
    display: flex;
    flex-direction: column;
    gap: 0;
}

.chart-header {
    display: flex;
    align-items: center;
    gap: 4px;
    margin-bottom: 0;
}

.info-icon {
    width: var(--rhg-sys-icon-size-default);
    height: var(--rhg-sys-icon-size-default);
}

.chart-placeholder {
    width: 100%;
    height: 320px;
    background-color: var(--rhg-neutral-grey);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--rhg-grey-medium);
    font-size: 14px;
    margin: 0;
}

.chart-note {
    font-family: var(--font-family-main);
    font-size: 14px;
    font-weight: var(--font-weight-normal);
    color: var(--rhg-deep-black);
    margin: 0;
    line-height: normal;
}

/* Charts row layout - responsive side-by-side charts */
.charts-row {
    display: flex;
    gap: 32px;
    margin-bottom: 24px;
    flex-wrap: wrap;
}

.charts-row > * {
    flex: 1;
    min-width: 0; /* Allows flex items to shrink below their content size */
}

/* BAN callouts row layout - responsive metric callouts */
.ban-callouts-row {
    display: flex;
    flex-wrap: wrap;
    gap: 32px;
    margin-bottom: 24px;
}

/*==================================================
 * 17. DASH-SPECIFIC STYLES
 *================================================== */

/* Ensure Dash app container has proper styling */
#react-entry-point {
    font-family: var(--font-family-main) !important;
    min-height: 100vh;
}

/* Force font family on all Dash components */
._dash-undo-redo, 
.dash-table-container, 
.Select-control, 
.dash-dropdown,
.dash-graph,
.plotly-graph-div {
    font-family: var(--font-family-main) !important;
}

/* Ensure proper spacing and layout for Dash content */
.main-content {
    padding: 0.5rem min(6rem, 6vw) 3rem min(3.5rem, 3.5vw);
    max-width: none;
    width: 100%;
    box-sizing: border-box;
}

/* Override any Dash-specific font issues */
.dash-table-container * {
    font-family: var(--font-family-secondary) !important;
}

/* Table scroll container to prevent tables from pushing main content width */
.table-scroll-container {
    width: 100% !important;
    max-width: 100% !important;
    overflow-x: auto !important;
    overflow-y: visible !important;
    box-sizing: border-box !important;
}

/* Ensure Dash table respects container constraints */
.table-scroll-container .dash-table-container {
    width: 100% !important;
    max-width: 100% !important;
    overflow-x: auto !important;
}

/* Prevent table from expanding beyond container */
.table-scroll-container .dash-table-container .dash-spreadsheet-container {
    max-width: 100% !important;
    overflow-x: auto !important;
}

/* Dash graph containers */
.js-plotly-plot .plotly .main-svg {
    font-family: var(--font-family-main) !important;
}

/* Disable cross cursor in Plotly graphs */
.js-plotly-plot .plotly .main-svg,
.js-plotly-plot .plotly .main-svg * {
    cursor: default !important;
}

/* Plotly notifier styling */
.plotly-notifier {
    display: block !important;
    visibility: visible !important;
    background-color: var(--rhg-pastel-blue) !important;
    color: var(--rhg-deep-black) !important;
    font-family: var(--font-family-main) !important;
    font-size: var(--font-size-paragraph) !important;
    font-weight: var(--font-weight-medium) !important;
    line-height: 1.3 !important;
    border: none !important;
    border-radius: 0 !important;
    padding: 8px 32px 8px 12px !important;
    box-shadow: none !important;
    margin: 0 16px 0 0 !important;
    opacity: 1 !important;
    transition: none !important;
    animation: none !important;
}

/* Hide notifier when empty or closed */
.plotly-notifier:empty {
    display: none !important;
    visibility: hidden !important;
    height: 0 !important;
    padding: 0 !important;
    margin: 0 !important;
}

.plotly-notifier p,
.plotly-notifier div,
.plotly-notifier span {
    background: none !important;
    background-color: transparent !important;
    font-family: var(--font-family-main) !important;
    color: var(--rhg-deep-black) !important;
    line-height: 1.3 !important;
    border: none !important;
    border-radius: 0 !important;
    box-shadow: none !important;
    padding: 0 !important;
    margin: 0 !important;
    text-indent: 0 !important;
    width: 100% !important;
    display: block !important;
}

/* Hide close button */
.plotly-notifier .notifier-close {
    display: none !important;
    visibility: hidden !important;
}

/* Target any nested notification elements */
.plotly-notifier [data-notifier-text],
.plotly-notifier .notifier-text,
.plotly-notifier .notifier-note {
    background: none !important;
    background-color: transparent !important;
    color: var(--rhg-deep-black) !important;
    font-family: var(--font-family-main) !important;
    border: none !important;
    width: 100% !important;
    display: block !important;
}

/* Force all child elements to fill container width */
.plotly-notifier * {
    box-sizing: border-box !important;
    max-width: 100% !important;
}

  

/* Ensure Dash dropdowns use RHG styling */
.Select-control {
    border: 1px solid var(--rhg-grey-light) !important;
    border-radius: 0 !important;
    font-size: 16px !important;
}

.Select-control:hover {
    border-color: var(--rhg-blue-medium) !important;
}

/* Prevent long text from overlapping dropdown arrows */
.Select-value {
    max-width: calc(100% - 40px) !important;
    overflow: hidden !important;
}

.Select-value-label {
    overflow: hidden !important;
    text-overflow: ellipsis !important;
    white-space: nowrap !important;
}

/* Dash loading components */
._dash-loading {
    font-family: var(--font-family-main) !important;
}

/* Ensure all Dash text uses proper fonts */
.dash-graph .gtitle,
.dash-graph .xtitle,
.dash-graph .ytitle,
.dash-graph .legend,
.dash-graph .annotation {
    font-family: var(--font-family-main) !important;
}

.maplibregl-ctrl-attrib-inner {
    font-family: var(--font-family-main) !important;
    font-size: 12px !important;
}

/* Hide the attribution toggle button and keep attribution always visible */
.maplibregl-ctrl-attrib-button {
    display: none !important;
}

.maplibregl-ctrl-attrib.maplibregl-compact {
    min-height: auto !important;
}

.maplibregl-ctrl-attrib.maplibregl-compact .maplibregl-ctrl-attrib-inner {
    display: block !important;
}

/* Position attribution on the right side with right alignment */
.maplibregl-ctrl-bottom-left .maplibregl-ctrl-attrib {
    float: right !important;
    clear: both !important;
}

.maplibregl-ctrl-attrib-inner {
    text-align: right !important;
}








/*==================================================
 * 19. AUTO-MULTISELECT INITIALIZATION SCRIPT
 *================================================== */

/* This JavaScript automatically handles multiselect dropdowns */
/* Add this script tag to your layout or it will be auto-injected */

/*==================================================
 * 20. UI COMPONENTS - CARDS
 *================================================== */

/* Base card utilities */
.rhg-card {
    box-sizing: border-box;
    font-family: var(--font-family-main);
}

/* ========================================
 * 20.1 BAN CARDS (Big Ass Number)
 * ======================================== */

/* BAN Card - Default (with container) */
.rhg-card--ban-default {
    background-color: var(--rhg-sys-background-default);
    border: var(--rhg-sys-border-default);
    width: 240px;
    box-sizing: border-box;
}

.rhg-card--ban-default .rhg-card--ban-content {
    padding: var(--spacing-md);
    display: flex;
    flex-direction: column;
    gap: 0;
}

/* BAN Card - Filled (no container) */
.rhg-card--ban-filled {
    display: flex;
    flex-direction: column;
    gap: 0;
    max-width: 240px;
}

/* BAN Card Elements */
.rhg-card--ban-metric {
    font-family: var(--font-family-main);
    font-size: var(--rhg-sys-font-size-body);
    font-weight: var(--rhg-sys-font-weight-heading);
    color: var(--rhg-sys-color-text-default);
    line-height: normal;
    margin: 0;
}

.rhg-card--ban-value {
    font-family: var(--font-family-main);
    font-size: var(--rhg-sys-font-size-ban);
    font-weight: var(--rhg-sys-font-weight-heading);
    color: var(--rhg-sys-color-text-default);
    line-height: normal;
    margin: 0;
}

.rhg-card--ban-unit {
    font-family: var(--font-family-main);
    font-size: var(--rhg-sys-font-size-label);
    font-weight: var(--rhg-sys-font-weight-body);
    color: var(--rhg-sys-color-text-default);
    line-height: normal;
    margin: 0;
}

.rhg-card--ban-spacer {
    height: var(--rhg-sys-spacing-container-padding-default);
}

.rhg-card--ban-context {
    font-family: var(--font-family-main);
    font-size: var(--rhg-sys-font-size-body);
    font-weight: var(--rhg-sys-font-weight-body);
    color: var(--rhg-sys-color-text-default);
    line-height: normal;
    margin: 0;
}

/* ========================================
 * 20.2 DATA CALLOUT CARDS
 * ======================================== */

/* Data Callout Card - Default (horizontal) */
.rhg-card--data-callout-default {
    background-color: var(--rhg-sys-background-default);
    border: var(--rhg-sys-border-default);
    max-width: 650px;
    box-sizing: border-box;
}

.rhg-card--data-callout-default .rhg-card--data-callout-content {
    padding: var(--spacing-md);
    display: flex;
    gap: var(--rhg-sys-spacing-inline-lg);
    align-items: flex-start;
}

.rhg-card--data-callout-default .rhg-card--data-callout-ban {
    flex-shrink: 0;
    display: flex;
    flex-direction: column;
    gap: 0;
}

.rhg-card--data-callout-default .rhg-card--data-callout-description {
    flex: 1;
    display: flex;
    align-items: center;
}

.rhg-card--data-callout-default .rhg-card--data-callout-description p {
    font-family: var(--font-family-main);
    font-size: var(--rhg-sys-font-size-body);
    font-weight: var(--rhg-sys-font-weight-body);
    color: var(--rhg-sys-color-text-default);
    line-height: normal;
    margin: 0;
}

/* Data Callout Card - Filled (vertical) */
.rhg-card--data-callout-filled {
    display: flex;
    flex-direction: column;
    gap: 0;
    max-width: 650px;
}

.rhg-card--data-callout-filled .rhg-card--data-callout-ban {
    display: flex;
    flex-direction: column;
    gap: 0;
}

.rhg-card--data-callout-filled .rhg-card--data-callout-description {
    flex: 1;
    display: flex;
    align-items: center;
}

.rhg-card--data-callout-filled .rhg-card--data-callout-description p {
    font-family: var(--font-family-main);
    font-size: var(--rhg-sys-font-size-body);
    font-weight: var(--rhg-sys-font-weight-body);
    color: var(--rhg-sys-color-text-default);
    line-height: normal;
    margin: 0;
}

/* ========================================
 * 20.3 CALLOUT CARDS
 * ======================================== */

/* Callout Card - Base */
.rhg-card--callout {
    display: flex;
    gap: var(--rhg-sys-spacing-inline-md);
    align-items: flex-start;
    max-width: 800px;
    padding: var(--spacing-md);
    box-sizing: border-box;
}

/* Callout Card - Outlined */
.rhg-card--callout-outlined {
    background-color: var(--rhg-sys-background-default);
    border: var(--rhg-sys-border-default);
}

/* Callout Card - Filled (grey) */
.rhg-card--callout-filled {
    background-color: var(--rhg-sys-background-neutral);
    border: none;
}

/* Callout Card - Blue */
.rhg-card--callout-blue {
    background-color: var(--rhg-sys-color-supporting-light);
    border: none;
}

/* Callout Card - Success */
.rhg-card--callout-success {
    background-color: var(--rhg-green-lightest);
    border: 1px solid var(--rhg-green-light);
    border-left: 4px solid var(--rhg-green-medium);
}

/* Callout Card - Warning */
.rhg-card--callout-warning {
    background-color: var(--rhg-yellow-lightest);
    border: 1px solid var(--rhg-yellow-light);
    border-left: 4px solid var(--rhg-yellow-medium);
}

/* Callout Card - Error */
.rhg-card--callout-error {
    background-color: var(--rhg-red-lightest);
    border: 1px solid var(--rhg-red-light);
    border-left: 4px solid var(--rhg-red-medium);
}

/* Callout Card Elements */
.rhg-card--callout-icon {
    width: var(--rhg-sys-icon-size-default);
    height: var(--rhg-sys-icon-size-default);
    flex-shrink: 0;
    padding-top: 2px;
}

.rhg-card--callout-icon img {
    width: 100%;
    height: 100%;
    display: block;
}

.rhg-card--callout-content {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: var(--rhg-sys-spacing-inline-sm);
}

.rhg-card--callout-title {
    font-family: var(--font-family-main);
    font-size: var(--rhg-sys-font-size-label);
    font-weight: var(--rhg-sys-font-weight-heading);
    color: var(--rhg-sys-color-text-default);
    line-height: normal;
    margin: 0;
}

.rhg-card--callout-description {
    font-family: var(--font-family-main);
    font-size: var(--rhg-sys-font-size-label);
    font-weight: var(--rhg-sys-font-weight-body);
    color: var(--rhg-sys-color-text-default);
    line-height: 1.2;
    margin: 0;
}

/* Callout Card - With Link Arrow */
.rhg-card--callout-with-link {
    cursor: pointer;
    transition: background-color 0.2s ease;
}

.rhg-card--callout-with-link:hover {
    background-color: var(--rhg-blue-lightest);
}

.rhg-card--callout-arrow {
    width: 16px;
    height: 16px;
    flex-shrink: 0;
    margin-top: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: transform 0.2s ease;
}

.rhg-card--callout-arrow svg {
    width: 100%;
    height: 100%;
    stroke: var(--rhg-sys-color-text-default);
}

.rhg-card--callout-with-link:hover .rhg-card--callout-arrow {
    transform: translateX(2px);
}

/* ========================================
 * 20.4 RESEARCH CARDS
 * ======================================== */

.rhg-card--research {
    display: flex;
    flex-direction: column;
    width: 320px;
    background-color: var(--rhg-crisp-white);
    text-decoration: none;
    color: inherit;
    transition: transform 0.2s ease;
}

.rhg-card--research:hover {
    transform: translateY(-2px);
}

.rhg-card--research-image {
    width: 100%;
    height: 181px;
    overflow: hidden;
    background-color: var(--rhg-neutral-grey);
}

.rhg-card--research-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.rhg-card--research-placeholder {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--rhg-grey-medium);
    font-size: 14px;
}

.rhg-card--research-info {
    padding: var(--spacing-md);
    display: flex;
    flex-direction: column;
    gap: var(--rhg-sys-spacing-inline-sm);
    border: var(--rhg-sys-border-default);
    border-top: none;
}

.rhg-card--research-type {
    font-family: var(--font-family-main);
    font-size: var(--rhg-sys-font-size-label);
    font-weight: var(--rhg-sys-font-weight-body);
    color: var(--rhg-sys-color-text-muted);
    line-height: normal;
    margin: 0;
}

.rhg-card--research-title {
    font-family: var(--font-family-main);
    font-size: var(--rhg-sys-font-size-body);
    font-weight: var(--rhg-sys-font-weight-heading);
    color: var(--rhg-sys-color-text-default);
    line-height: normal;
    margin: 0;
}

/* ========================================
 * 20.5 PRODUCT CARDS
 * ======================================== */

.rhg-card--product {
    display: flex;
    flex-direction: column;
    width: 320px;
    padding: var(--spacing-md);
    border: var(--rhg-sys-border-default);
    background-color: var(--rhg-sys-background-default);
    text-decoration: none;
    color: var(--rhg-sys-color-text-default);
    transition: background-color 0.2s ease, color 0.2s ease;
    box-sizing: border-box;
    position: relative;
}

.rhg-card--product:hover {
    background-color: var(--rhg-sys-color-primary);
    color: var(--rhg-sys-color-on_surface-dark);
}

.rhg-card--product:hover .rhg-card--product-title {
    color: var(--rhg-sys-color-on_surface-dark);
}

.rhg-card--product:hover .rhg-card--product-description {
    color: var(--rhg-sys-color-on_surface-dark);
}

.rhg-card--product:hover .rhg-card--product-url-text {
    color: var(--rhg-sys-color-on_surface-dark);
}

.rhg-card--product-icon {
    width: 80px;
    height: 50px;
    margin-bottom: 16px;
    flex-shrink: 0;
}

.rhg-card--product-icon img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    display: block;
}

.rhg-card--product-content {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 0;
}

.rhg-card--product-title {
    font-family: var(--font-family-main);
    font-size: var(--rhg-sys-font-size-heading);
    font-weight: var(--rhg-sys-font-weight-heading);
    line-height: normal;
    margin: 0 0 var(--rhg-sys-spacing-inline-sm) 0;
}

.rhg-card--product-description {
    font-family: var(--font-family-main);
    font-size: var(--rhg-sys-font-size-body);
    font-weight: var(--rhg-sys-font-weight-body);
    line-height: normal;
    margin: 0;
}

.rhg-card--product-arrow {
    width: 16px;
    height: 16px;
    margin-top: 16px;
    align-self: flex-end;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: transform 0.2s ease;
}

.rhg-card--product-arrow svg {
    width: 100%;
    height: 100%;
    stroke: var(--rhg-sys-color-text-default);
    transition: stroke 0.2s ease;
}

.rhg-card--product:hover .rhg-card--product-arrow {
    transform: translateX(2px);
}

.rhg-card--product:hover .rhg-card--product-arrow svg {
    stroke: #ffffff;
}

/* Product card with display URL */
.rhg-card--product-divider {
    width: 100%;
    height: 1px;
    background-color: var(--rhg-sys-color-border-default);
    margin-top: var(--rhg-sys-spacing-inline-md);
    margin-bottom: var(--rhg-sys-spacing-inline-md);
    transition: background-color 0.2s ease;
}

.rhg-card--product:hover .rhg-card--product-divider {
    background-color: var(--rhg-sys-color-on_surface-dark);
}

.rhg-card--product-url {
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: 100%;
    gap: var(--rhg-sys-spacing-inline-sm);
}

.rhg-card--product-url-text {
    font-family: var(--font-family-main);
    font-size: var(--rhg-sys-font-size-label);
    font-weight: var(--rhg-sys-font-weight-body);
    line-height: normal;
    flex: 1;
}

.rhg-card--product-url-arrow {
    width: 16px;
    height: 16px;
    flex-shrink: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: transform 0.2s ease;
}

.rhg-card--product-url-arrow svg {
    width: 100%;
    height: 100%;
    stroke: var(--rhg-sys-color-text-default);
    transition: stroke 0.2s ease;
}

.rhg-card--product:hover .rhg-card--product-url-arrow {
    transform: translateX(2px);
}

.rhg-card--product:hover .rhg-card--product-url-arrow svg {
    stroke: #ffffff;
}

/* ========================================
 * 20.6 CARD GRID LAYOUTS
 * ======================================== */

.rhg-card-grid {
    display: grid;
    gap: var(--rhg-sys-spacing-inline-lg);
    width: 100%;
}

.rhg-card-grid--2-col {
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    max-width: 640px;
}

.rhg-card-grid--3-col {
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    max-width: 1000px;
}

.rhg-card-grid--4-col {
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
}

.rhg-card-grid--gap-small {
    gap: var(--rhg-sys-spacing-grid-compact);
}

.rhg-card-grid--gap-large {
    gap: var(--rhg-sys-spacing-section);
}

/* Responsive adjustments */
@media (max-width: 768px) {
    .rhg-card-grid {
        grid-template-columns: 1fr;
    }
    
    .rhg-card--ban-default,
    .rhg-card--ban-filled {
        max-width: 100%;
        width: 100%;
    }
    
    .rhg-card--data-callout-default .rhg-card--data-callout-content {
        flex-direction: column;
        gap: 16px;
    }
    
    .rhg-card--callout {
        flex-direction: column;
    }
    
    .rhg-card--research,
    .rhg-card--product {
        max-width: 100%;
        width: 100%;
    }
}
/* ========================================
 * NEW UI COMPONENTS (Tags, Buttons, Fields, etc.)
 * ======================================== */

/* ========================================
 * Design Tokens - Component Level
 * Based on Rhodium_Group_Design_Tokens.md
 * ======================================== */
:root {
    /* ===== Reference Tokens ===== */
    /* ⚠️ DO NOT USE THESE DIRECTLY IN CODE - Use system or component tokens instead */
    
    /* Reference - Primary colors */
    --rhg-ref-primary-blue: #0078AD;
    --rhg-ref-primary-orange: #E48360;
    --rhg-ref-primary-yellow: #EBBC6A;
    --rhg-ref-primary-softnavy: #003C58;
    --rhg-ref-primary-pastelblue: #CCE4EF;
    --rhg-ref-primary-white: #FFFFFF;
    --rhg-ref-primary-deepblack: #0A0A19;
    
    /* Reference - Blue palette */
    --rhg-ref-palette-blue-100: #ADD4E8;
    --rhg-ref-palette-blue-200: #70B3D6;
    --rhg-ref-palette-blue-base: #3293C5;
    --rhg-ref-palette-blue-700: #28769E;
    --rhg-ref-palette-blue-900: #1E5876;
    
    /* Reference - Orange palette */
    --rhg-ref-palette-orange-100: #F4CDBF;
    --rhg-ref-palette-orange-200: #ECA890;
    --rhg-ref-palette-orange-base: #E48360;
    --rhg-ref-palette-orange-700: #B6694D;
    --rhg-ref-palette-orange-900: #894F3A;
    
    /* Reference - Yellow palette */
    --rhg-ref-palette-yellow-100: #F7E4C3;
    --rhg-ref-palette-yellow-200: #F1D097;
    --rhg-ref-palette-yellow-base: #EBBC6A;
    --rhg-ref-palette-yellow-700: #BC9655;
    --rhg-ref-palette-yellow-900: #8D7140;
    
    /* Reference - Cyan palette */
    --rhg-ref-palette-cyan-100: #BAE9EC;
    --rhg-ref-palette-cyan-200: #86D8DD;
    --rhg-ref-palette-cyan-base: #52C7CF;
    --rhg-ref-palette-cyan-700: #429FA6;
    --rhg-ref-palette-cyan-900: #31777C;
    
    /* Reference - Green palette */
    --rhg-ref-palette-green-100: #B7D9D1;
    --rhg-ref-palette-green-200: #82BDAE;
    --rhg-ref-palette-green-base: #4CA08B;
    --rhg-ref-palette-green-700: #3D806F;
    --rhg-ref-palette-green-900: #2E6053;
    
    /* Reference - Purple palette */
    --rhg-ref-palette-purple-100: #C6C3D0;
    --rhg-ref-palette-purple-200: #9C97AD;
    --rhg-ref-palette-purple-base: #716A8A;
    --rhg-ref-palette-purple-700: #5A556E;
    --rhg-ref-palette-purple-900: #444053;
    
    /* Reference - Gray palette */
    --rhg-ref-palette-gray-100: #C9CBCB;
    --rhg-ref-palette-gray-200: #A1A3A4;
    --rhg-ref-palette-gray-base: #797C7D;
    --rhg-ref-palette-gray-700: #616364;
    --rhg-ref-palette-gray-900: #494A4B;
    
    /* Reference - Red palette (for danger/destructive actions) */
    --rhg-ref-palette-red-100: #F4CFCF;
    --rhg-ref-palette-red-200: #ECA5A5;
    --rhg-ref-palette-red-base: #D64545;
    --rhg-ref-palette-red-700: #AC3737;
    --rhg-ref-palette-red-900: #812929;
    
    /* Reference - line thickness */
    --rhg-ref-line-thick: 1px;
    --rhg-ref-line-thin: 0.5px;
    
    /* Reference - spacing */
    --rhg-ref-spacing-0_5: 4px;
    --rhg-ref-spacing-1: 8px;
    --rhg-ref-spacing-1_5: 12px;
    --rhg-ref-spacing-2: 16px;
    --rhg-ref-spacing-3: 24px;
    --rhg-ref-spacing-4: 32px;
    --rhg-ref-spacing-5: 40px;
    --rhg-ref-spacing-6: 48px;
    --rhg-ref-spacing-7: 56px;
    
    /* Reference - font */
    --rhg-ref-size-font-1: 10px;
    --rhg-ref-size-font-1_5: 12px;
    --rhg-ref-size-font-1_75: 14px;
    --rhg-ref-size-font-2: 16px;
    --rhg-ref-size-font-2_25: 18px;
    --rhg-ref-size-font-2_5: 20px;
    --rhg-ref-size-font-3: 24px;
    --rhg-ref-size-font-4: 32px;
    --rhg-ref-size-font-5: 40px;
    --rhg-ref-size-font-6: 48px;
    --rhg-ref-font-weight-300: 300;
    --rhg-ref-font-weight-400: 400;
    --rhg-ref-font-weight-500: 500;
    --rhg-ref-font-weight-600: 600;
    --rhg-ref-font-weight-700: 700;
    
    /* Reference - border radius */
    --rhg-ref-radius-none: 0px;
    --rhg-ref-radius-sm: 4px;
    --rhg-ref-radius-md: 8px;
    
    /* ===== System Tokens ===== */
    /* ✅ USE THESE IN YOUR CODE - These have semantic meaning */
    
    /* System - Colors */
    --rhg-sys-color-primary: var(--rhg-ref-primary-blue);
    --rhg-sys-color-accent-china: var(--rhg-ref-primary-orange);
    --rhg-sys-color-accent-enc: var(--rhg-ref-primary-yellow);
    --rhg-sys-color-supporting-light: var(--rhg-ref-primary-pastelblue);
    --rhg-sys-color-supporting-dark: var(--rhg-ref-primary-softnavy);
    --rhg-sys-color-text-primary: var(--rhg-ref-primary-deepblack);
    --rhg-sys-color-border-default: var(--rhg-ref-palette-gray-100);
    --rhg-sys-background-default: var(--rhg-ref-primary-white);
    --rhg-sys-color-selected: var(--rhg-ref-primary-blue);
    --rhg-sys-color-surface-default: var(--rhg-ref-primary-blue);
    --rhg-sys-color-on_surface-dark: var(--rhg-ref-primary-white);
    --rhg-sys-color-surface_variant-light: var(--rhg-ref-primary-pastelblue);
    --rhg-sys-color-on_surface_variant-light: var(--rhg-ref-primary-deepblack);
    --rhg-sys-color-surface_variant-dark: var(--rhg-ref-primary-softnavy);
    --rhg-sys-color-on_surface_variant-dark: var(--rhg-ref-primary-white);
    --rhg-sys-color-deemphasized: var(--rhg-ref-palette-gray-base);
    
    /* System - Additional color utilities (for backward compatibility) */
    --rhg-sys-color-text-default: var(--rhg-sys-color-text-primary);
    --rhg-sys-color-text-muted: var(--rhg-ref-palette-gray-base);
    --rhg-sys-background-neutral: #F2F2F2;
    --rhg-sys-color-danger: var(--rhg-ref-palette-red-base);
    --rhg-sys-color-danger-light: var(--rhg-ref-palette-red-200);
    --rhg-sys-color-danger-dark: var(--rhg-ref-palette-red-700);
    
    /* System - Spacing */
    --rhg-sys-spacing-page-margin: 80px; /* <1440px */
    --rhg-sys-spacing-page-margin-large: 120px; /* >1440px */
    --rhg-sys-spacing-page-margin-mobile: var(--rhg-ref-spacing-3);
    --rhg-sys-spacing-section: var(--rhg-ref-spacing-5);
    --rhg-sys-spacing-sub-section: var(--rhg-ref-spacing-3);
    --rhg-sys-spacing-after-heading: var(--rhg-ref-spacing-2);
    --rhg-sys-spacing-container-padding-default: var(--rhg-ref-spacing-2);
    --rhg-sys-spacing-container-padding-compact: var(--rhg-ref-spacing-1);
    --rhg-sys-spacing-inline-sm: var(--rhg-ref-spacing-0_5);
    --rhg-sys-spacing-inline-md: var(--rhg-ref-spacing-2);
    --rhg-sys-spacing-inline-lg: var(--rhg-ref-spacing-4);
    --rhg-sys-spacing-grid-compact: var(--rhg-ref-spacing-2);
    --rhg-sys-spacing-grid-default: var(--rhg-ref-spacing-3);
    --rhg-sys-spacing-form-field: var(--rhg-ref-spacing-2);
    
    /* System - Typography */
    --rhg-sys-font-size-body: var(--rhg-ref-size-font-2);
    --rhg-sys-font-size-heading: var(--rhg-ref-size-font-3);
    --rhg-sys-font-size-subheading: var(--rhg-ref-size-font-2_5);
    --rhg-sys-font-size-label: var(--rhg-ref-size-font-1_75);
    --rhg-sys-font-size-product-name: var(--rhg-ref-size-font-4);
    --rhg-sys-font-size-ban: var(--rhg-ref-size-font-5);
    --rhg-sys-font-size-small: var(--rhg-ref-size-font-1_5);
    --rhg-sys-font-weight-body: var(--rhg-ref-font-weight-400);
    --rhg-sys-font-weight-heading: var(--rhg-ref-font-weight-700);
    --rhg-sys-font-weight-subheading: var(--rhg-ref-font-weight-600);
    --rhg-sys-font-weight-emphasis: var(--rhg-ref-font-weight-500);
    
    /* System - Border properties */
    --rhg-sys-border-default: 0.5px solid var(--rhg-sys-color-border-default);
    --rhg-sys-border-thick: 1px solid var(--rhg-sys-color-border-default);
    --rhg-sys-border-emphasis: 0.5px solid var(--rhg-sys-color-text-primary);
    --rhg-sys-radius-none: var(--rhg-ref-radius-none);
    --rhg-sys-radius-default: var(--rhg-ref-radius-sm);
    --rhg-sys-radius-large: var(--rhg-ref-radius-md);
    
    /* ===== Component Tokens - Tags ===== */
    --rhg-comp-tag-success-border: var(--rhg-ref-palette-green-200);
    --rhg-comp-tag-success-fill: var(--rhg-ref-palette-green-100);
    --rhg-comp-tag-success-text-color: var(--rhg-ref-palette-green-700);
    
    --rhg-comp-tag-warning-border: var(--rhg-ref-palette-yellow-200);
    --rhg-comp-tag-warning-fill: var(--rhg-ref-palette-yellow-100);
    --rhg-comp-tag-warning-text-color: var(--rhg-ref-palette-yellow-700);
    
    --rhg-comp-tag-danger-border: var(--rhg-ref-palette-orange-200);
    --rhg-comp-tag-danger-fill: var(--rhg-ref-palette-orange-100);
    --rhg-comp-tag-danger-text-color: var(--rhg-ref-palette-orange-700);
    
    --rhg-comp-tag-information-border: var(--rhg-ref-palette-blue-200);
    --rhg-comp-tag-information-fill: var(--rhg-ref-palette-blue-100);
    --rhg-comp-tag-information-text-color: var(--rhg-ref-palette-blue-700);
    
    --rhg-comp-tag-secondary-border: var(--rhg-ref-palette-gray-200);
    --rhg-comp-tag-secondary-fill: var(--rhg-ref-palette-gray-100);
    --rhg-comp-tag-secondary-text-color: var(--rhg-ref-palette-gray-700);
    
    --rhg-comp-tag-shape-radius: 8px;
    --rhg-comp-tag-border-thickness: var(--rhg-ref-line-thick);
    --rhg-comp-tag-text-size: var(--rhg-ref-size-font-1_5);
    --rhg-comp-tag-text-weight: var(--rhg-sys-font-weight-emphasis);
    --rhg-comp-tag-padding-top-bottom: 4px;
    --rhg-comp-tag-padding-left-right: 8px;
    
    /* ===== Component Tokens - Buttons ===== */
    --rhg-comp-button-padding-left-right: 20px;
    --rhg-comp-button-padding-top-bottom: 10px;
    --rhg-comp-button-inline-space: var(--rhg-sys-spacing-inline-sm);
    --rhg-comp-button-text-size: var(--rhg-sys-font-size-body);
    --rhg-comp-button-text-weight: var(--rhg-sys-font-weight-emphasis);
    --rhg-comp-button-height: 36px;
    
    /* Button - Filled style */
    --rhg-comp-button-filled-color-surface: var(--rhg-sys-color-primary);
    --rhg-comp-button-filled-color-on_surface: var(--rhg-sys-color-on_surface-dark);
    --rhg-comp-button-filled-hover-color-surface-opacity: 0.12;
    --rhg-comp-button-filled-icon-color: var(--rhg-sys-color-on_surface-dark);
    
    /* Button - Tonal style */
    --rhg-comp-button-tonal-color-surface: var(--rhg-sys-color-supporting-light);
    --rhg-comp-button-tonal-color-on_surface: var(--rhg-sys-color-text-primary);
    --rhg-comp-button-tonal-hover-color-surface-opacity: 0.12;
    --rhg-comp-button-tonal-icon-color: var(--rhg-sys-color-primary);
    
    /* Button - Outlined style */
    --rhg-comp-button-outlined-border-color: var(--rhg-sys-color-border-default);
    --rhg-comp-button-outlined-color-on_surface: var(--rhg-sys-color-text-primary);
    --rhg-comp-button-outlined-hover-border-color: var(--rhg-sys-color-primary);
    --rhg-comp-button-outlined-hover-text-color: var(--rhg-sys-color-primary);
    --rhg-comp-button-outlined-icon-color: var(--rhg-sys-color-primary);
    
    /* Button - Text style */
    --rhg-comp-button-text-color: var(--rhg-sys-color-text-primary);
    --rhg-comp-button-text-hover-text-color: var(--rhg-sys-color-primary);
    --rhg-comp-button-text-icon-color: var(--rhg-sys-color-text-primary);
    --rhg-comp-button-text-icon-hover-color: var(--rhg-sys-color-primary);
    
    /* Button - Disabled state */
    --rhg-comp-button-filled-tonal-disabled-color-surface: var(--rhg-ref-palette-gray-100);
    --rhg-comp-button-filled-tonal-disabled-color-on_surface: var(--rhg-ref-palette-gray-200);
    --rhg-comp-button-filled-tonal-disabled-icon-color: var(--rhg-ref-palette-gray-200);
    --rhg-comp-button-outlined-disabled-border-color: var(--rhg-sys-color-border-default);
    --rhg-comp-button-outlined-disabled-text-color: var(--rhg-ref-palette-gray-200);
    --rhg-comp-button-outlined-disabled-icon-color: var(--rhg-ref-palette-gray-100);
    --rhg-comp-button-text-disabled-color: var(--rhg-ref-palette-gray-200);
    --rhg-comp-button-text-disabled-icon-color: var(--rhg-ref-palette-gray-100);
    
    /* Button - Danger style (for destructive actions) */
    --rhg-comp-button-danger-color-surface: var(--rhg-sys-color-danger);
    --rhg-comp-button-danger-color-on_surface: var(--rhg-sys-color-on_surface-dark);
    --rhg-comp-button-danger-hover-color-surface: var(--rhg-sys-color-danger-dark);
    --rhg-comp-button-danger-icon-color: var(--rhg-sys-color-on_surface-dark);
    
    /* Tag - Danger style (using red instead of orange for critical warnings) */
    --rhg-comp-tag-critical-border: var(--rhg-ref-palette-red-200);
    --rhg-comp-tag-critical-fill: var(--rhg-ref-palette-red-100);
    --rhg-comp-tag-critical-text-color: var(--rhg-ref-palette-red-700);
    
    /* ===== Component Tokens - Header ===== */
    --rhg-comp-header-brand-color: var(--rhg-sys-color-text-primary);
    --rhg-comp-header-brand-font-size: var(--rhg-sys-font-size-product-name);
    --rhg-comp-header-brand-font-weight: var(--rhg-sys-font-weight-heading);
    --rhg-comp-header-spacing-right: 66px;
    --rhg-comp-header-background-color: var(--rhg-sys-background-default);
    --rhg-comp-header-height: 54px;
    
    /* ===== Component Tokens - Chart ===== */
    --rhg-comp-chart-title-font-weight: var(--rhg-sys-font-weight-heading);
    --rhg-comp-chart-title-font-size: var(--rhg-ref-size-font-2);
    --rhg-comp-chart-subtitle-font-weight: var(--rhg-sys-font-weight-body);
    --rhg-comp-chart-subtitle-font-size: var(--rhg-ref-size-font-1_75);
    --rhg-comp-chart-source-note-font-weight: var(--rhg-sys-font-weight-body);
    --rhg-comp-chart-source-note-font-size: var(--rhg-ref-size-font-1_5);
    --rhg-comp-chart-text-color-default: var(--rhg-sys-color-text-primary);
    --rhg-comp-chart-font-family: 'Roboto', sans-serif;
    --rhg-comp-chart-font-weight-default: var(--rhg-sys-font-weight-body);
    --rhg-comp-chart-font-size-default: var(--rhg-sys-font-size-label);
    --rhg-comp-chart-data_labels-font-weight-emphasized: var(--rhg-sys-font-weight-emphasis);
    --rhg-comp-chart-data_labels-font-color-on_light_surface: var(--rhg-sys-color-text-primary);
    --rhg-comp-chart-data_labels-font-color-on_dark_surface: var(--rhg-sys-color-on_surface-dark);
    --rhg-comp-chart-axis-line-thickness: var(--rhg-ref-line-thick);
    --rhg-comp-chart-axis-line-color: var(--rhg-sys-color-border-default);
    --rhg-comp-chart-tooltip-background: var(--rhg-sys-background-default);
    --rhg-comp-chart-tooltip-box-shadow: rgba(0, 0, 0, 0.1) 0px 1px 3px 0px;
    --rhg-comp-chart-tooltip-padding: var(--rhg-sys-spacing-container-padding-compact);
    --rhg-comp-chart-tooltip-category-font-weight: var(--rhg-sys-font-weight-heading);
    --rhg-comp-chart-tooltip-value_label-font-weight: var(--rhg-sys-font-weight-body);
    --rhg-comp-chart-tooltip-value-font-size: var(--rhg-sys-font-size-body);
    --rhg-comp-chart-tooltip-value-font-weight: var(--rhg-sys-font-weight-heading);
    --rhg-comp-chart-annotation-line-color-default: var(--rhg-sys-color-border-default);
    --rhg-comp-chart-annotation-line-color-emphasized: var(--rhg-sys-color-text-primary);
    --rhg-comp-chart-annotation-line-thickness: var(--rhg-ref-line-thin);
    --rhg-comp-chart-gridlines-thickness: var(--rhg-ref-line-thin);
    --rhg-comp-chart-gridlines-color: var(--rhg-sys-color-border-default);
    
    /* ===== Component Tokens - Table ===== */
    --rhg-comp-table-text-color: var(--rhg-sys-color-text-primary);
    --rhg-comp-table-font-size: 14px;
    --rhg-comp-table-font-weight: var(--rhg-sys-font-weight-body);
    --rhg-comp-table-header-font-weight: var(--rhg-sys-font-weight-heading);
    --rhg-comp-table-header-bottom-border-thickness: var(--rhg-ref-line-thin);
    --rhg-comp-table-header-bottom-border-color: var(--rhg-sys-color-text-primary);
    --rhg-comp-table-cell-padding: var(--rhg-sys-spacing-container-padding-compact);
    --rhg-comp-table-line-division-color: var(--rhg-sys-color-border-default);
    --rhg-comp-table-line-division-thickness: var(--rhg-ref-line-thin);
    --rhg-comp-table-zebra-stripes-color: #F2F2F2;
    
    /* ===== Component Tokens - Snackbar/Toast ===== */
    --rhg-comp-snackbar-text-size: var(--rhg-sys-font-size-body);
    --rhg-comp-snackbar-text-color: var(--rhg-sys-color-text-primary);
    --rhg-comp-snackbar-text-weight: var(--rhg-sys-font-weight-body);
    --rhg-comp-snackbar-action-text-size: var(--rhg-sys-font-size-body);
    --rhg-comp-snackbar-action-text-weight: var(--rhg-sys-font-weight-heading);
    --rhg-comp-snackbar-action-text-color: var(--rhg-sys-color-primary);
    --rhg-comp-snackbar-background-color: #F2F2F2;
    --rhg-comp-snackbar-border-color: var(--rhg-sys-color-border-default);
    --rhg-comp-snackbar-border-thickness: var(--rhg-ref-line-thin);
    --rhg-comp-snackbar-padding: var(--rhg-sys-spacing-container-padding-compact);
}

/* ========================================
 * TAG COMPONENTS
 * ======================================== */
.rhg-tag {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: var(--rhg-comp-tag-padding-top-bottom) var(--rhg-comp-tag-padding-left-right);
    border-radius: var(--rhg-comp-tag-shape-radius);
    border-width: var(--rhg-comp-tag-border-thickness);
    border-style: solid;
    font-family: var(--font-family-main);
    font-size: var(--rhg-comp-tag-text-size);
    font-weight: var(--rhg-comp-tag-text-weight);
    text-transform: uppercase;
    line-height: 1;
    white-space: nowrap;
    box-sizing: border-box;
}

/* Tag sizes */
.rhg-tag--small {
    padding: var(--rhg-comp-tag-padding-top-bottom) var(--rhg-comp-tag-padding-left-right);
    font-size: var(--rhg-comp-tag-text-size);
}

.rhg-tag--medium {
    padding: 6px 12px;
    font-size: 14px;
}

/* Tag styles */
.rhg-tag--success {
    background-color: var(--rhg-comp-tag-success-fill);
    border-color: var(--rhg-comp-tag-success-border);
    color: var(--rhg-comp-tag-success-text-color);
}

.rhg-tag--warning {
    background-color: var(--rhg-comp-tag-warning-fill);
    border-color: var(--rhg-comp-tag-warning-border);
    color: var(--rhg-comp-tag-warning-text-color);
}

.rhg-tag--danger {
    background-color: var(--rhg-comp-tag-danger-fill);
    border-color: var(--rhg-comp-tag-danger-border);
    color: var(--rhg-comp-tag-danger-text-color);
}

.rhg-tag--info {
    background-color: var(--rhg-comp-tag-information-fill);
    border-color: var(--rhg-comp-tag-information-border);
    color: var(--rhg-comp-tag-information-text-color);
}

.rhg-tag--secondary {
    background-color: var(--rhg-comp-tag-secondary-fill);
    border-color: var(--rhg-comp-tag-secondary-border);
    color: var(--rhg-comp-tag-secondary-text-color);
}

.rhg-tag--critical {
    background-color: var(--rhg-comp-tag-critical-fill);
    border-color: var(--rhg-comp-tag-critical-border);
    color: var(--rhg-comp-tag-critical-text-color);
}

/* Tag group */
.rhg-tag-group {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
}

.rhg-tag-group--gap-small {
    gap: var(--rhg-ref-spacing-1);
}

.rhg-tag-group--gap-medium {
    gap: var(--rhg-ref-spacing-2);
}

/* ========================================
 * BUTTON COMPONENTS
 * ======================================== */
.rhg-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: var(--rhg-comp-button-inline-space);
    padding: var(--rhg-comp-button-padding-top-bottom) var(--rhg-comp-button-padding-left-right);
    height: var(--rhg-comp-button-height);
    font-family: var(--font-family-main);
    font-size: var(--rhg-comp-button-text-size);
    font-weight: var(--rhg-comp-button-text-weight);
    line-height: 1;
    border-radius: 0px;
    border: none;
    cursor: pointer;
    transition: all 0.2s ease;
    text-decoration: none;
    box-sizing: border-box;
    white-space: nowrap;
}

.rhg-button__text {
    display: inline-block;
    color: inherit; /* Inherit color from parent button */
}

.rhg-button__icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: var(--rhg-sys-icon-size-default);
    height: var(--rhg-sys-icon-size-default);
    flex-shrink: 0;
}

.rhg-button__icon svg {
    width: 100%;
    height: 100%;
}

/* Filled button */
.rhg-button--filled {
    background-color: var(--rhg-comp-button-filled-color-surface);
    color: #FFFFFF !important; /* White text on dark background */
}

.rhg-button--filled * {
    color: #FFFFFF !important; /* Ensure all child elements are white */
}

.rhg-button--filled:hover:not(:disabled) {
    background-color: rgba(0, 120, 173, 0.88); /* Primary blue with hover opacity */
    color: #FFFFFF !important; /* Keep white text on hover */

}

.rhg-button--filled:hover:not(:disabled) * {
    color: #FFFFFF !important; /* Ensure all child elements stay white on hover */
}

.rhg-button--filled:active:not(:disabled) {
    transform: translateY(0);
    color: #FFFFFF !important; /* Keep white text on active */
}

.rhg-button--filled:active:not(:disabled) * {
    color: #FFFFFF !important; /* Ensure all child elements stay white on active */
}

.rhg-button--filled .rhg-button__icon svg {
    stroke: var(--rhg-comp-button-filled-icon-color);
    fill: var(--rhg-comp-button-filled-icon-color);
}

/* Tonal button */
.rhg-button--tonal {
    background-color: var(--rhg-comp-button-tonal-color-surface);
    color: var(--rhg-comp-button-tonal-color-on_surface);
}

.rhg-button--tonal:hover:not(:disabled) {
    background-color: rgba(204, 228, 239, 0.88); /* Pastel blue with hover opacity */
}

.rhg-button--tonal:active:not(:disabled) {
    transform: translateY(0);
}

.rhg-button--tonal .rhg-button__icon svg {
    stroke: var(--rhg-comp-button-tonal-icon-color);
    fill: var(--rhg-comp-button-tonal-icon-color);
}

/* Outlined button */
.rhg-button--outlined {
    background-color: transparent;
    color: var(--rhg-comp-button-outlined-color-on_surface);
    border: var(--rhg-ref-line-thick) solid var(--rhg-comp-button-outlined-border-color);
}

.rhg-button--outlined:hover:not(:disabled) {
    border-color: var(--rhg-comp-button-outlined-hover-border-color);
    color: var(--rhg-comp-button-outlined-hover-text-color);
    background-color: rgba(0, 120, 173, 0.04);
}

.rhg-button--outlined .rhg-button__icon svg {
    stroke: var(--rhg-comp-button-outlined-icon-color);
    fill: var(--rhg-comp-button-outlined-icon-color);
}

/* Text button */
.rhg-button--text {
    background-color: transparent;
    color: var(--rhg-comp-button-text-color);
    padding-left: 8px;
    padding-right: 8px;
}

.rhg-button--text:hover:not(:disabled) {
    color: var(--rhg-comp-button-text-hover-text-color);
    background-color: rgba(0, 120, 173, 0.04);
}

.rhg-button--text .rhg-button__icon svg {
    stroke: var(--rhg-comp-button-text-icon-color);
    fill: var(--rhg-comp-button-text-icon-color);
}

.rhg-button--text:hover:not(:disabled) .rhg-button__icon svg {
    stroke: var(--rhg-comp-button-text-icon-hover-color);
    fill: var(--rhg-comp-button-text-icon-hover-color);
}

/* Danger button (for destructive/critical actions like delete) */
.rhg-button--danger {
    background-color: var(--rhg-comp-button-danger-color-surface);
    color: #FFFFFF !important; /* White text on red background */
}

.rhg-button--danger * {
    color: #FFFFFF !important; /* Ensure all child elements are white */
}

.rhg-button--danger:hover:not(:disabled) {
    background-color: var(--rhg-comp-button-danger-hover-color-surface);
    color: #FFFFFF !important;

}

.rhg-button--danger:hover:not(:disabled) * {
    color: #FFFFFF !important;
}

.rhg-button--danger:active:not(:disabled) {
    transform: translateY(0);
    color: #FFFFFF !important;
}

.rhg-button--danger:active:not(:disabled) * {
    color: #FFFFFF !important;
}

.rhg-button--danger .rhg-button__icon svg {
    stroke: var(--rhg-comp-button-danger-icon-color);
    fill: var(--rhg-comp-button-danger-icon-color);
}

/* Disabled state */
.rhg-button--disabled,
.rhg-button:disabled {
    cursor: not-allowed;
    opacity: 0.6;
}

.rhg-button--filled.rhg-button--disabled,
.rhg-button--filled:disabled,
.rhg-button--tonal.rhg-button--disabled,
.rhg-button--tonal:disabled {
    background-color: var(--rhg-comp-button-filled-tonal-disabled-color-surface);
    color: var(--rhg-comp-button-filled-tonal-disabled-color-on_surface);
}

.rhg-button--outlined.rhg-button--disabled,
.rhg-button--outlined:disabled {
    border-color: var(--rhg-comp-button-outlined-disabled-border-color);
    color: var(--rhg-comp-button-outlined-disabled-text-color);
}

.rhg-button--text.rhg-button--disabled,
.rhg-button--text:disabled {
    color: var(--rhg-comp-button-text-disabled-color);
}

/* Button group */
.rhg-button-group {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
}

.rhg-button-group--gap-small {
    gap: var(--rhg-ref-spacing-1);
}

.rhg-button-group--gap-medium {
    gap: var(--rhg-ref-spacing-2);
}

.rhg-button-group--gap-large {
    gap: var(--spacing-lg);
}

/* ========================================
 * FORM FIELD COMPONENTS
 * ======================================== */
.rhg-field {
    display: flex;
    flex-direction: column;
    gap: var(--rhg-sys-spacing-inline-sm);
    width: 100%;
}

.rhg-field__label {
    display: flex;
    align-items: center;
    gap: var(--rhg-sys-spacing-inline-sm);
    font-family: var(--font-family-main);
    font-size: var(--rhg-sys-font-size-label);
    font-weight: var(--rhg-sys-font-weight-emphasis);
    color: var(--rhg-sys-color-text-primary);
    line-height: 1.4;
}

.rhg-field__required {
    color: var(--rhg-comp-tag-danger-text-color);
}

.rhg-field__info-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: var(--rhg-sys-icon-size-default);
    height: var(--rhg-sys-icon-size-default);
}

.rhg-field__info-icon svg {
    width: 100%;
    height: 100%;
    stroke: var(--rhg-sys-color-border-default);
    fill: var(--rhg-sys-color-border-default);
}

.rhg-field__tag {
    margin-left: auto;
}

.rhg-field__input {
    width: 100%;
    padding: 10px 12px;
    font-family: var(--font-family-main);
    font-size: var(--rhg-sys-font-size-body);
    font-weight: var(--rhg-sys-font-weight-body);
    color: var(--rhg-sys-color-text-primary);
    background-color: var(--rhg-sys-background-default);
    border: var(--rhg-sys-border-thick);
    border-radius: var(--rhg-sys-radius-none);
    box-sizing: border-box;
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.rhg-field__input:focus {
    outline: none;
    border-color: var(--rhg-sys-color-primary);
    box-shadow: 0 0 0 3px rgba(0, 120, 173, 0.1);
}

.rhg-field__input::placeholder {
    color: var(--rhg-ref-palette-gray-200);
}

.rhg-field__textarea {
    resize: vertical;
    min-height: 80px;
    line-height: 1.5;
}

.rhg-field__help-text {
    font-family: var(--font-family-main);
    font-size: var(--rhg-ref-size-font-1_5);
    font-weight: var(--rhg-sys-font-weight-body);
    color: var(--rhg-ref-palette-gray-700);
    line-height: 1.4;
}

.rhg-field__error-message {
    font-family: var(--font-family-main);
    font-size: var(--rhg-ref-size-font-1_5);
    font-weight: var(--rhg-sys-font-weight-body);
    color: var(--rhg-comp-tag-danger-text-color);
    line-height: 1.4;
}

.rhg-field__char-count {
    font-family: var(--font-family-main);
    font-size: var(--rhg-ref-size-font-1_5);
    font-weight: var(--rhg-sys-font-weight-body);
    color: var(--rhg-ref-palette-gray-700);
    text-align: right;
}

/* Error state */
.rhg-field--error .rhg-field__input {
    border-color: var(--rhg-comp-tag-danger-border);
}

.rhg-field--error .rhg-field__input:focus {
    border-color: var(--rhg-comp-tag-danger-text-color);
    box-shadow: 0 0 0 3px rgba(230, 131, 96, 0.1);
}

/* Disabled state */
.rhg-field--disabled .rhg-field__label {
    opacity: 0.6;
}

.rhg-field--disabled .rhg-field__input {
    background-color: var(--rhg-sys-background-neutral);
    cursor: not-allowed;
    opacity: 0.6;
}

/* ========================================
 * FORM LAYOUT COMPONENTS
 * ======================================== */
.rhg-form-grid {
    display: grid;
    width: 100%;
}

.rhg-form-grid--1-col {
    grid-template-columns: 1fr;
}

.rhg-form-grid--2-col {
    grid-template-columns: repeat(2, 1fr);
}

.rhg-form-grid--3-col {
    grid-template-columns: repeat(3, 1fr);
}

.rhg-form-grid--4-col {
    grid-template-columns: repeat(4, 1fr);
}

.rhg-form-grid--gap-compact {
    gap: var(--rhg-ref-spacing-2);
}

.rhg-form-grid--gap-default {
    gap: var(--spacing-lg);
}

.rhg-form-grid--gap-comfortable {
    gap: var(--spacing-xl);
}

/* Form section */
.rhg-form-section {
    display: flex;
    flex-direction: column;
    gap: var(--spacing-lg);
}

.rhg-form-section__title {
    font-family: var(--font-family-main);
    font-size: 24px;
    font-weight: var(--rhg-sys-font-weight-heading);
    color: var(--rhg-sys-color-text-primary);
    margin: 0;
    line-height: 1.3;
}

.rhg-form-section__description {
    font-family: var(--font-family-main);
    font-size: var(--rhg-sys-font-size-body);
    font-weight: var(--rhg-sys-font-weight-body);
    color: var(--rhg-ref-palette-gray-700);
    margin: 0;
    line-height: 1.5;
}

/* Responsive form grids */
@media (max-width: 768px) {
    .rhg-form-grid--2-col,
    .rhg-form-grid--3-col,
    .rhg-form-grid--4-col {
        grid-template-columns: 1fr;
    }
}

/* ========================================
 * TAB COMPONENTS
 * ======================================== */
 
.rhg-tabs {
    display: flex;
    flex-direction: column;
    width: 100%;
}

.rhg-tabs__nav {
    display: flex;
    align-items: flex-end;
    gap: var(--rhg-sys-spacing-inline-md);
    border-bottom: var(--rhg-sys-border-default);
    min-height: 54px;
    padding: 0 !important;
    margin: 0;
    width: 100%;
    background: none !important;
    background-color: transparent !important;
    height: auto !important; /* Override nav height */
}

.rhg-tab {
    /* Explicit resets to override any inherited styles */
    position: relative;
    display: inline-flex;
    align-items: center;
    padding: var(--rhg-sys-spacing-container-padding-compact);
    
    /* Typography */
    font-family: var(--font-family-main) !important;
    font-size: var(--rhg-sys-font-size-body);
    font-weight: var(--rhg-sys-font-weight-body);
    color: var(--rhg-sys-color-text-primary) !important;
    line-height: 1.2;
    text-decoration: none;
    white-space: nowrap;
    
    /* Remove all backgrounds and borders except bottom */
    background: none !important;
    background-color: transparent !important;
    border: none !important;
    border-bottom: 4px solid transparent !important;
    box-shadow: none !important;
    
    /* Interaction */
    cursor: pointer;
    transition: color 0.2s ease, border-color 0.2s ease;
    margin-bottom: -0.5px; /* Offset to overlay the container border */
    box-sizing: border-box;
}

.rhg-tab:hover {
    color: var(--rhg-sys-color-primary) !important;
    background: none !important;
    background-color: transparent !important;
}

.rhg-tab:focus {
    outline: none;
    background: none !important;
    background-color: transparent !important;
}

.rhg-tab:active {
    background: none !important;
    background-color: transparent !important;
}

.rhg-tab--active {
    font-weight: var(--rhg-sys-font-weight-heading) !important;
    color: var(--rhg-sys-color-primary) !important;
    border-bottom-color: var(--rhg-sys-color-primary) !important;
    background: none !important;
    background-color: transparent !important;
}

/* Tab panel */
.rhg-tab-panel {
    padding: var(--spacing-lg) 0;
}

.rhg-tab-panel[hidden] {
    display: none;
}

.rhg-tab-panel--active {
    display: block;
}

/* Tab JavaScript functionality */
/* Add this script to make tabs interactive:
   
   document.addEventListener('DOMContentLoaded', function() {
       const tabs = document.querySelectorAll('.rhg-tab');
       tabs.forEach(tab => {
           tab.addEventListener('click', function(e) {
               if (this.getAttribute('href').startsWith('#tab-')) {
                   e.preventDefault();
                   const tabId = this.getAttribute('data-tab-id');
                   const container = this.closest('.rhg-tabs');
                   
                   // Update active tab
                   container.querySelectorAll('.rhg-tab').forEach(t => t.classList.remove('rhg-tab--active'));
                   this.classList.add('rhg-tab--active');
                   
                   // Update active panel
                   const allPanels = document.querySelectorAll('.rhg-tab-panel');
                   allPanels.forEach(panel => {
                       panel.hidden = true;
                       panel.classList.remove('rhg-tab-panel--active');
                   });
                   
                   const targetPanel = document.getElementById('tab-' + tabId);
                   if (targetPanel) {
                       targetPanel.hidden = false;
                       targetPanel.classList.add('rhg-tab-panel--active');
                   }
               }
           });
       });
   });
*/

/* ========================================
 * SECTION COMPONENTS
 * ======================================== */
.rhg-section {
    display: flex;
    flex-direction: column;
}

.rhg-section__header {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.rhg-section__title {
    font-family: var(--font-family-main);
    font-size: 20px;
    font-weight: var(--rhg-sys-font-weight-heading);
    color: var(--rhg-sys-color-text-primary);
    margin: 0;
    line-height: 1.3;
}

.rhg-section__description {
    font-family: var(--font-family-main);
    font-size: var(--rhg-sys-font-size-body);
    font-weight: var(--rhg-sys-font-weight-body);
    color: var(--rhg-ref-palette-gray-700);
    margin: 0;
    line-height: 1.5;
}

.rhg-section__content {
    margin-top: var(--rhg-ref-spacing-2);
}

.rhg-section__divider {
    border: none;
    border-top: 1px solid var(--rhg-sys-color-border-default);
    margin: 0;
}

.rhg-section__divider--top {
    margin-bottom: var(--spacing-lg);
}

.rhg-section__divider--bottom {
    margin-top: var(--spacing-lg);
}

/* ========================================
 * ALERT COMPONENTS
 * ======================================== */
.rhg-alert {
    display: flex;
    align-items: flex-start;
    gap: var(--rhg-sys-spacing-inline-md);
    padding: var(--rhg-sys-spacing-container-padding-default);
    border-radius: var(--rhg-sys-radius-default);
    border: var(--rhg-sys-border-thick);
    font-family: var(--font-family-main);
}

.rhg-alert__icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: var(--rhg-sys-icon-size-large);
    height: var(--rhg-sys-icon-size-large);
    flex-shrink: 0;
}

.rhg-alert__icon svg {
    display: block;
    width: 100%;
    height: 100%;
    shape-rendering: geometricPrecision;
}

.rhg-alert__content {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: var(--rhg-sys-spacing-inline-sm);
}

.rhg-alert__title {
    font-size: var(--rhg-sys-font-size-body);
    font-weight: var(--rhg-sys-font-weight-heading);
    line-height: 1.4;
    margin: 0;
}

.rhg-alert__message {
    font-size: var(--rhg-sys-font-size-label);
    font-weight: var(--rhg-sys-font-weight-body);
    line-height: 1.5;
    margin: 0;
}

.rhg-alert__dismiss {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 20px;
    height: 20px;
    flex-shrink: 0;
    background: none;
    border: none;
    padding: 0;
    cursor: pointer;
    opacity: 0.6;
    transition: opacity 0.2s ease;
}

.rhg-alert__dismiss:hover {
    opacity: 1;
}

.rhg-alert__dismiss svg {
    width: 100%;
    height: 100%;
}

/* Alert styles */
.rhg-alert--info {
    background-color: var(--rhg-comp-tag-information-fill);
    border-color: var(--rhg-comp-tag-information-border);
    color: var(--rhg-comp-tag-information-text-color);
}

.rhg-alert--success {
    background-color: var(--rhg-comp-tag-success-fill);
    border-color: var(--rhg-comp-tag-success-border);
    color: var(--rhg-comp-tag-success-text-color);
}

.rhg-alert--warning {
    background-color: var(--rhg-comp-tag-warning-fill);
    border-color: var(--rhg-comp-tag-warning-border);
    color: var(--rhg-comp-tag-warning-text-color);
}

.rhg-alert--error {
    background-color: var(--rhg-comp-tag-danger-fill);
    border-color: var(--rhg-comp-tag-danger-border);
    color: var(--rhg-comp-tag-danger-text-color);
}


/*==================================================
 * FORM COMPONENTS - SELECT, CHECKBOX, RADIO
 *================================================== */

/* Select Field Styles */
.rhg-field--select .rhg-field__select {
    appearance: none;
    background-image: url('data:image/svg+xml;utf8,<svg width="12" height="8" viewBox="0 0 12 8" fill="none" xmlns="http://www.w3.org/2000/svg"><path d="M1 1.5L6 6.5L11 1.5" stroke="%230A0A19" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"/></svg>');
    background-repeat: no-repeat;
    background-position: right var(--spacing-md) center;
    padding-right: calc(var(--spacing-md) + 24px);
}

.rhg-field--select .rhg-field__select:disabled {
    background-image: url('data:image/svg+xml;utf8,<svg width="12" height="8" viewBox="0 0 12 8" fill="none" xmlns="http://www.w3.org/2000/svg"><path d="M1 1.5L6 6.5L11 1.5" stroke="%23A1A3A4" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"/></svg>');
}

/* Checkbox Styles */
.rhg-field__checkbox-wrapper {
    display: flex;
    align-items: center;
    gap: var(--spacing-sm);
    margin-bottom: var(--spacing-sm);
}

.rhg-field__checkbox {
    appearance: none;
    width: 20px;
    height: 20px;
    border: 1.5px solid var(--rhg-sys-color-border-default);
    border-radius: 4px;
    background-color: var(--rhg-crisp-white);
    cursor: pointer;
    position: relative;
    flex-shrink: 0;
    transition: all 0.2s ease;
}

.rhg-field__checkbox:checked {
    background-color: var(--rhg-rhodium-blue);
    border-color: var(--rhg-rhodium-blue);
}

.rhg-field__checkbox:checked::after {
    content: '';
    position: absolute;
    left: 6px;
    top: 2px;
    width: 5px;
    height: 10px;
    border: solid var(--rhg-crisp-white);
    border-width: 0 2px 2px 0;
    transform: rotate(45deg);
}

.rhg-field__checkbox:focus {
    outline: none;
    box-shadow: 0 0 0 2px rgba(50, 147, 197, 0.2);
}

.rhg-field__checkbox:disabled {
    background-color: var(--rhg-neutral-grey);
    border-color: var(--rhg-grey-light);
    cursor: not-allowed;
}

.rhg-field__checkbox-label {
    font-family: var(--font-family-main);
    font-size: var(--font-size-paragraph);
    color: var(--rhg-deep-black);
    cursor: pointer;
    user-select: none;
}

.rhg-field--disabled .rhg-field__checkbox-label {
    color: var(--rhg-grey-medium);
    cursor: not-allowed;
}

.rhg-field__checkbox-group {
    display: flex;
    flex-direction: column;
    gap: var(--spacing-sm);
    margin-top: var(--spacing-sm);
}

/* Radio Button Styles */
.rhg-field__radio-wrapper {
    display: flex;
    align-items: center;
    gap: var(--spacing-sm);
    margin-bottom: var(--spacing-sm);
}

.rhg-field__radio {
    appearance: none;
    width: 20px;
    height: 20px;
    border: 1.5px solid var(--rhg-sys-color-border-default);
    border-radius: 50%;
    background-color: var(--rhg-crisp-white);
    cursor: pointer;
    position: relative;
    flex-shrink: 0;
    transition: all 0.2s ease;
}

.rhg-field__radio:checked {
    border-color: var(--rhg-rhodium-blue);
}

.rhg-field__radio:checked::after {
    content: '';
    position: absolute;
    left: 50%;
    top: 50%;
    transform: translate(-50%, -50%);
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background-color: var(--rhg-rhodium-blue);
}

.rhg-field__radio:focus {
    outline: none;
    box-shadow: 0 0 0 2px rgba(50, 147, 197, 0.2);
}

.rhg-field__radio:disabled {
    background-color: var(--rhg-neutral-grey);
    border-color: var(--rhg-grey-light);
    cursor: not-allowed;
}

.rhg-field__radio-label {
    font-family: var(--font-family-main);
    font-size: var(--font-size-paragraph);
    color: var(--rhg-deep-black);
    cursor: pointer;
    user-select: none;
}

.rhg-field--disabled .rhg-field__radio-label {
    color: var(--rhg-grey-medium);
    cursor: not-allowed;
}

.rhg-field__radio-group {
    display: flex;
    flex-direction: column;
    gap: var(--spacing-sm);
    margin-top: var(--spacing-sm);
}


/*==================================================
 * DATA TABLES
 *================================================== */

.rhg-table-wrapper {
    background: var(--rhg-sys-background-default);
    border: var(--rhg-sys-border-default);
    border-radius: var(--rhg-sys-radius-large);
    overflow: hidden;
    margin-bottom: var(--spacing-xl);
}

.rhg-table {
    width: 100%;
    border-collapse: collapse;
    font-family: var(--font-family-secondary);
}

/* Table Header */
.rhg-table__header {
    background: transparent;
}

.rhg-table__header-cell {
    padding: var(--spacing-md);
    text-align: left;
    border-bottom: var(--rhg-sys-border-emphasis);
    color: var(--rhg-sys-color-text-default);
    font-weight: var(--font-weight-bold);
    font-size: var(--rhg-sys-font-size-label);
    line-height: 1.4;
}

.rhg-table__header-cell--sortable {
    cursor: pointer;
    user-select: none;
}

.rhg-table__header-cell--sortable:hover {
    background: var(--rhg-sys-background-neutral);
}

.rhg-table__sort-icon {
    display: inline-block;
    vertical-align: middle;
    width: 16px;
    height: 16px;
    margin: 0 4px;
}

/* Sticky Header */
.rhg-table--sticky-header .rhg-table__header {
    position: sticky;
    top: 0;
    z-index: 10;
}

/* Table Body */
.rhg-table__body {
    background: var(--rhg-sys-background-default);
}

.rhg-table__row {
    border-bottom: var(--rhg-sys-border-default);
}

.rhg-table__row:last-child {
    border-bottom: none;
}

.rhg-table__cell {
    padding: var(--spacing-md);
    font-size: var(--rhg-sys-font-size-label);
    color: var(--rhg-sys-color-text-default);
    line-height: 1.4;
    vertical-align: middle;
}

/* Hover Effect */
.rhg-table--hover .rhg-table__row:hover {
    background: var(--rhg-sys-background-neutral);
}

/* Zebra Stripes */
.rhg-table--zebra .rhg-table__row:nth-child(even) {
    background: var(--rhg-sys-background-neutral);
}

.rhg-table--zebra.rhg-table--hover .rhg-table__row:nth-child(even):hover {
    background: rgba(201, 203, 203, 0.5);
}

/* Cell Alignment */
.rhg-table__cell--align-left {
    text-align: left;
}

.rhg-table__cell--align-right {
    text-align: right;
}

.rhg-table__cell--align-center {
    text-align: center;
}

/* Table Cell Layout Components - Multi-line Cell Content */
.rhg-table__cell-content {
    display: flex;
    flex-direction: column;
    gap: var(--spacing-xs);
}

.rhg-table__cell-header {
    font-weight: var(--font-weight-semibold);
    font-size: var(--font-size-paragraph);
    color: var(--rhg-deep-black);
    line-height: 1.4;
}

.rhg-table__cell-body {
    font-weight: var(--font-weight-normal);
    font-size: var(--font-size-paragraph);
    color: var(--rhg-deep-black);
    line-height: 1.4;
}

.rhg-table__cell-muted {
    color: var(--rhg-grey-medium);
    font-size: var(--font-size-small);
    font-weight: var(--font-weight-normal);
    line-height: 1.4;
}

.rhg-table__cell-id {
    color: var(--rhg-grey-light);
    font-size: var(--font-size-tiny);
    font-family: monospace;
    font-weight: var(--font-weight-normal);
    line-height: 1.4;
}

.rhg-table__cell-link {
    color: var(--rhg-deep-black);
    text-decoration: none;
    font-weight: var(--font-weight-semibold);
}

.rhg-table__cell-link:hover {
    color: var(--rhg-blue-medium);
    text-decoration: underline;
}

/* Table Variants - Cell Padding */
.rhg-table--compact .rhg-table__cell,
.rhg-table--compact .rhg-table__header-cell {
    padding: var(--spacing-sm);
}

.rhg-table--spacious .rhg-table__cell,
.rhg-table--spacious .rhg-table__header-cell {
    padding: var(--spacing-lg);
}

/* Table Variants - Header Borders */
.rhg-table--header-borders .rhg-table__header-cell {
    border-right: 1px solid var(--rhg-sys-color-border-default);
}

.rhg-table--header-borders .rhg-table__header-cell:last-child {
    border-right: none;
}


/*==================================================
 * TABLE FILTERS
 *================================================== */

.rhg-table-filters {
    background: var(--rhg-neutral-grey);
    padding: var(--spacing-lg);
    border-radius: 8px;
    margin-bottom: var(--spacing-xl);
}

.rhg-table-filters__form {
    display: flex;
    gap: var(--spacing-md);
    align-items: flex-end;
    flex-wrap: wrap;
}

.rhg-table-filters__search {
    flex: 1;
    min-width: 200px;
}

.rhg-table-filters__fields {
    display: flex;
    gap: var(--spacing-md);
    align-items: flex-end;
    flex-wrap: wrap;
}

.rhg-table-filters__field {
    display: flex;
    flex-direction: column;
    gap: var(--spacing-xs);
    min-width: 150px;
}

.rhg-table-filters__actions {
    display: flex;
    gap: var(--spacing-sm);
    align-items: center;
}


/*==================================================
 * TABLE STATES
 *================================================== */

.rhg-table-state {
    background: var(--rhg-crisp-white);
    border: 1px solid var(--rhg-sys-color-border-default);
    border-radius: 8px;
    padding: var(--spacing-xxl);
    text-align: center;
    margin-bottom: var(--spacing-xl);
}

.rhg-table-state__icon {
    display: flex;
    justify-content: center;
    margin-bottom: var(--spacing-md);
}

.rhg-table-state__icon svg {
    width: 24px;
    height: 24px;
    color: var(--rhg-grey-medium);
}

.rhg-table-state__spinner {
    animation: rhg-spin 1s linear infinite;
}

@keyframes rhg-spin {
    from { transform: rotate(0deg); }
    to { transform: rotate(360deg); }
}

.rhg-table-state__message {
    font-family: var(--font-family-main);
    font-size: var(--font-size-paragraph);
    font-weight: var(--font-weight-semibold);
    color: var(--rhg-deep-black);
    margin-bottom: var(--spacing-sm);
}

.rhg-table-state__description {
    font-family: var(--font-family-main);
    font-size: var(--font-size-paragraph);
    color: var(--rhg-grey-medium);
    margin-bottom: var(--spacing-md);
}

.rhg-table-state__action {
    margin-top: var(--spacing-md);
}

/* Loading State */
.rhg-table-state--loading .rhg-table-state__icon svg {
    color: var(--rhg-rhodium-blue);
}

/* Error State */
.rhg-table-state--error {
    background: var(--rhg-red-lightest);
    border-color: var(--rhg-red-light);
}

.rhg-table-state--error .rhg-table-state__icon svg {
    color: var(--rhg-red-medium);
}

.rhg-table-state--error .rhg-table-state__message {
    color: var(--rhg-red-darkest);
}


/*==================================================
 * METRIC CARD ENHANCEMENTS
 *================================================== */

/* BAN Card Color Accents */
.rhg-card--ban-accent-blue {
    border-left: 4px solid var(--rhg-blue-medium);
}

.rhg-card--ban-accent-green {
    border-left: 4px solid var(--rhg-green-medium);
}

.rhg-card--ban-accent-orange {
    border-left: 4px solid var(--rhg-orange-medium);
}

/* BAN Card Actions */
.rhg-card--ban-actions {
    margin-top: var(--spacing-md);
    display: flex;
    gap: var(--spacing-sm);
    align-items: center;
    flex-wrap: wrap;
}


/*==================================================
 * PAGE HEADERS
 *================================================== */

.rhg-page-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: var(--spacing-xl);
    gap: var(--spacing-lg);
}

.rhg-page-header__content {
    flex: 1;
    min-width: 0;
}

.rhg-page-header__title-row {
    display: flex;
    align-items: center;
    gap: var(--spacing-md);
    flex-wrap: wrap;
}

.rhg-page-header__title {
    font-family: var(--font-family-main);
    font-size: var(--font-size-page-header);
    font-weight: var(--font-weight-bold);
    color: var(--rhg-deep-black);
    margin: 0;
}

.rhg-page-header__badges {
    display: flex;
    gap: var(--spacing-sm);
    align-items: center;
}

.rhg-page-header__subtitle {
    font-family: var(--font-family-main);
    font-size: var(--font-size-paragraph);
    color: var(--rhg-grey-medium);
    margin: var(--spacing-sm) 0 0 0;
}

.rhg-page-header__actions {
    display: flex;
    align-items: center;
    gap: var(--spacing-md);
    flex-shrink: 0;
}

/* Responsive behavior */
@media (max-width: 768px) {
    .rhg-page-header {
        flex-direction: column;
        align-items: stretch;
    }
    
    .rhg-page-header__actions {
        justify-content: flex-start;
    }
}


/*==================================================
 * LAYOUT UTILITIES
 *================================================== */

/* Stack - Vertical spacing layout (based on Figma CD2.0 spacing patterns) */
.rhg-stack {
    display: flex;
    flex-direction: column;
}

.rhg-stack--gap-compact {
    gap: var(--spacing-md);  /* 16px */
}

.rhg-stack--gap-default {
    gap: var(--spacing-lg);  /* 24px */
}

.rhg-stack--gap-comfortable {
    gap: var(--spacing-xl);  /* 32px */
}

.rhg-stack--gap-spacious {
    gap: var(--spacing-xxl);  /* 40px */
}

.rhg-stack--align-start {
    align-items: flex-start;
}

.rhg-stack--align-center {
    align-items: center;
}

.rhg-stack--align-end {
    align-items: flex-end;
}

/* Cluster - Horizontal wrapping layout */
.rhg-cluster {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
}

.rhg-cluster--gap-small {
    gap: var(--spacing-sm);  /* 8px */
}

.rhg-cluster--gap-default {
    gap: var(--spacing-md);  /* 16px */
}

.rhg-cluster--gap-large {
    gap: var(--spacing-lg);  /* 24px */
}

.rhg-cluster--align-start {
    align-items: flex-start;
}

.rhg-cluster--align-end {
    align-items: flex-end;
}

.rhg-cluster--justify-center {
    justify-content: center;
}

.rhg-cluster--justify-end {
    justify-content: flex-end;
}

.rhg-cluster--justify-between {
    justify-content: space-between;
}

/* Container - Width constraints for readability */
.rhg-container--narrow {
    max-width: 600px;
}

.rhg-container--medium {
    max-width: 800px;
}

.rhg-container--wide {
    max-width: 1200px;
}

/* Spacing utilities - Based on Figma spacing patterns */
.rhg-spacing-before--sm {
    margin-top: var(--spacing-md);  /* 16px */
}

.rhg-spacing-before--md {
    margin-top: var(--spacing-lg);  /* 24px */
}

.rhg-spacing-before--lg {
    margin-top: var(--spacing-xxl);  /* 40px */
}

.rhg-spacing-after--sm {
    margin-bottom: var(--spacing-md);  /* 16px */
}

.rhg-spacing-after--md {
    margin-bottom: var(--spacing-lg);  /* 24px */
}

.rhg-spacing-after--lg {
    margin-bottom: var(--spacing-xxl);  /* 40px */
}

/* Code blocks */
.rhg-code-block {
    background: var(--rhg-neutral-grey);
    padding: var(--spacing-md);
    border-radius: 4px;
    overflow-x: auto;
    font-family: 'Courier New', Consolas, Monaco, monospace;
    font-size: var(--font-size-paragraph);
    line-height: 1.5;
}

.rhg-code-block code {
    font-family: inherit;
}

/* Subsection headings (h3 equivalent) */
.rhg-subsection-header {
    font-family: var(--font-family-main);
    font-size: 18px;
    font-weight: var(--font-weight-semibold);
    color: var(--rhg-deep-black);
}

/* Descriptive/muted text */
.rhg-text-muted {
    color: var(--rhg-grey-medium);
}

/*==================================================
 * DANGER ZONE COMPONENTS
 *================================================== */

.rhg-danger-zone {
    background: var(--rhg-sys-background-default);
    border: 2px solid var(--rhg-red-light);
    border-radius: var(--rhg-sys-radius-large);
    margin-bottom: var(--spacing-xl);
}

.rhg-danger-zone__header {
    padding: var(--spacing-xl);
    border-bottom: var(--rhg-ref-line-thick) solid var(--rhg-red-light);
    background: rgba(244, 207, 207, 0.1);
}

.rhg-danger-zone__title {
    margin: 0 0 var(--spacing-sm) 0;
    font-size: var(--font-size-section-header);
    font-weight: var(--font-weight-semibold);
    color: var(--rhg-red-dark);
}

.rhg-danger-zone__description {
    margin: 0;
    font-size: var(--font-size-paragraph);
    color: var(--rhg-grey-dark);
}

.rhg-danger-zone__content {
    padding: var(--spacing-xl);
}

/* Danger Zone Section */
.rhg-danger-zone-section {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: var(--spacing-lg);
    padding-bottom: var(--spacing-lg);
    margin-bottom: var(--spacing-lg);
    border-bottom: var(--rhg-sys-border-thick);
}

.rhg-danger-zone-section:last-child {
    border-bottom: none;
    margin-bottom: 0;
    padding-bottom: 0;
}

.rhg-danger-zone-section__info {
    flex: 1;
}

.rhg-danger-zone-section__title {
    margin: 0 0 var(--spacing-sm) 0;
    font-size: var(--font-size-paragraph);
    font-weight: var(--font-weight-semibold);
    color: var(--rhg-deep-black);
}

.rhg-danger-zone-section__description {
    margin: 0 0 var(--spacing-sm) 0;
    font-size: var(--font-size-paragraph);
    color: var(--rhg-grey-dark);
}

.rhg-danger-zone-section__details {
    margin: var(--spacing-md) 0 0 0;
    padding-left: var(--spacing-lg);
    font-size: var(--font-size-small);
    color: var(--rhg-grey-dark);
}

.rhg-danger-zone-section__details li {
    margin-bottom: var(--spacing-xs);
}

.rhg-danger-zone-section__action {
    flex-shrink: 0;
}

/* Danger Button Style */
.rhg-button--danger {
    background: var(--rhg-red-medium);
    color: var(--rhg-crisp-white);
    border: none;
    padding: 10px 20px;
    font-size: var(--font-size-paragraph);
    font-weight: var(--font-weight-semibold);
    border-radius: 4px;
    cursor: pointer;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    transition: background-color 0.2s ease;
}

.rhg-button--danger:hover {
    background: var(--rhg-red-dark);
    color: var(--rhg-crisp-white);
    text-decoration: none;
}

.rhg-button--danger:active {
    background: var(--rhg-red-darkest);
}

/* Responsive: stack danger zone sections on mobile */
@media (max-width: 640px) {
    .rhg-danger-zone-section {
        flex-direction: column;
        align-items: stretch;
    }
    
    .rhg-danger-zone-section__action {
        width: 100%;
    }
    
    .rhg-danger-zone-section__action .rhg-button--danger {
        width: 100%;
    }
}


/*==================================================
 * DETAIL VIEW COMPONENTS
 *================================================== */

.rhg-detail-card {
    background: var(--rhg-sys-background-default);
    border: var(--rhg-sys-border-thick);
    border-radius: var(--rhg-sys-radius-large);
    margin-bottom: var(--spacing-xl);
}

.rhg-detail-card__header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: var(--spacing-xl);
    border-bottom: var(--rhg-sys-border-thick);
}

.rhg-detail-card__title {
    margin: 0;
    font-size: var(--font-size-section-header);
    font-weight: var(--font-weight-semibold);
    color: var(--rhg-deep-black);
}

.rhg-detail-card__actions {
    display: flex;
    gap: var(--spacing-sm);
    align-items: center;
}

.rhg-detail-card__content {
    padding: var(--spacing-xl);
}

/* Detail Section */
.rhg-detail-section {
    margin-bottom: var(--spacing-lg);
}

.rhg-detail-section:last-child {
    margin-bottom: 0;
}

.rhg-detail-section__title {
    margin: 0 0 var(--spacing-md) 0;
    font-size: var(--font-size-paragraph);
    font-weight: var(--font-weight-semibold);
    color: var(--rhg-grey-dark);
}

.rhg-detail-section__content {
    display: flex;
    flex-direction: column;
    gap: var(--spacing-md);
}

/* Detail Field */
.rhg-detail-field {
    display: flex;
    gap: var(--spacing-sm);
    align-items: baseline;
}

.rhg-detail-field--stacked {
    flex-direction: column;
    gap: var(--spacing-xs);
}

.rhg-detail-field__label {
    font-size: var(--font-size-paragraph);
    font-weight: var(--font-weight-medium);
    color: var(--rhg-grey-dark);
    min-width: 120px;
    flex-shrink: 0;
}

.rhg-detail-field--stacked .rhg-detail-field__label {
    min-width: unset;
    font-size: var(--font-size-small);
}

.rhg-detail-field__value {
    font-size: var(--font-size-paragraph);
    color: var(--rhg-deep-black);
    flex: 1;
}

.rhg-detail-field__value--emphasis {
    font-weight: var(--font-weight-semibold);
}

/* Detail Field Group */
.rhg-detail-field-group {
    display: grid;
    gap: var(--spacing-md);
    margin-bottom: var(--spacing-lg);
}

.rhg-detail-field-group:last-child {
    margin-bottom: 0;
}

.rhg-detail-field-group--2-col {
    grid-template-columns: repeat(2, 1fr);
}

.rhg-detail-field-group--3-col {
    grid-template-columns: repeat(3, 1fr);
}

/* Responsive: stack on mobile */
@media (max-width: 640px) {
    .rhg-detail-field-group--2-col,
    .rhg-detail-field-group--3-col {
        grid-template-columns: 1fr;
    }
    
    .rhg-detail-field {
        flex-direction: column;
        gap: var(--spacing-xs);
    }
    
    .rhg-detail-field__label {
        min-width: unset;
        font-size: var(--font-size-small);
    }
    
    .rhg-detail-card__header {
        flex-direction: column;
        align-items: flex-start;
        gap: var(--spacing-md);
    }
}


/*==================================================
 * TEXT UTILITY CLASSES
 *================================================== */

/* Semantic color utilities */
.text-muted {
    color: var(--rhg-grey-medium);
}

.text-success {
    color: var(--rhg-green-medium);
}

.text-warning {
    color: var(--rhg-orange-medium);
}

.text-error {
    color: var(--rhg-red-medium);
}

.text-info {
    color: var(--rhg-blue-medium);
}

/* Size utilities */
.text-small {
    font-size: var(--font-size-small);
}

.text-tiny {
    font-size: var(--font-size-tiny);
}

/* Style utilities */
.text-italic {
    font-style: italic;
}

.text-semibold {
    font-weight: var(--font-weight-semibold);
}

.text-bold {
    font-weight: var(--font-weight-bold);
}


/*==================================================
 * LOADING COMPONENTS
 *================================================== */

/* Loading Skeleton */
.rhg-skeleton {
    background: linear-gradient(
        90deg,
        var(--rhg-sys-background-neutral) 0%,
        rgba(242, 242, 242, 0.6) 50%,
        var(--rhg-sys-background-neutral) 100%
    );
    background-size: 200% 100%;
    animation: rhg-skeleton-loading 1.5s ease-in-out infinite;
    border-radius: var(--rhg-sys-radius-default);
}

/* Skeleton Shapes */
.rhg-skeleton--text {
    height: 1rem;
    width: 100%;
}

.rhg-skeleton--title {
    height: 2rem;
    width: 200px;
}

.rhg-skeleton--button {
    height: 2.5rem;
    width: 100px;
    border-radius: var(--rhg-sys-radius-default);
}

.rhg-skeleton--circle {
    width: 40px;
    height: 40px;
    border-radius: 50%;
}

.rhg-skeleton--rectangle {
    height: 100px;
    width: 100%;
}

/* Skeleton Group */
.rhg-skeleton-group {
    display: flex;
    flex-direction: column;
    gap: var(--spacing-md);
}

.rhg-skeleton-group--horizontal {
    flex-direction: row;
    align-items: center;
}

.rhg-skeleton-group--gap-small {
    gap: var(--spacing-sm);
}

.rhg-skeleton-group--gap-large {
    gap: var(--spacing-lg);
}

/* Loading Spinner */
.rhg-spinner {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: var(--spacing-md);
}

.rhg-spinner__icon {
    width: 24px;
    height: 24px;
    border: 3px solid var(--rhg-sys-background-neutral);
    border-top-color: var(--rhg-blue-medium);
    border-radius: 50%;
    animation: rhg-spin 0.8s linear infinite;
}

.rhg-spinner--small .rhg-spinner__icon {
    width: 16px;
    height: 16px;
    border-width: 2px;
}

.rhg-spinner--large .rhg-spinner__icon {
    width: 32px;
    height: 32px;
    border-width: 4px;
}

.rhg-spinner__message {
    font-size: var(--font-size-paragraph);
    color: var(--rhg-sys-color-text-muted);
    text-align: center;
}

/* Loading Animations */
@keyframes rhg-skeleton-loading {
    0% {
        background-position: 200% 0;
    }
    100% {
        background-position: -200% 0;
    }
}

@keyframes rhg-pulse {
    0%, 100% {
        opacity: 1;
    }
    50% {
        opacity: 0.5;
    }
}

.rhg-loading-pulse {
    animation: rhg-pulse 1.5s ease-in-out infinite;
}

/* ========================================
 * GRID BACKGROUND PATTERN
 * Reusable CSS grid pattern in Rhodium blue
 * Usage: Add .rhg-grid-background to any positioned container,
 *        or use .rhg-grid-background--overlay as a pseudo-element
 * ======================================== */

/* Direct application - apply to element that should have grid background */
.rhg-grid-background {
    background-image: 
        linear-gradient(to right, rgba(0, 120, 173, 0.15) 1px, transparent 1px),
        linear-gradient(to bottom, rgba(0, 120, 173, 0.15) 1px, transparent 1px);
    background-size: 96px 96px;
    background-position: left top;
}

/* Overlay variant - positioned absolutely within a relative parent */
.rhg-grid-background--overlay {
    position: absolute;
    right: 0;
    top: 0;
    bottom: 0;
    width: 50%;
    background-image: 
        linear-gradient(to right, rgba(0, 120, 173, 0.15) 1px, transparent 1px),
        linear-gradient(to bottom, rgba(0, 120, 173, 0.15) 1px, transparent 1px);
    background-size: 96px 96px;
    background-position: left top;
    pointer-events: none;
    z-index: 0;
}

/* Full-width variant */
.rhg-grid-background--full {
    position: absolute;
    inset: 0;
    background-image: 
        linear-gradient(to right, rgba(0, 120, 173, 0.15) 1px, transparent 1px),
        linear-gradient(to bottom, rgba(0, 120, 173, 0.15) 1px, transparent 1px);
    background-size: 96px 96px;
    background-position: left top;
    pointer-events: none;
    z-index: 0;
}

/* ========================================
 * SIGN IN REQUIRED COMPONENT
 * ======================================== */

.rhg-signin-required {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    justify-content: center;
    padding: var(--rhg-sys-spacing-page-margin, 80px);
    position: relative;
    width: 100%;
    /* Fill available height between header/nav and footer */
    min-height: calc(100vh - var(--header-height, 54px) - var(--navbar-height, 54px) - 60px);
    flex: 1 1 auto;
    box-sizing: border-box;
    overflow: hidden;
    background-color: var(--rhg-sys-background-default);
}

/* When sign-in required is a direct child of page-content, remove page-content padding */
.page-content:has(> .rhg-signin-required) {
    padding: 0;
    max-width: none;
    margin: 0;
}

/* When page-container contains sign-in required, ensure it fills height */
.page-container:has(.rhg-signin-required) {
    min-height: calc(100vh - var(--header-height, 54px) - var(--navbar-height, 54px) - 60px);
}

.rhg-signin-required__background {
    position: absolute;
    right: 0;
    top: 0;
    bottom: 0;
    width: 50%;
    /* CSS grid pattern using 1-inch (96px) grid lines in Rhodium blue */
    background-image: 
        linear-gradient(to right, rgba(0, 120, 173, 0.15) 1px, transparent 1px),
        linear-gradient(to bottom, rgba(0, 120, 173, 0.15) 1px, transparent 1px);
    background-size: 96px 96px;
    background-position: left top;
    opacity: 1;
    z-index: 0;
}

.rhg-signin-required__content {
    position: relative;
    z-index: 1;
    max-width: 600px;
    width: 100%;
}

.rhg-signin-required__title {
    font-family: var(--font-family-main);
    font-size: 48px;
    font-weight: bold;
    color: var(--rhg-sys-color-text-primary);
    line-height: 1.1;
    margin: 0 0 24px 0;
}

.rhg-signin-required__description {
    font-family: var(--font-family-main);
    font-size: var(--rhg-sys-font-size-body);
    font-weight: var(--rhg-sys-font-weight-body);
    color: var(--rhg-sys-color-text-primary);
    line-height: normal;
    margin: 0 0 24px 0;
}

.rhg-signin-required__buttons {
    display: flex;
    gap: var(--rhg-sys-spacing-inline-md, 16px);
    align-items: flex-start;
    flex-wrap: wrap;
}

/* Responsive design */
@media (max-width: 768px) {
    .rhg-signin-required {
        padding: var(--rhg-sys-spacing-page-margin-mobile, 24px);
        /* Adjust min-height for mobile - no navbar typically shown */
        min-height: calc(100vh - var(--header-height, 54px) - 100px);
    }
    
    .rhg-signin-required__background {
        display: none; /* Hide background on mobile for better readability */
    }
    
    .rhg-signin-required__title {
        font-size: 36px;
    }
    
    .rhg-signin-required__buttons {
        flex-direction: column;
        width: 100%;
    }
    
    .rhg-signin-required__buttons .rhg-button {
        width: 100%;
        justify-content: center;
    }
}
