@custom-media --viewport-desktop (width >=62.5rem); :root { --main-width: 960px; } html, body, div, h1, h2, ul, li, p, form, input, textarea, pre { margin: 0; padding: 0; text-size-adjust: 100%; } textarea { overflow: auto; } html, input, textarea { font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "Roboto", "Oxygen", "Ubuntu", "Cantarell", "Fira Sans", "Droid Sans", "Helvetica Neue", sans-serif; -webkit-font-smoothing: subpixel-antialiased; } h1, h2 { font-weight: normal; } ul { list-style-type: none; } a { color: #069; text-decoration: none; } img, hr { border: none; } #app { background: #fdfdfe; display: grid; grid-template-areas: "header" "content" "footer"; grid-template-columns: 1fr; grid-template-rows: minmax(1fr, auto) minmax(1fr, auto) auto; min-height: 100vh; font: -apple-system-body; font-family: -apple-system, Segoe UI; transition: margin-left 0.4s; } #header { grid-area: header; background: #fff; box-shadow: 0 0 3px rgba(0, 0, 0, 0.28); } #header_wrapper, .footer_container { display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; } #sidebar { border-right: 1px solid #ccc; color: #222; transition: width 0.4s; position: fixed; width: 0; top: 0; left: 0; overflow-x: hidden; height: 100%; z-index: 1; display: flex; flex-direction: column; } .nav_content { padding: 10px; } #wrapper { background: #fefdfe; grid-area: content; height: 100%; width: 100%; margin-top: 12px; } #footer { grid-area: footer; background: #f8f8f8; border-top: 1px solid #ccc; color: #222; padding: 10px; } .desktop { display: none; } .card { padding: 6px 24px; } #logo { height: 36px; width: 110px; } #logo a { background: url("//i.juick.com/logo.png") no-repeat; background-size: cover; border: 0; display: block; height: 36px; overflow: hidden; text-indent: 100%; white-space: nowrap; width: 110px; } #ctitle { display: flex; } #ctitle img { margin-right: 5px; vertical-align: middle; max-width: 48px; max-height: 48px; } #global { display: flex; } #global a, #ctitle a { display: flex; align-items: center; border-bottom: 2px solid transparent; } #global a { color: #88958d; padding: 14px 16px; } #sidebar a { color: #88958d; border-right: 2px solid transparent; display: flex; padding: 14px; align-items: center; vertical-align: middle; } #sidebar a:hover { background-color: #f8f8f8; border-right: 2px solid #ff339a; cursor: pointer; } #ctitle a { padding: 2px 20px; } #global a:hover, #ctitle a:hover, .l a:hover .msg-button:hover { background-color: #f8f8f8; border-bottom: 2px solid #ff339a; cursor: pointer; } .icon { vertical-align: middle; } #search input { background: #FFF; border: 1px solid #ccc; outline: none !important; padding: 4px; -webkit-appearance: none; border-radius: 0; } @media (--viewport-desktop) { #app { grid-template-areas: "header header" "content content" "footer footer"; grid-template-columns: 1fr 1fr; grid-template-rows: min-content minmax(min-content, 1fr) min-content; } #header_wrapper, .footer_container { margin: 0 auto; width: var(--main-width); } #wrapper { justify-self: center; width: var(--main-width); display: grid; grid-template-columns: 240px minmax(1fr, max-content); grid-template-rows: auto; grid-template-areas: "nav feed"; } .desktop { display: block; } .mobile { display: none; } #content { grid-area: feed; width: 728px; } #sidebar { border: 0; position: static; grid-area: nav; top: inherit; left: inherit; z-index: inherit; overflow-x: inherit; width: 100%; } }