Setup & guides · Developer reference
Customize
widget styling.
How to style the SweepSpot storefront widgets with your theme’s CSS: which method to use for each widget, the selectors and variables the widgets expose, and the checks to run before publishing.
Selectors verified against the current widget source on November 4, 2026. Apply only the examples you need and replace the sample palette with your brand colors. Back to Setup & guides.
Choose the correct customization method
| Widget | Where to customize | Theme CSS |
|---|---|---|
| Cart total entries | Theme app block settings, then theme stylesheet | Yes |
| Cart drawer entries | Theme app embed settings, then theme stylesheet | Yes |
| Product entries badge | Theme app block settings, then theme stylesheet | Yes |
| Product entries bars | App embed settings, then theme stylesheet; availability limited, see below | Yes, when rendered |
| Check entries by email | Theme app block settings, then theme stylesheet | Yes |
| Free-entry / AMOE form | App appearance settings, theme app block settings, then theme stylesheet | Yes |
| Thank You Sweepstakes Entries | App → Extensions and Shopify Checkout and Accounts branding | No arbitrary CSS |
| Customer account Sweepstakes Entries (Orders and Profile) | App → Extensions and Shopify Checkout and Accounts branding | No arbitrary CSS |
The referral-attribution embed handles attribution and has no visible widget to style.
1. Add and organize your CSS
- Work in a duplicate theme and preview it before publishing.
- Use the widget’s built-in appearance controls first. They cover common color, spacing, alignment, size and corner changes.
- Put additional rules in a theme-owned stylesheet loaded on every page where the widget appears. A dedicated asset such as
sweepspot-custom.csskeeps the changes easy to find. Load it through the theme’s normal stylesheet mechanism, preferably after its other stylesheets. - Keep selectors scoped to the widget. A rule targeting every
button,inputorstrongcan change unrelated parts of the store. - Preview the rendered storefront as well as the theme editor. Some editor states differ from customer states.
Do not edit the extension’s delivered CSS assets in a merchant theme as your customization strategy: future extension releases can replace them.
Inline variables and specificity
Many widget settings become CSS custom properties on the element’s inline style attribute. For example, --sweepspot-entry-size sets the total’s font size. A normal stylesheet declaration of that same variable on the same container does not override the inline value.
Use the editor setting, override the final property on the element that displays it, or set the variable on a descendant that consumes it. Use a narrowly scoped !important variable override only when you deliberately want to supersede the editor setting.
/* Direct property override: works despite an inline size variable. */
.sweepspot-cart-entries.sweepspot-entry-block [data-entry-total] {
font-size: clamp(2rem, 6vw, 3.5rem);
}
/* Deliberately force one editor-backed variable for all email-check blocks. */
sweepspot-entry-check.sweepspot-entry-check {
--ec-radius: 12px !important;
}The repeated widget classes in some examples provide enough specificity to beat the extension’s base rules. Load order still matters when selectors have equal specificity. In browser developer tools, inspect the element’s computed style to find the declaration that wins.
2. Cart total entries
Root: .sweepspot-cart-entries. The drawer uses the same class; exclude its attribute when styling only the cart-page block.
| Selector | Purpose |
|---|---|
.sweepspot-giveaway-name | Giveaway heading |
.sweepspot-entry-total | Total and unit wrapper |
[data-entry-total] | Calculated number |
.sweepspot-entry-unit | Entries label |
.sweepspot-cart-discount | Applied discount confirmation |
.sweepspot-entry-breakdown | Breakdown, when that layout renders it |
.sweepspot-entry-status | Loading, unavailable and explanatory text |
[data-sweepspot-entry-root] | One giveaway’s content |
.sweepspot-cart-entries.sweepspot-entry-block:not([data-sweepspot-drawer-widget]) {
background: #f5f7fa;
color: #172033;
border: 1px solid #c7ced8;
border-radius: 12px;
padding: 20px;
text-align: start;
}
.sweepspot-cart-entries.sweepspot-entry-block .sweepspot-entry-total {
justify-content: flex-start;
}
.sweepspot-cart-entries.sweepspot-entry-block .sweepspot-cart-discount {
background: #173e2c;
color: #ffffff;
border-radius: 6px;
}The second and third rules above affect both cart and drawer totals. Add :not([data-sweepspot-drawer-widget]) to their root selector if they should affect only the cart page.
The runtime can move the cart widget above checkout and restore it after section replacement. Style the widget itself rather than relying on its original app-block parent. Its width follows the checkout area where supported, with a 24px checkout gap. Avoid absolute positioning or a fixed width wider than the available checkout area.
3. Cart drawer entries
Root: .sweepspot-cart-entries[data-sweepspot-drawer-widget]. Enable Cart drawer entries in App embeds. Drawer integration depends on the theme’s markup; CSS cannot supply a missing drawer adapter.
.sweepspot-cart-entries[data-sweepspot-drawer-widget] {
background: #ffffff;
color: #172033;
border: 1px solid #c7ced8;
padding: 12px;
border-radius: 8px;
}
.sweepspot-cart-entries[data-sweepspot-drawer-widget] [data-entry-total] {
font-size: clamp(2rem, 8vw, 2.75rem);
}
.sweepspot-cart-entries[data-sweepspot-drawer-widget] .sweepspot-entry-total {
justify-content: center;
}Keep these rules in a persistent theme stylesheet. The drawer footer and widget may be replaced when quantities change; modifying a live element’s inline style manually will not survive replacement.
4. Product entries badge
Root: .sweepspot-product-entries. The visible surface is .sweepspot-product-summary; changing only the root background or padding may not produce the intended result.
.sweepspot-product-entries.sweepspot-entry-block .sweepspot-product-summary {
background: #f5f7fa;
color: #172033;
border: 1px solid #c7ced8;
border-radius: 10px;
padding: 10px 14px;
gap: 10px;
}
.sweepspot-product-entries.sweepspot-entry-block [data-entry-total] {
font-size: 1.75rem;
font-weight: 700;
}
.sweepspot-product-entries.sweepspot-entry-block .sweepspot-multiplier-badge {
background: #172033;
color: #ffffff;
border-radius: 6px;
}The number, entries unit and multiplier are independently styleable. Use the editor controls to show or hide entries and multiplier segments. Keep the accessible giveaway group label and multiplier wording.
When the Product entries bars configuration element exists, additional CSS changes manually placed product badges into connected segments. Those rules start with body:has([data-sweepspot-product-badges]) and have higher specificity. If that mode is active, use the same prefix plus your widget selectors to override it:
body:has([data-sweepspot-product-badges])
.sweepspot-product-entries .sweepspot-product-summary {
border-radius: 10px;
}5. Product entries bars
Availability: product entries bars currently render only on stores where the feature has been enabled. These examples apply where it renders; CSS cannot enable it on another shop.
The hidden [data-sweepspot-product-badges] element is configuration, not the visible bar. Target the generated elements:
| Selector | Purpose |
|---|---|
.sweepspot-product-bars | Stack of bars |
.sweepspot-product-bar | One giveaway’s bar |
.sweepspot-product-bar__entries | Entries segment |
.sweepspot-product-bar__multiplier | Multiplier segment |
.sweepspot-product-bar[data-shape="pill"] | Pill variant |
.sweepspot-product-bars .sweepspot-product-bar {
font-size: 14px;
border: 1px solid #c7ced8;
}
.sweepspot-product-bars .sweepspot-product-bar__entries {
background: #f5f7fa;
color: #172033;
padding: 6px 10px;
}
.sweepspot-product-bars .sweepspot-product-bar__multiplier {
background: #172033;
color: #ffffff;
padding: 6px 10px;
}Use settings for placement, bar or pill shape and full width. The runtime writes --ss-entries-bg, --ss-entries-color, --ss-multiplier-bg, --ss-multiplier-color, --ss-font-size and --ss-padding on each generated stack. Direct segment properties override their visual effects without fighting those inline variables. Preserve pointer-events: none so product-card links remain usable.
6. Check entries by email
Root: sweepspot-entry-check.sweepspot-entry-check. This custom element uses theme-accessible markup. It includes email entry, verification, results, history and status states.
sweepspot-entry-check.sweepspot-entry-check {
max-width: 42rem;
padding: 24px;
background: #ffffff;
color: #172033;
border: 1px solid #c7ced8;
border-radius: 12px;
}
.sweepspot-entry-check .sweepspot-entry-check__heading {
font-size: clamp(1.5rem, 4vw, 2rem);
}
.sweepspot-entry-check input {
background: #ffffff;
border-color: #667085;
border-radius: 6px;
}
.sweepspot-entry-check button[type="submit"] {
background: #172033;
color: #ffffff;
border-color: #172033;
border-radius: 6px;
}
.sweepspot-entry-check .sweepspot-entry-check__total {
font-size: 1.75rem;
}Additional hooks: .sweepspot-entry-check__actions, [data-entry-check-status], [data-entry-check-results] > li and [data-entry-check-more]. Prefer these hooks over generated input IDs.
Editor-backed variables: --ec-background, --ec-text, --ec-border, --ec-button, --ec-button-text, --ec-font-size, --ec-heading-size, --ec-padding, --ec-gap, --ec-radius, --ec-border-width, --ec-width and --ec-alignment.
Retain the disabled appearance and focus outline. Verification and history visibility are controlled by the app; never force hidden controls or results to display.
7. Free-entry / AMOE form
Root: .fif-amoe. The fif prefix is intentional and remains in the current source.
The block offers Use these styles instead of shared app styles. Enable it when you want the block’s local appearance settings to take precedence over shared appearance. The examples below target the visible elements directly; inspect computed styles if shared appearance introduces additional declarations.
.fif-amoe .fif-amoe__form {
background: #f5f7fa;
padding: 24px;
border: 1px solid #c7ced8;
border-radius: 12px;
}
.fif-amoe .fif-amoe__heading {
font-size: clamp(1.75rem, 5vw, 2.5rem);
}
.fif-amoe .fif-amoe__field input {
background: #ffffff;
color: #172033;
border-color: #667085;
border-radius: 6px;
}
.fif-amoe[data-theme-styles] .fif-amoe__submit {
background: #172033;
color: #ffffff;
border: 1px solid #172033;
border-radius: 6px;
padding: 12px 20px;
}
.fif-amoe .amoe-confirmation__codes li {
border-radius: 8px;
padding: 16px;
}Other useful hooks: .fif-amoe__description, .fif-amoe__sweepstakes, .fif-amoe__fields, .fif-amoe__attestation, .fif-amoe__rules, .fif-amoe__status, .amoe-confirmation__code and .amoe-confirmation__mailing.
For entry amount size and color, override the variables on the amount element. The base CSS uses !important on the properties that consume them:
.fif-amoe .fif-amoe__entry-amount {
--fif-amoe-total-size: 2rem;
--fif-amoe-total-color: #172033;
}The form becomes a confirmation after a successful submission, so review both layouts. Preserve the honeypot’s hidden styling, required consent, rules links, error and success distinction, and focus treatment.
8. Thank You and customer account widgets
These use Shopify UI extensions rather than storefront theme HTML. Theme CSS selectors and stylesheets cannot customize them, and there are no merchant CSS selectors for them.
- Open the app’s Extensions page.
- Adjust shared appearance, or choose independent Thank You and customer account overrides.
- Set supported header scale and alignment; body and total size, emphasis and semantic color; background, padding, content spacing, border and corners.
- Choose Cards or Compact independently for each widget.
- Preview and save. Use Use theme default where the widget should inherit Shopify branding.
- Use Shopify’s Checkout and Accounts editor for store-wide typeface and exact brand-color changes.
Thank You shows order entries and can show the running total. Customer account widgets can appear on Orders and Profile and show totals and recent orders. Check both account placements after appearance changes. CSS cannot change entry totals, processing behavior or which data is authorized for the customer.
9. Shared cart and product variable reference
These variables are consumed by the cart, drawer and manually placed product widgets. Editor settings write most of them inline.
| Variable | Controls |
|---|---|
--sweepspot-entry-color | Root text color |
--sweepspot-entry-bg | Cart surface / product summary background |
--sweepspot-entry-accent | Multiplier or discount background |
--sweepspot-entry-badge-text | Text on the accent background |
--sweepspot-entry-padding | Surface or segment padding |
--sweepspot-entry-radius | Surface or badge corners |
--sweepspot-entry-size | Entry total size |
--sweepspot-entry-align | Root text alignment |
--sweepspot-entry-border | Base container border; product summary has its own border |
--sweepspot-checkout-width | Cart width coordinated with checkout placement |
Text alignment alone does not align flex children; change .sweepspot-entry-total’s justify-content when needed.
10. Mobile and accessibility checks
Use flexible sizes and preserve wrapping. For example:
@media (max-width: 40rem) {
sweepspot-entry-check.sweepspot-entry-check {
padding: 16px;
}
.fif-amoe .fif-amoe__form {
padding: 16px;
}
}Before publishing:
- Check narrow mobile widths, desktop and 200% zoom for clipping or horizontal scrolling.
- Tab through email verification and AMOE controls. Keep visible focus and usable buttons; the shipped forms use approximately 44px minimum control heights.
- Check contrast for text, controls and badges. Aim for 4.5:1 for normal text and 3:1 for large text and essential control boundaries.
- Test loading, empty, unavailable, disabled, success and error states where applicable.
- Test multiple giveaways and long giveaway names or entry totals.
- Change product variants and quantity; add and remove cart items and reopen the drawer. Styles should survive the runtime’s updates.
- Preserve
[hidden], screen-reader-only text, live statuses and readable estimate wording. Never use a broaddisplay: block !importantrule on widget descendants.
11. Troubleshooting and rollback
| Symptom | What to check |
|---|---|
| Color or size does not change | Inspect inline variables and winning declarations; override the final property or use editor settings. |
| Product background seems unchanged | Style .sweepspot-product-summary or its connected segments. |
| Cart styles also change the drawer | Add :not([data-sweepspot-drawer-widget]) to cart-only selectors. |
| Drawer styles disappear after an update | Store rules in a persistent theme stylesheet; avoid styling only the old live node. |
| Product bars do not appear | Check the feature’s availability for your store, embed configuration, published rules and supported placement. |
| Widget shows unavailable or no entries | Check setup, eligibility, rules and currency; CSS cannot repair calculation or publication state. |
| Thank You or account ignores theme CSS | Use Extensions appearance controls and Shopify branding. |
| Form controls unexpectedly appear | Remove rules overriding [hidden] or broad display rules. |
To roll back, remove your custom stylesheet rules or its stylesheet include and restore any editor settings you changed. Preview again before publishing.
This is a source-verified customization reference. The sample CSS has not been applied to a live store; confirm the final appearance in your target theme.