/* Game Sets Styling */

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
}

.header-section {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 30px;
    flex-wrap: wrap;
    gap: 15px;
}

.header-section h1 {
    margin: 0;
    color: #333;
    font-size: 2rem;
}

.breadcrumb {
    color: #666;
    margin-bottom: 10px;
}

.breadcrumb a {
    color: #007bff;
    text-decoration: none;
}

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

.owner-note {
    color: #28a745;
    margin: 10px 0;
    font-style: italic;
}

/* Buttons */
.btn {
    padding: 10px 20px;
    border: none;
    border-radius: 5px;
    text-decoration: none;
    display: inline-block;
    cursor: pointer;
    font-size: 14px;
    transition: background-color 0.2s;
}

.btn-primary {
    background-color: #007bff;
    color: white;
}

.btn-primary:hover {
    background-color: #0056b3;
}

.btn-secondary {
    background-color: #6c757d;
    color: white;
}

.btn-secondary:hover {
    background-color: #545b62;
}

/* Game Sets Grid */
.game-sets-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 20px;
    margin-bottom: 30px;
}

.game-set-card {
    border: 1px solid #ddd;
    border-radius: 8px;
    padding: 20px;
    background: white;
    transition: box-shadow 0.2s, transform 0.2s;
}

.game-set-card:hover {
    box-shadow: 0 4px 8px rgba(0,0,0,0.1);
    transform: translateY(-2px);
}

.game-set-card.owned {
    border-color: #28a745;
    background-color: #f8fff9;
}

.game-set-link {
    text-decoration: none;
    color: inherit;
    display: block;
}

.game-set-card h3 {
    margin: 0 0 10px 0;
    color: #333;
}

.game-set-meta {
    display: flex;
    justify-content: space-between;
    align-items: center;
    color: #666;
    font-size: 14px;
}

.owned-badge {
    background-color: #28a745;
    color: white;
    padding: 3px 8px;
    border-radius: 3px;
    font-size: 12px;
}

/* Search Container */
.search-container {
    position: relative;
    margin-bottom: 20px;
}

#game-search {
    width: 80%;
    padding: 12px;
    border: 2px solid #ddd;
    border-radius: 5px;
    font-size: 16px;
}

#game-search:focus {
    outline: none;
    border-color: #007bff;
}

.search-results {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: white;
    border: 1px solid #ddd;
    border-top: none;
    max-height: 300px;
    overflow-y: auto;
    z-index: 1000;
    display: none;
}

.search-result-item {
    padding: 12px;
    border-bottom: 1px solid #eee;
    cursor: pointer;
    transition: background-color 0.2s;
}

.search-result-item:hover {
    background-color: #f8f9fa;
}

.search-result-item:last-child {
    border-bottom: none;
}

.game-id {
    font-size: 12px;
    color: #666;
}

/* Game Set Content */
.game-set-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    grid-template-rows: auto auto 1fr;
    gap: 20px;
    align-items: start;
}

.game-set-content > h2,
.game-set-content > h3 {
    margin: 0;
    color: #333;
}

.game-set-content > h2 {
    font-size: 1.5rem;
}

.game-set-content > h3 {
    font-size: 1.2rem;
}

.section-description {
    margin: 0;
    color: #666;
    font-size: 0.9rem;
}

@media (max-width: 768px) {
    .game-set-content {
        grid-template-columns: 1fr;
        grid-template-rows: auto;
        gap: 30px;
    }
}


/* Games Lists */
.games-list,
.similar-games-list {
    background: white;
    border: 1px solid #ddd;
    border-radius: 8px;
    overflow: hidden;
}

.game-item,
.similar-game-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px;
    border-bottom: 1px solid #eee;
}

.game-item:last-child,
.similar-game-item:last-child {
    border-bottom: none;
}

.game-info {
    flex: 1;
}

.game-meta {
    display: flex;
    gap: 15px;
    margin-top: 4px;
}

.predicted-rating {
    color: #007bff;
    font-weight: 500;
}

.remove-btn,
.add-btn {
    background-color: #dc3545;
    color: white;
    border: none;
    padding: 0;
    width: 24px;
    height: 24px;
    border-radius: 50%;
    cursor: pointer;
    font-size: 18px;
    font-weight: bold;
    line-height: 1;
    transition: background-color 0.2s;
    display: flex;
    align-items: center;
    justify-content: center;
}

.add-btn {
    background-color: #28a745;
}

.remove-btn:hover {
    background-color: #c82333;
}

.add-btn:hover {
    background-color: #218838;
}

/* Empty States */
.empty-state {
    text-align: center;
    padding: 40px 20px;
    color: #666;
}

.empty-state h3 {
    margin: 0 0 10px 0;
    color: #333;
}

/* Messages */
#message-container {
    margin-bottom: 20px;
}

.message {
    padding: 12px;
    border-radius: 5px;
    margin-bottom: 15px;
}

.message.success {
    background-color: #d4edda;
    color: #155724;
    border: 1px solid #c3e6cb;
}

.message.error {
    background-color: #f8d7da;
    color: #721c24;
    border: 1px solid #f5c6cb;
}

.message.info {
    background-color: #d1ecf1;
    color: #0c5460;
    border: 1px solid #bee5eb;
}

/* Pagination */
.pagination {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 15px;
    margin-top: 30px;
}

.page-info {
    color: #666;
    font-size: 14px;
}

/* Form Styling */
.game-set-form {
    max-width: 500px;
    margin: 0 auto;
    background: white;
    padding: 30px;
    border: 1px solid #ddd;
    border-radius: 8px;
}

.form-group {
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    margin-bottom: 5px;
    font-weight: 500;
    color: #333;
}

.form-control {
    width: 100%;
    padding: 12px;
    border: 1px solid #ddd;
    border-radius: 5px;
    font-size: 16px;
}

.form-control:focus {
    outline: none;
    border-color: #007bff;
}

.form-actions {
    display: flex;
    gap: 15px;
    justify-content: flex-end;
}

.info-section {
    margin-top: 40px;
    padding: 20px;
    background-color: #f8f9fa;
    border-radius: 8px;
}

.info-section h3 {
    margin-top: 0;
    color: #333;
}

.info-section ul {
    margin: 15px 0;
    padding-left: 20px;
}

.info-section li {
    margin-bottom: 8px;
    color: #666;
}

.login-prompt {
    color: #666;
    font-style: italic;
}

/* Features Content */
.features-content {
    background-color: #f8f9fa;
    border-radius: 8px;
    border: 1px solid #dee2e6;
}


.features-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
}

.feature-item {
    background: white;
    border-radius: 4px;
    padding: 8px;
    transition: all 0.2s ease;
}

.feature-item:hover {
    box-shadow: 0 1px 3px rgba(0,0,0,0.1);
}

.feature-label {
    display: flex;
    flex-direction: row;
    align-items: center;
    cursor: pointer;
    margin: 0;
    font-weight: normal;
}

.feature-main {
    display: flex;
    align-items: center;
}

.feature-checkbox {
    margin-right: 6px;
    transform: scale(0.9);
}

.feature-checkbox:checked + .feature-name {
    color: #007bff;
    font-weight: 600;
}

.feature-item:has(.feature-checkbox:checked) {
    background-color: #f0f8ff;
}

.feature-item:has(.feature-checkbox:disabled) {
    opacity: 0.6;
    cursor: not-allowed;
}

.feature-item:has(.feature-checkbox:disabled):hover {
    box-shadow: none;
}

.feature-name {
    color: #333;
    font-size: 12px;
    transition: all 0.2s ease;
}

.selection-status {
    text-align: center;
    margin-top: 12px;
    padding: 6px;
    background-color: white;
    border-radius: 4px;
    border: 1px solid #dee2e6;
    font-size: 12px;
    color: #666;
}

#selected-count {
    font-weight: bold;
    color: #007bff;
}

/* Feature Importance Circles */
.feature-importance-circle {
    display: inline-block;
    width: 12px;
    height: 12px;
    border-radius: 50%;
    margin-right: 8px;
    flex-shrink: 0;
}

.feature-importance-circle.very-high {
    background-color: #dc3545;
}

.feature-importance-circle.high {
    background-color: #fd7e14;
}

.feature-importance-circle.average {
    background-color: #ffc107;
}

.feature-importance-circle.low {
    background-color: #20c997;
}

.feature-importance-circle.very-low {
    background-color: #007bff;
}

.best-feature {
    display: flex;
    flex-direction: row;
    gap: 20px;
}

/* Best Feature Section */
.best-feature-section {
    margin: 20px 0;
    padding: 20px;
    background-color: #fff3cd;
    border: 1px solid #ffeaa7;
    border-radius: 8px;
    height: 100px;
}

.best-feature-section h3 {
    margin: 0 0 10px 0;
    color: #856404;
}

.feature-description {
    margin: 0;
    color: #856404;
}

.feature-description a {
    color: #007bff;
    text-decoration: none;
}

.feature-description a:hover {
    text-decoration: underline;
}

/* Feature sorting info */
.feature-sorting-info {
    background-color: #e3f2fd;
    border: 1px solid #90caf9;
    padding: 12px 16px;
    border-radius: 5px;
}

.feature-sorting-info p {
    margin: 0;
    color: #1565c0;
}

/* Feature value display in game items */
.feature-value {
    color: #1976d2;
    font-weight: 500;
}

.feature-value strong {
    color: #0d47a1;
}

/* Graph Styles */
.graph-section {
    grid-column: 1 / -1; /* Span all columns */
    margin: 20px 0;
    padding: 20px;
    background-color: #f8f9fa;
    border: 1px solid #dee2e6;
    border-radius: 8px;
}

.graph-section h3 {
    margin: 0 0 15px 0;
    color: #333;
    text-align: center;
}

.feature-graph {
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 400px;
    background-color: white;
    border: 1px solid #ddd;
    border-radius: 4px;
    padding: 10px;
}

.graph-svg {
    max-width: 100%;
    height: auto;
}

.graph-point {
    cursor: pointer;
    transition: all 0.2s ease;
}

.graph-point:hover {
    r: 6;
    fill: #ff6b6b;
    stroke: #ff5252;
    stroke-width: 2;
}

.graph-label {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    pointer-events: none;
    opacity: 0.8;
}

.graph-point:hover + .graph-label {
    opacity: 1;
    font-weight: bold;
}

@media (max-width: 768px) {
    .feature-graph {
        min-height: 300px;
    }

    .graph-svg {
        width: 100%;
        height: 300px;
    }

    .graph-label {
        font-size: 8px;
    }
}
