.ad-shell {
    width: min(100% - 1rem, 1600px);
    margin-right: auto;
    margin-left: auto;
    padding: 1rem 0 2.5rem;
    color: #07192f;
}

.ad-hero {
    display: grid;
    grid-template-columns: minmax(0, 1.35fr) minmax(18rem, 0.65fr);
    border: 1px solid #d7e2ed;
    background: #f8fbfd;
    margin-bottom: 0.9rem;
}

.ad-hero-main {
    padding: 1.05rem 1.2rem;
}

.ad-kicker,
.ad-label,
.ad-table th,
.ad-mini-label {
    color: #5b6d81;
    font-size: 0.73rem;
    font-weight: 850;
    letter-spacing: 0.11em;
    text-transform: uppercase;
}

.ad-hero h1 {
    margin: 0.1rem 0 0.35rem;
    font-size: clamp(2.1rem, 4.4vw, 4.4rem);
    line-height: 0.95;
    letter-spacing: 0;
}

.ad-hero p {
    max-width: 64rem;
    margin: 0;
    color: #3e5268;
    font-weight: 700;
    overflow-wrap: anywhere;
}

.ad-hero-side {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    border-left: 1px solid #d7e2ed;
    background: #ffffff;
}

.ad-hero-side > div {
    min-width: 0;
    padding: 0.8rem;
    border-right: 1px solid #d7e2ed;
    border-bottom: 1px solid #d7e2ed;
}

.ad-hero-side > div:nth-child(2n) {
    border-right: 0;
}

.ad-hero-side strong,
.ad-stat strong {
    display: block;
    color: #07192f;
    font-size: 1.55rem;
    line-height: 1.05;
}

.ad-actions,
.ad-exchange-tabs {
    display: flex;
    flex-wrap: wrap;
    gap: 0.45rem;
    margin: 0 0 0.9rem;
}

.ad-button,
.ad-exchange-tabs a {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 2.3rem;
    padding: 0.48rem 0.7rem;
    border: 1px solid #bfd0e0;
    background: #ffffff;
    color: #003366;
    font-weight: 850;
    text-decoration: none;
    text-align: center;
}

.ad-button.is-primary,
.ad-exchange-tabs a[aria-current="page"] {
    color: #ffffff;
    background: #003366;
    border-color: #003366;
}

.ad-regime {
    display: inline-flex;
    align-items: center;
    width: fit-content;
    min-height: 2rem;
    padding: 0.4rem 0.55rem;
    border: 1px solid #d5dfeb;
    background: #ffffff;
    color: #23384f;
    font-weight: 850;
}

.ad-regime.is-positive {
    color: #0f6b3b;
    border-color: #b8dbc8;
    background: #f2fbf5;
}

.ad-regime.is-warning {
    color: #9a5b00;
    border-color: #f1d094;
    background: #fff8eb;
}

.ad-regime.is-danger,
.ad-regime.is-negative {
    color: #a32020;
    border-color: #efb4b4;
    background: #fff3f3;
}

.ad-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 0.65rem;
    margin-bottom: 0.9rem;
}

.ad-stat,
.ad-panel,
.ad-card,
.ad-chart-panel {
    border: 1px solid #d7e2ed;
    background: #ffffff;
}

.ad-stat {
    min-width: 0;
    padding: 0.75rem 0.85rem;
    border-left-width: 4px;
    border-left-color: #8aa0b6;
}

.ad-stat span {
    display: block;
    color: #5b6d81;
    font-size: 0.78rem;
    font-weight: 800;
}

.ad-stat small {
    color: #60748a;
    font-weight: 750;
}

.ad-stat.is-positive {
    border-left-color: #16834f;
    background: linear-gradient(90deg, #f0fbf4 0%, #ffffff 56%);
}

.ad-stat.is-warning {
    border-left-color: #d97706;
    background: linear-gradient(90deg, #fff8eb 0%, #ffffff 56%);
}

.ad-stat.is-danger,
.ad-stat.is-negative {
    border-left-color: #dc2626;
    background: linear-gradient(90deg, #fff2f2 0%, #ffffff 56%);
}

.ad-score-guide {
    display: grid;
    grid-template-columns: minmax(16rem, 1.5fr) repeat(4, minmax(8rem, 1fr));
    gap: 0.55rem;
    align-items: stretch;
    margin: -0.15rem 0 0.9rem;
}

.ad-score-guide > div,
.ad-score-band {
    min-width: 0;
    border: 1px solid #d7e2ed;
    background: #ffffff;
    padding: 0.6rem 0.7rem;
}

.ad-score-guide strong,
.ad-score-band strong,
.ad-score-band span {
    display: block;
}

.ad-score-guide strong {
    color: #07192f;
    font-size: 0.9rem;
}

.ad-score-band span {
    color: #5b6d81;
    font-size: 0.72rem;
    font-weight: 900;
    letter-spacing: 0.09em;
    text-transform: uppercase;
}

.ad-score-band strong {
    margin-top: 0.18rem;
    font-size: 0.84rem;
}

.ad-score-band.is-positive {
    border-color: #b8dbc8;
    background: #f2fbf5;
    color: #0f6b3b;
}

.ad-score-band.is-warning,
.ad-score-band.is-inverse {
    border-color: #f1d094;
    background: #fff8eb;
    color: #925400;
}

.ad-score-band.is-danger {
    border-color: #efb4b4;
    background: #fff3f3;
    color: #a32020;
}

.ad-main-grid {
    display: grid;
    grid-template-columns: minmax(0, 1.45fr) minmax(20rem, 0.55fr);
    gap: 0.85rem;
    align-items: start;
    margin-bottom: 0.9rem;
}

.ad-chart-panel {
    min-width: 0;
    padding: 0.8rem;
}

.ad-panel {
    min-width: 0;
    padding: 0.85rem;
    margin-bottom: 0.9rem;
}

.ad-panel-head {
    display: flex;
    justify-content: space-between;
    gap: 1rem;
    align-items: start;
    margin-bottom: 0.7rem;
}

.ad-panel h2,
.ad-chart-panel h2,
.ad-card h2 {
    margin: 0;
    font-size: 1.35rem;
}

.ad-verdict {
    margin: 0.5rem 0 0;
    color: #273c53;
    font-size: 1rem;
    font-weight: 720;
    line-height: 1.45;
}

.ad-chart {
    width: 100%;
    min-height: 400px;
}

.ad-chart.is-small {
    min-height: 310px;
}

.ad-chart.is-compact {
    min-height: 0;
}

.ad-chart svg {
    display: block;
    width: 100%;
    height: auto;
    min-height: inherit;
}

.ad-chart-gridline {
    stroke: #dce5ef;
    stroke-width: 1;
}

.ad-chart-axis {
    stroke: #9fb0c2;
    stroke-width: 1;
}

.ad-chart-zero {
    stroke: #a8b5c4;
    stroke-width: 1;
    stroke-dasharray: 6 5;
}

.ad-chart-line {
    fill: none;
    stroke-width: 2.2;
}

.ad-chart-line.is-adLine {
    stroke: #07192f;
}

.ad-chart-line.is-adLineEma30 {
    stroke: #108047;
    stroke-width: 2;
}

.ad-chart-line.is-quality,
.ad-chart-line.is-fair,
.ad-chart-line.is-trend {
    stroke: #108047;
}

.ad-chart-line.is-pressure {
    stroke: #c2410c;
}

.ad-chart-line.is-md,
.ad-chart-line.is-advance {
    stroke: #0b63ce;
}

.ad-chart-line.is-earningsValuationProxy {
    stroke: #7c3aed;
}

.ad-chart-line.is-earningsValuationTrend {
    stroke: #108047;
}

.ad-chart-area {
    fill: rgba(15, 107, 59, 0.08);
}

.ad-chart-legend {
    display: flex;
    flex-wrap: wrap;
    gap: 0.45rem;
    margin: 0.55rem 0 0.2rem;
}

.ad-chart-legend-item {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    min-height: 1.85rem;
    padding: 0.25rem 0.45rem;
    border: 1px solid #d7e2ed;
    background: #f8fbfd;
    color: #23384f;
    font-size: 0.78rem;
    font-weight: 800;
    min-width: 0;
}

.ad-chart-legend-item i {
    width: 0.85rem;
    height: 0.18rem;
}

.ad-chart-legend-item em {
    color: #07192f;
    font-style: normal;
    font-weight: 900;
}

.ad-bar-chart {
    display: grid;
    gap: 0.7rem;
    margin-top: 0.8rem;
}

.ad-bar-row {
    border: 1px solid #d7e2ed;
    background: #f8fbfd;
    padding: 0.65rem;
}

.ad-bar-row.is-positive {
    border-color: #b8dbc8;
    background: #f2fbf5;
}

.ad-bar-row.is-warning {
    border-color: #f1d094;
    background: #fff8eb;
}

.ad-bar-row.is-danger {
    border-color: #efb4b4;
    background: #fff3f3;
}

.ad-bar-head {
    display: flex;
    justify-content: space-between;
    gap: 0.75rem;
    align-items: center;
}

.ad-bar-head strong,
.ad-bar-head span {
    color: #07192f;
    font-size: 0.9rem;
    font-weight: 950;
}

.ad-bar-head strong {
    display: inline-flex;
    align-items: center;
    gap: 0.42rem;
    min-width: 0;
}

.ad-bar-head i {
    flex: 0 0 auto;
    width: 0.9rem;
    height: 0.22rem;
}

.ad-bar-track {
    position: relative;
    height: 0.72rem;
    margin: 0.5rem 0 0.35rem;
    overflow: hidden;
    border: 1px solid #d7e2ed;
    background: #ffffff;
}

.ad-bar-track > span:not(.ad-bar-threshold) {
    display: block;
    height: 100%;
    min-width: 2px;
}

.ad-bar-threshold {
    position: absolute;
    top: -0.25rem;
    bottom: -0.25rem;
    width: 2px;
    z-index: 1;
    background: #07192f;
    opacity: 0.45;
}

.ad-bar-row small,
.ad-bar-note {
    color: #60748a;
    font-size: 0.78rem;
    font-weight: 760;
}

.ad-bar-note {
    margin: 0.15rem 0 0;
}

.ad-valuation-read {
    display: grid;
    grid-template-columns: minmax(12rem, 0.8fr) minmax(0, 1.2fr);
    gap: 0.75rem;
    align-items: center;
    margin: 0.8rem 0 0.65rem;
    border: 1px solid #d7e2ed;
    border-left: 4px solid #8aa0b6;
    background: #f8fbfd;
    padding: 0.7rem;
}

.ad-valuation-read.is-positive {
    border-left-color: #16834f;
    background: #f2fbf5;
}

.ad-valuation-read.is-warning {
    border-left-color: #d97706;
    background: #fff8eb;
}

.ad-valuation-read strong {
    display: block;
    color: #07192f;
    font-size: 1.15rem;
}

.ad-valuation-read p {
    margin: 0;
    color: #3e5268;
    font-weight: 760;
    line-height: 1.4;
}

.ad-valuation-facts {
    grid-column: 1 / -1;
    display: flex;
    flex-wrap: wrap;
    gap: 0.45rem;
}

.ad-valuation-facts span {
    display: inline-flex;
    min-height: 1.8rem;
    align-items: center;
    border: 1px solid #d7e2ed;
    background: #ffffff;
    padding: 0.25rem 0.45rem;
    color: #23384f;
    font-size: 0.78rem;
    font-weight: 850;
}

.ad-valuation-observations {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(9.5rem, 1fr));
    gap: 0.55rem;
    margin: 0.7rem 0 0.45rem;
}

.ad-valuation-observation {
    border: 1px solid #d7e2ed;
    background: #ffffff;
    padding: 0.65rem;
}

.ad-valuation-observation span,
.ad-valuation-observation strong,
.ad-valuation-observation small {
    display: block;
}

.ad-valuation-observation span {
    color: #5b6d81;
    font-size: 0.72rem;
    font-weight: 900;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.ad-valuation-observation strong {
    margin-top: 0.2rem;
    color: #07192f;
    font-size: 1.25rem;
}

.ad-valuation-observation small {
    margin-top: 0.15rem;
    color: #60748a;
    font-weight: 760;
}

.ad-mini-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0.55rem;
}

.ad-mini-grid-4 {
    grid-template-columns: repeat(4, minmax(0, 1fr));
    margin-bottom: 0.65rem;
}

.ad-mini {
    border: 1px solid #d7e2ed;
    background: #f8fbfd;
    padding: 0.65rem;
}

.ad-mini strong {
    display: block;
    margin-top: 0.2rem;
    font-size: 1.25rem;
}

.ad-stack {
    display: grid;
    gap: 0.65rem;
}

.ad-alert {
    border: 1px solid #d7e2ed;
    border-left: 4px solid #8aa0b6;
    padding: 0.65rem;
    background: #fbfdff;
}

.ad-alert.is-positive {
    border-left-color: #16834f;
}

.ad-alert.is-warning {
    border-left-color: #d97706;
}

.ad-alert.is-danger {
    border-left-color: #dc2626;
}

.ad-alert strong,
.ad-alert span {
    display: block;
}

.ad-alert span {
    margin-top: 0.2rem;
    color: #536a82;
    font-weight: 700;
}

.ad-two-col {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0.85rem;
}

.ad-chart-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0.85rem;
    margin-bottom: 0.9rem;
}

.ad-section-note {
    margin: 0.35rem 0 0;
    color: #60748a;
    font-size: 0.85rem;
    font-weight: 720;
}

.ad-help-button {
    display: inline-flex;
    width: 1.65rem;
    height: 1.65rem;
    align-items: center;
    justify-content: center;
    border: 1px solid #bfd0e0;
    background: #ffffff;
    color: #003366;
    font: inherit;
    font-size: 0.82rem;
    font-weight: 950;
    cursor: pointer;
}

.ad-help-button:hover,
.ad-help-button:focus {
    border-color: #003366;
    background: #f4f9fd;
}

.ad-title-row {
    display: flex;
    align-items: center;
    gap: 0.45rem;
}

.ad-modal {
    position: fixed;
    inset: 0;
    z-index: 90;
    display: grid;
    place-items: center;
    padding: 1rem;
    background: rgb(6 20 33 / 0.45);
}

.ad-modal[hidden] {
    display: none;
}

.ad-modal-panel {
    width: min(100%, 42rem);
    max-height: min(88vh, 44rem);
    overflow: auto;
    border: 1px solid #c3d1df;
    background: #ffffff;
    box-shadow: 0 20px 60px rgb(6 20 33 / 0.22);
}

.ad-modal-head {
    display: flex;
    justify-content: space-between;
    gap: 1rem;
    align-items: start;
    padding: 1rem;
    border-bottom: 1px solid #d7e2ed;
}

.ad-modal-head h2 {
    margin: 0;
    font-size: 1.35rem;
}

.ad-modal-body {
    padding: 1rem;
    color: #31475e;
    font-weight: 720;
    line-height: 1.5;
}

.ad-modal-body ul {
    margin: 0.75rem 0 0;
    padding-left: 1.1rem;
}

.ad-modal-close {
    width: 2rem;
    height: 2rem;
    border: 1px solid #bfd0e0;
    background: #ffffff;
    color: #003366;
    font-size: 1.2rem;
    font-weight: 900;
    cursor: pointer;
}

.ad-heatmap {
    display: grid;
    gap: 0.45rem;
}

.ad-heat-row {
    display: grid;
    grid-template-columns: minmax(9rem, 1.1fr) repeat(5, minmax(4rem, 0.55fr));
    gap: 0.25rem;
    align-items: stretch;
}

.ad-heat-cell {
    min-width: 0;
    padding: 0.45rem 0.5rem;
    background: #f5f8fb;
    color: #183149;
    font-size: 0.78rem;
    font-weight: 820;
}

.ad-heat-cell strong,
.ad-heat-cell span {
    display: block;
    overflow-wrap: anywhere;
}

.ad-heat-cell a {
    display: block;
    color: #003366;
    font-weight: 900;
    text-decoration-thickness: 1px;
    text-underline-offset: 0.16rem;
}

.ad-heat-cell.is-positive {
    background: #ecf8f0;
    color: #0f6b3b;
}

.ad-heat-cell.is-negative {
    background: #fff0f0;
    color: #a32020;
}

.ad-heat-cell.is-warning {
    background: #fff7e8;
    color: #925400;
}

.ad-heat-cell,
.ad-table th,
.ad-table td {
    overflow-wrap: anywhere;
}

.ad-table-wrap {
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
}

.ad-table {
    width: 100%;
    min-width: 680px;
    border-collapse: collapse;
}

.ad-table th,
.ad-table td {
    padding: 0.55rem 0.6rem;
    border-bottom: 1px solid #d7e2ed;
    text-align: left;
}

.ad-table td {
    color: #183149;
    font-weight: 750;
}

.ad-table a {
    color: #003366;
    font-weight: 850;
}

.ad-value,
.ad-score {
    display: inline-flex;
    min-width: 4.5rem;
    justify-content: flex-end;
    font-weight: 950;
}

.ad-value.is-positive,
.ad-score.is-positive {
    color: #0f6b3b;
}

.ad-value.is-negative,
.ad-score.is-negative {
    color: #a32020;
}

.ad-table tr.is-positive td:first-child {
    border-left: 3px solid #16834f;
}

.ad-table tr.is-negative td:first-child {
    border-left: 3px solid #dc2626;
}

.ad-muted {
    color: #60748a;
    font-weight: 700;
}

.ad-empty {
    display: grid;
    min-height: 18rem;
    place-items: center;
    border: 1px dashed #c7d4e2;
    background: #fbfdff;
    text-align: center;
}

.ad-exchange-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 0.7rem;
}

.ad-card {
    display: grid;
    gap: 0.5rem;
    min-height: 10rem;
    padding: 0.8rem;
    color: #07192f;
    text-decoration: none;
}

.ad-card:hover,
.ad-card:focus-visible {
    border-color: #7da7d2;
}

@media (max-width: 1180px) {
    .ad-grid,
    .ad-score-guide,
    .ad-exchange-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .ad-main-grid,
    .ad-two-col,
    .ad-chart-grid,
    .ad-hero {
        grid-template-columns: 1fr;
    }

    .ad-hero-side {
        border-left: 0;
        border-top: 1px solid #d7e2ed;
    }
}

@media (max-width: 720px) {
    .ad-grid,
    .ad-exchange-grid,
    .ad-mini-grid,
    .ad-mini-grid-4,
    .ad-score-guide {
        grid-template-columns: 1fr;
    }

    .ad-shell {
        width: min(100% - 0.75rem, 1600px);
        padding-top: 0.5rem;
    }

    .ad-hero-main,
    .ad-chart-panel,
    .ad-panel {
        padding: 0.75rem;
    }

    .ad-hero h1 {
        font-size: clamp(2rem, 13vw, 3rem);
        line-height: 1;
    }

    .ad-actions,
    .ad-exchange-tabs {
        gap: 0.35rem;
    }

    .ad-button,
    .ad-exchange-tabs a {
        flex: 1 1 8.5rem;
    }

    .ad-panel-head,
    .ad-title-row,
    .ad-bar-head {
        flex-direction: column;
        align-items: flex-start;
    }

    .ad-chart {
        min-height: 320px;
    }

    .ad-chart.is-small {
        min-height: 280px;
    }

    .ad-chart-legend-item {
        flex: 1 1 11rem;
    }

    .ad-valuation-read {
        grid-template-columns: 1fr;
    }

    .ad-hero-side {
        grid-template-columns: 1fr;
    }

    .ad-hero-side > div {
        border-right: 0;
    }

    .ad-heat-row {
        grid-template-columns: 1fr 1fr;
    }

    .ad-heat-row.is-head {
        display: none;
    }
}

@media (max-width: 460px) {
    .ad-hero-main,
    .ad-chart-panel,
    .ad-panel,
    .ad-stat {
        padding: 0.65rem;
    }

    .ad-hero h1 {
        font-size: clamp(1.75rem, 12vw, 2.45rem);
    }

    .ad-hero-side strong,
    .ad-stat strong {
        font-size: 1.28rem;
    }

    .ad-heat-row {
        grid-template-columns: 1fr;
    }

    .ad-modal {
        padding: 0.5rem;
    }
}
