body {
    font-family: Arial, sans-serif;
    margin: 20px;
    background-color: #f5f5f5;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    background-color: white;
    padding: 20px;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

h1 {
    color: #333;
    text-align: center;
    margin-bottom: 10px;
}

.subtitle {
    text-align: center;
    color: #666;
    margin-bottom: 20px;
}

.site-nav {
    display: flex;
    flex-wrap: wrap;
    gap: 15px;
    justify-content: center;
    margin-bottom: 20px;
    padding-bottom: 15px;
    border-bottom: 1px solid #ecf0f1;
}

.site-nav a {
    color: #2c3e50;
    text-decoration: none;
    font-weight: bold;
}

.site-nav a:hover {
    text-decoration: underline;
}

.form-section {
    margin-bottom: 30px;
    padding: 20px;
    background-color: #f8f9fa;
    border-radius: 5px;
}

.form-row {
    margin-bottom: 15px;
}

.form-row label {
    display: block;
    font-weight: bold;
    margin-bottom: 5px;
}

.form-row select,
.form-row input[type="text"],
.form-row input[type="number"] {
    padding: 8px;
    border-radius: 4px;
    border: 1px solid #ccc;
    font-size: 14px;
    min-width: 200px;
}

.team-selection {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
    gap: 10px;
    margin-top: 15px;
}

.team-checkbox {
    display: flex;
    align-items: center;
}

.team-checkbox input {
    margin-right: 8px;
}

.team-checkbox label {
    cursor: pointer;
}

.submit-btn {
    background-color: #2c3e50;
    color: white;
    padding: 12px 30px;
    border: none;
    border-radius: 5px;
    font-size: 16px;
    cursor: pointer;
    margin-top: 20px;
}

.submit-btn:hover {
    background-color: #34495e;
}

.results-section {
    margin-top: 30px;
}

.result-item {
    margin-bottom: 30px;
    border: 1px solid #ddd;
    border-radius: 5px;
    overflow: hidden;
}

.result-header {
    background-color: #2c3e50;
    color: white;
    padding: 15px;
    font-size: 18px;
    font-weight: bold;
}

table.data-table,
.games-table {
    width: 100%;
    border-collapse: collapse;
}

table.data-table th,
.games-table th {
    background-color: #ecf0f1;
    padding: 10px;
    text-align: left;
    border-bottom: 2px solid #bdc3c7;
    font-weight: bold;
    position: sticky;
    top: 0;
}

table.data-table td,
.games-table td {
    padding: 10px;
    border-bottom: 1px solid #ecf0f1;
}

table.data-table tr:hover,
.games-table tr:hover {
    background-color: #f8f9fa;
}

.table-wrap {
    overflow-x: auto;
}

.chart-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 20px;
    margin-top: 15px;
}

.chart-box {
    background-color: #f8f9fa;
    border-radius: 5px;
    padding: 15px;
}

.chart-box h3 {
    margin-top: 0;
    margin-bottom: 10px;
    font-size: 16px;
    color: #333;
}

.win {
    background-color: #d4edda;
    font-weight: bold;
}

.pfr-link {
    color: #e74c3c;
    text-decoration: none;
    font-weight: bold;
}

.pfr-link:hover {
    text-decoration: underline;
}

.no-results {
    padding: 20px;
    text-align: center;
    color: #666;
    font-size: 16px;
}

.error {
    background-color: #f8d7da;
    color: #721c24;
    padding: 15px;
    border-radius: 5px;
    margin-bottom: 20px;
}

.info {
    background-color: #d1ecf1;
    color: #0c5460;
    padding: 15px;
    border-radius: 5px;
    margin-bottom: 20px;
}

/* Home page tool/visualization grid */
.grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 20px;
}

.card {
    border: 1px solid #ddd;
    border-radius: 4px;
    padding: 20px;
}

.card a {
    text-decoration: none;
    color: inherit;
}

.card-content {
    display: flex;
    flex-direction: column;
}

.card-image {
    aspect-ratio: auto;
}

.card-title {
    font-weight: bold;
}
