#mock-screen-wrapper {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    height: 100%;
}

#mock-screen {
    transform-origin: center center;
    transition: transform 0.2s cubic-bezier(0.4, 0, 0.2, 1), box-shadow 0.2s cubic-bezier(0.4, 0, 0.2, 1);
    width: 375px;
    height: 812px;
    flex-shrink: 0;
}

#mock-screen.is-resizing {
    transition: none !important;
}

#mock-screen.is-focused {
    box-shadow: var(--shadow-lg), 0 0 0 2px var(--color-accent);
}

#mock-screen iframe {
    background: #ffffff;
    display: block;
    width: 100%;
    height: 100%;
    border: none;
    border-radius: inherit;
}

#overlay-shield {
    position: absolute;
    inset: 0;
    z-index: 10;
    cursor: grab;
}

#overlay-shield.active {
    cursor: grabbing;
}

.frame-loading {
    position: absolute;
    inset: 0;
    z-index: 25;
    background: rgba(15, 23, 42, 0.22);
    backdrop-filter: blur(1px);
    display: flex;
    align-items: center;
    justify-content: center;
}

.frame-loading .spinner {
    width: 30px;
    height: 30px;
    border-radius: 999px;
    border: 3px solid rgba(255, 255, 255, 0.35);
    border-top-color: #ffffff;
    animation: frame-spin 0.9s linear infinite;
}

@keyframes frame-spin {
    from { transform: rotate(0deg); }
    to { transform: rotate(360deg); }
}

.resize-handle {
    position: absolute;
    z-index: 20;
    transition: background-color 0.2s ease;
}

.resize-handle::before {
    content: '';
    position: absolute;
    background-color: var(--color-border);
    transition: background-color 0.2s ease;
}

.resize-handle:hover::before,
#mock-screen.is-resizing .resize-handle::before {
    background-color: var(--color-accent);
}

.handle-r {
    top: 0;
    right: -10px;
    bottom: 0;
    width: 20px;
    cursor: col-resize;
}

.handle-r::before {
    top: 50%;
    right: 8px;
    transform: translateY(-50%);
    width: 4px;
    height: 32px;
    border-radius: 4px;
}

.handle-b {
    left: 0;
    right: 0;
    bottom: -10px;
    height: 20px;
    cursor: row-resize;
}

.handle-b::before {
    bottom: 8px;
    left: 50%;
    transform: translateX(-50%);
    width: 32px;
    height: 4px;
    border-radius: 4px;
}

.handle-br {
    right: -10px;
    bottom: -10px;
    width: 24px;
    height: 24px;
    cursor: nwse-resize;
}

.handle-br::after {
    content: '';
    position: absolute;
    bottom: 8px;
    right: 8px;
    width: 8px;
    height: 8px;
    border-bottom: 3px solid var(--color-border);
    border-right: 3px solid var(--color-border);
    border-bottom-right-radius: 2px;
    transition: border-color 0.2s ease;
}

.handle-br:hover::after,
#mock-screen.is-resizing .handle-br::after {
    border-color: var(--color-accent);
}

@media (max-width: 768px) {
    .resize-handle {
        display: none;
    }
}
