.mpd-page-shell {
    margin: 0 auto;
}

.mpd-main-column,
.mpd-aside-column {
    padding-left: 0 !important;
    padding-right: 0 !important;
}

.mpd-container {
    margin: 0;
    padding: 0 10px;
    background: var(--color-bg-white);
    position: relative;
}

/* ──────────────────────────────────────────────────────────────────────────
   HERO
   ────────────────────────────────────────────────────────────────────────── */

.mpd-hero {
    position: relative;
    width: 100%;
    border-radius: 20px;
    overflow: hidden;
    background: #f3f4f6;
}

.mpd-image {
    width: 100%;
    height: 300px !important;
    display: block;
    object-fit: cover;
    border-radius: 0;
}

.mpd-image.skeleton {
    width: 100%;
    height: 300px;
    display: block;
    border-radius: 0;
    background: linear-gradient(
            110deg,
            rgba(0,0,0,0.05) 8%,
            rgba(0,0,0,0.10) 18%,
            rgba(0,0,0,0.05) 33%
    );
    background-size: 200% 100%;
    animation: mpd-shine 1.5s linear infinite;
}

@media only screen and (max-width: 600px) {
    .mpd-hero {
        border-radius: 0 !important;
        margin-left: -10px;
        margin-right: -10px;
    }

    .mpd-image,
    .mpd-image.skeleton {
        height: 240px !important;
        border-radius: 0 !important;
    }

    .mpd-hero-overlay {
        padding-left: 16px;
        padding-right: 16px;
    }
}

.mpd-hero-overlay {
    position: absolute;
    inset: 0;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    padding: 16px;
    pointer-events: none;
}

.mpd-hero-top-row {
    display: flex;
    justify-content: flex-end;
    pointer-events: none;
}

.mpd-hero-bottom-wrap {
    display: flex;
    flex-direction: column;
    gap: 12px;
    pointer-events: none;
}

.mpd-hero-content,
.mpd-video-pill--hero,
.mpd-share-fab {
    pointer-events: auto;
}

.mpd-hero-content {
    width: 100%;
    padding: 48px 20px 0;
    box-sizing: border-box;
    background: linear-gradient(
            to top,
            rgba(0, 0, 0, 0.76) 0%,
            rgba(0, 0, 0, 0.40) 55%,
            transparent 100%
    );
}
.mpd-flow-header-wrap {
    padding: 6px 16px 2px 16px;
}

.mpd-title {
    font-family: 'Fraunces', Georgia, serif;
    font-size: 1.85rem;
    font-weight: 700;
    color: #1a1a1a;
    line-height: 1.15;
    letter-spacing: -0.025em;
    margin-bottom: 10px;
}

.mpd-hero-content .mpd-title {
    color: #ffffff !important;
    text-shadow: 0 1px 4px rgba(0, 0, 0, 0.35);
}

.mpd-title.skeleton,
.mpd-hero-content .mpd-title.skeleton {
    background: linear-gradient(
            110deg,
            rgba(255,255,255,0.12) 8%,
            rgba(255,255,255,0.22) 18%,
            rgba(255,255,255,0.12) 33%
    );
    background-size: 200% 100%;
    animation: 1.5s shine linear infinite;
    border-radius: 6px;
    height: 32px;
    width: 70%;
    display: block;
    color: transparent !important;
    margin-bottom: 8px;
}

/* ──────────────────────────────────────────────────────────────────────────
   HERO ACTIONS
   ────────────────────────────────────────────────────────────────────────── */

.mpd-share-fab {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.94);
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.12);
    cursor: pointer;
}

.mpd-share-fab-icon {
    font-size: 18px !important;
    line-height: 1;
    color: var(--app-text-color, #1f2937);
}

.mpd-video-pill {
    display: flex;
    align-items: center;
    gap: 8px;
    min-width: 0;
    padding: 10px 12px;
    border-radius: 999px;
    cursor: pointer;
}

.mpd-video-pill--hero {
    align-self: flex-start;
    background: rgba(255, 255, 255, 0.94);
    padding: 10px 14px;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.12);
}

.mpd-video-pill-icon {
    font-size: 18px !important;
    color: #1b5e20;
}

.mpd-video-pill-text {
    font-size: 13px;
    font-weight: 500;
    color: #1f2d3d;
    flex: 1;
    min-width: 0;
}

.mpd-video-pill-chevron {
    font-size: 20px !important;
    color: #667781;
}

/* ──────────────────────────────────────────────────────────────────────────
   VIDEO MODAL
   ────────────────────────────────────────────────────────────────────────── */

.mpd-video-modal-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.62);
    z-index: 9999;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 16px;
}

.mpd-video-modal-card {
    width: 100%;
    max-width: 720px;
    background: #fff;
    border-radius: 20px;
    overflow: hidden;
}

.mpd-video-modal-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 14px 16px;
    border-bottom: 1px solid #eee;
}

.mpd-video-modal-title {
    font-weight: 700;
}

.mpd-video-modal-close {
    cursor: pointer;
}

.mpd-video-modal-host {
    width: 100%;
    aspect-ratio: 16 / 9;
}

.mpd-video-modal-player {
    width: 100%;
    min-height: 220px;
}

/* ──────────────────────────────────────────────────────────────────────────
   TIER SELECTOR
   ────────────────────────────────────────────────────────────────────────── */

.mpd-tier-selector {
    display: block;
    text-align: center;
    padding: 0 16px;
}

.mpd-tier-pills-sticky {
    position: sticky;
    top: 0;
    z-index: 30;
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    padding: 10px 0;
    margin: 0 15px 15px;
}

.mpd-tier-helper {
    display: block;
    margin-top: 8px;
    color: var(--color-text-muted);
    font-size: 0.9rem;
}

/* ──────────────────────────────────────────────────────────────────────────
   SUMMARY
   ────────────────────────────────────────────────────────────────────────── */
.mpd-summary-card {
    margin: 12px auto;
    max-width: 500px;
    padding: 14px 16px;
    border: 1px solid #edf0f2;
    border-radius: 18px;
    background: #fff;
    box-shadow: 0 1px 2px rgba(16, 24, 40, 0.04);
}

.mpd-summary-card--skeleton .mpd-summary-meta,
.mpd-summary-card--skeleton .mpd-summary-total,
.mpd-summary-card--skeleton .mpd-summary-side {
    color: transparent !important;
    border-radius: 6px;
    background: linear-gradient(
            110deg,
            rgba(0,0,0,0.04) 8%,
            rgba(0,0,0,0.08) 18%,
            rgba(0,0,0,0.04) 33%
    );
    background-size: 200% 100%;
    animation: 1.5s shine linear infinite;
}

.mpd-summary-card--skeleton .mpd-summary-meta {
    height: 14px;
    width: 140px;
    display: block;
    margin-bottom: 10px;
}

.mpd-summary-card--skeleton .mpd-summary-total {
    height: 22px;
    min-width: 170px;
    display: inline-block;
}

.mpd-summary-card--skeleton .mpd-summary-side {
    height: 16px;
    width: 110px;
    display: inline-block;
}

.mpd-summary-meta {
    display: block;
    margin-bottom: 8px;
    font-size: 0.82rem;
    color: #667085;
    line-height: 1.4;
    font-weight: 500;
}

.mpd-summary-main-row {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 12px;
}

.mpd-summary-total {
    font-size: 18px !important;
    font-weight: 700 !important;
    color: var(--GRAY_900) !important;
    line-height: 1.3 !important;
    margin: 0 !important;
}

.mpd-summary-side {
    font-size: 13px !important;
    font-weight: 500 !important;
    color: #667085 !important;
    line-height: 1.4 !important;
    margin: 0 !important;
    white-space: nowrap;
}

.mpd-schedule {
    margin-top: 24px;
}

/* ──────────────────────────────────────────────────────────────────────────
   STICKY FOOTER
   ────────────────────────────────────────────────────────────────────────── */
/* Mobile: floating button visible, sheet hidden until triggered */
.mpd-floating-basket-btn {
    display: none;
}

@media (max-width: 768px) {
    .mpd-floating-basket-btn {
        position: fixed !important;
        right: 16px !important;
        bottom: 72px !important; /* above mobile bottom nav */
        left: auto !important;

        z-index: 1000 !important;
        display: inline-flex;
        align-items: center;
        justify-content: center;

        min-height: 46px !important;
        padding: 0 18px !important;
        border-radius: 999px !important;

        background-color: var(--PRIMARY_CTA, #1B5E20) !important;
        color: #ffffff !important;
        font-weight: 700 !important;
        font-size: 0.95rem !important;
        text-transform: none !important;
        letter-spacing: 0 !important;
        box-shadow: 0 8px 24px rgba(27, 94, 32, 0.22) !important;
        border: none !important;
    }

    .mpd-floating-basket-btn,
    .mpd-floating-basket-btn .btn,
    .mpd-floating-basket-btn .material-icons {
        background-color: var(--PRIMARY_CTA, #1B5E20) !important;
        color: #ffffff !important;
    }
}

/* Desktop: no overlay backdrop, sheet is always shown inline and sticky */
@media (min-width: 769px) {
    .mpd-floating-basket-btn {
        display: none !important;
    }
}

@media (max-width: 768px) {
    .mpd-basket-sheet-overlay {
        position: fixed;
        inset: 0;
        margin-bottom: 64px;
        background: rgba(0, 0, 0, 0.28);
        z-index: 50;
        display: flex;
        align-items: flex-end;
        justify-content: center;
    }
}

@media (min-width: 769px) {
    .mpd-basket-sheet-overlay {
        position: static;
        background: transparent;
        display: block;
    }

    .mpd-basket-sheet-overlay .mpd-basket-sheet {
        position: sticky;
        border-radius: 0;
        margin-bottom: 0;
        border-top: 1px solid #eee;
        box-shadow: 0 -2px 10px rgba(0, 0, 0, 0.1);
    }

    .mpd-basket-sheet-overlay .mpd-basket-sheet-handle {
        display: none;
    }
}
.mpd-locked {
    pointer-events: none;
    opacity: 0.6;
}

.mpd-basket-sheet {
    width: 100%;
    background: #fff;
    padding: 12px 14px calc(14px + env(safe-area-inset-bottom));
    box-shadow: 0 -10px 30px rgba(0, 0, 0, 0.12);
}

.mpd-basket-sheet-handle {
    width: 42px;
    height: 5px;
    border-radius: 999px;
    background: #d1d5db;
    margin: 0 auto 12px;
}

.mpd-family-row {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 15px;
    margin: 0 auto;
}

.mpd-family-label {
    min-width: 120px;
    display: inline-block;
    font-weight: var(--weight-semibold);
}

.mpd-family-change-link,
.mpd-family-done-link {
    font-size: 0.88rem;
    font-weight: 600;
    color: var(--PRIMARY_CTA, #1B5E20);
    text-decoration: none !important;
    cursor: pointer;
    line-height: 1.2;
}

.mpd-family-change-link:hover,
.mpd-family-done-link:hover {
    text-decoration: underline;
}

.mpd-family-size-wrap {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 15px;
    margin: 0 auto;
}

.mpd-start-plan-btn {
    margin-top: 15px;
    width: 100%;
    min-height: 48px;
    border-radius: 999px !important;
    background-color: var(--PRIMARY_CTA, #1B5E20) !important;
    color: #fff !important;
    font-size: 0.98rem;
    font-weight: 700 !important;
    text-transform: none !important;
    letter-spacing: 0;
    box-shadow: 0 6px 18px rgba(27, 94, 32, 0.18);
}

.mpd-start-plan-btn:hover {
    background-color: var(--PRIMARY_CTA_HOVER, #0D3B10) !important;
    box-shadow: 0 8px 22px rgba(27, 94, 32, 0.22);
}

.mpd-start-plan-btn:disabled,
.mpd-start-plan-btn[disabled] {
    background-color: var(--DISABLED_COLOR, #BDBDBD) !important;
    color: #fff !important;
    box-shadow: none;
    cursor: not-allowed;
}

.mpd-delivery-hint {
    display: block;
    font-size: 12px !important;
    color: #5F5E5A !important;
    line-height: 1.5 !important;
    margin-top: 6px !important;
    padding: 0 4px !important;
    text-align: center;
}

/* ──────────────────────────────────────────────────────────────────────────
   RIGHT RAIL
   ────────────────────────────────────────────────────────────────────────── */

.mpd-aside-column {
    padding-left: 16px !important;
}

.mpd-aside-column-container {
    padding-left: 16px !important;
    position: fixed;
    top: 64px;
    height: calc(100vh - 64px);
    overflow-y: auto;
    overflow-x: hidden;
    /* smooth momentum scroll on iOS */
    -webkit-overflow-scrolling: touch;
    /* hide scrollbar visually but keep it functional */
    scrollbar-width: thin;
    scrollbar-color: rgba(0,0,0,0.15) transparent;
}

.mpd-aside-column-container::-webkit-scrollbar {
    width: 4px;
}

.meal-action-section-label {
    font-size: 12px;
    font-weight: 600;
    color: #757575;
    text-transform: uppercase;
    padding: 8px 16px 4px 16px;
}

.meal-action-subitem {
    display: block;
    padding: 10px 16px 10px 40px;
    font-size: 14px;
    color: #212121 !important;
    text-decoration: none !important;
    cursor: pointer;
}

.meal-action-subitem:hover {
    background-color: #f5f5f5;
}

.meal-action-section-label {
    font-size: 12px;
    font-weight: 600;
    color: #757575;
    text-transform: uppercase;
    padding: 8px 18px 4px 18px;
}

.meal-action-subitem {
    display: block;
    padding: 12px 18px 12px 42px;
    font-size: 15px;
    color: #212121 !important;
    text-decoration: none !important;
    cursor: pointer;
}

.meal-action-subitem:hover {
    background-color: #f5f5f5;
}

.mpd-aside-column-container::-webkit-scrollbar-track {
    background: transparent;
}

.mpd-aside-column-container::-webkit-scrollbar-thumb {
    background: rgba(0,0,0,0.15);
    border-radius: 2px;
}

.mpd-plan-overview-panel {
    margin-top: 20px;
    margin-bottom: 16px;
}

.mpd-selected-recipe-heading {
    display: block;
    margin: 0 0 10px 0;
    padding: 0 2px;
    font-size: 0.78rem;
    font-weight: 600;
    line-height: 1.3;
    color: #667085;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.mpd-value {
    font-size: var(--text-section-title);
    color: #555;
    margin-bottom: 16px;
}

.mpd-plan-overview-text {
    margin-top: 8px;
}

.mpd-plan-overview-text.skeleton {
    min-height: 60px;
    display: block;
    width: 100%;
}

.mpd-selected-recipe-panel {
    max-width: 500px;
    background: #FFFFFF;
    border: 1px solid #F0F2F4;
    border-radius: 20px;
    padding: 14px;
    box-sizing: border-box;
    overflow: hidden;
    box-shadow: 0 1px 2px rgba(16, 24, 40, 0.04);
    min-height: 320px;
}

/* ──────────────────────────────────────────────────────────────────────────
   RESPONSIVE
   ────────────────────────────────────────────────────────────────────────── */

@media only screen and (max-width: 992px) {
    .mpd-aside-column {
        display: none;
    }
}

@media only screen and (max-width: 600px) {
    .mpd-video-modal-card {
        max-width: 100%;
        border-radius: 16px;
    }

    .mpd-video-modal-player {
        min-height: 200px;
    }

    .mpd-family-size-wrap {
        gap: 8px;
    }

    .mpd-family-change-link,
    .mpd-family-done-link {
        font-size: 0.84rem;
    }

    .mpd-start-plan-btn {
        min-height: 46px;
        font-size: 0.95rem;
    }
}

@media (max-width: 480px) {
    .mpd-summary-card {
        padding: 12px 14px;
    }

    .mpd-summary-meta {
        font-size: 12px !important;
    }

    .mpd-summary-total {
        font-size: 14px !important;
    }

    .mpd-summary-side {
        text-align: left;
        margin-top: 4px;
    }
}

.mpd-selected-recipe-empty {
    display: block;
    padding: 24px 18px;
    border: 1px dashed #dde3e8;
    border-radius: 18px;
    background: linear-gradient(180deg, #fcfcfd 0%, #f8fafb 100%);
    font-size: 0.92rem;
    line-height: 1.55;
    color: #667085;
    text-align: center;
}

.mpd-selected-host {
    width: 100%;
    min-height: 240px;
    margin-top: 12px;
}

.mpd-schedule--loading {
    min-height: 420px;   /* ~2 day blocks */
    position: relative;
}

.mpd-schedule--loading::after {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(
            110deg,
            #f3f3f3 8%,
            #fafafa 18%,
            #f3f3f3 33%
    );
    background-size: 200% 100%;
    animation: 1.5s shine linear infinite;
    border-radius: 12px;
}

.mpd-video-modal-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.62);
    z-index: 9999;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 24px;
}


.mpd-video-modal-overlay--open {
    opacity: 1;
}

.mpd-video-modal-player,
.mpd-video-modal-host > * {
    width: 100%;
    height: 100%;
    min-height: 405px;
    box-sizing: border-box;
}

.mpd-video-modal-player .material-panel,
.mpd-video-modal-host .material-panel {
    width: 100%;
    height: 100%;
}

.meal-plan-video--modal {
    width: 100%;
    min-height: 405px;
}

.meal-plan-video--modal iframe {
    width: 100% !important;
    height: 405px !important;
    display: block;
    border: 0;
}

.meal-plan-video--inline {
    width: 100%;
}

.meal-plan-video--inline iframe {
    width: 100% !important;
    min-height: 220px;
    display: block;
    border: 0;
}



.mpd-replacement-option-card {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px;
    border: 1px solid #edf0f2;
    border-radius: 18px;
    background: #fff;
    cursor: pointer;
}

.mpd-replacement-option-image {
    width: 72px;
    height: 72px;
    min-width: 72px;
    border-radius: 14px;
    object-fit: cover;
}

.mpd-replacement-option-main {
    display: flex;
    flex-direction: column;
    gap: 4px;
    flex: 1;
    min-width: 0;
}

.mpd-replacement-picker-root {
    display: flex;
    flex-direction: column;
    gap: 18px;
}

.mpd-replacement-picker-context {
    font-size: 1rem;
    font-weight: 700;
    color: #111827;
    line-height: 1.35;
}

.mpd-replacement-picker-helper {
    font-size: 0.9rem;
    color: #667085;
    line-height: 1.5;
    margin-top: -8px;
}

.mpd-replacement-picker-section {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.mpd-replacement-picker-heading {
    font-size: 0.92rem;
    font-weight: 700;
    color: #111827;
    line-height: 1.35;
}

.mpd-replacement-picker-heading--small {
    font-size: 0.86rem;
}

.mpd-replacement-picker-subheading {
    font-size: 0.84rem;
    color: #667085;
    line-height: 1.45;
    margin-top: -4px;
}

.mpd-replacement-picker-search-block {
    display: flex;
    flex-direction: column;
    gap: 8px;
    padding-top: 4px;
}

.mpd-replacement-picker-search {
    width: 100%;
}

.mpd-replacement-picker-options {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.mpd-replacement-picker-empty {
    display: block;
    padding: 14px 16px;
    border: 1px dashed #dbe3e8;
    border-radius: 16px;
    background: #fafbfc;
    font-size: 0.9rem;
    line-height: 1.5;
    color: #667085;
    text-align: center;
}

.mpd-replacement-option-card:hover {
    border-color: #d6e4d8;
    box-shadow: 0 6px 18px rgba(16, 24, 40, 0.08);
    transform: translateY(-1px);
}

.mpd-replacement-option-main {
    display: flex;
    flex-direction: column;
    gap: 4px;
    min-width: 0;
    flex: 1;
}

.mpd-replacement-option-title {
    font-size: 0.98rem;
    font-weight: 700;
    color: #111827;
    line-height: 1.35;
}

.mpd-replacement-option-meta {
    font-size: 0.84rem;
    color: #6b7280;
    line-height: 1.4;
}

.mpd-replacement-option-tag {
    display: inline-block;
    width: fit-content;
    padding: 3px 8px;
    border-radius: 999px;
    background: #eef7ef;
    color: var(--PRIMARY_CTA, #1B5E20);
    font-size: 0.76rem;
    font-weight: 600;
    line-height: 1.3;
}

.mpd-replacement-option-reason {
    font-size: 0.86rem;
    color: #374151;
    line-height: 1.45;
}

.mpd-replacement-option-chevron {
    color: #98a2b3;
    flex: 0 0 auto;
}






.mpd-recipe-details-container {
    display: flex;
    flex-direction: column;
    gap: 14px;
    padding: 0 16px 20px;
    background: #fff;
}

.mpd-recipe-hero-wrap {
    position: relative;
    margin: 0 -16px;
}

.mpd-recipe-hero-image {
    width: 100%;
    display: block;
    object-fit: cover;
    border-radius: 18px;
    max-height: 280px;
}

.mpd-recipe-watch-overlay {
    position: absolute;
    right: 14px;
    bottom: 14px;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 10px 14px;
    border-radius: 999px;
    background: rgba(255,255,255,0.96);
    box-shadow: 0 8px 24px rgba(0,0,0,0.14);
    cursor: pointer;
}

.mpd-recipe-watch-overlay-icon {
    font-size: 18px;
    color: var(--PRIMARY_CTA, #1B5E20);
}

.mpd-recipe-watch-overlay-text {
    font-size: 0.92rem;
    font-weight: 600;
    color: #111827;
}

.mpd-recipe-top-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.mpd-recipe-chip {
    display: inline-flex;
    align-items: center;
    padding: 6px 10px;
    border-radius: 999px;
    font-size: 0.78rem;
    font-weight: 600;
}

.mpd-recipe-chip-effort {
    background: #f6eadb;
    color: #c65d00;
}

.mpd-recipe-chip-cost {
    background: #e7f0ff;
    color: #1357c5;
}

.mpd-recipe-chip-nutrition {
    background: #eef7ef;
    color: #1B5E20;
}

.mpd-recipe-title {
    font-size: 2rem;
    line-height: 1.1;
    font-weight: 700;
    color: #111827;
    margin: 2px 0 0;
}

.mpd-recipe-byline-row {
    display: flex;
    align-items: center;
    gap: 2px;
    font-size: 0.98rem;
    color: #111827;
}

.mpd-recipe-byline-prefix {
    color: #111827;
}

.mpd-recipe-byline-author {
    color: #111827;
    font-weight: 600;
    text-decoration: underline;
}

.mpd-recipe-date {
    font-size: 0.96rem;
    color: #374151;
    margin-top: -4px;
}

.mpd-recipe-summary {
    font-size: 1rem;
    line-height: 1.65;
    color: #1f2937;
}

.mpd-recipe-stats-bar {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    border: 1px solid #e7ecef;
    border-radius: 16px;
    overflow: hidden;
}

.mpd-recipe-stat-item {
    padding: 14px 10px;
    text-align: center;
    background: #fff;
    border-right: 1px solid #eef2f5;
}

.mpd-recipe-stat-item:last-child {
    border-right: none;
}

.mpd-recipe-stat-value {
    display: block;
    font-size: 1.05rem;
    font-weight: 700;
    color: #111827;
    margin-bottom: 4px;
}

.mpd-recipe-stat-label {
    color: #6b7280;
}

.mpd-recipe-section {
    padding-top: 4px;
}

.mpd-recipe-section-title {
    margin-bottom: 12px;
}

.mpd-recipe-ingredients-list,
.mpd-recipe-steps {
    line-height: 1.7;
    color: #111827;
}

.mpd-recipe-ingredient-row {
    padding: 0 0 8px;
}

.mpd-recipe-note {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    padding: 14px;
    border-radius: 14px;
    background: #eef7ef;
}

.mpd-recipe-note-icon {
    color: var(--PRIMARY_CTA, #1B5E20);
}

.mpd-recipe-note-text {
    color: #1f2937;
}

.mpd-recipe-utility-bar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
    padding: 12px 0 0;
    border-top: 1px solid #edf0f2;
    margin-top: 6px;
}

.mpd-recipe-utility-btn {
    flex: 1;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    min-height: 42px;
    border: none;
    border-radius: 999px;
    background: #fff;
    color: var(--PRIMARY_CTA, #1B5E20);
    font-weight: 600;
    cursor: pointer;
}

.mpd-recipe-utility-btn.is-saved,
.mpd-recipe-utility-btn.is-saved span,
.mpd-recipe-utility-btn.is-saved i {
    color: var(--PRIMARY_CTA, #1B5E20);
}

@media only screen and (max-width: 600px) {
    .mpd-recipe-details-container {
        padding: 0 24px 24px;
    }

    .mpd-recipe-hero-wrap {
        margin-left: -26px;
        margin-right: -26px;
    }

    .mpd-recipe-hero-image {
        width: 100%;
        height: 280px;
        min-height: 280px;
        max-height: 280px;
        border-radius: 0px;
        display: block;
        object-fit: cover;
    }

    .mpd-recipe-header-block {
        display: flex;
        flex-direction: column;
        gap: 6px;
        padding: 12px;
    }

    .mpd-recipe-title {
        margin: 0 !important;
        line-height: 1.08;
    }


    .mpd-recipe-utility-bar {
        position: sticky;
        bottom: 0;
        background: rgba(255,255,255,0.98);
        padding: 12px 0 calc(12px + env(safe-area-inset-bottom));
    }
}

/* ──────────────────────────────────────────────────────────────────────────
   SKELETON SHIMMER UTILITY
   Used by RecipeDetailsSkeletonView and any future skeleton screens.
   ────────────────────────────────────────────────────────────────────────── */

@keyframes mpd-shine {
    0%   { background-position: 200% center; }
    100% { background-position: -200% center; }
}

.mpd-skeleton {
    display: block;
    border-radius: 6px;
    background: linear-gradient(
            110deg,
            rgba(0, 0, 0, 0.05) 8%,
            rgba(0, 0, 0, 0.10) 18%,
            rgba(0, 0, 0, 0.05) 33%
    );
    background-size: 200% 100%;
    animation: mpd-shine 1.5s linear infinite;
    /* Prevent text / child content from being visible */
    color: transparent !important;
    pointer-events: none;
}

.mpd-saved-recipes-page {
    padding: 16px;
    max-width: 720px;
    margin: 0 auto;
}

.mpd-saved-recipes-title {
    font-size: 1.5rem;
    font-weight: 700;
    color: #111827;
    margin-bottom: 16px;
    display: block;
}

.mpd-saved-recipes-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.mpd-saved-recipe-row {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 12px;
    border: 1px solid #edf0f2;
    border-radius: 16px;
    background: #fff;
    cursor: pointer;
    transition: box-shadow 0.15s ease;
}

.mpd-saved-recipe-row:hover {
    box-shadow: 0 4px 16px rgba(0,0,0,0.08);
}

.mpd-saved-recipe-row-image {
    width: 72px;
    height: 72px;
    min-width: 72px;
    border-radius: 12px;
    object-fit: cover;
}

.mpd-saved-recipe-row-info {
    display: flex;
    flex-direction: column;
    gap: 4px;
    flex: 1;
    min-width: 0;
}

.mpd-saved-recipe-row-title {
    font-size: 0.98rem;
    font-weight: 700;
    color: #111827;
    line-height: 1.35;
}

.mpd-saved-recipe-row-meta {
    font-size: 0.84rem;
    color: #6b7280;
}

.mpd-saved-recipes-empty {
    padding: 32px 16px;
    text-align: center;
    color: #6b7280;
    font-size: 0.95rem;
    line-height: 1.6;
    border: 1px dashed #dde3e8;
    border-radius: 16px;
    background: #fafbfc;
}

.mpd-saved-recipe-skeleton-row {
    height: 96px;
    border-radius: 16px;
    margin-bottom: 12px;
    background: linear-gradient(110deg, rgba(0,0,0,0.05) 8%, rgba(0,0,0,0.10) 18%, rgba(0,0,0,0.05) 33%);
    background-size: 200% 100%;
    animation: mpd-shine 1.5s linear infinite;
}

.mpd-saved-recipes-header {
    margin-bottom: 16px;
}

.mpd-saved-recipes-skeleton {
    display: flex;
    flex-direction: column;
}
.mpd-saved-recipes-empty-text {
    color: #6b7280;
    font-size: 0.95rem;
    line-height: 1.6;
    display: block;
    text-align: center;
}

/* Container for the text area below the image */
.mpd-desktop-recipe-main-content {
    display: flex;
    flex-direction: column;
    padding: 12px 16px;
    background-color: #ffffff;
    /* Ensures the content area fills the card if the title is short */
    flex: 1 0 auto;
}

/* Meta wrapper (Dot + Meal Type Label) */
.mpd-desktop-recipe-meta {
    display: flex;
    align-items: center;
    gap: 8px; /* Space between dot and text */
    margin-bottom: 4px;
    opacity: 0.8;
}

/* The Meal Type Text specifically on desktop */
.mpd-desktop-recipe-meta .mpd-meal-type-text {
    font-size: 11px;
    letter-spacing: 0.8px;
    font-weight: 700;
    text-transform: uppercase;
    color: #757575;
}

/* The action icon (More Vert) positioned over the image */
.mpd-desktop-recipe-icon {
    color: #424242 !important;
    cursor: pointer;
    padding: 6px;
    background: rgba(255, 255, 255, 0.9);
    border-radius: 50%;
    /* Subtle shadow to make it pop against varying recipe images */
    box-shadow: 0 2px 4px rgba(0,0,0,0.12);
    transition: background 0.2s ease;
}

.mpd-desktop-recipe-icon:hover {
    background: #ffffff;
    box-shadow: 0 4px 8px rgba(0,0,0,0.2);
}


/* Card Container */
.mpd-desktop-recipe-card {
    display: flex;
    flex-direction: column;
    height: auto;
    border-radius: 8px;
    overflow: hidden;
    background: #fff;
    transition: transform 0.2s ease;
}

.mpd-desktop-recipe-card:hover {
    transform: translateY(-4px);
}

/* Media/Image Handling */
.mpd-desktop-recipe-media-wrap {
    width: 100%;
    height: 250px; /* Fixed height for consistent grid look */
    position: relative;
    overflow: hidden;
}

.mpd-desktop-recipe-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* Floating Action Button */
.mpd-desktop-recipe-action-overlay {
    position: absolute;
    top: 8px;
    right: 8px;
    background: rgba(255, 255, 255, 0.9);
    border-radius: 50%;
    padding: 4px;
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
}

/* Content Padding */
.mpd-desktop-recipe-content-wrap {
    padding: 12px;
    flex-grow: 1;
}

.mpd-desktop-recipe-title {
    font-size: 1.1rem;
    font-weight: 600;
    margin-top: 8px;
    display: block;
}

.mpd-desktop-recipe-cost {
    color: #666;
    font-size: 0.9rem;
    margin-top: 4px;
}

.mpd-pantry-dialog-content {
    width: 100%;
    height: 100%;
    box-sizing: border-box;
    padding: 0 16px 16px 16px;
    display: flex;
    flex-direction: column;
    gap: 0;
    overflow: hidden;
}

@media only screen and (max-width: 768px) {
    .mpd-pantry-dialog-content {
        padding: 14px 14px 14px 14px;
    }
}


/* ═══════════════════════════════════════════════════════════
   PantryCheckDialog + PantryItemRow
   ═══════════════════════════════════════════════════════════ */

/* ── PopupPanel host — GWT positions this; we override to fill screen ── */
.pantry-popup-host {
    position: fixed !important;
    inset: 0 !important;
    width: 100% !important;
    height: 100% !important;
    z-index: 1050 !important;
    background: none !important;
    border: none !important;
    padding: 0 !important;
    overflow: visible !important;
}

/* ── backdrop — the UiBinder root inside PopupPanel ── */
.pantry-sheet-backdrop {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: flex-end;
    background: rgba(0, 0, 0, 0);
    transition: background 280ms ease;
    pointer-events: none;
}
.pantry-sheet-backdrop--visible {
    background: rgba(0, 0, 0, 0.38);
    pointer-events: all;
}

/* ── sheet ── */
.pantry-sheet {
    width: 100%;
    max-height: 82vh;
    display: flex;
    flex-direction: column;
    background: #fff;
    border-radius: 20px 20px 0 0;
    transform: translateY(100%);
    transition: transform 300ms cubic-bezier(0.32, 0.72, 0, 1);
}
.pantry-sheet-backdrop--visible .pantry-sheet {
    transform: translateY(0);
}

/* ── drag handle ── */
.pantry-sheet-handle-wrap {
    display: flex;
    justify-content: center;
    padding: 10px 0 4px;
    flex-shrink: 0;
}
.pantry-sheet-handle-bar {
    width: 36px;
    height: 4px;
    border-radius: 2px;
    background: rgba(0, 0, 0, 0.16);
}

/* ── header ── */
.pantry-sheet-header {
    padding: 4px 16px 14px;
    border-bottom: 0.5px solid rgba(0, 0, 0, 0.1);
    flex-shrink: 0;
}
.pantry-sheet-title {
    display: block;
    font-size: 15px !important;
    font-weight: 500 !important;
    color: rgba(0, 0, 0, 0.87) !important;
    line-height: 1.3 !important;
    margin: 0 0 3px !important;
    padding: 0 !important;
}
.pantry-sheet-sub {
    display: block;
    top: 15px;
    font-size: 15px !important;
    color: rgba(0, 0, 0, 0.5) !important;
    line-height: 1.45 !important;
    margin: 0 !important;
    padding: 0 !important;
    position: sticky;
    top: 0;
}

/* ── scrollable body ── */
.pantry-sheet-scroll {
    margin-top: 10px;
    flex: 1;
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
}
.pantry-sheet-items {
    display: flex;
    flex-direction: column;
}

/* ── category label ── */
.pantry-cat-label {
    display: block;
    font-size: 11px !important;
    font-weight: 500 !important;
    color: rgba(0, 0, 0, 0.38) !important;
    text-transform: uppercase;
    letter-spacing: .07em;
    padding: 12px 16px 5px !important;
    line-height: 1 !important;
    margin: 0 !important;
}

/* ── item row ── */
.pantry-item-row {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 16px;
    border-bottom: 0.5px solid rgba(0, 0, 0, 0.07);
    cursor: pointer;
    -webkit-tap-highlight-color: transparent;
    transition: background 120ms;
}
.pantry-item-row:active {
    background: rgba(0, 0, 0, 0.04);
}

/* ── icon placeholder ── */
.pantry-item-icon {
    width: 32px;
    height: 32px;
    min-width: 32px;
    border-radius: 8px;
    background: rgba(0, 0, 0, 0.05);
    flex-shrink: 0;
}

/* ── name ── */
.pantry-item-name {
    flex: 1;
    min-width: 0;
    font-size: 13px !important;
    font-weight: 400 !important;
    color: rgba(0, 0, 0, 0.87) !important;
    line-height: 1.3 !important;
    margin: 0 !important;
    padding: 0 !important;
    transition: color 150ms;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* ── quantity ── */
.pantry-item-qty {
    font-size: 11px !important;
    font-weight: 400 !important;
    color: rgba(0, 0, 0, 0.38) !important;
    white-space: nowrap;
    flex-shrink: 0;
    margin: 0 4px 0 0 !important;
    padding: 0 !important;
    line-height: 1 !important;
}

/* ── checked state ── */
.pantry-item-row--checked .pantry-item-name {
    color: rgba(0, 0, 0, 0.35) !important;
    text-decoration: line-through;
}

/* ── checkbox circle ── */
.pantry-item-chk {
    width: 22px;
    height: 22px;
    min-width: 22px;
    border-radius: 50%;
    border: 1.5px solid rgba(0, 0, 0, 0.22);
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    transition: background 150ms, border-color 150ms;
}
.pantry-item-chk--on {
    background: #1D9E75;
    border-color: #1D9E75;
}

/* ── tick icon ── */
.pantry-item-tick {
    display: none !important;
    font-size: 14px !important;
    line-height: 1 !important;
    color: #fff !important;
    margin: 0 !important;
    padding: 0 !important;
}
.pantry-item-chk--on .pantry-item-tick {
    display: flex !important;
}
.pantry-item-chk--on .pantry-item-tick i,
.pantry-item-chk--on .pantry-item-tick .material-icons {
    color: #fff !important;
    font-size: 14px !important;
    line-height: 1 !important;
}

/* ── footer ── */
.pantry-sheet-footer {
    flex-shrink: 0;
    display: flex;
    flex-direction: column;
    padding: 12px 16px 24px;
    border-top: 0.5px solid rgba(0, 0, 0, 0.1);
    background: #fff;
    position: static;
    bottom: 0;
}
.pantry-excluded-bar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 10px;
}
.pantry-excluded-label {
    font-size: 12px !important;
    color: rgba(0, 0, 0, 0.5) !important;
    margin: 0 !important;
    padding: 0 !important;
}
.pantry-excluded-badge {
    font-size: 12px !important;
    font-weight: 500 !important;
    color: #0F6E56 !important;
    background: #E1F5EE;
    padding: 2px 10px !important;
    border-radius: 10px;
    line-height: 1.6 !important;
    margin: 0 !important;
}

/* ── desktop guard ── */
@media (min-width: 993px) {
    .pantry-sheet-backdrop {
        display: none;
    }
}
.pantry-empty-label {
    display: block;
    text-align: center;
    color: #98A2B3;
    font-size: 14px;
    padding: 32px 16px;
    line-height: 1.6;
}
/* ── thumbnail ── */
.pantry-item-thumb {
    width: 40px;
    min-width: 40px;
    height: 40px;
    border-radius: 8px;
    overflow: hidden;
    background: rgba(0, 0, 0, .06);
    flex-shrink: 0;
}
.pantry-item-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}
.pantry-item-thumb--placeholder {
    background: rgba(0, 0, 0, .06);
}

/* ── checkbox ── */
.pantry-item-checkbox {
    flex-shrink: 0;
    margin: 0 !important;
    padding: 0 !important;
    width: 24px !important;
    min-width: 24px !important;
}
.pantry-item-checkbox label {
    padding: 0 !important;
    margin: 0 !important;
    height: 24px !important;
    line-height: 24px !important;
}
/* hide the text node gap GWT Material adds next to the checkbox */
.pantry-item-checkbox label span {
    display: none !important;
}
.pantry-sheet-helper {
    font-size: 13px;
    line-height: 1.45;
    color: #667085;
    padding: 0px 15px;
}

.pantry-excluded-savings {
    font-size: 12px;
    font-weight: 600;
    color: var(--PRIMARY_CTA, #1B5E20);
    margin-left: auto;
}

.pantry-status-bar {
    background: #F6FBF6;
    border-radius: 12px;
    padding: 12px;
    margin-bottom: 12px;
}

.pantry-status-title {
    font-size: 14px;
    font-weight: 600;
    color: #1B5E20;
    margin-bottom: 4px;
}

.pantry-status-summary {
    font-size: 13px;
    color: #555;
    margin-bottom: 4px;
}

.pantry-live-feedback {
    font-size: 12px;
    color: #1B5E20;
}