/* Ujjina Player Studio - Preview Panel */

.preview-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 14px 24px;
    border-bottom: 1px solid var(--border);
    background: var(--surface);
}

.preview-header h2 {
    font-size: 11px;
    font-weight: 800;
    color: var(--accent);
    text-transform: uppercase;
    letter-spacing: 2px;
}

.preview-size-controls {
    display: flex;
    gap: 4px;
    align-items: center;
}

.preview-size-sep {
    width: 1px;
    height: 22px;
    background: var(--border);
    margin: 0 6px;
}

.preview-size-btn {
    width: 36px;
    height: 36px;
    border: 1px solid var(--border);
    border-radius: 10px;
    background: var(--surface);
    color: var(--text-muted);
    cursor: pointer;
    font-size: 14px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s;
}

.preview-size-btn:hover {
    background: var(--surface-hover);
    color: var(--text);
    border-color: var(--border-accent);
}

.preview-size-btn.active {
    border-color: var(--accent);
    color: var(--accent);
    background: var(--accent-soft);
    box-shadow: 0 0 0 3px var(--accent-glow);
}

/* Preview container */
.preview-container {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 28px 24px;
    min-height: 300px;
}

/* Device frame wrapper */
.preview-device-frame {
    position: relative;
    overflow: hidden;
    border-radius: 10px;
    box-shadow: var(--shadow-lg), 0 0 0 1px rgba(255, 255, 255, 0.05);
    background: #000;
    margin-bottom: 30px;
}

/* The iframe */
.preview-iframe {
    display: block;
    border: none;
    background: #000;
}

/* Device label */
.preview-device-label {
    position: absolute;
    bottom: -26px;
    left: 0;
    right: 0;
    text-align: center;
    font-size: 10px;
    font-weight: 600;
    color: var(--text-muted);
    opacity: 0.4;
    white-space: nowrap;
    letter-spacing: 1px;
    text-transform: uppercase;
}

.preview-placeholder {
    width: 100%;
    height: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    color: var(--text-muted);
    font-size: 14px;
    text-align: center;
    padding: 20px;
    min-height: 220px;
    font-weight: 500;
    gap: 8px;
}

/* Embed section */
.embed-section {
    padding: 24px;
    border-top: 1px solid var(--border);
    background: var(--bg-secondary);
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.embed-block {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.embed-section h3 {
    font-size: 11px;
    font-weight: 800;
    color: var(--accent);
    text-transform: uppercase;
    letter-spacing: 2px;
    margin-bottom: 0;
}

.embed-hint {
    font-size: 11px;
    color: var(--text-secondary);
}

.embed-code-wrap {
    display: flex;
    gap: 10px;
    align-items: flex-start;
}

.embed-code-wrap code {
    flex: 1;
    padding: 14px;
    background: var(--input-bg);
    border: 1px solid var(--input-border);
    border-radius: 10px;
    font-family: 'SF Mono', 'Fira Code', 'Consolas', monospace;
    font-size: 11px;
    color: var(--accent-hover);
    word-break: break-all;
    line-height: 1.6;
    display: block;
}

/* Responsive */
@media (max-width: 768px) {
    .preview-container {
        padding: 16px 12px;
    }

    .preview-header {
        padding: 10px 14px;
    }

    .embed-section {
        padding: 16px;
    }

    .embed-code-wrap {
        flex-direction: column;
    }
}

@media (max-width: 480px) {
    .preview-size-controls {
        display: none;
    }

    .preview-container {
        padding: 12px 8px;
        min-height: 220px;
    }

    .preview-device-frame {
        max-width: 100%;
        margin-bottom: 20px;
    }

    .preview-iframe {
        max-width: 100%;
    }

    .embed-section {
        padding: 12px;
    }

    .embed-code-wrap code {
        font-size: 10px;
        padding: 10px;
    }
}
