/* ==========================================
   POC改善プロセス：学習ループ再設計
   視覚的で理解しやすいインフォグラフィック中心のデザイン
   ========================================== */

/* セクション全体 */
.section-learning-loop-redesign {
    padding: 100px 0;
    background: linear-gradient(180deg, #f8fafc 0%, #ffffff 100%);
    position: relative;
    overflow: hidden;
}

/* セクションヘッダー */
.learning-loop-header {
    text-align: center;
    margin-bottom: 80px;
}

.learning-loop-title {
    font-size: 48px;
    font-weight: 700;
    color: #1e293b;
    margin-bottom: 16px;
    letter-spacing: -0.02em;
}

.learning-loop-subtitle {
    font-size: 20px;
    color: #64748b;
    font-weight: 400;
    max-width: 800px;
    margin: 0 auto;
}

/* メインレイアウト：左(失敗) - 中央(ループ) - 右(改善) */
.learning-loop-layout {
    display: grid;
    grid-template-columns: 280px 1fr 280px;
    gap: 60px;
    align-items: start;
    max-width: 1400px;
    margin: 0 auto;
    position: relative;
}

/* ========== 中央：学習ループ円形インフォグラフィック ========== */
.learning-loop-center {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 40px;
}

.loop-infographic-container {
    position: relative;
    width: 100%;
    max-width: 550px;
    margin: 0 auto;
}

.loop-svg-container {
    width: 100%;
    height: auto;
}

.loop-center-title {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    text-align: center;
    z-index: 10;
}

.loop-center-title h3 {
    font-size: 24px;
    font-weight: 700;
    color: #1e40af;
    margin: 0 0 8px 0;
    letter-spacing: 0.5px;
}

.loop-center-title p {
    font-size: 14px;
    color: #64748b;
    margin: 0;
    font-weight: 600;
}

/* SVGアニメーション */
@keyframes rotateLoop {
    from { transform: rotate(0deg); }
    to { transform: rotate(360deg); }
}

.loop-circle {
    fill: none;
    stroke: url(#loopGradient);
    stroke-width: 3;
    stroke-dasharray: 1570;
    stroke-dashoffset: 1570;
    animation: drawLoop 2s ease-out forwards;
}

@keyframes drawLoop {
    to { stroke-dashoffset: 0; }
}

.loop-arrow {
    fill: #3b82f6;
    opacity: 0;
    animation: fadeInArrow 0.5s ease-out forwards;
}

.loop-arrow:nth-child(1) { animation-delay: 0.5s; }
.loop-arrow:nth-child(2) { animation-delay: 1s; }
.loop-arrow:nth-child(3) { animation-delay: 1.5s; }
.loop-arrow:nth-child(4) { animation-delay: 2s; }

@keyframes fadeInArrow {
    to { opacity: 1; }
}

.loop-icon-wrapper {
    opacity: 0;
    animation: fadeInIcon 0.5s ease-out forwards;
}

.loop-icon-wrapper:nth-child(1) { animation-delay: 0.3s; }
.loop-icon-wrapper:nth-child(2) { animation-delay: 0.6s; }
.loop-icon-wrapper:nth-child(3) { animation-delay: 0.9s; }
.loop-icon-wrapper:nth-child(4) { animation-delay: 1.2s; }

@keyframes fadeInIcon {
    from { opacity: 0; transform: scale(0.8); }
    to { opacity: 1; transform: scale(1); }
}

/* 背景のシステムアイコン */
.loop-bg-icons {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    opacity: 0.05;
    pointer-events: none;
}

.loop-bg-icon {
    position: absolute;
    font-size: 48px;
    color: #3b82f6;
}

.loop-bg-icon:nth-child(1) { top: 10%; left: 10%; }
.loop-bg-icon:nth-child(2) { top: 20%; right: 15%; }
.loop-bg-icon:nth-child(3) { bottom: 15%; left: 15%; }
.loop-bg-icon:nth-child(4) { bottom: 20%; right: 10%; }

/* ========== 左側：赤い失敗カード（4つ） ========== */
.failure-cards-column {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.failure-card-compact {
    background: white;
    border-radius: 16px;
    padding: 20px;
    box-shadow: 0 4px 16px rgba(239, 68, 68, 0.15);
    border-left: 4px solid #ef4444;
    transition: all 0.3s ease;
    cursor: pointer;
}

.failure-card-compact:hover {
    box-shadow: 0 8px 24px rgba(239, 68, 68, 0.25);
    transform: translateX(-4px);
}

.failure-card-header-compact {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 12px;
}

.failure-icon-compact {
    width: 40px;
    height: 40px;
    background: linear-gradient(135deg, #ef4444, #dc2626);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    box-shadow: 0 4px 12px rgba(239, 68, 68, 0.3);
}

.failure-icon-compact i {
    font-size: 18px;
    color: white;
}

.failure-number-compact {
    font-size: 14px;
    font-weight: 700;
    color: #ef4444;
    background: #fef2f2;
    padding: 4px 12px;
    border-radius: 20px;
}

.failure-title-compact {
    font-size: 16px;
    font-weight: 700;
    color: #1e293b;
    margin: 0 0 8px 0;
    line-height: 1.4;
}

.failure-description-compact {
    font-size: 14px;
    color: #64748b;
    line-height: 1.6;
    margin: 0;
}

/* 折りたたみコンテンツ */
.failure-details-compact {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease;
    padding-top: 0;
    margin-top: 0;
}

.failure-card-compact.expanded .failure-details-compact {
    max-height: 200px;
    padding-top: 12px;
    margin-top: 12px;
    border-top: 1px solid #fee2e2;
}

.failure-details-text {
    font-size: 13px;
    color: #64748b;
    line-height: 1.7;
    margin: 0;
}

.expand-indicator {
    margin-left: auto;
    font-size: 14px;
    color: #ef4444;
    transition: transform 0.3s ease;
}

.failure-card-compact.expanded .expand-indicator {
    transform: rotate(180deg);
}

/* ========== 右側：青い改善カード（4つ） ========== */
.improvement-cards-column {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.improvement-card-compact {
    background: white;
    border-radius: 16px;
    padding: 20px;
    box-shadow: 0 4px 16px rgba(59, 130, 246, 0.15);
    border-left: 4px solid #3b82f6;
    transition: all 0.3s ease;
}

.improvement-card-compact:hover {
    box-shadow: 0 8px 24px rgba(59, 130, 246, 0.25);
    transform: translateX(4px);
}

.improvement-card-header-compact {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 12px;
}

.improvement-icon-compact {
    width: 40px;
    height: 40px;
    background: linear-gradient(135deg, #3b82f6, #2563eb);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    box-shadow: 0 4px 12px rgba(59, 130, 246, 0.3);
}

.improvement-icon-compact i {
    font-size: 18px;
    color: white;
}

.improvement-number-compact {
    font-size: 14px;
    font-weight: 700;
    color: #3b82f6;
    background: #eff6ff;
    padding: 4px 12px;
    border-radius: 20px;
}

.improvement-title-compact {
    font-size: 16px;
    font-weight: 700;
    color: #1e293b;
    margin: 0 0 8px 0;
    line-height: 1.4;
}

.improvement-description-compact {
    font-size: 14px;
    color: #64748b;
    line-height: 1.6;
    margin: 0;
}

/* ========== 結論メッセージ & CTA ========== */
.learning-loop-conclusion {
    margin-top: 80px;
    max-width: 1200px;
    margin-left: auto;
    margin-right: auto;
}

.conclusion-banner {
    background: linear-gradient(135deg, #1e40af, #3b82f6);
    border-radius: 24px;
    padding: 50px 60px;
    text-align: center;
    box-shadow: 0 12px 40px rgba(30, 64, 175, 0.3);
    position: relative;
    overflow: hidden;
}

.conclusion-banner::before {
    content: '';
    position: absolute;
    top: -50%;
    right: -20%;
    width: 400px;
    height: 400px;
    background: radial-gradient(circle, rgba(255, 255, 255, 0.1) 0%, transparent 70%);
    border-radius: 50%;
}

.conclusion-icon {
    width: 80px;
    height: 80px;
    background: rgba(255, 255, 255, 0.2);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 24px;
    backdrop-filter: blur(10px);
}

.conclusion-icon i {
    font-size: 40px;
    color: white;
}

.conclusion-title {
    font-size: 32px;
    font-weight: 700;
    color: white;
    margin: 0 0 16px 0;
    letter-spacing: -0.01em;
}

.conclusion-text {
    font-size: 18px;
    color: rgba(255, 255, 255, 0.95);
    line-height: 1.7;
    margin: 0 0 32px 0;
    max-width: 900px;
    margin-left: auto;
    margin-right: auto;
}

.conclusion-cta {
    display: flex;
    gap: 20px;
    justify-content: center;
    align-items: center;
}

.conclusion-btn-primary {
    background: white;
    color: #1e40af;
    padding: 16px 40px;
    border-radius: 40px;
    font-size: 18px;
    font-weight: 700;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 12px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.15);
    transition: all 0.3s ease;
}

.conclusion-btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 30px rgba(0, 0, 0, 0.25);
}

.conclusion-btn-secondary {
    background: rgba(255, 255, 255, 0.2);
    color: white;
    padding: 16px 40px;
    border-radius: 40px;
    font-size: 18px;
    font-weight: 700;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 12px;
    border: 2px solid white;
    backdrop-filter: blur(10px);
    transition: all 0.3s ease;
}

.conclusion-btn-secondary:hover {
    background: rgba(255, 255, 255, 0.3);
    transform: translateY(-2px);
}

/* ========== レスポンシブ対応 ========== */
@media (max-width: 1200px) {
    .learning-loop-layout {
        grid-template-columns: 1fr;
        gap: 60px;
    }

    .learning-loop-center {
        order: 1;
    }

    .failure-cards-column {
        order: 2;
    }

    .improvement-cards-column {
        order: 3;
    }

    .failure-card-compact,
    .improvement-card-compact {
        max-width: 600px;
        margin: 0 auto;
    }
}

@media (max-width: 768px) {
    .learning-loop-title {
        font-size: 32px;
    }

    .learning-loop-subtitle {
        font-size: 16px;
    }

    .loop-infographic-container {
        max-width: 350px;
    }

    .conclusion-banner {
        padding: 40px 30px;
    }

    .conclusion-title {
        font-size: 24px;
    }

    .conclusion-text {
        font-size: 16px;
    }

    .conclusion-cta {
        flex-direction: column;
        width: 100%;
    }

    .conclusion-btn-primary,
    .conclusion-btn-secondary {
        width: 100%;
        justify-content: center;
    }
}
