/* ====================================
   Biography Page Styles - Complete Version
   ==================================== */

/* Page Hero */
.page-hero {
    position: relative;
    height: 500px;
    margin-top: 70px;
    overflow: hidden;
}

.page-hero__bg {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-size: cover;
    background-position: center;
    filter: grayscale(100%) contrast(1.1);
    transform: scale(1.1);
}

.page-hero__overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(
        180deg,
        rgba(0, 0, 0, 0.7) 0%,
        rgba(0, 0, 0, 0.8) 50%,
        rgba(0, 0, 0, 0.9) 100%
    );
}

.page-hero__content {
    position: relative;
    z-index: 2;
    height: 100%;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    text-align: center;
}

.page-hero__title {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 15px;
}

.page-hero__title .title-en {
    font-family: 'Playfair Display', serif;
    font-size: 72px;
    font-weight: 900;
    color: var(--white);
    letter-spacing: 0.02em;
    text-shadow: 
        0 0 40px rgba(255, 255, 255, 0.3),
        0 10px 40px rgba(0, 0, 0, 0.8);
}

.page-hero__title .title-jp {
    font-size: 20px;
    color: var(--pale-gray);
    letter-spacing: 0.4em;
    text-shadow: 0 2px 10px rgba(0, 0, 0, 0.5);
}

.page-hero__subtitle {
    margin-top: 25px;
    font-size: 18px;
    color: var(--off-white);
    letter-spacing: 0.1em;
    text-shadow: 0 2px 10px rgba(0, 0, 0, 0.5);
}

/* Container */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 40px;
}

/* Section Title */
.section-title {
    text-align: center;
    margin-bottom: 50px;
}

.section-title .title-en {
    display: block;
    font-family: 'Playfair Display', serif;
    font-size: 36px;
    color: var(--white);
    margin-bottom: 10px;
}

.section-title .title-jp {
    font-size: 14px;
    color: var(--light-gray);
    letter-spacing: 0.2em;
}

/* Profile Section */
.profile-section {
    padding: 80px 0;
    background: var(--dark-gray);
}

.profile-grid {
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: 60px;
}

/* Profile Main */
.profile-main {
    background: rgba(0, 0, 0, 0.3);
    padding: 50px;
    border: 1px solid var(--medium-gray);
}

.profile-list {
    display: grid;
    gap: 25px;
}

.profile-item {
    display: grid;
    grid-template-columns: 140px 1fr;
    gap: 30px;
    padding-bottom: 20px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.profile-item:last-child {
    border-bottom: none;
}

.profile-item dt {
    font-size: 14px;
    color: var(--gray);
    letter-spacing: 0.1em;
}

.profile-item dd {
    font-size: 18px;
    color: var(--off-white);
    font-weight: 500;
}

.profile-item.highlight dd {
    font-family: 'Playfair Display', serif;
    font-size: 24px;
    color: var(--gold-light);
    font-weight: 700;
}

/* Profile Stats */
.profile-stats {
    display: flex;
    flex-direction: column;
    gap: 30px;
}

.stat-box-large {
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.02) 0%, rgba(0, 0, 0, 0.5) 100%);
    border: 1px solid var(--medium-gray);
    padding: 40px 30px;
    text-align: center;
    transition: all 0.3s;
}

.stat-box-large:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 30px rgba(0, 0, 0, 0.3);
    border-color: var(--gold);
}

.stat-title {
    display: block;
    font-size: 12px;
    color: var(--gray);
    letter-spacing: 0.2em;
    text-transform: uppercase;
    margin-bottom: 15px;
}

.stat-main {
    display: block;
    font-family: 'Playfair Display', serif;
    font-size: 36px;
    font-weight: 700;
    color: var(--white);
    margin-bottom: 10px;
}

.stat-detail {
    display: block;
    font-size: 14px;
    color: var(--light-gray);
}

.stat-list {
    list-style: none;
    margin-top: 15px;
}

.stat-list li {
    padding: 8px 0;
    color: var(--pale-gray);
    font-size: 15px;
    position: relative;
    padding-left: 20px;
}

.stat-list li::before {
    content: '▸';
    position: absolute;
    left: 0;
    color: var(--gold);
}

/* Pedigree Section - Table Style */
.pedigree-section {
    padding: 100px 0;
    background: linear-gradient(180deg, var(--black) 0%, var(--dark-gray) 100%);
}

/* 血統表テーブル */
.pedigree-table {
    max-width: 900px;
    margin: 0 auto 60px;
    background: rgba(0, 0, 0, 0.6);
    border: 2px solid var(--medium-gray);
    border-collapse: separate;
    border-spacing: 0;
    overflow: hidden;
}

.pedigree-table table {
    width: 100%;
    border-collapse: collapse;
}

.pedigree-table td {
    border: 1px solid rgba(255, 255, 255, 0.1);
    padding: 12px;
    text-align: center;
    vertical-align: middle;
    position: relative;
}

/* 本馬セル */
.horse-main {
    background: linear-gradient(135deg, rgba(184, 148, 31, 0.15) 0%, rgba(0, 0, 0, 0.8) 100%);
    border-right: 3px solid var(--gold) !important;
}

.horse-main .name {
    font-family: 'Playfair Display', serif;
    font-size: 24px;
    font-weight: 700;
    color: var(--gold-light);
    display: block;
    margin-bottom: 5px;
}

/* 父系セル */
.horse-sire {
    background: rgba(74, 144, 226, 0.08);
}

/* 母系セル */
.horse-dam {
    background: rgba(226, 74, 74, 0.08);
}

/* 馬名 */
.pedigree-table .name {
    font-family: 'Playfair Display', serif;
    font-size: 16px;
    font-weight: 600;
    color: var(--white);
    display: block;
    margin-bottom: 3px;
}

/* 馬情報 */
.pedigree-table .info {
    font-size: 11px;
    color: var(--light-gray);
    display: block;
}

/* 成績 */
.pedigree-table .record {
    font-size: 10px;
    color: var(--gold);
    display: block;
    margin-top: 2px;
}

/* 世代ごとの幅調整 */
.gen-0 { width: 25%; }
.gen-1 { width: 25%; }
.gen-2 { width: 25%; }
.gen-3 { width: 25%; }

/* 祖父母以降は文字を小さく */
.gen-2 .name {
    font-size: 14px;
}

.gen-3 .name {
    font-size: 12px;
}

.gen-3 .info {
    font-size: 10px;
}

/* ホバー効果 */
.pedigree-table td:hover {
    background: rgba(255, 255, 255, 0.05);
}

/* 血統情報 */
.pedigree-info {
    max-width: 900px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 30px;
}

.pedigree-stat {
    background: rgba(0, 0, 0, 0.4);
    border: 1px solid var(--medium-gray);
    padding: 25px;
    text-align: center;
}

.pedigree-stat-label {
    font-size: 12px;
    color: var(--gray);
    letter-spacing: 0.1em;
    text-transform: uppercase;
    display: block;
    margin-bottom: 10px;
}

.pedigree-stat-value {
    font-size: 16px;
    color: var(--gold-light);
    font-weight: 600;
}

.pedigree-analysis {
    margin-top: 40px;
    padding: 40px;
    background: rgba(0, 0, 0, 0.4);
    border: 1px solid var(--medium-gray);
    border-left: 4px solid var(--gold);
}

.pedigree-analysis h4 {
    font-size: 18px;
    color: var(--gold-light);
    margin-bottom: 15px;
}

.pedigree-analysis p {
    font-size: 14px;
    color: var(--pale-gray);
    line-height: 1.8;
}

/* Career Section - 縦型タイムライン */
.career-section {
    padding: 100px 0;
    background: linear-gradient(to bottom, #1a1a1a 0%, #0d0d0d 100%);
}

.career-timeline {
    max-width: 900px;
    margin: 60px auto 0;
    position: relative;
}

/* タイムライン縦線 */
.career-timeline::before {
    content: '';
    position: absolute;
    left: 90px;
    top: 0;
    bottom: 0;
    width: 2px;
    background: linear-gradient(to bottom, 
        var(--gold) 0%, 
        var(--medium-gray) 50%, 
        rgba(160, 130, 90, 0.3) 100%);
    z-index: 1;
}

.timeline-item {
    display: flex;
    gap: 40px;
    margin-bottom: 60px;
    position: relative;
}

.timeline-item:last-child {
    margin-bottom: 0;
}

/* 年号の円 */
.timeline-year {
    flex-shrink: 0;
    width: 80px;
    height: 80px;
    background: var(--gold);
    color: var(--black);
    font-family: 'Playfair Display', serif;
    font-size: 1.2rem;
    font-weight: 700;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    position: relative;
    z-index: 2;
    box-shadow: 0 4px 12px rgba(212, 175, 55, 0.5);
    text-align: center;
    line-height: 1.2;
    border: 3px solid var(--gold-light);
}

/* コンテンツボックス */
.timeline-content {
    flex: 1;
    background: rgba(0, 0, 0, 0.5);
    padding: 30px;
    border-radius: 8px;
    border: 1px solid var(--medium-gray);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.3);
    position: relative;
    transition: all 0.3s ease;
}

/* 左側の三角形 */
.timeline-content::before {
    content: '';
    position: absolute;
    left: -10px;
    top: 35px;
    width: 0;
    height: 0;
    border-style: solid;
    border-width: 10px 10px 10px 0;
    border-color: transparent var(--medium-gray) transparent transparent;
}

.timeline-content::after {
    content: '';
    position: absolute;
    left: -8px;
    top: 36px;
    width: 0;
    height: 0;
    border-style: solid;
    border-width: 9px 9px 9px 0;
    border-color: transparent rgba(0, 0, 0, 0.5) transparent transparent;
}

.timeline-item:hover .timeline-content {
    transform: translateY(-5px);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.5);
    border-color: var(--gold);
}

.timeline-content h3 {
    font-family: 'Noto Serif JP', serif;
    font-size: 1.4rem;
    font-weight: 600;
    color: var(--white);
    margin-bottom: 15px;
    line-height: 1.6;
}

.timeline-content p {
    font-family: 'Noto Serif JP', serif;
    font-size: 1rem;
    line-height: 1.8;
    color: var(--pale-gray);
}

/* Responsive */
@media (max-width: 768px) {
    /* Page Hero */
    .page-hero {
        height: 350px;
        margin-top: 60px;
    }
    
    .page-hero__title .title-en {
        font-size: 42px;
    }
    
    .page-hero__title .title-jp {
        font-size: 16px;
    }
    
    .page-hero__subtitle {
        font-size: 14px;
    }
    
    /* Container */
    .container {
        padding: 0 20px;
    }
    
    /* Profile Section */
    .profile-section {
        padding: 50px 0;
    }
    
    .profile-grid {
        grid-template-columns: 1fr;
        gap: 30px;
    }
    
    .profile-main {
        padding: 30px 20px;
    }
    
    .profile-item {
        grid-template-columns: 1fr;
        gap: 10px;
    }
    
    .profile-item dt {
        font-size: 12px;
    }
    
    .profile-item dd {
        font-size: 16px;
    }
    
    .profile-item.highlight dd {
        font-size: 20px;
    }
    
    /* Profile Stats */
    .stat-box-large {
        padding: 30px 20px;
    }
    
    .stat-main {
        font-size: 28px;
    }
    
    /* Pedigree Section */
    .pedigree-section {
        padding: 60px 0;
    }
    
    .pedigree-table {
        overflow-x: auto;
        display: block;
    }
    
    .pedigree-table table {
        min-width: 600px;
    }
    
    .pedigree-info {
        grid-template-columns: 1fr;
    }
    
    .pedigree-analysis {
        padding: 30px 20px;
    }
    
    .pedigree-analysis h4 {
        font-size: 16px;
    }
    
    .pedigree-analysis p {
        font-size: 13px;
    }
    
    /* Career Section */
    .career-section {
        padding: 60px 0;
    }

    .career-timeline::before {
        left: 40px;
    }

    .timeline-item {
        gap: 20px;
        margin-bottom: 50px;
    }

    .timeline-year {
        width: 60px;
        height: 60px;
        font-size: 0.9rem;
        border-width: 2px;
    }

    .timeline-content {
        padding: 20px;
    }

    .timeline-content::before {
        left: -8px;
        top: 25px;
        border-width: 8px 8px 8px 0;
    }

    .timeline-content::after {
        left: -6px;
        top: 26px;
        border-width: 7px 7px 7px 0;
    }

    .timeline-content h3 {
        font-size: 1.2rem;
    }

    .timeline-content p {
        font-size: 0.9rem;
    }
}

@media (max-width: 480px) {
    .page-hero__title .title-en {
        font-size: 32px;
    }
    
    .pedigree-table table {
        font-size: 10px;
    }
    
    .pedigree-table .name {
        font-size: 12px;
    }
    
    .horse-main .name {
        font-size: 18px;
    }

    .career-timeline::before {
        left: 30px;
    }

    .timeline-item {
        gap: 15px;
    }

    .timeline-year {
        width: 50px;
        height: 50px;
        font-size: 0.8rem;
    }

    .timeline-content {
        padding: 15px;
    }

    .timeline-content h3 {
        font-size: 1.1rem;
    }

    .timeline-content p {
        font-size: 0.85rem;
    }
}
