/* Dedicated table fixes for guide articles.
   Loaded after guide-article.css and guide-enhanced.css. */
.enhanced-guide-page .enhanced-table-scroll {
    display: block;
    width: 100%;
    max-width: 100%;
    overflow-x: auto;
    box-sizing: border-box;
    -webkit-overflow-scrolling: touch;
    background: transparent !important;
    border: 0 !important;
    border-radius: 0 !important;
    scrollbar-gutter: auto !important;
}

.enhanced-guide-page .enhanced-table-scroll > table.conversion-table {
    display: table;
    width: 100% !important;
    max-width: none !important;
    margin: 0 !important;
    border: 1px solid var(--border-color) !important;
    border-radius: 8px;
    border-collapse: separate !important;
    border-spacing: 0 !important;
    table-layout: fixed !important;
}

.enhanced-guide-page .enhanced-table-scroll.cols-4 > table.conversion-table {
    min-width: 680px !important;
}

.enhanced-guide-page .enhanced-table-scroll.cols-3 > table.conversion-table {
    min-width: 560px !important;
}

.enhanced-guide-page .enhanced-table-scroll > table.conversion-table th,
.enhanced-guide-page .enhanced-table-scroll > table.conversion-table td {
    width: auto !important;
    min-width: 0 !important;
    max-width: none !important;
    box-sizing: border-box;
    padding: 11px 13px !important;
    border: 0 !important;
    border-right: 1px solid var(--border-color) !important;
    border-bottom: 1px solid var(--border-color) !important;
    line-height: 1.55;
    vertical-align: middle;
    overflow-wrap: anywhere;
}

.enhanced-guide-page .enhanced-table-scroll > table.conversion-table th {
    color: var(--text-color) !important;
    background: var(--tool-bg) !important;
    font-weight: 700;
    white-space: normal;
}

.enhanced-guide-page .enhanced-table-scroll > table.conversion-table tr > :last-child {
    border-right: 0 !important;
}

.enhanced-guide-page .enhanced-table-scroll > table.conversion-table tbody tr:last-child > * {
    border-bottom: 0 !important;
}

/* よく使う3つの進数 */
.enhanced-guide-page .table-base-types th:nth-child(1),
.enhanced-guide-page .table-base-types td:nth-child(1) { width: 18% !important; text-align: center; }
.enhanced-guide-page .table-base-types th:nth-child(2),
.enhanced-guide-page .table-base-types td:nth-child(2) { width: 24% !important; text-align: center; }
.enhanced-guide-page .table-base-types th:nth-child(3),
.enhanced-guide-page .table-base-types td:nth-child(3) { width: 25% !important; text-align: center; }
.enhanced-guide-page .table-base-types th:nth-child(4),
.enhanced-guide-page .table-base-types td:nth-child(4) { width: 33% !important; text-align: left; }

/* 進数（基数）とは何か */
.enhanced-guide-page .table-base-system th:nth-child(1),
.enhanced-guide-page .table-base-system td:nth-child(1) { width: 18% !important; text-align: center; }
.enhanced-guide-page .table-base-system th:nth-child(2),
.enhanced-guide-page .table-base-system td:nth-child(2) { width: 12% !important; text-align: center; }
.enhanced-guide-page .table-base-system th:nth-child(3),
.enhanced-guide-page .table-base-system td:nth-child(3) { width: 30% !important; text-align: center; }
.enhanced-guide-page .table-base-system th:nth-child(4),
.enhanced-guide-page .table-base-system td:nth-child(4) { width: 40% !important; text-align: left; }

/* 相互変換早見表 */
.enhanced-guide-page .table-binary-hex th,
.enhanced-guide-page .table-binary-hex td { text-align: center !important; }
.enhanced-guide-page .table-binary-hex th:nth-child(1),
.enhanced-guide-page .table-binary-hex td:nth-child(1) { width: 25% !important; }
.enhanced-guide-page .table-binary-hex th:nth-child(2),
.enhanced-guide-page .table-binary-hex td:nth-child(2) { width: 45% !important; }
.enhanced-guide-page .table-binary-hex th:nth-child(3),
.enhanced-guide-page .table-binary-hex td:nth-child(3) { width: 30% !important; }

/* 試験で使われる進数の種類 */
.enhanced-guide-page .table-fe-types th:nth-child(1),
.enhanced-guide-page .table-fe-types td:nth-child(1) { width: 18% !important; text-align: center; }
.enhanced-guide-page .table-fe-types th:nth-child(2),
.enhanced-guide-page .table-fe-types td:nth-child(2) { width: 20% !important; text-align: center; }
.enhanced-guide-page .table-fe-types th:nth-child(3),
.enhanced-guide-page .table-fe-types td:nth-child(3) { width: 62% !important; text-align: left; }

@media (max-width: 600px) {
    .enhanced-guide-page .enhanced-table-scroll > table.conversion-table th,
    .enhanced-guide-page .enhanced-table-scroll > table.conversion-table td {
        padding: 9px 10px !important;
        font-size: 13px;
    }
}
