/* Styles are Mobile-First */

:root {
  --border-radius: 10px;
  --footer-height: 100px;
  --bg-transparent: rgba(255, 255, 255, 0.5);
  --formFirstColWidth: 125px;
}

::selection {
  color: var(--bg-color);
  background: var(--color-accent);
}

::-moz-selection {
  color: var(--bg-color);
  background: var(--color-accent);
}

@media print {
  a[href]:after {
    content: none;
  }
}

html {
  position: relative;
  min-height: 100%;
}

body {
  font-size: 16px;
  font-family: "Raleway", sans-serif;
  font-optical-sizing: auto;
  font-weight: 500;
  font-style: normal;
  color: var(--color-primary);
  background-color: var(--bg-color);
  background-repeat: no-repeat;
  background-position: center center;
  background-attachment: fixed;
  -webkit-background-size: cover;
  -moz-background-size: cover;
  -o-background-size: cover;
  background-size: cover;
  margin-top: 50px;

  display: flex;
  flex-direction: column;
  height: calc(100vh - 50px);

  &>.container {
    background-color: var(--bg-color);
    border-radius: 0 0 var(--border-radius) var(--border-radius);

    flex: 1;
  }
}

h1,
h2,
h3,
h4,
h5,
h6 {
  margin-top: 0;
}

a {
  color: var(--color-accent);
  transition: color .25s ease-in-out;
}

a:hover,
a:focus,
a:active {
  color: var(--color-highlight);
  text-decoration: none;
}

.gradientText,
.widget_box .fa-solid,
.widget_box .fa-brands {
  --blueLt: rgba(113, 196, 222, 1);
  --blueMd: rgba(0, 119, 155, 1);
  --textGrad: linear-gradient(-45deg, var(--blueMd), var(--blueLt));
  background-image: var(--textGrad);
  -webkit-background-clip: text;
  color: rgba(0, 0, 0, 0);
  font-weight: bold;
}

#wpadminbar {
  opacity: 0.25;
}

/* Menu */

#primary_menu {
  /* border-bottom: 1px solid var(--color-shadow); */
  box-shadow: 0px 0px 5px var(--color-shadow);
}

.navbar-default {
  background-color: var(--bg-menu);
  border-bottom: 1px solid var(--bg-shadow);
  border: 0;
  border-radius: 0;
  margin-bottom: 0;
}

.navbar-default .navbar-nav>.active>a,
.navbar-default .navbar-nav>.active>a:focus,
.navbar-default .navbar-nav>.active>a:hover {
  background-color: var(--color-shadow);
}

.dropdown-menu>.active>a,
.dropdown-menu>.active>a:focus,
.dropdown-menu>.active>a:hover {
  background-color: var(--color-accent);
}

.navbar-default .navbar-toggle {
  border: none;
}

.navbar-brand img {
  width: 100%;
  max-height: 50px;
  max-width: 275px;
  width: auto;
  top: -12px;
  position: relative;
}

/* Pages */

header {
  background-color: var(--bg-header);
  background-repeat: no-repeat;
  background-position: center center;
  -webkit-background-size: cover;
  -moz-background-size: cover;
  -o-background-size: cover;
  background-size: cover;
  box-shadow: 0px 3px 5px var(--color-shadow);
}

.container .row div {
  padding: 0;
}

header img {
  margin: 2em 0;
  max-width: 100%;
  height: auto;
  max-width: 500px;
}

header section {
  width: 100%;
  height: 50px;
  padding: 1em;
  color: white;
  background-color: var(--color-accent);
  background: linear-gradient(177deg, rgba(113, 196, 222, 1) 0%, rgba(0, 119, 155, 1) 100%);
  border-radius: var(--border-radius) var(--border-radius) 0 0;
  box-shadow: 5px 0px 5px var(--color-shadow);
}

.col-md-12 {
  min-height: 0;
}

.widget_homepage,
.widget_inline {
  background-color: var(--color-secondary);
  background: linear-gradient(177deg, rgba(255, 255, 255, 1) 0%, rgba(170, 170, 170, 1) 100%);
  border-bottom: 1px solid var(--color-shadow);
  border-top: 1px solid var(--color-shadow);
  padding: 1.5em 1em 0.75em 1em;
}

.widget_sidebar {
  background-color: var(--color-shadow);
  background: linear-gradient(177deg, rgba(255, 255, 255, 1) 0%, rgba(221, 221, 221, 1) 100%);
  box-shadow: inset 0px 0px 5px var(--color-shadow);
  border-bottom: 1px solid var(--color-secondary);
  padding: 1.5em 1em 0.75em 1em;
  height: 100%;
}

.separator {
  border-top: 3px solid var(--color-accent);
  padding: 1.5em 0.5em;
  margin-top: 3em;
}

.front-page main {
  margin-bottom: 3em;
}

.inside-page>.container {
  margin-bottom: 3em;

  &>.row {
    display: grid;
    grid-template-columns: 1fr 300px;
    height: 100%;
  }
}

body>.container {
  box-shadow: 1px 0px 3px var(--color-shadow);
}

main>.container {
  background-color: var(--bg-color);
  box-shadow: 1px 0px 3px var(--color-shadow);
}

.col-md-4 {
  position: relative;
  right: 0;
  height: 100%;
}

body .row:last-of-type {
  position: relative;
}

aside {
  height: 100%;
}

aside section {
  width: 100%;
  background-color: var(--bg-transparent);
  border-radius: 0 0 var(--border-radius) var(--border-radius);
}

article {
  padding: 2em 1em 1em;
  border-radius: 0;
}

article>img,
article>figure>img {
  max-width: 50%;
  height: auto;
  margin-bottom: 1em;
}

/* Footer */

.prefooter {
  text-align: center;
  color: var(--color-primary);
}

footer {
  position: relative;
  width: 100%;
  padding: 10px 10px 0 10px;
  color: var(--color-secondary);
  padding: 0;

  &>.container {
    width: 100%;
    padding: 0;
  }
}

footer span {
  white-space: nowrap;
}

.footer {
  width: 100%;
  background-color: var(--bg-footer);
  background: linear-gradient(177deg, rgba(66, 66, 66, 1) 0%, rgba(33, 33, 33, 1) 100%);

  &>.container>.row {
    height: 100%;
  }
}

.footer::before {
  display: block;
  content: '';
  width: 100%;
  height: 4px;
  background-color: var(--color-accent);
}

.footer a {
  color: var(--color-secondary);
  padding-right: 0.5em;
}

.footer>.container>.row>div {
  height: var(--footer-height);
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1em;
  align-items: center
}

.footer a:hover {
  color: var(--color-shadow);
}

/* Forms */

form:not(#weather .weather form) {
  margin-bottom: 2em;
}

fieldset {
  width: 100%;
  display: grid;
  grid-template-columns: var(--formFirstColWidth) 1fr;
}

input:not([type="submit"]),
select,
textarea {
  width: 100%;
  margin: 0.5em 0;
  padding: 0.5em;
  border: 1px solid var(--color-shadow);
  border-radius: 7px;
  transition: border-color .25s ease-in-out;
  outline: none;

  &:focus {
    border: 1px solid var(--color-accent);
  }
}

label {
  margin-top: 0.5em;
}

textarea {
  min-height: 150px;
  max-height: 500px;
  resize: vertical;
}

button,
input[type="submit"] {
  border: none;
  border-radius: 7px;
  color: var(--bg-menu);
  margin: 0.5em 0;
  padding: 0.5em;
  transition: background-color .25s ease-in-out;
  background-color: var(--color-secondary);
  white-space: nowrap;

  &:hover {
    background-color: var(--color-accent);
  }
}

button[type="submit"] {
  position: relative;
  left: var(--formFirstColWidth);
}

.contact_form button[type="submit"]::before {
  content: "\f1d8";
  font-family: "Font Awesome 6 Free";
  font-weight: 900;
  margin-right: 8px;
}

@media (max-width: 768px) {
  fieldset {
    grid-template-columns: calc(var(--formFirstColWidth) * 0.75) 1fr;
  }

  button[type="submit"] {
    position: relative;
    left: 92px !important;
  }
}

/* Box Widget */

#weather .weather,
form:not(#weather .weather form),
.widget_box {
  box-shadow: rgb(187, 204, 204) 0px 0px 5px;
  background: linear-gradient(177deg, rgb(255, 255, 255) 75%, rgb(221, 221, 221) 100%);
  border-bottom: 1px solid var(--color-shadow);
  padding: 1.5em 1em !important;
  border-radius: var(--border-radius);
  background-color: white;

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

.widget_box i {
  font-size: 4em;
  margin-bottom: 0.5em;
}

/* Front Page Overrides */

.front-page {
  & article {
    border-radius: 0;
  }

  & main .container:last-of-type {
    border-radius: 0 0 var(--border-radius) var(--border-radius);
  }

  & .widget_sidebar {
    border-radius: 0 0 var(--border-radius) var(--border-radius);
  }
}

/* Sitemap */

.garrettSitemap,
.garrettPosts,
.garrettSearch {
  padding-left: 0;
  margin-top: 1em;
  margin-left: 2em;
  line-height: 0.75em;
  text-align: left;
  list-style-type: none;

  & li {
    & ul {
      margin-top: 1em;
      margin-left: 1em;
      margin-bottom: 1em;
    }

    & a::before {
      font-family: 'Font Awesome 5 Free';
      content: '\f15c';
      margin-right: 0.5em;
    }
  }

  & small {
    line-height: 1.25em;
    margin: 1em;
    display: inline-block;
  }

  & img {
    float: right;
    max-height: 50px;
    max-width: 50px;
    height: auto;
    width: auto;
  }
}

/* Non-Mobile */

@media (min-width: 768px) {
  .inside-page>.container>.row {

    &:before {
      display: none;
    }

    &:after {
      display: none;
    }
  }
}

@media (min-width: 992px) {
  .inside-page>.container>.row {

    & div {
      width: 100%;
    }
  }

  article {
    border-radius: 0 0 0 var(--border-radius);
  }

  .widget_sidebar {
    border-radius: 0 0 var(--border-radius) 0;
  }
}

/* Small Phone */

@media (max-width: 768px) {
  body>.container {
    width: 100%;
  }

  .inside-page>.container>.row {
    grid-template-columns: 1fr;
  }

  .col-md-8 {
    margin-bottom: 3em;
  }

  .widget_prefooter {
    padding: 0 1em;
  }

  .navbar-fixed-bottom .navbar-collapse,
  .navbar-fixed-top .navbar-collapse {
    max-height: 100vh;
  }

  .footer>.container>.row>div {
    margin: 2em;
    grid-template-columns: 1fr;
    --footer-height: calc(var(--footer-height) * 3);
  }
}