]> _ Git - cubedesigners-v7.git/commitdiff
Many changes to make the website more responsive
authorstephen@cubedesigners.com <stephen@cubedesigners.com@f5622870-0f3c-0410-866d-9cb505b7a8ef>
Thu, 8 Jan 2015 10:25:25 +0000 (10:25 +0000)
committerstephen@cubedesigners.com <stephen@cubedesigners.com@f5622870-0f3c-0410-866d-9cb505b7a8ef>
Thu, 8 Jan 2015 10:25:25 +0000 (10:25 +0000)
22 files changed:
framework/application/configs/application.ini
framework/application/layouts/scripts/layout.phtml
framework/application/views/helpers/AgencyBlocs.php
framework/application/views/helpers/AgencyPictos.php
framework/application/views/helpers/HomeBlocs.php
framework/application/views/helpers/Liste.php
framework/application/views/helpers/Twocols.php
framework/application/views/scripts/common/footer.phtml
framework/application/views/scripts/common/header.phtml
framework/application/views/scripts/templates/agence.phtml
framework/application/views/scripts/templates/expertises.phtml
js/common.js
js/taglist.js
less/agence.less
less/common.less
less/expertises.less
less/footer.less
less/header.less
less/list.less
less/mixins.less
less/realisation.less
less/twocols.less

index bfdf04b3158f5d6d1cd626903b107b67c59cd35c..e0636967ce9eb42ebb331619aae7e4e7d487ad51 100644 (file)
@@ -56,7 +56,7 @@ database.params.dbname = cubev6dev
 locales.fr = dev.cubedesigners.fr
 locales.en = dev.cubedesigners.com
 
-httpauth.username = cubedesigners
-httpauth.password = cubedesigners
+;httpauth.username = cubedesigners
+;httpauth.password = cubedesigners
 
 webhost = dev.cubedesigners.fr
\ No newline at end of file
index 31b4eda6a51bcc6ab66d0a333237aa45f6228de9..5e3b97cf67bf3c6024758c2793eaccbdd01d5467 100644 (file)
@@ -11,7 +11,7 @@ $this->headScript()->addIEConditionnals();
 $this->headScript()->appendFile('/js/common.js');
 $this->headLink()->appendStylesheet('/less/common.less', 'all');
 
-$this->headMeta()->setViewport(1080);
+$this->headMeta()->setViewport('device-width', null, '1.0');
 
 profile(__FILE__, __LINE__, 'Before rendering body');
 $res = $this->htmlPage($this->render('common/body.phtml'));
index f7c13a0aeabcb02589b405aac54eecadab44c0ca..c2298717138ecaa197ee864b9c36e9e623781c6e 100644 (file)
@@ -20,10 +20,11 @@ class Cubedesigners_View_Helper_AgencyBlocs extends Zend_View_Helper_Abstract {
 
                        $res.='<div class="sousbloc" itemscope itemtype="http://schema.org/Person">';
                        $res.='<span style="background:url(\'' . $image . '\') no-repeat" class="photo" itemprop="image"></span>';
-                       $res.='<h3 itemprop="name">' . $bloc['titre'] . '</h3>';
+                       $res.='<div class="details">';
+            $res.='<h3 itemprop="name">' . $bloc['titre'] . '</h3>';
                        $res.='<span class="poste" itemprop="jobTitle">' . $bloc['poste'] . '</span>';
                        $res.= $this->view->markupDotclear($bloc['texte'], array('class' => 'texte'));
-                       $res.='</div>';
+                       $res.='</div></div>';
 
                        $i++;
                }
index 4b62dc3b6b2b7f7246ed0ede4e26421b547e99f6..e3e4c728bbb1e468354efc3f8e68afad03624e25 100644 (file)
@@ -12,10 +12,6 @@ class Cubedesigners_View_Helper_AgencyPictos extends Zend_View_Helper_Abstract {
 \r
         foreach ($blocs as $id => $bloc) {\r
 \r
-            if (($i % 3) == 0 && $i != 0) {\r
-                $res.='<div class="spacer"></div>';\r
-            }\r
-\r
             $image = $this->view->imageCms($bloc['picto'], '', 70, 70, array());\r
 \r
             $res .= '<article>';\r
index 25dbe56fcff4335d9701e04f5e9dccff81a186d0..d3ec6bfc9433f92e84d167aabb04c27141403e0e 100644 (file)
@@ -9,11 +9,11 @@ class Cubedesigners_View_Helper_HomeBlocs extends Zend_View_Helper_Abstract {
                $res = '';
                $i = 0;
                foreach ($blocs as $bloc) {
-                       if ($cols == 2) {
-                               if (($i % 2) == 0 && $i != 0) {
-                                       $res.='<div class="spacer"></div>';
-                               }
-                       }
+//                     if ($cols == 2) {
+//                             if (($i % 2) == 0 && $i != 0) {
+//                                     $res.='<div class="spacer"></div>';
+//                             }
+//                     }
                        $image = $this->view->imageCms($bloc['picto'], $bloc['titre'], 120, 120);
                        $res .= '<article class="sousbloc">';
                        $res.= $image;
index 21e316be1d6921a328e48f2a9dd9dcab25a74644..26cbb9fdc90adfed8efb9275914ff3d4b99375f8 100644 (file)
@@ -8,7 +8,7 @@ class Cubedesigners_View_Helper_Liste extends Zend_View_Helper_Abstract {
                $attrs = array_merge($defaultAttrs, $attrs);
 
                $this->view->headLink()->appendStylesheet('/less/list.less');
-               $res = '<div class="bloc-holder">';
+               $res = '<div class="bloc-holder content">';
                if ($items['titre']) {
                        $res.='<h2>' . ucfirst($items['titre']) . '</h2>';
                }
index 4688d08545ccebf34a9ec0627cb3145d5853177d..b63871148fe6a8b70594694f8d687810ee5ff329 100644 (file)
@@ -4,10 +4,11 @@ class Cubedesigners_View_Helper_Twocols extends Zend_View_Helper_Abstract {
 
        public function twocols($displayTitle = true) {
                $this->view->headLink()->appendStylesheet('/less/twocols.less');
-               $res = '<div class="twocols">';
+               $res = '<div class="twocols content">';
                $res.='<section>';
                if ($displayTitle && trim($this->view->titre)) {
-                       $res.= '<div class="title">' . $this->view->markupDotclear($this->view->titre) . '</div>';
+                       // Replacing <br /> tags with normal line breaks to allow for more flexible styling via CSS white-space
+            $res.= '<div class="title">' . str_replace('<br />', "\n", $this->view->markupDotclear($this->view->titre)) . '</div>';
                }
                $res.='<div class="cols">';
                $res.='<div class="col">' . $this->view->markupDotclear($this->view->colonnegauche) . '</div>';
index cbc43a8987e21c46f8bf1d781200cfb29d07f41b..f9679d400b6ddbb36dd35099d26b2c7e3052485e 100644 (file)
@@ -11,7 +11,7 @@ echo $this->clear();
 <footer id="footer">
        <div class="footer-holder">
                <div class="footer-top">
-                       <div class="footer-top-content">
+                       <div class="footer-top-content content">
                                <div class="bloc">
                                        <h2><?php echo __("Nous contacter"); ?></h2>
                                        <?php echo $this->footerContact($this->option('contact')); ?>
index 919e9c6f25a01f0f2ba75769b3c8c7f284707974..eb348f180bcff882ed65f33bab9adda182f0e183 100644 (file)
@@ -19,7 +19,10 @@ if (!is_null($homepage)) {
                }
                /* NAVIGATION */
                $mainMenu = $this->navigation()->findOneById($this->localeDefault() . '/' . CubeIT_Navigation::MAIN);
-               echo $this->navigation()->menu()->renderMenu($mainMenu, array('maxDepth' => 0)) . "\n";
+               echo '<a href="#menu" class="menu-link">&#9776;</a>';
+        echo '<nav id="menu" role="navigation">';
+        echo $this->navigation()->menu()->renderMenu($mainMenu, array('maxDepth' => 0)) . "\n";
+        echo '</nav>';
                ?>
     </div>
 </header>
\ No newline at end of file
index 200d1e6057a40befc1fde01ccc3e910e9ae47c1c..bfa2c39824ff14278c8908f9aeed18bcfaf3abe7 100644 (file)
@@ -4,7 +4,7 @@ $this->headScript()->addScriptAndStyle('slideshow');
 echo $this->twocols();
 ?>
 <div class="agency-pictos">
-       <div class="bloc-holder">
+       <div class="bloc-holder content">
                <?php echo $this->agencyPictos($this->pictos); ?>
        </div>
 </div>
@@ -12,7 +12,7 @@ echo $this->twocols();
 <div class="agency-photo"><?php echo $this->imageSlideshowContinuous($this->photo, 650, array(), array('arrowspermanent' => 1)); ?></div>
 
 <section class="agency-persons">
-       <div class="bloc-holder">
+       <div class="bloc-holder content">
                <h2><?php echo ucfirst($this->equipe['titre']); ?></h2>
                <?php echo $this->agencyBlocs($this->equipe); ?>
        </div>
index 16ccdb79cc2ac4b775fa5403b5a2964afbe720cf..1970ada03ca345df486cf952df4ed5b80e5a5755 100644 (file)
@@ -2,5 +2,5 @@
 
 $this->headScript()->addScriptAndStyle('expertises');
 echo $this->twocols();
-echo $this->htmlElement(nl2br($this->citation), 'blockquote', array('class' => 'citation'));
+echo $this->htmlElement($this->citation, 'blockquote', array('class' => 'citation'));
 echo $this->liste($this->expertises, true, array('id' => 'expertises'));
index 49565f8c2e38a8976ba3e1bb37b8cec5c36fa2a2..7ab2b2078f66ce02b5d0322b409826e93bd74a37 100644 (file)
@@ -3,12 +3,41 @@ registerLoader(load_commons);
 function load_commons() {
        $(window).on('cubeitresize', resize);
        resize();
+
+    $(window).on('orientationchange', orientationchange);
+    orientationchange();
+
+    var $menu = $('#menu'),
+        $menulink = $('.menu-link');
+
+    $menulink.click(function() {
+        $menulink.toggleClass('active');
+        $menu.toggleClass('active');
+        //$menulink.parent().toggleClass('menu-active');
+        return false;
+    });
+
 }
 
 function resize() {
-       if ($(window).width() < 1020) {
-               $("html").addClass('small');
-       } else {
-               $("html").removeClass('small');
-       }
+
+    //var ww = window.innerWidth || document.documentElement.clientWidth || document.body.clientWidth;
+    //
+    //
+       //if (ww < 1040) {
+       //      $("html").addClass('small');
+       //} else {
+       //      $("html").removeClass('small');
+       //}
+
+}
+
+function orientationchange() {
+
+    if(Modernizr.mq('screen and (max-device-width: 530px)')) {
+        //alert('mobile');
+        $("[name='viewport']").attr("content", "width=530, initial-scale=1.0");
+    } else {
+        $("[name='viewport']").attr("content", "width=device-width, initial-scale=1.0");
+    }
 }
\ No newline at end of file
index 8191752731e5fdae1c493b73a252fcba0472f1aa..6b9bb986e93155364053e9f282f3feeb039a397b 100644 (file)
                                //              }
                        });
 
+            // Reveal all items after init for onload animation
+            // https://github.com/metafizzy/isotope/issues/733#issuecomment-52868221
+            //var iso = this.container.data('isotope');
+            //this.container.isotope( 'reveal', iso.items );
+
                        // Also handle resizing of the window
                        $(window).on('cubeitresize', function () {
                                $this.resize();
                },
                resize: function () {
 
-                       fb('Running resize...');
+                       //fb('Running resize...');
 
                        var container = this.container
                        var margin = this.gutter;
                        var naturalWidth = this.columnWidth;
                        var scaleFactor = 1;
 
-                       var ww = Math.min($(window).width(), 980);
+                       var ww = Math.min($(window).width(), 1048);
+
+            ww -= 68; // Remove margins
 
                        // Handle extra padding that is added for small screens
-                       if ($('html').hasClass('small')) {
-                               //ww = ww - parseInt($('#main .content').css('paddingLeft')) - parseInt($('#main .content').css('paddingRight'));
-                               ww = ww - 40;
-                       }
+                       //if ($('html').hasClass('small')) {
+                       //      ww = ww - parseInt($('#main .content').css('paddingLeft')) - parseInt($('#main .content').css('paddingRight'));
+                       //      ww = ww - 68;
+                       //}
 
                        var nbcol = Math.ceil(ww / (naturalWidth + margin));
                        var ew = Math.floor((ww - (margin * (nbcol - 1))) / nbcol);
index 9726aef91e1ddc5d5a00bf854e56dac99d656038..0a4138f97cabc9e73d2cd360dc10bb8cdd917ca7 100644 (file)
@@ -1,40 +1,78 @@
+@import "mixins";
+
+@twocols : ~"screen and (max-width: 955px)";
+@onecol : ~"screen and (max-width: 700px)";
+
+
+.agency-pictos {
+  /* Agence pictos */
+  .bloc-holder {
+    //    min-width: 980px;
+    //    max-width: 980px;
+    //    width:100%;
+    //    margin: 0 auto;
+    padding-bottom: 25px;
+    margin-top: -25px;
+    overflow: hidden;
+    //    text-align: center;
+  }
+
+  .bloc-holder h2 {
+    font-weight: 300;
+    font-size: 32px;
+  }
+
+  article {
+    display: inline-block;
+    vertical-align: top;
+    width: 33%;
+//    min-width: 290px;
+    padding-right: 20px;
+    margin: 25px 0;
+    text-align: left;
 
-/* Agence pictos */
-.agency-pictos .bloc-holder {
-    min-width: 980px;
-    max-width: 980px;
-    width:100%;
-    margin: 0 auto;
-    padding: 0 0 50px 0;
-    overflow:hidden;
-}
+    @media @twocols {
+      width: 50%;
 
-.agency-pictos .bloc-holder h2 {
-    font-weight: 300;
-    font-size:32px;
-}
+      &:nth-child(even) {
+        padding-left: 20px;
+        padding-right: 0;
+      }
+    }
+    @media @onecol {
+      width: 100%;
+      padding: 0 !important; // Override nth-child (Vincent's brilliant idea :))
+    }
+  }
 
-.agency-pictos .bloc-holder .sousbloc {
-    float:left;
-    //width:50%;
-    width:30%;
-    margin-right: 20px;
-}
+  .sousbloc {
 
-.agency-pictos .bloc-holder .blocs .spacer {
-    clear:left;
-    padding:25px 0;
-}
+    &:extend(.media);
+
+    //float: left;
+
+  }
+
+  .spacer {
+    //    clear:left;
+    //    padding:25px 0;
+    display: none;
+  }
+
+  .dotclear {
 
-.agency-pictos .bloc-holder .dotclear {
-    height:70px;
+    &:extend(.media--body);
+
+    height: 70px;
     display: table-cell;
     vertical-align: middle;
-}
+  }
 
-.agency-pictos .bloc-holder .sousbloc img {
-    float:left;
-    padding-right: 20px;
+  .sousbloc img {
+    //float:left;
+    &:extend(.media--item);
+    margin-right: 20px;
+  }
 }
 
 /* Agence photo */
     color:#fff;
 
     .bloc-holder {
-        min-width: 980px;
-        max-width: 980px;
-        width:100%;
-        margin: 0 auto;
-        padding: 50px 0;
+        //min-width: 980px;
+        //max-width: 980px;
+        //width:100%;
+        //margin: 0 auto;
+        padding-top: 50px;
+        padding-bottom: 25px;
         overflow:hidden;
     }
 
-    .bloc-holder h2  {
+    h2  {
         font-size:56px;
     }
 
-    .bloc-holder h3{
+    h3{
         font-size:32px;
         padding: 0 0 20px 0;
     }
 
-    .bloc-holder .blocs {
-        padding: 40px 0;
+    .blocs {
+        padding: 40px 0 0 0;
+        margin-top: -25px;
     }
 
-    .bloc-holder .blocs .spacer {
-        clear:left;
-        padding:25px 0;
+    .spacer {
+//        clear:left;
+//        padding:25px 0;
+      display: none;
     }
 
-    .bloc-holder .sousbloc {
-        float:left;
-        //width:50%;
-        width: 47.5%;
-        margin-right: 20px;
-    }
+    .sousbloc {
 
-    .bloc-holder .sousbloc .texte {
-        width: 60%;
-        float:left;
+        &:extend(.media);
+
+        display: inline-block;
+        vertical-align: top;
+        width:50%;
+        min-width: 480px;
+        padding-right: 25px;
+        margin: 25px 0;
     }
 
-    .bloc-holder .sousbloc .photo {
+//    .bloc-holder .sousbloc .texte {
+//        width: 60%;
+//        float:left;
+//    }
+
+    .photo {
+
+        &:extend(.media--item);
+
         width:120px;
         height:120px;
         float:left;
         margin: 10px 25px 0 0;
         border-radius: 60px;
     }
+
+    .details {
+        &:extend(.media--body);
+
+        text-align: left;
+    }
 }
index 5e53350c6ee94036dfd6f7a20ccc54a165942abb..5111ced80709c33e1e8f5a106862ed1b66f8641b 100644 (file)
@@ -1,17 +1,33 @@
 @roboto: 'Roboto Condensed', sans-serif;
 
+/* apply a natural box layout model to all elements, but allowing components to change */
+/* Reference: http://www.paulirish.com/2012/box-sizing-border-box-ftw/ */
+html {
+  box-sizing: border-box;
+}
+*, *:before, *:after {
+  box-sizing: inherit;
+}
+
+
 .content,.cubeit-content{
-       max-width:980px;
+       max-width: 1048px; // = 980+(34*2) - Allow room for the 34px padding on each side
        margin:0 auto;
+    padding: 0 34px;
        position:relative;
-}
 
-.small{
-       .content,.cubeit-content{
-               padding:0 20px;
-       }
+//    @media screen and (max-width: 980 + (34*2)px) {
+//      padding: 0;
+//      margin: 0 34px;
+//    }
 }
 
+//.small{
+//     .content,.cubeit-content{
+//             margin:0 20px;
+//     }
+//}
+
 
 body {
        font-family: @roboto;
@@ -96,6 +112,11 @@ a.but {
                text-align: left;
                font-size: 22px;
                line-height: 25px;
+        white-space: pre-line; // Preserve line breaks from content
+
+        @media screen and (max-width: 980px){
+          white-space: normal;
+        }
        }
 }
 
index bd9c0c45cec50df2e192ce7fb56e4a40da812179..d18cc0b87ddc2a76541dc606eacbfd5b52367073 100644 (file)
@@ -4,6 +4,11 @@ blockquote.citation{
        color:#3885e0;
        line-height: 37px;
        text-align: center;
-       width:980px;
        margin:-20px auto 50px;
+    white-space: pre-line;
+
+    @media screen and (max-width: 1048px){
+      white-space: normal;
+      width: 85%;
+    }
 }
\ No newline at end of file
index 8e7a8b0e87066fa2c0e4458d119df3348f3e65c3..95cb7784244ad66577ee82122390c3cff3aa7b19 100644 (file)
@@ -3,58 +3,80 @@
                padding:50px 0 0 0;
                background-color: #282828;
                .footer-top-content {
-                       width:980px;
-                       margin: 0 auto;
+//                     max-width:980px;
+//                     margin: 0 auto;
                        overflow: hidden;
                        padding-bottom:50px;
                        white-space:nowrap;
                        .bloc {
-                               display: inline-block;
+//                             display: inline-block;
+                float: left;
                                white-space: normal;
                                vertical-align:top;
-                               width:470px;
-                               margin:0 40px 0 0;
-
-                               h2 {
-                                       color:#fff;
-                                       font-size:56px;
-                                       line-height: 45px;
-                                       padding:0 0 50px 0;
-                               }
-
-                               .social{
-                                       h2{
-                                               padding:0 0 25px 0;
-                                       }
-                               }
-
-                               .actus{
-                                       height:366px;
-                                       .actu {
-                                               color:#6c6c6c;
-                                               padding-bottom: 20px;
-
-                                               a{
-                                                       color:#6c6c6c;
-                                               }
-
-                                               h3 {
-                                                       width:90%;
-                                                       font-size:16px;
-                                                       line-height:20px;
-                                               }
-
-                                               &:last-child {
-                                                       padding-bottom: 0;
-                                               }
-                                               .date {
-                                                       font-size:12px;
-                                               }
-                                       }
-                               }
-                               &:last-child{
-                                       margin-right: 0;
-                               }
+                               width: 50%;
+                               padding:0 20px 0 0;
+
+                &:last-child {
+                  padding-right: 0;
+                  padding-left: 20px;
+                }
+
+                @media screen and (max-width: 1000px) {
+                  width: 100%;
+                  padding: 0 0 40px 0;
+
+                  &:last-child {
+                    padding: 0;
+                  }
+                }
+
+              h2 {
+                  color:#fff;
+                  font-size:56px;
+                  line-height: 45px;
+                  padding-bottom: 50px;
+
+                  @media screen and (max-width: 1000px) {
+                    padding-bottom: 30px;
+                  }
+                }
+
+              .social{
+                  h2{
+                      padding:0 0 25px 0;
+                    }
+                }
+
+              .actus{
+                  padding-bottom: 40px;
+
+                @media screen and (min-width: 980px) {
+                  min-height: 356px;
+                }
+
+                  .actu {
+                      color:#6c6c6c;
+                      padding-bottom: 20px;
+
+                      &:last-child {
+                        padding-bottom: 0;
+                      }
+
+                      a{
+                          color:#6c6c6c;
+                        }
+
+                      h3 {
+                          width: 90%;
+                          font-size: 16px;
+                          line-height: 20px;
+                        }
+
+                      .date {
+                          font-size: 12px;
+                      }
+                  }
+              }
                        }
                }
        }
                padding-bottom: 50px;
        }
        .bureau {
-               display:inline-block;
-               width: 214px;
+               //display:inline-block;
+        float: left;
+               width: 50%;
                vertical-align: top;
                color:#6c6c6c;
-               margin:0 42px 0 0;
-               &:last-child{
-                       margin-right: 0;
+               padding-right: 21px;
+
+        &:last-child{
+                       padding-right: 0;
+            padding-left: 21px;
                }
 
+        @media screen and (max-width: 1000px) {
+          width: auto;
+          float: none;
+          display: inline-block;
+          padding: 0 0 20px 0;
+          margin-right: 40px;
+
+          &:last-child {
+            padding: 0;
+            margin: 0;
+          }
+        }
 
                .titre,.numeros {
                        padding-bottom: 20px;
        }
        .footer-bottom {
                background-color: #191919;
-               height: 30px;
+               height: 46px;
                color: #6c6c6c;
                text-align: left;
                font-size: 12px;
-               line-height: 30px;
-               padding:8px 0;
+               line-height: 46px;
 
                .copyright{
                        display:inline-block;
index f6a872305f894ecd950b6a4d5d36710623e7c4fe..b61c6340381bd65a604466665f78c14ed26dadbc 100644 (file)
@@ -32,8 +32,8 @@
                width:318px;
                height:132px;
                position:absolute;
-               top:-1px;
-               left:-34px;
+               top: 0;
+               left: 0;
 
                &:hover{
                        .svg{
                }
        }
 }
+
+////////////////////////
+// @TODO tidy this up...
+
+a.menu-link {
+  display: none;
+
+  &:hover {
+    color: #84ae1e;
+  }
+}
+.js nav[role=navigation] {
+  max-height: none;
+}
+
+@media screen and (max-width: 890px) {
+
+  #header.content {
+    padding: 0;
+  }
+
+  #header {
+    height: auto;
+    min-height: 130px;
+  }
+
+  nav[role=navigation] {
+    background-color: #202020;
+    //margin: 0 -20px; // To offset the 20px margin from .content
+  }
+
+  a.menu-link {
+    position: absolute;
+    top: 0;
+    right: 5%;
+    padding: 0.5em;
+//    background: #3885e0;
+//    border-radius: 2px;
+    font: bold 36px sans-serif;
+    color: #3885e0;
+    text-transform: uppercase;
+    display: inline-block;
+  }
+  nav[role=navigation] {
+    clear: both;
+    transition: all 0.3s ease-out;
+  }
+  .js nav[role=navigation] {
+    overflow: hidden;
+    max-height: 0;
+  }
+  nav[role=navigation].active {
+    max-height: 16em;
+    padding: 135px 0 20px 0;
+    box-sizing: content-box;
+  }
+  #header .navigation {
+    margin: 0;
+    padding: 0;
+    float: none;
+    text-align: center;
+
+    li {
+      float: none;
+      margin: 0;
+    }
+
+    a {
+      color: #fff !important;
+      display: block;
+    }
+  }
+
+}
index 19269dce9bfadad832f6abcbac8b2089a467b864..8865807bc4b2e2a1f532fa2104cd8dd44a602067 100644 (file)
@@ -1,3 +1,5 @@
+@import "mixins";
+
 section.list{
 
        &#agency,&#expertises{
@@ -16,12 +18,13 @@ section.list{
 
 
        .bloc-holder {
-               min-width: 980px;
-               max-width: 980px;
-               width:100%;
-               margin: 0 auto;
-               padding: 50px 0;
-               overflow:hidden;
+//             min-width: 980px;
+//             max-width: 980px;
+//             width:100%;
+//             margin: 0 auto;
+        padding-top: 50px;
+        padding-bottom: 50px;
+        overflow:hidden;
                h2  {
                        font-size:56px;
                }
@@ -39,37 +42,63 @@ section.list{
                        padding: 40px 0;
                        overflow:hidden;
 
-                       .spacer {
-                               clear:left;
-                               padding:25px 0;
-                       }
+//                     .spacer {
+//                             clear:left;
+//                             padding:25px 0;
+//                     }
 
                        &.two{
-                               white-space:nowrap;
+                               //white-space:nowrap;
+                margin-bottom: -50px; // Offset the 50px margins on the .sousbloc
+
                                .sousbloc{
                                        white-space: normal;
-                                       width:470px;
-                                       margin:0 40px 0 0;
-                                       .text{
-                                               width:325px;
-                                       }
+                                       width: 50%;
+                                       padding-right: 20px;
+                    margin-bottom: 50px;
+
+                    &:nth-of-type(2n) {
+                      padding-right: 0;
+                      padding-left: 20px;
+                    }
+
+                  @media screen and (max-width: 990px){
+                    display: block;
+                    width: 100%;
+
+                    &:nth-of-type(2n) {
+                      padding: 0;
+                    }
+                  }
                                }
                        }
 
                        .sousbloc {
-                               display:inline-block;
-                               widows: 980px;
+                               display: inline-block;
+                vertical-align: top;
+                               //width: 980px;
                                margin:0 0 50px 0;
+                //float: left;
+
+                &:extend(.media);
 
                                .text {
-                                       display: inline-block;
-                                       width:835px;
-                                       vertical-align: top;
+
+                    &:extend(.media--body);
+//                                     display: inline-block;
+//                                     width:835px;
+//                                     vertical-align: top;
+//                    overflow: hidden; // Stop text wrapping under img
                                }
                                img {
-                                       display: inline-block;
-                                       margin:0 25px 0 0;
-                                       vertical-align: top;
+
+                    &:extend(.media--item);
+
+//                                     display: inline-block;
+//                                     margin:0 25px 0 0;
+//                                     vertical-align: top;
+//                    float: left;
+//                    margin-right: 25px;
                                }
                        }
                }
index e69de29bb2d1d6434b8b29ae775ad8c2e48c5391..058487a32905b883e720b9ac085968392b911b07 100644 (file)
@@ -0,0 +1,40 @@
+/*\r
+\r
+REMOVED FOR NOW - too much refactoring required to apply this neatly...\r
+\r
+// Ideas from: http://ianstormtaylor.com/oocss-plus-sass-is-the-best-way-to-css/\r
+// Modified to suit LESS...\r
+\r
+// Abstract media object - extended by other classes\r
+.media {\r
+  overflow: hidden;\r
+\r
+  // Extra modification: the ">" is needed so it doesn't keep applying to\r
+  // nested elements - just want the first level\r
+  // Alternatively, this would need to be broken down (eg. .media, .media--item, .media--body and applied separately to individual selectors\r
+  &> :first-child {\r
+    float: left;\r
+    margin-right: 25px; // Default spacing\r
+  }\r
+\r
+  &> :last-child {\r
+    overflow: hidden;\r
+  }\r
+}\r
+\r
+*/\r
+\r
+// PLAN B:\r
+\r
+.media {\r
+  overflow: hidden;\r
+}\r
+\r
+.media--item {\r
+  float: left;\r
+  margin-right: 25px;\r
+}\r
+\r
+.media--body {\r
+  overflow: hidden;\r
+}
\ No newline at end of file
index dfd833307051c8c273cde5b1016a36205c7bb058..17276bdde157cd4759224baa99f2a05c91d51cbc 100644 (file)
@@ -24,7 +24,7 @@
                .close {
                        display: inline-block;
                        position: absolute;
-                       right: 0;
+                       right: 34px;
                        top: 50%;
                        margin-top: -13px; // Half of line-height to position vertically in the centre
                        background-image: url(../images/close-portfolio.png);
index 7949ddfaa7875cbbb14f700794b57db6132a0a38..28d9f9a097f95a81c542f9a86f13ca401f5eceb8 100644 (file)
@@ -1,35 +1,54 @@
 .twocols{
-       .dotclear{
-               p{
-                       margin:30px 0 30px 0;
-               }
 
-               ul{
-                       margin:15px 0 30px 0;
-                       list-style: none;
-                       li{
-                               &:before{
-                                       content:"- ";
-                               }
-                       }
-               }
-       }
+  max-width: 980px;
+  margin: 0 auto;
+
+  .dotclear{
+      p{
+          margin:30px 0 30px 0;
+        }
+
+      ul{
+          margin:15px 0 30px 0;
+          list-style: none;
+          li{
+              &:before{
+                  content:"- ";
+                }
+            }
+        }
+    }
 
-       width: 980px;
-       margin: 0 auto;
        .cols {
-               padding: 0 0 50px 0;
+        padding-bottom: 50px;
                white-space:nowrap;
 
                .col {
                        white-space: normal;
                        display:inline-block;
-                       width:470px;
-                       margin:0 40px 0 0 ;
+                       width: 50%;
+                       padding-right: 20px;
                        vertical-align: top;
+            
                        &:last-child{
-                               margin:0;
+                               padding-right:0;
+                padding-left: 20px;
                        }
                }
+
+        @media screen and (max-width: 790px) {
+
+          padding-bottom: 10px;
+
+          .col {
+            width: 100%;
+            padding: 0;
+            display: block;
+
+            &:last-child {
+              padding: 0;
+            }
+          }
+        }
        }
 }
\ No newline at end of file