/* The basket dropdown in the header.

   Compiled on its own into _common/css/mini-basket.css and linked from the
   master page, because main.css is a Compass build we cannot regenerate. The
   old .basket-summary shell stays; only what sits inside it is ours.

   Laid out as the agreed mockup: the tread picture, make and pattern with the
   size beneath, a quantity stepper and Remove on every line, then the subtotal
   and the red button. */
/* a padlock for the reassurance under the button, and the X in the header */
/* the panel: main.css gives it a 280px box with a square 2px frame and a
   little rotated square for a pointer. It becomes a wider, rounded card. */
.mastheader-basket .basket-summary {
  width: 400px;
  padding: 0;
}
.mastheader-basket .basket-summary::after {
  display: none;
}

.mastheader-basket .basket-summary__wrapper {
  padding: 0;
  background-color: transparent;
}

.mastheader-basket .basket-summary__container {
  padding: 22px 24px 20px;
  border: 0;
  border-radius: 16px;
  background-color: #fff;
  box-shadow: 0 18px 45px rgba(20, 25, 35, 0.18);
}

/* the X keeps it shut until the pointer leaves the basket icon */
.mastheader-basket--closed .basket-summary {
  display: none !important;
}

/* while a quantity is being saved */
.mini-basket--busy {
  opacity: 0.55;
  pointer-events: none;
}

@media all and (max-width: 767px) {
  .mastheader-basket .basket-summary {
    width: min(360px, 100vw - 16px);
  }
  .mastheader-basket .basket-summary__container {
    padding: 18px 16px 16px;
  }
}
.basket-summary__container {
  font-family: "Inter", Helvetica, Arial, sans-serif;
  color: #51555F;
}

/* "Your basket", the item count, the X */
.mini-basket__header {
  display: flex;
  align-items: center;
  gap: 12px;
  margin: 0 0 18px;
  padding: 0;
  border: 0;
  background: none;
}

.mini-basket__title {
  color: #202020;
  font-family: "Montserrat", "Inter", Helvetica, Arial, sans-serif;
  font-size: 20px;
  font-weight: 700;
}

.mini-basket__count {
  padding: 4px 11px;
  border-radius: 999px;
  background-color: #F5F6F8;
  color: #51555F;
  font-size: 13px;
  font-weight: 600;
}

.mini-basket__close {
  flex: 0 0 auto;
  width: 34px;
  height: 34px;
  margin: 0 -6px 0 auto;
  padding: 0;
  border: 0;
  border-radius: 50%;
  background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23202020' stroke-width='2.2' stroke-linecap='round'%3E%3Cpath d='M6 6l12 12M18 6L6 18'/%3E%3C/svg%3E") no-repeat center/16px 16px;
  cursor: pointer;
}
.mini-basket__close:hover {
  background-color: #F5F6F8;
}

/* the lines */
.mini-basket__items {
  display: flex;
  flex-direction: column;
  gap: 18px;
  max-height: 360px;
  margin: 0 0 16px;
  padding: 0;
  overflow-y: auto;
}

.mini-basket__empty {
  margin: 0;
  padding: 10px 0;
  color: #868C98;
  font-size: 14px;
  text-align: center;
}

.mini-basket__item {
  display: flex;
  align-items: flex-start;
  gap: 16px;
}

.mini-basket__image {
  flex: 0 0 92px;
  display: block;
  width: 92px;
}
.mini-basket__image img {
  display: block;
  width: 100%;
  height: auto;
}

.mini-basket__item--service .mini-basket__image {
  flex-basis: 56px;
  width: 56px;
}

.mini-basket__detail {
  flex: 1 1 auto;
  min-width: 0;
}

.mini-basket__line {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
}

.mini-basket__name {
  min-width: 0;
  color: #202020;
  font-size: 15px;
  font-weight: 700;
  line-height: 1.35;
  text-decoration: none;
}

a.mini-basket__name:hover {
  color: #ff0801;
  text-decoration: underline;
}

.mini-basket__price {
  flex: 0 0 auto;
  color: #202020;
  font-size: 15px;
  font-weight: 700;
  white-space: nowrap;
}

.mini-basket__size {
  margin-top: 3px;
  color: #868C98;
  font-size: 13.5px;
  line-height: 1.4;
}

/* Qty  [ - 1 + ]   Remove */
.mini-basket__controls {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-top: 12px;
}

.mini-basket__qty-label {
  color: #51555F;
  font-size: 13.5px;
  font-weight: 600;
}

.mini-basket__stepper {
  display: inline-flex;
  align-items: stretch;
  height: 36px;
  border: 1px solid #E7EAEF;
  border-radius: 8px;
  overflow: hidden;
}

.mini-basket__step {
  width: 34px;
  margin: 0;
  padding: 0;
  border: 0;
  background: #fff;
  color: #202020;
  font-family: inherit;
  font-size: 18px;
  line-height: 1;
  cursor: pointer;
}
.mini-basket__step:hover {
  background-color: #F5F6F8;
}
.mini-basket__step:disabled {
  background: #fff;
  color: #c1c4cc;
  cursor: default;
}

.mini-basket__qty-value {
  display: flex;
  align-items: center;
  justify-content: center;
  min-width: 38px;
  border-left: 1px solid #E7EAEF;
  border-right: 1px solid #E7EAEF;
  color: #202020;
  font-size: 14px;
  font-weight: 600;
}

.mini-basket__remove {
  margin: 0 0 0 auto;
  padding: 0;
  border: 0;
  background: none;
  color: #51555F;
  font-family: inherit;
  font-size: 13.5px;
  font-weight: 500;
  text-decoration: underline;
  cursor: pointer;
}
.mini-basket__remove:hover {
  color: #ff0801;
}

.mini-basket__note {
  margin: 8px 0 0;
  color: #ff0801;
  font-size: 12.5px;
  line-height: 1.4;
}

/* subtotal, the button, the reassurance, the link */
.mini-basket__total {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
  padding-top: 16px;
  border-top: 1px solid #E7EAEF;
  color: #202020;
  font-family: "Montserrat", "Inter", Helvetica, Arial, sans-serif;
  font-size: 16px;
  font-weight: 700;
}

.mini-basket__total-value {
  font-size: 17px;
}

.mini-basket__checkout {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  height: 52px;
  margin: 16px 0 0;
  padding: 0 18px;
  border-radius: 10px;
  background-color: #ff0801;
  color: #fff;
  font-family: "Inter", Helvetica, Arial, sans-serif;
  font-size: 16px;
  font-weight: 700;
  text-align: center;
  text-decoration: none;
}
.mini-basket__checkout:hover {
  background-color: #d40600;
  color: #fff;
  text-decoration: none;
}

.mini-basket__secure {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  margin-top: 12px;
  color: #868C98;
  font-size: 13px;
}
.mini-basket__secure::before {
  content: "";
  width: 14px;
  height: 14px;
  background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23868C98' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Crect x='3' y='11' width='18' height='11' rx='2'/%3E%3Cpath d='M7 11V7a5 5 0 0 1 10 0v4'/%3E%3C/svg%3E") no-repeat center/14px 14px;
}

.mini-basket__view {
  display: block;
  margin-top: 14px;
  padding-top: 14px;
  border-top: 1px solid #E7EAEF;
  color: #202020;
  font-size: 14px;
  font-weight: 600;
  text-align: center;
  text-decoration: underline;
}
.mini-basket__view:hover {
  color: #ff0801;
}

/* nothing in it yet */
.mastheader-basket--empty .mini-basket__items, .mastheader-basket--empty .mini-basket__total, .mastheader-basket--empty .mini-basket__secure, .mastheader-basket--empty .mini-basket__view {
  display: none;
}
.mastheader-basket--empty .mini-basket__header {
  margin-bottom: 10px;
}
.mastheader-basket--empty .mini-basket__checkout {
  margin-top: 0;
}

@media all and (max-width: 767px) {
  .mini-basket__title {
    font-size: 18px;
  }
  .mini-basket__items {
    gap: 16px;
  }
  .mini-basket__item {
    gap: 12px;
  }
  .mini-basket__image {
    flex-basis: 74px;
    width: 74px;
  }
  .mini-basket__controls {
    gap: 10px;
  }
  .mini-basket__stepper {
    height: 34px;
  }
  .mini-basket__step {
    width: 30px;
  }
  .mini-basket__qty-value {
    min-width: 34px;
  }
}
