util.css 2.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144
  1. /* Feel free to add any useful code */
  2. /* This will help you scroll just the content of your app. Eg:
  3. <header class="fixed">
  4. ...
  5. <article class="scrollable header">
  6. */
  7. html {
  8. height: 100%;
  9. font-size: 62.5%; /* Setting base font to 10px and define all your units in rem. 1rem = 10px */
  10. }
  11. body {
  12. margin: 0;
  13. height: 100%;
  14. display: block;
  15. overflow: hidden;
  16. font-family: sans-serif;
  17. }
  18. .hidden {
  19. visibility: hidden;
  20. }
  21. section[role="region"] {
  22. height: 100%;
  23. background: #fff;
  24. }
  25. section[role="region"] > header.fixed:first-child {
  26. position: absolute;
  27. width: 100%;
  28. }
  29. .scrollable {
  30. overflow: scroll;
  31. height: 100%;
  32. box-sizing: border-box;
  33. -moz-box-sizing: border-box;
  34. -webkit-box-sizing: border-box;
  35. position: relative;
  36. }
  37. .scrollable.header {
  38. height: calc(100% - 5rem);
  39. top: 5rem;
  40. }
  41. /* Setting proper paddings and margins */
  42. .content {
  43. padding: 1.5rem;
  44. }
  45. section[role="region"] .content header {
  46. margin: 1.5rem -1.5rem;
  47. }
  48. section[role="region"] .content header:first-child {
  49. margin-top: -1.5rem;
  50. }
  51. .content [data-type="list"] {
  52. margin: -1.5rem;
  53. }
  54. .center {
  55. text-align: center;
  56. }
  57. [data-type="list"] {
  58. padding: 0;
  59. }
  60. [data-type="list"] ul {
  61. padding: 0 1.5rem;
  62. overflow: auto;
  63. }
  64. section[role="region"] .content [data-type="list"] header {
  65. margin: 0 1.5rem;
  66. }
  67. [data-type="list"] li p,
  68. [data-type="list"] li p:first-of-type {
  69. padding-left: 1.5rem;
  70. }
  71. /* Fonts */
  72. h1 { /* Main header */
  73. font-size: 2.5rem;
  74. font-weight: normal;
  75. }
  76. h2 { /* Subheader, Dialog title */
  77. font-size: 1.6rem;
  78. font-weight: normal;
  79. }
  80. p {
  81. font-size: 1.9rem;
  82. font-weight: normal;
  83. line-height: 2.5rem;
  84. }
  85. p.large { /* Dialog body */
  86. font-size: 2.3rem;
  87. font-weight: 300;
  88. line-height: 3rem;
  89. }
  90. p.alt { /* Body medium, Buttons */
  91. font-size: 1.7rem;
  92. font-weight: 500;
  93. line-height: 2.2rem;
  94. }
  95. p.small { /* Status bar */
  96. font-size: 1.5rem;
  97. line-height: 2rem;
  98. }
  99. p.mini { /* Fine print */
  100. font-size: 1.4rem;
  101. line-height: 1.9rem;
  102. }
  103. p.micro { /* App icon label */
  104. font-size: 1.3rem;
  105. line-height: 1.8rem;
  106. }
  107. ul, ol, li {
  108. list-style: none;
  109. margin: 0;
  110. padding: 0;
  111. font-size: 1.9rem;
  112. font-weight: normal;
  113. line-height: 2.5rem;
  114. }
  115. /* Themes */
  116. .skin-dark { background: #000; }
  117. .skin-organic { background: #f4f4f4; }