/* A score-free introductory rehearsal, layered above the existing concert scene. */
#modal .concert-scene.first-organ-tutorial-active .concert-start{display:none!important}
#modal .concert-scene.first-organ-tutorial-active .concert-motto{opacity:.18}
#modal .concert-scene.first-organ-tutorial-active .concert-hud{opacity:.30}
#modal .concert-scene.first-organ-tutorial-active .concert-orientation{display:none}
#modal .concert-scene .first-organ-lesson-card{display:none;position:absolute;top:27%;left:50%;transform:translateX(-50%);width:min(86%,420px);z-index:14;padding:12px 15px 10px;box-sizing:border-box;border-radius:17px;background:linear-gradient(150deg,rgba(36,25,18,.95),rgba(61,42,24,.95));border:1px solid #f0cb86b9;box-shadow:0 10px 38px rgba(0,0,0,.57);color:#f9e3b8;text-align:center;font-family:'Noto Serif JP','Yu Mincho',serif;}
#modal .concert-scene.first-organ-tutorial-active .first-organ-lesson-card{display:block}
#modal .concert-scene .first-organ-lesson-card.is-intro{top:41%;padding:18px 15px 16px}
#modal .concert-scene .first-organ-step{display:block;color:#ffe0a1;font-size:11px;font-weight:700;letter-spacing:.04em;margin-bottom:6px}
#modal .concert-scene .first-organ-lesson-card h3{font-family:inherit;font-size:clamp(15px,3.9vw,20px);line-height:1.45;color:#fff0cd;margin:0 0 8px}
#modal .concert-scene .first-organ-lesson-card p{font-family:inherit;font-size:clamp(12px,3.2vw,15px);line-height:1.55;color:#f2debf;margin:0 0 9px;word-break:normal;overflow-wrap:anywhere}
#modal .concert-scene .first-organ-lesson-actions{display:flex;flex-direction:column;align-items:stretch;gap:9px;margin:11px auto 0;max-width:300px}
#modal .concert-scene .first-organ-mini-actions{display:flex;justify-content:center;gap:12px;margin-top:8px}
#modal .concert-scene .first-organ-lesson-card button{font-family:inherit;min-height:38px!important;font-size:12px!important;border:1px solid #ceb17d!important;border-radius:10px!important;padding:7px 14px!important;background:#30271ecc!important;color:#f1d8b2!important;white-space:normal!important;cursor:pointer;touch-action:manipulation}
#modal .concert-scene .first-organ-lesson-card button.first-organ-primary{background:linear-gradient(145deg,#ffe6b5,#d5a45e)!important;border-color:#f9e0a7!important;color:#382513!important;font-weight:700}
#modal .concert-scene .first-organ-lesson-note{position:absolute;z-index:9;pointer-events:none;width:clamp(25px,6vw,46px);height:clamp(15px,3vw,24px);background:linear-gradient(#fff9db,#f2c266);border:2px solid #fff2bb;box-shadow:0 0 12px #ffdc88,0 0 25px #e6a94b99;border-radius:7px;opacity:0;will-change:left,top,transform;}
#modal .concert-scene .first-organ-lesson-line{display:none;position:absolute;top:96%;left:0;right:0;height:4px;border-radius:5px;z-index:8;pointer-events:none;background:#fff5c6;box-shadow:0 0 8px 3px #ffd98a,0 0 18px #f3b642}
#modal .concert-scene.first-organ-tutorial-active .first-organ-lesson-line{display:block}
#modal .concert-scene .first-organ-lesson-key-cue{position:absolute;top:70%;z-index:9;transform:translateX(-50%);font:bold 12px Georgia;color:#fff1d4;text-shadow:0 0 8px #f1b45e;opacity:0;pointer-events:none;white-space:nowrap}
#modal .concert-scene .rhythm-key.first-organ-lesson-target{outline:3px solid #fff8c4!important;outline-offset:1px;filter:brightness(1.22)!important;box-shadow:0 0 16px 5px rgba(255,211,112,.91),inset 0 -4px #957033!important;animation:first-organ-key-glow 1.4s ease-in-out infinite!important}
#modal .concert-scene .rhythm-key.first-organ-lesson-correct{filter:brightness(1.45)!important;box-shadow:0 0 20px 8px #fff4a8!important}
#modal .concert-scene .concert-start small{white-space:normal!important;display:block;max-width:100%;overflow-wrap:anywhere}
#modal .concert-scene .first-organ-replay{display:block!important;min-height:32px!important;padding:6px 10px!important;margin:8px auto 0!important;border:1px solid #d0b783!important;border-radius:9px!important;background:#322919!important;color:#fae3b3!important;font-size:11px!important}
@keyframes first-organ-key-glow{50%{filter:brightness(1.5);outline-color:#ffd16e}}
@media(max-width:520px){#modal .concert-scene .first-organ-lesson-card{top:25%;width:88%;padding:9px 11px 8px}#modal .concert-scene .first-organ-lesson-card.is-intro{top:42%;padding:14px 12px}#modal .concert-scene .first-organ-lesson-card h3{margin-bottom:5px}#modal .concert-scene .first-organ-lesson-card p{line-height:1.5;font-size:12px}#modal .concert-scene .first-organ-lesson-card button{min-height:36px!important}}
@media(orientation:landscape) and (max-height:520px){#modal .concert-scene .first-organ-lesson-card{top:12%;width:43%;left:72%;padding:7px 10px}#modal .concert-scene .first-organ-lesson-card.is-intro{top:25%;left:50%;width:min(75%,350px)}#modal .concert-scene .first-organ-lesson-card h3{font-size:13px;margin-bottom:3px}#modal .concert-scene .first-organ-lesson-card p{font-size:10px;line-height:1.35}#modal .concert-scene .first-organ-lesson-card button{min-height:29px!important;padding:4px 8px!important}}
@media(prefers-reduced-motion:reduce){#modal .concert-scene .rhythm-key.first-organ-lesson-target{animation:none!important}}
/* Count-in is real only after the user starts the full song. */
#modal .concert-scene.first-organ-tutorial-active #practiceCountdown{display:none!important}
/* Prevent the old one-line count-in copy from sitting beside / beyond the button. */
#modal.first-practice-simple-modal .concert-scene .concert-start{display:flex!important;flex-direction:column!important;align-items:center!important;justify-content:center!important;gap:7px!important;max-width:86%!important}
#modal.first-practice-simple-modal .concert-scene .concert-start small{display:block!important;white-space:normal!important;max-width:100%!important;margin:0 auto!important;font-size:11px!important;line-height:1.45!important;text-align:center!important}
#modal.first-practice-simple-modal .concert-scene .concert-start .first-organ-replay{display:block!important;margin:3px auto 0!important}

/* v0.80.659: A live performance must never show the pre-start overlay.
   The stronger selector wins over the initial mobile flex rule above;
   runtime also removes the gate node when the song begins. */
#modal.first-practice-simple-modal .concert-scene.first-organ-tutorial-active .concert-start,
#modal.first-practice-simple-modal.practice-live-input .concert-scene .concert-start,
#modal.practice-live-input .concert-scene .concert-start.started{display:none!important;visibility:hidden!important;pointer-events:none!important}

/* v0.80.659: Never cover the falling notes or the playable keys while teaching.
   The runway begins at 23% of the scene; anchor the *bottom* of the exercise
   strip 10px above it, regardless of screen height, notch, or orientation. */
#modal .concert-scene.first-organ-tutorial-active .first-organ-lesson-card.is-exercise{
  display:flex!important;
  top:auto!important;
  bottom:calc(77% + 10px)!important;
  left:50%!important;
  transform:translateX(-50%)!important;
  width:min(94%,520px)!important;
  max-height:calc(23% - 18px)!important;
  padding:6px 9px!important;
  gap:8px;
  align-items:center;
  text-align:left;
  overflow:hidden;
  box-shadow:0 3px 10px rgba(0,0,0,.38);
  background:rgba(37,27,19,.90);
}
#modal .concert-scene .first-organ-lesson-card.is-exercise .first-organ-exercise-info{flex:1;min-width:0;}
#modal .concert-scene .first-organ-lesson-card.is-exercise .first-organ-step{
  font-size:10px!important;line-height:1.3!important;margin:0 0 2px!important;
  display:block;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;
}
#modal .concert-scene .first-organ-lesson-card.is-exercise p{
  margin:0!important;font-size:11px!important;line-height:1.35!important;
  overflow:hidden;display:-webkit-box;-webkit-box-orient:vertical;-webkit-line-clamp:2;
}
#modal .concert-scene .first-organ-lesson-card.is-exercise .first-organ-mini-actions{
  display:flex;flex-direction:column;flex:none;gap:4px;margin:0!important;
}
#modal .concert-scene .first-organ-lesson-card.is-exercise .first-organ-mini-actions button{
  min-height:30px!important;min-width:69px!important;padding:3px 7px!important;
  font-size:10px!important;line-height:1.2!important;
}
@media (max-height:550px){
 #modal .concert-scene .first-organ-lesson-card.is-exercise p{-webkit-line-clamp:1!important;}
 #modal .concert-scene .first-organ-lesson-card.is-exercise .first-organ-mini-actions button{min-height:23px!important;}
}
/* The compact landscape concert starts its runway at 20%, not 23%. */
@media (orientation:landscape) and (max-height:480px){
 #modal .concert-scene.first-organ-tutorial-active .first-organ-lesson-card.is-exercise{
   bottom:calc(80% + 10px)!important;
   max-height:calc(20% - 12px)!important;
   padding:3px 7px!important;
 }
}

/* Keep the tutorial strike line on the same wooden runway. */
#modal .concert-scene .first-organ-lesson-line{left:2%;right:2%}
