/* Inter typeface
 * SIL OFL 1.1 - http://scripts.sil.org/OFL
 * Copyright (c) 2016-2020 The Inter Project Authors
 * https://github.com/rsms/inter
 * Version 3.13 - using western languages subset
 * webfonts generated using https://www.fontsquirrel.com/tools/webfont-generator
 */
@font-face {
    font-family: 'Inter';
    font-weight: 400;
    font-style: normal;
    src: url('/type/inter-regular.woff') format('woff');
}
/*
@font-face {
    font-family: 'Inter';
    font-weight: 400;
    font-style: italic;
    src: url('/type/inter-italic.woff') format('woff');
}
*/
@font-face {
    font-family: 'Inter';
    font-weight: 600;
    font-style: normal;
    src: url('/type/inter-semibold.woff') format('woff');
}
@font-face {
    font-family: 'Inter';
    font-weight: 700;
    font-style: normal;
    src: url('/type/inter-bold.woff') format('woff');
}

/* Generic element styling */
body {
    font-size: 18px;
    font-weight: 400;
    line-height: 1.5em;
    color: #00293e;
    font-family: "Inter", "Libre Franklin", "Dejavu Sans", "Roboto", sans-serif;
    margin: 0 auto;
    padding: 0;
    text-align: left;
    background: #fefefe;
}
a {
    text-decoration: none;
    color: #218ba2;
}
h1, h2, h3, h4, h5, h5 {
    font-weight: 600;
}
h1 {
    line-height: 1.2em;
}
h2 {
    font-size: 1.8em;
    line-height: 1.2em;
}
h3.devintro-section-header {
    /* color: #1388f0; */
    color: #052a4a;
    font-variant-caps: all-small-caps;
    letter-spacing: 1px;
    line-height: 1em;
    border-width: 0 0 4px 0;
    border-style: solid;
    padding-bottom: 0.2em;
}
li {
    margin: 0.3rem 0;
}
b, strong {
    font-weight: 700;
}
code {
    background: #edf5f7;
    padding: 0.1em 0.16em;
    color: #002942;
}
/* In lieu of pulling in an italic font specimen, just use muted colours as emphasis */
.muted-text {
    color: #657d8a;;
}


/* Navbar and header */
header {
    margin: 0 auto;
    text-align: center;
    padding: 0.8rem 0 0;
    display: flex;
    padding: 0.8rem 0 0;
    font-size: 16px;
}
nav {
    float: none;
    display: inline-block;
}
nav a {
    /* color: #00174f; */
    /* Need to mute color a bit due to font weight of 600 */
    color: #2b3e6d;
    /* font-family: "Overpass", sans-serif; */
    font-family: "Inter", sans-serif;
    /* 500 would be nicer, but let's not pull in another weight of Inter just
     * for this */
    /* font-weight: 500; */
    font-weight: 600;
    letter-spacing: 0.073rem;
    text-transform: uppercase;
    line-height: 2.4rem;
}
nav a.selected {
    border-bottom: 3px solid #077da2
}
.header-logo {
    color: #00174f;
    font-weight: 600;
    font-size: 1.66rem;
    display: inline-block;
    line-height: 2.4rem;
}
.header-logo a {
    color: #00174f;
}


/* General media queries */
@media (max-width:500px) {
    header {
        flex-flow: column nowrap;
    }
    .center-vs {
        text-align: center;
    }
}
@media (min-width:501px) {
    .header-logo {
        width: 38%;
    }
    nav {
        width: 56%;
    }
}
@media (max-width: 750px) {
    nav a {
        font-size: 0.8rem;
        padding: 0.4rem 0.4rem 0.2rem;
    }
    .item {
        flex-basis: 100%;
        margin: 1em 0;
    }
    .sitewide-logo {
        width: 100px;
        height: 100px;
    }
}
@media (min-width: 751px) {
    nav a {
        font-size: 1.06rem;
        padding: 0.4rem 0.6rem 0.2rem;
    }
    .item {
        flex-basis: 43%;
        border: 2px solid #31a9dc2e;
        margin: 5px;
    }
    .item:last-child {
        flex-basis: 47%;
        flex-grow: 0
    }
    .item:target {
        border: 2px solid #a80596;
    }
    .container {
        padding: 0 30px;
    }
    .sitewide-logo {
        width: 200px;
        object-fit: cover;
        height: 130px;
    }
    .chooser {
        border: 10px solid #dbe2fb;
        padding: 1rem 1rem;
        /* border-radius: 4px; */
    }
}


/* Flex container for grid items, children */
.container {
    display: flex;
    flex-direction: row;
    flex-wrap: wrap;
    justify-content: center;
    max-width: 1400px;
    margin: 0 auto;
}
.item {
    flex-grow: 1;
    border-radius: 2px;
    padding: 5px 20px;
    background: #ffffff;
}
.item-logo-bg {
    width: 80px;
    height: 80px;
    float: right;
    margin: 10px 10px 10px 20px;
    background-size: 80px 80px;
    background-position: center;
    background-size: contain;
    background-repeat: no-repeat;
}
.item h3 {
    margin: 1em 0 0;
    text-transform: uppercase;
    /* small caps results in numerals getting rendered full size */
    /* font-variant-caps: all-small-caps; */
    font-size: 1.1rem;
    letter-spacing: 1px;
    color: #27446f;
}
.news-post {
    margin-top: 3em;
}
.perma {
    visibility: hidden;
}
.news-post h3:hover .perma {
    visibility: visible;
}


/* Lists */
.checklist-container {
    background: #f0fffd;
    border-radius: 20px;
    padding: 0.7em 1em
}
ul.checklist {
    list-style-type: none;
    padding-left: 0;
}
ul.checklist li {
    position: relative;
    padding-left: 1.6em;
}
ul.checklist li:before {
    position: absolute;
    left: 0;
    /* content: '✓'; */
    /* Big fat checkmark */
    content: "\2714\0020";
    color: #1c9cdb;
    font-size: 1.4em;
}
ol.count {
    list-style-type: none;
    counter-reset: item;
    padding-inline-start: 1rem;
}
ol.count > li {
    counter-increment: item;
    list-style:none inside;
    margin: 0.6rem 0;
}
ol.count > li:before {
    content: counter(item);
    background: #00253f;
    color: white;
    display: block;
    margin-right: 1rem;
    float: left;
    width: 1.8rem;
    height: 1.8rem;
    font-size: 1.2rem;
    border-radius: 999px;
    text-align: center;
    line-height: 1.9rem;
}


/* Lipstick for elements */
.button-container {
    display: flex;
    flex-flow: row wrap;
}
.rounded-button {
    display: inline-block;
    background: #00ddc9;
    color: #ffffff;
    text-align: center;
    border-radius: 999px;
    /* border-radius: 4px; */
    font-size: 1.1em;
    padding: 0.4em 0.9em;
    margin: 0.4em 0.4em;
    background: linear-gradient(to right,#00c8dd,#009fdd);
}
.emphasis-button {
    background: linear-gradient(to right,#6f00dd,#dd007c);
}
.muted-button {
    display: inline-block;
    /* background: #00ddc9; */
    /* Slightly too flashy */
    /* background: #54fff0; */
    background: #8ef4ff;
    color: #052157;
    text-align: center;
    border-radius: 2px;
    font-size: 0.9rem;
    padding: 0.4em 0.9em;
    /* margin: 0.4em 0.4em; */
    margin: 0.4em 0.4em 0.4em 0;
    /* background: linear-gradient(to right,#00c8dd,#009fdd); */
}
.muted-button:hover, .muted-button:focus {
    background: #00a9dd;
}
img.showoff {
    max-width: 100%;
    max-height: 360px;
}
.landing-img {
    max-width: 300px;
    align-items: center;
    justify-content: center;
    opacity: 0.74;
}
.landing-img:hover {
    opacity: 1;
}
.showcase {
    width: 100%;
    max-width: 1500px;
    margin: 0 auto;
    justify-content: space-evenly;
    text-align: center;
    padding-bottom: 2em;
}
/*
TODO: More space-efficient captions
.showcase figure {
}
*/
h2#devswelcome {
    background: linear-gradient(to right,red,orange,#ffd700,#45db01,#00cfff,blue,indigo,violet);
    background-size:auto;
    background-clip: text;
    /* Yeah we know, Chrome, you're a precious special snowflake */
    -webkit-background-clip: text;
    color: transparent;
    width: max-content;
    text-shadow: 0px 1px 4px rgba(130, 102, 102, 0.15);
}

/* Device chooser dropdown */
input#device-chooser {
  box-sizing: border-box;
  /* search.svg: zondicons */
  background-image: url('/img/search.svg');
  background-position: 14px 14px;
  background-repeat: no-repeat;
  font-size: 16px;
  padding: 14px 20px 12px 45px;
  border: none;
  /* border-bottom: 1px solid #ddd; */
  background-size: 18px 18px;
}
input#device-chooser:focus {outline: 3px solid #ddd;}
.dropdown {
  padding: 0;
  position: absolute;
  background-color: #f6f6f6;
  min-width: 230px;
  border: 1px solid #ddd;
  /* Don't let the list grow too large.
   * Not ideal ofc since scrollbars would be more intuitive */
  max-height: 500px;
  overflow: hidden;
  z-index: 2;
}
.dropdown span {
  color: black;
  padding: 12px 16px;
  text-decoration: none;
  /* Hide initially */
  display: none;
}
.dropdown span:hover {background-color: #ddd;}


/* Utility classes */
@media (max-width: 750px) {
    .hide-sm {
        display: none;
    }
    .reading {
        padding: 0 1.2em;
    }
    .fullwidth-sm {
        width: 100%;
    }
    .justify-center-sm {
        justify-content: center;
    }
    .h-spacer-sm {
        height: 4em;
        width: 100%;
    }
    .mar-top-sm {
        margin-top: 4em;
    }
    h3.devintro-section-header {
        border-image: linear-gradient(to right, #6f00dd, #dd007c 100%) 1;
    }
}
@media (min-width: 751px) {
    .half-med {
        max-width: 50%;
    }
    .flex-half-med {
        flex: 1 0 50%;
    }
    .flex-third-med {
        flex: 1 0 33%;
    }
    .flex-twothirds-med {
        flex: 1 0 67%;
    }
    .flex-med {
        display: flex;
    }
    .flex-nogrow-med {
        flex-grow: 0;
    }
    .h-spacer-med {
        height: 4em;
        width: 100%;
    }
    .mar-left-med {
        margin-left: 2em;
    }
    .mar-right-med {
        margin-right: 2em;
    }
    h3.devintro-section-header {
        display: inline-block;
    }
    .mar-left-med h3.devintro-section-header {
        border-image: linear-gradient(to right, #6f00dd, #dd007c 100%) 1;
    }
    .mar-right-med h3.devintro-section-header {
        border-image: linear-gradient(to right, #dd007c, #6f00dd 100%) 1;
    }
    .space-evenly-med {
        justify-content: space-evenly;
    }
}

@media (prefers-color-scheme: dark) {
    body {
        background: #011714;
        color: #e2f0f2;
    }
    b, strong {
        color: #ffffff;
    }
    nav a {
        color: #eefdff;
    }
    .item {
        background: #011714;
        color: #eefdff;
    }
    .item h3 {
        color: #78aaf5;
    }
    a {
        color: #27b0e6;
    }
    .darkinvert {
        filter: invert(1);
    }
    input#device-chooser {
        background-color: #011714;
        color: #eefdff;
      background-image: url('/img/search-dark.svg');
    }
    .dropdown {
        border: 1px solid #259db9;
        background-color: #011714;
    }
    .dropdown span {
        color: #eefdff;
    }
    .dropdown span:hover {
        background-color: #083760;
    }
    h3.devintro-section-header {
        color: #ffffff;
    }
    .checklist-container {
        background: #032c3c;
    }
    ol.count > li:before {
        background: #ce41b8;
        color: #00192b;
    }
    @media (min-width: 751px) {
        .chooser {
            border: 10px solid #382d57;
        }
    }
}
