PluginProbe
Subscriptions for WooCommerce with Stripe Recurring Payments / 2.0.0
Subscriptions for WooCommerce with Stripe Recurring Payments v2.0.0
2.0.0 1.11.2 1.11.1 1.11.0 1.10.9 1.10.8 1.10.7 1.10.6 1.10.5 1.10.4 1.10.3 1.10.2 1.10.1 1.10.0 1.9.6 1.9.5 trunk 1.3.0 1.3.1 1.3.2 1.4.0 1.4.1 1.4.2 1.5.0 1.5.1 All 61 releases
subscription / assets / css / cancellation.css

cancellation.css in Subscriptions for WooCommerce with Stripe Recurring Payments 2.0.0, at assets/css/cancellation.css

401 lines 9.6 KB
No matching file
Up and down to move Enter to open Esc to close
Raw Download Zip
1 .subscrpt-pending-cancel-notice {
2 display: flex;
3 align-items: flex-start;
4 gap: 12px;
5 margin: 0 0 24px;
6 padding: 14px 16px;
7 border: 1px dashed #fca5a5;
8 border-radius: 10px;
9 background: linear-gradient(180deg, #fffafa 0%, #fef2f2 100%);
10 box-shadow: 0 1px 2px rgba(120, 0, 0, 0.06);
11 color: #3f3f46;
12 font-size: 0.95em;
13 line-height: 1.5;
14 }
15
16 .subscrpt-pending-cancel-notice__icon {
17 display: inline-flex;
18 align-items: center;
19 justify-content: center;
20 flex: 0 0 auto;
21 width: 34px;
22 height: 34px;
23 border-radius: 50%;
24 background: #fee2e2;
25 color: #b91c1c;
26 }
27
28 .subscrpt-pending-cancel-notice__body {
29 flex: 1 1 auto;
30 min-width: 0;
31 }
32
33 .subscrpt-pending-cancel-notice__text {
34 margin: 0;
35 }
36
37 .subscrpt-pending-cancel-notice__text strong {
38 color: #18181b;
39 }
40
41 /* ==========================================================================
42 Cancellation feedback modal
43 All rules are scoped under .subscrpt-feedback-modal and reset the properties
44 themes commonly set (buttons, inputs, box-sizing), so the modal renders
45 consistently across themes without leaking styles out.
46 ========================================================================== */
47 .subscrpt-feedback-modal {
48 /* Theming tokens — override any of these on `.subscrpt-feedback-modal` from a
49 theme to recolor the modal. Brand tokens mirror admin-components (whose
50 stylesheet is not loaded on the frontend). Structural overrides can also
51 target the BEM classes directly (e.g. .subscrpt-feedback-modal__confirm). */
52 --subscrpt-brand: #ff4d00;
53 --subscrpt-brand-dark: #d93f00;
54 --subscrpt-brand-light: #fff1eb;
55 --subscrpt-brand-ring: rgba(255, 77, 0, 0.2);
56 --subscrpt-cfm-on-brand: #ffffff;
57
58 --subscrpt-cfm-surface: #ffffff;
59 --subscrpt-cfm-overlay: rgba(17, 24, 39, 0.6);
60 --subscrpt-cfm-title: #18181b;
61 --subscrpt-cfm-text: #3f3f46;
62 --subscrpt-cfm-muted: #52525b;
63 --subscrpt-cfm-subtle: #a1a1aa;
64 --subscrpt-cfm-border: #e4e4e7;
65 --subscrpt-cfm-border-strong: #d4d4d8;
66 --subscrpt-cfm-hover-bg: #fafafa;
67 --subscrpt-cfm-hover-bg-strong: #f4f4f5;
68
69 position: fixed;
70 inset: 0;
71 z-index: 999999;
72 display: flex;
73 align-items: center;
74 justify-content: center;
75 padding: 16px;
76 box-sizing: border-box;
77 }
78
79 .subscrpt-feedback-modal *,
80 .subscrpt-feedback-modal *::before,
81 .subscrpt-feedback-modal *::after {
82 box-sizing: border-box;
83 }
84
85 .subscrpt-feedback-modal[hidden] {
86 display: none !important;
87 }
88
89 .subscrpt-feedback-modal__overlay {
90 position: absolute;
91 inset: 0;
92 background: var(--subscrpt-cfm-overlay);
93 animation: subscrpt-feedback-fade 0.18s ease-out;
94 }
95
96 .subscrpt-feedback-modal__dialog {
97 position: relative;
98 display: flex;
99 flex-direction: column;
100 width: 100%;
101 max-width: 440px;
102 max-height: calc(100vh - 32px);
103 overflow: hidden;
104 border-radius: 14px;
105 background: var(--subscrpt-cfm-surface);
106 box-shadow:
107 0 20px 60px rgba(0, 0, 0, 0.3),
108 0 2px 8px rgba(0, 0, 0, 0.12);
109 color: var(--subscrpt-cfm-text);
110 animation: subscrpt-feedback-in 0.18s ease-out;
111 }
112
113 .subscrpt-feedback-modal__header {
114 display: flex;
115 align-items: flex-start;
116 justify-content: space-between;
117 gap: 16px;
118 padding: 20px 24px 0;
119 }
120
121 .subscrpt-feedback-modal__title {
122 margin: 0;
123 padding: 0;
124 font-size: 18px;
125 font-weight: 600;
126 line-height: 1.3;
127 color: var(--subscrpt-cfm-title);
128 }
129
130 .subscrpt-feedback-modal__close {
131 flex: 0 0 auto;
132 display: inline-flex;
133 align-items: center;
134 justify-content: center;
135 width: 30px;
136 height: 30px;
137 margin: -4px -6px 0 0;
138 padding: 0;
139 border: none;
140 border-radius: 8px;
141 background: transparent;
142 color: var(--subscrpt-cfm-subtle);
143 cursor: pointer;
144 line-height: 0;
145 transition:
146 color 0.12s,
147 background 0.12s;
148 }
149
150 .subscrpt-feedback-modal__close:hover {
151 color: var(--subscrpt-cfm-text);
152 background: var(--subscrpt-cfm-hover-bg-strong);
153 }
154
155 .subscrpt-feedback-modal__body {
156 padding: 12px 24px 4px;
157 overflow-y: auto;
158 }
159
160 .subscrpt-feedback-modal__intro {
161 margin: 0 0 16px;
162 padding: 0;
163 font-size: 14px;
164 line-height: 1.5;
165 color: var(--subscrpt-cfm-muted);
166 }
167
168 .subscrpt-feedback-modal__reasons {
169 margin: 0 0 16px;
170 padding: 0;
171 list-style: none;
172 }
173
174 .subscrpt-feedback-modal__reason {
175 margin: 0 0 8px;
176 padding: 0;
177 list-style: none;
178 }
179
180 .subscrpt-feedback-modal__reason-label {
181 display: flex;
182 align-items: center;
183 gap: 10px;
184 margin: 0;
185 padding: 11px 14px;
186 border: 1px solid var(--subscrpt-cfm-border);
187 border-radius: 10px;
188 font-size: 14px;
189 color: var(--subscrpt-cfm-text);
190 cursor: pointer;
191 transition:
192 border-color 0.12s,
193 background 0.12s;
194 }
195
196 .subscrpt-feedback-modal__reason-label:hover {
197 border-color: var(--subscrpt-cfm-border-strong);
198 background: var(--subscrpt-cfm-hover-bg);
199 }
200
201 .subscrpt-feedback-modal__reason-text {
202 flex: 1 1 auto;
203 min-width: 0;
204 word-break: break-word;
205 overflow-wrap: anywhere;
206 }
207
208 .subscrpt-feedback-modal__radio {
209 flex: 0 0 auto;
210 width: 16px;
211 height: 16px;
212 margin: 0;
213 accent-color: var(--subscrpt-brand);
214 outline: none;
215 box-shadow: none;
216 }
217
218 /* Suppress the native/theme focus box on the radio itself (shows as a square
219 around the round control); the focus ring is moved to the row below. */
220 .subscrpt-feedback-modal__radio:focus,
221 .subscrpt-feedback-modal__radio:focus-visible {
222 outline: none !important;
223 box-shadow: none !important;
224 }
225
226 .subscrpt-feedback-modal__reason:has(.subscrpt-feedback-modal__radio:focus-visible)
227 .subscrpt-feedback-modal__reason-label {
228 border-color: var(--subscrpt-brand);
229 box-shadow: 0 0 0 3px var(--subscrpt-brand-ring);
230 }
231
232 /* Highlight the whole row when its radio is selected (progressive enhancement;
233 falls back to the native radio dot where :has() is unsupported). */
234 .subscrpt-feedback-modal__reason:has(.subscrpt-feedback-modal__radio:checked) .subscrpt-feedback-modal__reason-label {
235 border-color: var(--subscrpt-brand);
236 background: var(--subscrpt-brand-light);
237 }
238
239 .subscrpt-feedback-modal__comment {
240 display: block;
241 width: 100%;
242 margin: 0;
243 padding: 10px 12px;
244 border: 1px solid var(--subscrpt-cfm-border-strong);
245 border-radius: 10px;
246 background: var(--subscrpt-cfm-surface);
247 font-family: inherit;
248 font-size: 14px;
249 line-height: 1.5;
250 color: var(--subscrpt-cfm-text);
251 resize: vertical;
252 box-shadow: none;
253 }
254
255 .subscrpt-feedback-modal__comment:focus {
256 outline: none;
257 border-color: var(--subscrpt-brand);
258 box-shadow: 0 0 0 3px var(--subscrpt-brand-ring);
259 }
260
261 .subscrpt-feedback-modal__footer {
262 display: flex;
263 align-items: center;
264 justify-content: space-between;
265 gap: 10px;
266 padding: 16px 24px 20px;
267 }
268
269 .subscrpt-feedback-modal__btn {
270 -webkit-appearance: none;
271 appearance: none;
272 display: inline-flex;
273 align-items: center;
274 justify-content: center;
275 height: 42px;
276 margin: 0;
277 padding: 0 18px;
278 border: 1px solid transparent;
279 border-radius: 10px;
280 background: transparent;
281 font-family: inherit;
282 font-size: 14px;
283 font-weight: 600;
284 line-height: 1;
285 text-decoration: none;
286 cursor: pointer;
287 transition:
288 background 0.12s,
289 border-color 0.12s,
290 color 0.12s,
291 box-shadow 0.12s;
292 }
293
294 /* Staying is the button, leaving is a link. The offer step means the opposite
295 thing by "keep" and "confirm" - declining an offer is the leaving action
296 there - so it carries its own pair rather than reusing these. */
297 .subscrpt-feedback-modal__keep,
298 .subscrpt-feedback-modal__offer-claim {
299 background: var(--subscrpt-brand);
300 color: var(--subscrpt-cfm-on-brand);
301 }
302
303 .subscrpt-feedback-modal__keep:hover,
304 .subscrpt-feedback-modal__offer-claim:hover {
305 background: var(--subscrpt-brand-dark);
306 color: var(--subscrpt-cfm-on-brand);
307 }
308
309 .subscrpt-feedback-modal__confirm,
310 .subscrpt-feedback-modal__offer-decline {
311 height: auto;
312 padding: 0;
313 border: 0;
314 background: none;
315 color: var(--subscrpt-cfm-subtle);
316 font-weight: 500;
317 text-decoration: underline;
318 text-underline-offset: 3px;
319 }
320
321 .subscrpt-feedback-modal__confirm:hover,
322 .subscrpt-feedback-modal__offer-decline:hover {
323 background: none;
324 color: var(--subscrpt-cfm-text);
325 }
326
327 .subscrpt-feedback-modal__confirm[disabled],
328 .subscrpt-feedback-modal__offer-claim[disabled] {
329 opacity: 0.65;
330 cursor: not-allowed;
331 }
332
333 @keyframes subscrpt-feedback-fade {
334 from {
335 opacity: 0;
336 }
337 to {
338 opacity: 1;
339 }
340 }
341
342 @keyframes subscrpt-feedback-in {
343 from {
344 opacity: 0;
345 transform: translateY(8px) scale(0.98);
346 }
347 to {
348 opacity: 1;
349 transform: none;
350 }
351 }
352
353 @media (prefers-reduced-motion: reduce) {
354 .subscrpt-feedback-modal__overlay,
355 .subscrpt-feedback-modal__dialog {
356 animation: none;
357 }
358 }
359
360 @media (max-width: 480px) {
361 .subscrpt-feedback-modal__footer {
362 flex-direction: column-reverse;
363 }
364
365 .subscrpt-feedback-modal__btn {
366 width: 100%;
367 }
368
369 /* The link keeps its size when the row stacks - a full-width underline reads
370 as a second button, which is what this change exists to avoid. */
371 .subscrpt-feedback-modal__confirm,
372 .subscrpt-feedback-modal__offer-decline {
373 width: auto;
374 align-self: center;
375 }
376 }
377
378 /* The issued discount code, shown in place of the offer copy once claimed. */
379 .subscrpt-feedback-modal__offer-note {
380 margin: 14px 0 0;
381 padding: 12px 14px;
382 border: 1px dashed #d0d3d7;
383 border-radius: 6px;
384 background: #f6f7f7;
385 font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
386 font-size: 16px;
387 font-weight: 700;
388 letter-spacing: 0.08em;
389 text-align: center;
390 color: #1d2327;
391 }
392
393 /* The `hidden` attribute is only a user-agent `display: none`, so any class
394 that sets `display` beats it - and both of these do. Say it again with the
395 weight the attribute cannot bring on its own, or the step being swapped out
396 stays on screen underneath the one being swapped in. */
397 .subscrpt-feedback-modal__body[hidden],
398 .subscrpt-feedback-modal__footer[hidden] {
399 display: none !important;
400 }
401