/**
 * ドキュメントシステム専用CSS
 * ハグー風統一デザイン
 */

/* ========================================
   レイアウト構造
   ======================================== */

.docs-container {
    background: #f5f7fa;
    min-height: calc(100vh - 200px);
}

.docs-wrapper {
    max-width: 1400px;
    margin: 0 auto;
    display: flex;
    gap: 0;
}

/* ========================================
   左サイドバー
   ======================================== */

.docs-sidebar {
    width: 280px;
    flex-shrink: 0;
    background: #ffffff;
    border-right: 1px solid #e0e0e0;
    position: sticky;
    top: 80px; /* ヘッダー高さ分 */
    height: calc(100vh - 80px);
    overflow-y: auto;
    padding: 2rem 0;
}

.docs-nav-section {
    margin-bottom: 2rem;
    padding: 0 1.5rem;
}

.docs-nav-title {
    font-size: 0.9rem;
    font-weight: 700;
    color: #333;
    margin-bottom: 0.75rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.docs-nav-icon {
    font-size: 1.2rem;
}

.docs-nav-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

.docs-nav-list li {
    margin-bottom: 0.25rem;
}

.docs-nav-link {
    display: block;
    padding: 0.5rem 1rem;
    color: #666;
    text-decoration: none;
    border-radius: 6px;
    font-size: 0.9rem;
    transition: all 0.3s;
}

.docs-nav-link:hover {
    background: #f0f0f0;
    color: #4A90E2;
}

.docs-nav-link.active {
    background: #E3F2FD;
    color: #4A90E2;
    font-weight: 600;
}

/* サイドバーCTA */
.docs-sidebar-cta {
    margin-top: 2rem;
    padding: 0 1.5rem;
}

.docs-sidebar-cta-inner {
    background: #f8f9fa;
    border: 1px solid #e0e0e0;
    border-radius: 8px;
    padding: 1.5rem;
    text-align: center;
}

.docs-sidebar-cta-inner h4 {
    font-size: 0.9rem;
    font-weight: 700;
    margin-bottom: 0.5rem;
    color: #333;
}

.docs-sidebar-cta-inner p {
    font-size: 0.8rem;
    color: #666;
    margin-bottom: 1rem;
}

.docs-sidebar-cta-buttons {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.docs-sidebar-cta-buttons .btn {
    width: 100%;
    font-size: 0.85rem;
}

/* ========================================
   メインコンテンツ
   ======================================== */

.docs-main {
    flex: 1;
    min-width: 0;
    background: #ffffff;
    padding: 2rem 3rem;
}

/* パンくずリスト */
.docs-breadcrumb {
    margin-bottom: 2rem;
    padding-bottom: 1rem;
    border-bottom: 1px solid #e0e0e0;
}

.breadcrumb-list {
    display: flex;
    flex-wrap: wrap;
    list-style: none;
    padding: 0;
    margin: 0;
    font-size: 0.85rem;
    color: #666;
}

.breadcrumb-item {
    display: flex;
    align-items: center;
}

.breadcrumb-item + .breadcrumb-item::before {
    content: '>';
    margin: 0 0.5rem;
    color: #999;
}

.breadcrumb-item a {
    color: #4A90E2;
    text-decoration: none;
}

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

.breadcrumb-item.active {
    color: #333;
    font-weight: 600;
}

/* ヘッダー画像（オプション） */
.docs-header-image {
    margin-bottom: 2rem;
    border-radius: 8px;
    overflow: hidden;
}

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

/* コンテンツエリア */
.docs-content {
    max-width: 900px;
}

.docs-title {
    font-size: 2rem;
    font-weight: 700;
    color: #333;
    margin-bottom: 2rem;
    line-height: 1.4;
}

.docs-body {
    color: #333;
    line-height: 1.8;
    font-size: 1rem;
}

/* 見出し */
.docs-body h2 {
    font-size: 1.5rem;
    font-weight: 700;
    color: #333;
    margin-top: 2.5rem;
    margin-bottom: 1rem;
    padding-bottom: 0.5rem;
    border-bottom: 2px solid #4A90E2;
}

.docs-body h3 {
    font-size: 1.25rem;
    font-weight: 700;
    color: #333;
    margin-top: 2rem;
    margin-bottom: 1rem;
}

.docs-body h4 {
    font-size: 1.1rem;
    font-weight: 600;
    color: #333;
    margin-top: 1.5rem;
    margin-bottom: 0.75rem;
}

/* 段落 */
.docs-body p {
    margin-bottom: 1.5rem;
}

.docs-body p.lead {
    font-size: 1.15rem;
    color: #666;
    margin-bottom: 2rem;
}

/* リスト */
.docs-body ul,
.docs-body ol {
    margin-bottom: 1.5rem;
    padding-left: 2rem;
}

.docs-body li {
    margin-bottom: 0.5rem;
}

/* リンク */
.docs-body a {
    color: #4A90E2;
    text-decoration: underline;
}

.docs-body a:hover {
    color: #357ABD;
}

/* カード */
.docs-body .card {
    border: 1px solid #e0e0e0;
    border-radius: 8px;
    padding: 1.5rem;
    margin-bottom: 1.5rem;
    background: #f8f9fa;
}

/* テーブル */
.docs-body table {
    width: 100%;
    border-collapse: collapse;
    margin-bottom: 1.5rem;
}

.docs-body th,
.docs-body td {
    padding: 0.75rem;
    border: 1px solid #e0e0e0;
    text-align: left;
}

.docs-body th {
    background: #f8f9fa;
    font-weight: 600;
}

/* 注意事項ボックス */
.docs-body .alert {
    padding: 1rem 1.5rem;
    border-radius: 8px;
    margin-bottom: 1.5rem;
}

.docs-body .alert-info {
    background: #E3F2FD;
    border-left: 4px solid #4A90E2;
    color: #1565C0;
}

.docs-body .alert-success {
    background: #E8F5E9;
    border-left: 4px solid #4CAF50;
    color: #2E7D32;
}

.docs-body .alert-warning {
    background: #FFF3E0;
    border-left: 4px solid #FF9800;
    color: #E65100;
}

/* ========================================
   レスポンシブ対応
   ======================================== */

/* タブレット */
@media (max-width: 992px) {
    .docs-wrapper {
        flex-direction: column;
    }

    .docs-sidebar {
        width: 100%;
        height: auto;
        position: static;
        border-right: none;
        border-bottom: 1px solid #e0e0e0;
    }

    .docs-main {
        padding: 2rem 1.5rem;
    }
}

/* スマホ */
@media (max-width: 768px) {
    .docs-main {
        padding: 1.5rem 1rem;
    }

    .docs-title {
        font-size: 1.5rem;
    }

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

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

    /* サイドバーを折りたたみ可能に */
    .docs-sidebar {
        padding: 1rem 0;
    }

    .docs-nav-section {
        padding: 0 1rem;
    }
}
