@font-face {
    font-family: 'icons';
    src: url('/static/fonts/icons.eot?#iefix2013') format('embedded-opentype'),
         url('/static/fonts/icons.woff?2013') format('woff'),
         url('/static/fonts/icons.ttf?2013') format('truetype');
    font-weight: normal;
    font-style: normal;
}

:root {
  /* ### Highlighting ### */
  /* Selected source line background color.  This is used when clicking on a
     line-number (optionally holding ctrl or shift) to select it/a range. */
  --highlighted-bgcolor: rgb(255, 255, 204);

  /* ### Sticky Headers ### */
  /* Basically, what's the highest number we have a `.nesting-depth-N` selector
     for. This is only used by the `.goto` scroll-padding as a constant.  */
  --max-sticky-lines: 10;

  /* The background color applied to code lines that start a block and stick
     around until the block is closed. (They have the "stuck" class applied.) */
  --sticky-header-bgcolor: #ffe;

  /* ### Blame ### */
  /* Static blame zebra stripe colors. This may change in the future to be
     zebra-striping with logarithmic age coloring. */
  --blame-c1: lightgray;
  --blame-c2: darkgray;
}

/**
 * normalize - Remove the gray background color from active links in IE 10.
 */
a {
    background: transparent;
}
/**
 * normalize - Improve readability when focused and also mouse hovered in all browsers.
 */
a:active,
a:hover {
    outline: 0;
}
/**
 * normalize - Remove most spacing between table cells.
 */
table {
    border-collapse: collapse;
    border-spacing: 0;
}

/* apply a natural box layout model to all elements */
* {
    -moz-box-sizing: border-box;
    -webkit-box-sizing: border-box;
    box-sizing: border-box;
}

body {
    background-color: #fff;
    color: #333;
    font: 12px/1.5 Arial, Helvetica, sans-serif;
    margin: 0;
}
h4 {
    margin: 0 0 .5rem 0;
}
a:link,
a:visited {
    color: inherit;
    text-decoration: none;
}
a:hover {
    text-decoration: underline;
}
caption {
    text-align: left;
}
table {
    margin: 0;
    padding: 0;
    width: 100%;
    overflow: auto;
}
table#file {
    width: 100%;
}
table.folder-content thead tr:first-child {
    color: #555;
    padding: .5em;
}
table th {
    font-weight: bold;
    padding: .5em;
    text-align: left;
}
.folder-content th:first-child {
    padding-left: .5em;
}
.folder-content th {
    padding-left: 0;
    padding-right: .5em;
    padding-top: .2em;
    padding-bottom: .2em;
}
table.folder-content thead tr:first-child,
table.folder-content tr:nth-child(even) {
    background-color: #f5f5f5;
}
table.folder-content tbody tr:hover,
table tbody tr:hover,
.context-menu a:hover {
    background-color: #e8e8e8;
}
table.folder-content td {
    padding: 0;
}
table.folder-content a {
    display: block;  /* Make entire cells clickable. */
    padding-top: .5em;
    padding-right: .5em;
    padding-bottom: .5em;
    text-decoration: none;
}
table td {
    padding: .5em;
}
table.folder-content td.description {
    max-width: 60vw;
    padding-right: 2em;
}
table.folder-content td.description a {
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
td.code {
    padding: 0 0 0 .5em;
}
td#line-numbers {
    padding: 0;
}

.source-line-with-number {
  padding: 0rem 1rem;
  line-height: 1.3;
  display: flex;
}

.line-number {
    /* this needs to create a containing block for the .goto synthetic anchor
       elements which are created as children of .line-number elements, at least
       as long as .goto is position: absolute. */
    position: relative;
    display: inline-block;
    cursor: pointer;
    -moz-user-select: none;
    -o-user-select: none;
    -khtml-user-select: none;
    -webkit-user-select: none;
    -ms-user-select: none;
    user-select: none;
    text-align: right;
    padding: 0 0.5rem;
    /* this was originally set on the ".file td:first-child" */
    color: #aaa;
    width: 8ex;
    flex-shrink: 0;
}
.highlighted,
.multihighlight {
    background: none repeat scroll 0 0 rgb(255, 255, 204) !important;
}
.source-line {
    margin: 0;
    padding: 0;
    display: inline-block;
    white-space: pre;
    flex-grow: 1;
}

.source-line-with-number.stuck {
  background: var(--sticky-header-bgcolor);
}
.source-line-with-number.last-stuck {
  box-shadow: 0px 4px 8px #0002;
}

.source-line a {
    cursor: pointer;
}
.code code {
    padding: 0 0.5rem;
    width: 100%;
}
.code code a {
    cursor: context-menu;
}
mark {
    position: relative;
    padding: .5rem;
}
.logo a:focus {
    background-color: transparent;
}

/**
 * New fixed header mechanism!
 *
 * Previously, the search box stayed stuck at the top of the screen via
 * use of "position: fixed".  This was problematic with browser default
 * anchor positioning, but became untenable when we wanted to start using
 * "position: sticky" to show nesting scopes because we needed to specify "top"
 * positions for each nested sticky level, and it was hard to know for sure how
 * big the search box would actually be without involving JS.
 *
 * So our solution is to use flexbox to create a non-scrolling fixed-header,
 * alotting the remaining space to a scrolling region.
 */

html {
  height: 100%;
}
body {
  height: 100%;
  overflow: hidden;
  display: flex;
  flex-direction: column;
}

#fixed-header {
  flex-shrink: 0;
  display: inline-flex;
}

#scrolling {
  flex-grow: 1;
  overflow-y: auto;
}



/**
 * Nesting!
 */

.nesting-container {
  display: block;
  /* create a containing block that bounds the position: sticky
     .source-line-with-number div necessary for sticky operation. */
  position: relative;
}
.nesting-depth-1,
.nesting-depth-2,
.nesting-depth-3,
.nesting-depth-4,
.nesting-depth-5,
.nesting-depth-6,
.nesting-depth-7,
.nesting-depth-8,
.nesting-depth-9,
.nesting-depth-10 {
  /* be sticky, contained within a .nesting-container */
  position: sticky;
  /* even with our "stuck" and "last-stuck" classes, it's important to have an
     opaque background color for these because those classes don't take effect
     immediately. */
  background-color: white;
}
.nesting-depth-1 {
  top: calc(0 * 12px * 1.3);
  z-index: 100;
}
.nesting-depth-2 {
  top: calc(1 * 12px * 1.3);
  z-index: 99;
}
.nesting-depth-3 {
  top: calc(2 * 12px * 1.3);
  z-index: 98;
}
.nesting-depth-4 {
  top: calc(3 * 12px * 1.3);
  z-index: 97;
}
.nesting-depth-5 {
  top: calc(4 * 12px * 1.3);
  z-index: 96;
}
.nesting-depth-6 {
  top: calc(5 * 12px * 1.3);
  z-index: 95;
}
.nesting-depth-7 {
  top: calc(6 * 12px * 1.3);
  z-index: 94;
}
.nesting-depth-8 {
  top: calc(7 * 12px * 1.3);
  z-index: 93;
}
.nesting-depth-9 {
  top: calc(8 * 12px * 1.3);
  z-index: 92;
}
.nesting-depth-10 {
  top: calc(9 * 12px * 1.3);
  z-index: 91;
}

/* Search results */

.results tr:hover,
.file tr:hover {
    background: none;
}
.results tr,
.file tr {
    border: 0;
    line-height: 1.3;
}
.file tr .line-number,
.file tr .code pre code {
    max-height: calc(12px * 1.3); /* don't let bolded code increase the line-height - see bug 1322740 comment 9 */
}
.left-column,
.file td:first-child {
    text-align: right;
    color: #aaa;
    width: 8ex;
}
.results td {
    padding: .1rem .5rem;
}
.results a {
    cursor: pointer;
    display: inline-block;
}
.file a:target {
    background-color: gray;
    color: white;
    padding: 0 .5rem;
}
.results code {
    white-space: pre;
}
.result-head td
{
    padding-top: .3rem; /* Additional padding to visually seperate results.*/
    padding-bottom: 0;
}
.result-head td.left-column
{
    padding-right: .2rem; /* Moves the icon closer to the path by reducing the padding.*/
}
.result-head a
{
    display: inline;
}

.result-context {
    font-style: italic;
    margin-left: 10px;
    padding-left: 4px;
    padding-right: 4px;
    color: royalblue;
}

.section {
    text-align: right;
    font-size: 150%;
}

.result-pathkind {
  font-size: 150%;
}

.result-kind {
  font-size: 12px;
  font-weight: 800;
}

.expando {
  cursor: pointer;
  color: black;
}
/* End search results */

.file td {
    padding: 0;
}
.file pre {
    margin: 0;
}

/* Context menu */
.context-menu {
    /* absolutely positioned within the containing block of the <body> relative
       to the click event */
    position: absolute;
    background-color: #fff;
    margin: 0;
    padding: 0;
    border: 1px solid #333;
    -webkit-border-radius: 6px;
    -moz-border-radius: 6px;
    border-radius: 6px;
    -webkit-border-top-left-radius: 0;
    -moz-border-top-left-radius: 0;
    border-top-left-radius: 0;
    width: auto;
    list-style: none;
    z-index: 102;
}
.context-menu a {
    display: block;
    text-decoration: none;
}
.context-menu li:first-child a:hover {
    border-top-right-radius: 6px;
}
.context-menu li:last-child a:hover {
    border-bottom-right-radius: 6px;
    border-bottom-left-radius: 6px;
}

.content {
    padding: 1rem 2rem;
}
.content.source-listing {
    padding: 0.5rem 0rem;
}

/* Breadcrumbs */
.path-separator {
    margin: 0 .2rem;
}
.breadcrumbs {
    display: inline-block;
    margin: 0;
    padding: 1rem;
    text-align: left;
}

/* Link styling */
.breadcrumbs a:link,
.breadcrumbs a:visited,
.bubble a:link,
.bubble a:visited,
.result-head a:link,
.result-head a:visited {
    color: #0095dd;
}
.breadcrumbs a:hover,
.result-head a:hover {
    color: #00539f;
}
.breadcrumbs a:focus,
.result-head a:focus {
    color: #00539f;
    text-decoration: none;
}

/* Footer */
.footer {
    color: #999;
    font-size: .7rem;
    margin: 0 0 0 1.2rem;
}

/* Navigation panel */
.panel {
    /* (position:fixed is always relative to the viewport's initial containing
       block, so it doesn't matter where this node lives in the DOM, apart from
       accessibility tree purposes.) */
    position: fixed;
    top: 105px;
    right: 22px;
    background-color: #fff;
    border: 1px solid #e0e0e0;
    border-right: 0;
    min-width: 12rem;
    overflow-y: auto;
    overflow-x: hidden;
    max-height: calc(100% - 150px);
    z-index: 102;
}
.panel button{
    display: inline-block;
    background-color: #333;
    color: #fff;
    margin: 0;
    padding: .5rem .2rem .5rem .7rem;
    border: 0;
    width: 100%;
    text-align: left;
    cursor: pointer;
}
.navpanel-icon {
    display: inline-block;
    margin-right: .5rem;
    -webkit-transform: rotate(-90deg);
    -moz-transform: rotate(-90deg);
    transform: rotate(-90deg);
    transition: all .1s;
}
.navpanel-icon.expanded {
    -webkit-transform: rotate(0deg);
    -moz-transform: rotate(0deg);
    transform: rotate(0deg);
    transition: all .1s;
}
.navpanel-icon:before {
    font-family: icons;
    content: "\e801";
    speak: none;
}
.panel h4 {
    margin: 0;
    padding: .5rem;
}
.panel ul {
    margin: 0;
    padding: 0;
    list-style: none;
}
.panel a.class {
    background-position: 4px 8px;
}
.panel a.method {
    background-position: 4px 6px;
}
.panel a.field {
    background-position: 2px 10px;
}
.panel section a {
    display: inline-block;
    background-color: #fff;
    width: 100%;
}
.panel section a:hover {
    background-color: #e0e0e0;
    text-decoration: none;
}
.panel section a:focus {
    background-color: #e0e0e0;
    text-decoration: underline;
}
.no-results {
    clear: both;
    font-style: italic;
}
#fetch-results {
    display: none;
}

/* Hovering over symbol names */
span[data-symbols]:hover {
  cursor: pointer;
}
span[data-symbols].hovered {
  background-color: yellow;
}

/* Help screen */
.intro {
    font: 14px/1.5 Arial, Helvetica, sans-serif;
    margin-left: 10%;
    margin-right: 10%;
    margin-bottom: 10%;
}

/* ## Line number goto ##

   `scrollIntoView` in dxr.js creates a synthetic anchor element for the current
   hash string (which may be more than just "#200" and instead could be
   "#200-220" or "#220,225,227" or something like that) and gives it this class.
   The element is made a child of the .line-number element.

   See the method's documentation for more context.
*/
.goto {
    /* The negative top allows us to control how much visible padding there
       should be.  This needs to be large enough so that the "position: sticky"
       stuck lines don't obscure the line we're trying to display.  Previously
       this was necessary because the search header was position: fixed and we
       needed to avoid being obscured by that.

       The negative top could be eliminated and replaced with use of the CSS
       scroll-padding mechanism introduced in Firefox 68 (currently beta).
       However, we can't actually get rid of the synthetic anchor.  And since
       scroll-padding isn't on release yet, we're sticking with this for now. */
    top: calc(var(--max-sticky-lines) * 12px * -1.3);
    /* and for the negative top to work, we need to be position: absolute and
       .line-number needs to be position: relative to create a containing block
       that we can offset against. */
    position: absolute;
}

/* ## Blame ## */
/* the role=cell that holds the role=button `.blame-strip`.  We created a class
   for this so we could make it `position: relative` so it could create a new
   containing block for the `.blame-popup` which cannot live beneath the
   role=button `.blame-strip`. */
.blame-container {
  position: relative;
}
.blame-strip {
    display: block;
    width: 20px;
    height: 16px;
    padding: 0;
    margin: 0;
}
/* blame zebra stripes: we alternate colors whenever the revision a line is from
   changes between lines. */
.c1 {
    background: var(--blame-c1);
}
.c2 {
    background: var(--blame-c2);
}

.blame-popup {
    display: inline !important;
    /* positioned inside the .blame-container's containing block created by it
       being position: relative */
    position: absolute;
    top: 0;
    left: 20px;
    width: 600px;
    padding: 10px;
    background: #404040;
    box-shadow: 3px 3px 3px grey;
    border-radius: 3px;
    color: white;
    text-align: left;
    z-index: 200;
    cursor: auto;
    -moz-user-select: text;
    -o-user-select: text;
    -khtml-user-select: text;
    -webkit-user-select: text;
    -ms-user-select: text;
    user-select: text;
}
.blame-popup a {
    text-decoration: underline;
    cursor: pointer;
}
.deemphasize {
    color: #8c8c8c !important;
}
.minus-line {
    background-color: rgb(255, 204, 204);
}
.plus-line {
    background-color: rgb(153, 204, 255);
}

/* Search box */
fieldset {
    position: relative;
    margin: 0;
    padding: 0;
    border: 0;
}
input,
select {
    padding: .5em;
}
/* Kudos to David Walsh */
input[placeholder],
::-moz-placeholder, /* firefox 19+ */
input:-moz-placeholder {
    text-overflow: ellipsis;
}
input[type="checkbox"] {
    /*width: 1rem;*/
    /*height: 1rem;*/
}
#search-box #query {
    width: 100%;
}
#search-box #path {
    width: 100%;
}
#query {
    /* Leave room for spinner. */
    padding-right: 40px;
}
.access-key {
    text-decoration: underline;
}
.search-box {
    background-color: #f5f5f5;
    background-image: linear-gradient(to bottom, #f8f8f8, #eaeaea);
    border-bottom: 1px solid #6d6d6d;
    border-top: 1px solid #f5f5f5;
    color: #333;
    padding: .8rem;
    width: 100%;
}
body.old-rev #fixed-header .search-box {
    padding-bottom: .4rem;
}
#revision {
    padding-top: .2rem;
    color: #656565;
}
#revision a {
    text-decoration: underline;
    cursor: pointer;
}
.h-flex-container {
    display: flex;
    flex-direction: row;
    align-items: center;
}
.v-flex-container {
    display: flex;
    flex-direction: column;
}
#query-section {
    flex: 6;
    position: relative;
}
#option-section {
    flex-grow: 0;
    flex-shrink: 0;
    flex-basis: auto;

    justify-content: center;
    padding: 0 2rem 0 0;
    /*min-width: 9rem;*/
    /*align-self: center;*/
}
#path-section {
    flex: 3;
}
/*http://developer.yahoo.com/blogs/ydn/posts/2012/10/clip-your-hidden-content-for-better-accessibility/*/
.visually-hidden {
    position: absolute;
    clip: rect(1px 1px 1px 1px); /* IE6, IE7 */
    clip: rect(1px, 1px, 1px, 1px);
    padding:0;
    border:0;
    height: 1px;
    width: 1px;
    overflow: hidden;
}
/* Message bubble */
.bubble {
    border: 1px solid #ccc;
    border-radius: 9px;
    color: #6c6c6c;
    display: none;
    font-size: 85%;
    padding: 0.1rem 30px 0.1rem 34px;
    position: absolute;
    top: .25rem;
}
/* The big triangle */
.bubble:before {
    content: "";
    position: absolute;
    border-style: solid;
    border-color: #ccc transparent;
    /* reduce the damage in FF3.0 */
    display: block;
    width: 0;

    top: -9px; /* value = - border-top-width - border-bottom-width */
    bottom: auto;
    right: auto;
    left: 11px; /* controls horizontal position */
    border-width: 0 9px 9px;
}
/* The small triangle */
.bubble:after {
    content: "";
    position: absolute;
    border-style: solid;
    border-color: #fff transparent;
    /* reduce the damage in FF3.0 */
    display: block;
    width: 0;

    top: -8px; /* value = - border-top-width - border-bottom-width */
    bottom: auto;
    right: auto;
    left: 11px; /* value = (:before left) + (:before border-left) - (:after border-left) */
    border-width: 0 9px 9px;
}
.bubble.info {
    background: white url(/static/images/info.gif) 12px 0 / 3ex no-repeat;
}
.bubble.warning {
    background: white url('/static/images/warning.gif') 10px -2px / 3.5ex no-repeat;
}
.bubble.error {
    background: white url(/static/images/error.gif) 12px 0 / 3ex no-repeat;
}
.zero-size-container {
    position: relative;
    height: 0;
    width: 100%;
}
@media only screen and (min-width: 740px) {
    .bubble {
        margin-right: 16%;  /* 100% minus the above */
    }
    .basic_search {
        right: 13%;
    }
}

@media only screen and (min-device-width: 320px) {
    .bubble {
        margin-right: 38%;  /* 100% minus the above */
    }
    input[type="submit"] {
        margin-right: 14%;
    }
    .basic_search {
        top: 11%;
        left: 13px;
        text-align: left;
    }
}

.svg-preview > h4 {
    margin-bottom: 0;
}

.svg-preview > a {
    display: block;
}

.svg-preview > a > img {
    float: left;
    clear: both;
    min-height: 50px;
    max-height: 300px;
    min-width: 50px;
    max-width: 300px;
    box-sizing: content-box;
    border: 1px dashed #555;
    margin-top: 1em;
    margin-bottom: 1em;
}

#svg-preview-checkerboard {
    margin-inline-start: 0;
}

#svg-preview-checkerboard:checked + label + a > img {
    background-image:
      linear-gradient(45deg, #555 25%, transparent 25%,transparent 75%, #555 75%, #555 100%),
      linear-gradient(45deg, #555 25%, transparent 25%,transparent 75%, #555 75%, #555 100%);
    background-size: 10px 10px;
    background-position: 0 0, 5px 5px;
}

.syn_type {
    color: teal;
}

.syn_def {
    font-weight: 600;
}

.syn_string {
    color: green;
}

.syn_comment {
    color: darkred;
}

.syn_tag,
.syn_reserved {
    color: blue;
}

.syn_regex {
    color: #6d7b8d;
}
