.search-container {
    margin-bottom: 2rem;
    display: flex;
    justify-content: center;
}

.search-form {
    display: flex;
    width: 100%;
    max-width: 500px;
    position: relative;
}

.search-input {
    width: 100%;
    padding: 0.75rem 1rem 0.75rem 3rem;
    border-radius: 50px;
    border: 1px solid var(--border);
    background: rgba(10, 10, 10, 0.4);
    color: var(--text);
    font-size: 1rem;
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    transition: border-color 0.3s, box-shadow 0.3s;
}

html[dir="rtl"] .search-input {
    padding: 0.75rem 3rem 0.75rem 1rem;
}

.search-input:focus {
    outline: none;
    border-color: var(--red-bright);
    box-shadow: 0 0 0 2px rgba(229, 9, 20, 0.2);
}

.search-button {
    position: absolute;
    left: 5px;
    top: 50%;
    transform: translateY(-50%);
    background: transparent;
    border: none;
    color: var(--text-sub);
    cursor: pointer;
    padding: 0.5rem;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: color 0.3s;
}

html[dir="rtl"] .search-button {
    left: auto;
    right: 5px;
}

.search-button:hover {
    color: var(--red-bright);
}

.search-button svg {
    width: 20px;
    height: 20px;
    fill: currentColor;
}

.products-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 1.5rem;
}

.product-card {
    display: flex;
    flex-direction: column;
    overflow: hidden;
    transition: transform 0.3s, box-shadow 0.3s;
}

.product-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.3);
}

.product-image-container {
    position: relative;
    width: 100%;
    padding-top: 100%; /* 1:1 Aspect Ratio */
    background: rgba(0, 0, 0, 0.2);
    overflow: hidden;
}

.product-image {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease;
}

.product-card:hover .product-image {
    transform: scale(1.05);
}

.product-placeholder-icon {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 48px;
    height: 48px;
    fill: rgba(255, 255, 255, 0.1);
}

.product-details {
    padding: 1.25rem;
    display: flex;
    flex-direction: column;
    flex-grow: 1;
}

.product-title {
    font-size: 1.2rem;
    font-weight: 600;
    margin: 0 0 0.5rem 0;
    color: var(--text);
}

.product-price {
    font-size: 1.25rem;
    color: var(--red-bright);
    font-weight: 700;
    margin-bottom: 1rem;
}

.product-price-currency {
    font-size: 0.9rem;
    margin-inline-start: 0.15rem;
}

.product-description {
    font-size: 0.9rem;
    color: var(--text-sub);
    margin-bottom: 1.5rem;
    flex-grow: 1;
    /* line-clamp */
    display: -webkit-box;
    -webkit-line-clamp: 2;
    line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.product-actions {
    margin-top: auto;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.view-product-button {
    width: 100%;
    text-align: center;
    justify-content: center;
}

/* Page specific helper classes */
.no-products-panel {
    grid-column: 1 / -1;
    text-align: center;
    padding: 3rem;
}
