/* Inline-size containment keeps the cards responsive, but gives an auto-width
   Elementor flex item no intrinsic content width. Size the hosting widget. */
.elementor-widget-shortcode:has(.wpdst-most-active) {
    /* Elementor can emit per-widget width and max-width rules at each breakpoint. */
    width: 100% !important;
    max-width: 100% !important;
    box-sizing: border-box;
    grid-column: 1 / -1;
}
.elementor-widget-shortcode > .elementor-widget-container:has(.wpdst-most-active),
.elementor-widget-shortcode .elementor-shortcode:has(> .wpdst-most-active),
.wpdst-most-active {
    box-sizing: border-box;
    width: 100%;
    min-width: 0;
}
.wpdst-most-active {
    --ma-ink: #223243;
    --ma-muted: #636e79;
    --ma-shadow: 0 1px 2px #1c261e0d, 0 8px 24px -14px #1c261e2e;
    container: most-active / inline-size;
    background: #fafbf9;
    color: var(--ma-ink);
    padding: clamp(16px, 2vw, 32px);
    line-height: 1.45;
}
.wpdst-most-active *, .wpdst-most-active *::before, .wpdst-most-active *::after { box-sizing: border-box; }
.wpdst-most-active .ma-header, .wpdst-most-active .ma-actions, .wpdst-most-active .ma-toggle {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 16px;
}
.wpdst-most-active .ma-header { justify-content: space-between; align-items: flex-end; margin-bottom: 36px; }
.wpdst-most-active .ma-eyebrow {
    margin: 0 0 6px;
    color: #357741;
    font-size: 11px;
    font-weight: 700;
    letter-spacing: .16em;
    text-transform: uppercase;
}
.wpdst-most-active .ma-header h2 {
    margin: 0;
    color: #111b17;
    font-weight: 400; font-size: clamp(32px, 3vw, 40px); line-height: 1.14; font-style: normal;
    letter-spacing: -.025em;
}
.wpdst-most-active .ma-actions { gap: 8px 20px; font-size: 13px; }
.wpdst-most-active .ma-toggle {
    position: relative;
    gap: 10px;
    min-height: 44px;
    margin: 0;
    cursor: pointer;
    font-weight: 500;
}
.wpdst-most-active .ma-toggle input {
    position: absolute;
    width: 1px;
    height: 1px;
    opacity: 0;
}
.wpdst-most-active .ma-switch {
    display: inline-block;
    position: relative;
    width: 34px;
    height: 18px;
    border-radius: 1em;
    background: #d3d6cd;
}
.wpdst-most-active .ma-switch::after {
    content: '';
    position: absolute;
    inset: 3px auto auto 3px;
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background: #87917e;
    transition: transform .2s ease;
}
.wpdst-most-active .ma-toggle input:checked + .ma-switch { background: #d2ebd1; }
.wpdst-most-active .ma-toggle input:checked + .ma-switch::after { transform: translateX(16px); background: #338146; }
.wpdst-most-active .ma-toggle input:focus-visible + .ma-switch,
.wpdst-most-active .ma-browse:focus-visible { outline: 2px solid #337c49; outline-offset: 3px; }
.wpdst-most-active .ma-toggle:has(input:disabled) { cursor: default; color: var(--ma-muted); }
.wpdst-most-active .ma-browse {
    display: inline-flex;
    align-items: center;
    min-height: 40px;
    padding: 6px 16px;
    background: white;
    border: 1px solid #d3d7ce;
    border-radius: 24px;
    color: #1c3829;
    text-decoration: none;
    font-weight: 600;
}
.wpdst-most-active .ma-browse:hover { border-color: #68996c; }
.wpdst-most-active .ma-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 24px;
}
.wpdst-most-active .ma-card {
    container: ma-card / inline-size;
    position: relative;
    display: flex;
    flex-direction: column;
    min-width: 0;
    padding: 24px 22px 22px;
    margin: 0;
    border-radius: 14px;
    background: #fff;
    box-shadow: var(--ma-shadow);
    transition: transform .3s ease, box-shadow .3s ease;
}
.wpdst-most-active .ma-card:hover { transform: translateY(-3px); box-shadow: 0 12px 28px -15px #1c261e52; }
.wpdst-most-active .ma-card:focus-within { outline: 2px solid #337c49; }
.wpdst-most-active .ma-card-heading { margin: 0; padding: 0; font: inherit; }
.wpdst-most-active .ma-name {
    display: block;
    color: var(--ma-ink);
    font-weight: 600;
    line-height: 1.35;
    min-height: 2.7em;
    overflow-wrap: anywhere;
    text-decoration: none;
}
.wpdst-most-active .ma-name::after { content: ''; position: absolute; inset: 0; border-radius: 14px; }
.wpdst-most-active .ma-card:hover .ma-name { color: #40874b; }
.wpdst-most-active .ma-sides { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; margin: 16px 0 0; }
.wpdst-most-active .ma-label { color: var(--ma-muted); font-size: 11px; letter-spacing: .06em; text-transform: uppercase; }
.wpdst-most-active .ma-price-row { display: flex; flex-wrap: wrap; gap: 2px 5px; align-items: baseline; margin-top: 4px; }
.wpdst-most-active .ma-price-row strong { font-size: min(var(--ma-price-size), 15px); line-height: 1.25; overflow-wrap: anywhere; }
.wpdst-most-active .ma-price-row, .wpdst-most-active .ma-range { font-variant-numeric: tabular-nums; }
.wpdst-most-active .ma-move { display: none; font-size: 11px; color: var(--ma-muted); }
.wpdst-most-active:has(.ma-toggle input:checked) .ma-move { display: inline; }
.wpdst-most-active .ma-up { color: #227747; }
.wpdst-most-active .ma-down { color: #b4382d; }
.wpdst-most-active .ma-range { display: grid; grid-template-columns: auto minmax(42px, 1fr) auto; gap: 8px; align-items: end; margin-top: auto; padding-top: 20px; }
.wpdst-most-active .ma-extreme { font-size: 12px; font-weight: 600; overflow-wrap: anywhere; }
.wpdst-most-active .ma-extreme:last-child { text-align: right; }
.wpdst-most-active .ma-extreme time, .wpdst-most-active .ma-scale { font-size: 9px; font-weight: 500; color: var(--ma-muted); text-transform: uppercase; }
.wpdst-most-active .ma-extreme time { display: block; margin-top: 3px; }
.wpdst-most-active .ma-track { min-width: 0; padding-bottom: 4px; }
.wpdst-most-active .ma-scale { display: flex; align-items: end; justify-content: space-between; gap: 3px; line-height: 1.2; }
.wpdst-most-active .ma-caption { text-align: center; }
.wpdst-most-active .ma-bar { position: relative; height: 4px; margin-top: 6px; border-radius: 10px; background: linear-gradient(90deg,#f0857d,#ef6a60 46%,#6dd08a 54%,#4cbf72); }
.wpdst-most-active .ma-bar i { position: absolute; top: 50%; width: 9px; height: 9px; transform: translate(-50%, -50%); background: #22a45d; border: 2px solid #fff; border-radius: 50%; }
.wpdst-most-active .ma-unavailable { margin: auto 0 0; padding-top: 20px; color: var(--ma-muted); font-size: 12px; }
.wpdst-most-active .ma-empty { grid-column: 1 / -1; }
.wpdst-most-active .ma-notice { font-size: 13px; margin: 0 0 12px; }
.wpdst-most-active .ma-notice:empty { display: none; }
/* Match the reference viewport breakpoints. A boxed desktop section can
   fit four cards even when its content width is less than 1080px. */
@media (max-width: 1080px) {
    .wpdst-most-active .ma-grid { grid-template-columns: repeat(2, minmax(0,1fr)); }
}
/* Also accommodate genuinely narrow Elementor columns on wider screens. */
@container most-active (max-width: 840px) {
    .wpdst-most-active .ma-grid { grid-template-columns: repeat(2, minmax(0,1fr)); }
}
@media (max-width: 767px) {
    .wpdst-most-active {
        padding-inline-start: max(0px, calc(20px - var(--padding-inline-start, 0px)));
        padding-inline-end: max(0px, calc(20px - var(--padding-inline-end, 0px)));
    }
}
@media (max-width: 620px) {
    .wpdst-most-active .ma-grid { grid-template-columns: minmax(0,1fr); gap: 16px; }
    .wpdst-most-active .ma-header { margin-bottom: 20px; }
}
@container most-active (max-width: 460px) {
    .wpdst-most-active .ma-grid { grid-template-columns: minmax(0,1fr); gap: 16px; }
    .wpdst-most-active .ma-header { display: grid; grid-template-columns: minmax(0, 1fr); gap: 12px; margin-bottom: 16px; }
    .wpdst-most-active .ma-actions { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 8px; }
    .wpdst-most-active .ma-toggle { flex-wrap: nowrap; gap: 6px; min-width: 0; justify-self: start; }
    .wpdst-most-active .ma-switch { flex: none; }
    .wpdst-most-active .ma-browse { justify-content: center; min-height: 44px; padding-inline: 10px; text-align: center; }
    .wpdst-most-active .ma-card { padding: 18px 17px; }
    .wpdst-most-active .ma-name { min-height: 0; }
    .wpdst-most-active .ma-label { display: block; }
    .wpdst-most-active .ma-price-row { display: grid; grid-template-columns: minmax(0, 1fr); gap: 2px; }
}
@container most-active (max-width: 300px) {
    .wpdst-most-active .ma-actions { grid-template-columns: minmax(0, 1fr); gap: 4px; }
    .wpdst-most-active .ma-toggle { justify-self: stretch; justify-content: space-between; }
}
@container ma-card (max-width: 205px) {
    .wpdst-most-active .ma-caption { display: none; }
    .wpdst-most-active .ma-range { gap: 5px; }
}
@media (prefers-reduced-motion: reduce) {
    .wpdst-most-active .ma-card, .wpdst-most-active .ma-switch::after { transition: none; }
    .wpdst-most-active .ma-card:hover { transform: none; }
}
