/* ── Recommendations ── */
      .mc-rec-bar {
        background: linear-gradient(135deg, rgba(29,107,74,.06) 0%, rgba(29,107,74,.10) 100%);
        border: 1px solid rgba(29,107,74,.12);
        border-radius: 14px; padding: 18px 22px; margin-bottom: 22px;
        animation: cfFadeUp .4s ease-out both;
      }
      .mc-rec-bar h3 {
        font-size: .78rem; font-weight: 700; color: var(--accent-mid);
        text-transform: uppercase; letter-spacing: .6px; margin: 0 0 10px;
      }
      .mc-rec-bar h3 svg { vertical-align: -2px; margin-right: 4px; }
      .mc-rec-pills { display: flex; flex-wrap: wrap; gap: 8px; }
      .mc-rec-pill {
        display: inline-flex; align-items: center; gap: 6px;
        background: #fff; border: 1px solid rgba(29,107,74,.15);
        border-radius: 50px; padding: 7px 16px; font-size: .8rem;
        font-weight: 600; color: #123f2e; cursor: pointer;
        transition: all .25s cubic-bezier(.4,0,.2,1);
      }
      .mc-rec-pill:hover {
        background: rgba(29,107,74,.08); border-color: var(--accent-mid);
        transform: translateY(-1px); box-shadow: 0 3px 10px rgba(29,107,74,.12);
      }
      .mc-rec-pill span.mc-rec-icon { font-size: 1rem; }

      /* ── Challenge Grid ── */
      .mc-grid {
        display: grid; grid-template-columns: 1fr 1fr; gap: 16px;
        margin-bottom: 24px;
      }
      .mc-card {
        background: #fff; border: 1px solid rgba(29,107,74,.08);
        border-radius: 16px; padding: 22px;
        box-shadow: 0 1px 3px rgba(0,0,0,.04), 0 4px 12px rgba(29,107,74,.04);
        transition: all .25s cubic-bezier(.4,0,.2,1);
        animation: cfFadeUp .4s ease-out both;
        position: relative; overflow: hidden;
      }
      .mc-card:nth-child(2) { animation-delay: .06s; }
      .mc-card:nth-child(3) { animation-delay: .12s; }
      .mc-card:nth-child(4) { animation-delay: .14s; }
      .mc-card:hover {
        box-shadow: 0 4px 20px rgba(29,107,74,.1), 0 1px 3px rgba(0,0,0,.04);
        border-color: rgba(29,107,74,.15); transform: translateY(-2px);
      }
      .mc-card-icon { font-size: 1.6rem; margin-bottom: 8px; }
      .mc-card-title {
        font-size: .95rem; font-weight: 700; color: #123f2e;
        margin-bottom: 4px; letter-spacing: -.2px;
      }
      .mc-card-desc {
        font-size: .8rem; color: #6b7280; line-height: 1.45;
        margin-bottom: 14px;
      }
      .mc-badge {
        display: inline-block; padding: 3px 10px; border-radius: 50px;
        font-size: .68rem; font-weight: 700; letter-spacing: .3px;
        margin-bottom: 12px;
      }
      .mc-badge--2  { background: #fef3c7; color: #92400e; }
      .mc-badge--7  { background: #dbeafe; color: #1e40af; }
      .mc-badge--14 { background: #ede9fe; color: #5b21b6; }
      .mc-badge--30 { background: #fce7f3; color: #9d174d; }

      .mc-completed-badge {
        display: inline-flex; align-items: center; gap: 4px;
        background: rgba(29,107,74,.08); color: var(--accent-mid);
        font-size: .76rem; font-weight: 700; padding: 6px 14px;
        border-radius: 50px;
      }

      /* ── Buttons ── */
      .mc-btn {
        display: inline-flex; align-items: center; justify-content: center;
        border: none; cursor: pointer; font-family: inherit;
        font-weight: 700; border-radius: 50px; transition: all .25s cubic-bezier(.4,0,.2,1);
        letter-spacing: .2px;
      }
      .mc-btn--primary {
        background: linear-gradient(135deg, #2a7d59 0%, var(--accent-mid) 50%, #16543a 100%);
        color: #fff; font-size: .8rem; padding: 10px 24px;
        box-shadow: 0 3px 12px rgba(29,107,74,.25);
      }
      .mc-btn--primary:hover {
        transform: translateY(-2px); box-shadow: 0 6px 20px rgba(29,107,74,.35);
      }
      .mc-btn--primary:active { transform: scale(.97); }
      .mc-btn--outline {
        background: transparent; border: 2px solid rgba(29,107,74,.2);
        color: var(--accent-mid); font-size: .78rem; padding: 8px 20px;
      }
      .mc-btn--outline:hover {
        background: rgba(29,107,74,.06); border-color: var(--accent-mid);
      }
      .mc-btn--disabled {
        background: #e5e7eb; color: #6b7280; cursor: default;
        box-shadow: none; font-size: .78rem; padding: 10px 24px;
      }
      .mc-btn--disabled:hover { transform: none; box-shadow: none; }

      /* ── Active Challenge Card ── */
      .mc-active-card {
        /* White interior (padding-box) + a STATIC green gradient border (border-box).
           Replaces the old moving gradient that bled across the whole card and made
           the text hard to read. */
        background:
          linear-gradient(#fff, #fff) padding-box,
          linear-gradient(135deg, #2a7d59, #8fbf9c) border-box;
        border-radius: 18px; padding: 26px;
        margin-bottom: 24px; position: relative; overflow: hidden;
        border: 2px solid transparent;
        box-shadow: 0 4px 24px rgba(29,107,74,.12), 0 1px 3px rgba(0,0,0,.04);
        animation: cfFadeUp .4s ease-out both;
      }
      .mc-active-card::before { content: none; }
      @keyframes mcGradientShift {
        0% { background-position: 0% 50%; }
        50% { background-position: 100% 50%; }
        100% { background-position: 0% 50%; }
      }
      .mc-active-header {
        display: flex; align-items: center; gap: 14px; margin-bottom: 16px;
      }
      .mc-active-icon { font-size: 2rem; }
      .mc-active-title { font-size: 1.15rem; font-weight: 800; color: #123f2e; letter-spacing: -.3px; }
      .mc-active-subtitle { font-size: .78rem; color: #6b7280; margin-top: 2px; }

      /* Progress bar */
      .mc-progress-wrap { margin-bottom: 16px; }
      .mc-progress-label {
        display: flex; justify-content: space-between; margin-bottom: 6px;
        font-size: .74rem; font-weight: 600; color: #6b7280;
      }
      .mc-progress-label span:last-child { color: var(--accent-mid); }
      .mc-progress-bar {
        height: 10px; background: rgba(29,107,74,.08); border-radius: 50px;
        overflow: hidden;
      }
      .mc-progress-fill {
        height: 100%; border-radius: 50px;
        background: linear-gradient(90deg, #2a7d59, var(--accent-mid));
        transition: width .5s cubic-bezier(.4,0,.2,1);
      }

      /* Streak */
      .mc-streak {
        display: inline-flex; align-items: center; gap: 6px;
        font-size: .9rem; font-weight: 800; color: #f59e0b;
        margin-bottom: 16px;
      }

      /* Check-in calendar row */
      .mc-calendar { display: flex; gap: 6px; flex-wrap: wrap; margin-bottom: 18px; }
      .mc-cal-day {
        width: 32px; height: 32px; border-radius: 50%;
        display: flex; align-items: center; justify-content: center;
        font-size: .62rem; font-weight: 700; color: #6b7280;
        background: #f3f4f6; transition: all .2s;
        position: relative;
      }
      .mc-cal-day--done {
        background: linear-gradient(135deg, #2a7d59, var(--accent-mid)); color: #fff;
        box-shadow: 0 2px 6px rgba(29,107,74,.25);
      }
      .mc-cal-day--today {
        border: 2px solid var(--accent-mid);
        animation: cfPulseGreen 2s infinite;
      }
      .mc-cal-day--future { background: #f9fafb; color: #d1d5db; }

      /* Check-in button */
      .mc-checkin-area { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; }
      .mc-checkin-btn {
        min-width: 180px; height: 52px;
        background: linear-gradient(135deg, #2a7d59 0%, var(--accent-mid) 50%, #16543a 100%);
        border: none; color: #fff; font-size: .9rem; font-weight: 800;
        border-radius: 50px; cursor: pointer; position: relative;
        box-shadow: 0 4px 16px rgba(29,107,74,.3);
        transition: all .3s cubic-bezier(.4,0,.2,1);
        overflow: hidden;
      }
      .mc-checkin-btn:hover {
        transform: translateY(-3px) scale(1.03);
        box-shadow: 0 8px 28px rgba(29,107,74,.4);
      }
      .mc-checkin-btn:active { transform: scale(.97); }
      .mc-checkin-btn--done {
        background: #e5e7eb; color: #6b7280; cursor: default;
        box-shadow: none;
      }
      .mc-checkin-btn--done:hover { transform: none; box-shadow: none; }

      .mc-checkin-anim {
        position: absolute; inset: 0;
        display: flex; align-items: center; justify-content: center;
        background: var(--accent-mid); opacity: 0; transition: opacity .3s;
      }
      .mc-checkin-anim--show { opacity: 1; }
      .mc-checkin-anim svg { width: 28px; height: 28px; stroke: #fff; stroke-width: 3; fill: none; }

      .mc-note-input {
        flex: 1; min-width: 200px; padding: 12px 16px;
        border: 2px solid rgba(29,107,74,.1); border-radius: 12px;
        font-size: .82rem; font-family: inherit; color: #111827;
        background: rgba(29,107,74,.02); transition: all .25s;
      }
      .mc-note-input:focus {
        outline: none; border-color: var(--accent-mid); background: #fff;
        box-shadow: 0 0 0 4px rgba(29,107,74,.1);
      }
      .mc-note-input::placeholder { color: #a1a1aa; }

      /* Abandon link */
      .mc-abandon {
        display: inline-block; margin-top: 12px;
        font-size: .74rem; color: #6b7280; cursor: pointer;
        text-decoration: underline; transition: color .2s;
      }
      .mc-abandon:hover { color: #ef4444; }

      /* ── Section label ── */
      .mc-section-label {
        font-size: .7rem; font-weight: 700; color: var(--accent-mid);
        text-transform: uppercase; letter-spacing: 1.2px;
        margin-bottom: 12px; margin-top: 8px;
      }

      /* ── Celebration Overlay ── */
      .mc-celebration {
        position: fixed; inset: 0; z-index: 9999;
        background: rgba(0,0,0,.55); backdrop-filter: blur(6px);
        display: flex; align-items: center; justify-content: center;
        animation: mcCelebFade .4s ease-out;
      }
      @keyframes mcCelebFade { from { opacity: 0; } to { opacity: 1; } }
      .mc-celebration-inner {
        background: #fff; border-radius: 24px; padding: 40px 44px;
        text-align: center; max-width: 440px; width: 90%;
        box-shadow: 0 24px 80px rgba(0,0,0,.2);
        position: relative; overflow: hidden;
        animation: cfFadeUp .5s cubic-bezier(.4,0,.2,1);
      }
      .mc-celebration-title {
        font-size: 1.6rem; font-weight: 800; color: #123f2e;
        margin-bottom: 8px; letter-spacing: -.3px;
      }
      .mc-celebration-sub {
        font-size: .9rem; color: #6b7280; margin-bottom: 12px;
      }
      .mc-celebration-streak {
        font-size: 1.1rem; font-weight: 800; color: #f59e0b;
        margin-bottom: 16px;
      }
      .mc-celebration-next {
        font-size: .82rem; color: var(--accent-mid); font-weight: 600;
      }
      .mc-confetti-zone {
        position: absolute; inset: 0; pointer-events: none; overflow: hidden;
      }
      .mc-confetti {
        position: absolute; font-size: 1.4rem;
        animation: mcConfettiBurst 1.2s cubic-bezier(.25,.46,.45,.94) forwards;
      }
      @keyframes mcConfettiBurst {
        0%   { opacity: 1; transform: translate(0, 0) scale(1) rotate(0deg); }
        100% { opacity: 0; transform: translate(var(--tx), var(--ty)) scale(.4) rotate(var(--rot)); }
      }

      /* ── Motivational messages ── */
      .mc-motivation {
        font-size: .82rem; font-weight: 600; font-style: italic;
        color: var(--accent-mid); margin-bottom: 14px;
        padding: 10px 16px; background: rgba(29,107,74,.04);
        border-radius: 10px; border-left: 3px solid #2a7d59;
      }

      /* ── Notification Banner ── */
      .mc-notif-banner {
        display: flex; align-items: center; gap: 14px;
        background: linear-gradient(135deg, rgba(18,63,46,.04) 0%, rgba(29,107,74,.08) 100%);
        border: 1px solid rgba(29,107,74,.15);
        border-radius: 14px; padding: 16px 20px; margin-bottom: 20px;
        animation: cfFadeUp .4s ease-out both;
      }
      .mc-notif-banner__icon {
        width: 42px; height: 42px; border-radius: 50%; flex-shrink: 0;
        background: linear-gradient(135deg, #2a7d59, var(--accent-mid));
        display: flex; align-items: center; justify-content: center;
      }
      .mc-notif-banner__text {
        flex: 1;
      }
      .mc-notif-banner__title {
        font-size: .88rem; font-weight: 700; color: #123f2e; margin-bottom: 2px;
      }
      .mc-notif-banner__sub {
        font-size: .78rem; color: #6b7280; line-height: 1.4;
      }
      .mc-notif-banner__actions {
        display: flex; gap: 8px; flex-shrink: 0;
      }
      .mc-notif-banner__btn {
        padding: 8px 18px; border-radius: 50px; border: none;
        font-family: inherit; font-weight: 700; font-size: .78rem;
        cursor: pointer; transition: all .2s;
      }
      .mc-notif-banner__btn--yes {
        background: linear-gradient(135deg, #2a7d59, var(--accent-mid));
        color: #fff; box-shadow: 0 2px 8px rgba(29,107,74,.2);
      }
      .mc-notif-banner__btn--yes:hover {
        transform: translateY(-1px); box-shadow: 0 4px 14px rgba(29,107,74,.3);
      }
      .mc-notif-banner__btn--no {
        background: transparent; color: #6b7280;
      }
      .mc-notif-banner__btn--no:hover { color: #6b7280; }

      .mc-notif-active {
        display: flex; align-items: center; gap: 10px;
        background: rgba(29,107,74,.06); border: 1px solid rgba(29,107,74,.12);
        border-radius: 10px; padding: 12px 16px; margin-bottom: 20px;
        font-size: .82rem; color: #123f2e;
        animation: cfFadeUp .4s ease-out both;
      }
      .mc-notif-active svg { flex-shrink: 0; }
      .mc-notif-active__text { flex: 1; font-weight: 600; }
      .mc-notif-active__off {
        font-size: .76rem; color: #6b7280; cursor: pointer;
        text-decoration: underline; background: none; border: none;
        font-family: inherit;
      }
      .mc-notif-active__off:hover { color: #ef4444; }

      /* ── Challenge Modal ── */
      .mc-modal-label {
        display: block; font-size: .78rem; font-weight: 600; color: #123f2e;
        margin-bottom: 6px; letter-spacing: .2px;
      }
      .mc-modal-input {
        width: 100%; padding: 10px 14px; border: 2px solid rgba(29,107,74,.1);
        border-radius: 10px; font-size: .88rem; font-family: inherit;
        background: rgba(29,107,74,.02); color: #111827;
        transition: all .25s; box-sizing: border-box;
      }
      .mc-modal-input:focus {
        outline: none; border-color: var(--accent-mid); background: #fff;
        box-shadow: 0 0 0 4px rgba(29,107,74,.1);
      }
      .mc-emoji-picker {
        display: flex; gap: 6px; flex-wrap: wrap;
      }
      .mc-emoji-opt {
        width: 40px; height: 40px; border-radius: 10px;
        border: 2px solid rgba(29,107,74,.08); background: rgba(29,107,74,.02);
        cursor: pointer; font-size: 1.15rem; display: flex; align-items: center;
        justify-content: center; transition: all .2s;
      }
      .mc-emoji-opt:hover { border-color: rgba(29,107,74,.25); background: rgba(29,107,74,.06); transform: scale(1.08); }
      .mc-emoji-opt--active { border-color: var(--accent-mid); background: rgba(29,107,74,.1); box-shadow: 0 0 0 3px rgba(29,107,74,.15); transform: scale(1.1); }

      /* ── Edit / Delete buttons on cards ── */
      .mc-card-actions {
        display: flex; gap: 6px; position: absolute; top: 10px; right: 10px;
      }
      .mc-card-action-btn {
        width: 30px; height: 30px; border-radius: 8px;
        border: 1px solid rgba(29,107,74,.08); background: rgba(29,107,74,.03);
        cursor: pointer; display: flex; align-items: center; justify-content: center;
        transition: all .2s; color: #6b7280; font-size: .85rem;
      }
      .mc-card-action-btn:hover { background: rgba(29,107,74,.1); color: var(--accent-mid); border-color: rgba(29,107,74,.2); }
      .mc-card-action-btn--del:hover { background: rgba(239,68,68,.08); color: #ef4444; border-color: rgba(239,68,68,.15); }

      /* ── Create Challenge CTA ── */
      .mc-create-cta {
        display: flex; align-items: center; justify-content: center; gap: 8px;
        background: linear-gradient(135deg, rgba(29,107,74,.04), rgba(29,107,74,.08));
        border: 2px dashed rgba(29,107,74,.2); border-radius: 16px;
        padding: 28px; cursor: pointer; transition: all .25s;
        color: var(--accent-mid); font-weight: 700; font-size: .9rem;
      }
      .mc-create-cta:hover {
        background: rgba(29,107,74,.08); border-color: var(--accent-mid);
        transform: translateY(-2px); box-shadow: 0 4px 16px rgba(29,107,74,.1);
      }

      /* ── Custom badge ── */
      .mc-badge--custom { background: #eef4e8; color: var(--accent-mid); }

      /* ── Responsive ── */
      @media (max-width: 768px) {
        .mc-grid { grid-template-columns: 1fr; }
        .mc-active-card { padding: 20px; }
        .mc-checkin-area { flex-direction: column; align-items: stretch; }
        .mc-checkin-btn { width: 100%; }
        .mc-note-input { min-width: 0; }
        .mc-celebration-inner { padding: 28px 24px; }
        .mc-notif-banner { flex-direction: column; text-align: center; gap: 10px; }
        .mc-notif-banner__actions { justify-content: center; }
      }
