/* "See what you're leaving on the table": light calculator under the manager table.
   Inputs a creator knows (size, platform, niche, deals now) on the left; a yearly
   comparison of doing it yourself, a manager and Birdie on the right. */
.mcalc {
  --o: var(--brand-primary, #ff5400);
  --ink: var(--compare-ink, #211712);
  --line: var(--compare-line, #e0cfc4);
  --paper: var(--compare-paper, #fffaf6);
  --mut: #6d4939;
  --tint: #fff1e7;
  display: grid; grid-template-columns: minmax(0, .92fr) minmax(0, 1.08fr);
  margin-top: clamp(1.4rem, 3vw, 2.2rem);
  border: 1px solid var(--line); border-radius: 2rem; overflow: hidden;
  background: var(--paper); color: var(--ink);
  box-shadow: 0 40px 80px -50px rgba(133, 64, 46, .45);
}
.mcalc-in { padding: clamp(1.6rem, 3.4vw, 2.75rem); border-right: 1px solid var(--line); display: flex; flex-direction: column; }

/* CTA sits under the inputs, filling the space the shorter column used to leave empty */
.mcalc-cta { margin-top: auto; padding-top: 1.6rem; border-top: 1px dashed #e6cfc0; display: flex; flex-wrap: wrap; align-items: center; gap: .75rem 1rem; }
.mcalc-cta p { margin: 0; font-size: .9rem; line-height: 1.35; color: var(--mut); max-width: 24ch; }
.mcalc-val.is-zero { color: var(--mut); font-size: 1.6rem; }
/* Phones stack the columns, so the CTA moves under the result instead of above it */
.mcalc-cta--phone { display: none; }
@media (max-width: 760px) {
  .mcalc-in > .mcalc-cta { display: none; }
  .mcalc-cta--phone { display: flex; margin-top: 0; }
  .mcalc-cta--phone p { max-width: none; }
}
.mcalc-out { padding: clamp(1.6rem, 3.4vw, 2.75rem); background: var(--tint); display: flex; flex-direction: column; gap: 1.6rem; }

.mcalc-kick { margin: 0 0 .55rem; font-size: .95rem; color: var(--mut); }
.mcalc-title {
  margin: 0 0 1.6rem; font-family: var(--font-primary-dark); font-weight: 400; text-transform: uppercase;
  font-size: clamp(2.1rem, 4vw, 3.4rem); line-height: .9; letter-spacing: -.005em; color: var(--ink);
}

/* Questions */
.mcalc-q { border: 0; margin: 0 0 1.35rem; padding: 0; min-width: 0; }
.mcalc-q legend, .mcalc-legend { display: block; padding: 0; margin-bottom: .6rem; font-size: 1rem; font-weight: 500; }
.mcalc-chips { display: flex; flex-wrap: wrap; gap: .45rem; }
.mcalc-chips label { position: relative; cursor: pointer; }
.mcalc-chips input { position: absolute; opacity: 0; inset: 0; margin: 0; cursor: pointer; }
.mcalc-chips span {
  display: inline-block; padding: .6rem .95rem; border-radius: 99px; font-size: .95rem; line-height: 1;
  border: 1.5px solid var(--line); background: #fff; transition: background .15s, color .15s, border-color .15s, transform .15s;
}
.mcalc-chips label:hover span { border-color: var(--ink); }
.mcalc-chips input:checked + span { background: var(--ink); border-color: var(--ink); color: #fff; }
.mcalc-chips input:focus-visible + span { outline: 2.5px solid var(--o); outline-offset: 2px; }
.mcalc-chips label:active span { transform: scale(.96); }
.mcalc-select { position: relative; max-width: 18rem; }
.mcalc-select::after { content: ""; position: absolute; right: 1rem; top: 50%; width: .5rem; height: .5rem; border: solid var(--ink); border-width: 0 2px 2px 0; transform: translateY(-70%) rotate(45deg); pointer-events: none; }
.mcalc-select select {
  appearance: none; -webkit-appearance: none; width: 100%; padding: .7rem 2.4rem .7rem 1rem; border-radius: 99px;
  border: 1.5px solid var(--line); background: #fff; color: var(--ink); font: inherit; font-size: .95rem; cursor: pointer;
}
.mcalc-select select:focus-visible { outline: 2.5px solid var(--o); outline-offset: 2px; }

/* Result */
.mcalc-hero p { margin: 0; }
.mcalc-hero-k { font-size: 1.05rem; color: var(--mut); }
.mcalc-hero-n { display: flex; align-items: baseline; flex-wrap: wrap; gap: .1rem .6rem; margin: .15rem 0 .2rem !important; }
.mcalc-hero-n strong {
  font-family: var(--font-primary-dark); font-weight: 400; color: var(--o);
  font-size: clamp(3.6rem, 7.4vw, 6.2rem); line-height: .85; letter-spacing: -.01em; font-variant-numeric: tabular-nums;
}
.mcalc-hero-n span { font-size: 1.35rem; font-weight: 500; color: var(--o); }
.mcalc-hero-s { font-size: 1rem; line-height: 1.35; }
.mcalc-hero-vs {
  display: inline-block; margin: .7rem 0 0 !important; padding: .5rem .85rem; border-radius: 99px;
  background: #fff; border: 1px solid var(--line); font-size: .92rem; line-height: 1.3;
}
.mcalc-hero-vs b { color: var(--o); }
.mcalc-hero-vs:empty { display: none; }
.mcalc[data-verdict="wait"] .mcalc-hero-n strong, .mcalc[data-verdict="wait"] .mcalc-hero-n span { color: var(--ink); }

/* Comparison table */
.mcalc-table { background: #fff; border-radius: 1.25rem; padding: .35rem 0 .2rem; border: 1px solid var(--line); }
.mcalc-row { display: grid; grid-template-columns: 1.25fr 1fr 1fr 1fr; align-items: center; }
.mcalc-row > span { padding: .62rem .7rem; font-size: .9rem; line-height: 1.2; }
.mcalc-row > span[role="rowheader"] { color: var(--mut); }
.mcalc-row + .mcalc-row > span { border-top: 1px solid #f1e6de; }
.mcalc-head > span { font-weight: 600; font-size: .82rem; letter-spacing: .03em; text-transform: uppercase; color: var(--mut); padding-top: .5rem; }
.mcalc-row > .is-birdie { background: rgba(255, 84, 0, .07); font-weight: 600; color: var(--ink); }
.mcalc-head > .is-birdie { color: var(--o); border-radius: .8rem .8rem 0 0; }
.mcalc-total > span { font-weight: 600; font-size: 1.05rem; color: var(--ink); }
.mcalc-total > span[role="rowheader"] { color: var(--ink); }
.mcalc-total > .is-birdie { color: var(--o); font-size: 1.2rem; border-radius: 0 0 .8rem .8rem; }
/* Manager column greys out when a manager likely won't sign this creator yet
   (#8c776c keeps 4.3:1 on white, the old #b9a59a was too faint to read) */
.mcalc[data-mgr="no"] .mcalc-row > span:nth-child(3) { color: #8c776c; }
.mcalc-mgr-note { margin: .2rem .7rem .55rem; font-size: .8rem; line-height: 1.35; color: var(--mut); }
.mcalc-mgr-note::before { content: "* "; color: var(--o); font-weight: 700; }
.mcalc[data-mgr="no"] .mcalc-head > span:nth-child(3)::after { content: "*"; color: var(--o); }
@media (max-width: 400px) { .mcalc-mgr-note { font-size: .72rem; margin-inline: .45rem; } }
.mcalc-mgr-note:empty { display: none; }

/* Money left on each deal */
.mcalc-leak-t { margin: 0 0 .5rem; font-weight: 600; font-size: 1rem; }
.mcalc-leak ul { list-style: none; margin: 0; padding: 0; }
.mcalc-leak li { display: flex; justify-content: space-between; gap: 1rem; padding: .55rem 0; border-top: 1px dashed #e6cfc0; font-size: .95rem; }
.mcalc-leak li b { color: var(--o); white-space: nowrap; }
.mcalc-payback { margin: .8rem 0 0; font-size: .95rem; font-weight: 500; }

@media (max-width: 760px) {
  .mcalc { grid-template-columns: 1fr; border-radius: 1.5rem; }
  .mcalc-in { border-right: 0; border-bottom: 1px solid var(--line); }
  .mcalc-row { grid-template-columns: 1.1fr 1fr 1fr 1fr; }
  .mcalc-row > span { padding: .55rem .45rem; font-size: .8rem; }
  .mcalc-head > span { font-size: .68rem; letter-spacing: .02em; }
  .mcalc-total > span { font-size: .9rem; }
  .mcalc-total > .is-birdie { font-size: 1rem; }
}

/* Sliders: followers (log scale) and deals a month. Orange fill up to the thumb. */
.mcalc-qrow { display: flex; align-items: baseline; justify-content: space-between; gap: 1rem; margin-bottom: .35rem; }
.mcalc-qrow .mcalc-legend { margin-bottom: 0; }
.mcalc-val { font-family: var(--font-primary-dark); font-size: 2rem; line-height: 1; color: var(--o); font-variant-numeric: tabular-nums; white-space: nowrap; }
.mcalc-range {
  --fill: 50%;
  -webkit-appearance: none; appearance: none; width: 100%; height: 30px; margin: 0; background: transparent; cursor: pointer;
}
.mcalc-range::-webkit-slider-runnable-track {
  height: 6px; border-radius: 99px;
  background: linear-gradient(var(--o), var(--o)) 0 0 / var(--fill) 100% no-repeat, #ead7cf;
}
.mcalc-range::-webkit-slider-thumb {
  -webkit-appearance: none; width: 26px; height: 26px; margin-top: -10px; border-radius: 50%;
  background: #fff; border: 6px solid var(--o); box-shadow: 0 6px 14px -4px rgba(255, 84, 0, .55);
  transition: transform .15s ease;
}
.mcalc-range:active::-webkit-slider-thumb { transform: scale(1.12); }
.mcalc-range::-moz-range-track { height: 6px; border-radius: 99px; background: #ead7cf; }
.mcalc-range::-moz-range-progress { height: 6px; border-radius: 99px; background: var(--o); }
.mcalc-range::-moz-range-thumb { width: 14px; height: 14px; border-radius: 50%; background: #fff; border: 6px solid var(--o); box-shadow: 0 6px 14px -4px rgba(255, 84, 0, .55); }
.mcalc-range:focus-visible { outline: none; }
.mcalc-range:focus-visible::-webkit-slider-thumb { outline: 2.5px solid var(--ink); outline-offset: 2px; }
.mcalc-ticks { display: flex; justify-content: space-between; margin-top: .15rem; font-size: .8rem; color: var(--mut); }
