﻿* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    line-height: 1.6;
    color: #333;
    background-color: #f8f9fa;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px;
}

/* Header Section */
.header {
    background: linear-gradient(135deg, #1e3c72 0%, #2a5298 100%);
    color: white;
    padding: 30px;
    border-radius: 12px;
    margin-bottom: 30px;
    box-shadow: 0 4px 20px rgba(0,0,0,0.1);
}

.stallion-info h1 {
    font-size: 2.5rem;
    margin-bottom: 10px;
    font-weight: 700;
}

.stallion-details {
    font-size: 1.1rem;
    opacity: 0.9;
    margin-bottom: 20px;
}

.season-info {
    background: rgba(255,255,255,0.1);
    padding: 15px;
    border-radius: 8px;
    font-size: 0.95rem;
}

/* Summary Statistics */
.summary-stats {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 20px;
    margin-bottom: 30px;
}

.stat-card {
    background: white;
    padding: 25px;
    border-radius: 12px;
    text-align: center;
    box-shadow: 0 2px 10px rgba(0,0,0,0.08);
    border-left: 4px solid #2a5298;
}

.stat-number {
    font-size: 2.2rem;
    font-weight: 700;
    color: #2a5298;
    margin-bottom: 5px;
}

.stat-label {
    font-size: 0.9rem;
    color: #666;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

/* Controls */
.controls {
    background: white;
    padding: 20px;
    border-radius: 12px;
    margin-bottom: 30px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.08);
    display: flex;
    flex-wrap: wrap;
    gap: 15px;
    align-items: center;
}

.search-box, .year-filter {
    padding: 12px 15px;
    border: 2px solid #e9ecef;
    border-radius: 8px;
    font-size: 1rem;
    transition: all 0.3s ease;
}

    .search-box:focus, .year-filter:focus {
        outline: none;
        border-color: #2a5298;
        box-shadow: 0 0 0 3px rgba(42, 82, 152, 0.1);
    }

.search-box {
    flex: 1;
    min-width: 250px;
}

/* Stakes Winners Section */
.stakes-winners {
    margin-bottom: 40px;
}

.section-title {
    font-size: 1.8rem;
    color: #2a5298;
    margin-bottom: 20px;
    padding-bottom: 10px;
    border-bottom: 3px solid #2a5298;
    font-weight: 600;
}

.stakes-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: 20px;
    margin-bottom: 30px;
}

.stakes-horse-card {
    background: linear-gradient(0deg, #96D6EB 0%, #ffffff 100%);
    color: black;
    padding: 25px;
    border-radius: 12px;
    box-shadow: 0 4px 20px rgba(0,0,0,0.15);
    transition: transform 0.3s ease;
}

    .stakes-horse-card:hover {
        transform: translateY(-5px);
    }

.horse-name {
    font-size: 1.3rem;
    font-weight: 700;
    margin-bottom: 8px;
}

    .horse-name a {
        color: white;
        text-decoration: none;
    }

.horse-details {
    font-size: 0.9rem;
    opacity: 0.9;
    margin-bottom: 15px;
}

.earnings {
    font-size: 1.1rem;
    font-weight: 600;
    margin-bottom: 10px;
}

.major-wins {
    background: rgba(255,255,255,0.15);
    padding: 12px;
    border-radius: 6px;
    font-size: 0.9rem;
}

/* Stakes Placed Section */
.stakes-placed .section-title {
    color: #fd7e14;
    border-bottom-color: #fd7e14;
}

.stakes-placed-card {
    background: linear-gradient(0deg, #FD9944 0%, #FFFFFF 90%);
    color: black;
    padding: 25px;
    border-radius: 12px;
    box-shadow: 0 4px 20px rgba(0,0,0,0.15);
    transition: transform 0.3s ease;
}

    .stakes-placed-card:hover {
        transform: translateY(-5px);
    }

    .stakes-placed-card .horse-name {
        font-size: 1.3rem;
        font-weight: 700;
        margin-bottom: 8px;
    }

        .stakes-placed-card .horse-name a {
            color: white;
            text-decoration: none;
        }

    .stakes-placed-card .horse-details {
        font-size: 0.9rem;
        opacity: 0.9;
        margin-bottom: 15px;
    }

    .stakes-placed-card .earnings {
        font-size: 1.1rem;
        font-weight: 600;
        margin-bottom: 10px;
    }

    .stakes-placed-card .major-wins {
        background: rgba(255,255,255,0.15);
        padding: 12px;
        border-radius: 6px;
        font-size: 0.9rem;
    }

/* Regular Winners Section */
.regular-winners .section-title {
    color: #28a745;
    border-bottom-color: #28a745;
}

.winners-table {
    background: white;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 2px 10px rgba(0,0,0,0.08);
}

.table-header {
    background: #f8f9fa;
    padding: 15px 20px;
    border-bottom: 2px solid #e9ecef;
    font-weight: 600;
    display: grid;
    grid-template-columns: 2fr 1fr 1fr 3fr;
    gap: 15px;
}

.horse-row {
    padding: 15px 20px;
    border-bottom: 1px solid #e9ecef;
    display: grid;
    grid-template-columns: 2fr 1fr 1fr 3fr;
    gap: 15px;
    align-items: center;
    transition: background-color 0.2s ease;
}

    .horse-row:hover {
        background-color: #f8f9fa;
    }

    .horse-row:last-child {
        border-bottom: none;
    }

    .horse-row .horse-name {
        font-size: 1rem;
        font-weight: 600;
        color: #2a5298;
        margin-bottom: 3px;
    }

        .horse-row .horse-name a {
            color: #2a5298;
            text-decoration: none;
        }

            .horse-row .horse-name a:hover {
                text-decoration: underline;
            }

.horse-info {
    font-size: 0.85rem;
    color: #666;
}

.wins-count {
    font-weight: 600;
    color: #28a745;
}

.earnings-amount {
    font-weight: 600;
    color: #2a5298;
}

.race-results {
    font-size: 0.85rem;
    color: #666;
    line-height: 1.4;
}

.grade-tag {
    display: inline-block;
    background: #dc3545;
    color: white;
    padding: 2px 6px;
    border-radius: 4px;
    font-size: 0.7rem;
    font-weight: 600;
    margin-right: 3px;
}

.lr-tag {
    background: #fd7e14;
}

.gr-tag {
    background: #dc3545;
}

/* Placegetters Section */
.placegetters .section-title {
    color: #6f42c1;
    border-bottom-color: #6f42c1;
}

/* Responsive Design */
@media (max-width: 768px) {
    .container {
        padding: 15px;
    }

    .header {
        padding: 20px;
    }

    .stallion-info h1 {
        font-size: 2rem;
    }

    .summary-stats {
        grid-template-columns: repeat(2, 1fr);
    }

    .controls {
        flex-direction: column;
        align-items: stretch;
    }

    .stakes-grid {
        grid-template-columns: 1fr;
    }

    .table-header, .horse-row {
        grid-template-columns: 1fr;
        gap: 10px;
    }

    .table-header {
        display: none;
    }

    .horse-row {
        padding: 15px;
        border-radius: 8px;
        margin-bottom: 10px;
        box-shadow: 0 2px 5px rgba(0,0,0,0.05);
    }
}

.hidden {
    display: none;
}

/* Loading States */
.loading {
    text-align: center;
    padding: 40px;
    color: #666;
}
