* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html,
body {
    height: 100%;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen,
        Ubuntu, Cantarell, sans-serif;
    background: #f5f6f8;
    color: #1f2937;
}

.widget-container {
    display: flex;
    flex-direction: column;
    height: 100vh;
    width: 100%;
    background: #ffffff;
}

.widget-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 12px 20px;
    border-bottom: 1px solid #e5e7eb;
    background: #ffffff;
}

.widget-title {
    font-size: 16px;
    font-weight: 600;
    color: #111827;
}

.record-info {
    font-size: 13px;
    color: #6b7280;
}

.tabs {
    display: flex;
    gap: 4px;
    padding: 0 20px;
    background: #ffffff;
    border-bottom: 1px solid #e5e7eb;
}

.tab-button {
    background: transparent;
    border: none;
    border-bottom: 2px solid transparent;
    padding: 12px 16px;
    font-size: 14px;
    font-weight: 500;
    color: #6b7280;
    cursor: pointer;
    transition: color 0.15s ease, border-color 0.15s ease;
    white-space: nowrap;
}

.tab-button:hover {
    color: #2563eb;
}

.tab-button.active {
    color: #2563eb;
    border-bottom-color: #2563eb;
}

.tab-button:focus-visible {
    outline: 2px solid #93c5fd;
    outline-offset: -2px;
    border-radius: 4px;
}

.tab-content {
    flex: 1;
    position: relative;
    overflow: hidden;
}

.tab-panel {
    position: absolute;
    inset: 0;
    display: none;
}

.tab-panel.active {
    display: block;
}

.artifact-frame {
    width: 100%;
    height: 100%;
    border: 0;
    display: block;
}

@media (max-width: 640px) {
    .widget-header {
        padding: 10px 14px;
    }

    .tabs {
        padding: 0 8px;
        overflow-x: auto;
    }

    .tab-button {
        padding: 10px 12px;
        font-size: 13px;
    }
}
