/**
    Theme Name: Texas A&M Forest Service
    Author: NewCity
    Description: Custom theme developed by NewCity; uses the Timber engine.
    Version: 1.0
*/

/* Defaults
---------------------------------------- */

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

a,
button,
input:focus,
input[type='button'],
input[type='submit'],
textarea:focus,
.wp-element-button {
  transition: all 0.2s ease-in-out;
}

a,
a:focus,
a:hover,
a:not(.wp-element-button) {
  text-decoration-thickness: 1px;
}

b,
strong,
th {
  font-weight: var(--wp--custom--font-weight--medium);
}

mark {
  background: linear-gradient(
    90deg,
    var(--wp--preset--color--primary) 0%,
    var(--wp--preset--color--primary) 100%
  );
  background-position: 0 85%;
  background-repeat: repeat-x;
  background-size: 100% 15%;
}

/* -- Forms -- */

:root :where(input:not(.acf-block-fields *):not([class*='border-'])),
:root :where(select:not(.acf-block-fields *):not([class*='border-'])),
:root :where(textarea:not(.acf-block-fields *):not([class*='border-'])) {
  background-color: var(--wp--preset--color--base);
  border: 1px solid var(--wp--preset--color--contrast);
  border-radius: 0;
  color: var(--wp--preset--color--contrast);
  font-family: var(--wp--preset--font-family--primary);
  font-size: var(--wp--preset--font-size--medium);
  font-weight: var(--wp--custom--font-weight--light);
  line-height: var(--wp--custom--line-height--body);
  padding: 10px 20px;
  width: 100%;
}

input:focus,
textarea:focus {
  background-color: var(--wp--preset--color--neutral);
  outline: none;
}

input[type='checkbox'],
input[type='image'],
input[type='radio'] {
  width: auto;
}

input[type='button'],
input[type='email'],
input[type='search'],
input[type='submit'],
input[type='text'],
textarea {
  -webkit-appearance: none;
}

::placeholder {
  color: var(--wp--preset--color--contrast);
  font-size: var(--wp--preset--font-size--small);
  opacity: 0.5;
}

/* Blocks
---------------------------------------- */

/* -- Code -- */

*:not(.wp-block-code) > code {
  background-color: var(--wp--preset--color--neutral);
  font-size: var(--wp--preset--font-size--small);
  padding: 5px 8px;
}

/* -- Navigation -- */

.wp-block-navigation__responsive-container.is-menu-open {
  padding: var(--wp--custom--spacing--gap);
}

.wp-block-navigation__responsive-container.is-menu-open
  .wp-block-navigation__responsive-container-content {
  padding-top: var(--wp--custom--spacing--gap);
}

.wp-block-navigation__responsive-container-close,
.wp-block-navigation__responsive-container-open {
  border: 1px solid currentColor;
  padding: 2px;
}

.has-background .wp-block-navigation__responsive-container-open:focus,
.has-background .wp-block-navigation__responsive-container-open:hover {
  color: var(--wp--preset--color--base);
}

/* -- Navigation Submenu -- */

.wp-block-navigation:not(.has-background)
  .wp-block-navigation__submenu-container {
  background-color: var(--wp--preset--color--contrast);
  border: var(--wp--preset--color--contrast);
  color: var(--wp--preset--color--base);
  padding: 10px;
}

.wp-block-navigation :where(.wp-block-navigation__submenu-container) a {
  padding: 2px 10px;
}

:where(.wp-site-blocks) > nav {
  margin-top: 0;
}

/* Media Queries
---------------------------------------- */

@media only screen and (max-width: 600px) {
  /* -- Utility -- */

  .is-style-hidden-mobile {
    display: none !important;
  }
}

@media only screen and (max-width: 782px) {
  /* -- Columns -- */

  .is-style-columns-reverse {
    flex-direction: column-reverse;
  }
}

:root
  :where(
    h1.wp-block-heading,
    h2.wp-block-heading,
    h3.wp-block-heading,
    h4.wp-block-heading,
    h5.wp-block-heading,
    h6.wp-block-heading
  ) {
  margin-bottom: 0;
}
/* :root .wp-block-heading {
  margin-bottom: clamp(1rem, 0.5em, 1.5rem);
} */

:root :where(h1.wp-block-heading):not(class*=[text-]) {
  font-size: var(--wp--preset--font-size--max-36);
}
:root :where(h2:not([data-nc-component] *)) {
  font-size: var(--wp--preset--font-size--h-2-style);
}
:root :where(h3.wp-block-heading) {
  font-size: var(--wp--preset--font-size--h-3-style);
}
:root :where(h4.wp-block-heading) {
  font-size: var(--wp--preset--font-size--h-4-style);
}
:root :where(h5.wp-block-heading) {
  font-size: var(--wp--preset--font-size--h-5-style);
}
:root :where(h6.wp-block-heading) {
  font-family: var(--wp--preset--font-family--sans-serif);
  font-size: var(--wp--preset--font-size--h-6-style);
}

:root :where(section) {
  clear: both;
}

:root :where(body.single-post main > article),
:root :where(body.blog main > article) {
  padding-bottom: 2.5rem;
}

:root :where(.wp-block-image img ~ figcaption) {
  font-size: 0.875rem;
  color: rgb(var(--theme-text-color) / 1);
  padding-left: 1.5rem;
  border-left-style: solid;
  border-left-width: 1px;
  border-color: rgb(var(--theme-fancy-link-decoration-color, 0 0 0) / 1);
}

:root
  [data-tw-theme='dark-green-700']
  :where(.wp-block-image img ~ figcaption):not(html[data-mode='dark'] *) {
  border-color: rgb(233 228 197/1);
}
