donation fixes
[wolnelektury.git] / src / wolnelektury / static / 2022 / styles / layout / _checkout.scss
1 //Support bar
2 .l-checkout__support {
3     margin-bottom: 22px;
4
5     margin-left: 16px;
6     margin-right: 16px;
7 }
8
9 .l-checkout__support__bar {
10   background: #E6F0F1 url(../images/approval.svg) center right 5px no-repeat;
11   border-radius: 10px;
12   width: 100%; height: 34px;
13   position: relative;
14   flex: 1;
15   span {
16     position: absolute;
17     top: 0; left: 0;
18     height: 100%;
19     background: #92BD39;
20     border-radius: 10px;
21     &:after {
22         white-space: nowrap;
23         color: #083F4D;
24         top: 0; left:10px; bottom: 2px;
25         @include rwd($B5) {
26             color: #FFFFFF;
27             right: 13px;
28             left: auto;
29         }
30       margin: auto;
31       position: absolute;
32       content: attr(data-label);
33       font-weight: bold;
34       font-size: 15px;
35       display: flex;
36       align-items: center;
37       justify-content: center;
38     }
39   }
40 }
41
42 .l-checkout__support__footer {
43   display: flex;
44   margin-top: 7px;
45   justify-content: space-between;
46   align-items: flex-start;
47   gap: 15px;
48   p {
49     margin: 0;
50     font-weight: normal;
51     font-size: 15px;
52     line-height: 150%;
53     color: #083F4D;
54   }
55 }
56
57 //Box
58 .l-checkout__box {
59   background: #E1F1F2;
60   border-radius: 10px;
61   padding-bottom: 30px;
62   overflow: hidden;
63   margin: 0 16px;
64 }
65
66 .l-checkout__box__header {
67   display: flex;
68   background: #083F4D;
69
70   .l-checkout__box__header__img {
71       display: none;
72       background-position: center;
73       background-size: cover;
74       @include rwd($break-flow) {
75           display: block;
76           width: 50%;
77       }
78   }
79 }
80
81 .l-checkout__box__header__content h1 {
82   font-style: italic;
83   font-weight: 300;
84   font-size: 48px;
85   line-height: 55px;
86   letter-spacing: -0.02em;
87   color: #92BD39;
88   margin: 0;
89 }
90
91 .l-checkout__box__header__content p:first-of-type {
92   font-style: normal;
93   font-weight: 600;
94   font-size: 21.5px;
95   line-height: 140%;
96   letter-spacing: -0.01em;
97   color: #FFFFFF;
98   margin-top: 23px;
99 }
100
101 .l-checkout__box__header__content p {
102   font-weight: normal;
103   font-size: 18px;
104   line-height: 150%;
105   color: #FFFFFF;
106   margin-top: 8px;
107   max-width: 410px;
108 }
109
110 .l-checkout__box__header__content {
111   padding: 32px 45px;
112 }
113
114 //Steps
115 .l-checkout__steps {
116   display: flex;
117   margin-top: -24px;
118   justify-content: space-around;
119
120   @include rwd($break-flow) {
121       padding: 0 125px;
122       justify-content: space-between;
123   }
124
125   div {
126     width: 145px;
127     display: flex;
128     flex-direction: column;
129     align-items: center;
130     justify-content: center;
131
132     span {
133       width: 46px;
134       height: 46px;
135       background: #86AD34;
136       color: white;
137       border-radius: 50%;
138       display: flex;
139       align-items: center;
140       justify-content: center;
141       font-weight: 600;
142       font-size: 21px;
143       line-height: 140%;
144       letter-spacing: -0.01em;
145     }
146
147     p {
148       margin-top: 4px;
149       font-weight: 600;
150       font-size: 21px;
151       line-height: 140%;
152       text-align: center;
153       letter-spacing: -0.01em;
154       color: #083F4D;
155       display: none;
156       @include rwd($break-flow) {
157           display: block;
158       }
159     }
160
161     &.is-completed {
162       span {
163         overflow: hidden;
164         text-indent: -999px;
165         background: #86AD34 url(../images/check.svg) center no-repeat;
166       }
167     }
168
169     &.is-inactive {
170       span {
171         background: #ffffff;
172         color: #003C3C;
173       }
174       p {
175         color: #74BDC2;
176         font-weight: normal;
177       }
178     }
179   }
180 }
181
182 //Switch
183 .l-switch__wrapper {
184   display: flex;
185   align-items: center;
186   justify-content: center;
187   margin-top: 35px;
188   width: 100%;
189 }
190
191 .l-switch {
192   background: #fff;
193   display: block;
194   position: relative;
195   height: 26px;
196   width: 77px;
197   border-radius: 4px;
198 }
199
200 .l-switch label {
201   color: #74BDC2;
202   font-weight: 600;
203   font-size: 18.5px;
204   line-height: 26px;
205   transition: color .2s ease;
206   width: 122px;
207   cursor: pointer;
208
209   @include rwd($break-flow) {
210       font-size: 21.5px;
211   }
212 }
213
214 .l-switch label:nth-of-type(1) {
215   left: -175%;
216   position: absolute;
217   text-align: right;
218 }
219
220 .l-switch label:nth-of-type(2) {
221   position: absolute;
222   right: -175%;
223   text-align: left;
224 }
225
226 .l-switch input {
227   left: 0;
228   opacity: 0;
229   position: absolute;
230   top: 0;
231   height: 26px;
232   width: 77px;
233   z-index: 2;
234 }
235
236 .toggle-input-left:checked ~ .l-switch__wrapper {
237     .toggle-for-left {
238         color: #003C3C;
239     }
240     .toggle {
241         left: 5px;
242     }
243 }
244 .toggle-input-right:checked ~ .l-switch__wrapper {
245     .toggle-for-right {
246         color: #003C3C;
247     }
248     .toggle {
249         left: 39px;
250     }
251 }
252 .l-switch input:checked~label:nth-of-type(1) { color: #003C3C; }
253 .l-switch input~:checked~label:nth-of-type(2) { color: #003C3C; }
254
255 .l-switch input:checked~.toggle {
256   left: 5px;
257 }
258
259 .l-switch input~:checked~.toggle {
260   left: 39px;
261 }
262
263 .l-switch input:checked {
264   z-index: 0;
265 }
266
267 .toggle {
268   background: #003C3C;
269   left: 0;
270   position: absolute;
271   top: 5px;
272   transition: left .2s ease;
273   height: 16px;
274   width: 33px;
275   z-index: 1;
276   border-radius: 2px;
277   cursor: pointer;
278 }
279
280 //Payments
281 .l-checkout__payments {
282     display: none;
283     padding: 0 16px;
284   margin-top: 34px;
285   margin-bottom: 0;
286   flex-wrap: wrap;
287   justify-content: flex-start;
288   flex-direction: row;
289   column-gap: 16px;
290
291   @include rwd($break-flow) {
292       //flex-direction: row;
293       padding: 0 30px;
294       column-gap: 30px;
295   }
296 }
297
298 .l-checkout__payments__box {
299   display: flex;
300   flex-direction: column;
301   background: #FFFFFF;
302   border-radius: 10px;
303   overflow: hidden;
304   transition: box-shadow $ease-out 250ms;
305   box-shadow: 0px 0px 0px rgba(55, 170, 156, 0);
306   margin-bottom: 30px;
307   width: 100%;
308
309   @include rwd($break-flow) {
310       width: calc(33.333% - 20px);
311   }
312   h3 {
313     margin: 0;
314     font-weight: bold;
315     font-size: 44px;
316     line-height: 130%;
317     letter-spacing: -0.01em;
318     color: #083F4D;
319     height: 90px;
320     display: flex;
321     align-items: center;
322     justify-content: center;
323     transition: all $ease-out 250ms;
324
325     span {
326       font-weight: 600;
327       font-size: 25px;
328       line-height: 140%;
329       letter-spacing: -0.01em;
330       color: #92BD39;
331       margin-left: 10px;
332       transition: opacity $ease-out 250ms;
333     }
334   }
335   .l-checkout__payments__box__btn-wrp {
336       padding: 20px;
337     margin-bottom: 0;
338     margin-top: auto;
339   }
340   p {
341     margin-top: 0;
342     font-weight: normal;
343     font-size: 16px;
344     line-height: 150%;
345     color: #474747;
346     padding: 20px;
347     strong {
348       font-weight: 600;
349     }
350   }
351   button {
352       margin: 0;
353       font-family: "Source Sans Pro",sans-serif;
354     font-weight: bold;
355     font-size: 44px;
356     letter-spacing: -0.01em;
357     height: 90px;
358     display: flex;
359     align-items: center;
360     justify-content: center;
361     transition: all $ease-out 250ms;
362
363     background: #FFFFFF;
364     border: 1px solid #92BD39;
365     border-radius: 3px;
366     width: 100%;
367     outline: 0;
368     cursor: pointer;
369     text-align: center;
370     color: #083F4D;
371
372     flex-direction: column;
373     @include rwd($break-flow) {
374         flex-direction: row;
375         line-height: 130%;
376     }
377
378     span {
379       font-weight: 600;
380       font-size: 25px;
381       letter-spacing: -0.01em;
382       color: #92BD39;
383       margin-left: 10px;
384       transition: opacity $ease-out 250ms;
385     }
386     
387     &:hover {
388       background: rgba(#92BD39, 0.75);
389     }
390   }
391   img {
392       display: none;
393       @include rwd($break-flow) {
394           display: block;
395       }
396   }
397
398   &.is-active {
399       box-shadow: 0px 0px 20px rgba(55, 170, 156, 0.35);
400       background: white;
401       color: black;
402
403     h3 {
404       color: white;
405       background: #083F4D;
406     }
407
408     button {
409       background: #92BD39;
410       &:hover {
411         background: #83AD2B;
412       }
413       span {
414           color: white;
415       }
416     }
417   }
418
419   &.l-checkout__payments__box--half {
420       width: calc(50% - 8px);
421       @include rwd($break-flow) {
422           width: calc(33.333% - 20px);
423       }
424
425       &.is-active {
426           background: #083F4D;
427           color: white;
428
429           @include rwd($break-flow) {
430               background: white;
431               color: black;
432           }
433       }
434   }
435   &.l-checkout__payments__box--bar {
436       flex-direction: row;
437       
438       @include rwd($break-flow) {
439           flex-direction: column;
440       }
441
442       &.is-active {
443           background: #083F4D;
444           color: white;
445
446           @include rwd($break-flow) {
447               background: white;
448               color: black;
449           }
450       }
451
452       h3, .l-checkout__payments__box__btn-wrp {
453           flex-grow: 1;
454       }
455   }
456   &.l-checkout__payments__box--card {
457   }
458   
459   &.l-checkout__payments__box--xl {
460       width: 100%;
461       justify-content: center;
462       min-height: 160px;
463
464       @include rwd($break-flow) {
465           width: calc(67.4% - 20px);
466           padding-left: calc(33.7% - 10px);
467           position: relative;
468
469           h3 {
470               position: absolute;
471               left: 0;
472               top: 0;
473               padding-right: 50%;
474           }
475           
476           .l-checkout__payments__box__btn-wrp {
477               margin: 0;
478
479               p {
480                   flex-wrap: wrap;
481                   max-width: 340px;
482                   margin-right: 20px;
483               }
484
485               button {
486                   position: absolute;
487                   bottom: 20px;
488                   left: 20px;
489                   width: calc(50% - 50px);
490                   align-items: center;
491                   justify-content: center;
492               }
493           }
494       }
495
496     h3 {
497       width: 100%;
498     }
499
500     .l-checkout__payments__box__btn-wrp {
501       width: 100%;
502     }
503
504     &.once {
505       h3 {
506         text-indent: 0;
507         padding-left: 0;
508       }
509     }
510   }
511   &.l-checkout__payments__box--special {
512     button {
513       border-color: #FFA500;
514       background-color: #FFA500;
515       &:hover {
516         background: darken(#FFA500, 5%);
517       }
518     }
519   }
520 }
521
522 //Amount
523 .l-checkout__amount {
524   display: flex;
525   flex-direction: column;
526   padding: 0 16px;
527   row-gap: 16px;
528
529   @include rwd($break-flow) {
530       flex-direction: row;
531       align-items: flex-end;
532       justify-content: flex-end;
533       padding-right: 30px;
534   }
535   
536   button {
537       border: none;
538     height: 56px;
539     background: #083F4D;
540     border-radius: 3px;
541     font-weight: 600;
542     font-size: 20px;
543     line-height: 25px;
544     display: flex;
545     align-items: center;
546     justify-content: center;
547     text-align: center;
548     color: #FFFFFF;
549
550     @include rwd($break-flow) {
551         margin-left: 32px;
552         width: 340px;
553     }
554
555   }
556
557   .l-checkout__input {
558       @include rwd($break-flow) {
559           width: 340px;
560       }
561   }
562 }
563
564
565
566 //Input
567 .l-checkout__input {
568   display: flex;
569   flex-direction: column;
570
571   label {
572     font-style: normal;
573     font-weight: 600;
574     font-size: 15px;
575     line-height: 160%;
576     color: #083F4D;
577     span { color: #FF4C54; }
578   }
579   input, select, textarea {
580       width: 100%;
581     height: 56px;
582     background: #FFFFFF;
583     border: 1px solid #D5ECED;
584     border-radius: 3px;
585     transition: all $ease-out 250ms;
586     padding: 10px;
587     outline: 0;
588
589     &:focus {
590       border: 1px solid #007880;
591     }
592   }
593
594   button {
595     height: 40px;
596     background: #083F4D;
597     border: none;
598     border-radius: 3px;
599     font-weight: 600;
600     font-size: 16px;
601     line-height: 25px;
602     display: flex;
603     align-items: center;
604     justify-content: center;
605     text-align: center;
606     color: #FFFFFF;
607
608     @include rwd($break-flow) {
609         height: 56px;
610         font-size: 20px;
611         width: 340px;
612         margin-left: 32px;
613     }
614   }
615 }
616
617 //Cols
618 .l-checkout__cols {
619   display: flex;
620   flex-direction: column;
621   margin-top: 50px;
622   padding: 0 16px;
623
624   @include rwd($break-flow) {
625       padding: 0 30px;
626       flex-direction: row;
627   }
628   
629   &.bt-w {
630     margin-top: 30px;
631     padding-top: 20px;
632     border-top: 1px solid white;
633   }
634 }
635
636 .l-checkout__col {
637   @include rwd($break-flow) {
638   &:nth-child(1) {
639     width: 402px;
640     padding-right: 62px;
641     .l-checkout__payments__box {
642       width: 100%;
643     }
644   }
645   &:nth-child(2) {
646     width: calc(100% - 402px);
647   }
648   &.full {
649     width: 100%;
650     padding-right: 0;
651
652     .l-checkout__form__row.full {
653       flex-direction: row;
654
655       & > h3 {
656         margin-top: 22px;
657       }
658
659       .l-checkout__info {
660         width: 100%;
661         padding-left: 100px;
662       }
663     }
664   }
665   }
666 }
667
668 .l-checkout__secure {
669     margin-top: 30px;
670     margin-right: 30px;
671     text-align: right;
672     font-size: 15px;
673     color: #888;
674
675     .l-checkout__secure__padlock {
676         margin-right: 5px;
677         vertical-align: baseline;
678     }
679     
680     .l-checkout__secure__img {
681         margin-left: 10px;
682         vertical-align: bottom;
683     }
684 }
685
686
687 //Form
688 .l-checkout__form {
689   display: flex;
690   width: 100%;
691   flex-direction: column;
692 }
693
694 .l-checkout__form__row {
695     display: flex;
696     flex-direction: column;
697     gap: 20px;
698   margin-bottom: 24px;
699
700   @include rwd($break-flow) {
701       flex-direction: row;
702   }
703   
704   &:nth-child(4) {
705     .l-checkout__input {
706       &:nth-child(1) { width: 172px; }
707       &:nth-child(2) { width: calc(100% - 172px); }
708     }
709   }
710
711   &.full {
712     flex-direction: column;
713     @include rwd($break-flow) {
714         flex-direction: column;
715     }
716   }
717
718   h3 {
719     margin-top: 0;
720     font-weight: 600;
721     font-size: 21.5px;
722     line-height: 140%;
723     letter-spacing: -0.01em;
724     color: #083F4D;
725   }
726
727   .iframe {
728     margin-top: 16px;
729   }
730
731   .l-checkout__input {
732     width: 100%;
733   }
734
735   & > a {
736     font-weight: 600;
737     font-size: 20px;
738     line-height: 25px;
739     color: #74BDC2;
740     transition: all $ease-out 250ms;
741
742     &:hover {
743       color: #007880;
744     }
745   }
746
747   &.confirm {
748       display: flex;
749       flex-direction: row;
750     align-items: center;
751     justify-content: stretch;
752     width: 100%;
753     gap: 50px;
754
755     @include rwd($break-flow) {
756         justify-content: space-between;
757     }
758     
759     .l-checkout__input {
760         flex-grow: 1;
761         @include rwd($break-flow) {
762             width: auto;
763             flex-grow: 0;
764         }
765     }
766   }
767   .errorlist {
768       padding: 0;
769       margin: 0;
770       list-style: none;
771       color: #FF4C54;
772       li:before {
773           content: 'âš  ';
774       }
775   }
776 }
777
778 //Info
779 .l-checkout__info__item {
780   position: relative;
781   display: flex;
782   align-items: center;
783   justify-content: space-between;
784   transition: all $ease-out 250ms;
785   width: 100%;
786   overflow: hidden;
787   margin-top: 15px;
788
789   &:hover {
790     background-color: darken(#E1F1F2, 2%);
791   }
792
793   div {
794     font-weight: normal;
795     font-size: 15px;
796     line-height: 150%;
797     color: #083F4D;
798     width: 100px;
799   }
800
801   h3 {
802     width: 426px;
803     font-weight: 500;
804     font-size: 18px;
805     line-height: 150%;
806     color: #083F4D;
807     padding-left: 30px;
808   }
809
810   button {
811     outline: 0;
812     background: transparent;
813     border: 0;
814     cursor: pointer;
815     display: flex;
816     align-items: center;
817     justify-content: center;
818     margin-right: 0;
819     margin-left: auto;
820     &:hover {
821       opacity: 0.75;
822     }
823   }
824   input {
825     top: 0;
826     left: 0;
827     position: absolute;
828     transform: translate(-100%,-100%);
829   }
830 }
831
832 //Completed
833 .l-checkout__completed {
834   display: flex;
835   align-items: center;
836   justify-content: center;
837   flex-direction: column;
838   margin: auto;
839   padding: 140px 0;
840   background: url(../images/checkout-bg.png) no-repeat center;
841
842   .l-checkout__completed__wrapper {
843     max-width: 580px;
844     display: flex;
845     align-items: center;
846     justify-content: center;
847     flex-direction: column;
848   }
849
850   h1 {
851     margin-top: 0;
852     font-style: italic;
853     font-weight: 300;
854     font-size: 58px;
855     line-height: 55px;
856     letter-spacing: -0.02em;
857     color: #083F4D;
858   }
859   p {
860     margin-top: 30px;
861     font-weight: normal;
862     font-size: 21.5px;
863     line-height: 140%;
864     text-align: center;
865     letter-spacing: -0.01em;
866     color: #007880;
867   }
868   a {
869     margin-top: 50px;
870     font-weight: 600;
871     font-size: 20px;
872     line-height: 25px;
873     display: flex;
874     align-items: center;
875     justify-content: center;
876     background: #083F4D;
877     border-radius: 3px;
878     height: 56px;
879     text-align: center;
880     color: #FFFFFF;
881     width: 340px;
882   }
883 }
884
885 //Footer
886 .l-checkout__footer {
887   display: flex;
888   flex-wrap: wrap;
889   margin-top: 12px;
890   margin-bottom: 52px;
891   margin-left: 16px;
892   margin-right: 16px;
893 }
894
895 .l-checkout__footer > img {
896   margin-right: 0;
897   margin-left: auto;
898 }
899
900 .l-checkout__footer__content {
901   display: flex;
902   flex-direction: column;
903 }
904
905 .l-checkout__footer__content__item {
906   display: flex;
907   flex-direction: column;
908
909   @include rwd($break-flow) {
910       flex-direction: row;
911   }
912   
913   &:not(:last-child) {
914     padding-bottom: 30px;
915     margin-bottom: 30px;
916     border-bottom: 1px solid #E1F1F2;
917   }
918 }
919
920 .l-checkout__footer__content h3 {
921   @include rwd($break-flow) {
922   font-weight: 600;
923   font-size: 21.5px;
924   line-height: 140%;
925   letter-spacing: -0.01em;
926   color: #083F4D;
927   width: 318px;
928   }
929 }
930
931 .l-checkout__footer__content__item > div {
932   @include rwd($break-flow) {
933   width: 100%;
934   padding-left: 120px;
935   }
936 }
937
938 .l-checkout__footer__content__item > div p {
939   font-weight: normal;
940   font-size: 15px;
941   line-height: 150%;
942   color: #808080;
943 }
944
945 .l-checkout__footer__content__item > div p a {
946   color: #007880;
947   &:hover {
948     text-decoration: underline;
949   }
950 }
951
952 .l-checkout__footer__content {
953   .l-article__read-more {
954     margin-top: 20px;
955     font-size: 15px;
956     &:after {
957       margin-left: 5px;
958       display: inline-block;
959       transform: rotate(180deg);
960       content: $icon-arrow-up;
961       font-family: '#{$icomoon-font-family}' !important;
962       font-size: 12px;
963       speak: never;
964       font-style: normal;
965       font-weight: normal;
966       font-variant: normal;
967       text-transform: none;
968       line-height: 1;
969
970       /* Better Font Rendering =========== */
971       -webkit-font-smoothing: antialiased;
972       -moz-osx-font-smoothing: grayscale;
973     }
974   }
975
976   .l-article__overlay {
977     &:after {
978       display: none;
979     }
980     &.is-clicked {
981       & + .l-article__read-more {
982         &:after {
983           transform: none;
984         }
985       }
986     }
987   }
988 }
989
990
991
992
993
994 .toggle-input{
995     &#switch-once:checked {
996         ~.l-switch__wrapper {
997             label {
998                 &:nth-of-type(1) { color: #003C3C; }
999                 &:nth-of-type(2) { color: #74BDC2; }
1000             }
1001             .toggle {
1002                 left: 5px;
1003             }
1004         }
1005         ~.payments-once {
1006             display: flex;
1007
1008             &.wide-spot-1 ~.l-checkout__amount {
1009                 @include rwd($break-flow) {
1010                     margin-top: -110px;
1011
1012                     > div, > button {
1013                         width: calc(33.333% - 20px);
1014                     }
1015                 }
1016             }
1017             &.wide-spot-2 ~.l-checkout__amount {
1018                 @include rwd($break-flow) {
1019                     flex-direction: column;
1020                     margin-top: -182px;
1021
1022                     > div, > button {
1023                         width: calc(33.333% - 20px);
1024                     }
1025                 }
1026             }
1027         }
1028     }
1029     &#switch-monthly:checked {
1030         ~.l-switch__wrapper {
1031             label {
1032                 &:nth-of-type(1) { color: #74BDC2; }
1033                 &:nth-of-type(2) { color: #003C3C; }
1034             }
1035             .toggle {
1036                 left: 39px;
1037             }
1038         }
1039         ~.payments-recurring {
1040             display: flex;
1041
1042             &.wide-spot-1 ~.l-checkout__amount {
1043                 @include rwd($break-flow) {
1044                     margin-top: -110px;
1045
1046                     > div, > button {
1047                         width: calc(33.333% - 20px);
1048                         margin-left: 24px;
1049                     }
1050                 }
1051             }
1052             &.wide-spot-2 ~.l-checkout__amount {
1053                 @include rwd($break-flow) {
1054                     flex-direction: column;
1055                     margin-top: -182px;
1056
1057                     > div, > button {
1058                         width: calc(33.333% - 20px);
1059                     }
1060                 }
1061             }
1062         }
1063     }
1064 }
1065
1066
1067 .if-monthly { display: none; }
1068 .is-monthly {
1069     .if-monthly {
1070         display: block;
1071     }
1072     .if-not-monthly {
1073         display: none;
1074     }
1075 }
1076
1077
1078 .checkout-infobar {
1079     margin: 0 0 20px;
1080     padding: 20px;
1081     border-radius: 10px;
1082     border: 1px solid #edc016;
1083     background: #edc016;
1084 }