/*
 * Responsive additions for the exported Garland theme.
 * Everything is scoped below the theme's original 780px desktop minimum,
 * leaving the existing desktop presentation untouched.
 */
#footer .footer-links {
  display: flex;
  justify-content: center;
  gap: 1.5em;
  margin: 0;
  padding: 1.5em 0 0;
}

#footer .footer-links a,
#footer .footer-links a:link,
#footer .footer-links a:visited,
#footer .footer-links a:active {
  color: #494949;
}

#footer .footer-links a:hover,
#footer .footer-links a:focus {
  color: #494949;
  text-decoration: underline;
}

@media screen and (max-width: 779px) {
  html {
    -webkit-text-size-adjust: 100%;
  }

  body,
  body.sidebar-left,
  body.sidebar-right,
  body.sidebars {
    min-width: 0;
    width: auto;
    font-size: 14px;
    line-height: 1.6;
  }

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

  #header-region {
    min-height: 0.5em;
  }

  #wrapper #container {
    max-width: none;
    padding: 0 14px;
  }

  #wrapper #container #header {
    height: auto;
    min-height: 0;
    padding: 12px 6px 16px;
  }

  #wrapper #container #header #logo-floater {
    position: static;
  }

  #wrapper #container #header h1,
  #wrapper #container #header h1 a:link,
  #wrapper #container #header h1 a:visited {
    line-height: 1.25;
    position: static;
    white-space: normal;
    font-size: 1em !important;
  }

  #wrapper #container #header h1 a {
    display: grid;
    grid-template-columns: 118px minmax(0, 1fr);
    grid-template-rows: auto auto;
    column-gap: 14px;
    align-items: center;
    min-height: 102px;
  }

  #wrapper #container #header h1 a::after {
    content: none;
  }

  #wrapper #container #header h1 img {
    width: 118px;
    height: auto;
    padding: 0;
    float: none;
    grid-column: 1;
    grid-row: 1 / span 2;
  }

  #logo-floater h1 span {
    display: block;
    grid-column: 2;
    grid-row: 1;
    align-self: end;
    font-size: 1.45rem !important;
  }

  #wrapper #container .sidebar {
    width: auto;
    float: none;
    position: static;
    margin: 0 0 12px;
  }

  #sidebar-left .block {
    padding: 0;
  }

  #wrapper #container .sidebar .block {
    margin: 0;
  }

  #wrapper #container .sidebar .block-block {
    display: none;
  }

  #sidebar-left .block-menu .content {
    margin: 0;
  }

  #sidebar-left ul.menu {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 6px;
    margin: 0;
    padding: 0;
  }

  #sidebar-left ul.menu li,
  #sidebar-left ul.menu li.leaf {
    flex: 1 1 auto;
    min-width: 88px;
    margin: 0;
    padding: 0;
    background: none;
    text-align: center;
  }

  #sidebar-left ul.menu li a {
    display: flex;
    min-height: 44px;
    align-items: center;
    justify-content: center;
    padding: 0.65em 0.8em;
    border: 1px solid rgba(233, 195, 157, 0.8);
    border-radius: 4px;
    background: rgba(255, 255, 255, 0.72);
  }

  #sidebar-left ul.menu li a.active {
    background: #fff;
    font-weight: bold;
  }

  #wrapper #container #center,
  body.sidebar-left #center,
  body.sidebar-right #center,
  body.sidebars #center {
    width: auto;
    float: none;
    margin: 0;
  }

  body.sidebar-left #squeeze,
  body.sidebar-right #squeeze,
  body.sidebars #squeeze {
    margin: 0;
  }

  #wrapper #container #center .right-corner {
    left: 0;
    background: none;
  }

  #wrapper #container #center .right-corner .left-corner {
    left: 0;
    min-height: 0;
    margin-left: 0;
    padding: 30px 18px 3em;
    background: none;
  }

  #wrapper #container #center #squeeze {
    overflow: hidden;
    border-top: 12px solid #e4aa72;
    border-radius: 5px 5px 0 0;
    background: #fff;
  }

  #wrapper #container .breadcrumb {
    position: static;
    margin: 0 0 1em;
  }

  .node {
    margin: 0;
    padding: 1.25em 0;
  }

  h1,
  h2,
  h3,
  h4,
  h5,
  h6,
  p,
  a,
  td,
  th {
    overflow-wrap: anywhere;
  }

  img,
  video,
  iframe {
    max-width: 100%;
    height: auto;
  }

  table {
    display: block;
    max-width: 100%;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
  }

  input,
  select,
  textarea {
    max-width: 100%;
  }

  #wrapper #container #footer,
  body.sidebar-left #footer,
  body.sidebar-right #footer,
  body.sidebars #footer {
    margin-left: 0;
    margin-right: 0;
  }
}

@media screen and (max-width: 480px) {
  #wrapper #container {
    padding-right: 10px;
    padding-left: 10px;
  }

  #wrapper #container #header {
    padding-right: 2px;
    padding-left: 2px;
  }

  #wrapper #container #header h1 a {
    grid-template-columns: 94px minmax(0, 1fr);
    column-gap: 10px;
    min-height: 86px;
    font-size: 0.92em !important;
  }

  #wrapper #container #header h1 img {
    width: 94px;
  }

  #logo-floater h1 span {
    font-size: 1.3rem !important;
  }

  #wrapper #container #center .right-corner .left-corner {
    padding: 24px 14px 2.5em;
  }
}
