.product-page {
    width: 100%;
}

.product-breadcrumbs-section,
.product-main-section,
.product-description-section,
.product-materials-section {
    width: 100%;
    display: flex;
    justify-content: center;
}

.product-breadcrumbs-section {
    padding: 16px 0;
    border-bottom: 1px solid #e2e2ec;
    background: #fff;
}

.product-breadcrumbs-container,
.product-main-container,
.product-description-container,
.product-materials-container {
    width: 100%;
    max-width: var(--content-max-width);
    box-sizing: border-box;
}

.product-back-link {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-family: var(--font-family);
    font-size: 14px;
    font-weight: 500;
    line-height: 20px;
    color: #717188;
}

.product-back-link-icon {
    width: 16px;
    height: 16px;
    position: relative;
}

.product-back-link-icon::before {
    content: "";
    position: absolute;
    top: 5px;
    left: 4px;
    width: 7px;
    height: 7px;
    border-left: 1.5px solid #717188;
    border-bottom: 1.5px solid #717188;
    transform: rotate(45deg);
}

.product-main-section {
    padding: 48px 0;
    border-bottom: 1px solid #e2e2ec;
    background: #fff;
}

.product-main-container {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
    gap: 40px;
    align-items: start;
}

.product-gallery-main {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    min-height: 280px;
    max-height: 444px;
    aspect-ratio: 592 / 444;
    border: none;
    padding: 0;
    border-radius: 14px;
    background: #eaeaf2;
    overflow: hidden;
    cursor: zoom-in;
    text-decoration: none;
    box-sizing: border-box;
    font: inherit;
    color: inherit;
}

.product-gallery-main img {
    display: block;
    max-width: 100%;
    max-height: 100%;
    width: auto;
    height: auto;
    object-fit: contain;
}

.product-gallery-fancybox-sources {
    display: none;
}

.product-gallery-thumbs {
    margin-top: 12px;
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 12px;
    min-width: 0;
}

.product-gallery-thumbs img {
    height: 106px;
    cursor: pointer;
    border: 1px solid transparent;
    transition: border-color 0.2s ease, opacity 0.2s ease;
    width: 100%;
    object-fit: cover;
    border-radius: 10px;
}

.product-gallery-thumbs img:hover {
    opacity: 0.9;
}

.product-gallery-thumbs img.is-active {
    border-color: #252691;
}

.product-meta-row {
    display: flex;
    align-items: center;
    gap: 8px;
}

.product-sku {
    font-family: var(--font-family);
    font-size: 12px;
    font-weight: 600;
    line-height: 16px;
    letter-spacing: 0.6px;
    text-transform: uppercase;
    color: #717188;
}

.product-separator {
    width: 4px;
    height: 4px;
    border-radius: 50%;
    background: #e2e2ec;
}

.product-stock {
    display: inline-flex;
    align-items: center;
    padding: 2px 8px;
    border-radius: 99px;
    background: #f0fdf4;
    font-family: var(--font-family);
    font-size: 12px;
    font-weight: 600;
    line-height: 16px;
    color: #00a63e;
}

.product-info h1 {
    margin: 8px 0 0;
    font-family: var(--second-family);
    font-size: 36px;
    font-weight: 700;
    line-height: 45px;
    color: #151525;
    overflow-wrap: anywhere;
}

.product-specs {
    margin-top: 24px;
}

.product-configuration {
    margin-top: 20px;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.product-configuration-label {
    font-family: var(--font-family);
    font-size: 14px;
    font-weight: 600;
    line-height: 20px;
    color: #151525;
}

.product-configuration-select {
    width: 100%;
    max-width: 100%;
    min-height: 48px;
    padding: 0 16px;
    border: 1px solid #e2e2ec;
    border-radius: 12px;
    background: #fff;
    font-family: var(--font-family);
    font-size: 14px;
    font-weight: 500;
    line-height: 20px;
    color: #151525;
    outline: none;
}

.product-configuration-select:focus {
    border-color: #252691;
}

.product-configuration-description {
    display: flex;
    flex-direction: column;
    gap: 0;
}

.product-configuration-option {
    display: none;
    margin: 0;
    font-family: var(--font-family);
    font-size: 14px;
    font-weight: 400;
    line-height: 22px;
    color: #717188;
}

.product-configuration-option.is-active {
    display: block;
}

.product-specs h2 {
    margin: 0 0 8px;
    font-family: var(--second-family);
    font-size: 13px;
    font-weight: 600;
    line-height: 16px;
    letter-spacing: 0.6px;
    text-transform: uppercase;
    color: #717188;
}

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

.product-specs li {
    display: flex;
    justify-content: space-between;
    gap: 16px;
    border-bottom: 1px solid #e2e2ec;
    padding: 10px 0;
}

.product-specs li span {
    font-family: var(--font-family);
    font-size: 14px;
    font-weight: 400;
    line-height: 20px;
    color: #717188;
}

.product-specs li strong {
    font-family: var(--font-family);
    font-size: 14px;
    font-weight: 600;
    line-height: 20px;
    color: #151525;
    text-align: right;
    overflow-wrap: anywhere;
}

.product-actions {
    margin-top: 16px;
    display: flex;
    flex-wrap: wrap;
    align-items: stretch;
    gap: 12px;
}

.product-btn {
    flex: 1 1 220px;
    min-width: 0;
    min-height: 50px;
    padding: 10px 18px;
    border-radius: 99px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    font-family: var(--font-family);
    font-size: 14px;
    font-weight: 600;
    line-height: 20px;
    text-align: center;
    white-space: normal;
    box-sizing: border-box;
}

.product-btn span {
    min-width: 0;
    overflow-wrap: anywhere;
}

.product-btn-primary {
    background: #ff191e;
    color: #fff;
}

.product-btn-secondary {
    background: #f6f6fa;
    border: 1px solid #e2e2ec;
    color: #151525;
}

.product-download-icon {
    width: 16px;
    height: 16px;
    flex-shrink: 0;
    display: block;
}

.product-description-section {
    padding: 48px 0;
    background: #f6f6fa;
    border-top: 1px solid #e2e2ec;
}

.product-description-container h2 {
    margin: 0 0 16px;
    font-family: var(--second-family);
    font-size: 24px;
    font-weight: 700;
    line-height: 32px;
    color: #151525;
}

.product-description-container p {
    margin: 0;
    font-family: var(--font-family);
    font-size: 16px;
    font-weight: 400;
    line-height: 26px;
    color: #717188;
}

.product-description-container p+p {
    padding-top: 8px;
}

.product-description-content {
    margin-top: 24px;
    font-family: var(--font-family);
    font-size: 16px;
    font-weight: 400;
    line-height: 26px;
    color: #717188;
}

.product-description-content>*:first-child {
    margin-top: 0;
}

.product-description-content p {
    margin: 0 0 12px;
}

.product-description-content p:last-child {
    margin-bottom: 0;
}

.product-description-content h1,
.product-description-content h2,
.product-description-content h3,
.product-description-content h4,
.product-description-content h5,
.product-description-content h6 {
    margin: 20px 0 12px;
    font-family: var(--second-family);
    font-weight: 700;
    color: #151525;
}

.product-description-content h2 {
    font-size: 20px;
    line-height: 28px;
}

.product-description-content h3 {
    font-size: 18px;
    line-height: 24px;
}

.product-description-content ul,
.product-description-content ol {
    margin: 0 0 12px;
    padding-left: 20px;
}

.product-description-content li {
    margin: 6px 0;
}

.product-description-content a {
    color: #252691;
    font-weight: 600;
}

.product-description-content img {
    max-width: 100%;
    height: auto;
    border-radius: 10px;
}

.product-materials-section {
    padding: 48px 0;
    background: #fff;
    border-top: 1px solid #e2e2ec;
}

.product-materials-container h2 {
    margin: 0 0 20px;
    font-family: var(--second-family);
    font-size: 24px;
    font-weight: 700;
    line-height: 32px;
    color: #151525;
}

.product-materials-list {
    margin: 0;
    padding: 0;
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.product-materials-item {
    margin: 0;
}

.product-materials-link {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    min-height: 50px;
    padding: 12px 20px;
    border: 1px solid #e2e2ec;
    border-radius: 99px;
    background: #f6f6fa;
    font-family: var(--font-family);
    font-size: 14px;
    font-weight: 600;
    line-height: 20px;
    color: #151525;
    text-decoration: none;
    transition: border-color 0.2s ease, background-color 0.2s ease;
}

.product-materials-link:hover {
    border-color: #c8c8d8;
    background: #ececf2;
}

.product-modal-open {
    overflow: hidden;
}

html.header-price-modal-open {
    overflow: hidden;
}

.product-request-modal {
    position: fixed;
    inset: 0;
    z-index: 1200;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    transition:
        opacity 0.22s ease,
        visibility 0.22s ease;
}

.product-request-modal.is-open {
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
}

.product-request-modal-backdrop {
    position: absolute;
    inset: 0;
    background: rgba(21, 21, 37, 0.58);
}

.product-request-modal-dialog {
    position: relative;
    width: min(920px, 100%);
    max-height: calc(100vh - 40px);
    max-height: calc(100dvh - 40px);
    background: #fff;
    border-radius: 18px;
    border: 1px solid #e2e2ec;
    overflow: hidden;
    display: grid;
    grid-template-columns: minmax(0, 0.95fr) minmax(0, 1.05fr);
    grid-template-rows: minmax(0, 1fr);
    z-index: 1;
    box-shadow: 0 16px 50px rgba(14, 22, 45, 0.2);
}

.product-request-modal-dialog--form-only {
    grid-template-columns: 1fr;
    max-width: min(520px, 100%);
}

.product-request-modal-close {
    position: absolute;
    top: 14px;
    right: 14px;
    width: 36px;
    height: 36px;
    border: 1px solid #e2e2ec;
    border-radius: 50%;
    background: #fff;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    z-index: 2;
}

.product-request-modal-close img {
    width: 16px;
    height: 16px;
}

.product-request-modal-media {
    background: #f6f6fa;
    min-height: 0;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 24px;
    box-sizing: border-box;
}

.product-request-modal-media img {
    width: auto;
    max-width: 100%;
    height: auto;
    max-height: min(480px, 55vh);
    min-height: 0;
    object-fit: contain;
    object-position: center;
    display: block;
}

.product-request-modal-form-wrap {
    padding: 34px 30px 30px;
    min-height: 0;
    display: grid;
    grid-template-rows: minmax(0, 1fr) auto;
    overflow: hidden;
}

.product-request-modal-scroll {
    min-height: 0;
    overflow-y: auto;
    overscroll-behavior: contain;
    -webkit-overflow-scrolling: touch;
    padding-right: 8px;
    margin-right: -8px;
    scrollbar-width: thin;
    scrollbar-color: #c9cbdb transparent;
}

.product-request-modal-scroll::-webkit-scrollbar {
    width: 6px;
}

.product-request-modal-scroll::-webkit-scrollbar-thumb {
    background: #c9cbdb;
    border-radius: 99px;
}

.product-request-modal-form-wrap h2 {
    margin: 0;
    font-family: var(--second-family);
    font-size: 30px;
    font-weight: 700;
    line-height: 1.2;
    color: #151525;
}

.product-request-modal-subtitle {
    margin: 8px 0 0;
    font-family: var(--font-family);
    font-size: 14px;
    font-weight: 500;
    line-height: 1.45;
    color: #717188;
    overflow-wrap: anywhere;
}

.product-request-form {
    margin-top: 16px;
    padding-top: 16px;
    border-top: 1px solid #ececf4;
    background: #fff;
    display: grid;
    gap: 12px;
}

.product-request-specs-view {
    margin-top: 16px;
    padding: 12px;
    border: 1px solid #e2e2ec;
    border-radius: 12px;
    background: #f8f8fc;
}

.product-request-specs-title {
    margin: 0 0 8px;
    font-family: var(--font-family);
    font-size: 12px;
    font-weight: 600;
    line-height: 1.35;
    letter-spacing: 0.5px;
    text-transform: uppercase;
    color: #717188;
}

.product-request-specs-view ul {
    margin: 0;
    padding: 0;
    list-style: none;
    display: grid;
    gap: 8px;
}

.product-request-specs-view li {
    display: flex;
    justify-content: space-between;
    gap: 12px;
    padding-bottom: 8px;
    border-bottom: 1px dashed #dfe2ef;
}

.product-request-specs-view li:last-child {
    padding-bottom: 0;
    border-bottom: 0;
}

.product-request-specs-view li span,
.product-request-specs-view li strong {
    font-family: var(--font-family);
    font-size: 13px;
    line-height: 1.4;
    overflow-wrap: anywhere;
}

.product-request-specs-view li span {
    color: #717188;
}

.product-request-specs-view li strong {
    color: #151525;
    font-weight: 600;
    text-align: right;
}

.product-request-field {
    display: grid;
    gap: 6px;
}

.product-request-field span {
    font-family: var(--font-family);
    font-size: 13px;
    font-weight: 600;
    line-height: 1.35;
    color: #151525;
}

.product-request-field input,
.product-request-field textarea {
    width: 100%;
    border: 1px solid #d9dbe8;
    border-radius: 10px;
    padding: 12px 14px;
    box-sizing: border-box;
    font-family: var(--font-family);
    font-size: 14px;
    font-weight: 400;
    line-height: 1.45;
    color: #151525;
    background: #fff;
}

.product-request-field input:focus,
.product-request-field textarea:focus {
    outline: none;
    border-color: #252691;
    box-shadow: 0 0 0 3px rgba(37, 38, 145, 0.12);
}

.product-request-submit {
    margin-top: 4px;
    min-height: 50px;
    border: 0;
    border-radius: 99px;
    background: #ff191e;
    color: #fff;
    font-family: var(--font-family);
    font-size: 14px;
    font-weight: 600;
    line-height: 20px;
    cursor: pointer;
}

@media (max-width: 1200px) {
    .product-main-container {
        gap: 28px;
    }
}

@media (max-width: 1000px) {

    .product-breadcrumbs-container,
    .product-main-container,
    .product-description-container,
    .product-materials-container {
        padding-left: 24px;
        padding-right: 24px;
    }

    .product-main-container {
        gap: 22px;
    }

    .product-gallery-thumbs {
        grid-template-columns: repeat(4, minmax(0, 1fr));
        gap: 10px;
    }

    .product-gallery-thumbs img {
        height: 92px;
    }
}

@media (max-width: 900px) {

    .product-main-section,
    .product-description-section,
    .product-materials-section {
        padding-top: 40px;
        padding-bottom: 40px;
    }

    .product-info h1 {
        font-size: 32px;
        line-height: 1.22;
    }

    .product-request-modal-dialog {
        grid-template-columns: 1fr;
        grid-template-rows: auto minmax(0, 1fr);
        max-height: calc(100vh - 36px);
        max-height: calc(100dvh - 36px);
    }

    .product-request-modal-dialog--form-only {
        grid-template-rows: minmax(0, 1fr);
    }

    .product-request-modal-media img {
        max-height: min(240px, 42vh);
    }
}

@media (max-width: 900px) {

    /* 900-: info block goes to second row (stack) */
    .product-main-container {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 700px) {

    .product-breadcrumbs-container,
    .product-main-container,
    .product-description-container,
    .product-materials-container {
        padding-left: 20px;
        padding-right: 20px;
    }

    .product-request-modal {
        padding: 16px;
    }

    .product-request-modal-form-wrap {
        padding: 24px 20px 20px;
    }
}

@media (max-width: 600px) {
    .product-gallery-thumbs {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .product-gallery-thumbs img {
        height: 84px;
    }

    .product-btn {
        font-size: 13px;
    }

    .product-request-modal-form-wrap h2 {
        font-size: 26px;
    }
}

@media (max-width: 480px) {

    .product-breadcrumbs-container,
    .product-main-container,
    .product-description-container,
    .product-materials-container {
        padding-left: 16px;
        padding-right: 16px;
    }

    .product-info h1 {
        font-size: 28px;
    }

    .product-gallery-thumbs {
        gap: 8px;
    }

    .product-gallery-thumbs img {
        height: 72px;
    }

    .product-actions {
        gap: 8px;
    }

    .product-btn {
        min-height: 46px;
        padding-left: 10px;
        padding-right: 10px;
        font-size: 12px;
    }

    .product-request-modal {
        padding: 10px;
    }

    .product-request-modal-dialog {
        border-radius: 14px;
        max-height: calc(100vh - 20px);
        max-height: calc(100dvh - 20px);
    }

    .product-request-modal-close {
        top: 10px;
        right: 10px;
        width: 32px;
        height: 32px;
    }

    .product-request-modal-form-wrap {
        padding: 20px 14px 14px;
    }

    .product-request-modal-form-wrap h2 {
        font-size: 22px;
    }
}

/* Тар биіктікте форманы бекітсек ол сыймай кетеді — бүкіл блокты скроллға қайтарамыз */
@media (max-height: 620px) {
    .product-request-modal-form-wrap {
        display: block;
        overflow-y: auto;
        overscroll-behavior: contain;
        -webkit-overflow-scrolling: touch;
    }

    .product-request-modal-scroll {
        overflow: visible;
        padding-right: 0;
        margin-right: 0;
    }
}