diff --git a/README.md b/README.md index 804e0bba..3a3fd9f3 100644 --- a/README.md +++ b/README.md @@ -1,4 +1,4 @@ -# HTML-CSS-Practice-Problems + + + + +# Project Summary + +In this project you will be re-creating multiple html templates using the HTML and CSS skills you have learned so far. There will be 3 levels of difficulty, each being a template and having its own steps to get to the end solution. In each step you will be given a jpeg image that you will need to re-create. Each step will be a continuation of the previous. The goal is to get your project to look as close as you can to the design of the images provided. Good luck! + +## Setup + +* Clone and fork this GitHub Repo +* `cd` into the project directory + +## Important Notes + +* In this repo we include a folder named `base`, leave this folder alone. You will not need to change any code in this folder to complete the project. +* Each level has an `index.html` file, you will use the same `index.html` file for each of the steps in the current level. +* To see your progress right click on the `index.html` file you are currently working on and select `show in finder`. Then double click on the `index.html` file. This should open up a browser tab with what you have so far. + +## Level 1 Step 1 + +### Summary + +In this step, we will create a webpage that has the same structure and styling as the `level-1/step-1/step-1.jpg` image. We will accomplish this by adding some css styles to our webpage. + +### Instructions + +* Open the `level-1` folder and take a look inside. We have folders for steps one through three, a solution folder which is step-4, and an `index.html` file. You will be using the same `index.html` file for all three steps in this level. +* Now open the `step-1` folder and notice that there two items inside. There is a css file named `step-1.css` and an image named `step-1.jpg`. The image in this folder is what you will try to re-create. We will accomplish this by adding some styling in the `step-1.css` file. Ok, lets start styling. + +#### Level 1 Step 1.1 + +In this step, we will position the header at the top of the page. + + * Open `step-1.css`. + * The header automatically gets put at the top of the page because it is the first element on the HMTL file. So we don't need to add styling to the header. + +#### Level 1 Step 1.2 + +In this step, we will try to move box with a class of `content-left` to the left side of the page. + + * Open `step-1.css`. + * Give `.content-left` a css property that will make it float to the left. + * Give `.content-left` a `padding-top: 35px`. The reason we gave the div with a class of `.content-left` a padding on top is that it will have content inside in the future. + *
+ + Solution to Step 1.2 + + ```css + .content-left{ + width: 33.3%; + + height: 100px; + background: #565555; + float: left; + padding-top: 35px; + } + ``` + +
+ +#### Level 1 Step 1.3 + +In this step, we are going to position the box with a class of `content-mid` to line up directly to the right of `.content-left`. + + * Open `step-1.css`. + * Give `.content-mid` a css property that will make it float into the position directly after `content-left`. + *
+ + Solution to Step 1.3 + + ```css + .content-mid { + width: 66.3%; + + height: 100px; + background: #B0B0B0; + float: left; + } + ``` + +
+ +#### Level 1 Step 1.4 + +In this step, we will position the footer at the bottom of the page. + + * Open `step-1.css`. + * Give `.footer` a css property so that it positions itself in relation to its parent and then move it to the lowest point of the parent element. + *
+ + Solution to Step 1.4 + + ```css + .footer { + width: 100%; + height: 100px; + background: #3A3A3A; + position: absolute; + bottom: 0; + } + ``` + +
+ +#### Level 1 Step 1.5 + + * Now all we need to do is change the height and width on the divs so that your webpage looks as close as it can to the `step-1.jpg`. + +### Solution + +
+ + level-1/step-1/step-1.css + +```css +.header { + width: 100%; + height: 100px; + background: #D8D8D8; +} + +.content-left { + width: 33.3%; + height: 76vh; + padding-top: 35px; + float: left; + background: #565555; +} + +.content-mid { + width: 66.66%; + height: 76vh; + float: left; + background: #B0B0B0; +} + +.footer { + width: 100%; + height: 100px; + background: #3A3A3A; + position: absolute; + bottom: 0; +} +``` + +
+ +## Level 1 Step 2 + +### Summary + +In this step, we will create a webpage that has the same structure and styling as the `level-1/step-2/step-2.jpg` image. We will accomplish this by adding more css styles to our webpage. + +### Instructions + +* Now open the `step-2` folder and notice that there two items inside. There is a css file named `step-2.css` and an image named `step-2.jpg`. The image in this folder is what you will try to re-create. We will accomplish this by adding some styling in the `step-2.css` file. Ok, lets start styling. + +#### Level 1 Step 2.1 + +In this step, we will add the first box in the content-left container. + + * Open `step-2.css`. + * Give the `.profile-image-container` a height and a width so you can see it on the webpage. + * Give the `.profile-image-container` a margin so that it is centered. + * Now that the div with the `.profile-image-container` class is centered you can go in and change the height and width to match the `step-2.jpg`. + *
+ + Solution to Step 2.1 + + ```css + .profile-image-container { + width: 80%; + height: 180px; + margin: auto; + background: #96F0F2; + } + ``` + +
+ +#### Level 1 Step 2.2 + +In this step, we will add the second box in the content-left container. + + * Open `step-2.css`. + * Give the div with a class of `.profile-links-container` a height and a width so you can see the element on the webpage. + * Now lets try to give the div with a class of `.profile-links-container` a margin top, left and right all at the same time using the short-hand syntax. + * Now that the div with the `.profile-links-container` class is centered you can go in and change the height and width to match the `step-2.jpg`. + *
+ + Solution to Step 2.2 + + ```css + .profile-links-container { + width: 80%; + height: 300px; + margin: 20px auto; + background: #12F3F7; + } + ``` + +
+ +#### Level 1 Step 2.3 + +In this step, we will add the rectangle in the header and position in correctly to the left side of the webpage. + + * Open `step-2.css`. + * Give the div with a class of `.logo-container` a height and a width so you can see the element on the webpage. + * Now we need to move the element over to the left like you see in `step-2.jpg`. So lets give it a css property that will make it move to the left. + * Now the element is too close to the top-left corner. So lets give it some margin to move it to the correct position. + * The last thing we need to do is fix the height and the width to make our webpage look as close as we can to `step-2.jpg`. + *
+ + Solution to Step 2.3 + + ```css + .logo-container { + width: 26%; + height: 60px; + float: left; + margin-left: 30px; + margin-top: 20px; + background: #4F4949; + } + ``` + +
+ +#### Level 1 Step 2.4 + +In this step, we will add the square in the header and position in correctly to the right side of the webpage. + + * Open `step-2.css`. + * Give the div with a class of `.menu-container` a height and a width so you can see the element on the webpage. + * Now we need to move the element over to the right like you see in `step-2.jpg`. So let's give it a css property to move it to the right. + * Now the element is too close to the top-right corner. So lets give it some margin to position it correctly. + * The last thing we need to do is fix the height and the width to make our webpage look as close as we can to `step-2.jpg`. + *
+ + Solution to Step 2.4 + + ```css + .menu-container { + width: 60px; + height: 60px; + float: right; + margin-right: 10px; + margin-top: 20px; + background: #4F4949; + } + ``` + +
+ +### Solution + +
+ + level-1/step-2/step-2.css + +```css +.logo-container { + width: 26%; + height: 60px; + float: left; + margin-left: 30px; + margin-top: 20px; + background: #4F4949; +} + +.menu-container { + width: 60px; + height: 60px; + float: right; + margin-right: 10px; + margin-top: 20px; + background: #4F4949; +} + +.profile-image-container { + width: 80%; + height: 180px; + margin: auto; + background: #96F0F2; +} + +.profile-links-container { + width: 80%; + height: 300px; + margin: 20px auto; + background: #12F3F7; +} +``` + +
+ +## Level 1 Step 3 + +### Summary + +In this step, we will update our webpage so that it has the same structure and styling as the `level-1/step-3/step-3.jpg` image. We will accomplish this by adding more css styles to our webpage. + +### Instructions + +* Now open the `step-3` folder and notice that there two items inside. There is a css file named `step-3.css` and an image named `step-3.jpg`. The image in this folder is what you will try to re-create. We will accomplish this by adding some styling in the `step-3.css` file. We will also need to add a `

` tag element in the `index.html` file located in the level-1 folder. Ok, lets begin. + +#### Level 1 Step 3.1 + +In this step we will start making the content in the `.mid-content` div by adding a header to it. + + * Open `step-3.css`. + * Lets give the element with a class of `.content-mid-header` a height so it appears like the template image. + * Now our element is showing on the webpage. Good Job! + *
+ + Solution to Step 3.1 + + ```css + .content-mid-header { + background: #444; + height: 100px; + } + ``` + +
+ +#### Level 1 Step 3.2 + +In this step we will add some text inside of our `.content-left` div. + + * Open `index.html`. + * Look for the div with a class of `.content`. It is inside the `.content-left` div. Once you've found it insert a paragraph text inside the div. + *
+ + Solution to Step 3.2 + + ```html +
+

Sed ut perspiciatis unde omnis iste natus error sit voluptatem + accusantium doloremque laudantium, totam rem aperiam, Sed ut perspiciatis unde omnis iste natus error sit voluptatem + accusantium doloremque laudantium, totam rem aperiam,

+
+ ``` + +
+ +#### Level 1 Step 3.3 + +In this step, we will fix the alignment and positioning of the text we added in the previous step. + + * Open `step-3.css` + * Now we can see our text is too close to the borders. Give it some spacing around the edges. There are multiple ways of doing this. + * We should also fix the way the text is aligned. Center the text. + * Lastly our div seems to look a little short. Give it a css property to make it taller. + * Looking a lot better. Let's continue! + *
+ + Solution to Step 3.3 + + ```css + .content { + padding: 50px; + text-align: center; + height: 275px; + } + ``` + +
+ +#### Level 1 Step 3.4 + +In this step, we will changing the size of the container that is housing the content we added in the previous two steps. + + * Open `step-3.css`. + * Give the element with a class of `content-container` a css property that will make it the right width. + * We can also see in the image that this div has to be centered and moved down a bit. Lets accomplish that by giving it a css property that will add spacing on the outside of the div. + *
+ + Solution to Step 3.4 + + ```css + .content-container { + background: #D8D8D8; + width: 80%; + margin: 40px auto; + } + ``` + +
+ * Wow! That looks pretty good. Congratulations you have finished level-1! + +### Solution + +
+ + level-1/step-3/step-3.css + +```css +.content-mid-header { + height: 100px; + background: #444; +} + +.content-container { + width: 80%; + margin: 40px auto; + background: #D8D8D8; +} + +.content { + height: 275px; + padding: 50px; + text-align: center; +} +``` + +
+ +## Level 2 Step 1 + +### Summary + +In this step, we will also be re-creating an image that will be provided to you. We will accomplish this by adding some css styles to our webpage. Good luck! + +### Instructions + +* Open the `level-2` folder and take a look inside. We have folders for two steps, a solution folder which is name `step-3-possible-solution`, and an `index.html` file. You will be using the same `index.html` file for both steps in this level. +* Now open the `step-1` folder and notice that there two items inside. There is a css file named `step-1.css` and an image named `level-2-step-1.jpg`. The image in this folder is what you will try to re-create. We will accomplish this by adding some styling in the `step-1.css` file. Ok, lets start styling. + +#### Level 2 Step 1.1 + +In this step, we will be giving the div with a class of `.main-top-section` a position property that will allow its future child elements to change their position according to it. + + * Open `step-1.css`. + * Give `.main-top-section` a position property of relative. Like this `position: relative`. + * The reason we do this is that future children elements that will use a position of absolute will refer to the first parent with a set position. So we set a position on `.main-top-section` to have it be the parent being referred to. + *
+ + Solution to Step 1.1 + + ```css + .main-top-section { + width: 100%; + height: 375px; + background: #F7F1E7; + position: relative; + } + ``` + +
+ +#### Level 2 Step 1.2 + +In this step, we will be positioning the small menu box in the left hand side of the `level-2-step-1.jpg` image. + + * Open `step-1.css`. + * Let's start by giving `.menu` a property that will make it display side-by-side. + * Next lets give `.menu` a position of absolute. Like this `position: absolute`. This will give you the option to position the `.menu` element according to the first ancestor that has a position. That ancestor will be the `.main-top-section` because we gave it a position of relative in the previous step. + * Now we have the ability to give the `.menu` div a top, right, bottom, and left css property. Give `.menu` two of these css properties to position it correctly. + * Now the `.menu` element is in the correct position. But the other two elements are stacked on top. Let's fix that! + * Let's give `.logo` a css property that will make it display side-by-side. + * Let's also give the element with a class of `.sign-in` a a css property that will make it display side-by-side. + * Now let's give `.sign-in` a css property that will give it a position in relation to its parent. + * Now `.sign-in` can be moved by using top, right, bottom, and left. Use some of these to position it correctly. + * That looks better! + *
+ + Solution to Step 1.2 + + ```css + .menu { + width: 100px; + height: 40px; + background: #536A63; + display: inline-block; + position: absolute; + left: 10px; + top: 10px; + } + + .logo { + width: 300px; + height: 40px; + margin-top: 10px; + background: #536A63; + display: inline-block; + } + + .sign-in { + width: 100px; + height: 40px; + background: #536A63; + display: inline-block; + position: absolute; + right: 10px; + top: 10px; + } + ``` + +
+ +#### Level 2 Step 1.3 + +In this step, we will position the last green element overhanging below its parent element. + + * Open `step-1.css`. + * Now how are we going to move the `.bottom-container` element towards the bottom in reference to its parent? Lets give the element with a class name of `.bottom-container` a position that will move it in relation to its parent. + * Lastly let's give it a bottom and left properties. The bottom property will need to be a negative pixel value so that it is overhangs. + * Looking good! + *
+ + Solution to Step 1.3 + + ```css + .bottom-container { + width: 60%; + height: 60px; + position: absolute; + bottom: -30px; + left: 22%; + background: #536A63; + } + ``` + +
+ +### Solution + +
+ + level-2/step-1/level-1-step-3.css + +```css +.main-top-section { + width: 100%; + height: 375px; + background: #F7F1E7; + position: relative; +} + +.top-header { + width: 100%; + height: 70px; + text-align: center; + background: #D8D8D8; +} + +.menu { + width: 100px; + height: 40px; + display: inline-block; + position: absolute; + left: 10px; + top: 10px; + background: #536A63; +} + +.logo { + width: 300px; + height: 40px; + display: inline-block; + margin-top: 10px; + background: #536A63; +} + +.sign-in { + width: 100px; + height: 40px; + display: inline-block; + position: absolute; + right: 10px; + top: 10px; + background: #536A63; +} + +.bottom-container { + width: 60%; + height: 60px; + position: absolute; + bottom: -30px; + left: 22%; + background: #536A63; +} +``` + +
+ +## Level 2 Step 2 + +### Summary + +In this step, we will also be re-creating an image that will be provided to you. We will accomplish this by adding some css styles to our webpage. Good luck! + +### Instructions + +* Now open the `step-2` folder in level-2 and notice that there two items inside. There is a css file named `step-2.css` and an image named `level-2-step-2.jpg`. The image in this folder is what you will try to re-create. We will accomplish this by adding some styling in the `step-2.css` file. Let's go! + +#### Level 2 Step 2.1 + +In this step, we will be using a css property to align items in the center of the webpage. + + * Open `step-2.css`. + * Give the element with the class name of `main-bottom-section` a property that will center the text inside. + *
+ + level-2/step-1/level-1-step-3.css + + ```css + .main-bottom-section { + margin-top: 65px; + text-align: center; + } + ``` + +
+ +#### Level 2 Step 2.2 + +In this step, we will be adding a width, height and display property to make the small square containers look like the `level-2-step-2.jpg` image. + + * In the `level-2-step-2.jpg` image you can see there are three different types of boxes in the bottom container. The small square, the rectangle, and the big square. + * Lets give each of these their corresponding height and width. + * Open `step-2.css`. + * Starting with the small squares which have a class name of `.item`, lets give them a height and a width. + * But our items are not lined up correctly. Lets give them a property so they display side-by-side. + * Looks perfect! + *
+ + level-2/step-1/level-1-step-3.css + + ```css + .item { + display: inline-block; + height: 200px; + width: 40%; + background: #DED6D3; + margin-bottom: 30px; + } + ``` + +
+ +#### Level 2 Step 2.3 + +In this step, we will be adding a width, height and a margin property to make the rectangle container look like the `level-2-step-2.jpg` image. + + * Open `step-2.css`. + * Now lets focus on the rectangle element with a class of `.full-width-item`. Let's give this element a width and height. + * Now the element is the right size but too close to the surrounding elements. Lets fix that by giving `.full-width-item` a css property of margin with the correct value. Like this `margin 0 auto 30px`. When you give an element a margin property with 3 values it takes the first value as the margin-top the middle value as the left and right margins and the last value as the bottom-margin. + *
+ + level-2/step-2/level-2-step-2.css + + ```css + .full-width-item { + width: 80%; + height: 200px; + margin:0 auto 30px; + background: #DED6D3; + } + ``` + +
+ +#### Level 2 Step 2.4 + +In this step, we will add a height, width and a margin to make the big square look like the `level-2-step-2.jpg` image. + + * Open `step-2.css`. + * On the element with a class name of `.large-item` let's give it a height and with property. + * Again too close to the surrounding elements lets give it some margin. Try to use the short hand syntax. + * Nice! Congratulations you've finished level-2. + *
+ + level-2/step-2/level-2-step-2.css + + ```css + .large-item { + width: 80%; + height: 500px; + margin:0 auto 30px; + background: #DED6D3; + } + ``` + +
+ +### Solution + +
+ + level-2/step-2/level-2-step-2.css + +```css +.main-bottom-section { + margin-top: 65px; + text-align: center; + +} + +.item { + display: inline-block; + height: 200px; + width: 40%; + background: #DED6D3; + margin-bottom: 30px; +} + +.full-width-item { + width: 80%; + height: 200px; + margin:0 auto 30px; + background: #DED6D3; +} + +.large-item { + width: 80%; + height: 500px; + margin:0 auto 30px; + background: #DED6D3; +} +``` + +
+ +## Level 3 Step 1 + +### Summary + +In this step, we will be adding the images and logos to the layout designs that we made in the previous two levels. We'll be combining them to create a one big design. Have fun! + +### Instructions + +* Open the `level-3` folder and take a look inside. We have an `img` folder, folders for three steps, a solution folder which is named `step-4-possible-solution`, and an `index.html` file. You will be using the same `index.html` file for all three steps in this level. +* Check out what's inside the `img` folder. You will be using these images and icons in your webpage. +* Now open the `step-1` folder and notice that there two items inside. There is a css file named `step-1.css` and an image named `level-3-step-1.jpg`. The image in this folder is what you will try to re-create. We will accomplish this by adding some styling in the `step-1.css` file. Ok, lets start styling. + +#### Level 3 Step 1.1 + +In this step, we will be adding a background image to the `main-top-section`. + + * Open `step-1.css`. + * Give the element with a class of `.main-top-section` a background property with a value pointing to the `Background.png` image inside the `img` folder. Like this `background: url("../img/Background.png") no-repeat`. First you set the background to `url()`. Then you used `..` to go up one directory, then `/img` to enter the `img` folder, then `/Background.png` to select the background image file. Then adding `no-repeat` to the back of the url will make the image not repeat. By default the image will repeat to cover the whole page. + * Next let's give the background image a css size property to make it cover the page. + * Looks great! On to the next step. + *
+ + level-2/step-2/level-2-step-2.css + + ```css + .main-top-section { + width: 100%; + height: 530px; + position: relative; + background: url("../img/Background.png") no-repeat; + background-size: cover; + } + ``` + +
+ +#### Level 3 Step 1.2 + +In this step, we will be adding the src path on each of the images in the top half of the webpage. + + * Open `index.html`. + * Find the `` tag with a class of `menu-icon`. + * Give it a src path that will point to `MENU.png` in the `img/icons` folder. + *
+ + Correct src path + + ```html + menu icon + ``` + +
+ * Find the `` tag with a class of `logo-icon`. + * Give it a src path that will point to `dev-shop.png` in the `img/icons` folder. + *
+ + Correct src path + + ```html + logo icon + ``` + +
+ * Find the `` tag with a class of `sign-in-icon`. + * Give it a src path that will point to `Sign_In.png` in the `img/icons` folder. + *
+ + Correct src path + + ```html + sign in  icon + ``` + +
+ * Find the `` tag with a class of `shop-icon`. + * Give it a src path that will point to `Shop_Deals.png` in the `img/icons` folder. + *
+ + Correct src path + + ```html + shop icon + ``` + +
+ +### Solution + +
+ + level-3/index.html + +```html +
+
+ + + + +
+ +
+ + shop icon +
+
+``` + +
+ +## Level 3 Step 2 + +### Summary + +In this step, we will continue to add the images and logos to the layout designs that we made in the previous two levels. We'll be combining them to create a one big design. Good luck! + +### Instructions + +* Now open the `step-2` folder in level-3 and notice that there two items inside. There is a css file named `step-2.css` and an image named `level-3-step-2.jpg`. The image in this folder is what you will try to re-create. We will accomplish this by adding some styling in the `step-2.css` file. Let's go! + +#### Level 3 Step 2.1 + +In this step, we will be adding the src path on each of the images in the bottom half of the webpage. + + * Open `index.html`. + * Find the `` tag with a class of `item-image` that is inside the div with both classes `item tops`. + * Give it a src path that will point to `Tops.png` in the `img` folder. + *
+ + Correct src path + + ```html + tops + ``` + +
+ * Find the `` tag with a class of `item-image` that is inside the div with both classes `item bottoms`. + * Give it a src path that will point to `bottoms.png` in the `img` folder. + *
+ + Correct src path + + ```html + tops + ``` + +
+ * Find the `` tag with a class of `item-image` that is inside the div with both classes `full-width-item accessories`. + * Give it a src path that will point to `accessories.png` in the `img` folder. + *
+ + Correct src path + + ```html + tops + ``` + +
+ * Find the `` tag with a class of `item-image` that is inside the div with a class of `large-item`. + * Give it a src path that will point to `collection.png` in the `img` folder. + *
+ + Correct src path + + ```html + tops + ``` + +
+ * Find the `` tag with a class of `item-image` that is inside the div with both classes `item kicks`. + * Give it a src path that will point to `kicks.png` in the `img` folder. + *
+ + Correct src path + + ```html + tops + ``` + +
+ * Find the `` tag with a class of `item-image` that is inside the div with both classes `item hats`. C + * Give it a src path that will point to `hats.png` in the `img` folder. + *
+ + Correct src path + + ```html + tops + ``` + +
+ +### Solution + +
+ + level-3/index.html + +```html +
+
+ + + + +
+ +
+ + shop icon +
+
+``` + +
+ +## Level 3 Step 3 + +### Summary + +In this step, we will be giving our page a little taste of responsiveness. We will be making our images stop growing at a certain screen width. Lets begin! + +### Instructions + +* Open `index.html`. +* Inside the `` uncomment the link to `step-3.css`, and comment out the links to `step-1.css` and `step-2.css`. +* Now open the `step-3` folder. There is a css file named `step-3.css`. In this css file is where we will try to add media queries to make our webpage responsive. +* Scroll to the bottom of the page and look at the syntax for creating a media query. There are some missing pieces but we'll fill them in step by step. +* Inside the parenthesis `@media( inside here )` is where we will specify the mix or max width the query will start. We will also include the pixel at which the query will start. +Like this `@media(min-width: 900px)`. This means that starting at a minimum width of 900px the following css styles will be activated. +* Now inside there are three css declaration blocks `.item`, `.full-width-item`, and `.large-item`. Inside each of these set a width property with a pixel value. +* After completing the previous step go to your webpage in the browser and make the browser window width as small as you can and then increase it little by little. The images should stop growing at a width of over 900px. +* Great Job! You just made an amazing looking webpage. Congratulations you have finished this project. + *
+ + level-3/step-3/step-3.css + + ```css + @media(min-width: 900px) { + .item { + width:400px; + } + .full-width-item { + width: 800px; + } + .large-item { + width: 800px; + } + } + ``` + +
+ +### Solution + +
+ + level-3/index.html + +```html + + + + + + level-3 + + + + + + + + + + + + + + + + +
+ +
+
+ + + + +
+ +
+ + shop icon +
+
+ +
+ +
+ + + tops + +
+
+ + + tops + +
+ +
+ + + tops + +
+ +
+ + + tops + +
+ +
+ + + tops + +
+
+ + + tops + +
+ +
+ +
+ + +``` + +
+ +
+ + level-3/step-3/step-3.css + +```css + +.main-top-section { + width: 100%; + height: 530px; + position: relative; + background: url("../img/Background.png") no-repeat; + background-size: cover; + +} + + +.top-header { + width: 100%; + padding-top: 10px; + height: 70px; + text-align: center; + +} + + +.menu { + width: 100px; + height: 40px; + display: inline-block; + position: absolute; + left: 10px; + top: 20px; + +} + +.menu-icon { + width: 60%; + +} + +.logo { + width: 300px; + height: 40px; + display: inline-block; + margin-top: 10px; + +} + +.logo-icon { + width: 75%; +} + +.sign-in { + width: 100px; + height: 40px; + display: inline-block; + position: absolute; + right: 10px; + top: 30px; + +} + +.sign-in-icon { + width: 60%; +} + + +.bottom-container { + width: 100%; + height: 60px; + position: absolute; + text-align: center; + bottom: -30px; + +} + + +.shop-icon { + width: 350px; +} + + +.main-bottom-section { + margin-top: 65px; + text-align: center; + +} + +.item { + display: inline-block; + width: 40%; + background: #D6CFC9; + margin-bottom: 20px; + padding-top: 20px; + cursor: pointer; +} + +.item-image { + width: 100%; + display: block; +} + +.full-width-item { + width: 80%; + margin:0 auto 20px; + cursor: pointer; + +} + + +.large-item { + width: 80%; + margin:0 auto 20px; + cursor: pointer; + +} + +@media(min-width: 900px) { + .item { + width:400px; + } + .full-width-item { + width: 800px; + } + .large-item { + width: 800px; + } +} +``` + +
+ +## Contributions + +If you see a problem or a typo, please fork, make the necessary changes, and create a pull request so we can review your changes and merge them into the master repo and branch. ## Copyright © DevMountain LLC, 2016. Unauthorized use and/or duplication of this material without express and written permission from DevMountain, LLC is strictly prohibited. Excerpts and links may be used, provided that full and clear credit is given to DevMountain with appropriate and specific direction to the original content. - +

+ +

diff --git a/level-1/index.html b/level-1/index.html index a59bab53..2978d9e8 100644 --- a/level-1/index.html +++ b/level-1/index.html @@ -54,7 +54,10 @@
- +

Sed ut perspiciatis unde omnis iste natus error sit voluptatem + accusantium doloremque laudantium, totam rem aperiam, Sed ut perspiciatis + unde omnis iste natus error sit voluptatem + accusantium doloremque laudantium, totam rem aperiam,

@@ -68,4 +71,4 @@ - \ No newline at end of file + diff --git a/level-1/step-1/step-1.css b/level-1/step-1/step-1.css index 1c20aa78..f81e0d96 100755 --- a/level-1/step-1/step-1.css +++ b/level-1/step-1/step-1.css @@ -1,37 +1,27 @@ -/* Step-1.1 You don't need to put a position on this element because it is already at the top of the screen */ - .header { width: 100%; height: 100px; background: #D8D8D8; - } -/* Step-1.2 I would suggest using float to get this container in its desired location*/ - .content-left { width: 33.3%; - /*this height is a placeholder. You will need to make some adjustments to get this container to look like the design */ - height: 100px; + height: 76vh; + float: left; background: #565555; } - -/* Step-1.3 I would suggest using float to get this container in its desired location. */ - .content-mid { - width: 66.3%; - /*this height is a placeholder. You will need to make some adjustment to get this container to look like the design */ - height: 100px; + width: 66.66%; + height: 76vh; + float: left; background: #B0B0B0; - } -/* Step-1.4 you're going to want to add a positioning property to get this container to the bottom of the screen */ - .footer { width: 100%; height: 100px; background: #3A3A3A; - -} \ No newline at end of file + position: absolute; + bottom: 0; +} diff --git a/level-1/step-2/step-2.css b/level-1/step-2/step-2.css index e81e4cef..efc58d60 100644 --- a/level-1/step-2/step-2.css +++ b/level-1/step-2/step-2.css @@ -1,28 +1,31 @@ - -/* Step-2.1 One option to align this container to the center would be to give it a margin-left: auto; and margin-right: auto; */ - -.profile-image-container { - background: #96F0F2; -} - -/* Step-2.2 One option to align this container to the center would be to give it a margin-left: auto; and margin-right: auto; */ - -.profile-links-container { - background: #12F3F7; -} - -/* Step-2.3 You can either use float left or position absolute to get this element to in the desired location */ - .logo-container { + width: 26%; + height: 60px; + float: left; + margin-left: 30px; + margin-top: 20px; background: #4F4949; } - -/* Step-2.4 You can either use float left or position absolute to get this element to in the desired location*/ - .menu-container { + width: 60px; + height: 60px; + float: right; + margin-right: 10px; + margin-top: 20px; background: #4F4949; } +.profile-image-container { + width: 80%; + height: 180px; + margin: 35px auto 0 auto; + background: #96F0F2; +} - +.profile-links-container { + width: 80%; + height: 300px; + margin: 20px auto; + background: #12F3F7; +} diff --git a/level-1/step-3/step-3.css b/level-1/step-3/step-3.css index ad33a4c4..6ded5e89 100755 --- a/level-1/step-3/step-3.css +++ b/level-1/step-3/step-3.css @@ -1,17 +1,22 @@ -/* Step-3.1 Not much to do here except add a width */ +/* Step-3.1 Not much to do here except add a height */ .content-mid-header { background: #444; + height: 100px; } /* Step-3.3 add a margin top to give this container some space. Also you're going to want to set the margin-left and margin-right to auto. This will give equal distance left and right to the container--essentially--centering the container */ .content-container { background: #D8D8D8; + width: 80%; + margin: 40px auto; } /* Step-3.2 Remember to add some padding and text-align*/ .content { - + padding: 50px; + text-align: center; + height: 275px; } diff --git a/level-1/step-4-possible-solution/step-3.css b/level-1/step-4-possible-solution/step-3.css index 19f550eb..185ec7fc 100644 --- a/level-1/step-4-possible-solution/step-3.css +++ b/level-1/step-4-possible-solution/step-3.css @@ -11,7 +11,6 @@ .content { height: 275px; - padding:50px; + padding: 50px; text-align: center; - -} \ No newline at end of file +} diff --git a/level-2/step-1/step-1.css b/level-2/step-1/step-1.css index bb1851f8..10fa28d1 100755 --- a/level-2/step-1/step-1.css +++ b/level-2/step-1/step-1.css @@ -24,6 +24,10 @@ width: 100px; height: 40px; background: #536A63; + display: inline-block; + position: absolute; + left: 10px; + top: 10px; } .logo { @@ -31,15 +35,17 @@ height: 40px; margin-top: 10px; background: #536A63; - - + display: inline-block; } .sign-in { width: 100px; height: 40px; background: #536A63; - + display: inline-block; + position: absolute; + right: 10px; + top: 10px; } /* Step-1.3 Make this container overhang off its parent container. */ @@ -47,8 +53,9 @@ .bottom-container { width: 60%; height: 60px; + position: absolute; + bottom: -30px; left: 22%; background: #536A63; - -} \ No newline at end of file +} diff --git a/level-2/step-2/step-2.css b/level-2/step-2/step-2.css index 9f7ccb04..b5f97d69 100755 --- a/level-2/step-2/step-2.css +++ b/level-2/step-2/step-2.css @@ -2,15 +2,15 @@ /* Step-2.1 add a property that will align items in the center */ .main-bottom-section { margin-top: 65px; - /* alignment property */ + text-align: center; } /* Step-2.2 Add a width, height and display property to make these containers look like the design */ .item { - /*width*/ - /*height*/ - /*display*/ + height: 200px; + width: 40%; + display: inline-block; background: #DED6D3; margin-bottom: 30px; } @@ -18,21 +18,18 @@ /* Step-2.3 Add a width, height and margin property to make these containers look like the design. Remember margin: auto is helpful when trying to center a container*/ .full-width-item { - /*width*/ - /*height*/ - /*margin*/ - margin:0 auto 30px; - background: #DED6D3; + width: 80%; + height: 200px; + margin:0 auto 30px; + background: #DED6D3; } /* Step-2.4 Add a width, height and margin property to make these containers look like the design. Remember margin: auto is helpful when trying to center a container*/ .large-item { - /*width*/ - /*height*/ - /*margin*/ + width: 80%; + height: 500px; + margin:0 auto 30px; background: #DED6D3; } - - diff --git a/level-2/step-3-possible-solution/step-1.css b/level-2/step-3-possible-solution/step-1.css index 4df0a29e..b253cada 100755 --- a/level-2/step-3-possible-solution/step-1.css +++ b/level-2/step-3-possible-solution/step-1.css @@ -5,7 +5,6 @@ height: 375px; background: #F7F1E7; position: relative; - } @@ -17,7 +16,7 @@ } /* Step-1.2 You need to get all of these elements to line up side by side. What display property would do this for you? */ -/* Step-1.2 You will also need t add a position property to the logo and sign in the containers */ +/* Step-1.2 You will also need to add a position property to the logo and sign in the containers */ .menu { width: 100px; @@ -60,4 +59,3 @@ background: #536A63; } - diff --git a/level-2/step-3-possible-solution/step-2.css b/level-2/step-3-possible-solution/step-2.css index e5d6f99d..b16830f9 100644 --- a/level-2/step-3-possible-solution/step-2.css +++ b/level-2/step-3-possible-solution/step-2.css @@ -32,5 +32,3 @@ margin:0 auto 30px; background: #DED6D3; } - - diff --git a/level-3/index.html b/level-3/index.html index e55d6f98..1147eddc 100755 --- a/level-3/index.html +++ b/level-3/index.html @@ -8,39 +8,40 @@ - + - + - + +
- +
- shop icon + shop icon
@@ -49,40 +50,40 @@
- tops + tops
- tops + tops
- tops + tops
- tops + tops
- tops + tops
- tops + tops
@@ -90,4 +91,4 @@
- \ No newline at end of file + diff --git a/level-3/step-1/step-1.css b/level-3/step-1/step-1.css index 99a7e981..d908dfa1 100644 --- a/level-3/step-1/step-1.css +++ b/level-3/step-1/step-1.css @@ -4,8 +4,8 @@ width: 100%; height: 530px; position: relative; - - + background: url("../img/Background.png") no-repeat; + background-size: cover; } @@ -73,4 +73,3 @@ .shop-icon { width: 350px; } - diff --git a/level-3/step-3/step-3.css b/level-3/step-3/step-3.css index c064b5f2..0bf201f6 100644 --- a/level-3/step-3/step-3.css +++ b/level-3/step-3/step-3.css @@ -1,4 +1,3 @@ - .main-top-section { width: 100%; height: 530px; @@ -110,25 +109,14 @@ } -/* Set a min-width of 900px inside this media query */ - -@media(/* ADD SOME CODE HERE*/) { - - /* add a different width to these classes to make them look better on larger screens */ - +@media(min-width: 900px) { .item { - /*Add width*/ + width:400px; } - .full-width-item { - /*Add width*/ - + width: 800px; } - - .large-item { - /*Add width*/ - + width: 800px; } } - diff --git a/level-3/step-4-possible-solution/responsive.css b/level-3/step-4-possible-solution/responsive.css index 33422732..434cb2c7 100644 --- a/level-3/step-4-possible-solution/responsive.css +++ b/level-3/step-4-possible-solution/responsive.css @@ -116,15 +116,8 @@ } .full-width-item { width: 800px; - - } - - .large-item { width: 800px; - - } } - diff --git a/level-3/step-4-possible-solution/solution.html b/level-3/step-4-possible-solution/solution.html index bd08e4c5..61618cb4 100644 --- a/level-3/step-4-possible-solution/solution.html +++ b/level-3/step-4-possible-solution/solution.html @@ -90,4 +90,4 @@ - \ No newline at end of file +