:root {
    color-scheme: light;
    --paper: #fbfdff;
    --ink: #19364d;
    --muted: #42607a;
    --line: #c9dfec;
    --sky: #edf7fe;
    --sky-deep: #dbeefb;
    --accent: #bfe3f7;
    --accent-hover: #add9f2;
    --focus: #296b95;
    --lamp: #f4d6a0;
    --lamp-ink: #895d38;
    --brand-font: "Arial Rounded MT Bold", "Hiragino Maru Gothic ProN", "Trebuchet MS", ui-rounded, system-ui, sans-serif;
    font: 16px/1.7 "Hiragino Sans", "Yu Gothic UI", "Yu Gothic", Meiryo, system-ui, sans-serif;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body { margin: 0; color: var(--ink); background: var(--paper); }
img { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
button { font: inherit; }
:focus-visible { outline: 3px solid var(--focus); outline-offset: 4px; }
h1, h2, h3, p { margin: 0; }
h2, h3 { line-height: 1.4; }
h2 { font-size: clamp(1.65rem, 3.1vw, 2.55rem); font-weight: 900; letter-spacing: -.065em; }
section[id] { scroll-margin-top: 20px; }
.container { width: min(1120px, calc(100% - 80px)); margin-inline: auto; }

.skip-link {
    position: fixed;
    z-index: 5;
    inset: 10px auto auto 10px;
    padding: 8px 16px;
    color: var(--ink);
    background: var(--paper);
    transform: translateY(-150%);
}
.skip-link:focus { transform: none; }

.site-header { background: var(--paper); border-bottom: 1px solid #dceaf3; }
.header-row { min-height: 75px; display: flex; align-items: center; gap: 32px; }
.wordmark {
    display: inline-flex;
    align-items: center;
    gap: 9px;
    margin-right: auto;
    font: 900 1.75rem/1 var(--brand-font);
    letter-spacing: -.045em;
}
.wordmark img { object-fit: contain; }
.header-row nav, .footer-row nav { display: flex; align-items: center; gap: 25px; }
.header-row nav a { font-size: .9rem; font-weight: 750; }
.header-row nav a:hover, .footer-row nav a:hover, .text-link:hover { text-decoration: underline; text-underline-offset: 4px; }

.button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    min-height: 50px;
    padding: 10px 20px;
    border: 1px solid #a7cce2;
    border-radius: 13px;
    color: var(--ink);
    background: #f0f8fe;
    font-size: .91rem;
    font-weight: 800;
    white-space: nowrap;
    transition: transform .15s ease, background-color .15s ease, box-shadow .15s ease;
}
.button span { font-size: 1.14em; line-height: 1; }
.button:hover { background: #e4f2fc; }
.button:active { transform: translateY(1px); }
.button-small { min-height: 40px; padding: 7px 13px; font-size: .83rem; gap: 8px; }
.button-primary { background: var(--accent); box-shadow: 0 3px 0 #c2dcea; }
.button-primary:hover { background: var(--accent-hover); transform: translateY(-1px); box-shadow: 0 4px 0 #c2dcea; }
.button-primary:active { transform: translateY(2px); box-shadow: 0 1px 0 #c2dcea; }

.hero {
    padding-block: 30px 38px;
    background: linear-gradient(135deg, #e6f3fc, #edf5ff 58%, #f3f7fc);
}
.hero-grid {
    width: min(1240px, calc(100% - 48px));
    display: grid;
    grid-template-columns: minmax(0, .83fr) minmax(0, 1.17fr);
    align-items: center;
    padding: 12px;
    border: 1px solid #c7dfee;
    border-radius: 26px;
    background:
        radial-gradient(ellipse at 13% 86%, #fff3e68c, transparent 43%),
        linear-gradient(125deg, #eef8ff, #f8fcff 53%, #edf5fd);
    box-shadow: 0 16px 36px #467d9c14, 0 3px 0 #dceaf4;
}
.hero-copy {
    position: relative;
    isolation: isolate;
    padding: 35px clamp(24px, 4.2vw, 63px);
}
.hero-copy::before {
    position: absolute;
    z-index: -1;
    inset: 12px 13px 10px 8px;
    content: "";
    background-image: linear-gradient(#91b7d52b 1px, transparent 1px), linear-gradient(90deg, #91b7d52b 1px, transparent 1px);
    background-size: 16px 16px;
    mask-image: linear-gradient(to right, #000, transparent 84%);
    pointer-events: none;
}
.kicker { display: flex; align-items: center; gap: 9px; color: var(--muted); font-size: .83rem; font-weight: 750; }
.pixel-heart {
    width: 13px;
    height: 12px;
    flex: 0 0 13px;
    background: #e897aa;
}
.pixel-heart, .step-heart::before {
    clip-path: polygon(0 15%, 14% 15%, 14% 0, 43% 0, 43% 15%, 57% 15%, 57% 0, 86% 0, 86% 15%, 100% 15%, 100% 54%, 86% 54%, 86% 69%, 71% 69%, 71% 85%, 57% 85%, 57% 100%, 43% 100%, 43% 85%, 29% 85%, 29% 69%, 14% 69%, 14% 54%, 0 54%);
}
.hero h1 {
    margin-block: 17px 22px;
    font-size: clamp(2.8rem, 5.4vw, 4.25rem);
    font-weight: 900;
    line-height: 1.08;
    letter-spacing: -.11em;
    white-space: nowrap;
}
.hero-accent {
    display: inline-block;
    position: relative;
    isolation: isolate;
}
.hero-accent::before {
    position: absolute;
    inset: 69% .02em 2% -.04em;
    z-index: -1;
    border-radius: 6px;
    background: #c5e5f9;
    content: "";
}
.hero-description { color: var(--muted); font-size: clamp(.87rem, 1.33vw, 1rem); font-weight: 600; line-height: 1.85; }
.hero-lead { display: block; color: var(--ink); font-size: 1.12em; font-weight: 800; }
.hero-actions { display: flex; align-items: center; flex-wrap: wrap; gap: 12px 17px; margin-top: 25px; }
.text-link { display: inline-flex; align-items: center; min-height: 44px; gap: 8px; color: var(--ink); font-size: .84rem; font-weight: 750; }
.text-link span { color: var(--focus); }
.hero-art {
    padding: 5px;
    border: 1px solid #c6ddea;
    border-radius: 17px;
    background: #fcfeff;
    box-shadow: 0 6px 17px #3f678c1c;
}
.hero-art img {
    width: 100%;
    height: auto;
    aspect-ratio: 4 / 3;
    object-fit: contain;
    border-radius: 11px;
    image-rendering: pixelated;
}
.section { padding-block: 72px 80px; }
.steps {
    counter-reset: step;
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 16px;
    margin: 25px 0 0;
    padding: 0;
    list-style: none;
}
.step-card {
    counter-increment: step;
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    grid-template-rows: 38px auto;
    align-content: start;
    align-items: center;
    gap: 17px 12px;
    padding: 20px 21px 23px;
    border: 1px solid var(--line);
    border-radius: 17px;
    background: linear-gradient(145deg, #fff, #f5faff);
    box-shadow: 0 2px 0 #edf5fa;
}
.step-card::before {
    grid-area: 1 / 1;
    content: counter(step, decimal-leading-zero) / "";
    color: #3e6c90;
    font: 800 1.15rem/1 var(--brand-font);
    letter-spacing: .08em;
}
.step-card > div { grid-column: 1 / -1; min-width: 0; }
.step-icon {
    grid-area: 1 / 2;
    display: grid;
    place-items: center;
    width: 38px;
    height: 38px;
    border: 1px solid #c6e0f1;
    border-radius: 10px;
    background: #e6f3fc;
    color: #386b91;
}
.step-icon::before { content: ""; width: 19px; height: 17px; background: currentColor; }
.step-camera::before {
    clip-path: polygon(0 22%, 25% 22%, 25% 8%, 66% 8%, 66% 22%, 100% 22%, 100% 92%, 0 92%, 0 22%, 33% 22%, 33% 42%, 24% 42%, 24% 70%, 33% 70%, 33% 79%, 65% 79%, 65% 70%, 74% 70%, 74% 42%, 65% 42%, 65% 33%, 33% 33%, 33% 22%);
}
.step-heart { background: #fcf0e5; border-color: #ebd7bf; color: var(--lamp-ink); }
.step-voice { background: #eeeefa; border-color: #d8def0; color: #535f8b; }
.step-voice::before {
    background:
        linear-gradient(currentColor, currentColor) 0 50% / 2px 5px no-repeat,
        linear-gradient(currentColor, currentColor) 4px 50% / 2px 11px no-repeat,
        linear-gradient(currentColor, currentColor) 8px 50% / 2px 17px no-repeat,
        linear-gradient(currentColor, currentColor) 12px 50% / 2px 11px no-repeat,
        linear-gradient(currentColor, currentColor) 16px 50% / 2px 5px no-repeat;
}
.step-role { color: #426887; font-size: .76rem; font-weight: 800; }
.step-card h3 { margin-block: 4px 8px; font-size: clamp(1rem, 1.55vw, 1.19rem); letter-spacing: -.05em; }
.step-card p:last-child { color: var(--muted); font-size: .9rem; line-height: 1.8; }

.voice-section {
    padding-block: 67px;
    border-block: 1px solid #d9e8f4;
    background:
        radial-gradient(ellipse at 17% 100%, #fff1e166, transparent 46%),
        linear-gradient(125deg, #eaf6ff, #edf2ff);
}
.voice-grid { display: grid; grid-template-columns: minmax(0, .92fr) minmax(0, 1.08fr); align-items: center; gap: 60px; }
.voice-copy h2::before { display: block; width: 32px; height: 4px; margin-bottom: 15px; border-radius: 2px; content: ""; background: var(--lamp); }
.voice-copy p { margin-top: 14px; color: var(--muted); line-height: 1.85; font-weight: 600; }
.voice-demo {
    padding: 21px 25px 15px;
    border: 1px solid var(--line);
    border-radius: 19px;
    background-color: #fbfdff;
    background-image: linear-gradient(#a4c4df24 1px, transparent 1px), linear-gradient(90deg, #a4c4df24 1px, transparent 1px);
    background-size: 24px 24px;
    box-shadow: 0 6px 20px #507da617, inset 0 0 0 4px #f1f8fd;
}
.demo-title { display: flex; align-items: center; gap: 9px; color: var(--ink); font-size: .9rem; font-weight: 800; }
.demo-title::before { width: 6px; height: 6px; content: ""; background: var(--lamp); }
.voice-row { display: flex; align-items: end; gap: 10px; margin-top: 13px; }
.voice-row-right { flex-direction: row-reverse; }
.cat-avatar {
    flex: 0 0 52px;
    width: 52px;
    height: 52px;
    object-fit: none;
    border: 1px solid #b6d4e8;
    border-radius: 50%;
    background: var(--sky-deep);
    image-rendering: pixelated;
}
.avatar-ragdoll { object-position: 23% 62%; }
.avatar-tabby { object-position: 74% 62%; border-color: #e8cfb3; }
.voice-entry { width: min(100% - 62px, 258px); }
.voice-entry p { padding-inline: 6px; color: var(--muted); font-size: .76rem; font-weight: 700; }
.voice-row-right .voice-entry p { text-align: right; }
.voice-button {
    position: relative;
    display: flex;
    width: 100%;
    min-height: 46px;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
    padding: 6px 11px;
    overflow: hidden;
    isolation: isolate;
    border: 1px solid #c1dced;
    border-radius: 12px;
    background: #e5f3fe;
    color: var(--ink);
    cursor: pointer;
}
.voice-row-right .voice-button { background: #efeffb; border-color: #d7def2; }
.voice-button::before { position: absolute; z-index: -1; inset: 0 auto 0 0; width: var(--progress, 0%); content: ""; background: #bfdef5; }
.voice-row-right .voice-button::before { background: #d5dbf4; }
.voice-button:hover, .voice-row-right .voice-button:hover { border-color: #88b1ce; }
.play-icon { width: 12px; height: 13px; flex: 0 0 12px; background: var(--focus); clip-path: polygon(0 0, 100% 50%, 0 100%); }
.voice-button.is-playing .play-icon { clip-path: polygon(0 0, 36% 0, 36% 100%, 0 100%, 0 0, 64% 0, 100% 0, 100% 100%, 64% 100%, 64% 0); }
.wave { display: flex; flex: 1 1 auto; justify-content: center; align-items: center; gap: 3px; height: 24px; overflow: hidden; }
.wave i { width: 3px; height: 8px; flex: 0 1 3px; border-radius: 2px; background: #4f7d9c; }
.wave i:nth-child(3n+1) { height: 15px; }
.wave i:nth-child(5n+3) { height: 23px; }
.wave i:nth-child(7n+2) { height: 19px; }
.wave i:nth-child(7n) { height: 5px; }
.voice-length { flex: 0 0 auto; font-size: .72rem; font-variant-numeric: tabular-nums; }
.audio-status:not(:empty) { margin-top: 10px; color: var(--muted); font-size: .8rem; }
.audio-credits { margin-top: 13px; color: var(--muted); font-size: .74rem; overflow-wrap: anywhere; }
.audio-credits summary { width: fit-content; cursor: pointer; }
.audio-credits ul { margin: 6px 0; padding-left: 19px; }
.audio-credits a { text-decoration: underline; text-underline-offset: 2px; }

.closing { padding-block: 63px 67px; text-align: center; }
.closing h2 { font-size: clamp(1.5rem, 3vw, 2.25rem); }
.closing .button { margin-top: 17px; }
.site-footer { padding-block: 20px; border-top: 1px solid #d9e8f2; background: var(--sky); }
.footer-row { display: flex; align-items: center; justify-content: space-between; gap: 12px 24px; }
.footer-brand { display: flex; align-items: center; gap: 8px; color: var(--muted); font-size: .84rem; font-weight: 800; }
.footer-row nav { gap: 17px; color: var(--muted); font-size: .77rem; }

@media (max-width: 1060px) {
    .container { width: min(1120px, calc(100% - 58px)); }
    .hero-grid { width: calc(100% - 40px); }
    .hero-copy { padding-inline: clamp(22px, 3vw, 40px); }
    .voice-grid { gap: 38px; }
}

@media (max-width: 860px) {
    .hero-grid { grid-template-columns: minmax(0, 1fr); width: min(620px, calc(100% - 42px)); }
    .hero-copy { padding: 27px 28px 26px; }
    .hero h1 { font-size: clamp(3.05rem, 9vw, 4.75rem); margin-block: 12px 16px; }
    .hero-description { font-size: .96rem; }
    .hero-actions { margin-top: 17px; }
    .step-card { padding-inline: 19px; }
    .voice-grid { grid-template-columns: minmax(0, .82fr) minmax(0, 1.18fr); gap: 26px; }
}

@media (max-width: 650px) {
    .container { width: calc(100% - 38px); }
    .header-row {
        display: grid;
        grid-template-columns: minmax(0, 1fr) auto;
        min-height: auto;
        gap: 0 10px;
        padding-block: 8px 1px;
    }
    .wordmark { font-size: 1.5rem; gap: 7px; }
    .wordmark img { width: 34px; height: 34px; }
    .header-row .button-small { grid-area: 1 / 2; min-height: 36px; padding-inline: 9px; font-size: .75rem; }
    .header-row nav { grid-area: 2 / 1 / 3 / -1; justify-content: center; gap: 24px; margin-top: 5px; }
    .header-row nav a { display: inline-flex; align-items: center; min-height: 35px; font-size: .77rem; }
    .hero { padding-block: 12px 19px; }
    .hero-grid { width: min(580px, calc(100% - 24px)); padding: 8px; border-radius: 21px; }
    .hero-copy { padding: 23px 13px 21px; }
    .hero h1 { margin-block: 11px 13px; font-size: clamp(2.58rem, 12vw, 4.2rem); }
    .hero-description { font-size: .87rem; }
    .hero-actions { gap: 8px 13px; margin-top: 14px; }
    .hero-actions .button { min-height: 44px; padding-inline: 10px; gap: 6px; font-size: .82rem; }
    .hero-actions .text-link { min-height: 42px; gap: 4px; font-size: .76rem; }
    .hero-art { padding: 3px; border-radius: 13px; }
    .hero-art img { border-radius: 9px; }
    .section { padding-block: 46px 49px; }
    .steps { grid-template-columns: minmax(0, 1fr); gap: 10px; margin-top: 19px; }
    .step-card {
        grid-template-columns: 26px minmax(0, 1fr) 34px;
        grid-template-rows: auto;
        align-items: start;
        gap: 10px;
        padding: 14px;
    }
    .step-card::before { padding-top: 4px; font-size: .9rem; }
    .step-card > div { grid-area: 1 / 2; }
    .step-icon { grid-area: 1 / 3; width: 34px; height: 34px; }
    .step-card h3 { margin-block: 3px 5px; }
    .step-card p:last-child { font-size: .84rem; }
    .voice-section { padding-block: 43px 46px; }
    .voice-grid { grid-template-columns: minmax(0, 1fr); gap: 21px; }
    .voice-copy h2 br, .wide-only { display: none; }
    .voice-copy p { margin-top: 9px; font-size: .88rem; }
    .voice-demo { padding: 15px 13px 13px; }
    .closing .button { min-height: 44px; padding-inline: 13px; font-size: .84rem; }
    .footer-row { flex-direction: column; align-items: flex-start; }
}

@media (prefers-reduced-motion: reduce) {
    html { scroll-behavior: auto; }
    .button { transition: none; }
}
