@font-face {
    font-family: "TT Bluescreens";
    src: url("/include/parma_jersey/fonts/TTBluescreens-Bold.ttf") format("truetype");
    font-weight: 700;
    font-style: normal;
    font-display: swap;
}

@font-face {
    font-family: "TT Norms";
    src: url("/include/parma_jersey/fonts/TTNorms-Medium.otf") format("opentype");
    font-weight: 500;
    font-style: normal;
    font-display: swap;
}

.parma-jersey {
    margin: 4px 0 40px;
    padding: 28px 28px 32px;
    border: 1px solid #dadada;
    border-radius: 8px;
    overflow: hidden;
    background-color: #fff;
    background-image: url("/include/parma_jersey/images/bg_xl.png");
    background-repeat: no-repeat;
    background-size: cover;
    background-position: right top;
    font-family: Inter, Arial, sans-serif;
    color: #555;
    box-sizing: border-box;
}

.parma-jersey__head,
.parma-jersey__models-col,
.parma-jersey__form {
    background: rgba(255, 255, 255, 0.7);
    padding: 15px;
    border-radius: 8px;
    box-sizing: border-box;
}

.parma-jersey__head {
    margin-bottom: 28px;
    max-width: max-content;
}

.parma-jersey__grid {
    display: grid;
    grid-template-columns: minmax(220px, 280px) minmax(220px, 1fr) minmax(260px, 340px);
    gap: 28px 36px;
    align-items: center;
}

.parma-jersey__grid > * {
    min-width: 0;
}

.parma-jersey__title {
    margin: 0 0 8px;
    font-family: "Roboto Slab", Arial, sans-serif;
    font-size: 32px;
    font-weight: 500;
    line-height: 1.2;
    color: #222;
}

.parma-jersey__lead {
    margin: 0 0 12px;
    font-size: 18px;
    font-weight: 600;
    line-height: 1.3;
    color: #222;
}

.parma-jersey__term {
    margin: 0 0 16px;
    font-size: 15px;
    font-weight: 600;
    line-height: 1.4;
    color: #222;
}

.parma-jersey__note {
    margin: 0;
    max-width: 760px;
    font-size: 14px;
    line-height: 1.55;
    color: #555;
}

.parma-jersey__note a {
    color: #e31e24;
    text-decoration: none;
}

.parma-jersey__note a:hover {
    text-decoration: underline;
}

.parma-jersey__stage {
    position: relative;
}

.parma-jersey__mock {
    position: relative;
    width: min(100%, 390px);
    margin: 0 auto;
    container-type: inline-size;
}

.parma-jersey__photo {
    display: block;
    width: 100%;
    height: auto;
    background: transparent;
}

.parma-jersey__name {
    position: absolute;
    top: var(--pj-name-top, 15.5%);
    left: 50%;
    width: 92%;
    color: var(--pj-ink, #fff);
    font-family: "TT Bluescreens", "Arial Black", sans-serif;
    font-size: var(--pj-name-size, 12cqw);
    font-weight: 700;
    letter-spacing: 0.02em;
    line-height: 0.95;
    text-align: center;
    text-transform: uppercase;
    white-space: nowrap;
    pointer-events: none;
    transform: translateX(-50%);
    -webkit-text-stroke: var(--pj-name-stroke, 0px) var(--pj-stroke-color, transparent);
    paint-order: stroke fill;
}

.parma-jersey__name.is-ghost,
.parma-jersey__num.is-ghost {
    opacity: 0.55;
}

.parma-jersey__num {
    position: absolute;
    top: var(--pj-num-top, 26%);
    left: 50%;
    display: flex;
    justify-content: center;
    color: var(--pj-ink, #fff);
    font-family: "TT Norms", Arial, sans-serif;
    font-size: var(--pj-num-size, 36cqw);
    font-weight: 500;
    line-height: 0.95;
    letter-spacing: -0.03em;
    pointer-events: none;
    transform: translateX(-50%);
    -webkit-text-stroke: var(--pj-num-stroke, 0px) var(--pj-stroke-color, transparent);
    paint-order: stroke fill;
}

.parma-jersey__num span {
    display: block;
}

.parma-jersey__form {
    margin: 0;
}

.parma-jersey__field {
    margin-bottom: 16px;
}

.parma-jersey__label {
    display: block;
    margin-bottom: 8px;
    color: #222;
    font-size: 13px;
    font-weight: 600;
    line-height: 1.2;
}

.parma-jersey__side {
    position: absolute;
    z-index: 2;
    top: 50%;
    right: max(8px, calc((100% - min(100%, 390px)) / 2 - 56px));
    width: 44px;
    height: 44px;
    margin: -22px 0 0;
    padding: 0;
    border: 0;
    border-radius: 50%;
    background-color: var(--theme-base-color, #e31e24);
    background-image: url("/bitrix/templates/aspro-lite/images/svg/scroll.svg");
    background-repeat: no-repeat;
    background-position: center 14px;
    transform: rotate(90deg);
    cursor: pointer;
    transition: background-color 0.1s ease;
}

.parma-jersey__side:hover {
    background-color: hsl(
        var(--theme-base-color-hue),
        var(--theme-base-color-saturation),
        calc(var(--theme-base-color-lightness) + var(--theme-lightness-hover-diff))
    );
}

.parma-jersey__pair {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
    gap: 12px;
}

.parma-jersey__mock.is-front .parma-jersey__name {
    visibility: hidden;
}

.parma-jersey__mock.is-front .parma-jersey__num {
    top: var(--pj-front-top, 40%);
    font-size: var(--pj-front-size, 18cqw);
    -webkit-text-stroke-width: var(--pj-front-stroke, 0px);
}

.parma-jersey__input {
    display: block;
    width: 100%;
    height: 48px;
    padding: 0 14px;
    border: 1px solid #dadada;
    border-radius: 8px;
    background: #fff;
    color: #222;
    font: 16px/1.2 Inter, Arial, sans-serif;
    box-sizing: border-box;
}

.parma-jersey__input::placeholder {
    color: #9a9a9a;
}

.parma-jersey__input:focus {
    border-color: #e31e24;
    outline: none;
}

.parma-jersey__hint {
    margin: 6px 0 0;
    color: #8a8a8a;
    font-size: 12px;
    line-height: 1.3;
}

.parma-jersey__models {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.parma-jersey__model {
    display: flex;
    align-items: center;
    gap: 10px;
    width: 100%;
    padding: 6px 10px;
    border: 1px solid #e5e5e5;
    border-radius: 8px;
    background: #fff;
    color: #222;
    text-align: left;
    cursor: pointer;
}

.parma-jersey__model img {
    width: 36px;
    height: 56px;
    object-fit: contain;
    background: transparent;
    flex: 0 0 auto;
}

.parma-jersey__model-title,
.parma-jersey__model-color {
    display: block;
    line-height: 1.25;
}

.parma-jersey__model-title {
    font-size: 14px;
    font-weight: 600;
}

.parma-jersey__model-color {
    margin-top: 2px;
    color: #777;
    font-size: 13px;
}

.parma-jersey__model:hover {
    border-color: #222;
}

.parma-jersey__model.is-selected {
    border-color: #e31e24;
    box-shadow: inset 0 0 0 1px #e31e24;
}

.parma-jersey__sizes {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.parma-jersey__size {
    min-width: 44px;
    height: 40px;
    padding: 0 8px;
    border: 1px solid #dadada;
    border-radius: 8px;
    background: #fff;
    color: #222;
    font: 600 14px/1 Inter, Arial, sans-serif;
    cursor: pointer;
}

.parma-jersey__size:hover {
    border-color: #222;
}

.parma-jersey__size.is-selected {
    border-color: #e31e24;
    color: #e31e24;
    box-shadow: inset 0 0 0 1px #e31e24;
}

.parma-jersey__price {
    margin: 4px 0 14px;
    color: #222;
    font-size: 28px;
    font-weight: 600;
    line-height: 1.1;
}

.parma-jersey__error {
    margin: 0 0 10px;
    color: #e31e24;
    font-size: 13px;
    line-height: 1.4;
}

.parma-jersey__submit,
a.parma-jersey-pop__order {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    height: 48px;
    border: 0;
    border-radius: 8px;
    background: #e31e24;
    color: #fff;
    font: 600 15px/1 Inter, Arial, sans-serif;
    text-decoration: none;
    cursor: pointer;
    box-sizing: border-box;
}

a.parma-jersey-pop__order,
a.parma-jersey-pop__order:link,
a.parma-jersey-pop__order:visited,
a.parma-jersey-pop__order:hover,
a.parma-jersey-pop__order:focus,
a.parma-jersey-pop__order:active {
    color: #fff !important;
    -webkit-text-fill-color: #fff;
}

.parma-jersey__submit:hover,
a.parma-jersey-pop__order:hover {
    background: #c81a1f;
    color: #fff !important;
}

.parma-jersey__submit:disabled {
    opacity: 0.65;
    cursor: default;
}

.parma-jersey-pop {
    position: fixed;
    inset: 0;
    z-index: 12000;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 16px;
    background: rgba(34, 34, 34, 0.28);
}

.parma-jersey-pop[hidden] {
    display: none !important;
}

.parma-jersey-pop__card {
    position: relative;
    width: min(420px, 100%);
    padding: 28px 24px 22px;
    border-radius: 12px;
    background: #fff;
    box-shadow: 0 16px 48px rgba(0, 0, 0, 0.16);
    text-align: center;
}

.parma-jersey-pop__close {
    position: absolute;
    top: 8px;
    right: 8px;
    width: 36px;
    height: 36px;
    border: 0;
    background: transparent;
    color: #888;
    font-size: 26px;
    line-height: 1;
    cursor: pointer;
}

.parma-jersey-pop__title {
    margin: 0 0 8px;
    font-family: "Roboto Slab", Arial, sans-serif;
    font-size: 24px;
    font-weight: 500;
    color: #222;
}

.parma-jersey-pop__text {
    margin: 0 0 18px;
    color: #555;
    font-size: 15px;
    line-height: 1.45;
}

.parma-jersey-pop__continue {
    margin-top: 8px;
    border: 0;
    background: transparent;
    color: #222;
    font: 600 14px/1.2 Inter, Arial, sans-serif;
    cursor: pointer;
}

.parma-jersey-pop__continue:hover {
    color: #e31e24;
}

@media (max-width: 1100px) {
    .parma-jersey {
        padding: 22px 18px 24px;
    }

    .parma-jersey__grid {
        grid-template-columns: minmax(0, 1fr);
        gap: 22px;
        align-items: stretch;
    }

    .parma-jersey__note {
        max-width: none;
    }

    .parma-jersey__models {
        flex-direction: row;
        gap: 8px;
        min-width: 0;
        max-width: 100%;
        overflow-x: auto;
        padding-bottom: 4px;
    }

    .parma-jersey__model {
        flex: 0 0 180px;
        width: auto;
    }

    .parma-jersey__mock {
        width: min(100%, 320px);
    }

    .parma-jersey__side {
        right: max(8px, calc((100% - min(100%, 320px)) / 2 - 56px));
    }
}

@media (max-width: 767px) {
    .parma-jersey {
        margin-bottom: 28px;
        padding: 18px 14px 20px;
        background-image: url("/include/parma_jersey/images/bg_m.png");
        background-position: center top;
    }

    .parma-jersey__head {
        margin-bottom: 20px;
    }

    .parma-jersey__title {
        font-size: 26px;
    }

    .parma-jersey__mock {
        width: min(100%, 240px);
    }

    .parma-jersey__side {
        right: calc((100% - min(100%, 240px)) / 2 - 56px);
    }

    .parma-jersey__model {
        flex-basis: 168px;
    }

    .parma-jersey__price {
        font-size: 24px;
    }
}
