@font-face {
    font-family: 'Topol';
    src: url('TopolRegular.ttf') format('truetype');
}

body {
    margin: 0;
    padding: 0;
    background-color: white;
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 100vh;
    position: relative;
}

.back-area {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 1;
    cursor: pointer;
}

.viewer-wrapper {
    width: calc(min(100vw, 100vh) * 0.75);
    height: calc(min(100vw, 100vh) * 0.75);
    position: relative;
    z-index: 2;
    overflow: hidden;

    /* nový clipping path – rohy ubírají 10 % */
    clip-path: polygon(
        10% 0%,
        90% 0%,
        100% 10%,
        100% 90%,
        90% 100%,
        10% 100%,
        0% 90%,
        0% 10%
    );
}

/* pseudo-element pro oranžový okraj */
.viewer-wrapper::before {
    content: "";
    position: absolute;
    inset: -6px; /* dilate – zvětšení okraje ven */
    z-index: -1;

    background: rgb(243, 91, 52);

    /* stejné polygon rohy – ale zvětšené o stejný inset */
    clip-path: polygon(
        calc(10% + 3px) 3px,
        calc(90% - 3px) 3px,
        calc(100% - 3px) calc(10% + 3px),
        calc(100% - 3px) calc(90% - 3px),
        calc(90% - 3px) calc(100% - 3px),
        calc(10% + 3px) calc(100% - 3px),
        3px calc(90% - 3px),
        3px calc(10% + 3px)
    );
}

model-viewer {
    width: 100%;
    height: 100%;
    display: block;
    pointer-events: auto;
}

.loading {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    font-family: 'Topol', Arial, sans-serif;
    color: #ffffff;
    font-size: 24px;
    z-index: 3;
}
