main.scss 14 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719
  1. // @Author: Bachir Soussi Chiadmi <bach>
  2. // @Date: 18-12-2017
  3. // @Email: bachir@figureslibres.io
  4. // @Filename: app.scss
  5. // @Last modified by: bach
  6. // @Last modified time: 20-12-2017
  7. // @License: GPL-V3
  8. @import './base/reset';
  9. @import './base/variables';
  10. @import './base/colors';
  11. @import './base/grid';
  12. @import './base/layout';
  13. // $mdi-font-path: "./mdi/fonts";
  14. // @import './mdi/scss/materialdesignicons.scss';
  15. @import './base/fonts';
  16. html{
  17. // background-color: red;
  18. }
  19. aside.messages{
  20. border:none;
  21. }
  22. // _ _ _
  23. // | || |___ __ _ __| |___ _ _
  24. // | __ / -_) _` / _` / -_) '_|
  25. // |_||_\___\__,_\__,_\___|_|
  26. header[role="banner"]{
  27. padding:0.2em 0 0 0;
  28. %header-fs{
  29. font-size: 0.9em;
  30. // line-height: 1;
  31. font-weight: 400;
  32. }
  33. #block-sitebranding{
  34. h1{
  35. margin:0;
  36. line-height: 1;
  37. }
  38. }
  39. #block-userlogin{
  40. position: relative;
  41. // width:8em;
  42. padding:0 1em;
  43. overflow: visible;
  44. h2{
  45. @extend %header-fs;
  46. line-height: 1.38;
  47. margin: 0;
  48. }
  49. &>section{
  50. background-color: #fff;
  51. overflow: hidden;
  52. width:11em;
  53. height:1px;
  54. padding:0.01em 1em;
  55. // margin:0 0 0 -1em;
  56. box-sizing:content-box;
  57. transition: all 0.4s ease-in-out;
  58. // outline: 1px solid blue;
  59. transition-delay: 2s;
  60. position: absolute;
  61. right:0;
  62. top:1.7em;
  63. box-sizing: content-box;
  64. }
  65. &:hover{
  66. &>section{
  67. transition-delay: 0s;
  68. height:12em;
  69. padding:1em 1em;
  70. box-shadow: 0 0 10px #ccc;
  71. }
  72. }
  73. .form-item{
  74. margin:0;
  75. position: relative;
  76. width:100%;
  77. &.form-item-name{
  78. margin:2px 0 0.5em 0;
  79. input{
  80. width:90%;
  81. padding:0;
  82. box-sizing: content-box;
  83. }
  84. }
  85. &.form-item-pass{
  86. margin:0 0 0.5em 0;
  87. input{
  88. width:90%;
  89. padding:0;
  90. box-sizing: content-box;
  91. }
  92. }
  93. &.form-item-persistent-login{
  94. font-size: 0.756em;
  95. label{
  96. vertical-align: top;
  97. }
  98. }
  99. }
  100. #edit-actions{
  101. margin:0;
  102. }
  103. .item-list{
  104. ul{
  105. margin:0;
  106. li{
  107. list-style: none;
  108. margin:0;
  109. a{
  110. font-size: 0.756em;
  111. }
  112. }
  113. }
  114. }
  115. }
  116. // menu
  117. #block-header{
  118. margin-right: 1em;
  119. padding-left: 1em;
  120. border-left: 1px solid #000;
  121. ul.menu{
  122. margin:0;
  123. li{
  124. padding:0;
  125. display: inline-block;
  126. &:not(:first-of-type){
  127. margin-left: 0.5em;
  128. }
  129. a{
  130. @extend %header-fs;
  131. }
  132. }
  133. }
  134. }
  135. #block-languageswitcher{
  136. text-align: right;
  137. h2{
  138. margin: 0.1em 0 0 0;
  139. font-size: 0.756em;
  140. font-weight: 400;
  141. padding:0.1em 0.4em 0.2em;
  142. border-radius: 3px;
  143. background-color: #444;
  144. color: #fff;
  145. display: inline-block;
  146. vertical-align: top;
  147. }
  148. &>ul.links{
  149. // background-color: #fff;
  150. overflow: hidden;
  151. width:3.5em;
  152. // display: inline-block;
  153. height:1px;
  154. padding:0.01em 0;
  155. margin:0;
  156. box-sizing:content-box;
  157. transition: all 0.4s ease-in-out;
  158. // outline: 1px solid blue;
  159. // transition-delay: 2s;
  160. }
  161. &:hover{
  162. &>ul.links{
  163. transition-delay: 0s;
  164. height:2em;
  165. padding:0.3em 0;
  166. // box-shadow: 0 0 10px #ccc;
  167. }
  168. }
  169. li{
  170. list-style: none;
  171. padding:0;
  172. display: inline-block;
  173. &.is-active{
  174. display:none;
  175. }
  176. a{
  177. margin: 0;
  178. font-size: 0.756em;
  179. font-weight: 400;
  180. padding:0.2em 0.4em;
  181. border-radius: 3px;
  182. background-color: #444;
  183. color: #fff;
  184. }
  185. }
  186. }
  187. // header bottom
  188. #block-pagetitle{
  189. float: left;
  190. padding:1em 0;
  191. h2{
  192. margin:0;
  193. font-size: 1.512em;
  194. text-transform: capitalize;
  195. font-weight: 300;
  196. body:not(.path-home) & {
  197. padding:0.5em 1em;
  198. }
  199. body.path-blabla & {
  200. color: #fff;
  201. background-color: $color-blabla;
  202. }
  203. body.path-showrooms & {
  204. color: #fff;
  205. background-color: $color-showrooms;
  206. }
  207. body.path-base & {
  208. color: #fff;
  209. background-color: $color-base;
  210. }
  211. }
  212. }
  213. #block-materiosapisearchblock{
  214. float:right;
  215. display:inline-block;
  216. // box-shadow: 0 0 5px rgba(0,0,0,0.2);
  217. padding:0;
  218. #materio-sapi-search-form{
  219. .form-item, input.button{
  220. display: inline-block;
  221. }
  222. #edit-search{
  223. border:1px #BBB solid;
  224. border-radius: 14px;
  225. padding:0.3em;
  226. color:#666;
  227. }
  228. #edit-submit{
  229. border:0;
  230. text-indent: 50px;
  231. overflow: hidden;
  232. width:20px; height:20px;
  233. margin:0;
  234. // border-radius: 7px;
  235. background-image: url('../img/search.png');
  236. background-position: center;
  237. background-repeat: no-repeat;
  238. background-size: contain;
  239. }
  240. }
  241. }
  242. }
  243. // main
  244. aside.messages{
  245. padding: 0;
  246. }
  247. // content top
  248. // #content-top{
  249. // &:after{
  250. // content:"";
  251. // clear:both;
  252. // display: block;
  253. // }
  254. // }
  255. // __ _
  256. // / _|_ _ ___ _ _| |_
  257. // | _| '_/ _ \ ' \ _|
  258. // |_| |_| \___/_||_\__|
  259. article.node--type-frontpage{
  260. %front-col-field__label{
  261. font-size: 3.5em;
  262. line-height: 1;
  263. }
  264. %front-col-descritpion{
  265. font-size: 0.9em;
  266. line-height: 1.3;
  267. }
  268. %part-centered-layout{
  269. padding:1.5em 0;
  270. background-color: #fff;
  271. >div:nth-child(1){
  272. width:80%;
  273. margin: 0 auto;
  274. text-align: center;
  275. .field__label{
  276. @extend %front-col-field__label;
  277. }
  278. .field__item{
  279. @extend %front-col-descritpion;
  280. }
  281. }
  282. }
  283. %part-columned-layout{
  284. display:grid;
  285. grid-template-columns: 300px 1fr;
  286. grid-column-gap: 2em;
  287. padding:2em 1em;
  288. >div:nth-child(1){
  289. color: #fff;
  290. grid-column: 1;
  291. .field__label{
  292. @extend %front-col-field__label;
  293. }
  294. .field__item{
  295. @extend %front-col-descritpion;
  296. }
  297. }
  298. >div:nth-child(2){
  299. grid-column: 2;
  300. }
  301. }
  302. .node__content{
  303. &>section{
  304. &.home-intro{
  305. @extend %part-centered-layout;
  306. }
  307. &.home-database{
  308. background-color: $color-base;
  309. @extend %part-columned-layout;
  310. .field--name-field-a-database{}
  311. .cards-list-home{
  312. position: relative;
  313. // max-height: (130px*1.4)*3;
  314. max-height: 580px;
  315. overflow-y: hidden;
  316. ul{
  317. width:100%;
  318. margin:0; padding:0;
  319. display: grid;
  320. grid-template-columns: repeat(auto-fill, minmax(50px, 130px));
  321. grid-template-rows: 1fr;
  322. grid-gap: 1em;
  323. justify-content:start;
  324. li{
  325. position: relative;
  326. list-style: none;
  327. margin:0; padding:0;
  328. padding-top: 140%;
  329. .card{
  330. position:absolute;
  331. top:0; bottom:0;
  332. left:0; right:0;
  333. width: auto;
  334. height: auto;
  335. .field--name-field-short-description{
  336. font-size: 0.756em;
  337. line-height: 0.9;
  338. }
  339. }
  340. }
  341. }
  342. }
  343. }
  344. &.home-showrooms{
  345. background-color: $color-showrooms;
  346. @extend %part-columned-layout;
  347. .field--name-field-showrooms{
  348. }
  349. .field--name-computed-showrooms-reference{
  350. position:relative;
  351. // height:550px;
  352. display: grid;
  353. grid-template-rows: 1fr;
  354. $bp: ($column_width + $column_goutiere )*7;
  355. @media only screen and (max-width: $bp){
  356. grid-template-columns: 1fr;
  357. >.field__item{
  358. grid-column: 1;
  359. }
  360. }
  361. @media only screen and (min-width: $bp + 1px){
  362. grid-template-columns: 1fr 1fr;
  363. grid-gap: 1em;
  364. >.field__item:nth-child(odd){
  365. grid-column: 1;
  366. }
  367. >.field__item:nth-child(even){
  368. grid-column: 2;
  369. }
  370. }
  371. >.field__item{
  372. grid-row: 1;
  373. // position: absolute;
  374. // top:0; left:0;
  375. // width:100%; height:100%;
  376. // overflow: hidden;
  377. .taxonomy-term{
  378. position: relative;
  379. width:100%; height:100%;
  380. div.visuel{
  381. width:100%;
  382. padding-bottom: 10em;
  383. img{
  384. max-width: 100%;
  385. height: auto;
  386. }
  387. }
  388. section.text{
  389. position: absolute;
  390. bottom:0; left:0;
  391. width:100%;
  392. box-sizing:border-box;
  393. padding:1em 0;
  394. background-color:$color-showrooms;
  395. color: #fff;
  396. >*{
  397. // display: inline-block;
  398. font-size: 0.9em;
  399. }
  400. h2,p{
  401. margin:0;
  402. }
  403. }
  404. }
  405. }
  406. }
  407. }
  408. &.home-blabla{
  409. background-color: $color-blabla;
  410. @extend %part-columned-layout;
  411. .cards-list-home{
  412. position: relative;
  413. $bp: ($column_width + $column_goutiere );
  414. overflow-y: hidden;
  415. @media only screen and (max-width: $bp * 6){
  416. max-height: 630px;
  417. }
  418. @media only screen and (min-width: ($bp * 6) + 1px){
  419. max-height: 310px;
  420. }
  421. ul{
  422. width:100%;
  423. margin:0; padding:0;
  424. display: grid;
  425. grid-template-columns: repeat(auto-fill, minmax(80px, 220px));
  426. // grid-template-rows: 1fr;
  427. grid-gap: 1em;
  428. justify-content:start;
  429. li{
  430. position: relative;
  431. list-style: none;
  432. margin:0; padding:0;
  433. padding-top: 140%;
  434. overflow: hidden;
  435. .card{
  436. position:absolute;
  437. top:0; bottom:0;
  438. left:0; right:0;
  439. width: auto;
  440. height: auto;
  441. .field--name-title{
  442. font-size: 0.756em;
  443. line-height: 0.9;
  444. }
  445. }
  446. }
  447. }
  448. }
  449. }
  450. &.home-pricing{
  451. @extend %part-centered-layout;
  452. }
  453. }
  454. }
  455. }
  456. // ___ _
  457. // / __|__ _ _ _ __| |___
  458. // | (__/ _` | '_/ _` (_-<
  459. // \___\__,_|_| \__,_/__/
  460. .infinite-loading-container{
  461. .infinite-status-prompt{
  462. i[class^="loading-"]{
  463. width:15px; height:15px;
  464. }
  465. }
  466. }
  467. .cards-list{
  468. position: relative;
  469. .search-info{
  470. font-size: 0.756em;
  471. font-weight: 500;
  472. margin: 0;
  473. padding: 0 0 0.5em 0;
  474. }
  475. &>ul{
  476. // outline: 1px green solid;
  477. margin:0; padding:0;
  478. width: calc(100% + #{$column_goutiere});
  479. &>li{
  480. list-style: none;
  481. margin:0 $column_goutiere $column_goutiere 0; padding:0;
  482. display: inline-block;
  483. vertical-align: top;
  484. }
  485. }
  486. }
  487. article.card{
  488. position: relative;
  489. box-shadow: 0 0 5px rgba(0,0,0,0.2);
  490. width:$column_width; height:295px;
  491. // &.card-small{
  492. // width:100px; height:140px;
  493. // }
  494. // focused
  495. // box-shadow: 0 0 7px rgba(0,0,0,0.9);
  496. // &.article{
  497. // width: $column_width * 2 + $column_goutiere;
  498. //
  499. // }
  500. header{
  501. position: absolute;
  502. bottom:0;
  503. z-index:10;
  504. color: #000;
  505. background-color: rgba(255,255,255,0.8);
  506. padding: 0.3em 0.3em;
  507. box-sizing:border-box;
  508. width:100%;
  509. h1, h4{ margin:0; padding:0; }
  510. h1{
  511. font-size: 1.3em;
  512. font-weight: 700;
  513. line-height: 0.85;
  514. margin-bottom: 0.2em;
  515. }
  516. h4{
  517. font-size: 0.882em;
  518. font-weight: 300;
  519. line-height: 1;
  520. // margin-bottom: 0.1em;
  521. }
  522. span.ref{
  523. font-size: 0.693em;
  524. font-weight: 300;
  525. line-height: 1;
  526. }
  527. }
  528. section.images{
  529. position: relative;
  530. &, *{width: 100%; height:100%;}
  531. figure{
  532. margin:0;
  533. position: absolute;
  534. top:0; left:0;
  535. // width: 100%; height:100%;
  536. &:first-of-type{
  537. z-index:5
  538. }
  539. img{
  540. // width: 100%; height:100%;
  541. &.blank{
  542. position: absolute;
  543. top:0; left:0;
  544. z-index: 20;
  545. }
  546. }
  547. }
  548. }
  549. }
  550. // ___ _ _ _
  551. // | _ ) |__ _| |__| |__ _
  552. // | _ \ / _` | '_ \ / _` |
  553. // |___/_\__,_|_.__/_\__,_|
  554. #blabla{
  555. }
  556. #main-content > article.article{
  557. section.taxonomy{
  558. ul{
  559. margin:1em 0 0;
  560. }
  561. li{
  562. display:inline-block;
  563. padding:0 0.5em 0 0;
  564. }
  565. }
  566. section.visuels{
  567. width:calc(100% + #{$column_goutiere});
  568. figure{
  569. display: inline-block;
  570. vertical-align: top;
  571. width:$column_width;
  572. margin:0 $column_goutiere 0 0;
  573. img{
  574. width:100%;
  575. }
  576. }
  577. }
  578. aside.linked-materials{
  579. ul{
  580. width:calc(100% + #{$column_goutiere});
  581. li{
  582. display: inline-block;
  583. vertical-align: top;
  584. width:$column_width;
  585. margin:0 $column_goutiere 0 0;
  586. }
  587. }
  588. h3.field__label{
  589. font-size: 1em;
  590. font-weight: 500;
  591. margin: 2em 0 1em 0;
  592. }
  593. h1.title{
  594. font-size: 1em;
  595. font-weight: 400;
  596. }
  597. h3.ref{
  598. font-size: 0.756em;
  599. font-weight: 600;
  600. }
  601. h2.description{
  602. font-size: 0.756em;
  603. font-weight: 400;
  604. }
  605. }
  606. nav.prevnext{
  607. &.bottom{
  608. margin:2em 0;
  609. }
  610. ul{
  611. padding:0;
  612. margin:0;
  613. display: grid;
  614. grid-template-columns: 1fr 1fr;
  615. }
  616. li{
  617. padding:0;
  618. margin:0;
  619. list-style: none;
  620. a{
  621. font-size: 0.756em;
  622. font-weight: 700;
  623. }
  624. &:nth-child(1){
  625. grid-column: 1;
  626. a:before{
  627. content:'< ';
  628. }
  629. }
  630. &:nth-child(2){
  631. grid-column: 2;
  632. text-align: right;
  633. a:after{
  634. content:' >';
  635. }
  636. }
  637. }
  638. }
  639. }
  640. // ___ _
  641. // / __| |_ _____ __ ___ _ ___ ___ _ __ ___
  642. // \__ \ ' \/ _ \ V V / '_/ _ \/ _ \ ' \(_-<
  643. // |___/_||_\___/\_/\_/|_| \___/\___/_|_|_/__/
  644. #showrooms{
  645. width: calc(100% + #{$column_goutiere});
  646. article.showroom{
  647. width: $column_width * 2 + $column_goutiere;
  648. display: inline-block;
  649. vertical-align: top;
  650. margin: 0 $column_goutiere $column_goutiere 0;
  651. h1{
  652. margin:0;
  653. font-weight: 4;
  654. }
  655. p{ margin:0; }
  656. figure{
  657. margin:0;
  658. img{
  659. max-width: 100%;
  660. }
  661. }
  662. }
  663. }