Vous ne pouvez pas sélectionner plus de 25 sujets Les noms de sujets doivent commencer par une lettre ou un nombre, peuvent contenir des tirets ('-') et peuvent comporter jusqu'à 35 caractères.
 
 
 
 

243 lignes
4.1 KiB

  1. @import '../../_global/styles/mixins';
  2. @import '../../_global/styles/vars';
  3. .richtext {
  4. .detail-text:has(.survey) {
  5. overflow-x: visible;
  6. }
  7. }
  8. .survey {
  9. position: relative;
  10. display: block;
  11. margin: var(--section-margin) 0;
  12. background-color: var(--theme-color-secondary-dimmed);
  13. border-bottom: var(--border-width) solid var(--theme-color-secondary);
  14. .text-box {
  15. padding-bottom: 0;
  16. font-size: var(--font-size-small);
  17. .kicker {
  18. margin-top: -0.3em;
  19. }
  20. h2, h3 {
  21. margin-top: 0.2em;
  22. margin-bottom: 0.3em;
  23. }
  24. p:last-child {
  25. margin-bottom: 0;
  26. }
  27. @media(max-width: 567px) {
  28. padding-top: calc(var(--content-box-padding) * 1.5);
  29. }
  30. }
  31. .form-box {
  32. position: relative;
  33. padding: var(--content-box-padding);
  34. transition: height 0.5s $easeInOutCubic;
  35. @media(max-width: 567px) {
  36. padding-bottom: calc(var(--content-box-padding) * 1.5);
  37. }
  38. }
  39. form {
  40. @include show;
  41. transform: translate3d(0, 0, 0) scale(1);
  42. &:not(:last-child) {
  43. height: 0;
  44. }
  45. }
  46. h3, h4 {
  47. @media(max-width: 767px) {
  48. font-size: 26px;
  49. }
  50. }
  51. legend {
  52. @include h4;
  53. color: var(--theme-color-primary);
  54. margin: 1em 0 0.5em;
  55. padding: 0;
  56. border-bottom: 0;
  57. }
  58. ul {
  59. list-style: none;
  60. padding: 0;
  61. margin: 0 -2px;
  62. li.choice {
  63. position: relative;
  64. padding: 0;
  65. + li {
  66. margin-top: 15px;
  67. }
  68. }
  69. }
  70. input[type="radio"] {
  71. position: absolute;
  72. display: block;
  73. top: 0;
  74. left: 0;
  75. width: 100%;
  76. height: 100%;
  77. z-index: 1;
  78. border-radius: var(--border-radius-md);
  79. margin: 0;
  80. -webkit-appearance: none;
  81. -moz-appearance: none;
  82. appearance: none;
  83. transition: 0.25s ease;
  84. cursor: pointer;
  85. opacity: 0.000001;
  86. @include focus-visible();
  87. &:checked + label {
  88. background-color: var(--theme-color-secondary-intensed);
  89. color: var(--theme-color-white);
  90. }
  91. &:hover + label::after {
  92. opacity: var(--button-hover-shadow-opacity);
  93. box-shadow: 0 0 0 var(--button-hover-shadow-size) var(--button-bg-color);
  94. }
  95. }
  96. label.btn {
  97. width: 100%;
  98. transition: 0.3s ease;
  99. margin: 0;
  100. text-align: center;
  101. line-height: 1.2;
  102. min-height: 48px;
  103. @media(max-width: 999px) {
  104. min-height: 44px;
  105. }
  106. }
  107. fieldset {
  108. border: 0;
  109. padding: 0;
  110. margin: 0;
  111. }
  112. fieldset + fieldset {
  113. margin-top: calc(20px + 2%);
  114. }
  115. .btn-wrapper {
  116. display: none;
  117. }
  118. .survey-result > .title {
  119. display: none;
  120. }
  121. .result-wrapper {
  122. .title {
  123. @include h4;
  124. }
  125. }
  126. .sub-result-wrapper {
  127. position: relative;
  128. display: flex;
  129. justify-content: space-between;
  130. font-size: var(--font-size-copy);
  131. line-height: 1.1;
  132. padding: 10px 15px;
  133. align-items: center;
  134. font-family: "Korb", sans-serif;
  135. min-height: 48px;
  136. @media(max-width: 999px) {
  137. min-height: 44px;
  138. }
  139. @media(max-width: 767px) {
  140. padding: 5px 5px 5px 10px;
  141. }
  142. + .sub-result-wrapper {
  143. margin-top: 15px;
  144. }
  145. div {
  146. position: relative;
  147. display: block;
  148. &.answer {
  149. overflow: hidden;
  150. max-width: calc(100% - 60px);
  151. @media(max-width: 767px) {
  152. max-width: calc(100% - 50px);
  153. }
  154. }
  155. }
  156. .bar {
  157. position: absolute;
  158. display: block;
  159. left: 0;
  160. width: 0;
  161. top: 0;
  162. bottom: 0;
  163. transition: 0.8s $easeInOutCubic;
  164. min-width: 1px;
  165. background-color: #9AD7A3;
  166. }
  167. }
  168. .survey-result {
  169. @include hide;
  170. transform: translate3d(0, 0, 0) scale(0.9);
  171. h3 {
  172. margin-bottom: 0.9em;
  173. }
  174. }
  175. &.show-result {
  176. .survey-result {
  177. @include show(0.3s);
  178. transform: translate3d(0, 0, 0) scale(1);
  179. }
  180. form {
  181. @include hide();
  182. transform: translate3d(0, 0, 0) scale(0.9);
  183. }
  184. }
  185. &[data-size='lg'] {
  186. display: flex;
  187. align-items: center;
  188. .text-box, .form-box {
  189. flex: 1 1 100%;
  190. max-width: 50%;
  191. }
  192. .text-box {
  193. padding: var(--content-box-padding);
  194. margin-bottom: 0.1em;
  195. }
  196. .form-box {
  197. padding-left: 0;
  198. }
  199. }
  200. }