/* Printer Compatibility Search - Styles */

.pcs-wrapper {
	width: 100%;
    /*margin: 20px auto 30px;*/
    font-family: inherit;
}

/* Search Box */
.pcs-search-box {
    position: relative;
}

.pcs-input-wrap {
    display: flex;
    border: 2px solid #e74c3c;
    border-radius: 6px;
    overflow: visible;
    background: #fff;
    box-shadow: 0 2px 12px rgba(0,0,0,0.08);
}

.pcs-input {
    flex: 1;
    border: none;
    outline: none;
    padding: 14px 18px;
    font-size: 15px;
    background: transparent;
    color: #333;
}

.pcs-input::placeholder {
    color: #aaa;
}

.pcs-btn {
    background: #e74c3c;
    color: #fff;
    border: none;
    padding: 14px 28px;
    font-size: 14px;
    font-weight: 700;
    letter-spacing: 1px;
    cursor: pointer;
    transition: background 0.2s;
    border-radius: 0 4px 4px 0;
}

.pcs-btn:hover {
    background: #c0392b;
}

/* Autocomplete Dropdown */
.pcs-autocomplete {
    display: none;
    position: absolute;
    top: calc(100% + 2px);
    left: 0;
    right: 0;
    background: #fff;
    border: 1px solid #ddd;
    border-radius: 0 0 6px 6px;
    box-shadow: 0 6px 20px rgba(0,0,0,0.12);
    z-index: 9999;
    max-height: 320px;
    overflow-y: auto;
}

/* Hide if empty */
.pcs-autocomplete:empty {
    display: none !important;
}

.pcs-autocomplete-item {
    padding: 10px 18px;
    cursor: pointer;
    border-bottom: 1px solid #f5f5f5;
    transition: background 0.15s;
}

.pcs-autocomplete-item:hover,
.pcs-autocomplete-item.active {
    background: #fff5f5;
}

.pcs-autocomplete-item .pcs-item-name {
    font-weight: 600;
    color: #333;
    font-size: 14px;
}

.pcs-autocomplete-item .pcs-item-breadcrumb {
    font-size: 12px;
    color: #888;
    margin-top: 2px;
}

.pcs-autocomplete-item .pcs-item-count {
    font-size: 11px;
    color: #e74c3c;
    float: right;
    margin-top: 2px;
}

/* Breadcrumb */
.pcs-breadcrumb {
    margin-top: 12px;
    font-size: 13px;
    color: #666;
    padding: 8px 14px;
    background: #f9f9f9;
    border-left: 3px solid #e74c3c;
    border-radius: 0 4px 4px 0;
}

.pcs-breadcrumb span {
    color: #e74c3c;
    font-weight: 600;
}

/* Results Area */
.pcs-results {
    margin-top: 20px;
}

.pcs-results-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 16px;
    padding-bottom: 10px;
    border-bottom: 2px solid #f0f0f0;
}

#pcs-results-title {
    font-size: 16px;
    font-weight: 700;
    color: #333;
}

#pcs-results-count {
    font-size: 13px;
    color: #888;
    background: #f0f0f0;
    padding: 3px 10px;
    border-radius: 20px;
}

/* Products Grid */
.pcs-products-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
    gap: 16px;
}

.pcs-product-card {
    background: #fff;
    border: 1px solid #eee;
    border-radius: 8px;
    overflow: hidden;
    transition: box-shadow 0.2s, transform 0.2s;
    text-decoration: none;
    color: inherit;
    display: block;
}

.pcs-product-card:hover {
    box-shadow: 0 4px 20px rgba(0,0,0,0.1);
    transform: translateY(-2px);
    text-decoration: none;
    color: inherit;
}

.pcs-product-image {
    width: 100%;
    aspect-ratio: 1;
    object-fit: contain;
    padding: 12px;
    background: #fafafa;
    border-bottom: 1px solid #f0f0f0;
}

.pcs-product-info {
    padding: 10px 12px;
}

.pcs-product-title {
    font-size: 13px;
    font-weight: 600;
    color: #333;
    line-height: 1.4;
    margin-bottom: 4px;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.pcs-product-sku {
    font-size: 11px;
    color: #999;
    margin-bottom: 6px;
}

.pcs-product-price {
    font-size: 14px;
    font-weight: 700;
    color: #e74c3c;
}

.pcs-product-stock {
    font-size: 11px;
    margin-top: 4px;
}

.pcs-in-stock {
    color: #27ae60;
}

.pcs-out-of-stock {
    color: #e74c3c;
}

/* Loading */
.pcs-loading {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 20px;
    color: #888;
    font-size: 14px;
}

.pcs-spinner {
    width: 20px;
    height: 20px;
    border: 3px solid #f0f0f0;
    border-top-color: #e74c3c;
    border-radius: 50%;
    animation: pcs-spin 0.7s linear infinite;
}

@keyframes pcs-spin {
    to { transform: rotate(360deg); }
}

/* No Results */
.pcs-no-results {
    text-align: center;
    padding: 40px 20px;
    color: #888;
    font-size: 15px;
}

.pcs-no-results p {
    margin: 0;
}

/* Responsive */
@media (max-width: 600px) {
    .pcs-products-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    .pcs-btn {
        padding: 14px 16px;
        font-size: 13px;
    }
}
