/* 첫 안내는 화면을 가리지 않고 전시 안에서 이어진다. */
#easyboy-welcome {
  display: grid;
  grid-template-columns: 142px minmax(0, 1fr);
  align-items: center;
  gap: 22px;
  margin: 18px 0 0;
  padding: 18px 22px;
  color: var(--ink, #1A1714);
  background: #FFFDF9;
  border: 1px solid var(--brand-line, #E5CFBB);
  border-top: 3px solid var(--orange, #FF6A00);
  border-radius: 14px;
  box-shadow: 0 4px 0 #F2DFC9;
}
#easyboy-welcome[hidden] { display: none !important; }
.easyboy-welcome-art { display: grid; place-items: center; min-width: 0; }
.easyboy-welcome-art img {
  display: block;
  width: 132px;
  height: 138px;
  object-fit: contain;
  filter: drop-shadow(0 5px 3px #5D2D1020);
}
.easyboy-welcome-copy { min-width: 0; }
.easyboy-eyebrow {
  display: block;
  margin: 0 0 5px;
  color: #974000;
  font-size: 9px;
  font-weight: 800;
  letter-spacing: 1.25px;
}
#easyboy-welcome-title {
  margin: 0;
  color: var(--ink, #1A1714);
  font-size: clamp(20px, 2.3vw, 27px);
  line-height: 1.35;
  letter-spacing: -.65px;
  word-break: keep-all;
}
.easyboy-welcome-copy > p {
  margin: 6px 0 10px;
  color: var(--muted, #6B645B);
  font-size: 12px;
  line-height: 1.65;
  word-break: keep-all;
}
.easyboy-welcome-steps {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin: 0 0 12px;
  padding: 0;
  list-style: none;
}
.easyboy-welcome-steps li {
  display: inline-flex;
  align-items: center;
  min-height: 27px;
  padding: 5px 10px;
  color: #67452D;
  background: #FFF3E8;
  border: 1px solid #F0D8C2;
  border-radius: 20px;
  font-size: 10px;
  font-weight: 700;
  white-space: nowrap;
}
.easyboy-welcome-steps li + li::before {
  content: '→';
  margin-right: 7px;
  color: #A85A1F;
}
.easyboy-welcome-actions { display: flex; align-items: center; flex-wrap: wrap; gap: 8px; }
.easyboy-welcome-actions button,
.easyboy-help {
  min-height: 44px;
  border-radius: 9px;
  font: 700 11px/1.35 Pretendard, sans-serif;
  cursor: pointer;
}
.easyboy-welcome-actions :is([data-easyboy="start"],[data-easyboy="invite-start"]) {
  padding: 10px 16px;
  color: var(--cream, #FFF8EF);
  background: var(--ink, #1A1714);
  border: 1px solid var(--ink, #1A1714);
  box-shadow: 2px 3px 0 #D8B89B;
}
.easyboy-welcome-actions [data-easyboy="dismiss"] {
  padding: 9px 12px;
  color: var(--muted, #6B645B);
  background: transparent;
  border: 1px solid transparent;
}
.easyboy-welcome-actions small {
  flex-basis: 100%;
  color: #82766B;
  font-size: 9px;
  line-height: 1.5;
}
#easyboy-welcome button:focus-visible,
.easyboy-help:focus-visible {
  outline: 3px solid #974000;
  outline-offset: 3px;
}
.easyboy-help {
  flex: none;
  margin-left: 8px;
  padding: 7px 12px;
  color: #753100;
  background: #FFF3E8;
  border: 1px solid #E9C9AC;
}

/* 안내 문장이 길어지거나 글자가 커져도 잘리지 않게 한다. */
.easyboy-coach {
  scroll-margin-top: 90px;
  scroll-margin-bottom: 12px;
  display: flex;
  align-items: center;
  gap: 10px;
  min-height: 54px;
  border-radius: 12px;
  margin-bottom: 12px;
  padding: 5px 16px;
  background: #FFF3E8;
  border-bottom: 1px solid #EBD3BD;
}
.easyboy-coach img {
  flex: none;
  width: 43px;
  height: 48px;
  object-fit: contain;
  object-position: center bottom;
}
.easyboy-coach > div { min-width: 0; }
.easyboy-coach > div > small {
  display: block;
  margin-bottom: 2px;
  color: #974000;
  font-size: 8px;
  font-weight: 800;
  letter-spacing: .7px;
}
.easyboy-coach p {
  margin: 0;
  color: #49382B;
  font-size: 11px;
  font-weight: 600;
  line-height: 1.45;
  overflow-wrap: anywhere;
}
.has-easyboy-coach.is-quest-mode .brand-lab-guide { display:none; }
.has-easyboy-coach.is-quest-mode:is([data-quest-phase=mission],[data-quest-phase=observing]) .journey-kicker { display:none; }
.has-easyboy-coach.is-quest-mode:is([data-quest-phase=mission],[data-quest-phase=observing]) .journey-title { display:none; }
.has-easyboy-coach.is-quest-mode #model-stage .spatial-view { height:280px; }
.easyboy-next { margin-top:13px;padding:12px 15px;border:1px solid #EBCFB5;border-radius:12px;background:#FFF6EA; }
.easyboy-next>span { display:block;margin-bottom:4px;color:#8F4819;font-size:9px;font-weight:800;letter-spacing:.3px; }
.easyboy-next h4 { margin:0;color:#302319;font-size:15px;line-height:1.45;word-break:keep-all; }
.easyboy-next p { margin:4px 0 0;color:#6C5745;font-size:12px;line-height:1.55;word-break:keep-all;overflow-wrap:anywhere; }
.has-easyboy-coach.is-quest-mode[data-quest-phase=reward] .journey-reward .journey-copy { display:none; }
.lesson-body:has(.is-hall-reward) #lesson-modebar { display:none; }
.exhibit-theatre.is-hall-reward { display:block; }
.exhibit-theatre.is-hall-reward #quest-play { padding:20px; }
.exhibit-theatre.is-hall-reward :is(#motion-guide,#model-stage,#interactive-lab,.motion-caption) { display:none!important; }

@media (max-width: 650px) {
  #easyboy-welcome {
    display:block;
    margin-top: 12px;
    padding: 16px;
    border-radius: 11px;
  }
  .easyboy-welcome-art { float:right;margin:0 0 8px 8px; }
  .easyboy-welcome-art img { width: 64px; height: 75px; }
  .easyboy-eyebrow { font-size: 8px; letter-spacing: .3px; margin-bottom: 5px; }
  #easyboy-welcome-title { font-size: 21px; line-height: 1.35; letter-spacing: -.4px; }
  .easyboy-welcome-copy > p { clear:both;margin: 10px 0; font-size: 12px; line-height: 1.6; }
  .easyboy-welcome-steps { gap: 4px; margin-bottom: 8px; }
  .easyboy-welcome-steps li { min-height: 27px; padding: 5px 7px; font-size: 10px; }
  .easyboy-welcome-steps li + li::before { margin-right: 4px; }
  .easyboy-welcome-actions { grid-column: 1 / -1; gap: 6px; }
  .easyboy-welcome-actions button { min-height: 44px; font-size: 12px; }
  .easyboy-welcome-actions :is([data-easyboy="start"],[data-easyboy="continue"],[data-easyboy="invite-start"]) { flex: 1 1 100%; padding-inline: 10px; }
  .easyboy-welcome-actions [data-easyboy="dismiss"] { flex:1 1 100%;padding-inline: 9px; }
  .easyboy-welcome-actions small { font-size: 10px; }
  .easyboy-help { min-height: 44px; margin-left: 4px; padding: 6px 9px; font-size: 10px; }
  .museum-utility { flex-wrap:wrap;gap:8px; }
  .museum-utility .crumb { flex:1 1 50%; }
  .museum-utility .search { margin-left:auto; }
  .easyboy-coach { gap: 7px; min-height: 51px; padding: 8px; }
  .easyboy-coach img { width: 39px; height: 46px; }
  .easyboy-coach p { font-size: 12px; line-height: 1.5; }
  .has-easyboy-coach.is-quest-mode .mechanism-title { padding:10px 15px 0; }
  .has-easyboy-coach.is-quest-mode .mechanism-title>h3 { font-size:16px!important; }
  .has-easyboy-coach.is-quest-mode #model-stage .spatial-view { height:240px; }
  .easyboy-next { margin-top:11px;padding:11px 12px; }
  .easyboy-next h4 { font-size:14px; }
  .exhibit-theatre.is-hall-reward #quest-play { padding:12px; }
  .has-easyboy-coach.is-quest-mode[data-quest-phase=reward] .journey-actions>.journey-primary { flex-basis:100%; }
  /* 첫 실험은 직접 누를 버튼을 먼저 보여준다. 보조 조작은 그 아래에 둔다. */
  .has-easyboy-coach.is-quest-mode #interactive-lab .mx-controls [data-action="tamper"] { flex-basis:100%;order:-1;background:#FFF0E3;border-color:#F29B55;font-weight:700; }
  .has-easyboy-coach.is-quest-mode #interactive-lab .mx-controls button:not([data-action="tamper"]) { flex:1; }
}

@media (max-width: 370px) {
  #easyboy-welcome { padding: 14px; }
  .easyboy-welcome-art img { width: 56px; height: 62px; }
  #easyboy-welcome-title { font-size: 20px; }
  .easyboy-welcome-steps { gap: 3px; }
  .easyboy-welcome-steps li { padding-inline: 5px; font-size: 10px; }
  .easyboy-welcome-steps li + li::before { margin-right: 3px; }
}

@media (prefers-reduced-motion: no-preference) {
  #easyboy-welcome { animation: easyboy-welcome-in .32s ease-out both; }
  @keyframes easyboy-welcome-in {
    from { opacity: 0; transform: translateY(5px); }
    to { opacity: 1; transform: translateY(0); }
  }
}

/* 같은 탭으로 돌아가되, 각 서비스의 기록은 그대로 둔다. */
.next-handoff{display:flex;align-items:center;gap:12px;margin:10px 0;padding:0 12px;border:1px solid #EBD3BD;border-radius:10px;background:#FFF3E8;color:#67452D;font-size:12px;line-height:1.45;min-width:0}
.next-handoff[hidden]{display:none!important}
.next-handoff a{display:inline-flex;align-items:center;flex:none;min-height:44px;color:#753100;font-weight:800;text-decoration:none}
.next-handoff a:focus-visible{outline:3px solid #FF6A00;outline-offset:2px;border-radius:4px}
.next-handoff span{min-width:0;word-break:keep-all;overflow-wrap:anywhere}
.lesson-body>.next-handoff{margin:0 0 12px}
@media(max-width:650px){.next-handoff{font-size:11px;gap:8px;padding-inline:9px}.lesson-body>.next-handoff{margin-bottom:10px}}

/* 보상 원본을 옮기지 않고 NEXT의 탐험 수첩에 요약을 불러온다. */
.museum-next-collection{display:flex;align-items:center;gap:18px;background:#FFF0E1;border:1px solid #EBD3BD;border-radius:20px;padding:22px;margin:0 0 24px}
.museum-next-collection img{width:72px;height:80px;object-fit:contain;flex:none}
.museum-next-collection h2{font-size:20px;margin:0 0 8px;line-height:1.4}
.museum-next-collection p{font-size:14px;color:#67452D;margin:0 0 14px;line-height:1.6}
.museum-next-collection a{display:inline-flex;align-items:center;justify-content:center;min-height:44px;text-decoration:none;padding:11px 16px;border-radius:10px}
@media(max-width:650px){.museum-next-collection{padding:16px;gap:12px}.museum-next-collection img{width:48px;height:60px}.museum-next-collection h2{font-size:17px}.museum-next-collection p{font-size:12px}.museum-next-collection a{font-size:12px}.next-handoff{flex-wrap:wrap;gap:0 10px;padding-block:4px}.next-handoff span{flex:1 1 120px}}

/* 초대받은 친구는 첫 화면에서 안내와 시작 버튼을 함께 만난다. */
#easyboy-welcome[data-entry="invite"] { scroll-margin-top:110px; background:#FFF8EF; border-top-color:#FF6A00; }
#easyboy-welcome[data-entry="invite"] .easyboy-welcome-actions { margin-top:10px; }

.museum-separate-note{margin:0 0 18px;padding:12px 16px;border-radius:12px;background:#FFF0E1;border:1px solid #EBD3BD;font-size:13px;line-height:1.6}
