:root {
    --card-radius: 16px;
    --input-radius: 8px;
    /* --card-radius-lg: 18px; */
    --card-radius-pill: 999px;
    --card-padding: 28px;
    --card-padding-lg: 36px;
    --card-gap: 12px;
    --card-shadow: 0 8px 28px rgba(35, 60, 90, 0.06);
    --card-shadow-soft: 0 4px 18px rgba(35, 60, 90, 0.045);
    --page-bg-agent: #F0F5F9;
    --card-bg-agent: #FEFCFB;
    --panel-bg-agent: #F5FBFF;
    --color-accent-lime: #E0F28F;
    --color-accent-blue: #D1E9FD;
    --color-accent-yellow: #FDF08F;
    --color-track-soft: #EEF0ED;
    --text-color-primary: #1E202A;
    --text-color-secondary: #717378;
    --text-color-muted: #8A8D94;
    --chart-line-primary: #24253C;
    --font-size-metric-large: 56px;
    --font-size-metric-medium: 42px;
    --font-size-card-title: 20px;
    --font-size-card-value: 42px;
    --font-size-label: 14px;
    

    --edm-background-header: #181818;
    --edm-background-highlight: #EEF4E6;
    --edm-background-btn-hover: #F2F2F2;
    --edm-background-main-sub: #F9F9F9;
    --edm-background-card: #FFFFFF;
    --edm-backgounrd-icon: #bdbebfac;

    --edm-text-header-title: #FFFFFF;
    --edm-text-body: #242424;
    --edm-text-subtitle: #595959;
    --edm-text-hint: #6F6F6F;
    --edm-text-title: #181818;
    --edm-text-button: #FFFFFF;
     /* --edm-text-header-title: #F3F3F3; */

    --edm-accent: #89B157;   /*main point color*/
    --edm-accent-blue: #167fe5;
    --edm-accent-yellow: #f7e872;
    --edm-outline: #E0E0E0;
    --edm-background-accent: #EEF4E6;
    --edm-background-accent-blue: rgba(22, 140, 255, 0.08);
    --edm-background-accent-yellow: #faf5cb;
    --edm-accent-dark: #3B7D23;
    --edm-accent-blue-dark: #1a528b;
    --edm-accent-yellow-dark: #bb760e;
 
    /* --edm-background-bar: #303030; */
    --edm-background-button: #89B157;
    --edm-background: #202020;
    --edm-background-dropdown: #3C3C3C;
    /* --edm-outline: #898A87; */
    --edm-btn-outline-active: #F5F5F5;
    /* --edm-btn-background-hover: #3B7D23; */
    
    --edm-icon-line: #7F7F7F;

    --edm-text: #E1E1E1; /*#e5e5e5;*/
    /* --edm-text-subtitle: #8A8A8A; */
    --edm-text-header-main: #FFFFFF; /*#D4D5CF;*/
    --edm-text-header-sub: #E1E1E1; /*#898a87;*/
   
    --edm-text-dropdown: #919191;
    --edm-scrollbar: #444444;
    --edm-scrollbar-hover: #555555;
    --edm-highlight: #fbf091;
    --edm-alert: #F75270;
    --edm-alert-background: #ffeff2;
    --edm-ess-discharging: #89B157;
    --edm-ess-charging: #167fe5;

}

/* ------------------- Home ------------------- */
.home-page-shell,
.home-hero-shell {
    width: 100%;
    min-height: 100%;
    background: var(--edm-background-header);
}

.home-page-shell {
    overflow: hidden;
}

.home-hero-shell {
    display: flex;
    flex-direction: column;
}

.home-intro-video {
    display: block;
    width: 100%;
    height: auto;
    max-height: 720px;
    flex: 0 1 auto;
    object-fit: contain;
    background: var(--edm-background-header);
}

.home-hero-copy {
    position: relative;
    z-index: 1;
    display: flex;
    min-height: 240px;
    flex: 1 0 240px;
    align-items: center;
    justify-content: center;
    flex-direction: column;
    margin-top: -96px;
    padding: 132px 32px 56px;
    overflow: hidden;
    color: var(--edm-text-header-title);
    text-align: center;
    pointer-events: none;
    background: linear-gradient(
        180deg,
        rgba(24, 24, 24, 0) 0%,
        rgba(24, 24, 24, 0.88) 34%,
        var(--edm-background-header) 62%
    );
}

.home-hero-copy::after {
    position: absolute;
    right: 12%;
    bottom: 26px;
    left: 12%;
    height: 1px;
    background: linear-gradient(
        90deg,
        transparent,
        rgba(137, 177, 87, 0.7),
        rgba(22, 127, 229, 0.7),
        transparent
    );
    content: "";
}

.home-mobile-login {
    display: none;
    pointer-events: auto;
}

@media (min-width: 769px) {
    .home-page-shell {
        border-radius: var(--card-radius) 0 0 var(--card-radius);
    }
}

@media (max-width: 768px) {
    .home-hero-copy {
        min-height: 220px;
        padding-right: 20px;
        padding-left: 20px;
    }

    .home-hero-copy .edm-text-hero-large {
        font-size: clamp(30px, 7vw, 36px);
    }

    .home-mobile-login {
        display: inline-flex;
        align-items: center;
        justify-content: center;
        min-width: 136px;
        margin-top: 28px;
    }
}

/* ------------------- Developer ------------------- */
.fee-shell {
    width: 100%;
    min-height: 100%;
    padding: 32px clamp(16px, 3vw, 48px) 40px;
    background:
        radial-gradient(circle at 92% 4%, rgba(22, 127, 229, 0.12), transparent 24%),
        radial-gradient(circle at 8% 18%, rgba(137, 177, 87, 0.14), transparent 26%),
        var(--page-bg-agent);
    color: var(--text-color-primary);
}

.fee-hero {
    max-width: 1040px;
    margin: 0 auto 36px;
    text-align: center;
}

.fee-eyebrow {
    margin-bottom: 12px;
    color: var(--edm-accent-blue-dark);
    font-size: 12px;
    font-weight: 700;
    letter-spacing: 0.16em;
}

.fee-title {
    margin: 0 0 14px;
    color: var(--text-color-primary);
    font-size: clamp(36px, 4.5vw, 58px);
    font-weight: 600;
    line-height: 1.04;
    letter-spacing: -0.045em;
}

.fee-subtitle {
    max-width: none;
    margin: 0 auto;
    color: var(--text-color-secondary);
    font-size: 17px;
    line-height: 1.65;
    white-space: nowrap;
}

.fee-plan-grid {
    width: 100%;
    max-width: 1680px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 16px;
    align-items: stretch;
}

.fee-plan-card {
    --fee-plan-accent-start: var(--edm-accent);
    --fee-plan-accent-end: var(--edm-accent);
    position: relative;
    min-width: 0;
    min-height: 590px;
    display: flex;
    flex-direction: column;
    padding: 28px;
    overflow: hidden;
    background:
        linear-gradient(var(--card-bg-agent), var(--card-bg-agent)) padding-box,
        linear-gradient(90deg, var(--fee-plan-accent-start), var(--fee-plan-accent-end)) border-box;
    border: 0;
    border-top: 5px solid transparent;
    border-radius: var(--card-radius);
    box-shadow: var(--card-shadow);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.fee-plan-card-blue {
    --fee-plan-accent-start: var(--edm-accent-blue);
    --fee-plan-accent-end: var(--edm-accent-blue);
}

.fee-plan-card-featured {
    --fee-plan-accent-start: var(--edm-accent);
    --fee-plan-accent-end: var(--edm-accent-blue);
    box-shadow: 0 16px 42px rgba(59, 125, 35, 0.14);
}

.fee-plan-card-poc,
.fee-plan-card-basic,
.fee-plan-card-enterprise {
    background: var(--card-bg-agent);
    border-top: 0;
}

.fee-plan-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 16px 42px rgba(35, 60, 90, 0.12);
}

.fee-plan-badge {
    position: absolute;
    top: 18px;
    right: 18px;
    padding: 6px 10px;
    color: var(--edm-accent-dark);
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 0.05em;
    text-transform: uppercase;
    background: var(--edm-background-accent);
    border-radius: var(--card-radius-pill);
}

.fee-plan-header {
    min-height: 164px;
}

.fee-plan-audience {
    margin-bottom: 12px;
    color: var(--text-color-muted);
    font-size: 12px;
    font-weight: 650;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.fee-plan-name {
    margin: 0 0 12px;
    color: var(--text-color-primary);
    font-size: 30px;
    font-weight: 650;
    letter-spacing: -0.025em;
}

.fee-plan-description {
    margin: 0;
    color: var(--text-color-secondary);
    font-size: 14px;
    line-height: 1.55;
}

.fee-plan-price-row {
    min-height: 76px;
    display: flex;
    align-items: baseline;
    flex-wrap: wrap;
    gap: 7px;
    margin: 18px 0 16px;
}

.fee-plan-price {
    color: var(--text-color-primary);
    font-size: clamp(34px, 3vw, 44px);
    font-weight: 650;
    line-height: 1;
    letter-spacing: -0.04em;
    white-space: nowrap;
}

.fee-plan-price-custom {
    font-size: clamp(28px, 2.25vw, 36px);
    letter-spacing: -0.035em;
}

.fee-plan-period {
    color: var(--text-color-muted);
    font-size: 13px;
    font-weight: 500;
}

.fee-plan-button {
    width: 100%;
    min-height: 44px;
    margin-bottom: 26px;
    border-radius: var(--input-radius);
}

.fee-plan-card:not(.fee-plan-card-featured) .fee-plan-button {
    color: var(--edm-text-button);
    background: var(--edm-background-header);
    border: 1px solid var(--edm-outline);
}

.fee-plan-card:not(.fee-plan-card-featured) .fee-plan-button:hover,
.fee-plan-card:not(.fee-plan-card-featured) .fee-plan-button:focus,
.fee-plan-card:not(.fee-plan-card-featured) .fee-plan-button:active,
.fee-plan-card:not(.fee-plan-card-featured) .fee-plan-button:focus:active {
    color: var(--edm-text-button);
    background: var(--edm-background-header);
    border-color: var(--edm-outline);
    box-shadow: none;
    filter: none !important;
    opacity: 1 !important;
}

.fee-plan-card-featured .fee-plan-button {
    background: var(--edm-accent);
}

.fee-plan-card-featured .fee-plan-button:hover,
.fee-plan-card-featured .fee-plan-button:focus,
.fee-plan-card-featured .fee-plan-button:active,
.fee-plan-card-featured .fee-plan-button:focus:active {
    color: var(--edm-text-button);
    background: var(--edm-accent-dark);
    box-shadow: none;
    filter: none !important;
    opacity: 1 !important;
}

.fee-plan-features {
    padding-top: 22px;
    border-top: 1px solid var(--edm-outline);
}

.fee-plan-includes {
    min-height: 38px;
    margin-bottom: 16px;
    color: var(--text-color-primary);
    font-size: 14px;
    font-weight: 650;
}

.fee-feature-list {
    display: flex;
    flex-direction: column;
    gap: 14px;
    margin: 0;
    padding: 0;
    list-style: none;
}

.fee-feature-item {
    display: grid;
    grid-template-columns: 22px minmax(0, 1fr);
    gap: 10px;
    align-items: start;
    color: var(--text-color-secondary);
    font-size: 14px;
    line-height: 1.45;
}

.fee-feature-check {
    width: 20px;
    height: 20px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: var(--edm-accent-dark);
    font-size: 12px;
    font-weight: 800;
    background: var(--edm-background-accent);
    border-radius: 50%;
}

.fee-plan-card-blue .fee-feature-check {
    color: var(--edm-accent-blue-dark);
    background: var(--edm-background-accent-blue);
}

.fee-footnote {
    margin: 22px auto 0;
    color: var(--text-color-muted);
    font-size: 12px;
    text-align: center;
}

.pricing-contact-modal .modal-content {
    overflow: hidden;
    color: var(--text-color-primary);
    background: var(--card-bg-agent);
    border: 0;
    border-radius: var(--card-radius);
    box-shadow: var(--card-shadow);
}

.pricing-contact-modal .modal-dialog {
    width: calc(100% - 32px);
    max-width: 640px;
    margin-right: auto;
    margin-left: auto;
}

.pricing-contact-modal-header {
    padding: 20px 26px 16px;
    background: transparent;
    border-bottom: 1px solid var(--edm-outline);
}

.pricing-contact-modal-title {
    color: var(--text-color-primary);
    font-size: 18px;
    font-weight: 600;
}

.pricing-contact-modal-body {
    padding: 26px;
}

.pricing-contact-eyebrow {
    margin-bottom: 8px;
    color: var(--edm-accent-blue-dark);
    font-size: 12px;
    font-weight: 700;
    letter-spacing: 0.12em;
}

.pricing-contact-heading {
    margin: 0;
    color: var(--text-color-primary);
    font-size: 26px;
    font-weight: 600;
    line-height: 1.3;
}

.pricing-contact-description {
    max-width: 640px;
    margin: 10px 0 0;
    color: var(--text-color-secondary);
    font-size: 17px;
    font-weight: 500;
    line-height: 1.65;
    overflow-wrap: anywhere;
    white-space: normal;
}

.pricing-contact-grid {
    display: grid;
    grid-template-columns: minmax(0, 1fr);
    margin-top: 24px;
    padding: 4px 18px;
    background: var(--edm-background-main-sub);
    border-radius: 14px;
}

.pricing-contact-item {
    min-width: 0;
    padding: 16px 0;
    background: transparent;
    border-bottom: 1px solid var(--edm-outline);
    border-radius: 0;
}

.pricing-contact-item:last-child {
    border-bottom: 0;
}

.pricing-contact-label {
    color: var(--edm-text-subtitle);
    font-size: 12px;
    font-weight: 600;
}

.pricing-contact-value {
    margin-top: 7px;
    overflow: hidden;
    color: var(--text-color-primary);
    font-size: 15px;
    font-weight: 600;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.pricing-contact-hint {
    margin-top: 6px;
    color: var(--text-color-muted);
    font-size: 11px;
    line-height: 1.45;
}

.pricing-contact-template-note {
    margin-top: 20px;
    padding: 12px 14px;
    color: var(--edm-accent-dark);
    font-size: 12px;
    background: var(--edm-background-accent);
    border-radius: 10px;
}

.pricing-contact-modal-footer {
    padding: 16px 26px 20px;
    background: transparent;
    border-top: 1px solid var(--edm-outline);
}

.pricing-contact-close {
    min-width: 112px;
}

@media (max-width: 1280px) {
    .fee-plan-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .fee-plan-card {
        min-height: 540px;
    }
}

@media (max-width: 680px) {
    .fee-shell {
        padding: 24px 16px 32px;
    }

    .fee-hero {
        margin-bottom: 26px;
        text-align: left;
    }

    .fee-subtitle {
        font-size: 15px;
        white-space: normal;
    }

    .fee-plan-grid {
        grid-template-columns: 1fr;
    }

    .fee-plan-card {
        min-height: 0;
        padding: 24px;
    }

    .fee-plan-header {
        min-height: 0;
    }

    .pricing-contact-modal-header,
    .pricing-contact-modal-body,
    .pricing-contact-modal-footer {
        padding-right: 18px;
        padding-left: 18px;
    }

    .pricing-contact-grid {
        grid-template-columns: 1fr;
    }

    .pricing-contact-heading {
        font-size: 22px;
    }
}

/* ------------------- Developer ------------------- */
.team-shell {
    width: 100%;
    min-height: 100%;
    padding: 16px;
    background: var(--page-bg-agent);
    color: var(--text-color-primary);
    box-sizing: border-box;
}

.team-hero {
    position: relative;
    min-height: calc(100vh - 32px);
    padding: clamp(32px, 5vw, 72px);
    display: flex;
    align-items: stretch;
    justify-content: flex-start;
    flex-direction: column;
    gap: clamp(36px, 5vh, 64px);
    overflow: hidden;
    background:
        radial-gradient(circle at 88% 20%, rgba(22, 127, 229, 0.17), transparent 30%) padding-box,
        radial-gradient(circle at 70% 112%, rgba(137, 177, 87, 0.22), transparent 38%) padding-box,
        linear-gradient(var(--card-bg-agent), var(--card-bg-agent)) padding-box,
        linear-gradient(90deg, var(--edm-accent), var(--edm-accent-blue)) border-box;
    border: 0;
    border-top: 6px solid transparent;
    border-radius: var(--card-radius);
    box-shadow: var(--card-shadow);
}

.team-hero-header {
    position: relative;
    z-index: 1;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 48px;
}

.team-hero-copy {
    position: relative;
    z-index: 1;
    width: 100%;
    max-width: 1050px;
}

.team-eyebrow,
.team-section-kicker {
    margin-bottom: 14px;
    color: var(--edm-accent-dark);
    font-size: 12px;
    font-weight: 750;
    letter-spacing: 0.16em;
}

.team-title {
    width: 100%;
    margin: 0 0 18px;
    color: var(--text-color-primary);
    font-size: clamp(40px, 5vw, 66px);
    font-weight: 600;
    line-height: 1.02;
    letter-spacing: -0.045em;
}

.team-subtitle {
    max-width: 680px;
    margin: 0;
    color: var(--text-color-secondary);
    font-size: 17px;
    line-height: 1.7;
}

.team-profile-grid {
    position: relative;
    z-index: 1;
    display: grid;
    grid-template-columns: repeat(8, minmax(0, 1fr));
    gap: 18px;
    align-items: stretch;
}

.team-profile-card {
    grid-column: span 2;
    min-width: 0;
    min-height: 190px;
    padding: 24px;
    display: flex;
    flex-direction: column;
    gap: 22px;
    background: rgba(255, 255, 255, 0.72);
    border: 0;
    border-radius: var(--card-radius);
    box-shadow: var(--card-shadow-soft);
}

.team-profile-card:nth-child(5) {
    grid-column: 2 / span 2;
}

.team-profile-card:nth-child(6) {
    grid-column: 4 / span 2;
}

.team-profile-card:nth-child(7) {
    grid-column: 6 / span 2;
}

.team-profile-header {
    display: flex;
    align-items: center;
    gap: 16px;
}

.team-profile-avatar {
    width: 62px;
    height: 62px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex: 0 0 auto;
    overflow: hidden;
    background: var(--edm-background-accent-blue);
    border: 1px solid rgba(224, 224, 224, 0.78);
    border-radius: 50%;
}

.team-profile-avatar img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.team-profile-identity {
    min-width: 0;
}

.team-profile-name {
    margin: 0 0 5px;
    color: var(--text-color-primary);
    font-size: 19px;
    font-weight: 650;
    line-height: 1.2;
}

.team-profile-role {
    color: var(--edm-accent-blue-dark);
    font-size: 12px;
    font-weight: 650;
    line-height: 1.35;
}

.team-profile-description {
    display: flex;
    flex-direction: column;
    gap: 3px;
}

.team-profile-description-line {
    margin: 0;
    color: var(--text-color-secondary);
    font-size: 14px;
    line-height: 1.3;
}

@media (max-width: 1200px) {
    .team-profile-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .team-profile-card,
    .team-profile-card:nth-child(5),
    .team-profile-card:nth-child(6),
    .team-profile-card:nth-child(7) {
        grid-column: auto;
    }
}

@media (max-width: 680px) {
    .team-hero {
        min-height: 0;
        padding: 32px 24px;
    }

    .team-subtitle {
        font-size: 15px;
    }

    .team-profile-grid {
        grid-template-columns: 1fr;
    }

    .team-profile-card {
        min-height: 0;
    }
}

/* ------------------- Developer ------------------- */
.developer-shell {
    min-height: 100%;
    background: var(--page-bg-agent);
}

.developer-container {
    max-width: 1440px;
    padding: 16px;
}

.developer-content {
    display: flex;
    flex-direction: column;
    gap: var(--card-gap);
    padding-bottom: 24px;
}

.developer-hero.agent-card {
    position: relative;
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 32px;
    min-height: 230px;
    margin-bottom: var(--card-gap);
    overflow: hidden;
    background:
        linear-gradient(var(--edm-background-card), var(--edm-background-card)) padding-box,
        linear-gradient(180deg, var(--edm-accent), var(--edm-accent-blue)) border-box;
    border: 0;
    border-left: 6px solid transparent;
    box-shadow: var(--card-shadow);
}

.developer-hero-copy,
.developer-chip-row {
    position: relative;
    z-index: 1;
}

.developer-eyebrow {
    margin-bottom: 12px;
    color: var(--edm-accent-dark);
    font-size: 12px;
    font-weight: 700;
    letter-spacing: 0.16em;
}

.developer-title {
    margin: 0 0 12px;
    color: var(--text-color-primary);
    font-size: clamp(34px, 4vw, 52px);
    font-weight: 550;
    line-height: 1.05;
    letter-spacing: -0.035em;
}

.developer-subtitle {
    max-width: 720px;
    margin: 0;
    color: var(--text-color-secondary);
    font-size: 16px;
    line-height: 1.65;
}

.developer-chip-row {
    display: flex;
    flex-wrap: wrap;
    justify-content: flex-end;
    gap: 8px;
}

.developer-chip {
    padding: 7px 12px;
    border-radius: var(--card-radius-pill);
    font-size: 12px;
    font-weight: 650;
    white-space: nowrap;
}

.developer-chip-lime {
    color: var(--edm-accent-dark);
    background: var(--edm-background-accent);
}

.developer-chip-blue {
    color: var(--edm-accent-blue-dark);
    background: var(--edm-background-accent-blue);
}

.developer-chip-yellow {
    color: var(--edm-accent-yellow-dark);
    background: var(--edm-background-accent-yellow);
}

.developer-callout {
    margin: 0 !important;
    padding: 16px 18px !important;
    border-radius: 12px !important;
}

.developer-workflow-card,
.developer-section-card {
    background: var(--edm-background-card) !important;
    border: 0 !important;
    border-radius: var(--card-radius) !important;
    box-shadow: var(--card-shadow-soft) !important;
}

.developer-workflow-card {
    padding: 24px 28px;
}

.developer-workflow-header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 24px;
    margin-bottom: 24px;
}

.developer-workflow-title {
    color: var(--text-color-primary);
    font-size: 24px;
    font-weight: 600;
    line-height: 1.25;
}

.developer-workflow-subtitle {
    margin-top: 6px;
    color: var(--edm-text-subtitle);
    font-size: 16px;
    line-height: 1.6;
}

.developer-workflow-count {
    flex: 0 0 auto;
    padding: 7px 13px;
    color: var(--edm-accent-dark);
    font-size: 13px;
    font-weight: 600;
    line-height: 1;
    background: var(--edm-background-accent);
    border-radius: 999px;
}

.developer-workflow-notices {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: var(--card-gap);
    margin-bottom: 30px;
}

.developer-workflow-notices .developer-callout {
    box-sizing: border-box;
    height: 100%;
}

.developer-workflow-steps {
    position: relative;
    display: grid;
    grid-template-columns: repeat(7, minmax(0, 1fr));
    gap: 10px;
}

.developer-workflow-steps::before {
    position: absolute;
    top: 23px;
    right: 6%;
    left: 6%;
    z-index: 0;
    height: 2px;
    background: linear-gradient(
        90deg,
        var(--edm-accent-blue),
        var(--edm-accent),
        var(--edm-accent-yellow)
    );
    content: "";
    opacity: 0.35;
}

.developer-workflow-step {
    position: relative;
    z-index: 1;
    min-width: 0;
    padding: 0 8px 12px;
    text-align: center;
}

.developer-workflow-step-number {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 48px;
    height: 48px;
    margin: 0 auto 15px;
    color: var(--edm-accent-dark);
    font-size: 13px;
    font-weight: 700;
    background:
        linear-gradient(var(--edm-background-accent), var(--edm-background-accent)),
        var(--edm-background-card);
    border: 5px solid var(--edm-background-card);
    border-radius: 50%;
}

.developer-workflow-step:nth-child(even) .developer-workflow-step-number {
    color: var(--edm-accent-blue-dark);
    background:
        linear-gradient(var(--edm-background-accent-blue), var(--edm-background-accent-blue)),
        var(--edm-background-card);
}

.developer-workflow-step-title {
    min-height: 40px;
    color: var(--text-color-primary);
    font-size: 15px;
    font-weight: 600;
    line-height: 1.4;
}

.developer-workflow-step-description {
    margin-top: 5px;
    color: var(--edm-text-subtitle);
    font-size: 15px;
    line-height: 1.5;
}

.developer-description {
    margin-top: 5px;
    color: var(--edm-text-subtitle);
    font-size: 15px;
    line-height: 1.75;
}

.developer-section-card {
    margin: 0 !important;
    padding: 26px 28px;
}

.developer-playground-guide {
    overflow: hidden;
}

.developer-guide-header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 24px;
    padding-bottom: 24px;
}

.developer-guide-eyebrow {
    margin-bottom: 7px;
    color: var(--edm-accent-blue-dark);
    font-size: 12px;
    font-weight: 700;
    letter-spacing: 0.1em;
}

/* .developer-guide-title {
    color: var(--text-color-primary);
    font-size: 24px;
    font-weight: 600;
    line-height: 1.3;
} */

.developer-card-title {
    color: var(--text-color-primary);
    font-size: 24px;
    font-weight: 600;
    line-height: 1.3;
}

.developer-card-subtitle {
    max-width: 760px;
    margin-top: 7px;
    color: var(--edm-text-subtitle);
    font-size: 16px;
    line-height: 1.65;
}

/* .developer-guide-intro {
    max-width: 760px;
    margin-top: 7px;
    color: var(--edm-text-subtitle);
    font-size: 15px;
    line-height: 1.65;
} */

.developer-guide-status {
    flex: 0 0 auto;
    padding: 7px 13px;
    color: var(--edm-accent-blue-dark);
    font-size: 13px;
    font-weight: 600;
    background: var(--edm-background-accent-blue);
    border-radius: var(--card-radius-pill);
}

.developer-guide-stage {
    padding: 30px 0;
    border-top: 1px solid var(--edm-outline);
}

.developer-guide-stage:last-child {
    padding-bottom: 0;
}

.developer-guide-section-heading {
    display: flex;
    align-items: flex-start;
    gap: 14px;
    margin-bottom: 22px;
}

.developer-guide-section-number {
    display: flex;
    flex: 0 0 38px;
    align-items: center;
    justify-content: center;
    width: 38px;
    height: 38px;
    color: var(--edm-accent-dark);
    font-size: 12px;
    font-weight: 700;
    background: var(--edm-background-accent);
    border-radius: 50%;
}

.developer-guide-stage:nth-child(even) .developer-guide-section-number {
    color: var(--edm-accent-blue-dark);
    background: var(--edm-background-accent-blue);
}

.developer-guide-section-title {
    color: var(--text-color-primary);
    font-size: 20px;
    font-weight: 600;
    line-height: 1.35;
}

.developer-guide-section-description {
    margin-top: 4px;
    color: var(--edm-text-subtitle);
    font-size: 15px;
    line-height: 1.6;
}

.developer-guide-split {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    align-items: start;
    gap: 28px;
}

.developer-guide-explanation {
    display: flex;
    flex-direction: column;
    gap: 18px;
    min-width: 0;
}

/* .developer-guide-copy {
    margin: 0;
    color: var(--text-color-secondary);
    font-size: 15px;
    line-height: 1.75;
} */

.developer-guide-detail-card {
    padding: 18px;
    background: var(--edm-background-main-sub);
    border-radius: 14px;
}

.developer-guide-detail-title {
    color: var(--text-color-primary);
    font-size: 14px;
    font-weight: 600;
}

.developer-guide-detail-title:not(:first-child) {
    margin-top: 15px;
}

.developer-guide-detail-copy {
    margin-top: 4px;
    color: var(--edm-text-subtitle);
    font-size: 13px;
    line-height: 1.55;
}

.developer-guide-list {
    margin: 0;
    padding-left: 22px;
    color: var(--text-color-secondary);
    font-size: 14px;
    line-height: 2;
}

.developer-playground-preview.agent-card {
    min-height: 0;
    padding: 0 22px 18px;
    border: 1px solid var(--edm-outline) !important;
    box-shadow: none !important;
}

.developer-playground-preview .playground-panel-body,
.developer-playground-preview .playground-state-settings {
    row-gap: 14px;
    padding: 18px 0;
}

.developer-playground-preview .playground-field,
.developer-playground-preview .playground-field:last-child {
    margin-bottom: 0;
}

.developer-playground-preview .edm-input.form-control {
    height: 42px;
}

.developer-preview-button {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 38px;
    padding: 7px 16px;
    cursor: default;
}

.developer-playground-preview .playground-generate-row {
    margin-top: 16px;
}

.developer-playground-preview .playground-generate-row .developer-preview-button {
    width: 100%;
}

.developer-generate-panel {
    box-sizing: border-box;
    width: 100%;
    padding: 18px;
    background: var(--edm-background-main-sub);
    border-radius: 16px;
}

.developer-generate-content {
    box-sizing: border-box;
    width: 50%;
    margin: 0 auto;
}

.developer-json-toolbar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    margin-bottom: 12px;
}

.developer-json-meta {
    color: var(--edm-accent-dark);
    font-size: 12px;
    font-weight: 600;
}

.developer-json-meta-muted {
    color: var(--edm-text-subtitle);
    font-weight: 500;
}

.developer-json-panel {
    min-width: 0;
    padding: 16px;
    background: var(--card-bg-agent);
    border: 1px solid var(--edm-outline);
    border-radius: 14px;
}

.developer-json-label,
.developer-json-toolbar-title {
    margin-bottom: 10px;
    color: var(--text-color-primary);
    font-size: 14px;
    font-weight: 600;
}

.developer-json-toolbar-title {
    margin-bottom: 0;
}

.developer-guide-json-editor {
    border: 1px solid var(--edm-outline);
    border-radius: 10px;
}

.developer-guide-call-button {
    width: 100%;
    min-width: 0;
    margin-top: 14px;
    margin-left: 0;
    text-align: center;
}

.developer-output-layout {
    display: grid;
    grid-template-columns: minmax(0, 0.95fr) minmax(0, 1.05fr);
    align-items: stretch;
    gap: var(--card-gap);
    margin-bottom: var(--card-gap);
}

.developer-output-layout .developer-json-panel {
    display: flex;
    flex-direction: column;
    background: var(--edm-background-main-sub);
    border: 0;
}

.developer-output-layout .developer-guide-json-editor {
    flex: 1 1 auto;
}

.developer-output-summary {
    padding: 20px;
    background: var(--edm-background-main-sub);
    border-radius: 14px;
}

.developer-output-summary-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding-bottom: 16px;
    border-bottom: 1px solid var(--edm-outline);
}

.developer-output-status {
    color: var(--edm-accent-dark);
    font-size: 14px;
    font-weight: 650;
}

.developer-output-status::before {
    display: inline-block;
    width: 8px;
    height: 8px;
    margin-right: 8px;
    background: var(--edm-accent);
    border-radius: 50%;
    content: "";
}

.developer-output-version {
    color: var(--edm-text-subtitle);
    font-size: 12px;
}

.developer-output-actions {
    display: grid;
    gap: 12px;
    padding: 16px 0;
}

.developer-output-action {
    padding: 14px 16px;
    background: var(--card-bg-agent);
    border-left: 4px solid transparent;
    border-radius: 12px;
}

.developer-output-action-blue {
    border-left-color: var(--edm-accent-blue);
}

.developer-output-action-lime {
    border-left-color: var(--edm-accent);
}

.developer-output-action-yellow {
    border-left-color: var(--edm-accent-yellow);
}

.developer-output-action-label {
    color: var(--edm-text-subtitle);
    font-size: 12px;
}

.developer-output-action-value {
    margin-top: 4px;
    color: var(--text-color-primary);
    font-size: 23px;
    font-weight: 600;
}

.developer-output-action-description,
.developer-output-footnote {
    margin-top: 4px;
    color: var(--edm-text-subtitle);
    font-size: 13px;
    line-height: 1.55;
}

.developer-output-footnote {
    margin-top: 0;
    padding-top: 14px;
    border-top: 1px solid var(--edm-outline);
}

.developer-action-reference {
    padding: 22px;
    background: var(--edm-background-main-sub);
    border-radius: 14px;
}

.developer-action-reference-header {
    margin-bottom: 18px;
}

.developer-action-reference-heading {
    color: var(--text-color-primary);
    font-size: 17px;
    font-weight: 600;
}

.developer-action-reference-subtitle {
    margin-top: 5px;
    color: var(--edm-text-subtitle);
    font-size: 13px;
    line-height: 1.55;
}

.developer-action-reference-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 12px;
}

.developer-action-reference-group {
    min-width: 0;
    padding: 17px;
    background: var(--edm-background-card);
    border-radius: 12px;
    box-shadow: var(--card-shadow-soft);
}

.developer-action-reference-title {
    color: var(--text-color-primary);
    font-size: 15px;
    font-weight: 600;
}

.developer-action-reference-list {
    display: grid;
    gap: 10px;
    margin-top: 13px;
}

.developer-action-reference-row {
    display: grid;
    grid-template-columns: 108px minmax(0, 1fr);
    gap: 9px;
    align-items: center;
    padding-bottom: 10px;
    color: var(--text-color-secondary);
    font-size: 13px;
    line-height: 1.5;
    border-bottom: 1px solid var(--edm-outline);
}

.developer-action-reference-row:last-child {
    padding-bottom: 0;
    border-bottom: 0;
}

.developer-action-reference-value {
    box-sizing: border-box;
    width: 108px;
    padding: 4px 16px;
    color: var(--text-color-primary);
    font-weight: 600;
    background: var(--edm-background-accent);
    border-radius: var(--card-radius-pill);
    /* text-align: center; */
    white-space: nowrap;
}

.developer-action-reference-group-blue .developer-action-reference-value {
    color: var(--edm-accent-blue-dark);
    background: var(--edm-background-accent-blue);
}

.developer-action-reference-group-lime .developer-action-reference-value {
    color: var(--edm-accent-dark);
    background: var(--edm-background-accent);
}

.developer-action-reference-group-yellow .developer-action-reference-value {
    color: var(--edm-accent-yellow-dark);
    background: var(--edm-background-accent-yellow);
}

.developer-action-reference-description {
    color: var(--edm-text-subtitle);
}

.developer-guide-stage-output > .developer-callout {
    margin-top: var(--card-gap) !important;
}

.developer-api-guide {
    overflow: hidden;
}

.developer-api-auth-badge {
    flex: 0 0 auto;
    padding: 7px 13px;
    color: var(--edm-alert);
    font-size: 13px;
    font-weight: 600;
    background: var(--edm-alert-background);
    border-radius: var(--card-radius-pill);
}

.developer-api-overview {
    display: grid;
    gap: 14px;
    margin-bottom: 24px;
    padding: 20px;
    background: var(--edm-background-main-sub);
    border-radius: 14px;
}

.developer-api-endpoint {
    display: flex;
    align-items: center;
    gap: 12px;
    min-width: 0;
}

.developer-api-method {
    flex: 0 0 auto;
    padding: 6px 10px;
    color: var(--edm-text-button);
    font-size: 12px;
    font-weight: 700;
    background: var(--edm-accent);
    border-radius: 7px;
}

.developer-api-endpoint-url {
    min-width: 0;
    overflow-x: auto;
    color: var(--text-color-primary);
    font-size: 14px;
    white-space: nowrap;
}

.developer-api-params-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: var(--card-gap);
    padding: 22px;
    background: var(--edm-background-main-sub);
    border-radius: 16px;
}

.developer-api-param-column {
    min-width: 0;
    padding: 20px;
    background: transparent;
    border-radius: 14px;
}

.developer-api-param-title {
    padding-bottom: 15px;
    color: var(--text-color-primary);
    font-size: 17px;
    font-weight: 600;
    border-bottom: 1px solid var(--edm-outline);
}

.developer-api-param-list {
    margin-top: 16px;
}

.developer-api-param-list > .row,
.developer-api-param-list > .row > .row {
    margin-right: 0;
    margin-left: 0;
}

.developer-api-param-list > .row:last-child hr {
    display: none;
}

.developer-api-param-list .edm-text-param {
    font-size: 14px;
    font-weight: 600;
}

.developer-api-param-list .edm-text-detail {
    font-size: 13px;
    line-height: 1.55;
}

.developer-api-header-table-wrap {
    overflow: hidden;
    background: var(--edm-background-main-sub);
    border: 0;
    border-radius: 14px;
}

.developer-api-header-table-wrap .api-header-table {
    background: transparent;
}

.developer-api-header-table-wrap .api-header-table th,
.developer-api-header-table-wrap .api-header-table td {
    padding: 15px 18px;
    border-bottom: 1px solid var(--edm-outline);
}

.developer-api-header-table-wrap .api-header-table th {
    color: var(--text-color-primary);
    font-size: 13px;
    font-weight: 600;
    background: transparent;
}

.developer-api-header-table-wrap .edm-text-param,
.developer-api-header-table-wrap .edm-text-detail {
    font-size: 15px !important;
    line-height: 1.5;
}

.developer-api-header-table-wrap .api-header-table tbody tr:last-child td {
    border-bottom: 0;
}

.developer-api-code-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    align-items: stretch;
    gap: var(--card-gap);
}

.developer-api-code-panel {
    min-width: 0;
    padding: 16px;
    background: var(--edm-background-main-sub);
    border-radius: 14px;
}

.developer-api-code-title {
    margin-bottom: 12px;
    color: var(--text-color-primary);
    font-size: 14px;
    font-weight: 600;
}

.developer-api-code-editor {
    overflow: hidden;
    border: 1px solid var(--edm-outline);
    border-radius: 10px;
}

.developer-api-response-stage > .developer-callout {
    margin-top: var(--card-gap) !important;
}

.developer-section-card > .row:first-child {
    min-height: 42px;
    margin: 0 !important;
    padding-bottom: 14px;
    border-bottom: 1px solid var(--edm-outline) !important;
}

.developer-section-title {
    margin-top: 32px !important;
    color: var(--text-color-primary) !important;
    font-size: 20px !important;
    font-weight: 600 !important;
}

.developer-shell .card {
    border-color: var(--edm-outline) !important;
    box-shadow: none !important;
}

.developer-info-card {
    border: 0 !important;
    background: var(--edm-background-main-sub) !important;
}

.developer-api-example {
    margin-right: 0;
    margin-left: 0;
    padding: 16px 4px;
    background: var(--edm-background-main-sub);
    border-radius: 14px;
}

.developer-code-block pre,
.developer-code-block .ace_editor,
.developer-api-example .ace_editor {
    border: 0 !important;
    border-radius: 12px !important;
}

.developer-shell .api-header-table {
    overflow: hidden;
    background: var(--card-bg-agent);
    border-radius: 12px;
}

@media (max-width: 1200px) {
    .developer-workflow-steps {
        grid-template-columns: repeat(4, minmax(0, 1fr));
        row-gap: 24px;
    }

    .developer-workflow-steps::before {
        display: none;
    }

    .developer-guide-split,
    .developer-output-layout,
    .developer-api-params-grid,
    .developer-api-code-grid {
        grid-template-columns: 1fr;
    }

    .developer-generate-content {
        width: 100%;
    }

}

@media (max-width: 768px) {
    .developer-container {
        padding: 16px;
    }

    .developer-hero {
        align-items: flex-start;
        flex-direction: column;
        min-height: 0;
        padding: 28px 22px;
    }

    .developer-chip-row {
        justify-content: flex-start;
    }

    .developer-workflow-card,
    .developer-section-card {
        padding: 22px 18px;
    }

    .developer-workflow-header {
        flex-direction: column;
        gap: 14px;
        margin-bottom: 20px;
    }

    .developer-guide-header {
        flex-direction: column;
        gap: 14px;
    }

    .developer-guide-stage {
        padding: 24px 0;
    }

    .developer-guide-title {
        font-size: 21px;
    }

    .developer-api-endpoint {
        align-items: flex-start;
        flex-direction: column;
    }

    .developer-action-reference-grid {
        grid-template-columns: 1fr;
    }

    .developer-action-reference-group {
        padding: 16px;
    }

    .developer-api-endpoint-url {
        width: 100%;
    }

    .developer-api-params-grid {
        padding: 14px;
    }

    .developer-api-param-column,
    .developer-api-code-panel {
        padding: 14px;
    }

    .developer-playground-preview.agent-card,
    .developer-generate-panel,
    .developer-json-panel,
    .developer-output-summary {
        padding-right: 14px;
        padding-left: 14px;
    }

    .developer-playground-preview .playground-two-column {
        grid-template-columns: 1fr;
    }

    .developer-workflow-notices,
    .developer-workflow-steps {
        grid-template-columns: 1fr;
    }

    .developer-workflow-notices {
        margin-bottom: 24px;
    }

    .developer-workflow-steps {
        gap: 8px;
    }

    .developer-workflow-step {
        display: grid;
        grid-template-columns: 48px minmax(0, 1fr);
        column-gap: 14px;
        padding: 8px 0;
        text-align: left;
    }

    .developer-workflow-step-number {
        grid-row: 1 / 3;
        margin: 0;
    }

    .developer-workflow-step-title {
        align-self: end;
        min-height: 0;
    }

    .developer-workflow-step-description {
        align-self: start;
        margin-top: 2px;
    }

    .guide-responsive-mx {
        margin-right: 0;
        margin-left: 0;
    }
}


/* ------------------- text style ------------------- */
.edm-text-head-large {
    font-size: 26px;
    font-weight: 500;
    font-family: "Inter", sans-serif;
}

.edm-text-head {
    font-size: 24px;
    font-weight: 400;
    font-family: "Inter", sans-serif;
}

.edm-text-title {
    font-size: 18px;
    font-weight: 400;
    font-family: "Inter", sans-serif;
}

.edm-text-subtitle {
    font-size: 16px;
    font-weight: 400;
    font-family: "Inter", sans-serif;
}

.edm-text-body {
    font-size: 14px;
    font-weight: 400;
    font-family: "Inter", sans-serif;
}

.edm-text-point {
    font-size: 28px;
    font-weight: 500;
    font-family: "Inter", sans-serif;
}

.edm-text-param {
    font-size: 16px;
    font-weight: 600;
    font-family: "Consolas", monospace; /*Fira Code*/
}

.edm-text-type {
    font-size: 12px;
    font-weight: 300;
    font-family: "Consolas", monospace;
}

.edm-text-detail {
    font-size: 14px;
    font-weight: 400;
    font-family: "Inter", sans-serif;
}

.edm-text-hint {
    font-size: 15px;
    font-weight: 350;
    font-family: "Inter", sans-serif;
}

.edm-text-hint-samll {
    font-size: 13px;
    font-weight: 350;
    font-family: "Inter", sans-serif;
}

/* --- home --- */
.edm-text-hero-large {
  color: var(--edm-text-header-main);
  font-size: 50px;
  font-weight: 600;
}

.edm-text-hero-small {
  color: var(--edm-text-header-main);
  font-size: 50px;
  font-weight: 600;
}

.edm-text-home-card-title {
  color: var(--edm-text-body);
  font-size: 16px;
  font-weight: 500
}

.edm-text-home-card-content {
  color: var(--edm-text-subtitle);
  font-size: 14px;
  font-weight: 500
}

/* ------------------- animation ------------------- */
.line-container{
  --pad: 5px;
  --dot: 6px;

  position: relative;
  width: 50px;
  height: 20px;
}

.line-container::before{
  content:"";
  position:absolute;
  top:50%;
  left:var(--pad);
  right:var(--pad);
  height:1.5px;
  background-color: var(--edm-icon-line);
  transform: translateY(-50%);
}

.moving-dot{
  position:absolute;
  top:50%;
  width:var(--dot);
  height:var(--dot);
  border-radius:50%;
  transform: translateY(-50%);

  left: var(--pad);     
  opacity: 0;
}

@keyframes ess-move{
  0%   { left: var(--pad); }
  100% { left: calc(100% - var(--pad) - var(--dot)); }
}

.mode-idle .moving-dot{
  opacity:0;
  animation:none;
}

.mode-charging .moving-dot{
  opacity:1;
  background-color: var(--edm-ess-charging);
  animation: ess-move 3s linear infinite;
  animation-direction: normal;   /* left -> right */
}

.mode-discharging .moving-dot{
  opacity:1;
  background-color: var(--edm-ess-discharging);
  animation: ess-move 3s linear infinite;
  animation-direction: reverse;  /* right -> left */
}


/* ------------------- navigation bar ------------------- */
#nav-header {
    display: none;
}

.navbar-inner {
    min-height: 42px;
    padding: 0 12px;
    display: flex;
    align-items: center;
    justify-content: flex-start;
}

.header-logo-link {
    margin: 0;
    padding: 0;
}

.app-logo {
    display: block;
    height: 42px;
    width: auto;
}

.mobile-menu-btn {
    display: none;
}

@media (max-width: 768px) {
    #nav-header {
        display: flex;
        width: 100%;
        flex: 0 0 auto;
    }

    .navbar-inner {
        min-height: 42px;
        gap: 10px;
    }

    .app-logo {
        height: 30px;
    }

    .mobile-menu-btn {
        width: 32px;
        height: 32px;
        padding: 7px 5px;
        border: 0;
        border-radius: 6px;
        background: transparent;
        display: flex;
        flex-direction: column;
        justify-content: space-between;
        flex: 0 0 auto;
    }

    .mobile-menu-btn:hover,
    .mobile-menu-btn:focus-visible {
        background: rgba(255, 255, 255, 0.1);
    }

    .mobile-menu-line {
        display: block;
        width: 22px;
        height: 2px;
        border-radius: 2px;
        background: var(--edm-text-header-main);
    }
}

.navbar-toggler {
    width: 44px;
    height: 44px;
    padding: 6px;
    border-radius: 8px;
}

.navbar-toggler-icon {
    width: 22px;
    height: 22px;
}

@media (max-width: 768px) {
    .navbar-toggler {
        width: 34px;
        height: 34px;
        padding: 4px;
    }

    .navbar-toggler-icon {
      background-image: 
      url("data:image/svg+xml,%3csvg viewBox='0 0 30 30' xmlns='http://www.w3.org/2000/svg'%3e%3cpath stroke='%23FBF091' stroke-width='2' stroke-linecap='round' stroke-miterlimit='10' d='M4 7h22M4 15h22M4 23h22'/%3e%3c/svg%3e");
  }
}

.app-offcanvas {
  background-color: var(--edm-background-card); 
}

.app-offcanvas .offcanvas-header {
  border-bottom: 1px solid rgba(255,255,255,0.1);
}

.app-offcanvas .offcanvas-title {
  color: var(--edm-text-subtitle);
  font-weight: 600;
  font-size: 18px;
}

.app-offcanvas .header-nav-link.active {
  color: var(--edm-text-header-main) !important;
}

/* .app-offcanvas .offcanvas-body {
  padding: 16px;
} */

.app-offcanvas .btn-close {
    filter: invert(1);
    opacity: 0.7;
}

.app-offcanvas .btn-close:hover {
    opacity: 1;
}

/* API | Dashboard hover default*/
.header-nav-link {
    color: var(--edm-text-header-sub);              /* text color */
    font-size: 18px;
    font-weight: 350;
    font-family: "Inter", sans-serif;   
    cursor: pointer;             /* change mouse to hand */
    transition: color 0.2s ease, 
                border-color 0.2s ease,
                opacity 0.2s ease;
    padding-bottom: 2px;         
}

/* hover */
.header-nav-link:hover {
    color: var(--edm-text-header-main);  
    text-decoration: none;       
}

/* API | Dashboard actived */
.header-nav-link.active {
    color: var(--edm-text-header-main);              /* text color before click */
    border-bottom: 2px solid var(--edm-accent);  /* text color after click */
    font-weight: 400;            
}

/* ------------------- Agent card height ------------------- */
.card-fixed-height {
    height: 200px;
}

@media (max-width: 768px) {
    .card-fixed-height {
        height: 250px; 
    }
}

/* ------------------- API tool button ------------------- */
.tool-action{
  cursor: pointer;
  padding: 4px 8px;
  border-radius: 6px;
  color: var(--edm-text-header-sub);
}
.tool-action:hover{
  background: rgba(255,255,255,0.06);
  color: var(--edm-text-header-main);
}


/* ------------------- button hover ------------------- */
.edm-btn {
  background-color: var(--edm-accent);
  color: var(--edm-text-button);
  border: 0px solid;
  border-radius: 8px;
  padding: 6px 16px;
  transition: 0.2s ease;
  font-size: 17px;
  font-weight: 600;
}

/* hover（only works on buttons without the "no-hover" class) */
.edm-btn:not(.no-hover):hover {
  color: var(--edm-text-button);
  background-color: var(--edm-accent-dark);
  font-weight: 400;
  filter: none !important;     
  opacity: 1 !important;     
  font-weight: 650;  
}

.edm-btn:active {
    transform: scale(0.98);
}


/* ------------------- API Dash Ace ------------------- */
.edm-ace {
  border: 1px solid var(--edm-outline);
  border-radius: 6px;
}

/* .edm-ace.ace_focus {
  box-shadow: 0 0 6px 3px rgba(255, 255, 102, 0.25) !important;
} */

.edm-ace .ace_scrollbar::-webkit-scrollbar {
  width: 10px;
  height: 10px;
}

.edm-ace .ace_scrollbar::-webkit-scrollbar-track {
  background: var(--edm-background);     
}

.edm-ace .ace_scrollbar::-webkit-scrollbar-thumb {
  background-color: var(--edm-scrollbar); 
  border-radius: 6px;
  border: 2px solid var(--edm-background);
}

.edm-ace .ace_scrollbar::-webkit-scrollbar-thumb:hover {
  background-color: var(--edm-scrollbar-hover); 
}

.edm-ace .ace_cursor {
  color: var(--edm-accent);  
}

.edm-ace .ace_string {
  color: var(--edm-text-subtitle) !important;
}

.ace_keyword {
  color: var(--edm-accent-blue) !important;
}

.edm-ace .ace_constant.ace_numeric {
  color: var(--edm-accent-blue) !important;
}

/* .edm-ace .ace_constant {
    color: #c6cc99 !important;
}

.ace_keyword {
  color: #6699CC !important;
} */

/* ------------------- User Guide ------------------- */
.guide-display {
  display: flex;
}
@media (max-width: 576px) {
  .guide-display {
    display: none;
  }
}


/* ------------------- API Setting Row ------------------- */
.api-setting-row {
  margin: 0 50px;
}

@media (max-width: 576px) {
  .api-setting-row {
    margin: 0 10px;
  }
}

/* ------------------- API Dash Ace Row ------------------- */
.api-editor-row {
  padding: 0 50px;
}

@media (max-width: 576px) {
  .api-editor-row {
    padding: 0 10px;
  }
}

/* ------------------- Dropdown ------------------- */
.edm-dropdown .Select-control {
  background-color: var(--edm-background-card) !important;
  border-color: var(--edm-outline) !important;
}

/* text color */
.edm-dropdown .Select-value-label {
  color: var(--edm-text-body) !important;
}

/* list text color */
.edm-dropdown .VirtualizedSelectOption {
  background-color: var(--edm-background-card) !important;
  color: var(--edm-text-subtitle) !important;
}

/* hover line */
.edm-dropdown .VirtualizedSelectOption.VirtualizedSelectFocusedOption {
  background-color: var(--edm-background-btn-hover) !important;
}

.edm-dropdown:focus-within .Select-control {               
  /* box-shadow:  0 0 6px 3px rgba(255, 255, 102, 0.25) !important;  */
  box-shadow:  none !important;
  outline: none !important;                         
}


/* ------------------- Input (Textbox) ------------------- */
.edm-input.form-control {
  background-color: var(--edm-background-button) !important;
  border-color: var(--edm-outline) !important;
  color: var(--edm-text-body) !important;
  border-radius: 6px; 
}

/* placeholder color */
.edm-input::placeholder {
  color: var(--edm-text-subtitle) !important;
  opacity: 0.7;
}

/* hover */
.edm-input.form-control:hover {
  border-color: var(--edm-text-body) !important;
  background-color: var(--edm-background) !important;
}
.edm-input.form-control:disabled:hover {
  border-color: var(--edm-text-subtitle) !important;
  background-color: var(--edm-background-button) !important;
}

/* focus */
.edm-input.form-control:focus {
  background-color: var(--edm-background) !important;
  color: var(--edm-text-body) !important;

  /* box-shadow: 0 0 6px 3px rgba(255, 255, 102, 0.25) !important; */
  box-shadow: none !important;   
  border-color: var(--edm-accent) !important;
  outline: none !important;
}

.edm-input:-webkit-autofill {
  -webkit-box-shadow: 0 0 0 1000px #2b2b2b inset !important;
  -webkit-text-fill-color: #ffffff !important;
}

/* ------------------- Customize Input Spin Button ------------------- */
/* hide original spin button */
.edm-input::-webkit-outer-spin-button,
.edm-input::-webkit-inner-spin-button {
  -webkit-appearance: none;
  margin: 0;
}

.edm-input[type="number"] {
  appearance: textfield;
  -moz-appearance: textfield;
}

/* whole container */
.edm-number-wrapper {
  position: relative;
}

.edm-spinner-container {
  position: absolute;
  right: 8px;
  top: 50%;
  transform: translateY(-50%);
  display: flex;
  flex-direction: column;
}

.edm-spinner-btn {
  font-size: 10px;
  color: var(--edm-text-subtitle); 
  line-height: 10px;
  cursor: pointer;
  user-select: none;
  padding: 2px;
  transition: color 0.2s;
}

/* hover */
.edm-spinner-btn:not(.no-hover):hover {
  color: var(--edm-text-body);
}

/* no hover */
.edm-spinner-btn.no-hover {
  cursor: default;   
}

/* ------------------- Radio (RadioItem) ------------------- */
.edm-radio-btn {
  background-color: var(--edm-background-button);
  color: var(--edm-text-subtitle);
  border: 1px solid var(--edm-text-subtitle);
  border-radius: 6px;
  margin-right: 6px;
  padding: 6px 12px;
  transition: all 0.2s ease;
}

/* hover */
.edm-radio-btn:hover {
  color: var(--edm-text-body);
  border: 1px solid var(--edm-text-body);
}

input[type="radio"]:disabled + .edm-radio-btn,
input[type="radio"]:disabled + .edm-radio-btn:hover {
  color: var(--edm-text-subtitle);
  border: 1px solid var(--edm-text-subtitle);
}

/* button selected, active */
.edm-radio-btn.active {
  background-color: var(--edm-background);   
  color: var(--edm-text-body);                 
  border-color: var(--edm-accent);
}

.radio-readonly {
  pointer-events: none;
}

.radio-readonly .edm-radio-btn {
  cursor: default;
}

.radio-readonly .edm-radio-btn:hover {
  background-color: inherit !important;
  color: inherit !important;
  border-color: inherit !important;
  box-shadow: none !important;
}

/* ------------------- Graduated Bar ------------------- */
#bar-u-chiller > div > div,
#bar-u-heater > div > div,
#bar-u-load > div > div,
#bar-q-load > div > div,
#bar-q-chiller > div > div,
#bar-q-heater > div > div,
#bar-q-leak > div > div {
  width: 200px;  
  background-color: var(--edm-background-main-sub) !important;
}


/* ------------------- Modal Button CLose ------------------- */
.edm-modal .btn-close {
  filter: none;
  opacity: 0.7;
}

.edm-modal .btn-close:hover {
  opacity: 1;
}

/* .edm-modal-body .modal-body::-webkit-scrollbar {
    width: 10px;
    height: 10px;
}

.edm-modal-body .modal-body::-webkit-scrollbar-track {
    background: var(--edm-background);     
}

.edm-modal-body .modal-body::-webkit-scrollbar-thumb {
    background-color: var(--edm-scrollbar); 
    border-radius: 6px;
    border: 2px solid var(--edm-background);
}

.edm-modal-body .modal-body::-webkit-scrollbar-thumb:hover {
    background-color: var(--edm-scrollbar-hover); 
} */

/* ------------------- API params hover ------------------- */
.api-tips-link {
    color: var(--edm-text-body);
    transition: color 0.15s ease;
}

.api-tips-link:hover {
    color: var(--edm-accent);
}



/*----*/
@media (max-width: 767px) {
  .figure-padding-responsive {
    padding-right: 0 !important;
  }
}

/* large screen: add padding */
@media (min-width: 768px) {
  .figure-padding-responsive {
    padding-right: 60px;
  }
}

/* set toast  */
.no-toast-header .toast-header {
    display: none;
}

/* default: down */
.rotate-icon {
    transition: transform 0.25s ease-in-out;
    transform: rotate(0deg);
}

/* expand: up */
.rotate-icon.open {
    transform: rotate(180deg);
}

/* ------------------- Guide table ------------------- */
.api-header-table-wrap {
  width: 100%;
  overflow-x: auto;
}

.api-header-table {
  width: 100%;
  border-collapse: collapse;
  table-layout: fixed;   
}

.api-header-table th,
.api-header-table td {
  padding: 12px 8px;
  border-bottom: 1px solid rgba(255,255,255,0.12);
  vertical-align: middle;
  text-align: left;
}

.api-header-table th {
  font-weight: 600;
}

@media (max-width: 768px) {
  .api-header-table {
    width: max-content;
    min-width: 100%;
    table-layout: auto;
  }

  .api-header-table th,
  .api-header-table td {
    white-space: nowrap;
  }
}

.guide-responsive-mx {
  margin-left: 1.5rem;   /* ≈ mx-4 */
  margin-right: 1.5rem;
}
@media (max-width: 576px) {
  .guide-responsive-mx {
    margin-left: 0.5rem;  
    margin-right: 0.5rem;
  }
}

/*------------- Side Bar --------------*/
.sidebar-host {
    width: 264px;
    flex: 0 0 264px;
    min-height: 0;
    padding: 16px 0 16px 16px;
    background: var(--page-bg-agent);
    display: flex;
}

.desktop-sidebar-card {
    width: 240px;
    height: 100%;
    min-height: 0;
    display: flex;
    flex-direction: column;
    overflow: hidden;
    border-radius: var(--card-radius);
    background: var(--edm-background-card);
    box-shadow: var(--card-shadow);
}

.desktop-sidebar-header {
    padding: 6px 12px;
    display: flex;
    flex: 0 0 auto;
    align-items: center;
    background: var(--edm-background-header);
    border-bottom: 1px solid var(--edm-outline);
}

.desktop-sidebar-logo-link {
    display: inline-flex;
    align-items: center;
}

.desktop-sidebar-logo {
    display: block;
    height: 42px;
    width: auto;
}

.sidebar {
    width: 100%;
    min-height: 0;
    flex: 1;
    padding: 16px 12px;
    flex-shrink: 0;
    display: flex;
    flex-direction: column;
    border-right: 0;
    background: var(--edm-background-card);
}

.sidebar-backdrop {
    display: none;
}

@media (max-width: 768px) {
    .sidebar-host {
        width: 0;
        flex-basis: 0;
        padding: 0;
        background: transparent;
    }

    .desktop-sidebar-card {
        width: 0;
        display: contents;
        overflow: visible;
        border-radius: 0;
        box-shadow: none;
    }

    .desktop-sidebar-header {
        display: none;
    }

    .sidebar {
        width: 240px;
        position: fixed;
        z-index: 1045;
        top: 43px;
        bottom: 0;
        left: 0;
        height: auto;
        box-shadow: 8px 0 24px rgba(0, 0, 0, 0.14);
        transform: translateX(-105%);
        transition: transform 0.22s ease;
    }

    .sidebar.sidebar-open {
        transform: translateX(0);
    }

    .sidebar-backdrop {
        position: fixed;
        z-index: 1040;
        inset: 43px 0 0;
        width: 100%;
        padding: 0;
        border: 0;
        background: rgba(0, 0, 0, 0.35);
    }

    .sidebar-backdrop.sidebar-backdrop-open {
        display: block;
    }
}

.sidebar-top {
    overflow-y: auto;
}

.sidebar-bottom {
    margin-top: auto;
}

/*------------- Side Bar navigation --------------*/
.nav-section-label {
    width: 100%;
    box-sizing: border-box;
    padding: 11px 14px;
    display: flex;
    align-items: center;
    border: 1px solid rgba(137, 177, 87, 0.22);
    border-radius: 12px;
    margin-bottom: 10px;
    color: var(--edm-text-header-title);
    background: linear-gradient(
        135deg,
        var(--edm-accent-blue) 0%,
        var(--edm-accent) 100%
    );
    box-shadow: 0 6px 18px rgba(35, 60, 90, 0.1);
    font-size: 16px;
    font-weight: 700;
    line-height: 1.2;
    letter-spacing: 0.025em;
    text-transform: none;
    white-space: nowrap;
}

.sidebar-product-brand {
    width: 100%;
    box-sizing: border-box;
    padding: 8px 12px 0;
    display: flex;
    align-items: center;
    flex-direction: column;
}

.sidebar-product-logo {
    display: block;
    width: auto;
    max-width: 100%;
    height: 28px;
    object-fit: contain;
}

.sidebar-product-divider {
    width: 100%;
    height: 1px;
    margin-top: 16px;
    background: linear-gradient(
        90deg,
        rgba(24, 24, 24, 0) 0%,
        rgba(24, 24, 24, 0.42) 18%,
        rgba(24, 24, 24, 0.88) 50%,
        rgba(24, 24, 24, 0.42) 82%,
        rgba(24, 24, 24, 0) 100%
    );
}

.nav-item-link {
    display: flex;
    align-items: center;
    padding: 8px 12px;
    border-radius: 8px;
    color: var(--edm-text-body);
    font-size: 15px;
}

.nav-item-link:hover {
    background-color: var(--edm-background-btn-hover);
    color: var(--edm-text-body);
}

.nav-item-link.active {
    background-color: var(--edm-background-accent) !important;
    color: var(--text-color-primary) !important;
    font-weight: 500;
}

/*-------- Button Login --------*/
.edm-btn-login {
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--edm-background-header);
    border: 1px solid var(--edm-outline);
    color: var(--edm-text-button);
    font-size: 15px;
    font-weight: 600;
    padding: 8px 12px;
    border-radius: 8px;
    transition: 0.2s ease;
}

.edm-btn-login:hover,
.edm-btn-login:focus,
.edm-btn-login:active,
.edm-btn-login:focus:active {
  color: var(--edm-text-button);
  background-color: var(--edm-background-header);
  border: 1px solid var(--edm-outline);
  box-shadow: none;
  filter: none !important;
  opacity: 1 !important;
}

.edm-btn-login:active {
  background: var(--edm-background-header);
  color: var(--edm-text-button);
  transform: scale(0.98);
}

.edm-btn-login:disabled,
.edm-btn-login.disabled {
    background: var(--edm-background-dropdown);
    border-color: var(--edm-outline);
    color: var(--edm-text-button);
    opacity: 0.45;
    cursor: not-allowed;
}

/*-------- Button Start --------*/
.edm-btn-start {
  color: var(--edm-text-button);
  border-radius: 8px;
  padding: 10px 20px;
  background-color: var(--edm-accent);
  /* border: 2px solid var(--edm-accent); */
  font-size: 17px;
  font-weight: 600;
  transition: 0.2s ease;
}

.edm-btn-start:hover,
.edm-btn-start:focus,
.edm-btn-start:active,
.edm-btn-start:focus:active {
  color: var(--edm-text-button);
  background-color: var(--edm-accent-dark);
  /* border: 2px solid var(--edm-accent-dark); */
  box-shadow: none;
  filter: none !important;
  opacity: 1 !important;
}

.edm-btn-start:active {
  transform: scale(0.98);
}

/*-------- API ----------*/
.edm-playground-tab {
    width: 480px;
    padding: 16px 12px;
    flex-shrink: 0;
    display: flex;
    flex-direction: column;
}

/*-------- Playground redesign --------*/
.playground-shell {
    position: relative;
    min-height: 100%;
    background: var(--page-bg-agent);
}

.playground-container {
    min-height: 100%;
    padding: 16px;
}

.playground-layout {
    min-height: calc(100vh - 48px);
}

.playground-visual-column,
.playground-panel-column {
    padding: 0 8px;
}

.playground-visual-column {
    padding-left: 0;
}

.playground-panel-column {
    padding-right: 0;
    width: 500px;
    max-width: 500px;
    flex: 0 0 500px;
}

.agent-card.playground-visual-card {
    height: 100%;
    min-height: 720px;
    padding: 0;
    overflow: hidden;
}

.playground-digital-twin {
    width: 100%;
    height: 100%;
    min-height: 720px;
    display: block;
    border: 0;
}

.playground-panel-host {
    height: 100%;
}

.playground-panel {
    width: 100%;
    min-height: 100%;
    padding: 0;
    overflow: hidden;
}

#playground-api-panel {
    height: 100%;
    min-height: 0;
    flex-direction: column;
}

#playground-setting-panel {
    display: flex;
    flex-direction: column;
}

#playground-setting-panel .playground-panel-body {
    flex: 1 0 auto;
    align-content: start;
}

.playground-panel-header {
    padding: 16px 0px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    border-bottom: 1px solid var(--edm-outline);
}

.playground-panel-title {
    color: var(--text-color-primary);
    font-size: 24px;
    font-weight: 600;
    line-height: 1.2;
}

.playground-panel-subtitle {
    margin-top: 5px;
    color: var(--text-color-muted);
    font-size: 13px;
}

.playground-api-input-hint {
    display: block;
    transform: translateY(-10px);
}

.playground-panel-body,
.playground-state-settings,
.playground-api-section {
    padding: 20px 0px;
}

.playground-panel-body {
    display: grid;
    row-gap: 18px;
}

.playground-panel-body .playground-field {
    margin-bottom: 0;
}

.playground-field {
    min-width: 0;
    margin-bottom: 18px;
}

.playground-field:last-child {
    margin-bottom: 0;
}

.playground-field-label,
.playground-section-title {
    margin-bottom: 8px;
    color: var(--text-color-primary);
    font-size: 14px;
    font-weight: 600;
}

.playground-field-hint {
    margin-top: 5px;
    color: var(--text-color-muted);
    font-size: 12px;
}

.playground-two-column,
.playground-three-column {
    display: grid;
    column-gap: 14px;
    row-gap: 18px;
}

.playground-two-column {
    grid-template-columns: repeat(2, minmax(0, 1fr));
}

.playground-three-column {
    grid-template-columns: repeat(3, minmax(0, 1fr));
}

.playground-panel .edm-input.form-control {
    height: 44px;
    padding: 10px 42px 10px 12px;
    border: 1px solid var(--edm-outline) !important;
    border-radius: 10px;
    color: var(--text-color-primary) !important;
    background: var(--edm-background-main-sub) !important;
}

.playground-panel .edm-input.form-control:focus {
    border-color: var(--edm-accent) !important;
    background: var(--card-bg-agent) !important;
    box-shadow: 0 0 0 3px rgba(137, 177, 87, 0.14) !important;
}

.playground-panel .edm-input.form-control:disabled {
    color: var(--text-color-secondary) !important;
    background: #F0F1EF !important;
}

.playground-panel .edm-spinner-container {
    right: 12px;
}

.playground-panel .edm-spinner-btn {
    color: var(--text-color-secondary);
}

.playground-radio-group {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.playground-radio-group .form-check,
.playground-radio-group .form-check-inline {
    margin: 0;
    padding-left: 0;
    padding-right: 0;
}

.playground-radio-button {
    margin: 0;
    padding: 6px 12px;
    border: 1px solid var(--edm-outline);
    border-radius: 8px;
    color: var(--text-color-secondary);
    background: var(--edm-background-main-sub);
    font-size: 13px;
}

.playground-radio-button.active {
    border-color: var(--edm-accent);
    color: var(--text-color-primary);
    background: var(--edm-background-highlight);
}

.playground-primary-button {
    min-height: 40px;
    padding: 8px 18px;
    border-radius: 10px;
    font-size: 17px;
    font-weight: 600;
}

.playground-secondary-button {
    min-height: 40px;
    padding: 8px 18px;
    border-radius: 10px;
    font-size: 14px;
    font-weight: 600;
}

.playground-primary-button {
    border: 0;
    background-color: var(--edm-accent);
    color: var(--edm-text-button);
}

.playground-secondary-button {
    border: 1px solid var(--edm-outline);
    color: var(--text-color-primary);
    background: var(--card-bg-agent);
}

.playground-primary-button:hover,
.playground-secondary-button:hover {
    color: var(--edm-text-button);
    /* border-color: var(--edm-accent); */
    background: var(--edm-accent-dark);
}

.playground-config-actions {
    flex: 0 0 auto;
    margin-top: auto;
    padding: 16px 0 20px;
    display: flex;
    justify-content: flex-end;
    border-top: 1px solid var(--edm-outline);
}

.playground-config-edit-button {
    width: auto;
    min-width: 104px;
}

.playground-state-settings {
    padding-bottom: 8px;
    /* border-bottom: 1px solid var(--edm-outline); */
}

.playground-generate-row {
    margin-top: -8px;
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 14px;
}

.playground-generate-row .playground-secondary-button {
    width: 100%;
}

.playground-json-editor {
    overflow: hidden;
    border-radius: 10px;
}

.playground-api-input-section {
    flex: 1 1 auto;
    min-height: 270px;
    display: flex;
    flex-direction: column;
}

.playground-api-input-section .playground-json-editor {
    flex: 1 1 auto;
    min-height: 230px;
}

.playground-call-row {
    flex: 0 0 auto;
    padding: 16px 0 12px;
    border-top: 1px solid var(--edm-outline);
}

.playground-call-row .playground-primary-button {
    width: 100%;
}

.playground-inferencing-text {
    display: inline-block;
    min-height: 0;
    margin: 0;
    color: inherit;
    text-align: center;
    font: inherit;
}

.playground-api-fab {
    position: fixed;
    z-index: 1035;
    top: 28px;
    right: 28px;
    min-width: 84px;
    height: 48px;
    padding: 0 16px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 9px;
    border: 0;
    border-radius: var(--card-radius-pill);
    color: var(--edm-text-button);
    background: var(--edm-accent);
    box-shadow: 0 8px 24px rgba(35, 60, 90, 0.2);
    font-size: 14px;
    font-weight: 700;
}

.playground-api-fab:hover,
.playground-api-fab:focus-visible {
    background: var(--edm-accent-dark);
    transform: translateY(-1px);
}

.playground-api-fab-icon {
    width: 20px;
    height: 20px;
    display: block;
    flex: 0 0 20px;
    background: var(--edm-background-accent);
    -webkit-mask-position: center;
    mask-position: center;
    -webkit-mask-repeat: no-repeat;
    mask-repeat: no-repeat;
    -webkit-mask-size: contain;
    mask-size: contain;
}

.playground-api-fab-icon-api {
    -webkit-mask-image: url("/assets/icons/api.svg");
    mask-image: url("/assets/icons/api.svg");
}

.playground-api-fab-icon-settings {
    -webkit-mask-image: url("/assets/icons/settings.svg");
    mask-image: url("/assets/icons/settings.svg");
}

.playground-save-toast {
    position: fixed;
    z-index: 9999;
    bottom: 24px;
    left: 50%;
    width: auto;
    padding: 5px;
    transform: translateX(-50%);
    border-radius: var(--card-radius-pill);
    color: #FFFFFF;
    background: #C94040;
    text-align: center;
    font-size: 16px;
}

@media (max-width: 991px) {
    .playground-visual-column,
    .playground-panel-column {
        padding: 0;
    }

    .playground-panel-column {
        width: 100%;
        max-width: 100%;
        flex: 0 0 100%;
    }

    .playground-panel-column {
        margin-top: var(--card-gap);
    }

    .agent-card.playground-visual-card,
    .playground-digital-twin {
        min-height: 520px;
    }
}

@media (max-width: 768px) {
    .playground-api-fab {
        top: 60px;
    }
}

@media (max-width: 576px) {
    .playground-container {
        padding: 16px;
    }

    .playground-panel-header,
    .playground-panel-body,
    .playground-state-settings,
    .playground-api-section,
    .playground-config-actions {
        padding-left: 18px;
        padding-right: 18px;
    }

    .playground-api-fab {
        right: 18px;
    }
}

/*-------- Page Content --------*/
.main-content {
    flex: 1;   /* fill */
    min-width: 0;
    min-height: 0;
    overflow-y: auto;
}

.app-shell {
    height: 100vh;
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

.content-shell {
    flex: 1;
    min-height: 0;
    display: flex;
    flex-direction: row;
    overflow: hidden;
}

/*------------- Health dashboard redesign --------------*/
.dashboard-shell {
    min-height: 100%;
    background: var(--page-bg-agent);
    padding: 16px;
    color: var(--text-color-primary);
}

.dashboard-shell.dashboard-authenticated {
    background:
        radial-gradient(
            ellipse 25% 25% at 100% 0%,
            rgba(22, 127, 229, 0.20) 0%,
            rgba(22, 127, 229, 0.11) 42%,
            rgba(22, 127, 229, 0.04) 72%,
            rgba(22, 127, 229, 0) 100%
        ),
        var(--page-bg-agent);
}

.dashboard-top-grid {
    display: grid;
    grid-template-columns: minmax(680px, 2fr) minmax(360px, 1fr);
    gap: var(--card-gap);
    align-items: stretch;
    margin-bottom: var(--card-gap);
}

.dashboard-eyebrow {
    margin-bottom: 12px;
    color: var(--edm-accent-blue-dark);
    font-size: 14px;
    font-weight: 700;
    letter-spacing: 0.16em;
}

.dashboard-overview-column {
    min-width: 0;
    display: flex;
    flex-direction: column;
    gap: var(--card-gap);
}

.dashboard-overview-column > .overview-summary-card {
    height: auto;
    flex: 1;
}

.dashboard-expanded-layout {
    min-height: 0;
    flex: 1;
}

.dashboard-expanded-overview {
    height: 100%;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: var(--card-gap);
}

.expanded-overview-card,
.dashboard-expanded-agent-card {
    height: 100%;
}

.expanded-overview-card {
    padding: 22px;
    display: flex;
    flex-direction: column;
    justify-content: flex-start;
}

.expanded-overview-card .agent-card-header {
    grid-template-columns: 48px minmax(0, 1fr);
    gap: 18px;
    margin-bottom: 20px;
}

.expanded-overview-card .agent-card-title {
    font-size: 18px;
}

.expanded-overview-value {
    align-self: flex-start;
    /* margin-top: 20px; */
}

.expanded-overview-meta {
    margin-top: auto;
    padding-top: 32px;
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.expanded-overview-meta .agent-meta-row {
    flex-direction: column;
    align-items: stretch;
    justify-content: flex-start;
    gap: 8px;
}

.expanded-overview-meta .agent-meta-label {
    min-width: 0;
    font-size: 16px;
    line-height: 1.3;
}

.expanded-overview-meta .agent-pill {
    width: 100%;
    padding: 9px 18px;
    overflow: hidden;
    font-size: 18px;
    text-overflow: ellipsis;
}

.expanded-overview-value > *,
.expanded-overview-meta .agent-pill > * {
    font-size: inherit !important;
    font-weight: inherit !important;
    line-height: inherit !important;
}

.dashboard-expanded-agent-card {
    padding: var(--card-padding);
    flex-direction: column;
    justify-content: flex-start;
}

.dashboard-expanded-agent-card .agent-card-content {
    min-width: 0;
    flex: 1;
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 32px;
    align-items: center;
}

.dashboard-expanded-agent-card .agent-meta-stack,
.dashboard-expanded-agent-card .battery-main-row,
.dashboard-expanded-agent-card .battery-flow {
    min-width: 0;
}

.dashboard-shell.select-data-expanded .dashboard-overview-column > .overview-summary-card {
    flex: 0 0 auto;
}

.dashboard-shell.select-data-expanded .agent-page-grid {
    grid-template-columns: 1fr;
}

.dashboard-shell.select-data-expanded .agent-page-grid .agent-context-card {
    display: none;
}

.dashboard-shell.select-data-expanded-workload,
.dashboard-shell.select-data-expanded-ess {
    height: 100%;
    display: flex;
    flex-direction: column;
}

.dashboard-shell.select-data-expanded-workload .dashboard-top-grid,
.dashboard-shell.select-data-expanded-ess .dashboard-top-grid {
    flex: 0 0 auto;
}

.dashboard-shell.select-data-expanded-workload .dashboard-pages-shell,
.dashboard-shell.select-data-expanded-ess .dashboard-pages-shell {
    min-height: 0;
    flex: 1 1 auto;
}

.dashboard-shell.select-data-expanded #dashboard-page-agent-workload,
.dashboard-shell.select-data-expanded #dashboard-page-agent-ess {
    width: 100%;
    height: 100%;
    min-height: 0;
    grid-template-rows: minmax(0, 1fr);
}

.dashboard-shell.select-data-expanded #dashboard-page-agent-workload > .graph-card,
.dashboard-shell.select-data-expanded #dashboard-page-agent-ess > .graph-card {
    min-height: 0;
    flex: 1 1 auto;
    display: flex;
    flex-direction: column;
}

.dashboard-shell.select-data-expanded #dashboard-page-agent-workload .agent-graph,
.dashboard-shell.select-data-expanded #dashboard-page-agent-ess .agent-graph {
    height: auto !important;
    min-height: 0;
    flex: 1 1 0;
    overflow: hidden;
}

.dashboard-context-bar {
    width: 100%;
    min-width: 0;
    min-height: 42px;
    margin-bottom: var(--card-gap);
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
}

.dashboard-context-title {
    margin: 0;
    color: var(--text-color-primary);
    font-size: 24px;
    font-weight: 500;
    line-height: 1.2;
}

.dashboard-account-info {
    width: fit-content;
    height: 42px;
    min-width: 0;
    box-sizing: border-box;
    display: flex;
    flex: 0 0 auto;
    align-items: center;
    justify-content: flex-start;
    gap: 8px;
    padding: 0;
    background: transparent;
    white-space: nowrap;
}

.dashboard-account-label {
    color: var(--edm-text-subtitle);
    font-size: 14px;
    font-weight: 500;
}

.dashboard-account-value {
    max-width: 240px;
    overflow: hidden;
    color: var(--edm-text-body);
    font-size: 15px;
    font-weight: 600;
    text-overflow: ellipsis;
}

.dashboard-controls-card {
    background: var(--card-bg-agent);
    border-radius: var(--card-radius);
    box-shadow: var(--card-shadow);
    padding: 22px 24px;
    margin-bottom: 0;
    height: 100%;
}

.dashboard-controls-heading {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 18px;
    margin-bottom: 18px;
}

.dashboard-start-button-wrap {
    flex: 1 1 auto;
    min-width: 0;
}

.dashboard-current-time-control {
    display: flex;
    flex: 0 0 auto;
    flex-direction: column;
    align-items: flex-end;
    justify-content: center;
    min-width: 132px;
}

.dashboard-current-time-label {
    color: var(--text-color-secondary);
    font-size: 13px;
    font-weight: 500;
    margin-bottom: 4px;
}

.dashboard-time-text {
    color: var(--text-color-primary);
    font-size: 44px;
    font-weight: 500;
    line-height: 0.95;
    letter-spacing: 0;
    font-variant-numeric: tabular-nums;
    white-space: nowrap;
    padding: 6px 10px;
    border: 1px solid var(--edm-background-header);
    border-radius: 8px;
}

.dashboard-controls-title {
    font-size: 26px;
    font-weight: 500;
    color: var(--text-color-primary);
}

.dashboard-select-data-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    margin-bottom: 12px;
}

.dashboard-controls-section-title {
    color: var(--text-color-primary);
    font-size: var(--font-size-card-title);
    font-weight: 500;
}

.dashboard-select-data-toggle {
    border: 0;
    background: transparent;
    padding: 0;
    width: 32px;
    height: 32px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    box-shadow: none;
}

.dashboard-select-data-toggle:hover,
.dashboard-select-data-toggle:focus,
.dashboard-select-data-toggle:active {
    background: transparent;
    border: 0;
    box-shadow: none;
}

.dashboard-select-data-collapse {
    padding-top: 2px;
}

.dashboard-filter-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 16px;
}

.dashboard-filter-label {
    display: flex;
    align-items: center;
    gap: 10px;
    color: var(--edm-text-subtitle);
    font-size: var(--font-size-label);
    font-weight: 500;
    margin-bottom: 8px;
}

.dashboard-label-icon {
    width: 20px;
    height: 20px;
    color: var(--text-color-secondary);
    flex: 0 0 auto;
}

.dashboard-inline-svg {
    width: 100%;
    height: 100%;
    display: block;
}

.dashboard-dropdown .Select-control {
    border: 0 !important;
    border-radius: 8px !important;
    background: var(--edm-background-accent-blue) !important;
    min-height: 42px;
    box-shadow: none !important;
}

.dashboard-dropdown-action-row {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 36px;
    gap: 10px;
    align-items: center;
}

.dashboard-dropdown-custom-arrow .Select-arrow-zone {
    background-image: url("/assets/icons/icon_down_gray.svg");
    background-repeat: no-repeat;
    background-position: center;
    background-size: 18px 18px;
}

.dashboard-dropdown-custom-arrow .Select-arrow {
    display: none !important;
}

.dashboard-dropdown-with-upload .Select-arrow-zone {
    width: 36px !important;
    height: 100%;
    background-image: url("/assets/icons/icon_down_gray.svg");
    background-repeat: no-repeat;
    background-position: center;
    background-size: 18px 18px;
    pointer-events: none;
}

.dashboard-dropdown-with-upload .Select-arrow {
    display: none !important;
}

.dashboard-upload-plus-btn {
    width: 36px;
    height: 36px;
    border: 0;
    border-radius: var(--card-radius-pill);
    background: var(--edm-background-accent-blue);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0;
    box-shadow: none;
}

.dashboard-upload-plus-spacer {
    width: 36px;
    height: 36px;
    display: block;
}

.dashboard-upload-plus-btn:hover,
.dashboard-upload-plus-btn:focus,
.dashboard-upload-plus-btn:active {
    background: var(--edm-background-accent-yellow) !important;
    box-shadow: none !important;
    filter: none;
    opacity: 0.85;
}

.dashboard-upload-plus-btn .dashboard-inline-svg,
.dashboard-upload-plus-btn .dashboard-upload-plus-icon {
    width: 18px;
    height: 18px;
}

.dashboard-upload-dropzone {
    border: 1.5px dashed #D9DEE5;
    border-radius: var(--card-radius);
    background: var(--panel-bg-agent);
    padding: 30px 22px;
    cursor: pointer;
    transition: border-color 0.15s ease, background-color 0.15s ease;
}

.dashboard-upload-dropzone:hover {
    border-color: var(--color-accent-lime);
    background: #FAFDF5;
}

.dashboard-upload-dropzone-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    text-align: center;
}

.dashboard-upload-icon {
    width: 30px;
    height: 30px;
}

.dashboard-upload-title {
    color: var(--text-color-primary);
    font-size: 18px;
    font-weight: 500;
}

.dashboard-upload-hint,
.dashboard-upload-status {
    color: var(--text-color-muted);
    font-size: 14px;
}

.dashboard-upload-status {
    margin-top: 14px;
    min-height: 20px;
}

.dashboard-modal-close-btn {
    border: 0;
    border-radius: var(--card-radius-pill);
    background: var(--edm-accent);
    color: var(--edm-text-button);
    padding: 8px 20px;
}

.dashboard-modal-close-btn:hover,
.dashboard-modal-close-btn:focus {
    background: var(--edm-accent-dark);
    color: var(--edm-text-button);
    border: 0;
    box-shadow: none;
}

.dashboard-start-button {
    border-radius: var(--card-radius-pill);
    /* border: 0;*/
    background: var(--edm-accent); 
    min-width: 174px;
    width: 100%;
    display: flex;
    justify-content: center;
    align-items: center;
}

.dashboard-start-button-content {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    width: 100%;
}

.dashboard-start-button-icon {
    width: 18px;
    height: 18px;
    flex: 0 0 auto;
}

.dashboard-pages-shell {
    min-height: 0;
}

.dashboard-page-pane {
    min-height: 0;
}

.dashboard-page-grid {
    display: grid;
    gap: var(--card-gap);
}

#dashboard-page-overview {
    padding-bottom: 0;
    transition: padding-bottom 0.2s ease;
}

#dashboard-page-overview.dashboard-chat-bottom-space-active {
    padding-bottom: 160px;
}

.overview-summary-grid {
    display: grid;
    grid-template-columns: 1.1fr 1fr 1fr;
    gap: var(--card-gap);
}

.overview-summary-card {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 22px;
    height: 100%;
    padding: 28px 30px;
}

.overview-metric-item {
    display: grid;
    grid-template-columns: 64px minmax(0, 1fr);
    gap: 18px;
    align-items: center;
    min-width: 0;
}

.dashboard-icon-badge {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex: 0 0 auto;
}

.dashboard-icon-badge .dashboard-inline-svg {
    width: 30px;
    height: 30px;
}

.overview-metric-icon {
    width: 30px;
    height: 30px;
    display: block;
    object-fit: contain;
}

.overview-metric-body {
    min-width: 0;
}

.overview-metric-title {
    color: var(--text-color-secondary);
    font-size: var(--font-size-card-title);
    font-weight: 500;
    margin-bottom: 10px;
    white-space: nowrap;
}

.overview-metric-row {
    display: flex;
    align-items: baseline;
    gap: 12px;
    min-width: 0;
}

.overview-metric-value {
    color: var(--edm-text-body);
    font-size: var(--font-size-card-value);
    font-weight: 500;
    line-height: 0.95;
    white-space: nowrap;
}

.overview-weather-row {
    display: flex;
    align-items: center;
    gap: 14px;
    min-width: 0;
}

.overview-weather-details {
    color: var(--text-color-secondary);
    display: flex;
    flex-direction: column;
    gap: 4px;
    font-size: 13px;
    font-weight: 500;
    line-height: 1.15;
    white-space: nowrap;
}

.overview-metric-unit {
    color: var(--text-color-secondary);
    font-size: 14px;
    font-weight: 500;
    white-space: nowrap;
}

.overview-agent-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: var(--card-gap);
}

.dashboard-kpi-card {
    display: flex;
    min-height: 0;
    flex-direction: column;
    justify-content: center;
}

.dashboard-kpi-title {
    margin-bottom: 24px;
}

.dashboard-kpi-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 16px;
}

.dashboard-kpi-item {
    min-width: 0;
    padding: 0 20px;
}

.dashboard-kpi-item:first-child {
    padding-left: 0;
}

.dashboard-kpi-item:last-child {
    padding-right: 0;
}

.dashboard-kpi-item + .dashboard-kpi-item {
    border-left: 1px solid var(--edm-outline);
}

.dashboard-kpi-label {
    margin-bottom: 24px;
}

.agent-card-title.dashboard-kpi-label-yellow {
    color: var(--edm-accent-yellow-dark);
}

.agent-card-title.dashboard-kpi-label-blue {
    color: var(--edm-accent-blue);
}

.agent-card-title.dashboard-kpi-label-lime {
    color: var(--edm-accent);
}

.dashboard-kpi-value-row {
    display: flex;
    align-items: baseline;
    gap: 6px;
}

.dashboard-kpi-value {
    white-space: nowrap;
}

.dashboard-kpi-unit,
.dashboard-kpi-detail {
    color: var(--text-color-secondary);
}

.dashboard-kpi-detail {
    margin-top: 8px;
}

@media (min-width: 1201px) {
    .dashboard-shell.dashboard-view-overview {
        height: 100%;
        display: grid;
        grid-template-columns: minmax(680px, 2fr) minmax(360px, 1fr);
        grid-template-rows: auto auto 340px minmax(240px, 1fr);
        gap: var(--card-gap);
        align-items: stretch;
    }

    .dashboard-view-overview > .dashboard-context-bar {
        grid-column: 1 / -1;
        grid-row: 1;
        margin-bottom: 0;
    }

    .dashboard-view-overview > .dashboard-top-grid,
    .dashboard-view-overview .dashboard-overview-column,
    .dashboard-view-overview > .dashboard-pages-shell {
        display: contents;
    }

    .dashboard-view-overview #dashboard-page-overview {
        display: contents !important;
    }

    .dashboard-view-overview .dashboard-overview-column > .overview-summary-card {
        grid-column: 1;
        grid-row: 2;
    }

    .dashboard-view-overview .dashboard-expanded-layout,
    .dashboard-view-overview #dashboard-page-overview > .overview-agent-grid {
        min-height: 0;
        grid-column: 1;
        grid-row: 3;
    }

    .dashboard-view-overview .dashboard-controls-card {
        min-height: 0;
        grid-column: 2;
        grid-row: 2;
        align-self: start;
        height: auto;
    }

    .dashboard-view-overview.select-data-expanded .dashboard-controls-card {
        grid-row: 2 / 4;
        align-self: stretch;
        height: 100%;
    }

    .dashboard-view-overview .overview-agent-grid > .agent-card,
    .dashboard-view-overview .dashboard-expanded-overview > .agent-card {
        height: 100%;
    }

    .dashboard-view-overview .dashboard-kpi-card {
        grid-column: 1;
        grid-row: 4;
    }

    .dashboard-view-overview .dashboard-chat-card {
        width: 100%;
        height: 100%;
        grid-column: 2;
        grid-row: 3 / 5;
    }

    .dashboard-view-overview.select-data-expanded .dashboard-chat-card {
        grid-row: 4;
    }

    .dashboard-view-overview .dashboard-chat-history {
        flex: 1 1 auto;
    }
}

.dashboard-shell:not(.select-data-expanded) #dashboard-page-overview > .overview-agent-grid > .agent-card {
    overflow: hidden;
    background: var(--card-bg-agent);
    box-shadow: var(--card-shadow);
}

.dashboard-shell:not(.select-data-expanded) #dashboard-page-overview > .overview-agent-grid > .agent-card-lime {
    border-left: 6px solid var(--edm-accent);
}

.dashboard-shell:not(.select-data-expanded) #dashboard-page-overview > .overview-agent-grid > .agent-card-blue {
    border-left: 6px solid var(--edm-accent-blue);
}

.dashboard-shell:not(.select-data-expanded) #dashboard-page-overview > .overview-agent-grid > .agent-card-yellow {
    border-left: 6px solid var(--edm-accent-yellow);
}

.dashboard-shell:not(.select-data-expanded) #dashboard-page-overview > .overview-agent-grid > .agent-card-lime .dashboard-icon-badge {
    background: var(--edm-background-accent) !important;
}

.dashboard-shell:not(.select-data-expanded) #dashboard-page-overview > .overview-agent-grid > .agent-card-blue .dashboard-icon-badge {
    background: var(--edm-background-accent-blue) !important;
}

.dashboard-shell:not(.select-data-expanded) #dashboard-page-overview > .overview-agent-grid > .agent-card-yellow .dashboard-icon-badge {
    background: var(--edm-background-accent-yellow) !important;
}

.dashboard-shell:not(.select-data-expanded) #dashboard-page-overview > .overview-agent-grid > .agent-card-lime .agent-pill {
    background: var(--edm-background-accent) !important;
}

.dashboard-shell:not(.select-data-expanded) #dashboard-page-overview > .overview-agent-grid > .agent-card-blue .agent-pill {
    background: var(--edm-background-accent-blue) !important;
}

.dashboard-shell:not(.select-data-expanded) #dashboard-page-overview > .overview-agent-grid > .agent-card-yellow .agent-pill {
    background: var(--edm-background-accent-yellow) !important;
}

/* Dashboard overview always keeps the same full agent-card presentation. */
.dashboard-view-overview #dashboard-page-overview > .overview-agent-grid > .agent-card {
    overflow: hidden;
    background: var(--card-bg-agent);
    box-shadow: var(--card-shadow);
}

.dashboard-view-overview #dashboard-page-overview > .overview-agent-grid > .agent-card-lime {
    border-top: 6px solid var(--edm-accent);
    border-left: 0 !important;
}

.dashboard-view-overview #dashboard-page-overview > .overview-agent-grid > .agent-card-blue {
    border-top: 6px solid var(--edm-accent-blue);
    border-left: 0 !important;
}

.dashboard-view-overview #dashboard-page-overview > .overview-agent-grid > .agent-card-yellow {
    border-top: 6px solid var(--edm-accent-yellow);
    border-left: 0 !important;
}

.dashboard-view-overview .overview-agent-grid > .agent-card-lime .dashboard-icon-badge,
.dashboard-view-overview .overview-agent-grid > .agent-card-lime .agent-pill {
    background: var(--edm-background-accent) !important;
}

.dashboard-view-overview .overview-agent-grid > .agent-card-blue .dashboard-icon-badge,
.dashboard-view-overview .overview-agent-grid > .agent-card-blue .agent-pill {
    background: var(--edm-background-accent-blue) !important;
}

.dashboard-view-overview .overview-agent-grid > .agent-card-yellow .dashboard-icon-badge,
.dashboard-view-overview .overview-agent-grid > .agent-card-yellow .agent-pill {
    background: var(--edm-background-accent-yellow) !important;
}

.dashboard-view-overview .overview-agent-grid .agent-meta-row {
    align-items: stretch;
    flex-direction: column;
    gap: 8px;
}

.dashboard-view-overview .overview-agent-grid .agent-pill {
    width: 100%;
}

.dashboard-view-overview .overview-agent-grid .battery-main-row {
    display: flex;
    align-items: stretch;
    flex-direction: column;
    gap: 24px;
}

.dashboard-shell:not(.select-data-expanded) .dashboard-page-pane .agent-context-card > .agent-card-lime,
.dashboard-shell:not(.select-data-expanded) .dashboard-page-pane .agent-context-card > .agent-card-blue,
.dashboard-shell:not(.select-data-expanded) .dashboard-page-pane .agent-context-card > .agent-card-yellow {
    overflow: hidden;
    background: var(--card-bg-agent);
    box-shadow: var(--card-shadow);
}

.dashboard-shell:not(.select-data-expanded) .dashboard-page-pane .agent-context-card > .agent-card-lime {
    border-top: 6px solid var(--edm-accent);
}

.dashboard-shell:not(.select-data-expanded) .dashboard-page-pane .agent-context-card > .agent-card-blue {
    border-top: 6px solid var(--edm-accent-blue);
}

.dashboard-shell:not(.select-data-expanded) .dashboard-page-pane .agent-context-card > .agent-card-yellow {
    border-top: 6px solid var(--edm-accent-yellow);
}

.dashboard-shell:not(.select-data-expanded) .dashboard-page-pane .agent-context-card > .agent-card-lime .dashboard-icon-badge,
.dashboard-shell:not(.select-data-expanded) .dashboard-page-pane .agent-context-card > .agent-card-lime .agent-pill {
    background: var(--edm-background-accent) !important;
}

.dashboard-shell:not(.select-data-expanded) .dashboard-page-pane .agent-context-card > .agent-card-blue .dashboard-icon-badge,
.dashboard-shell:not(.select-data-expanded) .dashboard-page-pane .agent-context-card > .agent-card-blue .agent-pill {
    background: var(--edm-background-accent-blue) !important;
}

.dashboard-shell:not(.select-data-expanded) .dashboard-page-pane .agent-context-card > .agent-card-yellow .dashboard-icon-badge,
.dashboard-shell:not(.select-data-expanded) .dashboard-page-pane .agent-context-card > .agent-card-yellow .agent-pill {
    background: var(--edm-background-accent-yellow) !important;
}

.dashboard-shell.select-data-expanded .dashboard-expanded-layout .agent-card-lime,
.dashboard-shell.select-data-expanded .dashboard-expanded-layout .agent-card-blue,
.dashboard-shell.select-data-expanded .dashboard-expanded-layout .agent-card-yellow {
    overflow: hidden;
    background: var(--card-bg-agent);
    box-shadow: var(--card-shadow);
}

.dashboard-shell.select-data-expanded .dashboard-expanded-layout .agent-card-lime {
    border-top: 6px solid var(--edm-accent);
}

.dashboard-shell.select-data-expanded .dashboard-expanded-layout .agent-card-blue {
    border-top: 6px solid var(--edm-accent-blue);
}

.dashboard-shell.select-data-expanded .dashboard-expanded-layout .agent-card-yellow {
    border-top: 6px solid var(--edm-accent-yellow);
}

.dashboard-shell.select-data-expanded .dashboard-expanded-layout .dashboard-expanded-agent-card {
    border-top: 0;
}

.dashboard-shell.select-data-expanded .dashboard-expanded-layout #dashboard-expanded-agent-cooling {
    border-left: 6px solid var(--edm-accent-blue);
}

.dashboard-shell.select-data-expanded .dashboard-expanded-layout #dashboard-expanded-agent-workload {
    border-left: 6px solid var(--edm-accent);
}

.dashboard-shell.select-data-expanded .dashboard-expanded-layout #dashboard-expanded-agent-ess {
    border-left: 6px solid var(--edm-accent-yellow);
}

.dashboard-shell.select-data-expanded .dashboard-expanded-layout .agent-card-lime .dashboard-icon-badge {
    background: var(--edm-background-accent) !important;
}

.dashboard-shell.select-data-expanded .dashboard-expanded-layout .agent-card-blue .dashboard-icon-badge {
    background: var(--edm-background-accent-blue) !important;
}

.dashboard-shell.select-data-expanded .dashboard-expanded-layout .agent-card-yellow .dashboard-icon-badge {
    background: var(--edm-background-accent-yellow) !important;
}

.dashboard-shell.select-data-expanded .dashboard-expanded-layout .agent-card-lime .agent-pill {
    background: var(--edm-background-accent) !important;
}

.dashboard-shell.select-data-expanded .dashboard-expanded-layout .agent-card-blue .agent-pill {
    background: var(--edm-background-accent-blue) !important;
}

.dashboard-shell.select-data-expanded .dashboard-expanded-layout .agent-card-yellow .agent-pill {
    background: var(--edm-background-accent-yellow) !important;
}

.overview-agent-grid .battery-main-row {
    display: block;
}

.dashboard-chat-card {
    width: 100%;
    max-height: 800px;
    padding: 0;
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

.dashboard-chat-header {
    flex: 0 0 auto;
    padding: 22px 0px 18px;
    border-bottom: 1px solid var(--edm-outline);
}

.dashboard-chat-title {
    color: var(--text-color-primary);
    font-size: 20px;
    font-weight: 600;
}

.dashboard-chat-subtitle {
    margin-top: 4px;
    color: var(--text-color-muted);
    font-size: 13px;
}

.dashboard-chat-history {
    min-height: 0;
    padding: 24px 26px;
    display: flex;
    flex: 0 1 auto;
    flex-direction: column;
    gap: 18px;
    overflow-y: auto;
}

.dashboard-chat-history:empty {
    min-height: max(360px, min(720px, calc(100vh - 180px)));
}

.dashboard-chat-message {
    width: 100%;
    display: flex;
    align-items: flex-start;
    gap: 12px;
}

.dashboard-chat-message-user {
    justify-content: flex-end;
}

.dashboard-chat-agent-icon {
    width: 36px;
    height: 36px;
    display: inline-flex;
    flex: 0 0 36px;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    background: var(--color-accent-blue);
}

.dashboard-chat-agent-icon img {
    width: 20px;
    height: 20px;
}

.dashboard-chat-bubble {
    max-width: min(74%, 720px);
    padding: 12px 16px;
    border-radius: 16px;
    color: var(--text-color-primary);
    font-size: 14px;
    line-height: 1.55;
    overflow-wrap: anywhere;
}

.dashboard-chat-bubble-agent {
    border-top-left-radius: 5px;
    background: var(--edm-background-accent-blue);
}

.dashboard-chat-bubble-agent-alert {
    border-top-left-radius: 5px;
    background: var(--edm-alert-background);
}

.dashboard-chat-bubble-user {
    border-top-right-radius: 5px;
    background: var(--edm-background-btn-hover);
}

.dashboard-chat-composer {
    position: fixed;
    z-index: 1025;
    left: 280px;
    right: 16px;
    bottom: 16px;
    padding: 0;
    display: block;
    border: 0;
    background: transparent;
}

.dashboard-chat-input {
    width: 100%;
    box-sizing: border-box;
    display: block;
    min-height: 48px;
    max-height: 128px;
    padding: 12px 62px 12px 14px;
    resize: vertical;
    border: 1px solid var(--edm-outline);
    border-radius: 16px;
    outline: none;
    color: var(--text-color-primary);
    background: var(--card-bg-agent);
    box-shadow:
        0 2px 8px rgba(35, 60, 90, 0.08),
        0 10px 28px rgba(35, 60, 90, 0.18),
        0 24px 52px rgba(35, 60, 90, 0.12);
    font-family: "Inter", sans-serif;
    font-size: 14px;
    line-height: 1.45;
}

.dashboard-chat-input:focus {
    border-color: var(--edm-accent);
    box-shadow:
        0 0 0 3px rgba(137, 177, 87, 0.16),
        0 10px 28px rgba(35, 60, 90, 0.2),
        0 24px 52px rgba(35, 60, 90, 0.14);
}

.dashboard-chat-send {
    position: absolute;
    top: 50%;
    right: 8px;
    width: 36px;
    min-width: 36px;
    height: 36px;
    padding: 8px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    transform: translateY(-50%);
    border: 0;
    border-radius: 50%;
    color: var(--edm-accent);
    background: var(--edm-background-accent);
}

.dashboard-chat-send-icon {
    width: 20px;
    height: 20px;
    display: block;
    background: var(--edm-accent-dark);
    -webkit-mask: url("/assets/icons/send.svg") center / contain no-repeat;
    mask: url("/assets/icons/send.svg") center / contain no-repeat;
}

.dashboard-chat-send:hover,
.dashboard-chat-send:focus,
.dashboard-chat-send:active {
    color: var(--text-color-primary) !important;
    background: var(--edm-accent) !important;
    box-shadow: none !important;
}

.dashboard-chat-send:hover .dashboard-chat-send-icon,
.dashboard-chat-send:focus .dashboard-chat-send-icon,
.dashboard-chat-send:active .dashboard-chat-send-icon {
    background: #FFFFFF;
}

.dashboard-chat-send:active {
    transform: translateY(-50%) scale(0.96);
}

.agent-card {
    background: var(--card-bg-agent);
    border: 0;
    border-radius: var(--card-radius);
    box-shadow: var(--card-shadow);
    padding: var(--card-padding);
    min-width: 0;
}

.agent-card-lime {
    background: var(--color-accent-lime);
    --agent-icon-color: var(--edm-accent-dark);
    --agent-icon-mask: url("/assets/icons/task.svg");
}

.agent-card-blue {
    background: var(--color-accent-blue);
    --agent-icon-color: var(--edm-accent-blue-dark);
    --agent-icon-mask: url("/assets/icons/thermometer.svg");
}

.agent-card-yellow {
    background: var(--color-accent-yellow);
    --agent-icon-color: var(--edm-accent-yellow-dark);
    --agent-icon-mask: url("/assets/icons/battery.svg");
}

.agent-card-lime .dashboard-icon-badge,
.agent-card-blue .dashboard-icon-badge,
.agent-card-yellow .dashboard-icon-badge {
    position: relative;
}

.agent-card-lime .dashboard-icon-badge .overview-metric-icon,
.agent-card-blue .dashboard-icon-badge .overview-metric-icon,
.agent-card-yellow .dashboard-icon-badge .overview-metric-icon {
    opacity: 0;
}

.agent-card-lime .dashboard-icon-badge::after,
.agent-card-blue .dashboard-icon-badge::after,
.agent-card-yellow .dashboard-icon-badge::after {
    position: absolute;
    width: 30px;
    height: 30px;
    background: var(--agent-icon-color);
    content: "";
    -webkit-mask-image: var(--agent-icon-mask);
    mask-image: var(--agent-icon-mask);
    -webkit-mask-position: center;
    mask-position: center;
    -webkit-mask-repeat: no-repeat;
    mask-repeat: no-repeat;
    -webkit-mask-size: contain;
    mask-size: contain;
}

.agent-card-title {
    color: var(--text-color-primary);
    font-size: var(--font-size-card-title);
    font-weight: 500;
    line-height: 1.12;
    margin-bottom: 28px;
}

.agent-card-header {
    display: grid;
    grid-template-columns: 58px minmax(0, 1fr);
    gap: 18px;
    align-items: center;
    margin-bottom: 28px;
}

.agent-card-header .agent-card-title {
    margin-bottom: 0;
}

.agent-card-content {
    display: flex;
    flex-direction: column;
    gap: 24px;
}

.agent-metric-row {
    display: flex;
    align-items: baseline;
    gap: 10px;
}

.agent-metric-value {
    color: var(--text-color-primary);
    /* font-size: var(--font-size-metric-large); */
    font-size: var(--font-size-card-value);
    font-weight: 500;
    line-height: 0.95;
}

.agent-metric-unit {
    color: var(--text-color-primary);
    font-size: 26px;
    font-weight: 450;
}

.agent-meta-stack {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.agent-meta-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
}

.agent-meta-label {
    color: var(--text-color-secondary);
    font-size: 16px;
}

.agent-meta-value {
    color: var(--text-color-primary);
    font-size: 18px;
    font-weight: 500;
}

.agent-pill {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: var(--card-radius-pill);
    background: rgba(255, 255, 255, 0.72);
    color: var(--text-color-primary);
    font-size: 18px;
    font-weight: 450;
    padding: 9px 18px;
    line-height: 1;
    white-space: nowrap;

    width: 160px;
    box-sizing: border-box;
}

.battery-main-row {
    display: grid;
    align-items: center;
    grid-template-columns: 3.5fr 6.5fr;
    justify-content: space-between;
    gap: 16px;
}

.battery-main-row .agent-meta-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: 100%;
    min-width: 0;
    gap: 8px;
}

.battery-main-row .agent-meta-label {
    text-align: left;
    white-space: nowrap;
}

.battery-main-row .agent-pill {
    margin-left: auto;
    white-space: nowrap;
}

.battery-flow {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    min-height: 68px;
}

.battery-flow-icon {
    width: 48px;
    height: 48px;
    object-fit: contain;
}

.battery-ess-icon {
    width: 52px;
    height: 52px;
}

.battery-flow-line {
    margin-top: 0 !important;
}

.graph-card {
    padding: 24px 28px 18px;
}

.graph-card .agent-card-title {
    margin-bottom: 8px;
}

.agent-graph {
    width: 100%;
}

.agent-page-grid {
    display: grid;
    grid-template-columns: minmax(310px, 0.36fr) minmax(0, 1fr);
    gap: var(--card-gap);
    align-items: stretch;
}

.dashboard-shell:not(.select-data-expanded) #dashboard-page-agent-workload .agent-context-card > .agent-card,
.dashboard-shell:not(.select-data-expanded) #dashboard-page-agent-ess .agent-context-card > .agent-card {
    display: flex;
    flex-direction: column;
}

.dashboard-shell:not(.select-data-expanded) #dashboard-page-agent-workload .agent-card-content,
.dashboard-shell:not(.select-data-expanded) #dashboard-page-agent-ess .agent-card-content {
    min-height: 0;
    flex: 1;
    justify-content: space-between;
}

.dashboard-shell:not(.select-data-expanded) #dashboard-page-agent-workload .agent-meta-stack {
    gap: 18px;
}

.dashboard-shell:not(.select-data-expanded) #dashboard-page-agent-workload .agent-meta-row,
.dashboard-shell:not(.select-data-expanded) #dashboard-page-agent-ess .battery-main-row .agent-meta-row {
    flex-direction: column;
    align-items: stretch;
    gap: 8px;
}

.dashboard-shell:not(.select-data-expanded) #dashboard-page-agent-workload .agent-pill,
.dashboard-shell:not(.select-data-expanded) #dashboard-page-agent-ess .battery-main-row .agent-pill {
    width: 100%;
    margin-left: 0;
}

.dashboard-shell:not(.select-data-expanded) #dashboard-page-agent-ess .battery-main-row {
    grid-template-columns: 1fr;
    align-items: stretch;
    gap: 24px;
}

.cooling-agent-primary {
    grid-template-columns: minmax(310px, 1fr) minmax(0, 2fr);
    align-items: stretch;
}

.cooling-agent-primary > .graph-card,
.cooling-agent-primary > .agent-context-card {
    height: 100%;
}

.chiller-metrics-card {
    width: 100%;
}

.chiller-metrics-title {
    margin-bottom: 24px;
}

.chiller-metrics-card .chiller-kpi-grid {
    gap: 0;
    margin-bottom: 24px;
    padding-bottom: 24px;
    border-bottom: 1px solid var(--edm-outline);
}

.cooling-metric-item {
    min-width: 0;
    padding: 0 20px;
}

/* .cooling-metric-item:not(:last-child) {
    border-right: 1px solid var(--edm-outline);
} */

.cooling-metric-item:first-child {
    padding-left: 0;
}

.cooling-metric-item:last-child {
    padding-right: 0;
}

.cooling-metric-label {
    min-height: 20px;
    margin-bottom: 8px;
    color: var(--text-color-secondary);
    font-size: 16px;
    line-height: 1.3;
}

.chiller-metrics-card .chiller-kpi-grid .agent-metric-value {
    font-size: 32px;
}

.cooling-metric-item .agent-metric-value > *,
.chiller-compact-value > * {
    color: inherit !important;
    font: inherit !important;
    line-height: inherit !important;
}

.cooling-page-stack {
    gap: var(--card-gap);
}

.cooling-chiller-section {
    padding-top: 0;
}

.agent-context-card > .agent-card {
    height: 100%;
}

.chiller-kpi-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: var(--card-gap);
}

.chiller-kpi-grid .agent-metric-value {
    font-size: var(--font-size-metric-medium);
}

.chiller-two-column {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 40px;
}

.chiller-metrics-section {
    min-width: 0;
}

.chiller-metrics-section-title {
    margin-bottom: 12px;
    color: var(--text-color-secondary);
    font-size: 15px;
    font-weight: 500;
}

.chiller-compact-stack {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.chiller-compact-row {
    min-width: 0;
    min-height: 48px;
    display: grid;
    grid-template-columns: minmax(76px, 110px) 48px minmax(80px, 1fr);
    gap: 12px;
    align-items: center;
}

.chiller-compact-label {
    color: var(--text-color-secondary);
    font-size: 14px;
}

.chiller-compact-value {
    color: var(--text-color-primary);
    font-size: 18px;
    font-weight: 500;
}

.chiller-compact-bar {
    width: 100%;
    min-width: 0;
}

.chiller-safe-row {
    grid-template-columns: minmax(76px, 110px) 48px;
}

.chiller-heat-layout {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 132px;
    gap: 20px;
    align-items: center;
}

.chiller-compact-gauge {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
}

.overview-time-card {
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.toast {
    color: var(--edm-alert);
    position: fixed;
    bottom: 20px;
    left: 50%;
    width: auto;
    z-index: 9999;
    font-size: 16px;
    text-align: center;
    transform: translateX(-50%);
    background-color: var(--edm-alert-background);
    border-radius: var(--card-radius-pill);
    border: 0;
    padding: 2px;
}

.toast .toast-body {
    padding: 6px 12px;
}

.sidebar-dashboard-toggle {
    width: 100%;
    border: 0;
    background: transparent;
    color: var(--edm-text-body);
    border-radius: 10px;
    padding: 8px 12px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    font-size: 15px;
    text-align: left;
}

.sidebar-dashboard-toggle:hover,
.sidebar-dashboard-toggle:focus {
    background: var(--edm-background-btn-hover);
    color: var(--edm-text-body);
    box-shadow: none;
}

.sidebar-toggle-content {
    display: flex;
    align-items: center;
    gap: 10px;
}

.sidebar-caret {
    transition: transform 0.2s ease;
}

.sidebar-caret.open {
    transform: rotate(180deg);
}

.nav-submenu {
    display: flex;
    flex-direction: column;
    gap: 6px;
    padding: 6px 0 6px 18px;
}

.nav-submenu-deep {
    padding-left: 24px;
}

.nav-sub-link {
    display: flex;
    align-items: center;
    border-radius: 10px;
    color: var(--edm-text-subtitle);
    font-size: 14px;
    padding: 8px 12px;
}

.nav-sub-link:hover {
    background: var(--edm-background-btn-hover);
    color: var(--edm-text-body);
}

.nav-sub-link.active {
    background: var(--edm-background-accent) !important;
    color: var(--text-color-primary) !important;
    font-weight: 500;
}

.nav-sub-link-level-3 {
    font-size: 13px;
    padding-left: 16px;
}

@media (max-width: 1200px) {
    .dashboard-top-grid {
        grid-template-columns: 1fr;
    }

    .dashboard-filter-grid,
    .overview-agent-grid,
    .chiller-kpi-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .overview-summary-card {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .agent-page-grid,
    .chiller-two-column {
        grid-template-columns: 1fr;
    }

    .dashboard-expanded-overview {
        grid-template-columns: repeat(3, minmax(180px, 1fr));
        overflow-x: auto;
    }
}

@media (max-width: 768px) {
    .dashboard-shell {
        padding: 16px;
    }

    .dashboard-context-bar {
        gap: 12px;
    }

    .dashboard-context-title {
        font-size: 22px;
    }

    .dashboard-expanded-overview {
        grid-template-columns: 1fr;
        overflow: visible;
    }

    .expanded-overview-card,
    .dashboard-expanded-agent-card {
        min-height: 190px;
    }

    .expanded-agent-data-row {
        gap: 18px;
    }

    .expanded-agent-action-block {
        padding-left: 18px;
    }

    .expanded-agent-value {
        font-size: 38px;
    }

    .dashboard-account-label {
        font-size: 12px;
    }

    .dashboard-account-value {
        max-width: 130px;
        font-size: 13px;
    }

    .dashboard-chat-header,
    .dashboard-chat-history {
        padding-left: 18px;
        padding-right: 18px;
    }

    .dashboard-chat-bubble {
        max-width: 86%;
    }

    .dashboard-chat-composer {
        left: 16px;
        right: 16px;
        bottom: 16px;
        opacity: 0;
        visibility: hidden;
        pointer-events: none;
        transform: translateY(18px);
        transition: opacity 0.2s ease, transform 0.2s ease, visibility 0.2s;
    }

    .dashboard-chat-composer.dashboard-chat-composer-mobile-visible {
        opacity: 1;
        visibility: visible;
        pointer-events: auto;
        transform: translateY(0);
    }

    .dashboard-chat-send {
        right: 8px;
        width: 36px;
        min-width: 36px;
    }

    .dashboard-controls-heading {
        align-items: stretch;
        flex-direction: column;
    }

    .dashboard-current-time-control {
        align-items: flex-start;
        min-width: 0;
    }

    .dashboard-time-text {
        font-size: 40px;
    }

    .dashboard-filter-grid,
    .overview-summary-grid,
    .overview-agent-grid,
    .dashboard-kpi-grid,
    .chiller-kpi-grid,
    .chiller-control-grid {
        grid-template-columns: 1fr;
    }

    .dashboard-kpi-item,
    .dashboard-kpi-item:first-child,
    .dashboard-kpi-item:last-child {
        padding: 20px 0;
    }

    .dashboard-kpi-item + .dashboard-kpi-item {
        border-top: 1px solid var(--edm-outline);
        border-left: 0;
    }

    .overview-summary-card {
        grid-template-columns: 1fr;
    }

    .agent-card-title {
        font-size: 24px;
    }

    .agent-metric-value {
        font-size: 44px;
    }
}
