/* ===================================================================
   Service packages page: marketing plans (includes/service-packages/pages/marketing-plans.php)

   Loaded after css/pages/service-packages.css on this page only. Prefix `pp-mp-`.
   - Hero variant plan-toc (sections/hero/plan-toc.php)
   - mp-deliverables       (sections/custom/mp-deliverables.php)
   - mp-fit                (sections/custom/mp-fit.php)
   =================================================================== */

/* ---------- Hero visual: plan table of contents ---------- */

.pp-mp-toc {
    position: relative;
    margin: 0;
    padding: 58px 0 0;
    padding-inline-end: 34px;
}

/* Tilted "budget split" card peeking out behind the main card. */
.pp-mp-toc__back {
    position: absolute;
    top: 0;
    inset-inline-end: 0;
    width: 60%;
    padding: 14px 18px 70px;
    border-radius: 16px;
    background: linear-gradient(160deg, rgba(255, 255, 255, 0.08), rgba(255, 255, 255, 0.02));
    border: 1px solid var(--white-20);
    transform: rotate(-4deg);
    transform-origin: center;
}

.pp-mp-toc__back-title {
    display: block;
    margin-bottom: 10px;
    font-size: 0.74rem;
    font-weight: 700;
    color: var(--white-60);
}

.pp-mp-toc__split {
    display: flex;
    gap: 3px;
    height: 10px;
    border-radius: 999px;
    overflow: hidden;
}

.pp-mp-toc__seg {
    flex-basis: 0;
    min-width: 6px;
}

.pp-mp-toc__seg--0 { background: var(--brand-primary-bright); }
.pp-mp-toc__seg--1 { background: var(--brand-gold); }
.pp-mp-toc__seg--2 { background: rgba(126, 226, 160, 0.85); }
.pp-mp-toc__seg--3 { background: var(--white-45); }

/* Main card: the shared .pp-hero-card frame (+ --tilt), opaque enough to cover the back card. */
.pp-mp-toc__card {
    --pp-hero-card-bg: linear-gradient(160deg, rgba(23, 56, 90, 0.92), rgba(12, 32, 56, 0.9));
}

.pp-mp-toc__bar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    padding-bottom: 14px;
    margin-bottom: 8px;
    border-bottom: 1px solid var(--white-10);
}

.pp-mp-toc__title {
    font-weight: 800;
    font-size: 1rem;
    color: var(--white);
}

.pp-mp-toc__badge {
    padding: 4px 10px;
    border-radius: 999px;
    border: 1px dashed var(--white-30);
    color: var(--brand-gold);
    font-size: 0.74rem;
    font-weight: 700;
    white-space: nowrap;
}

.pp-mp-toc__list {
    list-style: none;
    margin: 0 0 14px;
    padding: 0;
}

.pp-mp-toc__item {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 7px 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    font-size: 0.9rem;
    color: var(--white-90);
    animation: pp-mp-toc-in 0.5s ease-out both;
    animation-delay: calc(0.2s + var(--pp-mp-index, 0) * 60ms);
}

.pp-mp-toc__item:last-child {
    border-bottom: 0;
}

.pp-mp-toc__num {
    flex: none;
    width: 28px;
    font-weight: 800;
    font-size: 0.8rem;
    color: var(--brand-primary-bright);
    direction: ltr;
    font-variant-numeric: tabular-nums;
}

.pp-mp-toc__name {
    flex: none;
    font-weight: 600;
    white-space: nowrap;
}

.pp-mp-toc__dots {
    flex: 1;
    min-width: 12px;
    height: 0;
    border-bottom: 2px dotted var(--white-25);
    transform: translateY(3px);
}

.pp-mp-toc__item.is-tier .pp-mp-toc__num {
    color: var(--brand-gold);
}

.pp-mp-toc__item.is-tier .pp-mp-toc__name {
    color: var(--white-80);
}

.pp-mp-toc__tag {
    flex: none;
    padding: 2px 8px;
    border-radius: 999px;
    background: var(--brand-gold-alpha-20);
    color: var(--brand-gold);
    font-size: 0.7rem;
    font-weight: 700;
    white-space: nowrap;
}

@keyframes pp-mp-toc-in {
    from { opacity: 0; transform: translateX(-8px); }
    to { opacity: 1; transform: none; }
}

.pp-mp-toc__timeline {
    display: grid;
    grid-template-columns: repeat(var(--pp-mp-cols, 3), minmax(0, 1fr));
    gap: 8px;
    padding: 12px;
    border-radius: 12px;
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid var(--white-10);
}

.pp-mp-toc__month {
    display: flex;
    flex-direction: column;
    gap: 6px;
    min-width: 0;
}

.pp-mp-toc__month-label {
    font-size: 0.7rem;
    color: var(--white-60);
}

.pp-mp-toc__task {
    display: block;
    height: 7px;
    border-radius: 999px;
    background: var(--white-20);
}

.pp-mp-toc__task--1 { width: 90%; }
.pp-mp-toc__task--2 { width: 62%; background: var(--primary-bright-alpha-50); }
.pp-mp-toc__task--3 { width: 75%; }

/* ---------- mp-deliverables: plan layers ---------- */

.pp-mp-layers {
    padding: 80px 0;
    background: var(--white);
}

.pp-mp-layers__grid {
    display: grid;
    grid-template-columns: repeat(var(--pp-mp-cols, 3), minmax(0, 1fr));
    gap: 20px;
    align-items: stretch;
    list-style: none;
    margin: 0;
    padding: 0;
}

.pp-mp-layer {
    position: relative;
    display: flex;
    flex-direction: column;
    gap: 10px;
    padding: 26px 24px 22px;
    background: var(--surface-5);
    border: 1px solid var(--border-soft);
    border-radius: 16px;
    transition: transform var(--transition-normal), box-shadow var(--transition-normal), border-color var(--transition-normal);
}

.pp-mp-layer:hover {
    transform: translateY(-4px);
    border-color: var(--primary-bright-alpha-40);
    box-shadow: 0 16px 36px var(--shadow-08);
}

.pp-mp-layer.is-popular {
    border-color: var(--primary-bright-alpha-40);
    box-shadow: 0 12px 30px var(--shadow-06);
}

/* Stacked sheets: one sheet per tier level, so the build-up reads at a glance. */
.pp-mp-layer__stack {
    display: flex;
    flex-direction: column-reverse;
    gap: 3px;
    width: 46px;
    margin-bottom: 4px;
}

.pp-mp-layer__stack span {
    display: block;
    height: 8px;
    border-radius: 3px;
    background: var(--brand-ink);
}

.pp-mp-layer__stack span:nth-child(2) {
    background: var(--brand-primary-bright);
    width: 88%;
}

.pp-mp-layer__stack span:nth-child(3) {
    background: var(--brand-gold);
    width: 76%;
}

.pp-mp-layer__package {
    align-self: flex-start;
    padding: 4px 12px;
    border-radius: 8px;
    background: var(--primary-bright-alpha-12);
    color: var(--pp-accent-text);
    font-size: 0.875rem;
    font-weight: 700;
}

.pp-mp-layer__title {
    margin: 2px 0 0;
    font-size: 1.14rem;
    font-weight: 800;
    color: var(--brand-ink);
}

.pp-mp-layer__base {
    margin: 0;
    font-size: 0.875rem;
    font-weight: 700;
    color: var(--text-muted-4);
}

.pp-mp-layer__adds {
    list-style: none;
    margin: 0;
    padding: 0;
    display: grid;
    gap: 6px;
}

.pp-mp-layer__adds li {
    position: relative;
    padding-inline-start: 24px;
    font-size: 0.93rem;
    font-weight: 600;
    color: var(--brand-ink);
    line-height: 1.6;
}

.pp-mp-layer__adds li::before {
    content: "+";
    position: absolute;
    inset-inline-start: 0;
    top: 2px;
    display: inline-grid;
    place-items: center;
    width: 17px;
    height: 17px;
    border-radius: 5px;
    background: var(--brand-primary-bright);
    color: var(--pp-on-primary);
    font-size: 0.8rem;
    font-weight: 800;
    line-height: 1;
}

.pp-mp-layer__text {
    flex: 1;
    margin: 4px 0 0;
    padding-top: 12px;
    border-top: 1px dashed var(--border-soft);
    font-size: 0.9rem;
    line-height: 1.85;
    color: var(--text-muted-2);
}

.pp-mp-layer__link {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    margin-top: 4px;
    padding: 10px 14px;
    border-radius: 10px;
    background: var(--white);
    border: 1px solid var(--border-soft);
    color: var(--pp-accent-text);
    font-size: 0.9rem;
    font-weight: 700;
    text-decoration: none;
    transition: border-color var(--transition-fast), background-color var(--transition-fast);
}

.pp-mp-layer__link:hover {
    border-color: var(--brand-primary-bright);
    background: var(--primary-bright-alpha-08);
    color: var(--pp-accent-text);
}

.pp-mp-layer__price {
    color: var(--brand-ink);
    font-weight: 800;
    white-space: nowrap;
}

/* ---------- mp-fit: pick by stage (dark band) ---------- */

.pp-mp-fit {
    position: relative;
    overflow: hidden;
    padding: 88px 0;
    color: var(--white);
    background:
        radial-gradient(800px 500px at 15% 100%, var(--primary-bright-alpha-20), transparent 65%),
        var(--brand-ink);
}

.pp-mp-fit .pp-section__title {
    color: var(--white);
}

.pp-mp-fit .pp-section__desc {
    color: var(--white-80);
}

.pp-mp-fit__grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 20px;
    list-style: none;
    margin: 0;
    padding: 0;
}

.pp-mp-fit__card {
    display: flex;
    flex-direction: column;
    gap: 12px;
    padding: 26px 24px 22px;
    border-radius: 16px;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid var(--white-10);
}

.pp-mp-fit__card.is-popular {
    border-color: var(--primary-bright-alpha-50);
    background: rgba(92, 181, 229, 0.08);
}

.pp-mp-fit__stage {
    display: flex;
    gap: 5px;
}

.pp-mp-fit__stage span {
    width: 26px;
    height: 6px;
    border-radius: 999px;
    background: var(--white-20);
}

.pp-mp-fit__stage span.is-on {
    background: var(--brand-gold);
}

.pp-mp-fit__title {
    margin: 0;
    font-size: 1.12rem;
    font-weight: 800;
    line-height: 1.5;
    color: var(--white);
}

.pp-mp-fit__text {
    flex: 1;
    margin: 0;
    font-size: 0.93rem;
    line-height: 1.85;
    color: var(--white-80);
}

.pp-mp-fit__pick {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 12px 14px;
    border-radius: 10px;
    background: var(--white-10);
    border: 1px solid var(--white-20);
    color: var(--white);
    text-decoration: none;
    transition: background-color var(--transition-fast), border-color var(--transition-fast);
}

.pp-mp-fit__pick:hover {
    background: var(--white-20);
    border-color: var(--white-45);
    color: var(--white);
}

.pp-mp-fit__pick-label {
    font-size: 0.875rem;
    color: var(--white-60);
}

.pp-mp-fit__pick strong {
    font-size: 1rem;
    font-weight: 800;
    color: var(--brand-gold);
}

.pp-mp-fit__arrow {
    margin-inline-start: auto;
    color: var(--white-80);
}

.pp-mp-fit__unsure {
    margin: 32px 0 0;
    text-align: center;
    font-size: 1rem;
    color: var(--white-80);
}

/* 44px tall hit area (was 26px). */
.pp-mp-fit__unsure a {
    display: inline-flex;
    align-items: center;
    min-height: 44px;
    margin-inline-start: 6px;
    color: var(--brand-gold);
    font-weight: 700;
    text-decoration: underline;
    text-underline-offset: 4px;
}

.pp-mp-fit__unsure a:hover {
    color: var(--white);
}

/* ---------- Responsive ---------- */

@media (max-width: 1024px) {
    .pp-mp-toc {
        max-width: 560px;
        margin: 0 auto;
        text-align: start;
    }

    .pp-mp-layers__grid,
    .pp-mp-fit__grid {
        grid-template-columns: 1fr;
        max-width: 620px;
        margin: 0 auto;
    }
}

@media (max-width: 768px) {
    .pp-mp-toc {
        padding-top: 50px;
        padding-inline-end: 10px;
    }

    .pp-mp-toc__back {
        width: 66%;
        transform: rotate(-3deg);
    }

    .pp-mp-toc__bar {
        flex-wrap: wrap;
    }

    .pp-mp-toc__badge {
        font-size: 0.68rem;
    }

    .pp-mp-toc__item {
        gap: 8px;
        padding: 6px 0;
        font-size: 0.84rem;
    }

    .pp-mp-toc__num {
        width: 22px;
        font-size: 0.74rem;
    }

    .pp-mp-toc__name {
        white-space: normal;
        flex: 0 1 auto;
    }

    .pp-mp-toc__tag {
        font-size: 0.64rem;
        padding: 2px 6px;
    }

    .pp-mp-layers,
    .pp-mp-fit {
        padding: 48px 0;
    }

    .pp-mp-layers__grid,
    .pp-mp-fit__grid {
        gap: 12px;
    }

    .pp-mp-layer,
    .pp-mp-fit__card {
        padding: 20px 18px 18px;
    }

    .pp-mp-layer:hover {
        transform: none;
    }

    .pp-mp-fit__unsure {
        margin-top: 24px;
    }

    .pp-mp-fit__unsure a {
        display: inline-flex;
        margin-top: 0;
    }
}

@media (prefers-reduced-motion: reduce) {
    .pp-mp-toc__item {
        animation: none;
    }

    .pp-mp-layer,
    .pp-mp-layer__link,
    .pp-mp-fit__pick {
        transition: none;
    }

    .pp-mp-layer:hover {
        transform: none;
    }
}
