/**
* 2010-2026 SwissGeek | Web Developer Freelance
*
 * NOTICE OF LICENSE
 *
 * This source file is subject to the Open Software License (OSL 3.0)
 * that is bundled with this package in the file LICENSE.md.
 * It is also available through the world-wide-web at this URL:
 * https:// opensource.org/licenses/OSL-3.0
 * If you did not receive a copy of the license and are unable to
 * obtain it through the world-wide-web, please send an email
 * to license@prestashop.com so we can send you a copy immediately.
 *
 * DISCLAIMER
 *
 * Do not edit or add to this file if you wish to upgrade PrestaShop to newer
 * versions in the future. If you wish to customize PrestaShop for your
 * needs please refer to https:// devdocs.prestashop.com/ for more information.
*
* @Module		SGK Header
* @Description	Search with suggestions, language and currency selectors, customer account and cart with its add-to-cart window, announcement bar. Replaces five native header modules; the main menu is drawn by SGK Main Menu.
* @Version		1.3.0
* @Copyright	SwissGeek | Web Developer Freelance <https://swissgeek.dev/>
* @support		Support Requests <https://admin.swissgeek.dev/forms/ticket?styled=1&with_logo=1>
* @Blog			Breaking News <https://news.swissgeek.dev/> <https://news.prestageek.ch/>
* @Addons		Developments <https://prestageek.ch/> <https://add.swissgeek.dev/>
*
* @license		http://opensource.org/licenses/afl-3.0.php  Academic Free License (AFL 3.0)
*				Valid for 1 website (or project) for each purchase of license International Registered 
*				Trademark & Property of SwissGeek. More information on <https://swissgeek.dev/license/>
*/

/* SGK Header — front office. Theme-agnostic: colours and fonts come from the SwissGeek theme
   tokens (--sgk-*) when they exist, from Bootstrap (--bs-*) otherwise, then from fallbacks. */

.sgkh {
  --sgkh-accent: var(--sgk-red, var(--bs-primary, #d7141c));
  --sgkh-accent-ink: var(--sgk-red-ink, var(--sgkh-accent));
  --sgkh-accent-text: var(--sgk-red-text, var(--sgkh-accent-ink));
  --sgkh-ink: var(--sgk-graphite, var(--bs-emphasis-color, #2c2f38));
  --sgkh-text: var(--sgk-text, var(--bs-body-color, #2c2f38));
  --sgkh-muted: var(--sgk-muted, var(--bs-secondary-color, #5c6070));
  --sgkh-line: var(--sgk-line, var(--bs-border-color, #e6e7eb));
  --sgkh-surface: var(--sgk-surface, var(--bs-body-bg, #ffffff));
  --sgkh-surface-2: var(--sgk-surface-2, var(--bs-tertiary-bg, #f4f5f7));
  --sgkh-success: var(--sgk-success, #188251);
  --sgkh-radius: var(--sgk-radius, 0.625rem);
  --sgkh-radius-sm: var(--sgk-radius-sm, 0.375rem);
  --sgkh-font: var(--sgk-font-display, inherit);
  --sgkh-shadow: 0 24px 48px -24px rgba(9, 13, 16, 0.35), 0 2px 8px -4px rgba(9, 13, 16, 0.12);
  --sgkh-container: 1320px;
  --sgkh-z: 1050;

  box-sizing: border-box;
}

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

.sgkh .sgkh-svg {
  display: block;
  flex: 0 0 auto;
  width: 1.35rem;
  height: 1.35rem;
}

.sgkh-sr {
  position: absolute !important;
  width: 1px !important;
  height: 1px !important;
  padding: 0 !important;
  margin: -1px !important;
  overflow: hidden !important;
  clip: rect(0, 0, 0, 0) !important;
  white-space: nowrap !important;
  border: 0 !important;
}

html.sgkh-locked,
html.sgkh-locked body {
  overflow: hidden;
}

.sgkh ul {
  padding: 0;
  margin: 0;
  list-style: none;
}

.sgkh p {
  margin: 0;
}

.sgkh button {
  font: inherit;
  color: inherit;
  cursor: pointer;
  background: none;
  border: 0;
}

/* ------------------------------------------------------------------ */
/* Main row                                                            */
/* ------------------------------------------------------------------ */

.sgkh.sgkh-top {
  display: flex;
  flex: 1 1 0%;
  gap: 0.25rem 0.75rem;
  align-items: center;
  align-self: stretch;
  justify-content: flex-end;
  width: auto;
  min-width: 0;
  max-width: 100%;
}

.sgkh-top .sgkh-search {
  margin-left: auto;
}

.sgkh-top__actions {
  display: flex;
  gap: 0.125rem;
  align-items: center;
}

.sgkh-action {
  position: relative;
  display: inline-flex;
  gap: 0.4rem;
  align-items: center;
  min-height: 2.5rem;
  padding: 0.4rem 0.5rem;
  font-family: var(--sgkh-font);
  font-size: 0.875rem;
  font-weight: 600;
  line-height: 1.2;
  color: var(--sgkh-ink);
  text-decoration: none;
  white-space: nowrap;
  background: none;
  border: 0;
  border-radius: var(--sgkh-radius-sm);
  transition: color 0.15s ease;
}

.sgkh-action:hover,
.sgkh-action:focus-visible {
  color: var(--sgkh-accent-text);
  text-decoration: none;
}

.sgkh-action:focus-visible,
.sgkh-dd__btn:focus-visible,
.sgkh-side button:focus-visible,
.sgkh-modal button:focus-visible {
  outline: 2px solid var(--sgkh-accent-text);
  outline-offset: 2px;
}

.sgkh-avatar {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 1.75rem;
  height: 1.75rem;
  font-size: 0.6875rem;
  font-weight: 700;
  letter-spacing: 0.02em;
  color: #fff;
  background: var(--sgkh-accent-ink);
  border-radius: 50%;
}

/* Cart button */
.sgkh-cart__icon {
  position: relative;
  display: inline-flex;
}

.sgkh-cart__badge {
  position: absolute;
  top: -0.45rem;
  right: -0.6rem;
  display: none;
  align-items: center;
  justify-content: center;
  min-width: 1.15rem;
  height: 1.15rem;
  padding: 0 0.3rem;
  font-family: var(--sgkh-font);
  font-size: 0.6875rem;
  font-weight: 700;
  line-height: 1;
  color: #fff;
  background: var(--sgkh-accent-ink);
  border-radius: 999px;
}

.sgkh-cart.is-filled .sgkh-cart__badge {
  display: inline-flex;
}

.sgkh-cart.is-filled .sgkh-cart__icon {
  margin-right: 0.3rem;
}

.sgkh-cart__total {
  font-weight: 700;
  color: var(--sgkh-text);
}

/* ------------------------------------------------------------------ */
/* Top bar                                                             */
/* ------------------------------------------------------------------ */

.sgkh.sgkh-nav {
  display: flex;
  flex-wrap: wrap;
  gap: 0 0.75rem;
  align-items: center;
  justify-content: flex-end;
}

.sgkh-nav .sgkh-action {
  min-height: 2.25rem;
  font-size: 0.8125rem;
}

/* ------------------------------------------------------------------ */
/* Dropdowns (languages, currencies, account)                          */
/* ------------------------------------------------------------------ */

.sgkh-dd {
  position: relative;
}

.sgkh-dd__btn {
  display: inline-flex;
  gap: 0.35rem;
  align-items: center;
  min-height: 2.25rem;
  padding: 0.3rem 0.4rem;
  font-size: 0.8125rem;
  color: var(--sgkh-muted);
  border-radius: var(--sgkh-radius-sm);
}

.sgkh-dd__btn.sgkh-action {
  font-size: 0.8125rem;
  color: var(--sgkh-ink);
}

.sgkh-dd__btn .sgkh-svg {
  width: 1.1rem;
  height: 1.1rem;
}

.sgkh-dd__btn:hover {
  color: var(--sgkh-accent-text);
}

.sgkh-dd__btn > .sgkh-svg:last-child {
  width: 0.95rem;
  height: 0.95rem;
  transition: transform 0.15s ease;
}

.sgkh-dd.is-open .sgkh-dd__btn > .sgkh-svg:last-child {
  transform: rotate(180deg);
}

.sgkh-dd__menu {
  position: absolute;
  top: calc(100% + 0.35rem);
  left: 0;
  z-index: calc(var(--sgkh-z) + 5);
  min-width: 13rem;
  padding: 0.35rem;
  background: var(--sgkh-surface);
  border: 1px solid var(--sgkh-line);
  border-radius: var(--sgkh-radius);
  box-shadow: var(--sgkh-shadow);
}

.sgkh-dd__menu--end,
.sgkh-dd__menu--flip {
  right: 0;
  left: auto;
}

.sgkh-dd__menu[hidden] {
  display: none;
}

.sgkh-dd__item {
  display: flex;
  gap: 0.6rem;
  align-items: center;
  padding: 0.5rem 0.65rem;
  font-size: 0.875rem;
  color: var(--sgkh-text);
  text-decoration: none;
  border-radius: var(--sgkh-radius-sm);
}

.sgkh-dd__item:hover,
.sgkh-dd__item:focus-visible {
  color: var(--sgkh-accent-text);
  text-decoration: none;
  background: var(--sgkh-surface-2);
  outline: none;
}

.sgkh-dd__item .sgkh-svg {
  width: 1.1rem;
  height: 1.1rem;
}

.sgkh-dd__item.is-current {
  font-weight: 600;
  color: var(--sgkh-ink);
}

.sgkh-dd__item.is-current .sgkh-svg:last-child {
  margin-left: auto;
  color: var(--sgkh-accent-text);
}

.sgkh-dd__code {
  min-width: 2.1rem;
  padding: 0.1rem 0.3rem;
  font-size: 0.6875rem;
  font-weight: 700;
  text-align: center;
  letter-spacing: 0.04em;
  color: var(--sgkh-muted);
  background: var(--sgkh-surface-2);
  border-radius: 0.25rem;
}

.sgkh-dd__sep {
  height: 1px;
  margin: 0.3rem 0.35rem;
  background: var(--sgkh-line);
}

/* ------------------------------------------------------------------ */
/* Phones: account, cart, languages and currencies in the main row     */
/* ------------------------------------------------------------------ */

/* Account and cart: in the top bar on wide screens (option), in the main row on phones.
   Languages and currencies: in the top bar on wide screens, behind one button of the main row
   on phones (themes hide their top bar there). */
@media (min-width: 768px) {
  .sgkh--actions-nav .sgkh-top__account,
  .sgkh--actions-nav .sgkh-top__cart,
  .sgkh-top__locale {
    display: none;
  }
}

@media (max-width: 767.98px) {
  .sgkh-nav__account,
  .sgkh-nav__cart,
  .sgkh-nav .sgkh-languages,
  .sgkh-nav .sgkh-currencies {
    display: none;
  }

  .sgkh-top .sgkh-action__label {
    position: absolute !important;
    width: 1px !important;
    height: 1px !important;
    overflow: hidden !important;
    clip: rect(0, 0, 0, 0) !important;
    white-space: nowrap !important;
  }

  .sgkh-top .sgkh-cart__total {
    display: none;
  }
}

/* Language and currency button of phones (as tall as the other icons of the main row) */
.sgkh-locale .sgkh-dd__btn {
  min-height: 2.5rem;
}

.sgkh-locale__codes {
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.03em;
}

.sgkh-locale__menu {
  min-width: 14rem;
  max-width: calc(100vw - 1.5rem);
  padding: 0.75rem 0.85rem 0.85rem;
}

.sgkh-locale__title {
  margin: 0 0 0.4rem;
  font-size: 0.6875rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--sgkh-muted);
}

.sgkh-locale__group {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem;
}

.sgkh-locale__group + .sgkh-locale__title {
  margin-top: 0.85rem;
}

.sgkh-chip {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 2.75rem;
  min-height: 2.5rem;
  padding: 0.25rem 0.6rem;
  font-size: 0.8125rem;
  font-weight: 700;
  color: var(--sgkh-text);
  text-decoration: none;
  background: var(--sgkh-surface);
  border: 1px solid var(--sgkh-line);
  border-radius: 999px;
}

.sgkh-chip:hover,
.sgkh-chip:focus-visible {
  color: var(--sgkh-accent-text);
  text-decoration: none;
  border-color: var(--sgkh-accent);
}

.sgkh-chip:focus-visible {
  outline: 2px solid var(--sgkh-accent-text);
  outline-offset: 2px;
}

.sgkh-chip.is-current,
.sgkh-chip.is-current:hover {
  color: #fff;
  background: var(--sgkh-accent-ink);
  border-color: var(--sgkh-accent-ink);
}

/* ------------------------------------------------------------------ */
/* Side cart, window: shared parts                                     */
/* ------------------------------------------------------------------ */

.sgkh-side {
  position: fixed;
  inset: 0;
  z-index: calc(var(--sgkh-z) + 10);
}

.sgkh-side[hidden] {
  display: none;
}

.sgkh-side__backdrop,
.sgkh-modal__backdrop {
  position: absolute;
  inset: 0;
  background: rgba(9, 13, 16, 0.5);
  opacity: 0;
  transition: opacity 0.2s ease;
}

.sgkh-side.is-open .sgkh-side__backdrop,
.sgkh-modal.is-open .sgkh-modal__backdrop {
  opacity: 1;
}

.sgkh-side__panel {
  position: absolute;
  top: 0;
  right: 0;
  bottom: 0;
  display: flex;
  flex-direction: column;
  width: min(27rem, 94vw);
  color: var(--sgkh-text);
  background: var(--sgkh-surface);
  box-shadow: var(--sgkh-shadow);
  transform: translateX(100%);
  transition: transform 0.22s ease;
}

.sgkh-side.is-open .sgkh-side__panel {
  transform: none;
}

.sgkh-side__head {
  display: flex;
  flex: 0 0 auto;
  gap: 0.5rem;
  align-items: center;
  min-height: 3.75rem;
  padding: 0.5rem 0.75rem 0.5rem 1.25rem;
  border-bottom: 1px solid var(--sgkh-line);
}

.sgkh-side__title {
  flex: 1 1 auto;
  min-width: 0;
  overflow: hidden;
  font-family: var(--sgkh-font);
  font-size: 1.0625rem;
  font-weight: 700;
  color: var(--sgkh-ink);
  text-overflow: ellipsis;
  white-space: nowrap;
}

.sgkh-side__close,
.sgkh-modal__close {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 2.5rem;
  height: 2.5rem;
  color: var(--sgkh-muted);
  border-radius: var(--sgkh-radius-sm);
}

.sgkh-side__close:hover,
.sgkh-modal__close:hover {
  color: var(--sgkh-accent-text);
  background: var(--sgkh-surface-2);
}

.sgkh-side__body {
  flex: 1 1 auto;
  overflow-y: auto;
  overscroll-behavior: contain;
}

/* ------------------------------------------------------------------ */
/* Search                                                              */
/* ------------------------------------------------------------------ */

.sgkh-search {
  position: relative;
}

.sgkh-search__open {
  display: none;
}

.sgkh-search__form {
  position: relative;
  display: flex;
  align-items: center;
  margin: 0;
}

.sgkh-search__icon {
  position: absolute;
  left: 0.85rem;
  display: flex;
  color: var(--sgkh-muted);
  pointer-events: none;
}

.sgkh-search__icon .sgkh-svg {
  width: 1.2rem;
  height: 1.2rem;
}

.sgkh-search.is-loading .sgkh-search__icon {
  animation: sgkh-pulse 0.9s ease-in-out infinite;
}

.sgkh .sgkh-search__input {
  width: clamp(14.5rem, 22vw, 20rem);
  height: 2.625rem;
  padding: 0 1rem 0 2.6rem;
  margin: 0;
  font: inherit;
  font-size: 0.9375rem;
  color: var(--sgkh-text);
  background: var(--sgkh-surface-2);
  border: 1px solid transparent;
  border-radius: 999px;
  box-shadow: none;
  transition: background-color 0.15s ease, border-color 0.15s ease, box-shadow 0.15s ease;
  -webkit-appearance: none;
  appearance: none;
}

.sgkh .sgkh-search__input::placeholder {
  color: var(--sgkh-muted);
  opacity: 1;
}

.sgkh .sgkh-search__input::-webkit-search-cancel-button {
  -webkit-appearance: none;
}

.sgkh .sgkh-search__input:focus {
  background: var(--sgkh-surface);
  border-color: var(--sgkh-accent-text);
  outline: none;
  box-shadow: 0 0 0 3px rgba(215, 20, 28, 0.14);
}

.sgkh-search__close {
  display: none;
  flex: 0 0 auto;
  align-items: center;
  justify-content: center;
  width: 2.5rem;
  height: 2.5rem;
  color: var(--sgkh-muted);
}

.sgkh-search__results {
  position: absolute;
  top: calc(100% + 0.5rem);
  right: 0;
  z-index: calc(var(--sgkh-z) + 5);
  width: max(100%, 25rem);
  max-height: min(70vh, 34rem);
  padding: 0.4rem;
  overflow-y: auto;
  background: var(--sgkh-surface);
  border: 1px solid var(--sgkh-line);
  border-radius: var(--sgkh-radius);
  box-shadow: var(--sgkh-shadow);
}

.sgkh-search__results[hidden] {
  display: none;
}

.sgkh-sugg__heading {
  padding: 0.55rem 0.6rem 0.3rem;
  font-size: 0.6875rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--sgkh-muted);
}

.sgkh-sugg {
  display: flex;
  gap: 0.75rem;
  align-items: center;
  padding: 0.45rem 0.6rem;
  font-size: 0.9rem;
  color: var(--sgkh-text);
  text-decoration: none;
  border-radius: var(--sgkh-radius-sm);
}

.sgkh-sugg:hover,
.sgkh-sugg.is-active {
  color: var(--sgkh-ink);
  text-decoration: none;
  background: var(--sgkh-surface-2);
}

.sgkh-sugg img {
  flex: 0 0 3rem;
  width: 3rem;
  height: 3rem;
  object-fit: contain;
  background: var(--sgkh-surface-2);
  border-radius: var(--sgkh-radius-sm);
}

.sgkh-sugg__body {
  display: flex;
  flex-direction: column;
  gap: 0.15rem;
  min-width: 0;
}

.sgkh-sugg__name {
  overflow: hidden;
  font-weight: 600;
  color: var(--sgkh-ink);
  text-overflow: ellipsis;
  white-space: nowrap;
}

.sgkh-sugg mark {
  padding: 0;
  font-weight: 700;
  color: var(--sgkh-accent-text);
  background: none;
}

.sgkh-sugg__price {
  font-size: 0.8125rem;
  color: var(--sgkh-muted);
}

/* 1.3.0: the regular price keeps the contrast of the muted text (no more transparency) */
.sgkh-sugg__price s {
  color: var(--sgkh-muted);
}

.sgkh-sugg--all {
  justify-content: center;
  margin-top: 0.3rem;
  font-family: var(--sgkh-font);
  font-weight: 600;
  color: var(--sgkh-accent-text);
  border-top: 1px solid var(--sgkh-line);
  border-radius: 0;
}

/* Popular searches (before typing) */
.sgkh-sugg--popular::before {
  flex: 0 0 auto;
  width: 0.5rem;
  height: 0.5rem;
  content: "";
  border: 2px solid var(--sgkh-muted);
  border-radius: 50%;
}

.sgkh-sugg--brand,
.sgkh-sugg--page,
.sgkh-sugg--doc {
  font-weight: 600;
}

/* 1.3.0: groups of the listbox, details of a module (platform, compatibility, version) */
.sgkh-sugg__group + .sgkh-sugg__group {
  margin-top: 0.25rem;
  border-top: 1px solid var(--sgkh-line);
}

.sgkh-sugg__meta {
  display: flex;
  flex-wrap: wrap;
  gap: 0.25rem;
}

.sgkh-sugg__pill {
  display: inline-flex;
  align-items: center;
  min-height: 1.25rem;
  padding: 0 0.4rem;
  font-size: 0.6875rem;
  font-weight: 600;
  line-height: 1.2;
  color: var(--sgkh-text);
  white-space: nowrap;
  background: var(--sgkh-surface-2);
  border: 1px solid var(--sgkh-line);
  border-radius: 999px;
}

.sgkh-sugg__pill--version {
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-weight: 500;
}

.sgkh-sugg__pill--platform.is-wordpress {
  border-color: #2271b1;
}

.sgkh-sugg__pill--edition {
  color: var(--sgkh-accent-text);
  border-color: currentcolor;
}

.sgkh-sugg--doc::before {
  flex: 0 0 auto;
  width: 0.75rem;
  height: 0.875rem;
  content: "";
  border: 2px solid var(--sgkh-muted);
  border-radius: 2px;
}

/* ---------- Announcement bar (displayBanner) ---------- */
.sgkh-ann {
  --sgkh-ann-bg-default: var(--sgk-ink, #090d10);

  color: var(--sgkh-ann-color, #fff);
  background: var(--sgkh-ann-bg, var(--sgkh-ann-bg-default));
}

.sgkh-ann[hidden] {
  display: none !important;
}

.sgkh-ann__inner {
  position: relative;
  display: flex;
  gap: 0.5rem;
  align-items: center;
  max-width: var(--sgkh-container);
  min-height: 2.5rem;
  padding: 0.35rem 1rem;
  margin: 0 auto;
}

.sgkh-ann__track {
  flex: 1 1 auto;
  min-width: 0;
}

.sgkh-ann--center .sgkh-ann__track {
  text-align: center;
}

.sgkh-ann__item {
  margin: 0;
  font-size: 0.875rem;
  font-weight: 600;
  line-height: 1.4;
}

.sgkh-ann__item.is-active {
  animation: sgkh-ann-in 0.35s ease;
}

.sgkh-ann__item a {
  color: inherit;
  text-decoration: underline;
  text-underline-offset: 0.2em;
}

.sgkh-ann__item a:hover,
.sgkh-ann__item a:focus-visible {
  text-decoration-thickness: 2px;
}

.sgkh-ann__close,
.sgkh-ann__pause {
  display: inline-flex;
  flex: 0 0 auto;
  align-items: center;
  justify-content: center;
  width: 2rem;
  height: 2rem;
  padding: 0;
  color: inherit;
  cursor: pointer;
  background: transparent;
  border: 0;
  border-radius: 50%;
}

.sgkh-ann__close:hover,
.sgkh-ann__pause:hover {
  background: rgba(255, 255, 255, 0.14);
}

.sgkh-ann__close:focus-visible,
.sgkh-ann__pause:focus-visible,
.sgkh-ann__item a:focus-visible {
  outline: 2px solid currentColor;
  outline-offset: 2px;
}

.sgkh-ann__close svg {
  width: 1.1rem;
  height: 1.1rem;
}

/* Pause icon (two bars), play icon once paused */
.sgkh-ann__pause-icon {
  width: 0.65rem;
  height: 0.75rem;
  border-right: 3px solid currentColor;
  border-left: 3px solid currentColor;
}

.sgkh-ann.is-paused .sgkh-ann__pause-icon {
  width: 0;
  height: 0;
  border-top: 0.4rem solid transparent;
  border-right: 0;
  border-bottom: 0.4rem solid transparent;
  border-left: 0.65rem solid currentColor;
}

@keyframes sgkh-ann-in {
  from {
    opacity: 0;
    transform: translateY(-0.25rem);
  }
}

@media (prefers-reduced-motion: reduce) {
  .sgkh-ann__item.is-active {
    animation: none;
  }
}

.sgkh-sugg__empty {
  padding: 0.9rem 0.6rem;
  font-size: 0.9rem;
  color: var(--sgkh-muted);
  text-align: center;
}

@keyframes sgkh-pulse {
  50% {
    opacity: 0.35;
  }
}

@media (max-width: 767.98px) {
  .sgkh-search__open {
    display: inline-flex;
  }

  .sgkh-search__form {
    display: none;
  }

  .sgkh-search.is-open .sgkh-search__form {
    position: fixed;
    top: 0;
    right: 0;
    left: 0;
    z-index: calc(var(--sgkh-z) + 12);
    display: flex;
    gap: 0.35rem;
    padding: 0.65rem 0.5rem 0.65rem 0.75rem;
    background: var(--sgkh-surface);
    border-bottom: 1px solid var(--sgkh-line);
    box-shadow: var(--sgkh-shadow);
  }

  .sgkh-search.is-open .sgkh-search__icon {
    left: 1.6rem;
  }

  .sgkh .sgkh-search.is-open .sgkh-search__input {
    flex: 1 1 auto;
    width: auto;
    font-size: 1rem;
  }

  .sgkh-search.is-open .sgkh-search__close {
    display: inline-flex;
  }

  .sgkh-search.is-open .sgkh-search__results {
    position: fixed;
    top: 4rem;
    right: 0.5rem;
    left: 0.5rem;
    width: auto;
    max-height: calc(100vh - 5rem);
  }
}

/* ------------------------------------------------------------------ */
/* Side cart, window, toast                                            */
/* ------------------------------------------------------------------ */

.sgkh-side__body {
  padding: 1rem 1.25rem 1.25rem;
}

.sgkh-side__loading {
  padding: 2rem 0;
  color: var(--sgkh-muted);
  text-align: center;
}

.sgkh-lines {
  margin-bottom: 1rem !important;
}

.sgkh-line {
  display: grid;
  grid-template-columns: 4rem minmax(0, 1fr) auto;
  gap: 0.85rem;
  align-items: start;
  padding: 0.85rem 0;
  border-bottom: 1px solid var(--sgkh-line);
}

.sgkh-line__media img {
  display: block;
  width: 4rem;
  height: 4rem;
  object-fit: contain;
  background: var(--sgkh-surface-2);
  border-radius: var(--sgkh-radius-sm);
}

.sgkh-line__name {
  display: block;
  font-family: var(--sgkh-font);
  font-size: 0.9375rem;
  font-weight: 600;
  line-height: 1.3;
  color: var(--sgkh-ink);
  text-decoration: none;
}

.sgkh-line__name:hover {
  color: var(--sgkh-accent-text);
}

.sgkh-line__attrs {
  margin-top: 0.2rem !important;
  font-size: 0.8125rem;
  color: var(--sgkh-muted);
}

.sgkh-line__meta {
  display: flex;
  gap: 0.5rem;
  align-items: baseline;
  justify-content: space-between;
  margin-top: 0.35rem !important;
  font-size: 0.875rem;
}

.sgkh-line__qty {
  color: var(--sgkh-muted);
}

.sgkh-line__remove {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 2.25rem;
  height: 2.25rem;
  color: var(--sgkh-muted);
  border-radius: var(--sgkh-radius-sm);
}

.sgkh-line__remove .sgkh-svg {
  width: 1.1rem;
  height: 1.1rem;
}

.sgkh-line__remove:hover {
  color: var(--sgkh-accent-text);
  background: var(--sgkh-surface-2);
}

.sgkh-line__remove[disabled] {
  opacity: 0.4;
}

.sgkh-sum__row {
  display: flex;
  gap: 1rem;
  justify-content: space-between;
  padding: 0.3rem 0;
  font-size: 0.9375rem;
}

.sgkh-sum__row--total {
  padding-top: 0.6rem;
  margin-top: 0.3rem !important;
  font-family: var(--sgkh-font);
  font-size: 1.0625rem;
  font-weight: 700;
  color: var(--sgkh-ink);
  border-top: 1px solid var(--sgkh-line);
}

.sgkh-sum__note {
  margin-top: 0.3rem !important;
  font-size: 0.8125rem;
  color: var(--sgkh-muted);
}

.sgkh-side__actions {
  position: sticky;
  bottom: -1.25rem;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.5rem;
  padding: 1rem 0 1.25rem;
  margin-top: 0.75rem;
  background: var(--sgkh-surface);
}

.sgkh-empty {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  align-items: center;
  padding: 3rem 1rem;
  color: var(--sgkh-muted);
  text-align: center;
}

.sgkh-empty .sgkh-svg {
  width: 2.5rem;
  height: 2.5rem;
}

.sgkh-btn {
  display: inline-flex;
  gap: 0.4rem;
  align-items: center;
  justify-content: center;
  min-height: 2.75rem;
  padding: 0.6rem 1.1rem;
  font-family: var(--sgkh-font);
  font-size: 0.9375rem;
  font-weight: 600;
  line-height: 1.2;
  text-align: center;
  text-decoration: none;
  border: 1px solid transparent;
  border-radius: var(--sgkh-radius-sm);
  transition: background-color 0.15s ease, border-color 0.15s ease, color 0.15s ease;
}

.sgkh .sgkh-btn--primary,
.sgkh .sgkh-btn--primary:visited {
  color: #fff;
  background: var(--sgkh-accent-ink);
  border-color: var(--sgkh-accent-ink);
}

.sgkh .sgkh-btn--primary:hover,
.sgkh .sgkh-btn--primary:focus-visible {
  color: #fff;
  text-decoration: none;
  filter: brightness(0.92);
}

.sgkh .sgkh-btn--ghost {
  color: var(--sgkh-ink);
  background: transparent;
  border-color: var(--sgkh-line);
}

.sgkh .sgkh-btn--ghost:hover,
.sgkh .sgkh-btn--ghost:focus-visible {
  color: var(--sgkh-accent-text);
  text-decoration: none;
  border-color: var(--sgkh-accent);
}

.sgkh-free {
  padding: 0.75rem 0.85rem;
  margin: 0.25rem 0 0.5rem;
  font-size: 0.8125rem;
  background: var(--sgkh-surface-2);
  border-radius: var(--sgkh-radius-sm);
}

.sgkh-free__text {
  display: flex;
  gap: 0.5rem;
  align-items: center;
  color: var(--sgkh-text);
}

.sgkh-free__text .sgkh-svg {
  width: 1.15rem;
  height: 1.15rem;
  color: var(--sgkh-accent-text);
}

.sgkh-free__bar {
  display: block;
  height: 0.375rem;
  margin-top: 0.5rem;
  overflow: hidden;
  background: var(--sgkh-line);
  border-radius: 999px;
}

.sgkh-free__bar > span {
  display: block;
  height: 100%;
  background: var(--sgkh-accent);
  border-radius: inherit;
  transition: width 0.3s ease;
}

.sgkh-free.is-reached .sgkh-free__text .sgkh-svg {
  color: var(--sgkh-success);
}

.sgkh-free.is-reached .sgkh-free__bar > span {
  background: var(--sgkh-success);
}

/* Add-to-cart window */
.sgkh.sgkh-modal {
  position: fixed;
  inset: 0;
  z-index: calc(var(--sgkh-z) + 20);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1rem;
}

.sgkh-modal__dialog {
  position: relative;
  display: flex;
  flex-direction: column;
  width: 100%;
  max-width: 46rem;
  max-height: calc(100vh - 2rem);
  overflow: hidden;
  color: var(--sgkh-text);
  background: var(--sgkh-surface);
  border-radius: var(--sgkh-radius);
  box-shadow: var(--sgkh-shadow);
  opacity: 0;
  transform: translateY(12px) scale(0.98);
  transition: opacity 0.2s ease, transform 0.2s ease;
}

.sgkh-modal.is-open .sgkh-modal__dialog {
  opacity: 1;
  transform: none;
}

.sgkh-modal__head {
  display: flex;
  gap: 1rem;
  align-items: center;
  justify-content: space-between;
  padding: 1rem 1rem 1rem 1.5rem;
  border-bottom: 1px solid var(--sgkh-line);
}

.sgkh-modal__title {
  display: flex;
  gap: 0.6rem;
  align-items: center;
  font-family: var(--sgkh-font);
  font-size: 1.125rem;
  font-weight: 700;
  color: var(--sgkh-ink);
}

.sgkh-modal__tick {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 1.75rem;
  height: 1.75rem;
  color: #fff;
  background: var(--sgkh-success);
  border-radius: 50%;
}

.sgkh-modal__tick .sgkh-svg {
  width: 1rem;
  height: 1rem;
}

.sgkh-modal__body {
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(0, 1fr);
  gap: 1.5rem;
  padding: 1.5rem;
  overflow-y: auto;
}

.sgkh-modal__product {
  display: flex;
  gap: 1rem;
  align-items: flex-start;
}

.sgkh-modal__image {
  flex: 0 0 7.5rem;
  width: 7.5rem;
  height: 7.5rem;
  object-fit: contain;
  background: var(--sgkh-surface-2);
  border-radius: var(--sgkh-radius-sm);
}

.sgkh-modal__name {
  font-family: var(--sgkh-font);
  font-size: 1.0625rem;
  font-weight: 700;
  line-height: 1.3;
  color: var(--sgkh-ink);
}

.sgkh-modal__attr,
.sgkh-modal__qty {
  margin-top: 0.25rem !important;
  font-size: 0.875rem;
  color: var(--sgkh-muted);
}

.sgkh-modal__price {
  margin-top: 0.5rem !important;
  font-size: 1rem;
  font-weight: 700;
  color: var(--sgkh-ink);
}

.sgkh-modal__summary {
  padding-left: 1.5rem;
  border-left: 1px solid var(--sgkh-line);
}

.sgkh-modal__count {
  margin-bottom: 0.5rem !important;
  font-size: 0.875rem;
  color: var(--sgkh-muted);
}

.sgkh-modal__foot {
  display: flex;
  flex-wrap: wrap;
  gap: 0.6rem;
  justify-content: flex-end;
  padding: 1rem 1.5rem;
  background: var(--sgkh-surface-2);
  border-top: 1px solid var(--sgkh-line);
}

.sgkh-modal__extra {
  padding: 0 1.5rem 1rem;
  background: var(--sgkh-surface-2);
}

@media (max-width: 639.98px) {
  .sgkh.sgkh-modal {
    align-items: flex-end;
    padding: 0;
  }

  .sgkh-modal__dialog {
    max-height: 92vh;
    border-radius: var(--sgkh-radius) var(--sgkh-radius) 0 0;
  }

  .sgkh-modal__body {
    grid-template-columns: 1fr;
    gap: 1rem;
    padding: 1rem 1.25rem;
  }

  .sgkh-modal__summary {
    padding: 1rem 0 0;
    border-top: 1px solid var(--sgkh-line);
    border-left: 0;
  }

  .sgkh-modal__image {
    flex-basis: 5rem;
    width: 5rem;
    height: 5rem;
  }

  .sgkh-modal__foot {
    flex-direction: column-reverse;
    padding: 0.85rem 1.25rem 1.25rem;
  }

  .sgkh-modal__foot .sgkh-btn {
    width: 100%;
  }
}

/* Notification after an add to cart */
.sgkh.sgkh-toast {
  position: fixed;
  right: 1.25rem;
  bottom: 1.25rem;
  z-index: calc(var(--sgkh-z) + 30);
  display: flex;
  gap: 1rem;
  align-items: center;
  max-width: min(26rem, calc(100vw - 2.5rem));
  padding: 0.85rem 1.1rem;
  font-size: 0.9rem;
  color: #fff;
  background: #11161b;
  border-radius: var(--sgkh-radius);
  box-shadow: var(--sgkh-shadow);
  opacity: 0;
  transform: translateY(1rem);
  transition: opacity 0.25s ease, transform 0.25s ease;
}

.sgkh.sgkh-toast.is-open {
  opacity: 1;
  transform: none;
}

.sgkh-toast a {
  flex: 0 0 auto;
  font-weight: 700;
  color: #fff;
  text-decoration: underline;
}

@media (prefers-reduced-motion: reduce) {
  .sgkh *,
  .sgkh.sgkh-toast,
  .sgkh-side__panel,
  .sgkh-modal__dialog {
    transition: none !important;
    animation: none !important;
  }
}
