/*
 * Theme Name: Budget for Black Lives Theme
 * Description: Theme for Budget for Black Lives site based on Timber
 * Author: Pat Sier
*/
/* Based on https://dev.to/hankchizljaw/a-modern-css-reset-6p3 */
/* Box sizing rules */
*,
*::before,
*::after {
  box-sizing: border-box;
}

/* Remove default padding */
ul[class],
ol[class] {
  padding: 0;
}

/* Remove default margin */
body,
h1,
h2,
h3,
h4,
p,
ul[class],
ol[class],
li,
figure,
figcaption,
blockquote,
dl,
dd {
  margin: 0;
}

/* Set core body defaults */
body {
  min-height: 100vh;
  scroll-behavior: smooth;
  text-rendering: optimizeSpeed;
  line-height: 1.5;
}

/* Remove list styles on ul, ol elements with a class attribute */
ul[class],
ol[class] {
  list-style: none;
}

/* A elements that don't have a class get default styles */
a:not([class]) {
  text-decoration-skip-ink: auto;
}

/* Make images easier to work with */
.wp-block-image img {
  height: auto;
}

img {
  max-width: 100%;
  display: block;
}

.feature {
  margin: auto;
}

.feature img {
  max-width: 1200px;
  width: 100%;
  margin: auto;
}

/* Natural flow and rhythm in articles by default */
article > * + * {
  margin-top: 1em;
}

/* Inherit fonts for inputs and buttons */
input,
button,
textarea,
select {
  font: inherit;
}

input[type="search"],
input[type="email"] {
  appearance: none;
}

fieldset {
  margin-inline-start: 0;
  margin-inline-end: 0;
  padding-block-start: 0;
  padding-block-end: 0;
  padding-inline-start: 0;
  padding-inline-end: 0;
  border: none;
  min-inline-size: min-content;
}

/* Remove all animations and transitions for people that prefer not to see them */
@media (prefers-reduced-motion: reduce) {
  * {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
}

@font-face {
  font-family: "Lemon Milk";
  src: url("./static/fonts/LEMONMILK-Regular.woff2") format("woff2"),
    url("./static/fonts/LEMONMILK-Regular.woff") format("woff");
  font-weight: normal;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: "Lemon Milk";
  src: url("./static/fonts/LEMONMILK-Medium.woff2") format("woff2"),
    url("./static/fonts/LEMONMILK-Medium.woff") format("woff");
  font-weight: bold;
  font-style: normal;
  font-display: swap;
}

:root {
  --black: #000000;
  --light-green: #87ea55;
  --white: #fff;
  --gray: #ccc;
  --light-gray: #f1f1f1;
  --text-color: var(--white);
  --link-color: var(--light-green);
  --border: solid 1px var(--gray);
  --box-shadow: 0 2px 3px rgba(0, 0, 0, 0.1), 0 0 0 1px rgba(0, 0, 0, 0.1);
  --sans-serif: BlinkMacSystemFont, -apple-system, "Helvetica Neue", "Segoe UI",
    "Roboto", "Oxygen", "Ubuntu", "Cantarell", "Fira Sans", "Droid Sans",
    "Helvetica", "Arial", sans-serif;
  --title-font: "Lemon Milk", var(--sans-serif);
  --grid: 6px;
  --grid--2: -12px;
  --grid-05: 3px;
  --grid-1-5: 9px;
  --grid-2: 12px;
  --grid-2-5: 15px;
  --grid-3: 18px;
  --grid-4: 24px;
  --grid-5: 30px;
  --grid-6: 36px;
  --grid-7: 42px;
  --grid-8: 48px;
  --grid-12: 72px;
  --grid-16: 96px;
  --grid-20: 120px;
  --grid-80: 480px;
  --font-size-small: 14px;
  --font-size-reduced: 16px;
  --font-size: 18px;
  --font-size-1-25: 22px;
  --font-size-1-5: 26px;
  --font-size-2: 36px;
  --font-size-2-5: 45px;
  --font-size-3: 54px;
  --nav-height: 60px;
  --max-nav-width: 1024px;
  --max-width: 1024px;
  --max-content-width: 720px;
  --min-input-width: 300px;
}

html,
body {
  background-color: var(--black);
  font-family: var(--sans-serif);
  margin: 0;
  padding: 0;
  font-size: var(--font-size);
  color: var(--text-color);
  scroll-behavior: smooth;
}

body {
  min-height: 100vh;
}

h1,
h2,
h3,
h4,
h5,
h6 {
  font-family: var(--title-font);
  font-weight: 800;
  line-height: 1.25;
}

h1 {
  font-size: var(--font-size-2);
  margin-bottom: var(--grid-5);
}

h2 {
  font-size: var(--font-size-1-5);
  margin-bottom: var(--grid-3);
}

h3 {
  font-size: var(--font-size-1-25);
  margin-bottom: var(--grid-3);
}

a {
  color: var(--link-color);
  text-decoration: none;
}

a:active,
a:hover,
a:focus {
  text-decoration: underline;
}

input {
  border-radius: 0;
  border: 0;
}

blockquote {
  border-left: solid var(--grid) var(--gray);
  padding-left: var(--grid-4);
  opacity: 0.7;
  margin-bottom: var(--grid-2);
}

header {
  padding: var(--grid-3) var(--grid-2);
  min-height: var(--nav-height);
  font-family: var(--title-font);
  font-weight: bold;
  border-bottom: solid var(--grid) var(--light-green);
}

header .nav-contents {
  max-width: var(--max-nav-width);
}

ul {
  padding-inline-start: var(--grid-2);
}

nav ul,
footer ul {
  list-style: none;
}

footer ul {
  padding-left: 0;
}

nav ul li {
  margin-right: var(--grid-3);
}

nav ul li:last-child {
  margin-right: 0;
}

main {
  min-height: calc(100vh - var(--nav-height));
  max-width: var(--max-content-width);
  padding: var(--grid-4) var(--grid-2);
  margin: auto;
}

main.full-width {
  max-width: 100vw;
  padding: var(--grid-4) 0;
}

main.full-width > .content {
  max-width: var(--max-content-width);
  padding: 0 var(--grid-2);
  margin: auto;
}

footer {
  border-top: solid var(--grid) var(--light-green);
  padding: var(--grid-2);
  min-height: 120px;
}

.content h2 {
  margin-top: var(--grid-5);
  margin-bottom: var(--grid-3);
}

.content h3 {
  margin-top: var(--grid-4);
  margin-bottom: var(--grid-3);
}

.content p:not(:last-child) {
  margin-bottom: var(--grid-2);
}

.content a {
  text-decoration: underline;
}

.content a:hover,
.content a:focus,
.content a:active {
  color: var(--text-color);
}

.banner {
  width: 100%;
  padding: var(--grid-6) var(--grid-2);
}

#nav-toggle {
  cursor: pointer;
  display: none;
  text-align: right;
  appearance: none;
  background-color: transparent;
  flex-direction: row;
  align-items: center;
  justify-content: flex-end;
  border-width: 0;
  box-sizing: border-box;
  color: var(--link-color);
  padding: 0;
  margin: 0;
}

#nav-toggle [aria-hidden="true"] {
  margin-left: var(--grid-05);
}

#nav-menu {
  padding-left: 0;
}

.score-row {
  display: flex;
  flex-direction: row;
  align-items: center;
  justify-content: space-between;
  border: solid var(--grid-05) var(--white);
  padding: var(--grid-1-5);
  margin-bottom: var(--grid-2);
  font-family: var(--title-font);
}

.district-detail {
  margin: 0 var(--grid--2);
  margin-bottom: var(--grid-6);
  padding: var(--grid-2) var(--grid-2);
  border: solid var(--grid-05) transparent;
}

.district-detail:target {
  border-color: var(--light-green);
}

.district-detail p:not(:last-child) {
  margin-bottom: var(--grid);
}

.icon-green {
  color: transparent;
  text-shadow: 0 0 0 var(--light-green);
}

.icon-override {
  font-family: monospace;
  font-size: var(--font-size-2);
  line-height: 0.5;
  vertical-align: sub;
}

.video-wrapper {
  position: relative;
  padding-bottom: 56.25%;
  padding-top: 25px;
  height: 0;
  margin: auto;
}

.video-wrapper iframe {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
}

@media screen and (min-width: 1000px) {
  .video-wrapper {
    padding-bottom: 550px;
  }
}

#take-action {
  min-height: 200px;
  position: relative;
  border: solid var(--grid) var(--light-green);
}

#take-action iframe {
  position: relative;
  z-index: 1;
}

.embed-placeholder {
  position: absolute;
  z-index: 0;
  left: 0;
  top: 50%;
  right: 0;
  bottom: 0;
  text-align: center;
}

/* UTILITY CLASSES */

.visually-hidden {
  clip: rect(0 0 0 0);
  clip-path: inset(50%);
  height: 1px;
  overflow: hidden;
  position: absolute;
  white-space: nowrap;
  width: 1px;
}

.visually-hidden-focusable:not(:focus) {
  clip: rect(0 0 0 0);
  clip-path: inset(50%);
  height: 1px;
  overflow: hidden;
  position: absolute;
  white-space: nowrap;
  width: 1px;
}

.relative {
  position: relative;
}

.hidden {
  display: none !important;
}

.inline-block {
  display: inline-block;
}

.text-title {
  font-family: var(--title-font);
}

.text-center {
  text-align: center;
}

.nowrap {
  white-space: nowrap;
}

.underlined {
  text-decoration: underline;
}

.padding-1 {
  padding: var(--grid);
}

.padding-1-5 {
  padding: var(--grid-1-5);
}

.padding-2 {
  padding: var(--grid-2);
}

.padding-top-3 {
  padding-top: var(--grid-3);
}

.padding-bottom-3 {
  padding-bottom: var(--grid-3);
}

.padding-right-1 {
  padding-right: var(--grid);
}

.padding-left-right-4 {
  padding-left: var(--grid-4);
  padding-right: var(--grid-4);
}

.margin-0 {
  margin: 0;
}

.margin-top-4 {
  margin-top: var(--grid-4);
}

.margin-top-6 {
  margin-top: var(--grid-6);
}

.margin-bottom-1 {
  margin-bottom: var(--grid);
}

.margin-bottom-1-5 {
  margin-bottom: var(--grid-1-5);
}

.margin-bottom-4,
ul.margin-bottom-4 {
  margin-bottom: var(--grid-4);
}

.margin-bottom-6,
ul.margin-bottom-6 {
  margin-bottom: var(--grid-6);
}

.margin-bottom-8,
ul.margin-bottom-8 {
  margin-bottom: var(--grid-8);
}

.margin-right-3 {
  margin-right: var(--grid-3);
}

.bold {
  font-weight: bold;
}

.italic {
  font-style: italic;
}

.text-right {
  text-align: right;
}

.font-size-small {
  font-size: var(--font-size-small);
}

.font-size-reduced {
  font-size: var(--font-size-reduced);
}

.font-size-1 {
  font-size: var(--font-size);
}

.font-size-1-5 {
  font-size: var(--font-size-1-5);
}

.font-size-2 {
  font-size: var(--font-size-2);
}

.font-size-3 {
  font-size: var(--font-size-3);
}

.line-height-1 {
  line-height: 1;
}

.line-height-1-25 {
  line-height: 1.25;
}

.block {
  display: block;
}

.flex-row-center {
  display: flex;
  flex-direction: row;
  align-items: center;
}

.flex-row-start {
  display: flex;
  flex-direction: row;
  align-items: flex-start;
}

.flex-column {
  display: flex;
  flex-direction: column;
}

.flex-1 {
  flex: 1;
}

.flex-grow {
  flex-grow: 1;
}

.flex-wrap {
  flex-wrap: wrap;
}

.align-center {
  align-items: center;
}

.justify-start {
  justify-content: flex-start;
}

.justify-end {
  justify-content: flex-end;
}

.justify-center {
  justify-content: center;
}

.justify-between {
  justify-content: space-between;
}

.height-6 {
  height: var(--grid-6);
}

.min-height-6 {
  min-height: var(--grid-6);
}

.min-height-12 {
  min-height: var(--grid-12);
}

.min-height-80 {
  min-height: var(--grid-80);
}

.max-width {
  max-width: var(--max-width);
}

.max-content-width {
  max-width: var(--max-content-width);
}

.width-12 {
  width: var(--grid-12);
}

.min-width-12 {
  min-width: var(--grid-12);
}

.width-16 {
  min-width: var(--grid-16);
  max-width: var(--grid-16);
}

.min-width-20 {
  min-width: var(--grid-20);
}

.min-input-width {
  min-width: var(--min-input-width);
}

@media screen and (min-width: 750px) {
  .margin-left-2-5-desktop {
    margin-left: var(--grid-2-5);
  }
  .margin-left-4-desktop {
    margin-left: var(--grid-4);
  }
}

@media screen and (max-width: 750px) {
  .flex-wrap-mobile {
    flex-wrap: wrap;
  }
  .margin-top-1-5-mobile,
  ul[class].margin-top-1-5-mobile {
    margin-top: var(--grid-1-5);
  }
  .margin-bottom-4-mobile {
    margin-bottom: var(--grid-4);
  }
  .justify-center-mobile {
    justify-content: center;
  }
  .font-size-2-5-mobile {
    font-size: var(--font-size-2-5);
  }
  .min-width-100-mobile {
    min-width: 100%;
  }
  #nav-toggle {
    display: flex;
  }
  #nav-toggle[aria-expanded="false"] + #nav-menu {
    display: none;
  }
  #nav-menu {
    margin-top: var(--grid-2);
    flex-direction: column;
    justify-content: flex-end;
    align-items: flex-end;
  }
  nav ul li {
    margin-right: 0;
    text-align: right;
  }
  nav ul li:not(:last-child) {
    margin-bottom: var(--grid);
  }
}

/* Hack for IE 11-only styles */
@media screen and (-ms-high-contrast: active),
  screen and (-ms-high-contrast: none) {
  main {
    display: flex;
    flex-direction: column;
  }
  header .nav-contents,
  main,
  .max-width,
  .max-content-width {
    width: 100%;
  }
  .min-height-80 {
    height: 0;
  }
}
