/* AP+ Магазин/Store: shared readable type, restrained surfaces, and equal shop/service journeys. */
:root{
  --space-1:.5rem;--space-2:1rem;--space-3:1.5rem;--space-4:2rem;--space-5:3rem;
  --r-sm:.625rem;--r-md:1rem;--r-lg:1.5rem;
  --bg:#f7f9fc;--fg:#192332;--muted:#536174;--border:#dce3ed;--border-strong:#aab8cb;
  --accent:#8e2036;--accent-hover:#71172a;--accent-soft:#f8edf0;
  --line:var(--border);--shadow-sm:0 2px 8px #192d4305;
}
html{scroll-padding-top:6rem}
body{font-size:1rem;line-height:1.6}
h1,h2,h3,h4{text-wrap:balance}
input,select,textarea{font-size:1rem}
input::placeholder,textarea::placeholder{color:#66758a;opacity:1}
button,a,input,select,textarea,summary{-webkit-tap-highlight-color:transparent}
button,a,summary{touch-action:manipulation}
:focus-visible{outline:3px solid var(--accent);outline-offset:4px}
.header-search:focus-within,.balance-search:focus-within,.search-bar .field:focus-within{outline:2px solid var(--accent);outline-offset:3px;border-radius:.75rem}
.btn{height:auto;min-height:3rem;padding:.75rem 1.25rem;font-size:.9375rem;line-height:1.4;white-space:normal;text-align:center;border-radius:.75rem}
.btn-sm{min-height:2.75rem;padding:.625rem 1rem;font-size:.875rem}
.btn-lg{min-height:3.25rem;font-size:1rem}
.btn:disabled{cursor:wait;opacity:.65}
.btn:disabled:not(.is-loading){cursor:not-allowed}
.btn.is-loading{opacity:1;cursor:progress;pointer-events:none}
.btn.is-loading:before{content:'';width:1rem;height:1rem;border:2px solid currentColor;border-right-color:transparent;border-radius:50%;animation:button-spin .8s linear infinite;flex-shrink:0}
@keyframes button-spin{to{transform:rotate(360deg)}}
.btn-secondary:disabled:hover,.btn-ghost:disabled:hover{background:var(--surface-2);border-color:var(--border)}
input:disabled,select:disabled,textarea:disabled{background:var(--surface-2)!important;color:var(--muted);cursor:not-allowed;opacity:1}
input[aria-invalid=true],select[aria-invalid=true],textarea[aria-invalid=true]{border-color:#a02525!important;outline-color:#a02525!important;box-shadow:0 0 0 1px #a02525}
input[type=checkbox][aria-invalid=true]{outline:2px solid #a02525;outline-offset:3px;box-shadow:none}
.form-guidance{font-size:.875rem;line-height:1.6;color:var(--muted);margin:0 0 1.25rem}
.form-error:not(:empty){padding:.875rem 1rem;background:#fff3f1;border:1px solid #e3b5ac;border-radius:.75rem;overflow-wrap:anywhere}
.form-error:empty{margin:0;padding:0}
[aria-busy=true] input,[aria-busy=true] select,[aria-busy=true] textarea{cursor:progress}
.not-found{min-height:65vh;padding-block:clamp(3rem,8vw,7rem);max-width:50rem}
.not-found h1{font-size:clamp(2rem,5vw,3.5rem);margin-bottom:1.25rem;line-height:1.12}
.not-found>p:not(.balance-kicker){max-width:53ch;color:var(--muted);font-size:1rem}
.not-found-actions{display:flex;flex-wrap:wrap;gap:1rem;margin:2rem 0 1rem}
.not-found-actions .btn{min-width:10rem}
#request-lookup{margin-top:1.5rem;max-width:50rem}
#request-lookup>.btn{margin-top:1.5rem}
#request-status:not(:empty){margin-top:1.25rem;overflow-wrap:anywhere}
.product-card .name,.product-card .sku,.pd-title,.ti-sum .v,.admin-request h2{overflow-wrap:anywhere}
.product-card .body,.cart-item>*,.ti-sum .v{min-width:0}
.ph-media{max-width:100%;min-width:0;overflow-wrap:anywhere}
.ph-media .ph-line1{font-size:.875rem;line-height:1.4}
.ph-media .ph-line2{font-size:.875rem;line-height:1.6}
input[type=checkbox]{width:1.125rem;height:1.125rem;min-height:0;flex-shrink:0}
.link-arrow{min-height:2.75rem;line-height:1.5}
.site-header{container:site-header / inline-size}
.header-inner{height:auto;min-height:4.5rem;padding-block:.625rem;flex-wrap:wrap}
.site-header .main-nav{flex:0 1 auto;flex-wrap:wrap}
.site-header .header-search{flex:1 1 12rem;min-width:12rem}
.site-header .cart-btn{flex-shrink:0;margin-left:auto}
.logo.brand-lockup{gap:.625rem;min-width:0;line-height:1;text-decoration:none}
.site-header .brand-lockup{min-height:2.75rem;flex:0 0 auto}
.logo-mark{width:2.5rem;height:2.5rem;padding:0;overflow:hidden;border-radius:.75rem;background:#000;box-shadow:0 0 0 1px #ffffff1f}
.logo-mark img{display:block;width:100%;height:100%;object-fit:contain}
.brand-copy{display:flex;min-width:0;flex-direction:column;justify-content:center;line-height:1}
.brand-primary{font-size:1.5rem;font-weight:800;letter-spacing:-.035em;white-space:nowrap}
.footer-brand .brand-primary{color:#fff}
.nav-link{min-height:2.75rem;display:inline-flex;align-items:center;font-size:.9375rem}
.cart-btn,.menu-toggle,.mm-close,.header-search input{min-height:2.75rem}
.cart-badge[hidden]{display:none}
.menu-toggle{flex-shrink:0}
.section-head{gap:var(--space-3);margin-bottom:var(--space-4)}
.section-head .sub{font-size:1rem;line-height:1.6;max-width:60ch;margin-top:.75rem}
.product-card{border-radius:var(--r-md);box-shadow:var(--shadow-sm)}
.product-card:hover{transform:none;box-shadow:var(--shadow-sm);border-color:#98aac3}
.product-card .media{height:auto;aspect-ratio:1;min-height:0;overflow:hidden;grid-template-rows:auto minmax(0,1fr);place-items:stretch}
.product-card .card-labels{display:flex;flex-wrap:wrap;align-items:center;gap:.5rem;min-height:2.5rem;padding:.75rem .75rem 0}
.product-card .card-media-stage{display:grid;grid-template-rows:minmax(0,1fr);place-items:center;min-width:0;min-height:0;overflow:hidden;padding:.5rem}
.product-card .media .m-wrap{min-width:0;min-height:0;width:82%;height:82%;display:grid;grid-template-rows:minmax(0,1fr);place-items:center}
.product-card .media .m-wrap img{width:100%;height:100%;min-height:0;max-height:100%;object-fit:contain}
.product-card .body{padding:1.25rem;gap:.625rem}
.product-card .name{font-size:1rem;line-height:1.45}
.product-card .brand{font-size:.75rem}
.product-card .sku{font-size:.75rem;line-height:1.5;font-variant-numeric:tabular-nums}
.product-card .btn{min-height:2.75rem;font-size:.875rem;padding:.75rem .875rem}
.product-card .price-row{padding-top:1rem}
.pd-model,.pd-crumb,.pd-price .note,.pd-service li,.pd-authenticity{font-size:.875rem;line-height:1.6}
.pd-title{line-height:1.2;letter-spacing:-.025em}
.pd-actions .btn{min-height:3.25rem}
.pd-service{padding:1.25rem}
.pd-service h4{font-size:1rem}
.variant-offer{min-height:3rem;font-size:1rem}
.vopt{min-height:2.75rem;font-size:.875rem}
.field label,.ti-card .sub,.field-err,.service-hint,.form-error{font-size:.875rem;line-height:1.6}
.field-err,.form-error{font-weight:600}
.field input,.field select,.field textarea{font-size:1rem;min-height:3rem}
.form-field label,.vlabel,.vlabel .vval,.cond-desc,.cond-note{font-size:.875rem;line-height:1.6}
.form-field input,.form-field select,.form-field textarea{font-size:1rem;min-height:3rem}
.form-field input:focus-visible,.form-field select:focus-visible,.form-field textarea:focus-visible{outline:2px solid var(--accent);outline-offset:3px}
.modal .dialog{max-height:calc(100dvh - 2.5rem);overflow-y:auto}
.modal .dialog h3{padding-right:2.5rem}
.modal .close{width:2.75rem;height:2.75rem}
.cond-btn .cb-label{font-size:.875rem;line-height:1.4}
.cond-btn.active .cb-label{color:white}
.ti-choice,.ti-yn button{min-height:2.75rem}
.ti-card,.service-page .service-form{border-radius:var(--r-lg);box-shadow:0 8px 32px #192d4305}
.service-page .service-fields label{font-size:.9375rem}
.service-page .service-fields input,.service-page .service-fields select,.service-page .service-fields textarea{background:white;min-height:3.25rem}
.service-page .service-consent{font-size:.875rem;line-height:1.65}
.service-consent input,input[type=checkbox]{accent-color:var(--accent)}
.service-form-actions{gap:.75rem;padding-top:1.5rem;margin-top:1.5rem}
.service-price-note,.service-draft-note,.service-hint{max-width:65ch}
.faq-item summary{min-height:3.5rem;font-size:1rem;line-height:1.5;padding:1.125rem 1.25rem;gap:1rem}
.faq-item .ans{font-size:1rem;line-height:1.7}
.footer-top a{display:inline-flex;align-items:center;min-height:2.75rem;font-size:.875rem;color:#c7d0df}
.footer-top ul{gap:.25rem}
.footer-brand p{font-size:.875rem;line-height:1.75;color:#c7d0df}
.footer-bottom{color:#b0bed2;font-size:.8125rem}
.admin-secure{max-width:64rem}
.admin-secure input{min-height:3rem;font-size:1rem}
.admin-table{font-size:.875rem}
.admin-table th,.admin-side .grp{font-size:.75rem}
.ti-promo-mark{background:#f8edf0}
.home-simple .home-service-card::before{background:radial-gradient(190px circle at var(--spot-x,50%) var(--spot-y,50%),#8e203618,transparent 75%)}
@media(hover:hover) and (pointer:fine){.home-simple .home-service-card:hover{box-shadow:0 4px 16px #8e203614}}

/* Shared responsive navigation and catalog controls. */
/* The em threshold follows the container's actual text size, including zoomed text. */
@container site-header (max-width:75em){.main-nav{display:none}.menu-toggle{display:grid}}
@container site-header (max-width:48em){.header-search{display:none}}
/* Safe compact navigation for browsers without size-container support. */
@media(max-width:1200px){.main-nav{display:none}.menu-toggle{display:grid}}
.mobile-menu .backdrop{background:#19233266;backdrop-filter:blur(4px)}
.mobile-menu .panel{top:8px;right:8px;height:calc(100% - 16px);height:calc(100dvh - 16px);width:min(380px,calc(100% - 24px));padding:20px;padding-top:max(20px,env(safe-area-inset-top));padding-bottom:max(20px,env(safe-area-inset-bottom));border:1px solid var(--border);border-radius:24px;background:linear-gradient(160deg,#fff 65%,var(--accent-soft));gap:16px;overflow-y:auto;overscroll-behavior:contain;transform:translateX(calc(100% + 16px))}
.mobile-menu .panel>*{flex-shrink:0}
.mobile-menu .mm-head{margin:0;min-height:44px}
.mm-title{font-size:1.25rem;font-weight:750;letter-spacing:-.02em}
.mobile-menu .mm-close{width:44px;height:44px;border-radius:50%;background:var(--surface-2)}
.mobile-menu .mm-search{margin:0}
.mobile-menu .mm-search input{height:48px;border-radius:16px}
.mm-nav{display:grid;gap:4px}
.mobile-menu .mm-link{display:flex;align-items:center;min-height:44px;padding:10px 14px;border-radius:16px;line-height:1.5;font-size:1rem}
.mm-contact{display:flex;flex-direction:column;align-items:flex-start;border-top:1px solid var(--border);padding:12px 4px 0;gap:2px}
.mm-contact-label{font-size:.8125rem;color:var(--muted)}
.mm-contact a{display:inline-flex;align-items:center;min-height:44px;gap:8px;color:var(--accent);border-radius:8px}
.mm-phone{font-size:1.0625rem;font-weight:700}
.mm-social{font-size:.9375rem}
.balance-kicker{font-size:.75rem;letter-spacing:.11em;line-height:1.5;margin-bottom:1rem}
.balance-search{min-height:3.25rem}

@media(max-width:900px){
  .header-inner{flex-wrap:wrap}
  .site-header .cart-btn{flex-shrink:0}
  .main-nav{display:none}
  .menu-toggle{display:grid}
  .product-card .body{padding:1rem}
}
@media(max-width:760px){.cart-btn{margin-left:auto}}
@media(max-width:600px){
  .container{width:calc(100% - 2rem);padding-inline:0}
  .site-header .container{padding-inline:0}
  .header-inner{min-height:4rem;gap:.75rem}
  .product-card .body{padding:.875rem}
  .product-card .name{font-size:.875rem;line-height:1.5}
  .product-card .btn{font-size:.875rem;padding:.75rem .5rem}
  .service-page.service-simple .service-form{padding:18px 14px;border-radius:16px}
  .service-simple .service-progress li{min-width:0;flex-direction:column;align-items:flex-start;overflow-wrap:anywhere}
  .service-simple .service-device-grid{grid-template-columns:repeat(auto-fit,minmax(min(100%,5.5rem),1fr))}
  .service-simple .service-picture-card strong{overflow-wrap:anywhere}
  .cond-switch{grid-template-columns:repeat(2,minmax(0,1fr))}
  .cond-btn{min-height:3.5rem;flex-direction:row;justify-content:center;gap:.625rem;padding:.75rem}
  .cond-btn:last-child{grid-column:1/-1}
  .ti-choice-grid{grid-template-columns:repeat(2,minmax(0,1fr))}
  .faq-item summary{padding:1rem;font-size:.9375rem}
  .footer-top{gap:2rem}
}
@media(max-width:360px){
  .header-inner{gap:.375rem}
  .site-header .brand-lockup{gap:.4375rem}
  .site-header .logo-mark{width:2.25rem;height:2.25rem;border-radius:.625rem}
  .site-header .brand-primary{font-size:1.25rem}
  .menu-toggle{width:2.75rem}
  .cart-btn{padding-inline:.625rem}
}
@media(prefers-reduced-motion:reduce){
  html{scroll-behavior:auto}
  *,*:before,*:after{scroll-behavior:auto!important;animation-duration:.01ms!important;animation-iteration-count:1!important;transition-duration:.01ms!important}
}

/* Rounded brand surface; leave overflow visible for keyboard focus rings. */
.qty{overflow:visible}
.qty button{width:44px;height:44px;min-width:44px;min-height:44px;border-radius:8px}
.ci-remove{min-height:44px}
.photo-cell .rm{width:44px;height:44px;font-size:18px}
.photo-cell .rm:focus-visible{outline:3px solid #fff;outline-offset:-4px}
.ti-page:has(#request-lookup)>h1{margin-bottom:12px}
@media(max-width:700px){.catalog-categories .catalog-category-art{height:72px}.catalog-categories .catalog-category-icon:not([hidden]){width:60px;height:60px}.catalog-categories .catalog-category-icon svg{width:36px;height:36px}}
.site-footer{margin-top:16px;background:linear-gradient(120deg,#42232e 0%,#241e2b 55%,#192332 100%);border-radius:clamp(24px,4vw,48px) clamp(24px,4vw,48px) 0 0;border-top:1px solid #70434f;box-shadow:0 -8px 32px #19233208}
body:has(.home-simple) .site-footer{margin-top:24px}
.site-footer :focus-visible{outline:3px solid #ffd5df;outline-offset:4px}
.site-footer .footer-bottom{border-top-color:#68515e}
.footer-brand{min-width:0}
.footer-contacts{display:flex;flex-wrap:wrap;gap:8px;margin-top:16px;max-width:400px}
.footer-top .footer-contact{display:flex;justify-content:center;gap:8px;min-height:48px;padding:10px 12px;border:1px solid #68515e;border-radius:14px;color:#fff;background:#ffffff08;text-decoration:none;line-height:1.4}
.footer-contact-phone{flex:1 1 170px}
.footer-contact-instagram{flex:1 1 112px}
.footer-contact svg{width:20px;height:20px;flex-shrink:0;color:#ffd5df}
.footer-contact span{overflow-wrap:anywhere}
.footer-top .footer-contact:hover{background:#ffffff14;border-color:#b0bed2}
/* Accessible footer disclosures. */
.footer-top{align-items:start;padding-block:32px;gap:24px}
.footer-group{min-width:0}
.footer-group summary{display:flex;align-items:center;justify-content:space-between;gap:12px;list-style:none;color:white;font-size:.875rem;text-transform:uppercase;letter-spacing:.08em;font-weight:700;cursor:pointer;min-height:44px;line-height:1.5;padding-block:10px;margin-bottom:6px}
.footer-group summary::-webkit-details-marker{display:none}
.footer-group summary::after{content:'';width:8px;height:8px;border-right:1.5px solid #b0bed2;border-bottom:1.5px solid #b0bed2;transform:rotate(45deg);flex-shrink:0;margin-right:4px}
.footer-group[open] summary::after{transform:rotate(225deg)}
/* Keep the short brand row out of the link grid on tablet widths. */
@media(min-width:601px) and (max-width:1024px){
  .footer-top{grid-template-columns:repeat(3,minmax(0,1fr));row-gap:16px}
  .footer-brand{grid-column:1/-1}
  .site-footer .footer-brand{display:flex;align-items:center;justify-content:space-between;gap:24px}
  .footer-contacts{margin-top:0;flex:1;max-width:400px}
}
@media(max-width:600px){
  .footer-top{grid-template-columns:1fr;padding-block:24px;gap:0}
  .site-footer .footer-top{padding-bottom:0}
  .footer-brand{margin-bottom:20px}
  .footer-brand p{margin-top:8px;max-width:38ch}
  .footer-group{border-top:1px solid #68515e}
  .footer-group summary{min-height:52px;padding:16px 0;margin:0;text-transform:none;letter-spacing:0}
  .footer-group ul{padding-bottom:12px}
  .footer-bottom{padding-block:16px}
}
/* Let real content wrap instead of widening the viewport or hiding it. */
.active-filters{min-width:0;max-width:100%}
.chip{max-width:100%;white-space:normal;overflow-wrap:anywhere}
.active-filters .chip{border-radius:12px;text-align:left}
@media(max-width:700px){.catalog-top>.active-filters:not(:empty){flex:1 0 100%}}
.pd-meta .sku,.ci-name,.ci-sku{min-width:0;max-width:100%;overflow-wrap:anywhere}
.cart-item.cart-item-unavailable{grid-template-columns:minmax(0,1fr);gap:12px}
.cart-item-unavailable .btn{justify-self:start;max-width:100%;white-space:normal}
@media(max-width:600px){.cart-item-unavailable .btn{width:100%}}
