/* Pokemon Card Search Form Styles */
.pokemon-search-form {
    background: #f9f9f9;
    padding: 20px;
    border-radius: 8px;
    margin-bottom: 20px;
    border: 1px solid #e0e0e0;
}

.search-input-group {
    margin-bottom: 15px;
}

.search-input {
    width: 100%;
    padding: 12px;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 16px;
    box-sizing: border-box;
}

.search-type-group {
    margin-bottom: 15px;
    display: flex;
    gap: 20px;
    flex-wrap: wrap;
}

.search-type-group label {
    display: flex;
    align-items: center;
    gap: 5px;
    cursor: pointer;
    font-weight: 500;
}

.search-filters {
    display: flex;
    gap: 10px;
    margin-bottom: 15px;
    flex-wrap: wrap;
}

.search-select {
    padding: 8px 12px;
    border: 1px solid #ddd;
    border-radius: 4px;
    background: white;
    min-width: 150px;
    font-size: 14px;
}

.search-button {
    background: #0073aa;
    color: white;
    border: none;
    padding: 12px 24px;
    border-radius: 4px;
    cursor: pointer;
    font-size: 16px;
    font-weight: 500;
    transition: background-color 0.2s;
}

.search-button:hover {
    background: #005a87;
}

.search-notification {
    color: #b00;
    margin: 1em 0;
    padding: 10px;
    background: #ffe6e6;
    border-radius: 4px;
}

.set-logo {
    text-align: center;
}

.set-logo img {
    max-height: 200px!important;
    display: inline-block;
    border-radius: 8px;
}

.set-logo-info-row {
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 50px 0 70px 0;
    gap: 32px;
}

.set-logo-info-row .set-logo {
    width: 25vw;
    height: 25vh;
}

.total-results {
    text-align: center;
    font-size: 14px;
    font-weight: 600;
    color: #333;
    margin: 20px 0;
    padding: 10px;
    background: #f5f5f5;
    border-radius: 6px;
    border-left: 4px solid #0073aa;
}

.results-count {
    color: #0073aa;
    font-weight: 700;
    font-size: 14px;
}

.set-info-box {
    background: #f9f9f9;
    padding: 18px 28px;
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.07);
    min-width: 280px;
    max-width: 400px;
}

.set-info-box h4 {
    margin-top: 0;
    margin-bottom: 12px;
    color: #333;
    font-size: 16px;
    font-weight: 600;
}

.set-info-box div {
    margin-bottom: 8px;
    line-height: 1.4;
}

.set-info-box strong {
    color: #2c2c2c;
    font-weight: 600;
    display: inline-block;
}

.price-value {
    color: green;
    transition: all 0.3s ease;
}

.price-value.loading {
    color: #ffc107;
    font-style: italic;
}

.price-value.updated {
    color: #007bff;
    animation: priceUpdate 0.5s ease-in-out;
}

@keyframes priceUpdate {
    0% { transform: scale(1); }
    50% { transform: scale(1.1); }
    100% { transform: scale(1); }
}

/* Card Details Modal Styles */
.card-modal {
    display: none;
    position: fixed;
    z-index: 10000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.7);
    overflow-y: auto;
}

.card-modal-content {
    background-color: #fff;
    margin: 2% auto;
    padding: 20px;
    border-radius: 8px;
    width: 90%;
    max-width: 800px;
    max-height: 90vh;
    overflow-y: auto;
    position: relative;
}

.card-modal-close {
    color: #aaa;
    float: right;
    font-size: 28px;
    font-weight: bold;
    cursor: pointer;
    position: absolute;
    top: 10px;
    right: 15px;
}

.card-modal-close:hover,
.card-modal-close:focus {
    color: #000;
    text-decoration: none;
}

.card-details-content {
    margin-top: 20px;
}

.database-card-details {
    font-family: Arial, sans-serif;
}

.card-details-header {
    border-bottom: 2px solid #0073aa;
    padding-bottom: 15px;
    margin-bottom: 20px;
}

.card-details-header h2 {
    margin: 0 0 5px 0;
    color: #0073aa;
}

.card-id {
    color: #666;
    font-size: 14px;
}

.card-details-content {
    display: flex;
    gap: 30px;
    flex-wrap: wrap;
}

.card-image-section {
    flex: 0 0 300px;
}

.card-large-image,
.card-small-image {
    max-width: 100%;
    height: auto;
    border-radius: 8px;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
}

.card-info-section {
    flex: 1;
    min-width: 300px;
}

.card-basic-info,
.card-set-info,
.card-attacks,
.card-weaknesses,
.card-resistances,
.card-flavor-text,
.card-rules {
    margin-bottom: 25px;
}

.card-basic-info h3,
.card-set-info h3,
.card-attacks h3,
.card-weaknesses h3,
.card-resistances h3,
.card-flavor-text h3,
.card-rules h3 {
    color: #0073aa;
    border-bottom: 1px solid #ddd;
    padding-bottom: 5px;
    margin-bottom: 15px;
}

.card-info-table {
    width: 100%;
    border-collapse: collapse;
}

.card-info-table td {
    padding: 8px 0;
    border-bottom: 1px solid #f0f0f0;
}

.card-info-table td:first-child {
    font-weight: bold;
    width: 40%;
    color: #333;
}

.attack-item,
.weakness-item,
.resistance-item {
    background: #f9f9f9;
    padding: 10px;
    margin-bottom: 10px;
    border-radius: 4px;
    border-left: 3px solid #0073aa;
}

.attack-cost,
.attack-damage {
    display: inline-block;
    margin-left: 15px;
    color: #666;
    font-size: 14px;
}

.attack-text {
    margin-top: 8px;
    color: #333;
    font-style: italic;
}

.card-prices-section {
    margin-top: 30px;
    border-top: 2px solid #0073aa;
    padding-top: 20px;
}

.card-prices-section h3 {
    color: #0073aa;
    margin-bottom: 15px;
}

.price-update-info {
    margin-bottom: 20px;
    color: #666;
    font-style: italic;
}

.cardmarket-prices,
.tcgplayer-prices {
    margin-bottom: 20px;
}

.cardmarket-prices h4,
.tcgplayer-prices h4 {
    color: #333;
    margin-bottom: 10px;
}

.price-table {
    width: 100%;
    border-collapse: collapse;
    background: #f9f9f9;
    border-radius: 4px;
    overflow: hidden;
}

.price-table td {
    padding: 10px;
    border-bottom: 1px solid #ddd;
}

.price-table td:first-child {
    font-weight: bold;
    background: #e9e9e9;
}

.loading {
    text-align: center;
    padding: 40px;
    color: #666;
    font-style: italic;
}

.error {
    text-align: center;
    padding: 40px;
    color: #d32f2f;
    background: #ffebee;
    border-radius: 4px;
}

/* Responsive Design */
@media (max-width: 768px) {
    .card-modal-content {
        width: 95%;
        margin: 5% auto;
        padding: 15px;
    }
    
    .card-details-content {
        flex-direction: column;
        gap: 20px;
    }
    
    .card-image-section {
        flex: none;
        text-align: center;
    }
    
    .card-info-section {
        min-width: auto;
    }
}

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

/* Card Grid Styles */
.pokemon-card-grid {
    display: flex;
    flex-wrap: wrap;
    gap: 1.5em;
    margin: 1em 0;
}

.pokemon-card-grid-item {
    background: #fff;
    border: 1px solid #eee;
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
    width: 180px;
    padding: 1em;
    text-align: left;
    transition: box-shadow 0.2s;
    text-decoration: none;
}

.pokemon-card-grid-item:hover {
    box-shadow: 0 4px 16px rgba(0,0,0,0.15);
    text-decoration: none;
}

.pokemon-card-grid-item img {
    max-width: 100%;
    height: auto;
    border-radius: 4px;
    margin-bottom: 0.5em;
    display: block;
}

.pokemon-card-grid-item .cardname {
    font-weight: bold;
    font-size: 14px;
    margin-bottom: 0.3em;
    display: block;
    color: #000;
}

.pokemon-card-grid-item .cardnumber {
    font-size: 14px;
    color: #000;
}

.pokemon-card-grid-item .marketprice {
    color: #0073aa;
    font-size: 14px;
    margin-top: 0.2em;
}

.pokemon-card-grid-item .label {
    color: #000;
    font-size: 14px;
    font-weight: 600;
    margin-right: 0.2em;
}

/* Card Image Link Styles */
.card-image-link {
    display: block;
    text-decoration: none;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.card-image-link:hover {
    transform: scale(1.05);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.card-image-link img {
    width: 100%;
    height: auto;
    border-radius: 8px;
    display: block;
}

/* Remove old show-product-link styles */
.show-product-link {
    display: none;
}

.pokemon-card-grid-item .show-product-link a {
    color: #2174c7;
    text-decoration: none;
    font-size: 15px;
}

.pokemon-card-grid-item .show-product-link a:hover {
    text-decoration: underline;
}

.add-to-cart-group {
    margin-top: 0.5em;
    display: flex;
    align-items: center;
    gap: 0.5em;
    justify-content: flex-end;
}

.add-to-cart-qty {
    width: 50px;
    padding: 0.2em 0.4em;
    font-size: 14px;
    border: 1px solid #ddd;
    border-radius: 3px;
    text-align: center;
}

.add-to-cart-btn {
    background: #2174c7;
    color: #fff;
    border: none;
    padding: 0.5em;
    border-radius: 4px;
    cursor: pointer;
    min-width: 40px;
    height: 40px;
    font-size: 16px;
    transition: background-color 0.2s;
    display: flex;
    align-items: center;
    justify-content: center;
}

.add-to-cart-btn:hover {
    background: #1a5a9e;
}

/* Collection Button Styles - Matching Add to Cart */
.add-to-collection-group {
    margin-top: 8px;
    display: flex;
    flex-direction: column;
    gap: 8px;
    align-items: flex-end;
}

.add-to-collection-btn {
    background: #2174c7;
    color: #fff;
    border: none;
    padding: 0.5em;
    border-radius: 4px;
    cursor: pointer;
    min-width: 40px;
    height: 40px;
    font-size: 16px;
    transition: background-color 0.2s;
    display: flex;
    align-items: center;
    justify-content: center;
}

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

.add-to-collection-btn.in-collection {
    background: #6c757d;
}

.add-to-collection-btn.in-collection:hover {
    background: #5a6268;
}

.add-to-collection-btn:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

.loading-spinner {
    font-size: 12px;
    font-style: italic;
}

/* Collection Quantity Controls */
.collection-quantity-controls {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    margin-top: 4px;
}

.quantity-btn {
    background: #6c757d;
    color: white;
    border: none;
    width: 24px;
    height: 24px;
    border-radius: 50%;
    cursor: pointer;
    font-size: 12px;
    font-weight: bold;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background-color 0.2s;
}

.quantity-btn:hover {
    background: #5a6268;
}

.quantity-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.quantity-display {
    font-size: 14px;
    font-weight: 500;
    min-width: 20px;
    text-align: center;
}

/* Notifications */
.poke-notification {
    position: fixed;
    top: 20px;
    right: 20px;
    padding: 12px 20px;
    border-radius: 6px;
    color: white;
    font-weight: 500;
    z-index: 9999;
    opacity: 0;
    transition: opacity 0.3s ease;
    max-width: 300px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
}

.poke-notification.success {
    background: #28a745;
}

.poke-notification.error {
    background: #dc3545;
}

/* Responsive Design */
@media (max-width: 768px) {
    .search-filters {
        flex-direction: column;
    }
    
    .search-select {
        min-width: 100%;
    }
    
    .search-type-group {
        flex-direction: column;
        gap: 10px;
    }
    
    .pokemon-card-grid {
        gap: 1em;
    }
    
    .pokemon-card-grid-item {
        width: calc(50% - 0.5em);
    }
}

@media (max-width: 480px) {
    .pokemon-card-grid-item {
        width: 100%;
    }
    
    .add-to-cart-group {
        flex-direction: column;
        align-items: stretch;
        justify-content: flex-end;
    }
    
    .add-to-cart-qty {
        width: 100%;
    }
    
    .add-to-cart-btn {
        width: 100%;
        height: 40px;
    }
    
    .add-to-collection-group {
        margin-top: 6px;
    }
    
    .add-to-collection-btn {
        width: 100%;
        height: 40px;
        justify-content: center;
    }
    
    .collection-quantity-controls {
        justify-content: center;
    }
}

/* Pokemon Card Info Styles */
.pokemon-card-info {
    margin-top: 2em;
    padding: 1em;
}

.pokemon-card-info h2 {
    margin-top: 0;
}

.pokemon-card-info table.woocommerce-table.shop_attributes {
    word-break: break-word;
    white-space: normal;
    text-align: left;
    min-width: 350px !important;
}

.pokemon-card-info table.woocommerce-table.shop_attributes th {
    font-weight: bold;
    text-align: left!important;
}

.pokemon-card-info table.woocommerce-table.shop_attributes td {
    text-align: left;
}

.pokemon-card-info table.woocommerce-table.shop_attributes tr {
    border-bottom: 1px solid #eee;
}

.pokemon-card-info table[style*="min-width: 350px"] {
    min-width: 350px !important;
}

.tcg-label, .cardmarket-label {
    max-width: 20px;
    margin-bottom: 0.5em !important;
}

.tcg-value, .cardmarket-value {
    text-align: left !important;
    margin-bottom: 0.5em !important;
}

.tcg-label {
    padding-right: 1em;
    text-align: left;
}

.tcg-value {
    text-align: left;
    margin-bottom: 1.5em !important;
}

.pokemon-card-info table.woocommerce-table.shop_attributes th,
.pokemon-card-info table.tcgplayer-prices-table th,
.pokemon-card-info table.cardmarket-prices-table th {
    text-align: left !important;
    font-weight: bold;
    min-width: fit-content !important;
}

.pokemon-card-info table.woocommerce-table.shop_attributes td {
    text-align: left;
}

.woocommerce-product-title, .product_title.entry-title {
    margin: 0 0 5em 0 !important;
}

.tcgplayer-prices-table {
    margin-bottom: 0.5em !important;
}

.tcgplayer-prices-table, .cardmarket-prices-table {
    min-width: 350px !important;
    margin-bottom: 0.5em !important;
    background: none !important;
    border: none !important;
}

.tcgplayer-prices-table tr, .cardmarket-prices-table tr {
    border: none !important;
    background: none !important;
}

.tcgplayer-prices-table td, .cardmarket-prices-table td {
    border: none !important;
    background: none !important;
}

.woocommerce div, .product div, .summary {
    text-align: left !important;
} 

/* Show More Link Styles */
.show-more-wrapper {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    margin: 30px 0;
    text-align: center;
}

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

.show-more-link {
    display: inline-block;
    color: #007cba;
    text-decoration: none;
    font-size: 16px;
    font-weight: 600;
    padding: 8px 16px;
    border-radius: 4px;
    transition: all 0.2s ease;
    cursor: pointer;
}

.show-more-link:active {
    transform: translateY(1px);
}

/* Loading state */
.show-more-link[style*="pointer-events: none"] {
    color: #999;
    cursor: not-allowed;
}

/* Responsive show more link */
@media (max-width: 768px) {
    .show-more-link {
        font-size: 14px;
        padding: 6px 12px;
    }
} 

/* Search Options (Sorting and Pagination) */
.search-options {
    margin: 20px 0;
    padding: 15px;
    background: #f8f9fa;
    border: 1px solid #dee2e6;
    border-radius: 6px;
    display: flex;
    gap: 20px;
    align-items: center;
    flex-wrap: wrap;
}

.sorting-option,
.pagination-option {
    display: flex;
    align-items: center;
    gap: 8px;
}

.sorting-option label,
.pagination-option label {
    font-weight: 600;
    color: #495057;
    margin: 0;
    white-space: nowrap;
}

.sorting-option .search-select,
.pagination-option .search-select {
    min-width: 150px;
    padding: 6px 10px;
    border: 1px solid #ced4da;
    border-radius: 4px;
    background: white;
    font-size: 14px;
}

.sorting-option .search-select:focus,
.pagination-option .search-select:focus {
    outline: none;
    border-color: #007cba;
    box-shadow: 0 0 0 2px rgba(0, 124, 186, 0.2);
}

/* Responsive design for search options */
@media (max-width: 768px) {
    .search-options {
        flex-direction: column;
        align-items: stretch;
        gap: 15px;
    }
    
    .sorting-option,
    .pagination-option {
        justify-content: space-between;
    }
    
    .sorting-option .search-select,
    .pagination-option .search-select {
        min-width: 120px;
    }
} 

.woocommerce div.product div.images img{
    max-width: 420px!important;
}

.woocommerce-product-title, .product_title.entry-title{
    margin: 0 0 3em 0!important;
}

.woocommerce-product-gallery, .set-logo{
    text-align: center!important;
}

.tcg-label, .cardmarket-label{
    max-width: 70px!important;
}

.woocommerce table.shop_attributes th{
    width: 190px!important;
}

/* Shop Price Styles */
.shop-price {
    font-size: 14px;
    color: #28a745;
    font-weight: 600;
    margin: 8px 0;
    text-align: center;
}

/* Responsive shop price */
@media (max-width: 768px) {
    .shop-price {
        font-size: 13px;
        margin: 6px 0;
    }
}

/* --- Responsive Set Logo & Info --- */
@media (max-width: 768px) {
    .set-logo-info-row {
        flex-direction: column;
        gap: 16px;
        margin: 24px 0 32px 0;
        align-items: center;
    }
    .set-logo img {
        max-width: 90vw;
        max-height: 120px!important;
        height: auto;
        min-width: 90vw!important;
        min-height: 19vh!important;
    }
    .set-info-box {
        min-width: 0;
        max-width: 95vw;
        padding: 12px 8px;
        font-size: 15px;
    }
}

/* --- Responsive Product Info Table --- */
@media (max-width: 768px) {
    .pokemon-card-info table.woocommerce-table.shop_attributes {
        display: block;
        width: 100%;
        overflow-x: auto;
        min-width: 0!important;
        font-size: 15px;
        border-spacing: 0;
        border-collapse: collapse;
        background: #fff;
    }
    .pokemon-card-info table.woocommerce-table.shop_attributes th,
    .pokemon-card-info table.woocommerce-table.shop_attributes td {
        white-space: normal;
        word-break: break-word;
        min-width: 90px!important;
        padding: 8px 6px;
        font-size: 15px;
    }
}

/* --- Extra kleine schermen --- */
@media (max-width: 480px) {
    .set-logo img {
        max-width: 98vw;
        max-height: 80px!important;
    }
    .set-info-box {
        font-size: 14px;
        padding: 8px 2px;
    }
    .pokemon-card-info table.woocommerce-table.shop_attributes th,
    .pokemon-card-info table.woocommerce-table.shop_attributes td {
        font-size: 14px;
        padding: 6px 4px;
    }
}