/* ═══════════════════════════════════════════════════════════════════════
   Корзина, мини-корзина, оформление заказа, личный кабинет (IPROD, 07.11.2026)
   Шаблоны: woocommerce/cart/*, woocommerce/checkout/form-checkout.php, review-order.php,
   woocommerce/myaccount/*, page-my-account.php; логика: inc/shop-flow.php.
   Подключается на всех страницах (выезжающая корзина есть везде), после fd-woo.css.
   ═══════════════════════════════════════════════════════════════════════ */
:root{
  --fd-shop-line: #ECE4F5;          /* разделители строк */
  --fd-shop-field: #D9CDEA;         /* рамка полей и кнопок выбора */
  --fd-shop-muted: #6E6878;         /* второстепенный текст: 5,4:1 на белом */
  --fd-shop-radius: 20px;
  --fd-shop-sticky: 104px;          /* отступ липких колонок под шапкой */
}

/* ── Каркас страницы ── */
.fd-shop{ padding: 28px 40px 96px; color: var(--fd-ink); }
.fd-shop__inner{ max-width: 1200px; margin: 0 auto; }
.fd-shop__title{
  font-family: var(--fd-display);
  font-weight: 800;
  font-size: clamp(32px, 4vw, 48px);
  line-height: 1.05;
  letter-spacing: -0.02em;
  margin: 0 0 28px;
  color: var(--fd-ink);
}
.fd-panel{
  background: #fff;
  border-radius: var(--fd-shop-radius);
  box-shadow: var(--fd-card-shadow);
  padding: 28px;
}
.fd-shop :is(.fd-summary__title, .fd-co__step-title, .fd-acc__title, .fd-acc__content h2){
  font-family: var(--fd-display);
  font-weight: 700;
  font-size: 22px;
  line-height: 1.2;
  letter-spacing: -0.01em;
  margin: 0 0 18px;
  color: var(--fd-ink);
}
.fd-shop a:not(.fd-btn):not(.button){ text-underline-offset: 3px; }
.fd-shop ::selection, .fd-mc ::selection{ background: var(--fd-purple-soft); color: var(--fd-ink); }

/* ── Поля форм ── */
.fd-co__fields,
.fd-shop .woocommerce-address-fields__field-wrapper{
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
}
.fd-co__fields::before, .fd-co__fields::after,
.fd-shop .woocommerce-address-fields__field-wrapper::before,
.fd-shop .woocommerce-address-fields__field-wrapper::after{ display: none; }
.fd-shop .form-row,
.fd-shop .woocommerce form .form-row{
  float: none;
  width: auto;
  margin: 0;
  padding: 0;
  grid-column: 1 / -1;
}
.fd-shop :is(.fd-co__fields, .woocommerce-address-fields__field-wrapper) .form-row-first{ grid-column: 1; }
.fd-shop :is(.fd-co__fields, .woocommerce-address-fields__field-wrapper) .form-row-last{ grid-column: 2; }
.fd-shop .fd-field-hidden{ display: none !important; } /* страна: всегда Узбекистан */
.fd-shop .form-row label,
.fd-shop .woocommerce form .form-row label{
  display: block;
  margin: 0 0 6px;
  font-family: var(--fd-body);
  font-size: 14px;
  font-weight: 500;
  line-height: 1.4;
  letter-spacing: 0;
  text-transform: none;
  color: var(--fd-ink-soft);
}
.fd-shop .form-row .required{ color: var(--fd-purple-deep); text-decoration: none; border: 0; }
.fd-shop .form-row .optional{ color: var(--fd-shop-muted); font-weight: 400; }
.fd-shop .form-row .description{ display: block; margin-top: 6px; font-size: 13px; color: var(--fd-shop-muted); }
.fd-shop :is(input.input-text, input[type="text"], input[type="email"], input[type="tel"], input[type="password"], select, textarea):not(.fd-qty__input),
.fd-input{
  display: block;
  width: 100%;
  height: 50px;
  padding: 0 16px;
  border: 1.5px solid var(--fd-shop-field);
  border-radius: 12px;
  background-color: #fff;
  font-family: var(--fd-body);
  font-size: 16px;               /* меньше 16px: iPhone увеличивает страницу при вводе */
  line-height: 1.3;
  color: var(--fd-ink);
  box-shadow: none;
  transition: border-color .2s;
}
.fd-shop textarea{ height: auto; min-height: 96px; padding: 12px 16px; resize: vertical; }
.fd-shop select{
  appearance: none;
  -webkit-appearance: none;
  padding-right: 44px;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath d='M1 1.5 6 6.5l5-5' fill='none' stroke='%231F1F1F' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 16px center;
  cursor: pointer;
}
.fd-shop ::placeholder{ color: #8F8A99; opacity: 1; }
.fd-shop :is(input, select, textarea):hover:not(:focus):not(.fd-qty__input){ border-color: #BFAEDA; }
.fd-shop :is(input, select, textarea):focus:not(.fd-qty__input),
.fd-input:focus{
  outline: none;
  border-color: var(--fd-purple-deep);
}
.fd-shop :is(input, select, textarea):focus-visible:not(.fd-qty__input){
  outline: 3px solid rgba(139, 93, 191, .22);
  outline-offset: 0;
}
.fd-shop form .form-row.woocommerce-invalid :is(input.input-text, select, textarea){ border-color: var(--fd-red); }
.fd-shop form .form-row.woocommerce-validated :is(input.input-text, select){ border-color: var(--fd-shop-field); } /* без зелёной рамки у каждого заполненного поля */
.fd-shop form .form-row.woocommerce-invalid label{ color: var(--fd-ink-soft); }
.fd-shop ul.woocommerce-error{ display: block; list-style: none; }
.fd-shop ul.woocommerce-error a{ color: inherit; text-decoration: none; }
.fd-shop .checkout-inline-error-message{ margin: 6px 0 0; font-size: 13px; color: #B3202E; }
.fd-shop .woocommerce-input-wrapper{ display: block; }
.fd-shop .password-input{ display: block; position: relative; }
.fd-shop .show-password-input{ top: 50%; transform: translateY(-50%); right: 14px; }

/* чекбокс «Запомнить меня» и т.п. */
.fd-check{ display: inline-flex; align-items: center; gap: 10px; font-size: 15px; color: var(--fd-ink-soft); cursor: pointer; }
.fd-check input{ width: 18px; height: 18px; margin: 0; accent-color: var(--fd-ink); }

/* кнопки WooCommerce внутри страниц магазина: как основная кнопка сайта */
.fd-shop :is(.button, button.button, a.button, input.button){
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 48px;
  padding: 12px 24px;
  border: 1.5px solid var(--fd-ink);
  border-radius: 10px;
  background: var(--fd-ink);
  color: #fff;
  font-family: var(--fd-body);
  font-size: 13px;
  font-weight: 700;
  letter-spacing: .08em;
  text-transform: uppercase;
  text-decoration: none;
  line-height: 1.2;
  box-shadow: none;
  transform: none;
  transition: background-color .2s, border-color .2s, color .2s;
}
.fd-shop :is(.button, button.button, a.button, input.button):hover{
  background: var(--fd-purple-deep);
  border-color: var(--fd-purple-deep);
  color: #fff;
}
.fd-shop .fd-btn i, .fd-mc .fd-btn i{ font-size: 14px; }

/* ── Уведомления на страницах магазина: ровная рамка, без цветной полосы слева ── */
.fd-shop :is(.woocommerce-message, .woocommerce-info, .woocommerce-error),
.woocommerce-cart .woocommerce-notices-wrapper :is(.woocommerce-message, .woocommerce-info, .woocommerce-error){
  border: 1px solid var(--fd-shop-line);
  border-radius: 14px;
  background: #fff;
  box-shadow: none;
  padding: 14px 18px;
  margin: 0 0 20px;
  font-size: 15px;
  line-height: 1.5;
  color: var(--fd-ink);
}
.fd-shop .woocommerce-error{ border-color: rgba(226, 55, 68, .4); background: #FFF7F8; }
.fd-shop .woocommerce-error li{ margin: 0; padding: 2px 0; }
.fd-shop :is(.woocommerce-message, .woocommerce-info) .button{ order: 2; margin-left: auto; min-height: 40px; padding: 8px 16px; font-size: 12px; }
.woocommerce-cart .fd-page-wrap > .woocommerce > .woocommerce-notices-wrapper{ max-width: 1200px; margin: 0 auto; padding: 28px 40px 0; }
.woocommerce-cart .fd-page-wrap > .woocommerce > .woocommerce-notices-wrapper:empty{ display: none; }

/* ── Сумма заказа (корзина, оформление) ── */
.fd-summary__rows{ margin: 0; padding: 0; }
.fd-summary__row{
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 16px;
  padding: 8px 0;
  font-size: 15px;
}
.fd-summary__row dt{ color: var(--fd-ink-soft); font-weight: 400; margin: 0; }
.fd-summary__row dd{ margin: 0; font-weight: 600; color: var(--fd-ink); white-space: nowrap; text-align: right; font-variant-numeric: tabular-nums; }
.fd-summary__count{ color: var(--fd-shop-muted); }
.fd-summary__row--total{
  margin-top: 8px;
  padding-top: 16px;
  border-top: 1px solid var(--fd-shop-line);
  align-items: center;
}
.fd-summary__row--total dt{ color: var(--fd-ink); font-weight: 700; font-size: 17px; }
.fd-summary__row--total dd{ font-family: var(--fd-display); font-weight: 800; font-size: 26px; letter-spacing: -0.01em; }
.fd-summary__row dd .woocommerce-Price-amount{ font: inherit; }
.fd-summary__row dd small{ display: none; } /* «(включая налог)»: налоги не считаются */
.fd-summary__note{ margin: 10px 0 0; font-size: 13px; line-height: 1.5; color: var(--fd-shop-muted); }
.fd-summary__note a{ color: var(--fd-purple-deep); text-decoration: underline; }
.fd-summary__wc-shipping{ width: 100%; border-collapse: collapse; font-size: 15px; }
.fd-summary__cta{ width: 100%; height: 56px; margin-top: 22px; justify-content: space-between; padding: 0 22px; }
.fd-summary__back{
  display: block;
  margin-top: 14px;
  text-align: center;
  font-size: 15px;
  font-weight: 600;
  color: var(--fd-ink-soft);
  text-decoration: underline;
  text-decoration-color: var(--fd-shop-field);
}
.fd-summary__back:hover{ color: var(--fd-purple-deep); text-decoration-color: currentColor; }

/* ── Количество − / + ── */
.fd-qty{
  display: inline-flex;
  align-items: center;
  height: 44px;
  border: 1.5px solid var(--fd-shop-field);
  border-radius: 12px;
  background: #fff;
  transition: border-color .2s;
}
.fd-qty:focus-within{ border-color: var(--fd-purple-deep); }
.fd-qty__btn{
  display: grid;
  place-items: center;
  width: 40px;
  height: 100%;
  padding: 0;
  border: 0;
  border-radius: 10px;
  background: none;
  color: var(--fd-ink);
  font-size: 12px;
  cursor: pointer;
  transition: color .2s;
}
.fd-qty__btn:hover:not(:disabled){ color: var(--fd-purple-deep); background: none; }
.fd-qty__btn:disabled{ color: #C4BDCF; cursor: default; }
.fd-qty__btn:focus-visible{ outline: 2px solid var(--fd-purple-deep); outline-offset: -2px; }
.fd-shop .fd-qty__input, .fd-mc .fd-qty__input{
  width: 40px;
  height: 100%;
  margin: 0;
  padding: 0;
  border: 0;
  background: none;
  box-shadow: none;
  text-align: center;
  font-family: var(--fd-body);
  font-size: 16px;
  font-weight: 600;
  color: var(--fd-ink);
  font-variant-numeric: tabular-nums;
  -moz-appearance: textfield;
  appearance: textfield;
}
.fd-qty__input::-webkit-outer-spin-button,
.fd-qty__input::-webkit-inner-spin-button{ -webkit-appearance: none; margin: 0; }
.fd-qty__input:focus{ outline: none; }
.fd-qty--sm{ height: 38px; }
.fd-qty--sm .fd-qty__btn{ width: 34px; }
.fd-qty--sm .fd-qty__input{ width: 34px; font-size: 15px; }

/* ═══════════ КОРЗИНА ═══════════ */
.fd-cartpage{
  display: grid;
  grid-template-columns: minmax(0, 1fr) 380px;
  gap: 28px;
  align-items: start;
}
.fd-cartpage__form{ padding: 4px 28px; margin: 0; }
.fd-cartpage__aside{ position: sticky; top: var(--fd-shop-sticky); }
.fd-lines{ list-style: none; margin: 0; padding: 0; }
.fd-line{
  display: grid;
  grid-template-columns: 88px minmax(0, 1fr) auto 128px 40px;
  grid-template-areas: "thumb info qty total remove";
  align-items: center;
  gap: 20px;
  padding: 20px 0;
  border-bottom: 1px solid var(--fd-shop-line);
}
.fd-line:last-child{ border-bottom: 0; }
.fd-line__thumb{
  grid-area: thumb;
  display: grid;
  place-items: center;
  width: 88px;
  height: 88px;
  border-radius: 14px;
  background: var(--fd-bg-soft);
  overflow: hidden;
}
.fd-line__thumb img{ width: 100%; height: 100%; object-fit: contain; }
.fd-line__info{ grid-area: info; min-width: 0; display: flex; flex-direction: column; gap: 4px; }
.fd-line__name{
  font-family: var(--fd-display);
  font-weight: 700;
  font-size: 18px;
  line-height: 1.2;
  color: var(--fd-ink);
  text-decoration: none;
  text-wrap: balance;
}
a.fd-line__name:hover{ color: var(--fd-purple-deep); }
.fd-line__price{ font-size: 14px; color: var(--fd-shop-muted); }
.fd-line__qty{ grid-area: qty; }
.fd-line__one{ display: inline-block; min-width: 40px; text-align: center; font-weight: 600; }
.fd-line__total{
  grid-area: total;
  text-align: right;
  font-weight: 700;
  font-size: 17px;
  white-space: nowrap;
  font-variant-numeric: tabular-nums;
}
.fd-line__remove{ grid-area: remove; display: flex; justify-content: flex-end; }
.fd-shop a.remove.fd-line__remove-btn{
  display: grid;
  place-items: center;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  color: var(--fd-shop-muted) !important;   /* WooCommerce красит a.remove в красный с !important */
  background: transparent;
  font-size: 16px;
  line-height: 1;
  transition: color .2s, background-color .2s;
}
.fd-shop a.remove.fd-line__remove-btn:hover{ color: var(--fd-ink) !important; background: var(--fd-bg-soft); }
.fd-cartpage__actions{ display: flex; flex-wrap: wrap; gap: 12px; }
.fd-cartpage__actions:not(:has(.fd-coupon)){ display: block; height: 0; }
.fd-coupon{ display: flex; gap: 10px; padding: 16px 0 20px; flex: 1 1 320px; }
.fd-coupon .fd-input{ max-width: 240px; }
/* «Обновить корзину»: количество применяется само, кнопку оставляем для cart.js и работы без скриптов */
.fd-shop .fd-cartpage__update{
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
  border: 0;
}

/* пустая корзина */
.fd-cart-empty{ padding: 56px 28px; text-align: center; }
.fd-cart-empty__icon{ font-size: 40px; color: var(--fd-purple-deep); margin-bottom: 18px; }
.fd-cart-empty__text{ max-width: 46ch; margin: 0 auto 24px; font-size: 17px; line-height: 1.55; color: var(--fd-ink-soft); }

/* ═══════════ ОФОРМЛЕНИЕ ЗАКАЗА ═══════════ */
.fd-co{
  display: grid;
  grid-template-columns: minmax(0, 1fr) 400px;
  grid-template-areas:
    "notices notices"
    "customer aside"
    "pay aside";
  grid-template-rows: auto auto 1fr;
  column-gap: 28px;
  align-items: start;
}
.fd-co > .woocommerce-NoticeGroup{ grid-area: notices; }
.fd-co__customer{ grid-area: customer; display: grid; gap: 20px; margin-bottom: 20px; }
.fd-co__aside{ grid-area: aside; position: sticky; top: var(--fd-shop-sticky); }
.fd-co__step--pay{ grid-area: pay; }
.fd-co__customer > h3{ display: none; }

/* комментарий: по ссылке, чтобы не добавлять поле всем */
.fd-co__note{ margin-top: 16px; }
.fd-co__note-toggle{
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px 0;
  font-size: 15px;
  font-weight: 600;
  color: var(--fd-purple-deep);
  cursor: pointer;
  list-style: none;
}
.fd-co__note-toggle::-webkit-details-marker{ display: none; }
.fd-co__note-toggle:hover{ text-decoration: underline; text-underline-offset: 3px; }
.fd-co__note[open] .fd-co__note-toggle{ margin-bottom: 10px; }
.fd-co__note .form-row label{ position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }

/* состав заказа */
.fd-review__items{
  list-style: none;
  margin: 0 0 8px;
  padding: 0;
  max-height: 420px;
  overflow: auto;
  overscroll-behavior: contain;
  scrollbar-width: thin;
  scrollbar-color: var(--fd-shop-field) transparent;
}
.fd-review__item{
  display: grid;
  grid-template-columns: 56px minmax(0, 1fr) auto;
  align-items: center;
  gap: 12px;
  padding: 10px 0;
  border-bottom: 1px solid var(--fd-shop-line);
}
.fd-review__thumb{
  display: grid;
  place-items: center;
  width: 56px;
  height: 56px;
  border-radius: 12px;
  background: var(--fd-bg-soft);
  overflow: hidden;
}
.fd-review__thumb img{ width: 100%; height: 100%; object-fit: contain; }
.fd-review__name{ font-size: 14px; font-weight: 600; line-height: 1.3; color: var(--fd-ink); }
.fd-review__meta{ display: block; margin-top: 2px; font-weight: 400; color: var(--fd-shop-muted); font-size: 13px; }
.fd-review__sum{ font-size: 14px; font-weight: 600; white-space: nowrap; font-variant-numeric: tabular-nums; }

/* способы оплаты: выбранный: тёмная рамка */
:is(.fd-shop, .woocommerce-order-pay) #payment{ background: none; border-radius: 0; padding: 0; }
:is(.fd-shop, .woocommerce-order-pay) #payment ul.payment_methods{
  display: grid;
  gap: 10px;
  margin: 0 0 20px;
  padding: 0;
  border: 0;
  list-style: none;
}
:is(.fd-shop, .woocommerce-order-pay) #payment ul.payment_methods::before, :is(.fd-shop, .woocommerce-order-pay) #payment ul.payment_methods::after{ display: none; }
:is(.fd-shop, .woocommerce-order-pay) #payment ul.payment_methods > li.wc_payment_method{
  position: relative;
  margin: 0;
  padding: 0;
  border: 1.5px solid var(--fd-shop-field);
  border-radius: 14px;
  background: #fff;
  line-height: 1.4;
  transition: border-color .2s;
}
:is(.fd-shop, .woocommerce-order-pay) #payment ul.payment_methods > li.wc_payment_method:hover{ border-color: #BFAEDA; }
:is(.fd-shop, .woocommerce-order-pay) #payment ul.payment_methods > li.wc_payment_method:has(input:checked){ border-color: var(--fd-ink); }
:is(.fd-shop, .woocommerce-order-pay) #payment ul.payment_methods > li > input.input-radio{
  position: absolute;
  top: 19px;
  left: 18px;
  width: 18px;
  height: 18px;
  margin: 0;
  accent-color: var(--fd-ink);
  cursor: pointer;
}
:is(.fd-shop, .woocommerce-order-pay) #payment ul.payment_methods > li > label{
  display: flex;
  align-items: center;
  gap: 10px;
  margin: 0;
  padding: 16px 18px 16px 48px;
  font-size: 16px;
  font-weight: 600;
  color: var(--fd-ink);
  cursor: pointer;
}
:is(.fd-shop, .woocommerce-order-pay) #payment ul.payment_methods > li > label img{ max-height: 24px; margin: 0 0 0 auto; }
:is(.fd-shop, .woocommerce-order-pay) #payment div.payment_box{
  margin: -6px 0 0;
  padding: 0 18px 16px 48px;
  background: none;
  font-size: 14px;
  line-height: 1.5;
  color: var(--fd-ink-soft);
}
:is(.fd-shop, .woocommerce-order-pay) #payment div.payment_box::before{ display: none; }
:is(.fd-shop, .woocommerce-order-pay) #payment div.payment_box p{ margin: 0; }
:is(.fd-shop, .woocommerce-order-pay) #payment div.place-order.form-row{ margin: 0; padding: 0; }
:is(.fd-shop, .woocommerce-order-pay) #payment .woocommerce-privacy-policy-text,
:is(.fd-shop, .woocommerce-order-pay) #payment .woocommerce-terms-and-conditions-wrapper{ font-size: 13px; color: var(--fd-shop-muted); margin-bottom: 14px; }
:is(.fd-shop, .woocommerce-order-pay) #payment #place_order{
  float: none;
  width: 100%;
  height: 56px;
  margin: 0;
  font-size: 14px;
}

/* ═══════════ МИНИ-КОРЗИНА ═══════════ */
.fd-mc{ position: fixed; inset: 0; z-index: 100000; } /* выше кнопки «наверх» (10000) и Chaty */
.fd-mc[hidden]{ display: none; }
.fd-mc__overlay{
  position: absolute;
  inset: 0;
  background: rgba(31, 22, 43, .42);
  opacity: 0;
  transition: opacity .25s ease-out;
}
.fd-mc__panel{
  position: absolute;
  top: 0;
  right: 0;
  bottom: 0;
  width: min(440px, 100%);
  display: flex;
  flex-direction: column;
  background: #fff;
  color: var(--fd-ink);
  box-shadow: -24px 0 48px -28px rgba(115, 84, 162, .45);
  transform: translateX(100%);
  transition: transform .32s cubic-bezier(.22, 1, .36, 1);
  outline: none;
}
.fd-mc.is-open .fd-mc__overlay{ opacity: 1; }
.fd-mc.is-open .fd-mc__panel{ transform: none; }
html.fd-mc-lock, html.fd-mc-lock body{ overflow: hidden; }
.fd-mc__head{
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 18px 24px;
  border-bottom: 1px solid var(--fd-shop-line);
}
.fd-mc__title{
  margin: 0;
  font-family: var(--fd-display);
  font-weight: 700;
  font-size: 24px;
  line-height: 1.1;
  color: var(--fd-ink);
}
.fd-mc__close{
  display: grid;
  place-items: center;
  width: 44px;
  height: 44px;
  padding: 0;
  border: 1.5px solid var(--fd-shop-field);
  border-radius: 50%;
  background: #fff;
  color: var(--fd-ink);
  font-size: 18px;
  cursor: pointer;
  transition: border-color .2s;
}
.fd-mc__close:hover{ border-color: var(--fd-ink); background: #fff; color: var(--fd-ink); }
.fd-mc__close:focus-visible, .fd-mc-item__remove:focus-visible{ outline: 2px solid var(--fd-purple-deep); outline-offset: 2px; }
.fd-mc__body, .fd-mc__body .widget_shopping_cart_content{
  flex: 1;
  min-height: 0;
  display: flex;
  flex-direction: column;
}
.fd-mc__list{
  flex: 1;
  min-height: 0;
  margin: 0;
  padding: 4px 24px;
  list-style: none;
  overflow-y: auto;
  overscroll-behavior: contain;
  scrollbar-width: thin;
  scrollbar-color: var(--fd-shop-field) transparent;
}
.fd-mc-item{
  display: grid;
  grid-template-columns: 76px minmax(0, 1fr) auto;
  align-items: start;
  gap: 14px;
  padding: 16px 0;
  border-bottom: 1px solid var(--fd-shop-line);
  transition: opacity .15s;
}
.fd-mc-item:last-child{ border-bottom: 0; }
.fd-mc-item.is-busy{ opacity: .5; pointer-events: none; }
.fd-mc-item__thumb{
  display: grid;
  place-items: center;
  width: 76px;
  height: 76px;
  border-radius: 12px;
  background: var(--fd-bg-soft);
  overflow: hidden;
}
.fd-mc-item__thumb img{ width: 100%; height: 100%; object-fit: contain; }
.fd-mc-item__info{ min-width: 0; }
.fd-mc-item__name{
  display: block;
  font-family: var(--fd-display);
  font-weight: 700;
  font-size: 16px;
  line-height: 1.2;
  color: var(--fd-ink);
  text-decoration: none;
}
.fd-mc-item__name:hover{ color: var(--fd-purple-deep); }
.fd-mc-item__price{ display: block; margin: 3px 0 10px; font-size: 13px; color: var(--fd-shop-muted); }
.fd-mc-item__row{ display: flex; align-items: center; gap: 8px; }
.fd-mc-item__one{ font-size: 14px; font-weight: 600; }
.fd-mc-item__remove{
  display: grid;
  place-items: center;
  width: 38px;
  height: 38px;
  padding: 0;
  border: 0;
  border-radius: 10px;
  background: none;
  color: var(--fd-shop-muted);
  font-size: 15px;
  cursor: pointer;
  transition: color .2s, background-color .2s;
}
.fd-mc-item__remove:hover{ color: var(--fd-ink); background: var(--fd-bg-soft); }
.fd-mc-item__total{ font-size: 15px; font-weight: 700; white-space: nowrap; font-variant-numeric: tabular-nums; }
.fd-mc__foot{
  padding: 18px 24px calc(18px + env(safe-area-inset-bottom));
  border-top: 1px solid var(--fd-shop-line);
  background: #fff;
}
.fd-mc__sum{ display: flex; justify-content: space-between; align-items: baseline; gap: 16px; font-size: 15px; color: var(--fd-ink-soft); }
.fd-mc__sum strong{ font-family: var(--fd-display); font-weight: 800; font-size: 24px; color: var(--fd-ink); font-variant-numeric: tabular-nums; }
.fd-mc__note{ margin: 2px 0 16px; font-size: 13px; color: var(--fd-shop-muted); }
.fd-mc__checkout{ width: 100%; height: 54px; justify-content: space-between; padding: 0 22px; }
.fd-mc__cartlink{
  display: block;
  margin-top: 12px;
  text-align: center;
  font-size: 15px;
  font-weight: 600;
  color: var(--fd-ink-soft);
  text-decoration: underline;
  text-decoration-color: var(--fd-shop-field);
  text-underline-offset: 3px;
}
.fd-mc__cartlink:hover{ color: var(--fd-purple-deep); text-decoration-color: currentColor; }
.fd-mc__empty{ margin: auto 0; padding: 48px 24px; text-align: center; }
.fd-mc__empty-text{ margin: 0 0 20px; font-size: 16px; color: var(--fd-ink-soft); }
.fd-mc__loading{ padding: 20px 24px; display: grid; gap: 16px; }
.fd-mc__skel{ display: block; height: 76px; border-radius: 12px; background: var(--fd-bg-soft); animation: fd-mc-wait 1.2s ease-in-out infinite alternate; }
@keyframes fd-mc-wait{ from{ opacity: 1; } to{ opacity: .45; } }

/* кнопки шапки: кабинет рядом с корзиной */
.fd-pill--account{ font-size: 17px; }
.fd-pill--icon[aria-expanded="true"]{ border-color: var(--fd-purple-deep); background: #fff; }

/* ═══════════ ЛИЧНЫЙ КАБИНЕТ ═══════════ */
.fd-acc{
  display: grid;
  grid-template-columns: 260px minmax(0, 1fr);
  gap: 28px;
  align-items: start;
}
.fd-acc__nav{ position: sticky; top: var(--fd-shop-sticky); }
.fd-acc__who{ margin: 0 0 14px; padding: 0 6px; line-height: 1.35; }
.fd-acc__who strong{ display: block; font-family: var(--fd-display); font-size: 20px; font-weight: 700; color: var(--fd-ink); }
.fd-acc__who span{ display: block; font-size: 14px; color: var(--fd-shop-muted); overflow-wrap: anywhere; }
.fd-acc__nav ul{
  margin: 0;
  padding: 8px;
  list-style: none;
  background: #fff;
  border-radius: var(--fd-shop-radius);
  box-shadow: var(--fd-card-shadow);
}
.fd-acc__nav li{ margin: 0; }
.fd-acc__nav li a{
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 14px;
  border-radius: 12px;
  font-size: 15px;
  font-weight: 600;
  color: var(--fd-ink-soft);
  text-decoration: none;
  transition: background-color .2s, color .2s;
}
.fd-acc__nav li a i{ width: 18px; text-align: center; color: var(--fd-purple-deep); }
.fd-acc__nav li a:hover{ color: var(--fd-ink); background: var(--fd-bg-soft); }
.fd-acc__nav li.is-active a{ color: var(--fd-ink); background: var(--fd-bg); font-weight: 700; }
.fd-acc__nav li.woocommerce-MyAccount-navigation-link--customer-logout{ margin-top: 6px; padding-top: 6px; border-top: 1px solid var(--fd-shop-line); }
.fd-acc__nav li.woocommerce-MyAccount-navigation-link--customer-logout a i{ color: var(--fd-shop-muted); }
.fd-acc__content{ padding: 32px; min-width: 0; }
.fd-acc__content > p:first-child:not([class]){ margin-top: 0; }
.fd-acc__content p{ font-size: 15px; line-height: 1.6; color: var(--fd-ink-soft); max-width: 70ch; }
.fd-acc__form > .fd-btn, .fd-shop .woocommerce-address-fields > p:last-child{ margin-top: 24px; }
.fd-acc__fieldset{ margin: 28px 0 0; padding: 24px 0 0; border: 0; border-top: 1px solid var(--fd-shop-line); }
.fd-acc__fieldset legend{ padding: 0; font-family: var(--fd-display); font-size: 18px; font-weight: 700; color: var(--fd-ink); }
.fd-acc__hint{ margin: 4px 0 16px; font-size: 14px; color: var(--fd-shop-muted); }
.fd-shop .woocommerce-address-fields .button{ margin-top: 0; }

/* таблицы заказов */
.fd-shop table.shop_table{
  width: 100%;
  margin: 0;
  border: 0;
  border-collapse: collapse;
  border-radius: 0;
  font-size: 15px;
}
.fd-shop table.shop_table :is(th, td){
  padding: 14px 12px;
  border: 0;
  border-bottom: 1px solid var(--fd-shop-line);
  text-align: left;
  vertical-align: middle;
  background: none;
  font-variant-numeric: tabular-nums;
}
.fd-shop table.shop_table thead th{ font-size: 13px; font-weight: 600; color: var(--fd-shop-muted); padding-top: 0; }
.fd-shop table.shop_table :is(th, td):first-child{ padding-left: 0; }
.fd-shop table.shop_table :is(th, td):last-child{ padding-right: 0; }
.fd-shop table.shop_table tbody tr:last-child td{ border-bottom: 0; }
.fd-shop .woocommerce-orders-table__cell-order-number a{ font-weight: 700; color: var(--fd-ink); }
.fd-shop .woocommerce-orders-table__cell-order-actions{ text-align: right; }
.fd-shop .woocommerce-orders-table .button{ min-height: 38px; padding: 8px 14px; font-size: 12px; background: #fff; color: var(--fd-ink); }
.fd-shop .woocommerce-orders-table .button:hover{ background: var(--fd-ink); border-color: var(--fd-ink); color: #fff; }
.fd-shop .woocommerce-pagination{ margin-top: 20px; display: flex; gap: 10px; }
.fd-shop .woocommerce-order-details, .fd-shop .woocommerce-customer-details{ margin-top: 28px; }
.fd-shop :is(.woocommerce-order-details__title, .woocommerce-column__title){ font-family: var(--fd-display); font-size: 20px; font-weight: 700; margin: 0 0 12px; }
.fd-shop .woocommerce-customer-details address{ border: 1px solid var(--fd-shop-line); border-radius: 14px; padding: 16px 18px; font-style: normal; line-height: 1.6; }
.fd-shop mark{ background: none; color: var(--fd-ink); font-weight: 700; }

/* вход и регистрация */
.fd-auth{ display: grid; gap: 24px; max-width: 560px; }
.fd-auth--two{ grid-template-columns: repeat(2, minmax(0, 1fr)); max-width: none; align-items: start; }
.fd-auth__box{ padding: 32px; }
.fd-shop .fd-auth__box form.woocommerce-form{ display: grid; gap: 16px; margin: 0; padding: 0; border: 0; border-radius: 0; } /* у WooCommerce у форм входа своя рамка */
.fd-auth__lead{ margin: -6px 0 18px; font-size: 15px; line-height: 1.55; color: var(--fd-ink-soft); max-width: 52ch; }
.fd-auth__row{ display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 12px; }
.fd-auth__link{ font-size: 15px; font-weight: 600; color: var(--fd-purple-deep); text-decoration: underline; text-underline-offset: 3px; }
.fd-auth__submit{ width: 100%; height: 52px; margin-top: 4px; }
.fd-shop .woocommerce-privacy-policy-text p{ margin: 0; font-size: 13px; color: var(--fd-shop-muted); }
.fd-shop .woocommerce-password-strength{ margin-top: 8px; padding: 6px 10px; border-radius: 8px; font-size: 13px; text-align: left; }
.fd-shop .woocommerce-password-hint{ display: block; margin-top: 6px; font-size: 13px; color: var(--fd-shop-muted); }
.fd-shop form.woocommerce-ResetPassword{ display: grid; gap: 16px; max-width: 560px; }

/* ── WooCommerce задаёт полям ширину 47% и красит «Подтвердить заказ» в свой фиолетовый более сильными
      селекторами (.woocommerce form .form-row-first, .woocommerce button.button.alt) ── */
.fd-shop form .form-row.form-row{ float: none; width: auto; margin: 0; padding: 0; }
.fd-shop form .form-row.form-row label{ line-height: 1.4; }
:is(.fd-shop, .woocommerce-order-pay) #payment #place_order,
.fd-shop .button.alt.alt{
  background: var(--fd-ink);
  border: 1.5px solid var(--fd-ink);
  border-radius: 10px;
  color: #fff;
  font-family: var(--fd-body);
  font-weight: 700;
  letter-spacing: .08em;
  text-transform: uppercase;
  box-shadow: none;
  transform: none;
}
:is(.fd-shop, .woocommerce-order-pay) #payment #place_order:hover,
.fd-shop .button.alt.alt:hover{
  background: var(--fd-purple-deep);
  border-color: var(--fd-purple-deep);
  color: #fff;
}
:is(.fd-shop, .woocommerce-order-pay) #payment #place_order:focus-visible{ outline: 2px solid var(--fd-purple-deep); outline-offset: 2px; }

/* WooCommerce ставит меню кабинета float 30%, содержимое 68% */
.fd-shop .fd-acc > :is(.fd-acc__nav, .fd-acc__content){ float: none; width: auto; margin: 0; }
/* кнопки в уведомлениях: старые правила fd-woo.css красят их в фиолетовый с !important */
.fd-shop :is(.woocommerce-message, .woocommerce-info) .button{
  background: var(--fd-ink) !important;
  color: #fff !important;
  border: 1.5px solid var(--fd-ink) !important;
  font-family: var(--fd-body) !important;
  margin: 0 0 0 auto !important;
}
.fd-shop :is(.woocommerce-message, .woocommerce-info) .button:hover{
  background: var(--fd-purple-deep) !important;
  border-color: var(--fd-purple-deep) !important;
}
/* логотип Click у способа оплаты */
:is(.fd-shop, .woocommerce-order-pay) #payment ul.payment_methods > li > label img{ height: 22px; width: auto; max-height: none; margin: 0 0 0 auto; }

/* ═══════════ Адаптив ═══════════ */
@media (max-width: 1100px){
  .fd-cartpage{ grid-template-columns: minmax(0, 1fr) 340px; }
  .fd-co{ grid-template-columns: minmax(0, 1fr) 360px; }
}
@media (max-width: 960px){
  .fd-cartpage{ grid-template-columns: 1fr; }
  .fd-cartpage__aside{ position: static; }
  .fd-co{
    grid-template-columns: minmax(0, 1fr);
    grid-template-areas: "notices" "customer" "aside" "pay";
    grid-template-rows: auto;
  }
  .fd-co__aside{ position: static; margin-bottom: 20px; }
  .fd-review__items{ max-height: none; }
  .fd-acc{ grid-template-columns: minmax(0, 1fr); gap: 16px; }
  .fd-acc__nav{ position: static; }
  .fd-acc__who{ display: none; }
  .fd-acc__nav ul{ display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 4px; }
  .fd-acc__nav li a{ padding: 11px 12px; font-size: 14px; }
  .fd-acc__nav li.woocommerce-MyAccount-navigation-link--customer-logout{ margin: 0; padding: 0; border: 0; }
  .fd-auth--two{ grid-template-columns: minmax(0, 1fr); }
}
@media (max-width: 720px){
  .fd-shop{ padding: 20px 16px 64px; }
  .fd-shop__title{ margin-bottom: 20px; }
  .fd-panel{ padding: 20px; border-radius: 18px; }
  .fd-cartpage__form{ padding: 0 20px; }
  .fd-line{
    grid-template-columns: 72px auto minmax(0, 1fr) 40px;
    grid-template-areas:
      "thumb info info remove"
      "thumb qty total total";
    gap: 10px 14px;
    align-items: start;
    padding: 18px 0;
  }
  .fd-line__thumb{ width: 72px; height: 72px; }
  .fd-line__name{ font-size: 16px; }
  .fd-line__remove{ margin: -8px -8px 0 0; }
  .fd-line__total{ align-self: center; font-size: 16px; text-align: right; }
  .fd-line__qty{ align-self: center; }
  .fd-co__fields, .fd-shop .woocommerce-address-fields__field-wrapper{ grid-template-columns: minmax(0, 1fr); }
  .fd-shop :is(.fd-co__fields, .woocommerce-address-fields__field-wrapper) :is(.form-row-first, .form-row-last){ grid-column: 1 / -1; }
  .fd-shop :is(.fd-summary__title, .fd-co__step-title, .fd-acc__title, .fd-acc__content h2){ font-size: 20px; margin-bottom: 14px; }
  .fd-acc__content{ padding: 20px; }
  .fd-auth__box{ padding: 24px 20px; }
  .fd-mc__head{ padding: 14px 16px; }
  .fd-mc__list{ padding: 4px 16px; }
  .fd-mc__foot{ padding: 16px 16px calc(16px + env(safe-area-inset-bottom)); }
  .fd-shop table.shop_table_responsive tr{ display: block; padding: 12px 0; border-bottom: 1px solid var(--fd-shop-line); }
  .fd-shop table.shop_table_responsive tr td{ display: flex; justify-content: space-between; gap: 12px; padding: 6px 0; border: 0; text-align: right !important; }
  .fd-shop table.shop_table_responsive tr td::before{ font-weight: 400; color: var(--fd-shop-muted); }
}
@media (max-width: 400px){
  .fd-cartpage__form{ padding: 0 14px; }
  .fd-line{ grid-template-columns: 60px auto minmax(0, 1fr) 36px; gap: 10px; }
  .fd-line__thumb{ width: 60px; height: 60px; border-radius: 12px; }
  .fd-line .fd-qty{ height: 40px; }
  .fd-line .fd-qty__btn{ width: 34px; }
  .fd-line .fd-qty__input{ width: 32px; }
  .fd-line__total{ font-size: 15px; }
}
@media (prefers-reduced-motion: reduce){
  .fd-mc__overlay, .fd-mc__panel, .fd-mc-item{ transition: none; }
  .fd-mc__skel{ animation: none; }
}
