=== Category Discount for WooCommerce ===
Contributors: marco
Tags: woocommerce, discount, category, sale, pricing
Requires at least: 6.0
Tested up to: 7.0
Requires PHP: 7.4
Stable tag: 1.0.0
License: GPLv2 or later
License URI: https://www.gnu.org/licenses/gpl-2.0.html

Create powerful discount rules per product category: percentage, fixed or price override discounts with scheduling, targeting and more.

== Description ==

Category Discount for WooCommerce lets you create unlimited discount rules targeting one or more product categories. Discounted prices are shown everywhere in your store — shop pages, product pages, cart and checkout — with the original price struck through, just like a native WooCommerce sale.

= Discount rules =

* Unlimited rules with priority ordering
* Target multiple categories per rule, optionally including subcategories
* Three discount types: percentage off, fixed amount off, or a fixed price override
* Exclude specific products, other categories, or products already on sale
* Cap the maximum discount amount per product
* Optional price rounding (e.g. to .99 or to a whole number)

= Scheduling =

* Start and end date/time per rule (site timezone)
* Recurring weekday schedule (e.g. weekends only)
* Daily time window ("happy hour" discounts)
* Rules activate and deactivate automatically at runtime — no cron required

= Targeting and conditions =

* Limit rules to specific user roles, logged-in users, or guests
* Cart conditions: minimum cart subtotal or minimum quantity of category items (applied as a cart discount)
* Stacking modes: best discount only, first match by priority, or combine all matching rules

= Frontend display =

* Sale badges on discounted products with customizable text (supports {percent} and {amount} placeholders)
* Promo message on product pages with optional countdown timer for scheduled rules
* [cdwc_discounted_products] shortcode to list currently discounted products

= Admin experience =

* Rules manager under WooCommerce → Category Discounts
* Quick-discount field directly on the category edit screen
* Live discount preview while editing a rule
* Import and export all rules as JSON
* Optional clean uninstall

== Installation ==

1. Upload the plugin folder to `/wp-content/plugins/` or install via the Plugins screen.
2. Activate the plugin. WooCommerce must be installed and active.
3. Go to WooCommerce → Category Discounts to create your first rule.

== Frequently Asked Questions ==

= Do discounts apply to variable products? =

Yes. Variation price ranges are recalculated and cached correctly.

= Do the discounts require coupon codes? =

No. Prices are adjusted directly, so customers see the discounted price everywhere without entering a coupon.

= Can I combine multiple rules? =

Yes. Choose between "best discount only", "first match by priority" or "combine all matching rules" in the settings.

== Changelog ==

= 1.0.0 =
* Initial release.
