michael@0: /* This Source Code Form is subject to the terms of the Mozilla Public michael@0: * License, v. 2.0. If a copy of the MPL was not distributed with this michael@0: * file, You can obtain one at http://mozilla.org/MPL/2.0/. */ michael@0: michael@0: input { michael@0: font: message-box !important; michael@0: font-size: 16px !important; michael@0: } michael@0: michael@0: input[type=button] { michael@0: cursor: pointer; michael@0: } michael@0: michael@0: /* SCROLLBOX */ michael@0: #newtab-scrollbox { michael@0: display: -moz-box; michael@0: position: relative; michael@0: -moz-box-flex: 1; michael@0: -moz-user-focus: normal; michael@0: -moz-box-orient: vertical; michael@0: } michael@0: michael@0: #newtab-scrollbox:not([page-disabled]) { michael@0: overflow: auto; michael@0: } michael@0: michael@0: /* UNDO */ michael@0: #newtab-undo-container { michael@0: transition: opacity 100ms ease-out; michael@0: display: -moz-box; michael@0: margin-bottom: 26px; /* 32 - 6 search form top "padding" */ michael@0: -moz-box-align: center; michael@0: -moz-box-pack: center; michael@0: } michael@0: michael@0: #newtab-undo-container[undo-disabled] { michael@0: opacity: 0; michael@0: pointer-events: none; michael@0: } michael@0: michael@0: /* TOGGLE */ michael@0: #newtab-toggle { michael@0: position: absolute; michael@0: top: 12px; michael@0: right: 12px; michael@0: } michael@0: michael@0: #newtab-toggle:-moz-locale-dir(rtl) { michael@0: left: 12px; michael@0: right: auto; michael@0: } michael@0: michael@0: /* MARGINS */ michael@0: #newtab-vertical-margin { michael@0: display: -moz-box; michael@0: position: relative; michael@0: -moz-box-flex: 1; michael@0: -moz-box-orient: vertical; michael@0: } michael@0: michael@0: #newtab-margin-top { michael@0: min-height: 50px; michael@0: max-height: 80px; michael@0: -moz-box-flex: 1; michael@0: -moz-box-align: center; michael@0: -moz-box-pack: center; michael@0: } michael@0: michael@0: #newtab-margin-undo-container { michael@0: display: -moz-box; michael@0: -moz-box-pack: center; michael@0: } michael@0: michael@0: #newtab-margin-bottom { michael@0: min-height: 40px; michael@0: max-height: 100px; michael@0: -moz-box-flex: 1; michael@0: } michael@0: michael@0: #newtab-horizontal-margin { michael@0: display: -moz-box; michael@0: -moz-box-flex: 1; michael@0: } michael@0: michael@0: #newtab-margin-top, michael@0: #newtab-margin-bottom { michael@0: display: -moz-box; michael@0: position: relative; michael@0: } michael@0: michael@0: #newtab-margin-top { michael@0: -moz-box-flex: 1; michael@0: } michael@0: michael@0: #newtab-margin-bottom { michael@0: -moz-box-flex: 2; michael@0: } michael@0: michael@0: .newtab-side-margin { michael@0: min-width: 40px; michael@0: max-width: 300px; michael@0: -moz-box-flex: 1; michael@0: } michael@0: michael@0: /* GRID */ michael@0: #newtab-grid { michael@0: display: -moz-box; michael@0: -moz-box-flex: 5; michael@0: -moz-box-orient: vertical; michael@0: min-width: 600px; michael@0: min-height: 400px; michael@0: transition: 100ms ease-out; michael@0: transition-property: opacity; michael@0: } michael@0: michael@0: #newtab-grid[page-disabled] { michael@0: opacity: 0; michael@0: } michael@0: michael@0: #newtab-grid[locked], michael@0: #newtab-grid[page-disabled] { michael@0: pointer-events: none; michael@0: } michael@0: michael@0: /* ROWS */ michael@0: .newtab-row { michael@0: display: -moz-box; michael@0: -moz-box-orient: horizontal; michael@0: -moz-box-direction: normal; michael@0: -moz-box-flex: 1; michael@0: } michael@0: michael@0: /* CELLS */ michael@0: .newtab-cell { michael@0: display: -moz-box; michael@0: -moz-box-flex: 1; michael@0: } michael@0: michael@0: /* SITES */ michael@0: .newtab-site { michael@0: position: relative; michael@0: -moz-box-flex: 1; michael@0: transition: 100ms ease-out; michael@0: transition-property: top, left, opacity; michael@0: } michael@0: michael@0: .newtab-site[frozen] { michael@0: position: absolute; michael@0: pointer-events: none; michael@0: } michael@0: michael@0: .newtab-site[dragged] { michael@0: transition-property: none; michael@0: z-index: 10; michael@0: } michael@0: michael@0: /* LINK + THUMBNAILS */ michael@0: .newtab-link, michael@0: .newtab-thumbnail { michael@0: position: absolute; michael@0: left: 0; michael@0: top: 0; michael@0: right: 0; michael@0: bottom: 0; michael@0: } michael@0: michael@0: .newtab-thumbnail { michael@0: opacity: .8; michael@0: transition: opacity 100ms ease-out; michael@0: } michael@0: michael@0: .newtab-thumbnail[dragged], michael@0: .newtab-link:-moz-focusring > .newtab-thumbnail, michael@0: .newtab-cell:not([ignorehover]) > .newtab-site:hover > .newtab-link > .newtab-thumbnail { michael@0: opacity: 1; michael@0: } michael@0: michael@0: /* TITLES */ michael@0: .newtab-title { michael@0: position: absolute; michael@0: left: 0; michael@0: right: 0; michael@0: bottom: 0; michael@0: white-space: nowrap; michael@0: overflow: hidden; michael@0: text-overflow: ellipsis; michael@0: } michael@0: michael@0: /* CONTROLS */ michael@0: .newtab-control { michael@0: position: absolute; michael@0: top: 4px; michael@0: opacity: 0; michael@0: transition: opacity 100ms ease-out; michael@0: } michael@0: michael@0: .newtab-control:-moz-focusring, michael@0: .newtab-cell:not([ignorehover]) > .newtab-site:hover > .newtab-control { michael@0: opacity: 1; michael@0: } michael@0: michael@0: .newtab-control[dragged] { michael@0: opacity: 0 !important; michael@0: } michael@0: michael@0: @media (-moz-touch-enabled) { michael@0: .newtab-control { michael@0: opacity: 1; michael@0: } michael@0: } michael@0: michael@0: .newtab-control-sponsored:-moz-locale-dir(rtl), michael@0: .newtab-control-pin:-moz-locale-dir(ltr), michael@0: .newtab-control-block:-moz-locale-dir(rtl) { michael@0: left: 4px; michael@0: } michael@0: michael@0: .newtab-control-sponsored:-moz-locale-dir(ltr), michael@0: .newtab-control-block:-moz-locale-dir(ltr), michael@0: .newtab-control-pin:-moz-locale-dir(rtl) { michael@0: right: 4px; michael@0: } michael@0: michael@0: .newtab-control.newtab-control-sponsored { michael@0: bottom: -20px; michael@0: height: 14px; michael@0: -moz-margin-end: -5px; michael@0: opacity: 1; michael@0: top: auto; michael@0: width: 14px; michael@0: } michael@0: michael@0: .newtab-site:not([type=sponsored]) .newtab-control-sponsored { michael@0: display: none; michael@0: } michael@0: michael@0: /* DRAG & DROP */ michael@0: michael@0: /* michael@0: * This is just a temporary drag element used for dataTransfer.setDragImage() michael@0: * so that we can use custom drag images and elements. It needs an opacity of michael@0: * 0.01 so that the core code detects that it's in fact a visible element. michael@0: */ michael@0: .newtab-drag { michael@0: width: 1px; michael@0: height: 1px; michael@0: background-color: #fff; michael@0: opacity: 0.01; michael@0: } michael@0: michael@0: /* SPONSORED PANEL */ michael@0: #sponsored-panel { michael@0: width: 330px; michael@0: } michael@0: michael@0: #sponsored-panel description { michael@0: margin: 0; michael@0: } michael@0: michael@0: #sponsored-panel .text-link { michael@0: margin: 12px 0 0; michael@0: } michael@0: michael@0: /* SEARCH */ michael@0: #newtab-search-container { michael@0: display: -moz-box; michael@0: position: relative; michael@0: -moz-box-align: center; michael@0: -moz-box-pack: center; michael@0: } michael@0: michael@0: #newtab-search-container[page-disabled] { michael@0: opacity: 0; michael@0: pointer-events: none; michael@0: } michael@0: michael@0: #newtab-search-form { michael@0: display: -moz-box; michael@0: -moz-box-flex: 5; michael@0: -moz-box-orient: horizontal; michael@0: -moz-box-align: center; michael@0: height: 44px; /* 32 + 6 logo top "padding" + 6 logo bottom "padding" */ michael@0: margin-bottom: 10px; /* 32 - 16 tiles top margin - 6 logo bottom "padding" */ michael@0: } michael@0: michael@0: #newtab-search-logo { michael@0: display: -moz-box; michael@0: width: 77px; /* 65 image width + 6 left "padding" + 6 right "padding" */ michael@0: height: 38px; /* 26 image height + 6 top "padding" + 6 bottom "padding" */ michael@0: border: 1px solid transparent; michael@0: -moz-margin-end: 8px; michael@0: background-repeat: no-repeat; michael@0: background-position: center; michael@0: background-size: 65px 26px; michael@0: } michael@0: michael@0: #newtab-search-logo[hidden] { michael@0: display: none; michael@0: } michael@0: michael@0: #newtab-search-logo[active], michael@0: #newtab-search-logo:hover { michael@0: background-color: #e9e9e9; michael@0: border: 1px solid rgb(226, 227, 229); michael@0: border-radius: 2.5px; michael@0: } michael@0: michael@0: #newtab-search-text { michael@0: height: 32px; michael@0: -moz-box-flex: 1; michael@0: michael@0: padding: 0 8px; michael@0: background: hsla(0,0%,100%,.9) padding-box; michael@0: border: 1px solid; michael@0: border-color: hsla(210,54%,20%,.15) hsla(210,54%,20%,.17) hsla(210,54%,20%,.2); michael@0: box-shadow: 0 1px 0 hsla(210,65%,9%,.02) inset, michael@0: 0 0 2px hsla(210,65%,9%,.1) inset, michael@0: 0 1px 0 hsla(0,0%,100%,.2); michael@0: border-radius: 2.5px 0 0 2.5px; michael@0: color: inherit; michael@0: } michael@0: michael@0: #newtab-search-text:-moz-dir(rtl) { michael@0: border-radius: 0 2.5px 2.5px 0; michael@0: } michael@0: michael@0: #newtab-search-text:focus, michael@0: #newtab-search-text[autofocus] { michael@0: border-color: hsla(206,100%,60%,.6) hsla(206,76%,52%,.6) hsla(204,100%,40%,.6); michael@0: } michael@0: michael@0: #newtab-search-submit { michael@0: height: 32px; michael@0: michael@0: -moz-margin-start: -1px; michael@0: background: linear-gradient(hsla(0,0%,100%,.8), hsla(0,0%,100%,.1)) padding-box; michael@0: padding: 0 9px; michael@0: border: 1px solid; michael@0: border-color: hsla(210,54%,20%,.15) hsla(210,54%,20%,.17) hsla(210,54%,20%,.2); michael@0: -moz-border-start: 1px solid transparent; michael@0: border-radius: 0 2.5px 2.5px 0; michael@0: box-shadow: 0 0 2px hsla(0,0%,100%,.5) inset, michael@0: 0 1px 0 hsla(0,0%,100%,.2); michael@0: color: inherit; michael@0: cursor: pointer; michael@0: transition-property: background-color, border-color, box-shadow; michael@0: transition-duration: 150ms; michael@0: } michael@0: michael@0: #newtab-search-submit:-moz-dir(rtl) { michael@0: border-radius: 2.5px 0 0 2.5px; michael@0: } michael@0: michael@0: #newtab-search-text:focus + #newtab-search-submit, michael@0: #newtab-search-text + #newtab-search-submit:hover, michael@0: #newtab-search-text[autofocus] + #newtab-search-submit { michael@0: border-color: #59b5fc #45a3e7 #3294d5; michael@0: color: white; michael@0: } michael@0: michael@0: #newtab-search-text:focus + #newtab-search-submit, michael@0: #newtab-search-text[autofocus] + #newtab-search-submit { michael@0: background-image: linear-gradient(#4cb1ff, #1793e5); michael@0: box-shadow: 0 1px 0 hsla(0,0%,100%,.2) inset, michael@0: 0 0 0 1px hsla(0,0%,100%,.1) inset, michael@0: 0 1px 0 hsla(210,54%,20%,.03); michael@0: } michael@0: michael@0: #newtab-search-text + #newtab-search-submit:hover { michael@0: background-image: linear-gradient(#66bdff, #0d9eff); michael@0: box-shadow: 0 1px 0 hsla(0,0%,100%,.2) inset, michael@0: 0 0 0 1px hsla(0,0%,100%,.1) inset, michael@0: 0 1px 0 hsla(210,54%,20%,.03), michael@0: 0 0 4px hsla(206,100%,20%,.2); michael@0: } michael@0: michael@0: #newtab-search-text + #newtab-search-submit:hover:active { michael@0: box-shadow: 0 1px 1px hsla(211,79%,6%,.1) inset, michael@0: 0 0 1px hsla(211,79%,6%,.2) inset; michael@0: transition-duration: 0ms; michael@0: } michael@0: michael@0: #newtab-search-panel .panel-arrowcontent { michael@0: -moz-padding-start: 0; michael@0: -moz-padding-end: 0; michael@0: padding-top: 0; michael@0: padding-bottom: 0; michael@0: background: rgb(248, 250, 251); michael@0: } michael@0: michael@0: .newtab-search-panel-engine { michael@0: -moz-box-align: center; michael@0: padding-top: 4px; michael@0: padding-bottom: 4px; michael@0: -moz-padding-start: 24px; michael@0: -moz-padding-end: 24px; michael@0: } michael@0: michael@0: .newtab-search-panel-engine:not(:last-child) { michael@0: border-bottom: 1px solid #ccc; michael@0: } michael@0: michael@0: .newtab-search-panel-engine > image { michael@0: -moz-margin-end: 8px; michael@0: width: 16px; michael@0: height: 16px; michael@0: list-style-image: url("chrome://mozapps/skin/places/defaultFavicon.png"); michael@0: } michael@0: michael@0: .newtab-search-panel-engine > label { michael@0: -moz-padding-start: 0; michael@0: -moz-margin-start: 0; michael@0: color: rgb(130, 132, 133); michael@0: } michael@0: michael@0: .newtab-search-panel-engine[selected] { michael@0: background: url("chrome://global/skin/menu/shared-menu-check.png") center left 4px no-repeat transparent; michael@0: }