/* Aditiser: language switcher (all languages), Japanese and Chinese typography. */

/* Language switcher in the header */
.lang-switch { display: flex; align-items: center; gap: 2px; flex: 0 0 auto; font-family: var(--wp--preset--font-family--heading); font-size: 14px; font-weight: 600; }
.lang-switch__item { padding: 6px 8px; border-radius: 999px; color: var(--wp--preset--color--blue-100); text-decoration: none; line-height: 1; }
.lang-switch a.lang-switch__item:hover, .lang-switch a.lang-switch__item:focus-visible { color: var(--wp--preset--color--white); background: rgba(255,255,255,.08); }
.lang-switch__item.is-current { color: var(--wp--preset--color--white); background: rgba(255,255,255,.12); }
@media (max-width: 600px) {
	.site-header > .alignwide { gap: 10px !important; }
	.site-header .site-header__logo img { width: 118px !important; height: auto !important; }
	.lang-switch { font-size: 12px; gap: 0; }
	.lang-switch__item { padding: 5px 6px; }
	.site-header__cta .wp-block-button__link { padding: 9px 12px !important; font-size: 13px; }
}
@media (max-width: 480px) {
	.site-header > .alignwide { gap: 6px !important; }
	.site-header .site-header__logo img { width: 100px !important; }
	.lang-switch__item { padding: 4px 5px; }
	.site-header__cta .wp-block-button__link { padding: 8px 10px !important; font-size: 12px; }
}
@media (max-width: 400px) { .site-header .site-header__cta { display: none !important; } } /* three languages + button do not fit on small phones */

/* Japanese pages: Japanese fonts installed on the visitor's device (no extra download), Latin text keeps the theme fonts */
html:lang(ja) {
	--wp--preset--font-family--heading: Inter, "Hiragino Sans", "Hiragino Kaku Gothic ProN", "Noto Sans JP", "Yu Gothic UI", "Yu Gothic", Meiryo, system-ui, sans-serif;
	--wp--preset--font-family--body: 'DM Sans', "Hiragino Sans", "Hiragino Kaku Gothic ProN", "Noto Sans JP", "Yu Gothic UI", "Yu Gothic", Meiryo, system-ui, sans-serif;
	--wp--preset--font-family--accent: Inter, "Hiragino Sans", "Hiragino Kaku Gothic ProN", "Noto Sans JP", "Yu Gothic UI", "Yu Gothic", Meiryo, sans-serif;
}
html:lang(ja) body { line-height: 1.8; }
/* Highlighted words in headings: same yellow/blue colour, upright Japanese type instead of the English italic serif */
html:lang(ja) h1 em, html:lang(ja) h2 em, html:lang(ja) h3 em, html:lang(ja) .has-accent em { font-family: var(--wp--preset--font-family--heading); font-style: normal; font-weight: inherit; letter-spacing: inherit; }
/* Japanese line breaking: keep phrases together in headings, no orphaned characters */
html:lang(ja) h1, html:lang(ja) h2, html:lang(ja) h3, html:lang(ja) h4,
html:lang(ja) .wp-block-button__link, html:lang(ja) .eyebrow { word-break: auto-phrase; line-break: strict; text-wrap: balance; overflow-wrap: anywhere; }
@media (max-width: 600px) { html:lang(ja) h1, html:lang(ja) h2 { word-break: normal; } }
html:lang(ja) h1, html:lang(ja) h2 { letter-spacing: -0.01em; line-height: 1.25; }
html:lang(ja) p, html:lang(ja) li { line-break: strict; overflow-wrap: anywhere; }

/* Tourism strip on the Japanese home page */
.ja-tourism-strip { padding-top: 18px; padding-bottom: 18px; border-top: 1px solid rgba(162,196,246,.18); }
.ja-tourism-strip p { margin: 0; font-size: 15px; color: var(--wp--preset--color--blue-100); }
.ja-tourism-strip strong { color: var(--wp--preset--color--white); margin-right: .6em; }
.ja-tourism-strip__link a { color: var(--wp--preset--color--accent); font-weight: 700; text-decoration: none; white-space: nowrap; }
.ja-tourism-strip__link a:hover { text-decoration: underline; }

/* Staff interview: profile photo in interview articles */
.ja-profile-photo img { width: 160px; height: 160px; object-fit: cover; border-radius: 50%; }

/* Staff interview card on service pages (matches Yukiko's design) */
.ja-interview { padding-top: 0; padding-bottom: 104px; background: #fff; }
.ja-iv-card { background: var(--wp--preset--color--subtle, #f5f7fa); border-radius: 24px; padding: clamp(28px, 4vw, 44px); display: flex; flex-direction: column; gap: 22px; }
.ja-iv-card > * { margin: 0 !important; }
.ja-iv-label { display: flex; align-items: baseline; gap: 14px; flex-wrap: wrap; color: #151c29; }
.ja-iv-label__en { font-family: var(--wp--preset--font-family--heading); font-weight: 500; font-size: 30px; letter-spacing: -0.01em; }
.ja-iv-label__ja { font-family: var(--wp--preset--font-family--heading); font-weight: 700; font-size: 13px; }
.ja-iv-card .ja-iv-title { padding-bottom: 20px; border-bottom: 1px solid #b9c6d8; font-weight: 800; font-size: clamp(1.35rem, 2.2vw, 1.75rem); line-height: 1.45; letter-spacing: -0.01em; color: #151c29; }
.ja-iv-body { display: flex; flex-wrap: wrap; gap: 24px 48px; align-items: flex-start; }
.ja-iv-person { display: flex; gap: 20px; flex: 0 1 380px; min-width: 0; }
.ja-iv-photo { margin: 0; flex: none; }
.ja-iv-photo img { width: 116px; height: 150px; object-fit: cover; object-position: center 25%; border-radius: 12px; display: block; background: #e7ecf3; }
.ja-iv-who { display: flex; flex-direction: column; gap: 10px; min-width: 0; }
.ja-iv-who p { margin: 0; }
.ja-iv-name { font-family: var(--wp--preset--font-family--heading); font-weight: 700; font-size: 17px; color: #151c29; }
.ja-iv-role { font-size: 14px; line-height: 1.7; color: #3c5176; }
.ja-iv-text { flex: 1 1 380px; min-width: 0; display: flex; flex-direction: column; gap: 16px; }
.ja-iv-text p { margin: 0; font-size: 15px; line-height: 1.9; color: #2e3f5b; }
.ja-iv-more a { display: inline-flex; align-items: center; gap: 10px; font-family: var(--wp--preset--font-family--heading); font-weight: 700; font-size: 16px; color: #151c29; text-decoration: none; }
.ja-iv-more a::after { content: ""; width: 20px; height: 20px; background: no-repeat center/20px url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23151c29' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'%3E%3Ccircle cx='12' cy='12' r='10'/%3E%3Cpath d='M8 12h8'/%3E%3Cpath d='M13 8l4 4-4 4'/%3E%3C/svg%3E"); }
.ja-iv-more a:hover { text-decoration: underline; }

/* Japanese pages: stat numbers like 「10年以上」「2,500以上」 stay on one line (slightly smaller so they fit) */
html:lang(ja) .band-stat__num, html:lang(ja) .big-stat__num, html:lang(ja) .csd-stat__num, html:lang(ja) .proof-stat__num,
html:lang(ja) .stat__num, html:lang(ja) .tst-stat__num, html:lang(ja) .info-card__num { white-space: nowrap; word-break: keep-all; overflow-wrap: normal; letter-spacing: -0.03em; }
html:lang(ja) .band-stat__num { font-size: clamp(2rem, 3.4vw, 3rem); }
html:lang(ja) .big-stat__num, html:lang(ja) .stat__num { font-size: clamp(1.9rem, 3.4vw, 3rem); }

/* Japanese pages: main heading on service pages (and About) a little smaller */
html:lang(ja) h1.is-svc-title { font-size: clamp(2.1rem, 4.4vw, 3.6rem); line-height: 1.2; letter-spacing: -0.02em; }

/* Tourism page: "詳しく見る →" link on each service card */
.info-card__more { margin-top: auto !important; padding-top: 8px; }
.info-card__more a { font-family: var(--wp--preset--font-family--heading); font-weight: 700; font-size: 14px; color: var(--wp--preset--color--primary); text-decoration: none; }
.info-card__more a:hover { text-decoration: underline; }
.ja-sec-lead { max-width: 46rem; margin: 0; color: var(--wp--preset--color--neutral-600, #3c5176); }

/* About page, government section: long Japanese heading wraps instead of running under the text box */
html:lang(ja) .gov__titles h2 { word-break: normal; overflow-wrap: anywhere; }

/* Chinese (Simplified) pages: Chinese fonts installed on the visitor's device (no extra download), Latin text keeps the theme fonts */
html:lang(zh) {
	--wp--preset--font-family--heading: Inter, "PingFang SC", "Hiragino Sans GB", "Noto Sans SC", "Source Han Sans SC", "Microsoft YaHei", system-ui, sans-serif;
	--wp--preset--font-family--body: 'DM Sans', "PingFang SC", "Hiragino Sans GB", "Noto Sans SC", "Source Han Sans SC", "Microsoft YaHei", system-ui, sans-serif;
	--wp--preset--font-family--accent: Inter, "PingFang SC", "Hiragino Sans GB", "Noto Sans SC", "Source Han Sans SC", "Microsoft YaHei", sans-serif;
}
html:lang(zh) body { line-height: 1.8; }
html:lang(zh) h1 em, html:lang(zh) h2 em, html:lang(zh) h3 em, html:lang(zh) .has-accent em { font-family: var(--wp--preset--font-family--heading); font-style: normal; font-weight: inherit; letter-spacing: inherit; }
html:lang(zh) h1, html:lang(zh) h2, html:lang(zh) h3, html:lang(zh) h4,
html:lang(zh) .wp-block-button__link, html:lang(zh) .eyebrow { line-break: strict; text-wrap: balance; overflow-wrap: anywhere; }
html:lang(zh) h1, html:lang(zh) h2 { letter-spacing: -0.01em; line-height: 1.3; }
html:lang(zh) p, html:lang(zh) li { line-break: strict; overflow-wrap: anywhere; }
html:lang(zh) .band-stat__num, html:lang(zh) .big-stat__num, html:lang(zh) .csd-stat__num, html:lang(zh) .proof-stat__num,
html:lang(zh) .stat__num, html:lang(zh) .tst-stat__num, html:lang(zh) .info-card__num { white-space: nowrap; word-break: keep-all; overflow-wrap: normal; letter-spacing: -0.03em; }
html:lang(zh) .band-stat__num { font-size: clamp(2rem, 3.4vw, 3rem); }
html:lang(zh) .big-stat__num, html:lang(zh) .stat__num { font-size: clamp(1.9rem, 3.4vw, 3rem); }
html:lang(zh) h1.is-svc-title { font-size: clamp(2.1rem, 4.4vw, 3.6rem); line-height: 1.2; letter-spacing: -0.02em; }
html:lang(zh) .gov__titles h2 { word-break: normal; overflow-wrap: anywhere; }
html:lang(zh) h2.is-jumbo { font-size: clamp(2.4rem, 6vw, 5.2rem); line-height: 1.2; }

/* About page: second team row with four people (all languages) */
.team-grid.team-row-4 { grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 32px 18px; }
@media (max-width: 900px) { .team-grid.team-row-4 { grid-template-columns: repeat(2, minmax(0, 1fr)); } }

/* Japanese team cards: English name in brackets on its own line */
.team-card__name-en { display: block; }
