/* Character collection: the original artworks retain their complete composition. */
.characters-section { padding: 70px var(--gutter) 72px; background: var(--paper); border-bottom: 1px solid var(--line); }
.characters-heading { display: flex; align-items: flex-end; justify-content: space-between; gap: 40px; margin: 53px 0 42px; }
.characters-heading-ko { font-size: .82rem; display: block; letter-spacing: .1em; margin-bottom: 18px; }
.characters-heading .display-title { font-size: clamp(48px, 6.7vw, 125px); white-space: nowrap; }
.characters-heading .display-title em { color: var(--ink); -webkit-text-stroke: 1px var(--ink); color: transparent; }
.characters-heading > p { font-size: .84rem; line-height: 1.9; padding-bottom: 5px; }
.characters-toolbar { display: flex; justify-content: space-between; align-items: center; gap: 25px; padding: 19px 0 15px; border-top: 1px solid var(--line); }
.character-filters { display: flex; flex-wrap: wrap; gap: 5px; }
.character-filters button { min-height: 38px; padding: 9px 14px; border-radius: 30px; font-size: .74rem; background: none; transition: background .2s, color .2s; }
.character-filters button[aria-pressed="true"] { background: var(--ink); color: var(--paper); }
.character-filters button:hover:not([aria-pressed="true"]) { background: #deded5; }
.character-filters button span { margin-left: 7px; font: .6rem var(--mono); }
.characters-hover-hint { font: .56rem var(--mono); white-space: nowrap; color: var(--muted); display: flex; gap: 18px; align-items: center; }
.characters-hover-hint > span { font-size: 1rem; }
.characters-instructions { font-size: .72rem; line-height: 1.7; color: var(--muted); margin-bottom: 25px; }
.character-grid { list-style: none; padding: 0; margin: 0; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 34px 24px; }
.character-item { min-width: 0; perspective: 1200px; }
.character-card { display: block; width: 100%; padding: 0; background: transparent; text-align: left; }
.character-card-art { display: block; position: relative; aspect-ratio: 941 / 1672; background: #171b1e; box-shadow: 0 8px 18px #1111110a; transition: transform .55s var(--ease), box-shadow .5s; transform-origin: center; transform-style: preserve-3d; border: 1px solid #191a1926; }
.character-card-art > img { width: 100%; height: 100%; object-fit: contain; }
.character-card.is-turning .character-card-art { transform: perspective(1100px) rotateY(-17deg) rotateZ(-1.5deg) translateY(-6px); box-shadow: 12px 15px 30px #1113; }
.character-card:focus-visible .character-card-art { box-shadow: 0 0 0 3px var(--blue), 0 10px 25px #1112; }
.character-card-number { position: absolute; top: 12px; left: 12px; font: .6rem var(--mono); border: 1px solid #fff5; padding: 6px; background: #1119; color: white; backdrop-filter: blur(6px); }
.character-card-open { position: absolute; right: 13px; top: 13px; width: 28px; height: 28px; border: 1px solid #fff7; border-radius: 50%; color: white; display: grid; place-items: center; background: #1116; opacity: 0; transform: translateY(4px); transition: opacity .25s, transform .25s; }
.character-card:hover .character-card-open, .character-card:focus-visible .character-card-open { opacity: 1; transform: none; }
.character-card-caption { display: flex; align-items: center; justify-content: space-between; gap: 14px; padding-top: 16px; }
.character-card-caption strong { font-size: 1.08rem; font-weight: 600; letter-spacing: -.035em; display: block; }
.character-card-caption small { color: var(--muted); display: block; font-size: .72rem; margin-top: 6px; }
.character-card-weapon { font-size: .64rem; border: 1px solid var(--line); padding: 6px 9px; color: #575b53; }
.characters-bottom { display: flex; justify-content: space-between; gap: 20px; margin-top: 39px; border-top: 1px solid var(--line); padding-top: 18px; color: var(--muted); font-size: .7rem; line-height: 1.8; }
.characters-bottom > span { font: .55rem/1.8 var(--mono); }
.desktop-nav { padding-left: 0; gap: clamp(18px, 2.5vw, 40px); }
/* Native modal supplies inert background and focus boundary; the backdrop stays hoverable. */
.character-dialog { --character-accent: #e5c17c; background: transparent; width: min(1200px, calc(100vw - 80px)); max-width: calc(100vw - 40px); max-height: calc(100dvh - 40px); overflow: visible; padding: 0; }
.character-dialog[open] { animation: none; }
.character-dialog[data-accent="ruby"] { --character-accent: #efa4af; }
.character-dialog[data-accent="blue"] { --character-accent: #a2c9ed; }
.character-dialog::backdrop { background: #0b1012b3; backdrop-filter: blur(22px) saturate(.5); }
.character-dialog.is-closing::backdrop { background: #0b101200; backdrop-filter: blur(0); transition: background .25s, backdrop-filter .25s; }
.character-spread { display: grid; grid-template-columns: minmax(0, .9fr) minmax(0, 1.15fr); gap: clamp(28px, 4vw, 72px); align-items: center; }
.character-visual { min-width: 0; display: flex; flex-direction: column; align-items: center; }
.character-visual-label { width: 100%; max-width: 405px; display: flex; justify-content: space-between; gap: 20px; color: #e4e7df; font: .6rem/1.6 var(--mono); letter-spacing: .07em; margin-bottom: 16px; }
.character-figure { display: block; padding: 0; border: 0; background: transparent; color: inherit; height: min(75dvh, 720px); aspect-ratio: 941 / 1672; max-width: 100%; position: relative; perspective: 1700px; filter: drop-shadow(0 25px 35px #0007); cursor: pointer; touch-action: manipulation; }
.character-figure:disabled { cursor: progress; }
.character-figure:focus-visible { outline: 2px solid var(--character-accent); outline-offset: 7px; }
.character-flipper { display: block; width: 100%; height: 100%; position: relative; transform-style: preserve-3d; transition: transform 950ms cubic-bezier(.2,.75,.23,1); }
.character-dialog.is-flipped .character-flipper { transform: rotateY(180deg); }
.character-face { position: absolute; inset: 0; overflow: hidden; backface-visibility: hidden; -webkit-backface-visibility: hidden; border: 1px solid #f5ead149; background: #111; }
.character-face img { width: 100%; height: 100%; object-fit: contain; }
.character-face::after { content: ""; position: absolute; inset: -35% -80%; pointer-events: none; background: linear-gradient(112deg, transparent 36%, #fff4 44%, #fff9 49%, #fff2 54%, transparent 63%); transform: translateX(-65%); opacity: 0; mix-blend-mode: screen; }
.character-figure.is-shining .character-face::after { animation: character-sheen 950ms cubic-bezier(.22,.6,.3,1) both; }
@keyframes character-sheen { 0% { transform: translateX(-65%); opacity: 0; } 18% { opacity: .5; } 48% { opacity: .85; } 100% { transform: translateX(65%); opacity: 0; } }
.character-back { transform: rotateY(180deg); }
.character-art-status { color: #d2d7cd; font-size: .63rem; line-height: 1.6; text-align: center; min-height: 1.6em; margin-top: 14px; }
.character-flip-hint { color: #c9d0d3; font-size: .6rem; line-height: 1.6; margin-top: 5px; text-align: center; text-shadow: 0 2px 8px #000; }
.character-flip-hint span { color: var(--character-accent); font-size: .9rem; margin-right: 5px; }
.character-profile { --line: #e3e8ed24; --muted: #bdc6cc; background: linear-gradient(105deg, #090e13e0, #090e13c9 68%, #090e139e); color: #f4f3ed; height: min(83dvh, 800px); display: flex; flex-direction: column; min-height: 0; min-width: 0; border: 0; box-shadow: 0 24px 75px #0005; text-shadow: 0 2px 12px #0008; }
.character-profile-top { padding: 17px 28px 15px; display: flex; align-items: center; justify-content: space-between; gap: 20px; border-bottom: 1px solid var(--line); flex-shrink: 0; }
.character-profile-top > span { font: .57rem var(--mono); letter-spacing: .12em; color: var(--muted); }
.character-close { background: transparent; color: inherit; min-width: 50px; min-height: 36px; display: flex; align-items: center; gap: 14px; padding: 4px 0 4px 9px; font-size: .7rem; }
.character-close span { font-size: 1.7rem; line-height: 1; }
.character-profile-scroll { overflow-y: auto; overscroll-behavior: contain; min-height: 0; padding: 34px 36px 36px; scrollbar-width: thin; scrollbar-color: #6d7880 transparent; flex: 1; }
.character-profile-scroll:focus-visible { outline-offset: -4px; }
.character-class { color: var(--character-accent); font-size: .82rem; font-weight: 600; letter-spacing: .1em; margin-bottom: 10px; }
#character-name { font-size: clamp(38px, 4vw, 64px); font-weight: 500; letter-spacing: -.065em; line-height: 1.1; margin-bottom: 19px; }
.character-basic { display: flex; flex-wrap: wrap; gap: 10px; font-size: .72rem; color: var(--muted); }
.character-basic span + span::before { content: "/"; margin-right: 10px; color: #b7b9ae; }
.character-quote { padding: 20px 0 24px; margin: 24px 0 0; border-top: 1px solid var(--line); font-size: clamp(1rem, 1.3vw, 1.25rem); line-height: 1.8; letter-spacing: -.04em; word-break: keep-all; overflow-wrap: anywhere; }
.character-quote::before { content: "“"; color: var(--character-accent); margin-right: .2em; }
.character-quote::after { content: "”"; color: var(--character-accent); margin-left: .2em; }
.character-facts { margin: 0; padding-bottom: 24px; display: grid; grid-template-columns: 73px 1fr; gap: 13px 17px; border-bottom: 1px solid var(--line); font-size: .79rem; line-height: 1.9; }
.character-facts dt { color: var(--muted); font-size: .69rem; padding-top: 2px; }
.character-facts dd { margin: 0; word-break: keep-all; overflow-wrap: anywhere; }
.character-story h4 { font-size: .84rem; font-weight: 600; margin: 27px 0 18px; }
.character-story h4 span { font: .64rem var(--mono); color: var(--character-accent); margin-right: 10px; }
.character-story p { font-size: .83rem; line-height: 2; word-break: keep-all; overflow-wrap: anywhere; margin: 0 0 17px; color: #dce0e2; }
.character-wish { padding-top: 21px; border-top: 1px solid var(--line); margin-top: 27px; }
.character-wish h4 { font-size: .7rem; color: var(--muted); font-weight: 400; margin: 0 0 12px; }
.character-wish p { font-size: .88rem; line-height: 1.9; word-break: keep-all; overflow-wrap: anywhere; }
.character-paging { display: flex; justify-content: space-between; align-items: center; border-top: 1px solid var(--line); gap: 15px; padding: 13px 25px; flex-shrink: 0; }
.character-paging button { min-height: 40px; padding: 6px 0; background: none; color: inherit; display: flex; align-items: center; gap: 14px; font-size: 1.2rem; }
.character-profile button:hover { color: var(--character-accent); }
.character-profile :focus-visible { outline-color: var(--character-accent); }
.character-paging button span { font-size: .7rem; }
#character-page-count { font: .62rem var(--mono); color: var(--muted); white-space: nowrap; }
.character-dialog.is-closing .character-spread { opacity: 0; transform: translateY(12px); transition: opacity .22s, transform .22s; }
.character-card.is-turning .character-card-caption strong { color: var(--gold); }
@media (max-width: 1100px) {
 .characters-heading { align-items: flex-start; flex-direction: column; gap: 24px; }
 .character-grid { gap: 26px 18px; }
 .character-card-caption { align-items: flex-start; gap: 7px; }
 .character-card-weapon { display: none; }
 .characters-hover-hint { display: none; }
 .character-dialog { width: calc(100vw - 54px); }
 .character-spread { gap: 25px; grid-template-columns: .85fr 1.15fr; }
 .character-figure { height: auto; width: 100%; max-height: 74dvh; }
 .character-profile-scroll { padding: 27px 24px; }
 .character-profile-top { padding-inline: 20px; }
 .character-facts { grid-template-columns: 58px 1fr; gap: 11px; }
 .character-visual-label { font-size: .48rem; }
}
@media (max-width: 760px) {
 .characters-section { padding: 42px var(--gutter) 45px; }
 .characters-heading { margin: 34px 0 29px; }
 .characters-heading .display-title { font-size: 11vw; }
 .characters-heading-ko { font-size: .76rem; margin-bottom: 12px; }
 .characters-heading > p { font-size: .77rem; line-height: 1.9; }
 .characters-heading > p br { display: none; }
 .characters-toolbar { padding: 14px 0; }
 .character-filters { gap: 3px; }
 .character-filters button { padding: 8px 12px; font-size: .72rem; }
 .characters-instructions { font-size: .7rem; margin-bottom: 20px; }
 .character-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 25px 15px; }
 .character-card-caption strong { font-size: .96rem; }
 .character-card-caption small { font-size: .66rem; }
 .character-card-caption { padding-top: 12px; }
 .character-card-number { font-size: .48rem; top: 7px; left: 7px; padding: 4px; }
 .character-card-open { width: 24px; height: 24px; top: 7px; right: 7px; font-size: .8rem; opacity: 1; }
 .characters-bottom { margin-top: 28px; font-size: .67rem; }
 .characters-bottom > span { display: none; }
 .character-dialog { width: calc(100vw - 24px); max-width: calc(100vw - 24px); max-height: calc(100dvh - 24px); overflow-y: auto; overscroll-behavior: contain; scrollbar-width: none; }
 .character-spread { display: flex; flex-direction: column; gap: 19px; }
 .character-visual { width: 100%; padding-top: 10px; flex: none; }
 .character-visual-label { width: min(100%, 360px); padding: 0 7px; font-size: .49rem; margin-bottom: 10px; }
 .character-visual-label > :last-child { display: none; }
 .character-figure { height: min(60dvh, 560px); width: auto; max-height: none; max-width: 90%; }
 .character-art-status { margin-top: 10px; min-height: 0; font-size: .6rem; }
 .character-profile { width: 100%; height: auto; min-height: 0; flex: none; }
 .character-profile-top { padding: 12px 20px; }
 .character-profile-top > span { font-size: .5rem; }
 .character-profile-scroll { overflow: visible; padding: 27px 23px 23px; flex: none; }
 #character-name { font-size: 2.5rem; }
 .character-class { font-size: .8rem; }
 .character-basic { font-size: .72rem; }
 .character-quote { font-size: 1rem; }
 .character-facts { font-size: .78rem; grid-template-columns: 59px 1fr; gap: 12px 13px; }
 .character-story p { font-size: .8rem; }
 .character-wish p { font-size: .84rem; }
 .character-paging { padding: 12px 20px; position: sticky; bottom: 0; background: #090e13f2; backdrop-filter: blur(16px); }
 .character-close { position: fixed; top: 9px; right: 9px; z-index: 5; border: 1px solid #fff6; color: white; background: #111d; border-radius: 30px; padding: 9px 13px; gap: 10px; box-shadow: 0 5px 18px #0003; }
 .character-profile-top { min-height: 46px; }
 .menu-body { padding-top: 28px; }
 .menu-body nav a { padding-top: 18px; padding-bottom: 35px; font-size: 8vw; }
}
@media (prefers-reduced-motion: reduce) {
 .character-figure.is-shining .character-face::after { animation: none !important; opacity: 0; }
 .character-card-art, .character-flipper { transition: none !important; }
 .character-card.is-turning .character-card-art { transform: none; }
 .character-dialog.is-closing .character-spread { transition: none; transform: none; }
}
.motion-paused .character-flipper, .motion-paused .character-card-art { transition: none; }
.motion-paused .character-figure.is-shining .character-face::after { animation: none !important; opacity: 0; }
html[data-text-scale="200"] .character-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
html[data-text-scale="200"] .character-card-caption { flex-wrap: wrap; }
html[data-text-scale="200"] .character-card-weapon, html[data-text-scale="200"] .characters-hover-hint { display: none; }
html[data-text-scale="200"] .characters-toolbar { flex-wrap: wrap; }
html[data-text-scale="200"] .character-dialog { overflow-y: auto; }
html[data-text-scale="200"] .character-spread { display: flex; flex-direction: column; }
html[data-text-scale="200"] .character-figure { height: min(55dvh, 600px); width: auto; }
html[data-text-scale="200"] .character-profile { height: auto; width: 100%; flex: none; }
html[data-text-scale="200"] .character-profile-scroll { overflow: visible; flex: none; }
html[data-text-scale="200"] .character-facts { grid-template-columns: 1fr; gap: 5px; }
html[data-text-scale="200"] .character-facts dd { margin-bottom: 14px; }
html[data-text-scale="200"] .character-visual-label { flex-wrap: wrap; }
html[data-text-scale="200"] .character-paging { flex-wrap: wrap; gap: 8px; }
html[data-text-scale="200"] .character-paging button span { font-size: .6rem; }
@media (max-width: 480px) { html[data-text-scale="200"] .character-grid { grid-template-columns: 1fr; } }

