/* Блок покупки «Мастер Офис» — стили из buy-approved.js, подключаются в <head> product.html, чтобы кнопки не мигали при загрузке (Claude 16.11) */
:is(#pBuy, .el-buy__cart, .elements .eltile .eltile__foot .el__buy){position:relative;isolation:isolate;overflow:hidden;
  display:flex!important;flex-direction:column;align-items:center;justify-content:center;gap:1px;line-height:1.15!important;
  white-space:nowrap;text-align:center;font-weight:600;color:#fff!important;cursor:pointer;
  border:1px solid #a42654!important;border-radius:999px!important;
  box-shadow:inset 0 1px 2px #ffffff55,inset 0 -1px 2px #ffffff22,0 3px 0 #080808,0 13px 18px -6px #0005!important;
  transform:translateY(-2px);transition:transform .35s,box-shadow .35s,background .3s!important}
:is(#pBuy, .el-buy__cart, .elements .eltile .eltile__foot .el__buy):not(.is-added),
.mbuy__btn[data-purchase="element"]:not(.is-added){
  border:1px solid #a42654!important;
  background:linear-gradient(180deg,#41444a 0%,#33363c 25%,#292c32 70%,#303339)!important}
:is(#pBuy, .el-buy__cart, .elements .eltile .eltile__foot .el__buy):not(.is-added):is(:hover,:focus-visible){
  transform:translateY(-4px);background:linear-gradient(165deg,#64122f,#302630 65%,#292c32)!important;
  box-shadow:inset 0 1px 2px #fffc,inset 0 -2px 5px #e578a3,0 0 0 1px #a42654,0 4px 0 #160a10,0 15px 22px -7px #0006,0 0 23px #a4265488!important}
:is(#pBuy, .el-buy__cart, .elements .eltile .eltile__foot .el__buy)::before{content:'';position:absolute;inset:3px;border-radius:inherit;pointer-events:none;z-index:-1;
  background:radial-gradient(ellipse at 75% 0%,#fff9,transparent 35%),radial-gradient(ellipse at 18% 100%,#ee7ba9,transparent 42%),linear-gradient(165deg,#a42654aa,transparent 55%,#a4265477);
  opacity:0;transition:opacity .4s}
:is(#pBuy, .el-buy__cart, .elements .eltile .eltile__foot .el__buy)::after{content:'';position:absolute;width:150%;height:100%;left:-25%;top:-45%;border-radius:50%;pointer-events:none;z-index:-1;
  background:linear-gradient(180deg,#fff8,#fff1);opacity:0;transform:rotate(-8deg) translateX(-15%);transition:opacity .4s,transform .8s}
:is(#pBuy, .el-buy__cart, .elements .eltile .eltile__foot .el__buy):is(:hover,:focus-visible)::before{opacity:1}
:is(#pBuy, .el-buy__cart, .elements .eltile .eltile__foot .el__buy):is(:hover,:focus-visible)::after{opacity:.8;transform:rotate(-8deg) translateX(10%)}
:is(#pBuy, .el-buy__cart).is-added,
.mbuy__btn[data-purchase="element"].is-added{background:linear-gradient(155deg,#A42654 0%,#963058 55%,#7d2347 100%)!important;border:1px solid #8f2149!important}
:is(#pBuy, .el-buy__cart, .elements .eltile .eltile__foot .el__buy) small{display:block;font-size:11.5px;font-weight:400;opacity:.9;line-height:1.1}
:is(#pBuy, .el-buy__cart, .elements .eltile .eltile__foot .el__buy):focus-visible{outline:3px solid #A42654;outline-offset:3px}
/* товар без комплектации и страница позиции */
.pbuy__row.eltile__foot,.el-buy__row.eltile__foot{display:flex!important;align-items:center!important;gap:8px!important;flex-wrap:nowrap}
.pbuy__row .elqty,.el-buy__row .elqty{flex:0 0 104px!important;width:104px;height:50px!important;min-height:0!important}
.pbuy__row .elqty button,.el-buy__row .elqty button{width:30px}
#pBuy,.el-buy__cart{flex:1 1 auto!important;min-width:140px!important;width:auto!important;max-width:300px;height:54px!important;min-height:54px!important;padding:0 14px!important;margin:0!important;font-size:15px!important}
/* Отдельный товар (кресла, стулья, вешалки… — #pBuy). Иван 13.11, повторно на kreslo-ofisnoe-rv-8074 (cart-count-preview «Фирменный градиент»):
   слева «− N +» 112×50, справа широкая прямоугольная плашка с мягкими углами 11 px и бордовым градиентом — без овала, канта-ореола и бликов.
   До добавления «В корзину», после — «В корзине N шт.» и ниже «Перейти →». Блок виден всегда (не скрывается при наведении). */
.pbuy .pbuy__row.eltile__foot{gap:10px!important}
.pbuy .pbuy__row .elqty{flex:0 0 112px!important;width:112px}
.pbuy .pbuy__row #pBuy,.pbuy .pbuy__row #pBuy.is-added,.pbuy .pbuy__row #pBuy:not(.is-added):is(:hover,:focus-visible){
  flex:1 1 200px!important;min-width:200px!important;max-width:380px!important;height:54px!important;min-height:54px!important;padding:8px 14px!important;
  border-radius:11px!important;color:#fff!important;
  box-shadow:none!important;transform:none!important;font-size:15px!important;transition:filter .2s!important}
.pbuy .pbuy__row #pBuy,.pbuy .pbuy__row #pBuy.is-added,.pbuy .pbuy__row #pBuy:not(.is-added):is(:hover,:focus-visible),
.mbuy__btn[data-purchase="product"]{border:1px solid #ddd1d7!important;background:linear-gradient(120deg,#a32957,#462535)!important}
.pbuy .pbuy__row #pBuy:is(:hover,:focus-visible){filter:brightness(1.08)}
.pbuy .pbuy__row #pBuy::before,.pbuy .pbuy__row #pBuy::after{display:none!important}
.pbuy .pbuy__row #pBuy small{font-size:11px!important;margin-top:3px}
@media(max-width:600px){
  .pbuy .pbuy__row.eltile__foot{flex-wrap:nowrap!important}
  .pbuy .pbuy__row #pBuy,.pbuy .pbuy__row #pBuy.is-added{min-width:0!important;flex:1 1 auto!important;padding:8px 10px!important;font-size:14px!important}
}
/* широкая карточка (цена, ♥, «поделиться» в одном ряду): количество и плашка — отдельной строкой во всю ширину, иначе цена обрезается */
@media(min-width:601px){
  .pinfo--w .pbuy:has(#pBuy){grid-template-columns:minmax(0,1fr) auto!important}
  .pinfo--w .pbuy:has(#pBuy) .pbuy__price{grid-column:1!important;justify-self:start;text-align:left}
  .pinfo--w .pbuy:has(#pBuy) .pw-icons{grid-column:2!important}
  .pinfo--w .pbuy:has(#pBuy) .pbuy__act{grid-column:1 / -1!important;width:100%;align-items:stretch}
  .pinfo--w .pbuy:has(#pBuy) .pbuy__row{width:100%}
  .pinfo--w .pbuy__sum b{white-space:nowrap}
}
/* карточки серии: количество слева, кнопка справа с надписью */
.elements .eltile .eltile__foot{display:flex!important;align-items:center!important;gap:6px!important;flex-wrap:nowrap;margin-top:auto}
.elements .eltile .eltile__foot .elqty{display:flex!important;flex:0 0 74px!important;width:74px;height:38px!important;min-width:0!important}
.elements .eltile .eltile__foot .elqty button{width:21px}
.elements .eltile .eltile__foot .el__buy{flex:1 1 auto!important;width:auto!important;min-width:0!important;max-width:none!important;height:38px!important;min-height:38px!important;
  padding:0 10px!important;margin:0!important;font-size:12.5px!important;background-image:none;transform:none;
  box-shadow:inset 0 1px 2px #ffffff55,inset 0 -1px 2px #ffffff22,0 2px 0 #080808,0 8px 12px -6px #0005!important}
.elements .eltile .eltile__foot .el__buy:not(.is-added):is(:hover,:focus-visible){transform:translateY(-2px)}
@media(max-width:600px){
  .elements .eltile .eltile__foot{flex-wrap:wrap!important}
  .elements .eltile .eltile__foot .elqty{flex:1 1 100%!important;width:100%}
  .elements .eltile .eltile__foot .el__buy{flex:1 1 100%!important}
  .pbuy__row.eltile__foot,.el-buy__row.eltile__foot{flex-wrap:wrap}
  #pBuy,.el-buy__cart{max-width:none;flex:1 1 150px!important}
}
/* Иван 13.11 (предпросмотр «ivan-hover-review» на kabinet-laym-yasen): в карточках позиций с мышью «− N +» во всю ширину,
   «В корзину» скрыта; при наведении или фокусе внутри карточки поле плавно сужается и справа выезжает кнопка 86 px.
   Высота карточки не меняется. Телефон (нет наведения) — кнопка видна всегда (правила выше).
   Основной блок покупки (#pBuy, страница позиции) не затронут — он не в .elements. */
@media (hover:hover) and (pointer:fine){
  #product .elements .eltile .eltile__foot{width:100%!important;display:flex!important;gap:0!important;flex-wrap:nowrap!important}
  #product .elements .eltile .eltile__foot .elqty{flex:1 1 0!important;width:auto!important;max-width:none!important;transition:flex-basis .22s ease,width .22s ease!important}
  #product .elements .eltile .eltile__foot .el__buy{box-sizing:border-box!important;flex:0 0 0!important;width:0!important;min-width:0!important;
    padding:0!important;margin:0!important;border-width:0!important;overflow:hidden!important;opacity:0!important;pointer-events:none!important;
    white-space:nowrap!important;transition:flex-basis .22s ease,width .22s ease,margin .22s ease,opacity .22s ease!important}
  #product .elements .eltile:is(:hover,:focus-within) .eltile__foot .el__buy{flex-basis:86px!important;width:86px!important;margin-left:6px!important;
    border-width:1px!important;opacity:1!important;pointer-events:auto!important}
}
@media (hover:hover) and (pointer:fine) and (prefers-reduced-motion:reduce){
  #product .elements .eltile .eltile__foot :is(.elqty,.el__buy){transition:none!important}
}
@media(prefers-reduced-motion:reduce){:is(#pBuy,.el-buy__cart,.elements .eltile .eltile__foot .el__buy),:is(#pBuy,.el-buy__cart,.elements .eltile .eltile__foot .el__buy)::before,:is(#pBuy,.el-buy__cart,.elements .eltile .eltile__foot .el__buy)::after{transition:none!important;transform:none!important}}
/* Иван 25.11 (vybor-knopka-korzina.html, вариант 1 «Бордо»): карточки серии.
   Обычный вид — как был (антрацит с бордовым кантом). Наведение — чистая бордовая кнопка без бликов и серых разводов.
   В корзине — бордовая кнопка, карточка белая с бордовой рамкой (вместо тауп из cart-taupe.js), подпись «В корзине N шт.» бордовая.
   #mo-tile — несуществующий id: даёт правилам вес id, чтобы перебить :is(#pBuy,…) выше и стили cart-taupe.js. Телефон (mobile-shell.css, иконка) не трогаем. */
:is(#mo-tile, .elements .eltile .eltile__foot .el__buy)::before,
:is(#mo-tile, .elements .eltile .eltile__foot .el__buy)::after{display:none!important}
:is(#mo-tile, .elements .eltile .eltile__foot .el__buy):not(.is-added):is(:hover,:focus-visible){
  background:linear-gradient(180deg,#c0356b 0%,#a42654 45%,#861d44 100%)!important;border-color:#861d44!important;
  box-shadow:inset 0 1px 2px #ffffff66,0 2px 0 #4e0f27,0 10px 16px -6px #a4265477!important}
:is(#mo-tile, .elements .eltile .eltile__foot .el__buy).is-added{
  background:linear-gradient(180deg,#b02c5e,#8a1d45)!important;border:1px solid #7a1a3e!important;color:#fff!important;
  box-shadow:inset 0 1px 2px #ffffff55,0 2px 0 #4e0f27,0 8px 12px -6px #0004!important}
:is(#mo-tile, .elements .eltile .eltile__foot .el__buy).is-added:is(:hover,:focus-visible){
  background:linear-gradient(180deg,#c0356b,#9a2350)!important;transform:translateY(-2px)}
/* Иван 26.11 (vybor-v-korzine.html, вариант 1, но серый): карточка в корзине — светло-серый фон и серая рамка, поле количества белое */
:is(#mo-tile, .elements) .eltile:has(.el__buy.is-added){background:#f0f0f2!important;border-color:#c4c4ca!important;box-shadow:none!important}
:is(#mo-tile, .elements) .eltile:has(.el__buy.is-added) .elqty{background:#fff!important;border-color:#c4c4ca!important}
:is(#mo-tile, .elements) .eltile .taupe-qty{color:#A42654!important}
