/* U243: the 일본어(JLPT) pages (design planning/japanese/design_preview). Subject colour --jp, its tint --jp-tint; one filled navy button a screen; green and red only for right and
   wrong. Japanese text carries lang="ja": Japanese letter shapes from an installed Japanese font (no web font is fetched). */
.jl { --jp: #B4235A; --jp-tint: #FCEEF3; }
.jl [lang="ja"], .jl-solve [lang="ja"], .wg-play [lang="ja"], .jl:lang(ja) { font-family: "Noto Sans JP", "Hiragino Sans", "Yu Gothic UI", "Yu Gothic", "Meiryo", "MS PGothic", sans-serif; }
/* JP013: the N3 texts have no spaces between words. The site keeps Korean words whole; Japanese breaks between characters, never before its punctuation */
.jl [lang="ja"], .jl-solve [lang="ja"], .wg-play [lang="ja"] { word-break: normal; line-break: strict; }
.jl-in { max-width: 1120px; margin: 0 auto; padding: 0 24px; }
.jl--part .jl-in { max-width: 760px; }
.jl-head { background: var(--jp-tint); }
.jl-head .jl-in { padding-top: 22px; padding-bottom: 26px; }
.jl-head .breadcrumb { font-size: 13px; color: #4B515C; margin-bottom: 12px; line-height: 1.7; }
.jl-head .breadcrumb a { color: #4B515C; padding: 0; }
.jl-head .breadcrumb .sep { margin: 0 6px; color: #6B7684; }
.jl-tag { display: inline-block; margin: 0; padding: 3px 10px; border-radius: 8px; background: var(--jp); color: #fff; font-size: 13px; font-weight: 800; }
.jl-head h1 { margin: 10px 0 6px; font-size: 30px; line-height: 1.35; font-weight: 900; color: #1F2329; }
.jl-lead { margin: 0; max-width: 720px; font-size: 15.5px; line-height: 1.65; color: #4B515C; }
.jl-main .jl-in { padding-top: 26px; padding-bottom: 56px; display: flex; flex-direction: column; gap: 34px; }
.jl-main .ad-wrap { margin: 0; }
.jl-sec h2 { margin: 0 0 12px; font-size: 20px; font-weight: 800; color: #1F2329; }
.jl-sec h2 small { margin-left: 6px; font-size: 13px; font-weight: 700; color: #4B515C; }
.jl-sec[id] { scroll-margin-top: 12px; }
.jl-small { margin: 8px 0 0; font-size: 13.5px; line-height: 1.7; color: #4B515C; }
.jl-btn { display: inline-flex; align-items: center; justify-content: center; min-height: 48px; min-width: 44px; padding: 0 22px; box-sizing: border-box; border: 1px solid #0F1E46; border-radius: 12px; background: #fff; color: #0F1E46; font: inherit; font-size: 15.5px; font-weight: 800; cursor: pointer; text-decoration: none; }
.jl-btn:hover { text-decoration: none; background: #F2F4F8; }
.jl .jl-btn--navy, .jl-btn--navy { background: #0F1E46; color: #fff; }
.jl .jl-btn--navy:hover, .jl-btn--navy:hover { background: #1A2C5E; color: #fff; }
.jl-acts { display: flex; gap: 10px; flex-wrap: wrap; }
.jl-head .jl-acts { margin-top: 16px; }
.jl-more { display: inline-flex; align-items: center; gap: 4px; min-height: 44px; font-weight: 800; color: #1F3C88; }
.jl-card { border: 1px solid #E6E8EC; border-radius: 14px; background: #fff; padding: 16px; }
.jl-card h3 { margin: 0; font-size: 16.5px; font-weight: 800; color: #1F2329; }
.jl-card h3 a { color: inherit; display: inline-flex; align-items: center; min-height: 44px; }
.jl-card p { margin: 4px 0 0; font-size: 14px; line-height: 1.6; color: #4B515C; }

/* the hub: one N3 card (U251) */
.jl-n3 { border: 2px solid var(--jp); max-width: 560px; }
.jl .jl-n3 h3 { font-size: 24px; color: var(--jp); margin-bottom: 4px; }
.jl-n3 .jl-acts { margin-top: 14px; align-items: center; gap: 8px 18px; }
.jl-n3 .jl-acts .jl-btn { flex: 1 1 200px; }
.jl-note { margin: 0; padding: 14px 16px; border-radius: 12px; background: #EEF2F9; font-size: 14.5px; line-height: 1.75; color: #1F2329; }
.jl-note a { display: inline-flex; align-items: center; gap: 4px; min-height: 44px; color: #1F3C88; text-decoration: underline; font-weight: 800; }

/* the level page */
.jl-chips { display: flex; gap: 8px; flex-wrap: wrap; }
.jl-chips a { display: inline-flex; align-items: center; min-height: 44px; padding: 0 16px; border: 1px solid #D9DCE3; border-radius: 999px; background: #fff; color: #1F2329; font-size: 14px; font-weight: 700; text-decoration: none; }
.jl-sets { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 12px; }
.jl-card--set { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 10px 20px; align-items: center; }
.jl-card--set .dl-count { grid-column: 1 / -1; margin: 0; text-align: left; }
.jl-wsets { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 10px; list-style: none; margin: 0; padding: 0; }
.jl-wset { display: flex; flex-direction: column; gap: 6px; height: 100%; box-sizing: border-box; color: #1F2329; text-decoration: none; }
.jl-wset:hover { text-decoration: none; border-color: var(--jp); }
.jl-wset > span { font-size: 14px; color: #4B515C; line-height: 1.6; overflow-wrap: anywhere; }
.jl-wset__games { display: flex; gap: 4px; flex-wrap: wrap; }
.jl-wset__games i { font-style: normal; font-size: 12px; padding: 2px 9px; border: 1px solid #D9DCE3; border-radius: 999px; }
.jl-table { width: 100%; border-collapse: collapse; font-size: 14.5px; margin-bottom: 14px; }
.jl-table caption { text-align: left; font-size: 14px; font-weight: 800; padding-bottom: 6px; color: #1F2329; }
.jl-table th, .jl-table td { border: 1px solid #E6E8EC; padding: 9px 10px; text-align: left; vertical-align: top; overflow-wrap: anywhere; }
.jl-table thead th { background: #F7F8FA; font-size: 13px; }
.jl-table tbody th { font-weight: 700; }
.jl-table--words tbody th { font-size: 17px; }
.jl-jmdict { margin: -6px 0 0; font-size: 12.5px; line-height: 1.6; color: #4B515C; }

/* the N3 page as a practice hub (U251): two columns on a wide screen, the side column below the practices on a narrow one */
.jl-hub { display: grid; grid-template-columns: minmax(0, 1fr) 300px; gap: 28px; align-items: start; }
.jl-col { display: flex; flex-direction: column; gap: 34px; min-width: 0; }
.jl-sec__line { margin: -4px 0 12px; }
.jl-progress { color: var(--jp); font-weight: 700; }
.jl-card p.jl-progress { color: var(--jp); }
.jl-types { list-style: none; margin: 0; padding: 0; border-top: 1px solid #E6E8EC; }
.jl-type { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 4px 14px; align-items: center; padding: 8px 0; border-bottom: 1px solid #E6E8EC; }
.jl-type h3 { margin: 0; font-size: 15.5px; font-weight: 800; }
.jl-type h3 a { color: #1F2329; display: inline-flex; align-items: center; min-height: 30px; }
.jl-type p { margin: 0; font-size: 13px; line-height: 1.6; color: #4B515C; }
.jl-type .jl-btn { min-height: 44px; min-width: 128px; padding: 0 14px; font-size: 14.5px; }
.jl-side { display: flex; flex-direction: column; gap: 12px; min-width: 0; }
.jl-side h2 { margin: 0 0 6px; font-size: 15px; font-weight: 800; color: #1F2329; }
.jl-side p, .jl-side li { font-size: 14px; line-height: 1.7; color: #1F2329; }
.jl-side p { margin: 0; }
.jl-side ol { margin: 0; padding-left: 18px; }
.jl-side [data-jl-wrong] ul { list-style: none; margin: 10px 0 0; padding: 0; display: flex; flex-direction: column; gap: 8px; }
.jl-side [data-jl-wrong] ul[hidden] { display: none; }
.jl-side [data-jl-wrong] .jl-btn { width: 100%; min-height: 44px; padding: 6px 12px; text-align: center; font-size: 14px; }
.jl-card--gray { background: #F7F8FA; }
.jl-tag--line { margin-left: 6px; background: #fff; color: var(--jp); box-shadow: inset 0 0 0 1px var(--jp); }

/* 독해: the 情報検索 table scrolls inside its own box; a long passage is folded on the solve screen */
.jl-scroll { overflow-x: auto; max-width: 100%; }
.jl-table--notice { min-width: 520px; font-size: 14px; line-height: 1.7; margin: 8px 0 0; }
.jl-table--notice th, .jl-table--notice td { overflow-wrap: normal; }
.jl-passage.is-folded { max-height: 15em; overflow: hidden; -webkit-mask-image: linear-gradient(#000 70%, transparent); mask-image: linear-gradient(#000 70%, transparent); margin-bottom: 4px; }
.jl-solve .jl-fold { width: 100%; min-height: 44px; margin-bottom: 14px; }
.jl-gist { margin: 18px 0 4px; padding: 10px 12px; border-radius: 10px; background: #F7F8FA; font-size: 14px; line-height: 1.75; }
.jl-gist b { display: block; margin-bottom: 2px; font-size: 13px; }

/* the word set page */
.jl-games { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; }
.jl-game { display: flex; align-items: center; justify-content: center; gap: 4px; min-height: 48px; padding: 4px 6px; text-align: center; border: 1px solid #D9DCE3; border-radius: 12px; background: #fff; color: #0F1E46; font-size: 14.5px; font-weight: 800; text-decoration: none; }
.jl-game:hover { text-decoration: none; border-color: var(--jp); }
.jl-game.is-done { background: #F1F3F6; border-color: #B9C0CC; }
.jl .jl-start { width: 100%; margin-top: 12px; }
.jl-examples { list-style: none; margin: 0; padding: 0; }
.jl-examples li { display: flex; flex-direction: column; gap: 2px; padding: 12px 0; border-bottom: 1px solid #E6E8EC; line-height: 1.7; }
.jl-examples li > span:last-child { font-size: 13.5px; color: #4B515C; }
.jl-examples b { color: var(--jp); }
.jl-pager { display: flex; justify-content: space-between; gap: 12px; }
.jl-report { display: inline-flex; align-items: center; min-height: 44px; padding: 0; border: 0; background: none; font: inherit; font-size: 13px; color: #4B515C; text-decoration: underline; cursor: pointer; }

/* the part page: the questions and 정답과 해설 */
.jl-group { margin-bottom: 26px; }
.jl-group h3 { margin: 0 0 10px; font-size: 15px; line-height: 1.7; font-weight: 700; color: #1F2329; }
.jl-group h3 small { margin-left: 6px; font-size: 12.5px; color: var(--jp); font-weight: 800; white-space: nowrap; }
.jl-qs { list-style: none; margin: 0; padding: 0; }
.jl-qs > li { display: grid; grid-template-columns: 30px minmax(0, 1fr); gap: 8px; padding: 12px 0; border-bottom: 1px solid #E6E8EC; }
.jl-no { font-size: 13px; font-weight: 800; color: #4B515C; padding-top: 4px; }
.jl-stem { margin: 0 0 6px; font-size: 17px; line-height: 1.9; }
.jl-opts { display: flex; flex-wrap: wrap; gap: 4px 22px; list-style: none; margin: 0; padding: 0; font-size: 15.5px; line-height: 1.8; }
.jl-opts li > span:first-child { font-size: 12.5px; color: #4B515C; }
.jl u, .jl-solve u { text-decoration: underline; text-underline-offset: 5px; text-decoration-thickness: 2px; }
.jl .blank i, .jl-solve .blank i { display: inline-block; width: 4.5em; }
.jl .slots, .jl-solve .slots { display: inline-flex; gap: 6px; align-items: flex-end; vertical-align: baseline; }
.jl .slot, .jl-solve .slot { display: inline-flex; align-items: flex-end; justify-content: center; width: 2.6em; min-height: 1.4em; border-bottom: 2px solid #1F2329; font-size: 0.95em; }
.jl-passage { padding: 14px 16px; border: 1px solid #D5DAE3; border-radius: 12px; background: #fff; font-size: 16px; line-height: 2; margin-bottom: 12px; }
.jl-passage p { margin: 0 0 8px; }
.jl-passage p:last-child { margin-bottom: 0; }
.jl .gap, .jl-solve .gap { white-space: nowrap; }
.jl-solve .gap.is-now { padding: 0 2px; border-radius: 6px; background: #FFF3B0; }
.jl-ans { border-bottom: 1px solid #E6E8EC; }
.jl-ans summary { display: flex; align-items: center; min-height: 48px; font-size: 14.5px; font-weight: 700; cursor: pointer; }
.jl-ans p { margin: 0 0 10px; line-height: 1.75; font-size: 14.5px; }
.jl-ans__right { font-size: 16.5px; font-weight: 700; }
.jl-trap { padding: 10px 12px; border-left: 4px solid #FFE94A; border-radius: 6px; background: #FFF8CC; font-size: 14px; line-height: 1.7; }
.jl-trap b { margin-right: 4px; }

/* the web solve (#solve): in the page, one question at a time */
.jl--part.is-solving .jl-listonly { display: none; }
.jl--part.is-solving .jl-head .jl-in { padding-bottom: 14px; }
.jl--part.is-solving .jl-head h1 { font-size: 19px; }
.jl--part.is-solving .jl-main .jl-in { padding-top: 12px; gap: 56px; }
.jl-solve[hidden] { display: none; }
.jl-solve { min-height: 640px; }
.js-solve { display: none; }
.jl-top { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.jl-where { margin: 0; font-size: 13.5px; color: #4B515C; outline: none; }
.jl-x { flex: 0 0 44px; width: 44px; height: 44px; border: 0; background: transparent; font-size: 18px; color: #1F2329; cursor: pointer; }
.jl-bar { display: block; height: 5px; border-radius: 3px; background: #E6E8EC; overflow: hidden; margin-bottom: 14px; }
.jl-bar i { display: block; height: 100%; background: #1F3C88; }
.jl-ask { margin: 0 0 8px; font-size: 13px; line-height: 1.7; color: #4B515C; }
.jl-solve .jl-stem { font-size: 19px; margin-bottom: 12px; overflow-wrap: anywhere; }
.jl-choices { display: flex; flex-direction: column; gap: 10px; }
.jl-choice { display: flex; align-items: center; gap: 10px; width: 100%; min-height: 52px; padding: 10px 12px; box-sizing: border-box; text-align: left; border: 1px solid #D9DCE3; border-radius: 12px; background: #fff; color: #1F2329; font: inherit; font-size: 17px; line-height: 1.6; cursor: pointer; }
.jl-choice .jl-num { flex: 0 0 26px; height: 26px; display: inline-flex; align-items: center; justify-content: center; border: 1px solid #D9DCE3; border-radius: 50%; font-size: 12.5px; font-weight: 800; }
.jl-choice:disabled { cursor: default; color: #1F2329; opacity: 1; }
.jl-choice.is-ok { border-color: #1B6B33; background: #EAF6EE; }
.jl-choice.is-ok .jl-num { background: #1B6B33; border-color: #1B6B33; color: #fff; }
.jl-choice.is-no { border-color: #B42318; background: #FDECEA; }
.jl-choice.is-no .jl-num { background: #B42318; border-color: #B42318; color: #fff; }
.jl-panel { margin-top: 14px; padding: 14px 16px; border-radius: 12px; background: #F7F8FA; line-height: 1.75; font-size: 14.5px; outline: none; }
.jl-panel b { display: block; margin-bottom: 4px; font-size: 15px; }
.jl-panel p { margin: 0; }
.jl-solve .jl-trap { margin: 10px 0 0; }
.jl-foot { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 18px; }
.jl-foot .jl-btn { flex: 1 1 160px; }
.jl-link { min-height: 44px; padding: 0 4px; border: 0; background: transparent; color: #1F3C88; font: inherit; font-size: 14px; font-weight: 700; text-decoration: underline; cursor: pointer; }
.jl-result { text-align: center; }
.jl-result h2 { margin: 4px 0; font-size: 15px; color: #4B515C; outline: none; }
.jl-score { margin: 0; font-size: 46px; font-weight: 900; color: #0F1E46; }
.jl-result .jl-table { margin-top: 14px; text-align: left; }

/* U255: the exam information page */
.jl-nextexam { border: 2px solid var(--jp); border-radius: 14px; padding: 16px 18px; max-width: 560px; }
.jl-nextexam h2 { margin: 0; font-size: 13.5px; color: var(--jp); }
.jl-nextexam__day { margin: 4px 0 2px; font-size: 24px; font-weight: 900; color: #1F2329; }
.jl-nextexam p { margin: 2px 0 0; font-size: 14.5px; line-height: 1.7; }
.jl-nextexam .jl-btn { width: 100%; margin-top: 14px; }
.jl-exam .jl-table { margin-bottom: 0; }
.jl-exam .jl-table th, .jl-exam .jl-table td { word-break: keep-all; }
.jl-exam .jl-table ul { list-style: none; margin: 0; padding: 0; }
.jl-checked { margin: 8px 0 16px; font-size: 12.5px; line-height: 1.7; color: #4B515C; }
.jl-state { display: inline-block; padding: 1px 8px; border: 1px solid #D9DCE3; border-radius: 999px; font-size: 12.5px; font-weight: 800; white-space: nowrap; }
.jl-state--closed { background: #F1F3F6; color: #4B515C; }
.jl-exam h3 { margin: 18px 0 8px; font-size: 15.5px; font-weight: 800; }
.jl-list { margin: 8px 0 0; padding-left: 20px; font-size: 14.5px; line-height: 1.8; }
.jl-about { margin: 0; display: grid; grid-template-columns: max-content minmax(0, 1fr); gap: 8px 14px; font-size: 14.5px; line-height: 1.7; }
.jl-about dt { font-weight: 900; } .jl-about dd { margin: 0; }
.jl-links { list-style: none; margin: 0; padding: 0; }
.jl-links li { padding: 8px 0; border-bottom: 1px solid #E6E8EC; }
.jl-links a { display: inline-flex; align-items: center; gap: 4px; min-height: 44px; font-weight: 800; color: #1F3C88; text-decoration: underline; }
.jl-links span { display: block; font-size: 13.5px; line-height: 1.6; color: #4B515C; }
.jl-note .jl-note__more { margin-left: 12px; }
.jl-examlink { margin: 0 0 4px; }
@media (max-width: 700px) {                                  /* each exam date is a card, so no column hides off the side */
  .jl-table--dates, .jl-table--dates tbody { display: block; }
  .jl-table--dates thead { position: absolute; left: -9999px; }
  .jl-table--dates tr { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 2px 8px; border: 1px solid #E6E8EC; border-radius: 12px; padding: 10px 12px; margin-bottom: 8px; }
  .jl-exam .jl-table--dates th, .jl-exam .jl-table--dates td { border: 0; padding: 0; }
  .jl-table--dates th { grid-column: 1; grid-row: 1; font-size: 15px; }
  .jl-table--dates td { grid-column: 1 / -1; }
  .jl-table--dates td[data-label]::before { content: attr(data-label) " "; color: #4B515C; font-size: 12.5px; font-weight: 700; margin-right: 4px; }
  .jl-table--dates td:last-child { grid-column: 2; grid-row: 1; }
  .jl-exam .jl-table th, .jl-exam .jl-table td { padding: 8px 6px; font-size: 13.5px; }
}

@media (max-width: 960px) {
  .jl-hub { grid-template-columns: minmax(0, 1fr); }
}

@media (max-width: 700px) {
  .jl-in { padding: 0 16px; }
  .jl-head h1 { font-size: 24px; }
  .jl-card--set { grid-template-columns: minmax(0, 1fr); }
  .jl-card--set .jl-acts .jl-btn { flex: 1 1 0; padding: 0 10px; }
  .jl-table--words th, .jl-table--words td { padding: 8px 6px; }
  .jl-table--words tbody th { font-size: 16px; }
}
