/*
 * MajestyFlair.UK — Edging Tasks cinematic skin
 * Scoped to body.edge-cinematic so no other game is changed.
 * Load AFTER /games/engine.css and the global theme styles.
 */

body.edge-cinematic {
  --edge-ink: #030103;
  --edge-black: #080407;
  --edge-panel: #12070d;
  --edge-panel-2: #1a0911;
  --edge-ruby: #7f0c2b;
  --edge-crimson: #b5113e;
  --edge-pink: #f22f72;
  --edge-rose: #ff6f98;
  --edge-plum: #27091d;
  --edge-wine: #390a19;
  --edge-gold: #c79a57;
  --edge-gold-soft: #e3c48c;
  --edge-cream: #f5eadb;
  --edge-muted: #c8b7ad;
  --edge-line: rgba(199, 154, 87, .38);
  --edge-ruby-line: rgba(242, 47, 114, .42);
  --edge-glow: rgba(242, 47, 114, .24);
  background:
    radial-gradient(circle at 78% 18%, rgba(117, 9, 48, .17), transparent 35%),
    radial-gradient(circle at 10% 62%, rgba(80, 6, 43, .16), transparent 34%),
    #030103;
  color: var(--edge-cream);
}

.edge-cinematic main {
  position: relative;
  isolation: isolate;
}

.edge-cinematic main::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: -2;
  pointer-events: none;
  opacity: .46;
  background:
    radial-gradient(circle at 50% -8%, rgba(243, 34, 111, .10), transparent 32%),
    linear-gradient(110deg, transparent 0 47%, rgba(193, 23, 74, .035) 50%, transparent 53% 100%);
}

/* ---------------------------------------------------------------
   Cinematic hero
   --------------------------------------------------------------- */
.edge-cinematic .edge-hero {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 1.03fr) minmax(330px, .97fr);
  min-height: 520px;
  margin-top: 24px;
  padding: 0;
  overflow: hidden;
  border: 1px solid var(--edge-line);
  background: linear-gradient(145deg, #120408 0%, #090305 44%, #15040d 100%);
  box-shadow: 0 26px 80px rgba(0, 0, 0, .55), inset 0 0 70px rgba(116, 11, 48, .11);
}

.edge-cinematic .edge-hero::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 1;
  pointer-events: none;
  background:
    linear-gradient(90deg, rgba(4, 1, 3, .04) 0%, rgba(4, 1, 3, .08) 44%, rgba(4, 1, 3, .38) 72%, rgba(4, 1, 3, .18) 100%),
    radial-gradient(circle at 48% 56%, transparent 0 32%, rgba(0, 0, 0, .26) 72%);
}

.edge-cinematic .edge-hero-copy {
  position: relative;
  z-index: 3;
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: clamp(36px, 5.5vw, 76px);
  background: linear-gradient(90deg, rgba(4, 1, 3, .96), rgba(7, 2, 5, .88) 74%, rgba(7, 2, 5, .24));
}

.edge-cinematic .edge-hero-scene {
  position: relative;
  z-index: 0;
  min-height: 520px;
  background:
    linear-gradient(90deg, #070205 0%, rgba(7, 2, 5, .18) 28%, rgba(7, 2, 5, .06) 100%),
    linear-gradient(0deg, rgba(7, 2, 5, .56), transparent 34%),
    url('/games/edging-tasks/assets/edging-tasks-hero.webp') center / cover no-repeat;
  transform: scale(1.015);
  transform-origin: center;
}

.edge-cinematic .edge-hero-scene::before,
.edge-cinematic .edge-hero-scene::after {
  content: "";
  position: absolute;
  pointer-events: none;
}

.edge-cinematic .edge-hero-scene::before {
  inset: 0;
  background:
    radial-gradient(circle at 21% 66%, rgba(245, 48, 116, .24), transparent 11%),
    radial-gradient(circle at 72% 28%, rgba(245, 48, 116, .13), transparent 14%),
    linear-gradient(115deg, transparent 0 43%, rgba(241, 38, 108, .16) 49%, transparent 55% 100%);
  mix-blend-mode: screen;
  animation: edgeSceneGlow 7s ease-in-out infinite alternate;
}

.edge-cinematic .edge-hero-scene::after {
  left: -12%;
  right: -12%;
  bottom: 14%;
  height: 2px;
  background: linear-gradient(90deg, transparent, rgba(255, 95, 146, .32), #ff2f72 62%, rgba(255, 95, 146, .18), transparent);
  box-shadow: 0 0 16px rgba(255, 47, 114, .7);
  transform: rotate(-8deg);
  animation: edgeLightSweep 6.5s ease-in-out infinite;
}

.edge-cinematic .edge-hero .mf-eyebrow {
  color: var(--edge-gold-soft);
  letter-spacing: .22em;
}

.edge-cinematic .edge-hero h1 {
  max-width: 720px;
  margin: .14em 0 .22em;
  color: var(--edge-cream);
  font-family: Georgia, 'Times New Roman', serif;
  font-size: clamp(50px, 7.2vw, 92px);
  font-weight: 400;
  line-height: .9;
  letter-spacing: -.035em;
  text-wrap: balance;
  text-shadow: 0 12px 34px rgba(0, 0, 0, .7);
}

.edge-cinematic .edge-title-accent {
  color: #f44a7e;
  text-shadow: 0 0 22px rgba(244, 74, 126, .22);
}

.edge-cinematic .edge-hero .mf-hook {
  max-width: 620px;
  color: #e9dacb;
  font-size: clamp(17px, 2vw, 20px);
}

.edge-cinematic .edge-hero .mf-meta {
  gap: 8px;
  margin-top: 24px;
}

.edge-cinematic .edge-hero .mf-meta span {
  border-color: rgba(199, 154, 87, .38);
  background: rgba(5, 2, 4, .62);
  color: #cbb9ad;
  box-shadow: inset 0 0 18px rgba(145, 19, 57, .06);
}

.edge-cinematic .edge-hero .mf-meta b {
  color: var(--edge-rose);
  font-family: Georgia, serif;
  font-size: 17px;
}

.edge-cinematic .edge-intensity-gems {
  color: #f33275 !important;
  letter-spacing: .16em !important;
  text-shadow: 0 0 12px rgba(243, 50, 117, .34);
}

.edge-cinematic .edge-hero .mf-payoff {
  max-width: 680px;
  margin-top: 20px;
  border-left: 1px solid var(--edge-gold);
  color: var(--edge-muted);
}

.edge-cinematic .edge-preservation-seal {
  display: inline-flex;
  width: fit-content;
  align-items: center;
  gap: 9px;
  margin-top: 18px;
  padding: 8px 12px;
  border: 1px solid rgba(199, 154, 87, .32);
  color: var(--edge-gold-soft);
  background: rgba(5, 2, 4, .54);
  font: 700 10px/1.25 Arial, sans-serif;
  letter-spacing: .16em;
  text-transform: uppercase;
}

.edge-cinematic .edge-preservation-seal::before {
  content: '♛';
  color: var(--edge-rose);
  font-size: 14px;
}

/* ---------------------------------------------------------------
   Generated game shell
   --------------------------------------------------------------- */
.edge-cinematic [data-mf-game="edging-tasks"] {
  position: relative;
  margin-top: 18px;
}

.edge-cinematic [data-mf-game="edging-tasks"]::before {
  content: "";
  position: absolute;
  inset: -50px -7vw auto;
  height: 220px;
  z-index: -1;
  pointer-events: none;
  background: radial-gradient(ellipse at 50% 0%, rgba(151, 12, 58, .13), transparent 65%);
}

.edge-cinematic [data-mf-game="edging-tasks"] .mf-game {
  position: relative;
  padding: 0;
}

.edge-cinematic [data-mf-game="edging-tasks"] .mf-head {
  align-items: end;
  margin: 0 0 12px;
  padding: 18px 0 14px;
  border-top: 1px solid rgba(199, 154, 87, .26);
  border-bottom: 1px solid rgba(199, 154, 87, .26);
  background: linear-gradient(90deg, rgba(25, 4, 12, .34), transparent 45%);
}

.edge-cinematic [data-mf-game="edging-tasks"] .mf-head h2 {
  margin: .12em 0 0;
  color: var(--edge-cream);
  font-family: Georgia, serif;
  font-size: clamp(32px, 4vw, 48px);
  font-weight: 400;
}

.edge-cinematic [data-mf-game="edging-tasks"] .mf-stats {
  gap: 0;
  justify-content: flex-end;
}

.edge-cinematic [data-mf-game="edging-tasks"] .mf-stat {
  min-width: 82px;
  padding: 7px 16px 5px;
  border-left: 1px solid rgba(199, 154, 87, .22);
  align-items: center;
}

.edge-cinematic [data-mf-game="edging-tasks"] .mf-stat-v {
  color: #f36b95;
  font-size: 25px;
  animation: edgeStatIn .42s cubic-bezier(.2,.75,.2,1) both;
}

.edge-cinematic [data-mf-game="edging-tasks"] .mf-stat-l {
  color: #bda9a0;
  letter-spacing: .15em;
}

.edge-cinematic [data-mf-game="edging-tasks"] .mf-live {
  min-height: 18px;
  margin: 4px 0 8px;
  color: #ea5f8a;
}

.edge-cinematic [data-mf-game="edging-tasks"] .mf-body {
  display: grid;
  grid-template-columns: minmax(0, 1.2fr) minmax(310px, .82fr);
  gap: 20px;
  align-items: start;
}

.edge-cinematic [data-mf-game="edging-tasks"] .edge-voice-slot,
.edge-cinematic [data-mf-game="edging-tasks"] .mf-body > .mf-card-task,
.edge-cinematic [data-mf-game="edging-tasks"] .mf-body > .mf-actions {
  grid-column: 1;
}

/* room voice panel remains first, but visually folds into task card */
.edge-cinematic [data-mf-game="edging-tasks"] .mf-body > *:first-child:not(.mf-card-task):not(.mf-actions):not(.mf-ledger) {
  grid-column: 1;
}

.edge-cinematic [data-mf-game="edging-tasks"] .mf-card-task {
  position: relative;
  min-height: 330px;
  padding: clamp(28px, 4.5vw, 48px);
  overflow: hidden;
  border: 1px solid rgba(242, 47, 114, .58);
  background:
    radial-gradient(circle at 92% 4%, rgba(242, 47, 114, .13), transparent 32%),
    linear-gradient(145deg, rgba(15, 4, 10, .98), rgba(6, 2, 5, .98));
  box-shadow:
    inset 0 0 0 1px rgba(199, 154, 87, .13),
    inset 0 0 58px rgba(116, 8, 47, .18),
    0 20px 54px rgba(0, 0, 0, .44),
    0 0 28px rgba(242, 47, 114, .07);
}

.edge-cinematic [data-mf-game="edging-tasks"] .mf-card-task::before,
.edge-cinematic [data-mf-game="edging-tasks"] .mf-card-task::after {
  content: "";
  position: absolute;
  pointer-events: none;
}

.edge-cinematic [data-mf-game="edging-tasks"] .mf-card-task::before {
  inset: 10px;
  border: 1px solid rgba(199, 154, 87, .22);
  box-shadow: inset 0 0 18px rgba(199, 154, 87, .035);
}

.edge-cinematic [data-mf-game="edging-tasks"] .mf-card-task::after {
  inset: 0;
  opacity: .22;
  background:
    linear-gradient(115deg, transparent 0 42%, rgba(255,255,255,.12) 48%, transparent 54% 100%);
  transform: translateX(-110%);
}

.edge-cinematic [data-mf-game="edging-tasks"] .mf-card-task.edge-task-live::after {
  animation: edgeCardSweep 1.05s ease-out .08s 1;
}

.edge-cinematic [data-mf-game="edging-tasks"] .edge-task-kicker {
  position: relative;
  z-index: 2;
  display: flex;
  align-items: center;
  gap: 10px;
  margin: 0 0 18px;
  color: #e9bdb0;
  font: 800 10px/1.3 Arial, sans-serif;
  letter-spacing: .19em;
  text-transform: uppercase;
}

.edge-cinematic [data-mf-game="edging-tasks"] .edge-task-kicker::before {
  content: '✦';
  color: var(--edge-gold-soft);
}

.edge-cinematic [data-mf-game="edging-tasks"] .edge-task-brand {
  position: relative;
  z-index: 2;
  margin: -6px 0 15px;
  color: #f25283;
  font: italic 15px/1.45 Georgia, serif;
}

.edge-cinematic [data-mf-game="edging-tasks"] .mf-prompt,
.edge-cinematic [data-mf-game="edging-tasks"] .mf-task,
.edge-cinematic [data-mf-game="edging-tasks"] .mf-tags {
  position: relative;
  z-index: 2;
}

.edge-cinematic [data-mf-game="edging-tasks"] .mf-prompt {
  max-width: 46rem;
  color: #cbb9ae;
  font-size: 18px;
}

.edge-cinematic [data-mf-game="edging-tasks"] .mf-task {
  max-width: 60rem;
  color: #f3e6d9;
  font-size: clamp(18px, 2vw, 21px);
  line-height: 1.7;
  text-wrap: pretty;
}

.edge-cinematic [data-mf-game="edging-tasks"] .mf-body > .mf-actions {
  gap: 14px;
  margin: -4px 0 4px;
}

.edge-cinematic [data-mf-game="edging-tasks"] .mf-btn {
  min-height: 52px;
  border-color: rgba(199, 154, 87, .48);
  background: linear-gradient(180deg, rgba(52, 8, 22, .78), rgba(16, 4, 10, .92));
  color: #f3e3d4;
  box-shadow: inset 0 0 0 1px rgba(242, 47, 114, .05);
  letter-spacing: .13em;
  transition: transform .2s ease, box-shadow .25s ease, border-color .25s ease, background .25s ease;
}

.edge-cinematic [data-mf-game="edging-tasks"] .mf-btn:hover {
  transform: translateY(-2px);
  border-color: rgba(255, 111, 152, .88);
  background: linear-gradient(180deg, rgba(93, 13, 42, .92), rgba(23, 5, 13, .95));
  box-shadow: 0 10px 28px rgba(155, 14, 59, .18), 0 0 20px rgba(242, 47, 114, .08);
}

.edge-cinematic [data-mf-game="edging-tasks"] .mf-btn-primary {
  border-color: rgba(255, 92, 139, .88);
  background: linear-gradient(105deg, #6f0c2a, #a60d3d 47%, #70102e);
  color: #fff0e4;
  box-shadow: inset 0 0 0 1px rgba(255,255,255,.08), 0 0 24px rgba(242, 47, 114, .14);
}

/* faux antique ledger */
.edge-cinematic [data-mf-game="edging-tasks"] .mf-ledger {
  position: relative;
  grid-column: 2;
  grid-row: 1 / span 4;
  min-height: 485px;
  margin: 0;
  padding: 32px 28px 28px;
  overflow: hidden;
  border: 1px solid rgba(199, 154, 87, .60);
  background:
    radial-gradient(circle at 18% 16%, rgba(255,255,255,.10), transparent 18%),
    radial-gradient(circle at 76% 72%, rgba(75, 40, 16, .08), transparent 23%),
    linear-gradient(90deg, rgba(83,49,26,.20) 49.7%, rgba(43,22,11,.42) 50%, rgba(255,255,255,.06) 50.4%, transparent 50.8%),
    #c8a777;
  color: #2d190f;
  box-shadow: inset 0 0 70px rgba(52, 22, 5, .32), 0 22px 58px rgba(0,0,0,.42);
}

.edge-cinematic [data-mf-game="edging-tasks"] .mf-ledger::before,
.edge-cinematic [data-mf-game="edging-tasks"] .mf-ledger::after {
  content: "";
  position: absolute;
  pointer-events: none;
}

.edge-cinematic [data-mf-game="edging-tasks"] .mf-ledger::before {
  inset: 10px;
  border: 1px solid rgba(63, 30, 12, .22);
  box-shadow: inset 0 0 0 4px rgba(232, 202, 150, .10);
}

.edge-cinematic [data-mf-game="edging-tasks"] .mf-ledger::after {
  top: 0;
  right: 34px;
  width: 42px;
  height: 104px;
  background: linear-gradient(#6f0d2c, #3f0719);
  border-inline: 1px solid rgba(69, 30, 17, .52);
  box-shadow: 0 8px 16px rgba(56, 15, 22, .28);
  clip-path: polygon(0 0, 100% 0, 100% 86%, 50% 100%, 0 86%);
}

.edge-cinematic [data-mf-game="edging-tasks"] .mf-ledger .mf-eyebrow {
  color: #5e2d1e;
}

.edge-cinematic [data-mf-game="edging-tasks"] .mf-ledger h3 {
  color: #5b1530;
  font-family: Georgia, serif;
  font-size: clamp(30px, 3vw, 42px);
  font-weight: 400;
  text-shadow: none;
}

.edge-cinematic [data-mf-game="edging-tasks"] .mf-ledger-rank,
.edge-cinematic [data-mf-game="edging-tasks"] .mf-ledger-note,
.edge-cinematic [data-mf-game="edging-tasks"] .mf-ledger-detail,
.edge-cinematic [data-mf-game="edging-tasks"] .mf-ledger p {
  color: #3c2518;
}

.edge-cinematic [data-mf-game="edging-tasks"] .mf-ledger-head {
  position: relative;
  z-index: 2;
  display: grid;
  grid-template-columns: 1fr;
  gap: 16px;
}

.edge-cinematic [data-mf-game="edging-tasks"] .mf-ledger .mf-actions {
  position: relative;
  z-index: 2;
  grid-column: auto;
  margin-top: 24px;
}

.edge-cinematic [data-mf-game="edging-tasks"] .mf-ledger .mf-btn {
  border-color: rgba(81, 31, 29, .50);
  background: rgba(73, 19, 34, .10);
  color: #4b1b27;
  box-shadow: none;
}

.edge-cinematic [data-mf-game="edging-tasks"] .mf-ledger .mf-btn:hover {
  border-color: #681d32;
  background: rgba(89, 22, 43, .16);
  color: #42101d;
}

.edge-cinematic [data-mf-game="edging-tasks"] .mf-ledger-detail {
  border-left-color: #6f1f36;
  background: rgba(78, 35, 17, .08);
}

.edge-cinematic [data-mf-game="edging-tasks"] .mf-foot {
  grid-column: 1 / -1;
  margin-top: 24px;
  padding: 22px 0 0;
  border-top-color: rgba(199, 154, 87, .22);
}

/* ---------------------------------------------------------------
   Motion states injected by edging-tasks-cinematic.js
   --------------------------------------------------------------- */
.edge-cinematic [data-mf-game="edging-tasks"].edge-is-drawing .mf-card-task {
  animation: edgeDrawPulse .52s cubic-bezier(.2,.8,.2,1) both;
}

.edge-cinematic [data-mf-game="edging-tasks"].edge-complete-burst .mf-card-task,
.edge-cinematic [data-mf-game="edging-tasks"].edge-complete-burst .mf-head {
  animation: edgeCompleteFlash .72s ease-out both;
}

.edge-cinematic [data-mf-game="edging-tasks"].edge-skip-smoke .mf-card-task {
  animation: edgeSkipAway .52s ease-out both;
}

.edge-cinematic .edge-burst-layer {
  position: fixed;
  inset: 0;
  z-index: 220;
  pointer-events: none;
  overflow: hidden;
}

.edge-cinematic .edge-burst-dot {
  position: absolute;
  left: var(--x);
  top: var(--y);
  width: var(--s);
  height: var(--s);
  border-radius: 50%;
  background: radial-gradient(circle, #fff6dc 0 14%, #ff4c86 38%, rgba(171,13,57,.15) 72%, transparent 74%);
  box-shadow: 0 0 12px rgba(242, 47, 114, .58);
  animation: edgeBurst .75s cubic-bezier(.12,.7,.2,1) forwards;
}

.edge-cinematic .edge-audio-toggle {
  position: absolute;
  right: 18px;
  bottom: 16px;
  z-index: 4;
  min-height: 38px;
  padding: 8px 12px;
  border: 1px solid rgba(199,154,87,.35);
  background: rgba(4,1,3,.68);
  color: #e7cfa5;
  font: 800 9px/1 Arial, sans-serif;
  letter-spacing: .14em;
  text-transform: uppercase;
  cursor: pointer;
}

.edge-cinematic .edge-audio-toggle:hover {
  border-color: rgba(255,103,150,.66);
  color: #ffb0c7;
}

@keyframes edgeSceneGlow {
  from { opacity: .55; filter: saturate(.92) brightness(.94); }
  to { opacity: 1; filter: saturate(1.08) brightness(1.03); }
}
@keyframes edgeLightSweep {
  0%, 100% { opacity: .32; transform: rotate(-8deg) translateX(-3%); }
  50% { opacity: .95; transform: rotate(-8deg) translateX(6%); }
}
@keyframes edgeCardSweep {
  from { transform: translateX(-110%); }
  to { transform: translateX(115%); }
}
@keyframes edgeStatIn {
  from { opacity: .28; transform: translateY(5px) scale(.94); }
  to { opacity: 1; transform: none; }
}
@keyframes edgeDrawPulse {
  0% { transform: scale(1); box-shadow: 0 20px 54px rgba(0,0,0,.44); }
  48% { transform: scale(.992); box-shadow: 0 0 36px rgba(242,47,114,.18), 0 20px 54px rgba(0,0,0,.44); }
  100% { transform: scale(1); }
}
@keyframes edgeCompleteFlash {
  0% { filter: brightness(1); }
  42% { filter: brightness(1.28) saturate(1.2); }
  100% { filter: none; }
}
@keyframes edgeSkipAway {
  0% { opacity: 1; transform: none; filter: blur(0); }
  100% { opacity: .18; transform: translateY(8px) scale(.985); filter: blur(3px); }
}
@keyframes edgeBurst {
  0% { opacity: 0; transform: translate(-50%,-50%) scale(.2); }
  18% { opacity: 1; }
  100% { opacity: 0; transform: translate(calc(-50% + var(--dx)), calc(-50% + var(--dy))) scale(1.35); }
}

@media (max-width: 980px) {
  .edge-cinematic .edge-hero {
    grid-template-columns: 1fr;
    min-height: auto;
  }
  .edge-cinematic .edge-hero-copy {
    min-height: 520px;
    background: linear-gradient(90deg, rgba(4,1,3,.97), rgba(4,1,3,.83) 72%, rgba(4,1,3,.55));
  }
  .edge-cinematic .edge-hero-scene {
    position: absolute;
    inset: 0;
    min-height: 100%;
    opacity: .52;
  }
  .edge-cinematic [data-mf-game="edging-tasks"] .mf-body {
    grid-template-columns: 1fr;
  }
  .edge-cinematic [data-mf-game="edging-tasks"] .mf-ledger {
    grid-column: 1;
    grid-row: auto;
    min-height: 0;
  }
  .edge-cinematic [data-mf-game="edging-tasks"] .mf-foot {
    grid-column: 1;
  }
}

@media (max-width: 640px) {
  .edge-cinematic .edge-hero-copy {
    min-height: 470px;
    padding: 30px 22px 46px;
  }
  .edge-cinematic .edge-hero h1 {
    font-size: clamp(46px, 16vw, 64px);
  }
  .edge-cinematic .edge-hero .mf-meta {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .edge-cinematic .edge-hero .mf-meta span {
    justify-content: center;
    text-align: center;
  }
  .edge-cinematic [data-mf-game="edging-tasks"] .mf-head {
    align-items: flex-start;
  }
  .edge-cinematic [data-mf-game="edging-tasks"] .mf-stats {
    width: 100%;
    justify-content: flex-start;
    overflow-x: auto;
    padding-bottom: 4px;
  }
  .edge-cinematic [data-mf-game="edging-tasks"] .mf-stat {
    min-width: 74px;
    padding-inline: 12px;
  }
  .edge-cinematic [data-mf-game="edging-tasks"] .mf-card-task {
    min-height: 270px;
    padding: 28px 22px;
  }
  .edge-cinematic [data-mf-game="edging-tasks"] .mf-actions {
    display: grid;
    grid-template-columns: 1fr;
  }
  .edge-cinematic [data-mf-game="edging-tasks"] .mf-actions .mf-btn {
    width: 100%;
  }
  .edge-cinematic .edge-audio-toggle {
    right: 10px;
    bottom: 10px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .edge-cinematic *,
  .edge-cinematic *::before,
  .edge-cinematic *::after {
    animation: none !important;
    transition-duration: .01ms !important;
    scroll-behavior: auto !important;
  }
}

/* ---------------------------------------------------------------
   Consent gate and Majesty voice - same world, no logic changes
   --------------------------------------------------------------- */
.edge-cinematic [data-mf-game="edging-tasks"] .mf-gate {
  position: relative;
  overflow: hidden;
  margin-top: 22px;
  padding: clamp(28px, 4.5vw, 48px);
  border: 1px solid rgba(199, 154, 87, .44);
  background:
    radial-gradient(circle at 86% 14%, rgba(242,47,114,.12), transparent 28%),
    linear-gradient(145deg, rgba(22,5,13,.98), rgba(7,2,5,.98));
  box-shadow: inset 0 0 60px rgba(122,10,48,.12), 0 18px 50px rgba(0,0,0,.36);
}
.edge-cinematic [data-mf-game="edging-tasks"] .mf-gate::before {
  content: "";
  position: absolute;
  inset: 10px;
  pointer-events: none;
  border: 1px solid rgba(199,154,87,.16);
}
.edge-cinematic [data-mf-game="edging-tasks"] .mf-gate > * {
  position: relative;
  z-index: 1;
}
.edge-cinematic [data-mf-game="edging-tasks"] .mf-gate h2 {
  color: var(--edge-cream);
  font-family: Georgia, serif;
  font-size: clamp(34px, 4.2vw, 52px);
}
.edge-cinematic [data-mf-game="edging-tasks"] .mf-gate .mf-lede {
  max-width: 48rem;
  color: #d8c5b9;
}
.edge-cinematic [data-mf-game="edging-tasks"] .mf-rules {
  margin-top: 24px;
  padding: 20px 22px;
  border: 1px solid rgba(199,154,87,.24);
  border-left: 3px solid var(--edge-crimson);
  background: rgba(12,3,8,.68);
}
.edge-cinematic [data-mf-game="edging-tasks"] .mf-rules h3,
.edge-cinematic [data-mf-game="edging-tasks"] .mf-filters h3 {
  color: #f0dfcf;
}
.edge-cinematic [data-mf-game="edging-tasks"] .mf-rules ul,
.edge-cinematic [data-mf-game="edging-tasks"] .mf-small {
  color: #c8b6ab;
}
.edge-cinematic [data-mf-game="edging-tasks"] .mf-filter {
  border-color: rgba(199,154,87,.22);
  background: linear-gradient(110deg, rgba(33,6,17,.64), rgba(8,2,6,.72));
}
.edge-cinematic [data-mf-game="edging-tasks"] .mf-filter:hover,
.edge-cinematic [data-mf-game="edging-tasks"] .mf-filter:focus-within {
  border-color: rgba(255,111,152,.7);
  background: linear-gradient(110deg, rgba(71,8,29,.72), rgba(12,3,8,.80));
}
.edge-cinematic [data-mf-game="edging-tasks"] .mf-check {
  accent-color: var(--edge-crimson);
}
.edge-cinematic [data-mf-game="edging-tasks"] .mf-voice-room {
  position: relative;
  overflow: hidden;
  margin: 0 0 0;
  border: 1px solid rgba(199,154,87,.24);
  border-left: 3px solid var(--edge-crimson);
  background: linear-gradient(100deg, rgba(64,7,28,.72), rgba(18,3,14,.78));
  box-shadow: inset 0 0 28px rgba(242,47,114,.05);
}
.edge-cinematic [data-mf-game="edging-tasks"] .mf-voice-room .mf-voice-crest {
  background: radial-gradient(circle at 35% 28%, #d13266, #700d2c 62%, #2d0718);
  box-shadow: 0 0 18px rgba(242,47,114,.18);
}
.edge-cinematic [data-mf-game="edging-tasks"] .mf-voice-room .mf-voice-body strong {
  color: #e5c28b;
}
.edge-cinematic [data-mf-game="edging-tasks"] .mf-voice-room .mf-voice-body em {
  color: #f3dfe4;
}

/* ---------------------------------------------------------------
   Reference-match pass v2
   Recreates the approved full cinematic composition with real UI.
   --------------------------------------------------------------- */
body.edge-cinematic {
  background-color: #020102;
  background-image:
    linear-gradient(rgba(2, 1, 2, .08), rgba(2, 1, 2, .16)),
    url('/games/edging-tasks/assets/edging-tasks-shell-v2.webp');
  background-repeat: no-repeat;
  background-position: center 58px;
  background-size: min(100vw, 1600px) auto;
  background-attachment: fixed;
}

body.edge-cinematic::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  background:
    radial-gradient(circle at 8% 74%, rgba(172, 9, 68, .18), transparent 25%),
    radial-gradient(circle at 94% 66%, rgba(114, 5, 48, .16), transparent 27%),
    linear-gradient(180deg, rgba(0, 0, 0, .08), #020102 88%);
}

/* Keep the room framed like the approved reference rather than the taller
   generic site chrome used by ordinary content pages. */
.edge-cinematic .preview-strip {
  display: none;
}

.edge-cinematic .site-header {
  min-height: 64px;
  padding-block: 4px;
  border-bottom-color: rgba(183, 129, 58, .42);
  background: rgba(2, 1, 2, .96);
}

.edge-cinematic .site-header .logo-link img {
  width: auto;
  height: 48px;
}

.edge-cinematic .site-header .primary-nav a {
  padding-block: 20px;
  font-size: 10px;
  letter-spacing: .18em;
}

.edge-cinematic #main {
  width: min(1456px, calc(100vw - 28px));
  max-width: none;
  margin-inline: auto;
  padding: 0 0 38px;
}

.edge-cinematic .edge-hero {
  grid-template-columns: minmax(500px, .94fr) minmax(560px, 1.06fr);
  min-height: clamp(410px, 31vw, 455px);
  box-sizing: border-box;
  padding: 0 !important;
  margin-top: 0;
  border: 0;
  border-bottom: 1px solid rgba(185, 132, 66, .5);
  background: rgba(2, 1, 2, .7);
  box-shadow:
    inset 0 -1px rgba(226, 183, 112, .12),
    0 28px 70px rgba(0, 0, 0, .45);
}

.edge-cinematic .edge-hero::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 2;
  pointer-events: none;
  border: 1px solid rgba(173, 119, 56, .24);
  border-top: 0;
  background:
    linear-gradient(90deg, rgba(4, 1, 3, .98) 0 30%, rgba(4, 1, 3, .62) 45%, transparent 62%),
    linear-gradient(0deg, rgba(3, 1, 2, .82), transparent 28%);
}

.edge-cinematic .edge-hero::after {
  z-index: 3;
  background:
    linear-gradient(90deg, rgba(3, 1, 2, .04), transparent 48%, rgba(0, 0, 0, .08)),
    radial-gradient(ellipse at 78% 45%, transparent 0 42%, rgba(0, 0, 0, .2) 80%);
}

.edge-cinematic .edge-hero-copy {
  z-index: 4;
  justify-content: center;
  padding: clamp(30px, 3.5vw, 48px) clamp(32px, 4vw, 58px);
  background: transparent;
}

.edge-cinematic .edge-hero-scene {
  min-height: clamp(410px, 31vw, 455px);
  background:
    linear-gradient(90deg, #040102 0, rgba(4, 1, 2, .26) 20%, transparent 44%),
    linear-gradient(0deg, rgba(3, 1, 2, .58), transparent 34%),
    url('/games/edging-tasks/assets/edging-tasks-cinematic-scene-v2.webp') center / cover no-repeat;
  transform: none;
}

.edge-cinematic .edge-hero h1 {
  margin: .12em 0 .27em;
  color: #dfbd82;
  font-size: clamp(54px, 5.15vw, 76px);
  white-space: nowrap;
  line-height: .9;
  letter-spacing: -.02em;
  text-transform: uppercase;
  text-shadow:
    0 1px 0 #7d4b29,
    0 0 1px #f5d59e,
    0 8px 30px rgba(0, 0, 0, .9),
    0 0 24px rgba(145, 27, 60, .13);
}

.edge-cinematic .edge-hero .mf-eyebrow {
  color: #d9a95e;
  font-size: 11px;
  letter-spacing: .42em;
}

.edge-cinematic .edge-hero .mf-hook {
  max-width: 470px;
  color: #d8c6b4;
  font: 17px/1.5 Georgia, serif;
  text-align: center;
}

.edge-cinematic .edge-hero .mf-meta {
  display: grid;
  grid-template-columns: 1.42fr .88fr .72fr 1.3fr;
  width: min(100%, 530px);
  gap: 8px;
}

.edge-cinematic .edge-hero .mf-meta span {
  min-height: 66px;
  justify-content: center;
  padding: 9px 8px;
  border: 1px solid rgba(181, 126, 58, .56);
  border-radius: 5px;
  background: rgba(2, 1, 2, .72);
  color: #bba997;
  font-size: 9px;
  letter-spacing: .13em;
  text-align: center;
  text-transform: uppercase;
}

.edge-cinematic .edge-hero .mf-meta b {
  display: block;
  margin-bottom: 3px;
  color: #f13e75;
  font-size: 19px;
  line-height: 1;
}

.edge-cinematic .edge-hero .mf-payoff {
  width: min(100%, 530px);
  margin-top: 13px;
  padding: 11px 14px;
  border: 1px solid rgba(181, 126, 58, .48);
  color: #cdbbab;
  background: rgba(2, 1, 2, .66);
  text-align: center;
}

.edge-cinematic .edge-hero .mf-payoff::first-line {
  color: #f44a7e;
}

.edge-cinematic .edge-preservation-seal {
  align-self: center;
  justify-content: center;
  min-width: 350px;
  margin-top: 14px;
  border-color: rgba(181, 126, 58, .58);
  background: rgba(2, 1, 2, .72);
}

.edge-cinematic [data-mf-game="edging-tasks"] {
  margin-top: 0;
  padding: 0 clamp(16px, 3vw, 40px) 18px;
  border-inline: 1px solid rgba(157, 100, 44, .22);
  background: rgba(2, 1, 2, .72);
  box-shadow: inset 0 0 90px rgba(65, 4, 28, .08);
}

.edge-cinematic [data-mf-game="edging-tasks"] .mf-head {
  min-height: 96px;
  padding: 20px 0 15px;
  border-top: 0;
  background: linear-gradient(90deg, rgba(56, 5, 23, .28), transparent 46%);
}

.edge-cinematic [data-mf-game="edging-tasks"] .mf-head h2 {
  color: #e0bd88;
  font-size: clamp(34px, 3.6vw, 52px);
  text-shadow: 0 5px 24px rgba(0, 0, 0, .75);
}

.edge-cinematic [data-mf-game="edging-tasks"] .mf-stat {
  min-width: 92px;
  padding-inline: 18px;
}

.edge-cinematic [data-mf-game="edging-tasks"] .mf-stat-v {
  color: #f2537f;
  font-family: Georgia, serif;
  font-size: 28px;
  text-shadow: 0 0 14px rgba(242, 47, 114, .24);
}

.edge-cinematic [data-mf-game="edging-tasks"] .mf-stat-l {
  color: #c5ab8b;
  font-size: 9px;
}

.edge-cinematic [data-mf-game="edging-tasks"] .mf-stat::before {
  display: block;
  margin-bottom: 3px;
  color: #d8a25f;
  font-size: 15px;
  line-height: 1;
  text-shadow: 0 0 10px rgba(234, 53, 111, .28);
}

.edge-cinematic [data-mf-game="edging-tasks"] .mf-stat:nth-child(1)::before { content: '♛'; }
.edge-cinematic [data-mf-game="edging-tasks"] .mf-stat:nth-child(2)::before { content: '◇'; }
.edge-cinematic [data-mf-game="edging-tasks"] .mf-stat:nth-child(3)::before { content: '♨'; }
.edge-cinematic [data-mf-game="edging-tasks"] .mf-stat:nth-child(4)::before { content: '◈'; }
.edge-cinematic [data-mf-game="edging-tasks"] .mf-stat:nth-child(5)::before { content: '◉'; }

.edge-cinematic [data-mf-game="edging-tasks"] .mf-body {
  grid-template-columns: minmax(0, 1.25fr) minmax(390px, .84fr);
  gap: 24px;
}

.edge-cinematic [data-mf-game="edging-tasks"] .mf-voice-room {
  margin-bottom: -1px;
  border: 1px solid rgba(225, 49, 108, .48);
  border-bottom: 0;
  background: linear-gradient(100deg, rgba(59, 5, 27, .82), rgba(12, 2, 8, .94));
}

.edge-cinematic [data-mf-game="edging-tasks"] .mf-card-task {
  min-height: 355px;
  padding: clamp(30px, 3.4vw, 48px);
  border: 2px solid rgba(223, 37, 101, .75);
  border-radius: 3px;
  background:
    radial-gradient(circle at 92% 8%, rgba(237, 35, 103, .18), transparent 28%),
    radial-gradient(circle at 3% 94%, rgba(112, 8, 52, .2), transparent 28%),
    linear-gradient(145deg, rgba(15, 3, 9, .99), rgba(4, 1, 3, .99));
  box-shadow:
    inset 0 0 0 6px rgba(88, 12, 39, .36),
    inset 0 0 0 8px rgba(195, 121, 62, .22),
    inset 0 0 74px rgba(121, 4, 49, .24),
    0 0 28px rgba(232, 28, 94, .15),
    0 24px 65px rgba(0, 0, 0, .48);
}

.edge-cinematic [data-mf-game="edging-tasks"] .mf-card-task::before {
  inset: 13px;
  border: 1px solid rgba(232, 56, 114, .6);
  background:
    linear-gradient(135deg, #d99c58 0 2px, transparent 2px) top left / 42px 42px no-repeat,
    linear-gradient(225deg, #d99c58 0 2px, transparent 2px) top right / 42px 42px no-repeat,
    linear-gradient(45deg, #d99c58 0 2px, transparent 2px) bottom left / 42px 42px no-repeat,
    linear-gradient(315deg, #d99c58 0 2px, transparent 2px) bottom right / 42px 42px no-repeat;
  box-shadow: inset 0 0 24px rgba(230, 43, 105, .1);
}

.edge-cinematic [data-mf-game="edging-tasks"] .mf-task {
  color: #ead8c3;
  font: 19px/1.38 Georgia, serif;
}

.edge-cinematic [data-mf-game="edging-tasks"] .mf-actions {
  gap: 20px;
  margin-top: -76px;
  padding: 0 clamp(28px, 3.4vw, 48px) 24px;
}

.edge-cinematic [data-mf-game="edging-tasks"] .mf-body > .mf-actions .mf-btn {
  min-height: 58px;
  border: 1px solid rgba(219, 159, 85, .72);
  background: linear-gradient(180deg, #230712, #080205);
  color: #ead6bc;
  font-family: Georgia, serif;
  font-size: 12px;
  letter-spacing: .24em;
  text-transform: uppercase;
}

.edge-cinematic [data-mf-game="edging-tasks"] .mf-body > .mf-actions .mf-btn-primary {
  border-color: #ff4c84;
  background: linear-gradient(180deg, #7b0c2f, #2a0615);
  box-shadow:
    inset 0 0 0 3px rgba(255, 118, 157, .15),
    0 0 18px rgba(243, 42, 109, .35);
}

.edge-cinematic [data-mf-game="edging-tasks"] .mf-ledger {
  display: grid;
  grid-template-columns: 1fr 1fr;
  align-content: start;
  gap: 22px 30px;
  min-height: 530px;
  padding: 46px 34px 36px;
  border: 11px solid #2e160c;
  border-radius: 52px 20px 48px 20px;
  outline: 2px solid rgba(197, 134, 67, .72);
  outline-offset: -7px;
  background:
    linear-gradient(90deg, transparent 48.7%, rgba(80, 40, 15, .38) 49.4%, rgba(255, 234, 190, .22) 50%, rgba(65, 31, 12, .36) 50.7%, transparent 51.3%),
    radial-gradient(circle at 16% 18%, rgba(255, 255, 255, .18), transparent 22%),
    radial-gradient(circle at 80% 78%, rgba(98, 50, 16, .13), transparent 25%),
    linear-gradient(95deg, #d4b37f 0 48%, #c59c67 49% 51%, #d8b984 52% 100%);
  box-shadow:
    inset 0 0 80px rgba(56, 25, 7, .34),
    inset 18px 0 28px rgba(62, 29, 9, .12),
    inset -18px 0 28px rgba(62, 29, 9, .12),
    0 25px 58px rgba(0, 0, 0, .6),
    10px 8px 0 #130905;
}

.edge-cinematic [data-mf-game="edging-tasks"] .mf-ledger::before {
  inset: 12px 16px;
  border: 1px solid rgba(73, 34, 13, .27);
  border-radius: 36px 12px;
  box-shadow: inset 0 0 0 4px rgba(240, 210, 158, .1);
}

.edge-cinematic [data-mf-game="edging-tasks"] .mf-ledger::after {
  right: 28px;
  width: 48px;
  height: 116px;
  background: linear-gradient(#8b1135, #410719);
  border-inline: 1px solid rgba(208, 141, 74, .72);
}

.edge-cinematic [data-mf-game="edging-tasks"] .mf-ledger h3 {
  color: #4e1429;
  font-size: clamp(29px, 2.5vw, 40px);
  text-align: center;
}

.edge-cinematic [data-mf-game="edging-tasks"] .mf-ledger-head {
  grid-column: 1;
}

.edge-cinematic [data-mf-game="edging-tasks"] .mf-ledger .mf-eyebrow,
.edge-cinematic [data-mf-game="edging-tasks"] .mf-ledger-rank,
.edge-cinematic [data-mf-game="edging-tasks"] .mf-ledger-note {
  text-align: center;
}

.edge-cinematic [data-mf-game="edging-tasks"] .mf-ledger .mf-actions {
  grid-column: 1 / -1;
  margin-top: 28px;
  padding: 0;
}

.edge-cinematic [data-mf-game="edging-tasks"] .edge-ledger-history {
  position: relative;
  z-index: 2;
  grid-column: 2;
  padding: 8px 2px 0;
  color: #3c2518;
}

.edge-cinematic [data-mf-game="edging-tasks"] .edge-ledger-history-kicker {
  margin: 0 0 18px;
  color: #5e2d1e;
  font: 700 10px/1.2 Arial, sans-serif;
  letter-spacing: .2em;
  text-align: center;
  text-transform: uppercase;
}

.edge-cinematic [data-mf-game="edging-tasks"] .edge-ledger-history-list {
  display: grid;
  gap: 9px;
}

.edge-cinematic [data-mf-game="edging-tasks"] .edge-ledger-history-list p {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin: 0;
  padding: 7px 4px 7px 22px;
  border-bottom: 1px solid rgba(82, 39, 18, .18);
  color: #3c2518;
  font: 12px/1.35 Georgia, serif;
}

.edge-cinematic [data-mf-game="edging-tasks"] .edge-ledger-history-list p::before {
  content: '♛';
  position: absolute;
  margin-left: -18px;
  color: #6b1b32;
  font-size: 10px;
}

.edge-cinematic [data-mf-game="edging-tasks"] .edge-ledger-history-list b {
  color: #671631;
  font-size: 15px;
}

.edge-cinematic [data-mf-game="edging-tasks"] .mf-ledger .mf-btn {
  min-height: 48px;
  border-color: rgba(84, 31, 35, .65);
  background: rgba(94, 19, 42, .09);
  color: #431323;
}

.edge-cinematic [data-mf-game="edging-tasks"] .mf-foot {
  margin-top: 28px;
  padding: 30px clamp(70px, 9vw, 130px) 8px;
  border-top: 1px solid rgba(173, 112, 52, .35);
}

.edge-cinematic [data-mf-game="edging-tasks"] .mf-foot .mf-btn {
  min-width: 190px;
}

@media (max-width: 1100px) {
  .edge-cinematic .edge-hero {
    grid-template-columns: 1fr;
  }
  .edge-cinematic .edge-hero-copy {
    min-height: 540px;
    background: linear-gradient(90deg, rgba(3, 1, 2, .98), rgba(3, 1, 2, .72) 65%, rgba(3, 1, 2, .35));
  }
  .edge-cinematic .edge-hero-scene {
    position: absolute;
    inset: 0;
    opacity: .62;
  }
  .edge-cinematic [data-mf-game="edging-tasks"] .mf-body {
    grid-template-columns: 1fr;
  }
  .edge-cinematic [data-mf-game="edging-tasks"] .mf-ledger {
    grid-column: 1;
    grid-row: auto;
  }
  .edge-cinematic [data-mf-game="edging-tasks"] .mf-body > .mf-actions {
    margin-top: -72px;
  }
}

@media (max-width: 680px) {
  body.edge-cinematic {
    background-attachment: scroll;
    background-size: auto 980px;
  }
  .edge-cinematic #main {
    width: min(100%, calc(100vw - 12px));
  }
  .edge-cinematic .edge-hero-copy {
    min-height: 570px;
    padding: 34px 20px 56px;
  }
  .edge-cinematic .edge-hero h1 {
    font-size: clamp(50px, 16vw, 72px);
    white-space: normal;
  }
  .edge-cinematic .edge-hero .mf-meta {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .edge-cinematic .edge-preservation-seal {
    min-width: 0;
    width: 100%;
  }
  .edge-cinematic [data-mf-game="edging-tasks"] {
    padding-inline: 10px;
  }
  .edge-cinematic [data-mf-game="edging-tasks"] .mf-stat {
    min-width: 78px;
    padding-inline: 10px;
  }
  .edge-cinematic [data-mf-game="edging-tasks"] .mf-card-task {
    min-height: 330px;
    padding: 30px 24px 104px;
  }
  .edge-cinematic [data-mf-game="edging-tasks"] .mf-body > .mf-actions {
    margin-top: -94px;
    padding: 0 24px 20px;
  }
  .edge-cinematic [data-mf-game="edging-tasks"] .mf-ledger {
    min-height: 470px;
    padding: 42px 24px 30px;
    border-width: 8px;
    border-radius: 34px 14px;
  }
  .edge-cinematic [data-mf-game="edging-tasks"] .mf-ledger {
    grid-template-columns: 1fr;
  }
  .edge-cinematic [data-mf-game="edging-tasks"] .mf-ledger-head,
  .edge-cinematic [data-mf-game="edging-tasks"] .edge-ledger-history {
    grid-column: 1;
  }
  .edge-cinematic [data-mf-game="edging-tasks"] .mf-foot {
    padding-inline: 0;
  }
}
