/* =====================================================================
   Site-wide responsive corrections.

   Loaded last on every page, so it corrects the stylesheets above it
   without editing them. It only addresses faults found by measuring all
   61 pages at 320, 375, 430, 576, 768, 992, 1024, 1280, 1440, 1920 and
   2560px. No colour, typeface, image, section or desktop layout is
   changed; the desktop view above 991px is untouched throughout.
   ===================================================================== */

/* ---------------------------------------------------------------------
   1. The header band was given a fixed height of 76px between 601px and
      991px, in css/style.css (home page) and css/metro-home-nav.css (the
      other 60 pages). Its contents need about 81px at that size, so the
      envelope icon and the email address were cut in half by the bottom
      edge of the red band on every page of the site. The band now takes
      its height from its contents and keeps 76px as a floor, so nothing
      moves at sizes where it already fitted.
   --------------------------------------------------------------------- */
@media (min-width: 601px) and (max-width: 991px) {
    .header,
    .hn .hn-header {
        height: auto;
        min-height: 76px;
    }
}

/* ---------------------------------------------------------------------
   2. Tap targets. On a touch screen these links were only 16-23px tall,
      because they are single lines of text with no padding. The padding
      below lifts the hit area to roughly 32px. The text itself, its size
      and its colour are unchanged, and nothing applies above 991px, so
      the desktop layout is untouched. Tablets are included because they
      are touched, not pointed at.
   --------------------------------------------------------------------- */
@media (max-width: 991px) {
    .header-middle ul li a,
    .hn .hn-header-middle ul li a,
    .metro-breadcrumb li a,
    .svc-crumb li a,
    .mal-office-lines li a,
    .furnitu-right h5 a,
    .footer-grids1-left ul li a,
    .footer .footer-grid-list li a,
    footer.footer-dark a:not(.btn) {
        display: inline-block;
        padding-top: 7px;
        padding-bottom: 7px;
    }

    /* the lists these links sit in lose their own line spacing in exchange,
       so the blocks stay about as tall as they were */
    .footer-grids1-left ul li,
    .footer .footer-grid-list li,
    footer.footer-dark ul li {
        line-height: 1.3;
    }
}

/* ---------------------------------------------------------------------
   3. Text under 12px. Three places set body text below the size at which
      it stays comfortable on a phone. Only the small sizes are raised,
      and only on small screens.

      The "Confidential" stamps on the case-file artwork (.cs-stamp,
      .ce-stamp) are left at 11px on purpose: they are part of a drawing
      of a rubber stamp, not text anybody reads.
   --------------------------------------------------------------------- */
.svc-related-cat,
.pm-verify-text span,
.faq-title-kicker,
#background-check-section .bc-card-text {
    font-size: 12px;
}

/* the card paragraph is the only one of these that is read rather than
   glanced at, so it gets a little more room on phones and tablets */
@media (max-width: 991px) {
    #background-check-section .bc-card-text {
        font-size: 13px;
    }
}

/* ---------------------------------------------------------------------
   4. The home page footer's first column holds a floated list and never
      closed over it, so the column box ended about 248px above its own
      content. Nothing shows today because the next column clears the
      float, but any change to that rule would drop the next block on top
      of the list. The column now contains its float.
   --------------------------------------------------------------------- */
.footer .footer-grid::after {
    content: "";
    display: table;
    clear: both;
}

/* ---------------------------------------------------------------------
   5. Phone header. Below 600px the header stacks into three bands - the
      red logo and contact block, the black menu-button row, and a third
      row holding four social icons - which together took 181px, about
      a third of the first screen, before any content appeared.

      The social row is removed on phones and the remaining two bands are
      tightened. Nothing is removed above 600px, so the tablet and desktop
      headers are exactly as they were.

      Note on the social icons: all four link to "#" on every page of the
      site, so nothing reachable is lost by hiding them. They are not
      copied into the footer because that would only move four dead links
      somewhere else; once there are real profile URLs they can go into
      the footer properly.
   --------------------------------------------------------------------- */
@media (max-width: 600px) {
    .top_nav_right,
    .hn .hn-top_nav_right {
        display: none;
    }

    .header,
    .hn .hn-header {
        padding-top: 3px;
        padding-bottom: 3px;
    }

    .header-left img,
    .hn .hn-header-left img {
        width: 195px;
    }

    .header-middle,
    .hn .hn-header-middle {
        margin-top: 2px;
    }

    /* the contact lines keep a comfortable hit area, just a tighter one than
       the 32px used further down the page, because this band is the first
       thing between the visitor and the content */
    .header-middle ul li a,
    .hn .hn-header-middle ul li a {
        padding-top: 5px;
        padding-bottom: 5px;
    }

    .header-middle ul li.ph,
    .hn .hn-header-middle ul li.hn-ph {
        margin-top: 0;
    }

    .navbar-toggle,
    .hn .hn-navbar-toggle {
        margin-top: 6px;
        margin-bottom: 6px;
    }
}
