source code CSS#1

CSS#1

/* Base styles */

a strong {
    colorinherit;
  }
  
  hr {
    backgroundnone;
    bordernone;
    border-bottom1px solid #d8dee9;
  }
  
  img {
    heightauto;
    max-width100%;
  }
  
  pre {
    overflowauto;
    white-spacepre-wrap;
  }
  
  footer {
    align-itemscenter;
    displayflex;
    justify-contentcenter;
    margin-top4em;
    text-aligncenter;
  }
  
  /* 01 Centering */
  
  header,
  main {
    margin0 auto;
    max-width50em;
  }
  
  /* 02 Font family */
  
  body {
    font-family"Helvetica""Arial"sans-serif;
  }
  
  /* 03 Spacing */
  
  body {
    line-height1.5;
    padding4em 1em;
  }
  
  h2 {
    margin-top1em;
    padding-top1em;
  }
  
  /* 04 Color and contrast */
  
  body {
    color#555;
  }
  
  h1,
  h2,
  strong {
    color#333;
  }
  
  /* 05 Balance */
  
  code,
  pre {
    background#eee;
  }
  
  code {
    padding2px 4px;
    vertical-aligntext-bottom;
  }
  
  pre {
    padding1em;
  }
  
  /* 06 Primary color */
  
  a {
    color#e81c4f;
  }
  
  /* 07 Secondary colors */
  
  body {
    backgroundwhite;
    color#566b78;
  }
  
  code,
  pre {
    background#f5f7f9;
    border-bottom1px solid #d8dee9;
    color#a7adba;
    -moz-font-smoothinggrayscale;
    -webkit-font-smoothinginitial;
  }
  
  pre {
    border-left2px solid #69c;
  }
  
  .selector {
    color#ec5f67;
  }
  
  .keyword {
    color#ab7967;
  }
  
  .unit {
    color#fac863;
  }
  
  .attribute {
    color#5fb3b3;
  }
  
  .number {
    color#f99157;
  }
  
  .string {
    color#c594c5;
  }
  
  /* 08 Custom font */
  
  body {
    font-family"Roboto""Helvetica""Arial"sans-serif;
    -moz-font-smoothinggrayscale;
    -webkit-font-smoothingantialiased;
  }
  
  h1,
  h2,
  strong {
    font-weight500;
  }
  
  /* 09 Images */
  
  body {
    margin0;
    padding0;
  }
  
  main {
    padding4em 1em;
  }
  
  header {
    background-color#263d36;
    background-imageurl("header.jpg");
    background-positioncenter top;
    background-repeatno-repeat;
    background-sizecover;
    line-height1.2;
    max-widthnone;
    padding10vw 2em;
    text-aligncenter;
  }
  
  #logo {
    displayinline-block;
    height120px;
    vertical-aligntop;
    width120px;
  }
  
  header h1 {
    colorwhite;
    font-size2.5em;
    font-weight300;
  }
  
  header a {
    border1px solid #e81c4f;
    border-radius290486px;
    colorwhite;
    font-size0.6em;
    letter-spacing0.2em;
    padding1em 2em;
    text-transformuppercase;
    text-decorationnone;
    transitionnone 200ms ease-out;
    transition-propertycolorbackground;
  }
  
  header a:hover {
    background#e81c4f;
    colorwhite;
  }
  
  /* Classes */
  
  .animate {
    animation-duration1s;
    animation-nameblink;
  }
  
  @keyframes blink {
    from {
      background-colorlightyellow;
    }
  
    to {
      background-colortransparent;
    }
  }
  
  html a.button {
    border1px solid #d8dee9;
    border-radius290486px;
    color#b0bfc7;
    padding1em 1.5em;
    text-aligncenter;
    text-decorationnone;
    transitionnone 200ms ease-out;
    transition-propertycolorbackground;
  }
  
  .button:hover {
    background#e81c4f;
    border-colortransparent;
    colorrgba(2552552550.5);
  }
  
  .button em {
    displayblock;
    font-size0.6em;
    font-stylenormal;
    letter-spacing0.2em;
    text-transformuppercase;
  }
  
  .button strong {
    color#e81c4f;
    transitioncolor 200ms ease-out;
  }
  
  .button:hover strong {
    colorwhite !important;
  }
  
  .button.github strong {
    color#333;
  }
  
  .button.github:hover {
    background#333;
  }
  
  .button.facebook strong {
    color#3b5998;
  }
  
  .button.facebook:hover {
    background#3b5998;
  }
  
  .button.twitter strong {
    color#55acee;
  }
  
  .button.twitter:hover {
    background#55acee;
  }
  
  footer .button {
    font-size0.8em;
    padding1em 2em;
  }
  
  .buttons .button {
    displayblock;
    margin-bottom1em;
  }
  
  /* Resources */
  
  .resources {
    margin1em 0;
    padding0;
  }
  
  .resource {
    align-itemscenter;
    border1px solid #d8dee9;
    border-radius5px;
    color#566b78;
    cursorpointer;
    displayflex;
    margin-top1em;
    padding1em 2em;
    text-decorationnone;
  }
  
  .resource:hover {
    border-color#e81c4f;
  }
  
  .resource strong {
    color#e81c4f;
  }
  
  .resource .resource-name {
    color#333;
    displayblock;
    font-size1.2em;
  }
  
  .resource-icon {
    box-sizingborder-box;
    displayblock;
    flex-grow0;
    flex-shrink0;
    height120px;
    margin0;
    margin-right1em;
    padding0;
    text-aligncenter;
    width120px;
  }
  
  .resource-marksheet .resource-icon {
    padding5px;
  }
  
  .resource-bulma .resource-icon {
    padding10px;
  }
  
  .resource-css-reference .resource-icon {
    padding20px;
  }
  
  /* Responsiveness */
  
  @media (min-width600px) {
    .buttons {
      align-itemscenter;
      displayflex;
      justify-contentspace-between;
      padding1em 0;
    }
  
    .buttons .button {
      flex-grow1;
      flex-shrink0;
      margin-bottom0;
      margin-right1em;
    }
  
    .buttons .button:last-child {
      margin-right0;
    }
  
    .resources {
      displayflex;
    }
  
    .resource {
      displayblock;
      flex-basis0;
      flex-grow1;
      flex-shrink1;
      text-aligncenter;
    }
  
    .resource + .resource {
      margin-left1em;
    }
  
    .resource-icon {
      margin0 auto 1em;
    }
  }

Nhận xét

Bài đăng phổ biến từ blog này

#2 Front end CSS

Phỏng vấn Front-end

Lộ trình trở thành một Java Web Developer