/* =========================================
   AIボディコンパス ドキュメント用スタイル
   ベースのCSS変数は style.css から継承
   ========================================= */

/* ドキュメント共通レイアウト */
.docs-container {
    max-width: 820px;
    margin: 0 auto;
    margin-top: 78px;
    padding: 2rem 1.5rem 4rem;
}

/* パンくずリスト */
.docs-breadcrumb {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.85rem;
    color: var(--text-gray);
    margin-bottom: 2rem;
    flex-wrap: wrap;
}

.docs-breadcrumb a {
    color: var(--primary-color);
    text-decoration: none;
}

.docs-breadcrumb a:hover {
    text-decoration: underline;
}

.docs-breadcrumb .separator {
    color: var(--border-color);
}

/* 記事ヘッダー */
.docs-header {
    margin-bottom: 2.5rem;
    padding-bottom: 2rem;
    border-bottom: 1px solid var(--border-color);
}

.docs-header h1 {
    font-size: 1.75rem;
    font-weight: 700;
    color: var(--text-dark);
    line-height: 1.5;
    margin-bottom: 0.75rem;
}

.docs-meta {
    font-size: 0.85rem;
    color: var(--text-gray);
}

/* アイキャッチ画像 */
.docs-eyecatch {
    width: 100%;
    border-radius: 12px;
    margin-bottom: 2rem;
    overflow: hidden;
}

.docs-eyecatch img {
    width: 100%;
    height: auto;
    display: block;
}

/* 記事本文 */
.docs-body h2 {
    font-size: 1.35rem;
    font-weight: 700;
    color: var(--text-dark);
    margin: 2.5rem 0 1rem;
    padding: 0.75rem 1rem;
    border-left: 4px solid var(--primary-color);
    background: var(--bg-section);
    border-radius: 0 8px 8px 0;
    scroll-margin-top: calc(var(--header-height, 78px) + 1.5rem);
}

.docs-body h3 {
    font-size: 1.15rem;
    font-weight: 600;
    color: var(--text-dark);
    margin: 2rem 0 0.75rem;
    padding-bottom: 0.5rem;
    border-bottom: 2px solid var(--border-color);
}

.docs-body p {
    margin: 1rem 0;
    line-height: 1.9;
    color: var(--text-light);
}

.docs-body strong {
    color: var(--text-dark);
    font-weight: 600;
}

.docs-body a {
    color: var(--primary-color);
    text-decoration: none;
    border-bottom: 1px solid transparent;
    transition: border-color 0.2s;
}

.docs-body a:hover {
    border-bottom-color: var(--primary-color);
}

/* 記事内画像 */
.docs-body .docs-image {
    margin: 1.5rem 0;
    text-align: center;
}

.docs-body .docs-image img {
    max-width: 100%;
    height: auto;
    border-radius: 8px;
    box-shadow: var(--shadow);
    border: 1px solid var(--border-color);
}

/* 箇条書きリスト */
.docs-body ul,
.docs-body ol {
    margin: 1rem 0;
    padding-left: 1.5rem;
    color: var(--text-light);
}

.docs-body li {
    margin: 0.5rem 0;
    line-height: 1.8;
}

/* リンクカード */
.docs-link-card {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    margin: 1.5rem 0;
    padding: 1rem 1.25rem;
    background: var(--white);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    text-decoration: none;
    color: var(--text-dark);
    transition: box-shadow 0.2s, border-color 0.2s;
}

.docs-link-card:hover {
    box-shadow: var(--shadow);
    border-color: var(--primary-color);
}

.docs-link-card .link-card-icon {
    flex-shrink: 0;
    width: 40px;
    height: 40px;
    background: var(--gradient-primary);
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.docs-link-card .link-card-icon svg {
    width: 20px;
    height: 20px;
    fill: white;
}

.docs-link-card .link-card-text {
    font-size: 0.95rem;
    font-weight: 500;
    line-height: 1.5;
}

/* 手順ボックス */
.docs-steps {
    background: var(--bg-section);
    border-radius: 12px;
    padding: 1.25rem 1.5rem;
    margin: 1.5rem 0;
}

.docs-steps ol {
    padding-left: 1.25rem;
}

.docs-steps li {
    margin: 0.6rem 0;
}

.docs-steps .step-note {
    font-size: 0.85rem;
    color: var(--text-gray);
    margin-top: 0.25rem;
}

/* ========== カテゴリーセクション ========== */
.docs-category {
    margin-bottom: 2.5rem;
}

.docs-category-header {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    margin-bottom: 1.25rem;
}

.docs-category-icon {
    width: 36px;
    height: 36px;
    background: rgba(81, 181, 188, 0.1);
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.docs-category-icon svg {
    width: 20px;
    height: 20px;
    color: var(--primary-color);
}

.docs-category-title {
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--text-dark);
    margin: 0;
    letter-spacing: 0.02em;
}

/* ========== アイコンカード ========== */
.docs-card .card-icon {
    width: 48px;
    height: 48px;
    background: linear-gradient(135deg, rgba(81, 181, 188, 0.12), rgba(81, 181, 188, 0.04));
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    transition: background 0.2s;
}

.docs-card:hover .card-icon {
    background: linear-gradient(135deg, rgba(81, 181, 188, 0.2), rgba(81, 181, 188, 0.08));
}

.docs-card .card-icon svg {
    width: 24px;
    height: 24px;
    color: var(--primary-color);
}

.docs-card .card-content {
    display: flex;
    flex-direction: column;
    gap: 0.35rem;
}

/* ========== 目次ページ ========== */
.docs-index-hero {
    background: var(--gradient-primary);
    margin-top: 78px;
    padding: 3rem 1.5rem;
    text-align: center;
    color: white;
    margin-bottom: 2.5rem;
    border-radius: 0 0 24px 24px;
}

.docs-index-hero h1 {
    font-size: 1.75rem;
    font-weight: 700;
    margin-bottom: 0.5rem;
}

.docs-index-hero p {
    font-size: 1rem;
    opacity: 0.9;
}

.docs-card-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
    gap: 1.25rem;
    margin: 2rem 0;
}

.docs-card {
    background: var(--white);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    padding: 1.5rem;
    text-decoration: none;
    color: var(--text-dark);
    transition: box-shadow 0.2s, transform 0.2s;
    display: flex;
    flex-direction: row;
    align-items: flex-start;
    gap: 1rem;
}

.docs-card:hover {
    box-shadow: var(--shadow-lg);
    transform: translateY(-2px);
}

.docs-card .card-number {
    display: none;
}

.docs-card .card-title {
    font-size: 1rem;
    font-weight: 600;
    line-height: 1.5;
}

.docs-card .card-desc {
    font-size: 0.85rem;
    color: var(--text-gray);
    line-height: 1.6;
}

/* モバイル対応 */
@media (max-width: 768px) {
    .docs-container {
        padding: 1.25rem 1rem 3rem;
    }

    .docs-header h1 {
        font-size: 1.4rem;
    }

    .docs-body h2 {
        font-size: 1.2rem;
    }

    .docs-body h3 {
        font-size: 1.05rem;
    }

    .docs-index-hero {
        padding: 2rem 1rem;
    }

    .docs-index-hero h1 {
        font-size: 1.4rem;
    }

    .docs-card-grid {
        grid-template-columns: 1fr;
    }

    .docs-card .card-icon {
        width: 40px;
        height: 40px;
    }

    .docs-card .card-icon svg {
        width: 20px;
        height: 20px;
    }
}
