/* SophicaQuest 紹介ページ（ゲームと同じ夜空の配色） */

:root {
    --sq-bg: #070f24;
    --sq-bg-2: #0b1733;
    --sq-card: #101f44;
    --sq-card-2: #142752;
    --sq-line: rgba(160, 185, 255, 0.18);
    --sq-text: #eef2ff;
    --sq-muted: #b6c2e3;
    --sq-gold: #f6c453;
    --sq-gold-2: #ffdf8a;
    --sq-mint: #6fe3c6;
    --sq-sky: #8fd0ff;
    --sq-radius: 20px;
}

body.sq {
    background: var(--sq-bg);
    color: var(--sq-text);
    -webkit-font-smoothing: antialiased;
}

.sq .container {
    max-width: 1120px;
    padding: 0 24px;
}

.sq a {
    color: var(--sq-sky);
}

/* styles.css の section h2（濃い灰色・下余白）を打ち消す */
.sq h1,
.sq h2,
.sq h3 {
    color: var(--sq-text);
    padding-bottom: 0;
}

/* ヒーロー */
.sq-hero {
    position: relative;
    background:
        linear-gradient(180deg, rgba(7, 15, 36, 0.55) 0%, rgba(7, 15, 36, 0.35) 45%, rgba(7, 15, 36, 0.92) 92%, var(--sq-bg) 100%),
        url("assets/sophicaquest/sky.webp") center 70% / cover no-repeat,
        var(--sq-bg);
    padding: 1.5rem 0 4.5rem;
    overflow: hidden;
}

.sq-back {
    display: inline-block;
    color: rgba(238, 242, 255, 0.7) !important;
    text-decoration: none;
    font-size: 0.875rem;
    margin-bottom: 2rem;
}

.sq-back:hover {
    color: var(--sq-text) !important;
}

.sq-hero-grid {
    display: grid;
    grid-template-columns: 1.05fr 0.95fr;
    gap: 3rem;
    align-items: center;
}

.sq-brand {
    display: flex;
    align-items: center;
    gap: 0.875rem;
    margin-bottom: 1.5rem;
}

.sq-brand img {
    width: 56px;
    height: 56px;
    border-radius: 13px;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.45);
}

.sq-brand-name {
    font-size: 1.25rem;
    font-weight: 800;
    letter-spacing: 0.01em;
    line-height: 1.2;
}

.sq-brand-kana {
    font-size: 0.8rem;
    color: var(--sq-muted);
    line-height: 1.4;
}

.sq-eyebrow {
    display: inline-block;
    font-size: 0.85rem;
    font-weight: 700;
    color: var(--sq-gold);
    border-left: 3px solid var(--sq-gold);
    padding-left: 0.6rem;
    margin-bottom: 0.9rem;
    line-height: 1.3;
}

.sq-line {
    display: inline-block;
}

.sq-hero h1 .sq-line {
    white-space: nowrap;
}

.sq-hero h1 {
    font-size: clamp(2rem, 4.4vw, 3.3rem);
    font-weight: 800;
    line-height: 1.25;
    letter-spacing: 0.01em;
    margin-bottom: 1.25rem;
    text-shadow: 0 2px 18px rgba(0, 0, 0, 0.5);
}

.sq-hero h1 .sq-accent {
    color: var(--sq-gold);
}

.sq-lead {
    font-size: 1.05rem;
    line-height: 1.95;
    color: rgba(238, 242, 255, 0.9);
    max-width: 34em;
    margin-bottom: 1.75rem;
    text-shadow: 0 1px 10px rgba(0, 0, 0, 0.5);
}

.sq-get {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.75rem 1.25rem;
}

.sq-badge {
    display: inline-block;
    line-height: 0;
}

.sq-badge img {
    width: 180px;
    height: auto;
}

.sq-chips {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    list-style: none;
    padding: 0;
}

.sq-chips li {
    font-size: 0.82rem;
    font-weight: 700;
    color: var(--sq-text);
    background: rgba(16, 31, 68, 0.75);
    border: 1px solid var(--sq-line);
    border-radius: 999px;
    padding: 0.3rem 0.8rem;
    line-height: 1.4;
}

.sq-search {
    margin-top: 1rem;
    font-size: 0.9rem;
    color: var(--sq-muted);
}

.sq-search strong {
    color: var(--sq-text);
    font-weight: 700;
}

.sq-hero-art img {
    display: block;
    width: 100%;
    max-width: 480px;
    height: auto;
    margin-left: auto;
    border-radius: 28px;
    box-shadow: 0 24px 60px rgba(0, 0, 0, 0.55), 0 0 0 1px rgba(255, 223, 138, 0.25), 0 0 80px rgba(246, 196, 83, 0.18);
}

/* セクション共通 */
.sq-section {
    padding: 4.5rem 0;
}

.sq-section.alt {
    background: var(--sq-bg-2);
}

.sq-section h2 {
    text-align: center;
    font-size: clamp(1.5rem, 3.4vw, 2rem);
    font-weight: 800;
    line-height: 1.4;
    margin-bottom: 0.75rem;
}

.sq-section-lead {
    text-align: center;
    color: var(--sq-muted);
    font-size: 1rem;
    margin-bottom: 2.75rem;
}

/* ゲームの画面 */
.sq-screens {
    list-style: none;
    padding: 0;
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 3rem 2rem;
    max-width: 960px;
    margin: 0 auto;
}

.sq-screens figure {
    margin: 0;
}

.sq-phone {
    border-radius: 26px;
    overflow: hidden;
    background: #000;
    border: 1px solid var(--sq-line);
    box-shadow: 0 18px 44px rgba(0, 0, 0, 0.5);
    max-width: 280px;
    margin: 0 auto;
}

.sq-phone img {
    display: block;
    width: 100%;
    height: auto;
}

.sq-screens figcaption {
    text-align: center;
    margin-top: 1.1rem;
}

.sq-screens figcaption strong {
    display: block;
    font-size: 1.05rem;
    font-weight: 800;
    line-height: 1.5;
    color: var(--sq-gold-2);
}

.sq-screens figcaption span {
    display: block;
    font-size: 0.875rem;
    color: var(--sq-muted);
    line-height: 1.7;
    margin-top: 0.2rem;
}

/* つくったわけ */
.sq-story {
    max-width: 760px;
    margin: 0 auto;
    background: linear-gradient(160deg, var(--sq-card-2), var(--sq-card));
    border: 1px solid var(--sq-line);
    border-radius: var(--sq-radius);
    padding: 2.5rem 2.75rem;
}

.sq-story h2 {
    margin-bottom: 1.5rem;
}

.sq-story p {
    font-size: 1rem;
    line-height: 2;
    color: rgba(238, 242, 255, 0.92);
    margin-bottom: 1rem;
}

.sq-story .sq-sign {
    text-align: right;
    color: var(--sq-muted);
    font-size: 0.9rem;
    margin: 1.5rem 0 0;
}

/* 単語帳 */
.sq-books {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1.5rem;
    max-width: 920px;
    margin: 0 auto;
}

.sq-book {
    background: var(--sq-card);
    border: 1px solid var(--sq-line);
    border-radius: var(--sq-radius);
    padding: 2rem;
}

.sq-book-tag {
    display: inline-block;
    font-size: 0.78rem;
    font-weight: 800;
    color: var(--sq-bg);
    background: var(--sq-mint);
    border-radius: 6px;
    padding: 0.1rem 0.55rem;
    margin-bottom: 0.75rem;
}

.sq-book.high .sq-book-tag {
    background: var(--sq-gold);
}

.sq-book h3 {
    font-size: 1.35rem;
    font-weight: 800;
    margin-bottom: 0.25rem;
}

.sq-book-level {
    color: var(--sq-muted);
    font-size: 0.92rem;
    margin-bottom: 1.25rem;
}

.sq-counts {
    display: flex;
    gap: 1rem;
    margin-bottom: 1.25rem;
}

.sq-count {
    flex: 1;
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid var(--sq-line);
    border-radius: 12px;
    padding: 0.75rem 0.5rem;
    text-align: center;
}

.sq-count b {
    display: block;
    font-size: 1.75rem;
    font-weight: 800;
    color: var(--sq-gold);
    line-height: 1.2;
}

.sq-count span {
    font-size: 0.8rem;
    color: var(--sq-muted);
}

.sq-examples dt {
    font-size: 0.8rem;
    color: var(--sq-muted);
    margin-top: 0.6rem;
}

.sq-examples dd {
    margin: 0.3rem 0 0;
    display: flex;
    flex-wrap: wrap;
    gap: 0.4rem;
}

.sq-word {
    font-family: Georgia, "Times New Roman", serif;
    font-size: 0.95rem;
    background: rgba(143, 208, 255, 0.1);
    border: 1px solid rgba(143, 208, 255, 0.25);
    border-radius: 8px;
    padding: 0.1rem 0.55rem;
    line-height: 1.6;
}

.sq-book-note {
    font-size: 0.85rem;
    color: var(--sq-muted);
    margin-top: 1rem;
}

.sq-tip {
    max-width: 920px;
    margin: 1.5rem auto 0;
    text-align: center;
    font-size: 0.92rem;
    color: var(--sq-muted);
}

/* 遊び方 */
.sq-steps {
    list-style: none;
    padding: 0;
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1.25rem;
    max-width: 980px;
    margin: 0 auto;
    counter-reset: sq-step;
}

.sq-steps li {
    background: var(--sq-card);
    border: 1px solid var(--sq-line);
    border-radius: var(--sq-radius);
    padding: 1.75rem 1.5rem;
    counter-increment: sq-step;
}

.sq-steps li::before {
    content: counter(sq-step);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 2rem;
    height: 2rem;
    border-radius: 50%;
    background: var(--sq-gold);
    color: var(--sq-bg);
    font-weight: 800;
    margin-bottom: 0.9rem;
}

.sq-steps h3,
.sq-features h3 {
    font-size: 1.1rem;
    font-weight: 800;
    line-height: 1.5;
    margin-bottom: 0.5rem;
}

.sq-steps p,
.sq-features p {
    font-size: 0.92rem;
    line-height: 1.85;
    color: var(--sq-muted);
}

/* 毎日少しずつ */
.sq-features {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1.25rem;
    max-width: 920px;
    margin: 0 auto;
}

.sq-features article {
    background: var(--sq-card);
    border: 1px solid var(--sq-line);
    border-left: 3px solid var(--sq-mint);
    border-radius: 14px;
    padding: 1.5rem 1.6rem;
}

/* 料金・サポート */
.sq-box {
    max-width: 640px;
    margin: 0 auto;
    background: var(--sq-card);
    border: 1px solid var(--sq-line);
    border-radius: var(--sq-radius);
    padding: 2rem 2.25rem;
    text-align: center;
}

.sq-price {
    font-size: 1.35rem;
    font-weight: 800;
    margin-bottom: 0.5rem;
}

.sq-note {
    font-size: 0.85rem;
    color: var(--sq-muted);
}

.sq-support {
    margin: 1.25rem auto 0;
    max-width: 420px;
    text-align: left;
}

.sq-support div {
    display: grid;
    grid-template-columns: 90px 1fr;
    gap: 1rem;
    padding: 0.75rem 0;
    border-bottom: 1px solid var(--sq-line);
}

.sq-support div:last-child {
    border-bottom: none;
}

.sq-support dt {
    color: var(--sq-muted);
    font-size: 0.9rem;
}

.sq-support dd {
    margin: 0;
    overflow-wrap: anywhere;
}

/* 最後の案内 */
.sq-final {
    text-align: center;
    padding: 5rem 0 3.5rem;
    background:
        linear-gradient(180deg, var(--sq-bg) 0%, rgba(7, 15, 36, 0.7) 40%, rgba(7, 15, 36, 0.85) 100%),
        url("assets/sophicaquest/sky.webp") center 80% / cover no-repeat,
        var(--sq-bg);
}

.sq-final h2 {
    font-size: clamp(1.6rem, 4vw, 2.3rem);
    font-weight: 800;
    margin-bottom: 0.75rem;
}

.sq-final h2 .sq-accent {
    color: var(--sq-gold);
}

.sq-final .sq-get {
    justify-content: center;
    margin-top: 1.75rem;
}

.sq-final .sq-search {
    margin-top: 1rem;
}

.sq-legal {
    margin-top: 2.5rem;
    font-size: 0.85rem;
    color: var(--sq-muted);
}

.sq-legal a {
    color: var(--sq-muted) !important;
    text-decoration: none;
}

.sq-legal a:hover {
    color: var(--sq-text) !important;
    text-decoration: underline;
}

.sq-legal span {
    margin: 0 0.75rem;
    opacity: 0.5;
}

body.sq footer {
    background: #040a1a;
    margin-top: 0;
    box-shadow: none;
    border-top: 1px solid var(--sq-line);
}

/* スマホ */
@media (max-width: 860px) {
    .sq-hero-grid {
        grid-template-columns: 1fr;
        gap: 2.25rem;
    }

    .sq-hero-art img {
        max-width: 420px;
        margin: 0 auto;
    }

    .sq-screens {
        display: flex;
        overflow-x: auto;
        scroll-snap-type: x mandatory;
        gap: 1.25rem;
        padding: 0 0 1rem;
        -webkit-overflow-scrolling: touch;
    }

    .sq-screens li {
        flex: 0 0 66%;
        max-width: 260px;
        scroll-snap-align: center;
    }

    .sq-books,
    .sq-features,
    .sq-steps {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 560px) {
    .sq .container {
        padding: 0 16px;
    }

    .sq-section {
        padding: 3.5rem 0;
    }

    .sq-story,
    .sq-book,
    .sq-box {
        padding: 1.75rem 1.25rem;
    }

    .sq-lead {
        font-size: 1rem;
    }

    .sq-story h2 {
        font-size: 1.3rem;
    }

    .sq-story h2 .sq-line {
        white-space: nowrap;
    }

    .sq-support div {
        grid-template-columns: 1fr;
        gap: 0.15rem;
    }
}
