.bgg-collection-wrapper {
    width: 100%;
    margin: 20px 0;
    font-family: "Segoe UI", Roboto, Oxygen-Sans, Ubuntu, Cantarell, "Helvetica Neue", sans-serif;
}

.bgg-search-container {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 12px;
    margin-bottom: 20px;
}

.bgg-search-input {
    flex: 1;
    min-width: 200px;
    max-width: 400px;
    padding: 10px 16px;
    font-size: 16px;
    border: 1px solid #eaeaea;
    border-radius: 4px;
    background-color: #fff;
    color: #404040;
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.bgg-search-input:focus {
    outline: none;
    border-color: #2196f3;
    box-shadow: 0 0 0 3px rgba(33, 150, 243, 0.1);
}

.bgg-search-input::placeholder {
    color: #999;
}

.bgg-search-count {
    font-size: 14px;
    color: #666;
    font-weight: 500;
}

.bgg-table-container {
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
}

.bgg-collection-table {
    width: 100%;
    border-collapse: collapse;
    background-color: #fff;
    box-shadow: 0px 5px 30px 0 rgba(0, 0, 0, 0.1);
    border: 1px solid #eaeaea;
}

.bgg-collection-table th,
.bgg-collection-table td {
    padding: 14px 16px;
    text-align: left;
    vertical-align: middle;
    border-bottom: 1px solid #eaeaea;
}

.bgg-collection-table th {
    background-color: #fafafa;
    font-weight: 500;
    color: #4d4d4d;
    font-size: 14px;
    border-bottom: 2px solid #eaeaea;
}

.bgg-collection-table tbody tr {
    transition: background-color 0.2s ease;
}

.bgg-collection-table tbody tr:hover {
    background-color: #f8f9fa;
}

.bgg-collection-table tbody tr:last-child td {
    border-bottom: none;
}

.bgg-col-thumbnail {
    width: 90px;
    text-align: center;
}

.bgg-col-age,
.bgg-col-players,
.bgg-col-time {
    white-space: nowrap;
}

.bgg-collection-table img {
    width: 75px;
    height: auto;
    display: block;
    border-radius: 4px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.bgg-collection-table a {
    color: #4169e1;
    text-decoration: none;
    font-weight: 500;
}

.bgg-collection-table a:hover,
.bgg-collection-table a:focus {
    color: #2196f3;
    text-decoration: none;
}

.no-thumbnail {
    display: block;
    width: 75px;
    height: 75px;
    background-color: #f5f5f5;
    border-radius: 4px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #999;
    font-size: 11px;
    text-align: center;
    line-height: 1.3;
}

.bgg-error {
    background-color: #f8d7da;
    color: #721c24;
    padding: 15px 20px;
    border: 1px solid #f5c6cb;
    border-radius: 4px;
    margin: 20px 0;
}

.bgg-no-results {
    background-color: #fff;
    padding: 40px 20px;
    text-align: center;
    border: 1px solid #eaeaea;
    border-radius: 4px;
    color: #666;
}

.bgg-no-results p {
    margin: 0;
    font-size: 16px;
}

.bgg-pagination-info {
    margin-bottom: 15px;
    color: #666;
    font-size: 14px;
}

.bgg-pagination-info p {
    margin: 0;
}

.bgg-pagination-controls {
    display: flex;
    justify-content: center;
    align-items: center;
    margin-top: 20px;
    gap: 10px;
    flex-wrap: wrap;
}

.bgg-pagination-numbers {
    display: flex;
    gap: 5px;
    align-items: center;
}

.bgg-pagination-link {
    display: inline-block;
    padding: 8px 14px;
    margin: 0 2px;
    background-color: #fff;
    color: #212121;
    text-decoration: none;
    border: 1px solid #eaeaea;
    border-radius: 4px;
    font-size: 14px;
    transition: all 0.2s ease;
    min-width: 40px;
    text-align: center;
}

.bgg-pagination-link:hover {
    background-color: #f5f5f5;
    color: #2196f3;
    border-color: #2196f3;
    text-decoration: none;
}

.bgg-pagination-current {
    background-color: #2196f3 !important;
    color: #fff !important;
    border-color: #2196f3 !important;
    font-weight: 500;
}

.bgg-pagination-current:hover {
    background-color: #1976d2 !important;
    color: #fff !important;
    border-color: #1976d2 !important;
}

.bgg-pagination-prev,
.bgg-pagination-next {
    font-weight: 500;
}

.bgg-pagination-ellipsis {
    padding: 8px 4px;
    color: #999;
    font-weight: bold;
}

@media (max-width: 768px) {
    .bgg-collection-wrapper {
        margin: 15px 0;
    }
    
    .bgg-search-input {
        min-width: 100%;
        max-width: 100%;
    }
    
    .bgg-collection-table {
        display: block;
        overflow-x: auto;
        white-space: nowrap;
    }
    
    .bgg-collection-table th,
    .bgg-collection-table td {
        padding: 10px 12px;
    }
    
    .bgg-collection-table img {
        width: 60px;
    }
    
    .no-thumbnail {
        width: 60px;
        height: 60px;
        font-size: 10px;
    }
    
    .bgg-pagination-controls {
        gap: 8px;
    }
    
    .bgg-pagination-link {
        padding: 6px 12px;
        font-size: 13px;
        min-width: 36px;
    }
    
    .bgg-pagination-numbers .bgg-pagination-link:nth-child(n+6) {
        display: none;
    }
}

@media (max-width: 600px) {
    .bgg-table-container {
        overflow-x: visible;
    }
    
    .bgg-collection-table,
    .bgg-collection-table thead,
    .bgg-collection-table tbody,
    .bgg-collection-table th,
    .bgg-collection-table td,
    .bgg-collection-table tr {
        display: block;
    }
    
    .bgg-collection-table thead {
        position: absolute;
        left: -9999px;
        top: -9999px;
    }
    
    .bgg-collection-table tbody tr {
        display: flex;
        flex-wrap: wrap;
        padding: 15px;
        border: 1px solid #eaeaea;
        margin-bottom: 15px;
        background-color: #fff;
        border-radius: 4px;
        box-shadow: 0px 5px 30px 0 rgba(0, 0, 0, 0.1);
    }
    
    .bgg-collection-table tbody tr:hover {
        background-color: #fff;
    }
    
    .bgg-collection-table td {
        border: none;
        padding: 5px 0;
        position: relative;
        width: 100%;
        text-align: left;
        white-space: normal;
    }
    
    .bgg-collection-table td[data-label]::before {
        content: attr(data-label);
        display: block;
        font-weight: 500;
        color: #4d4d4d;
        font-size: 12px;
        margin-bottom: 3px;
        text-transform: uppercase;
        letter-spacing: 0.5px;
    }
    
    .bgg-collection-table td:first-child {
        width: auto;
        margin-right: 15px;
        margin-bottom: 10px;
    }
    
    .bgg-collection-table td:first-child::before {
        display: none;
    }
    
    .bgg-collection-table td:nth-child(2) {
        flex: 1;
        min-width: 150px;
        margin-bottom: 10px;
    }
    
    .bgg-collection-table td:nth-child(2)::before {
        display: none;
    }
    
    .bgg-collection-table td:nth-child(n+3) {
        width: calc(50% - 10px);
        margin-right: 10px;
    }
    
    .bgg-collection-table td:nth-child(odd) {
        margin-right: 0;
    }
    
    .bgg-collection-table img {
        width: 70px;
    }
    
    .no-thumbnail {
        width: 70px;
        height: 70px;
    }
    
    .bgg-pagination-controls {
        flex-direction: column;
        gap: 10px;
    }
    
    .bgg-pagination-numbers {
        order: 2;
    }
    
    .bgg-pagination-prev {
        order: 1;
    }
    
    .bgg-pagination-next {
        order: 3;
    }
}

@media print {
    .bgg-search-container {
        display: none;
    }
    
    .bgg-pagination-controls {
        display: none;
    }
    
    .bgg-pagination-info {
        display: none;
    }
    
    .bgg-collection-wrapper {
        overflow: visible;
    }
    
    .bgg-collection-table {
        box-shadow: none;
        border: 1px solid #000;
    }
    
    .bgg-collection-table th,
    .bgg-collection-table td {
        border: 1px solid #000;
    }
    
    .bgg-collection-table a {
        color: #000;
        text-decoration: none;
    }
}
