/* ==========================================================================
   UTILITIES / #DEFENCE
   ========================================================================== */

/* stylelint-disable string-no-newline */
/* stylelint-disable selector-max-id */

@warn "Deprecation [utility]: Defence
Support for `_defence.scss` will be removed in Toolkit@3.0.0 due to deprecation of the existing Masthead.
If you experience any issues with this required change, please visit https://git.io/v9b7v for next steps.";

// Defence Settings
// 1. Sets classic-masthead sass-mq breakpoint.
// 2. Sets default Tile themes to defend.
@include mq-add-breakpoint(classic-masthead, 768px); // [1]
$defence-tile-themes: "sky-1", "sky-account", "sky-atlantic", "sky-arts", "sky-box-sets", "sky-cinema", "sky-kids", "sky-living", "sky-witness", "sky-news", "sky-sports", "sky-store", "ultimate-on-demand", "sky-mobile" !default; // [2]

/**
 * Repair alterations to the current masthead caused by the Toolkit.
 */
#skycom-masthead-wrapper {
  /*! autoprefixer: off */
  background: #fff !important;
  font-size: 16px !important;
  box-sizing: content-box !important;
  -moz-osx-font-smoothing: initial !important;
  -webkit-font-smoothing: initial !important;

  /**
   * Fixed media-query value set by the current masthead.
   */
  @include mq(classic-masthead) {
    padding-bottom: 10px !important;
  }
}

/**
 * Repair alterations to the current footer caused by the Toolkit.
 */
.skycom-footer {
  /*! autoprefixer: off */
  font-size: 16px !important;
  box-sizing: content-box !important;
  -moz-osx-font-smoothing: initial !important;
  -webkit-font-smoothing: initial !important;
}

.skycom-footer__nav {
  ul {
    margin: 0 !important;
  }
}

/**
 * Repair alterations to the current message banners caused by the Toolkit.
 */
.skycom-message-container {
  font-size: 14px !important;
  box-sizing: content-box !important;
}

/**
 * Repair links affected by 768px media query.
 */
@include mq($from: classic-masthead) {
  a {
    color: color(brand);
    text-decoration: none;
  }
}

/**
 * Repair all page links affected by `.skycom-focus`.
 */
body a.skycom-focus {
  background-color: transparent !important;
  color: inherit !important;
}

/**
 * Return masthead links to `.skycom-focus` style.
 */
#skycom-masthead-wrapper {
  a.skycom-focus {
    background-color: #255094 !important;
    color: #fff !important;
  }
}

/**
 * Repair `.skycom-focus` styles for channel themed Tiles on hover.
 */
[class*="c-tile--sky-"] {
  .c-tile__link:hover.skycom-focus {
    color: color(white) !important;
  }
}

/**
 * Repair altercations to the container.
 */
.skycom_container {
  max-width: 1140px !important;

  @include mq($from: classic-masthead) {
    max-width: 1140px !important;
  }
}

/**
 * Repair altercations to the mobile menu made by our hidden overflow-x.
 */
.skycom-mobile {
  body.skycom-fixed {
    overflow-x: visible !important;
  }
}

/* stylelint-enable */
