
@charset "UTF-8";

:root {
    --primary: #2563eb;
    --text: #1e293b;
    --muted: #64748b;
    --border: #e8edf4;
    --background: #f5f7fb;
}

* {
    box-sizing: border-box;
}

body {
    margin: 0;
    background: var(--background);
    color: var(--text);
    font-family:
        -apple-system,
        BlinkMacSystemFont,
        "Segoe UI",
        "Noto Sans JP",
        "Yu Gothic",
        Meiryo,
        sans-serif;
    line-height: 1.7;
    -webkit-text-size-adjust: 100%;
}

a {
    color: inherit;
    text-decoration: none;
}

a:focus-visible {
    outline: 3px solid #93b4fd;
    outline-offset: 4px;
}

.page {
    width: 100%;
    max-width: 1000px;
    margin: 0 auto;
    padding: 0 28px 24px;
}

/* ヘッダー */
.header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 18px 24px;
    margin: 0 -28px;
    background: #fff;
    border-bottom: 1px solid var(--border);
}

.site-title {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    color: var(--text);
    font-size: 22px;
    font-weight: 800;
    letter-spacing: 0.03em;
}

.site-title:hover {
    color: var(--primary);
}

.logo-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 38px;
    height: 38px;
    flex-shrink: 0;
    background: #eff6ff;
    border-radius: 11px;
    color: var(--primary);
}

.logo-icon svg {
    width: 23px;
    height: 23px;
    fill: none;
    stroke: currentColor;
    stroke-width: 1.8;
    stroke-linecap: round;
    stroke-linejoin: round;
}

.header-subtitle {
    color: var(--muted);
    font-size: 12px;
}

/* 紹介エリア */
.intro {
    padding: 42px 0 30px;
}

.intro-label {
    margin: 0 0 8px;
    color: var(--primary);
    font-size: 11px;
    font-weight: 800;
    letter-spacing: 0.16em;
}

.intro h1 {
    margin: 0;
    font-size: clamp(25px, 4vw, 34px);
    font-weight: 800;
    line-height: 1.5;
    letter-spacing: 0.02em;
}

.intro > p:last-child {
    margin: 12px 0 0;
    color: var(--muted);
    font-size: 14px;
    line-height: 2;
}

/* 一覧見出し */
.content {
    margin: 0 0 28px;
}

.section-heading {
    margin-bottom: 16px;
}

.section-heading h2 {
    margin: 0;
    font-size: 21px;
    font-weight: 750;
}

.section-heading p {
    margin: 3px 0 0;
    color: var(--muted);
    font-size: 13px;
}

/* メニューカード */
.menu {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 14px;
}

.menu-item {
    position: relative;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    min-width: 0;
    min-height: 174px;
    padding: 20px;
    overflow: hidden;
    background: #fff;
    border: 1px solid var(--border);
    border-radius: 16px;
    box-shadow: 0 3px 10px rgb(15 23 42 / 3%);
    transition:
        transform 0.2s ease,
        box-shadow 0.2s ease,
        border-color 0.2s ease;
}

.menu-item:hover {
    transform: translateY(-3px);
    box-shadow: 0 10px 24px rgb(15 23 42 / 8%);
    text-decoration: none;
}

/* アイコン共通 */
.menu-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 52px;
    height: 52px;
    margin-bottom: 15px;
    border-radius: 15px;
}

.menu-icon svg {
    width: 29px;
    height: 29px;
    fill: none;
    stroke: currentColor;
    stroke-width: 2;
    stroke-linecap: round;
    stroke-linejoin: round;
}

.menu-name {
    font-size: 17px;
    font-weight: 750;
    line-height: 1.5;
}

.menu-description {
    margin-top: 3px;
    font-size: 12px;
    color: var(--muted);
}

.menu-arrow {
    position: absolute;
    right: 17px;
    bottom: 14px;
    font-size: 19px;
    color: #94a3b8;
    transition: transform 0.2s ease;
}

.menu-item:hover .menu-arrow {
    transform: translate(3px, -3px);
}

/* カードごとのカラー */
.menu-item.blue .menu-icon {
    background: #eff6ff;
    color: #2563eb;
}
.menu-item.blue:hover {
    border-color: #bfdbfe;
}

.menu-item.green .menu-icon {
    background: #ecfdf5;
    color: #059669;
}
.menu-item.green:hover {
    border-color: #a7f3d0;
}

.menu-item.orange .menu-icon {
    background: #fff7ed;
    color: #ea580c;
}
.menu-item.orange:hover {
    border-color: #fed7aa;
}

.menu-item.purple .menu-icon {
    background: #f5f3ff;
    color: #7c3aed;
}
.menu-item.purple:hover {
    border-color: #ddd6fe;
}

.menu-item.red .menu-icon {
    background: #fef2f2;
    color: #dc2626;
}
.menu-item.red:hover {
    border-color: #fecaca;
}

/* 計算用紙の案内 */
.print-link {
    display: flex;
    align-items: center;
    gap: 16px;
    margin: 30px 0;
    padding: 20px;
    background: #fff;
    border: 1px solid var(--border);
    border-radius: 15px;
    transition:
        border-color 0.2s ease,
        box-shadow 0.2s ease;
}

.print-link:hover {
    border-color: #c7d2fe;
    box-shadow: 0 5px 16px rgb(15 23 42 / 5%);
    text-decoration: none;
}

.print-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 48px;
    height: 48px;
    flex-shrink: 0;
    color: #475569;
    background: #f1f5f9;
    border-radius: 13px;
}

.print-icon svg {
    width: 25px;
    height: 25px;
    fill: none;
    stroke: currentColor;
    stroke-width: 1.8;
    stroke-linecap: round;
    stroke-linejoin: round;
}

.print-content {
    display: flex;
    flex: 1;
    flex-direction: column;
    min-width: 0;
}

.print-title {
    font-size: 15px;
    font-weight: 750;
}

.print-description {
    margin-top: 3px;
    color: var(--muted);
    font-size: 12px;
}

.print-arrow {
    flex-shrink: 0;
    color: var(--primary);
    font-size: 22px;
}

/* 広告 */
.ad-area {
    min-width: 0;
    margin: 28px 0;
}

/* フッター */
.footer {
    margin-top: 35px;
    padding: 22px 0;
    border-top: 1px solid var(--border);
    text-align: center;
}

.footer > a {
    color: #475569;
    font-size: 13px;
    font-weight: 700;
}

.footer > a:hover {
    color: var(--primary);
}

.footer p {
    margin: 4px 0 0;
    color: var(--muted);
    font-size: 11px;
}

/* スマートフォン */
@media screen and (max-width: 640px) {
    .page {
        padding: 0 16px 20px;
    }

    .header {
        margin: 0 -16px;
        padding: 14px 16px;
    }

    .site-title {
        gap: 8px;
        font-size: 19px;
    }

    .logo-icon {
        width: 34px;
        height: 34px;
        border-radius: 10px;
    }

    .header-subtitle {
        max-width: 125px;
        font-size: 10px;
        text-align: right;
    }

    .intro {
        padding: 32px 0 27px;
    }

    .intro h1 {
        font-size: 25px;
    }

    .intro > p:last-child {
        font-size: 13px;
    }

    .section-heading h2 {
        font-size: 19px;
    }

    .menu {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 10px;
    }

    .menu-item {
        min-height: 155px;
        padding: 15px;
        border-radius: 14px;
    }

    .menu-icon {
        width: 46px;
        height: 46px;
        margin-bottom: 12px;
        border-radius: 13px;
    }

    .menu-icon svg {
        width: 26px;
        height: 26px;
    }

    .menu-name {
        font-size: 15px;
    }

    .menu-description {
        font-size: 11px;
    }

    .menu-arrow {
        right: 12px;
        bottom: 9px;
        font-size: 17px;
    }

    .print-link {
        gap: 11px;
        padding: 15px 12px;
    }

    .print-icon {
        width: 42px;
        height: 42px;
    }

    .print-title {
        font-size: 14px;
    }

    .print-description {
        font-size: 11px;
    }
}

/* 小型スマートフォン */
@media screen and (max-width: 360px) {
    .header-subtitle {
        max-width: 105px;
        font-size: 9px;
    }

    .intro h1 {
        font-size: 22px;
    }

    .menu {
        gap: 8px;
    }

    .menu-item {
        min-height: 148px;
        padding: 12px;
    }

    .menu-name {
        font-size: 14px;
    }

    .print-description {
        line-height: 1.6;
    }
}

/* アニメーションを控える設定 */
@media (prefers-reduced-motion: reduce) {
    .menu-item,
    .menu-arrow,
    .print-link {
        transition: none;
    }
}




/* 答えを見るボタン */
.answer-area {
    display: flex;
    justify-content: center;
    margin: 24px 0 32px;
}

.answer-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 20px;
    min-width: 200px;
    padding: 13px 22px;
    background: #2563eb;
    border: 1px solid #2563eb;
    border-radius: 10px;
    color: #fff;
    font-size: 15px;
    font-weight: 700;
    transition:
        background 0.2s ease,
        box-shadow 0.2s ease,
        transform 0.2s ease;
}

.answer-button:link,
.answer-button:visited,
.answer-button:hover,
.answer-button:active {
    color: #fff;
    text-decoration: none;
}

.answer-button:hover {
    background: #1d4ed8;
    box-shadow: 0 5px 14px rgb(37 99 235 / 20%);
    transform: translateY(-1px);
}

.answer-button span {
    font-size: 19px;
}

/* スマートフォン */
@media screen and (max-width: 640px) {
    .answer-area {
        margin: 20px 0 28px;
    }

    .answer-button {
        width: 100%;
        max-width: 320px;
        min-height: 48px;
    }
}

@media print {
    .no-print {
        display: none !important;
    }
    .content {
    margin: 28px 0;
    }
}


/* 問題表示領域 */
.play{
width: 90%;
background-color: #eee; 
border: 1px solid #999;
padding: 10px; 
border-radius: 10px;
margin:0 auto;
}




/* ナンプレ用 */
table.sud{
text-align: center;
margin: 0 auto 0;
border-collapse: collapse;
border:4px solid #000;
}
table.sud td{
width: 9vmin;
height: 9vmin;
background-color: #ffffff;
border:1px solid #000;
}
table.sud tr:nth-child(3n){
border-bottom:4px solid #000;
}
table.sud td:nth-child(3n){
border-right:4px solid #000;
}



/* 100マス用 */
table.c100{
text-align: center;
margin: 0 auto 0;
border-collapse: collapse;
border:4px solid #000;
}
table.c100 td{
width: 7.8vmin;
height: 7.8vmin;
background-color: #ffffff;
border:1px solid #000;
}
table.c100 tr:nth-child(1){
border-bottom:4px solid #000;
}
table.c100 td:nth-child(1){
border-right:4px solid #000;
}




