Welcome to the Treehouse Community

Want to collaborate on code errors? Have bugs you need feedback on? Looking for an extra set of eyes on your latest project? Get support with fellow developers, designers, and programmers of all backgrounds and skill levels here with the Treehouse Community!

Looking to learn something new?

Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and join thousands of Treehouse students and alumni in the community today.

Start your free trial


CSS problem when working with Foundation

I am creating my own take on the prototype in the Foundation course, but I've come unstuck on what seems a very basic issue. Trying to apply my own styles, my my-styles.css doesn't seem to want to link. I've checked the location of the files, tried a margin left etc and can't get it to apply the styles. My only thought is that Foundation.css is overwriting, but can anyone help?

For CSS I have:

.panel {
    margin: 70px;

For HTML I have:

<html class="no-js" lang="en">
    <meta charset="utf-8" />
    <meta name="viewport" content="width=device-width, initial-scale=1.0" />
    <title>Blooming Big Data</title>
    <link href="css/my-styles.css" rel="stylesheet" type="text/css" media="screen"/>
    <link href="css/foundation.css" rel="stylesheet" media="screen"/>
    <script src="js/modernizr.js"></script>
<!--- Top Bar -->
<div class="contain-to-grid fixed">
  <nav class="top-bar">
    <ul class="title-area">
      <li class="name">
          <a href="#">Blooming Big Data</a>
      <li class="toggle-topbar menu-icon">
        <a href="#"><span>Menu</span></a>
  <section class="top-bar-section"> 
    <ul class="right">
      <li><a href="#">Home</a></li>
      <li><a href="#">About</a></li>
      <li><a href="#">Tools</a></li>
      <li><a href="#">Sign Up</a></li>
<!--- End Top Bar -->
<!--- Headline content -->
<div class="row panel">
  <div class="large-12 columns">
    <h1>This site is dedicated to you.</h1>
    <p class="lead">Yes, you, who loves wrangling with ever-increasing amounts of data but who just every so often feels the need to scream about it.</p>
      <a href="#">Sign Up For <em>DOWN IN THE DATA DUMPS</em></a> 
<!--- End Headline content -->

2 Answers

Rookie, rookie error. Cascading Style Sheets. My-styles.css after foundation.css. (Mod can delete)

James Barnett
James Barnett
39,199 Points

Nice job figuring out your own issue. Rock on :guitar:. Instead of deleting this thread we can leave it so the other's who have the same issue can learn from what you wrote here.

Sander de Wijs
Sander de Wijs
Courses Plus Student 22,267 Points

You can also @import foundation.css at the top of the my-styles.css stylesheet. This way you only have to include my-styles.css in the head section.