scaffolding.less 1.67 KB
Newer Older
1
//
2
// Scaffolding
3
// --------------------------------------------------
Jacob Thornton's avatar
Jacob Thornton committed
4

5

Mark Otto's avatar
Mark Otto committed
6
7
8
9
// Reset the box-sizing
// -------------------------

* {
Mark Otto's avatar
Mark Otto committed
10
  .box-sizing(border-box);
Mark Otto's avatar
Mark Otto committed
11
12
13
}


14
// Body reset
15
// -------------------------
Jacob Thornton's avatar
Jacob Thornton committed
16

17
18
19
20
21
22
23
24
25
26
html {
  font-size: 62.5%;
  // Touch the Mobile Magic™
  -webkit-overflow-scrolling: touch;
  -webkit-tap-highlight-color: rgba(0,0,0,0);
}

// Disable iOS/WinMobile font size changes
@media screen and (max-device-width: 480px) {
  html {
27
28
    -webkit-text-size-adjust: 100%;
        -ms-text-size-adjust: 100%;
29
30
31
  }
}

Jacob Thornton's avatar
Jacob Thornton committed
32
body {
Mark Otto's avatar
Mark Otto committed
33
34
35
  font-family: @font-family-base;
  .font-size();
  line-height: @line-height-base;
Mark Otto's avatar
Mark Otto committed
36
37
  color: @text-color;
  background-color: @body-background;
38
39
40
41
42
43
44
}

// Reset fonts for revelant elements
input,
button,
select,
textarea {
Mark Otto's avatar
Mark Otto committed
45
46
47
  font-family: inherit;
  font-size: inherit;
  line-height: inherit;
Jacob Thornton's avatar
Jacob Thornton committed
48
49
}

50

51
// Links
52
// -------------------------
Jacob Thornton's avatar
Jacob Thornton committed
53
54

a {
Mark Otto's avatar
Mark Otto committed
55
  color: @link-color;
Jacob Thornton's avatar
Jacob Thornton committed
56
  text-decoration: none;
57
}
58
59
a:hover,
a:focus {
Mark Otto's avatar
Mark Otto committed
60
  color: @link-color-hover;
61
  text-decoration: underline;
Jacob Thornton's avatar
Jacob Thornton committed
62
}
Mark Otto's avatar
Mark Otto committed
63
64
65
a:focus {
  .tab-focus();
}
66
67
68
69
70


// Images
// -------------------------

Mark Otto's avatar
Mark Otto committed
71
72
73
74
75
76
77
78
79
80
img {
  // Responsive images (ensure images don't scale beyond their parents)
  max-width: 100%; // Part 1: Set a maxium relative to the parent
  width: auto\9; // IE8 need help adjusting responsive images
  height: auto; // Part 2: Scale the height according to the width, otherwise you get stretching

  // Match vertical alignment with other comment elements
  vertical-align: middle;
}

Mark Otto's avatar
Mark Otto committed
81
// Rounded corners
82
.img-rounded {
83
  border-radius: 6px;
84
85
}

86
// Image thumbnails
87
// See thumbnails.less for `.img-thumbnail`
88

Mark Otto's avatar
Mark Otto committed
89
// Perfect circle
90
.img-circle {
91
  border-radius: 500px; // crank the border-radius so it works with most reasonably sized images
92
}