/* ============================================================
   Russian Auto Parts page (parts.html / parts.ru.html)
   Loads after design.css — reuses its tokens, .container, .btn,
   .faq-*, .mobile-menu, .cookies, .popup-overlay, .footer base.
   ============================================================ */

/* ---------------- Header ---------------- */

.header.pheader { padding-top: 20px; padding-bottom: 20px; }
.header.pheader .logo img { width: 150px; height: auto; display: block; }

.header.pheader .pnav { display: flex; gap: 32px; font-size: 16px; letter-spacing: -0.01em; }
.header.pheader .pnav a { color: var(--text); transition: color .2s; }
.header.pheader .pnav a:hover { color: var(--primary); }
.header.pheader .pnav a.active { color: var(--primary); }

/* Mobile menu group labels */
.pmenu-group-label {
    font-family: var(--font-body);
    font-size: 13px;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: var(--text-3);
    margin-bottom: -16px;
}
.header.pheader .pnav .nav-drop-toggle { color: var(--text); font-size: 16px; letter-spacing: -0.01em; }
.header.pheader .pnav .nav-drop-toggle:hover { color: var(--primary); }
.header.pheader .pnav .nav-drop-panel a { display: block; }

/* ---------------- Hero ---------------- */

.phero {
    display: grid;
    grid-template-columns: 1fr 540px;
    gap: 80px;
    align-items: start;
    padding-top: 36px;
    padding-bottom: 90px;
}
.phero h1 {
    font-size: 56px;
    line-height: 1.16;
    letter-spacing: -0.02em;
    color: var(--text);
    margin-bottom: 28px;
}
.phero .hero-sub {
    font-size: 18px;
    line-height: 1.5;
    letter-spacing: -0.01em;
    color: var(--text-2);
    max-width: 560px;
    margin-bottom: 56px;
}
.pbadges-label {
    font-size: 14px;
    letter-spacing: -0.01em;
    color: var(--text-3);
    margin-bottom: 16px;
}
.pbadges {
    display: flex;
    flex-wrap: wrap;
    gap: 16px;
    max-width: 620px;
}
.pbadge {
    background: var(--bg-gray);
    /* Figma: rounded rectangle (10px), not a pill */
    border-radius: 10px;
    padding: 12px 24px;
    font-size: 15px;
    letter-spacing: -0.01em;
    color: var(--text);
}

/* Hero request card */

.pcard {
    background: var(--bg-gray);
    border-radius: 24px;
    padding: 36px 40px 32px;
}
.pcard-title {
    font-family: var(--font-head);
    font-size: 24px;
    letter-spacing: -0.01em;
    color: var(--text);
    margin-bottom: 14px;
}
.pcard-sub { font-size: 15px; color: var(--text-2); margin-bottom: 24px; }
.pcard-row {
    display: flex;
    align-items: center;
    gap: 14px;
    background: #fff;
    border-radius: 12px;
    padding: 14px 18px;
    margin-bottom: 14px;
    font-size: 16px;
    color: var(--text);
}
.pcard-num {
    flex-shrink: 0;
    width: 28px;
    height: 28px;
    border-radius: 50%;
    background: var(--light);
    color: var(--primary);
    font-size: 12px;
    font-weight: 500;
    display: flex;
    align-items: center;
    justify-content: center;
}
.pcard-divider { height: 1px; background: #e3e3e3; margin: 26px 0 24px; }
.pcard-contact-label { font-size: 15px; color: var(--text-2); margin-bottom: 18px; }
.pcard-btns { display: flex; gap: 16px; }
.pcard-btns .btn { flex: 1; }
/* glyph-only icons, sized with the button text (design-system 24px) */
.pcard-btns .btn img, .pcard-btns .btn svg { width: 24px; height: 24px; }
.pcard-note {
    margin-top: 24px;
    font-size: 14px;
    line-height: 1.45;
    color: var(--text-3);
}
.pcard-note a { color: var(--primary); text-decoration: underline; }

/* ---------------- Photo strip ---------------- */

.pphoto { line-height: 0; }
.pphoto img { width: 100%; height: auto; display: block; object-fit: cover; }

/* ---------------- Catalogue ---------------- */

.pcatalogue { padding: 90px 0 100px; }
.pcatalogue .section-title { font-size: 44px; margin-bottom: 20px; }
.pcatalogue-sub {
    font-size: 16px;
    color: var(--text-2);
    margin-bottom: 48px;
}
.pcat-panel {
    background: var(--bg-gray);
    border-radius: 24px;
    padding: 40px;
}
.pcat-cols {
    display: grid;
    grid-template-columns: 320px 1fr;
    gap: 40px;
}
.pcat-col-title {
    font-family: var(--font-head);
    font-size: 20px;
    color: var(--text);
    margin-bottom: 28px;
}
.pcat-label {
    display: block;
    font-size: 14px;
    color: var(--text-2);
    margin-bottom: 10px;
}
.psearch {
    position: relative;
    margin-bottom: 20px;
}
.psearch svg {
    position: absolute;
    left: 14px;
    top: 50%;
    transform: translateY(-50%);
    width: 18px;
    height: 18px;
    color: #9aa0a6;
    pointer-events: none;
}
.pinput {
    width: 100%;
    height: 48px;
    background: #fff;
    border: 1px solid #e3e3e3;
    border-radius: 10px;
    padding: 0 16px 0 42px;
    font-family: var(--font-body);
    font-size: 15px;
    color: var(--text);
    outline: none;
    transition: border-color .2s;
}
.pinput::placeholder { color: #9aa0a6; }
.pinput:focus { border-color: var(--primary); }
.plist {
    height: 328px;
    overflow-y: auto;
    display: flex;
    flex-direction: column;
    gap: 14px;
    padding-right: 10px;
    scrollbar-width: thin;
    scrollbar-color: #c9cdd2 transparent;
}
.plist::-webkit-scrollbar { width: 6px; }
.plist::-webkit-scrollbar-thumb { background: #c9cdd2; border-radius: 3px; }
.poption {
    display: flex;
    align-items: center;
    gap: 12px;
    background: #fff;
    border: 1px solid #e3e3e3;
    border-radius: 10px;
    padding: 14px 16px;
    font-size: 16px;
    color: var(--text);
    cursor: pointer;
    text-align: left;
    width: 100%;
    transition: border-color .15s, background .15s;
}
.poption:hover { border-color: var(--primary); }
.poption input { display: none; }
.poption .pradio {
    flex-shrink: 0;
    width: 20px;
    height: 20px;
    border-radius: 50%;
    border: 1.5px solid #c9cdd2;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: border-color .15s;
}
.poption .pradio::after {
    content: '';
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: var(--primary);
    transform: scale(0);
    transition: transform .15s;
}
.poption.selected {
    border-color: var(--primary);
    background: var(--light);
    color: var(--primary);
}
.poption.selected .pradio { border-color: var(--primary); }
.poption.selected .pradio::after { transform: scale(1); }
.pcat-empty { font-size: 14px; color: var(--text-3); padding: 8px 2px; }
.pcat-counter {
    margin-top: 20px;
    font-size: 14px;
    color: var(--text);
}
.pcat-counter span {
    display: block;
    margin-top: 4px;
    font-size: 13px;
    color: var(--text-3);
}
.pcat-footer {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 24px;
    margin-top: 36px;
    padding-top: 32px;
    border-top: 1px solid #e3e3e3;
}
.pcat-selected-label {
    font-size: 14px;
    color: var(--text-3);
    margin-bottom: 8px;
}
.pcat-selected-value {
    font-family: var(--font-head);
    font-size: 20px;
    color: var(--text);
}
.pcat-actions {
    display: flex;
    align-items: center;
    gap: 32px;
}
.plink {
    color: var(--primary);
    font-size: 15px;
    text-decoration: underline;
    background: none;
    border: 0;
    cursor: pointer;
    font-family: var(--font-body);
}

/* ---------------- FAQ ---------------- */

.pfaq {
    background: var(--bg-gray);
    padding: 90px 0 100px;
}
.pfaq .section-title { text-align: center; margin-bottom: 56px; }
.pfaq .faq-list { display: flex; flex-direction: column; gap: 20px; }

/* ---------------- Request form ---------------- */

.pform { padding: 100px 0 110px; }
.pform-card {
    background: var(--bg-gray);
    border-radius: 24px;
    padding: 48px;
}
.pform-card .pform-title {
    font-family: var(--font-head);
    font-size: 40px;
    letter-spacing: -0.02em;
    color: var(--text);
    margin-bottom: 16px;
}
.pform-sub { font-size: 15px; color: var(--text-3); opacity: .8; margin-bottom: 36px; }
.pfield-label {
    display: block;
    font-size: 15px;
    color: var(--text);
    margin-bottom: 10px;
}
.pfield-label .req { color: var(--primary); }
/* block, otherwise the margin-bottom is dropped on an inline span and the
   hint sits right on the textarea border */
.pfield-hint { display: block; font-size: 13px; color: var(--text-3); margin-bottom: 10px; }
.ptextarea,
.pfield input[type="text"],
.pfield input[type="email"] {
    width: 100%;
    background: #fff;
    border: 1px solid #e3e3e3;
    border-radius: 10px;
    padding: 14px 16px;
    font-family: var(--font-body);
    font-size: 15px;
    color: var(--text);
    outline: none;
    transition: border-color .2s;
}
.ptextarea { min-height: 140px; resize: vertical; }
.ptextarea::placeholder,
.pfield input::placeholder { color: #9aa0a6; }
.pfield input { text-overflow: ellipsis; }
.ptextarea:focus,
.pfield input:focus { border-color: var(--primary); }
.pfield { margin-bottom: 24px; }
.pform-vehicle { margin-bottom: 40px; }
.pform-vehicle .ptextarea,
.pform-vehicle input[type="text"] { min-height: 52px; }

.pform-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 24px 64px;
}
.pform-col-title {
    font-family: var(--font-head);
    font-size: 24px;
    color: var(--text);
    margin-bottom: 24px;
}
.pform-col-title .req { color: var(--primary); }
.pupload-row {
    display: grid;
    grid-template-columns: 160px 1fr;
    gap: 24px;
    align-items: end;
}
.pqty input {
    width: 100%;
    height: 52px;
}
.pupload {
    border: 1.5px dashed #b9c6d8;
    border-radius: 12px;
    background: transparent;
    padding: 20px 16px;
    text-align: center;
    cursor: pointer;
    transition: border-color .2s, background .2s;
}
.pupload:hover, .pupload.dragover { border-color: var(--primary); background: var(--light); }
.pupload svg { width: 28px; height: 28px; color: var(--primary); }
.pupload-text { font-size: 14px; color: var(--text-2); margin-top: 8px; }
.pupload-text button {
    color: var(--primary);
    text-decoration: underline;
    background: none;
    border: 0;
    cursor: pointer;
    font-size: 14px;
    font-family: var(--font-body);
}
.pupload-hint { font-size: 12px; color: var(--text-3); margin-top: 6px; }
.pfile {
    display: flex;
    align-items: center;
    gap: 12px;
    background: #fff;
    border: 1px solid #e3e3e3;
    border-radius: 12px;
    padding: 14px 16px;
    margin-top: 12px;
    text-align: left;
}
.pfile svg { flex-shrink: 0; width: 22px; height: 22px; color: var(--primary); }
.pfile-name { font-size: 14px; color: var(--text); word-break: break-all; }
.pfile-meta { font-size: 12px; color: var(--text-3); margin-top: 2px; }
.pfile-remove {
    margin-left: auto;
    flex-shrink: 0;
    width: 28px;
    height: 28px;
    border: 0;
    background: none;
    color: var(--text-3);
    cursor: pointer;
    font-size: 18px;
    line-height: 1;
}

/* Sub-heading inside the brand list (KrAZ / MAZ — "СССР и страны СНГ:") */
.pgroup-label {
    font-size: 13px;
    line-height: 1.2;
    letter-spacing: -0.01em;
    color: var(--text-3);
    padding: 6px 4px 2px;
    margin-top: 4px;
}

/* Country custom dropdown */

.pdrop { position: relative; }
.pdrop-toggle {
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    background: #fff;
    border: 1px solid #e3e3e3;
    border-radius: 10px;
    padding: 14px 16px;
    font-family: var(--font-body);
    font-size: 15px;
    color: var(--text);
    cursor: pointer;
    text-align: left;
}
.pdrop-toggle .placeholder { color: #9aa0a6; }
.pdrop-toggle svg { flex-shrink: 0; width: 18px; height: 18px; color: var(--text-2); transition: transform .2s; }
.pdrop.open .pdrop-toggle svg { transform: rotate(180deg); }
.pdrop.open .pdrop-toggle { border-color: var(--primary); }
.pdrop-panel {
    display: none;
    position: absolute;
    top: calc(100% + 6px);
    left: 0;
    right: 0;
    background: #fff;
    border: 1px solid #e3e3e3;
    border-radius: 10px;
    box-shadow: 0 12px 32px rgba(37, 42, 49, .12);
    padding: 12px;
    z-index: 30;
}
.pdrop.open .pdrop-panel { display: block; }
.pdrop-search { position: relative; margin-bottom: 8px; }
.pdrop-search svg {
    position: absolute;
    left: 12px;
    top: 50%;
    transform: translateY(-50%);
    width: 16px;
    height: 16px;
    color: #9aa0a6;
}
/* [type="text"] keeps this above the generic .pfield input padding rule,
   otherwise the placeholder slides under the magnifier icon */
.pdrop-search input,
.pdrop-search input[type="text"] {
    width: 100%;
    height: 42px;
    border: 1px solid #e3e3e3;
    border-radius: 8px;
    padding: 0 12px 0 44px;
    font-family: var(--font-body);
    font-size: 14px;
    outline: none;
}
.pdrop-search input:focus { border-color: var(--primary); }
.pdrop-list {
    max-height: 240px;
    overflow-y: auto;
    scrollbar-width: thin;
    scrollbar-color: #c9cdd2 transparent;
}
.pdrop-list::-webkit-scrollbar { width: 6px; }
.pdrop-list::-webkit-scrollbar-thumb { background: #c9cdd2; border-radius: 3px; }
.pdrop-option {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 11px 12px;
    border-radius: 8px;
    font-size: 14px;
    color: var(--text);
    cursor: pointer;
}
.pdrop-option:hover { background: var(--bg-gray); }
.pdrop-option.selected { background: var(--light); color: var(--primary); }
.pdrop-option.selected svg { width: 16px; height: 16px; color: var(--primary); }
.pdrop-empty { padding: 10px 12px; font-size: 13px; color: var(--text-3); }

.pform-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
    margin-top: 32px;
    padding-top: 32px;
    border-top: 1px solid #e3e3e3;
}
.pform-note {
    font-size: 13px;
    line-height: 1.5;
    color: var(--text-3);
    max-width: 560px;
}
.pform-submit { min-width: 320px; }
.pform-error {
    display: none;
    font-size: 13px;
    color: #d92d20;
    margin-top: 8px;
}
.pform-error.visible { display: block; }

/* ---------------- Footer (parts layout on design.css .footer) ---------------- */

.pfooter { background: var(--dark); color: #fff; padding: 90px 0 0; overflow: hidden; }
.pfooter-grid {
    display: flex;
    justify-content: space-between;
    gap: 40px;
    flex-wrap: wrap;
}
.pfooter-phone {
    font-family: var(--font-head);
    font-size: 26px;
    color: #fff;
    display: inline-block;
    margin-bottom: 14px;
}
.pfooter-mail { font-size: 16px; color: #fff; display: inline-block; }
.pfooter .socials { display: flex; gap: 12px; margin-top: 24px; }
.pfooter .socials a {
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: opacity .2s;
}
.pfooter .socials a:hover { opacity: .8; }
/* the SVGs carry their own 40px circle background (white / blue) */
.pfooter .socials img { width: 40px; height: 40px; }
.pfooter-right { text-align: right; }
.pfooter-nav {
    display: flex;
    justify-content: flex-end;
    gap: 32px;
    font-size: 15px;
}
.pfooter-nav a { color: #fff; transition: color .2s; }
.pfooter-nav a:hover { color: var(--primary); }
.pfooter .footer-chat { margin-top: 28px; }
.pfooter-bottom {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 64px;
    font-size: 14px;
    color: rgba(255, 255, 255, .72);
}
.pfooter-bottom a { color: rgba(255, 255, 255, .72); text-decoration: underline; }
.pfooter-wordmark {
    font-family: var(--font-head);
    font-weight: 700;
    color: #fff;
    font-size: min(120px, 8.33vw);
    line-height: 1;
    letter-spacing: -0.02em;
    white-space: nowrap;
    text-align: center;
    padding: 70px 0 0;
    position: relative;
    bottom: -26px;
}

/* RU step texts wrap to a different number of lines than EN, so let the
   cards stretch to a common row height instead of the design-system
   align-items:start, which leaves ragged rows on this page */
.process .process-grid { align-items: stretch; }
/* long step titles force a min-content wider than very narrow phones —
   let the cards shrink and the text wrap instead */
.process .step-card, .process .step-card > div { min-width: 0; }
.process .step-card p { overflow-wrap: break-word; }

/* ---------------- Modals ---------------- */

.pmodal {
    position: relative;
    background: var(--bg-gray);
    border-radius: 24px;
    width: 1240px;
    max-width: 100%;
    max-height: calc(100vh - 40px);
    overflow-y: auto;
    padding: 40px 44px;
}
.pmodal-close {
    position: absolute;
    top: 24px;
    right: 24px;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: #fff;
    border: 0;
    color: var(--text-2);
    font-size: 20px;
    line-height: 1;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: color .2s;
}
.pmodal-close:hover { color: var(--text); }
.pmodal-title {
    font-family: var(--font-head);
    font-size: 34px;
    letter-spacing: -0.02em;
    color: var(--text);
    margin-bottom: 12px;
    padding-right: 48px;
}
.pmodal-sub { font-size: 15px; color: var(--text-2); margin-bottom: 28px; }
.pmodal .pform-vehicle { margin-bottom: 28px; }
.pmodal .pform-grid { gap: 24px 64px; }
.pmodal-footer {
    display: grid;
    grid-template-columns: 1fr auto 1fr;
    align-items: center;
    gap: 24px;
    margin-top: 32px;
    padding-top: 32px;
    border-top: 1px solid #e3e3e3;
}
.pmodal-footer .pform-note { margin: 0 auto; text-align: center; }
.pmodal-footer .pform-submit { justify-self: end; }

/* Success popup */

.psuccess-card {
    position: relative;
    background: #fff;
    border-radius: 20px;
    width: 560px;
    max-width: 100%;
    padding: 56px 48px 48px;
    text-align: center;
}
.psuccess-check {
    width: 56px;
    height: 56px;
    border-radius: 50%;
    background: var(--light);
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 24px;
}
.psuccess-check svg { width: 24px; height: 24px; color: var(--primary); }
.psuccess-title {
    font-family: var(--font-head);
    font-size: 26px;
    letter-spacing: -0.01em;
    color: var(--text);
    margin-bottom: 16px;
}
.psuccess-text {
    font-size: 15px;
    line-height: 1.5;
    color: var(--text-2);
    margin-bottom: 28px;
}

/* Body lock while modal open */
body.pno-scroll { overflow: hidden; }

/* ============================================================
   Responsive
   ============================================================ */

@media (max-width: 1240px) {
    .phero { grid-template-columns: 1fr 44%; gap: 40px; }
    .phero h1 { font-size: 46px; }
    .pcatalogue .section-title { font-size: 38px; }
    .pform-card .pform-title { font-size: 34px; }
    .pmodal { width: 100%; }
}

@media (max-width: 900px) {
    .header.pheader .pnav { display: none; }
    /* the logo + language switch + burger fill the header edge-to-edge at
       phone widths, so tighten the side padding and the action gap */
    .header.pheader { padding-left: 24px; padding-right: 24px; gap: 16px; }
    /* per the 375 layout the header keeps only the round mark */
    .header.pheader .logo img { width: 44px; height: 44px; }
    .header.pheader .header-actions { gap: 16px; }
    .phero { grid-template-columns: 1fr; gap: 40px; padding-top: 24px; padding-bottom: 60px; }
    .phero h1 { font-size: 40px; margin-bottom: 20px; }
    .phero .hero-sub { margin-bottom: 40px; }
    .pcard { padding: 28px 24px; }
    .pcatalogue { padding: 60px 0 70px; }
    .pcatalogue .section-title { font-size: 32px; }
    .pcat-panel { padding: 24px; }
    .pcat-cols { grid-template-columns: 1fr; gap: 32px; }
    .plist { height: 280px; }
    .pcat-footer { flex-direction: column; align-items: flex-start; }
    .pcat-actions { width: 100%; justify-content: space-between; }
    .pfaq { padding: 60px 0 70px; }
    .pform { padding: 70px 0 80px; }
    .pform-card { padding: 28px 24px; }
    .pform-card .pform-title { font-size: 28px; }
    .pform-grid { grid-template-columns: 1fr; gap: 8px; }
    .pupload-row { grid-template-columns: 1fr; gap: 16px; align-items: stretch; }
    .pform-footer { flex-direction: column-reverse; align-items: stretch; }
    .pform-submit { width: 100%; min-width: 0; }
    .pmodal { padding: 28px 20px; border-radius: 20px; }
    .pmodal-title { font-size: 24px; }
    .pmodal-footer { grid-template-columns: 1fr; justify-items: start; gap: 16px; }
    .pmodal-footer .pform-note { margin: 0; text-align: left; }
    .pmodal-footer .pform-submit { justify-self: stretch; }
    .pfooter { padding-top: 70px; }
    .pfooter-right { text-align: left; }
    .pfooter-nav { justify-content: flex-start; flex-wrap: wrap; gap: 16px; font-size: 14px; }
    .pfooter-bottom { margin-top: 40px; }
    .pfooter-wordmark { font-size: 51px; padding: 40px 0 28px; bottom: -10px; }
}

@media (max-width: 480px) {
    .header.pheader { padding-left: 16px; padding-right: 16px; }
    .header.pheader .logo img { width: 40px; height: 40px; }
    .phero h1 { font-size: 30px; }
    .phero .hero-sub { font-size: 16px; }
    .pbadges { gap: 10px; }
    .pbadge { padding: 10px 18px; font-size: 14px; }
    /* in a column flex container flex:1 sets flex-basis:0 on the height axis,
       which flattened the pills to line-height — keep their 52px height */
    .pcard-btns { flex-direction: column; }
    .pcard-btns .btn { flex: none; width: 100%; }
    .pcatalogue .section-title { font-size: 26px; }
    .pcat-panel { padding: 20px 16px; }
    .pcat-actions { flex-direction: column-reverse; align-items: stretch; gap: 16px; }
    .pcat-actions .btn { width: 100%; min-width: 0; }
    .pcat-actions .plink { text-align: center; }
    .pform-card .pform-title { font-size: 24px; }
    .psuccess-card { padding: 40px 24px 32px; }
    .psuccess-title { font-size: 21px; }
    .pfooter-phone { font-size: 21px; }
    .pfooter-wordmark { font-size: 47px; white-space: normal; line-height: 1; }
}

/* Option brand suffix (all-models view) */
/* keep the catalogue columns shrinkable: the model rows carry a nowrap brand
   suffix, whose min-content width otherwise forces a page-wide overflow on
   narrow phones (≤320px) */
.pcat-col, .poption { min-width: 0; }
.poption-label { min-width: 0; overflow-wrap: anywhere; }
.poption-sub { font-size: 12px; color: var(--text-3); margin-left: 8px; white-space: nowrap; }

/* Invalid field highlight */
.perror, .pdrop-toggle.perror { border-color: #e5484d !important; }
