@import url('https://fonts.googleapis.com/css2?family=Pretendard:wght@400;500;600&display=swap');

:root{
  --carrot:#FF6F0F;
  --carrot-weak:rgba(255,111,15,0.08);
  --bg:#f6f7f9;
  --text:#222;
  --line:#eaeaea;
  --card:#ffffff;
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
  font-family: Pretendard, -apple-system, BlinkMacSystemFont, "Apple SD Gothic Neo",
               "Noto Sans KR", "Segoe UI", sans-serif;
}

body {
  background-image: url("bg_main.png");
  background-size: cover;
  background-position: center top;
  background-repeat: no-repeat;

  color: var(--text);
  min-height: 100vh;   /* ✅ 이 줄만 추가 */
}

/* =========================
   화면
   ========================= */
.screen {
  display: none;
  min-height: 100vh;
  height: auto;
  padding: 0;           /* ✅ 전체본문 확장 허용 */
  text-align: center;
}

#screen-start,
#screen-menu{
  padding: 40px 20px;
}

.screen.active {
  display: flex;
  flex-direction: column;
  align-items: center;
}

.title {
  font-size: 32px;
  margin-bottom: 24px;
  font-weight: 700;
  color: #111;
}

/* 시작 화면 안내 문구 */
.start-desc{
  font-size: 14px;
  color: #555;
  margin-bottom: 14px;
}

/* 닉네임 입력 */
.nickname-input{
  width: 100%;
  max-width: 240px;
  margin: 0 auto 20px;

  padding: 12px;
  font-size: 14px;
  text-align: center;

  border-radius: 10px;
  border: 1px solid #ccc;
}

/* 시작 화면 버튼 */
#screen-start .primary-btn {
  color: #fff;             /* 글자 흰색 */
  background: var(--carrot); /* 당근색 배경 */
  border: none;
  font-weight: 700;
  padding: 18px 40px;
  border-radius: 12px;
  cursor: pointer;
  transition: transform .08s, filter .15s;
}

#screen-start .primary-btn:hover {
  filter: brightness(0.97);
}

#screen-start .primary-btn:active {
  transform: scale(0.98);
}

/* 메인 화면 제목 */
.screen .title {
  font-size: 32px;
  margin-bottom: 40px;
  font-weight: 700;
  color: #111;             /* 검정 유지 */
}

/* =========================
   공통 버튼
   ========================= */
/* 앱카드 내부 버튼만 글씨 진한 회색 */
#screen-part-listen .back-btn,
#screen-text .back-btn {
  color: #222;       /* 글씨색 변경 */
}

/* 메인 제목과 버튼 글씨 색상 통일 */
.screen .title,
.primary-btn {
  color: #111;       /* 검정/진한 글씨 */
}

/* primary-btn 기존 배경 유지 */
.primary-btn {
  padding: 18px 40px;
  border-radius: 12px;
  border: none;
  background: var(--carrot);
  color: white;
  font-size: 16px;
  font-weight: 700;
  cursor: pointer;
  transition: transform .08s, filter .15s;
}

/* =========================
   전체듣기 오디오 컨트롤 (전용)
   ========================= */

.all-controls{
  display: flex;
  justify-content: center;
  gap: 12px;
  margin: 18px 0 14px;
}

/* 기본 상태 : 하얀 버튼 */
.ctrl-btn{
  background: #ffffff;
  color: #2f5d46;

  border: 1px solid rgba(63,127,95,0.28);
  box-shadow: 0 2px 6px rgba(0,0,0,0.08);

  width: 96px;
  height: 44px;

  font-size: 16px;
  font-weight: 800;

  border-radius: 14px;
  cursor: pointer;

  transition: background-color .15s,
              box-shadow .15s,
              transform .08s;
}

/* hover */
.ctrl-btn:hover{
  background: #f4f8f5;
  box-shadow: 0 6px 14px rgba(0,0,0,0.12);
}

/* 눌림(클릭 순간) */
.ctrl-btn:active{
  transform: scale(0.96);
}

/* 활성 상태 : 현재 선택된 버튼 */
.ctrl-btn.active{
  background: linear-gradient(180deg, #c9f2e3, #aee8d3);
  color: #1f3d33;

  border-color: #8fd6bc;
  box-shadow: 0 4px 0 #7cc9ae;

  transform: translateY(1px);
}

/* 재생 버튼 크기 고정 */
#btnAllPlay{
  width: 96px;
  height: 44px;
  font-size: 16px;   /* ✅ 다른 버튼과 동일 */
  font-weight: 800;
  padding: 0;
}

/* =========================
   본문보기 절 오디오 아이콘 전용
   ========================= */

.verse-audio-ctrl{
  display: flex;
  gap: 6px;
}

.audio-icon{
  width: 30px;
  height: 30px;
  border-radius: 50%;

  display: flex;
  align-items: center;
  justify-content: center;

  cursor: pointer;
  transition: background-color .15s, transform .1s;
}

.audio-icon:hover{
  background: rgba(63,127,95,0.12);
  transform: scale(1.05);
}

.audio-icon:active{
  transform: scale(0.96);
}

/* =========================
   공통 뒤로가기 버튼
   ========================= */

.back-btn{
  margin-top: 20px;
  padding: 12px 18px;

  border-radius: 10px;
  border: 1px solid #ddd;
  background: #fff;

  cursor: pointer;
  transition: background-color .15s,
              border-color .15s,
              color .15s;
}

.back-btn:hover{
  background: var(--carrot-weak);
  border-color: var(--carrot);
  color: var(--carrot);
}

/* =========================
   메뉴
   ========================= */
.menu {
  width: 100%;
  max-width: 360px;

  display: flex;
  flex-direction: column;
  gap: 26px;

  margin: 36px auto 0;
}

/* 메뉴 하단 영역 */
.menu-footer{
  margin-top: 28px;
  text-align: center;
}

/* 닉네임 변경 텍스트 버튼 */
.text-btn{
  background: none;
  border: none;
  padding: 6px 8px;

  font-size: 13px;
  color: #666;
  cursor: pointer;
}

.text-btn:hover{
  color: var(--carrot);
}

.menu-btn {
  padding: 22px 20px;
  font-size: 17px;
  font-weight: 700;

  border-radius: 18px;
  border: 1px solid rgba(63,127,95,0.35);

  background: #f6f5ef;          /* 종이톤 */
  color: #2f5d46;               /* 숲 글씨색 */

  cursor: pointer;
  box-shadow: 0 4px 10px rgba(0,0,0,0.08);
  transition: transform .12s, box-shadow .15s, background-color .15s;
}

.menu-btn:hover {
  background: #ffffff;
  transform: translateY(-2px);
  box-shadow: 0 6px 16px rgba(0,0,0,0.12);
}

.menu-btn:active {
  transform: scale(0.98);
}

/* =========================
   듣기 화면(예비)
   ========================= */
.listen-info{
  font-size: 14px;
  color:#666;
  margin-bottom: 32px;
}

.listen-verse{
  width: 100%;
  max-width: none;
  margin-left: 0;          /* ❌ 음수 마진 제거 */
  margin-right: 0;

  background: rgba(255,255,255,0.9);
  border: 1px solid rgba(0,0,0,0.10);
  border-radius: 20px;

  padding: 22px 16px;      /* ⬅ 좌우 최대 확장 */
  margin-bottom: 32px;

  text-align: left;
  line-height: 1.75;

  word-break: keep-all;
  overflow-wrap: anywhere; /* ⬅ 화면 밖 탈출 방지 */

  box-shadow: 0 6px 14px rgba(0,0,0,0.12);
}

/* =========================
   상단 헤더 (제목 중앙 + 메인화면 버튼 우측)
   ========================= */
.header-row {
  width: 100%;
  max-width: 520px;     /* 본문 폭과 동일 */
  margin: 0 auto 12px;
  padding-bottom: 12px;

  display: flex;
  justify-content: space-between;  /* 좌/우 분리 */
  align-items: center;

  border-bottom: 1px solid var(--line);
}

/* 제목 */
.header-row .title {
  margin: 0;
  flex: 1;
  text-align: center;              /* 중앙 유지 */
}

/* 메인화면 버튼 (1.5배 확대) */
.home-btn {
  position: static;
  padding: 10px 16px;        /* ⬅ 크기 체감 1.5배 */
  font-size: 16px;           /* ⬅ 가독성 강화 */

  background: #f6f5ef;
  color: #2f5d46;
  border: 1px solid rgba(63,127,95,0.28);

  border-radius: 999px;
  cursor: pointer;
  font-weight: 800;          /* ⬅ 버튼 위계 강화 */
  box-shadow: 0 4px 10px rgba(0,0,0,0.08);
  transition: background-color .15s, box-shadow .15s, transform .08s;
}

.home-btn:hover {
  background: #ffffff;
  box-shadow: 0 6px 14px rgba(0,0,0,0.12);
}

.home-btn:active {
  transform: scale(0.96);
}

/* =========================
   탭(모드)
   ========================= */
.mode-tabs{
  width: 100%;
  max-width: 520px;              /* 기준 유지 */
  margin: 12px auto 18px;

  display: flex;
  justify-content: center;
  gap: 10px;
}

/* 🔧 “꽉 찬” 느낌 제거: 각 버튼 최대폭 제한 */
.tab{
  flex: 0 1 148px;               /* 🔧 폭 줄임 + 반응형 */
  max-width: 148px;

  height: 42px;                  /* 🔧 살짝 낮춤 */
  padding: 0 12px;

  border-radius: 999px;          /* 🔧 가볍게(투박 제거) */
  border: 1px solid rgba(0,0,0,0.08);  /* 🔧 테두리 약화 */
  background: rgba(255,255,255,0.75);  /* 🔧 종이톤 */

  font-size: 16px;               /* 🔧 살짝 감소 */
  font-weight: 600;              /* 🔧 기본 무게 낮춤 */

  cursor: pointer;
  transition: background-color .15s, border-color .15s, color .15s;

  display: flex;
  align-items: center;
  justify-content: center;

  white-space: nowrap;
}

/* 🔹 전체듣기와 동일한 ‘은은한 활성 톤’ */
.tab.active{
  background: #f4f8f5;                 /* 종이+숲 톤 */
  border-color: rgba(63,127,95,0.45);
  color: #2f5d46;
  font-weight: 800;
}

/* hover는 이미 적절 → 유지 */
.action-btn:hover{
  background: rgba(63,127,95,0.12);
  border-color: #3f7f5f;
  color: #3f7f5f;
}

/* 별 상태도 ‘채움 제거 + 은은’ */
.status-slot.star{
  background: #f4f8f5;
  border-color: rgba(63,127,95,0.45);
  color: #2f5d46;
}

/* =========================
   상태 필터
   ========================= */
.status-filter{
  width: 100%;
  max-width: 520px;              /* 기준 유지 */
  margin: 0 auto 18px;

  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;

  padding: 0 6px;                /* 🔧 좌우 숨통 */
}

.status-filter .break{
  display: none;
}

.status-filter button{
  height: 42px;                  /* 🔧 살짝 낮춤 */
  padding: 0 10px;

  display: flex;
  align-items: center;
  justify-content: center;

  border-radius: 999px;          /* 🔧 부드럽게(투박 제거) */
  border: 1px solid rgba(0,0,0,0.08);  /* 🔧 테두리 약화 */
  background: rgba(255,255,255,0.75);  /* 🔧 종이톤 */

  font-size: 16px;               /* 🔧 살짝 감소 */
  font-weight: 600;              /* 🔧 기본 무게 낮춤 */

  cursor: pointer;
  transition: background-color .15s, border-color .15s, color .15s;
}

.status-filter button:hover{
  background: var(--carrot-weak);
  border-color: var(--carrot);
  color: var(--carrot);
}

.status-filter button.on{
  background: #fff;
  border-color: var(--carrot);
  color: var(--carrot);
  font-weight: 700;
}

/* =========================
   본문 리스트
   ========================= */
.verse-list{
  width: 100%;
  max-width: none;
  margin: 0 auto;
  text-align: left;
}

/* PC만 폭 제한 */
@media (min-width: 1024px){
  .verse-list{
    max-width: 760px;
  }
}

.verse {
  position: relative;
  padding: 18px 16px;
  margin-bottom: 16px;

  background: rgba(255,255,255,0.92);       /* 🌿 숲 컨셉 카드 */
  border: 2px solid rgba(63,127,95,0.35);
  box-shadow: 0 6px 16px rgba(0,0,0,0.10);
  border-radius: 16px;

  cursor: pointer;
  box-shadow: 0 4px 12px rgba(0,0,0,0.08);
  transition: box-shadow .15s, transform .12s;
}

.verse:hover {
  box-shadow: 0 6px 16px rgba(0,0,0,0.12);
}

.verse:hover {
  box-shadow: 0 5px 14px rgba(0,0,0,0.10);
}

.verse-text {
  background: transparent;
  color: #2f3a2e;                            /* 잉크 느낌 */
  line-height: 1.6;
}

/* 체크박스 + 절 제목(Isaiah 53:1) 같은 줄 */
/* 기본: 여백 없음 */
.verse-head{
  display:flex;
  align-items:center;
  gap:10px;
  padding-right:0;
}

/* 영문 모드에서만 스피커 공간 확보 */
#screen-text.mode-en .verse-head{
  padding-right:52px;
}

/* 본문: 좌우 100% 확장 */
.verse-body{
  margin-top: 10px;
  padding-left: 0;
  padding-right: 0;
}

/* 마우스 오버 */
.verse:hover{
  border-color: #e0e0e0;
}

/* 선택 시 배경 유지, 외곽선 강조 */
.verse.selected {
  background: #fefefe;
  border: 2px solid #3f7f5f; /* 🌿 숲색 */
  box-shadow: 0 0 0 3px rgba(63,127,95,0.12);
}

/* 상태 슬롯(동그라미) */
.status-slot{
  width: 22px;
  height: 22px;
  border-radius: 6px;
  border: 2px solid #d6d6d6;
  flex: 0 0 22px;
  margin-top: 2px;

  display: flex;
  align-items: center;
  justify-content: center;

  font-size: 14px;
  font-weight: 700;
  color: transparent;
}

/* 미암송 */
.status-slot.none{
  background: transparent;
}

/* 암송완료 = 체크 */
.status-slot.done{
  background: #22c55e;
  border-color: #22c55e;
  color: #fff;
}
.status-slot.done::before{
  content: "✓";
}

/* 집중암송 = 별 */
.status-slot.star{
  background: var(--carrot);
  border-color: var(--carrot);
  color: #fff;
}
.status-slot.star::before{
  content: "★";
}


/* 본문 텍스트 */
.verse-text{
  font-size: 19px;
  line-height: 1.85;
  color: #222;
  word-break: keep-all;
  overflow-wrap: anywhere;   /* ← 이 줄 추가 */
}

/* ✅ 사전 단어 밑줄(영문 전용에서 JS가 이 클래스만 붙일 예정) */
.dict-word{
  text-decoration: underline;
  text-decoration-thickness: 2px;
  text-underline-offset: 3px;
  cursor: pointer;
}

/* =========================
   컬러바 (절 아래로 이동)
   ========================= */
.color-bar{
  width: 100%;
  max-width: 520px;
  margin: 0 auto 14px;
  padding: 12px 10px;

  display: flex;
  flex-wrap: wrap;
  gap: 10px;

  background: #f7faf8; /* 🌿 연한 종이톤 */
  border: 1px solid rgba(63,127,95,0.18);
  border-radius: 12px;

  /* 🔑 부드러운 등장/사라짐 */
  opacity: 0;
  transform: translateY(-6px);
  transition: opacity .18s ease, transform .18s ease;
}

.color-bar.show{
  opacity: 1;
  transform: translateY(0);
}

/* ===== 1줄: 색상 ===== */
.color{
  width: 26px;
  height: 26px;
  border-radius: 50%;
  flex: 0 0 auto;
}

/* 줄 강제 분리 */
.bar-break{
  flex: 0 0 100%;               /* ✅ 여기서 정확히 줄 끊음 */
  height: 0;
}

/* ===== 2줄: 암송 버튼 ===== */
.action-btn{
  flex: 0 0 auto;
  white-space: nowrap;
}

/* 해제 버튼은 오른쪽 끝 */
.action-btn.clear{
  margin-left: auto;
}

.color{
  width: 26px;
  height: 26px;
  border-radius: 50%;
  cursor: pointer;
  border: 2px solid rgba(0,0,0,0.06);
  transition: transform .08s;
}
.color:active{ transform: scale(0.96); }

.bar-break{
  flex: 1 1 100%;
  height: 0;
}

/* =========================
   상태 버튼 (컬러바 안) - 최종 확정본
   ========================= */

/* 공통 */
.action-btn{
  background: linear-gradient(180deg, #c9f2e3, #aee8d3);
  color: #1f3d33;

  border: 1px solid #8fd6bc;
  box-shadow: 0 4px 0 #7cc9ae;

  padding: 10px 14px;
  font-size: 14px;
  font-weight: 600;

  border-radius: 10px;
  cursor: pointer;
  white-space: nowrap;

  transition: background .12s, box-shadow .12s, transform .1s;
}

.action-btn:active{
  background: linear-gradient(180deg, #9edec3, #8fd6bc);
  box-shadow: 0 2px 0 #6ab59c;
  transform: translateY(2px);
}

.action-btn:hover{
  background: var(--carrot-weak);
  border-color: var(--carrot);
  color: var(--carrot);
}

/* 암송완료 */
.action-btn.done{
  border-color: rgba(34,197,94,0.45);
}
.action-btn.done::before{
  content: "✓";
  margin-right: 4px;
  font-weight: 800;
}

/* 집중암송 */
.action-btn.star{
  border-color: rgba(255,111,15,0.45);
}
.action-btn.star::before{
  content: "★";
  margin-right: 4px;
  font-weight: 800;
}

/* 해제 버튼 (폭만 작게, 높이/폰트 동일) */
.action-btn.clear{
  margin-left: auto;      /* 우측 정렬 */
  padding: 10px 10px;     /* 좌우만 축소 */
  opacity: 0.85;
  border-color: rgba(0,0,0,0.18);
}

/* =========================
   중앙 카드 컨테이너 (숲/동화 컨셉)
   ========================= */
.app-card {
  background: rgba(255,255,255,0.72);
  backdrop-filter: blur(3px);

  border-radius: 22px;
  padding: 40px 12px 36px;   /* ⬅ 좌우 여백 축소 */
  width: 100%;               /* ⬅ 화면 끝까지 */
  max-width: none;
  margin: 24px auto 0;

  box-shadow: 0 8px 22px rgba(0,0,0,0.08);
}

/* =========================
   절 상단 헤더 (체크박스 + 절 번호)
   ========================= */
.verse-header{
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 8px;
}

/* =========================
   절 우측 상단 오디오 컨트롤 (재생/정지/반복)
   ========================= */
/* =========================
   절 우측 상단 오디오 컨트롤 (기본 복구)
   ========================= */
.verse-audio-ctrl{
  position: absolute;
  top: 12px;
  right: 12px;

  display: flex;
  gap: 6px;

  height: 30px;
  z-index: 2;
}

/* ✅ 구문/한글에서만 숨김 */
#screen-text.mode-split .verse-audio-ctrl,
#screen-text.mode-kr .verse-audio-ctrl{
  display: none !important;
}

.audio-icon:hover{
  background: rgba(63,127,95,0.12);
  transform: scale(1.05);
}

.audio-icon{
  width:30px;
  height:30px;

  border-radius:50%;
  cursor:pointer;

  transition:background-color .15s, transform .1s;
}

.audio-icon:hover{
  background: rgba(63,127,95,0.12);
  transform: scale(1.05);
}

.audio-icon.hidden{
  display:none;
}

/* 절 제목 (위계 강화) */
.verse-title{
  font-size: 20px;        /* ⬅ 본문(19px)보다 살짝 큼 */
  font-weight: 800;
  color: #111;
  white-space: nowrap;
}

/* =========================
   본문보기: 전체본문 박스 100% 확장 (핵심)
   ========================= */
#screen-text .app-card{
  background: linear-gradient(
    180deg,
    #d6f5ea,
    #c2efdf
  );

  width: 100%;
  max-width: none;
  margin: 0;
  border-radius: 0;

  padding: 36px 12px 32px;
  box-shadow: 0 8px 22px rgba(0,0,0,0.08);
}

/* =========================
   텍스트 선택 색상 통일 (당근 제거)
   ========================= */
::selection {
  background: rgba(63,127,95,0.25);
  color: #111;
}

::-moz-selection {
  background: rgba(63,127,95,0.25);
  color: #111;
}

/* =========================
   메인 화면 버튼 (menu-btn) – 최종본
   ========================= */
.menu-btn{
  background: linear-gradient(180deg, #d4f5e8, #bfeedd);
  color: #1f3d33;

  border: 1px solid #9adbc3;
  box-shadow: 0 4px 0 #86cbb2;

  font-weight: 700;
}

.menu-btn:active{
  background: linear-gradient(180deg, #bfeedd, #a6e5cd);
  box-shadow: 0 2px 0 #6fb8a0;
  transform: translateY(2px);
}

/* =========================
   본문 액션 버튼 (암송완료 / 집중암송 / 해제)
   ========================= */
.action-btn{
  background: linear-gradient(180deg, #c9f2e3, #aee8d3);
  color: #1f3d33;

  border: 1px solid #8fd6bc;
  box-shadow: 0 4px 0 #7cc9ae;
}

.action-btn:active{
  background: linear-gradient(180deg, #9edec3, #8fd6bc);
  box-shadow: 0 2px 0 #6ab59c;
  transform: translateY(2px);
}

/* =========================
   언어 탭 (영문 / 구문 / 한글)
   ========================= */

/* 기본 상태 */
.tab{
  background: rgba(255,255,255,0.85);
  color: #2f5d46;

  border: 1px solid rgba(63,127,95,0.25);
  box-shadow: 0 2px 0 rgba(63,127,95,0.18);

  font-weight: 600;
  transition: background .12s, box-shadow .12s, transform .1s;
}

/* 눌림 */
.tab:active{
  background: #f4f8f5;
  box-shadow: 0 1px 0 rgba(63,127,95,0.25);
  transform: translateY(1px);
}

/* 선택됨 */
.tab.active{
  background: linear-gradient(180deg, #c9f2e3, #aee8d3);
  color: #113328;

  border-color: #8fd6bc;
  box-shadow: 0 3px 0 #7cc9ae;

  font-weight: 800;
}

#colorBar{
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
}

/* 🔹 단어사전 버튼을 우측 끝선 기준으로 정렬 */
#btn-dict{
  margin-left: auto;     /* 핵심 */
  min-width: 64px;
  padding: 8px 10px;
}

/*********************************************************
 * 단어사전 팝업 디자인 (전문 사전 스타일)
 *********************************************************/
#dict-popup{
  position: fixed;
  left: 50%;
  bottom: 24px;
  transform: translateX(-50%);
  z-index: 9999;

  display: none;
  width: calc(100% - 32px);
  max-width: 420px;
}

.dict-popup-inner{
  position: relative;                 /* 🔑 꼬리 기준 */
  background: #f6f1e8;
  border-radius: 16px;
  padding: 18px 16px 16px;

  box-shadow: 0 10px 28px rgba(0,0,0,0.18);
  border: 1px solid rgba(0,0,0,0.08);

  max-width: min(320px, 90vw);
  word-break: keep-all;

  animation: dictPopupUp .18s ease-out;
}

/* 말풍선 꼬리 */
.dict-popup-inner::after{
  content: "";
  position: absolute;
  top: -8px;                          /* 카드 상단 중앙 */
  left: 24px;

  width: 0;
  height: 0;

  border-left: 8px solid transparent;
  border-right: 8px solid transparent;
  border-bottom: 8px solid #f6f1e8;   /* 카드 색과 동일 */
}

/* 단어 카드 전체 */
.dict-popup-inner{
  background: #f6f1e8;                 /* ✅ 베이지 */
  border-radius: 16px;
  padding: 18px 16px 16px;

  box-shadow: 0 10px 28px rgba(0,0,0,0.18);
  border: 1px solid rgba(0,0,0,0.08);

  max-width: min(320px, 90vw);         /* ✅ 화면 잘림 방지 */
  word-break: keep-all;

  animation: dictPopupUp .18s ease-out;
}

/* 단어 제목 */
.dict-title{
  font-size: 20px;
  font-weight: 800;
  color: #1f3d33;
  margin-bottom: 8px;
}

/* 뜻 영역 */
.dict-meaning{
  font-size: 15px;
  line-height: 1.6;
  color: #333;
}

/* 등장 애니메이션 */
@keyframes dictPopupUp{
  from{
    opacity: 0;
    transform: translateY(12px);
  }
  to{
    opacity: 1;
    transform: translateY(0);
  }
}

/* =========================
   단어사전 버튼: 영문(en)에서만 보이기
   ========================= */

/* 기본: 숨김 (구문/한글 포함 전부 숨김) */
#btn-dict{
  display: none !important;
}

/* 영문 모드일 때만 표시 */
#screen-text.mode-en #btn-dict{
  display: inline-flex !important;
}

/* =========================
   PC 전용: 전체듣기 화면 폭 제한
   (본문보기와 동일한 레이아웃)
   ========================= */
@media (min-width: 1024px){

  /* 전체듣기 화면의 카드 자체를 제한 */
  #screen-all-listen .app-card{
    max-width: 860px !important;
    margin: 24px auto 0 !important;
    border-radius: 22px !important;
  }

  /* 전체듣기 본문 카드 */
  #screen-all-listen .listen-verse{
    max-width: 760px !important;
    margin: 0 auto 32px !important;
  }
}

.dev-credit{
  position: fixed;
  right: 10px;
  bottom: 10px;

  padding: 6px 10px;
  border-radius: 999px;

  background: rgba(0,0,0,0.45);   /* 🔑 대비 확보 */
  color: #fff;                    /* 🔑 확실한 가독성 */

  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.2px;

  backdrop-filter: blur(4px);     /* 🌿 배경과 자연스럽게 */
  z-index: 20;
}

/* =========================
   캐릭터 표시 영역 (메인)
   ========================= */
.character-box {
  width: 100%;
  margin: 20px 0 10px;
  padding: 14px;
  background: #000;              /* ✅ 검은 박스 */
  border-radius: 16px;
  display: flex;
  justify-content: center;
  align-items: center;
}

.character-box img {
  width: 100%;
  max-width: 420px;              /* ✅ 모바일 기준 최대 */
  height: auto;
  display: block;
}

/* 🔥 진화 전체화면 오버레이 */
.evo-overlay {
  position: fixed;
  inset: 0;
  background: #000;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 9999;
}

.evo-overlay img {
  max-width: 90vw;
  max-height: 70vh;
  object-fit: contain;
}

/* 사전 모드일 때만 밑줄 보이기 */
#screen-text.dict-on .word{
  text-decoration: underline;
  text-underline-offset: 3px;
}

/* =========================
   단어사전 버튼: 클릭 후 눌림 표시 제거
   ========================= */
#btn-dict:focus,
#btn-dict:focus-visible {
  outline: none;
  box-shadow: none;
}

/* =========================
   단어사전 버튼: 눌림/활성 효과 완전 차단
   ========================= */
#btn-dict,
#btn-dict:hover,
#btn-dict:active,
#btn-dict:focus,
#btn-dict.active {
  background: linear-gradient(180deg, #c9f2e3, #aee8d3) !important;
  color: #1f3d33 !important;
  border: 1px solid #8fd6bc !important;
  box-shadow: 0 4px 0 #7cc9ae !important;
  transform: none !important;
  outline: none !important;
}






