.product-detail {

    display:none;

}


.product-detail.visible {

    display:block;
    animation:detailEnter 0.45s ease;

}


.detail-back {

    position:relative;
    border:none;
    background:#f3e9ff;
    color:#7130cc;
    border-radius:12px;
    padding:12px 16px;
    font-size:15px;
    font-weight:700;
    cursor:pointer;
    margin-bottom:26px;
    transition:transform 0.22s ease, box-shadow 0.22s ease, background 0.22s ease;

}


.detail-back:hover {

    background:#eadbff;
    transform:translateY(-2px);
    box-shadow:0 12px 28px rgba(155, 60, 255, 0.16);

}


.detail-layout {

    display:grid;
    grid-template-columns:minmax(0, 1fr) minmax(360px, 0.9fr);
    gap:42px;
    align-items:start;

}


.detail-preview {

    position:relative;
    aspect-ratio:1880 / 1324;
    min-height:0;
    border:1px solid #eee7f8;
    border-radius:18px;
    background:
        radial-gradient(circle at 20% 12%, rgba(155, 60, 255, 0.12), transparent 30%),
        white;
    display:flex;
    align-items:center;
    justify-content:center;
    overflow:hidden;
    box-shadow:0 18px 46px rgba(31, 31, 41, 0.1);
    transform:perspective(1100px) rotateX(var(--preview-rotate-x, 0deg)) rotateY(var(--preview-rotate-y, 0deg));
    transition:transform 0.18s ease, box-shadow 0.25s ease;

}


.detail-preview::before {

    content:"";
    position:absolute;
    inset:0;
    z-index:1;
    background:radial-gradient(circle at var(--preview-x, 50%) var(--preview-y, 50%), rgba(155, 60, 255, 0.18), transparent 34%);
    opacity:0;
    pointer-events:none;
    transition:opacity 0.22s ease;

}


.detail-preview:hover {

    box-shadow:0 24px 58px rgba(31, 31, 41, 0.15);

}


.detail-preview:hover::before {

    opacity:1;

}


.detail-preview img {

    position:relative;
    z-index:0;
    width:100%;
    height:100%;
    display:block;
    object-fit:contain;
    cursor:pointer;
    user-select:none;
    -webkit-user-select:none;
    -webkit-user-drag:none;

}


.detail-preview-icon {

    width:190px;
    height:190px;
    border-radius:38px;
    background:#f0e8ff;
    display:flex;
    align-items:center;
    justify-content:center;
    font-size:88px;

}


.detail-hint {

    position:absolute;
    z-index:2;
    left:50%;
    bottom:18px;
    transform:translateX(-50%);
    border-radius:999px;
    background:rgba(31, 31, 41, 0.72);
    color:white;
    padding:9px 16px;
    font-size:14px;
    font-weight:700;

}


.detail-breadcrumbs {

    margin-bottom:22px;
    color:#7a7485;
    font-size:15px;
    font-weight:700;

}


.detail-info h1 {

    margin:0 0 16px;
    color:#1f1f29;
    font-size:36px;
    line-height:1.12;

}


.detail-rating {

    display:flex;
    align-items:center;
    gap:14px;
    margin-bottom:26px;
    color:#f5a400;
    font-size:24px;

}


.detail-rating small {

    color:#7a7485;
    font-size:16px;
    font-weight:700;

}


.detail-actions {

    display:grid;
    gap:14px;
    margin-bottom:24px;

}

.detail-actions button,
.detail-author button {

    position:relative;
    overflow:hidden;
    border:none;
    border-radius:14px;
    padding:17px 20px;
    font-size:18px;
    font-weight:800;
    cursor:pointer;
    transition:transform 0.22s ease, box-shadow 0.22s ease, background 0.22s ease, color 0.22s ease;

}


.detail-actions button::after,
.detail-author button::after {

    content:"";
    position:absolute;
    left:var(--detail-click-x, 50%);
    top:var(--detail-click-y, 50%);
    width:12px;
    height:12px;
    border-radius:50%;
    background:rgba(255, 255, 255, 0.46);
    transform:translate(-50%, -50%) scale(0);
    opacity:0;
    pointer-events:none;

}


.detail-actions button.detail-clicked::after,
.detail-author button.detail-clicked::after {

    animation:detailRipple 0.58s ease;

}


.detail-actions button:hover {

    transform:none;

}


.detail-primary {

    border:2px solid #9b3cff !important;
    border-radius:12px !important;
    padding:12px 0 !important;
    background:transparent;
    color:#9b3cff;
    font-size:16px !important;
    font-weight:600 !important;
    line-height:24px;
    box-shadow:none;
    transition:background-color 0.3s cubic-bezier(0.4, 0, 0.2, 1), border-color 0.3s cubic-bezier(0.4, 0, 0.2, 1), color 0.3s cubic-bezier(0.4, 0, 0.2, 1);

}

.detail-primary::after {

    content:none !important;

}


.detail-primary:hover {

    border-color:#8b2ff0 !important;
    background:rgba(155, 60, 255, 0.06);
    color:#8b2ff0;
    box-shadow:none;

}


.detail-primary:active {

    background:rgba(155, 60, 255, 0.11);
    color:#7c28df;

}


.detail-primary:focus-visible {

    outline:3px solid rgba(155, 60, 255, 0.2);
    outline-offset:3px;

}


.detail-secondary {

    border:2px solid #9b3cff !important;
    border-radius:12px !important;
    padding:12px 0 !important;
    background:transparent;
    color:#9b3cff;
    font-size:16px !important;
    font-weight:600 !important;
    line-height:24px;
    box-shadow:none;
    transition:background-color 0.3s cubic-bezier(0.4, 0, 0.2, 1), border-color 0.3s cubic-bezier(0.4, 0, 0.2, 1), color 0.3s cubic-bezier(0.4, 0, 0.2, 1);

}

.detail-secondary::after {

    content:none !important;

}


.detail-secondary:not(.detail-secondary-active) {

    background:transparent;
    color:#9b3cff;
    box-shadow:none;

}


.detail-secondary:hover,
.detail-secondary:not(.detail-secondary-active):hover {

    border-color:#8b2ff0 !important;
    background:rgba(155, 60, 255, 0.06);
    color:#8b2ff0;
    box-shadow:none;

}


.detail-secondary:focus-visible {

    outline:3px solid rgba(155, 60, 255, 0.2);
    outline-offset:3px;

}


.detail-secondary-active {

    border-color:#8b2ff0 !important;
    background:rgba(155, 60, 255, 0.11);
    color:#7c28df;
    box-shadow:none;

}


@media (hover:hover) and (pointer:fine) {

    .detail-secondary:not(.detail-secondary-active):hover {

        background:rgba(155, 60, 255, 0.06);
        color:#8b2ff0;
        box-shadow:none;

    }

}


.detail-author {

    display:grid;
    grid-template-columns:auto 1fr auto;
    gap:16px;
    align-items:center;
    padding:20px;
    border:1px solid #eee7f8;
    border-radius:18px;
    background:white;
    box-shadow:0 12px 32px rgba(31, 31, 41, 0.08);
    transition:box-shadow 0.22s ease;

}


.detail-author:hover {

    box-shadow:0 18px 38px rgba(31, 31, 41, 0.11);

}


.detail-author-avatar {

    width:58px;
    height:58px;
    border-radius:50%;
    background:#f0e8ff;
    display:flex;
    align-items:center;
    justify-content:center;
    font-size:28px;
    overflow:hidden;
    border:2px solid rgba(155, 60, 255, 0.28);
    box-shadow:0 8px 18px rgba(155, 60, 255, 0.14);

}


.detail-author-avatar img {

    width:100%;
    height:100%;
    display:block;
    object-fit:cover;

}


.detail-author strong {

    color:#1f1f29;
    font-size:19px;

}


.detail-author p {

    margin:4px 0 0;
    color:#7a7485;
    font-weight:700;

}


.detail-author button {

    background:#f8f3ff;
    color:#9b3cff;
    font-size:16px;

}


.detail-author .detail-author-message {

    position:relative;
    width:162px;
    min-width:146px;
    min-height:48px;
    display:inline-flex;
    align-items:center;
    justify-content:center;
    padding:0 16px;
    text-align:center;
    border:2px solid #9b3cff !important;
    border-radius:12px !important;
    background:transparent;
    color:#9b3cff;
    font-size:16px;
    font-weight:600;
    line-height:24px;
    box-shadow:none;
    transform:none;
    transition:none;
    animation:none;
    overflow:hidden;
    isolation:isolate;
    white-space:nowrap;

}


.detail-author .detail-author-message::before,
.detail-author .detail-author-message::after {

    content:none !important;
    animation:none !important;

}


.detail-author .detail-author-message > span {

    position:relative;
    z-index:1;
    display:block;
    width:100%;
    text-align:center;
    line-height:inherit;

}


.detail-author .detail-author-message:hover,
.detail-author .detail-author-message:active,
.detail-author .detail-author-message.detail-author-button-opening {

    border-color:#9b3cff !important;
    background:transparent;
    color:#9b3cff;
    box-shadow:none;
    transform:none;

}


.detail-author .detail-author-message:focus-visible {

    outline:3px solid rgba(155, 60, 255, 0.2);
    outline-offset:3px;

}


.detail-author .detail-author-message.detail-author-button-opening {

    pointer-events:none;

}

@media (max-width:640px) {

    .detail-author .detail-author-message {
        width:100%;
    }

}


.detail-tabs {

    position:relative;
    margin-top:48px;
    display:grid;
    grid-template-columns:repeat(3, 1fr);
    border:1px solid #eee7f8;
    border-radius:18px 18px 0 0;
    overflow:hidden;
    background:white;

}


.detail-tabs button {

    position:relative;
    z-index:1;
    border:none;
    background:white;
    color:#7a7485;
    padding:20px;
    font-size:16px;
    font-weight:800;
    cursor:pointer;
    transition:background 0.2s ease, color 0.2s ease, box-shadow 0.2s ease;

}


.detail-tabs button:hover {

    background:#fbf8ff;
    color:#9b3cff;

}


.detail-tabs button.active {

    color:#9b3cff;

}


.detail-tabs-indicator {

    position:absolute;
    left:0;
    bottom:0;
    z-index:2;
    height:3px;
    border-radius:999px 999px 0 0;
    background:#9b3cff;
    transform:translateX(0);
    transition:transform 0.34s cubic-bezier(0.22, 1, 0.36, 1), width 0.34s cubic-bezier(0.22, 1, 0.36, 1);
    pointer-events:none;

}


.detail-description {

    overflow:hidden;
    padding:34px;
    border:1px solid #eee7f8;
    border-top:none;
    border-radius:0 0 18px 18px;
    background:white;
    transition:height 0.34s cubic-bezier(0.22, 1, 0.36, 1), opacity 0.22s ease, transform 0.22s ease;

}


.detail-description-switching {

    will-change:height;

}


.detail-description-body {

    opacity:1;
    transform:translateY(0);
    transition:opacity 0.18s ease, transform 0.22s ease;

}


.detail-description-body-hidden {

    opacity:0;
    transform:translateY(12px);

}


.detail-animate {

    opacity:0;
    transform:translateY(24px);

}


.detail-animate-visible {

    opacity:1;
    transform:translateY(0);
    transition:opacity 0.48s ease, transform 0.48s ease, box-shadow 0.22s ease, background 0.22s ease;

}


.detail-description h2 {

    margin:0 0 14px;
    font-size:26px;

}


.detail-description p,
.detail-description li {

    color:#5f6472;
    font-size:18px;
    line-height:1.55;

}


.detail-description ul {

    margin:18px 0 0;
    padding-left:22px;

}


.detail-related {

    margin-top:54px;
    scroll-margin-top:calc(var(--header-space) + 24px);

}


/* На широком экране рекомендации занимают ту же рабочую ширину, что и каталог. */
@media (min-width:901px) {

    .detail-related {

        position:relative;
        left:50%;
        width:calc(100vw - clamp(64px, 7vw, 160px));
        max-width:3000px;
        margin-left:calc(-50vw + clamp(32px, 3.5vw, 80px));

    }

}


.detail-related-title {

    margin:0 0 24px;
    color:#1f1f29;
    font-size:30px;
    line-height:1.2;

}


.detail-related-grid {

    margin-top:0;

}


.detail-related-empty {

    display:none;
    align-items:center;
    gap:18px;
    max-width:760px;
    margin:0 auto 28px;
    padding:24px;
    border:1px solid #eadbff;
    border-radius:18px;
    background:linear-gradient(135deg, rgba(155, 60, 255, 0.08), rgba(255, 255, 255, 0.96));
    box-shadow:0 14px 36px rgba(31, 31, 41, 0.08);

}


.detail-related-empty .empty-content {

    flex:1;

}


.detail-related-empty.visible {

    display:flex;
    animation:detailEnter 0.34s ease;

}


.detail-related-empty h3 {

    margin:0 0 6px;
    color:#1f1f29;
    font-size:22px;

}


.detail-related-empty p {

    margin:0;
    color:#5f6472;
    font-size:16px;
    line-height:1.45;

}


.detail-related-empty button {

    border:none;
    border-radius:14px;
    background:#9b3cff;
    color:white;
    padding:14px 24px;
    font-size:16px;
    font-weight:700;
    cursor:pointer;
    white-space:nowrap;
    box-shadow:0 12px 28px rgba(155, 60, 255, 0.24);
    transition:transform 0.2s ease, background 0.2s ease, box-shadow 0.2s ease;

}


.detail-related-empty button:hover {

    background:#842de6;
    transform:translateY(-2px);
    box-shadow:0 16px 34px rgba(155, 60, 255, 0.32);

}


.detail-related-empty button.empty-clicked {

    animation:emptyButtonPulse 0.42s ease;

}


.detail-related-loader {

    min-height:68px;
    display:flex;
    align-items:center;
    justify-content:center;
    color:#7a7485;
    font-size:16px;
    font-weight:800;
    opacity:0.82;

}


.detail-related-loader.done {

    display:none;

}


.image-modal {

    position:fixed;
    inset:0;
    z-index:200;
    padding:40px;
    background:rgba(20, 14, 30, 0.82);
    display:flex;
    align-items:center;
    justify-content:center;
    opacity:0;
    pointer-events:none;
    transition:opacity 0.25s ease;

}


.image-modal[hidden] {

    display:none !important;

}


.image-modal.open {

    opacity:1;
    pointer-events:auto;

}

.image-modal.checkout-preview-open {
    z-index:5100;
}


.modal-image {

    max-width:min(1100px, 92vw);
    max-height:86vh;
    border-radius:18px;
    background:white;
    box-shadow:0 28px 80px rgba(0, 0, 0, 0.36);
    transform:scale(0.94);
    transition:transform 0.25s ease;
    user-select:none;
    -webkit-user-select:none;
    -webkit-user-drag:none;

}


.image-modal.open .modal-image {

    transform:scale(1);

}


.modal-close {

    position:absolute;
    z-index:2;
    top:22px;
    right:26px;
    width:44px;
    height:44px;
    border:none;
    border-radius:50%;
    background:white;
    color:#1f1f29;
    font-size:32px;
    line-height:0;
    display:flex;
    align-items:center;
    justify-content:center;
    padding:0 0 2px;
    cursor:pointer;
    box-shadow:0 12px 32px rgba(0, 0, 0, 0.2);

}


.auth-modal {

    position:fixed;
    inset:0;
    z-index:220;
    padding:20px;
    background:rgba(28, 23, 38, 0.48);
    display:flex;
    align-items:center;
    justify-content:center;
    opacity:0;
    pointer-events:none;
    transition:opacity 0.34s ease, backdrop-filter 0.42s ease;
    backdrop-filter:blur(0) saturate(0.96);
    -webkit-backdrop-filter:blur(0) saturate(0.96);

}


.auth-modal[hidden] {

    display:none;

}


.auth-modal.open {

    opacity:1;
    pointer-events:auto;
    backdrop-filter:blur(9px) saturate(0.9);
    -webkit-backdrop-filter:blur(9px) saturate(0.9);

}


.auth-panel {

    position:relative;
    width:min(420px, 100%);
    padding:30px;
    overflow:hidden;
    border:1px solid #eadff5;
    border-radius:20px;
    background:rgba(255, 255, 255, 0.98);
    box-shadow:0 30px 90px rgba(31, 31, 41, 0.24), 0 10px 32px rgba(113, 48, 204, 0.1);
    opacity:0;
    filter:blur(4px);
    transform:translateY(30px) scale(0.965);
    transform-origin:center bottom;
    transition:opacity 0.3s ease, transform 0.46s cubic-bezier(0.16, 1, 0.3, 1), filter 0.32s ease;
    will-change:opacity, transform, filter;

}


.auth-panel:focus {

    outline:none;

}


.auth-modal.open .auth-panel {

    opacity:1;
    filter:blur(0);
    transform:translateY(0) scale(1);

}


.auth-close {

    position:absolute;
    z-index:2;
    top:14px;
    right:14px;
    width:32px;
    height:32px;
    border:1px solid #eadcf9;
    background:#ffffff;
    color:#7130cc;
    border-radius:50%;
    font-size:22px;
    line-height:1;
    cursor:pointer;
    opacity:0;
    transform:scale(0.85) rotate(-12deg);
    box-shadow:0 6px 18px rgba(113, 48, 204, 0.08);
    transition:background 0.2s ease, border-color 0.2s ease, opacity 0.32s ease, transform 0.38s cubic-bezier(0.16, 1, 0.3, 1);

}


.auth-panel.auth-panel-ready .auth-close {

    opacity:1;
    transform:scale(1) rotate(0);

}


.auth-panel.auth-panel-ready .auth-close:hover {

    background:#f6edff;
    border-color:#d9bff5;
    transform:scale(1.04);

}


.auth-heading {

    padding-right:38px;
    margin-bottom:22px;

}


.auth-heading h2 {

    margin:0 0 8px;
    color:#25202d;
    font-size:27px;
    line-height:1.15;

}


.auth-heading p {

    margin:0;
    color:#666270;
    font-size:15px;
    line-height:1.45;

}


.vkid-auth {

    position:relative;
    min-height:48px;
    display:grid;
    align-items:center;
    border-radius:10px;
    transition:transform 0.22s ease;

}


.vkid-auth::before {

    content:"";
    position:absolute;
    inset:0;
    z-index:2;
    border-radius:10px;
    background:#f0e7fa;
    opacity:0;
    pointer-events:none;

}


.vkid-auth.vkid-loading::before {

    opacity:1;
    animation:authLoadingPulse 1s ease-in-out infinite alternate;

}


.vkid-auth.vkid-ready:active {

    transform:scale(0.99);

}


.local-auth-button {

    width:100%;
    min-height:54px;
    display:flex;
    align-items:center;
    justify-content:center;
    gap:10px;
    border:0;
    border-radius:12px;
    background:linear-gradient(135deg, #9b3cff 0%, #7130cc 100%);
    color:#ffffff;
    font:inherit;
    font-size:17px;
    font-weight:800;
    cursor:pointer;
    box-shadow:0 14px 34px rgba(113, 48, 204, 0.24);
    transition:transform 0.2s ease, box-shadow 0.24s ease, filter 0.24s ease;

}


.local-auth-button span:first-child {

    width:24px;
    height:24px;
    display:grid;
    place-items:center;
    border-radius:50%;
    background:rgba(255, 255, 255, 0.18);
    font-size:15px;

}


.local-auth-button:hover {

    filter:saturate(1.06);
    box-shadow:0 18px 40px rgba(113, 48, 204, 0.3);
    transform:translateY(-1px);

}


.local-auth-button:active {

    transform:scale(0.985);
    box-shadow:0 10px 24px rgba(113, 48, 204, 0.2);

}

.vkid-auth > div,
.vkid-auth iframe {

    width:100% !important;
    max-width:100% !important;

}


.auth-status {

    min-height:0;
    margin:12px 0 0;
    color:#696978;
    font-size:14px;
    line-height:1.4;

}


.auth-status:empty {

    display:none;

}


.auth-heading,
.vkid-auth,
.auth-status {

    opacity:0;
    transform:translateY(14px);

}


.auth-panel.auth-panel-ready .auth-heading,
.auth-panel.auth-panel-ready .vkid-auth,
.auth-panel.auth-panel-ready .auth-status {

    animation:authContentIn 0.52s cubic-bezier(0.16, 1, 0.3, 1) both;

}


.auth-panel.auth-panel-ready .vkid-auth {

    animation-delay:0.09s;

}


.auth-panel.auth-panel-ready .auth-status {

    animation-delay:0.14s;

}


.auth-status.error {

    color:#c0397b;

}


.login.logged-in {

    background:#f4ecff !important;
    color:#8b3dff;
    width:44px;
    height:44px;
    min-height:44px;
    padding:0;
    border-radius:50%;
    gap:0;
    display:grid;
    place-items:center;
    box-shadow:inset 0 0 0 1px rgba(155, 60, 255, 0.14);

}


.login.logged-in:hover {

    background:#efe3ff !important;
    box-shadow:0 8px 22px rgba(155, 60, 255, 0.14);
    transform:translateY(-1px);

}


.login.logged-in[aria-expanded="true"] {

    background:#9b3cff !important;
    color:white;
    box-shadow:0 12px 28px rgba(155, 60, 255, 0.28);

}


.login.logged-in[aria-expanded="true"]:hover {

    background:#8b2ff0 !important;

}


.login.logged-in .login-avatar {

    width:44px;
    height:44px;
    flex-basis:44px;
    display:block;
    margin:0;
    border:0;
    background:transparent;
    color:currentColor;
    box-shadow:none;

}


.login.logged-in .login-avatar::before,
.login.logged-in .login-avatar::after {

    border:0;
    background:currentColor;

}


.login.logged-in .login-avatar.has-image {

    overflow:hidden;
    background-position:center;
    background-size:cover;

}


.login.logged-in .login-avatar.has-image::before,
.login.logged-in .login-avatar.has-image::after {

    display:none;

}


.login.logged-in .login-avatar::before {

    top:12px;
    width:8px;
    height:8px;

}


.login.logged-in .login-avatar::after {

    bottom:11px;
    width:19px;
    height:10px;
    border-radius:12px 12px 5px 5px;

}


.login.logged-in .login-label {

    display:none;

}

/* Branding belongs only to the enlarged public preview. */
.material-watermarked-preview { position:relative; display:inline-flex; line-height:0; }
.material-watermarked-preview::after {
    content:""; position:absolute; inset:0; pointer-events:none; border-radius:18px;
    background-image:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='280' height='170'%3E%3Ctext x='140' y='90' text-anchor='middle' transform='rotate(-28 140 90)' font-family='Arial,sans-serif' font-size='30' font-weight='600' fill='%23634b81' fill-opacity='.24'%3Euchitell.ru%3C/text%3E%3C/svg%3E");
}
