/* Phase 10.10 - Patient Activity Legacy Functional Parity */
body.page-visits {
    --patient1010-body: 16px;
    --patient1010-body-ar: 17px;
    --patient1010-section: clamp(24px, 2vw, 28px);
    --patient1010-card-title: 20px;
    --patient1010-kpi: clamp(36px, 3.4vw, 50px);
    --patient1010-label: 14px;
    --patient1010-radius: 22px;
}

body.page-visits .operations-hero .hero-copy > p,
body.page-visits .hero-command-card > p,
body.page-visits .patient1010-control p,
body.page-visits .patient1010-state p,
body.page-visits .patient1010-insight p,
body.page-visits .section-head p {
    font-size: var(--patient1010-body);
    line-height: 1.62;
}

html[dir="rtl"] body.page-visits .operations-hero .hero-copy > p,
html[dir="rtl"] body.page-visits .hero-command-card > p,
html[dir="rtl"] body.page-visits .patient1010-control p,
html[dir="rtl"] body.page-visits .patient1010-state p,
html[dir="rtl"] body.page-visits .patient1010-insight p,
html[dir="rtl"] body.page-visits .section-head p {
    font-size: var(--patient1010-body-ar);
    line-height: 1.72;
}

body.page-visits .patient1010-control {
    padding: 24px 26px;
    border-radius: var(--patient1010-radius);
    margin-bottom: 18px;
}

body.page-visits .patient1010-control-head {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 18px;
    margin-bottom: 20px;
}

body.page-visits .patient1010-control-head h2,
body.page-visits .patient1010-insight h2,
body.page-visits .patient1010-monthly-card .section-head h2,
body.page-visits .patient1010-table-card .section-head h2 {
    margin: 4px 0 6px;
    font-size: var(--patient1010-section);
    line-height: 1.18;
}

body.page-visits .patient1010-control-head p {
    margin: 0;
    color: #64748b;
    max-width: 760px;
}

body.page-visits .patient1010-parity-badge {
    flex: 0 0 auto;
    display: inline-flex;
    align-items: center;
    min-height: 36px;
    padding: 7px 12px;
    border-radius: 999px;
    background: #ecfdf5;
    border: 1px solid #bbf7d0;
    color: #047857;
    font-size: 13px;
    font-weight: 800;
}

body.page-visits .patient1010-filter {
    display: grid;
    grid-template-columns: minmax(150px, .9fr) repeat(3, minmax(150px, 1fr)) auto auto;
    gap: 12px;
    align-items: end;
}

body.page-visits .patient1010-filter label {
    display: grid;
    gap: 7px;
    min-width: 0;
}

body.page-visits .patient1010-filter label > span {
    color: #475569;
    font-size: var(--patient1010-label);
    font-weight: 800;
}

body.page-visits .patient1010-filter input,
body.page-visits .patient1010-filter select {
    width: 100%;
    min-height: 48px;
    padding: 0 14px;
    border: 1px solid #dbe4ef;
    border-radius: 14px;
    background: #fff;
    color: #0f172a;
    font: inherit;
    font-size: 16px;
    font-weight: 650;
}

html[dir="rtl"] body.page-visits .patient1010-filter input,
html[dir="rtl"] body.page-visits .patient1010-filter select {
    font-size: 17px;
}

body.page-visits .patient1010-filter.is-year [data-range-field] { display: none; }
body.page-visits .patient1010-filter.is-range [data-year-field] { display: none; }

body.page-visits .patient1010-filter .btn {
    min-height: 48px;
    padding-inline: 20px;
    font-size: 16px;
    font-weight: 800;
    white-space: nowrap;
}

body.page-visits .patient1010-filter-message {
    margin-top: 14px;
    padding: 12px 14px;
    border: 1px solid #fecaca;
    border-radius: 14px;
    background: #fff7f7;
    color: #9f1239;
    font-size: 15px;
    font-weight: 700;
}

body.page-visits .patient1010-period-strip {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 12px;
    margin-bottom: 18px;
}

body.page-visits .patient1010-period-strip article {
    min-width: 0;
    padding: 16px 18px;
    border: 1px solid #e2e8f0;
    border-radius: 18px;
    background: linear-gradient(180deg, #fff 0%, #f8fbff 100%);
}

body.page-visits .patient1010-period-strip span {
    display: block;
    margin-bottom: 6px;
    color: #64748b;
    font-size: 13px;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: .04em;
}

body.page-visits .patient1010-period-strip strong {
    display: block;
    overflow-wrap: anywhere;
    color: #0f172a;
    font-size: 16px;
    line-height: 1.4;
}

html[dir="rtl"] body.page-visits .patient1010-period-strip strong { font-size: 17px; }

body.page-visits .patient1010-state {
    margin-bottom: 18px;
    padding: 22px 24px;
    border-radius: 20px;
}

body.page-visits .patient1010-state-error {
    border: 1px solid #fecaca;
    background: #fff8f8;
}

body.page-visits .patient1010-state-warning {
    border: 1px solid #fde68a;
    background: #fffdf4;
}

body.page-visits .patient1010-state h2 {
    margin: 4px 0 6px;
    font-size: 22px;
}

body.page-visits .patient1010-kpis {
    margin-bottom: 18px;
}

body.page-visits .patient1010-kpi {
    min-height: 188px;
    padding: 22px;
}

body.page-visits .patient1010-kpi > span {
    font-size: 15px;
    font-weight: 800;
}

body.page-visits .patient1010-kpi > strong {
    font-size: var(--patient1010-kpi);
    line-height: 1;
    letter-spacing: -.035em;
}

body.page-visits .patient1010-kpi > small {
    font-size: 14px;
    line-height: 1.5;
}

html[dir="rtl"] body.page-visits .patient1010-kpi > span,
html[dir="rtl"] body.page-visits .patient1010-kpi > small { font-size: 15px; }

body.page-visits .patient1010-insight {
    display: grid;
    grid-template-columns: minmax(220px, .7fr) minmax(0, 1.6fr);
    gap: 24px;
    align-items: center;
    margin-bottom: 18px;
    padding: 22px 26px;
    border: 1px solid #dbeafe;
    border-radius: 22px;
    background: linear-gradient(120deg, #eff6ff 0%, #ffffff 56%, #f8fafc 100%);
}

body.page-visits .patient1010-insight p {
    margin: 0;
    color: #334155;
    font-weight: 650;
}

body.page-visits .patient1010-primary-grid {
    align-items: start;
}

body.page-visits .patient1010-monthly-card,
body.page-visits .patient1010-mix-card,
body.page-visits .patient1010-table-card {
    border-radius: var(--patient1010-radius);
}

body.page-visits .patient1010-charts {
    display: grid;
    grid-template-columns: 1fr;
    gap: 16px;
}

body.page-visits .patient1010-chart-card {
    min-width: 0;
    padding: 16px 16px 12px;
    border: 1px solid #e2e8f0;
    border-radius: 18px;
    background: #fff;
}

body.page-visits .patient1010-chart-head {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 12px;
    margin: 0 4px 8px;
}

body.page-visits .patient1010-chart-head h3 {
    margin: 0;
    font-size: var(--patient1010-card-title);
    line-height: 1.25;
}

body.page-visits .patient1010-chart-head span {
    color: #64748b;
    font-size: 13px;
    font-weight: 750;
    text-align: end;
}

body.page-visits .patient1010-chart-card canvas {
    width: 100%;
    min-height: 280px;
}

body.page-visits .patient1010-chart-state {
    display: grid;
    place-items: center;
    min-height: 220px;
    padding: 24px;
    border-radius: 16px;
    background: #f8fafc;
    color: #64748b;
    font-size: 16px;
    font-weight: 750;
    text-align: center;
}

body.page-visits .patient1010-chart-state[hidden] { display: none !important; }

body.page-visits .patient1010-secondary-grid {
    align-items: start;
}

body.page-visits .patient1010-table-card th,
body.page-visits .patient1010-table-card td {
    font-size: 15px;
    line-height: 1.45;
}

html[dir="rtl"] body.page-visits .patient1010-table-card th,
html[dir="rtl"] body.page-visits .patient1010-table-card td { font-size: 16px; }

body.page-visits .patient1010-table-card tbody td:first-child {
    font-weight: 800;
    color: #0f172a;
}

@media (max-width: 1500px) {
    body.page-visits .patient1010-filter {
        grid-template-columns: repeat(4, minmax(145px, 1fr));
    }
    body.page-visits .patient1010-filter .btn { width: 100%; }
}

@media (max-width: 1080px) {
    body.page-visits .patient1010-period-strip { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    body.page-visits .patient1010-filter { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    body.page-visits .patient1010-insight { grid-template-columns: 1fr; gap: 8px; }
}

@media (max-width: 680px) {
    body.page-visits .patient1010-control { padding: 20px 16px; }
    body.page-visits .patient1010-control-head { display: grid; }
    body.page-visits .patient1010-parity-badge { justify-self: start; }
    body.page-visits .patient1010-filter,
    body.page-visits .patient1010-period-strip { grid-template-columns: 1fr; }
    body.page-visits .patient1010-chart-head { display: grid; }
    body.page-visits .patient1010-chart-head span { text-align: start; }
    body.page-visits .patient1010-chart-card canvas { min-height: 250px; }
}

@media print {
    body.page-visits .patient1010-control,
    body.page-visits .patient1010-branch,
    body.page-visits .elite-sidebar,
    body.page-visits .elite-topbar,
    body.page-visits .elite-mobile-bar { display: none !important; }
    body.page-visits .patient1010-period-strip { grid-template-columns: repeat(4, 1fr); }
    body.page-visits .patient1010-kpi { min-height: auto; }
}


/* H11.0-P11.1-R31 — Visits Intelligence General Manager Executive Decision Redesign */
body.page-visits.visits31-active main,
body.page-visits.visits31-active .app-main { min-width: 0; }
body.page-visits.visits31-active .visits31-comparison,
body.page-visits.visits31-active .visits31-insight,
body.page-visits.visits31-active .visits31-main-chart,
body.page-visits.visits31-active .visits31-balance-card,
body.page-visits.visits31-active .visits31-funding-card,
body.page-visits.visits31-active .visits31-specialty-card,
body.page-visits.visits31-active .visits31-matrix-card,
body.page-visits.visits31-active .visits31-supporting-details,
body.page-visits.visits31-active .visits31-actions {
    border: 1px solid #dbe4f0;
    border-radius: 24px;
    background: rgba(255,255,255,.97);
    box-shadow: 0 16px 40px rgba(28, 39, 70, .07);
}
body.page-visits.visits31-active .visits31-comparison {
    display: grid;
    grid-template-columns: minmax(250px,.72fr) minmax(720px,1.5fr);
    gap: 22px;
    align-items: end;
    padding: 18px 20px;
    margin-bottom: 16px;
}
body.page-visits.visits31-active .visits31-comparison-copy { display: grid; gap: 4px; }
body.page-visits.visits31-active .visits31-comparison-copy strong { font-size: 18px; color: #18233d; }
body.page-visits.visits31-active .visits31-comparison-copy small { color: #6a7891; font-weight: 700; line-height: 1.45; }
body.page-visits.visits31-active .visits31-filter {
    display: grid;
    grid-template-columns: minmax(170px,1fr) minmax(150px,.8fr) minmax(170px,.85fr) minmax(180px,.9fr);
    gap: 10px;
    align-items: end;
}
body.page-visits.visits31-active .visits31-filter label { display: grid; gap: 6px; min-width: 0; }
body.page-visits.visits31-active .visits31-filter label > span { font-size: 13px; font-weight: 900; color: #4a5873; }
body.page-visits.visits31-active .visits31-filter input,
body.page-visits.visits31-active .visits31-filter select {
    width: 100%; min-height: 48px; border: 1px solid #d7e1ee; border-radius: 14px; background: #fff;
    color: #17213b; font: inherit; font-weight: 800; padding: 0 14px; outline: 0;
}
body.page-visits.visits31-active .visits31-filter.is-year [data-range-field] { display: none; }
body.page-visits.visits31-active .visits31-filter.is-range [data-year-field] { display: none; }
body.page-visits.visits31-active .visits31-apply { min-height: 48px; border-radius: 14px; }
body.page-visits.visits31-active .visits31-filter-message { grid-column: 1 / -1; color: #b42318; font-weight: 800; }
body.page-visits.visits31-active .visits31-state { padding: 16px 18px; margin-bottom: 16px; display: grid; gap: 5px; }
body.page-visits.visits31-active .visits31-state--notice { background: #fffaf0; border: 1px solid #fde4b5; }
body.page-visits.visits31-active .visits31-state--attention { background: #fff4f5; border: 1px solid #ffd2d8; }

body.page-visits.visits31-active .visits31-kpi-grid {
    display: grid; grid-template-columns: repeat(4,minmax(0,1fr)); gap: 14px; margin-bottom: 16px;
}
body.page-visits.visits31-active .visits31-kpi {
    position: relative; min-height: 140px; padding: 20px; border-radius: 22px; border: 1px solid #dbe4f0;
    background: #fff; box-shadow: 0 12px 30px rgba(28,39,70,.06); display: grid;
    grid-template-columns: 58px 1fr auto; align-items: center; gap: 14px; overflow: hidden;
}
body.page-visits.visits31-active .visits31-kpi::after { content: ''; position: absolute; width: 110px; height: 110px; border-radius: 50%; right: -40px; bottom: -52px; background: rgba(93, 92, 235, .06); }
html[dir="rtl"] body.page-visits.visits31-active .visits31-kpi::after { right: auto; left: -40px; }
body.page-visits.visits31-active .visits31-kpi-icon { width: 54px; height: 54px; border-radius: 18px; display: grid; place-items: center; font-size: 22px; font-weight: 950; }
body.page-visits.visits31-active .visits31-kpi--blue .visits31-kpi-icon { background: #e7f8ff; color: #0ea5e9; }
body.page-visits.visits31-active .visits31-kpi--violet .visits31-kpi-icon { background: #f2ebff; color: #7c3aed; }
body.page-visits.visits31-active .visits31-kpi--teal .visits31-kpi-icon { background: #e5fbf8; color: #0f9f96; }
body.page-visits.visits31-active .visits31-kpi--purple .visits31-kpi-icon { background: #f3ecff; color: #7c3aed; }
body.page-visits.visits31-active .visits31-kpi-copy { min-width: 0; display: grid; gap: 4px; }
body.page-visits.visits31-active .visits31-kpi-copy > span { color: #42516e; text-transform: uppercase; letter-spacing: .045em; font-size: 13px; font-weight: 950; }
body.page-visits.visits31-active .visits31-kpi-copy > strong { color: #111a34; font-size: clamp(34px,3vw,46px); line-height: 1; letter-spacing: -.045em; }
body.page-visits.visits31-active .visits31-kpi-copy > small { color: #748199; font-weight: 750; font-size: 13px; }
body.page-visits.visits31-active .visits31-delta { align-self: start; border-radius: 999px; padding: 7px 10px; font-size: 12px; font-style: normal; font-weight: 950; white-space: nowrap; }
body.page-visits.visits31-active .visits31-delta.down { background: #fff0f2; color: #d92d4a; }
body.page-visits.visits31-active .visits31-delta.up { background: #eafbf4; color: #079455; }

body.page-visits.visits31-active .visits31-insight {
    display: grid; grid-template-columns: 52px minmax(300px,.7fr) minmax(420px,1.3fr); gap: 18px; align-items: center;
    padding: 18px 22px; margin-bottom: 16px; background: linear-gradient(135deg,#fff 0%,#f7f3ff 58%,#f1fbff 100%);
}
body.page-visits.visits31-active .visits31-insight-icon { width: 50px; height: 50px; border-radius: 17px; display: grid; place-items: center; background: #efe7ff; color: #7138e8; font-size: 22px; }
body.page-visits.visits31-active .visits31-insight h2 { margin: 3px 0 0; font-size: clamp(24px,2vw,30px); color: #111a34; }
body.page-visits.visits31-active .visits31-insight p { margin: 0; color: #34405a; font-size: 17px; font-weight: 750; line-height: 1.55; }
body.page-visits.visits31-active .visits31-insight p strong { color: #b4233c; }

body.page-visits.visits31-active .visits31-primary-grid { display: grid; grid-template-columns: minmax(0,1.55fr) minmax(360px,.7fr); gap: 16px; margin-bottom: 16px; align-items: stretch; }
body.page-visits.visits31-active .visits31-main-chart,
body.page-visits.visits31-active .visits31-balance-card,
body.page-visits.visits31-active .visits31-funding-card,
body.page-visits.visits31-active .visits31-specialty-card,
body.page-visits.visits31-active .visits31-matrix-card { padding: 20px; min-width: 0; }
body.page-visits.visits31-active .visits31-card-head { display: flex; justify-content: space-between; align-items: flex-start; gap: 18px; margin-bottom: 14px; }
body.page-visits.visits31-active .visits31-card-head--stacked { display: block; }
body.page-visits.visits31-active .visits31-card-head h2 { margin: 4px 0 5px; color: #121b34; font-size: clamp(22px,1.9vw,28px); letter-spacing: -.035em; }
body.page-visits.visits31-active .visits31-card-head p { margin: 0; color: #6a7891; font-size: 15px; line-height: 1.5; font-weight: 700; }
body.page-visits.visits31-active .visits31-chart-tabs { display: flex; gap: 7px; flex-wrap: wrap; justify-content: flex-end; }
body.page-visits.visits31-active .visits31-chart-tabs button { border: 1px solid #d7e1ee; background: #fff; color: #33415d; border-radius: 12px; min-height: 40px; padding: 0 13px; font-weight: 900; cursor: pointer; }
body.page-visits.visits31-active .visits31-chart-tabs button.active { border-color: transparent; color: #fff; background: linear-gradient(135deg,#7138e8,#256ee9); box-shadow: 0 10px 20px rgba(113,56,232,.18); }
body.page-visits.visits31-active .visits31-chart-panel[hidden] { display: none !important; }
body.page-visits.visits31-active .visits31-chart-meta { display: flex; justify-content: space-between; gap: 12px; align-items: center; margin: 2px 2px 8px; }
body.page-visits.visits31-active .visits31-chart-meta strong { color: #26334f; font-size: 16px; }
body.page-visits.visits31-active .visits31-chart-meta span { color: #6a7891; font-size: 13px; font-weight: 850; }
body.page-visits.visits31-active .visits31-chart-stage { position: relative; width: 100%; height: 390px; min-height: 390px; overflow: hidden; border: 1px solid #e1e8f2; border-radius: 18px; background: linear-gradient(180deg,#fff,#fbfdff); }
body.page-visits.visits31-active .visits31-chart-stage canvas,
body.page-visits.visits31-active .visits31-chart-stage > .ddb-echart-host { width: 100% !important; height: 100% !important; max-height: 100% !important; }

body.page-visits.visits31-active .visits31-balance-card { display: flex; flex-direction: column; }
body.page-visits.visits31-active .visits31-balance-numbers { display: grid; gap: 10px; margin-top: 8px; }
body.page-visits.visits31-active .visits31-balance-numbers > div { position: relative; display: grid; grid-template-columns: 13px 1fr auto; grid-template-rows: auto auto; gap: 2px 10px; align-items: center; padding: 13px 14px; border: 1px solid #e2e9f3; border-radius: 16px; background: #fbfdff; }
body.page-visits.visits31-active .visits31-balance-numbers i { width: 9px; height: 9px; border-radius: 50%; grid-row: 1 / 3; }
body.page-visits.visits31-active .visits31-balance-numbers i.new { background: #2775f5; }
body.page-visits.visits31-active .visits31-balance-numbers i.follow { background: #0da47a; }
body.page-visits.visits31-active .visits31-balance-numbers strong { font-size: 23px; color: #152039; }
body.page-visits.visits31-active .visits31-balance-numbers span { color: #748199; font-weight: 750; font-size: 13px; }
body.page-visits.visits31-active .visits31-balance-numbers em { grid-column: 3; grid-row: 1 / 3; align-self: center; font-style: normal; font-weight: 950; color: #33415d; }
body.page-visits.visits31-active .visits31-balance-bar { display: flex; width: 100%; min-height: 42px; border-radius: 14px; overflow: hidden; margin: auto 0 10px; box-shadow: inset 0 0 0 1px rgba(16,24,40,.05); }
body.page-visits.visits31-active .visits31-balance-bar > span,
body.page-visits.visits31-active .visits31-balance-bar > i { display: grid; place-items: center; min-width: 0; transition: width .25s ease; font-style: normal; }
body.page-visits.visits31-active .visits31-balance-bar > span { background: linear-gradient(135deg,#2475f5,#4853e8); color: #fff; }
body.page-visits.visits31-active .visits31-balance-bar > i { background: linear-gradient(135deg,#14b886,#079b71); color: #fff; }
body.page-visits.visits31-active .visits31-balance-bar b { font-size: 13px; font-weight: 950; }
body.page-visits.visits31-active .visits31-total-visits { text-align: center; color: #6a7891; font-weight: 800; }
body.page-visits.visits31-active .visits31-total-visits strong { color: #152039; }

body.page-visits.visits31-active .visits31-secondary-grid { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 16px; margin-bottom: 16px; }
body.page-visits.visits31-active .visits31-profile-list { display: grid; gap: 13px; margin-top: 12px; }
body.page-visits.visits31-active .visits31-profile-row { display: grid; grid-template-columns: minmax(140px,.8fr) minmax(160px,1.5fr) 58px; gap: 14px; align-items: center; }
body.page-visits.visits31-active .visits31-profile-row > div { display: flex; justify-content: space-between; gap: 10px; min-width: 0; }
body.page-visits.visits31-active .visits31-profile-row > div strong { color: #33415d; }
body.page-visits.visits31-active .visits31-profile-row > div span { color: #17213b; font-weight: 900; }
body.page-visits.visits31-active .visits31-profile-row > b { height: 11px; border-radius: 999px; background: #edf2f7; overflow: hidden; }
body.page-visits.visits31-active .visits31-profile-row > b i { display: block; height: 100%; border-radius: inherit; background: linear-gradient(90deg,#55d6b2,#12a77d); }
body.page-visits.visits31-active .visits31-profile-row > em { font-style: normal; font-weight: 950; color: #0a8e69; text-align: end; }
body.page-visits.visits31-active .visits31-specialty-list { display: grid; gap: 10px; margin-top: 10px; }
body.page-visits.visits31-active .visits31-specialty-row { display: grid; grid-template-columns: 30px minmax(120px,.8fr) minmax(160px,1.5fr) 78px; gap: 10px; align-items: center; }
body.page-visits.visits31-active .visits31-specialty-row > em { width: 28px; height: 28px; border-radius: 10px; display: grid; place-items: center; background: #f0eaff; color: #6f36df; font-style: normal; font-weight: 950; }
body.page-visits.visits31-active .visits31-specialty-row > strong { color: #33415d; font-size: 14px; }
body.page-visits.visits31-active .visits31-specialty-row > span { height: 10px; border-radius: 99px; background: #edf1f7; overflow: hidden; }
body.page-visits.visits31-active .visits31-specialty-row > span i { display: block; height: 100%; border-radius: inherit; background: linear-gradient(90deg,#8b5cf6,#6d34df); }
body.page-visits.visits31-active .visits31-specialty-row > b { color: #17213b; text-align: end; }
body.page-visits.visits31-active .visits31-empty { border: 1px dashed #d6e0ed; border-radius: 18px; padding: 18px; background: #f9fbfe; color: #67758e; font-weight: 750; }
body.page-visits.visits31-active .visits31-empty--large { min-height: 190px; display: grid; place-content: center; text-align: center; gap: 6px; }
body.page-visits.visits31-active .visits31-empty strong { color: #26334f; }

body.page-visits.visits31-active .visits31-matrix-card { margin-bottom: 16px; }
body.page-visits.visits31-active .visits31-text-link { color: #6d34df; text-decoration: none; font-weight: 950; white-space: nowrap; }
body.page-visits.visits31-active .visits31-table-wrap { overflow-x: auto; border: 1px solid #e0e7f1; border-radius: 16px; background: #fff; }
body.page-visits.visits31-active .visits31-table-wrap table { width: 100%; border-collapse: collapse; min-width: 800px; }
body.page-visits.visits31-active .visits31-table-wrap th { background: #f5f8fc; color: #42516e; font-size: 13px; font-weight: 950; text-align: start; }
body.page-visits.visits31-active .visits31-table-wrap th,
body.page-visits.visits31-active .visits31-table-wrap td { padding: 12px 14px; border-bottom: 1px solid #e7edf5; }
body.page-visits.visits31-active .visits31-table-wrap tbody tr:last-child td { border-bottom: 0; }
body.page-visits.visits31-active .visits31-table-delta { font-weight: 950; white-space: nowrap; }
body.page-visits.visits31-active .visits31-table-delta.down { color: #d92d4a; }
body.page-visits.visits31-active .visits31-table-delta.up { color: #079455; }

body.page-visits.visits31-active .visits31-supporting-details { margin-bottom: 16px; overflow: hidden; }
body.page-visits.visits31-active .visits31-supporting-details > summary { list-style: none; cursor: pointer; padding: 18px 20px; display: flex; justify-content: space-between; align-items: center; gap: 14px; }
body.page-visits.visits31-active .visits31-supporting-details > summary::-webkit-details-marker { display: none; }
body.page-visits.visits31-active .visits31-supporting-details > summary span { font-size: 17px; color: #17213b; font-weight: 950; }
body.page-visits.visits31-active .visits31-supporting-details > summary small { color: #748199; font-weight: 750; }
body.page-visits.visits31-active .visits31-supporting-details[open] > summary { border-bottom: 1px solid #e4eaf3; }
body.page-visits.visits31-active .visits31-supporting-grid { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 14px; padding: 16px; }
body.page-visits.visits31-active .visits31-support-card { border: 1px solid #e1e8f2; border-radius: 18px; padding: 16px; background: #fbfdff; min-width: 0; }
body.page-visits.visits31-active .visits31-support-card--wide { grid-column: 1 / -1; }
body.page-visits.visits31-active .visits31-support-card h3 { margin: 5px 0 12px; color: #19243e; font-size: 20px; }
body.page-visits.visits31-active .visits31-profile-list--compact { margin-top: 6px; }
body.page-visits.visits31-active .visits31-daily-bars { height: 210px; display: flex; align-items: end; gap: 6px; padding: 26px 4px 0; overflow-x: auto; }
body.page-visits.visits31-active .visits31-daily-bars > div { position: relative; flex: 1 0 34px; height: 100%; display: flex; flex-direction: column; justify-content: flex-end; align-items: center; gap: 5px; }
body.page-visits.visits31-active .visits31-daily-bars > div > b { position: absolute; top: -20px; color: #33415d; font-size: 11px; }
body.page-visits.visits31-active .visits31-daily-bars > div > span { width: 70%; min-height: 8px; border-radius: 8px 8px 2px 2px; background: linear-gradient(180deg,#63dce9,#13b6cf); }
body.page-visits.visits31-active .visits31-daily-bars > div > small { color: #748199; font-size: 10px; white-space: nowrap; }

body.page-visits.visits31-active .visits31-actions { display: grid; grid-template-columns: minmax(260px,.8fr) repeat(3,minmax(0,1fr)); gap: 12px; align-items: stretch; padding: 16px; }
body.page-visits.visits31-active .visits31-actions-title { display: grid; align-content: center; padding: 4px 8px; }
body.page-visits.visits31-active .visits31-actions-title h2 { margin: 5px 0 0; font-size: 23px; color: #17213b; }
body.page-visits.visits31-active .visits31-actions > a { display: grid; grid-template-columns: 42px 1fr 20px; gap: 10px; align-items: center; border: 1px solid #e0e7f1; border-radius: 16px; padding: 13px; color: inherit; text-decoration: none; background: #fbfdff; transition: .18s ease; }
body.page-visits.visits31-active .visits31-actions > a:hover { transform: translateY(-2px); box-shadow: 0 12px 24px rgba(28,39,70,.08); }
body.page-visits.visits31-active .visits31-actions > a > i { width: 40px; height: 40px; border-radius: 13px; display: grid; place-items: center; background: #edf4ff; color: #256ee9; font-style: normal; font-weight: 950; }
body.page-visits.visits31-active .visits31-actions > a strong,
body.page-visits.visits31-active .visits31-actions > a span { display: block; }
body.page-visits.visits31-active .visits31-actions > a strong { color: #17213b; font-size: 14px; }
body.page-visits.visits31-active .visits31-actions > a span { margin-top: 4px; color: #748199; font-size: 12px; line-height: 1.45; font-weight: 700; }
body.page-visits.visits31-active .visits31-actions > a > em { color: #6d34df; font-style: normal; font-weight: 950; }

@media (max-width: 1250px) {
    body.page-visits.visits31-active .visits31-comparison { grid-template-columns: 1fr; }
    body.page-visits.visits31-active .visits31-primary-grid { grid-template-columns: 1fr; }
    body.page-visits.visits31-active .visits31-balance-bar { margin-top: 20px; }
    body.page-visits.visits31-active .visits31-actions { grid-template-columns: 1fr 1fr; }
    body.page-visits.visits31-active .visits31-actions-title { grid-column: 1 / -1; }
}
@media (max-width: 980px) {
    body.page-visits.visits31-active .visits31-kpi-grid { grid-template-columns: repeat(2,minmax(0,1fr)); }
    body.page-visits.visits31-active .visits31-secondary-grid,
    body.page-visits.visits31-active .visits31-supporting-grid { grid-template-columns: 1fr; }
    body.page-visits.visits31-active .visits31-support-card--wide { grid-column: auto; }
    body.page-visits.visits31-active .visits31-insight { grid-template-columns: 52px 1fr; }
    body.page-visits.visits31-active .visits31-insight p { grid-column: 1 / -1; }
    body.page-visits.visits31-active .visits31-filter { grid-template-columns: repeat(2,minmax(0,1fr)); }
}
@media (max-width: 680px) {
    body.page-visits.visits31-active .visits31-kpi-grid { grid-template-columns: 1fr; }
    body.page-visits.visits31-active .visits31-kpi { min-height: 122px; grid-template-columns: 52px 1fr auto; }
    body.page-visits.visits31-active .visits31-filter { grid-template-columns: 1fr; }
    body.page-visits.visits31-active .visits31-chart-stage { height: 330px; min-height: 330px; }
    body.page-visits.visits31-active .visits31-card-head { display: grid; }
    body.page-visits.visits31-active .visits31-chart-tabs { justify-content: flex-start; }
    body.page-visits.visits31-active .visits31-profile-row { grid-template-columns: 1fr 60px; }
    body.page-visits.visits31-active .visits31-profile-row > b { grid-column: 1 / -1; grid-row: 2; }
    body.page-visits.visits31-active .visits31-specialty-row { grid-template-columns: 30px 1fr 65px; }
    body.page-visits.visits31-active .visits31-specialty-row > span { grid-column: 2 / -1; }
    body.page-visits.visits31-active .visits31-actions { grid-template-columns: 1fr; }
    body.page-visits.visits31-active .visits31-actions-title { grid-column: auto; }
    body.page-visits.visits31-active .visits31-supporting-details > summary { display: grid; }
}


/* H11.0-P11.1-R32 — Visits full matrix interaction hotfix */
body.page-visits.visits31-active #visits31-full-matrix {
    scroll-margin-top: 118px;
    outline: none;
}
body.page-visits.visits31-active #visits31-full-matrix:focus-visible {
    box-shadow: 0 0 0 3px rgba(109, 52, 223, 0.18);
}
